File tree Expand file tree Collapse file tree 1 file changed +33
-0
lines changed
arduino-ide-extension/src/common/protocol Expand file tree Collapse file tree 1 file changed +33
-0
lines changed Original file line number Diff line number Diff line change @@ -8,6 +8,7 @@ export interface LibraryService
8
8
extends Installable < LibraryPackage > ,
9
9
Searchable < LibraryPackage > {
10
10
list ( options : LibraryService . List . Options ) : Promise < LibraryPackage [ ] > ;
11
+ search ( options : LibrarySearch ) : Promise < LibraryPackage [ ] > ;
11
12
/**
12
13
* When `installDependencies` is not set, it is `true` by default. If you want to skip the installation of required dependencies, set it to `false`.
13
14
*/
@@ -38,6 +39,38 @@ export interface LibraryService
38
39
} ) : Promise < LibraryDependency [ ] > ;
39
40
}
40
41
42
+ export interface LibrarySearch extends Searchable . Options {
43
+ readonly type ?: LibrarySearch . Type ;
44
+ readonly topic ?: LibrarySearch . Topic ;
45
+ }
46
+ export namespace LibrarySearch {
47
+ export const TypeLiterals = [
48
+ 'All' ,
49
+ 'Updatable' ,
50
+ 'Installed' ,
51
+ 'Arduino' ,
52
+ 'Partner' ,
53
+ 'Recommended' ,
54
+ 'Contributed' ,
55
+ 'Retired' ,
56
+ ] as const ;
57
+ export type Type = typeof TypeLiterals [ number ] ;
58
+ export const TopicLiterals = [
59
+ 'All' ,
60
+ 'Communication' ,
61
+ 'Data Processing' ,
62
+ 'Data Storage' ,
63
+ 'Device Control' ,
64
+ 'Display' ,
65
+ 'Others' ,
66
+ 'Sensors' ,
67
+ 'Signal Input/Output' ,
68
+ 'Timing' ,
69
+ 'Uncategorized' ,
70
+ ] ;
71
+ export type Topic = typeof TopicLiterals [ number ] ;
72
+ }
73
+
41
74
export namespace LibraryService {
42
75
export namespace List {
43
76
export interface Options {
You can’t perform that action at this time.
0 commit comments