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

[Visual Refresh] Add Borealis theme #199993

Merged
merged 16 commits into from
Nov 19, 2024
Merged

Conversation

mgadewoll
Copy link
Contributor

@mgadewoll mgadewoll commented Nov 13, 2024

Summary

This PR introduces the first internal version of the new theme Borealis and ensures that:

  • themes can be switched between "Amsterdam" and "Borealis"
  • theme-specific Sass files are available and can be loaded with KBN_OPTIMIZER_THEMES=experimental
  • legacy JSON variable usage accounts for both themes
  • static template styles account for both themes

Running locally

// kibana.dev.yml or kibana.yml
uiSettings.experimental.themeSwitcherEnabled: true

Start kibana

KBN_OPTIMIZER_THEMES='v8light,v8dark,borealislight,borealisdark' yarn start

or

KBN_OPTIMIZER_THEMES=experimental yarn start

Checklist

@mgadewoll mgadewoll added release_note:skip Skip the PR/issue when compiling release notes backport:skip This commit does not require backporting v9.0.0 ci:cloud-deploy Create or update a Cloud deployment labels Nov 13, 2024
@mgadewoll mgadewoll force-pushed the eui/theme-borealis branch 3 times, most recently from 1cc9b49 to b33a410 Compare November 14, 2024 08:17
@mgadewoll mgadewoll added ci:project-deploy-observability Create an Observability project and removed ci:cloud-deploy Create or update a Cloud deployment labels Nov 14, 2024
Copy link
Contributor

🤖 GitHub comments

Expand to view the GitHub comments

Just comment with:

  • /oblt-deploy : Deploy a Kibana instance using the Observability test environments.
  • run docs-build : Re-trigger the docs validation. (use unformatted text in the comment!)

@mgadewoll mgadewoll force-pushed the eui/theme-borealis branch 6 times, most recently from cb7491a to 00df65d Compare November 14, 2024 17:50
@SiddharthMantri SiddharthMantri self-requested a review November 18, 2024 12:42
Copy link
Contributor

@szwarckonrad szwarckonrad left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

DW changes ✅

@@ -8,25 +8,44 @@
*/

import React, { FC } from 'react';
import type { DarkModeValue } from '@kbn/core-ui-settings-common';
import { type DarkModeValue, ThemeName } from '@kbn/core-ui-settings-common';
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The type of ThemeName is now string but will get stricter in follow-up PRs

@@ -426,8 +426,8 @@ export default ({ getPageObjects, getService }: FtrProviderContext) => {
expect(nodesWithValue).to.eql([
{ name: 'host-5', value: 10, color: '#6092c0' },
{ name: 'host-4', value: 30, color: '#9ab6d5' },
{ name: 'host-1', value: 50, color: '#f1d9b9' },
{ name: 'host-2', value: 70, color: '#eba47a' },
{ name: 'host-1', value: 50, color: '#f6e0b9' },
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These values change because we updated how colors are calculated. The changes should be pretty much indistinguishable.

  • #f1d9b9 -> #f6e0b9
  • #eba47a -> #eda77a

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for doing this, was actually on my list of things we needed to look into with the change of the theme

Copy link
Member

@afharo afharo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Core changes LGTM

@tkajtoch
Copy link
Member

FYI I'm investigating the increased bundle size

Copy link
Contributor

@MichaelMarcialis MichaelMarcialis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Left one curiosity question, but otherwise this LGTM. Assuming there is a good reason to hardcode those color values I'm asking about, I'll approve now to not hold you up.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There appears to be a slight issue with the aggs-based visualization tooltips. They used to be dark even for light theme so I can tweaks this in a follow-up to work with the new themes.

Before

image

After

image

@elasticmachine
Copy link
Contributor

⏳ Build in-progress

  • Buildkite Build
  • Commit: d84e16e
  • Kibana Serverless Image: docker.elastic.co/kibana-ci/kibana-serverless:pr-199993-d84e16efc7d3

History

Copy link
Contributor

@sebelga sebelga left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! I added a comment to create an issue to not lose track of the work to be done when Borealis is in public beta.
Approving to unblock you but it would be great to have it. Cheers 👍

@@ -52,6 +52,11 @@ export function parseThemeTags(input?: unknown): ThemeTags {
return DEFAULT_THEME_TAGS;
}

// TODO: remove when Borealis is in public beta
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we create an issue for this to not forget to remove this condition? And then update the comment with the link to the issue?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Surely! I'm going to create an issue shortly and will update the comment in a follow-up PR so that we don't need to wait for CI to pass again. Thanks for catching it!

@mgadewoll mgadewoll merged commit ee49986 into elastic:main Nov 19, 2024
46 checks passed
tsullivan added a commit to tsullivan/kibana that referenced this pull request Nov 21, 2024
maryam-saeidi added a commit to maryam-saeidi/kibana that referenced this pull request Nov 26, 2024
paulinashakirova pushed a commit to paulinashakirova/kibana that referenced this pull request Nov 26, 2024
## Summary

This PR introduces the first internal version of the new theme
`Borealis` and ensures that:
- themes can be switched between "Amsterdam" and "Borealis"
- theme-specific Sass files are available and can be loaded with
`KBN_OPTIMIZER_THEMES=experimental`
- legacy JSON variable usage accounts for both themes
- static template styles account for both themes


## Running locally

```yml
// kibana.dev.yml or kibana.yml
uiSettings.experimental.themeSwitcherEnabled: true
```

Start kibana
```
KBN_OPTIMIZER_THEMES='v8light,v8dark,borealislight,borealisdark' yarn start

or

KBN_OPTIMIZER_THEMES=experimental yarn start
```

### Checklist

- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios
- [ ] [Flaky Test
Runner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1) was
used on any tests changed

---------

Co-authored-by: Tomasz Kajtoch <tomasz.kajtoch@elastic.co>
CAWilson94 pushed a commit to CAWilson94/kibana that referenced this pull request Dec 12, 2024
## Summary

This PR introduces the first internal version of the new theme
`Borealis` and ensures that:
- themes can be switched between "Amsterdam" and "Borealis"
- theme-specific Sass files are available and can be loaded with
`KBN_OPTIMIZER_THEMES=experimental`
- legacy JSON variable usage accounts for both themes
- static template styles account for both themes


## Running locally

```yml
// kibana.dev.yml or kibana.yml
uiSettings.experimental.themeSwitcherEnabled: true
```

Start kibana
```
KBN_OPTIMIZER_THEMES='v8light,v8dark,borealislight,borealisdark' yarn start

or

KBN_OPTIMIZER_THEMES=experimental yarn start
```

### Checklist

- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios
- [ ] [Flaky Test
Runner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1) was
used on any tests changed

---------

Co-authored-by: Tomasz Kajtoch <tomasz.kajtoch@elastic.co>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport:skip This commit does not require backporting ci:project-deploy-observability Create an Observability project release_note:skip Skip the PR/issue when compiling release notes v9.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.