@arc-ui/community-components 3.1.0 → 3.3.0
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/.turbo/turbo-build.log +14 -14
- package/CHANGELOG.md +31 -0
- package/lib/Accordion/Accordion.cjs +2 -3
- package/lib/Accordion/Accordion.mjs +2 -3
- package/lib/ActionTile/ActionTile.cjs +4 -5
- package/lib/ActionTile/ActionTile.mjs +2 -3
- package/lib/ActionTile/styles.css +1 -1
- package/lib/ArticleSidebar/ArticleSidebar.cjs +9 -10
- package/lib/ArticleSidebar/ArticleSidebar.mjs +4 -5
- package/lib/Author/Author.cjs +2 -3
- package/lib/Author/Author.mjs +2 -3
- package/lib/BannerWithTabs/BannerWithTabs.cjs +4 -5
- package/lib/BannerWithTabs/BannerWithTabs.mjs +4 -5
- package/lib/ContentInfoWidget/ContentInfoWidget.cjs +3 -2
- package/lib/ContentInfoWidget/ContentInfoWidget.mjs +3 -2
- package/lib/CopyLead/CopyLead.cjs +15 -16
- package/lib/CopyLead/CopyLead.mjs +3 -4
- package/lib/DownloadList/DownloadList.cjs +6 -8
- package/lib/DownloadList/DownloadList.mjs +6 -8
- package/lib/FAQs/FAQs.cjs +15 -12
- package/lib/FAQs/FAQs.mjs +13 -10
- package/lib/FeaturePost/FeaturePost.cjs +23 -17
- package/lib/FeaturePost/FeaturePost.mjs +18 -12
- package/lib/Highlights/Highlights.cjs +11 -12
- package/lib/Highlights/Highlights.mjs +11 -12
- package/lib/InlineLinkGroup/InlineLinkGroup.cjs +25 -0
- package/lib/InlineLinkGroup/InlineLinkGroup.mjs +23 -0
- package/lib/InlineLinkGroup/styles.css +1 -0
- package/lib/LinkTile/LinkTile.cjs +6 -6
- package/lib/LinkTile/LinkTile.mjs +4 -4
- package/lib/LinkTile/styles.css +1 -1
- package/lib/ProductNavigation/ProductNavigation.cjs +6 -7
- package/lib/ProductNavigation/ProductNavigation.mjs +3 -4
- package/lib/PromoListing/PromoListing.cjs +7 -8
- package/lib/PromoListing/PromoListing.mjs +5 -6
- package/lib/PromoListingThumbnailSignpost/PromoListingThumbnailSignpost.cjs +27 -0
- package/lib/PromoListingThumbnailSignpost/PromoListingThumbnailSignpost.mjs +25 -0
- package/lib/PromoListingThumbnailSignpost/styles.css +1 -0
- package/lib/Quote/Quote.cjs +5 -6
- package/lib/Quote/Quote.mjs +3 -4
- package/lib/SectionHeading/SectionHeading.cjs +2 -3
- package/lib/SectionHeading/SectionHeading.mjs +2 -3
- package/lib/Statistics/Statistics.cjs +21 -19
- package/lib/Statistics/Statistics.mjs +21 -19
- package/lib/Statistics/styles.css +1 -1
- package/lib/Summary/Summary.cjs +4 -4
- package/lib/Summary/Summary.mjs +4 -4
- package/lib/ThumbnailSignpost/ThumbnailSignpost.cjs +14 -0
- package/lib/ThumbnailSignpost/ThumbnailSignpost.mjs +8 -0
- package/lib/ThumbnailSignpost/styles.css +1 -0
- package/lib/_shared/cjs/{Accordion-BCJIm1Gq.cjs → Accordion-QqDoB3pY.cjs} +9 -10
- package/lib/_shared/cjs/{Author-D4dKNQem.cjs → Author-aL8YXi7C.cjs} +4 -5
- package/lib/_shared/cjs/{SectionHeading-DeSFM0HV.cjs → SectionHeading-Dj-dJfv3.cjs} +4 -5
- package/lib/_shared/cjs/ThumbnailSignpost-SBnrGooA.cjs +38 -0
- package/lib/_shared/cjs/{tslib.es6-BxB9I209.cjs → filter-attrs-C26zOt4_.cjs} +25 -0
- package/lib/_shared/cjs/{index.es-DzI6hGjj.cjs → index.es-Dq8bYrbW.cjs} +1 -1
- package/lib/_shared/esm/{Accordion-BN_lZk6L.mjs → Accordion-DrOTh90S.mjs} +2 -3
- package/lib/_shared/esm/{Author-HnYsFTPT.mjs → Author-BVCRPgkl.mjs} +1 -2
- package/lib/_shared/esm/{SectionHeading-CpDLCndw.mjs → SectionHeading-DZOg_gYi.mjs} +1 -2
- package/lib/_shared/esm/ThumbnailSignpost-DaZByYIH.mjs +36 -0
- package/lib/_shared/esm/{tslib.es6-D6Wu-xwB.mjs → filter-attrs-D-1kWaCP.mjs} +25 -1
- package/lib/_shared/esm/{index.es-B6Bolkcx.mjs → index.es-Bfdys5__.mjs} +1 -1
- package/lib/index.cjs +218 -173
- package/lib/index.cjs.map +1 -1
- package/lib/index.d.cts +60 -64
- package/lib/index.d.mts +60 -64
- package/lib/index.mjs +216 -173
- package/lib/index.mjs.map +1 -1
- package/lib/styles.css +1 -1
- package/package.json +13 -13
- package/src/components/Accordion/components/AccordionDisclosureList/AccordionDisclosureList.tsx +1 -1
- package/src/components/ActionTile/ActionTile.module.css +56 -37
- package/src/components/ActionTile/ActionTile.tsx +1 -1
- package/src/components/ArticleSidebar/ArticleSidebar.tsx +4 -6
- package/src/components/Author/Author.tsx +0 -3
- package/src/components/BannerWithTabs/BannerWithTabs.tsx +4 -6
- package/src/components/ContentInfoWidget/ContentInfoWidget.tsx +3 -4
- package/src/components/DownloadList/DownloadList.tsx +8 -8
- package/src/components/FAQs/FAQs.tsx +13 -6
- package/src/components/FeaturePost/FeaturePost.tsx +9 -9
- package/src/components/FeaturePost/components/Image/Image.tsx +31 -7
- package/src/components/FeaturePost/types/feature-post-image.ts +2 -0
- package/src/components/Highlights/Highlights.tsx +3 -2
- package/src/components/Highlights/components/HighlightItem/HighlightItem.tsx +3 -2
- package/src/components/Highlights/components/HighlightList/HighlightList.tsx +5 -2
- package/src/components/InlineLinkGroup/InlineLinkGroup.module.css +81 -0
- package/src/components/InlineLinkGroup/InlineLinkGroup.tsx +67 -0
- package/src/components/InlineLinkGroup/index.ts +5 -0
- package/src/components/LinkTile/LinkTile.module.css +62 -26
- package/src/components/LinkTile/LinkTile.tsx +8 -1
- package/src/components/PromoListing/PromoListing.tsx +3 -11
- package/src/components/PromoListingThumbnailSignpost/PromoListingThumbnailSignpost.module.css +54 -0
- package/src/components/PromoListingThumbnailSignpost/PromoListingThumbnailSignpost.tsx +53 -0
- package/src/components/PromoListingThumbnailSignpost/index.ts +4 -0
- package/src/components/Quote/Quote.tsx +1 -7
- package/src/components/Statistics/Statistics.module.css +0 -10
- package/src/components/Statistics/Statistics.tsx +35 -32
- package/src/components/Summary/Summary.tsx +3 -1
- package/src/components/ThumbnailSignpost/ThumbnailSignpost.module.css +112 -0
- package/src/components/ThumbnailSignpost/ThumbnailSignpost.tsx +100 -0
- package/src/components/ThumbnailSignpost/index.ts +4 -0
- package/src/components/index.ts +3 -1
- package/versions.json +1 -1
- package/lib/HeroLink/HeroLink.cjs +0 -35
- package/lib/HeroLink/HeroLink.mjs +0 -33
- package/lib/HeroLink/styles.css +0 -1
- package/lib/_shared/cjs/filter-attrs-BizjMsy0.cjs +0 -27
- package/lib/_shared/esm/filter-attrs-DZ7RCEZm.mjs +0 -25
- package/src/components/HeroLink/HeroLink.module.css +0 -44
- package/src/components/HeroLink/HeroLink.tsx +0 -136
- package/src/components/HeroLink/index.ts +0 -2
|
@@ -5,9 +5,8 @@ import { Icon } from "@arc-ui/components/Icon";
|
|
|
5
5
|
import { Text } from "@arc-ui/components/Text";
|
|
6
6
|
import { Link } from "@arc-ui/components/Link";
|
|
7
7
|
import { VerticalSpace } from "@arc-ui/components/VerticalSpace";
|
|
8
|
-
|
|
8
|
+
import { filterAttrs } from "@arc-ui/community-utils/filter-attrs";
|
|
9
9
|
import { type HighlightLink } from "../../types";
|
|
10
|
-
|
|
11
10
|
import styles from "../../Highlights.module.css";
|
|
12
11
|
import { getListHeadingLevel } from "../../utils/getListHeadingLevel";
|
|
13
12
|
|
|
@@ -18,6 +17,7 @@ export const HighlightItem: React.FC<HighlightItemProps> = ({
|
|
|
18
17
|
link,
|
|
19
18
|
isSmallIcon,
|
|
20
19
|
headingLevel,
|
|
20
|
+
...props
|
|
21
21
|
}) => {
|
|
22
22
|
const listHeadingLevel = getListHeadingLevel(headingLevel || "2");
|
|
23
23
|
|
|
@@ -25,6 +25,7 @@ export const HighlightItem: React.FC<HighlightItemProps> = ({
|
|
|
25
25
|
<div
|
|
26
26
|
data-testid="highlight-item-container"
|
|
27
27
|
className={styles.highlightItem}
|
|
28
|
+
{...filterAttrs(props)}
|
|
28
29
|
>
|
|
29
30
|
{icon && (
|
|
30
31
|
<div className={styles.Icon}>
|
|
@@ -4,7 +4,7 @@ import classNames from "classnames";
|
|
|
4
4
|
import { type HighlightListItem } from "../../types/highlight-list-item";
|
|
5
5
|
import { HighlightItem } from "../HighlightItem/HighlightItem";
|
|
6
6
|
import { HeadingLevel } from "@arc-ui/components/Heading";
|
|
7
|
-
|
|
7
|
+
import { filterAttrs } from "@arc-ui/community-utils/filter-attrs";
|
|
8
8
|
import styles from "../../Highlights.module.css";
|
|
9
9
|
|
|
10
10
|
export const HighlightList: React.FC<HighlightListProps> = ({
|
|
@@ -12,6 +12,7 @@ export const HighlightList: React.FC<HighlightListProps> = ({
|
|
|
12
12
|
columns,
|
|
13
13
|
isSmallIcon,
|
|
14
14
|
headingLevel,
|
|
15
|
+
...props
|
|
15
16
|
}) => {
|
|
16
17
|
const id = useId();
|
|
17
18
|
|
|
@@ -22,8 +23,9 @@ export const HighlightList: React.FC<HighlightListProps> = ({
|
|
|
22
23
|
styles.highlights,
|
|
23
24
|
styles[`highlights${columns}Column`],
|
|
24
25
|
)}
|
|
26
|
+
{...filterAttrs(props)}
|
|
25
27
|
>
|
|
26
|
-
{listItems.map(({ icon, heading, text, link }, i) => (
|
|
28
|
+
{listItems.map(({ icon, heading, text, link, ...itemProps }, i) => (
|
|
27
29
|
<HighlightItem
|
|
28
30
|
key={`highlight-${id}-${i}`}
|
|
29
31
|
icon={icon}
|
|
@@ -32,6 +34,7 @@ export const HighlightList: React.FC<HighlightListProps> = ({
|
|
|
32
34
|
link={link}
|
|
33
35
|
isSmallIcon={isSmallIcon}
|
|
34
36
|
headingLevel={headingLevel}
|
|
37
|
+
{...itemProps}
|
|
35
38
|
/>
|
|
36
39
|
))}
|
|
37
40
|
</div>
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
@import url("@arc-ui/tokens-arc/dist/custom-media.css");
|
|
2
|
+
|
|
3
|
+
.quick-help {
|
|
4
|
+
display: flex;
|
|
5
|
+
flex-direction: column;
|
|
6
|
+
align-items: center;
|
|
7
|
+
width: 100%;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
/* remove default list styles */
|
|
11
|
+
.quick-help ul,
|
|
12
|
+
.quick-help li {
|
|
13
|
+
list-style: none;
|
|
14
|
+
margin: 0;
|
|
15
|
+
padding: 0;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
.quick-help-label {
|
|
19
|
+
display: flex;
|
|
20
|
+
flex-direction: row;
|
|
21
|
+
align-items: center;
|
|
22
|
+
padding-bottom: var(--sem-space-padding-110);
|
|
23
|
+
width: 100%;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
/* container for links */
|
|
27
|
+
.quick-help-container {
|
|
28
|
+
display: flex;
|
|
29
|
+
flex-direction: row;
|
|
30
|
+
flex-wrap: wrap;
|
|
31
|
+
align-items: center;
|
|
32
|
+
gap: var(--sem-space-padding-70);
|
|
33
|
+
width: 100%;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
/* each link item */
|
|
37
|
+
.quick-help-item {
|
|
38
|
+
display: flex;
|
|
39
|
+
align-items: center;
|
|
40
|
+
gap: var(--arc-spacing-4);
|
|
41
|
+
width: auto;
|
|
42
|
+
flex: 0 0 auto;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
/* hide arrow icon on desktop/tablet */
|
|
46
|
+
.quick-help-item svg {
|
|
47
|
+
display: none;
|
|
48
|
+
width: 24px;
|
|
49
|
+
height: 24px;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
/* separator between links */
|
|
53
|
+
.quick-help-separator {
|
|
54
|
+
display: flex;
|
|
55
|
+
align-items: center;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
.quick-help-separator-line {
|
|
59
|
+
width: 1px;
|
|
60
|
+
height: 14px;
|
|
61
|
+
background: var(--sem-color-border-secondary-light-minimal);
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
/* XS breakpoint: stack vertically */
|
|
65
|
+
@media not (--arc-custom-media-min-width-s-px) {
|
|
66
|
+
.quick-help-container {
|
|
67
|
+
flex-direction: column;
|
|
68
|
+
align-items: flex-start;
|
|
69
|
+
gap: var(--sem-space-padding-70);
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
/* show arrow icon */
|
|
73
|
+
.quick-help-item svg {
|
|
74
|
+
display: block;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
/* hide separators */
|
|
78
|
+
.quick-help-separator {
|
|
79
|
+
display: none;
|
|
80
|
+
}
|
|
81
|
+
}
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { Link } from "@arc-ui/components/Link";
|
|
3
|
+
import { Icon } from "@arc-ui/components/Icon";
|
|
4
|
+
import { Heading } from "@arc-ui/components/Heading";
|
|
5
|
+
import { BtIconArrowAltRight } from "@arc-ui/icons/BtIconArrowAltRight";
|
|
6
|
+
import { filterAttrs } from "@arc-ui/community-utils/filter-attrs";
|
|
7
|
+
import styles from "./InlineLinkGroup.module.css";
|
|
8
|
+
|
|
9
|
+
export const InlineLinkGroup: React.FC<InlineLinkGroupProps> = ({
|
|
10
|
+
label,
|
|
11
|
+
links,
|
|
12
|
+
...props
|
|
13
|
+
}) => {
|
|
14
|
+
return (
|
|
15
|
+
<div className={styles["quick-help"]} {...filterAttrs(props)}>
|
|
16
|
+
{label && (
|
|
17
|
+
<div className={styles["quick-help-label"]}>
|
|
18
|
+
<Heading size="xxs" fontStyle="overline">
|
|
19
|
+
{label}
|
|
20
|
+
</Heading>
|
|
21
|
+
</div>
|
|
22
|
+
)}
|
|
23
|
+
|
|
24
|
+
<ul className={styles["quick-help-container"]}>
|
|
25
|
+
{links.map((link, index) => (
|
|
26
|
+
<React.Fragment key={index}>
|
|
27
|
+
<li className={styles["quick-help-item"]}>
|
|
28
|
+
<Link
|
|
29
|
+
href={link.href}
|
|
30
|
+
onClick={link.onClick}
|
|
31
|
+
aria-label={link.ariaLabel}
|
|
32
|
+
>
|
|
33
|
+
{link.label}
|
|
34
|
+
</Link>
|
|
35
|
+
|
|
36
|
+
<Icon icon={BtIconArrowAltRight} size={24} color="brand" />
|
|
37
|
+
</li>
|
|
38
|
+
|
|
39
|
+
{index < links.length - 1 && (
|
|
40
|
+
<li className={styles["quick-help-separator"]} aria-hidden="true">
|
|
41
|
+
<div className={styles["quick-help-separator-line"]} />
|
|
42
|
+
</li>
|
|
43
|
+
)}
|
|
44
|
+
</React.Fragment>
|
|
45
|
+
))}
|
|
46
|
+
</ul>
|
|
47
|
+
</div>
|
|
48
|
+
);
|
|
49
|
+
};
|
|
50
|
+
|
|
51
|
+
export interface InlineLinkGroupProps {
|
|
52
|
+
/** Optional overline label displayed above the link group */
|
|
53
|
+
label?: string;
|
|
54
|
+
/** Array of link items to display */
|
|
55
|
+
links: InlineLinkGroupItem[];
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
export interface InlineLinkGroupItem {
|
|
59
|
+
/** Display text for the link */
|
|
60
|
+
label: string;
|
|
61
|
+
/** URL the link navigates to */
|
|
62
|
+
href: string;
|
|
63
|
+
/** Optional click handler for the link */
|
|
64
|
+
onClick?: () => void;
|
|
65
|
+
/** Optional accessible label for screen readers */
|
|
66
|
+
ariaLabel?: string;
|
|
67
|
+
}
|
|
@@ -1,57 +1,93 @@
|
|
|
1
|
+
@import url("@arc-ui/tokens-arc/dist/custom-media.css");
|
|
2
|
+
|
|
1
3
|
.link-tile {
|
|
4
|
+
box-sizing: border-box;
|
|
2
5
|
display: flex;
|
|
3
6
|
flex-direction: column;
|
|
7
|
+
justify-content: center;
|
|
8
|
+
align-items: center;
|
|
4
9
|
width: 306px;
|
|
5
|
-
|
|
6
|
-
border
|
|
7
|
-
|
|
8
|
-
|
|
10
|
+
height: 96px;
|
|
11
|
+
border: var(--sem-border-width-xxs) solid
|
|
12
|
+
var(--sem-color-border-secondary-light-minimal);
|
|
13
|
+
border-radius: var(--sem-border-radius-xl);
|
|
14
|
+
padding: var(--sem-space-padding-110) var(--sem-space-padding-70)
|
|
15
|
+
var(--sem-space-padding-110) var(--sem-space-padding-110);
|
|
16
|
+
background: var(--sem-color-bg-secondary-light-default);
|
|
9
17
|
text-decoration: none;
|
|
10
18
|
cursor: pointer;
|
|
11
|
-
transition:
|
|
12
|
-
|
|
13
|
-
|
|
19
|
+
transition: border-color 0.2s ease;
|
|
20
|
+
flex: none;
|
|
21
|
+
align-self: stretch;
|
|
22
|
+
position: relative;
|
|
23
|
+
overflow: visible;
|
|
14
24
|
}
|
|
15
25
|
|
|
16
26
|
.link-tile-content {
|
|
17
27
|
display: flex;
|
|
28
|
+
flex-direction: row;
|
|
29
|
+
justify-content: center;
|
|
18
30
|
align-items: center;
|
|
19
|
-
|
|
20
|
-
|
|
31
|
+
gap: var(--sem-space-padding-40);
|
|
32
|
+
width: 100%;
|
|
33
|
+
height: 48px;
|
|
34
|
+
flex: none;
|
|
35
|
+
align-self: stretch;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.link-tile-icon {
|
|
39
|
+
display: flex;
|
|
40
|
+
width: 32px;
|
|
41
|
+
height: 32px;
|
|
42
|
+
color: var(--sem-color-fg-primary-light-default);
|
|
43
|
+
transition: color 0.2s ease;
|
|
44
|
+
flex: none;
|
|
45
|
+
flex-shrink: 0;
|
|
46
|
+
order: 1;
|
|
21
47
|
}
|
|
22
48
|
|
|
23
49
|
.link-tile-text {
|
|
24
|
-
font-family:
|
|
25
|
-
font-size:
|
|
26
|
-
font-weight:
|
|
27
|
-
line-height:
|
|
50
|
+
font-family: var(--sem-font-family-heading);
|
|
51
|
+
font-size: var(--sem-font-size-100);
|
|
52
|
+
font-weight: var(--sem-font-weight-semi);
|
|
53
|
+
line-height: var(--sem-line-height-base-scale-xs);
|
|
28
54
|
letter-spacing: 0;
|
|
29
|
-
color:
|
|
55
|
+
color: var(--sem-color-fg-primary-light-default);
|
|
30
56
|
transition: color 0.2s ease;
|
|
31
57
|
flex: 1;
|
|
58
|
+
order: 0;
|
|
32
59
|
}
|
|
33
60
|
|
|
61
|
+
.link-tile-icon svg,
|
|
34
62
|
.link-tile .link-tile-content svg {
|
|
35
|
-
color:
|
|
36
|
-
flex-shrink: 0;
|
|
63
|
+
color: inherit;
|
|
37
64
|
transition: color 0.2s ease;
|
|
38
65
|
}
|
|
39
66
|
|
|
40
|
-
.link-tile:
|
|
41
|
-
|
|
67
|
+
.link-tile:not(:has(svg)) {
|
|
68
|
+
padding: var(--sem-space-padding-110);
|
|
42
69
|
}
|
|
43
70
|
|
|
44
71
|
.link-tile:active {
|
|
45
|
-
border-radius:
|
|
72
|
+
border-radius: var(--sem-border-radius-xl);
|
|
46
73
|
}
|
|
47
74
|
|
|
48
|
-
|
|
49
|
-
.link-tile:hover .link-tile-content svg {
|
|
50
|
-
color: #3f187f;
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
@media (width <= 1023px) {
|
|
75
|
+
@media (--arc-custom-media-min-width-l-px) {
|
|
54
76
|
.link-tile {
|
|
55
|
-
padding:
|
|
77
|
+
padding: var(--sem-space-padding-110) var(--sem-space-padding-70)
|
|
78
|
+
var(--sem-space-padding-110) var(--sem-space-padding-110);
|
|
56
79
|
}
|
|
57
80
|
}
|
|
81
|
+
|
|
82
|
+
.link-tile:hover {
|
|
83
|
+
border-color: transparent;
|
|
84
|
+
box-shadow: inset 0 0 0 2px var(--button-v2-colors-light-text-hover);
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
.link-tile:hover .link-tile-text {
|
|
88
|
+
color: var(--button-v2-colors-light-text-hover);
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
.link-tile:hover .link-tile-icon {
|
|
92
|
+
color: var(--button-v2-colors-light-text-hover);
|
|
93
|
+
}
|
|
@@ -24,7 +24,11 @@ export const LinkTile: React.FC<LinkTileProps> = ({
|
|
|
24
24
|
{text && (
|
|
25
25
|
<div className={styles["link-tile-content"]}>
|
|
26
26
|
<span className={styles["link-tile-text"]}>{text}</span>
|
|
27
|
-
{showIcon &&
|
|
27
|
+
{showIcon && (
|
|
28
|
+
<span className={styles["link-tile-icon"]}>
|
|
29
|
+
<Icon icon={BtIconArrowAltRight} size={32} />
|
|
30
|
+
</span>
|
|
31
|
+
)}
|
|
28
32
|
</div>
|
|
29
33
|
)}
|
|
30
34
|
</Component>
|
|
@@ -32,7 +36,10 @@ export const LinkTile: React.FC<LinkTileProps> = ({
|
|
|
32
36
|
};
|
|
33
37
|
|
|
34
38
|
export interface LinkTileProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
39
|
+
/** Display text for the tile */
|
|
35
40
|
text?: string;
|
|
41
|
+
/** URL the tile navigates to. Renders as an anchor tag when provided */
|
|
36
42
|
href?: string;
|
|
43
|
+
/** Whether to show the arrow icon. Defaults to true */
|
|
37
44
|
showIcon?: boolean;
|
|
38
45
|
}
|
|
@@ -1,17 +1,12 @@
|
|
|
1
1
|
import React, { useId, ComponentType } from "react";
|
|
2
|
-
|
|
3
2
|
import classNames from "classnames";
|
|
4
|
-
|
|
5
3
|
import { ArcSizeBreakpointsL, ArcSizeBreakpointsM } from "@arc-ui/tokens-arc";
|
|
6
|
-
|
|
7
4
|
import { Carousel } from "@arc-ui/components/Carousel";
|
|
8
5
|
import { Heading, type HeadingLevel } from "@arc-ui/components/Heading";
|
|
9
6
|
import { useMediaQuery } from "@arc-ui/components/use-media-query";
|
|
10
|
-
|
|
11
7
|
import { SectionHeading, type SectionHeadingProps } from "../SectionHeading";
|
|
12
|
-
|
|
13
8
|
import { MediaCard, type MediaCardProps } from "@arc-ui/components/MediaCard";
|
|
14
|
-
|
|
9
|
+
import { filterAttrs } from "@arc-ui/community-utils/filter-attrs";
|
|
15
10
|
import {
|
|
16
11
|
ImpactCard,
|
|
17
12
|
type ImpactCardProps,
|
|
@@ -49,6 +44,7 @@ export const PromoListing: React.FC<PromoListingProps> = ({
|
|
|
49
44
|
button = { buttonStyle: "secondary" },
|
|
50
45
|
overlineHeadingLevel,
|
|
51
46
|
overlineLabel,
|
|
47
|
+
...props
|
|
52
48
|
}) => {
|
|
53
49
|
const componentId = useId();
|
|
54
50
|
|
|
@@ -97,7 +93,7 @@ export const PromoListing: React.FC<PromoListingProps> = ({
|
|
|
97
93
|
};
|
|
98
94
|
|
|
99
95
|
return (
|
|
100
|
-
<div className={styles.PromoListing}>
|
|
96
|
+
<div className={styles.PromoListing} {...filterAttrs(props)}>
|
|
101
97
|
{overlineLabel && (
|
|
102
98
|
<>
|
|
103
99
|
<Heading level={overlineHeadingLevel} fontStyle="overline">
|
|
@@ -230,8 +226,4 @@ interface PromoListingButton
|
|
|
230
226
|
* Style variant for the button. Defaults to "secondary".
|
|
231
227
|
*/
|
|
232
228
|
buttonStyle?: "secondary" | "compact";
|
|
233
|
-
/**
|
|
234
|
-
* Optional prop to pass additional props to the button. Only data-* and aria-* will work.
|
|
235
|
-
*/
|
|
236
|
-
[key: string]: unknown;
|
|
237
229
|
}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
@import url("@arc-ui/tokens-arc/dist/custom-media.css");
|
|
2
|
+
|
|
3
|
+
.PromoListingThumbnailSignpost {
|
|
4
|
+
max-width: 1280px;
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
.PromoListingThumbnailSignpost ul,
|
|
8
|
+
.PromoListingThumbnailSignpost li {
|
|
9
|
+
text-decoration: none;
|
|
10
|
+
padding: 0;
|
|
11
|
+
margin: 0;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
.list {
|
|
15
|
+
display: grid;
|
|
16
|
+
grid-template-columns: repeat(12, 1fr);
|
|
17
|
+
column-gap: var(--arc-size-grid-gutter-s);
|
|
18
|
+
row-gap: 24px;
|
|
19
|
+
list-style: none;
|
|
20
|
+
margin: 0;
|
|
21
|
+
padding: 0;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
.list li {
|
|
25
|
+
grid-column: span 12;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
@media (--arc-custom-media-min-width-s-px) {
|
|
29
|
+
.list {
|
|
30
|
+
row-gap: 32px;
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
@media (--arc-custom-media-min-width-m-px) {
|
|
35
|
+
.list {
|
|
36
|
+
column-gap: var(--arc-size-grid-gutter-m);
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.list li {
|
|
40
|
+
grid-column: span 6;
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
@media (--arc-custom-media-min-width-l-px) {
|
|
45
|
+
.list {
|
|
46
|
+
row-gap: 40px;
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
@media (--arc-custom-media-min-width-xl-px) {
|
|
51
|
+
.list {
|
|
52
|
+
column-gap: var(--arc-size-grid-gutter-l);
|
|
53
|
+
}
|
|
54
|
+
}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
|
|
3
|
+
import { SectionHeading, type SectionHeadingProps } from "../SectionHeading";
|
|
4
|
+
|
|
5
|
+
import { filterAttrs } from "@arc-ui/community-utils/filter-attrs";
|
|
6
|
+
|
|
7
|
+
import styles from "./PromoListingThumbnailSignpost.module.css";
|
|
8
|
+
|
|
9
|
+
import {
|
|
10
|
+
ThumbnailSignpost,
|
|
11
|
+
type ThumbnailSignpostProps,
|
|
12
|
+
} from "../ThumbnailSignpost";
|
|
13
|
+
|
|
14
|
+
/**
|
|
15
|
+
* Use `PromoListingThumbnailSignpost` to give supporting information about a page or proposition in the form of the ThumbnailSignposts components.
|
|
16
|
+
*/
|
|
17
|
+
export const PromoListingThumbnailSignpost: React.FC<
|
|
18
|
+
PromoListingThumbnailSignpostProps
|
|
19
|
+
> = ({
|
|
20
|
+
isPadded = true,
|
|
21
|
+
heading,
|
|
22
|
+
content,
|
|
23
|
+
headingLevel,
|
|
24
|
+
thumbnailList,
|
|
25
|
+
...props
|
|
26
|
+
}) => {
|
|
27
|
+
return (
|
|
28
|
+
<div
|
|
29
|
+
className={styles.PromoListingThumbnailSignpost}
|
|
30
|
+
{...filterAttrs(props)}
|
|
31
|
+
>
|
|
32
|
+
<SectionHeading
|
|
33
|
+
isPadded={isPadded}
|
|
34
|
+
data-testid="PromoListingThumbnailSignpost-header"
|
|
35
|
+
heading={heading}
|
|
36
|
+
headingLevel={headingLevel}
|
|
37
|
+
content={content}
|
|
38
|
+
/>
|
|
39
|
+
<ul className={styles.list}>
|
|
40
|
+
{thumbnailList.map((thumbnail, index) => (
|
|
41
|
+
<li key={index}>
|
|
42
|
+
<ThumbnailSignpost {...thumbnail} />
|
|
43
|
+
</li>
|
|
44
|
+
))}
|
|
45
|
+
</ul>
|
|
46
|
+
</div>
|
|
47
|
+
);
|
|
48
|
+
};
|
|
49
|
+
|
|
50
|
+
export interface PromoListingThumbnailSignpostProps
|
|
51
|
+
extends SectionHeadingProps {
|
|
52
|
+
thumbnailList: ThumbnailSignpostProps[];
|
|
53
|
+
}
|
|
@@ -38,13 +38,7 @@ export const Quote: React.FC<QuoteProps> = ({
|
|
|
38
38
|
</svg>
|
|
39
39
|
<p className={styles.quoteContent}>{content}</p>
|
|
40
40
|
</blockquote>
|
|
41
|
-
{author &&
|
|
42
|
-
<Author
|
|
43
|
-
name={author.name}
|
|
44
|
-
title={author.title}
|
|
45
|
-
avatar={author.avatar}
|
|
46
|
-
/>
|
|
47
|
-
)}
|
|
41
|
+
{author && <Author {...author} />}
|
|
48
42
|
</div>
|
|
49
43
|
);
|
|
50
44
|
};
|
|
@@ -1,16 +1,14 @@
|
|
|
1
1
|
import React, { useId } from "react";
|
|
2
|
-
|
|
2
|
+
import { filterAttrs } from "@arc-ui/community-utils/filter-attrs";
|
|
3
3
|
import { Columns, ColumnsCol } from "@arc-ui/components/Columns";
|
|
4
4
|
import { Rule } from "@arc-ui/components/Rule";
|
|
5
5
|
import { Text } from "@arc-ui/components/Text";
|
|
6
6
|
import { Align } from "@arc-ui/components/Align";
|
|
7
7
|
import { Heading } from "@arc-ui/components/Heading";
|
|
8
8
|
import { VerticalSpace } from "@arc-ui/components/VerticalSpace";
|
|
9
|
-
|
|
9
|
+
import { Hidden } from "@arc-ui/components/Hidden";
|
|
10
10
|
import { SectionHeading, type SectionHeadingProps } from "../SectionHeading";
|
|
11
|
-
|
|
12
11
|
import styles from "./Statistics.module.css";
|
|
13
|
-
|
|
14
12
|
import { getLinkProps } from "./helpers/get-link-props";
|
|
15
13
|
import { type Statistic } from "./types/statistic";
|
|
16
14
|
|
|
@@ -21,11 +19,12 @@ export const Statistics: React.FC<StatisticsProps> = ({
|
|
|
21
19
|
heading,
|
|
22
20
|
content,
|
|
23
21
|
statistics,
|
|
22
|
+
...props
|
|
24
23
|
}) => {
|
|
25
24
|
const componentId = useId();
|
|
26
25
|
|
|
27
26
|
return (
|
|
28
|
-
<Columns>
|
|
27
|
+
<Columns isGutterless {...filterAttrs(props)}>
|
|
29
28
|
<ColumnsCol spanM={9}>
|
|
30
29
|
<SectionHeading
|
|
31
30
|
id={id}
|
|
@@ -34,7 +33,6 @@ export const Statistics: React.FC<StatisticsProps> = ({
|
|
|
34
33
|
headingLevel={headingLevel}
|
|
35
34
|
content={content}
|
|
36
35
|
/>
|
|
37
|
-
<VerticalSpace size="16" />
|
|
38
36
|
</ColumnsCol>
|
|
39
37
|
<ColumnsCol spanL={9}>
|
|
40
38
|
<ul className={styles.list}>
|
|
@@ -54,38 +52,43 @@ export const Statistics: React.FC<StatisticsProps> = ({
|
|
|
54
52
|
<Heading color="brand" size="xxl">
|
|
55
53
|
{stat}
|
|
56
54
|
</Heading>
|
|
55
|
+
<Hidden s m l xl xxl>
|
|
56
|
+
<VerticalSpace size="12" />
|
|
57
|
+
</Hidden>
|
|
57
58
|
</div>
|
|
58
59
|
</Align>
|
|
59
60
|
</ColumnsCol>
|
|
60
61
|
<ColumnsCol spanS={6} spanM={4}>
|
|
61
|
-
<
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
62
|
+
<Align vertical="center">
|
|
63
|
+
<Text>{copy}</Text>
|
|
64
|
+
{link && (
|
|
65
|
+
<>
|
|
66
|
+
<VerticalSpace size="12" />
|
|
67
|
+
<a
|
|
68
|
+
href={link.href}
|
|
69
|
+
aria-label={link.ariaLabel}
|
|
70
|
+
{...getLinkProps(link)}
|
|
71
|
+
>
|
|
72
|
+
{link.text}
|
|
73
|
+
</a>
|
|
74
|
+
</>
|
|
75
|
+
)}
|
|
76
|
+
{source && (
|
|
77
|
+
<>
|
|
78
|
+
<VerticalSpace size="12" />
|
|
79
|
+
<Text size="xs">
|
|
80
|
+
<span className={styles.mutedText}>{source}</span>
|
|
81
|
+
</Text>
|
|
82
|
+
</>
|
|
83
|
+
)}
|
|
84
|
+
{sourceUrl && (
|
|
77
85
|
<Text size="xs">
|
|
78
|
-
<
|
|
86
|
+
<a className={styles.mutedText} href={sourceUrl}>
|
|
87
|
+
{sourceUrl}
|
|
88
|
+
</a>
|
|
79
89
|
</Text>
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
{sourceUrl && (
|
|
83
|
-
<Text size="xs">
|
|
84
|
-
<a className={styles.mutedText} href={sourceUrl}>
|
|
85
|
-
{sourceUrl}
|
|
86
|
-
</a>
|
|
87
|
-
</Text>
|
|
88
|
-
)}
|
|
90
|
+
)}
|
|
91
|
+
</Align>
|
|
89
92
|
</ColumnsCol>
|
|
90
93
|
</Columns>
|
|
91
94
|
</li>
|
|
@@ -8,13 +8,14 @@ import { Box } from "@arc-ui/components/Box";
|
|
|
8
8
|
import { Rule } from "@arc-ui/components/Rule";
|
|
9
9
|
import { VerticalSpace } from "@arc-ui/components/VerticalSpace";
|
|
10
10
|
import { useMediaQuery } from "@arc-ui/components/use-media-query";
|
|
11
|
-
|
|
11
|
+
import { filterAttrs } from "@arc-ui/community-utils/filter-attrs";
|
|
12
12
|
import styles from "./Summary.module.css";
|
|
13
13
|
|
|
14
14
|
export const Summary: React.FC<SummaryProps> = ({
|
|
15
15
|
content,
|
|
16
16
|
noBorder = false,
|
|
17
17
|
headingLevel = "3",
|
|
18
|
+
...props
|
|
18
19
|
}) => {
|
|
19
20
|
const isMinWidthArcBreakpointM = useMediaQuery(
|
|
20
21
|
`(min-width: ${ArcSizeBreakpointsM})`,
|
|
@@ -25,6 +26,7 @@ export const Summary: React.FC<SummaryProps> = ({
|
|
|
25
26
|
isBorderRadius
|
|
26
27
|
{...(!noBorder ? { borderWidth: "thin" } : { elevationLevel: "1" })}
|
|
27
28
|
padding="24"
|
|
29
|
+
{...filterAttrs(props)}
|
|
28
30
|
>
|
|
29
31
|
<div className={styles.row}>
|
|
30
32
|
{content.map(({ heading, text }, i) => (
|