@adminforth/upload 1.0.16 → 1.0.18

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.
@@ -158,7 +158,7 @@ async function confirmImage() {
158
158
  const img = images.value[currentIndex];
159
159
  // read url to base64 and send it to the parent component
160
160
  const imgBlob = await fetch(
161
- `/adminapi/v1/plugin/${props.meta.pluginInstanceId}/cors-proxy?url=${encodeURIComponent(img)}`
161
+ `${import.meta.env.VITE_ADMINFORTH_PUBLIC_PATH || ''}/adminapi/v1/plugin/${props.meta.pluginInstanceId}/cors-proxy?url=${encodeURIComponent(img)}`
162
162
  ).then(res => { return res.blob() });
163
163
 
164
164
  emit('uploadImage', imgBlob);
@@ -158,7 +158,7 @@ async function confirmImage() {
158
158
  const img = images.value[currentIndex];
159
159
  // read url to base64 and send it to the parent component
160
160
  const imgBlob = await fetch(
161
- `/adminapi/v1/plugin/${props.meta.pluginInstanceId}/cors-proxy?url=${encodeURIComponent(img)}`
161
+ `${import.meta.env.VITE_ADMINFORTH_PUBLIC_PATH || ''}/adminapi/v1/plugin/${props.meta.pluginInstanceId}/cors-proxy?url=${encodeURIComponent(img)}`
162
162
  ).then(res => { return res.blob() });
163
163
 
164
164
  emit('uploadImage', imgBlob);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@adminforth/upload",
3
- "version": "1.0.16",
3
+ "version": "1.0.18",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",