Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

All tabs being hidden when script loads in? #29

Open
chopfitzroy opened this issue Sep 25, 2015 · 2 comments
Open

All tabs being hidden when script loads in? #29

chopfitzroy opened this issue Sep 25, 2015 · 2 comments
Labels

Comments

@chopfitzroy
Copy link

All tabs being hidden when script loads in?

            <div class="row">
                <div class="tabs" data-toggle="tabslet" data-animation="true">
                    <div class="col-md-12">
                        <ul class="list-unstyled list-inline">
                            <li class="active"><a href="#tab-1">Public</a></li>
                            <li class=""><a href="#tab-2">Private</a></li>
                            <li class=""><a href="#tab-3">Popular</a></li>
                            <li class=""><a href="#tab-4">Trending</a></li>
                            <li class=""><a href="#tab-5">New</a></li>
                        </ul>
                    </div>
                    <div id="tab-1">
                        <div class="row">
                            {{#loop 3}}
                                <div class="col-md-4">
                                    <div class="card">
                                        <div class="card-header">
                                            <div class="row">
                                                <div class="col-md-12">
                                                    Title
                                                </div>
                                            </div>
                                        </div>
                                        <div class="card-block">
                                            <div class="row">
                                                <div class="col-md-12">
                                                    Icon / Iframe
                                                </div>
                                            </div>
                                        </div>
                                        <div class="card-footer">
                                            <div class="row">
                                                <div class="col-md-12">
                                                    Info
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                            {{/loop}}
                        </div>
                    </div>
                    <div id="tab-2">
                        <div class="row">
                            {{#loop 3}}
                                <div class="col-md-4">
                                    <div class="card">
                                        <div class="card-header">
                                            <div class="row">
                                                <div class="col-md-12">
                                                    Title
                                                </div>
                                            </div>
                                        </div>
                                        <div class="card-block">
                                            <div class="row">
                                                <div class="col-md-12">
                                                    Icon / Iframe
                                                </div>
                                            </div>
                                        </div>
                                        <div class="card-footer">
                                            <div class="row">
                                                <div class="col-md-12">
                                                    Info
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                            {{/loop}}
                        </div>
                    </div>
                    <div id="tab-3">
                        <div class="row">
                            <p>View not available</p>
                        </div>
                    </div>
                    <div id="tab-4">
                        <div class="row">
                            <p>View not available</p>
                        </div>
                    </div>
                    <div id="tab-5">
                        <div class="row">
                            <p>View not available</p>
                        </div>
                    </div>
                </div>

            </div>
$(window).on('ready', function(){
    $('.tabs').tabslet({
        mouseevent: 'click',
        attribute: 'href',
        animation: true
    });
});
@vdw
Copy link
Owner

vdw commented Sep 26, 2015

Tabslet hides the tabs on initialization and then activates the first one or the one set from the options or the browser link.

(comment on the code above: you can use one method to initialize Tabslet... either with javascript or with data attributes... the code above uses both ways.)

@chopfitzroy
Copy link
Author

Having removed the javascript and just using the data- attributes it is still hiding all items, if I navigate to the url with # appended it still hides all tabs.

Cheers.

@vdw vdw added the question label Sep 28, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants