@prisma/orm-family-sql 8.0.0-rc.24-dev.3 → 8.0.0-rc.24-dev.5
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/{config-types-DUvOG4yN.mjs → config-types-Bmuh-iqF.mjs} +2 -2
- package/dist/{config-types-DUvOG4yN.mjs.map → config-types-Bmuh-iqF.mjs.map} +1 -1
- package/dist/{contract-builder-Drywaj7K.mjs → contract-builder-DOhpzXZo.mjs} +2 -2
- package/dist/{contract-builder-Drywaj7K.mjs.map → contract-builder-DOhpzXZo.mjs.map} +1 -1
- package/dist/contract-prisma7__provider.mjs +4 -4
- package/dist/contract-psl.mjs +1 -1
- package/dist/contract-psl__attribute-specs.mjs +1 -1
- package/dist/contract-psl__provider.mjs +2 -2
- package/dist/contract-ts.mjs +3 -3
- package/dist/contract-ts__config-types.mjs +1 -1
- package/dist/contract-ts__contract-builder.mjs +2 -2
- package/dist/{control-BJWi318s.mjs → control-DH4OytZW.mjs} +3 -3
- package/dist/{control-BJWi318s.mjs.map → control-DH4OytZW.mjs.map} +1 -1
- package/dist/{derived-checks-zjkmqsa_-BZv7VzY0.mjs → derived-checks-Ci2yrIFf-CgDwDFhv.mjs} +29 -8
- package/dist/derived-checks-Ci2yrIFf-CgDwDFhv.mjs.map +1 -0
- package/dist/family.mjs +2 -2
- package/dist/family__control.mjs +1 -1
- package/dist/family__pack.mjs +2 -2
- package/dist/{generator-functions-Hy4pDDr9-CAx4Z7af.mjs → generator-functions-Hy4pDDr9-CcbbtMHT.mjs} +2 -2
- package/dist/{generator-functions-Hy4pDDr9-CAx4Z7af.mjs.map → generator-functions-Hy4pDDr9-CcbbtMHT.mjs.map} +1 -1
- package/dist/{interpreter-CVd521dx-PDiCxDLC.mjs → interpreter-CVd521dx-CbU4vaiW.mjs} +4 -4
- package/dist/{interpreter-CVd521dx-PDiCxDLC.mjs.map → interpreter-CVd521dx-CbU4vaiW.mjs.map} +1 -1
- package/dist/{psl-field-resolution-GN4iup8d-BSjTCYks.mjs → psl-field-resolution-GN4iup8d-BnaMdmB1.mjs} +2 -2
- package/dist/{psl-field-resolution-GN4iup8d-BSjTCYks.mjs.map → psl-field-resolution-GN4iup8d-BnaMdmB1.mjs.map} +1 -1
- package/package.json +18 -18
- package/dist/derived-checks-zjkmqsa_-BZv7VzY0.mjs.map +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { n as buildSqlContractFromDefinition, r as contractError, t as applySqlSpecifierControlPolicy } from "./derived-checks-
|
|
1
|
+
import { n as buildSqlContractFromDefinition, r as contractError, t as applySqlSpecifierControlPolicy } from "./derived-checks-Ci2yrIFf-CgDwDFhv.mjs";
|
|
2
2
|
import { ifDefined } from "@prisma/orm-framework/utils/defined";
|
|
3
3
|
import { createDataTypeLookup, emptyCodecLookup } from "@prisma/orm-framework/components/codec";
|
|
4
4
|
import { InternalError } from "@prisma/orm-framework/utils/internal-error";
|
|
@@ -65,4 +65,4 @@ function typescriptContractFromPath(contractPath, output, options) {
|
|
|
65
65
|
//#endregion
|
|
66
66
|
export { typescriptContract as n, typescriptContractFromPath as r, emptyContract as t };
|
|
67
67
|
|
|
68
|
-
//# sourceMappingURL=config-types-
|
|
68
|
+
//# sourceMappingURL=config-types-Bmuh-iqF.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config-types-
|
|
1
|
+
{"version":3,"file":"config-types-Bmuh-iqF.mjs","names":[],"sources":["../../../../2-sql-family/2-authoring/contract-ts/dist/config-types.mjs"],"sourcesContent":["import { n as buildSqlContractFromDefinition, s as contractError, t as applySqlSpecifierControlPolicy } from \"./derived-checks-Ci2yrIFf.mjs\";\nimport { createDataTypeLookup, emptyCodecLookup } from \"@internal/framework-components/codec\";\nimport { ifDefined } from \"@internal/utils/defined\";\nimport { InternalError } from \"@internal/utils/internal-error\";\nimport { pathToFileURL } from \"node:url\";\nimport { ok } from \"@internal/utils/result\";\nimport { extname } from \"pathe\";\n//#region src/config-types.ts\n/**\n* Derives the emit output path from the TS contract input so artefacts land\n* colocated with the source (e.g. `prisma/contract.ts` →\n* `prisma/contract.json`). Mirrors the same default-derivation logic in\n* `@internal/sql-contract-psl/provider`.\n*/\nfunction defaultOutputFromContractPath(contractPath) {\n\tconst ext = extname(contractPath);\n\tif (ext.length === 0) return `${contractPath}.json`;\n\treturn `${contractPath.slice(0, -ext.length)}.json`;\n}\nfunction emptyContract(options) {\n\treturn {\n\t\tsource: {\n\t\t\tformat: \"typescript\",\n\t\t\tload: async () => {\n\t\t\t\treturn ok(applySqlSpecifierControlPolicy(buildSqlContractFromDefinition({\n\t\t\t\t\twarnings: void 0,\n\t\t\t\t\ttarget: options.target,\n\t\t\t\t\tcreateNamespace: options.createNamespace,\n\t\t\t\t\tmodels: []\n\t\t\t\t}, {\n\t\t\t\t\t...emptyCodecLookup,\n\t\t\t\t\tdescriptorFor: () => void 0\n\t\t\t\t}, createDataTypeLookup([])), options.defaultControlPolicy, options.createNamespace));\n\t\t\t}\n\t\t},\n\t\t...ifDefined(\"output\", options.output)\n\t};\n}\nfunction typescriptContract(contract, output, options) {\n\treturn {\n\t\tsource: {\n\t\t\tformat: \"typescript\",\n\t\t\tload: async () => ok(options === void 0 ? contract : applySqlSpecifierControlPolicy(contract, options.defaultControlPolicy, options.createNamespace))\n\t\t},\n\t\t...ifDefined(\"output\", output)\n\t};\n}\nfunction typescriptContractFromPath(contractPath, output, options) {\n\treturn {\n\t\tsource: {\n\t\t\tformat: \"typescript\",\n\t\t\tinputs: [contractPath],\n\t\t\tload: async (context) => {\n\t\t\t\tconst [absolutePath] = context.resolvedInputs;\n\t\t\t\tif (absolutePath === void 0) throw new InternalError(\"typescriptContractFromPath: context.resolvedInputs is empty. The CLI config loader should populate it from source.inputs.\");\n\t\t\t\tconst mod = await import(pathToFileURL(absolutePath).href);\n\t\t\t\tconst contract = mod.default ?? mod.contract;\n\t\t\t\tif (contract === void 0) throw contractError(\"CONTRACT.MODULE_EXPORT_MISSING\", `typescriptContractFromPath: module at \"${absolutePath}\" has no \"default\" or \"contract\" export.`, { meta: { path: absolutePath } });\n\t\t\t\treturn ok(options === void 0 ? contract : applySqlSpecifierControlPolicy(contract, options.defaultControlPolicy, options.createNamespace));\n\t\t\t}\n\t\t},\n\t\toutput: output ?? defaultOutputFromContractPath(contractPath)\n\t};\n}\n//#endregion\nexport { emptyContract, typescriptContract, typescriptContractFromPath };\n\n//# sourceMappingURL=config-types.mjs.map"],"mappings":";;;;;;;;;;;;;;AAcA,SAAS,8BAA8B,cAAc;CACpD,MAAM,MAAM,QAAQ,YAAY;CAChC,IAAI,IAAI,WAAW,GAAG,OAAO,GAAG,aAAa;CAC7C,OAAO,GAAG,aAAa,MAAM,GAAG,CAAC,IAAI,MAAM,EAAE;AAC9C;AACA,SAAS,cAAc,SAAS;CAC/B,OAAO;EACN,QAAQ;GACP,QAAQ;GACR,MAAM,YAAY;IACjB,OAAO,GAAG,+BAA+B,+BAA+B;KACvE,UAAU,KAAK;KACf,QAAQ,QAAQ;KAChB,iBAAiB,QAAQ;KACzB,QAAQ,CAAC;IACV,GAAG;KACF,GAAG;KACH,qBAAqB,KAAK;IAC3B,GAAG,qBAAqB,CAAC,CAAC,CAAC,GAAG,QAAQ,sBAAsB,QAAQ,eAAe,CAAC;GACrF;EACD;EACA,GAAG,UAAU,UAAU,QAAQ,MAAM;CACtC;AACD;AACA,SAAS,mBAAmB,UAAU,QAAQ,SAAS;CACtD,OAAO;EACN,QAAQ;GACP,QAAQ;GACR,MAAM,YAAY,GAAG,YAAY,KAAK,IAAI,WAAW,+BAA+B,UAAU,QAAQ,sBAAsB,QAAQ,eAAe,CAAC;EACrJ;EACA,GAAG,UAAU,UAAU,MAAM;CAC9B;AACD;AACA,SAAS,2BAA2B,cAAc,QAAQ,SAAS;CAClE,OAAO;EACN,QAAQ;GACP,QAAQ;GACR,QAAQ,CAAC,YAAY;GACrB,MAAM,OAAO,YAAY;IACxB,MAAM,CAAC,gBAAgB,QAAQ;IAC/B,IAAI,iBAAiB,KAAK,GAAG,MAAM,IAAI,cAAc,2HAA2H;IAChL,MAAM,MAAM,MAAM,OAAO,cAAc,YAAY,CAAC,CAAC;IACrD,MAAM,WAAW,IAAI,WAAW,IAAI;IACpC,IAAI,aAAa,KAAK,GAAG,MAAM,cAAc,kCAAkC,0CAA0C,aAAa,2CAA2C,EAAE,MAAM,EAAE,MAAM,aAAa,EAAE,CAAC;IACjN,OAAO,GAAG,YAAY,KAAK,IAAI,WAAW,+BAA+B,UAAU,QAAQ,sBAAsB,QAAQ,eAAe,CAAC;GAC1I;EACD;EACA,QAAQ,UAAU,8BAA8B,YAAY;CAC7D;AACD"}
|
|
@@ -4,7 +4,7 @@ import { n as generatedIdColumnAliases, t as GENERATED_ID_COLUMN_ALIAS_NAMESPACE
|
|
|
4
4
|
import { a as isSqlExpression, c as requireSqlExpression, r as SqlExpression, s as readSqlExpression } from "./sql-expression-CKgKznXS.mjs";
|
|
5
5
|
import { t as CODEC_INSTANCE_KIND } from "./types-CISwoRED.mjs";
|
|
6
6
|
import { n as checkSqlDefaultText, o as reservedSqlDefaultText } from "./validators-CWcdf_jZ.mjs";
|
|
7
|
-
import { a as refuseTypesKey, n as buildSqlContractFromDefinition, r as contractError, s as toOneNullabilityContradictionMessage } from "./derived-checks-
|
|
7
|
+
import { a as refuseTypesKey, n as buildSqlContractFromDefinition, r as contractError, s as toOneNullabilityContradictionMessage } from "./derived-checks-Ci2yrIFf-CgDwDFhv.mjs";
|
|
8
8
|
import { isStructuredError } from "@prisma/orm-framework/utils/structured-error";
|
|
9
9
|
import { ifDefined } from "@prisma/orm-framework/utils/defined";
|
|
10
10
|
import { assembleDataTypeSupport, assertNoCrossRegistryCollisions, assertTypeAliasesValid, assertTypeChoicesValid, describeAdmittedForms, instantiateAuthoringTypeAlias, instantiateAuthoringTypeCall, instantiateAuthoringTypeConstructor, isAuthoringEntityTypeDescriptor, isAuthoringTypeAliasDescriptor, isAuthoringTypeChoiceDescriptor, isAuthoringTypeConstructorDescriptor, isAuthoringTypeDescriptor, readWrittenValueAs, resolveAuthoringTypeChoice, typeChoiceArgumentsFromObject, typeConstructorLookup, validateAuthoringHelperArguments, validateAuthoringTypeChoiceParams, validateAuthoringTypeParams } from "@prisma/orm-framework/components/authoring";
|
|
@@ -1947,4 +1947,4 @@ const unbound = Symbol.for("prisma.namespace.unbound");
|
|
|
1947
1947
|
//#endregion
|
|
1948
1948
|
export { check as a, defineContract as c, field as d, member as f, unbound as g, rel as h, buildContractDefinition as i, enumType as l, now as m, bindEnumType as n, composedExtensionPackRefs as o, model as p, buildBoundContract as r, createComposedAuthoringHelpers as s, autoincrement as t, extensionModel as u };
|
|
1949
1949
|
|
|
1950
|
-
//# sourceMappingURL=contract-builder-
|
|
1950
|
+
//# sourceMappingURL=contract-builder-DOhpzXZo.mjs.map
|