@lightspeed/crane 1.3.2 → 1.4.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 (24) hide show
  1. package/CHANGELOG.md +27 -0
  2. package/dist/app.d.mts +616 -8
  3. package/dist/app.d.ts +616 -8
  4. package/dist/cli.mjs +7 -7
  5. package/package.json +3 -3
  6. package/template/_gitignore +1 -0
  7. package/template/preview/sections/preview.html +2 -0
  8. package/template/preview/shared/mock.ts +175 -0
  9. package/template/preview/shared/preview.ts +104 -26
  10. package/template/preview/vite.config.js +49 -7
  11. package/template/reference/templates/reference-template-apparel/configuration.ts +22 -0
  12. package/template/reference/templates/reference-template-apparel/pages/catalog.ts +10 -0
  13. package/template/reference/templates/reference-template-apparel/pages/category.ts +10 -0
  14. package/template/reference/templates/reference-template-apparel/pages/home.ts +24 -0
  15. package/template/reference/templates/reference-template-apparel/pages/product.ts +10 -0
  16. package/template/reference/templates/reference-template-bike/configuration.ts +22 -0
  17. package/template/reference/templates/reference-template-bike/pages/catalog.ts +10 -0
  18. package/template/reference/templates/reference-template-bike/pages/category.ts +10 -0
  19. package/template/reference/templates/reference-template-bike/pages/home.ts +24 -0
  20. package/template/reference/templates/reference-template-bike/pages/product.ts +10 -0
  21. package/template/reference/templates/reference-template-apparel.ts +0 -44
  22. package/template/reference/templates/reference-template-bike.ts +0 -44
  23. package/template/templates/assets/template_cover_image.png +0 -0
  24. package/template/templates/template.ts +0 -198
