flowbite-svelte 0.15.10 → 0.15.13
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 +26 -0
- package/forms/Checkbox.svelte +56 -30
- package/forms/Checkbox.svelte.d.ts +12 -4
- package/forms/CheckboxInline.svelte +3 -0
- package/forms/CheckboxInline.svelte.d.ts +23 -0
- package/forms/Radio.svelte +52 -9
- package/forms/Radio.svelte.d.ts +12 -5
- package/forms/RadioInline.svelte +3 -0
- package/forms/RadioInline.svelte.d.ts +23 -0
- package/forms/Search.svelte +17 -0
- package/forms/Search.svelte.d.ts +23 -0
- package/index.js +3 -1
- package/package.json +4 -2
- package/types.d.ts +1 -7
- package/forms/SingleCheckbox.svelte +0 -18
- package/forms/SingleCheckbox.svelte.d.ts +0 -22
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,32 @@
|
|
|
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.15.13](https://github.com/themesberg/flowbite-svelte/compare/v0.15.12...v0.15.13) (2022-05-05)
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
### Features
|
|
9
|
+
|
|
10
|
+
* add Checkbox, CheckboxInline, and checkbox page ([baab944](https://github.com/themesberg/flowbite-svelte/commit/baab944e588645bb2fbe751fd5a2beb00b8f6e77))
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
### Bug Fixes
|
|
14
|
+
|
|
15
|
+
* update RadioItem props ([fd2f9a0](https://github.com/themesberg/flowbite-svelte/commit/fd2f9a0c4b3854c3a644710a4cb1df238e1a6af2))
|
|
16
|
+
|
|
17
|
+
### [0.15.12](https://github.com/themesberg/flowbite-svelte/compare/v0.15.11...v0.15.12) (2022-05-05)
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
### Features
|
|
21
|
+
|
|
22
|
+
* add RadioItem and RadioInline for colors, inline, helper text ([9fc2812](https://github.com/themesberg/flowbite-svelte/commit/9fc281268f8008023e5a8d501893b8761ba8a5ef))
|
|
23
|
+
|
|
24
|
+
### [0.15.11](https://github.com/themesberg/flowbite-svelte/compare/v0.15.10...v0.15.11) (2022-05-03)
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
### Features
|
|
28
|
+
|
|
29
|
+
* add Search component ([c9874ad](https://github.com/themesberg/flowbite-svelte/commit/c9874ada31fbf20c74a882ee6392e9a7cc8ecc36))
|
|
30
|
+
|
|
5
31
|
### [0.15.10](https://github.com/themesberg/flowbite-svelte/compare/v0.15.9...v0.15.10) (2022-05-03)
|
|
6
32
|
|
|
7
33
|
|
package/forms/Checkbox.svelte
CHANGED
|
@@ -1,33 +1,59 @@
|
|
|
1
|
-
<script>export let
|
|
2
|
-
export let divClass = 'flex items-center mb-4';
|
|
1
|
+
<script>export let divClass = 'flex items-center mr-4';
|
|
3
2
|
export let inputClass = 'w-4 h-4 text-blue-600 bg-gray-100 rounded border-gray-300 focus:ring-blue-500 dark:focus:ring-blue-600 dark:ring-offset-gray-800 focus:ring-2 dark:bg-gray-700 dark:border-gray-600';
|
|
4
|
-
export let labelClass = 'ml-
|
|
5
|
-
export let
|
|
6
|
-
|
|
3
|
+
export let labelClass = 'ml-2 text-sm font-medium text-gray-900 dark:text-gray-300';
|
|
4
|
+
export let disabled = false;
|
|
5
|
+
if (disabled) {
|
|
6
|
+
labelClass = 'ml-2 text-sm font-medium text-gray-400 dark:text-gray-500';
|
|
7
|
+
}
|
|
8
|
+
export let name = '';
|
|
9
|
+
export let divHelperClass = 'flex items-center h-5';
|
|
10
|
+
export let labelHelperClass = 'font-medium text-gray-900 dark:text-gray-300';
|
|
11
|
+
export let helperClass = 'text-xs font-normal text-gray-500 dark:text-gray-300';
|
|
12
|
+
export let color = 'blue';
|
|
13
|
+
if (color === 'red') {
|
|
14
|
+
inputClass = 'w-4 h-4 text-red-600 bg-gray-100 rounded border-gray-300 focus:ring-red-500 dark:focus:ring-red-600 dark:ring-offset-gray-800 focus:ring-2 dark:bg-gray-700 dark:border-gray-600';
|
|
15
|
+
}
|
|
16
|
+
else if (color === 'green') {
|
|
17
|
+
inputClass = 'w-4 h-4 text-green-600 bg-gray-100 rounded border-gray-300 focus:ring-green-500 dark:focus:ring-green-600 dark:ring-offset-gray-800 focus:ring-2 dark:bg-gray-700 dark:border-gray-600';
|
|
18
|
+
}
|
|
19
|
+
else if (color === 'purple') {
|
|
20
|
+
inputClass = 'w-4 h-4 text-purple-600 bg-gray-100 rounded border-gray-300 focus:ring-purple-500 dark:focus:ring-purple-600 dark:ring-offset-gray-800 focus:ring-2 dark:bg-gray-700 dark:border-gray-600';
|
|
21
|
+
}
|
|
22
|
+
else if (color === 'teal') {
|
|
23
|
+
inputClass = 'w-4 h-4 text-teal-600 bg-gray-100 rounded border-gray-300 focus:ring-teal-500 dark:focus:ring-teal-600 dark:ring-offset-gray-800 focus:ring-2 dark:bg-gray-700 dark:border-gray-600';
|
|
24
|
+
}
|
|
25
|
+
else if (color === 'yellow') {
|
|
26
|
+
inputClass = 'w-4 h-4 text-yellow-400 bg-gray-100 rounded border-gray-300 focus:ring-yellow-500 dark:focus:ring-yellow-600 dark:ring-offset-gray-800 focus:ring-2 dark:bg-gray-700 dark:border-gray-600';
|
|
27
|
+
}
|
|
28
|
+
else if (color === 'orange') {
|
|
29
|
+
inputClass = 'w-4 h-4 text-orange-500 bg-gray-100 rounded border-gray-300 focus:ring-orange-500 dark:focus:ring-orange-600 dark:ring-offset-gray-800 focus:ring-2 dark:bg-gray-700 dark:border-gray-600';
|
|
30
|
+
}
|
|
31
|
+
else {
|
|
32
|
+
inputClass = 'w-4 h-4 text-blue-600 bg-gray-100 rounded border-gray-300 focus:ring-blue-500 dark:focus:ring-blue-600 dark:ring-offset-gray-800 focus:ring-2 dark:bg-gray-700 dark:border-gray-600';
|
|
33
|
+
}
|
|
34
|
+
export let helper;
|
|
35
|
+
export let id;
|
|
36
|
+
export let value;
|
|
37
|
+
export let label;
|
|
7
38
|
</script>
|
|
8
39
|
|
|
9
|
-
|
|
10
|
-
<
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
<label for={option.id} class={labelClass}>{option.label}</label>
|
|
30
|
-
</div>
|
|
31
|
-
{/if}
|
|
32
|
-
{/each}
|
|
33
|
-
</fieldset>
|
|
40
|
+
{#if helper}
|
|
41
|
+
<div class="flex">
|
|
42
|
+
<div class={divHelperClass}>
|
|
43
|
+
<input {id} type="checkbox" {name} {value} class={inputClass} aria-labelledby={id} aria-describedby={id} {disabled} {...$$restProps} />
|
|
44
|
+
</div>
|
|
45
|
+
<div class="ml-2 text-sm">
|
|
46
|
+
<label for={id} class={labelHelperClass}>
|
|
47
|
+
{@html label}
|
|
48
|
+
</label>
|
|
49
|
+
<p id="{id}-helper-radio-text" class={helperClass}>{helper}</p>
|
|
50
|
+
</div>
|
|
51
|
+
</div>
|
|
52
|
+
{:else}
|
|
53
|
+
<div class={divClass}>
|
|
54
|
+
<input {id} type="checkbox" {name} {value} class={inputClass} aria-labelledby={id} aria-describedby={id} {disabled} {...$$restProps} />
|
|
55
|
+
<label for={id} class={labelClass}>
|
|
56
|
+
{@html label}
|
|
57
|
+
</label>
|
|
58
|
+
</div>
|
|
59
|
+
{/if}
|
|
@@ -1,13 +1,21 @@
|
|
|
1
1
|
import { SvelteComponentTyped } from "svelte";
|
|
2
|
-
import type {
|
|
2
|
+
import type { FormColorType } from '../types';
|
|
3
3
|
declare const __propDef: {
|
|
4
4
|
props: {
|
|
5
|
-
|
|
5
|
+
[x: string]: any;
|
|
6
6
|
divClass?: string;
|
|
7
7
|
inputClass?: string;
|
|
8
8
|
labelClass?: string;
|
|
9
|
-
|
|
10
|
-
|
|
9
|
+
disabled?: boolean;
|
|
10
|
+
name?: string;
|
|
11
|
+
divHelperClass?: string;
|
|
12
|
+
labelHelperClass?: string;
|
|
13
|
+
helperClass?: string;
|
|
14
|
+
color?: FormColorType;
|
|
15
|
+
helper: string;
|
|
16
|
+
id: string;
|
|
17
|
+
value: string;
|
|
18
|
+
label: string;
|
|
11
19
|
};
|
|
12
20
|
events: {
|
|
13
21
|
[evt: string]: CustomEvent<any>;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/** @typedef {typeof __propDef.props} CheckboxInlineProps */
|
|
2
|
+
/** @typedef {typeof __propDef.events} CheckboxInlineEvents */
|
|
3
|
+
/** @typedef {typeof __propDef.slots} CheckboxInlineSlots */
|
|
4
|
+
export default class CheckboxInline extends SvelteComponentTyped<{}, {
|
|
5
|
+
[evt: string]: CustomEvent<any>;
|
|
6
|
+
}, {
|
|
7
|
+
default: {};
|
|
8
|
+
}> {
|
|
9
|
+
}
|
|
10
|
+
export type CheckboxInlineProps = typeof __propDef.props;
|
|
11
|
+
export type CheckboxInlineEvents = typeof __propDef.events;
|
|
12
|
+
export type CheckboxInlineSlots = typeof __propDef.slots;
|
|
13
|
+
import { SvelteComponentTyped } from "svelte";
|
|
14
|
+
declare const __propDef: {
|
|
15
|
+
props: {};
|
|
16
|
+
events: {
|
|
17
|
+
[evt: string]: CustomEvent<any>;
|
|
18
|
+
};
|
|
19
|
+
slots: {
|
|
20
|
+
default: {};
|
|
21
|
+
};
|
|
22
|
+
};
|
|
23
|
+
export {};
|
package/forms/Radio.svelte
CHANGED
|
@@ -1,16 +1,59 @@
|
|
|
1
|
-
<script>export let divClass = 'flex items-center
|
|
1
|
+
<script>export let divClass = 'flex items-center mr-4';
|
|
2
2
|
export let inputClass = 'w-4 h-4 border-gray-300 focus:ring-2 focus:ring-blue-300 dark:focus:ring-blue-600 dark:focus:bg-blue-600 dark:bg-gray-700 dark:border-gray-600';
|
|
3
3
|
export let labelClass = 'block ml-2 text-sm font-medium text-gray-900 dark:text-gray-300';
|
|
4
|
-
export let
|
|
5
|
-
|
|
4
|
+
export let disabled = false;
|
|
5
|
+
if (disabled) {
|
|
6
|
+
labelClass = 'ml-2 text-sm font-medium text-gray-400 dark:text-gray-500';
|
|
7
|
+
}
|
|
8
|
+
export let name = '';
|
|
9
|
+
export let divHelperClass = 'flex items-center h-5';
|
|
10
|
+
export let labelHelperClass = 'font-medium text-gray-900 dark:text-gray-300';
|
|
11
|
+
export let helperClass = 'text-xs font-normal text-gray-500 dark:text-gray-300';
|
|
12
|
+
export let color = 'blue';
|
|
13
|
+
if (color === 'red') {
|
|
14
|
+
inputClass = 'w-4 h-4 text-red-600 bg-gray-100 border-gray-300 focus:ring-red-500 dark:focus:ring-red-600 dark:ring-offset-gray-800 focus:ring-2 dark:bg-gray-700 dark:border-gray-600';
|
|
15
|
+
}
|
|
16
|
+
else if (color === 'green') {
|
|
17
|
+
inputClass = 'w-4 h-4 text-green-600 bg-gray-100 border-gray-300 focus:ring-green-500 dark:focus:ring-green-600 dark:ring-offset-gray-800 focus:ring-2 dark:bg-gray-700 dark:border-gray-600';
|
|
18
|
+
}
|
|
19
|
+
else if (color === 'purple') {
|
|
20
|
+
inputClass = 'w-4 h-4 text-purple-600 bg-gray-100 border-gray-300 focus:ring-purple-500 dark:focus:ring-purple-600 dark:ring-offset-gray-800 focus:ring-2 dark:bg-gray-700 dark:border-gray-600';
|
|
21
|
+
}
|
|
22
|
+
else if (color === 'teal') {
|
|
23
|
+
inputClass = 'w-4 h-4 text-teal-600 bg-gray-100 border-gray-300 focus:ring-teal-500 dark:focus:ring-teal-600 dark:ring-offset-gray-800 focus:ring-2 dark:bg-gray-700 dark:border-gray-600';
|
|
24
|
+
}
|
|
25
|
+
else if (color === 'yellow') {
|
|
26
|
+
inputClass = 'w-4 h-4 text-yellow-400 bg-gray-100 border-gray-300 focus:ring-yellow-500 dark:focus:ring-yellow-600 dark:ring-offset-gray-800 focus:ring-2 dark:bg-gray-700 dark:border-gray-600';
|
|
27
|
+
}
|
|
28
|
+
else if (color === 'orange') {
|
|
29
|
+
inputClass = 'w-4 h-4 text-orange-500 bg-gray-100 border-gray-300 focus:ring-orange-500 dark:focus:ring-orange-600 dark:ring-offset-gray-800 focus:ring-2 dark:bg-gray-700 dark:border-gray-600';
|
|
30
|
+
}
|
|
31
|
+
else {
|
|
32
|
+
inputClass = 'w-4 h-4 border-gray-300 focus:ring-2 focus:ring-blue-300 dark:focus:ring-blue-600 dark:focus:bg-blue-600 dark:bg-gray-700 dark:border-gray-600';
|
|
33
|
+
}
|
|
34
|
+
export let helper;
|
|
35
|
+
export let id;
|
|
36
|
+
export let value;
|
|
37
|
+
export let label;
|
|
6
38
|
</script>
|
|
7
39
|
|
|
8
|
-
{#
|
|
40
|
+
{#if helper}
|
|
41
|
+
<div class="flex">
|
|
42
|
+
<div class={divHelperClass}>
|
|
43
|
+
<input {id} type="radio" {name} {value} class={inputClass} aria-labelledby={id} aria-describedby={id} {disabled} {...$$restProps} />
|
|
44
|
+
</div>
|
|
45
|
+
<div class="ml-2 text-sm">
|
|
46
|
+
<label for={id} class={labelHelperClass}>
|
|
47
|
+
{@html label}
|
|
48
|
+
</label>
|
|
49
|
+
<p id="{id}-helper-radio-text" class={helperClass}>{helper}</p>
|
|
50
|
+
</div>
|
|
51
|
+
</div>
|
|
52
|
+
{:else}
|
|
9
53
|
<div class={divClass}>
|
|
10
|
-
<input
|
|
11
|
-
<label for={
|
|
12
|
-
{@html
|
|
54
|
+
<input {id} type="radio" {name} {value} class={inputClass} aria-labelledby={id} aria-describedby={id} {disabled} {...$$restProps} />
|
|
55
|
+
<label for={id} class={labelClass}>
|
|
56
|
+
{@html label}
|
|
13
57
|
</label>
|
|
14
|
-
<slot name="helper" />
|
|
15
58
|
</div>
|
|
16
|
-
{/
|
|
59
|
+
{/if}
|
package/forms/Radio.svelte.d.ts
CHANGED
|
@@ -1,19 +1,26 @@
|
|
|
1
1
|
import { SvelteComponentTyped } from "svelte";
|
|
2
|
-
import type {
|
|
2
|
+
import type { FormColorType } from '../types';
|
|
3
3
|
declare const __propDef: {
|
|
4
4
|
props: {
|
|
5
|
+
[x: string]: any;
|
|
5
6
|
divClass?: string;
|
|
6
7
|
inputClass?: string;
|
|
7
8
|
labelClass?: string;
|
|
9
|
+
disabled?: boolean;
|
|
8
10
|
name?: string;
|
|
9
|
-
|
|
11
|
+
divHelperClass?: string;
|
|
12
|
+
labelHelperClass?: string;
|
|
13
|
+
helperClass?: string;
|
|
14
|
+
color?: FormColorType;
|
|
15
|
+
helper: string;
|
|
16
|
+
id: string;
|
|
17
|
+
value: string;
|
|
18
|
+
label: string;
|
|
10
19
|
};
|
|
11
20
|
events: {
|
|
12
21
|
[evt: string]: CustomEvent<any>;
|
|
13
22
|
};
|
|
14
|
-
slots: {
|
|
15
|
-
helper: {};
|
|
16
|
-
};
|
|
23
|
+
slots: {};
|
|
17
24
|
};
|
|
18
25
|
export declare type RadioProps = typeof __propDef.props;
|
|
19
26
|
export declare type RadioEvents = typeof __propDef.events;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/** @typedef {typeof __propDef.props} RadioInlineProps */
|
|
2
|
+
/** @typedef {typeof __propDef.events} RadioInlineEvents */
|
|
3
|
+
/** @typedef {typeof __propDef.slots} RadioInlineSlots */
|
|
4
|
+
export default class RadioInline extends SvelteComponentTyped<{}, {
|
|
5
|
+
[evt: string]: CustomEvent<any>;
|
|
6
|
+
}, {
|
|
7
|
+
default: {};
|
|
8
|
+
}> {
|
|
9
|
+
}
|
|
10
|
+
export type RadioInlineProps = typeof __propDef.props;
|
|
11
|
+
export type RadioInlineEvents = typeof __propDef.events;
|
|
12
|
+
export type RadioInlineSlots = typeof __propDef.slots;
|
|
13
|
+
import { SvelteComponentTyped } from "svelte";
|
|
14
|
+
declare const __propDef: {
|
|
15
|
+
props: {};
|
|
16
|
+
events: {
|
|
17
|
+
[evt: string]: CustomEvent<any>;
|
|
18
|
+
};
|
|
19
|
+
slots: {
|
|
20
|
+
default: {};
|
|
21
|
+
};
|
|
22
|
+
};
|
|
23
|
+
export {};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
<script>export let id = '';
|
|
2
|
+
export let labelClass = 'mb-2 text-sm font-medium text-gray-900 sr-only dark:text-gray-300';
|
|
3
|
+
export let inputClass = 'block p-4 pl-10 w-full text-sm text-gray-900 bg-gray-50 rounded-lg border border-gray-300 focus:ring-blue-500 focus:border-blue-500 dark:bg-gray-700 dark:border-gray-600 dark:placeholder-gray-400 dark:text-white dark:focus:ring-blue-500 dark:focus:border-blue-500';
|
|
4
|
+
export let btnClass = 'text-white absolute right-2.5 bottom-2.5 bg-blue-700 hover:bg-blue-800 focus:ring-4 focus:outline-none focus:ring-blue-300 font-medium rounded-lg text-sm px-4 py-2 dark:bg-blue-600 dark:hover:bg-blue-700 dark:focus:ring-blue-800';
|
|
5
|
+
export let placeholder = 'Search';
|
|
6
|
+
</script>
|
|
7
|
+
|
|
8
|
+
<form on:submit>
|
|
9
|
+
<label for={id} class={labelClass}>Search</label>
|
|
10
|
+
<div class="relative">
|
|
11
|
+
<div class="flex absolute inset-y-0 left-0 items-center pl-3 pointer-events-none">
|
|
12
|
+
<svg class="w-5 h-5 text-gray-500 dark:text-gray-400" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M21 21l-6-6m2-5a7 7 0 11-14 0 7 7 0 0114 0z" /></svg>
|
|
13
|
+
</div>
|
|
14
|
+
<input type="search" {id} class={inputClass} {placeholder} {...$$restProps} />
|
|
15
|
+
<button type="submit" class={btnClass}>Search</button>
|
|
16
|
+
</div>
|
|
17
|
+
</form>
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { SvelteComponentTyped } from "svelte";
|
|
2
|
+
declare const __propDef: {
|
|
3
|
+
props: {
|
|
4
|
+
[x: string]: any;
|
|
5
|
+
id?: string;
|
|
6
|
+
labelClass?: string;
|
|
7
|
+
inputClass?: string;
|
|
8
|
+
btnClass?: string;
|
|
9
|
+
placeholder?: string;
|
|
10
|
+
};
|
|
11
|
+
events: {
|
|
12
|
+
submit: SubmitEvent;
|
|
13
|
+
} & {
|
|
14
|
+
[evt: string]: CustomEvent<any>;
|
|
15
|
+
};
|
|
16
|
+
slots: {};
|
|
17
|
+
};
|
|
18
|
+
export declare type SearchProps = typeof __propDef.props;
|
|
19
|
+
export declare type SearchEvents = typeof __propDef.events;
|
|
20
|
+
export declare type SearchSlots = typeof __propDef.slots;
|
|
21
|
+
export default class Search extends SvelteComponentTyped<SearchProps, SearchEvents, SearchSlots> {
|
|
22
|
+
}
|
|
23
|
+
export {};
|
package/index.js
CHANGED
|
@@ -58,13 +58,15 @@ export { default as SitemapFooter } from './footer/SitemapFooter.svelte'
|
|
|
58
58
|
|
|
59
59
|
// Forms
|
|
60
60
|
export { default as Checkbox } from './forms/Checkbox.svelte'
|
|
61
|
+
export { default as CheckboxInline } from './forms/CheckboxInline.svelte'
|
|
61
62
|
export { default as Fileupload } from './forms/Fileupload.svelte'
|
|
62
63
|
export { default as FloatingLabelInput } from './forms/FloatingLabelInput.svelte'
|
|
63
64
|
export { default as Iconinput } from './forms/Iconinput.svelte'
|
|
64
65
|
export { default as Input } from './forms/Input.svelte'
|
|
66
|
+
export { default as RadioInline } from './forms/RadioInline.svelte'
|
|
65
67
|
export { default as Radio } from './forms/Radio.svelte'
|
|
66
68
|
export { default as Range } from './forms/Range.svelte'
|
|
67
|
-
export { default as
|
|
69
|
+
export { default as Search } from './forms/Search.svelte'
|
|
68
70
|
export { default as Select } from './forms/Select.svelte'
|
|
69
71
|
export { default as Textarea } from './forms/Textarea.svelte'
|
|
70
72
|
export { default as Toggle } from './forms/Toggle.svelte'
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "flowbite-svelte",
|
|
3
|
-
"version": "0.15.
|
|
3
|
+
"version": "0.15.13",
|
|
4
4
|
"description": "Flowbite components for Svelte",
|
|
5
5
|
"main": "./package/index.js",
|
|
6
6
|
"author": {
|
|
@@ -124,14 +124,16 @@
|
|
|
124
124
|
"./footer/SitemapFooter.svelte": "./footer/SitemapFooter.svelte",
|
|
125
125
|
"./footer/SocialMediaFooter.svelte": "./footer/SocialMediaFooter.svelte",
|
|
126
126
|
"./forms/Checkbox.svelte": "./forms/Checkbox.svelte",
|
|
127
|
+
"./forms/CheckboxInline.svelte": "./forms/CheckboxInline.svelte",
|
|
127
128
|
"./forms/Fileupload.svelte": "./forms/Fileupload.svelte",
|
|
128
129
|
"./forms/FloatingLabelInput.svelte": "./forms/FloatingLabelInput.svelte",
|
|
129
130
|
"./forms/Iconinput.svelte": "./forms/Iconinput.svelte",
|
|
130
131
|
"./forms/Input.svelte": "./forms/Input.svelte",
|
|
131
132
|
"./forms/Radio.svelte": "./forms/Radio.svelte",
|
|
133
|
+
"./forms/RadioInline.svelte": "./forms/RadioInline.svelte",
|
|
132
134
|
"./forms/Range.svelte": "./forms/Range.svelte",
|
|
135
|
+
"./forms/Search.svelte": "./forms/Search.svelte",
|
|
133
136
|
"./forms/Select.svelte": "./forms/Select.svelte",
|
|
134
|
-
"./forms/SingleCheckbox.svelte": "./forms/SingleCheckbox.svelte",
|
|
135
137
|
"./forms/Textarea.svelte": "./forms/Textarea.svelte",
|
|
136
138
|
"./forms/Toggle.svelte": "./forms/Toggle.svelte",
|
|
137
139
|
".": "./index.js",
|
package/types.d.ts
CHANGED
|
@@ -64,6 +64,7 @@ export interface DropdownType {
|
|
|
64
64
|
href: string;
|
|
65
65
|
divider?: boolean;
|
|
66
66
|
}
|
|
67
|
+
export declare type FormColorType = 'blue' | 'red' | 'green' | 'purple' | 'teal' | 'yellow' | 'orange';
|
|
67
68
|
export declare type Gradientduotones = 'purple2blue' | 'cyan2blue' | 'green2blue' | 'purple2pink' | 'pink2orange' | 'teal2lime' | 'red2yellow';
|
|
68
69
|
export interface GroupTimelineType {
|
|
69
70
|
title: string | HTMLElement;
|
|
@@ -117,13 +118,6 @@ export interface PillTabType {
|
|
|
117
118
|
selected: boolean;
|
|
118
119
|
href: string;
|
|
119
120
|
}
|
|
120
|
-
export interface RadioType {
|
|
121
|
-
id: string;
|
|
122
|
-
label: string | HTMLElement;
|
|
123
|
-
value: string;
|
|
124
|
-
checked?: boolean;
|
|
125
|
-
disabled?: boolean;
|
|
126
|
-
}
|
|
127
121
|
export declare type SelectOptionType = {
|
|
128
122
|
name: string;
|
|
129
123
|
value: string;
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
<script>import generateId from '../utils/generateId.js';
|
|
2
|
-
export let checked = false;
|
|
3
|
-
export let id = generateId();
|
|
4
|
-
export let required = false;
|
|
5
|
-
export let label;
|
|
6
|
-
export let name;
|
|
7
|
-
export let inputClass = 'w-4 h-4 bg-gray-50 rounded border border-gray-300 focus:ring-3 focus:ring-blue-300 dark:bg-gray-700 dark:border-gray-600 dark:focus:ring-blue-600 dark:ring-offset-gray-800';
|
|
8
|
-
export let labelClass = 'font-medium text-gray-900 dark:text-gray-300';
|
|
9
|
-
</script>
|
|
10
|
-
|
|
11
|
-
<div class="flex items-start">
|
|
12
|
-
<div class="flex items-center h-5">
|
|
13
|
-
<input bind:checked {id} aria-describedby={id} {name} type="checkbox" class={inputClass} {required} />
|
|
14
|
-
</div>
|
|
15
|
-
<div class="ml-3 text-sm">
|
|
16
|
-
<label for={id} class={labelClass}>{label}</label>
|
|
17
|
-
</div>
|
|
18
|
-
</div>
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import { SvelteComponentTyped } from "svelte";
|
|
2
|
-
declare const __propDef: {
|
|
3
|
-
props: {
|
|
4
|
-
checked?: boolean;
|
|
5
|
-
id?: string;
|
|
6
|
-
required?: boolean;
|
|
7
|
-
label: string;
|
|
8
|
-
name: string;
|
|
9
|
-
inputClass?: string;
|
|
10
|
-
labelClass?: string;
|
|
11
|
-
};
|
|
12
|
-
events: {
|
|
13
|
-
[evt: string]: CustomEvent<any>;
|
|
14
|
-
};
|
|
15
|
-
slots: {};
|
|
16
|
-
};
|
|
17
|
-
export declare type SingleCheckboxProps = typeof __propDef.props;
|
|
18
|
-
export declare type SingleCheckboxEvents = typeof __propDef.events;
|
|
19
|
-
export declare type SingleCheckboxSlots = typeof __propDef.slots;
|
|
20
|
-
export default class SingleCheckbox extends SvelteComponentTyped<SingleCheckboxProps, SingleCheckboxEvents, SingleCheckboxSlots> {
|
|
21
|
-
}
|
|
22
|
-
export {};
|