@cspell/cspell-types 6.0.0 → 6.1.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.
@@ -20,4 +20,25 @@ export interface TextDocumentOffset extends TextOffset {
20
20
  col: number;
21
21
  line: TextOffset;
22
22
  }
23
+ export interface Mapped {
24
+ /**
25
+ * `(i, j)` number pairs where
26
+ * - `i` is the offset in the source
27
+ * - `j` is the offset in the destination
28
+ *
29
+ * Example:
30
+ * - source text = `"caf\xe9"`
31
+ * - mapped text = `"café"`
32
+ * - map = `[3, 3, 7, 4]`, which is equivalent to `[0, 0, 3, 3, 7, 4]`
33
+ * where the `[0, 0]` is unnecessary.
34
+ *
35
+ */
36
+ map: number[];
37
+ }
38
+ export interface TransformedText extends Partial<Mapped> {
39
+ /**
40
+ * Transformed text with an optional map.
41
+ */
42
+ text: string;
43
+ }
23
44
  //# sourceMappingURL=TextOffset.d.ts.map
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "publishConfig": {
4
4
  "access": "public"
5
5
  },
6
- "version": "6.0.0",
6
+ "version": "6.1.1",
7
7
  "description": "Types for cspell and cspell-lib",
8
8
  "main": "dist/index.js",
9
9
  "typings": "dist/index.d.ts",
@@ -18,13 +18,11 @@
18
18
  "build": "npm run compile && npm run build-schema",
19
19
  "build-dev": "tsc -p tsconfig.dev.json",
20
20
  "build-schema": "ts-json-schema-generator --no-top-ref --path src/CSpellSettingsDef.ts --type CSpellSettings --validation-keywords markdownDescription --validation-keywords scope --validation-keywords deprecated --validation-keywords deprecationMessage -o ./cspell.schema.json && cp ./cspell.schema.json ../..",
21
- "build-cspell-types-docs": "rimraf ../../docs/types/cspell-types && typedoc --out ../../docs/types/cspell-types src/index.ts",
22
- "test-build-docs": "typedoc --out ./temp/docs src/index.ts",
23
21
  "clean-build": "npm run clean && npm run build",
24
22
  "compile": "tsc -p .",
25
23
  "test-schema": "ajv -s ./cspell.schema.json -d \"cspell.test.{json,yaml}\" -c ./ajv.config.js",
26
24
  "test": "jest && npm run test-schema",
27
- "prepare": "npm run build"
25
+ "prepare": "echo Skip Building Types"
28
26
  },
29
27
  "repository": {
30
28
  "type": "git",
@@ -53,9 +51,7 @@
53
51
  "jest": "^28.1.0",
54
52
  "rimraf": "^3.0.2",
55
53
  "ts-json-schema-generator": "^1.0.0",
56
- "typedoc": "0.22.15",
57
- "typedoc-plugin-markdown": "^3.12.1",
58
- "typescript": "^4.6.4"
54
+ "typescript": "^4.7.2"
59
55
  },
60
- "gitHead": "7fd3e4ff8738a84d0aa48b9a9d4581b5efe50bea"
56
+ "gitHead": "e871153bfebefa19b13754b431ce5e49a63da298"
61
57
  }