Skip to content

Commit c2f14bf

Browse files
ishikawa999Redmine Patch Meetup
authored and
Redmine Patch Meetup
committed
Change .next-prev-links spanをボタン化
1 parent 8d71268 commit c2f14bf

File tree

2 files changed

+20
-11
lines changed

2 files changed

+20
-11
lines changed

app/views/issues/show.html.erb

+8-4
Original file line numberDiff line numberDiff line change
@@ -9,23 +9,27 @@
99
<div class="<%= @issue.css_classes %> details">
1010
<% if @prev_issue_id || @next_issue_id %>
1111
<div class="next-prev-links contextual">
12-
<%= link_to_if @prev_issue_id,
12+
<span class="previous">
13+
<%= link_to_if @prev_issue_id,
1314
"\xc2\xab #{l(:label_previous)}",
1415
(@prev_issue_id ? issue_path(@prev_issue_id) : nil),
1516
:title => "##{@prev_issue_id}",
16-
:accesskey => accesskey(:previous) %> |
17+
:accesskey => accesskey(:previous) %>
18+
</span>
1719
<% if @issue_position && @issue_count %>
1820
<span class="position">
1921
<%= link_to_if @query_path,
2022
l(:label_item_position, :position => @issue_position, :count => @issue_count),
2123
@query_path %>
22-
</span> |
24+
</span>
2325
<% end %>
24-
<%= link_to_if @next_issue_id,
26+
<span class="next">
27+
<%= link_to_if @next_issue_id,
2528
"#{l(:label_next)} \xc2\xbb",
2629
(@next_issue_id ? issue_path(@next_issue_id) : nil),
2730
:title => "##{@next_issue_id}",
2831
:accesskey => accesskey(:next) %>
32+
</span>
2933
</div>
3034
<% end %>
3135

public/stylesheets/application.css

+12-7
Original file line numberDiff line numberDiff line change
@@ -737,12 +737,15 @@ textarea#custom_field_default_value {width: 95%; resize:vertical}
737737
input#content_comments {width: 99%}
738738

739739
span.pagination {margin-left:3px; color:#888; display:block;}
740-
.pagination ul.pages {
740+
.pagination ul.pages, .next-prev-links {
741741
margin: 0 5px 0 0;
742742
padding: 0;
743743
display: inline;
744744
}
745-
.pagination ul.pages li {
745+
div.next-prev-links.contextual span {
746+
margin-left: -5px;
747+
}
748+
.pagination ul.pages li, .next-prev-links span {
746749
display: inline-block;
747750
padding: 0;
748751
border: 1px solid #ddd;
@@ -753,14 +756,14 @@ span.pagination {margin-left:3px; color:#888; display:block;}
753756
text-align: center;
754757
}
755758
.pagination ul.pages li a,
756-
.pagination ul.pages li span {
759+
.pagination ul.pages li span, .next-prev-links span a {
757760
padding: 3px 8px;
758761
}
759-
.pagination ul.pages li:first-child {
762+
.pagination ul.pages li:first-child, .next-prev-links span:first-child {
760763
border-top-left-radius: 4px;
761764
border-bottom-left-radius: 4px;
762765
}
763-
.pagination ul.pages li:last-child {
766+
.pagination ul.pages li:last-child, .next-prev-links span:last-child {
764767
border-top-right-radius: 4px;
765768
border-bottom-right-radius: 4px;
766769
}
@@ -769,11 +772,13 @@ span.pagination {margin-left:3px; color:#888; display:block;}
769772
background-color: #628DB6;
770773
border-color: #628DB6;
771774
}
772-
.pagination ul.pages li.page:hover {
775+
.pagination ul.pages li.page:hover, .next-prev-links span:hover {
773776
background-color: #ddd;
774777
}
775778
.pagination ul.pages li.page a:hover,
776-
.pagination ul.pages li.page a:active {
779+
.pagination ul.pages li.page a:active,
780+
.next-prev-links span a:hover,
781+
.next-prev-links span a:active{
777782
color: #169;
778783
text-decoration: inherit;
779784
}

0 commit comments

Comments
 (0)