From 5f92c94fa34e4e1ff2d33a22a83ecc7f213f3c23 Mon Sep 17 00:00:00 2001 From: Ayrat Badykov Date: Fri, 19 Apr 2019 14:43:37 +0300 Subject: [PATCH 1/4] fix top nav autocomplete --- .../assets/css/components/_navbar.scss | 2 +- .../block_scout_web/templates/layout/_topnav.html.eex | 3 ++- .../lib/block_scout_web/templates/layout/app.html.eex | 11 ----------- 3 files changed, 3 insertions(+), 13 deletions(-) diff --git a/apps/block_scout_web/assets/css/components/_navbar.scss b/apps/block_scout_web/assets/css/components/_navbar.scss index 455011273a..81038a3c95 100644 --- a/apps/block_scout_web/assets/css/components/_navbar.scss +++ b/apps/block_scout_web/assets/css/components/_navbar.scss @@ -114,7 +114,7 @@ } .input-group-append { - margin-left: 0px; + margin-left: -0.5px; path { fill: $secondary; diff --git a/apps/block_scout_web/lib/block_scout_web/templates/layout/_topnav.html.eex b/apps/block_scout_web/lib/block_scout_web/templates/layout/_topnav.html.eex index 770dcdd436..c31c68ff42 100644 --- a/apps/block_scout_web/lib/block_scout_web/templates/layout/_topnav.html.eex +++ b/apps/block_scout_web/lib/block_scout_web/templates/layout/_topnav.html.eex @@ -93,8 +93,9 @@ prepop: true, minChars: 3, maxItems: 8, - value: "symbol", + value: "contract_address_hash", label: "contract_address_hash", + descrSearch: true, descr: "symbol" ]) %>
diff --git a/apps/block_scout_web/lib/block_scout_web/templates/layout/app.html.eex b/apps/block_scout_web/lib/block_scout_web/templates/layout/app.html.eex index c9c533138e..b3b6ba0665 100644 --- a/apps/block_scout_web/lib/block_scout_web/templates/layout/app.html.eex +++ b/apps/block_scout_web/lib/block_scout_web/templates/layout/app.html.eex @@ -19,17 +19,6 @@ - <%= render_existing(@view_module, "_metatags.html", assigns) || render("_default_title.html") %> From e522357180c72cd35352a9e8060f738a176884f2 Mon Sep 17 00:00:00 2001 From: Ayrat Badykov Date: Fri, 19 Apr 2019 14:49:42 +0300 Subject: [PATCH 2/4] add CHANGELOG entry --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 99dc22475f..7157d397c4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -18,6 +18,7 @@ - [#1769](https://github.com/poanetwork/blockscout/pull/1769) - add timestamp to block overview - [#1768](https://github.com/poanetwork/blockscout/pull/1768) - fix first block parameter - [#1778](https://github.com/poanetwork/blockscout/pull/1778) - Make websocket optional for realtime fetcher + - [#1793](https://github.com/poanetwork/blockscout/pull/1793) - fix top nav autocomplete ### Chore From 725682d8f86e6a61d96ccd0efc053d4e4b2fb82a Mon Sep 17 00:00:00 2001 From: Ayrat Badykov Date: Fri, 19 Apr 2019 15:01:42 +0300 Subject: [PATCH 3/4] fix gettext --- apps/block_scout_web/priv/gettext/default.pot | 18 +++++++++--------- .../priv/gettext/en/LC_MESSAGES/default.po | 18 +++++++++--------- 2 files changed, 18 insertions(+), 18 deletions(-) diff --git a/apps/block_scout_web/priv/gettext/default.pot b/apps/block_scout_web/priv/gettext/default.pot index 7010a68126..32542b09e1 100644 --- a/apps/block_scout_web/priv/gettext/default.pot +++ b/apps/block_scout_web/priv/gettext/default.pot @@ -62,7 +62,7 @@ msgid "(query)" msgstr "" #, elixir-format -#: lib/block_scout_web/templates/layout/app.html.eex:46 +#: lib/block_scout_web/templates/layout/app.html.eex:35 msgid "- We're indexing this chain right now. Some of the counts may be inaccurate." msgstr "" @@ -155,7 +155,7 @@ msgid "Block Height: %{height}" msgstr "" #, elixir-format -#: lib/block_scout_web/templates/layout/app.html.eex:61 +#: lib/block_scout_web/templates/layout/app.html.eex:50 msgid "Block Mined, awaiting import..." msgstr "" @@ -182,7 +182,7 @@ msgid "Blocks" msgstr "" #, elixir-format -#: lib/block_scout_web/templates/layout/app.html.eex:60 +#: lib/block_scout_web/templates/layout/app.html.eex:49 msgid "Blocks Indexed" msgstr "" @@ -389,7 +389,7 @@ msgstr "" #, elixir-format #: lib/block_scout_web/templates/address/_balance_card.html.eex:13 #: lib/block_scout_web/templates/internal_transaction/_tile.html.eex:16 -#: lib/block_scout_web/templates/layout/app.html.eex:66 +#: lib/block_scout_web/templates/layout/app.html.eex:55 #: lib/block_scout_web/templates/transaction/_pending_tile.html.eex:20 #: lib/block_scout_web/templates/transaction/_tile.html.eex:27 #: lib/block_scout_web/templates/transaction/overview.html.eex:163 @@ -472,7 +472,7 @@ msgid "IN" msgstr "" #, elixir-format -#: lib/block_scout_web/templates/layout/app.html.eex:62 +#: lib/block_scout_web/templates/layout/app.html.eex:51 msgid "Indexing Tokens" msgstr "" @@ -508,7 +508,7 @@ msgid "Inventory" msgstr "" #, elixir-format -#: lib/block_scout_web/templates/layout/app.html.eex:63 +#: lib/block_scout_web/templates/layout/app.html.eex:52 msgid "Less than" msgstr "" @@ -527,7 +527,7 @@ msgstr "" #, elixir-format #: lib/block_scout_web/templates/chain/show.html.eex:28 -#: lib/block_scout_web/templates/layout/app.html.eex:64 +#: lib/block_scout_web/templates/layout/app.html.eex:53 #: lib/block_scout_web/views/address_view.ex:121 msgid "Market Cap" msgstr "" @@ -679,7 +679,7 @@ msgstr "" #, elixir-format #: lib/block_scout_web/templates/chain/show.html.eex:21 -#: lib/block_scout_web/templates/layout/app.html.eex:65 +#: lib/block_scout_web/templates/layout/app.html.eex:54 msgid "Price" msgstr "" @@ -729,7 +729,7 @@ msgstr "" #, elixir-format #: lib/block_scout_web/templates/layout/_topnav.html.eex:89 -#: lib/block_scout_web/templates/layout/_topnav.html.eex:106 +#: lib/block_scout_web/templates/layout/_topnav.html.eex:107 msgid "Search" msgstr "" diff --git a/apps/block_scout_web/priv/gettext/en/LC_MESSAGES/default.po b/apps/block_scout_web/priv/gettext/en/LC_MESSAGES/default.po index 8a18c60018..20233767ee 100644 --- a/apps/block_scout_web/priv/gettext/en/LC_MESSAGES/default.po +++ b/apps/block_scout_web/priv/gettext/en/LC_MESSAGES/default.po @@ -62,7 +62,7 @@ msgid "(query)" msgstr "" #, elixir-format -#: lib/block_scout_web/templates/layout/app.html.eex:46 +#: lib/block_scout_web/templates/layout/app.html.eex:35 msgid "- We're indexing this chain right now. Some of the counts may be inaccurate." msgstr "" @@ -155,7 +155,7 @@ msgid "Block Height: %{height}" msgstr "" #, elixir-format -#: lib/block_scout_web/templates/layout/app.html.eex:61 +#: lib/block_scout_web/templates/layout/app.html.eex:50 msgid "Block Mined, awaiting import..." msgstr "" @@ -182,7 +182,7 @@ msgid "Blocks" msgstr "" #, elixir-format -#: lib/block_scout_web/templates/layout/app.html.eex:60 +#: lib/block_scout_web/templates/layout/app.html.eex:49 msgid "Blocks Indexed" msgstr "" @@ -389,7 +389,7 @@ msgstr "" #, elixir-format #: lib/block_scout_web/templates/address/_balance_card.html.eex:13 #: lib/block_scout_web/templates/internal_transaction/_tile.html.eex:16 -#: lib/block_scout_web/templates/layout/app.html.eex:66 +#: lib/block_scout_web/templates/layout/app.html.eex:55 #: lib/block_scout_web/templates/transaction/_pending_tile.html.eex:20 #: lib/block_scout_web/templates/transaction/_tile.html.eex:27 #: lib/block_scout_web/templates/transaction/overview.html.eex:163 @@ -472,7 +472,7 @@ msgid "IN" msgstr "" #, elixir-format -#: lib/block_scout_web/templates/layout/app.html.eex:62 +#: lib/block_scout_web/templates/layout/app.html.eex:51 msgid "Indexing Tokens" msgstr "" @@ -508,7 +508,7 @@ msgid "Inventory" msgstr "" #, elixir-format -#: lib/block_scout_web/templates/layout/app.html.eex:63 +#: lib/block_scout_web/templates/layout/app.html.eex:52 msgid "Less than" msgstr "" @@ -527,7 +527,7 @@ msgstr "" #, elixir-format #: lib/block_scout_web/templates/chain/show.html.eex:28 -#: lib/block_scout_web/templates/layout/app.html.eex:64 +#: lib/block_scout_web/templates/layout/app.html.eex:53 #: lib/block_scout_web/views/address_view.ex:121 msgid "Market Cap" msgstr "" @@ -679,7 +679,7 @@ msgstr "" #, elixir-format #: lib/block_scout_web/templates/chain/show.html.eex:21 -#: lib/block_scout_web/templates/layout/app.html.eex:65 +#: lib/block_scout_web/templates/layout/app.html.eex:54 msgid "Price" msgstr "" @@ -729,7 +729,7 @@ msgstr "" #, elixir-format #: lib/block_scout_web/templates/layout/_topnav.html.eex:89 -#: lib/block_scout_web/templates/layout/_topnav.html.eex:106 +#: lib/block_scout_web/templates/layout/_topnav.html.eex:107 msgid "Search" msgstr "" From f71ae772b507d36c221de88de8877815d69477aa Mon Sep 17 00:00:00 2001 From: Victor Baranov Date: Mon, 22 Apr 2019 12:44:16 +0300 Subject: [PATCH 4/4] Fix search field border break/overlap --- .../assets/css/components/_navbar.scss | 11 +++++++---- .../block_scout_web/templates/layout/_topnav.html.eex | 2 +- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/apps/block_scout_web/assets/css/components/_navbar.scss b/apps/block_scout_web/assets/css/components/_navbar.scss index 81038a3c95..667414d98a 100644 --- a/apps/block_scout_web/assets/css/components/_navbar.scss +++ b/apps/block_scout_web/assets/css/components/_navbar.scss @@ -20,6 +20,7 @@ form { flex-grow: 1; } + } .input-group { @@ -79,9 +80,8 @@ background: transparent; width: auto; font-size: 12px; - border-right: none; + border: none; color: $white; - border-color: transparentize($white, 0.30); padding-right: 0px; @@ -109,8 +109,7 @@ .navbar .input-group-text { background: none; - border-left: none; - border-color: transparentize($white, 0.30); + border: none; } .input-group-append { @@ -160,3 +159,7 @@ color: $white; } } + +.add-border { + border: 1px solid transparentize($white, 0.30); +} diff --git a/apps/block_scout_web/lib/block_scout_web/templates/layout/_topnav.html.eex b/apps/block_scout_web/lib/block_scout_web/templates/layout/_topnav.html.eex index c31c68ff42..f000e09111 100644 --- a/apps/block_scout_web/lib/block_scout_web/templates/layout/_topnav.html.eex +++ b/apps/block_scout_web/lib/block_scout_web/templates/layout/_topnav.html.eex @@ -78,7 +78,7 @@
- <%= form_for @conn, chain_path(@conn, :search), [class: "form-inline my-2 my-lg-0", method: :get, enforce_utf8: false], fn f -> %> + <%= form_for @conn, chain_path(@conn, :search), [class: "form-inline my-2 my-lg-0 add-border", method: :get, enforce_utf8: false], fn f -> %>
<%= awesomplete(f, :q,