@nine-lab/nine-mu 0.1.351 → 0.1.353
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 +85 -74
- 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/exception/ExceptionHook.js +78 -85
package/dist/nine-mu.js
CHANGED
|
@@ -17538,7 +17538,7 @@ render_fn = function() {
|
|
|
17538
17538
|
const customImport = nine$1.cssPath ? `@import "${nine$1.cssPath}/nine-mu.css";` : "";
|
|
17539
17539
|
this.shadowRoot.innerHTML = `
|
|
17540
17540
|
<style>
|
|
17541
|
-
@import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-mu@${"0.1.
|
|
17541
|
+
@import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-mu@${"0.1.352"}/dist/css/nine-mu.css";
|
|
17542
17542
|
${customImport}
|
|
17543
17543
|
</style>
|
|
17544
17544
|
<div class="wrapper">
|
|
@@ -43788,7 +43788,7 @@ class NineDiff extends HTMLElement {
|
|
|
43788
43788
|
const customImport = nine.cssPath ? `@import "${nine.cssPath}/nine-mu.css";` : "";
|
|
43789
43789
|
this.shadowRoot.innerHTML = `
|
|
43790
43790
|
<style>
|
|
43791
|
-
@import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-mu@${"0.1.
|
|
43791
|
+
@import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-mu@${"0.1.352"}/dist/css/nine-mu.css";
|
|
43792
43792
|
${customImport}
|
|
43793
43793
|
</style>
|
|
43794
43794
|
|
|
@@ -43928,7 +43928,7 @@ renderScaffolding_fn = function() {
|
|
|
43928
43928
|
const customImport = nine$1.cssPath ? `@import "${nine$1.cssPath}/nine-mu.css";` : "";
|
|
43929
43929
|
this.shadowRoot.innerHTML = `
|
|
43930
43930
|
<style>
|
|
43931
|
-
@import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-mu@${"0.1.
|
|
43931
|
+
@import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-mu@${"0.1.352"}/dist/css/nine-mu.css";
|
|
43932
43932
|
${customImport}
|
|
43933
43933
|
</style>
|
|
43934
43934
|
|
|
@@ -44037,7 +44037,7 @@ render_fn2 = function() {
|
|
|
44037
44037
|
const customImport = nine$1.cssPath ? `@import "${nine$1.cssPath}/nine-mu.css";` : "";
|
|
44038
44038
|
this.shadowRoot.innerHTML = `
|
|
44039
44039
|
<style>
|
|
44040
|
-
@import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-mu@${"0.1.
|
|
44040
|
+
@import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-mu@${"0.1.352"}/dist/css/nine-mu.css";
|
|
44041
44041
|
${customImport}
|
|
44042
44042
|
</style>
|
|
44043
44043
|
|
|
@@ -44367,7 +44367,7 @@ class ChatMessageBody extends HTMLElement {
|
|
|
44367
44367
|
const customImport = nine.cssPath ? `@import "${nine.cssPath}/nine-mu.css";` : "";
|
|
44368
44368
|
this.shadowRoot.innerHTML = `
|
|
44369
44369
|
<style>
|
|
44370
|
-
@import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-mu@${"0.1.
|
|
44370
|
+
@import "https://cdn.jsdelivr.net/npm/@nine-lab/nine-mu@${"0.1.352"}/dist/css/nine-mu.css";
|
|
44371
44371
|
${customImport}
|
|
44372
44372
|
</style>
|
|
44373
44373
|
|
|
@@ -44467,55 +44467,68 @@ if (!customElements.get("nine-chat-progress")) {
|
|
|
44467
44467
|
}
|
|
44468
44468
|
const NineExceptionStyles = {
|
|
44469
44469
|
container: {
|
|
44470
|
-
padding: "
|
|
44470
|
+
padding: "25px",
|
|
44471
44471
|
margin: "20px",
|
|
44472
44472
|
background: "#121314",
|
|
44473
44473
|
// 터미널 다크 블랙 배경
|
|
44474
44474
|
border: "1px solid #343A40",
|
|
44475
|
-
//
|
|
44475
|
+
// 외곽 메탈릭 테두리
|
|
44476
44476
|
borderRadius: "6px",
|
|
44477
44477
|
fontFamily: 'Consolas, Monaco, "Courier New", monospace',
|
|
44478
|
-
// 터미널 고정폭 글꼴 우선
|
|
44479
44478
|
textAlign: "left",
|
|
44480
|
-
boxShadow: "0 4px 12px rgba(0,0,0,0.3)"
|
|
44481
|
-
|
|
44479
|
+
boxShadow: "0 4px 12px rgba(0,0,0,0.3)",
|
|
44480
|
+
lineHeight: "1.2"
|
|
44481
|
+
// ⭐ 줄간격을 터미널처럼 촘촘하게 제어
|
|
44482
|
+
},
|
|
44483
|
+
systemError: {
|
|
44484
|
+
color: "#E53E3E",
|
|
44485
|
+
// 터미널 레드 Warning
|
|
44486
|
+
fontWeight: "bold",
|
|
44487
|
+
fontSize: "14px",
|
|
44488
|
+
margin: "0 0 8px 0",
|
|
44489
|
+
// 하단 마진 축소
|
|
44490
|
+
letterSpacing: "0.5px"
|
|
44482
44491
|
},
|
|
44483
44492
|
pre: {
|
|
44484
|
-
background: "
|
|
44485
|
-
// 코드 블록 내부의 살짝 더 깊은 블랙
|
|
44493
|
+
background: "transparent",
|
|
44486
44494
|
color: "#F8F9FA",
|
|
44487
|
-
|
|
44488
|
-
|
|
44489
|
-
|
|
44490
|
-
border: "
|
|
44495
|
+
padding: "0",
|
|
44496
|
+
margin: "0 0 12px 0",
|
|
44497
|
+
// 하단 마진 축소하여 다음 라인과 밀착
|
|
44498
|
+
border: "none",
|
|
44491
44499
|
overflowX: "auto",
|
|
44492
44500
|
whiteSpace: "pre-wrap",
|
|
44493
44501
|
fontFamily: "Consolas, Monaco, monospace",
|
|
44494
|
-
fontSize: "
|
|
44495
|
-
lineHeight: "1.5"
|
|
44502
|
+
fontSize: "14px"
|
|
44496
44503
|
},
|
|
44497
44504
|
footer: {
|
|
44498
|
-
|
|
44499
|
-
|
|
44500
|
-
|
|
44505
|
+
fontSize: "14px",
|
|
44506
|
+
color: "#E2E8F0",
|
|
44507
|
+
margin: "0",
|
|
44508
|
+
// 불필요한 공백 제거
|
|
44501
44509
|
display: "flex",
|
|
44502
44510
|
flexDirection: "column",
|
|
44503
|
-
gap: "
|
|
44511
|
+
gap: "6px"
|
|
44512
|
+
},
|
|
44513
|
+
promptRow: {
|
|
44514
|
+
display: "block",
|
|
44515
|
+
// 자연스러운 텍스트 흐름을 위해 block 처리
|
|
44516
|
+
margin: "0"
|
|
44504
44517
|
},
|
|
44505
|
-
|
|
44506
|
-
|
|
44507
|
-
background: "
|
|
44508
|
-
|
|
44509
|
-
|
|
44518
|
+
// ⭐ y 글자에 직접 바인딩할 터미널 링크 스타일
|
|
44519
|
+
cliLink: {
|
|
44520
|
+
background: "transparent",
|
|
44521
|
+
color: "#38A169",
|
|
44522
|
+
// 터미널 그린
|
|
44510
44523
|
border: "none",
|
|
44511
|
-
|
|
44512
|
-
|
|
44524
|
+
padding: "0 2px",
|
|
44525
|
+
fontFamily: "Consolas, Monaco, monospace",
|
|
44526
|
+
fontSize: "14px",
|
|
44513
44527
|
fontWeight: "bold",
|
|
44514
|
-
|
|
44515
|
-
|
|
44516
|
-
|
|
44517
|
-
|
|
44518
|
-
// 버튼 텍스트는 일반 폰트로 가독성 확보
|
|
44528
|
+
cursor: "pointer",
|
|
44529
|
+
textDecoration: "underline",
|
|
44530
|
+
textUnderlineOffset: "2px",
|
|
44531
|
+
display: "inline"
|
|
44519
44532
|
}
|
|
44520
44533
|
};
|
|
44521
44534
|
class NineExceptionHook extends React.Component {
|
|
@@ -44525,6 +44538,7 @@ class NineExceptionHook extends React.Component {
|
|
|
44525
44538
|
this.lastPath = window.location.pathname;
|
|
44526
44539
|
this.handleLocationChange = this.handleLocationChange.bind(this);
|
|
44527
44540
|
this.handleReport = this.handleReport.bind(this);
|
|
44541
|
+
this.handleKeyDown = this.handleKeyDown.bind(this);
|
|
44528
44542
|
}
|
|
44529
44543
|
static getDerivedStateFromError(error) {
|
|
44530
44544
|
return { hasError: true, error, reportStatus: "idle" };
|
|
@@ -44538,15 +44552,25 @@ class NineExceptionHook extends React.Component {
|
|
|
44538
44552
|
componentDidMount() {
|
|
44539
44553
|
window.addEventListener("popstate", this.handleLocationChange);
|
|
44540
44554
|
document.addEventListener("click", this.handleLocationChange, true);
|
|
44555
|
+
window.addEventListener("keydown", this.handleKeyDown);
|
|
44541
44556
|
}
|
|
44542
44557
|
componentWillUnmount() {
|
|
44543
44558
|
window.removeEventListener("popstate", this.handleLocationChange);
|
|
44544
44559
|
document.removeEventListener("click", this.handleLocationChange, true);
|
|
44560
|
+
window.removeEventListener("keydown", this.handleKeyDown);
|
|
44561
|
+
}
|
|
44562
|
+
handleKeyDown(e) {
|
|
44563
|
+
if (this.state.hasError && this.state.reportStatus === "idle") {
|
|
44564
|
+
if (e.key === "y" || e.key === "Y") {
|
|
44565
|
+
e.preventDefault();
|
|
44566
|
+
this.handleReport();
|
|
44567
|
+
}
|
|
44568
|
+
}
|
|
44545
44569
|
}
|
|
44546
44570
|
handleLocationChange() {
|
|
44547
44571
|
setTimeout(() => {
|
|
44548
44572
|
if (this.state.hasError && this.lastPath !== window.location.pathname) {
|
|
44549
|
-
console.log("[Nine-Library] 페이지 주소 변경 감지 ->
|
|
44573
|
+
console.log("[Nine-Library] 페이지 주소 변경 감지 -> 에러 상태 초기화");
|
|
44550
44574
|
this.lastPath = window.location.pathname;
|
|
44551
44575
|
this.setState({ hasError: false, error: null, reportStatus: "idle" });
|
|
44552
44576
|
}
|
|
@@ -44564,7 +44588,7 @@ class NineExceptionHook extends React.Component {
|
|
|
44564
44588
|
console.warn("[Nine-Library] window.triggerAutoRecovery 가 정의되지 않았습니다.");
|
|
44565
44589
|
}
|
|
44566
44590
|
this.setState({ reportStatus: "success" });
|
|
44567
|
-
},
|
|
44591
|
+
}, 600);
|
|
44568
44592
|
}
|
|
44569
44593
|
render() {
|
|
44570
44594
|
var _a2;
|
|
@@ -44574,60 +44598,47 @@ class NineExceptionHook extends React.Component {
|
|
|
44574
44598
|
}
|
|
44575
44599
|
const errorMessage = ((_a2 = this.state.error) == null ? void 0 : _a2.message) || String(this.state.error);
|
|
44576
44600
|
const customStyles = this.props.styles || {};
|
|
44577
|
-
let buttonText = "🚀 관제탑에 에러 피드백 전송하기";
|
|
44578
|
-
if (this.state.reportStatus === "sending") buttonText = "⏳ 관제탑 연락 중...";
|
|
44579
|
-
if (this.state.reportStatus === "success") buttonText = "✅ 전송 완료! AI 분석 시작";
|
|
44580
44601
|
return React.createElement(
|
|
44581
44602
|
"div",
|
|
44582
44603
|
{
|
|
44583
44604
|
style: { ...NineExceptionStyles.container, ...customStyles.container, ...this.props.containerStyle }
|
|
44584
44605
|
},
|
|
44585
|
-
|
|
44586
|
-
// 1. 상단 프롬프트 헤더 (시스템 상태 알림)
|
|
44587
|
-
React.createElement(
|
|
44588
|
-
'div',
|
|
44589
|
-
{ style: { ...NineExceptionStyles.title, ...customStyles.title } },
|
|
44590
|
-
React.createElement('span', { style: { color: '#38A169', marginRight: '5px' } }, 'nandoo@nine-mu:~$'),
|
|
44591
|
-
'./system-check --status'
|
|
44592
|
-
), */
|
|
44593
|
-
// 2. 시스템 에러 감지 출력 로그
|
|
44606
|
+
// 1. 에러 감지 로그
|
|
44594
44607
|
React.createElement(
|
|
44595
44608
|
"div",
|
|
44596
|
-
{ style: {
|
|
44609
|
+
{ style: { ...NineExceptionStyles.systemError, ...customStyles.systemError } },
|
|
44597
44610
|
"[SYSTEM] COMPONENT RENDER ERROR DETECTED"
|
|
44598
44611
|
),
|
|
44599
|
-
|
|
44600
|
-
// 3. 명령어 입력 시뮬레이션 ($ cat error.log)
|
|
44601
|
-
React.createElement(
|
|
44602
|
-
'p',
|
|
44603
|
-
{ style: { ...NineExceptionStyles.label, ...customStyles.label } },
|
|
44604
|
-
React.createElement('span', { style: { color: '#3182CE', marginRight: '6px' } }, 'nandoo@nine-mu:~$'),
|
|
44605
|
-
'cat error.log'
|
|
44606
|
-
), */
|
|
44607
|
-
// 4. 에러 내용 본문 박스
|
|
44612
|
+
// 2. 에러 내용 (하단 마진을 줄여 다음 줄과 간격을 맞춤)
|
|
44608
44613
|
React.createElement("pre", { style: { ...NineExceptionStyles.pre, ...customStyles.pre } }, errorMessage),
|
|
44609
|
-
//
|
|
44614
|
+
// 3. CLI 프롬프트 및 링크 영역
|
|
44610
44615
|
React.createElement(
|
|
44611
44616
|
"div",
|
|
44612
44617
|
{ style: { ...NineExceptionStyles.footer, ...customStyles.footer } },
|
|
44613
|
-
React.createElement(
|
|
44614
|
-
"
|
|
44615
|
-
{
|
|
44616
|
-
|
|
44617
|
-
|
|
44618
|
-
|
|
44619
|
-
|
|
44620
|
-
|
|
44618
|
+
this.state.reportStatus === "idle" && React.createElement(
|
|
44619
|
+
"div",
|
|
44620
|
+
{ style: NineExceptionStyles.promptRow },
|
|
44621
|
+
React.createElement("span", null, "Send error log to Control Tower ("),
|
|
44622
|
+
React.createElement(
|
|
44623
|
+
"button",
|
|
44624
|
+
{
|
|
44625
|
+
style: { ...NineExceptionStyles.cliLink, ...customStyles.cliLink },
|
|
44626
|
+
onClick: this.handleReport
|
|
44621
44627
|
},
|
|
44622
|
-
|
|
44623
|
-
|
|
44624
|
-
|
|
44625
|
-
|
|
44628
|
+
"y"
|
|
44629
|
+
),
|
|
44630
|
+
React.createElement("span", null, "/n)?")
|
|
44631
|
+
),
|
|
44632
|
+
this.state.reportStatus === "sending" && React.createElement(
|
|
44633
|
+
"div",
|
|
44634
|
+
{ style: { color: "#ED8936" } },
|
|
44635
|
+
">> Connecting to Control Tower... Sending payload."
|
|
44626
44636
|
),
|
|
44627
44637
|
this.state.reportStatus === "success" && React.createElement(
|
|
44628
44638
|
"div",
|
|
44629
|
-
{ style: {
|
|
44630
|
-
"
|
|
44639
|
+
{ style: { display: "flex", flexDirection: "column", gap: "4px" } },
|
|
44640
|
+
React.createElement("div", { style: { color: "#38A169", fontWeight: "bold" } }, ">> Transmit complete. Core engine initialized."),
|
|
44641
|
+
React.createElement("div", { style: { color: "#A0AEC0", fontStyle: "italic", fontSize: "13px" } }, "AI가 소스 코드를 재수정하는 동안 잠시만 기다려주세요...")
|
|
44631
44642
|
)
|
|
44632
44643
|
)
|
|
44633
44644
|
);
|
|
@@ -44636,7 +44647,7 @@ class NineExceptionHook extends React.Component {
|
|
|
44636
44647
|
}
|
|
44637
44648
|
}
|
|
44638
44649
|
const NineMu = {
|
|
44639
|
-
version: "0.1.
|
|
44650
|
+
version: "0.1.352",
|
|
44640
44651
|
init: (config2) => {
|
|
44641
44652
|
trace$1.log("🛠️ Nine-Mu Engine initialized", config2);
|
|
44642
44653
|
}
|