vue-element

修改input里placehoder字体颜色,解决firefox不生效问题

 <div class="search">
     <el-input
               v-model="formInline.searchName"
               class="pool-search"
               style="width:666px;"
               placeholder="请输入名称进行搜索"
               :trigger-on-focus="false"
               @keyup.enter.native="handleSelect"
               >
         <span slot="suffix" class="iconfont" @click="handleIconClick">&#xe6fc;</span>
     </el-input>
</div>
.el-input__inner {
      &::placeholder {
        color: #696969;
      }
      &::-webkit-input-placeholder {
        /* Chrome/Opera/Safari */
        color: #696969;
      }
      &:-moz-placeholder {
        /* Mozilla Firefox 4 to 18 适配火狐 */
        color: #696969;
        /* 设置opacity  解决firefox不生效问题 */
        opacity: 1;
      }
      &::-moz-placeholder {
        /* Mozilla Firefox 19+ 适配火狐 */
        color: #696969;
        opacity: 1;
      }
      &:-ms-input-placeholder {
        /* Internet Explorer 10+  适配ie*/
        color: #696969;
      }
    }
Logo

前往低代码交流专区

更多推荐