@ftlab/one-vue3 0.3.4 → 0.3.5

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 CHANGED
@@ -7,35 +7,30 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
7
7
 
8
8
  Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
9
9
 
10
- ## [v0.2.16](https://gitlab.ftlapp.cn/ftl/ftlab/one-vue3/compare/v0.2.4...v0.2.16)
10
+ ## [v0.3.5](https://gitlab.ftlapp.cn/ftl/ftlab/one-vue3/compare/v0.2.2...v0.3.5)
11
11
 
12
12
  ### Commits
13
13
 
14
14
  - feat: add date methods [`c41c7a2`](https://gitlab.ftlapp.cn/ftl/ftlab/one-vue3/commit/c41c7a26509d85073c815f87ed3bb03062654985)
15
15
  - feat: multipleChoose component add [`34a1d4d`](https://gitlab.ftlapp.cn/ftl/ftlab/one-vue3/commit/34a1d4dba5979031fb1387a77619843f8c82dc81)
16
16
  - fix: build bug fix [`d49527d`](https://gitlab.ftlapp.cn/ftl/ftlab/one-vue3/commit/d49527d29060ddd1a040a366ca4808e827b5f4df)
17
+ - feat: support iconfont [`5268467`](https://gitlab.ftlapp.cn/ftl/ftlab/one-vue3/commit/526846752ca3de05e7e78a665a7b1c1ff1b40b9f)
18
+ - fix: store bug fix [`bb66736`](https://gitlab.ftlapp.cn/ftl/ftlab/one-vue3/commit/bb6673665c1361ade8765af1e8f49c281d758313)
19
+ - feat: utils support js,add new entry [`5f71427`](https://gitlab.ftlapp.cn/ftl/ftlab/one-vue3/commit/5f7142710f12f1fbd7d7b39d29596e85cc64675b)
17
20
  - feat: remove element-plus origin style [`a0c4fa1`](https://gitlab.ftlapp.cn/ftl/ftlab/one-vue3/commit/a0c4fa1b195c3ee570a093c103ea28a3fbb64ac1)
18
21
  - hotfix: emit changeLanguage [`98f7a12`](https://gitlab.ftlapp.cn/ftl/ftlab/one-vue3/commit/98f7a12b06c16af4aedf4f1bf89442dcf727694c)
22
+ - feat: 时间格式化函数添加时间格式参数 [`653601b`](https://gitlab.ftlapp.cn/ftl/ftlab/one-vue3/commit/653601b3eb9090e1dceb1755b3f6b7a6a134caa3)
23
+ - feat: menu style detail change [`93c3abb`](https://gitlab.ftlapp.cn/ftl/ftlab/one-vue3/commit/93c3abba52a689bf6e0e265e4ad2c4aad38605fd)
19
24
  - fix: fix collapse style error [`54e9525`](https://gitlab.ftlapp.cn/ftl/ftlab/one-vue3/commit/54e9525a99b216a9f7bb1b29ec578a768b49cb93)
25
+ - feat: add type declare [`bd28cc0`](https://gitlab.ftlapp.cn/ftl/ftlab/one-vue3/commit/bd28cc0ab3d91271b5f2af00c85d663b4a868f17)
20
26
  - feat: remove click event [`1cd1e54`](https://gitlab.ftlapp.cn/ftl/ftlab/one-vue3/commit/1cd1e54da9c03fc4ea4a0f3480b33b302d7cf02d)
21
27
  - feat: add click event [`6a63a8a`](https://gitlab.ftlapp.cn/ftl/ftlab/one-vue3/commit/6a63a8ac7c5ca710c6d91765c573af53df439bf4)
22
28
  - charge storage to js [`1d1368d`](https://gitlab.ftlapp.cn/ftl/ftlab/one-vue3/commit/1d1368ddb5d1ce8ecbc5754530b46f705146013f)
23
29
  - fix: remove type declare [`d611d3a`](https://gitlab.ftlapp.cn/ftl/ftlab/one-vue3/commit/d611d3ab302a4426e96f1c1e4e7ae940e427c9a9)
24
30
  - chore: charge ts to js [`e2feead`](https://gitlab.ftlapp.cn/ftl/ftlab/one-vue3/commit/e2feeadc54c45ddab43a8947d38cb1decc76d230)
31
+ - fix: import bug [`892d8dc`](https://gitlab.ftlapp.cn/ftl/ftlab/one-vue3/commit/892d8dcfeebcfd7e643ccf5fc28533c423eafc46)
25
32
  - fix: winter time tz bug [`3f984ee`](https://gitlab.ftlapp.cn/ftl/ftlab/one-vue3/commit/3f984eebce6e6409084439fd0342bbaf883693c1)
26
33
 
27
- ## [v0.2.4](https://gitlab.ftlapp.cn/ftl/ftlab/one-vue3/compare/v0.2.3...v0.2.4) - 2024-01-10
28
-
29
- ### Commits
30
-
31
- - feat: support iconfont [`5268467`](https://gitlab.ftlapp.cn/ftl/ftlab/one-vue3/commit/526846752ca3de05e7e78a665a7b1c1ff1b40b9f)
32
-
33
- ## [v0.2.3](https://gitlab.ftlapp.cn/ftl/ftlab/one-vue3/compare/v0.2.2...v0.2.3) - 2023-12-11
34
-
35
- ### Commits
36
-
37
- - feat: menu style detail change [`93c3abb`](https://gitlab.ftlapp.cn/ftl/ftlab/one-vue3/commit/93c3abba52a689bf6e0e265e4ad2c4aad38605fd)
38
-
39
34
  ## [v0.2.2](https://gitlab.ftlapp.cn/ftl/ftlab/one-vue3/compare/v0.2.1...v0.2.2) - 2023-12-04
40
35
 
41
36
  ### Commits
package/global.d.ts ADDED
@@ -0,0 +1,63 @@
1
+ declare module '@ftlab/one-vue3/utils' {
2
+ import { Dayjs } from 'dayjs';
3
+
4
+ type dateFormat = (date: string | Date | null | undefined, format?: string, defaultStr?: string) => string;
5
+ type dateTransform = (date: string | Date | null | undefined, defaultStr?: string) => Date | string;
6
+ type tzTransform = (date: string | Date | null | undefined, tz: string) => Date | string;
7
+ type dateValidate = (date: any) => boolean;
8
+
9
+ export const TIME_FORMAT: string;
10
+
11
+ export const isValidDate: dateValidate;
12
+
13
+ export const utc_cn: dateFormat;
14
+ export const utc_fr: dateFormat;
15
+
16
+ export const local_utc_date: dateTransform;
17
+ export const local_tz_date: tzTransform;
18
+ export const local_cn_date: dateTransform;
19
+ export const local_fr_date: dateTransform;
20
+
21
+ export const dayjs: typeof import('dayjs');
22
+
23
+ export { dateFormat, dateTransform, tzTransform, dateValidate };
24
+ }
25
+
26
+ declare module '@ftlab/one-vue3/store' {
27
+ import { Pinia, StoreDefinition } from 'pinia';
28
+
29
+ const store: Pinia;
30
+ export default store;
31
+
32
+ export const useAuthStore: StoreDefinition<
33
+ 'auth',
34
+ {
35
+ userInfo: Record<string, any>;
36
+ username: string;
37
+ owner: string;
38
+ roles: any[];
39
+ menus: any[];
40
+ resources: any[];
41
+ },
42
+ {},
43
+ {
44
+ setInfo(authInfo: Record<string, any>): void;
45
+ setMenu(menus: any[]): void;
46
+ setResources(resources: any[]): void;
47
+ logout(): void;
48
+ }
49
+ >;
50
+
51
+ export const useLangStore: StoreDefinition<
52
+ 'lang',
53
+ {
54
+ language: string;
55
+ },
56
+ {},
57
+ {
58
+ setLanguage(lang: string): void;
59
+ }
60
+ >;
61
+ }
62
+
63
+ declare module '@ftlab/one-vue3' {}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ftlab/one-vue3",
3
- "version": "0.3.4",
3
+ "version": "0.3.5",
4
4
  "description": "One for Apps based on Element UI",
5
5
  "main": "dist/ftlOne.js",
6
6
  "exports": {
@@ -24,6 +24,7 @@
24
24
  }
25
25
  },
26
26
  "type": "module",
27
+ "types": "global.d.ts",
27
28
  "scripts": {
28
29
  "serve": "vite --host",
29
30
  "push": "npm publish --access=public",