@sc-360-v2/storefront-cms-library 0.0.7 → 0.0.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (34) hide show
  1. package/dist/builder.js +1 -1
  2. package/dist/css.js +1 -1
  3. package/dist/icons.js +1 -1
  4. package/dist/index.js +1 -1
  5. package/dist/types/builder/elements/common.d.ts +2 -0
  6. package/dist/types/builder/elements/container/index.d.ts +42 -0
  7. package/dist/types/builder/elements/countdown/index.d.ts +26 -0
  8. package/dist/types/builder/elements/embed/index.d.ts +59 -0
  9. package/dist/types/builder/elements/grid/index.d.ts +1 -1
  10. package/dist/types/builder/elements/image-hotspot/index.d.ts +30 -0
  11. package/dist/types/builder/elements/map/index.d.ts +30 -0
  12. package/dist/types/builder/elements/scroll/index.d.ts +26 -0
  13. package/dist/types/builder/elements/table/index.d.ts +1 -5
  14. package/dist/types/builder/enums/index.d.ts +46 -6
  15. package/dist/types/builder/index.d.ts +7 -1
  16. package/dist/types/builder/interfaces/global.d.ts +9 -0
  17. package/dist/types/builder/tools/element-edit/button.d.ts +1 -0
  18. package/dist/types/builder/tools/element-edit/buttonv2.d.ts +26 -0
  19. package/dist/types/builder/tools/element-edit/common.d.ts +19 -2
  20. package/dist/types/builder/tools/element-edit/container.d.ts +15 -0
  21. package/dist/types/builder/tools/element-edit/countdown.d.ts +300 -0
  22. package/dist/types/builder/tools/element-edit/faq.d.ts +39 -7
  23. package/dist/types/builder/tools/element-edit/gallery-slider.d.ts +32 -0
  24. package/dist/types/builder/tools/element-edit/imageHotspot.d.ts +154 -0
  25. package/dist/types/builder/tools/element-edit/index.d.ts +7 -1
  26. package/dist/types/builder/tools/element-edit/map.d.ts +122 -0
  27. package/dist/types/builder/tools/element-edit/scroll.d.ts +219 -0
  28. package/dist/types/builder/tools/element-edit/social.d.ts +228 -4
  29. package/dist/types/builder/tools/element-edit/table.d.ts +8 -4
  30. package/dist/types/builder/tools/element-edit/text.d.ts +1 -2
  31. package/dist/types/builder/tools/element-edit/video.d.ts +212 -4
  32. package/dist/types/global/types.d.ts +2 -2
  33. package/package.json +1 -1
  34. package/dist/faq.scss +0 -136
@@ -1,5 +1,6 @@
1
+ import { CMSElementEditTypes } from "../../enums";
1
2
  import { CMSIBCommonInterface } from "../../interfaces/global";
2
- import { CMSElementEditPopupInterface, CMSElementEditPopupLayoutInterface } from "./common";
3
+ import { CMSElementEditPopupInterface } from "./common";
3
4
  export interface SectionEditPopupInterface extends CMSElementEditPopupInterface {
4
5
  }
