@blocklet/discuss-kit-ux 2.3.28 → 2.3.30
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/icon-button.d.ts +5 -0
- package/dist/components/posts/index.d.ts +0 -1
- package/dist/components/rating/github-reaction-container.d.ts +8 -0
- package/dist/components/rating/github-reaction.d.ts +4 -6
- package/dist/components/rating/index.d.ts +1 -0
- package/dist/components/utils.d.ts +1 -0
- package/dist/{editor-LcIsRLJi.mjs → editor-D7LXxjZZ.mjs} +1 -1
- package/dist/{index-OmY69aLb.mjs → index-DaWKO34e.mjs} +203 -209
- package/dist/index.d.ts +1 -0
- package/dist/index.es.js +61 -60
- package/dist/index.umd.js +141 -147
- package/package.json +3 -3
- package/dist/components/posts/comment-icon-button.d.ts +0 -5
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { BoxProps, IconButtonProps } from '@mui/material';
|
|
2
|
+
export declare function IconButton<C extends React.ElementType>({ sx, ...rest }: IconButtonProps<C, {
|
|
3
|
+
component?: C;
|
|
4
|
+
}>): import("react/jsx-runtime").JSX.Element;
|
|
5
|
+
export declare function IconButtonGroup({ children, sx, ...rest }: BoxProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { AxiosInstance } from 'axios';
|
|
2
|
+
import { GithubReactionProps } from './github-reaction';
|
|
3
|
+
interface Props extends Omit<GithubReactionProps, 'data' | 'onRate' | 'onUnrate'> {
|
|
4
|
+
id: string;
|
|
5
|
+
request: AxiosInstance;
|
|
6
|
+
}
|
|
7
|
+
export declare function GithubReactionContainer({ id, request, ...rest }: Props): import("react/jsx-runtime").JSX.Element | null;
|
|
8
|
+
export {};
|
|
@@ -1,19 +1,17 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { IconButtonProps } from '@mui/material';
|
|
2
2
|
import { Rating as RatingType } from '../../types';
|
|
3
|
-
type GithubReactionProps = {
|
|
3
|
+
export type GithubReactionProps = {
|
|
4
4
|
data: RatingType[];
|
|
5
5
|
onRate: ({ ratingType, value }: {
|
|
6
6
|
ratingType: string;
|
|
7
7
|
value: string;
|
|
8
8
|
}) => Promise<any>;
|
|
9
9
|
onUnrate: () => Promise<any>;
|
|
10
|
-
append?: React.ReactNode;
|
|
11
10
|
interactive?: boolean;
|
|
12
|
-
};
|
|
11
|
+
} & IconButtonProps;
|
|
13
12
|
/**
|
|
14
13
|
* 说明:
|
|
15
14
|
* GithubReaction 与 Rating 组件不兼容, 后者是 n 选 1, GithubReaction 是 n 选 m,
|
|
16
15
|
* 所以 GithubReaction 相当于重写, 与 Rating 组件和 BinaryThumb 组件没有关系
|
|
17
16
|
*/
|
|
18
|
-
export default function GithubReaction({ data, onRate, onUnrate,
|
|
19
|
-
export {};
|
|
17
|
+
export default function GithubReaction({ data, onRate, onUnrate, interactive, sx, ...rest }: GithubReactionProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -14,6 +14,7 @@ export declare const blockletExists: (name: string) => boolean;
|
|
|
14
14
|
export declare const getExcerptFromLexicalContent: (content: any, size?: number) => string;
|
|
15
15
|
export declare const mergeSx: (initial: SystemStyleObject<Theme>, sx?: SxProps<Theme>) => any[];
|
|
16
16
|
export declare const discussKitMountPoint: string | undefined;
|
|
17
|
+
export declare const discussKitApiBaseUrl: string;
|
|
17
18
|
export declare const discussKitUploadsUrl: string;
|
|
18
19
|
export declare const isInDiscussKitApp: boolean | "" | undefined;
|
|
19
20
|
export declare const openProfile: (did: string, newTab?: boolean) => void;
|
|
@@ -4,7 +4,7 @@ import { OnContentChangePlugin } from "@blocklet/editor/lib/ext/OnContentChangeP
|
|
|
4
4
|
import { CtrlsShortcutPlugin } from "@blocklet/editor/lib/ext/ShortcutPlugin";
|
|
5
5
|
import { SafeAreaPlugin } from "@blocklet/editor/lib/ext/SafeAreaPlugin";
|
|
6
6
|
import { lazyRetry } from "@arcblock/ux/lib/Util";
|
|
7
|
-
import { i as inferInitialEditorState, I as ImagePathFixerPlugin, V as VideoPathFixerPlugin, a as isEmptyContent, s as stringify, g as getExcerptSync } from "./index-
|
|
7
|
+
import { i as inferInitialEditorState, I as ImagePathFixerPlugin, V as VideoPathFixerPlugin, a as isEmptyContent, s as stringify, g as getExcerptSync } from "./index-DaWKO34e.mjs";
|
|
8
8
|
const BlockletEditor = lazyRetry(() => import("@blocklet/editor"));
|
|
9
9
|
const Root = styled(Box)`
|
|
10
10
|
.be-editable,
|