Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/hnhdigital-os/jquery-sticky-bootstrap-tabs
This component extends bootstrap-tabs default behaviour to remember the selected tab across page reloads by using the location.hash. This also allows linking to a specific tab.
https://github.com/hnhdigital-os/jquery-sticky-bootstrap-tabs
Last synced: about 7 hours ago
JSON representation
This component extends bootstrap-tabs default behaviour to remember the selected tab across page reloads by using the location.hash. This also allows linking to a specific tab.
- Host: GitHub
- URL: https://github.com/hnhdigital-os/jquery-sticky-bootstrap-tabs
- Owner: hnhdigital-os
- License: mit
- Created: 2016-08-10T14:13:56.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2018-08-24T12:07:27.000Z (over 6 years ago)
- Last Synced: 2025-01-10T12:23:59.265Z (12 days ago)
- Language: HTML
- Size: 10.7 KB
- Stars: 1
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
jquery-sticky-bootstrap-tabs
=================
[![npm version](https://badge.fury.io/js/jquery-sticky-bootstrap-tabs.svg)](https://badge.fury.io/js/jquery-sticky-bootstrap-tabs)Provides pushState (back and forward button support) to Bootstrap tabs
Install
=======
NPM
---
type `npm install jquery-sticky-bootstrap-tabs --save` to install the library via NPMBower
-----
type `bower install jquery-sticky-bootstrap-tabs --save` to install the library via bowerUsage
=====Run this in document ready or some equivalent initializer on your page:
$('.nav-tabs').stickyTabs();
Where `nav-tabs` is the default class for the bootstrap tabs feature.
Options
=======The following options are available to pass to jquery-sticky-bootstrap-tabs on instantiation
**Example**
````javascript
$(function() {
var options = {
selectorAttribute: "data-target",
backToTop: true
};
$('.nav-tabs').stickyTabs( options );
});
````|option|default|description|
|------|-------|-----------|
| selectorAttribute | false | Override the default `href` attribute used as selector when you need to activate multiple TabPanels at once with a single Tab using the `data-target` attribute. |
| backToTop |false | Prevent the page from jumping down to the tab content by setting the backToTop setting to true. |
| showParentTabs |false | Show the parent tabs so the selected tab comes into view if it is part of another tab grouping. |
| showTabUsingClickTrigger |false | Activate the requeted tab using the click trigger so that any behaviours on the click trigger are activated. |