Skip to content

jQuery plugin to add a table scroll button to a wide table inside a scrollable container.

Notifications You must be signed in to change notification settings

Coufu/table-scroll-button

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 

Repository files navigation

Table Scroll Button

Tired of coding a custom table scroll buttons every time you need them? Use this feature-rich plugin which requires only one line of code!

Usage

HTML

<div class="table--scroll-wrapper">
    <table>
        <!-- Put huge table here -->
    </table>
</div>

JS

$('table').tableScrollButton();

or

$('.table--scroll-wrapper table').tableScrollButton();

Features

  • Shows/hides only if the table is wider than its container (even on window resize)
  • Clicking it scrolls the table to the right exactly one width of the container.
  • The button hides (via css class) when you can't scroll any further
  • Vertical placement is based on table height or screen height (whichever is smaller)

To Do

  • Add basic CSS
  • Minify JS
  • Structure repo with package.json and gulpfile.js to continue development
  • Add example HTML file
  • Handle potential performance issues when resizing window

About

jQuery plugin to add a table scroll button to a wide table inside a scrollable container.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published