node_modules ignore

This commit is contained in:
2025-05-08 23:43:47 +02:00
parent e19d52f172
commit 4574544c9f
65041 changed files with 10593536 additions and 0 deletions

2
server/node_modules/@ucast/mongo/dist/es5m/index.js generated vendored Normal file
View File

@@ -0,0 +1,2 @@
import{optimizedCompoundCondition as e,FieldCondition as t,CompoundCondition as r,ITSELF as n,NULL_CONDITION as o,buildAnd as a,ObjectQueryParser as i}from"@ucast/core";export{defaultInstructionParsers as defaultParsers}from"@ucast/core";function f(e,t){if(!Array.isArray(t))throw new Error('"'+e.name+'" expects value to be an array')}function u(e,t){if(f(e,t),!t.length)throw new Error('"'+e.name+'" expects to have at least one element in array')}var c=function(e){return function(t,r){if(typeof r!==e)throw new Error('"'+t.name+'" expects value to be a "'+e+'"')}},p={type:"compound",validate:u,parse:function(t,r,n){var o=n.parse,a=r.map((function(e){return o(e)}));return e(t.name,a)}},s=p,l={type:"compound",validate:u},d={type:"field",validate:function(e,t){if(!(t&&(t instanceof RegExp||t.constructor===Object)))throw new Error('"'+e.name+'" expects to receive either regular expression or object of field operators')},parse:function(e,n,o){var a=n instanceof RegExp?new t("regex",o.field,n):o.parse(n,o);return new r(e.name,[a])}},v={type:"field",validate:function(e,t){if(!t||t.constructor!==Object)throw new Error('"'+e.name+'" expects to receive an object with nested query or field level operators')},parse:function(e,r,o){var a=o.parse,i=o.field,f=(0,o.hasOperators)(r)?a(r,{field:n}):a(r);return new t(e.name,i,f)}},w={type:"field",validate:c("number")},y={type:"field",validate:f},$=y,x=y,h={type:"field",validate:function(e,t){if(!Array.isArray(t)||2!==t.length)throw new Error('"'+e.name+'" expects an array with 2 numeric elements')}},m={type:"field",validate:c("boolean")},g={type:"field",validate:function(e,t){if(!("string"==typeof t||"number"==typeof t||t instanceof Date))throw new Error('"'+e.name+'" expects value to be comparable (i.e., string, number or date)')}},b=g,E=b,j=b,O={type:"field"},R=O,_={type:"field",validate:function(e,t){if(!(t instanceof RegExp)&&"string"!=typeof t)throw new Error('"'+e.name+'" expects value to be a regular expression or a string that represents regular expression')},parse:function(e,r,n){var o="string"==typeof r?new RegExp(r,n.query.$options||""):r;return new t(e.name,n.field,o)}},q={type:"field",parse:function(){return o}},A={type:"document",validate:c("function")},N=Object.freeze({__proto__:null,$and:p,$or:s,$nor:l,$not:d,$elemMatch:v,$size:w,$in:y,$nin:$,$all:x,$mod:h,$exists:m,$gte:g,$gt:b,$lt:E,$lte:j,$eq:O,$ne:R,$regex:_,$options:q,$where:A});var P=function(e){var t,r;function n(t){return e.call(this,t,{defaultOperatorName:"$eq",operatorToConditionName:function(e){return e.slice(1)}})||this}return r=e,(t=n).prototype=Object.create(r.prototype),t.prototype.constructor=t,t.__proto__=r,n.prototype.parse=function(t,r){return r&&r.field?a(this.parseFieldOperators(r.field,t)):e.prototype.parse.call(this,t)},n}(i),z=N;export{x as $all,p as $and,v as $elemMatch,O as $eq,m as $exists,b as $gt,g as $gte,y as $in,E as $lt,j as $lte,h as $mod,R as $ne,$ as $nin,l as $nor,d as $not,q as $options,s as $or,_ as $regex,w as $size,A as $where,P as MongoQueryParser,z as allParsingInstructions};
//# sourceMappingURL=index.js.map

File diff suppressed because one or more lines are too long

2
server/node_modules/@ucast/mongo/dist/es6c/index.js generated vendored Normal file
View File

