Skip to content

Commit 1fbdb11

Browse files
committed
feat: remove loading bar in agg proofs
1 parent dab2b61 commit 1fbdb11

2 files changed

Lines changed: 1 addition & 19 deletions

File tree

explorer/lib/explorer_web/live/pages/agg_proofs/index.ex

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -16,19 +16,13 @@ defmodule ExplorerWeb.AggProofs.Index do
1616
})
1717
|> Enum.map(fn proof -> proof |> Map.merge(%{age: "2 days ago"}) end)
1818

19-
# TODO fetch from aggregation not batch
20-
remaining_time = Helpers.get_next_scheduled_batch_remaining_time()
21-
2219
{
2320
:ok,
2421
assign(
2522
socket,
2623
proofs: proofs,
2724
current_page: current_page,
28-
last_page: AggregatedProofs.get_last_page(@page_size),
29-
next_scheduled_batch_remaining_time_percentage:
30-
Helpers.get_next_scheduled_batch_remaining_time_percentage(remaining_time),
31-
next_scheduled_batch_remaining_time: remaining_time
25+
last_page: AggregatedProofs.get_last_page(@page_size)
3226
)
3327
}
3428
end

explorer/lib/explorer_web/live/pages/agg_proofs/index.html.heex

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,5 @@
11
<div class="flex flex-col space-y-3 text-foreground px-1 sm:max-w-lg md:max-w-3xl lg:max-w-5xl mx-auto capitalize">
22
<.card_preheding>Aggregation</.card_preheding>
3-
<!-- Progress bar based on https://dev.to/mikekennedydev/progress-bar-text-colour-1gg6 -->
4-
<.live_component
5-
id="labeled-progress-bar"
6-
module={LabeledProgressBarComponent}
7-
percent_progress={@next_scheduled_batch_remaining_time_percentage}
8-
label={
9-
case @next_scheduled_batch_remaining_time do
10-
0 -> "Next aggregated proof is around the corner!"
11-
time -> "Next aggregated proof in #{time} minutes"
12-
end
13-
}
14-
/>
153
<%= if @proofs != :empty and @proofs != [] do %>
164
<.card_background class="w-full overflow-x-auto sm:col-span-2">
175
<.agg_proofs_table proofs={@proofs} />

0 commit comments

Comments
 (0)