-
Notifications
You must be signed in to change notification settings - Fork 8.1k
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
[EuiProvider] Fix Security Solution code #183878
[EuiProvider] Fix Security Solution code #183878
Conversation
/ci |
Pinging @elastic/security-solution (Team: SecuritySolution) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you @tsullivan
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Greetings @tsullivan! I have tested the changes and haven't found any issues. I changed the language and turned the dark mode on – both do get applied to the modal.
I've also noticed that "mountReactNode" has its own "I18nProvider", so the content ends up being wrapped twice.
I wonder if it would be possible to move KibanaRenderContextProvider
inside mountReactNode
. If we manage to do that, then we won't have to pass startServices
here and will potentially cover more places at once. wdyt?
@nikitaindik great catch, and worthy of discussion. I would propose switching usage of The file in question is I put up a commit to do this, for your re-review: 97e75f8 |
💚 Build Succeeded
Metrics [docs]Module Count
Async chunks
History
To update your PR or re-run it, just comment with: cc @tsullivan |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for adding the change @tsullivan! I have re-tested it locally and haven't found any issues. Can confirm that there are no duplication of I18nProvider
.
## Summary Fixes needed for getting CI to pass when EUI throws an error if attempting to render a component without the EuiProvider in the render tree. ## Detailed description In elastic#180819, I will deliver a change that will cause EUI components to throw an error if the EuiProvider context is missing. This PR comes in as part of the final work to get all functional tests passing in an environment where EUI will throw the error. The tied to the ["Fix 'dark mode' inconsistencies in Kibana" Epic](elastic/kibana-team#805) has so far been in preparation for this. **Reviewers: Please interact with critical paths through the UI components touched in this PR, ESPECIALLY in terms of testing dark mode and i18n.** <img width="1107" alt="image" src="https://github.com/elastic/kibana/assets/908371/c0d2ce08-ac35-45a7-8192-0b2256fceb0e"> ### Checklist Delete any items that are not applicable to this PR. - [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 - [ ] This renders correctly on smaller devices using a responsive layout. (You can test this [in your browser](https://www.browserstack.com/guide/responsive-testing-on-local-server)) - [ ] This was checked for [cross-browser compatibility](https://www.elastic.co/support/matrix#matrix_browsers) --------- Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Summary
Fixes needed for getting CI to pass when EUI throws an error if attempting to render a component without the EuiProvider in the render tree.
Detailed description
In #180819, I will deliver a change that will cause EUI components to throw an error if the EuiProvider context is missing. This PR comes in as part of the final work to get all functional tests passing in an environment where EUI will throw the error. The tied to the "Fix 'dark mode' inconsistencies in Kibana" Epic has so far been in preparation for this.
Reviewers: Please interact with critical paths through the UI components touched in this PR, ESPECIALLY in terms of testing dark mode and i18n.
Checklist
Delete any items that are not applicable to this PR.