@@ -0,0 +1,2 @@
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("@ucast/core");function t(e,t){if(!Array.isArray(t))throw new Error(`"${e.name}" expects value to be an array`)}function r(e,r){if(t(e,r),!r.length)throw new Error(`"${e.name}" expects to have at least one element in array`)}const o=e=>(t,r)=>{if(typeof r!==e)throw new Error(`"${t.name}" expects value to be a "${e}"`)},s={type:"compound",validate:r,parse(t,r,{parse:o}){const s=r.map(e=>o(e));return e.optimizedCompoundCondition(t.name,s)}},a=s,n={type:"compound",validate:r},p={type:"field",validate(e,t){if(!(t&&(t instanceof RegExp||t.constructor===Object)))throw new Error(`"${e.name}" expects to receive either regular expression or object of field operators`)},parse(t,r,o){const s=r instanceof RegExp?new e.FieldCondition("regex",o.field,r):o.parse(r,o);return new e.CompoundCondition(t.name,[s])}},i={type:"field",validate(e,t){if(!t||t.constructor!==Object)throw new Error(`"${e.name}" expects to receive an object with nested query or field level operators`)},parse(t,r,{parse:o,field:s,hasOperators:a}){const n=a(r)?o(r,{field:e.ITSELF}):o(r);return new e.FieldCondition(t.name,s,n)}},l={type:"field",validate:o("number")},c={type:"field",validate:t},x=c,f=c,u={type:"field",validate(e,t){if(!Array.isArray(t)||2!==t.length)throw new Error(`"${e.name}" expects an array with 2 numeric elements`)}},d={type:"field",validate:o("boolean")},$={type:"field",validate:function(e,t){if(!("string"==typeof t||"number"==typeof t||t instanceof Date))throw new Error(`"${e.name}" expects value to be comparable (i.e., string, number or date)`)}},w=$,y=w,v=w,b={type:"field"},g=b,h={type:"field",validate(e,t){if(!(t instanceof RegExp)&&"string"!=typeof t)throw new Error(`"${e.name}" expects value to be a regular expression or a string that represents regular expression`)},parse(t,r,o){const s="string"==typeof r?new RegExp(r,o.query.$options||""):r;return new e.FieldCondition(t.name,o.field,s)}},m={type:"field",parse:()=>e.NULL_CONDITION},E={type:"document",validate:o("function")};var j=Object.freeze({__proto__:null,$and:s,$or:a,$nor:n,$not:p,$elemMatch:i,$size:l,$in:c,$nin:x,$all:f,$mod:u,$exists:d,$gte:$,$gt:w,$lt:y,$lte:v,$eq:b,$ne:g,$regex:h,$options:m,$where:E});class O extends e.ObjectQueryParser{constructor(e){super(e,{defaultOperatorName:"$eq",operatorToConditionName:e=>e.slice(1)})}parse(t,r){return r&&r.field?e.buildAnd(this.parseFieldOperators(r.field,t)):super.parse(t)}}const _=j;Object.defineProperty(exports,"defaultParsers",{enumerable:!0,get:function(){return e.defaultInstructionParsers}}),exports.$all=f,exports.$and=s,exports.$elemMatch=i,exports.$eq=b,exports.$exists=d,exports.$gt=w,exports.$gte=$,exports.$in=c,exports.$lt=y,exports.$lte=v,exports.$mod=u,exports.$ne=g,exports.$nin=x,exports.$nor=n,exports.$not=p,exports.$options=m,exports.$or=a,exports.$regex=h,exports.$size=l,exports.$where=E,exports.MongoQueryParser=O,exports.allParsingInstructions=_;
//# sourceMappingURL=index.js.map

File diff suppressed because one or more lines are too long

2
server/node_modules/@ucast/mongo/dist/es6m/index.mjs generated vendored Normal file
View File

