Skip to content

Commit 7d0ddf8

Browse files
committed
A few updates
1 parent 6b1fb45 commit 7d0ddf8

File tree

4 files changed

+33
-21
lines changed

4 files changed

+33
-21
lines changed

packages/dev/s2-docs/pages/s2/home/ExampleApp.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -293,6 +293,7 @@ export function AppFrame({children, inert, hidden, page, onPageChange}: any) {
293293
<Sidebar page={page} onPageChange={onPageChange} />
294294
<div
295295
data-content
296+
inert={!children}
296297
className={style({
297298
gridArea: 'content',
298299
backgroundColor: 'base',

packages/dev/s2-docs/pages/s2/home/Home.tsx

Lines changed: 23 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -256,8 +256,8 @@ export function Home() {
256256
<span className={swapSizer} aria-hidden>with React Spectrum</span>
257257
</span>
258258
</h1>
259-
<p className={style({font: 'body-3xl', marginY: 0, color: 'white'})}>React Spectrum empowers you to build high quality, accessible, cohesive apps with Adobe's signature design</p>
260-
<div className={style({display: 'flex', gap: 16, flexDirection: {default: 'column', sm: 'row'}, marginTop: 32, marginBottom: 56})}>
259+
<p className={style({font: 'body-3xl', marginY: 0, color: 'white', textWrap: 'balance'})}>React Spectrum empowers you to build high quality, accessible, cohesive apps with Adobe's signature design.</p>
260+
<div className={style({display: 'flex', gap: 16, flexDirection: {default: 'column', sm: 'row'}, marginTop: 32, marginBottom: 96})}>
261261
<LinkButton size="XL" staticColor="white" href="getting-started">Get started</LinkButton>
262262
<LinkButton size="XL" staticColor="white" variant="secondary" href="react-spectrum">Explore components</LinkButton>
263263
</div>
@@ -271,7 +271,7 @@ export function Home() {
271271
description="React Spectrum makes interfaces more accessible, flexible, and easier to maintain, while giving users a seamless experience no matter where they are.">
272272
<Feature
273273
title="Dark mode"
274-
description="Deliver effortless dark and light mode support with no extra styling needed."
274+
description="Deliver effortless light and dark mode support with no extra styling needed."
275275
illustration={<Lightbulb />}
276276
styles={style({gridColumnStart: {default: 'span 6', lg: 'span 3', xl: 'span 4'}})}>
277277
<DarkMode />
@@ -285,7 +285,7 @@ export function Home() {
285285
</Feature>
286286
<Feature
287287
title="Global ready by default"
288-
description="Automatically mirrors component layouts, and formats text for different languages, currencies, dates, and locales."
288+
description="Component layouts automatically mirrors, and format text for different languages, currencies, dates, and locales."
289289
illustration={<Translate />}
290290
styles={style({gridColumnStart: {default: 'span 6', lg: 'span 3'}})}>
291291
<Provider
@@ -325,14 +325,14 @@ export function Home() {
325325
</Feature> */}
326326
<Feature
327327
title="High contrast mode"
328-
description="Support for high contrast mode included, ensuring a clear and readable experience based on preference."
328+
description="Support for high contrast mode is included, ensuring a clear and readable experience based on preference."
329329
illustration={<Accessibility />}
330330
styles={style({gridColumnStart: {default: 'span 6', lg: 'span 3', xl: 'span 2'}})}>
331331
<HCM />
332332
</Feature>
333333
<Feature
334334
title="Adaptive font sizes"
335-
description="Fonts scale automatically according to user preferences and screen size, fully compatible with rem-based typography, allowing your text to scale naturally."
335+
description="Fonts scale automatically according to user preferences and screen size using rem-based typography, allowing your text to scale naturally."
336336
illustration={<TextIcon />}
337337
styles={style({gridColumnStart: {default: 'span 6', lg: 'span 3', xl: 'span 4'}})}>
338338
<Rems />
@@ -356,28 +356,28 @@ export function Home() {
356356
<SubmenuAnimation />
357357
</Feature>
358358
</Section> */}
359-
<Section title="Everything you need to build beautiful apps" description="Bring your interface to life with expressive icons, Spectrum colors, and rich illustrations. Every detail works together to make your product look polished and on-brand.">
359+
<Section title="Everything you need to build beautiful apps." description="Bring your interface to life with expressive icons, Spectrum colors, and rich illustrations. Every detail works together to make your product look polished and on-brand.">
360360
<Feature
361361
title="Icons"
362-
description="Spectrum icon support for your product. Use the icon search to simplify finding the right icon the right experience."
362+
description={<>With hundreds of Spectrum icons to choose from, use our <Link href="icons" variant="secondary">icon search</Link> to find the right icon for the right experience.</>}
363363
illustration={<VectorDraw />}
364364
styles={style({gridColumnStart: {default: 'span 6', lg: 'span 3'}})}>
365365
<Icons />
366366
</Feature>
367367
<Feature
368368
title="Illustrations"
369-
description="Rich illustrations that help bring your interface to life. Use the illustration search to find the right illustration for your product."
369+
description={<>Rich illustrations help bring your interface to life. Use our <Link href="illustrations" variant="secondary">illustration search</Link> to find the right illustration for your product.</>}
370370
illustration={<IllustrationIcon />}
371371
styles={style({gridColumnStart: {default: 'span 6', lg: 'span 3'}})}>
372372
<Illustrations />
373373
</Feature>
374374
</Section>
375375
<Section
376-
title={<>Rapidly style custom components with Style Macros</>}
376+
title={<>Rapidly style custom components with Style Macros.</>}
377377
description={<>Easily use Spectrum tokens like colors, spacing, and typography in your own custom components with style macros. Styles are <strong>colocated</strong> with your component code, allowing you to <strong>develop more efficiently</strong> and <strong>refactor with confidence</strong> – no more CSS conflicts or specificity issues. Style macros generate atomic CSS at build time, so you get tiny bundle sizes and fast runtime performance.</>}>
378378
<Feature
379379
title="Colors"
380-
description="Access the full range of Spectrum color tokens when you need them."
380+
description="Convenient access to the full range of Spectrum color tokens."
381381
illustration={<Color />}
382382
styles={style({gridColumnStart: {default: 'span 6', lg: 'span 3', xl: 'span 2'}})}>
383383
<ColorScales />
@@ -469,14 +469,14 @@ const buttonStyle = style({
469469
</Feature>
470470
<Feature
471471
title="Responsive design"
472-
description="Adaptive UI built on Spectrum's responsive layout definitions.... *needs work"
472+
description="Adapt your application for any screen size using our built-in breakpoints, or define your own."
473473
illustration={<Phone />}
474474
style={{gridColumn: 'span 6'}}>
475475
<Responsive />
476476
</Feature>
477477
</Section>
478478
<Section
479-
title="Built for modern development and the modern web"
479+
title="Built for modern development and the modern web."
480480
description="With AI-ready documentation, server side and runtime performance optimizations, React Spectrum helps you build modern, scalable apps without compromise.">
481481
<Feature
482482
title="AI-ready"
@@ -487,19 +487,26 @@ const buttonStyle = style({
487487
</Feature>
488488
<Feature
489489
title="SSR"
490-
description="Server-side rendering and React Server Components support, maximizing Core Web Vitals with zero layout thrashing."
490+
description="Server-side rendering and React Server Components support, maximizing Core Web Vitals."
491491
illustration={<Server />}
492492
styles={style({gridColumnStart: {default: 'span 6', lg: 'span 2'}})}>
493493

494494
</Feature>
495495
<Feature
496496
title="Small bundle"
497-
description="Aggressive tree-shaking and atomic CSS resulting in reduced bundle sizes and faster runtime performance."
497+
description="Aggressive tree-shaking and atomic CSS result in small bundle sizes and fast runtime performance."
498498
illustration={<SpeedFast />}
499499
styles={style({gridColumnStart: {default: 'span 6', lg: 'span 2'}})}>
500500

501501
</Feature>
502502
</Section>
503+
<section className={style({paddingY: 64})}>
504+
<h2 className={style({font: 'heading-2xl', color: 'white'})}>Ready to get started?</h2>
505+
<div className={style({display: 'flex', gap: 16, flexDirection: {default: 'column', sm: 'row'}})}>
506+
<LinkButton size="XL" staticColor="white" href="getting-started">Install and setup</LinkButton>
507+
<LinkButton size="XL" staticColor="white" variant="secondary" href="react-spectrum">Explore components</LinkButton>
508+
</div>
509+
</section>
503510
</main>
504511
<footer
505512
className={style({
@@ -537,7 +544,7 @@ function Section({title, description, children}: any) {
537544
return (
538545
<section aria-labelledby={headingId} className={style({paddingY: 64})}>
539546
<h2 id={headingId} className={style({font: 'heading-2xl', color: 'white'})}>{title}</h2>
540-
<p className={style({font: 'body-2xl', color: 'white', maxWidth: '80%', marginBottom: 64})}>{description}</p>
547+
<p className={style({font: 'body-2xl', color: 'white', maxWidth: '80%', marginBottom: 64, textWrap: 'balance'})}>{description}</p>
541548
<div className={style({display: 'grid', gridTemplateColumns: 'repeat(6, 1fr)', gap: 16})}>
542549
{children}
543550
</div>

packages/dev/s2-docs/pages/s2/home/States.tsx

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -60,8 +60,12 @@ export function States() {
6060
className={style({
6161
gridArea: 'props',
6262
display: 'flex',
63-
alignItems: 'center',
64-
columnGap: 16
63+
flexDirection: 'column',
64+
alignItems: {
65+
default: 'center',
66+
xl: 'start'
67+
},
68+
gap: 16
6569
})}>
6670
<Picker
6771
label="Variant"

packages/dev/s2-docs/pages/s2/index.mdx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import '../../src/client';
2-
import '@react-spectrum/s2/page.css';
32
import {Home} from './home/Home';
3+
import {Provider} from '@react-spectrum/s2';
44
import rspFavicon from 'url:../../assets/favicon.ico';
55

66
export const section = 'Overview';
@@ -9,7 +9,7 @@ export const description = 'Build high quality, accessible UI with the cohesive
99
export const omitFromNav = true;
1010
export const hideFromSearch = true;
1111

12-
<html lang="en">
12+
<Provider elementType="html" locale="en">
1313
<head>
1414
<meta charSet="utf-8" />
1515
<meta name="viewport" content="width=device-width, initial-scale=1" />
@@ -47,4 +47,4 @@ export const hideFromSearch = true;
4747
)}} />
4848
</head>
4949
<Home />
50-
</html>
50+
</Provider>

0 commit comments

Comments
 (0)