Skip to content

Commit e5a5f5e

Browse files
authored
Update wording on draft format options page (#3401)
1 parent b341e06 commit e5a5f5e

File tree

5 files changed

+65
-45
lines changed

5 files changed

+65
-45
lines changed

src/SIL.XForge.Scripture/ClientApp/src/app/translate/draft-generation/draft-history-list/draft-history-entry/draft-history-entry.component.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
<app-draft-download-button [build]="entry" [flat]="true" />
3131
@if (featureFlags.usfmFormat.enabled && isLatestBuild) {
3232
<button mat-button class="format-usfm" [routerLink]="['format']">
33-
<mat-icon>build</mat-icon> {{ t("format_draft") }}
33+
<mat-icon>build</mat-icon> {{ t("formatting_options") }}
3434
</button>
3535
}
3636
</div>

src/SIL.XForge.Scripture/ClientApp/src/app/translate/draft-generation/draft-usfm-format/_draft-usfm-format-theme.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
@mixin color($theme) {
44
$is-dark: mat.get-theme-type($theme) == dark;
55

6-
--sf-draft-usfm-format-description: #{mat.get-theme-color($theme, neutral, if($is-dark, 70, 40))};
6+
--new-indicator-background-color: #{mat.get-theme-color($theme, primary, if($is-dark, 70, 40))};
77
}
88

99
@mixin theme($theme) {

src/SIL.XForge.Scripture/ClientApp/src/app/translate/draft-generation/draft-usfm-format/draft-usfm-format.component.html

Lines changed: 25 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -1,56 +1,56 @@
11
<ng-container *transloco="let t; read: 'draft_usfm_format'">
2-
<h1>{{ t("draft_format_options") }}</h1>
2+
<h1>{{ t("formatting_options") }}</h1>
33
@if (!isOnline) {
44
<p class="offline-text">{{ t("connect_to_the_internet") }}</p>
55
}
66
<div class="format-container">
77
<div class="format-options">
88
<form [formGroup]="usfmFormatForm" (change)="reloadText()">
99
<p>{{ t("draft_format_description") }}</p>
10+
<p>{{ t("available_for_each_draft") }}</p>
1011
<mat-card class="options">
11-
<mat-card-header
12-
><mat-card-title>{{ t("line_breaks_title") }}</mat-card-title></mat-card-header
13-
>
12+
<mat-card-header>
13+
<mat-card-title> {{ t("line_breaks_title") }} </mat-card-title>
14+
</mat-card-header>
1415
<mat-card-content class="format-options">
1516
<span>{{ t("line_breaks_description") }}</span>
1617
<mat-radio-group formControlName="paragraphFormat">
1718
<mat-radio-button [value]="paragraphBreakFormat.BestGuess">
18-
{{ t("option_best_guess") }}
19-
<span class="new">{{ t("new") }}</span>
20-
<span class="description">
21-
{{ t("option_best_guess_description") }}
22-
</span>
19+
<span class="option-title"> {{ t("option_best_guess") }} </span>
20+
<span class="new"> {{ t("new") }} </span>
21+
<span class="description"> {{ t("option_best_guess_description") }} </span>
2322
</mat-radio-button>
2423
<mat-radio-button [value]="paragraphBreakFormat.Remove">
25-
{{ t("option_remove") }}
26-
<span class="new">{{ t("new") }}</span>
27-
<span class="description">
28-
{{ t("option_remove_description") }}
29-
</span>
24+
<span class="option-title"> {{ t("option_remove") }} </span>
25+
<span class="new"> {{ t("new") }} </span>
26+
<span class="description"> {{ t("option_remove_description") }} </span>
3027
</mat-radio-button>
3128
<mat-radio-button [value]="paragraphBreakFormat.MoveToEnd">
32-
{{ t("option_end") }}
33-
<span class="description">{{ t("option_end_description") }} </span>
29+
<span class="option-title"> {{ t("option_end") }} </span>
30+
<span class="description"> {{ t("option_end_description") }} </span>
3431
</mat-radio-button>
3532
</mat-radio-group>
3633
</mat-card-content>
3734
</mat-card>
3835
<mat-card class="options">
3936
<mat-card-header>
40-
<mat-card-title>Quote style <small>[coming soon]</small></mat-card-title>
37+
<mat-card-title> {{ t("quote_style") }} </mat-card-title>
4138
</mat-card-header>
4239
<mat-card-content class="format-options">
43-
Choose how quotes should appear in the draft.
40+
{{ t("choose_how_quotes_appear") }}
41+
42+
<!-- TODO make this notice conditional -->
43+
<app-notice type="warning" mode="fill-dark"> {{ t("no_quote_convention_detected") }} </app-notice>
44+
4445
<mat-radio-group formControlName="quoteFormat">
4546
<mat-radio-button [value]="quoteStyleFormat.Automatic">
46-
Automatic quote style <span class="new">{{ t("new") }}</span>
47-
<span class="description">
48-
Use the same quote style as the rest of the project, if possible. Recommended for most projects.
49-
</span>
47+
<span class="option-title"> {{ t("automatic_quote_style") }} </span>
48+
<span class="new"> {{ t("new") }} </span>
49+
<span class="description"> {{ t("automatic_quote_style_description") }} </span>
5050
</mat-radio-button>
5151
<mat-radio-button [value]="quoteStyleFormat.Straight">
52-
Straight quotes
53-
<span class="description"> Use only straight quotes in the draft.</span>
52+
<span class="option-title"> {{ t("straight_quotes") }} </span>
53+
<span class="description"> {{ t("straight_quotes_description") }} </span>
5454
</mat-radio-button>
5555
</mat-radio-group>
5656
</mat-card-content>
@@ -64,8 +64,7 @@ <h1>{{ t("draft_format_options") }}</h1>
6464
<mat-spinner diameter="24"></mat-spinner>
6565
</div>
6666
<button mat-flat-button class="save" color="primary" (click)="saveChanges()">
67-
<mat-icon>check</mat-icon>
68-
{{ t("save_changes") }}
67+
<mat-icon>check</mat-icon> {{ t("save_changes") }}
6968
</button>
7069
</div>
7170
</div>

src/SIL.XForge.Scripture/ClientApp/src/app/translate/draft-generation/draft-usfm-format/draft-usfm-format.component.scss

Lines changed: 20 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -31,13 +31,8 @@
3131
padding: 8px 0;
3232
row-gap: 8px;
3333

34-
span {
35-
display: block;
36-
}
37-
3834
.description {
39-
color: var(--sf-draft-usfm-format-description);
40-
font-size: smaller;
35+
display: block;
4136
}
4237
}
4338

@@ -101,9 +96,26 @@ form {
10196
}
10297

10398
.new {
104-
background-color: green;
99+
background-color: var(--new-indicator-background-color);
105100
color: white;
106-
display: inline-block !important;
101+
display: inline-block;
107102
border-radius: 50px;
108103
padding-inline: 6px;
104+
margin-inline-start: 1em;
105+
}
106+
107+
.option-title {
108+
font-weight: 500;
109+
line-height: 40px;
110+
}
111+
112+
mat-radio-group {
113+
display: flex;
114+
flex-direction: column;
115+
gap: 12px;
116+
}
117+
118+
// Vertically align radio buttons with the title of the label
119+
mat-radio-button ::ng-deep .mdc-form-field.mat-internal-form-field {
120+
align-items: flex-start;
109121
}

src/SIL.XForge.Scripture/ClientApp/src/assets/i18n/non_checking_en.json

Lines changed: 18 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -282,7 +282,7 @@
282282
"draft_unknown": "Unknown",
283283
"error_details": "Please include these details when contacting support for assistance",
284284
"finished_at": "Finished {{ finishedAtTime }}",
285-
"format_draft": "Format draft",
285+
"formatting_options": "Formatting options",
286286
"hide_model_training_configuration": "Hide model training configuration",
287287
"requested_at": "Requested {{ requestedAtTime }}.",
288288
"requested_by": "Requested by {{ requestedByUserName }} at {{ requestedAtTime }}.",
@@ -346,21 +346,30 @@
346346
"unknown_language_code": "unknown"
347347
},
348348
"draft_usfm_format": {
349+
"automatic_quote_style_description": "Use the same quote style as the rest of the project, if possible. Recommended for most projects.",
350+
"automatic_quote_style": "Automatic quote style",
351+
"available_for_each_draft": "You can do this for every new draft if you wish.",
349352
"cancel": "Cancel",
350-
"connect_to_the_internet": "Please connect to the internet to change the USFM format for your draft",
353+
"choose_how_quotes_appear": "Choose how quotes should appear",
354+
"connect_to_the_internet": "Please connect to the internet to change the draft formatting options.",
351355
"draft_format_description": "The draft has been created. Here are some formatting options for the text. You can try each option to see the difference it makes.",
352356
"draft_format_options": "Format draft",
353357
"failed_to_save": "Failed to save changes. Try again later.",
354-
"new": "New",
355-
"option_best_guess": "Best guess",
358+
"formatting_options": "Formatting options",
359+
"line_breaks_description": "Scripture Forge translates complete verses, without line breaks, because this gives the best translation. Choose where to place the line breaks from the source.",
360+
"line_breaks_title": "Line breaks",
361+
"new": "new",
362+
"no_quote_convention_detected": "No quote convention could be detected for your project. Straight quotes will be used in the draft regardless of which option you choose.",
356363
"option_best_guess_description": "Line breaks in the source will be placed at the best guess of where they should be in the draft. Recommended for most projects.",
357-
"option_end": "Move to end",
364+
"option_best_guess": "Best guess",
358365
"option_end_description": "Line breaks in the source will be moved to the end of the verse.",
359-
"option_remove": "Remove",
366+
"option_end": "Move to end",
360367
"option_remove_description": "Line breaks in the source will be omitted from the draft.",
361-
"line_breaks_description": "Scripture Forge translates complete verses, without line breaks, because this gives the best draft. Choose where to place the line breaks from the source.",
362-
"line_breaks_title": "Line breaks",
363-
"save_changes": "Save"
368+
"option_remove": "Remove",
369+
"quote_style": "Quote style",
370+
"save_changes": "Save",
371+
"straight_quotes_description": "Use only straight quotes in the draft.",
372+
"straight_quotes": "Straight quotes"
364373
},
365374
"editor": {
366375
"add_comment": "Add Comment",

0 commit comments

Comments
 (0)