@@ -0,0 +1,2 @@
import{optimizedCompoundCondition as e,FieldCondition as t,CompoundCondition as r,ITSELF as o,NULL_CONDITION as a,ObjectQueryParser as n,buildAnd as i}from"@ucast/core";export{defaultInstructionParsers as defaultParsers}from"@ucast/core";function s(e,t){if(!Array.isArray(t))throw new Error(`"${e.name}" expects value to be an array`)}function p(e,t){if(s(e,t),!t.length)throw new Error(`"${e.name}" expects to have at least one element in array`)}const l=e=>(t,r)=>{if(typeof r!==e)throw new Error(`"${t.name}" expects value to be a "${e}"`)},c={type:"compound",validate:p,parse(t,r,{parse:o}){const a=r.map(e=>o(e));return e(t.name,a)}},f=c,d={type:"compound",validate:p},u={type:"field",validate(e,t){if(!(t&&(t instanceof RegExp||t.constructor===Object)))throw new Error(`"${e.name}" expects to receive either regular expression or object of field operators`)},parse(e,o,a){const n=o instanceof RegExp?new t("regex",a.field,o):a.parse(o,a);return new r(e.name,[n])}},$={type:"field",validate(e,t){if(!t||t.constructor!==Object)throw new Error(`"${e.name}" expects to receive an object with nested query or field level operators`)},parse(e,r,{parse:a,field:n,hasOperators:i}){const s=i(r)?a(r,{field:o}):a(r);return new t(e.name,n,s)}},w={type:"field",validate:l("number")},y={type:"field",validate:s},x=y,v=y,h={type:"field",validate(e,t){if(!Array.isArray(t)||2!==t.length)throw new Error(`"${e.name}" expects an array with 2 numeric elements`)}},m={type:"field",validate:l("boolean")},g={type:"field",validate:function(e,t){if(!("string"==typeof t||"number"==typeof t||t instanceof Date))throw new Error(`"${e.name}" expects value to be comparable (i.e., string, number or date)`)}},b=g,E=b,j=b,O={type:"field"},R=O,_={type:"field",validate(e,t){if(!(t instanceof RegExp)&&"string"!=typeof t)throw new Error(`"${e.name}" expects value to be a regular expression or a string that represents regular expression`)},parse(e,r,o){const a="string"==typeof r?new RegExp(r,o.query.$options||""):r;return new t(e.name,o.field,a)}},q={type:"field",parse:()=>a},A={type:"document",validate:l("function")};var N=Object.freeze({__proto__:null,$and:c,$or:f,$nor:d,$not:u,$elemMatch:$,$size:w,$in:y,$nin:x,$all:v,$mod:h,$exists:m,$gte:g,$gt:b,$lt:E,$lte:j,$eq:O,$ne:R,$regex:_,$options:q,$where:A});class P extends n{constructor(e){super(e,{defaultOperatorName:"$eq",operatorToConditionName:e=>e.slice(1)})}parse(e,t){return t&&t.field?i(this.parseFieldOperators(t.field,e)):super.parse(e)}}const z=N;export{v as $all,c as $and,$ as $elemMatch,O as $eq,m as $exists,b as $gt,g as $gte,y as $in,E as $lt,j as $lte,h as $mod,R as $ne,x as $nin,d as $nor,u as $not,q as $options,f as $or,_ as $regex,w as $size,A as $where,P as MongoQueryParser,z as allParsingInstructions};
//# sourceMappingURL=index.mjs.map

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,9 @@
import { Condition, ParsingInstruction, ObjectQueryParser, FieldQueryOperators } from '@ucast/core';
import { MongoQuery } from './types';
export interface ParseOptions {
field: string;
}
export declare class MongoQueryParser extends ObjectQueryParser<MongoQuery<any>> {
constructor(instructions: Record<string, ParsingInstruction>);
parse<Q extends MongoQuery<any>, FQ extends FieldQueryOperators<Q> = FieldQueryOperators<Q>>(query: Q | FQ, options?: ParseOptions): Condition;
}

View File

@@ -0,0 +1,6 @@
import * as instructions from './instructions';
export declare const allParsingInstructions: typeof instructions;
export * from './instructions';
export * from './MongoQueryParser';
export * from './types';
export { defaultInstructionParsers as defaultParsers } from '@ucast/core';

View File