@@ -1,44 +0,0 @@
1
- export default {
2
- metadata: {
3
- name: 'Reference Template — Apparel',
4
- description: 'This is a reference template geared towards apparel merchants to aid development and act as a starting point for your custom template.',
5
- preview_url: 'https://reference-template-apparel.company.site/',
6
- cover_image: {
7
- set: {
8
- ORIGINAL: {
9
- url: 'reference_template_apparel_cover_image.jpg',
10
- },
11
- },
12
- },
13
- },
14
- sections: [
15
- {
16
- type: 'default',
17
- id: 'header',
18
- },
19
- {
20
- type: 'custom',
21
- id: 'intro-slider',
22
- showcase_id: '1',
23
- },
24
- {
25
- type: 'custom',
26
- id: 'tag-lines',
27
- showcase_id: '1',
28
- },
29
- {
30
- type: 'custom',
31
- id: 'about-us',
32
- showcase_id: '1',
33
- },
34
- {
35
- type: 'custom',
36
- id: 'example-section',
37
- showcase_id: '1',
38
- },
39
- {
40
- type: 'default',
41
- id: 'footer',
42
- },
43
- ],
44
- };
@@ -1,44 +0,0 @@
1
- export default {
2
- metadata: {
3
- name: 'Reference Template — Bike',
4
- description: 'This is a reference template geared towards bike shops to aid development and act as a starting point for your custom template.',
5
- preview_url: 'https://reference-template-bike.company.site/',
6
- cover_image: {
7
- set: {
8
- ORIGINAL: {
9
- url: 'reference_template_bike_cover_image.jpg',
10
- },
11
- },
12
- },
13
- },
14
- sections: [
15
- {
16
- type: 'default',
17
- id: 'header',
18
- },
19
- {
20
- type: 'custom',
21
- id: 'intro-slider',
22
- showcase_id: '2',
23
- },
24
- {
25
- type: 'custom',
26
- id: 'example-section',
27
- showcase_id: '3',
28
- },
29
- {
30
- type: 'custom',
31
- id: 'tag-lines',
32
- showcase_id: '2',
33
- },
34
- {
35
- type: 'custom',
36
- id: 'about-us',
37
- showcase_id: '2',
38
- },
39
- {
40
- type: 'default',
41
- id: 'footer',
42
- },
43
- ],
44
- };
@@ -1,198 +0,0 @@
1
- export default {
2
- metadata: {
3
- name: 'Example Template :: Standard Preset',
4
- description: 'Standard Preset for the Example template',
5
- preview_url: 'https://template_preview.company.site',
6
- cover_image: {
7
- set: {
8
- ORIGINAL: {
9
- url: 'template_cover_image.png',
10
- },
11
- },
12
- },
13
- },
14
- sections: [
15
- {
16
- type: 'default',
17
- id: 'header',
18
- },
19
- {
20
- type: 'default',
21
- id: 'slider',
22
- showcase_id: '001',
23
- },
24
- {
25
- type: 'custom',
26
- id: 'example-section',
27
- showcase_id: '1',
28
- },
29
- {
30
- type: 'custom',
31
- id: 'example-section',
32
- showcase_overrides: {
33
- content: {
34
- section_title: {
35
- type: 'INPUTBOX',
36
- text: '$label.template_standard_showcase_1.section_title.text',
37
- },
38
-
39
- images: {
40
- type: 'DECK',
41
- cards: [
42
- {
43
- settings: {
44
- image_text: {
45
- type: 'TEXTAREA',
46
- text: '$label.showcase_2.image_text_1.text',
47
- },
48
- image_content: {
49
- type: 'IMAGE',
50
- imageData: {
51
- set: {
52
- MOBILE_WEBP_LOW_RES: {
53
- url: 'new_tshirts_collection_mobile_low.jpeg',
54
- },
55
- MOBILE_WEBP_HI_RES: {
56
- url: 'new_tshirts_collection_mobile_high.jpeg',
57
- },
58
- WEBP_LOW_RES: {
59
- url: 'new_tshirts_collection_pc_low.jpeg',
60
- },
61
- WEBP_HI_2X_RES: {
62
- url: 'new_tshirts_collection_pc_high.jpeg',
63
- },
64
- },
65
- borderInfo: {},
66
- },
67
- },
68
- image_link: {
69
- type: 'INPUTBOX',
70
- text: '$label.showcase_2.image_link_1.text',
71
- },
72
- },
73
- },
74
- {
75
- settings: {
76
- image_text: {
77
- type: 'TEXTAREA',
78
- text: '$label.showcase_2.image_text_2.text',
79
- },
80
- image_content: {
81
- type: 'IMAGE',
82
- imageData: {
83
- set: {
84
- MOBILE_WEBP_LOW_RES: {
85
- url: 'autumn_looks_mobile_low.jpeg',
86
- },
87
- MOBILE_WEBP_HI_RES: {
88
- url: 'autumn_looks_mobile_high.jpeg',
89
- },
90
- WEBP_LOW_RES: {
91
- url: 'autumn_looks_pc_low.jpeg',
92
- },
93
- WEBP_HI_2X_RES: {
94
- url: 'autumn_looks_pc_high.jpeg',
95
- },
96
- },
97
- borderInfo: {},
98
- },
99
- },
100
- },
101
- },
102
-
103
- {
104
- settings: {
105
- image_text: {
106
- type: 'TEXTAREA',
107
- text: '$label.showcase_2.image_text_3.text',
108
- },
109
- image_content: {
110
- type: 'IMAGE',
111
- imageData: {
112
- set: {
113
- MOBILE_WEBP_LOW_RES: {
114
- url: 'bianka_wardrobe_mobile_low.jpeg',
115
- },
116
- MOBILE_WEBP_HI_RES: {
117
- url: 'bianka_wardrobe_mobile_high.jpeg',
118
- },
119
- WEBP_LOW_RES: {
120
- url: 'bianka_wardrobe_pc_low.jpeg',
121
- },
122
- WEBP_HI_2X_RES: {
123
- url: 'bianka_wardrobe_pc_high.jpeg',
124
- },
125
- },
126
- borderInfo: {},
127
- },
128
- },
129
- },
130
- },
131
-
132
- {
133
- settings: {
134
- image_text: {
135
- type: 'TEXTAREA',
136
- text: '$label.showcase_2.image_text_4.text',
137
- },
138
- image_content: {
139
- type: 'IMAGE',
140
- imageData: {
141
- set: {
142
- MOBILE_WEBP_LOW_RES: {
143
- url: 'story_of_jane_mobile_low.jpeg',
144
- },
145
- MOBILE_WEBP_HI_RES: {
146
- url: 'story_of_jane_mobile_high.jpeg',
147
- },
148
- WEBP_LOW_RES: {
149
- url: 'story_of_jane_pc_low.jpeg',
150
- },
151
- WEBP_HI_2X_RES: {
152
- url: 'story_of_jane_pc_high.jpeg',
153
- },
154
- },
155
- borderInfo: {},
156
- },
157
- },
158
- },
159
- },
160
- ],
161
- },
162
- },
163
- design: {
164
- section_title: {
165
- type: 'TEXT',
166
- font: 'global.fontFamily.body',
167
- size: 42,
168
- bold: true,
169
- italic: true,
170
- color: '#222',
171
- },
172
- image_text: {
173
- type: 'TEXT',
174
- size: 22,
175
- bold: false,
176
- italic: true,
177
- },
178
- background: {
179
- type: 'BACKGROUND',
180
- style: 'COLOR',
181
- color: 'global.color.background',
182
- },
183
- image_content: {
184
- type: 'IMAGE',
185
- overlay: 'GRADIENT',
186
- color: ['#FFFFFF', '#CCCCCC'],
187
- },
188
- },
189
- layoutId: 'Caption_Under_Image',
190
- blockName: '$label.showcase_2.blockName',
191
- },
192
- },
193
- {
194
- type: 'default',
195
- id: 'footer',
196
- },
197
- ],
198
- };