@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.
- package/CHANGELOG.md +7 -0
- package/dist/authentication.js +70 -41
- package/dist/form.js +9 -5
- package/dist/general.js +138 -31
- package/dist/types/ui/authentication/AccountsTable.vue.d.ts +5 -0
- package/dist/types/ui/authentication/ConsentList.vue.d.ts +3 -0
- package/dist/types/ui/authentication/LoginForm.vue.d.ts +4 -0
- package/dist/types/ui/authentication/PasswordChangeForm.vue.d.ts +8 -0
- package/dist/types/ui/authentication/RegisterForm.vue.d.ts +8 -0
- package/dist/types/ui/authentication/UserMenuButton.vue.d.ts +3 -0
- package/dist/types/ui/form/DateInput.vue.d.ts +8 -0
- package/dist/types/ui/general/QLanguageSelectBtn.vue.d.ts +11 -0
- package/dist/types/ui/general/ResourcePage.vue.d.ts +8 -0
- package/dist/types/ui/general/ResponsiveDialog.vue.d.ts +6 -2
- package/dist/types/ui/general/index.d.ts +1 -0
- package/package.json +1 -1
- package/src/ui/authentication/AccountsTable.vue +18 -9
- package/src/ui/authentication/ConsentList.vue +13 -18
- package/src/ui/authentication/LoginForm.vue +12 -3
- package/src/ui/authentication/PasswordChangeForm.vue +11 -3
- package/src/ui/authentication/RegisterForm.vue +11 -3
- package/src/ui/authentication/UserMenuButton.vue +9 -3
- package/src/ui/form/DateInput.vue +11 -3
- package/src/ui/general/QLanguageSelect.vue +1 -0
- package/src/ui/general/QLanguageSelectBtn.vue +99 -0
- package/src/ui/general/ResourcePage.vue +13 -5
- package/src/ui/general/ResponsiveDialog.vue +10 -3
- package/src/ui/general/index.ts +1 -0
- package/vite.config.ts +0 -70
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
round
|
|
19
19
|
size="lg"
|
|
20
20
|
dense
|
|
21
|
-
icon="add"
|
|
21
|
+
:icon="icons.add"
|
|
22
22
|
class="q-mr-sm bg-primary text-white"
|
|
23
23
|
@click="create"
|
|
24
24
|
/>
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
round
|
|
31
31
|
size="lg"
|
|
32
32
|
dense
|
|
33
|
-
icon="edit"
|
|
33
|
+
:icon="icons.edit"
|
|
34
34
|
class="q-mr-sm bg-primary text-white"
|
|
35
35
|
@click="update"
|
|
36
36
|
/>
|
|
@@ -44,7 +44,7 @@
|
|
|
44
44
|
v-if="type === 'create'"
|
|
45
45
|
:disable="disabled"
|
|
46
46
|
:label="lang.add"
|
|
47
|
-
icon="add"
|
|
47
|
+
:icon="icons.add"
|
|
48
48
|
outline
|
|
49
49
|
@click="create"
|
|
50
50
|
/>
|
|
@@ -52,7 +52,7 @@
|
|
|
52
52
|
v-else-if="type === 'update'"
|
|
53
53
|
:disable="disabled"
|
|
54
54
|
:label="lang.edit"
|
|
55
|
-
icon="edit"
|
|
55
|
+
:icon="icons.edit"
|
|
56
56
|
outline
|
|
57
57
|
@click="update"
|
|
58
58
|
/>
|
|
@@ -80,12 +80,20 @@ export interface Props {
|
|
|
80
80
|
disabled?: boolean
|
|
81
81
|
topBarFab?: boolean
|
|
82
82
|
topBarShrink?: boolean
|
|
83
|
+
icons?: {
|
|
84
|
+
add: string
|
|
85
|
+
edit: string
|
|
86
|
+
}
|
|
83
87
|
}
|
|
84
88
|
const props = withDefaults(defineProps<Props>(), {
|
|
85
89
|
type: undefined,
|
|
86
90
|
disabled: false,
|
|
87
91
|
topBarFab: false,
|
|
88
|
-
topBarShrink: true
|
|
92
|
+
topBarShrink: true,
|
|
93
|
+
icons: () => ({
|
|
94
|
+
add: 'add',
|
|
95
|
+
edit: 'edit'
|
|
96
|
+
})
|
|
89
97
|
})
|
|
90
98
|
|
|
91
99
|
const emit = defineEmits<{
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
>
|
|
9
9
|
<q-header class="bg-primary">
|
|
10
10
|
<q-toolbar>
|
|
11
|
-
<q-btn :icon="
|
|
11
|
+
<q-btn :icon="icons.close" flat round dense @click="close" />
|
|
12
12
|
<q-toolbar-title>
|
|
13
13
|
<slot name="title" />
|
|
14
14
|
</q-toolbar-title>
|
|
@@ -45,10 +45,17 @@ import QSubmitButton from './QSubmitButton.vue'
|
|
|
45
45
|
export interface Props {
|
|
46
46
|
display?: boolean
|
|
47
47
|
buttonType?: 'submit' | 'send'
|
|
48
|
-
closeIcon?: string
|
|
49
48
|
padding?: boolean
|
|
49
|
+
icons?: {
|
|
50
|
+
close: string
|
|
51
|
+
}
|
|
50
52
|
}
|
|
51
|
-
withDefaults(defineProps<Props>(), {
|
|
53
|
+
withDefaults(defineProps<Props>(), {
|
|
54
|
+
buttonType: 'submit',
|
|
55
|
+
icons: () => ({
|
|
56
|
+
close: 'close'
|
|
57
|
+
})
|
|
58
|
+
})
|
|
52
59
|
// const attrs = useAttrs();
|
|
53
60
|
const emit = defineEmits<{
|
|
54
61
|
(
|
package/src/ui/general/index.ts
CHANGED
|
@@ -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/vite.config.ts
CHANGED
|
@@ -3,76 +3,6 @@ import vue from '@vitejs/plugin-vue'
|
|
|
3
3
|
import Components from 'unplugin-vue-components/vite'
|
|
4
4
|
import { QuasarResolver } from 'unplugin-vue-components/resolvers'
|
|
5
5
|
import { FlagIcon, Icon } from './src/virtualModules.js'
|
|
6
|
-
// export const FlagIcon = (locale) => `
|
|
7
|
-
// import { computed, ref, watch, h } from 'vue'
|
|
8
|
-
// import { QuasarLanguageCodes, useQuasar, QIcon } from 'quasar'
|
|
9
|
-
// import { useLang, loadLang } from '${
|
|
10
|
-
// new URL(`./src/ui/flags/lang`, import.meta.url).pathname
|
|
11
|
-
// }'
|
|
12
|
-
// import icon from '${
|
|
13
|
-
// new URL(`./src/ui/flags/assets/${locale}.svg`, import.meta.url).pathname
|
|
14
|
-
// }'
|
|
15
|
-
// export default {
|
|
16
|
-
// setup(props, context) {
|
|
17
|
-
// const $q = useQuasar()
|
|
18
|
-
// const lang = useLang()
|
|
19
|
-
// if (lang.value.isoName !== $q.lang.isoName) loadLang($q.lang.isoName)
|
|
20
|
-
// watch($q.lang, (val) => {
|
|
21
|
-
// loadLang($q.lang.isoName)
|
|
22
|
-
// })
|
|
23
|
-
|
|
24
|
-
// const country = computed(
|
|
25
|
-
// () => lang.value.countries['${locale}']
|
|
26
|
-
// )
|
|
27
|
-
// // @ts-ignore
|
|
28
|
-
// const language = computed(() => lang.value.languages['${locale}'])
|
|
29
|
-
// const variables = ref({
|
|
30
|
-
// country,
|
|
31
|
-
// language
|
|
32
|
-
// // header: lang.value.some.nested.prop
|
|
33
|
-
// })
|
|
34
|
-
// const functions = ref({
|
|
35
|
-
// // submit
|
|
36
|
-
// })
|
|
37
|
-
|
|
38
|
-
// context.expose({
|
|
39
|
-
// variables,
|
|
40
|
-
// functions
|
|
41
|
-
// })
|
|
42
|
-
|
|
43
|
-
// // return the render function
|
|
44
|
-
// return () => h(QIcon, { name: \`img:\${icon}\` })
|
|
45
|
-
// }}
|
|
46
|
-
// `
|
|
47
|
-
|
|
48
|
-
// export const Icon = (icon) => `
|
|
49
|
-
// import { computed, ref, watch, h } from 'vue'
|
|
50
|
-
// import { QuasarLanguageCodes, useQuasar, QIcon } from 'quasar'
|
|
51
|
-
// import icon from '${
|
|
52
|
-
// new URL(`./src/ui/icons/assets/${icon}.svg`, import.meta.url).pathname
|
|
53
|
-
// }'
|
|
54
|
-
// import icons from '${
|
|
55
|
-
// new URL(`./src/ui/icons/icons.ts`, import.meta.url).pathname
|
|
56
|
-
// }'
|
|
57
|
-
// export default {
|
|
58
|
-
// setup(props, context) {
|
|
59
|
-
// const $q = useQuasar()
|
|
60
|
-
|
|
61
|
-
// const variables = ref(icons['${icon}'])
|
|
62
|
-
|
|
63
|
-
// const functions = ref({
|
|
64
|
-
// // submit
|
|
65
|
-
// })
|
|
66
|
-
|
|
67
|
-
// context.expose({
|
|
68
|
-
// variables,
|
|
69
|
-
// functions
|
|
70
|
-
// })
|
|
71
|
-
|
|
72
|
-
// // return the render function
|
|
73
|
-
// return () => h(QIcon, { name: \`img:\${icon}\` })
|
|
74
|
-
// }}
|
|
75
|
-
// `
|
|
76
6
|
|
|
77
7
|
export const moduleTransformPlugin: Plugin = {
|
|
78
8
|
name: 'module-tranform-plugin',
|