1. /**
    
  2.  * Copyright (c) Meta Platforms, Inc. and affiliates.
    
  3.  *
    
  4.  * This source code is licensed under the MIT license found in the
    
  5.  * LICENSE file in the root directory of this source tree.
    
  6.  *
    
  7.  * @flow
    
  8.  */
    
  9. 
    
  10. /* eslint-disable */
    
  11. 
    
  12. declare var __PROFILE__: boolean;
    
  13. declare var __UMD__: boolean;
    
  14. declare var __EXPERIMENTAL__: boolean;
    
  15. declare var __VARIANT__: boolean;
    
  16. 
    
  17. declare var __REACT_DEVTOOLS_GLOBAL_HOOK__: any; /*?{
    
  18.   inject: ?((stuff: Object) => void)
    
  19. };*/
    
  20. 
    
  21. declare var globalThis: Object;
    
  22. 
    
  23. declare var queueMicrotask: (fn: Function) => void;
    
  24. declare var reportError: (error: mixed) => void;
    
  25. declare var AggregateError: Class<Error>;
    
  26. 
    
  27. declare var FinalizationRegistry: any;
    
  28. 
    
  29. declare module 'create-react-class' {
    
  30.   declare var exports: React$CreateClass;
    
  31. }
    
  32. 
    
  33. // Flow hides the props of React$Element, this overrides it to unhide
    
  34. // them for React internals.
    
  35. // prettier-ignore
    
  36. declare opaque type React$Element<
    
  37.   +ElementType: React$ElementType,
    
  38.   +P = React$ElementProps<ElementType>,
    
  39. >: {
    
  40.   +type: ElementType,
    
  41.   +props: P,
    
  42.   +key: React$Key | null,
    
  43.   +ref: any,
    
  44. };
    
  45. 
    
  46. declare var trustedTypes: {
    
  47.   isHTML: (value: any) => boolean,
    
  48.   isScript: (value: any) => boolean,
    
  49.   isScriptURL: (value: any) => boolean,
    
  50.   // TrustedURLs are deprecated and will be removed soon: https://github.com/WICG/trusted-types/pull/204
    
  51.   isURL?: (value: any) => boolean,
    
  52. };
    
  53. 
    
  54. // ReactFeatureFlags www fork
    
  55. declare module 'ReactFeatureFlags' {
    
  56.   declare module.exports: any;
    
  57. }
    
  58. 
    
  59. // ReactFiberErrorDialog www fork
    
  60. declare module 'ReactFiberErrorDialog' {
    
  61.   declare module.exports: {showErrorDialog: (error: mixed) => boolean, ...};
    
  62. }
    
  63. 
    
  64. // EventListener www fork
    
  65. declare module 'EventListener' {
    
  66.   declare module.exports: {
    
  67.     listen: (
    
  68.       target: EventTarget,
    
  69.       type: string,
    
  70.       callback: Function,
    
  71.       priority?: number,
    
  72.       options?: {passive: boolean, ...},
    
  73.     ) => mixed,
    
  74.     capture: (target: EventTarget, type: string, callback: Function) => mixed,
    
  75.     captureWithPassiveFlag: (
    
  76.       target: EventTarget,
    
  77.       type: string,
    
  78.       callback: Function,
    
  79.       passive: boolean,
    
  80.     ) => mixed,
    
  81.     bubbleWithPassiveFlag: (
    
  82.       target: EventTarget,
    
  83.       type: string,
    
  84.       callback: Function,
    
  85.       passive: boolean,
    
  86.     ) => mixed,
    
  87.     ...
    
  88.   };
    
  89. }
    
  90. 
    
  91. declare function __webpack_chunk_load__(id: string): Promise<mixed>;
    
  92. declare var __webpack_require__: ((id: string) => any) & {
    
  93.   u: string => string,
    
  94. };
    
  95. 
    
  96. declare function __turbopack_load__(id: string): Promise<mixed>;
    
  97. declare var __turbopack_require__: ((id: string) => any) & {
    
  98.   u: string => string,
    
  99. };
    
  100. 
    
  101. declare module 'fs/promises' {
    
  102.   declare var access: (path: string, mode?: number) => Promise<void>;
    
  103.   declare var lstat: (
    
  104.     path: string,
    
  105.     options?: ?{bigint?: boolean},
    
  106.   ) => Promise<mixed>;
    
  107.   declare var readdir: (
    
  108.     path: string,
    
  109.     options?:
    
  110.       | ?string
    
  111.       | {
    
  112.           encoding?: ?string,
    
  113.           withFileTypes?: ?boolean,
    
  114.         },
    
  115.   ) => Promise<Buffer>;
    
  116.   declare var readFile: (
    
  117.     path: string,
    
  118.     options?:
    
  119.       | ?string
    
  120.       | {
    
  121.           encoding?: ?string,
    
  122.         },
    
  123.   ) => Promise<Buffer>;
    
  124.   declare var readlink: (
    
  125.     path: string,
    
  126.     options?:
    
  127.       | ?string
    
  128.       | {
    
  129.           encoding?: ?string,
    
  130.         },
    
  131.   ) => Promise<mixed>;
    
  132.   declare var realpath: (
    
  133.     path: string,
    
  134.     options?:
    
  135.       | ?string
    
  136.       | {
    
  137.           encoding?: ?string,
    
  138.         },
    
  139.   ) => Promise<mixed>;
    
  140.   declare var stat: (
    
  141.     path: string,
    
  142.     options?: ?{bigint?: boolean},
    
  143.   ) => Promise<mixed>;
    
  144. }
    
  145. declare module 'pg' {
    
  146.   declare var Pool: (options: mixed) => {
    
  147.     query: (query: string, values?: Array<mixed>) => void,
    
  148.   };
    
  149. }
    
  150. 
    
  151. declare module 'util' {
    
  152.   declare function debuglog(section: string): (data: any, ...args: any) => void;
    
  153.   declare function format(format: string, ...placeholders: any): string;
    
  154.   declare function log(string: string): void;
    
  155.   declare function inspect(object: any, options?: util$InspectOptions): string;
    
  156.   declare function isArray(object: any): boolean;
    
  157.   declare function isRegExp(object: any): boolean;
    
  158.   declare function isDate(object: any): boolean;
    
  159.   declare function isError(object: any): boolean;
    
  160.   declare function inherits(
    
  161.     constructor: Function,
    
  162.     superConstructor: Function,
    
  163.   ): void;
    
  164.   declare function deprecate(f: Function, string: string): Function;
    
  165.   declare function promisify(f: Function): Function;
    
  166.   declare function callbackify(f: Function): Function;
    
  167.   declare class TextDecoder {
    
  168.     constructor(
    
  169.       encoding?: string,
    
  170.       options?: {
    
  171.         fatal?: boolean,
    
  172.         ignoreBOM?: boolean,
    
  173.         ...
    
  174.       },
    
  175.     ): void;
    
  176.     decode(
    
  177.       input?: ArrayBuffer | DataView | $TypedArray,
    
  178.       options?: {stream?: boolean, ...},
    
  179.     ): string;
    
  180.     encoding: string;
    
  181.     fatal: boolean;
    
  182.     ignoreBOM: boolean;
    
  183.   }
    
  184.   declare class TextEncoder {
    
  185.     constructor(encoding?: string): TextEncoder;
    
  186.     encode(buffer: string): Uint8Array;
    
  187.     encodeInto(
    
  188.       buffer: string,
    
  189.       dest: Uint8Array,
    
  190.     ): {read: number, written: number};
    
  191.     encoding: string;
    
  192.   }
    
  193. }
    
  194. 
    
  195. declare module 'busboy' {
    
  196.   import type {Writable, Readable} from 'stream';
    
  197. 
    
  198.   declare interface Info {
    
  199.     encoding: string;
    
  200.     mimeType: string;
    
  201.   }
    
  202. 
    
  203.   declare interface FileInfo extends Info {
    
  204.     filename: string;
    
  205.   }
    
  206. 
    
  207.   declare interface FieldInfo extends Info {
    
  208.     nameTruncated: boolean;
    
  209.     valueTruncated: boolean;
    
  210.   }
    
  211. 
    
  212.   declare interface BusboyEvents {
    
  213.     file: (name: string, stream: Readable, info: FileInfo) => void;
    
  214.     field: (name: string, value: string, info: FieldInfo) => void;
    
  215.     partsLimit: () => void;
    
  216.     filesLimit: () => void;
    
  217.     fieldsLimit: () => void;
    
  218.     error: (error: mixed) => void;
    
  219.     close: () => void;
    
  220.   }
    
  221.   declare interface Busboy extends Writable {
    
  222.     addListener<Event: $Keys<BusboyEvents>>(
    
  223.       event: Event,
    
  224.       listener: BusboyEvents[Event],
    
  225.     ): Busboy;
    
  226.     addListener(
    
  227.       event: string | symbol,
    
  228.       listener: (...args: any[]) => void,
    
  229.     ): Busboy;
    
  230. 
    
  231.     on<Event: $Keys<BusboyEvents>>(
    
  232.       event: Event,
    
  233.       listener: BusboyEvents[Event],
    
  234.     ): Busboy;
    
  235.     on(event: string | symbol, listener: (...args: any[]) => void): Busboy;
    
  236. 
    
  237.     once<Event: $Keys<BusboyEvents>>(
    
  238.       event: Event,
    
  239.       listener: BusboyEvents[Event],
    
  240.     ): Busboy;
    
  241.     once(event: string | symbol, listener: (...args: any[]) => void): Busboy;
    
  242. 
    
  243.     removeListener<Event: $Keys<BusboyEvents>>(
    
  244.       event: Event,
    
  245.       listener: BusboyEvents[Event],
    
  246.     ): Busboy;
    
  247.     removeListener(
    
  248.       event: string | symbol,
    
  249.       listener: (...args: any[]) => void,
    
  250.     ): Busboy;
    
  251. 
    
  252.     off<Event: $Keys<BusboyEvents>>(
    
  253.       event: Event,
    
  254.       listener: BusboyEvents[Event],
    
  255.     ): Busboy;
    
  256.     off(event: string | symbol, listener: (...args: any[]) => void): Busboy;
    
  257. 
    
  258.     prependListener<Event: $Keys<BusboyEvents>>(
    
  259.       event: Event,
    
  260.       listener: BusboyEvents[Event],
    
  261.     ): Busboy;
    
  262.     prependListener(
    
  263.       event: string | symbol,
    
  264.       listener: (...args: any[]) => void,
    
  265.     ): Busboy;
    
  266. 
    
  267.     prependOnceListener<Event: $Keys<BusboyEvents>>(
    
  268.       event: Event,
    
  269.       listener: BusboyEvents[Event],
    
  270.     ): Busboy;
    
  271.     prependOnceListener(
    
  272.       event: string | symbol,
    
  273.       listener: (...args: any[]) => void,
    
  274.     ): Busboy;
    
  275.   }
    
  276. }
    
  277. 
    
  278. declare module 'pg/lib/utils' {
    
  279.   declare module.exports: {
    
  280.     prepareValue(val: any): mixed,
    
  281.   };
    
  282. }
    
  283. 
    
  284. declare class AsyncLocalStorage<T> {
    
  285.   disable(): void;
    
  286.   getStore(): T | void;
    
  287.   run(store: T, callback: (...args: any[]) => void, ...args: any[]): void;
    
  288.   enterWith(store: T): void;
    
  289. }
    
  290. 
    
  291. declare module 'async_hooks' {
    
  292.   declare class AsyncLocalStorage<T> {
    
  293.     disable(): void;
    
  294.     getStore(): T | void;
    
  295.     run(store: T, callback: (...args: any[]) => void, ...args: any[]): void;
    
  296.     enterWith(store: T): void;
    
  297.   }
    
  298. }
    
  299. 
    
  300. declare module 'node:worker_threads' {
    
  301.   declare class MessageChannel {
    
  302.     port1: MessagePort;
    
  303.     port2: MessagePort;
    
  304.   }
    
  305. }
    
  306. 
    
  307. declare var Bun: {
    
  308.   hash(
    
  309.     input: string | $TypedArray | DataView | ArrayBuffer | SharedArrayBuffer,
    
  310.   ): number,
    
  311. };