Styling /mempool live view

This commit is contained in:
Vamsi Krishna B 2021-07-13 18:20:43 +05:30
parent 84717e5d9c
commit 58de16bb3c
2 changed files with 26 additions and 37 deletions

View File

@ -18,40 +18,31 @@ defmodule ZcashExplorerWeb.RawMempoolLive do
<tbody class="bg-white-500 divide-y divide-gray-200">
<%= for tx <- @raw_mempool do %>
<tr class="hover:bg-indigo-50">
<td class="px-6 py-4 whitespace-nowrap text-sm font-medium text-indigo-600 hover:text-indigo-500">
<a href='/transactions/<%= tx["txid"] %>'>
<%= tx["txid"] %>
</a>
</td>
<td class="px-4 py-4 whitespace-nowrap text-sm font-medium text-gray-500 hover:text-gray-600">
<%= tx["info"]["height"] %>
</td>
<td class="px-4 py-4 whitespace-nowrap text-sm font-medium text-gray-500 hover:text-gray-600">
<%= ZcashExplorerWeb.BlockView.mined_time_rel(tx["info"]["time"]) %>
</td>
<td class="px-4 py-4 whitespace-nowrap text-sm font-medium text-gray-500 hover:text-gray-600">
<%= ZcashExplorerWeb.TransactionView.format_zec(tx["info"]["fee"]) %>
</td>
<td class="px-4 py-4 whitespace-nowrap text-sm font-medium text-gray-500 hover:text-gray-600">
<%= tx["info"]["size"] %>
</td>
<td class="px-4 py-4 whitespace-nowrap text-sm font-medium text-gray-500 hover:text-gray-600">
<%= tx["info"]["currentpriority"] %>
</td>
</tr>
<% end %>
</tbody>
</table>
</div>
"""
end

View File

@ -1,10 +1,8 @@
<main class="py-4">
<div class="grid gap-4 grid-cols-1 mx-8">
<h3 class="text-lg leading-6 font-medium text-gray-500 py-4">
<div class="grid grid-cols-1 mx-8">
<h3 class="text-lg leading-6 font-medium text-gray-500 py-2">
Zcash Mempool
</h3>
<div class="shadow overflow-hidden border-b border-gray-200 rounded-lg overflow-x-auto">
<%= live_render(@conn, ZcashExplorerWeb.RawMempoolLive) %>
</div>
</div>
</main>