Loading...
Loading...
Compare original and translation side by side
<header> <!-- site header, logo, primary nav -->
<nav> <!-- navigation links -->
<main> <!-- primary page content, one per page -->
<article> <!-- self-contained content: blog post, product card, news item -->
<section> <!-- thematic grouping with a heading -->
<aside> <!-- tangentially related content: sidebar, callout -->
<footer> <!-- site footer, secondary links, copyright --><header> <!-- site header, logo, primary nav -->
<nav> <!-- navigation links -->
<main> <!-- primary page content, one per page -->
<article> <!-- self-contained content: blog post, product card, news item -->
<section> <!-- thematic grouping with a heading -->
<aside> <!-- tangentially related content: sidebar, callout -->
<footer> <!-- site footer, secondary links, copyright --><h1>h1h3h2<h1>Product name</h1>
<h2>Features</h2>
<h3>Feature detail</h3>
<h2>Pricing</h2><h1>h1h3h2<h1>Product name</h1>
<h2>Features</h2>
<h3>Feature detail</h3>
<h2>Pricing</h2><button> <!-- clickable action, submits or triggers JS -->
<a href> <!-- navigation to a URL -->
<input> <!-- user data entry -->
<select> <!-- option selection -->
<details> / <summary> <!-- native disclosure/accordion --><div><span><button> <!-- clickable action, submits or triggers JS -->
<a href> <!-- navigation to a URL -->
<input> <!-- user data entry -->
<select> <!-- option selection -->
<details> / <summary> <!-- native disclosure/accordion --><div><span><img>alt| Image type | Alt text |
|---|---|
| Informative (product photo, chart) | Describe content: |
| Functional (icon button, logo link) | Describe function: |
| Decorative | Empty: |
| Complex (chart, diagram) | Short alt + longer description nearby or in |
<!-- Informative -->
<img src="sofa.jpg" alt="Red leather sofa, three-seater">
<!-- Decorative -->
<img src="divider.svg" alt="">
<!-- With caption -->
<figure>
<img src="chart.png" alt="Bar chart showing revenue growth Q1–Q4 2025">
<figcaption>Revenue grew 42% year-on-year in Q4 2025.</figcaption>
</figure><img>alt| 图片类型 | Alt文本 |
|---|---|
| 信息型(产品照片、图表) | 描述内容: |
| 功能型(图标按钮、Logo链接) | 描述功能: |
| 装饰型 | 留空: |
| 复杂型(图表、示意图) | 简短alt文本 + 附近或 |
<!-- Informative -->
<img src="sofa.jpg" alt="Red leather sofa, three-seater">
<!-- Decorative -->
<img src="divider.svg" alt="">
<!-- With caption -->
<figure>
<img src="chart.png" alt="Bar chart showing revenue growth Q1–Q4 2025">
<figcaption>Revenue grew 42% year-on-year in Q4 2025.</figcaption>
</figure><title>Product Name — Short descriptor | Brand</title>
<meta name="description" content="One or two sentences. What this page is, who it is for, what they will find."><title>Product Name — Short descriptor | Brand</title>
<meta name="description" content="One or two sentences. What this page is, who it is for, what they will find."><link rel="canonical" href="https://example.com/the-definitive-url"><link rel="canonical" href="https://example.com/the-definitive-url"><meta property="og:title" content="Page title">
<meta property="og:description" content="Page description">
<meta property="og:image" content="https://example.com/og-image.jpg">
<meta property="og:url" content="https://example.com/page">
<meta property="og:type" content="website">
<!-- Twitter/X -->
<meta name="twitter:card" content="summary_large_image">
<meta name="twitter:title" content="Page title">
<meta name="twitter:image" content="https://example.com/og-image.jpg"><meta property="og:title" content="Page title">
<meta property="og:description" content="Page description">
<meta property="og:image" content="https://example.com/og-image.jpg">
<meta property="og:url" content="https://example.com/page">
<meta property="og:type" content="website">
<!-- Twitter/X -->
<meta name="twitter:card" content="summary_large_image">
<meta name="twitter:title" content="Page title">
<meta name="twitter:image" content="https://example.com/og-image.jpg"><script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "Product",
"name": "Product Name",
"description": "Product description",
"image": "https://example.com/product.jpg",
"offers": {
"@type": "Offer",
"price": "49.00",
"priceCurrency": "EUR"
}
}
</script>ProductArticleBreadcrumbListFAQPageOrganizationSiteLinksSearchBox<script type="application/ld+json">
{
"@context": "https://schema.org",
"@type": "Product",
"name": "Product Name",
"description": "Product description",
"image": "https://example.com/product.jpg",
"offers": {
"@type": "Offer",
"price": "49.00",
"priceCurrency": "EUR"
}
}
</script>ProductArticleBreadcrumbListFAQPageOrganizationSiteLinksSearchBoxLayer 1: HTML — content is readable, links work, forms submit
Layer 2: CSS — layout, typography, visual design
Layer 3: JS — interactivity, animations, dynamic content<form action><a href>srcloading="lazy"Layer 1: HTML — 内容可阅读、链接可跳转、表单可提交
Layer 2: CSS — 布局、排版、视觉设计
Layer 3: JS — 交互性、动画、动态内容<form action><a href>srcloading="lazy"document.title<Head>document.title<Head><h1><main>// After route change
document.querySelector('h1')?.focus();<h1><main>// After route change
document.querySelector('h1')?.focus();pushStatereplaceStatepushStatereplaceState@media (hover: hover) {
/* hover states — mouse or trackpad */
.btn:hover { background: var(--color-primary-hover); }
}
@media (hover: none) {
/* touch device — no hover, larger targets */
.btn { min-height: 44px; }
}@media (hover: hover) {
/* hover states — mouse or trackpad */
.btn:hover { background: var(--color-primary-hover); }
}
@media (hover: none) {
/* touch device — no hover, larger targets */
.btn { min-height: 44px; }
}@media (pointer: coarse) {
/* fat-finger touch — increase target sizes */
.interactive { min-height: 44px; min-width: 44px; }
}
@media (pointer: fine) {
/* mouse — precise, can use smaller targets */
}@media (pointer: coarse) {
/* fat-finger touch — increase target sizes */
.interactive { min-height: 44px; min-width: 44px; }
}
@media (pointer: fine) {
/* mouse — precise, can use smaller targets */
}<!-- Lazy load images below the fold -->
<img src="product.jpg" loading="lazy" alt="...">
<!-- Serve modern formats with fallback -->
<picture>
<source srcset="image.avif" type="image/avif">
<source srcset="image.webp" type="image/webp">
<img src="image.jpg" alt="...">
</picture><!-- Lazy load images below the fold -->
<img src="product.jpg" loading="lazy" alt="...">
<!-- Serve modern formats with fallback -->
<picture>
<source srcset="image.avif" type="image/avif">
<source srcset="image.webp" type="image/webp">
<img src="image.jpg" alt="...">
</picture>@media (prefers-reduced-motion: reduce) { /* disable animations */ }
@media (prefers-color-scheme: dark) { /* dark mode tokens */ }
@media (prefers-contrast: more) { /* increase contrast */ }
@media (forced-colors: active) { /* Windows high contrast mode */ }@media (prefers-reduced-motion: reduce) { /* disable animations */ }
@media (prefers-color-scheme: dark) { /* dark mode tokens */ }
@media (prefers-contrast: more) { /* increase contrast */ }
@media (forced-colors: active) { /* Windows high contrast mode */ }<h1><main><nav><header><footer><article><section><img>altalt=""<title><meta name="description"><link rel="canonical">document.title@media (hover: hover)@media (pointer: coarse)loading="lazy"prefers-reduced-motion<h1><main><nav><header><footer><article><section><img>altalt=""<title><meta name="description"><link rel="canonical">document.title@media (hover: hover)@media (pointer: coarse)loading="lazy"prefers-reduced-motion