@blocklet/discuss-kit-ux 2.1.8 → 2.1.10
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/uploader/utils.d.ts +1 -1
- package/dist/components/utils.d.ts +1 -1
- package/dist/{editor-DmeTB3KQ.mjs → editor-Be1sUDpj.mjs} +1 -1
- package/dist/{index-DJrI2eNo.mjs → index-CfBDgHqA.mjs} +32 -37
- package/dist/index.es.js +2 -2
- package/dist/index.umd.js +31 -36
- package/package.json +4 -4
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const
|
|
1
|
+
export declare const getUploadedImageUrl: (imageUrl: string, width?: number) => string;
|
|
@@ -12,11 +12,11 @@ export declare function tryParseJSONObject(str: string): boolean;
|
|
|
12
12
|
export declare const getPreference: (key: string) => any;
|
|
13
13
|
export declare const getBlockletMountPointInfo: (name: string) => ComponentMountPoint | undefined;
|
|
14
14
|
export declare const blockletExists: (name: string) => boolean;
|
|
15
|
-
export declare const inferDiscussKitApiPrefix: () => any;
|
|
16
15
|
export declare const getDraftSessionKeyPrefix: () => string;
|
|
17
16
|
export declare const getExcerptFromLexicalContent: (content: any, size?: number) => string;
|
|
18
17
|
export declare const mergeSx: (initial: SystemStyleObject<Theme>, sx?: SxProps<Theme>) => any[];
|
|
19
18
|
export declare const discussKitMountPoint: string | undefined;
|
|
19
|
+
export declare const discussKitUploadsUrl: string;
|
|
20
20
|
export declare const isInDiscussKitApp: boolean | "" | undefined;
|
|
21
21
|
export declare const openProfile: (did: string, newTab?: boolean) => void;
|
|
22
22
|
export declare const randomId: () => string;
|
|
@@ -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 { lazy } from "react";
|
|
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-CfBDgHqA.mjs";
|
|
8
8
|
const BlockletEditor = lazy(() => import("@blocklet/editor"));
|
|
9
9
|
const Root = styled(Box)`
|
|
10
10
|
.be-editable,
|
|
@@ -13,8 +13,7 @@ import { useEditorConfig, EditorConfigProvider } from "@blocklet/editor/lib/conf
|
|
|
13
13
|
import { lazyWithPreload } from "react-lazy-with-preload";
|
|
14
14
|
import { $getRoot, $createParagraphNode, $createTextNode, KEY_ENTER_COMMAND, COMMAND_PRIORITY_LOW, $getSelection } from "lexical";
|
|
15
15
|
import { $isRootTextContentEmpty } from "@lexical/text";
|
|
16
|
-
import { withTrailingSlash, withQuery
|
|
17
|
-
import joinUrl from "url-join";
|
|
16
|
+
import { joinURL, withTrailingSlash, withQuery } from "ufo";
|
|
18
17
|
import { useLexicalComposerContext } from "@lexical/react/LexicalComposerContext";
|
|
19
18
|
import { ImageNode } from "@blocklet/editor/lib/main/nodes/ImageNode";
|
|
20
19
|
import { VideoNode } from "@blocklet/editor/lib/ext/VideoPlugin/VideoNode";
|
|
@@ -62,6 +61,7 @@ import Skeleton$1 from "@mui/material/Skeleton";
|
|
|
62
61
|
import ReactDOM, { createPortal } from "react-dom";
|
|
63
62
|
import dayjs from "dayjs";
|
|
64
63
|
import relativeTime from "dayjs/plugin/relativeTime";
|
|
64
|
+
import joinUrl from "url-join";
|
|
65
65
|
import mitt from "mitt";
|
|
66
66
|
import CircularProgress$1 from "@mui/material/CircularProgress";
|
|
67
67
|
import { Helmet } from "react-helmet";
|
|
@@ -294,10 +294,6 @@ const blockletExists = (name) => {
|
|
|
294
294
|
const info = getBlockletMountPointInfo(name);
|
|
295
295
|
return (info == null ? void 0 : info.status) === "running";
|
|
296
296
|
};
|
|
297
|
-
const inferDiscussKitApiPrefix = () => {
|
|
298
|
-
const service = getBlockletMountPointInfo("did-comments");
|
|
299
|
-
return service ? joinUrl(service.mountPoint, "/") : "/";
|
|
300
|
-
};
|
|
301
297
|
const getDraftSessionKeyPrefix = () => {
|
|
302
298
|
return "comment-draft-";
|
|
303
299
|
};
|
|
@@ -342,6 +338,7 @@ const mergeSx = (initial, sx) => {
|
|
|
342
338
|
return mergedSx;
|
|
343
339
|
};
|
|
344
340
|
const discussKitMountPoint = (_a = getBlockletMountPointInfo("did-comments")) == null ? void 0 : _a.mountPoint;
|
|
341
|
+
const discussKitUploadsUrl = joinURL(discussKitMountPoint || "", "/uploads");
|
|
345
342
|
const isInDiscussKitApp = discussKitMountPoint && withTrailingSlash(window.blocklet.prefix) === withTrailingSlash(discussKitMountPoint);
|
|
346
343
|
const openProfile = (did, newTab) => {
|
|
347
344
|
if (did) {
|
|
@@ -363,6 +360,7 @@ const utils = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.definePropert
|
|
|
363
360
|
blockletExists,
|
|
364
361
|
copy,
|
|
365
362
|
discussKitMountPoint,
|
|
363
|
+
discussKitUploadsUrl,
|
|
366
364
|
getBlockletMountPointInfo,
|
|
367
365
|
getDiscussKitClientId,
|
|
368
366
|
getDraftSessionKeyPrefix,
|
|
@@ -370,7 +368,6 @@ const utils = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.definePropert
|
|
|
370
368
|
getLastItem,
|
|
371
369
|
getPreference,
|
|
372
370
|
getResizedAvatar,
|
|
373
|
-
inferDiscussKitApiPrefix,
|
|
374
371
|
isInDiscussKitApp,
|
|
375
372
|
mergeSx,
|
|
376
373
|
minDelay,
|
|
@@ -480,14 +477,12 @@ function CmdEnterShortcutPlugin({ callback, shortcut = "CMD_ENTER" }) {
|
|
|
480
477
|
}, [editor, callback]);
|
|
481
478
|
return null;
|
|
482
479
|
}
|
|
483
|
-
const UPLOADS_PREFIX$1 = "/uploads";
|
|
484
|
-
const IMAGE_URL_PREFIX = joinUrl(inferDiscussKitApiPrefix(), UPLOADS_PREFIX$1);
|
|
485
480
|
const originalExportJSON$1 = ImageNode.prototype.exportJSON;
|
|
486
481
|
const ensureLeadingSlash$1 = (str) => str.startsWith("/") ? str : `/${str}`;
|
|
487
482
|
ImageNode.prototype.exportJSON = function exportJSON() {
|
|
488
483
|
const json = originalExportJSON$1.call(this);
|
|
489
|
-
if (json.src && json.src.startsWith(
|
|
490
|
-
json.src = json.src.replace(
|
|
484
|
+
if (json.src && json.src.startsWith(discussKitUploadsUrl)) {
|
|
485
|
+
json.src = json.src.replace(discussKitUploadsUrl, "");
|
|
491
486
|
json.src = ensureLeadingSlash$1(json.src);
|
|
492
487
|
}
|
|
493
488
|
return json;
|
|
@@ -495,8 +490,8 @@ ImageNode.prototype.exportJSON = function exportJSON() {
|
|
|
495
490
|
function imageNodeTransform(node) {
|
|
496
491
|
const targetNode = node;
|
|
497
492
|
const src = targetNode.getSrc();
|
|
498
|
-
if ((src == null ? void 0 : src.startsWith("/")) && !src.startsWith(
|
|
499
|
-
targetNode.setSrc(
|
|
493
|
+
if ((src == null ? void 0 : src.startsWith("/")) && !src.startsWith(discussKitUploadsUrl)) {
|
|
494
|
+
targetNode.setSrc(joinURL(discussKitUploadsUrl, src));
|
|
500
495
|
}
|
|
501
496
|
}
|
|
502
497
|
function ImagePathFixerPlugin() {
|
|
@@ -506,13 +501,12 @@ function ImagePathFixerPlugin() {
|
|
|
506
501
|
}, [editor]);
|
|
507
502
|
return null;
|
|
508
503
|
}
|
|
509
|
-
const UPLOADS_PREFIX = joinUrl(inferDiscussKitApiPrefix(), "/uploads");
|
|
510
504
|
const originalExportJSON = VideoNode.prototype.exportJSON;
|
|
511
505
|
const ensureLeadingSlash = (str) => str.startsWith("/") ? str : `/${str}`;
|
|
512
506
|
VideoNode.prototype.exportJSON = function exportJSON2() {
|
|
513
507
|
const json = originalExportJSON.call(this);
|
|
514
|
-
if (json.src && json.src.startsWith(
|
|
515
|
-
json.src = json.src.replace(
|
|
508
|
+
if (json.src && json.src.startsWith(discussKitUploadsUrl)) {
|
|
509
|
+
json.src = json.src.replace(discussKitUploadsUrl, "");
|
|
516
510
|
json.src = ensureLeadingSlash(json.src);
|
|
517
511
|
}
|
|
518
512
|
return json;
|
|
@@ -520,8 +514,8 @@ VideoNode.prototype.exportJSON = function exportJSON2() {
|
|
|
520
514
|
function VideoNodeTransform(node) {
|
|
521
515
|
const targetNode = node;
|
|
522
516
|
const src = targetNode.getSrc();
|
|
523
|
-
if ((src == null ? void 0 : src.startsWith("/")) && !src.startsWith(
|
|
524
|
-
targetNode.setSrc(
|
|
517
|
+
if ((src == null ? void 0 : src.startsWith("/")) && !src.startsWith(discussKitUploadsUrl)) {
|
|
518
|
+
targetNode.setSrc(joinURL(discussKitUploadsUrl, src));
|
|
525
519
|
}
|
|
526
520
|
}
|
|
527
521
|
function VideoPathFixerPlugin() {
|
|
@@ -2939,16 +2933,18 @@ function CommentList(props) {
|
|
|
2939
2933
|
] });
|
|
2940
2934
|
}
|
|
2941
2935
|
const materialSymbolsUpload = (props) => /* @__PURE__ */ jsx("svg", { viewBox: "0 0 24 24", width: "1.2em", height: "1.2em", ...props, children: /* @__PURE__ */ jsx("path", { fill: "currentColor", d: "M11 16V7.85l-2.6 2.6L7 9l5-5l5 5l-1.4 1.45l-2.6-2.6V16zm-5 4q-.825 0-1.412-.587T4 18v-3h2v3h12v-3h2v3q0 .825-.587 1.413T18 20z" }) });
|
|
2942
|
-
const
|
|
2936
|
+
const getUploadedImageUrl = (imageUrl, width = 320) => {
|
|
2943
2937
|
var _a2;
|
|
2944
|
-
const prefix2 =
|
|
2938
|
+
const prefix2 = joinURL(((_a2 = window.blocklet) == null ? void 0 : _a2.prefix) || "/", "uploads");
|
|
2945
2939
|
let result = imageUrl;
|
|
2946
2940
|
if (imageUrl && imageUrl.startsWith("/") && !imageUrl.startsWith(prefix2)) {
|
|
2947
|
-
result =
|
|
2941
|
+
result = joinURL(prefix2, imageUrl);
|
|
2948
2942
|
const tmp = new URL(result, window.location.origin);
|
|
2949
|
-
|
|
2950
|
-
|
|
2951
|
-
|
|
2943
|
+
if (!imageUrl.endsWith(".gif")) {
|
|
2944
|
+
tmp.searchParams.set("imageFilter", "resize");
|
|
2945
|
+
tmp.searchParams.set("w", width.toString());
|
|
2946
|
+
tmp.searchParams.set("f", "webp");
|
|
2947
|
+
}
|
|
2952
2948
|
return tmp.href;
|
|
2953
2949
|
}
|
|
2954
2950
|
return result;
|
|
@@ -3063,7 +3059,7 @@ function CoverImage({
|
|
|
3063
3059
|
/* @__PURE__ */ jsx(Box, { children: /* @__PURE__ */ jsx(
|
|
3064
3060
|
"img",
|
|
3065
3061
|
{
|
|
3066
|
-
src: url ?
|
|
3062
|
+
src: url ? getUploadedImageUrl(url, width) : "",
|
|
3067
3063
|
loading,
|
|
3068
3064
|
fetchpriority,
|
|
3069
3065
|
style: {
|
|
@@ -3595,7 +3591,7 @@ function BlogListWrapper({
|
|
|
3595
3591
|
}
|
|
3596
3592
|
return /* @__PURE__ */ jsx(BlogList, { ...rest });
|
|
3597
3593
|
}
|
|
3598
|
-
const prefix =
|
|
3594
|
+
const prefix = joinURL(window.location.origin, discussKitMountPoint || "", "blog");
|
|
3599
3595
|
function BlogPermaLink({ slug, onChange, ...rest }) {
|
|
3600
3596
|
return /* @__PURE__ */ jsx(Box, { ...rest, className: "blog-permalink-container", children: /* @__PURE__ */ jsxs(
|
|
3601
3597
|
Box,
|
|
@@ -3653,7 +3649,7 @@ function BlogPermaLink({ slug, onChange, ...rest }) {
|
|
|
3653
3649
|
{
|
|
3654
3650
|
sx: { px: 1 },
|
|
3655
3651
|
onClick: () => {
|
|
3656
|
-
copy(
|
|
3652
|
+
copy(joinURL(prefix, slug));
|
|
3657
3653
|
},
|
|
3658
3654
|
children: /* @__PURE__ */ jsx(ContentCopy, { sx: { fontSize: 18 } })
|
|
3659
3655
|
}
|
|
@@ -4716,7 +4712,7 @@ function Back({ url, fallbackUrl, iconOnly, sx, ...rest }) {
|
|
|
4716
4712
|
}
|
|
4717
4713
|
const tablerSend = (props) => /* @__PURE__ */ jsx("svg", { viewBox: "0 0 24 24", "data-iconify": "tabler", width: "1.2em", height: "1.2em", ...props, children: /* @__PURE__ */ jsx("path", { fill: "none", stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2, d: "M10 14L21 3m0 0l-6.5 18a.55.55 0 0 1-1 0L10 14l-7-3.5a.55.55 0 0 1 0-1z" }) });
|
|
4718
4714
|
const tablerLetterCase = (props) => /* @__PURE__ */ jsx("svg", { viewBox: "0 0 24 24", "data-iconify": "tabler", width: "1.2em", height: "1.2em", ...props, children: /* @__PURE__ */ jsx("path", { fill: "none", stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2, d: "M14 15.5a3.5 3.5 0 1 0 7 0a3.5 3.5 0 1 0-7 0M3 19V8.5a3.5 3.5 0 0 1 7 0V19m-7-6h7m11-1v7" }) });
|
|
4719
|
-
const Editor = lazy(() => import("./editor-
|
|
4715
|
+
const Editor = lazy(() => import("./editor-Be1sUDpj.mjs"));
|
|
4720
4716
|
function LazyEditor(props) {
|
|
4721
4717
|
const fallback2 = /* @__PURE__ */ jsxs(Box, { sx: { px: 3 }, children: [
|
|
4722
4718
|
/* @__PURE__ */ jsx(Skeleton, {}),
|
|
@@ -5889,8 +5885,7 @@ const DefaultApiErrorHandler = ({ request }) => {
|
|
|
5889
5885
|
useDefaultApiErrorHandler({ request });
|
|
5890
5886
|
return null;
|
|
5891
5887
|
};
|
|
5892
|
-
const
|
|
5893
|
-
const baseURL = joinUrl(window.location.origin, apiPrefix);
|
|
5888
|
+
const baseURL = joinURL(window.location.origin, discussKitMountPoint || "");
|
|
5894
5889
|
let cachedTemplateList = null;
|
|
5895
5890
|
function DefaultEditorConfigProvider({
|
|
5896
5891
|
request,
|
|
@@ -5932,14 +5927,14 @@ function DefaultEditorConfigProvider({
|
|
|
5932
5927
|
var _a3;
|
|
5933
5928
|
if (typeof payload === "string") {
|
|
5934
5929
|
const result2 = await request.post(
|
|
5935
|
-
|
|
5930
|
+
joinURL("/api/ai/completions"),
|
|
5936
5931
|
{ prompt: payload },
|
|
5937
5932
|
{ baseURL, timeout: 3e4 }
|
|
5938
5933
|
);
|
|
5939
5934
|
return (_a3 = result2.data) == null ? void 0 : _a3.message;
|
|
5940
5935
|
}
|
|
5941
5936
|
const result = await request.post(
|
|
5942
|
-
|
|
5937
|
+
joinURL(window.location.origin, aiAssistantMountPoint || "", "/api/ai/completions"),
|
|
5943
5938
|
{ ...payload, stream: false },
|
|
5944
5939
|
{ timeout: 3e4 }
|
|
5945
5940
|
);
|
|
@@ -5957,7 +5952,7 @@ function DefaultEditorConfigProvider({
|
|
|
5957
5952
|
return cachedTemplateList;
|
|
5958
5953
|
}
|
|
5959
5954
|
try {
|
|
5960
|
-
const { data = [] } = await request.get(
|
|
5955
|
+
const { data = [] } = await request.get(joinURL("/api/resources/posts"), { baseURL });
|
|
5961
5956
|
cachedTemplateList = data;
|
|
5962
5957
|
return data;
|
|
5963
5958
|
} catch (e) {
|
|
@@ -5971,7 +5966,7 @@ function DefaultEditorConfigProvider({
|
|
|
5971
5966
|
if (!(item == null ? void 0 : item.id) || !(item == null ? void 0 : item.content)) {
|
|
5972
5967
|
throw new Error("item is required");
|
|
5973
5968
|
}
|
|
5974
|
-
const { data } = await request.post(
|
|
5969
|
+
const { data } = await request.post(joinURL("/api/resources/import"), item, { baseURL });
|
|
5975
5970
|
return data;
|
|
5976
5971
|
}
|
|
5977
5972
|
};
|
|
@@ -5988,8 +5983,8 @@ function DefaultEditorConfigProvider({
|
|
|
5988
5983
|
}
|
|
5989
5984
|
},
|
|
5990
5985
|
userService,
|
|
5991
|
-
blockletEmbedEndpoint:
|
|
5992
|
-
openGraphEndpoint:
|
|
5986
|
+
blockletEmbedEndpoint: joinURL(window.location.origin, discussKitMountPoint || "", "/api/embed/check"),
|
|
5987
|
+
openGraphEndpoint: joinURL(window.location.origin, discussKitMountPoint || "", "/api/embed/og"),
|
|
5993
5988
|
AI,
|
|
5994
5989
|
templatePlugin
|
|
5995
5990
|
};
|
|
@@ -12291,7 +12286,7 @@ export {
|
|
|
12291
12286
|
useUploader as aj,
|
|
12292
12287
|
UploaderTrigger as ak,
|
|
12293
12288
|
UploaderProvider as al,
|
|
12294
|
-
|
|
12289
|
+
getUploadedImageUrl as am,
|
|
12295
12290
|
usePointUpContext as an,
|
|
12296
12291
|
PointUpProvider as ao,
|
|
12297
12292
|
ButtonGroup as ap,
|
package/dist/index.es.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export * from "@blocklet/labels";
|
|
2
|
-
import { T, n, W, A, m, ad, B, F, K, J, L, ap, Y, X, $, Z, _, a1, w, C, x, y, E, a5, a6, ah, a8, O, Q, ac, D, ag, af, H, G, b, k, ae, M, P, ao, v, q, R, S, a9, aq, o, a2, a4, ai, al, ak,
|
|
2
|
+
import { T, n, W, A, m, ad, B, F, K, J, L, ap, Y, X, $, Z, _, a1, w, C, x, y, E, a5, a6, ah, a8, O, Q, ac, D, ag, af, H, G, b, k, ae, M, P, ao, v, q, R, S, a9, aq, o, a2, a4, ai, al, ak, ar, N, am, as, l, f, p, r, j, t, h, aa, U, c, a0, z, a7, ab, u, an, d, at, a3, aj, e } from "./index-CfBDgHqA.mjs";
|
|
3
3
|
import "react/jsx-runtime";
|
|
4
4
|
import "react";
|
|
5
5
|
import "@mui/material/Box";
|
|
@@ -62,9 +62,9 @@ export {
|
|
|
62
62
|
ai as UploaderContext,
|
|
63
63
|
al as UploaderProvider,
|
|
64
64
|
ak as UploaderTrigger,
|
|
65
|
-
am as composeImageUrl,
|
|
66
65
|
ar as create,
|
|
67
66
|
N as getBlogLink,
|
|
67
|
+
am as getUploadedImageUrl,
|
|
68
68
|
as as getWsClient,
|
|
69
69
|
l as lexicalUtils,
|
|
70
70
|
f as preferences,
|
package/dist/index.umd.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
(function(global, factory) {
|
|
2
|
-
typeof exports === "object" && typeof module !== "undefined" ? factory(exports, require("@blocklet/labels"), require("react/jsx-runtime"), require("@mui/material/styles"), require("@arcblock/ux/lib/Theme"), require("react"), require("@mui/material"), require("lodash/isNil"), require("@blocklet/editor/lib/config"), require("react-lazy-with-preload"), require("@lexical/react/LexicalComposerContext"), require("lexical"), require("ahooks"), require("@mui/material/Box"), require("@mui/lab/LoadingButton"), require("@mui/icons-material"), require("@arcblock/ux/lib/Locale/context"), require("@mui/material/Alert"), require("lodash/isBoolean"), require("@mui/material/Button"), require("@arcblock/did-connect/lib/Avatar"), require("@mui/material/AvatarGroup"), require("@mui/material/colors"), require("@mui/material/useMediaQuery"), require("@arcblock/ux/lib/DID"), require("@mui/material/Tooltip"), require("react-router-dom"), require("@arcblock/react-hooks"), require("@arcblock/ux/lib/RelativeTime"), require("@mui/material/Chip"), require("@mui/material/Stack"), require("lodash/groupBy"), require("lodash/flatMap"), require("lodash/uniqBy"), require("lodash/trim"), require("@mui/material/Avatar"), require("@mui/icons-material/BrokenImage"), require("@iconify/react"), require("@arcblock/ux/lib/Empty"), require("@arcblock/did-connect/lib/Session"), require("semver-compare"), require("@arcblock/bridge"), require("@mui/icons-material/NotificationsActiveOutlined"), require("@blocklet/editor/lib/ext/CheckboxPlugin"), require("@arcblock/did-connect/lib/Address"), require("@mui/material/MenuItem"), require("clsx"), require("@mui/material/IconButton"), require("@mui/material/Menu"), require("@arcblock/ux/lib/Dialog"), require("lodash/orderBy"), require("@mui/material/Typography"), require("@mui/material/Skeleton"), require("react-dom"), require("
|
|
3
|
-
})(this, function(exports2, labels, jsxRuntime, styles, Theme, react, material, isNil, config, reactLazyWithPreload, LexicalComposerContext, lexical$1, ahooks, Box, LoadingButton, iconsMaterial, context, Alert, isBoolean, Button, DidAvatar, AvatarGroup, colors, useMediaQuery, DID, Tooltip, reactRouterDom, reactHooks, UxRelativeTime, Chip, Stack, groupBy, flatMap, uniqBy, trim, Avatar$1, BrokenImageIcon, react$1, Empty$3, Session, cmp, bridge, NotificationsActiveOutlinedIcon, CheckboxPlugin, DIDAddress, MuiMenuItem, clsx, IconButton$1, MuiMenu, Dialog, orderBy, Typography, Skeleton, ReactDOM,
|
|
2
|
+
typeof exports === "object" && typeof module !== "undefined" ? factory(exports, require("@blocklet/labels"), require("react/jsx-runtime"), require("@mui/material/styles"), require("@arcblock/ux/lib/Theme"), require("react"), require("@mui/material"), require("lodash/isNil"), require("@blocklet/editor/lib/config"), require("react-lazy-with-preload"), require("@lexical/react/LexicalComposerContext"), require("lexical"), require("ahooks"), require("@mui/material/Box"), require("@mui/lab/LoadingButton"), require("@mui/icons-material"), require("@arcblock/ux/lib/Locale/context"), require("@mui/material/Alert"), require("lodash/isBoolean"), require("@mui/material/Button"), require("@arcblock/did-connect/lib/Avatar"), require("@mui/material/AvatarGroup"), require("@mui/material/colors"), require("@mui/material/useMediaQuery"), require("@arcblock/ux/lib/DID"), require("@mui/material/Tooltip"), require("react-router-dom"), require("@arcblock/react-hooks"), require("@arcblock/ux/lib/RelativeTime"), require("@mui/material/Chip"), require("@mui/material/Stack"), require("lodash/groupBy"), require("lodash/flatMap"), require("lodash/uniqBy"), require("lodash/trim"), require("@mui/material/Avatar"), require("@mui/icons-material/BrokenImage"), require("@iconify/react"), require("@arcblock/ux/lib/Empty"), require("@arcblock/did-connect/lib/Session"), require("semver-compare"), require("@arcblock/bridge"), require("@mui/icons-material/NotificationsActiveOutlined"), require("@blocklet/editor/lib/ext/CheckboxPlugin"), require("@arcblock/did-connect/lib/Address"), require("@mui/material/MenuItem"), require("clsx"), require("@mui/material/IconButton"), require("@mui/material/Menu"), require("@arcblock/ux/lib/Dialog"), require("lodash/orderBy"), require("@mui/material/Typography"), require("@mui/material/Skeleton"), require("react-dom"), require("ufo"), require("dayjs"), require("dayjs/plugin/relativeTime"), require("url-join"), require("mitt"), require("@mui/material/CircularProgress"), require("react-helmet"), require("react-flip-toolkit"), require("@mui/material/colors/grey"), require("@blocklet/editor"), require("@mui/material/Fab"), require("lodash/debounce"), require("@blocklet/editor/lib/main/hooks/useIsFocused"), require("@blocklet/editor/lib/ext/BusyPlugin"), require("@mui/material/TextField"), require("@mui/icons-material/Add"), require("axios"), require("@arcblock/ux/lib/Toast"), require("@mui/material/Pagination"), require("unstated-next"), require("js-cookie"), require("@arcblock/ws"), require("@emotion/css"), require("@blocklet/editor/lib/ext/OnContentChangePlugin"), require("@blocklet/editor/lib/ext/ShortcutPlugin"), require("@blocklet/editor/lib/ext/SafeAreaPlugin"), require("@lexical/text"), require("@blocklet/editor/lib/main/nodes/ImageNode"), require("@blocklet/editor/lib/ext/VideoPlugin/VideoNode")) : typeof define === "function" && define.amd ? define(["exports", "@blocklet/labels", "react/jsx-runtime", "@mui/material/styles", "@arcblock/ux/lib/Theme", "react", "@mui/material", "lodash/isNil", "@blocklet/editor/lib/config", "react-lazy-with-preload", "@lexical/react/LexicalComposerContext", "lexical", "ahooks", "@mui/material/Box", "@mui/lab/LoadingButton", "@mui/icons-material", "@arcblock/ux/lib/Locale/context", "@mui/material/Alert", "lodash/isBoolean", "@mui/material/Button", "@arcblock/did-connect/lib/Avatar", "@mui/material/AvatarGroup", "@mui/material/colors", "@mui/material/useMediaQuery", "@arcblock/ux/lib/DID", "@mui/material/Tooltip", "react-router-dom", "@arcblock/react-hooks", "@arcblock/ux/lib/RelativeTime", "@mui/material/Chip", "@mui/material/Stack", "lodash/groupBy", "lodash/flatMap", "lodash/uniqBy", "lodash/trim", "@mui/material/Avatar", "@mui/icons-material/BrokenImage", "@iconify/react", "@arcblock/ux/lib/Empty", "@arcblock/did-connect/lib/Session", "semver-compare", "@arcblock/bridge", "@mui/icons-material/NotificationsActiveOutlined", "@blocklet/editor/lib/ext/CheckboxPlugin", "@arcblock/did-connect/lib/Address", "@mui/material/MenuItem", "clsx", "@mui/material/IconButton", "@mui/material/Menu", "@arcblock/ux/lib/Dialog", "lodash/orderBy", "@mui/material/Typography", "@mui/material/Skeleton", "react-dom", "ufo", "dayjs", "dayjs/plugin/relativeTime", "url-join", "mitt", "@mui/material/CircularProgress", "react-helmet", "react-flip-toolkit", "@mui/material/colors/grey", "@blocklet/editor", "@mui/material/Fab", "lodash/debounce", "@blocklet/editor/lib/main/hooks/useIsFocused", "@blocklet/editor/lib/ext/BusyPlugin", "@mui/material/TextField", "@mui/icons-material/Add", "axios", "@arcblock/ux/lib/Toast", "@mui/material/Pagination", "unstated-next", "js-cookie", "@arcblock/ws", "@emotion/css", "@blocklet/editor/lib/ext/OnContentChangePlugin", "@blocklet/editor/lib/ext/ShortcutPlugin", "@blocklet/editor/lib/ext/SafeAreaPlugin", "@lexical/text", "@blocklet/editor/lib/main/nodes/ImageNode", "@blocklet/editor/lib/ext/VideoPlugin/VideoNode"], factory) : (global = typeof globalThis !== "undefined" ? globalThis : global || self, factory(global.DiscussKitComponents = {}, global.labels, global.jsxRuntime, global.styles, global.Theme, global.react, global.material, global.isNil, global.config, global.reactLazyWithPreload, global.LexicalComposerContext, global.lexical$1, global.ahooks, global.Box, global.LoadingButton, global.iconsMaterial, global.context, global.Alert, global.isBoolean, global.Button, global.DidAvatar, global.AvatarGroup, global.colors, global.useMediaQuery, global.DID, global.Tooltip, global.reactRouterDom, global.reactHooks, global.UxRelativeTime, global.Chip, global.Stack, global.groupBy, global.flatMap, global.uniqBy, global.trim, global.Avatar$1, global.BrokenImageIcon, global.react$1, global.Empty$3, global.Session, global.cmp, global.bridge, global.NotificationsActiveOutlinedIcon, global.CheckboxPlugin, global.DIDAddress, global.MuiMenuItem, global.clsx, global.IconButton$1, global.MuiMenu, global.Dialog, global.orderBy, global.Typography, global.Skeleton, global.ReactDOM, global.ufo, global.dayjs, global.relativeTime, global.joinUrl, global.mitt, global.CircularProgress, global.reactHelmet, global.reactFlipToolkit, global.grey, global.editor$1, global.Fab, global.debounce, global.useIsFocused, global.BusyPlugin, global.TextField, global.AddIcon, global.axios, global.Toast, global.MuiPagination, global.unstatedNext, global.Cookie, global.ws, global.css, global.OnContentChangePlugin, global.ShortcutPlugin$1, global.SafeAreaPlugin, global.text, global.ImageNode, global.VideoNode));
|
|
3
|
+
})(this, function(exports2, labels, jsxRuntime, styles, Theme, react, material, isNil, config, reactLazyWithPreload, LexicalComposerContext, lexical$1, ahooks, Box, LoadingButton, iconsMaterial, context, Alert, isBoolean, Button, DidAvatar, AvatarGroup, colors, useMediaQuery, DID, Tooltip, reactRouterDom, reactHooks, UxRelativeTime, Chip, Stack, groupBy, flatMap, uniqBy, trim, Avatar$1, BrokenImageIcon, react$1, Empty$3, Session, cmp, bridge, NotificationsActiveOutlinedIcon, CheckboxPlugin, DIDAddress, MuiMenuItem, clsx, IconButton$1, MuiMenu, Dialog, orderBy, Typography, Skeleton, ReactDOM, ufo, dayjs, relativeTime, joinUrl, mitt, CircularProgress, reactHelmet, reactFlipToolkit, grey, editor$1, Fab, debounce, useIsFocused, BusyPlugin, TextField, AddIcon, axios, Toast, MuiPagination, unstatedNext, Cookie, ws, css, OnContentChangePlugin, ShortcutPlugin$1, SafeAreaPlugin, text, ImageNode, VideoNode) {
|
|
4
4
|
"use strict";var __defProp = Object.defineProperty;
|
|
5
5
|
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
6
6
|
var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
|
|
@@ -219,10 +219,6 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
219
219
|
const info = getBlockletMountPointInfo(name);
|
|
220
220
|
return (info == null ? void 0 : info.status) === "running";
|
|
221
221
|
};
|
|
222
|
-
const inferDiscussKitApiPrefix = () => {
|
|
223
|
-
const service = getBlockletMountPointInfo("did-comments");
|
|
224
|
-
return service ? joinUrl(service.mountPoint, "/") : "/";
|
|
225
|
-
};
|
|
226
222
|
const getDraftSessionKeyPrefix = () => {
|
|
227
223
|
return "comment-draft-";
|
|
228
224
|
};
|
|
@@ -267,6 +263,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
267
263
|
return mergedSx;
|
|
268
264
|
};
|
|
269
265
|
const discussKitMountPoint = (_a = getBlockletMountPointInfo("did-comments")) == null ? void 0 : _a.mountPoint;
|
|
266
|
+
const discussKitUploadsUrl = ufo.joinURL(discussKitMountPoint || "", "/uploads");
|
|
270
267
|
const isInDiscussKitApp = discussKitMountPoint && ufo.withTrailingSlash(window.blocklet.prefix) === ufo.withTrailingSlash(discussKitMountPoint);
|
|
271
268
|
const openProfile = (did, newTab) => {
|
|
272
269
|
if (did) {
|
|
@@ -288,6 +285,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
288
285
|
blockletExists,
|
|
289
286
|
copy,
|
|
290
287
|
discussKitMountPoint,
|
|
288
|
+
discussKitUploadsUrl,
|
|
291
289
|
getBlockletMountPointInfo,
|
|
292
290
|
getDiscussKitClientId,
|
|
293
291
|
getDraftSessionKeyPrefix,
|
|
@@ -295,7 +293,6 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
295
293
|
getLastItem,
|
|
296
294
|
getPreference,
|
|
297
295
|
getResizedAvatar,
|
|
298
|
-
inferDiscussKitApiPrefix,
|
|
299
296
|
isInDiscussKitApp,
|
|
300
297
|
mergeSx,
|
|
301
298
|
minDelay,
|
|
@@ -405,14 +402,12 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
405
402
|
}, [editor2, callback]);
|
|
406
403
|
return null;
|
|
407
404
|
}
|
|
408
|
-
const UPLOADS_PREFIX$1 = "/uploads";
|
|
409
|
-
const IMAGE_URL_PREFIX = joinUrl(inferDiscussKitApiPrefix(), UPLOADS_PREFIX$1);
|
|
410
405
|
const originalExportJSON$1 = ImageNode.ImageNode.prototype.exportJSON;
|
|
411
406
|
const ensureLeadingSlash$1 = (str) => str.startsWith("/") ? str : `/${str}`;
|
|
412
407
|
ImageNode.ImageNode.prototype.exportJSON = function exportJSON() {
|
|
413
408
|
const json = originalExportJSON$1.call(this);
|
|
414
|
-
if (json.src && json.src.startsWith(
|
|
415
|
-
json.src = json.src.replace(
|
|
409
|
+
if (json.src && json.src.startsWith(discussKitUploadsUrl)) {
|
|
410
|
+
json.src = json.src.replace(discussKitUploadsUrl, "");
|
|
416
411
|
json.src = ensureLeadingSlash$1(json.src);
|
|
417
412
|
}
|
|
418
413
|
return json;
|
|
@@ -420,8 +415,8 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
420
415
|
function imageNodeTransform(node) {
|
|
421
416
|
const targetNode = node;
|
|
422
417
|
const src = targetNode.getSrc();
|
|
423
|
-
if ((src == null ? void 0 : src.startsWith("/")) && !src.startsWith(
|
|
424
|
-
targetNode.setSrc(
|
|
418
|
+
if ((src == null ? void 0 : src.startsWith("/")) && !src.startsWith(discussKitUploadsUrl)) {
|
|
419
|
+
targetNode.setSrc(ufo.joinURL(discussKitUploadsUrl, src));
|
|
425
420
|
}
|
|
426
421
|
}
|
|
427
422
|
function ImagePathFixerPlugin() {
|
|
@@ -431,13 +426,12 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
431
426
|
}, [editor2]);
|
|
432
427
|
return null;
|
|
433
428
|
}
|
|
434
|
-
const UPLOADS_PREFIX = joinUrl(inferDiscussKitApiPrefix(), "/uploads");
|
|
435
429
|
const originalExportJSON = VideoNode.VideoNode.prototype.exportJSON;
|
|
436
430
|
const ensureLeadingSlash = (str) => str.startsWith("/") ? str : `/${str}`;
|
|
437
431
|
VideoNode.VideoNode.prototype.exportJSON = function exportJSON() {
|
|
438
432
|
const json = originalExportJSON.call(this);
|
|
439
|
-
if (json.src && json.src.startsWith(
|
|
440
|
-
json.src = json.src.replace(
|
|
433
|
+
if (json.src && json.src.startsWith(discussKitUploadsUrl)) {
|
|
434
|
+
json.src = json.src.replace(discussKitUploadsUrl, "");
|
|
441
435
|
json.src = ensureLeadingSlash(json.src);
|
|
442
436
|
}
|
|
443
437
|
return json;
|
|
@@ -445,8 +439,8 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
445
439
|
function VideoNodeTransform(node) {
|
|
446
440
|
const targetNode = node;
|
|
447
441
|
const src = targetNode.getSrc();
|
|
448
|
-
if ((src == null ? void 0 : src.startsWith("/")) && !src.startsWith(
|
|
449
|
-
targetNode.setSrc(
|
|
442
|
+
if ((src == null ? void 0 : src.startsWith("/")) && !src.startsWith(discussKitUploadsUrl)) {
|
|
443
|
+
targetNode.setSrc(ufo.joinURL(discussKitUploadsUrl, src));
|
|
450
444
|
}
|
|
451
445
|
}
|
|
452
446
|
function VideoPathFixerPlugin() {
|
|
@@ -2864,16 +2858,18 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
2864
2858
|
] });
|
|
2865
2859
|
}
|
|
2866
2860
|
const materialSymbolsUpload = (props) => /* @__PURE__ */ jsxRuntime.jsx("svg", { viewBox: "0 0 24 24", width: "1.2em", height: "1.2em", ...props, children: /* @__PURE__ */ jsxRuntime.jsx("path", { fill: "currentColor", d: "M11 16V7.85l-2.6 2.6L7 9l5-5l5 5l-1.4 1.45l-2.6-2.6V16zm-5 4q-.825 0-1.412-.587T4 18v-3h2v3h12v-3h2v3q0 .825-.587 1.413T18 20z" }) });
|
|
2867
|
-
const
|
|
2861
|
+
const getUploadedImageUrl = (imageUrl, width = 320) => {
|
|
2868
2862
|
var _a2;
|
|
2869
|
-
const prefix2 =
|
|
2863
|
+
const prefix2 = ufo.joinURL(((_a2 = window.blocklet) == null ? void 0 : _a2.prefix) || "/", "uploads");
|
|
2870
2864
|
let result = imageUrl;
|
|
2871
2865
|
if (imageUrl && imageUrl.startsWith("/") && !imageUrl.startsWith(prefix2)) {
|
|
2872
|
-
result =
|
|
2866
|
+
result = ufo.joinURL(prefix2, imageUrl);
|
|
2873
2867
|
const tmp = new URL(result, window.location.origin);
|
|
2874
|
-
|
|
2875
|
-
|
|
2876
|
-
|
|
2868
|
+
if (!imageUrl.endsWith(".gif")) {
|
|
2869
|
+
tmp.searchParams.set("imageFilter", "resize");
|
|
2870
|
+
tmp.searchParams.set("w", width.toString());
|
|
2871
|
+
tmp.searchParams.set("f", "webp");
|
|
2872
|
+
}
|
|
2877
2873
|
return tmp.href;
|
|
2878
2874
|
}
|
|
2879
2875
|
return result;
|
|
@@ -2988,7 +2984,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
2988
2984
|
/* @__PURE__ */ jsxRuntime.jsx(material.Box, { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
2989
2985
|
"img",
|
|
2990
2986
|
{
|
|
2991
|
-
src: url ?
|
|
2987
|
+
src: url ? getUploadedImageUrl(url, width) : "",
|
|
2992
2988
|
loading,
|
|
2993
2989
|
fetchpriority,
|
|
2994
2990
|
style: {
|
|
@@ -3520,7 +3516,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
3520
3516
|
}
|
|
3521
3517
|
return /* @__PURE__ */ jsxRuntime.jsx(BlogList, { ...rest });
|
|
3522
3518
|
}
|
|
3523
|
-
const prefix =
|
|
3519
|
+
const prefix = ufo.joinURL(window.location.origin, discussKitMountPoint || "", "blog");
|
|
3524
3520
|
function BlogPermaLink({ slug, onChange, ...rest }) {
|
|
3525
3521
|
return /* @__PURE__ */ jsxRuntime.jsx(material.Box, { ...rest, className: "blog-permalink-container", children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
3526
3522
|
material.Box,
|
|
@@ -3578,7 +3574,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
3578
3574
|
{
|
|
3579
3575
|
sx: { px: 1 },
|
|
3580
3576
|
onClick: () => {
|
|
3581
|
-
copy(
|
|
3577
|
+
copy(ufo.joinURL(prefix, slug));
|
|
3582
3578
|
},
|
|
3583
3579
|
children: /* @__PURE__ */ jsxRuntime.jsx(iconsMaterial.ContentCopy, { sx: { fontSize: 18 } })
|
|
3584
3580
|
}
|
|
@@ -5814,8 +5810,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
5814
5810
|
useDefaultApiErrorHandler({ request });
|
|
5815
5811
|
return null;
|
|
5816
5812
|
};
|
|
5817
|
-
const
|
|
5818
|
-
const baseURL = joinUrl(window.location.origin, apiPrefix);
|
|
5813
|
+
const baseURL = ufo.joinURL(window.location.origin, discussKitMountPoint || "");
|
|
5819
5814
|
let cachedTemplateList = null;
|
|
5820
5815
|
function DefaultEditorConfigProvider({
|
|
5821
5816
|
request,
|
|
@@ -5857,14 +5852,14 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
5857
5852
|
var _a3;
|
|
5858
5853
|
if (typeof payload === "string") {
|
|
5859
5854
|
const result2 = await request.post(
|
|
5860
|
-
|
|
5855
|
+
ufo.joinURL("/api/ai/completions"),
|
|
5861
5856
|
{ prompt: payload },
|
|
5862
5857
|
{ baseURL, timeout: 3e4 }
|
|
5863
5858
|
);
|
|
5864
5859
|
return (_a3 = result2.data) == null ? void 0 : _a3.message;
|
|
5865
5860
|
}
|
|
5866
5861
|
const result = await request.post(
|
|
5867
|
-
|
|
5862
|
+
ufo.joinURL(window.location.origin, aiAssistantMountPoint || "", "/api/ai/completions"),
|
|
5868
5863
|
{ ...payload, stream: false },
|
|
5869
5864
|
{ timeout: 3e4 }
|
|
5870
5865
|
);
|
|
@@ -5882,7 +5877,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
5882
5877
|
return cachedTemplateList;
|
|
5883
5878
|
}
|
|
5884
5879
|
try {
|
|
5885
|
-
const { data = [] } = await request.get(
|
|
5880
|
+
const { data = [] } = await request.get(ufo.joinURL("/api/resources/posts"), { baseURL });
|
|
5886
5881
|
cachedTemplateList = data;
|
|
5887
5882
|
return data;
|
|
5888
5883
|
} catch (e) {
|
|
@@ -5896,7 +5891,7 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
5896
5891
|
if (!(item == null ? void 0 : item.id) || !(item == null ? void 0 : item.content)) {
|
|
5897
5892
|
throw new Error("item is required");
|
|
5898
5893
|
}
|
|
5899
|
-
const { data } = await request.post(
|
|
5894
|
+
const { data } = await request.post(ufo.joinURL("/api/resources/import"), item, { baseURL });
|
|
5900
5895
|
return data;
|
|
5901
5896
|
}
|
|
5902
5897
|
};
|
|
@@ -5913,8 +5908,8 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
5913
5908
|
}
|
|
5914
5909
|
},
|
|
5915
5910
|
userService,
|
|
5916
|
-
blockletEmbedEndpoint:
|
|
5917
|
-
openGraphEndpoint:
|
|
5911
|
+
blockletEmbedEndpoint: ufo.joinURL(window.location.origin, discussKitMountPoint || "", "/api/embed/check"),
|
|
5912
|
+
openGraphEndpoint: ufo.joinURL(window.location.origin, discussKitMountPoint || "", "/api/embed/og"),
|
|
5918
5913
|
AI,
|
|
5919
5914
|
templatePlugin
|
|
5920
5915
|
};
|
|
@@ -12256,9 +12251,9 @@ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "sy
|
|
|
12256
12251
|
exports2.UploaderContext = UploaderContext;
|
|
12257
12252
|
exports2.UploaderProvider = UploaderProvider;
|
|
12258
12253
|
exports2.UploaderTrigger = UploaderTrigger;
|
|
12259
|
-
exports2.composeImageUrl = composeImageUrl;
|
|
12260
12254
|
exports2.create = create;
|
|
12261
12255
|
exports2.getBlogLink = getBlogLink;
|
|
12256
|
+
exports2.getUploadedImageUrl = getUploadedImageUrl;
|
|
12262
12257
|
exports2.getWsClient = getWsClient;
|
|
12263
12258
|
exports2.lexicalUtils = lexical;
|
|
12264
12259
|
exports2.preferences = preferences;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@blocklet/discuss-kit-ux",
|
|
3
|
-
"version": "2.1.
|
|
3
|
+
"version": "2.1.10",
|
|
4
4
|
"files": [
|
|
5
5
|
"dist"
|
|
6
6
|
],
|
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
"@arcblock/bridge": "^2.10.36",
|
|
22
22
|
"@arcblock/react-hooks": "^2.10.36",
|
|
23
23
|
"@arcblock/ws": "^1.18.135",
|
|
24
|
-
"@blocklet/uploader": "^0.1.
|
|
24
|
+
"@blocklet/uploader": "^0.1.43",
|
|
25
25
|
"@emotion/css": "^11.13.0",
|
|
26
26
|
"@emotion/react": "^11.13.3",
|
|
27
27
|
"@emotion/styled": "^11.13.0",
|
|
@@ -43,8 +43,8 @@
|
|
|
43
43
|
"ufo": "^1.5.4",
|
|
44
44
|
"unstated-next": "^1.1.0",
|
|
45
45
|
"url-join": "^4.0.1",
|
|
46
|
-
"@blocklet/editor": "^2.1.
|
|
47
|
-
"@blocklet/labels": "^2.1.
|
|
46
|
+
"@blocklet/editor": "^2.1.10",
|
|
47
|
+
"@blocklet/labels": "^2.1.10"
|
|
48
48
|
},
|
|
49
49
|
"peerDependencies": {
|
|
50
50
|
"@arcblock/did-connect": "^2.10.36",
|