@mobileaction/action-kit 1.1.41 → 1.1.43

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.
@@ -0,0 +1,93 @@
1
+ import type { PropType as __PropType } from 'vue';
2
+ import { DefaultOptionType as OptionType } from "ant-design-vue/lib/select";
3
+ export interface MaAutocompleteProps {
4
+ value?: string | undefined;
5
+ options?: OptionType[] | undefined;
6
+ label?: string;
7
+ filterFn?: Function;
8
+ placeholder?: string;
9
+ prefixIcon?: string;
10
+ avatarUrl?: string;
11
+ open?: boolean;
12
+ }
13
+ declare const _sfc_main: import("vue").DefineComponent<{
14
+ value: {
15
+ type: __PropType<string>;
16
+ required: false;
17
+ };
18
+ options: {
19
+ type: __PropType<OptionType[]>;
20
+ required: false;
21
+ default: () => OptionType[];
22
+ };
23
+ label: {
24
+ type: __PropType<string>;
25
+ required: false;
26
+ };
27
+ filterFn: {
28
+ type: __PropType<Function>;
29
+ required: false;
30
+ default: (value: string, option: OptionType) => boolean;
31
+ };
32
+ placeholder: {
33
+ type: __PropType<string>;
34
+ required: false;
35
+ };
36
+ prefixIcon: {
37
+ type: __PropType<string>;
38
+ required: false;
39
+ };
40
+ avatarUrl: {
41
+ type: __PropType<string>;
42
+ required: false;
43
+ };
44
+ open: {
45
+ type: __PropType<boolean>;
46
+ required: false;
47
+ default: boolean;
48
+ };
49
+ }, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("search" | "update:value")[], "search" | "update:value", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
50
+ value: {
51
+ type: __PropType<string>;
52
+ required: false;
53
+ };
54
+ options: {
55
+ type: __PropType<OptionType[]>;
56
+ required: false;
57
+ default: () => OptionType[];
58
+ };
59
+ label: {
60
+ type: __PropType<string>;
61
+ required: false;
62
+ };
63
+ filterFn: {
64
+ type: __PropType<Function>;
65
+ required: false;
66
+ default: (value: string, option: OptionType) => boolean;
67
+ };
68
+ placeholder: {
69
+ type: __PropType<string>;
70
+ required: false;
71
+ };
72
+ prefixIcon: {
73
+ type: __PropType<string>;
74
+ required: false;
75
+ };
76
+ avatarUrl: {
77
+ type: __PropType<string>;
78
+ required: false;
79
+ };
80
+ open: {
81
+ type: __PropType<boolean>;
82
+ required: false;
83
+ default: boolean;
84
+ };
85
+ }>> & {
86
+ "onUpdate:value"?: (...args: any[]) => any;
87
+ onSearch?: (...args: any[]) => any;
88
+ }, {
89
+ options: OptionType[];
90
+ filterFn: Function;
91
+ open: boolean;
92
+ }>;
93
+ export default _sfc_main;
@@ -17,7 +17,7 @@ declare const _sfc_main: import("vue").DefineComponent<{
17
17
  default: string;
18
18
  };
19
19
  variant: {
20
- type: __PropType<"general" | "add-app" | "table" | "selection">;
20
+ type: __PropType<"table" | "general" | "add-app" | "selection">;
21
21
  required: false;
22
22
  default: string;
23
23
  };
@@ -44,7 +44,7 @@ declare const _sfc_main: import("vue").DefineComponent<{
44
44
  default: string;
45
45
  };
46
46
  variant: {
47
- type: __PropType<"general" | "add-app" | "table" | "selection">;
47
+ type: __PropType<"table" | "general" | "add-app" | "selection">;
48
48
  required: false;
49
49
  default: string;
50
50
  };
@@ -65,7 +65,7 @@ declare const _sfc_main: import("vue").DefineComponent<{
65
65
  required: false;
66
66
  };
