You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In order to make guacamole more TS friendly we've created the following declaration file based on how the guacamole-lite app has been built.
// guacamole-lite.d.ts// See: https://stackoverflow.com/a/49936686/7931540typeDeepPartial<T>={[PinkeyofT]?: T[P]extendsArray<infer U>
? Array<DeepPartial<U>>
: T[P]extendsReadonlyArray<infer U>
? ReadonlyArray<DeepPartial<U>>
: DeepPartial<T[P]>;};declare module "guacamole-lite"{// See packages/client/models/guacamole.ts for other guacamole related types which should be served by "guacamole-lite"/** * This should have next type structure: https://github.com/websockets/ws/blob/master/doc/ws.md#new-websocketserveroptions-callback [1] * But guacamole-lite is using a really old version(1.1.2) of ws(now 8.13.0) */exportinterfaceWsServerOptions{port?: number;}/* * This configuration object is used inside the guacamole-lite server to establish the connection with the guacd using the following overload of `Net.connect` * function connect(port: number, host?: string, connectionListener?: () => void): Socket; * See: https://github.com/vadimpronin/guacamole-lite/blob/d2f4ce1ec1847781ca3667066c9e286624d8e432/lib/GuacdClient.js#L23 */exportinterfaceGuacdConnectOptions{port?: number;host?: string;}enumGuacamoleLogLevel{QUIET=0,ERRORS=10,NORMAL=20,VERBOSE=30,DEBUG=40,}/** * This configuration object comes from this lines of code used inside the Server.js * See: https://github.com/vadimpronin/guacamole-lite/blob/d2f4ce1ec1847781ca3667066c9e286624d8e432/lib/Server.js#L34-L107 */interface__GuacamoleClientOptions{maxInactivityTime: number;log: {level: GuacamoleLogLevel;stdLog: typeofconsole.log;errorLog: typeofconsole.error;};crypt: {cypher: string;};connectionDefaultSettings: {rdp: {args: string;port: string;width: number;height: number;dpi: number;};vnc: {args: string;port: string;width: number;height: number;dpi: number;};ssh: {args: string;port: number;width: number;height: number;dpi: number;};telnet: {args: string;port: number;width: number;height: number;dpi: number;};};allowedUnencryptedConnectionSettings: {rdp: string[];vnc: string[];ssh: string[];telnet: string[];};}exporttypeGuacamoleClientOptions=DeepPartial<__GuacamoleClientOptions>&{crypt: {key: string;};};exportdefaultclassGuacamoleLite{constructor(websocketOptions: WsServerOptions,guacdOptions: GuacdConnectOptions,clientOptions: GuacamoleClientOptions);}}
The text was updated successfully, but these errors were encountered:
In order to make guacamole more TS friendly we've created the following declaration file based on how the guacamole-lite app has been built.
The text was updated successfully, but these errors were encountered: