@kengic/vue 0.24.0 → 0.24.1-beta.1

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.
@@ -7,11 +7,11 @@ export interface IUseKgButton {
7
7
  * <p>调用此方法相当于手动触发某个按钮的点击事件.</p>
8
8
  *
9
9
  * @param param.type 按钮类型.
10
- * @param param.variableName 按钮变量名称.
10
+ * @param param.varName 按钮变量名称.
11
11
  */
12
12
  click(param: {
13
- type: KG__VAR_BUTTON__TYPE;
14
- variableName?: string;
13
+ type?: KG__VAR_BUTTON__TYPE;
14
+ varName?: string;
15
15
  }): void;
16
16
  /**
17
17
  * <p>「当前按钮」.</p>
@@ -80,9 +80,9 @@ export interface IUseKgButtonStoreActions {
80
80
  *
81
81
  * @param formID 界面标识.
82
82
  * @param type 按钮类型.
83
- * @param variableName 按钮变量名称.
83
+ * @param varName 按钮变量名称.
84
84
  */
85
- click(formID: string, type: KG__VAR_BUTTON__TYPE, variableName?: string): void;
85
+ click(formID: string, type?: KG__VAR_BUTTON__TYPE, varName?: string): void;
86
86
  dispose(formID: string | null | undefined): void;
87
87
  /**
88
88
  * 触发事件.
@@ -134,7 +134,7 @@ export declare const getProps: () => {
134
134
  prefixCls: StringConstructor;
135
135
  type: PropType<import("ant-design-vue/lib/button").ButtonType>;
136
136
  htmlType: {
137
- type: PropType<import("ant-design-vue/es/button/buttonTypes").ButtonHTMLType>;
137
+ type: PropType<import("ant-design-vue/es/button/buttonTypes").ButtonHTMLType>; /** 页面上专门添加了一个特殊的元素, 通过它可以获取其他元素对象. */
138
138
  default: string;
139
139
  };
