Prevented clearAll from removing non-deletable widgets
Signed-off-by: Jasper Boeijenga <jboeijenga@gmail.com>
This commit is contained in:
@@ -0,0 +1,5 @@
|
||||
---
|
||||
'@backstage/plugin-home': patch
|
||||
---
|
||||
|
||||
Fixed bug in CustomHomepageGrid where clearAll did not respect the deletable flag on widgets
|
||||
@@ -275,7 +275,7 @@ export const CustomHomepageGrid = (props: CustomHomepageGridProps) => {
|
||||
};
|
||||
|
||||
const clearLayout = () => {
|
||||
setWidgets([]);
|
||||
setWidgets(widgets.filter(w => !w.deletable));
|
||||
};
|
||||
|
||||
const changeEditMode = (mode: boolean) => {
|
||||
|
||||
Reference in New Issue
Block a user