flowbite-svelte 0.34.3 → 0.34.5
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/forms/FloatingLabelInput.svelte +1 -0
- package/dist/forms/FloatingLabelInput.svelte.d.ts +1 -0
- package/dist/gallery/Gallery.svelte +14 -6
- package/dist/gallery/Gallery.svelte.d.ts +3 -2
- package/dist/gallery/GalleryItem.svelte +5 -5
- package/dist/gallery/GalleryItem.svelte.d.ts +2 -2
- package/dist/speed-dial/SpeedDial.svelte +8 -2
- package/dist/speed-dial/SpeedDial.svelte.d.ts +4 -0
- package/package.json +1 -1
|
@@ -1,9 +1,17 @@
|
|
|
1
1
|
<script>import classNames from 'classnames';
|
|
2
|
-
|
|
3
|
-
export let
|
|
4
|
-
|
|
2
|
+
import GalleryItem from './GalleryItem.svelte';
|
|
3
|
+
export let items = [];
|
|
4
|
+
$: divClass = classNames('grid', $$props.class);
|
|
5
|
+
function init(node) {
|
|
6
|
+
if (getComputedStyle(node).gap === 'normal')
|
|
7
|
+
node.style.gap = 'inherit';
|
|
8
|
+
}
|
|
5
9
|
</script>
|
|
6
10
|
|
|
7
|
-
<div class=
|
|
8
|
-
|
|
9
|
-
|
|
11
|
+
<div {...$$restProps} class={divClass} use:init>
|
|
12
|
+
{#each items as { src, alt }}
|
|
13
|
+
<GalleryItem {src} {alt} />
|
|
14
|
+
{:else}
|
|
15
|
+
<slot />
|
|
16
|
+
{/each}
|
|
17
|
+
</div>
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { SvelteComponentTyped } from "svelte";
|
|
2
|
+
import type { ImgType } from '../types';
|
|
2
3
|
declare const __propDef: {
|
|
3
4
|
props: {
|
|
4
|
-
|
|
5
|
-
|
|
5
|
+
[x: string]: any;
|
|
6
|
+
items?: ImgType[] | undefined;
|
|
6
7
|
};
|
|
7
8
|
events: {
|
|
8
9
|
[evt: string]: CustomEvent<any>;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
<script>export let src
|
|
2
|
-
export let alt =
|
|
3
|
-
export let
|
|
1
|
+
<script>export let src;
|
|
2
|
+
export let alt = undefined;
|
|
3
|
+
export let defaultClass = 'h-auto max-w-full rounded-lg';
|
|
4
4
|
</script>
|
|
5
5
|
|
|
6
6
|
<div>
|
|
7
|
-
<img class=
|
|
8
|
-
</div>
|
|
7
|
+
<img class={defaultClass} {src} {alt} />
|
|
8
|
+
</div>
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { SvelteComponentTyped } from "svelte";
|
|
2
2
|
declare const __propDef: {
|
|
3
3
|
props: {
|
|
4
|
-
src
|
|
4
|
+
src: string;
|
|
5
5
|
alt?: string | undefined;
|
|
6
|
-
|
|
6
|
+
defaultClass?: string | undefined;
|
|
7
7
|
};
|
|
8
8
|
events: {
|
|
9
9
|
[evt: string]: CustomEvent<any>;
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
<script context="module">export {};
|
|
2
2
|
</script>
|
|
3
3
|
|
|
4
|
-
<script>import
|
|
4
|
+
<script>import { getContext } from 'svelte';
|
|
5
|
+
import classNames from 'classnames';
|
|
5
6
|
import Button from '../buttons/Button.svelte';
|
|
6
7
|
import Popper from '../utils/Popper.svelte';
|
|
7
8
|
import { setContext } from 'svelte';
|
|
@@ -13,6 +14,11 @@ export let tooltip = 'left';
|
|
|
13
14
|
export let trigger = 'hover';
|
|
14
15
|
export let textOutside = false;
|
|
15
16
|
export let id = generateId();
|
|
17
|
+
export let shadow = null;
|
|
18
|
+
export let outline = false;
|
|
19
|
+
const group = getContext('group');
|
|
20
|
+
export let color = group ? (outline ? 'dark' : 'alternative') : 'blue';
|
|
21
|
+
export let gradient = false;
|
|
16
22
|
setContext('speed-dial', { pill, tooltip, textOutside });
|
|
17
23
|
let divClass;
|
|
18
24
|
$: divClass = classNames(defaultClass, 'group', $$props.class);
|
|
@@ -21,7 +27,7 @@ $: poperClass = classNames('flex items-center mb-4 gap-2', ['top', 'bottom'].inc
|
|
|
21
27
|
</script>
|
|
22
28
|
|
|
23
29
|
<div class={divClass}>
|
|
24
|
-
<Button {pill} name="Open actions menu" aria-controls={id} aria-expanded="false" color
|
|
30
|
+
<Button {pill} name="Open actions menu" aria-controls={id} aria-expanded="false" {color} {gradient} {outline} {shadow} class="!p-3">
|
|
25
31
|
<slot name="icon">
|
|
26
32
|
<svg
|
|
27
33
|
aria-hidden="true"
|
|
@@ -15,6 +15,10 @@ declare const __propDef: {
|
|
|
15
15
|
trigger?: "click" | "hover" | undefined;
|
|
16
16
|
textOutside?: boolean | undefined;
|
|
17
17
|
id?: string | undefined;
|
|
18
|
+
shadow?: "red" | "green" | "purple" | "pink" | "blue" | "cyan" | "teal" | "lime" | null | undefined;
|
|
19
|
+
outline?: boolean | undefined;
|
|
20
|
+
color?: "red" | "yellow" | "green" | "purple" | "pink" | "blue" | "light" | "dark" | "cyan" | "teal" | "lime" | "alternative" | "primary" | "purpleToBlue" | "cyanToBlue" | "greenToBlue" | "purpleToPink" | "pinkToOrange" | "tealToLime" | "redToYellow" | undefined;
|
|
21
|
+
gradient?: boolean | undefined;
|
|
18
22
|
};
|
|
19
23
|
events: {
|
|
20
24
|
[evt: string]: CustomEvent<any>;
|