From c47cca3e3050636985fcdd6b37456d4cdb95907f Mon Sep 17 00:00:00 2001 From: Kibana Machine <42973632+kibanamachine@users.noreply.github.com> Date: Mon, 8 Jul 2024 15:32:48 +0200 Subject: [PATCH] [8.15] Fix "Elastic did not load properly" message color when system in dark mode (#187653) (#187670) # Backport This will backport the following commits from `main` to `8.15`: - [Fix "Elastic did not load properly" message color when system in dark mode (#187653)](https://github.com/elastic/kibana/pull/187653) ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sqren/backport) Co-authored-by: Anton Dosov Co-authored-by: Elastic Machine --- .../src/bootstrap/__snapshots__/render_template.test.ts.snap | 2 ++ .../src/bootstrap/render_template.ts | 2 ++ 2 files changed, 4 insertions(+) diff --git a/packages/core/rendering/core-rendering-server-internal/src/bootstrap/__snapshots__/render_template.test.ts.snap b/packages/core/rendering/core-rendering-server-internal/src/bootstrap/__snapshots__/render_template.test.ts.snap index af1808d9a2019..c1754bce247a9 100644 --- a/packages/core/rendering/core-rendering-server-internal/src/bootstrap/__snapshots__/render_template.test.ts.snap +++ b/packages/core/rendering/core-rendering-server-internal/src/bootstrap/__snapshots__/render_template.test.ts.snap @@ -64,10 +64,12 @@ if (window.__kbnStrictCsp__ && window.__kbnCspNotEnforced__) { var errorTitleEl = document.createElement('h1'); errorTitleEl.innerText = errorTitle; errorTitleEl.style.margin = '20px'; + errorTitleEl.style.color = '#1a1c21'; var errorTextEl = document.createElement('p'); errorTextEl.innerText = errorText; errorTextEl.style.margin = '20px'; + errorTextEl.style.color = '#343741'; var errorReloadEl = document.createElement('button'); errorReloadEl.innerText = errorReload; diff --git a/packages/core/rendering/core-rendering-server-internal/src/bootstrap/render_template.ts b/packages/core/rendering/core-rendering-server-internal/src/bootstrap/render_template.ts index fbb7a4290bf14..7644841ddead0 100644 --- a/packages/core/rendering/core-rendering-server-internal/src/bootstrap/render_template.ts +++ b/packages/core/rendering/core-rendering-server-internal/src/bootstrap/render_template.ts @@ -80,10 +80,12 @@ if (window.__kbnStrictCsp__ && window.__kbnCspNotEnforced__) { var errorTitleEl = document.createElement('h1'); errorTitleEl.innerText = errorTitle; errorTitleEl.style.margin = '20px'; + errorTitleEl.style.color = '#1a1c21'; var errorTextEl = document.createElement('p'); errorTextEl.innerText = errorText; errorTextEl.style.margin = '20px'; + errorTextEl.style.color = '#343741'; var errorReloadEl = document.createElement('button'); errorReloadEl.innerText = errorReload;