@prisma-next/sql-schema-ir 0.5.0-dev.9 → 0.5.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.
@@ -1 +1 @@
1
- {"version":3,"file":"naming.d.mts","names":[],"sources":["../../src/exports/naming.ts"],"sourcesContent":[],"mappings":";iBAAgB,gBAAA"}
1
+ {"version":3,"file":"naming.d.mts","names":[],"sources":["../../src/exports/naming.ts"],"mappings":";iBAAgB,gBAAA,CAAiB,SAAA,UAAmB,OAAA"}
@@ -2,7 +2,7 @@
2
2
  function defaultIndexName(tableName, columns) {
3
3
  return `${tableName}_${columns.join("_")}_idx`;
4
4
  }
5
-
6
5
  //#endregion
7
6
  export { defaultIndexName };
7
+
8
8
  //# sourceMappingURL=naming.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"naming.mjs","names":[],"sources":["../../src/exports/naming.ts"],"sourcesContent":["export function defaultIndexName(tableName: string, columns: readonly string[]): string {\n return `${tableName}_${columns.join('_')}_idx`;\n}\n"],"mappings":";AAAA,SAAgB,iBAAiB,WAAmB,SAAoC;AACtF,QAAO,GAAG,UAAU,GAAG,QAAQ,KAAK,IAAI,CAAC"}
1
+ {"version":3,"file":"naming.mjs","names":[],"sources":["../../src/exports/naming.ts"],"sourcesContent":["export function defaultIndexName(tableName: string, columns: readonly string[]): string {\n return `${tableName}_${columns.join('_')}_idx`;\n}\n"],"mappings":";AAAA,SAAgB,iBAAiB,WAAmB,SAAoC;CACtF,OAAO,GAAG,UAAU,GAAG,QAAQ,KAAK,IAAI,CAAC"}
@@ -1,2 +1,2 @@
1
- import { a as SqlForeignKeyIR, c as SqlSchemaIR, d as SqlTypeMetadataRegistry, f as SqlUniqueIR, i as SqlColumnIR, l as SqlTableIR, n as PrimaryKey, o as SqlIndexIR, r as SqlAnnotations, s as SqlReferentialAction, t as DependencyIR, u as SqlTypeMetadata } from "../types-BmyESSa6.mjs";
2
- export { DependencyIR, PrimaryKey, SqlAnnotations, SqlColumnIR, SqlForeignKeyIR, SqlIndexIR, SqlReferentialAction, SqlSchemaIR, SqlTableIR, SqlTypeMetadata, SqlTypeMetadataRegistry, SqlUniqueIR };
1
+ import { a as SqlIndexIR, c as SqlTableIR, d as SqlUniqueIR, i as SqlForeignKeyIR, l as SqlTypeMetadata, n as SqlAnnotations, o as SqlReferentialAction, r as SqlColumnIR, s as SqlSchemaIR, t as PrimaryKey, u as SqlTypeMetadataRegistry } from "../types-BNW257Ug.mjs";
2
+ export { PrimaryKey, SqlAnnotations, SqlColumnIR, SqlForeignKeyIR, SqlIndexIR, SqlReferentialAction, SqlSchemaIR, SqlTableIR, SqlTypeMetadata, SqlTypeMetadataRegistry, SqlUniqueIR };
@@ -1 +1 @@
1
- export { };
1
+ export {};
package/dist/index.d.mts CHANGED
@@ -1,2 +1,2 @@
1
- import { a as SqlForeignKeyIR, c as SqlSchemaIR, d as SqlTypeMetadataRegistry, f as SqlUniqueIR, i as SqlColumnIR, l as SqlTableIR, n as PrimaryKey, o as SqlIndexIR, r as SqlAnnotations, s as SqlReferentialAction, t as DependencyIR, u as SqlTypeMetadata } from "./types-BmyESSa6.mjs";
2
- export { DependencyIR, PrimaryKey, SqlAnnotations, SqlColumnIR, SqlForeignKeyIR, SqlIndexIR, SqlReferentialAction, SqlSchemaIR, SqlTableIR, SqlTypeMetadata, SqlTypeMetadataRegistry, SqlUniqueIR };
1
+ import { a as SqlIndexIR, c as SqlTableIR, d as SqlUniqueIR, i as SqlForeignKeyIR, l as SqlTypeMetadata, n as SqlAnnotations, o as SqlReferentialAction, r as SqlColumnIR, s as SqlSchemaIR, t as PrimaryKey, u as SqlTypeMetadataRegistry } from "./types-BNW257Ug.mjs";
2
+ export { PrimaryKey, SqlAnnotations, SqlColumnIR, SqlForeignKeyIR, SqlIndexIR, SqlReferentialAction, SqlSchemaIR, SqlTableIR, SqlTypeMetadata, SqlTypeMetadataRegistry, SqlUniqueIR };
package/dist/index.mjs CHANGED
@@ -1,3 +1,2 @@
1
1
  import "./exports/types.mjs";
