配合\n
修改样式,此方法还是不太可取 虽然可以实现
html:
<el-table-column align="center" label="操作" fixed="right" width="190">
<template slot-scope="{ row }">
<el-button v-if="checkBtn('11')" type="text" >查看</el-button>
<el-popconfirm :title="'换行测试换行测试\n将会被删除,确定要清空吗?'" @onConfirm="handleRemove(row)">
<el-button slot="reference" type="text">清空</el-button>
</el-popconfirm>
</template>
</el-table-column>
</el-table>
scss:
.el-popconfirm__main {
white-space: pre-line;
margin: -14px 0 4px;
}
.el-popconfirm__main > i {
margin-top: 22px;
margin-bottom: auto;
}
网友评论