@dao42/d42paas-front 0.7.36 → 0.7.38

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.
@@ -41931,6 +41931,196 @@ register$2(LevaInputs.BOOLEAN, boolean$6);
41931
41931
  register$2(LevaInputs.INTERVAL, interval);
41932
41932
  register$2(LevaInputs.VECTOR3D, vector3d);
41933
41933
  register$2(LevaInputs.VECTOR2D, vector2d);
41934
+ const clearCache = () => {
41935
+ var _a2, _b2;
41936
+ localStorage.clear();
41937
+ indexedDB.deleteDatabase("daopaas").onsuccess = () => {
41938
+ };
41939
+ (_b2 = (_a2 = useOT.getState()) == null ? void 0 : _a2.socket) == null ? void 0 : _b2.emit("clearCache");
41940
+ };
41941
+ const adminClearCache = () => {
41942
+ var _a2, _b2;
41943
+ localStorage.clear();
41944
+ indexedDB.deleteDatabase("daopaas").onsuccess = () => {
41945
+ };
41946
+ (_b2 = (_a2 = useOT.getState()) == null ? void 0 : _a2.socket) == null ? void 0 : _b2.emit("adminClearCache");
41947
+ };
41948
+ const guiStore = create$5((set2) => ({
41949
+ showGUI: false,
41950
+ setShowGUI: (arg) => set2(() => ({
41951
+ showGUI: arg
41952
+ }))
41953
+ }));
41954
+ var CRDTKeyToVal;
41955
+ (function(CRDTKeyToVal2) {
41956
+ CRDTKeyToVal2["editor"] = "\u7F16\u8F91\u5668";
41957
+ CRDTKeyToVal2["file"] = "\u6587\u4EF6";
41958
+ CRDTKeyToVal2["terminal"] = "\u7EC8\u7AEF";
41959
+ CRDTKeyToVal2["console"] = "\u8FD0\u884C\u6846";
41960
+ CRDTKeyToVal2["media"] = "\u5F71\u97F3";
41961
+ })(CRDTKeyToVal || (CRDTKeyToVal = {}));
41962
+ var DefaultContext = {
41963
+ color: void 0,
41964
+ size: void 0,
41965
+ className: void 0,
41966
+ style: void 0,
41967
+ attr: void 0
41968
+ };
41969
+ var IconContext = React.createContext && React.createContext(DefaultContext);
41970
+ var __assign$b = globalThis && globalThis.__assign || function() {
41971
+ __assign$b = Object.assign || function(t2) {
41972
+ for (var s2, i = 1, n2 = arguments.length; i < n2; i++) {
41973
+ s2 = arguments[i];
41974
+ for (var p2 in s2)
41975
+ if (Object.prototype.hasOwnProperty.call(s2, p2))
41976
+ t2[p2] = s2[p2];
41977
+ }
41978
+ return t2;
41979
+ };
41980
+ return __assign$b.apply(this, arguments);
41981
+ };
41982
+ var __rest = globalThis && globalThis.__rest || function(s2, e2) {
41983
+ var t2 = {};
41984
+ for (var p2 in s2)
41985
+ if (Object.prototype.hasOwnProperty.call(s2, p2) && e2.indexOf(p2) < 0)
41986
+ t2[p2] = s2[p2];
41987
+ if (s2 != null && typeof Object.getOwnPropertySymbols === "function")
41988
+ for (var i = 0, p2 = Object.getOwnPropertySymbols(s2); i < p2.length; i++) {
41989
+ if (e2.indexOf(p2[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s2, p2[i]))
41990
+ t2[p2[i]] = s2[p2[i]];
41991
+ }
41992
+ return t2;
41993
+ };
41994
+ function Tree2Element(tree2) {
41995
+ return tree2 && tree2.map(function(node2, i) {
41996
+ return React.createElement(node2.tag, __assign$b({
41997
+ key: i
41998
+ }, node2.attr), Tree2Element(node2.child));
41999
+ });
42000
+ }
42001
+ function GenIcon(data) {
42002
+ return function(props2) {
42003
+ return React.createElement(IconBase, __assign$b({
42004
+ attr: __assign$b({}, data.attr)
42005
+ }, props2), Tree2Element(data.child));
42006
+ };
42007
+ }
42008
+ function IconBase(props2) {
42009
+ var elem = function(conf2) {
42010
+ var attr = props2.attr, size2 = props2.size, title = props2.title, svgProps = __rest(props2, ["attr", "size", "title"]);
42011
+ var computedSize = size2 || conf2.size || "1em";
42012
+ var className;
42013
+ if (conf2.className)
42014
+ className = conf2.className;
42015
+ if (props2.className)
42016
+ className = (className ? className + " " : "") + props2.className;
42017
+ return React.createElement("svg", __assign$b({
42018
+ stroke: "currentColor",
42019
+ fill: "currentColor",
42020
+ strokeWidth: "0"
42021
+ }, conf2.attr, attr, svgProps, {
42022
+ className,
42023
+ style: __assign$b(__assign$b({
42024
+ color: props2.color || conf2.color
42025
+ }, conf2.style), props2.style),
42026
+ height: computedSize,
42027
+ width: computedSize,
42028
+ xmlns: "http://www.w3.org/2000/svg"
42029
+ }), title && React.createElement("title", null, title), props2.children);
42030
+ };
42031
+ return IconContext !== void 0 ? React.createElement(IconContext.Consumer, null, function(conf2) {
42032
+ return elem(conf2);
42033
+ }) : elem(DefaultContext);
42034
+ }
42035
+ function MdOutlinePersonOutline(props2) {
42036
+ return GenIcon({ "tag": "svg", "attr": { "viewBox": "0 0 24 24" }, "child": [{ "tag": "path", "attr": { "fill": "none", "d": "M0 0h24v24H0V0z" } }, { "tag": "path", "attr": { "d": "M12 5.9a2.1 2.1 0 110 4.2 2.1 2.1 0 010-4.2m0 9c2.97 0 6.1 1.46 6.1 2.1v1.1H5.9V17c0-.64 3.13-2.1 6.1-2.1M12 4C9.79 4 8 5.79 8 8s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4zm0 9c-2.67 0-8 1.34-8 4v3h16v-3c0-2.66-5.33-4-8-4z" } }] })(props2);
42037
+ }
42038
+ const DrawerComponent = ({
42039
+ drawerOpen,
42040
+ setDrawerOpen,
42041
+ replayList,
42042
+ option
42043
+ }) => {
42044
+ const [filterVal, setFilterVal] = react.exports.useState("");
42045
+ react.exports.useEffect(() => {
42046
+ }, [replayList]);
42047
+ return /* @__PURE__ */ jsxs(Drawer$1, {
42048
+ size: "lg",
42049
+ placement: "right",
42050
+ open: drawerOpen,
42051
+ onClose: () => setDrawerOpen(false),
42052
+ children: [/* @__PURE__ */ jsxs(Drawer$1.Header, {
42053
+ children: [/* @__PURE__ */ jsx(Drawer$1.Title, {
42054
+ children: !option ? "\u56DE\u653E\u5217\u8868" : option.title ? option.title : ""
42055
+ }), /* @__PURE__ */ jsx(Drawer$1.Actions, {
42056
+ children: /* @__PURE__ */ jsxs(InputGroup$1, {
42057
+ children: [/* @__PURE__ */ jsx(InputGroup$1.Addon, {
42058
+ children: /* @__PURE__ */ jsx(MdOutlinePersonOutline, {
42059
+ size: "1.5em"
42060
+ })
42061
+ }), /* @__PURE__ */ jsx(Input$1, {
42062
+ onChange: (evt) => {
42063
+ setFilterVal(evt);
42064
+ }
42065
+ })]
42066
+ })
42067
+ })]
42068
+ }), /* @__PURE__ */ jsx(Drawer$1.Body, {
42069
+ children: replayList ? /* @__PURE__ */ jsx("div", {
42070
+ children: /* @__PURE__ */ jsx("ul", {
42071
+ role: "list",
42072
+ className: "marker:text-sky-400 list-disc pl-5 space-y-3 text-gray-400",
42073
+ children: filterVal ? replayList.filter((item) => userListStore.getState().userList.find((user) => user.uuid === item.userInfo.uuid).username.indexOf(filterVal) >= 0).map((item, index2) => {
42074
+ var _a2, _b2;
42075
+ return /* @__PURE__ */ jsxs("li", {
42076
+ className: "hover:ring-sky-500 cursor-pointer",
42077
+ onClick: () => {
42078
+ setDrawerOpen(false);
42079
+ replay({
42080
+ timestamp: item.timestamp
42081
+ });
42082
+ },
42083
+ children: [CRDTKeyToVal[item.event], /* @__PURE__ */ jsx("span", {
42084
+ className: "mx-4",
42085
+ style: {
42086
+ color: (_a2 = userListStore.getState().userList.find((user) => user.uuid === item.userInfo.uuid)) == null ? void 0 : _a2.color
42087
+ },
42088
+ children: (_b2 = userListStore.getState().userList.find((user) => user.uuid === item.userInfo.uuid)) == null ? void 0 : _b2.username
42089
+ }), /* @__PURE__ */ jsxs("span", {
42090
+ children: ["\u3010", dayjs(Number(item.timestamp)).format("YYYY-DD-MM hh:mm:ss"), "\u3011"]
42091
+ })]
42092
+ }, index2);
42093
+ }) : replayList.map((item, index2) => {
42094
+ var _a2, _b2;
42095
+ return /* @__PURE__ */ jsxs("li", {
42096
+ className: "hover:ring-sky-500 cursor-pointer",
42097
+ onClick: () => {
42098
+ setDrawerOpen(false);
42099
+ replay({
42100
+ userId: item.userInfo.uuid,
42101
+ timestamp: item.timestamp
42102
+ });
42103
+ },
42104
+ children: [CRDTKeyToVal[item.event], /* @__PURE__ */ jsx("span", {
42105
+ className: "mx-4",
42106
+ style: {
42107
+ color: (_a2 = userListStore.getState().userList.find((user) => user.uuid === item.userInfo.uuid)) == null ? void 0 : _a2.color
42108
+ },
42109
+ children: (_b2 = userListStore.getState().userList.find((user) => user.uuid === item.userInfo.uuid)) == null ? void 0 : _b2.username
42110
+ }), /* @__PURE__ */ jsxs("span", {
42111
+ children: ["\u3010", dayjs(Number(item.timestamp)).format("YYYY-DD-MM hh:mm:ss"), "\u3011"]
42112
+ })]
42113
+ }, index2);
42114
+ })
42115
+ })
42116
+ }) : /* @__PURE__ */ jsx(Placeholder$2.Paragraph, {
42117
+ style: {
42118
+ marginTop: 30
42119
+ }
42120
+ })
42121
+ })]
42122
+ });
42123
+ };
41934
42124
  /**
41935
42125
  * @license
41936
42126
  * Copyright 2019 Google LLC
@@ -44188,196 +44378,6 @@ __decorate$1z([
44188
44378
  NinjaKeys = __decorate$1z([
44189
44379
  n$2("ninja-keys")
44190
44380
  ], NinjaKeys);
44191
- const clearCache = () => {
44192
- var _a2, _b2;
44193
- localStorage.clear();
44194
- indexedDB.deleteDatabase("daopaas").onsuccess = () => {
44195
- };
44196
- (_b2 = (_a2 = useOT.getState()) == null ? void 0 : _a2.socket) == null ? void 0 : _b2.emit("clearCache");
44197
- };
44198
- const adminClearCache = () => {
44199
- var _a2, _b2;
44200
- localStorage.clear();
44201
- indexedDB.deleteDatabase("daopaas").onsuccess = () => {
44202
- };
44203
- (_b2 = (_a2 = useOT.getState()) == null ? void 0 : _a2.socket) == null ? void 0 : _b2.emit("adminClearCache");
44204
- };
44205
- const guiStore = create$5((set2) => ({
44206
- showGUI: false,
44207
- setShowGUI: (arg) => set2(() => ({
44208
- showGUI: arg
44209
- }))
44210
- }));
44211
- var CRDTKeyToVal;
44212
- (function(CRDTKeyToVal2) {
44213
- CRDTKeyToVal2["editor"] = "\u7F16\u8F91\u5668";
44214
- CRDTKeyToVal2["file"] = "\u6587\u4EF6";
44215
- CRDTKeyToVal2["terminal"] = "\u7EC8\u7AEF";
44216
- CRDTKeyToVal2["console"] = "\u8FD0\u884C\u6846";
44217
- CRDTKeyToVal2["media"] = "\u5F71\u97F3";
44218
- })(CRDTKeyToVal || (CRDTKeyToVal = {}));
44219
- var DefaultContext = {
44220
- color: void 0,
44221
- size: void 0,
44222
- className: void 0,
44223
- style: void 0,
44224
- attr: void 0
44225
- };
44226
- var IconContext = React.createContext && React.createContext(DefaultContext);
44227
- var __assign$b = globalThis && globalThis.__assign || function() {
44228
- __assign$b = Object.assign || function(t2) {
44229
- for (var s2, i = 1, n2 = arguments.length; i < n2; i++) {
44230
- s2 = arguments[i];
44231
- for (var p2 in s2)
44232
- if (Object.prototype.hasOwnProperty.call(s2, p2))
44233
- t2[p2] = s2[p2];
44234
- }
44235
- return t2;
44236
- };
44237
- return __assign$b.apply(this, arguments);
44238
- };
44239
- var __rest = globalThis && globalThis.__rest || function(s2, e2) {
44240
- var t2 = {};
44241
- for (var p2 in s2)
44242
- if (Object.prototype.hasOwnProperty.call(s2, p2) && e2.indexOf(p2) < 0)
44243
- t2[p2] = s2[p2];
44244
- if (s2 != null && typeof Object.getOwnPropertySymbols === "function")
44245
- for (var i = 0, p2 = Object.getOwnPropertySymbols(s2); i < p2.length; i++) {
44246
- if (e2.indexOf(p2[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s2, p2[i]))
44247
- t2[p2[i]] = s2[p2[i]];
44248
- }
44249
- return t2;
44250
- };
44251
- function Tree2Element(tree2) {
44252
- return tree2 && tree2.map(function(node2, i) {
44253
- return React.createElement(node2.tag, __assign$b({
44254
- key: i
44255
- }, node2.attr), Tree2Element(node2.child));
44256
- });
44257
- }
44258
- function GenIcon(data) {
44259
- return function(props2) {
44260
- return React.createElement(IconBase, __assign$b({
44261
- attr: __assign$b({}, data.attr)
44262
- }, props2), Tree2Element(data.child));
44263
- };
44264
- }
44265
- function IconBase(props2) {
44266
- var elem = function(conf2) {
44267
- var attr = props2.attr, size2 = props2.size, title = props2.title, svgProps = __rest(props2, ["attr", "size", "title"]);
44268
- var computedSize = size2 || conf2.size || "1em";
44269
- var className;
44270
- if (conf2.className)
44271
- className = conf2.className;
44272
- if (props2.className)
44273
- className = (className ? className + " " : "") + props2.className;
44274
- return React.createElement("svg", __assign$b({
44275
- stroke: "currentColor",
44276
- fill: "currentColor",
44277
- strokeWidth: "0"
44278
- }, conf2.attr, attr, svgProps, {
44279
- className,
44280
- style: __assign$b(__assign$b({
44281
- color: props2.color || conf2.color
44282
- }, conf2.style), props2.style),
44283
- height: computedSize,
44284
- width: computedSize,
44285
- xmlns: "http://www.w3.org/2000/svg"
44286
- }), title && React.createElement("title", null, title), props2.children);
44287
- };
44288
- return IconContext !== void 0 ? React.createElement(IconContext.Consumer, null, function(conf2) {
44289
- return elem(conf2);
44290
- }) : elem(DefaultContext);
44291
- }
44292
- function MdOutlinePersonOutline(props2) {
44293
- return GenIcon({ "tag": "svg", "attr": { "viewBox": "0 0 24 24" }, "child": [{ "tag": "path", "attr": { "fill": "none", "d": "M0 0h24v24H0V0z" } }, { "tag": "path", "attr": { "d": "M12 5.9a2.1 2.1 0 110 4.2 2.1 2.1 0 010-4.2m0 9c2.97 0 6.1 1.46 6.1 2.1v1.1H5.9V17c0-.64 3.13-2.1 6.1-2.1M12 4C9.79 4 8 5.79 8 8s1.79 4 4 4 4-1.79 4-4-1.79-4-4-4zm0 9c-2.67 0-8 1.34-8 4v3h16v-3c0-2.66-5.33-4-8-4z" } }] })(props2);
44294
- }
44295
- const DrawerComponent = ({
44296
- drawerOpen,
44297
- setDrawerOpen,
44298
- replayList,
44299
- option
44300
- }) => {
44301
- const [filterVal, setFilterVal] = react.exports.useState("");
44302
- react.exports.useEffect(() => {
44303
- }, [replayList]);
44304
- return /* @__PURE__ */ jsxs(Drawer$1, {
44305
- size: "lg",
44306
- placement: "right",
44307
- open: drawerOpen,
44308
- onClose: () => setDrawerOpen(false),
44309
- children: [/* @__PURE__ */ jsxs(Drawer$1.Header, {
44310
- children: [/* @__PURE__ */ jsx(Drawer$1.Title, {
44311
- children: !option ? "\u56DE\u653E\u5217\u8868" : option.title ? option.title : ""
44312
- }), /* @__PURE__ */ jsx(Drawer$1.Actions, {
44313
- children: /* @__PURE__ */ jsxs(InputGroup$1, {
44314
- children: [/* @__PURE__ */ jsx(InputGroup$1.Addon, {
44315
- children: /* @__PURE__ */ jsx(MdOutlinePersonOutline, {
44316
- size: "1.5em"
44317
- })
44318
- }), /* @__PURE__ */ jsx(Input$1, {
44319
- onChange: (evt) => {
44320
- setFilterVal(evt);
44321
- }
44322
- })]
44323
- })
44324
- })]
44325
- }), /* @__PURE__ */ jsx(Drawer$1.Body, {
44326
- children: replayList ? /* @__PURE__ */ jsx("div", {
44327
- children: /* @__PURE__ */ jsx("ul", {
44328
- role: "list",
44329
- className: "marker:text-sky-400 list-disc pl-5 space-y-3 text-gray-400",
44330
- children: filterVal ? replayList.filter((item) => userListStore.getState().userList.find((user) => user.uuid === item.userInfo.uuid).username.indexOf(filterVal) >= 0).map((item, index2) => {
44331
- var _a2, _b2;
44332
- return /* @__PURE__ */ jsxs("li", {
44333
- className: "hover:ring-sky-500 cursor-pointer",
44334
- onClick: () => {
44335
- setDrawerOpen(false);
44336
- replay({
44337
- timestamp: item.timestamp
44338
- });
44339
- },
44340
- children: [CRDTKeyToVal[item.event], /* @__PURE__ */ jsx("span", {
44341
- className: "mx-4",
44342
- style: {
44343
- color: (_a2 = userListStore.getState().userList.find((user) => user.uuid === item.userInfo.uuid)) == null ? void 0 : _a2.color
44344
- },
44345
- children: (_b2 = userListStore.getState().userList.find((user) => user.uuid === item.userInfo.uuid)) == null ? void 0 : _b2.username
44346
- }), /* @__PURE__ */ jsxs("span", {
44347
- children: ["\u3010", dayjs(Number(item.timestamp)).format("YYYY-DD-MM hh:mm:ss"), "\u3011"]
44348
- })]
44349
- }, index2);
44350
- }) : replayList.map((item, index2) => {
44351
- var _a2, _b2;
44352
- return /* @__PURE__ */ jsxs("li", {
44353
- className: "hover:ring-sky-500 cursor-pointer",
44354
- onClick: () => {
44355
- setDrawerOpen(false);
44356
- replay({
44357
- userId: item.userInfo.uuid,
44358
- timestamp: item.timestamp
44359
- });
44360
- },
44361
- children: [CRDTKeyToVal[item.event], /* @__PURE__ */ jsx("span", {
44362
- className: "mx-4",
44363
- style: {
44364
- color: (_a2 = userListStore.getState().userList.find((user) => user.uuid === item.userInfo.uuid)) == null ? void 0 : _a2.color
44365
- },
44366
- children: (_b2 = userListStore.getState().userList.find((user) => user.uuid === item.userInfo.uuid)) == null ? void 0 : _b2.username
44367
- }), /* @__PURE__ */ jsxs("span", {
44368
- children: ["\u3010", dayjs(Number(item.timestamp)).format("YYYY-DD-MM hh:mm:ss"), "\u3011"]
44369
- })]
44370
- }, index2);
44371
- })
44372
- })
44373
- }) : /* @__PURE__ */ jsx(Placeholder$2.Paragraph, {
44374
- style: {
44375
- marginTop: 30
44376
- }
44377
- })
44378
- })]
44379
- });
44380
- };
44381
44381
  const CmdKey = () => {
44382
44382
  const ninjaKeys = react.exports.useRef(null);
44383
44383
  const actions = [
@@ -44751,12 +44751,20 @@ class DaoPaaS {
44751
44751
  userListStore.subscribe((next2, pre) => {
44752
44752
  this.trigger(lodash$2.exports.pick(pre, ["userList"]), lodash$2.exports.pick(next2, ["userList"]));
44753
44753
  });
44754
+ shadowUserStore.subscribe((next2, pre) => {
44755
+ this.trigger({
44756
+ followingUser: pre.shadowUser
44757
+ }, {
44758
+ followingUser: pre.shadowUser
44759
+ });
44760
+ });
44754
44761
  }
44755
44762
  trigger(_d2, data) {
44756
44763
  if (_d2 === "error") {
44757
44764
  this.on(data, _d2);
44758
44765
  return;
44759
44766
  }
44767
+ console.log(data);
44760
44768
  this.on(data);
44761
44769
  }
44762
44770
  clearIDB(callback) {
@@ -48432,6 +48440,20 @@ AwaitingWithBuffer.prototype.resend = function(client2) {
48432
48440
  client2.sendOperation(client2.revision, this.outstanding);
48433
48441
  };
48434
48442
  const FROZEN_CONTROL_COMPONENTS = ["editor", "file", "terminal"];
48443
+ newStyled.div`
48444
+ position: absolute;
48445
+ right: 0;
48446
+ top: -1.5rem;
48447
+ padding: 0 2rem;
48448
+ background: ${(props2) => props2.shadowUser.color}5c;
48449
+ border: 1px solid ${(props2) => props2.shadowUser.color};
48450
+ border-radius: 5px 5px 0 0;
48451
+
48452
+ span {
48453
+ font-size: 12px;
48454
+ color: #fff;
48455
+ }
48456
+ `;
48435
48457
  const FollowLayoutWrapper = newStyled.div`
48436
48458
  width: 100%;
48437
48459
  height: 100%;
@@ -48459,7 +48481,7 @@ const FollowLayout = ({
48459
48481
  const isPass = asyncType === name && (shadowUser == null ? void 0 : shadowUser.uuid) && !IsMe(shadowUser);
48460
48482
  return /* @__PURE__ */ jsxs(FollowLayoutWrapper, {
48461
48483
  user: shadowUser,
48462
- className: `${className} follow-layout`,
48484
+ className: `follow-layout`,
48463
48485
  isPass,
48464
48486
  onClick: () => {
48465
48487
  if (!(shadowUser == null ? void 0 : shadowUser.uuid))
@@ -229354,12 +229376,44 @@ const Index = (props2) => {
229354
229376
  react.exports.useEffect(() => {
229355
229377
  setUrl(playgroundInfo.url);
229356
229378
  }, [playgroundInfo]);
229379
+ dockerState.subscribe((state2) => state2, (pre, next2) => {
229380
+ });
229381
+ oTStore.subscribe((state2) => state2, (pre, next2) => {
229382
+ });
229383
+ ErrorMsgState.subscribe((state2) => state2, (next2, pre) => {
229384
+ Toast.message({
229385
+ type: "error",
229386
+ content: next2.message.content,
229387
+ placement: "topCenter"
229388
+ });
229389
+ });
229390
+ userListStore.subscribe((next2, pre) => {
229391
+ });
229392
+ shadowUserStore.subscribe((next2, pre) => {
229393
+ if (next2.shadowUser.userId) {
229394
+ Toast.message({
229395
+ type: "success",
229396
+ content: `\u6B63\u5728\u8DDF\u968F${next2.shadowUser.username}`,
229397
+ placement: "topCenter"
229398
+ });
229399
+ } else {
229400
+ Toast.message({
229401
+ type: "success",
229402
+ content: `\u5DF2\u9000\u51FA\u8DDF\u968F\u6A21\u5F0F`,
229403
+ placement: "topCenter"
229404
+ });
229405
+ }
229406
+ });
229357
229407
  react.exports.useEffect(() => {
229358
229408
  props2.playgroundId && (socket2 == null ? void 0 : socket2.emit("playgroundInfo", JSON.stringify({
229359
229409
  messageId: "1",
229360
229410
  playgroundId: props2.playgroundId
229361
229411
  })));
229362
229412
  }, [props2.playgroundId]);
229413
+ react.exports.useEffect(() => {
229414
+ var _a2;
229415
+ (_a2 = useOT.getState().socket) == null ? void 0 : _a2.emit("active");
229416
+ }, []);
229363
229417
  return /* @__PURE__ */ jsx(Fragment, {
229364
229418
  children: /* @__PURE__ */ jsxs(MainLayout, {
229365
229419
  className: "flex flex-col",
@@ -229475,7 +229529,7 @@ const HeaderComponent = () => {
229475
229529
  children: userListStore.getState().userList.map((item, index2) => {
229476
229530
  return /* @__PURE__ */ jsx("div", {
229477
229531
  onClick: () => {
229478
- shadowUserStore.getState().switchShadowUser(item);
229532
+ shadowUserStore.getState().switchShadowUser(item.userId);
229479
229533
  console.log(shadowUserStore.getState().shadowUser);
229480
229534
  },
229481
229535
  className: "-ml-2.5 z-0 avatar-hover",