更新大量 tsx 原始文件; 已经迁移 login panel; 部分 (#121)

* style(B1-1): 格式化 ink/buddy/cli/context/screens/tasks/services/keybindings/state (43 files)

纯格式化:移除分号、React Compiler import、import 多行展开。
修复了 Box.tsx 和 ScrollBox.tsx 中无效的 global.d.ts import。

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* style(B1-2): 格式化 commands (79 files)

纯格式化:移除分号、React Compiler import、import 多行展开。

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* style(B1-3): 格式化 components/messages,permissions,mcp,sandbox,shell (104 files)

纯格式化:移除分号、React Compiler import、import 多行展开。

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* style(B1-4): 格式化 components/PromptInput,FeedbackSurvey,tasks,agents,skills,design-system,wizard (73 files)

纯格式化:移除分号、React Compiler import、import 多行展开。

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* style(B1-5): 格式化 components其余 + hooks + tools (232 files)

纯格式化:移除分号、React Compiler import、import 多行展开。

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* style(B1-6): 格式化 main/entrypoints/utils/moreright (21 files)

纯格式化:移除分号、React Compiler import、import 多行展开。

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* docs: 更新 README,新增 Run.ps1/TODO.md,删除 V6.md

- README.md: 大幅重写,更详细版本历史和配置示例
- Run.ps1: 新增 Windows 启动脚本
- TODO.md: 新增包完成清单
- V6.md: 删除(架构重构规划已不适用)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* fix: 修复以前的问题

* fix: 修复 login 面板的问题

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
claude-code-best
2026-04-04 23:24:27 +08:00
committed by GitHub
parent 02694918b5
commit 5b1a52b8e0
559 changed files with 103807 additions and 101817 deletions

View File

@@ -1,127 +1,80 @@
import { c as _c } from "react/compiler-runtime";
import * as React from 'react';
import { useEffect, useMemo } from 'react';
import { getIsRemoteMode } from '../../bootstrap/state.js';
import { useNotifications } from '../../context/notifications.js';
import { Text } from '../../ink.js';
import { useAppState } from '../../state/AppState.js';
import { logForDebugging } from '../../utils/debug.js';
import { plural } from '../../utils/stringUtils.js';
export function usePluginInstallationStatus() {
const $ = _c(20);
const {
addNotification
} = useNotifications();
const installationStatus = useAppState(_temp);
let t0;
bb0: {
if (!installationStatus) {
let t1;
if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
t1 = {
import * as React from 'react'
import { useEffect, useMemo } from 'react'
import { getIsRemoteMode } from '../../bootstrap/state.js'
import { useNotifications } from '../../context/notifications.js'
import { Text } from '../../ink.js'
import { useAppState } from '../../state/AppState.js'
import { logForDebugging } from '../../utils/debug.js'
import { plural } from '../../utils/stringUtils.js'
export function usePluginInstallationStatus(): void {
const { addNotification } = useNotifications()
const installationStatus = useAppState(s => s.plugins.installationStatus)
// Memoize the failed counts to prevent unnecessary effect triggers
const { totalFailed, failedMarketplacesCount, failedPluginsCount } =
useMemo(() => {
if (!installationStatus) {
return {
totalFailed: 0,
failedMarketplacesCount: 0,
failedPluginsCount: 0
};
$[0] = t1;
} else {
t1 = $[0];
failedPluginsCount: 0,
}
}
t0 = t1;
break bb0;
}
let t1;
if ($[1] !== installationStatus.marketplaces) {
t1 = installationStatus.marketplaces.filter(_temp2);
$[1] = installationStatus.marketplaces;
$[2] = t1;
} else {
t1 = $[2];
}
const failedMarketplaces = t1;
let t2;
if ($[3] !== installationStatus.plugins) {
t2 = installationStatus.plugins.filter(_temp3);
$[3] = installationStatus.plugins;
$[4] = t2;
} else {
t2 = $[4];
}
const failedPlugins = t2;
const t3 = failedMarketplaces.length + failedPlugins.length;
let t4;
if ($[5] !== failedMarketplaces.length || $[6] !== failedPlugins.length || $[7] !== t3) {
t4 = {
totalFailed: t3,
const failedMarketplaces = installationStatus.marketplaces.filter(
m => m.status === 'failed',
)
const failedPlugins = installationStatus.plugins.filter(
p => p.status === 'failed',
)
return {
totalFailed: failedMarketplaces.length + failedPlugins.length,
failedMarketplacesCount: failedMarketplaces.length,
failedPluginsCount: failedPlugins.length
};
$[5] = failedMarketplaces.length;
$[6] = failedPlugins.length;
$[7] = t3;
$[8] = t4;
} else {
t4 = $[8];
failedPluginsCount: failedPlugins.length,
}
}, [installationStatus])
useEffect(() => {
if (getIsRemoteMode()) return
if (!installationStatus) {
logForDebugging('No installation status to monitor')
return
}
t0 = t4;
}
const {
if (totalFailed === 0) {
return
}
logForDebugging(
`Plugin installation status: ${failedMarketplacesCount} failed marketplaces, ${failedPluginsCount} failed plugins`,
)
if (totalFailed === 0) {
return
}
// Add notification for failures
logForDebugging(
`Adding notification for ${totalFailed} failed installations`,
)
addNotification({
key: 'plugin-install-failed',
jsx: (
<>
<Text color="error">
{totalFailed} {plural(totalFailed, 'plugin')} failed to install
</Text>
<Text dimColor> · /plugin for details</Text>
</>
),
priority: 'medium',
})
}, [
addNotification,
totalFailed,
failedMarketplacesCount,
failedPluginsCount
} = t0;
let t1;
if ($[9] !== addNotification || $[10] !== failedMarketplacesCount || $[11] !== failedPluginsCount || $[12] !== installationStatus || $[13] !== totalFailed) {
t1 = () => {
if (getIsRemoteMode()) {
return;
}
if (!installationStatus) {
logForDebugging("No installation status to monitor");
return;
}
if (totalFailed === 0) {
return;
}
logForDebugging(`Plugin installation status: ${failedMarketplacesCount} failed marketplaces, ${failedPluginsCount} failed plugins`);
if (totalFailed === 0) {
return;
}
logForDebugging(`Adding notification for ${totalFailed} failed installations`);
addNotification({
key: "plugin-install-failed",
jsx: <><Text color="error">{totalFailed} {plural(totalFailed, "plugin")} failed to install</Text><Text dimColor={true}> · /plugin for details</Text></>,
priority: "medium"
});
};
$[9] = addNotification;
$[10] = failedMarketplacesCount;
$[11] = failedPluginsCount;
$[12] = installationStatus;
$[13] = totalFailed;
$[14] = t1;
} else {
t1 = $[14];
}
let t2;
if ($[15] !== addNotification || $[16] !== failedMarketplacesCount || $[17] !== failedPluginsCount || $[18] !== totalFailed) {
t2 = [addNotification, totalFailed, failedMarketplacesCount, failedPluginsCount];
$[15] = addNotification;
$[16] = failedMarketplacesCount;
$[17] = failedPluginsCount;
$[18] = totalFailed;
$[19] = t2;
} else {
t2 = $[19];
}
useEffect(t1, t2);
}
function _temp3(p) {
return p.status === "failed";
}
function _temp2(m) {
return m.status === "failed";
}
function _temp(s) {
return s.plugins.installationStatus;
failedPluginsCount,
])
}