flowbite-svelte 0.38.1 → 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/alerts/Alert.svelte +1 -1
- package/dist/alerts/Alert.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/banner/Banner.svelte +8 -10
- package/dist/banner/Banner.svelte.d.ts +5 -5
- package/dist/banner/Banner.svelte.d.ts.map +1 -1
- package/dist/bottom-nav/BottomNav.svelte +16 -14
- package/dist/bottom-nav/BottomNav.svelte.d.ts +9 -7
- package/dist/bottom-nav/BottomNav.svelte.d.ts.map +1 -1
- package/dist/bottom-nav/BottomNavHeader.svelte +4 -3
- package/dist/bottom-nav/BottomNavHeader.svelte.d.ts.map +1 -1
- package/dist/bottom-nav/BottomNavHeaderItem.svelte +3 -2
- package/dist/bottom-nav/BottomNavHeaderItem.svelte.d.ts.map +1 -1
- package/dist/bottom-nav/BottomNavItem.svelte +11 -14
- package/dist/bottom-nav/BottomNavItem.svelte.d.ts +3 -6
- package/dist/bottom-nav/BottomNavItem.svelte.d.ts.map +1 -1
- package/dist/breadcrumbs/BreadcrumbItem.svelte +6 -5
- package/dist/breadcrumbs/BreadcrumbItem.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/carousels/Caption.svelte +2 -1
- package/dist/carousels/Caption.svelte.d.ts +1 -0
- package/dist/carousels/Caption.svelte.d.ts.map +1 -1
- package/dist/carousels/Carousel.svelte +15 -7
- package/dist/carousels/Carousel.svelte.d.ts +4 -1
- package/dist/carousels/Carousel.svelte.d.ts.map +1 -1
- package/dist/carousels/CarouselTransition.svelte +13 -5
- package/dist/carousels/CarouselTransition.svelte.d.ts +3 -0
- package/dist/carousels/CarouselTransition.svelte.d.ts.map +1 -1
- package/dist/carousels/Thumbnail.svelte +2 -1
- package/dist/carousels/Thumbnail.svelte.d.ts +1 -0
- package/dist/carousels/Thumbnail.svelte.d.ts.map +1 -1
- package/dist/device-mockup/DeviceMockup.svelte +93 -30
- package/dist/device-mockup/DeviceMockup.svelte.d.ts +1 -0
- package/dist/device-mockup/DeviceMockup.svelte.d.ts.map +1 -1
- package/dist/dropdowns/Dropdown.svelte +7 -6
- package/dist/dropdowns/Dropdown.svelte.d.ts +0 -2
- package/dist/dropdowns/Dropdown.svelte.d.ts.map +1 -1
- package/dist/footer/Footer.svelte +4 -20
- package/dist/footer/Footer.svelte.d.ts.map +1 -1
- package/dist/footer/FooterBrand.svelte +7 -4
- package/dist/footer/FooterBrand.svelte.d.ts.map +1 -1
- package/dist/footer/FooterCopyright.svelte +4 -2
- package/dist/footer/FooterCopyright.svelte.d.ts.map +1 -1
- package/dist/footer/FooterLink.svelte +4 -2
- package/dist/footer/FooterLink.svelte.d.ts.map +1 -1
- package/dist/forms/Checkbox.svelte +2 -1
- package/dist/forms/Checkbox.svelte.d.ts.map +1 -1
- package/dist/forms/FloatingLabelInput.svelte +3 -3
- package/dist/forms/Input.svelte +6 -4
- package/dist/forms/Input.svelte.d.ts +1 -0
- package/dist/forms/Input.svelte.d.ts.map +1 -1
- package/dist/forms/Radio.svelte.d.ts.map +1 -1
- package/dist/forms/Select.svelte +1 -1
- package/dist/forms/Toggle.svelte +10 -2
- package/dist/forms/Toggle.svelte.d.ts.map +1 -1
- package/dist/gallery/Gallery.svelte +1 -1
- package/dist/megamenu/MegaMenu.svelte +1 -1
- package/dist/megamenu/MegaMenu.svelte.d.ts.map +1 -1
- package/dist/modals/Modal.svelte +4 -3
- package/dist/modals/Modal.svelte.d.ts +2 -2
- package/dist/modals/Modal.svelte.d.ts.map +1 -1
- package/dist/navbar/NavHamburger.svelte +2 -1
- package/dist/navbar/NavHamburger.svelte.d.ts +1 -0
- package/dist/navbar/NavHamburger.svelte.d.ts.map +1 -1
- package/dist/navbar/NavSidebarHamburger.svelte +2 -1
- package/dist/navbar/NavSidebarHamburger.svelte.d.ts +1 -0
- package/dist/navbar/NavSidebarHamburger.svelte.d.ts.map +1 -1
- package/dist/navbar/NavUl.svelte +1 -1
- package/dist/navbar/Navbar.svelte +1 -1
- package/dist/navbar/Navbar.svelte.d.ts +1 -0
- package/dist/navbar/Navbar.svelte.d.ts.map +1 -1
- package/dist/navbar/SidebarMenu.svelte +1 -1
- package/dist/paginations/Pagination.svelte +6 -6
- package/dist/paginations/Pagination.svelte.d.ts.map +1 -1
- package/dist/progressbars/Progressbar.svelte +3 -3
- package/dist/progressbars/Progressbar.svelte.d.ts +1 -0
- package/dist/progressbars/Progressbar.svelte.d.ts.map +1 -1
- package/dist/ratings/Star.svelte +1 -1
- package/dist/ratings/Thumbup.svelte +1 -1
- package/dist/skeleton/CardPlaceholder.svelte.d.ts.map +1 -1
- package/dist/steps/StepIndicator.svelte +1 -1
- package/dist/toasts/Toast.svelte.d.ts +0 -38
- package/dist/toasts/Toast.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/dist/utils/Popper.svelte +2 -2
- package/package.json +15 -19
- package/dist/navbar/NavDropdown.svelte +0 -102
- package/dist/navbar/NavDropdown.svelte.d.ts +0 -84
- 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"}
|
package/dist/alerts/Alert.svelte
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Alert.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/alerts/Alert.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;
|
|
1
|
+
{"version":3,"file":"Alert.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/alerts/Alert.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;AAiED,QAAA,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAAwC,CAAC;AACxD,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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAqCG;AACH,MAAM,CAAC,OAAO,OAAO,KAAM,SAAQ,oBAAoB,CAAC,UAAU,EAAE,WAAW,EAAE,UAAU,CAAC;CAC3F"}
|
|
@@ -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"}
|
|
@@ -4,26 +4,24 @@ export let id = 'sticky-banner';
|
|
|
4
4
|
export let position = 'sticky';
|
|
5
5
|
export let dismissable = true;
|
|
6
6
|
export let bannerType = 'default';
|
|
7
|
-
export let
|
|
8
|
-
export let
|
|
7
|
+
export let divClass = 'z-10 flex justify-between p-4 dark:bg-gray-700 dark:border-gray-600';
|
|
8
|
+
export let innerClass = 'flex';
|
|
9
9
|
const divClasses = {
|
|
10
10
|
default: 'top-0 left-0 w-full border-b border-gray-200 bg-gray-50',
|
|
11
11
|
bottom: 'bottom-0 left-0 w-full border-t border-gray-200 bg-gray-50',
|
|
12
12
|
cta: 'flex-col md:flex-row w-[calc(100%-2rem)] -translate-x-1/2 bg-white border border-gray-100 rounded-lg shadow-sm lg:max-w-7xl left-1/2 top-6',
|
|
13
13
|
signup: 'top-0 left-0 w-full border-b border-gray-200 bg-gray-50',
|
|
14
|
-
info: 'top-0 left-0 flex-col w-full border-b border-gray-200 md:flex-row bg-gray-50'
|
|
15
|
-
custom: ''
|
|
14
|
+
info: 'top-0 left-0 flex-col w-full border-b border-gray-200 md:flex-row bg-gray-50'
|
|
16
15
|
};
|
|
17
16
|
const insideDivClasses = {
|
|
18
17
|
default: 'items-center mx-auto',
|
|
19
18
|
bottom: 'items-center mx-auto',
|
|
20
19
|
cta: 'flex-col items-start mb-3 mr-4 md:items-center md:flex-row md:mb-0',
|
|
21
20
|
signup: 'items-center flex-shrink-0 w-full mx-auto sm:w-auto',
|
|
22
|
-
info: 'items-center flex-shrink-0'
|
|
23
|
-
custom: ''
|
|
21
|
+
info: 'items-center flex-shrink-0'
|
|
24
22
|
};
|
|
25
|
-
$: divClass = twMerge(position,
|
|
26
|
-
$: div2Class = twMerge(
|
|
23
|
+
$: divClass = twMerge(position, divClass, divClasses[bannerType], $$props.classDiv);
|
|
24
|
+
$: div2Class = twMerge(innerClass, insideDivClasses[bannerType], $$props.classInner);
|
|
27
25
|
let show = true;
|
|
28
26
|
$: handleHide = () => {
|
|
29
27
|
show = !show;
|
|
@@ -69,8 +67,8 @@ $: handleHide = () => {
|
|
|
69
67
|
@prop id: string = 'sticky-banner';
|
|
70
68
|
@prop position: 'static' | 'fixed' | 'absolute' | 'relative' | 'sticky' = 'sticky';
|
|
71
69
|
@prop dismissable: boolean = true;
|
|
72
|
-
@prop bannerType: 'default' | 'bottom' | 'cta' | 'signup' | 'info'
|
|
73
|
-
@prop
|
|
70
|
+
@prop bannerType: 'default' | 'bottom' | 'cta' | 'signup' | 'info' = 'default';
|
|
71
|
+
@prop divClass: string = 'z-10 flex justify-between p-4 dark:bg-gray-700 dark:border-gray-600';
|
|
74
72
|
@prop insideDiv: string = 'flex';
|
|
75
73
|
## Event
|
|
76
74
|
- on:click
|
|
@@ -5,9 +5,9 @@ declare const __propDef: {
|
|
|
5
5
|
id?: string | undefined;
|
|
6
6
|
position?: "static" | "fixed" | "absolute" | "relative" | "sticky" | undefined;
|
|
7
7
|
dismissable?: boolean | undefined;
|
|
8
|
-
bannerType?: "default" | "
|
|
9
|
-
|
|
10
|
-
|
|
8
|
+
bannerType?: "default" | "bottom" | "cta" | "signup" | "info" | undefined;
|
|
9
|
+
divClass?: string | undefined;
|
|
10
|
+
innerClass?: string | undefined;
|
|
11
11
|
};
|
|
12
12
|
events: {
|
|
13
13
|
click: MouseEvent;
|
|
@@ -42,8 +42,8 @@ export type BannerSlots = typeof __propDef.slots;
|
|
|
42
42
|
* @prop id: string = 'sticky-banner';
|
|
43
43
|
* @prop position: 'static' | 'fixed' | 'absolute' | 'relative' | 'sticky' = 'sticky';
|
|
44
44
|
* @prop dismissable: boolean = true;
|
|
45
|
-
* @prop bannerType: 'default' | 'bottom' | 'cta' | 'signup' | 'info'
|
|
46
|
-
* @prop
|
|
45
|
+
* @prop bannerType: 'default' | 'bottom' | 'cta' | 'signup' | 'info' = 'default';
|
|
46
|
+
* @prop divClass: string = 'z-10 flex justify-between p-4 dark:bg-gray-700 dark:border-gray-600';
|
|
47
47
|
* @prop insideDiv: string = 'flex';
|
|
48
48
|
* ## Event
|
|
49
49
|
* - on:click
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Banner.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/banner/Banner.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;
|
|
1
|
+
{"version":3,"file":"Banner.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/banner/Banner.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;AAyDD,QAAA,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;CAA+D,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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2CG;AACH,MAAM,CAAC,OAAO,OAAO,MAAO,SAAQ,oBAAoB,CAAC,WAAW,EAAE,YAAY,EAAE,WAAW,CAAC;CAC/F"}
|
|
@@ -1,12 +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
|
-
export let
|
|
6
|
-
export let
|
|
7
|
-
export let
|
|
8
|
-
|
|
8
|
+
export let outerClass = 'w-full z-50 border-gray-200 dark:bg-gray-700 dark:border-gray-600';
|
|
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);
|
|
9
12
|
setContext('navType', navType);
|
|
13
|
+
setContext('bottomNavType', { activeClass: activeCls });
|
|
10
14
|
const outerDivClasses = {
|
|
11
15
|
default: 'bottom-0 left-0 h-16 bg-white border-t',
|
|
12
16
|
border: 'bottom-0 left-0 h-16 bg-white border-t',
|
|
@@ -15,8 +19,7 @@ const outerDivClasses = {
|
|
|
15
19
|
group: 'bottom-0 -translate-x-1/2 bg-white border-t left-1/2',
|
|
16
20
|
card: 'bottom-0 left-0 h-16 bg-white border-t',
|
|
17
21
|
meeting: 'bottom-0 left-0 grid h-16 grid-cols-1 px-8 bg-white border-t md:grid-cols-3',
|
|
18
|
-
video: 'bottom-0 left-0 grid h-24 grid-cols-1 px-8 bg-white border-t md:grid-cols-3'
|
|
19
|
-
custom: outerCustom
|
|
22
|
+
video: 'bottom-0 left-0 grid h-24 grid-cols-1 px-8 bg-white border-t md:grid-cols-3'
|
|
20
23
|
};
|
|
21
24
|
const innerDivClasses = {
|
|
22
25
|
default: '',
|
|
@@ -26,16 +29,15 @@ const innerDivClasses = {
|
|
|
26
29
|
group: '',
|
|
27
30
|
card: '',
|
|
28
31
|
meeting: 'flex items-center justify-center mx-auto',
|
|
29
|
-
video: 'flex items-center w-full'
|
|
30
|
-
custom: innerCustom
|
|
32
|
+
video: 'flex items-center w-full'
|
|
31
33
|
};
|
|
32
|
-
$:
|
|
33
|
-
$:
|
|
34
|
+
$: outerCls = twMerge(position, outerClass, outerDivClasses[navType], $$props.classOuter);
|
|
35
|
+
$: innerCls = twMerge(innerClass, innerDivClasses[navType], $$props.classInner);
|
|
34
36
|
</script>
|
|
35
37
|
|
|
36
|
-
<div {...$$restProps} class={
|
|
38
|
+
<div {...$$restProps} class={outerCls}>
|
|
37
39
|
<slot name="header" />
|
|
38
|
-
<div class={
|
|
40
|
+
<div class={innerCls}>
|
|
39
41
|
<slot />
|
|
40
42
|
</div>
|
|
41
43
|
</div>
|
|
@@ -53,8 +55,8 @@ $: innerClass = twMerge(innerDefault, innerDivClasses[navType], $$props.innerDiv
|
|
|
53
55
|
## Props
|
|
54
56
|
@prop position: 'static' | 'fixed' | 'absolute' | 'relative' | 'sticky' = 'fixed';
|
|
55
57
|
@prop navType:| 'default' | 'border' | 'application' | 'pagination' | 'group' | 'card' | 'meeting' | 'video' | 'custom' = 'default';
|
|
56
|
-
@prop
|
|
57
|
-
@prop
|
|
58
|
+
@prop outerClass: string = 'w-full z-50 border-gray-200 dark:bg-gray-700 dark:border-gray-600';
|
|
59
|
+
@prop innerClass: string = 'grid h-full max-w-lg mx-auto';
|
|
58
60
|
@prop outerCustom: string = '';
|
|
59
61
|
@prop innerCustom: string = '';
|
|
60
62
|
## Example
|
|
@@ -1,13 +1,15 @@
|
|
|
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;
|
|
5
8
|
position?: "static" | "fixed" | "absolute" | "relative" | "sticky" | undefined;
|
|
6
|
-
navType?: "default" | "border" | "application" | "group" | "
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
innerCustom?: string | undefined;
|
|
9
|
+
navType?: "default" | "border" | "application" | "group" | "pagination" | "card" | "meeting" | "video" | undefined;
|
|
10
|
+
outerClass?: string | undefined;
|
|
11
|
+
innerClass?: string | undefined;
|
|
12
|
+
activeClass?: string | undefined;
|
|
11
13
|
};
|
|
12
14
|
events: {
|
|
13
15
|
[evt: string]: CustomEvent<any>;
|
|
@@ -32,8 +34,8 @@ export type BottomNavSlots = typeof __propDef.slots;
|
|
|
32
34
|
* ## Props
|
|
33
35
|
* @prop position: 'static' | 'fixed' | 'absolute' | 'relative' | 'sticky' = 'fixed';
|
|
34
36
|
* @prop navType:| 'default' | 'border' | 'application' | 'pagination' | 'group' | 'card' | 'meeting' | 'video' | 'custom' = 'default';
|
|
35
|
-
* @prop
|
|
36
|
-
* @prop
|
|
37
|
+
* @prop outerClass: string = 'w-full z-50 border-gray-200 dark:bg-gray-700 dark:border-gray-600';
|
|
38
|
+
* @prop innerClass: string = 'grid h-full max-w-lg mx-auto';
|
|
37
39
|
* @prop outerCustom: string = '';
|
|
38
40
|
* @prop innerCustom: string = '';
|
|
39
41
|
* ## Example
|
|
@@ -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"}
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
<script>
|
|
1
|
+
<script>import { twMerge } from 'tailwind-merge';
|
|
2
|
+
export let outerClass = 'w-full';
|
|
2
3
|
export let innerClass = 'grid max-w-xs grid-cols-3 gap-1 p-1 mx-auto my-2 bg-gray-100 rounded-lg dark:bg-gray-600';
|
|
3
4
|
</script>
|
|
4
5
|
|
|
5
|
-
<div class={outerClass} {...$$restProps}>
|
|
6
|
-
<div class={innerClass} role="group">
|
|
6
|
+
<div class={twMerge(outerClass, $$props.classOuter)} {...$$restProps}>
|
|
7
|
+
<div class={twMerge(innerClass, $$props.classInner)} role="group">
|
|
7
8
|
<slot />
|
|
8
9
|
</div>
|
|
9
10
|
</div>
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BottomNavHeader.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/bottom-nav/BottomNavHeader.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;
|
|
1
|
+
{"version":3,"file":"BottomNavHeader.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/bottom-nav/BottomNavHeader.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;AAoBD,QAAA,MAAM,SAAS;;;;;;;;;;;;CAA+D,CAAC;AAC/E,MAAM,MAAM,oBAAoB,GAAG,OAAO,SAAS,CAAC,KAAK,CAAC;AAC1D,MAAM,MAAM,qBAAqB,GAAG,OAAO,SAAS,CAAC,MAAM,CAAC;AAC5D,MAAM,MAAM,oBAAoB,GAAG,OAAO,SAAS,CAAC,KAAK,CAAC;AAE1D;;;;;;;;;;;;;;;;;GAiBG;AACH,MAAM,CAAC,OAAO,OAAO,eAAgB,SAAQ,oBAAoB,CAAC,oBAAoB,EAAE,qBAAqB,EAAE,oBAAoB,CAAC;CACnI"}
|
|
@@ -1,11 +1,12 @@
|
|
|
1
|
-
<script>
|
|
1
|
+
<script>import { twMerge } from 'tailwind-merge';
|
|
2
|
+
export let itemName = '';
|
|
2
3
|
export let active = false;
|
|
3
4
|
export let defaultClass = 'px-5 py-1.5 text-xs font-medium text-gray-900 hover:bg-gray-200 dark:text-white dark:hover:bg-gray-700 rounded-lg';
|
|
4
5
|
export let activeClass = 'px-5 py-1.5 text-xs font-medium text-white bg-gray-900 dark:bg-gray-300 dark:text-gray-900 rounded-lg';
|
|
5
6
|
$: btnClass = active ? activeClass : defaultClass;
|
|
6
7
|
</script>
|
|
7
8
|
|
|
8
|
-
<button class={btnClass} {...$$restProps}>
|
|
9
|
+
<button class={twMerge(btnClass, $$props.class)} {...$$restProps}>
|
|
9
10
|
{itemName}
|
|
10
11
|
</button>
|
|
11
12
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BottomNavHeaderItem.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/bottom-nav/BottomNavHeaderItem.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;
|
|
1
|
+
{"version":3,"file":"BottomNavHeaderItem.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/bottom-nav/BottomNavHeaderItem.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;AAuBD,QAAA,MAAM,SAAS;;;;;;;;;;;;CAA+D,CAAC;AAC/E,MAAM,MAAM,wBAAwB,GAAG,OAAO,SAAS,CAAC,KAAK,CAAC;AAC9D,MAAM,MAAM,yBAAyB,GAAG,OAAO,SAAS,CAAC,MAAM,CAAC;AAChE,MAAM,MAAM,wBAAwB,GAAG,OAAO,SAAS,CAAC,KAAK,CAAC;AAE9D;;;;;;;;GAQG;AACH,MAAM,CAAC,OAAO,OAAO,mBAAoB,SAAQ,oBAAoB,CAAC,wBAAwB,EAAE,yBAAyB,EAAE,wBAAwB,CAAC;CACnJ"}
|
|
@@ -1,13 +1,11 @@
|
|
|
1
1
|
<script>import { getContext } from 'svelte';
|
|
2
2
|
import { twMerge } from 'tailwind-merge';
|
|
3
3
|
export let btnName = '';
|
|
4
|
-
export let appBtnPosition = '
|
|
5
|
-
export let
|
|
6
|
-
export let
|
|
7
|
-
export let btnCustom = '';
|
|
8
|
-
export let spanCustom = '';
|
|
9
|
-
export let appCustom = '';
|
|
4
|
+
export let appBtnPosition = 'middle';
|
|
5
|
+
export let activeClass = undefined;
|
|
6
|
+
export let active = false;
|
|
10
7
|
const navType = getContext('navType');
|
|
8
|
+
const context = getContext('bottomNavType') ?? {};
|
|
11
9
|
const btnClasses = {
|
|
12
10
|
default: 'inline-flex flex-col items-center justify-center px-5 hover:bg-gray-50 dark:hover:bg-gray-800 group',
|
|
13
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',
|
|
@@ -16,8 +14,7 @@ const btnClasses = {
|
|
|
16
14
|
group: 'inline-flex flex-col items-center justify-center p-4 hover:bg-gray-50 dark:hover:bg-gray-800 group',
|
|
17
15
|
card: 'inline-flex flex-col items-center justify-center px-5 hover:bg-gray-50 dark:hover:bg-gray-800 group',
|
|
18
16
|
meeting: '',
|
|
19
|
-
video: ''
|
|
20
|
-
custom: btnCustom
|
|
17
|
+
video: ''
|
|
21
18
|
};
|
|
22
19
|
const spanClasses = {
|
|
23
20
|
default: 'text-sm text-gray-500 dark:text-gray-400 group-hover:text-primary-600 dark:group-hover:text-primary-500',
|
|
@@ -27,17 +24,17 @@ const spanClasses = {
|
|
|
27
24
|
group: 'sr-only',
|
|
28
25
|
card: 'text-sm text-gray-500 dark:text-gray-400 group-hover:text-primary-600 dark:group-hover:text-primary-500',
|
|
29
26
|
meeting: '',
|
|
30
|
-
video: ''
|
|
31
|
-
custom: spanCustom
|
|
27
|
+
video: ''
|
|
32
28
|
};
|
|
33
29
|
const appBtnClasses = {
|
|
34
30
|
left: 'inline-flex flex-col items-center justify-center px-5 rounded-l-full hover:bg-gray-50 dark:hover:bg-gray-800 group',
|
|
35
31
|
middle: 'inline-flex flex-col items-center justify-center px-5 hover:bg-gray-50 dark:hover:bg-gray-800 group',
|
|
36
|
-
right: 'inline-flex flex-col items-center justify-center px-5 rounded-r-full hover:bg-gray-50 dark:hover:bg-gray-800 group'
|
|
37
|
-
custom: appCustom
|
|
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'
|
|
38
33
|
};
|
|
39
|
-
|
|
40
|
-
$:
|
|
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);
|
|
41
38
|
</script>
|
|
42
39
|
|
|
43
40
|
<button
|
|
@@ -3,12 +3,9 @@ declare const __propDef: {
|
|
|
3
3
|
props: {
|
|
4
4
|
[x: string]: any;
|
|
5
5
|
btnName?: string | undefined;
|
|
6
|
-
appBtnPosition?: "
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
btnCustom?: string | undefined;
|
|
10
|
-
spanCustom?: string | undefined;
|
|
11
|
-
appCustom?: string | undefined;
|
|
6
|
+
appBtnPosition?: "left" | "middle" | "right" | undefined;
|
|
7
|
+
activeClass?: string | undefined;
|
|
8
|
+
active?: boolean | undefined;
|
|
12
9
|
};
|
|
13
10
|
events: {
|
|
14
11
|
click: MouseEvent;
|
|
@@ -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"}
|
|
@@ -1,13 +1,14 @@
|
|
|
1
|
-
<script>
|
|
1
|
+
<script>import { twMerge } from 'tailwind-merge';
|
|
2
|
+
export let home = false;
|
|
2
3
|
export let href = undefined;
|
|
3
4
|
export let linkClass = 'ml-1 text-sm font-medium text-gray-700 hover:text-gray-900 md:ml-2 dark:text-gray-400 dark:hover:text-white';
|
|
4
5
|
export let spanClass = 'ml-1 text-sm font-medium text-gray-500 md:ml-2 dark:text-gray-400';
|
|
5
6
|
export let homeClass = 'inline-flex items-center text-sm font-medium text-gray-700 hover:text-gray-900 dark:text-gray-400 dark:hover:text-white';
|
|
6
7
|
</script>
|
|
7
8
|
|
|
8
|
-
<li class=
|
|
9
|
+
<li class={twMerge('inline-flex items-center', $$props.class)} {...$$restProps}>
|
|
9
10
|
{#if home}
|
|
10
|
-
<a class={homeClass} {href}>
|
|
11
|
+
<a class={twMerge(homeClass, $$props.classHome)} {href}>
|
|
11
12
|
{#if $$slots.icon}
|
|
12
13
|
<slot name="icon" />
|
|
13
14
|
{:else}
|
|
@@ -32,11 +33,11 @@ export let homeClass = 'inline-flex items-center text-sm font-medium text-gray-7
|
|
|
32
33
|
clip-rule="evenodd" /></svg>
|
|
33
34
|
{/if}
|
|
34
35
|
{#if href}
|
|
35
|
-
<a class={linkClass} {href}>
|
|
36
|
+
<a class={twMerge(linkClass, $$props.classLink)} {href}>
|
|
36
37
|
<slot />
|
|
37
38
|
</a>
|
|
38
39
|
{:else}
|
|
39
|
-
<span class={spanClass}>
|
|
40
|
+
<span class={twMerge(spanClass, $$props.classSpan)}>
|
|
40
41
|
<slot />
|
|
41
42
|
</span>
|
|
42
43
|
{/if}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BreadcrumbItem.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/breadcrumbs/BreadcrumbItem.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;
|
|
1
|
+
{"version":3,"file":"BreadcrumbItem.svelte.d.ts","sourceRoot":"","sources":["../../../src/lib/breadcrumbs/BreadcrumbItem.svelte"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,QAAQ,CAE5C;AA8CD,QAAA,MAAM,SAAS;;;;eAD2H,MAAM,GAAG,SAAS;;;;;;;;;;;;CAC9E,CAAC;AAC/E,MAAM,MAAM,mBAAmB,GAAG,OAAO,SAAS,CAAC,KAAK,CAAC;AACzD,MAAM,MAAM,oBAAoB,GAAG,OAAO,SAAS,CAAC,MAAM,CAAC;AAC3D,MAAM,MAAM,mBAAmB,GAAG,OAAO,SAAS,CAAC,KAAK,CAAC;AAEzD;;;;;;;;;;;;;GAaG;AACH,MAAM,CAAC,OAAO,OAAO,cAAe,SAAQ,oBAAoB,CAAC,mBAAmB,EAAE,oBAAoB,EAAE,mBAAmB,CAAC;CAC/H"}
|
|
@@ -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"}
|