<figure>要素 — 内容のまとまりとcaption
Technical Summary
figureは、図、写真、コード一覧など、ひとまとまりとして本文から参照できるflow contentを表します。画像専用でも、本文から切り離された補足専用でもありません。内容は周囲の本文の流れに含まれます。
figcaptionは、その親figureの内容に付けるcaptionです。省略可能で、使用する場合はfigureの最初か最後の子要素に1つ置きます。
定義・分類・content model
HTML Living Standardのfigureは、必要ならcaptionを付けられる、ひとまとまりとして扱えるflow contentです。主な例は、図解、写真、コード一覧です。「self-contained」は周囲の本文から完全に独立しているという意味ではなく、ひとまとまりとして参照できるという意味です。
| 項目 | figure | figcaption |
|---|---|---|
| 意味 | captionを付けられる、ひとまとまりのflow content | 親figureの内容を説明するcaption |
| 分類 | Flow content、palpable content | Flow content、palpable content |
| 配置 | Flow contentが使える場所 | figureの最初または最後の子要素 |
| 内容 | figcaptionを先頭に1つ置いてflow content、末尾に1つ置いてflow content、またはflow contentのみ | Flow content |
| タグ省略 | 開始・終了タグとも省略不可 | 開始・終了タグとも省略不可 |
| DOM interface | HTMLElementを使う。専用のHTMLFigureElement interfaceはない | HTMLElementを使う。専用のHTMLFigureCaptionElement interfaceはない |
親子関係はDOM上の直接の子要素で決まります。離れたcaptionをID参照するだけでは、HTMLのfigcaptionとしての親子関係になりません。DOM interfaceはどちらもHTMLElementです。
figure・figcaption・周辺要素の境界
figureは画像を意味する要素ではありません。図や写真以外に、コード一覧や詩なども含められます。一方、文の途中に置く小さな画像のように、周囲の文と一体になっている内容を機械的に囲む要素でもありません。
図の内容とcaptionの両方が本文の流れに関係するならfigureが候補です。主題とは別の補足、広告、繰り返しの引用など、周囲と別の目的を持つ内容にはasideが候補になります。CSSで位置を動かしただけでは、この意味の境界は変わりません。
figcaptionはfigureの直接の子要素です。captionを使う場合、子要素の先頭か最後に1つ置き、途中に置いたり、2つ以上置いたりしないようにします。caption自体を付けないfigureも適合します。
画像を含める場合、画像のaltとfigureのcaptionは別の役割です。altは画像の代替テキストです。captionは画像を含むまとまりの説明や出典を伝えます。HTML-AAMのname計算には、alt属性がない画像について、figure内の他のflow contentの有無とfigcaptionを条件に画像名を決める限定的な規則があります。これは作者がaltを省略してよいという一般的な推奨ではありません。
HTML-AAMとAccessible Name
HTML-AAM 1.0 Working Draft(2026-10-26)は、figureのimplicit roleをfigure、figcaptionのimplicit roleをWAI-ARIAのcaptionとして示します。これは規範文書のmappingであり、個々のブラウザーのAccessibility Treeが同じnameやnode構成を示すことは、別に実測します。
同Working Draftのfigure Accessible Name Computationでは、figureのnameは作者が指定したaria-labelまたはaria-labelledbyから計算し、いずれもなければtitleを使います。使える文字列がなければnameはありません。figcaptionの文字列はfigureのnameやdescriptionへ自動では含めず、作者が明示的に参照した場合に使います。
WAI-ARIA 1.2のcaption roleはfigureなどのcaptionを表し、captionを持つ親figureからaria-labelledbyで参照することを作者に推奨しています。captionをfigure自身のnameにも使う例は次のとおりです。
<figure aria-labelledby="chart-caption">
<img src="sales-chart.svg" alt="1月から6月までの売上を示す棒グラフ">
<figcaption id="chart-caption">図1. 月ごとの売上</figcaption>
</figure>
この例では、画像のaltは画像自体を説明し、aria-labelledbyはfigureのAccessible Nameをcaptionの文字列にします。画像の代替テキストとfigureの名前を同じものとして扱いません。
Fact / Evidence
規範的な定義、アクセシビリティmapping、WPT testharnessのassertion、Chromiumで観測した値を分けて記録します。WPTのpassは選定テストに対する結果であり、仕様全体や他のブラウザーの適合を証明しません。
| Type | Fact / Claim | Scope / conditions | Evidence |
|---|---|---|---|
| SPEC | figureはcaptionを付けられるflow contentのまとまり。figcaptionはfigureのcaptionを表し、直接の子要素の先頭または最後に1つ置く。 | HTML Living Standard §4.4.12–4.4.13。作者向け要件と実装mappingを分ける。 | figure · figcaption |
| AAM | HTML-AAM WDはfigureをfigure role、figcaptionをcaption roleへ対応付ける。figcaptionはfigureのaccessible name / descriptionに自動では入らず、明示参照時に使う。 | HTML-AAM 1.0 Working Draft 2026-10-26とWAI-ARIA 1.2。draftの記載とChromium観測は別記録。 | HTML-AAM: figure · HTML-AAM: figcaption · WAI-ARIA: caption |
| WPT | role mappingとfigure名計算について、選定した2つのHTML-AAM test fileを実行する。 | revision 4f6401cda49e7622832d3fd9652dceec65731d5b。ローカルtestharnessとCDP adapter。公式wptrunner / WebDriverではない。 | roles.html · figure-name-no-figcaption.tentative.html |
Evidence
- HTML Living Standard, §4.4.12 The figure element — definition, categories, context, content model, DOM interface, caption behavior, and author guidance.
- HTML Living Standard, §4.4.13 The figcaption element — parent relation, category, context, content model, and interface.
- HTML-AAM 1.0 Working Draft, 2026-10-26: figure — role mapping and accessible-name computation.
- HTML-AAM 1.0 Working Draft, 2026-10-26: figcaption — caption role mapping.
- WAI-ARIA 1.2: caption role — caption meaning and the recommendation to reference it from its parent.
Implementation Evidence
Browser DOM and Chromium Accessibility Tree observations use a dedicated fixture. Selected WPT tests use the pinned testharness with a Playwright / Chrome DevTools Protocol adapter for computed role and label. The adapter is not the official wptrunner or WebDriver launcher.
Reproducible fixture: figure-v1 records figure and figcaption child placement, accessible-name cases, image alt and caption cases, page metadata, responsive widths, theme settings, and the four Yugien / Atlas locale pages. Detailed conditions and output files are listed in the evidence registry below and docs/atlas/figure-evidence-2026-11-01.md.
| Type | Reproduced scope | Recorded conditions | Status |
|---|---|---|---|
| IMPL | Yugien / Atlasの日英4ページ、ページ情報・サイト内ナビゲーション・検索、figure / figcaption、レスポンシブ幅とテーマ切り替え |
2026-11-01 / Google Chrome 156.0.8078.74、Playwright 1.57.0 / Windows 11 Pro build 26300 / DPR 1。4ページはすべてHTTP 200、canonicalとhreflangあり、内部route・fragment欠落なし。320 / 390 / 768 / 1280 / 1920 CSS pxでページ全体の横はみ出しなし。system light / darkと明示的なlight / darkを確認。検索はAtlasで「図」、Yugienで「figure」を入力し、各日英ページを確認。fixtureと出力はbuild-config/yugien/research-results/figure-v1/。 |
部分観測(Chrome 156 / 1環境) |
| WPT | HTML-AAMの役割とfigure内画像のaccessible nameに関する選定WPT 2ファイル | 2026-11-01 / Google Chrome 156.0.8078.74 / WPT revision 4f6401cda49e7622832d3fd9652dceec65731d5b。html-aam/roles.html 60/60 pass。figure-name-no-figcaption.tentative.html 8/9 pass。合計68/69 pass、1 fail、timeoutなし。failは「figure内にfigcaptionがあるaltなし画像」のaccessible nameで、WPT期待値figcaptionに対してChromeは空文字を返した。tentativeテストであり、ローカルtestharnessをPlaywright / CDP adapterで実行。公式wptrunner / WebDriver実行ではない。詳細はdocs/atlas/figure-evidence-2026-11-01.md。実行したテストの版: |
部分実行(68/69 pass・1差異) |
| AAM | Chrome DevTools ProtocolのAccessibility Treeにおけるfigure / imgのroleとname |
2026-11-01 / Google Chrome 156.0.8078.74 / Windows 11 Pro build 26300。CDP Accessibility.getPartialAXTreeでfigure・画像のrole/nameを取得。figureはrole figure。通常のfigcaptionだけではfigure nameなし、aria-labelledbyで指したfigcaption・aria-label・titleはfigure nameに反映。altあり画像はrole imageとaltを公開、alt=""はignored。figureとfigcaptionのみの条件でもaltなし画像のnameは空で、選定tentative WPTの期待値と異なった。Chromium browser AX Treeのみ。OS accessibility API、読み上げ・点字は未実測。詳細はdocs/atlas/figure-evidence-2026-11-01.md。 |
部分観測(Chrome AX Tree / CDP) |
Coverage / Open Issues
- 仕様確認済みfigure / figcaptionの定義、categories、配置、content model、HTML-AAMのrole/name規則、WAI-ARIA caption guidance
- 選定範囲のみ実測Chromiumの単一環境、fixtureおよび日英4ページ、選定WPT 2ファイルの範囲。詳細値と例外はEvidence行を参照
- 未実施Firefox・Safari等の比較、Windows UI Automation / IAccessible2 / macOS AX / ATK、読み上げ・点字、WPTの全file
- 未解決・追跡対象figcaptionとfigureのAccessible Name / Descriptionに関するHTML-AAM・ARIA文書・実装間の扱い。最新draftと実測対象を個別に再確認する
- レビュー未実施Expert-gap Reviewおよび複数の支援技術を使った利用者観点の確認
このTopicのブラウザーおよびWPT結果を、すべてのHTML-AAM requirement、ブラウザー、OS、支援技術への適合として一般化しません。HTML-AAMはWorking Draftで、今後変更される可能性があります。
Related surfaces
初心者向けの使い方はYugienのfigure要素ページを参照してください。画像自体のalt・選択処理はimg Topic、表に付けるcaptionとtable nameはcaption Topic、画像内のリンク領域はimage maps Topicで扱います。
article・sectionの内容境界はarticle Topicとsection Topicを参照してください。