-
-
Notifications
You must be signed in to change notification settings - Fork 5
Update line break draft format wording #3273
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
base: master
Are you sure you want to change the base?
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
✅ All tests successful. No failed tests found. Additional details and impacted files@@ Coverage Diff @@
## master #3273 +/- ##
=======================================
Coverage 81.99% 81.99%
=======================================
Files 605 605
Lines 35111 35120 +9
Branches 5715 5716 +1
=======================================
+ Hits 28789 28798 +9
- Misses 5478 5490 +12
+ Partials 844 832 -12 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
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.
Reviewed 7 of 7 files at r1, all commit messages.
Reviewable status: all files reviewed, 4 unresolved discussions (waiting on @RaymondLuong3)
src/SIL.XForge.Scripture/ClientApp/src/app/translate/draft-generation/draft-usfm-format/draft-usfm-format.component.ts
line 182 at r1 (raw file):
await this.projectService.onlineSetUsfmConfig(this.projectId, this.currentFormat); this.lastSavedState = this.currentFormat; // not awaited so that the user is directed to the draft generation page
I don't understand this comment. How does awaiting prevent a redirect after saving?
src/SIL.XForge.Scripture/ClientApp/src/app/translate/draft-generation/draft-usfm-format/draft-usfm-format.component.ts
line 185 at r1 (raw file):
this.servalAdministration.onlineRetrievePreTranslationStatus(this.projectId).then(() => { this.router.navigate(['projects', this.projectId, 'draft-generation']); this.noticeService.show(translate('draft_usfm_format.changes_have_been_saved'));
Given the redirect only happens if it's successful, I think the notice is unneeded and doesn't match what we do elsewhere.
src/SIL.XForge.Scripture/ClientApp/src/app/translate/draft-generation/draft-usfm-format/draft-usfm-format.component.html
line 65 at r1 (raw file):
{{ t("save_changes") }} </button> <div class="progress" [ngClass]="{ saving: saving }">
What about [class.saving]="saving"
?
src/SIL.XForge.Scripture/ClientApp/src/app/translate/draft-generation/draft-usfm-format/draft-usfm-format.component.html
line 66 at r1 (raw file):
</button> <div class="progress" [ngClass]="{ saving: saving }"> <mat-spinner diameter="24"></mat-spinner>
I really dislike how this spinner changes the layout, but I don't have anything great to suggest. My best idea is to replace the check mark with a spinner, but making that work is somewhat challenging.
src/SIL.XForge.Scripture/ClientApp/src/app/translate/draft-generation/draft-usfm-format/draft-usfm-format.component.scss
line 92 at r1 (raw file):
justify-content: flex-end; .progress {
How about:
.progress:not(.saving) {
visibility: hidden;
}
Only one rule needed, and the intent is clearer.
This PR updates the wording for the line break options in the draft format component. Additionally, the user now navigates back to the generate draft page after saving the changes which is more intuitive. A progress circle has been introduced to notify the user their changes are currently saving.
I marked this as testing not required since the changes can be tested by a developer.
This change is