@fixefy/fixefy-ui-components 0.2.61 → 0.2.62
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.
|
@@ -223,6 +223,7 @@ const FxAsyncDropdown = /*#__PURE__*/ _react.default.forwardRef((props)=>{
|
|
|
223
223
|
if (defaultValue && (defaultValueData === null || defaultValueData === void 0 ? void 0 : (_defaultValueData_method_name = defaultValueData[method_name]) === null || _defaultValueData_method_name === void 0 ? void 0 : _defaultValueData_method_name.length) == 1) {
|
|
224
224
|
//choose default value
|
|
225
225
|
handleOptionClick(defaultValueData === null || defaultValueData === void 0 ? void 0 : defaultValueData[method_name][0]);
|
|
226
|
+
onAdd && onAdd(defaultValueData === null || defaultValueData === void 0 ? void 0 : defaultValueData[method_name][0]);
|
|
226
227
|
}
|
|
227
228
|
}, [
|
|
228
229
|
defaultValue,
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
export declare const FxModalWithButton: ({ btnValue, modalData, onClick, disabled, }: {
|
|
2
|
+
export declare const FxModalWithButton: ({ btnValue, modalData, onClick, disabled, defaultOpen, }: {
|
|
3
3
|
btnValue: string;
|
|
4
4
|
modalData: any;
|
|
5
5
|
onClick?: any;
|
|
6
6
|
disabled?: boolean;
|
|
7
|
+
defaultOpen?: boolean;
|
|
7
8
|
}) => React.JSX.Element;
|
|
@@ -52,8 +52,8 @@ function _interop_require_wildcard(obj, nodeInterop) {
|
|
|
52
52
|
}
|
|
53
53
|
return newObj;
|
|
54
54
|
}
|
|
55
|
-
const FxModalWithButton = ({ btnValue, modalData, onClick, disabled })=>{
|
|
56
|
-
const [isOpen, setIsOpen] = (0, _react.useState)(false);
|
|
55
|
+
const FxModalWithButton = ({ btnValue, modalData, onClick, disabled, defaultOpen })=>{
|
|
56
|
+
const [isOpen, setIsOpen] = (0, _react.useState)(defaultOpen || false);
|
|
57
57
|
const [AnchorEl, setAnchorEl] = (0, _react.useState)(null);
|
|
58
58
|
const handleClick = (e)=>{
|
|
59
59
|
if (onClick) {
|
package/package.json
CHANGED