@automattic/jetpack-components 1.12.14 → 1.12.17

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.
Files changed (66) hide show
  1. package/CHANGELOG.md +20 -0
  2. package/build/components/action-popover/index.js +1 -5
  3. package/build/components/admin-page/style.module.scss +2 -2
  4. package/build/components/alert/index.js +1 -2
  5. package/build/components/automattic-byline-logo/index.js +1 -3
  6. package/build/components/automattic-for-agencies-logo/index.d.ts +1 -1
  7. package/build/components/automattic-icon-logo/index.d.ts +1 -1
  8. package/build/components/automattic-icon-logo/index.js +1 -3
  9. package/build/components/boost-score-bar/index.js +1 -6
  10. package/build/components/boost-score-graph/background.js +1 -13
  11. package/build/components/boost-score-graph/tooltip.js +3 -23
  12. package/build/components/button/index.js +2 -4
  13. package/build/components/contextual-upgrade-trigger/index.js +1 -6
  14. package/build/components/decorative-card/index.js +1 -2
  15. package/build/components/details-viewer/index.js +2 -4
  16. package/build/components/dialog/index.js +1 -3
  17. package/build/components/diff-viewer/index.js +4 -10
  18. package/build/components/donut-meter/index.js +2 -4
  19. package/build/components/dot-pager/index.js +1 -3
  20. package/build/components/gravatar/index.d.ts +1 -1
  21. package/build/components/icon-tooltip/index.js +1 -3
  22. package/build/components/icons/index.d.ts +1 -0
  23. package/build/components/icons/index.js +5 -12
  24. package/build/components/icons/style.module.scss +12 -12
  25. package/build/components/jetpack-footer/index.js +2 -6
  26. package/build/components/jetpack-footer/style.scss +3 -2
  27. package/build/components/jetpack-logo/index.js +1 -4
  28. package/build/components/jetpack-protect-logo/index.js +1 -4
  29. package/build/components/jetpack-search-logo/index.js +1 -5
  30. package/build/components/jetpack-vaultpress-backup-logo/index.js +1 -6
  31. package/build/components/jetpack-videopress-logo/index.js +1 -4
  32. package/build/components/loading-placeholder/index.d.ts +1 -1
  33. package/build/components/marked-lines/index.js +2 -4
  34. package/build/components/navigator-modal/footer.js +1 -2
  35. package/build/components/navigator-modal/header.d.ts +1 -1
  36. package/build/components/navigator-modal/header.js +1 -3
  37. package/build/components/navigator-modal/screen.js +1 -3
  38. package/build/components/notice/index.js +1 -2
  39. package/build/components/popover/index.js +1 -3
  40. package/build/components/pricing-card/index.js +1 -7
  41. package/build/components/pricing-table/index.js +10 -18
  42. package/build/components/pricing-table/styles.module.scss +1 -7
  43. package/build/components/pricing-table/types.d.ts +8 -0
  44. package/build/components/product-offer/icons-card.js +1 -2
  45. package/build/components/product-offer/index.js +1 -6
  46. package/build/components/product-offer/product-offer-header.js +1 -3
  47. package/build/components/product-price/index.js +3 -11
  48. package/build/components/product-price/price.js +1 -2
  49. package/build/components/record-meter-bar/index.js +5 -20
  50. package/build/components/split-button/index.js +1 -3
  51. package/build/components/stat-card/index.js +1 -4
  52. package/build/components/status/index.d.ts +1 -1
  53. package/build/components/status/index.js +2 -4
  54. package/build/components/swipeable/index.js +3 -7
  55. package/build/components/testimonials/testimonial.js +1 -11
  56. package/build/components/text/constants.d.ts +12 -12
  57. package/build/components/upsell-banner/index.js +2 -7
  58. package/components/admin-page/style.module.scss +2 -2
  59. package/components/icons/index.tsx +1 -0
  60. package/components/icons/style.module.scss +12 -12
  61. package/components/jetpack-footer/style.scss +3 -2
  62. package/components/pricing-table/index.tsx +5 -4
  63. package/components/pricing-table/styles.module.scss +1 -7
  64. package/components/pricing-table/types.ts +9 -0
  65. package/components/status/index.tsx +1 -1
  66. package/package.json +21 -21
@@ -1,7 +1,7 @@
1
1
  import type { ReactNode } from 'react';
2
2
  declare const LoadingPlaceholder: ({ children, width, height, className, }: {
3
3
  children?: ReactNode;
4
- width?: string | number;
4
+ width?: number | string;
5
5
  height?: number;
6
6
  className?: string;
7
7
  }) => import("react/jsx-runtime").JSX.Element;
@@ -38,15 +38,13 @@ const markup = (marks, content) => {
38
38
  };
39
39
  const MarkedLines = ({ context }) => {
40
40
  const { marks, ...lines } = context;
41
- return (_jsxs("div", { className: styles['marked-lines'], children: [
42
- _jsx("div", { className: styles['marked-lines__line-numbers'], children: Object.keys(lines).map(lineNumber => {
41
+ return (_jsxs("div", { className: styles['marked-lines'], children: [_jsx("div", { className: styles['marked-lines__line-numbers'], children: Object.keys(lines).map(lineNumber => {
43
42
  const hasMarks = Object.hasOwn(marks, lineNumber);
44
43
  return (_jsx("div", { className: `${styles['marked-lines__line-number']} ${hasMarks ? styles['marked-lines__marked-line'] : ''}`, children: lineNumber }, lineNumber));
45
44
  }) }), _jsx("div", { className: styles['marked-lines__lines'], children: Object.keys(lines).map(lineNumber => {
46
45
  const lineContent = lines[lineNumber] || ' ';
47
46
  const hasMarks = Object.hasOwn(marks, lineNumber);
48
47
  return (_jsx("div", { className: `${styles['marked-lines__line']} ${hasMarks ? styles['marked-lines__marked-line'] : ''} `, children: _jsx(_Fragment, { children: hasMarks ? markup(marks[lineNumber], lineContent) : lineContent }) }, lineNumber));
49
- }) })
50
- ] }));
48
+ }) })] }));
51
49
  };
52
50
  export default MarkedLines;
@@ -21,8 +21,7 @@ export function Footer({ children, actions, isScreenLocked, className, ...props
21
21
  context.onClose?.();
22
22
  }
23
23
  }, [isScreenLocked, navigator, context]);
