@nine-lab/nine-mu 0.1.221 → 0.1.223

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.
@@ -1021,7 +1021,7 @@
1021
1021
  display: -webkit-box;
1022
1022
  -webkit-line-clamp: 3;
1023
1023
  -webkit-box-orient: vertical;
1024
- overflow: hidden;
1024
+ overflow: auto;
1025
1025
  padding: 0;
1026
1026
  flex-grow: 1;
1027
1027
  /* 줄바꿈 강제 적용 */
package/dist/nine-mu.js CHANGED
@@ -9,7 +9,7 @@ var __privateGet = (obj, member, getter) => (__accessCheck(obj, member, "read fr
9
9
  var __privateAdd = (obj, member, value) => member.has(obj) ? __typeError("Cannot add the same private member more than once") : member instanceof WeakSet ? member.add(obj) : member.set(obj, value);
10
10
  var __privateSet = (obj, member, value, setter) => (__accessCheck(obj, member, "write to private field"), setter ? setter.call(obj, value) : member.set(obj, value), value);
11
11
  var __privateMethod = (obj, member, method) => (__accessCheck(obj, member, "access private method"), method);
12
- var _mcpClient, _onAction, _onStatus, _onMessage, _owner, _routeUrl, _chatHistory, _NineChatManager_instances, connect_fn, updateStatus_fn, callTool_fn, getRoutes_fn, _getSourcePath, _service, _routes, _diffPopup, _packageName, _routesPath, _connectorUrl, _manager, _$nineChatMessage, _NineChat_instances, initInteractions_fn, initActions_fn, render_fn, _makeMenuHandler, _sourceGenHandler, _showDiff, _asisEditorView, _tobeEditorView, _asisEditorEl, _tobeEditorEl, _languageCompartment, _isScrollSyncActive, _initCodeMirror, _setupScrollSync, _applyDiffDecorations, _dialog, _diffView, _asisBackup, _host, _NineDiffPopup_instances, render_fn2, handleConfirm_fn, handleCancel_fn, _message, _data, _unique, _init, _message2, _init2, _progressData, _progressElements, _animationIntervals, _ProgressMessage_instances, updateCurrentActiveProgress_fn, renderProgress_fn, updateProgressItemVisuals_fn, startAnimation_fn, updateProgressItem_fn, _renderer, _init3;
12
+ var _mcpClient, _onAction, _onStatus, _onMessage, _owner, _routeUrl, _chatHistory, _NineChatManager_instances, connect_fn, updateStatus_fn, callTool_fn, _getSourcePath, _service, _routes, _diffPopup, _packageName, _routesPath, _connectorUrl, _manager, _$nineChatMessage, _NineChat_instances, initInteractions_fn, initActions_fn, render_fn, _makeMenuHandler, _sourceGenHandler, _showDiff, _asisEditorView, _tobeEditorView, _asisEditorEl, _tobeEditorEl, _languageCompartment, _isScrollSyncActive, _initCodeMirror, _setupScrollSync, _applyDiffDecorations, _dialog, _diffView, _asisBackup, _host, _NineDiffPopup_instances, render_fn2, handleConfirm_fn, handleCancel_fn, _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 } from "@nine-lab/nine-util";
14
14
  class Trace extends trace$1.constructor {
15
15
  constructor() {
@@ -17096,7 +17096,7 @@ class NineChatManager {
17096
17096
  return await __privateMethod(this, _NineChatManager_instances, callTool_fn).call(this, "system-brain", {
17097
17097
  user_input: userInput,
17098
17098
  chat_history: formattedHistory,
17099
- routes: await __privateMethod(this, _NineChatManager_instances, getRoutes_fn).call(this),
17099
+ routes: await this.getRoutes(),
17100
17100
  current_path: currentPath
17101
17101
  });
17102
17102
  });
@@ -17120,6 +17120,10 @@ class NineChatManager {
17120
17120
  return "";
17121
17121
  }
17122
17122
  }
17123
+ async getRoutes(toolName, args = {}) {
17124
+ const res = await fetch(__privateGet(this, _routeUrl));
17125
+ return res.ok ? await res.json() : [];
17126
+ }
17123
17127
  addChatHistory(message) {
17124
17128
  __privateGet(this, _chatHistory).push({ role: "ai", text: message });
17125
17129
  }
@@ -17143,7 +17147,9 @@ connect_fn = async function() {
17143
17147
  capabilities: {
17144
17148
  tools: {},
17145
17149
  logging: {}
17146
- }
17150
+ },
17151
+ timeout: 3e5
17152
+ // 5분
17147
17153
  }));
17148
17154
  trace.log(__privateGet(this, _mcpClient));
