@hostlink/nuxt-light 0.0.33 → 0.0.34

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,5 +1,5 @@
1
1
  {
2
2
  "name": "light",
3
3
  "configKey": "light",
4
- "version": "0.0.33"
4
+ "version": "0.0.34"
5
5
  }
package/dist/module.mjs CHANGED
@@ -35,6 +35,7 @@ const module = defineNuxtModule({
35
35
  path: resolver.resolve("./runtime/components")
36
36
  });
37
37
  const from = resolver.resolve("./runtime/lib");
38
+ const index = resolver.resolve("./runtime/index");
38
39
  addImports([
39
40
  { name: "addObject", from },
40
41
  { name: "f", from },
@@ -51,7 +52,8 @@ const module = defineNuxtModule({
51
52
  { name: "removeObject", from },
52
53
  { name: "t", from },
53
54
  { name: "updateObject", from },
54
- { name: "listObject", from }
55
+ { name: "listObject", from },
56
+ { name: "useLight", from: index }
55
57
  ]);
56
58
  addPlugin({
57
59
  src: resolver.resolve("./runtime/plugin"),
@@ -0,0 +1,32 @@
1
+
2
+ <script setup>
3
+ import { ref } from "vue"
4
+ const props = defineProps({
5
+ title: {
6
+ type: String,
7
+ default: ""
8
+ },
9
+ value: {
10
+ },
11
+ })
12
+
13
+ //check valu is a number?
14
+ const localValue = ref(props.value)
15
+ if (typeof props.value === "number") {
16
+ //format number, 268500 => 268,500
17
+ localValue.value = props.value.toLocaleString()
18
+ }
19
+
20
+
21
+ </script>
22
+ <template>
23
+ <div>
24
+ <div class="row">
25
+ {{ title }}
26
+ </div>
27
+ <div class="text-h5 row">
28
+ {{ localValue }}
29
+ </div>
30
+
31
+ </div>
32
+ </template>
@@ -1,7 +1,7 @@
1
1
  declare const _default: ({
2
2
  name: string;
3
3
  path: string;
4
- component: typeof index;
4
+ component: typeof logout;
5
5
  children?: undefined;
6
6
  } | {
7
7
  path: string;
@@ -14,6 +14,6 @@ declare const _default: ({
14
14
  name?: undefined;
15
15
  })[];
16
16
  export default _default;
17
- declare function index(): Promise<any>;
17
+ declare function logout(): Promise<any>;
18
18
  declare function User_setting(): Promise<any>;
19
19
  declare function User_setting_index(): Promise<any>;
@@ -1,6 +1,3 @@
1
- function index() {
2
- return import(/* webpackChunkName: "index" */ './pages/index.vue')
3
- }
4
1
  function logout() {
5
2
  return import(/* webpackChunkName: "logout" */ './pages/logout.vue')
6
3
  }
@@ -171,11 +168,6 @@ function User__user_id_view() {
171
168
  }
172
169
 
173
170
  export default [
174
- {
175
- name: 'index',
176
- path: '/',
177
- component: index,
178
- },
179
171
  {
180
172
  name: 'logout',
181
173
  path: '/logout',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hostlink/nuxt-light",
3
- "version": "0.0.33",
3
+ "version": "0.0.34",
4
4
  "description": "HostLink Nuxt Light Framework",
5
5
  "repository": "@hostlink/nuxt-light",
6
6
  "license": "MIT",
@@ -1,24 +0,0 @@
1
- <script setup>
2
- import { q } from '../'
3
- import { reactive } from 'vue'
4
- const my = await q("my", ["name", "first_name", "last_name", "email"]);
5
- import { useI18n } from 'vue-i18n';
6
- const i18n = useI18n();
7
-
8
- const obj = reactive({
9
- title: "Hello"
10
- })
11
-
12
- </script>
13
- <template>
14
- <q-page padding>
15
- <l-card>
16
- <q-card-section>
17
- Hello
18
-
19
- {{ i18n.locale }}
20
- {{ my }}
21
- </q-card-section>
22
- </l-card>
23
- </q-page>
24
- </template>