@kengic/vue 0.21.4-beta.2 → 0.21.5-beta.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (75) hide show
  1. package/dist/index.css +1 -1
  2. package/dist/kengic-vue.js +3119 -3047
  3. package/dist/project/build/config/themeConfig.ts +67 -0
  4. package/dist/project/build/constant.ts +6 -0
  5. package/dist/project/build/generate/generateModifyVars.ts +39 -0
  6. package/dist/project/build/generate/icon/index.ts +66 -0
  7. package/dist/project/build/getConfigFileName.ts +7 -0
  8. package/dist/project/build/index.ts +9 -0
  9. package/dist/project/build/script/buildConf.ts +45 -0
  10. package/dist/project/build/script/postBuild.ts +21 -0
  11. package/dist/project/build/utils.ts +92 -0
  12. package/dist/project/build/vite/plugin/compress.ts +32 -0
  13. package/dist/project/build/vite/plugin/html.ts +39 -0
  14. package/dist/project/build/vite/plugin/imagemin.ts +34 -0
  15. package/dist/project/build/vite/plugin/index.ts +80 -0
  16. package/dist/project/build/vite/plugin/mock.ts +19 -0
  17. package/dist/project/build/vite/plugin/pwa.ts +33 -0
  18. package/dist/project/build/vite/plugin/styleImport.ts +81 -0
  19. package/dist/project/build/vite/plugin/svgSprite.ts +17 -0
  20. package/dist/project/build/vite/plugin/theme.ts +100 -0
  21. package/dist/project/build/vite/plugin/visualizer.ts +17 -0
  22. package/dist/project/build/vite/proxy.ts +34 -0
  23. package/dist/project/index.ts +1 -0
  24. package/dist/project/src/api/sys/model/menuModel.ts +17 -0
  25. package/dist/project/src/api/sys/model/uploadModel.ts +5 -0
  26. package/dist/project/src/api/sys/model/userModel.ts +57 -0
  27. package/dist/project/src/enums/CompTypeEnum.ts +32 -0
  28. package/dist/project/src/enums/DateTypeEnum.ts +8 -0
  29. package/dist/project/src/enums/appEnum.ts +58 -0
  30. package/dist/project/src/enums/breakpointEnum.ts +28 -0
  31. package/dist/project/src/enums/cacheEnum.ts +39 -0
  32. package/dist/project/src/enums/exceptionEnum.ts +27 -0
  33. package/dist/project/src/enums/httpEnum.ts +50 -0
  34. package/dist/project/src/enums/jeecgEnum.ts +23 -0
  35. package/dist/project/src/enums/menuEnum.ts +50 -0
  36. package/dist/project/src/enums/pageEnum.ts +19 -0
  37. package/dist/project/src/enums/roleEnum.ts +7 -0
  38. package/dist/project/src/enums/sizeEnum.ts +27 -0
  39. package/dist/project/types/axios.d.ts +57 -0
  40. package/dist/project/types/config.d.ts +178 -0
  41. package/dist/project/types/global.d.ts +92 -0
  42. package/dist/project/types/index.d.ts +27 -0
  43. package/dist/project/types/module.d.ts +18 -0
  44. package/dist/project/types/store.d.ts +59 -0
  45. package/dist/project/types/utils.d.ts +5 -0
  46. package/dist/project/types/vue-router.d.ts +47 -0
  47. package/dist/src/components/KgForm.Item/addon/KgForm.Item.Addon.Lookup.Modal.d.ts +0 -1
  48. package/dist/src/components/KgForm.Item/addon/KgForm.Item.Addon.Lookup.d.ts +0 -1
  49. package/dist/src/components/KgForm.Item/components/KgForm.Item.Checkbox.d.ts +0 -3
  50. package/dist/src/components/KgForm.Item/components/KgForm.Item.CheckboxGroup.d.ts +2 -3
  51. package/dist/src/components/KgForm.Item/components/KgForm.Item.Date.d.ts +0 -1
  52. package/dist/src/components/KgForm.Item/components/KgForm.Item.DateRange.d.ts +0 -1
  53. package/dist/src/components/KgForm.Item/components/KgForm.Item.Image.d.ts +94 -0
  54. package/dist/src/components/KgForm.Item/components/KgForm.Item.Input.d.ts +0 -1
  55. package/dist/src/components/KgForm.Item/components/KgForm.Item.InputNumber.d.ts +0 -1
  56. package/dist/src/components/KgForm.Item/components/KgForm.Item.RadioGroup.d.ts +6 -7
  57. package/dist/src/components/KgForm.Item/components/KgForm.Item.Select.d.ts +0 -1
  58. package/dist/src/components/KgForm.Item/components/KgForm.Item.Switch.d.ts +0 -1
  59. package/dist/src/components/KgForm.Item/components/KgForm.Item.TextArea.d.ts +0 -1
  60. package/dist/src/components/KgImage/KgImage.d.ts +100 -0
  61. package/dist/src/components/KgImage/index.d.ts +1 -0
  62. package/dist/src/components/KgSubmit/KgSubmit.d.ts +13 -4
  63. package/dist/src/components/KgSubmit/KgSubmit.hooks.d.ts +10 -3
  64. package/dist/src/components/KgSubmit/index.d.ts +1 -1
  65. package/dist/src/components/KgTable/components/KgTable.BodyCell.d.ts +0 -1
  66. package/dist/src/components/KgTable/components/KgTable.HeaderCell.d.ts +0 -1
  67. package/dist/src/components/KgTable/components/KgTable.Info.d.ts +0 -1
  68. package/dist/src/components/KgVar/index.vm.d.ts +2 -2
  69. package/dist/src/components/index.d.ts +2 -1
  70. package/dist/src/config/index.hooks.d.ts +11 -53
  71. package/dist/src/config/index.store.d.ts +38 -3
  72. package/dist/src/consts/index.d.ts +15 -6
  73. package/dist/src/consts/index.vm.d.ts +30 -2
  74. package/dist/src/helpers/ant-design-vue.d.ts +34 -3
  75. package/package.json +39 -17
