feat: Enhance Marketplace and Skill Management UI with improved error handling and user feedback
- Updated MarketplaceDrawer to include security notes and manual installation hints. - Refactored SkillDetailDrawer to display default icons for skills. - Simplified SkillListItem to use default icons for better readability. - Integrated gateway status checks and warnings in SkillsPage for improved user awareness. - Enhanced error handling for skill installation and fetching, providing clearer feedback to users. - Added new translations for error messages and gateway warnings to improve localization support.
This commit is contained in:
@@ -40,6 +40,13 @@ export function getOpenClawDir(): string {
|
||||
return join(app.getAppPath(), 'node_modules', OPENCLAW_PACKAGE_DIR_NAME);
|
||||
}
|
||||
|
||||
export function getResourcesDir(): string {
|
||||
if (app.isPackaged) {
|
||||
return process.resourcesPath;
|
||||
}
|
||||
return join(app.getAppPath(), 'resources');
|
||||
}
|
||||
|
||||
export function getOpenClawResolvedDir(): string {
|
||||
const dir = getOpenClawDir();
|
||||
if (!existsSync(dir)) {
|
||||
@@ -57,6 +64,15 @@ export function getOpenClawEntryPath(): string {
|
||||
return join(getOpenClawDir(), OPENCLAW_ENTRY_FILE_NAME);
|
||||
}
|
||||
|
||||
export function getClawHubCliBinPath(): string {
|
||||
const binName = process.platform === 'win32' ? 'clawhub.cmd' : 'clawhub';
|
||||
return join(app.getAppPath(), 'node_modules', '.bin', binName);
|
||||
}
|
||||
|
||||
export function getClawHubCliEntryPath(): string {
|
||||
return join(app.getAppPath(), 'node_modules', 'clawhub', 'bin', 'clawdhub.js');
|
||||
}
|
||||
|
||||
export function ensureDir(dir: string): string {
|
||||
if (!existsSync(dir)) {
|
||||
mkdirSync(dir, { recursive: true });
|
||||
|
||||
Reference in New Issue
Block a user