Variable associated with names

What Grafana version and what operating system are you using?

  • Oracle Linux Server 8.8
  • Grafana 10.1.1

I have a dashboard with the following variable:
$month = 1M, 2M, 3M

In the “timeShift” function, I use it to select up to 3 previous months from an Zabbix SLA monitoring.

There’s a text box above the SLA visualization that displays a simple text.


Is there a way to display the selected month in a textual form instead of the actual variable value?

For example:

If $month = 1M
Then the text box displays “August”

If $month = 2M
Then the text box displays “July”

If $month = 3M
Then the text box displays “June”