Forum Discussion

amelia's avatar
06-14-2022

Adding text to indicator widget

Hi! I have an indicator widget that is updated weekly to show the latest weekly values. As such, I would like to have a line underneath this number that says something like 'updated as of *latest week date*' . The date would have to be updated based on the most recent week. Is there any way I would be able to achieve something like this? 

 

Thank you!

2 Replies

Replies have been turned off for this discussion
  • harikm007's avatar
    harikm007
    Data Warehouse

    Hi amelia ,

    One option is to use Blox.

    Blox script :

    {
        "style": "",
        "script": "",
        "title": "",
        "showCarousel": true,
        "body": [
            {
                "type": "Container",
                "items": [
                    {
                        "type": "TextBlock",
                        "id": "",
                        "class": "",
                        "horizontalAlignment": "center",
                        "text": "Total Subsribers",
                        "style": {
                            "font-size": "15px",
                            "font-weight": "600",
                            "color": "#575959"
                        }
                    },
                    {
                        "type": "TextBlock",
                        "id": "",
                        "class": "",
                        "horizontalAlignment": "center",
                        "text": "{panel:Value}",
                        "style": {
                            "font-size": "40px",
                            "font-weight": "600",
                            "color": "#0d5442"
                        }
                    },
                    {
                        "type": "TextBlock",
                        "id": "",
                        "class": "",
                        "horizontalAlignment": "center",
                        "text": "updated as of <b>{panel:Date}</b>"
                    }
                ]
            }
        ],
        "actions": []
    }

    -Hari

    • amelia's avatar
      amelia
      ETL

      Thanks so much for the help Hari, this helps! As an extension, I would like to do the same thing for an indicator metric that uses gauges - do you have any advice 😄