flowbite-svelte 0.13.6 → 0.13.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -2,6 +2,13 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ### [0.13.7](https://github.com/shinokada/flowbite-svelte/compare/v0.13.6...v0.13.7) (2022-04-13)
6
+
7
+
8
+ ### Bug Fixes
9
+
10
+ * remove SvelteKit app/stores page and session from Navbar ([09428df](https://github.com/shinokada/flowbite-svelte/commit/09428df9f46b16b07595ed16c08697c61c0099a5))
11
+
5
12
  ### [0.13.6](https://github.com/shinokada/flowbite-svelte/compare/v0.13.5...v0.13.6) (2022-04-13)
6
13
 
7
14
 
@@ -1,4 +1,10 @@
1
- <script >import { page, session } from '$app/stores';
1
+ <script >import { onMount } from 'svelte';
2
+ export let user = '';
3
+ let pathname = '';
4
+ onMount(() => {
5
+ pathname = window.location.pathname;
6
+ // console.log('pathname', pathname);
7
+ });
2
8
  export let siteName = 'Svelte Flow';
3
9
  export let logo = '/images/flowbite-svelte-logo-30.png';
4
10
  export let alt = 'Svelte Flow';
@@ -30,11 +36,11 @@ export let liLinkClass = `block py-2 pr-4 pl-3 text-gray-700 border-b border-gr
30
36
  <ul class="flex flex-col mt-4 md:flex-row md:space-x-8 md:mt-0 md:text-sm md:font-medium">
31
37
  {#each menus as { name, href, rel }}
32
38
  <li>
33
- <a class:active={$page.url.pathname === href} {href} {rel} class={liLinkClass}>{name}</a>
39
+ <a class:active={pathname === href} {href} {rel} class={liLinkClass}>{name}</a>
34
40
  </li>
35
41
  {/each}
36
42
  </ul>
37
- {#if $session['user']}
43
+ {#if user}
38
44
  <slot name="user" />
39
45
  {/if}
40
46
  </div>
@@ -2,6 +2,7 @@ import { SvelteComponentTyped } from "svelte";
2
2
  import type { LinkType } from '../types';
3
3
  declare const __propDef: {
4
4
  props: {
5
+ user?: string;
5
6
  siteName?: string;
6
7
  logo?: string;
7
8
  alt?: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "flowbite-svelte",
3
- "version": "0.13.6",
3
+ "version": "0.13.7",
4
4
  "description": "Flowbite components for Svelte",
5
5
  "main": "./package/index.js",
6
6
  "author": {