-
Notifications
You must be signed in to change notification settings - Fork 8.2k
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
[Workplace Search] Migrates Org Settings tree #88092
[Workplace Search] Migrates Org Settings tree #88092
Conversation
Only does linting changes and lodash import
Use useLocation and no longer pass around history, using the KibanaLogic navigateToUrl method instead
Also change name of component to OauthApplication as the default import was named that before
This is no longer needed with the Kibana syntax. Flash messages are set globally and only render when present.
In Kibana, we use the Eui components directly
We no longer control telemetry in Workplace Search. It is handled by Kibana itself
The global org name is not used anywhere outside of this section so we no longer need to update the global organization object as it is re-fetched when this section is entered. Previously, we displayed the org name in the sidebar but that has been removed in Kibana
We recently split out the logic from SourceLogic to the new AddSourceLogic and in settings, we were calling the saveSourceConfig method from the SourceLogic (now in AddSourceLogic) file and passing a callback that set the flash messages from that component’s state. Now, we set the flash messages globally and no longer need to have a saveUpdatedConfig method in the logic file, but can call it directly in the component and the flash messages will be set globally.
We use this method across both Enterprise Search products in Kibana
This would be the only place in the sidebar with a nav item breaking to a second line.
This happens automatically now in the global flash messages logic; route changes trigger clearing of messages
@elasticmachine merge upstream |
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.
LGTM! Only 1 minor typo:
); | ||
|
||
export const CREDENTIALS_TITLE = i18n.translate( | ||
'xpack.enterpriseSearch.workplaceSearch.credentials.desctitleription', |
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.
'xpack.enterpriseSearch.workplaceSearch.credentials.desctitleription', | |
'xpack.enterpriseSearch.workplaceSearch.credentials.title', |
@elasticmachine merge upstream |
@elasticmachine merge upstream |
Copied from this PR: elastic#88525
💚 Build SucceededMetrics [docs]Module Count
Async chunks
History
To update your PR or re-run it, just comment with: |
* Initial copy/paste of component tree Only does linting changes and lodash import * Replace withRouter HOC with hooks Use useLocation and no longer pass around history, using the KibanaLogic navigateToUrl method instead * Migrate LicenseCallout component * Update paths Also change name of component to OauthApplication as the default import was named that before * Remove conditional and passed in flash messages This is no longer needed with the Kibana syntax. Flash messages are set globally and only render when present. * Replace removed ConfirmModal In Kibana, we use the Eui components directly * Use internal tools for determining license * Fix a bunch of type issues * Remove telemetry settings section We no longer control telemetry in Workplace Search. It is handled by Kibana itself * Add SettingsSubNav component * Add route and update nav * Remove legacy AppView and sidenav * Clear flash messages globally * Remove global name change method call The global org name is not used anywhere outside of this section so we no longer need to update the global organization object as it is re-fetched when this section is entered. Previously, we displayed the org name in the sidebar but that has been removed in Kibana * Refactor saveUpdatedConfig We recently split out the logic from SourceLogic to the new AddSourceLogic and in settings, we were calling the saveSourceConfig method from the SourceLogic (now in AddSourceLogic) file and passing a callback that set the flash messages from that component’s state. Now, we set the flash messages globally and no longer need to have a saveUpdatedConfig method in the logic file, but can call it directly in the component and the flash messages will be set globally. * Update logic file to use global flash messages * Update server routes * Replace Rails http with kibana http * Fix subnav * Update routes to use consistent syntax We use this method across both Enterprise Search products in Kibana * Shorten nav item copy This would be the only place in the sidebar with a nav item breaking to a second line. * Fix some random typos * Replace React Router Link with helper * Add i18n * Remove redundant clearing of flash messages This happens automatically now in the global flash messages logic; route changes trigger clearing of messages * Add unit tests for components * Add tests for router * Store oauthApplication in mock for reuse * Add tests for SettingsLogic * Fix typo * Remove unncessary imports Copied from this PR: elastic#88525 * Refactor to use new helpers when mocking See elastic#88494 * Update logic test to use error helper See elastic#88422 * Fix type issue * Fix whitespace lint issue Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Summary
This PR migrates the Org Settings tree from
ent-search
.Checklist