Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 7 additions & 5 deletions app/views/hooks/_view_account_login_bottom.html.erb
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
<%= stylesheet_link_tag 'buttons', :plugin => 'redmine_omniauth_google' %>

<% if Setting.plugin_redmine_omniauth_google[:oauth_authentification] %>
<%= link_to oauth_google_path(:back_url => back_url) do %>
<%= button_tag :class => 'button-login' do %>
<%= image_tag('/plugin_assets/redmine_omniauth_google/images/google_login_icon.png', :class => 'button-login-icon', :alt => l(:login_via_google)) %>
<%= content_tag :div, l(:login_via_google), :class => 'button-login-text' %>
<% end %>
<%= content_tag :div, :class => 'container-link-google' do %>
<%= link_to oauth_google_path(:back_url => back_url) do %>
<%= button_tag :class => 'button-login' do %>
<span class="icon"></span>
<%= content_tag :span, l(:login_via_google), :class => 'button-text' %>
<% end %>
<% end %>
<% end %>
<% end %>
43 changes: 43 additions & 0 deletions assets/images/btn_google_light_normal_ios.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed assets/images/google_login_icon.png
Binary file not shown.
58 changes: 42 additions & 16 deletions assets/stylesheets/buttons.css
Original file line number Diff line number Diff line change
@@ -1,23 +1,49 @@
.container-link-google{
width: 100%;
display: flex;
justify-content: center;
}
.button-login {
position: relative;
left: 45%;
margin: 0 auto;
display: inline-block;
border: 1px solid #999;
border-radius: 2px;
margin-top: 10px;
width: 135px;
height: 25px;
padding: 0;
background: white;
color: #444;
width: 250px;
border-radius: 5px;
border: thin solid #888;
box-shadow: none;
padding-left: 8px;
padding-right: 8px;
text-align: left;
}

.button-login-icon {
float: left;
height: 18px;
padding: 1px 0px 0px 4px;
.button-login:hover,
.button-login:active,
.button-login:focus-within,
.button-login:focus {
cursor: pointer;
background-color: white;
color: #000000;
border: thin solid #888;
box-shadow: 1px 1px 1px grey;
}

.button-login-text {
line-height: 21px;
background-image: -webkit-linear-gradient(bottom, #ddd, white);
font-size: 12px;

.button-login span.label {
font-family: serif;
font-weight: normal;
}
.button-login span.icon {
background: url('../images/btn_google_light_normal_ios.svg') transparent 50% no-repeat;
display: inline-block;
vertical-align: middle;
width: 25px;
height: 25px;
margin-right: 10px;
}
.button-login span.button-text {
display: inline-block;
vertical-align: middle;
font-size: 14px;
font-weight: bold;
}