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

fix(ui5-dialog): Texts are no longer blurred in Chromium-based browsers #2417

Merged
merged 5 commits into from
Nov 5, 2020
Merged
Changes from 1 commit
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
Prev Previous commit
Next Next commit
fix failing test
georgimkv committed Nov 2, 2020
commit c6766552944723864f0b588e7a7d4d316ddaa560
14 changes: 6 additions & 8 deletions packages/main/src/Dialog.js
Original file line number Diff line number Diff line change
@@ -214,23 +214,21 @@ class Dialog extends Popup {
this._isRTL = this.effectiveDir === "rtl";
this.onPhone = isPhone();
this.onDesktop = isDesktop();

ResizeHandler.deregister(this, this._screenResizeHandler);
georgimkv marked this conversation as resolved.
Show resolved Hide resolved
ResizeHandler.deregister(document.body, this._screenResizeHandler);
}

show() {
onAfterRendering() {
ResizeHandler.register(this, this._screenResizeHandler);
ResizeHandler.register(document.body, this._screenResizeHandler);
}

show() {
super.show();
this._center();
}

close() {
ResizeHandler.deregister(this, this._screenResizeHandler);
ResizeHandler.deregister(document.body, this._screenResizeHandler);

super.close();
}

_center() {
const height = window.innerHeight - this.offsetHeight,
width = window.innerWidth - this.offsetWidth;
2 changes: 1 addition & 1 deletion packages/main/test/pages/DialogLifecycle.html
Original file line number Diff line number Diff line change
@@ -30,7 +30,7 @@

<template id="dt">
<ui5-dialog id="hello-dialog" header-text="Dialogs are easy!">
<div stype="padding: 2rem; display:flex; justify-content: center;">
<div style="padding: 2rem; display:flex; justify-content: center;">
Hello World!
<ui5-button id="closeDialogButton">Dismiss</ui5-button>
</div>