@readium/guided-navigation 1.3.0 → 1.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (306) hide show
  1. package/README.md +6 -6
  2. package/dist/a11y.js +1 -1
  3. package/dist/converter.js +1 -1
  4. package/dist/elementHandlers.js +1 -1
  5. package/dist/emptyPairs.js +1 -1
  6. package/dist/index.js +1 -1
  7. package/dist/object.js +1 -1
  8. package/dist/textrefFragment.js +1 -1
  9. package/fixtures/README.md +4 -4
  10. package/fixtures/ROLES_COVERAGE.md +3 -3
  11. package/fixtures/abbreviation-acronym-html-native/gnd.json +3 -5
  12. package/fixtures/abbreviation-before-formatting/gnd.json +3 -5
  13. package/fixtures/abbreviation-before-image/gnd.json +10 -14
  14. package/fixtures/abbreviation-html-native/gnd.json +3 -5
  15. package/fixtures/abbreviation-language/gnd.json +3 -5
  16. package/fixtures/abbreviation-line-break/gnd.json +3 -5
  17. package/fixtures/abbreviation-nested/gnd.json +3 -5
  18. package/fixtures/abbreviation-nested-emphasis/gnd.json +3 -5
  19. package/fixtures/abbreviation-nested-term/gnd.json +4 -8
  20. package/fixtures/abbreviation-nested-term-punctuation/gnd.json +4 -8
  21. package/fixtures/abbreviation-no-title/gnd.json +1 -3
  22. package/fixtures/abbreviation-period-mid-sentence/gnd.json +3 -5
  23. package/fixtures/abbreviation-period-sentence-end/gnd.json +3 -5
  24. package/fixtures/abbreviation-spanning-terms/gnd.json +3 -9
  25. package/fixtures/abbreviation-with-image/gnd.json +10 -14
  26. package/fixtures/abbreviation-with-svg-and-math/gnd.json +15 -21
  27. package/fixtures/abstract-epub-type/gnd.json +3 -7
  28. package/fixtures/abstract-role-aria/gnd.json +1 -3
  29. package/fixtures/accessible-name-labelledby-aria-hidden/gnd.json +2 -7
  30. package/fixtures/accessible-name-labelledby-hidden-attribute/gnd.json +2 -7
  31. package/fixtures/acknowledgments-epub-type/gnd.json +3 -7
  32. package/fixtures/acknowledgments-role-aria/gnd.json +1 -3
  33. package/fixtures/afterword-epub-type/gnd.json +3 -7
  34. package/fixtures/afterword-role-aria/gnd.json +1 -3
  35. package/fixtures/appendix-epub-type/gnd.json +3 -8
  36. package/fixtures/appendix-role-aria/gnd.json +1 -3
  37. package/fixtures/article-html-native/gnd.json +1 -3
  38. package/fixtures/article-role-aria/gnd.json +2 -4
  39. package/fixtures/aside-epub-type/gnd.json +3 -7
  40. package/fixtures/aside-html-native/gnd.json +1 -3
  41. package/fixtures/audio-html-native/gnd.json +3 -5
  42. package/fixtures/audio-no-description/gnd.json +2 -4
  43. package/fixtures/backlink-epub-type/gnd.json +3 -8
  44. package/fixtures/backlink-role-aria/gnd.json +2 -5
  45. package/fixtures/bibliography-epub-type/gnd.json +7 -18
  46. package/fixtures/bibliography-role-aria/gnd.json +4 -12
  47. package/fixtures/biblioref-epub-type/gnd.json +3 -8
  48. package/fixtures/biblioref-role-aria/gnd.json +2 -5
  49. package/fixtures/biblioref-target-descendant-ids/gnd.json +31 -49
  50. package/fixtures/biblioref-target-in-bibliography-role-aria/gnd.json +16 -29
  51. package/fixtures/biblioref-target-mixed-content/gnd.json +27 -36
  52. package/fixtures/blockquote-html-native/gnd.json +1 -3
  53. package/fixtures/blockquote-role-aria/gnd.json +2 -4
  54. package/fixtures/body-html-native/gnd.json +1 -3
  55. package/fixtures/chapter-epub-type/gnd.json +4 -11
  56. package/fixtures/chapter-role-aria/gnd.json +2 -7
  57. package/fixtures/colophon-epub-type/gnd.json +3 -7
  58. package/fixtures/colophon-role-aria/gnd.json +1 -3
  59. package/fixtures/complementary-role-aria/gnd.json +1 -3
  60. package/fixtures/conclusion-epub-type/gnd.json +3 -7
  61. package/fixtures/conclusion-role-aria/gnd.json +1 -3
  62. package/fixtures/cover-epub-type/gnd.json +5 -12
  63. package/fixtures/cover-role-aria/gnd.json +3 -6
  64. package/fixtures/credit-epub-type/gnd.json +4 -10
  65. package/fixtures/credit-role-aria/gnd.json +1 -3
  66. package/fixtures/credits-epub-type/gnd.json +9 -23
  67. package/fixtures/credits-role-aria/gnd.json +4 -14
  68. package/fixtures/dedication-epub-type/gnd.json +3 -7
  69. package/fixtures/dedication-role-aria/gnd.json +1 -3
  70. package/fixtures/definition-epub-type/gnd.json +4 -10
  71. package/fixtures/definition-html-native/gnd.json +1 -3
  72. package/fixtures/definition-role-aria/gnd.json +1 -3
  73. package/fixtures/description-roleless-lone-child/gnd.json +5 -9
  74. package/fixtures/description-roleless-wrapper/gnd.json +8 -12
  75. package/fixtures/details-html-native/gnd.json +1 -3
  76. package/fixtures/details-summary-html-native/gnd.json +2 -6
  77. package/fixtures/endnotes-epub-type/gnd.json +9 -26
  78. package/fixtures/endnotes-role-aria/gnd.json +4 -14
  79. package/fixtures/epigraph-epub-type/gnd.json +3 -7
  80. package/fixtures/epigraph-role-aria/gnd.json +1 -3
  81. package/fixtures/epilogue-epub-type/gnd.json +3 -7
  82. package/fixtures/epilogue-role-aria/gnd.json +1 -3
  83. package/fixtures/errata-epub-type/gnd.json +3 -7
  84. package/fixtures/errata-role-aria/gnd.json +1 -3
  85. package/fixtures/example-epub-type/gnd.json +5 -14
  86. package/fixtures/example-role-aria/gnd.json +1 -3
  87. package/fixtures/figure-aria-label-caption/gnd.json +19 -0
  88. package/fixtures/figure-aria-label-caption/input.html +1 -0
  89. package/fixtures/figure-aria-label-caption/meta.json +12 -0
  90. package/fixtures/figure-basic-html-native/gnd.json +4 -8
  91. package/fixtures/figure-basic-role-aria/gnd.json +4 -8
  92. package/fixtures/figure-caption-block-content/gnd.json +33 -0
  93. package/fixtures/figure-caption-block-content/input.html +7 -0
  94. package/fixtures/figure-caption-block-content/meta.json +14 -0
  95. package/fixtures/figure-caption-element-html-native/gnd.json +14 -8
  96. package/fixtures/figure-caption-element-html-native/meta.json +1 -1
  97. package/fixtures/figure-caption-element-role-aria/gnd.json +14 -8
  98. package/fixtures/figure-caption-element-role-aria/meta.json +1 -1
  99. package/fixtures/figure-caption-html-native/gnd.json +3 -5
  100. package/fixtures/figure-caption-role-aria/gnd.json +3 -5
  101. package/fixtures/figure-credit-nested-in-aria-labelledby-caption/gnd.json +13 -21
  102. package/fixtures/figure-credit-nested-in-caption/gnd.json +13 -21
  103. package/fixtures/figure-credit-nested-in-caption/meta.json +1 -1
  104. package/fixtures/figure-credit-role-aria/gnd.json +12 -18
  105. package/fixtures/figure-credit-role-aria/meta.json +1 -1
  106. package/fixtures/figure-describedby/gnd.json +4 -8
  107. package/fixtures/figure-epub-type/gnd.json +5 -11
  108. package/fixtures/figure-no-description/gnd.json +3 -7
  109. package/fixtures/footnote-epub-type/gnd.json +5 -14
  110. package/fixtures/footnote-role-aria/gnd.json +17 -31
  111. package/fixtures/foreword-epub-type/gnd.json +3 -7
  112. package/fixtures/foreword-role-aria/gnd.json +1 -3
  113. package/fixtures/glossary-epub-type/gnd.json +10 -22
  114. package/fixtures/glossary-role-aria/gnd.json +5 -15
  115. package/fixtures/glossref-epub-type/gnd.json +3 -8
  116. package/fixtures/glossref-role-aria/gnd.json +2 -5
  117. package/fixtures/glossref-role-aria-mid-sentence/gnd.json +5 -13
  118. package/fixtures/glossref-sole-content/gnd.json +11 -26
  119. package/fixtures/glossref-target-in-glossary-role-aria/gnd.json +17 -32
  120. package/fixtures/glossref-target-percent-encoded/gnd.json +17 -32
  121. package/fixtures/glossref-target-percent-encoded/meta.json +1 -1
  122. package/fixtures/header-html-native/gnd.json +1 -3
  123. package/fixtures/heading-html-native/gnd.json +6 -18
  124. package/fixtures/heading-role-aria/gnd.json +6 -18
  125. package/fixtures/heading-role-presentation/gnd.json +6 -12
  126. package/fixtures/hidden-aria-hidden-html-native/gnd.json +2 -6
  127. package/fixtures/hidden-attribute-html-native/gnd.json +2 -6
  128. package/fixtures/image-alt-html-native/gnd.json +3 -5
  129. package/fixtures/image-decorative-empty-alt/gnd.json +2 -6
  130. package/fixtures/image-decorative-role-presentation/gnd.json +2 -6
  131. package/fixtures/image-decorative-whitespace-alt/gnd.json +4 -8
  132. package/fixtures/image-no-description/gnd.json +2 -4
  133. package/fixtures/image-role-aria/gnd.json +3 -5
  134. package/fixtures/index-epub-type/gnd.json +11 -32
  135. package/fixtures/index-role-aria/gnd.json +10 -28
  136. package/fixtures/introduction-epub-type/gnd.json +3 -7
  137. package/fixtures/introduction-role-aria/gnd.json +1 -3
  138. package/fixtures/landmarks-epub-type/gnd.json +15 -43
  139. package/fixtures/language-alt-inherited/gnd.json +8 -12
  140. package/fixtures/language-alt-own-lang/gnd.json +8 -12
  141. package/fixtures/language-block/gnd.json +5 -11
  142. package/fixtures/language-block-empty-lang/gnd.json +1 -3
  143. package/fixtures/language-describedby-shared/gnd.json +19 -27
  144. package/fixtures/language-document/gnd.json +3 -7
  145. package/fixtures/language-empty-lang-stops-inheritance/gnd.json +6 -10
  146. package/fixtures/language-figcaption/gnd.json +13 -16
  147. package/fixtures/language-figcaption/meta.json +1 -1
  148. package/fixtures/language-figcaption-credit/gnd.json +17 -25
  149. package/fixtures/language-figcaption-credit/meta.json +1 -1
  150. package/fixtures/language-figcaption-switches/gnd.json +13 -15
  151. package/fixtures/language-figcaption-switches/meta.json +1 -1
  152. package/fixtures/language-figcaption-switches-throughout/gnd.json +13 -16
  153. package/fixtures/language-figcaption-switches-throughout/meta.json +1 -1
  154. package/fixtures/language-inline-case-insensitive/gnd.json +3 -5
  155. package/fixtures/language-inline-case-insensitive-ssml/gnd.json +3 -5
  156. package/fixtures/language-inline-empty-lang/gnd.json +3 -5
  157. package/fixtures/language-inline-empty-lang-formatted/gnd.json +1 -3
  158. package/fixtures/language-inline-empty-lang-only/gnd.json +1 -3
  159. package/fixtures/language-inline-empty-lang-undeclared/gnd.json +3 -5
  160. package/fixtures/language-inline-lang-attribute/gnd.json +3 -5
  161. package/fixtures/language-inline-nested/gnd.json +3 -5
  162. package/fixtures/language-inline-repeated/gnd.json +3 -5
  163. package/fixtures/language-inline-two-languages/gnd.json +3 -5
  164. package/fixtures/language-labelledby-target/gnd.json +8 -12
  165. package/fixtures/language-labelledby-target-aria-label/gnd.json +12 -16
  166. package/fixtures/language-labelledby-target-switches/gnd.json +6 -10
  167. package/fixtures/language-labelledby-targets-case/gnd.json +11 -17
  168. package/fixtures/language-labelledby-targets-differ/gnd.json +9 -15
  169. package/fixtures/language-link-switches/gnd.json +10 -13
  170. package/fixtures/language-pagebreak-label/gnd.json +10 -14
  171. package/fixtures/language-undeclared-description/gnd.json +4 -8
  172. package/fixtures/language-xml-lang-empty-html-inherits/gnd.json +8 -12
  173. package/fixtures/language-xml-lang-empty-html-lang-applies/gnd.json +8 -12
  174. package/fixtures/language-xml-lang-empty-xhtml/gnd.json +6 -10
  175. package/fixtures/language-xml-lang-over-lang/gnd.json +8 -12
  176. package/fixtures/link-containing-image/gnd.json +12 -17
  177. package/fixtures/link-containing-pagebreak/gnd.json +12 -17
  178. package/fixtures/link-content-conversion/gnd.json +14 -20
  179. package/fixtures/link-content-identity/gnd.json +7 -8
  180. package/fixtures/link-content-words/gnd.json +9 -14
  181. package/fixtures/list-aria-posinset-setsize/gnd.json +3 -7
  182. package/fixtures/list-epub-type/gnd.json +6 -14
  183. package/fixtures/list-html-native/gnd.json +4 -12
  184. package/fixtures/list-item-posinset-override/gnd.json +7 -15
  185. package/fixtures/list-item-value-override/gnd.json +7 -15
  186. package/fixtures/list-ordered-html-native/gnd.json +7 -15
  187. package/fixtures/list-ordered-reversed/gnd.json +7 -15
  188. package/fixtures/list-ordered-start/gnd.json +7 -15
  189. package/fixtures/list-role-aria/gnd.json +4 -12
  190. package/fixtures/listitem-role-presentation/gnd.json +5 -11
  191. package/fixtures/loa-epub-type/gnd.json +11 -32
  192. package/fixtures/loi-epub-type/gnd.json +11 -32
  193. package/fixtures/lot-epub-type/gnd.json +11 -32
  194. package/fixtures/lov-epub-type/gnd.json +11 -32
  195. package/fixtures/main-html-native/gnd.json +1 -3
  196. package/fixtures/main-role-aria/gnd.json +1 -3
  197. package/fixtures/manifest.json +51 -11
  198. package/fixtures/math-html-native/gnd.json +5 -7
  199. package/fixtures/math-inline/gnd.json +10 -14
  200. package/fixtures/math-no-description/gnd.json +3 -5
  201. package/fixtures/math-role-aria/gnd.json +5 -7
  202. package/fixtures/navigation-html-native/gnd.json +1 -3
  203. package/fixtures/navigation-role-aria/gnd.json +1 -3
  204. package/fixtures/nested-blockquote/gnd.json +3 -9
  205. package/fixtures/nested-section/gnd.json +3 -9
  206. package/fixtures/noteref-after-closing-straight-quote/gnd.json +13 -20
  207. package/fixtures/noteref-after-closing-straight-quote-split/gnd.json +12 -17
  208. package/fixtures/noteref-enclosed-across-formatting/gnd.json +13 -20
  209. package/fixtures/noteref-enclosed-adjacent-pairs/gnd.json +38 -62
  210. package/fixtures/noteref-enclosed-adjacent-text/gnd.json +16 -23
  211. package/fixtures/noteref-enclosed-before-formatting/gnd.json +16 -23
  212. package/fixtures/noteref-enclosed-guillemets-french/gnd.json +42 -63
  213. package/fixtures/noteref-enclosed-quotes-chinese/gnd.json +15 -25
  214. package/fixtures/noteref-enclosed-quotes-german/gnd.json +49 -75
  215. package/fixtures/noteref-enclosed-quotes-swedish/gnd.json +28 -42
  216. package/fixtures/noteref-enclosed-straight-quotes/gnd.json +13 -20
  217. package/fixtures/noteref-in-lone-block/gnd.json +12 -17
  218. package/fixtures/noteref-role-aria/gnd.json +1 -3
  219. package/fixtures/noteref-target-in-endnotes-epub-type/gnd.json +10 -29
  220. package/fixtures/noteref-target-in-endnotes-role-aria/gnd.json +9 -26
  221. package/fixtures/noteref-target-malformed-escape/gnd.json +13 -20
  222. package/fixtures/noteref-target-percent-encoded/gnd.json +13 -20
  223. package/fixtures/notice-epub-type/gnd.json +3 -7
  224. package/fixtures/notice-role-aria/gnd.json +1 -3
  225. package/fixtures/pagebreak-epub-type/gnd.json +6 -14
  226. package/fixtures/pagebreak-role-aria/gnd.json +5 -11
  227. package/fixtures/pagelist-epub-type/gnd.json +15 -43
  228. package/fixtures/pagelist-role-aria/gnd.json +14 -40
  229. package/fixtures/paragraph-basic/gnd.json +1 -3
  230. package/fixtures/part-epub-type/gnd.json +4 -11
  231. package/fixtures/part-role-aria/gnd.json +2 -7
  232. package/fixtures/preface-epub-type/gnd.json +3 -7
  233. package/fixtures/preface-role-aria/gnd.json +1 -3
  234. package/fixtures/preformatted-html-native/gnd.json +1 -3
  235. package/fixtures/presentation-role-aria/gnd.json +1 -3
  236. package/fixtures/prologue-epub-type/gnd.json +3 -7
  237. package/fixtures/prologue-role-aria/gnd.json +1 -3
  238. package/fixtures/pullquote-epub-type/gnd.json +3 -8
  239. package/fixtures/pullquote-role-aria/gnd.json +1 -3
  240. package/fixtures/qna-epub-type/gnd.json +3 -8
  241. package/fixtures/qna-role-aria/gnd.json +1 -3
  242. package/fixtures/redundant-role-body-chapter/gnd.json +3 -10
  243. package/fixtures/redundant-role-nested-chapter/gnd.json +4 -13
  244. package/fixtures/region-role-aria/gnd.json +1 -3
  245. package/fixtures/section-html-native/gnd.json +1 -3
  246. package/fixtures/separator-html-native/gnd.json +3 -9
  247. package/fixtures/separator-role-aria/gnd.json +3 -9
  248. package/fixtures/separator-with-glyphs/gnd.json +3 -9
  249. package/fixtures/subtitle-epub-type/gnd.json +3 -7
  250. package/fixtures/subtitle-role-aria/gnd.json +1 -3
  251. package/fixtures/summary-html-native/gnd.json +1 -3
  252. package/fixtures/table-aria-label-caption/gnd.json +27 -0
  253. package/fixtures/table-aria-label-caption/input.html +1 -0
  254. package/fixtures/table-aria-label-caption/meta.json +13 -0
  255. package/fixtures/table-caption/gnd.json +22 -42
  256. package/fixtures/table-caption/meta.json +1 -1
  257. package/fixtures/table-caption-aria-labelledby/gnd.json +28 -0
  258. package/fixtures/table-caption-aria-labelledby/input.html +1 -0
  259. package/fixtures/table-caption-aria-labelledby/meta.json +13 -0
  260. package/fixtures/table-caption-element-html-native/gnd.json +13 -22
  261. package/fixtures/table-caption-element-html-native/meta.json +1 -1
  262. package/fixtures/table-caption-role-aria/gnd.json +10 -15
  263. package/fixtures/table-cell-abbreviation/gnd.json +8 -16
  264. package/fixtures/table-cell-link/gnd.json +8 -19
  265. package/fixtures/table-cell-noteref/gnd.json +15 -25
  266. package/fixtures/table-colspan-html-native/gnd.json +9 -21
  267. package/fixtures/table-colspan-role-aria/gnd.json +9 -21
  268. package/fixtures/table-epub-type/gnd.json +7 -17
  269. package/fixtures/table-html-native/gnd.json +10 -30
  270. package/fixtures/table-in-role-none-wrapper/gnd.json +6 -18
  271. package/fixtures/table-nested-html-native/gnd.json +7 -19
  272. package/fixtures/table-nested-in-presentation-table/gnd.json +8 -24
  273. package/fixtures/table-nested-role-aria/gnd.json +7 -19
  274. package/fixtures/table-no-headers/gnd.json +11 -25
  275. package/fixtures/table-role-aria/gnd.json +10 -30
  276. package/fixtures/table-role-presentation-explicit-cell/gnd.json +4 -12
  277. package/fixtures/table-role-presentation-html-native/gnd.json +7 -17
  278. package/fixtures/table-role-presentation-role-aria/gnd.json +7 -17
  279. package/fixtures/table-rowgroup-role-aria/gnd.json +4 -10
  280. package/fixtures/table-rowspan-html-native/gnd.json +9 -21
  281. package/fixtures/table-rowspan-role-aria/gnd.json +9 -21
  282. package/fixtures/table-sectioning/gnd.json +10 -24
  283. package/fixtures/table-th-no-scope/gnd.json +11 -25
  284. package/fixtures/term-epub-type/gnd.json +4 -10
  285. package/fixtures/term-html-native/gnd.json +1 -3
  286. package/fixtures/term-role-aria/gnd.json +1 -3
  287. package/fixtures/term-span-in-dt/gnd.json +3 -9
  288. package/fixtures/tip-epub-type/gnd.json +3 -8
  289. package/fixtures/tip-role-aria/gnd.json +1 -3
  290. package/fixtures/toc-epub-type/gnd.json +15 -43
  291. package/fixtures/toc-role-aria/gnd.json +14 -40
  292. package/fixtures/video-html-native/gnd.json +3 -5
  293. package/fixtures/video-no-description/gnd.json +2 -4
  294. package/package.json +6 -2
  295. package/src/a11y.ts +3 -12
  296. package/src/converter.ts +10 -45
  297. package/src/elementHandlers.ts +3 -12
  298. package/src/emptyPairs.ts +35 -15
  299. package/src/index.ts +2 -1
  300. package/src/object.ts +4 -10
  301. package/src/textrefFragment.ts +7 -16
  302. package/types/src/a11y.d.ts +0 -2
  303. package/types/src/converter.d.ts +0 -2
  304. package/types/src/emptyPairs.d.ts +3 -0
  305. package/types/src/index.d.ts +2 -1
  306. package/types/src/textrefFragment.d.ts +0 -4
