@zag-js/number-input 0.2.1 → 0.2.2
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/index.js +2 -3
- package/dist/index.mjs +2 -3
- package/package.json +6 -6
package/dist/index.js
CHANGED
|
@@ -650,7 +650,7 @@ function getWindow(el) {
|
|
|
650
650
|
}
|
|
651
651
|
function getDescriptor(el, options) {
|
|
652
652
|
var _a;
|
|
653
|
-
const { type, property } = options;
|
|
653
|
+
const { type, property = "value" } = options;
|
|
654
654
|
const proto = getWindow(el)[type].prototype;
|
|
655
655
|
return (_a = Object.getOwnPropertyDescriptor(proto, property)) != null ? _a : {};
|
|
656
656
|
}
|
|
@@ -1058,8 +1058,7 @@ function machine(userContext) {
|
|
|
1058
1058
|
dispatchChangeEvent(ctx2) {
|
|
1059
1059
|
dispatchInputValueEvent(dom.getInputEl(ctx2), ctx2.formattedValue);
|
|
1060
1060
|
}
|
|
1061
|
-
}
|
|
1062
|
-
hookSync: true
|
|
1061
|
+
}
|
|
1063
1062
|
}
|
|
1064
1063
|
);
|
|
1065
1064
|
}
|
package/dist/index.mjs
CHANGED
|
@@ -623,7 +623,7 @@ function getWindow(el) {
|
|
|
623
623
|
}
|
|
624
624
|
function getDescriptor(el, options) {
|
|
625
625
|
var _a;
|
|
626
|
-
const { type, property } = options;
|
|
626
|
+
const { type, property = "value" } = options;
|
|
627
627
|
const proto = getWindow(el)[type].prototype;
|
|
628
628
|
return (_a = Object.getOwnPropertyDescriptor(proto, property)) != null ? _a : {};
|
|
629
629
|
}
|
|
@@ -1031,8 +1031,7 @@ function machine(userContext) {
|
|
|
1031
1031
|
dispatchChangeEvent(ctx2) {
|
|
1032
1032
|
dispatchInputValueEvent(dom.getInputEl(ctx2), ctx2.formattedValue);
|
|
1033
1033
|
}
|
|
1034
|
-
}
|
|
1035
|
-
hookSync: true
|
|
1034
|
+
}
|
|
1036
1035
|
}
|
|
1037
1036
|
);
|
|
1038
1037
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zag-js/number-input",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.2",
|
|
4
4
|
"description": "Core logic for the number-input widget implemented as a state machine",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"module": "dist/index.mjs",
|
|
@@ -29,14 +29,14 @@
|
|
|
29
29
|
"url": "https://github.com/chakra-ui/zag/issues"
|
|
30
30
|
},
|
|
31
31
|
"dependencies": {
|
|
32
|
-
"@zag-js/core": "0.2.
|
|
33
|
-
"@zag-js/types": "0.3.
|
|
32
|
+
"@zag-js/core": "0.2.2",
|
|
33
|
+
"@zag-js/types": "0.3.1"
|
|
34
34
|
},
|
|
35
35
|
"devDependencies": {
|
|
36
|
-
"@zag-js/dom-utils": "0.2.
|
|
37
|
-
"@zag-js/form-utils": "0.2.
|
|
36
|
+
"@zag-js/dom-utils": "0.2.1",
|
|
37
|
+
"@zag-js/form-utils": "0.2.1",
|
|
38
38
|
"@zag-js/number-utils": "0.2.0",
|
|
39
|
-
"@zag-js/utils": "0.3.
|
|
39
|
+
"@zag-js/utils": "0.3.1"
|
|
40
40
|
},
|
|
41
41
|
"scripts": {
|
|
42
42
|
"build-fast": "tsup src/index.ts --format=esm,cjs",
|