@mmb-digital/design-system-web 0.1.263 → 0.1.264

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/dist/index.d.ts CHANGED
@@ -2342,7 +2342,6 @@ interface ComboBoxFieldProps<TItem extends ComboBoxItem> extends Omit<ComboBoxPr
2342
2342
  declare const ComboBoxField: <TItem extends ComboBoxItem>(props: ComboBoxFieldProps<TItem>) => React__default.JSX.Element;
2343
2343
 
2344
2344
  interface FormErrorOutcomeProps extends DesignSystemBaseProps {
2345
- message: ReactElement | string;
2346
2345
  }
2347
2346
  declare const FormErrorOutcome: (props: FormErrorOutcomeProps) => React__default.JSX.Element | null;
2348
2347
 
@@ -2352,11 +2351,26 @@ interface FormErrorSummaryProps extends DesignSystemBaseProps {
2352
2351
  }
2353
2352
  declare const FormErrorSummary: (props: FormErrorSummaryProps) => React__default.JSX.Element;
2354
2353
 
2354
+ declare enum ThrownFormLevelErrorType {
2355
+ generic = "generic",
2356
+ timeout = "timeout"
2357
+ }
2358
+ interface ThrownFormLevelError {
2359
+ type: ThrownFormLevelErrorType;
2360
+ }
2361
+ interface ThrownFormErrors {
2362
+ formLevelErrors: ThrownFormLevelError[];
2363
+ }
2364
+ interface FormSettings {
2365
+ resolveThrownFormErrors?: (error?: unknown) => ThrownFormErrors;
2366
+ thrownFormLevelErrorFormatter?: Formatter<ThrownFormLevelError, ReactNode, string>;
2367
+ }
2368
+
2355
2369
  interface UseFormProps<TFieldValues extends FieldValues> extends UseFormProps$1<TFieldValues> {
2356
2370
  schema?: z.Schema;
2357
2371
  }
2358
2372
  interface UseFormReturn<TFieldValues extends FieldValues> extends UseFormReturn$1<TFieldValues> {
2359
- genericErrorOccurred: boolean;
2373
+ thrownFormErrors: ThrownFormErrors;
2360
2374
  }
2361
2375
  declare const useForm: <TFieldValues extends FieldValues = FieldValues>(props?: UseFormProps<TFieldValues>) => UseFormReturn<TFieldValues>;
2362
2376
 
@@ -2366,6 +2380,21 @@ interface FormProviderProps<TFieldValues extends FieldValues = FieldValues> {
2366
2380
  }
2367
2381
  declare const FormProvider: <TFieldValues extends FieldValues = FieldValues>(props: FormProviderProps<TFieldValues>) => React__default.JSX.Element;
2368
2382
 
2383
+ declare const FormSettingsContext: React__default.Context<FormSettings>;
2384
+ interface FormSettingsProviderProps {
2385
+ children: ReactNode;
2386
+ formSettings: FormSettings;
2387
+ }
2388
+ declare const FormSettingsProvider: (props: FormSettingsProviderProps) => React__default.JSX.Element;
2389
+
2390
+ interface FormSuccessOutcomeProps extends DesignSystemBaseProps {
2391
+ children: ReactNode;
2392
+ onHide: () => void;
2393
+ title: ReactNode;
2394
+ visible: boolean;
2395
+ }
2396
+ declare const FormSuccessOutcome: (props: FormSuccessOutcomeProps) => React__default.JSX.Element;
2397
+
2369
2398
  declare const useFormContext: <TFieldValues extends FieldValues = FieldValues>() => UseFormReturn<TFieldValues>;
2370
2399
 
