pds-dev-kit-web-test 2.5.260 → 2.5.262

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 (115) hide show
  1. package/dist/src/common/assets/icons/fill/BringToFrontArrow.d.ts +4 -0
  2. package/dist/src/common/assets/icons/fill/BringToFrontArrow.js +30 -0
  3. package/dist/src/common/assets/icons/fill/DesktopSync.d.ts +4 -0
  4. package/dist/src/common/assets/icons/fill/DesktopSync.js +30 -0
  5. package/dist/src/common/assets/icons/fill/MoveBackwardArrow.d.ts +4 -0
  6. package/dist/src/common/assets/icons/fill/MoveBackwardArrow.js +30 -0
  7. package/dist/src/common/assets/icons/fill/MoveForwardArrow.d.ts +4 -0
  8. package/dist/src/common/assets/icons/fill/MoveForwardArrow.js +30 -0
  9. package/dist/src/common/assets/icons/fill/SendToBackArrow.d.ts +4 -0
  10. package/dist/src/common/assets/icons/fill/SendToBackArrow.js +30 -0
  11. package/dist/src/common/assets/icons/fill/index.d.ts +5 -0
  12. package/dist/src/common/assets/icons/fill/index.js +11 -1
  13. package/dist/src/common/assets/icons/line/BringToFrontArrow.d.ts +4 -0
  14. package/dist/src/common/assets/icons/line/BringToFrontArrow.js +30 -0
  15. package/dist/src/common/assets/icons/line/DesktopSync.d.ts +4 -0
  16. package/dist/src/common/assets/icons/line/DesktopSync.js +30 -0
  17. package/dist/src/common/assets/icons/line/MoveBackwardArrow.d.ts +4 -0
  18. package/dist/src/common/assets/icons/line/MoveBackwardArrow.js +30 -0
  19. package/dist/src/common/assets/icons/line/MoveForwardArrow.d.ts +4 -0
  20. package/dist/src/common/assets/icons/line/MoveForwardArrow.js +30 -0
  21. package/dist/src/common/assets/icons/line/SendToBackArrow.d.ts +4 -0
  22. package/dist/src/common/assets/icons/line/SendToBackArrow.js +30 -0
  23. package/dist/src/common/assets/icons/line/index.d.ts +5 -0
  24. package/dist/src/common/assets/icons/line/index.js +11 -1
  25. package/dist/src/common/hooks/useTooltip.js +1 -1
  26. package/dist/src/common/styles/colorSet/PaletteColor_Dark.json +3 -1
  27. package/dist/src/common/styles/colorSet/PaletteColor_light.json +3 -1
  28. package/dist/src/common/styles/colorSet/SemanticColor.json +3 -1
  29. package/dist/src/common/styles/colorSet/UIColor.json +6 -2
  30. package/dist/src/common/styles/colorSet/index.d.ts +10 -0
  31. package/dist/src/common/styles/colorSet/ui-type.d.ts +4 -0
  32. package/dist/src/common/utils/SystemUIPositionGenerator/hoverTypeSystemUICssGenerator.js +1 -1
  33. package/dist/src/desktop/components/BasicButtonGroup/BasicButtonGroup.js +1 -1
  34. package/dist/src/desktop/components/Dropdown/Dropdown.js +6 -4
  35. package/dist/src/desktop/components/MainButton/MainButton.d.ts +1 -1
  36. package/dist/src/desktop/components/MainButton/MainButton.js +20 -6
  37. package/dist/src/desktop/components/UploadMainButton/UploadMainButton.d.ts +1 -1
  38. package/dist/src/desktop/components/UploadMainButton/UploadMainButton.js +21 -7
  39. package/dist/src/mobile/components/MainButton/MainButton.d.ts +1 -1
  40. package/dist/src/mobile/components/MainButton/MainButton.js +20 -6
  41. package/dist/src/mobile/components/UploadMainButton/UploadMainButton.d.ts +1 -1
  42. package/dist/src/mobile/components/UploadMainButton/UploadMainButton.js +20 -6
  43. package/dist/src/sub/DynamicLayout/components/EditModeSectionMatcher/EditModeSectionMatcher.js +0 -3
  44. package/dist/src/sub/DynamicLayout/components/EditModeSectionMatcher/SectionBox.js +1 -1
  45. package/dist/src/sub/DynamicLayout/components/Section/ErrorBoundary/ErrorBoundary.js +1 -12
  46. package/dist/src/sub/DynamicLayout/components/SectionMatcher/SectionMatcher.js +3 -5
  47. package/dist/src/sub/DynamicLayout/hooks/useCustomSectionShortcut/useCustomSectionShortcut.d.ts +1 -1
  48. package/dist/src/sub/DynamicLayout/hooks/useCustomSectionShortcut/useCustomSectionShortcut.js +1 -6
  49. package/dist/src/sub/DynamicLayout/mock_samplePage.js +132 -132
  50. package/dist/src/sub/DynamicLayout/pagesPreviewMock.d.ts +14038 -0
  51. package/dist/src/sub/DynamicLayout/pagesPreviewMock.js +35827 -0
  52. package/dist/src/sub/DynamicLayout/sectionActionTypes.d.ts +15 -64
  53. package/dist/src/sub/DynamicLayout/sections/CustomSection/CustomSection.d.ts +5 -0
  54. package/dist/src/sub/DynamicLayout/sections/CustomSection/CustomSection.js +200 -731
  55. package/dist/src/sub/DynamicLayout/sections/{FlexGridCustomSection.d.ts → CustomSection/FlexGridCustomSection.d.ts} +5 -1
  56. package/dist/src/sub/DynamicLayout/sections/{FlexGridCustomSection.js → CustomSection/FlexGridCustomSection.js} +88 -44
  57. package/dist/src/sub/DynamicLayout/sections/CustomSection/FlexGridItem.d.ts +1 -2
  58. package/dist/src/sub/DynamicLayout/sections/CustomSection/FlexGridItem.js +5 -8
  59. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/ComponentBlockMatcher.d.ts +0 -1
  60. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/ComponentBlockMatcher.js +0 -5
  61. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Button/Button.js +23 -25
  62. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Button/btnTypes.d.ts +76 -0
  63. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Button/btnTypes.js +2 -0
  64. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Text/Text.js +2 -16
  65. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Text/types.d.ts +38 -0
  66. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/Text/types.js +2 -0
  67. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/components/S_CB_Box.js +1 -1
  68. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/components/S_CB_BoxWithShadow.js +1 -1
  69. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/types.d.ts +1 -79
  70. package/dist/src/sub/DynamicLayout/sections/CustomSection/hooks/useGoogleFonts/getGoogleFonts.d.ts +4 -2
  71. package/dist/src/sub/DynamicLayout/sections/CustomSection/hooks/useGoogleFonts/getGoogleFonts.js +14 -3
  72. package/dist/src/sub/DynamicLayout/sections/CustomSection/hooks/useGoogleFonts/index.d.ts +1 -1
  73. package/dist/src/sub/DynamicLayout/sections/CustomSection/hooks/useGoogleFonts/index.js +3 -2
  74. package/dist/src/sub/DynamicLayout/sections/CustomSection/hooks/useGroupDrag/index.d.ts +1 -0
  75. package/dist/src/sub/DynamicLayout/sections/CustomSection/hooks/useGroupDrag/index.js +8 -0
  76. package/dist/src/sub/DynamicLayout/sections/CustomSection/hooks/useGroupDrag/useGroupDrag.d.ts +22 -0
  77. package/dist/src/sub/DynamicLayout/sections/CustomSection/hooks/useGroupDrag/useGroupDrag.js +273 -0
  78. package/dist/src/sub/DynamicLayout/sections/CustomSection/{newUtils/group.d.ts → hooks/useGroupDrag/utils.d.ts} +1 -4
  79. package/dist/src/sub/DynamicLayout/sections/CustomSection/{newUtils/group.js → hooks/useGroupDrag/utils.js} +1 -14
  80. package/dist/src/sub/DynamicLayout/sections/CustomSection/newUtils/colorUtil.d.ts +4 -4
  81. package/dist/src/sub/DynamicLayout/sections/CustomSection/newUtils/replaceUndefinedValues.js +1 -8
  82. package/dist/src/sub/DynamicLayout/sections/CustomSection/newUtils/textUtil.d.ts +6 -1
  83. package/dist/src/sub/DynamicLayout/sections/CustomSection/types.d.ts +2 -18
  84. package/dist/src/sub/DynamicLayout/sections/CustomSection/types.js +0 -2
  85. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/parsePlacement.d.ts +2 -5
  86. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/parsePlacement.js +9 -12
  87. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/stylePropParsers/parseStylePropTextSpec.d.ts +1 -1
  88. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/stylePropParsers/types.d.ts +1 -1
  89. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/stylePropParsers/types.js +1 -1
  90. package/dist/src/sub/DynamicLayout/sections/CustomSection/util/types.d.ts +5 -3
  91. package/dist/src/sub/DynamicLayout/types.d.ts +1 -45
  92. package/dist/src/sub/SandollFontKit/utils/appendSandollTagToHead.d.ts +1 -1
  93. package/dist/src/sub/SandollFontKit/utils/appendSandollTagToHead.js +11 -17
  94. package/package.json +3 -3
  95. package/release-note.md +2 -3
  96. package/dist/src/sub/DynamicLayout/CompositionRenderer/ComponentBlockMatcher.d.ts +0 -11
  97. package/dist/src/sub/DynamicLayout/CompositionRenderer/ComponentBlockMatcher.js +0 -56
  98. package/dist/src/sub/DynamicLayout/CompositionRenderer/Composition.d.ts +0 -9
  99. package/dist/src/sub/DynamicLayout/CompositionRenderer/Composition.js +0 -217
  100. package/dist/src/sub/DynamicLayout/CompositionRenderer/CompositionRenderer.d.ts +0 -6
  101. package/dist/src/sub/DynamicLayout/CompositionRenderer/CompositionRenderer.js +0 -27
  102. package/dist/src/sub/DynamicLayout/CompositionRenderer/FlexGridItem.d.ts +0 -12
  103. package/dist/src/sub/DynamicLayout/CompositionRenderer/FlexGridItem.js +0 -75
  104. package/dist/src/sub/DynamicLayout/gleStyles.d.ts +0 -3
  105. package/dist/src/sub/DynamicLayout/gleStyles.js +0 -19
  106. package/dist/src/sub/DynamicLayout/mocks.d.ts +0 -1111
  107. package/dist/src/sub/DynamicLayout/mocks.js +0 -4775
  108. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsCarousel/ContentsCarousel.d.ts +0 -8
  109. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsCarousel/ContentsCarousel.js +0 -12
  110. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/components/S_Backdrop.d.ts +0 -1
  111. package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/components/S_Backdrop.js +0 -13
  112. package/dist/src/sub/DynamicLayout/sections/CustomSection/newUtils/clsx.d.ts +0 -7
  113. package/dist/src/sub/DynamicLayout/sections/CustomSection/newUtils/clsx.js +0 -33
  114. package/dist/src/sub/DynamicLayout/sections/CustomSection/newUtils/fontSizeAdjustment.d.ts +0 -1
  115. package/dist/src/sub/DynamicLayout/sections/CustomSection/newUtils/fontSizeAdjustment.js +0 -333
