@axa-fr/canopee-react 2.0.0-alpha.71 → 2.0.0-alpha.73

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 (60) hide show
  1. package/dist/client.d.ts +1 -1
  2. package/dist/client.js +1 -1
  3. package/dist/distributeur/ItemFormHelper/ItemFormHelper.d.ts +8 -0
  4. package/dist/distributeur/ItemFormHelper/ItemFormHelper.js +31 -0
  5. package/dist/distributeur.d.ts +1 -0
  6. package/dist/distributeur.js +1 -0
  7. package/dist/prospect-client/Form/Checkbox/CardCheckbox/CardCheckboxApollo.js +1 -1
  8. package/dist/prospect-client/Form/Checkbox/CardCheckbox/CardCheckboxCommon.d.ts +1 -1
  9. package/dist/prospect-client/Form/Checkbox/CardCheckbox/CardCheckboxLF.js +1 -1
  10. package/dist/prospect-client/Form/Checkbox/CheckboxText/CheckboxTextApollo.js +1 -1
  11. package/dist/prospect-client/Form/Checkbox/CheckboxText/CheckboxTextCommon.d.ts +1 -1
  12. package/dist/prospect-client/Form/Checkbox/CheckboxText/CheckboxTextLF.js +1 -1
  13. package/dist/prospect-client/Form/Dropdown/DropdownApollo.js +1 -1
  14. package/dist/prospect-client/Form/Dropdown/DropdownCommon.d.ts +2 -2
  15. package/dist/prospect-client/Form/Dropdown/DropdownCommon.js +1 -1
  16. package/dist/prospect-client/Form/Dropdown/DropdownLF.js +1 -1
  17. package/dist/prospect-client/Form/FileUpload/InputFile/InputFileApollo.js +1 -1
  18. package/dist/prospect-client/Form/FileUpload/InputFile/InputFileCommon.d.ts +1 -1
  19. package/dist/prospect-client/Form/FileUpload/InputFile/InputFileCommon.js +1 -1
  20. package/dist/prospect-client/Form/FileUpload/InputFile/InputFileLF.js +1 -1
  21. package/dist/prospect-client/Form/FileUpload/ItemFile/ItemFileApollo.js +1 -1
  22. package/dist/prospect-client/Form/FileUpload/ItemFile/ItemFileCommon.d.ts +1 -1
  23. package/dist/prospect-client/Form/FileUpload/ItemFile/ItemFileLF.js +1 -1
  24. package/dist/prospect-client/Form/InputDate/InputDateApollo.js +1 -1
  25. package/dist/prospect-client/Form/InputDate/InputDateCommon.d.ts +2 -2
  26. package/dist/prospect-client/Form/InputDate/InputDateCommon.js +1 -1
  27. package/dist/prospect-client/Form/InputDate/InputDateLF.js +1 -1
  28. package/dist/prospect-client/Form/InputPhone/InputPhoneApollo.js +1 -1
  29. package/dist/prospect-client/Form/InputPhone/InputPhoneCommon.d.ts +2 -2
  30. package/dist/prospect-client/Form/InputPhone/InputPhoneCommon.js +1 -1
  31. package/dist/prospect-client/Form/InputPhone/InputPhoneLF.js +1 -1
  32. package/dist/prospect-client/Form/InputText/InputTextApollo.js +1 -1
  33. package/dist/prospect-client/Form/InputText/InputTextCommon.d.ts +3 -3
  34. package/dist/prospect-client/Form/InputText/InputTextCommon.js +1 -1
  35. package/dist/prospect-client/Form/InputText/InputTextLF.js +1 -1
  36. package/dist/prospect-client/Form/ItemMessage/{ItemMessageCommon.d.ts → ItemMessage.d.ts} +1 -0
  37. package/dist/prospect-client/Form/ItemMessage/{ItemMessageCommon.js → ItemMessage.js} +10 -9
  38. package/dist/prospect-client/Form/Radio/CardRadioGroup/CardRadioGroupApollo.js +1 -1
  39. package/dist/prospect-client/Form/Radio/CardRadioGroup/CardRadioGroupCommon.d.ts +3 -3
  40. package/dist/prospect-client/Form/Radio/CardRadioGroup/CardRadioGroupCommon.js +1 -1
  41. package/dist/prospect-client/Form/Radio/CardRadioGroup/CardRadioGroupLF.js +1 -1
  42. package/dist/prospect-client/Form/TextArea/TextAreaApollo.js +1 -1
  43. package/dist/prospect-client/Form/TextArea/TextAreaCommon.d.ts +2 -2
  44. package/dist/prospect-client/Form/TextArea/TextAreaCommon.js +1 -1
  45. package/dist/prospect-client/Form/TextArea/TextAreaLF.js +1 -1
  46. package/dist/prospect-client/List/ContentItemDuo/ContentItemDuoApollo.js +1 -1
  47. package/dist/prospect-client/List/ContentItemDuo/ContentItemDuoCommon.d.ts +2 -2
  48. package/dist/prospect-client/List/ContentItemDuo/ContentItemDuoCommon.js +1 -1
  49. package/dist/prospect-client/List/ContentItemDuo/ContentItemDuoLF.js +1 -1
  50. package/dist/prospect-client/Stepper/StepperApollo.js +2 -1
  51. package/dist/prospect-client/Stepper/StepperCommon.d.ts +3 -2
  52. package/dist/prospect-client/Stepper/StepperCommon.js +3 -3
  53. package/dist/prospect-client/Stepper/StepperLF.js +3 -2
  54. package/dist/prospect.d.ts +1 -1
  55. package/dist/prospect.js +1 -1
  56. package/package.json +2 -2
  57. package/dist/prospect-client/Form/ItemMessage/ItemMessageApollo.d.ts +0 -2
  58. package/dist/prospect-client/Form/ItemMessage/ItemMessageApollo.js +0 -2
  59. package/dist/prospect-client/Form/ItemMessage/ItemMessageLF.d.ts +0 -2
  60. package/dist/prospect-client/Form/ItemMessage/ItemMessageLF.js +0 -2
package/dist/client.d.ts CHANGED
@@ -30,7 +30,7 @@ export { InputPhone } from "./prospect-client/Form/InputPhone/InputPhoneLF";
30
30
  export { InputText } from "./prospect-client/Form/InputText/InputTextLF";
31
31
  export { InputTextAtom } from "./prospect-client/Form/InputTextAtom/InputTextAtomLF";
32
32
  export { ItemLabel } from "./prospect-client/Form/ItemLabel/ItemLabelLF";
33
- export { ItemMessage, itemMessageVariants, type ItemMessageVariants, } from "./prospect-client/Form/ItemMessage/ItemMessageLF";
33
+ export { ItemMessage, itemMessageVariants, type ItemMessageVariants, } from "./prospect-client/Form/ItemMessage/ItemMessage";
34
34
  export { ItemMultiSelect, type ItemMultiSelectProps, } from "./prospect-client/Form/ItemMultiSelect/ItemMultiSelectLF";
35
35
  export { MultiSelectList, type MultiSelectListProps, } from "./prospect-client/Form/MultiSelectList/MultiSelectListLF";
36
36
  export { CardRadio } from "./prospect-client/Form/Radio/CardRadio/CardRadioLF";
