Changing Font on SharePoint List using Group By

Alan Wells 20 Reputation points
2023-08-30T20:42:39.7666667+00:00

I am using SharePoint Server Subscription Edition On-Premise and have a lot of document libraries. Many of these lists/libraries contain a column named Category and in the List Settings we have the default view set to Group By Category. This reduces the size of the list when viewing those with a lot of documents.

I found the ability to adjust the font size on a specific column by adding this JSON info.

{ "$schema": "https://developer.microsoft.com/json-schemas/sp/column-formatting.schema.json", "elmType": "div", "debugMode": true, "txtContent": "@currentField", "style": { "font-size": "18pt" } }

This appears to only affect the actual document names inside each Category group but not the group name itself.

I even tried adding the category as a column in the view and applying the JSON there but that didn't work.

Does anyone know how to make this font smaller?

Capture

Microsoft 365 and Office | SharePoint Server | For business
0 comments No comments
{count} votes

Accepted answer
  1. Emily Du-MSFT 51,836 Reputation points Microsoft External Staff
    2023-08-31T07:10:17.69+00:00

    To change font size of category group header, you need to apply JSON codes in the list view formatting.

    Currently, according to this Microsoft article, list view formatting is currently supported only in the SharePoint Online.

    User's image

    Unfortunately, there is no option to change font size of category group header.


    If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.