@flyto/farco 1.2.1 → 1.4.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.
Files changed (166) hide show
  1. package/dist/chunk-0b1102a0.js +95 -0
  2. package/dist/chunk-0d0f8483.js +6 -0
  3. package/dist/chunk-0ec0668f.js +42 -0
  4. package/dist/chunk-0f50b26a.js +153 -0
  5. package/dist/chunk-17a233d7.js +1 -0
  6. package/dist/chunk-18dd07f2.js +71 -0
  7. package/dist/chunk-28ba1e67.js +4525 -0
  8. package/dist/chunk-2d4cc9ab.js +287 -0
  9. package/dist/chunk-32aa5901.js +1 -0
  10. package/dist/chunk-3659754f.js +103 -0
  11. package/dist/chunk-3e27c862.js +38 -0
  12. package/dist/chunk-3e3782aa.js +1 -0
  13. package/dist/chunk-451afd44.js +58 -0
  14. package/dist/chunk-45dbb8f9.js +1 -0
  15. package/dist/chunk-540a3872.js +1 -0
  16. package/dist/chunk-5672685f.js +2 -0
  17. package/dist/chunk-592857c5.js +1 -0
  18. package/dist/chunk-5f89350b.js +2 -0
  19. package/dist/chunk-6c665483.js +4 -0
  20. package/dist/chunk-7779a34c.js +169 -0
  21. package/dist/chunk-7e78427e.js +1 -0
  22. package/dist/chunk-7f0e9b41.js +1 -0
  23. package/dist/chunk-82468a2e.js +1 -0
  24. package/dist/chunk-867494bd.js +99 -0
  25. package/dist/chunk-8a4bafe4.js +135 -0
  26. package/dist/chunk-912642ce.js +36 -0
  27. package/dist/chunk-995c23b4.js +85 -0
  28. package/dist/chunk-a016ffab.js +1 -0
  29. package/dist/chunk-a1e9227b.js +1 -0
  30. package/dist/chunk-a67d2308.js +1 -0
  31. package/dist/chunk-abb01801.js +955 -0
  32. package/dist/chunk-b2838051.js +42 -0
  33. package/dist/chunk-c4c93c86.js +1 -0
  34. package/dist/chunk-c9e8fc0f.js +5 -0
  35. package/dist/chunk-db179b28.js +82 -0
  36. package/dist/chunk-dc6689c4.js +34 -0
  37. package/dist/chunk-e7fc446a.js +29 -0
  38. package/dist/chunk-ed8bf4fb.js +12607 -0
  39. package/dist/chunk-f363e104.js +1 -0
  40. package/dist/chunk-fe45f9f8.js +1 -0
  41. package/dist/fbutton.cjs.js +1 -0
  42. package/dist/fbutton.es.js +9 -0
  43. package/dist/fcheckbox.cjs.js +1 -0
  44. package/dist/fcheckbox.es.js +8 -0
  45. package/dist/fdate.cjs.js +1 -0
  46. package/dist/fdate.es.js +8 -0
  47. package/dist/fform-item.cjs.js +1 -0
  48. package/dist/fform-item.es.js +26 -0
  49. package/dist/fform.cjs.js +1 -0
  50. package/dist/fform.es.js +24 -0
  51. package/dist/ficon.cjs.js +1 -0
  52. package/dist/ficon.es.js +9 -0
  53. package/dist/finput.cjs.js +1 -0
  54. package/dist/finput.es.js +9 -0
  55. package/dist/flink.cjs.js +1 -0
  56. package/dist/flink.es.js +9 -0
  57. package/dist/fml-input.cjs.js +1 -0
  58. package/dist/fml-input.es.js +11 -0
  59. package/dist/fpop-choice.cjs.js +1 -0
  60. package/dist/fpop-choice.es.js +26 -0
  61. package/dist/fquery-list.cjs.js +1 -0
  62. package/dist/fquery-list.es.js +24 -0
  63. package/dist/fradio.cjs.js +1 -0
  64. package/dist/fradio.es.js +8 -0
  65. package/dist/frange.cjs.js +1 -0
  66. package/dist/frange.es.js +10 -0
  67. package/dist/fsearch.cjs.js +1 -0
  68. package/dist/fsearch.es.js +24 -0
  69. package/dist/fselect.cjs.js +1 -0
  70. package/dist/fselect.es.js +12 -0
  71. package/dist/fskeleton.cjs.js +1 -0
  72. package/dist/fskeleton.es.js +8 -0
  73. package/dist/fswitch.cjs.js +1 -0
  74. package/dist/fswitch.es.js +8 -0
  75. package/dist/ftable.cjs.js +1 -0
  76. package/dist/ftable.es.js +13 -0
  77. package/dist/ftext.cjs.js +1 -0
  78. package/dist/ftext.es.js +12 -0
  79. package/dist/ftextarea.cjs.js +1 -0
  80. package/dist/ftextarea.es.js +9 -0
  81. package/dist/index.cjs.js +1 -0
  82. package/dist/index.es.js +175 -19505
  83. package/dist/index.umd.js +25 -25
  84. package/dist/keys.cjs.js +1 -0
  85. package/dist/keys.es.js +9 -0
  86. package/dist/style.css +1 -1
  87. package/dist/types/components/fbutton/fbutton.d.ts +35 -35
  88. package/dist/types/components/fbutton/fbutton.vue.d.ts +35 -33
  89. package/dist/types/components/fbutton/index.d.ts +4 -4
  90. package/dist/types/components/fcheckbox/constants/index.d.ts +10 -10
  91. package/dist/types/components/fcheckbox/fcheckbox.d.ts +41 -41
  92. package/dist/types/components/fcheckbox/fcheckbox.vue.d.ts +168 -166
  93. package/dist/types/components/fcheckbox/index.d.ts +4 -4
  94. package/dist/types/components/fdate/fdate.d.ts +67 -67
  95. package/dist/types/components/fdate/fdate.vue.d.ts +47 -45
  96. package/dist/types/components/fdate/index.d.ts +4 -4
  97. package/dist/types/components/fform/fform.d.ts +83 -83
  98. package/dist/types/components/fform/fform.vue.d.ts +124 -122
  99. package/dist/types/components/fform/index.d.ts +4 -4
  100. package/dist/types/components/fform-item/fform-item.d.ts +91 -91
  101. package/dist/types/components/fform-item/fform-item.vue.d.ts +121 -117
  102. package/dist/types/components/fform-item/index.d.ts +4 -4
  103. package/dist/types/components/ficon/ficon.d.ts +44 -44
  104. package/dist/types/components/ficon/ficon.vue.d.ts +63 -59
  105. package/dist/types/components/ficon/index.d.ts +4 -4
  106. package/dist/types/components/finput/finput.d.ts +54 -54
  107. package/dist/types/components/finput/finput.vue.d.ts +87 -83
  108. package/dist/types/components/finput/index.d.ts +4 -4
  109. package/dist/types/components/flink/flink.d.ts +26 -26
  110. package/dist/types/components/flink/flink.vue.d.ts +42 -40
  111. package/dist/types/components/flink/index.d.ts +4 -4
  112. package/dist/types/components/fml-input/fml-input.d.ts +74 -74
  113. package/dist/types/components/fml-input/fml-input.vue.d.ts +601 -622
  114. package/dist/types/components/fml-input/index.d.ts +4 -4
  115. package/dist/types/components/fpop-choice/fpop-choice.d.ts +52 -52
  116. package/dist/types/components/fpop-choice/fpop-choice.vue.d.ts +884 -891
  117. package/dist/types/components/fpop-choice/index.d.ts +5 -5
  118. package/dist/types/components/fpop-choice/utils/index.d.ts +16 -16
  119. package/dist/types/components/fquery-list/fquery-list.d.ts +133 -133
  120. package/dist/types/components/fquery-list/fquery-list.vue.d.ts +467 -1352
  121. package/dist/types/components/fquery-list/index.d.ts +4 -4
  122. package/dist/types/components/fradio/constants/index.d.ts +8 -8
  123. package/dist/types/components/fradio/fradio.d.ts +48 -48
  124. package/dist/types/components/fradio/fradio.vue.d.ts +176 -174
  125. package/dist/types/components/fradio/index.d.ts +4 -4
  126. package/dist/types/components/frange/frange.d.ts +47 -47
  127. package/dist/types/components/frange/frange.vue.d.ts +92 -90
  128. package/dist/types/components/frange/index.d.ts +4 -4
  129. package/dist/types/components/fsearch/fsearch.d.ts +75 -75
  130. package/dist/types/components/fsearch/fsearch.vue.d.ts +103 -103
  131. package/dist/types/components/fsearch/index.d.ts +4 -4
  132. package/dist/types/components/fselect/constants/index.d.ts +6 -6
  133. package/dist/types/components/fselect/fselect-option.vue.d.ts +25 -25
  134. package/dist/types/components/fselect/fselect.d.ts +120 -120
  135. package/dist/types/components/fselect/fselect.vue.d.ts +184 -182
  136. package/dist/types/components/fselect/index.d.ts +4 -4
  137. package/dist/types/components/fskeleton/fskeleton.d.ts +18 -18
  138. package/dist/types/components/fskeleton/fskeleton.vue.d.ts +17 -15
  139. package/dist/types/components/fskeleton/index.d.ts +4 -4
  140. package/dist/types/components/fswitch/fswitch.d.ts +8 -8
  141. package/dist/types/components/fswitch/fswitch.vue.d.ts +365 -365
  142. package/dist/types/components/fswitch/index.d.ts +4 -4
  143. package/dist/types/components/ftable/constants/index.d.ts +14 -14
  144. package/dist/types/components/ftable/ftable-cols-set.vue.d.ts +6 -6
  145. package/dist/types/components/ftable/ftable-toolbar.vue.d.ts +57 -54
  146. package/dist/types/components/ftable/ftable.d.ts +332 -332
  147. package/dist/types/components/ftable/ftable.vue.d.ts +139 -333
  148. package/dist/types/components/ftable/index.d.ts +4 -4
  149. package/dist/types/components/ftable/utils/index.d.ts +13 -13
  150. package/dist/types/components/ftext/ftext.d.ts +97 -96
  151. package/dist/types/components/ftext/ftext.vue.d.ts +88 -86
  152. package/dist/types/components/ftext/index.d.ts +4 -4
  153. package/dist/types/components/ftextarea/ftextarea.d.ts +32 -32
  154. package/dist/types/components/ftextarea/ftextarea.vue.d.ts +569 -575
  155. package/dist/types/components/ftextarea/index.d.ts +4 -4
  156. package/dist/types/components/index.d.ts +40 -40
  157. package/dist/types/constants/fform.d.ts +8 -8
  158. package/dist/types/constants/global.d.ts +9 -24
  159. package/dist/types/constants/keys.d.ts +14 -0
  160. package/dist/types/env.d.ts +4 -0
  161. package/dist/types/index.d.ts +14 -15
  162. package/dist/types/types/global.d.ts +44 -44
  163. package/dist/types/types/index.d.ts +1 -1
  164. package/dist/types/utils/business-format.d.ts +136 -136
  165. package/dist/types/utils/index.d.ts +4 -4
  166. package/package.json +24 -4
