Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boxiang Sun
gitlab-ce
Commits
058909e7
Commit
058909e7
authored
Apr 01, 2018
by
Takuya Noguchi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Refactor and tweak margin for note forms on Issuable
Signed-off-by:
Takuya Noguchi
<
takninnovationresearch@gmail.com
>
parent
d2ad0bcc
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
31 additions
and
47 deletions
+31
-47
app/assets/javascripts/notes.js
app/assets/javascripts/notes.js
+2
-2
app/assets/javascripts/notes/components/noteable_discussion.vue
...sets/javascripts/notes/components/noteable_discussion.vue
+1
-3
app/assets/stylesheets/pages/diff.scss
app/assets/stylesheets/pages/diff.scss
+1
-0
app/assets/stylesheets/pages/note_form.scss
app/assets/stylesheets/pages/note_form.scss
+2
-11
app/assets/stylesheets/pages/notes.scss
app/assets/stylesheets/pages/notes.scss
+3
-13
app/views/shared/notes/_form.html.haml
app/views/shared/notes/_form.html.haml
+17
-18
changelogs/unreleased/44870-remove-extra-space-around-comment-form-on-merge-requests.yml
...ove-extra-space-around-comment-form-on-merge-requests.yml
+5
-0
No files found.
app/assets/javascripts/notes.js
View file @
058909e7
...
@@ -1190,12 +1190,12 @@ export default class Notes {
...
@@ -1190,12 +1190,12 @@ export default class Notes {
addForm
=
false
;
addForm
=
false
;
let
lineTypeSelector
=
''
;
let
lineTypeSelector
=
''
;
rowCssToAdd
=
rowCssToAdd
=
'
<tr class="notes_holder js-temp-notes-holder"><td class="notes_line" colspan="2"></td><td class="notes_content"><div class="content"></div></td></tr>
'
;
'
<tr class="notes_holder js-temp-notes-holder"><td class="notes_line" colspan="2"></td><td class="notes_content"><div class="content
discussion-notes
"></div></td></tr>
'
;
// In parallel view, look inside the correct left/right pane
// In parallel view, look inside the correct left/right pane
if
(
this
.
isParallelView
())
{
if
(
this
.
isParallelView
())
{
lineTypeSelector
=
`.
${
lineType
}
`
;
lineTypeSelector
=
`.
${
lineType
}
`
;
rowCssToAdd
=
rowCssToAdd
=
'
<tr class="notes_holder js-temp-notes-holder"><td class="notes_line old"></td><td class="notes_content parallel old"><div class="content
"></div></td><td class="notes_line new"></td><td class="notes_content parallel new"><div class="content
"></div></td></tr>
'
;
'
<tr class="notes_holder js-temp-notes-holder"><td class="notes_line old"></td><td class="notes_content parallel old"><div class="content
discussion-notes"></div></td><td class="notes_line new"></td><td class="notes_content parallel new"><div class="content discussion-notes
"></div></td></tr>
'
;
}
}
const
notesContentSelector
=
`.notes_content
${
lineTypeSelector
}
.content`
;
const
notesContentSelector
=
`.notes_content
${
lineTypeSelector
}
.content`
;
let
notesContent
=
targetRow
.
find
(
notesContentSelector
);
let
notesContent
=
targetRow
.
find
(
notesContentSelector
);
...
...
app/assets/javascripts/notes/components/noteable_discussion.vue
View file @
058909e7
...
@@ -258,9 +258,7 @@ Please check your network connection and try again.`;
...
@@ -258,9 +258,7 @@ Please check your network connection and try again.`;
:key=
"note.id"
:key=
"note.id"
/>
/>
</ul>
</ul>
<div
<div
class=
"discussion-reply-holder"
>
:class=
"
{ 'is-replying': isReplying }"
class="discussion-reply-holder">
<template
v-if=
"!isReplying && canReply"
>
<template
v-if=
"!isReplying && canReply"
>
<div
<div
class=
"btn-group-justified discussion-with-resolve-btn"
class=
"btn-group-justified discussion-with-resolve-btn"
...
...
app/assets/stylesheets/pages/diff.scss
View file @
058909e7
...
@@ -813,6 +813,7 @@
...
@@ -813,6 +813,7 @@
}
}
.discussion-notes
{
.discussion-notes
{
padding
:
0
$gl-padding
$gl-padding
;
min-height
:
35px
;
min-height
:
35px
;
&
:first-child
{
&
:first-child
{
...
...
app/assets/stylesheets/pages/note_form.scss
View file @
058909e7
...
@@ -173,11 +173,7 @@
...
@@ -173,11 +173,7 @@
}
}
.discussion-form
{
.discussion-form
{
background-color
:
$white-light
;
padding-top
:
$gl-padding-top
;
}
.discussion-form-container
{
padding
:
$gl-padding-top
$gl-padding
$gl-padding
;
}
}
.discussion-notes
.disabled-comment
{
.discussion-notes
.disabled-comment
{
...
@@ -237,12 +233,7 @@
...
@@ -237,12 +233,7 @@
.discussion-body
,
.discussion-body
,
.diff-file
{
.diff-file
{
.discussion-reply-holder
{
.discussion-reply-holder
{
background-color
:
$white-light
;
padding-top
:
$gl-padding
;
padding
:
10px
16px
;
&
.is-replying
{
padding-bottom
:
$gl-padding
;
}
}
}
}
}
...
...
app/assets/stylesheets/pages/notes.scss
View file @
058909e7
...
@@ -47,7 +47,7 @@ ul.notes {
...
@@ -47,7 +47,7 @@ ul.notes {
}
}
.timeline-entry-inner
{
.timeline-entry-inner
{
padding
:
$gl-padding
$gl-btn-padding
;
padding
:
$gl-padding
0
;
border-bottom
:
1px
solid
$white-normal
;
border-bottom
:
1px
solid
$white-normal
;
}
}
...
@@ -94,12 +94,6 @@ ul.notes {
...
@@ -94,12 +94,6 @@ ul.notes {
}
}
}
}
&
.note-discussion
{
.timeline-entry-inner
{
padding
:
$gl-padding
10px
;
}
}
.editing-spinner
{
.editing-spinner
{
display
:
none
;
display
:
none
;
}
}
...
@@ -352,6 +346,8 @@ ul.notes {
...
@@ -352,6 +346,8 @@ ul.notes {
}
}
.discussion-notes
{
.discussion-notes
{
background-color
:
$white-light
;
&
:not
(
:first-child
)
{
&
:not
(
:first-child
)
{
border-top
:
1px
solid
$white-normal
;
border-top
:
1px
solid
$white-normal
;
margin-top
:
20px
;
margin-top
:
20px
;
...
@@ -363,10 +359,6 @@ ul.notes {
...
@@ -363,10 +359,6 @@ ul.notes {
}
}
}
}
.notes
{
background-color
:
$white-light
;
}
a
code
{
a
code
{
top
:
0
;
top
:
0
;
margin-right
:
0
;
margin-right
:
0
;
...
@@ -647,8 +639,6 @@ ul.notes {
...
@@ -647,8 +639,6 @@ ul.notes {
border-bottom
:
1px
solid
$white-normal
;
border-bottom
:
1px
solid
$white-normal
;
.timeline-entry-inner
{
.timeline-entry-inner
{
padding-left
:
$gl-padding
;
padding-right
:
$gl-padding
;
border-bottom
:
0
;
border-bottom
:
0
;
}
}
}
}
...
...
app/views/shared/notes/_form.html.haml
View file @
058909e7
...
@@ -24,21 +24,20 @@
...
@@ -24,21 +24,20 @@
-# DiffNote
-# DiffNote
=
f
.
hidden_field
:position
=
f
.
hidden_field
:position
.discussion-form-container
=
render
layout:
'projects/md_preview'
,
locals:
{
url:
preview_url
,
referenced_users:
true
}
do
=
render
layout:
'projects/md_preview'
,
locals:
{
url:
preview_url
,
referenced_users:
true
}
do
=
render
'projects/zen'
,
f:
f
,
=
render
'projects/zen'
,
f:
f
,
attr: :note
,
attr: :note
,
classes:
'note-textarea js-note-text'
,
classes:
'note-textarea js-note-text'
,
placeholder:
"Write a comment or drag your files here..."
,
placeholder:
"Write a comment or drag your files here..."
,
supports_quick_actions:
supports_quick_actions
,
supports_quick_actions:
supports_quick_actions
,
supports_autocomplete:
supports_autocomplete
supports_autocomplete:
supports_autocomplete
=
render
'shared/notes/hints'
,
supports_quick_actions:
supports_quick_actions
=
render
'shared/notes/hints'
,
supports_quick_actions:
supports_quick_actions
.error-alert
.error-alert
.note-form-actions.clearfix
.note-form-actions.clearfix
=
render
partial:
'shared/notes/comment_button'
=
render
partial:
'shared/notes/comment_button'
=
yield
(
:note_actions
)
=
yield
(
:note_actions
)
%a
.btn.btn-cancel.js-note-discard
{
role:
"button"
,
data:
{
cancel_text:
"Cancel"
}
}
%a
.btn.btn-cancel.js-note-discard
{
role:
"button"
,
data:
{
cancel_text:
"Cancel"
}
}
Discard draft
Discard draft
changelogs/unreleased/44870-remove-extra-space-around-comment-form-on-merge-requests.yml
0 → 100644
View file @
058909e7
---
title
:
Refactor and tweak margin for note forms on Issuable
merge_request
:
18120
author
:
Takuya Noguchi
type
:
fixed
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment