@nine-lab/nine-mu 0.1.390 β 0.1.392
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/nine-mu.js +13 -45
- package/dist/nine-mu.js.map +1 -1
- package/dist/nine-mu.umd.js +1 -1
- package/dist/nine-mu.umd.js.map +1 -1
- package/package.json +1 -1
- package/src/components/hook/NineHook.js +11 -50
package/dist/nine-mu.js
CHANGED
|
@@ -11,7 +11,7 @@ var __privateSet = (obj, member, value, setter) => (__accessCheck(obj, member, "
|
|
|
11
11
|
var __privateMethod = (obj, member, method) => (__accessCheck(obj, member, "access private method"), method);
|
|
12
12
|
var _owner, _collectedFiles, _NotificationHandler_instances, handleLoggingMessage_fn, _collectModifySource, _openDiffPopup, _openRouteDiffPopup, _generateSource, _generateMenu, _mcpClient, _onAction, _onStatus, _onMessage, _owner2, _routeUrl, _chatHistory, _notiHandler, _NineChatManager_instances, connect_fn, updateStatus_fn, callTool_fn, _getSourcePath, _service, _packageName, _routesPath, _connectorUrl, _manager, _config, _$nineChatMessage, _NineChat_instances, initInteractions_fn, initActions_fn, render_fn, _sourceGenHandler, _asisEditorView, _tobeEditorView, _asisEditorEl, _tobeEditorEl, _isDirty, _initialAsisSrc, _initialTobeSrc, _languageCompartment, _isScrollSyncActive, _initCodeMirror, _checkDirtyState, _setupScrollSync, _applyDiffDecorations, _dialog, _tabContainer, _fileList, _host, _NineDiffPopup_instances, renderScaffolding_fn, handleConfirmAll_fn, handleCancel_fn, _dialog2, _diffView, _asisBackup, _host2, _NineMenuDiffPopup_instances, render_fn2, handleConfirm_fn, handleCancel_fn2, _message, _data, _unique, _init, _message2, _init2, _progressData, _progressElements, _animationIntervals, _ProgressMessage_instances, updateCurrentActiveProgress_fn, renderProgress_fn, updateProgressItemVisuals_fn, startAnimation_fn, updateProgressItem_fn, _renderer, _init3;
|
|
13
13
|
import { trace as trace$1, api, nine as nine$1 } from "@nine-lab/nine-util";
|
|
14
|
-
import React, { createContext,
|
|
14
|
+
import React, { createContext, Suspense, useContext, useState, lazy } from "react";
|
|
15
15
|
import { Routes, Route } from "react-router-dom";
|
|
16
16
|
class Trace extends trace$1.constructor {
|
|
17
17
|
constructor() {
|
|
@@ -17539,7 +17539,7 @@ render_fn = function() {
|
|
|
17539
17539
|
const customImport = nine$1.cssPath ? `@import "${nine$1.cssPath}/nine-mu.css";` : "";
|
|
17540
17540
|
this.shadowRoot.innerHTML = `
|
|
17541
17541
|
<style>
|
|
17542
|
-
@import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-mu@${"0.1.
|
|
17542
|
+
@import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-mu@${"0.1.391"}/dist/css/nine-mu.css";
|
|
17543
17543
|
${customImport}
|
|
17544
17544
|
</style>
|
|
17545
17545
|
<div class="wrapper">
|
|
@@ -43789,7 +43789,7 @@ class NineDiff extends HTMLElement {
|
|
|
43789
43789
|
const customImport = nine.cssPath ? `@import "${nine.cssPath}/nine-mu.css";` : "";
|
|
43790
43790
|
this.shadowRoot.innerHTML = `
|
|
43791
43791
|
<style>
|
|
43792
|
-
@import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-mu@${"0.1.
|
|
43792
|
+
@import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-mu@${"0.1.391"}/dist/css/nine-mu.css";
|
|
43793
43793
|
${customImport}
|
|
43794
43794
|
</style>
|
|
43795
43795
|
|
|
@@ -43929,7 +43929,7 @@ renderScaffolding_fn = function() {
|
|
|
43929
43929
|
const customImport = nine$1.cssPath ? `@import "${nine$1.cssPath}/nine-mu.css";` : "";
|
|
43930
43930
|
this.shadowRoot.innerHTML = `
|
|
43931
43931
|
<style>
|
|
43932
|
-
@import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-mu@${"0.1.
|
|
43932
|
+
@import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-mu@${"0.1.391"}/dist/css/nine-mu.css";
|
|
43933
43933
|
${customImport}
|
|
43934
43934
|
</style>
|
|
43935
43935
|
|
|
@@ -44038,7 +44038,7 @@ render_fn2 = function() {
|
|
|
44038
44038
|
const customImport = nine$1.cssPath ? `@import "${nine$1.cssPath}/nine-mu.css";` : "";
|
|
44039
44039
|
this.shadowRoot.innerHTML = `
|
|
44040
44040
|
<style>
|
|
44041
|
-
@import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-mu@${"0.1.
|
|
44041
|
+
@import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-mu@${"0.1.391"}/dist/css/nine-mu.css";
|
|
44042
44042
|
${customImport}
|
|
44043
44043
|
</style>
|
|
44044
44044
|
|
|
@@ -44368,7 +44368,7 @@ class ChatMessageBody extends HTMLElement {
|
|
|
44368
44368
|
const customImport = nine.cssPath ? `@import "${nine.cssPath}/nine-mu.css";` : "";
|
|
44369
44369
|
this.shadowRoot.innerHTML = `
|
|
44370
44370
|
<style>
|
|
44371
|
-
@import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-mu@${"0.1.
|
|
44371
|
+
@import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-mu@${"0.1.391"}/dist/css/nine-mu.css";
|
|
44372
44372
|
${customImport}
|
|
44373
44373
|
</style>
|
|
44374
44374
|
|
|
@@ -44516,6 +44516,7 @@ const createDynamicRoutes = (menuData, projectViews, Custom404) => {
|
|
|
44516
44516
|
const sanitizedParts = pathParts.map((part) => part.replace(/-/g, "_"));
|
|
44517
44517
|
const fullFolderPath = sanitizedParts.join("/");
|
|
44518
44518
|
const componentPath = `./views/${fullFolderPath}/${pascalName}.jsx`;
|
|
44519
|
+
trace.log(componentPath);
|
|
44519
44520
|
dynamicRoutes.push({
|
|
44520
44521
|
path: menu.path,
|
|
44521
44522
|
Component: lazyLoad(componentPath)
|
|
@@ -44652,42 +44653,7 @@ class NineExceptionHook extends React.Component {
|
|
|
44652
44653
|
return this.props.children;
|
|
44653
44654
|
}
|
|
44654
44655
|
}
|
|
44655
|
-
function NineHook({ children,
|
|
44656
|
-
const [menuData, setMenuData] = useState([]);
|
|
44657
|
-
const fetchRoutes = async () => {
|
|
44658
|
-
if (!menuUrl) return;
|
|
44659
|
-
try {
|
|
44660
|
-
const response = await fetch(`${menuUrl}?t=${Date.now()}`);
|
|
44661
|
-
if (response.ok) {
|
|
44662
|
-
const data = await response.json();
|
|
44663
|
-
setMenuData((prev) => {
|
|
44664
|
-
if (JSON.stringify(prev) === JSON.stringify(data)) return prev;
|
|
44665
|
-
console.log("π₯ [Nine-Library] routes.json λ³κ²½ κ°μ§ -> μ 체 μμ€ν
λκΈ°ν");
|
|
44666
|
-
return data;
|
|
44667
|
-
});
|
|
44668
|
-
}
|
|
44669
|
-
} catch (e) {
|
|
44670
|
-
console.error("[Nine-Library] λ°νμ λ©λ΄ λκΈ°ν μ€ν¨:", e);
|
|
44671
|
-
}
|
|
44672
|
-
};
|
|
44673
|
-
useEffect(() => {
|
|
44674
|
-
fetchRoutes();
|
|
44675
|
-
window.addEventListener("popstate", fetchRoutes);
|
|
44676
|
-
document.addEventListener("click", fetchRoutes, true);
|
|
44677
|
-
const intervalId = setInterval(fetchRoutes, 3e3);
|
|
44678
|
-
return () => {
|
|
44679
|
-
window.removeEventListener("popstate", fetchRoutes);
|
|
44680
|
-
document.removeEventListener("click", fetchRoutes, true);
|
|
44681
|
-
clearInterval(intervalId);
|
|
44682
|
-
};
|
|
44683
|
-
}, [menuUrl]);
|
|
44684
|
-
if (!menuData || menuData.length === 0) {
|
|
44685
|
-
return React.createElement(
|
|
44686
|
-
"div",
|
|
44687
|
-
{ style: { padding: "25px", color: "#666", fontFamily: "monospace", background: "#121314", minHeight: "100vh" } },
|
|
44688
|
-
">> Initializing menu matrix telemetry..."
|
|
44689
|
-
);
|
|
44690
|
-
}
|
|
44656
|
+
function NineHook({ children, menuData, views, error404, onCatch, fallback, styles, containerStyle }) {
|
|
44691
44657
|
const dynamicRoutes = createDynamicRoutes(menuData, views, error404);
|
|
44692
44658
|
return React.createElement(
|
|
44693
44659
|
ScreenProvider,
|
|
@@ -44695,8 +44661,10 @@ function NineHook({ children, menuUrl, views, error404, onCatch, fallback, style
|
|
|
44695
44661
|
React.createElement(
|
|
44696
44662
|
NineExceptionHook,
|
|
44697
44663
|
{ onCatch, fallback, styles, containerStyle },
|
|
44664
|
+
// LeftMenu λ μ΄μμ μμ μΆλ ₯ (λΆν
λλ μ΄ μμ΄ μ¦μ λ λλ§)
|
|
44698
44665
|
children,
|
|
44699
|
-
|
|
44666
|
+
// λ°μ΄ν°κ° μ‘΄μ¬ν λ μ μλλ‘ λΌμ°ν° ꡬμ νμ±ν
|
|
44667
|
+
menuData && menuData.length > 0 ? React.createElement(
|
|
44700
44668
|
Suspense,
|
|
44701
44669
|
{ fallback: React.createElement("div", { style: { padding: "25px", color: "#666", fontFamily: "monospace" } }, ">> Loading component matrix...") },
|
|
44702
44670
|
React.createElement(
|
|
@@ -44710,12 +44678,12 @@ function NineHook({ children, menuUrl, views, error404, onCatch, fallback, style
|
|
|
44710
44678
|
})
|
|
44711
44679
|
)
|
|
44712
44680
|
)
|
|
44713
|
-
)
|
|
44681
|
+
) : React.createElement("div", { style: { padding: "25px", color: "#444", fontFamily: "monospace" } }, ">> Database route matrix empty.")
|
|
44714
44682
|
)
|
|
44715
44683
|
);
|
|
44716
44684
|
}
|
|
44717
44685
|
const NineMu = {
|
|
44718
|
-
version: "0.1.
|
|
44686
|
+
version: "0.1.391",
|
|
44719
44687
|
init: (config2) => {
|
|
44720
44688
|
trace$1.log("π οΈ Nine-Mu Engine initialized", config2);
|
|
44721
44689
|
}
|