@@ -1,6 +1,6 @@
1
1
  /// <reference path="./components.d.ts" />
2
2
  import { default as FTextarea } from './ftextarea.vue';
3
-
4
- export default FTextarea;
5
- export type FTextareaInstance = InstanceType<typeof FTextarea>;
6
- export * from './ftextarea';
3
+
4
+ export default FTextarea;
5
+ export type FTextareaInstance = InstanceType<typeof FTextarea>;
6
+ export * from './ftextarea';
@@ -1,41 +1,41 @@
1
1
  /// <reference path="./components.d.ts" />
2
- export { default as FForm } from './fform';
3
- export * from './fform';
4
- export { default as FFormItem } from './fform-item';
5
- export * from './fform-item';
6
- export { default as FInput } from './finput';
7
- export * from './finput';
8
- export { default as FSelect } from './fselect';
9
- export * from './fselect';
10
- export { default as FRadio } from './fradio';
11
- export * from './fradio';
12
- export { default as FCheckbox } from './fcheckbox';
13
- export * from './fcheckbox';
14
- export { default as FSwitch } from './fswitch';
15
- export * from './fswitch';
16
- export { default as FDate } from './fdate';
17
- export * from './fdate';
18
- export { default as FRange } from './frange';
19
- export * from './frange';
20
- export { default as FMlInput } from './fml-input';
21
- export * from './fml-input';
22
- export { default as FTextarea } from './ftextarea';
23
- export * from './ftextarea';
24
- export { default as FText } from './ftext';
25
- export * from './ftext';
26
- export { default as FLink } from './flink';
27
- export * from './flink';
28
- export { default as FIcon } from './ficon';
29
- export * from './ficon';
30
- export { default as FButton } from './fbutton';
31
- export * from './fbutton';
32
- export { default as FTable } from './ftable';
33
- export * from './ftable';
34
- export { default as FSkeleton } from './fskeleton';
35
- export * from './fskeleton';
36
- export { default as FQueryList } from './fquery-list';
37
- export * from './fquery-list';
38
- export { default as FPopChoice } from './fpop-choice';
39
- export * from './fpop-choice';
40
- export { default as FSearch } from './fsearch';
41
- export * from './fsearch';
2
+ export { default as FForm } from './fform';
3
+ export * from './fform';
4
+ export { default as FFormItem } from './fform-item';
5
+ export * from './fform-item';
6
+ export { default as FInput } from './finput';
7
+ export * from './finput';
8
+ export { default as FSelect } from './fselect';
9
+ export * from './fselect';
10
+ export { default as FRadio } from './fradio';
11
+ export * from './fradio';
12
+ export { default as FCheckbox } from './fcheckbox';
13
+ export * from './fcheckbox';
14
+ export { default as FSwitch } from './fswitch';
15
+ export * from './fswitch';
16
+ export { default as FDate } from './fdate';
17
+ export * from './fdate';
18
+ export { default as FRange } from './frange';
19
+ export * from './frange';
20
+ export { default as FMlInput } from './fml-input';
21
+ export * from './fml-input';
22
+ export { default as FTextarea } from './ftextarea';
23
+ export * from './ftextarea';
24
+ export { default as FText } from './ftext';
25
+ export * from './ftext';
26
+ export { default as FLink } from './flink';
27
+ export * from './flink';
28
+ export { default as FIcon } from './ficon';
29
+ export * from './ficon';
30
+ export { default as FButton } from './fbutton';
31
+ export * from './fbutton';
32
+ export { default as FTable } from './ftable';
33
+ export * from './ftable';
34
+ export { default as FSkeleton } from './fskeleton';
35
+ export * from './fskeleton';
36
+ export { default as FQueryList } from './fquery-list';
37
+ export * from './fquery-list';
38
+ export { default as FPopChoice } from './fpop-choice';
39
+ export * from './fpop-choice';
40
+ export { default as FSearch } from './fsearch';
41
+ export * from './fsearch';
@@ -1,9 +1,9 @@
1
1
  import { InjectionKey } from 'vue';
