feat: group variants of the same IPTV channel into a logical channel (#9)
Add a channelVariantGrouping service that normalizes channel names (strips region prefixes and quality tokens) to fingerprint duplicate stream entries and cluster them under a single logical channel with quality/source variants. Wire it into the Live TV channel list and player variant selection, reducing duplicates without destructively merging streams. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@ -667,6 +667,60 @@ h4 {
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
|
||||
.variant-toggle {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 4px;
|
||||
border: 0;
|
||||
background: transparent;
|
||||
color: var(--color-text-muted);
|
||||
font-size: 0.72rem;
|
||||
white-space: nowrap;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.logical-channel.expanded .variant-chevron {
|
||||
transform: rotate(180deg);
|
||||
}
|
||||
|
||||
.channel-variants {
|
||||
margin: 0 var(--space-md) var(--space-xs) 56px;
|
||||
border-left: 1px solid var(--color-border);
|
||||
}
|
||||
|
||||
.channel-variant {
|
||||
width: 100%;
|
||||
display: grid;
|
||||
grid-template-columns: minmax(52px, auto) minmax(64px, auto) 1fr;
|
||||
gap: var(--space-sm);
|
||||
padding: 6px var(--space-sm);
|
||||
border: 0;
|
||||
background: transparent;
|
||||
color: var(--color-text-muted);
|
||||
text-align: left;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.channel-variant:hover {
|
||||
background: var(--color-bg-hover);
|
||||
color: var(--color-text-primary);
|
||||
}
|
||||
|
||||
.channel-variant.is-hidden {
|
||||
opacity: 0.5;
|
||||
}
|
||||
|
||||
.variant-quality {
|
||||
color: var(--color-accent);
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.variant-name {
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
/* =====================================================
|
||||
Video Player Section
|
||||
===================================================== */
|
||||
|
||||
Reference in New Issue
Block a user