From 19411351dd39da6de2bf6e41a40b909dc1f38e57 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rn-Michael=20Miehe?= Date: Wed, 1 Nov 2023 22:41:30 +0000 Subject: [PATCH] mobile layout optimization; auto-show doors on touch device --- ui/src/components/Calendar.vue | 2 +- ui/src/components/MultiModal.vue | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ui/src/components/Calendar.vue b/ui/src/components/Calendar.vue index e9c30a5..8af0c64 100644 --- a/ui/src/components/Calendar.vue +++ b/ui/src/components/Calendar.vue @@ -68,7 +68,7 @@ export default class extends Vue { public readonly doors!: Door[]; private readonly idle_caption = "Finde die Türchen auf dem Adventskalender!"; - public show_doors = false; + public show_doors = window.matchMedia("(any-hover: none)").matches; private multi_modal?: MultiModal; public figure_caption = this.idle_caption; public next_door: number | null = null; diff --git a/ui/src/components/MultiModal.vue b/ui/src/components/MultiModal.vue index bbdb275..e8eeda1 100644 --- a/ui/src/components/MultiModal.vue +++ b/ui/src/components/MultiModal.vue @@ -2,7 +2,7 @@