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
feaf8e09
Commit
feaf8e09
authored
Feb 03, 2022
by
GitLab Bot
Browse files
Options
Browse Files
Download
Plain Diff
Automatic merge of gitlab-org/gitlab master
parents
1de7a2a8
84597b8c
Changes
6
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
95 additions
and
103 deletions
+95
-103
app/models/commit.rb
app/models/commit.rb
+1
-3
app/views/layouts/nav/sidebar/_admin.html.haml
app/views/layouts/nav/sidebar/_admin.html.haml
+2
-2
package.json
package.json
+10
-10
spec/frontend/content_editor/test_utils.js
spec/frontend/content_editor/test_utils.js
+1
-1
spec/models/commit_spec.rb
spec/models/commit_spec.rb
+5
-11
yarn.lock
yarn.lock
+76
-76
No files found.
app/models/commit.rb
View file @
feaf8e09
...
...
@@ -513,9 +513,7 @@ class Commit
# We don't want to do anything for `Commit` model, so this is empty.
end
# WIP is deprecated in favor of Draft. Currently both options are supported
# https://gitlab.com/gitlab-org/gitlab/-/issues/227426
DRAFT_REGEX
=
/\A\s*
#{
Regexp
.
union
(
Gitlab
::
Regex
.
merge_request_wip
,
Gitlab
::
Regex
.
merge_request_draft
)
}
|(fixup!|squash!)\s/
.
freeze
DRAFT_REGEX
=
/\A\s*
#{
Gitlab
::
Regex
.
merge_request_draft
}
|(fixup!|squash!)\s/
.
freeze
def
work_in_progress?
!!
(
title
=~
DRAFT_REGEX
)
...
...
app/views/layouts/nav/sidebar/_admin.html.haml
View file @
feaf8e09
...
...
@@ -156,13 +156,13 @@
=
sprite_icon
(
'slight-frown'
)
%span
.nav-item-name
=
_
(
'Abuse Reports'
)
%span
.badge.badge-pill.count
=
number_with_delimiter
(
AbuseReport
.
count
(
:all
))
=
gl_badge_tag
number_with_delimiter
(
AbuseReport
.
count
(
:all
)),
variant: :info
,
size: :sm
%ul
.sidebar-sub-level-items.is-fly-out-only
=
nav_link
(
controller: :abuse_reports
,
html_options:
{
class:
"fly-out-top-item"
}
)
do
=
link_to
admin_abuse_reports_path
do
%strong
.fly-out-top-item-name
=
_
(
'Abuse Reports'
)
%span
.badge.badge-pill.count.merge_counter.js-merge-counter.fly-out-badge
=
number_with_delimiter
(
AbuseReport
.
count
(
:all
))
=
gl_badge_tag
number_with_delimiter
(
AbuseReport
.
count
(
:all
)),
variant: :info
,
size: :sm
=
render_if_exists
'layouts/nav/sidebar/licenses_link'
...
...
package.json
View file @
feaf8e09
...
...
@@ -62,36 +62,36 @@
"
@rails/ujs
"
:
"
6.1.4-1
"
,
"
@sentry/browser
"
:
"
5.30.0
"
,
"
@sourcegraph/code-host-integration
"
:
"
0.0.60
"
,
"
@tiptap/core
"
:
"
^2.0.0-beta.1
60
"
,
"
@tiptap/core
"
:
"
^2.0.0-beta.1
71
"
,
"
@tiptap/extension-blockquote
"
:
"
^2.0.0-beta.26
"
,
"
@tiptap/extension-bold
"
:
"
^2.0.0-beta.25
"
,
"
@tiptap/extension-bullet-list
"
:
"
^2.0.0-beta.26
"
,
"
@tiptap/extension-code
"
:
"
^2.0.0-beta.26
"
,
"
@tiptap/extension-code-block-lowlight
"
:
"
2.0.0-beta.6
3
"
,
"
@tiptap/extension-code-block-lowlight
"
:
"
2.0.0-beta.6
8
"
,
"
@tiptap/extension-document
"
:
"
^2.0.0-beta.15
"
,
"
@tiptap/extension-dropcursor
"
:
"
^2.0.0-beta.25
"
,
"
@tiptap/extension-gapcursor
"
:
"
^2.0.0-beta.34
"
,
"
@tiptap/extension-hard-break
"
:
"
^2.0.0-beta.30
"
,
"
@tiptap/extension-heading
"
:
"
^2.0.0-beta.2
4
"
,
"
@tiptap/extension-heading
"
:
"
^2.0.0-beta.2
6
"
,
"
@tiptap/extension-history
"
:
"
^2.0.0-beta.21
"
,
"
@tiptap/extension-horizontal-rule
"
:
"
^2.0.0-beta.3
0
"
,
"
@tiptap/extension-image
"
:
"
^2.0.0-beta.2
4
"
,
"
@tiptap/extension-horizontal-rule
"
:
"
^2.0.0-beta.3
1
"
,
"
@tiptap/extension-image
"
:
"
^2.0.0-beta.2
5
"
,
"
@tiptap/extension-italic
"
:
"
^2.0.0-beta.25
"
,
"
@tiptap/extension-link
"
:
"
^2.0.0-beta.3
4
"
,
"
@tiptap/extension-link
"
:
"
^2.0.0-beta.3
6
"
,
"
@tiptap/extension-list-item
"
:
"
^2.0.0-beta.20
"
,
"
@tiptap/extension-ordered-list
"
:
"
^2.0.0-beta.27
"
,
"
@tiptap/extension-paragraph
"
:
"
^2.0.0-beta.23
"
,
"
@tiptap/extension-strike
"
:
"
^2.0.0-beta.27
"
,
"
@tiptap/extension-subscript
"
:
"
^2.0.0-beta.10
"
,
"
@tiptap/extension-superscript
"
:
"
^2.0.0-beta.10
"
,
"
@tiptap/extension-table
"
:
"
^2.0.0-beta.4
6
"
,
"
@tiptap/extension-table
"
:
"
^2.0.0-beta.4
8
"
,
"
@tiptap/extension-table-cell
"
:
"
^2.0.0-beta.20
"
,
"
@tiptap/extension-table-header
"
:
"
^2.0.0-beta.22
"
,
"
@tiptap/extension-table-row
"
:
"
^2.0.0-beta.19
"
,
"
@tiptap/extension-task-item
"
:
"
^2.0.0-beta.3
0
"
,
"
@tiptap/extension-task-item
"
:
"
^2.0.0-beta.3
1
"
,
"
@tiptap/extension-task-list
"
:
"
^2.0.0-beta.26
"
,
"
@tiptap/extension-text
"
:
"
^2.0.0-beta.15
"
,
"
@tiptap/vue-2
"
:
"
^2.0.0-beta.7
4
"
,
"
@tiptap/vue-2
"
:
"
^2.0.0-beta.7
7
"
,
"
@toast-ui/editor
"
:
"
^2.5.2
"
,
"
@toast-ui/vue-editor
"
:
"
^2.5.2
"
,
"
apollo-cache-inmemory
"
:
"
^1.6.6
"
,
...
...
@@ -165,7 +165,7 @@
"
prosemirror-model
"
:
"
^1.16.1
"
,
"
prosemirror-state
"
:
"
^1.3.4
"
,
"
prosemirror-tables
"
:
"
^1.1.1
"
,
"
prosemirror-view
"
:
"
^1.23.
5
"
,
"
prosemirror-view
"
:
"
^1.23.
6
"
,
"
raphael
"
:
"
^2.2.7
"
,
"
raw-loader
"
:
"
^4.0.2
"
,
"
scrollparent
"
:
"
^2.0.1
"
,
...
...
spec/frontend/content_editor/test_utils.js
View file @
feaf8e09
...
...
@@ -132,7 +132,7 @@ export const triggerNodeInputRule = ({ tiptapEditor, inputRuleText }) => {
export
const
triggerMarkInputRule
=
({
tiptapEditor
,
inputRuleText
})
=>
{
const
{
view
}
=
tiptapEditor
;
tiptapEditor
.
chain
().
setContent
(
inputRuleText
).
setTextSelection
(
0
).
run
();
tiptapEditor
.
chain
().
setContent
(
inputRuleText
).
setTextSelection
(
1
).
run
();
const
{
state
}
=
tiptapEditor
;
const
{
selection
}
=
state
;
...
...
spec/models/commit_spec.rb
View file @
feaf8e09
...
...
@@ -748,29 +748,23 @@ eos
describe
'#work_in_progress?'
do
[
'squash! '
,
'fixup! '
,
'wip: '
,
'WIP: '
,
'[WIP] '
,
'squash! '
,
'fixup! '
,
'draft: '
,
'[Draft] '
,
'(draft) '
,
'Draft: '
].
each
do
|
wip
_prefix
|
it
"detects the '
#{
wip
_prefix
}
' prefix"
do
commit
.
message
=
"
#{
wip
_prefix
}#{
commit
.
message
}
"
].
each
do
|
draft
_prefix
|
it
"detects the '
#{
draft
_prefix
}
' prefix"
do
commit
.
message
=
"
#{
draft
_prefix
}#{
commit
.
message
}
"
expect
(
commit
).
to
be_work_in_progress
end
end
it
"detects WIP for a commit just saying 'wip'"
do
commit
.
message
=
"wip"
expect
(
commit
).
to
be_work_in_progress
end
it
"does not detect WIP for a commit just saying 'draft'"
do
commit
.
message
=
"draft"
expect
(
commit
).
not_to
be_work_in_progress
end
[
"FIXUP!"
,
"Draft - "
,
"Wipeout"
].
each
do
|
draft_prefix
|
[
"FIXUP!"
,
"Draft - "
,
"Wipeout"
,
"WIP: "
,
"[WIP] "
,
"wip: "
].
each
do
|
draft_prefix
|
it
"doesn't detect '
#{
draft_prefix
}
' at the start of the title as a draft"
do
commit
.
message
=
"
#{
draft_prefix
}
#{
commit
.
message
}
"
...
...
yarn.lock
View file @
feaf8e09
This diff is collapsed.
Click to expand it.
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