ranui 0.1.10-alpha.17 → 0.1.10-alpha.19
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.zh-CN.md +8 -6
- package/dist/index.d.ts +18 -16
- package/dist/typings.d.ts +18 -16
- package/package.json +6 -1
- package/readme.md +8 -0
- package/typings.d.ts +18 -16
package/README.zh-CN.md
CHANGED
|
@@ -50,15 +50,17 @@ import 'ranui/style';
|
|
|
50
50
|
如果遇到类型问题,可以选择手动导入类型文件
|
|
51
51
|
|
|
52
52
|
```ts
|
|
53
|
-
import 'ranui/
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
或者
|
|
57
|
-
|
|
58
|
-
|
|
53
|
+
import 'ranui/typings';
|
|
54
|
+
// 或者
|
|
55
|
+
import 'ranui/dist/index.d.ts';
|
|
56
|
+
// 或者
|
|
57
|
+
import 'ranui/type';
|
|
58
|
+
// 或者
|
|
59
59
|
import 'ranui/dist/typings';
|
|
60
60
|
```
|
|
61
61
|
|
|
62
|
+
并不是都要,选一个能生效的就行
|
|
63
|
+
|
|
62
64
|
也支持全量导入
|
|
63
65
|
|
|
64
66
|
```ts
|
package/dist/index.d.ts
CHANGED
|
@@ -110,22 +110,24 @@ interface MathJax {
|
|
|
110
110
|
tex2chtmlPromise: (x: string, y: object) => Promise<Element>;
|
|
111
111
|
}
|
|
112
112
|
|
|
113
|
-
declare
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
113
|
+
declare global {
|
|
114
|
+
interface Window {
|
|
115
|
+
ranui: Partial<Ranui>;
|
|
116
|
+
message: Partial<Ran.Message>;
|
|
117
|
+
MathJax: MathJax;
|
|
118
|
+
katex: {
|
|
119
|
+
render: (x: string, y: HTMLElement, z: object) => void;
|
|
120
|
+
};
|
|
121
|
+
pdfjsLib: {
|
|
122
|
+
GlobalWorkerOptions: {
|
|
123
|
+
workerSrc: string;
|
|
124
|
+
};
|
|
125
|
+
getDocument: (x: string | ArrayBuffer) => {
|
|
126
|
+
promise: Promise<PDFDocumentProxy>;
|
|
127
|
+
};
|
|
128
|
+
};
|
|
129
|
+
Hls: HLS;
|
|
130
|
+
}
|
|
129
131
|
}
|
|
130
132
|
|
|
131
133
|
namespace JSX {
|
package/dist/typings.d.ts
CHANGED
|
@@ -91,22 +91,24 @@ interface MathJax {
|
|
|
91
91
|
tex2chtmlPromise: (x: string, y: object) => Promise<Element>;
|
|
92
92
|
}
|
|
93
93
|
|
|
94
|
-
declare
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
94
|
+
declare global {
|
|
95
|
+
interface Window {
|
|
96
|
+
ranui: Partial<Ranui>;
|
|
97
|
+
message: Partial<Ran.Message>;
|
|
98
|
+
MathJax: MathJax;
|
|
99
|
+
katex: {
|
|
100
|
+
render: (x: string, y: HTMLElement, z: object) => void;
|
|
101
|
+
};
|
|
102
|
+
pdfjsLib: {
|
|
103
|
+
GlobalWorkerOptions: {
|
|
104
|
+
workerSrc: string;
|
|
105
|
+
};
|
|
106
|
+
getDocument: (x: string | ArrayBuffer) => {
|
|
107
|
+
promise: Promise<PDFDocumentProxy>;
|
|
108
|
+
};
|
|
109
|
+
};
|
|
110
|
+
Hls: HLS;
|
|
111
|
+
}
|
|
110
112
|
}
|
|
111
113
|
|
|
112
114
|
namespace JSX {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "ranui",
|
|
3
|
-
"version": "0.1.10-alpha.
|
|
3
|
+
"version": "0.1.10-alpha.19",
|
|
4
4
|
"description": "UI Component library based on `Web Component`",
|
|
5
5
|
"main": "dist/umd/index.umd.cjs",
|
|
6
6
|
"module": "dist/index.js",
|
|
@@ -158,6 +158,11 @@
|
|
|
158
158
|
"import": "./dist/index.js",
|
|
159
159
|
"require": "./dist/index.js"
|
|
160
160
|
},
|
|
161
|
+
"./typings": {
|
|
162
|
+
"types": "./dist/typings.d.ts",
|
|
163
|
+
"import": "./dist/typings.d.ts",
|
|
164
|
+
"require": "./dist/index.js"
|
|
165
|
+
},
|
|
161
166
|
"./dist/*": {
|
|
162
167
|
"types": "./dist/*",
|
|
163
168
|
"import": "./dist/*",
|
package/readme.md
CHANGED
|
@@ -51,9 +51,17 @@ import 'ranui/style';
|
|
|
51
51
|
If there is a `type` problem, you can manually import the type
|
|
52
52
|
|
|
53
53
|
```ts
|
|
54
|
+
import 'ranui/typings';
|
|
55
|
+
// or
|
|
54
56
|
import 'ranui/dist/index.d.ts';
|
|
57
|
+
// or
|
|
58
|
+
import 'ranui/type';
|
|
59
|
+
// or
|
|
60
|
+
import 'ranui/dist/typings';
|
|
55
61
|
```
|
|
56
62
|
|
|
63
|
+
Not all of them. Just pick one that works
|
|
64
|
+
|
|
57
65
|
Support global import
|
|
58
66
|
|
|
59
67
|
```ts
|
package/typings.d.ts
CHANGED
|
@@ -91,22 +91,24 @@ interface MathJax {
|
|
|
91
91
|
tex2chtmlPromise: (x: string, y: object) => Promise<Element>;
|
|
92
92
|
}
|
|
93
93
|
|
|
94
|
-
declare
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
94
|
+
declare global {
|
|
95
|
+
interface Window {
|
|
96
|
+
ranui: Partial<Ranui>;
|
|
97
|
+
message: Partial<Ran.Message>;
|
|
98
|
+
MathJax: MathJax;
|
|
99
|
+
katex: {
|
|
100
|
+
render: (x: string, y: HTMLElement, z: object) => void;
|
|
101
|
+
};
|
|
102
|
+
pdfjsLib: {
|
|
103
|
+
GlobalWorkerOptions: {
|
|
104
|
+
workerSrc: string;
|
|
105
|
+
};
|
|
106
|
+
getDocument: (x: string | ArrayBuffer) => {
|
|
107
|
+
promise: Promise<PDFDocumentProxy>;
|
|
108
|
+
};
|
|
109
|
+
};
|
|
110
|
+
Hls: HLS;
|
|
111
|
+
}
|
|
110
112
|
}
|
|
111
113
|
|
|
112
114
|
namespace JSX {
|