x-star-editor 0.4.2 → 0.6.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/dist/components/FileInput.js +16 -16
- package/dist/components/Toolbar.js +47 -82
- package/dist/index.d.ts +2 -0
- package/dist/index.js +2 -1
- package/dist/styles/cursor/editor-eraser.png +0 -0
- package/dist/styles/cursor/pencil.png +0 -0
- package/dist/styles/index.css +1455 -1261
- package/dist/themes/lark.css +160 -59
- package/dist/utils/container.js +7 -2
- package/dist/utils/global.d.ts +1 -1
- package/dist/utils/global.js +1 -1
- package/dist/utils/markdown.d.ts +8 -9
- package/dist/utils/markdown.js +36 -21
- package/dist/utils/slide/index.d.ts +0 -0
- package/dist/utils/slide/index.js +32 -0
- package/dist/x-star-editor/index.d.ts +2 -6
- package/dist/x-star-editor/index.js +10 -12
- package/dist/x-star-md-editor/index.js +1 -1
- package/dist/x-star-md-viewer/index.d.ts +0 -4
- package/dist/x-star-md-viewer/index.js +41 -31
- package/dist/x-star-slide-viewer/index.d.ts +42 -0
- package/dist/x-star-slide-viewer/index.js +367 -0
- package/package.json +8 -4
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { ViewerOptions } from "../x-star-md-viewer/index.js";
|
|
3
|
+
export interface XStarSlideViewerPlugin {
|
|
4
|
+
(ctx: ViewerOptions): void;
|
|
5
|
+
}
|
|
6
|
+
export interface XStarSlideViewerHandle {
|
|
7
|
+
getViewerContainer: () => HTMLDivElement;
|
|
8
|
+
getSlideContainer: () => HTMLDivElement;
|
|
9
|
+
}
|
|
10
|
+
export interface XStarSlideViewerProps {
|
|
11
|
+
/**
|
|
12
|
+
* CSS 类名
|
|
13
|
+
*/
|
|
14
|
+
className?: string;
|
|
15
|
+
/**
|
|
16
|
+
* CSS 样式
|
|
17
|
+
*/
|
|
18
|
+
style?: React.CSSProperties;
|
|
19
|
+
/**
|
|
20
|
+
* 查看器的高度
|
|
21
|
+
*/
|
|
22
|
+
height?: React.CSSProperties['height'];
|
|
23
|
+
/**
|
|
24
|
+
* 内置主题
|
|
25
|
+
*/
|
|
26
|
+
theme?: string;
|
|
27
|
+
/**
|
|
28
|
+
* 内部 Slide 容器 CSS 类名
|
|
29
|
+
*/
|
|
30
|
+
slideClassName?: string;
|
|
31
|
+
/**
|
|
32
|
+
* 文本
|
|
33
|
+
*/
|
|
34
|
+
value?: string;
|
|
35
|
+
/**
|
|
36
|
+
* 插件
|
|
37
|
+
*/
|
|
38
|
+
plugins?: XStarSlideViewerPlugin[];
|
|
39
|
+
}
|
|
40
|
+
declare const XStarSlideViewer: React.ForwardRefExoticComponent<XStarSlideViewerProps & React.RefAttributes<XStarSlideViewerHandle>>;
|
|
41
|
+
export default XStarSlideViewer;
|
|
42
|
+
export declare const useSlideViewerRef: () => React.RefObject<XStarSlideViewerHandle>;
|