Replaces icons of expand/collapse comments
This commit is contained in:
@@ -40,13 +40,7 @@
|
||||
$("#js-comment-form-" + id).toggle();
|
||||
},
|
||||
toggle_arrow: function(id) {
|
||||
var arrow;
|
||||
arrow = "span#" + id + "_arrow";
|
||||
if ($(arrow).hasClass("icon-arrow-right")) {
|
||||
$(arrow).removeClass("icon-arrow-right").addClass("icon-arrow-down");
|
||||
} else {
|
||||
$(arrow).removeClass("icon-arrow-down").addClass("icon-arrow-right");
|
||||
}
|
||||
$("span#" + id + "_arrow").toggleClass("fa-minus-square").toggleClass("fa-plus-square");
|
||||
},
|
||||
initialize: function() {
|
||||
$("body .js-add-comment-link").each(function() {
|
||||
|
||||
@@ -203,10 +203,6 @@
|
||||
content: "\f00b";
|
||||
}
|
||||
|
||||
.icon-arrow-down::before {
|
||||
content: "\f0dd";
|
||||
}
|
||||
|
||||
.icon-arrow-left::before {
|
||||
content: "\f0d9";
|
||||
}
|
||||
|
||||
@@ -2116,17 +2116,16 @@ table {
|
||||
padding: $line-height / 4;
|
||||
position: relative;
|
||||
|
||||
.relative,
|
||||
[class^="icon-arrow"] {
|
||||
padding-left: $line-height / 2;
|
||||
.relative {
|
||||
padding-left: rem-calc(18);
|
||||
}
|
||||
|
||||
[class^="icon-arrow"] {
|
||||
font-size: $base-font-size;
|
||||
left: -20px;
|
||||
.far {
|
||||
font-size: $small-font-size;
|
||||
left: 0;
|
||||
position: absolute;
|
||||
text-decoration: none;
|
||||
top: -1px;
|
||||
top: 2px;
|
||||
}
|
||||
|
||||
.divider {
|
||||
|
||||
@@ -94,7 +94,7 @@
|
||||
<%= link_to "", class: "js-toggle-children relative", data: { "id": "#{dom_id(comment)}" } do %>
|
||||
<span class="show-for-sr js-child-toggle" style="display: none;"><%= t("shared.show") %></span>
|
||||
<span class="show-for-sr js-child-toggle"><%= t("shared.hide") %></span>
|
||||
<span id="<%= dom_id(comment) %>_children_arrow" class="icon-arrow-down"></span>
|
||||
<span id="<%= dom_id(comment) %>_children_arrow" class="far fa-minus-square"></span>
|
||||
<span class="js-child-toggle" style="display: none;"><%= t("comments.comment.responses_show", count: comment.children.size) %></span>
|
||||
<span class="js-child-toggle"><%= t("comments.comment.responses_collapse", count: comment.children.size) %></span>
|
||||
<% end %>
|
||||
|
||||
Reference in New Issue
Block a user