24
- return (_jsxs(Flex, { className: clsx('jp-navigator-modal__footer', className), ...props, children: [
25
- _jsx(FlexBlock, { children: children }), actions ? (_jsx(FlexItem, { children: _jsx(Flex, { children: actions.map((action, index) => {
24
+ return (_jsxs(Flex, { className: clsx('jp-navigator-modal__footer', className), ...props, children: [_jsx(FlexBlock, { children: children }), actions ? (_jsx(FlexItem, { children: _jsx(Flex, { children: actions.map((action, index) => {
26
25
  if (typeof action === 'function') {
27
26
  return action({ navigate });
28
27
  }
@@ -26,4 +26,4 @@ export type HeaderProps = {
26
26
  *
27
27
  * @return component
28
28
  */
29
- export declare function Header({ icon, title, isScreenLocked, onGoBack: onGoBackProp, onClose: onCloseProp }: HeaderProps): import("react/jsx-runtime").JSX.Element;
29
+ export declare function Header({ icon, title, isScreenLocked, onGoBack: onGoBackProp, onClose: onCloseProp, }: HeaderProps): import("react/jsx-runtime").JSX.Element;
@@ -21,7 +21,5 @@ export function Header({ icon, title, isScreenLocked, onGoBack: onGoBackProp, on
21
21
  onCloseProp?.();
22
22
  context.onClose?.();
23
23
  }, [onCloseProp, context]);
24
- return (_jsxs("div", { className: "jp-navigator-modal__header", children: [
25
- _jsxs("div", { className: "jp-navigator-modal__title-wrap", children: [!isScreenLocked ? (_jsx(Button, { label: __('Go back', 'jetpack-components'), icon: isRTL() ? chevronRight : chevronLeft, onClick: onGoBack, variant: "tertiary", size: "compact" })) : null, icon, _jsx("h1", { children: title })
26
- ] }), context.isDismissible ? (_jsx(Button, { size: "compact", onClick: onCloseModal, icon: close, label: __('Close', 'jetpack-components'), variant: "tertiary" })) : null] }));
24
+ return (_jsxs("div", { className: "jp-navigator-modal__header", children: [_jsxs("div", { className: "jp-navigator-modal__title-wrap", children: [!isScreenLocked ? (_jsx(Button, { label: __('Go back', 'jetpack-components'), icon: isRTL() ? chevronRight : chevronLeft, onClick: onGoBack, variant: "tertiary", size: "compact" })) : null, icon, _jsx("h1", { children: title })] }), context.isDismissible ? (_jsx(Button, { size: "compact", onClick: onCloseModal, icon: close, label: __('Close', 'jetpack-components'), variant: "tertiary" })) : null] }));
27
25
  }
@@ -12,7 +12,5 @@ import { Header } from './header.js';
12
12
  */
13
13
  export function Screen({ path, className, title, sidebar, headerIcon, isScreenLocked, onGoBack, onClose, footerContent, footerActions, children, content, ...props }) {
14
14
  const hasFooter = Boolean(footerContent || (footerActions && footerActions.length));
15
- return (_jsx(Navigator.Screen, { path: path, className: clsx('jp-navigator-modal__screen', className), ...props, children: _jsxs(Flex, { direction: "column", gap: 0, children: [
16
- _jsx(Header, { title: title, isScreenLocked: isScreenLocked, icon: headerIcon, onGoBack: onGoBack, onClose: onClose }), _jsxs(Flex, { gap: 0, align: "start", className: "jp-navigator-modal__body", children: [sidebar ? _jsx("div", { className: "jp-navigator-modal__sidebar", children: sidebar }) : null, _jsx("div", { className: "jp-navigator-modal__content", children: content ?? children })
17
- ] }), hasFooter ? (_jsx(Footer, { actions: footerActions, isScreenLocked: isScreenLocked, children: footerContent })) : null] }) }));
15
+ return (_jsx(Navigator.Screen, { path: path, className: clsx('jp-navigator-modal__screen', className), ...props, children: _jsxs(Flex, { direction: "column", gap: 0, children: [_jsx(Header, { title: title, isScreenLocked: isScreenLocked, icon: headerIcon, onGoBack: onGoBack, onClose: onClose }), _jsxs(Flex, { gap: 0, align: "start", className: "jp-navigator-modal__body", children: [sidebar ? _jsx("div", { className: "jp-navigator-modal__sidebar", children: sidebar }) : null, _jsx("div", { className: "jp-navigator-modal__content", children: content ?? children })] }), hasFooter ? (_jsx(Footer, { actions: footerActions, isScreenLocked: isScreenLocked, children: footerContent })) : null] }) }));
18
16
  }
@@ -30,7 +30,6 @@ const getIconByLevel = (level) => {
30
30
  */
31
31
  const Notice = ({ level = 'info', title, children, actions, hideCloseButton = false, onClose, }) => {
32
32
  const classes = clsx(styles.container, styles[`is-${level}`]);
33
- return (_jsxs("div", { className: classes, children: [
34
- _jsx("div", { className: styles['icon-wrapper'], children: _jsx(Icon, { icon: getIconByLevel(level), className: styles.icon }) }), _jsxs("div", { className: styles['main-content'], children: [title && _jsx("div", { className: styles.title, children: title }), children, actions && actions.length > 0 && (_jsx("div", { className: styles['action-bar'], children: actions.map((action, index) => (_jsx("div", { className: styles.action, children: action }, index))) }))] }), !hideCloseButton && (_jsx("button", { "aria-label": "close", className: styles['close-button'], onClick: onClose, children: _jsx(Icon, { icon: close }) }))] }));
33
+ return (_jsxs("div", { className: classes, children: [_jsx("div", { className: styles['icon-wrapper'], children: _jsx(Icon, { icon: getIconByLevel(level), className: styles.icon }) }), _jsxs("div", { className: styles['main-content'], children: [title && _jsx("div", { className: styles.title, children: title }), children, actions && actions.length > 0 && (_jsx("div", { className: styles['action-bar'], children: actions.map((action, index) => (_jsx("div", { className: styles.action, children: action }, index))) }))] }), !hideCloseButton && (_jsx("button", { "aria-label": "close", className: styles['close-button'], onClick: onClose, children: _jsx(Icon, { icon: close }) }))] }));
35
34
  };
36
35
  export default Notice;
@@ -1,8 +1,6 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import './style.scss';
3
3
  const Popover = ({ icon, children, action }) => {
4
- return (_jsxs("div", { className: "jp-popover", children: [
5
- _jsx("div", { className: "jp-popover__icon", children: icon }), _jsx("div", { className: "jp-popover__body", children: children }), _jsx("div", { className: "jp-popover__action", children: action })
6
- ] }));
4
+ return (_jsxs("div", { className: "jp-popover", children: [_jsx("div", { className: "jp-popover__icon", children: icon }), _jsx("div", { className: "jp-popover__body", children: children }), _jsx("div", { className: "jp-popover__action", children: action })] }));
7
5
  };
8
6
  export default Popover;
@@ -27,12 +27,6 @@ const PricingCard = ({ currencyCode = 'USD', priceDetails = __('/month, paid yea
27
27
  const currencyObjectAfter = getCurrencyObject(props.priceAfter, currencyCode);
28
28
  return (_jsxs("div", { className: "jp-components__pricing-card", children: [props.icon && (_jsx("div", { className: "jp-components__pricing-card__icon", children: 'string' === typeof props.icon ? (_jsx("img", { src: props.icon, alt: sprintf(
29
29
  /* translators: %s: the product name */
30
- __('Icon for the product %s', 'jetpack-components'), props.title) })) : (props.icon) })), _jsx("h1", { className: "jp-components__pricing-card__title", children: props.title }), _jsxs("div", { className: "jp-components__pricing-card__pricing", children: [props.priceAfter === 0 && _jsx(LoadingPlaceholder, { width: "100%", height: 48 }), props.priceBefore !== props.priceAfter && props.priceAfter > 0 && (_jsxs("div", { className: "jp-components__pricing-card__price-before", children: [
31
- _jsx("span", { className: "jp-components__pricing-card__currency", children: currencyObjectBefore.symbol }), _jsx("span", { className: "jp-components__pricing-card__price", children: currencyObjectBefore.integer }), showPriceDecimals(currencyObjectBefore) && (_jsxs("span", { className: "jp-components__pricing-card__price-decimal", children: [' ', currencyObjectBefore.fraction] })), _jsx("div", { className: "jp-components__pricing-card__price-strikethrough" })
32
- ] })), props.priceAfter > 0 && (_jsxs(_Fragment, { children: [
33
- _jsxs("div", { className: "jp-components__pricing-card__price-after", children: [
34
- _jsx("span", { className: "jp-components__pricing-card__currency", children: currencyObjectAfter.symbol }), _jsx("span", { className: "jp-components__pricing-card__price", children: currencyObjectAfter.integer }), showPriceDecimals(currencyObjectAfter) && (_jsx("span", { className: "jp-components__pricing-card__price-decimal", children: currencyObjectAfter.fraction }))] }), _jsx("span", { className: "jp-components__pricing-card__price-details", children: priceDetails })
35
- ] }))] }), props.children && (_jsx("div", { className: "jp-components__pricing-card__extra-content-wrapper", children: props.children })), props.tosText && _jsx("div", { className: "jp-components__pricing-card__tos", children: props.tosText }), props.ctaText && (_jsxs(_Fragment, { children: [!props.tosText && (_jsx("div", { className: "jp-components__pricing-card__tos", children: _jsx(TermsOfService, { agreeButtonLabel: props.ctaText }) })), _jsx("div", { className: "jp-components__pricing-card__cta", children: _jsx(Button, { variant: "solid", className: "jp-components__pricing-card__button", onClick: props.onCtaClick, children: props.ctaText }) })
36
- ] })), props.infoText && (_jsx("div", { className: "jp-components__pricing-card__info", children: props.infoText }))] }));
30
+ __('Icon for the product %s', 'jetpack-components'), props.title) })) : (props.icon) })), _jsx("h1", { className: "jp-components__pricing-card__title", children: props.title }), _jsxs("div", { className: "jp-components__pricing-card__pricing", children: [props.priceAfter === 0 && _jsx(LoadingPlaceholder, { width: "100%", height: 48 }), props.priceBefore !== props.priceAfter && props.priceAfter > 0 && (_jsxs("div", { className: "jp-components__pricing-card__price-before", children: [_jsx("span", { className: "jp-components__pricing-card__currency", children: currencyObjectBefore.symbol }), _jsx("span", { className: "jp-components__pricing-card__price", children: currencyObjectBefore.integer }), showPriceDecimals(currencyObjectBefore) && (_jsxs("span", { className: "jp-components__pricing-card__price-decimal", children: [' ', currencyObjectBefore.fraction] })), _jsx("div", { className: "jp-components__pricing-card__price-strikethrough" })] })), props.priceAfter > 0 && (_jsxs(_Fragment, { children: [_jsxs("div", { className: "jp-components__pricing-card__price-after", children: [_jsx("span", { className: "jp-components__pricing-card__currency", children: currencyObjectAfter.symbol }), _jsx("span", { className: "jp-components__pricing-card__price", children: currencyObjectAfter.integer }), showPriceDecimals(currencyObjectAfter) && (_jsx("span", { className: "jp-components__pricing-card__price-decimal", children: currencyObjectAfter.fraction }))] }), _jsx("span", { className: "jp-components__pricing-card__price-details", children: priceDetails })] }))] }), props.children && (_jsx("div", { className: "jp-components__pricing-card__extra-content-wrapper", children: props.children })), props.tosText && _jsx("div", { className: "jp-components__pricing-card__tos", children: props.tosText }), props.ctaText && (_jsxs(_Fragment, { children: [!props.tosText && (_jsx("div", { className: "jp-components__pricing-card__tos", children: _jsx(TermsOfService, { agreeButtonLabel: props.ctaText }) })), _jsx("div", { className: "jp-components__pricing-card__cta", children: _jsx(Button, { variant: "solid", className: "jp-components__pricing-card__button", onClick: props.onCtaClick, children: props.ctaText }) })] })), props.infoText && (_jsx("div", { className: "jp-components__pricing-card__info", children: props.infoText }))] }));
37
31
  };
38
32
  export default PricingCard;
@@ -30,8 +30,8 @@ const getItemLabels = (isComingSoon, isIncluded, featureNameLabel) => {
30
30
  };
31
31
  };
32
32
  export const PricingTableItem = ({ isIncluded = false, isComingSoon = false, index = 0, label = null, tooltipInfo, tooltipTitle, tooltipClassName = '', }) => {
33
- const isLg = useViewportMatch('large');
34
- const item = useContext(PricingTableContext)[index];
33
+ const { items, isLg } = useContext(PricingTableContext);
34
+ const item = items[index];
35
35
  const isExplicitlyEmpty = label === '';
36
36
  const showTick = isComingSoon || isIncluded;
37
37
  const featureNameLabel = item.name;
@@ -44,11 +44,9 @@ export const PricingTableItem = ({ isIncluded = false, isComingSoon = false, ind
44
44
  if (isExplicitlyEmpty) {
45
45
  return (_jsx("div", { className: clsx(styles.item, styles.value, styles.empty) }));
46
46
  }
47
- return (_jsxs("div", { className: clsx(styles.item, styles.value), children: [
48
- _jsx(Icon, { className: clsx(styles.icon, showTick ? styles['icon-check'] : styles['icon-cross']), size: 32, icon: showTick ? check : closeSmall }), _jsx(Text, { variant: "body-small", children: label || defaultLabel }), showTooltip && (_jsx(IconTooltip, { title: tooltipTitle ? tooltipTitle : defaultTooltipTitle, iconClassName: styles['popover-icon'], className: clsx(styles.popover, tooltipClassName), placement: 'bottom-end', iconSize: 14, offset: 4, wide: Boolean(tooltipTitle && tooltipInfo), inline: false, shift: true, children: _jsx(Text, { variant: "body-small", component: "div", children: tooltipInfo || defaultTooltipInfo }) }))] }));
47
+ return (_jsxs("div", { className: clsx(styles.item, styles.value), children: [_jsx(Icon, { className: clsx(styles.icon, showTick ? styles['icon-check'] : styles['icon-cross']), size: 32, icon: showTick ? check : closeSmall }), _jsx(Text, { variant: "body-small", children: label || defaultLabel }), showTooltip && (_jsx(IconTooltip, { title: tooltipTitle ? tooltipTitle : defaultTooltipTitle, iconClassName: styles['popover-icon'], className: clsx(styles.popover, tooltipClassName), placement: 'bottom-end', iconSize: 14, offset: 4, wide: Boolean(tooltipTitle && tooltipInfo), inline: false, shift: true, children: _jsx(Text, { variant: "body-small", component: "div", children: tooltipInfo || defaultTooltipInfo }) }))] }));
49
48
  };
50
- export const PricingTableHeader = ({ title, children }) => (_jsxs("div", { className: styles.headerContainer, children: [title && (_jsx(Text, { variant: "headline-small", className: styles.title, children: title })), _jsx("div", { className: styles.header, children: children })
51
- ] }));
49
+ export const PricingTableHeader = ({ title, children }) => (_jsxs("div", { className: styles.headerContainer, children: [title && (_jsx(Text, { variant: "headline-small", className: styles.title, children: title })), _jsx("div", { className: styles.header, children: children })] }));
52
50
  export const PricingTableColumn = ({ primary = false, children, className, }) => {
53
51
  let index = 0;
54
52
  return (_jsx("div", { className: clsx(styles.card, { [styles['is-primary']]: primary }, className), children: Children.map(children, child => {
@@ -60,15 +58,12 @@ export const PricingTableColumn = ({ primary = false, children, className, }) =>
60
58
  return item;
61
59
  }) }));
62
60
  };
63
- const PricingTable = ({ title, headerLogo, items, children, showIntroOfferDisclaimer = false, }) => {
64
- const isLg = useViewportMatch('large');
65
- return (_jsxs(PricingTableContext.Provider, { value: items, children: [
66
- _jsx("div", { className: clsx(styles.container, { [styles['is-viewport-large']]: isLg }), style: {
61
+ const PricingTable = ({ title, headerLogo, items, children, showIntroOfferDisclaimer = false, breakpoint = 'large', }) => {
62
+ const isLg = useViewportMatch(breakpoint);
63
+ return (_jsxs(PricingTableContext.Provider, { value: { items, isLg }, children: [_jsx("div", { className: clsx(styles.container, { [styles['is-viewport-large']]: isLg }), style: {
67
64
  '--rows': items.length + 1,
68
65
  '--columns': Children.toArray(children).length + 1,
69
- }, children: _jsxs("div", { className: styles.table, children: [
70
- _jsxs("div", { children: [headerLogo && _jsx("div", { className: styles['header-logo'], children: headerLogo }), _jsx(Text, { variant: "headline-small", className: styles.tableTitle, children: title })
71
- ] }), isLg &&
66
+ }, children: _jsxs("div", { className: styles.table, children: [_jsxs("div", { children: [headerLogo && _jsx("div", { className: styles['header-logo'], children: headerLogo }), _jsx(Text, { variant: "headline-small", className: styles.tableTitle, children: title })] }), isLg &&
72
67
  items.map((item, i) => {
73
68
  // Skip rendering feature names that are empty
74
69
  if (!item.name) {
@@ -76,10 +71,7 @@ const PricingTable = ({ title, headerLogo, items, children, showIntroOfferDiscla
76
71
  }
77
72
  return (_jsxs("div", { className: clsx(styles.item, styles.feature, {
78
73
  [styles['last-feature']]: i === items.length - 1,
79
- }), children: [
80
- _jsx(Text, { variant: "body-small", children: _jsx("strong", { children: item.name }) }), item.tooltipInfo && (_jsx(IconTooltip, { title: item.tooltipTitle, iconClassName: styles['popover-icon'], className: styles.popover, placement: item.tooltipPlacement ? item.tooltipPlacement : 'bottom-end', iconSize: 14, offset: 4, wide: Boolean(item.tooltipTitle && item.tooltipInfo), inline: false, shift: true, children: _jsx(Text, { variant: "body-small", children: item.tooltipInfo }) }))] }, i));
81
- }), children] }) }), _jsx("div", { className: styles['tos-container'], children: _jsxs("div", { className: styles.tos, children: [showIntroOfferDisclaimer && (_jsx(Text, { variant: "body-small", children: __('Reduced pricing is a limited offer for the first year and renews at regular price.', 'jetpack-components') })), _jsx(TermsOfService, { multipleButtons: true })
82
- ] }) })
83
- ] }));
74
+ }), children: [_jsx(Text, { variant: "body-small", children: _jsx("strong", { children: item.name }) }), item.tooltipInfo && (_jsx(IconTooltip, { title: item.tooltipTitle, iconClassName: styles['popover-icon'], className: styles.popover, placement: item.tooltipPlacement ? item.tooltipPlacement : 'bottom-end', iconSize: 14, offset: 4, wide: Boolean(item.tooltipTitle && item.tooltipInfo), inline: false, shift: true, children: _jsx(Text, { variant: "body-small", children: item.tooltipInfo }) }))] }, i));
75
+ }), children] }) }), _jsx("div", { className: styles['tos-container'], children: _jsxs("div", { className: styles.tos, children: [showIntroOfferDisclaimer && (_jsx(Text, { variant: "body-small", children: __('Reduced pricing is a limited offer for the first year and renews at regular price.', 'jetpack-components') })), _jsx(TermsOfService, { multipleButtons: true })] }) })] }));
84
76
  };
85
77
  export default PricingTable;
@@ -1,5 +1,3 @@
1
- @use "@automattic/jetpack-base-styles/gutenberg-base-styles" as gb;
2
-
3
1
  .container {
4
2
  --padding: calc(var(--spacing-base) * 4);
5
3
  --padding-horizontal: calc(var(--spacing-base) * 3);
@@ -98,11 +96,7 @@
98
96
  background-image: url(./gradient.svg);
99
97
  background-repeat: no-repeat;
100
98
  background-size: 450px;
101
- background-position-x: center;
102
-
103
- @media (max-width: gb.$break-large) {
104
- background-position-x: right;
105
- }
99
+ background-position-x: right;
106
100
  }
107
101
 
108
102
  > :last-child {
@@ -26,6 +26,14 @@ export type PricingTableProps = {
26
26
  * Whether to show the intro offer disclaimer text with the ToS.
27
27
  */
28
28
  showIntroOfferDisclaimer?: boolean;
29
+ /**
30
+ * Viewport breakpoint at or above which the table renders as columns
31
+ * (below it, offers stack into blocks). Defaults to 'large' (960px).
32
+ * Interstitials hosting 3 offers can pass 'xlarge' (1080px) to stack
33
+ * earlier and avoid cramped columns. Accepts any `@wordpress/compose`
34
+ * viewport-match breakpoint name.
35
+ */
36
+ breakpoint?: 'mobile' | 'small' | 'medium' | 'large' | 'xlarge' | 'wide' | 'huge' | 'xhuge';
29
37
  };
30
38
  export type PricingTableColumnProps = {
31
39
  /**
@@ -18,7 +18,6 @@ export const IconsCard = ({ products, icon, size = 24 }) => {
18
18
  return (_jsx("div", { className: styles['product-bundle-icons'], children: products.map((product, index) => {
19
19
  const ProductIcon = getIconBySlug(product);
20
20
  const ProIcon = ProductIcon ? ProductIcon : () => null;
21
- return (_jsxs(Fragment, { children: [
22
- _jsx(ProIcon, { size: size }), index !== products.length - 1 && (_jsx(Icon, { className: styles['plus-icon'], icon: plus, size: 16 }, `icon-plugs${index * 2 + 1}`))] }, index));
21
+ return (_jsxs(Fragment, { children: [_jsx(ProIcon, { size: size }), index !== products.length - 1 && (_jsx(Icon, { className: styles['plus-icon'], icon: plus, size: 16 }, `icon-plugs${index * 2 + 1}`))] }, index));
23
22
  }) }));
24
23
  };
@@ -25,12 +25,7 @@ const ProductOffer = ({ addProductUrl, buttonDisclaimer, buttonText = '', classN
25
25
  return (_jsxs("div", { className: clsx(styles.wrapper, className, {
26
26
  [styles['is-bundle-card']]: isBundle,
27
27
  [styles['is-card']]: isCard || isBundle, // is card when is bundle.
28
- }), children: [isBundle && _jsx(ProductOfferHeader, {}), _jsxs("div", { className: styles['card-container'], children: [
29
- _jsx(IconsCard, { icon: icon, products: supportedProducts?.length ? supportedProducts : [slug], size: 32 }), _jsx(H3, { children: title }), subTitle && _jsx(Title, { mb: 3, children: subTitle }), description && _jsx(Text, { mb: 3, children: description }), _jsx("ul", { className: styles.features, children: features.map((feature, id) => (_jsxs(Text, { component: "li", variant: "body", children: [
30
- _jsx(Icon, { icon: check, size: 24, className: styles.check }), feature] }, `feature-${id}`))) }), needsPurchase && (_jsx(ProductPrice, { price: price, offPrice: offPrice, currency: currency })), isFree && _jsx(H3, { children: __('Free', 'jetpack-components') }), _jsx(Alert, { level: "error", showIcon: !!error, children: error }), buttonDisclaimer, (!isBundle || (isBundle && !hasRequiredPlan)) && (_jsx(Button, { onClick: addProductUrl ? null : onAdd, isLoading: isLoading, disabled: isLoading, variant: isLoading || !isBundle ? 'primary' : 'secondary', className: styles['add-button'], ...(addProductUrl ? { href: addProductUrl } : {}), children: buttonText || defautlButtonText })), isBundle && hasRequiredPlan && (_jsxs("div", { className: styles['product-has-required-plan'], children: [
31
- _jsx(CheckmarkIcon, { size: 36 }), _jsx(Text, { children: __('Active on your site', 'jetpack-components') })
32
- ] }))] })
33
- ] }));
28
+ }), children: [isBundle && _jsx(ProductOfferHeader, {}), _jsxs("div", { className: styles['card-container'], children: [_jsx(IconsCard, { icon: icon, products: supportedProducts?.length ? supportedProducts : [slug], size: 32 }), _jsx(H3, { children: title }), subTitle && _jsx(Title, { mb: 3, children: subTitle }), description && _jsx(Text, { mb: 3, children: description }), _jsx("ul", { className: styles.features, children: features.map((feature, id) => (_jsxs(Text, { component: "li", variant: "body", children: [_jsx(Icon, { icon: check, size: 24, className: styles.check }), feature] }, `feature-${id}`))) }), needsPurchase && (_jsx(ProductPrice, { price: price, offPrice: offPrice, currency: currency })), isFree && _jsx(H3, { children: __('Free', 'jetpack-components') }), _jsx(Alert, { level: "error", showIcon: !!error, children: error }), buttonDisclaimer, (!isBundle || (isBundle && !hasRequiredPlan)) && (_jsx(Button, { onClick: addProductUrl ? null : onAdd, isLoading: isLoading, disabled: isLoading, variant: isLoading || !isBundle ? 'primary' : 'secondary', className: styles['add-button'], ...(addProductUrl ? { href: addProductUrl } : {}), children: buttonText || defautlButtonText })), isBundle && hasRequiredPlan && (_jsxs("div", { className: styles['product-has-required-plan'], children: [_jsx(CheckmarkIcon, { size: 36 }), _jsx(Text, { children: __('Active on your site', 'jetpack-components') })] }))] })] }));
34
29
  };
35
30
  export default ProductOffer;
36
31
  export * from './icons-card.js';
@@ -10,7 +10,5 @@ import styles from './style.module.scss';
10
10
  * @return {ReactNode} ProductOfferHeader react component.
11
11
  */
12
12
  export const ProductOfferHeader = ({ title = __('Popular upgrade', 'jetpack-components'), }) => {
13
- return (_jsxs("div", { className: styles['card-header'], children: [
14
- _jsx(Icon, { icon: star, className: styles['product-bundle-icon'], size: 24 }), _jsx(Text, { variant: "label", children: title })
15
- ] }));
13
+ return (_jsxs("div", { className: styles['card-header'], children: [_jsx(Icon, { icon: star, className: styles['product-bundle-icon'], size: 24 }), _jsx(Text, { variant: "label", children: title })] }));
16
14
  };
@@ -27,19 +27,11 @@ const ProductPrice = ({ price, offPrice, currency = '', showNotOffPrice = true,
27
27
  const showDiscountLabel = !hideDiscountLabel && discount && discount > 0;
28
28
  const discountElt = showDiscountLabel ? discount + __('% off', 'jetpack-components') : null;
29
29
  if (variant === 'simple') {
30
- return (_jsxs("div", { className: styles.simple, children: [
31
- _jsxs("div", { className: styles.currentPrice, children: [
32
- _jsx(Price, { value: offPrice ?? price, currency: currency, isOff: !isNotConvenientPrice, hidePriceFraction: hidePriceFraction, inline: true }), _jsx("div", { children: legend })
33
- ] }), showNotOffPrice && (_jsxs("div", { className: styles.originalPrice, children: [
34
- _jsx(Price, { value: price, currency: currency, isOff: false, hidePriceFraction: hidePriceFraction, inline: true }), _jsx("div", { children: discount &&
30
+ return (_jsxs("div", { className: styles.simple, children: [_jsxs("div", { className: styles.currentPrice, children: [_jsx(Price, { value: offPrice ?? price, currency: currency, isOff: !isNotConvenientPrice, hidePriceFraction: hidePriceFraction, inline: true }), _jsx("div", { children: legend })] }), showNotOffPrice && (_jsxs("div", { className: styles.originalPrice, children: [_jsx(Price, { value: price, currency: currency, isOff: false, hidePriceFraction: hidePriceFraction, inline: true }), _jsx("div", { children: discount &&
35
31
  discount > 0 &&
36
- discount + __('% off the first year', 'jetpack-components') })
37
- ] }))] }));
32
+ discount + __('% off the first year', 'jetpack-components') })] }))] }));
38
33
  }
39
- return (_jsxs(_Fragment, { children: [
40
- _jsx("div", { className: styles.container, children: _jsxs("div", { className: clsx(styles['price-container'], 'product-price_container'), children: [
41
- _jsx(Price, { value: offPrice ?? price, currency: currency, isOff: !isNotConvenientPrice, hidePriceFraction: hidePriceFraction }), showNotOffPrice && (_jsx(Price, { value: price, currency: currency, isOff: false, hidePriceFraction: hidePriceFraction })), discountElt && (_jsx(Text, { className: clsx(styles['promo-label'], 'product-price_promo_label'), children: discountElt }))] }) }), _jsxs("div", { className: styles.footer, children: [children ? (children) : (_jsx(Text, { className: clsx(styles.legend, 'product-price_legend'), children: legend })), promoLabel && (_jsx(Text, { className: clsx(styles['promo-label'], 'product-price_promo_label'), children: promoLabel }))] })
42
- ] }));
34
+ return (_jsxs(_Fragment, { children: [_jsx("div", { className: styles.container, children: _jsxs("div", { className: clsx(styles['price-container'], 'product-price_container'), children: [_jsx(Price, { value: offPrice ?? price, currency: currency, isOff: !isNotConvenientPrice, hidePriceFraction: hidePriceFraction }), showNotOffPrice && (_jsx(Price, { value: price, currency: currency, isOff: false, hidePriceFraction: hidePriceFraction })), discountElt && (_jsx(Text, { className: clsx(styles['promo-label'], 'product-price_promo_label'), children: discountElt }))] }) }), _jsxs("div", { className: styles.footer, children: [children ? (children) : (_jsx(Text, { className: clsx(styles.legend, 'product-price_legend'), children: legend })), promoLabel && (_jsx(Text, { className: clsx(styles['promo-label'], 'product-price_promo_label'), children: promoLabel }))] })] }));
43
35
  };
44
36
  export default ProductPrice;
45
37
  export * from './price.js';
@@ -16,6 +16,5 @@ export const Price = ({ value, currency, isOff, hidePriceFraction, inline = fals
16
16
  });
17
17
  const { symbol, integer, fraction } = getCurrencyObject(value, currency);
18
18
  const showPriceFraction = !hidePriceFraction || !fraction.endsWith('00');
19
- return (_jsxs(Text, { className: classNames, variant: "headline-medium", component: "p", children: [inline ? (_jsxs(_Fragment, { children: [symbol, integer] })) : (_jsxs(_Fragment, { children: [
20
- _jsx(Text, { className: styles.symbol, component: "sup", variant: "title-medium", children: symbol }), integer] })), showPriceFraction && (_jsx(Text, { component: "sup", variant: "body-small", "data-testid": "PriceFraction", children: _jsx("strong", { children: fraction }) }))] }));
19
+ return (_jsxs(Text, { className: classNames, variant: "headline-medium", component: "p", children: [inline ? (_jsxs(_Fragment, { children: [symbol, integer] })) : (_jsxs(_Fragment, { children: [_jsx(Text, { className: styles.symbol, component: "sup", variant: "title-medium", children: symbol }), integer] })), showPriceFraction && (_jsx(Text, { component: "sup", variant: "body-small", "data-testid": "PriceFraction", children: _jsx("strong", { children: fraction }) }))] }));
21
20
  };
@@ -27,29 +27,14 @@ const RecordMeterBar = ({ totalCount, items = [], showLegendLabelBeforeCount = f
27
27
  }
28
28
  return items;
29
29
  }, [items, sortByCount]);
30
- return (_jsxs("div", { className: clsx('record-meter-bar', className), children: [
31
- _jsx("div", { className: "record-meter-bar__items", "aria-hidden": "true", children: itemsToRender.map(({ count, label, backgroundColor }) => {
30
+ return (_jsxs("div", { className: clsx('record-meter-bar', className), children: [_jsx("div", { className: "record-meter-bar__items", "aria-hidden": "true", children: itemsToRender.map(({ count, label, backgroundColor }) => {
32
31
  const widthPercent = ((count / total) * 100).toPrecision(2);
33
32
  return (_jsx("div", { style: { backgroundColor, flexBasis: `${widthPercent}%` } }, label));
34
33
  }) }), _jsxs("div", { className: "record-meter-bar__legend", "aria-hidden": "true", children: [legendTitle && _jsx("div", { className: "record-meter-bar__legend--title", children: legendTitle }), _jsx("ul", { className: "record-meter-bar__legend--items", children: itemsToRender.map(({ count, label, backgroundColor }) => {
35
34
  const formattedCount = formatNumber(count);
36
- return (_jsxs("li", { className: "record-meter-bar__legend--item", children: [
37
- _jsx("div", { className: "record-meter-bar__legend--item-circle", style: { backgroundColor } }), !showLegendLabelBeforeCount && (_jsxs("span", { children: [
38
- _jsx("span", { className: "record-meter-bar__legend--item-count", children: formattedCount }), _jsx("span", { className: "record-meter-bar__legend--item-label", children: label })
39
- ] })), showLegendLabelBeforeCount && (_jsxs("span", { children: [
40
- _jsx("span", { className: "record-meter-bar__legend--item-label record-meter-bar__legend--item-label-first", children: label }), _jsxs("span", { className: "record-meter-bar__legend--item-count", children: ["(", formattedCount, ")"] })
41
- ] }))] }, label));
42
- }) })
43
- ] }), _jsxs("table", { className: "screen-reader-text", children: [
44
- _jsx("caption", { children: tableCaption || __('Summary of the records', 'jetpack-components') }), _jsxs("tbody", { children: [
45
- _jsxs("tr", { children: [
46
- _jsx("th", { scope: "col", children: recordTypeLabel || __('Record type', 'jetpack-components') }), _jsx("th", { scope: "col", children: recordCountLabel || __('Record count', 'jetpack-components') })
47
- ] }), itemsToRender.map(({ label, count }) => {
48
- return (_jsxs("tr", { children: [
49
- _jsx("td", { children: label }), _jsx("td", { children: count })
50
- ] }, label));
51
- })] })
52
- ] })
53
- ] }));
35
+ return (_jsxs("li", { className: "record-meter-bar__legend--item", children: [_jsx("div", { className: "record-meter-bar__legend--item-circle", style: { backgroundColor } }), !showLegendLabelBeforeCount && (_jsxs("span", { children: [_jsx("span", { className: "record-meter-bar__legend--item-count", children: formattedCount }), _jsx("span", { className: "record-meter-bar__legend--item-label", children: label })] })), showLegendLabelBeforeCount && (_jsxs("span", { children: [_jsx("span", { className: "record-meter-bar__legend--item-label record-meter-bar__legend--item-label-first", children: label }), _jsxs("span", { className: "record-meter-bar__legend--item-count", children: ["(", formattedCount, ")"] })] }))] }, label));
36
+ }) })] }), _jsxs("table", { className: "screen-reader-text", children: [_jsx("caption", { children: tableCaption || __('Summary of the records', 'jetpack-components') }), _jsxs("tbody", { children: [_jsxs("tr", { children: [_jsx("th", { scope: "col", children: recordTypeLabel || __('Record type', 'jetpack-components') }), _jsx("th", { scope: "col", children: recordCountLabel || __('Record count', 'jetpack-components') })] }), itemsToRender.map(({ label, count }) => {
37
+ return (_jsxs("tr", { children: [_jsx("td", { children: label }), _jsx("td", { children: count })] }, label));
38
+ })] })] })] }));
54
39
  };
55
40
  export default RecordMeterBar;
@@ -9,8 +9,6 @@ const SplitButton = ({ variant, controls, popoverProps, toggleProps, label, ...b
9
9
  className: styles.button,
10
10
  ...buttonProps,
11
11
  };
12
- return (_jsx(Flex, { className: styles['split-button'], children: _jsxs("div", { role: "group", className: "components-button-group", children: [
13
- _jsx(Button, { ...wpButtonProps }), _jsx(DropdownMenu, { toggleProps: { variant, className: styles.button, ...toggleProps }, popoverProps: { noArrow: false, ...popoverProps }, icon: _jsx(DownIcon, {}), disableOpenOnArrowDown: true, controls: controls, label: label })
14
- ] }) }));
12
+ return (_jsx(Flex, { className: styles['split-button'], children: _jsxs("div", { role: "group", className: "components-button-group", children: [_jsx(Button, { ...wpButtonProps }), _jsx(DropdownMenu, { toggleProps: { variant, className: styles.button, ...toggleProps }, popoverProps: { noArrow: false, ...popoverProps }, icon: _jsx(DownIcon, {}), disableOpenOnArrowDown: true, controls: controls, label: label })] }) }));
15
13
  };
16
14
  export default SplitButton;
@@ -19,9 +19,6 @@ import styles from './style.module.scss';
19
19
  const StatCard = ({ className, hideValue, icon, label, value, variant = 'square', }) => {
20
20
  const formattedValue = formatNumber(value);
21
21
  const compactValue = formatNumberCompact(value);
22
- return (_jsxs("div", { className: clsx(className, styles.wrapper, styles[variant]), children: [
23
- _jsx("div", { className: clsx(styles.icon), children: icon }), _jsxs("div", { className: clsx(styles.info), children: [
24
- _jsx(Text, { className: styles.label, children: label }), variant === 'square' ? (_jsx(Tooltip, { text: formattedValue, placement: "top", children: _jsx(Text, { variant: "headline-small", className: clsx(styles.value), children: hideValue ? '-' : compactValue }) })) : (_jsx(Text, { variant: "title-medium-semi-bold", className: clsx(styles.value), children: hideValue ? '-' : formattedValue }))] })
25
- ] }));
22
+ return (_jsxs("div", { className: clsx(className, styles.wrapper, styles[variant]), children: [_jsx("div", { className: clsx(styles.icon), children: icon }), _jsxs("div", { className: clsx(styles.info), children: [_jsx(Text, { className: styles.label, children: label }), variant === 'square' ? (_jsx(Tooltip, { text: formattedValue, placement: "top", children: _jsx(Text, { variant: "headline-small", className: clsx(styles.value), children: hideValue ? '-' : compactValue }) })) : (_jsx(Text, { variant: "title-medium-semi-bold", className: clsx(styles.value), children: hideValue ? '-' : formattedValue }))] })] }));
26
23
  };
27
24
  export default StatCard;
@@ -7,7 +7,7 @@ export interface StatusProps {
7
7
  /**
8
8
  * Status component.
9
9
  *
10
- * @deprecated Inline the equivalent JSX using `Text` from `@wordpress/ui` and a small color-coded indicator span. The wrapper renders a flex container at `body-sm` size with `font-weight: 600` and a `0.666em` round indicator coloured by status using WPDS design tokens (`var(--wpds-color-fg-content-success-weak)` for `active`, `--wpds-color-fg-content-error-weak` for `error`, `--wpds-color-fg-content-neutral-weak` for `inactive`, `--wpds-color-fg-content-warning-weak` for `action`, `--wpds-color-fg-content-info-weak` for `initializing`). Include a fallback hex for surfaces that don't load `@wordpress/theme/design-tokens.css` (e.g. the legacy Jetpack settings dashboard).
10
+ * @deprecated Inline the equivalent JSX using `Text` from `@wordpress/ui` and a small color-coded indicator span. The wrapper renders a flex container at `body-sm` size with `font-weight: 600` and a `0.666em` round indicator coloured by status using WPDS design tokens (`var(--wpds-color-foreground-content-success-weak)` for `active`, `--wpds-color-foreground-content-error-weak` for `error`, `--wpds-color-foreground-content-neutral-weak` for `inactive`, `--wpds-color-foreground-content-warning-weak` for `action`, `--wpds-color-foreground-content-info-weak` for `initializing`). Include a fallback hex for surfaces that don't load `@wordpress/theme/design-tokens.css` (e.g. the legacy Jetpack settings dashboard).
11
11
  *
12
12
  * @param {StatusProps} props - The component properties.
13
13
  * @param {string} props.className - Optional className forwarded to the outer element.
@@ -6,7 +6,7 @@ import styles from './style.module.scss';
6
6
  /**
7
7
  * Status component.
8
8
  *
9
- * @deprecated Inline the equivalent JSX using `Text` from `@wordpress/ui` and a small color-coded indicator span. The wrapper renders a flex container at `body-sm` size with `font-weight: 600` and a `0.666em` round indicator coloured by status using WPDS design tokens (`var(--wpds-color-fg-content-success-weak)` for `active`, `--wpds-color-fg-content-error-weak` for `error`, `--wpds-color-fg-content-neutral-weak` for `inactive`, `--wpds-color-fg-content-warning-weak` for `action`, `--wpds-color-fg-content-info-weak` for `initializing`). Include a fallback hex for surfaces that don't load `@wordpress/theme/design-tokens.css` (e.g. the legacy Jetpack settings dashboard).
9
+ * @deprecated Inline the equivalent JSX using `Text` from `@wordpress/ui` and a small color-coded indicator span. The wrapper renders a flex container at `body-sm` size with `font-weight: 600` and a `0.666em` round indicator coloured by status using WPDS design tokens (`var(--wpds-color-foreground-content-success-weak)` for `active`, `--wpds-color-foreground-content-error-weak` for `error`, `--wpds-color-foreground-content-neutral-weak` for `inactive`, `--wpds-color-foreground-content-warning-weak` for `action`, `--wpds-color-foreground-content-info-weak` for `initializing`). Include a fallback hex for surfaces that don't load `@wordpress/theme/design-tokens.css` (e.g. the legacy Jetpack settings dashboard).
10
10
  *
11
11
  * @param {StatusProps} props - The component properties.
12
12
  * @param {string} props.className - Optional className forwarded to the outer element.
@@ -24,8 +24,6 @@ const Status = ({ className, label, status = 'inactive' }) => {
24
24
  };
25
25
  return (_jsxs(Text, { variant: "body-extra-small", className: clsx(styles.status, {
26
26
  [styles[`is-${status}`]]: status,
27
- }, className), children: [
28
- _jsx("span", { className: styles.status__indicator }), _jsx("span", { className: styles.status__label, children: label || label === '' ? label : defaultLabels[status] })
29
- ] }));
27
+ }, className), children: [_jsx("span", { className: styles.status__indicator }), _jsx("span", { className: styles.status__label, children: label || label === '' ? label : defaultLabels[status] })] }));
30
28
  };
31
29
  export default Status;
@@ -275,16 +275,14 @@ export const Swipeable = ({ hasDynamicHeight = false, children, currentPage = 0,
275
275
  return null;
276
276
  }, [handleDragStart, handleDrag, handleDragEnd]);
277
277
  const offset = getOffset(currentPage);
278
- return (_jsxs(_Fragment, { children: [
279
- _createElement("div", { ...getTouchEvents(), className: "swipeable__container", ref: pagesRef, ...otherProps,
278
+ return (_jsxs(_Fragment, { children: [_createElement("div", { ...getTouchEvents(), className: "swipeable__container", ref: pagesRef, ...otherProps,
280
279
  // Ensure that state is reset when the window is resized
281
280
  key: containerWidth?.toString() },
282
281
  _jsxs("div", { className: clsx('swipeable__pages', containerClassName), style: {
283
282
  ...pagesStyle,
284
283
  width: getPagesWidth(containerWidth, numPages + 2),
285
284
  transform: `translate3d(${offset}px, 0px, 0px)`,
286
- }, onTransitionEnd: handleTransitionEnd, children: [
287
- _jsx("div", { style: { width: `${containerWidth}px` }, className: clsx('swipeable__page', pageClassName, {
285
+ }, onTransitionEnd: handleTransitionEnd, children: [_jsx("div", { style: { width: `${containerWidth}px` }, className: clsx('swipeable__page', pageClassName, {
288
286
  'is-clone': true,
289
287
  'is-prev': currentPage === 0,
290
288
  }), children: Children.toArray(children)[numPages - 1] }, `clone-prev-${numPages - 1}`), Children.map(children, (child, index) => (_jsx("div", { style: { width: `${containerWidth}px` }, className: clsx('swipeable__page', pageClassName, {
@@ -294,8 +292,6 @@ export const Swipeable = ({ hasDynamicHeight = false, children, currentPage = 0,
294
292
  }), "data-testid": `swipeable-page-${index + 1}`, children: child }, `page-${index}`))), _jsx("div", { style: { width: `${containerWidth}px` }, className: clsx('swipeable__page', pageClassName, {
295
293
  'is-clone': true,
296
294
  'is-next': currentPage === numPages - 1,
297
- }), children: Children.toArray(children)[0] }, `clone-next-0`)
298
- ] })), _jsx("div", { ref: resizeObserverRef, className: "swipeable__resize-observer" })
299
- ] }));
295
+ }), children: Children.toArray(children)[0] }, `clone-next-0`)] })), _jsx("div", { ref: resizeObserverRef, className: "swipeable__resize-observer" })] }));
300
296
  };
301
297
  export default Swipeable;
@@ -2,16 +2,6 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import clsx from 'clsx';
3
3
  import './style.scss';
4
4
  const Testimonial = ({ quote, author, profession, img, hidden }) => {
5
- return (_jsxs("div", { className: clsx('testimonial', hidden ? 'hidden' : 'show'), children: [
6
- _jsx("img", { className: "testimonial__author-img", src: img, alt: author }), _jsxs("div", { className: "testimonial__content", children: [
7
- _jsxs("svg", { width: "32", height: "32", viewBox: "0 0 32 32", fill: "none", xmlns: "http://www.w3.org/2000/svg", className: "testimonial__quote-icon", children: [
8
- _jsx("path", { d: "M14.6667 24L6.66675 24L6.66675 16L14.6667 16L14.6667 24Z", fill: "#1E1E1E" }), _jsx("path", { d: "M26.6667 24L18.6667 24L18.6667 16L26.6667 16L26.6667 24Z", fill: "#1E1E1E" }), _jsx("path", { d: "M6.66675 24.0001C6.66675 19.5573 6.66675 14.9337 6.66675 10.6686C6.66675 6.40254 10.0001 6.67016 12.0001 6.66987", stroke: "#1E1E1E", strokeWidth: "1.5" }), _jsx("path", { d: "M18.6668 24.0001C18.6667 19.5573 18.6667 14.9337 18.6667 10.6686C18.6667 6.40254 22.0001 6.67016 24.0001 6.66987", stroke: "#1E1E1E", strokeWidth: "1.5" })
9
- ] }), _jsxs("div", { className: "testimonial__text-block", children: [
10
- _jsxs("blockquote", { className: "testimonial__quote", children: ["\u201C", quote, "\u201D"] }), _jsxs("figcaption", { children: [
11
- _jsx("span", { className: "testimonial__author", children: author }), _jsx("span", { className: "testimonial__profession", children: profession })
12
- ] })
13
- ] })
14
- ] })
15
- ] }, author));
5
+ return (_jsxs("div", { className: clsx('testimonial', hidden ? 'hidden' : 'show'), children: [_jsx("img", { className: "testimonial__author-img", src: img, alt: author }), _jsxs("div", { className: "testimonial__content", children: [_jsxs("svg", { width: "32", height: "32", viewBox: "0 0 32 32", fill: "none", xmlns: "http://www.w3.org/2000/svg", className: "testimonial__quote-icon", children: [_jsx("path", { d: "M14.6667 24L6.66675 24L6.66675 16L14.6667 16L14.6667 24Z", fill: "#1E1E1E" }), _jsx("path", { d: "M26.6667 24L18.6667 24L18.6667 16L26.6667 16L26.6667 24Z", fill: "#1E1E1E" }), _jsx("path", { d: "M6.66675 24.0001C6.66675 19.5573 6.66675 14.9337 6.66675 10.6686C6.66675 6.40254 10.0001 6.67016 12.0001 6.66987", stroke: "#1E1E1E", strokeWidth: "1.5" }), _jsx("path", { d: "M18.6668 24.0001C18.6667 19.5573 18.6667 14.9337 18.6667 10.6686C18.6667 6.40254 22.0001 6.67016 24.0001 6.66987", stroke: "#1E1E1E", strokeWidth: "1.5" })] }), _jsxs("div", { className: "testimonial__text-block", children: [_jsxs("blockquote", { className: "testimonial__quote", children: ["\u201C", quote, "\u201D"] }), _jsxs("figcaption", { children: [_jsx("span", { className: "testimonial__author", children: author }), _jsx("span", { className: "testimonial__profession", children: profession })] })] })] })] }, author));
16
6
  };
17
7
  export { Testimonial };
@@ -1,14 +1,14 @@
1
1
  export declare const VARIANTS_MAPPING: {
2
- readonly 'headline-medium': "h1";
3
- readonly 'headline-small': "h2";
4
- readonly 'headline-small-regular': "h2";
5
- readonly 'title-medium': "h3";
6
- readonly 'title-medium-semi-bold': "h3";
7
- readonly 'title-small': "h4";
8
- readonly body: "p";
9
- readonly 'body-small': "p";
10
- readonly 'body-extra-small': "p";
11
- readonly 'body-extra-small-bold': "p";
12
- readonly label: "p";
2
+ readonly 'headline-medium': 'h1';
3
+ readonly 'headline-small': 'h2';
4
+ readonly 'headline-small-regular': 'h2';
5
+ readonly 'title-medium': 'h3';
6
+ readonly 'title-medium-semi-bold': 'h3';
7
+ readonly 'title-small': 'h4';
8
+ readonly body: 'p';
9
+ readonly 'body-small': 'p';
10
+ readonly 'body-extra-small': 'p';
11
+ readonly 'body-extra-small-bold': 'p';
12
+ readonly label: 'p';
13
13
  };
14
- export declare const BOX_MODEL_VALUES: readonly ["mt", "mr", "mb", "ml", "mx", "my", "m", "pt", "pr", "pb", "pl", "px", "py", "p"];
14
+ export declare const BOX_MODEL_VALUES: readonly ['mt', 'mr', 'mb', 'ml', 'mx', 'my', 'm', 'pt', 'pr', 'pb', 'pl', 'px', 'py', 'p'];
@@ -14,13 +14,8 @@ import './style.scss';
14
14
  */
15
15
  const UpsellBanner = props => {
16
16
  const { icon, title, description, primaryCtaLabel, primaryCtaURL, primaryCtaIsExternalLink, primaryCtaOnClick, secondaryCtaLabel, secondaryCtaURL, secondaryCtaIsExternalLink, secondaryCtaOnClick, } = props;
17
- return (_jsx(Card, { isRounded: true, size: "large", children: _jsxs(CardBody, { className: "upsell-banner", size: "large", children: [icon && (_jsx("div", { className: "upsell-banner--icon", children: _jsx("img", { src: icon, alt: "" }) })), _jsxs("div", { className: "upsell-banner--content", children: [
18
- _jsxs("div", { className: "upsell-banner--content-info", children: [
19
- _jsx("h3", { children: title }), _jsx("p", { children: createInterpolateElement(description, {
17
+ return (_jsx(Card, { isRounded: true, size: "large", children: _jsxs(CardBody, { className: "upsell-banner", size: "large", children: [icon && (_jsx("div", { className: "upsell-banner--icon", children: _jsx("img", { src: icon, alt: "" }) })), _jsxs("div", { className: "upsell-banner--content", children: [_jsxs("div", { className: "upsell-banner--content-info", children: [_jsx("h3", { children: title }), _jsx("p", { children: createInterpolateElement(description, {
20
18
  br: _jsx("br", {}),
21
- }) })
22
- ] }), _jsxs("div", { className: "upsell-banner--content-cta", children: [secondaryCtaLabel && secondaryCtaURL && (_jsx(Button, { className: "upsell-banner--content-cta-button secondary", href: secondaryCtaURL, onClick: secondaryCtaOnClick ?? undefined, isExternalLink: secondaryCtaIsExternalLink, children: secondaryCtaLabel })), primaryCtaLabel && primaryCtaURL && (_jsx(Button, { className: "upsell-banner--content-cta-button primary", href: primaryCtaURL, onClick: primaryCtaOnClick ?? undefined, isExternalLink: primaryCtaIsExternalLink, children: primaryCtaLabel }))] })
23
- ] })
24
- ] }) }));
19
+ }) })] }), _jsxs("div", { className: "upsell-banner--content-cta", children: [secondaryCtaLabel && secondaryCtaURL && (_jsx(Button, { className: "upsell-banner--content-cta-button secondary", href: secondaryCtaURL, onClick: secondaryCtaOnClick ?? undefined, isExternalLink: secondaryCtaIsExternalLink, children: secondaryCtaLabel })), primaryCtaLabel && primaryCtaURL && (_jsx(Button, { className: "upsell-banner--content-cta-button primary", href: primaryCtaURL, onClick: primaryCtaOnClick ?? undefined, isExternalLink: primaryCtaIsExternalLink, children: primaryCtaLabel }))] })] })] }) }));
25
20
  };
26
21
  export default UpsellBanner;
@@ -105,9 +105,9 @@
105
105
  // We override only the bits that need to differ from those defaults.
106
106
  float: none;
107
107
  text-align: right;
108
- background: var(--wpds-color-bg-surface-neutral-strong, #fff);
108
+ background: var(--wpds-color-background-surface-neutral-strong, #fff);
109
109
  font-style: italic;
110
- color: var(--wpds-color-fg-content-neutral-weak, #87a6bc);
110
+ color: var(--wpds-color-foreground-content-neutral-weak, #87a6bc);
111
111
  border-bottom: none;
112
112
 
113
113
  @media (max-width: 659px) {
@@ -1,6 +1,7 @@
1
1
  import { Path, SVG, G, Polygon } from '@wordpress/components';
2
2
  import clsx from 'clsx';
3
3
  import { SocialLogo } from 'social-logos';
4
+ import 'social-logos/colors.css';
4
5
  import styles from './style.module.scss';
5
6
  import { BaseIconProps } from './types.ts';
6
7
  import type { ComponentProps, ComponentType, FC, ReactNode } from 'react';