@esposter/shared 2.36.0 → 2.37.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -1,13 +1,13 @@
1
1
  import { z } from "zod";
2
2
  import baseSanitizeHtml from "sanitize-html";
3
- declare const AllSpecialValues: {
3
+ export declare const AllSpecialValues: {
4
4
  isPlainObject: boolean;
5
5
  value: unknown;
6
6
  }[];
7
- declare class ForbiddenError extends Error {
7
+ export declare class ForbiddenError extends Error {
8
8
  constructor(message: string);
9
9
  }
10
- declare enum Operation {
10
+ export declare enum Operation {
11
11
  Create = "Create",
12
12
  Delete = "Delete",
13
13
  Push = "Push",
@@ -15,28 +15,28 @@ declare enum Operation {
15
15
  Unshift = "Unshift",
16
16
  Update = "Update"
17
17
  }
18
- declare class InvalidOperationError extends Error {
18
+ export declare class InvalidOperationError extends Error {
19
19
  constructor(operation: Operation, name: string, message: string);
20
20
  }
21
- declare class NotFoundError<T extends string = string> extends Error {
21
+ export declare class NotFoundError<T extends string = string> extends Error {
22
22
  constructor(name: T, id: string);
23
23
  }
24
- declare class NotInitializedError<T extends string = string> extends Error {
24
+ export declare class NotInitializedError<T extends string = string> extends Error {
25
25
  constructor(name: T);
26
26
  }
27
- declare class WordFilteredError extends Error {
27
+ export declare class WordFilteredError extends Error {
28
28
  constructor(message: string);
29
29
  }
30
- interface ClassifiedMentions {
30
+ export interface ClassifiedMentions {
31
31
  broadcastIds: string[];
32
32
  regularUserIds: string[];
33
33
  roleIds: string[];
34
34
  }
35
- declare enum MentionType {
35
+ export declare enum MentionType {
36
36
  Role = "role",
37
37
  User = "user"
38
38
  }
39
- declare const RoutePath: {
39
+ export declare const RoutePath: {
40
40
  readonly About: "/about";
41
41
  readonly Achievements: "/achievements";
42
42
  readonly Anime: "/anime";
@@ -60,60 +60,63 @@ declare const RoutePath: {
60
60
  readonly PostUpdate: (id: string) => string;
61
61
  readonly PrivacyPolicy: "/privacy-policy";
62
62
  readonly Resource: (id: string) => string;
63
+ readonly ResourceExplorer: "/resource-explorer";
64
+ readonly ResourceExplorerAll: "/resource-explorer/all";
65
+ readonly ResourceExplorerCreate: "/resource-explorer/create";
66
+ readonly ResourceExplorerCreateType: (type: string) => string;
67
+ readonly ResourceExplorerFavorites: "/resource-explorer/favorites";
68
+ readonly ResourceExplorerRecents: "/resource-explorer/recents";
69
+ readonly ResourceExplorerRecycleBin: "/resource-explorer/recycle-bin";
70
+ readonly ResourceExplorerTags: "/resource-explorer/tags";
63
71
  readonly ResourceItems: (id: string) => string;
64
- readonly Resources: "/resources";
65
- readonly ResourcesAll: "/resources/all";
66
- readonly ResourcesCreate: "/resources/create";
67
- readonly ResourcesCreateType: (type: string) => string;
68
- readonly ResourcesRecycleBin: "/resources/recycle-bin";
69
72
  readonly User: (id: string) => string;
70
73
  readonly UserSettings: "/user/settings";
71
74
  readonly View: (type: string, id: string) => string;
72
75
  };
73
- type RoutePath = typeof RoutePath;
74
- type GetArrayProps<T extends unknown[], P extends string, D extends unknown[], R extends boolean> = (D extends [unknown, ...infer Rest] ? GetProperties<T[number], R extends true ? `${P}[number]` : `${P}.[number]`, Rest, false> : never) | {
76
+ export type RoutePath = typeof RoutePath;
77
+ export type GetArrayProps<T extends unknown[], P extends string, D extends unknown[], R extends boolean> = (D extends [unknown, ...infer Rest] ? GetProperties<T[number], R extends true ? `${P}[number]` : `${P}.[number]`, Rest, false> : never) | {
75
78
  path: R extends true ? "length" : `${P}.length`;
76
79
  value: T["length"];
77
80
  };
78
- type KnownKeys<T> = { [K in keyof T as string extends K ? never : number extends K ? never : K]: T[K]; };
79
- type GetObjectProps<T, P extends string, D extends unknown[], R extends boolean> = { [K in keyof KnownKeys<T> & (number | string)]: K extends `${number}` ? never : NonNullable<T[K]> extends Function ? never : (D extends [unknown, ...infer Rest] ? GetProperties<T[K], R extends true ? `${K}` : `${P}.${K}`, Rest, false> : never) | {
81
+ export type KnownKeys<T> = { [K in keyof T as string extends K ? never : number extends K ? never : K]: T[K]; };
82
+ export type GetObjectProps<T, P extends string, D extends unknown[], R extends boolean> = { [K in keyof KnownKeys<T> & (number | string)]: K extends `${number}` ? never : NonNullable<T[K]> extends Function ? never : (D extends [unknown, ...infer Rest] ? GetProperties<T[K], R extends true ? `${K}` : `${P}.${K}`, Rest, false> : never) | {
80
83
  path: R extends true ? `${K}` : `${P}.${K}`;
81
84
  value: T[K];
82
85
  }; }[keyof KnownKeys<T> & (number | string)];
83
- type GetPrimitiveProps<T, P extends string, D extends unknown[], R extends boolean> = T extends string ? {
86
+ export type GetPrimitiveProps<T, P extends string, D extends unknown[], R extends boolean> = T extends string ? {
84
87
  path: R extends true ? "length" : `${P}.length`;
85
88
  value: number;
86
89
  } : T extends symbol ? (D extends [unknown, ...infer Rest] ? GetProperties<string | undefined, R extends true ? "description" : `${P}.description`, Rest, false> : never) | {
87
90
  path: R extends true ? "description" : `${P}.description`;
88
91
  value: string | undefined;
89
92
  } : never;
90
- type GetProperties<T, P extends string = "", D extends unknown[] = [unknown, unknown, unknown, unknown, unknown], R extends boolean = true> = [T] extends [never] ? never : D extends [] ? never : NonNullable<T> extends (infer O) ? O extends unknown[] ? GetArrayProps<O, P, D, R> : O extends object ? GetObjectProps<O, P, D, R> : GetPrimitiveProps<O, P, D, R> : never;
91
- type GetPaths<T> = GetProperties<T> extends (infer U) ? (U extends {
93
+ export type GetProperties<T, P extends string = "", D extends unknown[] = [unknown, unknown, unknown, unknown, unknown], R extends boolean = true> = [T] extends [never] ? never : D extends [] ? never : NonNullable<T> extends (infer O) ? O extends unknown[] ? GetArrayProps<O, P, D, R> : O extends object ? GetObjectProps<O, P, D, R> : GetPrimitiveProps<O, P, D, R> : never;
94
+ export type GetPaths<T> = GetProperties<T> extends (infer U) ? (U extends {
92
95
  path: infer Path;
93
96
  } ? Path : never) : never;
94
- type PropertyNames<T> = { [P in GetPaths<T>]: P; };
95
- interface ItemEntityType<T extends string> {
97
+ export type PropertyNames<T> = { [P in GetPaths<T>]: P; };
98
+ export interface ItemEntityType<T extends string> {
96
99
  type: T;
97
100
  }
98
- declare const ItemEntityTypePropertyNames: PropertyNames<ItemEntityType<string>>;
99
- declare const createItemEntityTypeSchema: <T extends z.ZodType<string>>(schema: T) => z.ZodObject<{
101
+ export declare const ItemEntityTypePropertyNames: PropertyNames<ItemEntityType<string>>;
102
+ export declare const createItemEntityTypeSchema: <T extends z.ZodType<string>>(schema: T) => z.ZodObject<{
100
103
  type: T;
101
104
  }>;
102
- declare class ItemMetadata {
105
+ export declare class ItemMetadata {
103
106
  createdAt: Date;
104
107
  deletedAt: Date | null;
105
108
  updatedAt: Date;
106
109
  }
107
- declare const ItemMetadataPropertyNames: PropertyNames<ItemMetadata>;
108
- declare const itemMetadataSchema: z.ZodObject<{
110
+ export declare const ItemMetadataPropertyNames: PropertyNames<ItemMetadata>;
111
+ export declare const itemMetadataSchema: z.ZodObject<{
109
112
  createdAt: z.ZodDate;
110
113
  deletedAt: z.ZodNullable<z.ZodDate>;
111
114
  updatedAt: z.ZodDate;
112
115
  }>;
113
- declare abstract class Serializable {
116
+ export declare abstract class Serializable {
114
117
  toJSON(): this;
115
118
  }
116
- interface TakeOne {
119
+ export interface TakeOne {
117
120
  <T extends readonly unknown[]>(values: T, index?: number): T[number];
118
121
  <T extends object | Record<PropertyKey, unknown>>(values: T, index: keyof T): T[keyof T];
119
122
  }
@@ -1868,16 +1871,19 @@ const rawCliOptions: KebabCasedProperties<CliOptions> = {
1868
1871
  @category Template literal
1869
1872
  */
1870
1873
  type KebabCase<Value, Options extends WordsOptions = {}> = DelimiterCase<Value, '-', ApplyDefaultOptions<WordsOptions, _DefaultDelimiterCaseOptions, Options>>;
1871
- type DeepOmit<T, TKey extends PropertyKey> = [T] extends [Date | Function | Primitive] ? T : [Record<string, unknown>] extends [T] ? T : T extends object ? T extends unknown[] ? T extends readonly unknown[] ? { [K in keyof T]: DeepOmit<T[K], TKey>; } : DeepOmit<T[number], TKey>[] : { [P in keyof T as P extends TKey ? never : P]: DeepOmit<T[P], TKey>; } : T;
1872
- type DeepOptionalUndefined<T> = T extends Date | Function | Primitive ? T : T extends unknown[] ? { [K in keyof T]: DeepOptionalUndefined<T[K]>; } : T extends object ? { [K in keyof T as undefined extends T[K] ? K : never]?: DeepOptionalUndefined<T[K]>; } & { [K in keyof T as undefined extends T[K] ? never : K]: DeepOptionalUndefined<T[K]>; } extends (infer O) ? { [K in keyof O]: O[K]; } : never : T;
1873
- type ToData<T> = DeepOptionalUndefined<DeepOmit<T, "toJSON">>;
1874
- interface WithMetadata<TBase extends Class<NonNullable<unknown>>> {
1874
+ export type DeepOmit<T, TKey extends PropertyKey> = [T] extends [Date | Function | Primitive] ? T : [Record<string, unknown>] extends [T] ? T : T extends object ? T extends unknown[] ? T extends readonly unknown[] ? { [K in keyof T]: DeepOmit<T[K], TKey>; } : DeepOmit<T[number], TKey>[] : { [P in keyof T as P extends TKey ? never : P]: DeepOmit<T[P], TKey>; } : T;
1875
+ export type DeepOptionalUndefined<T> = T extends Date | Function | Primitive ? T : T extends unknown[] ? { [K in keyof T]: DeepOptionalUndefined<T[K]>; } : T extends object ? { [K in keyof T as undefined extends T[K] ? K : never]?: DeepOptionalUndefined<T[K]>; } & { [K in keyof T as undefined extends T[K] ? never : K]: DeepOptionalUndefined<T[K]>; } extends (infer O) ? { [K in keyof O]: O[K]; } : never : T;
1876
+ export type ToData<T> = DeepOptionalUndefined<DeepOmit<T, "toJSON">>;
1877
+ export interface WithMetadata<TBase extends Class<NonNullable<unknown>>> {
1875
1878
  new (...args: ConstructorParameters<TBase>): InstanceType<TBase> & ItemMetadata;
1876
1879
  prototype: InstanceType<TBase> & ItemMetadata;
1877
1880
  }
1878
- declare const MAX_READ_LIMIT = 1000;
1879
- declare const SITE_NAME = "Esposter";
1880
- declare const createExponentialBackoff: (baseDelayMs: number, maxDelayMs: number) => (<T>(operation: () => Promise<T>) => Promise<T>);
1881
+ export declare const MAX_READ_LIMIT = 1e3;
1882
+ export declare const SITE_NAME = "Esposter";
1883
+ export declare const KIBIBYTE: number;
1884
+ export declare const MEGABYTE: number;
1885
+ export declare const GIBIBYTE: number;
1886
+ export declare const createExponentialBackoff: (baseDelayMs: number, maxDelayMs: number) => (<T>(operation: () => Promise<T>) => Promise<T>);
1881
1887
  interface ErrorConfig {
1882
1888
  withStackTrace: boolean;
1883
1889
  }
@@ -2173,19 +2179,19 @@ declare type Traverse<T, Depth extends number = 5> = Combine<T, Depth> extends [
2173
2179
  declare type TraverseWithAllErrors<T, Depth extends number = 5> = Traverse<T, Depth> extends Result<infer Oks, infer Errs> ? Result<Oks, Errs[]> : never;
2174
2180
  declare type CombineResults<T extends readonly Result<unknown, unknown>[]> = IsLiteralArray<T> extends 1 ? Traverse<T> : Result<ExtractOkTypes<T>, ExtractErrTypes<T>[number]>;
2175
2181
  declare type CombineResultsWithAllErrorsArray<T extends readonly Result<unknown, unknown>[]> = IsLiteralArray<T> extends 1 ? TraverseWithAllErrors<T> : Result<ExtractOkTypes<T>, ExtractErrTypes<T>[number][]>;
2176
- declare const getResult: <T>(fn: () => T) => Result<T, Error>;
2177
- declare const getResultAsync: <T>(fn: () => Promise<T>) => ResultAsync<T, Error>;
2178
- declare const toAppError: (error: unknown) => Error;
2179
- declare const withFinalizer: <T>(fn: () => T, finalizer?: () => void) => T;
2180
- declare const withFinalizerAsync: <T>(fn: () => Promisable<T>, finalizer?: () => Promisable<void>) => Promise<T>;
2181
- declare const classifyMentions: (message: string) => ClassifiedMentions;
2182
- declare const MENTION_ID_ATTRIBUTE = "data-id";
2183
- declare const MENTION_ITEM_TYPE_ATTRIBUTE = "data-mention-type";
2184
- declare const MENTION_LABEL_ATTRIBUTE = "data-label";
2185
- declare const MENTION_TYPE_ATTRIBUTE = "data-type";
2186
- declare const MENTION_TYPE = "mention";
2187
- declare const MENTION_HERE_ID = "@here";
2188
- declare const MENTION_EVERYONE_ID = "@everyone";
2182
+ export declare const getResult: <T>(fn: () => T) => Result<T, Error>;
2183
+ export declare const getResultAsync: <T>(fn: () => Promise<T>) => ResultAsync<T, Error>;
2184
+ export declare const toAppError: (error: unknown) => Error;
2185
+ export declare const withFinalizer: <T>(fn: () => T, finalizer?: () => void) => T;
2186
+ export declare const withFinalizerAsync: <T>(fn: () => Promisable<T>, finalizer?: () => Promisable<void>) => Promise<T>;
2187
+ export declare const classifyMentions: (message: string) => ClassifiedMentions;
2188
+ export declare const MENTION_ID_ATTRIBUTE = "data-id";
2189
+ export declare const MENTION_ITEM_TYPE_ATTRIBUTE = "data-mention-type";
2190
+ export declare const MENTION_LABEL_ATTRIBUTE = "data-label";
2191
+ export declare const MENTION_TYPE_ATTRIBUTE = "data-type";
2192
+ export declare const MENTION_TYPE = "mention";
2193
+ export declare const MENTION_HERE_ID = "@here";
2194
+ export declare const MENTION_EVERYONE_ID = "@everyone";
2189
2195
  declare class VoidTag {
2190
2196
  addClosingSlash: boolean;
2191
2197
  private voidTags;
@@ -2477,51 +2483,51 @@ interface Options {
2477
2483
  };
2478
2484
  closeAllByClosing?: boolean;
2479
2485
  }
2480
- declare const getMentions: (message: string) => HTMLElement[];
2481
- declare const css: typeof String.raw;
2482
- declare const html: typeof String.raw;
2483
- declare const sanitizeHtml: (...[html, options]: Parameters<typeof baseSanitizeHtml>) => string;
2484
- declare const sanitizeTextHtml: (html: string) => string;
2485
- declare const applyItemMetadataMixin: <TBase extends Class<NonNullable<unknown>>>(Base: TBase) => WithMetadata<TBase>;
2486
- declare const chunk: <T>(array: T[], size: number) => T[][];
2487
- declare const chunkBySerializedSize: <T>(items: T[], maxBytes: number, maxCount: number) => T[][];
2488
- declare const takeOne: TakeOne;
2489
- declare const getIsServer: () => boolean;
2490
- declare const noop: () => void;
2491
- declare const ID_SEPARATOR = "|";
2492
- declare const UUID_LENGTH = 36;
2493
- declare const getOrCreate: <TKey, TValue>(map: Map<TKey, TValue>, key: TKey, create: () => TValue) => TValue;
2494
- declare const checkIsPlainObject: (data: unknown) => data is object;
2495
- declare const getPropertyNames: <T>() => PropertyNames<T>;
2496
- declare const jsonDateParse: <T = any>(text: string) => T;
2497
- type MergeObjectsStrict<T extends object[]> = T extends [infer TFirst, infer TSecond, ...infer TRemaining] ? TSecond extends { [K in keyof TSecond]: K extends keyof TFirst ? never : TSecond[K]; } ? TRemaining extends object[] ? MergeObjectsStrict<[TSecond, ...TRemaining]> & TFirst : TFirst & TSecond : never : T extends [infer TFirst] ? TFirst : never;
2498
- declare const mergeObjectsStrict: <T extends object[]>(...objects: T) => MergeObjectsStrict<T>;
2499
- declare const settleAll: <T>(tasks: (() => Promise<T>)[], concurrencyLimit?: number) => Promise<T[]>;
2500
- declare const getRawData: <T>(data: T) => T;
2501
- declare const toRawDeep: <T extends object>(data: T) => T;
2502
- declare const capitalize: (string: string) => string;
2503
- declare const encodeUrlSubDelimiters: (value: string) => string;
2504
- declare const normalizeString: (value: null | string | undefined) => string;
2505
- declare const createNormalizedStringSchema: (maxLength: number, schema?: z.ZodString) => z.ZodPipe<z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>, z.ZodString>;
2506
- declare const streamToText: (readable: NodeJS.ReadableStream) => Promise<string>;
2507
- declare const toKebabCase: <T extends string>(string: T) => KebabCase<T>;
2508
- declare const truncate: (string: string, length: number) => string;
2509
- declare const uncapitalize: <T extends string>(string: T) => Uncapitalize<T>;
2510
- declare const hrtime: (previousHrTime?: [number, number]) => [number, number];
2511
- declare const now: () => string;
2512
- declare const sleep: (durationMs: number) => Promise<void>;
2513
- type BuildTuple<N extends number, T = unknown, R extends unknown[] = []> = R["length"] extends N ? R : BuildTuple<N, T, [...R, T]>;
2514
- type FunctionProperties<T> = { [K in keyof T]: T[K] extends Function ? K : never; };
2515
- type ExcludeFunctionProperties<T> = Except<T, FunctionProperties<T>[keyof T]>;
2516
- type MapValue<BaseType> = BaseType extends Map<unknown, infer ValueType> ? ValueType : never;
2517
- type TupleSplit<T extends unknown[], N extends number> = T extends [...BuildTuple<N>, ...infer R] ? [T extends [...infer H, ...R] ? H : BuildTuple<N, T[number]>, R] : [T, []];
2518
- type SkipFirst<T extends unknown[], N extends number> = TupleSplit<T, N>[1];
2519
- type TakeFirst<T extends unknown[], N extends number> = TupleSplit<T, N>[0];
2520
- type TupleSlice<T extends unknown[], S extends number, E extends number = T["length"]> = E extends T["length"] ? SkipFirst<T, S> : SkipFirst<TakeFirst<T, E>, S>;
2521
- declare const exhaustiveGuard: (value: never) => never;
2522
- type CreateUniqueArraySchema = (<TOutput extends object, TInput, TSchema extends z.ZodType<TOutput, TInput>>(schema: TSchema, key: UniqueArraySchemaKey<TSchema>) => z.ZodArray<TSchema>) & (<TSchema extends z.ZodType>(schema: TSchema) => z.ZodArray<TSchema>);
2523
- type UniqueArraySchemaKey<TSchema extends z.ZodType> = TSchema extends z.ZodObject ? keyof TSchema["shape"] & string : keyof z.output<TSchema> & string;
2524
- declare const createUniqueArraySchema: CreateUniqueArraySchema;
2525
- declare const UUIDV4_REGEX: RegExp;
2526
- declare const uuidValidateV4: (uuid: string) => boolean;
2527
- export { AllSpecialValues, BuildTuple, ClassifiedMentions, CreateUniqueArraySchema, DeepOmit, DeepOptionalUndefined, ExcludeFunctionProperties, ForbiddenError, FunctionProperties, GetArrayProps, GetObjectProps, GetPaths, GetPrimitiveProps, GetProperties, ID_SEPARATOR, InvalidOperationError, ItemEntityType, ItemEntityTypePropertyNames, ItemMetadata, ItemMetadataPropertyNames, KnownKeys, MAX_READ_LIMIT, MENTION_EVERYONE_ID, MENTION_HERE_ID, MENTION_ID_ATTRIBUTE, MENTION_ITEM_TYPE_ATTRIBUTE, MENTION_LABEL_ATTRIBUTE, MENTION_TYPE, MENTION_TYPE_ATTRIBUTE, MapValue, MentionType, MergeObjectsStrict, NotFoundError, NotInitializedError, Operation, PropertyNames, RoutePath, SITE_NAME, Serializable, SkipFirst, TakeFirst, TakeOne, ToData, TupleSlice, TupleSplit, UUIDV4_REGEX, UUID_LENGTH, UniqueArraySchemaKey, WithMetadata, WordFilteredError, applyItemMetadataMixin, capitalize, checkIsPlainObject, chunk, chunkBySerializedSize, classifyMentions, createExponentialBackoff, createItemEntityTypeSchema, createNormalizedStringSchema, createUniqueArraySchema, css, encodeUrlSubDelimiters, exhaustiveGuard, getIsServer, getMentions, getOrCreate, getPropertyNames, getRawData, getResult, getResultAsync, hrtime, html, itemMetadataSchema, jsonDateParse, mergeObjectsStrict, noop, normalizeString, now, sanitizeHtml, sanitizeTextHtml, settleAll, sleep, streamToText, takeOne, toAppError, toKebabCase, toRawDeep, truncate, uncapitalize, uuidValidateV4, withFinalizer, withFinalizerAsync };
2486
+ export declare const getMentions: (message: string) => HTMLElement[];
2487
+ export declare const css: typeof String.raw;
2488
+ export declare const html: typeof String.raw;
2489
+ export declare const sanitizeHtml: (...[html, options]: Parameters<typeof baseSanitizeHtml>) => string;
2490
+ export declare const sanitizeTextHtml: (html: string) => string;
2491
+ export declare const applyItemMetadataMixin: <TBase extends Class<NonNullable<unknown>>>(Base: TBase) => WithMetadata<TBase>;
2492
+ export declare const chunk: <T>(array: T[], size: number) => T[][];
2493
+ export declare const chunkBySerializedSize: <T>(items: T[], maxBytes: number, maxCount: number) => T[][];
2494
+ export declare const takeOne: TakeOne;
2495
+ export declare const getIsServer: () => boolean;
2496
+ export declare const noop: () => void;
2497
+ export declare const ID_SEPARATOR = "|";
2498
+ export declare const UUID_LENGTH = 36;
2499
+ export declare const getOrCreate: <TKey, TValue>(map: Map<TKey, TValue>, key: TKey, create: () => TValue) => TValue;
2500
+ export declare const checkIsPlainObject: (data: unknown) => data is object;
2501
+ export declare const getPropertyNames: <T>() => PropertyNames<T>;
2502
+ export declare const jsonDateParse: <T = any>(text: string) => T;
2503
+ export type MergeObjectsStrict<T extends object[]> = T extends [infer TFirst, infer TSecond, ...infer TRemaining] ? TSecond extends { [K in keyof TSecond]: K extends keyof TFirst ? never : TSecond[K]; } ? TRemaining extends object[] ? MergeObjectsStrict<[TSecond, ...TRemaining]> & TFirst : TFirst & TSecond : never : T extends [infer TFirst] ? TFirst : never;
2504
+ export declare const mergeObjectsStrict: <T extends object[]>(...objects: T) => MergeObjectsStrict<T>;
2505
+ export declare const settleAll: <T>(tasks: (() => Promise<T>)[], concurrencyLimit?: number) => Promise<T[]>;
2506
+ export declare const getRawData: <T>(data: T) => T;
2507
+ export declare const toRawDeep: <T extends object>(data: T) => T;
2508
+ export declare const capitalize: (string: string) => string;
2509
+ export declare const encodeUrlSubDelimiters: (value: string) => string;
2510
+ export declare const getDecodedUriComponent: (value: string, fallback: string) => string;
2511
+ export declare const normalizeString: (value: null | string | undefined) => string;
2512
+ export declare const createNormalizedStringSchema: (maxLength: number, schema?: z.ZodString) => z.ZodPipe<z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>, z.ZodString>;
2513
+ export declare const streamToText: (readable: NodeJS.ReadableStream) => Promise<string>;
2514
+ export declare const toKebabCase: <T extends string>(string: T) => KebabCase<T>;
2515
+ export declare const truncate: (string: string, length: number) => string;
2516
+ export declare const uncapitalize: <T extends string>(string: T) => Uncapitalize<T>;
2517
+ export declare const hrtime: (previousHrTime?: [number, number]) => [number, number];
2518
+ export declare const now: () => string;
2519
+ export declare const sleep: (durationMs: number) => Promise<void>;
2520
+ export type BuildTuple<N extends number, T = unknown, R extends unknown[] = []> = R["length"] extends N ? R : BuildTuple<N, T, [...R, T]>;
2521
+ export type FunctionProperties<T> = { [K in keyof T]: T[K] extends Function ? K : never; };
2522
+ export type ExcludeFunctionProperties<T> = Except<T, FunctionProperties<T>[keyof T]>;
2523
+ export type MapValue<BaseType> = BaseType extends Map<unknown, infer ValueType> ? ValueType : never;
2524
+ export type TupleSplit<T extends unknown[], N extends number> = T extends [...BuildTuple<N>, ...infer R] ? [T extends [...infer H, ...R] ? H : BuildTuple<N, T[number]>, R] : [T, []];
2525
+ export type SkipFirst<T extends unknown[], N extends number> = TupleSplit<T, N>[1];
2526
+ export type TakeFirst<T extends unknown[], N extends number> = TupleSplit<T, N>[0];
2527
+ export type TupleSlice<T extends unknown[], S extends number, E extends number = T["length"]> = E extends T["length"] ? SkipFirst<T, S> : SkipFirst<TakeFirst<T, E>, S>;
2528
+ export declare const exhaustiveGuard: (value: never) => never;
2529
+ export type CreateUniqueArraySchema = (<TOutput extends object, TInput, TSchema extends z.ZodType<TOutput, TInput>>(schema: TSchema, key: UniqueArraySchemaKey<TSchema>) => z.ZodArray<TSchema>) & (<TSchema extends z.ZodType>(schema: TSchema) => z.ZodArray<TSchema>);
2530
+ export type UniqueArraySchemaKey<TSchema extends z.ZodType> = TSchema extends z.ZodObject ? keyof TSchema["shape"] & string : keyof z.output<TSchema> & string;
2531
+ export declare const createUniqueArraySchema: CreateUniqueArraySchema;
2532
+ export declare const UUIDV4_REGEX: RegExp;
2533
+ export declare const uuidValidateV4: (uuid: string) => boolean;