2
-
3
- export declare const fformCtxInjectKey: InjectionKey<{
4
- data: Record<string, any>;
5
- }>;
6
- export declare const fformItemCtxInjectKey: InjectionKey<{
7
- prop: string;
8
- label: string;
9
- }>;
2
+
3
+ export declare const fformCtxInjectKey: InjectionKey<{
4
+ data: Record<string, any>;
5
+ }>;
6
+ export declare const fformItemCtxInjectKey: InjectionKey<{
7
+ prop: string;
8
+ label: string;
9
+ }>;
@@ -1,26 +1,11 @@
1
1
  import { Component, InjectionKey } from 'vue';
2
2
  import { Router } from 'vue-router';
3
-
4
- export declare const DEFAULT_REMOTE_DATA_NAME = "data";
5
- export declare const DEFAULT_REMOTE_DATA_NAME_SPLIT = ".";
6
- /** iconfont 图标唯一值 */
7
- export declare const ICONFONT_KEY: InjectionKey<Component<any, any, any, import('vue').ComputedOptions, import('vue').MethodOptions, {}, any>>;
8
- /** Arco 官方图标库 */
9
- export declare const ARCO_ICON_KEY: InjectionKey<Record<string, Component<any, any, any, import('vue').ComputedOptions, import('vue').MethodOptions, {}, any>>>;
10
- /** 全局通用的router实例 */
11
- export declare const ROUTER_KEY: InjectionKey<Router | null>;
12
- /**
13
- * FArco 依赖注入键集合。
14
- *
15
- * 如果不想通过 `app.use(FArco, opts)` 全局注册所有组件,
16
- * 而是按需引入时,需要手动 provide 这些键以确保 FLink / FIcon 正常工作。
17
- */
18
- declare const _default: {
19
- /** 对应 `FInstallOptions.router`,`FLink` SPA 跳转依赖,无需路由时传 `null` */
20
- ROUTER: InjectionKey<Router | null>;
21
- /** 对应 `FInstallOptions.iconfont`,`FIcon` IconFont 图标源,不使用时可传 `null` */
22
- ICONFONT: InjectionKey<Component<any, any, any, import('vue').ComputedOptions, import('vue').MethodOptions, {}, any>>;
23
- /** 对应 `FInstallOptions.arcoIcon`,`FIcon` Arco 图标映射表,不使用时可传 `{}` */
24
- ARCO_ICON: InjectionKey<Record<string, Component<any, any, any, import('vue').ComputedOptions, import('vue').MethodOptions, {}, any>>>;
25
- };
26
- export default _default;
3
+
4
+ export declare const DEFAULT_REMOTE_DATA_NAME = "data";
5
+ export declare const DEFAULT_REMOTE_DATA_NAME_SPLIT = ".";
6
+ /** iconfont 图标唯一值 */
7
+ export declare const ICONFONT_KEY: InjectionKey<Component>;
8
+ /** Arco 官方图标库 */
9
+ export declare const ARCO_ICON_KEY: InjectionKey<Record<string, Component>>;
10
+ /** 全局通用的router实例 */
11
+ export declare const ROUTER_KEY: InjectionKey<Router | null>;
@@ -0,0 +1,14 @@
1
+ /**
2
+ * FArco 依赖注入键集合。
3
+ *
4
+ * 如果不想通过 `app.use(FArco, opts)` 全局注册所有组件,
5
+ * 而是按需引入时,需要手动 provide 这些键以确保 FLink / FIcon 正常工作。
6
+ */
7
+ export declare const FArcoKeys: {
8
+ /** 对应 `FInstallOptions.router`,`FLink` SPA 跳转依赖,无需路由时传 `null` */
9
+ ROUTER: import('vue').InjectionKey<import('vue-router').Router | null>;
10
+ /** 对应 `FInstallOptions.iconfont`,`FIcon` IconFont 图标源,不使用时可传 `null` */
11
+ ICONFONT: import('vue').InjectionKey<import('vue').Component>;
12
+ /** 对应 `FInstallOptions.arcoIcon`,`FIcon` Arco 图标映射表,不使用时可传 `{}` */
13
+ ARCO_ICON: import('vue').InjectionKey<Record<string, import('vue').Component>>;
14
+ };
@@ -0,0 +1,4 @@
1
+ declare module '*.less' {
2
+ const content: string
3
+ export default content
4
+ }
@@ -1,18 +1,17 @@
1
1
  /// <reference path="./components.d.ts" />
