@axa-fr/design-system-apollo-react 1.0.5-alpha.443 → 1.0.5-alpha.444

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.
@@ -1,5 +1,6 @@
1
1
  import { ComponentType, type HTMLAttributes } from "react";
2
2
  import { ProgressBarGroupProps } from "../ProgressBarGroup/ProgressBarGroupCommon";
3
+ import { ItemMessageProps } from "../Form/ItemMessage/ItemMessageCommon";
3
4
  export type StepperProps = {
4
5
  currentStepProgress?: number;
5
6
  currentStep: number;
@@ -8,7 +9,8 @@ export type StepperProps = {
8
9
  nbSteps?: 3 | 4 | 5 | 6 | 7 | 8;
9
10
  helper?: string;
10
11
  message?: string;
12
+ messageType?: ItemMessageProps["messageType"];
11
13
  titleLevel?: 1 | 2 | 3;
12
14
  ProgressBarGroupComponent: ComponentType<Omit<ProgressBarGroupProps, "ProgressBarComponent">>;
13
15
  } & Omit<HTMLAttributes<HTMLDivElement>, "role">;
14
- export declare const Stepper: ({ currentStepProgress, currentTitle, nbSteps, currentStep, currentSubtitle, className, ProgressBarGroupComponent, helper, message, titleLevel, ...props }: StepperProps) => import("react/jsx-runtime").JSX.Element;
16
+ export declare const Stepper: ({ currentStepProgress, currentTitle, nbSteps, currentStep, currentSubtitle, className, ProgressBarGroupComponent, helper, message, messageType, titleLevel, ...props }: StepperProps) => 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";
4
- export const Stepper = ({ currentStepProgress, currentTitle, nbSteps, currentStep, currentSubtitle, className, ProgressBarGroupComponent, helper, message, titleLevel = 2, ...props }) => {
3
+ import { ItemMessage, } from "../Form/ItemMessage/ItemMessageCommon";
4
+ export const Stepper = ({ currentStepProgress, currentTitle, nbSteps, currentStep, currentSubtitle, className, ProgressBarGroupComponent, helper, message, messageType = "success", titleLevel = 2, ...props }) => {
5
5
  const stepperId = useId();
6
6
  const Title = `h${titleLevel}`;
7
- return (_jsxs("div", { className: "af-stepper", ...props, children: [_jsxs("div", { className: "af-stepper__header", children: [_jsx(Title, { className: "af-stepper__title", "aria-describedby": stepperId, children: currentTitle }), Boolean(currentSubtitle) && (_jsx("p", { className: "af-stepper__subtitle", children: currentSubtitle }))] }), _jsx(ProgressBarGroupComponent, { label: currentTitle, className: className, currentStep: currentStep, nbSteps: nbSteps, currentStepProgress: currentStepProgress }), Boolean(helper) && _jsx("span", { className: "af-stepper__helper", children: helper }), _jsx(ItemMessage, { message: message, messageType: "success" })] }));
7
+ return (_jsxs("div", { className: "af-stepper", ...props, children: [_jsxs("div", { className: "af-stepper__header", children: [_jsx(Title, { className: "af-stepper__title", "aria-describedby": stepperId, children: currentTitle }), Boolean(currentSubtitle) && (_jsx("p", { className: "af-stepper__subtitle", children: currentSubtitle }))] }), _jsx(ProgressBarGroupComponent, { label: currentTitle, className: className, currentStep: currentStep, nbSteps: nbSteps, currentStepProgress: currentStepProgress }), Boolean(helper) && _jsx("span", { className: "af-stepper__helper", children: helper }), _jsx(ItemMessage, { message: message, messageType: messageType })] }));
8
8
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@axa-fr/design-system-apollo-react",
3
- "version": "1.0.5-alpha.443",
3
+ "version": "1.0.5-alpha.444",
4
4
  "description": "",
5
5
  "main": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",
@@ -46,8 +46,8 @@
46
46
  },
47
47
  "homepage": "https://github.com/AxaFrance/design-system#readme",
48
48
  "peerDependencies": {
49
- "@axa-fr/design-system-apollo-css": "1.0.5-alpha.443",
50
- "@axa-fr/design-system-look-and-feel-css": "1.0.5-alpha.443",
49
+ "@axa-fr/design-system-apollo-css": "1.0.5-alpha.444",
50
+ "@axa-fr/design-system-look-and-feel-css": "1.0.5-alpha.444",
51
51
  "@material-symbols/svg-400": ">= 0.19.0",
52
52
  "react": ">= 18"
53
53
  },