@@ -1,9 +1,13 @@
1
1
  import React from 'react';
2
- import type { ISection } from '../types';
2
+ import type { ISection } from '../../types';
3
3
  import type { Layout } from 'publ-echo/dist/lib/GridLayoutEditor/types';
4
4
  export type LayoutsType = {
5
5
  sm: Layout;
6
6
  lg: Layout;
7
7
  };
8
+ export type CustomSectionImperativeHandleRef = {
9
+ selectCB: (cbId: number | 'group') => void;
10
+ selectCBInBulk: (cbIds: string[]) => void;
11
+ };
8
12
  declare const _default: React.MemoExoticComponent<React.ForwardRefExoticComponent<ISection & React.RefAttributes<unknown>>>;
9
13
  export default _default;
@@ -42,45 +42,89 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
42
42
  };
43
43
  Object.defineProperty(exports, "__esModule", { value: true });
44
44
  var jsx_runtime_1 = require("react/jsx-runtime");
45
- /* eslint-disable @typescript-eslint/no-unused-vars */
46
45
  var react_1 = __importStar(require("react"));
47
- var ErrorBoundary_1 = require("../../DynamicLayout/components/Section/ErrorBoundary");
48
- var dynamicLayoutContext_1 = require("../../DynamicLayout/dynamicLayoutContext");
46
+ var ErrorBoundary_1 = require("../../../DynamicLayout/components/Section/ErrorBoundary");
47
+ var dynamicLayoutContext_1 = require("../../../DynamicLayout/dynamicLayoutContext");
49
48
  var styled_components_1 = __importDefault(require("styled-components"));
50
- var components_1 = require("../components");
51
- var gleStyles_1 = require("../gleStyles");
52
- var FlexGridItem_1 = __importDefault(require("./CustomSection/FlexGridItem"));
53
- var useResizableObserver_1 = require("./CustomSection/hooks/useResizableObserver");
54
- var util_1 = require("./CustomSection/util");
55
- var parseSectionPadding_1 = __importDefault(require("./CustomSection/util/layoutPropParsers/parseSectionPadding"));
49
+ var components_1 = require("../../components");
50
+ var CustomSection_1 = require("./CustomSection");
51
+ var FlexGridItem_1 = __importDefault(require("./FlexGridItem"));
52
+ var useGroupDrag_1 = require("./hooks/useGroupDrag");
53
+ var useGroupDrag_2 = require("./hooks/useGroupDrag/useGroupDrag");
54
+ var utils_1 = require("./hooks/useGroupDrag/utils");
55
+ var useResizableObserver_1 = require("./hooks/useResizableObserver");
56
+ var util_1 = require("./util");
57
+ var parseSectionPadding_1 = __importDefault(require("./util/layoutPropParsers/parseSectionPadding"));
56
58
  var GRID_CELL_MIN = 24;
57
59
  var DESKTOP_GRID_COLS = 24;
58
60
  var MOBILE_GRID_COLS = 8;
59
61
  var GLE_MIN_WIDTH_DESKTOP_PX = "".concat(GRID_CELL_MIN * DESKTOP_GRID_COLS, "px");
60
62
  var GLE_MIN_WIDTH_MOBILE_PX = "".concat(GRID_CELL_MIN * MOBILE_GRID_COLS, "px");