140
140
  shape: {
@@ -182,7 +182,7 @@ export declare const getProps: () => {
182
182
  prefixCls: StringConstructor;
183
183
  type: PropType<import("ant-design-vue/lib/button").ButtonType>;
184
184
  htmlType: {
185
- type: PropType<import("ant-design-vue/es/button/buttonTypes").ButtonHTMLType>;
185
+ type: PropType<import("ant-design-vue/es/button/buttonTypes").ButtonHTMLType>; /** 页面上专门添加了一个特殊的元素, 通过它可以获取其他元素对象. */
186
186
  default: string;
187
187
  };
188
188
  shape: {
@@ -398,7 +398,7 @@ declare const _default: import("vue").DefineComponent<{
398
398
  prefixCls: StringConstructor;
399
399
  type: PropType<import("ant-design-vue/lib/button").ButtonType>;
400
400
  htmlType: {
401
- type: PropType<import("ant-design-vue/es/button/buttonTypes").ButtonHTMLType>;
401
+ type: PropType<import("ant-design-vue/es/button/buttonTypes").ButtonHTMLType>; /** 页面上专门添加了一个特殊的元素, 通过它可以获取其他元素对象. */
402
402
  default: string;
403
403
  };
404
404
  shape: {
@@ -446,7 +446,7 @@ declare const _default: import("vue").DefineComponent<{
446
446
  prefixCls: StringConstructor;
447
447
  type: PropType<import("ant-design-vue/lib/button").ButtonType>;
448
448
  htmlType: {
449
- type: PropType<import("ant-design-vue/es/button/buttonTypes").ButtonHTMLType>;
449
+ type: PropType<import("ant-design-vue/es/button/buttonTypes").ButtonHTMLType>; /** 页面上专门添加了一个特殊的元素, 通过它可以获取其他元素对象. */
450
450
  default: string;
451
451
  };
452
452
  shape: {
@@ -660,7 +660,7 @@ declare const _default: import("vue").DefineComponent<{
660
660
  prefixCls: StringConstructor;
661
661
  type: PropType<import("ant-design-vue/lib/button").ButtonType>;
662
662
  htmlType: {
663
- type: PropType<import("ant-design-vue/es/button/buttonTypes").ButtonHTMLType>;
663
+ type: PropType<import("ant-design-vue/es/button/buttonTypes").ButtonHTMLType>; /** 页面上专门添加了一个特殊的元素, 通过它可以获取其他元素对象. */
664
664
  default: string;
665
665
  };
666
666
  shape: {
@@ -708,7 +708,7 @@ declare const _default: import("vue").DefineComponent<{
708
708
  prefixCls: StringConstructor;
709
709
  type: PropType<import("ant-design-vue/lib/button").ButtonType>;
710
710
  htmlType: {
711
- type: PropType<import("ant-design-vue/es/button/buttonTypes").ButtonHTMLType>;
711
+ type: PropType<import("ant-design-vue/es/button/buttonTypes").ButtonHTMLType>; /** 页面上专门添加了一个特殊的元素, 通过它可以获取其他元素对象. */
712
712
  default: string;
713
713
  };
714
714
  shape: {
@@ -7,18 +7,20 @@ import { IKgModalProps } from './KgModal';
7
7
  * @param param.domRef 页面特殊元素对象.
8
8
  */
9
9
  export declare function useDragToMove(param: {
10
- getProps: Ref<IKgModalProps>;
11
10
  domRef: Ref<HTMLDivElement | null>;
11
+ getProps: Ref<IKgModalProps>;
12
12
  }): void;
13
13
  /**
14
14
  * 拖拽改变大小.
15
15
  *
16
- * @param param.getProps 组件参数.
17
- * @param param.domRef 页面特殊元素对象.
16
+ * @param param.props 组件参数.
17
+ * @param param.domRef 页面上的那个特殊元素对象, 专门用于获取其他元素对象.
18
+ * @param param.getProps 计算后的组件参数.
18
19
  */
19
20
  export declare function useDragToResize(param: {
20
- getProps: Ref<IKgModalProps>;
21
+ props: IKgModalProps;
21
22
  domRef: Ref<HTMLDivElement | null>;
23
+ getProps: Ref<IKgModalProps>;
22
24
  }): {
23
25
  /**
24
26
  * 鼠标按下事件.
@@ -30,4 +32,8 @@ export declare function useDragToResize(param: {
30
32
  event: MouseEvent;
31
33
  handleType: "left" | "right" | "top" | "bottom" | "top-left" | "top-right" | "bottom-right" | "bottom-left";
32
34
  }) => void;
35
+ /**
36
+ * 弹窗宽度.
37
+ */
38
+ width: Ref<string | number>;
33
39
  };
@@ -2,27 +2,103 @@ import { ExtractPropTypes, PropType } from 'vue';
2
2
  import { IKgProps, IKgSlots } from './index.vm';
3
3
  import './KgVar.less';
4
4
  export declare const getProps: () => {
5
- /** 插槽. 通过该参数可以给下面任意的子组件传递 slots 插槽, 当前支持的插槽可以参考 {@link IKgSlots} 中的定义. */
6
- kgSlots: PropType<IKgSlots>;
7
- /** 参数. 通过该参数可以给下面任意的子组件传递 props 参数, 当前支持的参数可以参考 {@link IKgProps} 中的定义. */
8
- kgProps: PropType<IKgProps>;
9
- /** 是否使用灰色背景. */
5
+ /**
6
+ * 是否使用灰色背景.
7
+ *
8
+ * @default false
9
+ */
10
10
  KgBackgroundGray: PropType<boolean>;
11
+ /**
12
+ * 界面标识.
13
+ *
14
+ * @default undefined
15
+ */
16
+ kgFormID: PropType<string>;
17
+ /**
18
+ * <p>界面层级.</p>
19
+ * <p>比如普通界面的层级为 0, 弹窗的界面层级为 1, 弹窗中的弹窗的界面层级为 2, 以此类推.</p>
20
+ *
21
+ * @default 0
22
+ */
23
+ kgLevel: {
24
+ type: PropType<number>;
25
+ default: number;
26
+ };
27
+ /**
28
+ * 参数. 通过该参数可以给下面任意的子组件传递 props 参数, 当前支持的参数可以参考 {@link IKgProps} 中的定义.
29
+ */
30
+ kgProps: PropType<IKgProps>;
31
+ /**
32
+ * 插槽. 通过该参数可以给下面任意的子组件传递 slots 插槽, 当前支持的插槽可以参考 {@link IKgSlots} 中的定义.
33
+ */
34
+ kgSlots: PropType<IKgSlots>;
11
35
  };
36
+ /** @deprecated */
12
37
  export declare type IKgVarProps = Partial<ExtractPropTypes<ReturnType<typeof getProps>>>;
38
+ export declare type KgVarProps = Partial<ExtractPropTypes<ReturnType<typeof getProps>>>;
13
39
  declare const _default: import("vue").DefineComponent<{
14
- /** 插槽. 通过该参数可以给下面任意的子组件传递 slots 插槽, 当前支持的插槽可以参考 {@link IKgSlots} 中的定义. */
15
- kgSlots: PropType<IKgSlots>;
16
- /** 参数. 通过该参数可以给下面任意的子组件传递 props 参数, 当前支持的参数可以参考 {@link IKgProps} 中的定义. */
17
- kgProps: PropType<IKgProps>;
18
- /** 是否使用灰色背景. */
40
+ /**
41
+ * 是否使用灰色背景.
42
+ *
43
+ * @default false
44
+ */
19
45
  KgBackgroundGray: PropType<boolean>;
20
- }, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<ExtractPropTypes<{
21
- /** 插槽. 通过该参数可以给下面任意的子组件传递 slots 插槽, 当前支持的插槽可以参考 {@link IKgSlots} 中的定义. */
22
- kgSlots: PropType<IKgSlots>;
23
- /** 参数. 通过该参数可以给下面任意的子组件传递 props 参数, 当前支持的参数可以参考 {@link IKgProps} 中的定义. */
46
+ /**
47
+ * 界面标识.
48
+ *
49
+ * @default undefined
50
+ */
51
+ kgFormID: PropType<string>;
52
+ /**
53
+ * <p>界面层级.</p>
54
+ * <p>比如普通界面的层级为 0, 弹窗的界面层级为 1, 弹窗中的弹窗的界面层级为 2, 以此类推.</p>
55
+ *
56
+ * @default 0
57
+ */
58
+ kgLevel: {
59
+ type: PropType<number>;
60
+ default: number;
61
+ };
62
+ /**
63
+ * 参数. 通过该参数可以给下面任意的子组件传递 props 参数, 当前支持的参数可以参考 {@link IKgProps} 中的定义.
64
+ */
24
65
  kgProps: PropType<IKgProps>;
25
- /** 是否使用灰色背景. */
66
+ /**
67
+ * 插槽. 通过该参数可以给下面任意的子组件传递 slots 插槽, 当前支持的插槽可以参考 {@link IKgSlots} 中的定义.
68
+ */
69
+ kgSlots: PropType<IKgSlots>;
70
+ }, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<ExtractPropTypes<{
71
+ /**
72
+ * 是否使用灰色背景.
73
+ *
74
+ * @default false
75
+ */
26
76
  KgBackgroundGray: PropType<boolean>;
27
- }>>, {}>;
77
+ /**
78
+ * 界面标识.
79
+ *
80
+ * @default undefined
81
+ */
82
+ kgFormID: PropType<string>;
83
+ /**
84
+ * <p>界面层级.</p>
85
+ * <p>比如普通界面的层级为 0, 弹窗的界面层级为 1, 弹窗中的弹窗的界面层级为 2, 以此类推.</p>
86
+ *
87
+ * @default 0
88
+ */
89
+ kgLevel: {
90
+ type: PropType<number>;
91
+ default: number;
92
+ };
93
+ /**
94
+ * 参数. 通过该参数可以给下面任意的子组件传递 props 参数, 当前支持的参数可以参考 {@link IKgProps} 中的定义.
95
+ */
96
+ kgProps: PropType<IKgProps>;
97
+ /**
98
+ * 插槽. 通过该参数可以给下面任意的子组件传递 slots 插槽, 当前支持的插槽可以参考 {@link IKgSlots} 中的定义.
99
+ */
100
+ kgSlots: PropType<IKgSlots>;
101
+ }>>, {
102
+ kgLevel: number;
103
+ }>;
28
104
  export default _default;
@@ -1,4 +1,4 @@
1
- export { default as KgVar, type IKgVarProps } from './KgVar';
1
+ export { default as KgVar, type IKgVarProps, type KgVarProps } from './KgVar';
2
2
  export * from './index.hooks';
3
3
  export * from './index.store';
4
4
  export * from './index.vm';
@@ -244,6 +244,7 @@ declare const _default: {
244
244
  export: string;
245
245
  exportSuccess: string;
246
246
  formId: string;
247
+ formName: string;
247
248
  formValidationFail: string;
248
249
  import: string;
249
250
  'import-template': string;
@@ -243,6 +243,7 @@ declare const _default: {
243
243
  export: string;
244
244
  exportSuccess: string;
245
245
  formId: string;
246
+ formName: string;
246
247
  formValidationFail: string;
247
248
  import: string;
248
249
  'import-template': string;
@@ -1,4 +1,6 @@
1
+ import { KgVarProps } from '../../components';
1
2
  import './KgVarContainer.less';
2
3
  export declare function KgVarContainer(param: {
3
4
  formID: string | null | undefined;
5
+ props?: KgVarProps;
4
6
  }): import("vue").DefineComponent<{}, () => null, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}> | import("vue").DefineComponent<{}, () => JSX.Element, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
@@ -18,7 +18,7 @@ export declare class KgVarUtil {
18
18
  * @param param.buttonVarName 「变量配置:表单控件」所属的按钮的变量名称.
19
19
  * @param param.formID 界面标识.
20
20
  * @param param.value 原始的值.
21
- * @param param.variableName 变量名称.
21
+ * @param param.varName 变量名称.
22
22
  * @return {} 转换后的合法的值.
23
23
  */
24
24
  static transformFormItemValue(param: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kengic/vue",
3
- "version": "0.24.0",
3
+ "version": "0.24.1-beta.1",
4
4
  "scripts": {
5
5
  "build": "npm run switch-node-version && rimraf dist && vue-tsc && vite build",
6
6
  "build:dev": "npm run switch-node-version && rimraf dist && vue-tsc && vite build --mode development",