ui-ingredients 0.6.0 → 0.7.0
Sign up to get free protection for your applications and to get access to all the features.
@@ -25,7 +25,6 @@ export function createField(props) {
|
|
25
25
|
readOnly: props.readOnly ?? false,
|
26
26
|
};
|
27
27
|
});
|
28
|
-
let focused = $state(false);
|
29
28
|
let hasErrorText = $state(false);
|
30
29
|
let hasHelperText = $state(false);
|
31
30
|
const ariaDescribedby = $derived.by(() => {
|
@@ -47,7 +46,6 @@ export function createField(props) {
|
|
47
46
|
'data-disabled': dataAttr(disabled),
|
48
47
|
'data-required': dataAttr(required),
|
49
48
|
'data-readonly': dataAttr(readOnly),
|
50
|
-
'data-focus': dataAttr(focused),
|
51
49
|
};
|
52
50
|
}
|
53
51
|
function getLabelProps() {
|
@@ -59,7 +57,6 @@ export function createField(props) {
|
|
59
57
|
'data-disabled': dataAttr(disabled),
|
60
58
|
'data-required': dataAttr(required),
|
61
59
|
'data-readonly': dataAttr(readOnly),
|
62
|
-
'data-focus': dataAttr(focused),
|
63
60
|
};
|
64
61
|
}
|
65
62
|
function getRequiredIndicatorProps() {
|
@@ -70,7 +67,6 @@ export function createField(props) {
|
|
70
67
|
'data-invalid': dataAttr(invalid),
|
71
68
|
'data-disabled': dataAttr(disabled),
|
72
69
|
'data-readonly': dataAttr(readOnly),
|
73
|
-
'data-focus': dataAttr(focused),
|
74
70
|
};
|
75
71
|
}
|
76
72
|
function getErrorTextProps() {
|
@@ -83,7 +79,6 @@ export function createField(props) {
|
|
83
79
|
'data-disabled': dataAttr(disabled),
|
84
80
|
'data-required': dataAttr(required),
|
85
81
|
'data-readonly': dataAttr(readOnly),
|
86
|
-
'data-focus': dataAttr(focused),
|
87
82
|
};
|
88
83
|
}
|
89
84
|
function getHelperTextProps() {
|
@@ -94,20 +89,11 @@ export function createField(props) {
|
|
94
89
|
'data-disabled': dataAttr(disabled),
|
95
90
|
'data-required': dataAttr(required),
|
96
91
|
'data-readonly': dataAttr(readOnly),
|
97
|
-
'data-focus': dataAttr(focused),
|
98
92
|
};
|
99
93
|
}
|
100
|
-
function onfocus() {
|
101
|
-
focused = true;
|
102
|
-
}
|
103
|
-
function onblur() {
|
104
|
-
focused = false;
|
105
|
-
}
|
106
94
|
function getControlProps() {
|
107
95
|
return {
|
108
96
|
id: ids.control,
|
109
|
-
onfocus,
|
110
|
-
onblur,
|
111
97
|
disabled,
|
112
98
|
required,
|
113
99
|
'aria-describedby': ariaDescribedby,
|
@@ -119,7 +105,6 @@ export function createField(props) {
|
|
119
105
|
'data-disabled': dataAttr(disabled),
|
120
106
|
'data-required': dataAttr(required),
|
121
107
|
'data-readonly': dataAttr(readOnly),
|
122
|
-
'data-focus': dataAttr(focused),
|
123
108
|
};
|
124
109
|
}
|
125
110
|
function getInputProps() {
|
@@ -161,7 +146,6 @@ export function createField(props) {
|
|
161
146
|
required,
|
162
147
|
readOnly,
|
163
148
|
invalid,
|
164
|
-
focused,
|
165
149
|
'aria-describedby': ariaDescribedby,
|
166
150
|
getRootProps,
|
167
151
|
getLabelProps,
|
package/package.json
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
"name": "ui-ingredients",
|
3
3
|
"type": "module",
|
4
4
|
"license": "MIT",
|
5
|
-
"version": "0.
|
5
|
+
"version": "0.7.0",
|
6
6
|
"packageManager": "pnpm@9.7.0",
|
7
7
|
"svelte": "./dist/index.js",
|
8
8
|
"types": "./dist/index.d.ts",
|
@@ -365,29 +365,29 @@
|
|
365
365
|
"devDependencies": {
|
366
366
|
"@faker-js/faker": "^9.0.3",
|
367
367
|
"@sveltejs/adapter-vercel": "^5.4.5",
|
368
|
-
"@sveltejs/kit": "^2.7.
|
368
|
+
"@sveltejs/kit": "^2.7.1",
|
369
369
|
"@sveltejs/package": "^2.3.5",
|
370
370
|
"@sveltejs/vite-plugin-svelte": "^4.0.0-next.6",
|
371
371
|
"@testing-library/jest-dom": "^6.5.0",
|
372
372
|
"@testing-library/svelte": "^5.2.3",
|
373
373
|
"@testing-library/user-event": "^14.5.2",
|
374
374
|
"@types/jsdom": "^21.1.7",
|
375
|
-
"@untitled-theme/icons-svelte": "^0.10.
|
375
|
+
"@untitled-theme/icons-svelte": "^0.10.11",
|
376
376
|
"autoprefixer": "^10.4.20",
|
377
377
|
"globals": "^15.11.0",
|
378
378
|
"jsdom": "^25.0.1",
|
379
379
|
"postcss": "^8.4.47",
|
380
380
|
"publint": "^0.2.11",
|
381
|
-
"release-it": "^17.
|
381
|
+
"release-it": "^17.9.0",
|
382
382
|
"resize-observer-polyfill": "^1.5.1",
|
383
|
-
"svelte": "^5.0.0-next.
|
383
|
+
"svelte": "^5.0.0-next.265",
|
384
384
|
"svelte-check": "^4.0.5",
|
385
|
-
"tailwind-merge": "^2.5.
|
385
|
+
"tailwind-merge": "^2.5.4",
|
386
386
|
"tailwind-variants": "^0.2.1",
|
387
387
|
"tailwindcss": "^3.4.13",
|
388
388
|
"typescript": "^5.6.3",
|
389
|
-
"vite": "^5.4.
|
390
|
-
"vitest": "^2.1.
|
389
|
+
"vite": "^5.4.9",
|
390
|
+
"vitest": "^2.1.3",
|
391
391
|
"vitest-axe": "^1.0.0-pre.3",
|
392
392
|
"vitest-canvas-mock": "^0.3.3"
|
393
393
|
},
|