根据面包屑的展开与隐藏控制样式
<div :class="classObj" class="app-wrapper">
主要的是classObj 这个对象
然后在计算属性中
computed: {currentRoute() {return this.$route.path},sidebar() {return this.$store.state.app.sidebar},device() {return this.$store.state.app.device},fixedHeader() {return this.$store.state.settings.fixedHeader},classObj() {return {hideSidebar: !this.sidebar.opened,openSidebar: this.sidebar.opened,}},...mapGetters(['sidebar'])},
在样式里面写 两个不同的样式
.hideSidebar .bread_container{
left:74px;
}
.openSidebar{
position: fixed;
top: 0;
}