Dashboards & Visualizations

Override ">= 0" legend label in sankey diagram?

Graham_Hanningt
Builder

I am using Splunk 8.1.0 with the Sankey Diagram 1.5.0 app.

My query for the sankey diagram conditionally, based on a form input, excludes zero values.

I would like to conditionally—say, based on a token being set—override the ">= 0" legend label with "> 0". I just want to remove the "=" from that label.

As a starting point, I've attempted to unconditionally override the sankey diagram CSS. For example:

    <panel>
      <html>
        <p/>
        <style>
.sankey_diagram > div.legend > ul > li:nth-child(1) > span {
  background-color: red;
}
        </style>
      </html>
    </panel>

but that's had no effect. (I was considering attempting pure a CSS approach: hiding the original content, then using a pseudo element to inject my override.)

It's occurred to me that I could also use a JavaScript document.querySelector to set the content of that span element in the legend, but I'd prefer not to have an external .js file for this.

Labels (2)
0 Karma
Get Updates on the Splunk Community!

Index This | I’m short for "configuration file.” What am I?

May 2024 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with a Special ...

New Articles from Academic Learning Partners, Help Expand Lantern’s Use Case Library, ...

Splunk Lantern is a Splunk customer success center that provides advice from Splunk experts on valuable data ...

Your Guide to SPL2 at .conf24!

So, you’re headed to .conf24? You’re in for a good time. Las Vegas weather is just *chef’s kiss* beautiful in ...