@axa-fr/design-system-look-and-feel-react 1.0.5-alpha.253 → 1.0.5-alpha.254
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/List/ContentItemDuo/ContentItemDuo.d.ts +1 -14
- package/dist/List/ContentItemDuo/ContentItemDuo.js +1 -17
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/package.json +3 -3
- package/dist/List/ContentItemDuo/index.d.ts +0 -2
- package/dist/List/ContentItemDuo/index.js +0 -2
@@ -1,14 +1 @@
|
|
1
|
-
|
2
|
-
type ContentItemDuoProps = {
|
3
|
-
label: string;
|
4
|
-
value: ReactNode;
|
5
|
-
isVertical?: boolean;
|
6
|
-
className?: string;
|
7
|
-
classModifier?: string;
|
8
|
-
isShowingDoneIcon?: boolean;
|
9
|
-
isShowingCloseIcon?: boolean;
|
10
|
-
buttonText?: string;
|
11
|
-
onButtonClick?: () => void;
|
12
|
-
};
|
13
|
-
export declare const ContentItemDuo: ({ label, value, isVertical, className, classModifier, isShowingDoneIcon, isShowingCloseIcon, buttonText, onButtonClick, }: ContentItemDuoProps) => import("react/jsx-runtime").JSX.Element;
|
14
|
-
export {};
|
1
|
+
export { ContentItemDuo } from "@axa-fr/design-system-apollo-react/lf";
|
@@ -1,17 +1 @@
|
|
1
|
-
|
2
|
-
import checkIcon from "@material-symbols/svg-400/outlined/check.svg";
|
3
|
-
import closeIcon from "@material-symbols/svg-400/outlined/close.svg";
|
4
|
-
import { useMemo } from "react";
|
5
|
-
import { Button, Svg } from "../..";
|
6
|
-
import { getComponentClassName } from "../../utilities";
|
7
|
-
export const ContentItemDuo = ({ label, value, isVertical = false, className, classModifier, isShowingDoneIcon = false, isShowingCloseIcon = false, buttonText, onButtonClick, }) => {
|
8
|
-
const componentClassName = useMemo(() => {
|
9
|
-
const classModifiers = [classModifier];
|
10
|
-
if (isVertical) {
|
11
|
-
classModifiers.push("vertical");
|
12
|
-
}
|
13
|
-
return getComponentClassName("af-content-item-duo", className, classModifiers.filter(Boolean).join(" "));
|
14
|
-
}, [classModifier, className, isVertical]);
|
15
|
-
const iconContainerModifier = useMemo(() => ` af-content-item-duo__icon--${isShowingDoneIcon ? "done" : "close"}`, [isShowingDoneIcon]);
|
16
|
-
return (_jsxs("div", { className: componentClassName, children: [(isShowingDoneIcon || isShowingCloseIcon) && (_jsxs("div", { className: `af-content-item-duo__icon${iconContainerModifier}`, children: [isShowingDoneIcon && _jsx(Svg, { src: checkIcon }), isShowingCloseIcon && _jsx(Svg, { src: closeIcon })] })), _jsx("p", { className: "af-content-item-duo__label", children: label }), typeof value === "string" ? (_jsx("p", { className: "af-content-item-duo__value", children: value })) : (_jsx("div", { className: "af-content-item-duo__value", children: value })), buttonText && (_jsx("div", { className: "af-content-item-duo__button", children: _jsx(Button, { variant: "ghost", onClick: onButtonClick, children: buttonText }) }))] }));
|
17
|
-
};
|
1
|
+
export { ContentItemDuo } from "@axa-fr/design-system-apollo-react/lf";
|
package/dist/index.d.ts
CHANGED
@@ -25,7 +25,7 @@ export { BurgerMenu, Header, NavBar, PreviousLink } from "./Layout/Header";
|
|
25
25
|
export { Link } from "./Link/Link";
|
26
26
|
export { List } from "./List";
|
27
27
|
export { ClickItem, createClickItemParent } from "./List/ClickItem";
|
28
|
-
export { ContentItemDuo } from "./List/ContentItemDuo";
|
28
|
+
export { ContentItemDuo } from "./List/ContentItemDuo/ContentItemDuo";
|
29
29
|
export { ContentItemMono, ContentItemMonoSize } from "./List/ContentItemMono";
|
30
30
|
export { ContentTabItem, ContentTabList } from "./List/ContentTabList";
|
31
31
|
export { Spinner, type SpinnerVariants, spinnerVariants, } from "./Spinner/Spinner";
|
package/dist/index.js
CHANGED
@@ -24,7 +24,7 @@ export { BurgerMenu, Header, NavBar, PreviousLink } from "./Layout/Header";
|
|
24
24
|
export { Link } from "./Link/Link";
|
25
25
|
export { List } from "./List";
|
26
26
|
export { ClickItem, createClickItemParent } from "./List/ClickItem";
|
27
|
-
export { ContentItemDuo } from "./List/ContentItemDuo";
|
27
|
+
export { ContentItemDuo } from "./List/ContentItemDuo/ContentItemDuo";
|
28
28
|
export { ContentItemMono, ContentItemMonoSize } from "./List/ContentItemMono";
|
29
29
|
export { ContentTabItem, ContentTabList } from "./List/ContentTabList";
|
30
30
|
export { Spinner, spinnerVariants, } from "./Spinner/Spinner";
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@axa-fr/design-system-look-and-feel-react",
|
3
|
-
"version": "1.0.5-alpha.
|
3
|
+
"version": "1.0.5-alpha.254",
|
4
4
|
"description": "",
|
5
5
|
"main": "./dist/index.js",
|
6
6
|
"types": "./dist/index.d.ts",
|
@@ -47,10 +47,10 @@
|
|
47
47
|
},
|
48
48
|
"homepage": "https://github.com/AxaFrance/design-system#readme",
|
49
49
|
"peerDependencies": {
|
50
|
-
"@axa-fr/design-system-look-and-feel-css": "1.0.5-alpha.
|
50
|
+
"@axa-fr/design-system-look-and-feel-css": "1.0.5-alpha.254",
|
51
51
|
"@material-symbols/svg-400": ">= 0.19.0",
|
52
52
|
"react": ">= 18",
|
53
|
-
"@axa-fr/design-system-apollo-react": "1.0.5-alpha.
|
53
|
+
"@axa-fr/design-system-apollo-react": "1.0.5-alpha.254"
|
54
54
|
},
|
55
55
|
"peerDependenciesMeta": {
|
56
56
|
"@material-symbols/svg-400": {
|