pds-dev-kit-web-test 2.5.436 → 2.5.438
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_contentsCarousel.js +5 -17
- package/dist/src/sub/DynamicLayout/mock_contentsList.js +2 -2
- package/dist/src/sub/DynamicLayout/mock_slideBanner.d.ts +63 -63
- package/dist/src/sub/DynamicLayout/mock_slideBanner.js +64 -64
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsCarousel/ContentsCarousel.js +63 -192
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsCarousel/ContentsCarouselCore.d.ts +2 -7
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsCarousel/ContentsCarouselCore.js +8 -6
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsCarousel/components/CustomNavigationNextBtn.d.ts +15 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsCarousel/components/CustomNavigationNextBtn.js +69 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsCarousel/components/CustomNavigationPrevBtn.d.ts +15 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsCarousel/components/CustomNavigationPrevBtn.js +69 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsCarousel/components/CustomProgressbar.d.ts +4 -18
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsCarousel/components/CustomProgressbar.js +19 -49
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsCarousel/components/progressConfigs.js +16 -16
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsCarousel/contentsCarouselUtils.d.ts +19 -20
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsCarousel/contentsCarouselUtils.js +131 -696
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsCarousel/hooks/useFlexGridLayout.d.ts +25 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsCarousel/hooks/useFlexGridLayout.js +234 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsCarousel/hooks/useSwiper.d.ts +14 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsCarousel/hooks/useSwiper.js +46 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsCarousel/types.d.ts +36 -2
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsList/ContentsList.js +38 -20
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsList/components/CustomPagination.d.ts +6 -25
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsList/components/CustomPagination.js +21 -51
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsList/contentsListUtils.d.ts +8 -9
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsList/contentsListUtils.js +42 -294
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsList/hooks/useFlexGridLayout.d.ts +23 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsList/hooks/useFlexGridLayout.js +230 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsList/types.d.ts +12 -1
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/SlideBanner/SlideBanner.js +69 -146
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/SlideBanner/SlideBannerCore.d.ts +2 -5
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/SlideBanner/SlideBannerCore.js +2 -2
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/SlideBanner/components/CustomNavigationNextBtn.d.ts +15 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/SlideBanner/components/CustomNavigationNextBtn.js +69 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/SlideBanner/components/CustomNavigationPrevBtn.d.ts +15 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/SlideBanner/components/CustomNavigationPrevBtn.js +69 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/SlideBanner/components/CustomPagination.d.ts +9 -22
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/SlideBanner/components/CustomPagination.js +25 -35
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/SlideBanner/components/CustomProgressbar.d.ts +4 -18
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/SlideBanner/components/CustomProgressbar.js +19 -49
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/SlideBanner/components/progressConfigs.js +8 -8
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/SlideBanner/hooks/useFlexGridLayout.d.ts +26 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/SlideBanner/hooks/useFlexGridLayout.js +235 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/SlideBanner/hooks/useSwiper.d.ts +16 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/SlideBanner/hooks/useSwiper.js +63 -0
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/SlideBanner/slideBannerUtils.d.ts +22 -24
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/SlideBanner/slideBannerUtils.js +155 -925
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/SlideBanner/types.d.ts +46 -3
- package/package.json +2 -2
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsCarousel/components/CustomNavigation.d.ts +0 -35
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsCarousel/components/CustomNavigation.js +0 -118
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsCarousel/components/CustomPagination.d.ts +0 -32
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/ContentsCarousel/components/CustomPagination.js +0 -183
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/SlideBanner/components/CustomNavigation.d.ts +0 -35
- package/dist/src/sub/DynamicLayout/sections/CustomSection/components/ComponentBlock/componentBlocks/SlideBanner/components/CustomNavigation.js +0 -118
|
@@ -1,956 +1,186 @@
|
|
|
1
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
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
|
-
exports.
|
|
19
|
-
var styled_components_1 = require("styled-components");
|
|
20
|
-
function parseSlideBannerStyleToSlideBannerCoreProp(_a) {
|
|
21
|
-
var props = _a.props, device = _a.device;
|
|
22
|
-
var availableSpecCodes = Object.keys(props).filter(function (key) { return !key.includes(':HOVER') && !key.includes(':MOBILE'); });
|
|
23
|
-
return availableSpecCodes.reduce(function (acc, currentKey) {
|
|
24
|
-
var _a, _b, _c, _d;
|
|
25
|
-
var keyWithDevice = device === 'DESKTOP' ? currentKey : "".concat(currentKey, ":MOBILE");
|
|
26
|
-
var keyWithHover = "".concat(keyWithDevice.toString(), ":HOVER");
|
|
27
|
-
var slideBannerCorePropertyKey = getSlideBannerCorePropKey(currentKey);
|
|
28
|
-
if (slideBannerCorePropertyKey === 'customStyle') {
|
|
29
|
-
var value = props[keyWithDevice];
|
|
30
|
-
var hoverValue = props[keyWithHover];
|
|
31
|
-
return {
|
|
32
|
-
normalStyle: __assign(__assign({}, acc.normalStyle), (_a = {}, _a[slideBannerCorePropertyKey] = getStyle(value), _a)),
|
|
33
|
-
hoverStyle: __assign(__assign({}, acc.hoverStyle), (_b = {}, _b[slideBannerCorePropertyKey] = getStyle(hoverValue !== null && hoverValue !== void 0 ? hoverValue : value), _b))
|
|
34
|
-
};
|
|
35
|
-
}
|
|
36
|
-
if (slideBannerCorePropertyKey === 'useAutoplay') {
|
|
37
|
-
var value = props[keyWithDevice];
|
|
38
|
-
var hoverValue = props[keyWithHover];
|
|
39
|
-
return {
|
|
40
|
-
normalStyle: __assign(__assign({}, acc.normalStyle), { useAutoplay: value }),
|
|
41
|
-
hoverStyle: __assign(__assign({}, acc.hoverStyle), { useAutoplay: hoverValue !== null && hoverValue !== void 0 ? hoverValue : value })
|
|
42
|
-
};
|
|
43
|
-
}
|
|
44
|
-
if (slideBannerCorePropertyKey === 'autoplayDelay') {
|
|
45
|
-
var value = props[keyWithDevice];
|
|
46
|
-
var hoverValue = props[keyWithHover];
|
|
47
|
-
return {
|
|
48
|
-
normalStyle: __assign(__assign({}, acc.normalStyle), { autoplay: {
|
|
49
|
-
delay: value * 1000,
|
|
50
|
-
disableOnInteraction: false,
|
|
51
|
-
pauseOnMouseEnter: true
|
|
52
|
-
} }),
|
|
53
|
-
hoverStyle: __assign(__assign({}, acc.hoverStyle), { autoplay: {
|
|
54
|
-
delay: (hoverValue !== null && hoverValue !== void 0 ? hoverValue : value) * 1000,
|
|
55
|
-
disableOnInteraction: false,
|
|
56
|
-
pauseOnMouseEnter: true
|
|
57
|
-
} })
|
|
58
|
-
};
|
|
59
|
-
}
|
|
60
|
-
if (slideBannerCorePropertyKey === 'loop') {
|
|
61
|
-
var value = props[keyWithDevice];
|
|
62
|
-
var hoverValue = props[keyWithHover];
|
|
63
|
-
return {
|
|
64
|
-
normalStyle: __assign(__assign({}, acc.normalStyle), (_c = {}, _c[slideBannerCorePropertyKey] = value, _c)),
|
|
65
|
-
hoverStyle: __assign(__assign({}, acc.hoverStyle), (_d = {}, _d[slideBannerCorePropertyKey] = hoverValue !== null && hoverValue !== void 0 ? hoverValue : value, _d))
|
|
66
|
-
};
|
|
67
|
-
}
|
|
68
|
-
return {
|
|
69
|
-
normalStyle: __assign({}, acc.normalStyle),
|
|
70
|
-
hoverStyle: __assign({}, acc.hoverStyle)
|
|
71
|
-
};
|
|
72
|
-
}, {
|
|
73
|
-
normalStyle: {},
|
|
74
|
-
hoverStyle: {}
|
|
75
|
-
});
|
|
76
|
-
}
|
|
77
|
-
exports.parseSlideBannerStyleToSlideBannerCoreProp = parseSlideBannerStyleToSlideBannerCoreProp;
|
|
78
|
-
function getSlideBannerCorePropKey(key) {
|
|
79
|
-
switch (key) {
|
|
80
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_STYLE":
|
|
81
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_STYLE:HOVER":
|
|
82
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_STYLE:MOBILE":
|
|
83
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_STYLE:MOBILE:HOVER":
|
|
84
|
-
return 'customStyle';
|
|
85
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_AUTOPLAYUSE":
|
|
86
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_AUTOPLAYUSE:HOVER":
|
|
87
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_AUTOPLAYUSE:MOBILE":
|
|
88
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_AUTOPLAYUSE:MOBILE:HOVER":
|
|
89
|
-
return 'useAutoplay';
|
|
90
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_AUTOPLAYTIME":
|
|
91
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_AUTOPLAYTIME:HOVER":
|
|
92
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_AUTOPLAYTIME:MOBILE":
|
|
93
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_AUTOPLAYTIME:MOBILE:HOVER":
|
|
94
|
-
return 'autoplayDelay';
|
|
95
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_INFINITESCROLL":
|
|
96
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_INFINITESCROLL:HOVER":
|
|
97
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_INFINITESCROLL:MOBILE":
|
|
98
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_INFINITESCROLL:MOBILE:HOVER":
|
|
99
|
-
return 'loop';
|
|
100
|
-
default:
|
|
101
|
-
return '';
|
|
102
|
-
}
|
|
103
|
-
}
|
|
104
|
-
exports.getSlideBannerCorePropKey = getSlideBannerCorePropKey;
|
|
3
|
+
exports.parseSlideBannerStyleToCustomProgressbarProp = exports.parseSlideBannerStyleToCustomNavigationProp = exports.parseSlideBannerStyleToCustomPaginationProp = exports.parseSlideBannerStyleToSlideBannerCoreProp = exports.getCustomPaginationPropKey = exports.getCustomProgressbarPropKey = exports.getCustomNavigationPropKey = exports.getSlideBannerCorePropKey = void 0;
|
|
105
4
|
function getStyle(value) {
|
|
106
5
|
switch (value) {
|
|
107
6
|
case 'DESIGN1':
|
|
108
|
-
return
|
|
7
|
+
return undefined;
|
|
109
8
|
case 'DESIGN2': {
|
|
110
|
-
return
|
|
9
|
+
return undefined;
|
|
111
10
|
}
|
|
112
11
|
default: {
|
|
113
|
-
return
|
|
12
|
+
return undefined;
|
|
114
13
|
}
|
|
115
14
|
}
|
|
116
15
|
}
|
|
117
|
-
function
|
|
118
|
-
var
|
|
119
|
-
var
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
var hoverValue = props[keyWithHover];
|
|
127
|
-
return {
|
|
128
|
-
normalStyle: __assign(__assign({}, acc.normalStyle), { type: value }),
|
|
129
|
-
hoverStyle: __assign(__assign({}, acc.hoverStyle), { type: hoverValue !== null && hoverValue !== void 0 ? hoverValue : value })
|
|
130
|
-
};
|
|
131
|
-
}
|
|
132
|
-
if (customPaginationPropertyKey === 'offset') {
|
|
133
|
-
var value = props[keyWithDevice];
|
|
134
|
-
var hoverValue = props[keyWithHover];
|
|
135
|
-
return {
|
|
136
|
-
normalStyle: __assign(__assign({}, acc.normalStyle), { offset: getCustomPaginationOffset(value) }),
|
|
137
|
-
hoverStyle: __assign(__assign({}, acc.hoverStyle), { offset: getCustomPaginationOffset(hoverValue !== null && hoverValue !== void 0 ? hoverValue : value) })
|
|
138
|
-
};
|
|
139
|
-
}
|
|
140
|
-
if (customPaginationPropertyKey === 'size') {
|
|
141
|
-
var value = props[keyWithDevice];
|
|
142
|
-
var hoverValue = props[keyWithHover];
|
|
143
|
-
return {
|
|
144
|
-
normalStyle: __assign(__assign({}, acc.normalStyle), { size: getCustomPaginationSize(value) }),
|
|
145
|
-
hoverStyle: __assign(__assign({}, acc.hoverStyle), { size: getCustomPaginationSize(hoverValue !== null && hoverValue !== void 0 ? hoverValue : value) })
|
|
146
|
-
};
|
|
147
|
-
}
|
|
148
|
-
if (customPaginationPropertyKey === 'primaryColor') {
|
|
149
|
-
var value = props[keyWithDevice];
|
|
150
|
-
var hoverValue = props[keyWithHover];
|
|
151
|
-
return {
|
|
152
|
-
normalStyle: __assign(__assign({}, acc.normalStyle), { primaryColor: value }),
|
|
153
|
-
hoverStyle: __assign(__assign({}, acc.hoverStyle), { primaryColor: hoverValue !== null && hoverValue !== void 0 ? hoverValue : value })
|
|
154
|
-
};
|
|
155
|
-
}
|
|
156
|
-
if (customPaginationPropertyKey === 'secondaryColor') {
|
|
157
|
-
var value = props[keyWithDevice];
|
|
158
|
-
var hoverValue = props[keyWithHover];
|
|
159
|
-
return {
|
|
160
|
-
normalStyle: __assign(__assign({}, acc.normalStyle), { secondaryColor: value }),
|
|
161
|
-
hoverStyle: __assign(__assign({}, acc.hoverStyle), { secondaryColor: hoverValue !== null && hoverValue !== void 0 ? hoverValue : value })
|
|
162
|
-
};
|
|
163
|
-
}
|
|
164
|
-
return {
|
|
165
|
-
normalStyle: __assign({}, acc.normalStyle),
|
|
166
|
-
hoverStyle: __assign({}, acc.hoverStyle)
|
|
167
|
-
};
|
|
168
|
-
}, {
|
|
169
|
-
normalStyle: {},
|
|
170
|
-
hoverStyle: {}
|
|
171
|
-
});
|
|
16
|
+
function getSlideBannerCorePropKey(key) {
|
|
17
|
+
var baseKey = key.split(':')[0];
|
|
18
|
+
var keyMapping = {
|
|
19
|
+
CB_STYLE_PROP_SLIDEBANNER_SPEC_STYLE: 'customStyle',
|
|
20
|
+
CB_STYLE_PROP_SLIDEBANNER_SPEC_AUTOPLAYUSE: 'useAutoplay',
|
|
21
|
+
CB_STYLE_PROP_SLIDEBANNER_SPEC_AUTOPLAYTIME: 'autoplay',
|
|
22
|
+
CB_STYLE_PROP_SLIDEBANNER_SPEC_INFINITESCROLL: 'loop'
|
|
23
|
+
};
|
|
24
|
+
return keyMapping[baseKey] || null;
|
|
172
25
|
}
|
|
173
|
-
exports.
|
|
26
|
+
exports.getSlideBannerCorePropKey = getSlideBannerCorePropKey;
|
|
27
|
+
function getCustomNavigationPropKey(key) {
|
|
28
|
+
var baseKey = key.split(':')[0];
|
|
29
|
+
var keyMapping = {
|
|
30
|
+
CB_STYLE_PROP_SLIDEBANNER_SPEC_PREVBTNSTYLE: 'prevBtnType',
|
|
31
|
+
CB_STYLE_PROP_SLIDEBANNER_SPEC_PREVBTNLOCATION: 'prevBtnLocation',
|
|
32
|
+
CB_STYLE_PROP_SLIDEBANNER_SPEC_PREVBTNSIZE: 'prevBtnSize',
|
|
33
|
+
CB_STYLE_PROP_SLIDEBANNER_SPEC_PREVBTNPRIMARYCOLOR: 'prevBtnPrimaryColor',
|
|
34
|
+
CB_STYLE_PROP_SLIDEBANNER_SPEC_PREVBTNSECONDARYCOLOR: 'prevBtnSecondaryColor',
|
|
35
|
+
CB_STYLE_PROP_SLIDEBANNER_SPEC_NEXTBTNSTYLE: 'nextBtnType',
|
|
36
|
+
CB_STYLE_PROP_SLIDEBANNER_SPEC_NEXTBTNLOCATION: 'nextBtnLocation',
|
|
37
|
+
CB_STYLE_PROP_SLIDEBANNER_SPEC_NEXTBTNSIZE: 'nextBtnSize',
|
|
38
|
+
CB_STYLE_PROP_SLIDEBANNER_SPEC_NEXTBTNPRIMARYCOLOR: 'nextBtnPrimaryColor',
|
|
39
|
+
CB_STYLE_PROP_SLIDEBANNER_SPEC_NEXTBTNSECONDARYCOLOR: 'nextBtnSecondaryColor'
|
|
40
|
+
};
|
|
41
|
+
return keyMapping[baseKey] || null;
|
|
42
|
+
}
|
|
43
|
+
exports.getCustomNavigationPropKey = getCustomNavigationPropKey;
|
|
44
|
+
function getCustomProgressbarPropKey(key) {
|
|
45
|
+
var baseKey = key.split(':')[0];
|
|
46
|
+
var keyMapping = {
|
|
47
|
+
CB_STYLE_PROP_SLIDEBANNER_SPEC_PROGRESSBAR: 'type',
|
|
48
|
+
CB_STYLE_PROP_SLIDEBANNER_SPEC_PROGRESSBARSIZE: 'size',
|
|
49
|
+
CB_STYLE_PROP_SLIDEBANNER_SPEC_PROGRESSBARPRIMARYCOLOR: 'primaryColor',
|
|
50
|
+
CB_STYLE_PROP_SLIDEBANNER_SPEC_PROGRESSBARSECONDARYCOLOR: 'secondaryColor'
|
|
51
|
+
};
|
|
52
|
+
return keyMapping[baseKey] || null;
|
|
53
|
+
}
|
|
54
|
+
exports.getCustomProgressbarPropKey = getCustomProgressbarPropKey;
|
|
174
55
|
function getCustomPaginationPropKey(key) {
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PAGINATIONLOCATION:MOBILE:HOVER":
|
|
185
|
-
return 'offset';
|
|
186
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PAGINATIONSIZE":
|
|
187
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PAGINATIONSIZE:HOVER":
|
|
188
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PAGINATIONSIZE:MOBILE":
|
|
189
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PAGINATIONSIZE:MOBILE:HOVER":
|
|
190
|
-
return 'size';
|
|
191
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PAGINATIONPRIMARYCOLOR":
|
|
192
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PAGINATIONPRIMARYCOLOR:HOVER":
|
|
193
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PAGINATIONPRIMARYCOLOR:MOBILE":
|
|
194
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PAGINATIONPRIMARYCOLOR:MOBILE:HOVER":
|
|
195
|
-
return 'primaryColor';
|
|
196
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PAGINATIONSECONDARYCOLOR":
|
|
197
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PAGINATIONSECONDARYCOLOR:HOVER":
|
|
198
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PAGINATIONSECONDARYCOLOR:MOBILE":
|
|
199
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PAGINATIONSECONDARYCOLOR:MOBILE:HOVER":
|
|
200
|
-
return 'secondaryColor';
|
|
201
|
-
default:
|
|
202
|
-
return '';
|
|
203
|
-
}
|
|
56
|
+
var baseKey = key.split(':')[0];
|
|
57
|
+
var keyMapping = {
|
|
58
|
+
CB_STYLE_PROP_SLIDEBANNER_SPEC_PAGINATIONSTYLE: 'type',
|
|
59
|
+
CB_STYLE_PROP_SLIDEBANNER_SPEC_PAGINATIONSIZE: 'size',
|
|
60
|
+
CB_STYLE_PROP_SLIDEBANNER_SPEC_PAGINATIONLOCATION: 'location',
|
|
61
|
+
CB_STYLE_PROP_SLIDEBANNER_SPEC_PAGINATIONPRIMARYCOLOR: 'primaryColor',
|
|
62
|
+
CB_STYLE_PROP_SLIDEBANNER_SPEC_PAGINATIONSECONDARYCOLOR: 'secondaryColor'
|
|
63
|
+
};
|
|
64
|
+
return keyMapping[baseKey] || null;
|
|
204
65
|
}
|
|
205
66
|
exports.getCustomPaginationPropKey = getCustomPaginationPropKey;
|
|
206
|
-
function
|
|
207
|
-
var
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
transformOrigin: 'top left'
|
|
224
|
-
};
|
|
225
|
-
case 'OUTSET3':
|
|
226
|
-
return {
|
|
227
|
-
top: '0px',
|
|
228
|
-
left: '100%',
|
|
229
|
-
translateX: -100,
|
|
230
|
-
translateY: -100,
|
|
231
|
-
transformOrigin: 'top left'
|
|
232
|
-
};
|
|
233
|
-
case 'OUTSET4':
|
|
234
|
-
return {
|
|
235
|
-
top: '0px',
|
|
236
|
-
left: '100%',
|
|
237
|
-
translateX: 0,
|
|
238
|
-
translateY: 0,
|
|
239
|
-
transformOrigin: 'left top'
|
|
240
|
-
};
|
|
241
|
-
case 'OUTSET5':
|
|
242
|
-
return {
|
|
243
|
-
top: '50%',
|
|
244
|
-
left: '100%',
|
|
245
|
-
translateX: 0,
|
|
246
|
-
translateY: -50,
|
|
247
|
-
transformOrigin: 'left top'
|
|
248
|
-
};
|
|
249
|
-
case 'OUTSET6':
|
|
250
|
-
return {
|
|
251
|
-
top: '100%',
|
|
252
|
-
left: '100%',
|
|
253
|
-
translateX: 0,
|
|
254
|
-
translateY: -100,
|
|
255
|
-
transformOrigin: 'left top'
|
|
256
|
-
};
|
|
257
|
-
case 'OUTSET7':
|
|
258
|
-
return {
|
|
259
|
-
top: '100%',
|
|
260
|
-
left: '100%',
|
|
261
|
-
translateX: -100,
|
|
262
|
-
translateY: 0,
|
|
263
|
-
transformOrigin: 'top left'
|
|
264
|
-
};
|
|
265
|
-
case 'OUTSET8':
|
|
266
|
-
return {
|
|
267
|
-
top: '100%',
|
|
268
|
-
left: '50%',
|
|
269
|
-
translateX: -50,
|
|
270
|
-
translateY: 0,
|
|
271
|
-
transformOrigin: 'top left'
|
|
272
|
-
};
|
|
273
|
-
case 'OUTSET9':
|
|
274
|
-
return {
|
|
275
|
-
top: '100%',
|
|
276
|
-
left: '0px',
|
|
277
|
-
translateX: 0,
|
|
278
|
-
translateY: 0,
|
|
279
|
-
transformOrigin: 'top left'
|
|
280
|
-
};
|
|
281
|
-
case 'OUTSET10':
|
|
282
|
-
return {
|
|
283
|
-
top: '100%',
|
|
284
|
-
left: '0px',
|
|
285
|
-
translateX: -100,
|
|
286
|
-
translateY: -100,
|
|
287
|
-
transformOrigin: 'right top'
|
|
288
|
-
};
|
|
289
|
-
case 'OUTSET11':
|
|
290
|
-
return {
|
|
291
|
-
top: '50%',
|
|
292
|
-
left: '0px',
|
|
293
|
-
translateX: -100,
|
|
294
|
-
translateY: -50,
|
|
295
|
-
transformOrigin: 'right top'
|
|
296
|
-
};
|
|
297
|
-
case 'OUTSET12':
|
|
298
|
-
return {
|
|
299
|
-
top: '0px',
|
|
300
|
-
left: '0px',
|
|
301
|
-
translateX: -100,
|
|
302
|
-
translateY: 0,
|
|
303
|
-
transformOrigin: 'right top'
|
|
304
|
-
};
|
|
305
|
-
case 'INSET1':
|
|
306
|
-
return { top: '0px', left: '0px', translateX: 0, translateY: 0, transformOrigin: 'left top' };
|
|
307
|
-
case 'INSET2':
|
|
308
|
-
return {
|
|
309
|
-
top: '0px',
|
|
310
|
-
left: '50%',
|
|
311
|
-
translateX: -50,
|
|
312
|
-
translateY: 0,
|
|
313
|
-
transformOrigin: 'left top'
|
|
314
|
-
};
|
|
315
|
-
case 'INSET3':
|
|
316
|
-
return {
|
|
317
|
-
top: '0px',
|
|
318
|
-
left: '100%',
|
|
319
|
-
translateX: -100,
|
|
320
|
-
translateY: 0,
|
|
321
|
-
transformOrigin: 'left top'
|
|
322
|
-
};
|
|
323
|
-
case 'INSET4':
|
|
324
|
-
return {
|
|
325
|
-
top: '50%',
|
|
326
|
-
left: '100%',
|
|
327
|
-
translateX: -100,
|
|
328
|
-
translateY: -50,
|
|
329
|
-
transformOrigin: 'left top'
|
|
330
|
-
};
|
|
331
|
-
case 'INSET5':
|
|
332
|
-
return {
|
|
333
|
-
top: '100%',
|
|
334
|
-
left: '100%',
|
|
335
|
-
translateX: -100,
|
|
336
|
-
translateY: -100,
|
|
337
|
-
transformOrigin: 'left top'
|
|
338
|
-
};
|
|
339
|
-
case 'INSET6':
|
|
340
|
-
return {
|
|
341
|
-
top: '100%',
|
|
342
|
-
left: '50%',
|
|
343
|
-
translateX: -50,
|
|
344
|
-
translateY: -100,
|
|
345
|
-
transformOrigin: 'left top'
|
|
346
|
-
};
|
|
347
|
-
case 'INSET7':
|
|
348
|
-
return {
|
|
349
|
-
top: '100%',
|
|
350
|
-
left: '0px',
|
|
351
|
-
translateX: 0,
|
|
352
|
-
translateY: -100,
|
|
353
|
-
transformOrigin: 'top left'
|
|
354
|
-
};
|
|
355
|
-
case 'INSET8':
|
|
356
|
-
return {
|
|
357
|
-
top: '50%',
|
|
358
|
-
left: '0px',
|
|
359
|
-
translateX: 0,
|
|
360
|
-
translateY: -50,
|
|
361
|
-
transformOrigin: 'top left'
|
|
362
|
-
};
|
|
67
|
+
var transformValue = function (key, value) {
|
|
68
|
+
var _a, _b, _c, _d;
|
|
69
|
+
switch (key) {
|
|
70
|
+
case 'customStyle':
|
|
71
|
+
return _a = {}, _a[key] = getStyle(value), _a;
|
|
72
|
+
case 'useAutoplay':
|
|
73
|
+
return _b = {}, _b[key] = value === true, _b;
|
|
74
|
+
case 'autoplay':
|
|
75
|
+
return {
|
|
76
|
+
autoplay: {
|
|
77
|
+
delay: value * 1000,
|
|
78
|
+
disableOnInteraction: false,
|
|
79
|
+
pauseOnMouseEnter: true
|
|
80
|
+
}
|
|
81
|
+
};
|
|
82
|
+
case 'loop':
|
|
83
|
+
return _c = {}, _c[key] = value, _c;
|
|
363
84
|
default:
|
|
364
|
-
return
|
|
85
|
+
return _d = {}, _d[key] = value, _d;
|
|
365
86
|
}
|
|
87
|
+
};
|
|
88
|
+
function parseSlideBannerStyleToSlideBannerCoreProp(_a) {
|
|
89
|
+
var props = _a.props, device = _a.device;
|
|
90
|
+
var normalStyle = {};
|
|
91
|
+
var hoverStyle = {};
|
|
92
|
+
var baseKeys = Object.keys(props).filter(function (key) { return !key.includes(':HOVER') && !key.includes(':MOBILE'); });
|
|
93
|
+
baseKeys.forEach(function (baseKey) {
|
|
94
|
+
var customNavKey = getSlideBannerCorePropKey(baseKey);
|
|
95
|
+
if (customNavKey) {
|
|
96
|
+
var deviceKey = device === 'DESKTOP' ? baseKey : "".concat(baseKey, ":MOBILE");
|
|
97
|
+
var hoverKey = "".concat(deviceKey, ":HOVER");
|
|
98
|
+
var normalValue = props[deviceKey];
|
|
99
|
+
var hoverValue = props[hoverKey];
|
|
100
|
+
if (normalValue !== undefined) {
|
|
101
|
+
Object.assign(normalStyle, transformValue(customNavKey, normalValue));
|
|
102
|
+
}
|
|
103
|
+
Object.assign(hoverStyle, transformValue(customNavKey, hoverValue !== null && hoverValue !== void 0 ? hoverValue : normalValue));
|
|
104
|
+
}
|
|
105
|
+
});
|
|
106
|
+
return {
|
|
107
|
+
normalStyle: normalStyle,
|
|
108
|
+
hoverStyle: hoverStyle
|
|
109
|
+
};
|
|
366
110
|
}
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
111
|
+
exports.parseSlideBannerStyleToSlideBannerCoreProp = parseSlideBannerStyleToSlideBannerCoreProp;
|
|
112
|
+
function parseSlideBannerStyleToCustomPaginationProp(_a) {
|
|
113
|
+
var props = _a.props, device = _a.device;
|
|
114
|
+
var normalStyle = {};
|
|
115
|
+
var hoverStyle = {};
|
|
116
|
+
var baseKeys = Object.keys(props).filter(function (key) { return !key.includes(':HOVER') && !key.includes(':MOBILE'); });
|
|
117
|
+
baseKeys.forEach(function (baseKey) {
|
|
118
|
+
var _a, _b;
|
|
119
|
+
var customNavKey = getCustomPaginationPropKey(baseKey);
|
|
120
|
+
if (customNavKey) {
|
|
121
|
+
var deviceKey = device === 'DESKTOP' ? baseKey : "".concat(baseKey, ":MOBILE");
|
|
122
|
+
var hoverKey = "".concat(deviceKey, ":HOVER");
|
|
123
|
+
var normalValue = props[deviceKey];
|
|
124
|
+
var hoverValue = props[hoverKey];
|
|
125
|
+
if (normalValue !== undefined) {
|
|
126
|
+
Object.assign(normalStyle, (_a = {}, _a[customNavKey] = normalValue, _a));
|
|
127
|
+
}
|
|
128
|
+
Object.assign(hoverStyle, (_b = {}, _b[customNavKey] = hoverValue !== null && hoverValue !== void 0 ? hoverValue : normalValue, _b));
|
|
129
|
+
}
|
|
130
|
+
});
|
|
131
|
+
return {
|
|
132
|
+
normalStyle: normalStyle,
|
|
133
|
+
hoverStyle: hoverStyle
|
|
134
|
+
};
|
|
378
135
|
}
|
|
136
|
+
exports.parseSlideBannerStyleToCustomPaginationProp = parseSlideBannerStyleToCustomPaginationProp;
|
|
379
137
|
function parseSlideBannerStyleToCustomNavigationProp(_a) {
|
|
380
138
|
var props = _a.props, device = _a.device;
|
|
381
|
-
var
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
var
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
var
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
var hoverValue = props[keyWithHover];
|
|
397
|
-
return {
|
|
398
|
-
normalStyle: __assign(__assign({}, acc.normalStyle), { prevBtnOffset: getCustomNavigationOffset(value) }),
|
|
399
|
-
hoverStyle: __assign(__assign({}, acc.hoverStyle), { prevBtnOffset: getCustomNavigationOffset(hoverValue !== null && hoverValue !== void 0 ? hoverValue : value) })
|
|
400
|
-
};
|
|
401
|
-
}
|
|
402
|
-
if (customNavigationPropertyKey === 'prevBtnSize') {
|
|
403
|
-
var value = props[keyWithDevice];
|
|
404
|
-
var hoverValue = props[keyWithHover];
|
|
405
|
-
return {
|
|
406
|
-
normalStyle: __assign(__assign({}, acc.normalStyle), { prevBtnSize: getCustomNavigationSize(value) }),
|
|
407
|
-
hoverStyle: __assign(__assign({}, acc.hoverStyle), { prevBtnSize: getCustomNavigationSize(hoverValue !== null && hoverValue !== void 0 ? hoverValue : value) })
|
|
408
|
-
};
|
|
409
|
-
}
|
|
410
|
-
if (customNavigationPropertyKey === 'prevBtnPrimaryColor') {
|
|
411
|
-
var value = props[keyWithDevice];
|
|
412
|
-
var hoverValue = props[keyWithHover];
|
|
413
|
-
return {
|
|
414
|
-
normalStyle: __assign(__assign({}, acc.normalStyle), { prevBtnPrimaryColor: value }),
|
|
415
|
-
hoverStyle: __assign(__assign({}, acc.hoverStyle), { prevBtnPrimaryColor: hoverValue !== null && hoverValue !== void 0 ? hoverValue : value })
|
|
416
|
-
};
|
|
417
|
-
}
|
|
418
|
-
if (customNavigationPropertyKey === 'prevBtnSecondaryColor') {
|
|
419
|
-
var value = props[keyWithDevice];
|
|
420
|
-
var hoverValue = props[keyWithHover];
|
|
421
|
-
return {
|
|
422
|
-
normalStyle: __assign(__assign({}, acc.normalStyle), { prevBtnSecondaryColor: value }),
|
|
423
|
-
hoverStyle: __assign(__assign({}, acc.hoverStyle), { prevBtnSecondaryColor: hoverValue !== null && hoverValue !== void 0 ? hoverValue : value })
|
|
424
|
-
};
|
|
139
|
+
var normalStyle = {};
|
|
140
|
+
var hoverStyle = {};
|
|
141
|
+
var baseKeys = Object.keys(props).filter(function (key) { return !key.includes(':HOVER') && !key.includes(':MOBILE'); });
|
|
142
|
+
baseKeys.forEach(function (baseKey) {
|
|
143
|
+
var _a, _b;
|
|
144
|
+
var customNavKey = getCustomNavigationPropKey(baseKey);
|
|
145
|
+
if (customNavKey) {
|
|
146
|
+
var deviceKey = device === 'DESKTOP' ? baseKey : "".concat(baseKey, ":MOBILE");
|
|
147
|
+
var hoverKey = "".concat(deviceKey, ":HOVER");
|
|
148
|
+
var normalValue = props[deviceKey];
|
|
149
|
+
var hoverValue = props[hoverKey];
|
|
150
|
+
if (normalValue !== undefined) {
|
|
151
|
+
Object.assign(normalStyle, (_a = {}, _a[customNavKey] = normalValue, _a));
|
|
152
|
+
}
|
|
153
|
+
Object.assign(hoverStyle, (_b = {}, _b[customNavKey] = hoverValue !== null && hoverValue !== void 0 ? hoverValue : normalValue, _b));
|
|
425
154
|
}
|
|
426
|
-
if (customNavigationPropertyKey === 'nextBtnType') {
|
|
427
|
-
var value = props[keyWithDevice];
|
|
428
|
-
var hoverValue = props[keyWithHover];
|
|
429
|
-
return {
|
|
430
|
-
normalStyle: __assign(__assign({}, acc.normalStyle), { nextBtnType: value }),
|
|
431
|
-
hoverStyle: __assign(__assign({}, acc.hoverStyle), { nextBtnType: hoverValue !== null && hoverValue !== void 0 ? hoverValue : value })
|
|
432
|
-
};
|
|
433
|
-
}
|
|
434
|
-
if (customNavigationPropertyKey === 'nextBtnOffset') {
|
|
435
|
-
var value = props[keyWithDevice];
|
|
436
|
-
var hoverValue = props[keyWithHover];
|
|
437
|
-
return {
|
|
438
|
-
normalStyle: __assign(__assign({}, acc.normalStyle), { nextBtnOffset: getCustomNavigationOffset(value) }),
|
|
439
|
-
hoverStyle: __assign(__assign({}, acc.hoverStyle), { nextBtnOffset: getCustomNavigationOffset(hoverValue !== null && hoverValue !== void 0 ? hoverValue : value) })
|
|
440
|
-
};
|
|
441
|
-
}
|
|
442
|
-
if (customNavigationPropertyKey === 'nextBtnSize') {
|
|
443
|
-
var value = props[keyWithDevice];
|
|
444
|
-
var hoverValue = props[keyWithHover];
|
|
445
|
-
return {
|
|
446
|
-
normalStyle: __assign(__assign({}, acc.normalStyle), { nextBtnSize: getCustomNavigationSize(value) }),
|
|
447
|
-
hoverStyle: __assign(__assign({}, acc.hoverStyle), { nextBtnSize: getCustomNavigationSize(hoverValue !== null && hoverValue !== void 0 ? hoverValue : value) })
|
|
448
|
-
};
|
|
449
|
-
}
|
|
450
|
-
if (customNavigationPropertyKey === 'nextBtnPrimaryColor') {
|
|
451
|
-
var value = props[keyWithDevice];
|
|
452
|
-
var hoverValue = props[keyWithHover];
|
|
453
|
-
return {
|
|
454
|
-
normalStyle: __assign(__assign({}, acc.normalStyle), { nextBtnPrimaryColor: value }),
|
|
455
|
-
hoverStyle: __assign(__assign({}, acc.hoverStyle), { nextBtnPrimaryColor: hoverValue !== null && hoverValue !== void 0 ? hoverValue : value })
|
|
456
|
-
};
|
|
457
|
-
}
|
|
458
|
-
if (customNavigationPropertyKey === 'nextBtnSecondaryColor') {
|
|
459
|
-
var value = props[keyWithDevice];
|
|
460
|
-
var hoverValue = props[keyWithHover];
|
|
461
|
-
return {
|
|
462
|
-
normalStyle: __assign(__assign({}, acc.normalStyle), { nextBtnSecondaryColor: value }),
|
|
463
|
-
hoverStyle: __assign(__assign({}, acc.hoverStyle), { nextBtnSecondaryColor: hoverValue !== null && hoverValue !== void 0 ? hoverValue : value })
|
|
464
|
-
};
|
|
465
|
-
}
|
|
466
|
-
return {
|
|
467
|
-
normalStyle: __assign({}, acc.normalStyle),
|
|
468
|
-
hoverStyle: __assign({}, acc.hoverStyle)
|
|
469
|
-
};
|
|
470
|
-
}, {
|
|
471
|
-
normalStyle: {},
|
|
472
|
-
hoverStyle: {}
|
|
473
155
|
});
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
switch (key) {
|
|
478
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PREVBTNSTYLE":
|
|
479
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PREVBTNSTYLE:HOVER":
|
|
480
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PREVBTNSTYLE:MOBILE":
|
|
481
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PREVBTNSTYLE:MOBILE:HOVER":
|
|
482
|
-
return 'prevBtnType';
|
|
483
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PREVBTNLOCATION":
|
|
484
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PREVBTNLOCATION:HOVER":
|
|
485
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PREVBTNLOCATION:MOBILE":
|
|
486
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PREVBTNLOCATION:MOBILE:HOVER":
|
|
487
|
-
return 'prevBtnOffset';
|
|
488
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PREVBTNSIZE":
|
|
489
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PREVBTNSIZE:HOVER":
|
|
490
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PREVBTNSIZE:MOBILE":
|
|
491
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PREVBTNSIZE:MOBILE:HOVER":
|
|
492
|
-
return 'prevBtnSize';
|
|
493
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PREVBTNPRIMARYCOLOR":
|
|
494
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PREVBTNPRIMARYCOLOR:HOVER":
|
|
495
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PREVBTNPRIMARYCOLOR:MOBILE":
|
|
496
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PREVBTNPRIMARYCOLOR:MOBILE:HOVER":
|
|
497
|
-
return 'prevBtnPrimaryColor';
|
|
498
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PREVBTNSECONDARYCOLOR":
|
|
499
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PREVBTNSECONDARYCOLOR:HOVER":
|
|
500
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PREVBTNSECONDARYCOLOR:MOBILE":
|
|
501
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PREVBTNSECONDARYCOLOR:MOBILE:HOVER":
|
|
502
|
-
return 'prevBtnSecondaryColor';
|
|
503
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_NEXTBTNSTYLE":
|
|
504
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_NEXTBTNSTYLE:HOVER":
|
|
505
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_NEXTBTNSTYLE:MOBILE":
|
|
506
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_NEXTBTNSTYLE:MOBILE:HOVER":
|
|
507
|
-
return 'nextBtnType';
|
|
508
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_NEXTBTNLOCATION":
|
|
509
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_NEXTBTNLOCATION:HOVER":
|
|
510
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_NEXTBTNLOCATION:MOBILE":
|
|
511
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_NEXTBTNLOCATION:MOBILE:HOVER":
|
|
512
|
-
return 'nextBtnOffset';
|
|
513
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_NEXTBTNSIZE":
|
|
514
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_NEXTBTNSIZE:HOVER":
|
|
515
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_NEXTBTNSIZE:MOBILE":
|
|
516
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_NEXTBTNSIZE:MOBILE:HOVER":
|
|
517
|
-
return 'nextBtnSize';
|
|
518
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_NEXTBTNPRIMARYCOLOR":
|
|
519
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_NEXTBTNPRIMARYCOLOR:HOVER":
|
|
520
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_NEXTBTNPRIMARYCOLOR:MOBILE":
|
|
521
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_NEXTBTNPRIMARYCOLOR:MOBILE:HOVER":
|
|
522
|
-
return 'nextBtnPrimaryColor';
|
|
523
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_NEXTBTNSECONDARYCOLOR":
|
|
524
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_NEXTBTNSECONDARYCOLOR:HOVER":
|
|
525
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_NEXTBTNSECONDARYCOLOR:MOBILE":
|
|
526
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_NEXTBTNSECONDARYCOLOR:MOBILE:HOVER":
|
|
527
|
-
return 'nextBtnSecondaryColor';
|
|
528
|
-
default:
|
|
529
|
-
return '';
|
|
530
|
-
}
|
|
531
|
-
}
|
|
532
|
-
exports.getCustomNavigationPropKey = getCustomNavigationPropKey;
|
|
533
|
-
function getCustomNavigationOffset(value) {
|
|
534
|
-
var OUTSET1 = {
|
|
535
|
-
top: '0px',
|
|
536
|
-
left: '0px',
|
|
537
|
-
translateX: 0,
|
|
538
|
-
translateY: -100,
|
|
539
|
-
transformOrigin: 'top left'
|
|
156
|
+
return {
|
|
157
|
+
normalStyle: normalStyle,
|
|
158
|
+
hoverStyle: hoverStyle
|
|
540
159
|
};
|
|
541
|
-
switch (value) {
|
|
542
|
-
case 'OUTSET1':
|
|
543
|
-
return OUTSET1;
|
|
544
|
-
case 'OUTSET2':
|
|
545
|
-
return {
|
|
546
|
-
top: '0px',
|
|
547
|
-
left: '50%',
|
|
548
|
-
translateX: -50,
|
|
549
|
-
translateY: -100,
|
|
550
|
-
transformOrigin: 'top left'
|
|
551
|
-
};
|
|
552
|
-
case 'OUTSET3':
|
|
553
|
-
return {
|
|
554
|
-
top: '0px',
|
|
555
|
-
left: '100%',
|
|
556
|
-
translateX: -100,
|
|
557
|
-
translateY: -100,
|
|
558
|
-
transformOrigin: 'top left'
|
|
559
|
-
};
|
|
560
|
-
case 'OUTSET4':
|
|
561
|
-
return {
|
|
562
|
-
top: '0px',
|
|
563
|
-
left: '100%',
|
|
564
|
-
translateX: 0,
|
|
565
|
-
translateY: 0,
|
|
566
|
-
transformOrigin: 'left top'
|
|
567
|
-
};
|
|
568
|
-
case 'OUTSET5':
|
|
569
|
-
return {
|
|
570
|
-
top: '50%',
|
|
571
|
-
left: '100%',
|
|
572
|
-
translateX: 0,
|
|
573
|
-
translateY: -50,
|
|
574
|
-
transformOrigin: 'left top'
|
|
575
|
-
};
|
|
576
|
-
case 'OUTSET6':
|
|
577
|
-
return {
|
|
578
|
-
top: '100%',
|
|
579
|
-
left: '100%',
|
|
580
|
-
translateX: 0,
|
|
581
|
-
translateY: -100,
|
|
582
|
-
transformOrigin: 'left top'
|
|
583
|
-
};
|
|
584
|
-
case 'OUTSET7':
|
|
585
|
-
return {
|
|
586
|
-
top: '100%',
|
|
587
|
-
left: '100%',
|
|
588
|
-
translateX: -100,
|
|
589
|
-
translateY: 0,
|
|
590
|
-
transformOrigin: 'top left'
|
|
591
|
-
};
|
|
592
|
-
case 'OUTSET8':
|
|
593
|
-
return {
|
|
594
|
-
top: '100%',
|
|
595
|
-
left: '50%',
|
|
596
|
-
translateX: -50,
|
|
597
|
-
translateY: 0,
|
|
598
|
-
transformOrigin: 'top left'
|
|
599
|
-
};
|
|
600
|
-
case 'OUTSET9':
|
|
601
|
-
return {
|
|
602
|
-
top: '100%',
|
|
603
|
-
left: '0px',
|
|
604
|
-
translateX: 0,
|
|
605
|
-
translateY: 0,
|
|
606
|
-
transformOrigin: 'top left'
|
|
607
|
-
};
|
|
608
|
-
case 'OUTSET10':
|
|
609
|
-
return {
|
|
610
|
-
top: '100%',
|
|
611
|
-
left: '0px',
|
|
612
|
-
translateX: -100,
|
|
613
|
-
translateY: -100,
|
|
614
|
-
transformOrigin: 'right top'
|
|
615
|
-
};
|
|
616
|
-
case 'OUTSET11':
|
|
617
|
-
return {
|
|
618
|
-
top: '50%',
|
|
619
|
-
left: '0px',
|
|
620
|
-
translateX: -100,
|
|
621
|
-
translateY: -50,
|
|
622
|
-
transformOrigin: 'right top'
|
|
623
|
-
};
|
|
624
|
-
case 'OUTSET12':
|
|
625
|
-
return {
|
|
626
|
-
top: '0px',
|
|
627
|
-
left: '0px',
|
|
628
|
-
translateX: -100,
|
|
629
|
-
translateY: 0,
|
|
630
|
-
transformOrigin: 'right top'
|
|
631
|
-
};
|
|
632
|
-
case 'INSET1':
|
|
633
|
-
return { top: '0px', left: '0px', translateX: 0, translateY: 0, transformOrigin: 'left top' };
|
|
634
|
-
case 'INSET2':
|
|
635
|
-
return {
|
|
636
|
-
top: '0px',
|
|
637
|
-
left: '50%',
|
|
638
|
-
translateX: -50,
|
|
639
|
-
translateY: 0,
|
|
640
|
-
transformOrigin: 'left top'
|
|
641
|
-
};
|
|
642
|
-
case 'INSET3':
|
|
643
|
-
return {
|
|
644
|
-
top: '0px',
|
|
645
|
-
left: '100%',
|
|
646
|
-
translateX: -100,
|
|
647
|
-
translateY: 0,
|
|
648
|
-
transformOrigin: 'left top'
|
|
649
|
-
};
|
|
650
|
-
case 'INSET4':
|
|
651
|
-
return {
|
|
652
|
-
top: '50%',
|
|
653
|
-
left: '100%',
|
|
654
|
-
translateX: -100,
|
|
655
|
-
translateY: -50,
|
|
656
|
-
transformOrigin: 'left top'
|
|
657
|
-
};
|
|
658
|
-
case 'INSET5':
|
|
659
|
-
return {
|
|
660
|
-
top: '100%',
|
|
661
|
-
left: '100%',
|
|
662
|
-
translateX: -100,
|
|
663
|
-
translateY: -100,
|
|
664
|
-
transformOrigin: 'left top'
|
|
665
|
-
};
|
|
666
|
-
case 'INSET6':
|
|
667
|
-
return {
|
|
668
|
-
top: '100%',
|
|
669
|
-
left: '50%',
|
|
670
|
-
translateX: -50,
|
|
671
|
-
translateY: -100,
|
|
672
|
-
transformOrigin: 'left top'
|
|
673
|
-
};
|
|
674
|
-
case 'INSET7':
|
|
675
|
-
return {
|
|
676
|
-
top: '100%',
|
|
677
|
-
left: '0px',
|
|
678
|
-
translateX: 0,
|
|
679
|
-
translateY: -100,
|
|
680
|
-
transformOrigin: 'top left'
|
|
681
|
-
};
|
|
682
|
-
case 'INSET8':
|
|
683
|
-
return {
|
|
684
|
-
top: '50%',
|
|
685
|
-
left: '0px',
|
|
686
|
-
translateX: 0,
|
|
687
|
-
translateY: -50,
|
|
688
|
-
transformOrigin: 'top left'
|
|
689
|
-
};
|
|
690
|
-
default:
|
|
691
|
-
return OUTSET1;
|
|
692
|
-
}
|
|
693
|
-
}
|
|
694
|
-
function getCustomNavigationSize(value) {
|
|
695
|
-
switch (value) {
|
|
696
|
-
case 'SMALL':
|
|
697
|
-
return 1;
|
|
698
|
-
case 'MEDIUM':
|
|
699
|
-
return 1.5;
|
|
700
|
-
case 'LARGE':
|
|
701
|
-
return 3;
|
|
702
|
-
default:
|
|
703
|
-
return 2;
|
|
704
|
-
}
|
|
705
160
|
}
|
|
161
|
+
exports.parseSlideBannerStyleToCustomNavigationProp = parseSlideBannerStyleToCustomNavigationProp;
|
|
706
162
|
function parseSlideBannerStyleToCustomProgressbarProp(_a) {
|
|
707
163
|
var props = _a.props, device = _a.device;
|
|
708
|
-
var
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
var
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
var
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
164
|
+
var normalStyle = {};
|
|
165
|
+
var hoverStyle = {};
|
|
166
|
+
var baseKeys = Object.keys(props).filter(function (key) { return !key.includes(':HOVER') && !key.includes(':MOBILE'); });
|
|
167
|
+
baseKeys.forEach(function (baseKey) {
|
|
168
|
+
var _a, _b;
|
|
169
|
+
var customNavKey = getCustomProgressbarPropKey(baseKey);
|
|
170
|
+
if (customNavKey) {
|
|
171
|
+
var deviceKey = device === 'DESKTOP' ? baseKey : "".concat(baseKey, ":MOBILE");
|
|
172
|
+
var hoverKey = "".concat(deviceKey, ":HOVER");
|
|
173
|
+
var normalValue = props[deviceKey];
|
|
174
|
+
var hoverValue = props[hoverKey];
|
|
175
|
+
if (normalValue !== undefined) {
|
|
176
|
+
Object.assign(normalStyle, (_a = {}, _a[customNavKey] = normalValue, _a));
|
|
177
|
+
}
|
|
178
|
+
Object.assign(hoverStyle, (_b = {}, _b[customNavKey] = hoverValue !== null && hoverValue !== void 0 ? hoverValue : normalValue, _b));
|
|
720
179
|
}
|
|
721
|
-
if (customProgressbarPropertyKey === 'size') {
|
|
722
|
-
var value = props[keyWithDevice];
|
|
723
|
-
var hoverValue = props[keyWithHover];
|
|
724
|
-
var offset = getCustomProgressbarOffset('INSET5');
|
|
725
|
-
return {
|
|
726
|
-
normalStyle: __assign(__assign({}, acc.normalStyle), { size: getCustomProgressbarSize(value), offset: offset }),
|
|
727
|
-
hoverStyle: __assign(__assign({}, acc.hoverStyle), { size: getCustomProgressbarSize(hoverValue !== null && hoverValue !== void 0 ? hoverValue : value), offset: offset })
|
|
728
|
-
};
|
|
729
|
-
}
|
|
730
|
-
if (customProgressbarPropertyKey === 'primaryColor') {
|
|
731
|
-
var value = props[keyWithDevice];
|
|
732
|
-
var hoverValue = props[keyWithHover];
|
|
733
|
-
return {
|
|
734
|
-
normalStyle: __assign(__assign({}, acc.normalStyle), { primaryColor: value }),
|
|
735
|
-
hoverStyle: __assign(__assign({}, acc.hoverStyle), { primaryColor: hoverValue !== null && hoverValue !== void 0 ? hoverValue : value })
|
|
736
|
-
};
|
|
737
|
-
}
|
|
738
|
-
if (customProgressbarPropertyKey === 'secondaryColor') {
|
|
739
|
-
var value = props[keyWithDevice];
|
|
740
|
-
var hoverValue = props[keyWithHover];
|
|
741
|
-
return {
|
|
742
|
-
normalStyle: __assign(__assign({}, acc.normalStyle), { secondaryColor: value }),
|
|
743
|
-
hoverStyle: __assign(__assign({}, acc.hoverStyle), { secondaryColor: hoverValue !== null && hoverValue !== void 0 ? hoverValue : value })
|
|
744
|
-
};
|
|
745
|
-
}
|
|
746
|
-
return {
|
|
747
|
-
normalStyle: __assign({}, acc.normalStyle),
|
|
748
|
-
hoverStyle: __assign({}, acc.hoverStyle)
|
|
749
|
-
};
|
|
750
|
-
}, {
|
|
751
|
-
normalStyle: {},
|
|
752
|
-
hoverStyle: {}
|
|
753
180
|
});
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
switch (key) {
|
|
758
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PROGRESSBAR":
|
|
759
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PROGRESSBAR:HOVER":
|
|
760
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PROGRESSBAR:MOBILE":
|
|
761
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PROGRESSBAR:MOBILE:HOVER":
|
|
762
|
-
return 'type';
|
|
763
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PROGRESSBARSIZE":
|
|
764
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PROGRESSBARSIZE:HOVER":
|
|
765
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PROGRESSBARSIZE:MOBILE":
|
|
766
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PROGRESSBARSIZE:MOBILE:HOVER":
|
|
767
|
-
return 'size';
|
|
768
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PROGRESSBARPRIMARYCOLOR":
|
|
769
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PROGRESSBARPRIMARYCOLOR:HOVER":
|
|
770
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PROGRESSBARPRIMARYCOLOR:MOBILE":
|
|
771
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PROGRESSBARPRIMARYCOLOR:MOBILE:HOVER":
|
|
772
|
-
return 'primaryColor';
|
|
773
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PROGRESSBARSECONDARYCOLOR":
|
|
774
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PROGRESSBARSECONDARYCOLOR:HOVER":
|
|
775
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PROGRESSBARSECONDARYCOLOR:MOBILE":
|
|
776
|
-
case "CB_STYLE_PROP_SLIDEBANNER_SPEC_PROGRESSBARSECONDARYCOLOR:MOBILE:HOVER":
|
|
777
|
-
return 'secondaryColor';
|
|
778
|
-
default:
|
|
779
|
-
return '';
|
|
780
|
-
}
|
|
781
|
-
}
|
|
782
|
-
exports.getCustomProgressbarPropKey = getCustomProgressbarPropKey;
|
|
783
|
-
function getCustomProgressbarOffset(value) {
|
|
784
|
-
var OUTSET1 = {
|
|
785
|
-
top: '0px',
|
|
786
|
-
left: '0px',
|
|
787
|
-
translateX: 0,
|
|
788
|
-
translateY: -100,
|
|
789
|
-
transformOrigin: 'top left'
|
|
181
|
+
return {
|
|
182
|
+
normalStyle: normalStyle,
|
|
183
|
+
hoverStyle: hoverStyle
|
|
790
184
|
};
|
|
791
|
-
switch (value) {
|
|
792
|
-
case 'OUTSET1':
|
|
793
|
-
return OUTSET1;
|
|
794
|
-
case 'OUTSET2':
|
|
795
|
-
return {
|
|
796
|
-
top: '0px',
|
|
797
|
-
left: '50%',
|
|
798
|
-
translateX: -50,
|
|
799
|
-
translateY: -100,
|
|
800
|
-
transformOrigin: 'top left'
|
|
801
|
-
};
|
|
802
|
-
case 'OUTSET3':
|
|
803
|
-
return {
|
|
804
|
-
top: '0px',
|
|
805
|
-
right: '0px',
|
|
806
|
-
translateX: 0,
|
|
807
|
-
translateY: -100,
|
|
808
|
-
transformOrigin: 'top right'
|
|
809
|
-
};
|
|
810
|
-
case 'OUTSET4':
|
|
811
|
-
return {
|
|
812
|
-
top: '0px',
|
|
813
|
-
left: '100%',
|
|
814
|
-
translateX: 0,
|
|
815
|
-
translateY: 0,
|
|
816
|
-
transformOrigin: 'left top'
|
|
817
|
-
};
|
|
818
|
-
case 'OUTSET5':
|
|
819
|
-
return {
|
|
820
|
-
top: '50%',
|
|
821
|
-
left: '100%',
|
|
822
|
-
translateX: 0,
|
|
823
|
-
translateY: -50,
|
|
824
|
-
transformOrigin: 'left top'
|
|
825
|
-
};
|
|
826
|
-
case 'OUTSET6':
|
|
827
|
-
return {
|
|
828
|
-
top: '100%',
|
|
829
|
-
left: '100%',
|
|
830
|
-
translateX: 0,
|
|
831
|
-
translateY: -100,
|
|
832
|
-
transformOrigin: 'left top'
|
|
833
|
-
};
|
|
834
|
-
case 'OUTSET7':
|
|
835
|
-
return {
|
|
836
|
-
top: '100%',
|
|
837
|
-
left: '100%',
|
|
838
|
-
translateX: -100,
|
|
839
|
-
translateY: 0,
|
|
840
|
-
transformOrigin: 'top left'
|
|
841
|
-
};
|
|
842
|
-
case 'OUTSET8':
|
|
843
|
-
return {
|
|
844
|
-
top: '100%',
|
|
845
|
-
left: '50%',
|
|
846
|
-
translateX: -50,
|
|
847
|
-
translateY: 0,
|
|
848
|
-
transformOrigin: 'top left'
|
|
849
|
-
};
|
|
850
|
-
case 'OUTSET9':
|
|
851
|
-
return {
|
|
852
|
-
top: '100%',
|
|
853
|
-
left: '0px',
|
|
854
|
-
translateX: 0,
|
|
855
|
-
translateY: 0,
|
|
856
|
-
transformOrigin: 'top left'
|
|
857
|
-
};
|
|
858
|
-
case 'OUTSET10':
|
|
859
|
-
return {
|
|
860
|
-
top: '100%',
|
|
861
|
-
left: '0px',
|
|
862
|
-
translateX: -100,
|
|
863
|
-
translateY: -100,
|
|
864
|
-
transformOrigin: 'right top'
|
|
865
|
-
};
|
|
866
|
-
case 'OUTSET11':
|
|
867
|
-
return {
|
|
868
|
-
top: '50%',
|
|
869
|
-
left: '0px',
|
|
870
|
-
translateX: -100,
|
|
871
|
-
translateY: -50,
|
|
872
|
-
transformOrigin: 'right top'
|
|
873
|
-
};
|
|
874
|
-
case 'OUTSET12':
|
|
875
|
-
return {
|
|
876
|
-
top: '0px',
|
|
877
|
-
left: '0px',
|
|
878
|
-
translateX: -100,
|
|
879
|
-
translateY: 0,
|
|
880
|
-
transformOrigin: 'right top'
|
|
881
|
-
};
|
|
882
|
-
case 'INSET1':
|
|
883
|
-
return { top: '0px', left: '0px', translateX: 0, translateY: 0, transformOrigin: 'left top' };
|
|
884
|
-
case 'INSET2':
|
|
885
|
-
return {
|
|
886
|
-
top: '0px',
|
|
887
|
-
left: '50%',
|
|
888
|
-
translateX: -50,
|
|
889
|
-
translateY: 0,
|
|
890
|
-
transformOrigin: 'left top'
|
|
891
|
-
};
|
|
892
|
-
case 'INSET3':
|
|
893
|
-
return {
|
|
894
|
-
top: '0px',
|
|
895
|
-
left: '100%',
|
|
896
|
-
translateX: -100,
|
|
897
|
-
translateY: 0,
|
|
898
|
-
transformOrigin: 'left top'
|
|
899
|
-
};
|
|
900
|
-
case 'INSET4':
|
|
901
|
-
return {
|
|
902
|
-
top: '50%',
|
|
903
|
-
left: '100%',
|
|
904
|
-
translateX: -100,
|
|
905
|
-
translateY: -50,
|
|
906
|
-
transformOrigin: 'left top'
|
|
907
|
-
};
|
|
908
|
-
case 'INSET5':
|
|
909
|
-
return {
|
|
910
|
-
top: '100%',
|
|
911
|
-
left: '100%',
|
|
912
|
-
translateX: -100,
|
|
913
|
-
translateY: -100,
|
|
914
|
-
transformOrigin: 'left top'
|
|
915
|
-
};
|
|
916
|
-
case 'INSET6':
|
|
917
|
-
return {
|
|
918
|
-
top: '100%',
|
|
919
|
-
left: '50%',
|
|
920
|
-
translateX: -50,
|
|
921
|
-
translateY: -100,
|
|
922
|
-
transformOrigin: 'left top'
|
|
923
|
-
};
|
|
924
|
-
case 'INSET7':
|
|
925
|
-
return {
|
|
926
|
-
top: '100%',
|
|
927
|
-
left: '0px',
|
|
928
|
-
translateX: 0,
|
|
929
|
-
translateY: -100,
|
|
930
|
-
transformOrigin: 'top left'
|
|
931
|
-
};
|
|
932
|
-
case 'INSET8':
|
|
933
|
-
return {
|
|
934
|
-
top: '50%',
|
|
935
|
-
left: '0px',
|
|
936
|
-
translateX: 0,
|
|
937
|
-
translateY: -50,
|
|
938
|
-
transformOrigin: 'top left'
|
|
939
|
-
};
|
|
940
|
-
default:
|
|
941
|
-
return OUTSET1;
|
|
942
|
-
}
|
|
943
|
-
}
|
|
944
|
-
function getCustomProgressbarSize(value) {
|
|
945
|
-
switch (value) {
|
|
946
|
-
case 'SMALL':
|
|
947
|
-
return 1;
|
|
948
|
-
case 'MEDIUM':
|
|
949
|
-
return 1.5;
|
|
950
|
-
case 'LARGE':
|
|
951
|
-
return 2;
|
|
952
|
-
default:
|
|
953
|
-
return 1;
|
|
954
|
-
}
|
|
955
185
|
}
|
|
956
|
-
|
|
186
|
+
exports.parseSlideBannerStyleToCustomProgressbarProp = parseSlideBannerStyleToCustomProgressbarProp;
|