Commit 05e8404b authored by Phil Hughes's avatar Phil Hughes

Fixed issue with dragging opening the issue sidebar

Added indicator when issue detail is visible
parent 6b3e3aeb
......@@ -12,6 +12,21 @@
disabled: Boolean,
index: Number
},
data () {
return {
showDetail: false,
detailIssue: Store.detail
};
},
computed: {
issueDetailVisible () {
if (this.detailIssue.issue && this.detailIssue.issue.id === this.issue.id) {
return true;
} else {
return false;
}
}
},
methods: {
filterByLabel (label, e) {
let labelToggleText = label.title;
......@@ -38,8 +53,19 @@
Store.updateFiltersUrl();
},
mouseDown () {
this.showDetail = true;
},
mouseMove () {
if (this.showDetail) {
this.showDetail = false;
}
},
showIssue () {
Store.detail.issue = this.issue;
if (this.showDetail) {
this.showDetail = false;
Vue.set(Store.detail, 'issue', this.issue);
}
}
}
});
......
......@@ -194,6 +194,10 @@ lex
margin-bottom: 5px;
}
&.is-active {
background-color: $row-hover;
}
.label {
border: 0;
outline: 0;
......
......@@ -7,9 +7,11 @@
":issue-link-base" => "issueLinkBase",
":disabled" => "disabled",
"track-by" => "id" }
%li.card{ ":class" => "{ 'user-can-drag': !disabled && issue.id, 'is-disabled': disabled || !issue.id }",
%li.card{ ":class" => "{ 'user-can-drag': !disabled && issue.id, 'is-disabled': disabled || !issue.id, 'is-active': issueDetailVisible }",
":index" => "index",
"@click" => "showIssue" }
"@mousedown" => "mouseDown",
"@mouseMove" => "mouseMove",
"@mouseup" => "showIssue" }
%h4.card-title
= icon("eye-slash", class: "confidential-icon", "v-if" => "issue.confidential")
%a{ ":href" => "issueLinkBase + '/' + issue.id",
......
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