What should be simple tab select...
I'm feeling utterly stupid that I cannot resolve my simple tab switchers located to the right-hand side of my page. Ordering it into the correct order, somewhat working then not then again... I keep going round in circles and it should be simple.
- On click - Users OR Alerts
- Remove all active classes
- Set active class on clicked
- On click - More
- Set active class WITHOUT toggling any others.
- Show drop menu
- Select Option
- Remove all active classes
- Set active class on clicked & 'MORE'
- Click outside / Other tab
- Remove active class on More
- Hide drop down.
- $('.Quick-Sidebar .nav-tabs li').click(function(e) {
- if (!$(this).hasClass('active')) {
- if (!$(this).hasClass('dropdown')) {
- $('.Quick-Sidebar .nav-tabs li').removeClass('active');
- $(this).addClass('active');
- }
- }
- if ($(this).hasClass('dropdown')) {
- $(this).toggleClass('active');
- $('.dropdown-menu').toggle();
- }
- });