@prisma/client-generator-js 7.3.0-integration-prisma6-fix-cloudflare-engine.3 → 7.3.0-integration-engines-7-3-0-10-fix-fix-mapped-enum-issue-0b7e6564db7dc3dac7f9312aa84e9ed81d805521.1

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.
Files changed (33) hide show
  1. package/dist/TSClient/Args.d.ts +5 -5
  2. package/dist/TSClient/GenerateContext.d.ts +5 -2
  3. package/dist/TSClient/PrismaClient.d.ts +2 -2
  4. package/dist/TSClient/TSClient.d.ts +2 -7
  5. package/dist/TSClient/common.d.ts +2 -2
  6. package/dist/generateClient.d.ts +2 -7
  7. package/dist/generator.d.ts +1 -1
  8. package/dist/index.d.mts +2 -7
  9. package/dist/index.d.ts +2 -7
  10. package/dist/index.js +373 -2976
  11. package/dist/index.mjs +359 -2968
  12. package/dist/resolvePrismaClient.d.ts +0 -5
  13. package/dist/typedSql/buildIndex.d.ts +2 -2
  14. package/dist/typedSql/typedSql.d.ts +1 -1
  15. package/dist/utils/buildDMMF.d.ts +1 -1
  16. package/dist/utils/buildDebugInitialization.d.ts +1 -1
  17. package/dist/utils/buildGetQueryCompilerWasmModule.d.ts +1 -1
  18. package/dist/utils/runtimeImport.d.ts +1 -8
  19. package/package.json +10 -11
  20. package/dist/TSClient/Datasources.d.ts +0 -7
  21. package/dist/extractSqliteSources.d.ts +0 -6
  22. package/dist/extractSqliteSources.test.d.ts +0 -1
  23. package/dist/resolveDatasources.d.ts +0 -1
  24. package/dist/resolveDatasources.test.d.ts +0 -1
  25. package/dist/serializeDatasources.d.ts +0 -4
  26. package/dist/serializeDatasources.test.d.ts +0 -1
  27. package/dist/utils/buildDirname.d.ts +0 -7
  28. package/dist/utils/buildGetQueryEngineWasmModule.d.ts +0 -6
  29. package/dist/utils/buildInjectableEdgeEnv.d.ts +0 -20
  30. package/dist/utils/buildInlineDatasources.d.ts +0 -3
  31. package/dist/utils/buildNFTAnnotations.d.ts +0 -11
  32. package/dist/utils/buildNFTAnnotations.test.d.ts +0 -1
  33. package/dist/utils/buildWarnEnvConflicts.d.ts +0 -10
