element ui 穿梭框宽度调整
<!-- 首先穿梭框设置ref用于引用 --> <el-transfer ref="grant_transfer" v-model="grant.value" :data="grant.data"></el-transfer> <script> //... ... /* 穿梭框 赋值后*/ this.$nextTick(function () { this.$refs.grant_transfer.$el.querySelectorAll('div.el-transfer-panel').forEach(p=>p.style.width='280px'); }); //... ... <script>