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
1
Merge Requests
1
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
nexedi
gitlab-ce
Commits
6829f144
Commit
6829f144
authored
Mar 16, 2021
by
Jarek Ostrowski
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update commit page buttons and spacing
MR:
https://gitlab.com/gitlab-org/gitlab/-/merge_requests/56793
parent
125a909a
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
14 additions
and
9 deletions
+14
-9
app/views/projects/diffs/_diffs.html.haml
app/views/projects/diffs/_diffs.html.haml
+2
-2
app/views/projects/diffs/_file.html.haml
app/views/projects/diffs/_file.html.haml
+3
-3
app/views/shared/notes/_comment_button.html.haml
app/views/shared/notes/_comment_button.html.haml
+4
-4
changelogs/unreleased/273284-update-commit-page-buttons.yml
changelogs/unreleased/273284-update-commit-page-buttons.yml
+5
-0
No files found.
app/views/projects/diffs/_diffs.html.haml
View file @
6829f144
...
...
@@ -8,7 +8,7 @@
.content-block.oneline-block.files-changed.diff-files-changed.js-diff-files-changed
.files-changed-inner
.inline-parallel-buttons.
d-none.d-md-block
.inline-parallel-buttons.
gl-display-none.gl-md-display-flex
-
if
!
diffs_expanded?
&&
diff_files
.
any?
{
|
diff_file
|
diff_file
.
collapsed?
}
=
link_to
_
(
'Expand all'
),
url_for
(
safe_params
.
merge
(
expanded:
1
,
format:
nil
)),
class:
'gl-button btn btn-default'
-
if
show_whitespace_toggle
...
...
@@ -20,7 +20,7 @@
=
diff_compare_whitespace_link
(
diffs
.
project
,
params
[
:from
],
params
[
:to
],
class:
'd-none d-sm-inline-block'
)
-
elsif
current_controller?
(
:wikis
)
=
toggle_whitespace_link
(
url_for
(
params_with_whitespace
),
class:
'd-none d-sm-inline-block'
)
.btn-group
.btn-group
.gl-ml-3
=
inline_diff_btn
=
parallel_diff_btn
=
render
'projects/diffs/stats'
,
diff_files:
diff_files
...
...
app/views/projects/diffs/_file.html.haml
View file @
6829f144
...
...
@@ -14,10 +14,10 @@
=
submodule_diff_compare_link
(
diff_file
)
-
unless
diff_file
.
submodule?
.file-actions.
d-none.d-sm-block
.file-actions.
gl-display-none.gl-sm-display-flex
-
if
diff_file
.
blob
&
.
readable_text?
%span
.has-tooltip
{
title:
_
(
"Toggle comments for this file"
)
}
=
link_to
'#'
,
class:
'js-toggle-diff-comments btn gl-button btn-default selected'
,
disabled:
@diff_notes_disabled
do
%span
.has-tooltip
.gl-mr-3
{
title:
_
(
"Toggle comments for this file"
)
}
=
link_to
'#'
,
class:
'js-toggle-diff-comments btn gl-button btn-default
btn-icon
selected'
,
disabled:
@diff_notes_disabled
do
=
sprite_icon
(
'comment'
)
\
-
if
editable_diff?
(
diff_file
)
...
...
app/views/shared/notes/_comment_button.html.haml
View file @
6829f144
-
noteable_name
=
@note
.
noteable
.
human_class_name
.float-left.btn-group.gl-mr-3.droplab-dropdown.comment-type-dropdown.js-comment-type-dropdown
%input
.btn.gl-button.btn-
success
.js-comment-button.js-comment-submit-button
{
type:
'submit'
,
value:
_
(
'Comment'
),
data:
{
qa_selector:
'comment_button'
}
}
%input
.btn.gl-button.btn-
confirm
.js-comment-button.js-comment-submit-button
{
type:
'submit'
,
value:
_
(
'Comment'
),
data:
{
qa_selector:
'comment_button'
}
}
-
if
@note
.
can_be_discussion_note?
=
button_tag
type:
'button'
,
class:
'gl-button btn dropdown-toggle btn-
success
js-note-new-discussion js-disable-on-submit'
,
data:
{
'dropdown-trigger'
=>
'#resolvable-comment-menu'
},
'aria-label'
=>
_
(
'Open comment type dropdown'
)
do
=
button_tag
type:
'button'
,
class:
'gl-button btn dropdown-toggle btn-
confirm btn-icon
js-note-new-discussion js-disable-on-submit'
,
data:
{
'dropdown-trigger'
=>
'#resolvable-comment-menu'
},
'aria-label'
=>
_
(
'Open comment type dropdown'
)
do
=
sprite_icon
(
'chevron-down'
)
%ul
#resolvable-comment-menu
.dropdown-menu.dropdown-open-top
{
data:
{
dropdown:
true
}
}
%li
#comment
.droplab-item-selected
{
data:
{
value:
''
,
'submit-text'
=>
_
(
'Comment'
),
'close-text'
=>
_
(
"Comment & close %{noteable_name}"
)
%
{
noteable_name:
noteable_name
},
'reopen-text'
=>
_
(
"Comment & reopen %{noteable_name}"
)
%
{
noteable_name:
noteable_name
}
}
}
%button
{
type:
'button'
}
%button
.btn.gl-button.btn-default-tertiary
=
sprite_icon
(
'check'
,
css_class:
'icon'
)
.description
%strong
=
_
(
"Comment"
)
...
...
@@ -19,7 +19,7 @@
%li
.divider.droplab-item-ignore
%li
#discussion
{
data:
{
value:
'DiscussionNote'
,
'submit-text'
=>
_
(
'Start thread'
),
'close-text'
=>
_
(
"Start thread & close %{noteable_name}"
)
%
{
noteable_name:
noteable_name
},
'reopen-text'
=>
_
(
"Start thread & reopen %{noteable_name}"
)
%
{
noteable_name:
noteable_name
}
}
}
%button
{
type:
'button'
}
%button
.btn.gl-button.btn-default-tertiary
=
sprite_icon
(
'check'
,
css_class:
'icon'
)
.description
%strong
=
_
(
"Start thread"
)
...
...
changelogs/unreleased/273284-update-commit-page-buttons.yml
0 → 100644
View file @
6829f144
---
title
:
Update buttons and spacing on commit page
merge_request
:
56793
author
:
type
:
changed
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