DashboardListPanel: Fixes issue with folder picker always showing All and using old form styles (#31160)

This commit is contained in:
Torkel Ödegaard 2021-02-12 10:29:59 +01:00 committed by GitHub
parent a18e4d8d64
commit a17661d198
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -45,7 +45,15 @@ export const plugin = new PanelPlugin<DashListOptions>(DashList)
id: 'folderId',
defaultValue: null,
editor: function RenderFolderPicker(props) {
return <FolderPicker initialTitle="All" enableReset={true} onChange={({ id }) => props.onChange(id)} />;
return (
<FolderPicker
initialFolderId={props.value}
useNewForms
initialTitle="All"
enableReset={true}
onChange={({ id }) => props.onChange(id)}
/>
);
},
})
.addCustomEditor({