stable

Clone or download

Read-only

Provide the sidebar configuration globally

This let us inject the configuration in all our components. While this still quite manageable at this time this approach will avoid prop drilling when the component hierarchy becomes bigger in upcoming contributions. Since what we do with the sidebar configuration is quite simple and never mutate inside the component having a full blown store like Pinia does not seem necessary. Part of request #23465 Publish a project sidebar custom element Change-Id: Iaee1cfeee32cc49a1b68b5b05e23e2abf59b2493

Modified Files

Name
M src/scripts/lib/project-sidebar/src/ProjectSidebar.vue +7 −10 Go to diff View file
M src/scripts/lib/project-sidebar/src/SidebarFooter.test.ts +24 −6 Go to diff View file
M src/scripts/lib/project-sidebar/src/SidebarFooter.vue +13 −11 Go to diff View file
M src/scripts/lib/project-sidebar/src/SidebarHeader.test.ts +6 −3 Go to diff View file
M src/scripts/lib/project-sidebar/src/SidebarHeader.vue +7 −5 Go to diff View file
M src/scripts/lib/project-sidebar/src/__snapshots__/ProjectSidebar.test.ts.snap +2 −8 Go to diff View file
M src/scripts/lib/project-sidebar/src/configuration.ts +1 −1 Go to diff View file
A src/scripts/lib/project-sidebar/src/injection-symbols.ts +27 −0 Go to diff View file
A src/scripts/lib/project-sidebar/src/strict-inject.test.ts +64 −0 Go to diff View file
A src/scripts/lib/project-sidebar/src/strict-inject.ts +33 −0 Go to diff View file