@atscript/db 0.1.145 → 0.1.147
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/agg.cjs +1 -1
- package/dist/agg.d.cts +1 -1
- package/dist/agg.d.mts +1 -1
- package/dist/agg.mjs +1 -1
- package/dist/{aggregate-fns-CfsveE1w.mjs → aggregate-fns-C0BymEqa.mjs} +3 -1
- package/dist/{aggregate-fns-CGBv3E8S.cjs → aggregate-fns-CtsRbZn9.cjs} +8 -0
- package/dist/{buckets-DYFu0eZ8.d.cts → buckets-CjdPipCC.d.cts} +522 -17
- package/dist/{buckets-DRycmhOW.d.mts → buckets-DYopfd2Y.d.mts} +522 -17
- package/dist/{column-diff-e2oHc71_.mjs → column-diff-CO06iQvI.mjs} +862 -115
- package/dist/{column-diff-D_Kyuh0S.cjs → column-diff-Dt7EDJsA.cjs} +872 -113
- package/dist/{column-diff-Q9UmWn5x.d.mts → fk-diff-BtOmL4OW.d.mts} +48 -2
- package/dist/{column-diff-w-Mym_3w.d.cts → fk-diff-DLqwVkKG.d.cts} +48 -2
- package/dist/index.cjs +28 -33
- package/dist/index.d.cts +40 -15
- package/dist/index.d.mts +40 -15
- package/dist/index.mjs +5 -33
- package/dist/{nested-writer-CnOOAehr.mjs → nested-writer-D35UsDBT.mjs} +542 -2
- package/dist/{nested-writer-xfQwxplL.cjs → nested-writer-SqtYJHF0.cjs} +666 -0
- package/dist/plugin.cjs +266 -5
- package/dist/plugin.mjs +267 -6
- package/dist/rel.cjs +2 -2
- package/dist/rel.d.cts +2 -2
- package/dist/rel.d.mts +2 -2
- package/dist/rel.mjs +2 -2
- package/dist/{relation-helpers-B-0NRKat.d.mts → relation-helpers-C2bLtE-t.d.mts} +1 -1
- package/dist/{relation-helpers-BOMm_HUI.d.cts → relation-helpers-DH3LvwLV.d.cts} +1 -1
- package/dist/relation-loader-BFhVuJ-B.cjs +369 -0
- package/dist/relation-loader-C0qE8xgR.mjs +370 -0
- package/dist/shared.cjs +1 -1
- package/dist/shared.d.cts +4 -3
- package/dist/shared.d.mts +4 -3
- package/dist/shared.mjs +1 -1
- package/dist/sync.cjs +10 -6
- package/dist/sync.d.cts +2 -25
- package/dist/sync.d.mts +2 -25
- package/dist/sync.mjs +10 -6
- package/dist/{validation-utils-DOsB4e6G.cjs → validation-utils-Da2GjobR.cjs} +35 -24
- package/dist/{validation-utils-CMR4fe2M.mjs → validation-utils-Dq0uZ7ef.mjs} +35 -24
- package/dist/{validator-Bw6ks9Hy.d.mts → validator-CMnTI6r7.d.cts} +9 -6
- package/dist/{validator-Bw6ks9Hy.d.cts → validator-CMnTI6r7.d.mts} +9 -6
- package/dist/validator.d.cts +1 -1
- package/dist/validator.d.mts +1 -1
- package/package.json +8 -8
- package/dist/relation-loader-CBPY6kM7.cjs +0 -461
- package/dist/relation-loader-D9XuXaMv.mjs +0 -462
|
@@ -344,44 +344,55 @@ function hasAnyViewAnnotation(node) {
|
|
|
344
344
|
return viewAnnotationNames.some((name) => node.countAnnotations(name) > 0);
|
|
345
345
|
}
|
|
346
346
|
/**
|
|
347
|
-
*
|
|
348
|
-
*
|
|
347
|
+
* Every field ref of a backtick argument — a predicate (`queryNode`), an
|
|
348
|
+
* arithmetic expression (`exprNode`) or an ordering (`orderNode`) — in source
|
|
349
|
+
* order. `[]` when the argument did not parse.
|
|
350
|
+
* @since 0.1.147
|
|
351
|
+
*/
|
|
352
|
+
function backtickFieldRefs(token) {
|
|
353
|
+
if (token.queryNode) {
|
|
354
|
+
const refs = [];
|
|
355
|
+
forEachFieldRef(token.queryNode.expression, (ref) => refs.push(ref));
|
|
356
|
+
return refs;
|
|
357
|
+
}
|
|
358
|
+
return (token.exprNode ?? token.orderNode)?.fieldRefs() ?? [];
|
|
359
|
+
}
|
|
360
|
+
/**
|
|
361
|
+
* Validate that all field refs in a backtick argument (a query, an `expr` or
|
|
362
|
+
* an `order`) are within `scope` — the same {@link TQueryScope} the editor
|
|
363
|
+
* completes (`lsp-scopes`):
|
|
349
364
|
* qualified refs must name one of `scope.allowedTypes`; an unqualified ref
|
|
350
365
|
* (a dotted path included) must be a field of `scope.unqualifiedTarget`, or
|
|
351
366
|
* is rejected outright when that is `null`.
|
|
352
367
|
*
|
|
353
|
-
* @param queryToken - The
|
|
368
|
+
* @param queryToken - The backtick arg token (with `.queryNode`, `.exprNode` or `.orderNode`)
|
|
354
369
|
* @param scope - The scope of the argument
|
|
355
370
|
* @param doc - The document for type lookups
|
|
356
371
|
* @param scopeHint - Replaces the default "expected 'A' or 'B'" tail of the out-of-scope message
|
|
357
372
|
*/
|
|
358
373
|
function validateQueryScope(queryToken, scope, doc, scopeHint) {
|
|
359
374
|
const errors = [];
|
|
360
|
-
const queryNode = queryToken.queryNode;
|
|
361
|
-
if (!queryNode) return errors;
|
|
362
375
|
const { allowedTypes, unqualifiedTarget } = scope;
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
message: `Query references '${typeName}' which is not in scope — ${scopeHint ?? `expected ${allowedTypes.map((t) => `'${t}'`).join(" or ")}`}`,
|
|
368
|
-
severity: 1,
|
|
369
|
-
range: ref.typeRef.range
|
|
370
|
-
});
|
|
371
|
-
} else if (unqualifiedTarget === null) errors.push({
|
|
372
|
-
message: `Unqualified field reference '${ref.fieldRef.text}' — use qualified form (e.g., Type.${ref.fieldRef.text})`,
|
|
376
|
+
for (const ref of backtickFieldRefs(queryToken)) if (ref.typeRef) {
|
|
377
|
+
const typeName = ref.typeRef.text;
|
|
378
|
+
if (!allowedTypes.includes(typeName)) errors.push({
|
|
379
|
+
message: `Query references '${typeName}' which is not in scope — ${scopeHint ?? `expected ${allowedTypes.map((t) => `'${t}'`).join(" or ")}`}`,
|
|
373
380
|
severity: 1,
|
|
374
|
-
range: ref.
|
|
381
|
+
range: ref.typeRef.range
|
|
375
382
|
});
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
severity: 1,
|
|
381
|
-
range: ref.fieldRef.range
|
|
382
|
-
});
|
|
383
|
-
}
|
|
383
|
+
} else if (unqualifiedTarget === null) errors.push({
|
|
384
|
+
message: `Unqualified field reference '${ref.fieldRef.text}' — use qualified form (e.g., Type.${ref.fieldRef.text})`,
|
|
385
|
+
severity: 1,
|
|
386
|
+
range: ref.fieldRef.range
|
|
384
387
|
});
|
|
388
|
+
else {
|
|
389
|
+
const targetDef = doc.unwindType(unqualifiedTarget)?.def;
|
|
390
|
+
if (targetDef && ((0, _atscript_core.isInterface)(targetDef) || (0, _atscript_core.isStructure)(targetDef)) && !doc.unwindType(unqualifiedTarget, ref.fieldRef.text.split("."))) errors.push({
|
|
391
|
+
message: `Field '${ref.fieldRef.text}' does not exist on '${unqualifiedTarget}'`,
|
|
392
|
+
severity: 1,
|
|
393
|
+
range: ref.fieldRef.range
|
|
394
|
+
});
|
|
395
|
+
}
|
|
385
396
|
return errors;
|
|
386
397
|
}
|
|
387
398
|
/**
|
|
@@ -344,44 +344,55 @@ function hasAnyViewAnnotation(node) {
|
|
|
344
344
|
return viewAnnotationNames.some((name) => node.countAnnotations(name) > 0);
|
|
345
345
|
}
|
|
346
346
|
/**
|
|
347
|
-
*
|
|
348
|
-
*
|
|
347
|
+
* Every field ref of a backtick argument — a predicate (`queryNode`), an
|
|
348
|
+
* arithmetic expression (`exprNode`) or an ordering (`orderNode`) — in source
|
|
349
|
+
* order. `[]` when the argument did not parse.
|
|
350
|
+
* @since 0.1.147
|
|
351
|
+
*/
|
|
352
|
+
function backtickFieldRefs(token) {
|
|
353
|
+
if (token.queryNode) {
|
|
354
|
+
const refs = [];
|
|
355
|
+
forEachFieldRef(token.queryNode.expression, (ref) => refs.push(ref));
|
|
356
|
+
return refs;
|
|
357
|
+
}
|
|
358
|
+
return (token.exprNode ?? token.orderNode)?.fieldRefs() ?? [];
|
|
359
|
+
}
|
|
360
|
+
/**
|
|
361
|
+
* Validate that all field refs in a backtick argument (a query, an `expr` or
|
|
362
|
+
* an `order`) are within `scope` — the same {@link TQueryScope} the editor
|
|
363
|
+
* completes (`lsp-scopes`):
|
|
349
364
|
* qualified refs must name one of `scope.allowedTypes`; an unqualified ref
|
|
350
365
|
* (a dotted path included) must be a field of `scope.unqualifiedTarget`, or
|
|
351
366
|
* is rejected outright when that is `null`.
|
|
352
367
|
*
|
|
353
|
-
* @param queryToken - The
|
|
368
|
+
* @param queryToken - The backtick arg token (with `.queryNode`, `.exprNode` or `.orderNode`)
|
|
354
369
|
* @param scope - The scope of the argument
|
|
355
370
|
* @param doc - The document for type lookups
|
|
356
371
|
* @param scopeHint - Replaces the default "expected 'A' or 'B'" tail of the out-of-scope message
|
|
357
372
|
*/
|
|
358
373
|
function validateQueryScope(queryToken, scope, doc, scopeHint) {
|
|
359
374
|
const errors = [];
|
|
360
|
-
const queryNode = queryToken.queryNode;
|
|
361
|
-
if (!queryNode) return errors;
|
|
362
375
|
const { allowedTypes, unqualifiedTarget } = scope;
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
message: `Query references '${typeName}' which is not in scope — ${scopeHint ?? `expected ${allowedTypes.map((t) => `'${t}'`).join(" or ")}`}`,
|
|
368
|
-
severity: 1,
|
|
369
|
-
range: ref.typeRef.range
|
|
370
|
-
});
|
|
371
|
-
} else if (unqualifiedTarget === null) errors.push({
|
|
372
|
-
message: `Unqualified field reference '${ref.fieldRef.text}' — use qualified form (e.g., Type.${ref.fieldRef.text})`,
|
|
376
|
+
for (const ref of backtickFieldRefs(queryToken)) if (ref.typeRef) {
|
|
377
|
+
const typeName = ref.typeRef.text;
|
|
378
|
+
if (!allowedTypes.includes(typeName)) errors.push({
|
|
379
|
+
message: `Query references '${typeName}' which is not in scope — ${scopeHint ?? `expected ${allowedTypes.map((t) => `'${t}'`).join(" or ")}`}`,
|
|
373
380
|
severity: 1,
|
|
374
|
-
range: ref.
|
|
381
|
+
range: ref.typeRef.range
|
|
375
382
|
});
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
severity: 1,
|
|
381
|
-
range: ref.fieldRef.range
|
|
382
|
-
});
|
|
383
|
-
}
|
|
383
|
+
} else if (unqualifiedTarget === null) errors.push({
|
|
384
|
+
message: `Unqualified field reference '${ref.fieldRef.text}' — use qualified form (e.g., Type.${ref.fieldRef.text})`,
|
|
385
|
+
severity: 1,
|
|
386
|
+
range: ref.fieldRef.range
|
|
384
387
|
});
|
|
388
|
+
else {
|
|
389
|
+
const targetDef = doc.unwindType(unqualifiedTarget)?.def;
|
|
390
|
+
if (targetDef && (isInterface(targetDef) || isStructure(targetDef)) && !doc.unwindType(unqualifiedTarget, ref.fieldRef.text.split("."))) errors.push({
|
|
391
|
+
message: `Field '${ref.fieldRef.text}' does not exist on '${unqualifiedTarget}'`,
|
|
392
|
+
severity: 1,
|
|
393
|
+
range: ref.fieldRef.range
|
|
394
|
+
});
|
|
395
|
+
}
|
|
385
396
|
return errors;
|
|
386
397
|
}
|
|
387
398
|
/**
|
|
@@ -1,7 +1,14 @@
|
|
|
1
1
|
import { TAtscriptAnnotatedType, TAtscriptTypeArray, TAtscriptTypeObject, TValidatorPlugin, Validator } from "@atscript/typescript/utils";
|
|
2
2
|
|
|
3
3
|
//#region src/db-error.d.ts
|
|
4
|
-
type DbErrorCode = "CONFLICT" | "FK_VIOLATION" | "NOT_FOUND" | "CASCADE_CYCLE" | "INVALID_QUERY" | "DEPTH_EXCEEDED" | "VERSION_COLUMN_WRITE" | "CAS_EXHAUSTED" | "CAS_MISMATCH" | "ENC_CONFIG_MISSING" | "ENC_KEY_INVALID" | "ENC_NOT_ENCRYPTED" | "ENC_DECRYPT_FAILED" | "ENC_FIELD_FILTER" | "ENC_FIELD_SORT" | "ENC_FIELD_AGG" | "ENC_FIELD_PATCH_OP" | "GEO_INDEX_MISSING" | "GEO_NOT_SUPPORTED" | "FILTER_TYPE_MISMATCH" /** The adapter's `calendarBucketUnits()` lacks the requested unit (moost-db: 400). */ | "BUCKET_NOT_SUPPORTED" /** The engine cannot resolve the bucket's time zone — a store-configuration condition (moost-db: 501). */ | "BUCKET_TZ_UNAVAILABLE" /** A known aggregate function the adapter's `aggregateFns()` lacks (moost-db: 400). @since 0.1.136 */ | "AGG_FN_NOT_SUPPORTED"
|
|
4
|
+
type DbErrorCode = "CONFLICT" | "FK_VIOLATION" | "NOT_FOUND" | "CASCADE_CYCLE" | "INVALID_QUERY" | "DEPTH_EXCEEDED" | "VERSION_COLUMN_WRITE" | "CAS_EXHAUSTED" | "CAS_MISMATCH" | "ENC_CONFIG_MISSING" | "ENC_KEY_INVALID" | "ENC_NOT_ENCRYPTED" | "ENC_DECRYPT_FAILED" | "ENC_FIELD_FILTER" | "ENC_FIELD_SORT" | "ENC_FIELD_AGG" | "ENC_FIELD_PATCH_OP" | "GEO_INDEX_MISSING" | "GEO_NOT_SUPPORTED" | "FILTER_TYPE_MISMATCH" /** The adapter's `calendarBucketUnits()` lacks the requested unit (moost-db: 400). */ | "BUCKET_NOT_SUPPORTED" /** The engine cannot resolve the bucket's time zone — a store-configuration condition (moost-db: 501). */ | "BUCKET_TZ_UNAVAILABLE" /** A known aggregate function the adapter's `aggregateFns()` lacks (moost-db: 400). @since 0.1.136 */ | "AGG_FN_NOT_SUPPORTED"
|
|
5
|
+
/**
|
|
6
|
+
* The adapter (or the table's wiring) cannot run a relational predicate:
|
|
7
|
+
* `supportsRelationFilters()` is false for the read/write mode, the related
|
|
8
|
+
* table lives on a different adapter, or the table was built without a
|
|
9
|
+
* `DbSpace` (moost-db: 400). @since 0.1.147
|
|
10
|
+
*/
|
|
11
|
+
| "REL_FILTER_NOT_SUPPORTED" | "TX_WAIT_TIMEOUT";
|
|
5
12
|
declare class DbError extends Error {
|
|
6
13
|
readonly code: DbErrorCode;
|
|
7
14
|
readonly errors: Array<{
|
|
@@ -39,11 +46,7 @@ declare class CasMismatchError extends DbError {
|
|
|
39
46
|
/** Keys passed to `touchMany`. */
|
|
40
47
|
readonly expected: number;
|
|
41
48
|
name: string;
|
|
42
|
-
constructor(/** Rows whose primary key + version matched. */
|
|
43
|
-
|
|
44
|
-
matched: number, /** Keys passed to `touchMany`. */
|
|
45
|
-
|
|
46
|
-
expected: number);
|
|
49
|
+
constructor(/** Rows whose primary key + version matched. */matched: number, /** Keys passed to `touchMany`. */expected: number);
|
|
47
50
|
}
|
|
48
51
|
/**
|
|
49
52
|
* The engine cannot resolve a calendar bucket's time zone (`BUCKET_TZ_UNAVAILABLE`,
|
|
@@ -1,7 +1,14 @@
|
|
|
1
1
|
import { TAtscriptAnnotatedType, TAtscriptTypeArray, TAtscriptTypeObject, TValidatorPlugin, Validator } from "@atscript/typescript/utils";
|
|
2
2
|
|
|
3
3
|
//#region src/db-error.d.ts
|
|
4
|
-
type DbErrorCode = "CONFLICT" | "FK_VIOLATION" | "NOT_FOUND" | "CASCADE_CYCLE" | "INVALID_QUERY" | "DEPTH_EXCEEDED" | "VERSION_COLUMN_WRITE" | "CAS_EXHAUSTED" | "CAS_MISMATCH" | "ENC_CONFIG_MISSING" | "ENC_KEY_INVALID" | "ENC_NOT_ENCRYPTED" | "ENC_DECRYPT_FAILED" | "ENC_FIELD_FILTER" | "ENC_FIELD_SORT" | "ENC_FIELD_AGG" | "ENC_FIELD_PATCH_OP" | "GEO_INDEX_MISSING" | "GEO_NOT_SUPPORTED" | "FILTER_TYPE_MISMATCH" /** The adapter's `calendarBucketUnits()` lacks the requested unit (moost-db: 400). */ | "BUCKET_NOT_SUPPORTED" /** The engine cannot resolve the bucket's time zone — a store-configuration condition (moost-db: 501). */ | "BUCKET_TZ_UNAVAILABLE" /** A known aggregate function the adapter's `aggregateFns()` lacks (moost-db: 400). @since 0.1.136 */ | "AGG_FN_NOT_SUPPORTED"
|
|
4
|
+
type DbErrorCode = "CONFLICT" | "FK_VIOLATION" | "NOT_FOUND" | "CASCADE_CYCLE" | "INVALID_QUERY" | "DEPTH_EXCEEDED" | "VERSION_COLUMN_WRITE" | "CAS_EXHAUSTED" | "CAS_MISMATCH" | "ENC_CONFIG_MISSING" | "ENC_KEY_INVALID" | "ENC_NOT_ENCRYPTED" | "ENC_DECRYPT_FAILED" | "ENC_FIELD_FILTER" | "ENC_FIELD_SORT" | "ENC_FIELD_AGG" | "ENC_FIELD_PATCH_OP" | "GEO_INDEX_MISSING" | "GEO_NOT_SUPPORTED" | "FILTER_TYPE_MISMATCH" /** The adapter's `calendarBucketUnits()` lacks the requested unit (moost-db: 400). */ | "BUCKET_NOT_SUPPORTED" /** The engine cannot resolve the bucket's time zone — a store-configuration condition (moost-db: 501). */ | "BUCKET_TZ_UNAVAILABLE" /** A known aggregate function the adapter's `aggregateFns()` lacks (moost-db: 400). @since 0.1.136 */ | "AGG_FN_NOT_SUPPORTED"
|
|
5
|
+
/**
|
|
6
|
+
* The adapter (or the table's wiring) cannot run a relational predicate:
|
|
7
|
+
* `supportsRelationFilters()` is false for the read/write mode, the related
|
|
8
|
+
* table lives on a different adapter, or the table was built without a
|
|
9
|
+
* `DbSpace` (moost-db: 400). @since 0.1.147
|
|
10
|
+
*/
|
|
11
|
+
| "REL_FILTER_NOT_SUPPORTED" | "TX_WAIT_TIMEOUT";
|
|
5
12
|
declare class DbError extends Error {
|
|
6
13
|
readonly code: DbErrorCode;
|
|
7
14
|
readonly errors: Array<{
|
|
@@ -39,11 +46,7 @@ declare class CasMismatchError extends DbError {
|
|
|
39
46
|
/** Keys passed to `touchMany`. */
|
|
40
47
|
readonly expected: number;
|
|
41
48
|
name: string;
|
|
42
|
-
constructor(/** Rows whose primary key + version matched. */
|
|
43
|
-
|
|
44
|
-
matched: number, /** Keys passed to `touchMany`. */
|
|
45
|
-
|
|
46
|
-
expected: number);
|
|
49
|
+
constructor(/** Rows whose primary key + version matched. */matched: number, /** Keys passed to `touchMany`. */expected: number);
|
|
47
50
|
}
|
|
48
51
|
/**
|
|
49
52
|
* The engine cannot resolve a calendar bucket's time zone (`BUCKET_TZ_UNAVAILABLE`,
|
package/dist/validator.d.cts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { a as $mul, c as $update, d as TDbFieldOp, g as separateCas, h as reconcileCas, i as $insert, l as $upsert, m as isDbFieldOp, n as $dec, o as $remove, r as $inc, s as $replace, t as $cas, u as TDbCas } from "./ops-AqhV7s9o.cjs";
|
|
2
2
|
import { a as isPlainObject, i as isEmptyObject } from "./object-CtPYTIvy.cjs";
|
|
3
|
-
import { a as buildValidationContext, c as isNavRelation, d as getKeyProps, i as buildPatchPartial, l as TArrayPatch, m as DbError, n as ValidatorMode, o as dbPlugin, r as buildDbValidator, s as forceNavNonOptional, t as ValidationContext, u as TDbPatch } from "./validator-
|
|
3
|
+
import { a as buildValidationContext, c as isNavRelation, d as getKeyProps, i as buildPatchPartial, l as TArrayPatch, m as DbError, n as ValidatorMode, o as dbPlugin, r as buildDbValidator, s as forceNavNonOptional, t as ValidationContext, u as TDbPatch } from "./validator-CMnTI6r7.cjs";
|
|
4
4
|
import { n as createDbValidatorPlugin, t as DbValidationContext } from "./db-validator-plugin-BWy60OvG.cjs";
|
|
5
5
|
export { $cas, $dec, $inc, $insert, $mul, $remove, $replace, $update, $upsert, DbError, type DbValidationContext, type TArrayPatch, type TDbCas, type TDbFieldOp, type TDbPatch, ValidationContext, ValidatorMode, buildDbValidator, buildPatchPartial, buildValidationContext, createDbValidatorPlugin, dbPlugin, forceNavNonOptional, getKeyProps, isDbFieldOp, isEmptyObject, isNavRelation, isPlainObject, reconcileCas, separateCas };
|
package/dist/validator.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { a as $mul, c as $update, d as TDbFieldOp, g as separateCas, h as reconcileCas, i as $insert, l as $upsert, m as isDbFieldOp, n as $dec, o as $remove, r as $inc, s as $replace, t as $cas, u as TDbCas } from "./ops-AqhV7s9o.mjs";
|
|
2
2
|
import { a as isPlainObject, i as isEmptyObject } from "./object-CtPYTIvy.mjs";
|
|
3
|
-
import { a as buildValidationContext, c as isNavRelation, d as getKeyProps, i as buildPatchPartial, l as TArrayPatch, m as DbError, n as ValidatorMode, o as dbPlugin, r as buildDbValidator, s as forceNavNonOptional, t as ValidationContext, u as TDbPatch } from "./validator-
|
|
3
|
+
import { a as buildValidationContext, c as isNavRelation, d as getKeyProps, i as buildPatchPartial, l as TArrayPatch, m as DbError, n as ValidatorMode, o as dbPlugin, r as buildDbValidator, s as forceNavNonOptional, t as ValidationContext, u as TDbPatch } from "./validator-CMnTI6r7.mjs";
|
|
4
4
|
import { n as createDbValidatorPlugin, t as DbValidationContext } from "./db-validator-plugin-BWy60OvG.mjs";
|
|
5
5
|
export { $cas, $dec, $inc, $insert, $mul, $remove, $replace, $update, $upsert, DbError, type DbValidationContext, type TArrayPatch, type TDbCas, type TDbFieldOp, type TDbPatch, ValidationContext, ValidatorMode, buildDbValidator, buildPatchPartial, buildValidationContext, createDbValidatorPlugin, dbPlugin, forceNavNonOptional, getKeyProps, isDbFieldOp, isEmptyObject, isNavRelation, isPlainObject, reconcileCas, separateCas };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atscript/db",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.147",
|
|
4
4
|
"description": "Database adapter utilities for atscript.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"atscript",
|
|
@@ -71,15 +71,15 @@
|
|
|
71
71
|
"access": "public"
|
|
72
72
|
},
|
|
73
73
|
"devDependencies": {
|
|
74
|
-
"@atscript/core": "^0.1.
|
|
75
|
-
"@atscript/typescript": "^0.1.
|
|
76
|
-
"@uniqu/core": "^0.1.
|
|
77
|
-
"unplugin-atscript": "^0.1.
|
|
74
|
+
"@atscript/core": "^0.1.99",
|
|
75
|
+
"@atscript/typescript": "^0.1.99",
|
|
76
|
+
"@uniqu/core": "^0.1.12",
|
|
77
|
+
"unplugin-atscript": "^0.1.99"
|
|
78
78
|
},
|
|
79
79
|
"peerDependencies": {
|
|
80
|
-
"@atscript/core": "^0.1.
|
|
81
|
-
"@atscript/typescript": "^0.1.
|
|
82
|
-
"@uniqu/core": "^0.1.
|
|
80
|
+
"@atscript/core": "^0.1.99",
|
|
81
|
+
"@atscript/typescript": "^0.1.99",
|
|
82
|
+
"@uniqu/core": "^0.1.12"
|
|
83
83
|
},
|
|
84
84
|
"scripts": {
|
|
85
85
|
"postinstall": "asc -f dts",
|