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

Active tab #76

Open
juanpprieto opened this issue Dec 15, 2017 · 5 comments
Open

Active tab #76

juanpprieto opened this issue Dec 15, 2017 · 5 comments

Comments

@juanpprieto
Copy link

Hey guys,

Thanks for the great work. I've been playing around with the library and got stuck trying to activate a given tab pane on load. Is there a way to do this via props or should I just use the active tab class?

Thanks!

@koppthe
Copy link
Member

koppthe commented Dec 16, 2017

sorry, i'm not very clear about your question.

You want to active custom tab via props? such like active Tab2 below?

<at-tabs>
  <at-tab-pane label="Tab1" name="name1">
    <p>Content of Tab Pane 1</p>
  </at-tab-pane>
  <at-tab-pane label="Tab2" name="name2">
    <p>Content of Tab Pane 2</p>
  </at-tab-pane>
  <at-tab-pane label="Tab3" name="name3">
    <p>Content of Tab Pane 3</p>
  </at-tab-pane>
</at-tabs>

@juanpprieto
Copy link
Author

Hi there,

Yes, I would like to know how to programatically activate a given tab.

I've seen other frameworks exposing an 'active' prop to do this.

Any tips?

@diego-lipinski-de-castro
Copy link
Contributor

diego-lipinski-de-castro commented Dec 20, 2017

Yes, it's in the docs, you can do two-way data binding by setting the v-model attribute in the at-tabs with the value of the name of one of the at-tab-pane's that are inside it

@juanpprieto
Copy link
Author

Thanks @diego-lipinski-de-castro that worked.

@diego-lipinski-de-castro
Copy link
Contributor

This is not working anymore, what happened?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants