satori 0.0.45 → 0.1.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/README.md +16 -1
- package/dist/index.cjs +9 -9
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +20 -1
- package/dist/index.js +9 -9
- package/dist/index.js.map +1 -1
- package/dist/index.wasm.cjs +9 -9
- package/dist/index.wasm.cjs.map +1 -1
- package/dist/index.wasm.js +9 -9
- package/dist/index.wasm.js.map +1 -1
- package/package.json +18 -18
- package/dist/esm/index.js +0 -9
- package/dist/esm/index.js.LEGAL.txt +0 -1
- package/dist/esm/index.js.map +0 -1
- package/dist/esm/index.wasm.js +0 -9
- package/dist/esm/index.wasm.js.LEGAL.txt +0 -1
- package/dist/esm/index.wasm.js.map +0 -1
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,24 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
2
|
import * as yoga_layout from 'yoga-layout';
|
|
3
3
|
|
|
4
|
+
declare const code: {
|
|
5
|
+
readonly 'ja-JP': RegExp;
|
|
6
|
+
readonly 'ko-KR': RegExp;
|
|
7
|
+
readonly 'zh-CN': RegExp;
|
|
8
|
+
readonly 'zh-TW': RegExp;
|
|
9
|
+
readonly 'zh-HK': RegExp;
|
|
10
|
+
readonly 'th-TH': RegExp;
|
|
11
|
+
readonly 'bn-IN': RegExp;
|
|
12
|
+
readonly 'ar-AR': RegExp;
|
|
13
|
+
readonly 'ta-IN': RegExp;
|
|
14
|
+
readonly 'ml-IN': RegExp;
|
|
15
|
+
readonly 'he-IL': RegExp;
|
|
16
|
+
readonly 'te-IN': RegExp;
|
|
17
|
+
readonly devanagari: RegExp;
|
|
18
|
+
readonly kannada: RegExp;
|
|
19
|
+
};
|
|
20
|
+
declare type Locale = keyof typeof code;
|
|
21
|
+
|
|
4
22
|
/**
|
|
5
23
|
* This class handles everything related to fonts.
|
|
6
24
|
*/
|
|
@@ -12,6 +30,7 @@ interface FontOptions {
|
|
|
12
30
|
name: string;
|
|
13
31
|
weight?: Weight;
|
|
14
32
|
style?: Style;
|
|
33
|
+
lang?: string;
|
|
15
34
|
}
|
|
16
35
|
|
|
17
36
|
declare let Yoga: typeof yoga_layout;
|
|
@@ -34,4 +53,4 @@ declare type SatoriOptions = ({
|
|
|
34
53
|
|
|
35
54
|
declare function satori(element: ReactNode, options: SatoriOptions): Promise<string>;
|
|
36
55
|
|
|
37
|
-
export { FontOptions as Font, Style as FontStyle, Weight as FontWeight, SatoriOptions, satori as default, init };
|
|
56
|
+
export { FontOptions as Font, Style as FontStyle, Weight as FontWeight, Locale, SatoriOptions, satori as default, init };
|