Compare commits

..

3 Commits

Author SHA1 Message Date
xRangerDE
c2b9b5759a release: 5.1.0-alpha.2 — Command Palette Streamer-Suche
Pillar 5 (UI Power) erweitert: Ctrl+K matched jetzt auch Streamer-Namen
(tippe Name oder @login → springt direkt zum Streamer im VODs-Tab).
Plus .gitignore-Hygiene.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-12 01:25:39 +02:00
xRangerDE
825c5dc96c feat(cmd-palette): add streamer search — type name or @login to jump
Reads config.streamers from the renderer global, builds one command per
streamer with label=name and keywords='@name name'. Action: showTab('vods')
+ selectStreamer(name). No-op if selectStreamer is unavailable
(e.g. on platforms where the streamers list wasn't loaded yet).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-12 01:25:25 +02:00
xRangerDE
a6b64ddf15 .gitignore: tmp_e2e_full/tmp_bugtest/tmp_dl test artifacts + codeberg stub
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-12 01:24:02 +02:00
4 changed files with 47 additions and 11 deletions

8
.gitignore vendored
View File

@ -3,3 +3,11 @@ dist/
release/ release/
*.log *.log
.DS_Store .DS_Store
# Test-Artefakte
tmp_e2e_full/
tmp_bugtest/
tmp_dl/
# Dev-Scripts ohne Token (Stub, nicht produktiv)
codeberg_api_upload.sh

4
package-lock.json generated
View File

@ -1,12 +1,12 @@
{ {
"name": "twitch-vod-manager", "name": "twitch-vod-manager",
"version": "5.1.0-alpha.1", "version": "5.1.0-alpha.2",
"lockfileVersion": 3, "lockfileVersion": 3,
"requires": true, "requires": true,
"packages": { "packages": {
"": { "": {
"name": "twitch-vod-manager", "name": "twitch-vod-manager",
"version": "5.1.0-alpha.1", "version": "5.1.0-alpha.2",
"license": "MIT", "license": "MIT",
"dependencies": { "dependencies": {
"axios": "^1.6.0", "axios": "^1.6.0",

View File

@ -1,6 +1,6 @@
{ {
"name": "twitch-vod-manager", "name": "twitch-vod-manager",
"version": "5.1.0-alpha.1", "version": "5.1.0-alpha.2",
"description": "Twitch VOD Manager - Download Twitch VODs easily", "description": "Twitch VOD Manager - Download Twitch VODs easily",
"main": "dist/main.js", "main": "dist/main.js",
"author": "xRangerDE", "author": "xRangerDE",

View File

@ -18,27 +18,55 @@ interface PaletteCommand {
}; };
function buildCommands(): PaletteCommand[] { function buildCommands(): PaletteCommand[] {
const showTab = (window as unknown as { showTab?: (tab: string) => void }).showTab; const w = window as unknown as {
showTab?: (tab: string) => void;
selectStreamer?: (name: string, forceRefresh?: boolean) => Promise<void>;
config?: { streamers?: Array<{ name: string }> };
};
const showTab = w.showTab;
if (typeof showTab !== 'function') { if (typeof showTab !== 'function') {
return []; return [];
} }
const tabs: Array<{ id: string; labels: string[]; hint: string }> = [ const tabs: Array<{ id: string; labels: string[]; hint: string }> = [
{ id: 'vods', labels: ['VODs', 'videos', 'streams'], hint: 'Go' }, { id: 'vods', labels: ['VODs', 'videos', 'streams'], hint: 'Tab' },
{ id: 'queue', labels: ['Queue', 'downloads', 'warteschlange'], hint: 'Go' }, { id: 'queue', labels: ['Queue', 'downloads', 'warteschlange'], hint: 'Tab' },
{ id: 'streamers', labels: ['Streamers', 'channels'], hint: 'Go' }, { id: 'streamers', labels: ['Streamers', 'channels'], hint: 'Tab' },
{ id: 'stats', labels: ['Stats', 'statistiken', 'dashboard'], hint: 'Go' }, { id: 'stats', labels: ['Stats', 'statistiken', 'dashboard'], hint: 'Tab' },
{ id: 'archive', labels: ['Archive', 'archiv'], hint: 'Go' }, { id: 'archive', labels: ['Archive', 'archiv'], hint: 'Tab' },
{ id: 'settings', labels: ['Settings', 'einstellungen', 'config'], hint: 'Go' }, { id: 'settings', labels: ['Settings', 'einstellungen', 'config'], hint: 'Tab' },
]; ];
return tabs.map(t => ({ const tabCommands: PaletteCommand[] = tabs.map(t => ({
id: 'tab:' + t.id, id: 'tab:' + t.id,
label: t.labels[0], label: t.labels[0],
hint: t.hint, hint: t.hint,
keywords: t.labels.join(' ').toLowerCase(), keywords: t.labels.join(' ').toLowerCase(),
action: () => showTab(t.id), action: () => showTab(t.id),
})); }));
// Streamer-Liste aus globalem config (gefuellt nach renderer-Init).
const streamerCommands: PaletteCommand[] = [];
const streamers = Array.isArray(w.config?.streamers) ? w.config.streamers : [];
const selectStreamer = w.selectStreamer;
if (typeof selectStreamer === 'function') {
for (const entry of streamers) {
if (!entry || typeof entry.name !== 'string') continue;
const name = entry.name;
streamerCommands.push({
id: 'streamer:' + name.toLowerCase(),
label: name,
hint: 'Streamer',
keywords: ('@' + name + ' ' + name).toLowerCase(),
action: () => {
showTab('vods');
void selectStreamer(name);
},
});
}
}
return [...tabCommands, ...streamerCommands];
} }
function getModal(): HTMLElement | null { function getModal(): HTMLElement | null {