{
  "$schema": "https://developer.microsoft.com/json-schemas/sp/v2/column-formatting.schema.json",
  "elmType": "div",
  "children": [
    {
      "elmType": "div",
      "style": {
        "width": "95%",
        "height": "30px",
        "display": "flex",
        "flex-direction": "row",
        "align-items": "center",
        "justify-content": "space-evenly",
        "margin": "5px",
        "min-width": "220px"
      },
      "attributes": {
        "class": "ms-fontColor-neutralTertiary"
      },
      "children": [
        {
          "elmType": "div",
          "forEach": "score in split('0,1,2,3,4,5,6,7,8,9,10',',')",
          "style": {
            "display": "flex",
            "justify-content": "center",
            "align-items": "center",
            "width": "100%",
            "height": "23px",
            "border": "1px solid",
            "border-left": "=if(Number([$score])==0,'','none')"
          },
          "attributes": {
            "class": "=if(Number([$score])==floor(Number(@currentField)),'ms-bgColor-themePrimary','')"
          },
          "children": [
            {
              "elmType": "div",
              "txtContent": "[$score]",
              "attributes": {
                "class": "='ms-font-m-plus ' + if(Number([$score])==floor(Number(@currentField)),'ms-fontColor-white','')"
              }
            }
          ]
        }
      ]
    }
  ]
}