@@ -0,0 +1,94 @@
1
+ declare const _default: import("vue").DefineComponent<{
2
+ kgVarName: {
3
+ type: import("vue").PropType<string>;
4
+ required: boolean;
5
+ };
6
+ kgContext: {
7
+ type: import("vue").PropType<string>;
8
+ default: import("../../../consts").KG_FORM_CONTEXT;
9
+ };
10
+ kgDisabled: {
11
+ type: import("vue").PropType<boolean>;
12
+ default: undefined;
13
+ };
14
+ kgSpan: import("vue").PropType<number>;
15
+ kgPlaceholder: import("vue").PropType<string>;
16
+ kgMode: import("vue").PropType<"multiple" | "tags">;
17
+ kgShowLabel: {
18
+ type: import("vue").PropType<boolean>;
19
+ default: boolean;
20
+ };
21
+ kgAllowClear: {
22
+ type: import("vue").PropType<boolean>;
23
+ default: undefined;
24
+ };
25
+ kgShowTime: {
26
+ type: import("vue").PropType<boolean | import("ant-design-vue/es/vc-picker/panels/TimePanel").SharedTimeProps<import("dayjs").Dayjs>>;
27
+ default: undefined;
28
+ };
29
+ kgPicker: {
30
+ type: import("vue").PropType<import("ant-design-vue/lib/vc-picker/interface").PickerMode>;
31
+ default: undefined;
32
+ };
33
+ kgRules: import("vue").PropType<import("ant-design-vue/es/form").RuleObject[]>;
34
+ value: {
35
+ type: import("vue").PropType<import("../index.vm").IKgFormItemValue>;
36
+ default: undefined;
37
+ };
38
+ 'onUpdate:value': import("vue").PropType<(value: import("../index.vm").IKgFormItemValue | null) => void>;
39
+ onKgSubmit: import("vue").PropType<() => void>;
40
+ onKgChange: import("vue").PropType<(value: any) => void>;
41
+ onKgSelectChange: import("vue").PropType<(value: any) => void>;
42
+ onKgSelectDatasChange: import("vue").PropType<(datas: any[]) => void>;
43
+ }, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
44
+ kgVarName: {
45
+ type: import("vue").PropType<string>;
46
+ required: boolean;
47
+ };
48
+ kgContext: {
49
+ type: import("vue").PropType<string>;
50
+ default: import("../../../consts").KG_FORM_CONTEXT;
51
+ };
52
+ kgDisabled: {
53
+ type: import("vue").PropType<boolean>;
54
+ default: undefined;
55
+ };
56
+ kgSpan: import("vue").PropType<number>;
57
+ kgPlaceholder: import("vue").PropType<string>;
58
+ kgMode: import("vue").PropType<"multiple" | "tags">;
59
+ kgShowLabel: {
60
+ type: import("vue").PropType<boolean>;
61
+ default: boolean;
62
+ };
63
+ kgAllowClear: {
64
+ type: import("vue").PropType<boolean>;
65
+ default: undefined;
66
+ };
67
+ kgShowTime: {
68
+ type: import("vue").PropType<boolean | import("ant-design-vue/es/vc-picker/panels/TimePanel").SharedTimeProps<import("dayjs").Dayjs>>;
69
+ default: undefined;
70
+ };
71
+ kgPicker: {
72
+ type: import("vue").PropType<import("ant-design-vue/lib/vc-picker/interface").PickerMode>;
73
+ default: undefined;
74
+ };
75
+ kgRules: import("vue").PropType<import("ant-design-vue/es/form").RuleObject[]>;
76
+ value: {
77
+ type: import("vue").PropType<import("../index.vm").IKgFormItemValue>;
78
+ default: undefined;
79
+ };
80
+ 'onUpdate:value': import("vue").PropType<(value: import("../index.vm").IKgFormItemValue | null) => void>;
81
+ onKgSubmit: import("vue").PropType<() => void>;
82
+ onKgChange: import("vue").PropType<(value: any) => void>;
83
+ onKgSelectChange: import("vue").PropType<(value: any) => void>;
84
+ onKgSelectDatasChange: import("vue").PropType<(datas: any[]) => void>;
85
+ }>>, {
86
+ value: import("../index.vm").IKgFormItemValue;
87
+ kgDisabled: boolean;
88
+ kgContext: string;
89
+ kgShowLabel: boolean;
90
+ kgAllowClear: boolean;
91
+ kgShowTime: boolean | import("ant-design-vue/es/vc-picker/panels/TimePanel").SharedTimeProps<import("dayjs").Dayjs>;
92
+ kgPicker: import("ant-design-vue/lib/vc-picker/interface").PickerMode;
93
+ }>;
94
+ export default _default;
@@ -1,4 +1,3 @@
1
- import '../KgForm.Item.less';
2
1
  declare const _default: import("vue").DefineComponent<{
3
2
  kgVarName: {
4
3
  type: import("vue").PropType<string>;
@@ -1,4 +1,3 @@
1
- import '../KgForm.Item.less';
2
1
  declare const _default: import("vue").DefineComponent<{
3
2
  kgVarName: {
4
3
  type: import("vue").PropType<string>;
@@ -1,4 +1,3 @@
1
- import '../KgForm.Item.less';
2
1
  declare const _default: import("vue").DefineComponent<{
3
2
  kgVarName: {
4
3
  type: import("vue").PropType<string>;
@@ -16,9 +15,9 @@ declare const _default: import("vue").DefineComponent<{
16
15
  kgPlaceholder: import("vue").PropType<string>;
17
16
  kgMode: import("vue").PropType<"multiple" | "tags">;
18
17
  kgShowLabel: {
19
- type: import("vue").PropType<boolean>;
20
- default: boolean; /** 初始. */
21
- }; /** 初始. */
18
+ type: import("vue").PropType<boolean>; /** 初始. */
19
+ default: boolean;
20
+ };
22
21
  kgAllowClear: {
23
22
  type: import("vue").PropType<boolean>;
24
23
  default: undefined;
@@ -58,9 +57,9 @@ declare const _default: import("vue").DefineComponent<{
58
57
  kgPlaceholder: import("vue").PropType<string>;
59
58
  kgMode: import("vue").PropType<"multiple" | "tags">;
60
59
  kgShowLabel: {
61
- type: import("vue").PropType<boolean>;
62
- default: boolean; /** 初始. */
63
- }; /** 初始. */
60
+ type: import("vue").PropType<boolean>; /** 初始. */
61
+ default: boolean;
62
+ };
64
63
  kgAllowClear: {
65
64
  type: import("vue").PropType<boolean>;
66
65
  default: undefined;
@@ -1,5 +1,4 @@
1
1
  import { KG_FORM_CONTEXT } from '../../../consts';
2
- import '../KgForm.Item.less';
3
2
  declare const _default: import("vue").DefineComponent<{
4
3
  kgVarName: {
5
4
  type: import("vue").PropType<string>;
@@ -1,4 +1,3 @@
1
- import '../KgForm.Item.less';
2
1
  declare const _default: import("vue").DefineComponent<{
3
2
  kgVarName: {
4
3
  type: import("vue").PropType<string>;
@@ -1,4 +1,3 @@
1
- import '../KgForm.Item.less';
2
1
  declare const _default: import("vue").DefineComponent<{
3
2
  kgVarName: {
4
3
  type: import("vue").PropType<string>;
@@ -0,0 +1,100 @@
1
+ import { ExtractPropTypes } from 'vue';
2
+ import './KgImage.less';
3
+ export declare const getProps: () => {
4
+ src: StringConstructor;
5
+ wrapperClassName: StringConstructor;
6
+ wrapperStyle: {
7
+ type: import("vue").PropType<import("vue").CSSProperties>;
8
+ default: undefined;
9
+ };
10
+ rootClassName: StringConstructor;
11
+ prefixCls: StringConstructor;
12
+ previewPrefixCls: StringConstructor;
13
+ previewMask: {
14
+ type: import("vue").PropType<false | (() => any)>;
15
+ default: undefined;
16
+ };
17
+ placeholder: StringConstructor;
18
+ fallback: StringConstructor;
19
+ preview: {
20
+ type: import("vue").PropType<any>;
21
+ default: any;
22
+ };
23
+ onClick: {
24
+ type: import("vue").PropType<(e: MouseEvent) => void>;
25
+ };
26
+ onError: {
27
+ type: import("vue").PropType<(event: string | Event, source?: string | undefined, lineno?: number | undefined, colno?: number | undefined, error?: Error | undefined) => any>;
28
+ };
29
+ id: StringConstructor;
30
+ width: (NumberConstructor | StringConstructor)[];
31
+ height: (NumberConstructor | StringConstructor)[];
32
+ style: StringConstructor;
33
+ };
34
+ export declare type KgImageProps = Partial<ExtractPropTypes<ReturnType<typeof getProps>>>;
35
+ declare const _default: import("vue").DefineComponent<{
36
+ src: StringConstructor;
37
+ wrapperClassName: StringConstructor;
38
+ wrapperStyle: {
39
+ type: import("vue").PropType<import("vue").CSSProperties>;
40
+ default: undefined;
41
+ };
42
+ rootClassName: StringConstructor;
43
+ prefixCls: StringConstructor;
44
+ previewPrefixCls: StringConstructor;
45
+ previewMask: {
46
+ type: import("vue").PropType<false | (() => any)>;
47
+ default: undefined;
48
+ };
49
+ placeholder: StringConstructor;
50
+ fallback: StringConstructor;
51
+ preview: {
52
+ type: import("vue").PropType<any>;
53
+ default: any;
54
+ };
55
+ onClick: {
56
+ type: import("vue").PropType<(e: MouseEvent) => void>;
57
+ };
58
+ onError: {
59
+ type: import("vue").PropType<(event: string | Event, source?: string | undefined, lineno?: number | undefined, colno?: number | undefined, error?: Error | undefined) => any>;
60
+ };
61
+ id: StringConstructor;
62
+ width: (NumberConstructor | StringConstructor)[];
63
+ height: (NumberConstructor | StringConstructor)[];
64
+ style: StringConstructor;
65
+ }, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<ExtractPropTypes<{
66
+ src: StringConstructor;
67
+ wrapperClassName: StringConstructor;
68
+ wrapperStyle: {
69
+ type: import("vue").PropType<import("vue").CSSProperties>;
70
+ default: undefined;
71
+ };
72
+ rootClassName: StringConstructor;
73
+ prefixCls: StringConstructor;
74
+ previewPrefixCls: StringConstructor;
75
+ previewMask: {
76
+ type: import("vue").PropType<false | (() => any)>;
77
+ default: undefined;
78
+ };
79
+ placeholder: StringConstructor;
80
+ fallback: StringConstructor;
81
+ preview: {
82
+ type: import("vue").PropType<any>;
83
+ default: any;
84
+ };
85
+ onClick: {
86
+ type: import("vue").PropType<(e: MouseEvent) => void>;
87
+ };
88
+ onError: {
89
+ type: import("vue").PropType<(event: string | Event, source?: string | undefined, lineno?: number | undefined, colno?: number | undefined, error?: Error | undefined) => any>;
90
+ };
91
+ id: StringConstructor;
92
+ width: (NumberConstructor | StringConstructor)[];
93
+ height: (NumberConstructor | StringConstructor)[];
94
+ style: StringConstructor;
95
+ }>>, {
96
+ wrapperStyle: import("vue").CSSProperties;
97
+ previewMask: false | (() => any);
98
+ preview: any;
99
+ }>;
100
+ export default _default;
@@ -0,0 +1 @@
1
+ export { default as KgImage, type KgImageProps } from './KgImage';
@@ -1,10 +1,13 @@
1
1
  import { ExtractPropTypes, PropType } from 'vue';
2
2
  import './KgSubmit.less';
3
3
  export declare const getProps: () => {
4
- /** 自定义的样式类名. */
4
+ /**
5
+ * 自定义的样式类名, 会附加到组件默认的样式类名后面.
6
+ */
5
7
  kgClass: PropType<string>;
6
8
  /**
7
9
  * 是否显示头部右侧的表单配置按钮.
10
+ *
8
11
  * @default true
9
12
  */
10
13
  kgIsShowVarSubmitConfigButton: {
@@ -12,12 +15,15 @@ export declare const getProps: () => {
12
15
  default: boolean;
13
16
  };
14
17
  };
15
- export declare type IKgSubmitProps = Partial<ExtractPropTypes<ReturnType<typeof getProps>>>;
18
+ export declare type KgSubmitProps = Partial<ExtractPropTypes<ReturnType<typeof getProps>>>;
16
19
  declare const _default: import("vue").DefineComponent<{
17
- /** 自定义的样式类名. */
20
+ /**
21
+ * 自定义的样式类名, 会附加到组件默认的样式类名后面.
22
+ */
18
23
  kgClass: PropType<string>;
19
24
  /**
20
25
  * 是否显示头部右侧的表单配置按钮.
26
+ *
21
27
  * @default true
22
28
  */
23
29
  kgIsShowVarSubmitConfigButton: {
@@ -25,10 +31,13 @@ declare const _default: import("vue").DefineComponent<{
25
31
  default: boolean;
26
32
  };
27
33
  }, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<ExtractPropTypes<{
28
- /** 自定义的样式类名. */
34
+ /**
35
+ * 自定义的样式类名, 会附加到组件默认的样式类名后面.
36
+ */
29
37
  kgClass: PropType<string>;
30
38
  /**
31
39
  * 是否显示头部右侧的表单配置按钮.
40
+ *
32
41
  * @default true
33
42
  */
34
43
  kgIsShowVarSubmitConfigButton: {
@@ -1,5 +1,5 @@
1
1
  import { Ref, UnwrapRef } from 'vue';
2
- import { IKgSubmitProps } from './KgSubmit';
2
+ import { KgSubmitProps } from './KgSubmit';
3
3
  export declare function _useFormModel(): {
4
4
  model: Ref<Record<string, any>>;
5
5
  };
@@ -8,8 +8,15 @@ export declare function _useResizeObserver(kgFormRef: Ref<UnwrapRef<HTMLDivEleme
8
8
  export declare function _useTitle(): {
9
9
  title: Ref<string>;
10
10
  };
11
- export declare function _useClass(props: IKgSubmitProps): {
12
- getClass: Ref<string>;
11
+ export declare function _useClass(props: KgSubmitProps): {
12
+ /**
13
+ * 弹窗样式.
14
+ */
15
+ getClass: import("vue").ComputedRef<string>;
16
+ /**
17
+ * 弹窗容器样式.
18
+ */
19
+ getWrapClass: import("vue").ComputedRef<string>;
13
20
  };
14
21
  export declare function _useLayout(): {
15
22
  getLayout: Ref<'horizontal' | 'vertical'>;
@@ -1,4 +1,4 @@
1
- export { default as KgSubmit, type IKgSubmitProps } from './KgSubmit';
1
+ export { default as KgSubmit, type KgSubmitProps } from './KgSubmit';
2
2
  export * from './index.hooks';
3
3
  export * from './index.store';
4
4
  export * from './index.vm';
@@ -1,6 +1,5 @@
1
1
  import { PropType } from 'vue';
2
2
  import { IKgTableRow, KG_TABLE_CELL_CONTEXT } from '../index.vm';
3
- import './KgTable.BodyCell.less';
4
3
  export declare const getProps: () => {
5
4
  /** 行对象. */
6
5
  kgRow: PropType<IKgTableRow>;
@@ -1,6 +1,5 @@
1
1
  import { ColumnType } from 'ant-design-vue/es/table';
2
2
  import { PropType } from 'vue';
3
- import './KgTable.HeaderCell.less';
4
3
  export declare const getProps: () => {
5
4
  /**
6
5
  * 列的数据.
@@ -1,5 +1,4 @@
1
1
  import { PropType } from 'vue';
2
- import './KgTable.Info.less';
3
2
  export declare const getProps: () => {
4
3
  /**
5
4
  * 行数.
@@ -2,7 +2,7 @@ import { ComputedRef, InjectionKey } from 'vue';
2
2
  import { IKgButtonProps } from '../KgButton';
3
3
  import { IKgFormItemSlotControlParam, IKgFormItemSlotControlRightParam } from '../KgForm.Item/index.vm';
4
4
  import { IKgSearchProps } from '../KgSearch';
5
- import { IKgSubmitProps } from '../KgSubmit';
5
+ import { KgSubmitProps } from '../KgSubmit';
6
6
  import { IKgTableSlotParams } from '../KgTable';
7
7
  import { IKgTableProps } from '../KgTable/KgTable';
8
8
  export declare type IKgSlots = {
@@ -40,7 +40,7 @@ export declare const DI_KG_VAR__KG_SLOTS: InjectionKey<IKgSlots | undefined>;
40
40
  export declare type IKgProps = {
41
41
  KgSearch?: IKgSearchProps;
42
42
  KgButton?: IKgButtonProps;
43
- KgSubmit?: IKgSubmitProps;
43
+ KgSubmit?: KgSubmitProps;
44
44
  KgTable?: IKgTableProps;
45
45
  };
46
46
  /** 注入 kgProps 参数. */
@@ -1,4 +1,6 @@
1
1
  export * from './KgAppSelect';
2
+ export * from './KgImage';
3
+ export * from './KgLayoutHeader';
2
4
  export * from './KgModal';
3
5
  export * from './KgProgressA';
4
6
  export * from './KgResizable';
@@ -14,4 +16,3 @@ export { default as KgButton } from './KgButton';
14
16
  export * from './KgForm';
15
17
  export { default as KgForm } from './KgForm';
16
18
  export * from './KgForm.Item';
17
- export * from './KgLayoutHeader';
@@ -1,11 +1,11 @@
1
1
  import { Pinia } from 'pinia';
2
2
  /**
3
- * @param pinia 在某些地方调用时(比如在路由守卫中), pinia 尚未设置, 此时需要手动传入 pinia 实例.
3
+ * @param pinia 在某些地方调用时(比如在路由守卫中), pinia 尚未初始化, 此时需要手动传入 pinia 实例.
4
4
  */
5
5
  export declare function useKg(pinia?: Pinia): {
6
6
  store: import("pinia").Store<"Kg", import("./index.store").IKgState, {
7
- getLocale: import("vue").ComputedRef<import("..").IKgLocale> | null;
8
- getRouter: import("vue-router").Router | null;
7
+ getLocale(): import("vue").ComputedRef<import("..").IKgLocale> | null;
8
+ getRouter(): import("vue-router").Router | null;
9
9
  getUseUserStore(): import("pinia").StoreDefinition<string, import("./index.store").UserState, {
10
10
  getToken(): string;
11
11
  getRoleList(): any[];
@@ -17,7 +17,8 @@ export declare function useKg(pinia?: Pinia): {
17
17
  getPermCodeList(): string[] | number[];
18
18
  getBackMenuList(): import("..").Menu[];
19
19
  }, import("pinia")._ActionsTree> | null;
20
- getOption: import("./index.store").IKgOption;
20
+ getOption(): import("./index.store").IKgOption;
21
+ getPublicPath(): string;
21
22
  }, {
22
23
  setLocale(locale: import("vue").ComputedRef<import("..").IKgLocale> | null): void;
23
24
  setRouter(router: import("vue-router").Router): void;
@@ -26,59 +27,16 @@ export declare function useKg(pinia?: Pinia): {
26
27
  setT(i18n: any): void;
27
28
  setP(fn: import("./index.store").P): void;
28
29
  setOption(option: import("./index.store").IKgOption): void;
29
- t: import("./index.store").T;
30
- p: import("./index.store").P;
30
+ t(key: string | null | undefined, ...arg: any[]): string;
31
+ p(permissionCode?: string | string[] | null | undefined): boolean;
31
32
  }>;
32
33
  /** 当前语言. */
33
- locale: import("vue").ComputedRef<"zh_CN" | "en" | "ru" | "ja" | "ko">;
34
+ locale: import("vue").ComputedRef<import("..").IKgLocale>;
34
35
  router: any;
35
36
  /** 配置参数. */
36
- option: import("vue").ComputedRef<{
37
- appIndex?: {
38
- "data-manager"?: string | undefined;
39
- "business-manager"?: string | undefined;
40
- wcs?: string | undefined;
41
- sys?: string | undefined;
42
- } | undefined;
43
- appTitle?: {
44
- "data-manager"?: string | undefined;
45
- "business-manager"?: string | undefined;
46
- wcs?: string | undefined;
47
- sys?: string | undefined;
48
- } | undefined;
49
- KgModal?: {
50
- drag?: {
51
- on?: boolean | undefined;
52
- } | undefined;
53
- dragToResize?: {
54
- isOn?: boolean | undefined;
55
- } | undefined;
56
- } | undefined;
57
- KgSearch?: {
58
- dynamicQuery?: {
59
- on?: boolean | undefined;
60
- } | undefined;
61
- } | undefined;
62
- KgTable?: {
63
- filter?: {
64
- on?: boolean | undefined;
65
- } | undefined;
66
- Setting?: {
67
- rowHeight?: {
68
- on?: boolean | undefined;
69
- } | undefined;
70
- } | undefined;
71
- } | undefined;
72
- KgWarehouse?: {
73
- on?: boolean | undefined;
74
- defaultWarehouseID?: string | undefined;
75
- } | undefined;
76
- KgLayoutTab?: {
77
- isTeleportToHeader?: boolean | undefined;
78
- } | undefined;
79
- }>;
37
+ option: import("vue").ComputedRef<import("./index.store").IKgOption>;
80
38
  /** 翻译. */
81
- t: import("./index.store").T;
39
+ t: (key: string | null | undefined, ...arg: any[]) => string;
82
40
  /** 检查权限. */
83
- p: import("./index.store").P;
41
+ p: (permissionCode?: string | string[] | null | undefined) => boolean;
84
42
  };
@@ -1,4 +1,4 @@
1
- import { Pinia, StoreDefinition } from 'pinia';
1
+ import { StoreDefinition } from 'pinia';
2
2
  import { ComputedRef } from 'vue';
3
3
  import { Router } from 'vue-router';
4
4
  import { SysUserWarehouseDTO } from '../apis/WMS/models';
@@ -26,6 +26,12 @@ export declare type IKgOption = {
26
26
  /** 默认为 '系统配置'. */
27
27
  [KG_APP.SYS]?: string;
28
28
  };
29
+ /**
30
+ * <p>后端接口地址前缀.</p>
31
+ *
32
+ * @default '/kengic-boot'
33
+ */
34
+ publicPath?: string;
29
35
  KgModal?: {
30
36
  /** 拖拽改变位置. */
31
37
  drag?: {
@@ -51,6 +57,7 @@ export declare type IKgOption = {
51
57
  dynamicQuery?: {
52
58
  /**
53
59
  * 是否启用功能.
60
+ *
54
61
  * @default false
55
62
  */
56
63
  on?: boolean;
@@ -199,6 +206,34 @@ export declare type IKgStoreDefinition = StoreDefinition<'Kg', IKgState, {
199
206
  /** 检查权限. */
200
207
  p: P;
201
208
  }>;
202
- export declare type IKgStore = ReturnType<IKgStoreDefinition>;
203
- export declare const useKgStore: (_pinia?: Pinia) => IKgStoreDefinition;
209
+ export declare const useKgStore: StoreDefinition<"Kg", IKgState, {
210
+ getLocale(): ComputedRef<IKgLocale> | null;
211
+ getRouter(): Router | null;
212
+ getUseUserStore(): StoreDefinition<string, UserState, {
213
+ getToken(): string;
214
+ getRoleList(): any[];
215
+ getUserWarehouses(): SysUserWarehouseDTO[];
216
+ getSessionTimeout(): boolean;
217
+ getUserInfo(): UserInfo;
218
+ }, {}> | null;
219
+ getUsePermissionStore(): StoreDefinition<string, PermissionState, {
220
+ getPermCodeList(): string[] | number[];
221
+ getBackMenuList(): Menu[];
222
+ }> | null;
223
+ getOption(): IKgOption;
224
+ /**
225
+ * 获取后端接口地址前缀.
226
+ */
227
+ getPublicPath(): string;
228
+ }, {
229
+ setLocale(locale: ComputedRef<IKgLocale> | null): void;
230
+ setRouter(router: Router): void;
231
+ setUseUserStore(useUserStore: StoreDefinition<any, any, any, any>): void;
232
+ setUsePermissionStore(usePermissionStore: StoreDefinition<any, any, any, any>): void;
233
+ setT(i18n: any): void;
234
+ setP(fn: P): void;
235
+ setOption(option: IKgOption): void;
236
+ t(key: string | null | undefined, ...arg: any[]): string;
237
+ p(permissionCode?: string | Array<string> | null): boolean;
238
+ }>;
204
239
  export {};
@@ -80,6 +80,11 @@ export declare const enum KG_FORM_ITEM_CONTROL_TYPE {
80
80
  DATE_WEEK = "DATE_WEEK",
81
81
  DATE_MONTH = "DATE_MONTH",
82
82
  DATE_YEAR = "DATE_YEAR",
83
+ /**
84
+ * <p>图片.</p>
85
+ * <p>点击可以预览.</p>
86
+ */
87
+ IMAGE = "IMAGE",
83
88
  /** 文件上传按钮. */
84
89
  BUTTON_UPLOAD = "BUTTON_UPLOAD"
85
90
  }
@@ -95,7 +100,7 @@ export declare const enum KG_FORM_CONTEXT {
95
100
  /**
96
101
  * 表格单元格的显示类型.
97
102
  * @see VarGridDetail.display_type_properties
98
- * @see IKgGridDetailDisplayTypeProperties
103
+ * @see IKgGridDetailDisplayTypeProps
99
104
  */
100
105
  export declare const enum KG_TABLE_CELL_DISPLAY_TYPE {
101
106
  /** 布尔数据, 使用 KgYesOrNo 组件显示. */
@@ -111,12 +116,16 @@ export declare const enum KG_TABLE_CELL_DISPLAY_TYPE {
111
116
  /** 显示为超链接, 点击跳转到其他路由. */
112
117
  ROUTE_LINK = "ROUTE_LINK",
113
118
  /**
114
- * 显示描述字段.
115
- * 假如原字段为 'status', 则实际上会显示描述字段 'status_dsc(或者 statusDsc)' 的值.
116
- * 默认, 描述字段是原字段加上 '_dsc(或者 Dsc)' 后缀, 比如原字段为 'status', 则描述字段为 'status_dsc(或者 statusDsc)'.
117
- * 可以通过 {@link IKgGridDetailDisplayTypeProperties.DESC.dscFieldName} 设置自定义的描述字段名.
119
+ * <p>显示描述字段.</p>
120
+ * <p>假如原字段为 'status', 则实际上会显示描述字段 'status_dsc(或者 statusDsc)' 的值,</p>
121
+ * <p>默认, 描述字段是原字段加上 '_dsc(或者 Dsc)' 后缀, 比如原字段为 'status', 则描述字段为 'status_dsc(或者 statusDsc)',</p>
122
+ * <p>可以通过 {@link IKgGridDetailDisplayTypeProps.DESC.dscFieldName} 设置自定义的描述字段名,</p>
123
+ */
124
+ DESC = "DESC",
125
+ /**
126
+ * <p>显示为图片, 点击可以预览.</p>
118
127
  */
119
- DESC = "DESC"
128
+ IMAGE = "IMAGE"
120
129
  }
121
130
  /** 按钮类型. */
122
131
  export declare const enum KG_BUTTON_TYPE {
@@ -23,7 +23,7 @@ export interface Menu {
23
23
  export declare type IKgLocale = 'zh_CN' | 'en' | 'ru' | 'ja' | 'ko';
24
24
  /**
25
25
  * 按钮确认弹窗的参数.
26
- * <p>对应于 {@link VarButton.modal_props} 字段.</p>
26
+ * <p>对应于 {@link VarButton#modal_props} 字段.</p>
27
27
  */
28
28
  export declare type IKgButtonModalProps = ModalFuncProps & {
29
29
  /** 是否隐藏取消按钮. */
@@ -31,7 +31,7 @@ export declare type IKgButtonModalProps = ModalFuncProps & {
31
31
  };
32
32
  /**
33
33
  * <p>提交弹窗的配置参数.</p>
34
- * <p>对应于 {@link VarSubmitConfig.props} 字段.</p>
34
+ * <p>对应于 {@link VarSubmitConfig#props} 字段.</p>
35
35
  */
36
36
  export interface IKgSubmitConfigProps {
37
37
  /** 创建时, 确认按钮的文本对应的变量名. */
@@ -89,6 +89,20 @@ export interface IKgVariableConfigProps {
89
89
  */
90
90
  allowClear?: boolean;
91
91
  };
92
+ IMAGE: {
93
+ /**
94
+ * 宽度.
95
+ *
96
+ * @default 100
97
+ */
98
+ width?: number;
99
+ /**
100
+ * 宽度.
101
+ *
102
+ * @default 100
103
+ */
104
+ height?: number;
105
+ };
92
106
  }
93
107
  /**
94
108
  * 对应于 {@link VarGridDetail.display_type_properties} 字段, 根据显示类型, 设置额外的参数.
@@ -169,4 +183,18 @@ export interface IKgGridDetailDisplayTypeProps {
169
183
  color?: string;
170
184
  }>;
171
185
  };
186
+ IMAGE: {
187
+ /**
188
+ * 宽度.
189
+ *
190
+ * @default 29
191
+ */
192
+ width?: number;
193
+ /**
194
+ * 宽度.
195
+ *
196
+ * @default 29
197
+ */
198
+ height?: number;
199
+ };
172
200
  }