diff --git a/CHANGELOG.md b/CHANGELOG.md index 3decfd491b..7c84006016 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,7 @@ ### Features ### Fixes +- [#2291](https://github.com/poanetwork/blockscout/pull/2291) - dashboard fix for md resolution, transactions load fix, block info row fix, addresses page issue, check mark issue ### Chore - [#2289](https://github.com/poanetwork/blockscout/pull/2289) - Optional websockets for dev environment diff --git a/apps/block_scout_web/assets/css/components/_card.scss b/apps/block_scout_web/assets/css/components/_card.scss index 63a8f4a852..0737e1b355 100644 --- a/apps/block_scout_web/assets/css/components/_card.scss +++ b/apps/block_scout_web/assets/css/components/_card.scss @@ -6,7 +6,7 @@ $card-vertical-padding: 30px; $card-background-1: $primary !default; $card-background-1-text-color: #fff !default; $card-tab-icon-color: #20b760 !default; -$card-tab-icon-color-active: #20b760 !default; +$card-tab-icon-color-active: #fff !default; .card { background-color: $card-background-color; @@ -14,6 +14,21 @@ $card-tab-icon-color-active: #20b760 !default; border: none; box-shadow: 0 0 30px 0 rgba(202, 199, 226, 0.5); margin-bottom: $common-container-margin; + + .block-details-row { + flex-direction: row; + @include media-breakpoint-down(sm) { + flex-direction: column; + } + + .block-detail-el { + & + .block-detail-el { + @include media-breakpoint-down(sm) { + margin-top: 6px; + } + } + } + } } .card-background-1 { diff --git a/apps/block_scout_web/assets/css/components/_dashboard-banner.scss b/apps/block_scout_web/assets/css/components/_dashboard-banner.scss index ecde4e882b..33d104a9fd 100644 --- a/apps/block_scout_web/assets/css/components/_dashboard-banner.scss +++ b/apps/block_scout_web/assets/css/components/_dashboard-banner.scss @@ -146,6 +146,11 @@ $dashboard-banner-chart-axis-font-color: $dashboard-stats-item-value-color !defa width: 750px; position: relative; + @include media-breakpoint-down(lg) { + margin-top: 15px; + width: 550px; + } + @include media-breakpoint-down(md) { border-top-right-radius: 10px; height: auto; @@ -157,10 +162,6 @@ $dashboard-banner-chart-axis-font-color: $dashboard-stats-item-value-color !defa box-shadow: 0 0 35px 0 rgba(0, 0, 0, 0.2); } - @include media-breakpoint-down(lg) { - margin-top: 15px; - } - @include media-breakpoint-down(sm) { width: 100%; } @@ -189,6 +190,11 @@ $dashboard-banner-chart-axis-font-color: $dashboard-stats-item-value-color !defa display: grid; grid-template-columns: 1fr 1fr 1fr 1fr; + @include media-breakpoint-down(lg) { + grid-template-columns: 1fr 1fr; + row-gap: 20px; + } + @include media-breakpoint-down(md) { grid-template-columns: 1fr; row-gap: 20px; diff --git a/apps/block_scout_web/assets/css/components/_stakes_table.scss b/apps/block_scout_web/assets/css/components/_stakes_table.scss index 0bbf59e69c..79cdc20b38 100644 --- a/apps/block_scout_web/assets/css/components/_stakes_table.scss +++ b/apps/block_scout_web/assets/css/components/_stakes_table.scss @@ -7,6 +7,25 @@ $stakes-table-cell-separation: 25px !default; width: 100%; } +.addresses-table-container { + margin-left: -30px; + margin-right: -30px; + .stakes-table-container { + table { + width: 100%; + th:first-child { + padding-left: 25px; + } + td:first-child { + padding-left: 25px; + } + } + } + .color-lighten { + color: #828ba0; + } +} + .stakes-table { min-width: fit-content; width: 100%; diff --git a/apps/block_scout_web/assets/css/components/_tile.scss b/apps/block_scout_web/assets/css/components/_tile.scss index 68b873334c..8965715727 100644 --- a/apps/block_scout_web/assets/css/components/_tile.scss +++ b/apps/block_scout_web/assets/css/components/_tile.scss @@ -272,6 +272,7 @@ $tile-body-a-color: #5959d8 !default; } &.tile-type-block { + max-width: 100%; .tile-title { font-weight: 700; line-height: 1.2; @@ -330,3 +331,23 @@ $tile-body-a-color: #5959d8 !default; } } } + +.card-chain-blocks { + .card-body { + .col-lg-3 { + @include media-breakpoint-down(lg) { + padding-left: 6px; + padding-right: 6px; + } + .tile-type-block { + overflow: hidden; + } + } + .row { + @include media-breakpoint-down(lg) { + margin-left: -6px; + margin-right: -6px; + } + } + } +} diff --git a/apps/block_scout_web/lib/block_scout_web/templates/address/_tile.html.eex b/apps/block_scout_web/lib/block_scout_web/templates/address/_tile.html.eex index c2e62e2004..9680faa2a8 100644 --- a/apps/block_scout_web/lib/block_scout_web/templates/address/_tile.html.eex +++ b/apps/block_scout_web/lib/block_scout_web/templates/address/_tile.html.eex @@ -1,51 +1,39 @@ -
-
- -
+ + - + <%= @index %> -
- -
-
-
- <%= @address |> BlockScoutWeb.AddressView.address_partial_selector(nil, nil) |> BlockScoutWeb.RenderHelpers.render_partial() %> - - - - <%= @tx_count %> - <%= gettext "Transactions sent" %> - <% if validator?(@address) do %> - - <%= @validation_count %> - <%= gettext "Validations" %> - <% end %> - -
- - -
- - <%= balance(@address) %> -
- - - data-usd-exchange-rate="<%= @exchange_rate.usd_value %>"> - <% end %> - - - - <%= if @total_supply do %> - (<%= balance_percentage(@address, @total_supply) %>) - <% end %> - -
-
-
-
-
-
+ + + <%= @address |> BlockScoutWeb.AddressView.address_partial_selector(nil, nil) |> BlockScoutWeb.RenderHelpers.render_partial() %> + + + <%= balance(@address) %> + + + data-usd-exchange-rate="<%= @exchange_rate.usd_value %>"> + <% end %> + + + + + <%= if @total_supply do %> + (<%= balance_percentage(@address, @total_supply) %>) + <% end %> + + + + + <%= @tx_count %> + <%= gettext "Transactions sent" %> + <% if validator?(@address) do %> + + <%= @validation_count %> + <%= gettext "Validations" %> + <% end %> + + + diff --git a/apps/block_scout_web/lib/block_scout_web/templates/address/index.html.eex b/apps/block_scout_web/lib/block_scout_web/templates/address/index.html.eex index 47d7f2457b..3aaab46ad5 100644 --- a/apps/block_scout_web/lib/block_scout_web/templates/address/index.html.eex +++ b/apps/block_scout_web/lib/block_scout_web/templates/address/index.html.eex @@ -3,11 +3,48 @@

