参见英文答案 >
What is aria-label and how should I use it? 3
我习惯于在我的链接/按钮/ …上使用title =“”属性来详细说明.但是,由于可理解的原因,引导程序使用了很多aria-label =“”属性,据我所知.
所以我想起来创建如下的按钮:
id="show-raw-result"
class="btn btn-default btn-sm btn-twigfiddle"
title="Result was not easily readable so it has been automatically cleaned up, use this button to see the result raw"
aria-label="Result was not easily readable so it has been automatically cleaned up, use this button to see the result raw">
Show raw result
但是,复制/粘贴标题来创建一个咏叹调标签看起来很丑陋.我应该选择哪一个,为什么?