Skip to content

Commit

Permalink
Merge pull request #2426 from instructure/release/parent-3.10.0-50
Browse files Browse the repository at this point in the history
Release Parent 3.10.0 (50)
  • Loading branch information
kristofnemere authored May 6, 2024
2 parents f6e3fe2 + 3fd7592 commit 1a6401d
Show file tree
Hide file tree
Showing 676 changed files with 32,803 additions and 6,216 deletions.
2 changes: 1 addition & 1 deletion android-vault
2 changes: 1 addition & 1 deletion apps/flutter_parent/android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ dependencies {
testImplementation 'junit:junit:4.12'

androidTestImplementation 'com.android.support.test:runner:1.0.2'
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.4.0'
implementation "com.squareup.okhttp3:okhttp:4.9.1"
implementation 'org.jsoup:jsoup:1.11.3'
implementation 'com.google.gms:google-services:4.3.14'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
<action android:name="android.intent.action.MAIN"/>
<category android:name="android.intent.category.LAUNCHER"/>
</intent-filter>
<intent-filter>
<intent-filter android:autoVerify="true">
<data android:scheme="https" />
<data android:scheme="http" />
<data android:host="*.instructure.com" />
Expand Down
13 changes: 10 additions & 3 deletions apps/flutter_parent/lib/l10n/app_localizations.dart
Original file line number Diff line number Diff line change
Expand Up @@ -989,11 +989,18 @@ class AppLocalizations {
desc: 'Screen reader-friendly replacement for the "-" character in letter grades like "A-"',
);

String latePenalty(String pointsLost) => Intl.message(
'Late penalty (-$pointsLost)',
String yourGrade(String pointsAchieved) => Intl.message(
'Your grade: $pointsAchieved',
desc: 'Text displayed when a late penalty has been applied to the assignment, this is the achieved score without the penalty',
args: [pointsAchieved],
name: 'yourGrade',
);

String latePenaltyUpdated(String pointsLost) => Intl.message(
'Late Penalty: -$pointsLost pts',
desc: 'Text displayed when a late penalty has been applied to the assignment',
args: [pointsLost],
name: 'latePenalty',
name: 'latePenaltyUpdated',
);

String finalGrade(String grade) => Intl.message(
Expand Down
85 changes: 84 additions & 1 deletion apps/flutter_parent/lib/l10n/res/intl_id.arb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"@@last_modified": "2022-10-28T11:03:07.232972",
"@@last_modified": "2023-08-25T11:04:20.901151",
"alertsLabel": "Peringatan",
"@alertsLabel": {
"description": "The label for the Alerts tab",
Expand Down Expand Up @@ -182,6 +182,19 @@
"points": {}
}
},
"calendarDaySemanticsLabel": "{eventCount,plural, =1{{date}, {eventCount} acara}other{{date}, {eventCount} acara}}",
"@calendarDaySemanticsLabel": {
"description": "Screen reader label used for calendar day, reads the date and count of events",
"type": "text",
"placeholders_order": [
"date",
"eventCount"
],
"placeholders": {
"date": {},
"eventCount": {}
}
},
"No Events Today!": "Tidak Ada Acara Hari Ini!",
"@No Events Today!": {
"description": "Title displayed when there are no calendar events for the current day",
Expand Down Expand Up @@ -2666,5 +2679,75 @@
"type": "text",
"placeholders_order": [],
"placeholders": {}
},
"Acceptable Use Policy": "Kebijakan Penggunaan yang Dapat Diterima",
"@Acceptable Use Policy": {
"description": "title for the acceptable use policy screen",
"type": "text",
"placeholders_order": [],
"placeholders": {}
},
"Submit": "Serahkan",
"@Submit": {
"description": "submit button title for acceptable use policy screen",
"type": "text",
"placeholders_order": [],
"placeholders": {}
},
"Either you're a new user or the Acceptable Use Policy has changed since you last agreed to it. Please agree to the Acceptable Use Policy before you continue.": "Anda pengguna baru atau Kebijakan Penggunaan yang Dapat Diterima telah berubah sejak Anda terakhir kali menyetujuinya. Silakan setujui Kebijakan Penggunaan yang Dapat Diterima sebelum Anda melanjutkan.",
"@Either you're a new user or the Acceptable Use Policy has changed since you last agreed to it. Please agree to the Acceptable Use Policy before you continue.": {
"description": "acceptable use policy screen description",
"type": "text",
"placeholders_order": [],
"placeholders": {}
},
"I agree to the Acceptable Use Policy.": "Saya menyetujui Kebijakan Penggunaan yang Dapat Diterima.",
"@I agree to the Acceptable Use Policy.": {
"description": "acceptable use policy switch title",
"type": "text",
"placeholders_order": [],
"placeholders": {}
},
"About": "Tentang",
"@About": {
"description": "Title for about menu item in settings",
"type": "text",
"placeholders_order": [],
"placeholders": {}
},
"App": "App",
"@App": {
"description": "Title for App field on about page",
"type": "text",
"placeholders_order": [],
"placeholders": {}
},
"Login ID": "ID Login",
"@Login ID": {
"description": "Title for Login ID field on about page",
"type": "text",
"placeholders_order": [],
"placeholders": {}
},
"Email": "Email",
"@Email": {
"description": "Title for Email field on about page",
"type": "text",
"placeholders_order": [],
"placeholders": {}
},
"Version": "Versi",
"@Version": {
"description": "Title for Version field on about page",
"type": "text",
"placeholders_order": [],
"placeholders": {}
},
"Instructure logo": "Logo Instructure",
"@Instructure logo": {
"description": "Semantics label for the Instructure logo on the about page",
"type": "text",
"placeholders_order": [],
"placeholders": {}
}
}
2 changes: 1 addition & 1 deletion apps/flutter_parent/lib/l10n/res/intl_ja.arb
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@
"placeholders_order": [],
"placeholders": {}
},
"pointsPossible": "{points}の可能なポイント",
"pointsPossible": "配点 {points}",
"@pointsPossible": {
"description": "Screen reader label used for the points possible for an assignment, quiz, etc.",
"type": "text",
Expand Down
2 changes: 1 addition & 1 deletion apps/flutter_parent/lib/models/assignment.dart
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ abstract class Assignment implements Built<Assignment, AssignmentBuilder> {

SubmissionStatus getStatus({required String? studentId}) {
final submission = this.submission(studentId);
if (!isSubmittable()) {
if (!isSubmittable() && submission == null) {
return SubmissionStatus.NONE;
} else if (submission?.isLate == true) {
return SubmissionStatus.LATE;
Expand Down
12 changes: 9 additions & 3 deletions apps/flutter_parent/lib/models/grade_cell_data.dart
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ abstract class GradeCellData implements Built<GradeCellData, GradeCellDataBuilde
String get grade;
String get gradeContentDescription;
String get outOf;
String get yourGrade;
String get latePenalty;
String get finalGrade;

Expand All @@ -58,6 +59,7 @@ abstract class GradeCellData implements Built<GradeCellData, GradeCellDataBuilde
..grade = ''
..gradeContentDescription = ''
..outOf = ''
..yourGrade = ''
..latePenalty = ''
..finalGrade = '';

Expand Down Expand Up @@ -125,8 +127,8 @@ abstract class GradeCellData implements Built<GradeCellData, GradeCellDataBuilde
..graphPercent = 1.0);
}

var score = NumberFormat.decimalPattern().format(submission.enteredScore);
var graphPercent = (submission.enteredScore / assignment.pointsPossible).clamp(0.0, 1.0);
var score = NumberFormat.decimalPattern().format(submission.score);
var graphPercent = (submission.score / assignment.pointsPossible).clamp(0.0, 1.0);

// If grading type is Points, don't show the grade since we're already showing it as the score
var grade = assignment.gradingType != GradingType.points ? submission.grade ?? '' : '';
Expand All @@ -138,6 +140,7 @@ abstract class GradeCellData implements Built<GradeCellData, GradeCellDataBuilde
// Screen reader fails on letter grades with a minus (e.g. 'A-'), so we replace the dash with the word 'minus'
var accessibleGradeString = grade.replaceAll('-', '. ${l10n.accessibilityMinus}');

var yourGrade = '';
var latePenalty = '';
var finalGrade = '';
var restrictedScore = grade;
Expand All @@ -146,7 +149,9 @@ abstract class GradeCellData implements Built<GradeCellData, GradeCellDataBuilde
if ((submission.pointsDeducted ?? 0.0) > 0.0) {
grade = ''; // Grade will be shown in the 'final grade' text
var pointsDeducted = NumberFormat.decimalPattern().format(submission.pointsDeducted ?? 0.0);
latePenalty = l10n.latePenalty(pointsDeducted);
var pointsAchieved = NumberFormat.decimalPattern().format(submission.enteredScore);
yourGrade = l10n.yourGrade(pointsAchieved);
latePenalty = l10n.latePenaltyUpdated(pointsDeducted);
finalGrade = l10n.finalGrade(submission.grade ?? grade);
}

Expand All @@ -166,6 +171,7 @@ abstract class GradeCellData implements Built<GradeCellData, GradeCellDataBuilde
..outOf = outOfText
..grade = grade
..gradeContentDescription = accessibleGradeString
..yourGrade = yourGrade
..latePenalty = latePenalty
..finalGrade = finalGrade);
}
Expand Down
14 changes: 14 additions & 0 deletions apps/flutter_parent/lib/models/grade_cell_data.g.dart

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,6 @@ class AccountCreationInteractor {
}

launchPrivacyPolicy() {
locator<UrlLauncher>().launch('https://www.instructure.com/canvas/privacy');
locator<UrlLauncher>().launch('https://www.instructure.com/policies/product-privacy-policy');
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,8 @@ class _AssignmentDetailsScreenState extends State<AssignmentDetailsScreen> {
final assignment = snapshot.data!.assignment!;
final submission = assignment.submission(_currentStudent?.id);
final fullyLocked = assignment.isFullyLocked;
final showStatus = assignment.isSubmittable() || submission?.isGraded() == true;
final missing = submission?.missing == true;
final showStatus = missing || assignment.isSubmittable() || submission?.isGraded() == true;
final submitted = submission?.submittedAt != null;
final submittedColor = submitted ? ParentTheme.of(context)?.successColor : textTheme.bodySmall?.color;

Expand Down Expand Up @@ -172,9 +173,9 @@ class _AssignmentDetailsScreenState extends State<AssignmentDetailsScreen> {
if (showStatus) SizedBox(width: 8),
if (showStatus)
Text(
!submitted
? l10n.assignmentNotSubmittedLabel
: submission?.isGraded() == true ? l10n.assignmentGradedLabel : l10n.assignmentSubmittedLabel,
missing ? l10n.assignmentMissingSubmittedLabel :
!submitted ? l10n.assignmentNotSubmittedLabel :
submission?.isGraded() == true ? l10n.assignmentGradedLabel : l10n.assignmentSubmittedLabel,
style: textTheme.bodySmall?.copyWith(
color: submittedColor,
),
Expand Down
Loading

0 comments on commit 1a6401d

Please sign in to comment.