61
- var FlexGridCustomSection = (0, react_1.forwardRef)(function CustomSection(props, ref) {
63
+ var CustomSection = (0, react_1.forwardRef)(function CustomSection(props, ref) {
62
64
  var _a;
63
65
  var _b = (0, react_1.useContext)(dynamicLayoutContext_1.dynamicLayoutContext), device = _b.device, editingSectionId = _b.editingSectionId, mode = _b.mode, shortcutKeyMode = _b.shortcutKeyMode, sectionActionHandler = _b.sectionActionHandler;
64
66
  var componentBlocks = props.componentBlocks, jsonProperties = props.jsonProperties;
65
- var _c = jsonProperties, _d = _c.data, CB_PLACEMENT_PROP_SECTION = _d.CB_PLACEMENT_PROP_SECTION, CB_LAYOUT_PROP_PADDING = _d.CB_LAYOUT_PROP_PADDING, zOrders = _c.zOrders;
67
+ var _c = jsonProperties.data, CB_PLACEMENT_PROP_SECTION = _c.CB_PLACEMENT_PROP_SECTION, CB_LAYOUT_PROP_PADDING = _c.CB_LAYOUT_PROP_PADDING;
66
68
  var containerRef = (0, react_1.useRef)(null);
67
69
  var size = (0, useResizableObserver_1.useResizeObserver)({ ref: containerRef, box: 'border-box' });
68
- var _e = (0, react_1.useState)(null), selectedCB = _e[0], setSelectedCB = _e[1];
70
+ var _d = (0, react_1.useState)(null), selectedCB = _d[0], setSelectedCB = _d[1];
69
71
  var gleRef = (0, react_1.useRef)(null);
70
72
  var isMobile = device === 'MOBILE';
71
73
  var isEditMode = mode === 'EDIT';
72
- // const layoutByDevice = device === 'DESKTOP' ? 'lg' : 'sm';
73
- // const [layouts] = useState<LayoutsType>(() => {
74
- // const { lg, sm } = parsePlacement(componentBlocks ?? []);
75
- // return {
76
- // lg,
77
- // sm
78
- // };
79
- // });
74
+ var layoutByDevice = device === 'DESKTOP' ? 'lg' : 'sm';
75
+ var _e = (0, react_1.useState)(function () {
76
+ var _a = (0, util_1.parsePlacement)(componentBlocks !== null && componentBlocks !== void 0 ? componentBlocks : []), lg = _a.lg, sm = _a.sm;
77
+ return {
78
+ lg: lg,
79
+ sm: sm
80
+ };
81
+ }), layouts = _e[0], setLayouts = _e[1];
82
+ var _f = (0, useGroupDrag_1.useGroupDrag)({
83
+ setLayouts: setLayouts,
84
+ device: device,
85
+ sectionActionHandler: sectionActionHandler
86
+ }), breakGroupCB = _f.breakGroupCB, makeAllInOneGroup = _f.makeAllInOneGroup, makeCollisionGroup = _f.makeCollisionGroup;
87
+ (0, react_1.useImperativeHandle)(ref, function () {
88
+ return {
89
+ selectCB: function (cbId) {
90
+ setSelectedCB(cbId);
91
+ },
92
+ selectCBInBulk: function (cbIds) {
93
+ var parsedLayouts = (0, util_1.parsePlacement)(componentBlocks !== null && componentBlocks !== void 0 ? componentBlocks : []);
94
+ setLayouts(function (prev) {
95
+ var _a;
96
+ var filteredLayout = (0, useGroupDrag_2.filterItemsById)(parsedLayouts[layoutByDevice], cbIds);
97
+ var newGroupLayout = (0, utils_1.getGroupForMultiple)(parsedLayouts[layoutByDevice].filter(function (each) { return cbIds.includes(each.i); }));
98
+ filteredLayout.push(newGroupLayout);
99
+ return __assign(__assign({}, prev), (_a = {}, _a[layoutByDevice] = filteredLayout, _a));
100
+ });
101
+ }
102
+ };
103
+ }, [componentBlocks]);
104
+ (0, react_1.useLayoutEffect)(function () {
105
+ var parsedLayouts = (0, util_1.parsePlacement)(componentBlocks !== null && componentBlocks !== void 0 ? componentBlocks : []);
106
+ setLayouts(function (prev) {
107
+ var _a;
108
+ var _b;
109
+ var group = (0, useGroupDrag_2.getGroupCB)(prev[layoutByDevice]);
110
+ var groupedCBIds = (_b = group === null || group === void 0 ? void 0 : group.childrenIds) !== null && _b !== void 0 ? _b : [];
111
+ var filteredLayout = (0, useGroupDrag_2.filterItemsById)(parsedLayouts[layoutByDevice], groupedCBIds);
112
+ if (group === null || group === void 0 ? void 0 : group.groupLayouts) {
113
+ var groupCbs = parsedLayouts[layoutByDevice].filter(function (each) {
114
+ return groupedCBIds.includes(each.i);
115
+ });
116
+ if (groupCbs.length > 0) {
117
+ var newGroupLayout = (0, utils_1.getGroupForMultiple)(groupCbs);
118
+ filteredLayout.push(newGroupLayout);
119
+ }
120
+ }
121
+ return __assign(__assign({}, prev), (_a = {}, _a[layoutByDevice] = filteredLayout, _a));
122
+ });
123
+ }, [componentBlocks, useGroupDrag_2.getGroupCB, layoutByDevice]);
80
124
  (0, react_1.useEffect)(function () {
81
125
  if (editingSectionId !== props.id) {
82
126
  setSelectedCB(null);
83
- // breakGroupCB();
127
+ breakGroupCB();
84
128
  }
85
129
  }, [editingSectionId]);
86
130
  // NOTE: 추후에 event를 외부에서 전달받게하거나, 아예 상태를 끌어올리거나 해야합니다.
@@ -96,38 +140,38 @@ var FlexGridCustomSection = (0, react_1.forwardRef)(function CustomSection(props
96
140
  setSelectedCB(componentBlocks[0].id);
97
141
  return;
98
142
  }
99
- // makeAllInOneGroup();
143
+ makeAllInOneGroup();
100
144
  return;
101
145
  }
102
146
  if (shortcutKeyMode === 'MANUAL_BULK_BREAK') {
103
- // breakGroupCB();
147
+ breakGroupCB();
104
148
  setSelectedCB(null);
105
149
  return;
106
150
  }
107
- }, [shortcutKeyMode, setSelectedCB]);
151
+ }, [shortcutKeyMode, setSelectedCB, breakGroupCB]);
108
152
  (0, react_1.useLayoutEffect)(function () {
109
153
  if (props.id !== editingSectionId) {
110
154
  return;
111
155
  }
112
156
  if (shortcutKeyMode === 'MANUAL_COLLISION_SELECT') {
113
- if (!selectedCB || selectedCB === 'BULK') {
157
+ if (!selectedCB || selectedCB === 'group') {
114
158
  return;
115
159
  }
116
- // makeCollisionGroup(selectedCB);
117
- // sectionActionHandler &&
118
- // sectionActionHandler({
119
- // type: '@CUSTOMSECTION/BLOCK_CLICKED',
120
- // payload: {
121
- // block:
122
- // }
123
- // });
124
- setSelectedCB('BULK');
125
- }
126
- }, [selectedCB, shortcutKeyMode, sectionActionHandler, setSelectedCB]);
127
- var _f = (0, util_1.parseCustomSectionPlacement)({
160
+ makeCollisionGroup(selectedCB);
161
+ sectionActionHandler &&
162
+ sectionActionHandler({
163
+ type: '@CUSTOMSECTION/CB_CLICKED',
164
+ payload: {
165
+ id: 'group'
166
+ }
167
+ });
168
+ setSelectedCB('group');
169
+ }
170
+ }, [selectedCB, shortcutKeyMode, makeCollisionGroup, sectionActionHandler, setSelectedCB]);
171
+ var _g = (0, util_1.parseCustomSectionPlacement)({
128
172
  isMobile: isMobile,
129
173
  customSectionProps: CB_PLACEMENT_PROP_SECTION
130
- }), width = _f.width, minHeight = _f.minHeight, isFullWidth = _f.isFullWidth;
174
+ }), width = _g.width, minHeight = _g.minHeight, isFullWidth = _g.isFullWidth;
131
175
  var customSectionStyles = {
132
176
  minHeight: "".concat(minHeight, "vh"),
133
177
  width: '100%',
@@ -137,6 +181,9 @@ var FlexGridCustomSection = (0, react_1.forwardRef)(function CustomSection(props
137
181
  if (!isEditMode) {
138
182
  return;
139
183
  }
184
+ if ((0, useGroupDrag_2.getGroupCB)(layouts[layoutByDevice])) {
185
+ breakGroupCB();
186
+ }
140
187
  setSelectedCB(null);
141
188
  sectionActionHandler &&
142
189
  sectionActionHandler({
@@ -184,7 +231,7 @@ var FlexGridCustomSection = (0, react_1.forwardRef)(function CustomSection(props
184
231
  }
185
232
  return 16;
186
233
  })();
187
- return ((0, jsx_runtime_1.jsx)(ErrorBoundary_1.ErrorBoundary, { children: (0, jsx_runtime_1.jsx)(gleStyles_1.S_gleStyles, { children: (0, jsx_runtime_1.jsx)(S_SectionWrapper, __assign({ ref: gleRef, "x-dlayout-section-type": "NO_NAME", onClick: onClickSection }, { children: (0, jsx_runtime_1.jsx)(components_1.CustomSection, __assign({}, props, { isMobile: isMobile, overrideStyles: {
234
+ return ((0, jsx_runtime_1.jsx)(ErrorBoundary_1.ErrorBoundary, { children: (0, jsx_runtime_1.jsx)(CustomSection_1.S_gleStyles, { children: (0, jsx_runtime_1.jsx)(S_SectionWrapper, __assign({ ref: gleRef, "x-dlayout-section-type": "NO_NAME", onClick: onClickSection }, { children: (0, jsx_runtime_1.jsx)(components_1.CustomSection, __assign({}, props, { isMobile: isMobile, overrideStyles: {
188
235
  minHeight: customSectionStyles.minHeight,
189
236
  paddingTop: padding.top,
190
237
  paddingBottom: padding.bottom,
@@ -195,14 +242,11 @@ var FlexGridCustomSection = (0, react_1.forwardRef)(function CustomSection(props
195
242
  maxWidth: customSectionStyles.maxWidth,
196
243
  minWidth: isMobile ? GLE_MIN_WIDTH_MOBILE_PX : GLE_MIN_WIDTH_DESKTOP_PX,
197
244
  fontSize: "".concat(baseFontSize, "px")
198
- } }, { children: (_a = props.componentBlocks) === null || _a === void 0 ? void 0 : _a.map(function (cb, index) {
199
- var _a;
200
- return ((0, jsx_runtime_1.jsx)(ErrorBoundary_1.ErrorBoundary, { children: (0, jsx_runtime_1.jsx)(FlexGridItem_1.default, { cb: cb, index: index, device: device, rowHeight: rowHeight, zIndex: (_a = zOrders === null || zOrders === void 0 ? void 0 : zOrders[device === 'DESKTOP' ? 'desktop' : 'mobile'][cb.id]) !== null && _a !== void 0 ? _a : 0 }) }, cb.id));
201
- }) })) })) })) }) }));
245
+ } }, { children: (_a = props.componentBlocks) === null || _a === void 0 ? void 0 : _a.map(function (cb, index) { return ((0, jsx_runtime_1.jsx)(ErrorBoundary_1.ErrorBoundary, { children: (0, jsx_runtime_1.jsx)(FlexGridItem_1.default, { cb: cb, index: index, device: device, rowHeight: rowHeight }) }, cb.id)); }) })) })) })) }) }));
202
246
  });
