1.0.13 ā€¢ Published 9 days ago

svelte-page-tab v1.0.13

Weekly downloads
-
License
MIT
Repository
github
Last release
9 days ago

svelte-page-tab

šŸŽ¹ Tab menu component that uses page as a state

Demo

Installation

npm i svelte-page-tab

Usage

<script>
  import { TabItems } from 'svelte-page-tab'
</script>

<ul>
  <TabItems
    prefix={/* path prefix (optional) */}
    routes={new Map([
      // [path, label]
      ['/', 'Top'],
      ['/page1', 'Page 1'],
      ['/page2', 'Page 2'],
      ['/page3', 'Page 3']
    ])}
  />
</ul>

<style>
  ul {
    /* list styles */
  }
  ul :global(li) {
    /* list item styles */
  }
  ul :global(a) {
    /* list item link styles */
  }
  ul :global(a[data-current-location]) {
    /* list item link (current location) styles */
  }
</style>

License

MIT

1.0.13

9 days ago

1.0.12

21 days ago

1.0.11

29 days ago

1.0.10

1 month ago

1.0.9

2 months ago

1.0.8

2 months ago

1.0.7

3 months ago

1.0.6

3 months ago

1.0.5

3 months ago

1.0.4

4 months ago

1.0.3

4 months ago

1.0.2

4 months ago

1.0.1

5 months ago

1.0.0

5 months ago

0.3.0

5 months ago

0.2.0

5 months ago

0.1.0

5 months ago

0.0.1

5 months ago