css: Remove the melodramatic fade-in animation on load.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
This commit is contained in:
Anders Kaseorg
2021-10-14 18:58:27 -07:00
parent 751eb6ef98
commit f092e99f42
2 changed files with 1 additions and 17 deletions

View File

@@ -299,34 +299,27 @@ body {
/* When the active webview is loaded */ /* When the active webview is loaded */
#webviews-container.loaded::before { #webviews-container.loaded::before {
opacity: 0;
z-index: -1; z-index: -1;
visibility: hidden; visibility: hidden;
} }
webview, webview,
.functional-view { .functional-view {
/* transition: opacity 0.3s ease-in; */
position: absolute; position: absolute;
width: 100%; width: 100%;
height: 100%; height: 100%;
flex-grow: 1; flex-grow: 1;
} }
webview.onload {
transition: opacity 1s cubic-bezier(0.95, 0.05, 0.795, 0.035);
}
webview.active, webview.active,
.functional-view.active { .functional-view.active {
opacity: 1;
z-index: 1; z-index: 1;
visibility: visible; visibility: visible;
} }
webview.disabled, webview.disabled,
.functional-view.disabled { .functional-view.disabled {
opacity: 0; visibility: hidden;
} }
webview.focus { webview.focus {

View File

@@ -143,10 +143,6 @@ export default class WebView {
}); });
this.$el!.addEventListener("dom-ready", () => { this.$el!.addEventListener("dom-ready", () => {
if (this.props.role === "server") {
this.$el!.classList.add("onload");
}
this.loading = false; this.loading = false;
this.props.switchLoading(false, this.props.url); this.props.switchLoading(false, this.props.url);
this.show(); this.show();
@@ -197,11 +193,6 @@ export default class WebView {
this.$el!.classList.remove("disabled"); this.$el!.classList.remove("disabled");
this.$el!.classList.add("active"); this.$el!.classList.add("active");
setTimeout(() => {
if (this.props.role === "server") {
this.$el!.classList.remove("onload");
}
}, 1000);
this.focus(); this.focus();
this.props.onTitleChange(); this.props.onTitleChange();
// Injecting preload css in webview to override some css rules // Injecting preload css in webview to override some css rules