@lapidist/dtif-language-server 1.0.6 → 2.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 (3) hide show
  1. package/LICENSE +28 -0
  2. package/README.md +5 -5
  3. package/package.json +15 -13
package/LICENSE ADDED
@@ -0,0 +1,28 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2025 Brett Dorrans and contributors
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
22
+
23
+ ---
24
+
25
+ This repository includes material copied from or derived from the
26
+ [Design Tokens Community Group format specification](https://design-tokens.github.io/community-group/format/),
27
+ originally distributed under the W3C Software Notice and License. Attribution is preserved
28
+ within the specification documents.
package/README.md CHANGED
@@ -9,7 +9,7 @@
9
9
 
10
10
  ### Diagnostics and validation
11
11
 
12
- - Parses DTIF documents with tolerant JSONC support and precise error ranges.
12
+ - Parses DTIF documents as strict JSON (no comments or trailing commas) with precise error ranges.
13
13
  - Validates against the canonical DTIF schema via `@lapidist/dtif-validator`.
14
14
  - Publishes diagnostics on open and change events, clearing them automatically when documents close.
15
15
 
@@ -26,7 +26,7 @@
26
26
 
27
27
  ### Authoring assistance
28
28
 
29
- - Supplies contextual completions for `$type` identifiers, measurement units, and `$extensions` namespaces sourced from the DTIF registry.
29
+ - Supplies contextual completions for `$type` identifiers (registry-backed), measurement units, and `$extensions` namespaces based on reverse-DNS snippets and observed workspace keys.
30
30
  - Orders completion results by relevance to the active pointer scope.
31
31
 
32
32
  ## Installation
@@ -90,9 +90,9 @@ The language server depends on `@lapidist/dtif-parser`, `@lapidist/dtif-validato
90
90
 
91
91
  ## Development
92
92
 
93
- - `npm run build --workspace=@lapidist/dtif-language-server` – compile to `dist/`.
94
- - `npm test --workspace=@lapidist/dtif-language-server` – run the Node.js test suite.
95
- - `npm run lint` / `npm run lint:ts` – enforce repository lint rules.
93
+ - `pnpm --filter @lapidist/dtif-language-server run build` – compile to `dist/`.
94
+ - `pnpm --filter @lapidist/dtif-language-server test` – run the Node.js test suite.
95
+ - `pnpm run lint` / `pnpm run lint:ts` – enforce repository lint rules.
96
96
 
97
97
  Integration tests in `language-server/tests/` spin up the LSP over JSON-RPC streams to verify diagnostics, navigation, refactors, and configuration handling end to end.
98
98
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lapidist/dtif-language-server",
3
- "version": "1.0.6",
3
+ "version": "2.0.0",
4
4
  "description": "Language Server Protocol implementation for the Design Token Interchange Format (DTIF).",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -9,7 +9,7 @@
9
9
  "types": "./dist/index.d.ts",
10
10
  "engines": {
11
11
  "node": ">=22",
12
- "npm": ">=10"
12
+ "pnpm": ">=10"
13
13
  },
14
14
  "exports": {
15
15
  ".": {
@@ -22,21 +22,17 @@
22
22
  "dist",
23
23
  "README.md"
24
24
  ],
25
- "scripts": {
26
- "build": "tsc -p tsconfig.json",
27
- "clean": "rimraf dist",
28
- "test": "node --import tsx --test ./tests/**/*.test.ts",
29
- "typecheck": "tsc -p tsconfig.json --noEmit",
30
- "prepack": "npm run build"
31
- },
32
25
  "dependencies": {
33
- "@lapidist/dtif-parser": "1.0.6",
34
- "@lapidist/dtif-schema": "1.0.6",
35
- "@lapidist/dtif-validator": "1.0.6",
26
+ "@lapidist/dtif-parser": "^2.0.0",
27
+ "@lapidist/dtif-schema": "^2.0.0",
28
+ "@lapidist/dtif-validator": "^2.0.0",
36
29
  "jsonc-parser": "^3.3.1",
37
30
  "vscode-languageserver": "^9.0.1",
38
31
  "vscode-languageserver-textdocument": "^1.0.11"
39
32
  },
33
+ "devDependencies": {
34
+ "vscode-jsonrpc": "8.2.0"
35
+ },
40
36
  "repository": {
41
37
  "type": "git",
42
38
  "url": "git+https://github.com/bylapidist/dtif.git",
@@ -44,5 +40,11 @@
44
40
  },
45
41
  "publishConfig": {
46
42
  "access": "public"
43
+ },
44
+ "scripts": {
45
+ "build": "tsc -p tsconfig.json",
46
+ "clean": "rimraf dist",
47
+ "test": "node --import tsx --test ./tests/**/*.test.ts",
48
+ "typecheck": "tsc -p tsconfig.json --noEmit"
47
49
  }
48
- }
50
+ }