@dbml/parse 10.0.0-optional-ref.0 → 10.0.0

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 (51) hide show
  1. package/dist/dbml-parse.js +29 -19
  2. package/dist/dbml-parse.mjs +5951 -4730
  3. package/dist/src/compiler/index.d.ts +11 -7
  4. package/dist/src/compiler/queries/transform/index.d.ts +3 -1
  5. package/dist/src/compiler/queries/transform/renameTable.d.ts +2 -2
  6. package/dist/src/compiler/queries/transform/syncDep.d.ts +54 -0
  7. package/dist/src/compiler/queries/transform/types.d.ts +48 -0
  8. package/dist/src/compiler/queries/transform/updateElementSetting.d.ts +6 -0
  9. package/dist/src/compiler/queries/transform/utils/index.d.ts +26 -0
  10. package/dist/src/compiler/queries/transform/utils/ref.d.ts +15 -0
  11. package/dist/src/compiler/queries/utils.d.ts +6 -0
  12. package/dist/src/compiler/types.d.ts +9 -7
  13. package/dist/src/core/global_modules/dep/bind.d.ts +18 -0
  14. package/dist/src/core/global_modules/dep/index.d.ts +2 -0
  15. package/dist/src/core/global_modules/dep/interpret.d.ts +18 -0
  16. package/dist/src/core/global_modules/metadata/bind.d.ts +11 -0
  17. package/dist/src/core/global_modules/metadata/index.d.ts +2 -0
  18. package/dist/src/core/global_modules/metadata/interpret.d.ts +14 -0
  19. package/dist/src/core/global_modules/metadata/utils.d.ts +29 -0
  20. package/dist/src/core/global_modules/note/interpret.d.ts +3 -1
  21. package/dist/src/core/global_modules/program/utils/dep.d.ts +4 -0
  22. package/dist/src/core/global_modules/program/utils/external.d.ts +3 -0
  23. package/dist/src/core/global_modules/program/utils/index.d.ts +3 -0
  24. package/dist/src/core/global_modules/program/utils/records.d.ts +6 -0
  25. package/dist/src/core/global_modules/table/bind.d.ts +2 -0
  26. package/dist/src/core/global_modules/table/interpret.d.ts +12 -1
  27. package/dist/src/core/global_modules/tableGroup/interpret.d.ts +3 -1
  28. package/dist/src/core/global_modules/utils.d.ts +5 -1
  29. package/dist/src/core/local_modules/dep/index.d.ts +2 -0
  30. package/dist/src/core/local_modules/dep/validate.d.ts +19 -0
  31. package/dist/src/core/local_modules/metadata/index.d.ts +2 -0
  32. package/dist/src/core/local_modules/metadata/utils.d.ts +7 -0
  33. package/dist/src/core/local_modules/metadata/validate.d.ts +14 -0
  34. package/dist/src/core/types/errors.d.ts +62 -53
  35. package/dist/src/core/types/keywords.d.ts +4 -1
  36. package/dist/src/core/types/nodes.d.ts +14 -3
  37. package/dist/src/core/types/relation.d.ts +6 -2
  38. package/dist/src/core/types/schemaJson/types.d.ts +45 -1
  39. package/dist/src/core/types/symbol/metadata.d.ts +30 -11
  40. package/dist/src/core/types/symbol/symbols.d.ts +10 -1
  41. package/dist/src/core/utils/expression.d.ts +2 -1
  42. package/dist/src/core/utils/interpret.d.ts +12 -2
  43. package/dist/src/core/utils/note.d.ts +18 -0
  44. package/dist/src/core/utils/setting.d.ts +13 -14
  45. package/dist/src/core/utils/tokens.d.ts +3 -0
  46. package/dist/src/core/utils/validate.d.ts +16 -2
  47. package/dist/src/index.d.ts +7 -3
  48. package/dist/src/services/suggestions/provider.d.ts +19 -0
  49. package/package.json +4 -3
  50. package/dist/src/compiler/queries/transform/utils.d.ts +0 -23
  51. package/dist/src/core/global_modules/program/utils.d.ts +0 -3
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "https://json.schemastore.org/package",
3
3
  "name": "@dbml/parse",
4
- "version": "10.0.0-optional-ref.0",
4
+ "version": "10.0.0",
5
5
  "description": "DBML parser v2",
6
6
  "author": "Holistics <dev@holistics.io>",
7
7
  "license": "Apache-2.0",
@@ -31,7 +31,8 @@
31
31
  "test:watch": "vitest watch",
32
32
  "coverage": "vitest run --coverage",
33
33
  "prepare": "npm run build",
34
- "lint": "eslint .",
34
+ "lint": "eslint $(git diff --relative --name-only --diff-filter=ACMRTUXB master -- . | grep -E '\\.ts$')",
35
+ "lint:all": "eslint .",
35
36
  "lint:fix": "eslint --fix .",
36
37
  "bench": "npx tsx __benchmarks__/compiler.benchmark.ts",
37
38
  "profile:build": "vite build --config vite.profile.config.mts && cp -r __benchmarks__/input dist-profile/input",
@@ -50,5 +51,5 @@
50
51
  "engines": {
51
52
  "node": ">=18"
52
53
  },
53
- "gitHead": "b8daf0503d91ec322d427ab1f5e71a8a7f2ca12f"
54
+ "gitHead": "399f6352a3cb4f1bffc1cb355301af28f84dc09b"
54
55
  }
@@ -1,23 +0,0 @@
1
- import { Filepath } from '../../../core/types/filepath';
2
- import { NodeSymbol } from '../../../core/types/symbol';
3
- import { default as Compiler } from '../../index';
4
- export type TableNameInput = string | {
5
- schema?: string;
6
- table: string;
7
- };
8
- /**
9
- * Normalizes a table name input to { schema, table } format.
10
- * Properly handles quoted identifiers with dots inside.
11
- */
12
- export declare function normalizeTableName(input: TableNameInput): {
13
- schema: string;
14
- table: string;
15
- };
16
- /**
17
- * Looks up a table symbol by matching its full qualified name.
18
- */
19
- export declare function lookupTableSymbol(compiler: Compiler, filepath: Filepath, schema: string, table: string): NodeSymbol | null;
20
- /**
21
- * Removes surrounding double quotes from a string if present.
22
- */
23
- export declare function stripQuotes(str: string): string;
@@ -1,3 +0,0 @@
1
- import { Database, ElementRef } from '../../types/schemaJson';
2
- import { NodeSymbol } from '../../types/symbol';
3
- export declare function pushExternal(db: Database, member: NodeSymbol, ref: ElementRef): void;