从textarea中删除所有样式(边框,发光) [英] Remove all stylings (border, glow) from textarea

查看:193
本文介绍了从textarea中删除所有样式(边框,发光)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想从文本区域中删除样式,如果可能,将其留白,不带任何边框或发光。我尝试过不同的东西在这里找到SO,但没有什么工作(尝试与FF和Chrome)。

I want to remove the stylings from a textarea and leave it all white without any border or glow, if possible. I've tried with different stuff found here on SO, but nothing works (tried with FF and Chrome).

所以,是可能的,如果是如何做?

So, is it possible and if so how to do it?

>

我到目前为止所尝试的

textarea#story {
  // other stuff
  -moz-appearance:none;
  outline:0px none transparent;
}

textarea:focus, input:focus{
    outline: 0;
}

*:focus {
    outline: 0;
}


推荐答案

可能由box-shadow控制。除了添加什么Pavel说,你可以为不同的浏览器引擎添加box-shadow属性。

The glow effect is most-likely controlled by box-shadow. In addition to adding what Pavel said, you can add the box-shadow property for the different browser engines.

textarea {
    border: none;
    overflow: auto;
    outline: none;

    -webkit-box-shadow: none;
    -moz-box-shadow: none;
    box-shadow: none;
}

您也可以尝试添加!important以确定此CSS的优先级。

You may also try adding !important to prioritize this CSS.

这篇关于从textarea中删除所有样式(边框,发光)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