Skip to content

Commit

Permalink
Implement feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
marcellamaki committed Jul 11, 2022
1 parent 504d1ed commit 68d333c
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions kolibri/plugins/learn/assets/src/views/TopicsPage.vue
Original file line number Diff line number Diff line change
Expand Up @@ -539,15 +539,12 @@
return this.contents.filter(content => content.kind !== ContentNodeKinds.TOPIC);
},
resourcesDisplayed() {
let displayed;
// if no folders are shown at this level, show more resources to fill the space
if (!this.showMoreResources) {
displayed = this.resources.slice(0, this.childrenToDisplay);
// otherwise display all resources
} else {
displayed = this.resources;
// or if the user has explicitly requested to show more resources
if (!this.topics.length || this.showMoreResources) {
return this.resources;
}
return displayed;
return this.resources.slice(0, this.childrenToDisplay);
},
moreResources() {
return this.resourcesDisplayed.length < this.resources.length;
Expand Down

0 comments on commit 68d333c

Please sign in to comment.