使用普通的組件樣式修改方法,對popover是不生效的。經(jīng)過查閱文檔發(fā)現(xiàn)菱肖,el提供了popper-class方法
用法
'popper-class'='popperClass' //添加類名
不要添加scoped疚宇。如果與項目沖突可新添加style標簽
<style lang="scss">
.el-popover.popperClass {
min-width: 80px;
}
</style>
時間組件默認選中當前月與上一個月
const start = dayjs().add(-1, 'month').startOf('month')
this.riQi = [start.$d, new Date()]