@simsustech/quasar-components 0.11.9 → 0.11.10

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.
@@ -32,6 +32,11 @@ declare const _default: <T extends Account>(__VLS_props: NonNullable<Awaited<typ
32
32
  pagination: Pagination;
33
33
  mappedRoles: Record<string, string>;
34
34
  columns?: QTableColumn[];
35
+ icons?: {
36
+ search: string;
37
+ cancel: string;
38
+ moreVert: string;
39
+ };
35
40
  } & Partial<{}>> & import("vue").PublicProps;
36
41
  expose(exposed: import("vue").ShallowUnwrapRef<{}>): void;
37
42
  attrs: any;
@@ -8,6 +8,9 @@ export interface Props {
8
8
  resourceScopes?: {
9
9
  name: string;
10
10
  }[];
11
+ icons?: {
12
+ check: string;
13
+ };
11
14
  }
12
15
  declare const _default: import("vue").DefineComponent<Props, {
13
16
  variables: import("vue").Ref<{
@@ -6,6 +6,10 @@ export interface Props {
6
6
  input?: Omit<QInputProps, 'id' | 'name' | 'modelValue' | 'label' | 'rules' | 'type' | 'lazy-rules' | 'autofocus' | ('label' & {
7
7
  style?: Partial<CSSStyleDeclaration>;
8
8
  })>;
9
+ icons?: {
10
+ visibility: string;
11
+ visibilifyOff: string;
12
+ };
9
13
  }
10
14
  declare const _default: __VLS_WithSlots<import("vue").DefineComponent<Props, {
11
15
  variables: import("vue").Ref<{
@@ -6,6 +6,10 @@ export interface Props {
6
6
  input?: Omit<QInputProps, 'id' | 'name' | 'modelValue' | 'label' | 'rules' | 'type' | 'lazy-rules' | 'autofocus' | ('label' & {
7
7
  style?: Partial<CSSStyleDeclaration>;
8
8
  })>;
9
+ icons?: {
10
+ visibility: string;
11
+ visibilityOff: string;
12
+ };
9
13
  }
10
14
  declare const _default: __VLS_WithSlots<import("vue").DefineComponent<Props, {
11
15
  variables: import("vue").Ref<{}, {}>;
@@ -41,6 +45,10 @@ declare const _default: __VLS_WithSlots<import("vue").DefineComponent<Props, {
41
45
  }) => any) | undefined;
42
46
  }>, {
43
47
  minimumPasswordLength: number;
48
+ icons: {
49
+ visibility: string;
50
+ visibilityOff: string;
51
+ };
44
52
  form: QFormProps & Partial<HTMLFormElement> & Partial<HTMLDivElement>;
45
53
  input: Omit<QInputProps, "id" | "name" | "modelValue" | "label" | "rules" | "type" | "lazy-rules" | "autofocus" | ("label" & {
46
54
  style?: Partial<CSSStyleDeclaration>;
@@ -11,6 +11,10 @@ export interface Props {
11
11
  input?: Omit<QInputProps, 'id' | 'name' | 'modelValue' | 'label' | 'rules' | 'type' | 'lazy-rules' | 'autofocus' | ('label' & {
12
12
  style?: Partial<CSSStyleDeclaration>;
13
13
  })>;
14
+ icons?: {
15
+ visibility: string;
16
+ visibilityOff: string;
17
+ };
14
18
  }
15
19
  declare const _default: __VLS_WithSlots<import("vue").DefineComponent<Props, {
16
20
  variables: import("vue").Ref<{
@@ -66,6 +70,10 @@ declare const _default: __VLS_WithSlots<import("vue").DefineComponent<Props, {
66
70
  }) => any) | undefined;
67
71
  }>, {
68
72
  minimumPasswordLength: number;
73
+ icons: {
74
+ visibility: string;
75
+ visibilityOff: string;
76
+ };
69
77
  form: QFormProps & Partial<HTMLFormElement> & Partial<HTMLDivElement>;
70
78
  input: Omit<QInputProps, "id" | "name" | "modelValue" | "label" | "rules" | "type" | "lazy-rules" | "autofocus" | ("label" & {
71
79
  style?: Partial<CSSStyleDeclaration>;
@@ -1,6 +1,9 @@
1
1
  import type { RouteLocationRaw } from 'vue-router';
2
2
  export interface Props {
3
3
  userRoute: RouteLocationRaw;
4
+ icons?: {
5
+ person: string;
6
+ };
4
7
  }
5
8
  declare const _default: __VLS_WithSlots<import("vue").DefineComponent<Props, {
6
9
  variables: import("vue").Ref<{}, {}>;
@@ -7,6 +7,10 @@ export interface Props {
7
7
  required?: boolean;
8
8
  clearable?: boolean;
9
9
  date?: Partial<QDateProps>;
10
+ icons?: {
11
+ event: string;
12
+ clear: string;
13
+ };
10
14
  }
11
15
  declare const _default: import("vue").DefineComponent<Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
12
16
  "update:modelValue": (val: string | null) => any;
@@ -14,6 +18,10 @@ declare const _default: import("vue").DefineComponent<Props, {}, {}, {}, {}, imp
14
18
  "onUpdate:modelValue"?: ((val: string | null) => any) | undefined;
15
19
  }>, {
16
20
  label: string;
21
+ icons: {
22
+ event: string;
23
+ clear: string;
24
+ };
17
25
  format: "YYYY-MM-DD" | "DD-MM-YYYY" | "MM-DD-YYYY";
18
26
  date: Partial<QDateProps>;
19
27
  locale: QuasarLanguageCodes[number];
@@ -0,0 +1,11 @@
1
+ import { QuasarLanguage } from 'quasar';
2
+ import { useLang as useFlagsLang } from '../flags/lang/index.js';
3
+ export interface Props {
4
+ modelValue: string;
5
+ languageImports: Record<string, () => Promise<{
6
+ default: QuasarLanguage;
7
+ }>>;
8
+ allowedCodes?: [keyof ReturnType<typeof useFlagsLang>['value']['languages']];
9
+ }
10
+ declare const _default: import("vue").DefineComponent<Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<Props> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>;
11
+ export default _default;
@@ -3,6 +3,10 @@ export interface Props {
3
3
  disabled?: boolean;
4
4
  topBarFab?: boolean;
5
5
  topBarShrink?: boolean;
6
+ icons?: {
7
+ add: string;
8
+ edit: string;
9
+ };
6
10
  }
7
11
  declare const _default: __VLS_WithSlots<import("vue").DefineComponent<Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
8
12
  update: (args_0: {
@@ -24,6 +28,10 @@ declare const _default: __VLS_WithSlots<import("vue").DefineComponent<Props, {},
24
28
  }) => any) | undefined;
25
29
  }>, {
26
30
  type: "create" | "update";
31
+ icons: {
32
+ add: string;
33
+ edit: string;
34
+ };
27
35
  disabled: boolean;
28
36
  topBarFab: boolean;
29
37
  topBarShrink: boolean;
@@ -1,8 +1,10 @@
1
1
  export interface Props {
2
2
  display?: boolean;
3
3
  buttonType?: 'submit' | 'send';
4
- closeIcon?: string;
5
4
  padding?: boolean;
5
+ icons?: {
6
+ close: string;
7
+ };
6
8
  }
7
9
  declare const _default: __VLS_WithSlots<import("vue").DefineComponent<Props, {
8
10
  variables: import("vue").Ref<{}, {}>;
@@ -28,8 +30,10 @@ declare const _default: __VLS_WithSlots<import("vue").DefineComponent<Props, {
28
30
  done: (success?: boolean) => void;
29
31
  }) => any) | undefined;
30
32
  }>, {
33
+ icons: {
34
+ close: string;
35
+ };
31
36
  buttonType: "submit" | "send";
32
- closeIcon: string;
33
37
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, {
34
38
  title?: ((props: {}) => any) | undefined;
35
39
  default?: ((props: {}) => any) | undefined;
@@ -3,5 +3,6 @@ export { default as QStyledCard } from './QStyledCard.vue';
3
3
  export { default as ResponsiveDialog } from './ResponsiveDialog.vue';
4
4
  export { default as ResourcePage } from './ResourcePage.vue';
5
5
  export { default as QLanguageSelect } from './QLanguageSelect.vue';
6
+ export { default as QLanguageSelectBtn } from './QLanguageSelectBtn.vue';
6
7
  export { default as QDrawerList } from './QDrawerList.vue';
7
8
  export { useLang, loadLang } from './lang/index.js';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@simsustech/quasar-components",
3
- "version": "0.11.9",
3
+ "version": "0.11.10",
4
4
  "author": "Stefan van Herwijnen",
5
5
  "description": "High level components for Quasar Framework",
6
6
  "license": "MIT",
@@ -17,17 +17,17 @@
17
17
  </q-tr>
18
18
  </template>
19
19
  <template #top-right>
20
- <q-btn icon="search" flat>
20
+ <q-btn :icon="searchIcon" flat>
21
21
  <q-menu>
22
22
  <div class="q-pa-sm">
23
23
  <q-input v-model="name" :label="lang.account.fields.name">
24
24
  <template #append>
25
25
  <q-icon
26
26
  v-if="name"
27
- name="cancel"
28
- @click="name = ''"
29
27
  class="q-field__focusable-action"
30
28
  role="button"
29
+ :name="cancelIcon"
30
+ @click="name = ''"
31
31
  />
32
32
  </template>
33
33
  </q-input>
@@ -35,10 +35,10 @@
35
35
  <template #append>
36
36
  <q-icon
37
37
  v-if="email"
38
- name="cancel"
39
- @click="email = ''"
40
38
  class="q-field__focusable-action"
41
39
  role="button"
40
+ :name="cancelIcon"
41
+ @click="email = ''"
42
42
  />
43
43
  </template>
44
44
  </q-input>
@@ -55,10 +55,10 @@
55
55
  <template #append>
56
56
  <q-icon
57
57
  v-if="roles.length"
58
- name="cancel"
59
- @click="roles = []"
60
58
  class="q-field__focusable-action"
61
59
  role="button"
60
+ :name="cancelIcon"
61
+ @click="roles = []"
62
62
  />
63
63
  </template>
64
64
  </q-select>
@@ -72,7 +72,7 @@
72
72
  {{ col.value }}
73
73
  </q-td>
74
74
  <q-td auto-width>
75
- <q-btn size="sm" round flat icon="more_vert">
75
+ <q-btn size="sm" round flat :icon="moreVertIcon">
76
76
  <q-menu>
77
77
  <q-list>
78
78
  <q-item clickable @click="openAddRoleDialog(props.row)">
@@ -127,6 +127,11 @@ const props = defineProps<{
127
127
  pagination: Pagination
128
128
  mappedRoles: Record<string, string> // value: label
129
129
  columns?: QTableColumn[]
130
+ icons?: {
131
+ search: string
132
+ cancel: string
133
+ moreVert: string
134
+ }
130
135
  }>()
131
136
 
132
137
  const emit = defineEmits<{
@@ -136,7 +141,7 @@ const emit = defineEmits<{
136
141
  (e: 'removeRole', { id, role }: { id: number; role: string }): void
137
142
  }>()
138
143
 
139
- const { modelValue, count, mappedRoles, columns } = toRefs(props)
144
+ const { modelValue, count, mappedRoles, columns, icons } = toRefs(props)
140
145
 
141
146
  // const { useQuery } = await createUseTrpc()
142
147
  const lang = useLang()
@@ -275,4 +280,8 @@ const openRemoveRoleDialog = (account: Account) => {
275
280
  emit('removeRole', { id: account.id, role })
276
281
  })
277
282
  }
283
+
284
+ const searchIcon = icons.value?.search ?? 'search'
285
+ const cancelIcon = icons.value?.cancel ?? 'cancel'
286
+ const moreVertIcon = icons.value?.moreVert ?? 'more_vert'
278
287
  </script>
@@ -2,7 +2,7 @@
2
2
  <q-list>
3
3
  <q-item v-for="scope in scopes" :key="scope.name">
4
4
  <q-item-section avatar>
5
- <q-icon color="green" name="check" />
5
+ <q-icon color="green" :name="checkIcon" />
6
6
  </q-item-section>
7
7
  <q-item-section>
8
8
  {{ scope.name }}
@@ -10,7 +10,7 @@
10
10
  </q-item>
11
11
  <q-item v-for="claim in claims" :key="claim.name">
12
12
  <q-item-section avatar>
13
- <q-icon color="green" name="check" />
13
+ <q-icon color="green" :name="checkIcon" />
14
14
  </q-item-section>
15
15
  <q-item-section>
16
16
  {{ claim.name }}
@@ -18,7 +18,7 @@
18
18
  </q-item>
19
19
  <q-item v-for="resourceScope in resourceScopes" :key="resourceScope.name">
20
20
  <q-item-section avatar>
21
- <q-icon color="green" name="check" />
21
+ <q-icon color="green" :name="checkIcon" />
22
22
  </q-item-section>
23
23
  <q-item-section>
24
24
  {{ resourceScope.name }}
@@ -34,7 +34,7 @@ export default {
34
34
  </script>
35
35
 
36
36
  <script setup lang="ts">
37
- import { computed, ref, watch } from 'vue'
37
+ import { computed, ref, toRefs, watch } from 'vue'
38
38
  import { useQuasar } from 'quasar'
39
39
  import { useLang, loadLang } from './lang'
40
40
 
@@ -48,21 +48,14 @@ export interface Props {
48
48
  resourceScopes?: {
49
49
  name: string
50
50
  }[]
51
+ icons?: {
52
+ check: string
53
+ }
51
54
  }
52
- defineProps<Props>()
53
- // const attrs = useAttrs();
54
- // const emit = defineEmits<{
55
- // (
56
- // e: "asyncEmit",
57
- // {
58
- // value,
59
- // done,
60
- // }: {
61
- // value: string;
62
- // done: () => void;
63
- // }
64
- // ): void;
65
- // }>();
55
+ const props = defineProps<Props>()
56
+
57
+ const { icons } = toRefs(props)
58
+
66
59
  const $q = useQuasar()
67
60
  const lang = useLang()
68
61
  if (lang.value.isoName !== $q.lang.isoName) loadLang($q.lang.isoName)
@@ -74,6 +67,8 @@ const message = computed(() => lang.value.consent.message)
74
67
  const allow = computed(() => lang.value.consent.allow)
75
68
  const deny = computed(() => lang.value.consent.deny)
76
69
 
70
+ const checkIcon = icons.value?.check ?? 'check'
71
+
77
72
  const variables = ref({
78
73
  message,
79
74
  allow,
@@ -44,7 +44,7 @@
44
44
  >
45
45
  <template #append>
46
46
  <q-icon
47
- :name="showPassword ? 'visibility' : 'visibility_off'"
47
+ :name="showPassword ? visibilityIcon : visibilityOffIcon"
48
48
  class="cursor-pointer"
49
49
  @click="showPassword = !showPassword"
50
50
  />
@@ -69,7 +69,7 @@ export default {
69
69
  </script>
70
70
 
71
71
  <script setup lang="ts">
72
- import { ref, computed, watch } from 'vue'
72
+ import { ref, computed, watch, toRefs } from 'vue'
73
73
  import { useQuasar, QFormProps, QForm, QInputProps } from 'quasar'
74
74
  import { useLang, loadLang } from './lang'
75
75
  import isEmail from 'validator/es/lib/isEmail'
@@ -92,8 +92,14 @@ export interface Props {
92
92
  | 'autofocus'
93
93
  | ('label' & { style?: Partial<CSSStyleDeclaration> })
94
94
  >
95
+ icons?: {
96
+ visibility: string
97
+ visibilifyOff: string
98
+ }
95
99
  }
96
- defineProps<Props>()
100
+ const props = defineProps<Props>()
101
+ const { icons } = toRefs(props)
102
+
97
103
  // const attrs = useAttrs();
98
104
  const emit = defineEmits<{
99
105
  (
@@ -154,6 +160,9 @@ const submit: InstanceType<typeof QSubmitButton>['$props']['onSubmit'] = (
154
160
  })
155
161
  }
156
162
 
163
+ const visibilityIcon = icons.value?.visibility ?? 'visibility'
164
+ const visibilityOffIcon = icons.value?.visibilifyOff ?? 'visibility_off'
165
+
157
166
  const variables = ref({
158
167
  header,
159
168
  createAccount,
@@ -19,7 +19,7 @@
19
19
  >
20
20
  <template #append>
21
21
  <q-icon
22
- :name="showPassword ? 'visibility' : 'visibility_off'"
22
+ :name="showPassword ? icons.visibility : icons.visibilityOff"
23
23
  class="cursor-pointer"
24
24
  @click="showPassword = !showPassword"
25
25
  />
@@ -38,7 +38,7 @@
38
38
  >
39
39
  <template #append>
40
40
  <q-icon
41
- :name="showRepeatPassword ? 'visibility' : 'visibility_off'"
41
+ :name="showRepeatPassword ? icons.visibility : icons.visibilityOff"
42
42
  class="cursor-pointer"
43
43
  @click="showRepeatPassword = !showRepeatPassword"
44
44
  />
@@ -79,11 +79,19 @@ export interface Props {
79
79
  | 'autofocus'
80
80
  | ('label' & { style?: Partial<CSSStyleDeclaration> })
81
81
  >
82
+ icons?: {
83
+ visibility: string
84
+ visibilityOff: string
85
+ }
82
86
  }
83
87
  const props = withDefaults(defineProps<Props>(), {
84
88
  minimumPasswordLength: 8,
85
89
  form: undefined,
86
- input: undefined
90
+ input: undefined,
91
+ icons: () => ({
92
+ visibility: 'visibility',
93
+ visibilityOff: 'visibility_off'
94
+ })
87
95
  })
88
96
  // const attrs = useAttrs();
89
97
  const emit = defineEmits<{
@@ -50,7 +50,7 @@
50
50
  >
51
51
  <template #append>
52
52
  <q-icon
53
- :name="showPassword ? 'visibility' : 'visibility_off'"
53
+ :name="showPassword ? icons.visibility : icons.visibilityOff"
54
54
  class="cursor-pointer"
55
55
  @click="showPassword = !showPassword"
56
56
  />
@@ -68,7 +68,7 @@
68
68
  >
69
69
  <template #append>
70
70
  <q-icon
71
- :name="showPassword ? 'visibility' : 'visibility_off'"
71
+ :name="showPassword ? icons.visibility : icons.visibilityOff"
72
72
  class="cursor-pointer"
73
73
  @click="showPassword = !showPassword"
74
74
  />
@@ -115,12 +115,20 @@ export interface Props {
115
115
  | 'autofocus'
116
116
  | ('label' & { style?: Partial<CSSStyleDeclaration> })
117
117
  >
118
+ icons?: {
119
+ visibility: string
120
+ visibilityOff: string
121
+ }
118
122
  }
119
123
  const props = withDefaults(defineProps<Props>(), {
120
124
  minimumPasswordLength: 8,
121
125
  extraFields: undefined,
122
126
  form: undefined,
123
- input: undefined
127
+ input: undefined,
128
+ icons: () => ({
129
+ visibility: 'visibility',
130
+ visibilityOff: 'visibility_off'
131
+ })
124
132
  })
125
133
  // const attrs = useAttrs();
126
134
  const emit = defineEmits<{
@@ -1,5 +1,5 @@
1
1
  <template>
2
- <q-btn icon="person">
2
+ <q-btn :icon="personIcon">
3
3
  <q-menu>
4
4
  <q-list>
5
5
  <q-item :to="userRoute">
@@ -21,15 +21,19 @@ export default {
21
21
  </script>
22
22
 
23
23
  <script setup lang="ts">
24
- import { ref, watch } from 'vue'
24
+ import { ref, toRefs, watch } from 'vue'
25
25
  import { useQuasar } from 'quasar'
26
26
  import { useLang, loadLang } from './lang'
27
27
  import type { RouteLocationRaw } from 'vue-router'
28
28
 
29
29
  export interface Props {
30
30
  userRoute: RouteLocationRaw
31
+ icons?: {
32
+ person: string
33
+ }
31
34
  }
32
- defineProps<Props>()
35
+ const props = defineProps<Props>()
36
+ const { icons } = toRefs(props)
33
37
  // const attrs = useAttrs();
34
38
  const emit = defineEmits<{
35
39
  (e: 'signOut'): void
@@ -41,6 +45,8 @@ watch($q.lang, (val) => {
41
45
  loadLang($q.lang.isoName)
42
46
  })
43
47
 
48
+ const personIcon = icons.value?.person ?? 'person'
49
+
44
50
  const variables = ref({
45
51
  // header: lang.value.some.nested.prop
46
52
  })
@@ -26,11 +26,11 @@
26
26
  <template #append>
27
27
  <q-icon
28
28
  v-if="clearable"
29
- name="clear"
29
+ :name="icons.clear"
30
30
  class="cursor-pointer"
31
31
  @click="emit('update:modelValue', null)"
32
32
  />
33
- <q-icon name="event" class="cursor-pointer">
33
+ <q-icon :name="icons.event" class="cursor-pointer">
34
34
  <q-tooltip v-if="formattedDate">
35
35
  {{ formattedDate }}
36
36
  </q-tooltip>
@@ -74,12 +74,20 @@ export interface Props {
74
74
  required?: boolean
75
75
  clearable?: boolean
76
76
  date?: Partial<QDateProps>
77
+ icons?: {
78
+ event: string
79
+ clear: string
80
+ }
77
81
  }
78
82
  const props = withDefaults(defineProps<Props>(), {
79
83
  format: 'YYYY-MM-DD',
80
84
  locale: 'en-US',
81
85
  label: '',
82
- date: () => ({})
86
+ date: () => ({}),
87
+ icons: () => ({
88
+ event: 'event',
89
+ clear: 'clear'
90
+ })
83
91
  })
84
92
  const emit = defineEmits<{
85
93
  (e: 'update:modelValue', val: string | null): void
@@ -3,6 +3,7 @@
3
3
  v-bind="attrs"
4
4
  :options="languageOptions"
5
5
  :model-value="modelValue"
6
+ borderless
6
7
  emit-value
7
8
  map-options
8
9
  >
@@ -0,0 +1,99 @@
1
+ <template>
2
+ <q-btn>
3
+ <div v-if="modelValue">
4
+ <component
5
+ :is="flags[modelValue.slice(-2).toLowerCase() as keyof typeof flags]"
6
+ />
7
+ </div>
8
+
9
+ <q-menu>
10
+ <q-list>
11
+ <q-item
12
+ v-for="option in languageOptions"
13
+ :key="option.value"
14
+ v-close-popup
15
+ clickable
16
+ @click="$emit('update:model-value', option.value)"
17
+ >
18
+ <q-item-section avatar>
19
+ <component
20
+ :is="
21
+ flags[
22
+ option.value.slice(-2).toLowerCase() as keyof typeof flags
23
+ ]
24
+ "
25
+ />
26
+ </q-item-section>
27
+ <q-item-section>
28
+ <q-item-label>
29
+ {{ option.label }}
30
+ </q-item-label>
31
+ </q-item-section>
32
+ </q-item>
33
+ </q-list>
34
+ </q-menu>
35
+ </q-btn>
36
+ </template>
37
+
38
+ <script setup lang="ts">
39
+ import { computed, watch } from 'vue'
40
+ import { useQuasar, QuasarLanguage } from 'quasar'
41
+ import * as flags from '../flags/index.js'
42
+ import { useLang as useFlagsLang } from '../flags/lang/index.js'
43
+
44
+ export interface Props {
45
+ modelValue: string
46
+ languageImports: Record<string, () => Promise<{ default: QuasarLanguage }>>
47
+ allowedCodes?: [keyof ReturnType<typeof useFlagsLang>['value']['languages']]
48
+ }
49
+ const {
50
+ modelValue,
51
+ allowedCodes = ['en-US', 'nl'],
52
+ languageImports
53
+ } = defineProps<Props>()
54
+ const $q = useQuasar()
55
+
56
+ const flagsLang = useFlagsLang()
57
+
58
+ const languageOptions = computed(() => {
59
+ const options = []
60
+ for (let lang of Object.keys(flagsLang.value.languages) as Array<
61
+ keyof (typeof flagsLang.value)['languages']
62
+ >) {
63
+ if (!allowedCodes.length || allowedCodes.includes(lang)) {
64
+ options.push({
65
+ label: flagsLang.value.languages[lang],
66
+ value: lang
67
+ })
68
+ }
69
+ }
70
+ return options
71
+ })
72
+
73
+ // const languageOptions = [
74
+ // {
75
+ // label: enUsLanguage.value,
76
+ // value: 'en-US'
77
+ // },
78
+ // {
79
+ // label: nlLanguage.value,
80
+ // value: 'nl'
81
+ // }
82
+ // ]
83
+
84
+ watch(
85
+ () => modelValue,
86
+ (langIso: string) => {
87
+ try {
88
+ languageImports[langIso]().then(
89
+ // langList[`../../../node_modules/quasar/lang/${langIso}.mjs`]().then(
90
+ (lang) => {
91
+ $q.lang.set(lang.default)
92
+ }
93
+ )
94
+ } catch (e) {
95
+ console.error(e)
96
+ }
97
+ }
98
+ )
99
+ </script>