diff --git a/src/app/features/consultation/consultation.module.ts b/src/app/features/consultation/consultation.module.ts
index 92c0934c..c69331b1 100644
--- a/src/app/features/consultation/consultation.module.ts
+++ b/src/app/features/consultation/consultation.module.ts
@@ -17,6 +17,7 @@ import { EditComponent } from './edit/edit.component';
import { ResultsRoundedComponent } from './results-rounded/results-rounded.component';
import { PollResultsDinumComponent } from './poll-results-dinum/poll-results-dinum.component';
import { ChoiceTableComponent } from './choice-table/choice-table.component';
+import { DialogModule } from 'primeng/dialog';
@NgModule({
declarations: [
@@ -39,6 +40,7 @@ import { ChoiceTableComponent } from './choice-table/choice-table.component';
SharedModule,
TranslateModule.forChild({ extend: true }),
AdministrationModule,
+ DialogModule,
],
})
export class ConsultationModule {}
diff --git a/src/app/features/consultation/edit/edit.component.html b/src/app/features/consultation/edit/edit.component.html
index 9c5c4414..f24f85d7 100644
--- a/src/app/features/consultation/edit/edit.component.html
+++ b/src/app/features/consultation/edit/edit.component.html
@@ -21,7 +21,7 @@
@@ -56,13 +59,13 @@
+
+
+
+
+ {{ 'participation.modal.cancel_own.title' | translate }}
+
+
+ {{ 'participation.modal.cancel_own.description' | translate }}
+
+
+
+
+
+
+
+
+
diff --git a/src/app/features/consultation/edit/edit.component.scss b/src/app/features/consultation/edit/edit.component.scss
index cba6fba5..417b69a2 100644
--- a/src/app/features/consultation/edit/edit.component.scss
+++ b/src/app/features/consultation/edit/edit.component.scss
@@ -1,8 +1,8 @@
.app-choice-button-dinum {
- button {
- margin-right: 1rem;
- display: inline-block;
- }
+ //button {
+ // margin-right: 1rem;
+ // display: inline-block;
+ //}
.groupe-label {
color: #383838;
font-weight: bold;
diff --git a/src/app/features/consultation/edit/edit.component.ts b/src/app/features/consultation/edit/edit.component.ts
index 806a0bf1..ec9e7326 100644
--- a/src/app/features/consultation/edit/edit.component.ts
+++ b/src/app/features/consultation/edit/edit.component.ts
@@ -1,4 +1,4 @@
-import { Component, OnInit } from '@angular/core';
+import { ChangeDetectorRef, Component, Inject, OnInit } from '@angular/core';
import { ActivatedRoute, ParamMap, Router } from '@angular/router';
import { ToastService } from '../../../core/services/toast.service';
import { StorageService } from '../../../core/services/storage.service';
@@ -7,6 +7,7 @@ import { Poll } from '../../../core/models/poll.model';
import { PollUtilitiesService } from '../../../core/services/poll.utilities.service';
import { ApiService } from '../../../core/services/api.service';
import { DateService } from '../../../core/services/date.service';
+import { DOCUMENT } from '@angular/common';
@Component({
selector: 'app-edit',
@@ -18,6 +19,7 @@ export class EditComponent implements OnInit {
public fetching = true;
private pollSlug: string;
private pass_hash: string;
+ display_vote_dialog: boolean = false;
constructor(
private router: Router,
@@ -27,6 +29,8 @@ export class EditComponent implements OnInit {
public api: ApiService,
public pollService: PollService,
public dateService: DateService,
+ private cd: ChangeDetectorRef,
+ @Inject(DOCUMENT) private document: any,
public toastService: ToastService
) {
this.pollService.poll.subscribe((newpoll: Poll) => {
@@ -80,4 +84,13 @@ export class EditComponent implements OnInit {
})
);
}
+
+ closeModalAndFocusOnButtonToOpen() {
+ this.display_vote_dialog = false;
+ this.cd.detectChanges();
+ let elem = this.document.querySelector('#vote_button_popup');
+ if (elem) {
+ elem.focus();
+ }
+ }
}
diff --git a/src/app/features/participation/add-answer/add-answer.component.html b/src/app/features/participation/add-answer/add-answer.component.html
index ac279450..196f47a5 100644
--- a/src/app/features/participation/add-answer/add-answer.component.html
+++ b/src/app/features/participation/add-answer/add-answer.component.html
@@ -1,4 +1,4 @@
-
+
@@ -23,11 +23,11 @@
diff --git a/src/app/features/shared/components/choice-button-dinum/choice-button-dinum.component.scss b/src/app/features/shared/components/choice-button-dinum/choice-button-dinum.component.scss
index 554aefd5..b19ccda8 100644
--- a/src/app/features/shared/components/choice-button-dinum/choice-button-dinum.component.scss
+++ b/src/app/features/shared/components/choice-button-dinum/choice-button-dinum.component.scss
@@ -1,14 +1,62 @@
-.choice-button {
- margin-right: 1em;
- &.is-active {
+@import '../../../../../../src/styles/variables.scss';
+.choice-button-zone {
+ margin-right: 15px;
+ border-radius: 8px;
+ background: #fff;
+ display: inline-block;
+ text-align: center;
+ min-width: 107px;
+ min-height: 83px;
+ padding: 8px 0 16px;
+ .button-description {
+ margin-top: 8px;
+ font-weight: 700;
+ font-size: 14px;
+ line-height: 16px;
+ }
+ button {
+ margin: 0 auto;
+ }
+ &:focus {
+ outline: $outline-color;
+ outline-style: solid;
+ outline-offset: 0.15rem;
+ }
+ &:active {
+ outline: transparent;
+ }
+
+ &:hover {
&.is-answer-YES {
- background: green;
+ background: $d-success;
+ color: $d-success-text;
}
&.is-answer-MAYBE {
- background: orange;
+ background: $d-warning;
+ color: $d-warning-text;
}
&.is-answer-NO {
- background: red;
+ background: $d-error;
+ color: $d-error-text;
}
}
+ &.is-active {
+ &.is-answer-YES {
+ background: $d-success;
+ color: $d-success-text;
+ }
+ &.is-answer-MAYBE {
+ background: $d-warning;
+ color: $d-warning-text;
+ }
+ &.is-answer-NO {
+ background: $d-error;
+ color: $d-error-text;
+ }
+ }
+ .icon-deco {
+ padding: 20px;
+ border: solid 1px grey;
+ background-position: center;
+ }
}
diff --git a/src/styles/dev-utilities/_helpers.scss b/src/styles/dev-utilities/_helpers.scss
index 3de322ea..c6fc056c 100644
--- a/src/styles/dev-utilities/_helpers.scss
+++ b/src/styles/dev-utilities/_helpers.scss
@@ -85,10 +85,20 @@
.has-no-padding {
padding: 0;
}
+// filters made with https://codepen.io/sosuke/pen/Pjoqqp
.is-filtered-icon-primary {
filter: invert(48%) sepia(68%) saturate(6489%) hue-rotate(233deg) brightness(89%) contrast(81%);
}
+.is-filtered-icon-yes {
+ filter: invert(48%) sepia(68%) saturate(6489%) hue-rotate(233deg) brightness(89%) contrast(81%);
+}
+.is-filtered-icon-maybe {
+ filter: invert(48%) sepia(68%) saturate(6489%) hue-rotate(233deg) brightness(89%) contrast(81%);
+}
+.is-filtered-icon-no {
+ filter: invert(48%) sepia(68%) saturate(6489%) hue-rotate(233deg) brightness(89%) contrast(81%);
+}
.is-large-button {
width: 100%;
display: block;
@@ -104,6 +114,17 @@
.has-background-transparent {
background-color: transparent;
}
+
+.has-background-answer-YES {
+ background: url('/assets/icons/plus-circle.svg') no-repeat 28px center;
+}
+.has-background-answer-MAYBE {
+ background: url('/assets/icons/help-circle.svg') no-repeat 28px center;
+}
+.has-background-answer-NO {
+ background: url('/assets/icons/x.svg') no-repeat 28px center;
+}
+
.has-background-plus {
background: url('/assets/icons/plus-circle.svg') no-repeat 16px center;
}
diff --git a/src/styles/partials/_buttons.scss b/src/styles/partials/_buttons.scss
index a519b9b1..54997795 100644
--- a/src/styles/partials/_buttons.scss
+++ b/src/styles/partials/_buttons.scss
@@ -179,7 +179,6 @@ a {
&:hover {
color: $white !important;
- //background-color: $primary_color;
button {
color: $white !important;
}
diff --git a/src/styles/partials/_typo.scss b/src/styles/partials/_typo.scss
index f2c09de3..2d462161 100644
--- a/src/styles/partials/_typo.scss
+++ b/src/styles/partials/_typo.scss
@@ -43,8 +43,8 @@ body {
}
.is-2 {
color: $d-primary-intense;
- font-size: 20px;
- line-height: 23px;
+ font-size: 28px;
+ line-height: 32px;
margin-bottom: 1rem;
}
.is-3 {
@@ -56,7 +56,33 @@ body {
line-height: 28px;
margin-bottom: 1rem;
}
-
+ .is-4 {
+ color: $d-primary-intense;
+ font-family: $title_font;
+ font-weight: 700;
+ font-style: normal;
+ font-size: 24px;
+ line-height: 28px;
+ margin-bottom: 1rem;
+ }
+ .is-5 {
+ color: #383838;
+ font-family: $title_font;
+ font-weight: 700;
+ font-style: normal;
+ font-size: 20px;
+ line-height: 23px;
+ margin-bottom: 1rem;
+ }
+ .is-6 {
+ color: #383838;
+ font-family: $title_font;
+ font-weight: 700;
+ font-style: normal;
+ font-size: 16px;
+ line-height: 20px;
+ margin-bottom: 1rem;
+ }
.nobold {
font-weight: normal;
}