@simsustech/quasar-components 0.3.4 → 0.3.6
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/CHANGELOG.md +13 -0
- package/StandardComponent.vue +19 -24
- package/dist/authentication.js +102 -99
- package/dist/flags.js +224 -5
- package/dist/form.js +66 -58
- package/dist/general.js +15 -24
- package/dist/types/ui/authentication/ConsentList.vue.d.ts +35 -10
- package/dist/types/ui/authentication/EmailChangeForm.vue.d.ts +29 -12
- package/dist/types/ui/authentication/EmailChangeStepper.vue.d.ts +15 -12
- package/dist/types/ui/authentication/LoginButton.vue.d.ts +10 -11
- package/dist/types/ui/authentication/LoginForm.vue.d.ts +33 -12
- package/dist/types/ui/authentication/OtpInput.vue.d.ts +12 -15
- package/dist/types/ui/authentication/PasswordChangeForm.vue.d.ts +42 -29
- package/dist/types/ui/authentication/PasswordChangeStepper.vue.d.ts +15 -12
- package/dist/types/ui/authentication/RegisterForm.vue.d.ts +56 -31
- package/dist/types/ui/authentication/RequestOtpForm.vue.d.ts +21 -12
- package/dist/types/ui/authentication/UserMenuButton.vue.d.ts +13 -12
- package/dist/types/ui/authentication/VerificationSlider.vue.d.ts +11 -12
- package/dist/types/ui/form/BooleanItem.vue.d.ts +18 -9
- package/dist/types/ui/form/BooleanSelect.vue.d.ts +24 -11
- package/dist/types/ui/form/DateInput.vue.d.ts +33 -10
- package/dist/types/ui/form/EmailInput.vue.d.ts +21 -12
- package/dist/types/ui/form/FormInput.vue.d.ts +27 -10
- package/dist/types/ui/form/FormItem.vue.d.ts +21 -10
- package/dist/types/ui/form/GenderItem.vue.d.ts +10 -9
- package/dist/types/ui/form/GenderSelect.vue.d.ts +25 -11
- package/dist/types/ui/form/PostalCodeInput.vue.d.ts +26 -11
- package/dist/types/ui/form/TelephoneNumberInput.vue.d.ts +18 -11
- package/dist/types/ui/general/QLanguageSelect.vue.d.ts +18 -9
- package/dist/types/ui/general/QStyledCard.vue.d.ts +10 -11
- package/dist/types/ui/general/QStyledLayout.vue.d.ts +12 -11
- package/dist/types/ui/general/QSubmitButton.vue.d.ts +1 -1
- package/dist/types/ui/general/ResourcePage.vue.d.ts +25 -30
- package/dist/types/ui/general/ResponsiveDialog.vue.d.ts +11 -12
- package/dist/types/virtualModules.d.ts +0 -1
- package/dist/virtualModules.d.ts +0 -1
- package/dist/virtualModules.js +34 -1
- package/dist/vite-plugin.js +1 -1
- package/package.json +21 -21
- package/src/ui/form/BooleanItem.vue +1 -1
- package/src/ui/form/BooleanSelect.vue +1 -1
- package/src/ui/form/DateInput.vue +9 -2
- package/src/ui/form/EmailInput.vue +3 -6
- package/src/ui/form/FormInput.vue +1 -1
- package/src/ui/form/FormItem.vue +1 -1
- package/src/ui/form/GenderItem.vue +1 -1
- package/src/ui/form/GenderSelect.vue +9 -5
- package/src/ui/form/TelephoneNumberInput.vue +1 -1
- package/src/ui/general/QLanguageSelect.vue +2 -2
- package/src/ui/general/ResourcePage.vue +2 -2
- package/src/ui/general/ResponsiveDialog.vue +1 -2
- package/src/virtualModules.ts +34 -34
- package/src/vite-plugin.ts +1 -1
- package/dist/en-US-6cc72154.js +0 -226
|
@@ -2,16 +2,23 @@ export interface Props {
|
|
|
2
2
|
modelValue: string;
|
|
3
3
|
required?: boolean;
|
|
4
4
|
}
|
|
5
|
-
declare const _default: import("vue").DefineComponent<
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
5
|
+
declare const _default: import("vue").DefineComponent<{
|
|
6
|
+
modelValue: {
|
|
7
|
+
type: import("vue").PropType<string>;
|
|
8
|
+
required: true;
|
|
9
|
+
};
|
|
10
|
+
required: {
|
|
11
|
+
type: import("vue").PropType<boolean>;
|
|
12
|
+
};
|
|
13
|
+
}, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "update:modelValue"[], "update:modelValue", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
14
|
+
modelValue: {
|
|
15
|
+
type: import("vue").PropType<string>;
|
|
15
16
|
required: true;
|
|
16
17
|
};
|
|
17
|
-
|
|
18
|
+
required: {
|
|
19
|
+
type: import("vue").PropType<boolean>;
|
|
20
|
+
};
|
|
21
|
+
}>> & {
|
|
22
|
+
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
23
|
+
}, {}, {}>;
|
|
24
|
+
export default _default;
|
|
@@ -3,14 +3,23 @@ export interface Props {
|
|
|
3
3
|
modelValue: string;
|
|
4
4
|
languageImports: Record<string, () => Promise<QuasarLanguage>>;
|
|
5
5
|
}
|
|
6
|
-
declare const _default: import("vue").DefineComponent<
|
|
7
|
-
|
|
8
|
-
type
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
6
|
+
declare const _default: import("vue").DefineComponent<{
|
|
7
|
+
modelValue: {
|
|
8
|
+
type: import("vue").PropType<string>;
|
|
9
|
+
required: true;
|
|
10
|
+
};
|
|
11
|
+
languageImports: {
|
|
12
|
+
type: import("vue").PropType<Record<string, () => Promise<QuasarLanguage>>>;
|
|
13
|
+
required: true;
|
|
14
|
+
};
|
|
15
|
+
}, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
16
|
+
modelValue: {
|
|
17
|
+
type: import("vue").PropType<string>;
|
|
18
|
+
required: true;
|
|
19
|
+
};
|
|
20
|
+
languageImports: {
|
|
21
|
+
type: import("vue").PropType<Record<string, () => Promise<QuasarLanguage>>>;
|
|
14
22
|
required: true;
|
|
15
23
|
};
|
|
16
|
-
}
|
|
24
|
+
}>>, {}, {}>;
|
|
25
|
+
export default _default;
|
|
@@ -2,10 +2,18 @@ import { QCardActionsProps } from 'quasar';
|
|
|
2
2
|
export interface Props {
|
|
3
3
|
actions?: QCardActionsProps;
|
|
4
4
|
}
|
|
5
|
-
declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<
|
|
5
|
+
declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
6
|
+
actions: {
|
|
7
|
+
type: import("vue").PropType<QCardActionsProps>;
|
|
8
|
+
};
|
|
9
|
+
}, {
|
|
6
10
|
variables: import("vue").Ref<{}>;
|
|
7
11
|
functions: import("vue").Ref<{}>;
|
|
8
|
-
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<
|
|
12
|
+
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
13
|
+
actions: {
|
|
14
|
+
type: import("vue").PropType<QCardActionsProps>;
|
|
15
|
+
};
|
|
16
|
+
}>>, {}, {}>, {
|
|
9
17
|
image?(_: {}): any;
|
|
10
18
|
title?(_: {}): any;
|
|
11
19
|
subtitle?(_: {}): any;
|
|
@@ -13,15 +21,6 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
13
21
|
actions?(_: {}): any;
|
|
14
22
|
}>;
|
|
15
23
|
export default _default;
|
|
16
|
-
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
17
|
-
type __VLS_TypePropsToRuntimeProps<T> = {
|
|
18
|
-
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
19
|
-
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
20
|
-
} : {
|
|
21
|
-
type: import('vue').PropType<T[K]>;
|
|
22
|
-
required: true;
|
|
23
|
-
};
|
|
24
|
-
};
|
|
25
24
|
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
26
25
|
new (): {
|
|
27
26
|
$slots: S;
|
|
@@ -1,22 +1,23 @@
|
|
|
1
1
|
export interface Props {
|
|
2
2
|
title: string;
|
|
3
3
|
}
|
|
4
|
-
declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<
|
|
4
|
+
declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
5
|
+
title: {
|
|
6
|
+
type: import("vue").PropType<string>;
|
|
7
|
+
required: true;
|
|
8
|
+
};
|
|
9
|
+
}, {
|
|
5
10
|
variables: import("vue").Ref<{}>;
|
|
6
11
|
functions: import("vue").Ref<{}>;
|
|
7
|
-
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<
|
|
12
|
+
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
13
|
+
title: {
|
|
14
|
+
type: import("vue").PropType<string>;
|
|
15
|
+
required: true;
|
|
16
|
+
};
|
|
17
|
+
}>>, {}, {}>, {
|
|
8
18
|
leftDrawerItems?(_: {}): any;
|
|
9
19
|
}>;
|
|
10
20
|
export default _default;
|
|
11
|
-
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
12
|
-
type __VLS_TypePropsToRuntimeProps<T> = {
|
|
13
|
-
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
14
|
-
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
15
|
-
} : {
|
|
16
|
-
type: import('vue').PropType<T[K]>;
|
|
17
|
-
required: true;
|
|
18
|
-
};
|
|
19
|
-
};
|
|
20
21
|
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
21
22
|
new (): {
|
|
22
23
|
$slots: S;
|
|
@@ -2,60 +2,55 @@ export interface Props {
|
|
|
2
2
|
type?: 'create' | 'update';
|
|
3
3
|
disabled?: boolean;
|
|
4
4
|
}
|
|
5
|
-
declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<
|
|
6
|
-
type:
|
|
7
|
-
|
|
8
|
-
|
|
5
|
+
declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
6
|
+
type: {
|
|
7
|
+
type: import("vue").PropType<"create" | "update">;
|
|
8
|
+
default: string;
|
|
9
|
+
};
|
|
10
|
+
disabled: {
|
|
11
|
+
type: import("vue").PropType<boolean>;
|
|
12
|
+
default: boolean;
|
|
13
|
+
};
|
|
14
|
+
}, {
|
|
9
15
|
variables: import("vue").Ref<{}>;
|
|
10
16
|
functions: import("vue").Ref<{}>;
|
|
11
17
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
|
|
12
18
|
create: (payload_0: {
|
|
13
|
-
data?:
|
|
19
|
+
data?: unknown;
|
|
14
20
|
done: (success?: boolean) => void;
|
|
15
21
|
}) => void;
|
|
16
22
|
update: (payload_0: {
|
|
17
|
-
data?:
|
|
23
|
+
data?: unknown;
|
|
18
24
|
done: (success?: boolean) => void;
|
|
19
25
|
}) => void;
|
|
20
|
-
}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<
|
|
21
|
-
type:
|
|
22
|
-
|
|
23
|
-
|
|
26
|
+
}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
27
|
+
type: {
|
|
28
|
+
type: import("vue").PropType<"create" | "update">;
|
|
29
|
+
default: string;
|
|
30
|
+
};
|
|
31
|
+
disabled: {
|
|
32
|
+
type: import("vue").PropType<boolean>;
|
|
33
|
+
default: boolean;
|
|
34
|
+
};
|
|
35
|
+
}>> & {
|
|
24
36
|
onCreate?: ((args_0: {
|
|
25
|
-
data?:
|
|
37
|
+
data?: unknown;
|
|
26
38
|
done: (success?: boolean) => void;
|
|
27
39
|
}) => any) | undefined;
|
|
28
40
|
onUpdate?: ((args_0: {
|
|
29
|
-
data?:
|
|
41
|
+
data?: unknown;
|
|
30
42
|
done: (success?: boolean) => void;
|
|
31
43
|
}) => any) | undefined;
|
|
32
44
|
}, {
|
|
33
45
|
type: "create" | "update";
|
|
34
46
|
disabled: boolean;
|
|
35
|
-
}>, {
|
|
47
|
+
}, {}>, {
|
|
36
48
|
default?(_: {}): any;
|
|
37
49
|
header?(_: {}): any;
|
|
38
50
|
}>;
|
|
39
51
|
export default _default;
|
|
40
|
-
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
41
|
-
type __VLS_TypePropsToRuntimeProps<T> = {
|
|
42
|
-
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
43
|
-
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
44
|
-
} : {
|
|
45
|
-
type: import('vue').PropType<T[K]>;
|
|
46
|
-
required: true;
|
|
47
|
-
};
|
|
48
|
-
};
|
|
49
|
-
type __VLS_WithDefaults<P, D> = {
|
|
50
|
-
[K in keyof Pick<P, keyof P>]: K extends keyof D ? __VLS_Prettify<P[K] & {
|
|
51
|
-
default: D[K];
|
|
52
|
-
}> : P[K];
|
|
53
|
-
};
|
|
54
52
|
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
55
53
|
new (): {
|
|
56
54
|
$slots: S;
|
|
57
55
|
};
|
|
58
56
|
};
|
|
59
|
-
type __VLS_Prettify<T> = {
|
|
60
|
-
[K in keyof T]: T[K];
|
|
61
|
-
} & {};
|
|
@@ -1,7 +1,11 @@
|
|
|
1
1
|
export interface Props {
|
|
2
2
|
display?: boolean;
|
|
3
3
|
}
|
|
4
|
-
declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<
|
|
4
|
+
declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<{
|
|
5
|
+
display: {
|
|
6
|
+
type: import("vue").PropType<boolean>;
|
|
7
|
+
};
|
|
8
|
+
}, {
|
|
5
9
|
variables: import("vue").Ref<{}>;
|
|
6
10
|
functions: import("vue").Ref<{
|
|
7
11
|
open: () => void | undefined;
|
|
@@ -12,24 +16,19 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
|
|
|
12
16
|
submit: (payload_0: {
|
|
13
17
|
done: (success?: boolean) => void;
|
|
14
18
|
}) => void;
|
|
15
|
-
}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<
|
|
19
|
+
}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
20
|
+
display: {
|
|
21
|
+
type: import("vue").PropType<boolean>;
|
|
22
|
+
};
|
|
23
|
+
}>> & {
|
|
16
24
|
onSubmit?: ((args_0: {
|
|
17
25
|
done: (success?: boolean) => void;
|
|
18
26
|
}) => any) | undefined;
|
|
19
|
-
}, {}>, {
|
|
27
|
+
}, {}, {}>, {
|
|
20
28
|
title?(_: {}): any;
|
|
21
29
|
default?(_: {}): any;
|
|
22
30
|
}>;
|
|
23
31
|
export default _default;
|
|
24
|
-
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
25
|
-
type __VLS_TypePropsToRuntimeProps<T> = {
|
|
26
|
-
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
27
|
-
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
28
|
-
} : {
|
|
29
|
-
type: import('vue').PropType<T[K]>;
|
|
30
|
-
required: true;
|
|
31
|
-
};
|
|
32
|
-
};
|
|
33
32
|
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
34
33
|
new (): {
|
|
35
34
|
$slots: S;
|
package/dist/virtualModules.d.ts
CHANGED
package/dist/virtualModules.js
CHANGED
|
@@ -1,3 +1,36 @@
|
|
|
1
1
|
export var FlagIcon = function (locale) { return "\n import { computed, ref, watch, h } from 'vue'\n import { useQuasar, QIcon } from 'quasar'\n import { useLang, loadLang } from '".concat(new URL("../src/ui/flags/lang", import.meta.url).pathname, "'\n import icon from '").concat(new URL("../src/ui/flags/assets/".concat(locale, ".svg"), import.meta.url).pathname, "'\n export default {\n setup(props, context) {\n const $q = useQuasar()\n const lang = useLang()\n if (lang.value.isoName !== $q.lang.isoName) loadLang($q.lang.isoName)\n watch($q.lang, (val) => {\n loadLang($q.lang.isoName)\n })\n \n const country = computed(\n () => lang.value.countries['").concat(locale, "']\n )\n // @ts-ignore\n // const language = computed(() => lang.value.languages['").concat(locale, "'])\n const language = computed(() => lang.value.languages['").concat(locale, "'])\n const variables = ref({\n country,\n language\n // header: lang.value.some.nested.prop\n })\n const functions = ref({\n // submit\n })\n\n context.expose({\n variables,\n functions\n })\n\n // return the render function\n return () => h(QIcon, { name: `img:${icon}` })\n }}\n"); };
|
|
2
2
|
export var Icon = function (icon) { return "\n import { computed, ref, watch, h } from 'vue'\n import { useQuasar, QIcon } from 'quasar'\n import icon from '".concat(new URL("../src/ui/icons/assets/".concat(icon, ".svg"), import.meta.url).pathname, "'\n import labels from '").concat(new URL("../src/ui/icons/labels.ts", import.meta.url).pathname, "'\n export default {\n setup(props, context) {\n const $q = useQuasar()\n\n const variables = ref(labels['").concat(icon, "'])\n\n const functions = ref({\n // submit\n })\n\n context.expose({\n variables,\n functions\n })\n\n // return the render function\n return () => h(QIcon, { name: `img:${icon}` })\n }}\n"); };
|
|
3
|
-
export
|
|
3
|
+
// export const FormItem = (field: string) => `
|
|
4
|
+
// import { ref, watch, useAttrs, h } from 'vue'
|
|
5
|
+
// import { QItem, QItemLabel, QItemSection, useQuasar } from 'quasar'
|
|
6
|
+
// import { useLang, loadLang } from '${
|
|
7
|
+
// new URL(`../src/ui/form/lang/index.ts`, import.meta.url).pathname
|
|
8
|
+
// }'
|
|
9
|
+
// export default {
|
|
10
|
+
// setup(props, context) {
|
|
11
|
+
// const $q = useQuasar()
|
|
12
|
+
// const attrs = useAttrs()
|
|
13
|
+
// const lang = useLang()
|
|
14
|
+
// if (lang.value.isoName !== $q.lang.isoName) loadLang($q.lang.isoName)
|
|
15
|
+
// watch($q.lang, (val) => {
|
|
16
|
+
// loadLang($q.lang.isoName)
|
|
17
|
+
// })
|
|
18
|
+
// const variables = ref({})
|
|
19
|
+
// const functions = ref({
|
|
20
|
+
// // submit
|
|
21
|
+
// })
|
|
22
|
+
// context.expose({
|
|
23
|
+
// variables,
|
|
24
|
+
// functions
|
|
25
|
+
// })
|
|
26
|
+
// // return the render function
|
|
27
|
+
// return () =>
|
|
28
|
+
// h(QItem, { attrs }, [
|
|
29
|
+
// h(QItemSection, {}, [
|
|
30
|
+
// h(QItemLabel, { overline: true }, 'field'),
|
|
31
|
+
// h(QItemLabel, {}, 'field')
|
|
32
|
+
// ])
|
|
33
|
+
// ])
|
|
34
|
+
// }
|
|
35
|
+
// }
|
|
36
|
+
// `
|
package/dist/vite-plugin.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@simsustech/quasar-components",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.6",
|
|
4
4
|
"author": "Stefan van Herwijnen",
|
|
5
5
|
"description": "High level components for Quasar Framework",
|
|
6
6
|
"license": "MIT",
|
|
@@ -52,28 +52,28 @@
|
|
|
52
52
|
"quasar": "^2.9.2"
|
|
53
53
|
},
|
|
54
54
|
"devDependencies": {
|
|
55
|
-
"@types/node": "^
|
|
56
|
-
"@types/validator": "^13.
|
|
57
|
-
"@types/ws": "^8.5.
|
|
58
|
-
"@typescript-eslint/eslint-plugin": "^
|
|
59
|
-
"@typescript-eslint/parser": "^
|
|
60
|
-
"@vitejs/plugin-vue": "^4.2.
|
|
61
|
-
"@vue/server-renderer": "^3.
|
|
62
|
-
"eslint": "^8.
|
|
63
|
-
"eslint-config-prettier": "^8.
|
|
55
|
+
"@types/node": "^20.4.5",
|
|
56
|
+
"@types/validator": "^13.9.0",
|
|
57
|
+
"@types/ws": "^8.5.5",
|
|
58
|
+
"@typescript-eslint/eslint-plugin": "^6.2.1",
|
|
59
|
+
"@typescript-eslint/parser": "^6.2.1",
|
|
60
|
+
"@vitejs/plugin-vue": "^4.2.3",
|
|
61
|
+
"@vue/server-renderer": "^3.3.4",
|
|
62
|
+
"eslint": "^8.46.0",
|
|
63
|
+
"eslint-config-prettier": "^8.9.0",
|
|
64
64
|
"eslint-plugin-prettier-vue": "^4.2.0",
|
|
65
|
-
"eslint-plugin-vue": "^9.
|
|
66
|
-
"glob": "^10.
|
|
65
|
+
"eslint-plugin-vue": "^9.16.1",
|
|
66
|
+
"glob": "^10.3.3",
|
|
67
67
|
"local-pkg": "^0.4.3",
|
|
68
|
-
"prettier": "^
|
|
69
|
-
"quasar": "^2.
|
|
70
|
-
"rimraf": "^5.0.
|
|
71
|
-
"typescript": "^5.
|
|
72
|
-
"unplugin-vue-components": "^0.
|
|
73
|
-
"vite": "^4.
|
|
74
|
-
"vue": "^3.
|
|
75
|
-
"vue-router": "^4.
|
|
76
|
-
"vue-tsc": "^1.
|
|
68
|
+
"prettier": "^3.0.0",
|
|
69
|
+
"quasar": "^2.12.3",
|
|
70
|
+
"rimraf": "^5.0.1",
|
|
71
|
+
"typescript": "^5.1.6",
|
|
72
|
+
"unplugin-vue-components": "^0.25.1",
|
|
73
|
+
"vite": "^4.4.8",
|
|
74
|
+
"vue": "^3.3.4",
|
|
75
|
+
"vue-router": "^4.2.4",
|
|
76
|
+
"vue-tsc": "^1.8.8"
|
|
77
77
|
},
|
|
78
78
|
"scripts": {
|
|
79
79
|
"build:plugin": "vite build",
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
:rules="validations"
|
|
5
5
|
:model-value="modelValue"
|
|
6
6
|
:label="`${label}${required ? '*' : ''}`"
|
|
7
|
+
placeholder="YYYY/MM/DD"
|
|
7
8
|
mask="date"
|
|
8
9
|
class="q-pr-md"
|
|
9
10
|
@update:model-value="$emit('update:modelValue', $event)"
|
|
@@ -57,11 +58,17 @@ const lang = useLang()
|
|
|
57
58
|
|
|
58
59
|
const $q = useQuasar()
|
|
59
60
|
if (lang.value.isoName !== $q.lang.isoName) loadLang($q.lang.isoName)
|
|
60
|
-
watch($q.lang, (
|
|
61
|
+
watch($q.lang, () => {
|
|
61
62
|
loadLang($q.lang.isoName)
|
|
62
63
|
})
|
|
63
64
|
|
|
64
|
-
const validations = ref<((val: string) => boolean | string)[]>([
|
|
65
|
+
const validations = ref<((val: string) => boolean | string)[]>([
|
|
66
|
+
(v) => {
|
|
67
|
+
if (v !== null)
|
|
68
|
+
return /^\d{4}\/(0?[1-9]|1[012])\/(0?[1-9]|[12][0-9]|3[01])$/.test(v)
|
|
69
|
+
return true
|
|
70
|
+
}
|
|
71
|
+
])
|
|
65
72
|
|
|
66
73
|
if (props.required)
|
|
67
74
|
validations.value.push(
|
|
@@ -19,22 +19,19 @@ export default {
|
|
|
19
19
|
</script>
|
|
20
20
|
|
|
21
21
|
<script setup lang="ts">
|
|
22
|
-
import { ref
|
|
23
|
-
import {
|
|
24
|
-
import { useLang, loadLang } from './lang'
|
|
22
|
+
import { ref } from 'vue'
|
|
23
|
+
import { useLang } from './lang'
|
|
25
24
|
|
|
26
25
|
export interface Props {
|
|
27
26
|
subject: string
|
|
28
27
|
body: string
|
|
29
28
|
}
|
|
30
|
-
|
|
31
|
-
const attrs = useAttrs()
|
|
29
|
+
defineProps<Props>()
|
|
32
30
|
const emit = defineEmits<{
|
|
33
31
|
(e: 'update:subject', value: string | number | null): void
|
|
34
32
|
(e: 'update:body', value: string | null): void
|
|
35
33
|
}>()
|
|
36
34
|
|
|
37
|
-
const $q = useQuasar()
|
|
38
35
|
const lang = useLang()
|
|
39
36
|
|
|
40
37
|
const variables = ref({
|
package/src/ui/form/FormItem.vue
CHANGED
|
@@ -19,6 +19,7 @@ import { useLang, loadLang } from './lang'
|
|
|
19
19
|
export type Gender = 'male' | 'female' | 'other' | null
|
|
20
20
|
export interface Props {
|
|
21
21
|
modelValue: Gender | null
|
|
22
|
+
disableOther?: boolean
|
|
22
23
|
required?: boolean
|
|
23
24
|
}
|
|
24
25
|
const props = defineProps<Props>()
|
|
@@ -29,7 +30,7 @@ const lang = useLang()
|
|
|
29
30
|
|
|
30
31
|
const $q = useQuasar()
|
|
31
32
|
if (lang.value.isoName !== $q.lang.isoName) await loadLang($q.lang.isoName)
|
|
32
|
-
watch($q.lang, (
|
|
33
|
+
watch($q.lang, () => {
|
|
33
34
|
loadLang($q.lang.isoName)
|
|
34
35
|
})
|
|
35
36
|
|
|
@@ -41,13 +42,16 @@ const genderOptions = ref([
|
|
|
41
42
|
{
|
|
42
43
|
label: lang.value.gender.female,
|
|
43
44
|
value: 'female'
|
|
44
|
-
},
|
|
45
|
-
{
|
|
46
|
-
label: lang.value.gender.other,
|
|
47
|
-
value: 'other'
|
|
48
45
|
}
|
|
49
46
|
])
|
|
50
47
|
|
|
48
|
+
if (!props.disableOther) {
|
|
49
|
+
genderOptions.value.push({
|
|
50
|
+
label: lang.value.gender.other,
|
|
51
|
+
value: 'other'
|
|
52
|
+
})
|
|
53
|
+
}
|
|
54
|
+
|
|
51
55
|
const validations = ref<ValidationRule[]>([])
|
|
52
56
|
|
|
53
57
|
if (props.required)
|
|
@@ -52,11 +52,11 @@ const attrs = useAttrs()
|
|
|
52
52
|
// const langList = import.meta.glob('../../../node_modules/quasar/lang/*.mjs')
|
|
53
53
|
|
|
54
54
|
const nlRef = ref<typeof nl>()
|
|
55
|
-
const nlCountry = computed(() => nlRef.value?.variables.country)
|
|
55
|
+
// const nlCountry = computed(() => nlRef.value?.variables.country)
|
|
56
56
|
const nlLanguage = computed(() => nlRef.value?.variables.language)
|
|
57
57
|
|
|
58
58
|
const enUsRef = ref<typeof enUs>()
|
|
59
|
-
const enUsCountry = computed(() => enUsRef.value?.variables.country)
|
|
59
|
+
// const enUsCountry = computed(() => enUsRef.value?.variables.country)
|
|
60
60
|
const enUsLanguage = computed(() => enUsRef.value?.variables.language)
|
|
61
61
|
|
|
62
62
|
const languageOptions = [
|
|
@@ -70,7 +70,7 @@ const emit = defineEmits<{
|
|
|
70
70
|
data,
|
|
71
71
|
done
|
|
72
72
|
}: {
|
|
73
|
-
data?:
|
|
73
|
+
data?: unknown
|
|
74
74
|
done: (success?: boolean) => void
|
|
75
75
|
}
|
|
76
76
|
): void
|
|
@@ -80,7 +80,7 @@ const emit = defineEmits<{
|
|
|
80
80
|
data,
|
|
81
81
|
done
|
|
82
82
|
}: {
|
|
83
|
-
data?:
|
|
83
|
+
data?: unknown
|
|
84
84
|
done: (success?: boolean) => void
|
|
85
85
|
}
|
|
86
86
|
): void
|
|
@@ -44,9 +44,8 @@ import QSubmitButton from './QSubmitButton.vue'
|
|
|
44
44
|
export interface Props {
|
|
45
45
|
display?: boolean
|
|
46
46
|
}
|
|
47
|
-
|
|
47
|
+
defineProps<Props>()
|
|
48
48
|
// const attrs = useAttrs();
|
|
49
|
-
const modelValue = ref(false)
|
|
50
49
|
const emit = defineEmits<{
|
|
51
50
|
(
|
|
52
51
|
e: 'submit',
|