67
67
  }>>, {
68
- variant: "general" | "add-app" | "table" | "selection";
68
+ variant: "table" | "general" | "add-app" | "selection";
69
69
  size: "small" | "medium" | "large";
70
70
  }>;
71
71
  export default _sfc_main;
@@ -90,7 +90,7 @@ declare const _sfc_main: import("vue").DefineComponent<{
90
90
  type: __PropType<string>;
91
91
  required: false;
92
92
  };
93
- }, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("change" | "currency-change" | "update:value" | "update:amountCurrency")[], "change" | "currency-change" | "update:value" | "update:amountCurrency", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
93
+ }, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("change" | "update:value" | "currency-change" | "update:amountCurrency" | "focus" | "focusout")[], "change" | "update:value" | "currency-change" | "update:amountCurrency" | "focus" | "focusout", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
94
94
  allowClear: {
95
95
  type: __PropType<boolean>;
96
96
  required: false;
@@ -163,9 +163,11 @@ declare const _sfc_main: import("vue").DefineComponent<{
163
163
  };
164
164
  }>> & {
165
165
  onChange?: (...args: any[]) => any;
166
+ onFocus?: (...args: any[]) => any;
166
167
  "onUpdate:value"?: (...args: any[]) => any;
167
168
  "onCurrency-change"?: (...args: any[]) => any;
168
169
  "onUpdate:amountCurrency"?: (...args: any[]) => any;
170
+ onFocusout?: (...args: any[]) => any;
169
171
  }, {
170
172
  type: MaInputType;
171
173
  size: MaInputSize;
@@ -75,7 +75,7 @@ declare const _sfc_main: import("vue").DefineComponent<{
75
75
  required: false;
76
76
  default: number;
77
77
  };
78
- }, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:visible" | "ok" | "cancel")[], "update:visible" | "ok" | "cancel", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
78
+ }, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:visible" | "cancel" | "ok")[], "update:visible" | "cancel" | "ok", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
79
79
  visible: {
80
80
  type: __PropType<boolean>;
81
81
  required: false;
@@ -141,7 +141,7 @@ declare const _sfc_main: import("vue").DefineComponent<{
141
141
  closable: boolean;
142
142
  width: number;
143
143
  visible: boolean;
144
- maskClosable: boolean;
145
144
  mask: boolean;
145
+ maskClosable: boolean;
146
146
  }>;
147
147
  export default _sfc_main;
@@ -15,7 +15,7 @@ export interface MaProgressProps {
15
15
  }
16
16
  declare const _sfc_main: import("vue").DefineComponent<{
17
17
  type: {
18
- type: __PropType<"line" | "circle" | "line-step" | "half-circle">;
18
+ type: __PropType<"circle" | "line" | "line-step" | "half-circle">;
19
19
  required: false;
20
20
  default: string;
21
21
  };
@@ -61,7 +61,7 @@ declare const _sfc_main: import("vue").DefineComponent<{
61
61
  };
62
62
  }, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
63
63
  type: {
64
- type: __PropType<"line" | "circle" | "line-step" | "half-circle">;
64
+ type: __PropType<"circle" | "line" | "line-step" | "half-circle">;
65
65
  required: false;
66
66
  default: string;
67
67
  };
@@ -106,7 +106,7 @@ declare const _sfc_main: import("vue").DefineComponent<{
106
106
  default: string;
107
107
  };
108
108
  }>>, {
109
- type: "line" | "circle" | "line-step" | "half-circle";
109
+ type: "circle" | "line" | "line-step" | "half-circle";
110
110
  color: "dark" | "blue" | "green" | "orange" | "red";
111
111
  showPercent: boolean;
112
112
  percentAlignment: "left" | "right";
@@ -238,9 +238,9 @@ declare const _sfc_main: import("vue").DefineComponent<{
238
238
  }, {
239
239
  value: string | number | string[] | number[];
240
240
  size: "default" | "small" | "large";
241
+ open: boolean;
241
242
  autoClearSearchValue: boolean;
242
243
  menuItemSelectedIcon: string;
243
- open: boolean;
244
244
  listHeight: number;
245
245
  }>;
246
246
  export default _sfc_main;
@@ -36,7 +36,7 @@ declare const _sfc_main: import("vue").DefineComponent<{
36
36
  required: false;
37
37
  };
38
38
  trigger: {
39
- type: __PropType<"click" | "hover" | "contextmenu" | "focus">;
39
+ type: __PropType<"focus" | "click" | "hover" | "contextmenu">;
40
40
  required: false;
41
41
  default: string;
42
42
  };
@@ -77,7 +77,7 @@ declare const _sfc_main: import("vue").DefineComponent<{
77
77
  required: false;
78
78
  };
79
79
  trigger: {
80
- type: __PropType<"click" | "hover" | "contextmenu" | "focus">;
80
+ type: __PropType<"focus" | "click" | "hover" | "contextmenu">;
81
81
  required: false;
82
82
  default: string;
83
83
  };
@@ -97,7 +97,7 @@ declare const _sfc_main: import("vue").DefineComponent<{
97
97
  }>>, {
98
98
  type: "primary" | "secondary";
99
99
  placement: TooltipPlacement;
100
- trigger: "click" | "hover" | "contextmenu" | "focus";
100
+ trigger: "focus" | "click" | "hover" | "contextmenu";
101
101
  defaultVisible: boolean;
102
102
  }>;
103
103
  export default _sfc_main;
package/dist/index.d.ts CHANGED
@@ -55,5 +55,6 @@ export { default as MaSideMenuAppButton } from './components/side-menu/app-butto
55
55
  export { default as MaSideMenuAddNewAppButton } from './components/side-menu/add-new-app-button/index.vue';
56
56
  export { default as MaProgress } from './components/progress/index.vue';
57
57
  export * from './components/progress/types';
58
+ export { default as MaAutoComplete } from './components/autocomplete/index.vue';
58
59
  export { ActionKitConfig } from './services/config';
59
60
  export { useActionKitConfig } from './composables/config';
@@ -0,0 +1,54 @@
1
+ import { DefaultOptionType as OptionType } from "ant-design-vue/lib/select";
2
+ export interface MaAutocompleteProps {
3
+ value?: string | undefined;
4
+ options?: OptionType[] | undefined;
5
+ label?: string;
6
+ filterFn?: Function;
7
+ placeholder?: string;
8
+ prefixIcon?: string;
9
+ avatarUrl?: string;
10
+ open?: boolean;
11
+ }
12
+ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<MaAutocompleteProps>, {
13
+ options: () => OptionType[];
14
+ filterFn: (value: string, option: OptionType) => boolean;
15
+ open: boolean;
16
+ }>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:value" | "search")[], "search" | "update:value", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<MaAutocompleteProps>, {
17
+ options: () => OptionType[];
18
+ filterFn: (value: string, option: OptionType) => boolean;
19
+ open: boolean;
20
+ }>>> & {
21
+ "onUpdate:value"?: (...args: any[]) => any;
22
+ onSearch?: (...args: any[]) => any;
23
+ }, {
24
+ options: OptionType[];
25
+ open: boolean;
26
+ filterFn: Function;
27
+ }>, {
28
+ default: (_: {}) => any;
29
+ option: (_: {
30
+ label: any;
31
+ value: string | number;
32
+ }) => any;
33
+ overlay: (_: {}) => any;
34
+ }>;
35
+ export default _default;
36
+ declare type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
37
+ declare type __VLS_TypePropsToRuntimeProps<T> = {
38
+ [K in keyof T]-?: {} extends Pick<T, K> ? {
39
+ type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
40
+ } : {
41
+ type: import('vue').PropType<T[K]>;
42
+ required: true;
43
+ };
44
+ };
45
+ declare type __VLS_WithDefaults<P, D> = {
46
+ [K in keyof Pick<P, keyof P>]: K extends keyof D ? P[K] & {
47
+ default: D[K];
48
+ } : P[K];
49
+ };
50
+ declare type __VLS_WithTemplateSlots<T, S> = T & {
51
+ new (): {
52
+ $slots: S;
53
+ };
54
+ };
@@ -0,0 +1,8 @@
1
+ import type { Meta, StoryFn } from '@storybook/vue3';
2
+ import MaAutocomplete from '../index.vue';
3
+ export declare const baseConfig: Meta<typeof MaAutocomplete>;
4
+ export declare const Template: StoryFn;
5
+ export declare const TemplateUserAvatar: StoryFn;
6
+ export declare const TemplateIcon: StoryFn;
7
+ export declare const TemplateCustomInput: StoryFn;
8
+ export declare const TemplateCustomAppInput: StoryFn;
@@ -0,0 +1,10 @@
1
+ import type { Meta, StoryObj } from '@storybook/vue3';
2
+ import type MaAutoComplete from '../index.vue';
3
+ declare const meta: Meta<typeof MaAutoComplete>;
4
+ export default meta;
5
+ declare type Story = StoryObj<typeof MaAutoComplete>;
6
+ export declare const Default: Story;
7
+ export declare const WithIcons: Story;
8
+ export declare const WithAvatar: Story;
9
+ export declare const CustomInput: Story;
10
+ export declare const CustomAppInput: Story;
@@ -24,8 +24,8 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
24
24
  onVisibleChange?: (...args: any[]) => any;
