Table of contents entries in the reference guide have no space between number and title for screen readers
维护者通常 1 天内回复
还没有人认领这个 Issue。
评估
- 难度
- 1/5
- 预计耗时
- 1 小时以内
- 新手友好度
- 70/100
- Issue 类型
- 缺陷
- 描述清晰度
- 描述清楚
- 活跃度
- 活跃
- 技术栈
- css, html, javascript
调研方向
打开 wicket-user-guide/src/main/asciidoc/js/guide.js 并阅读 followSections():它把每个 TOC 链接拆成一个 span.toc-num 加一个文本节点,并丢弃两者之间的空白。保留文本节点中的空格(例如追加 ' ' + match[2]),然后移除 wicket.css 中 .toc-num 上的 margin-right,这样视觉间隙就不会加倍。构建指南并确认 TOC 看起来没有变化,且某个链接的可访问名称读作 "3. Why should I learn Wicket?"。与 #1904 协调,它编辑了相同的行,应当先落地。
由索引模型根据 Issue 内容生成。
描述
The entries in the reference guide's table of contents have no space between the section number and the title in their text. Screen readers announce them as, for example, "3.Why should I learn Wicket?" and "13.4.Pageable repeaters".
The cause is followSections() in wicket-user-guide/src/main/asciidoc/js/guide.js. It splits each TOC link into a span.toc-num holding the number and a text node holding the title, and drops the whitespace in between. The visual gap comes from margin-right on .toc-num in wicket.css, so on screen it looks fine, but the link's text content and accessible name have no space. This was introduced in #1845.
The same text ends up in other names built from the link. In #1904 the disclosure buttons are labelled "Sections for 3.Why should I learn Wicket?".
Fix: keep the space in the text when the link is split up. One way is to append ' ' + match[2] instead of match[2] and drop the margin-right from .toc-num. Then check that the TOC still looks the same and that the accessible names read "3. Why should I learn Wicket?".
This touches the same lines in guide.js as #1904, so it should wait until #1904 is merged.
- 主要语言
- Java
- 星标
- 800
- 派生
- 423
- 平均合并
- 1 天 1 小时
- 30 天内合并 PR
- 170
环境准备
这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
apache/wicket 的其他 Issue
-
难度 2/5 1-3 小时 新手友好度 76/100
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 82/100
维护者通常 1 天内回复
-
Fix dark-mode table headers and phone-width overflow in the reference guide's CSS可能已有人在做 关联的 PR 仍在进行中或已合并。 未关闭
难度 2/5 1-3 小时 新手友好度 72/100
维护者通常 1 天内回复
-
Document and enforce pull request review guidelines可能已有人在做 @dashorst 于 7 天前认领。 未关闭
难度 2/5 1-3 小时 新手友好度 76/100
维护者通常 1 天内回复
-
COOP and COEP exemptions compare with the context path, so page exemptions never match可能已有人在做 @asvanberg 于 25 天前认领。 未关闭
难度 2/5 1-3 小时 新手友好度 67/100
apache/wicket#1661 · 1 条评论 · 1 个 reaction ·
维护者通常 1 天内回复
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 80/100
维护者通常 1 天内回复
-
RIS export splits an organization name containing “and” into multiple authors可能已有人在做 @Gautam-aman 今天认领。 未关闭status: needs-triage
难度 2/5 1-3 小时 新手友好度 78/100
维护者通常 1 天内回复
-
FailureContext.java rounds down thresholds in lastedAtLeast()可能已有人在做 关联的 PR 仍在进行中或已合并。 未关闭
难度 2/5 1-3 小时 新手友好度 82/100
维护者通常 1 天内回复
-
难度 1/5 1 小时以内 新手友好度 86/100
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 82/100
维护者通常 1 天内回复