@dao42/d42paas-front 0.7.50 → 0.7.53

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.
@@ -15087,14 +15087,29 @@ create$5((set2) => ({
15087
15087
  syncCursor: arg
15088
15088
  }))
15089
15089
  }));
15090
+ const followingUserStore = create$5((set2) => ({
15091
+ followingUsers: [],
15092
+ setFollowingUsers: (arg) => set2(() => ({
15093
+ followingUsers: arg
15094
+ }))
15095
+ }));
15090
15096
  const shadowUserStore = create$5(persist((set2) => ({
15091
15097
  shadowUser: {},
15092
15098
  switchShadowUser: (id2) => set2(() => {
15099
+ const followingUser = userStore.getState().userInfo;
15100
+ const io = useOT.getState().socket;
15093
15101
  let user;
15094
15102
  if (id2 !== void 0) {
15095
15103
  user = userListStore.getState().userList.find((user2) => user2.userId === id2);
15096
15104
  console.log(`\u5DF2\u5207\u6362\u81F3\u3010${user.username}\u3011\u89C6\u89D2`);
15105
+ io == null ? void 0 : io.emit("following", {
15106
+ user,
15107
+ followingUser
15108
+ });
15097
15109
  } else {
15110
+ io == null ? void 0 : io.emit("unFollowing", {
15111
+ followingUser
15112
+ });
15098
15113
  console.log(`\u5DF2\u9000\u51FA\u8DDF\u968F\u89C6\u89D2`);
15099
15114
  }
15100
15115
  return {
@@ -28602,6 +28617,24 @@ const PlaygroundInit = (arg) => {
28602
28617
  })];
28603
28618
  setUserList(userInfoList);
28604
28619
  });
28620
+ io.on("following", (d2) => {
28621
+ const users_server = JSON.parse(d2);
28622
+ const followingUsers = users_server.filter(({
28623
+ user
28624
+ }) => IsMe(user));
28625
+ followingUserStore.getState().setFollowingUsers(followingUsers.map(({
28626
+ followingUser
28627
+ }) => followingUser));
28628
+ });
28629
+ io.on("unFollowing", (d2) => {
28630
+ const {
28631
+ followingUsers,
28632
+ setFollowingUsers
28633
+ } = followingUserStore.getState();
28634
+ const user = JSON.parse(d2);
28635
+ followingUsers.splice(lodash$2.exports.findIndex(followingUsers, (f2) => f2.userId === user.followingUser.userId), 1);
28636
+ setFollowingUsers(followingUsers);
28637
+ });
28605
28638
  io.on("playgroundInfo", (data) => {
28606
28639
  var _a2;
28607
28640
  const {
@@ -44766,6 +44799,13 @@ class DaoPaaS {
44766
44799
  followingUser: pre.shadowUser
44767
44800
  });
44768
44801
  });
44802
+ followingUserStore.subscribe((next2, pre) => {
44803
+ this.trigger({
44804
+ usersFollowYou: pre.followingUsers
44805
+ }, {
44806
+ usersFollowYou: pre.followingUsers
44807
+ });
44808
+ });
44769
44809
  }
44770
44810
  trigger(_d2, data) {
44771
44811
  if (_d2 === "error") {
@@ -44877,14 +44917,14 @@ class DaoPaaS {
44877
44917
  props: arg.props || omitObj
44878
44918
  });
44879
44919
  break;
44880
- case "Browser":
44881
- this.Browser({
44920
+ case "Shell":
44921
+ this.Shell({
44882
44922
  container: arg.container,
44883
44923
  props: arg.props || omitObj
44884
44924
  });
44885
44925
  break;
44886
- case "Shell":
44887
- this.Shell({
44926
+ case "Browser":
44927
+ this.Browser({
44888
44928
  container: arg.container,
44889
44929
  props: arg.props || omitObj
44890
44930
  });
@@ -174561,8 +174601,8 @@ const FileTree = ({
174561
174601
  return /* @__PURE__ */ jsx(FollowLayout, {
174562
174602
  name: "file",
174563
174603
  children: /* @__PURE__ */ jsxs(TreeRootLayout, {
174604
+ className: "tree-root-containe",
174564
174605
  ref: treeRef,
174565
- className: `tree-root-layout`,
174566
174606
  dropBgColor,
174567
174607
  dropTextColor,
174568
174608
  hoverBgColor,
@@ -174946,13 +174986,21 @@ const EditorLayout = newStyled.div`
174946
174986
  }
174947
174987
 
174948
174988
  .margin-view-overlays {
174949
- background-color: ${(props2) => props2.theme.marginViewOverlays};
174989
+ background-color: ${(props2) => props2.theme.marginViewOverlaysColor};
174950
174990
 
174951
174991
  .line-numbers {
174952
- color: ${(props2) => props2.theme.lineNumbers};
174953
-
174992
+ color: ${(props2) => props2.theme.lineNumbersColor};
174993
+ width: ${(props2) => {
174994
+ var _a2;
174995
+ return (_a2 = props2.theme.lineNumbersWidth) != null ? _a2 : "18px";
174996
+ }} !important;
174997
+ left: ${(props2) => {
174998
+ var _a2;
174999
+ return (_a2 = props2.theme.lineNumbersLeft) != null ? _a2 : "36px";
175000
+ }} !important;
174954
175001
  &.active-line-number {
174955
- color: ${(props2) => props2.theme.activeLineNumber};
175002
+ /* color: ${(props2) => props2.theme.activeLineNumberColor}; */
175003
+ color: ${(props2) => props2.theme.activeLineNumberColor};
174956
175004
  }
174957
175005
  }
174958
175006
  }
@@ -220369,214 +220417,351 @@ const Markdown = ({
220369
220417
  })
220370
220418
  }), document.body);
220371
220419
  };
220372
- const Dracula = {
220373
- base: "vs-dark",
220374
- inherit: true,
220375
- rules: [
220376
- {
220377
- background: "282a36",
220378
- token: ""
220379
- },
220380
- {
220381
- foreground: "6272a4",
220382
- token: "comment"
220383
- },
220384
- {
220385
- foreground: "f1fa8c",
220386
- token: "string"
220387
- },
220388
- {
220389
- foreground: "bd93f9",
220390
- token: "constant.numeric"
220391
- },
220392
- {
220393
- foreground: "bd93f9",
220394
- token: "constant.language"
220395
- },
220396
- {
220397
- foreground: "bd93f9",
220398
- token: "constant.character"
220399
- },
220400
- {
220401
- foreground: "bd93f9",
220402
- token: "constant.other"
220403
- },
220404
- {
220405
- foreground: "ffb86c",
220406
- token: "variable.other.readwrite.instance"
220407
- },
220408
- {
220409
- foreground: "ff79c6",
220410
- token: "constant.character.escaped"
220411
- },
220412
- {
220413
- foreground: "ff79c6",
220414
- token: "constant.character.escape"
220415
- },
220416
- {
220417
- foreground: "ff79c6",
220418
- token: "string source"
220419
- },
220420
- {
220421
- foreground: "ff79c6",
220422
- token: "string source.ruby"
220423
- },
220424
- {
220425
- foreground: "ff79c6",
220426
- token: "keyword"
220427
- },
220428
- {
220429
- foreground: "ff79c6",
220430
- token: "storage"
220431
- },
220432
- {
220433
- foreground: "8be9fd",
220434
- fontStyle: "italic",
220435
- token: "storage.type"
220436
- },
220437
- {
220438
- foreground: "50fa7b",
220439
- fontStyle: "underline",
220440
- token: "entity.name.class"
220441
- },
220442
- {
220443
- foreground: "50fa7b",
220444
- fontStyle: "italic underline",
220445
- token: "entity.other.inherited-class"
220446
- },
220447
- {
220448
- foreground: "50fa7b",
220449
- token: "entity.name.function"
220450
- },
220451
- {
220452
- foreground: "ffb86c",
220453
- fontStyle: "italic",
220454
- token: "variable.parameter"
220455
- },
220456
- {
220457
- foreground: "ff79c6",
220458
- token: "entity.name.tag"
220459
- },
220460
- {
220461
- foreground: "50fa7b",
220462
- token: "entity.other.attribute-name"
220463
- },
220464
- {
220465
- foreground: "8be9fd",
220466
- token: "support.function"
220467
- },
220468
- {
220469
- foreground: "6be5fd",
220470
- token: "support.constant"
220471
- },
220472
- {
220473
- foreground: "66d9ef",
220474
- fontStyle: " italic",
220475
- token: "support.type"
220476
- },
220477
- {
220478
- foreground: "66d9ef",
220479
- fontStyle: " italic",
220480
- token: "support.class"
220481
- },
220482
- {
220483
- foreground: "f8f8f0",
220484
- background: "ff79c6",
220485
- token: "invalid"
220486
- },
220487
- {
220488
- foreground: "f8f8f0",
220489
- background: "bd93f9",
220490
- token: "invalid.deprecated"
220491
- },
220492
- {
220493
- foreground: "cfcfc2",
220494
- token: "meta.structure.dictionary.json string.quoted.double.json"
220495
- },
220496
- {
220497
- foreground: "6272a4",
220498
- token: "meta.diff"
220499
- },
220500
- {
220501
- foreground: "6272a4",
220502
- token: "meta.diff.header"
220503
- },
220504
- {
220505
- foreground: "ff79c6",
220506
- token: "markup.deleted"
220507
- },
220508
- {
220509
- foreground: "50fa7b",
220510
- token: "markup.inserted"
220511
- },
220512
- {
220513
- foreground: "e6db74",
220514
- token: "markup.changed"
220515
- },
220516
- {
220517
- foreground: "bd93f9",
220518
- token: "constant.numeric.line-number.find-in-files - match"
220519
- },
220520
- {
220521
- foreground: "e6db74",
220522
- token: "entity.name.filename"
220523
- },
220524
- {
220525
- foreground: "f83333",
220526
- token: "message.error"
220527
- },
220528
- {
220529
- foreground: "eeeeee",
220530
- token: "punctuation.definition.string.begin.json - meta.structure.dictionary.value.json"
220531
- },
220532
- {
220533
- foreground: "eeeeee",
220534
- token: "punctuation.definition.string.end.json - meta.structure.dictionary.value.json"
220535
- },
220536
- {
220537
- foreground: "8be9fd",
220538
- token: "meta.structure.dictionary.json string.quoted.double.json"
220539
- },
220540
- {
220541
- foreground: "f1fa8c",
220542
- token: "meta.structure.dictionary.value.json string.quoted.double.json"
220543
- },
220544
- {
220545
- foreground: "50fa7b",
220546
- token: "meta meta meta meta meta meta meta.structure.dictionary.value string"
220547
- },
220548
- {
220549
- foreground: "ffb86c",
220550
- token: "meta meta meta meta meta meta.structure.dictionary.value string"
220551
- },
220552
- {
220553
- foreground: "ff79c6",
220554
- token: "meta meta meta meta meta.structure.dictionary.value string"
220555
- },
220556
- {
220557
- foreground: "bd93f9",
220558
- token: "meta meta meta meta.structure.dictionary.value string"
220559
- },
220560
- {
220561
- foreground: "50fa7b",
220562
- token: "meta meta meta.structure.dictionary.value string"
220563
- },
220564
- {
220565
- foreground: "ffb86c",
220566
- token: "meta meta.structure.dictionary.value string"
220420
+ const Dracula = (theme) => {
220421
+ var _a2, _b2, _c2, _d2, _e2, _f2;
220422
+ return {
220423
+ base: "vs-dark",
220424
+ inherit: true,
220425
+ rules: [
220426
+ {
220427
+ background: "282a36",
220428
+ token: ""
220429
+ },
220430
+ {
220431
+ foreground: "6272a4",
220432
+ token: "comment"
220433
+ },
220434
+ {
220435
+ foreground: "f1fa8c",
220436
+ token: "string"
220437
+ },
220438
+ {
220439
+ foreground: "bd93f9",
220440
+ token: "constant.numeric"
220441
+ },
220442
+ {
220443
+ foreground: "bd93f9",
220444
+ token: "constant.language"
220445
+ },
220446
+ {
220447
+ foreground: "bd93f9",
220448
+ token: "constant.character"
220449
+ },
220450
+ {
220451
+ foreground: "bd93f9",
220452
+ token: "constant.other"
220453
+ },
220454
+ {
220455
+ foreground: "ffb86c",
220456
+ token: "variable.other.readwrite.instance"
220457
+ },
220458
+ {
220459
+ foreground: "ff79c6",
220460
+ token: "constant.character.escaped"
220461
+ },
220462
+ {
220463
+ foreground: "ff79c6",
220464
+ token: "constant.character.escape"
220465
+ },
220466
+ {
220467
+ foreground: "ff79c6",
220468
+ token: "string source"
220469
+ },
220470
+ {
220471
+ foreground: "ff79c6",
220472
+ token: "string source.ruby"
220473
+ },
220474
+ {
220475
+ foreground: "ff79c6",
220476
+ token: "keyword"
220477
+ },
220478
+ {
220479
+ foreground: "ff79c6",
220480
+ token: "storage"
220481
+ },
220482
+ {
220483
+ foreground: "8be9fd",
220484
+ fontStyle: "italic",
220485
+ token: "storage.type"
220486
+ },
220487
+ {
220488
+ foreground: "50fa7b",
220489
+ fontStyle: "underline",
220490
+ token: "entity.name.class"
220491
+ },
220492
+ {
220493
+ foreground: "50fa7b",
220494
+ fontStyle: "italic underline",
220495
+ token: "entity.other.inherited-class"
220496
+ },
220497
+ {
220498
+ foreground: "50fa7b",
220499
+ token: "entity.name.function"
220500
+ },
220501
+ {
220502
+ foreground: "ffb86c",
220503
+ fontStyle: "italic",
220504
+ token: "variable.parameter"
220505
+ },
220506
+ {
220507
+ foreground: "ff79c6",
220508
+ token: "entity.name.tag"
220509
+ },
220510
+ {
220511
+ foreground: "50fa7b",
220512
+ token: "entity.other.attribute-name"
220513
+ },
220514
+ {
220515
+ foreground: "8be9fd",
220516
+ token: "support.function"
220517
+ },
220518
+ {
220519
+ foreground: "6be5fd",
220520
+ token: "support.constant"
220521
+ },
220522
+ {
220523
+ foreground: "66d9ef",
220524
+ fontStyle: " italic",
220525
+ token: "support.type"
220526
+ },
220527
+ {
220528
+ foreground: "66d9ef",
220529
+ fontStyle: " italic",
220530
+ token: "support.class"
220531
+ },
220532
+ {
220533
+ foreground: "f8f8f0",
220534
+ background: "ff79c6",
220535
+ token: "invalid"
220536
+ },
220537
+ {
220538
+ foreground: "f8f8f0",
220539
+ background: "bd93f9",
220540
+ token: "invalid.deprecated"
220541
+ },
220542
+ {
220543
+ foreground: "cfcfc2",
220544
+ token: "meta.structure.dictionary.json string.quoted.double.json"
220545
+ },
220546
+ {
220547
+ foreground: "6272a4",
220548
+ token: "meta.diff"
220549
+ },
220550
+ {
220551
+ foreground: "6272a4",
220552
+ token: "meta.diff.header"
220553
+ },
220554
+ {
220555
+ foreground: "ff79c6",
220556
+ token: "markup.deleted"
220557
+ },
220558
+ {
220559
+ foreground: "50fa7b",
220560
+ token: "markup.inserted"
220561
+ },
220562
+ {
220563
+ foreground: "e6db74",
220564
+ token: "markup.changed"
220565
+ },
220566
+ {
220567
+ foreground: "bd93f9",
220568
+ token: "constant.numeric.line-number.find-in-files - match"
220569
+ },
220570
+ {
220571
+ foreground: "e6db74",
220572
+ token: "entity.name.filename"
220573
+ },
220574
+ {
220575
+ foreground: "f83333",
220576
+ token: "message.error"
220577
+ },
220578
+ {
220579
+ foreground: "eeeeee",
220580
+ token: "punctuation.definition.string.begin.json - meta.structure.dictionary.value.json"
220581
+ },
220582
+ {
220583
+ foreground: "eeeeee",
220584
+ token: "punctuation.definition.string.end.json - meta.structure.dictionary.value.json"
220585
+ },
220586
+ {
220587
+ foreground: "8be9fd",
220588
+ token: "meta.structure.dictionary.json string.quoted.double.json"
220589
+ },
220590
+ {
220591
+ foreground: "f1fa8c",
220592
+ token: "meta.structure.dictionary.value.json string.quoted.double.json"
220593
+ },
220594
+ {
220595
+ foreground: "50fa7b",
220596
+ token: "meta meta meta meta meta meta meta.structure.dictionary.value string"
220597
+ },
220598
+ {
220599
+ foreground: "ffb86c",
220600
+ token: "meta meta meta meta meta meta.structure.dictionary.value string"
220601
+ },
220602
+ {
220603
+ foreground: "ff79c6",
220604
+ token: "meta meta meta meta meta.structure.dictionary.value string"
220605
+ },
220606
+ {
220607
+ foreground: "bd93f9",
220608
+ token: "meta meta meta meta.structure.dictionary.value string"
220609
+ },
220610
+ {
220611
+ foreground: "50fa7b",
220612
+ token: "meta meta meta.structure.dictionary.value string"
220613
+ },
220614
+ {
220615
+ foreground: "ffb86c",
220616
+ token: "meta meta.structure.dictionary.value string"
220617
+ }
220618
+ ],
220619
+ colors: {
220620
+ "editor.foreground": (_b2 = (_a2 = theme == null ? void 0 : theme.editor) == null ? void 0 : _a2.foreground) != null ? _b2 : "#f8f8f0",
220621
+ "editor.background": (_d2 = (_c2 = theme == null ? void 0 : theme.editor) == null ? void 0 : _c2.background) != null ? _d2 : "#15171c",
220622
+ "editor.lineHighlightBackground": (_f2 = (_e2 = theme == null ? void 0 : theme.editor) == null ? void 0 : _e2.lineHighlightBackground) != null ? _f2 : "#15171c",
220623
+ "editor.selectionBackground": "#44475a",
220624
+ "editorCursor.foreground": "#f8f8f0",
220625
+ "editorWhitespace.foreground": "#3B3A32",
220626
+ "editorIndentGuide.activeBackground": "#9D550FB0",
220627
+ "editor.selectionHighlightBorder": "#222218"
220628
+ }
220629
+ };
220630
+ };
220631
+ const FileTreeStackLayout = newStyled.ul`
220632
+ .active {
220633
+ background-color: ${(props2) => props2.menuStyle.backgroundColor};
220634
+ box-shadow: 0px 1px 0px 0 #333;
220635
+ border-right: 1px solid ${(props2) => props2.menuStyle.backgroundColor};
220636
+ }
220637
+
220638
+ width: 100%;
220639
+ height: ${(props2) => props2.menuStyle.height};
220640
+ transform: translate(0, -1px);
220641
+ overflow-x: auto;
220642
+ flex-wrap: nowrap;
220643
+
220644
+ li {
220645
+ /* width: 100px; */
220646
+ height: 100%;
220647
+ padding: 5px 25px;
220648
+ color: ${(props2) => props2.menuStyle.textColor};
220649
+ font-size: 12px;
220650
+ flex: 0 0 auto;
220651
+ &:hover {
220652
+ background: ${(props2) => props2.menuStyle.hoverBgColor};
220653
+ color: ${(props2) => props2.menuStyle.hoverTextColor};
220654
+ }
220655
+ }
220656
+
220657
+ .tree-closer {
220658
+ right: 4px;
220659
+ font-size: 14px;
220660
+ opacity: 0;
220661
+ line-height: 0;
220662
+ transition: opacity 0.2s ease-in-out;
220663
+ color: ${(props2) => props2.menuStyle.iconColor};
220664
+ &.hover {
220665
+ opacity: 1;
220666
+ color: ${(props2) => props2.menuStyle.hoverIconColor};
220567
220667
  }
220568
- ],
220569
- colors: {
220570
- "editor.foreground": "#f8f8f2",
220571
- "editor.background": "#282a36",
220572
- "editor.selectionBackground": "#44475a",
220573
- "editor.lineHighlightBackground": "#44475a",
220574
- "editorCursor.foreground": "#f8f8f0",
220575
- "editorWhitespace.foreground": "#3B3A32",
220576
- "editorIndentGuide.activeBackground": "#9D550FB0",
220577
- "editor.selectionHighlightBorder": "#222218"
220578
220668
  }
220669
+ `;
220670
+ const FileListStack = ({
220671
+ editor: editor2,
220672
+ switchModel,
220673
+ menuStyle = {
220674
+ backgroundColor: "#005391",
220675
+ textColor: "#fff",
220676
+ hoverBgColor: "rgb(37 45 124 / 80%)",
220677
+ hoverTextColor: "#fff",
220678
+ iconColor: "#fff",
220679
+ hoverIconColor: "#fff",
220680
+ height: "35px"
220681
+ }
220682
+ }) => {
220683
+ const switchDoc2 = oTStore((state2) => state2.switchDoc);
220684
+ oTStore((state2) => state2.dockerInfo);
220685
+ const docFile = oTStore((state2) => state2.doc);
220686
+ const fileTreeStack = editorStore((state2) => state2.fileTreeStack);
220687
+ const setFileTreeStack = editorStore((state2) => state2.setFileTreeStack);
220688
+ const ref = useHorizontalScroll();
220689
+ const closeCurrentFile = (evt, index2) => {
220690
+ evt.preventDefault();
220691
+ evt.stopPropagation();
220692
+ const _fileTreeStackList = [...fileTreeStack];
220693
+ _fileTreeStackList.splice(index2, 1);
220694
+ setFileTreeStack(_fileTreeStackList);
220695
+ if (_fileTreeStackList.length === 0) {
220696
+ switchDoc2({
220697
+ path: "",
220698
+ value: ""
220699
+ });
220700
+ editor2.getModel().setValue("");
220701
+ } else {
220702
+ switchModel(_fileTreeStackList.slice(-1)[0].model);
220703
+ }
220704
+ };
220705
+ return fileTreeStack && fileTreeStack.length > 0 ? /* @__PURE__ */ jsx(FileTreeStackLayout, {
220706
+ menuStyle,
220707
+ id: "menu-list",
220708
+ ref,
220709
+ className: "flex flex-row file-list-container items-center flex-shrink-0 scroll-smooth no-scrollbar overflow-x-scroll bg-codezone-black overflow-auto touch-pan-x",
220710
+ children: fileTreeStack == null ? void 0 : fileTreeStack.map((f2, index2) => /* @__PURE__ */ jsxs("li", {
220711
+ className: `
220712
+ flex
220713
+ flex-row
220714
+ flex-grow-0
220715
+ relative
220716
+ flex-shrink-0
220717
+ justify-center
220718
+ items-center
220719
+ cursor-pointer
220720
+ ${f2.path === (docFile == null ? void 0 : docFile.path) ? "active" : ""}
220721
+ `,
220722
+ onClick: () => {
220723
+ switchModel(f2.model);
220724
+ },
220725
+ onDoubleClick: (evt) => {
220726
+ closeCurrentFile(evt, index2);
220727
+ },
220728
+ onMouseEnter: (evt) => {
220729
+ var _a2, _b2, _c2;
220730
+ (_c2 = (_b2 = (_a2 = evt.currentTarget) == null ? void 0 : _a2.lastElementChild) == null ? void 0 : _b2.classList) == null ? void 0 : _c2.add("hover");
220731
+ },
220732
+ onMouseLeave: (evt) => {
220733
+ var _a2, _b2, _c2;
220734
+ (_c2 = (_b2 = (_a2 = evt.currentTarget) == null ? void 0 : _a2.lastElementChild) == null ? void 0 : _b2.classList) == null ? void 0 : _c2.remove("hover");
220735
+ },
220736
+ children: [f2.label.split("/").slice(-1)[0], /* @__PURE__ */ jsx("i", {
220737
+ className: "d42 close tree-closer absolute",
220738
+ onClick: (evt) => {
220739
+ closeCurrentFile(evt, index2);
220740
+ }
220741
+ })]
220742
+ }, f2.path))
220743
+ }) : null;
220579
220744
  };
220745
+ function useHorizontalScroll() {
220746
+ const elRef = react.exports.useRef(null);
220747
+ const el = elRef.current;
220748
+ const onWheel = (e2) => {
220749
+ if (e2.deltaY == 0)
220750
+ return;
220751
+ e2.preventDefault();
220752
+ el == null ? void 0 : el.scrollTo({
220753
+ left: el.scrollLeft + e2.deltaY * 10,
220754
+ behavior: "smooth"
220755
+ });
220756
+ };
220757
+ react.exports.useEffect(() => {
220758
+ if (el) {
220759
+ el.addEventListener("wheel", onWheel);
220760
+ return () => el.removeEventListener("wheel", onWheel);
220761
+ }
220762
+ }, [el]);
220763
+ return elRef;
220764
+ }
220580
220765
  const APP_DIR = "/home/runner/app";
220581
220766
  let editor;
220582
220767
  const docServer = new Map();
@@ -220866,7 +221051,7 @@ const Editor = ({
220866
221051
  io == null ? void 0 : io.emit("fileTreeOp", JSON.stringify(payload));
220867
221052
  }
220868
221053
  });
220869
- editor$1.defineTheme("myCoolTheme", Dracula);
221054
+ editor$1.defineTheme("myCoolTheme", Dracula(theme));
220870
221055
  editor$1.setTheme("myCoolTheme");
220871
221056
  setClientEditor(new MonacoAdapter(editor, serviceWorkerOrigin));
220872
221057
  setOtherClients(new ClientMeta(editor, userList.filter((x2) => !IsMe(x2))));
@@ -221035,8 +221220,8 @@ const Editor = ({
221035
221220
  }), /* @__PURE__ */ jsxs(EditorLayout, {
221036
221221
  style: containerStyle,
221037
221222
  theme,
221038
- className: `editor-layout flex flex-col`,
221039
- children: [/* @__PURE__ */ jsx(FileTreeStack, {
221223
+ className: `editor-container flex flex-col`,
221224
+ children: [/* @__PURE__ */ jsx(FileListStack, {
221040
221225
  editor,
221041
221226
  menuStyle,
221042
221227
  switchModel,
@@ -221044,145 +221229,12 @@ const Editor = ({
221044
221229
  }), /* @__PURE__ */ jsx(ContentLayout, {
221045
221230
  ref: divEl,
221046
221231
  userList: userListStore.getState().userList,
221047
- className: "editor-content flex-1",
221232
+ className: "editor-container flex-1",
221048
221233
  style: editorStyle
221049
221234
  })]
221050
221235
  })]
221051
221236
  });
221052
221237
  };
221053
- const FileTreeStackLayout = newStyled.ul`
221054
- .active {
221055
- background-color: ${(props2) => props2.menuStyle.backgroundColor};
221056
- box-shadow: 0px 1px 0px 0 #333;
221057
- border-right: 1px solid ${(props2) => props2.menuStyle.backgroundColor};
221058
- }
221059
-
221060
- width: 100%;
221061
- height: 35px;
221062
- transform: translate(0, -1px);
221063
- overflow-x: auto;
221064
- flex-wrap: nowrap;
221065
- li {
221066
- /* width: 100px; */
221067
- height: 100%;
221068
- padding: 5px 25px;
221069
- color: ${(props2) => props2.menuStyle.textColor};
221070
- font-size: 12px;
221071
- flex: 0 0 auto;
221072
- &:hover {
221073
- background: ${(props2) => props2.menuStyle.hoverBgColor};
221074
- color: ${(props2) => props2.menuStyle.hoverTextColor};
221075
- }
221076
- }
221077
-
221078
- .tree-closer {
221079
- right: 4px;
221080
- font-size: 14px;
221081
- opacity: 0;
221082
- line-height: 0;
221083
- transition: opacity 0.2s ease-in-out;
221084
- color: ${(props2) => props2.menuStyle.iconColor};
221085
- &.hover {
221086
- opacity: 1;
221087
- color: ${(props2) => props2.menuStyle.hoverIconColor};
221088
- }
221089
- }
221090
- `;
221091
- const FileTreeStack = ({
221092
- editor: editor2,
221093
- switchModel,
221094
- clearPlayground,
221095
- menuStyle = {
221096
- backgroundColor: "#005391",
221097
- textColor: "#fff",
221098
- hoverBgColor: "rgb(37 45 124 / 80%)",
221099
- hoverTextColor: "#fff",
221100
- iconColor: "#fff",
221101
- hoverIconColor: "#fff"
221102
- }
221103
- }) => {
221104
- const switchDoc2 = oTStore((state2) => state2.switchDoc);
221105
- oTStore((state2) => state2.dockerInfo);
221106
- const docFile = oTStore((state2) => state2.doc);
221107
- const fileTreeStack = editorStore((state2) => state2.fileTreeStack);
221108
- const setFileTreeStack = editorStore((state2) => state2.setFileTreeStack);
221109
- const ref = useHorizontalScroll();
221110
- const closeCurrentFile = (evt, index2) => {
221111
- evt.preventDefault();
221112
- evt.stopPropagation();
221113
- const _fileTreeStackList = [...fileTreeStack];
221114
- _fileTreeStackList.splice(index2, 1);
221115
- setFileTreeStack(_fileTreeStackList);
221116
- if (_fileTreeStackList.length === 0) {
221117
- switchDoc2({
221118
- path: "",
221119
- value: ""
221120
- });
221121
- editor2.getModel().setValue("");
221122
- } else {
221123
- switchModel(_fileTreeStackList.slice(-1)[0].model);
221124
- }
221125
- };
221126
- return fileTreeStack && fileTreeStack.length > 0 ? /* @__PURE__ */ jsx(FileTreeStackLayout, {
221127
- menuStyle,
221128
- id: "menu-list",
221129
- ref,
221130
- className: "flex flex-row stack-list items-center flex-shrink-0 scroll-smooth no-scrollbar overflow-x-scroll bg-codezone-black overflow-auto touch-pan-x",
221131
- children: fileTreeStack == null ? void 0 : fileTreeStack.map((f2, index2) => /* @__PURE__ */ jsxs("li", {
221132
- className: `
221133
- flex
221134
- flex-row
221135
- flex-grow-0
221136
- relative
221137
- flex-shrink-0
221138
- justify-center
221139
- items-center
221140
- cursor-pointer
221141
- ${f2.path === (docFile == null ? void 0 : docFile.path) ? "active" : ""}
221142
- `,
221143
- onClick: () => {
221144
- switchModel(f2.model);
221145
- },
221146
- onDoubleClick: (evt) => {
221147
- closeCurrentFile(evt, index2);
221148
- },
221149
- onMouseEnter: (evt) => {
221150
- var _a2, _b2, _c2;
221151
- (_c2 = (_b2 = (_a2 = evt.currentTarget) == null ? void 0 : _a2.lastElementChild) == null ? void 0 : _b2.classList) == null ? void 0 : _c2.add("hover");
221152
- },
221153
- onMouseLeave: (evt) => {
221154
- var _a2, _b2, _c2;
221155
- (_c2 = (_b2 = (_a2 = evt.currentTarget) == null ? void 0 : _a2.lastElementChild) == null ? void 0 : _b2.classList) == null ? void 0 : _c2.remove("hover");
221156
- },
221157
- children: [f2.label.split("/").slice(-1)[0], /* @__PURE__ */ jsx("i", {
221158
- className: "d42 close tree-closer absolute",
221159
- onClick: (evt) => {
221160
- closeCurrentFile(evt, index2);
221161
- }
221162
- })]
221163
- }, f2.path))
221164
- }) : null;
221165
- };
221166
- function useHorizontalScroll() {
221167
- const elRef = react.exports.useRef(null);
221168
- const el = elRef.current;
221169
- const onWheel = (e2) => {
221170
- if (e2.deltaY == 0)
221171
- return;
221172
- e2.preventDefault();
221173
- el == null ? void 0 : el.scrollTo({
221174
- left: el.scrollLeft + e2.deltaY * 10,
221175
- behavior: "smooth"
221176
- });
221177
- };
221178
- react.exports.useEffect(() => {
221179
- if (el) {
221180
- el.addEventListener("wheel", onWheel);
221181
- return () => el.removeEventListener("wheel", onWheel);
221182
- }
221183
- }, [el]);
221184
- return elRef;
221185
- }
221186
221238
  var index$4 = /* @__PURE__ */ Object.freeze({
221187
221239
  __proto__: null,
221188
221240
  [Symbol.toStringTag]: "Module",
@@ -228395,7 +228447,7 @@ const Console = (_e2) => {
228395
228447
  }, [dockerStatus]);
228396
228448
  return /* @__PURE__ */ jsx(FollowLayout, {
228397
228449
  children: /* @__PURE__ */ jsx("div", {
228398
- className: props2.className ? props2.className : "",
228450
+ className: `console-container ${props2.className ? props2.className : ""}`,
228399
228451
  style: {
228400
228452
  height: "100%",
228401
228453
  width: "100%"
@@ -228418,7 +228470,7 @@ const NavBar = newStyled.div`
228418
228470
  height: 30px;
228419
228471
  display: flex;
228420
228472
  align-items: center;
228421
-
228473
+ background-color: ${(props2) => props2.navBgColor};
228422
228474
  .reload {
228423
228475
  color: ${(props2) => props2.freshIconColor};
228424
228476
  }
@@ -228428,7 +228480,9 @@ const NavBar = newStyled.div`
228428
228480
  }
228429
228481
 
228430
228482
  input {
228431
- color: ${(props2) => props2.inputColor};
228483
+ color: ${(props2) => props2.inputTextColor};
228484
+ background-color: ${(props2) => props2.inputBgColor};
228485
+ border: ${(props2) => props2.navBorder};
228432
228486
  }
228433
228487
 
228434
228488
  i {
@@ -228458,7 +228512,6 @@ const NavBar = newStyled.div`
228458
228512
  height: 26px;
228459
228513
  line-height: 26px;
228460
228514
  padding: 0 8px;
228461
- border: 1px solid #adacac;
228462
228515
  border-radius: 5px;
228463
228516
  }
228464
228517
  `;
@@ -228477,14 +228530,22 @@ const StopMask = newStyled.div`
228477
228530
  const OutputBrowser = (_g2) => {
228478
228531
  var _h2 = _g2, {
228479
228532
  showURL = false,
228480
- freshIconColor = "#00bcd4",
228481
- inputColor = "#adacac",
228482
- openIconColor = "#adacac"
228533
+ bgColor = "#f2f2f2",
228534
+ freshIconColor = "#0487D9",
228535
+ inputTextColor = "#0487D9",
228536
+ openIconColor = "#0487D9",
228537
+ inputBgColor = "#000",
228538
+ navBgColor = "#000",
228539
+ navBorder = "0 solid transparent"
228483
228540
  } = _h2, props2 = __objRest(_h2, [
228484
228541
  "showURL",
228542
+ "bgColor",
228485
228543
  "freshIconColor",
228486
- "inputColor",
228487
- "openIconColor"
228544
+ "inputTextColor",
228545
+ "openIconColor",
228546
+ "inputBgColor",
228547
+ "navBgColor",
228548
+ "navBorder"
228488
228549
  ]);
228489
228550
  var _a2;
228490
228551
  const pStatus = oTStore((state2) => state2.playgroundStatus);
@@ -228541,11 +228602,14 @@ const OutputBrowser = (_g2) => {
228541
228602
  return /* @__PURE__ */ jsx(FollowLayout, {
228542
228603
  name: "browser",
228543
228604
  children: /* @__PURE__ */ jsxs(BrowserLayout, {
228544
- className: "w-full h-full",
228605
+ className: "browser-container w-full h-full",
228545
228606
  children: [showURL ? /* @__PURE__ */ jsxs(NavBar, {
228607
+ navBgColor,
228546
228608
  freshIconColor,
228547
- inputColor,
228609
+ inputTextColor,
228610
+ inputBgColor,
228548
228611
  openIconColor,
228612
+ navBorder,
228549
228613
  children: [/* @__PURE__ */ jsx("i", {
228550
228614
  className: "d42 text-xl reload cursor-pointer",
228551
228615
  onClick: onRefresh
@@ -228701,7 +228765,7 @@ const TerminalComponent = (_i) => {
228701
228765
  return /* @__PURE__ */ jsx(FollowLayout, {
228702
228766
  name: "terminal",
228703
228767
  children: /* @__PURE__ */ jsx("div", {
228704
- className: props2.className ? props2.className : "",
228768
+ className: "terminal-container shell-container",
228705
228769
  id: "terminal",
228706
228770
  style: {
228707
228771
  height: "100%",
@@ -229049,7 +229113,7 @@ const Avatar = (_m) => {
229049
229113
  "user"
229050
229114
  ]);
229051
229115
  return /* @__PURE__ */ jsx(AvatarLayout, __spreadValues({
229052
- className: "rounded-full motion-safe:hover:scale-110 h-8 w-8 self-center bg-cover bg-no-repeat bg-center border-2",
229116
+ className: "avatar-container rounded-full motion-safe:hover:scale-110 h-8 w-8 self-center bg-cover bg-no-repeat bg-center border-2",
229053
229117
  user
229054
229118
  }, props2));
229055
229119
  };