收藏
回答

radio组件disabled后color无效?

radio组件disabled后color无效!

代码片段

<radio checked="{{true}}" color="#f78209disabled="{{true}}"></radio>

基础库 2.17.0

回答关注问题邀请回答
收藏

3 个回答

  • Cjiang
    Cjiang
    2021-10-14

    disabled后 是呈现灰色的

    2021-10-14
    有用
    回复 2
    • F
      F
      2021-10-14
      这样子的
      2021-10-14
      回复
    • Cjiang
      Cjiang
      2021-10-15回复F
      试下其他开发者的使用方法
      2021-10-15
      回复
  • 会画画的猿
    会画画的猿
    2021-10-13

    自定义吧

    2021-10-13
    有用
    回复
  • 朝酒晚舞
    朝酒晚舞
    2021-10-13

    给你的wxss加上这个:

    radio .wx-radio-input.wx-radio-input-disabled {
      border : 2rpx solid #999999;
      border-radius: 100%;
      background : #f78209;
    }
    radio .wx-radio-input.wx-radio-input-checked {
      border-color: #f78209 !important;
      background : #f78209 !important;
      }
      
      radio .wx-radio-input.wx-radio-input-checked::before {
      border-radius : 50%;
      width : 20px;
      height : 20px;
      line-height : 20px;
      text-align : center;
      font-size : 15px;
      color : #fff;
      background : transparent;
      transform : translate(-50%, -50%) scale(1);
      -webkit-transform: translate(-50%, -50%) scale(1);
      }
    
    2021-10-13
    有用
    回复
登录 后发表内容