@strapi/plugin-cloud 4.26.0 → 4.26.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.
@@ -3,13 +3,20 @@ const helperPlugin = require("@strapi/helper-plugin");
3
3
  const react = require("react");
4
4
  const jsxRuntime = require("react/jsx-runtime");
5
5
  const icons = require("@strapi/icons");
6
- const __variableDynamicImportRuntimeHelper = (glob, path) => {
6
+ const __variableDynamicImportRuntimeHelper = (glob, path, segs) => {
7
7
  const v = glob[path];
8
8
  if (v) {
9
9
  return typeof v === "function" ? v() : Promise.resolve(v);
10
10
  }
11
11
  return new Promise((_, reject) => {
12
- (typeof queueMicrotask === "function" ? queueMicrotask : setTimeout)(reject.bind(null, new Error("Unknown variable dynamic import: " + path)));
12
+ (typeof queueMicrotask === "function" ? queueMicrotask : setTimeout)(
13
+ reject.bind(
14
+ null,
15
+ new Error(
16
+ "Unknown variable dynamic import: " + path + (path.split("/").length !== segs ? ". Note that variables only represent file names one level deep." : "")
17
+ )
18
+ )
19
+ );
13
20
  });
14
21
  };
15
22
  const pluginId = "cloud";
@@ -34,7 +41,7 @@ const index = {
34
41
  defaultMessage: name
35
42
  },
36
43
  Component: async () => {
37
- const { App } = await Promise.resolve().then(() => require("./App-Gh4oSOHw.js"));
44
+ const { App } = await Promise.resolve().then(() => require("./App-D-wfuQOx.js"));
38
45
  return App;
39
46
  }
40
47
  });