<%= gettext "Addresses" %>

- <%= render BlockScoutWeb.CommonComponentsView, "_pagination_container.html", position: "top", cur_page_number: "1", show_pagination_limit: true, data_next_page_button: true, data_prev_page_button: true %> - -
- - <%= render BlockScoutWeb.CommonComponentsView, "_pagination_container.html", position: "bottom", cur_page_number: "1", show_pagination_limit: true, data_next_page_button: true, data_prev_page_button: true %> + <%= render BlockScoutWeb.CommonComponentsView, "_pagination_container.html", position: "top", cur_page_number: "1", show_pagination_limit: true, data_next_page_button: true, data_prev_page_button: true %> + +
+
+ + + + + + + + + + + + + +
+
+   +
+
+
+ Address +
+
+
+ Balance +
+
+
+ Percentage +
+
+
+ Txn Count +
+
+
+
+ + <%= render BlockScoutWeb.CommonComponentsView, "_pagination_container.html", position: "bottom", cur_page_number: "1", show_pagination_limit: true, data_next_page_button: true, data_prev_page_button: true %>
diff --git a/apps/block_scout_web/lib/block_scout_web/templates/address/overview.html.eex b/apps/block_scout_web/lib/block_scout_web/templates/address/overview.html.eex index 76387a9662..e6178a4e72 100644 --- a/apps/block_scout_web/lib/block_scout_web/templates/address/overview.html.eex +++ b/apps/block_scout_web/lib/block_scout_web/templates/address/overview.html.eex @@ -4,7 +4,7 @@
-

+

<%= address_title(@address) %> <%= gettext "Details" %> diff --git a/apps/block_scout_web/lib/block_scout_web/templates/block/overview.html.eex b/apps/block_scout_web/lib/block_scout_web/templates/block/overview.html.eex index 23985be4f6..24b2d9e61a 100644 --- a/apps/block_scout_web/lib/block_scout_web/templates/block/overview.html.eex +++ b/apps/block_scout_web/lib/block_scout_web/templates/block/overview.html.eex @@ -16,17 +16,17 @@ <%= link(@block, to: block_path(BlockScoutWeb.Endpoint, :show, @block.number)) %> <% end %>

-
+
- <%= gettext "%{count} Transactions", count: @block_transaction_count %> + <%= gettext "%{count} Transactions", count: @block_transaction_count %> <%= if @block.size do %> - <%= Cldr.Unit.new(:byte, @block.size) |> cldr_unit_to_string!() %> + <%= Cldr.Unit.new(:byte, @block.size) |> cldr_unit_to_string!() %> <% end %> - +

diff --git a/apps/block_scout_web/priv/gettext/default.pot b/apps/block_scout_web/priv/gettext/default.pot index c263d8a6ce..41aa7bf553 100644 --- a/apps/block_scout_web/priv/gettext/default.pot +++ b/apps/block_scout_web/priv/gettext/default.pot @@ -877,7 +877,7 @@ msgid "Transactions" msgstr "" #, elixir-format -#: lib/block_scout_web/templates/address/_tile.html.eex:19 +#: lib/block_scout_web/templates/address/_tile.html.eex:31 msgid "Transactions sent" msgstr "" @@ -923,7 +923,7 @@ msgid "Validated Transactions" msgstr "" #, elixir-format -#: lib/block_scout_web/templates/address/_tile.html.eex:23 +#: lib/block_scout_web/templates/address/_tile.html.eex:35 msgid "Validations" msgstr ""