From 953952b4cda3e2a93ccf83a6df63d6c451fcdcf7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pau=20Ferrer=20Oca=C3=B1a?= Date: Mon, 21 Feb 2022 13:51:05 +0100 Subject: [PATCH] MOBILE-3814 grades: Use ion icon to render grades svg --- src/assets/fonts/moodle/moodle/agg_mean.svg | 1 + src/assets/fonts/moodle/moodle/agg_sum.svg | 1 + src/assets/img/grades/agg_mean.svg | 1 - src/assets/img/grades/agg_sum.svg | 1 - src/core/features/grades/services/grades-helper.ts | 4 ++-- 5 files changed, 4 insertions(+), 4 deletions(-) create mode 100644 src/assets/fonts/moodle/moodle/agg_mean.svg create mode 100644 src/assets/fonts/moodle/moodle/agg_sum.svg delete mode 100644 src/assets/img/grades/agg_mean.svg delete mode 100644 src/assets/img/grades/agg_sum.svg diff --git a/src/assets/fonts/moodle/moodle/agg_mean.svg b/src/assets/fonts/moodle/moodle/agg_mean.svg new file mode 100644 index 000000000..c10adf743 --- /dev/null +++ b/src/assets/fonts/moodle/moodle/agg_mean.svg @@ -0,0 +1 @@ + diff --git a/src/assets/fonts/moodle/moodle/agg_sum.svg b/src/assets/fonts/moodle/moodle/agg_sum.svg new file mode 100644 index 000000000..6108dc6df --- /dev/null +++ b/src/assets/fonts/moodle/moodle/agg_sum.svg @@ -0,0 +1 @@ + diff --git a/src/assets/img/grades/agg_mean.svg b/src/assets/img/grades/agg_mean.svg deleted file mode 100644 index ac4368d15..000000000 --- a/src/assets/img/grades/agg_mean.svg +++ /dev/null @@ -1 +0,0 @@ - diff --git a/src/assets/img/grades/agg_sum.svg b/src/assets/img/grades/agg_sum.svg deleted file mode 100644 index 9ebd5c23d..000000000 --- a/src/assets/img/grades/agg_sum.svg +++ /dev/null @@ -1 +0,0 @@ - diff --git a/src/core/features/grades/services/grades-helper.ts b/src/core/features/grades/services/grades-helper.ts index cff4e9b98..1720fd445 100644 --- a/src/core/features/grades/services/grades-helper.ts +++ b/src/core/features/grades/services/grades-helper.ts @@ -593,11 +593,11 @@ export class CoreGradesHelperProvider { text = text.replace('%2F', '/').replace('%2f', '/'); if (text.indexOf('/agg_mean') > -1) { row.itemtype = 'agg_mean'; - row.image = 'assets/img/grades/agg_mean.svg'; + row.icon = 'moodle-agg_mean'; row.iconAlt = Translate.instant('core.grades.aggregatemean'); } else if (text.indexOf('/agg_sum') > -1) { row.itemtype = 'agg_sum'; - row.image = 'assets/img/grades/agg_sum.svg'; + row.icon = 'moodle-agg_sum'; row.iconAlt = Translate.instant('core.grades.aggregatesum'); } else if (text.indexOf('/outcomes') > -1 || text.indexOf('fa-tasks') > -1) { row.itemtype = 'outcome';