pds-dev-kit-web-test 2.5.628 → 2.5.630
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/src/common/services/i18n/resources/en.json +14 -14
- package/dist/src/common/styles/scroll/scrollbarStyle.d.ts +2 -0
- package/dist/src/common/styles/scroll/scrollbarStyle.js +4 -3
- package/dist/src/core/pricing/translator.js +8 -7
- package/dist/src/core/pricing/types.js +1 -1
- package/dist/src/desktop/components/AdminList/AdminList.d.ts +10 -1
- package/dist/src/desktop/components/AdminList/AdminList.js +2 -2
- package/dist/src/desktop/components/AdminList/HeaderRow.d.ts +10 -1
- package/dist/src/desktop/components/AdminList/HeaderRow.js +2 -2
- package/dist/src/desktop/components/AdminListHeader/AdminListHeader.d.ts +2 -1
- package/dist/src/desktop/components/AdminListHeader/AdminListHeader.js +2 -2
- package/dist/src/desktop/components/AdminListHeader/HeaderBar.d.ts +2 -1
- package/dist/src/desktop/components/AdminListHeader/HeaderBar.js +2 -2
- package/dist/src/desktop/components/BoxItem/BoxItem.js +1 -1
- package/dist/src/desktop/components/Calendar/Calendar.js +51 -46
- package/dist/src/desktop/components/Calendar/CalendarContext.d.ts +1 -3
- package/dist/src/desktop/components/Calendar/CalendarContext.js +1 -2
- package/dist/src/desktop/components/Calendar/DailyView.d.ts +2 -8
- package/dist/src/desktop/components/Calendar/DailyView.js +7 -88
- package/dist/src/desktop/components/Calendar/MonthlyView.d.ts +1 -2
- package/dist/src/desktop/components/Calendar/MonthlyView.js +6 -81
- package/dist/src/desktop/components/Calendar/WeeklyView.d.ts +0 -3
- package/dist/src/desktop/components/Calendar/WeeklyView.js +7 -113
- package/dist/src/desktop/components/Calendar/calendarUtils.js +10 -20
- package/dist/src/desktop/components/Calendar/types.d.ts +4 -8
- package/dist/src/desktop/components/TextButton/TextButton.d.ts +5 -2
- package/dist/src/desktop/components/TextButton/TextButton.js +14 -4
- package/dist/src/desktop/layout/LayoutWF/Containers/ContentsContainer/variation/WFA.js +1 -1
- package/dist/src/desktop/layout/LayoutWF/Containers/ContentsContainer/variation/WFB.js +1 -1
- package/dist/src/desktop/layout/LayoutWF/Containers/ContentsContainer/variation/WFE.js +1 -1
- package/dist/src/desktop/layout/LayoutWF/Containers/ContentsContainer/variation/WFL.js +8 -5
- package/dist/src/desktop/panels/DesktopBasicModal/DesktopBasicModal.d.ts +2 -1
- package/dist/src/desktop/panels/DesktopBasicModal/DesktopBasicModal.js +13 -15
- package/dist/src/desktop/panels/DesktopBasicModalWithTab/DesktopBasicModalWithTab.d.ts +3 -1
- package/dist/src/desktop/panels/DesktopBasicModalWithTab/DesktopBasicModalWithTab.js +12 -6
- package/dist/src/desktop/panels/DesktopHeadlessModal/DesktopHeadlessModal.d.ts +2 -1
- package/dist/src/desktop/panels/DesktopHeadlessModal/DesktopHeadlessModal.js +7 -27
- package/dist/src/desktop/panels/DesktopTutorialModal/DesktopTutorialModal.d.ts +3 -1
- package/dist/src/desktop/panels/DesktopTutorialModal/DesktopTutorialModal.js +11 -5
- package/dist/src/desktop/panels/MultilingualModal/MultilingualModal.d.ts +3 -1
- package/dist/src/desktop/panels/MultilingualModal/MultilingualModal.js +11 -4
- package/dist/src/mobile/components/BoxItem/BoxItem.js +1 -1
- package/dist/src/mobile/components/TextButton/TextButton.d.ts +5 -2
- package/dist/src/mobile/components/TextButton/TextButton.js +14 -4
- package/dist/src/mobile/panels/MobileBasicModal/MobileBasicModal.d.ts +3 -1
- package/dist/src/mobile/panels/MobileBasicModal/MobileBasicModal.js +10 -3
- package/dist/src/sub/AdminList/AdminList/AdminList.d.ts +10 -1
- package/dist/src/sub/AdminList/AdminList/AdminList.js +2 -2
- package/dist/src/sub/AdminList/AdminList/HeaderRow.d.ts +10 -1
- package/dist/src/sub/AdminList/AdminList/HeaderRow.js +2 -2
- package/package.json +1 -1
- package/release-note.md +2 -2
@@ -51,6 +51,7 @@ var __rest = (this && this.__rest) || function (s, e) {
|
|
51
51
|
Object.defineProperty(exports, "__esModule", { value: true });
|
52
52
|
var jsx_runtime_1 = require("react/jsx-runtime");
|
53
53
|
var react_1 = require("react");
|
54
|
+
var components_1 = require("../../../hybrid/components");
|
54
55
|
var styled_components_1 = __importStar(require("styled-components"));
|
55
56
|
var transitionStyle_1 = require("../../../common/styles/movement/transitionStyle");
|
56
57
|
var TextLabel_1 = require("../TextLabel");
|
@@ -70,6 +71,15 @@ var textColor = {
|
|
70
71
|
white: 'sysTextWhite',
|
71
72
|
white2: 'sysTextWhite'
|
72
73
|
};
|
74
|
+
var iconColor = {
|
75
|
+
none: 'ui_cpnt_button_icon_primary',
|
76
|
+
red: 'ui_cpnt_button_icon_error',
|
77
|
+
grey_01: 'ui_cpnt_button_icon_enabled',
|
78
|
+
grey2: 'ui_cpnt_button_icon_default',
|
79
|
+
grey3: 'ui_141',
|
80
|
+
white: 'ui_cpnt_sidebar_icon_01',
|
81
|
+
white2: 'ui_cpnt_sidebar_icon_01'
|
82
|
+
};
|
73
83
|
var textDisabledColor = {
|
74
84
|
none: 'sysTextTertiary',
|
75
85
|
red: 'sysTextTertiary',
|
@@ -116,7 +126,7 @@ var backgroundPressedColor = {
|
|
116
126
|
white2: 'ui_cpnt_textbutton_white_variation_base_pressed'
|
117
127
|
};
|
118
128
|
function TextButton(_a) {
|
119
|
-
var text = _a.text, _b = _a.size, size = _b === void 0 ? 'large' : _b, _c = _a.responsiveMode, responsiveMode = _c === void 0 ? 'none' : _c, fontWeight = _a.fontWeight, _d = _a.type, type = _d === void 0 ? 'button' : _d, _e = _a.state, state = _e === void 0 ? 'normal' : _e, _f = _a.
|
129
|
+
var text = _a.text, _b = _a.size, size = _b === void 0 ? 'large' : _b, _c = _a.responsiveMode, responsiveMode = _c === void 0 ? 'none' : _c, fontWeight = _a.fontWeight, _d = _a.type, type = _d === void 0 ? 'button' : _d, _e = _a.state, state = _e === void 0 ? 'normal' : _e, _f = _a.iconMode, iconMode = _f === void 0 ? 'none' : _f, _g = _a.iconFillType, iconFillType = _g === void 0 ? 'line' : _g, iconName = _a.iconName, _h = _a.colorTheme, colorTheme = _h === void 0 ? 'none' : _h, onClick = _a.onClick, onKeyDown = _a.onKeyDown, rest = __rest(_a, ["text", "size", "responsiveMode", "fontWeight", "type", "state", "iconMode", "iconFillType", "iconName", "colorTheme", "onClick", "onKeyDown"]);
|
120
130
|
var buttonRef = (0, react_1.useRef)(null);
|
121
131
|
/**
|
122
132
|
* @when keydown 이벤트가 있을 때만
|
@@ -134,9 +144,9 @@ function TextButton(_a) {
|
|
134
144
|
onClick(e);
|
135
145
|
}
|
136
146
|
};
|
137
|
-
return ((0, jsx_runtime_1.
|
138
|
-
|
139
|
-
|
147
|
+
return ((0, jsx_runtime_1.jsxs)(S_Button, __assign({ ref: buttonRef, "x-pds-name": "TextButton", "x-pds-element-type": "component", "x-pds-device-type": "desktop" }, rest, { size: size, responsiveMode: responsiveMode, onClick: handleClick, onKeyDown: onKeyDown, type: type, fontWeight: fontWeight, disabled: state === 'disabled', state: state, hoverColor: backgroundHoverColor[colorTheme], pressedColor: backgroundPressedColor[colorTheme] }, { children: [size !== 'xsmall' && iconMode === 'left' && ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(components_1.Icon, { iconName: iconName, size: size === 'large' || size === 'rlarge' ? 20 : 16, colorKey: state === 'disabled' ? 'ui_cpnt_button_text_disabled' : iconColor[colorTheme], fillType: iconFillType }), (0, jsx_runtime_1.jsx)(components_1.Spacing, { size: size === 'large' || size === 'rlarge' ? 'spacing_b' : 'spacing_a', spacingType: "width" })] })), (0, jsx_runtime_1.jsx)(TextLabel_1.TextLabel, { text: text, styleTheme: textStyle[size], colorTheme: state === 'disabled' ? textDisabledColor[colorTheme] : textColor[colorTheme], colorOverride: state === 'disabled'
|
148
|
+
? overrideTextDisabledColor[colorTheme]
|
149
|
+
: overrideTextColor[colorTheme], singleLineMode: "use", ellipsisMode: "use", lineLimit: 1, wordBreak: "break_all" }), size !== 'xsmall' && iconMode === 'right' && ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(components_1.Spacing, { size: size === 'large' || size === 'rlarge' ? 'spacing_b' : 'spacing_a', spacingType: "width" }), (0, jsx_runtime_1.jsx)(components_1.Icon, { iconName: iconName, size: size === 'large' || size === 'rlarge' ? 20 : 16, colorKey: state === 'disabled' ? 'ui_cpnt_button_text_disabled' : iconColor[colorTheme], fillType: iconFillType })] }))] })));
|
140
150
|
}
|
141
151
|
var large = (0, styled_components_1.css)(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n border-radius: 14px;\n height: 48px;\n\n ", ";\n\n & > div {\n height: 48px;\n line-height: 48px;\n }\n"], ["\n border-radius: 14px;\n height: 48px;\n\n ", ";\n\n & > div {\n height: 48px;\n line-height: 48px;\n }\n"])), function (_a) {
|
142
152
|
var size = _a.size;
|
@@ -93,7 +93,7 @@ var overrideStyleContainer1 = (0, styled_components_1.css)(templateObject_11 ||
|
|
93
93
|
var theme = _a.theme, overrideContainer1ColorKey = _a.overrideContainer1ColorKey;
|
94
94
|
return overrideContainer1ColorKey && theme[overrideContainer1ColorKey];
|
95
95
|
});
|
96
|
-
var S_ContentsContainer = styled_components_1.default.div(templateObject_12 || (templateObject_12 = __makeTemplateObject(["\n background-color: ", ";\n border-radius: 24px;\n display: flex;\n height: 60vh;\n justify-content: center;\n max-height: 640px;\n overflow-x: hidden;\n overflow-y: overlay;\n width:
|
96
|
+
var S_ContentsContainer = styled_components_1.default.div(templateObject_12 || (templateObject_12 = __makeTemplateObject(["\n background-color: ", ";\n border-radius: 24px;\n display: flex;\n height: 60vh;\n justify-content: center;\n max-height: 640px;\n overflow-x: hidden;\n overflow-y: overlay;\n scrollbar-width: auto !important;\n ", ";\n ", ";\n width: 864px;\n\n ", "\n ", "\n"], ["\n background-color: ", ";\n border-radius: 24px;\n display: flex;\n height: 60vh;\n justify-content: center;\n max-height: 640px;\n overflow-x: hidden;\n overflow-y: overlay;\n scrollbar-width: auto !important;\n ", ";\n ", ";\n width: 864px;\n\n ", "\n ", "\n"])), function (_a) {
|
97
97
|
var theme = _a.theme;
|
98
98
|
return theme.ui_wizard_contentscontainer01_background;
|
99
99
|
}, function (_a) {
|
@@ -50,7 +50,7 @@ var overrideStyleContainer1 = (0, styled_components_1.css)(templateObject_1 || (
|
|
50
50
|
var theme = _a.theme, overrideContainer1ColorKey = _a.overrideContainer1ColorKey;
|
51
51
|
return overrideContainer1ColorKey && theme[overrideContainer1ColorKey];
|
52
52
|
});
|
53
|
-
var S_ContentsContainer = styled_components_1.default.div(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n align-items: flex-start;\n background-color: ", ";\n border-radius: 24px;\n display: flex;\n height: 60vh;\n justify-content: center;\n max-height: 640px;\n overflow-x: hidden;\n overflow-y: overlay;\n width: 864px;\n ", ";\n\n ", "\n ", "\n"], ["\n align-items: flex-start;\n background-color: ", ";\n border-radius: 24px;\n display: flex;\n height: 60vh;\n justify-content: center;\n max-height: 640px;\n overflow-x: hidden;\n overflow-y: overlay;\n width: 864px;\n ", ";\n\n ", "\n ", "\n"])), function (_a) {
|
53
|
+
var S_ContentsContainer = styled_components_1.default.div(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n align-items: flex-start;\n background-color: ", ";\n border-radius: 24px;\n display: flex;\n height: 60vh;\n justify-content: center;\n max-height: 640px;\n overflow-x: hidden;\n overflow-y: overlay;\n scrollbar-width: auto !important;\n width: 864px;\n ", ";\n\n ", "\n ", "\n"], ["\n align-items: flex-start;\n background-color: ", ";\n border-radius: 24px;\n display: flex;\n height: 60vh;\n justify-content: center;\n max-height: 640px;\n overflow-x: hidden;\n overflow-y: overlay;\n scrollbar-width: auto !important;\n width: 864px;\n ", ";\n\n ", "\n ", "\n"])), function (_a) {
|
54
54
|
var theme = _a.theme;
|
55
55
|
return theme.ui_wizard_contentscontainer01_background;
|
56
56
|
}, function (_a) {
|
@@ -60,7 +60,7 @@ var overrideStyleContainer1 = (0, styled_components_1.css)(templateObject_11 ||
|
|
60
60
|
var theme = _a.theme, overrideContainer1ColorKey = _a.overrideContainer1ColorKey;
|
61
61
|
return overrideContainer1ColorKey && theme[overrideContainer1ColorKey];
|
62
62
|
});
|
63
|
-
var S_ContentsContainer = styled_components_1.default.div(templateObject_12 || (templateObject_12 = __makeTemplateObject(["\n align-items: flex-start;\n background-color: ", ";\n display: flex;\n height: 60vh;\n justify-content: center;\n max-height: 640px;\n
|
63
|
+
var S_ContentsContainer = styled_components_1.default.div(templateObject_12 || (templateObject_12 = __makeTemplateObject(["\n align-items: flex-start;\n background-color: ", ";\n display: flex;\n height: 60vh;\n justify-content: center;\n max-height: 640px;\n scrollbar-width: auto !important;\n ", ";\n ", ";\n\n ", "\n ", "\n"], ["\n align-items: flex-start;\n background-color: ", ";\n display: flex;\n height: 60vh;\n justify-content: center;\n max-height: 640px;\n scrollbar-width: auto !important;\n ", ";\n ", ";\n\n ", "\n ", "\n"])), function (_a) {
|
64
64
|
var theme = _a.theme;
|
65
65
|
return theme.ui_wizard_contentscontainer01_background;
|
66
66
|
}, function (_a) {
|
@@ -61,7 +61,7 @@ var WFL_4Area2Style = (0, styled_components_1.css)(templateObject_12 || (templat
|
|
61
61
|
var WFL_1Content2Style = (0, styled_components_1.css)(templateObject_13 || (templateObject_13 = __makeTemplateObject(["\n height: 100%;\n overflow: hidden;\n"], ["\n height: 100%;\n overflow: hidden;\n"])));
|
62
62
|
var WFL_2Content2Style = (0, styled_components_1.css)(templateObject_14 || (templateObject_14 = __makeTemplateObject(["\n height: 100%;\n overflow: hidden;\n"], ["\n height: 100%;\n overflow: hidden;\n"])));
|
63
63
|
var S_Box = styled_components_1.default.div(templateObject_15 || (templateObject_15 = __makeTemplateObject(["\n display: flex;\n height: 60vh;\n max-height: 640px;\n"], ["\n display: flex;\n height: 60vh;\n max-height: 640px;\n"])));
|
64
|
-
var S_ContentsContainer1 = styled_components_1.default.div(templateObject_16 || (templateObject_16 = __makeTemplateObject(["\n background-color: ", ";\n border-radius: 24px 0 0 24px;\n box-sizing: border-box;\n overflow-x: hidden;\n overflow-y: auto;\n width:
|
64
|
+
var S_ContentsContainer1 = styled_components_1.default.div(templateObject_16 || (templateObject_16 = __makeTemplateObject(["\n background-color: ", ";\n border-radius: 24px 0 0 24px;\n box-sizing: border-box;\n overflow-x: hidden;\n overflow-y: auto;\n scrollbar-width: auto !important;\n\n ", ";\n ", ";\n\n width: 480px;\n\n ", "\n"], ["\n background-color: ", ";\n border-radius: 24px 0 0 24px;\n box-sizing: border-box;\n overflow-x: hidden;\n overflow-y: auto;\n scrollbar-width: auto !important;\n\n ", ";\n ", ";\n\n width: 480px;\n\n ", "\n"])), function (_a) {
|
65
65
|
var theme = _a.theme;
|
66
66
|
return theme.ui_wizard_contentscontainer01_background;
|
67
67
|
}, function (_a) {
|
@@ -75,8 +75,8 @@ var S_ContentsContainer1 = styled_components_1.default.div(templateObject_16 ||
|
|
75
75
|
}, function (_a) {
|
76
76
|
var containerColor = _a.containerColor;
|
77
77
|
return "background-color: ".concat(containerColor);
|
78
|
-
}, scrollbarStyle_1.
|
79
|
-
var S_ContentsContainer2 = styled_components_1.default.div(templateObject_17 || (templateObject_17 = __makeTemplateObject(["\n background-color: ", ";\n border-radius: 0 24px 24px 0;\n width:
|
78
|
+
}, scrollbarStyle_1.scrollbarWithPaddingStyle);
|
79
|
+
var S_ContentsContainer2 = styled_components_1.default.div(templateObject_17 || (templateObject_17 = __makeTemplateObject(["\n background-color: ", ";\n border-radius: 0 24px 24px 0;\n\n scrollbar-width: auto !important;\n\n ", ";\n ", ";\n\n width: 672px;\n\n ", "\n"], ["\n background-color: ", ";\n border-radius: 0 24px 24px 0;\n\n scrollbar-width: auto !important;\n\n ", ";\n ", ";\n\n width: 672px;\n\n ", "\n"])), function (_a) {
|
80
80
|
var theme = _a.theme;
|
81
81
|
return theme.ui_wizard_contentscontainer02_background;
|
82
82
|
}, function (_a) {
|
@@ -90,12 +90,15 @@ var S_ContentsContainer2 = styled_components_1.default.div(templateObject_17 ||
|
|
90
90
|
}, function (_a) {
|
91
91
|
var containerColor = _a.containerColor;
|
92
92
|
return "background-color: ".concat(containerColor);
|
93
|
-
});
|
93
|
+
}, scrollbarStyle_1.scrollbarWithPaddingStyle);
|
94
94
|
var S_ContentsArea1 = styled_components_1.default.div(templateObject_18 || (templateObject_18 = __makeTemplateObject(["\n box-sizing: border-box;\n padding-bottom: 64px;\n\n ", ";\n"], ["\n box-sizing: border-box;\n padding-bottom: 64px;\n\n ", ";\n"])), function (_a) {
|
95
95
|
var areaColor = _a.areaColor;
|
96
96
|
return "background-color: ".concat(areaColor);
|
97
97
|
});
|
98
|
-
var S_ContentsArea2 = styled_components_1.default.div(templateObject_19 || (templateObject_19 = __makeTemplateObject(["\n box-sizing: border-box;\n
|
98
|
+
var S_ContentsArea2 = styled_components_1.default.div(templateObject_19 || (templateObject_19 = __makeTemplateObject(["\n box-sizing: border-box;\n padding-left: ", ";\n ", ";\n ", ";\n"], ["\n box-sizing: border-box;\n padding-left: ", ";\n ", ";\n ", ";\n"])), function (_a) {
|
99
|
+
var theme = _a.theme;
|
100
|
+
return theme.spacing.spacingF;
|
101
|
+
}, function (_a) {
|
99
102
|
var layoutType = _a.layoutType;
|
100
103
|
return ({
|
101
104
|
WFL_1: WFL_1Area2Style,
|
@@ -1,4 +1,5 @@
|
|
1
1
|
/// <reference types="react" />
|
2
|
+
import { ScrollVisibleType } from '../../../common/styles/scroll/scrollbarStyle';
|
2
3
|
import type { PDSTextType } from '../../../common';
|
3
4
|
type DesktopBasicModalProps = {
|
4
5
|
titleText: PDSTextType;
|
@@ -16,7 +17,7 @@ type DesktopBasicModalProps = {
|
|
16
17
|
mBtn2Type?: 'button' | 'submit';
|
17
18
|
mBtn3Type?: 'button' | 'submit';
|
18
19
|
size?: 'large' | 'medium' | 'small' | 'rlarge';
|
19
|
-
scrollVisibleType?:
|
20
|
+
scrollVisibleType?: ScrollVisibleType;
|
20
21
|
onClickMBtn1?: () => void;
|
21
22
|
onClickMBtn2?: () => void;
|
22
23
|
onClickMBtn3?: () => void;
|
@@ -44,9 +44,9 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
44
44
|
var jsx_runtime_1 = require("react/jsx-runtime");
|
45
45
|
var react_1 = require("react");
|
46
46
|
var react_dom_1 = __importDefault(require("react-dom"));
|
47
|
+
var scrollbarStyle_1 = require("../../../common/styles/scroll/scrollbarStyle");
|
47
48
|
var styled_components_1 = __importStar(require("styled-components"));
|
48
49
|
var animationStyle_1 = require("../../../common/styles/movement/animationStyle");
|
49
|
-
var scrollbarStyle_1 = require("../../../common/styles/scroll/scrollbarStyle");
|
50
50
|
var components_1 = require("../../components");
|
51
51
|
function DesktopBasicModal(_a) {
|
52
52
|
var titleText = _a.titleText, contentText = _a.contentText, _b = _a.bodySpacingMode, bodySpacingMode = _b === void 0 ? 'use' : _b, _c = _a.bodyOverflowType, bodyOverflowType = _c === void 0 ? 'overlay' : _c, _d = _a.btnMode, btnMode = _d === void 0 ? 'mbtn_amount2' : _d, mBtn1Text = _a.mBtn1Text, mBtn2Text = _a.mBtn2Text, mBtn3Text = _a.mBtn3Text, _e = _a.mBtn1State, mBtn1State = _e === void 0 ? 'normal' : _e, _f = _a.mBtn2State, mBtn2State = _f === void 0 ? 'normal' : _f, _g = _a.mBtn3State, mBtn3State = _g === void 0 ? 'normal' : _g, _h = _a.mBtn1Type, mBtn1Type = _h === void 0 ? 'button' : _h, _j = _a.mBtn2Type, mBtn2Type = _j === void 0 ? 'button' : _j, _k = _a.mBtn3Type, mBtn3Type = _k === void 0 ? 'button' : _k, onClickMBtn1 = _a.onClickMBtn1, onClickMBtn2 = _a.onClickMBtn2, onClickMBtn3 = _a.onClickMBtn3, _l = _a.size, size = _l === void 0 ? 'large' : _l, _m = _a.scrollVisibleType, scrollVisibleType = _m === void 0 ? 'visible' : _m, children = _a.children;
|
@@ -70,13 +70,12 @@ function DesktopBasicModal(_a) {
|
|
70
70
|
var btn3Mode = ['mbtn_amount3'];
|
71
71
|
return react_dom_1.default.createPortal((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(S_ModalOverlay, {}), (0, jsx_runtime_1.jsxs)(S_ModalWrapper, __assign({ "x-pds-name": "DesktopBasicModal", "x-pds-element-type": "panel", "x-pds-device-type": "desktop", size: size }, { children: [(0, jsx_runtime_1.jsx)(S_Header, { children: (0, jsx_runtime_1.jsx)(components_1.TextLabel, { text: titleText, colorTheme: "sysTextPrimary", styleTheme: "headingBold" }) }), (0, jsx_runtime_1.jsxs)(S_Body, __assign({ bodySpacingMode: bodySpacingMode, bodyOverflowType: bodyOverflowType, scrollVisibleType: scrollVisibleType }, { children: [contentText && ((0, jsx_runtime_1.jsx)(components_1.TextLabel, { text: contentText, colorTheme: "sysTextSecondary", styleTheme: "subTitleRegular" })), children && children] })), (0, jsx_runtime_1.jsxs)(S_Footer, { children: [(0, jsx_runtime_1.jsx)(S_Left, { children: btn3Mode.includes(btnMode) && mBtn3Text && ((0, jsx_runtime_1.jsx)(components_1.MainButton, { styleTheme: "secondary", text: mBtn3Text, state: mBtn3State, type: mBtn3Type, size: "medium", onClick: onClickMBtn3 })) }), (0, jsx_runtime_1.jsxs)(S_Right, { children: [(0, jsx_runtime_1.jsx)(S_Btn2Wrapper, { children: btn2Mode.includes(btnMode) && mBtn2Text && ((0, jsx_runtime_1.jsx)(components_1.MainButton, { styleTheme: "secondary", text: mBtn2Text, state: mBtn2State, type: mBtn2Type, size: "medium", onClick: onClickMBtn2 })) }), btn1Mode.includes(btnMode) && mBtn1Text && ((0, jsx_runtime_1.jsx)(components_1.MainButton, { text: mBtn1Text, state: mBtn1State, type: mBtn1Type, size: "medium", onClick: onClickMBtn1 }))] })] })] }))] }), container);
|
72
72
|
}
|
73
|
-
var
|
74
|
-
var S_ModalOverlay = styled_components_1.default.div(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n background-color: ", ";\n height: 100vh;\n left: 0;\n position: fixed;\n top: 0;\n width: 100vw;\n\n ", "\n"], ["\n background-color: ", ";\n height: 100vh;\n left: 0;\n position: fixed;\n top: 0;\n width: 100vw;\n\n ", "\n"])), function (_a) {
|
73
|
+
var S_ModalOverlay = styled_components_1.default.div(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n background-color: ", ";\n height: 100vh;\n left: 0;\n position: fixed;\n top: 0;\n width: 100vw;\n\n ", "\n"], ["\n background-color: ", ";\n height: 100vh;\n left: 0;\n position: fixed;\n top: 0;\n width: 100vw;\n\n ", "\n"])), function (_a) {
|
75
74
|
var theme = _a.theme;
|
76
75
|
return theme.ui_cpnt_modal_dimmed;
|
77
76
|
}, animationStyle_1.modalOverlayOnAni);
|
78
|
-
var rlarge = (0, styled_components_1.css)(
|
79
|
-
var S_ModalWrapper = styled_components_1.default.div(
|
77
|
+
var rlarge = (0, styled_components_1.css)(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n max-width: 1400px;\n min-width: 960px;\n"], ["\n max-width: 1400px;\n min-width: 960px;\n"])));
|
78
|
+
var S_ModalWrapper = styled_components_1.default.div(templateObject_3 || (templateObject_3 = __makeTemplateObject(["\n background-color: ", ";\n border: 1px solid ", ";\n border-radius: 24px;\n box-shadow: ", ";\n box-sizing: border-box;\n display: flex;\n flex-direction: column;\n left: 50%;\n position: fixed;\n top: 50%;\n transform: translate(-50%, -50%);\n width: ", ";\n ", ";\n\n ", "\n"], ["\n background-color: ", ";\n border: 1px solid ", ";\n border-radius: 24px;\n box-shadow: ", ";\n box-sizing: border-box;\n display: flex;\n flex-direction: column;\n left: 50%;\n position: fixed;\n top: 50%;\n transform: translate(-50%, -50%);\n width: ", ";\n ", ";\n\n ", "\n"])), function (_a) {
|
80
79
|
var theme = _a.theme;
|
81
80
|
return theme.ui_cpnt_modal_base;
|
82
81
|
}, function (_a) {
|
@@ -98,16 +97,16 @@ var S_ModalWrapper = styled_components_1.default.div(templateObject_4 || (templa
|
|
98
97
|
var size = _a.size;
|
99
98
|
return size === 'rlarge' && rlarge;
|
100
99
|
}, animationStyle_1.modalOnAni);
|
101
|
-
var S_Left = styled_components_1.default.div(
|
100
|
+
var S_Left = styled_components_1.default.div(templateObject_4 || (templateObject_4 = __makeTemplateObject(["\n margin-right: ", ";\n"], ["\n margin-right: ", ";\n"])), function (_a) {
|
102
101
|
var theme = _a.theme;
|
103
102
|
return theme.spacing.spacingB;
|
104
103
|
});
|
105
|
-
var S_Btn2Wrapper = styled_components_1.default.div(
|
104
|
+
var S_Btn2Wrapper = styled_components_1.default.div(templateObject_5 || (templateObject_5 = __makeTemplateObject(["\n margin-right: ", ";\n"], ["\n margin-right: ", ";\n"])), function (_a) {
|
106
105
|
var theme = _a.theme;
|
107
106
|
return theme.spacing.spacingB;
|
108
107
|
});
|
109
|
-
var S_Right = styled_components_1.default.div(
|
110
|
-
var S_Header = styled_components_1.default.div(
|
108
|
+
var S_Right = styled_components_1.default.div(templateObject_6 || (templateObject_6 = __makeTemplateObject(["\n display: flex;\n"], ["\n display: flex;\n"])));
|
109
|
+
var S_Header = styled_components_1.default.div(templateObject_7 || (templateObject_7 = __makeTemplateObject(["\n padding-bottom: ", ";\n padding-left: ", ";\n padding-right: ", ";\n padding-top: ", ";\n"], ["\n padding-bottom: ", ";\n padding-left: ", ";\n padding-right: ", ";\n padding-top: ", ";\n"])), function (_a) {
|
111
110
|
var theme = _a.theme;
|
112
111
|
return theme.spacing.spacingC;
|
113
112
|
}, function (_a) {
|
@@ -120,7 +119,7 @@ var S_Header = styled_components_1.default.div(templateObject_8 || (templateObje
|
|
120
119
|
var theme = _a.theme;
|
121
120
|
return theme.spacing.spacingE;
|
122
121
|
});
|
123
|
-
var S_Body = styled_components_1.default.div(
|
122
|
+
var S_Body = styled_components_1.default.div(templateObject_9 || (templateObject_9 = __makeTemplateObject(["\n flex: 1;\n max-height: 60vh;\n overflow: ", ";\n padding-bottom: ", ";\n padding-left: ", ";\n padding-right: ", ";\n padding-top: ", ";\n\n ", "\n ", ";\n"], ["\n flex: 1;\n max-height: 60vh;\n overflow: ", ";\n padding-bottom: ", ";\n padding-left: ", ";\n padding-right: ", ";\n padding-top: ", ";\n\n ", "\n ", ";\n"])), function (_a) {
|
124
123
|
var bodyOverflowType = _a.bodyOverflowType;
|
125
124
|
return bodyOverflowType;
|
126
125
|
}, function (_a) {
|
@@ -140,15 +139,14 @@ var S_Body = styled_components_1.default.div(templateObject_10 || (templateObjec
|
|
140
139
|
return bodyOverflowType !== 'visible' &&
|
141
140
|
scrollVisibleType &&
|
142
141
|
{
|
143
|
-
moving: scrollInvisible,
|
144
142
|
visible: scrollbarStyle_1.scrollbarStyle,
|
145
|
-
hidden: scrollInvisible
|
143
|
+
hidden: scrollbarStyle_1.scrollInvisible
|
146
144
|
}[scrollVisibleType];
|
147
145
|
}, function (_a) {
|
148
146
|
var bodySpacingMode = _a.bodySpacingMode;
|
149
|
-
return bodySpacingMode === 'none' && (0, styled_components_1.css)(
|
147
|
+
return bodySpacingMode === 'none' && (0, styled_components_1.css)(templateObject_8 || (templateObject_8 = __makeTemplateObject(["\n padding-bottom: 0;\n padding-left: 0;\n padding-right: 0;\n "], ["\n padding-bottom: 0;\n padding-left: 0;\n padding-right: 0;\n "])));
|
150
148
|
});
|
151
|
-
var S_Footer = styled_components_1.default.div(
|
149
|
+
var S_Footer = styled_components_1.default.div(templateObject_10 || (templateObject_10 = __makeTemplateObject(["\n border-top: 1px solid ", ";\n box-sizing: border-box;\n display: flex;\n justify-content: space-between;\n padding-bottom: ", ";\n padding-left: ", ";\n padding-right: ", ";\n padding-top: ", ";\n"], ["\n border-top: 1px solid ", ";\n box-sizing: border-box;\n display: flex;\n justify-content: space-between;\n padding-bottom: ", ";\n padding-left: ", ";\n padding-right: ", ";\n padding-top: ", ";\n"])), function (_a) {
|
152
150
|
var theme = _a.theme;
|
153
151
|
return theme.ui_cpnt_modal_border;
|
154
152
|
}, function (_a) {
|
@@ -165,4 +163,4 @@ var S_Footer = styled_components_1.default.div(templateObject_11 || (templateObj
|
|
165
163
|
return theme.spacing.spacingD;
|
166
164
|
});
|
167
165
|
exports.default = DesktopBasicModal;
|
168
|
-
var templateObject_1, templateObject_2, templateObject_3, templateObject_4, templateObject_5, templateObject_6, templateObject_7, templateObject_8, templateObject_9, templateObject_10
|
166
|
+
var templateObject_1, templateObject_2, templateObject_3, templateObject_4, templateObject_5, templateObject_6, templateObject_7, templateObject_8, templateObject_9, templateObject_10;
|
@@ -1,4 +1,5 @@
|
|
1
1
|
/// <reference types="react" />
|
2
|
+
import { ScrollVisibleType } from '../../../common/styles/scroll/scrollbarStyle';
|
2
3
|
import type { PDSTextType } from '../../../common';
|
3
4
|
export type DesktopBasicModalWithTabInfoType = {
|
4
5
|
sideTabTitleText: PDSTextType;
|
@@ -9,6 +10,7 @@ type DesktopBasicModalWithTabProps = {
|
|
9
10
|
size?: 'large' | 'medium';
|
10
11
|
modalTitleText: PDSTextType;
|
11
12
|
infoArray: DesktopBasicModalWithTabInfoType[];
|
13
|
+
scrollVisibleType?: ScrollVisibleType;
|
12
14
|
btnMode?: 'btn_amount1' | 'btn_amount2' | 'btn_amount3';
|
13
15
|
btn1Text: PDSTextType;
|
14
16
|
btn2Text?: PDSTextType;
|
@@ -23,5 +25,5 @@ type DesktopBasicModalWithTabProps = {
|
|
23
25
|
onClickBtn2?: (e: React.MouseEvent<HTMLButtonElement>) => void;
|
24
26
|
onClickBtn3?: (e: React.MouseEvent<HTMLButtonElement>) => void;
|
25
27
|
};
|
26
|
-
declare function DesktopBasicModalWithTab({ size, modalTitleText, infoArray, btnMode, btn1Text, btn2Text, btn3Text, btn1State, btn2State, btn3State, btn1Type, btn2Type, btn3Type, onClickBtn1, onClickBtn2, onClickBtn3 }: DesktopBasicModalWithTabProps): import("react").ReactPortal;
|
28
|
+
declare function DesktopBasicModalWithTab({ size, modalTitleText, infoArray, scrollVisibleType, btnMode, btn1Text, btn2Text, btn3Text, btn1State, btn2State, btn3State, btn1Type, btn2Type, btn3Type, onClickBtn1, onClickBtn2, onClickBtn3 }: DesktopBasicModalWithTabProps): import("react").ReactPortal;
|
27
29
|
export default DesktopBasicModalWithTab;
|
@@ -21,14 +21,14 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
21
21
|
var jsx_runtime_1 = require("react/jsx-runtime");
|
22
22
|
var react_1 = require("react");
|
23
23
|
var react_dom_1 = __importDefault(require("react-dom"));
|
24
|
+
var scrollbarStyle_1 = require("../../../common/styles/scroll/scrollbarStyle");
|
24
25
|
var styled_components_1 = __importDefault(require("styled-components"));
|
25
26
|
var animationStyle_1 = require("../../../common/styles/movement/animationStyle");
|
26
|
-
var scrollbarStyle_1 = require("../../../common/styles/scroll/scrollbarStyle");
|
27
27
|
var hybrid_1 = require("../../../hybrid");
|
28
28
|
var components_1 = require("../../components");
|
29
29
|
var Components_1 = require("./Components");
|
30
30
|
function DesktopBasicModalWithTab(_a) {
|
31
|
-
var _b = _a.size, size = _b === void 0 ? 'large' : _b, modalTitleText = _a.modalTitleText, infoArray = _a.infoArray, _c = _a.btnMode, btnMode =
|
31
|
+
var _b = _a.size, size = _b === void 0 ? 'large' : _b, modalTitleText = _a.modalTitleText, infoArray = _a.infoArray, _c = _a.scrollVisibleType, scrollVisibleType = _c === void 0 ? 'visible' : _c, _d = _a.btnMode, btnMode = _d === void 0 ? 'btn_amount2' : _d, btn1Text = _a.btn1Text, btn2Text = _a.btn2Text, btn3Text = _a.btn3Text, _e = _a.btn1State, btn1State = _e === void 0 ? 'normal' : _e, _f = _a.btn2State, btn2State = _f === void 0 ? 'normal' : _f, _g = _a.btn3State, btn3State = _g === void 0 ? 'normal' : _g, _h = _a.btn1Type, btn1Type = _h === void 0 ? 'button' : _h, _j = _a.btn2Type, btn2Type = _j === void 0 ? 'button' : _j, _k = _a.btn3Type, btn3Type = _k === void 0 ? 'button' : _k, onClickBtn1 = _a.onClickBtn1, onClickBtn2 = _a.onClickBtn2, onClickBtn3 = _a.onClickBtn3;
|
32
32
|
var container = (0, react_1.useState)(function () {
|
33
33
|
var modalRoot = document.createElement('div');
|
34
34
|
modalRoot.setAttribute('id', 'DesktopBasicModalWithTab');
|
@@ -44,7 +44,7 @@ function DesktopBasicModalWithTab(_a) {
|
|
44
44
|
root.removeChild(container);
|
45
45
|
};
|
46
46
|
}, []);
|
47
|
-
var
|
47
|
+
var _l = (0, react_1.useState)("".concat(infoArray[0].sideTabTitleText, "0")), selectedItem = _l[0], setSelectedItem = _l[1];
|
48
48
|
var sideTabTitleArray = infoArray.map(function (data, index) {
|
49
49
|
return {
|
50
50
|
title: data.sideTabTitleText,
|
@@ -57,7 +57,7 @@ function DesktopBasicModalWithTab(_a) {
|
|
57
57
|
var btn3Mode = ['btn_amount3'];
|
58
58
|
return react_dom_1.default.createPortal((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(S_ModalOverlay, {}), (0, jsx_runtime_1.jsxs)(S_ModalWrapper, __assign({ "x-pds-name": "DesktopBasicModalWithTab", "x-pds-element-type": "panel", "x-pds-device-type": "desktop", size: size }, { children: [(0, jsx_runtime_1.jsxs)(S_UpsidePanel, { children: [(0, jsx_runtime_1.jsxs)(S_LeftPanel, { children: [(0, jsx_runtime_1.jsx)(S_Header, { children: (0, jsx_runtime_1.jsx)(components_1.TextLabel, { text: modalTitleText, lineLimit: 2, ellipsisMode: "use", styleTheme: "headingBold" }) }), (0, jsx_runtime_1.jsxs)(S_SideTabWrapper, { children: [(0, jsx_runtime_1.jsx)(Components_1.SideTab, { itemArray: sideTabTitleArray }), (0, jsx_runtime_1.jsx)(hybrid_1.Spacing, { size: "spacing_i" })] })] }), infoArray
|
59
59
|
.filter(function (data, index) { return selectedItem === "".concat(data.sideTabTitleText).concat(index); })
|
60
|
-
.map(function (data, index) { return ((0, jsx_runtime_1.jsx)(S_RightContainer, { children: (0, jsx_runtime_1.jsxs)(S_RightArea, { children: [(0, jsx_runtime_1.jsx)(components_1.TextLabel, { text: data.bodyTitleText ? data.bodyTitleText : data.sideTabTitleText, styleTheme: "headingBold" }), (0, jsx_runtime_1.jsx)(hybrid_1.Spacing, { size: "spacing_e" }), (0, jsx_runtime_1.jsx)(S_Body, { children: data.body && data.body })] }) }, "".concat(data.sideTabTitleText).concat(index))); })] }), (0, jsx_runtime_1.jsxs)(S_Footer, { children: [(0, jsx_runtime_1.jsx)(S_Left, { children: btn3Mode.includes(btnMode) && btn3Text && ((0, jsx_runtime_1.jsx)(components_1.MainButton, { styleTheme: "secondary", text: btn3Text, state: btn3State, type: btn3Type, size: "medium", onClick: onClickBtn3 })) }), (0, jsx_runtime_1.jsxs)(S_Right, { children: [(0, jsx_runtime_1.jsx)(S_Btn2Wrapper, { children: btn2Mode.includes(btnMode) && btn2Text && ((0, jsx_runtime_1.jsx)(components_1.MainButton, { styleTheme: "secondary", text: btn2Text, state: btn2State, type: btn2Type, size: "medium", onClick: onClickBtn2 })) }), btn1Mode.includes(btnMode) && btn1Text && ((0, jsx_runtime_1.jsx)(components_1.MainButton, { text: btn1Text, state: btn1State, type: btn1Type, size: "medium", onClick: onClickBtn1 }))] })] })] }))] }), container);
|
60
|
+
.map(function (data, index) { return ((0, jsx_runtime_1.jsx)(S_RightContainer, __assign({ scrollVisibleType: scrollVisibleType }, { children: (0, jsx_runtime_1.jsxs)(S_RightArea, { children: [(0, jsx_runtime_1.jsx)(components_1.TextLabel, { text: data.bodyTitleText ? data.bodyTitleText : data.sideTabTitleText, styleTheme: "headingBold" }), (0, jsx_runtime_1.jsx)(hybrid_1.Spacing, { size: "spacing_e" }), (0, jsx_runtime_1.jsx)(S_Body, { children: data.body && data.body })] }) }), "".concat(data.sideTabTitleText).concat(index))); })] }), (0, jsx_runtime_1.jsxs)(S_Footer, { children: [(0, jsx_runtime_1.jsx)(S_Left, { children: btn3Mode.includes(btnMode) && btn3Text && ((0, jsx_runtime_1.jsx)(components_1.MainButton, { styleTheme: "secondary", text: btn3Text, state: btn3State, type: btn3Type, size: "medium", onClick: onClickBtn3 })) }), (0, jsx_runtime_1.jsxs)(S_Right, { children: [(0, jsx_runtime_1.jsx)(S_Btn2Wrapper, { children: btn2Mode.includes(btnMode) && btn2Text && ((0, jsx_runtime_1.jsx)(components_1.MainButton, { styleTheme: "secondary", text: btn2Text, state: btn2State, type: btn2Type, size: "medium", onClick: onClickBtn2 })) }), btn1Mode.includes(btnMode) && btn1Text && ((0, jsx_runtime_1.jsx)(components_1.MainButton, { text: btn1Text, state: btn1State, type: btn1Type, size: "medium", onClick: onClickBtn1 }))] })] })] }))] }), container);
|
61
61
|
}
|
62
62
|
var S_ModalOverlay = styled_components_1.default.div(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n background-color: ", ";\n height: 100vh;\n left: 0;\n position: fixed;\n top: 0;\n width: 100vw;\n\n ", "\n"], ["\n background-color: ", ";\n height: 100vh;\n left: 0;\n position: fixed;\n top: 0;\n width: 100vw;\n\n ", "\n"])), function (_a) {
|
63
63
|
var theme = _a.theme;
|
@@ -102,7 +102,13 @@ var S_SideTabWrapper = styled_components_1.default.div(templateObject_6 || (temp
|
|
102
102
|
var theme = _a.theme;
|
103
103
|
return theme.ui_cpnt_modalwithtab_leftside_base;
|
104
104
|
});
|
105
|
-
var S_RightContainer = styled_components_1.default.div(templateObject_7 || (templateObject_7 = __makeTemplateObject(["\n display: flex;\n flex: 1;\n flex-direction: column;\n height: 100%;\n overflow-x: hidden;\n overflow-y: overlay;\n\n ", "\n"], ["\n display: flex;\n flex: 1;\n flex-direction: column;\n height: 100%;\n overflow-x: hidden;\n overflow-y: overlay;\n\n ", "\n"])),
|
105
|
+
var S_RightContainer = styled_components_1.default.div(templateObject_7 || (templateObject_7 = __makeTemplateObject(["\n display: flex;\n flex: 1;\n flex-direction: column;\n height: 100%;\n overflow-x: hidden;\n overflow-y: overlay;\n\n ", "\n"], ["\n display: flex;\n flex: 1;\n flex-direction: column;\n height: 100%;\n overflow-x: hidden;\n overflow-y: overlay;\n\n ", "\n"])), function (_a) {
|
106
|
+
var scrollVisibleType = _a.scrollVisibleType;
|
107
|
+
return ({
|
108
|
+
visible: scrollbarStyle_1.scrollbarStyle,
|
109
|
+
hidden: scrollbarStyle_1.scrollInvisible
|
110
|
+
}[scrollVisibleType]);
|
111
|
+
});
|
106
112
|
var S_RightArea = styled_components_1.default.div(templateObject_8 || (templateObject_8 = __makeTemplateObject(["\n box-sizing: border-box;\n padding-bottom: ", ";\n padding-left: ", ";\n padding-right: ", ";\n padding-top: ", ";\n"], ["\n box-sizing: border-box;\n padding-bottom: ", ";\n padding-left: ", ";\n padding-right: ", ";\n padding-top: ", ";\n"])), function (_a) {
|
107
113
|
var theme = _a.theme;
|
108
114
|
return theme.spacing.spacingI;
|
@@ -116,7 +122,7 @@ var S_RightArea = styled_components_1.default.div(templateObject_8 || (templateO
|
|
116
122
|
var theme = _a.theme;
|
117
123
|
return theme.spacing.spacingE;
|
118
124
|
});
|
119
|
-
var S_Body = styled_components_1.default.div(templateObject_9 || (templateObject_9 = __makeTemplateObject(["\n overflow-x: hidden;\n"], ["\n overflow-x: hidden;\n"])));
|
125
|
+
var S_Body = styled_components_1.default.div(templateObject_9 || (templateObject_9 = __makeTemplateObject(["\n overflow-wrap: break-word;\n overflow-x: hidden;\n white-space: pre-wrap;\n"], ["\n overflow-wrap: break-word;\n overflow-x: hidden;\n white-space: pre-wrap;\n"])));
|
120
126
|
var S_Footer = styled_components_1.default.div(templateObject_10 || (templateObject_10 = __makeTemplateObject(["\n border-top: 1px solid ", ";\n box-sizing: border-box;\n display: flex;\n justify-content: space-between;\n padding-bottom: ", ";\n padding-left: ", ";\n padding-right: ", ";\n padding-top: ", ";\n"], ["\n border-top: 1px solid ", ";\n box-sizing: border-box;\n display: flex;\n justify-content: space-between;\n padding-bottom: ", ";\n padding-left: ", ";\n padding-right: ", ";\n padding-top: ", ";\n"])), function (_a) {
|
121
127
|
var theme = _a.theme;
|
122
128
|
return theme.ui_cpnt_modal_border;
|
@@ -1,10 +1,11 @@
|
|
1
1
|
/// <reference types="react" />
|
2
|
+
import { ScrollVisibleType } from '../../../common/styles/scroll/scrollbarStyle';
|
2
3
|
import type { PDSTextType } from '../../../common/types';
|
3
4
|
type DesktopHeadlessModalProps = {
|
4
5
|
body: React.ReactNode;
|
5
6
|
size?: 'large' | 'medium' | 'small' | 'rlarge' | 'xlarge' | 'rxlarge';
|
6
7
|
dimmedClickCloseMode?: 'use' | 'none';
|
7
|
-
scrollVisibleType?:
|
8
|
+
scrollVisibleType?: ScrollVisibleType;
|
8
9
|
footerMode?: 'use' | 'none';
|
9
10
|
btnMode?: 'mbtn_amount1' | 'mbtn_amount2' | 'mbtn_amount3';
|
10
11
|
mBtn1Text?: PDSTextType;
|
@@ -44,10 +44,10 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
44
44
|
var jsx_runtime_1 = require("react/jsx-runtime");
|
45
45
|
var react_1 = require("react");
|
46
46
|
var react_dom_1 = __importDefault(require("react-dom"));
|
47
|
+
var scrollbarStyle_1 = require("../../../common/styles/scroll/scrollbarStyle");
|
47
48
|
var components_1 = require("../../components");
|
48
49
|
var styled_components_1 = __importStar(require("styled-components"));
|
49
50
|
var animationStyle_1 = require("../../../common/styles/movement/animationStyle");
|
50
|
-
var scrollbarStyle_1 = require("../../../common/styles/scroll/scrollbarStyle");
|
51
51
|
function DesktopHeadlessModal(_a) {
|
52
52
|
var body = _a.body, _b = _a.size, size = _b === void 0 ? 'rlarge' : _b, _c = _a.dimmedClickCloseMode, dimmedClickCloseMode = _c === void 0 ? 'none' : _c, _d = _a.scrollVisibleType, scrollVisibleType = _d === void 0 ? 'visible' : _d, onClose = _a.onClose, _e = _a.footerMode, footerMode = _e === void 0 ? 'none' : _e, _f = _a.btnMode, btnMode = _f === void 0 ? 'mbtn_amount2' : _f, mBtn1Text = _a.mBtn1Text, mBtn2Text = _a.mBtn2Text, mBtn3Text = _a.mBtn3Text, _g = _a.mBtn1State, mBtn1State = _g === void 0 ? 'normal' : _g, _h = _a.mBtn2State, mBtn2State = _h === void 0 ? 'normal' : _h, _j = _a.mBtn3State, mBtn3State = _j === void 0 ? 'normal' : _j, _k = _a.mBtn1Type, mBtn1Type = _k === void 0 ? 'button' : _k, _l = _a.mBtn2Type, mBtn2Type = _l === void 0 ? 'button' : _l, _m = _a.mBtn3Type, mBtn3Type = _m === void 0 ? 'button' : _m, onClickMBtn1 = _a.onClickMBtn1, onClickMBtn2 = _a.onClickMBtn2, onClickMBtn3 = _a.onClickMBtn3;
|
53
53
|
var container = (0, react_1.useState)(function () {
|
@@ -55,7 +55,6 @@ function DesktopHeadlessModal(_a) {
|
|
55
55
|
modalRoot.setAttribute('id', 'DesktopHeadlessModal');
|
56
56
|
return modalRoot;
|
57
57
|
})[0];
|
58
|
-
var targetRef = (0, react_1.useRef)(null);
|
59
58
|
var handleClickOutside = function (e) {
|
60
59
|
e.stopPropagation();
|
61
60
|
if (dimmedClickCloseMode === 'use') {
|
@@ -66,32 +65,18 @@ function DesktopHeadlessModal(_a) {
|
|
66
65
|
};
|
67
66
|
(0, react_1.useLayoutEffect)(function () {
|
68
67
|
var root = document.getElementById('root');
|
69
|
-
var isScrolling;
|
70
|
-
var handleScroll = function () {
|
71
|
-
if (targetRef.current) {
|
72
|
-
targetRef.current.classList.add('scrollMoving');
|
73
|
-
}
|
74
|
-
isScrolling = setTimeout(function () {
|
75
|
-
var _a;
|
76
|
-
(_a = targetRef.current) === null || _a === void 0 ? void 0 : _a.classList.remove('scrollMoving');
|
77
|
-
}, 500);
|
78
|
-
};
|
79
68
|
if (!root) {
|
80
69
|
return;
|
81
70
|
}
|
82
|
-
if (targetRef.current) {
|
83
|
-
targetRef.current.onscroll = handleScroll;
|
84
|
-
}
|
85
71
|
root.appendChild(container);
|
86
72
|
return function () {
|
87
73
|
root.removeChild(container);
|
88
|
-
clearTimeout(isScrolling);
|
89
74
|
};
|
90
75
|
}, []);
|
91
76
|
var btn1Mode = ['mbtn_amount1', 'mbtn_amount2', 'mbtn_amount3'];
|
92
77
|
var btn2Mode = ['mbtn_amount2', 'mbtn_amount3'];
|
93
78
|
var btn3Mode = ['mbtn_amount3'];
|
94
|
-
return react_dom_1.default.createPortal((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(S_ModalOverlay, { "x-pds-name": "DesktopHeadlessModal", "x-pds-element-type": "panel", "x-pds-device-type": "desktop", onMouseDown: handleClickOutside }), (0, jsx_runtime_1.jsxs)(S_ModalWrapper, __assign({ size: size }, { children: [(0, jsx_runtime_1.jsx)(S_Body, __assign({
|
79
|
+
return react_dom_1.default.createPortal((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(S_ModalOverlay, { "x-pds-name": "DesktopHeadlessModal", "x-pds-element-type": "panel", "x-pds-device-type": "desktop", onMouseDown: handleClickOutside }), (0, jsx_runtime_1.jsxs)(S_ModalWrapper, __assign({ size: size }, { children: [(0, jsx_runtime_1.jsx)(S_Body, __assign({ scrollVisibleType: scrollVisibleType }, { children: body && body })), footerMode === 'use' && ((0, jsx_runtime_1.jsxs)(S_Footer, { children: [(0, jsx_runtime_1.jsx)(S_Left, { children: btn3Mode.includes(btnMode) && mBtn3Text && ((0, jsx_runtime_1.jsx)(components_1.MainButton, { styleTheme: "secondary", text: mBtn3Text, state: mBtn3State, type: mBtn3Type, size: "medium", onClick: onClickMBtn3 })) }), (0, jsx_runtime_1.jsxs)(S_Right, { children: [(0, jsx_runtime_1.jsx)(S_Btn2Wrapper, { children: btn2Mode.includes(btnMode) && mBtn2Text && ((0, jsx_runtime_1.jsx)(components_1.MainButton, { styleTheme: "secondary", text: mBtn2Text, state: mBtn2State, type: mBtn2Type, size: "medium", onClick: onClickMBtn2 })) }), btn1Mode.includes(btnMode) && mBtn1Text && ((0, jsx_runtime_1.jsx)(components_1.MainButton, { text: mBtn1Text, state: mBtn1State, type: mBtn1Type, size: "medium", onClick: onClickMBtn1 }))] })] }))] }))] }), container);
|
95
80
|
}
|
96
81
|
var S_ModalOverlay = styled_components_1.default.div(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n background-color: ", ";\n height: 100vh;\n left: 0;\n position: fixed;\n top: 0;\n width: 100vw;\n\n ", "\n"], ["\n background-color: ", ";\n height: 100vh;\n left: 0;\n position: fixed;\n top: 0;\n width: 100vw;\n\n ", "\n"])), function (_a) {
|
97
82
|
var theme = _a.theme;
|
@@ -122,17 +107,12 @@ var S_ModalWrapper = styled_components_1.default.div(templateObject_2 || (templa
|
|
122
107
|
return sizes[size];
|
123
108
|
}, animationStyle_1.modalOnAni);
|
124
109
|
var scrollInvisible = (0, styled_components_1.css)(templateObject_3 || (templateObject_3 = __makeTemplateObject(["\n ::-webkit-scrollbar {\n display: none;\n }\n"], ["\n ::-webkit-scrollbar {\n display: none;\n }\n"])));
|
125
|
-
var S_Body = styled_components_1.default.div(templateObject_4 || (templateObject_4 = __makeTemplateObject(["\n overflow: auto;\n overflow-y: overlay;\n width: 100%;\n\n ", "\n
|
126
|
-
var scrollVisibleType = _a.scrollVisibleType;
|
127
|
-
return scrollVisibleType &&
|
128
|
-
{
|
129
|
-
moving: scrollInvisible,
|
130
|
-
visible: scrollbarStyle_1.scrollbarWithPaddingStyle,
|
131
|
-
hidden: scrollInvisible
|
132
|
-
}[scrollVisibleType];
|
133
|
-
}, function (_a) {
|
110
|
+
var S_Body = styled_components_1.default.div(templateObject_4 || (templateObject_4 = __makeTemplateObject(["\n overflow: auto;\n overflow-y: overlay;\n width: 100%;\n\n ", "\n"], ["\n overflow: auto;\n overflow-y: overlay;\n width: 100%;\n\n ", "\n"])), function (_a) {
|
134
111
|
var scrollVisibleType = _a.scrollVisibleType;
|
135
|
-
return
|
112
|
+
return ({
|
113
|
+
visible: scrollbarStyle_1.scrollbarWithPaddingStyle,
|
114
|
+
hidden: scrollInvisible
|
115
|
+
}[scrollVisibleType]);
|
136
116
|
});
|
137
117
|
var S_Left = styled_components_1.default.div(templateObject_5 || (templateObject_5 = __makeTemplateObject(["\n margin-right: ", ";\n"], ["\n margin-right: ", ";\n"])), function (_a) {
|
138
118
|
var theme = _a.theme;
|
@@ -1,4 +1,5 @@
|
|
1
1
|
/// <reference types="react" />
|
2
|
+
import { ScrollVisibleType } from '../../../common/styles/scroll/scrollbarStyle';
|
2
3
|
import type { PDSTextType } from '../../../common';
|
3
4
|
export type DesktopTutorialModalInfoType = {
|
4
5
|
sideTabTitleText: PDSTextType;
|
@@ -13,7 +14,8 @@ type DesktopTutorialModalProps = {
|
|
13
14
|
modalTitleText: PDSTextType;
|
14
15
|
infoArray: DesktopTutorialModalInfoType[];
|
15
16
|
sequenceMode?: 'use' | 'none';
|
17
|
+
scrollVisibleType?: ScrollVisibleType;
|
16
18
|
onClose: (e: React.MouseEvent<HTMLButtonElement>) => void;
|
17
19
|
};
|
18
|
-
declare function DesktopTutorialModal({ modalTitleText, infoArray, sequenceMode, onClose }: DesktopTutorialModalProps): import("react").ReactPortal;
|
20
|
+
declare function DesktopTutorialModal({ modalTitleText, infoArray, sequenceMode, scrollVisibleType, onClose }: DesktopTutorialModalProps): import("react").ReactPortal;
|
19
21
|
export default DesktopTutorialModal;
|
@@ -21,14 +21,14 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
21
21
|
var jsx_runtime_1 = require("react/jsx-runtime");
|
22
22
|
var react_1 = require("react");
|
23
23
|
var react_dom_1 = __importDefault(require("react-dom"));
|
24
|
+
var scrollbarStyle_1 = require("../../../common/styles/scroll/scrollbarStyle");
|
24
25
|
var styled_components_1 = __importDefault(require("styled-components"));
|
25
26
|
var animationStyle_1 = require("../../../common/styles/movement/animationStyle");
|
26
|
-
var scrollbarStyle_1 = require("../../../common/styles/scroll/scrollbarStyle");
|
27
27
|
var hybrid_1 = require("../../../hybrid");
|
28
28
|
var components_1 = require("../../components");
|
29
29
|
var Components_1 = require("./Components");
|
30
30
|
function DesktopTutorialModal(_a) {
|
31
|
-
var modalTitleText = _a.modalTitleText, infoArray = _a.infoArray, _b = _a.sequenceMode, sequenceMode = _b === void 0 ? 'use' : _b, onClose = _a.onClose;
|
31
|
+
var modalTitleText = _a.modalTitleText, infoArray = _a.infoArray, _b = _a.sequenceMode, sequenceMode = _b === void 0 ? 'use' : _b, _c = _a.scrollVisibleType, scrollVisibleType = _c === void 0 ? 'visible' : _c, onClose = _a.onClose;
|
32
32
|
var container = (0, react_1.useState)(function () {
|
33
33
|
var modalRoot = document.createElement('div');
|
34
34
|
modalRoot.setAttribute('id', 'DesktopTutorialModal');
|
@@ -44,7 +44,7 @@ function DesktopTutorialModal(_a) {
|
|
44
44
|
root.removeChild(container);
|
45
45
|
};
|
46
46
|
}, []);
|
47
|
-
var
|
47
|
+
var _d = (0, react_1.useState)("".concat(infoArray[0].sideTabTitleText, "0")), selectedItem = _d[0], setSelectedItem = _d[1];
|
48
48
|
var sideTabTitleArray = infoArray.map(function (data, index) {
|
49
49
|
return {
|
50
50
|
title: data.sideTabTitleText,
|
@@ -70,7 +70,7 @@ function DesktopTutorialModal(_a) {
|
|
70
70
|
};
|
71
71
|
return react_dom_1.default.createPortal((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(S_ModalOverlay, {}), (0, jsx_runtime_1.jsxs)(S_ModalWrapper, __assign({ "x-pds-name": "DesktopTutorialModal", "x-pds-element-type": "panel", "x-pds-device-type": "desktop" }, { children: [(0, jsx_runtime_1.jsxs)(S_LeftPanel, { children: [(0, jsx_runtime_1.jsx)(S_Header, { children: (0, jsx_runtime_1.jsx)(components_1.TextLabel, { text: modalTitleText, lineLimit: 2, ellipsisMode: "use", styleTheme: "headingBold" }) }), (0, jsx_runtime_1.jsxs)(S_SideTabWrapper, { children: [(0, jsx_runtime_1.jsx)(Components_1.SideTab, { itemArray: sideTabTitleArray }), (0, jsx_runtime_1.jsx)(hybrid_1.Spacing, { size: "spacing_i" })] })] }), infoArray
|
72
72
|
.filter(function (data, index) { return selectedItem === "".concat(data.sideTabTitleText).concat(index); })
|
73
|
-
.map(function (data, index) { return ((0, jsx_runtime_1.jsxs)(S_RightPanel, { children: [(0, jsx_runtime_1.jsx)(hybrid_1.ImageView, { src: data.imageSrc, shapeType: "rectangle", width: "responsive", ratio: "16_9", scaleType: "cover", backgroundFillMode: "use" }), (0, jsx_runtime_1.jsxs)(S_InfoBox, { children: [(0, jsx_runtime_1.jsx)(components_1.TextLabel, { text: data.infoTitleText ? data.infoTitleText : data.sideTabTitleText, styleTheme: "headingBold" }), (0, jsx_runtime_1.jsx)(hybrid_1.Spacing, { size: "spacing_d" }), (0, jsx_runtime_1.jsx)(components_1.TextLabel, { text: data.infoDescText, styleTheme: "body2Regular", colorTheme: "sysTextSecondary" })] }), data.btnMode === 'btn_amount1' && ((0, jsx_runtime_1.jsx)(S_Footer, { children: (0, jsx_runtime_1.jsx)(components_1.MainButton, { text: data.btn1Text, type: "button", size: "medium", onClick: data.onClickBtn1 }) }))] }, "".concat(data.sideTabTitleText).concat(index))); }), (0, jsx_runtime_1.jsx)(S_IconButtonWrapper, { children: sequenceMode === 'use' && selectedItemIndex !== lastIndex ? ((0, jsx_runtime_1.jsx)(components_1.IconButton, { shapeType: "circular", baseSize: "medium", baseColorKey: "ui_cpnt_button_fill_base_tutorialmodal", iconName: "ic_arrow_right", iconColorKey: "ui_cpnt_button_icon_white", onClick: handleClickNextBtn })) : ((0, jsx_runtime_1.jsx)(components_1.IconButton, { shapeType: "circular", baseSize: "medium", baseColorKey: "ui_cpnt_button_fill_base_tutorialmodal", iconName: "ic_xmark", iconColorKey: "ui_cpnt_button_icon_white", onClick: handleClickCloseBtn })) })] }))] }), container);
|
73
|
+
.map(function (data, index) { return ((0, jsx_runtime_1.jsxs)(S_RightPanel, { children: [(0, jsx_runtime_1.jsx)(hybrid_1.ImageView, { src: data.imageSrc, shapeType: "rectangle", width: "responsive", ratio: "16_9", scaleType: "cover", backgroundFillMode: "use" }), (0, jsx_runtime_1.jsxs)(S_InfoBox, __assign({ scrollVisibleType: scrollVisibleType }, { children: [(0, jsx_runtime_1.jsx)(components_1.TextLabel, { text: data.infoTitleText ? data.infoTitleText : data.sideTabTitleText, styleTheme: "headingBold" }), (0, jsx_runtime_1.jsx)(hybrid_1.Spacing, { size: "spacing_d" }), (0, jsx_runtime_1.jsx)(components_1.TextLabel, { text: data.infoDescText, styleTheme: "body2Regular", colorTheme: "sysTextSecondary" })] })), data.btnMode === 'btn_amount1' && ((0, jsx_runtime_1.jsx)(S_Footer, { children: (0, jsx_runtime_1.jsx)(components_1.MainButton, { text: data.btn1Text, type: "button", size: "medium", onClick: data.onClickBtn1 }) }))] }, "".concat(data.sideTabTitleText).concat(index))); }), (0, jsx_runtime_1.jsx)(S_IconButtonWrapper, { children: sequenceMode === 'use' && selectedItemIndex !== lastIndex ? ((0, jsx_runtime_1.jsx)(components_1.IconButton, { shapeType: "circular", baseSize: "medium", baseColorKey: "ui_cpnt_button_fill_base_tutorialmodal", iconName: "ic_arrow_right", iconColorKey: "ui_cpnt_button_icon_white", onClick: handleClickNextBtn })) : ((0, jsx_runtime_1.jsx)(components_1.IconButton, { shapeType: "circular", baseSize: "medium", baseColorKey: "ui_cpnt_button_fill_base_tutorialmodal", iconName: "ic_xmark", iconColorKey: "ui_cpnt_button_icon_white", onClick: handleClickCloseBtn })) })] }))] }), container);
|
74
74
|
}
|
75
75
|
var S_ModalOverlay = styled_components_1.default.div(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n background-color: ", ";\n height: 100vh;\n left: 0;\n position: fixed;\n top: 0;\n width: 100vw;\n\n ", "\n"], ["\n background-color: ", ";\n height: 100vh;\n left: 0;\n position: fixed;\n top: 0;\n width: 100vw;\n\n ", "\n"])), function (_a) {
|
76
76
|
var theme = _a.theme;
|
@@ -114,7 +114,13 @@ var S_InfoBox = styled_components_1.default.div(templateObject_7 || (templateObj
|
|
114
114
|
}, function (_a) {
|
115
115
|
var theme = _a.theme;
|
116
116
|
return theme.spacing.spacingF;
|
117
|
-
},
|
117
|
+
}, function (_a) {
|
118
|
+
var scrollVisibleType = _a.scrollVisibleType;
|
119
|
+
return ({
|
120
|
+
visible: scrollbarStyle_1.scrollbarStyle,
|
121
|
+
hidden: scrollbarStyle_1.scrollInvisible
|
122
|
+
}[scrollVisibleType]);
|
123
|
+
});
|
118
124
|
var S_Footer = styled_components_1.default.div(templateObject_8 || (templateObject_8 = __makeTemplateObject(["\n align-items: flex-end;\n box-sizing: border-box;\n display: flex;\n height: 88px;\n min-height: 88px;\n padding-bottom: ", ";\n padding-left: ", ";\n padding-right: ", ";\n"], ["\n align-items: flex-end;\n box-sizing: border-box;\n display: flex;\n height: 88px;\n min-height: 88px;\n padding-bottom: ", ";\n padding-left: ", ";\n padding-right: ", ";\n"])), function (_a) {
|
119
125
|
var theme = _a.theme;
|
120
126
|
return theme.spacing.spacingF;
|
@@ -1,4 +1,5 @@
|
|
1
1
|
/// <reference types="react" />
|
2
|
+
import { ScrollVisibleType } from '../../../common/styles/scroll/scrollbarStyle';
|
2
3
|
import type { MultilingualConfig } from '../../../common/types';
|
3
4
|
type MultilingualModalModalProps = {
|
4
5
|
isOpen: boolean;
|
@@ -6,6 +7,7 @@ type MultilingualModalModalProps = {
|
|
6
7
|
config?: MultilingualConfig;
|
7
8
|
size?: 'large' | 'medium' | 'small' | 'rlarge';
|
8
9
|
onHiddenInputUpdate?: (newValue: string) => void;
|
10
|
+
scrollVisibleType?: ScrollVisibleType;
|
9
11
|
};
|
10
|
-
declare function MultilingualModal({ isOpen, onClose, config, size, onHiddenInputUpdate }: MultilingualModalModalProps): import("react").ReactPortal | null;
|
12
|
+
declare function MultilingualModal({ isOpen, onClose, config, size, onHiddenInputUpdate, scrollVisibleType }: MultilingualModalModalProps): import("react").ReactPortal | null;
|
11
13
|
export default MultilingualModal;
|
@@ -24,6 +24,7 @@ var react_dom_1 = __importDefault(require("react-dom"));
|
|
24
24
|
var react_hook_form_1 = require("react-hook-form");
|
25
25
|
var react_i18next_1 = require("react-i18next");
|
26
26
|
var animationStyle_1 = require("../../../common/styles/movement/animationStyle");
|
27
|
+
var scrollbarStyle_1 = require("../../../common/styles/scroll/scrollbarStyle");
|
27
28
|
var components_1 = require("../../components");
|
28
29
|
var components_2 = require("../../../hybrid/components");
|
29
30
|
var styled_components_1 = __importDefault(require("styled-components"));
|
@@ -38,7 +39,7 @@ var LANGUAGE_I18N_KEYS = {
|
|
38
39
|
};
|
39
40
|
function MultilingualModal(_a) {
|
40
41
|
var _b, _c;
|
41
|
-
var isOpen = _a.isOpen, onClose = _a.onClose, config = _a.config, _d = _a.size, size = _d === void 0 ? 'medium' : _d, onHiddenInputUpdate = _a.onHiddenInputUpdate;
|
42
|
+
var isOpen = _a.isOpen, onClose = _a.onClose, config = _a.config, _d = _a.size, size = _d === void 0 ? 'medium' : _d, onHiddenInputUpdate = _a.onHiddenInputUpdate, _e = _a.scrollVisibleType, scrollVisibleType = _e === void 0 ? 'visible' : _e;
|
42
43
|
var t = (0, react_i18next_1.useTranslation)().t;
|
43
44
|
var allLangInReadonly = (_b = config === null || config === void 0 ? void 0 : config.visibleLanguages) === null || _b === void 0 ? void 0 : _b.every(function (item) { var _a; return (_a = config === null || config === void 0 ? void 0 : config.readonlyLanguages) === null || _a === void 0 ? void 0 : _a.includes(item); });
|
44
45
|
// FormProvider에서 사용할 기본값 계산
|
@@ -114,11 +115,11 @@ function MultilingualModal(_a) {
|
|
114
115
|
};
|
115
116
|
if (!isOpen)
|
116
117
|
return null;
|
117
|
-
return react_dom_1.default.createPortal((0, jsx_runtime_1.jsxs)(react_hook_form_1.FormProvider, __assign({}, methods, { children: [(0, jsx_runtime_1.jsx)(S_ModalOverlay, { onClick: handleCancel }), (0, jsx_runtime_1.jsxs)(S_ModalWrapper, __assign({ "x-pds-name": "MultiLanguageModal", "x-pds-element-type": "panel", "x-pds-device-type": "desktop", size: size }, { children: [(0, jsx_runtime_1.jsx)(S_Header, { children: (0, jsx_runtime_1.jsx)(components_1.TextLabel, { text: t('str_multilingual_settings'), colorTheme: "sysTextPrimary", styleTheme: "headingBold" }) }), (0, jsx_runtime_1.jsxs)(S_Body, { children: [(config === null || config === void 0 ? void 0 : config.originalText) && ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(components_1.BodyTextGroup, { titleText: t('str_original_text'), contentText: config.originalText }), (0, jsx_runtime_1.jsx)(components_2.Spacing, { size: "spacing_f" }), (0, jsx_runtime_1.jsx)(components_2.Divider, {}), (0, jsx_runtime_1.jsx)(components_2.Spacing, { size: "spacing_f" })] })), (_c = config === null || config === void 0 ? void 0 : config.visibleLanguages) === null || _c === void 0 ? void 0 : _c.map(function (languageCode, index) {
|
118
|
+
return react_dom_1.default.createPortal((0, jsx_runtime_1.jsxs)(react_hook_form_1.FormProvider, __assign({}, methods, { children: [(0, jsx_runtime_1.jsx)(S_ModalOverlay, { onClick: handleCancel }), (0, jsx_runtime_1.jsxs)(S_ModalWrapper, __assign({ "x-pds-name": "MultiLanguageModal", "x-pds-element-type": "panel", "x-pds-device-type": "desktop", size: size }, { children: [(0, jsx_runtime_1.jsx)(S_Header, { children: (0, jsx_runtime_1.jsx)(components_1.TextLabel, { text: t('str_multilingual_settings'), colorTheme: "sysTextPrimary", styleTheme: "headingBold" }) }), (0, jsx_runtime_1.jsxs)(S_Body, __assign({ scrollVisibleType: scrollVisibleType }, { children: [(config === null || config === void 0 ? void 0 : config.originalText) && ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(components_1.BodyTextGroup, { titleText: t('str_original_text'), contentText: config.originalText }), (0, jsx_runtime_1.jsx)(components_2.Spacing, { size: "spacing_f" }), (0, jsx_runtime_1.jsx)(components_2.Divider, {}), (0, jsx_runtime_1.jsx)(components_2.Spacing, { size: "spacing_f" })] })), (_c = config === null || config === void 0 ? void 0 : config.visibleLanguages) === null || _c === void 0 ? void 0 : _c.map(function (languageCode, index) {
|
118
119
|
var _a, _b;
|
119
120
|
var isReadonly = (_a = config.readonlyLanguages) === null || _a === void 0 ? void 0 : _a.includes(languageCode);
|
120
121
|
return ((0, jsx_runtime_1.jsxs)(S_LanguageField, { children: [(0, jsx_runtime_1.jsx)(components_1.TextLabel, { text: "".concat(t(LANGUAGE_I18N_KEYS[languageCode])), styleTheme: "subTitleBold", colorTheme: "sysTextPrimary" }), (0, jsx_runtime_1.jsx)(components_2.Spacing, { size: "spacing_b" }), (0, jsx_runtime_1.jsx)(components_1.TextField, { responsiveMode: "use", multiRows: config.textFieldLineType === 'multi' ? 5 : undefined, autoMaxRows: config.textFieldLineType === 'auto' ? 5 : undefined, autoMinRows: config.textFieldLineType === 'auto' ? 1 : undefined, name: languageCode, hintText: t('str_9071'), placeholder: "Input Text", textLineType: config.textFieldLineType, state: isReadonly ? 'disabled' : 'normal' }), index < (((_b = config.visibleLanguages) === null || _b === void 0 ? void 0 : _b.length) || 0) - 1 && (0, jsx_runtime_1.jsx)(components_2.Spacing, { size: "spacing_f" })] }, "".concat(languageCode, "_field")));
|
121
|
-
})] }), (0, jsx_runtime_1.jsxs)(S_Footer, { children: [(0, jsx_runtime_1.jsx)(S_Left, {}), (0, jsx_runtime_1.jsxs)(S_Right, { children: [!allLangInReadonly && ((0, jsx_runtime_1.jsx)(S_Btn2Wrapper, { children: (0, jsx_runtime_1.jsx)(components_1.MainButton, { styleTheme: "secondary", text: t('str_cancel'), size: "medium", onClick: handleCancel }) })), (0, jsx_runtime_1.jsx)(components_1.MainButton, { text: allLangInReadonly ? t('str_confirm') : t('str_apply'), size: "medium", onClick: handleConfirm })] })] })] }))] })), container);
|
122
|
+
})] })), (0, jsx_runtime_1.jsxs)(S_Footer, { children: [(0, jsx_runtime_1.jsx)(S_Left, {}), (0, jsx_runtime_1.jsxs)(S_Right, { children: [!allLangInReadonly && ((0, jsx_runtime_1.jsx)(S_Btn2Wrapper, { children: (0, jsx_runtime_1.jsx)(components_1.MainButton, { styleTheme: "secondary", text: t('str_cancel'), size: "medium", onClick: handleCancel }) })), (0, jsx_runtime_1.jsx)(components_1.MainButton, { text: allLangInReadonly ? t('str_confirm') : t('str_apply'), size: "medium", onClick: handleConfirm })] })] })] }))] })), container);
|
122
123
|
}
|
123
124
|
var S_ModalOverlay = styled_components_1.default.div(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n background-color: ", ";\n height: 100vh;\n left: 0;\n position: fixed;\n top: 0;\n width: 100vw;\n\n ", "\n"], ["\n background-color: ", ";\n height: 100vh;\n left: 0;\n position: fixed;\n top: 0;\n width: 100vw;\n\n ", "\n"])), function (_a) {
|
124
125
|
var theme = _a.theme;
|
@@ -156,7 +157,7 @@ var S_Header = styled_components_1.default.div(templateObject_3 || (templateObje
|
|
156
157
|
var theme = _a.theme;
|
157
158
|
return theme.spacing.spacingE;
|
158
159
|
});
|
159
|
-
var S_Body = styled_components_1.default.div(templateObject_4 || (templateObject_4 = __makeTemplateObject(["\n flex: 1;\n max-height: 60vh;\n overflow: auto;\n padding-bottom: ", ";\n padding-left: ", ";\n padding-right: ", ";\n padding-top: ", ";\n"], ["\n flex: 1;\n max-height: 60vh;\n overflow: auto;\n padding-bottom: ", ";\n padding-left: ", ";\n padding-right: ", ";\n padding-top: ", ";\n"])), function (_a) {
|
160
|
+
var S_Body = styled_components_1.default.div(templateObject_4 || (templateObject_4 = __makeTemplateObject(["\n flex: 1;\n max-height: 60vh;\n overflow: auto;\n padding-bottom: ", ";\n padding-left: ", ";\n padding-right: ", ";\n padding-top: ", ";\n\n ", "\n"], ["\n flex: 1;\n max-height: 60vh;\n overflow: auto;\n padding-bottom: ", ";\n padding-left: ", ";\n padding-right: ", ";\n padding-top: ", ";\n\n ", "\n"])), function (_a) {
|
160
161
|
var theme = _a.theme;
|
161
162
|
return theme.spacing.spacingF;
|
162
163
|
}, function (_a) {
|
@@ -168,6 +169,12 @@ var S_Body = styled_components_1.default.div(templateObject_4 || (templateObject
|
|
168
169
|
}, function (_a) {
|
169
170
|
var theme = _a.theme;
|
170
171
|
return theme.spacing.spacingD;
|
172
|
+
}, function (_a) {
|
173
|
+
var scrollVisibleType = _a.scrollVisibleType;
|
174
|
+
return ({
|
175
|
+
visible: scrollbarStyle_1.scrollbarStyle,
|
176
|
+
hidden: scrollbarStyle_1.scrollInvisible
|
177
|
+
}[scrollVisibleType]);
|
171
178
|
});
|
172
179
|
var S_Footer = styled_components_1.default.div(templateObject_5 || (templateObject_5 = __makeTemplateObject(["\n border-top: 1px solid ", ";\n box-sizing: border-box;\n display: flex;\n justify-content: space-between;\n padding-bottom: ", ";\n padding-left: ", ";\n padding-right: ", ";\n padding-top: ", ";\n"], ["\n border-top: 1px solid ", ";\n box-sizing: border-box;\n display: flex;\n justify-content: space-between;\n padding-bottom: ", ";\n padding-left: ", ";\n padding-right: ", ";\n padding-top: ", ";\n"])), function (_a) {
|
173
180
|
var theme = _a.theme;
|