@@ -0,0 +1,29 @@
import { CompoundInstruction, FieldInstruction, DocumentInstruction, Comparable, FieldParsingContext, ObjectQueryFieldParsingContext } from '@ucast/core';
import { MongoQuery } from './types';
export declare const $and: CompoundInstruction<MongoQuery<any>[]>;
export declare const $or: CompoundInstruction<(import("./types").MongoQueryOperators<any> | ({
[x: string]: any;
} & import("./types").MongoQueryTopLevelOperators<any>))[], {}>;
export declare const $nor: CompoundInstruction<MongoQuery<any>[]>;
export declare const $not: FieldInstruction<MongoQuery<any> | RegExp>;
export declare const $elemMatch: FieldInstruction<MongoQuery<any>, ObjectQueryFieldParsingContext>;
export declare const $size: FieldInstruction<number>;
export declare const $in: FieldInstruction<unknown[]>;
export declare const $nin: FieldInstruction<unknown[], FieldParsingContext>;
export declare const $all: FieldInstruction<unknown[], FieldParsingContext>;
export declare const $mod: FieldInstruction<[number, number]>;
export declare const $exists: FieldInstruction<boolean>;
export declare const $gte: FieldInstruction<Comparable>;
export declare const $gt: FieldInstruction<string | number | Date, FieldParsingContext>;
export declare const $lt: FieldInstruction<string | number | Date, FieldParsingContext>;
export declare const $lte: FieldInstruction<string | number | Date, FieldParsingContext>;
export declare const $eq: FieldInstruction;
export declare const $ne: FieldInstruction<unknown, FieldParsingContext>;
export interface RegExpFieldContext extends FieldParsingContext {
query: {
$options?: string;
};
}
export declare const $regex: FieldInstruction<string | RegExp, RegExpFieldContext>;
export declare const $options: FieldInstruction;
export declare const $where: DocumentInstruction<() => boolean>;

43
server/node_modules/@ucast/mongo/dist/types/types.d.ts generated vendored Normal file
View File

@@ -0,0 +1,43 @@
import { Comparable } from '@ucast/core';
export interface MongoQueryTopLevelOperators<Value> {
$and?: MongoQuery<Value>[];
$or?: MongoQuery<Value>[];
$nor?: MongoQuery<Value>[];
$where?: (this: Value) => boolean;
}
export interface MongoQueryFieldOperators<Value = any> {
$eq?: Value;
$ne?: Value;
$lt?: Extract<Comparable, Value>;
$lte?: Extract<Comparable, Value>;
$gt?: Extract<Comparable, Value>;
$gte?: Extract<Comparable, Value>;
$in?: Value[];
$nin?: Value[];
$all?: Value[];
/** checks by array length */
$size?: number;
$regex?: RegExp | string;
$options?: 'i' | 'g' | 'm' | 'u';
/** checks the shape of array item */
$elemMatch?: MongoQuery<Value>;
$exists?: boolean;
$not?: Omit<MongoQueryFieldOperators<Value>, '$not'>;
}
export declare type MongoQueryOperators<Value = any> = MongoQueryFieldOperators<Value> & MongoQueryTopLevelOperators<Value>;
export interface CustomOperators {
toplevel?: {};
field?: {};
}
declare type ItemOf<T, AdditionalArrayTypes = never> = T extends any[] ? T[number] | AdditionalArrayTypes : T;
declare type OperatorValues<T> = null | T | Partial<ItemOf<T, []>> | MongoQueryFieldOperators<ItemOf<T>>;
declare type Query<T extends Record<PropertyKey, any>, FieldOperators> = {
[K in keyof T]?: OperatorValues<T[K]> | FieldOperators;
};
export interface DefaultOperators<T> {
toplevel: MongoQueryTopLevelOperators<T>;
field: MongoQueryOperators<T>;
}
export declare type BuildMongoQuery<T = Record<PropertyKey, any>, O extends CustomOperators = DefaultOperators<T>> = T extends Record<PropertyKey, any> ? Query<T, O['field']> & O['toplevel'] : O['field'] & O['toplevel'];
export declare type MongoQuery<T = Record<PropertyKey, any>, O extends CustomOperators = CustomOperators> = BuildMongoQuery<T, DefaultOperators<T> & O>;
export {};

View File

@@ -0,0 +1,2 @@
import { MongoQueryOperators } from './types';
export declare function hasOperators(value: any): value is MongoQueryOperators;

2
server/node_modules/@ucast/mongo/dist/umd/index.js generated vendored Normal file
View File

