[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:
parent
0fb971dd0a
commit
a5b65061f0
34 changed files with 157 additions and 135 deletions
|
|
@ -41,4 +41,15 @@ defmodule Pinchflat.Utils.StringUtils do
|
|||
string
|
||||
end
|
||||
end
|
||||
|
||||
@doc """
|
||||
Wraps a string in double braces. Useful as a UI helper now that
|
||||
LiveView 1.0.0 allows `{}` for interpolation so now we can't use braces
|
||||
directly in the view.
|
||||
|
||||
Returns binary()
|
||||
"""
|
||||
def double_brace(string) do
|
||||
"{{ #{string} }}"
|
||||
end
|
||||
end
|
||||
|
|
|
|||
|
|
@ -100,6 +100,7 @@ defmodule PinchflatWeb do
|
|||
import PinchflatWeb.CustomComponents.TextComponents
|
||||
import PinchflatWeb.CustomComponents.TableComponents
|
||||
import PinchflatWeb.CustomComponents.ButtonComponents
|
||||
import Pinchflat.Utils.StringUtils, only: [double_brace: 1]
|
||||
|
||||
alias Pinchflat.Settings
|
||||
alias Pinchflat.Utils.StringUtils
|
||||
|
|
|
|||
|
|
@ -82,7 +82,7 @@ defmodule PinchflatWeb.CoreComponents do
|
|||
</button>
|
||||
</div>
|
||||
<div id={"#{@id}-content"}>
|
||||
<%= render_slot(@inner_block) %>
|
||||
{render_slot(@inner_block)}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
@ -126,9 +126,9 @@ defmodule PinchflatWeb.CoreComponents do
|
|||
]}>
|
||||
<main>
|
||||
<h5 :if={@title} class="mb-2 text-lg font-bold">
|
||||
<%= @title %>
|
||||
{@title}
|
||||
</h5>
|
||||
<p class="mt-2 text-md leading-5 opacity-80"><%= msg %></p>
|
||||
<p class="mt-2 text-md leading-5 opacity-80">{msg}</p>
|
||||
</main>
|
||||
<button
|
||||
type="button"
|
||||
|
|
@ -208,9 +208,9 @@ defmodule PinchflatWeb.CoreComponents do
|
|||
def simple_form(assigns) do
|
||||
~H"""
|
||||
<.form :let={f} for={@for} as={@as} {@rest}>
|
||||
<%= render_slot(@inner_block, f) %>
|
||||
{render_slot(@inner_block, f)}
|
||||
<div :for={action <- @actions} class="mt-2 flex items-center justify-between gap-6">
|
||||
<%= render_slot(action, f) %>
|
||||
{render_slot(action, f)}
|
||||
</div>
|
||||
</.form>
|
||||
"""
|
||||
|
|
@ -297,11 +297,11 @@ defmodule PinchflatWeb.CoreComponents do
|
|||
class={["rounded focus:ring-0", @inputclass]}
|
||||
{@rest}
|
||||
/>
|
||||
<%= @label %>
|
||||
<span :if={@label_suffix} class="text-xs text-bodydark"><%= @label_suffix %></span>
|
||||
{@label}
|
||||
<span :if={@label_suffix} class="text-xs text-bodydark">{@label_suffix}</span>
|
||||
</label>
|
||||
<.help :if={@help}><%= if @html_help, do: Phoenix.HTML.raw(@help), else: @help %></.help>
|
||||
<.error :for={msg <- @errors}><%= msg %></.error>
|
||||
<.help :if={@help}>{if @html_help, do: Phoenix.HTML.raw(@help), else: @help}</.help>
|
||||
<.error :for={msg <- @errors}>{msg}</.error>
|
||||
</div>
|
||||
"""
|
||||
end
|
||||
|
|
@ -310,7 +310,7 @@ defmodule PinchflatWeb.CoreComponents do
|
|||
~H"""
|
||||
<div phx-feedback-for={@name}>
|
||||
<.label for={@id}>
|
||||
<%= @label %><span :if={@label_suffix} class="text-xs text-bodydark"><%= @label_suffix %></span>
|
||||
{@label}<span :if={@label_suffix} class="text-xs text-bodydark">{@label_suffix}</span>
|
||||
</.label>
|
||||
<section class="grid grid-cols-1 gap-2 md:grid-cols-2 max-w-prose mb-4 ml-1">
|
||||
<div :for={{option_name, option_value} <- @options} class="flex items-center">
|
||||
|
|
@ -323,12 +323,12 @@ defmodule PinchflatWeb.CoreComponents do
|
|||
class={["rounded focus:ring-offset-0 ring-offset-0 focus:ring-0 h-5 w-5 ", @inputclass]}
|
||||
/>
|
||||
<label for={"#{@id}-#{option_value}"} class="ml-2 cursor-pointer select-none">
|
||||
<%= option_name %>
|
||||
{option_name}
|
||||
</label>
|
||||
</div>
|
||||
</section>
|
||||
<.help :if={@help}><%= if @html_help, do: Phoenix.HTML.raw(@help), else: @help %></.help>
|
||||
<.error :for={msg <- @errors}><%= msg %></.error>
|
||||
<.help :if={@help}>{if @html_help, do: Phoenix.HTML.raw(@help), else: @help}</.help>
|
||||
<.error :for={msg <- @errors}>{msg}</.error>
|
||||
</div>
|
||||
"""
|
||||
end
|
||||
|
|
@ -342,8 +342,8 @@ defmodule PinchflatWeb.CoreComponents do
|
|||
~H"""
|
||||
<div x-data={"{ enabled: #{@checked} }"} class="" phx-update="ignore" id={"#{@id}-wrapper"}>
|
||||
<.label :if={@label} for={@id}>
|
||||
<%= @label %>
|
||||
<span :if={@label_suffix} class="text-xs text-bodydark"><%= @label_suffix %></span>
|
||||
{@label}
|
||||
<span :if={@label_suffix} class="text-xs text-bodydark">{@label_suffix}</span>
|
||||
</.label>
|
||||
<div class="relative flex flex-col">
|
||||
<input type="hidden" id={@id} name={@name} x-bind:value="enabled" {@rest} />
|
||||
|
|
@ -359,8 +359,8 @@ defmodule PinchflatWeb.CoreComponents do
|
|||
>
|
||||
</div>
|
||||
</div>
|
||||
<.help :if={@help}><%= if @html_help, do: Phoenix.HTML.raw(@help), else: @help %></.help>
|
||||
<.error :for={msg <- @errors}><%= msg %></.error>
|
||||
<.help :if={@help}>{if @html_help, do: Phoenix.HTML.raw(@help), else: @help}</.help>
|
||||
<.error :for={msg <- @errors}>{msg}</.error>
|
||||
</div>
|
||||
</div>
|
||||
"""
|
||||
|
|
@ -370,7 +370,7 @@ defmodule PinchflatWeb.CoreComponents do
|
|||
~H"""
|
||||
<div phx-feedback-for={@name}>
|
||||
<.label :if={@label} for={@id}>
|
||||
<%= @label %><span :if={@label_suffix} class="text-xs text-bodydark"><%= @label_suffix %></span>
|
||||
{@label}<span :if={@label_suffix} class="text-xs text-bodydark">{@label_suffix}</span>
|
||||
</.label>
|
||||
<div class="flex">
|
||||
<select
|
||||
|
|
@ -385,13 +385,13 @@ defmodule PinchflatWeb.CoreComponents do
|
|||
multiple={@multiple}
|
||||
{@rest}
|
||||
>
|
||||
<option :if={@prompt} value=""><%= @prompt %></option>
|
||||
<%= Phoenix.HTML.Form.options_for_select(@options, @value) %>
|
||||
<option :if={@prompt} value="">{@prompt}</option>
|
||||
{Phoenix.HTML.Form.options_for_select(@options, @value)}
|
||||
</select>
|
||||
<%= render_slot(@inner_block) %>
|
||||
{render_slot(@inner_block)}
|
||||
</div>
|
||||
<.help :if={@help}><%= if @html_help, do: Phoenix.HTML.raw(@help), else: @help %></.help>
|
||||
<.error :for={msg <- @errors}><%= msg %></.error>
|
||||
<.help :if={@help}>{if @html_help, do: Phoenix.HTML.raw(@help), else: @help}</.help>
|
||||
<.error :for={msg <- @errors}>{msg}</.error>
|
||||
</div>
|
||||
"""
|
||||
end
|
||||
|
|
@ -400,7 +400,7 @@ defmodule PinchflatWeb.CoreComponents do
|
|||
~H"""
|
||||
<div phx-feedback-for={@name}>
|
||||
<.label for={@id}>
|
||||
<%= @label %><span :if={@label_suffix} class="text-xs text-bodydark"><%= @label_suffix %></span>
|
||||
{@label}<span :if={@label_suffix} class="text-xs text-bodydark">{@label_suffix}</span>
|
||||
</.label>
|
||||
<textarea
|
||||
id={@id}
|
||||
|
|
@ -414,8 +414,8 @@ defmodule PinchflatWeb.CoreComponents do
|
|||
]}
|
||||
{@rest}
|
||||
><%= Phoenix.HTML.Form.normalize_value("textarea", @value) %></textarea>
|
||||
<.help :if={@help}><%= if @html_help, do: Phoenix.HTML.raw(@help), else: @help %></.help>
|
||||
<.error :for={msg <- @errors}><%= msg %></.error>
|
||||
<.help :if={@help}>{if @html_help, do: Phoenix.HTML.raw(@help), else: @help}</.help>
|
||||
<.error :for={msg <- @errors}>{msg}</.error>
|
||||
</div>
|
||||
"""
|
||||
end
|
||||
|
|
@ -425,7 +425,7 @@ defmodule PinchflatWeb.CoreComponents do
|
|||
~H"""
|
||||
<div phx-feedback-for={@name}>
|
||||
<.label for={@id}>
|
||||
<%= @label %><span :if={@label_suffix} class="text-xs text-bodydark"><%= @label_suffix %></span>
|
||||
{@label}<span :if={@label_suffix} class="text-xs text-bodydark">{@label_suffix}</span>
|
||||
</.label>
|
||||
<div class="flex items-center">
|
||||
<input
|
||||
|
|
@ -442,10 +442,10 @@ defmodule PinchflatWeb.CoreComponents do
|
|||
]}
|
||||
{@rest}
|
||||
/>
|
||||
<%= render_slot(@input_append) %>
|
||||
{render_slot(@input_append)}
|
||||
</div>
|
||||
<.help :if={@help}><%= if @html_help, do: Phoenix.HTML.raw(@help), else: @help %></.help>
|
||||
<.error :for={msg <- @errors}><%= msg %></.error>
|
||||
<.help :if={@help}>{if @html_help, do: Phoenix.HTML.raw(@help), else: @help}</.help>
|
||||
<.error :for={msg <- @errors}>{msg}</.error>
|
||||
</div>
|
||||
"""
|
||||
end
|
||||
|
|
@ -458,7 +458,7 @@ defmodule PinchflatWeb.CoreComponents do
|
|||
def help(assigns) do
|
||||
~H"""
|
||||
<p class="mt-1 text-sm leading-5">
|
||||
<%= render_slot(@inner_block) %>
|
||||
{render_slot(@inner_block)}
|
||||
</p>
|
||||
"""
|
||||
end
|
||||
|
|
@ -472,7 +472,7 @@ defmodule PinchflatWeb.CoreComponents do
|
|||
def label(assigns) do
|
||||
~H"""
|
||||
<label for={@for} class="mt-5 mb-2 inline-block text-md font-medium text-black dark:text-white">
|
||||
<%= render_slot(@inner_block) %>
|
||||
{render_slot(@inner_block)}
|
||||
</label>
|
||||
"""
|
||||
end
|
||||
|
|
@ -486,7 +486,7 @@ defmodule PinchflatWeb.CoreComponents do
|
|||
~H"""
|
||||
<p class="mt-1 mb-5 flex gap-3 text-md leading-6 text-rose-600 phx-no-feedback:hidden">
|
||||
<.icon name="hero-exclamation-circle-mini" class="mt-0.5 h-5 w-5 flex-none" />
|
||||
<%= render_slot(@inner_block) %>
|
||||
{render_slot(@inner_block)}
|
||||
</p>
|
||||
"""
|
||||
end
|
||||
|
|
@ -505,13 +505,13 @@ defmodule PinchflatWeb.CoreComponents do
|
|||
<header class={[@actions != [] && "flex items-center justify-between gap-6", @class]}>
|
||||
<div>
|
||||
<h1 class="text-lg font-semibold leading-8 text-zinc-800">
|
||||
<%= render_slot(@inner_block) %>
|
||||
{render_slot(@inner_block)}
|
||||
</h1>
|
||||
<p :if={@subtitle != []} class="mt-2 text-sm leading-6 text-zinc-600">
|
||||
<%= render_slot(@subtitle) %>
|
||||
{render_slot(@subtitle)}
|
||||
</p>
|
||||
</div>
|
||||
<div class="flex-none"><%= render_slot(@actions) %></div>
|
||||
<div class="flex-none">{render_slot(@actions)}</div>
|
||||
</header>
|
||||
"""
|
||||
end
|
||||
|
|
@ -551,9 +551,9 @@ defmodule PinchflatWeb.CoreComponents do
|
|||
<table class="w-[40rem] mt-11 sm:w-full">
|
||||
<thead class="text-sm text-left leading-6 text-zinc-500">
|
||||
<tr>
|
||||
<th :for={col <- @col} class="p-0 pb-4 pr-6 font-normal"><%= col[:label] %></th>
|
||||
<th :for={col <- @col} class="p-0 pb-4 pr-6 font-normal">{col[:label]}</th>
|
||||
<th :if={@action != []} class="relative p-0 pb-4">
|
||||
<span class="sr-only"><%= gettext("Actions") %></span>
|
||||
<span class="sr-only">{gettext("Actions")}</span>
|
||||
</th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
|
@ -571,7 +571,7 @@ defmodule PinchflatWeb.CoreComponents do
|
|||
<div class="block py-4 pr-6">
|
||||
<span class="absolute -inset-y-px right-0 -left-4 group-hover:bg-zinc-50 sm:rounded-l-xl" />
|
||||
<span class={["relative", i == 0 && "font-semibold text-zinc-900"]}>
|
||||
<%= render_slot(col, @row_item.(row)) %>
|
||||
{render_slot(col, @row_item.(row))}
|
||||
</span>
|
||||
</div>
|
||||
</td>
|
||||
|
|
@ -579,7 +579,7 @@ defmodule PinchflatWeb.CoreComponents do
|
|||
<div class="relative whitespace-nowrap py-4 text-right text-sm font-medium">
|
||||
<span class="absolute -inset-y-px -right-4 left-0 group-hover:bg-zinc-50 sm:rounded-r-xl" />
|
||||
<span :for={action <- @action} class="relative ml-4 font-semibold leading-6 text-zinc-900 hover:text-zinc-700">
|
||||
<%= render_slot(action, @row_item.(row)) %>
|
||||
{render_slot(action, @row_item.(row))}
|
||||
</span>
|
||||
</div>
|
||||
</td>
|
||||
|
|
@ -608,8 +608,8 @@ defmodule PinchflatWeb.CoreComponents do
|
|||
<div class="mt-2 mb-14">
|
||||
<dl class="-my-4 divide-y dark:divide-strokedark">
|
||||
<div :for={item <- @item} class="flex gap-4 py-4 text-sm leading-6 sm:gap-8">
|
||||
<dt class="w-1/4 flex-none dark:text-white"><%= item.title %></dt>
|
||||
<dd class="dark:text-white"><%= render_slot(item) %></dd>
|
||||
<dt class="w-1/4 flex-none dark:text-white">{item.title}</dt>
|
||||
<dd class="dark:text-white">{render_slot(item)}</dd>
|
||||
</div>
|
||||
</dl>
|
||||
</div>
|
||||
|
|
@ -644,12 +644,12 @@ defmodule PinchflatWeb.CoreComponents do
|
|||
~H"""
|
||||
<ul>
|
||||
<li :for={{k, v} <- @iterable_attributes} class="mb-2 w-2/3">
|
||||
<strong><%= k %>:</strong>
|
||||
<strong>{k}:</strong>
|
||||
<code class="inline-block text-sm font-mono text-gray p-0.5 mx-0.5">
|
||||
<%= if is_binary(v) && URI.parse(v).scheme && URI.parse(v).scheme =~ "http" do %>
|
||||
<TextComponents.inline_link href={v}><%= v %></TextComponents.inline_link>
|
||||
<TextComponents.inline_link href={v}>{v}</TextComponents.inline_link>
|
||||
<% else %>
|
||||
<%= v %>
|
||||
{v}
|
||||
<% end %>
|
||||
</code>
|
||||
</li>
|
||||
|
|
@ -672,7 +672,7 @@ defmodule PinchflatWeb.CoreComponents do
|
|||
<div class="mt-16">
|
||||
<.link href={@href} class="text-sm font-semibold leading-6 text-zinc-900 hover:text-zinc-700">
|
||||
<.icon name="hero-arrow-left-solid" class="h-3 w-3" />
|
||||
<%= render_slot(@inner_block) %>
|
||||
{render_slot(@inner_block)}
|
||||
</.link>
|
||||
</div>
|
||||
"""
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@ defmodule PinchflatWeb.CustomComponents.ButtonComponents do
|
|||
disabled={@disabled}
|
||||
{@rest}
|
||||
>
|
||||
<%= render_slot(@inner_block) %>
|
||||
{render_slot(@inner_block)}
|
||||
</button>
|
||||
"""
|
||||
end
|
||||
|
|
@ -66,7 +66,7 @@ defmodule PinchflatWeb.CustomComponents.ButtonComponents do
|
|||
"font-medium text-white hover:bg-opacity-95"
|
||||
]}
|
||||
>
|
||||
<%= @text %>
|
||||
{@text}
|
||||
<CoreComponents.icon
|
||||
name="hero-chevron-down"
|
||||
class="fill-current duration-200 ease-linear mt-1"
|
||||
|
|
@ -81,7 +81,7 @@ defmodule PinchflatWeb.CustomComponents.ButtonComponents do
|
|||
<ul class="flex flex-col">
|
||||
<li :for={option <- @option}>
|
||||
<span class="flex px-5 py-2 font-medium text-bodydark2 hover:text-white cursor-pointer">
|
||||
<%= render_slot(option) %>
|
||||
{render_slot(option)}
|
||||
</span>
|
||||
</li>
|
||||
</ul>
|
||||
|
|
@ -126,7 +126,7 @@ defmodule PinchflatWeb.CustomComponents.ButtonComponents do
|
|||
>
|
||||
<span class="border-light absolute -top-1 left-1/2 -z-10 h-2 w-2 -translate-x-1/2 rotate-45 rounded-sm bg-meta-4">
|
||||
</span>
|
||||
<span><%= @tooltip %></span>
|
||||
<span>{@tooltip}</span>
|
||||
</div>
|
||||
</div>
|
||||
"""
|
||||
|
|
|
|||
|
|
@ -34,16 +34,16 @@ defmodule PinchflatWeb.CustomComponents.TabComponents do
|
|||
x-bind:class={"openTab === '#{tab.id}' ? activeClasses : inactiveClasses"}
|
||||
class="border-b-2 py-4 w-full sm:w-fit text-sm font-medium hover:text-meta-5 md:text-base"
|
||||
>
|
||||
<span class="text-xl"><%= tab.title %></span>
|
||||
<span class="text-xl">{tab.title}</span>
|
||||
</a>
|
||||
</div>
|
||||
<div class="mx-4 my-4 lg:my-0 flex gap-5 sm:gap-10 items-center">
|
||||
<%= render_slot(@tab_append) %>
|
||||
{render_slot(@tab_append)}
|
||||
</div>
|
||||
</header>
|
||||
<div class="mt-4 min-h-60">
|
||||
<div :for={tab <- @tab} x-show={"openTab === '#{tab.id}'"} class="font-medium leading-relaxed">
|
||||
<%= render_slot(tab) %>
|
||||
{render_slot(tab)}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -32,7 +32,7 @@ defmodule PinchflatWeb.CustomComponents.TableComponents do
|
|||
<thead>
|
||||
<tr class="text-left bg-meta-4">
|
||||
<th :for={col <- @col} class="px-4 py-4 font-medium text-white xl:pl-11">
|
||||
<%= col[:label] %>
|
||||
{col[:label]}
|
||||
</th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
|
@ -45,7 +45,7 @@ defmodule PinchflatWeb.CustomComponents.TableComponents do
|
|||
col[:class]
|
||||
]}
|
||||
>
|
||||
<%= render_slot(col, @row_item.(row)) %>
|
||||
{render_slot(col, @row_item.(row))}
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ defmodule PinchflatWeb.CustomComponents.TextComponents do
|
|||
def inline_code(assigns) do
|
||||
~H"""
|
||||
<code class="inline-block text-sm font-mono text-gray bg-boxdark rounded-md p-0.5 mx-0.5 text-nowrap">
|
||||
<%= render_slot(@inner_block) %>
|
||||
{render_slot(@inner_block)}
|
||||
</code>
|
||||
"""
|
||||
end
|
||||
|
|
@ -26,7 +26,7 @@ defmodule PinchflatWeb.CustomComponents.TextComponents do
|
|||
def inline_link(assigns) do
|
||||
~H"""
|
||||
<.link href={@href} target="_blank" class="text-blue-500 hover:text-blue-300">
|
||||
<%= render_slot(@inner_block) %>
|
||||
{render_slot(@inner_block)}
|
||||
</.link>
|
||||
"""
|
||||
end
|
||||
|
|
@ -41,7 +41,7 @@ defmodule PinchflatWeb.CustomComponents.TextComponents do
|
|||
def subtle_link(assigns) do
|
||||
~H"""
|
||||
<.link href={@href} target={@target} class="underline decoration-bodydark decoration-1 hover:decoration-white">
|
||||
<%= render_slot(@inner_block) %>
|
||||
{render_slot(@inner_block)}
|
||||
</.link>
|
||||
"""
|
||||
end
|
||||
|
|
@ -82,7 +82,7 @@ defmodule PinchflatWeb.CustomComponents.TextComponents do
|
|||
assigns = Map.put(assigns, :text, formatted_text)
|
||||
|
||||
~H"""
|
||||
<span><%= @text %></span>
|
||||
<span>{@text}</span>
|
||||
"""
|
||||
end
|
||||
|
||||
|
|
@ -98,7 +98,7 @@ defmodule PinchflatWeb.CustomComponents.TextComponents do
|
|||
assigns = Map.put(assigns, :timezone, timezone)
|
||||
|
||||
~H"""
|
||||
<time><%= Calendar.strftime(Timex.Timezone.convert(@datetime, @timezone), @format) %></time>
|
||||
<time>{Calendar.strftime(Timex.Timezone.convert(@datetime, @timezone), @format)}</time>
|
||||
"""
|
||||
end
|
||||
|
||||
|
|
@ -109,7 +109,7 @@ defmodule PinchflatWeb.CustomComponents.TextComponents do
|
|||
|
||||
def localized_number(assigns) do
|
||||
~H"""
|
||||
<span x-data x-text={"Intl.NumberFormat().format(#{@number})"}><%= @number %></span>
|
||||
<span x-data x-text={"Intl.NumberFormat().format(#{@number})"}>{@number}</span>
|
||||
"""
|
||||
end
|
||||
|
||||
|
|
@ -122,7 +122,7 @@ defmodule PinchflatWeb.CustomComponents.TextComponents do
|
|||
|
||||
def pluralize(assigns) do
|
||||
~H"""
|
||||
<%= @word %><%= if @count == 1, do: "", else: @suffix %>
|
||||
{@word}{if @count == 1, do: "", else: @suffix}
|
||||
"""
|
||||
end
|
||||
end
|
||||
|
|
|
|||
|
|
@ -61,7 +61,7 @@ defmodule PinchflatWeb.Layouts do
|
|||
x-on:click="selected = !selected"
|
||||
>
|
||||
<span class="flex items-center gap-2.5">
|
||||
<.icon name={@icon} /> <%= @text %>
|
||||
<.icon name={@icon} /> {@text}
|
||||
</span>
|
||||
<span class="text-bodydark2">
|
||||
<.icon name="hero-chevron-down" x-bind:class="{ 'rotate-180': selected }" />
|
||||
|
|
@ -103,7 +103,7 @@ defmodule PinchflatWeb.Layouts do
|
|||
@class
|
||||
]}
|
||||
>
|
||||
<.icon :if={@icon} name={@icon} /> <%= @text %>
|
||||
<.icon :if={@icon} name={@icon} /> {@text}
|
||||
</.link>
|
||||
"""
|
||||
end
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@
|
|||
<main>
|
||||
<div class="mx-auto max-w-screen-2xl p-4 md:p-6 2xl:p-10">
|
||||
<.flash_group flash={@flash} />
|
||||
<%= @inner_content %>
|
||||
{@inner_content}
|
||||
</div>
|
||||
</main>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@
|
|||
<main>
|
||||
<div class="mx-auto max-w-screen-2xl p-4 md:p-6 2xl:p-10">
|
||||
<.flash_group flash={@flash} />
|
||||
<%= @inner_content %>
|
||||
{@inner_content}
|
||||
</div>
|
||||
</main>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -67,7 +67,7 @@
|
|||
class="group relative flex items-center gap-2.5 px-4 pt-2 text-sm"
|
||||
x-on:click={"markVersionAsSeen('#{Application.spec(:pinchflat)[:vsn]}')"}
|
||||
>
|
||||
<span>Pinchflat <%= Application.spec(:pinchflat)[:vsn] %></span>
|
||||
<span>Pinchflat {Application.spec(:pinchflat)[:vsn]}</span>
|
||||
<a
|
||||
href="https://github.com/kieraneglin/pinchflat/releases"
|
||||
target="_blank"
|
||||
|
|
@ -79,7 +79,7 @@
|
|||
</a>
|
||||
</span>
|
||||
<span class="group relative flex items-center gap-2.5 px-4 pt-2 text-sm">
|
||||
yt-dlp <%= Settings.get!(:yt_dlp_version) %>
|
||||
yt-dlp {Settings.get!(:yt_dlp_version)}
|
||||
</span>
|
||||
</li>
|
||||
</ul>
|
||||
|
|
|
|||
|
|
@ -25,6 +25,6 @@
|
|||
into the text box and press the button.
|
||||
</p>
|
||||
|
||||
<%= live_render(@conn, Pinchflat.UpgradeButtonLive) %>
|
||||
{live_render(@conn, Pinchflat.UpgradeButtonLive)}
|
||||
</section>
|
||||
</.modal>
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@
|
|||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||
<meta name="csrf-token" content={get_csrf_token()} />
|
||||
<.live_title>
|
||||
<%= assigns[:page_title] || "Pinchflat" %>
|
||||
{assigns[:page_title] || "Pinchflat"}
|
||||
</.live_title>
|
||||
<link phx-track-static rel="stylesheet" href={~p"/assets/app.css"} />
|
||||
<link rel="icon" type="image/x-icon" href={~p"/favicon.ico?cachebust=2024-03-20"} />
|
||||
|
|
@ -21,7 +21,7 @@
|
|||
class="dark text-bodydark bg-boxdark-2"
|
||||
data-socket-path={Path.join(Application.get_env(:pinchflat, :base_route_path), "/live")}
|
||||
>
|
||||
<%= @inner_content %>
|
||||
{@inner_content}
|
||||
|
||||
<.donate_modal conn={@conn} />
|
||||
<template x-if="!proEnabled && !onboarding">
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
<div class="mb-6 flex gap-3 flex-row items-center">
|
||||
<h2 class="text-title-md2 font-bold text-black dark:text-white ml-4">
|
||||
Editing "<%= StringUtils.truncate(@media_item.title, 35) %>"
|
||||
Editing "{StringUtils.truncate(@media_item.title, 35)}"
|
||||
</h2>
|
||||
</div>
|
||||
|
||||
|
|
|
|||
|
|
@ -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-4">
|
||||
<%= StringUtils.truncate(@media_item.title, 35) %>
|
||||
{StringUtils.truncate(@media_item.title, 35)}
|
||||
</h2>
|
||||
</div>
|
||||
|
||||
|
|
@ -31,8 +31,8 @@
|
|||
<.media_preview media_item={@media_item} />
|
||||
</div>
|
||||
<aside class="mt-4">
|
||||
<h2 class="text-xl mb-2"><%= @media_item.title %></h2>
|
||||
<div>Uploaded: <%= DateTime.to_date(@media_item.uploaded_at) %></div>
|
||||
<h2 class="text-xl mb-2">{@media_item.title}</h2>
|
||||
<div>Uploaded: {DateTime.to_date(@media_item.uploaded_at)}</div>
|
||||
<div>
|
||||
<span :if={URI.parse(@media_item.original_url).scheme =~ "http"}>
|
||||
<.subtle_link href={@media_item.original_url} target="_blank">Open Original</.subtle_link>
|
||||
|
|
@ -58,7 +58,7 @@
|
|||
<section>
|
||||
<strong>Source:</strong>
|
||||
<.subtle_link href={~p"/sources/#{@media_item.source_id}"}>
|
||||
<%= @media_item.source.custom_name %>
|
||||
{@media_item.source.custom_name}
|
||||
</.subtle_link>
|
||||
<.list_items_from_map map={Map.from_struct(@media_item)} />
|
||||
</section>
|
||||
|
|
@ -68,10 +68,10 @@
|
|||
<%= if match?([_|_], @media_item.tasks) do %>
|
||||
<.table rows={@media_item.tasks} table_class="text-black dark:text-white">
|
||||
<:col :let={task} label="Worker">
|
||||
<%= task.job.worker %>
|
||||
{task.job.worker}
|
||||
</:col>
|
||||
<:col :let={task} label="State">
|
||||
<%= task.job.state %>
|
||||
{task.job.state}
|
||||
</:col>
|
||||
<:col :let={task} label="Scheduled At">
|
||||
<.datetime_in_zone datetime={task.job.scheduled_at} />
|
||||
|
|
|
|||
|
|
@ -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>
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@ defmodule PinchflatWeb.Pages.PageHTML do
|
|||
})
|
||||
|
||||
~H"""
|
||||
<.localized_number number={@num} /> <%= @suffix %>
|
||||
<.localized_number number={@num} /> {@suffix}
|
||||
"""
|
||||
end
|
||||
end
|
||||
|
|
|
|||
|
|
@ -30,21 +30,21 @@ defmodule Pinchflat.Pages.HistoryTableLive do
|
|||
<.table rows={@records} table_class="text-white">
|
||||
<:col :let={media_item} label="Title">
|
||||
<.subtle_link href={~p"/sources/#{media_item.source_id}/media/#{media_item}"}>
|
||||
<%= StringUtils.truncate(media_item.title, 35) %>
|
||||
{StringUtils.truncate(media_item.title, 35)}
|
||||
</.subtle_link>
|
||||
</:col>
|
||||
<:col :let={media_item} label="Upload Date">
|
||||
<%= DateTime.to_date(media_item.uploaded_at) %>
|
||||
{DateTime.to_date(media_item.uploaded_at)}
|
||||
</:col>
|
||||
<:col :let={media_item} label="Indexed At">
|
||||
<%= format_datetime(media_item.inserted_at) %>
|
||||
{format_datetime(media_item.inserted_at)}
|
||||
</:col>
|
||||
<:col :let={media_item} label="Downloaded At">
|
||||
<%= format_datetime(media_item.media_downloaded_at) %>
|
||||
{format_datetime(media_item.media_downloaded_at)}
|
||||
</:col>
|
||||
<:col :let={media_item} label="Source">
|
||||
<.subtle_link href={~p"/sources/#{media_item.source_id}"}>
|
||||
<%= StringUtils.truncate(media_item.source.custom_name, 35) %>
|
||||
{StringUtils.truncate(media_item.source.custom_name, 35)}
|
||||
</.subtle_link>
|
||||
</:col>
|
||||
</.table>
|
||||
|
|
|
|||
|
|
@ -42,13 +42,13 @@
|
|||
<div class="rounded-sm border shadow-default border-strokedark bg-boxdark mt-4 p-5">
|
||||
<span class="text-2xl font-medium mb-4">Media History</span>
|
||||
<section class="mt-6">
|
||||
<%= live_render(@conn, Pinchflat.Pages.HistoryTableLive) %>
|
||||
{live_render(@conn, Pinchflat.Pages.HistoryTableLive)}
|
||||
</section>
|
||||
</div>
|
||||
|
||||
<div class="rounded-sm border shadow-default border-strokedark bg-boxdark mt-4 p-5">
|
||||
<span class="text-2xl font-medium mb-4">Active Tasks</span>
|
||||
<section class="mt-6 min-h-80">
|
||||
<%= live_render(@conn, Pinchflat.Pages.JobTableLive) %>
|
||||
{live_render(@conn, Pinchflat.Pages.JobTableLive)}
|
||||
</section>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -19,18 +19,18 @@ defmodule Pinchflat.Pages.JobTableLive do
|
|||
<div class="max-w-full overflow-x-auto">
|
||||
<.table rows={@tasks} table_class="text-white">
|
||||
<:col :let={task} label="Task">
|
||||
<%= worker_to_task_name(task.job.worker) %>
|
||||
{worker_to_task_name(task.job.worker)}
|
||||
</:col>
|
||||
<:col :let={task} label="Subject">
|
||||
<.subtle_link href={task_to_link(task)}>
|
||||
<%= StringUtils.truncate(task_to_record_name(task), 35) %>
|
||||
{StringUtils.truncate(task_to_record_name(task), 35)}
|
||||
</.subtle_link>
|
||||
</:col>
|
||||
<:col :let={task} label="Attempt No.">
|
||||
<%= task.job.attempt %>
|
||||
{task.job.attempt}
|
||||
</:col>
|
||||
<:col :let={task} label="Started At">
|
||||
<%= format_datetime(task.job.attempted_at) %>
|
||||
{format_datetime(task.job.attempted_at)}
|
||||
</:col>
|
||||
</.table>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@ defmodule PinchflatWeb.Searches.SearchHTML do
|
|||
|
||||
~H"""
|
||||
<%= for fragment <- @split_string do %>
|
||||
<%= render_fragment(fragment) %>
|
||||
{render_fragment(fragment)}
|
||||
<% end %>
|
||||
"""
|
||||
end
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
<div class="mb-6 flex gap-3 flex-row items-center justify-between">
|
||||
<h2 class="text-title-md2 font-bold text-black dark:text-white">
|
||||
Results for "<%= StringUtils.truncate(@search_term, 50) %>"
|
||||
Results for "{StringUtils.truncate(@search_term, 50)}"
|
||||
</h2>
|
||||
</div>
|
||||
|
||||
|
|
@ -11,7 +11,7 @@
|
|||
<.table rows={@search_results} table_class="text-black dark:text-white">
|
||||
<:col :let={result} label="Title">
|
||||
<.subtle_link href={~p"/sources/#{result.source_id}/media/#{result.id}"}>
|
||||
<%= StringUtils.truncate(result.title, 35) %>
|
||||
{StringUtils.truncate(result.title, 35)}
|
||||
</.subtle_link>
|
||||
</:col>
|
||||
<:col :let={result} label="Excerpt">
|
||||
|
|
|
|||
|
|
@ -19,11 +19,11 @@
|
|||
</span>
|
||||
</section>
|
||||
|
||||
<%= live_render(
|
||||
{live_render(
|
||||
@conn,
|
||||
Pinchflat.Settings.AppriseServerLive,
|
||||
session: %{"value" => f[:apprise_server].value}
|
||||
) %>
|
||||
)}
|
||||
</section>
|
||||
|
||||
<section class="mt-8">
|
||||
|
|
|
|||
|
|
@ -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 "<%= @source.custom_name %>"
|
||||
Editing "{@source.custom_name}"
|
||||
</h2>
|
||||
</div>
|
||||
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@
|
|||
<div class="rounded-sm border border-stroke bg-white shadow-default dark:border-strokedark dark:bg-boxdark">
|
||||
<div class="max-w-full overflow-x-auto">
|
||||
<div class="flex flex-col gap-10 min-w-max">
|
||||
<%= live_render(@conn, PinchflatWeb.Sources.IndexTableLive) %>
|
||||
{live_render(@conn, PinchflatWeb.Sources.IndexTableLive)}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@ defmodule PinchflatWeb.Sources.IndexTableLive do
|
|||
<.table rows={@sources} table_class="text-white">
|
||||
<:col :let={source} label="Name">
|
||||
<.subtle_link href={~p"/sources/#{source.id}"}>
|
||||
<%= StringUtils.truncate(source.custom_name || source.collection_name, 35) %>
|
||||
{StringUtils.truncate(source.custom_name || source.collection_name, 35)}
|
||||
</.subtle_link>
|
||||
</:col>
|
||||
<:col :let={source} label="Pending">
|
||||
|
|
@ -36,7 +36,7 @@ defmodule PinchflatWeb.Sources.IndexTableLive do
|
|||
</:col>
|
||||
<:col :let={source} label="Media Profile">
|
||||
<.subtle_link href={~p"/media_profiles/#{source.media_profile_id}"}>
|
||||
<%= source.media_profile.name %>
|
||||
{source.media_profile.name}
|
||||
</.subtle_link>
|
||||
</:col>
|
||||
<:col :let={source} label="Enabled?">
|
||||
|
|
|
|||
|
|
@ -48,14 +48,14 @@ defmodule PinchflatWeb.Sources.MediaItemTableLive do
|
|||
<.table rows={@records} table_class="text-white">
|
||||
<:col :let={media_item} label="Title">
|
||||
<.subtle_link href={~p"/sources/#{@source.id}/media/#{media_item.id}"}>
|
||||
<%= StringUtils.truncate(media_item.title, 50) %>
|
||||
{StringUtils.truncate(media_item.title, 50)}
|
||||
</.subtle_link>
|
||||
</:col>
|
||||
<:col :let={media_item} :if={@media_state == "other"} label="Manually Ignored?">
|
||||
<.icon name={if media_item.prevent_download, do: "hero-check", else: "hero-x-mark"} />
|
||||
</:col>
|
||||
<:col :let={media_item} label="Upload Date">
|
||||
<%= DateTime.to_date(media_item.uploaded_at) %>
|
||||
{DateTime.to_date(media_item.uploaded_at)}
|
||||
</:col>
|
||||
<:col :let={media_item} label="" class="flex justify-end">
|
||||
<.icon_link href={~p"/sources/#{@source.id}/media/#{media_item.id}/edit"} icon="hero-pencil-square" class="mr-4" />
|
||||
|
|
|
|||
|
|
@ -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-4">
|
||||
<%= @source.custom_name %>
|
||||
{@source.custom_name}
|
||||
</h2>
|
||||
</div>
|
||||
|
||||
|
|
@ -29,7 +29,7 @@
|
|||
<section>
|
||||
<strong>Media Profile:</strong>
|
||||
<.subtle_link href={~p"/media_profiles/#{@source.media_profile_id}"}>
|
||||
<%= @source.media_profile.name %>
|
||||
{@source.media_profile.name}
|
||||
</.subtle_link>
|
||||
</section>
|
||||
|
||||
|
|
@ -37,34 +37,34 @@
|
|||
</div>
|
||||
</:tab>
|
||||
<:tab title="Pending" id="pending">
|
||||
<%= live_render(
|
||||
{live_render(
|
||||
@conn,
|
||||
PinchflatWeb.Sources.MediaItemTableLive,
|
||||
session: %{"source_id" => @source.id, "media_state" => "pending"}
|
||||
) %>
|
||||
)}
|
||||
</:tab>
|
||||
<:tab title="Downloaded" id="downloaded">
|
||||
<%= live_render(
|
||||
{live_render(
|
||||
@conn,
|
||||
PinchflatWeb.Sources.MediaItemTableLive,
|
||||
session: %{"source_id" => @source.id, "media_state" => "downloaded"}
|
||||
) %>
|
||||
)}
|
||||
</:tab>
|
||||
<:tab title="Other" id="other">
|
||||
<%= live_render(
|
||||
{live_render(
|
||||
@conn,
|
||||
PinchflatWeb.Sources.MediaItemTableLive,
|
||||
session: %{"source_id" => @source.id, "media_state" => "other"}
|
||||
) %>
|
||||
)}
|
||||
</:tab>
|
||||
<:tab title="Tasks" id="tasks">
|
||||
<%= if match?([_|_], @pending_tasks) do %>
|
||||
<.table rows={@pending_tasks} table_class="text-black dark:text-white">
|
||||
<:col :let={task} label="Worker">
|
||||
<%= task.job.worker %>
|
||||
{task.job.worker}
|
||||
</:col>
|
||||
<:col :let={task} label="State">
|
||||
<%= task.job.state %>
|
||||
{task.job.state}
|
||||
</:col>
|
||||
<:col :let={task} label="Scheduled At">
|
||||
<.datetime_in_zone datetime={task.job.scheduled_at} />
|
||||
|
|
|
|||
4
mix.exs
4
mix.exs
|
|
@ -54,8 +54,8 @@ defmodule Pinchflat.MixProject do
|
|||
{:ecto_sqlite3_extras, "~> 1.2.0"},
|
||||
{:phoenix_html, "~> 3.3"},
|
||||
{:phoenix_live_reload, "~> 1.2", only: :dev},
|
||||
{:phoenix_live_view, "~> 0.20.1"},
|
||||
{:floki, ">= 0.30.0", only: :test},
|
||||
{:phoenix_live_view, "~> 1.0.0"},
|
||||
{:floki, ">= 0.36.0", only: :test},
|
||||
{:phoenix_live_dashboard, "~> 0.8.2"},
|
||||
{:esbuild, "~> 0.8", runtime: Mix.env() == :dev},
|
||||
{:tailwind, "~> 0.2.0", runtime: Mix.env() == :dev},
|
||||
|
|
|
|||
12
mix.lock
12
mix.lock
|
|
@ -1,6 +1,6 @@
|
|||
%{
|
||||
"bunt": {:hex, :bunt, "1.0.0", "081c2c665f086849e6d57900292b3a161727ab40431219529f13c4ddcf3e7a44", [:mix], [], "hexpm", "dc5f86aa08a5f6fa6b8096f0735c4e76d54ae5c9fa2c143e5a1fc7c1cd9bb6b5"},
|
||||
"castore": {:hex, :castore, "1.0.8", "dedcf20ea746694647f883590b82d9e96014057aff1d44d03ec90f36a5c0dc6e", [:mix], [], "hexpm", "0b2b66d2ee742cb1d9cb8c8be3b43c3a70ee8651f37b75a8b982e036752983f1"},
|
||||
"castore": {:hex, :castore, "1.0.10", "43bbeeac820f16c89f79721af1b3e092399b3a1ecc8df1a472738fd853574911", [:mix], [], "hexpm", "1b0b7ea14d889d9ea21202c43a4fa015eb913021cb535e8ed91946f4b77a8848"},
|
||||
"cc_precompiler": {:hex, :cc_precompiler, "0.1.10", "47c9c08d8869cf09b41da36538f62bc1abd3e19e41701c2cea2675b53c704258", [:mix], [{:elixir_make, "~> 0.7", [hex: :elixir_make, repo: "hexpm", optional: false]}], "hexpm", "f6e046254e53cd6b41c6bacd70ae728011aa82b2742a80d6e2214855c6e06b22"},
|
||||
"certifi": {:hex, :certifi, "2.12.0", "2d1cca2ec95f59643862af91f001478c9863c2ac9cb6e2f89780bfd8de987329", [:rebar3], [], "hexpm", "ee68d85df22e554040cdb4be100f33873ac6051387baf6a8f6ce82272340ff1c"},
|
||||
"combine": {:hex, :combine, "0.10.0", "eff8224eeb56498a2af13011d142c5e7997a80c8f5b97c499f84c841032e429f", [:mix], [], "hexpm", "1b1dbc1790073076580d0d1d64e42eae2366583e7aecd455d1215b0d16f2451b"},
|
||||
|
|
@ -10,7 +10,7 @@
|
|||
"credo": {:hex, :credo, "1.7.7", "771445037228f763f9b2afd612b6aa2fd8e28432a95dbbc60d8e03ce71ba4446", [:mix], [{:bunt, "~> 0.2.1 or ~> 1.0", [hex: :bunt, repo: "hexpm", optional: false]}, {:file_system, "~> 0.2 or ~> 1.0", [hex: :file_system, repo: "hexpm", optional: false]}, {:jason, "~> 1.0", [hex: :jason, repo: "hexpm", optional: false]}], "hexpm", "8bc87496c9aaacdc3f90f01b7b0582467b69b4bd2441fe8aae3109d843cc2f2e"},
|
||||
"credo_naming": {:hex, :credo_naming, "2.1.0", "d44ad58890d4db552e141ce64756a74ac1573665af766d1ac64931aa90d47744", [:make, :mix], [{:credo, "~> 1.6", [hex: :credo, repo: "hexpm", optional: false]}], "hexpm", "830e23b3fba972e2fccec49c0c089fe78c1e64bc16782a2682d78082351a2909"},
|
||||
"db_connection": {:hex, :db_connection, "2.7.0", "b99faa9291bb09892c7da373bb82cba59aefa9b36300f6145c5f201c7adf48ec", [:mix], [{:telemetry, "~> 0.4 or ~> 1.0", [hex: :telemetry, repo: "hexpm", optional: false]}], "hexpm", "dcf08f31b2701f857dfc787fbad78223d61a32204f217f15e881dd93e4bdd3ff"},
|
||||
"decimal": {:hex, :decimal, "2.1.1", "5611dca5d4b2c3dd497dec8f68751f1f1a54755e8ed2a966c2633cf885973ad6", [:mix], [], "hexpm", "53cfe5f497ed0e7771ae1a475575603d77425099ba5faef9394932b35020ffcc"},
|
||||
"decimal": {:hex, :decimal, "2.2.0", "df3d06bb9517e302b1bd265c1e7f16cda51547ad9d99892049340841f3e15836", [:mix], [], "hexpm", "af8daf87384b51b7e611fb1a1f2c4d4876b65ef968fa8bd3adf44cff401c7f21"},
|
||||
"dns_cluster": {:hex, :dns_cluster, "0.1.2", "3eb5be824c7888dadf9781018e1a5f1d3d1113b333c50bce90fb1b83df1015f2", [:mix], [], "hexpm", "7494272040f847637bbdb01bcdf4b871e82daf09b813e7d3cb3b84f112c6f2f8"},
|
||||
"ecto": {:hex, :ecto, "3.12.3", "1a9111560731f6c3606924c81c870a68a34c819f6d4f03822f370ea31a582208", [:mix], [{:decimal, "~> 2.0", [hex: :decimal, repo: "hexpm", optional: false]}, {:jason, "~> 1.0", [hex: :jason, repo: "hexpm", optional: true]}, {:telemetry, "~> 0.4 or ~> 1.0", [hex: :telemetry, repo: "hexpm", optional: false]}], "hexpm", "9efd91506ae722f95e48dc49e70d0cb632ede3b7a23896252a60a14ac6d59165"},
|
||||
"ecto_sql": {:hex, :ecto_sql, "3.12.0", "73cea17edfa54bde76ee8561b30d29ea08f630959685006d9c6e7d1e59113b7d", [:mix], [{:db_connection, "~> 2.4.1 or ~> 2.5", [hex: :db_connection, repo: "hexpm", optional: false]}, {:ecto, "~> 3.12", [hex: :ecto, repo: "hexpm", optional: false]}, {:myxql, "~> 0.7", [hex: :myxql, repo: "hexpm", optional: true]}, {:postgrex, "~> 0.19 or ~> 1.0", [hex: :postgrex, repo: "hexpm", optional: true]}, {:tds, "~> 2.1.1 or ~> 2.2", [hex: :tds, repo: "hexpm", optional: true]}, {:telemetry, "~> 0.4.0 or ~> 1.0", [hex: :telemetry, repo: "hexpm", optional: false]}], "hexpm", "dc9e4d206f274f3947e96142a8fdc5f69a2a6a9abb4649ef5c882323b6d512f0"},
|
||||
|
|
@ -24,7 +24,7 @@
|
|||
"faker": {:hex, :faker, "0.17.0", "671019d0652f63aefd8723b72167ecdb284baf7d47ad3a82a15e9b8a6df5d1fa", [:mix], [], "hexpm", "a7d4ad84a93fd25c5f5303510753789fc2433ff241bf3b4144d3f6f291658a6a"},
|
||||
"file_system": {:hex, :file_system, "0.2.10", "fb082005a9cd1711c05b5248710f8826b02d7d1784e7c3451f9c1231d4fc162d", [:mix], [], "hexpm", "41195edbfb562a593726eda3b3e8b103a309b733ad25f3d642ba49696bf715dc"},
|
||||
"finch": {:hex, :finch, "0.17.0", "17d06e1d44d891d20dbd437335eebe844e2426a0cd7e3a3e220b461127c73f70", [:mix], [{:castore, "~> 0.1 or ~> 1.0", [hex: :castore, repo: "hexpm", optional: false]}, {:mime, "~> 1.0 or ~> 2.0", [hex: :mime, repo: "hexpm", optional: false]}, {:mint, "~> 1.3", [hex: :mint, repo: "hexpm", optional: false]}, {:nimble_options, "~> 0.4 or ~> 1.0", [hex: :nimble_options, repo: "hexpm", optional: false]}, {:nimble_pool, "~> 0.2.6 or ~> 1.0", [hex: :nimble_pool, repo: "hexpm", optional: false]}, {:telemetry, "~> 0.4 or ~> 1.0", [hex: :telemetry, repo: "hexpm", optional: false]}], "hexpm", "8d014a661bb6a437263d4b5abf0bcbd3cf0deb26b1e8596f2a271d22e48934c7"},
|
||||
"floki": {:hex, :floki, "0.35.2", "87f8c75ed8654b9635b311774308b2760b47e9a579dabf2e4d5f1e1d42c39e0b", [:mix], [], "hexpm", "6b05289a8e9eac475f644f09c2e4ba7e19201fd002b89c28c1293e7bd16773d9"},
|
||||
"floki": {:hex, :floki, "0.36.3", "1102f93b16a55bc5383b85ae3ec470f82dee056eaeff9195e8afdf0ef2a43c30", [:mix], [], "hexpm", "fe0158bff509e407735f6d40b3ee0d7deb47f3f3ee7c6c182ad28599f9f6b27a"},
|
||||
"gettext": {:hex, :gettext, "0.24.0", "6f4d90ac5f3111673cbefc4ebee96fe5f37a114861ab8c7b7d5b30a1108ce6d8", [:mix], [{:expo, "~> 0.5.1", [hex: :expo, repo: "hexpm", optional: false]}], "hexpm", "bdf75cdfcbe9e4622dd18e034b227d77dd17f0f133853a1c73b97b3d6c770e8b"},
|
||||
"hackney": {:hex, :hackney, "1.20.1", "8d97aec62ddddd757d128bfd1df6c5861093419f8f7a4223823537bad5d064e2", [:rebar3], [{:certifi, "~> 2.12.0", [hex: :certifi, repo: "hexpm", optional: false]}, {:idna, "~> 6.1.0", [hex: :idna, repo: "hexpm", optional: false]}, {:metrics, "~> 1.0.0", [hex: :metrics, repo: "hexpm", optional: false]}, {:mimerl, "~> 1.1", [hex: :mimerl, repo: "hexpm", optional: false]}, {:parse_trans, "3.4.1", [hex: :parse_trans, repo: "hexpm", optional: false]}, {:ssl_verify_fun, "~> 1.1.0", [hex: :ssl_verify_fun, repo: "hexpm", optional: false]}, {:unicode_util_compat, "~> 0.7.0", [hex: :unicode_util_compat, repo: "hexpm", optional: false]}], "hexpm", "fe9094e5f1a2a2c0a7d10918fee36bfec0ec2a979994cff8cfe8058cd9af38e3"},
|
||||
"hpax": {:hex, :hpax, "0.1.2", "09a75600d9d8bbd064cdd741f21fc06fc1f4cf3d0fcc335e5aa19be1a7235c84", [:mix], [], "hexpm", "2c87843d5a23f5f16748ebe77969880e29809580efdaccd615cd3bed628a8c13"},
|
||||
|
|
@ -40,12 +40,12 @@
|
|||
"nimble_pool": {:hex, :nimble_pool, "1.0.0", "5eb82705d138f4dd4423f69ceb19ac667b3b492ae570c9f5c900bb3d2f50a847", [:mix], [], "hexpm", "80be3b882d2d351882256087078e1b1952a28bf98d0a287be87e4a24a710b67a"},
|
||||
"oban": {:hex, :oban, "2.18.3", "1608c04f8856c108555c379f2f56bc0759149d35fa9d3b825cb8a6769f8ae926", [:mix], [{:ecto_sql, "~> 3.10", [hex: :ecto_sql, repo: "hexpm", optional: false]}, {:ecto_sqlite3, "~> 0.9", [hex: :ecto_sqlite3, repo: "hexpm", optional: true]}, {:jason, "~> 1.1", [hex: :jason, repo: "hexpm", optional: false]}, {:postgrex, "~> 0.16", [hex: :postgrex, repo: "hexpm", optional: true]}, {:telemetry, "~> 0.4 or ~> 1.0", [hex: :telemetry, repo: "hexpm", optional: false]}], "hexpm", "36ca6ca84ef6518f9c2c759ea88efd438a3c81d667ba23b02b062a0aa785475e"},
|
||||
"parse_trans": {:hex, :parse_trans, "3.4.1", "6e6aa8167cb44cc8f39441d05193be6e6f4e7c2946cb2759f015f8c56b76e5ff", [:rebar3], [], "hexpm", "620a406ce75dada827b82e453c19cf06776be266f5a67cff34e1ef2cbb60e49a"},
|
||||
"phoenix": {:hex, :phoenix, "1.7.14", "a7d0b3f1bc95987044ddada111e77bd7f75646a08518942c72a8440278ae7825", [:mix], [{:castore, ">= 0.0.0", [hex: :castore, repo: "hexpm", optional: false]}, {:jason, "~> 1.0", [hex: :jason, repo: "hexpm", optional: true]}, {:phoenix_pubsub, "~> 2.1", [hex: :phoenix_pubsub, repo: "hexpm", optional: false]}, {:phoenix_template, "~> 1.0", [hex: :phoenix_template, repo: "hexpm", optional: false]}, {:phoenix_view, "~> 2.0", [hex: :phoenix_view, repo: "hexpm", optional: true]}, {:plug, "~> 1.14", [hex: :plug, repo: "hexpm", optional: false]}, {:plug_cowboy, "~> 2.7", [hex: :plug_cowboy, repo: "hexpm", optional: true]}, {:plug_crypto, "~> 1.2 or ~> 2.0", [hex: :plug_crypto, repo: "hexpm", optional: false]}, {:telemetry, "~> 0.4 or ~> 1.0", [hex: :telemetry, repo: "hexpm", optional: false]}, {:websock_adapter, "~> 0.5.3", [hex: :websock_adapter, repo: "hexpm", optional: false]}], "hexpm", "c7859bc56cc5dfef19ecfc240775dae358cbaa530231118a9e014df392ace61a"},
|
||||
"phoenix": {:hex, :phoenix, "1.7.17", "2fcdceecc6fb90bec26fab008f96abbd0fd93bc9956ec7985e5892cf545152ca", [:mix], [{:castore, ">= 0.0.0", [hex: :castore, repo: "hexpm", optional: false]}, {:jason, "~> 1.0", [hex: :jason, repo: "hexpm", optional: true]}, {:phoenix_pubsub, "~> 2.1", [hex: :phoenix_pubsub, repo: "hexpm", optional: false]}, {:phoenix_template, "~> 1.0", [hex: :phoenix_template, repo: "hexpm", optional: false]}, {:phoenix_view, "~> 2.0", [hex: :phoenix_view, repo: "hexpm", optional: true]}, {:plug, "~> 1.14", [hex: :plug, repo: "hexpm", optional: false]}, {:plug_cowboy, "~> 2.7", [hex: :plug_cowboy, repo: "hexpm", optional: true]}, {:plug_crypto, "~> 1.2 or ~> 2.0", [hex: :plug_crypto, repo: "hexpm", optional: false]}, {:telemetry, "~> 0.4 or ~> 1.0", [hex: :telemetry, repo: "hexpm", optional: false]}, {:websock_adapter, "~> 0.5.3", [hex: :websock_adapter, repo: "hexpm", optional: false]}], "hexpm", "50e8ad537f3f7b0efb1509b2f75b5c918f697be6a45d48e49a30d3b7c0e464c9"},
|
||||
"phoenix_ecto": {:hex, :phoenix_ecto, "4.4.3", "86e9878f833829c3f66da03d75254c155d91d72a201eb56ae83482328dc7ca93", [:mix], [{:ecto, "~> 3.5", [hex: :ecto, repo: "hexpm", optional: false]}, {:phoenix_html, "~> 2.14.2 or ~> 3.0 or ~> 4.0", [hex: :phoenix_html, repo: "hexpm", optional: true]}, {:plug, "~> 1.9", [hex: :plug, repo: "hexpm", optional: false]}], "hexpm", "d36c401206f3011fefd63d04e8ef626ec8791975d9d107f9a0817d426f61ac07"},
|
||||
"phoenix_html": {:hex, :phoenix_html, "3.3.4", "42a09fc443bbc1da37e372a5c8e6755d046f22b9b11343bf885067357da21cb3", [:mix], [{:plug, "~> 1.5", [hex: :plug, repo: "hexpm", optional: true]}], "hexpm", "0249d3abec3714aff3415e7ee3d9786cb325be3151e6c4b3021502c585bf53fb"},
|
||||
"phoenix_live_dashboard": {:hex, :phoenix_live_dashboard, "0.8.3", "7ff51c9b6609470f681fbea20578dede0e548302b0c8bdf338b5a753a4f045bf", [:mix], [{:ecto, "~> 3.6.2 or ~> 3.7", [hex: :ecto, repo: "hexpm", optional: true]}, {:ecto_mysql_extras, "~> 0.5", [hex: :ecto_mysql_extras, repo: "hexpm", optional: true]}, {:ecto_psql_extras, "~> 0.7", [hex: :ecto_psql_extras, repo: "hexpm", optional: true]}, {:ecto_sqlite3_extras, "~> 1.1.7 or ~> 1.2.0", [hex: :ecto_sqlite3_extras, repo: "hexpm", optional: true]}, {:mime, "~> 1.6 or ~> 2.0", [hex: :mime, repo: "hexpm", optional: false]}, {:phoenix_live_view, "~> 0.19 or ~> 1.0", [hex: :phoenix_live_view, repo: "hexpm", optional: false]}, {:telemetry_metrics, "~> 0.6 or ~> 1.0", [hex: :telemetry_metrics, repo: "hexpm", optional: false]}], "hexpm", "f9470a0a8bae4f56430a23d42f977b5a6205fdba6559d76f932b876bfaec652d"},
|
||||
"phoenix_live_reload": {:hex, :phoenix_live_reload, "1.4.1", "2aff698f5e47369decde4357ba91fc9c37c6487a512b41732818f2204a8ef1d3", [:mix], [{:file_system, "~> 0.2.1 or ~> 0.3", [hex: :file_system, repo: "hexpm", optional: false]}, {:phoenix, "~> 1.4", [hex: :phoenix, repo: "hexpm", optional: false]}], "hexpm", "9bffb834e7ddf08467fe54ae58b5785507aaba6255568ae22b4d46e2bb3615ab"},
|
||||
"phoenix_live_view": {:hex, :phoenix_live_view, "0.20.3", "8b6406bc0a451f295407d7acff7f234a6314be5bbe0b3f90ed82b07f50049878", [:mix], [{:jason, "~> 1.0", [hex: :jason, repo: "hexpm", optional: true]}, {:phoenix, "~> 1.6.15 or ~> 1.7.0", [hex: :phoenix, repo: "hexpm", optional: false]}, {:phoenix_html, "~> 3.3 or ~> 4.0", [hex: :phoenix_html, repo: "hexpm", optional: false]}, {:phoenix_template, "~> 1.0", [hex: :phoenix_template, repo: "hexpm", optional: false]}, {:phoenix_view, "~> 2.0", [hex: :phoenix_view, repo: "hexpm", optional: true]}, {:plug, "~> 1.15", [hex: :plug, repo: "hexpm", optional: false]}, {:telemetry, "~> 0.4.2 or ~> 1.0", [hex: :telemetry, repo: "hexpm", optional: false]}], "hexpm", "a8e4385e05618b424779f894ed2df97d3c7518b7285fcd11979077ae6226466b"},
|
||||
"phoenix_live_view": {:hex, :phoenix_live_view, "1.0.0", "3a10dfce8f87b2ad4dc65de0732fc2a11e670b2779a19e8d3281f4619a85bce4", [:mix], [{:floki, "~> 0.36", [hex: :floki, repo: "hexpm", optional: true]}, {:jason, "~> 1.0", [hex: :jason, repo: "hexpm", optional: true]}, {:phoenix, "~> 1.6.15 or ~> 1.7.0", [hex: :phoenix, repo: "hexpm", optional: false]}, {:phoenix_html, "~> 3.3 or ~> 4.0", [hex: :phoenix_html, repo: "hexpm", optional: false]}, {:phoenix_template, "~> 1.0", [hex: :phoenix_template, repo: "hexpm", optional: false]}, {:phoenix_view, "~> 2.0", [hex: :phoenix_view, repo: "hexpm", optional: true]}, {:plug, "~> 1.15", [hex: :plug, repo: "hexpm", optional: false]}, {:telemetry, "~> 0.4.2 or ~> 1.0", [hex: :telemetry, repo: "hexpm", optional: false]}], "hexpm", "254caef0028765965ca6bd104cc7d68dcc7d57cc42912bef92f6b03047251d99"},
|
||||
"phoenix_pubsub": {:hex, :phoenix_pubsub, "2.1.3", "3168d78ba41835aecad272d5e8cd51aa87a7ac9eb836eabc42f6e57538e3731d", [:mix], [], "hexpm", "bba06bc1dcfd8cb086759f0edc94a8ba2bc8896d5331a1e2c2902bf8e36ee502"},
|
||||
"phoenix_template": {:hex, :phoenix_template, "1.0.4", "e2092c132f3b5e5b2d49c96695342eb36d0ed514c5b252a77048d5969330d639", [:mix], [{:phoenix_html, "~> 2.14.2 or ~> 3.0 or ~> 4.0", [hex: :phoenix_html, repo: "hexpm", optional: true]}], "hexpm", "2c0c81f0e5c6753faf5cca2f229c9709919aba34fab866d3bc05060c9c444206"},
|
||||
"plug": {:hex, :plug, "1.16.1", "40c74619c12f82736d2214557dedec2e9762029b2438d6d175c5074c933edc9d", [:mix], [{:mime, "~> 1.0 or ~> 2.0", [hex: :mime, repo: "hexpm", optional: false]}, {:plug_crypto, "~> 1.1.1 or ~> 1.2 or ~> 2.0", [hex: :plug_crypto, repo: "hexpm", optional: false]}, {:telemetry, "~> 0.4.3 or ~> 1.0", [hex: :telemetry, repo: "hexpm", optional: false]}], "hexpm", "a13ff6b9006b03d7e33874945b2755253841b238c34071ed85b0e86057f8cddc"},
|
||||
|
|
@ -64,5 +64,5 @@
|
|||
"tzdata": {:hex, :tzdata, "1.1.2", "45e5f1fcf8729525ec27c65e163be5b3d247ab1702581a94674e008413eef50b", [:mix], [{:hackney, "~> 1.17", [hex: :hackney, repo: "hexpm", optional: false]}], "hexpm", "cec7b286e608371602318c414f344941d5eb0375e14cfdab605cca2fe66cba8b"},
|
||||
"unicode_util_compat": {:hex, :unicode_util_compat, "0.7.0", "bc84380c9ab48177092f43ac89e4dfa2c6d62b40b8bd132b1059ecc7232f9a78", [:rebar3], [], "hexpm", "25eee6d67df61960cf6a794239566599b09e17e668d3700247bc498638152521"},
|
||||
"websock": {:hex, :websock, "0.5.3", "2f69a6ebe810328555b6fe5c831a851f485e303a7c8ce6c5f675abeb20ebdadc", [:mix], [], "hexpm", "6105453d7fac22c712ad66fab1d45abdf049868f253cf719b625151460b8b453"},
|
||||
"websock_adapter": {:hex, :websock_adapter, "0.5.7", "65fa74042530064ef0570b75b43f5c49bb8b235d6515671b3d250022cb8a1f9e", [:mix], [{:bandit, ">= 0.6.0", [hex: :bandit, repo: "hexpm", optional: true]}, {:plug, "~> 1.14", [hex: :plug, repo: "hexpm", optional: false]}, {:plug_cowboy, "~> 2.6", [hex: :plug_cowboy, repo: "hexpm", optional: true]}, {:websock, "~> 0.5", [hex: :websock, repo: "hexpm", optional: false]}], "hexpm", "d0f478ee64deddfec64b800673fd6e0c8888b079d9f3444dd96d2a98383bdbd1"},
|
||||
"websock_adapter": {:hex, :websock_adapter, "0.5.8", "3b97dc94e407e2d1fc666b2fb9acf6be81a1798a2602294aac000260a7c4a47d", [:mix], [{:bandit, ">= 0.6.0", [hex: :bandit, repo: "hexpm", optional: true]}, {:plug, "~> 1.14", [hex: :plug, repo: "hexpm", optional: false]}, {:plug_cowboy, "~> 2.6", [hex: :plug_cowboy, repo: "hexpm", optional: true]}, {:websock, "~> 0.5", [hex: :websock, repo: "hexpm", optional: false]}], "hexpm", "315b9a1865552212b5f35140ad194e67ce31af45bcee443d4ecb96b5fd3f3782"},
|
||||
}
|
||||
|
|
|
|||
|
|
@ -41,4 +41,10 @@ defmodule Pinchflat.Utils.StringUtilsTest do
|
|||
assert StringUtils.truncate("hello", 10) == "hello"
|
||||
end
|
||||
end
|
||||
|
||||
describe "double_brace/1" do
|
||||
test "wraps a string in double braces" do
|
||||
assert StringUtils.double_brace("hello") == "{{ hello }}"
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
|||
Loading…
Reference in a new issue