Jump to content

  • You cannot start a new topic
  • You cannot reply to this topic

Make Top Panel Floating Rate Topic   - - - - -

 
  • Darius
  • Douchebag
  • Members
  • Join Date: 20-Apr 08
  • 3176 posts

Posted 03 May 2018 - 05:32 AM #1

Howdy,

 

whats the proper way of making top panel in layouts floating like in admin panel.

 

In admin panel it has css

 

position: fixed;
top: 37px;

 

is there more to this? Thank you



 
  • straygecko
  • Advanced Member
  • Members
  • Join Date: 01-May 13
  • 92 posts

Posted 03 May 2018 - 06:52 PM #2

You need a little bit more. From the doc on microformats https://docs.cs-cart...croformats.html

cm-sticky-scroll - fixes a block in which it is used. In data-ce-top the distance scrolled from the upper end of the page till a block is fixed is specified. In data-ce-padding the distanse from the upper end of the screen to the fixed block is specified.

Format:

<div class="subnav cm-sticky-scroll" data-ce-top="100" data-ce-padding="20" >

When the window is crolled down for 100px, the panel will be fixed at the distanse of 20px from its upper end.

 
  • Darius
  • Douchebag
  • Members
  • Join Date: 20-Apr 08
  • 3176 posts

Posted 04 May 2018 - 05:24 AM #3

Thank you for you input!

 

You need a little bit more. From the doc on microformats https://docs.cs-cart...croformats.html

cm-sticky-scroll - fixes a block in which it is used. In data-ce-top the distance scrolled from the upper end of the page till a block is fixed is specified. In data-ce-padding the distanse from the upper end of the screen to the fixed block is specified.

Format:

<div class="subnav cm-sticky-scroll" data-ce-top="100" data-ce-padding="20" >

When the window is crolled down for 100px, the panel will be fixed at the distanse of 20px from its upper end.