Skip to content

Commit fa6765a

Browse files
committed
fixed zero state appearing with selected collection after refreshing collection list in sidebar
1 parent 071babd commit fa6765a

File tree

2 files changed

+8
-7
lines changed

2 files changed

+8
-7
lines changed

src/home/index.js

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -64,13 +64,14 @@ var HomeView = View.extend({
6464
this.renderSubview(new TourView(), this.queryByHook('tour-container'));
6565
},
6666
onInstanceFetched: function() {
67-
if (app.instance.collections.length === 0) {
68-
this.showNoCollectionsZeroState = true;
69-
} else {
70-
this.showDefaultZeroState = true;
71-
}
7267
if (!this.ns) {
7368
app.instance.collections.unselectAll();
69+
70+
if (app.instance.collections.length === 0) {
71+
this.showNoCollectionsZeroState = true;
72+
} else {
73+
this.showDefaultZeroState = true;
74+
}
7475
} else {
7576
this.showCollection(app.instance.collections.get(this.ns));
7677
}

src/home/index.less

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -91,8 +91,8 @@
9191
display: flex;
9292
overflow: hidden;
9393
height: 100vh;
94-
margin-top: -168px; // total computed header + .refine-view-container height
95-
padding-top: 168px; // total computed header + .refine-view-container height
94+
margin-top: -155px; // total computed header + .refine-view-container height
95+
padding-top: 155px; // total computed header + .refine-view-container height
9696
position: relative;
9797
width: 100%;
9898
}

0 commit comments

Comments
 (0)