@ostack.tech/ui-kform 0.1.2 → 0.2.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.
Files changed (102) hide show
  1. package/dist/chunks/en-C1hDoCmB.js +135 -0
  2. package/dist/chunks/en-C1hDoCmB.js.map +1 -0
  3. package/dist/locales/en-GB.js +10 -0
  4. package/dist/locales/en-GB.js.map +1 -0
  5. package/dist/locales/en-US.js +10 -0
  6. package/dist/locales/en-US.js.map +1 -0
  7. package/dist/locales/fr.js +137 -0
  8. package/dist/locales/fr.js.map +1 -0
  9. package/dist/locales/pt.js +137 -0
  10. package/dist/locales/pt.js.map +1 -0
  11. package/dist/ostack-ui-kform.js +1129 -1472
  12. package/dist/ostack-ui-kform.js.map +1 -1
  13. package/dist/types/components/Annexes/Annex.d.ts +5 -5
  14. package/dist/types/components/Annexes/Annexes.d.ts +10 -10
  15. package/dist/types/components/Annexes/AnnexesContext.d.ts +5 -5
  16. package/dist/types/components/Annexes/AnnexesManager.d.ts +15 -15
  17. package/dist/types/components/Annexes/AnnexesMenu.d.ts +4 -4
  18. package/dist/types/components/Annexes/AnnexesTabList.d.ts +3 -3
  19. package/dist/types/components/CheckboxControl/CheckboxControl.d.ts +6 -6
  20. package/dist/types/components/CheckboxGroupControl/CheckboxGroupControl.d.ts +9 -9
  21. package/dist/types/components/ControlField/ControlField.d.ts +3 -3
  22. package/dist/types/components/ControlField/ControlFieldContext.d.ts +1 -2
  23. package/dist/types/components/DateControl/DateControl.d.ts +6 -6
  24. package/dist/types/components/DateRangeControl/DateRangeControl.d.ts +9 -9
  25. package/dist/types/components/FileControl/FileControl.d.ts +9 -9
  26. package/dist/types/components/FormApp/FormApp.d.ts +23 -15
  27. package/dist/types/components/FormApp/FormAppAutoFocus.d.ts +2 -0
  28. package/dist/types/components/FormApp/FormAppContext.d.ts +11 -13
  29. package/dist/types/components/FormApp/FormAppElement.d.ts +9 -0
  30. package/dist/types/components/FormApp/FormAppIssueMessages.d.ts +3 -3
  31. package/dist/types/components/FormApp/FormAppStatus.d.ts +2 -2
  32. package/dist/types/components/FormPages/FormPage.d.ts +17 -17
  33. package/dist/types/components/FormPages/FormPageHeader.d.ts +3 -3
  34. package/dist/types/components/FormPages/FormPages.d.ts +7 -7
  35. package/dist/types/components/FormPages/FormPagesContext.d.ts +4 -4
  36. package/dist/types/components/FormPages/FormPagesNavigation.d.ts +5 -5
  37. package/dist/types/components/FormPages/FormPagesSelect.d.ts +3 -3
  38. package/dist/types/components/FormPages/FormPagesSidebar.d.ts +3 -3
  39. package/dist/types/components/FormStepper/FormStepContent.d.ts +5 -5
  40. package/dist/types/components/FormStepper/FormStepList.d.ts +3 -3
  41. package/dist/types/components/FormStepper/FormStepper.d.ts +5 -5
  42. package/dist/types/components/FormStepper/FormStepperContext.d.ts +3 -3
  43. package/dist/types/components/IssueAlert/IssueAlert.d.ts +4 -4
  44. package/dist/types/components/IssueMessage/IssueMessage.d.ts +4 -4
  45. package/dist/types/components/IssueMessages/IssueMessages.d.ts +6 -6
  46. package/dist/types/components/IssuesPanel/IssuesPanel.d.ts +25 -25
  47. package/dist/types/components/IssuesPanel/IssuesPanelMessagesCard.d.ts +4 -4
  48. package/dist/types/components/IssuesPanel/IssuesPanelSummaryCard.d.ts +4 -4
  49. package/dist/types/components/IssuesPopover/IssuesPopover.d.ts +3 -3
  50. package/dist/types/components/LoadAction/LoadAction.d.ts +2 -2
  51. package/dist/types/components/NumericControl/NumericControl.d.ts +6 -6
  52. package/dist/types/components/PathLink/PathLink.d.ts +2 -2
  53. package/dist/types/components/RadioGroupControl/RadioGroupControl.d.ts +9 -9
  54. package/dist/types/components/SaveAction/SaveAction.d.ts +6 -6
  55. package/dist/types/components/SelectControl/SelectControl.d.ts +6 -6
  56. package/dist/types/components/SelectMultipleControl/SelectMultipleControl.d.ts +6 -6
  57. package/dist/types/components/SubmitAction/SubmitAction.d.ts +20 -20
  58. package/dist/types/components/TableControl/TableControl.d.ts +7 -7
  59. package/dist/types/components/TableControl/TableControlAddRowTrigger.d.ts +4 -4
  60. package/dist/types/components/TableControl/TableControlApi.d.ts +2 -2
  61. package/dist/types/components/TableControl/TableControlCell.d.ts +3 -3
  62. package/dist/types/components/TableControl/TableControlColumn.d.ts +3 -3
  63. package/dist/types/components/TableControl/TableControlContent.d.ts +3 -3
  64. package/dist/types/components/TableControl/TableControlContext.d.ts +4 -4
  65. package/dist/types/components/TableControl/TableControlRemoveRowTrigger.d.ts +9 -9
  66. package/dist/types/components/TableControl/TableControlRow.d.ts +3 -3
  67. package/dist/types/components/TextControl/TextControl.d.ts +8 -8
  68. package/dist/types/components/TopBar/TopBar.d.ts +3 -3
  69. package/dist/types/components/TopBar/TopBarActions.d.ts +3 -3
  70. package/dist/types/components/ValidateAction/ValidateAction.d.ts +2 -2
  71. package/dist/types/index.d.ts +1 -1
  72. package/dist/types/locales/en-GB.d.ts +3 -0
  73. package/dist/types/locales/en-US.d.ts +3 -0
  74. package/dist/types/{locale → locales}/en.d.ts +2 -2
  75. package/dist/types/locales/fr.d.ts +3 -0
  76. package/dist/types/locales/index.d.ts +4 -0
  77. package/dist/types/locales/pt.d.ts +3 -0
  78. package/dist/types/providers/LocalizationProvider/LocalizationContext.d.ts +6 -4
  79. package/dist/types/{locale → providers/LocalizationProvider}/LocalizationObject.d.ts +14 -15
  80. package/dist/types/providers/LocalizationProvider/LocalizationProvider.d.ts +17 -6
  81. package/dist/types/providers/LocalizationProvider/index.d.ts +1 -0
  82. package/dist/types/providers/LocalizationProvider/useLocale.d.ts +6 -3
  83. package/dist/types/providers/PrefixSuffixProvider/PrefixSuffixContext.d.ts +1 -4
  84. package/dist/types/providers/PrefixSuffixProvider/PrefixSuffixProvider.d.ts +3 -3
  85. package/dist/types/providers/PrefixSuffixProvider/defaultPrefixSuffix.d.ts +12 -0
  86. package/dist/types/providers/PrefixSuffixProvider/index.d.ts +1 -0
  87. package/dist/types/utils/options.d.ts +4 -4
  88. package/dist/types/utils/selectionTransformations.d.ts +2 -1
  89. package/dist/types/utils/useControlAutofocus.d.ts +2 -2
  90. package/dist/types/utils/useControlIssues.d.ts +3 -3
  91. package/dist/types/utils/useFormLoader.d.ts +3 -3
  92. package/dist/types/utils/useFormSaver.d.ts +3 -3
  93. package/dist/types/utils/useRegisterControl.d.ts +6 -6
  94. package/package.json +21 -5
  95. package/dist/ostack-ui-kform.cjs +0 -7534
  96. package/dist/ostack-ui-kform.cjs.map +0 -1
  97. package/dist/types/locale/defaultLocale.d.ts +0 -3
  98. package/dist/types/locale/en-GB.d.ts +0 -3
  99. package/dist/types/locale/en-US.d.ts +0 -3
  100. package/dist/types/locale/fr-FR.d.ts +0 -3
  101. package/dist/types/locale/index.d.ts +0 -6
  102. package/dist/types/locale/pt-PT.d.ts +0 -3
