-
Notifications
You must be signed in to change notification settings - Fork 634
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Return to resource list after adding/removing an item from a lesson/quiz #7213
Return to resource list after adding/removing an item from a lesson/quiz #7213
Conversation
Codecov Report
|
We should prevent the Preview pages changing in appearance before navigating back to the resource-list page (see GIF). Could you
|
kolibri/plugins/coach/assets/src/views/plan/PlanQuizPreviewPage.vue
Outdated
Show resolved
Hide resolved
kolibri/plugins/coach/assets/src/views/plan/PlanQuizPreviewPage.vue
Outdated
Show resolved
Hide resolved
I also added some suggestions for fixing #7212 inside some comments |
- do not switch between added/removed states before redirect - disable add/remove button after click
Hi JB, thank you. I've just pushed all updates. Regarding "Added" indicator, although it's not rendered after "Add" button click anymore, it's still displayed on the preview page load - is it fine or do you want to remove it completely? I've tried both options and it seems that keeping indicator for this situation makes visually clear if it's added or not at first glance when compared to displaying "Remove" button only. |
Also added a commit to unify snackbar messages that closes #7212. |
@@ -173,6 +190,11 @@ | |||
); | |||
}, | |||
}, | |||
watch: { | |||
isSelected() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This watcher is not currently used though I added it because I would expect that disableSelectButton
will be appropriately reset on selection state change.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The changes look great, thanks!
@MisRob I found a bug where if you removed the only resource in a lesson from the preview page, it would be automatically re-added when navigating back to the resource list (due to the complicated autosaving logic we use). I added one more commit as a hack to fix this by committing the resource removal before the navigation, but keeping the Preview page buttons and indicators saying "added" until the navigation occurs. |
Summary
Redirect coaches to a list after adding or removing an item from a lesson/quiz when planning a class. Display snackbar on a list page.
Reviewer guidance
Lesson
Quiz
References
Closes #6819
Opened #7212
Contributor Checklist
PR process:
Testing:
Reviewer Checklist
yarn
andpip
)