@lightspeed/crane 2.0.5 → 3.0.0

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 (131) hide show
  1. package/CHANGELOG.md +34 -0
  2. package/UPGRADE.md +96 -0
  3. package/dist/cli.mjs +44 -25
  4. package/package.json +6 -3
  5. package/template/blank/sections/blank-section/BlankSection.vue +9 -0
  6. package/template/blank/sections/blank-section/assets/blank_section_showcase_1_preview.jpg +0 -0
  7. package/template/blank/sections/blank-section/client.ts +6 -0
  8. package/template/blank/sections/blank-section/server.ts +6 -0
  9. package/template/blank/sections/blank-section/settings/content.ts +2 -0
  10. package/template/blank/sections/blank-section/settings/design.ts +2 -0
  11. package/template/blank/sections/blank-section/settings/layout.ts +2 -0
  12. package/template/blank/sections/blank-section/settings/translations.ts +8 -0
  13. package/template/blank/sections/blank-section/showcases/1.ts +15 -0
  14. package/template/blank/sections/blank-section/showcases/translations.ts +10 -0
  15. package/template/blank/sections/blank-section/type.ts +5 -0
  16. package/template/collections/assets/collection_cover_image.png +0 -0
  17. package/template/collections/example-collection/configuration.ts +21 -0
  18. package/template/crane.config.json +1 -1
  19. package/template/footers/example-footer/ExampleFooter.vue +4 -4
  20. package/template/footers/example-footer/component/LegalLinks.vue +1 -1
  21. package/template/footers/example-footer/component/MadeWith.vue +1 -1
  22. package/template/footers/example-footer/component/ReportAbuse.vue +1 -1
  23. package/template/footers/example-footer/settings/design.ts +5 -4
  24. package/template/footers/example-footer/settings/translations.ts +4 -3
  25. package/template/footers/example-footer/showcases/1.ts +4 -2
  26. package/template/footers/example-footer/showcases/translations.ts +4 -2
  27. package/template/headers/example-header/ExampleHeader.vue +1 -1
  28. package/template/headers/example-header/component/Account.vue +1 -1
  29. package/template/headers/example-header/component/CategoriesDropdown.vue +1 -1
  30. package/template/headers/example-header/component/Logo.vue +7 -7
  31. package/template/headers/example-header/component/NavigationMenu.vue +1 -1
  32. package/template/headers/example-header/settings/content.ts +8 -1
  33. package/template/headers/example-header/settings/design.ts +7 -1
  34. package/template/headers/example-header/settings/layout.ts +1 -1
  35. package/template/headers/example-header/settings/translations.ts +4 -2
  36. package/template/headers/example-header/showcases/1.ts +15 -11
  37. package/template/headers/example-header/showcases/2.ts +12 -8
  38. package/template/headers/example-header/showcases/translations.ts +4 -2
  39. package/template/layouts/catalog/example-catalog/components/Icon.vue +14 -14
  40. package/template/layouts/catalog/example-catalog/slots/custom-bottom-bar/CustomBottomBar.vue +1 -1
  41. package/template/package.json +1 -0
  42. package/template/page-templates/example-template/configuration.ts +8 -10
  43. package/template/page-templates/example-template/pages/catalog.ts +3 -6
  44. package/template/page-templates/example-template/pages/category.ts +3 -6
  45. package/template/page-templates/example-template/pages/home.ts +42 -57
  46. package/template/page-templates/example-template/pages/product.ts +3 -6
  47. package/template/preview/sections/preview.html +10 -6
  48. package/template/preview/shared/api-routes.ts +235 -102
  49. package/template/preview/shared/logger.ts +9 -0
  50. package/template/preview/shared/preview.ts +108 -72
  51. package/template/preview/shared/utils.ts +63 -43
  52. package/template/preview/ssr-server.ts +1 -1
  53. package/template/reference/sections/about-us/AboutUs.vue +20 -22
  54. package/template/reference/sections/about-us/component/Image.vue +18 -18
  55. package/template/reference/sections/about-us/component/Stats.vue +40 -40
  56. package/template/reference/sections/about-us/component/Title.vue +1 -1
  57. package/template/reference/sections/about-us/settings/content.ts +15 -19
  58. package/template/reference/sections/about-us/settings/design.ts +14 -18
  59. package/template/reference/sections/about-us/settings/layout.ts +7 -5
  60. package/template/reference/sections/about-us/settings/translations.ts +4 -2
  61. package/template/reference/sections/about-us/showcases/1.ts +48 -62
  62. package/template/reference/sections/about-us/showcases/2.ts +44 -56
  63. package/template/reference/sections/about-us/showcases/translations.ts +4 -2
  64. package/template/reference/sections/featured-products/FeaturedProducts.vue +12 -6
  65. package/template/reference/sections/featured-products/component/ProductItem.vue +18 -1
  66. package/template/reference/sections/featured-products/component/ProductPlaceholder.vue +42 -0
  67. package/template/reference/sections/featured-products/component/Title.vue +1 -1
  68. package/template/reference/sections/featured-products/settings/content.ts +8 -10
  69. package/template/reference/sections/featured-products/settings/design.ts +7 -7
  70. package/template/reference/sections/featured-products/settings/translations.ts +4 -2
  71. package/template/reference/sections/featured-products/showcases/1.ts +8 -12
  72. package/template/reference/sections/featured-products/showcases/translations.ts +4 -2
  73. package/template/reference/sections/intro-slider/IntroSlider.vue +6 -6
  74. package/template/reference/sections/intro-slider/component/Slider.vue +42 -43
  75. package/template/reference/sections/intro-slider/component/Title.vue +7 -7
  76. package/template/reference/sections/intro-slider/settings/content.ts +33 -36
  77. package/template/reference/sections/intro-slider/settings/design.ts +17 -22
  78. package/template/reference/sections/intro-slider/settings/layout.ts +6 -4
  79. package/template/reference/sections/intro-slider/settings/translations.ts +4 -2
  80. package/template/reference/sections/intro-slider/showcases/1.ts +52 -75
  81. package/template/reference/sections/intro-slider/showcases/2.ts +50 -72
  82. package/template/reference/sections/intro-slider/showcases/translations.ts +4 -2
  83. package/template/reference/sections/tag-lines/TagLines.vue +41 -47
  84. package/template/reference/sections/tag-lines/component/HighlightedText.vue +1 -1
  85. package/template/reference/sections/tag-lines/component/SectionImage.vue +18 -18
  86. package/template/reference/sections/tag-lines/component/Title.vue +1 -1
  87. package/template/reference/sections/tag-lines/settings/content.ts +47 -47
  88. package/template/reference/sections/tag-lines/settings/design.ts +15 -19
  89. package/template/reference/sections/tag-lines/settings/layout.ts +6 -4
  90. package/template/reference/sections/tag-lines/settings/translations.ts +4 -2
  91. package/template/reference/sections/tag-lines/showcases/1.ts +40 -50
  92. package/template/reference/sections/tag-lines/showcases/2.ts +40 -50
  93. package/template/reference/sections/tag-lines/showcases/translations.ts +4 -2
  94. package/template/reference/sections/trending-categories/TrendingCategories.vue +1 -1
  95. package/template/reference/sections/trending-categories/component/CategoryItem.vue +18 -1
  96. package/template/reference/sections/trending-categories/component/Title.vue +1 -1
  97. package/template/reference/sections/trending-categories/settings/content.ts +8 -10
  98. package/template/reference/sections/trending-categories/settings/design.ts +7 -7
  99. package/template/reference/sections/trending-categories/settings/translations.ts +4 -2
  100. package/template/reference/sections/trending-categories/showcases/1.ts +14 -15
  101. package/template/reference/sections/trending-categories/showcases/translations.ts +4 -2
  102. package/template/reference/shared/components/Button.vue +6 -6
  103. package/template/reference/shared/components/SectionWrapper.vue +5 -5
  104. package/template/reference/shared/components/Tagline.vue +12 -11
  105. package/template/reference/templates/reference-template-apparel/configuration.ts +8 -8
  106. package/template/reference/templates/reference-template-apparel/pages/catalog.ts +3 -6
  107. package/template/reference/templates/reference-template-apparel/pages/category.ts +3 -6
  108. package/template/reference/templates/reference-template-apparel/pages/home.ts +14 -18
  109. package/template/reference/templates/reference-template-apparel/pages/product.ts +3 -6
  110. package/template/reference/templates/reference-template-bike/configuration.ts +9 -9
  111. package/template/reference/templates/reference-template-bike/pages/catalog.ts +3 -6
  112. package/template/reference/templates/reference-template-bike/pages/category.ts +3 -6
  113. package/template/reference/templates/reference-template-bike/pages/home.ts +14 -18
  114. package/template/reference/templates/reference-template-bike/pages/product.ts +3 -6
  115. package/template/sections/example-section/ExampleSection.vue +3 -5
  116. package/template/sections/example-section/component/button/Button.vue +1 -1
  117. package/template/sections/example-section/component/image/Image.vue +43 -43
  118. package/template/sections/example-section/component/image/ImagesGrid.vue +21 -32
  119. package/template/sections/example-section/component/selectbox/Selectbox.vue +1 -1
  120. package/template/sections/example-section/component/title/Title.vue +1 -1
  121. package/template/sections/example-section/component/toggle/Toggle.vue +4 -4
  122. package/template/sections/example-section/settings/content.ts +25 -34
  123. package/template/sections/example-section/settings/design.ts +15 -19
  124. package/template/sections/example-section/settings/layout.ts +15 -14
  125. package/template/sections/example-section/settings/translations.ts +4 -2
  126. package/template/sections/example-section/showcases/1.ts +52 -79
  127. package/template/sections/example-section/showcases/2.ts +46 -62
  128. package/template/sections/example-section/showcases/3.ts +50 -76
  129. package/template/sections/example-section/showcases/translations.ts +4 -2
  130. package/template/shared/components/LanguageSelector.vue +1 -1
  131. package/template/shared/components/SectionWrapper.vue +5 -5
