Skip to content

An open source design system that's fully customizable and agent ready

TypeScript

Update Foundations cards with custom images, reorder, and add CLI page (#1719)

rubyycheunga6e198969fc0
diff --git a/apps/sandbox/public/docsite/FoundationsColors.png b/apps/sandbox/public/docsite/FoundationsColors.png
new file mode 100644
index 0000000000..8289c3696d
Binary files /dev/null and b/apps/sandbox/public/docsite/FoundationsColors.png differ
diff --git a/apps/sandbox/public/docsite/FoundationsIcons.png b/apps/sandbox/public/docsite/FoundationsIcons.png
new file mode 100644
index 0000000000..25f0440c7d
Binary files /dev/null and b/apps/sandbox/public/docsite/FoundationsIcons.png differ
diff --git a/apps/sandbox/public/docsite/FoundationsIllustrations.png b/apps/sandbox/public/docsite/FoundationsIllustrations.png
new file mode 100644
index 0000000000..66956c678b
Binary files /dev/null and b/apps/sandbox/public/docsite/FoundationsIllustrations.png differ
diff --git a/apps/sandbox/public/docsite/FoundationsShape.png b/apps/sandbox/public/docsite/FoundationsShape.png
new file mode 100644
index 0000000000..bb0d20642e
Binary files /dev/null and b/apps/sandbox/public/docsite/FoundationsShape.png differ
diff --git a/apps/sandbox/public/docsite/FoundationsSpacing.png b/apps/sandbox/public/docsite/FoundationsSpacing.png
new file mode 100644
index 0000000000..31e42ead58
Binary files /dev/null and b/apps/sandbox/public/docsite/FoundationsSpacing.png differ
diff --git a/apps/sandbox/public/docsite/FoundationsTypogrpahy.png b/apps/sandbox/public/docsite/FoundationsTypogrpahy.png
new file mode 100644
index 0000000000..ae7225b79f
Binary files /dev/null and b/apps/sandbox/public/docsite/FoundationsTypogrpahy.png differ
diff --git a/apps/sandbox/src/app/(fullscreen)/pages/docsite/DocsView.tsx b/apps/sandbox/src/app/(fullscreen)/pages/docsite/DocsView.tsx
index 235f901c4f..261e04bb18 100644
--- a/apps/sandbox/src/app/(fullscreen)/pages/docsite/DocsView.tsx
+++ b/apps/sandbox/src/app/(fullscreen)/pages/docsite/DocsView.tsx
@@ -71,42 +71,49 @@ const FOUNDATION_ITEMS: {
key: string;
title: string;
description: string;
+ image: string;
}[] = [
+ {
+ key: 'typography',
+ title: 'Typography',
+ image: `${basePath}/docsite/FoundationsTypogrpahy.png`,
+ description:
+ 'A type scale from display-1 down to supporting text, with weight and color options. Establishes visual hierarchy without guessing font sizes.',
+ },
{
key: 'colors',
title: 'Colors',
+ image: `${basePath}/docsite/FoundationsColors.png`,
description:
'A semantic palette that adapts across themes. Use surface, text, border, and accent tokens instead of raw hex values so your UI stays consistent in light, dark, and custom themes.',
},
{
- key: 'typography',
- title: 'Typography',
+ key: 'shape',
+ title: 'Shape',
+ image: `${basePath}/docsite/FoundationsShape.png`,
description:
- 'A type scale from display-1 down to supporting text, with weight and color options. Establishes visual hierarchy without guessing font sizes.',
+ 'Border radius tokens from sharp (2px) to fully rounded (pill). Controls, cards, and containers each have a designated radius so shapes feel intentional.',
},
{
key: 'spacing',
title: 'Spacing',
+ image: `${basePath}/docsite/FoundationsSpacing.png`,
description:
'A 4px-based scale (0–10) used for padding, margins, and gaps. Keeps layouts aligned to a consistent rhythm across every component and page.',
},
{
- key: 'radius',
- title: 'Radius',
- description:
- 'Border radius tokens from sharp (2px) to fully rounded (pill). Controls, cards, and containers each have a designated radius so shapes feel intentional.',
- },
- {
- key: 'motion',
- title: 'Motion',
+ key: 'icons',
+ title: 'Icons',
+ image: `${basePath}/docsite/FoundationsIcons.png`,
description:
- 'Duration and easing presets for transitions and animations. Fast (150ms) for micro-interactions, medium (250ms) for panels, slow (400ms) for page transitions.',
+ 'A consistent icon set built for XDS components. Semantic and non-semantic color options with multiple sizes.',
},
{
- key: 'elevation',
- title: 'Elevation',
+ key: 'illustrations',
+ title: 'Illustrations',
+ image: `${basePath}/docsite/FoundationsIllustrations.png`,
description:
- 'Layered shadow tokens that communicate depth. Cards sit at level 1, popovers at level 2, dialogs at level 3 — no manual box-shadow needed.',
+ 'Illustration guidelines and assets for empty states, onboarding, and feature highlights.',
},
];
@@ -1403,10 +1410,10 @@ function LibraryOverview({
gap={0}
hAlign="center"
style={{flex: 1, minWidth: 0, textAlign: 'center'}}>
- <XDSText type="display-1">
+ <XDSText type="display-1" style={{fontSize: '3.25rem'}}>
XDS OSS
<br />
- for building with AI
+ Build with AI
</XDSText>
<XDSStack direction="horizontal" gap={3} style={{marginTop: 28}}>
<XDSButton
@@ -1440,37 +1447,32 @@ function LibraryOverview({
style={{
display: 'grid',
gridTemplateColumns: 'repeat(3, 1fr)',
- gap: 16,
+ columnGap: 16,
+ rowGap: 32,
}}>
{FOUNDATION_ITEMS.map(item => (
<div
key={item.key}
onClick={() => onSelectComponent(item.key)}
style={{cursor: 'pointer'}}>
- <XDSCard padding={0}>
- <img
- src={`${basePath}/docsite/foundation-preview.png`}
- alt={item.title}
- style={{
- display: 'block',
- width: '100%',
- aspectRatio: '16 / 9',
- objectFit: 'cover',
- borderRadius: '12px 12px 0 0',
- }}
- />
- <XDSStack
- direction="vertical"
- gap={1}
- style={{padding: '16px 20px'}}>
- <XDSText type="body" weight="bold">
- {item.title}
- </XDSText>
- <XDSText type="supporting" color="secondary">
- {item.description}
- </XDSText>
- </XDSStack>
- </XDSCard>
+ <img
+ src={item.image}
+ alt={item.title}
+ style={{
+ display: 'block',
+ width: '100%',
+ aspectRatio: '16 / 9',
+ objectFit: 'cover',
+ borderRadius: 12,
+ marginBottom: 12,
+ }}
+ />
+ <XDSText type="body" weight="bold" style={{display: 'block', marginBottom: 4}}>
+ {item.title}
+ </XDSText>
+ <XDSText type="supporting" color="secondary">
+ {item.description}
+ </XDSText>
</div>
))}
</div>
@@ -1513,54 +1515,43 @@ function LibraryOverview({
<div
key={pkg.key}
onClick={() => onSelectComponent(pkg.key)}
- style={{cursor: 'pointer', height: '100%'}}>
- <XDSCard padding={0} style={{height: '100%'}}>
- <div
- style={{
- aspectRatio: '16 / 9',
- backgroundColor:
- 'var(--color-background-accent-muted, #DBEAFE)',
- borderRadius: '12px 12px 0 0',
- display: 'flex',
- alignItems: 'center',
- justifyContent: 'center',
- position: 'relative',
- }}>
- <XDSIcon icon={IconComp} size="lg" color="accent" />
- {pkg.status === 'Coming Soon' && (
- <div style={{position: 'absolute', top: 12, right: 12}}>
- <XDSBadge label="Coming Soon" variant="info" />
- </div>
- )}
- </div>
- <XDSStack
- direction="vertical"
- gap={1}
- style={{padding: '16px 20px'}}>
- <XDSStack
- direction="horizontal"
- gap={2}
- style={{alignItems: 'baseline'}}>
- <XDSText
- type="body"
- weight="bold"
- style={{fontFamily: 'monospace', fontSize: 14}}>
- {pkg.name}
- </XDSText>
- {pkg.version && (
- <XDSText
- type="supporting"
- color="secondary"
- style={{fontFamily: 'monospace', fontSize: 12}}>
- v{pkg.version}
- </XDSText>
- )}
- </XDSStack>
- <XDSText type="supporting" color="secondary">
- {pkg.description}
+ style={{cursor: 'pointer'}}>
+ <div
+ style={{
+ aspectRatio: '16 / 9',
+ backgroundColor:
+ 'var(--color-background-accent-muted, #DBEAFE)',
+ borderRadius: 12,
+ display: 'flex',
+ alignItems: 'center',
+ justifyContent: 'center',
+ position: 'relative',
+ marginBottom: 12,
+ }}>
+ <XDSIcon icon={IconComp} size="lg" color="accent" />
+ {pkg.status === 'Coming Soon' && (
+ <div style={{position: 'absolute', top: 12, right: 12}}>
+ <XDSBadge label="Coming Soon" variant="info" />
+ </div>
+ )}
+ </div>
+ <XDSText
+ type="body"
+ weight="bold"
+ style={{fontFamily: 'monospace', fontSize: 14, display: 'block', marginBottom: 4}}>
+ {pkg.name}
+ {pkg.version && (
+ <XDSText
+ type="supporting"
+ color="secondary"
+ style={{fontFamily: 'monospace', fontSize: 12, marginLeft: 8}}>
+ v{pkg.version}
</XDSText>
- </XDSStack>
- </XDSCard>
+ )}
+ </XDSText>
+ <XDSText type="supporting" color="secondary">
+ {pkg.description}
+ </XDSText>
</div>
);
})}