diff --git a/src/assets/styles/_helper.scss b/src/assets/styles/_helper.scss index d22e9d0c1..07c5bfcbf 100644 --- a/src/assets/styles/_helper.scss +++ b/src/assets/styles/_helper.scss @@ -80,6 +80,9 @@ .MR5{ margin-right: 5px; } +.MR4{ + @include margin(null, 4px, null, null); +} .MR6{ @include margin(null, 6px, null, null); @@ -89,6 +92,11 @@ @include margin(null, 10px, null, null); } + +.MR12{ + @include margin(null, 12px, null, null); +} + .MR15{ @include margin(null, 15px, null, null); } @@ -217,7 +225,7 @@ } .PR10{ - padding-right: 10px; + @include padding(null, 10px, null, null) } .PR15{ diff --git a/src/component/card/resource/resource-card.html b/src/component/card/resource/resource-card.html index 6c08463a4..7a03142d6 100644 --- a/src/component/card/resource/resource-card.html +++ b/src/component/card/resource/resource-card.html @@ -3,7 +3,7 @@
- +
@@ -13,7 +13,7 @@
{{course?.gradeLevel}} - + {{course?.subject}}
diff --git a/src/component/card/resource/resource-card.scss b/src/component/card/resource/resource-card.scss index 3bf6c42b8..1bfc37be6 100644 --- a/src/component/card/resource/resource-card.scss +++ b/src/component/card/resource/resource-card.scss @@ -1,124 +1,119 @@ - - .resource-card{ - box-shadow: none; - } - .app-icon{ - width:100%; - min-height:70px; - max-height:70px; +.resource-card{ + box-shadow: none; +} +.custom.card { + width: 282px; + border-radius: 2px; + height: 80px; + // box-shadow: 0 3px 5px 0 rgba(0, 0, 0, 0.12); + grid-gap: 13px; + background-color: #fff; + &.saved { + border-radius: 2px; + background-color: rgba(0, 136, 68, 0.1); + border: 0.5px solid #008844; } - .custom.card { - width: 282px; + &.recent { border-radius: 2px; - height: 80px; - // box-shadow: 0 3px 5px 0 rgba(0, 0, 0, 0.12); - grid-gap: 13px; - background-color: #fff; - &.saved { - border-radius: 2px; - background-color: rgba(0, 136, 68, 0.1); - border: 0.5px solid #008844; + background-color: rgba(2, 79, 157, 0.1); + border: 0.5px solid #024f9d; + } + @include margin(0, 16px, 0, 0); + @include padding(15px, 16px); + display: grid; + grid-template-columns: 1fr 2.9fr; + &.about{ + display: block; + ion-label{ + margin-bottom: 1px; + font-size: 12px; + font-weight: bold; + font-style: normal; + font-stretch: normal; + line-height: normal; + letter-spacing: -0.4px; + color: #a4a4a4; } - &.recent { - border-radius: 2px; - background-color: rgba(2, 79, 157, 0.1); - border: 0.5px solid #024f9d; + p{ + margin-top: 0; + font-size: 14px; + font-weight: normal; + font-style: normal; + font-stretch: normal; + line-height: normal; + letter-spacing: -0.4px; + color: #000000; } - @include margin(0, 16px, 0, 0); - @include padding(15px, 16px); + } + // &:first-child { + // @include margin(null, null, null, 21px !important); + // } + // &:last-child { + // @include margin(null, 16px, null, null !important); + // } + .left { + overflow:hidden; display: grid; - grid-template-columns: 1fr 2.9fr; - &.about{ - display: block; - ion-label{ - margin-bottom: 1px; - font-size: 12px; - font-weight: bold; - font-style: normal; - font-stretch: normal; - line-height: normal; - letter-spacing: -0.4px; - color: #a4a4a4; - } - p{ - margin-top: 0; - font-size: 14px; - font-weight: normal; - font-style: normal; - font-stretch: normal; - line-height: normal; - letter-spacing: -0.4px; - color: #000000; - } - } - // &:first-child { - // @include margin(null, null, null, 21px !important); - // } - // &:last-child { - // @include margin(null, 16px, null, null !important); - // } - .left { - overflow:hidden; - display: grid; - grid-template-columns: 1fr; - grid-template-rows: 1fr; + grid-template-columns: 1fr; + grid-template-rows: 1fr; - .img-container { - background-color: grey; - width:100%; - min-height:70px; - } + .img-container { + background-color: grey; + width:100%; + width: 56px; + height: 56px; } - .right { - overflow:hidden; - display: grid; - grid-template-columns: 1fr; - grid-template-rows: 1fr; + } + .right { + overflow:hidden; + display: grid; + grid-template-columns: 1fr; + grid-template-rows: 1fr; - .title { - width:100%; - overflow:hidden; - text-overflow: ellipsis; - display: -webkit-box; - -webkit-line-clamp: 2; - -webkit-box-orient: vertical; - margin:0; - margin-bottom: 3px; - padding:0; - font-weight: 500; - font-style: normal; - font-stretch: normal; - line-height: normal; - letter-spacing: -0.4px; - color: #333333; - } - .info{ - font-size: 12px; - font-weight: 500; - font-style: normal; - font-stretch: normal; - line-height: normal; - letter-spacing: -0.4px; - color: #979797; - } + .title { + width:100%; + overflow:hidden; + text-overflow: ellipsis; + display: -webkit-box; + -webkit-line-clamp: 2; + -webkit-box-orient: vertical; + margin:0; + margin-bottom: 3px; + padding:0; + font-weight: 500; + font-style: normal; + font-stretch: normal; + line-height: normal; + letter-spacing: -0.4px; + color: #333333; } + .info{ + font-size: 12px; + font-weight: 500; + font-style: normal; + font-stretch: normal; + line-height: normal; + letter-spacing: -0.4px; + color: #979797; + } + } - &.offline{ - .left{ - margin: -16px 0 -15px -16px; + &.offline{ + .left{ + margin: -16px 0 -15px -16px; - .img-container { - display: flex; - align-items: center; - background-color: map-get($colors, danger); - .icon{ - margin: auto; - font-size: 25px; - } + .img-container { + display: flex; + align-items: center; + background-color: map-get($colors, danger); + .icon{ + margin: auto; + font-size: 25px; } } - .right{ - opacity: 0.5; - } + } + .right{ + opacity: 0.5; } } +} diff --git a/src/pages/profile/personal-details-edit.profile/personal-details-edit.profile.html b/src/pages/profile/personal-details-edit.profile/personal-details-edit.profile.html index bf67b4b4c..5afce4ee9 100644 --- a/src/pages/profile/personal-details-edit.profile/personal-details-edit.profile.html +++ b/src/pages/profile/personal-details-edit.profile/personal-details-edit.profile.html @@ -14,7 +14,7 @@ {{'ERROR_NAME_INVALID' | translate}}
+ (ionChange)="enableSubmitButton();" dir="{{commonUtilService.getAppDirection()}}"> {{'STATE' | translate}} diff --git a/src/pages/resources/resources.html b/src/pages/resources/resources.html index 62f1088e6..d6b1fd9e2 100644 --- a/src/pages/resources/resources.html +++ b/src/pages/resources/resources.html @@ -20,12 +20,12 @@ -
- {{medium?.name}} Medium + -
- + {{grade?.name}} @@ -96,7 +96,7 @@
{{item?.gradeLevel}} - + {{item?.subject}}
diff --git a/src/pages/resources/resources.scss b/src/pages/resources/resources.scss index 5debd2417..30f10ccf8 100644 --- a/src/pages/resources/resources.scss +++ b/src/pages/resources/resources.scss @@ -105,8 +105,9 @@ page-resources { .scroll-heading { padding-top: 10px; @extend .NotoSans-bold; - font-size: 1.350em; width: 60%; + color: #333333; + font-size: 16px; } .view-all-link { font-size: 1.2rem; @@ -196,7 +197,7 @@ page-resources { } .medium-pill { - min-width: 120px; + min-width: 106px; // height: 30px; height: 100%; // border-radius: 2px !important; @@ -232,10 +233,10 @@ page-resources { .class-filter-cotainer { box-shadow: 0 2px 4px 0 rgba(0, 0, 0, 0.2); background-color: #f4f4f4; + margin-bottom: 4px; } - .class-pill { - min-width: 75px; + min-width: 47px; // height: 30px; // border-radius: 15px !important; // box-shadow: 0 3px 4px 0 rgba(0, 0, 0, 0.12); @@ -256,25 +257,23 @@ page-resources { // box-shadow: 0 3px 4px 0 rgba(0, 0, 0, 0.19); // background-color: #024f9d; // color: #ffffff; - opacity: 1; + opacity: 1.5; } &:last-child { @include margin(0, 30, 0, 0); } } - .app-icon{ - width:100%; - height:50px; - } .section-solid{ + background-color: #ffffff; .heading{ - font-size: 18px; + font-size: 16px; font-weight: bold; font-style: normal; font-stretch: normal; line-height: normal; letter-spacing: -0.5px; - color: #024f9d; + color: #333333; + padding-bottom: 4px; } .card-container { width:100%; @@ -318,10 +317,9 @@ page-resources { grid-template-columns: 1fr; grid-template-rows: 1fr; .img-container { - background-color: grey; - width:100%; - min-height:70px; - max-height:70px; + background-color: #d8d8d8; + width: 56px; + height: 56px; } } .right { @@ -359,6 +357,4 @@ page-resources { } } } -} - - +} \ No newline at end of file diff --git a/src/pages/resources/resources.ts b/src/pages/resources/resources.ts index 1abe1abcb..0090492df 100644 --- a/src/pages/resources/resources.ts +++ b/src/pages/resources/resources.ts @@ -433,14 +433,10 @@ export class ResourcesPage implements OnInit, AfterViewInit { } console.log('pageAssembleCriteria', contentSearchCriteria); // swipe down to refresh should not over write current selected options - if (this.currentGrade && this.currentGrade.name) { - this.getGroupByPageReq.grade = [this.currentGrade.name]; - } else if (contentSearchCriteria.grade) { + if (contentSearchCriteria.grade) { this.getGroupByPageReq.grade = [contentSearchCriteria.grade[0]]; } - if (this.currentMedium) { - this.getGroupByPageReq.medium = [this.currentMedium]; - } else if (contentSearchCriteria.medium) { + if (contentSearchCriteria.medium) { this.getGroupByPageReq.medium = [contentSearchCriteria.medium[0]]; } if (contentSearchCriteria.board) { @@ -636,6 +632,7 @@ export class ResourcesPage implements OnInit, AfterViewInit { } this.getPopularContent(false); + this.getCategoryData(); } @@ -718,7 +715,7 @@ export class ResourcesPage implements OnInit, AfterViewInit { for (let i = 0, len = this.categoryMediums.length; i < len; i++) { if (this.getGroupByPageReq.medium[0].toLowerCase().trim() === this.categoryMediums[i].name.toLowerCase().trim() ) { - this.mediumClick(i); + this.mediumClick(this.categoryMediums[i].name); } } } @@ -792,21 +789,20 @@ export class ResourcesPage implements OnInit, AfterViewInit { } document.getElementById('gradeScroll').scrollTo({top: 0, left: index * 75, behavior: 'smooth'}); } - mediumClick(index) { - this.getGroupByPageReq.medium = [this.categoryMediums[index].name]; - if ( this.currentMedium !== this.categoryMediums[index].name) { + mediumClick(mediumName: string) { + this.getGroupByPageReq.medium = [mediumName]; + if ( this.currentMedium !== mediumName) { this.getGroupByPage(); } for (let i = 0, len = this.categoryMediums.length; i < len; i++) { - if (i === index ) { - this.currentMedium = this.categoryMediums[index].name; + if (this.categoryMediums[i].name === mediumName ) { + this.currentMedium = this.categoryMediums[i].name; this.categoryMediums[i].selected = true; } else { this.categoryMediums[i].selected = false; } } - console.log('medium', this.categoryMediums[index]); } navigateToDetailPage(item, index, sectionName) { diff --git a/src/pages/search/filters/filter.ts b/src/pages/search/filters/filter.ts index c47a38d4d..2f6a12788 100644 --- a/src/pages/search/filters/filter.ts +++ b/src/pages/search/filters/filter.ts @@ -3,6 +3,7 @@ import { NavParams, PopoverController, NavController, Events, Platform } from 'i import { CommonUtilService } from '../../../service/common-util.service'; import * as _ from 'lodash'; import { FilterOptions } from './options/options'; +import { IonicApp } from 'ionic-angular'; @Component({ selector: 'page-filter', @@ -22,7 +23,8 @@ export class FilterPage { private navCtrl: NavController, private events: Events, private commonUtilService: CommonUtilService, - private platform: Platform + private platform: Platform, + private ionicApp: IonicApp ) { this.init(); this.handleBackButton(); @@ -105,7 +107,13 @@ export class FilterPage { */ handleBackButton() { this.unregisterBackButton = this.platform.registerBackButtonAction(() => { - this.navCtrl.pop(); + const activePortal = this.ionicApp._modalPortal.getActive() || + this.ionicApp._toastPortal.getActive() || this.ionicApp._overlayPortal.getActive(); + if (activePortal) { + activePortal.dismiss(); + } else if (this.navCtrl.canGoBack()) { + this.navCtrl.pop(); + } this.unregisterBackButton(); }, 11); } diff --git a/src/pages/user-and-groups/add-or-remove-group-user/add-or-remove-group-user.ts b/src/pages/user-and-groups/add-or-remove-group-user/add-or-remove-group-user.ts index 72ca22c75..5917c7e17 100644 --- a/src/pages/user-and-groups/add-or-remove-group-user/add-or-remove-group-user.ts +++ b/src/pages/user-and-groups/add-or-remove-group-user/add-or-remove-group-user.ts @@ -238,7 +238,7 @@ export class AddOrRemoveGroupUserPage { } }, { - text: this.commonUtilService.translateMessage('Yes'), + text: this.commonUtilService.translateMessage('YES'), cssClass: 'alert-btn-delete', handler: () => { this.deleteUsersFromGroup(); diff --git a/src/pages/user-and-groups/group-details/group-details.ts b/src/pages/user-and-groups/group-details/group-details.ts index a4be9e999..6246f578f 100644 --- a/src/pages/user-and-groups/group-details/group-details.ts +++ b/src/pages/user-and-groups/group-details/group-details.ts @@ -372,7 +372,7 @@ export class GroupDetailsPage { } }, { - text: this.translateMessage('Yes'), + text: this.translateMessage('YES'), cssClass: 'alert-btn-delete', handler: () => { this.deleteGroup(); @@ -424,7 +424,7 @@ export class GroupDetailsPage { } }, { - text: this.translateMessage('Yes'), + text: this.translateMessage('YES'), cssClass: 'alert-btn-delete', handler: () => { this.deleteUsersinGroup(index); diff --git a/src/pages/user-and-groups/user-and-groups.ts b/src/pages/user-and-groups/user-and-groups.ts index 9ff8a0fcd..c3b69cffa 100644 --- a/src/pages/user-and-groups/user-and-groups.ts +++ b/src/pages/user-and-groups/user-and-groups.ts @@ -555,7 +555,7 @@ export class UserAndGroupsPage { } }, { - text: this.translateMessage('Yes'), + text: this.translateMessage('YES'), cssClass: 'alert-btn-delete', handler: () => { this.deleteGroup(index); @@ -618,7 +618,7 @@ export class UserAndGroupsPage { } }, { - text: this.translateMessage('Yes'), + text: this.translateMessage('YES'), cssClass: 'alert-btn-delete', handler: () => { this.deleteUser(index); diff --git a/src/service/common-util.service.ts b/src/service/common-util.service.ts index 672b85479..a1f5ef42a 100644 --- a/src/service/common-util.service.ts +++ b/src/service/common-util.service.ts @@ -250,7 +250,7 @@ export class CommonUtilService implements OnDestroy { buttons: [ { text: this.translateMessage('YES'), - cssClass: 'alert-btn-delete', + cssClass: 'alert-btn-cancel', handler: () => { this.telemetryGeneratorService.generateBackClickedTelemetry(pageId, environment, isNavBack); this.platform.exitApp(); @@ -259,7 +259,7 @@ export class CommonUtilService implements OnDestroy { }, { text: this.translateMessage('NO'), - cssClass: 'alert-btn-cancel', + cssClass: 'alert-btn-delete', handler: () => { // telemetry if (this.alert) {