fix(themes): pages themes Twitch vides -> requetes Helix tokenisees + fallbacks game_id/top-streams

This commit is contained in:
2026-09-26 18:46:55 -04:00
parent db03b70854
commit 21f2296c41
4 changed files with 389 additions and 87 deletions
@@ -215,8 +215,10 @@ export class ThemePageComponent {
return;
}
// Twitch hors live/trending : VODs + clips + fallback top streams.
// Helix ne matche pas les longues phrases : un seul mot-clé court.
if (block.provider === 'twitch') {
const q = tokens.join(' ');
const raw = tokens.join(' ').trim();
const q = (raw.split(/[^A-Za-z0-9à-ÿ]+/).filter(w => w.length >= 3)[0] || raw).trim();
const call = q ? this.api.searchTwitchThemePage(q, null) : this.api.getTwitchTopStreamsPage(null);
call.subscribe({
next: res => {