@lightspeed/crane 2.0.3 → 2.0.5
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/CHANGELOG.md +34 -0
- package/dist/cli.mjs +37 -21
- package/package.json +3 -2
- package/template/headers/example-header/showcases/2.ts +0 -3
- package/template/page-templates/example-template/pages/custom.ts +6 -0
- package/template/preview/shared/api-routes.ts +337 -11
- package/template/preview/shared/preview.ts +86 -30
- package/template/preview/shared/utils.ts +0 -1
- package/template/preview/vite.config.js +5 -0
- package/template/reference/sections/about-us/component/Stats.vue +2 -2
- package/template/reference/sections/about-us/settings/content.ts +28 -21
- package/template/reference/sections/about-us/settings/design.ts +1 -1
- package/template/reference/sections/about-us/showcases/1.ts +1 -0
- package/template/reference/sections/about-us/showcases/2.ts +1 -0
- package/template/reference/sections/intro-slider/component/Slider.vue +1 -1
- package/template/reference/sections/intro-slider/component/Title.vue +2 -2
- package/template/reference/sections/intro-slider/settings/content.ts +22 -1
- package/template/reference/sections/intro-slider/settings/design.ts +1 -1
- package/template/reference/sections/intro-slider/showcases/1.ts +1 -0
- package/template/reference/sections/intro-slider/showcases/2.ts +1 -0
- package/template/reference/sections/tag-lines/component/HighlightedText.vue +1 -1
- package/template/reference/sections/tag-lines/component/Title.vue +1 -1
- package/template/reference/sections/tag-lines/settings/content.ts +34 -0
- package/template/reference/sections/trending-categories/component/Title.vue +1 -1
- package/template/sections/example-section/settings/content.ts +15 -13
- package/template/sections/example-section/showcases/1.ts +0 -1
- package/template/sections/example-section/showcases/2.ts +0 -1
- package/template/sections/example-section/showcases/3.ts +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
export default {
|
|
2
2
|
title: {
|
|
3
3
|
type: 'INPUTBOX',
|
|
4
4
|
label: '$label.section_title.label',
|
|
@@ -17,15 +17,17 @@ const content: ContentEditor = {
|
|
|
17
17
|
type: 'INPUTBOX',
|
|
18
18
|
label: '$label.stat_value.label',
|
|
19
19
|
placeholder: '$label.stat_value.placeholder',
|
|
20
|
-
|
|
21
|
-
|
|
20
|
+
defaults: {
|
|
21
|
+
text: '$label.stat_value.default.text',
|
|
22
|
+
},
|
|
22
23
|
},
|
|
23
24
|
stat_caption: {
|
|
24
25
|
type: 'INPUTBOX',
|
|
25
26
|
label: '$label.stat_caption.label',
|
|
26
27
|
placeholder: '$label.stat_caption.placeholder',
|
|
27
|
-
|
|
28
|
-
|
|
28
|
+
defaults: {
|
|
29
|
+
text: '$label.stat_caption.default.text',
|
|
30
|
+
},
|
|
29
31
|
},
|
|
30
32
|
},
|
|
31
33
|
},
|
|
@@ -34,28 +36,33 @@ const content: ContentEditor = {
|
|
|
34
36
|
button: {
|
|
35
37
|
type: 'BUTTON',
|
|
36
38
|
label: '$label.button_content.label',
|
|
37
|
-
|
|
39
|
+
defaults: {
|
|
40
|
+
title: '$label.button_content.title',
|
|
41
|
+
buttonType: 'HYPER_LINK',
|
|
42
|
+
link: 'https://www.example.com',
|
|
43
|
+
},
|
|
38
44
|
},
|
|
39
45
|
image: {
|
|
40
46
|
type: 'IMAGE',
|
|
41
47
|
label: '$label.image_content.label',
|
|
42
48
|
defaults: {
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
49
|
+
imageData: {
|
|
50
|
+
set: {
|
|
51
|
+
MOBILE_WEBP_LOW_RES: {
|
|
52
|
+
url: 'our_company_in_numbers.jpg',
|
|
53
|
+
},
|
|
54
|
+
MOBILE_WEBP_HI_RES: {
|
|
55
|
+
url: 'our_company_in_numbers.jpg',
|
|
56
|
+
},
|
|
57
|
+
WEBP_LOW_RES: {
|
|
58
|
+
url: 'our_company_in_numbers.jpg',
|
|
59
|
+
},
|
|
60
|
+
WEBP_HI_2X_RES: {
|
|
61
|
+
url: 'our_company_in_numbers.jpg',
|
|
62
|
+
},
|
|
55
63
|
},
|
|
64
|
+
borderInfo: {},
|
|
56
65
|
},
|
|
57
|
-
borderInfo: {},
|
|
58
66
|
},
|
|
59
67
|
},
|
|
60
|
-
};
|
|
61
|
-
export default content;
|
|
68
|
+
} as const;
|
|
@@ -79,7 +79,7 @@ const slideImageStyles = computed<CSSProperties>(() => {
|
|
|
79
79
|
const slideTextStyles = computed<CSSProperties>(() => ({
|
|
80
80
|
fontSize: `${slideTextDesign.size}px`,
|
|
81
81
|
fontFamily: slideTextDesign.font,
|
|
82
|
-
color: (slideTextDesign.color as Color)
|
|
82
|
+
color: (slideTextDesign.color as Color)?.hex,
|
|
83
83
|
fontStyle: slideTextDesign.italic ? 'italic' : 'normal',
|
|
84
84
|
fontWeight: slideTextDesign.bold ? 'bold' : 'normal',
|
|
85
85
|
}));
|
|
@@ -37,7 +37,7 @@ const titleClass = computed(() => [
|
|
|
37
37
|
const titleStyle = computed<CSSProperties>(() => ({
|
|
38
38
|
fontSize: `${titleDesign.size}px`,
|
|
39
39
|
fontFamily: titleDesign.font,
|
|
40
|
-
color: (titleDesign.color as Color)
|
|
40
|
+
color: (titleDesign.color as Color)?.hex,
|
|
41
41
|
fontStyle: titleDesign.italic ? 'italic' : 'normal',
|
|
42
42
|
fontWeight: titleDesign.bold ? 'bold' : 'normal',
|
|
43
43
|
}));
|
|
@@ -45,7 +45,7 @@ const titleStyle = computed<CSSProperties>(() => ({
|
|
|
45
45
|
const descriptionStyle = computed<CSSProperties>(() => ({
|
|
46
46
|
fontSize: `${descriptionDesign.size}px`,
|
|
47
47
|
fontFamily: descriptionDesign.font,
|
|
48
|
-
color: (descriptionDesign.color as Color)
|
|
48
|
+
color: (descriptionDesign.color as Color)?.hex,
|
|
49
49
|
fontStyle: descriptionDesign.italic ? 'italic' : 'normal',
|
|
50
50
|
fontWeight: descriptionDesign.bold ? 'bold' : 'normal',
|
|
51
51
|
}));
|
|
@@ -17,7 +17,11 @@ export default {
|
|
|
17
17
|
section_button: {
|
|
18
18
|
type: 'BUTTON',
|
|
19
19
|
label: '$label.section_button.label',
|
|
20
|
-
|
|
20
|
+
defaults: {
|
|
21
|
+
title: '$label.section_button.title',
|
|
22
|
+
buttonType: 'HYPER_LINK',
|
|
23
|
+
link: 'https://www.example.com',
|
|
24
|
+
},
|
|
21
25
|
},
|
|
22
26
|
slider: {
|
|
23
27
|
type: 'DECK',
|
|
@@ -31,6 +35,23 @@ export default {
|
|
|
31
35
|
image_content: {
|
|
32
36
|
type: 'IMAGE',
|
|
33
37
|
label: '$label.slide_content.label',
|
|
38
|
+
imageData: {
|
|
39
|
+
set: {
|
|
40
|
+
MOBILE_WEBP_LOW_RES: {
|
|
41
|
+
url: 'category_4.jpg',
|
|
42
|
+
},
|
|
43
|
+
MOBILE_WEBP_HI_RES: {
|
|
44
|
+
url: 'category_4@2x.jpg',
|
|
45
|
+
},
|
|
46
|
+
WEBP_LOW_RES: {
|
|
47
|
+
url: 'category_4@2x.jpg',
|
|
48
|
+
},
|
|
49
|
+
WEBP_HI_2X_RES: {
|
|
50
|
+
url: 'category_4@2x.jpg',
|
|
51
|
+
},
|
|
52
|
+
},
|
|
53
|
+
borderInfo: {},
|
|
54
|
+
},
|
|
34
55
|
},
|
|
35
56
|
image_text: {
|
|
36
57
|
type: 'TEXTAREA',
|
|
@@ -14,7 +14,7 @@ const props = defineProps<{
|
|
|
14
14
|
const textStyle = computed<CSSProperties>(() => ({
|
|
15
15
|
fontSize: props.design.size ? `${props.design.size}px` : undefined,
|
|
16
16
|
fontFamily: props.design.font,
|
|
17
|
-
color: props.design.color ? (props.design.color as Color)
|
|
17
|
+
color: props.design.color ? (props.design.color as Color)?.hex : undefined,
|
|
18
18
|
fontStyle: props.design.italic ? 'italic' : 'normal',
|
|
19
19
|
fontWeight: props.design.bold ? 'bold' : 'normal',
|
|
20
20
|
}));
|
|
@@ -18,7 +18,7 @@ const titleDesign = useTextElementDesign<Design>('section_title');
|
|
|
18
18
|
const titleStyle = computed<CSSProperties>(() => ({
|
|
19
19
|
fontSize: `${titleDesign.size}px`,
|
|
20
20
|
fontFamily: titleDesign.font,
|
|
21
|
-
color: (titleDesign.color as Color)
|
|
21
|
+
color: (titleDesign.color as Color)?.hex,
|
|
22
22
|
fontStyle: titleDesign.italic ? 'italic' : 'normal',
|
|
23
23
|
fontWeigh: titleDesign.bold ? 'bold' : 'normal',
|
|
24
24
|
}));
|
|
@@ -26,6 +26,23 @@ export default {
|
|
|
26
26
|
image_content: {
|
|
27
27
|
type: 'IMAGE',
|
|
28
28
|
label: '$label.content.deck.highlighted_text_image_on_hover.label',
|
|
29
|
+
imageData: {
|
|
30
|
+
set: {
|
|
31
|
+
MOBILE_WEBP_LOW_RES: {
|
|
32
|
+
url: 'fall_is_here.jpg',
|
|
33
|
+
},
|
|
34
|
+
MOBILE_WEBP_HI_RES: {
|
|
35
|
+
url: 'fall_is_here_preview.jpg',
|
|
36
|
+
},
|
|
37
|
+
WEBP_LOW_RES: {
|
|
38
|
+
url: 'fall_is_here.jpg',
|
|
39
|
+
},
|
|
40
|
+
WEBP_HI_2X_RES: {
|
|
41
|
+
url: 'fall_is_here_preview.jpg',
|
|
42
|
+
},
|
|
43
|
+
},
|
|
44
|
+
borderInfo: {},
|
|
45
|
+
},
|
|
29
46
|
},
|
|
30
47
|
},
|
|
31
48
|
},
|
|
@@ -34,5 +51,22 @@ export default {
|
|
|
34
51
|
section_image: {
|
|
35
52
|
type: 'IMAGE',
|
|
36
53
|
label: '$label.content.image_title.label',
|
|
54
|
+
imageData: {
|
|
55
|
+
set: {
|
|
56
|
+
MOBILE_WEBP_LOW_RES: {
|
|
57
|
+
url: 'fall_is_here.jpg',
|
|
58
|
+
},
|
|
59
|
+
MOBILE_WEBP_HI_RES: {
|
|
60
|
+
url: 'fall_is_here.jpg',
|
|
61
|
+
},
|
|
62
|
+
WEBP_LOW_RES: {
|
|
63
|
+
url: 'fall_is_here.jpg',
|
|
64
|
+
},
|
|
65
|
+
WEBP_HI_2X_RES: {
|
|
66
|
+
url: 'fall_is_here.jpg',
|
|
67
|
+
},
|
|
68
|
+
},
|
|
69
|
+
borderInfo: {},
|
|
70
|
+
},
|
|
37
71
|
},
|
|
38
72
|
} as const;
|
|
@@ -18,7 +18,7 @@ const titleDesign = useTextElementDesign<Design>('section_title');
|
|
|
18
18
|
const titleStyle = computed(() => ({
|
|
19
19
|
fontSize: `${titleDesign.size}px`,
|
|
20
20
|
fontFamily: titleDesign.font,
|
|
21
|
-
color: (titleDesign.color as Color)
|
|
21
|
+
color: (titleDesign.color as Color)?.hex,
|
|
22
22
|
'font-style': titleDesign.italic ? 'italic' : 'normal',
|
|
23
23
|
'font-weight': titleDesign.bold ? 'bold' : 'normal',
|
|
24
24
|
}));
|
|
@@ -26,21 +26,23 @@ export default {
|
|
|
26
26
|
type: 'IMAGE',
|
|
27
27
|
label: '$label.image_content_1.label',
|
|
28
28
|
defaults: {
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
29
|
+
imageData: {
|
|
30
|
+
set: {
|
|
31
|
+
MOBILE_WEBP_LOW_RES: {
|
|
32
|
+
url: 'new_arrivals_mobile_low.jpeg',
|
|
33
|
+
},
|
|
34
|
+
MOBILE_WEBP_HI_RES: {
|
|
35
|
+
url: 'new_arrivals_mobile_high.jpeg',
|
|
36
|
+
},
|
|
37
|
+
WEBP_LOW_RES: {
|
|
38
|
+
url: 'new_arrivals_pc_low.jpeg',
|
|
39
|
+
},
|
|
40
|
+
WEBP_HI_2X_RES: {
|
|
41
|
+
url: 'new_arrivals_pc_high.jpeg',
|
|
42
|
+
},
|
|
41
43
|
},
|
|
44
|
+
borderInfo: {},
|
|
42
45
|
},
|
|
43
|
-
borderInfo: {},
|
|
44
46
|
},
|
|
45
47
|
},
|
|
46
48
|
image_text: {
|