Skip to content

Conversation

@ryankeairns
Copy link
Contributor

@ryankeairns ryankeairns commented Sep 19, 2025

Closes #9039

Summary

For the Borealis theme:

  • Decrease title-to-body spacing from 'm' to 's' (16px → 8px)
  • Decrease body-to-actions spacing from 'l' to 'm' (24px → 16px)
  • Decrease default padding from 'l' to 'm' (24px → 16px)
  • Create _spacing.ts file following established theme config patterns
  • Extend EuiThemeShape to include custom spacing property
  • Update both light and dark Borealis theme JSON files
  • Modify EuiEmptyPrompt to use new theme-based spacing values
  • Update snapshot tests to reflect new spacing values

Amsterdam theme remains unchanged

Screenshots

Borealis before (left) and after (right)

CleanShot 2025-09-19 at 14 01 55@2x CleanShot 2025-09-19 at 14 02 17@2x

Amsterdam before and after (unchanged)

CleanShot 2025-09-19 at 14 03 13@2x

QA

Remove or strikethrough items that do not apply to your PR.

General checklist

  • Browser QA
    • Checked in both light and dark modes
    • Checked in both MacOS and Windows high contrast modes
    • Checked in mobile
    • Checked in Chrome, Safari, Edge, and Firefox
    • Checked for accessibility including keyboard-only and screenreader modes
  • Docs site QA
  • Code quality checklist
  • Release checklist
    • A changelog entry exists and is marked appropriately.
    • If applicable, added the breaking change issue label (and filled out the breaking change checklist)
  • Designer checklist
    • If applicable, file an issue to update EUI's Figma library with any corresponding UI changes. (This is an internal repo, if you are external to Elastic, ask a maintainer to submit this request)

- Decrease title-to-body spacing from 'm' to 's' (16px → 8px)
- Decrease body-to-actions spacing from 'l' to 'm' (24px → 16px)
- Decrease default padding from 'l' to 'm' (24px → 16px)
- Create _spacing.ts file following established theme patterns
- Extend EuiThemeShape to include custom spacing property
- Update both light and dark Borealis theme JSON files
- Modify EuiEmptyPrompt to use theme-based spacing values
- Update snapshot tests to reflect new spacing values
- Amsterdam theme remains unchanged

Addresses #9039
@ryankeairns ryankeairns changed the title feat: reduce EuiEmptyPrompt spacing in Borealis theme Reduce EuiEmptyPrompt spacing in Borealis theme Sep 19, 2025
@ryankeairns ryankeairns marked this pull request as ready for review September 19, 2025 21:59
@ryankeairns ryankeairns requested a review from a team as a code owner September 19, 2025 21:59
@weronikaolejniczak
Copy link
Contributor

@ryankeairns awesome! 🚀 One thing we're missing is the VRT images. Could you update them by running yarn workspace @elastic/eui test-visual-regression update and verify manually if the changes are as expected?

@weronikaolejniczak
Copy link
Contributor

@ryankeairns btw we'd need a changelog for eui-theme-borealis as well. Otherwise, it won't be released 😄

@ryankeairns
Copy link
Contributor Author

Thanks @weronikaolejniczak , will do!

- Update .loki reference images to reflect reduced spacing in Borealis theme
- Add changelog entry for emptyPrompt spacing theme defaults
@ryankeairns
Copy link
Contributor Author

@weronikaolejniczak ready for another look!

@elasticmachine
Copy link
Collaborator

💚 Build Succeeded

History

@elasticmachine
Copy link
Collaborator

💚 Build Succeeded

History

Copy link
Contributor

Choose a reason for hiding this comment

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

@ryankeairns I'm thinking, we have the "Components" tokens, maybe it'd be better to add an emptyPrompt property there with the spacing values? 🤔 I believe it'd be more consistent and expected. We would have to update the documentation while we're at it.

Let me know what you think! And sorry for the back-and-forth, I just believe it's worth mentioning 💚

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Can you explain that further?

No worries on the back and forth. I'm hoping to find some patterns as I intend to do more theme overrides.

Copy link
Contributor Author

@ryankeairns ryankeairns Sep 24, 2025

Choose a reason for hiding this comment

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

So it would be something like adding these new tokens:

  • euiTheme.components.emptyPrompt.titleBodySpacing
  • euiTheme.components.emptyPrompt.bodyActionsSpacing
  • euiTheme.components.emptyPrompt.paddingSize
    ... and then wiring those in?

Then adding a section to the docs per component? (e.g. as we have Buttons today; or maybe a Components section?)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@weronikaolejniczak Opened a new PR, based on the same branch, that reworks to use theme component tokens
#9057

@weronikaolejniczak
Copy link
Contributor

@ryankeairns did you have a chance to run yarn workspace @elastic/eui test-visual-regression update? You can push any updates to this PR, this way we can track visual regression!

@ryankeairns
Copy link
Contributor Author

@ryankeairns did you have a chance to run yarn workspace @elastic/eui test-visual-regression update? You can push any updates to this PR, this way we can track visual regression!

Yes, it added one updated png. Should there be more? I can run it again.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@weronikaolejniczak here's the sole visual regression that was added.

@ryankeairns
Copy link
Contributor Author

ryankeairns commented Sep 24, 2025

Reverted to Draft.
Likely to be replaced by #9057 which take the theme component tokens approach, as suggested.

@ryankeairns ryankeairns marked this pull request as draft September 24, 2025 21:47
@ryankeairns
Copy link
Contributor Author

closing in favor of #9057

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[EuiEmptyPrompt] Decrease default spacing

4 participants