2
2
  import { App } from 'vue';
3
3
  import { FInstallOptions } from './types';
4
-
5
- export * from './components/index';
6
- export { utils } from './utils';
7
- /** FArco 依赖注入键,按需引入场景下手动 provide 使用 */
8
- export { default as FArcoKeys } from './constants/global';
9
- declare function installFn(app: App, opts?: FInstallOptions): App;
10
- export declare const install: typeof installFn;
11
- declare const _default: {
12
- install: typeof installFn;
13
- version: string;
14
- framework: {
15
- vue: string;
16
- };
17
- };
18
- export default _default;
4
+
5
+ export * from './components/index';
6
+ export { utils } from './utils';
7
+ export { FArcoKeys } from './constants/keys';
8
+ declare function installFn(app: App, opts?: FInstallOptions): App;
9
+ export declare const install: typeof installFn;
10
+ declare const FArco: {
11
+ install: typeof installFn;
12
+ version: string;
13
+ framework: {
14
+ vue: string;
15
+ };
16
+ };
17
+ export default FArco;
@@ -1,46 +1,46 @@
1
1
  import { ROUTER_KEY } from '../../../../../../../../src/constants/global';
2
2
  import { InjectionKey, Component } from 'vue';
3
-
4
- export type AnyObject<T = any> = Record<string, T>;
5
- /**
6
- * 提取类型中不为null或undefined的字段
7
- */
8
- export type OmitNullUndefined<T> = {
9
- [K in keyof T as T[K] extends null | undefined ? never : K]: T[K];
10
- };
11
- export type FArcoRender = (data: any) => Component | number | string;
12
- /**
13
- * 通过方法获取的数据
14
- */
15
- export type FMethodData<T> = (params: AnyObject) => Promise<T> | T;
16
- /**
17
- * 分页查询返回的标准数据结构
18
- */
19
- export interface QF_Response<T = any> {
20
- list: T[];
21
- pageIndex: number;
22
- pageSize: number;
23
- pages: number;
24
- total: number;
25
- tag: string;
26
- }
27
- /**
28
- * 注册组件库时,提供的配置项
29
- */
30
- export interface FInstallOptions {
31
- /**
32
- * 使用方的VueRouter实例
33
- * @returns
34
- */
35
- router?: typeof ROUTER_KEY extends InjectionKey<infer U> ? U : never;
36
- /**
37
- * 图标库
38
- *
39
- * - arco: Arco官方图标库
40
- * - iconfont: Iconfont图标
41
- */
42
- icons?: {
43
- iconfont?: Component;
44
- arco?: Record<string, Component>;
45
- };
46
- }
3
+
4
+ export type AnyObject<T = any> = Record<string, T>;
5
+ /**
6
+ * 提取类型中不为null或undefined的字段
7
+ */
8
+ export type OmitNullUndefined<T> = {
9
+ [K in keyof T as T[K] extends null | undefined ? never : K]: T[K];
10
+ };
11
+ export type FArcoRender = (data: any) => Component | number | string;
12
+ /**
13
+ * 通过方法获取的数据
14
+ */
15
+ export type FMethodData<T> = (params: AnyObject) => Promise<T> | T;
16
+ /**
17
+ * 分页查询返回的标准数据结构
18
+ */
19
+ export interface QF_Response<T = any> {
20
+ list: T[];
21
+ pageIndex: number;
22
+ pageSize: number;
23
+ pages: number;
24
+ total: number;
25
+ tag: string;
26
+ }
27
+ /**
28
+ * 注册组件库时,提供的配置项
29
+ */
30
+ export interface FInstallOptions {
31
+ /**
32
+ * 使用方的VueRouter实例
33
+ * @returns
34
+ */
35
+ router?: typeof ROUTER_KEY extends InjectionKey<infer U> ? U : never;
36
+ /**
37
+ * 图标库
38
+ *
39
+ * - arco: Arco官方图标库
40
+ * - iconfont: Iconfont图标
41
+ */
42
+ icons?: {
43
+ iconfont?: Component;
44
+ arco?: Record<string, Component>;
45
+ };
46
+ }
@@ -1,2 +1,2 @@
1
1
  /// <reference path="./components.d.ts" />
