@dao42/d42paas-front 0.5.54 → 0.5.59
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/DaoPaaS.es.js +46 -11
- package/dist/DaoPaaS.umd.js +261 -261
- package/package.json +2 -4
package/dist/DaoPaaS.es.js
CHANGED
|
@@ -14724,6 +14724,9 @@ async function setReplaySource(val) {
|
|
|
14724
14724
|
file: lodash$2.exports.omit(val.file, "value")
|
|
14725
14725
|
}), val.timestamp + "." + v4$1().split("-")[0]);
|
|
14726
14726
|
}
|
|
14727
|
+
async function getLocalFile(key) {
|
|
14728
|
+
return (await daopaasDB).get("files", key);
|
|
14729
|
+
}
|
|
14727
14730
|
async function getLocalReplayFile(key) {
|
|
14728
14731
|
return (await daopaasDB).get("replayFiles", key);
|
|
14729
14732
|
}
|
|
@@ -28508,10 +28511,14 @@ const PlaygroundInit = (arg) => {
|
|
|
28508
28511
|
}
|
|
28509
28512
|
});
|
|
28510
28513
|
io.on("serverAck", (d2) => {
|
|
28514
|
+
var _a2;
|
|
28511
28515
|
const _d2 = JSON.parse(d2);
|
|
28512
28516
|
setAsyncType("editor");
|
|
28513
28517
|
setReplaySource(__spreadProps(__spreadValues({}, _d2), {
|
|
28514
|
-
event: "editor"
|
|
28518
|
+
event: "editor",
|
|
28519
|
+
editor: __spreadProps(__spreadValues({}, _d2.editor), {
|
|
28520
|
+
revision: ((_a2 = _d2.editor) == null ? void 0 : _a2.revision) + 1
|
|
28521
|
+
})
|
|
28515
28522
|
}));
|
|
28516
28523
|
setServerAck();
|
|
28517
28524
|
});
|
|
@@ -30591,11 +30598,11 @@ const replay = async (item) => {
|
|
|
30591
30598
|
const filterReplayList = replayList.filter((replayItem) => replayItem.userInfo.uuid === item.userId);
|
|
30592
30599
|
const filterReplaySource = filterReplayList.find((f2) => f2.timestamp === item.timestamp);
|
|
30593
30600
|
if (filterReplaySource.file) {
|
|
30594
|
-
const
|
|
30595
|
-
filterReplaySource.file.value =
|
|
30596
|
-
if ((
|
|
30601
|
+
const doc2 = await getLocalFile(filterReplaySource.file.path);
|
|
30602
|
+
filterReplaySource.file.value = doc2;
|
|
30603
|
+
if ((doc2 == null ? void 0 : doc2.path) !== filterReplaySource.file.path) {
|
|
30597
30604
|
switchDoc == null ? void 0 : switchDoc({
|
|
30598
|
-
value:
|
|
30605
|
+
value: doc2.value,
|
|
30599
30606
|
path: filterReplaySource.file.path
|
|
30600
30607
|
});
|
|
30601
30608
|
}
|
|
@@ -187668,6 +187675,22 @@ const ContentLayout = newStyled.div`
|
|
|
187668
187675
|
${(props2) => props2.userList.map((u2) => "." + u2.role + "-selection{background:" + u2.color + "a6;color: #fff;width: 2px !important;}")}
|
|
187669
187676
|
`;
|
|
187670
187677
|
self.MonacoEnvironment = {
|
|
187678
|
+
baseUrl: "https://develop.1024paas.com",
|
|
187679
|
+
getWorkerUrl(_moduleId, label) {
|
|
187680
|
+
if (label === "json") {
|
|
187681
|
+
return "./json.worker.bundle.js";
|
|
187682
|
+
}
|
|
187683
|
+
if (label === "css") {
|
|
187684
|
+
return "./css.worker.bundle.js";
|
|
187685
|
+
}
|
|
187686
|
+
if (label === "html") {
|
|
187687
|
+
return "./html.worker.bundle.js";
|
|
187688
|
+
}
|
|
187689
|
+
if (label === "typescript" || label === "javascript") {
|
|
187690
|
+
return "./ts.worker.bundle.js";
|
|
187691
|
+
}
|
|
187692
|
+
return "./editor.worker.bundle.js";
|
|
187693
|
+
},
|
|
187671
187694
|
getWorker(_2, label) {
|
|
187672
187695
|
if (label === "json") {
|
|
187673
187696
|
return new WorkerWrapper$3();
|
|
@@ -187787,7 +187810,10 @@ const Editor = ({
|
|
|
187787
187810
|
preOffset = change.rangeOffset + change.rangeLength;
|
|
187788
187811
|
});
|
|
187789
187812
|
client2.applyClient(operation);
|
|
187790
|
-
setLocalFile((doc22 == null ? void 0 : doc22.path) ? doc22 == null ? void 0 : doc22.path : "singleFile",
|
|
187813
|
+
setLocalFile((doc22 == null ? void 0 : doc22.path) ? doc22 == null ? void 0 : doc22.path : "singleFile", {
|
|
187814
|
+
value: editor.getValue(),
|
|
187815
|
+
revision: client2.revision + 1
|
|
187816
|
+
});
|
|
187791
187817
|
} else {
|
|
187792
187818
|
setValue2(changes[0].text);
|
|
187793
187819
|
}
|
|
@@ -187879,7 +187905,10 @@ const Editor = ({
|
|
|
187879
187905
|
revision: client2.revision,
|
|
187880
187906
|
value: file.value
|
|
187881
187907
|
});
|
|
187882
|
-
oTStore.getState().appStatus !== "replay" && setLocalFile(doc22 == null ? void 0 : doc22.path,
|
|
187908
|
+
oTStore.getState().appStatus !== "replay" && setLocalFile(doc22 == null ? void 0 : doc22.path, {
|
|
187909
|
+
value: file.value,
|
|
187910
|
+
revision: client2.revision
|
|
187911
|
+
});
|
|
187883
187912
|
}
|
|
187884
187913
|
};
|
|
187885
187914
|
const lspServerInject = (_lan, useLsp) => {
|
|
@@ -187888,6 +187917,11 @@ const Editor = ({
|
|
|
187888
187917
|
extensions: [".rb"],
|
|
187889
187918
|
aliases: ["ruby", "RUBY"]
|
|
187890
187919
|
});
|
|
187920
|
+
languages.register({
|
|
187921
|
+
id: "python",
|
|
187922
|
+
extensions: [".py"],
|
|
187923
|
+
aliases: ["python", "PYTHON"]
|
|
187924
|
+
});
|
|
187891
187925
|
languages.register({
|
|
187892
187926
|
id: "java",
|
|
187893
187927
|
extensions: [".java"],
|
|
@@ -187921,7 +187955,7 @@ const Editor = ({
|
|
|
187921
187955
|
const languageClient = new lib.MonacoLanguageClient({
|
|
187922
187956
|
name: "Language Client",
|
|
187923
187957
|
clientOptions: {
|
|
187924
|
-
documentSelector: ["java", "ruby"],
|
|
187958
|
+
documentSelector: ["java", "ruby", "python"],
|
|
187925
187959
|
errorHandler: {
|
|
187926
187960
|
error: () => lib.ErrorAction.Continue,
|
|
187927
187961
|
closed: () => lib.CloseAction.DoNotRestart
|
|
@@ -187998,11 +188032,13 @@ const Editor = ({
|
|
|
187998
188032
|
}
|
|
187999
188033
|
return result;
|
|
188000
188034
|
};
|
|
188035
|
+
window.ot = __spreadProps(__spreadValues({}, ot), {
|
|
188036
|
+
oTStore,
|
|
188037
|
+
editor
|
|
188038
|
+
});
|
|
188001
188039
|
}
|
|
188002
|
-
window.ot = ot;
|
|
188003
188040
|
};
|
|
188004
188041
|
react.exports.useEffect(() => {
|
|
188005
|
-
window.ot = ot;
|
|
188006
188042
|
editorInit();
|
|
188007
188043
|
return () => {
|
|
188008
188044
|
editor.dispose();
|
|
@@ -195674,7 +195710,6 @@ const TerminalComponent = (_i) => {
|
|
|
195674
195710
|
writeText(terminal, ((_b2 = crdt == null ? void 0 : crdt.doc) == null ? void 0 : _b2.value) || "");
|
|
195675
195711
|
if (!CRDTInfo.userInfo.uuid)
|
|
195676
195712
|
return;
|
|
195677
|
-
console.log(CRDTInfo.userInfo.uuid);
|
|
195678
195713
|
const postUser = userListStore.getState().userList.find(({
|
|
195679
195714
|
uuid: uuid2
|
|
195680
195715
|
}) => uuid2 === CRDTInfo.userInfo.uuid);
|