203
247
  var GridContainer = styled_components_1.default.div(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n display: grid; /* Space between grid items */\n gap: 10px;\n grid-auto-rows: minmax(", ", auto);\n grid-template-columns: repeat(", ", 1fr);\n grid-template-rows: repeat(\n ", ",\n minmax(", ", auto)\n );\n padding: 10px 10px;\n\n * {\n box-sizing: border-box;\n }\n"], ["\n display: grid; /* Space between grid items */\n gap: 10px;\n grid-auto-rows: minmax(", ", auto);\n grid-template-columns: repeat(", ", 1fr);\n grid-template-rows: repeat(\n ", ",\n minmax(", ", auto)\n );\n padding: 10px 10px;\n\n * {\n box-sizing: border-box;\n }\n"])), function (props) { return "".concat(props.rowHeight, "px"); }, function (props) { return props.cols; }, function (props) { return props.sectionRow; }, function (props) { return "".concat(props.rowHeight, "px"); });
204
248
  var S_SectionWrapper = styled_components_1.default.div(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n position: relative;\n"], ["\n position: relative;\n"])));
205
- exports.default = react_1.default.memo(FlexGridCustomSection);
249
+ exports.default = react_1.default.memo(CustomSection);
206
250
  function getDefensiveFontSize(device, width) {
207
251
  if (device === 'MOBILE') {
208
252
  return width * (0.0000868 * width + 0.0202);
@@ -6,7 +6,6 @@ type Props = {
6
6
  index: number;
7
7
  device: Device;
8
8
  rowHeight: number;
9
- zIndex: number;
10
9
  };
11
- declare function FlexGridItem({ cb, index, device, rowHeight, zIndex }: Props): JSX.Element;
10
+ declare function FlexGridItem({ cb, index, device, rowHeight }: Props): JSX.Element;
12
11
  export default FlexGridItem;
@@ -23,21 +23,18 @@ var styled_components_1 = __importDefault(require("styled-components"));
23
23
  var ComponentBlockMatcher_1 = __importDefault(require("./components/ComponentBlock/ComponentBlockMatcher"));
24
24
  var gap = 10;
25
25
  function FlexGridItem(_a) {
26
- var cb = _a.cb, index = _a.index, device = _a.device, rowHeight = _a.rowHeight, zIndex = _a.zIndex;
26
+ var cb = _a.cb, index = _a.index, device = _a.device, rowHeight = _a.rowHeight;
27
27
  // eslint-disable-next-line @typescript-eslint/no-unused-vars
28
28
  var defaultHeight = getMaxHeight(cb.jsonProperties.data.CB_PLACEMENT_PROP_PLACEMENT, device, rowHeight);
29
29
  var gridArea = getGridAreaFromCB(cb.jsonProperties.data.CB_PLACEMENT_PROP_PLACEMENT, device);
30
- // const zIndex =
31
- // device === 'DESKTOP'
32
- // ? cb.jsonProperties.data.CB_PLACEMENT_PROP_PLACEMENT.CB_PLACEMENT_PROP_PLACEMENT_SPEC_ZINDEX
33
- // : cb.jsonProperties.data.CB_PLACEMENT_PROP_PLACEMENT[
34
- // 'CB_PLACEMENT_PROP_PLACEMENT_SPEC_ZINDEX:MOBILE'
35
- // ];
30
+ var zIndex = device === 'DESKTOP'
31
+ ? cb.jsonProperties.data.CB_PLACEMENT_PROP_PLACEMENT.CB_PLACEMENT_PROP_PLACEMENT_SPEC_ZINDEX
32
+ : cb.jsonProperties.data.CB_PLACEMENT_PROP_PLACEMENT['CB_PLACEMENT_PROP_PLACEMENT_SPEC_ZINDEX:MOBILE'];
36
33
  return ((0, jsx_runtime_1.jsx)(GridItem, __assign({ style: {
37
34
  zIndex: zIndex,
38
35
  gridArea: gridArea
39
36
  // maxHeight: cb.componentBlockCode !== CB_ALL_CODES.CB_TEXT ? defaultHeight : undefined
40
- } }, { children: (0, jsx_runtime_1.jsx)(ComponentBlockMatcher_1.default, { rowHeight: rowHeight, cbProps: cb, device: device, index: index }) })));
37
+ } }, { children: (0, jsx_runtime_1.jsx)(ComponentBlockMatcher_1.default, { cbProps: cb, device: device, index: index }) })));
41
38
  }
