Skip to content

YcodeMan/tab

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

77 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

This toggle tab

Build Status Coverage Status

demo

demo

Started

We need to import CSS and js

<link type="text/css" href="assets/css/tab.css"rel="stylesheet" />
<script src="assets/js/tab.js" type="text/javascript" ></script>

Now, we can create a tab. We add a script to our page:

  tab({
                tabList: 5,
                curIndex: 3,
                changeMethod: 'vertical',
                mouse: 'click',
                autoPlay: false
            });

Default configuration param

  var defaultConfig = {
				tabList: 5,
				curIndex: 1,
				mouse: 'click',
				changeMethod: 'default',
				autoPlay: false
			}
  • tabList The number tab
  • curIndex Show the current tab
  • mouse mouse : click / hover click or mouseover handler
  • changeMethod changeMethod: default/vertical/horizontal/opacity The way to switch content
  • autoPlay autoPlay : false/true Is swicth by auto

About

toggle tab

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published