Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Panel dragger workaround for Safari #3799

Merged
merged 2 commits into from
Oct 4, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,13 @@

## 69.0.0-SNAPSHOT - unreleased

### 🐞 Bug Fixes

* Added a workaround for a bug where Panel drag resizing was broken in Safari.

### 💥 Breaking Changes (upgrade difficulty: 🟢 LOW )
* The `INITIALIZING` AppState has been replaced with more fine-grained states (see below). This
is not expected to effect any applications.
is not expected to affect any applications.

### 🎁 New Features

Expand Down
4 changes: 3 additions & 1 deletion desktop/cmp/panel/impl/dragger/DraggerModel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -254,7 +254,9 @@ export class DraggerModel extends HoistModel {
}

private isValidMouseEvent(e) {
return e.buttons && e.buttons !== 0;
// Note: We fall back to deprecated 'which' to work around a Safari issue where `buttons`
// was not being set. We may be able to remove in the future.
return (e.buttons && e.buttons !== 0) || (e.which && e.which !== 0);
}

private isValidTouchEvent(e) {
Expand Down
Loading