@cantoo/fontkit 2.0.7 → 2.0.8

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cantoo/fontkit",
3
- "version": "2.0.7",
3
+ "version": "2.0.8",
4
4
  "description": "An advanced font engine for Node and the browser",
5
5
  "keywords": [
6
6
  "opentype",
@@ -58,14 +58,17 @@
58
58
  "default": "./dist/browser-module.mjs"
59
59
  },
60
60
  "./unicode-trie": {
61
+ "types": "./src/packages/unicode-trie/dist/index.d.ts",
61
62
  "import": "./src/packages/unicode-trie/dist/index.mjs",
62
63
  "require": "./src/packages/unicode-trie/dist/index.cjs"
63
64
  },
64
65
  "./unicode-trie/builder.js": {
66
+ "types": "./src/packages/unicode-trie/dist/builder.d.ts",
65
67
  "import": "./src/packages/unicode-trie/dist/builder.mjs",
66
68
  "require": "./src/packages/unicode-trie/dist/builder.cjs"
67
69
  },
68
70
  "./unicode-properties": {
71
+ "types": "./src/packages/unicode-properties/dist/index.d.ts",
69
72
  "import": "./src/packages/unicode-properties/dist/index.mjs",
70
73
  "require": "./src/packages/unicode-properties/dist/index.cjs"
71
74
  },
@@ -0,0 +1,37 @@
1
+ /**
2
+ * Public TypeScript API for `@cantoo/unicode-properties`.
3
+ */
4
+
5
+ export function getCategory(codePoint: number): string;
6
+ export function getCombiningClass(codePoint: number): string;
7
+ export function getScript(codePoint: number): string;
8
+ export function getEastAsianWidth(codePoint: number): string;
9
+ export function getNumericValue(codePoint: number): number | null;
10
+ export function isAlphabetic(codePoint: number): boolean;
11
+ export function isDigit(codePoint: number): boolean;
12
+ export function isPunctuation(codePoint: number): boolean;
13
+ export function isLowerCase(codePoint: number): boolean;
14
+ export function isUpperCase(codePoint: number): boolean;
15
+ export function isTitleCase(codePoint: number): boolean;
16
+ export function isWhiteSpace(codePoint: number): boolean;
17
+ export function isBaseForm(codePoint: number): boolean;
18
+ export function isMark(codePoint: number): boolean;
19
+
20
+ declare const unicodeProperties: {
21
+ getCategory: typeof getCategory;
22
+ getCombiningClass: typeof getCombiningClass;
23
+ getScript: typeof getScript;
24
+ getEastAsianWidth: typeof getEastAsianWidth;
25
+ getNumericValue: typeof getNumericValue;
26
+ isAlphabetic: typeof isAlphabetic;
27
+ isDigit: typeof isDigit;
28
+ isPunctuation: typeof isPunctuation;
29
+ isLowerCase: typeof isLowerCase;
30
+ isUpperCase: typeof isUpperCase;
31
+ isTitleCase: typeof isTitleCase;
32
+ isWhiteSpace: typeof isWhiteSpace;
33
+ isBaseForm: typeof isBaseForm;
34
+ isMark: typeof isMark;
35
+ };
36
+
37
+ export default unicodeProperties;