feat: new UX for the boards/library manager widgets

Closes #19
Closes #781
Closes #1591
Closes #1607
Closes #1697
Closes #1707
Closes #1924
Closes #1941

Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
This commit is contained in:
Akos Kitta
2023-03-01 18:02:45 +01:00
committed by Akos Kitta
parent 58aac236bf
commit 2aad0e3b16
29 changed files with 1409 additions and 504 deletions

View File

@@ -118,6 +118,16 @@ export class ExamplesServiceImpl implements ExamplesService {
return { user, current, any };
}
async find(options: { libraryName: string }): Promise<SketchContainer[]> {
const { libraryName } = options;
const packages = await this.libraryService.list({ libraryName });
return Promise.all(
packages
.filter(({ location }) => location === LibraryLocation.USER)
.map((pkg) => this.tryGroupExamples(pkg))
);
}
/**
* The CLI provides direct FS paths to the examples so that menus and menu groups cannot be built for the UI by traversing the
* folder hierarchy. This method tries to workaround it by falling back to the `installDirUri` and manually creating the