@processmaker/screen-builder 2.83.3 → 2.83.4

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": "@processmaker/screen-builder",
3
- "version": "2.83.3",
3
+ "version": "2.83.4",
4
4
  "scripts": {
5
5
  "dev": "VITE_COVERAGE=true vite",
6
6
  "build": "vite build",
@@ -5,7 +5,7 @@
5
5
  {{ $t('File uploads are unavailable in preview mode.') }}
6
6
  </b-card>
7
7
  <uploader
8
- v-else
8
+ v-if="!inPreviewMode && showComponent"
9
9
  :options="options"
10
10
  :attrs="attrs"
11
11
  ref="uploader"
@@ -106,6 +106,10 @@ export default {
106
106
 
107
107
  this.$root.$on('removed-loop',
108
108
  (loop, removed) => this.listenRemovedLoop(loop, removed));
109
+
110
+ window.ProcessMaker.EventBus.$on("modal-shown", () => {
111
+ this.clearFiles();
112
+ });
109
113
 
110
114
  this.removeDefaultClasses();
111
115
 
@@ -297,9 +301,16 @@ export default {
297
301
  nativeFiles: {},
298
302
  uploading: false,
299
303
  invalidFile: false,
304
+ showComponent: true,
300
305
  };
301
306
  },
302
307
  methods: {
308
+ clearFiles() {
309
+ this.showComponent = false;
310
+ this.$nextTick(() => {
311
+ this.showComponent = true;
312
+ });
313
+ },
303
314
  uploaderLoaded() {
304
315
  return this.$refs['uploader'];
305
316
  },