42
39
  var GridItem = styled_components_1.default.div(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n height: auto;\n word-break: break-word;\n"], ["\n height: auto;\n word-break: break-word;\n"])));
43
40
  function getMaxHeight(props, device, rowHeight) {
@@ -5,7 +5,6 @@ type Props = {
5
5
  cbProps: ComponentBlock;
6
6
  device: Device;
7
7
  index: number;
8
- rowHeight: number;
9
8
  };
10
9
  export default function ComponentBlockMatcher({ cbProps, device, index }: Props): JSX.Element;
11
10
  export {};
@@ -19,7 +19,6 @@ require("react");
19
19
  var newUtils_1 = require("../../newUtils");
20
20
  var types_1 = require("../../types");
21
21
  var Button_1 = __importDefault(require("./componentBlocks/Button/Button"));
22
- var ContentsCarousel_1 = __importDefault(require("./componentBlocks/ContentsCarousel/ContentsCarousel"));
23
22
  var Divider_1 = __importDefault(require("./componentBlocks/Divider/Divider"));
24
23
  var Embed_1 = __importDefault(require("./componentBlocks/Embed/Embed"));
25
24
  var Image_1 = __importDefault(require("./componentBlocks/Image/Image"));
@@ -48,10 +47,6 @@ function ComponentBlockMatcher(_a) {
48
47
  return (0, jsx_runtime_1.jsx)(Youtube_1.Youtube, __assign({}, propsWithValue, { index: index }));
49
48
  case types_1.CB_ALL_CODES.CB_EMBED:
50
49
  return (0, jsx_runtime_1.jsx)(Embed_1.default, __assign({}, propsWithValue, { index: index }));
51
- case types_1.CB_ALL_CODES.CB_CONTENTS_CAROUSEL: {
52
- var compositions = cbProps.compositions;
53
- return ((0, jsx_runtime_1.jsx)(ContentsCarousel_1.default, __assign({}, propsWithValue, { compositions: compositions, index: index })));
54
- }
55
50
  default:
56
51
  return (0, jsx_runtime_1.jsx)("div", { children: "Error: not supported CB" });
57
52
  }
@@ -40,18 +40,18 @@ var S_HiddenCover_1 = require("../components/S_HiddenCover");
40
40
  var useCLINK_1 = __importDefault(require("../hooks/useCLINK"));
41
41
  function Button(props) {
42
42
  var _a = (0, react_1.useContext)(DynamicLayout_1.dynamicLayoutContext), device = _a.device, mode = _a.mode;
43
- var index = props.index, CB_STYLE_PROP_COLOR = props.CB_STYLE_PROP_COLOR, _b = props.CB_CONTENT_PROP_CLINK, CB_CONTENT_PROP_CLINK_SPEC_SRC = _b.CB_CONTENT_PROP_CLINK_SPEC_SRC, CB_CONTENT_PROP_CLINK_SPEC_TYPE = _b.CB_CONTENT_PROP_CLINK_SPEC_TYPE, CB_CONTENT_PROP_CLINK_SPEC_NEWTAB = _b.CB_CONTENT_PROP_CLINK_SPEC_NEWTAB, CB_CONTENT_PROP_CLINK_SPEC_INTERNALSRC = _b.CB_CONTENT_PROP_CLINK_SPEC_INTERNALSRC, CB_STYLE_PROP_SHADOW = props.CB_STYLE_PROP_SHADOW, CB_EFFECT_PROP_ENTANIM = props.CB_EFFECT_PROP_ENTANIM;
43
+ var index = props.index, CB_STYLE_PROP_BTNCOLOR = props.CB_STYLE_PROP_BTNCOLOR, _b = props.CB_CONTENT_PROP_CLINK, CB_CONTENT_PROP_CLINK_SPEC_SRC = _b.CB_CONTENT_PROP_CLINK_SPEC_SRC, CB_CONTENT_PROP_CLINK_SPEC_TYPE = _b.CB_CONTENT_PROP_CLINK_SPEC_TYPE, CB_CONTENT_PROP_CLINK_SPEC_NEWTAB = _b.CB_CONTENT_PROP_CLINK_SPEC_NEWTAB, CB_CONTENT_PROP_CLINK_SPEC_INTERNALSRC = _b.CB_CONTENT_PROP_CLINK_SPEC_INTERNALSRC, CB_STYLE_PROP_SHADOW = props.CB_STYLE_PROP_SHADOW, CB_EFFECT_PROP_ENTANIM = props.CB_EFFECT_PROP_ENTANIM;
44
44
  var _c = (0, useCLINK_1.default)({
45
45
  src: CB_CONTENT_PROP_CLINK_SPEC_SRC,
46
46
  type: CB_CONTENT_PROP_CLINK_SPEC_TYPE,
47
47
  openNewTab: CB_CONTENT_PROP_CLINK_SPEC_NEWTAB,
48
48
  internalSrc: String(CB_CONTENT_PROP_CLINK_SPEC_INTERNALSRC)
49
49
  }), onClickCLINK = _c.onClickCLINK, CLINKCursor = _c.CLINKCursor;
50
- var _d = getBTNStyles(props.CB_STYLE_PROP_TEXT, device), btnTextStyle = _d.style, btnTextHoverStyle = _d.hoverStyle;
51
- var _e = getBTNColorStyles(CB_STYLE_PROP_COLOR, device), btnColorStyle = _e.style, btnColorHoverStyle = _e.hoverStyle;
50
+ var _d = getBTNStyles(props.CB_STYLE_PROP_BTNTEXT, device), btnTextStyle = _d.style, btnTextHoverStyle = _d.hoverStyle;
51
+ var _e = getBTNColorStyles(CB_STYLE_PROP_BTNCOLOR, device), btnColorStyle = _e.style, btnColorHoverStyle = _e.hoverStyle;
52
52
  var _f = (0, util_1.parseProperties)(props, device), propsStyle = _f.style, propsHoverStyle = _f.hoverStyle, _g = _f.layout, paddingLeft = _g.paddingLeft, paddingRight = _g.paddingRight, paddingTop = _g.paddingTop, paddingBottom = _g.paddingBottom, layoutStyle = __rest(_g, ["paddingLeft", "paddingRight", "paddingTop", "paddingBottom"]), effect = _f.effect;
53
53
  var isEditModeAndHidden = propsStyle.visibility === 'hidden' && mode === 'EDIT';
54
- var googleFonts = (0, useGoogleFonts_1.getGoogleFontsFromTextSpecCode)(props.CB_STYLE_PROP_TEXT, device === 'MOBILE');
54
+ var googleFonts = (0, useGoogleFonts_1.getGoogleFontsFromBtnCB)(props.CB_STYLE_PROP_BTNTEXT, device === 'MOBILE');
55
55
  (0, useGoogleFonts_1.useGoogleFonts)({ fonts: googleFonts });
56
56
  if (mode === 'EDIT') {
57
57
  propsStyle.visibility = 'visible';
@@ -72,34 +72,32 @@ function Button(props) {
72
72
  paddingRight: paddingRight,
73
73
  paddingBottom: paddingBottom,
74
74
  paddingTop: paddingTop
75
- } }, { children: (0, jsx_runtime_1.jsx)(S_CB_BoxWithShadow_1.S_CB_BoxWithShadow, __assign({ onMouseLeave: function (e) {
76
- e.currentTarget.classList.remove('hovered');
77
- }, className: "cb-layout-box", normalStyle: __assign(__assign(__assign(__assign(__assign(__assign({}, btnTextStyle), propsStyle), layoutStyle), effectCssProperties), btnColorStyle), { whiteSpace: 'pre-wrap', wordBreak: 'break-word', cursor: CLINKCursor }), hoverStyle: __assign(__assign(__assign(__assign({}, btnTextHoverStyle), propsHoverStyle), btnColorHoverStyle), { whiteSpace: 'pre-wrap', wordBreak: 'break-word' }), cbStylePropsShadowSpecs: CB_STYLE_PROP_SHADOW, device: device, onClick: onClickCLINK }, { children: props.CB_CONTENT_PROP_TEXT.CB_CONTENT_PROP_TEXT_SPEC_TEXT })) }))] }));
75
+ } }, { children: (0, jsx_runtime_1.jsx)(S_CB_BoxWithShadow_1.S_CB_BoxWithShadow, __assign({ className: "cb-layout-box", normalStyle: __assign(__assign(__assign(__assign(__assign(__assign({}, btnTextStyle), propsStyle), layoutStyle), effectCssProperties), btnColorStyle), { whiteSpace: 'pre-wrap', wordBreak: 'break-word', cursor: CLINKCursor }), hoverStyle: __assign(__assign(__assign(__assign({}, btnTextHoverStyle), propsHoverStyle), btnColorHoverStyle), { whiteSpace: 'pre-wrap', wordBreak: 'break-word' }), cbStylePropsShadowSpecs: CB_STYLE_PROP_SHADOW, device: device, onClick: onClickCLINK }, { children: props.CB_CONTENT_PROP_TEXT.CB_CONTENT_PROP_TEXT_SPEC_TEXT })) }))] }));
78
76
  }
79
77
  function getBTNStyles(props, device) {
80
78
  var availableSpecCodes = [
81
- 'CB_STYLE_PROP_TEXT_SPEC_TYPEFACE',
82
- 'CB_STYLE_PROP_TEXT_SPEC_WEIGHT',
83
- 'CB_STYLE_PROP_TEXT_SPEC_SIZE',
84
- 'CB_STYLE_PROP_TEXT_SPEC_LINEHEIGHT',
85
- 'CB_STYLE_PROP_TEXT_SPEC_LETTERSPACING',
86
- 'CB_STYLE_PROP_TEXT_SPEC_COLOR',
87
- 'CB_STYLE_PROP_TEXT_SPEC_HORIZONTAL',
88
- 'CB_STYLE_PROP_TEXT_SPEC_VERTICAL'
79
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_TYPEFACE',
80
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_WEIGHT',
81
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_SIZE',
82
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_LINEHEIGHT',
83
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_LETTERSPACING',
84
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_COLOR',
85
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_HORIZONTAL',
86
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_VERTICAL'
89
87
  ];
90
- return (0, newUtils_1.parseStyleTextToCSSProp)({ availableSpecCodes: availableSpecCodes, props: props, device: device, propKey: 'TEXT' });
88
+ return (0, newUtils_1.parseStyleTextToCSSProp)({ availableSpecCodes: availableSpecCodes, props: props, device: device, propKey: 'BTNTEXT' });
91
89
  }
92
90
  function getBTNColorStyles(props, device) {
93
91
  var availableSpecCodes = [
94
- 'CB_STYLE_PROP_COLOR_SPEC_ANGLE',
95
- 'CB_STYLE_PROP_COLOR_SPEC_COLOR',
96
- 'CB_STYLE_PROP_COLOR_SPEC_ENDCOLOR',
97
- 'CB_STYLE_PROP_COLOR_SPEC_ENDLOC',
98
- 'CB_STYLE_PROP_COLOR_SPEC_GRADIENT',
99
- 'CB_STYLE_PROP_COLOR_SPEC_STARTCOLOR',
100
- 'CB_STYLE_PROP_COLOR_SPEC_STARTLOC',
101
- 'CB_STYLE_PROP_COLOR_SPEC_TYPE'
92
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_ANGLE',
93
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_COLOR',
94
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_ENDCOLOR',
95
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_ENDLOC',
96
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_GRADIENT',
97
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_STARTCOLOR',
98
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_STARTLOC',
99
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_TYPE'
102
100
  ];
103
- return (0, colorUtil_1.parseStyleColorToCSSProp)({ availableSpecCodes: availableSpecCodes, props: props, propKey: 'COLOR', device: device });
101
+ return (0, colorUtil_1.parseStyleColorToCSSProp)({ availableSpecCodes: availableSpecCodes, props: props, propKey: 'BTNCOLOR', device: device });
104
102
  }
