1 | select,option{ |
2 | text-align : right ; |
3 | } |
1、添加 dir 属性,适合中文,但是会导致英文单词或者有空格的地方文字变成从右到左。
1 | < select dir = "rtl" > |
2 | < option >Foo</ option > |
3 | < option >bar</ option > |
4 | < option >to the right</ option > |
5 | </ select > |
1 | select { |
2 | direction : rtl ; |
3 | } |
4 | select option { |
5 | direction : ltr ; |
6 | } |