Forum Discussion
Unable to format document library Title field with JSON
- Mar 25, 2019
Hello tiredoldcoder ,
I don't believe the Name/Title column is supported.
From Use column formatting to customize SharePoint:
Supported column types
The following column types support column formatting:
- Single line of text
- Number
- Choice
- Person or Group
- Yes/No
- Hyperlink
- Picture
- Date/Time
- Lookup
- Title (in Lists)
The following are not currently supported:
- Managed Metadata
- Filename (in Document Libraries)
- Calculated
- Retention Label
- Currency
I hope this helps.
Norm
Hi tiredoldcoder,
Can you please post the JSON you are using for the field? I was able to reproduce this exact behavior and seems buggy to me.
Format the Title, and paste this JSON just to bold it for example:
{ "$schema":"http://columnformatting.sharepointpnp.com/columnFormattingSchema.json",
"elmType":"div",
"style":{
"font-weight":"bold"
}, "txtContent":"@currentField"
}
Click Save, it shows. Click the X to close the format dialog, the formatting disappears. I do the exact same thing to a different column like Name, click the X and the formatting sticks. If you edit the library and put it in Title, it does indeed remove it as saving it. Its like they don't want you to save it.
I'd like someone else to validate. Is the Title field locked or something underneath that prevents this from working?