5
6
  interface ControlInterface {
@@ -32,7 +33,6 @@ export interface VideoControlInterface {
32
33
  selectorKey?: string;
33
34
  icon?: CMSIBCommonInterface;
34
35
  iconSize?: CMSIBCommonInterface;
35
- iconColor?: CMSIBCommonInterface;
36
36
  };
37
37
  video?: {
38
38
  selectorKey?: string;
@@ -60,7 +60,11 @@ export declare enum VideoSelectorKeysEnum {
60
60
  CONTENT = "content",
61
61
  VIDEO_PLAYER_TEXT = "videoPlayerText",
62
62
  PLAY_PAUSE = "playPause",
63
- VIDEO = "video"
63
+ VIDEO = "video",
64
+ VIDEO_WIDGET_LAYOUT = "videoWidgetLayout",
65
+ VIDEO_WIDGET_DESIGN = "videoWidgetDesign",
66
+ VIDEO_TEXT_LAYOUT = "videoTextLayout",
67
+ VIDEO_TEXT_CONTAINER_DESIGN = "videoTextContainerDesign"
64
68
  }
65
69
  export interface SelectorKeys {
66
70
  LAYOUT: string;
@@ -70,5 +74,209 @@ export interface SelectorKeys {
70
74
  PLAY_PAUSE: string;
71
75
  VIDEO: string;
72
76
  }
73
- export declare const getDefaultData: () => CMSVideoEditPopupInterface<VideoControlInterface & VideoControlInterface & VideoControlInterface & CMSElementEditPopupLayoutInterface>;
77
+ export declare const getDefaultData: () => {
78
+ layout: {
79
+ selectorKey: VideoSelectorKeysEnum;
80
+ width: {
81
+ value: string;
82
+ unit: number;
83
+ };
84
+ height: {
85
+ value: string;
86
+ unit: number;
87
+ property?: any;
88
+ propertyType?: any;
89
+ isReadOnly?: boolean | undefined;
90
+ parentRef?: string | undefined;
91
+ };
92
+ margin: import("../../interfaces/global").CSSPaddingValues | undefined;
93
+ padding: {
94
+ value: string;
95
+ unit: number;
96
+ isAll?: boolean | undefined;
97
+ sides?: import("../../interfaces/global").PaddingSides | import("../../interfaces/global").BorderSides | undefined;
98
+ property?: string | undefined;
99
+ iscss?: boolean | undefined;
100
+ propertyType?: any;
101
+ };
102
+ autoplay: {
103
+ value: string;
104
+ propertyType: CMSElementEditTypes;
105
+ };
106
+ showControls: {
107
+ value: string;
108
+ propertyType: CMSElementEditTypes;
109
+ };
110
+ loopVideo: {
111
+ value: boolean;
112
+ propertyType: CMSElementEditTypes;
113
+ };
114
+ loopCount: {
115
+ value: number;
116
+ propertyType: CMSElementEditTypes;
117
+ };
118
+ positionType: CMSIBCommonInterface | undefined;
119
+ pinTo: CMSIBCommonInterface | undefined;
120
+ };
121
+ content: {
122
+ selectorKey: VideoSelectorKeysEnum;
123
+ videoFile: {
124
+ value: string;
125
+ propertyType: CMSElementEditTypes;
126
+ };
127
+ showVideoTitle: {
128
+ value: boolean;
129
+ propertyType: CMSElementEditTypes;
130
+ };
131
+ videoTitle: {
132
+ value: string;
133
+ propertyType: CMSElementEditTypes;
134
+ };
135
+ showVideoDescription: {
136
+ value: boolean;
137
+ propertyType: CMSElementEditTypes;
138
+ };
139
+ videoDescription: {
140
+ value: string;
141
+ propertyType: CMSElementEditTypes;
142
+ };
143
+ showCustomVideoThumbnail: {
144
+ value: boolean;
145
+ propertyType: CMSElementEditTypes;
146
+ };
147
+ thumbnailImage: {
148
+ value: string;
149
+ propertyType: CMSElementEditTypes;
150
+ };
151
+ image: {
152
+ value: {
153
+ src: string;
154
+ };
155
+ propertyType: CMSElementEditTypes;
156
+ };
157
+ };
158
+ design: {
159
+ selectorKey: VideoSelectorKeysEnum;
160
+ videoWidgetLayout: {
161
+ selectorKey: VideoSelectorKeysEnum;
162
+ verticalAlignment: {
163
+ value: string;
164
+ property: string;
165
+ propertyType: CMSElementEditTypes;
166
+ };
167
+ widgetTextAndItemSpacing: {
168
+ value: string;
169
+ property: string;
170
+ unit: number;
171
+ propertyType: CMSElementEditTypes;
172
+ };
173
+ textPosition: {
174
+ value: string;
175
+ property: string;
176
+ propertyType: CMSElementEditTypes;
177
+ };
178
+ };
179
+ videoWidgetDesign: {
180
+ selectorKey: VideoSelectorKeysEnum;
181
+ backgroundColor: CMSIBCommonInterface;
182
+ borderColor: CMSIBCommonInterface;
183
+ borderStyle: CMSIBCommonInterface;
184
+ borderPerSlide: import("../../interfaces/global").CSSPaddingValues;
185
+ showBorder: CMSIBCommonInterface;
186
+ showShadow: CMSIBCommonInterface;
187
+ shadowColor: CMSIBCommonInterface;
188
+ blur: import("../../interfaces/global").CMSIBSizeInterface;
189
+ spread: import("../../interfaces/global").CMSIBSizeInterface;
190
+ angle: import("../../interfaces/global").CMSIBSizeInterface;
191
+ borderRadius: import("../../interfaces/global").CSSPaddingValues;
192
+ showIcon: CMSIBCommonInterface | undefined;
193
+ iconSize: import("../../interfaces/global").CMSIBSizeInterface;
194
+ iconColor: CMSIBCommonInterface;
195
+ theme: CMSIBCommonInterface;
196
+ font: CMSIBCommonInterface;
197
+ fontSize: import("../../interfaces/global").CMSIBSizeInterface;
198
+ textColor: CMSIBCommonInterface;
199
+ bold: CMSIBCommonInterface;
200
+ italic: CMSIBCommonInterface;
201
+ linethrough: CMSIBCommonInterface;
202
+ underline: CMSIBCommonInterface;
203
+ textAlign: CMSIBCommonInterface;
204
+ characterSpacing: import("../../interfaces/global").CMSIBSizeInterface;
205
+ lineHeight: import("../../interfaces/global").CMSIBSizeInterface;
206
+ themeDesc: CMSIBCommonInterface;
207
+ fontDesc: CMSIBCommonInterface;
208
+ fontSizeDesc: import("../../interfaces/global").CMSIBSizeInterface;
209
+ textColorDesc: CMSIBCommonInterface;
210
+ boldDesc: CMSIBCommonInterface;
211
+ italicDesc: CMSIBCommonInterface;
212
+ linethroughDesc: CMSIBCommonInterface;
213
+ underlineDesc: CMSIBCommonInterface;
214
+ textAlignDesc: CMSIBCommonInterface;
215
+ characterSpacingDesc: import("../../interfaces/global").CMSIBSizeInterface | undefined;
216
+ lineHeightDesc: import("../../interfaces/global").CMSIBSizeInterface;
217
+ };
218
+ videoTextLayout: {
219
+ selectorKey: VideoSelectorKeysEnum;
220
+ textVerticalPadding: {
221
+ value: string;
222
+ property: string;
223
+ unit: number;
224
+ propertyType: CMSElementEditTypes;
225
+ };
226
+ textHorizontalPadding: {
227
+ value: string;
228
+ property: string;
229
+ unit: number;
230
+ propertyType: CMSElementEditTypes;
231
+ };
232
+ titleAndDescriptionSpacing: {
233
+ value: string;
234
+ property: string;
235
+ unit: number;
236
+ propertyType: CMSElementEditTypes;
237
+ };
238
+ };
239
+ videoTextContainerDesign: {
240
+ selectorKey: VideoSelectorKeysEnum;
241
+ backgroundColor: CMSIBCommonInterface;
242
+ showBorder: CMSIBCommonInterface;
243
+ borderStyle: CMSIBCommonInterface;
244
+ borderColor: CMSIBCommonInterface;
245
+ borderPerSlide: import("../../interfaces/global").CSSPaddingValues;
246
+ borderRadius: import("../../interfaces/global").CSSPaddingValues;
247
+ showShadow: CMSIBCommonInterface;
248
+ shadowColor: CMSIBCommonInterface;
249
+ angle: import("../../interfaces/global").CMSIBSizeInterface;
250
+ spread: import("../../interfaces/global").CMSIBSizeInterface;
251
+ blur: import("../../interfaces/global").CMSIBSizeInterface;
252
+ };
253
+ playPause: {
254
+ selectorKey: VideoSelectorKeysEnum;
255
+ playIcon: {
256
+ value: string;
257
+ property: string;
258
+ propertyType: CMSElementEditTypes;
259
+ };
260
+ pauseIcon: {
261
+ value: string;
262
+ property: string;
263
+ propertyType: CMSElementEditTypes;
264
+ };
265
+ size: {
266
+ value: string;
267
+ property: string;
268
+ unit: number;
269
+ propertyType: CMSElementEditTypes;
270
+ };
271
+ iconColor: CMSIBCommonInterface;
272
+ backgroundShape: {
273
+ value: string;
274
+ property: string;
275
+ unit: number;
276
+ propertyType: CMSElementEditTypes;
277
+ };
278
+ backgroundColor: CMSIBCommonInterface;
279
+ };
280
+ };
281
+ };
74
282
  export {};
@@ -27,10 +27,10 @@ export type ResponsiveBehaviourTypes = "proportional-scaling" | "fixed-height" |
27
27
  export type SizeTypeValue = "inline" | "block" | string;
28
28
  export type GlobalImageAttributes = "src" | "alt" | "width" | "height" | "loading" | "crossOrigin" | "referrerPolicy";
29
29
  export type GlobalTextAttributes = "lang" | "dir" | "title" | "aria-label" | "aria-hidden" | "aria-live" | "tabIndex" | "role";
30
- export type ImageBuilderAttributes = "dataDivType" | "dataType" | "dataElementType" | "dataWidgetType";
30
+ export type ImageBuilderAttributes = "dataDivType" | "dataType" | "dataElementType" | "dataWidgetType" | "dataElementSubChild";
31
31
  export type CMSEditControlsTypes = "Slider" | "Settings" | string;
32
32
  export type GlobalVideoAttributes = "src" | "poster" | "controls" | "autoplay" | "loop" | "muted" | "preload" | "crossOrigin" | "playsInline";
33
- export type CommonBuilderAttributes = "dataDivType" | "dataType" | "dataElementType" | "dataWidgetType";
33
+ export type CommonBuilderAttributes = "dataDivType" | "dataType" | "dataElementType" | "dataWidgetType" | "dataElementSubChild";
34
34
  export type GlobalTableAttributes = "cellPadding" | "cellSpacing" | "border" | "width" | "height" | "align" | "bgColor" | "frame" | "headers" | "rows" | "rules";
35
35
  export type ObjectFitValue = "fill" | "contain" | "cover" | "none" | "scale-down" | string;
36
36
  export type ObjectPositionValue = string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sc-360-v2/storefront-cms-library",
3
- "version": "0.0.7",
3
+ "version": "0.0.8",
4
4
  "main": "/dist/index.js",
5
5
  "types": "./dist/index.d.ts",
6
6
  "exports": {
package/dist/faq.scss DELETED
@@ -1,136 +0,0 @@
1
- @use "sass:map";
2
- @use "sass:list";
3
-
4
- [data-div-type="element"] {
5
- &[data-element-type="faq"] {
6
- // width: var(--_lt-wh);
7
- // height: var(--_lt-ht);
8
- // margin: var(--_lt-mn);
9
- // padding: var(--_lt-pg);
10
- // width: var(--_ctm-lt-wh, var(--_tst-lt-wh));
11
- width: var(--_sf-nw-wh, var(--_tst-lt-wh));
12
- margin: var(--_ctm-lt-mn, --_tst-lt-mn);
13
- // height: var(--_ctm-lt-ht, var(--_tst-lt-ht));
14
- // height: ;
15
- aspect-ratio: 1 / var(--_sf-aspect-ratio);
16
- --_aspect-ratio: calc(
17
- 1 * (var(--_ctm-lt-ht, var(--_tst-lt-ht)) / var(--_ctm-lt-wh, var(--_tst-lt-wh)))
18
- );
19
-
20
- & > .wrapper {
21
- width: 100%;
22
- // height: 100%;
23
- }
24
- &[data-show-shadow="false"] {
25
- --_show-shadow: none;
26
- }
27
-
28
- .accordion-element {
29
- background-color: var(--_ctm-dn-fq-wt-bd-cr, var(--_tst-dn-fq-wt-bd-cr));
30
- padding: var(--_ctm-lt-pg, var(--_tst-lt-pg));
31
- display: flex;
32
- flex-direction: column;
33
- --_sf-gp: 16px;
34
- --_sf-cd-gp: calc(var(--_sf-gp) * 0.5);
35
- row-gap: var(--_sf-gp);
36
- width: 100%;
37
- // height: 100%;
38
- border-color: var(--_ctm-dn-fq-wt-br-cr, var(--_tst-dn-fq-wt-br-cr));
39
- border-style: var(--_ctm-dn-fq-wt-br-se, var(--_tst-dn-fq-wt-br-se));
40
- border-width: var(--_ctm-dn-fq-wt-br-wh, var(--_tst-dn-fq-wt-br-wh));
41
- border-radius: var(--_ctm-dn-fq-wt-br-rs, var(--_tst-dn-fq-wt-br-rs));
42
- box-shadow: var(
43
- --_show-shadow,
44
- var(--_ctm-dn-fq-wt-sw-ae, var(--_tst-dn-fq-wt-sw-ae))
45
- var(--_ctm-dn-fq-wt-sw-br, var(--_tst-dn-fq-wt-sw-br))
46
- var(--_ctm-dn-fq-wt-sw-sd, var(--_tst-dn-fq-wt-sw-sd))
47
- var(--_ctm-dn-fq-wt-sw-cr, var(--_tst-dn-fq-wt-sw-cr))
48
- );
49
-
50
- &[data-divider-show="true"] {
51
- --_sf-dvdr: 1px solid var(--_ctm-dn-dr-bd-cr, var(--_tst-dn-dr-bd-cr));
52
- --_sf-dvdr-gap: var(--_sf-gp);
53
- }
54
- &[data-icon-position="Left"] {
55
- --_sf-fd: row-reverse;
56
- --_sf-jc: flex-end;
57
- }
58
- &[data-show-icon="false"] {
59
- --_sf-show-icon-ff: none;
60
- }
61
- }
62
-
63
- .accordion-item {
64
- width: 100%;
65
- display: grid;
66
- overflow: clip;
67
- grid-template-rows: var(
68
- --_self-active-gtr,
69
- minmax(var(--_ctm-dn-in-in-se, var(--_tst-dn-in-in-se)), auto) 0px
70
- );
71
- // transition: grid-template-rows 0.45s ease-in-out;
72
-
73
- --_sf-pd-cd: var(--_sf-dvdr-gap);
74
- &:not(:last-of-type) {
75
- border-block-end: var(--_sf-dvdr);
76
- }
77
-
78
- &[data-state="open"] {
79
- // overflow: inherit;
80
- --_self-active-gtr: minmax(var(--_ctm-dn-in-in-se, var(--_tst-dn-in-in-se)), auto)
81
- minmax(50px, auto);
82
-
83
- --_sf-dc-pd: var(--_sf-dvdr-gap, var(--_sf-cd-gp));
84
- --_sf-dc-mb: var(--_sf-cd-gp);
85
- --_sf-tt-pd: 0px;
86
- --_sf-dc-pd-bt: var(--_sf-dvdr-gap, 0px);
87
- }
88
- }
89
- .accordion-title {
90
- display: flex;
91
- flex-direction: var(--_sf-fd, row);
92
- align-content: center;
93
- gap: var(--_sf-cd-gp);
94
- align-items: center;
95
- justify-content: var(--_sf-jc, space-between);
96
- cursor: pointer;
97
- padding-block-end: var(--_sf-dc-pd, var(--_sf-pd-cd));
98
-
99
- p {
100
- padding-inline: var(--_sf-cd-gp);
101
- color: var(--_ctm-dn-te-tt-cr, var(--_tst-dn-te-tt-cr));
102
- font-family: var(--_ctm-dn-te-tt-ft-fy, var(--_tst-dn-te-tt-ft-fy)), sans-serif;
103
- font-size: var(--_ctm-dn-te-tt-ft-se, var(--_tst-dn-te-tt-ft-se));
104
- font-weight: var(--_ctm-dn-te-tt-ft-wt, var(--_tst-dn-te-tt-ft-wt));
105
- font-style: var(--_ctm-dn-te-tt-ft-se-ic, var(--_tst-dn-te-tt-ft-se-ic));
106
- text-align: var(--_ctm-dn-te-tt-tt-an, var(--_tst-dn-te-tt-tt-an));
107
- letter-spacing: var(--_ctm-dn-te-tt-lr-sg, var(--_tst-dn-te-tt-lr-sg));
108
- line-height: var(--_ctm-dn-te-tt-le-ht, var(--_tst-dn-te-tt-le-ht));
109
- }
110
- .icon {
111
- display: var(--_sf-show-icon-ff, flex);
112
- svg {
113
- width: var(--_ctm-dn-in-in-se, var(--_tst-dn-in-in-se));
114
- height: var(--_ctm-dn-in-in-se, var(--_tst-dn-in-in-se));
115
- path {
116
- stroke: var(--_ctm-dn-in-in-c1, var(--_tst-dn-in-in-c1));
117
- }
118
- }
119
- }
120
- }
121
- .accordion-description {
122
- // margin-block-start: calc(-1 * var(--_sf-dc-mb));
123
- padding-block-end: var(--_sf-dc-pd-bt);
124
- p {
125
- color: var(--_ctm-dn-dn-tt-cr, var(--_tst-dn-dn-tt-cr));
126
- font-family: var(--_ctm-dn-dn-tt-ft-fy, var(--_tst-dn-dn-tt-ft-fy)), sans-serif;
127
- font-size: var(--_ctm-dn-dn-tt-ft-se, var(--_tst-dn-dn-tt-ft-se));
128
- font-weight: var(--_ctm-dn-dn-tt-ft-wt, var(--_tst-dn-dn-tt-ft-wt));
129
- font-style: var(--_ctm-dn-dn-tt-ft-se-ic, var(--_tst-dn-dn-tt-ft-se-ic));
130
- text-align: var(--_ctm-dn-dn-tt-tt-an, var(--_tst-dn-dn-tt-tt-an));
131
- letter-spacing: var(--_ctm-dn-dn-tt-lr-sg, var(--_tst-dn-dn-tt-lr-sg));
132
- line-height: var(--_ctm-dn-dn-tt-le-ht, var(--_tst-dn-dn-tt-le-ht));
133
- }
134
- }
135
- }
136
- }