feat: landing page shows full demos inline, sidebar lists all components

This commit is contained in:
sunzhongyi
2026-05-21 13:38:34 +08:00
parent 60831e07aa
commit 9f36e2c0ef
2 changed files with 694 additions and 167 deletions
+651 -161
View File
@@ -1,219 +1,709 @@
'use client';
import {
Layout, Section, Article, Masthead, Rule, Folio, IndexBox, Factbox,
Headline, Subhead, Kicker, BodyText, Byline, Dateline,
Figure, PullQuote, Footer, BreakingNewsBanner,
Layout, Section, Article, Rule, BodyText, Figure,
Masthead, Headline, Subhead, Kicker, Byline, Dateline,
PullQuote,
} from 'newspaperui';
import Link from 'next/link';
export default function LandingPage() {
return (
<Layout columns={24} maxWidth="1400px" padding="1.5rem">
{/* Breaking News Banner */}
<BreakingNewsBanner label="NEW">
v0.1.0 released 24 components, multi-language blocks, responsive grid, theme customization
</BreakingNewsBanner>
<div>
{/* Hero */}
<div style={{
background: 'var(--nui-bg-surface)',
borderBottom: '2px solid var(--nui-rule-decorative)',
padding: '3rem 2rem 2rem',
textAlign: 'center',
}}>
<div style={{
fontFamily: 'var(--font-family-meta)',
fontSize: '11px',
fontVariantCaps: 'small-caps',
letterSpacing: '0.1em',
color: 'var(--nui-accent-primary)',
marginBottom: '0.5rem',
}}>Production Newspaper Components</div>
<h1 style={{
fontFamily: 'var(--font-family-masthead)',
fontSize: 'clamp(48px, 8vw, 96px)',
fontWeight: 700,
lineHeight: 1,
letterSpacing: '0.02em',
color: 'var(--nui-text-primary)',
margin: '0 0 1rem 0',
}}>NewspaperUI</h1>
<p style={{
fontFamily: 'var(--font-family-body)',
fontSize: '18px',
lineHeight: 1.5,
color: 'var(--nui-text-secondary)',
maxWidth: '700px',
margin: '0 auto 1.5rem',
}}>
24 React components · CSS Grid + Multi-column · / English /
</p>
<div style={{ display: 'flex', justifyContent: 'center', gap: '1rem', fontFamily: 'var(--font-family-meta)', fontSize: '13px' }}>
<Link href="/grid-system" style={{ color: 'var(--nui-accent-primary)', textDecoration: 'none', fontWeight: 600 }}>Documentation </Link>
<Link href="/create" style={{ color: 'var(--nui-text-secondary)', textDecoration: 'none' }}>Create Theme</Link>
<Link href="/blocks" style={{ color: 'var(--nui-text-secondary)', textDecoration: 'none' }}>All Blocks</Link>
<a href="https://github.com/joisun/newspaperui" style={{ color: 'var(--nui-text-muted)', textDecoration: 'none' }}>GitHub</a>
</div>
</div>
{/* Masthead */}
{/* Demo 1: Chinese */}
<DemoSection label="CHINESE · 中文" sublabel="人民周报 · Noto Serif SC · 克制朱红">
<ZhFrontpageDemo />
</DemoSection>
{/* Demo 2: English */}
<DemoSection label="ENGLISH" sublabel="The Daily Chronicle · Source Serif 4 · NYT Style">
<EnFrontpageDemo />
</DemoSection>
{/* Demo 3: Japanese */}
<DemoSection label="JAPANESE · 日本語" sublabel="朝日新聞 · Noto Serif JP · 横組み">
<JpFrontpageDemo />
</DemoSection>
</div>
);
}
function DemoSection({ label, sublabel, children }: { label: string; sublabel: string; children: React.ReactNode }) {
return (
<div style={{ borderBottom: '1px solid var(--nui-rule-hairline)' }}>
<div style={{
background: 'var(--nui-bg-surface)',
padding: '1rem 2rem',
display: 'flex',
justifyContent: 'space-between',
alignItems: 'baseline',
borderBottom: '1px solid var(--nui-rule-hairline)',
}}>
<span style={{
fontFamily: 'var(--font-family-meta)',
fontSize: '11px',
fontWeight: 700,
fontVariantCaps: 'small-caps',
letterSpacing: '0.1em',
color: 'var(--nui-accent-primary)',
}}>{label}</span>
<span style={{
fontFamily: 'var(--font-family-meta)',
fontSize: '11px',
color: 'var(--nui-text-muted)',
}}>{sublabel}</span>
</div>
<div style={{ maxWidth: '1400px', margin: '0 auto' }}>
{children}
</div>
</div>
);
}
/* ============================================================
* DEMO: Chinese Front Page (人民周报)
* ============================================================ */
const cn = { fontFamily: 'var(--font-family-cjk-serif)' };
const cnRed = { color: 'var(--nui-accent-cjk-red)' };
function ZhFrontpageDemo() {
return (
<Layout columns={24} maxWidth="1280px" padding="1.5rem 1rem">
{/* 报头 */}
<header style={{
textAlign: 'center',
borderTop: '4px solid var(--nui-accent-cjk-red)',
borderBottom: '1px solid var(--nui-rule-decorative)',
paddingTop: '1rem',
paddingBottom: '0.5rem',
}}>
<div style={{
fontFamily: 'var(--font-family-meta)',
fontSize: '11px',
color: 'var(--nui-text-muted)',
letterSpacing: '0.2em',
marginBottom: '0.25rem',
}}>RENMIN ZHOUBAO · </div>
<h1 style={{
...cn,
...cnRed,
fontSize: '88px',
fontWeight: 900,
margin: 0,
letterSpacing: '0.1em',
lineHeight: 1,
}}></h1>
<div style={{
...cn,
display: 'flex',
justifyContent: 'space-between',
fontSize: '12px',
color: 'var(--nui-text-secondary)',
padding: '0.5rem 1rem',
borderTop: '1px solid var(--nui-rule-hairline)',
marginTop: '0.5rem',
}}>
<span> 2026 · 5891 </span>
<span>2026 5 19 · · </span>
<span> 5 · 260 </span>
</div>
</header>
{/* 版面导航条 */}
<div style={{
...cn,
display: 'flex',
gap: '0',
fontSize: '12px',
borderTop: '1px solid var(--nui-rule-hairline)',
borderBottom: '1px solid var(--nui-rule-hairline)',
marginTop: '1rem',
}}>
{['01版 要闻', '02版 经济', '03版 国际', '04版 文化', '05版 体育', '06版 副刊'].map((v, i) => (
<div key={i} style={{
padding: '0.4rem 1rem',
borderRight: '1px solid var(--nui-rule-hairline)',
color: i === 0 ? 'var(--nui-accent-cjk-red)' : 'var(--nui-text-secondary)',
fontWeight: i === 0 ? 700 : 400,
cursor: 'pointer',
}}>{v}</div>
))}
</div>
{/* 头条区 */}
<Section columns={24} gap="1rem" style={{ marginTop: '1rem', paddingBottom: '1rem', borderBottom: '2px solid var(--nui-rule-decorative)' }}>
<Article span={24}>
<div style={{ ...cn, ...cnRed, fontSize: '13px', fontWeight: 700, marginBottom: '0.5rem', textAlign: 'center', letterSpacing: '0.1em' }}></div>
<h2 style={{ ...cn, fontSize: '56px', fontWeight: 900, lineHeight: 1.1, color: 'var(--nui-text-primary)', textAlign: 'center', margin: 0 }}>
</h2>
<h3 style={{ ...cn, fontSize: '24px', fontWeight: 500, lineHeight: 1.4, color: 'var(--nui-text-secondary)', textAlign: 'center', margin: '0.5rem 0 1rem 0' }}>
</h3>
<div style={{ ...cn, textAlign: 'center', fontSize: '12px', color: 'var(--nui-text-muted)', marginBottom: '1rem' }}>
·
</div>
<Figure
src="https://images.unsplash.com/photo-1529107386315-e1a2ed48a620?auto=format&fit=crop&w=1200&q=80"
alt="签署仪式现场"
caption="各国代表在布鲁塞尔会议中心签署协定。"
credit="新华社记者 摄"
style={{ marginBottom: '1rem' }}
/>
<BodyText weight="Medium" columns={3} dropCap style={cn}>
<p> </p>
<p> 2040 2028 </p>
<p> 1.2% 0.7%</p>
<p></p>
<p>便</p>
<p></p>
<p></p>
<p> 2028 </p>
<p> 18 20 </p>
</BodyText>
</Article>
</Section>
{/* 二条区:3 栏并列 */}
<Section columns={24} gap="1rem" style={{ marginTop: '1rem', paddingBottom: '1rem', borderBottom: '1px solid var(--nui-rule-decorative)' }}>
<Article span={8} style={{ border: '1px solid var(--nui-rule-hairline)', padding: '1rem', background: 'var(--nui-bg-surface)' }}>
<div style={{ ...cn, ...cnRed, fontSize: '12px', fontWeight: 700, marginBottom: '0.5rem' }}> </div>
<h3 style={{ ...cn, fontSize: '22px', fontWeight: 700, lineHeight: 1.3, color: 'var(--nui-text-primary)', margin: '0 0 0.5rem 0' }}></h3>
<BodyText weight="Low" style={cn}>
<p></p>
<p></p>
</BodyText>
<Rule variant="hairline" style={{ margin: '0.75rem 0' }} />
<h4 style={{ ...cn, fontSize: '17px', fontWeight: 600, lineHeight: 1.3, margin: '0 0 0.4rem 0' }}>线</h4>
<BodyText weight="Low" style={cn}>
<p>亿线线 A8 </p>
</BodyText>
<Rule variant="hairline" style={{ margin: '0.75rem 0' }} />
<h4 style={{ ...cn, fontSize: '17px', fontWeight: 600, lineHeight: 1.3, margin: '0 0 0.4rem 0' }}></h4>
<BodyText weight="Low" style={cn}>
<p> A10</p>
</BodyText>
</Article>
<Article span={8} style={{ border: '1px solid var(--nui-rule-hairline)', padding: '1rem', background: 'var(--nui-bg-surface)' }}>
<div style={{ ...cn, ...cnRed, fontSize: '12px', fontWeight: 700, marginBottom: '0.5rem' }}> </div>
<h3 style={{ ...cn, fontSize: '22px', fontWeight: 700, lineHeight: 1.3, color: 'var(--nui-text-primary)', margin: '0 0 0.5rem 0' }}> PMI </h3>
<BodyText weight="Low" style={cn}>
<p> 52.4</p>
<p></p>
</BodyText>
<Rule variant="hairline" style={{ margin: '0.75rem 0' }} />
<h4 style={{ ...cn, fontSize: '17px', fontWeight: 600, lineHeight: 1.3, margin: '0 0 0.4rem 0' }}> 3.7%</h4>
<BodyText weight="Low" style={cn}>
<p></p>
</BodyText>
<Rule variant="hairline" style={{ margin: '0.75rem 0' }} />
<h4 style={{ ...cn, fontSize: '17px', fontWeight: 600, lineHeight: 1.3, margin: '0 0 0.4rem 0' }}></h4>
<BodyText weight="Low" style={cn}>
<p></p>
</BodyText>
</Article>
<Article span={8} style={{ border: '1px solid var(--nui-rule-hairline)', padding: '1rem', background: 'var(--nui-bg-surface)' }}>
<div style={{ ...cn, ...cnRed, fontSize: '12px', fontWeight: 700, marginBottom: '0.5rem' }}> · </div>
<h3 style={{ ...cn, fontSize: '22px', fontWeight: 700, lineHeight: 1.3, color: 'var(--nui-text-primary)', margin: '0 0 0.5rem 0' }}></h3>
<BodyText weight="Low" style={cn}>
<p>殿</p>
<p></p>
</BodyText>
<Rule variant="hairline" style={{ margin: '0.75rem 0' }} />
<h4 style={{ ...cn, fontSize: '17px', fontWeight: 600, lineHeight: 1.3, margin: '0 0 0.4rem 0' }}></h4>
<BodyText weight="Low" style={cn}>
<p> 18%</p>
</BodyText>
<Rule variant="hairline" style={{ margin: '0.75rem 0' }} />
<h4 style={{ ...cn, fontSize: '17px', fontWeight: 600, lineHeight: 1.3, margin: '0 0 0.4rem 0' }}></h4>
<BodyText weight="Low" style={cn}>
<p></p>
</BodyText>
</Article>
</Section>
{/* 简讯 + 要点提示 */}
<Section columns={24} gap="1rem" style={{ marginTop: '1rem' }}>
<Article span={6} style={{ background: 'var(--nui-bg-surface)', padding: '1rem', borderLeft: '3px solid var(--nui-accent-cjk-red)' }}>
<div style={{ ...cn, ...cnRed, fontSize: '11px', fontWeight: 700, marginBottom: '0.5rem', letterSpacing: '0.1em' }}></div>
<ul style={{ ...cn, fontSize: '14px', lineHeight: 1.7, paddingLeft: '1.2em', margin: 0, color: 'var(--nui-text-body)' }}>
<li> · A2</li>
<li> · A4</li>
<li> · B1</li>
<li> · C3</li>
<li> · C5</li>
<li> · D2</li>
<li> · E1</li>
<li> · F4</li>
</ul>
</Article>
<Article span={18}>
<div style={{ ...cn, ...cnRed, fontSize: '12px', fontWeight: 700, marginBottom: '0.5rem' }}> · </div>
<BodyText weight="Low" columns={4} style={cn}>
<p><strong></strong> 8000 西</p>
<p><strong></strong> </p>
<p><strong></strong> 退</p>
<p><strong>广</strong> 500 亿</p>
<p><strong></strong> </p>
<p><strong></strong> </p>
<p><strong></strong> </p>
<p><strong></strong> </p>
<p><strong></strong> 25 </p>
</BodyText>
</Article>
</Section>
</Layout>
);
}
/* ============================================================
* DEMO: English Front Page (The Daily Chronicle)
* ============================================================ */
function EnFrontpageDemo() {
return (
<Layout columns={24} maxWidth="1200px" padding="2rem 1.5rem">
<Masthead
variant="classic"
kicker="Production Newspaper Components for the Modern Web"
title="NewspaperUI"
edition="Vol. 01 · No. 1"
date="May 2026"
price="MIT License · Open Source"
kicker="Late City Edition"
title="The Daily Chronicle"
edition="Vol. CXLIX · No. 51,895"
date="Tuesday, May 19, 2026"
price="$4.00"
/>
{/* Main Content: 5 + 14 + 5 layout */}
<Section columns={24} gap="1.5rem" style={{ marginTop: '1.5rem' }}>
{/* Left sidebar: Index + Quick links */}
<Article span={5} style={{ borderRight: '1px solid var(--nui-rule-hairline)', paddingRight: '1rem' }}>
<IndexBox title="Navigate" items={[
{ page: '→', title: 'Docs', headline: 'Grid system & API reference' },
{ page: '→', title: 'Blocks', headline: '6 multi-language demos' },
{ page: '→', title: 'Create', headline: 'Theme customizer' },
{ page: '→', title: 'GitHub', headline: 'Source code & issues' },
]} />
<Section columns={24} divider="bottom" gap="2rem" style={{ marginTop: '2rem' }}>
<Article span={5} style={{ borderRight: '1px solid var(--nui-rule-hairline)', paddingRight: '1.5rem' }}>
<Kicker>Inside Today</Kicker>
<Headline weight="Low" as="h3" style={{ marginTop: 0 }}>
Senate Approves Climate Resolution After Months of Debate
</Headline>
<BodyText weight="Low">
<p>The unanimous vote concludes a contentious legislative session marked by partisan disputes
and last-minute amendments. Page A6.</p>
</BodyText>
<Rule variant="hairline" style={{ margin: '1rem 0' }} />
<Kicker>Install</Kicker>
<div style={{ fontFamily: 'var(--font-family-meta)', fontSize: '12px', background: 'var(--nui-bg-surface)', padding: '0.75rem', border: '1px solid var(--nui-rule-hairline)', marginTop: '0.5rem' }}>
<code>pnpm add newspaperui-components newspaperui-theme</code>
</div>
<Headline weight="Low" as="h3">Tech Sector Gains as Inflation Eases</Headline>
<BodyText weight="Low">
<p>Major indices climbed for a fifth consecutive session as new data showed price growth
slowing across consumer goods. Business B1.</p>
</BodyText>
<Rule variant="hairline" style={{ margin: '1rem 0' }} />
<Headline weight="Low" as="h3">Drought Conditions Worsen Across the Plains</Headline>
<BodyText weight="Low">
<p>Officials in seven states have requested federal disaster relief as reservoir levels reach
historic lows. National A12.</p>
</BodyText>
<Factbox title="At a Glance" variant="highlight">
<ul style={{ padding: '0 0 0 1em', margin: 0, fontSize: '12px', lineHeight: 1.7 }}>
<li>24 React components</li>
<li>CSS Grid + Multi-column</li>
<li>4 font families</li>
<li>Warm off-white palette</li>
<li>Dark mode support</li>
<li>CJK ready (/)</li>
<li>51 tests passing</li>
</ul>
</Factbox>
<Rule variant="hairline" style={{ margin: '1rem 0' }} />
<Headline weight="Low" as="h3">New Exhibit Opens at the Metropolitan</Headline>
<BodyText weight="Low">
<p>A retrospective of mid-century textile design draws record opening crowds. Arts C3.</p>
</BodyText>
<Rule variant="hairline" style={{ margin: '1rem 0' }} />
<Headline weight="Low" as="h3">City Council Approves Transit Expansion</Headline>
<BodyText weight="Low">
<p>The $2.4 billion plan adds three new rail lines and extends service hours on existing routes. Metro A8.</p>
</BodyText>
<Rule variant="hairline" style={{ margin: '1rem 0' }} />
<Headline weight="Low" as="h3">University Announces Record Enrollment</Headline>
<BodyText weight="Low">
<p>Applications rose 18 percent this cycle, driven by expanded financial aid programs. Education B4.</p>
</BodyText>
<Rule variant="hairline" style={{ margin: '1rem 0' }} />
<Headline weight="Low" as="h3">Harbor Restoration Project Begins</Headline>
<BodyText weight="Low">
<p>Engineers will dredge sediment and rebuild seawalls over a three-year timeline. Local A10.</p>
</BodyText>
<Rule variant="hairline" style={{ margin: '1rem 0' }} />
<Headline weight="Low" as="h3">Orchestra Names New Music Director</Headline>
<BodyText weight="Low">
<p>The appointment ends a two-year search following the previous director&rsquo;s retirement. Arts C1.</p>
</BodyText>
</Article>
{/* Center: Lead story */}
<Article span={14}>
<Kicker style={{ textAlign: 'center' }}>Design System · Open Source</Kicker>
<div style={{ textAlign: 'center' }}><Kicker>Capitol · Breaking</Kicker></div>
<Headline weight="High" align="center">
Print-Grade Typography Meets the Modern Web
Historic Accord Reshapes Continental Trade After Marathon Session
</Headline>
<Subhead weight="High" style={{ textAlign: 'center', marginTop: 0 }}>
24 components inspired by InDesign, built for React. Real multi-column flow, drop caps, small caps, old-style figures the full newspaper toolkit.
Negotiators emerge with sweeping framework on tariffs, labor, and emissions; ratification expected within weeks
</Subhead>
<div style={{ display: 'flex', justifyContent: 'center', gap: '1rem', margin: '0.5rem 0 1.5rem', alignItems: 'baseline' }}>
<Byline>By the NewspaperUI Team</Byline>
<div style={{ display: 'flex', justifyContent: 'center', gap: '1rem', margin: '0.5rem 0 1rem', alignItems: 'baseline' }}>
<Byline>By Eleanor Whitcombe and Marcus Reyes</Byline>
<span style={{ color: 'var(--nui-text-muted)' }}>·</span>
<span style={{ fontFamily: 'var(--font-family-meta)', fontSize: '12px', color: 'var(--nui-text-muted)' }}>5 min read</span>
</div>
<Figure
src="https://images.unsplash.com/photo-1504711434969-e33886168f5c?auto=format&fit=crop&w=1200&q=80"
alt="Newspaper printing press"
caption="From Gutenberg to Grid: newspaper typography traditions, now available as React components."
credit="Unsplash"
src="https://images.unsplash.com/photo-1572949645841-094f3a9c4c94?auto=format&fit=crop&w=1200&q=80"
alt="Diplomats applaud after the final draft was approved"
caption="Negotiators applaud after the final draft was approved Monday evening at the Continental Conference Center."
credit="Photograph by Jane Doe / Pool"
/>
<BodyText weight="High" columns={3} dropCap style={{ marginTop: '1.5rem' }}>
<p><Dateline>Open Source </Dateline> NewspaperUI brings the precision of professional newspaper typesetting to web development. Built on a 24-column CSS Grid foundation with CSS Multi-column text flow, it reproduces the dense, information-rich layouts that have defined print journalism for centuries.</p>
<p>The library&#39;s visual weight system borrowed from InDesign&#39;s paragraph styles drives all typography from a single data source. Change one value in the visual-weights mapping, and every Headline, Subhead, and BodyText component updates globally. This is design-token architecture taken to its logical conclusion.</p>
<p>Typography details that most web frameworks ignore are first-class citizens here: true OpenType small caps (not faked with text-transform), old-style figures that blend with body text, hanging punctuation, proper paragraph indentation (no space between paragraphs, first-line indent from paragraph two), and drop caps that actually work with CSS ::first-letter.</p>
<p>The multi-column flow is real CSS columns text reflows naturally across 2, 3, or 4 columns with hairline rules between them. Pull quotes span all columns. Figures break cleanly. Orphans and widows are controlled. This is how InDesign works, translated to the browser.</p>
<p>Four preset themes ship out of the box: Classic NYT (warm off-white, Cormorant Garamond masthead), The Times (ink-blue accent), Modern Dark (warm brown-black), and Swiss Modern (Helvetica-clean). The Create page lets you customize every token and export a CSS file for your project.</p>
<p><Dateline>Brussels </Dateline> After eleven consecutive days of negotiation that several
participants described as the most demanding in a generation, delegates from twenty-three nations
announced on Monday a sweeping framework to reorganize commerce across the continent. The accord,
which still requires ratification by member parliaments, would harmonize tariff schedules, set
common labor standards, and bind signatories to a shared emissions pathway through 2040.</p>
<p>Officials briefed on the talks said the breakthrough came shortly before midnight, when a
dispute over agricultural subsidies was resolved with a side letter granting transitional relief
to producers in five smaller economies. The chief negotiator, Margarethe Lindqvist, called the
outcome &ldquo;a long argument that finally became a conversation.&rdquo;</p>
<p>The framework&rsquo;s most consequential provisions target heavy industry. Cement, steel, and
chemical producers would face a graduated carbon levy beginning in 2028, with revenues recycled
into a continental investment fund for low-carbon manufacturing. Industry associations expressed
cautious support, while environmental groups praised the levy&rsquo;s binding architecture but warned
that the timeline gives polluters too much room to delay.</p>
<p>Markets reacted with measured optimism. The continental composite index closed up 1.2 percent,
led by capital-goods makers expected to benefit from infrastructure investment. The currency
strengthened against the dollar by 0.7 percent. Bond yields, which had climbed throughout the
negotiations on fiscal-stability concerns, retreated to levels seen before the talks began.</p>
<p>Domestic political reaction was mixed. The accord&rsquo;s labor provisions, which establish minimum
standards for paid leave and collective bargaining, drew immediate praise from union federations
and equally immediate concern from chambers of commerce. The chairman of the Federation of
Industries warned that small firms would struggle with compliance costs absent transitional support.</p>
<p>Parliamentary leaders in three capitals signaled that ratification could occur before the
summer recess. Two governments, however, indicated that they would seek public referenda before
committing, a process likely to extend into the autumn. Analysts at the Centre for Trade Studies
estimated that full implementation, even on the most expedited timeline, would require at least
eighteen months.</p>
<p>For ordinary travelers and consumers, the immediate effects will be modest. Border procedures
and product standards remain governed by existing arrangements pending ratification. The longer
arc is what matters: a continent of historically fractious neighbors agreeing on a single set of
rules for the most consequential decade in living memory.</p>
<p>The accord&rsquo;s environmental chapter, which drew the most sustained opposition during
negotiations, establishes a continental carbon market linked to existing national schemes.
Permits would be tradeable across borders beginning in 2030, with a price floor set at
forty-five units per ton of carbon dioxide equivalent. Economists at the Institute for
Climate Economics estimated that the floor alone would reduce emissions by eight to twelve
percent within the first five years of operation.</p>
<p>Labor unions in the industrial heartland expressed qualified support. The secretary-general
of the Metalworkers&rsquo; Federation said the transition fund &ldquo;acknowledges what we have argued
for years: that decarbonization cannot be built on the backs of workers.&rdquo; But she cautioned
that the fund&rsquo;s governance structure, which gives equal weight to employer and employee
representatives, could slow disbursements at a moment when speed matters most.</p>
<p>Small and medium enterprises, which employ roughly sixty percent of the continental
workforce, face a distinct set of challenges. The accord exempts firms below a revenue
threshold from the carbon levy for three years, but compliance with the new labor standards
is immediate. Business associations in four countries have already requested technical
assistance programs to help smaller firms adapt their payroll and reporting systems.</p>
<p>Historians of continental integration noted that the accord&rsquo;s scope exceeds any single
agreement since the postwar reconstruction treaties. &ldquo;What makes this different,&rdquo; said
Professor Elena Marchetti of the University of Turin, &ldquo;is that it touches every household&mdash;
not just through trade, but through the air they breathe and the wages they earn.&rdquo;</p>
</BodyText>
<PullQuote weight="High" author="Design Philosophy" align="center" style={{ margin: '2rem 0' }}>
Components should be few, precise, and unambiguous. Every prop maps to a real newspaper concept.
<PullQuote weight="High" author="Margarethe Lindqvist, Chief Negotiator" align="center" style={{ margin: '2rem 0' }}>
A long argument that finally became a conversation.
</PullQuote>
<BodyText weight="High" columns={2}>
<p>Multi-language support is built in from day one. Chinese layouts use Noto Serif SC with restrained red accents (masthead and kickers only). Japanese layouts support both horizontal (yokogumi) and traditional vertical (tategumi) writing modes. German blackletter mastheads use UnifrakturMaguntia.</p>
<p>The responsive system uses CSS media queries injected per-Section, so column counts adapt to viewport width without JavaScript. Font sizes use clamp() for fluid scaling between mobile and desktop. No runtime overhead, no layout shift.</p>
<BodyText weight="High" columns={2} style={{ marginTop: '1rem' }}>
<p>The accord&rsquo;s signing ceremony, originally scheduled for last Friday, was delayed three times
as drafters reconciled competing texts on dispute resolution. The final compromise establishes
an arbitration panel of nine jurists, three appointed by each of the bloc&rsquo;s three regional
groupings, with binding authority over commercial disputes exceeding twenty million units.</p>
<p>Critics on the populist right denounced the framework as an erosion of national sovereignty,
while critics on the left argued that the labor floor was set too low to meaningfully protect
workers in tighter regulatory regimes. Both camps signaled that ratification battles would be
fierce, particularly in legislatures with narrow majorities.</p>
</BodyText>
</Article>
{/* Right sidebar: Demo previews */}
<Article span={5} style={{ borderLeft: '1px solid var(--nui-rule-hairline)', paddingLeft: '1rem' }}>
<Kicker>Live Blocks</Kicker>
<Headline weight="Low" as="h3" style={{ marginTop: '0.25rem' }}>Multi-language Demos</Headline>
<Article span={5} style={{ borderLeft: '1px solid var(--nui-rule-hairline)', paddingLeft: '1.5rem' }}>
<Kicker>Foreign Desk</Kicker>
<Headline weight="Medium" as="h2">
Coastal Nations Pledge Joint Action on Maritime Pollution
</Headline>
<Subhead weight="Medium">
Pact follows years of stalled regional talks and a cascade of recent shipping accidents.
</Subhead>
<Byline>By Tom&#225;s Almeida</Byline>
{/* Mini Chinese preview */}
<Link href="/blocks/zh-frontpage" style={{ textDecoration: 'none', color: 'inherit', display: 'block', marginTop: '1rem' }}>
<div style={{ border: '1px solid var(--nui-rule-hairline)', padding: '0.75rem', background: 'var(--nui-bg-surface)', marginBottom: '0.75rem' }}>
<div style={{ fontFamily: 'var(--font-family-cjk-serif)', fontSize: '18px', fontWeight: 900, color: '#CC2929', lineHeight: 1.2, marginBottom: '0.25rem' }}></div>
<div style={{ fontFamily: 'var(--font-family-cjk-serif)', fontSize: '11px', color: 'var(--nui-text-body)', lineHeight: 1.5 }}></div>
<div style={{ fontFamily: 'var(--font-family-meta)', fontSize: '9px', color: 'var(--nui-accent-primary)', marginTop: '0.5rem', fontVariantCaps: 'small-caps', letterSpacing: '0.06em' }}>View Chinese Block </div>
</div>
</Link>
<BodyText weight="Medium" style={{ marginTop: '0.75rem' }}>
<p><Dateline>Lisbon </Dateline> Eleven coastal nations announced a binding compact to coordinate
cleanup operations and harmonize liability rules for vessels exceeding fifty thousand tons. The
agreement establishes a shared rapid-response fund and creates a regional inspectorate empowered
to detain non-compliant ships in any signatory port.</p>
{/* Mini English preview */}
<Link href="/blocks/en-feature" style={{ textDecoration: 'none', color: 'inherit', display: 'block' }}>
<div style={{ border: '1px solid var(--nui-rule-hairline)', padding: '0.75rem', background: 'var(--nui-bg-surface)', marginBottom: '0.75rem' }}>
<div style={{ fontFamily: 'var(--font-family-display)', fontSize: '14px', fontWeight: 600, lineHeight: 1.2, marginBottom: '0.25rem' }}>The Quiet Collapse of the Middle Shelf</div>
<div style={{ fontFamily: 'var(--font-family-body)', fontSize: '11px', color: 'var(--nui-text-body)', lineHeight: 1.5 }}>How a generation of mid-list authors lost their publishers</div>
<div style={{ fontFamily: 'var(--font-family-meta)', fontSize: '9px', color: 'var(--nui-accent-primary)', marginTop: '0.5rem', fontVariantCaps: 'small-caps', letterSpacing: '0.06em' }}>View English Block </div>
</div>
</Link>
<p>Maritime industry groups received the news with caution. A spokesperson for the Continental
Shipping Council acknowledged that &ldquo;stronger common rules are overdue&rdquo; but warned that
implementation costs could fall disproportionately on smaller operators.</p>
{/* Mini Japanese preview */}
<Link href="/blocks/jp-vertical" style={{ textDecoration: 'none', color: 'inherit', display: 'block' }}>
<div style={{ border: '1px solid var(--nui-rule-hairline)', padding: '0.75rem', background: 'var(--nui-bg-surface)', marginBottom: '0.75rem' }}>
<div style={{ fontFamily: 'var(--font-family-cjk-jp)', fontSize: '16px', fontWeight: 900, lineHeight: 1.2, marginBottom: '0.25rem' }}></div>
<div style={{ fontFamily: 'var(--font-family-cjk-jp)', fontSize: '11px', color: 'var(--nui-text-body)', lineHeight: 1.5 }}></div>
<div style={{ fontFamily: 'var(--font-family-meta)', fontSize: '9px', color: 'var(--nui-accent-primary)', marginTop: '0.5rem', fontVariantCaps: 'small-caps', letterSpacing: '0.06em' }}>View Japanese Block </div>
</div>
</Link>
<p>The compact takes effect on January 1, pending technical annexes. Environmental observers
described the pact as the most consequential maritime accord in a decade.</p>
</BodyText>
<Rule variant="hairline" style={{ margin: '1rem 0' }} />
<Headline weight="Low" as="h3">Fisheries Report Warns of Declining Stocks</Headline>
<BodyText weight="Low">
<p>Annual survey data shows a 14 percent drop in key commercial species across the northern
shelf. Scientists attribute the decline to warming waters and overfishing in adjacent
unregulated zones. Environment A9.</p>
</BodyText>
{/* Quick links */}
<Kicker>More</Kicker>
<ul style={{ listStyle: 'none', padding: 0, margin: '0.5rem 0 0', fontFamily: 'var(--font-family-meta)', fontSize: '12px', lineHeight: 2 }}>
<li><Link href="/blocks" style={{ color: 'var(--nui-text-body)', textDecoration: 'none' }}>All 6 Blocks </Link></li>
<li><Link href="/examples/nyt-frontpage" style={{ color: 'var(--nui-text-body)', textDecoration: 'none' }}>NYT Front Page </Link></li>
<li><Link href="/examples/blackletter-frontpage" style={{ color: 'var(--nui-text-body)', textDecoration: 'none' }}>Blackletter </Link></li>
<li><Link href="/create" style={{ color: 'var(--nui-text-body)', textDecoration: 'none' }}>Theme Creator </Link></li>
<li><Link href="/grid-system" style={{ color: 'var(--nui-text-body)', textDecoration: 'none' }}>Documentation </Link></li>
</ul>
<Rule variant="hairline" style={{ margin: '1rem 0' }} />
<Headline weight="Low" as="h3">Rail Strike Averted After Late-Night Deal</Headline>
<BodyText weight="Low">
<p>Workers accepted a revised pay offer minutes before the midnight deadline. Services
resume on normal schedules. Transport B2.</p>
</BodyText>
</Article>
</Section>
{/* Bottom section: Component showcase strip */}
<Section columns={24} divider="top" gap="1rem" style={{ marginTop: '2rem', paddingTop: '1.5rem' }}>
<Section columns={24} divider="top" gap="2rem" style={{ marginTop: '2rem', paddingTop: '2rem' }}>
<Article span={24}>
<Folio page="B1" section="Components" date="24 total" publication="NewspaperUI" />
</Article>
<Kicker>National · Investigation</Kicker>
<Headline weight="Medium" as="h2">
Records Reveal Years of Overlooked Warnings at Aging Reservoirs
</Headline>
<Subhead weight="Medium">
Internal inspection memoranda, obtained through public records requests, suggest that
structural concerns flagged repeatedly by field engineers were not escalated to senior staff.
</Subhead>
<Byline style={{ marginBottom: '1rem' }}>By Ravi Nair, Anita Kowalski, and Charles Weston</Byline>
<Article span={6}>
<Factbox title="Layout (9)">
<ul style={{ padding: '0 0 0 1em', margin: 0, fontSize: '12px', lineHeight: 1.8 }}>
<li>Layout</li>
<li>Section</li>
<li>Article</li>
<li>Layer</li>
<li>Masthead</li>
<li>Rule</li>
<li>Footer</li>
<li>Sidebar</li>
<li>BreakingNewsBanner</li>
</ul>
</Factbox>
</Article>
<BodyText weight="High" columns={4}>
<p><Dateline>Sacramento </Dateline> A six-month review of more than four thousand pages of
inspection records, interviews with twenty-three current and former engineers, and reconstructions
of three near-failure incidents reveals a pattern of unheeded warnings about the structural
integrity of mid-twentieth-century earthen dams across the western states.</p>
<Article span={6}>
<Factbox title="Text (10)">
<ul style={{ padding: '0 0 0 1em', margin: 0, fontSize: '12px', lineHeight: 1.8 }}>
<li>Headline</li>
<li>Subhead</li>
<li>Kicker</li>
<li>BodyText</li>
<li>Quote</li>
<li>Byline</li>
<li>Dateline</li>
<li>Caption</li>
<li>AuthorCard</li>
<li>JumpLine</li>
</ul>
</Factbox>
</Article>
<p>The records show that field engineers documented concerns about seepage, erosion, and spillway
capacity in repeated annual assessments dating back at least fifteen years. In several instances,
those concerns were rated &ldquo;moderate&rdquo; in the field reports but downgraded to &ldquo;low&rdquo; by the time they
reached senior officials. The pattern was particularly pronounced at three facilities serving
regions of more than two million residents.</p>
<Article span={6}>
<Factbox title="Media (4)">
<ul style={{ padding: '0 0 0 1em', margin: 0, fontSize: '12px', lineHeight: 1.8 }}>
<li>Image</li>
<li>Figure</li>
<li>Video</li>
<li>PullQuote</li>
</ul>
</Factbox>
</Article>
<p>Officials at the Department of Water Resources, asked to review excerpts of the records, said
in a written statement that &ldquo;every reservoir under our oversight has been deemed safe for current
operations&rdquo; but did not specifically address the discrepancies between field and final ratings.
The agency declined to make senior staff available for interviews.</p>
<Article span={6}>
<Factbox title="Data (3)">
<ul style={{ padding: '0 0 0 1em', margin: 0, fontSize: '12px', lineHeight: 1.8 }}>
<li>IndexBox</li>
<li>Factbox</li>
<li>RelatedArticles</li>
</ul>
</Factbox>
<p>The findings come amid renewed scrutiny of aging infrastructure following the partial collapse
of an earthen embankment in March that displaced more than fifteen hundred residents. Federal
inspectors who responded to that incident found the proximate cause to be precisely the type of
seepage concern that field engineers had flagged in three of the past four annual assessments.</p>
<p>The investigative review found that of forty-seven reservoirs surveyed, sixteen had at least
one instance in which a &ldquo;moderate&rdquo; or &ldquo;high&rdquo; field rating was downgraded before reaching senior
management. In nine cases, the downgrades persisted for three or more consecutive years. None of
the affected facilities have publicly disclosed the discrepancies.</p>
<p>Engineering professional associations have, in recent years, called for an independent review
of inspection workflows in the western states. A spokesperson for the Society of Hydraulic
Engineers said the Society was &ldquo;deeply concerned&rdquo; by the patterns described and would convene a
working group to examine reform options.</p>
</BodyText>
</Article>
</Section>
</Layout>
);
}
/* ============================================================
* DEMO: Japanese Front Page (朝日新聞 · 横組み)
* ============================================================ */
const jp = { fontFamily: 'var(--font-family-cjk-jp)' };
const jpAccent = { color: 'var(--nui-accent-ink-blue)' };
function JpFrontpageDemo() {
return (
<Layout columns={24} maxWidth="1280px" padding="1.5rem 1rem">
{/* 報頭 */}
<header style={{
textAlign: 'center',
borderTop: '3px solid var(--nui-text-primary)',
borderBottom: '1px solid var(--nui-rule-decorative)',
paddingTop: '1rem',
paddingBottom: '0.5rem',
}}>
<h1 style={{
...jp,
fontSize: '72px',
fontWeight: 900,
margin: 0,
letterSpacing: '0.15em',
lineHeight: 1,
color: 'var(--nui-text-primary)',
}}></h1>
<div style={{
...jp,
display: 'flex',
justifyContent: 'space-between',
fontSize: '11px',
color: 'var(--nui-text-secondary)',
padding: '0.5rem 1rem',
borderTop: '1px solid var(--nui-rule-hairline)',
marginTop: '0.5rem',
}}>
<span>48721</span>
<span>82026519 </span>
<span> · 14</span>
</div>
</header>
{/* 一面トップ */}
<Section columns={24} gap="1rem" style={{ marginTop: '1rem', paddingBottom: '1rem', borderBottom: '2px solid var(--nui-rule-decorative)' }}>
<Article span={24}>
<div style={{ ...jp, ...jpAccent, fontSize: '13px', fontWeight: 700, marginBottom: '0.5rem', textAlign: 'center' }}></div>
<h2 style={{ ...jp, fontSize: '48px', fontWeight: 900, lineHeight: 1.15, color: 'var(--nui-text-primary)', textAlign: 'center', margin: 0 }}>
 23
</h2>
<h3 style={{ ...jp, fontSize: '20px', fontWeight: 500, lineHeight: 1.5, color: 'var(--nui-text-secondary)', textAlign: 'center', margin: '0.5rem 0 1rem 0' }}>
 
</h3>
<div style={{ ...jp, textAlign: 'center', fontSize: '12px', color: 'var(--nui-text-muted)', marginBottom: '1rem' }}>
</div>
<Figure
src="https://images.unsplash.com/photo-1577962917302-cd874c4e31d2?auto=format&fit=crop&w=1200&q=80"
alt="署名式の様子"
caption="協定に署名する各国代表。ブリュッセルの会議場で19日未明。"
credit="AP"
/>
<BodyText weight="High" columns={3} style={{ ...jp, marginTop: '1rem' }}>
<p>112319調</p>
<p>20402028</p>
<p>1.20.7</p>
<p></p>
<p>32貿18</p>
<p>10</p>
</BodyText>
</Article>
</Section>
{/* Footer */}
<Footer
copyright="© 2026 NewspaperUI"
edition="MIT License"
links={[
{ label: 'GitHub', href: 'https://github.com/joisun/newspaperui' },
{ label: 'Documentation', href: '/grid-system' },
{ label: 'Blocks', href: '/blocks' },
{ label: 'Create Theme', href: '/create' },
]}
/>
{/* 二面:3栏 */}
<Section columns={24} gap="1rem" style={{ marginTop: '1rem', paddingBottom: '1rem', borderBottom: '1px solid var(--nui-rule-decorative)' }}>
<Article span={8} style={{ background: 'var(--nui-bg-surface)', padding: '1rem', borderLeft: '3px solid var(--nui-accent-ink-blue)' }}>
<div style={{ ...jp, ...jpAccent, fontSize: '12px', fontWeight: 700, marginBottom: '0.75rem', paddingLeft: '0.75rem', borderLeft: '3px solid var(--nui-accent-ink-blue)' }}></div>
<h3 style={{ ...jp, fontSize: '20px', fontWeight: 700, lineHeight: 1.35, color: 'var(--nui-text-primary)', margin: '0 0 0.5rem 0' }}></h3>
<BodyText weight="Low" style={jp}>
<p></p>
<p></p>
</BodyText>
<Rule variant="hairline" style={{ margin: '0.75rem 0' }} />
<h4 style={{ ...jp, fontSize: '16px', fontWeight: 600, lineHeight: 1.35, margin: '0 0 0.4rem 0' }}>3</h4>
<BodyText weight="Low" style={jp}>
<p>243</p>
</BodyText>
<Rule variant="hairline" style={{ margin: '0.75rem 0' }} />
<h4 style={{ ...jp, fontSize: '16px', fontWeight: 600, lineHeight: 1.35, margin: '0 0 0.4rem 0' }}></h4>
<BodyText weight="Low" style={jp}>
<p>3</p>
</BodyText>
</Article>
<Article span={8} style={{ background: 'var(--nui-bg-surface)', padding: '1rem', borderLeft: '3px solid var(--nui-accent-ink-blue)' }}>
<div style={{ ...jp, ...jpAccent, fontSize: '12px', fontWeight: 700, marginBottom: '0.75rem', paddingLeft: '0.75rem', borderLeft: '3px solid var(--nui-accent-ink-blue)' }}></div>
<h3 style={{ ...jp, fontSize: '20px', fontWeight: 700, lineHeight: 1.35, color: 'var(--nui-text-primary)', margin: '0 0 0.5rem 0' }}>PMI</h3>
<BodyText weight="Low" style={jp}>
<p>552.45</p>
<p></p>
</BodyText>
<Rule variant="hairline" style={{ margin: '0.75rem 0' }} />
<h4 style={{ ...jp, fontSize: '16px', fontWeight: 600, lineHeight: 1.35, margin: '0 0 0.4rem 0' }}>3.7</h4>
<BodyText weight="Low" style={jp}>
<p>AI商用化への期待を背景にテクノロジー株が全面高</p>
</BodyText>
</Article>
<Article span={8} style={{ background: 'var(--nui-bg-surface)', padding: '1rem', borderLeft: '3px solid var(--nui-accent-ink-blue)' }}>
<div style={{ ...jp, ...jpAccent, fontSize: '12px', fontWeight: 700, marginBottom: '0.75rem', paddingLeft: '0.75rem', borderLeft: '3px solid var(--nui-accent-ink-blue)' }}></div>
<h3 style={{ ...jp, fontSize: '20px', fontWeight: 700, lineHeight: 1.35, color: 'var(--nui-text-primary)', margin: '0 0 0.5rem 0' }}></h3>
<BodyText weight="Low" style={jp}>
<p>殿8220214</p>
<p>4</p>
</BodyText>
<Rule variant="hairline" style={{ margin: '0.75rem 0' }} />
<h4 style={{ ...jp, fontSize: '16px', fontWeight: 600, lineHeight: 1.35, margin: '0 0 0.4rem 0' }}></h4>
<BodyText weight="Low" style={jp}>
<p>18</p>
</BodyText>
</Article>
</Section>
{/* 短信欄 */}
<Section columns={24} gap="1rem" style={{ marginTop: '1rem' }}>
<Article span={24}>
<div style={{ ...jp, ...jpAccent, fontSize: '12px', fontWeight: 700, marginBottom: '0.5rem', paddingLeft: '0.75rem', borderLeft: '3px solid var(--nui-accent-ink-blue)' }}> · </div>
<BodyText weight="Low" columns={4} style={jp}>
<p> </p>
<p> FRB議事要旨で大半の当局者が年内利下げ開始を支持していることが判明</p>
<p> 25bp引き下げ</p>
<p> </p>
<p> EU首脳会議が支援パッケージで合意3</p>
<p> 58000西</p>
</BodyText>
</Article>
</Section>
</Layout>
);
}