pds-dev-kit-web-test 2.5.338 → 2.5.339
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/CompositionRenderer/ComponentBlockMatcher.js +3 -0
- package/dist/src/sub/DynamicLayout/mock_contentsCarousel.js +1 -1
- package/dist/src/sub/DynamicLayout/mock_contentsList.d.ts +2 -0
- package/dist/src/sub/DynamicLayout/mock_contentsList.js +291 -0
- package/dist/src/sub/DynamicLayout/mocks.d.ts +3 -1
- package/dist/src/sub/DynamicLayout/mocks.js +14 -2
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/ComponentBlockMatcher.js +5 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsList/ContentsList.d.ts +8 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsList/ContentsList.js +93 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsList/ContentsListCore.d.ts +17 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsList/ContentsListCore.js +39 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsList/components/CustomPagination.d.ts +27 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsList/components/CustomPagination.js +188 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsList/contentsListUtils.d.ts +30 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsList/contentsListUtils.js +357 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsList/index.d.ts +1 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsList/index.js +8 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsList/types.d.ts +46 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsList/types.js +2 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/types.d.ts +11 -1
- package/dist/src/sub/DynamicLayout/sections/CustomSection/types.d.ts +11 -3
- package/dist/src/sub/DynamicLayout/sections/CustomSection/types.js +1 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/util/parseProperties.d.ts +2 -2
- package/dist/src/sub/DynamicLayout/sections/CustomSection/util/types.d.ts +16 -1
- package/package.json +1 -1
@@ -49,6 +49,9 @@ function ComponentBlockMatcher(_a) {
|
|
49
49
|
case types_1.CB_ALL_CODES.CB_CONTENTSCAROUSEL: {
|
50
50
|
return (0, jsx_runtime_1.jsx)("div", { children: "NOT SUPPORTED NESTED CAROUSEL" });
|
51
51
|
}
|
52
|
+
case types_1.CB_ALL_CODES.CB_CONTENTSLIST: {
|
53
|
+
return (0, jsx_runtime_1.jsx)("div", { children: "NOT SUPPORTED NESTED CONTENTSLIST" });
|
54
|
+
}
|
52
55
|
default:
|
53
56
|
return (0, jsx_runtime_1.jsx)("div", { children: "Error: not supported CB" });
|
54
57
|
}
|
@@ -105,7 +105,7 @@ exports.SAMPLE_CONTENTSCAROUSEL_CB = {
|
|
105
105
|
CB_CONTENT_PROP_CONTENTSCAROUSEL_SPEC_CONNECT_DATA: '아티클:포스트',
|
106
106
|
CB_CONTENT_PROP_CONTENTSCAROUSEL_SPEC_DATASORTING: '최신순',
|
107
107
|
CB_CONTENT_PROP_CONTENTSCAROUSEL_SPEC_OFFSET: '1',
|
108
|
-
|
108
|
+
CB_CONTENT_PROP_CONTENTSCAROUSEL_SPEC_MANUALITEM: [],
|
109
109
|
CB_CONTENT_PROP_CONTENTSCAROUSEL_SPEC_ITEMCOUNTS: 50,
|
110
110
|
CB_CONTENT_PROP_CONTENTSCAROUSEL_SPEC_DISPLAYCOUNTS: 1
|
111
111
|
},
|
@@ -0,0 +1,291 @@
|
|
1
|
+
"use strict";
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
+
exports.SAMPLE_CONTENTSLIST_CB = void 0;
|
4
|
+
var mock_composition_1 = require("./mock_composition");
|
5
|
+
var types_1 = require("./sections/CustomSection/types");
|
6
|
+
exports.SAMPLE_CONTENTSLIST_CB = {
|
7
|
+
availablePlugins: [],
|
8
|
+
componentBlockCode: types_1.CB_ALL_CODES.CB_CONTENTSLIST,
|
9
|
+
dynamicLayoutSectionId: 18661,
|
10
|
+
type: 'GENERAL',
|
11
|
+
id: 188290,
|
12
|
+
blockId: 'CB_188290',
|
13
|
+
jsonProperties: {
|
14
|
+
data: {
|
15
|
+
CB_PLACEMENT_PROP_PLACEMENT: {
|
16
|
+
CB_PLACEMENT_PROP_PLACEMENT_SPEC_COLS: 7,
|
17
|
+
'CB_PLACEMENT_PROP_PLACEMENT_SPEC_COLS:MOBILE': 8,
|
18
|
+
CB_PLACEMENT_PROP_PLACEMENT_SPEC_ROWS: 16,
|
19
|
+
'CB_PLACEMENT_PROP_PLACEMENT_SPEC_ROWS:MOBILE': 20,
|
20
|
+
CB_PLACEMENT_PROP_PLACEMENT_SPEC_STARTX: 5,
|
21
|
+
'CB_PLACEMENT_PROP_PLACEMENT_SPEC_STARTX:MOBILE': 0,
|
22
|
+
CB_PLACEMENT_PROP_PLACEMENT_SPEC_STARTY: 0,
|
23
|
+
'CB_PLACEMENT_PROP_PLACEMENT_SPEC_STARTY:MOBILE': 0,
|
24
|
+
CB_PLACEMENT_PROP_PLACEMENT_SPEC_ZINDEX: 3,
|
25
|
+
'CB_PLACEMENT_PROP_PLACEMENT_SPEC_ZINDEX:MOBILE': 2
|
26
|
+
// 'CB_PLACEMENT_PROP_PLACEMENT_SPEC_LATEST_LOCKED_STARTY:MOBILE': 2,
|
27
|
+
// 'CB_PLACEMENT_PROP_PLACEMENT_SPEC_LOCKSTATUS:MOBILE': 'FALLBACK_TO_SYNC'
|
28
|
+
},
|
29
|
+
CB_STYLE_PROP_CONTENTSLIST: {
|
30
|
+
// Base properties
|
31
|
+
CB_STYLE_PROP_CONTENTSLIST_SPEC_STYLE: 'DESIGN1',
|
32
|
+
CB_STYLE_PROP_CONTENTSLIST_SPEC_ITEMSPACING: 'NORMAL',
|
33
|
+
CB_STYLE_PROP_CONTENTSLIST_SPEC_ITEMLINEHEIGHT: 10,
|
34
|
+
CB_STYLE_PROP_CONTENTSLIST_SPEC_ITEMHEIGHTFITCONTENT: false,
|
35
|
+
CB_STYLE_PROP_CONTENTSLIST_SPEC_INFINITESCROLL: 'NONE',
|
36
|
+
CB_STYLE_PROP_CONTENTSLIST_SPEC_PAGINATIONSTYLE: 'DESIGN1',
|
37
|
+
CB_STYLE_PROP_CONTENTSLIST_SPEC_PAGINATIONLOCATION: 'INSET20',
|
38
|
+
CB_STYLE_PROP_CONTENTSLIST_SPEC_PAGINATIONSIZE: 'MEDIUM',
|
39
|
+
// Hover state
|
40
|
+
'CB_STYLE_PROP_CONTENTSLIST_SPEC_STYLE:HOVER': 'DESIGN1',
|
41
|
+
'CB_STYLE_PROP_CONTENTSLIST_SPEC_ITEMSPACING:HOVER': 'NORMAL',
|
42
|
+
'CB_STYLE_PROP_CONTENTSLIST_SPEC_ITEMLINEHEIGHT:HOVER': 10,
|
43
|
+
'CB_STYLE_PROP_CONTENTSLIST_SPEC_ITEMHEIGHTFITCONTENT:HOVER': false,
|
44
|
+
'CB_STYLE_PROP_CONTENTSLIST_SPEC_INFINITESCROLL:HOVER': 'NONE',
|
45
|
+
'CB_STYLE_PROP_CONTENTSLIST_SPEC_PAGINATIONSTYLE:HOVER': 'DESIGN1',
|
46
|
+
'CB_STYLE_PROP_CONTENTSLIST_SPEC_PAGINATIONLOCATION:HOVER': 'INSET20',
|
47
|
+
'CB_STYLE_PROP_CONTENTSLIST_SPEC_PAGINATIONSIZE:HOVER': 'MEDIUM',
|
48
|
+
// Mobile state
|
49
|
+
'CB_STYLE_PROP_CONTENTSLIST_SPEC_STYLE:MOBILE': 'DESIGN1',
|
50
|
+
'CB_STYLE_PROP_CONTENTSLIST_SPEC_ITEMSPACING:MOBILE': 'NORMAL',
|
51
|
+
'CB_STYLE_PROP_CONTENTSLIST_SPEC_ITEMLINEHEIGHT:MOBILE': 10,
|
52
|
+
'CB_STYLE_PROP_CONTENTSLIST_SPEC_ITEMHEIGHTFITCONTENT:MOBILE': false,
|
53
|
+
'CB_STYLE_PROP_CONTENTSLIST_SPEC_INFINITESCROLL:MOBILE': 'NONE',
|
54
|
+
'CB_STYLE_PROP_CONTENTSLIST_SPEC_PAGINATIONSTYLE:MOBILE': 'DESIGN1',
|
55
|
+
'CB_STYLE_PROP_CONTENTSLIST_SPEC_PAGINATIONLOCATION:MOBILE': 'INSET20',
|
56
|
+
'CB_STYLE_PROP_CONTENTSLIST_SPEC_PAGINATIONSIZE:MOBILE': 'MEDIUM',
|
57
|
+
// Mobile hover state
|
58
|
+
'CB_STYLE_PROP_CONTENTSLIST_SPEC_STYLE:MOBILE:HOVER': 'DESIGN1',
|
59
|
+
'CB_STYLE_PROP_CONTENTSLIST_SPEC_ITEMSPACING:MOBILE:HOVER': 'NORMAL',
|
60
|
+
'CB_STYLE_PROP_CONTENTSLIST_SPEC_ITEMLINEHEIGHT:MOBILE:HOVER': 10,
|
61
|
+
'CB_STYLE_PROP_CONTENTSLIST_SPEC_ITEMHEIGHTFITCONTENT:MOBILE:HOVER': false,
|
62
|
+
'CB_STYLE_PROP_CONTENTSLIST_SPEC_INFINITESCROLL:MOBILE:HOVER': 'NONE',
|
63
|
+
'CB_STYLE_PROP_CONTENTSLIST_SPEC_PAGINATIONSTYLE:MOBILE:HOVER': 'DESIGN1',
|
64
|
+
'CB_STYLE_PROP_CONTENTSLIST_SPEC_PAGINATIONLOCATION:MOBILE:HOVER': 'INSET20',
|
65
|
+
'CB_STYLE_PROP_CONTENTSLIST_SPEC_PAGINATIONSIZE:MOBILE:HOVER': 'MEDIUM'
|
66
|
+
},
|
67
|
+
CB_CONTENT_PROP_CONTENTSLIST: {
|
68
|
+
CB_CONTENT_PROP_CONTENTSLIST_SPEC_VALUETYPE: 'OPT_VALUE',
|
69
|
+
CB_CONTENT_PROP_CONTENTSLIST_SPEC_CONNECTDATA: '아티클:포스트',
|
70
|
+
CB_CONTENT_PROP_CONTENTSLIST_SPEC_DATASORTING: '최신순',
|
71
|
+
CB_CONTENT_PROP_CONTENTSLIST_SPEC_OFFSET: '1',
|
72
|
+
CB_CONTENT_PROP_CONTENTSLIST_SPEC_MANUALITEM: [],
|
73
|
+
CB_CONTENT_PROP_CONTENTSLIST_SPEC_COLUMNS: 3,
|
74
|
+
CB_CONTENT_PROP_CONTENTSLIST_SPEC_ITEMCOUNTS: 50,
|
75
|
+
CB_CONTENT_PROP_CONTENTSLIST_SPEC_DISPLAYCOUNTS: 1
|
76
|
+
},
|
77
|
+
CB_STYLE_PROP_BORDER: {
|
78
|
+
CB_STYLE_PROP_BORDER_SPEC_STYLE: 'SOLID',
|
79
|
+
'CB_STYLE_PROP_BORDER_SPEC_STYLE:HOVER': 'SOLID',
|
80
|
+
'CB_STYLE_PROP_BORDER_SPEC_STYLE:MOBILE': 'DASHED',
|
81
|
+
'CB_STYLE_PROP_BORDER_SPEC_STYLE:MOBILE:HOVER': 'DOTTED',
|
82
|
+
CB_STYLE_PROP_BORDER_SPEC_WIDTH: 0,
|
83
|
+
'CB_STYLE_PROP_BORDER_SPEC_WIDTH:HOVER': 0,
|
84
|
+
'CB_STYLE_PROP_BORDER_SPEC_WIDTH:MOBILE': 0,
|
85
|
+
'CB_STYLE_PROP_BORDER_SPEC_WIDTH:MOBILE:HOVER': 0,
|
86
|
+
CB_STYLE_PROP_BORDER_SPEC_COLOR: '#FF573300',
|
87
|
+
'CB_STYLE_PROP_BORDER_SPEC_COLOR:HOVER': '#FF573300',
|
88
|
+
'CB_STYLE_PROP_BORDER_SPEC_COLOR:MOBILE': '#00FF5733',
|
89
|
+
'CB_STYLE_PROP_BORDER_SPEC_COLOR:MOBILE:HOVER': '#5733FF00',
|
90
|
+
CB_STYLE_PROP_BORDER_SPEC_RADIUS: { tl: 5, tr: 5, bl: 5, br: 5 },
|
91
|
+
'CB_STYLE_PROP_BORDER_SPEC_RADIUS:HOVER': { tl: 5, tr: 5, bl: 5, br: 5 },
|
92
|
+
'CB_STYLE_PROP_BORDER_SPEC_RADIUS:MOBILE': { tl: 10, tr: 10, bl: 10, br: 10 },
|
93
|
+
'CB_STYLE_PROP_BORDER_SPEC_RADIUS:MOBILE:HOVER': { tl: 15, tr: 15, bl: 15, br: 15 },
|
94
|
+
CB_STYLE_PROP_BORDER_SPEC_RADIUSFIX: true,
|
95
|
+
'CB_STYLE_PROP_BORDER_SPEC_RADIUSFIX:HOVER': true,
|
96
|
+
'CB_STYLE_PROP_BORDER_SPEC_RADIUSFIX:MOBILE': false,
|
97
|
+
'CB_STYLE_PROP_BORDER_SPEC_RADIUSFIX:MOBILE:HOVER': true
|
98
|
+
},
|
99
|
+
CB_STYLE_PROP_SHADOW: {
|
100
|
+
CB_STYLE_PROP_SHADOW_SPEC_BLUR: 24,
|
101
|
+
'CB_STYLE_PROP_SHADOW_SPEC_BLUR:HOVER': 24,
|
102
|
+
'CB_STYLE_PROP_SHADOW_SPEC_BLUR:MOBILE': null,
|
103
|
+
'CB_STYLE_PROP_SHADOW_SPEC_BLUR:MOBILE:HOVER': null,
|
104
|
+
CB_STYLE_PROP_SHADOW_SPEC_COLOR: '#000000',
|
105
|
+
'CB_STYLE_PROP_SHADOW_SPEC_COLOR:HOVER': '#000000',
|
106
|
+
'CB_STYLE_PROP_SHADOW_SPEC_COLOR:MOBILE': null,
|
107
|
+
'CB_STYLE_PROP_SHADOW_SPEC_COLOR:MOBILE:HOVER': null,
|
108
|
+
CB_STYLE_PROP_SHADOW_SPEC_OPACITY: 30,
|
109
|
+
'CB_STYLE_PROP_SHADOW_SPEC_OPACITY:HOVER': 30,
|
110
|
+
'CB_STYLE_PROP_SHADOW_SPEC_OPACITY:MOBILE': null,
|
111
|
+
'CB_STYLE_PROP_SHADOW_SPEC_OPACITY:MOBILE:HOVER': null,
|
112
|
+
CB_STYLE_PROP_SHADOW_SPEC_SPREAD: 2,
|
113
|
+
'CB_STYLE_PROP_SHADOW_SPEC_SPREAD:HOVER': 2,
|
114
|
+
'CB_STYLE_PROP_SHADOW_SPEC_SPREAD:MOBILE': null,
|
115
|
+
'CB_STYLE_PROP_SHADOW_SPEC_SPREAD:MOBILE:HOVER': null,
|
116
|
+
CB_STYLE_PROP_SHADOW_SPEC_TYPE: 'OUTSET',
|
117
|
+
'CB_STYLE_PROP_SHADOW_SPEC_TYPE:HOVER': 'OUTSET',
|
118
|
+
'CB_STYLE_PROP_SHADOW_SPEC_TYPE:MOBILE': null,
|
119
|
+
'CB_STYLE_PROP_SHADOW_SPEC_TYPE:MOBILE:HOVER': null,
|
120
|
+
CB_STYLE_PROP_SHADOW_SPEC_X: 0,
|
121
|
+
'CB_STYLE_PROP_SHADOW_SPEC_X:HOVER': 0,
|
122
|
+
'CB_STYLE_PROP_SHADOW_SPEC_X:MOBILE': null,
|
123
|
+
'CB_STYLE_PROP_SHADOW_SPEC_X:MOBILE:HOVER': null,
|
124
|
+
CB_STYLE_PROP_SHADOW_SPEC_Y: 12,
|
125
|
+
'CB_STYLE_PROP_SHADOW_SPEC_Y:HOVER': 12,
|
126
|
+
'CB_STYLE_PROP_SHADOW_SPEC_Y:MOBILE': null,
|
127
|
+
'CB_STYLE_PROP_SHADOW_SPEC_Y:MOBILE:HOVER': null
|
128
|
+
},
|
129
|
+
CB_STYLE_PROP_OPACITY: {
|
130
|
+
CB_STYLE_PROP_OPACITY_SPEC_OPACITY: 100,
|
131
|
+
'CB_STYLE_PROP_OPACITY_SPEC_OPACITY:HOVER': 100,
|
132
|
+
'CB_STYLE_PROP_OPACITY_SPEC_OPACITY:MOBILE': null,
|
133
|
+
'CB_STYLE_PROP_OPACITY_SPEC_OPACITY:MOBILE:HOVER': null
|
134
|
+
},
|
135
|
+
CB_STYLE_PROP_BGCOLOR: {
|
136
|
+
CB_STYLE_PROP_BGCOLOR_SPEC_ANGLE: 90,
|
137
|
+
'CB_STYLE_PROP_BGCOLOR_SPEC_ANGLE:HOVER': 90,
|
138
|
+
'CB_STYLE_PROP_BGCOLOR_SPEC_ANGLE:MOBILE': null,
|
139
|
+
'CB_STYLE_PROP_BGCOLOR_SPEC_ANGLE:MOBILE:HOVER': null,
|
140
|
+
CB_STYLE_PROP_BGCOLOR_SPEC_COLOR: '#455EEFFF',
|
141
|
+
'CB_STYLE_PROP_BGCOLOR_SPEC_COLOR:HOVER': '#455EEFFF',
|
142
|
+
'CB_STYLE_PROP_BGCOLOR_SPEC_COLOR:MOBILE': null,
|
143
|
+
'CB_STYLE_PROP_BGCOLOR_SPEC_COLOR:MOBILE:HOVER': null,
|
144
|
+
CB_STYLE_PROP_BGCOLOR_SPEC_ENDCOLOR: '#ff0000',
|
145
|
+
'CB_STYLE_PROP_BGCOLOR_SPEC_ENDCOLOR:HOVER': '#27FFBFFF',
|
146
|
+
'CB_STYLE_PROP_BGCOLOR_SPEC_ENDCOLOR:MOBILE': null,
|
147
|
+
'CB_STYLE_PROP_BGCOLOR_SPEC_ENDCOLOR:MOBILE:HOVER': null,
|
148
|
+
CB_STYLE_PROP_BGCOLOR_SPEC_ENDLOC: 100,
|
149
|
+
'CB_STYLE_PROP_BGCOLOR_SPEC_ENDLOC:HOVER': 100,
|
150
|
+
'CB_STYLE_PROP_BGCOLOR_SPEC_ENDLOC:MOBILE': null,
|
151
|
+
'CB_STYLE_PROP_BGCOLOR_SPEC_ENDLOC:MOBILE:HOVER': null,
|
152
|
+
CB_STYLE_PROP_BGCOLOR_SPEC_GRADIENT: 'NONE',
|
153
|
+
'CB_STYLE_PROP_BGCOLOR_SPEC_GRADIENT:HOVER': 'NONE',
|
154
|
+
'CB_STYLE_PROP_BGCOLOR_SPEC_GRADIENT:MOBILE': null,
|
155
|
+
'CB_STYLE_PROP_BGCOLOR_SPEC_GRADIENT:MOBILE:HOVER': null,
|
156
|
+
CB_STYLE_PROP_BGCOLOR_SPEC_STARTCOLOR: 'NONE',
|
157
|
+
'CB_STYLE_PROP_BGCOLOR_SPEC_STARTCOLOR:HOVER': 'NONE',
|
158
|
+
'CB_STYLE_PROP_BGCOLOR_SPEC_STARTCOLOR:MOBILE': null,
|
159
|
+
'CB_STYLE_PROP_BGCOLOR_SPEC_STARTCOLOR:MOBILE:HOVER': null,
|
160
|
+
CB_STYLE_PROP_BGCOLOR_SPEC_STARTLOC: 0,
|
161
|
+
'CB_STYLE_PROP_BGCOLOR_SPEC_STARTLOC:HOVER': 0,
|
162
|
+
'CB_STYLE_PROP_BGCOLOR_SPEC_STARTLOC:MOBILE': null,
|
163
|
+
'CB_STYLE_PROP_BGCOLOR_SPEC_STARTLOC:MOBILE:HOVER': null,
|
164
|
+
CB_STYLE_PROP_BGCOLOR_SPEC_TYPE: 'SOLID',
|
165
|
+
'CB_STYLE_PROP_BGCOLOR_SPEC_TYPE:HOVER': 'SOLID',
|
166
|
+
'CB_STYLE_PROP_BGCOLOR_SPEC_TYPE:MOBILE': null,
|
167
|
+
'CB_STYLE_PROP_BGCOLOR_SPEC_TYPE:MOBILE:HOVER': null
|
168
|
+
},
|
169
|
+
CB_STYLE_PROP_BGOVERLAY: {
|
170
|
+
CB_STYLE_PROP_BGOVERLAY_SPEC_ANGLE: 45,
|
171
|
+
CB_STYLE_PROP_BGOVERLAY_SPEC_COLOR: '#FF573300',
|
172
|
+
CB_STYLE_PROP_BGOVERLAY_SPEC_ENDCOLOR: '#00FF5733',
|
173
|
+
CB_STYLE_PROP_BGOVERLAY_SPEC_ENDLOC: 80,
|
174
|
+
CB_STYLE_PROP_BGOVERLAY_SPEC_GRADIENT: 'LINEAR',
|
175
|
+
CB_STYLE_PROP_BGOVERLAY_SPEC_STARTCOLOR: '#5733FF00',
|
176
|
+
CB_STYLE_PROP_BGOVERLAY_SPEC_STARTLOC: 20,
|
177
|
+
CB_STYLE_PROP_BGOVERLAY_SPEC_TYPE: 'OVERLAY',
|
178
|
+
'CB_STYLE_PROP_BGOVERLAY_SPEC_ANGLE:HOVER': 60,
|
179
|
+
'CB_STYLE_PROP_BGOVERLAY_SPEC_ANGLE:MOBILE': 30,
|
180
|
+
'CB_STYLE_PROP_BGOVERLAY_SPEC_ANGLE:MOBILE:HOVER': 90,
|
181
|
+
'CB_STYLE_PROP_BGOVERLAY_SPEC_COLOR:HOVER': '#AA573300',
|
182
|
+
'CB_STYLE_PROP_BGOVERLAY_SPEC_COLOR:MOBILE': '#BBFF5733',
|
183
|
+
'CB_STYLE_PROP_BGOVERLAY_SPEC_COLOR:MOBILE:HOVER': '#CC5733FF',
|
184
|
+
'CB_STYLE_PROP_BGOVERLAY_SPEC_ENDCOLOR:HOVER': '#DD573300',
|
185
|
+
'CB_STYLE_PROP_BGOVERLAY_SPEC_ENDCOLOR:MOBILE': '#EEFF5733',
|
186
|
+
'CB_STYLE_PROP_BGOVERLAY_SPEC_ENDCOLOR:MOBILE:HOVER': '#FF5733FF',
|
187
|
+
'CB_STYLE_PROP_BGOVERLAY_SPEC_ENDLOC:HOVER': 85,
|
188
|
+
'CB_STYLE_PROP_BGOVERLAY_SPEC_ENDLOC:MOBILE': 75,
|
189
|
+
'CB_STYLE_PROP_BGOVERLAY_SPEC_ENDLOC:MOBILE:HOVER': 95,
|
190
|
+
'CB_STYLE_PROP_BGOVERLAY_SPEC_GRADIENT:HOVER': 'RADIAL',
|
191
|
+
'CB_STYLE_PROP_BGOVERLAY_SPEC_GRADIENT:MOBILE': 'LINEAR',
|
192
|
+
'CB_STYLE_PROP_BGOVERLAY_SPEC_GRADIENT:MOBILE:HOVER': 'CONIC',
|
193
|
+
'CB_STYLE_PROP_BGOVERLAY_SPEC_STARTCOLOR:HOVER': '#11573300',
|
194
|
+
'CB_STYLE_PROP_BGOVERLAY_SPEC_STARTCOLOR:MOBILE': '#225733FF',
|
195
|
+
'CB_STYLE_PROP_BGOVERLAY_SPEC_STARTCOLOR:MOBILE:HOVER': '#3357FF00',
|
196
|
+
'CB_STYLE_PROP_BGOVERLAY_SPEC_STARTLOC:HOVER': 25,
|
197
|
+
'CB_STYLE_PROP_BGOVERLAY_SPEC_STARTLOC:MOBILE': 15,
|
198
|
+
'CB_STYLE_PROP_BGOVERLAY_SPEC_STARTLOC:MOBILE:HOVER': 35,
|
199
|
+
'CB_STYLE_PROP_BGOVERLAY_SPEC_TYPE:HOVER': 'BLEND',
|
200
|
+
'CB_STYLE_PROP_BGOVERLAY_SPEC_TYPE:MOBILE': 'MIX',
|
201
|
+
'CB_STYLE_PROP_BGOVERLAY_SPEC_TYPE:MOBILE:HOVER': 'OVERLAY'
|
202
|
+
},
|
203
|
+
CB_STYLE_PROP_BGMEDIA: {
|
204
|
+
// Base properties
|
205
|
+
CB_STYLE_PROP_BGMEDIA_SPEC_YSRC: 'https://example.com/video.mp4',
|
206
|
+
CB_STYLE_PROP_BGMEDIA_SPEC_TYPE: 'video',
|
207
|
+
CB_STYLE_PROP_BGMEDIA_SPEC_SCROLL: true,
|
208
|
+
CB_STYLE_PROP_BGMEDIA_SPEC_STARTTIME: 0,
|
209
|
+
CB_STYLE_PROP_BGMEDIA_SPEC_REPLAY: false,
|
210
|
+
CB_STYLE_PROP_BGMEDIA_SPEC_MPLAY: true,
|
211
|
+
CB_STYLE_PROP_BGMEDIA_SPEC_IMAGEPOSITION: 'center',
|
212
|
+
CB_STYLE_PROP_BGMEDIA_SPEC_IMAGESELECTOR: '.background-image',
|
213
|
+
CB_STYLE_PROP_BGMEDIA_SPEC_IMAGEFIT: 'cover',
|
214
|
+
CB_STYLE_PROP_BGMEDIA_SPEC_ENDTIME: 60,
|
215
|
+
// Hover state
|
216
|
+
'CB_STYLE_PROP_BGMEDIA_SPEC_ENDTIME:HOVER': 65,
|
217
|
+
'CB_STYLE_PROP_BGMEDIA_SPEC_IMAGEFIT:HOVER': 'contain',
|
218
|
+
'CB_STYLE_PROP_BGMEDIA_SPEC_IMAGESELECTOR:HOVER': '.bg-hover',
|
219
|
+
'CB_STYLE_PROP_BGMEDIA_SPEC_IMAGEPOSITION:HOVER': 'top',
|
220
|
+
'CB_STYLE_PROP_BGMEDIA_SPEC_REPLAY:HOVER': true,
|
221
|
+
'CB_STYLE_PROP_BGMEDIA_SPEC_STARTTIME:HOVER': 5,
|
222
|
+
'CB_STYLE_PROP_BGMEDIA_SPEC_SCROLL:HOVER': false,
|
223
|
+
'CB_STYLE_PROP_BGMEDIA_SPEC_TYPE:HOVER': 'gif',
|
224
|
+
'CB_STYLE_PROP_BGMEDIA_SPEC_YSRC:HOVER': 'https://example.com/hover-video.mp4',
|
225
|
+
// Mobile state
|
226
|
+
'CB_STYLE_PROP_BGMEDIA_SPEC_ENDTIME:MOBILE': 55,
|
227
|
+
'CB_STYLE_PROP_BGMEDIA_SPEC_IMAGEFIT:MOBILE': 'fill',
|
228
|
+
'CB_STYLE_PROP_BGMEDIA_SPEC_IMAGESELECTOR:MOBILE': '.bg-mobile',
|
229
|
+
'CB_STYLE_PROP_BGMEDIA_SPEC_IMAGEPOSITION:MOBILE': 'bottom',
|
230
|
+
'CB_STYLE_PROP_BGMEDIA_SPEC_MPLAY:MOBILE': false,
|
231
|
+
'CB_STYLE_PROP_BGMEDIA_SPEC_REPLAY:MOBILE': true,
|
232
|
+
'CB_STYLE_PROP_BGMEDIA_SPEC_STARTTIME:MOBILE': 10,
|
233
|
+
'CB_STYLE_PROP_BGMEDIA_SPEC_SCROLL:MOBILE': true,
|
234
|
+
'CB_STYLE_PROP_BGMEDIA_SPEC_TYPE:MOBILE': 'image',
|
235
|
+
'CB_STYLE_PROP_BGMEDIA_SPEC_YSRC:MOBILE': 'https://example.com/mobile-video.mp4',
|
236
|
+
// Mobile hover state
|
237
|
+
'CB_STYLE_PROP_BGMEDIA_SPEC_ENDTIME:MOBILE:HOVER': 70,
|
238
|
+
'CB_STYLE_PROP_BGMEDIA_SPEC_IMAGEFIT:MOBILE:HOVER': 'scale-down',
|
239
|
+
'CB_STYLE_PROP_BGMEDIA_SPEC_IMAGESELECTOR:MOBILE:HOVER': '.bg-mobile-hover',
|
240
|
+
'CB_STYLE_PROP_BGMEDIA_SPEC_IMAGEPOSITION:MOBILE:HOVER': 'left',
|
241
|
+
'CB_STYLE_PROP_BGMEDIA_SPEC_REPLAY:MOBILE:HOVER': false,
|
242
|
+
'CB_STYLE_PROP_BGMEDIA_SPEC_STARTTIME:MOBILE:HOVER': 15,
|
243
|
+
'CB_STYLE_PROP_BGMEDIA_SPEC_SCROLL:MOBILE:HOVER': false,
|
244
|
+
'CB_STYLE_PROP_BGMEDIA_SPEC_TYPE:MOBILE:HOVER': 'video',
|
245
|
+
'CB_STYLE_PROP_BGMEDIA_SPEC_YSRC:MOBILE:HOVER': 'https://example.com/mobile-hover-video.mp4'
|
246
|
+
},
|
247
|
+
CB_LAYOUT_PROP_PADDING: {
|
248
|
+
CB_LAYOUT_PROP_PADDING_SPEC_PADDING: {
|
249
|
+
top: 0,
|
250
|
+
right: 0,
|
251
|
+
bottom: 0,
|
252
|
+
left: 0
|
253
|
+
},
|
254
|
+
'CB_LAYOUT_PROP_PADDING_SPEC_PADDING:MOBILE': {
|
255
|
+
top: 0,
|
256
|
+
right: 0,
|
257
|
+
bottom: 0,
|
258
|
+
left: 0
|
259
|
+
},
|
260
|
+
CB_LAYOUT_PROP_PADDING_SPEC_FIX: true,
|
261
|
+
'CB_LAYOUT_PROP_PADDING_SPEC_FIX:MOBILE': false
|
262
|
+
},
|
263
|
+
CB_CONTENT_PROP_HOVER: {
|
264
|
+
CB_CONTENT_PROP_HOVER_SPEC_MUSE: true
|
265
|
+
},
|
266
|
+
CB_LAYOUT_PROP_ARRANGE: {
|
267
|
+
CB_LAYOUT_PROP_ARRANGE_SPEC_HORIZONTAL: 'CENTER',
|
268
|
+
'CB_LAYOUT_PROP_ARRANGE_SPEC_HORIZONTAL:MOBILE': 'CENTER',
|
269
|
+
CB_LAYOUT_PROP_ARRANGE_SPEC_VERTICAL: 'MIDDLE',
|
270
|
+
'CB_LAYOUT_PROP_ARRANGE_SPEC_VERTICAL:MOBILE': undefined
|
271
|
+
},
|
272
|
+
CB_CONTENT_PROP_VISIBILITY: {
|
273
|
+
CB_CONTENT_PROP_VISIBILITY_SPEC_DESKTOP: true,
|
274
|
+
CB_CONTENT_PROP_VISIBILITY_SPEC_MOBILEWEB: true
|
275
|
+
},
|
276
|
+
CB_EFFECT_PROP_ENTANIM: {
|
277
|
+
CB_EFFECT_PROP_ENTANIM_SPEC_TYPE: 'SLIDEINLEFT',
|
278
|
+
'CB_EFFECT_PROP_ENTANIM_SPEC_TYPE:MOBILE': 'SLIDEINLEFT',
|
279
|
+
CB_EFFECT_PROP_ENTANIM_SPEC_DURATION: 1,
|
280
|
+
'CB_EFFECT_PROP_ENTANIM_SPEC_DURATION:MOBILE': undefined,
|
281
|
+
CB_EFFECT_PROP_ENTANIM_SPEC_REPEAT: 1,
|
282
|
+
'CB_EFFECT_PROP_ENTANIM_SPEC_REPEAT:MOBILE': undefined,
|
283
|
+
CB_EFFECT_PROP_ENTANIM_SPEC_TFUNC: 'EASEINOUT',
|
284
|
+
'CB_EFFECT_PROP_ENTANIM_SPEC_TFUNC:MOBILE': undefined
|
285
|
+
}
|
286
|
+
}
|
287
|
+
},
|
288
|
+
queryableDefinitionPreset: 'N/A',
|
289
|
+
queryableTapSrc: 'N/A',
|
290
|
+
compositions: [mock_composition_1.sampleMockComposition1, mock_composition_1.sampleMockComposition2]
|
291
|
+
};
|
@@ -1,7 +1,7 @@
|
|
1
1
|
export declare const MOCK_SECTIONS: {
|
2
2
|
administrativeTitle: string;
|
3
3
|
appearanceTemplate: string;
|
4
|
-
componentBlocks: (import("./sections/CustomSection/types").CB_CONTENTSCAROUSEL | import("./sections/CustomSection/types").CB_SLIDEBANNER | {
|
4
|
+
componentBlocks: (import("./sections/CustomSection/types").CB_CONTENTSLIST | import("./sections/CustomSection/types").CB_CONTENTSCAROUSEL | import("./sections/CustomSection/types").CB_SLIDEBANNER | {
|
5
5
|
availablePlugins: never[];
|
6
6
|
blockId: string;
|
7
7
|
componentBlockCode: string;
|
@@ -999,6 +999,7 @@ export declare const MOCK_SECTIONS: {
|
|
999
999
|
'188287': number;
|
1000
1000
|
'188290': number;
|
1001
1001
|
'188291': number;
|
1002
|
+
'188292': number;
|
1002
1003
|
};
|
1003
1004
|
mobile: {
|
1004
1005
|
'188262': number;
|
@@ -1029,6 +1030,7 @@ export declare const MOCK_SECTIONS: {
|
|
1029
1030
|
'188287': number;
|
1030
1031
|
'188290': number;
|
1031
1032
|
'188291': number;
|
1033
|
+
'188292': number;
|
1032
1034
|
};
|
1033
1035
|
};
|
1034
1036
|
};
|
@@ -2,6 +2,7 @@
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
3
|
exports.MOCK_SECTIONS = void 0;
|
4
4
|
var mock_contentsCarousel_1 = require("./mock_contentsCarousel");
|
5
|
+
var mock_contentsList_1 = require("./mock_contentsList");
|
5
6
|
var mock_slideBanner_1 = require("./mock_slideBanner");
|
6
7
|
exports.MOCK_SECTIONS = [
|
7
8
|
{
|
@@ -10,6 +11,7 @@ exports.MOCK_SECTIONS = [
|
|
10
11
|
componentBlocks: [
|
11
12
|
mock_slideBanner_1.SAMPLE_SLIDEBANNER_CB,
|
12
13
|
mock_contentsCarousel_1.SAMPLE_CONTENTSCAROUSEL_CB,
|
14
|
+
mock_contentsList_1.SAMPLE_CONTENTSLIST_CB,
|
13
15
|
{
|
14
16
|
availablePlugins: [],
|
15
17
|
blockId: 'CB_188265',
|
@@ -4644,6 +4646,14 @@ exports.MOCK_SECTIONS = [
|
|
4644
4646
|
type: 'COMPONENT_BLOCK',
|
4645
4647
|
zOrderDesktopInternal: 28,
|
4646
4648
|
zOrderMobileInternal: 28
|
4649
|
+
},
|
4650
|
+
{
|
4651
|
+
blockId: 'CB_188292',
|
4652
|
+
children: [],
|
4653
|
+
componentBlockId: 188292,
|
4654
|
+
type: 'COMPONENT_BLOCK',
|
4655
|
+
zOrderDesktopInternal: 28,
|
4656
|
+
zOrderMobileInternal: 28
|
4647
4657
|
}
|
4648
4658
|
],
|
4649
4659
|
componentBlockId: null,
|
@@ -4681,7 +4691,8 @@ exports.MOCK_SECTIONS = [
|
|
4681
4691
|
'188286': 26,
|
4682
4692
|
'188287': 19,
|
4683
4693
|
'188290': 27,
|
4684
|
-
'188291': 28
|
4694
|
+
'188291': 28,
|
4695
|
+
'188292': 29
|
4685
4696
|
},
|
4686
4697
|
mobile: {
|
4687
4698
|
'188262': 10,
|
@@ -4711,7 +4722,8 @@ exports.MOCK_SECTIONS = [
|
|
4711
4722
|
'188286': 25,
|
4712
4723
|
'188287': 19,
|
4713
4724
|
'188290': 27,
|
4714
|
-
'188291': 28
|
4725
|
+
'188291': 28,
|
4726
|
+
'188292': 29
|
4715
4727
|
}
|
4716
4728
|
}
|
4717
4729
|
},
|
@@ -20,6 +20,7 @@ var newUtils_1 = require("../../newUtils");
|
|
20
20
|
var types_1 = require("../../types");
|
21
21
|
var Button_1 = __importDefault(require("./componentBlocks/Button/Button"));
|
22
22
|
var ContentsCarousel_1 = require("./componentBlocks/ContentsCarousel");
|
23
|
+
var ContentsList_1 = require("./componentBlocks/ContentsList");
|
23
24
|
var Divider_1 = __importDefault(require("./componentBlocks/Divider/Divider"));
|
24
25
|
var Embed_1 = __importDefault(require("./componentBlocks/Embed/Embed"));
|
25
26
|
var Image_1 = __importDefault(require("./componentBlocks/Image/Image"));
|
@@ -57,6 +58,10 @@ function ComponentBlockMatcher(_a) {
|
|
57
58
|
var compositions = cbProps.compositions;
|
58
59
|
return ((0, jsx_runtime_1.jsx)(SlideBanner_1.SlideBanner, __assign({}, propsWithValue, { compositions: compositions, index: index })));
|
59
60
|
}
|
61
|
+
case types_1.CB_ALL_CODES.CB_CONTENTSLIST: {
|
62
|
+
var compositions = cbProps.compositions;
|
63
|
+
return ((0, jsx_runtime_1.jsx)(ContentsList_1.ContentsList, __assign({}, propsWithValue, { compositions: compositions, index: index })));
|
64
|
+
}
|
60
65
|
default:
|
61
66
|
return (0, jsx_runtime_1.jsx)("div", { children: "Error: not supported CB" });
|
62
67
|
}
|
@@ -0,0 +1,8 @@
|
|
1
|
+
/// <reference types="react" />
|
2
|
+
import type { CB_CONTENTSLIST } from '../../../../../../../DynamicLayout/sections/CustomSection/types';
|
3
|
+
import type { CB_CONTENTSLIST_PROPERTIES_TYPE, IndexForIntersection } from '../../../../../../../DynamicLayout/sections/CustomSection/util/types';
|
4
|
+
type Props = CB_CONTENTSLIST_PROPERTIES_TYPE & IndexForIntersection & {
|
5
|
+
compositions: CB_CONTENTSLIST['compositions'];
|
6
|
+
};
|
7
|
+
declare function ContentsList(props: Props): JSX.Element;
|
8
|
+
export default ContentsList;
|
@@ -0,0 +1,93 @@
|
|
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
|
+
/* eslint-disable */
|
23
|
+
var react_1 = require("react");
|
24
|
+
var Composition_1 = __importDefault(require("../../../../../../../DynamicLayout/CompositionRenderer/Composition"));
|
25
|
+
var dynamicLayoutContext_1 = require("../../../../../../../DynamicLayout/dynamicLayoutContext");
|
26
|
+
var hooks_1 = require("../../../../../../../DynamicLayout/sections/CustomSection/hooks");
|
27
|
+
var util_1 = require("../../../../../../../DynamicLayout/sections/CustomSection/util");
|
28
|
+
var styled_components_1 = __importDefault(require("styled-components"));
|
29
|
+
var S_CB_AnimationObserverBox_1 = require("../components/S_CB_AnimationObserverBox");
|
30
|
+
var S_CB_BoxWithShadow_1 = require("../components/S_CB_BoxWithShadow");
|
31
|
+
var CustomPagination_1 = require("./components/CustomPagination");
|
32
|
+
require("./ContentsListCore");
|
33
|
+
var contentsListUtils_1 = require("./contentsListUtils");
|
34
|
+
function ContentsList(props) {
|
35
|
+
var device = (0, react_1.useContext)(dynamicLayoutContext_1.dynamicLayoutContext).device;
|
36
|
+
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;
|
37
|
+
var _a = (0, react_1.useState)(false), isHovered = _a[0], setIsHovered = _a[1];
|
38
|
+
var _b = (0, react_1.useState)(1), currentPage = _b[0], setCurrentPage = _b[1];
|
39
|
+
var totalItemCounts = CB_CONTENT_PROP_CONTENTSLIST.CB_CONTENT_PROP_CONTENTSLIST_SPEC_ITEMCOUNTS;
|
40
|
+
var displayCounts = CB_CONTENT_PROP_CONTENTSLIST.CB_CONTENT_PROP_CONTENTSLIST_SPEC_DISPLAYCOUNTS;
|
41
|
+
var totalPage = Math.ceil(totalItemCounts / displayCounts);
|
42
|
+
var _c = (0, util_1.parseProperties)(props, device), style = _c.style, hoverStyle = _c.hoverStyle, layout = _c.layout, effect = _c.effect;
|
43
|
+
var contentPropCss = (0, contentsListUtils_1.parseGridContentProp)({
|
44
|
+
props: CB_CONTENT_PROP_CONTENTSLIST
|
45
|
+
}).contentPropCss;
|
46
|
+
var _d = (0, contentsListUtils_1.parseGridStyleProp)({
|
47
|
+
props: CB_STYLE_PROP_CONTENTSLIST,
|
48
|
+
device: device
|
49
|
+
}), stylePropCss = _d.stylePropCss, hoverStylePropCss = _d.hoverStylePropCss;
|
50
|
+
var _e = (0, contentsListUtils_1.parsePaginationStyleProp)({
|
51
|
+
props: CB_STYLE_PROP_CONTENTSLIST,
|
52
|
+
device: device
|
53
|
+
}), paginationNormalStyle = _e.normalStyle, paginationHoverStyle = _e.hoverStyle;
|
54
|
+
var cbRef = (0, react_1.useRef)(null);
|
55
|
+
var entry = (0, hooks_1.useIntersectionObserver)(cbRef, { threshold: 0.2, freezeOnceVisible: false }, [
|
56
|
+
index
|
57
|
+
]);
|
58
|
+
var isVisible = !!(entry === null || entry === void 0 ? void 0 : entry.isIntersecting);
|
59
|
+
var effectCssProperties = isVisible ? effect : {};
|
60
|
+
var isNoneEffectType = device === 'DESKTOP'
|
61
|
+
? CB_EFFECT_PROP_ENTANIM.CB_EFFECT_PROP_ENTANIM_SPEC_TYPE === 'NONE'
|
62
|
+
: CB_EFFECT_PROP_ENTANIM['CB_EFFECT_PROP_ENTANIM_SPEC_TYPE:MOBILE'] === 'NONE';
|
63
|
+
var hasEffect = !isNoneEffectType;
|
64
|
+
var effectVisibleStyle = hasEffect
|
65
|
+
? { opacity: isVisible ? 1 : 0, position: 'relative' }
|
66
|
+
: { position: 'relative' };
|
67
|
+
var handlePrevBtnClick = function () {
|
68
|
+
if (currentPage === 1)
|
69
|
+
return;
|
70
|
+
setCurrentPage(function (prev) { return prev - 1; });
|
71
|
+
};
|
72
|
+
var handleNextBtnClick = function () {
|
73
|
+
if (currentPage === totalPage)
|
74
|
+
return;
|
75
|
+
setCurrentPage(function (prev) { return prev + 1; });
|
76
|
+
};
|
77
|
+
var handleBulletClick = function (index) {
|
78
|
+
setCurrentPage(index + 1);
|
79
|
+
};
|
80
|
+
var startIndex = (currentPage - 1) * displayCounts;
|
81
|
+
var endIndex = startIndex + displayCounts;
|
82
|
+
return ((0, jsx_runtime_1.jsxs)(S_CB_AnimationObserverBox_1.S_CB_AnimationObserverBox, __assign({ ref: hasEffect ? cbRef : null, effectVisibleStyle: effectVisibleStyle }, { children: [(0, jsx_runtime_1.jsx)(S_CB_BoxWithShadow_1.S_CB_BoxWithShadow, __assign({ id: "contentslist-box", className: "cb-layout-box", normalStyle: __assign(__assign(__assign({}, style), layout), effectCssProperties), hoverStyle: hoverStyle, cbStylePropsShadowSpecs: CB_STYLE_PROP_SHADOW, device: device, onMouseEnter: function () { return setIsHovered(true); }, onMouseLeave: function () { return setIsHovered(false); } }, { children: (0, jsx_runtime_1.jsx)(S_ContentsListWrapper, __assign({ id: "contentslist-wrapper" }, { children: (0, jsx_runtime_1.jsx)(S_ContentsListGrid, __assign({ id: "contentslist-grid", contentPropCss: contentPropCss, stylePropCss: isHovered ? hoverStylePropCss : stylePropCss }, { children: compositions.slice(startIndex, endIndex).map(function (composition) { return ((0, jsx_runtime_1.jsx)(Composition_1.default, __assign({}, composition), composition.id)); }) })) })) })), (0, jsx_runtime_1.jsx)(CustomPagination_1.CustomPagination, { effectVisibleStyle: effectVisibleStyle, type: isHovered ? paginationHoverStyle.type : paginationNormalStyle.type, offset: isHovered ? paginationHoverStyle.offset : paginationNormalStyle.offset, current: currentPage, total: Math.ceil(totalItemCounts / displayCounts), size: isHovered ? paginationHoverStyle.size : paginationNormalStyle.size, onBulletClick: handleBulletClick })] })));
|
83
|
+
}
|
84
|
+
var S_ContentsListWrapper = styled_components_1.default.div(templateObject_1 || (templateObject_1 = __makeTemplateObject(["\n height: 100%;\n /* overflow-y: hidden; */\n position: relative;\n width: 100%;\n"], ["\n height: 100%;\n /* overflow-y: hidden; */\n position: relative;\n width: 100%;\n"])));
|
85
|
+
var S_ContentsListGrid = styled_components_1.default.div(templateObject_2 || (templateObject_2 = __makeTemplateObject(["\n display: grid;\n height: 100%;\n\n ", "\n ", "\n"], ["\n display: grid;\n height: 100%;\n\n ", "\n ", "\n"])), function (_a) {
|
86
|
+
var contentPropCss = _a.contentPropCss;
|
87
|
+
return contentPropCss;
|
88
|
+
}, function (_a) {
|
89
|
+
var stylePropCss = _a.stylePropCss;
|
90
|
+
return stylePropCss;
|
91
|
+
});
|
92
|
+
exports.default = ContentsList;
|
93
|
+
var templateObject_1, templateObject_2;
|
@@ -0,0 +1,17 @@
|
|
1
|
+
/// <reference types="react" />
|
2
|
+
import 'swiper/modules/navigation/navigation.min.css';
|
3
|
+
import 'swiper/swiper-bundle.css';
|
4
|
+
import type { SwiperProps, SwiperRef } from 'swiper/react/swiper-react.js';
|
5
|
+
export interface ContentsListCoreProps extends SwiperProps {
|
6
|
+
scrollbar?: SwiperProps['scrollbar'];
|
7
|
+
slidesPerView?: SwiperProps['slidesPerView'];
|
8
|
+
slidesPerGroup?: SwiperProps['slidesPerGroup'];
|
9
|
+
spaceBetween?: SwiperProps['spaceBetween'];
|
10
|
+
freeMode?: SwiperProps['freeMode'];
|
11
|
+
autoplay?: SwiperProps['autoplay'];
|
12
|
+
useAutoplay?: boolean;
|
13
|
+
loop?: SwiperProps['loop'];
|
14
|
+
children?: React.ReactNode[];
|
15
|
+
}
|
16
|
+
declare const ContentsListCore: import("react").ForwardRefExoticComponent<ContentsListCoreProps & import("react").RefAttributes<SwiperRef>>;
|
17
|
+
export default ContentsListCore;
|
@@ -0,0 +1,39 @@
|
|
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
|
+
var __rest = (this && this.__rest) || function (s, e) {
|
14
|
+
var t = {};
|
15
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
16
|
+
t[p] = s[p];
|
17
|
+
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
18
|
+
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
19
|
+
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
20
|
+
t[p[i]] = s[p[i]];
|
21
|
+
}
|
22
|
+
return t;
|
23
|
+
};
|
24
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
25
|
+
var jsx_runtime_1 = require("react/jsx-runtime");
|
26
|
+
var react_1 = require("react");
|
27
|
+
var swiper_1 = require("swiper");
|
28
|
+
require("swiper/modules/navigation/navigation.min.css");
|
29
|
+
var react_2 = require("swiper/react");
|
30
|
+
require("swiper/swiper-bundle.css");
|
31
|
+
var ContentsListCore = (0, react_1.forwardRef)(function (_a, ref) {
|
32
|
+
var scrollbar = _a.scrollbar, slidesPerView = _a.slidesPerView, slidesPerGroup = _a.slidesPerGroup, spaceBetween = _a.spaceBetween, freeMode = _a.freeMode, autoplay = _a.autoplay, useAutoplay = _a.useAutoplay, loop = _a.loop, children = _a.children, props = __rest(_a, ["scrollbar", "slidesPerView", "slidesPerGroup", "spaceBetween", "freeMode", "autoplay", "useAutoplay", "loop", "children"]);
|
33
|
+
return ((0, jsx_runtime_1.jsx)(react_2.Swiper, __assign({ ref: ref, style: {
|
34
|
+
width: '100%',
|
35
|
+
height: '100%'
|
36
|
+
}, modules: [swiper_1.Pagination, swiper_1.Navigation, swiper_1.Scrollbar, swiper_1.FreeMode, swiper_1.Autoplay], slidesPerView: slidesPerView, scrollbar: scrollbar, slidesPerGroup: slidesPerGroup, spaceBetween: spaceBetween, freeMode: freeMode, autoplay: useAutoplay ? autoplay : false, loop: loop }, props, { children: (0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, { children: children === null || children === void 0 ? void 0 : children.map(function (slide, index) { return ((0, jsx_runtime_1.jsx)(react_2.SwiperSlide, { children: slide }, index)); }) }) })));
|
37
|
+
});
|
38
|
+
ContentsListCore.displayName = 'ContentsListCore';
|
39
|
+
exports.default = ContentsListCore;
|
@@ -0,0 +1,27 @@
|
|
1
|
+
/// <reference types="react" />
|
2
|
+
import type { CB_STYLE_PROP_CONTENTSLIST_SPEC_PAGINATIONSTYLE_TYPE } from '../types';
|
3
|
+
export interface CustomPaginationProps {
|
4
|
+
effectVisibleStyle?: React.CSSProperties;
|
5
|
+
current?: number;
|
6
|
+
total?: number;
|
7
|
+
type?: CB_STYLE_PROP_CONTENTSLIST_SPEC_PAGINATIONSTYLE_TYPE;
|
8
|
+
offset?: {
|
9
|
+
top?: string;
|
10
|
+
bottom?: string;
|
11
|
+
left?: string;
|
12
|
+
right?: string;
|
13
|
+
translateX?: number;
|
14
|
+
translateY?: number;
|
15
|
+
transformOrigin?: string;
|
16
|
+
};
|
17
|
+
size?: number;
|
18
|
+
onBulletClick?: (index: number) => void;
|
19
|
+
}
|
20
|
+
export declare const CustomPagination: ({ effectVisibleStyle, current, total, type, offset, size, onBulletClick }: CustomPaginationProps) => JSX.Element;
|
21
|
+
export interface FlexBoxProps {
|
22
|
+
direction?: 'row' | 'column';
|
23
|
+
justifyContent?: string;
|
24
|
+
alignItems?: string;
|
25
|
+
gap?: string;
|
26
|
+
}
|
27
|
+
export default CustomPagination;
|