
Announcements
Hello
I am trying to create a tiles view with json.
I have a custom tenant and the following code works, in my devlopment tenant NOT.
{
"$schema": "https://developer.microsoft.com/json-schemas/sp/v2/tile-formatting.schema.json",
"height": 135,
"width": 135,
"hideSelection": true,
"fillHorizontally": false,
"formatter": {
"elmType": "a",
"attributes": {
"href": "[$myURL]",
"class": "sp-row-card sp-card-borderHighlight ms-bgColor-themePrimary ms-bgColor-themeDarker--hover ms-fontColor-white ms-fontColor-themePrimary--hover"
},
"style": {
"width": "135px",
"height": "135px",
"border-color": "#00A0f5",
"border-style": "solid",
"border-width": "1px",
"border-radius": "0px",
"background-color": "#00A0f5",
"white-space": "normal",
"padding": "4px",
"font-size": "8px",
"display": "flex",
"flex-direction": "column",
"justify-content": "center",
"align-items": "center",
"cursor": "pointer",
"text-decoration": "none"
},
"children": [
{
"elmType": "div",
"attributes": {
"class": "ms-bgColor-white sp-css-borderColor-neutralLight sp-card-subContainer"
},
"style": {
"display": "flex",
"flex-direction": "column",
"align-items": "center",
"justify-content": "center",
"background-color": "#00A0f5",
"padding": "8px"
},
"children": [
{
"elmType": "img",
"style": {
"width": "45%",
"height": "auto",
"transition": "transform 0.3s",
"margin-bottom": "8px"
},
"attributes": {
"src": "[$Icone]"
}
},
{
"elmType": "div",
"style": {
"color": "white",
"text-align": "center",
"font-size": "15px",
"font-weight": "600",
"background-color": "#00A0f5"
},
"attributes": {
"class": "ms-fontColor-neutralPrimary sp-card-content sp-card-highlightedContent",
"title": "[$Description]"
},
"txtContent": "[$myName]"
}
]
}
]
}
}
The following list column I am using:
ICON is the link to the icon
Description is as it is 😉
myUrl is where I will go to if I click on the tile and
myTitle is the buttom title of that tile
If somebody has any idea why it works on one tenant and not on the other one..
Please let me know.
Thanks in advance 😉
Cheers
Michael
Do you notice if Microsoft Lists looks different between the two tenants? I have found that my JSON formatting for views have broken on some lists since the latest Microsoft List updates.