Created
April 28, 2024 09:49
-
-
Save tecchan1107/347e125a65eb0c3d04eb65235457c428 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"$schema": "https://developer.microsoft.com/json-schemas/sp/v2/column-formatting.schema.json", | |
"elmType": "div", | |
"children": [ | |
{ | |
"elmType": "div", | |
"style": { | |
"display": "flex", | |
"flex-direction": "column" | |
}, | |
"children": [ | |
{ | |
"elmType": "div", | |
"style": { | |
"display": "=if(@currentField.email,'flex','none')", | |
"flex-direction": "row", | |
"align-items": "center", | |
"white-space": "nowrap", | |
"border-radius": "14px" | |
}, | |
"attributes": { | |
"class": "=if(@currentField.email==@me,'ms-bgColor-themeLighter ms-fontColor-themeDarker','ms-bgColor-neutralLight ms-fontColor-neutralPrimary')" | |
}, | |
"defaultHoverField": "@currentField", | |
"children": [ | |
{ | |
"elmType": "img", | |
"style": { | |
"width": "28px", | |
"height": "28px", | |
"border-radius": "50%" | |
}, | |
"attributes": { | |
"src": "=getUserImage(@currentField.email, 'small')" | |
} | |
}, | |
{ | |
"elmType": "div", | |
"txtContent": "@currentField.title", | |
"style": { | |
"padding-left": "6px", | |
"padding-right": "10px" | |
}, | |
"attributes": { | |
"class": "ms-fontSize-s" | |
} | |
} | |
] | |
} | |
] | |
} | |
] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment