tweak styling
This commit is contained in:
parent
bf235b837c
commit
821a8e223c
@ -7,7 +7,7 @@
|
|||||||
|
|
||||||
.input-primary {
|
.input-primary {
|
||||||
@apply bg-primary-900;
|
@apply bg-primary-900;
|
||||||
@apply border-primary-600 hover:border-primary-500 active:border-primary-400;
|
@apply border-primary-900 hover:border-primary-800 active:border-primary-700;
|
||||||
@apply text-primary-400;
|
@apply text-primary-400;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -34,7 +34,7 @@
|
|||||||
|
|
||||||
.btn-primary {
|
.btn-primary {
|
||||||
@apply bg-primary-900 focus:bg-primary-900 active:bg-primary-800;
|
@apply bg-primary-900 focus:bg-primary-900 active:bg-primary-800;
|
||||||
@apply border-primary-600 hover:border-primary-500 active:border-primary-400;
|
@apply border-primary-900 hover:border-primary-800 active:border-primary-700;
|
||||||
@apply text-primary-400;
|
@apply text-primary-400;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -59,7 +59,6 @@
|
|||||||
|
|
||||||
.alert {
|
.alert {
|
||||||
@apply bg-primary-900;
|
@apply bg-primary-900;
|
||||||
@apply border-primary-600 hover:border-primary-500 active:border-primary-400;
|
|
||||||
@apply text-primary-400;
|
@apply text-primary-400;
|
||||||
padding: 15px;
|
padding: 15px;
|
||||||
margin-bottom: 20px;
|
margin-bottom: 20px;
|
||||||
|
@ -71,8 +71,8 @@ defmodule MemexWeb.Components.TableComponent do
|
|||||||
last_sort_key: initial_key,
|
last_sort_key: initial_key,
|
||||||
sort_mode: initial_sort_mode
|
sort_mode: initial_sort_mode
|
||||||
)
|
)
|
||||||
|> assign_new(:row_class, fn -> "bg-white" end)
|
|> assign_new(:row_class, fn -> "bg-primary-900" end)
|
||||||
|> assign_new(:alternate_row_class, fn -> "bg-gray-200" end)
|
|> assign_new(:alternate_row_class, fn -> "bg-primary-900" end)
|
||||||
|
|
||||||
{:ok, socket}
|
{:ok, socket}
|
||||||
end
|
end
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
<div id={@id} class="w-full overflow-x-auto border border-gray-600 rounded-lg shadow-lg bg-black">
|
<div id={@id} class="w-full overflow-x-auto rounded-lg shadow-lg bg-primary-900">
|
||||||
<table class="min-w-full table-auto text-center bg-white">
|
<table class="min-w-full table-auto text-center bg-primary-900">
|
||||||
<thead class="border-b border-primary-600">
|
<thead class="border-b border-primary-800">
|
||||||
<tr>
|
<tr>
|
||||||
<%= for %{key: key, label: label} = column <- @columns do %>
|
<%= for %{key: key, label: label} = column <- @columns do %>
|
||||||
<%= if column |> Map.get(:sortable, true) do %>
|
<%= if column |> Map.get(:sortable, true) do %>
|
||||||
@ -11,16 +11,16 @@
|
|||||||
phx-value-sort-key={key}
|
phx-value-sort-key={key}
|
||||||
phx-target={@myself}
|
phx-target={@myself}
|
||||||
>
|
>
|
||||||
<span class="underline"><%= label %></span>
|
<span><%= label %></span>
|
||||||
<%= if @last_sort_key == key do %>
|
<%= if @last_sort_key == key do %>
|
||||||
<%= case @sort_mode do %>
|
<%= case @sort_mode do %>
|
||||||
<% :asc -> %>
|
<% :asc -> %>
|
||||||
<i class="fas fa-sm fa-chevron-down"></i>
|
<i class="w-0 float-right fas fa-sm fa-chevron-down"></i>
|
||||||
<% :desc -> %>
|
<% :desc -> %>
|
||||||
<i class="fas fa-sm fa-chevron-up"></i>
|
<i class="w-0 float-right fas fa-sm fa-chevron-up"></i>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% else %>
|
<% else %>
|
||||||
<i class="fas fa-sm fa-chevron-up opacity-0"></i>
|
<i class="w-0 float-right fas fa-sm fa-chevron-up opacity-0"></i>
|
||||||
<% end %>
|
<% end %>
|
||||||
</span>
|
</span>
|
||||||
</th>
|
</th>
|
||||||
|
Loading…
Reference in New Issue
Block a user