Dashboards & Visualizations

How do you right align a text label with an input check box (defaults to top of checkbox)?

jaj
Path Finder

My label (text description) for my check box is displaying above the checkbox. How do I align the label (text) to the right of my checkbox?

note: i've tried to apply various styling but to no avail

...
  <fieldset submitButton="false" autoRun="true"> 
    </input>
    <input type="checkbox" token="my_checkbox_filter" searchWhenChanged="true">
      <label>Filter Results</label>
      <delimiter> </delimiter>
    </input>
  </fieldset>
...
0 Karma
1 Solution

niketnilay
Legend

@jaj try the following:

<input type="checkbox" token="my_checkbox" searchWhenChanged="true">
  <label></label>
  <delimiter> </delimiter>
  <choice value="filter">Filter Results</choice>
  <change>
    <set token="my_checkbox_filter">$value$</set>
  </change>
</input>
____________________________________________
| makeresults | eval message= "Happy Splunking!!!"

View solution in original post

niketnilay
Legend

@jaj try the following:

<input type="checkbox" token="my_checkbox" searchWhenChanged="true">
  <label></label>
  <delimiter> </delimiter>
  <choice value="filter">Filter Results</choice>
  <change>
    <set token="my_checkbox_filter">$value$</set>
  </change>
</input>
____________________________________________
| makeresults | eval message= "Happy Splunking!!!"

Ashwini008
Contributor

@niketnilay I have 3 input type i.e (input type=time,input type=multiselect,input type=check box) in a single row at the centre.How can i align all these input types to right corner of my panel?

(Drag and drop option isnt working here).

Also how can i increase the font size of my choices/options in radio button input type?

 

Thank you. 

0 Karma

jaj
Path Finder

@niketnilay BAM! works great! thank you! ++ any idea how i can increase the width for longer descriptions instead of it wrapping? can i apply styles in your code somehow and make the width 200% or something?

0 Karma

jaj
Path Finder

@niketnilay
Splunk Enterprise
Version:
7.1.3
Build:
51d9cac7b837

0 Karma

niketnilay
Legend

@jaj I have tried the following on Splunk 7.2 . So kinldy check and confirm whether the same DOM select works or not

<form>
  <label>Checkbox Width</label>
  <fieldset submitButton="false">
  </fieldset>
  <row>
    <panel>
     <input id="myCheckBox" type="checkbox" token="my_checkbox" searchWhenChanged="true">
       <label></label>
       <delimiter> </delimiter>
       <choice value="filter">Filter A Really Really Looooooonnnnnnggggggg Results</choice>
       <change>
         <set token="my_checkbox_filter">$value$</set>
       </change>
     </input>
      <html depends="$alwaysHide$">
        <style>
          #myCheckBox{
            min-width: 400px !important;
            width: 400px !important;
          }
        </style>

      </html>      
    </panel>
  </row>
</form>
____________________________________________
| makeresults | eval message= "Happy Splunking!!!"
0 Karma

jaj
Path Finder

@niketnilay so awesome! thank you

0 Karma

niketnilay
Legend

Which version of splunk are you on?

____________________________________________
| makeresults | eval message= "Happy Splunking!!!"
0 Karma
Get Updates on the Splunk Community!

Improve Your Security Posture

Watch NowImprove Your Security PostureCustomers are at the center of everything we do at Splunk and security ...

Maximize the Value from Microsoft Defender with Splunk

 Watch NowJoin Splunk and Sens Consulting for this Security Edition Tech TalkWho should attend:  Security ...

This Week's Community Digest - Splunk Community Happenings [6.27.22]

Get the latest news and updates from the Splunk Community here! News From Splunk Answers ✍️ Splunk Answers is ...