mirror of
https://github.com/Hopiu/vue-material.git
synced 2026-05-05 05:54:43 +00:00
fix card expand negative margin
This commit is contained in:
parent
0e3b43aec1
commit
a3a84259e3
1 changed files with 9 additions and 7 deletions
|
|
@ -18,15 +18,17 @@
|
|||
}
|
||||
},
|
||||
mounted() {
|
||||
this.trigger = this.$el.querySelector('[md-expand-trigger]');
|
||||
this.content = this.$el.querySelector('.md-card-content');
|
||||
window.setTimeout(() => {
|
||||
this.trigger = this.$el.querySelector('[md-expand-trigger]');
|
||||
this.content = this.$el.querySelector('.md-card-content');
|
||||
|
||||
if (this.content) {
|
||||
this.setContentMargin();
|
||||
if (this.content) {
|
||||
this.setContentMargin();
|
||||
|
||||
this.trigger.addEventListener('click', this.toggle);
|
||||
window.addEventListener('resize', this.onWindowResize);
|
||||
}
|
||||
this.trigger.addEventListener('click', this.toggle);
|
||||
window.addEventListener('resize', this.onWindowResize);
|
||||
}
|
||||
}, 200);
|
||||
},
|
||||
destroyed() {
|
||||
if (this.content) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue