From a76b18a127eae468da955252bcb9e4d01f6d27d3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pau=20Ferrer=20Oca=C3=B1a?= Date: Tue, 7 Nov 2023 09:46:57 +0100 Subject: [PATCH 01/17] MOBILE-3947 chore: Remove old ionic migration --- .github/workflows/migration.yml | 18 -------------- ionic-migration.json | 43 --------------------------------- 2 files changed, 61 deletions(-) delete mode 100644 .github/workflows/migration.yml delete mode 100644 ionic-migration.json diff --git a/.github/workflows/migration.yml b/.github/workflows/migration.yml deleted file mode 100644 index 360a4361b..000000000 --- a/.github/workflows/migration.yml +++ /dev/null @@ -1,18 +0,0 @@ -name: Migration checks - -on: workflow_dispatch - -jobs: - checks: - - runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v2 - - uses: actions/setup-node@v3 - with: - node-version-file: '.nvmrc' - - run: npm ci --no-audit - - run: result=$(find src -type f -iname '*.html' -exec sh -c 'cat {} | tr "\n" " " | grep -Eo "class=\"[^\"]+\"[^>]+class=\"" ' \; | wc -l); test $result -eq 0 - - run: npm install -D @ionic/v4-migration-tslint - - run: npx tslint -c ionic-migration.json -p tsconfig.json diff --git a/ionic-migration.json b/ionic-migration.json deleted file mode 100644 index 8da798098..000000000 --- a/ionic-migration.json +++ /dev/null @@ -1,43 +0,0 @@ -{ - "rulesDirectory": ["@ionic/v4-migration-tslint/rules"], - "rules": { - "ion-action-sheet-method-create-parameters-renamed": true, - "ion-alert-method-create-parameters-renamed": true, - "ion-back-button-not-added-by-default": { "options": [true], "severity": "warning" }, - "ion-button-attributes-renamed": true, - "ion-button-is-now-an-element": true, - "ion-buttons-attributes-renamed": true, - "ion-col-attributes-renamed": true, - "ion-datetime-capitalization-changed": true, - "ion-fab-attributes-renamed": true, - "ion-fab-button-is-now-an-element": true, - "ion-fab-fixed-content": true, - "ion-icon-attribute-is-active-removed": true, - "ion-item-attributes-renamed": true, - "ion-item-divider-ion-label-required": true, - "ion-item-ion-label-required": true, - "ion-item-is-now-an-element": true, - "ion-item-option-is-now-an-element": true, - "ion-item-option-method-get-sliding-percent-renamed": true, - "ion-item-options-attribute-values-renamed": true, - "ion-label-attributes-renamed": true, - "ion-list-header-ion-label-required": true, - "ion-loading-method-create-parameters-renamed": true, - "ion-menu-events-renamed": true, - "ion-menu-toggle-is-now-an-element": true, - "ion-navbar-is-now-ion-toolbar": true, - "ion-option-is-now-ion-select-option": true, - "ion-overlay-method-create-should-use-await": true, - "ion-overlay-method-present-should-use-await": { "options": [true], "severity": "warning" }, - "ion-radio-attributes-renamed": true, - "ion-radio-group-is-now-an-element": true, - "ion-radio-slot-required": true, - "ion-range-attributes-renamed": true, - "ion-segment-button-ion-label-required": true, - "ion-spinner-attribute-values-renamed": true, - "ion-tabs-refactored": { "options": [true], "severity": "warning" }, - "ion-text-is-now-an-element": true - } -} - - From 8265f0fbe1ba168271fae4c337c2ba6ae3a290ef Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pau=20Ferrer=20Oca=C3=B1a?= Date: Tue, 7 Nov 2023 11:28:14 +0100 Subject: [PATCH 02/17] MOBILE-3947 chore: Remove unneeded optional chaining on HTML --- src/addons/mod/assign/pages/index/index.html | 2 +- .../bigbluebuttonbn/pages/index/index.html | 2 +- src/addons/mod/book/pages/index/index.html | 2 +- src/addons/mod/chat/pages/index/index.html | 2 +- src/addons/mod/choice/pages/index/index.html | 2 +- .../mod/feedback/pages/index/index.html | 2 +- src/addons/mod/folder/pages/index/index.html | 2 +- .../mod/glossary/pages/index/index.html | 2 +- src/addons/mod/imscp/pages/index/index.html | 2 +- src/addons/mod/lesson/pages/index/index.html | 2 +- .../mod/lesson/pages/player/player.html | 34 +++++++++---------- src/addons/mod/page/pages/index/index.html | 2 +- src/addons/mod/quiz/pages/index/index.html | 2 +- .../mod/resource/pages/index/index.html | 2 +- src/addons/mod/scorm/pages/index/index.html | 2 +- src/addons/mod/url/pages/index/index.html | 2 +- src/addons/mod/wiki/pages/index/index.html | 2 +- 17 files changed, 33 insertions(+), 33 deletions(-) diff --git a/src/addons/mod/assign/pages/index/index.html b/src/addons/mod/assign/pages/index/index.html index 2d3f9be93..0ee3bc5a8 100644 --- a/src/addons/mod/assign/pages/index/index.html +++ b/src/addons/mod/assign/pages/index/index.html @@ -5,7 +5,7 @@

- +

diff --git a/src/addons/mod/bigbluebuttonbn/pages/index/index.html b/src/addons/mod/bigbluebuttonbn/pages/index/index.html index 273ff5994..506ef400b 100644 --- a/src/addons/mod/bigbluebuttonbn/pages/index/index.html +++ b/src/addons/mod/bigbluebuttonbn/pages/index/index.html @@ -5,7 +5,7 @@

- +

diff --git a/src/addons/mod/book/pages/index/index.html b/src/addons/mod/book/pages/index/index.html index 5e55e1db3..5b58f63cc 100644 --- a/src/addons/mod/book/pages/index/index.html +++ b/src/addons/mod/book/pages/index/index.html @@ -5,7 +5,7 @@

- +

diff --git a/src/addons/mod/chat/pages/index/index.html b/src/addons/mod/chat/pages/index/index.html index 5f2cec7ce..8516625cf 100644 --- a/src/addons/mod/chat/pages/index/index.html +++ b/src/addons/mod/chat/pages/index/index.html @@ -5,7 +5,7 @@

- +

diff --git a/src/addons/mod/choice/pages/index/index.html b/src/addons/mod/choice/pages/index/index.html index 82d3899af..b1837e151 100644 --- a/src/addons/mod/choice/pages/index/index.html +++ b/src/addons/mod/choice/pages/index/index.html @@ -5,7 +5,7 @@

- +

diff --git a/src/addons/mod/feedback/pages/index/index.html b/src/addons/mod/feedback/pages/index/index.html index 091b40c1c..a0ca034af 100644 --- a/src/addons/mod/feedback/pages/index/index.html +++ b/src/addons/mod/feedback/pages/index/index.html @@ -5,7 +5,7 @@

- +

diff --git a/src/addons/mod/folder/pages/index/index.html b/src/addons/mod/folder/pages/index/index.html index cfafeebb9..0082579ce 100644 --- a/src/addons/mod/folder/pages/index/index.html +++ b/src/addons/mod/folder/pages/index/index.html @@ -5,7 +5,7 @@

- +

diff --git a/src/addons/mod/glossary/pages/index/index.html b/src/addons/mod/glossary/pages/index/index.html index 501b8f25d..486a6fe89 100644 --- a/src/addons/mod/glossary/pages/index/index.html +++ b/src/addons/mod/glossary/pages/index/index.html @@ -5,7 +5,7 @@

- +

diff --git a/src/addons/mod/imscp/pages/index/index.html b/src/addons/mod/imscp/pages/index/index.html index 12b3a7f08..1ecc39a45 100644 --- a/src/addons/mod/imscp/pages/index/index.html +++ b/src/addons/mod/imscp/pages/index/index.html @@ -5,7 +5,7 @@

- +

diff --git a/src/addons/mod/lesson/pages/index/index.html b/src/addons/mod/lesson/pages/index/index.html index f83508304..2b4c25520 100644 --- a/src/addons/mod/lesson/pages/index/index.html +++ b/src/addons/mod/lesson/pages/index/index.html @@ -5,7 +5,7 @@

- +

diff --git a/src/addons/mod/lesson/pages/player/player.html b/src/addons/mod/lesson/pages/player/player.html index 00187eb49..a351a1109 100644 --- a/src/addons/mod/lesson/pages/player/player.html +++ b/src/addons/mod/lesson/pages/player/player.html @@ -5,7 +5,7 @@

- +

@@ -63,7 +63,7 @@

-

@@ -87,8 +87,8 @@ {{ 'core.content' | translate }} @@ -96,8 +96,8 @@

{{ 'addon.mod_lesson.youranswer' | translate }}

-

@@ -112,7 +112,7 @@ + contextLevel="module" [contextInstanceId]="lesson.coursemodule" [courseId]="courseId"> @@ -124,8 +124,8 @@ - + @@ -138,8 +138,8 @@

- +

@@ -173,7 +173,7 @@ - + {{ 'addon.mod_lesson.progresscompleted' | translate:{$a: pageData.progress} }} @@ -182,7 +182,7 @@ - + {{ 'addon.mod_lesson.progressbarteacherwarning2' | translate }} @@ -253,14 +253,14 @@ - - @@ -275,8 +275,8 @@
- +
diff --git a/src/addons/mod/page/pages/index/index.html b/src/addons/mod/page/pages/index/index.html index 8cc1affc1..013f28a4d 100644 --- a/src/addons/mod/page/pages/index/index.html +++ b/src/addons/mod/page/pages/index/index.html @@ -5,7 +5,7 @@

- +

diff --git a/src/addons/mod/quiz/pages/index/index.html b/src/addons/mod/quiz/pages/index/index.html index 83bd934c9..5691e4137 100644 --- a/src/addons/mod/quiz/pages/index/index.html +++ b/src/addons/mod/quiz/pages/index/index.html @@ -5,7 +5,7 @@

- +

diff --git a/src/addons/mod/resource/pages/index/index.html b/src/addons/mod/resource/pages/index/index.html index 8413a0de5..be5afe998 100644 --- a/src/addons/mod/resource/pages/index/index.html +++ b/src/addons/mod/resource/pages/index/index.html @@ -5,7 +5,7 @@

- +

diff --git a/src/addons/mod/scorm/pages/index/index.html b/src/addons/mod/scorm/pages/index/index.html index 54f781209..1e5f18cd5 100644 --- a/src/addons/mod/scorm/pages/index/index.html +++ b/src/addons/mod/scorm/pages/index/index.html @@ -5,7 +5,7 @@

- +

diff --git a/src/addons/mod/url/pages/index/index.html b/src/addons/mod/url/pages/index/index.html index 5de9e34ee..7d4b31ae6 100644 --- a/src/addons/mod/url/pages/index/index.html +++ b/src/addons/mod/url/pages/index/index.html @@ -5,7 +5,7 @@

- +

diff --git a/src/addons/mod/wiki/pages/index/index.html b/src/addons/mod/wiki/pages/index/index.html index c11fb730c..1289bc186 100644 --- a/src/addons/mod/wiki/pages/index/index.html +++ b/src/addons/mod/wiki/pages/index/index.html @@ -5,7 +5,7 @@

- +

