Merge pull request #1474 from crazyserver/MOBILE-649

Mobile 649
main
Juan Leyva 2018-08-22 16:41:38 +01:00 committed by GitHub
commit e5a4fb3412
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
7 changed files with 31 additions and 20 deletions

View File

@ -200,6 +200,14 @@ ion-datetime {
position: relative; position: relative;
} }
input {
@include rtl() {
text-align: right;
}
}
/** Format Text */ /** Format Text */
core-format-text[maxHeight], core-format-text[maxHeight],
core-format-text[ng-reflect-max-height] { core-format-text[ng-reflect-max-height] {
@ -238,11 +246,10 @@ core-format-text[ng-reflect-max-height] {
font-size: 14px; font-size: 14px;
display: block; display: block;
position: absolute; position: absolute;
bottom: 0; @include position(null, 0, 0, null);
right: 0;
z-index: 1001; z-index: 1001;
background-color: $white; background-color: $white;
padding-left: 10px; @include padding(null, null, null, 10px);
} }
&:before { &:before {
@ -308,8 +315,7 @@ audio.core-media-adapt-width {
.core-image-viewer-icon { .core-image-viewer-icon {
position: absolute; position: absolute;
right: 10px; @include position(null, 10px, 10px, null);
bottom: 10px;
color: $black; color: $black;
border-radius: 5px; border-radius: 5px;
background: rgba(255, 255, 255, .5); background: rgba(255, 255, 255, .5);
@ -348,7 +354,7 @@ core-format-text {
} }
ul, ol { ul, ol {
list-style-position: inside; list-style-position: inside;
margin-left: 15px; @include margin(null, null, null, 15px);
} }
} }
@ -411,7 +417,7 @@ ion-col ion-select {
.core-button-select { .core-button-select {
ion-icon:last-child { ion-icon:last-child {
margin-left: 5px; @include margin(null, null, null, 5px);
} }
} }
@ -423,8 +429,7 @@ ion-col ion-select {
input { input {
position: absolute; position: absolute;
top: 0; @include position(null, 0, 0, null);
right: 0;
min-width: 100%; min-width: 100%;
min-height: 100%; min-height: 100%;
opacity: 0; opacity: 0;
@ -490,7 +495,7 @@ ion-col ion-select {
} }
.core-question-feedback-padding { .core-question-feedback-padding {
padding: 8px 35px 8px 14px; @include padding(8px, 35px, 8px, 14px);
} }
.core-question-correct { .core-question-correct {
@ -579,13 +584,13 @@ ion-col ion-select {
/*rtl:begin:ignore*/ /*rtl:begin:ignore*/
.atto_image_button_left { .atto_image_button_left {
float: left; float: left;
margin: 0 0.5em 0 0; @include margin(0, 0.5em, 0, 0);
max-width: calc(100% - 1em); max-width: calc(100% - 1em);
} }
.atto_image_button_right { .atto_image_button_right {
float: right; float: right;
margin: 0 0 0 0.5em; @include margin(0, 0, 0, 0.5em);
max-width: calc(100% - 1em); max-width: calc(100% - 1em);
} }
/*rtl:end:ignore*/ /*rtl:end:ignore*/
@ -657,8 +662,7 @@ canvas[core-chart] {
ion-icon { ion-icon {
color: $color-base; color: $color-base;
position: absolute; position: absolute;
top: 0; @include position(0, null, null, 16px)
left: 16px;
height: 100%; height: 100%;
font-size: 24px; font-size: 24px;
display: flex; display: flex;
@ -716,8 +720,7 @@ canvas[core-chart] {
.core-modal-fullscreen { .core-modal-fullscreen {
.modal-wrapper { .modal-wrapper {
position: absolute; position: absolute;
top: 0 !important; @include position(0 !important, null, null, 0 !important);
left: 0 !important;
display: block; display: block;
width: 100% !important; width: 100% !important;
height: 100% !important; height: 100% !important;
@ -759,9 +762,7 @@ canvas[core-chart] {
object, object,
video { video {
position: absolute; position: absolute;
top: 0; @include position(0, null, 0, 0);
bottom: 0;
left: 0;
width: 100%; width: 100%;
height: 100%; height: 100%;
border: 0; border: 0;
@ -848,6 +849,7 @@ ion-alert.core-inapp-notification {
position: absolute; position: absolute;
top: -18px; top: -18px;
right: -8px; right: -8px;
@include position(-18px, -8px, null, null);
color: red; color: red;
font-size: 16px; font-size: 16px;
} }

View File

@ -128,6 +128,7 @@
"submit": "سلم", "submit": "سلم",
"success": "نجاح", "success": "نجاح",
"teachers": "معلمون", "teachers": "معلمون",
"thisdirection": "rtl",
"time": "وقت", "time": "وقت",
"timesup": "انتهى الوقت!", "timesup": "انتهى الوقت!",
"today": "اليوم", "today": "اليوم",

View File

@ -214,6 +214,7 @@
"tablet": "Tablet", "tablet": "Tablet",
"teachers": "Teachers", "teachers": "Teachers",
"thereisdatatosync": "There are offline {{$a}} to be synchronized.", "thereisdatatosync": "There are offline {{$a}} to be synchronized.",
"thisdirection": "ltr",
"time": "Time", "time": "Time",
"timesup": "Time is up!", "timesup": "Time is up!",
"today": "Today", "today": "Today",

View File

@ -125,6 +125,7 @@
"submit": "ثبت", "submit": "ثبت",
"success": "موفق", "success": "موفق",
"teachers": "استاد", "teachers": "استاد",
"thisdirection": "rtl",
"time": "زمان", "time": "زمان",
"timesup": "وقت تمام شد!", "timesup": "وقت تمام شد!",
"today": "امروز", "today": "امروز",

View File

@ -146,6 +146,7 @@
"success": "הצלחה", "success": "הצלחה",
"tablet": "טאבלט", "tablet": "טאבלט",
"teachers": "מורים", "teachers": "מורים",
"thisdirection": "rtl",
"time": "זמן", "time": "זמן",
"timesup": "זמנך נגמר!", "timesup": "זמנך נגמר!",
"today": "היום", "today": "היום",

View File

@ -44,6 +44,11 @@ export class CoreLangProvider {
moment.locale(language); moment.locale(language);
}); });
}); });
translate.onLangChange.subscribe((event: any) => {
platform.setLang(event.lang, true);
platform.setDir(this.translate.instant('core.thisdirection'), true);
});
} }
/** /**

View File

@ -8,7 +8,7 @@ $font-path: "../assets/fonts";
// The app direction is used to include // The app direction is used to include
// rtl styles in your app. For more info, please see: // rtl styles in your app. For more info, please see:
// http://ionicframework.com/docs/theming/rtl-support/ // http://ionicframework.com/docs/theming/rtl-support/
$app-direction: ltr; $app-direction: multi;
@import "ionic.globals"; @import "ionic.globals";