From 6d32ac9ec08566cd43a85eeaf2efd175100f238c Mon Sep 17 00:00:00 2001 From: "Jens L." Date: Thu, 5 Jun 2025 21:26:12 +0000 Subject: [PATCH] web/user: fix user settings flow not loading (#14911) * web/user: fix user settings flow not loading Signed-off-by: Jens Langhammer * fix Signed-off-by: Jens Langhammer * unrelated fix: fix select caret color in dark theme Signed-off-by: Jens Langhammer --------- Signed-off-by: Jens Langhammer Co-authored-by: Marc 'risson' Schmitt --- web/src/common/styles/theme-dark.css | 4 ++++ .../details/UserSettingsFlowExecutor.ts | 17 ++++++++++------- 2 files changed, 14 insertions(+), 7 deletions(-) diff --git a/web/src/common/styles/theme-dark.css b/web/src/common/styles/theme-dark.css index 240a29e22b18..c42501c85be6 100644 --- a/web/src/common/styles/theme-dark.css +++ b/web/src/common/styles/theme-dark.css @@ -201,6 +201,10 @@ select[multiple] option:checked { --pf-c-input-group--BackgroundColor: transparent; } +select.pf-c-form-control { + --pf-c-form-control__select--BackgroundUrl: url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 320 512'%3E%3Cpath fill='%23fafafa' d='M31.3 192h257.3c17.8 0 26.7 21.5 14.1 34.1L174.1 354.8c-7.8 7.8-20.5 7.8-28.3 0L17.2 226.1C4.6 213.5 13.5 192 31.3 192z'/%3E%3C/svg%3E"); +} + .pf-c-form-control { --pf-c-form-control--BorderTopColor: transparent !important; --pf-c-form-control--BorderRightColor: transparent !important; diff --git a/web/src/user/user-settings/details/UserSettingsFlowExecutor.ts b/web/src/user/user-settings/details/UserSettingsFlowExecutor.ts index 9db2cbed4fa9..8ee8abc64bfe 100644 --- a/web/src/user/user-settings/details/UserSettingsFlowExecutor.ts +++ b/web/src/user/user-settings/details/UserSettingsFlowExecutor.ts @@ -11,7 +11,7 @@ import { StageHost } from "#flow/stages/base"; import "#user/user-settings/details/stages/prompt/PromptStage"; import { msg } from "@lit/localize"; -import { CSSResult, PropertyValues, TemplateResult, html } from "lit"; +import { CSSResult, TemplateResult, html } from "lit"; import { customElement, property } from "lit/decorators.js"; import { unsafeHTML } from "lit/directives/unsafe-html.js"; @@ -36,7 +36,7 @@ export class UserSettingsFlowExecutor implements StageHost { @property() - flowSlug?: string; + flowSlug = this.brand?.flowUserSettings; private _challenge?: ChallengeTypes; @@ -86,12 +86,15 @@ export class UserSettingsFlowExecutor }); } - updated(changedProperties: PropertyValues): void { - if (changedProperties.has("brand") && this.brand) { - this.flowSlug = this.brand.flowUserSettings; - - if (!this.flowSlug) return; + firstUpdated() { + if (this.flowSlug) { + this.nextChallenge(); + } + } + updated(): void { + if (!this.flowSlug && this.brand) { + this.flowSlug = this.brand.flowUserSettings; this.nextChallenge(); } }