<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: How to hold the table header, when using splunk JS. in Splunk Enterprise</title>
    <link>https://community.splunk.com/t5/Splunk-Enterprise/How-to-hold-the-table-header-when-using-Splunk-JS/m-p/608340#M13540</link>
    <description>&lt;P&gt;To be honest, I haven't played with Splunk JS and am not experienced in javascript either. I'm no help lol. Nonetheless, I've reposted this in the &lt;A href="https://docs.splunk.com/Documentation/Community/current/community/Chat" target="_self"&gt;#appdev&lt;/A&gt; channel for Splunk User Groups and have asked some other folks internally to look at this.&lt;/P&gt;&lt;P&gt;It sounds like when the page scrolls the header scrolls as well and you want it to stay fixed on the screen. I'm no javascript developer but maybe there is a general (not Splunk) javascript way of doing that? As in, is this a Splunk question or a general javascript question for which more javascript forums could also yield help?&lt;/P&gt;&lt;P&gt;I also wonder if the solution is now recommended through &lt;A href="https://splunkui.splunk.com/" target="_self"&gt;SplunkUI&lt;/A&gt; rather than Splunk JS.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 04 Aug 2022 20:02:30 GMT</pubDate>
    <dc:creator>sloshburch</dc:creator>
    <dc:date>2022-08-04T20:02:30Z</dc:date>
    <item>
      <title>How to hold the table header when using Splunk JS?</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/How-to-hold-the-table-header-when-using-Splunk-JS/m-p/607024#M13450</link>
      <description>&lt;P&gt;We are working on a table creation, where in we are just passing the SPL query to the splunk JS, which populates the table in the UI.&lt;/P&gt;
