Dashboards & Visualizations

font-size in splunk6

crt89
Communicator

Hi is anyone experiencing that the font-size parameter on css doesn't affect the views on Splunk 6? Or its just me. I'm currently applying my custom css for views I can see splunk can load my css but the font-size parameter is not working for me. Put the css files on the proper location still font-size parameter not working. Is it just me?

Tags (3)
0 Karma
1 Solution

grijhwani
Motivator

Use a browser such as Firefox which allows you to perform element inspection. It will show you how CSS is being applied. It is possible element/class names have changed or been augmented and that your CSS is being ignored or over-ridden.

View solution in original post

0 Karma

msuters
New Member

Did you ever find a solution to this question?

I am trying to increase the font size of the single-value result to be bigger than the default of 24px. I have used Firefox/Firebug to inspect the element of a single value result. I can see values being over-ridden (they are crossed out in Firebug) from bootstrap.min.css, dashboard-simple-bootstrap.min.css, and application.css, and the one that remains comes from "mgs" (which is the name of the dashboard), and sets the font size to 24px. I have set the font size parameter to a value other than 24 in all .css files I can find underneath the Splunk directory. I can see these changed values being registered (in Firebug), but 24px still continues to be selected at the end. I have also reset the font size for single-result from 24px to something else (mostly 23px) everywhere else I can find it (including other .css files, .js and .less files). But the single value result font remains at 24px. Are there any other suggestions for what to try?

Similar questions have been asked before, and answers indicated that the syntax of the CSS changed between Splunk versions 4 and 5, and I think version 6 is different again. So those previous answers are not helping with the solution for Splunk 6.

0 Karma

ng1p
Path Finder
0 Karma

crt89
Communicator

Good thing it works for you as well.

0 Karma

ng1p
Path Finder

I am trying to get this to work with Splunk 6.1.3 and I cant get the font to change. Does anyone have this working on Splunk 6.1.x?

In my dashboard I am pointing at single.css using:
dashboard stylesheet="single.css"

Then in this single.css I have the following:
.row-textinputheader .single-value .single-result { color:#FFF; font-size:42px !important; }

Do I have this right?

0 Karma

msuters
New Member

Thanks crt89,
Your solution of the "!important" tag worked for me also. Increased font size makes the dashboards much more effective because the information can be seen from further away. (Colour-coding also helps.)

0 Karma

crt89
Communicator

Yes I did manage to change the font-size of the single values. I added the !important tag. Here's my sample css

.row-textinputheader .single-value .single-result {
color: #FFF;
font-size: 42px !important;
}

0 Karma

grijhwani
Motivator

Use a browser such as Firefox which allows you to perform element inspection. It will show you how CSS is being applied. It is possible element/class names have changed or been augmented and that your CSS is being ignored or over-ridden.

0 Karma

crt89
Communicator

I see thanks for your answer, I'm going to recheck and see what cause my problem.

0 Karma
Get Updates on the Splunk Community!

.conf24 | Registration Open!

Hello, hello! I come bearing good news: Registration for .conf24 is now open!   conf is Splunk’s rad annual ...

ICYMI - Check out the latest releases of Splunk Edge Processor

Splunk is pleased to announce the latest enhancements to Splunk Edge Processor.  HEC Receiver authorization ...

Introducing the 2024 SplunkTrust!

Hello, Splunk Community! We are beyond thrilled to announce our newest group of SplunkTrust members!  The ...