Skip to content

Conversation

@syeopite
Copy link
Member

Closes #2564

transcripts widget
video description transcript toggle

The current description box isn't really designed to hold non preformatted content hence the extraneous spacing at the bottom. Once #4111 is merged the description box should get a redesign to better accommodate these description widgets and how they should be affected by the expand description user preference.

@syeopite syeopite requested review from a team and SamantazFox as code owners May 11, 2025 04:02

addEventListener("DOMContentLoaded", () => {
const transcriptLines = document.getElementById("lines");
for (const transcriptLine of transcriptLines.children) {
Copy link
Contributor

Choose a reason for hiding this comment

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

I'd recommend adding the click event listener on transcriptLines and checking the event's target. This would have better performance than adding an event listener onto each transcriptLine

}
});

addEventListener("DOMContentLoaded", () => {
Copy link
Contributor

Choose a reason for hiding this comment

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

I don't remember if internet explorer is still a supported browser or not but arrow functions aren't supported in IE. So if it is still supported it will need to be changed. https://caniuse.com/arrow-functions

Suggested change
addEventListener("DOMContentLoaded", () => {
addEventListener("DOMContentLoaded", function() {

margin: 0;
}

.transcript-line:hover, .selected.transcript-line, .transcript-title-line:hover, .selected.transcript-title-line {
Copy link
Member

Choose a reason for hiding this comment

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

Hovering looks great on light mode, but it doesn't look great on dark mode (the default used by invidious).

2025-05-13_12-10

Suggested change
.transcript-line:hover, .selected.transcript-line, .transcript-title-line:hover, .selected.transcript-title-line {
.transcript-line:hover, .selected.transcript-line, .transcript-title-line:hover, .selected.transcript-title-line {
background: #4f4f4f;
}
.light-theme .transcript-line:hover, .selected.transcript-line, .transcript-title-line:hover, .selected.transcript-title-line {
background: #cacaca;
}

With the suggestion, it now looks like this:

2025-05-13_12-27
2025-05-13_12-12

@Fijxu
Copy link
Member

Fijxu commented May 13, 2025

In testing on https://inv.nadeko.net with my CSS suggestion applied

R0gu3h3h3h3 pushed a commit to R0gu3h3h3h3/oiia that referenced this pull request May 16, 2025
@8bitjoe
Copy link

8bitjoe commented Sep 19, 2025

What's missing to get this upstream?

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.

[Feature request] Add support for transcripts

4 participants