What is sr-only in Bootstrap 3?

后端 未结 6 857
猫巷女王i
猫巷女王i 2020-11-22 09:23

What is the class sr-only used for? Is it important or can I remove it? Works fine without.

Here\'s my example:

6条回答
  •  闹比i
    闹比i (楼主)
    2020-11-22 10:27

    I found this in the navbar example, and simplified it.

    
    

    You see which one is selected (sr-only part is hidden):

    • Default
    • Static top
    • Fixed top

    You hear which one is selected if you use screen reader:

    • Default
    • Static top
    • Fixed top (current)

    As a result of this technique blind people supposed to navigate easier on your website.

提交回复
热议问题