diff options
author | Annabel Gray <annabel.m.gray@gmail.com> | 2018-06-14 17:35:15 +0000 |
---|---|---|
committer | Annabel Gray <annabel.m.gray@gmail.com> | 2018-06-14 17:35:15 +0000 |
commit | edfa2e3fb673412272e8bc9cdbfa2e3a86a9f21f (patch) | |
tree | bc845de75a7818b10295b2aa1ce91175bc5d4aff | |
parent | 7a21c911b5e4aa9e552d30235780a728d8931fa8 (diff) | |
parent | 26fcf83308ba1388423fe6afd536bf433d327a76 (diff) | |
download | gitlab-ce-edfa2e3fb673412272e8bc9cdbfa2e3a86a9f21f.tar.gz |
Merge branch '47850-placeholder-note-renders-the-user-name-in-a-new-line' into 'master'
Resolve "Placeholder note renders the user name in a new line"
Closes #47850
See merge request gitlab-org/gitlab-ce!19791
-rw-r--r-- | app/assets/javascripts/notes.js | 4 | ||||
-rw-r--r-- | app/assets/javascripts/vue_shared/components/notes/placeholder_note.vue | 2 | ||||
-rw-r--r-- | spec/javascripts/notes_spec.js | 4 |
3 files changed, 5 insertions, 5 deletions
diff --git a/app/assets/javascripts/notes.js b/app/assets/javascripts/notes.js index b2c1a26bbae..55f1d0b496c 100644 --- a/app/assets/javascripts/notes.js +++ b/app/assets/javascripts/notes.js @@ -1675,7 +1675,7 @@ export default class Notes { <div class="note-header"> <div class="note-header-info"> <a href="/${_.escape(currentUsername)}"> - <span class="d-none d-sm-block">${_.escape( + <span class="d-none d-sm-inline-block">${_.escape( currentUsername, )}</span> <span class="note-headline-light">${_.escape( @@ -1694,7 +1694,7 @@ export default class Notes { </li>`, ); - $tempNote.find('.d-none.d-sm-block').text(_.escape(currentUserFullname)); + $tempNote.find('.d-none.d-sm-inline-block').text(_.escape(currentUserFullname)); $tempNote .find('.note-headline-light') .text(`@${_.escape(currentUsername)}`); diff --git a/app/assets/javascripts/vue_shared/components/notes/placeholder_note.vue b/app/assets/javascripts/vue_shared/components/notes/placeholder_note.vue index eccba61a8c0..38115f268bb 100644 --- a/app/assets/javascripts/vue_shared/components/notes/placeholder_note.vue +++ b/app/assets/javascripts/vue_shared/components/notes/placeholder_note.vue @@ -54,7 +54,7 @@ <div class="note-header"> <div class="note-header-info"> <a :href="getUserData.path"> - <span class="d-none d-sm-block">{{ getUserData.name }}</span> + <span class="d-none d-sm-inline-block">{{ getUserData.name }}</span> <span class="note-headline-light">@{{ getUserData.username }}</span> </a> </div> diff --git a/spec/javascripts/notes_spec.js b/spec/javascripts/notes_spec.js index 648fb3e9bd3..acbf23e2007 100644 --- a/spec/javascripts/notes_spec.js +++ b/spec/javascripts/notes_spec.js @@ -974,7 +974,7 @@ import timeoutPromise from './helpers/set_timeout_promise_helper'; ).toBeFalsy(); expect( $tempNoteHeader - .find('.d-none.d-sm-block') + .find('.d-none.d-sm-inline-block') .text() .trim(), ).toEqual(currentUserFullname); @@ -1020,7 +1020,7 @@ import timeoutPromise from './helpers/set_timeout_promise_helper'; const $tempNoteHeader = $tempNote.find('.note-header'); expect( $tempNoteHeader - .find('.d-none.d-sm-block') + .find('.d-none.d-sm-inline-block') .text() .trim(), ).toEqual('Foo <script>alert("XSS")</script>'); |