cc-core-cli 1.0.12 → 1.0.14

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cc-core-cli",
3
- "version": "1.0.12",
3
+ "version": "1.0.14",
4
4
  "description": "Command Line Interface tool for generating project templates for the (Your Platform's Name) platform.",
5
5
  "main": "bin/index.js",
6
6
  "scripts": {
@@ -43,16 +43,6 @@ module.exports = withPlugins([
43
43
  [withLess, {
44
44
  lessLoaderOptions: {}
45
45
  }],
46
- [
47
- withPWA, {
48
- pwa: {
49
- dest: 'public',
50
- register: true,
51
- skipWaiting: true,
52
- disable: process.env.NODE_ENV === 'development'
53
- }
54
- }
55
- ],
56
46
  withAntd,
57
47
  withAntdTheme,
58
48
  ], {
@@ -14,7 +14,7 @@
14
14
  "author": "",
15
15
  "license": "ISC",
16
16
  "dependencies": {
17
- "@shopstack/cc-admin-lib": "^2.5.1"
17
+ "@shopstack/cc-admin-lib": "^2.5.24"
18
18
  },
19
19
  "devDependencies": {
20
20
  "identity-obj-proxy": "^3.0.0",
@@ -0,0 +1,21 @@
1
+ self.addEventListener('activate', event => {
2
+ event.waitUntil(self.clients.claim());
3
+ });
4
+
5
+ self.addEventListener('fetch', event => {
6
+ const privateHost = new URL(self.serviceWorker.scriptURL).searchParams.get('host')
7
+ if (!event.request.url.startsWith(privateHost)) return
8
+
9
+ event.respondWith(modifyAPIResponse(event.request));
10
+ })
11
+
12
+ async function modifyAPIResponse(request) {
13
+ const imageLink = request.url
14
+ request = new Request(`/api/media?url=${imageLink}`, {
15
+ method: 'GET',
16
+ headers: request.headers,
17
+ mode: 'same-origin',
18
+ credentials: 'include',
19
+ });
20
+ return await fetch(request)
21
+ }
@@ -38,7 +38,7 @@
38
38
  "@nestjs/platform-fastify": "^9.3.9",
39
39
  "@nestjs/schedule": "^2.2.0",
40
40
  "@nestjs/swagger": "^6.2.1",
41
- "@shopstack/cc-core-lib": "^2.5.15",
41
+ "@shopstack/cc-core-lib": "^2.5.18",
42
42
  "@types/chroma-js": "^2.4.0",
43
43
  "@types/numeral": "^2.0.2",
44
44
  "amazon-cognito-identity-js": "^4.5.0",
@@ -35,7 +35,8 @@
35
35
  "jpg",
36
36
  "svg"
37
37
  ],
38
- "path_file": "system/global_setting/profile"
38
+ "path_file": "system/global_setting/profile",
39
+ "is_public": true
39
40
  }
40
41
  ],
41
42
  [
@@ -159,7 +160,8 @@
159
160
  "svg"
160
161
  ],
161
162
  "path_file": "system/general_setting/logo",
162
- "max_file_size": 10
163
+ "max_file_size": 10,
164
+ "is_public": true
163
165
  }
164
166
  ],
165
167
  [
@@ -179,7 +181,8 @@
179
181
  "svg"
180
182
  ],
181
183
  "path_file": "system/general_setting/bg",
182
- "max_file_size": 10
184
+ "max_file_size": 10,
185
+ "is_public": true
183
186
  }
184
187
  ]
185
188
  ]