pds-dev-kit-web-test 2.7.162 → 2.7.164
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/sub/DynamicLayout/mock_contentsList.js +4680 -254
- package/dist/src/sub/DynamicLayout/mocks.js +6 -6
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsCarousel/components/CustomNavigationPrevBtn.d.ts +1 -1
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsCarousel/components/CustomNavigationPrevBtn.js +1 -1
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsList/ContentsList.js +10 -6
- package/package.json +1 -1
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.MOCK_SECTIONS = void 0;
|
|
4
|
-
|
|
5
|
-
require("./mock_contentsList");
|
|
6
|
-
|
|
4
|
+
require("./mock_contentsCarousel");
|
|
5
|
+
var mock_contentsList_1 = require("./mock_contentsList");
|
|
6
|
+
require("./mock_slideBanner");
|
|
7
7
|
exports.MOCK_SECTIONS = [
|
|
8
8
|
{
|
|
9
9
|
administrativeTitle: 'Daily Pages',
|
|
@@ -11,9 +11,9 @@ exports.MOCK_SECTIONS = [
|
|
|
11
11
|
componentBlocks: [
|
|
12
12
|
// MOCK_VIDEO_CB,
|
|
13
13
|
// MOCK_VIDEO_CB_2,
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
14
|
+
// SAMPLE_CONTENTSCAROUSEL_CB,
|
|
15
|
+
// SAMPLE_SLIDEBANNER_CB,
|
|
16
|
+
mock_contentsList_1.SAMPLE_LIST_CB
|
|
17
17
|
// ...MOCK_COMPONENT_BLOCKS
|
|
18
18
|
],
|
|
19
19
|
display: true,
|
|
@@ -3,7 +3,7 @@ import type { CustomNavigationProps } from '../types';
|
|
|
3
3
|
export interface CustomNavigationPrevBtnProps {
|
|
4
4
|
isDisabled: boolean;
|
|
5
5
|
styles: CustomNavigationProps;
|
|
6
|
-
hoverStyles
|
|
6
|
+
hoverStyles?: CustomNavigationProps;
|
|
7
7
|
onClick?: () => void;
|
|
8
8
|
}
|
|
9
9
|
export declare const CustomNavigationPrevBtn: ({ isDisabled, styles, hoverStyles, onClick }: CustomNavigationPrevBtnProps) => JSX.Element;
|
|
@@ -58,7 +58,7 @@ var CustomNavigationPrevBtn = function (_a) {
|
|
|
58
58
|
buttonSize = 'xxlarge';
|
|
59
59
|
iconSize = 48;
|
|
60
60
|
}
|
|
61
|
-
return ((0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: prevButton && ((0, jsx_runtime_1.jsx)(S_PrevButton, __assign({ className: "cb-contentscarousel-prev-button", disabled: isDisabled, "$size": styles.prevBtnSize }, { children: (0, jsx_runtime_1.jsx)(IconButton_1.IconButton, { fillType: "fill", baseSize: buttonSize, iconSize: iconSize, shapeType: prevButton.shapeType, borderColorKey: prevButton.borderColorKey, iconName: prevButton.iconName, iconFillType: "line", iconColorKey: prevButton.iconColorKey || 'ui_cpnt_icon_sys_black', overrideBaseColorHex: styles.prevBtnPrimaryColor, overrideBaseColorHexHover: hoverStyles.prevBtnPrimaryColor, overrideIconColorHex: styles.prevBtnSecondaryColor, overrideIconColorHexHover: hoverStyles.prevBtnSecondaryColor, shadow: prevButton.shadow, onClick: onClick, useDefaultActiveStyle: false, useDefaultHoverStyle: false }) }))) }));
|
|
61
|
+
return ((0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: prevButton && ((0, jsx_runtime_1.jsx)(S_PrevButton, __assign({ className: "cb-contentscarousel-prev-button", disabled: isDisabled, "$size": styles.prevBtnSize }, { children: (0, jsx_runtime_1.jsx)(IconButton_1.IconButton, { fillType: "fill", baseSize: buttonSize, iconSize: iconSize, shapeType: prevButton.shapeType, borderColorKey: prevButton.borderColorKey, iconName: prevButton.iconName, iconFillType: "line", iconColorKey: prevButton.iconColorKey || 'ui_cpnt_icon_sys_black', overrideBaseColorHex: styles.prevBtnPrimaryColor, overrideBaseColorHexHover: hoverStyles === null || hoverStyles === void 0 ? void 0 : hoverStyles.prevBtnPrimaryColor, overrideIconColorHex: styles.prevBtnSecondaryColor, overrideIconColorHexHover: hoverStyles === null || hoverStyles === void 0 ? void 0 : hoverStyles.prevBtnSecondaryColor, shadow: prevButton.shadow, onClick: onClick, useDefaultActiveStyle: false, useDefaultHoverStyle: false }) }))) }));
|
|
62
62
|
};
|
|
63
63
|
exports.CustomNavigationPrevBtn = CustomNavigationPrevBtn;
|
|
64
64
|
var S_PrevButton = styled_components_1.default.div(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n cursor: pointer;\n\n ", ";\n"], ["\n cursor: pointer;\n\n ", ";\n"])), function (_a) {
|
|
@@ -60,14 +60,18 @@ function ContentsList(props) {
|
|
|
60
60
|
var _a, _b, _c, _d, _e, _f;
|
|
61
61
|
var _g = (0, react_1.useContext)(dynamicLayoutContext_1.dynamicLayoutContext), device = _g.device, mode = _g.mode, queryData = _g.queryData;
|
|
62
62
|
var index = props.index, compositions = props.compositions, CB_CONTENT_PROP_CONTENTSLIST = props.CB_CONTENT_PROP_CONTENTSLIST, CB_STYLE_PROP_CONTENTSLIST = props.CB_STYLE_PROP_CONTENTSLIST, CB_STYLE_PROP_SHADOW = props.CB_STYLE_PROP_SHADOW, CB_EFFECT_PROP_ENTANIM = props.CB_EFFECT_PROP_ENTANIM, CB_LAYOUT_PROP_PADDING = props.CB_LAYOUT_PROP_PADDING, CB_STYLE_PROP_BGMEDIA = props.CB_STYLE_PROP_BGMEDIA, CB_STYLE_PROP_BGOVERLAY = props.CB_STYLE_PROP_BGOVERLAY;
|
|
63
|
-
var CB_CONTENT_PROP_CONTENTSLIST_SPEC_ITEMCOUNTS = CB_CONTENT_PROP_CONTENTSLIST.CB_CONTENT_PROP_CONTENTSLIST_SPEC_ITEMCOUNTS,
|
|
63
|
+
var CB_CONTENT_PROP_CONTENTSLIST_SPEC_ITEMCOUNTS = CB_CONTENT_PROP_CONTENTSLIST.CB_CONTENT_PROP_CONTENTSLIST_SPEC_ITEMCOUNTS,
|
|
64
|
+
// CB_CONTENT_PROP_CONTENTSLIST_SPEC_DISPLAYCOUNTS,
|
|
65
|
+
CB_CONTENT_PROP_CONTENTSLIST_SPEC_VALUETYPE = CB_CONTENT_PROP_CONTENTSLIST.CB_CONTENT_PROP_CONTENTSLIST_SPEC_VALUETYPE, CB_CONTENT_PROP_CONTENTSLIST_SPEC_CONNECTDATA = CB_CONTENT_PROP_CONTENTSLIST.CB_CONTENT_PROP_CONTENTSLIST_SPEC_CONNECTDATA, CB_CONTENT_PROP_CONTENTSLIST_SPEC_COLUMNS = CB_CONTENT_PROP_CONTENTSLIST.CB_CONTENT_PROP_CONTENTSLIST_SPEC_COLUMNS, CB_CONTENT_PROP_CONTENTSLIST_SPEC_MANUALITEMS = CB_CONTENT_PROP_CONTENTSLIST.CB_CONTENT_PROP_CONTENTSLIST_SPEC_MANUALITEMS;
|
|
64
66
|
var _h = (0, react_1.useState)(false), isHovered = _h[0], setIsHovered = _h[1];
|
|
65
67
|
var _j = (0, react_1.useState)(1), currentPage = _j[0], setCurrentPage = _j[1];
|
|
68
|
+
var CB_CONTENT_PROP_CONTENTSLIST_SPEC_DISPLAYCOUNTS = 3;
|
|
66
69
|
var parsedQueryPath = removeFirstSegment(CB_CONTENT_PROP_CONTENTSLIST_SPEC_CONNECTDATA);
|
|
67
70
|
var queryDataValue = queryData === null || queryData === void 0 ? void 0 : queryData[parsedQueryPath];
|
|
68
71
|
var totalPage = Math.ceil((CB_CONTENT_PROP_CONTENTSLIST_SPEC_VALUETYPE === 'DATA' && queryDataValue
|
|
69
72
|
? queryDataValue === null || queryDataValue === void 0 ? void 0 : queryDataValue.length
|
|
70
|
-
:
|
|
73
|
+
: CB_CONTENT_PROP_CONTENTSLIST_SPEC_MANUALITEMS.length) /
|
|
74
|
+
CB_CONTENT_PROP_CONTENTSLIST_SPEC_DISPLAYCOUNTS);
|
|
71
75
|
var _k = (0, util_1.parseProperties)(props, device), style = _k.style, hoverStyle = _k.hoverStyle, layout = _k.layout, effect = _k.effect, overlayStyle = _k.overlayStyle;
|
|
72
76
|
var contentPropCss = (0, contentsListUtils_1.parseGridContentProp)({
|
|
73
77
|
props: CB_CONTENT_PROP_CONTENTSLIST
|
|
@@ -98,10 +102,10 @@ function ContentsList(props) {
|
|
|
98
102
|
var handlePageClick = function (page) {
|
|
99
103
|
setCurrentPage(page);
|
|
100
104
|
};
|
|
101
|
-
var displayCounts =
|
|
105
|
+
var displayCounts = CB_CONTENT_PROP_CONTENTSLIST_SPEC_DISPLAYCOUNTS;
|
|
102
106
|
// CB_CONTENT_PROP_CONTENTSLIST_SPEC_DISPLAYCOUNTS ?? CB_CONTENT_PROP_CONTENTSLIST_SPEC_ITEMCOUNTS;
|
|
103
107
|
var startIndex = (currentPage - 1) * displayCounts;
|
|
104
|
-
var endIndex = startIndex + displayCounts;
|
|
108
|
+
var endIndex = startIndex + (displayCounts - 1);
|
|
105
109
|
// list의 minheight / minwidth를 계산
|
|
106
110
|
var numberOfColumns = CB_CONTENT_PROP_CONTENTSLIST_SPEC_COLUMNS;
|
|
107
111
|
// NOTE: edit환경에서 hover가 작동하지 않아서 제외함 필요시 추가..
|
|
@@ -177,10 +181,10 @@ function ContentsList(props) {
|
|
|
177
181
|
style: { gridTemplateRows: "repeat(".concat(numberOfRows, ", 1fr)") } }, { children: (0, createCompositions_1.createCompositions)({
|
|
178
182
|
valueType: CB_CONTENT_PROP_CONTENTSLIST_SPEC_VALUETYPE,
|
|
179
183
|
queryPath: CB_CONTENT_PROP_CONTENTSLIST_SPEC_CONNECTDATA,
|
|
180
|
-
limit:
|
|
184
|
+
limit: displayCounts,
|
|
181
185
|
queryData: queryData,
|
|
182
186
|
compositions: orderedCompositions
|
|
183
|
-
}).slice(startIndex, endIndex) })) }))] })) }))] }));
|
|
187
|
+
}).slice(startIndex, endIndex + 1) })) }))] })) }))] }));
|
|
184
188
|
}
|
|
185
189
|
function getIsBgMedia(isMobile, specs) {
|
|
186
190
|
if (!specs) {
|