1.0.19 • Published 12 months ago

svelte-page-tab v1.0.19

Weekly downloads
-
License
MIT
Repository
github
Last release
12 months 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.19

12 months ago

1.0.18

1 year ago

1.0.17

1 year ago

1.0.16

1 year ago

1.0.15

1 year ago

1.0.14

1 year ago

1.0.13

1 year ago

1.0.12

1 year ago

1.0.11

1 year ago

1.0.10

1 year ago

1.0.9

1 year ago

1.0.8

1 year ago

1.0.7

1 year ago

1.0.6

1 year ago

1.0.5

1 year ago

1.0.4

1 year ago

1.0.3

2 years ago

1.0.2

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago

0.3.0

2 years ago

0.2.0

2 years ago

0.1.0

2 years ago

0.0.1

2 years ago