flowbite-svelte 0.21.14 → 0.21.17
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 +3 -1
- package/forms/Checkbox.svelte.d.ts +3 -0
- package/forms/Radio.svelte +3 -2
- package/forms/Radio.svelte.d.ts +3 -0
- package/forms/Toggle.svelte +1 -1
- package/forms/Toggle.svelte.d.ts +2 -0
- package/package.json +1 -1
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.21.17](https://github.com/themesberg/flowbite-svelte/compare/v0.21.16...v0.21.17) (2022-07-20)
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
### Bug Fixes
|
|
9
|
+
|
|
10
|
+
* Checkbox on:click position ([cfb1c65](https://github.com/themesberg/flowbite-svelte/commit/cfb1c658ae971bb689cd4e01f797ccc5c11db991))
|
|
11
|
+
* on:click for Toggle, Checkbox and Radio ([48710b5](https://github.com/themesberg/flowbite-svelte/commit/48710b59c9a9096ec95dfa26d1764a312552b49e))
|
|
12
|
+
|
|
13
|
+
### [0.21.16](https://github.com/themesberg/flowbite-svelte/compare/v0.21.14...v0.21.16) (2022-07-20)
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
### Bug Fixes
|
|
17
|
+
|
|
18
|
+
* dropdown search ([4416a31](https://github.com/themesberg/flowbite-svelte/commit/4416a312756331f6dd04b1d5fe5dd61b764fd38d))
|
|
19
|
+
* padding issues with dropdown ([6a48d4d](https://github.com/themesberg/flowbite-svelte/commit/6a48d4dc6a262fc62aa2d9b4c6233bf1cee4b741))
|
|
20
|
+
* padding issues with dropdown ([8e8c2d4](https://github.com/themesberg/flowbite-svelte/commit/8e8c2d4bed3e85e95c28e936c513489e6d975e8f))
|
|
21
|
+
|
|
22
|
+
### [0.21.15](https://github.com/themesberg/flowbite-svelte/compare/v0.21.14...v0.21.15) (2022-07-20)
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
### Bug Fixes
|
|
26
|
+
|
|
27
|
+
* dropdown search ([4416a31](https://github.com/themesberg/flowbite-svelte/commit/4416a312756331f6dd04b1d5fe5dd61b764fd38d))
|
|
28
|
+
* padding issues with dropdown ([6a48d4d](https://github.com/themesberg/flowbite-svelte/commit/6a48d4dc6a262fc62aa2d9b4c6233bf1cee4b741))
|
|
29
|
+
* padding issues with dropdown ([8e8c2d4](https://github.com/themesberg/flowbite-svelte/commit/8e8c2d4bed3e85e95c28e936c513489e6d975e8f))
|
|
30
|
+
|
|
5
31
|
### [0.21.14](https://github.com/themesberg/flowbite-svelte/compare/v0.21.13...v0.21.14) (2022-07-19)
|
|
6
32
|
|
|
7
33
|
|
package/forms/Checkbox.svelte
CHANGED
|
@@ -27,10 +27,12 @@ let inputClass; // get the value from the underlying Radio
|
|
|
27
27
|
export let custom = false;
|
|
28
28
|
export let color = 'blue';
|
|
29
29
|
export let inline = false;
|
|
30
|
+
export let tinted = false;
|
|
30
31
|
</script>
|
|
31
32
|
|
|
32
|
-
<Radio class={$$restProps.class} bind:inputClass {color} {custom} {inline}>
|
|
33
|
+
<Radio class={$$restProps.class} bind:inputClass {color} {custom} {inline} {tinted}>
|
|
33
34
|
<input
|
|
35
|
+
on:click
|
|
34
36
|
slot="input"
|
|
35
37
|
type="checkbox"
|
|
36
38
|
bind:checked
|
package/forms/Radio.svelte
CHANGED
|
@@ -15,10 +15,11 @@ import classNames from 'classnames';
|
|
|
15
15
|
export let color = 'blue';
|
|
16
16
|
export let custom = false;
|
|
17
17
|
export let inline = false;
|
|
18
|
+
export let tinted = false;
|
|
18
19
|
export let group = '';
|
|
19
20
|
export let value = '';
|
|
20
21
|
export let inputClass;
|
|
21
|
-
$: inputClass = classNames('w-4 h-4 bg-gray-100 border-gray-300 dark:ring-offset-gray-800 focus:ring-2 dark:bg-gray-700 dark:border-gray-600
|
|
22
|
+
$: inputClass = classNames('w-4 h-4 bg-gray-100 border-gray-300 dark:ring-offset-gray-800 focus:ring-2 mr-2', tinted ? 'dark:bg-gray-600 dark:border-gray-500' : 'dark:bg-gray-700 dark:border-gray-600', custom && 'sr-only peer', colorClasses[color]);
|
|
22
23
|
let colorLabel = 'gray';
|
|
23
24
|
$: colorLabel = $$restProps.disabled ? 'disabled' : colorLabel;
|
|
24
25
|
let labelClass;
|
|
@@ -43,7 +44,7 @@ const colorClasses = {
|
|
|
43
44
|
<!-- svelte-ignore a11y-label-has-associated-control -->
|
|
44
45
|
<label class={labelClass}>
|
|
45
46
|
<slot name="input">
|
|
46
|
-
<input type="radio" bind:group {value} {...$$restProps} class={inputClass} />
|
|
47
|
+
<input on:click type="radio" bind:group {value} {...$$restProps} class={inputClass} />
|
|
47
48
|
</slot>
|
|
48
49
|
<slot />
|
|
49
50
|
</label>
|
package/forms/Radio.svelte.d.ts
CHANGED
|
@@ -6,11 +6,14 @@ declare const __propDef: {
|
|
|
6
6
|
color?: FormColorType;
|
|
7
7
|
custom?: boolean;
|
|
8
8
|
inline?: boolean;
|
|
9
|
+
tinted?: boolean;
|
|
9
10
|
group?: number | string;
|
|
10
11
|
value?: string;
|
|
11
12
|
inputClass: string;
|
|
12
13
|
};
|
|
13
14
|
events: {
|
|
15
|
+
click: MouseEvent;
|
|
16
|
+
} & {
|
|
14
17
|
[evt: string]: CustomEvent<any>;
|
|
15
18
|
};
|
|
16
19
|
slots: {
|
package/forms/Toggle.svelte
CHANGED
|
@@ -18,7 +18,7 @@ const sizes = {
|
|
|
18
18
|
};
|
|
19
19
|
</script>
|
|
20
20
|
|
|
21
|
-
<Checkbox custom class="relative {$$restProps.class}" {...$$restProps}>
|
|
21
|
+
<Checkbox on:click custom class="relative {$$restProps.class}" {...$$restProps}>
|
|
22
22
|
<div class={classNames(common, colors[$$restProps.color ?? 'blue'], sizes[size])} />
|
|
23
23
|
<slot />
|
|
24
24
|
</Checkbox>
|
package/forms/Toggle.svelte.d.ts
CHANGED