@@ -51,7 +58,7 @@ const index = {
51
58
  const { locales } = app;
52
59
  const importedTrads = await Promise.all(
53
60
  locales.map((locale) => {
54
- return __variableDynamicImportRuntimeHelper(/* @__PURE__ */ Object.assign({ "./translations/en.json": () => Promise.resolve().then(() => require("./en-IGOLzfH6.js")), "./translations/fr.json": () => Promise.resolve().then(() => require("./fr-o9I0MEIB.js")) }), `./translations/${locale}.json`).then(({ default: data }) => {
61
+ return __variableDynamicImportRuntimeHelper(/* @__PURE__ */ Object.assign({ "./translations/en.json": () => Promise.resolve().then(() => require("./en-j5SB1oBn.js")), "./translations/fr.json": () => Promise.resolve().then(() => require("./fr-Y8WZfiox.js")) }), `./translations/${locale}.json`, 3).then(({ default: data }) => {
55
62
  return {
56
63
  data: helperPlugin.prefixPluginTranslations(data, pluginId),
57
64
  locale
@@ -69,4 +76,4 @@ const index = {
69
76
  };
70
77
  exports.index = index;
71
78
  exports.pluginId = pluginId;
72
- //# sourceMappingURL=index-mjWlxKqq.js.map
79
+ //# sourceMappingURL=index-DiqkM4F0.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index-mjWlxKqq.js","sources":["../../admin/src/pluginId.ts","../../admin/src/components/Initializer.tsx","../../admin/src/components/PluginIcon.tsx","../../admin/src/index.ts"],"sourcesContent":["export const pluginId = 'cloud';\n","/**\n *\n * Initializer\n *\n */\n\nimport { useEffect, useRef } from 'react';\n\nimport { pluginId } from '../pluginId';\n\ntype InitializerProps = {\n setPlugin: (id: string) => void;\n};\n\nconst Initializer = ({ setPlugin }: InitializerProps) => {\n const ref = useRef(setPlugin);\n\n useEffect(() => {\n ref.current(pluginId);\n }, []);\n\n return null;\n};\n\nexport { Initializer };\n","/**\n *\n * PluginIcon\n *\n */\n\nimport { Cloud } from '@strapi/icons';\n\nconst PluginIcon = () => <Cloud />;\n\nexport { PluginIcon };\n","/* eslint-disable check-file/filename-naming-convention */\nimport { prefixPluginTranslations } from '@strapi/helper-plugin';\n\nimport { Initializer } from './components/Initializer';\nimport { PluginIcon } from './components/PluginIcon';\nimport { pluginId } from './pluginId';\n\nconst name = 'Deploy';\n\n// eslint-disable-next-line import/no-default-export\nexport default {\n register(app: any) {\n const { backendURL } = window.strapi;\n\n // Only add the plugin menu link and registering it if the project is on development (localhost).\n if (backendURL?.includes('localhost')) {\n app.addMenuLink({\n to: `/plugins/${pluginId}`,\n icon: PluginIcon,\n intlLabel: {\n id: `${pluginId}.plugin.name`,\n defaultMessage: name,\n },\n Component: async () => {\n const { App } = await import('./pages/App');\n\n return App;\n },\n });\n const plugin = {\n id: pluginId,\n initializer: Initializer,\n isReady: false,\n name,\n };\n\n app.registerPlugin(plugin);\n }\n },\n\n async registerTrads(app: any) {\n const { locales } = app;\n\n const importedTrads = await Promise.all(\n (locales as any[]).map((locale) => {\n return import(`./translations/${locale}.json`)\n .then(({ default: data }) => {\n return {\n data: prefixPluginTranslations(data, pluginId),\n locale,\n };\n })\n .catch(() => {\n return {\n data: {},\n locale,\n };\n });\n })\n );\n\n return Promise.resolve(importedTrads);\n },\n};\n"],"names":["useRef","useEffect","jsx","Cloud","prefixPluginTranslations"],"mappings":";;;;;;;;;;;;;;AAAO,MAAM,WAAW;ACcxB,MAAM,cAAc,CAAC,EAAE,gBAAkC;AACjD,QAAA,MAAMA,aAAO,SAAS;AAE5BC,QAAAA,UAAU,MAAM;AACd,QAAI,QAAQ,QAAQ;AAAA,EACtB,GAAG,CAAE,CAAA;AAEE,SAAA;AACT;ACdA,MAAM,aAAa,MAAMC,2BAAAA,IAACC,MAAM,OAAA,EAAA;ACDhC,MAAM,OAAO;AAGb,MAAe,QAAA;AAAA,EACb,SAAS,KAAU;AACX,UAAA,EAAE,WAAW,IAAI,OAAO;AAG1B,QAAA,YAAY,SAAS,WAAW,GAAG;AACrC,UAAI,YAAY;AAAA,QACd,IAAI,YAAY,QAAQ;AAAA,QACxB,MAAM;AAAA,QACN,WAAW;AAAA,UACT,IAAI,GAAG,QAAQ;AAAA,UACf,gBAAgB;AAAA,QAClB;AAAA,QACA,WAAW,YAAY;AACrB,gBAAM,EAAE,IAAA,IAAQ,MAAM,QAAA,QAAA,EAAA,KAAA,MAAA,QAAO,mBAAa,CAAA;AAEnC,iBAAA;AAAA,QACT;AAAA,MAAA,CACD;AACD,YAAM,SAAS;AAAA,QACb,IAAI;AAAA,QACJ,aAAa;AAAA,QACb,SAAS;AAAA,QACT;AAAA,MAAA;AAGF,UAAI,eAAe,MAAM;AAAA,IAC3B;AAAA,EACF;AAAA,EAEA,MAAM,cAAc,KAAU;AACtB,UAAA,EAAE,QAAY,IAAA;AAEd,UAAA,gBAAgB,MAAM,QAAQ;AAAA,MACjC,QAAkB,IAAI,CAAC,WAAW;AAC1B,eAAA,qCAA+B,uBAAA,OAAA,EAAA,0BAAA,MAAA,qCAAA,kBAAA,CAAA,GAAA,0BAAA,MAAA,QAAA,QAAA,EAAA,KAAA,MAAA,QAAA,kBAAA,CAAA,EAAA,CAAA,GAAA,kBAAA,MAAA,OAAA,EACnC,KAAK,CAAC,EAAE,SAAS,WAAW;AACpB,iBAAA;AAAA,YACL,MAAMC,aAAAA,yBAAyB,MAAM,QAAQ;AAAA,YAC7C;AAAA,UAAA;AAAA,QACF,CACD,EACA,MAAM,MAAM;AACJ,iBAAA;AAAA,YACL,MAAM,CAAC;AAAA,YACP;AAAA,UAAA;AAAA,QACF,CACD;AAAA,MAAA,CACJ;AAAA,IAAA;AAGI,WAAA,QAAQ,QAAQ,aAAa;AAAA,EACtC;AACF;;;"}
1
+ {"version":3,"file":"index-DiqkM4F0.js","sources":["../../admin/src/pluginId.ts","../../admin/src/components/Initializer.tsx","../../admin/src/components/PluginIcon.tsx","../../admin/src/index.ts"],"sourcesContent":["export const pluginId = 'cloud';\n","/**\n *\n * Initializer\n *\n */\n\nimport { useEffect, useRef } from 'react';\n\nimport { pluginId } from '../pluginId';\n\ntype InitializerProps = {\n setPlugin: (id: string) => void;\n};\n\nconst Initializer = ({ setPlugin }: InitializerProps) => {\n const ref = useRef(setPlugin);\n\n useEffect(() => {\n ref.current(pluginId);\n }, []);\n\n return null;\n};\n\nexport { Initializer };\n","/**\n *\n * PluginIcon\n *\n */\n\nimport { Cloud } from '@strapi/icons';\n\nconst PluginIcon = () => <Cloud />;\n\nexport { PluginIcon };\n","/* eslint-disable check-file/filename-naming-convention */\nimport { prefixPluginTranslations } from '@strapi/helper-plugin';\n\nimport { Initializer } from './components/Initializer';\nimport { PluginIcon } from './components/PluginIcon';\nimport { pluginId } from './pluginId';\n\nconst name = 'Deploy';\n\n// eslint-disable-next-line import/no-default-export\nexport default {\n register(app: any) {\n const { backendURL } = window.strapi;\n\n // Only add the plugin menu link and registering it if the project is on development (localhost).\n if (backendURL?.includes('localhost')) {\n app.addMenuLink({\n to: `/plugins/${pluginId}`,\n icon: PluginIcon,\n intlLabel: {\n id: `${pluginId}.plugin.name`,\n defaultMessage: name,\n },\n Component: async () => {\n const { App } = await import('./pages/App');\n\n return App;\n },\n });\n const plugin = {\n id: pluginId,\n initializer: Initializer,\n isReady: false,\n name,\n };\n\n app.registerPlugin(plugin);\n }\n },\n\n async registerTrads(app: any) {\n const { locales } = app;\n\n const importedTrads = await Promise.all(\n (locales as any[]).map((locale) => {\n return import(`./translations/${locale}.json`)\n .then(({ default: data }) => {\n return {\n data: prefixPluginTranslations(data, pluginId),\n locale,\n };\n })\n .catch(() => {\n return {\n data: {},\n locale,\n };\n });\n })\n );\n\n return Promise.resolve(importedTrads);\n },\n};\n"],"names":["useRef","useEffect","jsx","Cloud","prefixPluginTranslations"],"mappings":";;;;;;;;;;;;;;;;;;;;;AAAO,MAAM,WAAW;ACcxB,MAAM,cAAc,CAAC,EAAE,gBAAkC;AACvD,QAAM,MAAMA,MAAAA,OAAO,SAAS;AAE5BC,QAAAA,UAAU,MAAM;AACd,QAAI,QAAQ,QAAQ;AAAA,EACtB,GAAG,CAAA,CAAE;AAEL,SAAO;AACT;ACdA,MAAM,aAAa,MAAMC,2BAAAA,IAACC,MAAAA,OAAA,EAAM;ACDhC,MAAM,OAAO;AAGb,MAAA,QAAe;AAAA,EACb,SAAS,KAAU;AACjB,UAAM,EAAE,eAAe,OAAO;AAG9B,QAAI,YAAY,SAAS,WAAW,GAAG;AACrC,UAAI,YAAY;AAAA,QACd,IAAI,YAAY,QAAQ;AAAA,QACxB,MAAM;AAAA,QACN,WAAW;AAAA,UACT,IAAI,GAAG,QAAQ;AAAA,UACf,gBAAgB;AAAA,QAAA;AAAA,QAElB,WAAW,YAAY;AACrB,gBAAM,EAAE,IAAA,IAAQ,MAAM,QAAA,QAAA,EAAA,KAAA,MAAA,QAAO,mBAAa,CAAA;AAE1C,iBAAO;AAAA,QACT;AAAA,MAAA,CACD;AACD,YAAM,SAAS;AAAA,QACb,IAAI;AAAA,QACJ,aAAa;AAAA,QACb,SAAS;AAAA,QACT;AAAA,MAAA;AAGF,UAAI,eAAe,MAAM;AAAA,IAC3B;AAAA,EACF;AAAA,EAEA,MAAM,cAAc,KAAU;AAC5B,UAAM,EAAE,YAAY;AAEpB,UAAM,gBAAgB,MAAM,QAAQ;AAAA,MACjC,QAAkB,IAAI,CAAC,WAAW;AACjC,eAAO,qCAAA,uBAAA,OAAA,EAAA,0BAAA,MAAA,QAAA,QAAA,EAAA,KAAA,MAAA,QAAA,kBAAA,CAAA,GAAA,0BAAA,MAAA,qCAAA,kBAAA,CAAA,EAAA,CAAA,GAAA,kBAAA,MAAA,SAAA,CAAA,EACJ,KAAK,CAAC,EAAE,SAAS,WAAW;AAC3B,iBAAO;AAAA,YACL,MAAMC,aAAAA,yBAAyB,MAAM,QAAQ;AAAA,YAC7C;AAAA,UAAA;AAAA,QAEJ,CAAC,EACA,MAAM,MAAM;AACX,iBAAO;AAAA,YACL,MAAM,CAAA;AAAA,YACN;AAAA,UAAA;AAAA,QAEJ,CAAC;AAAA,MACL,CAAC;AAAA,IAAA;AAGH,WAAO,QAAQ,QAAQ,aAAa;AAAA,EACtC;AACF;;;"}
@@ -1,8 +1,5 @@
1
1
  "use strict";
2
- const index = require("../_chunks/index-mjWlxKqq.js");
2
+ const index = require("../_chunks/index-DiqkM4F0.js");
3
3
  require("@strapi/helper-plugin");
4
- require("react");
5
- require("react/jsx-runtime");
6
- require("@strapi/icons");
7
4
  module.exports = index.index;
8
5
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;"}
1
+ {"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;"}
@@ -1,8 +1,5 @@
1
- import { i } from "../_chunks/index-DQ7yF1-E.mjs";
1
+ import { i } from "../_chunks/index-DFKy9ZkE.mjs";
2
2
  import "@strapi/helper-plugin";
3
- import "react";
4
- import "react/jsx-runtime";
5
- import "@strapi/icons";
6
3
  export {
7
4
  i as default
8
5
  };
@@ -1 +1 @@
1
- {"version":3,"file":"index.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;"}
1
+ {"version":3,"file":"index.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@strapi/plugin-cloud",
3
- "version": "4.26.0",
3
+ "version": "4.26.2",
4
4
  "description": "Instructions to deploy your local project to Strapi Cloud",
5
5
  "license": "MIT",
6
6
  "author": {
@@ -37,22 +37,22 @@
37
37
  },
38
38
  "dependencies": {
39
39
  "@strapi/design-system": "1.19.0",
40
- "@strapi/helper-plugin": "4.26.0",
40
+ "@strapi/helper-plugin": "4.26.2",
41
41
  "@strapi/icons": "1.19.0",
42
42
  "react-intl": "6.4.1"
43
43
  },
44
44
  "devDependencies": {
45
- "@strapi/strapi": "4.26.0",
45
+ "@strapi/strapi": "4.26.2",
46
46
  "@types/react": "18.2.39",
47
47
  "@types/react-dom": "18.2.17",
48
48
  "@types/react-router-dom": "^5.3.3",
49
49
  "@types/styled-components": "5.1.32",
50
- "eslint-config-custom": "4.26.0",
50
+ "eslint-config-custom": "4.26.2",
51
51
  "react": "18.2.0",
52
52
  "react-dom": "18.2.0",
53
53
  "react-router-dom": "5.3.4",
54
54
  "styled-components": "5.3.3",
55
- "tsconfig": "4.26.0",
55
+ "tsconfig": "4.26.2",
56
56
  "typescript": "5.2.2"
57
57
  },
58
58
  "peerDependencies": {
@@ -63,7 +63,7 @@
63
63
  "styled-components": "5.3.3"
64
64
  },
65
65
  "engines": {
66
- "node": ">=18.0.0 <=20.x.x",
66
+ "node": ">=18.0.0 <=22.x.x",
67
67
  "npm": ">=6.0.0"
68
68
  },
69
69
  "strapi": {
@@ -72,5 +72,5 @@
72
72
  "kind": "plugin",
73
73
  "displayName": "Strapi Cloud"
74
74
  },
75
- "gitHead": "57657610e79a82f73b7ca504cb66aaa9109d3a0b"
75
+ "gitHead": "7ad165f89d1ccae3c524439a36fc619ecf6b23f9"
76
76
  }
@@ -1 +0,0 @@
1
- {"version":3,"file":"en-IGOLzfH6.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"en-evVkl65r.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"fr-e4xtqkR1.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"fr-o9I0MEIB.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;"}