105
103
  exports.default = Button;
@@ -0,0 +1,76 @@
1
+ import type { ENUM_STRING, NUMBER_INTEGER, STRING_8DIGIT_HEX } from '../../../../util/types';
2
+ export type BtnPropsKeys = keyof CB_BTNTEXT_STYLE_PROPS;
3
+ export type CB_BTNTEXT_STYLE_PROPS = {
4
+ CB_STYLE_PROP_BTNTEXT_SPEC_TYPEFACE: ENUM_STRING;
5
+ CB_STYLE_PROP_BTNTEXT_SPEC_WEIGHT: NUMBER_INTEGER;
6
+ CB_STYLE_PROP_BTNTEXT_SPEC_SIZE: NUMBER_INTEGER;
7
+ CB_STYLE_PROP_BTNTEXT_SPEC_LINEHEIGHT: NUMBER_INTEGER;
8
+ CB_STYLE_PROP_BTNTEXT_SPEC_LETTERSPACING: NUMBER_INTEGER;
9
+ CB_STYLE_PROP_BTNTEXT_SPEC_COLOR: STRING_8DIGIT_HEX;
10
+ CB_STYLE_PROP_BTNTEXT_SPEC_HORIZONTAL: ENUM_STRING;
11
+ CB_STYLE_PROP_BTNTEXT_SPEC_VERTICAL: ENUM_STRING;
12
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_TYPEFACE:HOVER': ENUM_STRING | null | undefined;
13
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_TYPEFACE:MOBILE': ENUM_STRING | null | undefined;
14
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_TYPEFACE:MOBILE:HOVER': ENUM_STRING | null | undefined;
15
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_WEIGHT:HOVER': NUMBER_INTEGER | null | undefined;
16
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_WEIGHT:MOBILE': NUMBER_INTEGER | null | undefined;
17
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_WEIGHT:MOBILE:HOVER': NUMBER_INTEGER | null | undefined;
18
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_SIZE:HOVER': NUMBER_INTEGER | null | undefined;
19
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_SIZE:MOBILE': NUMBER_INTEGER | null | undefined;
20
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_SIZE:MOBILE:HOVER': NUMBER_INTEGER | null | undefined;
21
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_LINEHEIGHT:HOVER': NUMBER_INTEGER | null | undefined;
22
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_LINEHEIGHT:MOBILE': NUMBER_INTEGER | null | undefined;
23
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_LINEHEIGHT:MOBILE:HOVER': NUMBER_INTEGER | null | undefined;
24
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_LETTERSPACING:HOVER': NUMBER_INTEGER | null | undefined;
25
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_LETTERSPACING:MOBILE': NUMBER_INTEGER | null | undefined;
26
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_LETTERSPACING:MOBILE:HOVER': NUMBER_INTEGER | null | undefined;
27
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_COLOR:HOVER': STRING_8DIGIT_HEX | null | undefined;
28
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_COLOR:MOBILE': STRING_8DIGIT_HEX | null | undefined;
29
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_COLOR:MOBILE:HOVER': STRING_8DIGIT_HEX | null | undefined;
30
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_HORIZONTAL:HOVER': ENUM_STRING | null | undefined;
31
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_HORIZONTAL:MOBILE': ENUM_STRING | null | undefined;
32
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_HORIZONTAL:MOBILE:HOVER': ENUM_STRING | null | undefined;
33
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_VERTICAL:HOVER': ENUM_STRING | null | undefined;
34
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_VERTICAL:MOBILE': ENUM_STRING | null | undefined;
35
+ 'CB_STYLE_PROP_BTNTEXT_SPEC_VERTICAL:MOBILE:HOVER': ENUM_STRING | null | undefined;
36
+ };
37
+ export type CB_STYLE_PROP_BTNCOLOR_ENUM_GRADIENT = 'LINEAR' | 'RADIAL';
38
+ export type CB_STYLE_PROP_BTNCOLOR_ENUM_TYPE = 'NONE' | 'SOLID' | 'GRADIENT';
39
+ export type CB_STYLE_PROP_BTNCOLOR_SPECS_BASE = {
40
+ CB_STYLE_PROP_BTNCOLOR_SPEC_ANGLE: NUMBER_INTEGER;
41
+ CB_STYLE_PROP_BTNCOLOR_SPEC_COLOR: ENUM_STRING;
42
+ CB_STYLE_PROP_BTNCOLOR_SPEC_ENDCOLOR: ENUM_STRING;
43
+ CB_STYLE_PROP_BTNCOLOR_SPEC_ENDLOC: NUMBER_INTEGER;
44
+ CB_STYLE_PROP_BTNCOLOR_SPEC_GRADIENT: CB_STYLE_PROP_BTNCOLOR_ENUM_GRADIENT;
45
+ CB_STYLE_PROP_BTNCOLOR_SPEC_STARTCOLOR: ENUM_STRING;
46
+ CB_STYLE_PROP_BTNCOLOR_SPEC_STARTLOC: NUMBER_INTEGER;
47
+ CB_STYLE_PROP_BTNCOLOR_SPEC_TYPE: CB_STYLE_PROP_BTNCOLOR_ENUM_TYPE;
48
+ };
49
+ export type CB_STYLE_PROP_BTNCOLOR_SPECS = CB_STYLE_PROP_BTNCOLOR_SPECS_BASE & {
50
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_ANGLE:HOVER': NUMBER_INTEGER | null | undefined;
51
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_ANGLE:MOBILE': NUMBER_INTEGER | null | undefined;
52
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_ANGLE:MOBILE:HOVER': NUMBER_INTEGER | null | undefined;
53
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_COLOR:HOVER': ENUM_STRING | null | undefined;
54
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_COLOR:MOBILE': ENUM_STRING | null | undefined;
55
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_COLOR:MOBILE:HOVER': ENUM_STRING | null | undefined;
56
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_ENDCOLOR:HOVER': ENUM_STRING | null | undefined;
57
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_ENDCOLOR:MOBILE': ENUM_STRING | null | undefined;
58
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_ENDCOLOR:MOBILE:HOVER': ENUM_STRING | null | undefined;
59
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_ENDLOC:HOVER': NUMBER_INTEGER | null | undefined;
60
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_ENDLOC:MOBILE': NUMBER_INTEGER | null | undefined;
61
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_ENDLOC:MOBILE:HOVER': NUMBER_INTEGER | null | undefined;
62
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_GRADIENT:HOVER': CB_STYLE_PROP_BTNCOLOR_ENUM_GRADIENT | null | undefined;
63
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_GRADIENT:MOBILE': CB_STYLE_PROP_BTNCOLOR_ENUM_GRADIENT | null | undefined;
64
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_GRADIENT:MOBILE:HOVER': CB_STYLE_PROP_BTNCOLOR_ENUM_GRADIENT | null | undefined;
65
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_STARTCOLOR:HOVER': ENUM_STRING | null | undefined;
66
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_STARTCOLOR:MOBILE': ENUM_STRING | null | undefined;
67
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_STARTCOLOR:MOBILE:HOVER': ENUM_STRING | null | undefined;
68
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_STARTLOC:HOVER': NUMBER_INTEGER | null | undefined;
69
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_STARTLOC:MOBILE': NUMBER_INTEGER | null | undefined;
70
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_STARTLOC:MOBILE:HOVER': NUMBER_INTEGER | null | undefined;
71
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_TYPE:HOVER': CB_STYLE_PROP_BTNCOLOR_ENUM_TYPE | null | undefined;
72
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_TYPE:MOBILE': CB_STYLE_PROP_BTNCOLOR_ENUM_TYPE | null | undefined;
73
+ 'CB_STYLE_PROP_BTNCOLOR_SPEC_TYPE:MOBILE:HOVER': CB_STYLE_PROP_BTNCOLOR_ENUM_TYPE | null | undefined;
74
+ };
75
+ export type BtnColorPropsKeys = keyof CB_STYLE_PROP_BTNCOLOR_SPECS;
76
+ export type BTNColorValueSetType = Partial<Record<keyof CB_STYLE_PROP_BTNCOLOR_SPECS, CB_STYLE_PROP_BTNCOLOR_ENUM_GRADIENT | NUMBER_INTEGER | ENUM_STRING | undefined>>;
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -39,7 +39,7 @@ function Text(props) {
39
39
  var _d = getTextStyles(props.CB_STYLE_PROP_TEXT, device), textStyle = _d.style, textHoverStyle = _d.hoverStyle;
40
40
  var _e = (0, util_1.parseProperties)(props, device), propsStyle = _e.style, propsHoverStyle = _e.hoverStyle, layoutStyle = _e.layout, effect = _e.effect;
41
41
  var isEditModeAndHidden = propsStyle.visibility === 'hidden' && mode === 'EDIT';
42
- var googleFonts = (0, getGoogleFonts_1.getGoogleFontsFromTextSpecCode)(props.CB_STYLE_PROP_TEXT, device === 'MOBILE');
42
+ var googleFonts = (0, getGoogleFonts_1.getGoogleFontsFromTextCB)(props.CB_STYLE_PROP_TEXT, device === 'MOBILE');
43
43
  (0, useGoogleFonts_1.default)({ fonts: googleFonts });
44
44
  if (mode === 'EDIT') {
45
45
  propsStyle.visibility = 'visible';
@@ -55,25 +55,11 @@ function Text(props) {
55
55
  : CB_EFFECT_PROP_ENTANIM['CB_EFFECT_PROP_ENTANIM_SPEC_TYPE:MOBILE'] === 'NONE';
56
56
  var hasEffect = !isNoneEffectType;
57
57
  var effectVisibleStyle = hasEffect ? { opacity: isVisible ? 1 : 0 } : {};
58
- var textValue = function () {
59
- if (device === 'MOBILE') {
60
- var value = props.CB_CONTENT_PROP_TEXT.CB_CONTENT_PROP_TEXT_SPEC_TEXTMOBILEALTERNATIVE;
61
- if (value === null || value === undefined) {
62
- return props.CB_CONTENT_PROP_TEXT.CB_CONTENT_PROP_TEXT_SPEC_TEXT;
63
- }
64
- return value;
65
- }
66
- return props.CB_CONTENT_PROP_TEXT.CB_CONTENT_PROP_TEXT_SPEC_TEXT;
67
- };
68
58
  return ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [isEditModeAndHidden && (0, jsx_runtime_1.jsx)(S_HiddenCover_1.S_HiddenCover, {}), (0, jsx_runtime_1.jsx)(S_CB_AnimationObserverBox_1.S_CB_AnimationObserverBox, __assign({ style: {
69
59
  height: '100%',
70
60
  display: 'flex',
71
61
  alignItems: textStyle.alignItems
72
- }, ref: hasEffect ? cbRef : null, effectVisibleStyle: effectVisibleStyle }, { children: (0, jsx_runtime_1.jsx)(S_CB_Box_1.S_CB_Box, __assign({ onMouseEnter: function (e) {
73
- e.currentTarget.classList.add('hovered');
74
- }, onMouseLeave: function (e) {
75
- e.currentTarget.classList.remove('hovered');
76
- }, className: "cb-layout-box", normalStyle: __assign(__assign(__assign(__assign(__assign({}, textStyle), propsStyle), layoutStyle), effectCssProperties), { whiteSpace: 'pre-wrap', wordBreak: 'break-word', cursor: CLINKCursor, height: 'fit-content', minWidth: "calc(2ch + ".concat(layoutStyle.paddingLeft, " + ").concat(layoutStyle.paddingRight, ")") }), hoverStyle: __assign(__assign(__assign({}, textHoverStyle), propsHoverStyle), { whiteSpace: 'pre-wrap', wordBreak: 'break-word' }), onClick: onClickCLINK }, { children: textValue() })) }))] }));
62
+ }, ref: hasEffect ? cbRef : null, effectVisibleStyle: effectVisibleStyle }, { children: (0, jsx_runtime_1.jsx)(S_CB_Box_1.S_CB_Box, __assign({ className: "cb-layout-box", normalStyle: __assign(__assign(__assign(__assign(__assign(__assign({}, textStyle), propsStyle), layoutStyle), effectCssProperties), { whiteSpace: 'pre-wrap', wordBreak: 'break-word', cursor: CLINKCursor, height: 'fit-content', minWidth: "calc(2ch + ".concat(layoutStyle.paddingLeft, " + ").concat(layoutStyle.paddingRight, ")") }), textStyle), hoverStyle: __assign(__assign(__assign({}, textHoverStyle), propsHoverStyle), { whiteSpace: 'pre-wrap', wordBreak: 'break-word' }), onClick: onClickCLINK }, { children: props.CB_CONTENT_PROP_TEXT.CB_CONTENT_PROP_TEXT_SPEC_TEXT })) }))] }));
77
63
  }
