diff --git a/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-circle-stacked-false-inverse-false-1-snap.png b/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-circle-stacked-false-inverse-false-1-snap.png index f06b5608c..6077fc967 100644 Binary files a/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-circle-stacked-false-inverse-false-1-snap.png and b/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-circle-stacked-false-inverse-false-1-snap.png differ diff --git a/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-circle-stacked-false-inverse-true-1-snap.png b/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-circle-stacked-false-inverse-true-1-snap.png index faee30028..c4e34d8e2 100644 Binary files a/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-circle-stacked-false-inverse-true-1-snap.png and b/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-circle-stacked-false-inverse-true-1-snap.png differ diff --git a/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-circle-stacked-true-inverse-false-1-snap.png b/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-circle-stacked-true-inverse-false-1-snap.png index f20b3acf2..fa88e240a 100644 Binary files a/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-circle-stacked-true-inverse-false-1-snap.png and b/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-circle-stacked-true-inverse-false-1-snap.png differ diff --git a/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-circle-stacked-true-inverse-true-1-snap.png b/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-circle-stacked-true-inverse-true-1-snap.png index ad29f701f..8a61fa95e 100644 Binary files a/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-circle-stacked-true-inverse-true-1-snap.png and b/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-circle-stacked-true-inverse-true-1-snap.png differ diff --git a/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-square-stacked-false-inverse-false-1-snap.png b/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-square-stacked-false-inverse-false-1-snap.png index 8b52cb138..355bd89c6 100644 Binary files a/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-square-stacked-false-inverse-false-1-snap.png and b/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-square-stacked-false-inverse-false-1-snap.png differ diff --git a/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-square-stacked-false-inverse-true-1-snap.png b/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-square-stacked-false-inverse-true-1-snap.png index 3b161cdc8..d44c79dd0 100644 Binary files a/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-square-stacked-false-inverse-true-1-snap.png and b/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-square-stacked-false-inverse-true-1-snap.png differ diff --git a/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-square-stacked-true-inverse-false-1-snap.png b/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-square-stacked-true-inverse-false-1-snap.png index db5c00edf..ba5756fc5 100644 Binary files a/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-square-stacked-true-inverse-false-1-snap.png and b/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-square-stacked-true-inverse-false-1-snap.png differ diff --git a/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-square-stacked-true-inverse-true-1-snap.png b/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-square-stacked-true-inverse-true-1-snap.png index 6b0753fe6..56ca2ba46 100644 Binary files a/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-square-stacked-true-inverse-true-1-snap.png and b/src/__screenshot_tests__/__image_snapshots__/stacking-group-screenshot-test-tsx-stacking-group-type-square-stacked-true-inverse-true-1-snap.png differ diff --git a/src/avatar.tsx b/src/avatar.tsx index ef07aeca7..3277cafb1 100644 --- a/src/avatar.tsx +++ b/src/avatar.tsx @@ -43,7 +43,7 @@ type AvatarProps = { /** * Not using TextPresets here because we don't want to scale the avatar text with the device settings */ -const renderText = (size: number, text: string): JSX.Element | null => { +export const renderText = (size: number, text: string): JSX.Element | null => { if (!text) { return null; } diff --git a/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-button-and-link-footer-image-false-1-snap.png b/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-button-and-link-footer-image-false-1-snap.png index 9ddaa5f76..15e8a7027 100644 Binary files a/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-button-and-link-footer-image-false-1-snap.png and b/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-button-and-link-footer-image-false-1-snap.png differ diff --git a/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-button-and-link-footer-image-true-1-snap.png b/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-button-and-link-footer-image-true-1-snap.png index 7b1918918..e2cc070da 100644 Binary files a/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-button-and-link-footer-image-true-1-snap.png and b/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-button-and-link-footer-image-true-1-snap.png differ diff --git a/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-button-footer-image-false-1-snap.png b/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-button-footer-image-false-1-snap.png index d14e59a8c..55c1e3108 100644 Binary files a/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-button-footer-image-false-1-snap.png and b/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-button-footer-image-false-1-snap.png differ diff --git a/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-button-footer-image-true-1-snap.png b/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-button-footer-image-true-1-snap.png index fb6acaa8c..757177b42 100644 Binary files a/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-button-footer-image-true-1-snap.png and b/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-button-footer-image-true-1-snap.png differ diff --git a/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-link-footer-image-false-1-snap.png b/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-link-footer-image-false-1-snap.png index 6c688b8fe..ad93627b6 100644 Binary files a/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-link-footer-image-false-1-snap.png and b/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-link-footer-image-false-1-snap.png differ diff --git a/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-link-footer-image-true-1-snap.png b/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-link-footer-image-true-1-snap.png index e4688a382..38b07b1ab 100644 Binary files a/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-link-footer-image-true-1-snap.png and b/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-link-footer-image-true-1-snap.png differ diff --git a/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-none-footer-image-false-1-snap.png b/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-none-footer-image-false-1-snap.png index 0955811ef..7b27f68f3 100644 Binary files a/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-none-footer-image-false-1-snap.png and b/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-none-footer-image-false-1-snap.png differ diff --git a/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-none-footer-image-true-1-snap.png b/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-none-footer-image-true-1-snap.png index 7d775e24e..37723c560 100644 Binary files a/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-none-footer-image-true-1-snap.png and b/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-actions-none-footer-image-true-1-snap.png differ diff --git a/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-extras-0-1-snap.png b/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-extras-0-1-snap.png index 9ddaa5f76..15e8a7027 100644 Binary files a/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-extras-0-1-snap.png and b/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-extras-0-1-snap.png differ diff --git a/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-extras-1-1-snap.png b/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-extras-1-1-snap.png index f63ab76ad..34748e363 100644 Binary files a/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-extras-1-1-snap.png and b/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-extras-1-1-snap.png differ diff --git a/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-extras-3-1-snap.png b/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-extras-3-1-snap.png index 334010b21..6b803ac56 100644 Binary files a/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-extras-3-1-snap.png and b/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-extras-3-1-snap.png differ diff --git a/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-extras-3-no-divider-1-snap.png b/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-extras-3-no-divider-1-snap.png index 3de229ac7..fa32bd2b1 100644 Binary files a/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-extras-3-no-divider-1-snap.png and b/src/community/__screenshot_tests__/__image_snapshots__/advanced-data-card-screenshot-test-tsx-advanced-data-card-extras-3-no-divider-1-snap.png differ diff --git a/src/community/__screenshot_tests__/__image_snapshots__/blocks-screenshot-test-tsx-blocks-progress-block-2-snap.png b/src/community/__screenshot_tests__/__image_snapshots__/blocks-screenshot-test-tsx-blocks-progress-block-2-snap.png index a9b0c388e..6f184ae6c 100644 Binary files a/src/community/__screenshot_tests__/__image_snapshots__/blocks-screenshot-test-tsx-blocks-progress-block-2-snap.png and b/src/community/__screenshot_tests__/__image_snapshots__/blocks-screenshot-test-tsx-blocks-progress-block-2-snap.png differ diff --git a/src/community/__screenshot_tests__/__image_snapshots__/blocks-screenshot-test-tsx-blocks-row-block-1-snap.png b/src/community/__screenshot_tests__/__image_snapshots__/blocks-screenshot-test-tsx-blocks-row-block-1-snap.png index 5b36b6ef7..b412e4809 100644 Binary files a/src/community/__screenshot_tests__/__image_snapshots__/blocks-screenshot-test-tsx-blocks-row-block-1-snap.png and b/src/community/__screenshot_tests__/__image_snapshots__/blocks-screenshot-test-tsx-blocks-row-block-1-snap.png differ diff --git a/src/stacking-group.tsx b/src/stacking-group.tsx index 996dc2840..076bac2de 100644 --- a/src/stacking-group.tsx +++ b/src/stacking-group.tsx @@ -3,10 +3,10 @@ import * as React from 'react'; import {useIsInverseOrMediaVariant} from './theme-variant-context'; import {vars} from './skins/skin-contract.css'; import Inline from './inline'; -import {Text4} from './text'; import * as styles from './stacking-group.css'; import * as mediaStyles from './image.css'; import {applyCssVars} from './utils/css'; +import {renderText} from './avatar'; type Props = { stacked?: boolean; @@ -31,6 +31,7 @@ const StackingGroup = ({ const size = moreItemsStyle.size; const borderRadius = moreItemsStyle.type === 'circle' ? '50%' : vars.borderRadii.mediaSmall; + const textColor = isInverse ? vars.colors.textPrimaryInverse : vars.colors.textBrand; return (
- - {'+' + moreItemsCount} - + {renderText(size, `+${moreItemsCount}`)}
)}