flowbite-svelte 0.38.2 → 0.38.3
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/dist/accordion/Accordion.svelte +4 -4
- package/dist/accordion/Accordion.svelte.d.ts +8 -4
- package/dist/accordion/Accordion.svelte.d.ts.map +1 -1
- package/dist/accordion/AccordionItem.svelte +18 -5
- package/dist/accordion/AccordionItem.svelte.d.ts +6 -4
- package/dist/accordion/AccordionItem.svelte.d.ts.map +1 -1
- package/dist/avatar/Avatar.svelte +1 -1
- package/dist/avatar/Placeholder.svelte +4 -6
- package/dist/avatar/Placeholder.svelte.d.ts +1 -0
- package/dist/avatar/Placeholder.svelte.d.ts.map +1 -1
- package/dist/badges/Badge.svelte.d.ts +1 -1
- package/dist/badges/Badge.svelte.d.ts.map +1 -1
- package/dist/bottom-nav/BottomNav.svelte +6 -0
- package/dist/bottom-nav/BottomNav.svelte.d.ts +4 -0
- package/dist/bottom-nav/BottomNav.svelte.d.ts.map +1 -1
- package/dist/bottom-nav/BottomNavItem.svelte +7 -2
- package/dist/bottom-nav/BottomNavItem.svelte.d.ts +2 -0
- package/dist/bottom-nav/BottomNavItem.svelte.d.ts.map +1 -1
- package/dist/buttons/Button.svelte +8 -11
- package/dist/buttons/Button.svelte.d.ts +0 -1
- package/dist/buttons/Button.svelte.d.ts.map +1 -1
- package/dist/device-mockup/DeviceMockup.svelte +1 -1
- package/dist/navbar/Navbar.svelte +1 -2
- package/dist/navbar/Navbar.svelte.d.ts +1 -0
- package/dist/navbar/Navbar.svelte.d.ts.map +1 -1
- package/dist/typography/A.svelte +1 -1
- package/dist/typography/A.svelte.d.ts +2 -0
- package/dist/typography/A.svelte.d.ts.map +1 -1
- package/dist/utils/ChevronUp.svelte +1 -1
- package/package.json +6 -10
- package/dist/navbar/NavDropdown.svelte +0 -103
- package/dist/navbar/NavDropdown.svelte.d.ts +0 -85
- package/dist/navbar/NavDropdown.svelte.d.ts.map +0 -1
|
@@ -6,13 +6,13 @@ import { twMerge } from 'tailwind-merge';
|
|
|
6
6
|
import { setContext } from 'svelte';
|
|
7
7
|
export let multiple = false;
|
|
8
8
|
export let flush = false;
|
|
9
|
-
export let
|
|
10
|
-
export let
|
|
9
|
+
export let activeClass = 'bg-gray-100 dark:bg-gray-800 text-gray-900 dark:text-white focus:ring-4 focus:ring-gray-200 dark:focus:ring-gray-800';
|
|
10
|
+
export let inactiveClass = 'text-gray-500 dark:text-gray-400 hover:bg-gray-100 hover:dark:bg-gray-800';
|
|
11
11
|
export let defaultClass = 'text-gray-500 dark:text-gray-400';
|
|
12
12
|
const ctx = {
|
|
13
13
|
flush,
|
|
14
|
-
|
|
15
|
-
|
|
14
|
+
activeClass: twMerge(activeClass, $$props.classActive),
|
|
15
|
+
inactiveClass: twMerge(inactiveClass, $$props.classInactive),
|
|
16
16
|
selected: multiple ? undefined : writable()
|
|
17
17
|
};
|
|
18
18
|
setContext('ctx', ctx);
|
|
@@ -2,9 +2,11 @@ import { SvelteComponentTyped } from "svelte";
|
|
|
2
2
|
import { type Writable } from 'svelte/store';
|
|
3
3
|
export interface AccordionCtxType {
|
|
4
4
|
flush: boolean;
|
|
5
|
-
|
|
6
|
-
|
|
5
|
+
activeClass: string;
|
|
6
|
+
inactiveClass: string;
|
|
7
7
|
selected?: Writable<object>;
|
|
8
|
+
classActive?: string;
|
|
9
|
+
classInactive?: string;
|
|
8
10
|
}
|
|
9
11
|
declare const __propDef: {
|
|
10
12
|
props: {
|
|
@@ -251,9 +253,11 @@ declare const __propDef: {
|
|
|
251
253
|
options?: object | undefined;
|
|
252
254
|
multiple?: boolean | undefined;
|
|
253
255
|
flush?: boolean | undefined;
|
|
254
|
-
|
|
255
|
-
|
|
256
|
+
activeClass?: string | undefined;
|
|
257
|
+
inactiveClass?: string | undefined;
|
|
256
258
|
defaultClass?: string | undefined;
|
|
259
|
+
classActive?: string | undefined;
|
|
260
|
+
classInactive?: string | undefined;
|
|
257
261
|
};
|
|
258
262
|
events: {
|
|
259
263
|
[evt: string]: CustomEvent<any>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Accordion.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/accordion/Accordion.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;AACC,OAAO,EAAY,KAAK,QAAQ,EAAE,MAAM,cAAc,CAAC;AAEvD,MAAM,WAAW,gBAAgB;IAC/B,KAAK,EAAE,OAAO,CAAC;IACf,
|
|
1
|
+
{"version":3,"file":"Accordion.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/accordion/Accordion.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;AACC,OAAO,EAAY,KAAK,QAAQ,EAAE,MAAM,cAAc,CAAC;AAEvD,MAAM,WAAW,gBAAgB;IAC/B,KAAK,EAAE,OAAO,CAAC;IACf,WAAW,EAAE,MAAM,CAAC;IACpB,aAAa,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,EAAE,QAAQ,CAAC,MAAM,CAAC,CAAC;IAC5B,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AAoDH,QAAA,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAAwC,CAAC;AACxD,MAAM,MAAM,cAAc,GAAG,OAAO,SAAS,CAAC,KAAK,CAAC;AACpD,MAAM,MAAM,eAAe,GAAG,OAAO,SAAS,CAAC,MAAM,CAAC;AACtD,MAAM,MAAM,cAAc,GAAG,OAAO,SAAS,CAAC,KAAK,CAAC;AAEpD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkCG;AACH,MAAM,CAAC,OAAO,OAAO,SAAU,SAAQ,oBAAoB,CAAC,cAAc,EAAE,eAAe,EAAE,cAAc,CAAC;CAC3G"}
|
|
@@ -5,8 +5,8 @@ import { getContext, onMount } from 'svelte';
|
|
|
5
5
|
import { writable } from 'svelte/store';
|
|
6
6
|
import { fade, blur, fly, slide } from 'svelte/transition';
|
|
7
7
|
export let open = false;
|
|
8
|
-
export let
|
|
9
|
-
export let
|
|
8
|
+
export let activeClass = undefined;
|
|
9
|
+
export let inactiveClass = undefined;
|
|
10
10
|
export let defaultClass = 'flex items-center justify-between w-full font-medium text-left group-first:rounded-t-xl border-gray-200 dark:border-gray-700';
|
|
11
11
|
export let transitionType = 'slide';
|
|
12
12
|
export let transitionParams = {};
|
|
@@ -18,6 +18,10 @@ export let borderClass = 'border-l border-r group-first:border-t';
|
|
|
18
18
|
export let borderOpenClass = 'border-l border-r';
|
|
19
19
|
export let borderBottomClass = 'border-b';
|
|
20
20
|
export let borderSharedClass = 'border-gray-200 dark:border-gray-700';
|
|
21
|
+
export let classActive = undefined;
|
|
22
|
+
export let classInactive = undefined;
|
|
23
|
+
let activeCls = twMerge(activeClass, classActive);
|
|
24
|
+
let inactiveCls = twMerge(inactiveClass, classInactive);
|
|
21
25
|
// make a custom transition function that returns the desired transition
|
|
22
26
|
const multiple = (node, params) => {
|
|
23
27
|
switch (transitionType) {
|
|
@@ -45,7 +49,16 @@ onMount(() => {
|
|
|
45
49
|
});
|
|
46
50
|
const handleToggle = (_) => selected.set(open ? {} : self);
|
|
47
51
|
let buttonClass;
|
|
48
|
-
$: buttonClass = twMerge(
|
|
52
|
+
$: buttonClass = twMerge([
|
|
53
|
+
defaultClass,
|
|
54
|
+
ctx.flush || borderClass,
|
|
55
|
+
borderBottomClass,
|
|
56
|
+
borderSharedClass,
|
|
57
|
+
ctx.flush ? paddingFlush : paddingDefault,
|
|
58
|
+
open && (ctx.flush ? textFlushOpen : activeCls || ctx.activeClass),
|
|
59
|
+
!open && (ctx.flush ? textFlushDefault : inactiveCls || ctx.inactiveClass),
|
|
60
|
+
$$props.class
|
|
61
|
+
]);
|
|
49
62
|
</script>
|
|
50
63
|
|
|
51
64
|
<h2 class="group">
|
|
@@ -82,8 +95,8 @@ $: buttonClass = twMerge(defaultClass, ctx.flush || borderClass, borderBottomCla
|
|
|
82
95
|
|
|
83
96
|
## Props
|
|
84
97
|
@prop open: boolean = false;
|
|
85
|
-
@prop
|
|
86
|
-
@prop
|
|
98
|
+
@prop activeClass: string | undefined = undefined;
|
|
99
|
+
@prop inactiveClass: string | undefined = undefined;
|
|
87
100
|
@prop defaultClass: string = 'flex items-center justify-between w-full font-medium text-left group-first:rounded-t-xl border-gray-200 dark:border-gray-700';
|
|
88
101
|
@prop transitionType: TransitionTypes = 'slide';
|
|
89
102
|
@prop transitionParams: TransitionParamTypes = {};
|
|
@@ -4,8 +4,8 @@ declare const __propDef: {
|
|
|
4
4
|
props: {
|
|
5
5
|
[x: string]: any;
|
|
6
6
|
open?: boolean | undefined;
|
|
7
|
-
|
|
8
|
-
|
|
7
|
+
activeClass?: string | undefined;
|
|
8
|
+
inactiveClass?: string | undefined;
|
|
9
9
|
defaultClass?: string | undefined;
|
|
10
10
|
transitionType?: TransitionTypes | undefined;
|
|
11
11
|
transitionParams?: TransitionParamTypes | undefined;
|
|
@@ -17,6 +17,8 @@ declare const __propDef: {
|
|
|
17
17
|
borderOpenClass?: string | undefined;
|
|
18
18
|
borderBottomClass?: string | undefined;
|
|
19
19
|
borderSharedClass?: string | undefined;
|
|
20
|
+
classActive?: string | undefined;
|
|
21
|
+
classInactive?: string | undefined;
|
|
20
22
|
};
|
|
21
23
|
events: {
|
|
22
24
|
[evt: string]: CustomEvent<any>;
|
|
@@ -43,8 +45,8 @@ export type AccordionItemSlots = typeof __propDef.slots;
|
|
|
43
45
|
*
|
|
44
46
|
* ## Props
|
|
45
47
|
* @prop open: boolean = false;
|
|
46
|
-
* @prop
|
|
47
|
-
* @prop
|
|
48
|
+
* @prop activeClass: string | undefined = undefined;
|
|
49
|
+
* @prop inactiveClass: string | undefined = undefined;
|
|
48
50
|
* @prop defaultClass: string = 'flex items-center justify-between w-full font-medium text-left group-first:rounded-t-xl border-gray-200 dark:border-gray-700';
|
|
49
51
|
* @prop transitionType: TransitionTypes = 'slide';
|
|
50
52
|
* @prop transitionParams: TransitionParamTypes = {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AccordionItem.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/accordion/AccordionItem.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;AAOD,OAAO,KAAK,EAAE,eAAe,EAAE,oBAAoB,EAAE,MAAM,UAAU,CAAC;
|
|
1
|
+
{"version":3,"file":"AccordionItem.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/accordion/AccordionItem.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;AAOD,OAAO,KAAK,EAAE,eAAe,EAAE,oBAAoB,EAAE,MAAM,UAAU,CAAC;AAwGtE,QAAA,MAAM,SAAS;;;;sBADqhB,MAAM,GAAG,SAAS;wBAAkB,MAAM,GAAG,SAAS;;;;;;;;;;;;sBAA6T,MAAM,GAAG,SAAS;wBAAkB,MAAM,GAAG,SAAS;;;;;;;;;;;CAC/3B,CAAC;AAC/E,MAAM,MAAM,kBAAkB,GAAG,OAAO,SAAS,CAAC,KAAK,CAAC;AACxD,MAAM,MAAM,mBAAmB,GAAG,OAAO,SAAS,CAAC,MAAM,CAAC;AAC1D,MAAM,MAAM,kBAAkB,GAAG,OAAO,SAAS,CAAC,KAAK,CAAC;AAExD;;;;;;;;;;;;;;;;;;;;;;;;;GAyBG;AACH,MAAM,CAAC,OAAO,OAAO,aAAc,SAAQ,oBAAoB,CAAC,kBAAkB,EAAE,mBAAmB,EAAE,kBAAkB,CAAC;CAC3H"}
|
|
@@ -30,7 +30,7 @@ $: avatarClass = twMerge(rounded ? 'rounded' : 'rounded-full', border && 'p-1 ri
|
|
|
30
30
|
{#if src}
|
|
31
31
|
<img {alt} {src} class={rounded ? 'rounded' : 'rounded-full'} />
|
|
32
32
|
{:else}
|
|
33
|
-
<slot><AvatarPlaceholder {rounded} /></slot>
|
|
33
|
+
<slot><AvatarPlaceholder {rounded} class={twMerge($$props.classPlaceholder)} /></slot>
|
|
34
34
|
{/if}
|
|
35
35
|
{#if dot}
|
|
36
36
|
<Indicator border offset={rounded} {...dot} />
|
|
@@ -1,11 +1,9 @@
|
|
|
1
|
-
<script>
|
|
1
|
+
<script>import { twMerge } from 'tailwind-merge';
|
|
2
|
+
export let rounded = false;
|
|
3
|
+
let svgClass = twMerge('text-gray-400 bg-gray-100 dark:bg-gray-600', rounded ? 'rounded' : 'rounded-full', $$props.class);
|
|
2
4
|
</script>
|
|
3
5
|
|
|
4
|
-
<svg
|
|
5
|
-
class="text-gray-400 bg-gray-100 dark:bg-gray-600 {rounded ? 'rounded' : 'rounded-full'}"
|
|
6
|
-
fill="currentColor"
|
|
7
|
-
viewBox="0 0 16 16"
|
|
8
|
-
xmlns="http://www.w3.org/2000/svg">
|
|
6
|
+
<svg class={svgClass} fill="currentColor" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
|
|
9
7
|
<path fill-rule="evenodd" d="M8 9a3 3 0 100-6 3 3 0 000 6zm-7 9a7 7 0 1114 0H3z" clip-rule="evenodd" />
|
|
10
8
|
</svg>
|
|
11
9
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Placeholder.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/avatar/Placeholder.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;
|
|
1
|
+
{"version":3,"file":"Placeholder.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/avatar/Placeholder.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;AAqBD,QAAA,MAAM,SAAS;;;;;;;;;CAA+D,CAAC;AAC/E,MAAM,MAAM,gBAAgB,GAAG,OAAO,SAAS,CAAC,KAAK,CAAC;AACtD,MAAM,MAAM,iBAAiB,GAAG,OAAO,SAAS,CAAC,MAAM,CAAC;AACxD,MAAM,MAAM,gBAAgB,GAAG,OAAO,SAAS,CAAC,KAAK,CAAC;AAEtD;;;;GAIG;AACH,MAAM,CAAC,OAAO,OAAO,WAAY,SAAQ,oBAAoB,CAAC,gBAAgB,EAAE,iBAAiB,EAAE,gBAAgB,CAAC;CACnH"}
|
|
@@ -2,7 +2,7 @@ import { SvelteComponentTyped } from "svelte";
|
|
|
2
2
|
declare const __propDef: {
|
|
3
3
|
props: {
|
|
4
4
|
[x: string]: any;
|
|
5
|
-
color?: "red" | "yellow" | "green" | "indigo" | "purple" | "pink" | "blue" | "dark" | "none" | undefined;
|
|
5
|
+
color?: "red" | "yellow" | "green" | "indigo" | "purple" | "pink" | "blue" | "dark" | "primary" | "none" | undefined;
|
|
6
6
|
large?: boolean | undefined;
|
|
7
7
|
border?: boolean | undefined;
|
|
8
8
|
href?: string | undefined;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Badge.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/badges/Badge.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;
|
|
1
|
+
{"version":3,"file":"Badge.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/badges/Badge.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;AAqJD,QAAA,MAAM,SAAS;;;;;;eADyC,MAAM,GAAG,SAAS;;;;;;;;;;;;;;;;CACI,CAAC;AAC/E,MAAM,MAAM,UAAU,GAAG,OAAO,SAAS,CAAC,KAAK,CAAC;AAChD,MAAM,MAAM,WAAW,GAAG,OAAO,SAAS,CAAC,MAAM,CAAC;AAClD,MAAM,MAAM,UAAU,GAAG,OAAO,SAAS,CAAC,KAAK,CAAC;AAEhD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8BG;AACH,MAAM,CAAC,OAAO,OAAO,KAAM,SAAQ,oBAAoB,CAAC,UAAU,EAAE,WAAW,EAAE,UAAU,CAAC;CAC3F"}
|
|
@@ -1,10 +1,16 @@
|
|
|
1
|
+
<script context="module">export {};
|
|
2
|
+
</script>
|
|
3
|
+
|
|
1
4
|
<script>import { setContext } from 'svelte';
|
|
2
5
|
import { twMerge } from 'tailwind-merge';
|
|
3
6
|
export let position = 'fixed';
|
|
4
7
|
export let navType = 'default';
|
|
5
8
|
export let outerClass = 'w-full z-50 border-gray-200 dark:bg-gray-700 dark:border-gray-600';
|
|
6
9
|
export let innerClass = 'grid h-full max-w-lg mx-auto';
|
|
10
|
+
export let activeClass = 'text-primary-700 dark:text-primary-700 hover:text-primary-900 dark:hover:text-primary-900';
|
|
11
|
+
let activeCls = twMerge(activeClass, $$props.classActive);
|
|
7
12
|
setContext('navType', navType);
|
|
13
|
+
setContext('bottomNavType', { activeClass: activeCls });
|
|
8
14
|
const outerDivClasses = {
|
|
9
15
|
default: 'bottom-0 left-0 h-16 bg-white border-t',
|
|
10
16
|
border: 'bottom-0 left-0 h-16 bg-white border-t',
|
|
@@ -1,4 +1,7 @@
|
|
|
1
1
|
import { SvelteComponentTyped } from "svelte";
|
|
2
|
+
export type BottomNavLiType = {
|
|
3
|
+
activeClass: string;
|
|
4
|
+
};
|
|
2
5
|
declare const __propDef: {
|
|
3
6
|
props: {
|
|
4
7
|
[x: string]: any;
|
|
@@ -6,6 +9,7 @@ declare const __propDef: {
|
|
|
6
9
|
navType?: "default" | "border" | "application" | "group" | "pagination" | "card" | "meeting" | "video" | undefined;
|
|
7
10
|
outerClass?: string | undefined;
|
|
8
11
|
innerClass?: string | undefined;
|
|
12
|
+
activeClass?: string | undefined;
|
|
9
13
|
};
|
|
10
14
|
events: {
|
|
11
15
|
[evt: string]: CustomEvent<any>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BottomNav.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/bottom-nav/BottomNav.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;
|
|
1
|
+
{"version":3,"file":"BottomNav.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/bottom-nav/BottomNav.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;AACC,MAAM,MAAM,eAAe,GAAG;IAC5B,WAAW,EAAE,MAAM,CAAC;CACrB,CAAC;AA2EJ,QAAA,MAAM,SAAS;;;;;;;;;;;;;;;;CAA+D,CAAC;AAC/E,MAAM,MAAM,cAAc,GAAG,OAAO,SAAS,CAAC,KAAK,CAAC;AACpD,MAAM,MAAM,eAAe,GAAG,OAAO,SAAS,CAAC,MAAM,CAAC;AACtD,MAAM,MAAM,cAAc,GAAG,OAAO,SAAS,CAAC,KAAK,CAAC;AAEpD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8CG;AACH,MAAM,CAAC,OAAO,OAAO,SAAU,SAAQ,oBAAoB,CAAC,cAAc,EAAE,eAAe,EAAE,cAAc,CAAC;CAC3G"}
|
|
@@ -2,7 +2,10 @@
|
|
|
2
2
|
import { twMerge } from 'tailwind-merge';
|
|
3
3
|
export let btnName = '';
|
|
4
4
|
export let appBtnPosition = 'middle';
|
|
5
|
+
export let activeClass = undefined;
|
|
6
|
+
export let active = false;
|
|
5
7
|
const navType = getContext('navType');
|
|
8
|
+
const context = getContext('bottomNavType') ?? {};
|
|
6
9
|
const btnClasses = {
|
|
7
10
|
default: 'inline-flex flex-col items-center justify-center px-5 hover:bg-gray-50 dark:hover:bg-gray-800 group',
|
|
8
11
|
border: 'inline-flex flex-col items-center justify-center px-5 border-gray-200 border-x hover:bg-gray-50 dark:hover:bg-gray-800 group dark:border-gray-600',
|
|
@@ -28,8 +31,10 @@ const appBtnClasses = {
|
|
|
28
31
|
middle: 'inline-flex flex-col items-center justify-center px-5 hover:bg-gray-50 dark:hover:bg-gray-800 group',
|
|
29
32
|
right: 'inline-flex flex-col items-center justify-center px-5 rounded-r-full hover:bg-gray-50 dark:hover:bg-gray-800 group'
|
|
30
33
|
};
|
|
31
|
-
|
|
32
|
-
$:
|
|
34
|
+
let btnClass;
|
|
35
|
+
$: btnClass = twMerge(btnClasses[navType], appBtnClasses[appBtnPosition], active && (activeClass ?? context.activeClass), $$props.btnClass);
|
|
36
|
+
let spanClass;
|
|
37
|
+
$: spanClass = twMerge(spanClasses[navType], active && (activeClass ?? context.activeClass), $$props.spanClass);
|
|
33
38
|
</script>
|
|
34
39
|
|
|
35
40
|
<button
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BottomNavItem.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/bottom-nav/BottomNavItem.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;
|
|
1
|
+
{"version":3,"file":"BottomNavItem.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/bottom-nav/BottomNavItem.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;AAwFD,QAAA,MAAM,SAAS;;;;;sBADmL,MAAM,GAAG,SAAS;;;;;;;;;;;;;;;;;;CACtI,CAAC;AAC/E,MAAM,MAAM,kBAAkB,GAAG,OAAO,SAAS,CAAC,KAAK,CAAC;AACxD,MAAM,MAAM,mBAAmB,GAAG,OAAO,SAAS,CAAC,MAAM,CAAC;AAC1D,MAAM,MAAM,kBAAkB,GAAG,OAAO,SAAS,CAAC,KAAK,CAAC;AAExD;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,MAAM,CAAC,OAAO,OAAO,aAAc,SAAQ,oBAAoB,CAAC,kBAAkB,EAAE,mBAAmB,EAAE,kBAAkB,CAAC;CAC3H"}
|
|
@@ -5,7 +5,6 @@ export let pill = false;
|
|
|
5
5
|
export let outline = false;
|
|
6
6
|
export let size = group ? 'sm' : 'md';
|
|
7
7
|
export let href = undefined;
|
|
8
|
-
export let btnClass = undefined;
|
|
9
8
|
export let type = 'button';
|
|
10
9
|
export let color = group ? (outline ? 'dark' : 'alternative') : 'primary';
|
|
11
10
|
export let shadow = false;
|
|
@@ -66,16 +65,14 @@ const sizeClasses = {
|
|
|
66
65
|
};
|
|
67
66
|
const hasBorder = () => outline || color === 'alternative' || color === 'light';
|
|
68
67
|
let buttonClass;
|
|
69
|
-
$: buttonClass =
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
? (pill && 'first:rounded-l-full last:rounded-r-full') || 'first:rounded-l-lg last:rounded-r-lg'
|
|
78
|
-
: (pill && 'rounded-full') || 'rounded-lg', shadow && 'shadow-lg', shadow && coloredShadowClasses[color], $$props.disabled && 'cursor-not-allowed opacity-50', $$props.class);
|
|
68
|
+
$: buttonClass = twMerge('text-center font-medium', group ? 'focus:ring-2' : 'focus:ring-4', group && 'focus:z-10', group || 'focus:outline-none', 'inline-flex items-center justify-center ' + sizeClasses[size], outline ? outlineClasses[color] : colorClasses[color], color === 'alternative' &&
|
|
69
|
+
(group
|
|
70
|
+
? 'dark:bg-gray-700 dark:text-white dark:border-gray-700 dark:hover:border-gray-600 dark:hover:bg-gray-600'
|
|
71
|
+
: 'dark:bg-transparent dark:border-gray-600 dark:hover:border-gray-700'), outline &&
|
|
72
|
+
color === 'dark' &&
|
|
73
|
+
(group ? 'dark:text-white dark:border-white' : 'dark:text-gray-400 dark:border-gray-700'), coloredFocusClasses[color], hasBorder() && group && 'border-l-0 first:border-l', group
|
|
74
|
+
? (pill && 'first:rounded-l-full last:rounded-r-full') || 'first:rounded-l-lg last:rounded-r-lg'
|
|
75
|
+
: (pill && 'rounded-full') || 'rounded-lg', shadow && 'shadow-lg', shadow && coloredShadowClasses[color], $$props.disabled && 'cursor-not-allowed opacity-50', $$props.class);
|
|
79
76
|
</script>
|
|
80
77
|
|
|
81
78
|
<!-- svelte-ignore a11y-click-events-have-key-events -->
|
|
@@ -7,7 +7,6 @@ declare const __propDef: {
|
|
|
7
7
|
outline?: boolean | undefined;
|
|
8
8
|
size?: "xs" | "sm" | "lg" | "xl" | "md" | undefined;
|
|
9
9
|
href?: string | undefined;
|
|
10
|
-
btnClass?: string | undefined;
|
|
11
10
|
type?: ButtonType | undefined;
|
|
12
11
|
color?: "red" | "yellow" | "green" | "purple" | "blue" | "light" | "dark" | "primary" | "none" | "alternative" | undefined;
|
|
13
12
|
shadow?: boolean | undefined;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Button.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/buttons/Button.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;AAGD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,UAAU,CAAC;
|
|
1
|
+
{"version":3,"file":"Button.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/buttons/Button.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;AAGD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,UAAU,CAAC;AA+H3C,QAAA,MAAM,SAAS;;;;;;eAD+L,MAAM,GAAG,SAAS;;;;;;;;;;;;;;;;;;;;;CAClJ,CAAC;AAC/E,MAAM,MAAM,WAAW,GAAG,OAAO,SAAS,CAAC,KAAK,CAAC;AACjD,MAAM,MAAM,YAAY,GAAG,OAAO,SAAS,CAAC,MAAM,CAAC;AACnD,MAAM,MAAM,WAAW,GAAG,OAAO,SAAS,CAAC,KAAK,CAAC;AAEjD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgDG;AACH,MAAM,CAAC,OAAO,OAAO,MAAO,SAAQ,oBAAoB,CAAC,WAAW,EAAE,YAAY,EAAE,WAAW,CAAC;CAC/F"}
|
|
@@ -11,11 +11,10 @@ let hidden = true;
|
|
|
11
11
|
let toggle = () => {
|
|
12
12
|
hidden = !hidden;
|
|
13
13
|
};
|
|
14
|
-
let navDivCls = twMerge(navDivClass, $$props.classNav);
|
|
15
14
|
</script>
|
|
16
15
|
|
|
17
16
|
<Frame tag="nav" {...$$restProps} class={twMerge(navClass, $$props.class)}>
|
|
18
|
-
<div class={twMerge(
|
|
17
|
+
<div class={twMerge(navDivClass, $$props.classNavDiv, (fluid && 'w-full') || 'container')}>
|
|
19
18
|
<slot {hidden} {toggle} />
|
|
20
19
|
</div>
|
|
21
20
|
</Frame>
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Navbar.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/navbar/Navbar.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;AA2CD,QAAA,MAAM,SAAS
|
|
1
|
+
{"version":3,"file":"Navbar.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/navbar/Navbar.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;AA2CD,QAAA,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAAwC,CAAC;AACxD,MAAM,MAAM,WAAW,GAAG,OAAO,SAAS,CAAC,KAAK,CAAC;AACjD,MAAM,MAAM,YAAY,GAAG,OAAO,SAAS,CAAC,MAAM,CAAC;AACnD,MAAM,MAAM,WAAW,GAAG,OAAO,SAAS,CAAC,KAAK,CAAC;AAEjD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAiCG;AACH,MAAM,CAAC,OAAO,OAAO,MAAO,SAAQ,oBAAoB,CAAC,WAAW,EAAE,YAAY,EAAE,WAAW,CAAC;CAC/F"}
|
package/dist/typography/A.svelte
CHANGED
|
@@ -4,7 +4,7 @@ export let color = 'text-primary-600 dark:text-primary-500';
|
|
|
4
4
|
export let aClass = 'inline-flex items-center hover:underline';
|
|
5
5
|
</script>
|
|
6
6
|
|
|
7
|
-
<a {...$$restProps} {href} class={twMerge(aClass, color, $$props.class)}>
|
|
7
|
+
<a {...$$restProps} {href} class={twMerge(aClass, color, $$props.class)} on:click>
|
|
8
8
|
<slot />
|
|
9
9
|
</a>
|
|
10
10
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"A.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/typography/A.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;AAmBD,QAAA,MAAM,SAAS
|
|
1
|
+
{"version":3,"file":"A.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/typography/A.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;AAmBD,QAAA,MAAM,SAAS;;;;;;;;;;;;;;;CAA+D,CAAC;AAC/E,MAAM,MAAM,MAAM,GAAG,OAAO,SAAS,CAAC,KAAK,CAAC;AAC5C,MAAM,MAAM,OAAO,GAAG,OAAO,SAAS,CAAC,MAAM,CAAC;AAC9C,MAAM,MAAM,MAAM,GAAG,OAAO,SAAS,CAAC,KAAK,CAAC;AAE5C;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8BG;AACH,MAAM,CAAC,OAAO,OAAO,CAAE,SAAQ,oBAAoB,CAAC,MAAM,EAAE,OAAO,EAAE,MAAM,CAAC;CAC3E"}
|
|
@@ -5,7 +5,7 @@ export let ariaLabel = 'chevron up';
|
|
|
5
5
|
export let role = 'img';
|
|
6
6
|
let viewBox;
|
|
7
7
|
let svgpath;
|
|
8
|
-
let svgoutline = `<path clip-rule="evenodd" fill-rule="evenodd" d="
|
|
8
|
+
let svgoutline = `<path clip-rule="evenodd" fill-rule="evenodd" d="M4.5 15.75L12 8.25L19.5 15.75" stroke="${color}"></path>`;
|
|
9
9
|
let svgsolid = `<path clip-rule="evenodd" fill-rule="evenodd" d="M14.707 12.707a1 1 0 01-1.414 0L10 9.414l-3.293 3.293a1 1 0 01-1.414-1.414l4-4a1 1 0 011.414 0l4 4a1 1 0 010 1.414z" fill="${color}"></path>`;
|
|
10
10
|
$: switch (variation) {
|
|
11
11
|
case 'outline':
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "flowbite-svelte",
|
|
3
|
-
"version": "0.38.
|
|
3
|
+
"version": "0.38.3",
|
|
4
4
|
"description": "Flowbite components for Svelte",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"author": {
|
|
@@ -30,16 +30,16 @@
|
|
|
30
30
|
},
|
|
31
31
|
"devDependencies": {
|
|
32
32
|
"@docsearch/js": "^3.5.0",
|
|
33
|
-
"@playwright/test": "^1.35.
|
|
33
|
+
"@playwright/test": "^1.35.1",
|
|
34
34
|
"@sveltejs/adapter-vercel": "^3.0.1",
|
|
35
|
-
"@sveltejs/kit": "^1.20.
|
|
35
|
+
"@sveltejs/kit": "^1.20.4",
|
|
36
36
|
"@sveltejs/package": "2.0.2",
|
|
37
37
|
"@typescript-eslint/eslint-plugin": "^5.59.11",
|
|
38
38
|
"@typescript-eslint/parser": "^5.59.11",
|
|
39
39
|
"autoprefixer": "^10.4.14",
|
|
40
40
|
"createprops": "^0.5.5",
|
|
41
|
-
"esbuild": "0.18.
|
|
42
|
-
"eslint": "^8.
|
|
41
|
+
"esbuild": "0.18.4",
|
|
42
|
+
"eslint": "^8.43.0",
|
|
43
43
|
"eslint-config-prettier": "^8.8.0",
|
|
44
44
|
"eslint-plugin-svelte3": "^4.0.0",
|
|
45
45
|
"mdsvex": "^0.10.6",
|
|
@@ -110,7 +110,7 @@
|
|
|
110
110
|
},
|
|
111
111
|
"dependencies": {
|
|
112
112
|
"@popperjs/core": "^2.11.8",
|
|
113
|
-
"flowbite": "^1.6.
|
|
113
|
+
"flowbite": "^1.6.6",
|
|
114
114
|
"tailwind-merge": "^1.13.1"
|
|
115
115
|
},
|
|
116
116
|
"engines": {
|
|
@@ -410,10 +410,6 @@
|
|
|
410
410
|
"types": "./dist/navbar/NavBrand.svelte.d.ts",
|
|
411
411
|
"svelte": "./dist/navbar/NavBrand.svelte"
|
|
412
412
|
},
|
|
413
|
-
"./NavDropdown.svelte": {
|
|
414
|
-
"types": "./dist/navbar/NavDropdown.svelte.d.ts",
|
|
415
|
-
"svelte": "./dist/navbar/NavDropdown.svelte"
|
|
416
|
-
},
|
|
417
413
|
"./NavHamburger.svelte": {
|
|
418
414
|
"types": "./dist/navbar/NavHamburger.svelte.d.ts",
|
|
419
415
|
"svelte": "./dist/navbar/NavHamburger.svelte"
|
|
@@ -1,103 +0,0 @@
|
|
|
1
|
-
<script>import { twMerge } from 'tailwind-merge';
|
|
2
|
-
import { clickOutside } from '../utils/clickOutside';
|
|
3
|
-
export let liBtnClass = 'flex items-center justify-between w-full';
|
|
4
|
-
export let name;
|
|
5
|
-
export let child = [];
|
|
6
|
-
export let dropdownDiv = '';
|
|
7
|
-
export let dropdownLinkClassWithChild = undefined;
|
|
8
|
-
export let rel = undefined;
|
|
9
|
-
let hidden = true;
|
|
10
|
-
let block = false;
|
|
11
|
-
const handleDropdown = () => {
|
|
12
|
-
hidden = !hidden;
|
|
13
|
-
block = !block;
|
|
14
|
-
};
|
|
15
|
-
let liClass = 'flex justify-center py-2 pr-4 pl-3 text-gray-700 border-b border-gray-100 hover:bg-gray-50 md:hover:bg-transparent md:border-0 md:hover:text-primary-700 md:p-0 dark:text-gray-400 md:dark:hover:text-white dark:hover:bg-gray-700 dark:hover:text-white md:dark:hover:bg-transparent dark:border-gray-700';
|
|
16
|
-
</script>
|
|
17
|
-
|
|
18
|
-
<li use:clickOutside={() => !hidden && handleDropdown()} class={twMerge(liClass, $$props.classLi)}>
|
|
19
|
-
<button on:click={() => handleDropdown()} class={twMerge(liBtnClass, $$props.classBtn)}
|
|
20
|
-
>{name}
|
|
21
|
-
<svg class="ml-1 w-4 h-4" fill="currentColor" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"
|
|
22
|
-
><path
|
|
23
|
-
fill-rule="evenodd"
|
|
24
|
-
d="M5.293 7.293a1 1 0 011.414 0L10 10.586l3.293-3.293a1 1 0 111.414 1.414l-4 4a1 1 0 01-1.414 0l-4-4a1 1 0 010-1.414z"
|
|
25
|
-
clip-rule="evenodd" /></svg
|
|
26
|
-
></button>
|
|
27
|
-
|
|
28
|
-
<!-- Dropdown menu -->
|
|
29
|
-
<div class:hidden class="absolute {dropdownDiv} mt-8 z-10">
|
|
30
|
-
<slot>
|
|
31
|
-
<ul class="py-1" aria-labelledby="dropdownLargeButton">
|
|
32
|
-
{#each child as item}
|
|
33
|
-
<li>
|
|
34
|
-
<a
|
|
35
|
-
href={item.href}
|
|
36
|
-
{rel}
|
|
37
|
-
on:blur
|
|
38
|
-
on:change
|
|
39
|
-
on:click
|
|
40
|
-
on:focus
|
|
41
|
-
on:keydown
|
|
42
|
-
on:keypress
|
|
43
|
-
on:keyup
|
|
44
|
-
on:mouseenter
|
|
45
|
-
on:mouseleave
|
|
46
|
-
on:mouseover
|
|
47
|
-
class={dropdownLinkClassWithChild}>{item.name}</a>
|
|
48
|
-
</li>
|
|
49
|
-
{/each}
|
|
50
|
-
</ul>
|
|
51
|
-
</slot>
|
|
52
|
-
</div>
|
|
53
|
-
</li>
|
|
54
|
-
|
|
55
|
-
<!--
|
|
56
|
-
@component
|
|
57
|
-
[Go to Navbar](https://flowbite-svelte.com/docs/components/navbar)
|
|
58
|
-
## Props
|
|
59
|
-
@prop liBtnClass: string = 'flex items-center justify-between w-full';
|
|
60
|
-
@prop name: string;
|
|
61
|
-
@prop child: NavbarType[] = [];
|
|
62
|
-
@prop dropdownDiv: string = '';
|
|
63
|
-
@prop dropdownLinkClassWithChild: string | undefined = undefined;
|
|
64
|
-
@prop rel: string | undefined = undefined;
|
|
65
|
-
## Event
|
|
66
|
-
- on:blur
|
|
67
|
-
- on:change
|
|
68
|
-
- on:click
|
|
69
|
-
- on:focus
|
|
70
|
-
- on:keydown
|
|
71
|
-
- on:keypress
|
|
72
|
-
- on:keyup
|
|
73
|
-
- on:mouseenter
|
|
74
|
-
- on:mouseleave
|
|
75
|
-
- on:mouseover
|
|
76
|
-
## Example
|
|
77
|
-
```
|
|
78
|
-
<script>
|
|
79
|
-
import { Navbar, NavBrand, NavLi, NavUl, NavHamburger } from 'flowbite-svelte'
|
|
80
|
-
</script>
|
|
81
|
-
|
|
82
|
-
<Navbar let:hidden let:toggle>
|
|
83
|
-
<NavBrand href="/">
|
|
84
|
-
<img
|
|
85
|
-
src="/images/flowbite-svelte-icon-logo.svg"
|
|
86
|
-
class="mr-3 h-6 sm:h-9"
|
|
87
|
-
alt="Flowbite Logo"
|
|
88
|
-
/>
|
|
89
|
-
<span class="self-center whitespace-nowrap text-xl font-semibold dark:text-white">
|
|
90
|
-
Flowbite
|
|
91
|
-
</span>
|
|
92
|
-
</NavBrand>
|
|
93
|
-
<NavHamburger on:click={toggle} />
|
|
94
|
-
<NavUl {hidden}>
|
|
95
|
-
<NavLi href="/" active={true}>Home</NavLi>
|
|
96
|
-
<NavLi href="/about">About</NavLi>
|
|
97
|
-
<NavLi href="/services">Services</NavLi>
|
|
98
|
-
<NavLi href="/pricing">Pricing</NavLi>
|
|
99
|
-
<NavLi href="/contact">Contact</NavLi>
|
|
100
|
-
</NavUl>
|
|
101
|
-
</Navbar>
|
|
102
|
-
```
|
|
103
|
-
-->
|
|
@@ -1,85 +0,0 @@
|
|
|
1
|
-
import { SvelteComponentTyped } from "svelte";
|
|
2
|
-
import type { NavbarType } from '../types';
|
|
3
|
-
declare const __propDef: {
|
|
4
|
-
props: {
|
|
5
|
-
[x: string]: any;
|
|
6
|
-
liBtnClass?: string | undefined;
|
|
7
|
-
name: string;
|
|
8
|
-
child?: NavbarType[] | undefined;
|
|
9
|
-
dropdownDiv?: string | undefined;
|
|
10
|
-
dropdownLinkClassWithChild?: string | undefined;
|
|
11
|
-
rel?: string | undefined;
|
|
12
|
-
};
|
|
13
|
-
events: {
|
|
14
|
-
blur: FocusEvent;
|
|
15
|
-
change: Event;
|
|
16
|
-
click: MouseEvent;
|
|
17
|
-
focus: FocusEvent;
|
|
18
|
-
keydown: KeyboardEvent;
|
|
19
|
-
keypress: KeyboardEvent;
|
|
20
|
-
keyup: KeyboardEvent;
|
|
21
|
-
mouseenter: MouseEvent;
|
|
22
|
-
mouseleave: MouseEvent;
|
|
23
|
-
mouseover: MouseEvent;
|
|
24
|
-
} & {
|
|
25
|
-
[evt: string]: CustomEvent<any>;
|
|
26
|
-
};
|
|
27
|
-
slots: {
|
|
28
|
-
default: {};
|
|
29
|
-
};
|
|
30
|
-
};
|
|
31
|
-
export type NavDropdownProps = typeof __propDef.props;
|
|
32
|
-
export type NavDropdownEvents = typeof __propDef.events;
|
|
33
|
-
export type NavDropdownSlots = typeof __propDef.slots;
|
|
34
|
-
/**
|
|
35
|
-
* [Go to Navbar](https://flowbite-svelte.com/docs/components/navbar)
|
|
36
|
-
* ## Props
|
|
37
|
-
* @prop liBtnClass: string = 'flex items-center justify-between w-full';
|
|
38
|
-
* @prop name: string;
|
|
39
|
-
* @prop child: NavbarType[] = [];
|
|
40
|
-
* @prop dropdownDiv: string = '';
|
|
41
|
-
* @prop dropdownLinkClassWithChild: string | undefined = undefined;
|
|
42
|
-
* @prop rel: string | undefined = undefined;
|
|
43
|
-
* ## Event
|
|
44
|
-
* - on:blur
|
|
45
|
-
* - on:change
|
|
46
|
-
* - on:click
|
|
47
|
-
* - on:focus
|
|
48
|
-
* - on:keydown
|
|
49
|
-
* - on:keypress
|
|
50
|
-
* - on:keyup
|
|
51
|
-
* - on:mouseenter
|
|
52
|
-
* - on:mouseleave
|
|
53
|
-
* - on:mouseover
|
|
54
|
-
* ## Example
|
|
55
|
-
* ```
|
|
56
|
-
* <script>
|
|
57
|
-
* import { Navbar, NavBrand, NavLi, NavUl, NavHamburger } from 'flowbite-svelte'
|
|
58
|
-
* </script>
|
|
59
|
-
*
|
|
60
|
-
* <Navbar let:hidden let:toggle>
|
|
61
|
-
* <NavBrand href="/">
|
|
62
|
-
* <img
|
|
63
|
-
* src="/images/flowbite-svelte-icon-logo.svg"
|
|
64
|
-
* class="mr-3 h-6 sm:h-9"
|
|
65
|
-
* alt="Flowbite Logo"
|
|
66
|
-
* />
|
|
67
|
-
* <span class="self-center whitespace-nowrap text-xl font-semibold dark:text-white">
|
|
68
|
-
* Flowbite
|
|
69
|
-
* </span>
|
|
70
|
-
* </NavBrand>
|
|
71
|
-
* <NavHamburger on:click={toggle} />
|
|
72
|
-
* <NavUl {hidden}>
|
|
73
|
-
* <NavLi href="/" active={true}>Home</NavLi>
|
|
74
|
-
* <NavLi href="/about">About</NavLi>
|
|
75
|
-
* <NavLi href="/services">Services</NavLi>
|
|
76
|
-
* <NavLi href="/pricing">Pricing</NavLi>
|
|
77
|
-
* <NavLi href="/contact">Contact</NavLi>
|
|
78
|
-
* </NavUl>
|
|
79
|
-
* </Navbar>
|
|
80
|
-
* ```
|
|
81
|
-
*/
|
|
82
|
-
export default class NavDropdown extends SvelteComponentTyped<NavDropdownProps, NavDropdownEvents, NavDropdownSlots> {
|
|
83
|
-
}
|
|
84
|
-
export {};
|
|
85
|
-
//# sourceMappingURL=NavDropdown.svelte.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"NavDropdown.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/navbar/NavDropdown.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;AAED,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,UAAU,CAAC;AAiD3C,QAAA,MAAM,SAAS;;;;cADoL,MAAM;;;qCAA2E,MAAM,GAAG,SAAS;cAAQ,MAAM,GAAG,SAAS;;;;;;;;;;;;;;;;;;;CAClP,CAAC;AAC/E,MAAM,MAAM,gBAAgB,GAAG,OAAO,SAAS,CAAC,KAAK,CAAC;AACtD,MAAM,MAAM,iBAAiB,GAAG,OAAO,SAAS,CAAC,MAAM,CAAC;AACxD,MAAM,MAAM,gBAAgB,GAAG,OAAO,SAAS,CAAC,KAAK,CAAC;AAEtD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+CG;AACH,MAAM,CAAC,OAAO,OAAO,WAAY,SAAQ,oBAAoB,CAAC,gBAAgB,EAAE,iBAAiB,EAAE,gBAAgB,CAAC;CACnH"}
|