Let Me Tink About It
Let Me Tink About It

Reputation: 16102

Polymer 1.0: Where is a working example of <paper-tabs> to control content?

Background

Question

Can someone please point to an example showing how <paper-tabs> can be used to control the display of content?

Upvotes: 2

Views: 2423

Answers (1)

Ricky
Ricky

Reputation: 1009

It's in the docs of the first link:

A common usage for paper-tabs is to use it along with iron-pages to switch between different views.

<paper-tabs selected="{{selected}}">
  <paper-tab>Tab 1</paper-tab>
  <paper-tab>Tab 2</paper-tab>
  <paper-tab>Tab 3</paper-tab>
</paper-tabs>

<iron-pages selected="{{selected}}">
  <div>Page 1</div>
  <div>Page 2</div>
  <div>Page 3</div>
</iron-pages>

Upvotes: 8

Related Questions