17149
17155
  __privateGet(this, _mcpClient).connect(transport).then(async () => {
@@ -17185,10 +17191,6 @@ updateStatus_fn = function(msg) {
17185
17191
  callTool_fn = async function(toolName, args = {}) {
17186
17192
  return __privateGet(this, _mcpClient).callTool({ name: toolName, arguments: args });
17187
17193
  };
17188
- getRoutes_fn = async function(toolName, args = {}) {
17189
- const res = await fetch(__privateGet(this, _routeUrl));
17190
- return res.ok ? await res.json() : [];
17191
- };
17192
17194
  class NineMuService {
17193
17195
  constructor(connectorUrl) {
17194
17196
  __privateAdd(this, _getSourcePath, (menuUrl) => {
@@ -17392,13 +17394,13 @@ initActions_fn = function() {
17392
17394
  trace.log(result);
17393
17395
  try {
17394
17396
  const rawText = (_b = (_a2 = result == null ? void 0 : result.content) == null ? void 0 : _a2[0]) == null ? void 0 : _b.text;
17395
- trace.log(rawText);
17396
17397
  const parsed = JSON.parse(rawText);
17397
17398
  __privateGet(this, _manager).addChatHistory(parsed.message);
17398
17399
  __privateGet(this, _$nineChatMessage).add("ai", parsed.message);
17400
+ const currRoutes = await __privateGet(this, _$nineChatMessage).getRoutes();
17399
17401
  if (((_c = parsed == null ? void 0 : parsed.action) == null ? void 0 : _c.selected_tool) === "source-missing") {
17400
17402
  nine.alert("메뉴 정리를 위한 라우터 정보 저장 화면으로 이동합니다.").then((res) => {
17401
- __privateGet(this, _showDiff).call(this, parsed.action.params.routes, parsed.data, "json");
17403
+ __privateGet(this, _showDiff).call(this, currRoutes, parsed.data, "json");
17402
17404
  });
17403
17405
  }
17404
17406
  } catch (err2) {
@@ -17415,7 +17417,7 @@ render_fn = function() {
17415
17417
  const customImport = this.getAttribute("css-path") ? `@import "${this.getAttribute("css-path")}";` : "";
17416
17418
  this.shadowRoot.innerHTML = `
17417
17419
  <style>
17418
- @import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-mu@${"0.1.220"}/dist/css/nine-mu.css";
17420
+ @import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-mu@${"0.1.222"}/dist/css/nine-mu.css";
17419
17421
  ${customImport}
17420
17422
  </style>
17421
17423
  <div class="wrapper">
@@ -43634,7 +43636,7 @@ class NineDiff extends HTMLElement {
43634
43636
  const customImport = this.getAttribute("css-path") ? `@import "${this.getAttribute("css-path")}";` : "";
43635
43637
  this.shadowRoot.innerHTML = `
43636
43638
  <style>
43637
- @import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-mu@${"0.1.220"}/dist/css/nine-mu.css";
43639
+ @import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-mu@${"0.1.222"}/dist/css/nine-mu.css";
43638
43640
  ${customImport}
43639
43641
  </style>
43640
43642
 
@@ -43744,7 +43746,7 @@ render_fn2 = function() {
43744
43746
  const customImport = this.getAttribute("css-path") ? `@import "${this.getAttribute("css-path")}";` : "";
43745
43747
  this.shadowRoot.innerHTML = `
43746
43748
  <style>
43747
- @import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-mu@${"0.1.220"}/dist/css/nine-mu.css";
43749
+ @import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-mu@${"0.1.222"}/dist/css/nine-mu.css";
43748
43750
  ${customImport}
43749
43751
  </style>
43750
43752
 
@@ -44071,7 +44073,7 @@ class ChatMessageBody extends HTMLElement {
44071
44073
  const customImport = this.getAttribute("css-path") ? `@import "${this.getAttribute("css-path")}";` : "";
44072
44074
  this.shadowRoot.innerHTML = `
44073
44075
  <style>
44074
- @import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-mu@${"0.1.220"}/dist/css/nine-mu.css";
44076
+ @import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-mu@${"0.1.222"}/dist/css/nine-mu.css";
44075
44077
  ${customImport}
44076
44078
  </style>
44077
44079
 
@@ -44165,7 +44167,7 @@ if (!customElements.get("nine-chat-progress")) {
44165
44167
  customElements.define("nine-chat-progress", ProgressMessage);
44166
44168
  }
44167
44169
  const NineMu = {
44168
- version: "0.1.220",
44170
+ version: "0.1.222",
44169
44171
  init: (config2) => {
44170
44172
  trace$1.log("🛠️ Nine-Mu Engine initialized", config2);
44171
44173
  }