2
-
3
- export { };
2
+ export {};
@@ -62,6 +62,8 @@ type SqlIndexIR = {
62
62
  readonly columns: readonly string[];
63
63
  readonly name?: string;
64
64
  readonly unique: boolean;
65
+ readonly type?: string;
66
+ readonly options?: Record<string, unknown>;
65
67
  readonly annotations?: SqlAnnotations;
66
68
  };
67
69
  /**
@@ -77,9 +79,6 @@ type SqlTableIR = {
77
79
  readonly indexes: readonly SqlIndexIR[];
78
80
  readonly annotations?: SqlAnnotations;
79
81
  };
80
- type DependencyIR = {
81
- readonly id: string;
82
- };
83
82
  /**
84
83
  * SQL Schema IR representing the complete database schema.
85
84
  * This is the target-agnostic representation used for verification and migration planning.
@@ -87,7 +86,6 @@ type DependencyIR = {
87
86
  type SqlSchemaIR = {
88
87
  readonly tables: Record<string, SqlTableIR>;
89
88
  readonly annotations?: SqlAnnotations;
90
- readonly dependencies: readonly DependencyIR[];
91
89
  };
92
90
  /**
93
91
  * SQL type metadata for control-plane and execution-plane type availability and mapping.
@@ -122,5 +120,5 @@ interface SqlTypeMetadataRegistry {
122
120
  values(): IterableIterator<SqlTypeMetadata>;
123
121
  }
124
122
  //#endregion
125
- export { SqlForeignKeyIR as a, SqlSchemaIR as c, SqlTypeMetadataRegistry as d, SqlUniqueIR as f, SqlColumnIR as i, SqlTableIR as l, PrimaryKey as n, SqlIndexIR as o, SqlAnnotations as r, SqlReferentialAction as s, DependencyIR as t, SqlTypeMetadata as u };
126
- //# sourceMappingURL=types-BmyESSa6.d.mts.map
123
+ export { SqlIndexIR as a, SqlTableIR as c, SqlUniqueIR as d, SqlForeignKeyIR as i, SqlTypeMetadata as l, SqlAnnotations as n, SqlReferentialAction as o, SqlColumnIR as r, SqlSchemaIR as s, PrimaryKey as t, SqlTypeMetadataRegistry as u };
124
+ //# sourceMappingURL=types-BNW257Ug.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types-BNW257Ug.d.mts","names":[],"sources":["../src/types.ts"],"mappings":";;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@@ -1,19 +1,20 @@
1
1
  {
2
2
  "name": "@prisma-next/sql-schema-ir",
3
- "version": "0.5.0-dev.9",
3
+ "version": "0.5.1",
4
+ "license": "Apache-2.0",
4
5
  "type": "module",
5
6
  "sideEffects": false,
6
7
  "description": "SQL Schema IR types for schema introspection and verification",
7
8
  "dependencies": {
8
- "@prisma-next/contract": "0.5.0-dev.9"
9
+ "@prisma-next/contract": "0.5.1"
9
10
  },
10
11
  "devDependencies": {
11
- "tsdown": "0.18.4",
12
+ "tsdown": "0.22.0",
12
13
  "typescript": "5.9.3",
13
- "vitest": "4.0.17",
14
+ "vitest": "4.1.5",
14
15
  "@prisma-next/test-utils": "0.0.1",
15
- "@prisma-next/tsdown": "0.0.0",
16
- "@prisma-next/tsconfig": "0.0.0"
16
+ "@prisma-next/tsconfig": "0.0.0",
17
+ "@prisma-next/tsdown": "0.0.0"
17
18
  },
18
19
  "files": [
19
20
  "dist",
@@ -1,5 +1,4 @@
1
1
  export type {
2
- DependencyIR,
3
2
  PrimaryKey,
4
3
  SqlAnnotations,
5
4
  SqlColumnIR,
package/src/types.ts CHANGED
@@ -68,6 +68,8 @@ export type SqlIndexIR = {
68
68
  readonly columns: readonly string[];
69
69
  readonly name?: string;
70
70
  readonly unique: boolean;
71
+ readonly type?: string;
72
+ readonly options?: Record<string, unknown>;
71
73
  readonly annotations?: SqlAnnotations;
72
74
  };
73
75
 
@@ -85,10 +87,6 @@ export type SqlTableIR = {
85
87
  readonly annotations?: SqlAnnotations; // table-level metadata
86
88
  };
87
89
 
88
- export type DependencyIR = {
89
- readonly id: string;
90
- };
91
-
92
90
  /**
93
91
  * SQL Schema IR representing the complete database schema.
94
92
  * This is the target-agnostic representation used for verification and migration planning.
@@ -96,7 +94,6 @@ export type DependencyIR = {
96
94
  export type SqlSchemaIR = {
97
95
  readonly tables: Record<string, SqlTableIR>;
98
96
  readonly annotations?: SqlAnnotations; // extensible global metadata
99
- readonly dependencies: readonly DependencyIR[];
100
97
  };
101
98
 
102
99
  /**
@@ -1 +0,0 @@
1
- {"version":3,"file":"types-BmyESSa6.d.mts","names":[],"sources":["../src/types.ts"],"sourcesContent":[],"mappings":";;AAWA;AASA;AAOA;AAYA;AAKA;;;;;AAaY,KA9CA,UAAA,GA8CW;EASX,SAAA,OAAU,EAAA,SAIG,MAAA,EAAA;EAOb,SAAA,IAAU,CAAA,EAAA,MAAA;CAEa;;;;;AAIN,KA/DjB,cAAA,GA+DiB;EACJ,UAAA,SAAA,EAAA,MAAA,CAAA,EAAA,OAAA;CAAc;AAGvC;AAQA;;AACmB,KArEP,WAAA,GAqEO;EACM,SAAA,IAAA,EAAA,MAAA;EACS,SAAA,UAAA,EAAA,MAAA;EAAY,SAAA,QAAA,EAAA,OAAA;EAO7B,SAAA,OAAA,CAAA,EAAe,MAAA;EAyBf,SAAA,WAAA,CAAA,EAlGQ,cAkGe;;;;;;KA3F5B,oBAAA;;;;KAKA,eAAA;;;;;sBAKU;sBACA;yBACG;;;;;KAMb,WAAA;;;yBAGa;;;;;KAMb,UAAA;;;;yBAIa;;;;;;KAOb,UAAA;;oBAEQ,eAAe;wBACX;iCACS;6BACJ;6BACA;yBACJ;;KAGb,YAAA;;;;;;;KAQA,WAAA;mBACO,eAAe;yBACT;kCACS;;;;;;UAOjB,eAAA;;;;;;;;;;;;;;;;;;;;;;UAyBA,uBAAA;;;;YAIL,iBAAiB"}