diff --git a/assets/css/default.css b/assets/css/default.css index 2cedcf0c..c9bb9619 100644 --- a/assets/css/default.css +++ b/assets/css/default.css @@ -816,3 +816,7 @@ h1, h2, h3, h4, h5, p, #download_widget { width: 100%; } +.description-chapters-content-container { + display: flex; + flex-direction: row; +} diff --git a/src/invidious/views/components/description_chapters_widget.ecr b/src/invidious/views/components/description_chapters_widget.ecr new file mode 100644 index 00000000..e5ecdb99 --- /dev/null +++ b/src/invidious/views/components/description_chapters_widget.ecr @@ -0,0 +1,27 @@ +<% if !chapters.empty? %> +
+
+

+

Chapters
+ +
+ <% chapters.each do | chapter |%> + + <% end %> +
+
+
+<% end %> \ No newline at end of file diff --git a/src/invidious/views/watch.ecr b/src/invidious/views/watch.ecr index 45c58a16..d18622b7 100644 --- a/src/invidious/views/watch.ecr +++ b/src/invidious/views/watch.ecr @@ -254,10 +254,16 @@ we're going to need to do it here in order to allow for translations.
<% if video.description.size < 200 || params.extend_desc %> -
<%= video.description_html %>
+
+ <%= video.description_html %> + <%= rendered "components/description_chapters_widget" %> +
<% else %> -
<%= video.description_html %>
+
+ <%= video.description_html %> + <%= rendered "components/description_chapters_widget" %> +