@@ -0,0 +1,2 @@
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("@ucast/core")):"function"==typeof define&&define.amd?define(["exports","@ucast/core"],t):t(((e=e||self).ucast=e.ucast||{},e.ucast.mongo={}),e.ucast.core)}(this,(function(e,t){"use strict";function r(e,t){if(!Array.isArray(t))throw new Error('"'+e.name+'" expects value to be an array')}function n(e,t){if(r(e,t),!t.length)throw new Error('"'+e.name+'" expects to have at least one element in array')}var o=function(e){return function(t,r){if(typeof r!==e)throw new Error('"'+t.name+'" expects value to be a "'+e+'"')}},i={type:"compound",validate:n,parse:function(e,r,n){var o=n.parse,i=r.map((function(e){return o(e)}));return t.optimizedCompoundCondition(e.name,i)}},a=i,f={type:"compound",validate:n},u={type:"field",validate:function(e,t){if(!(t&&(t instanceof RegExp||t.constructor===Object)))throw new Error('"'+e.name+'" expects to receive either regular expression or object of field operators')},parse:function(e,r,n){var o=r instanceof RegExp?new t.FieldCondition("regex",n.field,r):n.parse(r,n);return new t.CompoundCondition(e.name,[o])}},c={type:"field",validate:function(e,t){if(!t||t.constructor!==Object)throw new Error('"'+e.name+'" expects to receive an object with nested query or field level operators')},parse:function(e,r,n){var o=n.parse,i=n.field,a=(0,n.hasOperators)(r)?o(r,{field:t.ITSELF}):o(r);return new t.FieldCondition(e.name,i,a)}},s={type:"field",validate:o("number")},p={type:"field",validate:r},l=p,d=p,v={type:"field",validate:function(e,t){if(!Array.isArray(t)||2!==t.length)throw new Error('"'+e.name+'" expects an array with 2 numeric elements')}},y={type:"field",validate:o("boolean")},w={type:"field",validate:function(e,t){if(!("string"==typeof t||"number"==typeof t||t instanceof Date))throw new Error('"'+e.name+'" expects value to be comparable (i.e., string, number or date)')}},x=w,$=x,h=x,b={type:"field"},g=b,m={type:"field",validate:function(e,t){if(!(t instanceof RegExp)&&"string"!=typeof t)throw new Error('"'+e.name+'" expects value to be a regular expression or a string that represents regular expression')},parse:function(e,r,n){var o="string"==typeof r?new RegExp(r,n.query.$options||""):r;return new t.FieldCondition(e.name,n.field,o)}},E={type:"field",parse:function(){return t.NULL_CONDITION}},j={type:"document",validate:o("function")},O=Object.freeze({__proto__:null,$and:i,$or:a,$nor:f,$not:u,$elemMatch:c,$size:s,$in:p,$nin:l,$all:d,$mod:v,$exists:y,$gte:w,$gt:x,$lt:$,$lte:h,$eq:b,$ne:g,$regex:m,$options:E,$where:j});var _=function(e){var r,n;function o(t){return e.call(this,t,{defaultOperatorName:"$eq",operatorToConditionName:function(e){return e.slice(1)}})||this}return n=e,(r=o).prototype=Object.create(n.prototype),r.prototype.constructor=r,r.__proto__=n,o.prototype.parse=function(r,n){return n&&n.field?t.buildAnd(this.parseFieldOperators(n.field,r)):e.prototype.parse.call(this,r)},o}(t.ObjectQueryParser),q=O;Object.defineProperty(e,"defaultParsers",{enumerable:!0,get:function(){return t.defaultInstructionParsers}}),e.$all=d,e.$and=i,e.$elemMatch=c,e.$eq=b,e.$exists=y,e.$gt=x,e.$gte=w,e.$in=p,e.$lt=$,e.$lte=h,e.$mod=v,e.$ne=g,e.$nin=l,e.$nor=f,e.$not=u,e.$options=E,e.$or=a,e.$regex=m,e.$size=s,e.$where=j,e.MongoQueryParser=_,e.allParsingInstructions=q,Object.defineProperty(e,"__esModule",{value:!0})}));
//# sourceMappingURL=index.js.map

File diff suppressed because one or more lines are too long