BigW Consortium Gitlab

Resolve feedback.

parent 15950477
...@@ -149,6 +149,11 @@ ...@@ -149,6 +149,11 @@
if (activeTab === 'notes') { if (activeTab === 'notes') {
$target = $target.closest('.note-discussion'); $target = $target.closest('.note-discussion');
// If the next discussion is closed, toggle it open.
if ($target.find('.js-toggle-content').is(':hidden')) {
$target.find('.js-toggle-button i').trigger('click')
}
} else if (activeTab === 'diffs') { } else if (activeTab === 'diffs') {
// Resolved discussions are hidden in the diffs tab by default. // Resolved discussions are hidden in the diffs tab by default.
// If they are marked unresolved on the notes tab, they will still be hidden on the diffs tab. // If they are marked unresolved on the notes tab, they will still be hidden on the diffs tab.
...@@ -176,12 +181,6 @@ ...@@ -176,12 +181,6 @@
$.scrollTo($target, { $.scrollTo($target, {
offset: -($('.navbar-gitlab').outerHeight() + $('.layout-nav').outerHeight()) offset: -($('.navbar-gitlab').outerHeight() + $('.layout-nav').outerHeight())
}); });
// If the next discussion is closed, toggle it open.
if ($target.find(".js-toggle-content").attr('style') == "display: none;") {
$target.find('.js-toggle-button i').toggleClass('fa fa-chevron-down').toggleClass('fa fa-chevron-up');
$target.find(".js-toggle-content").toggle();
}
} }
} }
}); });
......
- discussion = local_assigns.fetch(:discussion, nil) - discussion = local_assigns.fetch(:discussion, nil)
- if current_user - if current_user
%jump-to-discussion{ "inline-template" => true, ":discussion-id" => "'#{discussion.try(:id)}'" } %jump-to-discussion{ "inline-template" => true, ":discussion-id" => "'#{discussion.try(:id)}'" }
.btn-group{ role: "group", .btn-group{ role: "group", "v-show" => "!allResolved", "v-if" => "showButton" }
"v-show" => "!allResolved",
"v-if" => "showButton" }
%button.btn.btn-default.discussion-next-btn.has-tooltip{ "@click" => "jumpToNextUnresolvedDiscussion", %button.btn.btn-default.discussion-next-btn.has-tooltip{ "@click" => "jumpToNextUnresolvedDiscussion",
title: "Jump to next unresolved discussion", title: "Jump to next unresolved discussion",
"aria-label" => "Jump to next unresolved discussion", "aria-label" => "Jump to next unresolved discussion",
......
...@@ -652,6 +652,16 @@ ActiveRecord::Schema.define(version: 20160810142633) do ...@@ -652,6 +652,16 @@ ActiveRecord::Schema.define(version: 20160810142633) do
add_index "namespaces", ["path"], name: "index_namespaces_on_path_trigram", using: :gin, opclasses: {"path"=>"gin_trgm_ops"} add_index "namespaces", ["path"], name: "index_namespaces_on_path_trigram", using: :gin, opclasses: {"path"=>"gin_trgm_ops"}
add_index "namespaces", ["type"], name: "index_namespaces_on_type", using: :btree add_index "namespaces", ["type"], name: "index_namespaces_on_type", using: :btree
create_table "note_templates", force: :cascade do |t|
t.integer "user_id"
t.string "title"
t.text "note"
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
end
add_index "note_templates", ["user_id"], name: "index_note_templates_on_user_id", using: :btree
create_table "notes", force: :cascade do |t| create_table "notes", force: :cascade do |t|
t.text "note" t.text "note"
t.string "noteable_type" t.string "noteable_type"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment