@hostlink/nuxt-light 1.14.0 → 1.14.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.
package/dist/module.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "light",
3
3
  "configKey": "light",
4
- "version": "1.14.0",
4
+ "version": "1.14.2",
5
5
  "builder": {
6
6
  "@nuxt/module-builder": "0.8.3",
7
7
  "unbuild": "2.0.0"
@@ -8,6 +8,7 @@ const { humanStorageSize } = format
8
8
  const light = useLight();
9
9
  const i18n = useI18n();
10
10
  const quasar = useQuasar();
11
+ const $q = quasar;
11
12
  const emit = defineEmits(["input", "close"]);
12
13
 
13
14
  const props = defineProps({
@@ -339,7 +340,7 @@ const showUploadFiles = ref(false);
339
340
 
340
341
  const onUploadFiles = async () => {
341
342
 
342
- quasar.loading.show({
343
+ $q.loading.show({
343
344
  message: "Uploading files...",
344
345
  });
345
346
 
@@ -352,17 +353,16 @@ const onUploadFiles = async () => {
352
353
  });
353
354
  }
354
355
  } catch (e) {
355
- quasar.dialog({
356
+ $q.dialog({
356
357
  title: "Error",
357
358
  message: e.message,
358
359
  });
359
-
360
+ $q.loading.hide();
360
361
  return;
361
-
362
362
  }
363
363
  uploadFiles.value = [];
364
364
 
365
- quasar.loading.hide();
365
+ $q.loading.hide();
366
366
 
367
367
  showUploadFiles.value = false;
368
368
 
@@ -1,13 +1,14 @@
1
1
  <script setup lang="ts">
2
2
  import { ref, computed, useAttrs } from "vue";
3
3
  import { useLight, m, q } from '#imports';
4
- import { Loading, useQuasar } from "quasar";
4
+ import { useQuasar } from "quasar";
5
5
  import { useI18n } from "vue-i18n";
6
6
  import { format } from 'quasar'
7
7
  const { humanStorageSize } = format
8
8
  const light = useLight();
9
9
  const i18n = useI18n();
10
10
  const quasar = useQuasar();
11
+ const $q = quasar;
11
12
 
12
13
  const { system } = await q({
13
14
  system: {
@@ -90,7 +91,7 @@ const onUploadFile = async () => {
90
91
  return;
91
92
  }
92
93
 
93
- Loading.show({
94
+ $q.loading.show({
94
95
  message: i18n.t("Uploading file..."),
95
96
  });
96
97
 
@@ -105,22 +106,20 @@ const onUploadFile = async () => {
105
106
  if (v.startsWith("/")) v = v.substr(1);
106
107
 
107
108
  localValue.value = v;
108
-
109
- Loading.hide();
110
-
111
109
  show.value = false;
112
110
  uploadFile.value = null;
113
- return;
114
111
  } catch (e: any) {
115
- quasar.dialog({
112
+ $q.loading.hide();
113
+
114
+ $q.dialog({
116
115
  title: i18n.t("Error"),
117
116
  message: e.message,
118
117
  });
119
- Loading.hide();
120
118
  }
119
+ $q.loading.hide();
120
+
121
121
 
122
122
 
123
- Loading.hide();
124
123
  }
125
124
 
126
125
  </script>
@@ -261,6 +261,7 @@ const onRequest = async (p: any) => {
261
261
  props.columns?.forEach((col) => {
262
262
  if (col.gqlField) {
263
263
  builder.add(col.gqlField);
264
+ return;
264
265
  }
265
266
 
266
267
  if (!col.name) return;
@@ -431,7 +432,7 @@ const onDelete = async (id: any) => {
431
432
  const attrs = computed(() => {
432
433
  return {
433
434
  ...props,
434
-
435
+
435
436
  ...{
436
437
  dense: light.getStyle("tableDense"),
437
438
  flat: light.getStyle("tableFlat"),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hostlink/nuxt-light",
3
- "version": "1.14.0",
3
+ "version": "1.14.2",
4
4
  "description": "HostLink Nuxt Light Framework",
5
5
  "repository": {
6
6
  "type": "git",
@@ -56,4 +56,4 @@
56
56
  "eslint": "^8.46.0",
57
57
  "nuxt": "^3.7.0"
58
58
  }
59
- }
59
+ }