From 087a1ba2de138d3124c36a36dfd847c44d690cf6 Mon Sep 17 00:00:00 2001 From: tykayn Date: Tue, 21 Dec 2021 16:45:19 +0100 Subject: [PATCH] fix autoscroll to top on nav change --- src/app/app.component.ts | 8 ++++---- .../form/date/list/day/day-list.component.html | 14 ++++++-------- .../form/steps/step-four/step-four.component.html | 9 ++++----- 3 files changed, 14 insertions(+), 17 deletions(-) diff --git a/src/app/app.component.ts b/src/app/app.component.ts index 6bbd694d..2501be93 100644 --- a/src/app/app.component.ts +++ b/src/app/app.component.ts @@ -32,10 +32,9 @@ export class AppComponent implements OnInit, OnDestroy, AfterViewInit { public themeClass: string; public isSidebarOpened = false; public devModeEnabled = !environment.production; - private themeSubscription: Subscription; - public environment = environment; public onHomePage = false; + private themeSubscription: Subscription; constructor( private router: Router, @@ -71,8 +70,9 @@ export class AppComponent implements OnInit, OnDestroy, AfterViewInit { console.log('evt', evt); this.onHomePage = evt.url === '/'; - - window.scrollTo(0, 0); + setTimeout(() => { + window.scrollTo(0, 0); + }, 10); }); if (!environment.production) { diff --git a/src/app/features/administration/form/date/list/day/day-list.component.html b/src/app/features/administration/form/date/list/day/day-list.component.html index fc5a32e0..a12f215e 100644 --- a/src/app/features/administration/form/date/list/day/day-list.component.html +++ b/src/app/features/administration/form/date/list/day/day-list.component.html @@ -1,18 +1,16 @@
-
-
+
+

+ {{ choice.date_object | date: 'short' }} +

+
diff --git a/src/app/features/administration/form/steps/step-four/step-four.component.html b/src/app/features/administration/form/steps/step-four/step-four.component.html index a5280d1a..7bedf69d 100644 --- a/src/app/features/administration/form/steps/step-four/step-four.component.html +++ b/src/app/features/administration/form/steps/step-four/step-four.component.html @@ -40,14 +40,10 @@

- Choisissez les horaires ou options à appliquer à toutes les dates + Choisissez les horaires

-

- Propositions de créneaux horaires -

-
+

+ Appliquer le même horaire / option à toutes les dates +