78
64
  function getTextStyles(props, device) {
79
65
  var availableSpecCodes = [
@@ -0,0 +1,38 @@
1
+ import type { ENUM_STRING, NUMBER_INTEGER, STRING_8DIGIT_HEX } from '../../../../../../../DynamicLayout/sections/CustomSection/util/types';
2
+ export type TextPropsKeys = keyof CB_STYLE_PROP_TEXT_SPECS;
3
+ export type CB_STYLE_PROP_TEXT_SPECS_BASE = {
4
+ CB_STYLE_PROP_TEXT_SPEC_TYPEFACE: ENUM_STRING;
5
+ CB_STYLE_PROP_TEXT_SPEC_WEIGHT: NUMBER_INTEGER;
6
+ CB_STYLE_PROP_TEXT_SPEC_SIZE: NUMBER_INTEGER;
7
+ CB_STYLE_PROP_TEXT_SPEC_LINEHEIGHT: NUMBER_INTEGER;
8
+ CB_STYLE_PROP_TEXT_SPEC_LETTERSPACING: NUMBER_INTEGER;
9
+ CB_STYLE_PROP_TEXT_SPEC_COLOR: STRING_8DIGIT_HEX;
10
+ CB_STYLE_PROP_TEXT_SPEC_HORIZONTAL: ENUM_STRING;
11
+ CB_STYLE_PROP_TEXT_SPEC_VERTICAL: ENUM_STRING;
12
+ };
13
+ export type CB_STYLE_PROP_TEXT_SPECS = CB_STYLE_PROP_TEXT_SPECS_BASE & {
14
+ 'CB_STYLE_PROP_TEXT_SPEC_TYPEFACE:HOVER': ENUM_STRING | null | undefined;
15
+ 'CB_STYLE_PROP_TEXT_SPEC_TYPEFACE:MOBILE': ENUM_STRING | null | undefined;
16
+ 'CB_STYLE_PROP_TEXT_SPEC_TYPEFACE:MOBILE:HOVER': ENUM_STRING | null | undefined;
17
+ 'CB_STYLE_PROP_TEXT_SPEC_WEIGHT:HOVER': NUMBER_INTEGER | null | undefined;
18
+ 'CB_STYLE_PROP_TEXT_SPEC_WEIGHT:MOBILE': NUMBER_INTEGER | null | undefined;
19
+ 'CB_STYLE_PROP_TEXT_SPEC_WEIGHT:MOBILE:HOVER': NUMBER_INTEGER | null | undefined;
20
+ 'CB_STYLE_PROP_TEXT_SPEC_SIZE:HOVER': NUMBER_INTEGER | null | undefined;
21
+ 'CB_STYLE_PROP_TEXT_SPEC_SIZE:MOBILE': NUMBER_INTEGER | null | undefined;
22
+ 'CB_STYLE_PROP_TEXT_SPEC_SIZE:MOBILE:HOVER': NUMBER_INTEGER | null | undefined;
23
+ 'CB_STYLE_PROP_TEXT_SPEC_LINEHEIGHT:HOVER': NUMBER_INTEGER | null | undefined;
24
+ 'CB_STYLE_PROP_TEXT_SPEC_LINEHEIGHT:MOBILE': NUMBER_INTEGER | null | undefined;
25
+ 'CB_STYLE_PROP_TEXT_SPEC_LINEHEIGHT:MOBILE:HOVER': NUMBER_INTEGER | null | undefined;
26
+ 'CB_STYLE_PROP_TEXT_SPEC_LETTERSPACING:HOVER': NUMBER_INTEGER | null | undefined;
27
+ 'CB_STYLE_PROP_TEXT_SPEC_LETTERSPACING:MOBILE': NUMBER_INTEGER | null | undefined;
28
+ 'CB_STYLE_PROP_TEXT_SPEC_LETTERSPACING:MOBILE:HOVER': NUMBER_INTEGER | null | undefined;
29
+ 'CB_STYLE_PROP_TEXT_SPEC_COLOR:HOVER': STRING_8DIGIT_HEX | null | undefined;
30
+ 'CB_STYLE_PROP_TEXT_SPEC_COLOR:MOBILE': STRING_8DIGIT_HEX | null | undefined;
31
+ 'CB_STYLE_PROP_TEXT_SPEC_COLOR:MOBILE:HOVER': STRING_8DIGIT_HEX | null | undefined;
32
+ 'CB_STYLE_PROP_TEXT_SPEC_HORIZONTAL:HOVER': ENUM_STRING | null | undefined;
33
+ 'CB_STYLE_PROP_TEXT_SPEC_HORIZONTAL:MOBILE': ENUM_STRING | null | undefined;
34
+ 'CB_STYLE_PROP_TEXT_SPEC_HORIZONTAL:MOBILE:HOVER': ENUM_STRING | null | undefined;
35
+ 'CB_STYLE_PROP_TEXT_SPEC_VERTICAL:HOVER': ENUM_STRING | null | undefined;
36
+ 'CB_STYLE_PROP_TEXT_SPEC_VERTICAL:MOBILE': ENUM_STRING | null | undefined;
37
+ 'CB_STYLE_PROP_TEXT_SPEC_VERTICAL:MOBILE:HOVER': ENUM_STRING | null | undefined;
38
+ };
@@ -0,0 +1,2 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -40,7 +40,7 @@ var __importStar = (this && this.__importStar) || function (mod) {
40
40
  Object.defineProperty(exports, "__esModule", { value: true });
41
41
  exports.S_CB_Box = void 0;
42
42
  var styled_components_1 = __importStar(require("styled-components"));
43
- exports.S_CB_Box = styled_components_1.default.div(templateObject_3 || (templateObject_3 = __makeTemplateObject(["\n /*\n Introduced in IE 10.\n See http://ie.microsoft.com/testdrive/HTML5/msUserSelect/\n */\n\n height: 100%;\n width: 100%;\n\n ", ";\n\n &:hover,\n &.hovered {\n ", ";\n }\n"], ["\n /*\n Introduced in IE 10.\n See http://ie.microsoft.com/testdrive/HTML5/msUserSelect/\n */\n\n height: 100%;\n width: 100%;\n\n ", ";\n\n &:hover,\n &.hovered {\n ", ";\n }\n"])), function (_a) {
43
+ exports.S_CB_Box = styled_components_1.default.div(templateObject_3 || (templateObject_3 = __makeTemplateObject(["\n /*\n Introduced in IE 10.\n See http://ie.microsoft.com/testdrive/HTML5/msUserSelect/\n */\n\n height: 100%;\n width: 100%;\n\n ", ";\n\n &:hover {\n ", ";\n }\n"], ["\n /*\n Introduced in IE 10.\n See http://ie.microsoft.com/testdrive/HTML5/msUserSelect/\n */\n\n height: 100%;\n width: 100%;\n\n ", ";\n\n &:hover {\n ", ";\n }\n"])), function (_a) {
44
44
  var normalStyle = _a.normalStyle;
45
45
  return (0, styled_components_1.css)(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n ", "\n "], ["\n ", "\n "])), __assign(__assign({}, normalStyle), { boxShadow: '' }));
46
46
  }, function (_a) {
@@ -44,7 +44,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
44
44
  exports.S_CB_BoxWithShadow = void 0;
45
45
  var isNullOrUndefined_1 = __importDefault(require("../../../../../../../DynamicLayout/sections/CustomSection/util/isNullOrUndefined"));
46
46
  var styled_components_1 = __importStar(require("styled-components"));
47
- exports.S_CB_BoxWithShadow = styled_components_1.default.div(templateObject_3 || (templateObject_3 = __makeTemplateObject(["\n /*\n Introduced in IE 10.\n See http://ie.microsoft.com/testdrive/HTML5/msUserSelect/\n */\n\n height: 100%;\n width: 100%;\n\n ", ";\n\n &:before {\n border-bottom-left-radius: ", "px;\n border-bottom-right-radius: ", "px;\n border-top-left-radius: ", "px;\n border-top-right-radius: ", "px;\n box-shadow: ", ";\n content: '';\n height: 100%;\n left: 0;\n opacity: ", ";\n pointer-events: none;\n position: absolute;\n top: 0;\n width: 100%;\n }\n\n &:hover,\n &.hovered {\n ", ";\n\n &:before {\n border-bottom-left-radius: ", "px;\n border-bottom-right-radius: ", "px;\n border-top-left-radius: ", "px;\n border-top-right-radius: ", "px;\n box-shadow: ", ";\n content: '';\n height: 100%;\n left: 0;\n opacity: ", ";\n pointer-events: none;\n position: absolute;\n top: 0;\n width: 100%;\n }\n }\n"], ["\n /*\n Introduced in IE 10.\n See http://ie.microsoft.com/testdrive/HTML5/msUserSelect/\n */\n\n height: 100%;\n width: 100%;\n\n ", ";\n\n &:before {\n border-bottom-left-radius: ", "px;\n border-bottom-right-radius: ", "px;\n border-top-left-radius: ", "px;\n border-top-right-radius: ", "px;\n box-shadow: ", ";\n content: '';\n height: 100%;\n left: 0;\n opacity: ", ";\n pointer-events: none;\n position: absolute;\n top: 0;\n width: 100%;\n }\n\n &:hover,\n &.hovered {\n ", ";\n\n &:before {\n border-bottom-left-radius: ", "px;\n border-bottom-right-radius: ", "px;\n border-top-left-radius: ", "px;\n border-top-right-radius: ", "px;\n box-shadow: ", ";\n content: '';\n height: 100%;\n left: 0;\n opacity: ", ";\n pointer-events: none;\n position: absolute;\n top: 0;\n width: 100%;\n }\n }\n"])), function (_a) {
47
+ exports.S_CB_BoxWithShadow = styled_components_1.default.div(templateObject_3 || (templateObject_3 = __makeTemplateObject(["\n /*\n Introduced in IE 10.\n See http://ie.microsoft.com/testdrive/HTML5/msUserSelect/\n */\n\n height: 100%;\n width: 100%;\n\n ", ";\n\n &:before {\n border-bottom-left-radius: ", "px;\n border-bottom-right-radius: ", "px;\n border-top-left-radius: ", "px;\n border-top-right-radius: ", "px;\n box-shadow: ", ";\n content: '';\n height: 100%;\n left: 0;\n opacity: ", ";\n pointer-events: none;\n position: absolute;\n top: 0;\n width: 100%;\n }\n\n &:hover {\n ", ";\n\n &:before {\n border-bottom-left-radius: ", "px;\n border-bottom-right-radius: ", "px;\n border-top-left-radius: ", "px;\n border-top-right-radius: ", "px;\n box-shadow: ", ";\n content: '';\n height: 100%;\n left: 0;\n opacity: ", ";\n pointer-events: none;\n position: absolute;\n top: 0;\n width: 100%;\n }\n }\n"], ["\n /*\n Introduced in IE 10.\n See http://ie.microsoft.com/testdrive/HTML5/msUserSelect/\n */\n\n height: 100%;\n width: 100%;\n\n ", ";\n\n &:before {\n border-bottom-left-radius: ", "px;\n border-bottom-right-radius: ", "px;\n border-top-left-radius: ", "px;\n border-top-right-radius: ", "px;\n box-shadow: ", ";\n content: '';\n height: 100%;\n left: 0;\n opacity: ", ";\n pointer-events: none;\n position: absolute;\n top: 0;\n width: 100%;\n }\n\n &:hover {\n ", ";\n\n &:before {\n border-bottom-left-radius: ", "px;\n border-bottom-right-radius: ", "px;\n border-top-left-radius: ", "px;\n border-top-right-radius: ", "px;\n box-shadow: ", ";\n content: '';\n height: 100%;\n left: 0;\n opacity: ", ";\n pointer-events: none;\n position: absolute;\n top: 0;\n width: 100%;\n }\n }\n"])), function (_a) {
48
48
  var normalStyle = _a.normalStyle;
49
49
  return (0, styled_components_1.css)(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n ", "\n "], ["\n ", "\n "])), __assign(__assign({}, normalStyle), { boxShadow: '' }));
50
50
  }, function (_a) {