orxapi.plugins.tabs
The tabulation plugin library for orxapi.
Getting Started
If you haven't used NodeJs before, be sure to have install the LTS version on your desktop ! Check your version with this command:
node -vv10.15.1
Installation
npm install orxapi.plugins.tabs --save
dependencies
Usage
This library is written in TypeScript, but you can use JavaScript.
Warning version 2 vs 1
This is the version 2, the initialization has changed and not compatible with version 1. See below for more detail.
Direct download
Download the script here and include it (unless you are packaging scripts somehow else):
Standalone: You can use the standalone version into bundle directory. The bundle contains a minimized version of the tabs plugins with a Fuse Box Quantum API.
Min: If you want use other orxapi tools or plugins choose the min bundle and add external api.
...
Package Managers
Plugins Tabs supports npm under the name "orxapi.plugins.tabs".
TypeScript code
;; // Create tabs from content; // Select the third tabulation;;console.log"default selected tab: ", selectTabs_1;/// -> default selected tab: 2 // Custom tabs; // Select the third tabulation;tabsCustom_1.selectTab3;
HTML code
<!-- CREATE TABS FROM CONTENT --> info ... description ... details ... <!-- CUSTOM TAB --> info description details ... ... ...
LESS code
// LOGIC .tab-content display: none; &.selected display: block;
Methods
TabsManager()
- add Add a new tabs into TabsMap
- remove Remove a specific tabs into TabsMap
- getTabsMap Getting the tabs map
- getOptions Getting the options initialized
Tabs()
- selectTab Change the selected tab
- disabled Get / Set disabled tab
- selected Get the selected tab
See docs for more information
This library was designed to work with ES 5+
TODO
- Add multi instance compatibility
- Add examples
- Add unit tests
- Add functional tests
- Add documentation of the optional parameters
- Improve the documentation