WeCodePixels / theia-sticky-sidebar

Glues your website's sidebars, making them permanently visible while scrolling.
MIT License
569 stars 209 forks source link

Removed inline style for cartain cases. #27

Closed tomothumb closed 7 years ago

tomothumb commented 8 years ago

On responsive website, sometimes, sidebar elements will be fixed content, like using off-canvas layout navigation. This mobile style will be like this,

.sidebar {
  position:fixed;
}
@mdeia ~~~~~~{
  /*Mobile*/
  .sidebar {
    position:fixed;
  }
}

I think those inline styles for setting (like "border-box", "overflow" ) should be moved into style.css and toggle class by some trigger. Or reset proper initial styles.

I removed a style "position:relative" from javascript code anyway.

liviucmg commented 7 years ago

Good news, you can now solve this by overriding the defaultPosition option in v1.7.0.