Adds modified date to snippets#show #1767

- Fixed a bug with .btn-sm padding.
 - Changed created_at to modified_at for snippets#index as it seems to
   be more relevant.
This commit is contained in:
Han Loong Liauw 2015-10-12 18:38:34 +11:00
parent 42603af326
commit 857cc388e1
4 changed files with 14 additions and 4 deletions

View file

@ -45,6 +45,7 @@ v 8.1.0 (unreleased)
- Fix position of hamburger in header for smaller screens (Han Loong Liauw) - Fix position of hamburger in header for smaller screens (Han Loong Liauw)
- Fix bug where Emojis in Markdown would truncate remaining text (Sakata Sinji) - Fix bug where Emojis in Markdown would truncate remaining text (Sakata Sinji)
- Persist filters when sorting on admin user page (Jerry Lukins) - Persist filters when sorting on admin user page (Jerry Lukins)
- Added last modified date to snippets#show (Han Loong Liauw)
v 8.0.4 v 8.0.4
- Fix Message-ID header to be RFC 2111-compliant to prevent e-mails being dropped (Stan Hu) - Fix Message-ID header to be RFC 2111-compliant to prevent e-mails being dropped (Stan Hu)

View file

@ -22,6 +22,12 @@
padding: 11px 24px; padding: 11px 24px;
} }
@mixin btn-sm {
@include btn-default;
@include border-radius(2px);
padding: 5px 10px;
}
@mixin btn-color($light, $border-light, $normal, $border-normal, $dark, $border-dark, $color) { @mixin btn-color($light, $border-light, $normal, $border-normal, $dark, $border-dark, $color) {
background-color: $light; background-color: $light;
border-color: $border-light; border-color: $border-light;
@ -71,6 +77,10 @@
@include btn-default; @include btn-default;
@include btn-white; @include btn-white;
&.btn-sm {
@include btn-sm;
}
&.btn-success, &.btn-success,
&.btn-new, &.btn-new,
&.btn-create, &.btn-create,

View file

@ -17,5 +17,4 @@
= link_to user_snippets_path(snippet.author) do = link_to user_snippets_path(snippet.author) do
= image_tag avatar_icon(snippet.author_email), class: "avatar s24", alt: '' = image_tag avatar_icon(snippet.author_email), class: "avatar s24", alt: ''
= snippet.author_name = snippet.author_name
authored #{time_ago_with_tooltip(snippet.created_at)} authored #{time_ago_with_tooltip(snippet.updated_at)}

View file

@ -11,12 +11,12 @@
= link_to new_snippet_path, class: "btn btn-new btn-sm", title: "New Snippet" do = link_to new_snippet_path, class: "btn btn-new btn-sm", title: "New Snippet" do
Add new snippet Add new snippet
.append-bottom-10.prepend-top-10 .append-bottom-10.prepend-top-10.clearfix
.pull-right .pull-right
%span.light %span.light
created by
= link_to user_snippets_path(@snippet.author) do = link_to user_snippets_path(@snippet.author) do
= @snippet.author_name = @snippet.author_name
authored #{time_ago_with_tooltip(@snippet.updated_at)}
.back-link .back-link
- if @snippet.author == current_user - if @snippet.author == current_user