Comparing version 1.5.4 to 1.5.5-rc.0
@@ -51,2 +51,7 @@ "use strict"; | ||
}, [props, value]); | ||
(0, _react.useLayoutEffect)(function () { | ||
if (propValue) { | ||
setValue(propValue); | ||
} | ||
}, [propValue]); | ||
var prefixCls = (0, _class.getPrefixCls)("radio-group"); | ||
@@ -53,0 +58,0 @@ var childrenRadio = children; |
@@ -28,3 +28,3 @@ "use strict"; | ||
var _excluded = ["className", "defaultOpen", "label", "status", "helperText", "errorText", "placeholder", "children", "defaultValue", "disabled", "mask", "maskCloseable", "multiple", "onChange"]; | ||
var _excluded = ["className", "defaultOpen", "label", "status", "helperText", "errorText", "placeholder", "children", "defaultValue", "disabled", "mask", "maskCloseable", "multiple", "onChange", "closeOnSelect"]; | ||
@@ -52,2 +52,3 @@ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); } | ||
onChange = props.onChange, | ||
closeOnSelect = props.closeOnSelect, | ||
restProps = (0, _objectWithoutPropertiesLoose2["default"])(props, _excluded); | ||
@@ -102,4 +103,9 @@ | ||
setValue(val); | ||
if (closeOnSelect) { | ||
// eslint-disable-next-line no-use-before-define | ||
closeSelectSheet(); | ||
} | ||
} | ||
}, [multiple, onChange, value]); | ||
}, [closeOnSelect, multiple, onChange, value]); | ||
@@ -106,0 +112,0 @@ var closeSelectSheet = function closeSelectSheet() { |
@@ -1,2 +0,2 @@ | ||
import React, { useCallback, useMemo, useState } from "react"; | ||
import React, { useCallback, useLayoutEffect, useMemo, useState } from "react"; | ||
import classNames from "clsx"; | ||
@@ -36,2 +36,7 @@ import GroupContext from "./context"; | ||
}, [props, value]); | ||
useLayoutEffect(function () { | ||
if (propValue) { | ||
setValue(propValue); | ||
} | ||
}, [propValue]); | ||
var prefixCls = getPrefixCls("radio-group"); | ||
@@ -38,0 +43,0 @@ var childrenRadio = children; |
import _objectWithoutPropertiesLoose from "@babel/runtime/helpers/objectWithoutPropertiesLoose"; | ||
var _excluded = ["className", "defaultOpen", "label", "status", "helperText", "errorText", "placeholder", "children", "defaultValue", "disabled", "mask", "maskCloseable", "multiple", "onChange"]; | ||
var _excluded = ["className", "defaultOpen", "label", "status", "helperText", "errorText", "placeholder", "children", "defaultValue", "disabled", "mask", "maskCloseable", "multiple", "onChange", "closeOnSelect"]; | ||
import React, { useCallback, useMemo, useState } from "react"; | ||
@@ -29,2 +29,3 @@ import classNames from "clsx"; | ||
onChange = props.onChange, | ||
closeOnSelect = props.closeOnSelect, | ||
restProps = _objectWithoutPropertiesLoose(props, _excluded); | ||
@@ -79,4 +80,9 @@ | ||
setValue(val); | ||
if (closeOnSelect) { | ||
// eslint-disable-next-line no-use-before-define | ||
closeSelectSheet(); | ||
} | ||
} | ||
}, [multiple, onChange, value]); | ||
}, [closeOnSelect, multiple, onChange, value]); | ||
@@ -83,0 +89,0 @@ var closeSelectSheet = function closeSelectSheet() { |
/** | ||
* Zaui 1.5.4 | ||
* Zaui 1.5.5-rc.0 | ||
* Zalo Mini App framework | ||
@@ -10,3 +10,3 @@ * undefined | ||
* | ||
* Released on: January 16, 2023 | ||
* Released on: February 6, 2023 | ||
*/ | ||
@@ -13,0 +13,0 @@ |
{ | ||
"name": "zmp-ui", | ||
"version": "1.5.4", | ||
"version": "1.5.5-rc.0", | ||
"description": "Zalo Mini App framework ", | ||
@@ -5,0 +5,0 @@ "main": "esm/index.js", |
@@ -132,2 +132,3 @@ import React, { CSSProperties, ReactNode } from "react"; | ||
maskCloseable?: boolean; | ||
closeOnSelect?: boolean; | ||
} | ||
@@ -134,0 +135,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
1221015
527
23875
2