&lt;P&gt;&amp;gt;My problem is that im not able to hold the table headers ,when scrolled it ,it does not stay.&lt;/P&gt;
&lt;P&gt;&amp;gt;Also if I scroll horizontally I have to go all the way to the end of the table layout to scroll horizontally.&lt;/P&gt;
&lt;P&gt;Any help or suggestion will help greatly.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;Jabez.&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="jabezds_0-1658834630613.png" style="width: 400px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/20686iF228B0EAA7ACEF24/image-size/medium?v=v2&amp;amp;px=400" role="button" title="jabezds_0-1658834630613.png" alt="jabezds_0-1658834630613.png" /&gt;&lt;/span&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="jabezds_1-1658834677596.png" style="width: 400px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/20687i9AB6160E6E03049C/image-size/medium?v=v2&amp;amp;px=400" role="button" title="jabezds_1-1658834677596.png" alt="jabezds_1-1658834677596.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 15 Aug 2022 22:02:24 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/How-to-hold-the-table-header-when-using-Splunk-JS/m-p/607024#M13450</guid>
      <dc:creator>jabezds</dc:creator>
      <dc:date>2022-08-15T22:02:24Z</dc:date>
    </item>
    <item>
      <title>Re: How to hold the table header, when using splunk JS.</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/How-to-hold-the-table-header-when-using-Splunk-JS/m-p/608340#M13540</link>
      <description>&lt;P&gt;To be honest, I haven't played with Splunk JS and am not experienced in javascript either. I'm no help lol. Nonetheless, I've reposted this in the &lt;A href="https://docs.splunk.com/Documentation/Community/current/community/Chat" target="_self"&gt;#appdev&lt;/A&gt; channel for Splunk User Groups and have asked some other folks internally to look at this.&lt;/P&gt;&lt;P&gt;It sounds like when the page scrolls the header scrolls as well and you want it to stay fixed on the screen. I'm no javascript developer but maybe there is a general (not Splunk) javascript way of doing that? As in, is this a Splunk question or a general javascript question for which more javascript forums could also yield help?&lt;/P&gt;&lt;P&gt;I also wonder if the solution is now recommended through &lt;A href="https://splunkui.splunk.com/" target="_self"&gt;SplunkUI&lt;/A&gt; rather than Splunk JS.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 04 Aug 2022 20:02:30 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/How-to-hold-the-table-header-when-using-Splunk-JS/m-p/608340#M13540</guid>
      <dc:creator>sloshburch</dc:creator>
      <dc:date>2022-08-04T20:02:30Z</dc:date>
    </item>
    <item>
      <title>Re: How to hold the table header, when using splunk JS.</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/How-to-hold-the-table-header-when-using-Splunk-JS/m-p/608341#M13541</link>
      <description>&lt;P&gt;&lt;SPAN&gt;Have you tried utilizing sticky positioning with some CSS?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A class="" href="https://stackoverflow.com/questions/8423768/freeze-the-top-row-for-an-html-table-only-fixed-table-header-scrolling" target="_blank" rel="noopener noreferrer"&gt;https://stackoverflow.com/questions/8423768/freeze-the-top-row-for-an-html-table-only-fixed-table-header-scrolling&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A class="" href="https://developer.mozilla.org/en-US/docs/Web/CSS/position#sticky_positioning" target="_blank" rel="noopener noreferrer"&gt;https://developer.mozilla.org/en-US/docs/Web/CSS/position#sticky_positioning&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 04 Aug 2022 20:05:46 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/How-to-hold-the-table-header-when-using-Splunk-JS/m-p/608341#M13541</guid>
      <dc:creator>splunkian</dc:creator>
      <dc:date>2022-08-04T20:05:46Z</dc:date>
    </item>
    <item>
      <title>Re: How to hold the table header, when using splunk JS.</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/How-to-hold-the-table-header-when-using-Splunk-JS/m-p/608789#M13577</link>
      <description>&lt;P&gt;Thanks,&amp;nbsp;&lt;/P&gt;&lt;P&gt;we tried various approaches, but this one worked for us.&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;--&amp;gt;Override the splunk table CSS , with the below code change. Make sure to change the data view path according to your table&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;#incidents_hash div [data-view="YOUR_DATA_VIEW_PATH"]{&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;overflow-y: auto !important;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;height: 300px !important;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;}&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;#incidents_hash div [data-view="YOUR_DATA_VIEW_PATH"] table{&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;border-collapse: collapse !important;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;width: 10px !important;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;}&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;#incidents_hash div [data-view="YOUR_DATA_VIEW_PATH"] th {&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;position: sticky !important;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;text-align: left !important;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;top: 0 !important;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;}&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 09 Aug 2022 07:28:43 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/How-to-hold-the-table-header-when-using-Splunk-JS/m-p/608789#M13577</guid>
      <dc:creator>jabezds</dc:creator>
      <dc:date>2022-08-09T07:28:43Z</dc:date>
    </item>
    <item>
      <title>Re: How to hold the table header, when using splunk JS?</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/How-to-hold-the-table-header-when-using-Splunk-JS/m-p/609021#M13595</link>
      <description>&lt;P&gt;Can I ask what app this is for? Much like&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/27103"&gt;@sloshburch&lt;/a&gt;&amp;nbsp;mentioned, I would recommend looking into the &lt;A href="https://splunkui.splunk.com/" target="_self"&gt;Splunk UI Toolkit&lt;/A&gt;. As part of that Toolkit, we have actively developed React Components that can be used inside of a React app in Splunk.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Here is a link to our Table Component:&amp;nbsp;&lt;A href="https://splunkui.splunk.com/Packages/react-ui/Table" target="_blank"&gt;https://splunkui.splunk.com/Packages/react-ui/Table&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Here is a Code Sandbox showing how you would set a table header to "fixed"&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;A href="https://codesandbox.io/s/7xqj28?file=/demo.jsx" target="_self"&gt;https://codesandbox.io/s/7xqj28?file=/demo.jsx&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 10 Aug 2022 13:53:17 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/How-to-hold-the-table-header-when-using-Splunk-JS/m-p/609021#M13595</guid>
      <dc:creator>ryanoconnor</dc:creator>
      <dc:date>2022-08-10T13:53:17Z</dc:date>
    </item>
    <item>
      <title>Re: How to hold the table header, when using splunk JS.</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/How-to-hold-the-table-header-when-using-Splunk-JS/m-p/609538#M13644</link>
      <description>&lt;P&gt;Make sure to "Accept as Solution" (button) so others can learn from your experience. Yay!&lt;/P&gt;</description>
      <pubDate>Mon, 15 Aug 2022 22:00:28 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/How-to-hold-the-table-header-when-using-Splunk-JS/m-p/609538#M13644</guid>
      <dc:creator>sloshburch</dc:creator>
      <dc:date>2022-08-15T22:00:28Z</dc:date>
    </item>
  </channel>
</rss>

