@hostlink/nuxt-light 1.39.0 → 1.40.0

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.39.0",
4
+ "version": "1.40.0",
5
5
  "builder": {
6
6
  "@nuxt/module-builder": "1.0.1",
7
7
  "unbuild": "3.5.0"
package/dist/module.mjs CHANGED
@@ -303,7 +303,8 @@ const module = defineNuxtModule({
303
303
  components: {
304
304
  defaults: {
305
305
  QInput: {
306
- stackLabel: true
306
+ stackLabel: true,
307
+ outlined: true
307
308
  },
308
309
  QSelect: {
309
310
  stackLabel: true
@@ -1 +1 @@
1
- body{font-family:Noto Sans,Noto Sans HK,Noto Sans TC,-apple-system,Helvetica Neue,Helvetica,Arial,sans-serif}.q-card__actions .q-btn--rectangle{padding:4px 16px}.q-table--dense .q-table td,.q-table--dense .q-table td:first-child,.q-table--dense .q-table th,.q-table--dense .q-table th:first-child{padding:2px 4px}.q-tab-panel{padding:8px}::-webkit-scrollbar{background:transparent;height:12px;overflow:visible;width:14px;z-index:12}::-webkit-scrollbar-thumb{background-clip:padding-box;background-color:#c1c1c1;border:4px solid transparent;border-radius:10px;margin:4px;min-height:32px;min-width:32px;-webkit-transition:background-color .32s ease-in-out;transition:background-color .32s ease-in-out;width:10px;z-index:12}::-webkit-scrollbar-thumb:hover{background:#c1c1c1}
1
+ body{font-family:Noto Sans,Noto Sans HK,Noto Sans TC,-apple-system,Helvetica Neue,Helvetica,Arial,sans-serif}.q-field--dense .q-field__before,.q-field--dense .q-field__prepend{padding-right:5px}.q-field--dense .q-field__after,.q-field--dense .q-field__append{padding-left:5px}.q-field--outlined .q-field__control{padding:0 10px}.q-field__before,.q-field__prepend{padding-right:10px}.q-field--filled .q-field__control{padding:0 10px}.q-card__actions .q-btn--rectangle{padding:4px 16px}.q-table--dense .q-table td,.q-table--dense .q-table td:first-child,.q-table--dense .q-table th,.q-table--dense .q-table th:first-child{padding:2px 4px}.q-tab-panel{padding:8px}::-webkit-scrollbar{background:transparent;height:12px;overflow:visible;width:14px;z-index:12}::-webkit-scrollbar-thumb{background-clip:padding-box;background-color:#c1c1c1;border:4px solid transparent;border-radius:10px;margin:4px;min-height:32px;min-width:32px;-webkit-transition:background-color .32s ease-in-out;transition:background-color .32s ease-in-out;width:10px;z-index:12}::-webkit-scrollbar-thumb:hover{background:#c1c1c1}
@@ -23,7 +23,10 @@ const onSubmit = async (d) => {
23
23
 
24
24
  <form-kit label="Password based" type="l-checkbox" name="authentication_password_based" true-value="1"
25
25
  false-value="0" />
26
- <q-separator />
26
+
27
+ <div class="col-12">
28
+ <q-separator />
29
+ </div>
27
30
 
28
31
  <form-kit label="Google Client ID" type="l-input" name="authentication_google_client_id" />
29
32
 
@@ -14,7 +14,7 @@ const onSubmit = async (d) => {
14
14
  </script>
15
15
 
16
16
  <template>
17
- <form-kit type="l-form" :value="{
17
+ <form-kit :bordered="false" type="l-form" :value="{
18
18
  forget_password_enabled: processedEnabled,
19
19
  forget_password_subject: processedSubject,
20
20
  forget_password_template: processedTemplate
@@ -7,8 +7,9 @@ defineProps({
7
7
 
8
8
  <template>
9
9
  <form-kit type="l-form" :bordered="false" :value="$props" @submit="$emit('submit', $event)">
10
- <l-field :label="$t('File Manager')" stack-label :color="$light.color" hide-bottom-space>
10
+ <l-field :label="$t('File Manager')" stack-label :color="$light.color" hide-bottom-space class="col-6">
11
11
  <form-kit type="l-checkbox" label="Show" name="file_manager" true-value="1" false-value="0" />
12
12
  </l-field>
13
+
13
14
  </form-kit>
14
15
  </template>
@@ -4,6 +4,7 @@ import { useLight, watch } from "#imports";
4
4
  import { useQuasar } from "quasar";
5
5
  import { q } from "#imports";
6
6
  import { useRoute } from "vue-router";
7
+ import "../assets/main.css";
7
8
  const route = useRoute();
8
9
  const light = useLight();
9
10
  const quasar = useQuasar();
@@ -81,11 +81,8 @@ const onSubmit = (e) => {
81
81
  <template>
82
82
  <q-form ref="form" @submit="onSubmit">
83
83
  <l-card :bordered="bordered">
84
- <q-card-section>
85
- <div :class="`q-gutter-${gutter}`">
86
- <slot></slot>
87
- </div>
88
-
84
+ <q-card-section class="row q-col-gutter-md">
85
+ <slot></slot>
89
86
  </q-card-section>
90
87
 
91
88
  <q-card-actions align="right">
@@ -1,5 +1,5 @@
1
1
  <script setup>
2
- import { computed, ref } from "vue";
2
+ import { computed, ref, useAttrs } from "vue";
3
3
  import { useI18n } from "vue-i18n";
4
4
  import tc2sc from "../composables/tc2sc";
5
5
  const { t } = useI18n();
@@ -136,10 +136,17 @@ const localShowPassword = computed(() => {
136
136
  const onClickTc2Sc = () => {
137
137
  modelValue.value = tc2sc(modelValue.value ?? "");
138
138
  };
139
+ const attrs = useAttrs();
140
+ const localClass = computed(() => {
141
+ if (attrs.class) {
142
+ return attrs.class;
143
+ }
144
+ return "col-12";
145
+ });
139
146
  </script>
140
147
 
141
148
  <template>
142
- <q-input v-bind="$light.getInputProps($props)" :rules="new_rules" :type="localType">
149
+ <q-input v-bind="$light.getInputProps($props)" :rules="new_rules" :type="localType" :class="localClass">
143
150
  <template v-if="translate" #prepend>
144
151
  <q-btn icon="sym_o_translate" flat dense rounded>
145
152
  <q-menu dense>
@@ -1,5 +1,5 @@
1
1
  <script setup>
2
- import { ref } from "vue";
2
+ import { ref, useAttrs, computed } from "vue";
3
3
  const props = defineProps({
4
4
  name: { type: null, required: false },
5
5
  virtualScrollHorizontal: { type: Boolean, required: false, skipCheck: true },
@@ -150,8 +150,15 @@ const filterFn = (val, update, abort) => {
150
150
  });
151
151
  });
152
152
  };
153
+ const attrs = useAttrs();
154
+ const localClass = computed(() => {
155
+ if (attrs.class) {
156
+ return attrs.class;
157
+ }
158
+ return "col-12";
159
+ });
153
160
  </script>
154
161
 
155
162
  <template>
156
- <q-select v-bind="$light.getInputProps($props)" :options="select_options" @filter="filterFn" />
163
+ <q-select v-bind="$light.getInputProps($props)" :options="select_options" @filter="filterFn" :class="localClass" />
157
164
  </template>
@@ -77,10 +77,8 @@ const isNoDirtyCheck = computed(() => {
77
77
  <template>
78
78
  <form v-bind="context.attrs">
79
79
  <l-card :bordered="bordered">
80
- <q-card-section>
81
- <div :class="`q-gutter-${gutter}`">
82
- <slot v-bind="context"></slot>
83
- </div>
80
+ <q-card-section class="row q-col-gutter-md">
81
+ <slot v-bind="context"></slot>
84
82
  </q-card-section>
85
83
 
86
84
  <q-card-actions align="right" v-if="context.actions">
@@ -24,9 +24,9 @@ const onSave = async () => {
24
24
 
25
25
  <template>
26
26
  <l-page>
27
- <l-form @save="onSave">
27
+ <l-form @submit="onSave">
28
28
 
29
- <l-input label="Permission name" v-model="obj.value" required></l-input>
29
+ <l-input label="Permission name" v-model="obj.value" required class="col-12"></l-input>
30
30
 
31
31
  <l-field label="Roles" stack-label>
32
32
  <q-option-group type="checkbox" :options="roles" v-model="obj.roles" inline :color="$light.color">
@@ -52,7 +52,7 @@ const languages = tt.app.languages.map((lang) => {
52
52
  <l-page>
53
53
 
54
54
  <FormKit type="l-form" :value="obj">
55
- <l-row>
55
+ <l-row class="col">
56
56
  <l-col md="6">
57
57
  <FormKit type="l-input" label="Username" name="username" validation="required" />
58
58
  <FormKit type="l-input" label="Password" name="password" :validation="system.passwordPolicy"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hostlink/nuxt-light",
3
- "version": "1.39.0",
3
+ "version": "1.40.0",
4
4
  "description": "HostLink Nuxt Light Framework",
5
5
  "repository": {
6
6
  "type": "git",