@lightspeed/crane 1.2.1 → 1.2.2
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 +19 -0
- package/README.md +11 -0
- package/UPGRADE.md +30 -0
- package/dist/app.d.mts +29 -1
- package/dist/app.d.ts +29 -1
- package/dist/cli.mjs +8 -8
- package/package.json +7 -8
- package/template/eslint.config.cjs +1 -0
- package/template/footers/example-footer/component/MadeWith.vue +1 -1
- package/template/package.json +3 -5
- package/template/page-templates/assets/template_cover_image.png +0 -0
- package/template/page-templates/example-template/configuration.ts +22 -0
- package/template/page-templates/example-template/pages/catalog.ts +8 -0
- package/template/page-templates/example-template/pages/category.ts +8 -0
- package/template/page-templates/example-template/pages/home.ts +178 -0
- package/template/page-templates/example-template/pages/product.ts +8 -0
- package/template/reference/sections/about-us/settings/content.ts +4 -7
- package/template/reference/sections/about-us/showcases/1.ts +0 -3
- package/template/reference/sections/about-us/showcases/2.ts +0 -3
- package/template/reference/sections/intro-slider/assets/category_4.jpg +0 -0
- package/template/reference/sections/intro-slider/assets/category_4@2x.jpg +0 -0
- package/template/reference/sections/intro-slider/settings/content.ts +1 -0
- package/template/reference/sections/intro-slider/showcases/1.ts +0 -18
- package/template/reference/sections/intro-slider/showcases/2.ts +0 -18
- package/template/reference/sections/tag-lines/settings/content.ts +1 -0
- package/template/reference/sections/tag-lines/showcases/1.ts +0 -12
- package/template/reference/sections/tag-lines/showcases/2.ts +0 -12
- package/template/sections/example-section/settings/content.ts +0 -3
- package/template/sections/example-section/showcases/1.ts +0 -12
- package/template/sections/example-section/showcases/2.ts +0 -12
- package/template/sections/example-section/showcases/3.ts +0 -12
- package/template/templates/template.ts +0 -12
- package/template/.eslintrc.cjs +0 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,24 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 1.2.2 - 2025-05-12
|
|
4
|
+
|
|
5
|
+
_If you are upgrading: please see [UPGRADE.md](UPGRADE.md)._
|
|
6
|
+
|
|
7
|
+
### Added
|
|
8
|
+
|
|
9
|
+
- **Storefront (experimental):** add multipage support for Custom Templates.
|
|
10
|
+
- Add image validation for custom section and template configuration files during the 'build' command.
|
|
11
|
+
- Provide icon URL for 'Made With' component through the external content.
|
|
12
|
+
|
|
13
|
+
### Changed
|
|
14
|
+
|
|
15
|
+
- **Breaking:** Change minimal supported Node.js version to 22 LTS.
|
|
16
|
+
- **Breaking:** Upgrade ESLint dependency to version 9.
|
|
17
|
+
|
|
18
|
+
### Removed
|
|
19
|
+
|
|
20
|
+
- **Breaking:** Remove unused image resolutions from the templating files across all sections.
|
|
21
|
+
|
|
3
22
|
## 1.2.1 - 2025-04-17
|
|
4
23
|
|
|
5
24
|
### Added
|
package/README.md
CHANGED
|
@@ -22,6 +22,10 @@ permissions granted, as well as an optional test site in order to verify the cha
|
|
|
22
22
|
|
|
23
23
|
```For both the test site and the permission, please contact your Partner Manager!```
|
|
24
24
|
|
|
25
|
+
### Recommended Node.js Version
|
|
26
|
+
|
|
27
|
+
For the best compatibility and performance, it is recommended to use **Node.js 22.x**
|
|
28
|
+
|
|
25
29
|
### Installation
|
|
26
30
|
|
|
27
31
|
The following commands need to be performed to install the required dependencies and Crane utility, along with our linter:
|
|
@@ -111,3 +115,10 @@ npm install
|
|
|
111
115
|
|
|
112
116
|
3. HTTP 403 during deployment:
|
|
113
117
|
Insufficient permissions, please contact your Partner Manager regarding the necessary permissions.
|
|
118
|
+
|
|
119
|
+
### More information
|
|
120
|
+
|
|
121
|
+
For more information regarding the notable changes for each versioned release and the upgrade guide, please refer to the following files:
|
|
122
|
+
|
|
123
|
+
- [CHANGELOG](CHANGELOG.md)
|
|
124
|
+
- [UPGRADE](UPGRADE.md)
|
package/UPGRADE.md
ADDED
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
# Upgrades
|
|
2
|
+
|
|
3
|
+
## 1.2.1 to 1.2.2
|
|
4
|
+
|
|
5
|
+
### Node.js Version Upgrade
|
|
6
|
+
|
|
7
|
+
The required Node.js version has been updated from **20 LTS** to **22 LTS**.
|
|
8
|
+
Ensure that your environment is running Node.js 22 LTS to maintain compatibility with the latest dependencies.
|
|
9
|
+
|
|
10
|
+
### Restriction on Image Resolutions
|
|
11
|
+
|
|
12
|
+
As of this update, a new limitation on the types of image resolutions that can be uploaded has been added.
|
|
13
|
+
The build will fail if any resolutions other than the ones specified below are used:
|
|
14
|
+
|
|
15
|
+
- **MOBILE_WEBP_HI_RES**: 1000px x 2000px
|
|
16
|
+
- **WEBP_LOW_RES**: 200px x 200px
|
|
17
|
+
- **WEBP_HI_2X_RES**: 2000px x 2000px
|
|
18
|
+
- **MOBILE_WEBP_LOW_RES**: 100px x 200px
|
|
19
|
+
- **ORIGINAL**: The original version of the image, not resized.
|
|
20
|
+
|
|
21
|
+
Ensure that all images conform to these resolutions to prevent build failures.
|
|
22
|
+
|
|
23
|
+
### ESLint upgrade from 8 to 9
|
|
24
|
+
|
|
25
|
+
1. Create a file named ```eslint.config.cjs``` in custom app root directory.
|
|
26
|
+
2. Add the following content to the file:
|
|
27
|
+
```js
|
|
28
|
+
module.exports = require('@lightspeed/eslint-config-crane');
|
|
29
|
+
```
|
|
30
|
+
3. Remove existing ```.eslintrc.cjs``` file
|
package/dist/app.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as vue from 'vue';
|
|
2
|
-
import {
|
|
2
|
+
import type { Ref, App, Component } from 'vue';
|
|
3
3
|
|
|
4
4
|
interface AppBaseContext {
|
|
5
5
|
readonly appName: string;
|
|
@@ -56,6 +56,8 @@ interface GlobalDesign {
|
|
|
56
56
|
customCss?: string;
|
|
57
57
|
}
|
|
58
58
|
|
|
59
|
+
|
|
60
|
+
|
|
59
61
|
interface VueBaseProps<CONTENT, DESIGN> {
|
|
60
62
|
init: (app: App<Element>, contextValue: AppBaseContext, contentValue: CONTENT, designValue: DESIGN, defaultsValue: Record<string, unknown>, externalContent: ExternalContentData, globalDesignValue: GlobalDesign) => void;
|
|
61
63
|
update: (app: App<Element>, contentValue: CONTENT, designValue: DESIGN, defaultsValue: Record<string, unknown>, externalContent: ExternalContentData, globalDesignValue: GlobalDesign) => void;
|
|
@@ -239,6 +241,15 @@ declare function useLogoElementContent<CONTENT>(): {
|
|
|
239
241
|
};
|
|
240
242
|
};
|
|
241
243
|
|
|
244
|
+
|
|
245
|
+
|
|
246
|
+
|
|
247
|
+
|
|
248
|
+
|
|
249
|
+
|
|
250
|
+
|
|
251
|
+
|
|
252
|
+
|
|
242
253
|
declare function useTextElementDesign<DESIGN>(elementName: keyof DESIGN): {
|
|
243
254
|
font: string | undefined;
|
|
244
255
|
size: number | GlobalTextSizeString | undefined;
|
|
@@ -290,6 +301,10 @@ declare function useLayoutElementDesign(): {
|
|
|
290
301
|
|
|
291
302
|
declare function useLogoElementDesign<DESIGN>(): vue.ComputedRef<LogoDesignData>;
|
|
292
303
|
|
|
304
|
+
|
|
305
|
+
|
|
306
|
+
|
|
307
|
+
|
|
293
308
|
interface VueServerAppExtensions {
|
|
294
309
|
init?: (app: App<Element>) => void;
|
|
295
310
|
render?: <C, D>(app: App<Element>, context: AppBaseContext, data: AppBaseData<C, D>) => void;
|
|
@@ -304,6 +319,10 @@ declare function createVueServerApp<C, D>(appComponent: Component, extensions?:
|
|
|
304
319
|
};
|
|
305
320
|
};
|
|
306
321
|
|
|
322
|
+
|
|
323
|
+
|
|
324
|
+
|
|
325
|
+
|
|
307
326
|
interface VueClientAppExtensions {
|
|
308
327
|
init?: (app: App<Element>) => void;
|
|
309
328
|
mount?: <C, D, S extends AppBaseState<C, D>>(app: App<Element>, rootContainer: string, state: S) => void;
|
|
@@ -383,5 +402,14 @@ interface InstantsiteJSAPI {
|
|
|
383
402
|
|
|
384
403
|
declare function useInstantsiteJsApi(): InstantsiteJSAPI | undefined;
|
|
385
404
|
|
|
405
|
+
|
|
406
|
+
|
|
407
|
+
|
|
408
|
+
|
|
409
|
+
|
|
410
|
+
|
|
411
|
+
|
|
412
|
+
|
|
413
|
+
|
|
386
414
|
export { EditorTypes, createVueClientApp, createVueServerApp, useBackgroundElementDesign, useButtonElementContent, useButtonElementDesign, useDeckElementContent, useImageElementContent, useImageElementDesign, useInputboxElementContent, useInstantsiteJsApi, useLayoutElementDesign, useLogoElementContent, useLogoElementDesign, useMenuElementContent, useNavigationMenuElementContent, useSelectboxElementContent, useSelectboxElementDesign, useTextElementDesign, useTextareaElementContent, useTextareaElementDesign, useToggleElementContent, useToggleElementDesign, useVueBaseProps };
|
|
387
415
|
export type { ButtonContent, Card, Deck, ImageContent, InputBoxContent, SelectBoxContent, TextAreaContent, ToggleContent };
|
package/dist/app.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as vue from 'vue';
|
|
2
|
-
import {
|
|
2
|
+
import type { Ref, App, Component } from 'vue';
|
|
3
3
|
|
|
4
4
|
interface AppBaseContext {
|
|
5
5
|
readonly appName: string;
|
|
@@ -56,6 +56,8 @@ interface GlobalDesign {
|
|
|
56
56
|
customCss?: string;
|
|
57
57
|
}
|
|
58
58
|
|
|
59
|
+
|
|
60
|
+
|
|
59
61
|
interface VueBaseProps<CONTENT, DESIGN> {
|
|
60
62
|
init: (app: App<Element>, contextValue: AppBaseContext, contentValue: CONTENT, designValue: DESIGN, defaultsValue: Record<string, unknown>, externalContent: ExternalContentData, globalDesignValue: GlobalDesign) => void;
|
|
61
63
|
update: (app: App<Element>, contentValue: CONTENT, designValue: DESIGN, defaultsValue: Record<string, unknown>, externalContent: ExternalContentData, globalDesignValue: GlobalDesign) => void;
|
|
@@ -239,6 +241,15 @@ declare function useLogoElementContent<CONTENT>(): {
|
|
|
239
241
|
};
|
|
240
242
|
};
|
|
241
243
|
|
|
244
|
+
|
|
245
|
+
|
|
246
|
+
|
|
247
|
+
|
|
248
|
+
|
|
249
|
+
|
|
250
|
+
|
|
251
|
+
|
|
252
|
+
|
|
242
253
|
declare function useTextElementDesign<DESIGN>(elementName: keyof DESIGN): {
|
|
243
254
|
font: string | undefined;
|
|
244
255
|
size: number | GlobalTextSizeString | undefined;
|
|
@@ -290,6 +301,10 @@ declare function useLayoutElementDesign(): {
|
|
|
290
301
|
|
|
291
302
|
declare function useLogoElementDesign<DESIGN>(): vue.ComputedRef<LogoDesignData>;
|
|
292
303
|
|
|
304
|
+
|
|
305
|
+
|
|
306
|
+
|
|
307
|
+
|
|
293
308
|
interface VueServerAppExtensions {
|
|
294
309
|
init?: (app: App<Element>) => void;
|
|
295
310
|
render?: <C, D>(app: App<Element>, context: AppBaseContext, data: AppBaseData<C, D>) => void;
|
|
@@ -304,6 +319,10 @@ declare function createVueServerApp<C, D>(appComponent: Component, extensions?:
|
|
|
304
319
|
};
|
|
305
320
|
};
|
|
306
321
|
|
|
322
|
+
|
|
323
|
+
|
|
324
|
+
|
|
325
|
+
|
|
307
326
|
interface VueClientAppExtensions {
|
|
308
327
|
init?: (app: App<Element>) => void;
|
|
309
328
|
mount?: <C, D, S extends AppBaseState<C, D>>(app: App<Element>, rootContainer: string, state: S) => void;
|
|
@@ -383,5 +402,14 @@ interface InstantsiteJSAPI {
|
|
|
383
402
|
|
|
384
403
|
declare function useInstantsiteJsApi(): InstantsiteJSAPI | undefined;
|
|
385
404
|
|
|
405
|
+
|
|
406
|
+
|
|
407
|
+
|
|
408
|
+
|
|
409
|
+
|
|
410
|
+
|
|
411
|
+
|
|
412
|
+
|
|
413
|
+
|
|
386
414
|
export { EditorTypes, createVueClientApp, createVueServerApp, useBackgroundElementDesign, useButtonElementContent, useButtonElementDesign, useDeckElementContent, useImageElementContent, useImageElementDesign, useInputboxElementContent, useInstantsiteJsApi, useLayoutElementDesign, useLogoElementContent, useLogoElementDesign, useMenuElementContent, useNavigationMenuElementContent, useSelectboxElementContent, useSelectboxElementDesign, useTextElementDesign, useTextareaElementContent, useTextareaElementDesign, useToggleElementContent, useToggleElementDesign, useVueBaseProps };
|
|
387
415
|
export type { ButtonContent, Card, Deck, ImageContent, InputBoxContent, SelectBoxContent, TextAreaContent, ToggleContent };
|