Hi. Thank you for your question and reaching out. My name is John and I’d be more than happy to help you with your query.
Use column formatting to change how fields appear in SharePoint lists and libraries. To achieve this, you construct a JSON object that defines the components that will be used for style when a field is included in a list view, as well as the items that will be displayed when that field is included in the list view. The data itself in the list item or file is unaffected by the column formatting; it only changes how the data is shown to people that explore the list. By employing column formatting, anyone who is capable of generating and managing views in a list can alter how view fields are shown.
For more information, please see https://learn.microsoft.com/en-us/sharepoint/dev/declarative-customization/column-formatting
You can also check this discussion https://answers.microsoft.com/en-us/msoffice/forum/all/teams/fcab025b-38a4-4603-8a88-51617a43db51 that is similar to your concern.
Please don't hesitate to post back for further questions. Best regards, John