@@ -1,4 +1,6 @@
1
- export default {
1
+ import { content, design, showcase } from '@lightspeed/crane-api';
2
+
3
+ export default showcase.init({
2
4
  showcaseId: '2',
3
5
  layoutId: 'Wide_Title_And_Images_Without_Border_Radius',
4
6
  previewImage: {
@@ -10,31 +12,25 @@ export default {
10
12
  },
11
13
  blockName: '$label.showcase_2.blockName',
12
14
  content: {
13
- section_title: {
14
- type: 'TEXTAREA',
15
+ section_title: content.default.textarea({
15
16
  text: '$label.showcase_2.section_title.text',
16
- },
17
- section_tagline: {
18
- type: 'INPUTBOX',
17
+ }),
18
+ section_tagline: content.default.inputbox({
19
19
  text: '$label.showcase_2.section_tagline.text',
20
- },
21
- section_button: {
22
- type: 'BUTTON',
20
+ }),
21
+ section_button: content.default.button({
23
22
  title: '$label.showcase_2.section_button.title',
24
23
  buttonType: 'HYPER_LINK',
25
24
  link: 'https://www.example.com',
26
- },
27
- slider: {
28
- type: 'DECK',
25
+ }),
26
+ slider: content.default.deck({
29
27
  cards: [
30
28
  {
31
29
  settings: {
32
- image_text: {
33
- type: 'INPUTBOX',
30
+ image_text: content.default.inputbox({
34
31
  text: '$label.showcase_2.slide_text_1.text',
35
- },
36
- image_content: {
37
- type: 'IMAGE',
32
+ }),
33
+ image_content: content.default.image({
38
34
  imageData: {
39
35
  set: {
40
36
  MOBILE_WEBP_LOW_RES: {
@@ -52,17 +48,15 @@ export default {
52
48
  },
53
49
  borderInfo: {},
54
50
  },
55
- },
51
+ }),
56
52
  },
57
53
  },
58
54
  {
59
55
  settings: {
60
- image_text: {
61
- type: 'INPUTBOX',
56
+ image_text: content.default.inputbox({
62
57
  text: '$label.showcase_2.slide_text_2.text',
63
- },
64
- image_content: {
65
- type: 'IMAGE',
58
+ }),
59
+ image_content: content.default.image({
66
60
  imageData: {
67
61
  set: {
68
62
  MOBILE_WEBP_LOW_RES: {
@@ -80,17 +74,15 @@ export default {
80
74
  },
81
75
  borderInfo: {},
82
76
  },
83
- },
77
+ }),
84
78
  },
85
79
  },
86
80
  {
87
81
  settings: {
88
- image_text: {
89
- type: 'INPUTBOX',
82
+ image_text: content.default.inputbox({
90
83
  text: '$label.showcase_2.slide_text_3.text',
91
- },
92
- image_content: {
93
- type: 'IMAGE',
84
+ }),
85
+ image_content: content.default.image({
94
86
  imageData: {
95
87
  set: {
96
88
  MOBILE_WEBP_LOW_RES: {
@@ -108,17 +100,15 @@ export default {
108
100
  },
109
101
  borderInfo: {},
110
102
  },
111
- },
103
+ }),
112
104
  },
113
105
  },
114
106
  {
115
107
  settings: {
116
- image_text: {
117
- type: 'INPUTBOX',
108
+ image_text: content.default.inputbox({
118
109
  text: '$label.showcase_2.slide_text_4.text',
119
- },
120
- image_content: {
121
- type: 'IMAGE',
110
+ }),
111
+ image_content: content.default.image({
122
112
  imageData: {
123
113
  set: {
124
114
  MOBILE_WEBP_LOW_RES: {
@@ -136,18 +126,15 @@ export default {
136
126
  },
137
127
  borderInfo: {},
138
128
  },
139
- },
129
+ }),
140
130
  },
141
131
  },
142
132
  {
143
-
144
133
  settings: {
145
- image_text: {
146
- type: 'INPUTBOX',
134
+ image_text: content.default.inputbox({
147
135
  text: '$label.showcase_2.slide_text_5.text',
148
- },
149
- image_content: {
150
- type: 'IMAGE',
136
+ }),
137
+ image_content: content.default.image({
151
138
  imageData: {
152
139
  set: {
153
140
  MOBILE_WEBP_LOW_RES: {
@@ -165,17 +152,15 @@ export default {
165
152
  },
166
153
  borderInfo: {},
167
154
  },
168
- },
155
+ }),
169
156
  },
170
157
  },
171
158
  {
172
159
  settings: {
173
- image_text: {
174
- type: 'INPUTBOX',
160
+ image_text: content.default.inputbox({
175
161
  text: '$label.showcase_2.slide_text_6.text',
176
- },
177
- image_content: {
178
- type: 'IMAGE',
162
+ }),
163
+ image_content: content.default.image({
179
164
  imageData: {
180
165
  set: {
181
166
  MOBILE_WEBP_LOW_RES: {
@@ -193,62 +178,55 @@ export default {
193
178
  },
194
179
  borderInfo: {},
195
180
  },
196
- },
181
+ }),
197
182
  },
198
183
  },
199
184
  ],
200
- },
185
+ }),
201
186
  },
202
187
  design: {
203
- section_title: {
204
- type: 'TEXT',
188
+ section_title: design.default.text({
205
189
  font: 'pt_mono',
206
190
  size: 48,
207
191
  bold: true,
208
192
  italic: false,
209
193
  color: '#FFFFFF',
210
- },
211
- section_description: {
212
- type: 'TEXT',
194
+ }),
195
+ section_description: design.default.text({
213
196
  font: 'inter',
214
197
  size: 16,
215
198
  bold: true,
216
199
  italic: false,
217
200
  color: '#FFFFFF',
218
- },
219
- section_tagline: {
220
- type: 'TEXT',
201
+ }),
202
+ section_tagline: design.default.text({
221
203
  font: 'pt_mono',
222
204
  size: 16,
223
205
  bold: false,
224
206
  italic: false,
225
207
  color: '#FFB92E',
226
- },
227
- section_button: {
228
- type: 'BUTTON',
208
+ }),
209
+ section_button: design.default.button({
229
210
  font: 'inter',
230
211
  appearance: 'SOLID',
231
212
  size: 'LARGE',
232
213
  shape: 'RECTANGLE',
233
214
  color: '#FFFFFF',
234
- },
235
- background: {
236
- type: 'BACKGROUND',
215
+ }),
216
+ background: design.default.background({
237
217
  style: 'COLOR',
238
218
  color: '#000000',
239
- },
240
- image_text: {
241
- type: 'TEXT',
219
+ }),
220
+ image_text: design.default.text({
242
221
  font: 'pt_mono',
243
222
  size: 24,
244
223
  bold: true,
245
224
  italic: false,
246
225
  color: '#FFFFFF',
247
- },
248
- image_content: {
249
- type: 'IMAGE',
226
+ }),
227
+ image_content: design.default.image({
250
228
  overlay: 'GRADIENT',
251
229
  color: ['#000000', '#000000'],
252
- },
230
+ }),
253
231
  },
254
- } as const;
232
+ });
@@ -1,4 +1,6 @@
1
- export default {
1
+ import { translation } from '@lightspeed/crane-api';
2
+
3
+ export default translation.init({
2
4
  en: {
3
5
  '$label.showcase_1.blockName': 'Reference Section — Slider',
4
6
 
@@ -85,4 +87,4 @@ export default {
85
87
  '$label.showcase_2.slide_text_5.text': 'Nom du vélo 5',
86
88
  '$label.showcase_2.slide_text_6.text': 'Nom du vélo 6',
87
89
  },
88
- } as const;
90
+ });
@@ -94,65 +94,59 @@ const {
94
94
 
95
95
  </script>
96
96
 
97
- <style lang="scss" scoped>
98
- .tag-lines-section {
99
- &__wrapper {
100
- display: flex;
101
- flex-direction: column;
102
- align-items: center;
103
- gap: 24px;
104
-
105
- @media screen and (min-width: 900px) {
106
- flex-direction: row;
107
- justify-content: space-between;
108
- }
97
+ <style scoped>
98
+ .tag-lines-section__wrapper {
99
+ display: flex;
100
+ flex-direction: column;
101
+ align-items: center;
102
+ gap: 24px;
103
+
104
+ @media screen and (min-width: 900px) {
105
+ flex-direction: row;
106
+ justify-content: space-between;
109
107
  }
108
+ }
110
109
 
111
- &__info {
112
- width: 100%;
110
+ .tag-lines-section__info {
111
+ width: 100%;
113
112
 
114
- @media screen and (min-width: 900px) {
115
- width: unset;
116
- max-width: 530px;
117
- }
113
+ @media screen and (min-width: 900px) {
114
+ width: unset;
115
+ max-width: 530px;
118
116
  }
117
+ }
119
118
 
120
- &__tagline {
121
- margin-bottom: 24px;
122
- }
119
+ .tag-lines-section__tagline {
120
+ margin-bottom: 24px;
121
+ }
123
122
 
124
- &__image {
125
- width: 100%;
123
+ .tag-lines-section__image {
124
+ width: 100%;
126
125
 
127
- @media screen and (min-width: 900px) {
128
- max-width: 479px;
129
- }
126
+ @media screen and (min-width: 900px) {
127
+ max-width: 479px;
130
128
  }
129
+ }
131
130
 
132
- &::v-deep(.tag-lines-section__highlighted-texts:has(.tag-lines-section__highlighted-text:hover)) {
133
- & .tag-lines-section__highlighted-text {
134
- opacity: 0.2;
131
+ .tag-lines-section::v-deep(.tag-lines-section__highlighted-texts:has(.tag-lines-section__highlighted-text:hover)) .tag-lines-section__highlighted-text {
132
+ opacity: 0.2;
133
+ }
135
134
 
136
- &:hover {
137
- opacity: 1;
138
- }
139
- }
140
- }
135
+ .tag-lines-section::v-deep(.tag-lines-section__highlighted-texts:has(.tag-lines-section__highlighted-text:hover)) .tag-lines-section__highlighted-text:hover {
136
+ opacity: 1;
137
+ }
141
138
 
142
- &__highlighted-text {
143
- transition: opacity ease-in-out 0.3s;
144
- }
139
+ .tag-lines-section__highlighted-text {
140
+ transition: opacity ease-in-out 0.3s;
141
+ }
145
142
 
146
- &:has(.tag-lines-section__highlighted-text:hover) {
147
- &::v-deep(.section-image__element) {
148
- opacity: 0;
149
- }
150
- }
143
+ .tag-lines-section:has(.tag-lines-section__highlighted-text:hover)::v-deep(.section-image__element) {
144
+ opacity: 0;
145
+ }
151
146
 
152
- &:has(.tag-lines-section__highlighted-text--1:hover)::v-deep(.section-image__element--1),
153
- &:has(.tag-lines-section__highlighted-text--2:hover)::v-deep(.section-image__element--2),
154
- &:has(.tag-lines-section__highlighted-text--3:hover)::v-deep(.section-image__element--3) {
155
- opacity: 1;
156
- }
147
+ .tag-lines-section:has(.tag-lines-section__highlighted-text--1:hover)::v-deep(.section-image__element--1),
148
+ .tag-lines-section:has(.tag-lines-section__highlighted-text--2:hover)::v-deep(.section-image__element--2),
149
+ .tag-lines-section:has(.tag-lines-section__highlighted-text--3:hover)::v-deep(.section-image__element--3) {
150
+ opacity: 1;
157
151
  }
158
152
  </style>
@@ -20,7 +20,7 @@ const textStyle = computed<CSSProperties>(() => ({
20
20
  }));
21
21
  </script>
22
22
 
23
- <style lang="scss" scoped>
23
+ <style scoped>
24
24
  .highlighted-text {
25
25
  --font-size: v-bind(textStyle.fontSize);
26
26
  --font-family: v-bind(textStyle.fontFamily);
@@ -47,32 +47,32 @@ const imageClass = computed(() => [
47
47
  ]);
48
48
  </script>
49
49
 
50
- <style lang="scss" scoped>
50
+ <style scoped>
51
51
  .section-image {
52
52
  position: relative;
53
53
  overflow: hidden;
54
54
  aspect-ratio: 0.785;
55
+ }
55
56
 
56
- &--with-border-radius {
57
- border-radius: 24px;
57
+ .section-image--with-border-radius {
58
+ border-radius: 24px;
58
59
 
59
- @media screen and (min-width: 1200px) {
60
- border-radius: 32px;
61
- }
60
+ @media screen and (min-width: 1200px) {
61
+ border-radius: 32px;
62
62
  }
63
+ }
63
64
 
64
- &__element {
65
- position: absolute;
66
- top: 0;
67
- left: 0;
68
- width: 100%;
69
- height: 100%;
70
- object-fit: cover;
71
- transition: opacity 0.3s ease-in-out;
65
+ .section-image__element {
66
+ position: absolute;
67
+ top: 0;
68
+ left: 0;
69
+ width: 100%;
70
+ height: 100%;
71
+ object-fit: cover;
72
+ transition: opacity 0.3s ease-in-out;
73
+ }
72
74
 
73
- &--highlighted {
74
- opacity: 0;
75
- }
76
- }
75
+ .section-image__element--highlighted {
76
+ opacity: 0;
77
77
  }
78
78
  </style>
@@ -24,7 +24,7 @@ const titleStyle = computed<CSSProperties>(() => ({
24
24
  }));
25
25
  </script>
26
26
 
27
- <style lang="scss" scoped>
27
+ <style scoped>
28
28
  .title {
29
29
  --font-size: v-bind(titleStyle.fontSize);
30
30
  --font-family: v-bind(titleStyle.fontFamily);
@@ -1,16 +1,15 @@
1
+ import { content } from '@lightspeed/crane-api';
2
+
1
3
  export default {
2
- section_tagline: {
3
- type: 'INPUTBOX',
4
+ section_tagline: content.inputbox({
4
5
  label: '$label.content.tagline.label',
5
6
  placeholder: '$label.content.tagline.placeholder',
6
- },
7
- section_title: {
8
- type: 'INPUTBOX',
7
+ }),
8
+ section_title: content.inputbox({
9
9
  label: '$label.content.section_title.label',
10
10
  placeholder: '$label.content.section_title.placeholder',
11
- },
12
- highlighted_text: {
13
- type: 'DECK',
11
+ }),
12
+ highlighted_text: content.deck({
14
13
  label: '$label.content.highlighted_text_title.label',
15
14
  addButtonLabel: '$label.content.deck.highlighted_text.add_button',
16
15
  maxCards: 3,
@@ -18,55 +17,56 @@ export default {
18
17
  defaultCardContent: {
19
18
  label: '$label.content.highlighted_text.label',
20
19
  settings: {
21
- text: {
22
- type: 'INPUTBOX',
20
+ text: content.inputbox({
23
21
  label: '$label.content.deck.highlighted_text.label',
24
22
  placeholder: '$label.content.deck.highlighted_text.label',
25
- },
26
- image_content: {
27
- type: 'IMAGE',
23
+ }),
24
+ image_content: content.image({
28
25
  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',
26
+ defaults: {
27
+ imageData: {
28
+ set: {
29
+ MOBILE_WEBP_LOW_RES: {
30
+ url: 'fall_is_here.jpg',
31
+ },
32
+ MOBILE_WEBP_HI_RES: {
33
+ url: 'fall_is_here_preview.jpg',
34
+ },
35
+ WEBP_LOW_RES: {
36
+ url: 'fall_is_here.jpg',
37
+ },
38
+ WEBP_HI_2X_RES: {
39
+ url: 'fall_is_here_preview.jpg',
40
+ },
42
41
  },
42
+ borderInfo: {},
43
43
  },
44
- borderInfo: {},
45
44
  },
46
- },
45
+ }),
47
46
  },
48
47
  },
49
48
  },
50
- },
51
- section_image: {
52
- type: 'IMAGE',
49
+ }),
50
+ section_image: content.image({
53
51
  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',
52
+ defaults: {
53
+ imageData: {
54
+ set: {
55
+ MOBILE_WEBP_LOW_RES: {
56
+ url: 'fall_is_here.jpg',
57
+ },
58
+ MOBILE_WEBP_HI_RES: {
59
+ url: 'fall_is_here.jpg',
60
+ },
61
+ WEBP_LOW_RES: {
62
+ url: 'fall_is_here.jpg',
63
+ },
64
+ WEBP_HI_2X_RES: {
65
+ url: 'fall_is_here.jpg',
66
+ },
67
67
  },
68
+ borderInfo: {},
68
69
  },
69
- borderInfo: {},
70
70
  },
71
- },
72
- } as const;
71
+ }),
72
+ };
@@ -1,15 +1,15 @@
1
+ import { design } from '@lightspeed/crane-api';
2
+
1
3
  export default {
2
- background: {
3
- type: 'BACKGROUND',
4
+ background: design.background({
4
5
  label: '$label.design.background.label',
5
6
  colors: ['#FFFFFF', '#000000', '#F4EFE3', '#FFBF24', '#6281C5', '#C5629A', '#BAA33E', '#8A91D0', '#C3455C'],
6
7
  defaults: {
7
8
  style: 'COLOR',
8
9
  color: '#FFFFFF',
9
10
  },
10
- },
11
- section_tagline: {
12
- type: 'TEXT',
11
+ }),
12
+ section_tagline: design.text({
13
13
  label: '$label.design.tagline.label',
14
14
  colors: ['#FFFFFF', '#000000', '#F4EFE3', '#FFBF24', '#6281C5', '#C5629A', '#BAA33E', '#8A91D0', '#C3455C'],
15
15
  sizes: [12, 13, 14, 15, 16, 17, 18, 20],
@@ -21,9 +21,8 @@ export default {
21
21
  color: '#F4EFE3',
22
22
  visible: true,
23
23
  },
24
- },
25
- section_title: {
26
- type: 'TEXT',
24
+ }),
25
+ section_title: design.text({
27
26
  label: '$label.design.section_title.label',
28
27
  colors: ['#FFFFFF', '#000000', '#F4EFE3', '#FFBF24', '#6281C5', '#C5629A', '#BAA33E', '#8A91D0', '#C3455C'],
29
28
  sizes: [18, 20, 22, 24, 26, 28, 30, 32, 34, 36, 38, 40, 42, 44, 46, 48, 50, 52, 54, 56, 58, 60],
@@ -35,9 +34,8 @@ export default {
35
34
  color: '#000000',
36
35
  visible: true,
37
36
  },
38
- },
39
- highlighted_text_1: {
40
- type: 'TEXT',
37
+ }),
38
+ highlighted_text_1: design.text({
41
39
  label: '$label.design.highlighted_text_1.label',
42
40
  colors: ['#FFFFFF', '#000000', '#F4EFE3', '#FFBF24', '#6281C5', '#C5629A', '#BAA33E', '#8A91D0', '#C3455C'],
43
41
  sizes: [18, 20, 22, 24, 26, 28, 30, 32, 34, 36, 38, 40, 42, 44, 46, 48, 50, 52, 54, 56, 58, 60],
@@ -49,9 +47,8 @@ export default {
49
47
  color: '#FFBF24',
50
48
  visible: true,
51
49
  },
52
- },
53
- highlighted_text_2: {
54
- type: 'TEXT',
50
+ }),
51
+ highlighted_text_2: design.text({
55
52
  label: '$label.design.highlighted_text_2.label',
56
53
  colors: ['#FFFFFF', '#000000', '#F4EFE3', '#FFBF24', '#6281C5', '#C5629A', '#BAA33E', '#8A91D0', '#C3455C'],
57
54
  sizes: [18, 20, 22, 24, 26, 28, 30, 32, 34, 36, 38, 40, 42, 44, 46, 48, 50, 52, 54, 56, 58, 60],
@@ -63,9 +60,8 @@ export default {
63
60
  color: '#6281C5',
64
61
  visible: true,
65
62
  },
66
- },
67
- highlighted_text_3: {
68
- type: 'TEXT',
63
+ }),
64
+ highlighted_text_3: design.text({
69
65
  label: '$label.design.highlighted_text_3.label',
70
66
  colors: ['#FFFFFF', '#000000', '#F4EFE3', '#FFBF24', '#6281C5', '#C5629A', '#BAA33E', '#8A91D0', '#C3455C'],
71
67
  sizes: [18, 20, 22, 24, 26, 28, 30, 32, 34, 36, 38, 40, 42, 44, 46, 48, 50, 52, 54, 56, 58, 60],
@@ -77,5 +73,5 @@ export default {
77
73
  color: '#C5629A',
78
74
  visible: true,
79
75
  },
80
- },
81
- } as const;
76
+ }),
77
+ };
@@ -1,12 +1,14 @@
1
+ import { layout } from '@lightspeed/crane-api';
2
+
1
3
  export default [
2
- {
4
+ layout.init({
3
5
  layoutId: 'Image_With_Border_Radius',
4
6
  selectedContentSettings: [],
5
7
  selectedDesignSettings: [],
6
- },
7
- {
8
+ }),
9
+ layout.init({
8
10
  layoutId: 'Image_Without_Border_Radius',
9
11
  selectedContentSettings: [],
10
12
  selectedDesignSettings: [],
11
- },
13
+ }),
12
14
  ];
@@ -1,4 +1,6 @@
1
- export default {
1
+ import { translation } from '@lightspeed/crane-api';
2
+
3
+ export default translation.init({
2
4
  en: {
3
5
  '$label.content.tagline.label': 'Tagline',
4
6
  '$label.content.section_title.label': 'Title',
@@ -58,4 +60,4 @@ export default {
58
60
  '$label.design.highlighted_text_2.label': 'Texte en surbrillance 2',
59
61
  '$label.design.highlighted_text_3.label': 'Texte en surbrillance 3',
60
62
  },
61
- } as const;
63
+ });