@vodafone_de/brix-components 8.1.2 → 8.1.3
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/ToggleButtonContext-TOVux5cw.js +13 -0
- package/dist/components/Button/getButtonIcon.d.ts +2 -2
- package/dist/components/Button/index.d.ts +1 -1
- package/dist/components/Button/index.js +3 -3
- package/dist/components/Button/props.d.ts +8 -3
- package/dist/components/ButtonAsLink/index.js +1 -1
- package/dist/components/ButtonGroup/index.js +1 -1
- package/dist/components/Carousel/index.js +1 -1
- package/dist/components/ConsentMessage/index.js +1 -1
- package/dist/components/DateInput/index.js +26 -1
- package/dist/components/DemoBox/index.js +1 -1
- package/dist/components/EnergySnippet/props.d.ts +1 -1
- package/dist/components/EnergySnippet/styled.d.ts +1 -1
- package/dist/components/FilterGroup/props.d.ts +2 -2
- package/dist/components/GridItem/index.js +1 -1
- package/dist/components/TimeInput/index.js +1 -1
- package/dist/components/ToggleButton/index.d.ts +5 -0
- package/dist/components/ToggleButton/index.js +48 -0
- package/dist/components/ToggleButton/props.d.ts +20 -0
- package/dist/components/ToggleButtonProvider/components/ToggleButtonContext.d.ts +18 -0
- package/dist/components/ToggleButtonProvider/index.d.ts +5 -0
- package/dist/components/ToggleButtonProvider/index.js +93 -0
- package/dist/components/ToggleButtonProvider/props.d.ts +51 -0
- package/dist/contentful/live-preview-inspector/index.js +1 -1
- package/dist/contentful/live-preview-renderer/index.js +1 -1
- package/dist/contentful/renderer/index.js +1 -1
- package/dist/index.d.ts +4 -0
- package/dist/index.js +154 -150
- package/dist/{mapContentToComponents-B5jXlSge.js → mapContentToComponents-CUCG09B3.js} +2 -2
- package/dist/{styled-L1Dt_uzc.js → styled-0KSRG-Fv.js} +1 -1
- package/dist/{styled-DTTTzJXP.js → styled-Dw5c-xwf.js} +1 -1
- package/dist/{validate-DpS8-lSn.js → validate-Dlzxlfzp.js} +5 -5
- package/package.json +1 -1
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { createContext, useContext } from "react";
|
|
2
|
+
const ToggleButtonContext = createContext(null);
|
|
3
|
+
const useToggleButtonContext = () => {
|
|
4
|
+
const context = useContext(ToggleButtonContext);
|
|
5
|
+
if (!context) {
|
|
6
|
+
throw new Error("useToggleButtonContext must be used within <ToggleButtonProvider>");
|
|
7
|
+
}
|
|
8
|
+
return context;
|
|
9
|
+
};
|
|
10
|
+
export {
|
|
11
|
+
ToggleButtonContext as T,
|
|
12
|
+
useToggleButtonContext as u
|
|
13
|
+
};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export declare const getButtonIcon: (icon:
|
|
1
|
+
import { ButtonSharedProps } from './props';
|
|
2
|
+
export declare const getButtonIcon: (icon: ButtonSharedProps["icon"], iconPosition?: ButtonSharedProps["iconPosition"]) => import("react/jsx-runtime").JSX.Element | null;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { FC } from 'react';
|
|
2
|
-
import { ButtonProps } from './props';
|
|
3
2
|
import { ButtonAsLinkProps } from '../ButtonAsLink/props';
|
|
3
|
+
import { ButtonProps } from './props';
|
|
4
4
|
declare const Button: FC<ButtonProps | ButtonAsLinkProps>;
|
|
5
5
|
export default Button;
|
|
6
6
|
export * from './props';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
|
-
import { B as ButtonAsLink, g as getButtonIcon } from "../../validate-
|
|
4
|
-
import { c, a, b, d, f, e } from "../../validate-
|
|
3
|
+
import { B as ButtonAsLink, g as getButtonIcon } from "../../validate-Dlzxlfzp.js";
|
|
4
|
+
import { c, a, b, d, f, e } from "../../validate-Dlzxlfzp.js";
|
|
5
5
|
import { r as renderInlineRichTextFromOpenText } from "../../renderInlineRichTextFromOpenText-RvOG3QbI.js";
|
|
6
6
|
import { B as ButtonStyled } from "../../styled-7vJ7mrAA.js";
|
|
7
7
|
const isButtonAsLinkProp = (props) => {
|
|
@@ -13,7 +13,7 @@ const Button = (props) => {
|
|
|
13
13
|
}
|
|
14
14
|
return /* @__PURE__ */ jsxs(ButtonStyled, { ...props, children: [
|
|
15
15
|
renderInlineRichTextFromOpenText(props.children),
|
|
16
|
-
getButtonIcon(props
|
|
16
|
+
getButtonIcon(props.icon, props.iconPosition)
|
|
17
17
|
] });
|
|
18
18
|
};
|
|
19
19
|
export {
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
+
import { IconName } from '@vfde-react/inline-icon-library/IconName';
|
|
1
2
|
import { ButtonHTMLAttributes } from 'react';
|
|
2
3
|
import { PatternProps } from '../../foundations/PatternProps';
|
|
3
4
|
import { ButtonAppearances } from '../../foundations/types/ButtonAppearances';
|
|
4
|
-
import {
|
|
5
|
+
import { leftPosition, rightPosition } from '../../foundations/types/PositionType';
|
|
5
6
|
export declare const buttonFullWidth = "full";
|
|
6
7
|
export declare const buttonAutoWidth = "auto";
|
|
7
8
|
export type ButtonWidthBehavior = typeof buttonFullWidth | typeof buttonAutoWidth;
|
|
@@ -15,9 +16,13 @@ export interface ButtonSharedProps {
|
|
|
15
16
|
*/
|
|
16
17
|
width?: ButtonWidthBehavior;
|
|
17
18
|
/**
|
|
18
|
-
*
|
|
19
|
+
* Icon to indicate purpose of the action
|
|
19
20
|
*/
|
|
20
|
-
icon?:
|
|
21
|
+
icon?: IconName;
|
|
22
|
+
/**
|
|
23
|
+
* Positioning of the icon relative to the label
|
|
24
|
+
*/
|
|
25
|
+
iconPosition?: typeof leftPosition | typeof rightPosition;
|
|
21
26
|
/**
|
|
22
27
|
* Pin component's name from string to the concrete name
|
|
23
28
|
*/
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import "react/jsx-runtime";
|
|
3
|
-
import { B, i, v } from "../../validate-
|
|
3
|
+
import { B, i, v } from "../../validate-Dlzxlfzp.js";
|
|
4
4
|
import "../../hooks/useLinkComponent/index.js";
|
|
5
5
|
import "../../filterProps-BJ5SpbnA.js";
|
|
6
6
|
import "../../renderInlineRichTextFromOpenText-RvOG3QbI.js";
|
|
@@ -6,7 +6,7 @@ import { b as flexJustifyStart, c as flexJustifyEnd, d as flexJustifyCenter, e a
|
|
|
6
6
|
import FlexItem from "../FlexItem/index.js";
|
|
7
7
|
import { b as spacingSm, s as spacingMd } from "../../Spacing-8v6hcO2x.js";
|
|
8
8
|
import { useViewport } from "../../hooks/useViewport/index.js";
|
|
9
|
-
import { e as validateButtonProps, v as validateButtonAsLinkProps } from "../../validate-
|
|
9
|
+
import { e as validateButtonProps, v as validateButtonAsLinkProps } from "../../validate-Dlzxlfzp.js";
|
|
10
10
|
import { i as isObject, h as hasMatchingComponentName } from "../../isObject-BYBrvoVW.js";
|
|
11
11
|
import { i as isBottomSpacing } from "../../isBottomSpacing-BxfreCZU.js";
|
|
12
12
|
const flexJustifyBehaviors = [flexJustifyStart, flexJustifyEnd, flexJustifyCenter, flexJustifyBetween];
|
|
@@ -8,7 +8,7 @@ import { s as spacingMd } from "../../Spacing-8v6hcO2x.js";
|
|
|
8
8
|
import styled from "styled-components";
|
|
9
9
|
import { a as CardStyled } from "../../styled-Dq0NuP5r.js";
|
|
10
10
|
import { G as GridStyled } from "../../styled-BiCOjvNq.js";
|
|
11
|
-
import { G as GridItemStyled } from "../../styled-
|
|
11
|
+
import { G as GridItemStyled } from "../../styled-0KSRG-Fv.js";
|
|
12
12
|
import viewport from "../../foundations/media-query/viewport/index.js";
|
|
13
13
|
import { getBorderRadius } from "../../foundations/token/getBorderRadius/index.js";
|
|
14
14
|
import { getBottomSpacing } from "../../foundations/token/getBottomSpacing/index.js";
|
|
@@ -3,7 +3,7 @@ import { jsxs, Fragment, jsx } from "react/jsx-runtime";
|
|
|
3
3
|
import { useState, useEffect } from "react";
|
|
4
4
|
import Body, { bodyAlignCenter } from "../Body/index.js";
|
|
5
5
|
import Button from "../Button/index.js";
|
|
6
|
-
import { a as buttonAutoWidth } from "../../validate-
|
|
6
|
+
import { a as buttonAutoWidth } from "../../validate-Dlzxlfzp.js";
|
|
7
7
|
import styled from "styled-components";
|
|
8
8
|
import { B as ButtonStyled, t as tertiaryAppearance } from "../../styled-7vJ7mrAA.js";
|
|
9
9
|
import viewport from "../../foundations/media-query/viewport/index.js";
|
|
@@ -11,11 +11,28 @@ import { i as iconSizeSm } from "../../IconSize-AJp7xdJi.js";
|
|
|
11
11
|
import { s as spacingMd, a as spacingXs } from "../../Spacing-8v6hcO2x.js";
|
|
12
12
|
import { aW as CalendarMonthIcon } from "../../_5gPlusIcon-CnxmOo1u.js";
|
|
13
13
|
import styled from "styled-components";
|
|
14
|
+
import forcedColors from "../../foundations/media-query/forcedColors/index.js";
|
|
15
|
+
import { getBorderColor } from "../../foundations/token/getBorderColor/index.js";
|
|
16
|
+
import { getBorderWidth } from "../../foundations/token/getBorderWidth/index.js";
|
|
17
|
+
import { c as colorBorderFocus } from "../../BorderColor-BummoQ1-.js";
|
|
18
|
+
import { a as borderWidthFocus } from "../../BorderWidth-BjXpOdM5.js";
|
|
14
19
|
const CalendarMonthIconStyled = styled(CalendarMonthIcon).withConfig({
|
|
15
20
|
displayName: "CalendarMonthIconStyled",
|
|
16
21
|
componentId: "sc-12ai2q6-0"
|
|
17
22
|
})(() => {
|
|
18
23
|
return {
|
|
24
|
+
"&:focus": {
|
|
25
|
+
...forcedColors({
|
|
26
|
+
border: "none"
|
|
27
|
+
}),
|
|
28
|
+
outline: "none"
|
|
29
|
+
},
|
|
30
|
+
"&:focus-visible": {
|
|
31
|
+
...forcedColors({
|
|
32
|
+
border: "none"
|
|
33
|
+
}),
|
|
34
|
+
outline: `${getBorderWidth(borderWidthFocus)} solid ${getBorderColor(colorBorderFocus)}`
|
|
35
|
+
},
|
|
19
36
|
"@-moz-document url-prefix()": {
|
|
20
37
|
"&": {
|
|
21
38
|
display: "none",
|
|
@@ -64,6 +81,14 @@ const DateInput = forwardRef(({
|
|
|
64
81
|
innerRef.current.focus();
|
|
65
82
|
}, 1);
|
|
66
83
|
};
|
|
84
|
+
const handleCalendarSpaceKey = (event) => {
|
|
85
|
+
if (null === innerRef || null === innerRef.current) {
|
|
86
|
+
return;
|
|
87
|
+
}
|
|
88
|
+
if (event.code === "Space") {
|
|
89
|
+
innerRef.current.showPicker();
|
|
90
|
+
}
|
|
91
|
+
};
|
|
67
92
|
return /* @__PURE__ */ jsxs(FormElement, { className: props.className, bottomSpacing, disabled: props.disabled, children: [
|
|
68
93
|
/* @__PURE__ */ jsx(FormHelperLabel, { label, uid }),
|
|
69
94
|
/* @__PURE__ */ jsxs(InputWrapperStyled, { status, readOnly: props.readOnly, bottomSpacing: inputStateError !== status && helperText || inputStateError === status && errorMessage ? spacingXs : void 0, children: [
|
|
@@ -77,7 +102,7 @@ const DateInput = forwardRef(({
|
|
|
77
102
|
onUpdate(event.target.value);
|
|
78
103
|
} }),
|
|
79
104
|
/* @__PURE__ */ jsx(FormHelperStatusIcon, { status }),
|
|
80
|
-
/* @__PURE__ */ jsx(CalendarMonthIconStyled, { size: iconSizeSm, onClick: handleCalendarClick })
|
|
105
|
+
/* @__PURE__ */ jsx(CalendarMonthIconStyled, { size: iconSizeSm, onClick: handleCalendarClick, onKeyDown: handleCalendarSpaceKey, tabIndex: 0, role: "button", title: "Datumsauswahl anzeigen" })
|
|
81
106
|
] }),
|
|
82
107
|
/* @__PURE__ */ jsx(FormHelperMessage, { id: messageId, status, message: inputStateError === status ? errorMessage : helperText })
|
|
83
108
|
] });
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import { jsxs, jsx } from "react/jsx-runtime";
|
|
3
3
|
import IconSnippet from "../IconSnippet/index.js";
|
|
4
4
|
import { t as textHeadingXs } from "../../HeadingSize-CfCRn3Lh.js";
|
|
5
|
-
import { D as DemoBoxStyled } from "../../styled-
|
|
5
|
+
import { D as DemoBoxStyled } from "../../styled-Dw5c-xwf.js";
|
|
6
6
|
const DemoBox = ({
|
|
7
7
|
children,
|
|
8
8
|
...props
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
+
import { HTMLAttributes } from 'react';
|
|
1
2
|
import { LinkProps } from '../Link';
|
|
2
3
|
import { PatternProps } from '../../foundations/PatternProps';
|
|
3
|
-
import { HTMLAttributes } from 'react';
|
|
4
4
|
import { UtilityLinkProps } from '../UtilityLink/props';
|
|
5
5
|
export type EnergySnippetSize = 'sm' | 'md' | 'lg';
|
|
6
6
|
export type EnergyClass = 'A' | 'B' | 'C' | 'D' | 'E' | 'F' | 'G';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { UtilityLinkProps } from '../UtilityLink/props';
|
|
2
1
|
import { EnergySnippetProps } from './props';
|
|
2
|
+
import { UtilityLinkProps } from '../UtilityLink/props';
|
|
3
3
|
export declare const EnergySnippetFlexStyled: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components').FastOmit<import('styled-components').FastOmit<import('react').DetailedHTMLProps<import('react').HTMLAttributes<HTMLDivElement>, HTMLDivElement>, keyof import('../Flex').FlexProps> & import('../Flex').FlexProps, never>> & string;
|
|
4
4
|
export declare const EnergySnippetImageLink: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components/dist/types').Substitute<UtilityLinkProps, UtilityLinkProps & Pick<EnergySnippetProps, "orientation">>> & string & Omit<import('react').FC<UtilityLinkProps>, keyof import('react').Component<any, {}, any>>;
|
|
@@ -20,13 +20,13 @@ export interface FilterProps extends InputHTMLAttributes<HTMLInputElement> {
|
|
|
20
20
|
*/
|
|
21
21
|
checked?: boolean;
|
|
22
22
|
}
|
|
23
|
-
export interface FilterGroupProps extends FieldsetSharedProps {
|
|
23
|
+
export interface FilterGroupProps extends Omit<FieldsetSharedProps, 'status' | 'errorMessage' | 'disabled' | 'helperText' | 'disabled'> {
|
|
24
24
|
/**
|
|
25
25
|
* Pin component's name from string to the concrete name
|
|
26
26
|
*/
|
|
27
27
|
component?: 'FilterGroup';
|
|
28
28
|
/**
|
|
29
|
-
* Array of
|
|
29
|
+
* Array of FilterProps
|
|
30
30
|
*/
|
|
31
31
|
filters: FilterProps[];
|
|
32
32
|
/**
|
|
@@ -3,7 +3,7 @@ import { jsx } from "react/jsx-runtime";
|
|
|
3
3
|
import { useContext } from "react";
|
|
4
4
|
import { d as divTagName, l as liTagName, n as navTagName, m as mainTagName, s as sectionTagName, a as asideTagName, b as articleTagName, u as ulTagName, o as olTagName } from "../../tags-D7CRQqc1.js";
|
|
5
5
|
import { validateGridColSpan, GridContext } from "../Grid/index.js";
|
|
6
|
-
import { G as GridItemStyled } from "../../styled-
|
|
6
|
+
import { G as GridItemStyled } from "../../styled-0KSRG-Fv.js";
|
|
7
7
|
import { i as isObject, h as hasMatchingComponentName } from "../../isObject-BYBrvoVW.js";
|
|
8
8
|
const gridItemTags = [divTagName, liTagName, navTagName, mainTagName, sectionTagName, asideTagName, articleTagName];
|
|
9
9
|
const gridItemAligns = ["left", "center", "right"];
|
|
@@ -95,7 +95,7 @@ const TimeInput = forwardRef(({
|
|
|
95
95
|
if (e.key === "Enter" || e.key === " ") {
|
|
96
96
|
handlePickerInteraction();
|
|
97
97
|
}
|
|
98
|
-
}, browserSupportsPicker, role: browserSupportsPicker ? "button" : void 0, tabIndex: browserSupportsPicker ? 0 : void 0 })
|
|
98
|
+
}, browserSupportsPicker, role: browserSupportsPicker ? "button" : void 0, tabIndex: browserSupportsPicker ? 0 : void 0, title: "Zeitauswahl anzeigen" })
|
|
99
99
|
] }),
|
|
100
100
|
/* @__PURE__ */ jsx(FormHelperMessage, { id: messageId, status: internalStatus, message: inputStateError === internalStatus ? errorMessage : helperText })
|
|
101
101
|
] });
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsxs, Fragment, jsx } from "react/jsx-runtime";
|
|
3
|
+
import { useEffect } from "react";
|
|
4
|
+
import Button from "../Button/index.js";
|
|
5
|
+
import { u as useToggleButtonContext } from "../../ToggleButtonContext-TOVux5cw.js";
|
|
6
|
+
const ToggleButton = ({
|
|
7
|
+
value,
|
|
8
|
+
initialChecked = false,
|
|
9
|
+
component: _component,
|
|
10
|
+
...props
|
|
11
|
+
}) => {
|
|
12
|
+
const {
|
|
13
|
+
labelChecked,
|
|
14
|
+
labelUnchecked,
|
|
15
|
+
iconChecked,
|
|
16
|
+
iconUnchecked,
|
|
17
|
+
width,
|
|
18
|
+
name,
|
|
19
|
+
isChecked,
|
|
20
|
+
onChange,
|
|
21
|
+
register,
|
|
22
|
+
unregister
|
|
23
|
+
} = useToggleButtonContext();
|
|
24
|
+
const checked = isChecked(value, initialChecked);
|
|
25
|
+
useEffect(() => {
|
|
26
|
+
const minimalProps = {
|
|
27
|
+
value,
|
|
28
|
+
checked
|
|
29
|
+
};
|
|
30
|
+
register(minimalProps);
|
|
31
|
+
return () => {
|
|
32
|
+
unregister(value);
|
|
33
|
+
};
|
|
34
|
+
}, [value, checked, register, unregister]);
|
|
35
|
+
const onClick = (event) => {
|
|
36
|
+
onChange(value, !checked);
|
|
37
|
+
if (props.onClick) {
|
|
38
|
+
props.onClick(event);
|
|
39
|
+
}
|
|
40
|
+
};
|
|
41
|
+
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
42
|
+
checked && /* @__PURE__ */ jsx("input", { type: "hidden", name: `${name}[]`, value: `${value}` }),
|
|
43
|
+
/* @__PURE__ */ jsx(Button, { ...props, type: "button", width, appearance: checked ? "secondary" : "tertiary", "aria-pressed": checked, icon: checked ? iconChecked : iconUnchecked, iconPosition: "left", onClick, children: checked ? labelChecked : labelUnchecked })
|
|
44
|
+
] });
|
|
45
|
+
};
|
|
46
|
+
export {
|
|
47
|
+
ToggleButton as default
|
|
48
|
+
};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { ButtonProps } from '../Button/props';
|
|
2
|
+
export interface ToggleButtonProps extends Omit<ButtonProps, 'children' | 'icon' | 'appearance' | 'width' | 'aria-pressed' | 'name' | 'component'> {
|
|
3
|
+
/**
|
|
4
|
+
* Pin component's name from string to the concrete name
|
|
5
|
+
*/
|
|
6
|
+
component?: 'ToggleButton';
|
|
7
|
+
/**
|
|
8
|
+
* indicate if the button should be initial checked.
|
|
9
|
+
* After it is registered only Provider's state is controlling checked
|
|
10
|
+
*/
|
|
11
|
+
initialChecked?: boolean;
|
|
12
|
+
/**
|
|
13
|
+
* value is mandatory
|
|
14
|
+
*/
|
|
15
|
+
value: string;
|
|
16
|
+
}
|
|
17
|
+
export type ToggleButtonState = {
|
|
18
|
+
value: string;
|
|
19
|
+
checked: boolean;
|
|
20
|
+
};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { IconName } from '@vfde-react/inline-icon-library/IconName';
|
|
2
|
+
import { ButtonWidthBehavior } from '../../Button';
|
|
3
|
+
import { ToggleButtonState } from '../../ToggleButton';
|
|
4
|
+
export interface ToggleButtonContextValue {
|
|
5
|
+
buttons: ToggleButtonState[];
|
|
6
|
+
labelChecked: string;
|
|
7
|
+
labelUnchecked: string;
|
|
8
|
+
iconChecked?: IconName;
|
|
9
|
+
iconUnchecked?: IconName;
|
|
10
|
+
width?: ButtonWidthBehavior;
|
|
11
|
+
name: string;
|
|
12
|
+
register: (button: ToggleButtonState) => void;
|
|
13
|
+
unregister: (value: string) => void;
|
|
14
|
+
onChange: (value: string, checked: boolean) => void;
|
|
15
|
+
isChecked: (buttonUid: string, initialChecked: boolean) => boolean;
|
|
16
|
+
}
|
|
17
|
+
export declare const ToggleButtonContext: import('react').Context<ToggleButtonContextValue | null>;
|
|
18
|
+
export declare const useToggleButtonContext: () => ToggleButtonContextValue;
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx } from "react/jsx-runtime";
|
|
3
|
+
import { useRef, useState, useLayoutEffect, useCallback, useEffect } from "react";
|
|
4
|
+
import { T as ToggleButtonContext } from "../../ToggleButtonContext-TOVux5cw.js";
|
|
5
|
+
const ToggleButtonProvider = ({
|
|
6
|
+
exclusive,
|
|
7
|
+
labelChecked,
|
|
8
|
+
labelUnchecked,
|
|
9
|
+
iconChecked,
|
|
10
|
+
iconUnchecked,
|
|
11
|
+
name,
|
|
12
|
+
width,
|
|
13
|
+
onUpdate,
|
|
14
|
+
children,
|
|
15
|
+
...props
|
|
16
|
+
}) => {
|
|
17
|
+
const setupComplete = useRef(false);
|
|
18
|
+
const [buttons, setButtons] = useState([]);
|
|
19
|
+
useLayoutEffect(() => {
|
|
20
|
+
setupComplete.current = true;
|
|
21
|
+
}, []);
|
|
22
|
+
const register = useCallback((button) => {
|
|
23
|
+
setButtons((prev) => {
|
|
24
|
+
const existing = prev.find((b) => b.value === button.value);
|
|
25
|
+
if (existing) {
|
|
26
|
+
return prev.map((b) => b.value === button.value ? {
|
|
27
|
+
...b,
|
|
28
|
+
...button
|
|
29
|
+
} : b);
|
|
30
|
+
}
|
|
31
|
+
return [...prev, button];
|
|
32
|
+
});
|
|
33
|
+
}, []);
|
|
34
|
+
const unregister = useCallback((value) => {
|
|
35
|
+
setButtons((prev) => prev.filter((b) => b.value !== value));
|
|
36
|
+
}, []);
|
|
37
|
+
const onChange = useCallback((value, checked) => {
|
|
38
|
+
setButtons((prev) => {
|
|
39
|
+
if (exclusive && checked) {
|
|
40
|
+
return prev.map((b) => {
|
|
41
|
+
return {
|
|
42
|
+
...b,
|
|
43
|
+
checked: b.value === value
|
|
44
|
+
};
|
|
45
|
+
});
|
|
46
|
+
}
|
|
47
|
+
return prev.map((b) => b.value === value ? {
|
|
48
|
+
...b,
|
|
49
|
+
checked
|
|
50
|
+
} : b);
|
|
51
|
+
});
|
|
52
|
+
}, [exclusive]);
|
|
53
|
+
const isChecked = useCallback((value, initialChecked) => {
|
|
54
|
+
const findButton = buttons.find((button) => value === button.value);
|
|
55
|
+
if (!findButton) {
|
|
56
|
+
return initialChecked;
|
|
57
|
+
}
|
|
58
|
+
return findButton.checked;
|
|
59
|
+
}, [buttons]);
|
|
60
|
+
useEffect(() => {
|
|
61
|
+
var _a;
|
|
62
|
+
if (!setupComplete.current) {
|
|
63
|
+
return;
|
|
64
|
+
}
|
|
65
|
+
if (!onUpdate) {
|
|
66
|
+
return;
|
|
67
|
+
}
|
|
68
|
+
if (exclusive) {
|
|
69
|
+
const value = ((_a = buttons.find((button) => button.checked)) == null ? void 0 : _a.value) || null;
|
|
70
|
+
onUpdate(value);
|
|
71
|
+
} else {
|
|
72
|
+
const values = buttons.filter((button) => button.checked).map((button) => button.value);
|
|
73
|
+
onUpdate(values);
|
|
74
|
+
}
|
|
75
|
+
}, [buttons, exclusive, onUpdate]);
|
|
76
|
+
const contextValue = {
|
|
77
|
+
buttons,
|
|
78
|
+
labelChecked,
|
|
79
|
+
labelUnchecked,
|
|
80
|
+
iconChecked,
|
|
81
|
+
iconUnchecked,
|
|
82
|
+
width,
|
|
83
|
+
name,
|
|
84
|
+
register,
|
|
85
|
+
unregister,
|
|
86
|
+
onChange,
|
|
87
|
+
isChecked
|
|
88
|
+
};
|
|
89
|
+
return /* @__PURE__ */ jsx(ToggleButtonContext.Provider, { value: contextValue, children: /* @__PURE__ */ jsx("div", { ...props, children }) });
|
|
90
|
+
};
|
|
91
|
+
export {
|
|
92
|
+
ToggleButtonProvider as default
|
|
93
|
+
};
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { IconName } from '@vfde-react/inline-icon-library/IconName';
|
|
2
|
+
import { HTMLAttributes } from 'react';
|
|
3
|
+
import { ButtonWidthBehavior } from '../Button';
|
|
4
|
+
interface ToggleButtonProviderBaseProps extends HTMLAttributes<HTMLDivElement> {
|
|
5
|
+
/**
|
|
6
|
+
* All toggle buttons within a provider are given the same label when checked.
|
|
7
|
+
*/
|
|
8
|
+
labelChecked: string;
|
|
9
|
+
/**
|
|
10
|
+
* All toggle buttons within a provider are given the same label when unchecked.
|
|
11
|
+
*/
|
|
12
|
+
labelUnchecked: string;
|
|
13
|
+
/**
|
|
14
|
+
* All toggle buttons within a provider display the same icon when checked.
|
|
15
|
+
*/
|
|
16
|
+
iconChecked?: IconName;
|
|
17
|
+
/**
|
|
18
|
+
* All toggle buttons within a provider display the same icon when unchecked.
|
|
19
|
+
*/
|
|
20
|
+
iconUnchecked?: IconName;
|
|
21
|
+
/**
|
|
22
|
+
* Supports different width behaviors
|
|
23
|
+
*/
|
|
24
|
+
width?: ButtonWidthBehavior;
|
|
25
|
+
/**
|
|
26
|
+
* Name of all ToggleButtons' form control within a provider. Submitted with the form as part of a name/value pair
|
|
27
|
+
*/
|
|
28
|
+
name: string;
|
|
29
|
+
}
|
|
30
|
+
interface ToggleButtonProviderExclusiveProps extends ToggleButtonProviderBaseProps {
|
|
31
|
+
/**
|
|
32
|
+
* If this is true, then only one ToggleButton within the Provider can be selected. When a button is selected, all others are deselected.
|
|
33
|
+
*/
|
|
34
|
+
exclusive: true;
|
|
35
|
+
/**
|
|
36
|
+
* Callback fired when the value changes and one time ofter after useLayout
|
|
37
|
+
*/
|
|
38
|
+
onUpdate?: (value: string | null) => void;
|
|
39
|
+
}
|
|
40
|
+
interface ToggleButtonProviderMultiProps extends ToggleButtonProviderBaseProps {
|
|
41
|
+
/**
|
|
42
|
+
* If this is true, then only one ToggleButton within the Provider can be selected. When a button is selected, all others are deselected.
|
|
43
|
+
*/
|
|
44
|
+
exclusive: false;
|
|
45
|
+
/**
|
|
46
|
+
* Callback fired when the value changes and one time ofter after useLayout
|
|
47
|
+
*/
|
|
48
|
+
onUpdate?: (value: string[]) => void;
|
|
49
|
+
}
|
|
50
|
+
export type ToggleButtonProviderProps = ToggleButtonProviderExclusiveProps | ToggleButtonProviderMultiProps;
|
|
51
|
+
export {};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { jsx, Fragment } from "react/jsx-runtime";
|
|
3
3
|
import { useContentfulLiveUpdates, ContentfulLivePreviewProvider } from "@contentful/live-preview/react";
|
|
4
|
-
import { m as mapContentToComponents } from "../../mapContentToComponents-
|
|
4
|
+
import { m as mapContentToComponents } from "../../mapContentToComponents-CUCG09B3.js";
|
|
5
5
|
const BrixLiveRendererComponents = ({
|
|
6
6
|
data
|
|
7
7
|
}) => {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { jsx, Fragment } from "react/jsx-runtime";
|
|
3
3
|
import LivePreviewRenderer from "../live-preview-renderer/index.js";
|
|
4
|
-
import { m as mapContentToComponents } from "../../mapContentToComponents-
|
|
4
|
+
import { m as mapContentToComponents } from "../../mapContentToComponents-CUCG09B3.js";
|
|
5
5
|
const Renderer = ({
|
|
6
6
|
content,
|
|
7
7
|
isDraftMode
|
package/dist/index.d.ts
CHANGED
|
@@ -4,6 +4,10 @@ export * from './components/UtilityLink';
|
|
|
4
4
|
export { default as UtilityLink } from './components/UtilityLink';
|
|
5
5
|
export * from './components/Tray';
|
|
6
6
|
export { default as Tray } from './components/Tray';
|
|
7
|
+
export * from './components/ToggleButtonProvider';
|
|
8
|
+
export { default as ToggleButtonProvider } from './components/ToggleButtonProvider';
|
|
9
|
+
export * from './components/ToggleButton';
|
|
10
|
+
export { default as ToggleButton } from './components/ToggleButton';
|
|
7
11
|
export * from './components/TimeInput';
|
|
8
12
|
export { default as TimeInput } from './components/TimeInput';
|
|
9
13
|
export * from './components/Textarea';
|
package/dist/index.js
CHANGED
|
@@ -1,90 +1,92 @@
|
|
|
1
1
|
import { default as default2, YoutubeVideoIframeStyled, YoutubeVideoStyled } from "./components/YoutubeVideo/index.js";
|
|
2
2
|
import { default as default3 } from "./components/UtilityLink/index.js";
|
|
3
3
|
import { default as default4 } from "./components/Tray/index.js";
|
|
4
|
-
import { default as default5 } from "./components/
|
|
5
|
-
import { default as default6 } from "./components/
|
|
4
|
+
import { default as default5 } from "./components/ToggleButtonProvider/index.js";
|
|
5
|
+
import { default as default6 } from "./components/ToggleButton/index.js";
|
|
6
|
+
import { default as default7 } from "./components/TimeInput/index.js";
|
|
7
|
+
import { default as default8 } from "./components/Textarea/index.js";
|
|
6
8
|
import { R, T, a } from "./index-CLHcudLb.js";
|
|
7
9
|
import { P, T as T2, c, k, g, f, j, p, a as a2, i, e, d, b, h, v } from "./index-GkBE6ANF.js";
|
|
8
10
|
import { T as T3, a as a3, b as b2, c as c2, d as d2, e as e2, f as f2, T as T4 } from "./TableWrapper-Do9KCTGV.js";
|
|
9
|
-
import { PanelStyled, default as
|
|
10
|
-
import { default as
|
|
11
|
-
import { default as
|
|
12
|
-
import { default as
|
|
13
|
-
import { default as
|
|
14
|
-
import { default as
|
|
15
|
-
import { default as
|
|
11
|
+
import { PanelStyled, default as default9, TabGroupContainerStyled, TabGroupIndicatorStyled, TabGroupTabsScrollableContainerStyled, TabGroupTabsStyled, TabLabelStyled, TabStyled, iconPositionLeft, iconPositionTop, tabGroupWidthAuto, tabGroupWidthFull } from "./components/TabGroup/index.js";
|
|
12
|
+
import { default as default10 } from "./components/Switch/index.js";
|
|
13
|
+
import { default as default11 } from "./components/SuggestInput/index.js";
|
|
14
|
+
import { default as default12 } from "./components/Stepper/index.js";
|
|
15
|
+
import { default as default13 } from "./components/SmoothScrollArea/index.js";
|
|
16
|
+
import { default as default14 } from "./components/SelectInput/index.js";
|
|
17
|
+
import { default as default15 } from "./components/SearchInput/index.js";
|
|
16
18
|
import { S } from "./index-CfIoFAvq.js";
|
|
17
|
-
import { default as
|
|
18
|
-
import { default as
|
|
19
|
-
import { HiddenRadioStyled, default as
|
|
20
|
-
import { default as
|
|
21
|
-
import { default as
|
|
22
|
-
import { default as
|
|
23
|
-
import { default as
|
|
24
|
-
import { default as
|
|
25
|
-
import { default as
|
|
26
|
-
import { default as
|
|
19
|
+
import { default as default16 } from "./components/RichtTextContentful/index.js";
|
|
20
|
+
import { default as default17, isResponsiveImageProps, validateResponsiveImageProps } from "./components/ResponsiveImage/index.js";
|
|
21
|
+
import { HiddenRadioStyled, default as default18, RatingFieldsetStyled, StarLabelStyled, StarsWrapperStyled } from "./components/Rating/index.js";
|
|
22
|
+
import { default as default19 } from "./components/RadioGroup/index.js";
|
|
23
|
+
import { default as default20 } from "./components/QuickLinkList/index.js";
|
|
24
|
+
import { default as default21 } from "./components/ProductCard/index.js";
|
|
25
|
+
import { default as default22 } from "./components/PickerGroup/index.js";
|
|
26
|
+
import { default as default23, overlayAppearancePrimary, overlayAppearanceSecondary } from "./components/Overlay/index.js";
|
|
27
|
+
import { default as default24 } from "./components/OpenTextFootnoteAdapter/index.js";
|
|
28
|
+
import { default as default25, notificationStatusError, notificationStatusInfo, notificationStatusSuccess, notificationStatusWarning } from "./components/Notification/index.js";
|
|
27
29
|
import { M, i as i2, a as a4, b as b3, m, c as c3, v as v2 } from "./index-DubgGwxc.js";
|
|
28
|
-
import { default as
|
|
29
|
-
import { default as
|
|
30
|
-
import { default as
|
|
31
|
-
import { default as
|
|
30
|
+
import { default as default26 } from "./components/LocalStyle/index.js";
|
|
31
|
+
import { default as default27 } from "./components/LoadingSpinner/index.js";
|
|
32
|
+
import { default as default28, linkListItemVariantHorizontal, linkListItemVariantVertical } from "./components/LinkListItem/index.js";
|
|
33
|
+
import { default as default29, linkListVariantColumn, linkListVariantRow } from "./components/LinkList/index.js";
|
|
32
34
|
import { L, i as i3, v as v3 } from "./index-CEotMXpL.js";
|
|
33
|
-
import { default as
|
|
34
|
-
import { default as
|
|
35
|
-
import { default as
|
|
36
|
-
import { default as
|
|
37
|
-
import { default as
|
|
38
|
-
import { IconWithAccent, default as
|
|
39
|
-
import { default as
|
|
40
|
-
import { default as
|
|
41
|
-
import { default as
|
|
42
|
-
import { default as
|
|
43
|
-
import { default as
|
|
35
|
+
import { default as default30, isLinkProps, validateLinkProps } from "./components/Link/index.js";
|
|
36
|
+
import { default as default31 } from "./components/Legend/index.js";
|
|
37
|
+
import { default as default32 } from "./components/Label/index.js";
|
|
38
|
+
import { default as default33 } from "./components/Input/index.js";
|
|
39
|
+
import { default as default34, isInlineLinkProps, validateInlineLinkProps } from "./components/InlineLink/index.js";
|
|
40
|
+
import { IconWithAccent, default as default35, InlineIconStyled, inlineIconModeFill, inlineIconModeStroke } from "./components/InlineIcon/index.js";
|
|
41
|
+
import { default as default36, infoBannerAppearancePrimary, infoBannerAppearanceSecondary } from "./components/InfoBanner/index.js";
|
|
42
|
+
import { default as default37, imageHeaderPositionLeft, imageHeaderPositionRight, imageHeaderPositions, imageHeaderVariantFull, imageHeaderVariantSplit, imageHeaderVariants, isImageHeaderProps, validateImageHeaderProps } from "./components/ImageHeader/index.js";
|
|
43
|
+
import { default as default38 } from "./components/Image/index.js";
|
|
44
|
+
import { default as default39, isIconSnippetListProps, validateIconSnippetListProps } from "./components/IconSnippetList/index.js";
|
|
45
|
+
import { default as default40, iconSnippetAlignCenter, iconSnippetAlignTop, iconSnippetAligns, iconSnippetPositionCenter, iconSnippetPositionLeft, iconSnippetPositions, iconSnippetSize3Xl, iconSnippetSizeLarge, iconSnippetSizeSmall, iconSnippetSizes, iconSnippetTags, isIconSnippetProps, validateIconSnippetProps } from "./components/IconSnippet/index.js";
|
|
44
46
|
import { I, i as i4, a as a5, v as v4 } from "./index--RjkzZm0.js";
|
|
45
|
-
import { default as
|
|
46
|
-
import { default as
|
|
47
|
-
import { default as
|
|
48
|
-
import { default as
|
|
49
|
-
import { default as
|
|
50
|
-
import { default as
|
|
51
|
-
import { default as
|
|
52
|
-
import { default as
|
|
53
|
-
import { default as
|
|
54
|
-
import { default as
|
|
55
|
-
import { default as
|
|
56
|
-
import { default as
|
|
47
|
+
import { default as default41, iconButtonShapeCircle, iconButtonShapeSquare } from "./components/IconButton/index.js";
|
|
48
|
+
import { default as default42 } from "./components/Icon/index.js";
|
|
49
|
+
import { default as default43, hifiIconSizes, isHifiIconProps, validateHifiIconProps } from "./components/HifiIcon/index.js";
|
|
50
|
+
import { default as default44, headingAlignCenter, headingAlignLeft, headingSizes, headingTags, headingWeights, headlingAligns, isHeadingProps, validateHeadingProps } from "./components/Heading/index.js";
|
|
51
|
+
import { default as default45, gridItemAligns, gridItemTags, isGridItemProps, validateGridItemProps } from "./components/GridItem/index.js";
|
|
52
|
+
import { default as default46, GridContext, gridAligns, gridSpacings, gridTags, isGridConfig, isGridProps, validateGridColSpan, validateGridConfig, validateGridProps } from "./components/Grid/index.js";
|
|
53
|
+
import { default as default47 } from "./components/GoogleMap/index.js";
|
|
54
|
+
import { default as default48, inputStatusIcons } from "./components/FormHelperStatusIcon/index.js";
|
|
55
|
+
import { default as default49 } from "./components/FormHelperMessage/index.js";
|
|
56
|
+
import { default as default50 } from "./components/FormHelperLabel/index.js";
|
|
57
|
+
import { default as default51 } from "./components/FormElement/index.js";
|
|
58
|
+
import { default as default52 } from "./components/Form/index.js";
|
|
57
59
|
import { F } from "./index-DToaoQpl.js";
|
|
58
|
-
import { default as
|
|
59
|
-
import { default as
|
|
60
|
-
import { default as
|
|
61
|
-
import { default as
|
|
62
|
-
import { default as
|
|
63
|
-
import { default as
|
|
64
|
-
import { default as
|
|
65
|
-
import { default as
|
|
66
|
-
import { default as
|
|
67
|
-
import { default as
|
|
68
|
-
import { default as
|
|
69
|
-
import { default as
|
|
70
|
-
import { default as
|
|
71
|
-
import { default as
|
|
72
|
-
import { default as
|
|
73
|
-
import { default as
|
|
74
|
-
import { default as
|
|
75
|
-
import { default as
|
|
76
|
-
import { default as
|
|
77
|
-
import { default as
|
|
78
|
-
import { default as
|
|
79
|
-
import { default as
|
|
80
|
-
import { default as
|
|
81
|
-
import { B, c as c4, a as a6, b as b4, d as d3, i as i5, f as f3, v as v5, e as e3 } from "./validate-
|
|
82
|
-
import { default as
|
|
83
|
-
import { default as
|
|
84
|
-
import { default as
|
|
60
|
+
import { default as default53 } from "./components/FootnoteContent/index.js";
|
|
61
|
+
import { default as default54, flexItemAutoGrow, flexItemFullGrow } from "./components/FlexItem/index.js";
|
|
62
|
+
import { default as default55 } from "./components/Flex/index.js";
|
|
63
|
+
import { default as default56 } from "./components/FilterGroup/index.js";
|
|
64
|
+
import { default as default57 } from "./components/Fieldset/index.js";
|
|
65
|
+
import { default as default58 } from "./components/EnergySnippet/index.js";
|
|
66
|
+
import { default as default59, isDividerProps, validateDividerProps } from "./components/Divider/index.js";
|
|
67
|
+
import { default as default60, isDiscoveryCardGroupProps, validateDiscoveryCardGroupProps } from "./components/DiscoveryCardGroup/index.js";
|
|
68
|
+
import { default as default61, discoveryCardOrientationHorizontal, discoveryCardOrientationVertical, isDiscoveryCardProps, validateDiscoveryCardProps } from "./components/DiscoveryCard/index.js";
|
|
69
|
+
import { default as default62 } from "./components/Dialog/index.js";
|
|
70
|
+
import { default as default63 } from "./components/DemoBox/index.js";
|
|
71
|
+
import { default as default64 } from "./components/DateInput/index.js";
|
|
72
|
+
import { default as default65, ContainerAppearanceColor, containerAppearances, containerPaddings, isContainerProps, validateContainerProps } from "./components/Container/index.js";
|
|
73
|
+
import { default as default66 } from "./components/ConsentMessage/index.js";
|
|
74
|
+
import { default as default67, isColorSwatchGroupProps, validateColorSwatchGroupProps } from "./components/ColorSwatchGroup/index.js";
|
|
75
|
+
import { default as default68, colorSwatchSizeMedium, colorSwatchSizeSmall, colorSwatchSizes, isColorSwatchProps, validateColorSwatchProps } from "./components/ColorSwatch/index.js";
|
|
76
|
+
import { default as default69 } from "./components/Collapsible/index.js";
|
|
77
|
+
import { default as default70 } from "./components/CheckboxGroup/index.js";
|
|
78
|
+
import { default as default71 } from "./components/Checkbox/index.js";
|
|
79
|
+
import { default as default72 } from "./components/Carousel/index.js";
|
|
80
|
+
import { default as default73, cardAppearances, cardTags, isCardProps, validateCardProps } from "./components/Card/index.js";
|
|
81
|
+
import { default as default74 } from "./components/Calendar/index.js";
|
|
82
|
+
import { default as default75, flexJustifyBehaviors, flexOrientations, isButtonGroupProps, validateButtonGroupProps } from "./components/ButtonGroup/index.js";
|
|
83
|
+
import { B, c as c4, a as a6, b as b4, d as d3, i as i5, f as f3, v as v5, e as e3 } from "./validate-Dlzxlfzp.js";
|
|
84
|
+
import { default as default76 } from "./components/Button/index.js";
|
|
85
|
+
import { default as default77 } from "./components/BottomBar/index.js";
|
|
86
|
+
import { default as default78, bodyAlignCenter, bodyAlignLeft, bodyAlignRight, bodyAligns, bodySizes, bodyTags, bodyWeights, isBodyProps, validateBodyProps } from "./components/Body/index.js";
|
|
85
87
|
import { B as B2, b as b5, c as c5, d as d4, i as i6, p as p2, s, a as a7, t, v as v6 } from "./index-DOjE2zK8.js";
|
|
86
|
-
import { default as
|
|
87
|
-
import { default as
|
|
88
|
+
import { default as default79, isAccordionGroupProps, validateAccordionGroupProps } from "./components/AccordionGroup/index.js";
|
|
89
|
+
import { default as default80, accordionToggleCollapsed, accordionToggleCollapsing, accordionToggleExpanded, isAccordionProps, validateAccordionProps } from "./components/Accordion/index.js";
|
|
88
90
|
import { getTextDecoration } from "./foundations/token/getTextDecoration/index.js";
|
|
89
91
|
import { getTextColor } from "./foundations/token/getTextColor/index.js";
|
|
90
92
|
import { getSpacing } from "./foundations/token/getSpacing/index.js";
|
|
@@ -114,109 +116,109 @@ import { useForcedColors } from "./hooks/useForcedColors/index.js";
|
|
|
114
116
|
import { useFocusWithin } from "./hooks/useFocusWithin/index.js";
|
|
115
117
|
import "react/jsx-runtime";
|
|
116
118
|
import "@contentful/live-preview/react";
|
|
117
|
-
import { L as L2 } from "./mapContentToComponents-
|
|
119
|
+
import { L as L2 } from "./mapContentToComponents-CUCG09B3.js";
|
|
118
120
|
import { a as a8, i as i7 } from "./props-DDpgcryb.js";
|
|
119
121
|
import { p as p3, m as m2, q, r, s as s2, n, t as t2, x, d as d5, h as h2, c as c6, w, z, o, a as a9, b as b6, u, e as e4, i as i8, g as g2, f as f4, l, k as k2, j as j2, v as v7, y } from "./validate-DYmFz2FF.js";
|
|
120
122
|
import { e as e5, d as d6, c as c7, b as b7, f as f5, a as a10 } from "./styled-BxkvYuWW.js";
|
|
121
123
|
import { C } from "./styled-Dq0NuP5r.js";
|
|
122
124
|
export {
|
|
123
|
-
|
|
124
|
-
|
|
125
|
+
default80 as Accordion,
|
|
126
|
+
default79 as AccordionGroup,
|
|
125
127
|
B2 as Badge,
|
|
126
128
|
b5 as BadgeAppearanceColor,
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
129
|
+
default78 as Body,
|
|
130
|
+
default77 as BottomBar,
|
|
131
|
+
default76 as Button,
|
|
130
132
|
B as ButtonAsLink,
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
133
|
+
default75 as ButtonGroup,
|
|
134
|
+
default74 as Calendar,
|
|
135
|
+
default73 as Card,
|
|
134
136
|
C as CardAppearanceColor,
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
137
|
+
default72 as Carousel,
|
|
138
|
+
default71 as Checkbox,
|
|
139
|
+
default70 as CheckboxGroup,
|
|
140
|
+
default69 as Collapsible,
|
|
141
|
+
default68 as ColorSwatch,
|
|
142
|
+
default67 as ColorSwatchGroup,
|
|
143
|
+
default66 as ConsentMessage,
|
|
144
|
+
default65 as Container,
|
|
143
145
|
ContainerAppearanceColor,
|
|
144
|
-
|
|
146
|
+
default64 as DateInput,
|
|
145
147
|
DefaultLink,
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
148
|
+
default63 as DemoBox,
|
|
149
|
+
default62 as Dialog,
|
|
150
|
+
default61 as DiscoveryCard,
|
|
151
|
+
default60 as DiscoveryCardGroup,
|
|
152
|
+
default59 as Divider,
|
|
153
|
+
default58 as EnergySnippet,
|
|
154
|
+
default57 as Fieldset,
|
|
155
|
+
default56 as FilterGroup,
|
|
156
|
+
default55 as Flex,
|
|
157
|
+
default54 as FlexItem,
|
|
158
|
+
default53 as FootnoteContent,
|
|
157
159
|
F as FootnoteLink,
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
160
|
+
default52 as Form,
|
|
161
|
+
default51 as FormElement,
|
|
162
|
+
default50 as FormHelperLabel,
|
|
163
|
+
default49 as FormHelperMessage,
|
|
164
|
+
default48 as FormHelperStatusIcon,
|
|
163
165
|
GlobalStyle,
|
|
164
|
-
|
|
165
|
-
|
|
166
|
+
default47 as GoogleMap,
|
|
167
|
+
default46 as Grid,
|
|
166
168
|
GridContext,
|
|
167
|
-
|
|
168
|
-
|
|
169
|
+
default45 as GridItem,
|
|
170
|
+
default44 as Heading,
|
|
169
171
|
HiddenRadioStyled,
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
172
|
+
default43 as HifiIcon,
|
|
173
|
+
default42 as Icon,
|
|
174
|
+
default41 as IconButton,
|
|
173
175
|
I as IconLoader,
|
|
174
|
-
|
|
175
|
-
|
|
176
|
+
default40 as IconSnippet,
|
|
177
|
+
default39 as IconSnippetList,
|
|
176
178
|
IconWithAccent,
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
179
|
+
default38 as Image,
|
|
180
|
+
default37 as ImageHeader,
|
|
181
|
+
default36 as InfoBanner,
|
|
182
|
+
default35 as InlineIcon,
|
|
181
183
|
InlineIconStyled,
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
184
|
+
default34 as InlineLink,
|
|
185
|
+
default33 as Input,
|
|
186
|
+
default32 as Label,
|
|
187
|
+
default31 as Legend,
|
|
188
|
+
default30 as Link,
|
|
187
189
|
L as LinkAsButton,
|
|
188
190
|
LinkContext,
|
|
189
|
-
|
|
190
|
-
|
|
191
|
+
default29 as LinkList,
|
|
192
|
+
default28 as LinkListItem,
|
|
191
193
|
LinkProvider,
|
|
192
194
|
L2 as LivePreviewInspector,
|
|
193
|
-
|
|
194
|
-
|
|
195
|
+
default27 as LoadingSpinner,
|
|
196
|
+
default26 as LocalStyle,
|
|
195
197
|
M as MediaText,
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
198
|
+
default25 as Notification,
|
|
199
|
+
default24 as OpenTextFootnoteAdapter,
|
|
200
|
+
default23 as Overlay,
|
|
199
201
|
PanelStyled,
|
|
200
|
-
|
|
202
|
+
default22 as PickerGroup,
|
|
201
203
|
P as Price,
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
204
|
+
default21 as ProductCard,
|
|
205
|
+
default20 as QuickLinkList,
|
|
206
|
+
default19 as RadioGroup,
|
|
207
|
+
default18 as Rating,
|
|
206
208
|
RatingFieldsetStyled,
|
|
207
|
-
|
|
209
|
+
default17 as ResponsiveImage,
|
|
208
210
|
R as RichText,
|
|
209
|
-
|
|
211
|
+
default16 as RichtTextContentful,
|
|
210
212
|
S as ScreenreaderOnly,
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
213
|
+
default15 as SearchInput,
|
|
214
|
+
default14 as SelectInput,
|
|
215
|
+
default13 as SmoothScrollArea,
|
|
214
216
|
StarLabelStyled,
|
|
215
217
|
StarsWrapperStyled,
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
218
|
+
default12 as Stepper,
|
|
219
|
+
default11 as SuggestInput,
|
|
220
|
+
default10 as Switch,
|
|
221
|
+
default9 as TabGroup,
|
|
220
222
|
TabGroupContainerStyled,
|
|
221
223
|
TabGroupIndicatorStyled,
|
|
222
224
|
TabGroupTabsScrollableContainerStyled,
|
|
@@ -234,8 +236,10 @@ export {
|
|
|
234
236
|
T2 as TabularPrice,
|
|
235
237
|
T as TextList,
|
|
236
238
|
a as TextListItem,
|
|
237
|
-
|
|
238
|
-
|
|
239
|
+
default8 as Textarea,
|
|
240
|
+
default7 as TimeInput,
|
|
241
|
+
default6 as ToggleButton,
|
|
242
|
+
default5 as ToggleButtonProvider,
|
|
239
243
|
default4 as Tray,
|
|
240
244
|
default3 as UtilityLink,
|
|
241
245
|
default2 as YoutubeVideo,
|
|
@@ -3,7 +3,7 @@ import AccordionGroup, { isAccordionGroupProps } from "./components/AccordionGro
|
|
|
3
3
|
import { i as isBadgeProps, B as Badge } from "./index-DOjE2zK8.js";
|
|
4
4
|
import Body, { isBodyProps } from "./components/Body/index.js";
|
|
5
5
|
import Button from "./components/Button/index.js";
|
|
6
|
-
import { i as isButtonAsLinkProps, f as isButtonProps, B as ButtonAsLink } from "./validate-
|
|
6
|
+
import { i as isButtonAsLinkProps, f as isButtonProps, B as ButtonAsLink } from "./validate-Dlzxlfzp.js";
|
|
7
7
|
import ButtonGroup, { isButtonGroupProps } from "./components/ButtonGroup/index.js";
|
|
8
8
|
import Card, { isCardProps } from "./components/Card/index.js";
|
|
9
9
|
import ConsentMessage from "./components/ConsentMessage/index.js";
|
|
@@ -48,7 +48,7 @@ import "./styled-Dq0NuP5r.js";
|
|
|
48
48
|
import "./components/InlineLink/index.js";
|
|
49
49
|
import "./TableWrapper-Do9KCTGV.js";
|
|
50
50
|
import "./index-CLHcudLb.js";
|
|
51
|
-
import "./styled-
|
|
51
|
+
import "./styled-0KSRG-Fv.js";
|
|
52
52
|
const validateLegibleContent = (check) => {
|
|
53
53
|
var _a, _b, _c, _d;
|
|
54
54
|
if (null === check) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import styled from "styled-components";
|
|
2
2
|
import { a as CardStyled } from "./styled-Dq0NuP5r.js";
|
|
3
|
-
import { D as DemoBoxStyled } from "./styled-
|
|
3
|
+
import { D as DemoBoxStyled } from "./styled-Dw5c-xwf.js";
|
|
4
4
|
import viewport from "./foundations/media-query/viewport/index.js";
|
|
5
5
|
import { getSpacing } from "./foundations/token/getSpacing/index.js";
|
|
6
6
|
import { s as spacingMd } from "./Spacing-8v6hcO2x.js";
|
|
@@ -12,7 +12,7 @@ const DemoBoxStyled = styled.div.withConfig({
|
|
|
12
12
|
displayName: "DemoBoxStyled",
|
|
13
13
|
componentId: "sc-xo01zx-0"
|
|
14
14
|
})({
|
|
15
|
-
|
|
15
|
+
minHeight: "100px",
|
|
16
16
|
background: "#FFC5A8",
|
|
17
17
|
border: `1px dashed ${getBorderColor(colorBorderWarning)}`,
|
|
18
18
|
color: getTextColor(colorTextNeutral),
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { i as iconSizeSm } from "./IconSize-AJp7xdJi.js";
|
|
3
|
-
import {
|
|
3
|
+
import { a as ButtonIconStyled, l as leftPosition, b as buttonHeight, p as primaryAppearance, s as secondaryAppearance, t as tertiaryAppearance, r as rightPosition } from "./styled-7vJ7mrAA.js";
|
|
4
4
|
import { useLinkComponent } from "./hooks/useLinkComponent/index.js";
|
|
5
5
|
import { a as filterProps, f as filterPropsForUnstyledComponent } from "./filterProps-BJ5SpbnA.js";
|
|
6
6
|
import { r as renderInlineRichTextFromOpenText } from "./renderInlineRichTextFromOpenText-RvOG3QbI.js";
|
|
@@ -21,12 +21,12 @@ import "html-react-parser";
|
|
|
21
21
|
import { i as isObject, h as hasMatchingComponentName } from "./isObject-BYBrvoVW.js";
|
|
22
22
|
import { i as isBottomSpacing } from "./isBottomSpacing-BxfreCZU.js";
|
|
23
23
|
import { b as iconNames } from "./index--RjkzZm0.js";
|
|
24
|
-
const getButtonIcon = (icon) => {
|
|
25
|
-
if (!icon
|
|
24
|
+
const getButtonIcon = (icon, iconPosition) => {
|
|
25
|
+
if (!icon) {
|
|
26
26
|
return null;
|
|
27
27
|
}
|
|
28
|
-
const position =
|
|
29
|
-
return /* @__PURE__ */ jsx(ButtonIconStyled, { iconPosition: position, size: iconSizeSm, name: icon
|
|
28
|
+
const position = iconPosition || leftPosition;
|
|
29
|
+
return /* @__PURE__ */ jsx(ButtonIconStyled, { iconPosition: position, size: iconSizeSm, name: icon });
|
|
30
30
|
};
|
|
31
31
|
const ButtonAsLinkStyled = styled.span.withConfig({
|
|
32
32
|
shouldForwardProp: filterProps(["href"]),
|