@ultraviolet/form 2.14.4 → 2.14.5

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.
package/README.md CHANGED
@@ -5,7 +5,7 @@
5
5
  Ultraviolet Form is an extension of Ultraviolet UI including everything to build forms using React.
6
6
  It is using [React Hook Form](https://react-hook-form.com/) under the hood.
7
7
 
8
- ## Installation
8
+ ## Get Started
9
9
 
10
10
  ```sh
11
11
  $ pnpm add @ultraviolet/form @emotion/react @emotion/styled
@@ -23,6 +23,7 @@ const NumberInputFieldV2 = ({
23
23
  success,
24
24
  helper,
25
25
  rules,
26
+ controls = true,
26
27
  "aria-label": ariaLabel,
27
28
  "data-testid": dataTestId,
28
29
  required,
@@ -58,6 +59,6 @@ const NumberInputFieldV2 = ({
58
59
  label: label ?? "",
59
60
  max,
60
61
  min
61
- }, error), success, helper, tooltip, unit, "aria-label": ariaLabel, autoFocus, readOnly, required });
62
+ }, error), success, helper, tooltip, unit, "aria-label": ariaLabel, autoFocus, readOnly, required, controls });
62
63
  };
63
64
  exports.NumberInputFieldV2 = NumberInputFieldV2;
@@ -2,10 +2,10 @@ import { NumberInputV2 } from '@ultraviolet/ui';
2
2
  import type { ComponentProps } from 'react';
3
3
  import type { FieldPath, FieldValues } from 'react-hook-form';
4
4
  import type { BaseFieldProps } from '../../types';
5
- type NumberInputV2Props<TFieldValues extends FieldValues, TName extends FieldPath<TFieldValues>> = BaseFieldProps<TFieldValues, TName> & Partial<Pick<ComponentProps<typeof NumberInputV2>, 'disabled' | 'id' | 'onBlur' | 'onChange' | 'onFocus' | 'value' | 'data-testid' | 'label' | 'tooltip' | 'unit' | 'size' | 'step' | 'className' | 'placeholder' | 'error' | 'success' | 'helper' | 'labelDescription' | 'aria-label' | 'autoFocus' | 'readOnly' | 'min' | 'max'>> & {
5
+ type NumberInputV2Props<TFieldValues extends FieldValues, TName extends FieldPath<TFieldValues>> = BaseFieldProps<TFieldValues, TName> & Partial<Pick<ComponentProps<typeof NumberInputV2>, 'disabled' | 'id' | 'onBlur' | 'onChange' | 'onFocus' | 'value' | 'data-testid' | 'label' | 'tooltip' | 'unit' | 'size' | 'step' | 'className' | 'placeholder' | 'error' | 'success' | 'helper' | 'labelDescription' | 'aria-label' | 'autoFocus' | 'readOnly' | 'min' | 'max' | 'controls'>> & {
6
6
  className?: string;
7
7
  name: string;
8
8
  required?: boolean;
9
9
  };
10
- export declare const NumberInputFieldV2: <TFieldValues extends FieldValues, TName extends FieldPath<TFieldValues> = FieldPath<TFieldValues>>({ disabled, max, min, name, onChange, onBlur, size, step, unit, tooltip, className, label, labelDescription, id, placeholder, success, helper, rules, "aria-label": ariaLabel, "data-testid": dataTestId, required, autoFocus, readOnly, shouldUnregister, }: NumberInputV2Props<TFieldValues, TName>) => import("@emotion/react/jsx-runtime").JSX.Element;
10
+ export declare const NumberInputFieldV2: <TFieldValues extends FieldValues, TName extends FieldPath<TFieldValues> = FieldPath<TFieldValues>>({ disabled, max, min, name, onChange, onBlur, size, step, unit, tooltip, className, label, labelDescription, id, placeholder, success, helper, rules, controls, "aria-label": ariaLabel, "data-testid": dataTestId, required, autoFocus, readOnly, shouldUnregister, }: NumberInputV2Props<TFieldValues, TName>) => import("@emotion/react/jsx-runtime").JSX.Element;
11
11
  export {};
@@ -21,6 +21,7 @@ const NumberInputFieldV2 = ({
21
21
  success,
22
22
  helper,
23
23
  rules,
24
+ controls = true,
24
25
  "aria-label": ariaLabel,
25
26
  "data-testid": dataTestId,
26
27
  required,
@@ -56,7 +57,7 @@ const NumberInputFieldV2 = ({
56
57
  label: label ?? "",
57
58
  max,
58
59
  min
59
- }, error), success, helper, tooltip, unit, "aria-label": ariaLabel, autoFocus, readOnly, required });
60
+ }, error), success, helper, tooltip, unit, "aria-label": ariaLabel, autoFocus, readOnly, required, controls });
60
61
  };
61
62
  export {
62
63
  NumberInputFieldV2
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ultraviolet/form",
3
- "version": "2.14.4",
3
+ "version": "2.14.5",
4
4
  "description": "Ultraviolet Form",
5
5
  "homepage": "https://github.com/scaleway/ultraviolet#readme",
6
6
  "repository": {
@@ -60,7 +60,7 @@
60
60
  "devDependencies": {
61
61
  "@babel/core": "7.24.7",
62
62
  "@types/final-form-focus": "1.1.7",
63
- "@types/react": "18.3.1",
63
+ "@types/react": "18.3.3",
64
64
  "@types/react-dom": "18.3.0",
65
65
  "react": "18.3.1",
66
66
  "react-dom": "18.3.1",
@@ -72,7 +72,7 @@
72
72
  "@emotion/styled": "11.11.5",
73
73
  "react-select": "5.8.0",
74
74
  "react-hook-form": "7.51.5",
75
- "@ultraviolet/ui": "1.55.3",
75
+ "@ultraviolet/ui": "1.56.0",
76
76
  "@ultraviolet/themes": "1.12.0"
77
77
  },
78
78
  "scripts": {