[Housekeeping] Bump Phoenix LiveView to 1.0.0 (#495)

* bumped liveview to 1.0.0

* Converted interpolation to new syntax
This commit is contained in:
Kieran
2024-12-06 10:37:15 -08:00
committed by GitHub
parent 0fb971dd0a
commit a5b65061f0
34 changed files with 157 additions and 135 deletions
@@ -3,7 +3,7 @@
<.icon name="hero-arrow-left" class="w-10 h-10 hover:dark:text-white" />
</.link>
<h2 class="text-title-md2 font-bold text-black dark:text-white ml-4">
Editing "<%= @media_profile.name %>"
Editing "{@media_profile.name}"
</h2>
</div>
@@ -16,11 +16,11 @@
<.table rows={@media_profiles} table_class="text-black dark:text-white">
<:col :let={media_profile} label="Name">
<.subtle_link href={~p"/media_profiles/#{media_profile.id}"}>
<%= media_profile.name %>
{media_profile.name}
</.subtle_link>
</:col>
<:col :let={media_profile} label="Preferred Resolution">
<%= media_profile.preferred_resolution %>
{media_profile.preferred_resolution}
</:col>
<:col :let={media_profile} label="Sources">
<.subtle_link href={~p"/media_profiles/#{media_profile.id}/#tab-sources"}>
@@ -6,7 +6,9 @@
<ul class="list-disc list-inside ml-2 md:ml-5">
<li>
Liquid-style:
<.inline_code>/{{ channel }}/{{ title }} - {{ id }}.{{ ext }}</.inline_code>
<.inline_code>
{"/#{double_brace("channel")}/#{double_brace("title")} - #{double_brace("id")}.#{double_brace("ext")}"}
</.inline_code>
</li>
<li>
<code class="text-sm">yt-dlp</code>-style
@@ -17,7 +19,7 @@
</li>
<li>
Any bare words:
<.inline_code>/videos/1080p/{{ id }}.{{ ext }}</.inline_code>
<.inline_code>{"/videos/1080p/#{double_brace("id")}.#{double_brace("ext")}"}</.inline_code>
</li>
</ul>
<p class="my-2">
@@ -25,7 +27,7 @@
<em>any</em>
single-word <code class="text-sm">yt-dlp</code>
option can be used as liquid-style and it's automatically made filepath-safe. For example, the
<.inline_code>{{ duration }}</.inline_code>
<.inline_code>{double_brace("duration")}</.inline_code>
option is translated to
<.inline_code>%(duration)S</.inline_code>
</p>
@@ -33,12 +35,14 @@
<strong>Major 🔑:</strong>
these syntaxes can be mixed and matched freely! I prefer to use liquid-style and bare words
but I'll include <code class="text-sm">yt-dlp</code>-style when I need more control. For example:
<.inline_code>/1080p/{{ channel }}/{{ title }}-(%(subtitles.en.-1.ext)s).{{ ext }}</.inline_code>
<.inline_code>
{"/1080p/#{double_brace("channel")}/#{double_brace("title")}-(%(subtitles.en.-1.ext)s).#{double_brace("ext")}"}
</.inline_code>
</p>
<p class="my-2">
<strong>NOTE:</strong>
Your template <em>must</em>
end with an extension option (<.inline_code>.{{ ext }}</.inline_code>
end with an extension option (<.inline_code>.{double_brace("ext")}</.inline_code>
or
<.inline_code>.%(ext)S</.inline_code>).
Downloading won't work as expected without it.
@@ -59,21 +63,21 @@
<h3 class="text-lg font-bold my-2">Media Center Custom Aliases</h3>
<ul class="list-disc list-inside mb-4 ml-2 md:ml-5 max-w-prose">
<li :for={{k, v} <- media_center_custom_output_template_options()} class="mt-1">
<.inline_code>{{ <%= k %> }}</.inline_code>
<span :if={v}>- <%= html_escape({:safe, v}) %></span>
<.inline_code>{double_brace(k)}</.inline_code>
<span :if={v}>- {html_escape({:safe, v})}</span>
</li>
</ul>
<h3 class="text-lg font-bold mb-2">Other Custom Aliases</h3>
<ul class="list-disc list-inside mb-4 ml-2 md:ml-5 max-w-prose">
<li :for={{k, v} <- other_custom_output_template_options()} class="mt-1">
<.inline_code>{{ <%= k %> }}</.inline_code>
<span :if={v}>- <%= html_escape({:safe, v}) %></span>
<.inline_code>{double_brace(k)}</.inline_code>
<span :if={v}>- {html_escape({:safe, v})}</span>
</li>
</ul>
<h3 class="text-lg font-bold mb-2">Common Options</h3>
<ul class="list-disc list-inside ml-2 md:ml-5">
<li :for={opt <- common_output_template_options()} class="mt-1">
<.inline_code>{{ <%= opt %> }}</.inline_code>
<.inline_code>{double_brace(opt)}</.inline_code>
</li>
</ul>
</section>
@@ -4,7 +4,7 @@
<.icon name="hero-arrow-left" class="w-10 h-10 hover:dark:text-white" />
</.link>
<h2 class="text-title-md2 font-bold text-black dark:text-white ml-2">
<%= @media_profile.name %>
{@media_profile.name}
</h2>
</div>
@@ -33,10 +33,10 @@
<.table rows={@sources} table_class="text-black dark:text-white">
<:col :let={source} label="Name">
<.subtle_link href={~p"/sources/#{source.id}"}>
<%= source.custom_name || source.collection_name %>
{source.custom_name || source.collection_name}
</.subtle_link>
</:col>
<:col :let={source} label="Type"><%= source.collection_type %></:col>
<:col :let={source} label="Type">{source.collection_type}</:col>
<:col :let={source} label="Should Download?">
<.icon name={if source.download_media, do: "hero-check", else: "hero-x-mark"} />
</:col>