pds-dev-kit-web-test 2.6.2 → 2.6.3

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.
Files changed (49) hide show
  1. package/dist/index.d.ts +5 -5
  2. package/dist/index.js +5 -7
  3. package/dist/src/common/assets/icons/fill/Gift.d.ts +4 -0
  4. package/dist/src/common/assets/icons/fill/Gift.js +30 -0
  5. package/dist/src/common/assets/icons/fill/index.d.ts +1 -0
  6. package/dist/src/common/assets/icons/fill/index.js +3 -1
  7. package/dist/src/common/assets/icons/line/Gift.d.ts +4 -0
  8. package/dist/src/common/assets/icons/line/Gift.js +30 -0
  9. package/dist/src/common/assets/icons/line/index.d.ts +1 -0
  10. package/dist/src/common/assets/icons/line/index.js +3 -1
  11. package/dist/src/common/types/index.d.ts +1 -1
  12. package/dist/src/common/types/index.js +1 -1
  13. package/dist/src/common/types/{LocalizedContent.d.ts → multilingual.d.ts} +5 -6
  14. package/dist/src/desktop/components/BasicFormGroup/BasicFormGroup.d.ts +5 -4
  15. package/dist/src/desktop/components/BasicFormGroup/BasicFormGroup.js +53 -3
  16. package/dist/src/desktop/components/BodyTextGroup/BodyTextGroup.d.ts +5 -3
  17. package/dist/src/desktop/components/BodyTextGroup/BodyTextGroup.js +51 -3
  18. package/dist/src/desktop/components/RichTextEditor/RichTextEditor.js +1 -1
  19. package/dist/src/desktop/components/index.d.ts +1 -2
  20. package/dist/src/desktop/components/index.js +1 -3
  21. package/dist/src/desktop/index.d.ts +2 -2
  22. package/dist/src/desktop/index.js +1 -3
  23. package/dist/src/desktop/panels/ContentSheet/ContentSheet.d.ts +4 -1
  24. package/dist/src/desktop/panels/ContentSheet/ContentSheet.js +11 -3
  25. package/dist/src/desktop/panels/MultilingualModal/MultilingualModal.d.ts +13 -0
  26. package/dist/src/desktop/panels/MultilingualModal/MultilingualModal.js +206 -0
  27. package/dist/src/desktop/panels/MultilingualModal/index.d.ts +1 -0
  28. package/dist/src/desktop/panels/{LocalizedContentModal → MultilingualModal}/index.js +2 -2
  29. package/dist/src/desktop/panels/SectionSheet/SectionSheet.d.ts +4 -1
  30. package/dist/src/desktop/panels/SectionSheet/SectionSheet.js +11 -3
  31. package/dist/src/desktop/panels/index.d.ts +2 -2
  32. package/dist/src/desktop/panels/index.js +3 -3
  33. package/dist/src/mobile/panels/ContentSheet/ContentSheet.d.ts +4 -1
  34. package/dist/src/mobile/panels/ContentSheet/ContentSheet.js +11 -3
  35. package/dist/src/mobile/panels/SectionSheet/SectionSheet.d.ts +4 -1
  36. package/dist/src/mobile/panels/SectionSheet/SectionSheet.js +11 -3
  37. package/dist/src/sub/DynamicLayout/sections/CustomSection/CustomSection.js +5 -3
  38. package/package.json +1 -1
  39. package/release-note.md +3 -3
  40. package/dist/src/common/styles/editorContentStyle.d.ts +0 -1
  41. package/dist/src/common/styles/editorContentStyle.js +0 -76
  42. package/dist/src/desktop/components/LocalizedButton/LocalizedButton.d.ts +0 -8
  43. package/dist/src/desktop/components/LocalizedButton/LocalizedButton.js +0 -44
  44. package/dist/src/desktop/components/LocalizedButton/index.d.ts +0 -1
  45. package/dist/src/desktop/components/LocalizedButton/index.js +0 -8
  46. package/dist/src/desktop/panels/LocalizedContentModal/LocalizedContentModal.d.ts +0 -24
  47. package/dist/src/desktop/panels/LocalizedContentModal/LocalizedContentModal.js +0 -81
  48. package/dist/src/desktop/panels/LocalizedContentModal/index.d.ts +0 -1
  49. /package/dist/src/common/types/{LocalizedContent.js → multilingual.js} +0 -0