From a81f93822fd141915d835aed4c5e639573175c76 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pau=20Ferrer=20Oca=C3=B1a?= Date: Tue, 7 Nov 2023 13:32:19 +0100 Subject: [PATCH 03/17] MOBILE-3947 chore: Change import to use on Sass --- .../components/onlineusers/onlineusers.scss | 2 +- .../recentactivity/recentactivity.scss | 2 +- .../recentlyaccesseditems.scss | 2 +- .../timeline/components/events/events.scss | 2 +- src/addons/calendar/calendar-common.scss | 2 +- .../components/calendar/calendar.scss | 2 +- .../calendar/components/filter/filter.scss | 2 +- src/addons/messages/messages-common.scss | 2 +- .../messages/pages/discussion/discussion.scss | 3 +- .../messages/pages/discussion/discussion.ts | 2 +- src/addons/mod/chat/pages/chat/chat.scss | 2 -- src/addons/mod/chat/pages/chat/chat.ts | 2 +- .../session-messages/session-messages.scss | 2 -- .../session-messages/session-messages.ts | 2 +- src/addons/mod/data/data-forms.scss | 2 +- src/addons/mod/data/data.scss | 2 +- .../mod/forum/components/index/index.scss | 2 +- .../mod/forum/components/post/post.scss | 2 +- .../pages/new-discussion/new-discussion.scss | 2 +- .../attempt-results/attempt-results.scss | 2 +- .../lesson/pages/user-retake/user-retake.scss | 2 +- .../mod/resource/components/index/index.scss | 2 +- .../mod/scorm/components/index/index.scss | 2 +- .../mod/wiki/components/index/index.scss | 2 +- src/addons/notifications/notifications.scss | 2 +- src/addons/notifications/pages/list/list.scss | 2 +- .../pages/notification/notification.scss | 2 +- .../component/ddimageortext.scss | 2 +- .../ddimageortext/component/ddimageortext.ts | 2 +- src/addons/qtype/ddwtos/component/ddwtos.scss | 2 +- src/addons/qtype/ddwtos/component/ddwtos.ts | 2 +- .../pages/course-storage/course-storage.scss | 2 +- .../checkbox/component/checkbox.scss | 2 +- src/core/components/combobox/combobox.scss | 2 +- .../context-menu/context-menu-popover.scss | 2 +- .../components/course-image/course-image.scss | 2 +- src/core/components/empty-box/empty-box.scss | 2 +- src/core/components/loading/loading.scss | 2 +- .../mark-required/mark-required.scss | 2 +- src/core/components/message/message.scss | 2 +- src/core/components/mod-icon/mod-icon.scss | 2 +- .../navigation-bar/navigation-bar.scss | 2 +- .../components/progress-bar/progress-bar.scss | 2 +- .../refresh-button-modal.scss | 2 +- .../components/sheet-modal/sheet-modal.scss | 2 +- .../show-password/show-password.scss | 2 +- .../components/split-view/split-view.scss | 2 +- src/core/components/tabs/tabs.scss | 2 +- .../components/user-avatar/user-avatar.scss | 2 +- .../side-blocks-button.scss | 2 +- .../components/side-blocks/side-blocks.scss | 2 +- .../comments/pages/viewer/viewer.scss | 2 -- .../features/comments/pages/viewer/viewer.ts | 2 +- .../components/course-index/course-index.scss | 2 +- .../module-info/course-module-info.scss | 2 +- .../module-navigation/module-navigation.scss | 2 +- .../module-summary/module-summary.scss | 2 +- .../course/components/module/module.scss | 2 +- .../pages/course-summary/course-summary.scss | 2 +- .../features/course/pages/index/index.scss | 2 +- .../pages/module-preview/module-preview.scss | 2 +- .../course-list-item/course-list-item.scss | 2 +- .../rich-text-editor/rich-text-editor.scss | 2 +- .../features/grades/pages/course/course.scss | 2 +- .../site-onboarding/site-onboarding.scss | 2 +- src/core/features/login/login.scss | 2 +- src/core/features/login/pages/site/site.scss | 2 +- .../components/user-menu/user-menu.scss | 2 +- .../features/mainmenu/pages/menu/menu.scss | 2 +- src/core/features/question/question.scss | 2 +- .../reminders/components/date/date.scss | 2 +- .../report-column/report-column.scss | 2 +- .../report-detail/report-detail.scss | 2 +- .../report-summary/report-summary.scss | 2 +- .../features/sitehome/pages/index/index.scss | 2 +- .../features/tag/components/list/list.scss | 2 +- src/theme/components/discussion.scss | 2 +- src/theme/components/format-text.scss | 18 ++++++------ src/theme/theme.scss | 28 +++++++++---------- 79 files changed, 97 insertions(+), 104 deletions(-) diff --git a/src/addons/block/onlineusers/components/onlineusers/onlineusers.scss b/src/addons/block/onlineusers/components/onlineusers/onlineusers.scss index 1de16d878..678e73a3f 100644 --- a/src/addons/block/onlineusers/components/onlineusers/onlineusers.scss +++ b/src/addons/block/onlineusers/components/onlineusers/onlineusers.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { --core-avatar-size: 30px; diff --git a/src/addons/block/recentactivity/components/recentactivity/recentactivity.scss b/src/addons/block/recentactivity/components/recentactivity/recentactivity.scss index a72a303fb..14537fe1c 100644 --- a/src/addons/block/recentactivity/components/recentactivity/recentactivity.scss +++ b/src/addons/block/recentactivity/components/recentactivity/recentactivity.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host .core-block-content ::ng-deep { .activitydate, .activityhead { diff --git a/src/addons/block/recentlyaccesseditems/components/recentlyaccesseditems/recentlyaccesseditems.scss b/src/addons/block/recentlyaccesseditems/components/recentlyaccesseditems/recentlyaccesseditems.scss index 77fad00dd..9f161779f 100644 --- a/src/addons/block/recentlyaccesseditems/components/recentlyaccesseditems/recentlyaccesseditems.scss +++ b/src/addons/block/recentlyaccesseditems/components/recentlyaccesseditems/recentlyaccesseditems.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { .core-horizontal-scroll div.core-horizontal-scroll-item { diff --git a/src/addons/block/timeline/components/events/events.scss b/src/addons/block/timeline/components/events/events.scss index 07634e1d5..68e7378f5 100644 --- a/src/addons/block/timeline/components/events/events.scss +++ b/src/addons/block/timeline/components/events/events.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; h3 { font-weight: bold; diff --git a/src/addons/calendar/calendar-common.scss b/src/addons/calendar/calendar-common.scss index 3746e7872..8b3f5108f 100644 --- a/src/addons/calendar/calendar-common.scss +++ b/src/addons/calendar/calendar-common.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { diff --git a/src/addons/calendar/components/calendar/calendar.scss b/src/addons/calendar/components/calendar/calendar.scss index 0df183e40..f3d27322f 100644 --- a/src/addons/calendar/components/calendar/calendar.scss +++ b/src/addons/calendar/components/calendar/calendar.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { --addon-calendar-blank-day-background-color: var(--light); diff --git a/src/addons/calendar/components/filter/filter.scss b/src/addons/calendar/components/filter/filter.scss index 29e652dd0..dd51360a8 100644 --- a/src/addons/calendar/components/filter/filter.scss +++ b/src/addons/calendar/components/filter/filter.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { ion-item { diff --git a/src/addons/messages/messages-common.scss b/src/addons/messages/messages-common.scss index 255a9a156..da75d7348 100644 --- a/src/addons/messages/messages-common.scss +++ b/src/addons/messages/messages-common.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { .addon-messages-conversation-item, diff --git a/src/addons/messages/pages/discussion/discussion.scss b/src/addons/messages/pages/discussion/discussion.scss index 0c82d4a87..2de83952c 100644 --- a/src/addons/messages/pages/discussion/discussion.scss +++ b/src/addons/messages/pages/discussion/discussion.scss @@ -1,5 +1,4 @@ -@import "~theme/components/discussion.scss"; -@import "~theme/globals.scss"; +@use "theme/globals" as *; :host { diff --git a/src/addons/messages/pages/discussion/discussion.ts b/src/addons/messages/pages/discussion/discussion.ts index 74e817bc7..6f36ec0f9 100644 --- a/src/addons/messages/pages/discussion/discussion.ts +++ b/src/addons/messages/pages/discussion/discussion.ts @@ -51,7 +51,7 @@ import { CoreDom } from '@singletons/dom'; @Component({ selector: 'page-addon-messages-discussion', templateUrl: 'discussion.html', - styleUrls: ['discussion.scss'], + styleUrls: ['../../../../theme/components/discussion.scss', 'discussion.scss'], }) export class AddonMessagesDiscussionPage implements OnInit, OnDestroy, AfterViewInit { diff --git a/src/addons/mod/chat/pages/chat/chat.scss b/src/addons/mod/chat/pages/chat/chat.scss index 79a0b6be9..2ee6b3c8c 100644 --- a/src/addons/mod/chat/pages/chat/chat.scss +++ b/src/addons/mod/chat/pages/chat/chat.scss @@ -1,5 +1,3 @@ -@import "~theme/components/discussion.scss"; - :host { .addon-mod_chat-notice { margin-top: 8px; diff --git a/src/addons/mod/chat/pages/chat/chat.ts b/src/addons/mod/chat/pages/chat/chat.ts index e1c168c10..bbba13c00 100644 --- a/src/addons/mod/chat/pages/chat/chat.ts +++ b/src/addons/mod/chat/pages/chat/chat.ts @@ -37,7 +37,7 @@ import { CoreAnalytics, CoreAnalyticsEventType } from '@services/analytics'; @Component({ selector: 'page-addon-mod-chat-chat', templateUrl: 'chat.html', - styleUrls: ['chat.scss'], + styleUrls: ['../../../../../theme/components/discussion.scss', 'chat.scss'], }) export class AddonModChatChatPage implements OnInit, OnDestroy, CanLeave { diff --git a/src/addons/mod/chat/pages/session-messages/session-messages.scss b/src/addons/mod/chat/pages/session-messages/session-messages.scss index 79a0b6be9..2ee6b3c8c 100644 --- a/src/addons/mod/chat/pages/session-messages/session-messages.scss +++ b/src/addons/mod/chat/pages/session-messages/session-messages.scss @@ -1,5 +1,3 @@ -@import "~theme/components/discussion.scss"; - :host { .addon-mod_chat-notice { margin-top: 8px; diff --git a/src/addons/mod/chat/pages/session-messages/session-messages.ts b/src/addons/mod/chat/pages/session-messages/session-messages.ts index fa94740e1..8401d485d 100644 --- a/src/addons/mod/chat/pages/session-messages/session-messages.ts +++ b/src/addons/mod/chat/pages/session-messages/session-messages.ts @@ -31,7 +31,7 @@ import { CoreTime } from '@singletons/time'; @Component({ selector: 'page-addon-mod-chat-session-messages', templateUrl: 'session-messages.html', - styleUrls: ['session-messages.scss'], + styleUrls: ['../../../../../theme/components/discussion.scss', 'session-messages.scss'], }) export class AddonModChatSessionMessagesPage implements OnInit { diff --git a/src/addons/mod/data/data-forms.scss b/src/addons/mod/data/data-forms.scss index 1ee47a8c0..92f6ff9fa 100644 --- a/src/addons/mod/data/data-forms.scss +++ b/src/addons/mod/data/data-forms.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; // Edit and search modal. :host { diff --git a/src/addons/mod/data/data.scss b/src/addons/mod/data/data.scss index b844da080..d96d7035c 100644 --- a/src/addons/mod/data/data.scss +++ b/src/addons/mod/data/data.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; /// @prop - The padding for the grid column $grid-column-padding: var(--ion-grid-column-padding, 5px) !default; diff --git a/src/addons/mod/forum/components/index/index.scss b/src/addons/mod/forum/components/index/index.scss index c89233e8f..be5046279 100644 --- a/src/addons/mod/forum/components/index/index.scss +++ b/src/addons/mod/forum/components/index/index.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { diff --git a/src/addons/mod/forum/components/post/post.scss b/src/addons/mod/forum/components/post/post.scss index b4a5b0092..4dfb6f53a 100644 --- a/src/addons/mod/forum/components/post/post.scss +++ b/src/addons/mod/forum/components/post/post.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host .addon-mod_forum-post { background-color: var(--ion-item-background); diff --git a/src/addons/mod/forum/pages/new-discussion/new-discussion.scss b/src/addons/mod/forum/pages/new-discussion/new-discussion.scss index 9ddfaed1c..92b171fe7 100644 --- a/src/addons/mod/forum/pages/new-discussion/new-discussion.scss +++ b/src/addons/mod/forum/pages/new-discussion/new-discussion.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { .addon-forum-group-info { diff --git a/src/addons/mod/h5pactivity/pages/attempt-results/attempt-results.scss b/src/addons/mod/h5pactivity/pages/attempt-results/attempt-results.scss index 09e782178..a9021111d 100644 --- a/src/addons/mod/h5pactivity/pages/attempt-results/attempt-results.scss +++ b/src/addons/mod/h5pactivity/pages/attempt-results/attempt-results.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { .core-warning-item { diff --git a/src/addons/mod/lesson/pages/user-retake/user-retake.scss b/src/addons/mod/lesson/pages/user-retake/user-retake.scss index 8c364a127..7ff927840 100644 --- a/src/addons/mod/lesson/pages/user-retake/user-retake.scss +++ b/src/addons/mod/lesson/pages/user-retake/user-retake.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { .button-disabled { diff --git a/src/addons/mod/resource/components/index/index.scss b/src/addons/mod/resource/components/index/index.scss index 9874efd46..88b63eec0 100644 --- a/src/addons/mod/resource/components/index/index.scss +++ b/src/addons/mod/resource/components/index/index.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { .addon-mod_resource-outdated { diff --git a/src/addons/mod/scorm/components/index/index.scss b/src/addons/mod/scorm/components/index/index.scss index f8fc150a1..2bda23817 100644 --- a/src/addons/mod/scorm/components/index/index.scss +++ b/src/addons/mod/scorm/components/index/index.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { .addon-mod_scorm-attempt-summary ion-item > p { diff --git a/src/addons/mod/wiki/components/index/index.scss b/src/addons/mod/wiki/components/index/index.scss index 9bbc1c0ed..e2a7ffaac 100644 --- a/src/addons/mod/wiki/components/index/index.scss +++ b/src/addons/mod/wiki/components/index/index.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; $addon-mod-wiki-toc-level-padding: 12px !default; diff --git a/src/addons/notifications/notifications.scss b/src/addons/notifications/notifications.scss index 60caa6312..9dc8d2b0b 100644 --- a/src/addons/notifications/notifications.scss +++ b/src/addons/notifications/notifications.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { --extra-icon-size: 16px; diff --git a/src/addons/notifications/pages/list/list.scss b/src/addons/notifications/pages/list/list.scss index cc83595d1..a5e92ddc2 100644 --- a/src/addons/notifications/pages/list/list.scss +++ b/src/addons/notifications/pages/list/list.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; ion-item { ion-label { diff --git a/src/addons/notifications/pages/notification/notification.scss b/src/addons/notifications/pages/notification/notification.scss index 7b0943218..c1c58d5ab 100644 --- a/src/addons/notifications/pages/notification/notification.scss +++ b/src/addons/notifications/pages/notification/notification.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { diff --git a/src/addons/qtype/ddimageortext/component/ddimageortext.scss b/src/addons/qtype/ddimageortext/component/ddimageortext.scss index dfb6f7f01..de99dcda6 100644 --- a/src/addons/qtype/ddimageortext/component/ddimageortext.scss +++ b/src/addons/qtype/ddimageortext/component/ddimageortext.scss @@ -1,4 +1,4 @@ -@import "~core/features/question/question"; +@use "theme/globals" as *; // Style ddimageortext content a bit. Almost all these styles are copied from Moodle. :host { diff --git a/src/addons/qtype/ddimageortext/component/ddimageortext.ts b/src/addons/qtype/ddimageortext/component/ddimageortext.ts index 6550c2c38..2fbf0b746 100644 --- a/src/addons/qtype/ddimageortext/component/ddimageortext.ts +++ b/src/addons/qtype/ddimageortext/component/ddimageortext.ts @@ -24,7 +24,7 @@ import { AddonQtypeDdImageOrTextQuestion } from '../classes/ddimageortext'; @Component({ selector: 'addon-qtype-ddimageortext', templateUrl: 'addon-qtype-ddimageortext.html', - styleUrls: ['ddimageortext.scss'], + styleUrls: ['../../../../core/features/question/question.scss', 'ddimageortext.scss'], }) export class AddonQtypeDdImageOrTextComponent extends CoreQuestionBaseComponent diff --git a/src/addons/qtype/ddwtos/component/ddwtos.scss b/src/addons/qtype/ddwtos/component/ddwtos.scss index 9c7bed139..557fc3f76 100644 --- a/src/addons/qtype/ddwtos/component/ddwtos.scss +++ b/src/addons/qtype/ddwtos/component/ddwtos.scss @@ -1,4 +1,4 @@ -@import "~core/features/question/question"; +@use "theme/globals" as *; // Style ddwtos content a bit. Almost all these styles are copied from Moodle. .addon-qtype-ddwtos-container { diff --git a/src/addons/qtype/ddwtos/component/ddwtos.ts b/src/addons/qtype/ddwtos/component/ddwtos.ts index 3d76a2747..c3f8631d5 100644 --- a/src/addons/qtype/ddwtos/component/ddwtos.ts +++ b/src/addons/qtype/ddwtos/component/ddwtos.ts @@ -25,7 +25,7 @@ import { AddonQtypeDdwtosQuestion } from '../classes/ddwtos'; @Component({ selector: 'addon-qtype-ddwtos', templateUrl: 'addon-qtype-ddwtos.html', - styleUrls: ['ddwtos.scss'], + styleUrls: ['../../../../core/features/question/question.scss', 'ddwtos.scss'], }) export class AddonQtypeDdwtosComponent extends CoreQuestionBaseComponent implements OnDestroy { diff --git a/src/addons/storagemanager/pages/course-storage/course-storage.scss b/src/addons/storagemanager/pages/course-storage/course-storage.scss index becd7cebb..640d75a3e 100644 --- a/src/addons/storagemanager/pages/course-storage/course-storage.scss +++ b/src/addons/storagemanager/pages/course-storage/course-storage.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { --course-storage-max-activity-height: 120px; diff --git a/src/addons/userprofilefield/checkbox/component/checkbox.scss b/src/addons/userprofilefield/checkbox/component/checkbox.scss index 7306a701f..1fe09f21c 100644 --- a/src/addons/userprofilefield/checkbox/component/checkbox.scss +++ b/src/addons/userprofilefield/checkbox/component/checkbox.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { --text-overflow: initial; diff --git a/src/core/components/combobox/combobox.scss b/src/core/components/combobox/combobox.scss index 3afd8c316..80c9379ad 100644 --- a/src/core/components/combobox/combobox.scss +++ b/src/core/components/combobox/combobox.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { max-width: 100%; diff --git a/src/core/components/context-menu/context-menu-popover.scss b/src/core/components/context-menu/context-menu-popover.scss index 6461e72ef..128643a79 100644 --- a/src/core/components/context-menu/context-menu-popover.scss +++ b/src/core/components/context-menu/context-menu-popover.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; ion-list { padding: 0; diff --git a/src/core/components/course-image/course-image.scss b/src/core/components/course-image/course-image.scss index 5bd16990d..c530efbd0 100644 --- a/src/core/components/course-image/course-image.scss +++ b/src/core/components/course-image/course-image.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { --core-image-radius: var(--core-courseimage-radius); diff --git a/src/core/components/empty-box/empty-box.scss b/src/core/components/empty-box/empty-box.scss index 86fe96d48..7c57385ea 100644 --- a/src/core/components/empty-box/empty-box.scss +++ b/src/core/components/empty-box/empty-box.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { --image-size: 120px; diff --git a/src/core/components/loading/loading.scss b/src/core/components/loading/loading.scss index ff665fdf2..6b2b08ffe 100644 --- a/src/core/components/loading/loading.scss +++ b/src/core/components/loading/loading.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; @mixin inline() { &:not(.core-loading-loaded) { diff --git a/src/core/components/mark-required/mark-required.scss b/src/core/components/mark-required/mark-required.scss index 1c05a77f4..51535396a 100644 --- a/src/core/components/mark-required/mark-required.scss +++ b/src/core/components/mark-required/mark-required.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { .core-input-required-asterisk { diff --git a/src/core/components/message/message.scss b/src/core/components/message/message.scss index 3ece454ac..f179df22d 100644 --- a/src/core/components/message/message.scss +++ b/src/core/components/message/message.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { --message-background: var(--core-messages-message-bg); diff --git a/src/core/components/mod-icon/mod-icon.scss b/src/core/components/mod-icon/mod-icon.scss index 0be4daed3..37913a25e 100644 --- a/src/core/components/mod-icon/mod-icon.scss +++ b/src/core/components/mod-icon/mod-icon.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { display: inline-block; diff --git a/src/core/components/navigation-bar/navigation-bar.scss b/src/core/components/navigation-bar/navigation-bar.scss index 6579ff761..bdc0220d6 100644 --- a/src/core/components/navigation-bar/navigation-bar.scss +++ b/src/core/components/navigation-bar/navigation-bar.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { --height: var(--core-navigation-max-height); diff --git a/src/core/components/progress-bar/progress-bar.scss b/src/core/components/progress-bar/progress-bar.scss index 0246fad88..7937c4595 100644 --- a/src/core/components/progress-bar/progress-bar.scss +++ b/src/core/components/progress-bar/progress-bar.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { display: flex; diff --git a/src/core/components/refresh-button-modal/refresh-button-modal.scss b/src/core/components/refresh-button-modal/refresh-button-modal.scss index 5541fba16..93102a126 100644 --- a/src/core/components/refresh-button-modal/refresh-button-modal.scss +++ b/src/core/components/refresh-button-modal/refresh-button-modal.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { ion-chip { diff --git a/src/core/components/sheet-modal/sheet-modal.scss b/src/core/components/sheet-modal/sheet-modal.scss index a03fd57e8..b1170cfcd 100644 --- a/src/core/components/sheet-modal/sheet-modal.scss +++ b/src/core/components/sheet-modal/sheet-modal.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { --backdrop-opacity: var(--ion-backdrop-opacity, 0.4); diff --git a/src/core/components/show-password/show-password.scss b/src/core/components/show-password/show-password.scss index 07280df85..c866c89cd 100644 --- a/src/core/components/show-password/show-password.scss +++ b/src/core/components/show-password/show-password.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { display: contents; diff --git a/src/core/components/split-view/split-view.scss b/src/core/components/split-view/split-view.scss index ab8692946..1024e55a1 100644 --- a/src/core/components/split-view/split-view.scss +++ b/src/core/components/split-view/split-view.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { --menu-min-width: 270px; diff --git a/src/core/components/tabs/tabs.scss b/src/core/components/tabs/tabs.scss index 26eebb6a9..66a57c342 100644 --- a/src/core/components/tabs/tabs.scss +++ b/src/core/components/tabs/tabs.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { --tabs-background: var(--core-tabs-background); diff --git a/src/core/components/user-avatar/user-avatar.scss b/src/core/components/user-avatar/user-avatar.scss index 2b6e28aa9..1ffc913c8 100644 --- a/src/core/components/user-avatar/user-avatar.scss +++ b/src/core/components/user-avatar/user-avatar.scss @@ -1,4 +1,4 @@ -@import '~theme/globals.scss'; +@use "theme/globals" as *; :host { position: relative; diff --git a/src/core/features/block/components/side-blocks-button/side-blocks-button.scss b/src/core/features/block/components/side-blocks-button/side-blocks-button.scss index f8f4f8250..cd1537e63 100644 --- a/src/core/features/block/components/side-blocks-button/side-blocks-button.scss +++ b/src/core/features/block/components/side-blocks-button/side-blocks-button.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { @include position(50%, 0px, null, null); diff --git a/src/core/features/block/components/side-blocks/side-blocks.scss b/src/core/features/block/components/side-blocks/side-blocks.scss index fc2f730f2..17669c03e 100644 --- a/src/core/features/block/components/side-blocks/side-blocks.scss +++ b/src/core/features/block/components/side-blocks/side-blocks.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host ::ng-deep core-block { @include media-breakpoint-up(md) { diff --git a/src/core/features/comments/pages/viewer/viewer.scss b/src/core/features/comments/pages/viewer/viewer.scss index cf231da48..e8297c249 100644 --- a/src/core/features/comments/pages/viewer/viewer.scss +++ b/src/core/features/comments/pages/viewer/viewer.scss @@ -1,5 +1,3 @@ -@import "~theme/components/discussion.scss"; - ion-badge { margin: 8px auto; } diff --git a/src/core/features/comments/pages/viewer/viewer.ts b/src/core/features/comments/pages/viewer/viewer.ts index ba750924b..f1401ecb6 100644 --- a/src/core/features/comments/pages/viewer/viewer.ts +++ b/src/core/features/comments/pages/viewer/viewer.ts @@ -51,7 +51,7 @@ import { CoreAnimations } from '@components/animations'; selector: 'page-core-comments-viewer', templateUrl: 'viewer.html', animations: [CoreAnimations.SLIDE_IN_OUT], - styleUrls: ['viewer.scss'], + styleUrls: ['../../../../../theme/components/discussion.scss', 'viewer.scss'], }) export class CoreCommentsViewerPage implements OnInit, OnDestroy { diff --git a/src/core/features/course/components/course-index/course-index.scss b/src/core/features/course/components/course-index/course-index.scss index 2c169c852..2b2aa5de0 100644 --- a/src/core/features/course/components/course-index/course-index.scss +++ b/src/core/features/course/components/course-index/course-index.scss @@ -1,4 +1,4 @@ -@import '~theme/globals.scss'; +@use "theme/globals" as *; core-progress-bar { --bar-margin: 8px 0 4px 0; --line-height: 20px; diff --git a/src/core/features/course/components/module-info/course-module-info.scss b/src/core/features/course/components/module-info/course-module-info.scss index 389a72714..013704204 100644 --- a/src/core/features/course/components/module-info/course-module-info.scss +++ b/src/core/features/course/components/module-info/course-module-info.scss @@ -1,4 +1,4 @@ -@import '~theme/globals.scss'; +@use "theme/globals" as *; :host { display: block; diff --git a/src/core/features/course/components/module-navigation/module-navigation.scss b/src/core/features/course/components/module-navigation/module-navigation.scss index 95d039bfb..8e4d48343 100644 --- a/src/core/features/course/components/module-navigation/module-navigation.scss +++ b/src/core/features/course/components/module-navigation/module-navigation.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { --height: var(--core-navigation-max-height); diff --git a/src/core/features/course/components/module-summary/module-summary.scss b/src/core/features/course/components/module-summary/module-summary.scss index e524c4757..3594fb7eb 100644 --- a/src/core/features/course/components/module-summary/module-summary.scss +++ b/src/core/features/course/components/module-summary/module-summary.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host ::ng-deep ion-item[collapsible] ion-label { margin-top: 12px; diff --git a/src/core/features/course/components/module/module.scss b/src/core/features/course/components/module/module.scss index 3e96dbc1f..8bed4a7a9 100644 --- a/src/core/features/course/components/module/module.scss +++ b/src/core/features/course/components/module/module.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { --horizontal-margin: 12px; diff --git a/src/core/features/course/pages/course-summary/course-summary.scss b/src/core/features/course/pages/course-summary/course-summary.scss index 03c882ad9..b26938458 100644 --- a/src/core/features/course/pages/course-summary/course-summary.scss +++ b/src/core/features/course/pages/course-summary/course-summary.scss @@ -1,4 +1,4 @@ -@import '~theme/globals.scss'; +@use "theme/globals" as *; :host { --thumb-height: 180px; diff --git a/src/core/features/course/pages/index/index.scss b/src/core/features/course/pages/index/index.scss index 216c0eb75..32907c9a4 100644 --- a/src/core/features/course/pages/index/index.scss +++ b/src/core/features/course/pages/index/index.scss @@ -1,4 +1,4 @@ -@import '~theme/globals.scss'; +@use "theme/globals" as *; :host { .core-format-progress-list { diff --git a/src/core/features/course/pages/module-preview/module-preview.scss b/src/core/features/course/pages/module-preview/module-preview.scss index 1481b21b3..5e34beb75 100644 --- a/src/core/features/course/pages/module-preview/module-preview.scss +++ b/src/core/features/course/pages/module-preview/module-preview.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; .core-module-availabilityinfo { background: var(--light); diff --git a/src/core/features/courses/components/course-list-item/course-list-item.scss b/src/core/features/courses/components/course-list-item/course-list-item.scss index 31cbcadc2..6ede3c36d 100644 --- a/src/core/features/courses/components/course-list-item/course-list-item.scss +++ b/src/core/features/courses/components/course-list-item/course-list-item.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { @for $i from 0 to length($core-course-image-background) { diff --git a/src/core/features/editor/components/rich-text-editor/rich-text-editor.scss b/src/core/features/editor/components/rich-text-editor/rich-text-editor.scss index b009050e0..150441cdf 100644 --- a/src/core/features/editor/components/rich-text-editor/rich-text-editor.scss +++ b/src/core/features/editor/components/rich-text-editor/rich-text-editor.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { --placeholder-color: var(--ion-placeholder-color); --toobar-background: var(--white); diff --git a/src/core/features/grades/pages/course/course.scss b/src/core/features/grades/pages/course/course.scss index 388f624e4..3e1cd42bc 100644 --- a/src/core/features/grades/pages/course/course.scss +++ b/src/core/features/grades/pages/course/course.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { --header-background: var(--white); diff --git a/src/core/features/login/components/site-onboarding/site-onboarding.scss b/src/core/features/login/components/site-onboarding/site-onboarding.scss index 084eee0f2..a03301739 100644 --- a/src/core/features/login/components/site-onboarding/site-onboarding.scss +++ b/src/core/features/login/components/site-onboarding/site-onboarding.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { .core-login-onboarding-step { diff --git a/src/core/features/login/login.scss b/src/core/features/login/login.scss index 785732e0a..1c9514390 100644 --- a/src/core/features/login/login.scss +++ b/src/core/features/login/login.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { ion-content, diff --git a/src/core/features/login/pages/site/site.scss b/src/core/features/login/pages/site/site.scss index ddb292de2..8bf0224bf 100644 --- a/src/core/features/login/pages/site/site.scss +++ b/src/core/features/login/pages/site/site.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { --list-item-max-width: 600px; diff --git a/src/core/features/mainmenu/components/user-menu/user-menu.scss b/src/core/features/mainmenu/components/user-menu/user-menu.scss index a42d797cd..0c871f3f0 100644 --- a/src/core/features/mainmenu/components/user-menu/user-menu.scss +++ b/src/core/features/mainmenu/components/user-menu/user-menu.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { .core-user-menu-preferences { diff --git a/src/core/features/mainmenu/pages/menu/menu.scss b/src/core/features/mainmenu/pages/menu/menu.scss index 637457cc4..d72dfe76c 100644 --- a/src/core/features/mainmenu/pages/menu/menu.scss +++ b/src/core/features/mainmenu/pages/menu/menu.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { ion-tabs { diff --git a/src/core/features/question/question.scss b/src/core/features/question/question.scss index 7c94d2f05..4ae53140a 100644 --- a/src/core/features/question/question.scss +++ b/src/core/features/question/question.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host ::ng-deep { .core-question-answer-correct { diff --git a/src/core/features/reminders/components/date/date.scss b/src/core/features/reminders/components/date/date.scss index 8d16930b4..7b32f1d09 100644 --- a/src/core/features/reminders/components/date/date.scss +++ b/src/core/features/reminders/components/date/date.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { display: flex; diff --git a/src/core/features/reportbuilder/components/report-column/report-column.scss b/src/core/features/reportbuilder/components/report-column/report-column.scss index 65df0f953..31767c74f 100644 --- a/src/core/features/reportbuilder/components/report-column/report-column.scss +++ b/src/core/features/reportbuilder/components/report-column/report-column.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { --rotate-expandable: rotate(180deg); diff --git a/src/core/features/reportbuilder/components/report-detail/report-detail.scss b/src/core/features/reportbuilder/components/report-detail/report-detail.scss index 1f9dcd143..02f8bd52a 100644 --- a/src/core/features/reportbuilder/components/report-detail/report-detail.scss +++ b/src/core/features/reportbuilder/components/report-detail/report-detail.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { --header-background: var(--white); diff --git a/src/core/features/reportbuilder/components/report-summary/report-summary.scss b/src/core/features/reportbuilder/components/report-summary/report-summary.scss index 32bb1fe4e..1512f8e33 100644 --- a/src/core/features/reportbuilder/components/report-summary/report-summary.scss +++ b/src/core/features/reportbuilder/components/report-summary/report-summary.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; .filters-info { padding-bottom: 1rem; diff --git a/src/core/features/sitehome/pages/index/index.scss b/src/core/features/sitehome/pages/index/index.scss index 8a8e71e12..9c849123b 100644 --- a/src/core/features/sitehome/pages/index/index.scss +++ b/src/core/features/sitehome/pages/index/index.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; ion-item ion-icon { display: inline-block; diff --git a/src/core/features/tag/components/list/list.scss b/src/core/features/tag/components/list/list.scss index 1f8205861..861b4a9c4 100644 --- a/src/core/features/tag/components/list/list.scss +++ b/src/core/features/tag/components/list/list.scss @@ -1,4 +1,4 @@ -@import "~theme/globals"; +@use "theme/globals" as *; :host { line-height: 1.6; diff --git a/src/theme/components/discussion.scss b/src/theme/components/discussion.scss index fcb653a9d..c2cc72133 100644 --- a/src/theme/components/discussion.scss +++ b/src/theme/components/discussion.scss @@ -1,4 +1,4 @@ -@import "~theme/globals.scss"; +@use "theme/globals" as *; :host-context(.ios) { ion-footer .toolbar:last-child { diff --git a/src/theme/components/format-text.scss b/src/theme/components/format-text.scss index bf2f2d4cd..2b937a7d8 100644 --- a/src/theme/components/format-text.scss +++ b/src/theme/components/format-text.scss @@ -1,6 +1,6 @@ /** Format Text - Show more styles. */ /** Styles of elements inside the directive should be placed in format-text.scss */ -@import "~theme/globals"; +@use "theme/globals.variables" as global; core-format-text { --core-format-text-background: var(--background, var(--ion-item-background)); @@ -42,7 +42,7 @@ core-format-text { } } - @if ($core-format-text-never-shorten) { + @if (global.$core-format-text-never-shorten) { &.collapsible-enabled { --display-toggle: none !important; --collapsible-height: auto !important; @@ -200,7 +200,7 @@ core-format-text { .embed-responsive-1by1 { &::before { - padding-top: percentage(1 / 1); + padding-top: percentage(1); } } @@ -474,7 +474,7 @@ core-rich-text-editor .core-rte-editor { font-weight: 400; } - @each $color-name, $unused in $colors { + @each $color-name, $unused in global.$colors { .alert-#{$color-name} { --color-base: var(--#{$color-name}); color: var(--#{$color-name}-shade); @@ -504,7 +504,7 @@ core-rich-text-editor .core-rte-editor { &[disabled] ~ .form-check-label, &:disabled ~ .form-check-label { - color: $gray-600; + color: global.$gray-600; } } @@ -549,7 +549,7 @@ core-rich-text-editor .core-rte-editor { .border-bottom-0 { border-bottom: 0 !important; } .border-left-0 { border-left: 0 !important; } - @each $color-name, $unused in $colors { + @each $color-name, $unused in global.$colors { .border-#{$color-name} { border-color: var(--#{$color-name}) !important; } @@ -633,7 +633,7 @@ core-rich-text-editor .core-rte-editor { .font-italic { font-style: italic !important; } .text-white { color: var(--white) !important; } - @each $color-name, $unused in $colors { + @each $color-name, $unused in global.$colors { .text-#{$color-name} { color: var(--#{$color-name}); } @@ -669,7 +669,7 @@ core-rich-text-editor .core-rte-editor { background-color: var(--danger); } - @each $color-name, $unused in $colors { + @each $color-name, $unused in global.$colors { .label-#{$color-name} { color: var(--#{$color-name}-contrast); background-color: var(--#{$color-name}); @@ -690,7 +690,7 @@ core-rich-text-editor .core-rte-editor { } } - @each $color-name, $unused in $colors { + @each $color-name, $unused in global.$colors { .btn.btn-#{$color-name} { --color-base: var(--#{$color-name}); color: var(--#{$color-name}-shade); diff --git a/src/theme/theme.scss b/src/theme/theme.scss index 5baa55e42..af644c972 100644 --- a/src/theme/theme.scss +++ b/src/theme/theme.scss @@ -10,26 +10,26 @@ */ /* Global variables */ -@import "./globals.scss"; +@import "globals.scss"; /* Application styles */ -@import "./theme.light.scss"; -@import "./theme.dark.scss"; -@import "./theme.custom.scss"; -@import "./theme.design-system.scss"; -@import "./theme.base.scss"; +@import "theme.light.scss"; +@import "theme.dark.scss"; +@import "theme.custom.scss"; +@import "theme.design-system.scss"; +@import "theme.base.scss"; /* Components */ -@import "./components/collapsible-header.scss"; -@import "./components/collapsible-item.scss"; -@import "./components/format-text.scss"; -@import "./components/rubrics.scss"; -@import "./components/mod-label.scss"; +@import "components/collapsible-header.scss"; +@import "components/collapsible-item.scss"; +@import "components/format-text.scss"; +@import "components/rubrics.scss"; +@import "components/mod-label.scss"; @import "../core/components/error-info/error-info.scss"; -@import "./components/videojs.scss"; +@import "components/videojs.scss"; /* Some styles from 3rd party libraries. */ -@import "./bootstrap.scss"; +@import "bootstrap.scss"; /* Core CSS required for Ionic components to work properly */ @import "~@ionic/angular/css/core.css"; @@ -38,7 +38,7 @@ @import "~@ionic/angular/css/normalize.css"; @import "~@ionic/angular/css/structure.css"; @import "~@ionic/angular/css/typography.css"; -@import '~@ionic/angular/css/display.css'; +@import "~@ionic/angular/css/display.css"; /* Optional CSS utils that can be commented out */ @import "~@ionic/angular/css/padding.css"; From 4ca0cf785aef0b55a9202f070453a55314f2b930 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pau=20Ferrer=20Oca=C3=B1a?= Date: Tue, 7 Nov 2023 16:16:51 +0100 Subject: [PATCH 04/17] MOBILE-3947 chore: Deprecation fixes --- .../rich-text-editor/rich-text-editor.ts | 4 ++++ src/core/services/lang.ts | 15 +++++++++------ src/core/services/utils/utils.ts | 2 +- 3 files changed, 14 insertions(+), 7 deletions(-) diff --git a/src/core/features/editor/components/rich-text-editor/rich-text-editor.ts b/src/core/features/editor/components/rich-text-editor/rich-text-editor.ts index fde9e250e..6df15894d 100644 --- a/src/core/features/editor/components/rich-text-editor/rich-text-editor.ts +++ b/src/core/features/editor/components/rich-text-editor/rich-text-editor.ts @@ -174,6 +174,7 @@ export class CoreEditorRichTextEditorComponent implements OnInit, AfterViewInit, this.lastDraft = this.control?.value; // Use paragraph on enter. + // eslint-disable-next-line deprecation/deprecation document.execCommand('DefaultParagraphSeparator', false, 'p'); this.maximizeEditorSize(); @@ -632,6 +633,7 @@ export class CoreEditorRichTextEditorComponent implements OnInit, AfterViewInit, */ protected executeCommand({ name: command, parameters }: EditorCommand): void { if (parameters == 'block') { + // eslint-disable-next-line deprecation/deprecation document.execCommand('formatBlock', false, '<' + command + '>'); return; @@ -641,6 +643,7 @@ export class CoreEditorRichTextEditorComponent implements OnInit, AfterViewInit, this.toolbarStyles[parameters] = this.toolbarStyles[parameters] == 'true' ? 'false' : 'true'; } + // eslint-disable-next-line deprecation/deprecation document.execCommand(command, false); // Modern browsers are using non a11y tags, so replace them. @@ -1043,6 +1046,7 @@ export class CoreEditorRichTextEditorComponent implements OnInit, AfterViewInit, if (text) { this.editorElement?.focus(); // Make sure the editor is focused. + // eslint-disable-next-line deprecation/deprecation document.execCommand('insertText', false, text); } } diff --git a/src/core/services/lang.ts b/src/core/services/lang.ts index f85eb43c8..78fd63355 100644 --- a/src/core/services/lang.ts +++ b/src/core/services/lang.ts @@ -349,12 +349,15 @@ export class CoreLangProvider { getTranslationTable(lang: string): Promise> { // Create a promise to convert the observable into a promise. return new Promise((resolve, reject): void => { - const observer = Translate.getTranslation(lang).subscribe((table) => { - resolve(table); - observer.unsubscribe(); - }, (err) => { - reject(err); - observer.unsubscribe(); + const observer = Translate.getTranslation(lang).subscribe({ + next: (table) => { + resolve(table); + observer.unsubscribe(); + }, + error: (err) => { + reject(err); + observer.unsubscribe(); + }, }); }); } diff --git a/src/core/services/utils/utils.ts b/src/core/services/utils/utils.ts index 147930bb8..16ccfe1f2 100644 --- a/src/core/services/utils/utils.ts +++ b/src/core/services/utils/utils.ts @@ -376,7 +376,7 @@ export class CoreUtilsProvider { virtualInput.innerHTML = text; virtualInput.select(); virtualInput.setSelectionRange(0, 99999); - document.execCommand('copy'); + document.execCommand('copy'); // eslint-disable-line deprecation/deprecation } // Show toast using ionicLoading. From 9be60c9e83aa4098281852d05f460c55a00638ec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pau=20Ferrer=20Oca=C3=B1a?= Date: Tue, 7 Nov 2023 15:52:08 +0100 Subject: [PATCH 05/17] MOBILE-3947 chore: Fix eqeqeq on HTML --- .../myoverview/addon-block-myoverview.html | 6 ++--- .../calendar/pages/edit-event/edit-event.html | 6 ++--- .../messages/pages/contacts-35/contacts.html | 4 +-- .../messages/pages/discussion/discussion.html | 14 +++++----- src/addons/messages/pages/search/search.html | 2 +- .../mod/assign/components/index/index.ts | 2 +- .../addon-mod-assign-submission.html | 12 ++++----- src/addons/mod/chat/pages/chat/chat.html | 8 +++--- .../session-messages/session-messages.html | 8 +++--- .../action/addon-mod-data-action.html | 26 +++++++++---------- .../mod/feedback/pages/attempt/attempt.html | 4 +-- src/addons/mod/feedback/pages/form/form.html | 20 +++++++------- .../mod/forum/components/index/index.html | 2 +- .../mod/forum/components/post/post.html | 2 +- .../forum/pages/discussion/discussion.html | 10 +++---- .../pages/new-discussion/new-discussion.html | 2 +- .../pages/new-discussion/new-discussion.ts | 1 - .../navigation-modal/navigation-modal.html | 10 +++---- .../index/addon-mod-resource-index.html | 8 +++--- .../mod/resource/pages/index/index.html | 2 +- .../index/addon-mod-workshop-index.html | 10 +++---- .../mod/workshop/components/phase/phase.html | 8 +++--- .../mod/workshop/services/workshop-helper.ts | 2 +- src/addons/notes/pages/list/list.html | 4 +-- src/addons/notes/pages/list/list.ts | 2 +- .../privatefiles/pages/index/index.html | 2 +- .../essay/component/addon-qtype-essay.html | 2 +- .../components/combobox/core-combobox.html | 6 ++--- .../core-context-menu-popover.html | 6 ++--- .../core-infinite-loading.html | 4 +-- .../input-errors/core-input-errors.html | 4 +-- src/core/components/tabs/core-tabs.html | 4 +-- .../module-summary/module-summary.html | 20 +++++++------- .../pages/course-summary/course-summary.html | 2 +- .../core-courses-course-list-item.html | 14 +++++----- .../core-courses-course-options-menu.html | 2 +- .../features/grades/pages/course/course.html | 2 +- .../grades/pages/courses/courses.html | 2 +- src/core/features/login/pages/site/site.html | 8 +++--- .../features/mainmenu/pages/menu/menu.html | 4 +-- .../features/mainmenu/pages/more/more.html | 8 +++--- .../search-box/core-search-box.html | 2 +- .../settings/pages/general/general.html | 2 +- src/core/features/tag/pages/index/index.html | 2 +- .../user/classes/support/support-config.ts | 4 +-- 45 files changed, 137 insertions(+), 138 deletions(-) diff --git a/src/addons/block/myoverview/components/myoverview/addon-block-myoverview.html b/src/addons/block/myoverview/components/myoverview/addon-block-myoverview.html index 0c7735f12..90adc25e6 100644 --- a/src/addons/block/myoverview/components/myoverview/addon-block-myoverview.html +++ b/src/addons/block/myoverview/components/myoverview/addon-block-myoverview.html @@ -88,11 +88,11 @@ - - @@ -123,7 +123,7 @@
- + diff --git a/src/addons/calendar/pages/edit-event/edit-event.html b/src/addons/calendar/pages/edit-event/edit-event.html index a61fcb899..102ac07dc 100644 --- a/src/addons/calendar/pages/edit-event/edit-event.html +++ b/src/addons/calendar/pages/edit-event/edit-event.html @@ -51,7 +51,7 @@ - +

{{ 'core.category' | translate }}

@@ -64,7 +64,7 @@
- +

{{ 'core.course' | translate }}

@@ -75,7 +75,7 @@
- + diff --git a/src/addons/messages/pages/contacts-35/contacts.html b/src/addons/messages/pages/contacts-35/contacts.html index 1e52521df..314a3b0d0 100644 --- a/src/addons/messages/pages/contacts-35/contacts.html +++ b/src/addons/messages/pages/contacts-35/contacts.html @@ -22,10 +22,10 @@ autocorrect="off" spellcheck="false" lengthCheck="2" [disabled]="!loaded" searchArea="AddonMessagesContacts"> - - diff --git a/src/addons/messages/pages/discussion/discussion.html b/src/addons/messages/pages/discussion/discussion.html index 775381ad4..0e402e14f 100644 --- a/src/addons/messages/pages/discussion/discussion.html +++ b/src/addons/messages/pages/discussion/discussion.html @@ -103,17 +103,17 @@ - -

+ +

{{ 'addon.messages.unabletomessage' | translate }}

-
+

{{ 'addon.messages.youhaveblockeduser' | translate }}

{{ 'addon.messages.unblockuser' | translate }}
-
+

{{ 'addon.messages.isnotinyourcontacts' | translate: {$a: otherMember.fullname} }}

@@ -122,7 +122,7 @@ {{ 'addon.messages.sendcontactrequest' | translate }}
-
+

{{ 'addon.messages.userwouldliketocontactyou' | translate: {$a: otherMember.fullname} }}

{{ 'addon.messages.acceptandaddcontact' | translate }} @@ -131,13 +131,13 @@ {{ 'addon.messages.decline' | translate }}
-
+

{{ 'addon.messages.contactrequestsent' | translate }}

{{ 'addon.messages.yourcontactrequestpending' | translate: {$a: otherMember.fullname} }}

- diff --git a/src/addons/messages/pages/search/search.html b/src/addons/messages/pages/search/search.html index afbf8b227..f55f879bd 100644 --- a/src/addons/messages/pages/search/search.html +++ b/src/addons/messages/pages/search/search.html @@ -68,7 +68,7 @@ - +
{{ 'core.loadmore' | translate }} diff --git a/src/addons/mod/assign/components/index/index.ts b/src/addons/mod/assign/components/index/index.ts index 638ba2215..e72b848c7 100644 --- a/src/addons/mod/assign/components/index/index.ts +++ b/src/addons/mod/assign/components/index/index.ts @@ -54,7 +54,7 @@ import { AddonModAssignSubmissionComponent } from '../submission/submission'; }) export class AddonModAssignIndexComponent extends CoreCourseModuleMainActivityComponent implements OnInit, OnDestroy { - @ViewChild(AddonModAssignSubmissionComponent) submissionComponent?: AddonModAssignSubmissionComponent; + @ViewChild(AddonModAssignSubmissionComponent) submissionComponent?: AddonModAssignSubmissionComponent; component = AddonModAssignProvider.COMPONENT; pluginName = 'assign'; diff --git a/src/addons/mod/assign/components/submission/addon-mod-assign-submission.html b/src/addons/mod/assign/components/submission/addon-mod-assign-submission.html index 2bd756e01..ac1208cd8 100644 --- a/src/addons/mod/assign/components/submission/addon-mod-assign-submission.html +++ b/src/addons/mod/assign/components/submission/addon-mod-assign-submission.html @@ -264,7 +264,7 @@ + *ngIf="feedback?.gradefordisplay && (!isGrading || grade.method !== 'simple')">

{{ 'addon.mod_assign.currentgrade' | translate }}

@@ -280,7 +280,7 @@ - +

{{ 'addon.mod_assign.gradeoutof' | translate: {$a: gradeInfo!.grade} }}

@@ -291,7 +291,7 @@
- +

{{ 'addon.mod_assign.grade' | translate }}

@@ -323,13 +323,13 @@

{{ 'addon.mod_assign.currentassigngrade' | translate }}

-

{{ grade.unreleasedGrade}} / {{ gradeInfo.grade }}

-

{{ grade.unreleasedGrade }}

+

{{ grade.unreleasedGrade}} / {{ gradeInfo.grade }}

+

{{ grade.unreleasedGrade }}

- +

{{ 'addon.mod_assign.currentgrade' | translate }}

diff --git a/src/addons/mod/chat/pages/chat/chat.html b/src/addons/mod/chat/pages/chat/chat.html index 4cbfff287..281a4e325 100644 --- a/src/addons/mod/chat/pages/chat/chat.html +++ b/src/addons/mod/chat/pages/chat/chat.html @@ -26,7 +26,7 @@

- + {{ message.timestamp * 1000 | coreFormatDate:"strftimetime" }} @@ -34,7 +34,7 @@ - + {{ message.timestamp * 1000 | coreFormatDate:"strftimetime" }} @@ -42,7 +42,7 @@ - + {{ message.timestamp * 1000 | coreFormatDate:"strftimetime" }} @@ -60,7 +60,7 @@ + *ngIf="message.userid === currentUserId && message.beep && message.beep !== 'all'"> {{ message.timestamp * 1000 | coreFormatDate:"strftimetime" }} diff --git a/src/addons/mod/chat/pages/session-messages/session-messages.html b/src/addons/mod/chat/pages/session-messages/session-messages.html index dbcb5d29c..76a956b89 100644 --- a/src/addons/mod/chat/pages/session-messages/session-messages.html +++ b/src/addons/mod/chat/pages/session-messages/session-messages.html @@ -21,7 +21,7 @@
- + {{ message.timestamp * 1000 | coreFormatDate:"strftimetime" }} @@ -29,7 +29,7 @@ - + {{ message.timestamp * 1000 | coreFormatDate:"strftimetime" }} @@ -37,7 +37,7 @@ - + {{ message.timestamp * 1000 | coreFormatDate:"strftimetime" }} @@ -55,7 +55,7 @@ + *ngIf="message.userid === currentUserId && message.beep && message.beep !== 'all'"> {{ message.timestamp * 1000 | coreFormatDate:"strftimetime" }} diff --git a/src/addons/mod/data/components/action/addon-mod-data-action.html b/src/addons/mod/data/components/action/addon-mod-data-action.html index f1506fd9c..2fca169f6 100644 --- a/src/addons/mod/data/components/action/addon-mod-data-action.html +++ b/src/addons/mod/data/components/action/addon-mod-data-action.html @@ -1,49 +1,49 @@ - - - + - - - - - -{{ entry.timecreated * 1000 | coreFormatDate }} -{{ entry.timemodified * 1000 | coreFormatDate }} +{{ entry.timecreated * 1000 | coreFormatDate }} +{{ entry.timemodified * 1000 | coreFormatDate }} - - + {{entry.fullname}} - + diff --git a/src/addons/mod/feedback/pages/attempt/attempt.html b/src/addons/mod/feedback/pages/attempt/attempt.html index 0a110f49b..a8d28e106 100644 --- a/src/addons/mod/feedback/pages/attempt/attempt.html +++ b/src/addons/mod/feedback/pages/attempt/attempt.html @@ -30,8 +30,8 @@ - - + +

{{item.itemnumber}}. diff --git a/src/addons/mod/feedback/pages/form/form.html b/src/addons/mod/feedback/pages/form/form.html index 5b417b796..4f55ac59e 100644 --- a/src/addons/mod/feedback/pages/form/form.html +++ b/src/addons/mod/feedback/pages/form/form.html @@ -23,8 +23,8 @@ - - + + @@ -35,18 +35,18 @@ {{item.postfix}}

-

+

- - + @@ -56,11 +56,11 @@ - - @@ -71,7 +71,7 @@
- @@ -83,7 +83,7 @@ - + - + diff --git a/src/addons/mod/forum/components/index/index.html b/src/addons/mod/forum/components/index/index.html index 63fcc9497..6e926f3a1 100644 --- a/src/addons/mod/forum/components/index/index.html +++ b/src/addons/mod/forum/components/index/index.html @@ -18,7 +18,7 @@ - diff --git a/src/addons/mod/forum/components/post/post.html b/src/addons/mod/forum/components/post/post.html index 3e3b2048f..df950ecdd 100644 --- a/src/addons/mod/forum/components/post/post.html +++ b/src/addons/mod/forum/components/post/post.html @@ -146,7 +146,7 @@ {{ 'core.cancel' | translate }} - + {{ 'core.savechanges' | translate }} {{ 'addon.mod_forum.posttoforum' | translate }} diff --git a/src/addons/mod/forum/pages/discussion/discussion.html b/src/addons/mod/forum/pages/discussion/discussion.html index 130547200..95385a60f 100644 --- a/src/addons/mod/forum/pages/discussion/discussion.html +++ b/src/addons/mod/forum/pages/discussion/discussion.html @@ -24,13 +24,13 @@ [content]="'core.settings.synchronizenow' | translate" [iconAction]="syncIcon" [closeOnClick]="false" (action)="doRefresh(null, $event, true)"> - - -
- + - + diff --git a/src/addons/mod/forum/pages/new-discussion/new-discussion.html b/src/addons/mod/forum/pages/new-discussion/new-discussion.html index 69721b8a6..ba0d4359d 100644 --- a/src/addons/mod/forum/pages/new-discussion/new-discussion.html +++ b/src/addons/mod/forum/pages/new-discussion/new-discussion.html @@ -84,7 +84,7 @@ {{ 'core.discard' | translate }} - {{ 'addon.mod_forum.posttoforum' | translate }} diff --git a/src/addons/mod/forum/pages/new-discussion/new-discussion.ts b/src/addons/mod/forum/pages/new-discussion/new-discussion.ts index 3c4921173..4f3c43b73 100644 --- a/src/addons/mod/forum/pages/new-discussion/new-discussion.ts +++ b/src/addons/mod/forum/pages/new-discussion/new-discussion.ts @@ -266,7 +266,6 @@ export class AddonModForumNewDiscussionPage implements OnInit, OnDestroy, CanLea CoreSync.blockOperation(AddonModForumProvider.COMPONENT, this.syncId); } - // eslint-disable-next-line promise/no-nesting return AddonModForumOffline.instance .getNewDiscussion(this.forumId, this.timeCreated) .then(async (discussion) => { diff --git a/src/addons/mod/quiz/components/navigation-modal/navigation-modal.html b/src/addons/mod/quiz/components/navigation-modal/navigation-modal.html index eb7fd9ead..43d093486 100644 --- a/src/addons/mod/quiz/components/navigation-modal/navigation-modal.html +++ b/src/addons/mod/quiz/components/navigation-modal/navigation-modal.html @@ -28,17 +28,17 @@ - - - -
diff --git a/src/addons/mod/resource/components/index/addon-mod-resource-index.html b/src/addons/mod/resource/components/index/addon-mod-resource-index.html index e0701e66d..a190f2522 100644 --- a/src/addons/mod/resource/components/index/addon-mod-resource-index.html +++ b/src/addons/mod/resource/components/index/addon-mod-resource-index.html @@ -24,15 +24,15 @@
- + -
+
- + @@ -84,7 +84,7 @@
-
+
diff --git a/src/addons/mod/resource/pages/index/index.html b/src/addons/mod/resource/pages/index/index.html index be5afe998..2509b760f 100644 --- a/src/addons/mod/resource/pages/index/index.html +++ b/src/addons/mod/resource/pages/index/index.html @@ -16,7 +16,7 @@ - diff --git a/src/addons/mod/workshop/components/index/addon-mod-workshop-index.html b/src/addons/mod/workshop/components/index/addon-mod-workshop-index.html index 07801751f..18e47a08a 100644 --- a/src/addons/mod/workshop/components/index/addon-mod-workshop-index.html +++ b/src/addons/mod/workshop/components/index/addon-mod-workshop-index.html @@ -22,13 +22,13 @@ - + - - {{task.title}}

-
diff --git a/src/addons/mod/workshop/components/phase/phase.html b/src/addons/mod/workshop/components/phase/phase.html index 5d4ffbf95..2635a752a 100644 --- a/src/addons/mod/workshop/components/phase/phase.html +++ b/src/addons/mod/workshop/components/phase/phase.html @@ -29,13 +29,13 @@ - - @@ -43,7 +43,7 @@

{{task.title}}

-
diff --git a/src/addons/mod/workshop/services/workshop-helper.ts b/src/addons/mod/workshop/services/workshop-helper.ts index 55eaa30b2..367148474 100644 --- a/src/addons/mod/workshop/services/workshop-helper.ts +++ b/src/addons/mod/workshop/services/workshop-helper.ts @@ -391,7 +391,7 @@ export class AddonModWorkshopHelperProvider { files: CoreFileEntry[], offline: false, siteId?: string, - ): Promise + ): Promise; uploadOrStoreAssessmentFiles( workshopId: number, assessmentId: number, diff --git a/src/addons/notes/pages/list/list.html b/src/addons/notes/pages/list/list.html index 33eb17108..89204e975 100644 --- a/src/addons/notes/pages/list/list.html +++ b/src/addons/notes/pages/list/list.html @@ -86,8 +86,8 @@ [attr.aria-label]="'core.restore' | translate">
- diff --git a/src/addons/notes/pages/list/list.ts b/src/addons/notes/pages/list/list.ts index 58bf0e68e..badf1372e 100644 --- a/src/addons/notes/pages/list/list.ts +++ b/src/addons/notes/pages/list/list.ts @@ -42,7 +42,7 @@ import { CoreTime } from '@singletons/time'; }) export class AddonNotesListPage implements OnInit, OnDestroy { - @ViewChild(IonContent) content?: IonContent; + @ViewChild(IonContent) content?: IonContent; courseId!: number; userId?: number; diff --git a/src/addons/privatefiles/pages/index/index.html b/src/addons/privatefiles/pages/index/index.html index 3ad05578f..8887aab00 100644 --- a/src/addons/privatefiles/pages/index/index.html +++ b/src/addons/privatefiles/pages/index/index.html @@ -51,7 +51,7 @@ - + {{ 'core.fileuploader.uploadafile' | translate }} diff --git a/src/addons/qtype/essay/component/addon-qtype-essay.html b/src/addons/qtype/essay/component/addon-qtype-essay.html index 26f95d1d9..4996c7b8b 100644 --- a/src/addons/qtype/essay/component/addon-qtype-essay.html +++ b/src/addons/qtype/essay/component/addon-qtype-essay.html @@ -67,7 +67,7 @@ - + diff --git a/src/core/components/combobox/core-combobox.html b/src/core/components/combobox/core-combobox.html index 6142c71c0..58a91cd47 100644 --- a/src/core/components/combobox/core-combobox.html +++ b/src/core/components/combobox/core-combobox.html @@ -1,16 +1,16 @@ - + - - {{ label }}: diff --git a/src/core/components/context-menu/core-context-menu-popover.html b/src/core/components/context-menu/core-context-menu-popover.html index 7ba6c7cd4..960de7d6b 100644 --- a/src/core/components/context-menu/core-context-menu-popover.html +++ b/src/core/components/context-menu/core-context-menu-popover.html @@ -13,12 +13,12 @@

- - + - diff --git a/src/core/components/infinite-loading/core-infinite-loading.html b/src/core/components/infinite-loading/core-infinite-loading.html index 8cb69a24d..32b06f708 100644 --- a/src/core/components/infinite-loading/core-infinite-loading.html +++ b/src/core/components/infinite-loading/core-infinite-loading.html @@ -1,4 +1,4 @@ - +
{{ 'core.loadmore' | translate }} @@ -13,7 +13,7 @@ - +
{{ 'core.loadmore' | translate }} diff --git a/src/core/components/input-errors/core-input-errors.html b/src/core/components/input-errors/core-input-errors.html index 6c1448d3b..9bee393c3 100644 --- a/src/core/components/input-errors/core-input-errors.html +++ b/src/core/components/input-errors/core-input-errors.html @@ -3,10 +3,10 @@
{{errorMessages[error]}} - + {{ 'core.login.invalidvaluemax' | translate:{$a: control.errors!.max.max} }} - + {{ 'core.login.invalidvaluemin' | translate:{$a: control.errors!.min.min} }}
diff --git a/src/core/components/tabs/core-tabs.html b/src/core/components/tabs/core-tabs.html index 9ea65bded..301f51521 100644 --- a/src/core/components/tabs/core-tabs.html +++ b/src/core/components/tabs/core-tabs.html @@ -7,11 +7,11 @@
- + [attr.aria-selected]="selected === tab.id" [tabindex]="selected === tab.id ? 0 : -1">

{{ tab.title | translate}}

diff --git a/src/core/features/course/components/module-summary/module-summary.html b/src/core/features/course/components/module-summary/module-summary.html index c318637b8..aadf0701f 100644 --- a/src/core/features/course/components/module-summary/module-summary.html +++ b/src/core/features/course/components/module-summary/module-summary.html @@ -80,8 +80,8 @@

{{ 'core.grades.grade' | translate }}

-

- +

+ {{ 'core.grades.notgraded' | translate }}
@@ -92,48 +92,48 @@
- +

{{ 'core.grades.weight' | translate}}

- +

{{ 'core.grades.range' | translate}}

- +

{{ 'core.grades.percentage' | translate}}

- +

{{ 'core.grades.lettergrade' | translate}}

- +

{{ 'core.grades.rank' | translate}}

- +

{{ 'core.grades.average' | translate}}

- +

{{ 'core.grades.feedback' | translate}}

@@ -145,7 +145,7 @@ + *ngIf="grade.contributiontocoursetotal?.length > 0 && grade.contributiontocoursetotal !== '-'">

{{ 'core.grades.contributiontocoursetotal' | translate}}

diff --git a/src/core/features/course/pages/course-summary/course-summary.html b/src/core/features/course/pages/course-summary/course-summary.html index b491d89a5..e7d2179b3 100644 --- a/src/core/features/course/pages/course-summary/course-summary.html +++ b/src/core/features/course/pages/course-summary/course-summary.html @@ -116,7 +116,7 @@ : - diff --git a/src/core/features/courses/components/course-list-item/core-courses-course-list-item.html b/src/core/features/courses/components/course-list-item/core-courses-course-list-item.html index 6838978d8..7f6f0fc00 100644 --- a/src/core/features/courses/components/course-list-item/core-courses-course-list-item.html +++ b/src/core/features/courses/components/course-list-item/core-courses-course-list-item.html @@ -1,14 +1,14 @@ - -
+
- +
- + @@ -55,7 +55,7 @@ - + @@ -82,7 +82,7 @@
-
diff --git a/src/core/features/courses/components/course-options-menu/core-courses-course-options-menu.html b/src/core/features/courses/components/course-options-menu/core-courses-course-options-menu.html index 17633d581..06589ca7b 100644 --- a/src/core/features/courses/components/course-options-menu/core-courses-course-options-menu.html +++ b/src/core/features/courses/components/course-options-menu/core-courses-course-options-menu.html @@ -8,7 +8,7 @@ + *ngIf="prefetch.status === 'downloaded' || prefetch.status === 'outdated'">

{{ 'addon.storagemanager.deletedata' | translate }}

diff --git a/src/core/features/grades/pages/course/course.html b/src/core/features/grades/pages/course/course.html index a5c6dc447..c45814538 100644 --- a/src/core/features/grades/pages/course/course.html +++ b/src/core/features/grades/pages/course/course.html @@ -37,7 +37,7 @@ [class.core-grades-grade-clickable]="row.expandable && showSummary" [id]="'grade-'+row.id" *ngIf="row.itemtype !== 'leader'"> - +
- + {{ 'core.grades.grade' | translate }} {{course.grade}} diff --git a/src/core/features/login/pages/site/site.html b/src/core/features/login/pages/site/site.html index d4dd1aae5..e6e1fb8cc 100644 --- a/src/core/features/login/pages/site/site.html +++ b/src/core/features/login/pages/site/site.html @@ -22,7 +22,7 @@
- +

{{ 'core.login.siteaddress' | translate }}

@@ -32,7 +32,7 @@
- +

{{ 'core.login.siteaddress' | translate }}

@@ -74,7 +74,7 @@
- + {{ 'core.login.connect' | translate }} @@ -85,7 +85,7 @@ - +

{{ 'core.login.selectsite' | translate }}

diff --git a/src/core/features/mainmenu/pages/menu/menu.html b/src/core/features/mainmenu/pages/menu/menu.html index 2cc91b881..f17ec2c5e 100644 --- a/src/core/features/mainmenu/pages/menu/menu.html +++ b/src/core/features/mainmenu/pages/menu/menu.html @@ -1,9 +1,9 @@ + [class.tabshidden]="!isMainScreen && tabsPlacement === 'bottom'" (ionTabsDidChange)="tabChanged($event)"> - +
- +

{{item.label}}

- diff --git a/src/core/features/search/components/search-box/core-search-box.html b/src/core/features/search/components/search-box/core-search-box.html index 3dce170b6..57a4eaac3 100644 --- a/src/core/features/search/components/search-box/core-search-box.html +++ b/src/core/features/search/components/search-box/core-search-box.html @@ -9,7 +9,7 @@
+ [disabled]="searched === '' || disabled" (click)="clearForm()">
diff --git a/src/core/features/settings/pages/general/general.html b/src/core/features/settings/pages/general/general.html index 57fe64eee..90843dac5 100644 --- a/src/core/features/settings/pages/general/general.html +++ b/src/core/features/settings/pages/general/general.html @@ -47,7 +47,7 @@ {{ 'core.settings.colorscheme-' + scheme | translate }}
- +

{{ 'core.settings.colorscheme-system-notice' | translate }}

diff --git a/src/core/features/tag/pages/index/index.html b/src/core/features/tag/pages/index/index.html index 5afa6ae04..e3963735c 100644 --- a/src/core/features/tag/pages/index/index.html +++ b/src/core/features/tag/pages/index/index.html @@ -21,7 +21,7 @@ {{ 'core.tag.warningareasnotsupported' | translate }}
+ (click)="openArea(area)" [attr.aria-current]="area.id === selectedAreaId ? 'page' : 'false'" button detail="true">

{{ area.nameKey | translate }}

diff --git a/src/core/features/user/classes/support/support-config.ts b/src/core/features/user/classes/support/support-config.ts index fd15ddf12..1cd345738 100644 --- a/src/core/features/user/classes/support/support-config.ts +++ b/src/core/features/user/classes/support/support-config.ts @@ -22,14 +22,14 @@ export abstract class CoreUserSupportConfig { * * @returns Whether the user can contact support. */ - public abstract canContactSupport(): boolean; + abstract canContactSupport(): boolean; /** * Get language used in the support page, if any. * * @returns Support page language. */ - public abstract getSupportPageLang(): string | null; + abstract getSupportPageLang(): string | null; /** * Get url to use for contacting support. From 1639e60ebe65f2d5836f149904ccda4fc625b743 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pau=20Ferrer=20Oca=C3=B1a?= Date: Mon, 13 Nov 2023 13:12:29 +0100 Subject: [PATCH 06/17] MOBILE-3947 dx: Update some config to align to Ionic7 --- .editorconfig | 19 ++++++++++++ .gitignore | 66 ++++++++++++++++++++++++++++++++--------- .vscode/extensions.json | 1 + tsconfig.json | 28 +++++++++-------- 4 files changed, 88 insertions(+), 26 deletions(-) create mode 100644 .editorconfig diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 000000000..6c0301949 --- /dev/null +++ b/.editorconfig @@ -0,0 +1,19 @@ +# Editor configuration, see https://editorconfig.org +root = true + +[*] +charset = utf-8 +indent_style = space +indent_size = 4 +insert_final_newline = true +trim_trailing_whitespace = true + +[*.json] +indent_size = 2 + +[*.ts] +quote_type = single + +[*.md] +max_line_length = off +trim_trailing_whitespace = false diff --git a/.gitignore b/.gitignore index d3b41f8be..4d221f5fa 100644 --- a/.gitignore +++ b/.gitignore @@ -6,32 +6,70 @@ .tmp *.tmp *.tmp.* -*.sublime-project -*.sublime-workspace -.DS_Store -Thumbs.db UserInterfaceState.xcuserstate $RECYCLE.BIN/ *.log log.txt -npm-debug.log* -/.idea -/.ionic -/.sass-cache /.sourcemaps /.versions /coverage -/dist -/node_modules + +# Ionic +/.ionic +/www /platforms /plugins -/www + +# Compiled output +/dist +/tmp +/out-tsc +/bazel-out + +# Node +/node_modules +npm-debug.log +yarn-error.log + +# IDEs and editors +.idea/ +.project +.classpath +.c9/ +*.launch +.settings/ +*.sublime-project +*.sublime-workspace + +# Visual Studio Code +.vscode/* +!.vscode/settings.json +!.vscode/tasks.json +!.vscode/launch.json +!.vscode/extensions.json +.history/* + + +# Miscellaneous +/.angular +/.angular/cache +.sass-cache/ +/connect.lock +/coverage +/libpeerconnection.log +testem.log +/typings + +# System files +.DS_Store +Thumbs.db + +# Moodle App /src/assets/lib +/src/assets/lang/* +/src/assets/env.json /moodle.config.*.json !/moodle.config.example.json - -/src/assets/lang/* -/src/assets/env.json diff --git a/.vscode/extensions.json b/.vscode/extensions.json index 71bb27499..2442fe5ac 100644 --- a/.vscode/extensions.json +++ b/.vscode/extensions.json @@ -1,5 +1,6 @@ { "recommendations": [ + "ionic.ionic", "dbaeumer.vscode-eslint", "angular.ng-template" ] diff --git a/tsconfig.json b/tsconfig.json index 013b67b32..7b7f668e0 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -9,6 +9,8 @@ "experimentalDecorators": true, "strictNullChecks": true, "strictPropertyInitialization": true, + "forceConsistentCasingInFileNames": true, + "useDefineForClassFields": false, "module": "esnext", "moduleResolution": "node", "importHelpers": true, @@ -32,21 +34,23 @@ "webpack-env" ], "paths": { - "@addons/*": ["addons/*"], - "@classes/*": ["core/classes/*"], - "@components/*": ["core/components/*"], - "@directives/*": ["core/directives/*"], - "@features/*": ["core/features/*"], - "@guards/*": ["core/guards/*"], - "@pipes/*": ["core/pipes/*"], - "@services/*": ["core/services/*"], - "@singletons": ["core/singletons/index"], - "@singletons/*": ["core/singletons/*"], - "@/*": ["*"] + "@addons/*": ["./addons/*"], + "@classes/*": ["./core/classes/*"], + "@components/*": ["./core/components/*"], + "@directives/*": ["./core/directives/*"], + "@features/*": ["./core/features/*"], + "@guards/*": ["./core/guards/*"], + "@pipes/*": ["./core/pipes/*"], + "@services/*": ["./core/services/*"], + "@singletons": ["./core/singletons/index"], + "@singletons/*": ["./core/singletons/*"], + "@/*": ["./*"] } }, "angularCompilerOptions": { "fullTemplateTypeCheck": true, - "strictInjectionParameters": true + "enableI18nLegacyMessageIdFormat": false, + "strictInjectionParameters": true, + "strictInputAccessModifiers": true } } From 9e9052db85e9db376a63184e4ebe5c7ae0dc168f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pau=20Ferrer=20Oca=C3=B1a?= Date: Thu, 9 Nov 2023 16:28:49 +0100 Subject: [PATCH 07/17] MOBILE-3947 chore: Fix some non valid types --- src/addons/block/timeline/classes/section.ts | 2 +- .../timeline/components/timeline/timeline.ts | 2 +- .../enrol/guest/services/enrol-handler.ts | 2 +- .../services/handlers/mathjaxloader.ts | 4 ++-- .../mod/assign/services/assign-offline.ts | 5 +++-- .../mod/assign/services/handlers/prefetch.ts | 2 +- .../mod/choice/components/index/index.ts | 2 +- src/addons/mod/feedback/services/feedback.ts | 4 ++-- .../workshop/pages/submission/submission.ts | 2 +- src/core/classes/database/database-table.ts | 4 ++-- src/core/components/split-view/split-view.ts | 2 +- src/core/directives/format-text.ts | 12 +++++++----- .../comments/services/comments-offline.ts | 7 ++++--- .../audio-recorder.component.ts | 2 +- .../components/report-detail/report-detail.ts | 19 ++++++++++--------- .../features/reportbuilder/pages/list/list.ts | 2 +- src/core/pipes/seconds-to-hms.ts | 6 +++--- src/core/services/utils/dom.ts | 2 +- src/core/services/utils/text.ts | 2 +- 19 files changed, 44 insertions(+), 39 deletions(-) diff --git a/src/addons/block/timeline/classes/section.ts b/src/addons/block/timeline/classes/section.ts index ae82df5a0..08a5f1104 100644 --- a/src/addons/block/timeline/classes/section.ts +++ b/src/addons/block/timeline/classes/section.ts @@ -44,7 +44,7 @@ export class AddonBlockTimelineSection { this.overdue = overdue; this.dateRange = dateRange; this.course = course; - this.dataSubject$ = new BehaviorSubject({ + this.dataSubject$ = new BehaviorSubject({ events: [], lastEventId: canLoadMore, canLoadMore: typeof canLoadMore !== 'undefined', diff --git a/src/addons/block/timeline/components/timeline/timeline.ts b/src/addons/block/timeline/components/timeline/timeline.ts index b9ee654cc..e61a52f5c 100644 --- a/src/addons/block/timeline/components/timeline/timeline.ts +++ b/src/addons/block/timeline/components/timeline/timeline.ts @@ -56,7 +56,7 @@ export class AddonBlockTimelineComponent implements OnInit, ICoreBlockComponent constructor() { this.logger = CoreLogger.getInstance('AddonBlockTimelineComponent'); - this.search$ = new BehaviorSubject(null); + this.search$ = new BehaviorSubject(null); this.initializeSort(); this.initializeFilter(); this.initializeSections(); diff --git a/src/addons/enrol/guest/services/enrol-handler.ts b/src/addons/enrol/guest/services/enrol-handler.ts index 0a0b174c4..00c2a1313 100644 --- a/src/addons/enrol/guest/services/enrol-handler.ts +++ b/src/addons/enrol/guest/services/enrol-handler.ts @@ -98,7 +98,7 @@ export class AddonEnrolGuestHandlerService implements CoreEnrolGuestHandler { return false; } - const validatePassword = async (password: string): Promise => { + const validatePassword = async (password = ''): Promise => { const modal = await CoreDomUtils.showModalLoading('core.loading', true); try { diff --git a/src/addons/filter/mathjaxloader/services/handlers/mathjaxloader.ts b/src/addons/filter/mathjaxloader/services/handlers/mathjaxloader.ts index aca1a8916..5d40042a9 100644 --- a/src/addons/filter/mathjaxloader/services/handlers/mathjaxloader.ts +++ b/src/addons/filter/mathjaxloader/services/handlers/mathjaxloader.ts @@ -407,8 +407,8 @@ type MathJaxWindow = Window & { MathJax?: any; // eslint-disable-line @typescript-eslint/naming-convention, @typescript-eslint/no-explicit-any M?: { // eslint-disable-line @typescript-eslint/naming-convention filter_mathjaxloader?: { // eslint-disable-line @typescript-eslint/naming-convention - _lang: ''; // eslint-disable-line @typescript-eslint/naming-convention - _configured: false; // eslint-disable-line @typescript-eslint/naming-convention + _lang: string; // eslint-disable-line @typescript-eslint/naming-convention + _configured: boolean; // eslint-disable-line @typescript-eslint/naming-convention // Add the configuration to the head and set the lang. configure: (params: Record) => void; _setLocale: () => void; // eslint-disable-line @typescript-eslint/naming-convention diff --git a/src/addons/mod/assign/services/assign-offline.ts b/src/addons/mod/assign/services/assign-offline.ts index e275a489b..cf8d095f0 100644 --- a/src/addons/mod/assign/services/assign-offline.ts +++ b/src/addons/mod/assign/services/assign-offline.ts @@ -28,6 +28,7 @@ import { SUBMISSIONS_GRADES_TABLE, SUBMISSIONS_TABLE, } from './database/assign'; +import { CoreArray } from '@singletons/array'; /** * Service to handle offline assign. @@ -86,8 +87,8 @@ export class AddonModAssignOfflineProvider { const results = await Promise.all(promises); // Flatten array. - const flatten: (AddonModAssignSubmissionsDBRecord | AddonModAssignSubmissionsGradingDBRecord)[] = - [].concat.apply([], results); + const flatten = CoreArray + .flatten(results); // Get assign id. let assignIds: number[] = flatten.map((assign) => assign.assignid); diff --git a/src/addons/mod/assign/services/handlers/prefetch.ts b/src/addons/mod/assign/services/handlers/prefetch.ts index 0cb4fc2f4..b90c16a28 100644 --- a/src/addons/mod/assign/services/handlers/prefetch.ts +++ b/src/addons/mod/assign/services/handlers/prefetch.ts @@ -166,7 +166,7 @@ export class AddonModAssignPrefetchHandlerService extends CoreCourseActivityPref // Get intro and activity files from the submission status if it's a student. // It's ok if they were already obtained from the assignment instance, they won't be downloaded twice. - const files = canViewAllSubmissions ? + const files: CoreWSFile[] = canViewAllSubmissions ? [] : (submissionStatus.assignmentdata?.attachments?.intro || []) .concat(submissionStatus.assignmentdata?.attachments?.activity || []); diff --git a/src/addons/mod/choice/components/index/index.ts b/src/addons/mod/choice/components/index/index.ts index e119299fa..720cf2b88 100644 --- a/src/addons/mod/choice/components/index/index.ts +++ b/src/addons/mod/choice/components/index/index.ts @@ -301,7 +301,7 @@ export class AddonModChoiceIndexComponent extends CoreCourseModuleMainActivityCo this.data = []; this.labels = []; - this.results = results.map((result: AddonModChoiceResultFormatted) => { + this.results = results.map((result) => { if (result.numberofuser > 0) { hasVotes = true; } diff --git a/src/addons/mod/feedback/services/feedback.ts b/src/addons/mod/feedback/services/feedback.ts index 3eb4e1375..f44148a97 100644 --- a/src/addons/mod/feedback/services/feedback.ts +++ b/src/addons/mod/feedback/services/feedback.ts @@ -194,9 +194,9 @@ export class AddonModFeedbackProvider { } // Treat multichoice checkboxes. - if (item.typ == 'multichoice' && item.presentation.split(AddonModFeedbackProvider.MULTICHOICE_TYPE_SEP)[0] == 'c') { + if (item.typ === 'multichoice' && item.presentation.split(AddonModFeedbackProvider.MULTICHOICE_TYPE_SEP)[0] === 'c') { - offlineValues[item.id] = offlineValues[item.id].filter((value) => value > 0); + offlineValues[item.id] = offlineValues[item.id].filter((value) => Number(value) > 0); item.rawValue = offlineValues[item.id].join(AddonModFeedbackProvider.LINE_SEP); } else { item.rawValue = offlineValues[item.id][0]; diff --git a/src/addons/mod/workshop/pages/submission/submission.ts b/src/addons/mod/workshop/pages/submission/submission.ts index bfb7c87b9..81db1a141 100644 --- a/src/addons/mod/workshop/pages/submission/submission.ts +++ b/src/addons/mod/workshop/pages/submission/submission.ts @@ -513,7 +513,7 @@ export class AddonModWorkshopSubmissionPage implements OnInit, OnDestroy, CanLea published: boolean; } = this.feedbackForm.value; - inputData.grade = inputData.grade >= 0 ? inputData.grade : ''; + inputData.grade = Number(inputData.grade) >= 0 ? inputData.grade : ''; // Add some HTML to the message if needed. inputData.text = CoreTextUtils.formatHtmlLines(inputData.text); diff --git a/src/core/classes/database/database-table.ts b/src/core/classes/database/database-table.ts index 20fbf8a86..629e95ed7 100644 --- a/src/core/classes/database/database-table.ts +++ b/src/core/classes/database/database-table.ts @@ -348,8 +348,8 @@ export class CoreDatabaseTable< records.sort((a, b) => { for (const [column, direction] of columnsSorting) { - const aValue = a[column]; - const bValue = b[column]; + const aValue = a[column] ?? 0; + const bValue = b[column] ?? 0; if (aValue > bValue) { return direction === 'desc' ? -1 : 1; diff --git a/src/core/components/split-view/split-view.ts b/src/core/components/split-view/split-view.ts index f053a7048..fa23064be 100644 --- a/src/core/components/split-view/split-view.ts +++ b/src/core/components/split-view/split-view.ts @@ -40,7 +40,7 @@ export class CoreSplitViewComponent implements AfterViewInit, OnDestroy { isNested = false; disabledScrollOuterContents: HTMLIonContentElement[] = []; - private outletRouteSubject: BehaviorSubject = new BehaviorSubject(null); + private outletRouteSubject = new BehaviorSubject(null); private subscriptions?: Subscription[]; constructor(private element: ElementRef) {} diff --git a/src/core/directives/format-text.ts b/src/core/directives/format-text.ts index 7c25767cf..2046dbc94 100644 --- a/src/core/directives/format-text.ts +++ b/src/core/directives/format-text.ts @@ -464,11 +464,13 @@ export class CoreFormatTextDirective implements OnChanges, OnDestroy, AsyncDirec const audios = Array.from(div.querySelectorAll('audio')); const videos = Array.from(div.querySelectorAll('video')); const iframes = Array.from(div.querySelectorAll('iframe')); - const buttons = Array.from(div.querySelectorAll('.button')); + const buttons = Array.from(div.querySelectorAll('.button')); const icons = Array.from(div.querySelectorAll('i.fa,i.fas,i.far,i.fab')); - const elementsWithInlineStyles = Array.from(div.querySelectorAll('*[style]')); - const stopClicksElements = Array.from(div.querySelectorAll('button,input,select,textarea')); - const frames = Array.from(div.querySelectorAll(CoreIframeUtilsProvider.FRAME_TAGS.join(',').replace(/iframe,?/, ''))); + const elementsWithInlineStyles = Array.from(div.querySelectorAll('*[style]')); + const stopClicksElements = Array.from(div.querySelectorAll('button,input,select,textarea')); + const frames = Array.from( + div.querySelectorAll(CoreIframeUtilsProvider.FRAME_TAGS.join(',').replace(/iframe,?/, '')), + ); const svgImages = Array.from(div.querySelectorAll('image')); const promises: Promise[] = []; @@ -560,7 +562,7 @@ export class CoreFormatTextDirective implements OnChanges, OnDestroy, AsyncDirec }); // Handle all kind of frames. - const frameControllers = frames.map((frame: FrameElement) => { + const frameControllers = frames.map((frame) => { CoreIframeUtils.treatFrame(frame, false); return new FrameElementController(frame, !this.disabled); diff --git a/src/core/features/comments/services/comments-offline.ts b/src/core/features/comments/services/comments-offline.ts index 997b5f72a..766c72b3e 100644 --- a/src/core/features/comments/services/comments-offline.ts +++ b/src/core/features/comments/services/comments-offline.ts @@ -17,6 +17,7 @@ import { CoreSites } from '@services/sites'; import { CoreTimeUtils } from '@services/utils/time'; import { makeSingleton } from '@singletons'; import { COMMENTS_TABLE, COMMENTS_DELETED_TABLE, CoreCommentsDBRecord, CoreCommentsDeletedDBRecord } from './database/comments'; +import { CoreArray } from '@singletons/array'; /** * Service to handle offline comments. @@ -33,11 +34,11 @@ export class CoreCommentsOfflineProvider { async getAllComments(siteId?: string): Promise<(CoreCommentsDBRecord | CoreCommentsDeletedDBRecord)[]> { const site = await CoreSites.getSite(siteId); const results = await Promise.all([ - site.getDb().getRecords(COMMENTS_TABLE), - site.getDb().getRecords(COMMENTS_DELETED_TABLE), + site.getDb().getRecords(COMMENTS_TABLE), + site.getDb().getRecords(COMMENTS_DELETED_TABLE), ]); - return [].concat.apply([], results); + return CoreArray.flatten(results); } /** diff --git a/src/core/features/fileuploader/components/audio-recorder/audio-recorder.component.ts b/src/core/features/fileuploader/components/audio-recorder/audio-recorder.component.ts index 85d01340c..f6285e211 100644 --- a/src/core/features/fileuploader/components/audio-recorder/audio-recorder.component.ts +++ b/src/core/features/fileuploader/components/audio-recorder/audio-recorder.component.ts @@ -48,7 +48,7 @@ export class CoreFileUploaderAudioRecorderComponent extends CoreModalComponent(null); this.recording$ = this.media$.pipe( recorderAudioRecording(), shareReplay(), diff --git a/src/core/features/reportbuilder/components/report-detail/report-detail.ts b/src/core/features/reportbuilder/components/report-detail/report-detail.ts index 9a445b942..0e48d1701 100644 --- a/src/core/features/reportbuilder/components/report-detail/report-detail.ts +++ b/src/core/features/reportbuilder/components/report-detail/report-detail.ts @@ -51,15 +51,16 @@ export class CoreReportBuilderReportDetailComponent implements OnInit { return this.layout === 'card' || (CoreScreen.isMobile && this.layout === 'adaptative'); } - state$: Readonly> = new BehaviorSubject({ - report: null, - loaded: false, - canLoadMoreRows: true, - errorLoadingRows: false, - cardviewShowFirstTitle: false, - cardVisibleColumns: 1, - page: 0, - }); + state$: Readonly> = + new BehaviorSubject({ + report: null, + loaded: false, + canLoadMoreRows: true, + errorLoadingRows: false, + cardviewShowFirstTitle: false, + cardVisibleColumns: 1, + page: 0, + }); source$: Observable; diff --git a/src/core/features/reportbuilder/pages/list/list.ts b/src/core/features/reportbuilder/pages/list/list.ts index b57ce261f..d67c23af3 100644 --- a/src/core/features/reportbuilder/pages/list/list.ts +++ b/src/core/features/reportbuilder/pages/list/list.ts @@ -35,7 +35,7 @@ export class CoreReportBuilderListPage implements AfterViewInit, OnDestroy { reports!: CoreListItemsManager; - state$: Readonly> = new BehaviorSubject({ + state$: Readonly> = new BehaviorSubject({ page: 1, perpage: REPORTS_LIST_LIMIT, loaded: false, diff --git a/src/core/pipes/seconds-to-hms.ts b/src/core/pipes/seconds-to-hms.ts index 4a14d02b1..9afc7c7ac 100644 --- a/src/core/pipes/seconds-to-hms.ts +++ b/src/core/pipes/seconds-to-hms.ts @@ -41,9 +41,7 @@ export class CoreSecondsToHMSPipe implements PipeTransform { * @returns Formatted seconds. */ transform(seconds: string | number, showHours: boolean = true): string { - if (!seconds || seconds < 0) { - seconds = 0; - } else if (typeof seconds == 'string') { + if (typeof seconds === 'string') { // Convert the value to a number. const numberSeconds = parseInt(seconds, 10); if (isNaN(numberSeconds)) { @@ -52,6 +50,8 @@ export class CoreSecondsToHMSPipe implements PipeTransform { return seconds; } seconds = numberSeconds; + } else if (!seconds || seconds < 0) { + seconds = 0; } // Don't allow decimals. diff --git a/src/core/services/utils/dom.ts b/src/core/services/utils/dom.ts index 6a5e06a33..feae6ef72 100644 --- a/src/core/services/utils/dom.ts +++ b/src/core/services/utils/dom.ts @@ -687,7 +687,7 @@ export class CoreDomUtilsProvider { const element = this.convertToElement(html); // Treat elements with src (img, audio, video, ...). - const media = Array.from(element.querySelectorAll('img, video, audio, source, track')); + const media = Array.from(element.querySelectorAll('img, video, audio, source, track')); media.forEach((media: HTMLElement) => { const currentSrc = media.getAttribute('src'); const newSrc = currentSrc ? diff --git a/src/core/services/utils/text.ts b/src/core/services/utils/text.ts index 35bbb1571..dd7d148ef 100644 --- a/src/core/services/utils/text.ts +++ b/src/core/services/utils/text.ts @@ -982,7 +982,7 @@ export class CoreTextUtilsProvider { * @returns Number with leading zeros. */ twoDigits(num: string | number): string { - if (num < 10) { + if (Number(num) < 10) { return '0' + num; } else { return '' + num; // Convert to string for coherence. From e40a4f13bb56581ab023512f6a6e80d8b09ec956 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pau=20Ferrer=20Oca=C3=B1a?= Date: Mon, 13 Nov 2023 10:05:19 +0100 Subject: [PATCH 08/17] MOBILE-3947 chore: Fix some HTML strict types --- .../badges/pages/user-badges/user-badges.html | 2 +- .../addon-block-activitymodules.html | 4 ++-- .../myoverview/addon-block-myoverview.html | 2 +- .../addon-block-recentlyaccessedcourses.html | 2 +- .../addon-block-recentlyaccesseditems.html | 4 ++-- .../sitemainmenu/addon-block-sitemainmenu.html | 2 +- .../addon-block-starredcourses.html | 2 +- .../events/addon-block-timeline-events.html | 2 +- .../timeline/addon-block-timeline.html | 2 +- src/addons/blog/pages/entries/entries.html | 2 +- src/addons/calendar/pages/event/event.html | 2 +- .../pages/competencies/competencies.html | 2 +- .../coursecompetencies/coursecompetencies.html | 2 +- src/addons/competency/pages/plan/plan.html | 2 +- .../competency/pages/planlist/planlist.html | 2 +- .../conversation-info/conversation-info.html | 2 +- .../messages/pages/contacts-35/contacts.html | 2 +- src/addons/messages/pages/contacts/contacts.html | 4 ++-- .../pages/discussions-35/discussions.html | 6 +++--- .../group-conversations/group-conversations.html | 16 ++++++++-------- src/addons/messages/pages/search/search.html | 2 +- .../components/index/addon-mod-assign-index.html | 3 ++- .../submission/addon-mod-assign-submission.html | 2 +- .../pages/submission-list/submission-list.html | 2 +- .../addon-mod-assign-submission-comments.html | 2 +- .../addon-mod-assign-submission-file.html | 2 +- .../addon-mod-assign-submission-onlinetext.html | 2 +- .../bigbluebuttonbn/components/index/index.html | 4 ++-- .../components/index/addon-mod-book-index.html | 2 +- src/addons/mod/book/components/toc/toc.html | 2 +- .../components/index/addon-mod-choice-index.html | 2 +- .../data/components/actionsmenu/actionsmenu.html | 2 +- .../components/index/addon-mod-data-index.html | 4 ++-- .../index/addon-mod-feedback-index.html | 2 +- .../mod/feedback/pages/attempts/attempts.html | 4 ++-- .../components/index/addon-mod-folder-index.html | 2 +- .../discussion-options-menu.html | 12 ++++++------ src/addons/mod/forum/components/index/index.html | 2 +- .../post-options-menu/post-options-menu.html | 6 +++--- src/addons/mod/forum/components/post/post.html | 2 +- .../sort-order-selector/sort-order-selector.html | 2 +- .../pages/new-discussion/new-discussion.html | 2 +- .../index/addon-mod-glossary-index.html | 4 ++-- .../pages/user-attempts/user-attempts.html | 6 +++--- .../pages/users-attempts/users-attempts.html | 4 ++-- .../components/index/addon-mod-imscp-index.html | 2 +- src/addons/mod/imscp/components/toc/toc.html | 2 +- .../components/index/addon-mod-lesson-index.html | 2 +- .../lesson/components/menu-modal/menu-modal.html | 2 +- src/addons/mod/lesson/pages/player/player.html | 2 +- .../components/index/addon-mod-quiz-index.html | 2 +- .../navigation-modal/navigation-modal.html | 2 +- .../components/index/addon-mod-scorm-index.html | 2 +- src/addons/mod/wiki/components/map/map.html | 4 ++-- .../addon-mod-wiki-subwiki-picker.html | 2 +- .../index/addon-mod-workshop-index.html | 4 ++-- .../mod/workshop/components/phase/phase.html | 4 ++-- src/addons/privatefiles/pages/index/index.html | 3 ++- .../pages/course-storage/course-storage.html | 2 +- .../pages/courses-storage/courses-storage.html | 2 +- src/core/components/context-menu/context-menu.ts | 3 +-- .../context-menu/core-context-menu-popover.html | 2 +- src/core/components/file/core-file.html | 2 +- .../components/local-file/core-local-file.html | 2 +- .../components/tabs-outlet/core-tabs-outlet.html | 2 +- src/core/components/tabs/tab.ts | 2 +- .../only-title-block/core-block-only-title.html | 2 +- .../core-block-pre-rendered.html | 2 +- .../choose-site-modal/choose-site-modal.html | 2 +- .../components/course-index/course-index.html | 4 ++-- .../module-summary/module-summary.html | 2 +- .../components/module/core-course-module.html | 2 +- .../tag-area/core-course-tag-area.html | 2 +- .../pages/course-summary/course-summary.html | 6 +++--- .../core-courses-course-options-menu.html | 12 ++++++------ .../courses/pages/categories/categories.html | 2 +- .../features/grades/pages/courses/courses.html | 2 +- .../login/components/site-help/site-help.html | 4 ++-- src/core/features/login/pages/site/site.html | 4 ++-- .../mainmenu/components/user-menu/user-menu.html | 13 +++++++------ src/core/features/mainmenu/pages/more/more.html | 10 +++++----- .../set-reminder-menu/set-reminder-menu.html | 6 +++--- .../components/search-box/core-search-box.html | 2 +- .../features/settings/pages/about/about.html | 12 ++++++------ .../settings/pages/deviceinfo/deviceinfo.html | 2 +- .../features/settings/pages/index/index.html | 4 ++-- .../settings/pages/licenses/licenses.html | 2 +- .../sharedfiles/components/list/list.html | 2 +- .../core-siteplugins-only-title-block.html | 2 +- src/core/features/tag/pages/index/index.html | 2 +- .../user/pages/participants/participants.html | 2 +- .../features/user/pages/profile/profile.html | 4 ++-- 92 files changed, 152 insertions(+), 150 deletions(-) diff --git a/src/addons/badges/pages/user-badges/user-badges.html b/src/addons/badges/pages/user-badges/user-badges.html index 8b872cbea..d91a5e0e8 100644 --- a/src/addons/badges/pages/user-badges/user-badges.html +++ b/src/addons/badges/pages/user-badges/user-badges.html @@ -19,7 +19,7 @@ + (click)="badges.select(badge)" [attr.aria-current]="badges.getItemAriaCurrent(badge)" [detail]="true"> diff --git a/src/addons/block/activitymodules/components/activitymodules/addon-block-activitymodules.html b/src/addons/block/activitymodules/components/activitymodules/addon-block-activitymodules.html index b4f800003..98aebcd59 100644 --- a/src/addons/block/activitymodules/components/activitymodules/addon-block-activitymodules.html +++ b/src/addons/block/activitymodules/components/activitymodules/addon-block-activitymodules.html @@ -1,10 +1,10 @@ - +

{{ 'addon.block_activitymodules.pluginname' | translate }}

- + {{ entry.name }} diff --git a/src/addons/block/myoverview/components/myoverview/addon-block-myoverview.html b/src/addons/block/myoverview/components/myoverview/addon-block-myoverview.html index 90adc25e6..176c08c90 100644 --- a/src/addons/block/myoverview/components/myoverview/addon-block-myoverview.html +++ b/src/addons/block/myoverview/components/myoverview/addon-block-myoverview.html @@ -1,4 +1,4 @@ - +

{{ 'addon.block_myoverview.pluginname' | translate }}

diff --git a/src/addons/block/recentlyaccessedcourses/components/recentlyaccessedcourses/addon-block-recentlyaccessedcourses.html b/src/addons/block/recentlyaccessedcourses/components/recentlyaccessedcourses/addon-block-recentlyaccessedcourses.html index d4b28ea36..66e1245d7 100644 --- a/src/addons/block/recentlyaccessedcourses/components/recentlyaccessedcourses/addon-block-recentlyaccessedcourses.html +++ b/src/addons/block/recentlyaccessedcourses/components/recentlyaccessedcourses/addon-block-recentlyaccessedcourses.html @@ -1,4 +1,4 @@ - +

{{ 'addon.block_recentlyaccessedcourses.pluginname' | translate }}

diff --git a/src/addons/block/recentlyaccesseditems/components/recentlyaccesseditems/addon-block-recentlyaccesseditems.html b/src/addons/block/recentlyaccesseditems/components/recentlyaccesseditems/addon-block-recentlyaccesseditems.html index 2b185a878..9d157d6d1 100644 --- a/src/addons/block/recentlyaccesseditems/components/recentlyaccesseditems/addon-block-recentlyaccesseditems.html +++ b/src/addons/block/recentlyaccesseditems/components/recentlyaccesseditems/addon-block-recentlyaccesseditems.html @@ -1,4 +1,4 @@ - +

{{ 'addon.block_recentlyaccesseditems.pluginname' | translate }}

@@ -14,7 +14,7 @@
- + diff --git a/src/addons/block/sitemainmenu/components/sitemainmenu/addon-block-sitemainmenu.html b/src/addons/block/sitemainmenu/components/sitemainmenu/addon-block-sitemainmenu.html index 11bc7d2b8..4b6d5b6ba 100644 --- a/src/addons/block/sitemainmenu/components/sitemainmenu/addon-block-sitemainmenu.html +++ b/src/addons/block/sitemainmenu/components/sitemainmenu/addon-block-sitemainmenu.html @@ -1,4 +1,4 @@ - +

{{ 'addon.block_sitemainmenu.pluginname' | translate }}

diff --git a/src/addons/block/starredcourses/components/starredcourses/addon-block-starredcourses.html b/src/addons/block/starredcourses/components/starredcourses/addon-block-starredcourses.html index 88e7fdfce..7d297b771 100644 --- a/src/addons/block/starredcourses/components/starredcourses/addon-block-starredcourses.html +++ b/src/addons/block/starredcourses/components/starredcourses/addon-block-starredcourses.html @@ -1,4 +1,4 @@ - +

{{ 'addon.block_starredcourses.pluginname' | translate }}

diff --git a/src/addons/block/timeline/components/events/addon-block-timeline-events.html b/src/addons/block/timeline/components/events/addon-block-timeline-events.html index 4428d0f64..d84981b96 100644 --- a/src/addons/block/timeline/components/events/addon-block-timeline-events.html +++ b/src/addons/block/timeline/components/events/addon-block-timeline-events.html @@ -14,7 +14,7 @@
- diff --git a/src/addons/block/timeline/components/timeline/addon-block-timeline.html b/src/addons/block/timeline/components/timeline/addon-block-timeline.html index 92d911286..b20b7952d 100644 --- a/src/addons/block/timeline/components/timeline/addon-block-timeline.html +++ b/src/addons/block/timeline/components/timeline/addon-block-timeline.html @@ -1,4 +1,4 @@ - +

{{ 'addon.block_timeline.pluginname' | translate }}

diff --git a/src/addons/blog/pages/entries/entries.html b/src/addons/blog/pages/entries/entries.html index fb9ffa77c..ff2f5d39b 100644 --- a/src/addons/blog/pages/entries/entries.html +++ b/src/addons/blog/pages/entries/entries.html @@ -65,7 +65,7 @@ - + {{ 'addon.blog.linktooriginalentry' | translate }} diff --git a/src/addons/calendar/pages/event/event.html b/src/addons/calendar/pages/event/event.html index 494a78e42..81a83d325 100644 --- a/src/addons/calendar/pages/event/event.html +++ b/src/addons/calendar/pages/event/event.html @@ -72,7 +72,7 @@

{{ 'addon.calendar.type' + event.formattedType | translate }}

- +

{{ 'core.course' | translate}}

diff --git a/src/addons/competency/pages/competencies/competencies.html b/src/addons/competency/pages/competencies/competencies.html index 72793a1db..33b3afe43 100644 --- a/src/addons/competency/pages/competencies/competencies.html +++ b/src/addons/competency/pages/competencies/competencies.html @@ -20,7 +20,7 @@ + [attr.aria-current]="competencies.getItemAriaCurrent(competency)" button [detail]="true">

+ [attr.aria-label]="competency.competency.shortname" [detail]="true" button>

diff --git a/src/addons/competency/pages/plan/plan.html b/src/addons/competency/pages/plan/plan.html index 5090642c4..dbe729263 100644 --- a/src/addons/competency/pages/plan/plan.html +++ b/src/addons/competency/pages/plan/plan.html @@ -81,7 +81,7 @@ + [attr.aria-label]="competency.competency.shortname" [detail]="true" button>

+ [attr.aria-current]="plans.getItemAriaCurrent(plan)" button [detail]="true">

diff --git a/src/addons/messages/components/conversation-info/conversation-info.html b/src/addons/messages/components/conversation-info/conversation-info.html index 3a4fb4af7..8d53b3dce 100644 --- a/src/addons/messages/components/conversation-info/conversation-info.html +++ b/src/addons/messages/components/conversation-info/conversation-info.html @@ -35,7 +35,7 @@ + [detail]="true" button> diff --git a/src/addons/messages/pages/contacts-35/contacts.html b/src/addons/messages/pages/contacts-35/contacts.html index 314a3b0d0..e79d83c11 100644 --- a/src/addons/messages/pages/contacts-35/contacts.html +++ b/src/addons/messages/pages/contacts-35/contacts.html @@ -42,7 +42,7 @@ diff --git a/src/addons/messages/pages/contacts/contacts.html b/src/addons/messages/pages/contacts/contacts.html index c049589e0..1ac693568 100644 --- a/src/addons/messages/pages/contacts/contacts.html +++ b/src/addons/messages/pages/contacts/contacts.html @@ -28,7 +28,7 @@ @@ -67,7 +67,7 @@ + [attr.aria-current]="request.id == selectedUserId ? 'page' : 'false'" [detail]="true"> diff --git a/src/addons/messages/pages/discussions-35/discussions.html b/src/addons/messages/pages/discussions-35/discussions.html index bb3368ca3..a95d142d8 100644 --- a/src/addons/messages/pages/discussions-35/discussions.html +++ b/src/addons/messages/pages/discussions-35/discussions.html @@ -28,7 +28,7 @@ + [attr.aria-label]="'addon.messages.contacts' | translate" [detail]="true" button>

{{ 'addon.messages.contacts' | translate }}

@@ -46,7 +46,7 @@ + [attr.aria-current]="result.userid == discussionUserId ? 'page' : 'false'" [detail]="false">

{{ result.fullname }}

@@ -60,7 +60,7 @@ + [attr.aria-current]="discussion.message!.user == discussionUserId ? 'page' : 'false'" [detail]="false">
diff --git a/src/addons/messages/pages/group-conversations/group-conversations.html b/src/addons/messages/pages/group-conversations/group-conversations.html index 9cca75e2d..eb9e0fdd7 100644 --- a/src/addons/messages/pages/group-conversations/group-conversations.html +++ b/src/addons/messages/pages/group-conversations/group-conversations.html @@ -27,7 +27,7 @@ - +

{{ 'addon.messages.contacts' | translate }}

@@ -38,10 +38,10 @@
- + [detail]="false"> @@ -73,9 +73,9 @@ - + aria-controls="addon-messages-groupconversations-group" role="heading" [detail]="false"> @@ -106,10 +106,10 @@ - + [detail]="false"> @@ -147,7 +147,7 @@ - + (click)="openConversation(result)" [attr.aria-current]="result == selectedResult ? 'page' : 'false'" [detail]="true" button>

diff --git a/src/addons/mod/assign/components/index/addon-mod-assign-index.html b/src/addons/mod/assign/components/index/addon-mod-assign-index.html index e7e04b991..3f65bb593 100644 --- a/src/addons/mod/assign/components/index/addon-mod-assign-index.html +++ b/src/addons/mod/assign/components/index/addon-mod-assign-index.html @@ -46,7 +46,8 @@ - +

{{ 'addon.mod_assign.numberofteams' | translate }}

{{ 'addon.mod_assign.numberofparticipants' | translate }}

diff --git a/src/addons/mod/assign/components/submission/addon-mod-assign-submission.html b/src/addons/mod/assign/components/submission/addon-mod-assign-submission.html index ac1208cd8..475acc689 100644 --- a/src/addons/mod/assign/components/submission/addon-mod-assign-submission.html +++ b/src/addons/mod/assign/components/submission/addon-mod-assign-submission.html @@ -393,7 +393,7 @@ + [attr.aria-label]="grader!.fullname" [detail]="true">

{{ 'addon.mod_assign.gradedby' | translate }}

diff --git a/src/addons/mod/assign/pages/submission-list/submission-list.html b/src/addons/mod/assign/pages/submission-list/submission-list.html index 61399abfc..dfc608421 100644 --- a/src/addons/mod/assign/pages/submission-list/submission-list.html +++ b/src/addons/mod/assign/pages/submission-list/submission-list.html @@ -28,7 +28,7 @@ + [attr.aria-current]="submissions.getItemAriaCurrent(submission)" [detail]="true">

{{submission.userfullname}}

diff --git a/src/addons/mod/assign/submission/comments/component/addon-mod-assign-submission-comments.html b/src/addons/mod/assign/submission/comments/component/addon-mod-assign-submission-comments.html index 157d9f527..912151506 100644 --- a/src/addons/mod/assign/submission/comments/component/addon-mod-assign-submission-comments.html +++ b/src/addons/mod/assign/submission/comments/component/addon-mod-assign-submission-comments.html @@ -1,4 +1,4 @@ - +

{{plugin.name}}

- +

{{ plugin.name }}

diff --git a/src/addons/mod/assign/submission/onlinetext/component/addon-mod-assign-submission-onlinetext.html b/src/addons/mod/assign/submission/onlinetext/component/addon-mod-assign-submission-onlinetext.html index 43f6b2009..b417a1286 100644 --- a/src/addons/mod/assign/submission/onlinetext/component/addon-mod-assign-submission-onlinetext.html +++ b/src/addons/mod/assign/submission/onlinetext/component/addon-mod-assign-submission-onlinetext.html @@ -13,7 +13,7 @@
- +

{{ plugin.name }}

diff --git a/src/addons/mod/bigbluebuttonbn/components/index/index.html b/src/addons/mod/bigbluebuttonbn/components/index/index.html index 0b2dccaf4..bb1d82c25 100644 --- a/src/addons/mod/bigbluebuttonbn/components/index/index.html +++ b/src/addons/mod/bigbluebuttonbn/components/index/index.html @@ -92,7 +92,7 @@ + [attr.aria-label]="(recording.expanded ? 'core.collapse' : 'core.expand') | translate" [detail]="false"> @@ -108,7 +108,7 @@

{{ recording.playbackLabel }}

-

{{ playback.name }}

diff --git a/src/addons/mod/book/components/index/addon-mod-book-index.html b/src/addons/mod/book/components/index/addon-mod-book-index.html index 89b4c085b..4d62979c4 100644 --- a/src/addons/mod/book/components/index/addon-mod-book-index.html +++ b/src/addons/mod/book/components/index/addon-mod-book-index.html @@ -20,7 +20,7 @@
-

diff --git a/src/addons/mod/book/components/toc/toc.html b/src/addons/mod/book/components/toc/toc.html index 7d63bbfea..f633ab0ff 100644 --- a/src/addons/mod/book/components/toc/toc.html +++ b/src/addons/mod/book/components/toc/toc.html @@ -14,7 +14,7 @@