@@ -25,23 +25,35 @@ export interface CanvasHistory {
2525 label : string ;
2626}
2727
28+ /**
29+ * @see https://wicg.github.io/file-system-access/#api-filesystemdirectoryhandle-getdirectoryhandle
30+ */
2831export interface DirectoryHandler {
2932 entries : ( ) => FileIterator ;
3033 getDirectoryHandle : ( path : string ) => Promise < DirectoryHandler > ;
3134 getFileHandle : ( path : string ) => Promise < FileHandler > ;
3235}
3336
37+ /**
38+ * @see https://wicg.github.io/file-system-access/#api-filesystemdirectoryhandle-asynciterable
39+ */
3440export interface FileIterator {
3541 next : ( ) => {
3642 done : boolean ;
3743 value ?: [ string , FileHandler ] ;
3844 } ;
3945}
4046
47+ /**
48+ * @see https://wicg.github.io/file-system-access/#api-filesystemdirectoryhandle-getfilehandle
49+ */
4150export interface FileHandler {
4251 getFile : ( ) => Promise < File > ;
4352}
4453
54+ /**
55+ * @see https://wicg.github.io/file-system-access/#api-filesystemfilehandle-getfile
56+ */
4557export interface File {
4658 slice : ( ) => Promise < Blob > ;
4759 text : ( ) => Promise < string > ;
@@ -69,16 +81,18 @@ export interface InteractiveCanvasWindow extends Window {
6981 title : string ;
7082 projectId : string ;
7183 /**
72- * base64 representation of the project's logo
84+ * base64 representation of the project's logo.
7385 */
7486 logoSrcData : string ;
7587 } ;
7688 /**
77- * JSYaml is a 3P library that converts YAML to JSON
89+ * JSYaml is a 3P library that converts YAML to JSON.
90+ * @see https://www.npmjs.com/package/js-yaml
7891 */
7992 jsyaml : JSYaml ;
8093 /**
81- * A browser operation that opens a file directory selector
94+ * A browser operation that opens a file directory selector.
95+ * @see https://web.dev/file-system-access/
8296 */
8397 showDirectoryPicker : ( ) => Promise < DirectoryHandler > ;
8498}
0 commit comments