Skip to content
Snippets Groups Projects
Commit a9bcb5b8 authored by Phil Hughes's avatar Phil Hughes
Browse files

Fixed eslint errors

parent 7512af29
No related branches found
No related tags found
No related merge requests found
Loading
Loading
@@ -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;
Loading
Loading
@@ -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');
Loading
Loading
@@ -40,7 +43,7 @@ describe('Issue card', () => {
index: 0,
rootPath: '/',
},
}).$mount();;
}).$mount();
done();
}, 0);
});
Loading
Loading
@@ -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);
};
Loading
Loading
@@ -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({});
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment