@next-bricks/form 1.4.0 → 1.5.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.
@@ -2,15 +2,22 @@ import React from "react";
2
2
  import "@next-core/theme";
3
3
  import { FormItemElementBase, MessageBody } from "@next-shared/form";
4
4
  import type { FormItemProps } from "../form-item/index.jsx";
5
- interface EoAutoCompleteComponentProps extends FormItemProps {
5
+ export interface AutoCompleteProps extends FormItemProps {
6
6
  curElement?: HTMLElement;
7
- value?: any;
7
+ value?: string;
8
8
  options?: string[] | OptionType[];
9
9
  placeholder?: string;
10
10
  inputStyle?: React.CSSProperties;
11
11
  disabled?: boolean;
12
12
  filterByCaption?: boolean;
13
- onChange?: (value: any) => void;
13
+ validateState?: string;
14
+ onChange?: (v: any) => void;
15
+ }
16
+ export interface AutoCompleteEvents {
17
+ change: CustomEvent<string>;
18
+ }
19
+ export interface AutoCompleteEventsMap {
20
+ onChange: "change";
14
21
  }
15
22
  export interface Option {
16
23
  label: string;
@@ -28,7 +35,7 @@ export type OptionType = Option | OptionGroup;
28
35
  *
29
36
  * @category form-input-basic
30
37
  */
31
- export declare class EoAutoComplete extends FormItemElementBase {
38
+ export declare class AutoComplete extends FormItemElementBase {
32
39
  #private;
33
40
  /**
34
41
  * 字段名称
@@ -79,5 +86,4 @@ export declare class EoAutoComplete extends FormItemElementBase {
79
86
  handleInputChange: (value: string) => void;
80
87
  render(): React.JSX.Element;
81
88
  }
82
- export declare function EoAutoCompleteComponent(props: EoAutoCompleteComponentProps): React.JSX.Element;
83
- export {};
89
+ export declare function EoAutoCompleteComponent(props: AutoCompleteProps): React.JSX.Element;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@next-bricks/form",
3
- "version": "1.4.0",
3
+ "version": "1.5.0",
4
4
  "homepage": "https://github.com/easyops-cn/next-bricks/tree/master/bricks/form",
5
5
  "repository": {
6
6
  "type": "git",
@@ -43,5 +43,5 @@
43
43
  "@next-bricks/icons": "*",
44
44
  "@next-bricks/illustrations": "*"
45
45
  },
46
- "gitHead": "2a943abb329b09fbb01de9d37c13990fca637b17"
46
+ "gitHead": "fe516f9a8844e037bceeb514ef042d082512a0b1"
47
47
  }