From 27cbd4e1b106c79b78dafb65594daa7a5412c7df Mon Sep 17 00:00:00 2001 From: Simon Date: Tue, 24 Apr 2018 20:21:28 +0200 Subject: [PATCH] Various admin style fixes (#937) - remove clipboard icons #867 - cards overflow and breakword #929 - deposit details ui #928 --- app/assets/stylesheets/admin.scss | 8 ++++++++ app/helpers/application_helper.rb | 2 +- app/views/admin/deposits/fiats/show.html.erb | 12 ++++++------ app/views/admin/withdraws/fiats/show.html.erb | 12 +++--------- app/views/shared/admin/_account.html.erb | 2 +- 5 files changed, 19 insertions(+), 17 deletions(-) diff --git a/app/assets/stylesheets/admin.scss b/app/assets/stylesheets/admin.scss index ec6ec63d1e..a17021a7d7 100644 --- a/app/assets/stylesheets/admin.scss +++ b/app/assets/stylesheets/admin.scss @@ -27,6 +27,14 @@ flex-direction: row-reverse; text-align: right; font-weight: bold; + max-width: 30%; + } + dd { + margin-bottom: 0; + span { + width: 100%; + word-wrap: break-word; + } } } diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index 068d438b9e..81a0b54164 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -175,7 +175,7 @@ def language_path(lang=nil) end def description_for(name, &block) - content_tag :div, class: "dl-#{name} dl-horizontal" do + content_tag :dl, class: "dl-#{name} dl-horizontal" do capture(&block) end end diff --git a/app/views/admin/deposits/fiats/show.html.erb b/app/views/admin/deposits/fiats/show.html.erb index 78d113e5b9..e0a2d987f3 100644 --- a/app/views/admin/deposits/fiats/show.html.erb +++ b/app/views/admin/deposits/fiats/show.html.erb @@ -1,16 +1,16 @@
-
+

Deposit details

<%= description_for :member do %> - ID: <%= @deposit.sn %>
- Member: <%= @deposit.member.email %>
- Amount: <%= number_with_precision(@deposit.amount, precision: 2) %>
- Created at: <%= t(@deposit.created_at, format: :long) %>
- State: <%= @deposit.aasm_state_text %> +
ID
<%= @deposit.sn %>
+
Member
<%= @deposit.member.email %>
+
Amount
<%= number_with_precision(@deposit.amount, precision: 2) %>
+
Created at
<%= t(@deposit.created_at, format: :long) %>
+
State
<%= @deposit.aasm_state_text %>
<% end %>
<% if @deposit.may_accept? %> diff --git a/app/views/admin/withdraws/fiats/show.html.erb b/app/views/admin/withdraws/fiats/show.html.erb index 53a433341a..1e719bedfc 100644 --- a/app/views/admin/withdraws/fiats/show.html.erb +++ b/app/views/admin/withdraws/fiats/show.html.erb @@ -12,19 +12,13 @@ <%= item_for @withdraw, :aasm_state_text %>
<%= item_for @withdraw.member, :email do %> - - <%= @withdraw.member.email %> - + <%= @withdraw.member.email %> <% end %> <%= item_for @withdraw, 'Recipient ID' do %> - - <%= @withdraw.rid %> - + <%= @withdraw.rid %> <% end %> <%= item_for @withdraw, :amount do %> - - <%= @withdraw.amount %> - + <%= @withdraw.amount %> <% end %>
    <% if @withdraw.may_accept? || @withdraw.may_process? || @withdraw.may_success? %> diff --git a/app/views/shared/admin/_account.html.erb b/app/views/shared/admin/_account.html.erb index 6e387bad6a..031df9ffcb 100644 --- a/app/views/shared/admin/_account.html.erb +++ b/app/views/shared/admin/_account.html.erb @@ -5,7 +5,7 @@ <%= account.currency.code.upcase %>
-
+
<%= item_for account, :amount %> <%= item_for account, :locked %> <%= item_for account, :balance %>