File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -98,30 +98,29 @@ import CommonFormats, { Category } from "src/CommonFormats.ts";
9898class dummyHandler implements FormatHandler {
9999
100100 public name: string = " dummy" ;
101- public supportedFormats? : FileFormat [];
101+ public supportedFormats: FileFormat [] = [
102+ // Example PNG format, with both input and output disabled
103+ CommonFormats .PNG .builder (" png" )
104+ .markLossless ()
105+ .allowFrom (false )
106+ .allowTo (false ),
107+
108+ // Alternatively, if you need a custom format, define it like so:
109+ {
110+ name: " CompuServe Graphics Interchange Format (GIF)" ,
111+ format: " gif" ,
112+ extension: " gif" ,
113+ mime: " image/gif" ,
114+ from: false ,
115+ to: false ,
116+ internal: " gif" ,
117+ category: [Category .IMAGE , CATEGORY .VIDEO ], // See src/CommonFormats.ts for valid categories
118+ lossless: false
119+ },
120+ ];
102121 public ready: boolean = false ;
103122
104123 async init () {
105- this .supportedFormats = [
106- // Example PNG format, with both input and output disabled
107- CommonFormats .PNG .builder (" png" )
108- .markLossless ()
109- .allowFrom (false )
110- .allowTo (false ),
111-
112- // Alternatively, if you need a custom format, define it like so:
113- {
114- name: " CompuServe Graphics Interchange Format (GIF)" ,
115- format: " gif" ,
116- extension: " gif" ,
117- mime: " image/gif" ,
118- from: false ,
119- to: false ,
120- internal: " gif" ,
121- category: [Category .IMAGE , CATEGORY .VIDEO ], // See src/CommonFormats.ts for valid categories
122- lossless: false
123- },
124- ];
125124 this .ready = true ;
126125 }
127126
You can’t perform that action at this time.
0 commit comments