UNPKG

@hf-chimera/store

Version:

Cross-end reactivity API

821 lines 44.8 kB
//#region src/shared/types.d.ts type KeysOfType<Obj, Type> = { [K in keyof Obj]: Obj[K] extends Type ? K : never }[keyof Obj]; type StrKeys<T> = keyof T & string & {}; type DeepPartial<T> = T extends object ? { [P in keyof T]?: DeepPartial<T[P]> } : T; type ChimeraEntityId = string | number; type ChimeraEntityMap = Record<string, object>; type ChimeraEntityGetter<Entity, Return = unknown> = (entity: Entity) => Return; type ChimeraPropertyGetter<Entity, Type = unknown, Return = unknown> = { get: ChimeraEntityGetter<Entity, Return> | KeysOfType<Entity, Type>; key: string; }; type ChimeraIdGetterFunc<Entity> = ChimeraEntityGetter<Entity, ChimeraEntityId>; type ChimeraMutationRequester<Entity> = (entity: Entity, cb: (item: Entity) => void) => void; //#endregion //#region src/filter/constants.d.ts declare const ChimeraOperatorSymbol: unique symbol; declare const ChimeraConjunctionSymbol: unique symbol; //#endregion //#region src/filter/types.d.ts type ChimeraFilterChecker<Entity> = (item: Entity) => boolean; type ChimeraConjunctionType = "and" | "or" | "not"; type ChimeraOperatorFunction = (itemValue: any, testValue: any) => boolean; type ChimeraOperatorMap = Record<string, ChimeraOperatorFunction>; type ChimeraFilterOperatorDescriptor<OperatorsMap extends ChimeraOperatorMap, Entity, Op extends keyof OperatorsMap & string = keyof OperatorsMap & string> = { [K in Op]: { type: typeof ChimeraOperatorSymbol; op: K; value: ChimeraPropertyGetter<Entity, Parameters<OperatorsMap[K]>[0]>; test: Parameters<OperatorsMap[K]>[1]; } }[Op]; type ChimeraConjunctionOperationDescriptor<OperatorsMap extends ChimeraOperatorMap, Entity> = ChimeraFilterOperatorDescriptor<OperatorsMap, Entity> | ChimeraConjunctionDescriptor<OperatorsMap, Entity>; type ChimeraConjunctionDescriptor<OperatorsMap extends ChimeraOperatorMap, Entity, Conj extends ChimeraConjunctionType = ChimeraConjunctionType> = { [K in Conj]: { type: typeof ChimeraConjunctionSymbol; kind: K; operations: ChimeraConjunctionOperationDescriptor<OperatorsMap, Entity>[]; } }[Conj]; type ChimeraFilterDescriptor<OperatorsMap extends ChimeraOperatorMap, Entity> = ChimeraConjunctionDescriptor<OperatorsMap, Entity>; type ChimeraSimplifiedOperator<OperatorsMap extends ChimeraOperatorMap, Keys extends string = string, Op extends keyof OperatorsMap & string = keyof OperatorsMap & string> = { [K in Op]: { type: typeof ChimeraOperatorSymbol; op: K; key: Keys | string; test: Parameters<OperatorsMap[K]>[1]; } }[Op]; type ChimeraSimplifiedConjunctionOperation<OperatorsMap extends ChimeraOperatorMap, Keys extends string = string> = ChimeraSimplifiedOperator<OperatorsMap, Keys> | SimplifiedConjunction<OperatorsMap, Keys>; type SimplifiedConjunction<OperatorsMap extends ChimeraOperatorMap, Keys extends string = string, Conj extends ChimeraConjunctionType = ChimeraConjunctionType> = { [K in Conj]: { type: typeof ChimeraConjunctionSymbol; kind: K; operations: ChimeraSimplifiedConjunctionOperation<OperatorsMap, Keys>[]; } }[Conj]; type ChimeraSimplifiedFilter<OperatorsMap extends ChimeraOperatorMap, Keys extends string = string> = SimplifiedConjunction<OperatorsMap, Keys> | null; type ChimeraKeyFromFilterGetter = <OperatorsMap extends ChimeraOperatorMap>(filter: ChimeraSimplifiedFilter<OperatorsMap> | null) => string; type ChimeraKeyFromOperatorGetter = <OperatorsMap extends ChimeraOperatorMap>(operator: ChimeraSimplifiedOperator<OperatorsMap> | null) => string; type ChimeraFilterConfig<OperatorsMap extends ChimeraOperatorMap> = { operators: OperatorsMap; getFilterKey?: ChimeraKeyFromFilterGetter; getOperatorKey?: ChimeraKeyFromOperatorGetter; }; //#endregion //#region src/order/types.d.ts declare enum ChimeraOrderNulls { First = "first", Last = "last", } type ChimeraOrderDescriptor<Entity> = { key: ChimeraPropertyGetter<Entity>; desc: boolean; nulls: ChimeraOrderNulls; }; type ChimeraOrderPriority<Entity> = ChimeraOrderDescriptor<Entity>[]; type ChimeraOrderByComparator<Entity> = (a: Entity, b: Entity) => number; type ChimeraPrimitiveComparator = (a: unknown, b: unknown) => number; type ChimeraSimplifiedOrderDescriptor<Keys extends string = string> = { field: Keys | string; desc: boolean; nulls: ChimeraOrderNulls; }; type ChimeraKeyFromOrderGetter = (order: ChimeraSimplifiedOrderDescriptor[] | null) => string; type ChimeraOrderConfig = { primitiveComparator?: ChimeraPrimitiveComparator; getKey?: ChimeraKeyFromOrderGetter; }; //#endregion //#region src/shared/ChimeraEventEmitter/ChimeraEventEmitter.d.ts type ValidEventTypes = string | object; type EventNames<T extends ValidEventTypes> = T extends string ? T : keyof T; type ArgumentMap<T extends object> = { [K in keyof T]: T[K] extends ((...args: any[]) => void) ? Parameters<T[K]>[0] : T[K] extends any[] ? T[K][0] : T[K] }; type EventListener<T extends ValidEventTypes, K$1 extends EventNames<T>> = T extends string ? (arg: any) => void : (arg: ArgumentMap<Exclude<T, string | symbol>>[Extract<K$1, keyof T>]) => void; type EventArgs<T extends ValidEventTypes, K$1 extends EventNames<T>> = Parameters<EventListener<T, K$1>>[0]; type EventRecord<T extends ValidEventTypes, K$1 extends EventNames<T>> = { fn: EventListener<T, K$1>; once: boolean; }; type EventRecordMap<T extends ValidEventTypes> = { [K in EventNames<T>]?: EventRecord<T, K> | EventRecord<T, K>[] }; declare class ChimeraEventEmitter<EventTypes extends ValidEventTypes = string> { #private; _events: EventRecordMap<EventTypes>; _eventsCount: number; constructor(); eventNames(): EventNames<EventTypes>[]; listeners<T extends EventNames<EventTypes>>(event: T): EventListener<EventTypes, T>[]; listenerCount(event: EventNames<EventTypes>): number; removeListener<T extends EventNames<EventTypes>>(event: T, fn?: EventListener<EventTypes, T>, once?: boolean): this; emit<T extends EventNames<EventTypes>>(event: T, arg?: EventArgs<EventTypes, T>): boolean; on<T extends EventNames<EventTypes>>(event: T, fn: EventListener<EventTypes, T>): this; once<T extends EventNames<EventTypes>>(event: T, fn: EventListener<EventTypes, T>): this; removeAllListeners(event?: EventNames<EventTypes>): this; off: <T extends EventNames<EventTypes>>(event: T, fn?: EventListener<EventTypes, T>, once?: boolean) => this; addListener: <T extends EventNames<EventTypes>>(event: T, fn: EventListener<EventTypes, T>) => this; } //#endregion //#region src/query/types.d.ts declare enum ChimeraQueryFetchingState { /** Query just initialized. */ Initialized = "initialized", /** Not used yet. */ Scheduled = "scheduled", /** Fetching in progress. */ Fetching = "fetching", /** Creating in progress */ Creating = "creating", /** Updating in progress. */ Updating = "updating", /** Deleting in progress. */ Deleting = "deleting", /** Fetch requested after reaching the Fetched, Errored, or Prefetched states. */ Refetching = "refetching", /** Data retrieved from existing queries without initiating a fetch. */ Prefetched = "prefetched", /** Fetch ended successfully; data is ready for use. */ Fetched = "fetched", /** Fetch ended with an error; no data is available. */ Errored = "errored", /** Refetch ended with an error, but old data is still available. */ ReErrored = "reErrored", /** * Only for the item query, data is deleted, but the local value is still present, * no longer allows updates, but `refetch` still works (in case of strange errors, allows recovering state) */ Deleted = "deleted", /** Only for the item query, data was actualized from an external event */ Actualized = "actualized", } interface ChimeraQueryFetchingStatable { get state(): ChimeraQueryFetchingState; get inProgress(): boolean; get ready(): boolean; } /** * Id getter types */ type ChimeraQueryEntityIdGetter<Entity> = keyof Entity | ChimeraIdGetterFunc<Entity>; type ChimeraQueryDefaultEntityIdGetterFunction<EntityMap extends ChimeraEntityMap> = <EntityName extends StrKeys<EntityMap>>(name: EntityName, newEntity: EntityMap[EntityName]) => ChimeraEntityId; type ChimeraQueryDefaultEntityIdGetter<EntityMap extends ChimeraEntityMap> = keyof EntityMap[keyof EntityMap] | ChimeraQueryDefaultEntityIdGetterFunction<EntityMap>; /** * Response types */ type ChimeraQueryCollectionFetcherResponse<Entity, Meta = any> = { data: Entity[]; meta?: Meta; }; type ChimeraQueryItemFetcherResponse<Entity, Meta = any> = { data: Entity; meta?: Meta; }; type ChimeraQueryDeletionResult<Success extends boolean = boolean> = { id: ChimeraEntityId; success: Success; }; type ChimeraQueryItemDeleteResponse<Meta = any> = { result: ChimeraQueryDeletionResult; meta?: Meta; }; type ChimeraQueryBatchedDeleteResponse<Meta = any> = { result: ChimeraQueryDeletionResult[]; meta?: Meta; }; /** * Fetcher types */ type ChimeraQueryEntityFetcherRequestParams = { signal: AbortSignal; }; type ChimeraQueryEntityCollectionFetcherParams<Entity, OperatorsMap extends ChimeraOperatorMap, Meta = any> = { order: ChimeraSimplifiedOrderDescriptor<keyof Entity & string>[] | null; filter: ChimeraSimplifiedFilter<OperatorsMap, keyof Entity & string> | null; meta: Meta; }; type ChimeraQueryEntityItemFetcherParams<Entity, Meta = any> = { id: ChimeraEntityId; meta: Meta; }; type ChimeraQueryEntityCollectionFetcher<Entity, OperatorsMap extends ChimeraOperatorMap, Meta = any> = (params: ChimeraQueryEntityCollectionFetcherParams<Entity, OperatorsMap, Meta>, requestParams: ChimeraQueryEntityFetcherRequestParams) => Promise<ChimeraQueryCollectionFetcherResponse<Entity>>; type ChimeraQueryEntityItemFetcher<Entity> = (params: ChimeraQueryEntityItemFetcherParams<Entity>, requestParams: ChimeraQueryEntityFetcherRequestParams) => Promise<ChimeraQueryItemFetcherResponse<Entity>>; type ChimeraQueryDefaultCollectionFetcher<EntityMap extends ChimeraEntityMap, OperatorsMap extends ChimeraOperatorMap> = <EntityName extends StrKeys<EntityMap>>(entityName: EntityName, params: ChimeraQueryEntityCollectionFetcherParams<EntityMap[EntityName], OperatorsMap>, requestParams: ChimeraQueryEntityFetcherRequestParams) => Promise<ChimeraQueryCollectionFetcherResponse<EntityMap[EntityName]>>; type ChimeraQueryDefaultItemFetcher<EntityMap extends ChimeraEntityMap> = <EntityName extends StrKeys<EntityMap>>(entityName: EntityName, params: ChimeraQueryEntityItemFetcherParams<EntityMap[EntityName]>, requestParams: ChimeraQueryEntityFetcherRequestParams) => Promise<ChimeraQueryItemFetcherResponse<EntityMap[EntityName]>>; /** * Updater types */ type ChimeraQueryEntityItemUpdater<Entity> = (updatedEntity: Entity, requestParams: ChimeraQueryEntityFetcherRequestParams) => Promise<ChimeraQueryItemFetcherResponse<Entity>>; type ChimeraQueryEntityBatchedUpdater<Entity> = (updatedEntities: Entity[], requestParams: ChimeraQueryEntityFetcherRequestParams) => Promise<ChimeraQueryCollectionFetcherResponse<Entity>>; type ChimeraQueryDefaultItemUpdater<EntityMap extends ChimeraEntityMap> = <EntityName extends StrKeys<EntityMap>>(entityName: EntityName, updatedEntity: EntityMap[EntityName], requestParams: ChimeraQueryEntityFetcherRequestParams) => Promise<ChimeraQueryItemFetcherResponse<EntityMap[EntityName]>>; type ChimeraQueryDefaultBatchedUpdater<EntityMap extends ChimeraEntityMap> = <EntityName extends StrKeys<EntityMap>>(entityName: EntityName, updatedEntities: EntityMap[EntityName][], requestParams: ChimeraQueryEntityFetcherRequestParams) => Promise<ChimeraQueryCollectionFetcherResponse<EntityMap[EntityName]>>; /** * Deleter types */ type ChimeraQueryEntityItemDeleter = (deleteId: ChimeraEntityId, requestParams: ChimeraQueryEntityFetcherRequestParams) => Promise<ChimeraQueryItemDeleteResponse>; type ChimeraQueryEntityBatchedDeleter = (deletedIds: ChimeraEntityId[], requestParams: ChimeraQueryEntityFetcherRequestParams) => Promise<ChimeraQueryBatchedDeleteResponse>; type ChimeraQueryDefaultItemDeleter<EntityMap extends ChimeraEntityMap> = <EntityName extends StrKeys<EntityMap>>(entityName: EntityName, deleteId: ChimeraEntityId, requestParams: ChimeraQueryEntityFetcherRequestParams) => Promise<ChimeraQueryItemDeleteResponse>; type ChimeraQueryDefaultBatchedDeleter<EntityMap extends ChimeraEntityMap> = <EntityName extends StrKeys<EntityMap>>(entityName: EntityName, deletedIds: ChimeraEntityId[], requestParams: ChimeraQueryEntityFetcherRequestParams) => Promise<ChimeraQueryBatchedDeleteResponse>; /** * Creator type */ type ChimeraQueryEntityItemCreator<Entity> = (item: DeepPartial<Entity>, requestParams: ChimeraQueryEntityFetcherRequestParams) => Promise<ChimeraQueryItemFetcherResponse<Entity>>; type ChimeraQueryEntityBatchedCreator<Entity> = (items: DeepPartial<Entity>[], requestParams: ChimeraQueryEntityFetcherRequestParams) => Promise<ChimeraQueryCollectionFetcherResponse<Entity>>; type ChimeraQueryDefaultItemCreator<EntityMap extends ChimeraEntityMap> = <EntityName extends StrKeys<EntityMap>>(entityName: EntityName, item: DeepPartial<EntityMap[EntityName]>, requestParams: ChimeraQueryEntityFetcherRequestParams) => Promise<ChimeraQueryItemFetcherResponse<EntityMap[EntityName]>>; type ChimeraQueryDefaultBatchedCreator<EntityMap extends ChimeraEntityMap> = <EntityName extends StrKeys<EntityMap>>(entityName: EntityName, items: DeepPartial<EntityMap[EntityName]>[], requestParams: ChimeraQueryEntityFetcherRequestParams) => Promise<ChimeraQueryCollectionFetcherResponse<EntityMap[EntityName]>>; /** * Config types */ type QueryEntityConfig<Entity extends object, OperatorsMap extends ChimeraOperatorMap> = { name: string; devMode: boolean; trustQuery: boolean; updateDebounceTimeout: number; idGetter: ChimeraIdGetterFunc<Entity>; collectionFetcher: ChimeraQueryEntityCollectionFetcher<Entity, OperatorsMap>; itemFetcher: ChimeraQueryEntityItemFetcher<Entity>; itemUpdater: ChimeraQueryEntityItemUpdater<Entity>; batchedUpdater: ChimeraQueryEntityBatchedUpdater<Entity>; itemDeleter: ChimeraQueryEntityItemDeleter; batchedDeleter: ChimeraQueryEntityBatchedDeleter; itemCreator: ChimeraQueryEntityItemCreator<Entity>; batchedCreator: ChimeraQueryEntityBatchedCreator<Entity>; }; type ChimeraQueryEntityConfig<Entity, OperatorsMap extends ChimeraOperatorMap, Meta = any> = { trustQuery?: boolean; updateDebounceTimeout?: number; idGetter?: ChimeraQueryEntityIdGetter<Entity>; collectionFetcher?: ChimeraQueryEntityCollectionFetcher<Entity, OperatorsMap, Meta>; itemFetcher?: ChimeraQueryEntityItemFetcher<Entity>; itemUpdater?: ChimeraQueryEntityItemUpdater<Entity>; batchedUpdater?: ChimeraQueryEntityBatchedUpdater<Entity>; itemDeleter?: ChimeraQueryEntityItemDeleter; batchedDeleter?: ChimeraQueryEntityBatchedDeleter; itemCreator?: ChimeraQueryEntityItemCreator<Entity>; batchedCreator?: ChimeraQueryEntityBatchedCreator<Entity>; }; type ChimeraQueryDefaultsConfig<EntityMap extends ChimeraEntityMap, OperatorsMap extends ChimeraOperatorMap> = { trustQuery?: boolean; updateDebounceTimeout?: number; idGetter?: ChimeraQueryDefaultEntityIdGetter<EntityMap>; collectionFetcher?: ChimeraQueryDefaultCollectionFetcher<EntityMap, OperatorsMap>; itemFetcher?: ChimeraQueryDefaultItemFetcher<EntityMap>; itemUpdater?: ChimeraQueryDefaultItemUpdater<EntityMap>; batchedUpdater?: ChimeraQueryDefaultBatchedUpdater<EntityMap>; itemDeleter?: ChimeraQueryDefaultItemDeleter<EntityMap>; batchedDeleter?: ChimeraQueryDefaultBatchedDeleter<EntityMap>; itemCreator?: ChimeraQueryDefaultItemCreator<EntityMap>; batchedCreator?: ChimeraQueryDefaultBatchedCreator<EntityMap>; }; type ChimeraEntityConfigMap<EntityMap extends ChimeraEntityMap, OperatorsMap extends ChimeraOperatorMap> = { [K in keyof EntityMap]: ChimeraQueryEntityConfig<EntityMap[K], OperatorsMap> }; type ChimeraQueryConfig<EntityMap extends ChimeraEntityMap, OperatorsMap extends ChimeraOperatorMap> = { defaults: ChimeraQueryDefaultsConfig<EntityMap, OperatorsMap>; entities: ChimeraEntityConfigMap<EntityMap, OperatorsMap>; }; //#endregion //#region src/query/constants.d.ts declare const ChimeraGetParamsSym: unique symbol; declare const ChimeraSetOneSym: unique symbol; declare const ChimeraSetManySym: unique symbol; declare const ChimeraDeleteOneSym: unique symbol; declare const ChimeraDeleteManySym: unique symbol; declare const ChimeraUpdateMixedSym: unique symbol; //#endregion //#region src/query/ChimeraCollectionQuery.d.ts type ChimeraCollectionQueryEventMap<Item extends object, OperatorsMap extends ChimeraOperatorMap> = { /** Once the query is initialized */ initialized: { instance: ChimeraCollectionQuery<Item, OperatorsMap>; }; /** Once the query data is ready (will be followed by 'update') */ ready: { instance: ChimeraCollectionQuery<Item, OperatorsMap>; }; /** Each time the query was updated */ updated: { instance: ChimeraCollectionQuery<Item, OperatorsMap>; items: Item[]; oldItems: Item[] | null; }; /** Each time the query was an initiator of update */ selfUpdated: { instance: ChimeraCollectionQuery<Item, OperatorsMap>; items: Item[]; oldItems: Item[] | null; }; /** Each time item created */ selfItemCreated: { instance: ChimeraCollectionQuery<Item, OperatorsMap>; item: Item; }; /** Each time item added */ itemAdded: { instance: ChimeraCollectionQuery<Item, OperatorsMap>; item: Item; }; /** Each time item updated */ itemUpdated: { instance: ChimeraCollectionQuery<Item, OperatorsMap>; oldItem: Item; newItem: Item; }; /** Each time the query was an initiator of an item update */ selfItemUpdated: { instance: ChimeraCollectionQuery<Item, OperatorsMap>; item: Item; }; /** Each time item deleted */ itemDeleted: { instance: ChimeraCollectionQuery<Item, OperatorsMap>; item: Item; }; /** Each time the query was an initiator of item deletion */ selfItemDeleted: { instance: ChimeraCollectionQuery<Item, OperatorsMap>; id: ChimeraEntityId; }; /** Each time the fetcher produces an error */ error: { instance: ChimeraCollectionQuery<Item, OperatorsMap>; error: unknown; }; }; declare class ChimeraCollectionQuery<Item extends object, OperatorsMap extends ChimeraOperatorMap> extends ChimeraEventEmitter<ChimeraCollectionQueryEventMap<Item, OperatorsMap>> implements ChimeraQueryFetchingStatable { #private; emit(): never; constructor(config: QueryEntityConfig<Item, OperatorsMap>, params: ChimeraQueryEntityCollectionFetcherParams<Item, any>, existingItems: Iterable<Item> | null, order: ChimeraOrderByComparator<Item>, filter: ChimeraFilterChecker<Item>, alreadyValid: boolean); get [ChimeraGetParamsSym](): ChimeraQueryEntityCollectionFetcherParams<Item, OperatorsMap>; [ChimeraSetOneSym](item: Item): void; [ChimeraDeleteOneSym](id: ChimeraEntityId): void; [ChimeraSetManySym](items: Iterable<Item>): void; [ChimeraDeleteManySym](ids: Iterable<ChimeraEntityId>): void; [ChimeraUpdateMixedSym](toAdd: Iterable<Item>, toDelete: Iterable<ChimeraEntityId>): void; get state(): ChimeraQueryFetchingState; get inProgress(): boolean; get ready(): boolean; get lastError(): unknown; /** * Wait for the current progress process to complete (both success or error) */ get progress(): Promise<void>; /** * Wait for the current progress process to complete, throw an error if it fails */ get result(): Promise<void>; /** Return an item if it is ready, throw error otherwise */ getById(id: ChimeraEntityId): Item | undefined; /** Return mutable ref to item by idx if it is ready, throw error otherwise */ mutableAt(idx: number): Item | undefined; /** Return mutable ref to item by [id] if it is ready, throw error otherwise */ mutableGetById(id: ChimeraEntityId): Item | undefined; /** * Trigger refetch, return existing refetch promise if already running * @param force If true cancels any running process and starts a new one * @throws {ChimeraQueryAlreadyRunningError} If deleting or updating already in progress */ refetch(force?: boolean): Promise<ChimeraQueryCollectionFetcherResponse<Item>>; /** * Update item using updated copy * @param newItem new item to update */ update(newItem: Item): Promise<ChimeraQueryItemFetcherResponse<Item>>; /** * Update item using updated copy * @param newItems array of items to update */ batchedUpdate(newItems: Iterable<Item>): Promise<ChimeraQueryCollectionFetcherResponse<Item>>; /** * Delete item using its [id] * @param id id of item to delete */ delete(id: ChimeraEntityId): Promise<ChimeraQueryItemDeleteResponse>; /** * Delete a list of items by their [id]s * @param ids array of items to delete */ batchedDelete(ids: Iterable<ChimeraEntityId>): Promise<ChimeraQueryBatchedDeleteResponse>; /** * Create new item using partial data * @param item partial item data to create new item */ create(item: DeepPartial<Item>): Promise<ChimeraQueryItemFetcherResponse<Item>>; /** * Create multiple items using partial data * @param items array of partial item data to create new items */ batchedCreate(items: Iterable<DeepPartial<Item>>): Promise<ChimeraQueryCollectionFetcherResponse<Item>>; /** * Standard Array API without mutations */ get length(): number; [Symbol.iterator](): Iterator<Item>; at(idx: number): Item | undefined; entries(): ArrayIterator<[number, Item]>; values(): ArrayIterator<Item>; keys(): ArrayIterator<number>; every<S extends Item>(predicate: (value: Item, index: number, query: this) => value is S): this is ChimeraCollectionQuery<S, OperatorsMap>; every(predicate: (value: Item, index: number, query: this) => unknown): boolean; some(predicate: (value: Item, index: number, query: this) => unknown): boolean; filter<S extends Item>(predicate: (value: Item, index: number, query: this) => value is S): S[]; filter(predicate: (value: Item, index: number, query: this) => boolean): Item[]; find<S extends Item>(predicate: (value: Item, index: number, query: this) => value is S): S | undefined; find(predicate: (value: Item, index: number, query: this) => unknown): Item | undefined; findIndex<S extends Item>(predicate: (value: Item, index: number, query: this) => value is S): number; findIndex(predicate: (value: Item, index: number, query: this) => boolean): number; findLast<S extends Item>(predicate: (value: Item, index: number, query: this) => value is S): S | undefined; findLast(predicate: (value: Item, index: number, query: this) => boolean): Item | undefined; findLastIndex<S extends Item>(predicate: (value: Item, index: number, query: this) => value is S): number; findLastIndex(predicate: (value: Item, index: number, query: this) => boolean): number; forEach(cb: (value: Item, index: number, query: this) => void): void; includes(item: Item): boolean; indexOf(item: Item): number; map<U>(cb: (value: Item, index: number, query: this) => U): U[]; reduce<U>(cb: (previousValue: U, currentValue: Item, currentIndex: number, query: this) => U, initialValue?: U): U | undefined; reduceRight<U>(cb: (previousValue: U, currentValue: Item, currentIndex: number, query: this) => U, initialValue?: U): U | undefined; slice(start?: number, end?: number): Item[]; toSorted(compareFn?: (a: Item, b: Item) => number): Item[]; toSpliced(start: number, deleteCount: number, ...items: Item[]): Item[]; toJSON(): Item[]; toString(): string; } //#endregion //#region src/shared/errors.d.ts declare class ChimeraError extends Error {} declare class ChimeraInternalError extends ChimeraError { constructor(message: string, options?: ErrorOptions); } //#endregion //#region src/filter/errors.d.ts declare class ChimeraFilterError extends ChimeraError {} declare class ChimeraFilterOperatorError extends ChimeraFilterError { constructor(operator: string, message: string); } declare class ChimeraFilterOperatorNotFoundError extends ChimeraFilterOperatorError { constructor(operator: string); } //#endregion //#region src/filter/filter.d.ts declare const chimeraCreateOperator: <Entity, OperatorsMap extends ChimeraOperatorMap, Op extends keyof OperatorsMap & string>(op: Op, value: ChimeraPropertyGetter<Entity, Parameters<OperatorsMap[Op]>[0]> | (KeysOfType<Entity, Parameters<OperatorsMap[Op]>[0]> & string), test: Parameters<OperatorsMap[Op]>[1]) => ChimeraFilterOperatorDescriptor<OperatorsMap, Entity, Op>; declare const chimeraCreateConjunction: <Entity, OperatorsMap extends ChimeraOperatorMap, Conj extends Exclude<ChimeraConjunctionType, "not"> = Exclude<ChimeraConjunctionType, "not">>(kind: Conj, operations: ChimeraConjunctionOperationDescriptor<OperatorsMap, Entity>[]) => ChimeraConjunctionDescriptor<OperatorsMap, Entity, Conj>; declare const chimeraCreateNot: <Entity, OperatorsMap extends ChimeraOperatorMap>(operation: ChimeraConjunctionOperationDescriptor<OperatorsMap, Entity>) => ChimeraConjunctionDescriptor<OperatorsMap, Entity, "not">; declare function chimeraIsConjunction(item: ChimeraConjunctionOperationDescriptor<ChimeraOperatorMap, any>): item is ChimeraConjunctionDescriptor<ChimeraOperatorMap, any>; declare function chimeraIsConjunction(item: ChimeraSimplifiedConjunctionOperation<ChimeraOperatorMap>): item is SimplifiedConjunction<ChimeraOperatorMap>; declare function chimeraIsOperator(item: ChimeraConjunctionOperationDescriptor<ChimeraOperatorMap, any>): item is ChimeraFilterOperatorDescriptor<ChimeraOperatorMap, any>; declare function chimeraIsOperator(item: ChimeraSimplifiedConjunctionOperation<ChimeraOperatorMap>): item is ChimeraSimplifiedOperator<ChimeraOperatorMap>; //#endregion //#region src/query/ChimeraItemQuery.d.ts type ChimeraItemQueryEventMap<Item extends object> = { /** Once the query is initialized */ initialized: [{ instance: ChimeraItemQuery<Item>; }]; /** Once the query data was created */ selfCreated: [{ instance: ChimeraItemQuery<Item>; item: Item; }]; /** Once the query data is ready (will be followed by 'update') */ ready: [{ instance: ChimeraItemQuery<Item>; }]; /** Each time the query was updated */ updated: [{ instance: ChimeraItemQuery<Item>; item: Item; oldItem: Item | null; }]; /** Each time the query was an initiator of update */ selfUpdated: [{ instance: ChimeraItemQuery<Item>; item: Item; oldItem: Item | null; }]; /** Once the query data was deleted */ deleted: [{ instance: ChimeraItemQuery<Item>; id: ChimeraEntityId; }]; /** Once the query was an initiator of deletion */ selfDeleted: [{ instance: ChimeraItemQuery<Item>; id: ChimeraEntityId; }]; /** Each time the fetcher produces an error */ error: [{ instance: ChimeraItemQuery<Item>; error: unknown; }]; }; declare class ChimeraItemQuery<Item extends object> extends ChimeraEventEmitter<ChimeraItemQueryEventMap<Item>> implements ChimeraQueryFetchingStatable { #private; emit(): never; constructor(config: QueryEntityConfig<Item, ChimeraOperatorMap>, params: ChimeraQueryEntityItemFetcherParams<Item>, existingItem: Item | null, toCreateItem: DeepPartial<Item> | null); get [ChimeraGetParamsSym](): ChimeraQueryEntityItemFetcherParams<Item>; [ChimeraSetOneSym](item: Item): void; [ChimeraDeleteOneSym](id: ChimeraEntityId): void; get state(): ChimeraQueryFetchingState; get inProgress(): boolean; get ready(): boolean; get lastError(): unknown; get id(): ChimeraEntityId; /** Return an item if it is ready, throw error otherwise */ get data(): Item; /** Get ref for an item that can be changed as a regular object. To send changes to updater, use <commit> method */ get mutable(): Item; get promise(): Promise<unknown> | null; /** * Wait for the current progress process to complete (both success or error) */ get progress(): Promise<void>; /** * Wait for the current progress process to complete, throw an error if it fails */ get result(): Promise<void>; /** * Trigger refetch, return existing refetch promise if already running * @param force If true cancels any running process and starts a new one * @throws {ChimeraQueryAlreadyRunningError} If deleting or updating already in progress */ refetch(force?: boolean): Promise<ChimeraQueryItemFetcherResponse<Item>>; /** * Update item using updated copy, a running update process will be cancelled * @param newItem new item to replace existing * @param force if true cancels any running process including fetch and delete * @throws {ChimeraQueryAlreadyRunningError} If deleting or updating already in progress */ update(newItem: Item, force?: boolean): Promise<ChimeraQueryItemFetcherResponse<Item>>; /** * Update item using function with draft item as argument * that can be used to patch item in place or return a patched value, * a running update process will be cancelled * @param mutator mutator function * @param force if true cancels any running process including fetch and delete * @throws {ChimeraQueryAlreadyRunningError} If deleting or updating already in progress */ mutate(mutator: (draft: Item) => Item, force?: boolean): Promise<ChimeraQueryItemFetcherResponse<Item>>; /** * Commit updated value from mutable ref, a running update process will be canceled * @param force if true cancels any running process including fetch and delete * @throws {ChimeraQueryAlreadyRunningError} If deleting or updating already in progress */ commit(force?: boolean): Promise<ChimeraQueryItemFetcherResponse<Item>>; /** * Request to delete the value. * Local copy will still be available if it was present. * A running delete process will be canceled * @param force if true cancels any running process including fetch and update * @throws {ChimeraQueryAlreadyRunningError} If deleting or updating already in progress */ delete(force?: boolean): Promise<ChimeraQueryItemDeleteResponse>; toJSON(): Item; toString(): string; } //#endregion //#region src/debug/types.d.ts type ChimeraLogLevel = "debug" | "info" | "off"; type ChimeraDebugConfig = { name?: string; logs?: ChimeraLogLevel; devMode?: boolean; }; //#endregion //#region src/store/types.d.ts type ChimeraCollectionParams<OperatorsMap extends ChimeraOperatorMap, Entity, Meta = any> = { filter?: ChimeraFilterDescriptor<OperatorsMap, Entity> | null; order?: ChimeraOrderPriority<Entity> | null; meta?: Meta; }; type ChimeraStoreConfig<EntityMap extends ChimeraEntityMap, OperatorsMap extends ChimeraOperatorMap> = { query?: ChimeraQueryConfig<EntityMap, OperatorsMap>; order?: ChimeraOrderConfig; filter?: ChimeraFilterConfig<OperatorsMap>; debug?: ChimeraDebugConfig; }; //#endregion //#region src/store/ChimeraEntityRepository.d.ts type ChimeraEntityRepositoryEventMap<Item extends object, OperatorsMap extends ChimeraOperatorMap> = { /** Once the repository is initialized */ initialized: { instance: ChimeraEntityRepository<Item, OperatorsMap>; }; /** Each time item added */ itemAdded: [{ instance: ChimeraEntityRepository<Item, OperatorsMap>; item: Item; }]; /** Each time many items updated */ updated: [{ instance: ChimeraEntityRepository<Item, OperatorsMap>; items: Item[]; }]; /** Each time item updated */ itemUpdated: [{ instance: ChimeraEntityRepository<Item, OperatorsMap>; item: Item; oldItem: Item | null; }]; /** Each time many items deleted */ deleted: [{ instance: ChimeraEntityRepository<Item, OperatorsMap>; ids: ChimeraEntityId[]; }]; /** Each time item deleted */ itemDeleted: [{ instance: ChimeraEntityRepository<Item, OperatorsMap>; oldItem: Item | null; }]; }; declare class ChimeraEntityRepository<Item extends object, OperatorsMap extends ChimeraOperatorMap> extends ChimeraEventEmitter<ChimeraEntityRepositoryEventMap<Item, OperatorsMap>> { #private; emit(): never; constructor(config: QueryEntityConfig<Item, OperatorsMap>, filterConfig: Required<ChimeraFilterConfig<OperatorsMap>>, orderConfig: Required<ChimeraOrderConfig>); [ChimeraSetOneSym](item: Item): void; [ChimeraDeleteOneSym](id: ChimeraEntityId): void; [ChimeraSetManySym](items: Item[]): void; [ChimeraDeleteManySym](ids: ChimeraEntityId[]): void; [ChimeraUpdateMixedSym](toAdd: Item[], toDelete: ChimeraEntityId[]): void; createItem(item: DeepPartial<Item>, meta?: any): ChimeraItemQuery<Item>; getItem(id: ChimeraEntityId, meta?: any): ChimeraItemQuery<Item>; getCollection(params: ChimeraCollectionParams<OperatorsMap, Item>): ChimeraCollectionQuery<Item, OperatorsMap>; } //#endregion //#region src/filter/defaults.d.ts declare const getKeyFromOperation: ChimeraKeyFromOperatorGetter; declare const chimeraDefaultGetKeyFromFilter: ChimeraKeyFromFilterGetter; declare const chimeraDefaultFilterOperators: { contains: <I extends string | unknown[], T extends (I extends never[] ? unknown : I extends unknown[] ? I[number] | I : I extends string ? string : never)>(a: I, b: T) => boolean; endsWith: (a: string, b: string) => boolean; startsWith: (a: string, b: string) => boolean; eq: <T>(a: T, b: T) => boolean; gt: (a: any, b: any) => boolean; gte: (a: any, b: any) => boolean; in: <I, T extends (I extends never[] ? unknown[] : I extends unknown[] ? I : I[])>(a: I, b: T) => boolean; lt: (a: any, b: any) => boolean; lte: (a: any, b: any) => boolean; neq: <T>(a: T, b: T) => boolean; notIn: (a: any, b: any) => boolean; }; declare const chimeraDefaultFilterConfig: { getFilterKey: ChimeraKeyFromFilterGetter; getOperatorKey: ChimeraKeyFromOperatorGetter; operators: { contains: <I extends string | unknown[], T extends (I extends never[] ? unknown : I extends unknown[] ? I[number] | I : I extends string ? string : never)>(a: I, b: T) => boolean; endsWith: (a: string, b: string) => boolean; startsWith: (a: string, b: string) => boolean; eq: <T>(a: T, b: T) => boolean; gt: (a: any, b: any) => boolean; gte: (a: any, b: any) => boolean; in: <I, T extends (I extends never[] ? unknown[] : I extends unknown[] ? I : I[])>(a: I, b: T) => boolean; lt: (a: any, b: any) => boolean; lte: (a: any, b: any) => boolean; neq: <T>(a: T, b: T) => boolean; notIn: (a: any, b: any) => boolean; }; }; //#endregion //#region src/store/ChimeraStore.d.ts type ItemEvent<EntityMap extends ChimeraEntityMap> = { [K in StrKeys<EntityMap>]: { entityName: K; item: EntityMap[K]; } }[StrKeys<EntityMap>]; type ManyItemEvent<EntityMap extends ChimeraEntityMap> = { [K in StrKeys<EntityMap>]: { entityName: K; items: EntityMap[K][]; } }[StrKeys<EntityMap>]; type ItemDeleteEvent<EntityMap extends ChimeraEntityMap> = { [K in StrKeys<EntityMap>]: { entityName: K; id: ChimeraEntityId; } }[StrKeys<EntityMap>]; type ManyDeleteEvent<EntityMap extends ChimeraEntityMap> = { [K in StrKeys<EntityMap>]: { entityName: K; ids: ChimeraEntityId[]; } }[StrKeys<EntityMap>]; type RepositoryEvent<EntityMap extends ChimeraEntityMap, OperatorsMap extends ChimeraOperatorMap> = { [K in StrKeys<EntityMap>]: { entityName: K; repository: ChimeraEntityRepository<EntityMap[K], OperatorsMap>; } }[StrKeys<EntityMap>]; type ChimeraStoreEventMap<EntityMap extends ChimeraEntityMap, OperatorsMap extends ChimeraOperatorMap> = { /** Once the store is initialized */ initialized: [{ instance: ChimeraStore<EntityMap, OperatorsMap>; }]; repositoryInitialized: [{ instance: ChimeraStore<EntityMap, OperatorsMap>; } & RepositoryEvent<EntityMap, OperatorsMap>]; /** Each time item added */ itemAdded: [{ instance: ChimeraStore<EntityMap, OperatorsMap>; } & RepositoryEvent<EntityMap, OperatorsMap> & ItemEvent<EntityMap>]; /** Each time many items updated */ updated: [{ instance: ChimeraStore<EntityMap, OperatorsMap>; } & RepositoryEvent<EntityMap, OperatorsMap> & ManyItemEvent<EntityMap>]; /** Each time item updated */ itemUpdated: [{ instance: ChimeraStore<EntityMap, OperatorsMap>; } & RepositoryEvent<EntityMap, OperatorsMap> & ItemEvent<EntityMap>]; /** Each time many items deleted */ deleted: [{ instance: ChimeraStore<EntityMap, OperatorsMap>; } & RepositoryEvent<EntityMap, OperatorsMap> & ManyDeleteEvent<EntityMap>]; /** Each time item deleted */ itemDeleted: [{ instance: ChimeraStore<EntityMap, OperatorsMap>; } & RepositoryEvent<EntityMap, OperatorsMap> & ItemDeleteEvent<EntityMap>]; }; declare class ChimeraStore<EntityMap extends ChimeraEntityMap, OperatorsMap extends ChimeraOperatorMap = typeof chimeraDefaultFilterOperators, Config extends ChimeraStoreConfig<EntityMap, OperatorsMap> = ChimeraStoreConfig<EntityMap, OperatorsMap>> extends ChimeraEventEmitter<ChimeraStoreEventMap<EntityMap, OperatorsMap>> { #private; emit(): never; constructor(config: Config); get config(): Config; from<EntityName extends StrKeys<EntityMap>>(entityName: EntityName): ChimeraEntityRepository<EntityMap[EntityName], OperatorsMap>; updateOne<EntityName extends StrKeys<EntityMap>>(entityName: EntityName, item: EntityMap[EntityName]): void; updateMany<EntityName extends StrKeys<EntityMap>>(entityName: EntityName, items: EntityMap[EntityName][]): void; deleteOne<EntityName extends StrKeys<EntityMap>>(entityName: EntityName, id: ChimeraEntityId): void; deleteMany<EntityName extends StrKeys<EntityMap>>(entityName: EntityName, ids: ChimeraEntityId[]): void; updateMixed<EntityName extends StrKeys<EntityMap>>(entityName: EntityName, toAdd: EntityMap[EntityName][], toDelete: ChimeraEntityId[]): void; } type AnyChimeraStore = ChimeraStore<any, any>; type ExtractsStoreGenerics<T extends AnyChimeraStore> = T extends ChimeraStore<infer E, infer O> ? { entityMap: E; operatorMap: O; } : never; type ChimeraStoreEntityMap<T extends AnyChimeraStore> = ExtractsStoreGenerics<T>["entityMap"]; type ChimeraStoreOperatorMap<T extends AnyChimeraStore> = ExtractsStoreGenerics<T>["operatorMap"]; type ChimeraStoreEntities<T extends AnyChimeraStore> = keyof ChimeraStoreEntityMap<T> & string; type ChimeraStoreOperator<T extends AnyChimeraStore> = keyof ChimeraStoreOperatorMap<T> & string; type ChimeraStoreEntityType<T extends AnyChimeraStore, K$1 extends ChimeraStoreEntities<T>> = ChimeraStoreEntityMap<T>[K$1]; //#endregion //#region src/order/errors.d.ts declare class ChimeraOrderError extends ChimeraError {} declare class ChimeraOrderTypeError extends ChimeraOrderError {} declare class ChimeraOrderTypeComparisonError extends ChimeraOrderTypeError { constructor(a: unknown, b: unknown); } //#endregion //#region src/order/order.d.ts declare const chimeraCreateOrderBy: <Entity>(key: ChimeraPropertyGetter<Entity> | (keyof Entity & string), desc?: boolean, nulls?: ChimeraOrderNulls) => ChimeraOrderDescriptor<Entity>; //#endregion //#region src/query/errors.d.ts declare class ChimeraQueryError extends ChimeraError { readonly entityName: string; constructor(entityName: string, message: string, options?: ErrorOptions); } declare class ChimeraQueryIdMismatchError extends ChimeraQueryError { readonly old: ChimeraEntityId; readonly new: ChimeraEntityId; constructor(entityName: string, oldId: ChimeraEntityId, newId: ChimeraEntityId); } declare class ChimeraQueryNotSpecifiedError extends ChimeraQueryError { readonly methodName: string; constructor(entityName: string, methodName: string); } declare class ChimeraQueryTrustError extends ChimeraQueryError { constructor(entityName: string, description: string); } declare class ChimeraQueryTrustIdMismatchError extends ChimeraQueryTrustError { readonly old: ChimeraEntityId; readonly new: ChimeraEntityId; constructor(entityName: string, oldId: ChimeraEntityId, newId: ChimeraEntityId); } declare class ChimeraQueryTrustFetchedCollectionError extends ChimeraQueryTrustError { readonly old: unknown[]; readonly new: unknown[]; constructor(entityName: string, input: unknown[], output: unknown[]); } //#endregion //#region src/shared/ChimeraWeakValueMap/ChimeraWeakValueMap.d.ts type ChimeraWeakValueMapEventMap<K$1, V extends object> = { /** An item was added to the map */ set: { key: K$1; value: V; instance: ChimeraWeakValueMap<K$1, V>; }; /** An item was removed from the map */ delete: { key: K$1; value: V; instance: ChimeraWeakValueMap<K$1, V>; }; /** Weak reference was automatically collected */ finalize: { key: K$1; instance: ChimeraWeakValueMap<K$1, V>; }; /** All items were removed from the map */ clear: { instance: ChimeraWeakValueMap<K$1, V>; }; }; declare class ChimeraWeakValueMap<K$1, V extends object> extends ChimeraEventEmitter<ChimeraWeakValueMapEventMap<K$1, V>> { #private; emit(): never; constructor(values?: readonly (readonly [K$1, V])[] | null); set(key: K$1, value: V): this; delete(key: K$1): boolean; has(key: K$1): boolean; forEach(callbackFn: (value: V, key: K$1, map: ChimeraWeakValueMap<K$1, V>) => void, thisArg?: any): void; get(key: K$1): V | undefined; get size(): number; entries(): IterableIterator<[K$1, V]>; keys(): IterableIterator<K$1>; values(): IterableIterator<V>; [Symbol.iterator](): IterableIterator<[K$1, V]>; clear(): void; cleanup(): void; get rawSize(): number; } //#endregion export { ChimeraQueryDefaultItemFetcher as $, chimeraCreateNot as A, ChimeraConjunctionType as At, ChimeraCollectionQueryEventMap as B, ChimeraSimplifiedFilter as Bt, getKeyFromOperation as C, ChimeraOrderDescriptor as Ct, ChimeraItemQuery as D, ChimeraSimplifiedOrderDescriptor as Dt, ChimeraStoreConfig as E, ChimeraPrimitiveComparator as Et, ChimeraFilterOperatorError as F, ChimeraKeyFromFilterGetter as Ft, ChimeraQueryDefaultBatchedCreator as G, ChimeraIdGetterFunc as Gt, ChimeraQueryBatchedDeleteResponse as H, ChimeraEntityGetter as Ht, ChimeraFilterOperatorNotFoundError as I, ChimeraKeyFromOperatorGetter as It, ChimeraQueryDefaultCollectionFetcher as J, KeysOfType as Jt, ChimeraQueryDefaultBatchedDeleter as K, ChimeraMutationRequester as Kt, ChimeraError as L, ChimeraOperatorFunction as Lt, chimeraIsConjunction as M, ChimeraFilterConfig as Mt, chimeraIsOperator as N, ChimeraFilterDescriptor as Nt, ChimeraItemQueryEventMap as O, ChimeraConjunctionDescriptor as Ot, ChimeraFilterError as P, ChimeraFilterOperatorDescriptor as Pt, ChimeraQueryDefaultItemDeleter as Q, ChimeraInternalError as R, ChimeraOperatorMap as Rt, chimeraDefaultGetKeyFromFilter as S, ChimeraOrderConfig as St, ChimeraCollectionParams as T, ChimeraOrderPriority as Tt, ChimeraQueryCollectionFetcherResponse as U, ChimeraEntityId as Ut, ChimeraEntityConfigMap as V, ChimeraSimplifiedOperator as Vt, ChimeraQueryConfig as W, ChimeraEntityMap as Wt, ChimeraQueryDefaultEntityIdGetterFunction as X, ChimeraQueryDefaultEntityIdGetter as Y, ChimeraQueryDefaultItemCreator as Z, ChimeraStoreEntityType as _, ChimeraQueryFetchingState as _t, ChimeraQueryNotSpecifiedError as a, ChimeraQueryEntityBatchedUpdater as at, chimeraDefaultFilterConfig as b, ChimeraKeyFromOrderGetter as bt, ChimeraQueryTrustIdMismatchError as c, ChimeraQueryEntityConfig as ct, ChimeraOrderTypeComparisonError as d, ChimeraQueryEntityItemCreator as dt, ChimeraQueryDefaultItemUpdater as et, ChimeraOrderTypeError as f, ChimeraQueryEntityItemDeleter as ft, ChimeraStoreEntityMap as g, ChimeraQueryFetchingStatable as gt, ChimeraStoreEntities as h, ChimeraQueryEntityItemUpdater as ht, ChimeraQueryIdMismatchError as i, ChimeraQueryEntityBatchedDeleter as it, chimeraCreateOperator as j, ChimeraFilterChecker as jt, chimeraCreateConjunction as k, ChimeraConjunctionOperationDescriptor as kt, chimeraCreateOrderBy as l, ChimeraQueryEntityFetcherRequestParams as lt, ChimeraStore as m, ChimeraQueryEntityItemFetcherParams as mt, ChimeraWeakValueMapEventMap as n, ChimeraQueryDeletionResult as nt, ChimeraQueryTrustError as o, ChimeraQueryEntityCollectionFetcher as ot, AnyChimeraStore as p, ChimeraQueryEntityItemFetcher as pt, ChimeraQueryDefaultBatchedUpdater as q, ChimeraPropertyGetter as qt, ChimeraQueryError as r, ChimeraQueryEntityBatchedCreator as rt, ChimeraQueryTrustFetchedCollectionError as s, ChimeraQueryEntityCollectionFetcherParams as st, ChimeraWeakValueMap as t, ChimeraQueryDefaultsConfig as tt, ChimeraOrderError as u, ChimeraQueryEntityIdGetter as ut, ChimeraStoreOperator as v, ChimeraQueryItemDeleteResponse as vt, ChimeraEntityRepository as w, ChimeraOrderNulls as wt, chimeraDefaultFilterOperators as x, ChimeraOrderByComparator as xt, ChimeraStoreOperatorMap as y, ChimeraQueryItemFetcherResponse as yt, ChimeraCollectionQuery as z, ChimeraSimplifiedConjunctionOperation as zt }; //# sourceMappingURL=index-DP6-nR2O.d.cts.map