{
  "$schema": "https://developer.microsoft.com/json-schemas/sp/v2/column-formatting.schema.json",
  "elmType": "div",
  "children": [
    {
      "elmType": "span",
      "txtContent": "@currentField",
      "style": {
        "display": "=if(@currentField == '', 'none', 'inline-block')",
        "white-space": "nowrap",
        "padding": "2px 10px",
        "border-radius": "12px",
        "font-weight": "600"
      },
      "attributes": {
        "class": "=if(@currentField == 'Validé', 'sp-css-backgroundColor-BgMintGreen sp-css-color-MintGreenFont', if(@currentField == 'En relecture', 'sp-css-backgroundColor-BgGold sp-css-color-GoldFont', if(@currentField == 'Brouillon', 'sp-css-backgroundColor-BgCornflowerBlue sp-css-color-CornflowerBlueFont', 'sp-css-backgroundColor-BgLightGray sp-css-color-LightGrayFont')))"
      }
    }
  ]
}