2371
2400
  interface UseFormSuccessOutcomeManagerReturn {
@@ -2378,14 +2407,6 @@ interface UseFormSuccessOutcomeManagerReturn {
2378
2407
  }
2379
2408
  declare const useFormSuccessOutcomeManager: () => UseFormSuccessOutcomeManagerReturn;
2380
2409
 
2381
- interface FormSuccessOutcomeProps extends DesignSystemBaseProps {
2382
- children: ReactNode;
2383
- onHide: () => void;
2384
- title: ReactNode;
2385
- visible: boolean;
2386
- }
2387
- declare const FormSuccessOutcome: (props: FormSuccessOutcomeProps) => React__default.JSX.Element;
2388
-
2389
2410
  declare enum FileInputErrorCode {
2390
2411
  fileSizeTooLarge = "fileSizeTooLarge",
2391
2412
  general = "general",
@@ -2464,10 +2485,13 @@ declare const isRenderable: (node: ReactNode) => node is Exclude<ReactNode, bool
2464
2485
  declare const identityFormatter: afformative.Formatter<any, any, any, {
2465
2486
  [x: string]: any;
2466
2487
  }>;
2488
+ declare const jsonFormatter: afformative.Formatter<any, string, string, {
2489
+ [x: string]: any;
2490
+ }>;
2467
2491
  declare const useMessageFormatter: <TInput extends unknown>(getMessage: (value: TInput) => MessageDescriptor | string) => afformative.Formatter<TInput, React__default.ReactNode, string, {
2468
2492
  [x: string]: any;
2469
2493
  }>;
2470
2494
 
2471
2495
  declare const styled: typeof emotionStyled;
2472
2496
 
2473
- export { Accordion, AccordionContent, type AccordionContentType, AccordionItem, type AccordionItemProps, type AccordionItemType, AccordionKeyValue, type AccordionKeyValueProps, type AccordionProps, AccordionVariant, BorderRadius, Button, type ButtonProps, ButtonSize, ButtonStyle, ButtonType, ButtonsLayout, ButtonsLayoutAlign, ButtonsLayoutDirection, type ButtonsLayoutProps, CalculatorResult, type CalculatorResultBodyItem, type CalculatorResultHeader, CalculatorResultInfoPosition, type CalculatorResultMain, type CalculatorResultModalDescriptor, type CalculatorResultProps, Checkbox, CheckboxControl, type CheckboxControlProps, CheckboxField, type CheckboxFieldProps, CheckboxPosition, type CheckboxProps, type ChooseColor, CircularProgressBar, type CircularProgressBarProps, type ColorObject, ColorScheme, ColorSchemeProvider, type ColorSchemeProviderProps, ComboBox, ComboBoxControl, type ComboBoxControlProps, ComboBoxField, type ComboBoxFieldProps, type ComboBoxItem, type ComboBoxItemOrder, ComboBoxItemOrderSource, type ComboBoxProps, type CreateTooltipInfoDescriptor, type CreateTooltipInfoDescriptorParam, DatePicker, DatePickerControl, type DatePickerControlProps, DatePickerField, type DatePickerFieldProps, type DatePickerProps, type DesignSystemBaseProps, DesignSystemProvider, type DesignSystemProviderProps, EmailInput, EmailInputField, type EmailInputFieldProps, type EmailInputProps, ErrorBox, type ErrorBoxItem, type ErrorBoxProps, type FieldAddon, FieldAddonPosition, type FieldConfig, FieldConfigProvider, type FieldConfigProviderProps, type FieldControlProps, FieldLabelStoreProvider, type FieldLabelStoreProviderProps, FieldOptionality, FieldWrapper, FieldWrapperLayout, type FieldWrapperProps, FileInput, type FileInputDropzoneDragFilesHereComponent, type FileInputDropzoneDragOrSelectFilesComponent, type FileInputDropzoneSelectFilesComponent, FileInputErrorCode, FileInputField, type FileInputFieldProps, type FileInputLimitDescriptionComponent, type FileInputProps, type FileInputRemoveButtonTextComponent, type FileInputSettings, type FileInputUploadErrorReasonComponent, type FileInputUploadFailedComponent, FlexWrap, FontWeight, FormErrorOutcome, type FormErrorOutcomeProps, FormErrorSummary, type FormErrorSummaryProps, FormProvider, type FormProviderProps, FormSuccessOutcome, type FormSuccessOutcomeProps, FormatAmountCurrencyDisplay, FormatAmountGrouping, FormattedAmount$1 as FormattedAmount, type FormattedAmountProps$1 as FormattedAmountProps, FormattedHtmlMessage, type FormattedHtmlMessageProps, FormattedMessage, type FormattedMessageProps, _default as FormattedPercentage, type GetColor, IconProduct, type IconProductProps, IconProductSize, IconProductType, IconProductVariant, IconSystem, type IconSystemProps, IconSystemSize, IconSystemType, Infobox, type InfoboxProps, InfoboxSize, type InfoboxTextContent, InfoboxVariant, InputBase, type InputBaseProps, InputLabel, type InputLabelPassthroughProps, type InputLabelProps, InputLabelSize, InputSize, InputTextAlign, LabelTooltipPosition, Loader, LoaderOverlayBox, type LoaderOverlayBoxProps, type LoaderProps, LoaderSize, MaskedInput, MaskedInputBase, type MaskedInputBaseProps, MaskedInputField, type MaskedInputFieldProps, type MaskedInputProps, MediaType, MediaTypeProvider, type MediaTypeProviderProps, type MessageDescriptorWithPrimitiveValues, type MessageDescriptorWithValues, type MessageValues, Modal, type ModalOnClose, type ModalProps, ModalVerticalPosition, ModalWidthType, FormattedAmount as NextFormattedAmount, type FormattedAmountProps as NextFormattedAmountProps, NumberInput, NumberInputField, type NumberInputFieldProps, type NumberInputProps, Overflow, Paper, type PaperProps, PaperShadow, PhoneInput, PhoneInputField, type PhoneInputFieldProps, type PhoneInputProps, type PrimitiveMessageValues, ProgressPaper, type ProgressPaperProps, Radio, RadioButton, RadioButtonGroup, RadioButtonGroupControl, type RadioButtonGroupControlProps, RadioButtonGroupField, type RadioButtonGroupFieldProps, type RadioButtonGroupItem, RadioButtonGroupLayout, type RadioButtonGroupProps, type RadioButtonLabel, type RadioButtonProps, RadioControl, type RadioControlProps, RadioField, type RadioFieldProps, RadioGroup, RadioGroupControl, type RadioGroupControlProps, RadioGroupDirection, RadioGroupField, type RadioGroupFieldProps, type RadioGroupItem, type RadioGroupProps, RadioPosition, type RadioProps, ReasonForClosing, SearchInput, type SearchInputProps, Select, SelectControl, type SelectControlProps, SelectField, type SelectFieldProps, type SelectItem, type SelectItemOrder, SelectItemOrderSource, type SelectProps, SelectVariant, Slider, type SliderAriaValueTextFormatter, type SliderAriaValueTextFormatterDataContext, type SliderBreakpoint, SliderInput, SliderInputField, type SliderInputFieldProps, type SliderInputLimitExceededLiveTextFormatter, type SliderInputLimitExceededLiveTextFormatterDataContext, type SliderInputProps, SliderInputRoundingType, type SliderMinMaxLabels, type SliderProps, SliderStepType, type SliderSteps, Spacing, SpanButton, type SpanButtonProps, Stack, StackDirection, type StackProps, type TabItemType, Table, TableBody, type TableBodyProps, TableData, type TableDataProps, TableHead, TableHeadData, type TableHeadDataProps, type TableHeadProps, type TableProps, TableRow, type TableRowProps, TableTextAlign, TableVariant, Tabs, TabsActiveTabDefaultPosition, TabsItem, type TabsItemProps, type TabsProps, TabsSize, type TabsType, TabsVariant, Tag, TagIconPosition, type TagProps, TagSize, TagTextTransform, TagType, TextArea, TextAreaField, type TextAreaFieldProps, type TextAreaProps, TextDecoration, TextInput, TextInputField, type TextInputFieldProps, type TextInputProps, type Theme, Toggle, type ToggleProps, TooltipCloseReason, type TooltipDescriptor, TooltipGeneral, type TooltipGeneralProps, TooltipInfo, TooltipInfoConditional, type TooltipInfoConditionalProps, type TooltipInfoDescriptor, TooltipInfoDisplayMethod, TooltipInfoDisplayableCheck, type TooltipInfoDisplayableCheckProps, type TooltipInfoProps, TooltipPlacement, type TooltipRenderParent, TrailingTextInput, type TrailingTextInputProps, Typography, type TypographyProps, TypographyTextAlign, TypographyVariant, type UseColorSchemeOptions, type UseColorSchemeParam, type UseDesignSystemOptions, type UseDesignSystemParam, type UseFormProps, type UseFormReturn, type UseFormSuccessOutcomeManagerReturn, type UseFormatAmountParam, type UseMediaTypeOptions, type UseMediaTypeParam, VisuallyHidden, type VisuallyHiddenProps, datePickerValueFormat, getColor, getTextDecorationStyle, identityFormatter, isRenderable, resolveBorderRadiusValue, resolveFlexWrapValue, resolveFontWeightValue, resolveOverflowValue, resolveSpacingValue, resolveTextDecorationValue, styled, theme, useChooseColor, useColorScheme, useCreateTooltipInfoDescriptor, useDesignSystem, useFieldConfig, useFieldLabels, useForm, useFormContext, useFormSuccessOutcomeManager, useFormatAmount$1 as useFormatAmount, useFormattedPercentage, useGetFormattedHtmlMessageIfDisplayable, useIsMessageDisplayable, useMediaType, useMessageFormatter, useFormatAmount as useNextFormatAmount, useRegisterFieldLabel, withFieldWrapper, withMaskedInputField };
2497
+ export { Accordion, AccordionContent, type AccordionContentType, AccordionItem, type AccordionItemProps, type AccordionItemType, AccordionKeyValue, type AccordionKeyValueProps, type AccordionProps, AccordionVariant, BorderRadius, Button, type ButtonProps, ButtonSize, ButtonStyle, ButtonType, ButtonsLayout, ButtonsLayoutAlign, ButtonsLayoutDirection, type ButtonsLayoutProps, CalculatorResult, type CalculatorResultBodyItem, type CalculatorResultHeader, CalculatorResultInfoPosition, type CalculatorResultMain, type CalculatorResultModalDescriptor, type CalculatorResultProps, Checkbox, CheckboxControl, type CheckboxControlProps, CheckboxField, type CheckboxFieldProps, CheckboxPosition, type CheckboxProps, type ChooseColor, CircularProgressBar, type CircularProgressBarProps, type ColorObject, ColorScheme, ColorSchemeProvider, type ColorSchemeProviderProps, ComboBox, ComboBoxControl, type ComboBoxControlProps, ComboBoxField, type ComboBoxFieldProps, type ComboBoxItem, type ComboBoxItemOrder, ComboBoxItemOrderSource, type ComboBoxProps, type CreateTooltipInfoDescriptor, type CreateTooltipInfoDescriptorParam, DatePicker, DatePickerControl, type DatePickerControlProps, DatePickerField, type DatePickerFieldProps, type DatePickerProps, type DesignSystemBaseProps, DesignSystemProvider, type DesignSystemProviderProps, EmailInput, EmailInputField, type EmailInputFieldProps, type EmailInputProps, ErrorBox, type ErrorBoxItem, type ErrorBoxProps, type FieldAddon, FieldAddonPosition, type FieldConfig, FieldConfigProvider, type FieldConfigProviderProps, type FieldControlProps, FieldLabelStoreProvider, type FieldLabelStoreProviderProps, FieldOptionality, FieldWrapper, FieldWrapperLayout, type FieldWrapperProps, FileInput, type FileInputDropzoneDragFilesHereComponent, type FileInputDropzoneDragOrSelectFilesComponent, type FileInputDropzoneSelectFilesComponent, FileInputErrorCode, FileInputField, type FileInputFieldProps, type FileInputLimitDescriptionComponent, type FileInputProps, type FileInputRemoveButtonTextComponent, type FileInputSettings, type FileInputUploadErrorReasonComponent, type FileInputUploadFailedComponent, FlexWrap, FontWeight, FormErrorOutcome, type FormErrorOutcomeProps, FormErrorSummary, type FormErrorSummaryProps, FormProvider, type FormProviderProps, type FormSettings, FormSettingsContext, FormSettingsProvider, type FormSettingsProviderProps, FormSuccessOutcome, type FormSuccessOutcomeProps, FormatAmountCurrencyDisplay, FormatAmountGrouping, FormattedAmount$1 as FormattedAmount, type FormattedAmountProps$1 as FormattedAmountProps, FormattedHtmlMessage, type FormattedHtmlMessageProps, FormattedMessage, type FormattedMessageProps, _default as FormattedPercentage, type GetColor, IconProduct, type IconProductProps, IconProductSize, IconProductType, IconProductVariant, IconSystem, type IconSystemProps, IconSystemSize, IconSystemType, Infobox, type InfoboxProps, InfoboxSize, type InfoboxTextContent, InfoboxVariant, InputBase, type InputBaseProps, InputLabel, type InputLabelPassthroughProps, type InputLabelProps, InputLabelSize, InputSize, InputTextAlign, LabelTooltipPosition, Loader, LoaderOverlayBox, type LoaderOverlayBoxProps, type LoaderProps, LoaderSize, MaskedInput, MaskedInputBase, type MaskedInputBaseProps, MaskedInputField, type MaskedInputFieldProps, type MaskedInputProps, MediaType, MediaTypeProvider, type MediaTypeProviderProps, type MessageDescriptorWithPrimitiveValues, type MessageDescriptorWithValues, type MessageValues, Modal, type ModalOnClose, type ModalProps, ModalVerticalPosition, ModalWidthType, FormattedAmount as NextFormattedAmount, type FormattedAmountProps as NextFormattedAmountProps, NumberInput, NumberInputField, type NumberInputFieldProps, type NumberInputProps, Overflow, Paper, type PaperProps, PaperShadow, PhoneInput, PhoneInputField, type PhoneInputFieldProps, type PhoneInputProps, type PrimitiveMessageValues, ProgressPaper, type ProgressPaperProps, Radio, RadioButton, RadioButtonGroup, RadioButtonGroupControl, type RadioButtonGroupControlProps, RadioButtonGroupField, type RadioButtonGroupFieldProps, type RadioButtonGroupItem, RadioButtonGroupLayout, type RadioButtonGroupProps, type RadioButtonLabel, type RadioButtonProps, RadioControl, type RadioControlProps, RadioField, type RadioFieldProps, RadioGroup, RadioGroupControl, type RadioGroupControlProps, RadioGroupDirection, RadioGroupField, type RadioGroupFieldProps, type RadioGroupItem, type RadioGroupProps, RadioPosition, type RadioProps, ReasonForClosing, SearchInput, type SearchInputProps, Select, SelectControl, type SelectControlProps, SelectField, type SelectFieldProps, type SelectItem, type SelectItemOrder, SelectItemOrderSource, type SelectProps, SelectVariant, Slider, type SliderAriaValueTextFormatter, type SliderAriaValueTextFormatterDataContext, type SliderBreakpoint, SliderInput, SliderInputField, type SliderInputFieldProps, type SliderInputLimitExceededLiveTextFormatter, type SliderInputLimitExceededLiveTextFormatterDataContext, type SliderInputProps, SliderInputRoundingType, type SliderMinMaxLabels, type SliderProps, SliderStepType, type SliderSteps, Spacing, SpanButton, type SpanButtonProps, Stack, StackDirection, type StackProps, type TabItemType, Table, TableBody, type TableBodyProps, TableData, type TableDataProps, TableHead, TableHeadData, type TableHeadDataProps, type TableHeadProps, type TableProps, TableRow, type TableRowProps, TableTextAlign, TableVariant, Tabs, TabsActiveTabDefaultPosition, TabsItem, type TabsItemProps, type TabsProps, TabsSize, type TabsType, TabsVariant, Tag, TagIconPosition, type TagProps, TagSize, TagTextTransform, TagType, TextArea, TextAreaField, type TextAreaFieldProps, type TextAreaProps, TextDecoration, TextInput, TextInputField, type TextInputFieldProps, type TextInputProps, type Theme, type ThrownFormErrors, type ThrownFormLevelError, ThrownFormLevelErrorType, Toggle, type ToggleProps, TooltipCloseReason, type TooltipDescriptor, TooltipGeneral, type TooltipGeneralProps, TooltipInfo, TooltipInfoConditional, type TooltipInfoConditionalProps, type TooltipInfoDescriptor, TooltipInfoDisplayMethod, TooltipInfoDisplayableCheck, type TooltipInfoDisplayableCheckProps, type TooltipInfoProps, TooltipPlacement, type TooltipRenderParent, TrailingTextInput, type TrailingTextInputProps, Typography, type TypographyProps, TypographyTextAlign, TypographyVariant, type UseColorSchemeOptions, type UseColorSchemeParam, type UseDesignSystemOptions, type UseDesignSystemParam, type UseFormProps, type UseFormReturn, type UseFormSuccessOutcomeManagerReturn, type UseFormatAmountParam, type UseMediaTypeOptions, type UseMediaTypeParam, VisuallyHidden, type VisuallyHiddenProps, datePickerValueFormat, getColor, getTextDecorationStyle, identityFormatter, isRenderable, jsonFormatter, resolveBorderRadiusValue, resolveFlexWrapValue, resolveFontWeightValue, resolveOverflowValue, resolveSpacingValue, resolveTextDecorationValue, styled, theme, useChooseColor, useColorScheme, useCreateTooltipInfoDescriptor, useDesignSystem, useFieldConfig, useFieldLabels, useForm, useFormContext, useFormSuccessOutcomeManager, useFormatAmount$1 as useFormatAmount, useFormattedPercentage, useGetFormattedHtmlMessageIfDisplayable, useIsMessageDisplayable, useMediaType, useMessageFormatter, useFormatAmount as useNextFormatAmount, useRegisterFieldLabel, withFieldWrapper, withMaskedInputField };