pds-dev-kit-web-test 2.5.675 → 2.5.677
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.
@@ -47,29 +47,29 @@ var createComponent = function (type, getDesignType, getLocation) {
|
|
47
47
|
};
|
48
48
|
};
|
49
49
|
function ContentsList(props) {
|
50
|
-
var _a, _b, _c, _d, _e;
|
51
|
-
var
|
50
|
+
var _a, _b, _c, _d, _e, _f;
|
51
|
+
var _g = (0, react_1.useContext)(dynamicLayoutContext_1.dynamicLayoutContext), device = _g.device, mode = _g.mode, queryData = _g.queryData;
|
52
52
|
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;
|
53
53
|
var CB_CONTENT_PROP_CONTENTSLIST_SPEC_ITEMCOUNTS = CB_CONTENT_PROP_CONTENTSLIST.CB_CONTENT_PROP_CONTENTSLIST_SPEC_ITEMCOUNTS, CB_CONTENT_PROP_CONTENTSLIST_SPEC_DISPLAYCOUNTS = CB_CONTENT_PROP_CONTENTSLIST.CB_CONTENT_PROP_CONTENTSLIST_SPEC_DISPLAYCOUNTS, 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;
|
54
|
-
var
|
55
|
-
var
|
54
|
+
var _h = (0, react_1.useState)(false), isHovered = _h[0], setIsHovered = _h[1];
|
55
|
+
var _j = (0, react_1.useState)(1), currentPage = _j[0], setCurrentPage = _j[1];
|
56
56
|
var parsedQueryPath = removeFirstSegment(CB_CONTENT_PROP_CONTENTSLIST_SPEC_CONNECTDATA);
|
57
57
|
var queryDataValue = queryData === null || queryData === void 0 ? void 0 : queryData[parsedQueryPath];
|
58
58
|
var totalPage = Math.ceil((CB_CONTENT_PROP_CONTENTSLIST_SPEC_VALUETYPE === 'DATA' && queryDataValue
|
59
59
|
? queryDataValue === null || queryDataValue === void 0 ? void 0 : queryDataValue.length
|
60
60
|
: compositions.length - 1) / CB_CONTENT_PROP_CONTENTSLIST_SPEC_DISPLAYCOUNTS);
|
61
|
-
var
|
61
|
+
var _k = (0, util_1.parseProperties)(props, device), style = _k.style, hoverStyle = _k.hoverStyle, layout = _k.layout, effect = _k.effect, overlayStyle = _k.overlayStyle;
|
62
62
|
var contentPropCss = (0, contentsListUtils_1.parseGridContentProp)({
|
63
63
|
props: CB_CONTENT_PROP_CONTENTSLIST
|
64
64
|
}).contentPropCss;
|
65
|
-
var
|
65
|
+
var _l = (0, contentsListUtils_1.parseGridStyleProp)({
|
66
66
|
props: CB_STYLE_PROP_CONTENTSLIST,
|
67
67
|
device: device
|
68
|
-
}), stylePropCss =
|
69
|
-
var
|
68
|
+
}), stylePropCss = _l.stylePropCss, hoverStylePropCss = _l.hoverStylePropCss;
|
69
|
+
var _m = (0, contentsListUtils_1.parsePaginationStyleProp)({
|
70
70
|
props: CB_STYLE_PROP_CONTENTSLIST,
|
71
71
|
device: device
|
72
|
-
}), paginationNormalStyle =
|
72
|
+
}), paginationNormalStyle = _m.normalStyle, paginationHoverStyle = _m.hoverStyle;
|
73
73
|
// NOTE: edit모드에서는 그리드의 이벤트만 작동하도록 CB의 포인터 이벤트는 막습니다.
|
74
74
|
var editModeStyle = mode === 'EDIT' ? { pointerEvents: 'none' } : {};
|
75
75
|
var cbRef = (0, react_1.useRef)(null);
|
@@ -119,9 +119,9 @@ function ContentsList(props) {
|
|
119
119
|
var components = [
|
120
120
|
createPagination(paginationNormalStyle, paginationHoverStyle, isHovered)
|
121
121
|
].filter(function (component) { return component !== undefined; });
|
122
|
-
var
|
122
|
+
var _o = (0, useFlexGridLayout_1.useFlexGridLayout)({ components: components }), layoutRef = _o.layoutRef, positionRefs = _o.positionRefs,
|
123
123
|
// ccbInset,
|
124
|
-
componentGroups =
|
124
|
+
componentGroups = _o.componentGroups, getPositionStyle = _o.getPositionStyle, getComponentGroupLayout = _o.getComponentGroupLayout;
|
125
125
|
var ccbInset = {
|
126
126
|
top: '0px',
|
127
127
|
right: '0px',
|
@@ -140,8 +140,11 @@ function ContentsList(props) {
|
|
140
140
|
var isMobile = device === 'MOBILE';
|
141
141
|
var isBgMedia = getIsBgMedia(isMobile, CB_STYLE_PROP_BGMEDIA);
|
142
142
|
var mediaType = getMediaType(isMobile, CB_STYLE_PROP_BGMEDIA);
|
143
|
-
var queryLength = (_e = queryData === null || queryData === void 0 ? void 0 : queryData[CB_CONTENT_PROP_CONTENTSLIST_SPEC_CONNECTDATA].length) !== null &&
|
143
|
+
var queryLength = (_f = (_e = queryData === null || queryData === void 0 ? void 0 : queryData[CB_CONTENT_PROP_CONTENTSLIST_SPEC_CONNECTDATA]) === null || _e === void 0 ? void 0 : _e.length) !== null && _f !== void 0 ? _f : 0;
|
144
144
|
var displayedItemLength = Math.max(0, Math.min(endIndex, queryLength) - startIndex);
|
145
|
+
console.log(queryLength);
|
146
|
+
console.log('queryData', queryData);
|
147
|
+
console.log('CB_CONTENT_PROP_CONTENTSLIST_SPEC_CONNECTDATA', CB_CONTENT_PROP_CONTENTSLIST_SPEC_CONNECTDATA);
|
145
148
|
return ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [Object.entries(componentGroups).map(function (_a) {
|
146
149
|
var position = _a[0], groupComponents = _a[1];
|
147
150
|
return ((0, jsx_runtime_1.jsx)("div", __assign({ className: "cb-contentslist-button-group", ref: function (el) {
|