formica-ui-lib 1.0.237 → 1.0.239

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.
@@ -5,10 +5,13 @@ export interface InputProps {
5
5
  type?: "text" | "email" | "password" | "tel" | "number" | "search";
6
6
  value?: string;
7
7
  placeholder?: string;
8
+ ariaLabel?: string;
8
9
  disabled?: boolean;
9
10
  readOnly?: boolean;
10
11
  required?: boolean;
11
12
  hasError?: boolean;
13
+ clearable?: boolean;
14
+ clearLabel?: string;
12
15
  className?: string;
13
16
  inputClassName?: string;
14
17
  autoComplete?: string;
@@ -19,6 +22,9 @@ export interface InputProps {
19
22
  onBlur?: (event: React.FocusEvent<HTMLInputElement>) => void;
20
23
  onFocus?: (event: React.FocusEvent<HTMLInputElement>) => void;
21
24
  onKeyDown?: (event: React.KeyboardEvent<HTMLInputElement>) => void;
25
+ onClear?: (payload: {
26
+ value: string;
27
+ }) => void;
22
28
  }
23
29
  export interface InputFieldProps extends InputProps {
24
30
  label?: string;
@@ -1,2 +1,7 @@
1
1
  import { InputProps } from "../../atoms/input/inputProps";
2
- export type SearchBarProps = Omit<InputProps, "type">;
2
+ export interface SearchBarSubmitPayload {
3
+ value: string;
4
+ }
5
+ export type SearchBarProps = Omit<InputProps, "type" | "leadingIcon" | "trailingIcon" | "clearable"> & {
6
+ onSearchSubmit?: (payload: SearchBarSubmitPayload) => void;
7
+ };
@@ -3,7 +3,7 @@ export type DynamicFormFieldSeverity = "blocking" | "recommended" | "optional";
3
3
  export type DynamicFormFieldState = "neutral" | "valid" | "warning" | "error";
4
4
  export type DynamicFormFieldValue = string | number | null;
5
5
  export type DynamicFormDensity = "compact" | "comfortable";
6
- export type DynamicFormSeverityDisplay = "icon" | "label";
6
+ export type DynamicFormSeverityDisplay = "icon" | "label" | "none";
7
7
  export interface DynamicFormFieldOption {
8
8
  label: string;
9
9
  value: string;
@@ -24,6 +24,12 @@ export interface DynamicFormFieldConfig {
24
24
  helpText?: string;
25
25
  readOnly?: boolean;
26
26
  }
27
+ export interface DynamicFormFieldGroup {
28
+ id: string;
29
+ title: string;
30
+ description?: string;
31
+ fieldIds: string[];
32
+ }
27
33
  export interface DynamicFormFieldChangePayload {
28
34
  fieldId: string;
29
35
  value: DynamicFormFieldValue;
@@ -35,6 +41,7 @@ export interface DynamicFormProps {
35
41
  title?: string;
36
42
  description?: string;
37
43
  fields: DynamicFormFieldConfig[];
44
+ fieldGroups?: DynamicFormFieldGroup[];
38
45
  density?: DynamicFormDensity;
39
46
  severityDisplay?: DynamicFormSeverityDisplay;
40
47
  submitLabel?: string;