2
- export * from './global';
2
+ export * from './global';
@@ -1,136 +1,136 @@
1
- /** 后端返回数据的基础字段 */
2
- interface ServerEntityBase {
3
- /**
4
- * 创建人系统编号
5
- */
6
- InUserSysNo: number;
7
- /**
8
- * 创建人
9
- */
10
- InUserName: string;
11
- /**
12
- * 创建时间
13
- */
14
- InDate: string;
15
- /**
16
- * 创建时间(格式化)
17
- */
18
- InDateStr: string;
19
- /**
20
- * 修改人系统编号
21
- */
22
- EditUserSysNo?: number | null;
23
- /**
24
- * 修改人
25
- */
26
- EditUserName?: string | null;
27
- /**
28
- * 修改时间
29
- */
30
- EditDate?: string | null;
31
- /**
32
- * 修改时间(格式化)
33
- */
34
- EditDateStr?: string;
35
- }
36
- /** 服务端返回的菜单及权限 */
37
- export interface AuthFunction extends ServerEntityBase {
38
- /**
39
- * 系统编号
40
- */
41
- SysNo: number;
42
- /**
43
- * 应用系统
44
- */
45
- AppID: string;
46
- /**
47
- * 菜单树编号
48
- */
49
- TreeCode: string;
50
- /**
51
- * 菜单Key
52
- */
53
- FunctionKey: string;
54
- /**
55
- * 菜单名称
56
- */
57
- FunctionName: string;
58
- /**
59
- * 是否为菜单
60
- * 0:不是菜单
61
- * 1:是菜单
62
- */
63
- IsMenu: 0 | 1;
64
- /**
65
- * 菜单页面url
66
- */
67
- MenuUrl: string | null;
68
- /**
69
- * 菜单图标
70
- */
71
- MenuIcon: string | null;
72
- /**
73
- * 是否启用
74
- * 0:禁用
75
- * 1:启用
76
- */
77
- CommonStatus: number;
78
- /**
79
- * 是否启用 - 转文本描述
80
- */
81
- CommonStatusStr: string;
82
- /**
83
- * 适用类型
84
- *
85
- * 用于某些特殊需求,比如SELLER PORTAL中该菜单适用哪种商家来源,1=只适用来源于客户ERP,2=只适用来源于飞驼OMS,0表示都适用不限制
86
- */
87
- ApplicableType: number;
88
- /**
89
- * 备注
90
- */
91
- Note: string;
92
- /**
93
- * 在角色分配权限时,标记是否选中
94
- */
95
- _IsSelected: boolean;
96
- }
97
- /** arco框架的应用菜单 */
98
- export interface ArcoAppMenu {
99
- /**
100
- * 系统编号
101
- */
102
- sysno: number;
103
- /**
104
- * 菜单树编号
105
- */
106
- treeCode: string;
107
- /**
108
- * 菜单key
109
- */
110
- key: string;
111
- /**
112
- * 菜单名称
113
- */
114
- title: string;
115
- /**
116
- * 菜单图标
117
- */
118
- icon: string;
119
- /**
120
- * 菜单页面路径地址
121
- */
122
- path: string;
123
- /**
124
- * 子菜单列表
125
- */
126
- children?: ArcoAppMenu[];
127
- }
128
- /**
129
- * 格式化服务端返回权限菜单数据 -- 仅支持arco框架的项目
130
- *
131
- * !!!目前只支持固定格式返回,暂无自定义处理能力!!!
132
- * @param list 需要处理的权限数据
133
- * @returns 格式化后的菜单列表
134
- */
135
- export declare function formatListToMenus(list: AuthFunction[]): ArcoAppMenu[];
136
- export {};
1
+ /** 后端返回数据的基础字段 */
2
+ interface ServerEntityBase {
3
+ /**
4
+ * 创建人系统编号
5
+ */
6
+ InUserSysNo: number;
7
+ /**
8
+ * 创建人
9
+ */
10
+ InUserName: string;
11
+ /**
12
+ * 创建时间
13
+ */
14
+ InDate: string;
15
+ /**
16
+ * 创建时间(格式化)
17
+ */
18
+ InDateStr: string;
19
+ /**
20
+ * 修改人系统编号
21
+ */
22
+ EditUserSysNo?: number | null;
23
+ /**
24
+ * 修改人
25
+ */
26
+ EditUserName?: string | null;
27
+ /**
28
+ * 修改时间
29
+ */
30
+ EditDate?: string | null;
31
+ /**
32
+ * 修改时间(格式化)
33
+ */
34
+ EditDateStr?: string;
35
+ }
36
+ /** 服务端返回的菜单及权限 */
37
+ export interface AuthFunction extends ServerEntityBase {
38
+ /**
39
+ * 系统编号
40
+ */
41
+ SysNo: number;
42
+ /**
43
+ * 应用系统
44
+ */
45
+ AppID: string;
46
+ /**
47
+ * 菜单树编号
48
+ */
49
+ TreeCode: string;
50
+ /**
51
+ * 菜单Key
52
+ */
53
+ FunctionKey: string;
54
+ /**
55
+ * 菜单名称
56
+ */
57
+ FunctionName: string;
58
+ /**
59
+ * 是否为菜单
60
+ * 0:不是菜单
61
+ * 1:是菜单
62
+ */
63
+ IsMenu: 0 | 1;
64
+ /**
65
+ * 菜单页面url
66
+ */
67
+ MenuUrl: string | null;
68
+ /**
69
+ * 菜单图标
70
+ */
71
+ MenuIcon: string | null;
72
+ /**
73
+ * 是否启用
74
+ * 0:禁用
75
+ * 1:启用
76
+ */
77
+ CommonStatus: number;
78
+ /**
79
+ * 是否启用 - 转文本描述
80
+ */
81
+ CommonStatusStr: string;
82
+ /**
83
+ * 适用类型
84
+ *
85
+ * 用于某些特殊需求,比如SELLER PORTAL中该菜单适用哪种商家来源,1=只适用来源于客户ERP,2=只适用来源于飞驼OMS,0表示都适用不限制
86
+ */
87
+ ApplicableType: number;
88
+ /**
89
+ * 备注
90
+ */
91
+ Note: string;
92
+ /**
93
+ * 在角色分配权限时,标记是否选中
94
+ */
95
+ _IsSelected: boolean;
96
+ }
97
+ /** arco框架的应用菜单 */
98
+ export interface ArcoAppMenu {
99
+ /**
100
+ * 系统编号
101
+ */
102
+ sysno: number;
103
+ /**
104
+ * 菜单树编号
105
+ */
106
+ treeCode: string;
107
+ /**
108
+ * 菜单key
109
+ */
110
+ key: string;
111
+ /**
112
+ * 菜单名称
113
+ */
114
+ title: string;
115
+ /**
116
+ * 菜单图标
117
+ */
118
+ icon: string;
119
+ /**
120
+ * 菜单页面路径地址
121
+ */
122
+ path: string;
123
+ /**
124
+ * 子菜单列表
125
+ */
126
+ children?: ArcoAppMenu[];
127
+ }
128
+ /**
129
+ * 格式化服务端返回权限菜单数据 -- 仅支持arco框架的项目
130
+ *
131
+ * !!!目前只支持固定格式返回,暂无自定义处理能力!!!
132
+ * @param list 需要处理的权限数据
133
+ * @returns 格式化后的菜单列表
134
+ */
135
+ export declare function formatListToMenus(list: AuthFunction[]): ArcoAppMenu[];
136
+ export {};
@@ -1,5 +1,5 @@
1
1
  /// <reference path="./components.d.ts" />
