@pdg/react-form 1.0.123 → 1.0.124
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.esm.js +124 -96
- package/dist/index.js +124 -96
- package/package.json +1 -1
package/dist/index.esm.js
CHANGED
|
@@ -1299,14 +1299,17 @@ styleInject(css_248z$l);var FormTextField = React.forwardRef(function (_a, ref)
|
|
|
1299
1299
|
* Render
|
|
1300
1300
|
* ******************************************************************************************************************/
|
|
1301
1301
|
return (React.createElement(TextField, __assign({}, props, { variant: variant, size: size, color: color, focused: focused || undefined, name: name, label: label, placeholder: placeholder, className: classNames(className, 'FormValueItem', 'FormTextField', "variant-".concat(variant)), inputRef: initInputRef ? initInputRef : inputRef, value: value, required: required, fullWidth: !width && fullWidth, error: error, helperText: formColWithHelperText ? undefined : error ? errorHelperText : helperText, FormHelperTextProps: { component: 'div' }, disabled: disabled, InputProps: muiInputProps, InputLabelProps: muiInputLabelProps, inputProps: ((_b = initInputProps === null || initInputProps === void 0 ? void 0 : initInputProps.className) === null || _b === void 0 ? void 0 : _b.includes('FormTag-Input')) ? initInputProps : inputProps, style: style, select: select, SelectProps: SelectProps, multiline: multiline, onChange: handleChange, onBlur: handleBlur, onKeyDown: handleKeyDown })));
|
|
1302
|
-
});
|
|
1302
|
+
});
|
|
1303
|
+
FormTextField.displayName = 'FormTextField';var css_248z$k = ".FormHidden {\n display: none !important;\n}";
|
|
1303
1304
|
styleInject(css_248z$k);var FormHidden = React.forwardRef(function (_a, ref) {
|
|
1304
1305
|
var className = _a.className, props = __rest(_a, ["className"]);
|
|
1305
1306
|
return (React.createElement(FormTextField, __assign({ ref: ref, className: classNames(className, 'FormHidden'), type: 'hidden', variant: 'standard' }, props)));
|
|
1306
|
-
});
|
|
1307
|
+
});
|
|
1308
|
+
FormHidden.displayName = 'FormHidden';var FormText = React.forwardRef(function (_a, ref) {
|
|
1307
1309
|
var className = _a.className, _b = _a.clear, clear = _b === void 0 ? true : _b, _c = _a.value, value = _c === void 0 ? '' : _c, props = __rest(_a, ["className", "clear", "value"]);
|
|
1308
1310
|
return (React.createElement(FormTextField, __assign({ ref: ref, className: classNames(className, 'FormText'), clear: clear, value: value, disableReturnKey: true }, props)));
|
|
1309
|
-
});
|
|
1311
|
+
});
|
|
1312
|
+
FormText.displayName = 'FormText';var css_248z$j = ".FormTag.FormTextField {\n min-width: 200px;\n}";
|
|
1310
1313
|
styleInject(css_248z$j);var FormTag = React.forwardRef(function (_a, ref) {
|
|
1311
1314
|
/********************************************************************************************************************
|
|
1312
1315
|
* FormState
|
|
@@ -1505,7 +1508,8 @@ styleInject(css_248z$j);var FormTag = React.forwardRef(function (_a, ref) {
|
|
|
1505
1508
|
delete renderProps.inputProps.value;
|
|
1506
1509
|
return (React.createElement(FormText, __assign({}, renderProps, { ref: handleRef, name: name, className: classNames(className, 'FormValueItem', 'FormTag'), error: error, disabled: disabled, fullWidth: fullWidth, required: required, value: inputValue, exceptValue: exceptValue, helperText: error ? errorHelperText : helperText, onKeyDown: handleInputKeyDown, onChange: handleInputChange, onBlur: handleBlur })));
|
|
1507
1510
|
} })));
|
|
1508
|
-
});
|
|
1511
|
+
});
|
|
1512
|
+
FormTag.displayName = 'FormTag';var FormEmail = React.forwardRef(function (_a, ref) {
|
|
1509
1513
|
var className = _a.className, _b = _a.validPattern, validPattern = _b === void 0 ? /^(([^<>()[\].,;:\s@"]+(\.[^<>()[\].,;:\s@"]+)*)|(".+"))@(([^<>()[\].,;:\s@"]+\.)+[^<>()[\].,;:\s@"]{2,})$/g : _b, onValue = _a.onValue, props = __rest(_a, ["className", "validPattern", "onValue"]);
|
|
1510
1514
|
var handleValue = useCallback(function (value) {
|
|
1511
1515
|
var newValue = value.replace(/ /gi, '');
|
|
@@ -1515,7 +1519,8 @@ styleInject(css_248z$j);var FormTag = React.forwardRef(function (_a, ref) {
|
|
|
1515
1519
|
* Render
|
|
1516
1520
|
* ******************************************************************************************************************/
|
|
1517
1521
|
return (React.createElement(FormText, __assign({ ref: ref, className: classNames(className, 'FormEmail'), type: 'email', validPattern: validPattern, onValue: handleValue }, props)));
|
|
1518
|
-
});
|
|
1522
|
+
});
|
|
1523
|
+
FormEmail.displayName = 'FormEmail';var css_248z$i = ".FormPassword .eye-icon-button-wrap {\n visibility: hidden;\n}\n.FormPassword.variant-filled .eye-icon-button-wrap {\n margin-top: 9px;\n margin-bottom: -9px;\n}\n.FormPassword:hover .eye-icon-button-wrap.show,\n.FormPassword .MuiInputBase-root.Mui-focused .eye-icon-button-wrap.show {\n visibility: visible;\n}";
|
|
1519
1524
|
styleInject(css_248z$i);var StyledEyeInputAdornment = styled(InputAdornment)(templateObject_1$c || (templateObject_1$c = __makeTemplateObject(["\n visibility: hidden;\n"], ["\n visibility: hidden;\n"])));
|
|
1520
1525
|
var FormPassword = React.forwardRef(function (_a, ref) {
|
|
1521
1526
|
/********************************************************************************************************************
|
|
@@ -1555,6 +1560,7 @@ var FormPassword = React.forwardRef(function (_a, ref) {
|
|
|
1555
1560
|
* ******************************************************************************************************************/
|
|
1556
1561
|
return (React.createElement(FormText, __assign({ ref: ref, className: classNames(className, 'FormPassword'), onChange: handleChange, type: type, InputProps: muiInputProps, clear: clear }, props)));
|
|
1557
1562
|
});
|
|
1563
|
+
FormPassword.displayName = 'FormPassword';
|
|
1558
1564
|
var templateObject_1$c;var FormTel = React.forwardRef(function (_a, ref) {
|
|
1559
1565
|
/********************************************************************************************************************
|
|
1560
1566
|
* Event Handler
|
|
@@ -1568,10 +1574,12 @@ var templateObject_1$c;var FormTel = React.forwardRef(function (_a, ref) {
|
|
|
1568
1574
|
* Render
|
|
1569
1575
|
* ******************************************************************************************************************/
|
|
1570
1576
|
return (React.createElement(FormText, __assign({ ref: ref, className: classNames(className, 'FormTel'), onValue: handleValue, maxLength: 13, validPattern: validPattern }, props)));
|
|
1571
|
-
});
|
|
1577
|
+
});
|
|
1578
|
+
FormTel.displayName = 'FormTel';var FormMobile = React.forwardRef(function (_a, ref) {
|
|
1572
1579
|
var className = _a.className, _b = _a.validPattern, validPattern = _b === void 0 ? /(^(01(?:0|1|[6-9]))([0-9]{3,4})([0-9]{4,4})$)|(^(01(?:0|1|[6-9]))-([0-9]{3,4})-([0-9]{4,4})$)|(^\+(?:[-]?[0-9]){8,}$)/ : _b, props = __rest(_a, ["className", "validPattern"]);
|
|
1573
1580
|
return React.createElement(FormTel, __assign({ ref: ref, className: classNames(className, 'FormMobile'), validPattern: validPattern }, props));
|
|
1574
|
-
});
|
|
1581
|
+
});
|
|
1582
|
+
FormMobile.displayName = 'FormMobile';var NumberFormatCustom = React.forwardRef(function (_a, ref) {
|
|
1575
1583
|
var onChange = _a.onChange, props = __rest(_a, ["onChange"]);
|
|
1576
1584
|
return (React.createElement(NumericFormat, __assign({}, props, { getInputRef: ref, onValueChange: function (values) {
|
|
1577
1585
|
if (onChange)
|
|
@@ -1651,15 +1659,18 @@ var templateObject_1$c;var FormTel = React.forwardRef(function (_a, ref) {
|
|
|
1651
1659
|
* Render
|
|
1652
1660
|
* ******************************************************************************************************************/
|
|
1653
1661
|
return (React.createElement(FormTextField, __assign({ ref: ref, className: classNames(className, 'FormNumber'), disableReturnKey: true, labelShrink: strValue === '' || strValue === undefined ? labelShrink : true, InputProps: muiInputProps, readOnly: readOnly, clear: clear, value: strValue, onChange: handleChange, onValue: handleValue, onValidate: handleValidate }, props)));
|
|
1654
|
-
});
|
|
1662
|
+
});
|
|
1663
|
+
FormNumber.displayName = 'FormNumber';var css_248z$h = ".FormSearch input[type=search]::-webkit-search-decoration,\n.FormSearch input[type=search]::-webkit-search-cancel-button,\n.FormSearch input[type=search]::-webkit-search-results-button,\n.FormSearch input[type=search]::-webkit-search-results-decoration {\n -webkit-appearance: none;\n}";
|
|
1655
1664
|
styleInject(css_248z$h);var FormSearch = React.forwardRef(function (_a, ref) {
|
|
1656
1665
|
var className = _a.className, props = __rest(_a, ["className"]);
|
|
1657
1666
|
return React.createElement(FormText, __assign({ className: classNames(className, 'FormSearch'), ref: ref, type: 'search' }, props));
|
|
1658
|
-
});
|
|
1667
|
+
});
|
|
1668
|
+
FormSearch.displayName = 'FormSearch';var css_248z$g = ".FormTextarea .MuiInputBase-root .MuiInputBase-input {\n overflow-y: scroll;\n}\n.FormTextarea .MuiInputBase-root .MuiInputBase-input::-webkit-scrollbar {\n width: 8px;\n}\n.FormTextarea .MuiInputBase-root .MuiInputBase-input::-webkit-scrollbar-thumb {\n background-color: rgba(0, 0, 0, 0.1882352941);\n background-clip: padding-box;\n border-left: 4px transparent solid;\n}";
|
|
1659
1669
|
styleInject(css_248z$g);var FormTextarea = React.forwardRef(function (_a, ref) {
|
|
1660
1670
|
var className = _a.className, _b = _a.clear, clear = _b === void 0 ? false : _b, _c = _a.rows, rows = _c === void 0 ? 3 : _c, _d = _a.value, value = _d === void 0 ? '' : _d, props = __rest(_a, ["className", "clear", "rows", "value"]);
|
|
1661
1671
|
return (React.createElement(FormTextField, __assign({ ref: ref, className: classNames(className, 'FormTextarea'), clear: clear, rows: rows, value: value }, props, { multiline: true })));
|
|
1662
|
-
});
|
|
1672
|
+
});
|
|
1673
|
+
FormTextarea.displayName = 'FormTextarea';var FormUrl = React.forwardRef(function (_a, ref) {
|
|
1663
1674
|
/********************************************************************************************************************
|
|
1664
1675
|
* Event Handler
|
|
1665
1676
|
* ******************************************************************************************************************/
|
|
@@ -1672,7 +1683,8 @@ styleInject(css_248z$g);var FormTextarea = React.forwardRef(function (_a, ref) {
|
|
|
1672
1683
|
* Render
|
|
1673
1684
|
* ******************************************************************************************************************/
|
|
1674
1685
|
return (React.createElement(FormText, __assign({ ref: ref, className: classNames(className, 'FormUrl'), type: 'url', validPattern: validPattern, onValue: handleValue }, props)));
|
|
1675
|
-
});
|
|
1686
|
+
});
|
|
1687
|
+
FormUrl.displayName = 'FormUrl';function getDateValidationErrorText(error) {
|
|
1676
1688
|
switch (error) {
|
|
1677
1689
|
case 'invalidDate':
|
|
1678
1690
|
return '형식이 일치하지 않습니다.';
|
|
@@ -2260,7 +2272,8 @@ styleInject(css_248z$f);var FormSelect = ToForwardRefExoticComponent(AutoTypeFor
|
|
|
2260
2272
|
multiple && checkbox && Array.isArray(value) && React.createElement(Checkbox, { checked: value.includes(itemValue) }),
|
|
2261
2273
|
itemLabel));
|
|
2262
2274
|
})) : (React.createElement(MenuItem, { value: '' })))));
|
|
2263
|
-
}));
|
|
2275
|
+
}));
|
|
2276
|
+
FormSelect.displayName = 'FormSelect';var FormCompanyNo = React.forwardRef(function (_a, ref) {
|
|
2264
2277
|
/********************************************************************************************************************
|
|
2265
2278
|
* Event Handler
|
|
2266
2279
|
* ******************************************************************************************************************/
|
|
@@ -2273,7 +2286,8 @@ styleInject(css_248z$f);var FormSelect = ToForwardRefExoticComponent(AutoTypeFor
|
|
|
2273
2286
|
* Render
|
|
2274
2287
|
* ******************************************************************************************************************/
|
|
2275
2288
|
return (React.createElement(FormText, __assign({ ref: ref, className: classNames(className, 'FormCompanyNo'), maxLength: 12, validPattern: validPattern, onValue: handleValue }, props)));
|
|
2276
|
-
});
|
|
2289
|
+
});
|
|
2290
|
+
FormCompanyNo.displayName = 'FormCompanyNo';var FormPersonalNo = React.forwardRef(function (_a, ref) {
|
|
2277
2291
|
/********************************************************************************************************************
|
|
2278
2292
|
* Event Handler
|
|
2279
2293
|
* ******************************************************************************************************************/
|
|
@@ -2320,7 +2334,8 @@ styleInject(css_248z$f);var FormSelect = ToForwardRefExoticComponent(AutoTypeFor
|
|
|
2320
2334
|
* Render
|
|
2321
2335
|
* ******************************************************************************************************************/
|
|
2322
2336
|
return (React.createElement(FormText, __assign({ ref: ref, className: classNames(className, 'FormPersonalNo'), maxLength: 14, validPattern: validPattern, onValue: handleValue, onValidate: handleValidate }, props)));
|
|
2323
|
-
});
|
|
2337
|
+
});
|
|
2338
|
+
FormPersonalNo.displayName = 'FormPersonalNo';var css_248z$e = ".FormItemBase .FormItemBase-InputLabel {\n overflow: visible;\n padding-left: 5px;\n}\n.FormItemBase .FormItemBase-InputLabel.MuiInputLabel-sizeSmall {\n transform: translate(0, -1.5px) scale(0.7);\n}\n.FormItemBase .FormItemBase-Control-wrap {\n position: relative;\n}\n.FormItemBase .FormItemBase-Control {\n position: absolute;\n left: 0;\n top: 0;\n}\n.FormItemBase.variant-standard .FormItemBase-Control-wrap {\n margin-top: 16px;\n}";
|
|
2324
2339
|
styleInject(css_248z$e);var FormItemBase = React.forwardRef(function (_a, ref) {
|
|
2325
2340
|
/********************************************************************************************************************
|
|
2326
2341
|
* Ref
|
|
@@ -2452,7 +2467,8 @@ styleInject(css_248z$e);var FormItemBase = React.forwardRef(function (_a, ref) {
|
|
|
2452
2467
|
marginTop: controlMarginTop,
|
|
2453
2468
|
} }, control))),
|
|
2454
2469
|
!formColWithHelperText && helperText && (React.createElement(FormHelperText, __assign({ component: 'div' }, helperTextProps), helperText)))));
|
|
2455
|
-
});
|
|
2470
|
+
});
|
|
2471
|
+
FormItemBase.displayName = 'FormItemBase';var FormCheckbox = React.forwardRef(function (_a, ref) {
|
|
2456
2472
|
/********************************************************************************************************************
|
|
2457
2473
|
* ID
|
|
2458
2474
|
* ******************************************************************************************************************/
|
|
@@ -2648,7 +2664,8 @@ styleInject(css_248z$e);var FormItemBase = React.forwardRef(function (_a, ref) {
|
|
|
2648
2664
|
* Render
|
|
2649
2665
|
* ******************************************************************************************************************/
|
|
2650
2666
|
return (React.createElement(FormItemBase, { variant: variant, size: size, color: color, focused: focused, className: classNames(className, 'FormValueItem', 'FormCheckbox'), labelIcon: labelIcon, label: label, error: error, fullWidth: fullWidth, helperText: error ? errorHelperText : helperText, helperTextProps: { style: { marginLeft: 2 } }, style: style, sx: sx, hidden: hidden, autoSize: true, controlHeight: height || (size === 'small' ? 35 : 39), controlVerticalCenter: true, control: React.createElement(FormControlLabel, { ref: labelRef, control: React.createElement(Checkbox, __assign({ name: name, color: color, size: size, inputRef: initInputRef ? initInputRef : inputRef, action: initAction ? initAction : actionRef, checked: checked, checkedIcon: React.createElement(CheckBox, { color: error ? 'error' : undefined }), icon: React.createElement(CheckBoxOutlineBlank, { color: error ? 'error' : undefined }), onChange: handleChange, disabled: disabled || readOnly }, props)), label: React.createElement(Typography, { color: error ? 'error' : readOnly || disabled ? theme.palette.text.disabled : undefined, whiteSpace: 'nowrap' }, text) }) }));
|
|
2651
|
-
});
|
|
2667
|
+
});
|
|
2668
|
+
FormCheckbox.displayName = 'FormCheckbox';var PADDING_LEFT = 3;
|
|
2652
2669
|
var FormRadioGroup = ToForwardRefExoticComponent(AutoTypeForwardRef(function (_a, ref) {
|
|
2653
2670
|
/********************************************************************************************************************
|
|
2654
2671
|
* type
|
|
@@ -2966,7 +2983,8 @@ var FormRadioGroup = ToForwardRefExoticComponent(AutoTypeForwardRef(function (_a
|
|
|
2966
2983
|
var value = _a.value, label = _a.label, itemDisabled = _a.disabled;
|
|
2967
2984
|
return (React.createElement(FormControlLabel, { key: idx, control: React.createElement(Radio, { icon: React.createElement(RadioButtonUnchecked, { color: error ? 'error' : undefined }), checkedIcon: React.createElement(RadioButtonChecked, { color: error ? 'error' : undefined }), color: color, size: size, inputRef: idx === 0 ? firstInputRef : null }), label: label, style: { color: error ? theme.palette.error.main : '', marginTop: -10, whiteSpace: 'nowrap' }, value: value, disabled: disabled || readOnly || itemDisabled }));
|
|
2968
2985
|
})))))) }));
|
|
2969
|
-
}));
|
|
2986
|
+
}));
|
|
2987
|
+
FormRadioGroup.displayName = 'FormRadioGroup';var css_248z$d = ".FormToggleButtonGroup .ToggleButton {\n display: inline-flex;\n padding: 0 10px;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n align-items: center;\n}\n.FormToggleButtonGroup .ToggleButton .__label__ {\n height: 0;\n line-height: 0 !important;\n overflow: visible !important;\n}\n.FormToggleButtonGroup.type-checkbox .ToggleButton, .FormToggleButtonGroup.type-radio .ToggleButton {\n padding-left: 3px;\n padding-right: 5px;\n border: 0 !important;\n margin-left: 0 !important;\n justify-content: flex-start;\n display: flex;\n background-color: transparent !important;\n}\n.FormToggleButtonGroup.type-checkbox .ToggleButton:not(:last-child), .FormToggleButtonGroup.type-radio .ToggleButton:not(:last-child) {\n margin-right: 5px;\n}\n.FormToggleButtonGroup.type-checkbox .ToggleButton .__checkbox-checked__,\n.FormToggleButtonGroup.type-checkbox .ToggleButton .__checkbox-unchecked__, .FormToggleButtonGroup.type-radio .ToggleButton .__checkbox-checked__,\n.FormToggleButtonGroup.type-radio .ToggleButton .__checkbox-unchecked__ {\n margin-right: 3px;\n}\n.FormToggleButtonGroup.type-checkbox .ToggleButton .__checkbox-checked__, .FormToggleButtonGroup.type-radio .ToggleButton .__checkbox-checked__ {\n display: none;\n}\n.FormToggleButtonGroup.type-checkbox .ToggleButton.Mui-selected .__checkbox-checked__, .FormToggleButtonGroup.type-radio .ToggleButton.Mui-selected .__checkbox-checked__ {\n display: block;\n}\n.FormToggleButtonGroup.type-checkbox .ToggleButton.Mui-selected .__checkbox-unchecked__, .FormToggleButtonGroup.type-radio .ToggleButton.Mui-selected .__checkbox-unchecked__ {\n display: none;\n}\n.FormToggleButtonGroup:not(.with-label).variant-outlined .FormItemBase-Control-wrap {\n margin-top: 15px;\n margin-bottom: -15px;\n}\n.FormToggleButtonGroup:not(.with-label).variant-outlined .FormItemBase-Control-wrap .ToggleButton {\n height: 37px;\n}\n.FormToggleButtonGroup:not(.with-label).variant-filled .FormItemBase-Control-wrap {\n margin-top: 15px;\n margin-bottom: -15px;\n}\n.FormToggleButtonGroup:not(.with-label).variant-filled .FormItemBase-Control-wrap .ToggleButton {\n height: 37px;\n}\n.FormToggleButtonGroup:not(.with-label).variant-standard .FormItemBase-Control-wrap {\n margin-top: 0px;\n margin-bottom: 0px;\n}\n.FormToggleButtonGroup:not(.with-label).variant-standard .FormItemBase-Control-wrap .ToggleButton {\n height: 28px;\n}\n.FormToggleButtonGroup:not(.with-label).size-small.variant-outlined .FormItemBase-Control-wrap {\n margin-top: 13px;\n margin-bottom: -13px;\n}\n.FormToggleButtonGroup:not(.with-label).size-small.variant-outlined .FormItemBase-Control-wrap .ToggleButton {\n height: 24px;\n}\n.FormToggleButtonGroup:not(.with-label).size-small.variant-filled .FormItemBase-Control-wrap {\n margin-top: 13px;\n margin-bottom: -13px;\n}\n.FormToggleButtonGroup:not(.with-label).size-small.variant-filled .FormItemBase-Control-wrap .ToggleButton {\n height: 31px;\n}\n.FormToggleButtonGroup:not(.with-label).size-small.variant-standard .FormItemBase-Control-wrap {\n margin-top: 0px;\n margin-bottom: 0px;\n}\n.FormToggleButtonGroup:not(.with-label).size-small.variant-standard .FormItemBase-Control-wrap .ToggleButton {\n height: 26px;\n}\n.FormToggleButtonGroup.with-label.variant-outlined .FormItemBase-Control-wrap {\n margin-top: 0;\n margin-bottom: 0;\n}\n.FormToggleButtonGroup.with-label.variant-outlined .FormItemBase-Control-wrap .ToggleButton {\n height: 37px;\n}\n.FormToggleButtonGroup.with-label.variant-filled .FormItemBase-Control-wrap {\n margin-top: 0;\n margin-bottom: 0;\n}\n.FormToggleButtonGroup.with-label.variant-filled .FormItemBase-Control-wrap .ToggleButton {\n height: 37px;\n}\n.FormToggleButtonGroup.with-label.variant-standard .FormItemBase-Control-wrap {\n margin-top: 0;\n margin-bottom: 0;\n}\n.FormToggleButtonGroup.with-label.variant-standard .FormItemBase-Control-wrap .ToggleButton {\n height: 28px;\n}\n.FormToggleButtonGroup.with-label.size-small.variant-outlined .FormItemBase-Control-wrap {\n margin-top: 0;\n margin-bottom: 0;\n}\n.FormToggleButtonGroup.with-label.size-small.variant-outlined .FormItemBase-Control-wrap .ToggleButton {\n height: 24px;\n}\n.FormToggleButtonGroup.with-label.size-small.variant-filled .FormItemBase-Control-wrap {\n margin-top: 0;\n margin-bottom: 0;\n}\n.FormToggleButtonGroup.with-label.size-small.variant-filled .FormItemBase-Control-wrap .ToggleButton {\n height: 31px;\n}\n.FormToggleButtonGroup.with-label.size-small.variant-standard .FormItemBase-Control-wrap {\n margin-top: 0;\n margin-bottom: 0;\n}\n.FormToggleButtonGroup.with-label.size-small.variant-standard .FormItemBase-Control-wrap .ToggleButton {\n height: 26px;\n}\n\n.Form .FormCol.with-label .FormToggleButtonGroup.variant-outlined .FormItemBase-Control-wrap {\n margin-top: 0;\n margin-bottom: 0;\n}\n.Form .FormCol.with-label .FormToggleButtonGroup.variant-outlined .FormItemBase-Control-wrap .ToggleButton {\n height: 37px;\n}\n.Form .FormCol.with-label .FormToggleButtonGroup.variant-filled .FormItemBase-Control-wrap {\n margin-top: 0;\n margin-bottom: 0;\n}\n.Form .FormCol.with-label .FormToggleButtonGroup.variant-filled .FormItemBase-Control-wrap .ToggleButton {\n height: 37px;\n}\n.Form .FormCol.with-label .FormToggleButtonGroup.variant-standard .FormItemBase-Control-wrap {\n margin-top: 0;\n margin-bottom: 0;\n}\n.Form .FormCol.with-label .FormToggleButtonGroup.variant-standard .FormItemBase-Control-wrap .ToggleButton {\n height: 28px;\n}\n.Form .FormCol.with-label .FormToggleButtonGroup.size-small.variant-outlined .FormItemBase-Control-wrap {\n margin-top: 0;\n margin-bottom: 0;\n}\n.Form .FormCol.with-label .FormToggleButtonGroup.size-small.variant-outlined .FormItemBase-Control-wrap .ToggleButton {\n height: 24px;\n}\n.Form .FormCol.with-label .FormToggleButtonGroup.size-small.variant-filled .FormItemBase-Control-wrap {\n margin-top: 0;\n margin-bottom: 0;\n}\n.Form .FormCol.with-label .FormToggleButtonGroup.size-small.variant-filled .FormItemBase-Control-wrap .ToggleButton {\n height: 31px;\n}\n.Form .FormCol.with-label .FormToggleButtonGroup.size-small.variant-standard .FormItemBase-Control-wrap {\n margin-top: 0;\n margin-bottom: 0;\n}\n.Form .FormCol.with-label .FormToggleButtonGroup.size-small.variant-standard .FormItemBase-Control-wrap .ToggleButton {\n height: 26px;\n}";
|
|
2970
2988
|
styleInject(css_248z$d);var FormToggleButtonGroup = ToForwardRefExoticComponent(AutoTypeForwardRef(function (_a, ref) {
|
|
2971
2989
|
/********************************************************************************************************************
|
|
2972
2990
|
* type
|
|
@@ -3405,7 +3423,8 @@ styleInject(css_248z$d);var FormToggleButtonGroup = ToForwardRefExoticComponent(
|
|
|
3405
3423
|
: undefined,
|
|
3406
3424
|
flexWrap: type === 'checkbox' || type === 'radio' ? 'wrap' : 'nowrap',
|
|
3407
3425
|
}, "aria-labelledby": notEmpty(label) ? labelId : undefined }, isOnGetItemLoading || loading || !items || empty(items) ? (React.createElement(ToggleButton, { ref: refForButtonResizeHeightDetect, size: size, className: 'ToggleButton', disabled: disabled || readOnly, value: '', style: { visibility: 'hidden' } })) : (buttons)))) })));
|
|
3408
|
-
}));
|
|
3426
|
+
}));
|
|
3427
|
+
FormToggleButtonGroup.displayName = 'FormToggleButtonGroup';var FormRating = React.forwardRef(function (_a, ref) {
|
|
3409
3428
|
/********************************************************************************************************************
|
|
3410
3429
|
* ID
|
|
3411
3430
|
* ******************************************************************************************************************/
|
|
@@ -3600,7 +3619,8 @@ styleInject(css_248z$d);var FormToggleButtonGroup = ToForwardRefExoticComponent(
|
|
|
3600
3619
|
* Render
|
|
3601
3620
|
* ******************************************************************************************************************/
|
|
3602
3621
|
return (React.createElement(FormItemBase, { variant: variant, size: size, color: color, focused: focused, className: classNames(className, 'FormValueItem', 'FormRating'), labelIcon: labelIcon, label: label, error: error, fullWidth: false, required: required, helperText: error ? errorHelperText : helperText, helperTextProps: { style: { marginLeft: 5 } }, style: style, sx: sx, hidden: hidden, autoSize: true, controlHeight: height || (size === 'small' ? 21 : 26), controlVerticalCenter: true, control: React.createElement(Rating, { ref: ratingRef, size: size === 'medium' ? 'large' : 'medium', name: name, precision: precision, highlightSelectedOnly: highlightSelectedOnly, value: value, disabled: disabled || readOnly, max: max, icon: React.createElement(PdgIcon, { color: color, size: 'inherit' }, icon ? icon : 'Star'), emptyIcon: React.createElement(PdgIcon, { size: 'inherit' }, emptyIcon ? emptyIcon : 'StarBorder'), onChange: handleChange, onFocus: function () { return setFocused(initFocused || true); }, onBlur: function () { return setFocused(initFocused || false); } }) }));
|
|
3603
|
-
});
|
|
3622
|
+
});
|
|
3623
|
+
FormRating.displayName = 'FormRating';var css_248z$c = ".FormTextEditor.initializing textarea {\n display: none;\n}\n.FormTextEditor.error .tox-tinymce {\n border-color: #d32f2f;\n}\n\n.tox-menu.tox-collection.tox-collection--list .tox-collection__group .tox-menu-nav__js.tox-collection__item {\n padding-right: 20px !important;\n}\n\n.tox-notifications-container {\n display: none;\n}";
|
|
3604
3624
|
styleInject(css_248z$c);var FormTextEditor = React.forwardRef(function (_a, ref) {
|
|
3605
3625
|
/********************************************************************************************************************
|
|
3606
3626
|
* ID
|
|
@@ -3824,7 +3844,8 @@ styleInject(css_248z$c);var FormTextEditor = React.forwardRef(function (_a, ref)
|
|
|
3824
3844
|
editorRef.current = editor;
|
|
3825
3845
|
setTimeout(function () { return setInitialized(true); }, 10);
|
|
3826
3846
|
}, onEditorChange: handleEditorChange, onKeyDown: handleKeyDown, onFocus: function () { return setFocused(initFocused || true); }, onBlur: function () { return setFocused(initFocused || false); } })) }));
|
|
3827
|
-
});
|
|
3847
|
+
});
|
|
3848
|
+
FormTextEditor.displayName = 'FormTextEditor';var FormAutocomplete = ToForwardRefExoticComponent(AutoTypeForwardRef(function (_a, ref) {
|
|
3828
3849
|
/********************************************************************************************************************
|
|
3829
3850
|
* type
|
|
3830
3851
|
* ******************************************************************************************************************/
|
|
@@ -4310,7 +4331,8 @@ styleInject(css_248z$c);var FormTextEditor = React.forwardRef(function (_a, ref)
|
|
|
4310
4331
|
}, renderInput: function (params) { return (React.createElement(FormTextField, __assign({}, params, { ref: textFieldRef, name: name, variant: variant, size: size, color: color, labelIcon: labelIcon, label: label, labelShrink: labelShrink, required: required, focused: focused, error: error, readOnly: readOnly, helperText: error ? errorHelperText : helperText, placeholder: placeholder, noFormValueItem: true, InputProps: __assign(__assign({}, params.InputProps), { endAdornment: (React.createElement(React.Fragment, null,
|
|
4311
4332
|
loading || isOnGetItemLoading ? React.createElement(CircularProgress, { color: 'inherit', size: 20 }) : null,
|
|
4312
4333
|
params.InputProps.endAdornment)) }), inputProps: readOnly || disabled ? __assign(__assign({}, params.inputProps), { tabIndex: -1 }) : params.inputProps }))); } }));
|
|
4313
|
-
}));
|
|
4334
|
+
}));
|
|
4335
|
+
FormAutocomplete.displayName = 'FormAutocomplete';var css_248z$b = ".PrivateYearSelect {\n position: absolute;\n left: 0;\n right: 0;\n top: 0;\n bottom: 0;\n background-color: white;\n}\n.PrivateYearSelect button {\n font-size: 14px;\n font-weight: 400;\n border-radius: 18px;\n}";
|
|
4314
4336
|
styleInject(css_248z$b);var PrivateToggleButton = React.forwardRef(function (_a, ref) {
|
|
4315
4337
|
var children = _a.children, initClassName = _a.className, selected = _a.selected, activated = _a.activated, outlined = _a.outlined, props = __rest(_a, ["children", "className", "selected", "activated", "outlined"]);
|
|
4316
4338
|
var theme = useTheme();
|
|
@@ -6593,16 +6615,10 @@ var PrivateYearPicker = function (_a) {
|
|
|
6593
6615
|
};var StyledContainer$2 = styled(Grid)(templateObject_1$5 || (templateObject_1$5 = __makeTemplateObject(["\n padding: 4px;\n position: relative;\n"], ["\n padding: 4px;\n position: relative;\n"])));
|
|
6594
6616
|
var StyledButton = styled(Button)(templateObject_2$2 || (templateObject_2$2 = __makeTemplateObject(["\n font-size: 12px;\n background-color: transparent;\n color: unset;\n outline: 0;\n font-weight: 400;\n line-height: 1.75;\n border-radius: 18px;\n cursor: pointer;\n width: 100%;\n border: 1px solid transparent;\n\n &:focus {\n background-color: rgba(0, 0, 0, 0.12);\n }\n\n &.default {\n background-color: #efefef;\n }\n &.selected,\n &.selected-temp {\n background-color: rgba(66, 165, 245, 0.6);\n }\n &.selected-start,\n &.selected-end {\n color: #fff;\n background-color: rgba(25, 118, 210, 1);\n\n &.range:not(.active) {\n background-color: rgba(25, 118, 210, 0.8);\n }\n }\n &.active {\n color: #fff;\n background-color: rgba(25, 118, 210, 1);\n box-shadow: inset 1px 1px 1px 1px #05569f;\n }\n &.disabled {\n opacity: 0.8;\n border: 1px solid transparent;\n }\n &:hover:not(.disabled):not(.selected-start):not(.selected-end) {\n color: inherit;\n background-color: rgba(66, 165, 245, 0.3);\n border: 1px solid transparent;\n }\n"], ["\n font-size: 12px;\n background-color: transparent;\n color: unset;\n outline: 0;\n font-weight: 400;\n line-height: 1.75;\n border-radius: 18px;\n cursor: pointer;\n width: 100%;\n border: 1px solid transparent;\n\n &:focus {\n background-color: rgba(0, 0, 0, 0.12);\n }\n\n &.default {\n background-color: #efefef;\n }\n &.selected,\n &.selected-temp {\n background-color: rgba(66, 165, 245, 0.6);\n }\n &.selected-start,\n &.selected-end {\n color: #fff;\n background-color: rgba(25, 118, 210, 1);\n\n &.range:not(.active) {\n background-color: rgba(25, 118, 210, 0.8);\n }\n }\n &.active {\n color: #fff;\n background-color: rgba(25, 118, 210, 1);\n box-shadow: inset 1px 1px 1px 1px #05569f;\n }\n &.disabled {\n opacity: 0.8;\n border: 1px solid transparent;\n }\n &:hover:not(.disabled):not(.selected-start):not(.selected-end) {\n color: inherit;\n background-color: rgba(66, 165, 245, 0.3);\n border: 1px solid transparent;\n }\n"])));
|
|
6595
6617
|
var templateObject_1$5, templateObject_2$2;var PrivateMonthPickerMonth = React.forwardRef(function (_a, ref) {
|
|
6596
|
-
/********************************************************************************************************************
|
|
6597
|
-
* Memo
|
|
6598
|
-
* ******************************************************************************************************************/
|
|
6599
|
-
var month = _a.month, range = _a.range, disabled = _a.disabled, isDefault = _a.isDefault, active = _a.active, selected = _a.selected, selectedStart = _a.selectedStart, selectedEnd = _a.selectedEnd, selectedTemp = _a.selectedTemp, onClick = _a.onClick, onMouseEnter = _a.onMouseEnter, onMouseLeave = _a.onMouseLeave;
|
|
6600
|
-
var className = useMemo(function () {
|
|
6601
|
-
return classNames(range && 'range', isDefault && 'default', active && 'active', selected && 'selected', selectedStart && 'selected-start', selectedEnd && 'selected-end', selectedTemp && 'selected-temp', disabled && 'disabled');
|
|
6602
|
-
}, [range, isDefault, active, selected, selectedStart, selectedEnd, selectedTemp, disabled]);
|
|
6603
6618
|
/********************************************************************************************************************
|
|
6604
6619
|
* Event Handler
|
|
6605
6620
|
* ******************************************************************************************************************/
|
|
6621
|
+
var month = _a.month, range = _a.range, disabled = _a.disabled, isDefault = _a.isDefault, active = _a.active, selected = _a.selected, selectedStart = _a.selectedStart, selectedEnd = _a.selectedEnd, selectedTemp = _a.selectedTemp, onClick = _a.onClick, onMouseEnter = _a.onMouseEnter, onMouseLeave = _a.onMouseLeave;
|
|
6606
6622
|
var handleClick = useCallback(function () {
|
|
6607
6623
|
onClick && onClick(month);
|
|
6608
6624
|
}, [month, onClick]);
|
|
@@ -6610,7 +6626,7 @@ var templateObject_1$5, templateObject_2$2;var PrivateMonthPickerMonth = React.f
|
|
|
6610
6626
|
* Render
|
|
6611
6627
|
* ******************************************************************************************************************/
|
|
6612
6628
|
return (React.createElement(StyledContainer$2, { className: 'PrivateMonthPickerMonth', ref: ref, item: true, xs: 4 },
|
|
6613
|
-
React.createElement(StyledButton, { className:
|
|
6629
|
+
React.createElement(StyledButton, { className: classNames(range && 'range', isDefault && 'default', active && 'active', selected && 'selected', selectedStart && 'selected-start', selectedEnd && 'selected-end', selectedTemp && 'selected-temp', disabled && 'disabled'), disabled: disabled, onClick: handleClick, onMouseEnter: onMouseEnter, onMouseLeave: onMouseLeave },
|
|
6614
6630
|
month,
|
|
6615
6631
|
"\uC6D4")));
|
|
6616
6632
|
});var StyledContainer$1 = styled(Grid)(templateObject_1$4 || (templateObject_1$4 = __makeTemplateObject(["\n width: 240px;\n padding: 4px;\n"], ["\n width: 240px;\n padding: 4px;\n"])));
|
|
@@ -6619,57 +6635,62 @@ var templateObject_1$4;var PrivateMonthPickerMonthList = function (_a) {
|
|
|
6619
6635
|
* Memo
|
|
6620
6636
|
* ******************************************************************************************************************/
|
|
6621
6637
|
var value = _a.value, initDefaultValue = _a.defaultValue, minAvailableValue = _a.minAvailableValue, maxAvailableValue = _a.maxAvailableValue, disablePast = _a.disablePast, disableFuture = _a.disableFuture, selectFromValue = _a.selectFromValue, selectToValue = _a.selectToValue, onChange = _a.onChange;
|
|
6622
|
-
var
|
|
6623
|
-
|
|
6624
|
-
|
|
6625
|
-
|
|
6626
|
-
|
|
6627
|
-
|
|
6628
|
-
|
|
6629
|
-
|
|
6630
|
-
|
|
6631
|
-
|
|
6632
|
-
|
|
6633
|
-
|
|
6634
|
-
|
|
6635
|
-
|
|
6636
|
-
|
|
6637
|
-
|
|
6638
|
-
|
|
6639
|
-
|
|
6640
|
-
|
|
6641
|
-
|
|
6642
|
-
var
|
|
6643
|
-
|
|
6638
|
+
var dateInfo = useMemo(function () {
|
|
6639
|
+
var nowDate = dayjs();
|
|
6640
|
+
var nowValue = dateToValue$2(nowDate);
|
|
6641
|
+
var nowYm = valueToYm$2(nowValue);
|
|
6642
|
+
var availableYm = {
|
|
6643
|
+
min: valueToYm$2(minAvailableValue),
|
|
6644
|
+
max: valueToYm$2(maxAvailableValue),
|
|
6645
|
+
};
|
|
6646
|
+
var defaultValue = initDefaultValue
|
|
6647
|
+
? initDefaultValue
|
|
6648
|
+
: nowYm < availableYm.min
|
|
6649
|
+
? minAvailableValue
|
|
6650
|
+
: nowYm > availableYm.max
|
|
6651
|
+
? maxAvailableValue
|
|
6652
|
+
: nowValue;
|
|
6653
|
+
return { nowDate: nowDate, nowValue: nowValue, nowYm: nowYm, availableYm: availableYm, defaultValue: defaultValue };
|
|
6654
|
+
}, [initDefaultValue, maxAvailableValue, minAvailableValue]);
|
|
6655
|
+
/********************************************************************************************************************
|
|
6656
|
+
* Variable
|
|
6657
|
+
* ******************************************************************************************************************/
|
|
6658
|
+
var currentYear = value ? value.year : dateInfo.defaultValue.year;
|
|
6659
|
+
/********************************************************************************************************************
|
|
6660
|
+
* Memo
|
|
6661
|
+
* ******************************************************************************************************************/
|
|
6644
6662
|
var months = useMemo(function () {
|
|
6645
6663
|
var newMonths = [];
|
|
6646
6664
|
var range = !!selectFromValue || !!selectToValue;
|
|
6647
|
-
var startYm = selectFromValue ? valueToYm$
|
|
6648
|
-
var endYm = selectToValue ? valueToYm$
|
|
6665
|
+
var startYm = selectFromValue ? valueToYm$2(selectFromValue) : value ? valueToYm$2(value) : 0;
|
|
6666
|
+
var endYm = selectToValue ? valueToYm$2(selectToValue) : value ? valueToYm$2(value) : 0;
|
|
6649
6667
|
for (var i = 1; i <= 12; i += 1) {
|
|
6650
6668
|
var ym = currentYear * 100 + i;
|
|
6651
6669
|
newMonths.push({
|
|
6652
6670
|
month: i,
|
|
6653
6671
|
range: range,
|
|
6654
|
-
isDefault: !value && i ===
|
|
6655
|
-
active: (!!selectFromValue || !!selectToValue) && !!value && ym === valueToYm$
|
|
6672
|
+
isDefault: !value && i === dateInfo.defaultValue.month,
|
|
6673
|
+
active: (!!selectFromValue || !!selectToValue) && !!value && ym === valueToYm$2(value),
|
|
6656
6674
|
selected: !!value && ym >= startYm && ym <= endYm,
|
|
6657
6675
|
selectedStart: !!value && ym === startYm,
|
|
6658
6676
|
selectedEnd: !!value && ym === endYm,
|
|
6659
|
-
disabled: ym <
|
|
6677
|
+
disabled: ym < dateInfo.availableYm.min ||
|
|
6678
|
+
ym > dateInfo.availableYm.max ||
|
|
6679
|
+
(disablePast && ym < dateInfo.nowYm) ||
|
|
6680
|
+
(disableFuture && ym > dateInfo.nowYm),
|
|
6660
6681
|
});
|
|
6661
6682
|
}
|
|
6662
6683
|
return newMonths;
|
|
6663
6684
|
}, [
|
|
6664
6685
|
selectFromValue,
|
|
6665
|
-
value,
|
|
6666
6686
|
selectToValue,
|
|
6687
|
+
value,
|
|
6667
6688
|
currentYear,
|
|
6668
|
-
|
|
6669
|
-
|
|
6670
|
-
|
|
6689
|
+
dateInfo.defaultValue.month,
|
|
6690
|
+
dateInfo.availableYm.min,
|
|
6691
|
+
dateInfo.availableYm.max,
|
|
6692
|
+
dateInfo.nowYm,
|
|
6671
6693
|
disablePast,
|
|
6672
|
-
nowYm,
|
|
6673
6694
|
disableFuture,
|
|
6674
6695
|
]);
|
|
6675
6696
|
/********************************************************************************************************************
|
|
@@ -6686,8 +6707,8 @@ var templateObject_1$4;var PrivateMonthPickerMonthList = function (_a) {
|
|
|
6686
6707
|
/********************************************************************************************************************
|
|
6687
6708
|
* Function
|
|
6688
6709
|
* ******************************************************************************************************************/
|
|
6689
|
-
var valueToYm$
|
|
6690
|
-
var dateToValue$
|
|
6710
|
+
var valueToYm$2 = function (v) { return v.year * 100 + v.month; };
|
|
6711
|
+
var dateToValue$2 = function (v) { return ({ year: v.year(), month: v.month() + 1 }); };var StyledContainer = styled('div')(templateObject_1$3 || (templateObject_1$3 = __makeTemplateObject(["\n .PrivateYearPickerYearList {\n max-height: 130px;\n }\n"], ["\n .PrivateYearPickerYearList {\n max-height: 130px;\n }\n"])));
|
|
6691
6712
|
var TitleContainer = styled('div')(templateObject_2$1 || (templateObject_2$1 = __makeTemplateObject(["\n display: flex;\n justify-content: center;\n align-items: center;\n border-bottom: 1px solid #efefef;\n padding: 10px;\n font-size: 14px;\n"], ["\n display: flex;\n justify-content: center;\n align-items: center;\n border-bottom: 1px solid #efefef;\n padding: 10px;\n font-size: 14px;\n"])));
|
|
6692
6713
|
var StyledIconButton = styled(IconButton)(templateObject_3$1 || (templateObject_3$1 = __makeTemplateObject(["\n margin-top: -8px;\n margin-bottom: -10px;\n"], ["\n margin-top: -8px;\n margin-bottom: -10px;\n"])));
|
|
6693
6714
|
var StyledYearMonth = styled('div')(templateObject_4 || (templateObject_4 = __makeTemplateObject(["\n flex: 1;\n display: flex;\n align-items: center;\n justify-content: center;\n"], ["\n flex: 1;\n display: flex;\n align-items: center;\n justify-content: center;\n"])));
|
|
@@ -6695,7 +6716,9 @@ var StyledYearMonthError = styled('div')(templateObject_5 || (templateObject_5 =
|
|
|
6695
6716
|
var theme = _a.theme;
|
|
6696
6717
|
return theme.palette.error.main;
|
|
6697
6718
|
});
|
|
6698
|
-
var templateObject_1$3, templateObject_2$1, templateObject_3$1, templateObject_4, templateObject_5;var
|
|
6719
|
+
var templateObject_1$3, templateObject_2$1, templateObject_3$1, templateObject_4, templateObject_5;var valueToDate = function (v) { return dayjs("".concat(v.year, "-").concat(v.month, "-01")); };
|
|
6720
|
+
var valueToYm$1 = function (v) { return v.year * 100 + v.month; };
|
|
6721
|
+
var dateToValue$1 = function (v) { return ({ year: v.year(), month: v.month() + 1 }); };var DEFAULT_MIN_VALUE$3 = {
|
|
6699
6722
|
year: 2020,
|
|
6700
6723
|
month: 1,
|
|
6701
6724
|
};
|
|
@@ -6709,37 +6732,31 @@ var PrivateMonthPicker = function (_a) {
|
|
|
6709
6732
|
* ******************************************************************************************************************/
|
|
6710
6733
|
var _b = _a.value, initValue = _b === void 0 ? null : _b, _c = _a.minValue, minValue = _c === void 0 ? DEFAULT_MIN_VALUE$3 : _c, _d = _a.maxValue, maxValue = _d === void 0 ? DEFAULT_MAX_VALUE$3 : _d, disablePast = _a.disablePast, disableFuture = _a.disableFuture, selectFromValue = _a.selectFromValue, selectToValue = _a.selectToValue, onChange = _a.onChange;
|
|
6711
6734
|
var _e = useAutoUpdateState(initValue), value = _e[0], setValue = _e[1];
|
|
6712
|
-
/********************************************************************************************************************
|
|
6713
|
-
* Function
|
|
6714
|
-
* ******************************************************************************************************************/
|
|
6715
|
-
var valueToDate = useCallback(function (v) { return dayjs("".concat(v.year, "-").concat(v.month, "-01")); }, []);
|
|
6716
|
-
var valueToYm = useCallback(function (v) { return v.year * 100 + v.month; }, []);
|
|
6717
|
-
var dateToValue = useCallback(function (v) { return ({ year: v.year(), month: v.month() + 1 }); }, []);
|
|
6718
6735
|
/********************************************************************************************************************
|
|
6719
6736
|
* Memo
|
|
6720
6737
|
* ******************************************************************************************************************/
|
|
6721
|
-
var nowValue = useMemo(function () { return dateToValue(dayjs()); }, [
|
|
6722
|
-
var nowYm = useMemo(function () { return valueToYm(nowValue); }, [nowValue
|
|
6738
|
+
var nowValue = useMemo(function () { return dateToValue$1(dayjs()); }, []);
|
|
6739
|
+
var nowYm = useMemo(function () { return valueToYm$1(nowValue); }, [nowValue]);
|
|
6723
6740
|
var minAvailableValue = useMemo(function () {
|
|
6724
6741
|
if (disablePast) {
|
|
6725
|
-
var minYm = valueToYm(minValue);
|
|
6742
|
+
var minYm = valueToYm$1(minValue);
|
|
6726
6743
|
return nowYm > minYm ? nowValue : minValue;
|
|
6727
6744
|
}
|
|
6728
6745
|
else {
|
|
6729
6746
|
return minValue;
|
|
6730
6747
|
}
|
|
6731
|
-
}, [disablePast,
|
|
6732
|
-
var minAvailableYm = useMemo(function () { return valueToYm(minAvailableValue); }, [minAvailableValue
|
|
6748
|
+
}, [disablePast, minValue, nowYm, nowValue]);
|
|
6749
|
+
var minAvailableYm = useMemo(function () { return valueToYm$1(minAvailableValue); }, [minAvailableValue]);
|
|
6733
6750
|
var maxAvailableValue = useMemo(function () {
|
|
6734
6751
|
if (disableFuture) {
|
|
6735
|
-
var maxYm = valueToYm(maxValue);
|
|
6752
|
+
var maxYm = valueToYm$1(maxValue);
|
|
6736
6753
|
return nowYm < maxYm ? nowValue : maxValue;
|
|
6737
6754
|
}
|
|
6738
6755
|
else {
|
|
6739
6756
|
return maxValue;
|
|
6740
6757
|
}
|
|
6741
|
-
}, [disableFuture,
|
|
6742
|
-
var maxAvailableYm = useMemo(function () { return valueToYm(maxAvailableValue); }, [maxAvailableValue
|
|
6758
|
+
}, [disableFuture, maxValue, nowYm, nowValue]);
|
|
6759
|
+
var maxAvailableYm = useMemo(function () { return valueToYm$1(maxAvailableValue); }, [maxAvailableValue]);
|
|
6743
6760
|
var displayValue = useMemo(function () {
|
|
6744
6761
|
if (value && !Number.isNaN(value.year) && !Number.isNaN(value.month)) {
|
|
6745
6762
|
return value;
|
|
@@ -6766,7 +6783,7 @@ var PrivateMonthPicker = function (_a) {
|
|
|
6766
6783
|
selectToValue,
|
|
6767
6784
|
value,
|
|
6768
6785
|
]);
|
|
6769
|
-
var displayValueDate = useMemo(function () { return valueToDate(displayValue); }, [displayValue
|
|
6786
|
+
var displayValueDate = useMemo(function () { return valueToDate(displayValue); }, [displayValue]);
|
|
6770
6787
|
var displayValueYm = useMemo(function () { return displayValue.year * 100 + displayValue.month; }, [displayValue]);
|
|
6771
6788
|
var displayValueError = useMemo(function () { return displayValueYm < minAvailableYm || displayValueYm > maxAvailableYm; }, [displayValueYm, maxAvailableYm, minAvailableYm]);
|
|
6772
6789
|
/********************************************************************************************************************
|
|
@@ -6774,7 +6791,7 @@ var PrivateMonthPicker = function (_a) {
|
|
|
6774
6791
|
* ******************************************************************************************************************/
|
|
6775
6792
|
var handleYearChange = useCallback(function (year) {
|
|
6776
6793
|
var newValue = __assign(__assign({}, displayValue), { year: year });
|
|
6777
|
-
var valueYm = valueToYm(newValue);
|
|
6794
|
+
var valueYm = valueToYm$1(newValue);
|
|
6778
6795
|
if (valueYm < minAvailableYm) {
|
|
6779
6796
|
setValue(minAvailableValue);
|
|
6780
6797
|
onChange(minAvailableValue, false);
|
|
@@ -6787,21 +6804,21 @@ var PrivateMonthPicker = function (_a) {
|
|
|
6787
6804
|
setValue(newValue);
|
|
6788
6805
|
onChange(newValue, false);
|
|
6789
6806
|
}
|
|
6790
|
-
}, [displayValue, maxAvailableValue, maxAvailableYm, minAvailableValue, minAvailableYm, onChange, setValue
|
|
6807
|
+
}, [displayValue, maxAvailableValue, maxAvailableYm, minAvailableValue, minAvailableYm, onChange, setValue]);
|
|
6791
6808
|
var handleMonthChange = useCallback(function (newValue) {
|
|
6792
6809
|
setValue(newValue);
|
|
6793
6810
|
onChange(newValue, true);
|
|
6794
6811
|
}, [onChange, setValue]);
|
|
6795
6812
|
var handlePrevClick = useCallback(function () {
|
|
6796
|
-
var newValue = dateToValue(displayValueDate.subtract(1, 'months'));
|
|
6813
|
+
var newValue = dateToValue$1(displayValueDate.subtract(1, 'months'));
|
|
6797
6814
|
setValue(newValue);
|
|
6798
6815
|
onChange(newValue, false);
|
|
6799
|
-
}, [
|
|
6816
|
+
}, [displayValueDate, onChange, setValue]);
|
|
6800
6817
|
var handleNextClick = useCallback(function () {
|
|
6801
|
-
var newValue = dateToValue(displayValueDate.add(1, 'months'));
|
|
6818
|
+
var newValue = dateToValue$1(displayValueDate.add(1, 'months'));
|
|
6802
6819
|
setValue(newValue);
|
|
6803
6820
|
onChange(newValue, false);
|
|
6804
|
-
}, [
|
|
6821
|
+
}, [displayValueDate, onChange, setValue]);
|
|
6805
6822
|
/********************************************************************************************************************
|
|
6806
6823
|
* Render
|
|
6807
6824
|
* ******************************************************************************************************************/
|
|
@@ -6977,7 +6994,8 @@ var dateToValue = function (v) { return ({ year: v.year(), month: v.month() + 1
|
|
|
6977
6994
|
* ******************************************************************************************************************/
|
|
6978
6995
|
return (React.createElement(FormContextProvider, { value: __assign({ onAddValueItem: handleAddValueItem }, otherFormState) },
|
|
6979
6996
|
React.createElement(PrivateDatePicker, __assign({ className: classNames(className, 'FormDatePicker') }, props, { ref: ref, type: 'date' }))));
|
|
6980
|
-
});
|
|
6997
|
+
});
|
|
6998
|
+
FormDatePicker.displayName = 'FormDatePicker';var FormDateTimePicker = React.forwardRef(function (_a, ref) {
|
|
6981
6999
|
/********************************************************************************************************************
|
|
6982
7000
|
* FormState
|
|
6983
7001
|
* ******************************************************************************************************************/
|
|
@@ -6995,7 +7013,8 @@ var dateToValue = function (v) { return ({ year: v.year(), month: v.month() + 1
|
|
|
6995
7013
|
* ******************************************************************************************************************/
|
|
6996
7014
|
return (React.createElement(FormContextProvider, { value: __assign({ onAddValueItem: handleAddValueItem }, otherFormState) },
|
|
6997
7015
|
React.createElement(PrivateDateTimePicker, __assign({ className: classNames(className, 'FormDateTimePicker') }, props, { ref: ref, type: 'date_time' }))));
|
|
6998
|
-
});
|
|
7016
|
+
});
|
|
7017
|
+
FormDateTimePicker.displayName = 'FormDateTimePicker';var FormTimePicker = React.forwardRef(function (_a, ref) {
|
|
6999
7018
|
/********************************************************************************************************************
|
|
7000
7019
|
* FormState
|
|
7001
7020
|
* ******************************************************************************************************************/
|
|
@@ -7013,7 +7032,8 @@ var dateToValue = function (v) { return ({ year: v.year(), month: v.month() + 1
|
|
|
7013
7032
|
* ******************************************************************************************************************/
|
|
7014
7033
|
return (React.createElement(FormContextProvider, { value: __assign({ onAddValueItem: handleAddValueItem }, otherFormState) },
|
|
7015
7034
|
React.createElement(PrivateDateTimePicker, __assign({ className: classNames(className, 'FormTimePicker') }, props, { ref: ref, type: 'time' }))));
|
|
7016
|
-
});
|
|
7035
|
+
});
|
|
7036
|
+
FormTimePicker.displayName = 'FormTimePicker';var css_248z$3 = ".FormDateRangePickerTooltipPicker .MuiPickersCalendarHeader-root {\n display: none;\n}\n.FormDateRangePickerTooltipPicker .MuiDayPicker-header > span {\n margin: 0;\n}\n.FormDateRangePickerTooltipPicker .MuiPickerStaticWrapper-content {\n min-width: 292px;\n}\n.FormDateRangePickerTooltipPicker .MuiPickerStaticWrapper-content .MuiCalendarOrClockPicker-root > div {\n width: 292px;\n}\n.FormDateRangePickerTooltipPicker .MuiPickerStaticWrapper-content .MuiCalendarOrClockPicker-root > div .MuiCalendarPicker-root {\n width: 292px;\n}\n.FormDateRangePickerTooltipPicker .selected-bg {\n display: none;\n position: absolute;\n}\n.FormDateRangePickerTooltipPicker .selected-bg.sel {\n display: block;\n position: absolute;\n top: 0;\n bottom: 0;\n left: 0;\n right: 0;\n background-color: rgba(66, 165, 245, 0.6);\n}\n.FormDateRangePickerTooltipPicker .selected-bg.sel.ui-start, .FormDateRangePickerTooltipPicker .selected-bg.sel.s-start {\n border-top-left-radius: 50%;\n border-bottom-left-radius: 50%;\n}\n.FormDateRangePickerTooltipPicker .selected-bg.sel.ui-end, .FormDateRangePickerTooltipPicker .selected-bg.sel.s-end {\n border-top-right-radius: 50%;\n border-bottom-right-radius: 50%;\n}\n.FormDateRangePickerTooltipPicker .selected-bg.sel ~ .MuiPickersDay-root {\n border: 0;\n}\n.FormDateRangePickerTooltipPicker .selected-bg.sel ~ .MuiPickersDay-root:not(:hover):not(:active):not(.Mui-selected) {\n background-color: transparent;\n}\n.FormDateRangePickerTooltipPicker .focused-bg {\n display: none;\n position: absolute;\n}\n.FormDateRangePickerTooltipPicker .focused-bg.focused {\n display: block;\n position: absolute;\n top: 0;\n bottom: 0;\n left: 0;\n right: 0;\n border: 2px solid #efefef;\n border-left: 0;\n border-right: 0;\n}\n.FormDateRangePickerTooltipPicker .focused-bg.focused.ui-start, .FormDateRangePickerTooltipPicker .focused-bg.focused.f-start {\n border-left: 2px solid #efefef;\n border-top-left-radius: 50%;\n border-bottom-left-radius: 50%;\n}\n.FormDateRangePickerTooltipPicker .focused-bg.focused.ui-end, .FormDateRangePickerTooltipPicker .focused-bg.focused.f-end {\n border-right: 2px solid #efefef;\n border-top-right-radius: 50%;\n border-bottom-right-radius: 50%;\n}\n.FormDateRangePickerTooltipPicker .focused-bg.focused ~ .MuiPickersDay-root:not(:hover):not(:active):not(.Mui-selected) {\n background-color: transparent;\n}";
|
|
7017
7037
|
styleInject(css_248z$3);var FormDateRangePickerTooltipPicker = React.forwardRef(function (_a, ref) {
|
|
7018
7038
|
/********************************************************************************************************************
|
|
7019
7039
|
* State
|
|
@@ -8040,7 +8060,8 @@ var FormDateRangePicker = React.forwardRef(function (_a, ref) {
|
|
|
8040
8060
|
(error && errorHelperText) ||
|
|
8041
8061
|
(fromError && fromErrorHelperText) ||
|
|
8042
8062
|
(toError && toErrorHelperText)) && (React.createElement(FormHelperText, { error: error || fromError || toError, style: { marginLeft: variant === 'standard' ? 0 : 14 } }, error ? errorHelperText : fromError ? fromErrorHelperText : toError ? toErrorHelperText : helperText))))));
|
|
8043
|
-
});
|
|
8063
|
+
});
|
|
8064
|
+
FormDateRangePicker.displayName = 'FormDateRangePicker';var LinkDialog = function (_a) {
|
|
8044
8065
|
/********************************************************************************************************************
|
|
8045
8066
|
* Ref
|
|
8046
8067
|
* ******************************************************************************************************************/
|
|
@@ -8402,7 +8423,8 @@ var FormFile = React.forwardRef(function (_a, ref) {
|
|
|
8402
8423
|
!hideRemove && notEmpty(value) && (React.createElement(StyledPdgButton, { variant: 'outlined', tabIndex: removeTabIndex, className: classNames('remove-btn form-file-btn', !!hideRemoveLabel && 'hidden-label'), color: error ? 'error' : color, startIcon: 'close', size: size, disabled: disabled, onClick: handleRemoveClick }, !hideRemoveLabel && (removeLabel || '삭제'))))),
|
|
8403
8424
|
React.createElement(PrivateAlertDialog, __assign({}, alertDialogProps, { onClose: function () { return setAlertDialogProps({ open: false }); } })),
|
|
8404
8425
|
React.createElement(LinkDialog, { open: isOpenLinkDialog, onConfirm: handleLinkDialogConfirm, onClose: function () { return setIsOpenLinkDialog(false); } })) }));
|
|
8405
|
-
});
|
|
8426
|
+
});
|
|
8427
|
+
FormFile.displayName = 'FormFile';var css_248z = ".FormImageFile .preview-img {\n max-width: 100%;\n}\n.FormImageFile:not(.hide-file-name):not(.variant-standard) .preview-img {\n padding-right: 14px;\n}";
|
|
8406
8428
|
styleInject(css_248z);var FormImageFile = React.forwardRef(function (_a, ref) {
|
|
8407
8429
|
var className = _a.className, imageSize = _a.imageSize, preview = _a.preview, previewMaxHeight = _a.previewMaxHeight, _b = _a.accept, accept = _b === void 0 ? '.jpg,.jpeg,.png' : _b, initValue = _a.value, onChange = _a.onChange, onFile = _a.onFile, onLink = _a.onLink, props = __rest(_a, ["className", "imageSize", "preview", "previewMaxHeight", "accept", "value", "onChange", "onFile", "onLink"]);
|
|
8408
8430
|
var _c = useState({
|
|
@@ -8550,7 +8572,8 @@ styleInject(css_248z);var FormImageFile = React.forwardRef(function (_a, ref) {
|
|
|
8550
8572
|
return (React.createElement(React.Fragment, null,
|
|
8551
8573
|
React.createElement(FormFile, __assign({ ref: ref, className: classNames(className, 'FormImageFile'), accept: accept, value: value, preview: previewNode, onChange: handleChange, onFile: handleFile, onLink: handleLink }, props)),
|
|
8552
8574
|
React.createElement(PrivateAlertDialog, __assign({}, alertDialogProps, { onClose: function () { return setAlertDialogProps({ open: false }); } }))));
|
|
8553
|
-
});
|
|
8575
|
+
});
|
|
8576
|
+
FormImageFile.displayName = 'FormImageFile';var DEFAULT_VALUE$3 = null;
|
|
8554
8577
|
var DEFAULT_FORMAT$2 = 'YYYY년 MM월';
|
|
8555
8578
|
var DEFAULT_MIN_VALUE$1 = {
|
|
8556
8579
|
year: 2020,
|
|
@@ -8900,7 +8923,8 @@ var FormMonthPicker = React.forwardRef(function (_a, ref) {
|
|
|
8900
8923
|
React.createElement("div", null,
|
|
8901
8924
|
React.createElement(PrivateInputDatePicker, __assign({}, inputDatePickerProps, { style: inputStyle, sx: sx, value: valueDate, label: label, labelIcon: labelIcon, error: error, focused: focused, required: required, readOnly: readOnly, readOnlyInput: readOnlyInput, icon: icon, startAdornment: startAdornment, endAdornment: endAdornment, inputRef: inputRef, onChange: function (v) { return setValue(v ? dateToValue(v) : v); }, onFocus: handleInputDatePickerFocus, onError: function (reason) { return (inputDatePickerErrorRef.current = reason); }, shouldDisableYear: handleInputDatePickerShouldDisableYear })))),
|
|
8902
8925
|
!formColWithHelperText && (!!helperText || (error && !!errorHelperText)) && (React.createElement(FormHelperText, { error: error, style: { marginLeft: variant === 'standard' ? 0 : 14 } }, error ? errorHelperText : helperText))))));
|
|
8903
|
-
});
|
|
8926
|
+
});
|
|
8927
|
+
FormMonthPicker.displayName = 'FormMonthPicker';var DEFAULT_VALUE$2 = [null, null];
|
|
8904
8928
|
var DEFAULT_FORMAT$1 = 'YYYY년 MM월';
|
|
8905
8929
|
var DEFAULT_MIN_VALUE = {
|
|
8906
8930
|
year: 2020,
|
|
@@ -9355,7 +9379,8 @@ var FormMonthRangePicker = React.forwardRef(function (_a, ref) {
|
|
|
9355
9379
|
(error && errorHelperText) ||
|
|
9356
9380
|
(fromError && fromErrorHelperText) ||
|
|
9357
9381
|
(toError && toErrorHelperText)) && (React.createElement(FormHelperText, { error: error || fromError || toError, style: { marginLeft: variant === 'standard' ? 0 : 14 } }, error ? errorHelperText : fromError ? fromErrorHelperText : toError ? toErrorHelperText : helperText))))));
|
|
9358
|
-
});
|
|
9382
|
+
});
|
|
9383
|
+
FormMonthRangePicker.displayName = 'FormMonthRangePicker';var DEFAULT_VALUE$1 = null;
|
|
9359
9384
|
var DEFAULT_FORMAT = 'YYYY년 MM월';
|
|
9360
9385
|
var FormYearPicker = React.forwardRef(function (_a, ref) {
|
|
9361
9386
|
/********************************************************************************************************************
|
|
@@ -9653,7 +9678,8 @@ var FormYearPicker = React.forwardRef(function (_a, ref) {
|
|
|
9653
9678
|
React.createElement("div", null,
|
|
9654
9679
|
React.createElement(PrivateInputDatePicker, __assign({}, inputDatePickerProps, { style: inputStyle, sx: sx, value: valueDate, label: label, labelIcon: labelIcon, error: error, focused: focused, required: required, readOnly: readOnly, readOnlyInput: readOnlyInput, icon: icon, startAdornment: startAdornment, endAdornment: endAdornment, inputRef: inputRef, onChange: handleInputDatePickerChange, onFocus: handleInputDatePickerFocus, onError: function (reason) { return (inputDatePickerErrorRef.current = reason); }, shouldDisableYear: handleInputDatePickerShouldDisableYear })))),
|
|
9655
9680
|
!formColWithHelperText && (!!helperText || (error && !!errorHelperText)) && (React.createElement(FormHelperText, { error: error, style: { marginLeft: variant === 'standard' ? 0 : 14 } }, error ? errorHelperText : helperText))))));
|
|
9656
|
-
});
|
|
9681
|
+
});
|
|
9682
|
+
FormYearPicker.displayName = 'FormYearPicker';var DEFAULT_VALUE = [null, null];
|
|
9657
9683
|
var FormYearRangePicker = React.forwardRef(function (_a, ref) {
|
|
9658
9684
|
/********************************************************************************************************************
|
|
9659
9685
|
* ID
|
|
@@ -10008,7 +10034,8 @@ var FormYearRangePicker = React.forwardRef(function (_a, ref) {
|
|
|
10008
10034
|
(error && errorHelperText) ||
|
|
10009
10035
|
(fromError && fromErrorHelperText) ||
|
|
10010
10036
|
(toError && toErrorHelperText)) && (React.createElement(FormHelperText, { error: error || fromError || toError, style: { marginLeft: variant === 'standard' ? 0 : 14 } }, error ? errorHelperText : fromError ? fromErrorHelperText : toError ? toErrorHelperText : helperText))))));
|
|
10011
|
-
});
|
|
10037
|
+
});
|
|
10038
|
+
FormYearRangePicker.displayName = 'FormYearRangePicker';var FormSwitch = React.forwardRef(function (_a, ref) {
|
|
10012
10039
|
/********************************************************************************************************************
|
|
10013
10040
|
* ID
|
|
10014
10041
|
* ******************************************************************************************************************/
|
|
@@ -10178,7 +10205,8 @@ var FormYearRangePicker = React.forwardRef(function (_a, ref) {
|
|
|
10178
10205
|
* ******************************************************************************************************************/
|
|
10179
10206
|
var switchControl = useMemo(function () { return (React.createElement(Switch, { size: size, name: name, checked: value, color: color, disabled: disabled, onChange: handleChange, onFocus: function () { return setFocused(initFocused || true); }, onBlur: function () { return setFocused(initFocused || false); } })); }, [color, disabled, handleChange, initFocused, name, setFocused, size, value]);
|
|
10180
10207
|
return (React.createElement(FormItemBase, { variant: variant, size: size, color: color, focused: focused, className: classNames(className, 'FormValueItem', 'FormSwitch'), labelIcon: labelIcon, label: label, error: error, fullWidth: false, helperText: error ? errorHelperText : helperText, helperTextProps: { style: { marginLeft: 5 } }, style: style, sx: sx, hidden: hidden, autoSize: true, controlHeight: size === 'small' ? 21 : 26, controlVerticalCenter: true, control: switchLabel ? (React.createElement(FormControlLabel, { control: switchControl, label: switchLabel, disabled: disabled })) : (switchControl) }));
|
|
10181
|
-
});
|
|
10208
|
+
});
|
|
10209
|
+
FormSwitch.displayName = 'FormSwitch';var SearchGroupRow = function (_a) {
|
|
10182
10210
|
var children = _a.children, props = __rest(_a, ["children"]);
|
|
10183
10211
|
return (React.createElement(FormRow, __assign({}, props),
|
|
10184
10212
|
React.createElement(FormCol, null,
|
package/dist/index.js
CHANGED
|
@@ -1299,14 +1299,17 @@ styleInject(css_248z$l);var FormTextField = React.forwardRef(function (_a, ref)
|
|
|
1299
1299
|
* Render
|
|
1300
1300
|
* ******************************************************************************************************************/
|
|
1301
1301
|
return (React.createElement(material.TextField, __assign({}, props, { variant: variant, size: size, color: color, focused: focused || undefined, name: name, label: label, placeholder: placeholder, className: classNames(className, 'FormValueItem', 'FormTextField', "variant-".concat(variant)), inputRef: initInputRef ? initInputRef : inputRef, value: value, required: required, fullWidth: !width && fullWidth, error: error, helperText: formColWithHelperText ? undefined : error ? errorHelperText : helperText, FormHelperTextProps: { component: 'div' }, disabled: disabled, InputProps: muiInputProps, InputLabelProps: muiInputLabelProps, inputProps: ((_b = initInputProps === null || initInputProps === void 0 ? void 0 : initInputProps.className) === null || _b === void 0 ? void 0 : _b.includes('FormTag-Input')) ? initInputProps : inputProps, style: style, select: select, SelectProps: SelectProps, multiline: multiline, onChange: handleChange, onBlur: handleBlur, onKeyDown: handleKeyDown })));
|
|
1302
|
-
});
|
|
1302
|
+
});
|
|
1303
|
+
FormTextField.displayName = 'FormTextField';var css_248z$k = ".FormHidden {\n display: none !important;\n}";
|
|
1303
1304
|
styleInject(css_248z$k);var FormHidden = React.forwardRef(function (_a, ref) {
|
|
1304
1305
|
var className = _a.className, props = __rest(_a, ["className"]);
|
|
1305
1306
|
return (React.createElement(FormTextField, __assign({ ref: ref, className: classNames(className, 'FormHidden'), type: 'hidden', variant: 'standard' }, props)));
|
|
1306
|
-
});
|
|
1307
|
+
});
|
|
1308
|
+
FormHidden.displayName = 'FormHidden';var FormText = React.forwardRef(function (_a, ref) {
|
|
1307
1309
|
var className = _a.className, _b = _a.clear, clear = _b === void 0 ? true : _b, _c = _a.value, value = _c === void 0 ? '' : _c, props = __rest(_a, ["className", "clear", "value"]);
|
|
1308
1310
|
return (React.createElement(FormTextField, __assign({ ref: ref, className: classNames(className, 'FormText'), clear: clear, value: value, disableReturnKey: true }, props)));
|
|
1309
|
-
});
|
|
1311
|
+
});
|
|
1312
|
+
FormText.displayName = 'FormText';var css_248z$j = ".FormTag.FormTextField {\n min-width: 200px;\n}";
|
|
1310
1313
|
styleInject(css_248z$j);var FormTag = React.forwardRef(function (_a, ref) {
|
|
1311
1314
|
/********************************************************************************************************************
|
|
1312
1315
|
* FormState
|
|
@@ -1505,7 +1508,8 @@ styleInject(css_248z$j);var FormTag = React.forwardRef(function (_a, ref) {
|
|
|
1505
1508
|
delete renderProps.inputProps.value;
|
|
1506
1509
|
return (React.createElement(FormText, __assign({}, renderProps, { ref: handleRef, name: name, className: classNames(className, 'FormValueItem', 'FormTag'), error: error, disabled: disabled, fullWidth: fullWidth, required: required, value: inputValue, exceptValue: exceptValue, helperText: error ? errorHelperText : helperText, onKeyDown: handleInputKeyDown, onChange: handleInputChange, onBlur: handleBlur })));
|
|
1507
1510
|
} })));
|
|
1508
|
-
});
|
|
1511
|
+
});
|
|
1512
|
+
FormTag.displayName = 'FormTag';var FormEmail = React.forwardRef(function (_a, ref) {
|
|
1509
1513
|
var className = _a.className, _b = _a.validPattern, validPattern = _b === void 0 ? /^(([^<>()[\].,;:\s@"]+(\.[^<>()[\].,;:\s@"]+)*)|(".+"))@(([^<>()[\].,;:\s@"]+\.)+[^<>()[\].,;:\s@"]{2,})$/g : _b, onValue = _a.onValue, props = __rest(_a, ["className", "validPattern", "onValue"]);
|
|
1510
1514
|
var handleValue = React.useCallback(function (value) {
|
|
1511
1515
|
var newValue = value.replace(/ /gi, '');
|
|
@@ -1515,7 +1519,8 @@ styleInject(css_248z$j);var FormTag = React.forwardRef(function (_a, ref) {
|
|
|
1515
1519
|
* Render
|
|
1516
1520
|
* ******************************************************************************************************************/
|
|
1517
1521
|
return (React.createElement(FormText, __assign({ ref: ref, className: classNames(className, 'FormEmail'), type: 'email', validPattern: validPattern, onValue: handleValue }, props)));
|
|
1518
|
-
});
|
|
1522
|
+
});
|
|
1523
|
+
FormEmail.displayName = 'FormEmail';var css_248z$i = ".FormPassword .eye-icon-button-wrap {\n visibility: hidden;\n}\n.FormPassword.variant-filled .eye-icon-button-wrap {\n margin-top: 9px;\n margin-bottom: -9px;\n}\n.FormPassword:hover .eye-icon-button-wrap.show,\n.FormPassword .MuiInputBase-root.Mui-focused .eye-icon-button-wrap.show {\n visibility: visible;\n}";
|
|
1519
1524
|
styleInject(css_248z$i);var StyledEyeInputAdornment = material.styled(material.InputAdornment)(templateObject_1$c || (templateObject_1$c = __makeTemplateObject(["\n visibility: hidden;\n"], ["\n visibility: hidden;\n"])));
|
|
1520
1525
|
var FormPassword = React.forwardRef(function (_a, ref) {
|
|
1521
1526
|
/********************************************************************************************************************
|
|
@@ -1555,6 +1560,7 @@ var FormPassword = React.forwardRef(function (_a, ref) {
|
|
|
1555
1560
|
* ******************************************************************************************************************/
|
|
1556
1561
|
return (React.createElement(FormText, __assign({ ref: ref, className: classNames(className, 'FormPassword'), onChange: handleChange, type: type, InputProps: muiInputProps, clear: clear }, props)));
|
|
1557
1562
|
});
|
|
1563
|
+
FormPassword.displayName = 'FormPassword';
|
|
1558
1564
|
var templateObject_1$c;var FormTel = React.forwardRef(function (_a, ref) {
|
|
1559
1565
|
/********************************************************************************************************************
|
|
1560
1566
|
* Event Handler
|
|
@@ -1568,10 +1574,12 @@ var templateObject_1$c;var FormTel = React.forwardRef(function (_a, ref) {
|
|
|
1568
1574
|
* Render
|
|
1569
1575
|
* ******************************************************************************************************************/
|
|
1570
1576
|
return (React.createElement(FormText, __assign({ ref: ref, className: classNames(className, 'FormTel'), onValue: handleValue, maxLength: 13, validPattern: validPattern }, props)));
|
|
1571
|
-
});
|
|
1577
|
+
});
|
|
1578
|
+
FormTel.displayName = 'FormTel';var FormMobile = React.forwardRef(function (_a, ref) {
|
|
1572
1579
|
var className = _a.className, _b = _a.validPattern, validPattern = _b === void 0 ? /(^(01(?:0|1|[6-9]))([0-9]{3,4})([0-9]{4,4})$)|(^(01(?:0|1|[6-9]))-([0-9]{3,4})-([0-9]{4,4})$)|(^\+(?:[-]?[0-9]){8,}$)/ : _b, props = __rest(_a, ["className", "validPattern"]);
|
|
1573
1580
|
return React.createElement(FormTel, __assign({ ref: ref, className: classNames(className, 'FormMobile'), validPattern: validPattern }, props));
|
|
1574
|
-
});
|
|
1581
|
+
});
|
|
1582
|
+
FormMobile.displayName = 'FormMobile';var NumberFormatCustom = React.forwardRef(function (_a, ref) {
|
|
1575
1583
|
var onChange = _a.onChange, props = __rest(_a, ["onChange"]);
|
|
1576
1584
|
return (React.createElement(reactNumberFormat.NumericFormat, __assign({}, props, { getInputRef: ref, onValueChange: function (values) {
|
|
1577
1585
|
if (onChange)
|
|
@@ -1651,15 +1659,18 @@ var templateObject_1$c;var FormTel = React.forwardRef(function (_a, ref) {
|
|
|
1651
1659
|
* Render
|
|
1652
1660
|
* ******************************************************************************************************************/
|
|
1653
1661
|
return (React.createElement(FormTextField, __assign({ ref: ref, className: classNames(className, 'FormNumber'), disableReturnKey: true, labelShrink: strValue === '' || strValue === undefined ? labelShrink : true, InputProps: muiInputProps, readOnly: readOnly, clear: clear, value: strValue, onChange: handleChange, onValue: handleValue, onValidate: handleValidate }, props)));
|
|
1654
|
-
});
|
|
1662
|
+
});
|
|
1663
|
+
FormNumber.displayName = 'FormNumber';var css_248z$h = ".FormSearch input[type=search]::-webkit-search-decoration,\n.FormSearch input[type=search]::-webkit-search-cancel-button,\n.FormSearch input[type=search]::-webkit-search-results-button,\n.FormSearch input[type=search]::-webkit-search-results-decoration {\n -webkit-appearance: none;\n}";
|
|
1655
1664
|
styleInject(css_248z$h);var FormSearch = React.forwardRef(function (_a, ref) {
|
|
1656
1665
|
var className = _a.className, props = __rest(_a, ["className"]);
|
|
1657
1666
|
return React.createElement(FormText, __assign({ className: classNames(className, 'FormSearch'), ref: ref, type: 'search' }, props));
|
|
1658
|
-
});
|
|
1667
|
+
});
|
|
1668
|
+
FormSearch.displayName = 'FormSearch';var css_248z$g = ".FormTextarea .MuiInputBase-root .MuiInputBase-input {\n overflow-y: scroll;\n}\n.FormTextarea .MuiInputBase-root .MuiInputBase-input::-webkit-scrollbar {\n width: 8px;\n}\n.FormTextarea .MuiInputBase-root .MuiInputBase-input::-webkit-scrollbar-thumb {\n background-color: rgba(0, 0, 0, 0.1882352941);\n background-clip: padding-box;\n border-left: 4px transparent solid;\n}";
|
|
1659
1669
|
styleInject(css_248z$g);var FormTextarea = React.forwardRef(function (_a, ref) {
|
|
1660
1670
|
var className = _a.className, _b = _a.clear, clear = _b === void 0 ? false : _b, _c = _a.rows, rows = _c === void 0 ? 3 : _c, _d = _a.value, value = _d === void 0 ? '' : _d, props = __rest(_a, ["className", "clear", "rows", "value"]);
|
|
1661
1671
|
return (React.createElement(FormTextField, __assign({ ref: ref, className: classNames(className, 'FormTextarea'), clear: clear, rows: rows, value: value }, props, { multiline: true })));
|
|
1662
|
-
});
|
|
1672
|
+
});
|
|
1673
|
+
FormTextarea.displayName = 'FormTextarea';var FormUrl = React.forwardRef(function (_a, ref) {
|
|
1663
1674
|
/********************************************************************************************************************
|
|
1664
1675
|
* Event Handler
|
|
1665
1676
|
* ******************************************************************************************************************/
|
|
@@ -1672,7 +1683,8 @@ styleInject(css_248z$g);var FormTextarea = React.forwardRef(function (_a, ref) {
|
|
|
1672
1683
|
* Render
|
|
1673
1684
|
* ******************************************************************************************************************/
|
|
1674
1685
|
return (React.createElement(FormText, __assign({ ref: ref, className: classNames(className, 'FormUrl'), type: 'url', validPattern: validPattern, onValue: handleValue }, props)));
|
|
1675
|
-
});
|
|
1686
|
+
});
|
|
1687
|
+
FormUrl.displayName = 'FormUrl';function getDateValidationErrorText(error) {
|
|
1676
1688
|
switch (error) {
|
|
1677
1689
|
case 'invalidDate':
|
|
1678
1690
|
return '형식이 일치하지 않습니다.';
|
|
@@ -2260,7 +2272,8 @@ styleInject(css_248z$f);var FormSelect = ToForwardRefExoticComponent(AutoTypeFor
|
|
|
2260
2272
|
multiple && checkbox && Array.isArray(value) && React.createElement(material.Checkbox, { checked: value.includes(itemValue) }),
|
|
2261
2273
|
itemLabel));
|
|
2262
2274
|
})) : (React.createElement(material.MenuItem, { value: '' })))));
|
|
2263
|
-
}));
|
|
2275
|
+
}));
|
|
2276
|
+
FormSelect.displayName = 'FormSelect';var FormCompanyNo = React.forwardRef(function (_a, ref) {
|
|
2264
2277
|
/********************************************************************************************************************
|
|
2265
2278
|
* Event Handler
|
|
2266
2279
|
* ******************************************************************************************************************/
|
|
@@ -2273,7 +2286,8 @@ styleInject(css_248z$f);var FormSelect = ToForwardRefExoticComponent(AutoTypeFor
|
|
|
2273
2286
|
* Render
|
|
2274
2287
|
* ******************************************************************************************************************/
|
|
2275
2288
|
return (React.createElement(FormText, __assign({ ref: ref, className: classNames(className, 'FormCompanyNo'), maxLength: 12, validPattern: validPattern, onValue: handleValue }, props)));
|
|
2276
|
-
});
|
|
2289
|
+
});
|
|
2290
|
+
FormCompanyNo.displayName = 'FormCompanyNo';var FormPersonalNo = React.forwardRef(function (_a, ref) {
|
|
2277
2291
|
/********************************************************************************************************************
|
|
2278
2292
|
* Event Handler
|
|
2279
2293
|
* ******************************************************************************************************************/
|
|
@@ -2320,7 +2334,8 @@ styleInject(css_248z$f);var FormSelect = ToForwardRefExoticComponent(AutoTypeFor
|
|
|
2320
2334
|
* Render
|
|
2321
2335
|
* ******************************************************************************************************************/
|
|
2322
2336
|
return (React.createElement(FormText, __assign({ ref: ref, className: classNames(className, 'FormPersonalNo'), maxLength: 14, validPattern: validPattern, onValue: handleValue, onValidate: handleValidate }, props)));
|
|
2323
|
-
});
|
|
2337
|
+
});
|
|
2338
|
+
FormPersonalNo.displayName = 'FormPersonalNo';var css_248z$e = ".FormItemBase .FormItemBase-InputLabel {\n overflow: visible;\n padding-left: 5px;\n}\n.FormItemBase .FormItemBase-InputLabel.MuiInputLabel-sizeSmall {\n transform: translate(0, -1.5px) scale(0.7);\n}\n.FormItemBase .FormItemBase-Control-wrap {\n position: relative;\n}\n.FormItemBase .FormItemBase-Control {\n position: absolute;\n left: 0;\n top: 0;\n}\n.FormItemBase.variant-standard .FormItemBase-Control-wrap {\n margin-top: 16px;\n}";
|
|
2324
2339
|
styleInject(css_248z$e);var FormItemBase = React.forwardRef(function (_a, ref) {
|
|
2325
2340
|
/********************************************************************************************************************
|
|
2326
2341
|
* Ref
|
|
@@ -2452,7 +2467,8 @@ styleInject(css_248z$e);var FormItemBase = React.forwardRef(function (_a, ref) {
|
|
|
2452
2467
|
marginTop: controlMarginTop,
|
|
2453
2468
|
} }, control))),
|
|
2454
2469
|
!formColWithHelperText && helperText && (React.createElement(material.FormHelperText, __assign({ component: 'div' }, helperTextProps), helperText)))));
|
|
2455
|
-
});
|
|
2470
|
+
});
|
|
2471
|
+
FormItemBase.displayName = 'FormItemBase';var FormCheckbox = React.forwardRef(function (_a, ref) {
|
|
2456
2472
|
/********************************************************************************************************************
|
|
2457
2473
|
* ID
|
|
2458
2474
|
* ******************************************************************************************************************/
|
|
@@ -2648,7 +2664,8 @@ styleInject(css_248z$e);var FormItemBase = React.forwardRef(function (_a, ref) {
|
|
|
2648
2664
|
* Render
|
|
2649
2665
|
* ******************************************************************************************************************/
|
|
2650
2666
|
return (React.createElement(FormItemBase, { variant: variant, size: size, color: color, focused: focused, className: classNames(className, 'FormValueItem', 'FormCheckbox'), labelIcon: labelIcon, label: label, error: error, fullWidth: fullWidth, helperText: error ? errorHelperText : helperText, helperTextProps: { style: { marginLeft: 2 } }, style: style, sx: sx, hidden: hidden, autoSize: true, controlHeight: height || (size === 'small' ? 35 : 39), controlVerticalCenter: true, control: React.createElement(material.FormControlLabel, { ref: labelRef, control: React.createElement(material.Checkbox, __assign({ name: name, color: color, size: size, inputRef: initInputRef ? initInputRef : inputRef, action: initAction ? initAction : actionRef, checked: checked, checkedIcon: React.createElement(iconsMaterial.CheckBox, { color: error ? 'error' : undefined }), icon: React.createElement(iconsMaterial.CheckBoxOutlineBlank, { color: error ? 'error' : undefined }), onChange: handleChange, disabled: disabled || readOnly }, props)), label: React.createElement(material.Typography, { color: error ? 'error' : readOnly || disabled ? theme.palette.text.disabled : undefined, whiteSpace: 'nowrap' }, text) }) }));
|
|
2651
|
-
});
|
|
2667
|
+
});
|
|
2668
|
+
FormCheckbox.displayName = 'FormCheckbox';var PADDING_LEFT = 3;
|
|
2652
2669
|
var FormRadioGroup = ToForwardRefExoticComponent(AutoTypeForwardRef(function (_a, ref) {
|
|
2653
2670
|
/********************************************************************************************************************
|
|
2654
2671
|
* type
|
|
@@ -2966,7 +2983,8 @@ var FormRadioGroup = ToForwardRefExoticComponent(AutoTypeForwardRef(function (_a
|
|
|
2966
2983
|
var value = _a.value, label = _a.label, itemDisabled = _a.disabled;
|
|
2967
2984
|
return (React.createElement(material.FormControlLabel, { key: idx, control: React.createElement(material.Radio, { icon: React.createElement(iconsMaterial.RadioButtonUnchecked, { color: error ? 'error' : undefined }), checkedIcon: React.createElement(iconsMaterial.RadioButtonChecked, { color: error ? 'error' : undefined }), color: color, size: size, inputRef: idx === 0 ? firstInputRef : null }), label: label, style: { color: error ? theme.palette.error.main : '', marginTop: -10, whiteSpace: 'nowrap' }, value: value, disabled: disabled || readOnly || itemDisabled }));
|
|
2968
2985
|
})))))) }));
|
|
2969
|
-
}));
|
|
2986
|
+
}));
|
|
2987
|
+
FormRadioGroup.displayName = 'FormRadioGroup';var css_248z$d = ".FormToggleButtonGroup .ToggleButton {\n display: inline-flex;\n padding: 0 10px;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n align-items: center;\n}\n.FormToggleButtonGroup .ToggleButton .__label__ {\n height: 0;\n line-height: 0 !important;\n overflow: visible !important;\n}\n.FormToggleButtonGroup.type-checkbox .ToggleButton, .FormToggleButtonGroup.type-radio .ToggleButton {\n padding-left: 3px;\n padding-right: 5px;\n border: 0 !important;\n margin-left: 0 !important;\n justify-content: flex-start;\n display: flex;\n background-color: transparent !important;\n}\n.FormToggleButtonGroup.type-checkbox .ToggleButton:not(:last-child), .FormToggleButtonGroup.type-radio .ToggleButton:not(:last-child) {\n margin-right: 5px;\n}\n.FormToggleButtonGroup.type-checkbox .ToggleButton .__checkbox-checked__,\n.FormToggleButtonGroup.type-checkbox .ToggleButton .__checkbox-unchecked__, .FormToggleButtonGroup.type-radio .ToggleButton .__checkbox-checked__,\n.FormToggleButtonGroup.type-radio .ToggleButton .__checkbox-unchecked__ {\n margin-right: 3px;\n}\n.FormToggleButtonGroup.type-checkbox .ToggleButton .__checkbox-checked__, .FormToggleButtonGroup.type-radio .ToggleButton .__checkbox-checked__ {\n display: none;\n}\n.FormToggleButtonGroup.type-checkbox .ToggleButton.Mui-selected .__checkbox-checked__, .FormToggleButtonGroup.type-radio .ToggleButton.Mui-selected .__checkbox-checked__ {\n display: block;\n}\n.FormToggleButtonGroup.type-checkbox .ToggleButton.Mui-selected .__checkbox-unchecked__, .FormToggleButtonGroup.type-radio .ToggleButton.Mui-selected .__checkbox-unchecked__ {\n display: none;\n}\n.FormToggleButtonGroup:not(.with-label).variant-outlined .FormItemBase-Control-wrap {\n margin-top: 15px;\n margin-bottom: -15px;\n}\n.FormToggleButtonGroup:not(.with-label).variant-outlined .FormItemBase-Control-wrap .ToggleButton {\n height: 37px;\n}\n.FormToggleButtonGroup:not(.with-label).variant-filled .FormItemBase-Control-wrap {\n margin-top: 15px;\n margin-bottom: -15px;\n}\n.FormToggleButtonGroup:not(.with-label).variant-filled .FormItemBase-Control-wrap .ToggleButton {\n height: 37px;\n}\n.FormToggleButtonGroup:not(.with-label).variant-standard .FormItemBase-Control-wrap {\n margin-top: 0px;\n margin-bottom: 0px;\n}\n.FormToggleButtonGroup:not(.with-label).variant-standard .FormItemBase-Control-wrap .ToggleButton {\n height: 28px;\n}\n.FormToggleButtonGroup:not(.with-label).size-small.variant-outlined .FormItemBase-Control-wrap {\n margin-top: 13px;\n margin-bottom: -13px;\n}\n.FormToggleButtonGroup:not(.with-label).size-small.variant-outlined .FormItemBase-Control-wrap .ToggleButton {\n height: 24px;\n}\n.FormToggleButtonGroup:not(.with-label).size-small.variant-filled .FormItemBase-Control-wrap {\n margin-top: 13px;\n margin-bottom: -13px;\n}\n.FormToggleButtonGroup:not(.with-label).size-small.variant-filled .FormItemBase-Control-wrap .ToggleButton {\n height: 31px;\n}\n.FormToggleButtonGroup:not(.with-label).size-small.variant-standard .FormItemBase-Control-wrap {\n margin-top: 0px;\n margin-bottom: 0px;\n}\n.FormToggleButtonGroup:not(.with-label).size-small.variant-standard .FormItemBase-Control-wrap .ToggleButton {\n height: 26px;\n}\n.FormToggleButtonGroup.with-label.variant-outlined .FormItemBase-Control-wrap {\n margin-top: 0;\n margin-bottom: 0;\n}\n.FormToggleButtonGroup.with-label.variant-outlined .FormItemBase-Control-wrap .ToggleButton {\n height: 37px;\n}\n.FormToggleButtonGroup.with-label.variant-filled .FormItemBase-Control-wrap {\n margin-top: 0;\n margin-bottom: 0;\n}\n.FormToggleButtonGroup.with-label.variant-filled .FormItemBase-Control-wrap .ToggleButton {\n height: 37px;\n}\n.FormToggleButtonGroup.with-label.variant-standard .FormItemBase-Control-wrap {\n margin-top: 0;\n margin-bottom: 0;\n}\n.FormToggleButtonGroup.with-label.variant-standard .FormItemBase-Control-wrap .ToggleButton {\n height: 28px;\n}\n.FormToggleButtonGroup.with-label.size-small.variant-outlined .FormItemBase-Control-wrap {\n margin-top: 0;\n margin-bottom: 0;\n}\n.FormToggleButtonGroup.with-label.size-small.variant-outlined .FormItemBase-Control-wrap .ToggleButton {\n height: 24px;\n}\n.FormToggleButtonGroup.with-label.size-small.variant-filled .FormItemBase-Control-wrap {\n margin-top: 0;\n margin-bottom: 0;\n}\n.FormToggleButtonGroup.with-label.size-small.variant-filled .FormItemBase-Control-wrap .ToggleButton {\n height: 31px;\n}\n.FormToggleButtonGroup.with-label.size-small.variant-standard .FormItemBase-Control-wrap {\n margin-top: 0;\n margin-bottom: 0;\n}\n.FormToggleButtonGroup.with-label.size-small.variant-standard .FormItemBase-Control-wrap .ToggleButton {\n height: 26px;\n}\n\n.Form .FormCol.with-label .FormToggleButtonGroup.variant-outlined .FormItemBase-Control-wrap {\n margin-top: 0;\n margin-bottom: 0;\n}\n.Form .FormCol.with-label .FormToggleButtonGroup.variant-outlined .FormItemBase-Control-wrap .ToggleButton {\n height: 37px;\n}\n.Form .FormCol.with-label .FormToggleButtonGroup.variant-filled .FormItemBase-Control-wrap {\n margin-top: 0;\n margin-bottom: 0;\n}\n.Form .FormCol.with-label .FormToggleButtonGroup.variant-filled .FormItemBase-Control-wrap .ToggleButton {\n height: 37px;\n}\n.Form .FormCol.with-label .FormToggleButtonGroup.variant-standard .FormItemBase-Control-wrap {\n margin-top: 0;\n margin-bottom: 0;\n}\n.Form .FormCol.with-label .FormToggleButtonGroup.variant-standard .FormItemBase-Control-wrap .ToggleButton {\n height: 28px;\n}\n.Form .FormCol.with-label .FormToggleButtonGroup.size-small.variant-outlined .FormItemBase-Control-wrap {\n margin-top: 0;\n margin-bottom: 0;\n}\n.Form .FormCol.with-label .FormToggleButtonGroup.size-small.variant-outlined .FormItemBase-Control-wrap .ToggleButton {\n height: 24px;\n}\n.Form .FormCol.with-label .FormToggleButtonGroup.size-small.variant-filled .FormItemBase-Control-wrap {\n margin-top: 0;\n margin-bottom: 0;\n}\n.Form .FormCol.with-label .FormToggleButtonGroup.size-small.variant-filled .FormItemBase-Control-wrap .ToggleButton {\n height: 31px;\n}\n.Form .FormCol.with-label .FormToggleButtonGroup.size-small.variant-standard .FormItemBase-Control-wrap {\n margin-top: 0;\n margin-bottom: 0;\n}\n.Form .FormCol.with-label .FormToggleButtonGroup.size-small.variant-standard .FormItemBase-Control-wrap .ToggleButton {\n height: 26px;\n}";
|
|
2970
2988
|
styleInject(css_248z$d);var FormToggleButtonGroup = ToForwardRefExoticComponent(AutoTypeForwardRef(function (_a, ref) {
|
|
2971
2989
|
/********************************************************************************************************************
|
|
2972
2990
|
* type
|
|
@@ -3405,7 +3423,8 @@ styleInject(css_248z$d);var FormToggleButtonGroup = ToForwardRefExoticComponent(
|
|
|
3405
3423
|
: undefined,
|
|
3406
3424
|
flexWrap: type === 'checkbox' || type === 'radio' ? 'wrap' : 'nowrap',
|
|
3407
3425
|
}, "aria-labelledby": util.notEmpty(label) ? labelId : undefined }, isOnGetItemLoading || loading || !items || util.empty(items) ? (React.createElement(material.ToggleButton, { ref: refForButtonResizeHeightDetect, size: size, className: 'ToggleButton', disabled: disabled || readOnly, value: '', style: { visibility: 'hidden' } })) : (buttons)))) })));
|
|
3408
|
-
}));
|
|
3426
|
+
}));
|
|
3427
|
+
FormToggleButtonGroup.displayName = 'FormToggleButtonGroup';var FormRating = React.forwardRef(function (_a, ref) {
|
|
3409
3428
|
/********************************************************************************************************************
|
|
3410
3429
|
* ID
|
|
3411
3430
|
* ******************************************************************************************************************/
|
|
@@ -3600,7 +3619,8 @@ styleInject(css_248z$d);var FormToggleButtonGroup = ToForwardRefExoticComponent(
|
|
|
3600
3619
|
* Render
|
|
3601
3620
|
* ******************************************************************************************************************/
|
|
3602
3621
|
return (React.createElement(FormItemBase, { variant: variant, size: size, color: color, focused: focused, className: classNames(className, 'FormValueItem', 'FormRating'), labelIcon: labelIcon, label: label, error: error, fullWidth: false, required: required, helperText: error ? errorHelperText : helperText, helperTextProps: { style: { marginLeft: 5 } }, style: style, sx: sx, hidden: hidden, autoSize: true, controlHeight: height || (size === 'small' ? 21 : 26), controlVerticalCenter: true, control: React.createElement(material.Rating, { ref: ratingRef, size: size === 'medium' ? 'large' : 'medium', name: name, precision: precision, highlightSelectedOnly: highlightSelectedOnly, value: value, disabled: disabled || readOnly, max: max, icon: React.createElement(reactComponent.PdgIcon, { color: color, size: 'inherit' }, icon ? icon : 'Star'), emptyIcon: React.createElement(reactComponent.PdgIcon, { size: 'inherit' }, emptyIcon ? emptyIcon : 'StarBorder'), onChange: handleChange, onFocus: function () { return setFocused(initFocused || true); }, onBlur: function () { return setFocused(initFocused || false); } }) }));
|
|
3603
|
-
});
|
|
3622
|
+
});
|
|
3623
|
+
FormRating.displayName = 'FormRating';var css_248z$c = ".FormTextEditor.initializing textarea {\n display: none;\n}\n.FormTextEditor.error .tox-tinymce {\n border-color: #d32f2f;\n}\n\n.tox-menu.tox-collection.tox-collection--list .tox-collection__group .tox-menu-nav__js.tox-collection__item {\n padding-right: 20px !important;\n}\n\n.tox-notifications-container {\n display: none;\n}";
|
|
3604
3624
|
styleInject(css_248z$c);var FormTextEditor = React.forwardRef(function (_a, ref) {
|
|
3605
3625
|
/********************************************************************************************************************
|
|
3606
3626
|
* ID
|
|
@@ -3824,7 +3844,8 @@ styleInject(css_248z$c);var FormTextEditor = React.forwardRef(function (_a, ref)
|
|
|
3824
3844
|
editorRef.current = editor;
|
|
3825
3845
|
setTimeout(function () { return setInitialized(true); }, 10);
|
|
3826
3846
|
}, onEditorChange: handleEditorChange, onKeyDown: handleKeyDown, onFocus: function () { return setFocused(initFocused || true); }, onBlur: function () { return setFocused(initFocused || false); } })) }));
|
|
3827
|
-
});
|
|
3847
|
+
});
|
|
3848
|
+
FormTextEditor.displayName = 'FormTextEditor';var FormAutocomplete = ToForwardRefExoticComponent(AutoTypeForwardRef(function (_a, ref) {
|
|
3828
3849
|
/********************************************************************************************************************
|
|
3829
3850
|
* type
|
|
3830
3851
|
* ******************************************************************************************************************/
|
|
@@ -4310,7 +4331,8 @@ styleInject(css_248z$c);var FormTextEditor = React.forwardRef(function (_a, ref)
|
|
|
4310
4331
|
}, renderInput: function (params) { return (React.createElement(FormTextField, __assign({}, params, { ref: textFieldRef, name: name, variant: variant, size: size, color: color, labelIcon: labelIcon, label: label, labelShrink: labelShrink, required: required, focused: focused, error: error, readOnly: readOnly, helperText: error ? errorHelperText : helperText, placeholder: placeholder, noFormValueItem: true, InputProps: __assign(__assign({}, params.InputProps), { endAdornment: (React.createElement(React.Fragment, null,
|
|
4311
4332
|
loading || isOnGetItemLoading ? React.createElement(material.CircularProgress, { color: 'inherit', size: 20 }) : null,
|
|
4312
4333
|
params.InputProps.endAdornment)) }), inputProps: readOnly || disabled ? __assign(__assign({}, params.inputProps), { tabIndex: -1 }) : params.inputProps }))); } }));
|
|
4313
|
-
}));
|
|
4334
|
+
}));
|
|
4335
|
+
FormAutocomplete.displayName = 'FormAutocomplete';var css_248z$b = ".PrivateYearSelect {\n position: absolute;\n left: 0;\n right: 0;\n top: 0;\n bottom: 0;\n background-color: white;\n}\n.PrivateYearSelect button {\n font-size: 14px;\n font-weight: 400;\n border-radius: 18px;\n}";
|
|
4314
4336
|
styleInject(css_248z$b);var PrivateToggleButton = React.forwardRef(function (_a, ref) {
|
|
4315
4337
|
var children = _a.children, initClassName = _a.className, selected = _a.selected, activated = _a.activated, outlined = _a.outlined, props = __rest(_a, ["children", "className", "selected", "activated", "outlined"]);
|
|
4316
4338
|
var theme = material.useTheme();
|
|
@@ -6593,16 +6615,10 @@ var PrivateYearPicker = function (_a) {
|
|
|
6593
6615
|
};var StyledContainer$2 = material.styled(material.Grid)(templateObject_1$5 || (templateObject_1$5 = __makeTemplateObject(["\n padding: 4px;\n position: relative;\n"], ["\n padding: 4px;\n position: relative;\n"])));
|
|
6594
6616
|
var StyledButton = material.styled(material.Button)(templateObject_2$2 || (templateObject_2$2 = __makeTemplateObject(["\n font-size: 12px;\n background-color: transparent;\n color: unset;\n outline: 0;\n font-weight: 400;\n line-height: 1.75;\n border-radius: 18px;\n cursor: pointer;\n width: 100%;\n border: 1px solid transparent;\n\n &:focus {\n background-color: rgba(0, 0, 0, 0.12);\n }\n\n &.default {\n background-color: #efefef;\n }\n &.selected,\n &.selected-temp {\n background-color: rgba(66, 165, 245, 0.6);\n }\n &.selected-start,\n &.selected-end {\n color: #fff;\n background-color: rgba(25, 118, 210, 1);\n\n &.range:not(.active) {\n background-color: rgba(25, 118, 210, 0.8);\n }\n }\n &.active {\n color: #fff;\n background-color: rgba(25, 118, 210, 1);\n box-shadow: inset 1px 1px 1px 1px #05569f;\n }\n &.disabled {\n opacity: 0.8;\n border: 1px solid transparent;\n }\n &:hover:not(.disabled):not(.selected-start):not(.selected-end) {\n color: inherit;\n background-color: rgba(66, 165, 245, 0.3);\n border: 1px solid transparent;\n }\n"], ["\n font-size: 12px;\n background-color: transparent;\n color: unset;\n outline: 0;\n font-weight: 400;\n line-height: 1.75;\n border-radius: 18px;\n cursor: pointer;\n width: 100%;\n border: 1px solid transparent;\n\n &:focus {\n background-color: rgba(0, 0, 0, 0.12);\n }\n\n &.default {\n background-color: #efefef;\n }\n &.selected,\n &.selected-temp {\n background-color: rgba(66, 165, 245, 0.6);\n }\n &.selected-start,\n &.selected-end {\n color: #fff;\n background-color: rgba(25, 118, 210, 1);\n\n &.range:not(.active) {\n background-color: rgba(25, 118, 210, 0.8);\n }\n }\n &.active {\n color: #fff;\n background-color: rgba(25, 118, 210, 1);\n box-shadow: inset 1px 1px 1px 1px #05569f;\n }\n &.disabled {\n opacity: 0.8;\n border: 1px solid transparent;\n }\n &:hover:not(.disabled):not(.selected-start):not(.selected-end) {\n color: inherit;\n background-color: rgba(66, 165, 245, 0.3);\n border: 1px solid transparent;\n }\n"])));
|
|
6595
6617
|
var templateObject_1$5, templateObject_2$2;var PrivateMonthPickerMonth = React.forwardRef(function (_a, ref) {
|
|
6596
|
-
/********************************************************************************************************************
|
|
6597
|
-
* Memo
|
|
6598
|
-
* ******************************************************************************************************************/
|
|
6599
|
-
var month = _a.month, range = _a.range, disabled = _a.disabled, isDefault = _a.isDefault, active = _a.active, selected = _a.selected, selectedStart = _a.selectedStart, selectedEnd = _a.selectedEnd, selectedTemp = _a.selectedTemp, onClick = _a.onClick, onMouseEnter = _a.onMouseEnter, onMouseLeave = _a.onMouseLeave;
|
|
6600
|
-
var className = React.useMemo(function () {
|
|
6601
|
-
return classNames(range && 'range', isDefault && 'default', active && 'active', selected && 'selected', selectedStart && 'selected-start', selectedEnd && 'selected-end', selectedTemp && 'selected-temp', disabled && 'disabled');
|
|
6602
|
-
}, [range, isDefault, active, selected, selectedStart, selectedEnd, selectedTemp, disabled]);
|
|
6603
6618
|
/********************************************************************************************************************
|
|
6604
6619
|
* Event Handler
|
|
6605
6620
|
* ******************************************************************************************************************/
|
|
6621
|
+
var month = _a.month, range = _a.range, disabled = _a.disabled, isDefault = _a.isDefault, active = _a.active, selected = _a.selected, selectedStart = _a.selectedStart, selectedEnd = _a.selectedEnd, selectedTemp = _a.selectedTemp, onClick = _a.onClick, onMouseEnter = _a.onMouseEnter, onMouseLeave = _a.onMouseLeave;
|
|
6606
6622
|
var handleClick = React.useCallback(function () {
|
|
6607
6623
|
onClick && onClick(month);
|
|
6608
6624
|
}, [month, onClick]);
|
|
@@ -6610,7 +6626,7 @@ var templateObject_1$5, templateObject_2$2;var PrivateMonthPickerMonth = React.f
|
|
|
6610
6626
|
* Render
|
|
6611
6627
|
* ******************************************************************************************************************/
|
|
6612
6628
|
return (React.createElement(StyledContainer$2, { className: 'PrivateMonthPickerMonth', ref: ref, item: true, xs: 4 },
|
|
6613
|
-
React.createElement(StyledButton, { className:
|
|
6629
|
+
React.createElement(StyledButton, { className: classNames(range && 'range', isDefault && 'default', active && 'active', selected && 'selected', selectedStart && 'selected-start', selectedEnd && 'selected-end', selectedTemp && 'selected-temp', disabled && 'disabled'), disabled: disabled, onClick: handleClick, onMouseEnter: onMouseEnter, onMouseLeave: onMouseLeave },
|
|
6614
6630
|
month,
|
|
6615
6631
|
"\uC6D4")));
|
|
6616
6632
|
});var StyledContainer$1 = material.styled(material.Grid)(templateObject_1$4 || (templateObject_1$4 = __makeTemplateObject(["\n width: 240px;\n padding: 4px;\n"], ["\n width: 240px;\n padding: 4px;\n"])));
|
|
@@ -6619,57 +6635,62 @@ var templateObject_1$4;var PrivateMonthPickerMonthList = function (_a) {
|
|
|
6619
6635
|
* Memo
|
|
6620
6636
|
* ******************************************************************************************************************/
|
|
6621
6637
|
var value = _a.value, initDefaultValue = _a.defaultValue, minAvailableValue = _a.minAvailableValue, maxAvailableValue = _a.maxAvailableValue, disablePast = _a.disablePast, disableFuture = _a.disableFuture, selectFromValue = _a.selectFromValue, selectToValue = _a.selectToValue, onChange = _a.onChange;
|
|
6622
|
-
var
|
|
6623
|
-
|
|
6624
|
-
|
|
6625
|
-
|
|
6626
|
-
|
|
6627
|
-
|
|
6628
|
-
|
|
6629
|
-
|
|
6630
|
-
|
|
6631
|
-
|
|
6632
|
-
|
|
6633
|
-
|
|
6634
|
-
|
|
6635
|
-
|
|
6636
|
-
|
|
6637
|
-
|
|
6638
|
-
|
|
6639
|
-
|
|
6640
|
-
|
|
6641
|
-
|
|
6642
|
-
var
|
|
6643
|
-
|
|
6638
|
+
var dateInfo = React.useMemo(function () {
|
|
6639
|
+
var nowDate = dayjs();
|
|
6640
|
+
var nowValue = dateToValue$2(nowDate);
|
|
6641
|
+
var nowYm = valueToYm$2(nowValue);
|
|
6642
|
+
var availableYm = {
|
|
6643
|
+
min: valueToYm$2(minAvailableValue),
|
|
6644
|
+
max: valueToYm$2(maxAvailableValue),
|
|
6645
|
+
};
|
|
6646
|
+
var defaultValue = initDefaultValue
|
|
6647
|
+
? initDefaultValue
|
|
6648
|
+
: nowYm < availableYm.min
|
|
6649
|
+
? minAvailableValue
|
|
6650
|
+
: nowYm > availableYm.max
|
|
6651
|
+
? maxAvailableValue
|
|
6652
|
+
: nowValue;
|
|
6653
|
+
return { nowDate: nowDate, nowValue: nowValue, nowYm: nowYm, availableYm: availableYm, defaultValue: defaultValue };
|
|
6654
|
+
}, [initDefaultValue, maxAvailableValue, minAvailableValue]);
|
|
6655
|
+
/********************************************************************************************************************
|
|
6656
|
+
* Variable
|
|
6657
|
+
* ******************************************************************************************************************/
|
|
6658
|
+
var currentYear = value ? value.year : dateInfo.defaultValue.year;
|
|
6659
|
+
/********************************************************************************************************************
|
|
6660
|
+
* Memo
|
|
6661
|
+
* ******************************************************************************************************************/
|
|
6644
6662
|
var months = React.useMemo(function () {
|
|
6645
6663
|
var newMonths = [];
|
|
6646
6664
|
var range = !!selectFromValue || !!selectToValue;
|
|
6647
|
-
var startYm = selectFromValue ? valueToYm$
|
|
6648
|
-
var endYm = selectToValue ? valueToYm$
|
|
6665
|
+
var startYm = selectFromValue ? valueToYm$2(selectFromValue) : value ? valueToYm$2(value) : 0;
|
|
6666
|
+
var endYm = selectToValue ? valueToYm$2(selectToValue) : value ? valueToYm$2(value) : 0;
|
|
6649
6667
|
for (var i = 1; i <= 12; i += 1) {
|
|
6650
6668
|
var ym = currentYear * 100 + i;
|
|
6651
6669
|
newMonths.push({
|
|
6652
6670
|
month: i,
|
|
6653
6671
|
range: range,
|
|
6654
|
-
isDefault: !value && i ===
|
|
6655
|
-
active: (!!selectFromValue || !!selectToValue) && !!value && ym === valueToYm$
|
|
6672
|
+
isDefault: !value && i === dateInfo.defaultValue.month,
|
|
6673
|
+
active: (!!selectFromValue || !!selectToValue) && !!value && ym === valueToYm$2(value),
|
|
6656
6674
|
selected: !!value && ym >= startYm && ym <= endYm,
|
|
6657
6675
|
selectedStart: !!value && ym === startYm,
|
|
6658
6676
|
selectedEnd: !!value && ym === endYm,
|
|
6659
|
-
disabled: ym <
|
|
6677
|
+
disabled: ym < dateInfo.availableYm.min ||
|
|
6678
|
+
ym > dateInfo.availableYm.max ||
|
|
6679
|
+
(disablePast && ym < dateInfo.nowYm) ||
|
|
6680
|
+
(disableFuture && ym > dateInfo.nowYm),
|
|
6660
6681
|
});
|
|
6661
6682
|
}
|
|
6662
6683
|
return newMonths;
|
|
6663
6684
|
}, [
|
|
6664
6685
|
selectFromValue,
|
|
6665
|
-
value,
|
|
6666
6686
|
selectToValue,
|
|
6687
|
+
value,
|
|
6667
6688
|
currentYear,
|
|
6668
|
-
|
|
6669
|
-
|
|
6670
|
-
|
|
6689
|
+
dateInfo.defaultValue.month,
|
|
6690
|
+
dateInfo.availableYm.min,
|
|
6691
|
+
dateInfo.availableYm.max,
|
|
6692
|
+
dateInfo.nowYm,
|
|
6671
6693
|
disablePast,
|
|
6672
|
-
nowYm,
|
|
6673
6694
|
disableFuture,
|
|
6674
6695
|
]);
|
|
6675
6696
|
/********************************************************************************************************************
|
|
@@ -6686,8 +6707,8 @@ var templateObject_1$4;var PrivateMonthPickerMonthList = function (_a) {
|
|
|
6686
6707
|
/********************************************************************************************************************
|
|
6687
6708
|
* Function
|
|
6688
6709
|
* ******************************************************************************************************************/
|
|
6689
|
-
var valueToYm$
|
|
6690
|
-
var dateToValue$
|
|
6710
|
+
var valueToYm$2 = function (v) { return v.year * 100 + v.month; };
|
|
6711
|
+
var dateToValue$2 = function (v) { return ({ year: v.year(), month: v.month() + 1 }); };var StyledContainer = material.styled('div')(templateObject_1$3 || (templateObject_1$3 = __makeTemplateObject(["\n .PrivateYearPickerYearList {\n max-height: 130px;\n }\n"], ["\n .PrivateYearPickerYearList {\n max-height: 130px;\n }\n"])));
|
|
6691
6712
|
var TitleContainer = material.styled('div')(templateObject_2$1 || (templateObject_2$1 = __makeTemplateObject(["\n display: flex;\n justify-content: center;\n align-items: center;\n border-bottom: 1px solid #efefef;\n padding: 10px;\n font-size: 14px;\n"], ["\n display: flex;\n justify-content: center;\n align-items: center;\n border-bottom: 1px solid #efefef;\n padding: 10px;\n font-size: 14px;\n"])));
|
|
6692
6713
|
var StyledIconButton = material.styled(material.IconButton)(templateObject_3$1 || (templateObject_3$1 = __makeTemplateObject(["\n margin-top: -8px;\n margin-bottom: -10px;\n"], ["\n margin-top: -8px;\n margin-bottom: -10px;\n"])));
|
|
6693
6714
|
var StyledYearMonth = material.styled('div')(templateObject_4 || (templateObject_4 = __makeTemplateObject(["\n flex: 1;\n display: flex;\n align-items: center;\n justify-content: center;\n"], ["\n flex: 1;\n display: flex;\n align-items: center;\n justify-content: center;\n"])));
|
|
@@ -6695,7 +6716,9 @@ var StyledYearMonthError = material.styled('div')(templateObject_5 || (templateO
|
|
|
6695
6716
|
var theme = _a.theme;
|
|
6696
6717
|
return theme.palette.error.main;
|
|
6697
6718
|
});
|
|
6698
|
-
var templateObject_1$3, templateObject_2$1, templateObject_3$1, templateObject_4, templateObject_5;var
|
|
6719
|
+
var templateObject_1$3, templateObject_2$1, templateObject_3$1, templateObject_4, templateObject_5;var valueToDate = function (v) { return dayjs("".concat(v.year, "-").concat(v.month, "-01")); };
|
|
6720
|
+
var valueToYm$1 = function (v) { return v.year * 100 + v.month; };
|
|
6721
|
+
var dateToValue$1 = function (v) { return ({ year: v.year(), month: v.month() + 1 }); };var DEFAULT_MIN_VALUE$3 = {
|
|
6699
6722
|
year: 2020,
|
|
6700
6723
|
month: 1,
|
|
6701
6724
|
};
|
|
@@ -6709,37 +6732,31 @@ var PrivateMonthPicker = function (_a) {
|
|
|
6709
6732
|
* ******************************************************************************************************************/
|
|
6710
6733
|
var _b = _a.value, initValue = _b === void 0 ? null : _b, _c = _a.minValue, minValue = _c === void 0 ? DEFAULT_MIN_VALUE$3 : _c, _d = _a.maxValue, maxValue = _d === void 0 ? DEFAULT_MAX_VALUE$3 : _d, disablePast = _a.disablePast, disableFuture = _a.disableFuture, selectFromValue = _a.selectFromValue, selectToValue = _a.selectToValue, onChange = _a.onChange;
|
|
6711
6734
|
var _e = reactHook.useAutoUpdateState(initValue), value = _e[0], setValue = _e[1];
|
|
6712
|
-
/********************************************************************************************************************
|
|
6713
|
-
* Function
|
|
6714
|
-
* ******************************************************************************************************************/
|
|
6715
|
-
var valueToDate = React.useCallback(function (v) { return dayjs("".concat(v.year, "-").concat(v.month, "-01")); }, []);
|
|
6716
|
-
var valueToYm = React.useCallback(function (v) { return v.year * 100 + v.month; }, []);
|
|
6717
|
-
var dateToValue = React.useCallback(function (v) { return ({ year: v.year(), month: v.month() + 1 }); }, []);
|
|
6718
6735
|
/********************************************************************************************************************
|
|
6719
6736
|
* Memo
|
|
6720
6737
|
* ******************************************************************************************************************/
|
|
6721
|
-
var nowValue = React.useMemo(function () { return dateToValue(dayjs()); }, [
|
|
6722
|
-
var nowYm = React.useMemo(function () { return valueToYm(nowValue); }, [nowValue
|
|
6738
|
+
var nowValue = React.useMemo(function () { return dateToValue$1(dayjs()); }, []);
|
|
6739
|
+
var nowYm = React.useMemo(function () { return valueToYm$1(nowValue); }, [nowValue]);
|
|
6723
6740
|
var minAvailableValue = React.useMemo(function () {
|
|
6724
6741
|
if (disablePast) {
|
|
6725
|
-
var minYm = valueToYm(minValue);
|
|
6742
|
+
var minYm = valueToYm$1(minValue);
|
|
6726
6743
|
return nowYm > minYm ? nowValue : minValue;
|
|
6727
6744
|
}
|
|
6728
6745
|
else {
|
|
6729
6746
|
return minValue;
|
|
6730
6747
|
}
|
|
6731
|
-
}, [disablePast,
|
|
6732
|
-
var minAvailableYm = React.useMemo(function () { return valueToYm(minAvailableValue); }, [minAvailableValue
|
|
6748
|
+
}, [disablePast, minValue, nowYm, nowValue]);
|
|
6749
|
+
var minAvailableYm = React.useMemo(function () { return valueToYm$1(minAvailableValue); }, [minAvailableValue]);
|
|
6733
6750
|
var maxAvailableValue = React.useMemo(function () {
|
|
6734
6751
|
if (disableFuture) {
|
|
6735
|
-
var maxYm = valueToYm(maxValue);
|
|
6752
|
+
var maxYm = valueToYm$1(maxValue);
|
|
6736
6753
|
return nowYm < maxYm ? nowValue : maxValue;
|
|
6737
6754
|
}
|
|
6738
6755
|
else {
|
|
6739
6756
|
return maxValue;
|
|
6740
6757
|
}
|
|
6741
|
-
}, [disableFuture,
|
|
6742
|
-
var maxAvailableYm = React.useMemo(function () { return valueToYm(maxAvailableValue); }, [maxAvailableValue
|
|
6758
|
+
}, [disableFuture, maxValue, nowYm, nowValue]);
|
|
6759
|
+
var maxAvailableYm = React.useMemo(function () { return valueToYm$1(maxAvailableValue); }, [maxAvailableValue]);
|
|
6743
6760
|
var displayValue = React.useMemo(function () {
|
|
6744
6761
|
if (value && !Number.isNaN(value.year) && !Number.isNaN(value.month)) {
|
|
6745
6762
|
return value;
|
|
@@ -6766,7 +6783,7 @@ var PrivateMonthPicker = function (_a) {
|
|
|
6766
6783
|
selectToValue,
|
|
6767
6784
|
value,
|
|
6768
6785
|
]);
|
|
6769
|
-
var displayValueDate = React.useMemo(function () { return valueToDate(displayValue); }, [displayValue
|
|
6786
|
+
var displayValueDate = React.useMemo(function () { return valueToDate(displayValue); }, [displayValue]);
|
|
6770
6787
|
var displayValueYm = React.useMemo(function () { return displayValue.year * 100 + displayValue.month; }, [displayValue]);
|
|
6771
6788
|
var displayValueError = React.useMemo(function () { return displayValueYm < minAvailableYm || displayValueYm > maxAvailableYm; }, [displayValueYm, maxAvailableYm, minAvailableYm]);
|
|
6772
6789
|
/********************************************************************************************************************
|
|
@@ -6774,7 +6791,7 @@ var PrivateMonthPicker = function (_a) {
|
|
|
6774
6791
|
* ******************************************************************************************************************/
|
|
6775
6792
|
var handleYearChange = React.useCallback(function (year) {
|
|
6776
6793
|
var newValue = __assign(__assign({}, displayValue), { year: year });
|
|
6777
|
-
var valueYm = valueToYm(newValue);
|
|
6794
|
+
var valueYm = valueToYm$1(newValue);
|
|
6778
6795
|
if (valueYm < minAvailableYm) {
|
|
6779
6796
|
setValue(minAvailableValue);
|
|
6780
6797
|
onChange(minAvailableValue, false);
|
|
@@ -6787,21 +6804,21 @@ var PrivateMonthPicker = function (_a) {
|
|
|
6787
6804
|
setValue(newValue);
|
|
6788
6805
|
onChange(newValue, false);
|
|
6789
6806
|
}
|
|
6790
|
-
}, [displayValue, maxAvailableValue, maxAvailableYm, minAvailableValue, minAvailableYm, onChange, setValue
|
|
6807
|
+
}, [displayValue, maxAvailableValue, maxAvailableYm, minAvailableValue, minAvailableYm, onChange, setValue]);
|
|
6791
6808
|
var handleMonthChange = React.useCallback(function (newValue) {
|
|
6792
6809
|
setValue(newValue);
|
|
6793
6810
|
onChange(newValue, true);
|
|
6794
6811
|
}, [onChange, setValue]);
|
|
6795
6812
|
var handlePrevClick = React.useCallback(function () {
|
|
6796
|
-
var newValue = dateToValue(displayValueDate.subtract(1, 'months'));
|
|
6813
|
+
var newValue = dateToValue$1(displayValueDate.subtract(1, 'months'));
|
|
6797
6814
|
setValue(newValue);
|
|
6798
6815
|
onChange(newValue, false);
|
|
6799
|
-
}, [
|
|
6816
|
+
}, [displayValueDate, onChange, setValue]);
|
|
6800
6817
|
var handleNextClick = React.useCallback(function () {
|
|
6801
|
-
var newValue = dateToValue(displayValueDate.add(1, 'months'));
|
|
6818
|
+
var newValue = dateToValue$1(displayValueDate.add(1, 'months'));
|
|
6802
6819
|
setValue(newValue);
|
|
6803
6820
|
onChange(newValue, false);
|
|
6804
|
-
}, [
|
|
6821
|
+
}, [displayValueDate, onChange, setValue]);
|
|
6805
6822
|
/********************************************************************************************************************
|
|
6806
6823
|
* Render
|
|
6807
6824
|
* ******************************************************************************************************************/
|
|
@@ -6977,7 +6994,8 @@ var dateToValue = function (v) { return ({ year: v.year(), month: v.month() + 1
|
|
|
6977
6994
|
* ******************************************************************************************************************/
|
|
6978
6995
|
return (React.createElement(FormContextProvider, { value: __assign({ onAddValueItem: handleAddValueItem }, otherFormState) },
|
|
6979
6996
|
React.createElement(PrivateDatePicker, __assign({ className: classNames(className, 'FormDatePicker') }, props, { ref: ref, type: 'date' }))));
|
|
6980
|
-
});
|
|
6997
|
+
});
|
|
6998
|
+
FormDatePicker.displayName = 'FormDatePicker';var FormDateTimePicker = React.forwardRef(function (_a, ref) {
|
|
6981
6999
|
/********************************************************************************************************************
|
|
6982
7000
|
* FormState
|
|
6983
7001
|
* ******************************************************************************************************************/
|
|
@@ -6995,7 +7013,8 @@ var dateToValue = function (v) { return ({ year: v.year(), month: v.month() + 1
|
|
|
6995
7013
|
* ******************************************************************************************************************/
|
|
6996
7014
|
return (React.createElement(FormContextProvider, { value: __assign({ onAddValueItem: handleAddValueItem }, otherFormState) },
|
|
6997
7015
|
React.createElement(PrivateDateTimePicker, __assign({ className: classNames(className, 'FormDateTimePicker') }, props, { ref: ref, type: 'date_time' }))));
|
|
6998
|
-
});
|
|
7016
|
+
});
|
|
7017
|
+
FormDateTimePicker.displayName = 'FormDateTimePicker';var FormTimePicker = React.forwardRef(function (_a, ref) {
|
|
6999
7018
|
/********************************************************************************************************************
|
|
7000
7019
|
* FormState
|
|
7001
7020
|
* ******************************************************************************************************************/
|
|
@@ -7013,7 +7032,8 @@ var dateToValue = function (v) { return ({ year: v.year(), month: v.month() + 1
|
|
|
7013
7032
|
* ******************************************************************************************************************/
|
|
7014
7033
|
return (React.createElement(FormContextProvider, { value: __assign({ onAddValueItem: handleAddValueItem }, otherFormState) },
|
|
7015
7034
|
React.createElement(PrivateDateTimePicker, __assign({ className: classNames(className, 'FormTimePicker') }, props, { ref: ref, type: 'time' }))));
|
|
7016
|
-
});
|
|
7035
|
+
});
|
|
7036
|
+
FormTimePicker.displayName = 'FormTimePicker';var css_248z$3 = ".FormDateRangePickerTooltipPicker .MuiPickersCalendarHeader-root {\n display: none;\n}\n.FormDateRangePickerTooltipPicker .MuiDayPicker-header > span {\n margin: 0;\n}\n.FormDateRangePickerTooltipPicker .MuiPickerStaticWrapper-content {\n min-width: 292px;\n}\n.FormDateRangePickerTooltipPicker .MuiPickerStaticWrapper-content .MuiCalendarOrClockPicker-root > div {\n width: 292px;\n}\n.FormDateRangePickerTooltipPicker .MuiPickerStaticWrapper-content .MuiCalendarOrClockPicker-root > div .MuiCalendarPicker-root {\n width: 292px;\n}\n.FormDateRangePickerTooltipPicker .selected-bg {\n display: none;\n position: absolute;\n}\n.FormDateRangePickerTooltipPicker .selected-bg.sel {\n display: block;\n position: absolute;\n top: 0;\n bottom: 0;\n left: 0;\n right: 0;\n background-color: rgba(66, 165, 245, 0.6);\n}\n.FormDateRangePickerTooltipPicker .selected-bg.sel.ui-start, .FormDateRangePickerTooltipPicker .selected-bg.sel.s-start {\n border-top-left-radius: 50%;\n border-bottom-left-radius: 50%;\n}\n.FormDateRangePickerTooltipPicker .selected-bg.sel.ui-end, .FormDateRangePickerTooltipPicker .selected-bg.sel.s-end {\n border-top-right-radius: 50%;\n border-bottom-right-radius: 50%;\n}\n.FormDateRangePickerTooltipPicker .selected-bg.sel ~ .MuiPickersDay-root {\n border: 0;\n}\n.FormDateRangePickerTooltipPicker .selected-bg.sel ~ .MuiPickersDay-root:not(:hover):not(:active):not(.Mui-selected) {\n background-color: transparent;\n}\n.FormDateRangePickerTooltipPicker .focused-bg {\n display: none;\n position: absolute;\n}\n.FormDateRangePickerTooltipPicker .focused-bg.focused {\n display: block;\n position: absolute;\n top: 0;\n bottom: 0;\n left: 0;\n right: 0;\n border: 2px solid #efefef;\n border-left: 0;\n border-right: 0;\n}\n.FormDateRangePickerTooltipPicker .focused-bg.focused.ui-start, .FormDateRangePickerTooltipPicker .focused-bg.focused.f-start {\n border-left: 2px solid #efefef;\n border-top-left-radius: 50%;\n border-bottom-left-radius: 50%;\n}\n.FormDateRangePickerTooltipPicker .focused-bg.focused.ui-end, .FormDateRangePickerTooltipPicker .focused-bg.focused.f-end {\n border-right: 2px solid #efefef;\n border-top-right-radius: 50%;\n border-bottom-right-radius: 50%;\n}\n.FormDateRangePickerTooltipPicker .focused-bg.focused ~ .MuiPickersDay-root:not(:hover):not(:active):not(.Mui-selected) {\n background-color: transparent;\n}";
|
|
7017
7037
|
styleInject(css_248z$3);var FormDateRangePickerTooltipPicker = React.forwardRef(function (_a, ref) {
|
|
7018
7038
|
/********************************************************************************************************************
|
|
7019
7039
|
* State
|
|
@@ -8040,7 +8060,8 @@ var FormDateRangePicker = React.forwardRef(function (_a, ref) {
|
|
|
8040
8060
|
(error && errorHelperText) ||
|
|
8041
8061
|
(fromError && fromErrorHelperText) ||
|
|
8042
8062
|
(toError && toErrorHelperText)) && (React.createElement(material.FormHelperText, { error: error || fromError || toError, style: { marginLeft: variant === 'standard' ? 0 : 14 } }, error ? errorHelperText : fromError ? fromErrorHelperText : toError ? toErrorHelperText : helperText))))));
|
|
8043
|
-
});
|
|
8063
|
+
});
|
|
8064
|
+
FormDateRangePicker.displayName = 'FormDateRangePicker';var LinkDialog = function (_a) {
|
|
8044
8065
|
/********************************************************************************************************************
|
|
8045
8066
|
* Ref
|
|
8046
8067
|
* ******************************************************************************************************************/
|
|
@@ -8402,7 +8423,8 @@ var FormFile = React.forwardRef(function (_a, ref) {
|
|
|
8402
8423
|
!hideRemove && util.notEmpty(value) && (React.createElement(StyledPdgButton, { variant: 'outlined', tabIndex: removeTabIndex, className: classNames('remove-btn form-file-btn', !!hideRemoveLabel && 'hidden-label'), color: error ? 'error' : color, startIcon: 'close', size: size, disabled: disabled, onClick: handleRemoveClick }, !hideRemoveLabel && (removeLabel || '삭제'))))),
|
|
8403
8424
|
React.createElement(PrivateAlertDialog, __assign({}, alertDialogProps, { onClose: function () { return setAlertDialogProps({ open: false }); } })),
|
|
8404
8425
|
React.createElement(LinkDialog, { open: isOpenLinkDialog, onConfirm: handleLinkDialogConfirm, onClose: function () { return setIsOpenLinkDialog(false); } })) }));
|
|
8405
|
-
});
|
|
8426
|
+
});
|
|
8427
|
+
FormFile.displayName = 'FormFile';var css_248z = ".FormImageFile .preview-img {\n max-width: 100%;\n}\n.FormImageFile:not(.hide-file-name):not(.variant-standard) .preview-img {\n padding-right: 14px;\n}";
|
|
8406
8428
|
styleInject(css_248z);var FormImageFile = React.forwardRef(function (_a, ref) {
|
|
8407
8429
|
var className = _a.className, imageSize = _a.imageSize, preview = _a.preview, previewMaxHeight = _a.previewMaxHeight, _b = _a.accept, accept = _b === void 0 ? '.jpg,.jpeg,.png' : _b, initValue = _a.value, onChange = _a.onChange, onFile = _a.onFile, onLink = _a.onLink, props = __rest(_a, ["className", "imageSize", "preview", "previewMaxHeight", "accept", "value", "onChange", "onFile", "onLink"]);
|
|
8408
8430
|
var _c = React.useState({
|
|
@@ -8550,7 +8572,8 @@ styleInject(css_248z);var FormImageFile = React.forwardRef(function (_a, ref) {
|
|
|
8550
8572
|
return (React.createElement(React.Fragment, null,
|
|
8551
8573
|
React.createElement(FormFile, __assign({ ref: ref, className: classNames(className, 'FormImageFile'), accept: accept, value: value, preview: previewNode, onChange: handleChange, onFile: handleFile, onLink: handleLink }, props)),
|
|
8552
8574
|
React.createElement(PrivateAlertDialog, __assign({}, alertDialogProps, { onClose: function () { return setAlertDialogProps({ open: false }); } }))));
|
|
8553
|
-
});
|
|
8575
|
+
});
|
|
8576
|
+
FormImageFile.displayName = 'FormImageFile';var DEFAULT_VALUE$3 = null;
|
|
8554
8577
|
var DEFAULT_FORMAT$2 = 'YYYY년 MM월';
|
|
8555
8578
|
var DEFAULT_MIN_VALUE$1 = {
|
|
8556
8579
|
year: 2020,
|
|
@@ -8900,7 +8923,8 @@ var FormMonthPicker = React.forwardRef(function (_a, ref) {
|
|
|
8900
8923
|
React.createElement("div", null,
|
|
8901
8924
|
React.createElement(PrivateInputDatePicker, __assign({}, inputDatePickerProps, { style: inputStyle, sx: sx, value: valueDate, label: label, labelIcon: labelIcon, error: error, focused: focused, required: required, readOnly: readOnly, readOnlyInput: readOnlyInput, icon: icon, startAdornment: startAdornment, endAdornment: endAdornment, inputRef: inputRef, onChange: function (v) { return setValue(v ? dateToValue(v) : v); }, onFocus: handleInputDatePickerFocus, onError: function (reason) { return (inputDatePickerErrorRef.current = reason); }, shouldDisableYear: handleInputDatePickerShouldDisableYear })))),
|
|
8902
8925
|
!formColWithHelperText && (!!helperText || (error && !!errorHelperText)) && (React.createElement(material.FormHelperText, { error: error, style: { marginLeft: variant === 'standard' ? 0 : 14 } }, error ? errorHelperText : helperText))))));
|
|
8903
|
-
});
|
|
8926
|
+
});
|
|
8927
|
+
FormMonthPicker.displayName = 'FormMonthPicker';var DEFAULT_VALUE$2 = [null, null];
|
|
8904
8928
|
var DEFAULT_FORMAT$1 = 'YYYY년 MM월';
|
|
8905
8929
|
var DEFAULT_MIN_VALUE = {
|
|
8906
8930
|
year: 2020,
|
|
@@ -9355,7 +9379,8 @@ var FormMonthRangePicker = React.forwardRef(function (_a, ref) {
|
|
|
9355
9379
|
(error && errorHelperText) ||
|
|
9356
9380
|
(fromError && fromErrorHelperText) ||
|
|
9357
9381
|
(toError && toErrorHelperText)) && (React.createElement(material.FormHelperText, { error: error || fromError || toError, style: { marginLeft: variant === 'standard' ? 0 : 14 } }, error ? errorHelperText : fromError ? fromErrorHelperText : toError ? toErrorHelperText : helperText))))));
|
|
9358
|
-
});
|
|
9382
|
+
});
|
|
9383
|
+
FormMonthRangePicker.displayName = 'FormMonthRangePicker';var DEFAULT_VALUE$1 = null;
|
|
9359
9384
|
var DEFAULT_FORMAT = 'YYYY년 MM월';
|
|
9360
9385
|
var FormYearPicker = React.forwardRef(function (_a, ref) {
|
|
9361
9386
|
/********************************************************************************************************************
|
|
@@ -9653,7 +9678,8 @@ var FormYearPicker = React.forwardRef(function (_a, ref) {
|
|
|
9653
9678
|
React.createElement("div", null,
|
|
9654
9679
|
React.createElement(PrivateInputDatePicker, __assign({}, inputDatePickerProps, { style: inputStyle, sx: sx, value: valueDate, label: label, labelIcon: labelIcon, error: error, focused: focused, required: required, readOnly: readOnly, readOnlyInput: readOnlyInput, icon: icon, startAdornment: startAdornment, endAdornment: endAdornment, inputRef: inputRef, onChange: handleInputDatePickerChange, onFocus: handleInputDatePickerFocus, onError: function (reason) { return (inputDatePickerErrorRef.current = reason); }, shouldDisableYear: handleInputDatePickerShouldDisableYear })))),
|
|
9655
9680
|
!formColWithHelperText && (!!helperText || (error && !!errorHelperText)) && (React.createElement(material.FormHelperText, { error: error, style: { marginLeft: variant === 'standard' ? 0 : 14 } }, error ? errorHelperText : helperText))))));
|
|
9656
|
-
});
|
|
9681
|
+
});
|
|
9682
|
+
FormYearPicker.displayName = 'FormYearPicker';var DEFAULT_VALUE = [null, null];
|
|
9657
9683
|
var FormYearRangePicker = React.forwardRef(function (_a, ref) {
|
|
9658
9684
|
/********************************************************************************************************************
|
|
9659
9685
|
* ID
|
|
@@ -10008,7 +10034,8 @@ var FormYearRangePicker = React.forwardRef(function (_a, ref) {
|
|
|
10008
10034
|
(error && errorHelperText) ||
|
|
10009
10035
|
(fromError && fromErrorHelperText) ||
|
|
10010
10036
|
(toError && toErrorHelperText)) && (React.createElement(material.FormHelperText, { error: error || fromError || toError, style: { marginLeft: variant === 'standard' ? 0 : 14 } }, error ? errorHelperText : fromError ? fromErrorHelperText : toError ? toErrorHelperText : helperText))))));
|
|
10011
|
-
});
|
|
10037
|
+
});
|
|
10038
|
+
FormYearRangePicker.displayName = 'FormYearRangePicker';var FormSwitch = React.forwardRef(function (_a, ref) {
|
|
10012
10039
|
/********************************************************************************************************************
|
|
10013
10040
|
* ID
|
|
10014
10041
|
* ******************************************************************************************************************/
|
|
@@ -10178,7 +10205,8 @@ var FormYearRangePicker = React.forwardRef(function (_a, ref) {
|
|
|
10178
10205
|
* ******************************************************************************************************************/
|
|
10179
10206
|
var switchControl = React.useMemo(function () { return (React.createElement(material.Switch, { size: size, name: name, checked: value, color: color, disabled: disabled, onChange: handleChange, onFocus: function () { return setFocused(initFocused || true); }, onBlur: function () { return setFocused(initFocused || false); } })); }, [color, disabled, handleChange, initFocused, name, setFocused, size, value]);
|
|
10180
10207
|
return (React.createElement(FormItemBase, { variant: variant, size: size, color: color, focused: focused, className: classNames(className, 'FormValueItem', 'FormSwitch'), labelIcon: labelIcon, label: label, error: error, fullWidth: false, helperText: error ? errorHelperText : helperText, helperTextProps: { style: { marginLeft: 5 } }, style: style, sx: sx, hidden: hidden, autoSize: true, controlHeight: size === 'small' ? 21 : 26, controlVerticalCenter: true, control: switchLabel ? (React.createElement(material.FormControlLabel, { control: switchControl, label: switchLabel, disabled: disabled })) : (switchControl) }));
|
|
10181
|
-
});
|
|
10208
|
+
});
|
|
10209
|
+
FormSwitch.displayName = 'FormSwitch';var SearchGroupRow = function (_a) {
|
|
10182
10210
|
var children = _a.children, props = __rest(_a, ["children"]);
|
|
10183
10211
|
return (React.createElement(FormRow, __assign({}, props),
|
|
10184
10212
|
React.createElement(FormCol, null,
|