From eac0f2f59f5d4028567fd8d9413fd23131166e1f Mon Sep 17 00:00:00 2001 From: Xavier Valarino Date: Tue, 21 Mar 2023 20:30:23 -0700 Subject: [PATCH] Fix frame extending past viewport when zoomed in When a user zooms in (`ctrl/cmd` + `+`), the Vomnibar frame will extend down past the viewport. The height is set to calc(100% - 70px) on the actual iframe, and we can't reach it with this CSS. Setting a max-height that is effectively the same, but measured in viewport units, on the Vomnibar container keeps it from going past the bottom of the viewport. --- src/catppuccin-vimium-frappe.css | 1 + src/catppuccin-vimium-latte.css | 1 + src/catppuccin-vimium-macchiato.css | 1 + src/catppuccin-vimium-mocha.css | 1 + 4 files changed, 4 insertions(+) diff --git a/src/catppuccin-vimium-frappe.css b/src/catppuccin-vimium-frappe.css index acbc639..2f0e5ff 100644 --- a/src/catppuccin-vimium-frappe.css +++ b/src/catppuccin-vimium-frappe.css @@ -23,6 +23,7 @@ background: #303446; /* base */ border: 2px solid #BABBF1; /* lavender */ animation: show 200ms cubic-bezier(0, 0, 0.2, 1) forwards; + max-height: calc(100vh - 70px); overflow: hidden; } diff --git a/src/catppuccin-vimium-latte.css b/src/catppuccin-vimium-latte.css index b691611..fc0c6f3 100644 --- a/src/catppuccin-vimium-latte.css +++ b/src/catppuccin-vimium-latte.css @@ -23,6 +23,7 @@ background: #EFF1F5; /* base */ border: 2px solid #7287FD; /* lavender */ animation: show 200ms cubic-bezier(0, 0, 0.2, 1) forwards; + max-height: calc(100vh - 70px); overflow: hidden; } diff --git a/src/catppuccin-vimium-macchiato.css b/src/catppuccin-vimium-macchiato.css index fb3f5b8..b524178 100644 --- a/src/catppuccin-vimium-macchiato.css +++ b/src/catppuccin-vimium-macchiato.css @@ -23,6 +23,7 @@ background: #24273A; /* base */ border: 2px solid #B7BDF8; /* lavender */ animation: show 200ms cubic-bezier(0, 0, 0.2, 1) forwards; + max-height: calc(100vh - 70px); overflow: hidden; } diff --git a/src/catppuccin-vimium-mocha.css b/src/catppuccin-vimium-mocha.css index a1fc828..47a87aa 100644 --- a/src/catppuccin-vimium-mocha.css +++ b/src/catppuccin-vimium-mocha.css @@ -23,6 +23,7 @@ background: #1E1E2E; /* base */ border: 2px solid #B4BEFE; /* lavender */ animation: show 200ms cubic-bezier(0, 0, 0.2, 1) forwards; + max-height: calc(100vh - 70px); overflow: hidden; }