@dafaz-ui/react 4.0.18 → 4.0.19

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.
@@ -1,5 +1,5 @@
1
1
 
2
- > @dafaz-ui/react@4.0.18 build
2
+ > @dafaz-ui/react@4.0.19 build
3
3
  > tsup src/index.tsx --format esm,cjs --dts --external react
4
4
 
5
5
  CLI Building entry: src/index.tsx
@@ -8,11 +8,11 @@
8
8
  CLI Target: es6
9
9
  ESM Build start
10
10
  CJS Build start
11
- ESM dist/index.mjs 20.31 KB
12
- ESM ⚡️ Build success in 37ms
13
- CJS dist/index.js 22.84 KB
14
- CJS ⚡️ Build success in 37ms
11
+ ESM dist/index.mjs 20.33 KB
12
+ ESM ⚡️ Build success in 38ms
13
+ CJS dist/index.js 22.86 KB
14
+ CJS ⚡️ Build success in 39ms
15
15
  DTS Build start
16
- DTS ⚡️ Build success in 4493ms
16
+ DTS ⚡️ Build success in 4462ms
17
17
  DTS dist/index.d.mts 103.82 KB
18
18
  DTS dist/index.d.ts 103.82 KB
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # @dafaz-ui/react
2
2
 
3
+ ## 4.0.19
4
+
5
+ ### Patch Changes
6
+
7
+ - fix value checkbox
8
+
3
9
  ## 4.0.18
4
10
 
5
11
  ### Patch Changes
package/dist/index.js CHANGED
@@ -467,7 +467,7 @@ var CheckBox = (0, import_react2.forwardRef)(
467
467
  "onCheckedChange",
468
468
  "value"
469
469
  ]);
470
- const [checkValue, setCheckValue] = (0, import_react2.useState)(value);
470
+ const [checkValue, setCheckValue] = (0, import_react2.useState)(checked ? value : void 0);
471
471
  (0, import_react2.useEffect)(() => {
472
472
  if (checked) {
473
473
  setCheckValue(value);
package/dist/index.mjs CHANGED
@@ -418,7 +418,7 @@ var CheckBox = forwardRef(
418
418
  "onCheckedChange",
419
419
  "value"
420
420
  ]);
421
- const [checkValue, setCheckValue] = useState(value);
421
+ const [checkValue, setCheckValue] = useState(checked ? value : void 0);
422
422
  useEffect(() => {
423
423
  if (checked) {
424
424
  setCheckValue(value);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dafaz-ui/react",
3
- "version": "4.0.18",
3
+ "version": "4.0.19",
4
4
  "main": "./dist/index.js",
5
5
  "module": "./dist/index.mjs",
6
6
  "types": "./dist/index.d.ts",
@@ -27,7 +27,7 @@ export const CheckBox = forwardRef<
27
27
  }: CheckboxProps,
28
28
  ref,
29
29
  ) => {
30
- const [checkValue, setCheckValue] = useState(value)
30
+ const [checkValue, setCheckValue] = useState(checked ? value : undefined)
31
31
 
32
32
  useEffect(() => {
33
33
  if (checked) {