Add lib panel from empty dashboard page (#83522)
* wip * tests + refactor ad panel func * Add row functionality * update row state only when there are children * Add new row + copy paste panels * Add library panel functionality * tests * PR mods * reafctor + tests * reafctor * fix test * refactor * fix bug on cancelling lib widget * dashboard now saves with lib panel widget * add lib panels widget works in rows as well * split add lib panel func to another PR * Add library panel functionality * Add lib panel from empty dashboard page * refactor * take panelKey into account when getting next panel id in dashboard * fix tests
This commit is contained in:
@@ -113,7 +113,7 @@ const DashboardEmpty = ({ dashboard, canCreate }: Props) => {
|
|||||||
onClick={() => {
|
onClick={() => {
|
||||||
DashboardInteractions.emptyDashboardButtonClicked({ item: 'import_from_library' });
|
DashboardInteractions.emptyDashboardButtonClicked({ item: 'import_from_library' });
|
||||||
if (dashboard instanceof DashboardScene) {
|
if (dashboard instanceof DashboardScene) {
|
||||||
// TODO: dashboard scene logic for adding a library panel
|
dashboard.onCreateLibPanelWidget();
|
||||||
} else {
|
} else {
|
||||||
onAddLibraryPanel(dashboard);
|
onAddLibraryPanel(dashboard);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user