CSS Html:Chrome上选定文本区域的圆角
我正在尝试添加一个圆角文本区域到我的网站 我正在使用这个css:CSS Html:Chrome上选定文本区域的圆角,css,google-chrome,rounded-corners,Css,Google Chrome,Rounded Corners,我正在尝试添加一个圆角文本区域到我的网站 我正在使用这个css: -webkit-border-radius: 6px; -moz-border-radius: 6px; border-radius: 6px; 现在,这在chrome中正确显示,但是当textarea获得焦点时,textarea会添加一个橙色边框,这样的边框没有圆角 你知道怎么解决这个问题吗 谢谢textarea:focus{outline:none}应该这样做,尽管在没有看到的情况下很难回答删除默认的大纲,然后用一个更符合
-webkit-border-radius: 6px;
-moz-border-radius: 6px;
border-radius: 6px;
现在,这在chrome中正确显示,但是当textarea获得焦点时,textarea会添加一个橙色边框,这样的边框没有圆角
你知道怎么解决这个问题吗
谢谢
textarea:focus{outline:none}
应该这样做,尽管在没有看到的情况下很难回答删除默认的大纲
,然后用一个更符合……风格的大纲来模拟该大纲:
textarea {
width: 40%;
height: 10em;
border-radius: 1em;
border: 1px solid #000; /* everything up to and including this line
are aesthetics, adjust to taste */
outline: none; /* removes the default outline */
resize: none; /* prevents the user-resizing, adjust to taste */
}
textarea:focus {
box-shadow: inset 0 0 3px 2px #f90; /* provides a more style-able
replacement to the outline */
}
.将此css添加到
textarea、textarea:focus
和outline:1px solid\ccc代码>将删除该橙色边框。