@speedkit/cli 2.51.0 → 2.53.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.
- package/CHANGELOG.md +15 -0
- package/README.md +1 -1
- package/dist/services/customer-config/templates/config_dynamicBlocks.es6.hbs +29 -26
- package/dist/services/document-handler-runtime/document-handler-server.d.ts +1 -0
- package/dist/services/document-handler-runtime/document-handler-server.js +14 -7
- package/oclif.manifest.json +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,18 @@
|
|
|
1
|
+
# [2.53.0](https://gitlab.orestes.info/baqend/speed-kit-cli/compare/v2.52.0...v2.53.0) (2024-08-22)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Features
|
|
5
|
+
|
|
6
|
+
* **customer-config:** restore shopify-specific block config ([0e52434](https://gitlab.orestes.info/baqend/speed-kit-cli/commit/0e52434ad7b6dde866bf5b006d7b138c124d8282))
|
|
7
|
+
* **customer-config:** set body as default main block ([d600453](https://gitlab.orestes.info/baqend/speed-kit-cli/commit/d6004538cdd0daf86d7776cd95dd91a714b7635a))
|
|
8
|
+
|
|
9
|
+
# [2.52.0](https://gitlab.orestes.info/baqend/speed-kit-cli/compare/v2.51.0...v2.52.0) (2024-08-09)
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
### Features
|
|
13
|
+
|
|
14
|
+
* **onboarding:** disable deploymentDetection in localMode ([b6faa9f](https://gitlab.orestes.info/baqend/speed-kit-cli/commit/b6faa9f0bbe0a44784d929689b1fec01a25dcde2))
|
|
15
|
+
|
|
1
16
|
# [2.51.0](https://gitlab.orestes.info/baqend/speed-kit-cli/compare/v2.50.0...v2.51.0) (2024-08-09)
|
|
2
17
|
|
|
3
18
|
|
package/README.md
CHANGED
|
@@ -61,48 +61,51 @@
|
|
|
61
61
|
{{/unless}}
|
|
62
62
|
{{/if}}
|
|
63
63
|
|
|
64
|
-
{{#if isShopify}}
|
|
65
|
-
// Shopify specific:
|
|
66
|
-
{
|
|
67
|
-
selector: "#shopify-section-announcement-bar",
|
|
68
|
-
detectChanges: [{
|
|
69
|
-
find: ".announcement-bar--wrapper",
|
|
70
|
-
compare: ["text"],
|
|
71
|
-
}],
|
|
72
|
-
},
|
|
73
|
-
// cover all the other high-level Shopify sections:
|
|
74
|
-
{
|
|
75
|
-
selector: "body > .shopify-section[id]",
|
|
76
|
-
idAttribute: "id",
|
|
77
|
-
},
|
|
78
|
-
|
|
79
|
-
{{/if}}
|
|
80
64
|
{
|
|
81
|
-
selector: '
|
|
65
|
+
selector: 'body',
|
|
82
66
|
detectChanges: [
|
|
83
|
-
|
|
84
|
-
// home teaser:
|
|
67
|
+
// Main Headline:
|
|
85
68
|
{
|
|
86
|
-
find: '
|
|
87
|
-
compare: ['
|
|
69
|
+
find: 'h1',
|
|
70
|
+
compare: ['text'],
|
|
88
71
|
},
|
|
72
|
+
|
|
73
|
+
// Home:
|
|
89
74
|
{
|
|
90
|
-
find: '.teaser source',
|
|
75
|
+
find: '.stage-teaser source',
|
|
91
76
|
compare: ['srcset'],
|
|
92
77
|
},
|
|
93
78
|
|
|
94
|
-
//
|
|
79
|
+
// PLP:
|
|
95
80
|
{
|
|
96
|
-
find: '.product-grid .product
|
|
81
|
+
find: '.product-grid .product img',
|
|
97
82
|
limit: 9, // only compare the first 9 products
|
|
98
|
-
compare: ['
|
|
83
|
+
compare: ['src'],
|
|
99
84
|
},
|
|
100
85
|
// ...
|
|
101
86
|
|
|
102
|
-
//
|
|
87
|
+
// PDP:
|
|
103
88
|
// ...
|
|
104
89
|
],
|
|
105
90
|
},
|
|
91
|
+
{{#if isShopify}}
|
|
92
|
+
|
|
93
|
+
// Shopify specific:
|
|
94
|
+
{
|
|
95
|
+
selector: "#shopify-section-announcement-bar",
|
|
96
|
+
merge: false, // TODO: remove if body is not the main block
|
|
97
|
+
detectChanges: [{
|
|
98
|
+
find: ".announcement-bar--wrapper",
|
|
99
|
+
compare: ["text"],
|
|
100
|
+
}],
|
|
101
|
+
},
|
|
102
|
+
// Cover all the other high-level Shopify sections:
|
|
103
|
+
// TODO: activate if body is not the main block
|
|
104
|
+
// {
|
|
105
|
+
// selector: "body > .shopify-section[id]",
|
|
106
|
+
// idAttribute: "id",
|
|
107
|
+
// },
|
|
108
|
+
{{/if}}
|
|
106
109
|
{{#if isPlentymarkets}}
|
|
107
110
|
|
|
108
111
|
// Plentymarkets specific:
|
|
@@ -18,6 +18,7 @@ export declare class DocumentHandlerServer {
|
|
|
18
18
|
private getTransformFunctionWrapper;
|
|
19
19
|
buildDocumentHandler(): Promise<void>;
|
|
20
20
|
private createDocumentHandlerConfigFile;
|
|
21
|
+
private deactivateReleaseAndDeploymentDetection;
|
|
21
22
|
private getDocumentHandler;
|
|
22
23
|
private getDynamicFetcher;
|
|
23
24
|
private getDynamicFetcherConfig;
|
|
@@ -90,7 +90,14 @@ class DocumentHandlerServer {
|
|
|
90
90
|
this.cli.writeSuccess("rebuild documentHandler");
|
|
91
91
|
}
|
|
92
92
|
async createDocumentHandlerConfigFile() {
|
|
93
|
-
|
|
93
|
+
const config = this.getDocumentHandlerConfig().replace("export const post", "const post");
|
|
94
|
+
return this.deactivateReleaseAndDeploymentDetection(config);
|
|
95
|
+
}
|
|
96
|
+
deactivateReleaseAndDeploymentDetection(documentHandlerConfig) {
|
|
97
|
+
return documentHandlerConfig.replace("const documentHandler =", (selected) => {
|
|
98
|
+
return (`config["executeDeploymentDetection"] = false;config["executeReleaseDetection"] = false;\n` +
|
|
99
|
+
selected);
|
|
100
|
+
});
|
|
94
101
|
}
|
|
95
102
|
async getDocumentHandler() {
|
|
96
103
|
return this.files
|
|
@@ -131,19 +138,19 @@ class DocumentHandlerServer {
|
|
|
131
138
|
}
|
|
132
139
|
async createDataBaseMock() {
|
|
133
140
|
const vmConsole = {
|
|
134
|
-
log: (
|
|
141
|
+
log: (...logArguments) => {
|
|
135
142
|
this.verboseLevel
|
|
136
|
-
? this.cli.write(`[documentHandler.dbLog]: ${JSON.stringify(
|
|
143
|
+
? this.cli.write(`[documentHandler.dbLog]: ${JSON.stringify(logArguments)}`)
|
|
137
144
|
: "";
|
|
138
145
|
},
|
|
139
|
-
info: (
|
|
146
|
+
info: (...logArguments) => {
|
|
140
147
|
this.verboseLevel
|
|
141
|
-
? this.cli.writeWarning(`[documentHandler.dbLog]: ${JSON.stringify(
|
|
148
|
+
? this.cli.writeWarning(`[documentHandler.dbLog]: ${JSON.stringify(logArguments)}`)
|
|
142
149
|
: "";
|
|
143
150
|
},
|
|
144
|
-
error: (
|
|
151
|
+
error: (...logArguments) => {
|
|
145
152
|
this.verboseLevel
|
|
146
|
-
? this.cli.writeError(`[documentHandler.dbLog]: ${JSON.stringify(
|
|
153
|
+
? this.cli.writeError(`[documentHandler.dbLog]: ${JSON.stringify(logArguments)}`)
|
|
147
154
|
: "";
|
|
148
155
|
},
|
|
149
156
|
};
|
package/oclif.manifest.json
CHANGED