Hi,
I need to increase the size of text box filters in my dashboard. I need to be able to increase size of all or select textbox filter. I found below solution from a previous post but it is not working in Splunk Enterprise versions 7.x and 8.x. Can someone assist pls? Thanks in -advance!!!
<form>
<label>Text Box Size</label>
<fieldset submitButton="false">
</fieldset>
<row>
<panel depends="$alwaysHideCSSStyle$">
<html>
<style>
#text4 .splunk-textinput
{
width: 300px !important;
}
#text4 .splunk-textinput input{
width: 300px !important;
}
#text5
{
padding-left:95px !important;
}
#text5 .splunk-textinput
{
width: 300px !important;
}
#text5 .splunk-textinput input{
width: 300px !important;
}
</style>
</html>
</panel>
<panel>
<input id="text1" type="text" token="field1">
<label>field1</label>
</input>
<input id="text2" type="text" token="field2">
<label>field2</label>
</input>
<input id="text3" type="text" token="field3">
<label>field3</label>
</input>
<input id="text4" type="text" token="field4">
<label>field4</label>
</input>
<input id="text5" type="text" token="field5">
<label>field5</label>
</input>
</panel>
</row>
</form>
Splunk Enterprise
@mbasharat All 7.x do not have same DOM structure for Splunk Dashboards. Since the CSS override is not working in 8.x as well. I am guessing you are on 7.1+ or 7.2 or higher. (even 7.1.x and 7.2.x may have different DOMs, but I have no way to check).
Nevertheless, check out the following answer of mine which changes the width of all inputs using CSS override for ver 7.2.x+: https://community.splunk.com/t5/Dashboards-Visualizations/Why-is-the-dropdown-input-width-not-increa...
Please try out for Text Box and confirm as per your use case.
Hi @ niketnilay,
I have tried this solution and it did not work for me. I am @ Splunk Enterprise 7.3.3
@mbasharat I wished you had mentioned specific version 7.3.3 instead of 7.x which becomes vague for us to assist you better. Please refer to one of my older answers about the known issue while applying CSS extension directly through Dashboard XML. PS: You should always move CSS style from dashboard XML (which should be only meant for testing) to CSS static file in the appserver/static for better reusability, reduction of developer errors, separation of concerns and too many overrides for the same node.
May be cache problem. You should run below to see change you make.
http[s]://yourinstance:webport/en-US/_bump
Hi @ thambisetty,
I tried this approach well and no luck so far 😞
Hi @mbasharat , above example dashboard works perfectly fine for me on Splunk Version 8.x
Are you trying above example in a fresh dashboard or you are trying the logic in your dashboard when you say its not working?
Hi @Nisha18789 ,
I havent implemented this in my dashboard yet because I wanted to test first. I simply created a new view by copy/paste of code then tried different sizes in code but textbox sizes never changed.