package/release-note.md CHANGED
@@ -1,6 +1,6 @@
1
- # PDS-DEV-KIT-WEB-TEST Release Notes
2
- ## [v2.6.2]
1
+ # PDS-DEV-KIT-WEB Release Notes
2
+ ## [v2.2.231]
3
3
  ## daily|https://design.storybook.publ.biz/
4
4
 
5
5
  ### 업데이트 사항
6
- * [DAILY][PDS-1339] 다국어 모달 수정
6
+ * [PDS-1359] ic_gift 아이콘 추가 건
@@ -1 +0,0 @@
1
- export declare const editorContentStyle: import("styled-components").FlattenInterpolation<import("styled-components").ThemeProps<import("styled-components").DefaultTheme>>;
@@ -1,76 +0,0 @@
1
- "use strict";
2
- var __makeTemplateObject = (this && this.__makeTemplateObject) || function (cooked, raw) {
3
- if (Object.defineProperty) { Object.defineProperty(cooked, "raw", { value: raw }); } else { cooked.raw = raw; }
4
- return cooked;
5
- };
6
- Object.defineProperty(exports, "__esModule", { value: true });
7
- exports.editorContentStyle = void 0;
8
- var styled_components_1 = require("styled-components");
9
- exports.editorContentStyle = (0, styled_components_1.css)(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n color: ", ";\n font-size: ", ";\n line-height: ", ";\n text-align: left;\n white-space: pre-wrap;\n width: 100%;\n word-break: break-word;\n\n & pre {\n white-space: pre-wrap;\n }\n\n div,\n p {\n overflow: hidden;\n }\n\n h1 {\n font-size: ", ";\n line-height: ", ";\n }\n\n h2 {\n font-size: ", ";\n line-height: ", ";\n }\n\n h3 {\n font-size: ", ";\n line-height: ", ";\n }\n\n p,\n li,\n ol {\n font-size: ", ";\n line-height: ", ";\n }\n\n p {\n margin-top: 25px;\n margin-bottom: 25px;\n }\n\n ul {\n margin-top: 25px;\n margin-bottom: 25px;\n }\n\n a {\n color: ", ";\n font-size: ", ";\n line-height: ", ";\n }\n\n img {\n max-width: 100%;\n height: auto;\n margin-top: 30px;\n margin-bottom: 30px;\n }\n\n figure {\n margin: 0;\n max-width: 100%;\n\n img {\n max-width: 100%;\n height: auto;\n }\n }\n\n iframe,\n video {\n max-width: 100%;\n border: none;\n max-height: 404px;\n }\n\n blockquote {\n border-left: 4px solid ", ";\n margin: ", ";\n padding-bottom: ", ";\n padding-left: ", ";\n padding-right: ", ";\n padding-top: ", ";\n\n p {\n font-size: ", ";\n font-style: oblique;\n line-height: ", ";\n margin: 0;\n }\n }\n\n span {\n font-weight: inherit;\n }\n"], ["\n color: ", ";\n font-size: ", ";\n line-height: ", ";\n text-align: left;\n white-space: pre-wrap;\n width: 100%;\n word-break: break-word;\n\n & pre {\n white-space: pre-wrap;\n }\n\n div,\n p {\n overflow: hidden;\n }\n\n h1 {\n font-size: ", ";\n line-height: ", ";\n }\n\n h2 {\n font-size: ", ";\n line-height: ", ";\n }\n\n h3 {\n font-size: ", ";\n line-height: ", ";\n }\n\n p,\n li,\n ol {\n font-size: ", ";\n line-height: ", ";\n }\n\n p {\n margin-top: 25px;\n margin-bottom: 25px;\n }\n\n ul {\n margin-top: 25px;\n margin-bottom: 25px;\n }\n\n a {\n color: ", ";\n font-size: ", ";\n line-height: ", ";\n }\n\n img {\n max-width: 100%;\n height: auto;\n margin-top: 30px;\n margin-bottom: 30px;\n }\n\n figure {\n margin: 0;\n max-width: 100%;\n\n img {\n max-width: 100%;\n height: auto;\n }\n }\n\n iframe,\n video {\n max-width: 100%;\n border: none;\n max-height: 404px;\n }\n\n blockquote {\n border-left: 4px solid ", ";\n margin: ", ";\n padding-bottom: ", ";\n padding-left: ", ";\n padding-right: ", ";\n padding-top: ", ";\n\n p {\n font-size: ", ";\n font-style: oblique;\n line-height: ", ";\n margin: 0;\n }\n }\n\n span {\n font-weight: inherit;\n }\n"])), function (_a) {
10
- var theme = _a.theme;
11
- return theme.ui_temp_grey_01;
12
- }, function (_a) {
13
- var theme = _a.theme;
14
- return theme.desktopEditorFontSize.p;
15
- }, function (_a) {
16
- var theme = _a.theme;
17
- return theme.desktopEditorLineHeight.p;
18
- }, function (_a) {
19
- var theme = _a.theme;
20
- return theme.desktopEditorFontSize.h1;
21
- }, function (_a) {
22
- var theme = _a.theme;
23
- return theme.desktopEditorLineHeight.h1;
24
- }, function (_a) {
25
- var theme = _a.theme;
26
- return theme.desktopEditorFontSize.h2;
27
- }, function (_a) {
28
- var theme = _a.theme;
29
- return theme.desktopEditorLineHeight.h2;
30
- }, function (_a) {
31
- var theme = _a.theme;
32
- return theme.desktopEditorFontSize.h3;
33
- }, function (_a) {
34
- var theme = _a.theme;
35
- return theme.desktopEditorLineHeight.h3;
36
- }, function (_a) {
37
- var theme = _a.theme;
38
- return theme.desktopEditorFontSize.p;
39
- }, function (_a) {
40
- var theme = _a.theme;
41
- return theme.desktopEditorLineHeight.p;
42
- }, function (_a) {
43
- var theme = _a.theme;
44
- return theme.ui_papp_post_notice_link;
45
- }, function (_a) {
46
- var theme = _a.theme;
47
- return theme.desktopEditorFontSize.p;
48
- }, function (_a) {
49
- var theme = _a.theme;
50
- return theme.desktopEditorLineHeight.p;
51
- }, function (_a) {
52
- var theme = _a.theme;
53
- return theme.ui_temp_grey_03;
54
- }, function (_a) {
55
- var theme = _a.theme;
56
- return theme.spacing.spacingD;
57
- }, function (_a) {
58
- var theme = _a.theme;
59
- return theme.spacing.spacingA;
60
- }, function (_a) {
61
- var theme = _a.theme;
62
- return theme.spacing.spacingC;
63
- }, function (_a) {
64
- var theme = _a.theme;
65
- return theme.spacing.spacingA;
66
- }, function (_a) {
67
- var theme = _a.theme;
68
- return theme.spacing.spacingA;
69
- }, function (_a) {
70
- var theme = _a.theme;
71
- return theme.desktopEditorFontSize.p;
72
- }, function (_a) {
73
- var theme = _a.theme;
74
- return theme.desktopEditorLineHeight.p;
75
- });
76
- var templateObject_1;
@@ -1,8 +0,0 @@
1
- /// <reference types="react" />
2
- import type { LocalizedContentConfig } from '../../../common/types';
3
- export type LocalizedButtonProps = {
4
- localizedContentModalConfig: LocalizedContentConfig;
5
- state?: 'normal' | 'disabled' | undefined;
6
- };
7
- declare function LocalizedButton({ localizedContentModalConfig, state }: LocalizedButtonProps): JSX.Element;
8
- export default LocalizedButton;
@@ -1,44 +0,0 @@
1
- "use strict";
2
- var __assign = (this && this.__assign) || function () {
3
- __assign = Object.assign || function(t) {
4
- for (var s, i = 1, n = arguments.length; i < n; i++) {
5
- s = arguments[i];
6
- for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
7
- t[p] = s[p];
8
- }
9
- return t;
10
- };
11
- return __assign.apply(this, arguments);
12
- };
13
- Object.defineProperty(exports, "__esModule", { value: true });
14
- var jsx_runtime_1 = require("react/jsx-runtime");
15
- var react_1 = require("react");
16
- var panels_1 = require("../../panels");
17
- var IconButton_1 = require("../IconButton");
18
- function LocalizedButton(_a) {
19
- var localizedContentModalConfig = _a.localizedContentModalConfig, _b = _a.state, state = _b === void 0 ? 'normal' : _b;
20
- var _c = (0, react_1.useState)(false), isLocalizedContentModalOpen = _c[0], setIsLocalizedContentModalOpen = _c[1];
21
- var _d = (0, react_1.useState)(false), hasValues = _d[0], setHasValues = _d[1];
22
- var checkMultilingualValues = function () {
23
- try {
24
- var values = localizedContentModalConfig.initialValues || '{}';
25
- var hasValues_1 = Object.values(values).some(function (value) { return value && value.toString().trim() !== ''; });
26
- setHasValues(hasValues_1);
27
- }
28
- catch (_a) {
29
- setHasValues(false);
30
- }
31
- };
32
- // initialValues 변경될 때마다 체크
33
- (0, react_1.useEffect)(function () {
34
- checkMultilingualValues();
35
- }, [localizedContentModalConfig.initialValues]);
36
- var handleLanguageButtonClick = function () {
37
- setIsLocalizedContentModalOpen(true);
38
- };
39
- var handleLanguageModalClose = function () {
40
- setIsLocalizedContentModalOpen(false);
41
- };
42
- return ((0, jsx_runtime_1.jsxs)("div", { children: [(0, jsx_runtime_1.jsx)(IconButton_1.IconButton, { iconFillType: "line", iconName: "ic_translate", baseSize: "small", shapeType: "round", baseColorKey: "ui_cpnt_button_fill_base_default", iconColorKey: hasValues ? 'ui_cpnt_button_icon_primary' : 'ui_cpnt_icon_sys_grey_02', state: state, onClick: state === 'normal' ? handleLanguageButtonClick : undefined }), isLocalizedContentModalOpen && ((0, jsx_runtime_1.jsx)(panels_1.LocalizedContentModal, __assign({}, localizedContentModalConfig, { isOpen: isLocalizedContentModalOpen, onClose: handleLanguageModalClose })))] }));
43
- }
44
- exports.default = LocalizedButton;
@@ -1 +0,0 @@
1
- export { default as LocalizedButton } from './LocalizedButton';
@@ -1,8 +0,0 @@
1
- "use strict";
2
- var __importDefault = (this && this.__importDefault) || function (mod) {
3
- return (mod && mod.__esModule) ? mod : { "default": mod };
4
- };
5
- Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.LocalizedButton = void 0;
7
- var LocalizedButton_1 = require("./LocalizedButton");
8
- Object.defineProperty(exports, "LocalizedButton", { enumerable: true, get: function () { return __importDefault(LocalizedButton_1).default; } });
@@ -1,24 +0,0 @@
1
- /// <reference types="react" />
2
- import type { LanguageCode } from '../../../common/types';
3
- import type { RichTextEditorProps } from '../../components/RichTextEditor/RichTextEditor';
4
- export type RichEditorConfig = Omit<RichTextEditorProps, 'toolbar'> & {
5
- toolbar?: string[];
6
- };
7
- type LocalizedContentModalProps = {
8
- isOpen: boolean;
9
- size?: 'large' | 'medium' | 'small' | 'rlarge';
10
- textFieldLineType?: 'single' | 'multi' | 'auto' | 'tinyeditor';
11
- originalText?: string;
12
- initialValues?: {
13
- [key in LanguageCode]?: string;
14
- };
15
- visibleLanguages?: LanguageCode[];
16
- readonly?: boolean;
17
- richEditorConfig?: RichEditorConfig;
18
- onClose: () => void;
19
- onApply?: (values: {
20
- [key in LanguageCode]?: string;
21
- }) => void;
22
- };
23
- declare function LocalizedContentModal({ isOpen, size, textFieldLineType, originalText, initialValues, visibleLanguages, readonly, richEditorConfig, onClose, onApply }: LocalizedContentModalProps): JSX.Element | null;
24
- export default LocalizedContentModal;
@@ -1,81 +0,0 @@
1
- "use strict";
2
- var __makeTemplateObject = (this && this.__makeTemplateObject) || function (cooked, raw) {
3
- if (Object.defineProperty) { Object.defineProperty(cooked, "raw", { value: raw }); } else { cooked.raw = raw; }
4
- return cooked;
5
- };
6
- var __assign = (this && this.__assign) || function () {
7
- __assign = Object.assign || function(t) {
8
- for (var s, i = 1, n = arguments.length; i < n; i++) {
9
- s = arguments[i];
10
- for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
11
- t[p] = s[p];
12
- }
13
- return t;
14
- };
15
- return __assign.apply(this, arguments);
16
- };
17
- var __importDefault = (this && this.__importDefault) || function (mod) {
18
- return (mod && mod.__esModule) ? mod : { "default": mod };
19
- };
20
- Object.defineProperty(exports, "__esModule", { value: true });
21
- var jsx_runtime_1 = require("react/jsx-runtime");
22
- var react_1 = require("react");
23
- var react_hook_form_1 = require("react-hook-form");
24
- var react_i18next_1 = require("react-i18next");
25
- var editorContentStyle_1 = require("../../../common/styles/editorContentStyle");
26
- var components_1 = require("../../components");
27
- var components_2 = require("../../../hybrid/components");
28
- var styled_components_1 = __importDefault(require("styled-components"));
29
- var AnnotationSheet_1 = require("../AnnotationSheet");
30
- var DesktopBasicModal_1 = require("../DesktopBasicModal");
31
- var LANGUAGE_I18N_KEYS = {
32
- en: 'str_multilingual_en',
33
- ko: 'str_multilingual_ko',
34
- ja: 'str_multilingual_ja',
35
- zh: 'str_multilingual_zh_cn',
36
- 'zh-Hant': 'str_multilingual_zh_tw',
37
- fr: 'str_multilingual_fr',
38
- es: 'str_multilingual_es'
39
- };
40
- function LocalizedContentModal(_a) {
41
- var isOpen = _a.isOpen, _b = _a.size, size = _b === void 0 ? 'medium' : _b, textFieldLineType = _a.textFieldLineType, originalText = _a.originalText, initialValues = _a.initialValues, visibleLanguages = _a.visibleLanguages, readonly = _a.readonly, richEditorConfig = _a.richEditorConfig, onClose = _a.onClose, onApply = _a.onApply;
42
- var t = (0, react_i18next_1.useTranslation)().t;
43
- var methods = (0, react_hook_form_1.useForm)({
44
- defaultValues: initialValues
45
- });
46
- (0, react_1.useLayoutEffect)(function () {
47
- if (isOpen && initialValues) {
48
- methods.reset(initialValues);
49
- }
50
- }, [isOpen, initialValues]);
51
- var handleApply = function () {
52
- var formValues = methods.getValues();
53
- if (onApply) {
54
- onApply(formValues);
55
- }
56
- onClose();
57
- };
58
- var handleCancel = function () {
59
- onClose();
60
- };
61
- if (!isOpen)
62
- return null;
63
- return ((0, jsx_runtime_1.jsx)(DesktopBasicModal_1.DesktopBasicModal, __assign({ titleText: t('str_multilingual_settings'), btnMode: readonly ? 'mbtn_amount1' : 'mbtn_amount2', mBtn1Text: readonly ? t('str_confirm') : t('str_apply'), mBtn2Text: t('str_cancel'), size: size, onClickMBtn1: handleApply, onClickMBtn2: handleCancel }, { children: (0, jsx_runtime_1.jsxs)(react_hook_form_1.FormProvider, __assign({}, methods, { children: [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: 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" })] })), visibleLanguages === null || visibleLanguages === void 0 ? void 0 : visibleLanguages.map(function (languageCode, index) {
64
- 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" }), textFieldLineType === 'tinyeditor' ? (readonly ? ((0, jsx_runtime_1.jsx)(AnnotationSheet_1.AnnotationSheet, __assign({ width: "100%", height: "240px", backgroundColorTheme: "base3", shapeType: "round", radius: 16, paddingTop: "spacing_d", paddingRight: "spacing_d", paddingBottom: "spacing_d", paddingLeft: "spacing_d" }, { children: (0, jsx_runtime_1.jsx)(S_ReadonlyContent, { dangerouslySetInnerHTML: {
65
- __html: (initialValues === null || initialValues === void 0 ? void 0 : initialValues[languageCode]) || ''
66
- } }) }))) : ((0, jsx_runtime_1.jsx)(components_1.RichTextEditor, __assign({}, richEditorConfig, { onChange: function (value) { return methods.setValue(languageCode, value); }, defaultText: methods.getValues(languageCode), toolbar: (richEditorConfig === null || richEditorConfig === void 0 ? void 0 : richEditorConfig.toolbar) || [
67
- 'blocks',
68
- 'bold italic underline strikethrough',
69
- 'alignleft aligncenter alignright alignjustify',
70
- 'outdent indent',
71
- 'forecolor backcolor numlist bullist blockquote',
72
- 'link insertfile image media',
73
- 'undo redo',
74
- 'code'
75
- ] })))) : ((0, jsx_runtime_1.jsx)(components_1.TextField, { responsiveMode: "use", multiRows: textFieldLineType === 'multi' ? 5 : undefined, autoMaxRows: textFieldLineType === 'auto' ? 5 : undefined, autoMinRows: textFieldLineType === 'auto' ? 1 : undefined, name: languageCode, hintText: t('str_9071'), placeholder: "Input Text", textLineType: textFieldLineType, state: readonly ? 'disabled' : 'normal' })), index < ((visibleLanguages === null || visibleLanguages === void 0 ? void 0 : visibleLanguages.length) || 0) - 1 && (0, jsx_runtime_1.jsx)(components_2.Spacing, { size: "spacing_f" })] }, "".concat(languageCode, "_field")));
76
- })] })) })));
77
- }
78
- var S_LanguageField = styled_components_1.default.div(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n width: 100%;\n"], ["\n width: 100%;\n"])));
79
- var S_ReadonlyContent = styled_components_1.default.div(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n ", "\n height: 100%;\n overflow-y: auto;\n"], ["\n ", "\n height: 100%;\n overflow-y: auto;\n"])), editorContentStyle_1.editorContentStyle);
80
- exports.default = LocalizedContentModal;
81
- var templateObject_1, templateObject_2;
@@ -1 +0,0 @@
1
- export { default } from './LocalizedContentModal';