Wildcard [Charts]: Move charts to the wildcard package
Created by: vovakulikov
Closes https://github.com/sourcegraph/sourcegraph/issues/39955 Blocker for https://github.com/sourcegraph/sourcegraph/pull/40138
Background
Code Insights team is working on a new UI for the search result page. This UI implies using chart components on the search page. Currently, the chart components are stored in the web
package. The web package depends on the search-ui
package. If we want to reuse chart components in the search-ui
package, this will lead us to cyclic dependency (web → search-UI → web).
In order to resolve this, we have to move chart components into a separate package (or wildcard package). The chart components are consumer agnostic, don't use any code insights specific logic and already have been used in more than one place in the app (at the moment, they have two primary consumers, code insights and site admin page). So based on this, I think putting them in the wildcard makes sense. This also may lead to better usage since they will be more accessible.
Follow-ups
- Currently, chart components don't have good docs, we have an issue, and this will be addressed later (but I hope shortly) https://github.com/sourcegraph/sourcegraph/issues/39878
- Chart components don't have a clear design in the Figma wildcard components. https://github.com/sourcegraph/sourcegraph/issues/40210
- https://github.com/sourcegraph/sourcegraph/issues/40253
Test plan
- Make sure that code insights don't have any visual regressions
- Make sure that site admin pages don't have any visual regressions
App preview:
Check out the client app preview documentation to learn more.