@@ -1,9 +1,9 @@
1
1
  import { type Path } from "@ostack.tech/kform";
2
2
  import { ErrorBoundary, TabContent } from "@ostack.tech/ui";
3
- import * as React from "react";
3
+ import { type ComponentPropsWithoutRef, type ComponentPropsWithRef, type ReactNode } from "react";
4
4
  import { type IssueMessagesByCode } from "../IssueMessages";
5
5
  /** Properties of the annex component. */
6
- export interface AnnexProps extends Omit<React.ComponentPropsWithoutRef<typeof TabContent>, "value" | "children"> {
6
+ export interface AnnexProps extends Omit<ComponentPropsWithoutRef<typeof TabContent>, "value" | "children"> {
7
7
  /** Annex path. This should match the path of the annex provided to `Annexes`. */
8
8
  path?: string | Path;
9
9
  /** Sets the annex as disabled. */
@@ -39,8 +39,8 @@ export interface AnnexProps extends Omit<React.ComponentPropsWithoutRef<typeof T
39
39
  */
40
40
  issueMessages?: Record<string, IssueMessagesByCode>;
41
41
  /** Properties to pass to the `ErrorBoundary` component. */
42
- errorBoundaryProps?: React.ComponentPropsWithRef<typeof ErrorBoundary>;
43
- children?: React.ReactNode;
42
+ errorBoundaryProps?: ComponentPropsWithRef<typeof ErrorBoundary>;
43
+ children?: ReactNode;
44
44
  }
45
45
  /** Component containing the content of an annex. */
46
- export declare const Annex: React.ForwardRefExoticComponent<AnnexProps & React.RefAttributes<HTMLDivElement>>;
46
+ export declare const Annex: import("react").ForwardRefExoticComponent<AnnexProps & import("react").RefAttributes<HTMLDivElement>>;
@@ -1,8 +1,8 @@
1
1
  import { type AbsolutePath, type Path } from "@ostack.tech/kform";
2
2
  import { Tabs } from "@ostack.tech/ui";
3
- import * as React from "react";
3
+ import { type ComponentPropsWithoutRef, type ReactNode } from "react";
4
4
  /** Properties of the annexes component. */
5
- export interface AnnexesProps extends Omit<React.ComponentPropsWithoutRef<typeof Tabs>, "defaultValue" | "value" | "onValueChange"> {
5
+ export interface AnnexesProps extends Omit<ComponentPropsWithoutRef<typeof Tabs>, "defaultValue" | "value" | "onValueChange"> {
6
6
  /** Base path for all declared annexes. */
7
7
  path?: string | Path;
8
8
  /** List of all annexes. */
@@ -29,7 +29,7 @@ export interface AnnexesProps extends Omit<React.ComponentPropsWithoutRef<typeof
29
29
  * @param removedAnnexPath Path of the removed annex.
30
30
  */
31
31
  onAnnexRemove?: (removedAnnexPath: AbsolutePath) => void;
32
- children?: React.ReactNode;
32
+ children?: ReactNode;
33
33
  }
34
34
  /** Object representation of an annex. */
35
35
  export interface AnnexObject<T = any> {
@@ -40,22 +40,22 @@ export interface AnnexObject<T = any> {
40
40
  */
41
41
  path: string | Path;
42
42
  /** Annex's title. */
43
- title: React.ReactNode | ((value: T) => React.ReactNode);
43
+ title: ReactNode | ((value: T) => ReactNode);
44
44
  /** Annex's subtitle. */
45
- subtitle?: React.ReactNode | ((value: T, index?: number) => React.ReactNode);
45
+ subtitle?: ReactNode | ((value: T, index?: number) => ReactNode);
46
46
  /** Annex's description. */
47
- description?: React.ReactNode;
47
+ description?: ReactNode;
48
48
  /**
49
49
  * Annex's label in the issues panel. The `title` and `subtitle` are used by
50
50
  * default.
51
51
  */
52
- issuesPanelLabel?: React.ReactNode | ((value: T) => React.ReactNode);
53
- itemTitle?: React.ReactNode | ((value: T, index: number) => React.ReactNode);
52
+ issuesPanelLabel?: ReactNode | ((value: T) => ReactNode);
53
+ itemTitle?: ReactNode | ((value: T, index: number) => ReactNode);
54
54
  /**
55
55
  * Issues panel label for each annex of a collection of annexes. The
56
56
  * `subtitle` and index of the item are used by default.
57
57
  */
58
- itemIssuesPanelLabel?: React.ReactNode | ((value: T, index: number) => React.ReactNode);
58
+ itemIssuesPanelLabel?: ReactNode | ((value: T, index: number) => ReactNode);
59
59
  /**
60
60
  * Title of the annex as a string to display in the document's title.
61
61
  *
@@ -92,4 +92,4 @@ export interface AnnexObject<T = any> {
92
92
  getValue?: (value: T) => T | null | undefined | Promise<T | null | undefined>;
93
93
  }
94
94
  /** Root component used to render form annexes. */
95
- export declare const Annexes: React.ForwardRefExoticComponent<AnnexesProps & React.RefAttributes<HTMLDivElement>>;
95
+ export declare const Annexes: import("react").ForwardRefExoticComponent<AnnexesProps & import("react").RefAttributes<HTMLDivElement>>;
@@ -1,5 +1,5 @@
1
1
  import { AbsolutePath, type DisplayStatus, type FormManager, type Path, type Schema, type SealedValidationIssue, type TableRowId } from "@ostack.tech/kform";
2
- import * as React from "react";
2
+ import { type ReactNode } from "react";
3
3
  import { type AnnexesProps, type AnnexObject } from "./Annexes.tsx";
4
4
  /** Value of the annexes' context. */
5
5
  export type AnnexesContextValue = AnnexesStore;
@@ -10,9 +10,9 @@ export interface ResolvedAnnexObject extends AnnexObject {
10
10
  /** Annex state. */
11
11
  export interface AnnexState {
12
12
  path: AbsolutePath;
13
- title: React.ReactNode;
14
- subtitle?: React.ReactNode;
15
- description?: React.ReactNode;
13
+ title: ReactNode;
14
+ subtitle?: ReactNode;
15
+ description?: ReactNode;
16
16
  documentTitle?: string | null;
17
17
  isRepetitive: boolean;
18
18
  schema: Schema;
@@ -57,7 +57,7 @@ export interface AnnexesActions {
57
57
  /** Annexes' store. */
58
58
  export type AnnexesStore = ReturnType<typeof useCreateAnnexesContext>;
59
59
  /** Annexes' context. */
60
- export declare const AnnexesContext: React.Context<(Omit<import("zustand").StoreApi<AnnexesState>, "subscribe"> & {
60
+ export declare const AnnexesContext: import("react").Context<(Omit<import("zustand").StoreApi<AnnexesState>, "subscribe"> & {
61
61
  subscribe: {
62
62
  (listener: (selectedState: AnnexesState, previousSelectedState: AnnexesState) => void): () => void;
63
63
  <U>(selector: (state: AnnexesState) => U, listener: (selectedState: U, previousSelectedState: U) => void, options?: {
@@ -1,11 +1,11 @@
1
1
  import { type Button, type DropdownMenu, type DropdownMenuContent, type TabList } from "@ostack.tech/ui";
2
- import * as React from "react";
2
+ import { type ComponentPropsWithoutRef, type ComponentPropsWithRef, type ReactNode } from "react";
3
3
  /** Properties of the annexes' manager component. */
4
- export interface AnnexesManagerProps extends React.ComponentPropsWithoutRef<"nav"> {
4
+ export interface AnnexesManagerProps extends ComponentPropsWithoutRef<"nav"> {
5
5
  /** Text of the menu button. */
6
- menuButtonText?: React.ReactNode;
6
+ menuButtonText?: ReactNode;
7
7
  /** Text of the "add annex" item. */
8
- addAnnexText?: React.ReactNode;
8
+ addAnnexText?: ReactNode;
9
9
  /** Label of the remove annex button, announced by assistive technologies. */
10
10
  removeAnnexButtonLabel?: string;
11
11
  /**
@@ -14,34 +14,34 @@ export interface AnnexesManagerProps extends React.ComponentPropsWithoutRef<"nav
14
14
  */
15
15
  removeAnnexKeyboardHint?: string;
16
16
  /** Title of the "remove annex" confirm dialog. */
17
- removeAnnexConfirmDialogTitle?: React.ReactNode;
17
+ removeAnnexConfirmDialogTitle?: ReactNode;
18
18
  /**
19
19
  * Function that should return the message of the "remove annex" confirm
20
20
  * dialog, given a node with the name of the annex.
21
21
  *
22
22
  * @param annexName Node containing the name of the annex.
23
23
  */
24
- removeAnnexConfirmDialogMessage?: (annexName: React.ReactNode) => React.ReactNode;
24
+ removeAnnexConfirmDialogMessage?: (annexName: ReactNode) => ReactNode;
25
25
  /** Text of the "remove annex" confirm dialog OK button. */
26
- removeAnnexConfirmDialogOkText?: React.ReactNode;
26
+ removeAnnexConfirmDialogOkText?: ReactNode;
27
27
  /** Text of the "remove annex" confirm dialog cancel button. */
28
- removeAnnexConfirmDialogCancelText?: React.ReactNode;
28
+ removeAnnexConfirmDialogCancelText?: ReactNode;
29
29
  /** Properties to pass to the menu container element. */
30
- menuContainerProps?: React.ComponentPropsWithRef<"div">;
30
+ menuContainerProps?: ComponentPropsWithRef<"div">;
31
31
  /** Properties to pass to the menu trigger component. */
32
- menuTriggerProps?: Omit<React.ComponentPropsWithRef<typeof Button>, "icon">;
32
+ menuTriggerProps?: Omit<ComponentPropsWithRef<typeof Button>, "icon">;
33
33
  /** Properties to pass to the menu content component. */
34
- menuContentProps?: React.ComponentPropsWithRef<typeof DropdownMenuContent>;
34
+ menuContentProps?: ComponentPropsWithRef<typeof DropdownMenuContent>;
35
35
  /** Properties to pass to the menu component. */
36
- menuProps?: React.ComponentPropsWithRef<typeof DropdownMenu>;
36
+ menuProps?: ComponentPropsWithRef<typeof DropdownMenu>;
37
37
  /** Properties to pass to the tab-list container element. */
38
- tabListContainerProps?: React.ComponentPropsWithRef<"div">;
38
+ tabListContainerProps?: ComponentPropsWithRef<"div">;
39
39
  /** Properties to pass to the tab-list component. */
40
- tabListProps?: React.ComponentPropsWithRef<typeof TabList>;
40
+ tabListProps?: ComponentPropsWithRef<typeof TabList>;
41
41
  }
42
42
  /**
43
43
  * Component used to manage the form's annexes. Provides a menu that allows
44
44
  * changing, adding, and removing annexes, as well as a list of tabs for each
45
45
  * existing annex.
46
46
  */
47
- export declare const AnnexesManager: React.ForwardRefExoticComponent<AnnexesManagerProps & React.RefAttributes<HTMLElement>>;
47
+ export declare const AnnexesManager: import("react").ForwardRefExoticComponent<AnnexesManagerProps & import("react").RefAttributes<HTMLElement>>;
@@ -1,10 +1,10 @@
1
1
  import { Button, DropdownMenu, DropdownMenuContent } from "@ostack.tech/ui";
2
- import * as React from "react";
2
+ import { type ComponentPropsWithoutRef, type ComponentPropsWithRef } from "react";
3
3
  import { type AnnexesManager } from "./AnnexesManager.tsx";
4
4
  /** Properties of the annexes' menu. */
5
- export interface AnnexesMenuProps extends Pick<React.ComponentPropsWithoutRef<typeof AnnexesManager>, "menuButtonText" | "addAnnexText" | "removeAnnexButtonLabel" | "removeAnnexKeyboardHint" | "removeAnnexConfirmDialogTitle" | "removeAnnexConfirmDialogMessage" | "removeAnnexConfirmDialogOkText" | "removeAnnexConfirmDialogCancelText">, React.ComponentPropsWithoutRef<typeof DropdownMenu> {
6
- menuTriggerProps?: Omit<React.ComponentPropsWithRef<typeof Button>, "icon">;
7
- menuContentProps?: React.ComponentPropsWithRef<typeof DropdownMenuContent>;
5
+ export interface AnnexesMenuProps extends Pick<ComponentPropsWithoutRef<typeof AnnexesManager>, "menuButtonText" | "addAnnexText" | "removeAnnexButtonLabel" | "removeAnnexKeyboardHint" | "removeAnnexConfirmDialogTitle" | "removeAnnexConfirmDialogMessage" | "removeAnnexConfirmDialogOkText" | "removeAnnexConfirmDialogCancelText">, ComponentPropsWithoutRef<typeof DropdownMenu> {
6
+ menuTriggerProps?: Omit<ComponentPropsWithRef<typeof Button>, "icon">;
7
+ menuContentProps?: ComponentPropsWithRef<typeof DropdownMenuContent>;
8
8
  }
9
9
  /** Component that allows to navigate between, add, and remove annexes. */
10
10
  export declare function AnnexesMenu({ menuButtonText, addAnnexText, removeAnnexButtonLabel, removeAnnexKeyboardHint, removeAnnexConfirmDialogTitle, removeAnnexConfirmDialogMessage, removeAnnexConfirmDialogOkText, removeAnnexConfirmDialogCancelText, defaultOpen, open: controlledOpen, onOpenChange, menuTriggerProps, menuContentProps, ...otherProps }: AnnexesMenuProps): import("react/jsx-runtime").JSX.Element;
@@ -1,8 +1,8 @@
1
1
  import { TabList } from "@ostack.tech/ui";
2
- import * as React from "react";
2
+ import { type ComponentPropsWithoutRef } from "react";
3
3
  /** Properties of the annex tab list component. */
4
- export interface AnnexTabListProps extends React.ComponentPropsWithoutRef<typeof TabList> {
4
+ export interface AnnexTabListProps extends ComponentPropsWithoutRef<typeof TabList> {
5
5
  hideNonActiveOnSmallScreens: boolean;
6
6
  }
7
7
  /** List of annex tabs. */
8
- export declare const AnnexesTabList: React.ForwardRefExoticComponent<AnnexTabListProps & React.RefAttributes<HTMLDivElement>>;
8
+ export declare const AnnexesTabList: import("react").ForwardRefExoticComponent<AnnexTabListProps & import("react").RefAttributes<HTMLDivElement>>;
@@ -1,10 +1,10 @@
1
1
  import { type Path } from "@ostack.tech/kform";
2
2
  import { type InputController, type InputOptions } from "@ostack.tech/kform-react";
3
3
  import { Checkbox, type CheckboxChecked } from "@ostack.tech/ui";
4
- import * as React from "react";
4
+ import { type ComponentPropsWithoutRef, type ComponentPropsWithRef, type ComponentRef, type ReactNode, type Ref } from "react";
5
5
  import { type IssueMessages, type IssueMessagesByCode } from "../IssueMessages";
6
6
  /** Properties of the checkbox control component. */
7
- export interface CheckboxControlProps<T extends boolean | null = boolean | null> extends Omit<InputOptions<T, CheckboxChecked, React.ComponentRef<typeof Checkbox>>, "enabled" | "format" | "parse">, Omit<React.ComponentPropsWithoutRef<typeof Checkbox>, "defaultChecked" | "checked" | "status"> {
7
+ export interface CheckboxControlProps<T extends boolean | null = boolean | null> extends Omit<InputOptions<T, CheckboxChecked, ComponentRef<typeof Checkbox>>, "enabled" | "format" | "parse">, Omit<ComponentPropsWithoutRef<typeof Checkbox>, "defaultChecked" | "checked" | "status"> {
8
8
  /** Path to the value. */
9
9
  path?: string | Path;
10
10
  /**
@@ -19,7 +19,7 @@ export interface CheckboxControlProps<T extends boolean | null = boolean | null>
19
19
  *
20
20
  * This label has priority over the field's `ControlLabel`.
21
21
  */
22
- issuesPanelLabel?: React.ReactNode;
22
+ issuesPanelLabel?: ReactNode;
23
23
  /**
24
24
  * Whether to display the issues associated with this control.
25
25
  *
@@ -37,12 +37,12 @@ export interface CheckboxControlProps<T extends boolean | null = boolean | null>
37
37
  */
38
38
  preventAutoFocus?: boolean;
39
39
  /** Reference to the control's API. */
40
- apiRef?: React.Ref<InputController<T, CheckboxChecked, React.ComponentRef<typeof Checkbox>> | undefined>;
40
+ apiRef?: Ref<InputController<T, CheckboxChecked, ComponentRef<typeof Checkbox>> | undefined>;
41
41
  /** Properties to pass to the `IssueMessages` component. */
42
- issueMessagesProps?: Omit<React.ComponentPropsWithRef<typeof IssueMessages>, "path" | "issues" | "messages" | "unwrapped">;
42
+ issueMessagesProps?: Omit<ComponentPropsWithRef<typeof IssueMessages>, "path" | "issues" | "messages" | "unwrapped">;
43
43
  }
44
44
  /**
45
45
  * Checkbox control component supporting (possibly nullable) schemas of type
46
46
  * "Boolean". `null` values are represented as an "indeterminate" checkbox.
47
47
  */
48
- export declare const CheckboxControl: React.ForwardRefExoticComponent<CheckboxControlProps<boolean | null> & React.RefAttributes<HTMLButtonElement>>;
48
+ export declare const CheckboxControl: import("react").ForwardRefExoticComponent<CheckboxControlProps<boolean | null> & import("react").RefAttributes<HTMLButtonElement>>;
@@ -1,19 +1,19 @@
1
1
  import { type Path } from "@ostack.tech/kform";
2
2
  import { type Listable, type ListableInputController, type ListableInputOptions } from "@ostack.tech/kform-react";
3
3
  import { Checkbox, CheckboxGroup } from "@ostack.tech/ui";
4
- import * as React from "react";
4
+ import { type ComponentPropsWithoutRef, type ComponentPropsWithRef, type ComponentRef, type Key, type ReactNode, type Ref } from "react";
5
5
  import { type IssueMessages, type IssueMessagesByCode } from "../IssueMessages";
6
6
  /** Checkbox in object notation. */
7
- export type CheckboxObject<T = unknown> = Omit<React.ComponentPropsWithRef<typeof Checkbox>, "defaultChecked" | "checked" | "value" | "children"> & {
7
+ export type CheckboxObject<T = unknown> = Omit<ComponentPropsWithRef<typeof Checkbox>, "defaultChecked" | "checked" | "value" | "children"> & {
8
8
  /** Option value. */
9
9
  value: T;
10
10
  /** Option's rendered text. */
11
- text?: React.ReactNode;
11
+ text?: ReactNode;
12
12
  /** Option's unique key. */
13
- key?: React.Key;
13
+ key?: Key;
14
14
  };
15
15
  /** Properties of the checkbox group control component. */
16
- export interface CheckboxGroupControlProps<T = unknown, TListable extends Listable<T> | null = Listable<T> | null> extends Omit<ListableInputOptions<T, TListable, string[], React.ComponentRef<typeof CheckboxGroup>>, "enabled" | "formatFromArray" | "parseToArray">, Omit<React.ComponentPropsWithoutRef<typeof CheckboxGroup>, "defaultValue" | "value" | "onValueChange" | "children" | "status"> {
16
+ export interface CheckboxGroupControlProps<T = unknown, TListable extends Listable<T> | null = Listable<T> | null> extends Omit<ListableInputOptions<T, TListable, string[], ComponentRef<typeof CheckboxGroup>>, "enabled" | "formatFromArray" | "parseToArray">, Omit<ComponentPropsWithoutRef<typeof CheckboxGroup>, "defaultValue" | "value" | "onValueChange" | "children" | "status"> {
17
17
  /** Path to the value. */
18
18
  path?: string | Path;
19
19
  /** Checkbox group control options. */
@@ -30,7 +30,7 @@ export interface CheckboxGroupControlProps<T = unknown, TListable extends Listab
30
30
  *
31
31
  * This label has priority over the field's `ControlLabel`.
32
32
  */
33
- issuesPanelLabel?: React.ReactNode;
33
+ issuesPanelLabel?: ReactNode;
34
34
  /**
35
35
  * Whether to display the issues associated with this control.
36
36
  *
@@ -48,9 +48,9 @@ export interface CheckboxGroupControlProps<T = unknown, TListable extends Listab
48
48
  */
49
49
  preventAutoFocus?: boolean;
50
50
  /** Reference to the control's API. */
51
- apiRef?: React.Ref<ListableInputController<T, TListable, string[], React.ComponentRef<typeof CheckboxGroup>> | undefined>;
51
+ apiRef?: Ref<ListableInputController<T, TListable, string[], ComponentRef<typeof CheckboxGroup>> | undefined>;
52
52
  /** Properties to pass to the `IssueMessages` component. */
53
- issueMessagesProps?: Omit<React.ComponentPropsWithRef<typeof IssueMessages>, "path" | "issues" | "messages" | "unwrapped">;
53
+ issueMessagesProps?: Omit<ComponentPropsWithRef<typeof IssueMessages>, "path" | "issues" | "messages" | "unwrapped">;
54
54
  }
55
55
  /**
56
56
  * Checkbox group control component supporting (possibly nullable) listable
@@ -60,4 +60,4 @@ export interface CheckboxGroupControlProps<T = unknown, TListable extends Listab
60
60
  * the control contains no elements. Note, however, that the form may still hold
61
61
  * an empty listable as value if set programmatically.
62
62
  */
63
- export declare const CheckboxGroupControl: React.ForwardRefExoticComponent<CheckboxGroupControlProps<unknown, Listable<unknown> | null> & React.RefAttributes<HTMLDivElement>>;
63
+ export declare const CheckboxGroupControl: import("react").ForwardRefExoticComponent<CheckboxGroupControlProps<unknown, Listable<unknown> | null> & import("react").RefAttributes<HTMLDivElement>>;
@@ -1,8 +1,8 @@
1
1
  import { Path } from "@ostack.tech/kform";
2
2
  import { Field } from "@ostack.tech/ui";
3
- import * as React from "react";
3
+ import { type ComponentPropsWithoutRef } from "react";
4
4
  /** Properties of the control field component. */
5
- export interface ControlFieldProps extends React.ComponentPropsWithoutRef<typeof Field> {
5
+ export interface ControlFieldProps extends ComponentPropsWithoutRef<typeof Field> {
6
6
  /** Path of the field; inner control paths will be relative to this path. */
7
7
  path?: string | Path;
8
8
  /**
@@ -47,4 +47,4 @@ export interface ControlFieldProps extends React.ComponentPropsWithoutRef<typeof
47
47
  * Aria descriptions and error messages are set on the control based on the
48
48
  * provided helper texts or feedbacks.
49
49
  */
50
- export declare const ControlField: React.ForwardRefExoticComponent<ControlFieldProps & React.RefAttributes<HTMLDivElement>>;
50
+ export declare const ControlField: import("react").ForwardRefExoticComponent<ControlFieldProps & import("react").RefAttributes<HTMLDivElement>>;
@@ -1,6 +1,5 @@
1
1
  import { type AbsolutePath, type FormManager, type Schema, type SealedValidationIssue } from "@ostack.tech/kform";
2
2
  import { type Controller } from "@ostack.tech/kform-react";
3
- import * as React from "react";
4
3
  /** Value of the control field context. */
5
4
  export type ControlFieldContextValue = ControlFieldStore;
6
5
  /** State of the control field. */
@@ -18,7 +17,7 @@ export interface ControlState {
18
17
  /** Control field store. */
19
18
  export type ControlFieldStore = ReturnType<typeof useCreateControlFieldContext>;
20
19
  /** Control field context. */
21
- export declare const ControlFieldContext: React.Context<import("zustand").StoreApi<ControlFieldState> | null>;
20
+ export declare const ControlFieldContext: import("react").Context<import("zustand").StoreApi<ControlFieldState> | null>;
22
21
  /** Hook which creates the control field context value. */
23
22
  export declare function useCreateControlFieldContext(): import("zustand").StoreApi<ControlFieldState>;
24
23
  /** Hook that returns access to the control field's store. */
@@ -1,10 +1,10 @@
1
1
  import { type Path } from "@ostack.tech/kform";
2
2
  import { type Temporal, type TemporalInputController, type TemporalInputOptions } from "@ostack.tech/kform-react";
3
3
  import { DateInput } from "@ostack.tech/ui";
4
- import * as React from "react";
4
+ import { type ComponentPropsWithoutRef, type ComponentPropsWithRef, type ComponentRef, type ReactNode, type Ref } from "react";
5
5
  import { type IssueMessages, type IssueMessagesByCode } from "../IssueMessages";
6
6
  /** Properties of the date control component. */
7
- export interface DateControlProps<T extends Temporal | null = Temporal | null> extends Omit<TemporalInputOptions<T, string, React.ComponentRef<typeof DateInput>>, "enabled" | "formatFromString" | "parseToString">, Omit<React.ComponentPropsWithoutRef<typeof DateInput>, "defaultValue" | "value" | "onValueChange" | "status"> {
7
+ export interface DateControlProps<T extends Temporal | null = Temporal | null> extends Omit<TemporalInputOptions<T, string, ComponentRef<typeof DateInput>>, "enabled" | "formatFromString" | "parseToString">, Omit<ComponentPropsWithoutRef<typeof DateInput>, "defaultValue" | "value" | "onValueChange" | "status"> {
8
8
  /** Path to the value. */
9
9
  path?: string | Path;
10
10
  /**
@@ -19,7 +19,7 @@ export interface DateControlProps<T extends Temporal | null = Temporal | null> e
19
19
  *
20
20
  * This label has priority over the field's `ControlLabel`.
21
21
  */
22
- issuesPanelLabel?: React.ReactNode;
22
+ issuesPanelLabel?: ReactNode;
23
23
  /**
24
24
  * Whether to display the issues associated with this control.
25
25
  *
@@ -37,9 +37,9 @@ export interface DateControlProps<T extends Temporal | null = Temporal | null> e
37
37
  */
38
38
  preventAutoFocus?: boolean;
39
39
  /** Reference to the control's API. */
40
- apiRef?: React.Ref<TemporalInputController<T, string, React.ComponentRef<typeof DateInput>> | undefined>;
40
+ apiRef?: Ref<TemporalInputController<T, string, ComponentRef<typeof DateInput>> | undefined>;
41
41
  /** Properties to pass to the `IssueMessages` component. */
42
- issueMessagesProps?: Omit<React.ComponentPropsWithRef<typeof IssueMessages>, "path" | "issues" | "messages" | "unwrapped">;
42
+ issueMessagesProps?: Omit<ComponentPropsWithRef<typeof IssueMessages>, "path" | "issues" | "messages" | "unwrapped">;
43
43
  }
44
44
  /** Date control component supporting nullable temporal schemas. */
45
- export declare const DateControl: React.ForwardRefExoticComponent<DateControlProps<Temporal | null> & React.RefAttributes<HTMLInputElement>>;
45
+ export declare const DateControl: import("react").ForwardRefExoticComponent<DateControlProps<Temporal | null> & import("react").RefAttributes<HTMLInputElement>>;
@@ -1,10 +1,10 @@
1
1
  import { type Path } from "@ostack.tech/kform";
2
2
  import { type Temporal, type TemporalInputController, type TemporalInputOptions } from "@ostack.tech/kform-react";
3
3
  import { DateRangeInput } from "@ostack.tech/ui";
4
- import * as React from "react";
4
+ import { type ComponentPropsWithoutRef, type ComponentPropsWithRef, type ReactNode, type Ref } from "react";
5
5
  import { type IssueMessages, type IssueMessagesByCode } from "../IssueMessages";
6
6
  /** Properties of the date-range control component. */
7
- export interface DateRangeControlProps<TStart extends Temporal | null = Temporal | null, TEnd extends Temporal | null = TStart> extends Omit<React.ComponentPropsWithoutRef<typeof DateRangeInput>, "defaultValue" | "value"> {
7
+ export interface DateRangeControlProps<TStart extends Temporal | null = Temporal | null, TEnd extends Temporal | null = TStart> extends Omit<ComponentPropsWithoutRef<typeof DateRangeInput>, "defaultValue" | "value"> {
8
8
  /** Path to the start value. */
9
9
  startPath: string | Path;
10
10
  /** Path to the end value. */
@@ -27,17 +27,17 @@ export interface DateRangeControlProps<TStart extends Temporal | null = Temporal
27
27
  *
28
28
  * This label has priority over the field's `ControlLabel`.
29
29
  */
30
- issuesPanelLabel?: React.ReactNode;
30
+ issuesPanelLabel?: ReactNode;
31
31
  /**
32
32
  * Label suffix to use in the issues panel when displaying issues associated
33
33
  * with this field's start date.
34
34
  */
35
- issuesPanelStartLabelSuffix?: React.ReactNode;
35
+ issuesPanelStartLabelSuffix?: ReactNode;
36
36
  /**
37
37
  * Label suffix to use in the issues panel when displaying issues associated
38
38
  * with this field's end date.
39
39
  */
40
- issuesPanelEndLabelSuffix?: React.ReactNode;
40
+ issuesPanelEndLabelSuffix?: ReactNode;
41
41
  /**
42
42
  * Whether to display the issues associated with this control.
43
43
  *
@@ -55,11 +55,11 @@ export interface DateRangeControlProps<TStart extends Temporal | null = Temporal
55
55
  */
56
56
  preventAutoFocus?: boolean;
57
57
  /** Reference to the start control's API. */
58
- startApiRef?: React.Ref<TemporalInputController<TStart, string> | undefined>;
58
+ startApiRef?: Ref<TemporalInputController<TStart, string> | undefined>;
59
59
  /** Reference to the end control's API. */
60
- endApiRef?: React.Ref<TemporalInputController<TEnd, string> | undefined>;
60
+ endApiRef?: Ref<TemporalInputController<TEnd, string> | undefined>;
61
61
  /** Properties to pass to the `IssueMessages` component. */
62
- issueMessagesProps?: Omit<React.ComponentPropsWithRef<typeof IssueMessages>, "path" | "issues" | "messages" | "unwrapped">;
62
+ issueMessagesProps?: Omit<ComponentPropsWithRef<typeof IssueMessages>, "path" | "issues" | "messages" | "unwrapped">;
63
63
  onStartInitialized?: TemporalInputOptions<TStart, string>["onInitialized"];
64
64
  onStartFormManagerEvent?: TemporalInputOptions<TStart, string>["onFormManagerEvent"];
65
65
  onStartValueChange?: TemporalInputOptions<TStart, string>["onValueChange"];
@@ -76,4 +76,4 @@ export interface DateRangeControlProps<TStart extends Temporal | null = Temporal
76
76
  onEndTouchedStatusChange?: TemporalInputOptions<TEnd, string>["onTouchedStatusChange"];
77
77
  }
78
78
  /** Date-range control component supporting nullable temporal schemas. */
79
- export declare const DateRangeControl: React.ForwardRefExoticComponent<DateRangeControlProps<Temporal | null, Temporal | null> & React.RefAttributes<HTMLDivElement>>;
79
+ export declare const DateRangeControl: import("react").ForwardRefExoticComponent<DateRangeControlProps<Temporal | null, Temporal | null> & import("react").RefAttributes<HTMLDivElement>>;
@@ -1,7 +1,7 @@
1
1
  import { type File as KFormFile, type Path } from "@ostack.tech/kform";
2
2
  import { type FileInputController, type FileInputOptions } from "@ostack.tech/kform-react";
3
3
  import { Input } from "@ostack.tech/ui";
4
- import * as React from "react";
4
+ import { type ComponentPropsWithoutRef, type ComponentPropsWithRef, type ComponentRef, type ReactNode, type Ref } from "react";
5
5
  import { type IssueMessages, type IssueMessagesByCode } from "../IssueMessages";
6
6
  /**
7
7
  * File control's interaction with the selected file:
@@ -15,7 +15,7 @@ import { type IssueMessages, type IssueMessagesByCode } from "../IssueMessages";
15
15
  */
16
16
  export type FileControlFileInteraction = "view" | "download" | "none";
17
17
  /** Properties of the file control component. */
18
- export interface FileControlProps<T extends KFormFile | null = KFormFile | null> extends Omit<FileInputOptions<T, FileList, React.ComponentRef<typeof Input>>, "enabled" | "formatFromFileList" | "parseToFileList">, Omit<React.ComponentPropsWithoutRef<typeof Input>, "type" | "multiple" | "defaultValue" | "value" | "onValueChange" | "status" | "align"> {
18
+ export interface FileControlProps<T extends KFormFile | null = KFormFile | null> extends Omit<FileInputOptions<T, FileList, ComponentRef<typeof Input>>, "enabled" | "formatFromFileList" | "parseToFileList">, Omit<ComponentPropsWithoutRef<typeof Input>, "type" | "multiple" | "defaultValue" | "value" | "onValueChange" | "status" | "align"> {
19
19
  /** Path to the value. */
20
20
  path?: string | Path;
21
21
  /**
@@ -30,7 +30,7 @@ export interface FileControlProps<T extends KFormFile | null = KFormFile | null>
30
30
  *
31
31
  * This label has priority over the field's `ControlLabel`.
32
32
  */
33
- issuesPanelLabel?: React.ReactNode;
33
+ issuesPanelLabel?: ReactNode;
34
34
  /**
35
35
  * Whether to display the issues associated with this control.
36
36
  *
@@ -48,7 +48,7 @@ export interface FileControlProps<T extends KFormFile | null = KFormFile | null>
48
48
  */
49
49
  preventAutoFocus?: boolean;
50
50
  /** Reference to the control's API. */
51
- apiRef?: React.Ref<FileInputController<T, FileList, React.ComponentRef<typeof Input>> | undefined>;
51
+ apiRef?: Ref<FileInputController<T, FileList, ComponentRef<typeof Input>> | undefined>;
52
52
  /**
53
53
  * Type of interaction with the selected file.
54
54
  *
@@ -56,13 +56,13 @@ export interface FileControlProps<T extends KFormFile | null = KFormFile | null>
56
56
  */
57
57
  fileInteraction?: FileControlFileInteraction;
58
58
  /** Label of the button used to open the file viewer. */
59
- viewFileButtonLabel?: React.ReactNode;
59
+ viewFileButtonLabel?: ReactNode;
60
60
  /** Label of the button used to download the file. */
61
- downloadFileButtonLabel?: React.ReactNode;
61
+ downloadFileButtonLabel?: ReactNode;
62
62
  /** Text displayed when the file cannot be viewed. */
63
- fallbackText?: React.ReactNode;
63
+ fallbackText?: ReactNode;
64
64
  /** Properties to pass to the `IssueMessages` component. */
65
- issueMessagesProps?: Omit<React.ComponentPropsWithRef<typeof IssueMessages>, "path" | "issues" | "messages" | "unwrapped">;
65
+ issueMessagesProps?: Omit<ComponentPropsWithRef<typeof IssueMessages>, "path" | "issues" | "messages" | "unwrapped">;
66
66
  }
67
67
  /** File control component supporting (possibly nullable) file schemas. */
68
- export declare const FileControl: React.ForwardRefExoticComponent<FileControlProps<KFormFile | null> & React.RefAttributes<HTMLInputElement>>;
68
+ export declare const FileControl: import("react").ForwardRefExoticComponent<FileControlProps<KFormFile | null> & import("react").RefAttributes<HTMLInputElement>>;
@@ -1,20 +1,20 @@
1
1
  import { AbsolutePath, type Path, type Schema, type SchemaKt } from "@ostack.tech/kform";
2
2
  import { type Controller, type FormOptions } from "@ostack.tech/kform-react";
3
3
  import { type Responsive, Root } from "@ostack.tech/ui";
4
- import * as React from "react";
5
- import { type LocalizationObject } from "../../locale/LocalizationObject.ts";
4
+ import { type ComponentPropsWithoutRef, type ReactNode, type Ref } from "react";
5
+ import { type LocalizationObject } from "../../providers/LocalizationProvider/LocalizationObject.ts";
6
6
  import { type IssueMessagesByCode } from "../IssueMessages";
7
7
  /** Mode of displaying issue messages. */
8
8
  export type IssuesDisplayMode = "inline" | "panel";
9
9
  /** Properties of the form app component. */
10
- export type FormAppProps<T = any> = Pick<React.ComponentPropsWithoutRef<typeof Root>, "enableErrorReporting" | "reportError" | "errorReportingUrl" | "errorReportingMethod" | "encodeErrorReport" | "encodedErrorReportMimeType" | "errorReportingOptions" | "baseDocumentTitle" | "documentTitleBaseSeparator" | "documentTitleBreadcrumbsSeparator" | "portalsContainer" | "tooltipsDelayDuration" | "tooltipsSkipDelayDuration" | "disableTooltipsHoverableContent" | "toastsLabel" | "toastsDuration" | "toastsSwipeDirection" | "toastsSwipeThreshold" | "toastViewportHotkey" | "toastViewportLabel" | "toastViewportProps" | "errorBoundaryProps"> & FormOptions<T> & Omit<React.ComponentPropsWithoutRef<"form">, "onSubmit" | "onReset"> & {
10
+ export type FormAppProps<T = any> = Pick<ComponentPropsWithoutRef<typeof Root>, "enableErrorReporting" | "reportError" | "errorReportingUrl" | "errorReportingMethod" | "encodeErrorReport" | "encodedErrorReportMimeType" | "errorReportingOptions" | "baseDocumentTitle" | "documentTitleBaseSeparator" | "documentTitleBreadcrumbsSeparator" | "portalsContainer" | "tooltipsDelayDuration" | "tooltipsSkipDelayDuration" | "disableTooltipsHoverableContent" | "toastsLabel" | "toastsDuration" | "toastsSwipeDirection" | "toastsSwipeThreshold" | "toastViewportHotkey" | "toastViewportLabel" | "toastViewportProps" | "errorBoundaryProps"> & FormOptions<T> & Omit<ComponentPropsWithoutRef<"form">, "onSubmit" | "onReset"> & {
11
11
  /** Schema of the form. */
12
12
  schema: Schema<T> | SchemaKt;
13
13
  /**
14
14
  * Label to use in the issues panel when displaying issues associated with
15
15
  * the form app.
16
16
  */
17
- issuesPanelLabel?: React.ReactNode;
17
+ issuesPanelLabel?: ReactNode;
18
18
  /** Whether to disable the whole form. */
19
19
  disabled?: boolean;
20
20
  /** Whether to set the whole form as read-only. */
@@ -26,12 +26,16 @@ export type FormAppProps<T = any> = Pick<React.ComponentPropsWithoutRef<typeof R
26
26
  * This prefix-suffix should match the `$prefix-suffix` SCSS variable.
27
27
  */
28
28
  prefixSuffix?: string;
29
+ /** Uncontrolled form app locale. */
30
+ defaultLocale?: LocalizationObject;
31
+ /** Controlled form app locale. */
32
+ locale?: LocalizationObject;
29
33
  /**
30
- * Form app locale.
34
+ * Function called when the locale changes.
31
35
  *
32
- * @default defaultLocale
36
+ * @param locale New locale.
33
37
  */
34
- locale?: LocalizationObject;
38
+ onLocaleChange?: (locale: LocalizationObject) => void;
35
39
  /**
36
40
  * Mapping of issue messages from the path of the field with issues to the
37
41
  * issue messages of said field (which are themselves grouped by their
@@ -92,7 +96,7 @@ export type FormAppProps<T = any> = Pick<React.ComponentPropsWithoutRef<typeof R
92
96
  */
93
97
  minHeight?: Responsive<number | string>;
94
98
  /** Reference to the form app's API. */
95
- apiRef?: React.Ref<FormAppApi<T> | undefined>;
99
+ apiRef?: Ref<FormAppApi<T> | undefined>;
96
100
  };
97
101
  /** Imperative form app API. */
98
102
  export type FormAppApi<T = unknown> = Controller<T> & {
@@ -121,14 +125,14 @@ export type FormAppApi<T = unknown> = Controller<T> & {
121
125
  * ostack/UI's `locale` is automatically provided to the ostack/UI `Root`
122
126
  * component from the provided `FormApp` `locale`.
123
127
  */
124
- export declare const FormApp: React.ForwardRefExoticComponent<Pick<Omit<import("@ostack.tech/ui").RootProps & React.RefAttributes<HTMLDivElement>, "ref">, "reportError" | "errorReportingUrl" | "errorReportingMethod" | "encodeErrorReport" | "encodedErrorReportMimeType" | "errorReportingOptions" | "baseDocumentTitle" | "enableErrorReporting" | "documentTitleBaseSeparator" | "documentTitleBreadcrumbsSeparator" | "portalsContainer" | "tooltipsDelayDuration" | "tooltipsSkipDelayDuration" | "disableTooltipsHoverableContent" | "toastsLabel" | "toastsDuration" | "toastsSwipeDirection" | "toastsSwipeThreshold" | "toastViewportHotkey" | "toastViewportLabel" | "toastViewportProps" | "errorBoundaryProps"> & Omit<import("@ostack.tech/kform-react").ControllerOptions<any, import("@ostack.tech/kform-react").FormControllerState<any>>, "formManager"> & import("@ostack.tech/kform-react").FormOwnOptions<any, unknown> & Omit<Omit<React.DetailedHTMLProps<React.FormHTMLAttributes<HTMLFormElement>, HTMLFormElement>, "ref">, "onReset" | "onSubmit"> & {
128
+ export declare const FormApp: import("react").ForwardRefExoticComponent<Pick<Omit<import("@ostack.tech/ui").RootProps & import("react").RefAttributes<HTMLDivElement>, "ref">, "reportError" | "errorReportingUrl" | "errorReportingMethod" | "encodeErrorReport" | "encodedErrorReportMimeType" | "errorReportingOptions" | "baseDocumentTitle" | "enableErrorReporting" | "documentTitleBaseSeparator" | "documentTitleBreadcrumbsSeparator" | "portalsContainer" | "tooltipsDelayDuration" | "tooltipsSkipDelayDuration" | "disableTooltipsHoverableContent" | "toastsLabel" | "toastsDuration" | "toastsSwipeDirection" | "toastsSwipeThreshold" | "toastViewportHotkey" | "toastViewportLabel" | "toastViewportProps" | "errorBoundaryProps"> & Omit<import("@ostack.tech/kform-react").ControllerOptions<any, import("@ostack.tech/kform-react").FormControllerState<any>>, "formManager"> & import("@ostack.tech/kform-react").FormOwnOptions<any, unknown> & Omit<Omit<import("react").DetailedHTMLProps<import("react").FormHTMLAttributes<HTMLFormElement>, HTMLFormElement>, "ref">, "onReset" | "onSubmit"> & {
125
129
  /** Schema of the form. */
126
130
  schema: SchemaKt | Schema<any>;
127
131
  /**
128
132
  * Label to use in the issues panel when displaying issues associated with
129
133
  * the form app.
130
134
  */
131
- issuesPanelLabel?: React.ReactNode;
135
+ issuesPanelLabel?: ReactNode;
132
136
  /** Whether to disable the whole form. */
133
137
  disabled?: boolean;
134
138
  /** Whether to set the whole form as read-only. */
@@ -140,12 +144,16 @@ export declare const FormApp: React.ForwardRefExoticComponent<Pick<Omit<import("
140
144
  * This prefix-suffix should match the `$prefix-suffix` SCSS variable.
141
145
  */
142
146
  prefixSuffix?: string;
147
+ /** Uncontrolled form app locale. */
148
+ defaultLocale?: LocalizationObject;
149
+ /** Controlled form app locale. */
150
+ locale?: LocalizationObject;
143
151
  /**
144
- * Form app locale.
152
+ * Function called when the locale changes.
145
153
  *
146
- * @default defaultLocale
154
+ * @param locale New locale.
147
155
  */
148
- locale?: LocalizationObject;
156
+ onLocaleChange?: (locale: LocalizationObject) => void;
149
157
  /**
150
158
  * Mapping of issue messages from the path of the field with issues to the
151
159
  * issue messages of said field (which are themselves grouped by their
@@ -206,5 +214,5 @@ export declare const FormApp: React.ForwardRefExoticComponent<Pick<Omit<import("
206
214
  */
207
215
  minHeight?: Responsive<number | string>;
208
216
  /** Reference to the form app's API. */
209
- apiRef?: React.Ref<FormAppApi<any> | undefined> | undefined;
210
- } & React.RefAttributes<HTMLFormElement>>;
217
+ apiRef?: Ref<FormAppApi<any> | undefined> | undefined;
218
+ } & import("react").RefAttributes<HTMLFormElement>>;
@@ -0,0 +1,2 @@
1
+ /** Component enabling support for auto-focusing the form app via `focus("/")`. */
2
+ export declare function FormAppAutoFocus(): null;