translate poll creation, buttons place in stepper 🎨

This commit is contained in:
Tykayn 2022-02-08 18:06:47 +01:00 committed by tykayn
parent 19b9d61192
commit c7e4798ce0
5 changed files with 21 additions and 13 deletions

View File

@ -87,12 +87,12 @@
<div class="column has-text-right">
<app-language-selector class="nav-button"></app-language-selector>
<button
class="has-no-border nav-button cancel-button"
class="nav-button cancel-button"
(click)="showCancelDialog()"
id="display_cancel_popup_button"
aria-haspopup="dialog"
>
{{ 'nav.leave' | translate }} <i class="fa fa-times"></i>
{{ 'nav.leave' | translate }}
</button>
</div>
</div>

View File

@ -54,24 +54,29 @@
.nav-button {
margin-top: 0;
line-height: $stepper-nav-height;
height: $stepper-nav-height;
margin-right: 1em;
line-height: $stepper-nav-height / 2;
height: $stepper-nav-height / 2;
display: inline-block;
padding-left: 1em;
&:nth-last-of-type(1) {
margin-right: 0;
}
&app-language-selector {
padding-top: 1rem;
}
}
.cancel-button {
line-height: $stepper-nav-height;
height: $stepper-nav-height;
line-height: $stepper-nav-height / 2;
height: $stepper-nav-height / 2;
padding: 0 1rem;
color: $secondary_color;
margin-top: $stepper-nav-height / 4.5;
color: $primary_color;
border-color: $primary_color;
&:hover {
color: $font_color;
outline: black;
outline-style: solid;
color: $white;
background: $primary_color;
}
}
.cancel-button-reject-bottom {

View File

@ -3,7 +3,7 @@
<i class="fa fa-language"></i>
{{ 'LANGUAGES_SHORT.' + currentLang.toUpperCase() | translate }}
<!-- <i class="fa fa-language lang-selector-icon clickable" ></i>-->
<i class="fa fa-chevron-down"></i>
<!-- <i class="fa fa-chevron-down"></i>-->
</button>
<p-dialog
[modal]="true"

View File

@ -25,10 +25,13 @@ export class LanguageSelectorComponent implements OnInit {
ngOnInit(): void {
this.availableLanguages = this.languageService.getAvailableLanguages();
this.currentLang = this.languageService.getLangage();
if (this.storageService.language && this.availableLanguages.indexOf(this.storageService.language) !== -1) {
this.languageService.setLanguage(this.storageService.language);
this.currentLang = this.storageService.language;
}
this.currentLang = this.languageService.getLangage();
this.language_to_apply = '' + this.currentLang;
}
setLang(newlang: string = 'fr'): void {

View File

@ -41,7 +41,7 @@
},
"creation": {
"init": "Creation",
"title": "To begin with",
"title": "Poll creation",
"want": "I want to create a poll",
"dialog": "Leave poll creation?",
"dialog_content": "Do you really want to leave the poll creation ? All data will be lost.",