Bootstrap Tabs
Nova uses Bootstrap’s tab JavaScript plugin.
How to use?
Wrap any block in a parent element with an ID or class and add the same ID in the JS init function of the hs.bs-tabs.js
plugin.
Copy-paste the following <script>
near the end of your pages under JS Nova to enable it.
Copy-paste the init function under JS Plugins Init., before the closing </body>
tag, to enable it.
Dropdown example
Shrink down the resolution of your device to see the how it lines up on small resolutions.
Accordion example
Shrink down the resolution of your device to see the how it lines up on small resolutions.
Methods
Options can be passed via data attributes or JavaScript. For data attributes, append the option name to data-
, as in data-tabs-mobile-type=""
.
Attribute | Description |
---|---|
|
determines the type of tabs on resolution less than 768px. Admissable significances are: slide-up-down | accordion
|
|
if data-tabs-mobile-type = "slide-up-down" or data-tabs-mobile-type = "accordion", then it accepts classes for styling buttons on mobile resolution. |
|
indicates below what resolution the tabs will be transformed in the dropdown. |
|
data-target ID block with tabs. |