Skip to content

Commit eb7de93

Browse files
committed
add kitchen sink links on home page
1 parent 57f769e commit eb7de93

8 files changed

Lines changed: 101 additions & 2 deletions

File tree

Lines changed: 1 addition & 0 deletions
Loading
Lines changed: 1 addition & 0 deletions
Loading
Lines changed: 1 addition & 0 deletions
Loading
Lines changed: 1 addition & 0 deletions
Loading
Lines changed: 1 addition & 0 deletions
Loading
Lines changed: 1 addition & 0 deletions
Loading

src/components/landing/TableLanding.tsx

Lines changed: 93 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ import {
2424
} from '@tanstack/react-table'
2525
import { useHotkeys } from '@tanstack/react-hotkeys'
2626
import {
27+
ArrowRightIcon,
2728
BracketsCurlyIcon,
2829
CaretDownIcon,
2930
CaretUpIcon,
@@ -142,6 +143,51 @@ const developerControls = [
142143
'Events & interactions',
143144
] as const
144145

146+
const componentLibraryExamples = [
147+
{
148+
name: 'shadcn/ui + Base UI',
149+
detail: 'Base UI',
150+
logo: '/images/table/component-libraries/shadcn-ui.svg',
151+
href: '/table/latest/docs/framework/react/examples/kitchen-sink-shadcn-base',
152+
},
153+
{
154+
name: 'shadcn/ui + Radix UI',
155+
detail: 'Radix UI',
156+
logo: '/images/table/component-libraries/shadcn-ui.svg',
157+
href: '/table/latest/docs/framework/react/examples/kitchen-sink-shadcn-radix',
158+
},
159+
{
160+
name: 'HeroUI',
161+
detail: 'HeroUI',
162+
logo: '/images/table/component-libraries/hero-ui.svg',
163+
href: '/table/latest/docs/framework/react/examples/kitchen-sink-hero-ui',
164+
},
165+
{
166+
name: 'React Aria',
167+
detail: 'Adobe',
168+
logo: '/images/table/component-libraries/react-aria.svg',
169+
href: '/table/latest/docs/framework/react/examples/kitchen-sink-react-aria',
170+
},
171+
{
172+
name: 'Material UI',
173+
detail: 'MUI',
174+
logo: '/images/table/component-libraries/material-ui.svg',
175+
href: '/table/latest/docs/framework/react/examples/kitchen-sink-material-ui',
176+
},
177+
{
178+
name: 'Mantine',
179+
detail: 'Mantine',
180+
logo: '/images/table/component-libraries/mantine.svg',
181+
href: '/table/latest/docs/framework/react/examples/kitchen-sink-mantine',
182+
},
183+
{
184+
name: 'Chakra UI',
185+
detail: 'Chakra UI',
186+
logo: '/images/table/component-libraries/chakra-ui.svg',
187+
href: '/table/latest/docs/framework/react/examples/kitchen-sink-chakra-ui',
188+
},
189+
] as const
190+
145191
const stateModes: Record<
146192
StateMode,
147193
{ code: string; note: string; path: string }
@@ -237,6 +283,7 @@ export default function TableLanding() {
237283
/>
238284
<OwnershipModel />
239285
</div>
286+
<ComponentLibraryExamples />
240287
</LandingSection>
241288

242289
<LandingSection tone="accent">
@@ -274,6 +321,52 @@ export default function TableLanding() {
274321
)
275322
}
276323

324+
function ComponentLibraryExamples() {
325+
return (
326+
<div className="mt-16 border-t border-border-subtle pt-10 lg:mt-20 lg:pt-12">
327+
<div className="max-w-[42rem]">
328+
<h3 className="text-ds-heading-3 text-text-primary md:text-ds-heading-2">
329+
Already using one of these popular component libraries?
330+
</h3>
331+
<p className="mt-3 text-ds-body-sm text-text-primary/55 sm:text-ds-body-md">
332+
Check out our official component library examples.
333+
</p>
334+
</div>
335+
336+
<div className="mt-8 grid gap-3 sm:grid-cols-2 md:grid-cols-4 xl:grid-cols-7">
337+
{componentLibraryExamples.map((example) => (
338+
<a
339+
key={example.href}
340+
className="group relative flex min-h-28 flex-col items-start rounded-xl border border-border-subtle bg-background-surface p-3 shadow-sm transition-[border-color,box-shadow,transform] hover:-translate-y-0.5 hover:border-[color:rgb(var(--landing-glow)/0.55)] hover:shadow-lg focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--landing-accent-bright)]"
341+
href={example.href}
342+
>
343+
<span className="flex size-12 shrink-0 items-center justify-center rounded-lg border border-black/5 bg-white p-2.5 shadow-sm">
344+
<img
345+
alt=""
346+
aria-hidden="true"
347+
className="size-full object-contain"
348+
src={example.logo}
349+
/>
350+
</span>
351+
<span className="mt-3 min-w-0">
352+
<span className="block text-ds-label-sm text-text-primary">
353+
{example.name}
354+
</span>
355+
<span className="mt-1 block font-ds-mono text-ds-mono-2xs uppercase text-text-primary/40">
356+
{example.detail} example
357+
</span>
358+
</span>
359+
<ArrowRightIcon
360+
aria-hidden="true"
361+
className="absolute right-3 top-3 size-3.5 text-text-primary/35 transition-transform group-hover:translate-x-0.5 group-hover:text-text-primary"
362+
/>
363+
</a>
364+
))}
365+
</div>
366+
</div>
367+
)
368+
}
369+
277370
function TableWorkbench() {
278371
const gridRef = React.useRef<HTMLDivElement>(null)
279372
const [globalFilter, setGlobalFilter] = React.useState('')

src/libraries/libraries.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -295,7 +295,7 @@ export const table: LibrarySlim = {
295295
tagline: 'Headless, type-safe table and data-grid infrastructure',
296296
description:
297297
'Build tables and data grids with feature-level tree shaking, reactive state, fast row models, and complete control over markup and styles.',
298-
badge: undefined,
298+
badge: 'fresh',
299299
repo: 'tanstack/table',
300300
frameworks: [
301301
'angular',
@@ -399,7 +399,7 @@ export const form: LibrarySlim = {
399399
tagline: 'Headless UI for building performant and type-safe forms',
400400
description:
401401
'Headless, performant, and type-safe form state management for TS/JS, React, Preact, Vue, Angular, Solid, Lit and Svelte.',
402-
badge: 'new',
402+
badge: undefined,
403403
repo: 'tanstack/form',
404404
corePackageName: '@tanstack/form-core',
405405
npmPackageNames: ['@tanstack/form-core'],

0 commit comments

Comments
 (0)