@ultraviolet/form 1.5.1 → 1.7.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.
@@ -20,6 +20,7 @@ const CheckboxField = /*#__PURE__*/forwardRef((_ref, ref) => {
20
20
  onFocus,
21
21
  value,
22
22
  helper,
23
+ tooltip,
23
24
  'data-testid': dataTestId
24
25
  } = _ref;
25
26
  const {
@@ -66,6 +67,7 @@ const CheckboxField = /*#__PURE__*/forwardRef((_ref, ref) => {
66
67
  value: input.value,
67
68
  required: required,
68
69
  "data-testid": dataTestId,
70
+ tooltip: tooltip,
69
71
  children: children
70
72
  });
71
73
  });
@@ -16,7 +16,8 @@ const RadioField = _ref => {
16
16
  onFocus,
17
17
  required,
18
18
  validate,
19
- value
19
+ value,
20
+ tooltip
20
21
  } = _ref;
21
22
  const {
22
23
  getError
@@ -59,7 +60,8 @@ const RadioField = _ref => {
59
60
  },
60
61
  required: required,
61
62
  value: input.value,
62
- label: label
63
+ label: label,
64
+ tooltip: tooltip
63
65
  });
64
66
  };
65
67
 
package/dist/index.d.ts CHANGED
@@ -85,6 +85,7 @@ declare const CheckboxField: react.ForwardRefExoticComponent<BaseFieldProps<stri
85
85
  "data-visibility"?: string | undefined;
86
86
  required?: boolean | undefined;
87
87
  'data-testid'?: string | undefined;
88
+ tooltip?: string | undefined;
88
89
  } & Pick<react.InputHTMLAttributes<HTMLInputElement>, "name" | "value" | "onFocus" | "onBlur" | "autoFocus" | "id" | "onChange"> & (({
89
90
  "aria-label"?: undefined;
90
91
  } & {
@@ -93,7 +94,7 @@ declare const CheckboxField: react.ForwardRefExoticComponent<BaseFieldProps<stri
93
94
  children?: undefined;
94
95
  } & {
95
96
  'aria-label': string;
96
- }))) & react.RefAttributes<HTMLInputElement>, "value" | "disabled" | "progress" | "onFocus" | "onBlur" | "onChange" | "size" | "data-testid" | "helper">> & {
97
+ }))) & react.RefAttributes<HTMLInputElement>, "value" | "disabled" | "progress" | "onFocus" | "onBlur" | "onChange" | "size" | "data-testid" | "helper" | "tooltip">> & {
97
98
  name: string;
98
99
  label?: string | undefined;
99
100
  className?: string | undefined;
@@ -116,6 +117,7 @@ declare const CheckboxGroupField: {
116
117
  "data-visibility"?: string | undefined;
117
118
  required?: boolean | undefined;
118
119
  'data-testid'?: string | undefined;
120
+ tooltip?: string | undefined;
119
121
  } & Pick<react.InputHTMLAttributes<HTMLInputElement>, "name" | "value" | "onFocus" | "onBlur" | "autoFocus" | "id" | "onChange"> & (({
120
122
  "aria-label"?: undefined;
121
123
  } & {
@@ -165,12 +167,12 @@ type FormProps<FormValues = unknown> = {
165
167
  declare const Form: <FormValues>({ children, onRawSubmit, errors, initialValues, validateOnBlur, validate, name, render, mutators, keepDirtyOnReinitialize, className, }: FormProps<FormValues>) => JSX.Element;
166
168
 
167
169
  type RadioValue$1 = NonNullable<ComponentProps<typeof Radio>['value']>;
168
- type RadioFieldProps<T = RadioValue$1, K = string> = BaseFieldProps<T, K> & Partial<Pick<ComponentProps<typeof Radio>, 'disabled' | 'id' | 'onBlur' | 'onChange' | 'onFocus' | 'value' | 'data-testid' | 'label'>> & {
170
+ type RadioFieldProps<T = RadioValue$1, K = string> = BaseFieldProps<T, K> & Partial<Pick<ComponentProps<typeof Radio>, 'disabled' | 'id' | 'onBlur' | 'onChange' | 'onFocus' | 'value' | 'data-testid' | 'label' | 'tooltip'>> & {
169
171
  className?: string;
170
172
  name: string;
171
173
  required?: boolean;
172
174
  };
173
- declare const RadioField: ({ className, "data-testid": dataTestId, disabled, id, label, name, onBlur, onChange, onFocus, required, validate, value, }: RadioFieldProps) => JSX.Element;
175
+ declare const RadioField: ({ className, "data-testid": dataTestId, disabled, id, label, name, onBlur, onChange, onFocus, required, validate, value, tooltip, }: RadioFieldProps) => JSX.Element;
174
176
 
175
177
  type SelectOption = {
176
178
  value: string;
@@ -622,7 +624,6 @@ declare const TextInputField: react.ForwardRefExoticComponent<BaseFieldProps<Tex
622
624
  accept?: string | undefined;
623
625
  alt?: string | undefined;
624
626
  capture?: boolean | "user" | "environment" | undefined;
625
- crossOrigin?: "" | "anonymous" | "use-credentials" | undefined;
626
627
  enterKeyHint?: "search" | "enter" | "done" | "go" | "next" | "previous" | "send" | undefined;
627
628
  formAction?: string | undefined;
628
629
  formEncType?: string | undefined;
@@ -697,6 +698,7 @@ declare const RadioGroupField: {
697
698
  'aria-label'?: string | undefined;
698
699
  'data-testid'?: string | undefined;
699
700
  helper?: react.ReactNode;
701
+ tooltip?: string | undefined;
700
702
  onKeyDown?: react.KeyboardEventHandler<HTMLInputElement> | undefined;
701
703
  }) => _emotion_react_jsx_runtime.JSX.Element;
702
704
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ultraviolet/form",
3
- "version": "1.5.1",
3
+ "version": "1.7.1",
4
4
  "description": "Ultraviolet Form",
5
5
  "homepage": "https://github.com/scaleway/ultraviolet#readme",
6
6
  "repository": {
@@ -38,10 +38,10 @@
38
38
  "react-dom": "18.x"
39
39
  },
40
40
  "devDependencies": {
41
- "@babel/core": "7.22.15",
41
+ "@babel/core": "7.22.17",
42
42
  "@types/final-form-focus": "1.1.4",
43
- "@types/react": "18.2.14",
44
- "@types/react-dom": "18.2.6",
43
+ "@types/react": "18.2.21",
44
+ "@types/react-dom": "18.2.7",
45
45
  "react": "18.2.0",
46
46
  "react-dom": "18.2.0"
47
47
  },
@@ -55,6 +55,6 @@
55
55
  "react-final-form": "6.5.9",
56
56
  "react-final-form-arrays": "3.1.4",
57
57
  "react-select": "5.7.4",
58
- "@ultraviolet/ui": "1.11.1"
58
+ "@ultraviolet/ui": "1.13.1"
59
59
  }
60
60
  }