simplesvelte 2.2.23 → 2.4.0
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/README.md +214 -214
- package/dist/AG_GRID_SERVER_API.md +373 -373
- package/dist/Grid.svelte +129 -129
- package/dist/Input.svelte +142 -142
- package/dist/Label.svelte +43 -43
- package/dist/Modal.svelte +39 -39
- package/dist/Select.svelte +605 -472
- package/dist/Select.svelte.d.ts +7 -2
- package/dist/TextArea.svelte +43 -43
- package/dist/styles.css +15 -10
- package/package.json +21 -21
package/dist/Select.svelte.d.ts
CHANGED
|
@@ -1,12 +1,17 @@
|
|
|
1
|
-
type
|
|
1
|
+
export type SelectOption = {
|
|
2
2
|
value: any;
|
|
3
3
|
label: any;
|
|
4
4
|
group?: string;
|
|
5
5
|
[key: string]: any;
|
|
6
6
|
};
|
|
7
|
+
export type SelectFetchParams = {
|
|
8
|
+
filter: string | undefined;
|
|
9
|
+
};
|
|
7
10
|
type Props = {
|
|
8
11
|
value?: string | number | undefined | null | (string | number)[];
|
|
9
|
-
options
|
|
12
|
+
options?: SelectOption[];
|
|
13
|
+
fetchOptions?: (params: SelectFetchParams) => Promise<SelectOption[]>;
|
|
14
|
+
debounceMs?: number;
|
|
10
15
|
name?: string;
|
|
11
16
|
label?: string;
|
|
12
17
|
class?: string;
|
package/dist/TextArea.svelte
CHANGED
|
@@ -1,43 +1,43 @@
|
|
|
1
|
-
<script lang="ts">
|
|
2
|
-
import Label from './Label.svelte'
|
|
3
|
-
|
|
4
|
-
type Props = {
|
|
5
|
-
value?: any
|
|
6
|
-
name?: string
|
|
7
|
-
label?: string
|
|
8
|
-
class?: string
|
|
9
|
-
required?: boolean
|
|
10
|
-
disabled?: boolean
|
|
11
|
-
element?: HTMLElement
|
|
12
|
-
error?: string
|
|
13
|
-
zodErrors?: {
|
|
14
|
-
expected: string
|
|
15
|
-
code: string
|
|
16
|
-
path: string[]
|
|
17
|
-
message: string
|
|
18
|
-
}[]
|
|
19
|
-
[x: string]: any
|
|
20
|
-
}
|
|
21
|
-
let {
|
|
22
|
-
value = $bindable(),
|
|
23
|
-
element = $bindable(),
|
|
24
|
-
label,
|
|
25
|
-
name,
|
|
26
|
-
required,
|
|
27
|
-
disabled,
|
|
28
|
-
class: myClass,
|
|
29
|
-
error,
|
|
30
|
-
zodErrors,
|
|
31
|
-
...rest
|
|
32
|
-
}: Props = $props()
|
|
33
|
-
const errorText = $derived.by(() => {
|
|
34
|
-
if (error) return error
|
|
35
|
-
if (!name) return undefined
|
|
36
|
-
if (zodErrors) return zodErrors.find((e) => e.path.includes(name))?.message
|
|
37
|
-
return undefined
|
|
38
|
-
})
|
|
39
|
-
</script>
|
|
40
|
-
|
|
41
|
-
<Label class={myClass} {label} {name} optional={!required} {disabled} error={errorText}>
|
|
42
|
-
<textarea bind:this={element} {disabled} {name} {required} class="textarea w-full" {...rest} bind:value></textarea>
|
|
43
|
-
</Label>
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import Label from './Label.svelte'
|
|
3
|
+
|
|
4
|
+
type Props = {
|
|
5
|
+
value?: any
|
|
6
|
+
name?: string
|
|
7
|
+
label?: string
|
|
8
|
+
class?: string
|
|
9
|
+
required?: boolean
|
|
10
|
+
disabled?: boolean
|
|
11
|
+
element?: HTMLElement
|
|
12
|
+
error?: string
|
|
13
|
+
zodErrors?: {
|
|
14
|
+
expected: string
|
|
15
|
+
code: string
|
|
16
|
+
path: string[]
|
|
17
|
+
message: string
|
|
18
|
+
}[]
|
|
19
|
+
[x: string]: any
|
|
20
|
+
}
|
|
21
|
+
let {
|
|
22
|
+
value = $bindable(),
|
|
23
|
+
element = $bindable(),
|
|
24
|
+
label,
|
|
25
|
+
name,
|
|
26
|
+
required,
|
|
27
|
+
disabled,
|
|
28
|
+
class: myClass,
|
|
29
|
+
error,
|
|
30
|
+
zodErrors,
|
|
31
|
+
...rest
|
|
32
|
+
}: Props = $props()
|
|
33
|
+
const errorText = $derived.by(() => {
|
|
34
|
+
if (error) return error
|
|
35
|
+
if (!name) return undefined
|
|
36
|
+
if (zodErrors) return zodErrors.find((e) => e.path.includes(name))?.message
|
|
37
|
+
return undefined
|
|
38
|
+
})
|
|
39
|
+
</script>
|
|
40
|
+
|
|
41
|
+
<Label class={myClass} {label} {name} optional={!required} {disabled} error={errorText}>
|
|
42
|
+
<textarea bind:this={element} {disabled} {name} {required} class="textarea w-full" {...rest} bind:value></textarea>
|
|
43
|
+
</Label>
|
package/dist/styles.css
CHANGED
|
@@ -1,10 +1,15 @@
|
|
|
1
|
-
@import 'tailwindcss';
|
|
2
|
-
@plugin "daisyui";
|
|
3
|
-
|
|
4
|
-
html,
|
|
5
|
-
body {
|
|
6
|
-
display: flex;
|
|
7
|
-
flex-direction: column;
|
|
8
|
-
height: 100%;
|
|
9
|
-
background-color: var(--color-base-200);
|
|
10
|
-
}
|
|
1
|
+
@import 'tailwindcss';
|
|
2
|
+
@plugin "daisyui";
|
|
3
|
+
|
|
4
|
+
html,
|
|
5
|
+
body {
|
|
6
|
+
display: flex;
|
|
7
|
+
flex-direction: column;
|
|
8
|
+
height: 100%;
|
|
9
|
+
background-color: var(--color-base-200);
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
/* Ensure popover elements are hidden by default - use !important to override menu display:flex */
|
|
13
|
+
[popover]:not(:popover-open) {
|
|
14
|
+
display: none !important;
|
|
15
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "simplesvelte",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.4.0",
|
|
4
4
|
"scripts": {
|
|
5
5
|
"dev": "bun vite dev",
|
|
6
6
|
"build": "bun vite build && bun run prepack",
|
|
@@ -36,31 +36,31 @@
|
|
|
36
36
|
},
|
|
37
37
|
"devDependencies": {
|
|
38
38
|
"@eslint/compat": "^1.4.1",
|
|
39
|
-
"@eslint/js": "^9.39.
|
|
40
|
-
"@sveltejs/adapter-cloudflare": "^7.2.
|
|
41
|
-
"@sveltejs/kit": "^2.
|
|
42
|
-
"@sveltejs/package": "^2.5.
|
|
43
|
-
"@sveltejs/vite-plugin-svelte": "^6.2.
|
|
44
|
-
"@tailwindcss/cli": "^4.1.
|
|
45
|
-
"@tailwindcss/vite": "^4.1.
|
|
46
|
-
"@testing-library/svelte": "^5.
|
|
39
|
+
"@eslint/js": "^9.39.2",
|
|
40
|
+
"@sveltejs/adapter-cloudflare": "^7.2.5",
|
|
41
|
+
"@sveltejs/kit": "^2.50.0",
|
|
42
|
+
"@sveltejs/package": "^2.5.7",
|
|
43
|
+
"@sveltejs/vite-plugin-svelte": "^6.2.4",
|
|
44
|
+
"@tailwindcss/cli": "^4.1.18",
|
|
45
|
+
"@tailwindcss/vite": "^4.1.18",
|
|
46
|
+
"@testing-library/svelte": "^5.3.1",
|
|
47
47
|
"@testing-library/user-event": "^14.6.1",
|
|
48
|
-
"daisyui": "^5.
|
|
49
|
-
"eslint": "^9.39.
|
|
48
|
+
"daisyui": "^5.5.14",
|
|
49
|
+
"eslint": "^9.39.2",
|
|
50
50
|
"eslint-config-prettier": "^10.1.8",
|
|
51
|
-
"eslint-plugin-svelte": "^3.
|
|
51
|
+
"eslint-plugin-svelte": "^3.14.0",
|
|
52
52
|
"globals": "^16.5.0",
|
|
53
|
-
"jsdom": "^27.
|
|
54
|
-
"prettier": "^3.
|
|
55
|
-
"prettier-plugin-svelte": "^3.4.
|
|
53
|
+
"jsdom": "^27.4.0",
|
|
54
|
+
"prettier": "^3.8.1",
|
|
55
|
+
"prettier-plugin-svelte": "^3.4.1",
|
|
56
56
|
"prettier-plugin-tailwindcss": "^0.6.14",
|
|
57
|
-
"publint": "^0.3.
|
|
58
|
-
"svelte": "^5.
|
|
59
|
-
"svelte-check": "^4.3.
|
|
60
|
-
"tailwindcss": "^4.1.
|
|
57
|
+
"publint": "^0.3.17",
|
|
58
|
+
"svelte": "^5.47.1",
|
|
59
|
+
"svelte-check": "^4.3.5",
|
|
60
|
+
"tailwindcss": "^4.1.18",
|
|
61
61
|
"typescript": "^5.9.3",
|
|
62
|
-
"typescript-eslint": "^8.
|
|
63
|
-
"vite": "^7.1
|
|
62
|
+
"typescript-eslint": "^8.53.1",
|
|
63
|
+
"vite": "^7.3.1",
|
|
64
64
|
"vitest": "^3.2.4"
|
|
65
65
|
},
|
|
66
66
|
"keywords": [
|