Dashboards & Visualizations

How to reference various elements in Splunk Dashboard

kaeleyt
Path Finder

Hi fellow Splunkers!

I'm trying to figure out how to customize the subtitle of a dashboard (bold the font or change the font size for example). I'm currently using a hidden HTML style panel within my XML so if possible I'd like to continue with that method rather than converting the whole dashboard to HTML.

 

<row>
    <panel>
      <title>Quick Stats</title>
      <single>
        <title>User Counts</title>
        <search>
......
        </search>
      </single>
    </panel>
</row>

 

The "User Counts" title is the one I am interested in adding specific styles to.

Here is an example of how I am currently customizing some of the elements of my dashboard:

 

...
<row>
    <panel>**<html depends="$hiddenForCSS$">**
           <style>
             .dashboard-row {
             padding-bottom: 5px !important;
             padding-top: 5px !important;
             }
            .dashboard-panel h2{
             background:#65A637 !important;
             color:white !important;
             text-align: center !important;
             font-weight: bold !important;
             border-top-right-radius: 15px !important;
             border-top-left-radius: 15px !important;
            }
           </style>
          </html>
    </panel>
  </row>
...

 

I'm mainly trying to identify the correct way to reference the subtitle but if anyone has any general tips for the best way to identify the correct way to reference the various dashboard elements, that would be super helpful as well.

0 Karma
1 Solution

richgalloway
SplunkTrust
SplunkTrust
Perhaps this blog posting by a Splunker will help.
https://www.splunk.com/en_us/blog/tips-and-tricks/splunk-clara-fication-customizing-simplexml-dashbo...
---
If this reply helps you, an upvote would be appreciated.

View solution in original post

richgalloway
SplunkTrust
SplunkTrust
Perhaps this blog posting by a Splunker will help.
https://www.splunk.com/en_us/blog/tips-and-tricks/splunk-clara-fication-customizing-simplexml-dashbo...
---
If this reply helps you, an upvote would be appreciated.

View solution in original post

kaeleyt
Path Finder

@richgallowayThat was very helpful. I was able to find the element by going in to the developer tools, narrowing down to just one of the panels and then once I got down to the subtitle I clicked on it and it actually ends up displaying the exact syntax I can just copy and paste into the XML to override.

Example answer for anyone who needs this:

.dashboard-row .dashboard-panel .panel-head h3{
            font-size: 20px !important;
            }

Thank you so much!

 

0 Karma
.conf21 Now Fully Virtual!
Register for FREE Today!

We've made .conf21 totally virtual and totally FREE! Our completely online experience will run from 10/19 through 10/20 with some additional events, too!