2
- import * as businessFormat from './business-format';
3
- export declare const utils: {
4
- formatListToMenus(list: businessFormat.AuthFunction[]): businessFormat.ArcoAppMenu[];
5
- };
2
+ import * as businessFormat from './business-format';
3
+ export declare const utils: {
4
+ formatListToMenus(list: businessFormat.AuthFunction[]): businessFormat.ArcoAppMenu[];
5
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@flyto/farco",
3
- "version": "1.2.1",
3
+ "version": "1.4.0",
4
4
  "main": "dist/index.umd.js",
5
5
  "module": "dist/index.es.js",
6
6
  "types": "dist/types/index.d.ts",
@@ -10,8 +10,28 @@
10
10
  "require": "./dist/index.umd.js",
11
11
  "types": "./dist/types/index.d.ts"
12
12
  },
13
+ "./keys": {
14
+ "import": "./dist/keys.es.js",
15
+ "require": "./dist/keys.cjs.js",
16
+ "types": "./dist/types/constants/keys.d.ts"
17
+ },
18
+ "./*": {
19
+ "import": "./dist/*.es.js",
20
+ "require": "./dist/*.cjs.js",
21
+ "types": "./dist/types/components/*/index.d.ts"
22
+ },
13
23
  "./style.css": "./dist/style.css"
