MOBILE-3947 chore: Fix eqeqeq on HTML
parent
4ca0cf785a
commit
9be60c9e83
|
@ -88,11 +88,11 @@
|
|||
</core-combobox>
|
||||
</ion-col>
|
||||
<ion-col size="auto" *ngIf="isLayoutSwitcherAvailable">
|
||||
<ion-button *ngIf="layout == 'card'" fill="outline" (click)="toggleLayout('list')"
|
||||
<ion-button *ngIf="layout === 'card'" fill="outline" (click)="toggleLayout('list')"
|
||||
[attr.aria-label]="'addon.block_myoverview.aria:list' | translate">
|
||||
<ion-icon slot="icon-only" name="fas-list" aria-hidden="true"></ion-icon>
|
||||
</ion-button>
|
||||
<ion-button *ngIf="layout == 'list'" fill="outline" (click)="toggleLayout('card')"
|
||||
<ion-button *ngIf="layout === 'list'" fill="outline" (click)="toggleLayout('card')"
|
||||
[attr.aria-label]="'addon.block_myoverview.aria:card' | translate">
|
||||
<ion-icon slot="icon-only" name="fas-table-cells-large" aria-hidden="true"></ion-icon>
|
||||
</ion-button>
|
||||
|
@ -123,7 +123,7 @@
|
|||
|
||||
<!-- List of courses. -->
|
||||
<div class="safe-area-padding" *ngIf="hasCourses">
|
||||
<ion-grid class="ion-no-padding" [class.core-no-grid]="layout != 'card'" [class.list-item-limited-width]="layout != 'card'">
|
||||
<ion-grid class="ion-no-padding" [class.core-no-grid]="layout !== 'card'" [class.list-item-limited-width]="layout !== 'card'">
|
||||
<ion-row class="ion-no-padding">
|
||||
<ion-col *ngFor="let course of filteredCourses" class="ion-no-padding" size="12" size-sm="6" size-md="6" size-lg="4"
|
||||
size-xl="3">
|
||||
|
|
|
@ -51,7 +51,7 @@
|
|||
</ion-item>
|
||||
|
||||
<!-- Category. -->
|
||||
<ion-item class="ion-text-wrap" *ngIf="typeControl.value == 'category'">
|
||||
<ion-item class="ion-text-wrap" *ngIf="typeControl.value === 'category'">
|
||||
<ion-label>
|
||||
<p class="item-heading" [core-mark-required]="true">{{ 'core.category' | translate }}</p>
|
||||
</ion-label>
|
||||
|
@ -64,7 +64,7 @@
|
|||
</ion-item>
|
||||
|
||||
<!-- Course. -->
|
||||
<ion-item class="ion-text-wrap" *ngIf="typeControl.value == 'course'">
|
||||
<ion-item class="ion-text-wrap" *ngIf="typeControl.value === 'course'">
|
||||
<ion-label>
|
||||
<p class="item-heading" [core-mark-required]="true">{{ 'core.course' | translate }}</p>
|
||||
</ion-label>
|
||||
|
@ -75,7 +75,7 @@
|
|||
</ion-item>
|
||||
|
||||
<!-- Group. -->
|
||||
<ng-container *ngIf="typeControl.value == 'group'">
|
||||
<ng-container *ngIf="typeControl.value === 'group'">
|
||||
<!-- Select the course. -->
|
||||
<ion-item class="ion-text-wrap">
|
||||
<ion-label>
|
||||
|
|
|
@ -22,10 +22,10 @@
|
|||
autocorrect="off" spellcheck="false" lengthCheck="2" [disabled]="!loaded" searchArea="AddonMessagesContacts"></core-search-box>
|
||||
|
||||
<core-loading [hideUntil]="loaded" [message]="loadingMessage">
|
||||
<core-empty-box *ngIf="!hasContacts && searchString == ''" icon="fas-address-book"
|
||||
<core-empty-box *ngIf="!hasContacts && searchString === ''" icon="fas-address-book"
|
||||
[message]="'addon.messages.contactlistempty' | translate"></core-empty-box>
|
||||
|
||||
<core-empty-box *ngIf="!hasContacts && searchString != ''" icon="fas-address-book"
|
||||
<core-empty-box *ngIf="!hasContacts && searchString !== ''" icon="fas-address-book"
|
||||
[message]="'addon.messages.nousersfound' | translate"></core-empty-box>
|
||||
|
||||
<ion-list *ngFor="let contactType of contactTypes" class="ion-no-margin">
|
||||
|
|
|
@ -103,17 +103,17 @@
|
|||
</ion-fab>
|
||||
</ion-content>
|
||||
<ion-footer class="footer-adjustable" *ngIf="loaded && (!conversationId || conversation)">
|
||||
<ion-toolbar [color]="footerType == 'message' ? null : 'light'">
|
||||
<p *ngIf="footerType == 'unable'" class="ion-text-center ion-margin-horizontal">
|
||||
<ion-toolbar [color]="footerType === 'message' ? null : 'light'">
|
||||
<p *ngIf="footerType === 'unable'" class="ion-text-center ion-margin-horizontal">
|
||||
{{ 'addon.messages.unabletomessage' | translate }}
|
||||
</p>
|
||||
<div *ngIf="footerType == 'blocked'" class="ion-padding-horizontal">
|
||||
<div *ngIf="footerType === 'blocked'" class="ion-padding-horizontal">
|
||||
<p class="ion-text-center">{{ 'addon.messages.youhaveblockeduser' | translate }}</p>
|
||||
<ion-button expand="block" class="ion-text-wrap ion-margin-bottom" (click)="unblockUser()">
|
||||
{{ 'addon.messages.unblockuser' | translate }}
|
||||
</ion-button>
|
||||
</div>
|
||||
<div *ngIf="footerType == 'requiresContact' && otherMember" class="ion-padding-horizontal">
|
||||
<div *ngIf="footerType === 'requiresContact' && otherMember" class="ion-padding-horizontal">
|
||||
<p class="ion-text-center">
|
||||
<strong>{{ 'addon.messages.isnotinyourcontacts' | translate: {$a: otherMember.fullname} }}</strong>
|
||||
</p>
|
||||
|
@ -122,7 +122,7 @@
|
|||
{{ 'addon.messages.sendcontactrequest' | translate }}
|
||||
</ion-button>
|
||||
</div>
|
||||
<div *ngIf="footerType == 'requestReceived' && otherMember" class="ion-padding-horizontal">
|
||||
<div *ngIf="footerType === 'requestReceived' && otherMember" class="ion-padding-horizontal">
|
||||
<p class="ion-text-center">{{ 'addon.messages.userwouldliketocontactyou' | translate: {$a: otherMember.fullname} }}</p>
|
||||
<ion-button expand="block" class="ion-text-wrap ion-margin-bottom" (click)="confirmContactRequest()">
|
||||
{{ 'addon.messages.acceptandaddcontact' | translate }}
|
||||
|
@ -131,13 +131,13 @@
|
|||
{{ 'addon.messages.decline' | translate }}
|
||||
</ion-button>
|
||||
</div>
|
||||
<div *ngIf="footerType == 'requestSent' || (footerType == 'message' && requestContactSent)" class="ion-padding-horizontal">
|
||||
<div *ngIf="footerType === 'requestSent' || (footerType === 'message' && requestContactSent)" class="ion-padding-horizontal">
|
||||
<p class="ion-text-center"><strong>{{ 'addon.messages.contactrequestsent' | translate }}</strong></p>
|
||||
<p class="ion-text-center" *ngIf="otherMember">
|
||||
{{ 'addon.messages.yourcontactrequestpending' | translate: {$a: otherMember.fullname} }}
|
||||
</p>
|
||||
</div>
|
||||
<core-send-message-form *ngIf="footerType == 'message'" (onSubmit)="sendMessage($event)" [showKeyboard]="showKeyboard"
|
||||
<core-send-message-form *ngIf="footerType === 'message'" (onSubmit)="sendMessage($event)" [showKeyboard]="showKeyboard"
|
||||
[placeholder]="'addon.messages.newmessage' | translate"></core-send-message-form>
|
||||
</ion-toolbar>
|
||||
</ion-footer>
|
||||
|
|
|
@ -68,7 +68,7 @@
|
|||
</ion-item>
|
||||
|
||||
<!-- Load more button for contacts and non-contacts -->
|
||||
<ng-container *ngIf="item.type != 'messages'">
|
||||
<ng-container *ngIf="item.type !== 'messages'">
|
||||
<div class="ion-padding-horizontal" *ngIf="item.canLoadMore && !item.loadingMore">
|
||||
<ion-button expand="block" fill="outline" (click)="search(query, item.type)">
|
||||
{{ 'core.loadmore' | translate }}
|
||||
|
|
|
@ -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';
|
||||
|
|
|
@ -264,7 +264,7 @@
|
|||
<ng-template>
|
||||
<!-- Current grade if method is advanced. -->
|
||||
<ion-item class="ion-text-wrap core-grading-summary"
|
||||
*ngIf="feedback?.gradefordisplay && (!isGrading || grade.method != 'simple')">
|
||||
*ngIf="feedback?.gradefordisplay && (!isGrading || grade.method !== 'simple')">
|
||||
<ion-label>
|
||||
<p class="item-heading">{{ 'addon.mod_assign.currentgrade' | translate }}</p>
|
||||
<p>
|
||||
|
@ -280,7 +280,7 @@
|
|||
<ng-container *ngIf="isGrading">
|
||||
<!-- Numeric grade.
|
||||
Use a text input because otherwise we cannot readthe value if it has an invalid character. -->
|
||||
<ion-item class="ion-text-wrap" *ngIf="grade.method == 'simple' && !grade.scale">
|
||||
<ion-item class="ion-text-wrap" *ngIf="grade.method === 'simple' && !grade.scale">
|
||||
<ion-label position="stacked">
|
||||
<p class="item-heading">{{ 'addon.mod_assign.gradeoutof' | translate: {$a: gradeInfo!.grade} }}</p>
|
||||
</ion-label>
|
||||
|
@ -291,7 +291,7 @@
|
|||
</ion-item>
|
||||
|
||||
<!-- Grade using a scale. -->
|
||||
<ion-item class="ion-text-wrap" *ngIf="grade.method == 'simple' && grade.scale">
|
||||
<ion-item class="ion-text-wrap" *ngIf="grade.method === 'simple' && grade.scale">
|
||||
<ion-label>
|
||||
<p class="item-heading">{{ 'addon.mod_assign.grade' | translate }}</p>
|
||||
</ion-label>
|
||||
|
@ -323,13 +323,13 @@
|
|||
<ion-item class="ion-text-wrap" *ngIf="gradeInfo && grade.unreleasedGrade !== undefined">
|
||||
<ion-label>
|
||||
<p class="item-heading">{{ 'addon.mod_assign.currentassigngrade' | translate }}</p>
|
||||
<p *ngIf="grade.method != 'simple' || !grade.scale">{{ grade.unreleasedGrade}} / {{ gradeInfo.grade }}</p>
|
||||
<p *ngIf="grade.method == 'simple' && grade.scale">{{ grade.unreleasedGrade }}</p>
|
||||
<p *ngIf="grade.method !== 'simple' || !grade.scale">{{ grade.unreleasedGrade}} / {{ gradeInfo.grade }}</p>
|
||||
<p *ngIf="grade.method === 'simple' && grade.scale">{{ grade.unreleasedGrade }}</p>
|
||||
</ion-label>
|
||||
</ion-item>
|
||||
|
||||
<!-- Gradebook grade for simple grading. -->
|
||||
<ion-item class="ion-text-wrap" *ngIf="grade.method == 'simple'">
|
||||
<ion-item class="ion-text-wrap" *ngIf="grade.method === 'simple'">
|
||||
<ion-label>
|
||||
<p class="item-heading">{{ 'addon.mod_assign.currentgrade' | translate }}</p>
|
||||
<p *ngIf="grade.gradebookGrade && !grade.scale">
|
||||
|
|
|
@ -26,7 +26,7 @@
|
|||
</p>
|
||||
|
||||
<div class="ion-text-center addon-mod_chat-notice" *ngIf="message.special">
|
||||
<ion-badge class="ion-text-wrap" color="success" *ngIf="message.system && message.message == 'enter'">
|
||||
<ion-badge class="ion-text-wrap" color="success" *ngIf="message.system && message.message === 'enter'">
|
||||
<span>
|
||||
<ion-icon name="fas-right-to-bracket" aria-hidden="true"></ion-icon>
|
||||
{{ message.timestamp * 1000 | coreFormatDate:"strftimetime" }}
|
||||
|
@ -34,7 +34,7 @@
|
|||
</span>
|
||||
</ion-badge>
|
||||
|
||||
<ion-badge class="ion-text-wrap" color="danger" *ngIf="message.system && message.message == 'exit'">
|
||||
<ion-badge class="ion-text-wrap" color="danger" *ngIf="message.system && message.message === 'exit'">
|
||||
<span>
|
||||
<ion-icon name="fas-right-from-bracket" aria-hidden="true"></ion-icon>
|
||||
{{ message.timestamp * 1000 | coreFormatDate:"strftimetime" }}
|
||||
|
@ -42,7 +42,7 @@
|
|||
</span>
|
||||
</ion-badge>
|
||||
|
||||
<ion-badge class="ion-text-wrap" color="primary" *ngIf="message.beep == 'all'">
|
||||
<ion-badge class="ion-text-wrap" color="primary" *ngIf="message.beep === 'all'">
|
||||
<span>
|
||||
<ion-icon name="fas-bell" aria-hidden="true"></ion-icon>
|
||||
{{ message.timestamp * 1000 | coreFormatDate:"strftimetime" }}
|
||||
|
@ -60,7 +60,7 @@
|
|||
</ion-badge>
|
||||
|
||||
<ion-badge class="ion-text-wrap" color="light"
|
||||
*ngIf="message.userid == currentUserId && message.beep && message.beep != 'all'">
|
||||
*ngIf="message.userid === currentUserId && message.beep && message.beep !== 'all'">
|
||||
<span>
|
||||
<ion-icon name="fas-bell" aria-hidden="true"></ion-icon>
|
||||
{{ message.timestamp * 1000 | coreFormatDate:"strftimetime" }}
|
||||
|
|
|
@ -21,7 +21,7 @@
|
|||
</div>
|
||||
|
||||
<div class="ion-text-center addon-mod_chat-notice" *ngIf="message.special">
|
||||
<ion-badge class="ion-text-wrap" color="success" *ngIf="message.issystem && message.message == 'enter'">
|
||||
<ion-badge class="ion-text-wrap" color="success" *ngIf="message.issystem && message.message === 'enter'">
|
||||
<span>
|
||||
<ion-icon name="fas-right-to-bracket" aria-hidden="true"></ion-icon>
|
||||
{{ message.timestamp * 1000 | coreFormatDate:"strftimetime" }}
|
||||
|
@ -29,7 +29,7 @@
|
|||
</span>
|
||||
</ion-badge>
|
||||
|
||||
<ion-badge class="ion-text-wrap" color="danger" *ngIf="message.issystem && message.message == 'exit'">
|
||||
<ion-badge class="ion-text-wrap" color="danger" *ngIf="message.issystem && message.message === 'exit'">
|
||||
<span>
|
||||
<ion-icon name="fas-right-from-bracket" aria-hidden="true"></ion-icon>
|
||||
{{ message.timestamp * 1000 | coreFormatDate:"strftimetime" }}
|
||||
|
@ -37,7 +37,7 @@
|
|||
</span>
|
||||
</ion-badge>
|
||||
|
||||
<ion-badge class="ion-text-wrap" color="primary" *ngIf="message.beep == 'all'">
|
||||
<ion-badge class="ion-text-wrap" color="primary" *ngIf="message.beep === 'all'">
|
||||
<span>
|
||||
<ion-icon name="fas-bell" aria-hidden="true"></ion-icon>
|
||||
{{ message.timestamp * 1000 | coreFormatDate:"strftimetime" }}
|
||||
|
@ -55,7 +55,7 @@
|
|||
</ion-badge>
|
||||
|
||||
<ion-badge class="ion-text-wrap" color="light"
|
||||
*ngIf="message.userid == currentUserId && message.beep && message.beep != 'all'">
|
||||
*ngIf="message.userid === currentUserId && message.beep && message.beep !== 'all'">
|
||||
<span>
|
||||
<ion-icon name="fas-bell" aria-hidden="true"></ion-icon>
|
||||
{{ message.timestamp * 1000 | coreFormatDate:"strftimetime" }}
|
||||
|
|
|
@ -1,49 +1,49 @@
|
|||
<ion-button size="small" *ngIf="action == 'actionsmenu'" fill="clear" (click)="actionsMenu($event)"
|
||||
<ion-button size="small" *ngIf="action === 'actionsmenu'" fill="clear" (click)="actionsMenu($event)"
|
||||
[attr.aria-label]="'addon.mod_data.actionsmenu' | translate">
|
||||
<ion-icon name="fas-ellipsis-vertical" slot="icon-only" aria-hidden="true"></ion-icon>
|
||||
</ion-button>
|
||||
|
||||
<ion-button size="small" *ngIf="action == 'more'" fill="clear" (click)="viewEntry()"
|
||||
<ion-button size="small" *ngIf="action === 'more'" fill="clear" (click)="viewEntry()"
|
||||
[attr.aria-label]="'addon.mod_data.showmore' | translate">
|
||||
<ion-icon name="fas-magnifying-glass-plus" slot="icon-only" aria-hidden="true"></ion-icon>
|
||||
</ion-button>
|
||||
|
||||
<ion-button size="small" *ngIf="action == 'edit'" fill="clear" (click)="editEntry()" [attr.aria-label]="'core.edit' | translate">
|
||||
<ion-button size="small" *ngIf="action === 'edit'" fill="clear" (click)="editEntry()" [attr.aria-label]="'core.edit' | translate">
|
||||
<ion-icon name="fas-pen" slot="icon-only" aria-hidden="true"></ion-icon>
|
||||
</ion-button>
|
||||
|
||||
<ion-button size="small" *ngIf="action == 'delete' && !entry.deleted" fill="clear" color="danger" (click)="deleteEntry()"
|
||||
<ion-button size="small" *ngIf="action === 'delete' && !entry.deleted" fill="clear" color="danger" (click)="deleteEntry()"
|
||||
[attr.aria-label]="'core.delete' | translate">
|
||||
<ion-icon name="fas-trash" slot="icon-only" aria-hidden="true"></ion-icon>
|
||||
</ion-button>
|
||||
|
||||
<ion-button size="small" *ngIf="action == 'delete' && entry.deleted" fill="clear" color="danger" (click)="undoDelete()"
|
||||
<ion-button size="small" *ngIf="action === 'delete' && entry.deleted" fill="clear" color="danger" (click)="undoDelete()"
|
||||
[attr.aria-label]="'core.restore' | translate">
|
||||
<ion-icon name="fas-rotate-left" slot="icon-only" aria-hidden="true"></ion-icon>
|
||||
</ion-button>
|
||||
|
||||
<ion-button size="small" *ngIf="action == 'approve'" fill="clear" (click)="approveEntry()"
|
||||
<ion-button size="small" *ngIf="action === 'approve'" fill="clear" (click)="approveEntry()"
|
||||
[attr.aria-label]="'addon.mod_data.approve' | translate">
|
||||
<ion-icon name="fas-thumbs-up" slot="icon-only" aria-hidden="true"></ion-icon>
|
||||
</ion-button>
|
||||
|
||||
<ion-button size="small" *ngIf="action == 'disapprove'" fill="clear" (click)="disapproveEntry()"
|
||||
<ion-button size="small" *ngIf="action === 'disapprove'" fill="clear" (click)="disapproveEntry()"
|
||||
[attr.aria-label]="'addon.mod_data.disapprove' | translate">
|
||||
<ion-icon name="far-thumbs-down" slot="icon-only" aria-hidden="true"></ion-icon>
|
||||
</ion-button>
|
||||
|
||||
<core-comments *ngIf="action == 'comments' && mode == 'list'" contextLevel="module" [instanceId]="database.coursemodule"
|
||||
<core-comments *ngIf="action === 'comments' && mode === 'list'" contextLevel="module" [instanceId]="database.coursemodule"
|
||||
component="mod_data" [itemId]="entry.id" area="database_entry" [courseId]="database.course">
|
||||
</core-comments>
|
||||
|
||||
<span *ngIf="action == 'timeadded'">{{ entry.timecreated * 1000 | coreFormatDate }}</span>
|
||||
<span *ngIf="action == 'timemodified'">{{ entry.timemodified * 1000 | coreFormatDate }}</span>
|
||||
<span *ngIf="action === 'timeadded'">{{ entry.timecreated * 1000 | coreFormatDate }}</span>
|
||||
<span *ngIf="action === 'timemodified'">{{ entry.timemodified * 1000 | coreFormatDate }}</span>
|
||||
|
||||
<core-user-avatar *ngIf="action == 'userpicture'" [user]="entry" slot="start" [courseId]="database.course" [userId]="entry.userid"
|
||||
<core-user-avatar *ngIf="action === 'userpicture'" [user]="entry" slot="start" [courseId]="database.course" [userId]="entry.userid"
|
||||
[profileUrl]="userPicture"></core-user-avatar>
|
||||
|
||||
<a *ngIf="action == 'user' && entry" core-user-link [courseId]="database.course" [userId]="entry.userid" [title]="entry.fullname">
|
||||
<a *ngIf="action === 'user' && entry" core-user-link [courseId]="database.course" [userId]="entry.userid" [title]="entry.fullname">
|
||||
{{entry.fullname}}
|
||||
</a>
|
||||
|
||||
<core-tag-list *ngIf="tagsEnabled && action == 'tags' && entry" [tags]="entry.tags"></core-tag-list>
|
||||
<core-tag-list *ngIf="tagsEnabled && action === 'tags' && entry" [tags]="entry.tags"></core-tag-list>
|
||||
|
|
|
@ -30,8 +30,8 @@
|
|||
</ion-item>
|
||||
<ng-container *ngIf="items && items.length">
|
||||
<ng-container *ngFor="let item of items">
|
||||
<core-spacer *ngIf="item.typ == 'pagebreak'"></core-spacer>
|
||||
<ion-item class="ion-text-wrap" *ngIf="item.typ != 'pagebreak'" [color]="item.dependitem > 0 ? 'light' : ''">
|
||||
<core-spacer *ngIf="item.typ === 'pagebreak'"></core-spacer>
|
||||
<ion-item class="ion-text-wrap" *ngIf="item.typ !== 'pagebreak'" [color]="item.dependitem > 0 ? 'light' : ''">
|
||||
<ion-label>
|
||||
<p class="item-heading" *ngIf="item.name" [core-mark-required]="item.required">
|
||||
<span *ngIf="feedback!.autonumbering && item.itemnumber">{{item.itemnumber}}. </span>
|
||||
|
|
|
@ -23,8 +23,8 @@
|
|||
</ion-label>
|
||||
</ion-item>
|
||||
<ng-container *ngFor="let item of items">
|
||||
<core-spacer *ngIf="item.typ == 'pagebreak'"></core-spacer>
|
||||
<ng-container *ngIf="item.typ != 'pagebreak'">
|
||||
<core-spacer *ngIf="item.typ === 'pagebreak'"></core-spacer>
|
||||
<ng-container *ngIf="item.typ !== 'pagebreak'">
|
||||
<ion-item class="ion-text-wrap addon-mod_feedback-item" [color]="item.dependitem > 0 ? 'light' : ''"
|
||||
[class.core-danger-item]="item.isEmpty || item.hasError">
|
||||
<ion-label [position]="item.hasTextInput ? 'stacked' : undefined">
|
||||
|
@ -35,18 +35,18 @@
|
|||
</core-format-text>
|
||||
<span *ngIf="item.postfix" class="addon-mod_feedback-postfix">{{item.postfix}}</span>
|
||||
</p>
|
||||
<p *ngIf="item.templateName == 'label'">
|
||||
<p *ngIf="item.templateName === 'label'">
|
||||
<core-format-text [component]="component" [componentId]="cmId" [text]="item.presentation"
|
||||
contextLevel="module" [contextInstanceId]="cmId" [wsNotFiltered]="true" [courseId]="courseId">
|
||||
</core-format-text>
|
||||
</p>
|
||||
</ion-label>
|
||||
|
||||
<ion-input *ngIf="item.templateName == 'textfield'" type="text" [(ngModel)]="item.value" autocorrect="off"
|
||||
<ion-input *ngIf="item.templateName === 'textfield'" type="text" [(ngModel)]="item.value" autocorrect="off"
|
||||
name="{{item.typ}}_{{item.id}}" maxlength="{{item.length}}" [required]="item.required">
|
||||
</ion-input>
|
||||
|
||||
<ng-container *ngIf="item.templateName == 'numeric'">
|
||||
<ng-container *ngIf="item.templateName === 'numeric'">
|
||||
<ion-input type="number" [(ngModel)]="item.value" name="{{item.typ}}_{{item.id}}"
|
||||
[required]="item.required">
|
||||
</ion-input>
|
||||
|
@ -56,11 +56,11 @@
|
|||
</ion-text>
|
||||
</ng-container>
|
||||
|
||||
<ion-textarea *ngIf="item.templateName == 'textarea'" [required]="item.required" name="{{item.typ}}_{{item.id}}"
|
||||
<ion-textarea *ngIf="item.templateName === 'textarea'" [required]="item.required" name="{{item.typ}}_{{item.id}}"
|
||||
[(ngModel)]="item.value">
|
||||
</ion-textarea>
|
||||
|
||||
<ion-select *ngIf="item.templateName == 'multichoice-d'" [required]="item.required"
|
||||
<ion-select *ngIf="item.templateName === 'multichoice-d'" [required]="item.required"
|
||||
name="{{item.typ}}_{{item.id}}" [(ngModel)]="item.value" interface="action-sheet"
|
||||
[cancelText]="'core.cancel' | translate" [interfaceOptions]="{header: item.name}">
|
||||
<ion-select-option *ngFor="let option of item.choices" [value]="option.value">
|
||||
|
@ -71,7 +71,7 @@
|
|||
</ion-select>
|
||||
</ion-item>
|
||||
|
||||
<ion-radio-group *ngIf="item.templateName == 'multichoice-r'" [(ngModel)]="item.value" [required]="item.required"
|
||||
<ion-radio-group *ngIf="item.templateName === 'multichoice-r'" [(ngModel)]="item.value" [required]="item.required"
|
||||
name="{{item.typ}}_{{item.id}}">
|
||||
<ion-item *ngFor="let option of item.choices">
|
||||
<ion-label>
|
||||
|
@ -83,7 +83,7 @@
|
|||
</ion-item>
|
||||
</ion-radio-group>
|
||||
|
||||
<ng-container *ngIf="item.templateName == 'multichoice-c'">
|
||||
<ng-container *ngIf="item.templateName === 'multichoice-c'">
|
||||
<ion-item *ngFor="let option of item.choices">
|
||||
<ion-label>
|
||||
<core-format-text [component]="component" [componentId]="cmId" [text]="option.label"
|
||||
|
@ -96,7 +96,7 @@
|
|||
</ion-item>
|
||||
</ng-container>
|
||||
|
||||
<ng-container *ngIf="item.templateName == 'captcha'">
|
||||
<ng-container *ngIf="item.templateName === 'captcha'">
|
||||
<core-recaptcha *ngIf="!preview && !offline" [publicKey]="item.captcha.recaptchapublickey" [model]="item"
|
||||
modelValueName="value">
|
||||
</core-recaptcha>
|
||||
|
|
|
@ -18,7 +18,7 @@
|
|||
|
||||
<core-loading [hideUntil]="!showLoading && discussions && discussions.loaded">
|
||||
<!-- Activity info. -->
|
||||
<core-course-module-info [module]="module" [description]="forum && forum.type != 'single' && description" [component]="component"
|
||||
<core-course-module-info [module]="module" [description]="forum && forum.type !== 'single' && description" [component]="component"
|
||||
[componentId]="componentId" [courseId]="courseId" [hasDataToSync]="hasOffline || hasOfflineRatings"
|
||||
(completionChanged)="onCompletionChange()">
|
||||
<ion-item class="ion-text-wrap">
|
||||
|
|
|
@ -146,7 +146,7 @@
|
|||
<ion-button expand="block" fill="outline" (click)="cancel()">{{ 'core.cancel' | translate }}</ion-button>
|
||||
</ion-col>
|
||||
<ion-col>
|
||||
<ion-button expand="block" (click)="send()" [disabled]="formData.subject == '' || formData.message == null">
|
||||
<ion-button expand="block" (click)="send()" [disabled]="formData.subject === '' || formData.message === null">
|
||||
<span *ngIf="formData.isEditing">{{ 'core.savechanges' | translate }}</span>
|
||||
<span *ngIf="!formData.isEditing">{{ 'addon.mod_forum.posttoforum' | translate }}</span>
|
||||
</ion-button>
|
||||
|
|
|
@ -24,13 +24,13 @@
|
|||
[content]="'core.settings.synchronizenow' | translate" [iconAction]="syncIcon" [closeOnClick]="false"
|
||||
(action)="doRefresh(null, $event, true)">
|
||||
</core-context-menu-item>
|
||||
<core-context-menu-item [hidden]="sort == 'flat-oldest'" [priority]="500"
|
||||
<core-context-menu-item [hidden]="sort === 'flat-oldest'" [priority]="500"
|
||||
[content]="'addon.mod_forum.modeflatoldestfirst' | translate" iconAction="fas-arrow-down" (action)="changeSort('flat-oldest')">
|
||||
</core-context-menu-item>
|
||||
<core-context-menu-item [hidden]="sort == 'flat-newest'" [priority]="450"
|
||||
<core-context-menu-item [hidden]="sort === 'flat-newest'" [priority]="450"
|
||||
[content]="'addon.mod_forum.modeflatnewestfirst' | translate" iconAction="fas-arrow-up" (action)="changeSort('flat-newest')">
|
||||
</core-context-menu-item>
|
||||
<core-context-menu-item [hidden]="sort == 'nested'" [priority]="400" [content]="'addon.mod_forum.modenested' | translate"
|
||||
<core-context-menu-item [hidden]="sort === 'nested'" [priority]="400" [content]="'addon.mod_forum.modenested' | translate"
|
||||
iconAction="fas-right-left" (action)="changeSort('nested')">
|
||||
</core-context-menu-item>
|
||||
<core-context-menu-item [hidden]="!discussion || !discussion.canlock || discussion.locked" [priority]="300"
|
||||
|
@ -102,7 +102,7 @@
|
|||
</addon-mod-forum-post>
|
||||
</div>
|
||||
|
||||
<ion-card *ngIf="sort != 'nested' && posts.length">
|
||||
<ion-card *ngIf="sort !== 'nested' && posts.length">
|
||||
<ng-container *ngFor="let post of posts; first as first">
|
||||
<core-spacer *ngIf="!first"></core-spacer>
|
||||
<addon-mod-forum-post [post]="post" [courseId]="courseId" [discussionId]="discussionId" [component]="component"
|
||||
|
@ -113,7 +113,7 @@
|
|||
</ng-container>
|
||||
</ion-card>
|
||||
|
||||
<ng-container *ngIf="sort == 'nested' && posts.length">
|
||||
<ng-container *ngIf="sort === 'nested' && posts.length">
|
||||
<ng-container *ngFor="let post of posts">
|
||||
<ng-container *ngTemplateOutlet="nestedPosts; context: {post: post}"></ng-container>
|
||||
</ng-container>
|
||||
|
|
|
@ -84,7 +84,7 @@
|
|||
<ion-button expand="block" fill="outline" (click)="discard()">{{ 'core.discard' | translate }}</ion-button>
|
||||
</ion-col>
|
||||
<ion-col>
|
||||
<ion-button expand="block" [disabled]="newDiscussion.subject == '' || newDiscussion.message == null"
|
||||
<ion-button expand="block" [disabled]="newDiscussion.subject === '' || newDiscussion.message === null"
|
||||
(click)="add()">
|
||||
{{ 'addon.mod_forum.posttoforum' | translate }}
|
||||
</ion-button>
|
||||
|
|
|
@ -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) => {
|
||||
|
|
|
@ -28,17 +28,17 @@
|
|||
|
||||
<ion-icon *ngIf="question.type === 'description' || !question.questionnumber" name="fas-circle-info" slot="end"
|
||||
aria-hidden="true"></ion-icon>
|
||||
<ion-icon *ngIf="question.stateClass == 'core-question-requiresgrading'" name="fas-circle-question"
|
||||
<ion-icon *ngIf="question.stateClass === 'core-question-requiresgrading'" name="fas-circle-question"
|
||||
[attr.aria-label]="question.status" slot="end">
|
||||
</ion-icon>
|
||||
<ion-icon *ngIf="question.stateClass == 'core-question-correct'" name="fas-check" color="success"
|
||||
<ion-icon *ngIf="question.stateClass === 'core-question-correct'" name="fas-check" color="success"
|
||||
[attr.aria-label]="question.status" slot="end">
|
||||
</ion-icon>
|
||||
<ion-icon *ngIf="question.stateClass == 'core-question-partiallycorrect'" name="fas-square-check" color="warning"
|
||||
<ion-icon *ngIf="question.stateClass === 'core-question-partiallycorrect'" name="fas-square-check" color="warning"
|
||||
[attr.aria-label]="question.status" slot="end">
|
||||
</ion-icon>
|
||||
<ion-icon *ngIf="question.stateClass == 'core-question-incorrect' ||
|
||||
question.stateClass == 'core-question-notanswered'" name="fas-xmark" color="danger" [attr.aria-label]="question.status"
|
||||
<ion-icon *ngIf="question.stateClass === 'core-question-incorrect' ||
|
||||
question.stateClass === 'core-question-notanswered'" name="fas-xmark" color="danger" [attr.aria-label]="question.status"
|
||||
slot="end">
|
||||
</ion-icon>
|
||||
</ion-item>
|
||||
|
|
|
@ -24,15 +24,15 @@
|
|||
</ion-item>
|
||||
</ion-card>
|
||||
|
||||
<ng-container *ngIf="mode == 'iframe'">
|
||||
<ng-container *ngIf="mode === 'iframe'">
|
||||
<core-iframe [src]="src"></core-iframe>
|
||||
</ng-container>
|
||||
|
||||
<div *ngIf="mode == 'embedded'" class="ion-padding">
|
||||
<div *ngIf="mode === 'embedded'" class="ion-padding">
|
||||
<core-format-text [text]="contentText" [filter]="false"></core-format-text>
|
||||
</div>
|
||||
|
||||
<ng-container *ngIf="mode == 'external'">
|
||||
<ng-container *ngIf="mode === 'external'">
|
||||
<ion-list>
|
||||
<ion-item class="ion-text-wrap" *ngIf="type">
|
||||
<ion-label>
|
||||
|
@ -84,7 +84,7 @@
|
|||
</ng-container>
|
||||
|
||||
<div collapsible-footer appearOnBottom *ngIf="!showLoading" slot="fixed">
|
||||
<div class="list-item-limited-width" *ngIf="mode == 'external'">
|
||||
<div class="list-item-limited-width" *ngIf="mode === 'external'">
|
||||
<ion-button *ngIf="isIOS && (!shouldOpenInBrowser || !isOnline)" expand="block" fill="outline"
|
||||
(click)="open(openFileAction.OPEN_WITH)" class="ion-margin ion-text-wrap">
|
||||
<ion-icon name="far-share-from-square" slot="start" aria-hidden="true"></ion-icon>
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
</ion-toolbar>
|
||||
</ion-header>
|
||||
<ion-content class="limited-width">
|
||||
<ion-refresher slot="fixed" [disabled]="activityComponent?.showLoading || activityComponent?.mode == 'iframe'"
|
||||
<ion-refresher slot="fixed" [disabled]="activityComponent?.showLoading || activityComponent?.mode === 'iframe'"
|
||||
(ionRefresh)="activityComponent?.doRefresh($event.target)">
|
||||
<ion-refresher-content pullingText="{{ 'core.pulltorefresh' | translate }}"></ion-refresher-content>
|
||||
</ion-refresher>
|
||||
|
|
|
@ -22,13 +22,13 @@
|
|||
<ng-container *ngIf="phases && phases[workshop.phase] && phases[workshop.phase].tasks &&
|
||||
phases[workshop.phase].tasks.length">
|
||||
<ion-item button class="ion-text-wrap" *ngFor="let task of phases[workshop.phase].tasks"
|
||||
[class.item-dimmed]="task.code == 'submit' && !showSubmit" (click)="runTask(task)" detail="false">
|
||||
<ion-icon slot="start" name="far-circle" *ngIf="task.completed == null"
|
||||
[class.item-dimmed]="task.code === 'submit' && !showSubmit" (click)="runTask(task)" detail="false">
|
||||
<ion-icon slot="start" name="far-circle" *ngIf="task.completed === null"
|
||||
[attr.aria-label]="'addon.mod_workshop.tasktodo' | translate"></ion-icon>
|
||||
<ion-icon slot="start" name="fas-circle-xmark" color="danger" *ngIf="task.completed == ''"
|
||||
<ion-icon slot="start" name="fas-circle-xmark" color="danger" *ngIf="task.completed === ''"
|
||||
[attr.aria-label]="'addon.mod_workshop.taskfail' | translate">
|
||||
</ion-icon>
|
||||
<ion-icon slot="start" name="fas-circle-info" color="info" *ngIf="task.completed == 'info'"
|
||||
<ion-icon slot="start" name="fas-circle-info" color="info" *ngIf="task.completed === 'info'"
|
||||
[attr.aria-label]="'addon.mod_workshop.taskinfo' | translate">
|
||||
</ion-icon>
|
||||
<ion-icon slot="start" name="fas-circle-check" color="success" *ngIf="task.completed == '1'"
|
||||
|
@ -38,7 +38,7 @@
|
|||
<p class="item-heading">{{task.title}}</p>
|
||||
<p *ngIf="task.details" [innerHTML]="task.details"></p>
|
||||
</ion-label>
|
||||
<ion-icon slot="end" *ngIf="task.link && task.code != 'submit'" name="fas-up-right-from-square" aria-hidden="true">
|
||||
<ion-icon slot="end" *ngIf="task.link && task.code !== 'submit'" name="fas-up-right-from-square" aria-hidden="true">
|
||||
</ion-icon>
|
||||
</ion-item>
|
||||
</ng-container>
|
||||
|
|
|
@ -29,13 +29,13 @@
|
|||
<ion-icon slot="end" name="fas-up-right-from-square" aria-hidden="true"></ion-icon>
|
||||
</ion-item>
|
||||
<ion-item class="ion-text-wrap" *ngFor="let task of phase.tasks"
|
||||
[class.item-dimmed]="phase.code != workshopPhase || (task.code == 'submit' && !showSubmit)" (click)="runTask(task)"
|
||||
[class.item-dimmed]="phase.code !== workshopPhase || (task.code === 'submit' && !showSubmit)" (click)="runTask(task)"
|
||||
detail="false" button>
|
||||
<ion-icon slot="start" name="far-circle" *ngIf="task.completed == null"
|
||||
[attr.aria-label]="'addon.mod_workshop.tasktodo' | translate"></ion-icon>
|
||||
<ion-icon slot="start" name="fas-circle-xmark" color="danger" *ngIf="task.completed == ''"
|
||||
<ion-icon slot="start" name="fas-circle-xmark" color="danger" *ngIf="task.completed === ''"
|
||||
[attr.aria-label]="'addon.mod_workshop.taskfail' | translate"></ion-icon>
|
||||
<ion-icon slot="start" name="fas-circle-info" color="info" *ngIf="task.completed == 'info'"
|
||||
<ion-icon slot="start" name="fas-circle-info" color="info" *ngIf="task.completed === 'info'"
|
||||
[attr.aria-label]="'addon.mod_workshop.taskinfo' | translate"></ion-icon>
|
||||
<ion-icon slot="start" name="fas-circle-check" color="success" *ngIf="task.completed == '1'"
|
||||
[attr.aria-label]="'addon.mod_workshop.taskdone' | translate"></ion-icon>
|
||||
|
@ -43,7 +43,7 @@
|
|||
<p class="item-heading ion-text-wrap">{{task.title}}</p>
|
||||
<p *ngIf="task.details" [innerHTML]="task.details"></p>
|
||||
</ion-label>
|
||||
<ion-icon slot="end" *ngIf="task.link && task.code != 'submit'" name="fas-up-right-from-square" aria-hidden="true">
|
||||
<ion-icon slot="end" *ngIf="task.link && task.code !== 'submit'" name="fas-up-right-from-square" aria-hidden="true">
|
||||
</ion-icon>
|
||||
</ion-item>
|
||||
</ng-container>
|
||||
|
|
|
@ -391,7 +391,7 @@ export class AddonModWorkshopHelperProvider {
|
|||
files: CoreFileEntry[],
|
||||
offline: false,
|
||||
siteId?: string,
|
||||
): Promise<number>
|
||||
): Promise<number>;
|
||||
uploadOrStoreAssessmentFiles(
|
||||
workshopId: number,
|
||||
assessmentId: number,
|
||||
|
|
|
@ -86,8 +86,8 @@
|
|||
[attr.aria-label]="'core.restore' | translate">
|
||||
<ion-icon name="fas-rotate-left" slot="icon-only" aria-hidden="true"></ion-icon>
|
||||
</ion-button>
|
||||
<ion-button *ngIf="showDelete && !note.deleted && (type != 'personal' || note.usermodified == currentUserId)" slot="end"
|
||||
fill="clear" [@coreSlideInOut]="'fromRight'" color="danger" (click)="deleteNote($event, note)"
|
||||
<ion-button *ngIf="showDelete && !note.deleted && (type !== 'personal' || note.usermodified === currentUserId)"
|
||||
slot="end" fill="clear" [@coreSlideInOut]="'fromRight'" color="danger" (click)="deleteNote($event, note)"
|
||||
[attr.aria-label]="'core.delete' | translate">
|
||||
<ion-icon name="fas-trash" slot="icon-only" aria-hidden="true"></ion-icon>
|
||||
</ion-button>
|
||||
|
|
|
@ -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;
|
||||
|
|
|
@ -51,7 +51,7 @@
|
|||
</core-loading>
|
||||
|
||||
<!-- Upload a private file. -->
|
||||
<ion-fab slot="fixed" core-fab vertical="bottom" horizontal="end" *ngIf="showUpload && root != 'site' && !path">
|
||||
<ion-fab slot="fixed" core-fab vertical="bottom" horizontal="end" *ngIf="showUpload && root !== 'site' && !path">
|
||||
<ion-fab-button (click)="uploadFile()" [attr.aria-label]="'core.fileuploader.uploadafile' | translate">
|
||||
<ion-icon name="fas-plus" aria-hidden="true"></ion-icon>
|
||||
<span class="sr-only">{{ 'core.fileuploader.uploadafile' | translate }}</span>
|
||||
|
|
|
@ -67,7 +67,7 @@
|
|||
<!-- Reviewing the question. -->
|
||||
<ng-container *ngIf="review">
|
||||
<!-- Answer to the question and attachments (reviewing). -->
|
||||
<ion-item class="ion-text-wrap" *ngIf="question.answer || question.answer == ''">
|
||||
<ion-item class="ion-text-wrap" *ngIf="question.answer || question.answer === ''">
|
||||
<ion-label>
|
||||
<core-format-text [ngClass]='{"core-monospaced": question.isMonospaced}' [component]="component" [componentId]="componentId"
|
||||
[text]="question.answer" [contextLevel]="contextLevel" [contextInstanceId]="contextInstanceId" [courseId]="courseId">
|
||||
|
|
|
@ -1,16 +1,16 @@
|
|||
<ion-button (click)="openSelect($event)" *ngIf="interface != 'modal' && icon" [disabled]="disabled">
|
||||
<ion-button (click)="openSelect($event)" *ngIf="interface !== 'modal' && icon" [disabled]="disabled">
|
||||
<ion-icon [name]="icon" [attr.aria-label]="label" slot="start">
|
||||
</ion-icon>
|
||||
<div class="select-icon" role="presentation" aria-hidden="true">
|
||||
<div class="select-icon-inner"></div>
|
||||
</div>
|
||||
</ion-button>
|
||||
<ion-select *ngIf="interface != 'modal'" class="ion-text-start" [(ngModel)]="selection" (ngModelChange)="onValueChanged(selection)"
|
||||
<ion-select *ngIf="interface !== 'modal'" class="ion-text-start" [(ngModel)]="selection" (ngModelChange)="onValueChanged(selection)"
|
||||
[interface]="interface" [attr.aria-label]="label + ': ' + selection" [disabled]="disabled" [hidden]="!!icon">
|
||||
<ng-content></ng-content>
|
||||
</ion-select>
|
||||
|
||||
<ion-button *ngIf="interface == 'modal'" aria-haspopup="listbox" [attr.aria-controls]="listboxId" [attr.aria-owns]="listboxId"
|
||||
<ion-button *ngIf="interface === 'modal'" aria-haspopup="listbox" [attr.aria-controls]="listboxId" [attr.aria-owns]="listboxId"
|
||||
[attr.aria-expanded]="expanded" (click)="openSelect()" [disabled]="disabled" expand="block" role="combobox">
|
||||
<ion-icon *ngIf="icon" [name]="icon" slot="start" aria-hidden="true"></ion-icon>
|
||||
<span class="sr-only" *ngIf="label">{{ label }}:</span>
|
||||
|
|
|
@ -13,12 +13,12 @@
|
|||
</p>
|
||||
</ion-label>
|
||||
<ng-container *ngIf="(item.href || item.action) && item.iconAction">
|
||||
<ion-icon *ngIf="item.iconAction != 'spinner' && item.iconAction != 'toggle'" [name]="item.iconAction"
|
||||
<ion-icon *ngIf="item.iconAction !== 'spinner' && item.iconAction !== 'toggle'" [name]="item.iconAction"
|
||||
[class.icon-slash]="item.iconSlash" slot="end" aria-hidden="true">
|
||||
</ion-icon>
|
||||
<ion-spinner *ngIf="item.iconAction == 'spinner'" slot="end" [attr.aria-label]="'core.loading' | translate">
|
||||
<ion-spinner *ngIf="item.iconAction === 'spinner'" slot="end" [attr.aria-label]="'core.loading' | translate">
|
||||
</ion-spinner>
|
||||
<ion-toggle *ngIf="item.iconAction == 'toggle'" [(ngModel)]="item.toggle" (ionChange)="item.toggleChanged($event)"
|
||||
<ion-toggle *ngIf="item.iconAction === 'toggle'" [(ngModel)]="item.toggle" (ionChange)="item.toggleChanged($event)"
|
||||
slot="end">
|
||||
</ion-toggle>
|
||||
</ng-container>
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
<ng-container *ngIf="!loadingMore && position != 'top'">
|
||||
<ng-container *ngIf="!loadingMore && position !== 'top'">
|
||||
<div *ngIf="enabled || error" class="ion-padding-horizontal" #bottombutton>
|
||||
<ion-button *ngIf="!error" expand="block" (click)="loadMore()" fill="outline">
|
||||
{{ 'core.loadmore' | translate }}
|
||||
|
@ -13,7 +13,7 @@
|
|||
<ion-infinite-scroll-content></ion-infinite-scroll-content>
|
||||
</ion-infinite-scroll>
|
||||
|
||||
<ng-container *ngIf="!loadingMore && position == 'top'">
|
||||
<ng-container *ngIf="!loadingMore && position === 'top'">
|
||||
<div *ngIf="enabled || error" class="ion-padding-horizontal" #topbutton>
|
||||
<ion-button *ngIf="!error" expand="block" (click)="loadMore()" fill="outline">
|
||||
{{ 'core.loadmore' | translate }}
|
||||
|
|
|
@ -3,10 +3,10 @@
|
|||
<ng-container *ngFor="let error of errorKeys">
|
||||
<div *ngIf="control.hasError(error)" class="core-input-error">
|
||||
<span *ngIf="errorMessages && errorMessages[error]">{{errorMessages[error]}}</span>
|
||||
<span *ngIf="(!errorMessages || !errorMessages[error]) && error == 'max' && control.errors?.max">
|
||||
<span *ngIf="(!errorMessages || !errorMessages[error]) && error === 'max' && control.errors?.max">
|
||||
{{ 'core.login.invalidvaluemax' | translate:{$a: control.errors!.max.max} }}
|
||||
</span>
|
||||
<span *ngIf="(!errorMessages || !errorMessages[error]) && error == 'min' && control.errors?.min">
|
||||
<span *ngIf="(!errorMessages || !errorMessages[error]) && error === 'min' && control.errors?.min">
|
||||
{{ 'core.login.invalidvaluemin' | translate:{$a: control.errors!.min.min} }}
|
||||
</span>
|
||||
</div>
|
||||
|
|
|
@ -7,11 +7,11 @@
|
|||
</ion-button>
|
||||
<ion-slides [options]="slidesOpts" [dir]="direction" role="tablist" [attr.aria-label]="description">
|
||||
<ng-container *ngFor="let tab of tabs">
|
||||
<ion-slide *ngIf="tab.enabled" role="presentation" [id]="tab.id! + '-tab'" [class.selected]="selected == tab.id"
|
||||
<ion-slide *ngIf="tab.enabled" role="presentation" [id]="tab.id! + '-tab'" [class.selected]="selected === tab.id"
|
||||
class="{{tab.class}}">
|
||||
<ion-tab-button (click)="selectTab(tab.id, $event)" (keydown)="tabAction.keyDown(tab.id, $event)"
|
||||
(keyup)="tabAction.keyUp(tab.id, $event)" [layout]="layout" role="tab" [attr.aria-controls]="tab.id"
|
||||
[attr.aria-selected]="selected == tab.id" [tabindex]="selected == tab.id ? 0 : -1">
|
||||
[attr.aria-selected]="selected === tab.id" [tabindex]="selected === tab.id ? 0 : -1">
|
||||
<ion-icon *ngIf="tab.icon" [name]="tab.icon" aria-hidden="true"></ion-icon>
|
||||
<ion-label>
|
||||
<h2>{{ tab.title | translate}}</h2>
|
||||
|
|
|
@ -80,8 +80,8 @@
|
|||
<p class="item-heading" *ngIf="grade.itemmodule">
|
||||
{{ 'core.grades.grade' | translate }}
|
||||
</p>
|
||||
<p *ngIf="grade.grade && grade.grade != '-'" [innerHTML]="grade.grade"></p>
|
||||
<ion-badge *ngIf="!grade.grade || grade.grade == '-'" color="light">
|
||||
<p *ngIf="grade.grade && grade.grade !== '-'" [innerHTML]="grade.grade"></p>
|
||||
<ion-badge *ngIf="!grade.grade || grade.grade === '-'" color="light">
|
||||
{{ 'core.grades.notgraded' | translate }}
|
||||
</ion-badge>
|
||||
</ion-label>
|
||||
|
@ -92,48 +92,48 @@
|
|||
</ion-icon>
|
||||
</ion-item>
|
||||
<div *ngIf="grade.expanded" [id]="'grade-'+grade.id">
|
||||
<ion-item class="ion-text-wrap" *ngIf="grade.weight?.length > 0 && grade.weight != '-'">
|
||||
<ion-item class="ion-text-wrap" *ngIf="grade.weight?.length > 0 && grade.weight !== '-'">
|
||||
<ion-label>
|
||||
<p class="item-heading">{{ 'core.grades.weight' | translate}}</p>
|
||||
<p [innerHTML]="grade.weight"></p>
|
||||
</ion-label>
|
||||
</ion-item>
|
||||
<ion-item class="ion-text-wrap" *ngIf="grade.range?.length > 0 && grade.range != '-'">
|
||||
<ion-item class="ion-text-wrap" *ngIf="grade.range?.length > 0 && grade.range !== '-'">
|
||||
<ion-label>
|
||||
<p class="item-heading">{{ 'core.grades.range' | translate}}</p>
|
||||
<p [innerHTML]="grade.range"></p>
|
||||
</ion-label>
|
||||
</ion-item>
|
||||
|
||||
<ion-item class="ion-text-wrap" *ngIf="grade.percentage?.length > 0 && grade.percentage != '-'">
|
||||
<ion-item class="ion-text-wrap" *ngIf="grade.percentage?.length > 0 && grade.percentage !== '-'">
|
||||
<ion-label>
|
||||
<p class="item-heading">{{ 'core.grades.percentage' | translate}}</p>
|
||||
<p [innerHTML]="grade.percentage"></p>
|
||||
</ion-label>
|
||||
</ion-item>
|
||||
|
||||
<ion-item class="ion-text-wrap" *ngIf="grade.lettergrade?.length > 0 && grade.lettergrade != '-'">
|
||||
<ion-item class="ion-text-wrap" *ngIf="grade.lettergrade?.length > 0 && grade.lettergrade !== '-'">
|
||||
<ion-label>
|
||||
<p class="item-heading">{{ 'core.grades.lettergrade' | translate}}</p>
|
||||
<p [innerHTML]="grade.lettergrade"></p>
|
||||
</ion-label>
|
||||
</ion-item>
|
||||
|
||||
<ion-item class="ion-text-wrap" *ngIf="grade.rank?.length > 0 && grade.rank != '-'">
|
||||
<ion-item class="ion-text-wrap" *ngIf="grade.rank?.length > 0 && grade.rank !== '-'">
|
||||
<ion-label>
|
||||
<p class="item-heading">{{ 'core.grades.rank' | translate}}</p>
|
||||
<p [innerHTML]="grade.rank"></p>
|
||||
</ion-label>
|
||||
</ion-item>
|
||||
|
||||
<ion-item class="ion-text-wrap" *ngIf="grade.average?.length > 0 && grade.average != '-'">
|
||||
<ion-item class="ion-text-wrap" *ngIf="grade.average?.length > 0 && grade.average !== '-'">
|
||||
<ion-label>
|
||||
<p class="item-heading">{{ 'core.grades.average' | translate}}</p>
|
||||
<p [innerHTML]="grade.average"></p>
|
||||
</ion-label>
|
||||
</ion-item>
|
||||
|
||||
<ion-item class="ion-text-wrap" *ngIf="grade.feedback?.length > 0 && grade.feedback != '-'">
|
||||
<ion-item class="ion-text-wrap" *ngIf="grade.feedback?.length > 0 && grade.feedback !== '-'">
|
||||
<ion-label>
|
||||
<p class="item-heading">{{ 'core.grades.feedback' | translate}}</p>
|
||||
<p>
|
||||
|
@ -145,7 +145,7 @@
|
|||
</ion-item>
|
||||
|
||||
<ion-item class="ion-text-wrap"
|
||||
*ngIf="grade.contributiontocoursetotal?.length > 0 && grade.contributiontocoursetotal != '-'">
|
||||
*ngIf="grade.contributiontocoursetotal?.length > 0 && grade.contributiontocoursetotal !== '-'">
|
||||
<ion-label>
|
||||
<p class="item-heading">{{ 'core.grades.contributiontocoursetotal' | translate}}</p>
|
||||
<p [innerHTML]="grade.contributiontocoursetotal"></p>
|
||||
|
|
|
@ -116,7 +116,7 @@
|
|||
<span class="core-customfieldseparator">: </span>
|
||||
</span>
|
||||
<span class="core-customfieldvalue">
|
||||
<core-format-text [text]="field.value" [collapsible-item]="field.type == 'textarea' ? '' : null"
|
||||
<core-format-text [text]="field.value" [collapsible-item]="field.type === 'textarea' ? '' : null"
|
||||
contextLevel="course" [contextInstanceId]="course.id">
|
||||
</core-format-text>
|
||||
</span>
|
||||
|
|
|
@ -1,14 +1,14 @@
|
|||
<ion-card [class.core-course-list-item]="layout == 'list' || layout == 'listwithenrol'"
|
||||
[class.core-course-list-card]="layout == 'card' || layout == 'summarycard'" [class.item-dimmed]="course.hidden" (click)="openCourse()"
|
||||
<ion-card [class.core-course-list-item]="layout === 'list' || layout === 'listwithenrol'"
|
||||
[class.core-course-list-card]="layout === 'card' || layout === 'summarycard'" [class.item-dimmed]="course.hidden" (click)="openCourse()"
|
||||
button [attr.aria-label]="course.displayname || course.fullname">
|
||||
|
||||
<div *ngIf="layout == 'card' || layout == 'summarycard'" class="core-course-thumb" [class.core-course-color-img]="course.courseimage">
|
||||
<div *ngIf="layout === 'card' || layout === 'summarycard'" class="core-course-thumb" [class.core-course-color-img]="course.courseimage">
|
||||
<img *ngIf="course.courseimage" [src]="course.courseimage" core-external-content alt="" (error)="loadFallbackCourseIcon()" />
|
||||
<ion-icon *ngIf="!course.courseimage" name="fas-graduation-cap" class="course-icon" aria-hidden="true">
|
||||
</ion-icon>
|
||||
</div>
|
||||
|
||||
<ng-container *ngIf="isEnrolled && layout != 'summarycard'">
|
||||
<ng-container *ngIf="isEnrolled && layout !== 'summarycard'">
|
||||
<div class="core-button-spinner" *ngIf="!courseOptionMenuEnabled && showDownload">
|
||||
<core-download-refresh [status]="prefetchCourseData.status" [enabled]="showDownload"
|
||||
[statusTranslatable]="prefetchCourseData.statusTranslatable" [canTrustDownload]="false"
|
||||
|
@ -29,7 +29,7 @@
|
|||
|
||||
<ion-item class="ion-text-wrap">
|
||||
|
||||
<ng-container *ngIf="layout == 'list' || layout == 'listwithenrol'">
|
||||
<ng-container *ngIf="layout === 'list' || layout === 'listwithenrol'">
|
||||
<ion-icon *ngIf="!course.courseimage" name="fas-graduation-cap" slot="start" class="course-icon core-course-thumb"
|
||||
aria-hidden="true">
|
||||
</ion-icon>
|
||||
|
@ -55,7 +55,7 @@
|
|||
<core-format-text [text]="course.fullname" contextLevel="course" [contextInstanceId]="course.id">
|
||||
</core-format-text>
|
||||
|
||||
<span *ngIf="(layout == 'list' || layout == 'listwithenrol') && !isEnrolled" class="core-course-enrol-icons">
|
||||
<span *ngIf="(layout === 'list' || layout === 'listwithenrol') && !isEnrolled" class="core-course-enrol-icons">
|
||||
<ion-icon *ngFor="let icon of enrolmentIcons" color="medium" [name]="icon.icon" [title]="icon.label | translate"
|
||||
[attr.aria-label]="icon.label | translate" [ngClass]="[icon.className]">
|
||||
</ion-icon>
|
||||
|
@ -82,7 +82,7 @@
|
|||
</ion-chip>
|
||||
</div>
|
||||
|
||||
<div *ngIf="layout != 'summarycard' && isEnrolled && progress >= 0 && completionUserTracked !== false"
|
||||
<div *ngIf="layout !== 'summarycard' && isEnrolled && progress >= 0 && completionUserTracked !== false"
|
||||
class="core-course-progress">
|
||||
<core-progress-bar [progress]="progress" a11yText="core.courses.aria:courseprogress"></core-progress-bar>
|
||||
</div>
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
</ion-label>
|
||||
</ion-item>
|
||||
<ion-item button class="ion-text-wrap" (click)="action('delete')" detail="false"
|
||||
*ngIf="prefetch.status == 'downloaded' || prefetch.status == 'outdated'">
|
||||
*ngIf="prefetch.status === 'downloaded' || prefetch.status === 'outdated'">
|
||||
<ion-icon name="fas-trash" slot="start" aria-hidden="true"></ion-icon>
|
||||
<ion-label>
|
||||
<p class="item-heading">{{ 'addon.storagemanager.deletedata' | translate }}</p>
|
||||
|
|
|
@ -37,7 +37,7 @@
|
|||
[class.core-grades-grade-clickable]="row.expandable && showSummary" [id]="'grade-'+row.id"
|
||||
*ngIf="row.itemtype !== 'leader'">
|
||||
<ng-container *ngIf="row.itemtype">
|
||||
<td *ngIf="row.itemtype == 'category'" class="core-grades-table-category" [attr.rowspan]="row.rowspan">
|
||||
<td *ngIf="row.itemtype === 'category'" class="core-grades-table-category" [attr.rowspan]="row.rowspan">
|
||||
</td>
|
||||
<th class="core-grades-table-gradeitem ion-text-start" [attr.colspan]="row.colspan">
|
||||
<ion-icon *ngIf="row.expandable && showSummary" aria-hidden="true" slot="start" name="fas-chevron-right"
|
||||
|
|
|
@ -26,7 +26,7 @@
|
|||
</core-format-text>
|
||||
</ion-label>
|
||||
<ion-badge slot="end" color="light">
|
||||
<span class="sr-only" *ngIf="course.grade && course.grade != '-'">
|
||||
<span class="sr-only" *ngIf="course.grade && course.grade !== '-'">
|
||||
{{ 'core.grades.grade' | translate }}
|
||||
</span>
|
||||
{{course.grade}}
|
||||
|
|
|
@ -22,7 +22,7 @@
|
|||
</div>
|
||||
<form [formGroup]="siteForm" (ngSubmit)="connect(siteForm.value.siteUrl, $event)" *ngIf="!fixedSites && siteForm" #siteFormEl>
|
||||
<!-- Form to input the site URL if there are no fixed sites. -->
|
||||
<ng-container *ngIf=" siteSelector=='url'">
|
||||
<ng-container *ngIf=" siteSelector==='url'">
|
||||
<ion-item>
|
||||
<ion-label position=" stacked">
|
||||
<h2>{{ 'core.login.siteaddress' | translate }}</h2>
|
||||
|
@ -32,7 +32,7 @@
|
|||
</ion-input>
|
||||
</ion-item>
|
||||
</ng-container>
|
||||
<ng-container *ngIf="siteSelector != 'url'">
|
||||
<ng-container *ngIf="siteSelector !== 'url'">
|
||||
<ion-item>
|
||||
<ion-label position="stacked">
|
||||
<h2>{{ 'core.login.siteaddress' | translate }}</h2>
|
||||
|
@ -74,7 +74,7 @@
|
|||
</div>
|
||||
</ng-container>
|
||||
|
||||
<ion-item *ngIf="siteSelector == 'url'">
|
||||
<ion-item *ngIf="siteSelector === 'url'">
|
||||
<ion-label>
|
||||
<ion-button expand="block" [disabled]="!siteForm.valid" class="ion-text-wrap" type="submit">
|
||||
{{ 'core.login.connect' | translate }}
|
||||
|
@ -85,7 +85,7 @@
|
|||
|
||||
<ng-container *ngIf="fixedSites">
|
||||
<!-- Pick the site from a list of fixed sites. -->
|
||||
<ion-list *ngIf="siteSelector == 'list'">
|
||||
<ion-list *ngIf="siteSelector === 'list'">
|
||||
<ion-item>
|
||||
<ion-label>
|
||||
<h2 class="item-heading">{{ 'core.login.selectsite' | translate }}</h2>
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
<ion-tabs #mainTabs [hidden]="!showTabs" [class]="'placement-' + tabsPlacement"
|
||||
[class.tabshidden]="!isMainScreen && tabsPlacement == 'bottom'" (ionTabsDidChange)="tabChanged($event)">
|
||||
[class.tabshidden]="!isMainScreen && tabsPlacement === 'bottom'" (ionTabsDidChange)="tabChanged($event)">
|
||||
<ion-tab-bar slot="bottom" class="mainmenu-tabs" [@menuVisibilityAnimation]="visibility">
|
||||
<ion-spinner *ngIf="!loaded" [attr.aria-label]="'core.loading' | translate"></ion-spinner>
|
||||
|
||||
<core-user-menu-button *ngIf="loaded && tabsPlacement == 'side'" [alwaysShow]="true"></core-user-menu-button>
|
||||
<core-user-menu-button *ngIf="loaded && tabsPlacement === 'side'" [alwaysShow]="true"></core-user-menu-button>
|
||||
|
||||
<ion-tab-button *ngFor="let tab of tabs" (keydown)="tabAction.keyDown(tab.page, $event)" (keyup)="tabAction.keyUp(tab.page, $event)"
|
||||
[hidden]="!loaded && tab.hide" [tab]="tab.page" [disabled]="tab.hide" layout="label-hide" class="{{tab.class}}"
|
||||
|
|
|
@ -36,15 +36,15 @@
|
|||
</ion-spinner>
|
||||
</ion-item>
|
||||
<ng-container *ngFor="let item of customItems">
|
||||
<ion-item button *ngIf="item.type != 'embedded'" [href]="item.url" [attr.aria-label]="item.label" core-link
|
||||
[capture]="item.type == 'app'" [inApp]="item.type == 'inappbrowser'" class="core-moremenu-customitem" detail="true"
|
||||
[detailIcon]="item.type == 'browser' ? 'open-outline' : 'chevron-forward'">
|
||||
<ion-item button *ngIf="item.type !== 'embedded'" [href]="item.url" [attr.aria-label]="item.label" core-link
|
||||
[capture]="item.type === 'app'" [inApp]="item.type === 'inappbrowser'" class="core-moremenu-customitem" detail="true"
|
||||
[detailIcon]="item.type === 'browser' ? 'open-outline' : 'chevron-forward'">
|
||||
<ion-icon [name]="item.icon" slot="start" aria-hidden="true"></ion-icon>
|
||||
<ion-label>
|
||||
<p class="item-heading">{{item.label}}</p>
|
||||
</ion-label>
|
||||
</ion-item>
|
||||
<ion-item button *ngIf="item.type == 'embedded'" (click)="openItem(item)" [attr.aria-label]="item.label"
|
||||
<ion-item button *ngIf="item.type === 'embedded'" (click)="openItem(item)" [attr.aria-label]="item.label"
|
||||
class="core-moremenu-customitem" detail="true">
|
||||
<ion-icon [name]="item.icon" slot="start" aria-hidden="true"></ion-icon>
|
||||
<ion-label>
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
<ion-icon name="fas-magnifying-glass" slot="icon-only" aria-hidden="true"></ion-icon>
|
||||
</ion-button>
|
||||
<ion-button *ngIf="showClear" slot="end" fill="clear" [attr.aria-label]="'core.clearsearch' | translate"
|
||||
[disabled]="searched == '' || disabled" (click)="clearForm()">
|
||||
[disabled]="searched === '' || disabled" (click)="clearForm()">
|
||||
<ion-icon name="fas-delete-left" slot="icon-only" aria-hidden="true" flip-rtl></ion-icon>
|
||||
</ion-button>
|
||||
</ion-item>
|
||||
|
|
|
@ -47,7 +47,7 @@
|
|||
{{ 'core.settings.colorscheme-' + scheme | translate }}</ion-select-option>
|
||||
</ion-select>
|
||||
</ion-item>
|
||||
<ion-item *ngIf="colorSchemes.length> 0 && selectedScheme=='system' && isAndroid" lines="none">
|
||||
<ion-item *ngIf="colorSchemes.length> 0 && selectedScheme==='system' && isAndroid" lines="none">
|
||||
<ion-label class="ion-text-wrap">
|
||||
<p>{{ 'core.settings.colorscheme-system-notice' | translate }}</p>
|
||||
</ion-label>
|
||||
|
|
|
@ -21,7 +21,7 @@
|
|||
<ion-label class="ion-text-wrap">{{ 'core.tag.warningareasnotsupported' | translate }}</ion-label>
|
||||
</ion-item>
|
||||
<ion-item class="ion-text-wrap" *ngFor="let area of areas" [attr.aria-label]="area.nameKey | translate"
|
||||
(click)="openArea(area)" [attr.aria-current]="area.id == selectedAreaId ? 'page' : 'false'" button detail="true">
|
||||
(click)="openArea(area)" [attr.aria-current]="area.id === selectedAreaId ? 'page' : 'false'" button detail="true">
|
||||
<ion-label>
|
||||
<p class="item-heading">{{ area.nameKey | translate }}</p>
|
||||
</ion-label>
|
||||
|
|
|
@ -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.
|
||||
|
|
Loading…
Reference in New Issue