@@ -1,7 +1,5 @@
1
1
  {
2
- "role": [
3
- "paragraph"
4
- ],
2
+ "role": ["paragraph"],
5
3
  "text": {
6
4
  "plain": "It is a truth universally acknowledged, that a single man in possession of a good fortune, must be in want of a wife."
7
5
  }
@@ -1,21 +1,14 @@
1
1
  {
2
- "role": [
3
- "body"
4
- ],
2
+ "role": ["body"],
5
3
  "children": [
6
4
  {
7
- "role": [
8
- "section",
9
- "part"
10
- ],
5
+ "role": ["section", "part"],
11
6
  "children": [
12
7
  {
8
+ "role": ["heading1"],
13
9
  "text": {
14
10
  "plain": "Title of the part"
15
- },
16
- "role": [
17
- "heading1"
18
- ]
11
+ }
19
12
  }
20
13
  ]
21
14
  }
@@ -1,13 +1,8 @@
1
1
  {
2
- "role": [
3
- "section",
4
- "part"
5
- ],
2
+ "role": ["section", "part"],
6
3
  "children": [
7
4
  {
8
- "role": [
9
- "heading1"
10
- ],
5
+ "role": ["heading1"],
11
6
  "text": {
12
7
  "plain": "Title of the part"
13
8
  }
@@ -1,15 +1,11 @@
1
1
  {
2
- "role": [
3
- "body"
4
- ],
2
+ "role": ["body"],
5
3
  "children": [
6
4
  {
5
+ "role": ["preface"],
7
6
  "text": {
8
7
  "plain": "This edition adds a chapter on automation."
9
- },
10
- "role": [
11
- "preface"
12
- ]
8
+ }
13
9
  }
14
10
  ]
15
11
  }
@@ -1,7 +1,5 @@
1
1
  {
2
- "role": [
3
- "preface"
4
- ],
2
+ "role": ["preface"],
5
3
  "text": {
6
4
  "plain": "This edition adds a chapter on automation."
7
5
  }
@@ -1,7 +1,5 @@
1
1
  {
2
- "role": [
3
- "preformatted"
4
- ],
2
+ "role": ["preformatted"],
5
3
  "text": {
6
4
  "plain": "10 PRINT \"HELLO\" 20 GOTO 10"
7
5
  }
@@ -1,7 +1,5 @@
1
1
  {
2
- "role": [
3
- "presentation"
4
- ],
2
+ "role": ["presentation"],
5
3
  "text": {
6
4
  "plain": "Decorative content with no semantic meaning."
7
5
  }
@@ -1,15 +1,11 @@
1
1
  {
2
- "role": [
3
- "body"
4
- ],
2
+ "role": ["body"],
5
3
  "children": [
6
4
  {
5
+ "role": ["prologue"],
7
6
  "text": {
8
7
  "plain": "Before the lamp was ever lit, the rock was already feared."
9
- },
10
- "role": [
11
- "prologue"
12
- ]
8
+ }
13
9
  }
14
10
  ]
15
11
  }
@@ -1,7 +1,5 @@
1
1
  {
2
- "role": [
3
- "prologue"
4
- ],
2
+ "role": ["prologue"],
5
3
  "text": {
6
4
  "plain": "Before the lamp was ever lit, the rock was already feared."
7
5
  }
@@ -1,16 +1,11 @@
1
1
  {
2
- "role": [
3
- "body"
4
- ],
2
+ "role": ["body"],
5
3
  "children": [
6
4
  {
5
+ "role": ["aside", "pullquote"],
7
6
  "text": {
8
7
  "plain": "The lamp still turns, though no one climbs the stairs anymore."
9
- },
10
- "role": [
11
- "aside",
12
- "pullquote"
13
- ]
8
+ }
14
9
  }
15
10
  ]
16
11
  }
@@ -1,7 +1,5 @@
1
1
  {
2
- "role": [
3
- "pullquote"
4
- ],
2
+ "role": ["pullquote"],
5
3
  "text": {
6
4
  "plain": "The lamp still turns, though no one climbs the stairs anymore."
7
5
  }
@@ -1,16 +1,11 @@
1
1
  {
2
- "role": [
3
- "body"
4
- ],
2
+ "role": ["body"],
5
3
  "children": [
6
4
  {
5
+ "role": ["section", "qna"],
7
6
  "text": {
8
7
  "plain": "Q: How often was the lamp refueled? A: Nightly, by hand."
9
- },
10
- "role": [
11
- "section",
12
- "qna"
13
- ]
8
+ }
14
9
  }
15
10
  ]
16
11
  }
@@ -1,7 +1,5 @@
1
1
  {
2
- "role": [
3
- "qna"
4
- ],
2
+ "role": ["qna"],
5
3
  "text": {
6
4
  "plain": "Q: How often was the lamp refueled? A: Nightly, by hand."
7
5
  }
@@ -1,23 +1,16 @@
1
1
  {
2
+ "role": ["body", "chapter"],
2
3
  "children": [
3
4
  {
5
+ "role": ["section"],
4
6
  "children": [
5
7
  {
6
- "role": [
7
- "paragraph"
8
- ],
8
+ "role": ["paragraph"],
9
9
  "text": {
10
10
  "plain": "It was a dark and stormy night."
11
11
  }
12
12
  }
13
- ],
14
- "role": [
15
- "section"
16
13
  ]
17
14
  }
18
- ],
19
- "role": [
20
- "body",
21
- "chapter"
22
15
  ]
23
16
  }
@@ -1,30 +1,21 @@
1
1
  {
2
+ "role": ["body"],
2
3
  "children": [
3
4
  {
5
+ "role": ["section", "chapter"],
4
6
  "children": [
5
7
  {
8
+ "role": ["section"],
6
9
  "children": [
7
10
  {
8
- "role": [
9
- "paragraph"
10
- ],
11
+ "role": ["paragraph"],
11
12
  "text": {
12
13
  "plain": "It was a dark and stormy night."
13
14
  }
14
15
  }
15
- ],
16
- "role": [
17
- "section"
18
16
  ]
19
17
  }
20
- ],
21
- "role": [
22
- "section",
23
- "chapter"
24
18
  ]
25
19
  }
26
- ],
27
- "role": [
28
- "body"
29
20
  ]
30
21
  }
@@ -1,7 +1,5 @@
1
1
  {
2
- "role": [
3
- "region"
4
- ],
2
+ "role": ["region"],
5
3
  "text": {
6
4
  "plain": "A named region of interest within the page."
7
5
  }
@@ -1,7 +1,5 @@
1
1
  {
2
- "role": [
3
- "section"
4
- ],
2
+ "role": ["section"],
5
3
  "text": {
6
4
  "plain": "The lighthouse was decommissioned in 1998, though its light still functions as a private aid to navigation."
7
5
  }
@@ -1,23 +1,17 @@
1
1
  {
2
2
  "children": [
3
3
  {
4
- "role": [
5
- "paragraph"
6
- ],
4
+ "role": ["paragraph"],
7
5
  "text": {
8
6
  "plain": "Section one."
9
7
  }
10
8
  },
11
9
  {
12
- "role": [
13
- "separator"
14
- ],
10
+ "role": ["separator"],
15
11
  "textref": "#css(hr)"
16
12
  },
17
13
  {
18
- "role": [
19
- "paragraph"
20
- ],
14
+ "role": ["paragraph"],
21
15
  "text": {
22
16
  "plain": "Section two."
23
17
  }
@@ -1,23 +1,17 @@
1
1
  {
2
2
  "children": [
3
3
  {
4
- "role": [
5
- "paragraph"
6
- ],
4
+ "role": ["paragraph"],
7
5
  "text": {
8
6
  "plain": "Section one."
9
7
  }
10
8
  },
11
9
  {
12
- "role": [
13
- "separator"
14
- ],
10
+ "role": ["separator"],
15
11
  "textref": "#css(div)"
16
12
  },
17
13
  {
18
- "role": [
19
- "paragraph"
20
- ],
14
+ "role": ["paragraph"],
21
15
  "text": {
22
16
  "plain": "Section two."
23
17
  }
@@ -1,25 +1,19 @@
1
1
  {
2
2
  "children": [
3
3
  {
4
- "role": [
5
- "paragraph"
6
- ],
4
+ "role": ["paragraph"],
7
5
  "text": {
8
6
  "plain": "Before."
9
7
  }
10
8
  },
11
9
  {
12
- "role": [
13
- "separator"
14
- ],
10
+ "role": ["separator"],
15
11
  "text": {
16
12
  "plain": "* * *"
17
13
  }
18
14
  },
19
15
  {
20
- "role": [
21
- "paragraph"
22
- ],
16
+ "role": ["paragraph"],
23
17
  "text": {
24
18
  "plain": "After."
25
19
  }
@@ -1,15 +1,11 @@
1
1
  {
2
- "role": [
3
- "body"
4
- ],
2
+ "role": ["body"],
5
3
  "children": [
6
4
  {
5
+ "role": ["subtitle"],
7
6
  "text": {
8
7
  "plain": "A History of Coastal Lights"
9
- },
10
- "role": [
11
- "subtitle"
12
- ]
8
+ }
13
9
  }
14
10
  ]
15
11
  }
@@ -1,7 +1,5 @@
1
1
  {
2
- "role": [
3
- "subtitle"
4
- ],
2
+ "role": ["subtitle"],
5
3
  "text": {
6
4
  "plain": "A History of Coastal Lights"
7
5
  }
@@ -1,7 +1,5 @@
1
1
  {
2
- "role": [
3
- "summary"
4
- ],
2
+ "role": ["summary"],
5
3
  "text": {
6
4
  "plain": "Click to expand"
7
5
  }
@@ -0,0 +1,27 @@
1
+ {
2
+ "role": ["table"],
3
+ "description": {
4
+ "text": {
5
+ "plain": "Engineering team"
6
+ }
7
+ },
8
+ "children": [
9
+ {
10
+ "role": ["caption"],
11
+ "text": {
12
+ "plain": "Team roster"
13
+ }
14
+ },
15
+ {
16
+ "role": ["row"],
17
+ "children": [
18
+ {
19
+ "role": ["cell"],
20
+ "text": {
21
+ "plain": "Ada"
22
+ }
23
+ }
24
+ ]
25
+ }
26
+ ]
27
+ }
@@ -0,0 +1 @@
1
+ <table aria-label="Engineering team"><caption>Team roster</caption><tr><td>Ada</td></tr></table>
@@ -0,0 +1,13 @@
1
+ {
2
+ "id": "table-aria-label-caption",
3
+ "description": "A table with an aria-label and a <caption> — the label becomes the table's description and the caption stays a caption child",
4
+ "role": "table",
5
+ "rolesCovered": [
6
+ "table",
7
+ "caption",
8
+ "row",
9
+ "cell"
10
+ ],
11
+ "sourceRef": "https://www.w3.org/TR/html-aam-1.0/",
12
+ "inputKind": "fragment"
13
+ }
@@ -1,81 +1,61 @@
1
1
  {
2
- "role": [
3
- "table"
4
- ],
2
+ "role": ["table"],
3
+ "description": {
4
+ "text": {
5
+ "plain": "Team roster"
6
+ }
7
+ },
5
8
  "children": [
6
9
  {
7
- "role": [
8
- "row"
9
- ],
10
+ "role": ["row"],
10
11
  "children": [
11
12
  {
13
+ "role": ["columnheader"],
12
14
  "text": {
13
15
  "plain": "Name"
14
- },
15
- "role": [
16
- "columnheader"
17
- ]
16
+ }
18
17
  },
19
18
  {
19
+ "role": ["columnheader"],
20
20
  "text": {
21
21
  "plain": "Role"
22
- },
23
- "role": [
24
- "columnheader"
25
- ]
22
+ }
26
23
  }
27
24
  ]
28
25
  },
29
26
  {
30
- "role": [
31
- "row"
32
- ],
27
+ "role": ["row"],
33
28
  "children": [
34
29
  {
30
+ "role": ["rowheader"],
35
31
  "text": {
36
32
  "plain": "Ada"
37
- },
38
- "role": [
39
- "rowheader"
40
- ]
33
+ }
41
34
  },
42
35
  {
36
+ "role": ["cell"],
43
37
  "text": {
44
38
  "plain": "Engineer"
45
- },
46
- "role": [
47
- "cell"
48
- ]
39
+ }
49
40
  }
50
41
  ]
51
42
  },
52
43
  {
53
- "role": [
54
- "row"
55
- ],
44
+ "role": ["row"],
56
45
  "children": [
57
46
  {
47
+ "role": ["rowheader"],
58
48
  "text": {
59
49
  "plain": "Grace"
60
- },
61
- "role": [
62
- "rowheader"
63
- ]
50
+ }
64
51
  },
65
52
  {
53
+ "role": ["cell"],
66
54
  "text": {
67
55
  "plain": "Admiral"
68
- },
69
- "role": [
70
- "cell"
71
- ]
56
+ }
72
57
  }
73
58
  ]
74
59
  }
75
- ],
76
- "description": {
77
- "text": {
78
- "plain": "Team roster"
79
- }
80
- }
60
+ ]
81
61
  }
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "id": "table-caption",
3
- "description": "A table with an accessible name via aria-label — the {description} branch of table's own announcement template. Uses aria-label rather than a native <caption> element since native <caption>/<figcaption> implicit accessible-name folding is not yet implemented (see CONTEXTUALIZATION_PLAN.md)",
3
+ "description": "A table with an accessible name via aria-label — the {description} branch of table's own announcement template. A native <caption> stays a caption child instead (see table-caption-element-html-native)",
4
4
  "role": "table",
5
5
  "rolesCovered": [
6
6
  "table",
@@ -0,0 +1,28 @@
1
+ {
2
+ "role": ["table"],
3
+ "description": {
4
+ "text": {
5
+ "plain": "Team roster"
6
+ }
7
+ },
8
+ "children": [
9
+ {
10
+ "role": ["caption"],
11
+ "id": "roster",
12
+ "text": {
13
+ "plain": "Team roster"
14
+ }
15
+ },
16
+ {
17
+ "role": ["row"],
18
+ "children": [
19
+ {
20
+ "role": ["cell"],
21
+ "text": {
22
+ "plain": "Ada"
23
+ }
24
+ }
25
+ ]
26
+ }
27
+ ]
28
+ }
@@ -0,0 +1 @@
1
+ <table aria-labelledby="roster"><caption id="roster">Team roster</caption><tr><td>Ada</td></tr></table>
@@ -0,0 +1,13 @@
1
+ {
2
+ "id": "table-caption-aria-labelledby",
3
+ "description": "A table labelled via aria-labelledby by its own <caption> — the caption text becomes the table's description, and the caption is still read as a caption child",
4
+ "role": "table",
5
+ "rolesCovered": [
6
+ "table",
7
+ "caption",
8
+ "row",
9
+ "cell"
10
+ ],
11
+ "sourceRef": "https://www.w3.org/TR/html-aam-1.0/",
12
+ "inputKind": "fragment"
13
+ }
@@ -1,40 +1,31 @@
1
1
  {
2
- "role": [
3
- "table"
4
- ],
5
- "description": {
6
- "text": {
7
- "plain": "Team roster"
8
- }
9
- },
2
+ "role": ["table"],
10
3
  "children": [
11
4
  {
12
- "role": [
13
- "row"
14
- ],
5
+ "role": ["caption"],
6
+ "text": {
7
+ "plain": "Team roster"
8
+ }
9
+ },
10
+ {
11
+ "role": ["row"],
15
12
  "children": [
16
13
  {
14
+ "role": ["columnheader"],
17
15
  "text": {
18
16
  "plain": "Name"
19
- },
20
- "role": [
21
- "columnheader"
22
- ]
17
+ }
23
18
  }
24
19
  ]
25
20
  },
26
21
  {
27
- "role": [
28
- "row"
29
- ],
22
+ "role": ["row"],
30
23
  "children": [
31
24
  {
25
+ "role": ["cell"],
32
26
  "text": {
33
27
  "plain": "Ada"
34
- },
35
- "role": [
36
- "cell"
37
- ]
28
+ }
38
29
  }
39
30
  ]
40
31
  }
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "id": "table-caption-element-html-native",
3
- "description": "A native <table><caption> with no explicit aria-labelledby — the caption becomes a separate child node with role \"caption\", not folded into the table's own description field. Directly demonstrates the caption-folding gap noted in CONTEXTUALIZATION_PLAN.md: table.md's spec assumes <caption> \"can end up in description\", but that implicit association isn't implemented. Contrast with table-caption (which uses explicit aria-label and does populate description) and table-caption-role-aria (the same un-folded-caption behavior via role=\"caption\")",
3
+ "description": "A native <table><caption> with no explicit aria-labelledby — the caption becomes a separate child node with role \"caption\", not folded into the table's own description. Contrast with table-caption (explicit aria-label, which populates description) and table-caption-role-aria (the same via role=\"caption\")",
4
4
  "role": "table",
5
5
  "rolesCovered": [
6
6
  "table",