@idfkit/language 0.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.
- package/LICENSE +21 -0
- package/README.md +47 -0
- package/dist/complete.d.ts +93 -0
- package/dist/complete.d.ts.map +1 -0
- package/dist/complete.js +225 -0
- package/dist/complete.js.map +1 -0
- package/dist/cursor.d.ts +59 -0
- package/dist/cursor.d.ts.map +1 -0
- package/dist/cursor.js +286 -0
- package/dist/cursor.js.map +1 -0
- package/dist/declaration.d.ts +70 -0
- package/dist/declaration.d.ts.map +1 -0
- package/dist/declaration.js +184 -0
- package/dist/declaration.js.map +1 -0
- package/dist/explain.d.ts +97 -0
- package/dist/explain.d.ts.map +1 -0
- package/dist/explain.js +130 -0
- package/dist/explain.js.map +1 -0
- package/dist/findings.d.ts +58 -0
- package/dist/findings.d.ts.map +1 -0
- package/dist/findings.js +325 -0
- package/dist/findings.js.map +1 -0
- package/dist/index.d.ts +33 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +28 -0
- package/dist/index.js.map +1 -0
- package/package.json +48 -0
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* `@idfkit/language` — the opt-in language service for IDF text.
|
|
3
|
+
*
|
|
4
|
+
* Answers a cursor: what completes here, what this means, what this points at.
|
|
5
|
+
* Positions the findings a parse and a validation already produced. Everything
|
|
6
|
+
* exported here is synchronous and free of I/O, so the same code runs unchanged
|
|
7
|
+
* in Node, a browser, a browser worker, and behind an editor server.
|
|
8
|
+
*
|
|
9
|
+
* Every answer takes the text itself and never a path (FR-026): an editor's
|
|
10
|
+
* buffer differs from the file on disk whenever there are unsaved changes,
|
|
11
|
+
* which is most of the time an editor is interesting. Nothing here reads a
|
|
12
|
+
* file, opens a socket, consults a clock, or returns a promise, and there is no
|
|
13
|
+
* service object to construct, because a service object is where state would
|
|
14
|
+
* accumulate.
|
|
15
|
+
*
|
|
16
|
+
* The syntax layer this builds on is not re-exported. `scanIdf` and `classify`
|
|
17
|
+
* come from `@idfkit/core`, which this package peer-depends on, because the
|
|
18
|
+
* layer serves reading and writing too and one function deserves one name.
|
|
19
|
+
*
|
|
20
|
+
* Nothing here imports, depends on, or names a type from any editor protocol
|
|
21
|
+
* library, and nothing here ever will. A consumer translates.
|
|
22
|
+
*/
|
|
23
|
+
export { contextAt } from './cursor.js';
|
|
24
|
+
export type { CursorContext } from './cursor.js';
|
|
25
|
+
export { completionsAt } from './complete.js';
|
|
26
|
+
export type { CompletionOptions, CompletionResult, Offer } from './complete.js';
|
|
27
|
+
export { explainAt } from './explain.js';
|
|
28
|
+
export type { Explanation, ExplanationResult } from './explain.js';
|
|
29
|
+
export { declarationAt } from './declaration.js';
|
|
30
|
+
export type { Declaration, DeclarationResult } from './declaration.js';
|
|
31
|
+
export { findingsIn, position } from './findings.js';
|
|
32
|
+
export type { PositionedFinding } from './findings.js';
|
|
33
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,YAAY,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAEjD,OAAO,EAAE,aAAa,EAAE,MAAM,eAAe,CAAC;AAC9C,YAAY,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AAEhF,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACzC,YAAY,EAAE,WAAW,EAAE,iBAAiB,EAAE,MAAM,cAAc,CAAC;AAEnE,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AACjD,YAAY,EAAE,WAAW,EAAE,iBAAiB,EAAE,MAAM,kBAAkB,CAAC;AAEvE,OAAO,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AACrD,YAAY,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAC"}
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* `@idfkit/language` — the opt-in language service for IDF text.
|
|
3
|
+
*
|
|
4
|
+
* Answers a cursor: what completes here, what this means, what this points at.
|
|
5
|
+
* Positions the findings a parse and a validation already produced. Everything
|
|
6
|
+
* exported here is synchronous and free of I/O, so the same code runs unchanged
|
|
7
|
+
* in Node, a browser, a browser worker, and behind an editor server.
|
|
8
|
+
*
|
|
9
|
+
* Every answer takes the text itself and never a path (FR-026): an editor's
|
|
10
|
+
* buffer differs from the file on disk whenever there are unsaved changes,
|
|
11
|
+
* which is most of the time an editor is interesting. Nothing here reads a
|
|
12
|
+
* file, opens a socket, consults a clock, or returns a promise, and there is no
|
|
13
|
+
* service object to construct, because a service object is where state would
|
|
14
|
+
* accumulate.
|
|
15
|
+
*
|
|
16
|
+
* The syntax layer this builds on is not re-exported. `scanIdf` and `classify`
|
|
17
|
+
* come from `@idfkit/core`, which this package peer-depends on, because the
|
|
18
|
+
* layer serves reading and writing too and one function deserves one name.
|
|
19
|
+
*
|
|
20
|
+
* Nothing here imports, depends on, or names a type from any editor protocol
|
|
21
|
+
* library, and nothing here ever will. A consumer translates.
|
|
22
|
+
*/
|
|
23
|
+
export { contextAt } from './cursor.js';
|
|
24
|
+
export { completionsAt } from './complete.js';
|
|
25
|
+
export { explainAt } from './explain.js';
|
|
26
|
+
export { declarationAt } from './declaration.js';
|
|
27
|
+
export { findingsIn, position } from './findings.js';
|
|
28
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAGxC,OAAO,EAAE,aAAa,EAAE,MAAM,eAAe,CAAC;AAG9C,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAGzC,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAGjD,OAAO,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC"}
|
package/package.json
ADDED
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@idfkit/language",
|
|
3
|
+
"version": "0.0.0",
|
|
4
|
+
"description": "The opt-in IDF language service: cursor answers, positioned findings, synchronous and free of I/O, with no editor protocol",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"license": "MIT",
|
|
7
|
+
"author": "Samuel Letellier-Duchesne <developers@idfkit.com>",
|
|
8
|
+
"repository": {
|
|
9
|
+
"type": "git",
|
|
10
|
+
"url": "git+https://github.com/idfkit/idfkit-js.git",
|
|
11
|
+
"directory": "packages/language"
|
|
12
|
+
},
|
|
13
|
+
"homepage": "https://js.idfkit.com/",
|
|
14
|
+
"bugs": {
|
|
15
|
+
"url": "https://github.com/idfkit/idfkit-js/issues"
|
|
16
|
+
},
|
|
17
|
+
"keywords": [
|
|
18
|
+
"energyplus",
|
|
19
|
+
"idf",
|
|
20
|
+
"editor",
|
|
21
|
+
"completion",
|
|
22
|
+
"diagnostics",
|
|
23
|
+
"building-energy",
|
|
24
|
+
"simulation"
|
|
25
|
+
],
|
|
26
|
+
"exports": {
|
|
27
|
+
".": {
|
|
28
|
+
"types": "./dist/index.d.ts",
|
|
29
|
+
"default": "./dist/index.js"
|
|
30
|
+
}
|
|
31
|
+
},
|
|
32
|
+
"files": [
|
|
33
|
+
"dist",
|
|
34
|
+
"LICENSE"
|
|
35
|
+
],
|
|
36
|
+
"publishConfig": {
|
|
37
|
+
"access": "public"
|
|
38
|
+
},
|
|
39
|
+
"engines": {
|
|
40
|
+
"node": ">=20"
|
|
41
|
+
},
|
|
42
|
+
"peerDependencies": {
|
|
43
|
+
"@idfkit/core": "0.0.0"
|
|
44
|
+
},
|
|
45
|
+
"scripts": {
|
|
46
|
+
"build": "tsc --build"
|
|
47
|
+
}
|
|
48
|
+
}
|