@gem-sdk/core 1.58.0-dev.69 → 1.58.0-dev.87
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/cjs/helpers/compose-advance-style.js +9 -2
- package/dist/cjs/helpers/radius.js +2 -1
- package/dist/cjs/helpers/third-party/appSetting.js +8 -1
- package/dist/cjs/helpers/third-party/getAppBlockConfig.js +1 -1
- package/dist/esm/helpers/compose-advance-style.js +9 -2
- package/dist/esm/helpers/radius.js +2 -1
- package/dist/esm/helpers/third-party/appSetting.js +8 -1
- package/dist/esm/helpers/third-party/getAppBlockConfig.js +1 -1
- package/dist/types/index.d.ts +127 -35
- package/package.json +1 -1
|
@@ -118,7 +118,8 @@ function composeAdvanceStyle(data, tag, pageType) {
|
|
|
118
118
|
'Text',
|
|
119
119
|
'Heading',
|
|
120
120
|
'Image',
|
|
121
|
-
'Button'
|
|
121
|
+
'Button',
|
|
122
|
+
'HeroBanner'
|
|
122
123
|
];
|
|
123
124
|
const productElements = [
|
|
124
125
|
'ProductTitle',
|
|
@@ -128,9 +129,15 @@ function composeAdvanceStyle(data, tag, pageType) {
|
|
|
128
129
|
'Product',
|
|
129
130
|
'ProductSku'
|
|
130
131
|
];
|
|
132
|
+
const boostElements = [
|
|
133
|
+
'Icon',
|
|
134
|
+
'IconListHoz',
|
|
135
|
+
'Line'
|
|
136
|
+
];
|
|
131
137
|
const listElementShadowV2 = [
|
|
132
138
|
...baseElements,
|
|
133
|
-
...productElements
|
|
139
|
+
...productElements,
|
|
140
|
+
...boostElements
|
|
134
141
|
];
|
|
135
142
|
let hasBoxShadowV2 = hasBoxShadow;
|
|
136
143
|
if (listElementShadowV2.includes(tag || '')) {
|
|
@@ -32,7 +32,8 @@ const getCustomRadius = (state, radius, device)=>{
|
|
|
32
32
|
'pill',
|
|
33
33
|
'rounded',
|
|
34
34
|
'single',
|
|
35
|
-
'none'
|
|
35
|
+
'none',
|
|
36
|
+
'circle'
|
|
36
37
|
];
|
|
37
38
|
if (!radius || !state || !list.includes(radius?.radiusType ?? '')) return {};
|
|
38
39
|
const suffix = device && device !== 'desktop' ? constant.devicesMapping?.[device] : '';
|
|
@@ -99,7 +99,14 @@ const overrideSettings = (tag, currentSetting, appSetting)=>{
|
|
|
99
99
|
{
|
|
100
100
|
return {
|
|
101
101
|
...currentSetting,
|
|
102
|
-
|
|
102
|
+
'show-views': appSetting?.showViews,
|
|
103
|
+
heading: appSetting?.heading,
|
|
104
|
+
'template-type': appSetting?.templateType,
|
|
105
|
+
'title-font-size': parseFloat(appSetting?.titleFontSize),
|
|
106
|
+
'landscape-padding': parseFloat(appSetting?.landscapePadding),
|
|
107
|
+
'top-bottom-padding': parseFloat(appSetting?.topBottomPadding),
|
|
108
|
+
'scroll-video-tile-size': parseFloat(appSetting?.scrollVideoTitleSize),
|
|
109
|
+
'scroll-video-tile-size-portrait': parseFloat(appSetting?.scrollVideoTitleSizePortrait)
|
|
103
110
|
};
|
|
104
111
|
}
|
|
105
112
|
case 'PowerfulContactFormBuilder':
|
|
@@ -12,7 +12,7 @@ const listThirdPartyRejectAppBlock = {
|
|
|
12
12
|
}
|
|
13
13
|
};
|
|
14
14
|
const getAppBlockConfig = (tag, appBlockId, settings)=>{
|
|
15
|
-
if (listThirdPartyRejectAppBlock[tag] && eval(listThirdPartyRejectAppBlock[tag]
|
|
15
|
+
if (listThirdPartyRejectAppBlock[tag] && eval(listThirdPartyRejectAppBlock[tag]?.conditionToReject ?? '')) {
|
|
16
16
|
return;
|
|
17
17
|
}
|
|
18
18
|
let widgetType = settings?.widgetType;
|
|
@@ -116,7 +116,8 @@ function composeAdvanceStyle(data, tag, pageType) {
|
|
|
116
116
|
'Text',
|
|
117
117
|
'Heading',
|
|
118
118
|
'Image',
|
|
119
|
-
'Button'
|
|
119
|
+
'Button',
|
|
120
|
+
'HeroBanner'
|
|
120
121
|
];
|
|
121
122
|
const productElements = [
|
|
122
123
|
'ProductTitle',
|
|
@@ -126,9 +127,15 @@ function composeAdvanceStyle(data, tag, pageType) {
|
|
|
126
127
|
'Product',
|
|
127
128
|
'ProductSku'
|
|
128
129
|
];
|
|
130
|
+
const boostElements = [
|
|
131
|
+
'Icon',
|
|
132
|
+
'IconListHoz',
|
|
133
|
+
'Line'
|
|
134
|
+
];
|
|
129
135
|
const listElementShadowV2 = [
|
|
130
136
|
...baseElements,
|
|
131
|
-
...productElements
|
|
137
|
+
...productElements,
|
|
138
|
+
...boostElements
|
|
132
139
|
];
|
|
133
140
|
let hasBoxShadowV2 = hasBoxShadow;
|
|
134
141
|
if (listElementShadowV2.includes(tag || '')) {
|
|
@@ -30,7 +30,8 @@ const getCustomRadius = (state, radius, device)=>{
|
|
|
30
30
|
'pill',
|
|
31
31
|
'rounded',
|
|
32
32
|
'single',
|
|
33
|
-
'none'
|
|
33
|
+
'none',
|
|
34
|
+
'circle'
|
|
34
35
|
];
|
|
35
36
|
if (!radius || !state || !list.includes(radius?.radiusType ?? '')) return {};
|
|
36
37
|
const suffix = device && device !== 'desktop' ? devicesMapping?.[device] : '';
|
|
@@ -97,7 +97,14 @@ const overrideSettings = (tag, currentSetting, appSetting)=>{
|
|
|
97
97
|
{
|
|
98
98
|
return {
|
|
99
99
|
...currentSetting,
|
|
100
|
-
|
|
100
|
+
'show-views': appSetting?.showViews,
|
|
101
|
+
heading: appSetting?.heading,
|
|
102
|
+
'template-type': appSetting?.templateType,
|
|
103
|
+
'title-font-size': parseFloat(appSetting?.titleFontSize),
|
|
104
|
+
'landscape-padding': parseFloat(appSetting?.landscapePadding),
|
|
105
|
+
'top-bottom-padding': parseFloat(appSetting?.topBottomPadding),
|
|
106
|
+
'scroll-video-tile-size': parseFloat(appSetting?.scrollVideoTitleSize),
|
|
107
|
+
'scroll-video-tile-size-portrait': parseFloat(appSetting?.scrollVideoTitleSizePortrait)
|
|
101
108
|
};
|
|
102
109
|
}
|
|
103
110
|
case 'PowerfulContactFormBuilder':
|
|
@@ -10,7 +10,7 @@ const listThirdPartyRejectAppBlock = {
|
|
|
10
10
|
}
|
|
11
11
|
};
|
|
12
12
|
const getAppBlockConfig = (tag, appBlockId, settings)=>{
|
|
13
|
-
if (listThirdPartyRejectAppBlock[tag] && eval(listThirdPartyRejectAppBlock[tag]
|
|
13
|
+
if (listThirdPartyRejectAppBlock[tag] && eval(listThirdPartyRejectAppBlock[tag]?.conditionToReject ?? '')) {
|
|
14
14
|
return;
|
|
15
15
|
}
|
|
16
16
|
let widgetType = settings?.widgetType;
|
package/dist/types/index.d.ts
CHANGED
|
@@ -7279,7 +7279,7 @@ type HyperlinkInfo = {
|
|
|
7279
7279
|
link?: string;
|
|
7280
7280
|
modal?: CommonModalApp;
|
|
7281
7281
|
};
|
|
7282
|
-
type Mapped$
|
|
7282
|
+
type Mapped$8<K, T> = NonNullable<T> extends ObjectDevices<infer U> ? {
|
|
7283
7283
|
id: K;
|
|
7284
7284
|
label?: string;
|
|
7285
7285
|
info?: string;
|
|
@@ -7315,6 +7315,7 @@ type Mapped$7<K, T> = NonNullable<T> extends ObjectDevices<infer U> ? {
|
|
|
7315
7315
|
compoDefaultValue?: ResponsiveConfig<U>;
|
|
7316
7316
|
emptyOnClear?: boolean;
|
|
7317
7317
|
showVideo?: boolean;
|
|
7318
|
+
disableGetDefault?: boolean;
|
|
7318
7319
|
} : {
|
|
7319
7320
|
id: K;
|
|
7320
7321
|
label?: string;
|
|
@@ -7352,19 +7353,20 @@ type Mapped$7<K, T> = NonNullable<T> extends ObjectDevices<infer U> ? {
|
|
|
7352
7353
|
showVideo?: boolean;
|
|
7353
7354
|
default?: T;
|
|
7354
7355
|
compoDefaultValue?: T;
|
|
7356
|
+
disableGetDefault?: boolean;
|
|
7355
7357
|
};
|
|
7356
7358
|
type SharedControlType<T> = {
|
|
7357
|
-
[K in keyof T]-?: Mapped$
|
|
7359
|
+
[K in keyof T]-?: Mapped$8<K, T[K]>;
|
|
7358
7360
|
}[keyof T];
|
|
7359
7361
|
|
|
7360
|
-
type Option$
|
|
7362
|
+
type Option$6 = {
|
|
7361
7363
|
value: number | string;
|
|
7362
7364
|
label?: string | number;
|
|
7363
7365
|
type?: string;
|
|
7364
7366
|
icon?: string;
|
|
7365
7367
|
isTextIcon?: boolean;
|
|
7366
7368
|
};
|
|
7367
|
-
type Mapped$
|
|
7369
|
+
type Mapped$7<K, T> = NonNullable<T> extends ObjectDevices<infer U> ? {
|
|
7368
7370
|
id: K;
|
|
7369
7371
|
label: string;
|
|
7370
7372
|
info?: string;
|
|
@@ -7382,7 +7384,7 @@ type Mapped$6<K, T> = NonNullable<T> extends ObjectDevices<infer U> ? {
|
|
|
7382
7384
|
};
|
|
7383
7385
|
placeholder?: string;
|
|
7384
7386
|
type: 'layout-custom-segment';
|
|
7385
|
-
options: Option$
|
|
7387
|
+
options: Option$6[];
|
|
7386
7388
|
devices?: ResponsiveConfig<U>;
|
|
7387
7389
|
iconViewBox?: string;
|
|
7388
7390
|
enableItemBackground?: boolean;
|
|
@@ -7407,14 +7409,14 @@ type Mapped$6<K, T> = NonNullable<T> extends ObjectDevices<infer U> ? {
|
|
|
7407
7409
|
};
|
|
7408
7410
|
placeholder?: string;
|
|
7409
7411
|
type: 'layout-custom-segment';
|
|
7410
|
-
options?: Option$
|
|
7412
|
+
options?: Option$6[];
|
|
7411
7413
|
iconViewBox?: string;
|
|
7412
7414
|
enableItemBackground?: boolean;
|
|
7413
7415
|
enableTooltip?: boolean;
|
|
7414
7416
|
default?: T;
|
|
7415
7417
|
};
|
|
7416
7418
|
type LayoutCustomSegmentControlType<T> = {
|
|
7417
|
-
[K in keyof T]-?: Mapped$
|
|
7419
|
+
[K in keyof T]-?: Mapped$7<K, T[K]>;
|
|
7418
7420
|
}[keyof T];
|
|
7419
7421
|
|
|
7420
7422
|
type AngleControlType<T> = SharedControlType<T> & {
|
|
@@ -7426,12 +7428,12 @@ type AngleControlType<T> = SharedControlType<T> & {
|
|
|
7426
7428
|
readonly?: boolean;
|
|
7427
7429
|
};
|
|
7428
7430
|
|
|
7429
|
-
type Option$
|
|
7431
|
+
type Option$5<T> = {
|
|
7430
7432
|
value: T extends ObjectDevices<infer U> ? U extends StateProp<infer A> ? A : U : T extends StateProp<infer B> ? B : T;
|
|
7431
7433
|
text: string | number;
|
|
7432
7434
|
desc?: any;
|
|
7433
7435
|
};
|
|
7434
|
-
type Mapped$
|
|
7436
|
+
type Mapped$6<K, T> = NonNullable<T> extends ObjectDevices<infer U> ? {
|
|
7435
7437
|
id: K;
|
|
7436
7438
|
label: string;
|
|
7437
7439
|
hideOnMode?: {
|
|
@@ -7447,7 +7449,7 @@ type Mapped$5<K, T> = NonNullable<T> extends ObjectDevices<infer U> ? {
|
|
|
7447
7449
|
active?: boolean;
|
|
7448
7450
|
};
|
|
7449
7451
|
type: 'checkbox';
|
|
7450
|
-
options: Option$
|
|
7452
|
+
options: Option$5<T>[];
|
|
7451
7453
|
devices?: ResponsiveConfig<U>;
|
|
7452
7454
|
} : {
|
|
7453
7455
|
id: K;
|
|
@@ -7465,11 +7467,11 @@ type Mapped$5<K, T> = NonNullable<T> extends ObjectDevices<infer U> ? {
|
|
|
7465
7467
|
active?: boolean;
|
|
7466
7468
|
};
|
|
7467
7469
|
type: 'checkbox';
|
|
7468
|
-
options: Option$
|
|
7470
|
+
options: Option$5<T>[];
|
|
7469
7471
|
default?: T;
|
|
7470
7472
|
};
|
|
7471
7473
|
type CheckboxControlType<T> = {
|
|
7472
|
-
[K in keyof T]-?: Mapped$
|
|
7474
|
+
[K in keyof T]-?: Mapped$6<K, T[K]>;
|
|
7473
7475
|
}[keyof T];
|
|
7474
7476
|
|
|
7475
7477
|
type ChildrensControlType = {
|
|
@@ -7558,6 +7560,7 @@ type InputNumberControlType<T> = SharedControlType<T> & {
|
|
|
7558
7560
|
min?: number;
|
|
7559
7561
|
max?: number;
|
|
7560
7562
|
readonly?: boolean;
|
|
7563
|
+
includeUnit?: 'px' | '%';
|
|
7561
7564
|
};
|
|
7562
7565
|
|
|
7563
7566
|
type SizeUnit$2 = 's' | '%' | 'cm' | 'mm' | 'Q' | 'in' | 'pc' | 'pt' | 'px' | 'em' | 'cap' | 'ex' | 'ch' | 'ic' | 'rem' | 'lh' | 'rlh' | 'vw' | 'vh' | 'vi' | 'vb' | 'vmin' | 'vmax' | 'ms' | 'min' | 'days';
|
|
@@ -7614,14 +7617,14 @@ type RangeControlType<T> = SharedControlType<T> & {
|
|
|
7614
7617
|
maxRelated?: string;
|
|
7615
7618
|
}>;
|
|
7616
7619
|
|
|
7617
|
-
type Option$
|
|
7620
|
+
type Option$4<T> = {
|
|
7618
7621
|
value: T extends ObjectDevices<infer U> ? U extends StateProp<infer A> ? A : U : T extends StateProp<infer B> ? B : T;
|
|
7619
7622
|
label?: string | number;
|
|
7620
7623
|
type?: string;
|
|
7621
7624
|
icon?: string;
|
|
7622
7625
|
tooltip?: string;
|
|
7623
7626
|
};
|
|
7624
|
-
type Mapped$
|
|
7627
|
+
type Mapped$5<K, T> = NonNullable<T> extends ObjectDevices<infer U> ? {
|
|
7625
7628
|
id: K;
|
|
7626
7629
|
label?: string;
|
|
7627
7630
|
info?: string;
|
|
@@ -7639,7 +7642,7 @@ type Mapped$4<K, T> = NonNullable<T> extends ObjectDevices<infer U> ? {
|
|
|
7639
7642
|
};
|
|
7640
7643
|
placeholder?: string;
|
|
7641
7644
|
type: 'segment' | 'accordion:segment';
|
|
7642
|
-
options: Option$
|
|
7645
|
+
options: Option$4<T>[];
|
|
7643
7646
|
iconCustom?: boolean;
|
|
7644
7647
|
devices?: ResponsiveConfig<U>;
|
|
7645
7648
|
} : {
|
|
@@ -7660,12 +7663,12 @@ type Mapped$4<K, T> = NonNullable<T> extends ObjectDevices<infer U> ? {
|
|
|
7660
7663
|
};
|
|
7661
7664
|
placeholder?: string;
|
|
7662
7665
|
type: 'segment' | 'accordion:segment';
|
|
7663
|
-
options: Option$
|
|
7666
|
+
options: Option$4<T>[];
|
|
7664
7667
|
iconCustom?: boolean;
|
|
7665
7668
|
default?: T;
|
|
7666
7669
|
};
|
|
7667
7670
|
type SegmentControlType<T> = {
|
|
7668
|
-
[K in keyof T]-?: Mapped$
|
|
7671
|
+
[K in keyof T]-?: Mapped$5<K, T[K]>;
|
|
7669
7672
|
}[keyof T];
|
|
7670
7673
|
|
|
7671
7674
|
type OpenLinkControlType<T> = SharedControlType<T> & {
|
|
@@ -7676,7 +7679,7 @@ type OpenLinkControlType<T> = SharedControlType<T> & {
|
|
|
7676
7679
|
linkType?: 'openApp' | 'install';
|
|
7677
7680
|
};
|
|
7678
7681
|
|
|
7679
|
-
type Option$
|
|
7682
|
+
type Option$3<T> = {
|
|
7680
7683
|
value: T extends ObjectDevices<infer U> ? U extends StateProp<infer A> ? A : U : T extends StateProp<infer B> ? B : T;
|
|
7681
7684
|
label: string | number;
|
|
7682
7685
|
hideOnPage?: string[];
|
|
@@ -7689,7 +7692,7 @@ type Option$2<T> = {
|
|
|
7689
7692
|
note?: string;
|
|
7690
7693
|
maxOption?: number;
|
|
7691
7694
|
};
|
|
7692
|
-
type Mapped$
|
|
7695
|
+
type Mapped$4<K, T> = NonNullable<T> extends ObjectDevices<infer U> ? {
|
|
7693
7696
|
id: K;
|
|
7694
7697
|
label?: string;
|
|
7695
7698
|
info?: string;
|
|
@@ -7708,7 +7711,7 @@ type Mapped$3<K, T> = NonNullable<T> extends ObjectDevices<infer U> ? {
|
|
|
7708
7711
|
};
|
|
7709
7712
|
placeholder?: string;
|
|
7710
7713
|
type: 'select';
|
|
7711
|
-
options: Option$
|
|
7714
|
+
options: Option$3<T>[];
|
|
7712
7715
|
devices?: ResponsiveConfig<U>;
|
|
7713
7716
|
} : {
|
|
7714
7717
|
id: K;
|
|
@@ -7728,12 +7731,12 @@ type Mapped$3<K, T> = NonNullable<T> extends ObjectDevices<infer U> ? {
|
|
|
7728
7731
|
};
|
|
7729
7732
|
placeholder?: string;
|
|
7730
7733
|
type: 'select';
|
|
7731
|
-
options: Option$
|
|
7734
|
+
options: Option$3<T>[];
|
|
7732
7735
|
default?: T;
|
|
7733
7736
|
isFullWidth?: boolean;
|
|
7734
7737
|
};
|
|
7735
7738
|
type SelectControlType<T> = {
|
|
7736
|
-
[K in keyof T]-?: Mapped$
|
|
7739
|
+
[K in keyof T]-?: Mapped$4<K, T[K]>;
|
|
7737
7740
|
}[keyof T];
|
|
7738
7741
|
|
|
7739
7742
|
type TextareaControlType<T> = SharedControlType<T> & {
|
|
@@ -7961,14 +7964,15 @@ type CustomCodeEditor = {
|
|
|
7961
7964
|
id: string;
|
|
7962
7965
|
};
|
|
7963
7966
|
|
|
7964
|
-
type Option$
|
|
7967
|
+
type Option$2<T> = {
|
|
7965
7968
|
value: T extends ObjectDevices<infer U> ? U extends StateProp<infer A> ? A : U : T extends StateProp<infer B> ? B : T;
|
|
7966
7969
|
label?: string | number;
|
|
7967
7970
|
type?: string;
|
|
7968
7971
|
icon?: string;
|
|
7972
|
+
iconName?: string;
|
|
7969
7973
|
isTextIcon?: boolean;
|
|
7970
7974
|
};
|
|
7971
|
-
type Mapped$
|
|
7975
|
+
type Mapped$3<K, T> = NonNullable<T> extends ObjectDevices<infer U> ? {
|
|
7972
7976
|
id: K;
|
|
7973
7977
|
label: string;
|
|
7974
7978
|
info?: string;
|
|
@@ -7986,7 +7990,11 @@ type Mapped$2<K, T> = NonNullable<T> extends ObjectDevices<infer U> ? {
|
|
|
7986
7990
|
};
|
|
7987
7991
|
placeholder?: string;
|
|
7988
7992
|
type: 'layout-segment';
|
|
7989
|
-
options: Option$
|
|
7993
|
+
options: Option$2<T>[];
|
|
7994
|
+
groups?: {
|
|
7995
|
+
label: string;
|
|
7996
|
+
options: Option$2<T>[];
|
|
7997
|
+
}[];
|
|
7990
7998
|
devices?: ResponsiveConfig<U>;
|
|
7991
7999
|
iconViewBox?: string;
|
|
7992
8000
|
enableItemBackground?: boolean;
|
|
@@ -8013,14 +8021,18 @@ type Mapped$2<K, T> = NonNullable<T> extends ObjectDevices<infer U> ? {
|
|
|
8013
8021
|
type: 'layout-segment';
|
|
8014
8022
|
itemPerRow?: number;
|
|
8015
8023
|
itemSpacing?: 'large' | 'small';
|
|
8016
|
-
options?: Option$
|
|
8024
|
+
options?: Option$2<T>[];
|
|
8025
|
+
groups?: {
|
|
8026
|
+
label: string;
|
|
8027
|
+
options: Option$2<T>[];
|
|
8028
|
+
}[];
|
|
8017
8029
|
iconViewBox?: string;
|
|
8018
8030
|
enableItemBackground?: boolean;
|
|
8019
8031
|
enableTooltip?: boolean;
|
|
8020
8032
|
default?: T;
|
|
8021
8033
|
};
|
|
8022
8034
|
type LayoutSegmentControlType<T> = {
|
|
8023
|
-
[K in keyof T]-?: Mapped$
|
|
8035
|
+
[K in keyof T]-?: Mapped$3<K, T[K]>;
|
|
8024
8036
|
}[keyof T];
|
|
8025
8037
|
|
|
8026
8038
|
type InputSpacing<T> = SharedControlType<T> & {
|
|
@@ -8143,7 +8155,7 @@ type Actions = {
|
|
|
8143
8155
|
actionHandle?: string;
|
|
8144
8156
|
link?: string;
|
|
8145
8157
|
};
|
|
8146
|
-
type Mapped$
|
|
8158
|
+
type Mapped$2<K, T> = {
|
|
8147
8159
|
id: K;
|
|
8148
8160
|
label: string;
|
|
8149
8161
|
info?: string;
|
|
@@ -8152,7 +8164,7 @@ type Mapped$1<K, T> = {
|
|
|
8152
8164
|
default?: T;
|
|
8153
8165
|
};
|
|
8154
8166
|
type StepsGuide<T> = {
|
|
8155
|
-
[K in keyof T]-?: Mapped$
|
|
8167
|
+
[K in keyof T]-?: Mapped$2<K, T[K]>;
|
|
8156
8168
|
}[keyof T];
|
|
8157
8169
|
|
|
8158
8170
|
type ImageShape<T> = SharedControlType<T> & {
|
|
@@ -8262,14 +8274,14 @@ type SneakPeakRange<T> = SharedControlType<T> & {
|
|
|
8262
8274
|
sneakPeakType?: string;
|
|
8263
8275
|
};
|
|
8264
8276
|
|
|
8265
|
-
type Option<T> = {
|
|
8277
|
+
type Option$1<T> = {
|
|
8266
8278
|
value: T extends ObjectDevices<infer U> ? U extends StateProp<infer A> ? A : U : T extends StateProp<infer B> ? B : T;
|
|
8267
8279
|
label?: string | number;
|
|
8268
8280
|
type?: string;
|
|
8269
8281
|
icon?: string;
|
|
8270
8282
|
isTextIcon?: boolean;
|
|
8271
8283
|
};
|
|
8272
|
-
type Mapped<K, T> = NonNullable<T> extends ObjectDevices<infer U> ? {
|
|
8284
|
+
type Mapped$1<K, T> = NonNullable<T> extends ObjectDevices<infer U> ? {
|
|
8273
8285
|
id: K;
|
|
8274
8286
|
label: string;
|
|
8275
8287
|
info?: string;
|
|
@@ -8287,7 +8299,7 @@ type Mapped<K, T> = NonNullable<T> extends ObjectDevices<infer U> ? {
|
|
|
8287
8299
|
};
|
|
8288
8300
|
placeholder?: string;
|
|
8289
8301
|
type: 'sneak-peak-type';
|
|
8290
|
-
options: Option<T>[];
|
|
8302
|
+
options: Option$1<T>[];
|
|
8291
8303
|
devices?: ResponsiveConfig<U>;
|
|
8292
8304
|
iconViewBox?: string;
|
|
8293
8305
|
enableItemBackground?: boolean;
|
|
@@ -8312,14 +8324,14 @@ type Mapped<K, T> = NonNullable<T> extends ObjectDevices<infer U> ? {
|
|
|
8312
8324
|
};
|
|
8313
8325
|
placeholder?: string;
|
|
8314
8326
|
type: 'sneak-peak-type';
|
|
8315
|
-
options?: Option<T>[];
|
|
8327
|
+
options?: Option$1<T>[];
|
|
8316
8328
|
iconViewBox?: string;
|
|
8317
8329
|
enableItemBackground?: boolean;
|
|
8318
8330
|
enableTooltip?: boolean;
|
|
8319
8331
|
default?: T;
|
|
8320
8332
|
};
|
|
8321
8333
|
type SneakPeakTypeControlType<T> = {
|
|
8322
|
-
[K in keyof T]-?: Mapped<K, T[K]>;
|
|
8334
|
+
[K in keyof T]-?: Mapped$1<K, T[K]>;
|
|
8323
8335
|
}[keyof T];
|
|
8324
8336
|
|
|
8325
8337
|
type ProductInputCurrencyUnitControlType<T> = SharedControlType<T> & {
|
|
@@ -8590,16 +8602,21 @@ type SettingUICompo = {
|
|
|
8590
8602
|
controls?: SettingUIControl[];
|
|
8591
8603
|
iconName?: string;
|
|
8592
8604
|
getValueFromSettingID?: string;
|
|
8605
|
+
defaultValueWhenClear?: any;
|
|
8593
8606
|
fixedValue?: string;
|
|
8594
8607
|
placeholder?: string;
|
|
8595
8608
|
help?: SettingUIHelpType;
|
|
8609
|
+
popoverLabel?: LabelWithLang;
|
|
8610
|
+
comboType?: 'color' | 'image';
|
|
8596
8611
|
};
|
|
8597
8612
|
type SettingUIMoreSetting = {
|
|
8598
8613
|
label?: LabelWithLang;
|
|
8599
8614
|
labelAction?: LabelWithLang;
|
|
8600
8615
|
controls?: SettingUIControl[];
|
|
8601
8616
|
help?: SettingUIHelpType;
|
|
8617
|
+
type?: SettingUIMoreSettingType;
|
|
8602
8618
|
};
|
|
8619
|
+
type SettingUIMoreSettingType = 'button' | 'collapse' | 'icon';
|
|
8603
8620
|
type SettingUITab = {
|
|
8604
8621
|
label?: LabelWithLang;
|
|
8605
8622
|
controls?: SettingUIControl[];
|
|
@@ -8905,7 +8922,82 @@ type ImageV2ControlType<T> = SharedControlType<T> & {
|
|
|
8905
8922
|
type: 'image-v2';
|
|
8906
8923
|
};
|
|
8907
8924
|
|
|
8908
|
-
type
|
|
8925
|
+
type ComboControlType<T> = SharedControlType<T> & {
|
|
8926
|
+
type: 'combo';
|
|
8927
|
+
readonly?: boolean;
|
|
8928
|
+
};
|
|
8929
|
+
|
|
8930
|
+
type Option<T> = {
|
|
8931
|
+
value: T extends ObjectDevices<infer U> ? U extends StateProp<infer A> ? A : U : T extends StateProp<infer B> ? B : T;
|
|
8932
|
+
label?: string | number;
|
|
8933
|
+
iconName?: string;
|
|
8934
|
+
type?: string;
|
|
8935
|
+
noPadding?: string;
|
|
8936
|
+
};
|
|
8937
|
+
type Mapped<K, T> = NonNullable<T> extends ObjectDevices<infer U> ? {
|
|
8938
|
+
id: K;
|
|
8939
|
+
label: string;
|
|
8940
|
+
info?: string;
|
|
8941
|
+
hide?: boolean;
|
|
8942
|
+
hideOnMode?: {
|
|
8943
|
+
responsive?: boolean;
|
|
8944
|
+
mobileOnly?: boolean;
|
|
8945
|
+
};
|
|
8946
|
+
disableToggle?: boolean;
|
|
8947
|
+
state?: {
|
|
8948
|
+
normal?: boolean;
|
|
8949
|
+
hover?: boolean;
|
|
8950
|
+
focus?: boolean;
|
|
8951
|
+
active?: boolean;
|
|
8952
|
+
};
|
|
8953
|
+
placeholder?: string;
|
|
8954
|
+
type: 'layout-selector';
|
|
8955
|
+
options: Option<T>[];
|
|
8956
|
+
groups?: {
|
|
8957
|
+
label: string;
|
|
8958
|
+
options: Option<T>[];
|
|
8959
|
+
}[];
|
|
8960
|
+
devices?: ResponsiveConfig<U>;
|
|
8961
|
+
iconViewBox?: string;
|
|
8962
|
+
enableItemBackground?: boolean;
|
|
8963
|
+
itemPerRow?: number;
|
|
8964
|
+
itemSpacing?: 'large' | 'small';
|
|
8965
|
+
enableTooltip?: boolean;
|
|
8966
|
+
} : {
|
|
8967
|
+
id: K;
|
|
8968
|
+
label: string;
|
|
8969
|
+
info?: string;
|
|
8970
|
+
hide?: boolean;
|
|
8971
|
+
hideOnMode?: {
|
|
8972
|
+
responsive?: boolean;
|
|
8973
|
+
mobileOnly?: boolean;
|
|
8974
|
+
};
|
|
8975
|
+
disableToggle?: boolean;
|
|
8976
|
+
state?: {
|
|
8977
|
+
normal?: boolean;
|
|
8978
|
+
hover?: boolean;
|
|
8979
|
+
focus?: boolean;
|
|
8980
|
+
active?: boolean;
|
|
8981
|
+
};
|
|
8982
|
+
placeholder?: string;
|
|
8983
|
+
type: 'layout-selector';
|
|
8984
|
+
itemPerRow?: number;
|
|
8985
|
+
itemSpacing?: 'large' | 'small';
|
|
8986
|
+
options?: Option<T>[];
|
|
8987
|
+
groups?: {
|
|
8988
|
+
label: string;
|
|
8989
|
+
options: Option<T>[];
|
|
8990
|
+
}[];
|
|
8991
|
+
iconViewBox?: string;
|
|
8992
|
+
enableItemBackground?: boolean;
|
|
8993
|
+
enableTooltip?: boolean;
|
|
8994
|
+
default?: T;
|
|
8995
|
+
};
|
|
8996
|
+
type LayoutSelectorControlType<T> = {
|
|
8997
|
+
[K in keyof T]-?: Mapped<K, T[K]>;
|
|
8998
|
+
}[keyof T];
|
|
8999
|
+
|
|
9000
|
+
type ControlProp<T> = ProductBundleChildControlType<T> | SelectProductBundleControlType<T> | AngleControlType<T> | CheckboxControlType<T> | ColorPickerControlType<T> | GroupControlType<T> | IconControlType<T> | InputFixContentControlType<T> | InputNumberControlType<T> | InputUnitControlType<T> | InputUnitSpacingControlType<T> | InputUnitWidthControlType<T> | InputControlType<T> | MarginControlType<T> | PaddingControlType<T> | PositionControlType<T> | RadioGroupControlType | RangeControlType<T> | SegmentControlType<T> | OpenLinkControlType<T> | SelectControlType<T> | TextareaControlType<T> | ToggleControlType<T> | ImageControlType<T> | ChildrensControlType | GridControlType<T> | FlexControlType<T> | TextEditorControlType<T> | ProductControlType<T> | TypographyControlType<T> | TypographyV2ControlType<T> | MenuControlType<T> | BehaviorStateControlType<T> | PickLinkControlType<T> | BoxShadowControlType<T> | TextShadowControlType<T> | BorderControlType<T> | BorderRadiusControlType<T> | RadiusPresetControlType<T> | SizeControlType<T> | ChildItemType<T> | PickMultiProductControlType<T> | CollectionControlType<T> | BackgroundControlType<T> | VisibilityControlType<T> | SelectVariantControlType | VariantListingControlType | CountdownEvergreenType | Timezone<T> | CustomContentControlType<T> | DateTimePickerControlType | CountdownDailyType | KlaviyoCodes | YotpoLoyaltyCodes | InputWidthControlType<T> | LayoutSegmentControlType<T> | InputSpacing<T> | UniqueIdControlType<T> | PositionSquareControlType<T> | CustomCodeEditor | LayoutControlType<T> | LayoutBannerControlType<T> | SwatchesLinkControlType<T> | VariantSwatchesPresetControlType<T> | VariantSwatchesOnlyDefaultVariantControlType<T> | ProductListControlType<T> | ArticleListControlType<T> | CollectionBannerControlType<T> | Ratio<T> | StickyDisplayControlType<T> | SyncProductPropertiesControlType<T> | StepsGuide<T> | ImageShape<T> | GridArrange<T> | SizeSetting$1<T> | ChildIconType<T> | DropdownInput<T> | Dropdown<T> | AliPickSectionControlType<T> | ParallaxScrollingType<T> | BackgroundColorPickerType<T> | PlayPauseControlType<T> | LayoutCustomSegmentControlType<T> | SneakPeakRange<T> | SneakPeakTypeControlType<T> | SneakPeakControlType<T> | ProductInputCurrencyUnitControlType<T> | TypographyPostPurchaseControlType<T> | ProductOffersControlType<T> | DiscountAndShippingFee<T> | PostPurchaseTextareaControlType<T> | NotesControlType<T> | ButtonLayoutType<T> | ShapeSelectorControlType<T> | DisplayTriggerControlType<T> | CustomPositionControlType<T> | DealControlType<T> | ProductHandleType<T> | ColorPickerV2ControlType<T> | BorderV2ControlType<T> | CornerV2ControlType<T> | PaddingV2ControlType<T> | BackgroundImageType<T> | BackgroundVideoType<T> | ShadowV2ControlType<T> | BackgroundMediaControlType<T> | BackgroundVideoType<T> | SwitchControlType<T> | ImageV2ControlType<T> | LayoutSelectorControlType<T> | ComboControlType<T>;
|
|
8909
9001
|
type ControlTriggerAction = {
|
|
8910
9002
|
controlId: string;
|
|
8911
9003
|
newValue?: any;
|