HEX
Server: nginx/1.18.0
System: Linux test-ipsremont 5.4.0-214-generic #234-Ubuntu SMP Fri Mar 14 23:50:27 UTC 2025 x86_64
User: ips (1000)
PHP: 8.0.30
Disabled: pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare,
Upload Files
File: /var/www/design.system/node_modules/@rushstack/terminal/lib/TerminalStreamWritable.js.map
{"version":3,"file":"TerminalStreamWritable.js","sourceRoot":"","sources":["../src/TerminalStreamWritable.ts"],"names":[],"mappings":";AAAA,4FAA4F;AAC5F,2DAA2D;;;AAE3D,mCAAwD;AAExD,2DAA+D;AAsB/D;;;;GAIG;AACH,MAAa,sBAAuB,SAAQ,iBAAQ;IAGlD,YAAmB,OAAuC;QACxD,MAAM,EAAE,QAAQ,EAAE,QAAQ,EAAE,eAAe,EAAE,GAAG,OAAO,CAAC;QACxD,KAAK,CAAC,eAAe,CAAC,CAAC;QAEvB,IAAI,CAAC,OAAO,GAAG,SAAS,CAAC;QACzB,QAAQ,QAAQ,EAAE,CAAC;YACjB,KAAK,4CAAwB,CAAC,GAAG;gBAC/B,IAAI,CAAC,YAAY,GAAG,QAAQ,CAAC,KAAK,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;gBAClD,MAAM;YACR,KAAK,4CAAwB,CAAC,OAAO;gBACnC,IAAI,CAAC,YAAY,GAAG,QAAQ,CAAC,YAAY,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;gBACzD,MAAM;YACR,KAAK,4CAAwB,CAAC,KAAK;gBACjC,IAAI,CAAC,YAAY,GAAG,QAAQ,CAAC,UAAU,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;gBACvD,MAAM;YACR,KAAK,4CAAwB,CAAC,OAAO;gBACnC,IAAI,CAAC,YAAY,GAAG,QAAQ,CAAC,YAAY,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;gBACzD,MAAM;YACR,KAAK,4CAAwB,CAAC,KAAK;gBACjC,IAAI,CAAC,YAAY,GAAG,QAAQ,CAAC,UAAU,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;gBACvD,MAAM;YACR;gBACE,MAAM,IAAI,KAAK,CAAC,qBAAqB,QAAQ,EAAE,CAAC,CAAC;QACrD,CAAC;IACH,CAAC;IAEM,MAAM,CACX,KAAmC,EACnC,QAAgB;IAChB,kDAAkD;IAClD,QAAwC;QAExC,IAAI,CAAC;YACH,MAAM,SAAS,GAAoB,OAAO,KAAK,KAAK,QAAQ,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;YAC1F,IAAI,CAAC,YAAY,CAAC,SAAS,CAAC,QAAQ,EAAE,CAAC,CAAC;QAC1C,CAAC;QAAC,OAAO,CAAU,EAAE,CAAC;YACpB,QAAQ,CAAC,CAAU,CAAC,CAAC;YACrB,OAAO;QACT,CAAC;QACD,QAAQ,EAAE,CAAC;IACb,CAAC;CACF;AA5CD,wDA4CC","sourcesContent":["// Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license.\n// See LICENSE in the project root for license information.\n\nimport { Writable, type WritableOptions } from 'stream';\nimport type { ITerminal } from './ITerminal';\nimport { TerminalProviderSeverity } from './ITerminalProvider';\n\n/**\n * Options for {@link TerminalStreamWritable}.\n *\n * @beta\n */\nexport interface ITerminalStreamWritableOptions {\n  /**\n   * The {@link ITerminal} that the Writable will write to.\n   */\n  terminal: ITerminal;\n  /**\n   * The severity of the messages that will be written to the {@link ITerminal}.\n   */\n  severity: TerminalProviderSeverity;\n  /**\n   * Options for the underlying Writable.\n   */\n  writableOptions?: WritableOptions;\n}\n\n/**\n * A adapter to allow writing to a provided terminal using Writable streams.\n *\n * @beta\n */\nexport class TerminalStreamWritable extends Writable {\n  private _writeMethod: (data: string) => void;\n\n  public constructor(options: ITerminalStreamWritableOptions) {\n    const { terminal, severity, writableOptions } = options;\n    super(writableOptions);\n\n    this._writev = undefined;\n    switch (severity) {\n      case TerminalProviderSeverity.log:\n        this._writeMethod = terminal.write.bind(terminal);\n        break;\n      case TerminalProviderSeverity.verbose:\n        this._writeMethod = terminal.writeVerbose.bind(terminal);\n        break;\n      case TerminalProviderSeverity.debug:\n        this._writeMethod = terminal.writeDebug.bind(terminal);\n        break;\n      case TerminalProviderSeverity.warning:\n        this._writeMethod = terminal.writeWarning.bind(terminal);\n        break;\n      case TerminalProviderSeverity.error:\n        this._writeMethod = terminal.writeError.bind(terminal);\n        break;\n      default:\n        throw new Error(`Unknown severity: ${severity}`);\n    }\n  }\n\n  public _write(\n    chunk: string | Buffer | Uint8Array,\n    encoding: string,\n    // eslint-disable-next-line @rushstack/no-new-null\n    callback: (error?: Error | null) => void\n  ): void {\n    try {\n      const chunkData: string | Buffer = typeof chunk === 'string' ? chunk : Buffer.from(chunk);\n      this._writeMethod(chunkData.toString());\n    } catch (e: unknown) {\n      callback(e as Error);\n      return;\n    }\n    callback();\n  }\n}\n"]}