14
24
  },
25
+ "typesVersions": {
26
+ "*": {
27
+ "keys": [
28
+ "./dist/types/constants/keys.d.ts"
29
+ ],
30
+ "*": [
31
+ "./dist/types/components/*/index.d.ts"
32
+ ]
33
+ }
34
+ },
15
35
  "files": [
16
36
  "dist"
17
37
  ],
@@ -39,16 +59,16 @@
39
59
  "@vitejs/plugin-vue": "^3.2.0",
40
60
  "@vitejs/plugin-vue-jsx": "^2.0.1",
41
61
  "less": "^4.5.1",
42
- "typescript": "^4.8.4",
62
+ "typescript": "^5.3.0",
43
63
  "unplugin-vue-components": "^0.25.1",
44
64
  "vite": "^3.2.5",
45
65
  "vite-plugin-dts": "^3.4.0",
46
- "vue": "^3.4.31",
66
+ "vue": "^3.5.30",
47
67
  "vue-component-type-helpers": "^2.2.8",
48
68
  "vue-router": "^4.4.0",
49
69
  "vue-tsc": "^1.0.14"
50
70
  },
51
71
  "scripts": {
52
- "build": "vite build"
72
+ "build": "vite build && vite build --config vite.umd.config.ts"
53
73
  }
54
74
  }