@arc-ui/community-components 3.0.1 → 3.2.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 +19 -22
- package/CHANGELOG.md +30 -0
- package/lib/Accordion/Accordion.cjs +2 -2
- package/lib/Accordion/Accordion.mjs +2 -2
- package/lib/ActionTile/ActionTile.cjs +35 -0
- package/lib/ActionTile/ActionTile.mjs +33 -0
- package/lib/ActionTile/styles.css +1 -0
- package/lib/ArticleSidebar/ArticleSidebar.cjs +68 -58
- package/lib/ArticleSidebar/ArticleSidebar.mjs +68 -58
- package/lib/ArticleSidebar/styles.css +1 -1
- package/lib/Author/Author.cjs +2 -2
- package/lib/Author/Author.mjs +2 -2
- package/lib/BannerWithTabs/BannerWithTabs.cjs +5 -5
- package/lib/BannerWithTabs/BannerWithTabs.mjs +5 -5
- package/lib/CopyLead/CopyLead.cjs +12 -12
- package/lib/CopyLead/CopyLead.mjs +12 -12
- package/lib/DownloadList/DownloadList.cjs +5 -5
- package/lib/DownloadList/DownloadList.mjs +5 -5
- package/lib/FAQs/FAQs.cjs +16 -12
- package/lib/FAQs/FAQs.mjs +16 -12
- package/lib/FeaturePost/FeaturePost.cjs +18 -11
- package/lib/FeaturePost/FeaturePost.mjs +18 -11
- package/lib/HeroLink/HeroLink.cjs +35 -0
- package/lib/HeroLink/HeroLink.mjs +33 -0
- package/lib/HeroLink/styles.css +1 -0
- package/lib/Highlights/Highlights.cjs +9 -16
- package/lib/Highlights/Highlights.mjs +7 -14
- package/lib/LinkTile/LinkTile.cjs +21 -0
- package/lib/LinkTile/LinkTile.mjs +19 -0
- package/lib/LinkTile/styles.css +1 -0
- package/lib/ProductNavigation/ProductNavigation.cjs +10 -13
- package/lib/ProductNavigation/ProductNavigation.mjs +10 -13
- package/lib/PromoListing/PromoListing.cjs +17 -9
- package/lib/PromoListing/PromoListing.mjs +17 -9
- package/lib/PromoListingThumbnailSignpost/PromoListingThumbnailSignpost.cjs +28 -0
- package/lib/PromoListingThumbnailSignpost/PromoListingThumbnailSignpost.mjs +26 -0
- package/lib/PromoListingThumbnailSignpost/styles.css +1 -0
- package/lib/Quote/Quote.cjs +3 -3
- package/lib/Quote/Quote.mjs +3 -3
- package/lib/SectionHeading/SectionHeading.cjs +3 -3
- package/lib/SectionHeading/SectionHeading.mjs +3 -3
- package/lib/Statistics/Statistics.cjs +6 -6
- package/lib/Statistics/Statistics.mjs +6 -6
- package/lib/Summary/Summary.cjs +1 -1
- package/lib/Summary/Summary.mjs +1 -1
- package/lib/ThumbnailSignpost/ThumbnailSignpost.cjs +15 -0
- package/lib/ThumbnailSignpost/ThumbnailSignpost.mjs +9 -0
- package/lib/ThumbnailSignpost/styles.css +1 -0
- package/lib/_shared/cjs/{Accordion-D5fpUJzm.cjs → Accordion-DfNGOjTm.cjs} +5 -5
- package/lib/_shared/cjs/{Author-X47pv31V.cjs → Author-D4dKNQem.cjs} +2 -2
- package/lib/_shared/cjs/BtIconArrowAltRight-CLQdP61r.cjs +11 -0
- package/lib/_shared/cjs/BtIconArrowRightFill-BVCZv7Lm.cjs +11 -0
- package/lib/_shared/cjs/{SectionHeading-DepTV4JA.cjs → SectionHeading-DeSFM0HV.cjs} +5 -5
- package/lib/_shared/cjs/ThumbnailSignpost-GkOiwt-Z.cjs +39 -0
- package/lib/_shared/cjs/filter-attrs-BizjMsy0.cjs +27 -0
- package/lib/_shared/cjs/{index.es-D11PdokQ.cjs → index.es-Dq8bYrbW.cjs} +1 -1
- package/lib/_shared/esm/{Accordion-LLwNdzax.mjs → Accordion-cd1oYvBv.mjs} +5 -5
- package/lib/_shared/esm/{Author-CydDYCma.mjs → Author-HnYsFTPT.mjs} +2 -2
- package/lib/_shared/esm/BtIconArrowAltRight-VH6RTTnL.mjs +9 -0
- package/lib/_shared/esm/BtIconArrowRightFill-D0zKgk3B.mjs +9 -0
- package/lib/_shared/esm/{SectionHeading-BayinGP_.mjs → SectionHeading-CpDLCndw.mjs} +5 -5
- package/lib/_shared/esm/ThumbnailSignpost-BeRiXbUp.mjs +37 -0
- package/lib/_shared/esm/filter-attrs-DZ7RCEZm.mjs +25 -0
- package/lib/_shared/esm/{index.es-C4PyYMjI.mjs → index.es-Bfdys5__.mjs} +1 -1
- package/lib/index.cjs +378 -227
- package/lib/index.cjs.map +1 -1
- package/lib/index.d.cts +190 -26
- package/lib/index.d.mts +190 -26
- package/lib/index.mjs +374 -228
- package/lib/index.mjs.map +1 -1
- package/lib/styles.css +1 -1
- package/package.json +13 -13
- package/src/components/Accordion/Accordion.tsx +3 -2
- package/src/components/Accordion/components/AccordionDisclosureList/AccordionDisclosureList.tsx +3 -3
- package/src/components/Accordion/components/AccordionHeading/AccordionHeading.tsx +3 -4
- package/src/components/ActionTile/ActionTile.module.css +89 -0
- package/src/components/ActionTile/ActionTile.tsx +70 -0
- package/src/components/ActionTile/index.ts +1 -0
- package/src/components/ArticleSidebar/ArticleSidebar.module.css +6 -0
- package/src/components/ArticleSidebar/ArticleSidebar.tsx +115 -85
- package/src/components/ArticleSidebar/types/link-section.ts +2 -1
- package/src/components/ArticleSidebar/types/share-button.ts +1 -1
- package/src/components/ArticleSidebar/types/share.ts +5 -1
- package/src/components/ArticleSidebar/types/text-section.ts +3 -2
- package/src/components/ArticleSidebar/types/topic.ts +2 -2
- package/src/components/Author/Author.tsx +2 -2
- package/src/components/BannerWithTabs/BannerWithTabs.tsx +9 -3
- package/src/components/CopyLead/CopyLead.tsx +21 -5
- package/src/components/CopyLead/components/MediaContent/MediaContent.tsx +10 -1
- package/src/components/CopyLead/templates/Content/Content.tsx +4 -0
- package/src/components/CopyLead/templates/Media/Media.tsx +10 -1
- package/src/components/CopyLead/types/copy-lead-button.ts +1 -1
- package/src/components/CopyLead/types/copy-lead-image.ts +1 -1
- package/src/components/DownloadList/DownloadList.tsx +4 -0
- package/src/components/FAQs/FAQs.tsx +20 -9
- package/src/components/FeaturePost/FeaturePost.tsx +27 -6
- package/src/components/FeaturePost/components/Image/Image.tsx +31 -7
- package/src/components/FeaturePost/types/feature-post-app-button-footer.ts +1 -1
- package/src/components/FeaturePost/types/feature-post-cta-footer.ts +2 -1
- package/src/components/FeaturePost/types/feature-post-image.ts +3 -1
- package/src/components/HeroLink/HeroLink.module.css +44 -0
- package/src/components/HeroLink/HeroLink.tsx +136 -0
- package/src/components/HeroLink/index.ts +2 -0
- package/src/components/Highlights/Highlights.tsx +6 -1
- package/src/components/Highlights/components/HighlightItem/HighlightItem.tsx +1 -0
- package/src/components/Highlights/types/highlight-link.ts +1 -0
- package/src/components/LinkTile/LinkTile.module.css +57 -0
- package/src/components/LinkTile/LinkTile.tsx +38 -0
- package/src/components/LinkTile/index.ts +1 -0
- package/src/components/ProductNavigation/ProductNavigation.tsx +10 -11
- package/src/components/ProductNavigation/types/product-list.ts +1 -8
- package/src/components/PromoListing/PromoListing.tsx +67 -3
- 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 +2 -2
- package/src/components/SectionHeading/SectionHeading.tsx +17 -7
- package/src/components/Statistics/Statistics.tsx +6 -2
- 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 +5 -0
- package/versions.json +1 -1
- package/lib/_shared/cjs/filter-data-attrs-ajtUvDAC.cjs +0 -15
- package/lib/_shared/esm/filter-data-attrs-V7cbJuwS.mjs +0 -13
|
@@ -8,9 +8,9 @@ var Text = require('@arc-ui/components/Text');
|
|
|
8
8
|
var Align = require('@arc-ui/components/Align');
|
|
9
9
|
var Heading = require('@arc-ui/components/Heading');
|
|
10
10
|
var VerticalSpace = require('@arc-ui/components/VerticalSpace');
|
|
11
|
-
var SectionHeading = require('../_shared/cjs/SectionHeading-
|
|
11
|
+
var SectionHeading = require('../_shared/cjs/SectionHeading-DeSFM0HV.cjs');
|
|
12
12
|
require('../_shared/cjs/index-Bp6Dd2i1.cjs');
|
|
13
|
-
require('../_shared/cjs/filter-
|
|
13
|
+
require('../_shared/cjs/filter-attrs-BizjMsy0.cjs');
|
|
14
14
|
require('@arc-ui/components/Image');
|
|
15
15
|
|
|
16
16
|
var styles = {"list":"Statistics-module_list__BI-eQ","mutedText":"Statistics-module_mutedText__MR1JM","statWrapper":"Statistics-module_statWrapper__83OnM"};
|
|
@@ -25,16 +25,16 @@ var getLinkProps = function (link) {
|
|
|
25
25
|
};
|
|
26
26
|
|
|
27
27
|
var Statistics = function (_a) {
|
|
28
|
-
var headingLevel = _a.headingLevel, heading = _a.heading, content = _a.content, statistics = _a.statistics;
|
|
29
|
-
var
|
|
28
|
+
var id = _a.id, isHeadingWordWrap = _a.isHeadingWordWrap, headingLevel = _a.headingLevel, heading = _a.heading, content = _a.content, statistics = _a.statistics;
|
|
29
|
+
var componentId = React.useId();
|
|
30
30
|
return (React.createElement(Columns.Columns, null,
|
|
31
31
|
React.createElement(Columns.ColumnsCol, { spanM: 9 },
|
|
32
|
-
React.createElement(SectionHeading.SectionHeading, { heading: heading, headingLevel: headingLevel, content: content }),
|
|
32
|
+
React.createElement(SectionHeading.SectionHeading, { id: id, heading: heading, isHeadingWordWrap: isHeadingWordWrap, headingLevel: headingLevel, content: content }),
|
|
33
33
|
React.createElement(VerticalSpace.VerticalSpace, { size: "16" })),
|
|
34
34
|
React.createElement(Columns.ColumnsCol, { spanL: 9 },
|
|
35
35
|
React.createElement("ul", { className: styles.list }, statistics.map(function (_a, i) {
|
|
36
36
|
var stat = _a.stat, copy = _a.copy, link = _a.link, source = _a.source, sourceUrl = _a.sourceUrl;
|
|
37
|
-
return (React.createElement("li", { key: "statistic-".concat(
|
|
37
|
+
return (React.createElement("li", { key: "statistic-".concat(componentId, "-").concat(i) },
|
|
38
38
|
i !== 0 && (React.createElement(React.Fragment, null,
|
|
39
39
|
React.createElement(VerticalSpace.VerticalSpace, { size: "24", sizeS: "32", sizeXL: "40" }),
|
|
40
40
|
React.createElement(Rule.Rule, null),
|
|
@@ -6,9 +6,9 @@ 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
|
-
import { S as SectionHeading } from '../_shared/esm/SectionHeading-
|
|
9
|
+
import { S as SectionHeading } from '../_shared/esm/SectionHeading-CpDLCndw.mjs';
|
|
10
10
|
import '../_shared/esm/index-BfTCfPZ1.mjs';
|
|
11
|
-
import '../_shared/esm/filter-
|
|
11
|
+
import '../_shared/esm/filter-attrs-DZ7RCEZm.mjs';
|
|
12
12
|
import '@arc-ui/components/Image';
|
|
13
13
|
|
|
14
14
|
var styles = {"list":"Statistics-module_list__BI-eQ","mutedText":"Statistics-module_mutedText__MR1JM","statWrapper":"Statistics-module_statWrapper__83OnM"};
|
|
@@ -23,16 +23,16 @@ var getLinkProps = function (link) {
|
|
|
23
23
|
};
|
|
24
24
|
|
|
25
25
|
var Statistics = function (_a) {
|
|
26
|
-
var headingLevel = _a.headingLevel, heading = _a.heading, content = _a.content, statistics = _a.statistics;
|
|
27
|
-
var
|
|
26
|
+
var id = _a.id, isHeadingWordWrap = _a.isHeadingWordWrap, headingLevel = _a.headingLevel, heading = _a.heading, content = _a.content, statistics = _a.statistics;
|
|
27
|
+
var componentId = useId();
|
|
28
28
|
return (React.createElement(Columns, null,
|
|
29
29
|
React.createElement(ColumnsCol, { spanM: 9 },
|
|
30
|
-
React.createElement(SectionHeading, { heading: heading, headingLevel: headingLevel, content: content }),
|
|
30
|
+
React.createElement(SectionHeading, { id: id, heading: heading, isHeadingWordWrap: isHeadingWordWrap, headingLevel: headingLevel, content: content }),
|
|
31
31
|
React.createElement(VerticalSpace, { size: "16" })),
|
|
32
32
|
React.createElement(ColumnsCol, { spanL: 9 },
|
|
33
33
|
React.createElement("ul", { className: styles.list }, statistics.map(function (_a, i) {
|
|
34
34
|
var stat = _a.stat, copy = _a.copy, link = _a.link, source = _a.source, sourceUrl = _a.sourceUrl;
|
|
35
|
-
return (React.createElement("li", { key: "statistic-".concat(
|
|
35
|
+
return (React.createElement("li", { key: "statistic-".concat(componentId, "-").concat(i) },
|
|
36
36
|
i !== 0 && (React.createElement(React.Fragment, null,
|
|
37
37
|
React.createElement(VerticalSpace, { size: "24", sizeS: "32", sizeXL: "40" }),
|
|
38
38
|
React.createElement(Rule, null),
|
package/lib/Summary/Summary.cjs
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
var tslib_es6 = require('../_shared/cjs/tslib.es6-BxB9I209.cjs');
|
|
4
4
|
var React = require('react');
|
|
5
|
-
var index_es = require('../_shared/cjs/index.es-
|
|
5
|
+
var index_es = require('../_shared/cjs/index.es-Dq8bYrbW.cjs');
|
|
6
6
|
var Heading = require('@arc-ui/components/Heading');
|
|
7
7
|
var Text = require('@arc-ui/components/Text');
|
|
8
8
|
var Box = require('@arc-ui/components/Box');
|
package/lib/Summary/Summary.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { _ as __assign } from '../_shared/esm/tslib.es6-D6Wu-xwB.mjs';
|
|
2
2
|
import React from 'react';
|
|
3
|
-
import { b as ArcSizeBreakpointsM } from '../_shared/esm/index.es-
|
|
3
|
+
import { b as ArcSizeBreakpointsM } from '../_shared/esm/index.es-Bfdys5__.mjs';
|
|
4
4
|
import { Heading } from '@arc-ui/components/Heading';
|
|
5
5
|
import { Text } from '@arc-ui/components/Text';
|
|
6
6
|
import { Box } from '@arc-ui/components/Box';
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var ThumbnailSignpost = require('../_shared/cjs/ThumbnailSignpost-GkOiwt-Z.cjs');
|
|
4
|
+
require('../_shared/cjs/tslib.es6-BxB9I209.cjs');
|
|
5
|
+
require('react');
|
|
6
|
+
require('../_shared/cjs/index-Bp6Dd2i1.cjs');
|
|
7
|
+
require('../_shared/cjs/filter-attrs-BizjMsy0.cjs');
|
|
8
|
+
require('../_shared/cjs/BtIconArrowRightFill-BVCZv7Lm.cjs');
|
|
9
|
+
require('@arc-ui/components/Image');
|
|
10
|
+
require('@arc-ui/components/VerticalSpace');
|
|
11
|
+
require('@arc-ui/components/Heading');
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
exports.ThumbnailSignpost = ThumbnailSignpost.ThumbnailSignpost;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export { T as ThumbnailSignpost } from '../_shared/esm/ThumbnailSignpost-BeRiXbUp.mjs';
|
|
2
|
+
import '../_shared/esm/tslib.es6-D6Wu-xwB.mjs';
|
|
3
|
+
import 'react';
|
|
4
|
+
import '../_shared/esm/index-BfTCfPZ1.mjs';
|
|
5
|
+
import '../_shared/esm/filter-attrs-DZ7RCEZm.mjs';
|
|
6
|
+
import '../_shared/esm/BtIconArrowRightFill-D0zKgk3B.mjs';
|
|
7
|
+
import '@arc-ui/components/Image';
|
|
8
|
+
import '@arc-ui/components/VerticalSpace';
|
|
9
|
+
import '@arc-ui/components/Heading';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.ThumbnailSignpost-module_thumbnailSignpost__Yf26b button{all:unset;cursor:pointer}.ThumbnailSignpost-module_thumbnailSignpost__Yf26b{display:inline-flex;flex-direction:row;gap:var(--arc-size-grid-gutter-s);max-width:720px}.ThumbnailSignpost-module_isLink__FucdG:focus{cursor:pointer;outline:var(--focus-border-weight-s) solid var(--focus-colors-light-border-subtle);outline-offset:2px;border-radius:calc(var(--thumbnail-signpost-border-radius-s) + 2px)}.ThumbnailSignpost-module_isLink__FucdG:hover{cursor:pointer}.ThumbnailSignpost-module_content__XG9oj{width:100%;font:var(--sem-type-body-reg-s)}.ThumbnailSignpost-module_heading__mTrpJ{display:block;font:var(--sem-type-mobile-semi-xxs);font-family:var(--sem-font-family-heading);font-size:1em;font-weight:var(--sem-font-weight-semi-bold);margin:0}.ThumbnailSignpost-module_isLink__FucdG:hover .ThumbnailSignpost-module_heading__mTrpJ,.ThumbnailSignpost-module_isLink__FucdG:focus .ThumbnailSignpost-module_heading__mTrpJ{color:var(--button-v2-colors-light-text-hover);text-decoration:underline}.ThumbnailSignpost-module_image__syGZj{width:calc((((100% + var(--arc-size-grid-gutter-s))/12) * 6) - var(--arc-size-grid-gutter-s))}.ThumbnailSignpost-module_image__syGZj img{border-radius:var(--thumbnail-signpost-border-radius-s);width:100%}@media (min-width:636px){.ThumbnailSignpost-module_image__syGZj{width:calc((((100% + var(--arc-size-grid-gutter-s))/12) * 6) - var(--arc-size-grid-gutter-m))}.ThumbnailSignpost-module_thumbnailSignpost__Yf26b{gap:var(--arc-size-grid-gutter-m)}.ThumbnailSignpost-module_heading__mTrpJ{font:var(--sem-type-mobile-semi-xs)}}@media (min-width:1280px){.ThumbnailSignpost-module_thumbnailSignpost__Yf26b{gap:var(--arc-size-grid-gutter-l)}}.ThumbnailSignpost-module_thumbnailButton__Nn-NR{display:flex;align-items:center;gap:var(--button-v2-gap-xs);color:var(--button-v2-colors-light-text-default);font:var(--sem-type-interface-button-s);height:var(--button-v2-size-s)}.ThumbnailSignpost-module_buttonIcon__ydmza{background:var(--icon-color-brand-alt-light);display:block;height:100%;line-height:0;-webkit-mask-position:center;mask-position:center;-webkit-mask-size:contain;mask-size:contain;width:100%}.ThumbnailSignpost-module_isLink__FucdG:focus .ThumbnailSignpost-module_buttonIcon__ydmza,.ThumbnailSignpost-module_isLink__FucdG:hover .ThumbnailSignpost-module_buttonIcon__ydmza{background:var(--button-v2-colors-light-text-hover)}.ThumbnailSignpost-module_isLink__FucdG:hover .ThumbnailSignpost-module_thumbnailButton__Nn-NR,.ThumbnailSignpost-module_isLink__FucdG:focus .ThumbnailSignpost-module_thumbnailButton__Nn-NR{background:none;color:var(--button-v2-colors-light-text-hover);-webkit-text-decoration:var(--sem-underline);text-decoration:var(--sem-underline)}
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
var tslib_es6 = require('./tslib.es6-BxB9I209.cjs');
|
|
4
4
|
var React = require('react');
|
|
5
|
-
var
|
|
5
|
+
var filterAttrs = require('./filter-attrs-BizjMsy0.cjs');
|
|
6
6
|
var index = require('./index-Bp6Dd2i1.cjs');
|
|
7
7
|
var Heading = require('@arc-ui/components/Heading');
|
|
8
8
|
var Text = require('@arc-ui/components/Text');
|
|
@@ -19,7 +19,7 @@ var AccordionHeading = function (_a) {
|
|
|
19
19
|
_b[styles$2["accordion-header"]] = true,
|
|
20
20
|
_b[styles$2["accordion-header--padded"]] = isPadded,
|
|
21
21
|
_b[styles$2["accordion-header--headingSizeM"]] = headingSize === "m",
|
|
22
|
-
_b)) },
|
|
22
|
+
_b)) }, filterAttrs.filterAttrs(props)),
|
|
23
23
|
React.createElement("div", { className: index.classNames((_c = {}, _c[styles$2["accordion-header--hasImage"]] = image, _c)) },
|
|
24
24
|
image && (React.createElement("div", null,
|
|
25
25
|
React.createElement(Image.Image, tslib_es6.__assign({}, image, { width: 68, fit: "cover" })))),
|
|
@@ -35,8 +35,8 @@ var AccordionDisclosureList = function (_a) {
|
|
|
35
35
|
var disclosureList = _a.disclosureList;
|
|
36
36
|
return (React.createElement("ul", null, disclosureList.map(function (_a) {
|
|
37
37
|
var children = _a.children, summary = _a.summary, _b = _a.isOpen, isOpen = _b === void 0 ? false : _b, _c = _a.indentDetails, indentDetails = _c === void 0 ? false : _c, headingLevel = _a.headingLevel, id = _a.id, props = tslib_es6.__rest(_a, ["children", "summary", "isOpen", "indentDetails", "headingLevel", "id"]);
|
|
38
|
-
return (React.createElement("li", { key: id, className: styles$1.AccordionDisclosureListItem },
|
|
39
|
-
React.createElement(Disclosure.Disclosure, tslib_es6.__assign({ summary: summary, isOpen: isOpen, indentDetails: indentDetails, headingLevel: headingLevel },
|
|
38
|
+
return (React.createElement("li", { key: id, className: styles$1.AccordionDisclosureListItem, id: id },
|
|
39
|
+
React.createElement(Disclosure.Disclosure, tslib_es6.__assign({ summary: summary, isOpen: isOpen, indentDetails: indentDetails, headingLevel: headingLevel }, filterAttrs.filterAttrs(props)), children)));
|
|
40
40
|
})));
|
|
41
41
|
};
|
|
42
42
|
|
|
@@ -47,7 +47,7 @@ var styles = {"Accordion":"Accordion-module_Accordion__LsXTU"};
|
|
|
47
47
|
*/
|
|
48
48
|
var Accordion = function (_a) {
|
|
49
49
|
var heading = _a.heading, headingLevel = _a.headingLevel, headingSize = _a.headingSize, content = _a.content, id = _a.id, disclosureList = _a.disclosureList, props = tslib_es6.__rest(_a, ["heading", "headingLevel", "headingSize", "content", "id", "disclosureList"]);
|
|
50
|
-
return (React.createElement("div", tslib_es6.__assign({ className: styles.Accordion },
|
|
50
|
+
return (React.createElement("div", tslib_es6.__assign({ className: styles.Accordion }, filterAttrs.filterAttrs(props)),
|
|
51
51
|
React.createElement(AccordionHeading, { isPadded: true, id: id, "data-testid": "Accordion-header", heading: heading, headingLevel: headingLevel, headingSize: headingSize, content: content }),
|
|
52
52
|
React.createElement(AccordionDisclosureList, { disclosureList: disclosureList })));
|
|
53
53
|
};
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
var tslib_es6 = require('./tslib.es6-BxB9I209.cjs');
|
|
4
4
|
var React = require('react');
|
|
5
|
-
var
|
|
5
|
+
var filterAttrs = require('./filter-attrs-BizjMsy0.cjs');
|
|
6
6
|
var Grid = require('@arc-ui/components/Grid');
|
|
7
7
|
var Avatar = require('@arc-ui/components/Avatar');
|
|
8
8
|
var Heading = require('@arc-ui/components/Heading');
|
|
@@ -15,7 +15,7 @@ var Author = function (_a) {
|
|
|
15
15
|
var avatarSizes = ["s", "m", "l", "xl"];
|
|
16
16
|
avatar.size = avatarSizes.includes(avatar.size || "") ? avatar.size : "m";
|
|
17
17
|
var isLargeAvatar = avatar.size === "l" || avatar.size === "xl";
|
|
18
|
-
return (React.createElement("div", tslib_es6.__assign({},
|
|
18
|
+
return (React.createElement("div", tslib_es6.__assign({}, filterAttrs.filterAttrs(props)),
|
|
19
19
|
React.createElement(Grid.Grid, { isFluid: true, isGutterless: true },
|
|
20
20
|
React.createElement(Grid.GridRow, { align: "center" },
|
|
21
21
|
React.createElement(Grid.GridCol, { xs: isLargeAvatar ? 12 : "auto" },
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Do not edit directly
|
|
5
|
+
* Generated file
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
const BtIconArrowAltRight =
|
|
9
|
+
"data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3e%3cpath fill='currentColor' d='M18.854 11.646a.5.5 0 0 0-.707.707l3.146 3.147H9.5a.5.5 0 0 0 0 1h11.793l-3.146 3.146a.5.5 0 1 0 .707.707L23.207 16Z'/%3e%3c/svg%3e";
|
|
10
|
+
|
|
11
|
+
exports.BtIconArrowAltRight = BtIconArrowAltRight;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Do not edit directly
|
|
5
|
+
* Generated file
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
const BtIconArrowRightFill =
|
|
9
|
+
"data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3e%3cpath fill='currentColor' d='M2 16A14 14 0 1 0 16 2 14 14 0 0 0 2 16m16.854-4.354L23.207 16l-4.354 4.354a.5.5 0 0 1-.707-.707l3.147-3.147H9.5a.5.5 0 0 1 0-1h11.793l-3.146-3.146a.5.5 0 0 1 .707-.707'/%3e%3c/svg%3e";
|
|
10
|
+
|
|
11
|
+
exports.BtIconArrowRightFill = BtIconArrowRightFill;
|
|
@@ -3,25 +3,25 @@
|
|
|
3
3
|
var tslib_es6 = require('./tslib.es6-BxB9I209.cjs');
|
|
4
4
|
var React = require('react');
|
|
5
5
|
var index = require('./index-Bp6Dd2i1.cjs');
|
|
6
|
-
var
|
|
7
|
-
var Heading = require('@arc-ui/components/Heading');
|
|
6
|
+
var filterAttrs = require('./filter-attrs-BizjMsy0.cjs');
|
|
8
7
|
var Text = require('@arc-ui/components/Text');
|
|
9
8
|
var VerticalSpace = require('@arc-ui/components/VerticalSpace');
|
|
10
9
|
var Image = require('@arc-ui/components/Image');
|
|
10
|
+
var Heading = require('@arc-ui/components/Heading');
|
|
11
11
|
|
|
12
12
|
var styles = {"section-header":"SectionHeading-module_section-header__iB07I","section-header--hasImage":"SectionHeading-module_section-header--hasImage__Ka3T7","section-header--padded":"SectionHeading-module_section-header--padded__0FXP2"};
|
|
13
13
|
|
|
14
14
|
var SectionHeading = function (_a) {
|
|
15
15
|
var _b, _c;
|
|
16
|
-
var heading = _a.heading, content = _a.content, id = _a.id, _d = _a.isPadded, isPadded = _d === void 0 ? false : _d, _e = _a.headingLevel, headingLevel = _e === void 0 ? "2" : _e,
|
|
16
|
+
var heading = _a.heading, content = _a.content, id = _a.id, image = _a.image, isHeadingWordWrap = _a.isHeadingWordWrap, _d = _a.isPadded, isPadded = _d === void 0 ? false : _d, _e = _a.headingLevel, headingLevel = _e === void 0 ? "2" : _e, props = tslib_es6.__rest(_a, ["heading", "content", "id", "image", "isHeadingWordWrap", "isPadded", "headingLevel"]);
|
|
17
17
|
return (React.createElement("div", tslib_es6.__assign({ className: index.classNames((_b = {},
|
|
18
18
|
_b[styles["section-header"]] = true,
|
|
19
19
|
_b[styles["section-header--padded"]] = isPadded,
|
|
20
|
-
_b)) },
|
|
20
|
+
_b)) }, filterAttrs.filterAttrs(props)),
|
|
21
21
|
React.createElement("div", { className: index.classNames((_c = {}, _c[styles["section-header--hasImage"]] = image, _c)) },
|
|
22
22
|
image && (React.createElement("div", null,
|
|
23
23
|
React.createElement(Image.Image, tslib_es6.__assign({}, image, { width: 68, fit: "cover" })))),
|
|
24
|
-
React.createElement(Heading.Heading, { level: headingLevel, id: id, size: "xl" }, heading)),
|
|
24
|
+
React.createElement(Heading.Heading, { level: headingLevel, id: id, size: "xl", isWordWrap: isHeadingWordWrap }, heading)),
|
|
25
25
|
content && (React.createElement(React.Fragment, null,
|
|
26
26
|
React.createElement(VerticalSpace.VerticalSpace, { size: "24" }),
|
|
27
27
|
React.createElement(Text.Text, { size: "l", elementType: "p" }, content)))));
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var tslib_es6 = require('./tslib.es6-BxB9I209.cjs');
|
|
4
|
+
var React = require('react');
|
|
5
|
+
var index = require('./index-Bp6Dd2i1.cjs');
|
|
6
|
+
var filterAttrs = require('./filter-attrs-BizjMsy0.cjs');
|
|
7
|
+
var BtIconArrowRightFill = require('./BtIconArrowRightFill-BVCZv7Lm.cjs');
|
|
8
|
+
var Image = require('@arc-ui/components/Image');
|
|
9
|
+
var VerticalSpace = require('@arc-ui/components/VerticalSpace');
|
|
10
|
+
var Heading = require('@arc-ui/components/Heading');
|
|
11
|
+
|
|
12
|
+
var styles = {"thumbnailSignpost":"ThumbnailSignpost-module_thumbnailSignpost__Yf26b","isLink":"ThumbnailSignpost-module_isLink__FucdG","content":"ThumbnailSignpost-module_content__XG9oj","heading":"ThumbnailSignpost-module_heading__mTrpJ","image":"ThumbnailSignpost-module_image__syGZj","thumbnailButton":"ThumbnailSignpost-module_thumbnailButton__Nn-NR","buttonIcon":"ThumbnailSignpost-module_buttonIcon__ydmza"};
|
|
13
|
+
|
|
14
|
+
/** Use `ThumbnailSignpost` to highlight key information or navigation points with an accompanying thumbnail image or icon. */
|
|
15
|
+
var ThumbnailSignpost = function (_a) {
|
|
16
|
+
var _b;
|
|
17
|
+
var text = _a.text, title = _a.title, img = _a.img, onClick = _a.onClick, buttonLabel = _a.buttonLabel, props = tslib_es6.__rest(_a, ["text", "title", "img", "onClick", "buttonLabel"]);
|
|
18
|
+
return (React.createElement("div", tslib_es6.__assign({ className: index.classNames(styles.thumbnailSignpost, (_b = {},
|
|
19
|
+
_b[styles.isLink] = onClick,
|
|
20
|
+
_b)), onClick: onClick, "aria-label": title, tabIndex: onClick ? 0 : -1 }, (onClick && { role: "button" }), filterAttrs.filterAttrs(props)),
|
|
21
|
+
img && (React.createElement("div", { className: styles.image },
|
|
22
|
+
React.createElement(Image.Image, tslib_es6.__assign({}, img)))),
|
|
23
|
+
React.createElement("div", { className: styles.content },
|
|
24
|
+
React.createElement("span", { className: styles.heading }, title),
|
|
25
|
+
React.createElement(VerticalSpace.VerticalSpace, { size: "8" }),
|
|
26
|
+
text,
|
|
27
|
+
buttonLabel && onClick && (React.createElement(React.Fragment, null,
|
|
28
|
+
React.createElement(VerticalSpace.VerticalSpace, { size: "8" }),
|
|
29
|
+
React.createElement("div", { className: styles.thumbnailButton },
|
|
30
|
+
React.createElement("span", { className: styles.buttonIcon, role: "img", style: {
|
|
31
|
+
height: 24,
|
|
32
|
+
width: 24,
|
|
33
|
+
maskImage: "url(\"".concat(BtIconArrowRightFill.BtIconArrowRightFill, "\")"),
|
|
34
|
+
WebkitMaskImage: "url(\"".concat(BtIconArrowRightFill.BtIconArrowRightFill, "\")"),
|
|
35
|
+
} }),
|
|
36
|
+
React.createElement(Heading.Heading, { size: "xxs" }, buttonLabel)))))));
|
|
37
|
+
};
|
|
38
|
+
|
|
39
|
+
exports.ThumbnailSignpost = ThumbnailSignpost;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Filters out attributes from the given props object based on a pattern.
|
|
5
|
+
*
|
|
6
|
+
* This function extracts all properties that match either the `data-*` or `aria-*` attribute patterns
|
|
7
|
+
* and returns a new object containing only those properties.
|
|
8
|
+
*
|
|
9
|
+
* @param props - The object containing properties to filter.
|
|
10
|
+
* @returns A new object containing only the matched attributes (`data-*` and `aria-*`) from the input props.
|
|
11
|
+
*/
|
|
12
|
+
var attributePrefixes = ["data-", "aria-"];
|
|
13
|
+
var filterAttrs = function (props) {
|
|
14
|
+
var filteredProps = {};
|
|
15
|
+
var _loop_1 = function (prop) {
|
|
16
|
+
if (Object.prototype.hasOwnProperty.call(props, prop) &&
|
|
17
|
+
attributePrefixes.some(function (prefix) { return prop.startsWith(prefix); })) {
|
|
18
|
+
filteredProps[prop] = props[prop];
|
|
19
|
+
}
|
|
20
|
+
};
|
|
21
|
+
for (var prop in props) {
|
|
22
|
+
_loop_1(prop);
|
|
23
|
+
}
|
|
24
|
+
return filteredProps;
|
|
25
|
+
};
|
|
26
|
+
|
|
27
|
+
exports.filterAttrs = filterAttrs;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { a as __rest, _ as __assign } from './tslib.es6-D6Wu-xwB.mjs';
|
|
2
2
|
import React from 'react';
|
|
3
|
-
import { f as
|
|
3
|
+
import { f as filterAttrs } from './filter-attrs-DZ7RCEZm.mjs';
|
|
4
4
|
import { c as classNames } from './index-BfTCfPZ1.mjs';
|
|
5
5
|
import { Heading } from '@arc-ui/components/Heading';
|
|
6
6
|
import { Text } from '@arc-ui/components/Text';
|
|
@@ -17,7 +17,7 @@ var AccordionHeading = function (_a) {
|
|
|
17
17
|
_b[styles$2["accordion-header"]] = true,
|
|
18
18
|
_b[styles$2["accordion-header--padded"]] = isPadded,
|
|
19
19
|
_b[styles$2["accordion-header--headingSizeM"]] = headingSize === "m",
|
|
20
|
-
_b)) },
|
|
20
|
+
_b)) }, filterAttrs(props)),
|
|
21
21
|
React.createElement("div", { className: classNames((_c = {}, _c[styles$2["accordion-header--hasImage"]] = image, _c)) },
|
|
22
22
|
image && (React.createElement("div", null,
|
|
23
23
|
React.createElement(Image, __assign({}, image, { width: 68, fit: "cover" })))),
|
|
@@ -33,8 +33,8 @@ var AccordionDisclosureList = function (_a) {
|
|
|
33
33
|
var disclosureList = _a.disclosureList;
|
|
34
34
|
return (React.createElement("ul", null, disclosureList.map(function (_a) {
|
|
35
35
|
var children = _a.children, summary = _a.summary, _b = _a.isOpen, isOpen = _b === void 0 ? false : _b, _c = _a.indentDetails, indentDetails = _c === void 0 ? false : _c, headingLevel = _a.headingLevel, id = _a.id, props = __rest(_a, ["children", "summary", "isOpen", "indentDetails", "headingLevel", "id"]);
|
|
36
|
-
return (React.createElement("li", { key: id, className: styles$1.AccordionDisclosureListItem },
|
|
37
|
-
React.createElement(Disclosure, __assign({ summary: summary, isOpen: isOpen, indentDetails: indentDetails, headingLevel: headingLevel },
|
|
36
|
+
return (React.createElement("li", { key: id, className: styles$1.AccordionDisclosureListItem, id: id },
|
|
37
|
+
React.createElement(Disclosure, __assign({ summary: summary, isOpen: isOpen, indentDetails: indentDetails, headingLevel: headingLevel }, filterAttrs(props)), children)));
|
|
38
38
|
})));
|
|
39
39
|
};
|
|
40
40
|
|
|
@@ -45,7 +45,7 @@ var styles = {"Accordion":"Accordion-module_Accordion__LsXTU"};
|
|
|
45
45
|
*/
|
|
46
46
|
var Accordion = function (_a) {
|
|
47
47
|
var heading = _a.heading, headingLevel = _a.headingLevel, headingSize = _a.headingSize, content = _a.content, id = _a.id, disclosureList = _a.disclosureList, props = __rest(_a, ["heading", "headingLevel", "headingSize", "content", "id", "disclosureList"]);
|
|
48
|
-
return (React.createElement("div", __assign({ className: styles.Accordion },
|
|
48
|
+
return (React.createElement("div", __assign({ className: styles.Accordion }, filterAttrs(props)),
|
|
49
49
|
React.createElement(AccordionHeading, { isPadded: true, id: id, "data-testid": "Accordion-header", heading: heading, headingLevel: headingLevel, headingSize: headingSize, content: content }),
|
|
50
50
|
React.createElement(AccordionDisclosureList, { disclosureList: disclosureList })));
|
|
51
51
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { a as __rest, _ as __assign } from './tslib.es6-D6Wu-xwB.mjs';
|
|
2
2
|
import React from 'react';
|
|
3
|
-
import { f as
|
|
3
|
+
import { f as filterAttrs } from './filter-attrs-DZ7RCEZm.mjs';
|
|
4
4
|
import { Grid, GridRow, GridCol } from '@arc-ui/components/Grid';
|
|
5
5
|
import { Avatar } from '@arc-ui/components/Avatar';
|
|
6
6
|
import { Heading } from '@arc-ui/components/Heading';
|
|
@@ -13,7 +13,7 @@ var Author = function (_a) {
|
|
|
13
13
|
var avatarSizes = ["s", "m", "l", "xl"];
|
|
14
14
|
avatar.size = avatarSizes.includes(avatar.size || "") ? avatar.size : "m";
|
|
15
15
|
var isLargeAvatar = avatar.size === "l" || avatar.size === "xl";
|
|
16
|
-
return (React.createElement("div", __assign({},
|
|
16
|
+
return (React.createElement("div", __assign({}, filterAttrs(props)),
|
|
17
17
|
React.createElement(Grid, { isFluid: true, isGutterless: true },
|
|
18
18
|
React.createElement(GridRow, { align: "center" },
|
|
19
19
|
React.createElement(GridCol, { xs: isLargeAvatar ? 12 : "auto" },
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Do not edit directly
|
|
3
|
+
* Generated file
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
const BtIconArrowAltRight =
|
|
7
|
+
"data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3e%3cpath fill='currentColor' d='M18.854 11.646a.5.5 0 0 0-.707.707l3.146 3.147H9.5a.5.5 0 0 0 0 1h11.793l-3.146 3.146a.5.5 0 1 0 .707.707L23.207 16Z'/%3e%3c/svg%3e";
|
|
8
|
+
|
|
9
|
+
export { BtIconArrowAltRight as B };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Do not edit directly
|
|
3
|
+
* Generated file
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
const BtIconArrowRightFill =
|
|
7
|
+
"data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 32 32'%3e%3cpath fill='currentColor' d='M2 16A14 14 0 1 0 16 2 14 14 0 0 0 2 16m16.854-4.354L23.207 16l-4.354 4.354a.5.5 0 0 1-.707-.707l3.147-3.147H9.5a.5.5 0 0 1 0-1h11.793l-3.146-3.146a.5.5 0 0 1 .707-.707'/%3e%3c/svg%3e";
|
|
8
|
+
|
|
9
|
+
export { BtIconArrowRightFill as B };
|
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
import { a as __rest, _ as __assign } from './tslib.es6-D6Wu-xwB.mjs';
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { c as classNames } from './index-BfTCfPZ1.mjs';
|
|
4
|
-
import { f as
|
|
5
|
-
import { Heading } from '@arc-ui/components/Heading';
|
|
4
|
+
import { f as filterAttrs } from './filter-attrs-DZ7RCEZm.mjs';
|
|
6
5
|
import { Text } from '@arc-ui/components/Text';
|
|
7
6
|
import { VerticalSpace } from '@arc-ui/components/VerticalSpace';
|
|
8
7
|
import { Image } from '@arc-ui/components/Image';
|
|
8
|
+
import { Heading } from '@arc-ui/components/Heading';
|
|
9
9
|
|
|
10
10
|
var styles = {"section-header":"SectionHeading-module_section-header__iB07I","section-header--hasImage":"SectionHeading-module_section-header--hasImage__Ka3T7","section-header--padded":"SectionHeading-module_section-header--padded__0FXP2"};
|
|
11
11
|
|
|
12
12
|
var SectionHeading = function (_a) {
|
|
13
13
|
var _b, _c;
|
|
14
|
-
var heading = _a.heading, content = _a.content, id = _a.id, _d = _a.isPadded, isPadded = _d === void 0 ? false : _d, _e = _a.headingLevel, headingLevel = _e === void 0 ? "2" : _e,
|
|
14
|
+
var heading = _a.heading, content = _a.content, id = _a.id, image = _a.image, isHeadingWordWrap = _a.isHeadingWordWrap, _d = _a.isPadded, isPadded = _d === void 0 ? false : _d, _e = _a.headingLevel, headingLevel = _e === void 0 ? "2" : _e, props = __rest(_a, ["heading", "content", "id", "image", "isHeadingWordWrap", "isPadded", "headingLevel"]);
|
|
15
15
|
return (React.createElement("div", __assign({ className: classNames((_b = {},
|
|
16
16
|
_b[styles["section-header"]] = true,
|
|
17
17
|
_b[styles["section-header--padded"]] = isPadded,
|
|
18
|
-
_b)) },
|
|
18
|
+
_b)) }, filterAttrs(props)),
|
|
19
19
|
React.createElement("div", { className: classNames((_c = {}, _c[styles["section-header--hasImage"]] = image, _c)) },
|
|
20
20
|
image && (React.createElement("div", null,
|
|
21
21
|
React.createElement(Image, __assign({}, image, { width: 68, fit: "cover" })))),
|
|
22
|
-
React.createElement(Heading, { level: headingLevel, id: id, size: "xl" }, heading)),
|
|
22
|
+
React.createElement(Heading, { level: headingLevel, id: id, size: "xl", isWordWrap: isHeadingWordWrap }, heading)),
|
|
23
23
|
content && (React.createElement(React.Fragment, null,
|
|
24
24
|
React.createElement(VerticalSpace, { size: "24" }),
|
|
25
25
|
React.createElement(Text, { size: "l", elementType: "p" }, content)))));
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { a as __rest, _ as __assign } from './tslib.es6-D6Wu-xwB.mjs';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import { c as classNames } from './index-BfTCfPZ1.mjs';
|
|
4
|
+
import { f as filterAttrs } from './filter-attrs-DZ7RCEZm.mjs';
|
|
5
|
+
import { B as BtIconArrowRightFill } from './BtIconArrowRightFill-D0zKgk3B.mjs';
|
|
6
|
+
import { Image } from '@arc-ui/components/Image';
|
|
7
|
+
import { VerticalSpace } from '@arc-ui/components/VerticalSpace';
|
|
8
|
+
import { Heading } from '@arc-ui/components/Heading';
|
|
9
|
+
|
|
10
|
+
var styles = {"thumbnailSignpost":"ThumbnailSignpost-module_thumbnailSignpost__Yf26b","isLink":"ThumbnailSignpost-module_isLink__FucdG","content":"ThumbnailSignpost-module_content__XG9oj","heading":"ThumbnailSignpost-module_heading__mTrpJ","image":"ThumbnailSignpost-module_image__syGZj","thumbnailButton":"ThumbnailSignpost-module_thumbnailButton__Nn-NR","buttonIcon":"ThumbnailSignpost-module_buttonIcon__ydmza"};
|
|
11
|
+
|
|
12
|
+
/** Use `ThumbnailSignpost` to highlight key information or navigation points with an accompanying thumbnail image or icon. */
|
|
13
|
+
var ThumbnailSignpost = function (_a) {
|
|
14
|
+
var _b;
|
|
15
|
+
var text = _a.text, title = _a.title, img = _a.img, onClick = _a.onClick, buttonLabel = _a.buttonLabel, props = __rest(_a, ["text", "title", "img", "onClick", "buttonLabel"]);
|
|
16
|
+
return (React.createElement("div", __assign({ className: classNames(styles.thumbnailSignpost, (_b = {},
|
|
17
|
+
_b[styles.isLink] = onClick,
|
|
18
|
+
_b)), onClick: onClick, "aria-label": title, tabIndex: onClick ? 0 : -1 }, (onClick && { role: "button" }), filterAttrs(props)),
|
|
19
|
+
img && (React.createElement("div", { className: styles.image },
|
|
20
|
+
React.createElement(Image, __assign({}, img)))),
|
|
21
|
+
React.createElement("div", { className: styles.content },
|
|
22
|
+
React.createElement("span", { className: styles.heading }, title),
|
|
23
|
+
React.createElement(VerticalSpace, { size: "8" }),
|
|
24
|
+
text,
|
|
25
|
+
buttonLabel && onClick && (React.createElement(React.Fragment, null,
|
|
26
|
+
React.createElement(VerticalSpace, { size: "8" }),
|
|
27
|
+
React.createElement("div", { className: styles.thumbnailButton },
|
|
28
|
+
React.createElement("span", { className: styles.buttonIcon, role: "img", style: {
|
|
29
|
+
height: 24,
|
|
30
|
+
width: 24,
|
|
31
|
+
maskImage: "url(\"".concat(BtIconArrowRightFill, "\")"),
|
|
32
|
+
WebkitMaskImage: "url(\"".concat(BtIconArrowRightFill, "\")"),
|
|
33
|
+
} }),
|
|
34
|
+
React.createElement(Heading, { size: "xxs" }, buttonLabel)))))));
|
|
35
|
+
};
|
|
36
|
+
|
|
37
|
+
export { ThumbnailSignpost as T };
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Filters out attributes from the given props object based on a pattern.
|
|
3
|
+
*
|
|
4
|
+
* This function extracts all properties that match either the `data-*` or `aria-*` attribute patterns
|
|
5
|
+
* and returns a new object containing only those properties.
|
|
6
|
+
*
|
|
7
|
+
* @param props - The object containing properties to filter.
|
|
8
|
+
* @returns A new object containing only the matched attributes (`data-*` and `aria-*`) from the input props.
|
|
9
|
+
*/
|
|
10
|
+
var attributePrefixes = ["data-", "aria-"];
|
|
11
|
+
var filterAttrs = function (props) {
|
|
12
|
+
var filteredProps = {};
|
|
13
|
+
var _loop_1 = function (prop) {
|
|
14
|
+
if (Object.prototype.hasOwnProperty.call(props, prop) &&
|
|
15
|
+
attributePrefixes.some(function (prefix) { return prop.startsWith(prefix); })) {
|
|
16
|
+
filteredProps[prop] = props[prop];
|
|
17
|
+
}
|
|
18
|
+
};
|
|
19
|
+
for (var prop in props) {
|
|
20
|
+
_loop_1(prop);
|
|
21
|
+
}
|
|
22
|
+
return filteredProps;
|
|
23
|
+
};
|
|
24
|
+
|
|
25
|
+
export { filterAttrs as f };
|