Skip to content

feat(ui): programme details in the live channel context menu - #1387

Closed
4gray wants to merge 3 commits into
masterfrom
claude/live-list-program-details-menu
Closed

feat(ui): programme details in the live channel context menu#1387
4gray wants to merge 3 commits into
masterfrom
claude/live-list-program-details-menu

Conversation

@4gray

@4gray 4gray commented Aug 8, 2026

Copy link
Copy Markdown
Owner

Follow-up to the discussion in #1341: the Xtream and Stalker live sidebars intentionally have no per-row (i) button (the current programme is already shown inline), but that left no way to read a programme description without switching channels. Instead of adding a third button to every row, the programme details are now reachable through the row context menu, consistently across live lists.

What changed

  • Xtream live sidebar (portal-channels-list) and Stalker ITV sidebar (stalker-live-stream-layout): right-click now offers "Show program details" (opens the existing EpgItemDescriptionComponent dialog) whenever the row has a current preview programme.
  • Favorites / recently-viewed lists (global-favorites-list, used by the portal favorites/recent tabs and global favorites): the same item appears when the row has a current programme.
  • The context-menu availability gate now keys on what the menu can actually offer (mapping support or a current programme) instead of EPG-mapping support alone. Note this is future-proofing, not PWA support: EPG previews are currently populated only where supportsEpg (Electron), so in the PWA the maps stay empty and the item does not appear — behavior there is unchanged. If portal EPG previews ever land in the PWA, the menu lights up automatically. "Map EPG" itself stays Electron-gated.
  • Reuses the existing EPG.PROGRAM_DIALOG.SHOW_PROGRAM_DETAILS key — no new translations needed. Icon is event_note to avoid clashing with the M3U "Show details" (channel metadata) item that already uses info in the favorites menu.

Rationale

The sidebar row already shows the programme title, time, and progress inline, and selecting a channel opens the full EPG timeline — a third per-row button would add action density to a high-frequency zapping surface and appear/disappear per row depending on EPG coverage. The context menu gives consistent access everywhere with zero visual noise.

Tests

  • portal-channels-list spec: menu offered only when a programme exists (no mapping support in harness), programme lookup, dialog open.
  • stalker-live-stream-layout spec: programme lookup and dialog open via the preview-programme map.
  • global-favorites-list spec: enriched-row programme flows into the menu and opens the dialog.
  • All three suites green; lint clean; nx build web (template typecheck) passes; release note added (release:notes:validate passes).

🤖 Generated with Claude Code

The Xtream and Stalker live sidebars hide the per-row (i) button by
design — the current programme is already inline — which left no way to
read a programme description without switching channels. Right-click now
offers "Show program details" (opening the existing EPG description
dialog) in both portal sidebars and in the favorites/recently-viewed
lists, whenever the row has a current programme. The context menu is no
longer gated on EPG-mapping support alone, so the item also works in the
PWA.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@greptile-apps

greptile-apps Bot commented Aug 8, 2026

Copy link
Copy Markdown

Greptile Summary

This PR adds programme-description access to live-channel context menus without increasing per-row action density.

  • Adds “Show program details” to Xtream and Stalker live sidebars when preview EPG data exists.
  • Adds the same action to shared favorites and recently viewed lists.
  • Separates programme-detail availability from the Electron-only EPG-mapping capability.
  • Adds focused component tests and a user-facing release note.

Confidence Score: 5/5

The PR appears safe to merge; no concrete changed-code failure remains.

The new menu actions consistently resolve the selected row’s existing programme association, preserve capability gating for EPG mapping, and defensively no-op if programme data is unavailable.

Important Files Changed

Filename Overview
libs/portal/shared/ui/src/lib/components/global-favorites-list/global-favorites-list.component.ts Extends the shared favorites/recent context-menu gate and opens the existing programme-description dialog from the enriched row.
libs/portal/stalker/feature/src/lib/stalker-live-stream-layout/stalker-live-stream-layout.component.ts Resolves the selected Stalker row’s normalized preview programme and exposes it through the context menu.
libs/portal/xtream/feature/src/lib/portal-channels-list/portal-channels-list.component.ts Resolves Xtream preview EPG by stream ID and adds programme details independently of EPG-mapping support.
libs/portal/shared/ui/src/lib/components/global-favorites-list/global-favorites-list.component.html Conditionally renders the programme-details action for enriched favorite and recent rows.
libs/portal/stalker/feature/src/lib/stalker-live-stream-layout/stalker-live-stream-layout.component.html Adds the programme-details menu item while retaining Electron-gated EPG mapping and radio-mode suppression.
libs/portal/xtream/feature/src/lib/portal-channels-list/portal-channels-list.component.html Enables the context-menu affordance for rows with preview EPG and conditionally renders each available action.

Sequence Diagram

sequenceDiagram
    participant User
    participant Row as Live channel row
    participant Menu as Context menu
    participant EPG as Current programme map
    participant Dialog as Programme details dialog
    User->>Row: Right-click channel
    Row->>EPG: Check current programme
    EPG-->>Row: Programme or none
    Row->>Menu: Open when an action is available
    User->>Menu: Select Show program details
    Menu->>EPG: Resolve row programme
    EPG-->>Dialog: EpgProgram
    Dialog-->>User: Show programme description
Loading

Reviews (1): Last reviewed commit: "feat(ui): offer programme details from t..." | Re-trigger Greptile

@4gray

4gray commented Aug 8, 2026

Copy link
Copy Markdown
Owner Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 9ca7175bff

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".


/** Whether right-click has anything to offer for this row. */
hasChannelContextMenu(item: XtreamChannelListItem): boolean {
return this.supportsEpgMapping || this.epgPrograms.has(item.xtream_id);

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Populate EPG data before enabling PWA menu support

When running as a PWA (window.electron is absent), supportsEpgMapping is false and epgPrograms can never make this fallback true: every Xtream population path is guarded by supportsEpg, which itself requires Electron bridge methods. The same problem affects the other changed surfaces—the Stalker layout explicitly clears epgPreviewPrograms when supportsEpg is false, and UnifiedLiveTabComponent clears the favorites/recent EPG map—so the new program-details action remains unavailable throughout the PWA despite the change's intended PWA support. Populate portal-provided EPG independently of the Electron-only capability, and cover the actual PWA path rather than only injecting a map in unit tests.

AGENTS.md reference: AGENTS.md:L79-L85

Useful? React with 👍 / 👎.

EPG previews are populated only where supportsEpg (Electron), so the
programme-details menu item cannot appear in the PWA today; the
data-presence gate is future-proofing, not PWA support (Codex review).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@4gray

4gray commented Aug 8, 2026

Copy link
Copy Markdown
Owner Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. 👍

Reviewed commit: 9028f919fb

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

The main layout spec was one effective line under the 1200 max-lines
test budget; the new context-menu test tipped it over and failed CI
lint. Following the playback-session-key precedent, the test moves into
its own template-less spec — which also restores the negative assertion,
since this harness runs without EPG-mapping support.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@4gray

4gray commented Aug 9, 2026

Copy link
Copy Markdown
Owner Author

Superseded: instead of hiding programme details behind the context menu, the (i) button now appears in all live lists with the row actions stacked vertically (star on top, info below, reserved slot — no horizontal cost, no layout jumps). Landing as part of #1341 where the row layout was already being reworked.

@4gray 4gray closed this Aug 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant