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

Make antd messages click-through #7239

Merged
merged 4 commits into from
Jul 28, 2023
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
1 change: 1 addition & 0 deletions CHANGELOG.unreleased.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ For upgrade instructions, please check the [migration guide](MIGRATIONS.released
- Added configuration to require users' emails to be verified, added flow to verify emails via link. [#7161](https://github.com/scalableminds/webknossos/pull/7161)

### Changed
- Small messages during annotating (e.g. “finished undo”, “applying mapping…”) are now click-through so they do not block users from selecting tools. [7239](https://github.com/scalableminds/webknossos/pull/7239)

### Fixed

Expand Down
2 changes: 2 additions & 0 deletions frontend/javascripts/main.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import ReactDOM from "react-dom";
import { document } from "libs/window";
import rootSaga from "oxalis/model/sagas/root_saga";
import UnthrottledStore, { startSagas } from "oxalis/store";
import { message } from "antd";

import { getActiveUser, checkAnyOrganizationExists, getOrganization } from "admin/admin_rest_api";
import { googleAnalyticsLogClicks } from "oxalis/model/helpers/analytics";
Expand Down Expand Up @@ -88,6 +89,7 @@ document.addEventListener("DOMContentLoaded", async () => {
ErrorHandling.initialize({
throwAssertions: false,
});
message.config({ top: 30 });
document.addEventListener("click", googleAnalyticsLogClicks);
checkBrowserFeatures();
await Promise.all([loadFeatureToggles(), loadActiveUser(), loadHasOrganizations()]);
Expand Down
4 changes: 4 additions & 0 deletions frontend/stylesheets/main.less
Original file line number Diff line number Diff line change
Expand Up @@ -667,3 +667,7 @@ i.without-icon-margin,
}
}
}

.ant-message, .ant-message * {
pointer-events: none;
}