From 5e390cf989b01c9dc97418f03b2b6938345da960 Mon Sep 17 00:00:00 2001 From: Lu Wilson Date: Mon, 4 Mar 2024 14:26:01 +0000 Subject: [PATCH] [terrible] Firefox: Allow scrolling on keyboard shortcuts dialog (#2974) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This PR lets firefox users scroll the keyboard shortcuts dialog **horizontally**. This isn't a real solution, just a plea for help for any ideas on how to fix this in a better way. Firefox users haven't been able to scroll the keyboard shortcuts dialog for a long time. The problem is that firefox handles overflowing column content differently to other browsers. Most browsers overflow *downwards*, but firefox overflows *sideways*, and there's no CSS property to control that behaviour. ### Change Type - [x] `patch` — Bug fix - [ ] `minor` — New feature - [ ] `major` — Breaking change - [ ] `dependencies` — Changes to package dependencies[^1] - [ ] `documentation` — Changes to the documentation only[^2] - [ ] `tests` — Changes to any test code only[^2] - [ ] `internal` — Any other changes that don't affect the published package[^2] - [ ] I don't know [^1]: publishes a `patch` release, for devDependencies use `internal` [^2]: will not publish a new version ### Test Plan 1. Open the keyboard shortcuts dialog on firefox. 2. Try to scroll the dialog to see overflowing content. More visible on smaller screens. - [ ] Unit Tests - [ ] End to end tests ### Release Notes - Add a brief release note for your PR here. Co-authored-by: Steve Ruiz --- packages/tldraw/src/lib/ui.css | 3 +++ 1 file changed, 3 insertions(+) diff --git a/packages/tldraw/src/lib/ui.css b/packages/tldraw/src/lib/ui.css index bbf9054b0..51624ff09 100644 --- a/packages/tldraw/src/lib/ui.css +++ b/packages/tldraw/src/lib/ui.css @@ -1492,6 +1492,9 @@ column-gap: var(--space-9); pointer-events: all; touch-action: auto; + + /* Terrible fix to allow firefox users to scroll the dialog */ + overflow-x: auto; } .tlui-shortcuts-dialog__body__tablet {