diff --git a/CHANGELOG.md b/CHANGELOG.md index a847de3b1d..94a259cd55 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,9 +1,11 @@ ## Current ### Features +- [#2109](https://github.com/poanetwork/blockscout/pull/2109) - use bigger updates instead of `Multi` transactions in BlocksTransactionsMismatch - [#2075](https://github.com/poanetwork/blockscout/pull/2075) - add blocks cache ### Fixes +- [#2121](https://github.com/poanetwork/blockscout/pull/2121) - Binding of 404 page - [#2120](https://github.com/poanetwork/blockscout/pull/2120) - footer links and socials focus color issue - [#2113](https://github.com/poanetwork/blockscout/pull/2113) - renewed logos for rsk, dai, blockscout; themes color changes for lukso; error images for lukso - [#2112](https://github.com/poanetwork/blockscout/pull/2112) - themes color improvements, dropdown color issue @@ -12,7 +14,12 @@ - [#2090](https://github.com/poanetwork/blockscout/pull/2090) - updated some ETC theme colors - [#2096](https://github.com/poanetwork/blockscout/pull/2096) - RSK theme fixes - [#2093](https://github.com/poanetwork/blockscout/pull/2093) - detect token transfer type for deprecated erc721 spec -- [#2108](https://github.com/poanetwork/blockscout/pull/2108) - fixe uncle fetching without full transactions +- [#2108](https://github.com/poanetwork/blockscout/pull/2108) - fix uncle fetching without full transactions +- [#2123](https://github.com/poanetwork/blockscout/pull/2123) - fix coins percentage view +- [#2119](https://github.com/poanetwork/blockscout/pull/2119) - fix map logging + +### Chore +- [#2127](https://github.com/poanetwork/blockscout/pull/2127) - use previouse chromedriver version ### Chore diff --git a/apps/block_scout_web/lib/block_scout_web/controller.ex b/apps/block_scout_web/lib/block_scout_web/controller.ex index fe2851c197..cf545f5260 100644 --- a/apps/block_scout_web/lib/block_scout_web/controller.ex +++ b/apps/block_scout_web/lib/block_scout_web/controller.ex @@ -12,8 +12,9 @@ defmodule BlockScoutWeb.Controller do def not_found(conn) do conn |> put_status(:not_found) - |> put_view(BlockScoutWeb.ErrorView) - |> render("404.html") + |> put_view(BlockScoutWeb.PageNotFoundView) + |> render(:index) + |> halt() end def unprocessable_entity(conn) do diff --git a/apps/block_scout_web/lib/block_scout_web/controllers/page_not_found_controller.ex b/apps/block_scout_web/lib/block_scout_web/controllers/page_not_found_controller.ex new file mode 100644 index 0000000000..e453e5463b --- /dev/null +++ b/apps/block_scout_web/lib/block_scout_web/controllers/page_not_found_controller.ex @@ -0,0 +1,8 @@ +defmodule BlockScoutWeb.PageNotFoundController do + use BlockScoutWeb, :controller + + def index(conn, _params) do + conn + |> render("index.html") + end +end diff --git a/apps/block_scout_web/lib/block_scout_web/router.ex b/apps/block_scout_web/lib/block_scout_web/router.ex index aa19725811..48a5c8f8da 100644 --- a/apps/block_scout_web/lib/block_scout_web/router.ex +++ b/apps/block_scout_web/lib/block_scout_web/router.ex @@ -245,5 +245,7 @@ defmodule BlockScoutWeb.Router do get("/chain_blocks", ChainController, :chain_blocks, as: :chain_blocks) get("/api_docs", APIDocsController, :index) + + get("/:page", PageNotFoundController, :index) end end 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 270450c2c0..c2e62e2004 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 @@ -39,7 +39,7 @@ - <% if @total_supply do %> + <%= if @total_supply do %> (<%= balance_percentage(@address, @total_supply) %>) <% end %> diff --git a/apps/block_scout_web/lib/block_scout_web/templates/page_not_found/index.html.eex b/apps/block_scout_web/lib/block_scout_web/templates/page_not_found/index.html.eex index 6850c2deb2..d91690ea9e 100644 --- a/apps/block_scout_web/lib/block_scout_web/templates/page_not_found/index.html.eex +++ b/apps/block_scout_web/lib/block_scout_web/templates/page_not_found/index.html.eex @@ -4,8 +4,8 @@
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua
+The requested path was not found on BlockScout.
Back Home