25
25
  }, {
26
26
  disabled: boolean;
27
+ placement: "bottomLeft" | "bottomRight" | "topLeft" | "topRight" | "bottom" | "top";
27
28
  destroyPopupOnHide: boolean;
28
- placement: "bottomLeft" | "bottom" | "bottomRight" | "topLeft" | "top" | "topRight";
29
29
  trigger: ("click" | "hover" | "contextmenu")[];
30
30
  visible: boolean;
31
31
  }>, {
@@ -21,10 +21,12 @@ export interface MaInputProps {
21
21
  declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<MaInputProps>, {
22
22
  type: "text";
23
23
  size: "small";
24
- }>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("change" | "currency-change" | "update:value" | "update:amountCurrency")[], "change" | "currency-change" | "update:value" | "update:amountCurrency", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<MaInputProps>, {
24
+ }>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("change" | "focus" | "currency-change" | "update:value" | "update:amountCurrency" | "focusout")[], "change" | "focus" | "currency-change" | "update:value" | "update:amountCurrency" | "focusout", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<MaInputProps>, {
25
25
  type: "text";
26
26
  size: "small";
27
27
  }>>> & {
28
+ onFocus?: (...args: any[]) => any;
29
+ onFocusout?: (...args: any[]) => any;
28
30
  onChange?: (...args: any[]) => any;
29
31
  "onUpdate:value"?: (...args: any[]) => any;
30
32
  "onCurrency-change"?: (...args: any[]) => any;
@@ -24,7 +24,7 @@ declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__
24
24
  }>>>, {
25
25
  type: "primary" | "secondary";
26
26
  placement: TooltipPlacement;
27
- trigger: "click" | "hover" | "contextmenu" | "focus";
27
+ trigger: "click" | "focus" | "hover" | "contextmenu";
28
28
  defaultVisible: boolean;
29
29
  }>, {
30
30
  default: (_: {}) => any;
@@ -56,5 +56,6 @@ export { default as MaSideMenuAppButton } from './components/side-menu/app-butto
56
56
  export { default as MaSideMenuAddNewAppButton } from './components/side-menu/add-new-app-button/index.vue';
57
57
  export { default as MaProgress } from './components/progress/index.vue';
58
58
  export * from './components/progress/types';
59
+ export { default as MaAutoComplete } from './components/autocomplete/index.vue';
59
60
  export { ActionKitConfig } from './services/config';
60
61
  export { useActionKitConfig } from './composables/config';