package/dist/client.js CHANGED
@@ -30,7 +30,7 @@ export { InputPhone } from "./prospect-client/Form/InputPhone/InputPhoneLF";
30
30
  export { InputText } from "./prospect-client/Form/InputText/InputTextLF";
31
31
  export { InputTextAtom } from "./prospect-client/Form/InputTextAtom/InputTextAtomLF";
32
32
  export { ItemLabel } from "./prospect-client/Form/ItemLabel/ItemLabelLF";
33
- export { ItemMessage, itemMessageVariants, } from "./prospect-client/Form/ItemMessage/ItemMessageLF";
33
+ export { ItemMessage, itemMessageVariants, } from "./prospect-client/Form/ItemMessage/ItemMessage";
34
34
  export { ItemMultiSelect, } from "./prospect-client/Form/ItemMultiSelect/ItemMultiSelectLF";
35
35
  export { MultiSelectList, } from "./prospect-client/Form/MultiSelectList/MultiSelectListLF";
36
36
  export { CardRadio } from "./prospect-client/Form/Radio/CardRadio/CardRadioLF";
@@ -0,0 +1,8 @@
1
+ import "@axa-fr/canopee-css/distributeur/ItemFormHelper/ItemFormHelper.css";
2
+ export type ItemFormHelperVariant = "todo" | "inprogress" | "validated";
3
+ export type ItemFormHelperProps = {
4
+ variant: ItemFormHelperVariant;
5
+ label?: string;
6
+ className?: string;
7
+ };
8
+ export declare const ItemFormHelper: ({ variant, label, className, }: ItemFormHelperProps) => import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,31 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import "@axa-fr/canopee-css/distributeur/ItemFormHelper/ItemFormHelper.css";
3
+ import checkSvg from "@material-symbols/svg-400/outlined/check.svg";
4
+ import toDoSvg from "@material-symbols/svg-400/outlined/circle.svg";
5
+ import wipSvg from "@material-symbols/svg-400/outlined/circle-fill.svg";
6
+ import { Svg } from "../Svg";
7
+ import { getClassName } from "../utilities/helpers/getClassName";
8
+ const variants = {
9
+ todo: {
10
+ icon: toDoSvg,
11
+ defaultLabel: "à compléter",
12
+ },
13
+ inprogress: {
14
+ icon: wipSvg,
15
+ defaultLabel: "en cours",
16
+ },
17
+ validated: {
18
+ icon: checkSvg,
19
+ defaultLabel: "validé",
20
+ },
21
+ };
22
+ export const ItemFormHelper = ({ variant, label, className, }) => {
23
+ const { icon, defaultLabel } = variants[variant];
24
+ const displayLabel = label ?? defaultLabel;
25
+ const componentClassName = getClassName({
26
+ baseClassName: "af-item-form-helper",
27
+ modifiers: [variant],
28
+ className,
29
+ });
30
+ return (_jsxs("div", { className: componentClassName, children: [_jsx(Svg, { src: icon, width: 12, height: 12 }), _jsx("span", { children: displayLabel })] }));
31
+ };
@@ -74,3 +74,4 @@ export { EditorialMessage, type EditorialMessageProps, type EditorialMessageType
74
74
  export { Timeline, type TimelineProps, type TimelineVariants, } from "./distributeur/Timeline/Timeline";
75
75
  export { CardButton, type CardButtonProps, } from "./distributeur/CardButton/CardButton";
76
76
  export { BaseCard, type BaseCardProps } from "./distributeur/Card/BaseCard";
77
+ export { ItemFormHelper, type ItemFormHelperProps, type ItemFormHelperVariant, } from "./distributeur/ItemFormHelper/ItemFormHelper";
@@ -63,3 +63,4 @@ export { EditorialMessage, } from "./distributeur/EditorialMessage/EditorialMess
63
63
  export { Timeline, } from "./distributeur/Timeline/Timeline";
64
64
  export { CardButton, } from "./distributeur/CardButton/CardButton";
65
65
  export { BaseCard } from "./distributeur/Card/BaseCard";
66
+ export { ItemFormHelper, } from "./distributeur/ItemFormHelper/ItemFormHelper";
@@ -1,5 +1,5 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
- import { ItemMessage } from "../../ItemMessage/ItemMessageApollo";
2
+ import { ItemMessage } from "../../ItemMessage/ItemMessage";
3
3
  import { CardCheckboxOption } from "../CardCheckboxOption/CardCheckboxOptionApollo";
4
4
  import { CheckboxText } from "../CheckboxText/CheckboxTextApollo";
5
5
  import { CardCheckboxCommon, } from "./CardCheckboxCommon";
@@ -1,6 +1,6 @@
1
1
  import { type ComponentType, type ReactNode } from "react";
2
2
  import type { GridContainerProps } from "../../../utilities/types/GridContainerProps";
3
- import type { ItemMessageProps } from "../../ItemMessage/ItemMessageCommon";
3
+ import type { ItemMessageProps } from "../../ItemMessage/ItemMessage";
4
4
  import type { CardCheckboxOptionProps } from "../CardCheckboxOption/CardCheckboxOptionCommon";
5
5
  import type { CheckboxTextProps } from "../CheckboxText/CheckboxTextCommon";
6
6
  type CheckboxOption = Omit<CardCheckboxOptionProps, "name" | "type">;
@@ -1,5 +1,5 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
- import { ItemMessage } from "../../ItemMessage/ItemMessageLF";
2
+ import { ItemMessage } from "../../ItemMessage/ItemMessage";
3
3
  import { CardCheckboxOption } from "../CardCheckboxOption/CardCheckboxOptionLF";
4
4
  import { CheckboxText } from "../CheckboxText/CheckboxTextLF";
5
5
  import { CardCheckboxCommon, } from "./CardCheckboxCommon";
@@ -1,6 +1,6 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import "@axa-fr/canopee-css/prospect/Form/Checkbox/CheckboxText/CheckboxTextApollo.css";
3
- import { ItemMessage } from "../../ItemMessage/ItemMessageApollo";
3
+ import { ItemMessage } from "../../ItemMessage/ItemMessage";
4
4
  import { Checkbox } from "../Checkbox/CheckboxApollo";
5
5
  import { CheckboxTextCommon, } from "./CheckboxTextCommon";
6
6
  export const CheckboxText = ({ ...props }) => (_jsx(CheckboxTextCommon, { ...props, CheckboxComponent: Checkbox, ItemMessageComponent: ItemMessage }));
@@ -1,6 +1,6 @@
1
1
  import { type ComponentType, type ReactNode } from "react";
2
2
  import type { GridContainerProps } from "../../../utilities/types/GridContainerProps";
3
- import type { ItemMessageProps } from "../../ItemMessage/ItemMessageCommon";
3
+ import type { ItemMessageProps } from "../../ItemMessage/ItemMessage";
4
4
  import type { CheckboxProps } from "../Checkbox/CheckboxCommon";
5
5
  export type CheckboxTextProps = {
6
6
  label: string | ReactNode;
@@ -1,6 +1,6 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import "@axa-fr/canopee-css/client/Form/Checkbox/CheckboxText/CheckboxTextLF.css";
3
- import { ItemMessage } from "../../ItemMessage/ItemMessageLF";
3
+ import { ItemMessage } from "../../ItemMessage/ItemMessage";
4
4
  import { Checkbox } from "../Checkbox/CheckboxLF";
5
5
  import { CheckboxTextCommon, } from "./CheckboxTextCommon";
6
6
  export const CheckboxText = ({ ...props }) => (_jsx(CheckboxTextCommon, { ...props, CheckboxComponent: Checkbox, ItemMessageComponent: ItemMessage }));
@@ -1,6 +1,6 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import "@axa-fr/canopee-css/prospect/Form/Dropdown/DropdownApollo.css";
3
3
  import { ItemLabel } from "../ItemLabel/ItemLabelApollo";
4
- import { ItemMessage } from "../ItemMessage/ItemMessageApollo";
4
+ import { ItemMessage } from "../ItemMessage/ItemMessage";
5
5
  import { DropdownCommon } from "./DropdownCommon";
6
6
  export const Dropdown = (props) => (_jsx(DropdownCommon, { ...props, ItemLabelComponent: ItemLabel, ItemMessageComponent: ItemMessage }));
@@ -1,7 +1,7 @@
1
1
  import { type ComponentProps, type ComponentPropsWithRef, type ComponentType } from "react";
2
2
  import type { GridContainerProps } from "../../utilities/types/GridContainerProps";
3
3
  import { ItemLabelCommon, type ItemLabelProps } from "../ItemLabel/ItemLabelCommon";
4
- import { ItemMessage, type ItemMessageProps } from "../ItemMessage/ItemMessageCommon";
4
+ import { type ItemMessageProps } from "../ItemMessage/ItemMessage";
5
5
  export type DropdownProps = ComponentPropsWithRef<"select"> & {
6
6
  id?: string;
7
7
  classModifier?: string;
@@ -13,7 +13,7 @@ export type DropdownProps = ComponentPropsWithRef<"select"> & {
13
13
  } & Pick<ItemLabelProps, "moreButtonLabel" | "onMoreButtonClick" | "sideButtonLabel" | "onSideButtonClick"> & Pick<ItemMessageProps, "message" | "messageType">;
14
14
  type DropdownCommonProps = DropdownProps & {
15
15
  ItemLabelComponent: ComponentType<Omit<ComponentProps<typeof ItemLabelCommon>, "ButtonComponent">>;
16
- ItemMessageComponent: ComponentType<ComponentProps<typeof ItemMessage>>;
16
+ ItemMessageComponent: ComponentType<ItemMessageProps>;
17
17
  };
18
18
  declare const DropdownCommon: {
19
19
  ({ id, required, label, placeholder, children, helper, message, messageType, description, moreButtonLabel, onMoreButtonClick, sideButtonLabel, onSideButtonClick, ItemLabelComponent, ItemMessageComponent, containerProps, ...otherProps }: DropdownCommonProps): import("react/jsx-runtime").JSX.Element;
@@ -2,7 +2,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import classNames from "classnames";
3
3
  import { useId, } from "react";
4
4
  import { ItemLabelCommon, } from "../ItemLabel/ItemLabelCommon";
5
- import { ItemMessage, } from "../ItemMessage/ItemMessageCommon";
5
+ import {} from "../ItemMessage/ItemMessage";
6
6
  const DropdownCommon = ({ id, required, label, placeholder, children, helper, message, messageType = "error", description, moreButtonLabel, onMoreButtonClick, sideButtonLabel, onSideButtonClick, ItemLabelComponent, ItemMessageComponent, containerProps, ...otherProps }) => {
7
7
  const idMessage = useId();
8
8
  let inputId = useId();
@@ -1,6 +1,6 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import "@axa-fr/canopee-css/client/Form/Dropdown/DropdownLF.css";
3
3
  import { ItemLabel } from "../ItemLabel/ItemLabelLF";
4
- import { ItemMessage } from "../ItemMessage/ItemMessageLF";
4
+ import { ItemMessage } from "../ItemMessage/ItemMessage";
5
5
  import { DropdownCommon } from "./DropdownCommon";
6
6
  export const Dropdown = (props) => (_jsx(DropdownCommon, { ...props, ItemLabelComponent: ItemLabel, ItemMessageComponent: ItemMessage }));
@@ -1,6 +1,6 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import { ItemLabel } from "../../ItemLabel/ItemLabelApollo";
3
- import { ItemMessage } from "../../ItemMessage/ItemMessageApollo";
3
+ import { ItemMessage } from "../../ItemMessage/ItemMessage";
4
4
  import { InputFileCommon } from "./InputFileCommon";
5
5
  import "@axa-fr/canopee-css/prospect/Form/FileUpload/InputFile/InputFileApollo.css";
6
6
  const InputFile = ({ ...props }) => {
@@ -1,7 +1,7 @@
1
1
  import { type ComponentPropsWithRef, type ComponentType, type MouseEventHandler, type ReactNode } from "react";
2
2
  import type { GridContainerProps } from "../../../utilities/types/GridContainerProps";
3
3
  import { type ItemLabelProps } from "../../ItemLabel/ItemLabelCommon";
4
- import { type ItemMessageProps } from "../../ItemMessage/ItemMessageCommon";
4
+ import { type ItemMessageProps } from "../../ItemMessage/ItemMessage";
5
5
  type LabelProps = Partial<Omit<ItemLabelProps, "children" | "label" | "description" | "sideButtonLabel" | "onSideButtonClick" | "moreButtonLabel" | "onMoreButtonClick">>;
6
6
  export type InputFileProps = Omit<ComponentPropsWithRef<"input">, "type"> & {
7
7
  /**
@@ -4,7 +4,7 @@ import { useId, } from "react";
4
4
  import { Svg } from "../../../Svg/Svg";
5
5
  import { getClassName } from "../../../utilities/getClassName";
6
6
  import {} from "../../ItemLabel/ItemLabelCommon";
7
- import {} from "../../ItemMessage/ItemMessageCommon";
7
+ import {} from "../../ItemMessage/ItemMessage";
8
8
  const DEFAULT_DROPZONE_LABELS = {
9
9
  dropzone: "Glisser et déposer un fichier",
10
10
  or: "ou",
@@ -1,6 +1,6 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import { ItemLabel } from "../../ItemLabel/ItemLabelLF";
3
- import { ItemMessage } from "../../ItemMessage/ItemMessageLF";
3
+ import { ItemMessage } from "../../ItemMessage/ItemMessage";
4
4
  import { InputFileCommon } from "./InputFileCommon";
5
5
  import "@axa-fr/canopee-css/client/Form/FileUpload/InputFile/InputFileLF.css";
6
6
  const InputFile = ({ ...props }) => (_jsx(InputFileCommon, { ...props, ItemLabelComponent: ItemLabel, ItemMessageComponent: ItemMessage }));
@@ -4,7 +4,7 @@ import visibilityIcon from "@material-symbols/svg-400/outlined/visibility-fill.s
4
4
  import { ClickIcon } from "../../../ClickIcon/ClickIconApollo";
5
5
  import { Icon } from "../../../Icon/IconApollo";
6
6
  import { Spinner } from "../../../Spinner/SpinnerApollo";
7
- import { ItemMessage } from "../../ItemMessage/ItemMessageApollo";
7
+ import { ItemMessage } from "../../ItemMessage/ItemMessage";
8
8
  import { ItemFileCommon } from "./ItemFileCommon";
9
9
  import "@axa-fr/canopee-css/prospect/ContentItemMono/ContentItemMonoApollo.css";
10
10
  import "@axa-fr/canopee-css/prospect/Form/FileUpload/ItemFile/ItemFileApollo.css";
@@ -2,7 +2,7 @@ import { type ComponentPropsWithoutRef, type ComponentType, type MouseEvent } fr
2
2
  import type { ClickIconProps } from "../../../ClickIcon/ClickIconCommon";
3
3
  import type { IconProps } from "../../../Icon/IconCommon";
4
4
  import type { SpinnerProps } from "../../../Spinner/SpinnerCommon";
5
- import type { ItemMessageProps } from "../../ItemMessage/ItemMessageCommon";
5
+ import type { ItemMessageProps } from "../../ItemMessage/ItemMessage";
6
6
  export type ItemFileProps = {
7
7
  /**
8
8
  * The JavaScript File object representing the uploaded file.
@@ -4,7 +4,7 @@ import visibilityIcon from "@material-symbols/svg-400/outlined/visibility-fill.s
4
4
  import { ClickIcon } from "../../../ClickIcon/ClickIconLF";
5
5
  import { Icon } from "../../../Icon/IconLF";
6
6
  import { Spinner } from "../../../Spinner/SpinnerLF";
7
- import { ItemMessage } from "../../ItemMessage/ItemMessageLF";
7
+ import { ItemMessage } from "../../ItemMessage/ItemMessage";
8
8
  import { ItemFileCommon } from "./ItemFileCommon";
9
9
  import "@axa-fr/canopee-css/client/ContentItemMono/ContentItemMonoLF.css";
10
10
  import "@axa-fr/canopee-css/client/Form/FileUpload/ItemFile/ItemFileLF.css";
@@ -1,7 +1,7 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import "@axa-fr/canopee-css/prospect/Form/InputDate/InputDateApollo.css";
3
3
  import { ItemLabel } from "../ItemLabel/ItemLabelApollo";
4
- import { ItemMessage } from "../ItemMessage/ItemMessageApollo";
4
+ import { ItemMessage } from "../ItemMessage/ItemMessage";
5
5
  import { InputDateCommon } from "./InputDateCommon";
6
6
  export const InputDate = ({ ...props }) => (_jsx(InputDateCommon, { ...props, ItemLabelComponent: ItemLabel, ItemMessageComponent: ItemMessage }));
7
7
  InputDate.displayName = "InputDate";
@@ -1,7 +1,7 @@
1
1
  import { type ComponentProps, type ComponentPropsWithRef, type ComponentType } from "react";
2
2
  import type { GridContainerProps } from "../../utilities/types/GridContainerProps";
3
3
  import { ItemLabelCommon, type ItemLabelProps } from "../ItemLabel/ItemLabelCommon";
4
- import { ItemMessage, type ItemMessageProps } from "../ItemMessage/ItemMessageCommon";
4
+ import { type ItemMessageProps } from "../ItemMessage/ItemMessage";
5
5
  import { type InputDateAtomProps } from "./InputDateAtom";
6
6
  export type InputDateProps = Omit<ComponentPropsWithRef<"input">, "value" | "min" | "max"> & {
7
7
  classModifier?: string;
@@ -16,7 +16,7 @@ export type InputDateProps = Omit<ComponentPropsWithRef<"input">, "value" | "min
16
16
  } & Partial<Pick<ItemLabelProps, "description" | "moreButtonLabel" | "onMoreButtonClick"> & ItemMessageProps>;
17
17
  type InputDateCommonProps = InputDateProps & {
18
18
  ItemLabelComponent: ComponentType<Omit<ComponentProps<typeof ItemLabelCommon>, "ButtonComponent">>;
19
- ItemMessageComponent: ComponentType<ComponentProps<typeof ItemMessage>>;
19
+ ItemMessageComponent: ComponentType<ItemMessageProps>;
20
20
  };
21
21
  declare const InputDateCommon: {
22
22
  ({ className, classModifier, helper, message, messageType, label, description, moreButtonLabel, onMoreButtonClick, ItemLabelComponent, ItemMessageComponent, required, hidePicker, max, min, containerProps, ...otherProps }: InputDateCommonProps): import("react/jsx-runtime").JSX.Element;
@@ -2,7 +2,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { useId, } from "react";
3
3
  import { getClassName } from "../../utilities/getClassName";
4
4
  import { ItemLabelCommon, } from "../ItemLabel/ItemLabelCommon";
5
- import { ItemMessage, } from "../ItemMessage/ItemMessageCommon";
5
+ import {} from "../ItemMessage/ItemMessage";
6
6
  import { InputDateAtom } from "./InputDateAtom";
7
7
  import { InputDateTextAtom } from "./InputDateTextAtom";
8
8
  const InputDateCommon = ({ className, classModifier = "", helper, message, messageType = "error", label, description, moreButtonLabel, onMoreButtonClick, ItemLabelComponent, ItemMessageComponent, required, hidePicker, max, min, containerProps, ...otherProps }) => {
@@ -1,7 +1,7 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import "@axa-fr/canopee-css/client/Form/InputDate/InputDateLF.css";
3
3
  import { ItemLabel } from "../ItemLabel/ItemLabelLF";
4
- import { ItemMessage } from "../ItemMessage/ItemMessageLF";
4
+ import { ItemMessage } from "../ItemMessage/ItemMessage";
5
5
  import { InputDateCommon } from "./InputDateCommon";
6
6
  export const InputDate = ({ ...props }) => (_jsx(InputDateCommon, { ...props, ItemLabelComponent: ItemLabel, ItemMessageComponent: ItemMessage }));
7
7
  InputDate.displayName = "InputDate";
@@ -1,7 +1,7 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import "@axa-fr/canopee-css/prospect/Form/InputPhone/InputPhoneApollo.css";
3
3
  import { ItemLabel } from "../ItemLabel/ItemLabelApollo";
4
- import { ItemMessage } from "../ItemMessage/ItemMessageApollo";
4
+ import { ItemMessage } from "../ItemMessage/ItemMessage";
5
5
  import { InputPhoneCommon } from "./InputPhoneCommon";
6
6
  import { InputTextAtom } from "../InputTextAtom/InputTextAtomApollo";
7
7
  import { Icon } from "../../Icon/IconApollo";
@@ -4,7 +4,7 @@ import { Icon } from "../../Icon/IconCommon";
4
4
  import type { GridContainerProps } from "../../utilities/types/GridContainerProps";
5
5
  import { InputTextAtom } from "../InputTextAtom/InputTextAtomCommon";
6
6
  import { ItemLabelCommon, type ItemLabelProps } from "../ItemLabel/ItemLabelCommon";
7
- import { ItemMessage, type ItemMessageProps } from "../ItemMessage/ItemMessageCommon";
7
+ import { type ItemMessageProps } from "../ItemMessage/ItemMessage";
8
8
  import { type OptionType } from "./InputPhone.types";
9
9
  export type InputPhoneProps = ComponentPropsWithRef<"input"> & {
10
10
  classModifier?: string;
@@ -21,7 +21,7 @@ export type InputPhoneProps = ComponentPropsWithRef<"input"> & {
21
21
  } & Pick<ItemLabelProps, "description" | "moreButtonLabel" | "onMoreButtonClick" | "sideButtonLabel" | "onSideButtonClick"> & Pick<ItemMessageProps, "message" | "messageType">;
22
22
  type InputPhoneCommonProps = InputPhoneProps & {
23
23
  ItemLabelComponent: ComponentType<Omit<ComponentProps<typeof ItemLabelCommon>, "ButtonComponent">>;
24
- ItemMessageComponent: ComponentType<ComponentProps<typeof ItemMessage>>;
24
+ ItemMessageComponent: ComponentType<ItemMessageProps>;
25
25
  InputTextComponent: ComponentType<ComponentProps<typeof InputTextAtom>>;
26
26
  IconComponent: ComponentType<ComponentProps<typeof Icon>>;
27
27
  };
@@ -3,7 +3,7 @@ import { useId, } from "react";
3
3
  import { Icon } from "../../Icon/IconCommon";
4
4
  import { InputTextAtom } from "../InputTextAtom/InputTextAtomCommon";
5
5
  import { ItemLabelCommon, } from "../ItemLabel/ItemLabelCommon";
6
- import { ItemMessage, } from "../ItemMessage/ItemMessageCommon";
6
+ import {} from "../ItemMessage/ItemMessage";
7
7
  import { CountryCodeSelect } from "./CountryCodeSelect";
8
8
  import {} from "./InputPhone.types";
9
9
  import { maskFrenchPhoneNumber } from "./maskFrenchPhoneNumber";
@@ -1,7 +1,7 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import "@axa-fr/canopee-css/client/Form/InputPhone/InputPhoneLF.css";
3
3
  import { ItemLabel } from "../ItemLabel/ItemLabelLF";
4
- import { ItemMessage } from "../ItemMessage/ItemMessageLF";
4
+ import { ItemMessage } from "../ItemMessage/ItemMessage";
5
5
  import { InputPhoneCommon } from "./InputPhoneCommon";
6
6
  import { InputTextAtom } from "../InputTextAtom/InputTextAtomLF";
7
7
  import { Icon } from "../../Icon/IconLF";
@@ -1,7 +1,7 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import "@axa-fr/canopee-css/prospect/Form/InputText/InputTextApollo.css";
3
3
  import { ItemLabel } from "../ItemLabel/ItemLabelApollo";
4
- import { ItemMessage } from "../ItemMessage/ItemMessageApollo";
4
+ import { ItemMessage } from "../ItemMessage/ItemMessage";
5
5
  import { InputTextCommon } from "./InputTextCommon";
6
6
  import { InputTextAtom } from "../InputTextAtom/InputTextAtomApollo";
7
7
  export const InputText = ({ ...props }) => (_jsx(InputTextCommon, { ...props, ItemLabelComponent: ItemLabel, ItemMessageComponent: ItemMessage, InputTextAtomComponent: InputTextAtom }));
@@ -1,8 +1,8 @@
1
1
  import { type ComponentProps, type ComponentType, type ReactNode } from "react";
2
- import type { GridContainerProps } from "../../utilities/types/GridContainerProps";
3
2
  import { InputTextAtom } from "../InputTextAtom/InputTextAtomCommon";
4
3
  import { ItemLabelCommon, type ItemLabelProps } from "../ItemLabel/ItemLabelCommon";
5
- import { ItemMessage, type ItemMessageProps } from "../ItemMessage/ItemMessageCommon";
4
+ import { type ItemMessageProps } from "../ItemMessage/ItemMessage";
5
+ import type { GridContainerProps } from "../../utilities/types/GridContainerProps";
6
6
  export type InputTextProps = ComponentProps<"input"> & {
7
7
  unit?: ReactNode;
8
8
  classModifier?: string;
@@ -12,7 +12,7 @@ export type InputTextProps = ComponentProps<"input"> & {
12
12
  } & Pick<ItemLabelProps, "description" | "moreButtonLabel" | "onMoreButtonClick" | "sideButtonLabel" | "onSideButtonClick"> & Pick<ItemMessageProps, "message" | "messageType">;
13
13
  type InputTextCommonProps = InputTextProps & {
14
14
  ItemLabelComponent: ComponentType<Omit<ComponentProps<typeof ItemLabelCommon>, "ButtonComponent">>;
15
- ItemMessageComponent: ComponentType<ComponentProps<typeof ItemMessage>>;
15
+ ItemMessageComponent: ComponentType<ItemMessageProps>;
16
16
  InputTextAtomComponent: ComponentType<ComponentProps<typeof InputTextAtom>>;
17
17
  };
18
18
  declare const InputTextCommon: {
@@ -2,7 +2,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { useId, } from "react";
3
3
  import { InputTextAtom } from "../InputTextAtom/InputTextAtomCommon";
4
4
  import { ItemLabelCommon, } from "../ItemLabel/ItemLabelCommon";
5
- import { ItemMessage, } from "../ItemMessage/ItemMessageCommon";
5
+ import {} from "../ItemMessage/ItemMessage";
6
6
  const InputTextCommon = ({ unit, className, classModifier = "", helper, message, messageType = "error", label, description, moreButtonLabel, onMoreButtonClick, required, sideButtonLabel, onSideButtonClick, ItemLabelComponent, ItemMessageComponent, InputTextAtomComponent, containerProps, ...otherProps }) => {
7
7
  let inputId = useId();
8
8
  inputId = otherProps.id || inputId;
@@ -1,7 +1,7 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import "@axa-fr/canopee-css/client/Form/InputText/InputTextLF.css";
3
3
  import { ItemLabel } from "../ItemLabel/ItemLabelLF";
4
- import { ItemMessage } from "../ItemMessage/ItemMessageLF";
4
+ import { ItemMessage } from "../ItemMessage/ItemMessage";
5
5
  import { InputTextCommon } from "./InputTextCommon";
6
6
  import { InputTextAtom } from "../InputTextAtom/InputTextAtomLF";
7
7
  export const InputText = ({ ...props }) => (_jsx(InputTextCommon, { ...props, ItemLabelComponent: ItemLabel, ItemMessageComponent: ItemMessage, InputTextAtomComponent: InputTextAtom }));
@@ -1,3 +1,4 @@
1
+ import "@axa-fr/canopee-css/prospect/Form/ItemMessage/ItemMessageAll.css";
1
2
  import type { ReactNode } from "react";
2
3
  export declare const itemMessageVariants: {
3
4
  readonly error: "error";
@@ -1,23 +1,24 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import "@axa-fr/canopee-css/prospect/Form/ItemMessage/ItemMessageAll.css";
2
3
  import successIcon from "@material-symbols/svg-400/outlined/check_circle-fill.svg";
3
4
  import errorIcon from "@material-symbols/svg-400/outlined/error-fill.svg";
4
5
  import warningIcon from "@material-symbols/svg-400/outlined/warning-fill.svg";
5
- import { Svg } from "../../Svg/Svg";
6
+ import { Icon } from "../../Icon/IconCommon";
6
7
  export const itemMessageVariants = {
7
8
  error: "error",
8
9
  success: "success",
9
10
  warning: "warning",
10
11
  };
12
+ const getIcon = (messageType) => {
13
+ if (messageType === "success")
14
+ return successIcon;
15
+ if (messageType === "warning")
16
+ return warningIcon;
17
+ return errorIcon;
18
+ };
11
19
  export const ItemMessage = ({ message, id, messageType = "error", }) => {
12
20
  if (!message) {
13
21
  return null;
14
22
  }
15
- const getIcon = () => {
16
- if (messageType === "success")
17
- return successIcon;
18
- if (messageType === "warning")
19
- return warningIcon;
20
- return errorIcon;
21
- };
22
- return (_jsxs("small", { id: id, className: `af-item-message af-item-message--${messageType}`, role: messageType === "success" ? undefined : "alert", "aria-live": "assertive", children: [_jsx(Svg, { src: getIcon(), className: "af-item-message__icon", "aria-hidden": "true" }), _jsx("span", { className: "af-item-message__message", children: message })] }));
23
+ return (_jsxs("small", { id: id, className: `af-item-message af-item-message--${messageType}`, role: messageType === "success" ? undefined : "alert", "aria-live": "assertive", children: [_jsx(Icon, { src: getIcon(messageType), size: "XS", variant: messageType, "aria-hidden": "true" }), _jsx("span", { className: "af-item-message__message", children: message })] }));
23
24
  };
@@ -1,5 +1,5 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
- import { ItemMessage } from "../../ItemMessage/ItemMessageApollo";
2
+ import { ItemMessage } from "../../ItemMessage/ItemMessage";
3
3
  import { CardRadio } from "../CardRadio/CardRadioApollo";
4
4
  import { CardRadioGroupCommon, } from "./CardRadioGroupCommon";
5
5
  import "@axa-fr/canopee-css/prospect/Form/Radio/CardRadioGroup/CardRadioGroupApollo.css";
@@ -1,6 +1,6 @@
1
- import { type ComponentProps, type ComponentType, type PropsWithChildren, type ReactNode } from "react";
1
+ import { type ComponentType, type PropsWithChildren, type ReactNode } from "react";
2
2
  import type { GridContainerProps } from "../../../utilities/types/GridContainerProps";
3
- import { ItemMessage, type ItemMessageProps } from "../../ItemMessage/ItemMessageCommon";
3
+ import { type ItemMessageProps } from "../../ItemMessage/ItemMessage";
4
4
  import { type CardRadioProps } from "../CardRadio/CardRadioCommon";
5
5
  type RadioOption = Omit<CardRadioProps, "name" | "type" | "variant">;
6
6
  export type CardRadioGroupProps = Omit<CardRadioProps, "value" | "label" | "type" | "variant" | "icon" | "src" | "basePictureProps" | "description" | "subtitle" | "children" | "position"> & {
@@ -13,7 +13,7 @@ export type CardRadioGroupProps = Omit<CardRadioProps, "value" | "label" | "type
13
13
  } & PropsWithChildren & Partial<ItemMessageProps>;
14
14
  export type CardRadioCommonProps = CardRadioGroupProps & {
15
15
  CardRadioComponent: ComponentType<CardRadioProps>;
16
- ItemMessageComponent: ComponentType<ComponentProps<typeof ItemMessage>>;
16
+ ItemMessageComponent: ComponentType<ItemMessageProps>;
17
17
  };
18
18
  declare const CardRadioGroupCommon: {
19
19
  ({ className, label, description, required, options, cardStyle, position, message, messageType, name, id, CardRadioComponent, ItemMessageComponent, containerProps, ...inputProps }: CardRadioCommonProps): import("react/jsx-runtime").JSX.Element;
@@ -1,6 +1,6 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { useId, } from "react";
3
- import { ItemMessage, } from "../../ItemMessage/ItemMessageCommon";
3
+ import {} from "../../ItemMessage/ItemMessage";
4
4
  import {} from "../CardRadio/CardRadioCommon";
5
5
  const CardRadioGroupCommon = ({ className, label, description, required, options, cardStyle, position = cardStyle === "vertical" ? "column" : "line", message, messageType = "error", name, id, CardRadioComponent, ItemMessageComponent, containerProps, ...inputProps }) => {
6
6
  const generatedId = useId();
@@ -1,5 +1,5 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
- import { ItemMessage } from "../../ItemMessage/ItemMessageLF";
2
+ import { ItemMessage } from "../../ItemMessage/ItemMessage";
3
3
  import { CardRadio } from "../CardRadio/CardRadioLF";
4
4
  import { CardRadioGroupCommon, } from "./CardRadioGroupCommon";
5
5
  import "@axa-fr/canopee-css/client/Form/Radio/CardRadioGroup/CardRadioGroupLF.css";
@@ -1,7 +1,7 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import "@axa-fr/canopee-css/prospect/Form/TextArea/TextAreaApollo.css";
3
3
  import { ItemLabel } from "../ItemLabel/ItemLabelApollo";
4
- import { ItemMessage } from "../ItemMessage/ItemMessageApollo";
4
+ import { ItemMessage } from "../ItemMessage/ItemMessage";
5
5
  import { TextAreaCommon } from "./TextAreaCommon";
6
6
  export const TextArea = ({ ...props }) => (_jsx(TextAreaCommon, { ...props, ItemLabelComponent: ItemLabel, ItemMessageComponent: ItemMessage }));
7
7
  TextArea.displayName = "TextArea";
@@ -1,7 +1,7 @@
1
1
  import { type ComponentProps, type ComponentPropsWithRef, type ComponentType } from "react";
2
2
  import type { GridContainerProps } from "../../utilities/types/GridContainerProps";
3
3
  import { ItemLabelCommon, type ItemLabelProps } from "../ItemLabel/ItemLabelCommon";
4
- import { ItemMessage, type ItemMessageProps } from "../ItemMessage/ItemMessageCommon";
4
+ import { type ItemMessageProps } from "../ItemMessage/ItemMessage";
5
5
  export type TextAreaProps = ComponentPropsWithRef<"textarea"> & {
6
6
  label?: ItemLabelProps["children"];
7
7
  helper?: string;
@@ -9,7 +9,7 @@ export type TextAreaProps = ComponentPropsWithRef<"textarea"> & {
9
9
  } & Pick<ItemLabelProps, "description" | "moreButtonLabel" | "onMoreButtonClick" | "sideButtonLabel" | "onSideButtonClick"> & Pick<ItemMessageProps, "message" | "messageType">;
10
10
  type TextAreaCommonProps = TextAreaProps & {
11
11
  ItemLabelComponent: ComponentType<Omit<ComponentProps<typeof ItemLabelCommon>, "ButtonComponent">>;
12
- ItemMessageComponent: ComponentType<ComponentProps<typeof ItemMessage>>;
12
+ ItemMessageComponent: ComponentType<ItemMessageProps>;
13
13
  };
14
14
  declare const TextAreaCommon: {
15
15
  ({ id, className, label, description, helper, message, messageType, moreButtonLabel, onMoreButtonClick, required, sideButtonLabel, ItemLabelComponent, ItemMessageComponent, onSideButtonClick, placeholder, containerProps, ...inputProps }: TextAreaCommonProps): import("react/jsx-runtime").JSX.Element;
@@ -2,7 +2,7 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { useId, } from "react";
3
3
  import { getClassName } from "../../utilities/getClassName";
4
4
  import { ItemLabelCommon, } from "../ItemLabel/ItemLabelCommon";
5
- import { ItemMessage, } from "../ItemMessage/ItemMessageCommon";
5
+ import {} from "../ItemMessage/ItemMessage";
6
6
  const TextAreaCommon = ({ id, className, label, description, helper, message, messageType = "error", moreButtonLabel, onMoreButtonClick, required, sideButtonLabel, ItemLabelComponent, ItemMessageComponent, onSideButtonClick, placeholder = " ", containerProps, ...inputProps }) => {
7
7
  const generatedId = useId();
8
8
  const inputId = id ?? generatedId;
@@ -1,7 +1,7 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import "@axa-fr/canopee-css/client/Form/TextArea/TextAreaLF.css";
3
3
  import { ItemLabel } from "../ItemLabel/ItemLabelLF";
4
- import { ItemMessage } from "../ItemMessage/ItemMessageLF";
4
+ import { ItemMessage } from "../ItemMessage/ItemMessage";
5
5
  import { TextAreaCommon } from "./TextAreaCommon";
6
6
  export const TextArea = ({ ...props }) => (_jsx(TextAreaCommon, { ...props, ItemLabelComponent: ItemLabel, ItemMessageComponent: ItemMessage }));
7
7
  TextArea.displayName = "TextArea";
@@ -2,5 +2,5 @@ import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import "@axa-fr/canopee-css/prospect/List/ContentItemDuo/ContentItemDuoApollo.css";
3
3
  import { Button } from "../../Button/ButtonApollo";
4
4
  import { ContentItemDuoCommon, } from "./ContentItemDuoCommon";
5
- import { ItemMessage } from "../../Form/ItemMessage/ItemMessageApollo";
5
+ import { ItemMessage } from "../../Form/ItemMessage/ItemMessage";
6
6
  export const ContentItemDuo = (props) => (_jsx(ContentItemDuoCommon, { ...props, ButtonComponent: Button, ItemMessageComponent: ItemMessage }));
@@ -1,6 +1,6 @@
1
1
  import { type ComponentProps, type ComponentType, type ReactNode } from "react";
2
2
  import type { ButtonProps } from "../../Button/ButtonCommon";
3
- import { ItemMessage, type ItemMessageProps } from "../../Form/ItemMessage/ItemMessageCommon";
3
+ import { type ItemMessageProps } from "../../Form/ItemMessage/ItemMessage";
4
4
  type ContentItemDuoPositions = {
5
5
  position?: "horizontal";
6
6
  size?: "small" | "large";
@@ -16,7 +16,7 @@ export type ContentItemDuoProps = {
16
16
  } & Pick<ItemMessageProps, "message" | "messageType"> & ContentItemDuoPositions & ComponentProps<"div">;
17
17
  type ContentItemDuoCommonProps = ContentItemDuoProps & {
18
18
  ButtonComponent: ComponentType<ButtonProps>;
19
- ItemMessageComponent: ComponentType<ComponentProps<typeof ItemMessage>>;
19
+ ItemMessageComponent: ComponentType<ItemMessageProps>;
20
20
  };
21
21
  export declare const ContentItemDuoCommon: ({ label, value, position, size, className, buttonText, onButtonClick, ButtonComponent, message, messageType, ItemMessageComponent, ...containerProps }: ContentItemDuoCommonProps) => import("react/jsx-runtime").JSX.Element;
22
22
  export {};
@@ -1,7 +1,7 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import {} from "react";
3
- import { ItemMessage, } from "../../Form/ItemMessage/ItemMessageCommon";
4
3
  import { getClassName } from "../../utilities/getClassName";
4
+ import {} from "../../Form/ItemMessage/ItemMessage";
5
5
  export const ContentItemDuoCommon = ({ label, value, position = "horizontal", size = "large", className, buttonText, onButtonClick, ButtonComponent, message, messageType, ItemMessageComponent, ...containerProps }) => {
6
6
  const componentClassName = getClassName({
7
7
  baseClassName: "af-content-item-duo",
@@ -2,5 +2,5 @@ import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import "@axa-fr/canopee-css/client/List/ContentItemDuo/ContentItemDuoLF.css";
3
3
  import { Button } from "../../Button/ButtonLF";
4
4
  import { ContentItemDuoCommon, } from "./ContentItemDuoCommon";
5
- import { ItemMessage } from "../../Form/ItemMessage/ItemMessageLF";
5
+ import { ItemMessage } from "../../Form/ItemMessage/ItemMessage";
6
6
  export const ContentItemDuo = (props) => (_jsx(ContentItemDuoCommon, { ...props, ButtonComponent: Button, ItemMessageComponent: ItemMessage }));
@@ -2,5 +2,6 @@ import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import "@axa-fr/canopee-css/prospect/Stepper/StepperApollo.css";
3
3
  import { Heading } from "../Heading/HeadingApollo";
4
4
  import { ProgressBarGroup } from "../ProgressBarGroup/ProgressBarGroupApollo";
5
+ import { ItemMessage } from "../Form/ItemMessage/ItemMessage";
5
6
  import { StepperCommon } from "./StepperCommon";
6
- export const Stepper = (props) => (_jsx(StepperCommon, { ...props, ProgressBarGroupComponent: ProgressBarGroup, HeadingComponent: Heading }));
7
+ export const Stepper = (props) => (_jsx(StepperCommon, { ...props, ProgressBarGroupComponent: ProgressBarGroup, HeadingComponent: Heading, ItemMessageComponent: ItemMessage }));
@@ -1,5 +1,5 @@
1
1
  import { type ComponentType, type HTMLAttributes, type ReactNode } from "react";
2
- import { type ItemMessageProps } from "../Form/ItemMessage/ItemMessageCommon";
2
+ import { type ItemMessageProps } from "../Form/ItemMessage/ItemMessage";
3
3
  import { type ProgressBarGroupProps } from "../ProgressBarGroup/ProgressBarGroupCommon";
4
4
  import type { HeadingCommonProps } from "../Heading/HeadingCommon";
5
5
  import type { HeadingLevel } from "../Heading/types";
@@ -19,5 +19,6 @@ export type StepperProps = {
19
19
  export type StepperCommonProps = StepperProps & {
20
20
  ProgressBarGroupComponent: ComponentType<ProgressBarGroupProps>;
21
21
  HeadingComponent: ComponentType<HeadingCommonProps>;
22
+ ItemMessageComponent: ComponentType<ItemMessageProps>;
22
23
  };
23
- export declare const StepperCommon: ({ currentStepProgress, currentTitle, nbSteps, currentStep, currentSubtitle, className, ProgressBarGroupComponent, HeadingComponent, helper, icon, iconProps, message, messageType, titleLevel, ...props }: StepperCommonProps) => import("react/jsx-runtime").JSX.Element;
24
+ export declare const StepperCommon: ({ currentStepProgress, currentTitle, nbSteps, currentStep, currentSubtitle, className, ProgressBarGroupComponent, HeadingComponent, ItemMessageComponent, helper, icon, iconProps, message, messageType, titleLevel, ...props }: StepperCommonProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,8 +1,8 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { useId, } from "react";
3
- import { ItemMessage, } from "../Form/ItemMessage/ItemMessageCommon";
3
+ import {} from "../Form/ItemMessage/ItemMessage";
4
4
  import {} from "../ProgressBarGroup/ProgressBarGroupCommon";
5
- export const StepperCommon = ({ currentStepProgress, currentTitle, nbSteps, currentStep, currentSubtitle, className, ProgressBarGroupComponent, HeadingComponent, helper, icon, iconProps, message, messageType = "success", titleLevel = 2, ...props }) => {
5
+ export const StepperCommon = ({ currentStepProgress, currentTitle, nbSteps, currentStep, currentSubtitle, className, ProgressBarGroupComponent, HeadingComponent, ItemMessageComponent, helper, icon, iconProps, message, messageType = "success", titleLevel = 2, ...props }) => {
6
6
  const titleId = useId();
7
- return (_jsxs("div", { className: "af-stepper", ...props, tabIndex: undefined, children: [_jsx("div", { className: "af-stepper__header", id: titleId, children: _jsx(HeadingComponent, { level: titleLevel, icon: icon, iconProps: iconProps, firstSubtitle: currentSubtitle, children: currentTitle }) }), _jsx(ProgressBarGroupComponent, { className: className, currentStep: currentStep, stepsCount: nbSteps, currentStepProgress: currentStepProgress, "aria-labelledby": titleId }), Boolean(helper) && _jsx("span", { className: "af-stepper__helper", children: helper }), _jsx(ItemMessage, { message: message, messageType: messageType })] }));
7
+ return (_jsxs("div", { className: "af-stepper", ...props, tabIndex: undefined, children: [_jsx("div", { className: "af-stepper__header", id: titleId, children: _jsx(HeadingComponent, { level: titleLevel, icon: icon, iconProps: iconProps, firstSubtitle: currentSubtitle, children: currentTitle }) }), _jsx(ProgressBarGroupComponent, { className: className, currentStep: currentStep, stepsCount: nbSteps, currentStepProgress: currentStepProgress, "aria-labelledby": titleId }), Boolean(helper) && _jsx("span", { className: "af-stepper__helper", children: helper }), _jsx(ItemMessageComponent, { message: message, messageType: messageType })] }));
8
8
  };
@@ -1,6 +1,7 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
2
  import "@axa-fr/canopee-css/client/Stepper/StepperLF.css";
3
- import { Heading } from "../Heading/HeadingLF";
4
3
  import { ProgressBarGroup } from "../ProgressBarGroup/ProgressBarGroupLF";
5
4
  import { StepperCommon } from "./StepperCommon";
6
- export const Stepper = (props) => (_jsx(StepperCommon, { ...props, ProgressBarGroupComponent: ProgressBarGroup, HeadingComponent: Heading }));
5
+ import { Heading } from "../Heading/HeadingLF";
6
+ import { ItemMessage } from "../Form/ItemMessage/ItemMessage";
7
+ export const Stepper = (props) => (_jsx(StepperCommon, { ...props, ProgressBarGroupComponent: ProgressBarGroup, HeadingComponent: Heading, ItemMessageComponent: ItemMessage }));
@@ -30,7 +30,7 @@ export { InputPhone } from "./prospect-client/Form/InputPhone/InputPhoneApollo";
30
30
  export { InputText } from "./prospect-client/Form/InputText/InputTextApollo";
31
31
  export { InputTextAtom } from "./prospect-client/Form/InputTextAtom/InputTextAtomApollo";
32
32
  export { ItemLabel } from "./prospect-client/Form/ItemLabel/ItemLabelApollo";
33
- export { ItemMessage, itemMessageVariants, type ItemMessageVariants, } from "./prospect-client/Form/ItemMessage/ItemMessageApollo";
33
+ export { ItemMessage, itemMessageVariants, type ItemMessageVariants, } from "./prospect-client/Form/ItemMessage/ItemMessage";
34
34
  export { ItemMultiSelect, type ItemMultiSelectProps, } from "./prospect-client/Form/ItemMultiSelect/ItemMultiSelectApollo";
35
35
  export { MultiSelectList, type MultiSelectListProps, } from "./prospect-client/Form/MultiSelectList/MultiSelectListApollo";
36
36
  export { CardRadio } from "./prospect-client/Form/Radio/CardRadio/CardRadioApollo";
package/dist/prospect.js CHANGED
@@ -30,7 +30,7 @@ export { InputPhone } from "./prospect-client/Form/InputPhone/InputPhoneApollo";
30
30
  export { InputText } from "./prospect-client/Form/InputText/InputTextApollo";
31
31
  export { InputTextAtom } from "./prospect-client/Form/InputTextAtom/InputTextAtomApollo";
32
32
  export { ItemLabel } from "./prospect-client/Form/ItemLabel/ItemLabelApollo";
33
- export { ItemMessage, itemMessageVariants, } from "./prospect-client/Form/ItemMessage/ItemMessageApollo";
33
+ export { ItemMessage, itemMessageVariants, } from "./prospect-client/Form/ItemMessage/ItemMessage";
34
34
  export { ItemMultiSelect, } from "./prospect-client/Form/ItemMultiSelect/ItemMultiSelectApollo";
35
35
  export { MultiSelectList, } from "./prospect-client/Form/MultiSelectList/MultiSelectListApollo";
36
36
  export { CardRadio } from "./prospect-client/Form/Radio/CardRadio/CardRadioApollo";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@axa-fr/canopee-react",
3
- "version": "2.0.0-alpha.71",
3
+ "version": "2.0.0-alpha.73",
4
4
  "description": "Package React - Design System Canopée",
5
5
  "exports": {
6
6
  "./distributeur": {
@@ -53,7 +53,7 @@
53
53
  },
54
54
  "homepage": "https://github.com/AxaFrance/design-system#readme",
55
55
  "peerDependencies": {
56
- "@axa-fr/canopee-css": "2.0.0-alpha.71",
56
+ "@axa-fr/canopee-css": "2.0.0-alpha.73",
57
57
  "@material-symbols/svg-400": ">= 0.19.0",
58
58
  "@material-symbols/svg-700": ">= 0.19.0",
59
59
  "react": ">= 19"
@@ -1,2 +0,0 @@
1
- import "@axa-fr/canopee-css/prospect/Form/ItemMessage/ItemMessageApollo.css";
2
- export { ItemMessage, itemMessageVariants, type ItemMessageVariants, } from "./ItemMessageCommon";
@@ -1,2 +0,0 @@
1
- import "@axa-fr/canopee-css/prospect/Form/ItemMessage/ItemMessageApollo.css";
2
- export { ItemMessage, itemMessageVariants, } from "./ItemMessageCommon";
@@ -1,2 +0,0 @@
1
- import "@axa-fr/canopee-css/client/Form/ItemMessage/ItemMessageLF.css";
2
- export { ItemMessage, itemMessageVariants, type ItemMessageVariants, } from "./ItemMessageCommon";
@@ -1,2 +0,0 @@
1
- import "@axa-fr/canopee-css/client/Form/ItemMessage/ItemMessageLF.css";
2
- export { ItemMessage, itemMessageVariants, } from "./ItemMessageCommon";