Commit a9bcb5b8 authored by Phil Hughes's avatar Phil Hughes

Fixed eslint errors

parent 7512af29
......@@ -31,25 +31,25 @@ module.exports = {
index: Number,
rootPath: String,
},
data () {
data() {
return {
showDetail: false,
detailIssue: Store.detail
detailIssue: Store.detail,
};
},
computed: {
issueDetailVisible () {
issueDetailVisible() {
return this.detailIssue.issue && this.detailIssue.issue.id === this.issue.id;
}
},
},
methods: {
mouseDown () {
mouseDown() {
this.showDetail = true;
},
mouseMove() {
this.showDetail = false;
},
showIssue (e) {
showIssue(e) {
const targetTagName = e.target.tagName.toLowerCase();
if (targetTagName === 'a' || targetTagName === 'button') return;
......@@ -64,6 +64,6 @@ module.exports = {
Store.detail.list = this.list;
}
}
}
}
},
},
};
/* global Vue */
/* global List */
/* global ListLabel */
/* global listObj */
/* global boardsMockInterceptor */
/* global BoardService */
require('~/boards/models/list');
require('~/boards/models/label');
......@@ -40,7 +43,7 @@ describe('Issue card', () => {
index: 0,
rootPath: '/',
},
}).$mount();;
}).$mount();
done();
}, 0);
});
......@@ -88,7 +91,8 @@ describe('Issue card', () => {
describe('mouse events', () => {
const triggerEvent = (eventName, el = vm.$el) => {
const event = document.createEvent('MouseEvents');
event.initMouseEvent(eventName, true, true, window, 1, 0, 0, 0, 0, false, false, false, false, 0, null);
event.initMouseEvent(eventName, true, true, window, 1, 0, 0, 0, 0, false, false,
false, false, 0, null);
el.dispatchEvent(event);
};
......@@ -125,7 +129,7 @@ describe('Issue card', () => {
expect(gl.issueBoards.BoardsStore.detail.issue).toEqual({});
});
it('does not set detail issue if showDetail is false', () => {
it('does not set detail issue if showDetail is false after mouseup', () => {
triggerEvent('mouseup');
expect(gl.issueBoards.BoardsStore.detail.issue).toEqual({});
......
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