Merge remote-tracking branch 'upstream/pull/4654'
This commit is contained in:
commit
b0c17047a1
14 changed files with 22 additions and 28 deletions
|
@ -66,12 +66,6 @@ time[title] {
|
||||||
color: $blue;
|
color: $blue;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Rules for borders */
|
|
||||||
/* These add additional colours to those provided by bootstrap */
|
|
||||||
.border-grey {
|
|
||||||
border-color: $grey !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Rules for the header */
|
/* Rules for the header */
|
||||||
|
|
||||||
#menu-icon {
|
#menu-icon {
|
||||||
|
|
|
@ -2,7 +2,7 @@ module UserHelper
|
||||||
# User images
|
# User images
|
||||||
|
|
||||||
def user_image(user, options = {})
|
def user_image(user, options = {})
|
||||||
options[:class] ||= "user_image border border-grey"
|
options[:class] ||= "user_image border border-secondary-subtle"
|
||||||
options[:alt] ||= ""
|
options[:alt] ||= ""
|
||||||
|
|
||||||
if user.image_use_gravatar
|
if user.image_use_gravatar
|
||||||
|
@ -15,7 +15,7 @@ module UserHelper
|
||||||
end
|
end
|
||||||
|
|
||||||
def user_thumbnail(user, options = {})
|
def user_thumbnail(user, options = {})
|
||||||
options[:class] ||= "user_thumbnail border border-grey"
|
options[:class] ||= "user_thumbnail border border-secondary-subtle"
|
||||||
options[:alt] ||= ""
|
options[:alt] ||= ""
|
||||||
|
|
||||||
if user.image_use_gravatar
|
if user.image_use_gravatar
|
||||||
|
@ -28,7 +28,7 @@ module UserHelper
|
||||||
end
|
end
|
||||||
|
|
||||||
def user_thumbnail_tiny(user, options = {})
|
def user_thumbnail_tiny(user, options = {})
|
||||||
options[:class] ||= "user_thumbnail_tiny border border-grey"
|
options[:class] ||= "user_thumbnail_tiny border border-secondary-subtle"
|
||||||
options[:alt] ||= ""
|
options[:alt] ||= ""
|
||||||
|
|
||||||
if user.image_use_gravatar
|
if user.image_use_gravatar
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
<tr>
|
<tr>
|
||||||
<th class='py-1 border-grey table-light fw-normal' dir='auto'><%= format_key(tag[0]) %></th>
|
<th class='py-1 border-secondary-subtle table-light fw-normal' dir='auto'><%= format_key(tag[0]) %></th>
|
||||||
<td class='py-1 border-grey border-start' dir='auto'><%= format_value(tag[0], tag[1]) %></td>
|
<td class='py-1 border-secondary-subtle border-start' dir='auto'><%= format_value(tag[0], tag[1]) %></td>
|
||||||
</tr>
|
</tr>
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<% unless tag_details.empty? %>
|
<% unless tag_details.empty? %>
|
||||||
<h4><%= t ".tags" %></h4>
|
<h4><%= t ".tags" %></h4>
|
||||||
<div class='mb-3 border border-grey rounded overflow-hidden'>
|
<div class='mb-3 border border-secondary-subtle rounded overflow-hidden'>
|
||||||
<table class='mb-0 browse-tag-list table align-middle text-break'>
|
<table class='mb-0 browse-tag-list table align-middle text-break'>
|
||||||
<%= render :partial => "browse/tag", :collection => tag_details.sort %>
|
<%= render :partial => "browse/tag", :collection => tag_details.sort %>
|
||||||
</table>
|
</table>
|
||||||
|
|
|
@ -6,7 +6,7 @@
|
||||||
<% if current_user and @user.id == current_user.id %>
|
<% if current_user and @user.id == current_user.id %>
|
||||||
<div class="col-md order-md-last">
|
<div class="col-md order-md-last">
|
||||||
<% if !@user.home_location? %>
|
<% if !@user.home_location? %>
|
||||||
<div id="map" class="content_map border border-grey">
|
<div id="map" class="content_map border border-secondary-subtle">
|
||||||
<p class="m-3"><%= t(".no_home_location_html", :edit_profile_link => link_to(t(".edit_your_profile"), edit_profile_path)) %></p>
|
<p class="m-3"><%= t(".no_home_location_html", :edit_profile_link => link_to(t(".edit_your_profile"), edit_profile_path)) %></p>
|
||||||
</div>
|
</div>
|
||||||
<% else %>
|
<% else %>
|
||||||
|
@ -19,7 +19,7 @@
|
||||||
:icon => image_path("marker-red.png"),
|
:icon => image_path("marker-red.png"),
|
||||||
:description => render(:partial => "popup", :object => current_user, :locals => { :type => "your location" })
|
:description => render(:partial => "popup", :object => current_user, :locals => { :type => "your location" })
|
||||||
} %>
|
} %>
|
||||||
<%= tag.div "", :id => "map", :class => "content_map border border-grey rounded", :data => { :user => user_data } %>
|
<%= tag.div "", :id => "map", :class => "content_map border border-secondary-subtle rounded", :data => { :user => user_data } %>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
<% friends = @user.friends %>
|
<% friends = @user.friends %>
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
<article class='diary_post border-top border-grey py-3<%= " text-muted px-3 bg-danger bg-opacity-10" unless diary_entry.visible %> user_<%= diary_entry.user.id %>'>
|
<article class='diary_post border-top border-secondary-subtle py-3<%= " text-muted px-3 bg-danger bg-opacity-10" unless diary_entry.visible %> user_<%= diary_entry.user.id %>'>
|
||||||
<%= render :partial => "diary_entry_heading", :object => diary_entry, :as => "diary_entry" %>
|
<%= render :partial => "diary_entry_heading", :object => diary_entry, :as => "diary_entry" %>
|
||||||
|
|
||||||
<div class="richtext text-break" xml:lang="<%= diary_entry.language_code %>" lang="<%= diary_entry.language_code %>">
|
<div class="richtext text-break" xml:lang="<%= diary_entry.language_code %>" lang="<%= diary_entry.language_code %>">
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
<fieldset>
|
<fieldset>
|
||||||
<legend><%= t ".location" -%></legend>
|
<legend><%= t ".location" -%></legend>
|
||||||
|
|
||||||
<%= tag.div "", :id => "map", :class => "border border-grey rounded mb-3", :data => { :lat => @lat, :lon => @lon, :zoom => @zoom } %>
|
<%= tag.div "", :id => "map", :class => "border border-secondary-subtle rounded mb-3", :data => { :lat => @lat, :lon => @lon, :zoom => @zoom } %>
|
||||||
|
|
||||||
<div class="row mb-3">
|
<div class="row mb-3">
|
||||||
<%= f.text_field :latitude, :wrapper_class => "col-sm-4 d-flex flex-column", :class => "mt-auto", :id => "latitude" %>
|
<%= f.text_field :latitude, :wrapper_class => "col-sm-4 d-flex flex-column", :class => "mt-auto", :id => "latitude" %>
|
||||||
|
|
|
@ -13,7 +13,7 @@
|
||||||
<%= render @entry %>
|
<%= render @entry %>
|
||||||
|
|
||||||
<div id="comments" class="comments mb-3 overflow-hidden">
|
<div id="comments" class="comments mb-3 overflow-hidden">
|
||||||
<div class="row border-bottom border-grey">
|
<div class="row border-bottom border-secondary-subtle">
|
||||||
<h2 class="col"><%= t(".discussion") %></h2>
|
<h2 class="col"><%= t(".discussion") %></h2>
|
||||||
|
|
||||||
<% if current_user %>
|
<% if current_user %>
|
||||||
|
|
|
@ -81,7 +81,7 @@
|
||||||
</ul>
|
</ul>
|
||||||
<% if current_user && current_user.id %>
|
<% if current_user && current_user.id %>
|
||||||
<div class='d-inline-flex dropdown user-menu logged-in'>
|
<div class='d-inline-flex dropdown user-menu logged-in'>
|
||||||
<button class='dropdown-toggle btn btn-outline-secondary border-grey bg-white text-secondary px-2 py-1 flex-grow-1' type='button' data-bs-toggle='dropdown'>
|
<button class='dropdown-toggle btn btn-outline-secondary border-secondary-subtle bg-white text-secondary px-2 py-1 flex-grow-1' type='button' data-bs-toggle='dropdown'>
|
||||||
<%= user_thumbnail_tiny(current_user, :width => 25, :height => 25, :class => "user_thumbnail_tiny rounded-1") %>
|
<%= user_thumbnail_tiny(current_user, :width => 25, :height => 25, :class => "user_thumbnail_tiny rounded-1") %>
|
||||||
<%= render :partial => "layouts/inbox" %>
|
<%= render :partial => "layouts/inbox" %>
|
||||||
<span class="user-button">
|
<span class="user-button">
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
<h1><%= @message.title %></h1>
|
<h1><%= @message.title %></h1>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
<div class='mb-3 border-bottom border-grey py-1 d-flex gap-1 flex-wrap'>
|
<div class='mb-3 border-bottom border-secondary-subtle py-1 d-flex gap-1 flex-wrap'>
|
||||||
<% if current_user == @message.recipient %>
|
<% if current_user == @message.recipient %>
|
||||||
<%= user_thumbnail_tiny @message.sender %>
|
<%= user_thumbnail_tiny @message.sender %>
|
||||||
<%= link_to @message.sender.display_name, @message.sender %>
|
<%= link_to @message.sender.display_name, @message.sender %>
|
||||||
|
|
|
@ -56,7 +56,7 @@
|
||||||
<input class="form-check-input" type="checkbox" name="updatehome" value="1" <% unless current_user.home_location? %> checked <% end %> id="updatehome" />
|
<input class="form-check-input" type="checkbox" name="updatehome" value="1" <% unless current_user.home_location? %> checked <% end %> id="updatehome" />
|
||||||
<label class="form-check-label" for="updatehome"><%= t ".update home location on click" %></label>
|
<label class="form-check-label" for="updatehome"><%= t ".update home location on click" %></label>
|
||||||
</div>
|
</div>
|
||||||
<%= tag.div "", :id => "map", :class => "content_map set_location border border-grey rounded" %>
|
<%= tag.div "", :id => "map", :class => "content_map set_location border border-secondary-subtle rounded" %>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
|
|
||||||
<%= f.primary t(".save") %>
|
<%= f.primary t(".save") %>
|
||||||
|
|
|
@ -6,7 +6,7 @@
|
||||||
<%= hidden_field_tag "format", "osm", :autocomplete => "off" %>
|
<%= hidden_field_tag "format", "osm", :autocomplete => "off" %>
|
||||||
|
|
||||||
<div class='export_area_inputs'>
|
<div class='export_area_inputs'>
|
||||||
<div class='export_boxy border border-grey rounded'>
|
<div class='export_boxy border border-secondary-subtle rounded'>
|
||||||
<%= text_field_tag("maxlat", nil, :size => 10, :autocomplete => "off", :class => "export_bound form-control mx-auto") %>
|
<%= text_field_tag("maxlat", nil, :size => 10, :autocomplete => "off", :class => "export_bound form-control mx-auto") %>
|
||||||
<div class="clearfix">
|
<div class="clearfix">
|
||||||
<%= text_field_tag("minlon", nil, :size => 10, :autocomplete => "off", :class => "export_bound form-control my-2") %>
|
<%= text_field_tag("minlon", nil, :size => 10, :autocomplete => "off", :class => "export_bound form-control my-2") %>
|
||||||
|
|
|
@ -30,7 +30,7 @@
|
||||||
<% end %>
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div id="contributorTerms" class="legale border border-grey rounded">
|
<div id="contributorTerms" class="legale border border-secondary-subtle rounded">
|
||||||
<%= render :partial => "terms" %>
|
<%= render :partial => "terms" %>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
|
@ -8,12 +8,12 @@ class UserHelperTest < ActionView::TestCase
|
||||||
gravatar_user = create(:user, :image_use_gravatar => true)
|
gravatar_user = create(:user, :image_use_gravatar => true)
|
||||||
|
|
||||||
image = user_image(user)
|
image = user_image(user)
|
||||||
assert_match %r{^<img class="user_image border border-grey" .* src="/images/avatar_large.png" />$}, image
|
assert_match %r{^<img class="user_image border border-secondary-subtle" .* src="/images/avatar_large.png" />$}, image
|
||||||
|
|
||||||
image = user_image(user, :class => "foo")
|
image = user_image(user, :class => "foo")
|
||||||
assert_match %r{^<img class="foo" .* src="/images/avatar_large.png" />$}, image
|
assert_match %r{^<img class="foo" .* src="/images/avatar_large.png" />$}, image
|
||||||
image = user_image(gravatar_user)
|
image = user_image(gravatar_user)
|
||||||
assert_match %r{^<img class="user_image border border-grey" .* src="http://www.gravatar.com/avatar/.*" />$}, image
|
assert_match %r{^<img class="user_image border border-secondary-subtle" .* src="http://www.gravatar.com/avatar/.*" />$}, image
|
||||||
|
|
||||||
image = user_image(gravatar_user, :class => "foo")
|
image = user_image(gravatar_user, :class => "foo")
|
||||||
assert_match %r{^<img class="foo" .* src="http://www.gravatar.com/avatar/.*" />$}, image
|
assert_match %r{^<img class="foo" .* src="http://www.gravatar.com/avatar/.*" />$}, image
|
||||||
|
@ -24,13 +24,13 @@ class UserHelperTest < ActionView::TestCase
|
||||||
gravatar_user = create(:user, :image_use_gravatar => true)
|
gravatar_user = create(:user, :image_use_gravatar => true)
|
||||||
|
|
||||||
image = user_thumbnail(user)
|
image = user_thumbnail(user)
|
||||||
assert_match %r{^<img class="user_thumbnail border border-grey" .* src="/images/avatar_small.png" />$}, image
|
assert_match %r{^<img class="user_thumbnail border border-secondary-subtle" .* src="/images/avatar_small.png" />$}, image
|
||||||
|
|
||||||
image = user_thumbnail(user, :class => "foo")
|
image = user_thumbnail(user, :class => "foo")
|
||||||
assert_match %r{^<img class="foo" .* src="/images/avatar_small.png" />$}, image
|
assert_match %r{^<img class="foo" .* src="/images/avatar_small.png" />$}, image
|
||||||
|
|
||||||
image = user_thumbnail(gravatar_user)
|
image = user_thumbnail(gravatar_user)
|
||||||
assert_match %r{^<img class="user_thumbnail border border-grey" .* src="http://www.gravatar.com/avatar/.*" />$}, image
|
assert_match %r{^<img class="user_thumbnail border border-secondary-subtle" .* src="http://www.gravatar.com/avatar/.*" />$}, image
|
||||||
|
|
||||||
image = user_thumbnail(gravatar_user, :class => "foo")
|
image = user_thumbnail(gravatar_user, :class => "foo")
|
||||||
assert_match %r{^<img class="foo" .* src="http://www.gravatar.com/avatar/.*" />$}, image
|
assert_match %r{^<img class="foo" .* src="http://www.gravatar.com/avatar/.*" />$}, image
|
||||||
|
@ -41,13 +41,13 @@ class UserHelperTest < ActionView::TestCase
|
||||||
gravatar_user = create(:user, :image_use_gravatar => true)
|
gravatar_user = create(:user, :image_use_gravatar => true)
|
||||||
|
|
||||||
image = user_thumbnail_tiny(user)
|
image = user_thumbnail_tiny(user)
|
||||||
assert_match %r{^<img class="user_thumbnail_tiny border border-grey" .* src="/images/avatar_small.png" />$}, image
|
assert_match %r{^<img class="user_thumbnail_tiny border border-secondary-subtle" .* src="/images/avatar_small.png" />$}, image
|
||||||
|
|
||||||
image = user_thumbnail_tiny(user, :class => "foo")
|
image = user_thumbnail_tiny(user, :class => "foo")
|
||||||
assert_match %r{^<img class="foo" .* src="/images/avatar_small.png" />$}, image
|
assert_match %r{^<img class="foo" .* src="/images/avatar_small.png" />$}, image
|
||||||
|
|
||||||
image = user_thumbnail_tiny(gravatar_user)
|
image = user_thumbnail_tiny(gravatar_user)
|
||||||
assert_match %r{^<img class="user_thumbnail_tiny border border-grey" .* src="http://www.gravatar.com/avatar/.*" />$}, image
|
assert_match %r{^<img class="user_thumbnail_tiny border border-secondary-subtle" .* src="http://www.gravatar.com/avatar/.*" />$}, image
|
||||||
|
|
||||||
image = user_thumbnail_tiny(gravatar_user, :class => "foo")
|
image = user_thumbnail_tiny(gravatar_user, :class => "foo")
|
||||||
assert_match %r{^<img class="foo" .* src="http://www.gravatar.com/avatar/.*" />$}, image
|
assert_match %r{^<img class="foo" .* src="http://www.gravatar.com/avatar/.*" />$}, image
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue