From 6f4ef0a9fa099716a33b957bbb593cb87309b45f Mon Sep 17 00:00:00 2001 From: Janne Mareike Koschinski Date: Wed, 6 Jul 2022 12:38:25 +0200 Subject: [PATCH] Make element web integration tests happy --- res/css/structures/_MatrixChat.scss | 53 +++++++++---------- src/components/structures/MatrixChat.tsx | 5 +- .../views/dialogs/UseCaseSelection.tsx | 2 +- 3 files changed, 28 insertions(+), 32 deletions(-) diff --git a/res/css/structures/_MatrixChat.scss b/res/css/structures/_MatrixChat.scss index 9d18326d574c..a6ba59826034 100644 --- a/res/css/structures/_MatrixChat.scss +++ b/res/css/structures/_MatrixChat.scss @@ -15,22 +15,10 @@ limitations under the License. */ .mx_MatrixChat_splash { - position: relative; - height: 100%; -} - -.mx_MatrixChat_splashButtons { - text-align: center; - width: 100%; - position: absolute; - bottom: 30px; -} - -.mx_MatrixChat_splashBackdrop { position: relative; &::before { /* Once we drop support for Firefox 102, remove this entire pseudo-element, move the background to the - .mx_MatrixChat_splashBackdrop, and use backdrop-filter for the blur instead. */ + .mx_MatrixChat_splash, and use backdrop-filter for the blur instead. */ content: ""; display: block; position: absolute; @@ -41,28 +29,28 @@ limitations under the License. gamma-incorrect gradient blending in browsers */ background-image: radial-gradient( - 53.85% 66.75% at 87.55% 0%, - hsla(250, 76%, 71%, 0.261) 0%, - hsla(251, 83%, 79%, 0.1305) 50%, - hsla(250, 100%, 88%, 0) 100% + 53.85% 66.75% at 87.55% 0%, + hsla(250, 76%, 71%, 0.261) 0%, + hsla(251, 83%, 79%, 0.1305) 50%, + hsla(250, 100%, 88%, 0) 100% ), radial-gradient( - 41.93% 41.93% at 0% 0%, - hsla(222, 29%, 20%, 0.28) 0%, - hsla(240, 17%, 53%, 0.14) 50%, - hsla(250, 100%, 88%, 0) 100% + 41.93% 41.93% at 0% 0%, + hsla(222, 29%, 20%, 0.28) 0%, + hsla(240, 17%, 53%, 0.14) 50%, + hsla(250, 100%, 88%, 0) 100% ), radial-gradient( - 100% 100% at 0% 0%, - hsla(250, 100%, 88%, 0.2436) 0%, - hsla(318, 50%, 82%, 0.1218) 50%, - hsla(0, 100%, 86%, 0) 100% + 100% 100% at 0% 0%, + hsla(250, 100%, 88%, 0.2436) 0%, + hsla(318, 50%, 82%, 0.1218) 50%, + hsla(0, 100%, 86%, 0) 100% ), radial-gradient( - 106.35% 96.26% at 100% 0%, - hsla(250, 100%, 88%, 0.4) 0%, - hsla(208, 67%, 85%, 0.2) 50%, - hsla(167, 76%, 82%, 0) 100% + 106.35% 96.26% at 100% 0%, + hsla(250, 100%, 88%, 0.4) 0%, + hsla(208, 67%, 85%, 0.2) 50%, + hsla(167, 76%, 82%, 0) 100% ); /* Ugly hack to allow us to get rid of the color banding of the gradients */ /* Can be replaced with backdrop-filter, replacing the hack below, after we stop supporting Firefox 102 */ @@ -72,6 +60,13 @@ limitations under the License. } } +.mx_MatrixChat_splashButtons { + text-align: center; + width: 100%; + position: absolute; + bottom: 30px; +} + .mx_MatrixChat_wrapper { display: flex; diff --git a/src/components/structures/MatrixChat.tsx b/src/components/structures/MatrixChat.tsx index 8fb19ee01df2..cae518b5fcfc 100644 --- a/src/components/structures/MatrixChat.tsx +++ b/src/components/structures/MatrixChat.tsx @@ -1236,6 +1236,7 @@ export default class MatrixChat extends React.PureComponent { this.screenAfterLogin.params, ); this.screenAfterLogin = null; + MatrixClientPeg.userRegisteredWithinLastHours() } else if (MatrixClientPeg.currentUserIsJustRegistered()) { MatrixClientPeg.setJustRegisteredUserId(null); @@ -1911,7 +1912,7 @@ export default class MatrixChat extends React.PureComponent { if (this.state.view === Views.LOADING) { view = ( -
+
); @@ -1961,7 +1962,7 @@ export default class MatrixChat extends React.PureComponent {
; } view = ( -
+
{ errorBox }
diff --git a/src/components/views/dialogs/UseCaseSelection.tsx b/src/components/views/dialogs/UseCaseSelection.tsx index 12082cea2ba1..2e4560812893 100644 --- a/src/components/views/dialogs/UseCaseSelection.tsx +++ b/src/components/views/dialogs/UseCaseSelection.tsx @@ -33,7 +33,7 @@ interface Props { export default function UseCaseSelection({ onFinished }: Props) { return ( -
+

{ _t("You’re in") }