Commit 95cd4799 authored by Tim Zallmann's avatar Tim Zallmann

Fixed UserPopover Conflicts

parent 42e00f75
...@@ -31,12 +31,9 @@ import initPerformanceBar from './performance_bar'; ...@@ -31,12 +31,9 @@ import initPerformanceBar from './performance_bar';
import initSearchAutocomplete from './search_autocomplete'; import initSearchAutocomplete from './search_autocomplete';
import GlFieldErrors from './gl_field_errors'; import GlFieldErrors from './gl_field_errors';
import initUserPopovers from './user_popovers'; import initUserPopovers from './user_popovers';
<<<<<<< HEAD
// EE-only scripts // EE-only scripts
import 'ee/main'; import 'ee/main';
=======
>>>>>>> upstream/master
// expose jQuery as global (TODO: remove these) // expose jQuery as global (TODO: remove these)
window.jQuery = jQuery; window.jQuery = jQuery;
......
...@@ -81,10 +81,7 @@ export default { ...@@ -81,10 +81,7 @@ export default {
:data-user-id="author.id" :data-user-id="author.id"
:data-username="author.username" :data-username="author.username"
> >
<<<<<<< HEAD
<slot name="note-header-info"></slot> <slot name="note-header-info"></slot>
=======
>>>>>>> upstream/master
<span class="note-header-author-name">{{ author.name }}</span> <span class="note-header-author-name">{{ author.name }}</span>
<span v-if="author.status_tooltip_html" v-html="author.status_tooltip_html"></span> <span v-if="author.status_tooltip_html" v-html="author.status_tooltip_html"></span>
<span class="note-headline-light">@{{ author.username }}</span> <span class="note-headline-light">@{{ author.username }}</span>
......
...@@ -47,10 +47,7 @@ const handleUserPopoverMouseOver = event => { ...@@ -47,10 +47,7 @@ const handleUserPopoverMouseOver = event => {
bio: null, bio: null,
organization: null, organization: null,
status: null, status: null,
<<<<<<< HEAD
=======
loaded: false, loaded: false,
>>>>>>> upstream/master
}; };
if (userId || username) { if (userId || username) {
const UserPopoverComponent = Vue.extend(UserPopover); const UserPopoverComponent = Vue.extend(UserPopover);
...@@ -98,22 +95,11 @@ const handleUserPopoverMouseOver = event => { ...@@ -98,22 +95,11 @@ const handleUserPopoverMouseOver = event => {
renderedPopover = null; renderedPopover = null;
}); });
} }
<<<<<<< HEAD
}, 200);
};
export default elements => {
let userLinks = elements;
if (!elements) {
userLinks = [...document.querySelectorAll('.js-user-link')];
}
=======
}, 200); // 200ms delay so not every mouseover triggers Popover + API Call }, 200); // 200ms delay so not every mouseover triggers Popover + API Call
}; };
export default elements => { export default elements => {
const userLinks = elements || [...document.querySelectorAll('.js-user-link')]; const userLinks = elements || [...document.querySelectorAll('.js-user-link')];
>>>>>>> upstream/master
userLinks.forEach(el => { userLinks.forEach(el => {
el.addEventListener('mouseenter', handleUserPopoverMouseOver); el.addEventListener('mouseenter', handleUserPopoverMouseOver);
......
...@@ -53,17 +53,10 @@ export default { ...@@ -53,17 +53,10 @@ export default {
return !this.user.name; return !this.user.name;
}, },
jobInfoIsLoading() { jobInfoIsLoading() {
<<<<<<< HEAD
return !this.loaded && this.user.organization === null;
},
locationIsLoading() {
return !this.loaded && this.user.location === null;
=======
return !this.user.loaded && this.user.organization === null; return !this.user.loaded && this.user.organization === null;
}, },
locationIsLoading() { locationIsLoading() {
return !this.user.loaded && this.user.location === null; return !this.user.loaded && this.user.location === null;
>>>>>>> upstream/master
}, },
}, },
}; };
......
...@@ -333,7 +333,6 @@ describe('Api', () => { ...@@ -333,7 +333,6 @@ describe('Api', () => {
}); });
}); });
<<<<<<< HEAD
describe('ldap_groups', () => { describe('ldap_groups', () => {
it('calls callback on completion', done => { it('calls callback on completion', done => {
const query = 'query'; const query = 'query';
...@@ -356,8 +355,6 @@ describe('Api', () => { ...@@ -356,8 +355,6 @@ describe('Api', () => {
}); });
}); });
=======
>>>>>>> upstream/master
describe('user', () => { describe('user', () => {
it('fetches single user', done => { it('fetches single user', done => {
const userId = '123456'; const userId = '123456';
......
...@@ -48,11 +48,7 @@ describe('User Popovers', () => { ...@@ -48,11 +48,7 @@ describe('User Popovers', () => {
expect(document.querySelector('.popover')).toBeNull(); expect(document.querySelector('.popover')).toBeNull();
done(); done();
}); });
<<<<<<< HEAD
}, 210);
=======
}, 210); // We need to wait until the 200ms mouseover delay is over, only then the popover will be visible }, 210); // We need to wait until the 200ms mouseover delay is over, only then the popover will be visible
>>>>>>> upstream/master
}); });
it('Should Not show a popover on short mouse over', done => { it('Should Not show a popover on short mouse over', done => {
......
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