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
07f5bc94
Commit
07f5bc94
authored
Dec 22, 2020
by
Lukas Eipert
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Run prettier on 30 files: 4 of 8
Mandatory not to break master. Automatically created with prettier.
parent
888002a6
Changes
30
Hide whitespace changes
Inline
Side-by-side
Showing
30 changed files
with
93 additions
and
172 deletions
+93
-172
app/assets/javascripts/members.js
app/assets/javascripts/members.js
+2
-6
app/assets/javascripts/merge_conflicts/components/diff_file_editor.js
...avascripts/merge_conflicts/components/diff_file_editor.js
+20
-11
app/assets/javascripts/merge_request.js
app/assets/javascripts/merge_request.js
+11
-11
app/assets/javascripts/mini_pipeline_graph_dropdown.js
app/assets/javascripts/mini_pipeline_graph_dropdown.js
+1
-5
app/assets/javascripts/monitoring/components/dashboard_panel_builder.vue
...scripts/monitoring/components/dashboard_panel_builder.vue
+1
-1
app/assets/javascripts/network/branch_graph.js
app/assets/javascripts/network/branch_graph.js
+2
-2
app/assets/javascripts/new_branch_form.js
app/assets/javascripts/new_branch_form.js
+2
-2
app/assets/javascripts/notes.js
app/assets/javascripts/notes.js
+12
-50
app/assets/javascripts/notes/components/discussion_actions.vue
...ssets/javascripts/notes/components/discussion_actions.vue
+2
-2
app/assets/javascripts/notes/components/note_form.vue
app/assets/javascripts/notes/components/note_form.vue
+1
-2
app/assets/javascripts/notifications_dropdown.js
app/assets/javascripts/notifications_dropdown.js
+2
-6
app/assets/javascripts/packages/details/components/package_files.vue
...javascripts/packages/details/components/package_files.vue
+1
-1
app/assets/javascripts/packages/list/components/packages_list_app.vue
...avascripts/packages/list/components/packages_list_app.vue
+1
-1
app/assets/javascripts/pages/profiles/index.js
app/assets/javascripts/pages/profiles/index.js
+1
-1
app/assets/javascripts/pages/projects/graphs/components/code_coverage.vue
...cripts/pages/projects/graphs/components/code_coverage.vue
+1
-3
app/assets/javascripts/pages/projects/init_form.js
app/assets/javascripts/pages/projects/init_form.js
+1
-1
app/assets/javascripts/pages/projects/issues/show.js
app/assets/javascripts/pages/projects/issues/show.js
+1
-1
app/assets/javascripts/pages/projects/merge_requests/creations/new/compare.js
...ts/pages/projects/merge_requests/creations/new/compare.js
+2
-6
app/assets/javascripts/pages/projects/merge_requests/init_merge_request_show.js
.../pages/projects/merge_requests/init_merge_request_show.js
+1
-1
app/assets/javascripts/pages/projects/pipeline_schedules/shared/components/interval_pattern_input.vue
...ne_schedules/shared/components/interval_pattern_input.vue
+1
-1
app/assets/javascripts/pages/projects/project.js
app/assets/javascripts/pages/projects/project.js
+9
-17
app/assets/javascripts/pages/projects/shared/permissions/components/settings_panel.vue
...projects/shared/permissions/components/settings_panel.vue
+6
-3
app/assets/javascripts/pages/projects/tags/index/index.js
app/assets/javascripts/pages/projects/tags/index/index.js
+1
-4
app/assets/javascripts/pages/search/show/search.js
app/assets/javascripts/pages/search/show/search.js
+3
-10
app/assets/javascripts/pages/users/activity_calendar.js
app/assets/javascripts/pages/users/activity_calendar.js
+2
-9
app/assets/javascripts/pages/users/index.js
app/assets/javascripts/pages/users/index.js
+1
-3
app/assets/javascripts/pipeline_editor/components/lint/ci_lint_results.vue
...ripts/pipeline_editor/components/lint/ci_lint_results.vue
+1
-1
app/assets/javascripts/pipelines/components/graph/job_item.vue
...ssets/javascripts/pipelines/components/graph/job_item.vue
+1
-2
app/assets/javascripts/pipelines/components/pipeline_graph/drawing_utils.js
...ipts/pipelines/components/pipeline_graph/drawing_utils.js
+2
-8
app/assets/javascripts/pipelines/components/pipelines_list/pipeline_url.vue
...ipts/pipelines/components/pipelines_list/pipeline_url.vue
+1
-1
No files found.
app/assets/javascripts/members.js
View file @
07f5bc94
...
...
@@ -12,13 +12,9 @@ export default class Members {
addListeners
()
{
// eslint-disable-next-line @gitlab/no-global-event-off
$
(
'
.js-member-update-control
'
)
.
off
(
'
change
'
)
.
on
(
'
change
'
,
this
.
formSubmit
.
bind
(
this
));
$
(
'
.js-member-update-control
'
).
off
(
'
change
'
).
on
(
'
change
'
,
this
.
formSubmit
.
bind
(
this
));
// eslint-disable-next-line @gitlab/no-global-event-off
$
(
'
.js-edit-member-form
'
)
.
off
(
'
ajax:success
'
)
.
on
(
'
ajax:success
'
,
this
.
formSuccess
.
bind
(
this
));
$
(
'
.js-edit-member-form
'
).
off
(
'
ajax:success
'
).
on
(
'
ajax:success
'
,
this
.
formSuccess
.
bind
(
this
));
disableButtonIfEmptyField
(
'
#user_ids
'
,
'
input[name=commit]
'
,
'
change
'
);
}
...
...
app/assets/javascripts/merge_conflicts/components/diff_file_editor.js
View file @
07f5bc94
...
...
@@ -60,19 +60,28 @@ import { __ } from '~/locale';
const
DataPromise
=
axios
.
get
(
this
.
file
.
content_path
);
Promise
.
all
([
EditorPromise
,
DataPromise
])
.
then
(([{
default
:
EditorLite
},
{
data
:
{
content
,
new_path
:
path
}
}])
=>
{
const
contentEl
=
this
.
$el
.
querySelector
(
'
.editor
'
);
.
then
(
([
{
default
:
EditorLite
},
{
data
:
{
content
,
new_path
:
path
},
},
])
=>
{
const
contentEl
=
this
.
$el
.
querySelector
(
'
.editor
'
);
this
.
originalContent
=
content
;
this
.
fileLoaded
=
true
;
this
.
originalContent
=
content
;
this
.
fileLoaded
=
true
;
this
.
editor
=
new
EditorLite
().
createInstance
({
el
:
contentEl
,
blobPath
:
path
,
blobContent
:
content
,
});
this
.
editor
.
onDidChangeModelContent
(
debounce
(
this
.
saveDiffResolution
.
bind
(
this
),
250
));
})
this
.
editor
=
new
EditorLite
().
createInstance
({
el
:
contentEl
,
blobPath
:
path
,
blobContent
:
content
,
});
this
.
editor
.
onDidChangeModelContent
(
debounce
(
this
.
saveDiffResolution
.
bind
(
this
),
250
),
);
},
)
.
catch
(()
=>
{
flash
(
__
(
'
An error occurred while loading the file
'
));
});
...
...
app/assets/javascripts/merge_request.js
View file @
07f5bc94
...
...
@@ -47,11 +47,11 @@ function MergeRequest(opts) {
}
// Local jQuery finder
MergeRequest
.
prototype
.
$
=
function
(
selector
)
{
MergeRequest
.
prototype
.
$
=
function
(
selector
)
{
return
this
.
$el
.
find
(
selector
);
};
MergeRequest
.
prototype
.
initTabs
=
function
()
{
MergeRequest
.
prototype
.
initTabs
=
function
()
{
if
(
window
.
mrTabs
)
{
window
.
mrTabs
.
unbindEvents
();
}
...
...
@@ -59,12 +59,12 @@ MergeRequest.prototype.initTabs = function() {
window
.
mrTabs
=
new
MergeRequestTabs
(
this
.
opts
);
};
MergeRequest
.
prototype
.
showAllCommits
=
function
()
{
MergeRequest
.
prototype
.
showAllCommits
=
function
()
{
this
.
$
(
'
.first-commits
'
).
remove
();
return
this
.
$
(
'
.all-commits
'
).
removeClass
(
'
hide
'
);
};
MergeRequest
.
prototype
.
initMRBtnListeners
=
function
()
{
MergeRequest
.
prototype
.
initMRBtnListeners
=
function
()
{
const
_this
=
this
;
const
draftToggles
=
document
.
querySelectorAll
(
'
.js-draft-toggle-button
'
);
...
...
@@ -99,7 +99,7 @@ MergeRequest.prototype.initMRBtnListeners = function() {
});
}
return
$
(
'
.btn-close, .btn-reopen
'
).
on
(
'
click
'
,
function
(
e
)
{
return
$
(
'
.btn-close, .btn-reopen
'
).
on
(
'
click
'
,
function
(
e
)
{
const
$this
=
$
(
this
);
const
shouldSubmit
=
$this
.
hasClass
(
'
btn-comment
'
);
if
(
shouldSubmit
&&
$this
.
data
(
'
submitted
'
))
{
...
...
@@ -117,7 +117,7 @@ MergeRequest.prototype.initMRBtnListeners = function() {
});
};
MergeRequest
.
prototype
.
submitNoteForm
=
function
(
form
,
$button
)
{
MergeRequest
.
prototype
.
submitNoteForm
=
function
(
form
,
$button
)
{
const
noteText
=
form
.
find
(
'
textarea.js-note-text
'
).
val
();
if
(
noteText
.
trim
().
length
>
0
)
{
form
.
submit
();
...
...
@@ -126,7 +126,7 @@ MergeRequest.prototype.submitNoteForm = function(form, $button) {
}
};
MergeRequest
.
prototype
.
initCommitMessageListeners
=
function
()
{
MergeRequest
.
prototype
.
initCommitMessageListeners
=
function
()
{
$
(
document
).
on
(
'
click
'
,
'
a.js-with-description-link
'
,
e
=>
{
const
textarea
=
$
(
'
textarea.js-commit-message
'
);
e
.
preventDefault
();
...
...
@@ -146,7 +146,7 @@ MergeRequest.prototype.initCommitMessageListeners = function() {
});
};
MergeRequest
.
setStatusBoxToMerged
=
function
()
{
MergeRequest
.
setStatusBoxToMerged
=
function
()
{
$
(
'
.detail-page-header .status-box
'
)
.
removeClass
(
'
status-box-open
'
)
.
addClass
(
'
status-box-mr-merged
'
)
...
...
@@ -154,20 +154,20 @@ MergeRequest.setStatusBoxToMerged = function() {
.
text
(
__
(
'
Merged
'
));
};
MergeRequest
.
decreaseCounter
=
function
(
by
=
1
)
{
MergeRequest
.
decreaseCounter
=
function
(
by
=
1
)
{
const
$el
=
$
(
'
.js-merge-counter
'
);
const
count
=
Math
.
max
(
parseInt
(
$el
.
text
().
replace
(
/
[^\d]
/
,
''
),
10
)
-
by
,
0
);
$el
.
text
(
addDelimiter
(
count
));
};
MergeRequest
.
hideCloseButton
=
function
()
{
MergeRequest
.
hideCloseButton
=
function
()
{
const
el
=
document
.
querySelector
(
'
.merge-request .js-issuable-actions
'
);
// Dropdown for mobile screen
el
.
querySelector
(
'
li.js-close-item
'
).
classList
.
add
(
'
hidden
'
);
};
MergeRequest
.
toggleDraftStatus
=
function
(
title
,
isReady
)
{
MergeRequest
.
toggleDraftStatus
=
function
(
title
,
isReady
)
{
if
(
isReady
)
{
createFlash
(
__
(
'
The merge request can now be merged.
'
),
'
notice
'
);
}
...
...
app/assets/javascripts/mini_pipeline_graph_dropdown.js
View file @
07f5bc94
...
...
@@ -92,11 +92,7 @@ export default class MiniPipelineGraph {
})
.
catch
(()
=>
{
this
.
toggleLoading
(
button
);
if
(
$
(
button
)
.
parent
()
.
hasClass
(
'
open
'
)
)
{
if
(
$
(
button
).
parent
().
hasClass
(
'
open
'
))
{
$
(
button
).
dropdown
(
'
toggle
'
);
}
flash
(
__
(
'
An error occurred while fetching the builds.
'
),
'
alert
'
);
...
...
app/assets/javascripts/monitoring/components/dashboard_panel_builder.vue
View file @
07f5bc94
...
...
@@ -146,7 +146,7 @@ export default {
)
"
>
<template
#code
="
{
content
}">
<template
#code
="
{
content
}">
<code>
{{
content
}}
</code>
</
template
>
</gl-sprintf>
...
...
app/assets/javascripts/network/branch_graph.js
View file @
07f5bc94
...
...
@@ -243,11 +243,11 @@ export default class BranchGraph {
})
.
click
(()
=>
window
.
open
(
options
.
commit_url
.
replace
(
'
%s
'
,
commit
.
id
),
'
_blank
'
))
.
hover
(
function
()
{
function
()
{
this
.
tooltip
=
r
.
commitTooltip
(
x
+
5
,
y
,
commit
);
return
top
.
push
(
this
.
tooltip
.
insertBefore
(
this
));
},
function
()
{
function
()
{
return
this
.
tooltip
&&
this
.
tooltip
.
remove
()
&&
delete
this
.
tooltip
;
},
);
...
...
app/assets/javascripts/new_branch_form.js
View file @
07f5bc94
...
...
@@ -53,13 +53,13 @@ export default class NewBranchForm {
const
{
indexOf
}
=
[];
this
.
branchNameError
.
empty
();
const
unique
=
function
(
values
,
value
)
{
const
unique
=
function
(
values
,
value
)
{
if
(
indexOf
.
call
(
values
,
value
)
===
-
1
)
{
values
.
push
(
value
);
}
return
values
;
};
const
formatter
=
function
(
values
,
restriction
)
{
const
formatter
=
function
(
values
,
restriction
)
{
const
formatted
=
values
.
map
(
value
=>
{
switch
(
false
)
{
case
!
/
\s
/
.
test
(
value
):
...
...
app/assets/javascripts/notes.js
View file @
07f5bc94
...
...
@@ -108,10 +108,7 @@ export default class Notes {
// We are in the Merge Requests page so we need another edit form for Changes tab
if
(
getPagePath
(
1
)
===
'
merge_requests
'
)
{
$
(
'
.note-edit-form
'
)
.
clone
()
.
addClass
(
'
mr-note-edit-form
'
)
.
insertAfter
(
'
.note-edit-form
'
);
$
(
'
.note-edit-form
'
).
clone
().
addClass
(
'
mr-note-edit-form
'
).
insertAfter
(
'
.note-edit-form
'
);
}
const
hash
=
getLocationHash
();
...
...
@@ -427,12 +424,7 @@ export default class Notes {
}
else
if
(
Notes
.
isUpdatedNote
(
noteEntity
,
$note
))
{
// The server can send the same update multiple times so we need to make sure to only update once per actual update.
const
isEditing
=
$note
.
hasClass
(
'
is-editing
'
);
const
initialContent
=
normalizeNewlines
(
$note
.
find
(
'
.original-note-content
'
)
.
text
()
.
trim
(),
);
const
initialContent
=
normalizeNewlines
(
$note
.
find
(
'
.original-note-content
'
).
text
().
trim
());
const
$textarea
=
$note
.
find
(
'
.js-note-text
'
);
const
currentContent
=
$textarea
.
val
();
// There can be CRLF vs LF mismatches if we don't sanitize and compare the same way
...
...
@@ -541,14 +533,8 @@ export default class Notes {
form
.
find
(
'
.js-errors
'
).
remove
();
// reset text and preview
form
.
find
(
'
.js-md-write-button
'
).
click
();
form
.
find
(
'
.js-note-text
'
)
.
val
(
''
)
.
trigger
(
'
input
'
);
form
.
find
(
'
.js-note-text
'
)
.
data
(
'
autosave
'
)
.
reset
();
form
.
find
(
'
.js-note-text
'
).
val
(
''
).
trigger
(
'
input
'
);
form
.
find
(
'
.js-note-text
'
).
data
(
'
autosave
'
).
reset
();
const
event
=
document
.
createEvent
(
'
Event
'
);
event
.
initEvent
(
'
autosize:update
'
,
true
,
false
);
...
...
@@ -690,10 +676,7 @@ export default class Notes {
}
checkContentToAllowEditing
(
$el
)
{
const
initialContent
=
$el
.
find
(
'
.original-note-content
'
)
.
text
()
.
trim
();
const
initialContent
=
$el
.
find
(
'
.original-note-content
'
).
text
().
trim
();
const
currentContent
=
$el
.
find
(
'
.js-note-text
'
).
val
();
let
isAllowed
=
true
;
...
...
@@ -877,10 +860,7 @@ export default class Notes {
const
form
=
this
.
cleanForm
(
this
.
formClone
.
clone
());
const
replyLink
=
$
(
target
).
closest
(
'
.js-discussion-reply-button
'
);
// insert the form after the button
replyLink
.
closest
(
'
.discussion-reply-holder
'
)
.
hide
()
.
after
(
form
);
replyLink
.
closest
(
'
.discussion-reply-holder
'
).
hide
().
after
(
form
);
// show the form
return
this
.
setupDiscussionNoteForm
(
replyLink
,
form
);
}
...
...
@@ -1069,10 +1049,7 @@ export default class Notes {
const
row
=
form
.
closest
(
'
tr
'
);
const
glForm
=
form
.
data
(
'
glForm
'
);
glForm
.
destroy
();
form
.
find
(
'
.js-note-text
'
)
.
data
(
'
autosave
'
)
.
reset
();
form
.
find
(
'
.js-note-text
'
).
data
(
'
autosave
'
).
reset
();
// show the reply button (will only work for replies)
form
.
prev
(
'
.discussion-reply-holder
'
).
show
();
if
(
row
.
is
(
'
.js-temp-notes-holder
'
))
{
...
...
@@ -1181,16 +1158,10 @@ export default class Notes {
this
.
glForm
=
new
GLForm
(
$editForm
.
find
(
'
form
'
),
this
.
enableGFM
);
$editForm
.
find
(
'
form
'
)
.
attr
(
'
action
'
,
`
${
postUrl
}
?html=true`
)
.
attr
(
'
data-remote
'
,
'
true
'
);
$editForm
.
find
(
'
form
'
).
attr
(
'
action
'
,
`
${
postUrl
}
?html=true`
).
attr
(
'
data-remote
'
,
'
true
'
);
$editForm
.
find
(
'
.js-form-target-id
'
).
val
(
targetId
);
$editForm
.
find
(
'
.js-form-target-type
'
).
val
(
targetType
);
$editForm
.
find
(
'
.js-note-text
'
)
.
focus
()
.
val
(
originalContent
);
$editForm
.
find
(
'
.js-note-text
'
).
focus
().
val
(
originalContent
);
$editForm
.
find
(
'
.js-md-write-button
'
).
trigger
(
'
click
'
);
$editForm
.
find
(
'
.referenced-users
'
).
hide
();
}
...
...
@@ -1306,9 +1277,7 @@ export default class Notes {
* intrusive.
*/
collapseLongCommitList
()
{
const
systemNotes
=
$
(
'
#notes-list
'
)
.
find
(
'
li.system-note
'
)
.
has
(
'
ul
'
);
const
systemNotes
=
$
(
'
#notes-list
'
).
find
(
'
li.system-note
'
).
has
(
'
ul
'
);
$
.
each
(
systemNotes
,
(
index
,
systemNote
)
=>
{
const
$systemNote
=
$
(
systemNote
);
...
...
@@ -1365,11 +1334,7 @@ export default class Notes {
// There can be CRLF vs LF mismatches if we don't sanitize and compare the same way
const
sanitizedNoteEntityText
=
normalizeNewlines
(
noteEntity
.
note
.
trim
());
const
currentNoteText
=
normalizeNewlines
(
$note
.
find
(
'
.original-note-content
'
)
.
first
()
.
text
()
.
trim
(),
$note
.
find
(
'
.original-note-content
'
).
first
().
text
().
trim
(),
);
return
sanitizedNoteEntityText
!==
currentNoteText
;
}
...
...
@@ -1545,10 +1510,7 @@ export default class Notes {
let
$form
=
$submitBtn
.
parents
(
'
form
'
);
const
$closeBtn
=
$form
.
find
(
'
.js-note-target-close
'
);
const
isDiscussionNote
=
$submitBtn
.
parent
()
.
find
(
'
li.droplab-item-selected
'
)
.
attr
(
'
id
'
)
===
'
discussion
'
;
$submitBtn
.
parent
().
find
(
'
li.droplab-item-selected
'
).
attr
(
'
id
'
)
===
'
discussion
'
;
const
isMainForm
=
$form
.
hasClass
(
'
js-main-target-form
'
);
const
isDiscussionForm
=
$form
.
hasClass
(
'
js-discussion-note-form
'
);
const
isDiscussionResolve
=
$submitBtn
.
hasClass
(
'
js-comment-resolve-button
'
);
...
...
app/assets/javascripts/notes/components/discussion_actions.vue
View file @
07f5bc94
...
...
@@ -77,8 +77,8 @@ export default {
<div
v-if=
"
!hideJumpToNextUnresolvedInThreads &&
discussion.resolvable &&
shouldShowJumpToNextDiscussion
discussion.resolvable &&
shouldShowJumpToNextDiscussion
"
class=
"btn-group discussion-actions ml-sm-2"
>
...
...
app/assets/javascripts/notes/components/note_form.vue
View file @
07f5bc94
...
...
@@ -193,8 +193,7 @@ export default {
},
canSuggest
()
{
return
(
this
.
getNoteableData
.
can_receive_suggestion
&&
(
this
.
line
&&
this
.
line
.
can_receive_suggestion
)
this
.
getNoteableData
.
can_receive_suggestion
&&
this
.
line
&&
this
.
line
.
can_receive_suggestion
);
},
changedCommentText
()
{
...
...
app/assets/javascripts/notifications_dropdown.js
View file @
07f5bc94
...
...
@@ -12,9 +12,7 @@ export default function notificationsDropdown() {
}
const
notificationLevel
=
$
(
this
).
data
(
'
notificationLevel
'
);
const
form
=
$
(
this
)
.
parents
(
'
.notification-form
'
)
.
first
();
const
form
=
$
(
this
).
parents
(
'
.notification-form
'
).
first
();
form
.
find
(
'
.js-notification-loading
'
).
toggleClass
(
'
spinner
'
);
if
(
form
.
hasClass
(
'
no-label
'
))
{
...
...
@@ -29,9 +27,7 @@ export default function notificationsDropdown() {
const
data
=
e
.
detail
[
0
];
if
(
data
.
saved
)
{
$
(
e
.
currentTarget
)
.
closest
(
'
.js-notification-dropdown
'
)
.
replaceWith
(
data
.
html
);
$
(
e
.
currentTarget
).
closest
(
'
.js-notification-dropdown
'
).
replaceWith
(
data
.
html
);
}
else
{
Flash
(
__
(
'
Failed to save new settings
'
),
'
alert
'
);
}
...
...
app/assets/javascripts/packages/details/components/package_files.vue
View file @
07f5bc94
...
...
@@ -90,7 +90,7 @@ export default {
</gl-link>
</
template
>
<
template
#cell(commit)=
"{
item
}"
>
<
template
#cell(commit)=
"{
item
}"
>
<gl-link
:href=
"item.pipeline.project.commit_url"
class=
"gl-text-gray-500"
...
...
app/assets/javascripts/packages/list/components/packages_list_app.vue
View file @
07f5bc94
...
...
@@ -110,7 +110,7 @@ export default {
<template
#description
>
<gl-sprintf
v-if=
"filterQuery"
:message=
"$options.i18n.widenFilters"
/>
<gl-sprintf
v-else
:message=
"$options.i18n.noResults"
>
<template
#noPackagesLink
="
{
content
}">
<template
#noPackagesLink
="
{
content
}">
<gl-link
:href=
"emptyListHelpUrl"
target=
"_blank"
>
{{
content
}}
</gl-link>
</
template
>
</gl-sprintf>
...
...
app/assets/javascripts/pages/profiles/index.js
View file @
07f5bc94
...
...
@@ -4,7 +4,7 @@ import Profile from '~/profile/profile';
document
.
addEventListener
(
'
DOMContentLoaded
'
,
()
=>
{
// eslint-disable-next-line func-names
$
(
document
).
on
(
'
input.ssh_key
'
,
'
#key_key
'
,
function
()
{
$
(
document
).
on
(
'
input.ssh_key
'
,
'
#key_key
'
,
function
()
{
const
$title
=
$
(
'
#key_title
'
);
const
comment
=
$
(
this
)
.
val
()
...
...
app/assets/javascripts/pages/projects/graphs/components/code_coverage.vue
View file @
07f5bc94
...
...
@@ -161,9 +161,7 @@ export default {
<template
#coveragePercentage
>
{{
coveragePercentage
}}
</
template
>
<
template
#percentSymbol
>
%
</
template
>
<
template
#percentSymbol
>
%
</
template
>
</gl-sprintf>
</template>
</gl-area-chart>
...
...
app/assets/javascripts/pages/projects/init_form.js
View file @
07f5bc94
import
ZenMode
from
'
~/zen_mode
'
;
import
GLForm
from
'
~/gl_form
'
;
export
default
function
(
$formEl
)
{
export
default
function
(
$formEl
)
{
new
ZenMode
();
// eslint-disable-line no-new
new
GLForm
(
$formEl
);
// eslint-disable-line no-new
}
app/assets/javascripts/pages/projects/issues/show.js
View file @
07f5bc94
...
...
@@ -16,7 +16,7 @@ import initInviteMemberModal from '~/invite_member/init_invite_member_modal';
import
{
IssuableType
}
from
'
~/issuable_show/constants
'
;
export
default
function
()
{
export
default
function
()
{
const
initialDataEl
=
document
.
getElementById
(
'
js-issuable-app
'
);
const
{
issueType
,
...
issuableData
}
=
parseIssuableData
(
initialDataEl
);
...
...
app/assets/javascripts/pages/projects/merge_requests/creations/new/compare.js
View file @
07f5bc94
...
...
@@ -29,9 +29,7 @@ export default mrNewCompareNode => {
$
(
mrNewCompareNode
).
find
(
'
.js-source-loading
'
),
$
(
mrNewCompareNode
).
find
(
'
.mr_source_commit
'
),
{
ref
:
$
(
mrNewCompareNode
)
.
find
(
"
input[name='merge_request[source_branch]']
"
)
.
val
(),
ref
:
$
(
mrNewCompareNode
).
find
(
"
input[name='merge_request[source_branch]']
"
).
val
(),
},
);
const
updateTargetBranchCommitList
=
()
=>
...
...
@@ -43,9 +41,7 @@ export default mrNewCompareNode => {
target_project_id
:
$
(
mrNewCompareNode
)
.
find
(
"
input[name='merge_request[target_project_id]']
"
)
.
val
(),
ref
:
$
(
mrNewCompareNode
)
.
find
(
"
input[name='merge_request[target_branch]']
"
)
.
val
(),
ref
:
$
(
mrNewCompareNode
).
find
(
"
input[name='merge_request[target_branch]']
"
).
val
(),
},
);
initCompareAutocomplete
(
'
branches
'
,
$dropdown
=>
{
...
...
app/assets/javascripts/pages/projects/merge_requests/init_merge_request_show.js
View file @
07f5bc94
...
...
@@ -8,7 +8,7 @@ import loadAwardsHandler from '~/awards_handler';
import
initInviteMemberTrigger
from
'
~/invite_member/init_invite_member_trigger
'
;
import
initInviteMemberModal
from
'
~/invite_member/init_invite_member_modal
'
;
export
default
function
()
{
export
default
function
()
{
new
ZenMode
();
// eslint-disable-line no-new
initIssuableSidebar
();
initPipelines
();
...
...
app/assets/javascripts/pages/projects/pipeline_schedules/shared/components/interval_pattern_input.vue
View file @
07f5bc94
...
...
@@ -125,7 +125,7 @@ export default {
:data-testid=
"option.value"
>
<gl-sprintf
v-if=
"option.link"
:message=
"option.text"
>
<template
#link
="
{
content
}">
<template
#link
="
{
content
}">
<gl-link
:href=
"option.link"
target=
"_blank"
class=
"gl-font-sm"
>
{{
content
}}
</gl-link>
...
...
app/assets/javascripts/pages/projects/project.js
View file @
07f5bc94
...
...
@@ -18,34 +18,26 @@ export default class Project {
// Ref switcher
if
(
document
.
querySelector
(
'
.js-project-refs-dropdown
'
))
{
Project
.
initRefSwitcher
();
$
(
'
.project-refs-select
'
).
on
(
'
change
'
,
function
()
{
return
$
(
this
)
.
parents
(
'
form
'
)
.
trigger
(
'
submit
'
);
$
(
'
.project-refs-select
'
).
on
(
'
change
'
,
function
()
{
return
$
(
this
).
parents
(
'
form
'
).
trigger
(
'
submit
'
);
});
}
$
(
'
.hide-no-ssh-message
'
).
on
(
'
click
'
,
function
(
e
)
{
$
(
'
.hide-no-ssh-message
'
).
on
(
'
click
'
,
function
(
e
)
{
Cookies
.
set
(
'
hide_no_ssh_message
'
,
'
false
'
);
$
(
this
)
.
parents
(
'
.no-ssh-key-message
'
)
.
remove
();
$
(
this
).
parents
(
'
.no-ssh-key-message
'
).
remove
();
return
e
.
preventDefault
();
});
$
(
'
.hide-no-password-message
'
).
on
(
'
click
'
,
function
(
e
)
{
$
(
'
.hide-no-password-message
'
).
on
(
'
click
'
,
function
(
e
)
{
Cookies
.
set
(
'
hide_no_password_message
'
,
'
false
'
);
$
(
this
)
.
parents
(
'
.no-password-message
'
)
.
remove
();
$
(
this
).
parents
(
'
.no-password-message
'
).
remove
();
return
e
.
preventDefault
();
});
$
(
'
.hide-auto-devops-implicitly-enabled-banner
'
).
on
(
'
click
'
,
function
(
e
)
{
$
(
'
.hide-auto-devops-implicitly-enabled-banner
'
).
on
(
'
click
'
,
function
(
e
)
{
const
projectId
=
$
(
this
).
data
(
'
project-id
'
);
const
cookieKey
=
`hide_auto_devops_implicitly_enabled_banner_
${
projectId
}
`
;
Cookies
.
set
(
cookieKey
,
'
false
'
);
$
(
this
)
.
parents
(
'
.auto-devops-implicitly-enabled-banner
'
)
.
remove
();
$
(
this
).
parents
(
'
.auto-devops-implicitly-enabled-banner
'
).
remove
();
return
e
.
preventDefault
();
});
...
...
@@ -67,7 +59,7 @@ export default class Project {
refLink
.
href
=
'
#
'
;
return
$
(
'
.js-project-refs-dropdown
'
).
each
(
function
()
{
return
$
(
'
.js-project-refs-dropdown
'
).
each
(
function
()
{
const
$dropdown
=
$
(
this
);
const
selected
=
$dropdown
.
data
(
'
selected
'
);
const
fieldName
=
$dropdown
.
data
(
'
fieldName
'
);
...
...
app/assets/javascripts/pages/projects/shared/permissions/components/settings_panel.vue
View file @
07f5bc94
...
...
@@ -354,18 +354,21 @@ export default {
<option
:value=
"visibilityOptions.PRIVATE"
:disabled=
"!visibilityAllowed(visibilityOptions.PRIVATE)"
>
{{
s__
(
'
ProjectSettings|Private
'
)
}}
</option
>
{{
s__
(
'
ProjectSettings|Private
'
)
}}
</option>
<option
:value=
"visibilityOptions.INTERNAL"
:disabled=
"!visibilityAllowed(visibilityOptions.INTERNAL)"
>
{{
s__
(
'
ProjectSettings|Internal
'
)
}}
</option
>
{{
s__
(
'
ProjectSettings|Internal
'
)
}}
</option>
<option
:value=
"visibilityOptions.PUBLIC"
:disabled=
"!visibilityAllowed(visibilityOptions.PUBLIC)"
>
{{
s__
(
'
ProjectSettings|Public
'
)
}}
</option
>
{{
s__
(
'
ProjectSettings|Public
'
)
}}
</option>
</select>
<gl-icon
name=
"chevron-down"
...
...
app/assets/javascripts/pages/projects/tags/index/index.js
View file @
07f5bc94
...
...
@@ -3,10 +3,7 @@ import { initRemoveTag } from '../remove_tag';
document
.
addEventListener
(
'
DOMContentLoaded
'
,
()
=>
{
initRemoveTag
({
onDelete
:
path
=>
{
document
.
querySelector
(
`[data-path="
${
path
}
"]`
)
.
closest
(
'
.js-tag-list
'
)
.
remove
();
document
.
querySelector
(
`[data-path="
${
path
}
"]`
).
closest
(
'
.js-tag-list
'
).
remove
();
},
});
});
app/assets/javascripts/pages/search/show/search.js
View file @
07f5bc94
...
...
@@ -16,16 +16,12 @@ export default class Search {
}
eventListeners
()
{
$
(
document
)
.
off
(
'
keyup
'
,
this
.
searchInput
)
.
on
(
'
keyup
'
,
this
.
searchInput
,
this
.
searchKeyUp
);
$
(
document
).
off
(
'
keyup
'
,
this
.
searchInput
).
on
(
'
keyup
'
,
this
.
searchInput
,
this
.
searchKeyUp
);
$
(
document
)
.
off
(
'
click
'
,
this
.
searchClear
)
.
on
(
'
click
'
,
this
.
searchClear
,
this
.
clearSearchField
.
bind
(
this
));
$
(
'
a.js-search-clear
'
)
.
off
(
'
click
'
,
this
.
clearSearchFilter
)
.
on
(
'
click
'
,
this
.
clearSearchFilter
);
$
(
'
a.js-search-clear
'
).
off
(
'
click
'
,
this
.
clearSearchFilter
).
on
(
'
click
'
,
this
.
clearSearchFilter
);
}
static
submitSearch
()
{
...
...
@@ -42,10 +38,7 @@ export default class Search {
}
clearSearchField
()
{
return
$
(
this
.
searchInput
)
.
val
(
''
)
.
trigger
(
'
keyup
'
)
.
focus
();
return
$
(
this
.
searchInput
).
val
(
''
).
trigger
(
'
keyup
'
).
focus
();
}
// We need to manually follow the link on the anchors
...
...
app/assets/javascripts/pages/users/activity_calendar.js
View file @
07f5bc94
...
...
@@ -42,11 +42,7 @@ function formatTooltipText({ date, count }) {
return
`
${
contribText
}
<br />
${
dateDayName
}
${
dateText
}
`
;
}
const
initColorKey
=
()
=>
d3
.
scaleLinear
()
.
range
([
'
#acd5f2
'
,
'
#254e77
'
])
.
domain
([
0
,
3
]);
const
initColorKey
=
()
=>
d3
.
scaleLinear
().
range
([
'
#acd5f2
'
,
'
#254e77
'
]).
domain
([
0
,
3
]);
export
default
class
ActivityCalendar
{
constructor
(
...
...
@@ -291,10 +287,7 @@ export default class ActivityCalendar {
this
.
colorKey
(
2
),
this
.
colorKey
(
3
),
];
return
d3
.
scaleThreshold
()
.
domain
([
0
,
10
,
20
,
30
])
.
range
(
colorRange
);
return
d3
.
scaleThreshold
().
domain
([
0
,
10
,
20
,
30
]).
range
(
colorRange
);
}
clickDay
(
stamp
)
{
...
...
app/assets/javascripts/pages/users/index.js
View file @
07f5bc94
...
...
@@ -11,9 +11,7 @@ function initUserProfile(action) {
$
(
'
.hide-project-limit-message
'
).
on
(
'
click
'
,
e
=>
{
e
.
preventDefault
();
Cookies
.
set
(
'
hide_project_limit_message
'
,
'
false
'
);
$
(
this
)
.
parents
(
'
.project-limit-message
'
)
.
remove
();
$
(
this
).
parents
(
'
.project-limit-message
'
).
remove
();
});
}
...
...
app/assets/javascripts/pipeline_editor/components/lint/ci_lint_results.vue
View file @
07f5bc94
...
...
@@ -103,7 +103,7 @@ export default {
data-testid=
"ci-lint-status"
>
{{
status
.
text
}}
<gl-sprintf
:message=
"$options.includesText"
>
<template
#code
="
{
content
}">
<template
#code
="
{
content
}">
<code>
{{
content
}}
</code>
...
...
app/assets/javascripts/pipelines/components/graph/job_item.vue
View file @
07f5bc94
...
...
@@ -151,8 +151,7 @@ export default {
:href="detailsPath"
:title="tooltipText"
:class="jobClasses"
class="js-pipeline-graph-job-link qa-job-link menu-item gl-text-gray-900 gl-active-text-decoration-none
gl-focus-text-decoration-none gl-hover-text-decoration-none"
class="js-pipeline-graph-job-link qa-job-link menu-item gl-text-gray-900 gl-active-text-decoration-none gl-focus-text-decoration-none gl-hover-text-decoration-none"
data-testid="job-with-link"
@click.stop="hideTooltips"
@mouseout="hideTooltips"
...
...
app/assets/javascripts/pipelines/components/pipeline_graph/drawing_utils.js
View file @
07f5bc94
...
...
@@ -36,16 +36,10 @@ export const generateLinksData = ({ links }, containerID) => {
// positioned in the center of the job node by adding half the height
// of the job pill.
const
paddingLeft
=
Number
(
window
.
getComputedStyle
(
containerEl
,
null
)
.
getPropertyValue
(
'
padding-left
'
)
.
replace
(
'
px
'
,
''
),
window
.
getComputedStyle
(
containerEl
,
null
).
getPropertyValue
(
'
padding-left
'
).
replace
(
'
px
'
,
''
),
);
const
paddingTop
=
Number
(
window
.
getComputedStyle
(
containerEl
,
null
)
.
getPropertyValue
(
'
padding-top
'
)
.
replace
(
'
px
'
,
''
),
window
.
getComputedStyle
(
containerEl
,
null
).
getPropertyValue
(
'
padding-top
'
).
replace
(
'
px
'
,
''
),
);
const
sourceNodeX
=
sourceNodeCoordinates
.
right
-
containerCoordinates
.
x
-
paddingLeft
;
...
...
app/assets/javascripts/pipelines/components/pipelines_list/pipeline_url.vue
View file @
07f5bc94
...
...
@@ -113,7 +113,7 @@ export default {
)
"
>
<template
#strong
="
{
content
}">
<template
#strong
="
{
content
}">
<b>
{{
content
}}
</b>
</
template
>
</gl-sprintf>
...
...
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