Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • K.Garrein 162 posts 626 karma points
    Oct 18, 2019 @ 08:50
    K.Garrein
    0

    Grid Layout styles colorpicker not rendering correct

    I added the following style on a grid layout. This seems to be the way it's done in all the tutorials I find online.

     {
        "label": "Set a background color",
        "description": "Set a background color",
        "key": "background-color",
        "view": "colorpicker",
        "applyTo": "cell",
        "prevalues": [
          "#ffffff",
          "#424242"
        ]
      }
    

    However, when this gets rendered on the front (website), I get the following:

    <div style="background-color:{
          "value": "424242",
          "label": "#424242",
          "id": "1"
        }; color:{
          "value": "ffffff",
         "label": "#ffffff",
          "id": "0"
        };">
                <p>“Quote lorem ipsum dolor sit amet consect etur adipscing elit”</p>
    </div>
    

    How do I get Umbraco to render the selected color in stead of that JSON code?

    Thanks.

  • This forum is in read-only mode while we transition to the new forum.

    You can continue this topic on the new forum by tapping the "Continue discussion" link below.

Please Sign in or register to post replies