@@ -9,8 +9,3 @@ export declare const debug: ((...args: any[]) => void) & {
9
9
  * Resolves the path to the Prisma Client to determine the default output directory.
10
10
  */
11
11
  export declare function resolvePrismaClient(baseDir: string): Promise<string>;
12
- /**
13
- * Resolves the path to the Prisma Client to determine the default output directory.
14
- * Installs the Prisma Client if it is not found.
15
- */
16
- export declare function resolveOrInstallPrismaClient(baseDir: string, version: string): Promise<string>;
@@ -1,5 +1,5 @@
1
1
  import { SqlQueryOutput } from '@prisma/generator';
2
2
  import { DbEnumsList } from './buildDbEnums';
3
3
  export declare function buildIndexTs(queries: SqlQueryOutput[], enums: DbEnumsList): string;
4
- export declare function buildIndexCjs(queries: SqlQueryOutput[], edgeRuntimeSuffix?: 'wasm-engine-edge' | 'wasm-compiler-edge' | 'edge' | undefined): string;
5
- export declare function buildIndexEsm(queries: SqlQueryOutput[], edgeRuntimeSuffix?: 'wasm-engine-edge' | 'wasm-compiler-edge' | 'edge' | undefined): string;
4
+ export declare function buildIndexCjs(queries: SqlQueryOutput[], edgeRuntimeSuffix?: 'wasm-compiler-edge' | undefined): string;
5
+ export declare function buildIndexEsm(queries: SqlQueryOutput[], edgeRuntimeSuffix?: 'wasm-compiler-edge' | undefined): string;
@@ -4,7 +4,7 @@ import { FileMap } from '../generateClient';
4
4
  type TypeSqlBuildOptions = {
5
5
  runtimeBase: string;
6
6
  mainRuntimeName: string;
7
- edgeRuntimeName: 'wasm-engine-edge' | 'wasm-compiler-edge' | 'edge';
7
+ edgeRuntimeName: 'wasm-compiler-edge';
8
8
  dmmf: DMMF.Document;
9
9
  queries: SqlQueryOutput[];
10
10
  };
@@ -13,4 +13,4 @@ import { TSClientOptions } from '../TSClient/TSClient';
13
13
  * @param datamodel
14
14
  * @returns
15
15
  */
16
- export declare function buildRuntimeDataModel(datamodel: DMMF.Datamodel, runtimeNameJs: TSClientOptions['runtimeNameJs']): string;
16
+ export declare function buildRuntimeDataModel(datamodel: DMMF.Datamodel, runtimeName: TSClientOptions['runtimeName']): string;
@@ -9,4 +9,4 @@
9
9
  *
10
10
  * @param edge Whether the edge runtime is used
11
11
  */
12
- export declare function buildDebugInitialization(edge: boolean): string;
12
+ export declare function buildDebugInitialization(edge: boolean): "" | "if (typeof globalThis !== 'undefined' && globalThis['DEBUG'] || (typeof process !== 'undefined' && process.env && process.env.DEBUG) || undefined) {\n Debug.enable(typeof globalThis !== 'undefined' && globalThis['DEBUG'] || (typeof process !== 'undefined' && process.env && process.env.DEBUG) || undefined)\n}\n";
@@ -3,4 +3,4 @@ import { TSClientOptions } from '../TSClient/TSClient';
3
3
  * Builds the necessary glue code to load the query compiler wasm module.
4
4
  * @returns
5
5
  */
6
- export declare function buildQueryCompilerWasmModule(forceEdgeWasmLoader: boolean, runtimeNameJs: TSClientOptions['runtimeNameJs']): "config.compilerWasm = {\n getRuntime: async () => require('./query_compiler_bg.js'),\n getQueryCompilerWasmModule: async () => {\n const queryCompilerWasmFilePath = require('path').join(config.dirname, 'query_compiler_bg.wasm')\n const queryCompilerWasmFileBytes = require('fs').readFileSync(queryCompilerWasmFilePath)\n\n return new WebAssembly.Module(queryCompilerWasmFileBytes)\n }\n }" | "config.compilerWasm = {\n getRuntime: async () => require('./query_compiler_bg.js'),\n getQueryCompilerWasmModule: async () => {\n const loader = (await import('#wasm-compiler-loader')).default\n const compiler = (await loader).default\n return compiler\n }\n}" | "config.compilerWasm = undefined";
6
+ export declare function buildQueryCompilerWasmModule(forceEdgeWasmLoader: boolean, runtimeName: TSClientOptions['runtimeName'], compilerBuild: TSClientOptions['compilerBuild']): string;
@@ -1,11 +1,4 @@
1
1
  import * as ts from '@prisma/ts-builders';
2
- type RuntimeExport = keyof typeof import('@prisma/client/runtime/library') & string;
3
- /**
4
- * Helps to ensure that when we want to refer to a type or value, imported from runtime Module
5
- * we are referring to the name, that is actually exported
6
- *
7
- * @param name imported name
8
- */
9
- export declare function runtimeImport(name: RuntimeExport): string;
2
+ type RuntimeExport = keyof typeof import('@prisma/client/runtime/client') & string;
10
3
  export declare function runtimeImportedType(name: RuntimeExport): ts.NamedType;
11
4
  export {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@prisma/client-generator-js",
3
- "version": "7.3.0-integration-prisma6-fix-cloudflare-engine.3",
3
+ "version": "7.3.0-integration-engines-7-3-0-10-fix-fix-mapped-enum-issue-0b7e6564db7dc3dac7f9312aa84e9ed81d805521.1",
4
4
  "description": "This package is intended for Prisma's internal use",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",
@@ -25,22 +25,21 @@
25
25
  "license": "Apache-2.0",
26
26
  "dependencies": {
27
27
  "@antfu/ni": "0.21.12",
28
- "@prisma/engines-version": "7.1.1-3.c2990dca591cba766e3b7ef5d9e8a84796e47ab7",
29
- "ci-info": "4.2.0",
28
+ "@prisma/engines-version": "7.3.0-10.fix-fix-mapped-enum-issue-0b7e6564db7dc3dac7f9312aa84e9ed81d805521",
30
29
  "env-paths": "2.2.1",
31
30
  "indent-string": "4.0.0",
32
31
  "klona": "2.0.6",
33
32
  "package-up": "5.0.0",
34
33
  "pluralize": "8.0.0",
35
34
  "ts-pattern": "5.6.2",
36
- "@prisma/client-common": "7.3.0-integration-prisma6-fix-cloudflare-engine.3",
37
- "@prisma/dmmf": "7.3.0-integration-prisma6-fix-cloudflare-engine.3",
38
- "@prisma/generator": "7.3.0-integration-prisma6-fix-cloudflare-engine.3",
39
- "@prisma/get-platform": "7.3.0-integration-prisma6-fix-cloudflare-engine.3",
40
- "@prisma/debug": "7.3.0-integration-prisma6-fix-cloudflare-engine.3",
41
- "@prisma/fetch-engine": "7.3.0-integration-prisma6-fix-cloudflare-engine.3",
42
- "@prisma/internals": "7.3.0-integration-prisma6-fix-cloudflare-engine.3",
43
- "@prisma/ts-builders": "7.3.0-integration-prisma6-fix-cloudflare-engine.3"
35
+ "@prisma/client-common": "7.3.0-integration-engines-7-3-0-10-fix-fix-mapped-enum-issue-0b7e6564db7dc3dac7f9312aa84e9ed81d805521.1",
36
+ "@prisma/dmmf": "7.3.0-integration-engines-7-3-0-10-fix-fix-mapped-enum-issue-0b7e6564db7dc3dac7f9312aa84e9ed81d805521.1",
37
+ "@prisma/debug": "7.3.0-integration-engines-7-3-0-10-fix-fix-mapped-enum-issue-0b7e6564db7dc3dac7f9312aa84e9ed81d805521.1",
38
+ "@prisma/fetch-engine": "7.3.0-integration-engines-7-3-0-10-fix-fix-mapped-enum-issue-0b7e6564db7dc3dac7f9312aa84e9ed81d805521.1",
39
+ "@prisma/generator": "7.3.0-integration-engines-7-3-0-10-fix-fix-mapped-enum-issue-0b7e6564db7dc3dac7f9312aa84e9ed81d805521.1",
40
+ "@prisma/get-platform": "7.3.0-integration-engines-7-3-0-10-fix-fix-mapped-enum-issue-0b7e6564db7dc3dac7f9312aa84e9ed81d805521.1",
41
+ "@prisma/internals": "7.3.0-integration-engines-7-3-0-10-fix-fix-mapped-enum-issue-0b7e6564db7dc3dac7f9312aa84e9ed81d805521.1",
42
+ "@prisma/ts-builders": "7.3.0-integration-engines-7-3-0-10-fix-fix-mapped-enum-issue-0b7e6564db7dc3dac7f9312aa84e9ed81d805521.1"
44
43
  },
45
44
  "devDependencies": {
46
45
  "@types/pluralize": "0.0.33",
@@ -1,7 +0,0 @@
1
- import { DataSource } from '@prisma/generator';
2
- import type { Generable } from './Generable';
3
- export declare class Datasources implements Generable {
4
- protected readonly internalDatasources: DataSource[];
5
- constructor(internalDatasources: DataSource[]);
6
- toTS(): string;
7
- }
@@ -1,6 +0,0 @@
1
- export interface DatasourceOverwrite {
2
- name: string;
3
- url?: string;
4
- env?: string;
5
- }
6
- export declare function extractSqliteSources(datamodel: string, cwd: string, outputDir: string, absolutePaths?: boolean): DatasourceOverwrite[];
@@ -1 +0,0 @@
1
- export {};
@@ -1 +0,0 @@
1
- export declare function absolutizeRelativePath(url: string, cwd: string, outputDir: string, absolutePaths?: boolean): string;
@@ -1 +0,0 @@
1
- export {};
@@ -1,4 +0,0 @@
1
- import type { DataSource } from '@prisma/generator';
2
- import type { DatasourceOverwrite } from './extractSqliteSources';
3
- export declare function serializeDatasources(datasources: DatasourceOverwrite[]): string;
4
- export declare function datasourceToDatasourceOverwrite(datasource: DataSource): DatasourceOverwrite;
@@ -1 +0,0 @@
1
- export {};
@@ -1,7 +0,0 @@
1
- /**
2
- * Builds a `dirname` variable that holds the location of the generated client.
3
- * @param edge
4
- * @param relativeOutdir
5
- * @returns
6
- */
7
- export declare function buildDirname(edge: boolean, relativeOutdir: string): string;
@@ -1,6 +0,0 @@
1
- import { TSClientOptions } from '../TSClient/TSClient';
2
- /**
3
- * Builds the necessary glue code to load the query engine wasm module.
4
- * @returns
5
- */
6
- export declare function buildQueryEngineWasmModule(wasm: boolean, copyEngine: boolean, runtimeNameJs: TSClientOptions['runtimeNameJs']): "config.engineWasm = {\n getRuntime: async () => require('./query_engine_bg.js'),\n getQueryEngineWasmModule: async () => {\n const queryEngineWasmFilePath = require('path').join(config.dirname, 'query_engine_bg.wasm')\n const queryEngineWasmFileBytes = require('fs').readFileSync(queryEngineWasmFilePath)\n\n return new WebAssembly.Module(queryEngineWasmFileBytes)\n }\n }" | "config.engineWasm = {\n getRuntime: async () => require('./query_engine_bg.js'),\n getQueryEngineWasmModule: async () => {\n const loader = (await import('#wasm-engine-loader')).default\n const engine = (await loader).default\n return engine\n }\n}" | "config.engineWasm = undefined";
@@ -1,20 +0,0 @@
1
- import { DataSource } from '@prisma/generator';
2
- /**
3
- * Builds an injectable environment for the data proxy edge client. It's useful
4
- * because it is designed to run in browser-like environments where things like
5
- * `fs`, `process.env`, and .env file loading are not available. That means env
6
- * vars are represented as a global variable or injected at build time. This is
7
- * the glue code to make this work with our existing env var loading logic. It
8
- * is the place where we make collect the env vars for the edge client. To
9
- * understand this better, take a look at the generated code in the edge client.
10
- * @see {@link declareInjectableEdgeEnv}
11
- * @param edge
12
- * @param datasources
13
- * @returns
14
- */
15
- export declare function buildInjectableEdgeEnv(edge: boolean, datasources: DataSource[]): string;
16
- /**
17
- * Builds the expression to get the value of an environment variable at run time.
18
- * @param envVarName Name of the environment variable
19
- */
20
- export declare function getRuntimeEdgeEnvVar(envVarName: string): string;
@@ -1,3 +0,0 @@
1
- import type { GetPrismaClientConfig } from '@prisma/client-common';
2
- import { DataSource } from '@prisma/generator';
3
- export declare function buildInlineDatasources(datasources: DataSource[]): GetPrismaClientConfig['inlineDatasources'];
@@ -1,11 +0,0 @@
1
- import type { BinaryTarget } from '@prisma/get-platform';
2
- import { ClientEngineType } from '@prisma/internals';
3
- /**
4
- * Build bundler-like annotations so that Vercel automatically uploads the
5
- * prisma schema as well as the query engine binaries to the deployments.
6
- * @param engineType the client engine in use
7
- * @param binaryTargets the targeted binaryTargets
8
- * @param relativeOutdir outdir relative to root
9
- * @returns
10
- */
11
- export declare function buildNFTAnnotations(noEngine: boolean, engineType: ClientEngineType, binaryTargets: BinaryTarget[] | undefined, relativeOutdir: string): string;
@@ -1 +0,0 @@
1
- export {};
@@ -1,10 +0,0 @@
1
- import { TSClientOptions } from '../TSClient/TSClient';
2
- /**
3
- * Builds the necessary bits so that our users can get a helpful warning during
4
- * "generate" in case of conflicts between their environment & their env files.
5
- * @param edge
6
- * @param runtimeBase
7
- * @param runtimeNameJs
8
- * @returns
9
- */
10
- export declare function buildWarnEnvConflicts(edge: boolean, runtimeBase: string, runtimeNameJs: TSClientOptions['runtimeNameJs']): string;