SVG 访问性
· 3 min read
按钮必须有可访问名称(对屏幕阅读器来说有“名字”),这个名字可以来自按钮的可见文本、aria-label、或 aria-labelledby;如果 SVG 只是装饰,给它 aria-hidden="true"(同时 focusable="false");如果 SVG 本身承载语义(例如显示状态),确保它参与名称或用 ARIA 状态描述按钮(例如 aria-pressed / aria-expanded)。
按钮必须有可访问名称(对屏幕阅读器来说有“名字”),这个名字可以来自按钮的可见文本、aria-label、或 aria-labelledby;如果 SVG 只是装饰,给它 aria-hidden="true"(同时 focusable="false");如果 SVG 本身承载语义(例如显示状态),确保它参与名称或用 ARIA 状态描述按钮(例如 aria-pressed / aria-expanded)。
Docusaurus blogging features are powered by the blog plugin.
Here are a few tips you might find useful.
Blog posts support Docusaurus Markdown features, such as MDX.
Use the power of React to create interactive blog posts.
This is the summary of a very long blog post,
Use a <!-- truncate --> comment to limit blog post size in the list view.
Lorem ipsum dolor sit amet...