From 006d4cf1ffcefca5d9120defa1fc67bd921e9ef5 Mon Sep 17 00:00:00 2001 From: Matt Date: Sat, 9 Aug 2025 19:49:12 +0200 Subject: [PATCH] Improve mobile keyboard handling and viewport detection - Disable transitions and make menu persistent on mobile devices - Add keyboard open/close detection to prevent unwanted viewport updates - Differentiate between keyboard events and actual viewport changes - Improve resize debouncing with longer delays for mobile - Handle orientation changes separately from keyboard events --- components/PhoneInputWrapper.vue | 4 ++- composables/useMobileDetection.ts | 48 +++++++++++++++++++++++++++---- 2 files changed, 45 insertions(+), 7 deletions(-) diff --git a/components/PhoneInputWrapper.vue b/components/PhoneInputWrapper.vue index 97b311d..cbe39b1 100644 --- a/components/PhoneInputWrapper.vue +++ b/components/PhoneInputWrapper.vue @@ -24,8 +24,10 @@ location="bottom start" :offset="4" :min-width="mobileDetection.isMobile ? '90vw' : '280'" - transition="fade-transition" + :transition="mobileDetection.isMobile ? 'none' : 'fade-transition'" :no-click-animation="true" + :persistent="mobileDetection.isMobile" + :attach="false" >