修改el-radio-group 自适应

/* 修改rodio 自适应
*  
*/
.radio4 .el-radio-group {
  width: 100%;

}
.radio4 .el-radio-group{
  .el-radio-button {
    width: 25%!important;
    
  }
  .el-radio-button__inner {
    width: 100%!important;
    padding-left: 0!important;
    padding-right: 0!important;
    text-align: center;
  }

html

                <el-col :span="6" class="radio4">
                                <el-radio-group v-model="dateKey" size="medium"  @change="onDateKey">
                                    <el-radio-button label="1" style="max-width:70px">今天</el-radio-button>
                                    <el-radio-button label="2" style="max-width:70px">昨天</el-radio-button>
                                    <el-radio-button label="3" style="max-width:70px">本月</el-radio-button>
                                    <el-radio-button label="4" style="max-width:70px">上月</el-radio-button>
                                </el-radio-group>
                            </el-col>

 

posted @ 2022-04-15 18:22  front-gl  阅读(4105)  评论(0编辑  收藏  举报