kibana/packages/kbn-management
Clint Andrew Hall 1546490e98
[settings] Extract and fix Section Registry (#163502)
## Summary

While working to extract various portions of the `advancedSettings`
plugin into packages, I found the `ComponentRegistry` in the plugin to
have a number of issues that contributed to a fairly bad UX:

- the API allows for adding/overriding the title, subtitle and footer of
the Advanced Settings page, but only the footer is rendered.
- the API is available to all plugins, but only renders a single
entry... so depending on the plugin load order, the render is not
guaranteed.
- filtering the footer in or out of the display is delegated to the
component itself, so:
  - it only takes effect on render.
- the count is only updated if you click on the page that contains it,
but that logic is currently broken.
  - the error message is inaccurate.

![Aug-09-2023
11-19-06](494aba14-f2c0-4ce7-b3f0-1910824aeb0e)

This PR fixes those issues and more:

- extracts the registry into its own package.
- changes the API to allow for multiple sections from multiple plugins.
- changes the API to filter these sections from the plugin, rather than
from each individual component.
- fixes state management to show sections, keep counts accurate, etc.

![Aug-09-2023
11-02-11](d8e8033c-f9ed-4615-b954-b5c23fda4d7a)

---------

Co-authored-by: Vadim Kibana <82822460+vadimkibana@users.noreply.github.com>
2023-08-14 11:00:33 -07:00
..
cards_navigation [Management] Update landing page links (#162608) 2023-08-01 13:59:29 +03:00
settings/section_registry [settings] Extract and fix Section Registry (#163502) 2023-08-14 11:00:33 -07:00
storybook/config [Deployment Management] Add cards navigation in management landing page for serverless (#160096) 2023-06-30 11:27:56 +02:00