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
a627210a
Commit
a627210a
authored
May 01, 2019
by
GitLab Bot
Browse files
Options
Browse Files
Download
Plain Diff
Automatic merge of gitlab-org/gitlab-ce master
parents
713ce79b
40983f47
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
14 additions
and
6 deletions
+14
-6
app/assets/javascripts/behaviors/copy_to_clipboard.js
app/assets/javascripts/behaviors/copy_to_clipboard.js
+3
-2
app/assets/javascripts/behaviors/markdown/nodes/table_of_contents.js
...javascripts/behaviors/markdown/nodes/table_of_contents.js
+2
-1
app/assets/javascripts/behaviors/preview_markdown.js
app/assets/javascripts/behaviors/preview_markdown.js
+2
-2
app/assets/javascripts/behaviors/quick_submit.js
app/assets/javascripts/behaviors/quick_submit.js
+4
-1
locale/gitlab.pot
locale/gitlab.pot
+3
-0
No files found.
app/assets/javascripts/behaviors/copy_to_clipboard.js
View file @
a627210a
import
$
from
'
jquery
'
;
import
Clipboard
from
'
clipboard
'
;
import
{
sprintf
,
__
}
from
'
~/locale
'
;
function
showTooltip
(
target
,
title
)
{
const
$target
=
$
(
target
);
...
...
@@ -16,7 +17,7 @@ function showTooltip(target, title) {
}
function
genericSuccess
(
e
)
{
showTooltip
(
e
.
trigger
,
'
Copied
'
);
showTooltip
(
e
.
trigger
,
__
(
'
Copied
'
)
);
// Clear the selection and blur the trigger so it loses its border
e
.
clearSelection
();
$
(
e
.
trigger
).
blur
();
...
...
@@ -33,7 +34,7 @@ function genericError(e) {
}
else
{
key
=
'
Ctrl
'
;
}
showTooltip
(
e
.
trigger
,
`Press
${
key
}
-C to copy`
);
showTooltip
(
e
.
trigger
,
sprintf
(
__
(
`Press %{key}-C to copy`
),
{
key
})
);
}
export
default
function
initCopyToClipboard
()
{
...
...
app/assets/javascripts/behaviors/markdown/nodes/table_of_contents.js
View file @
a627210a
/* eslint-disable class-methods-use-this */
import
{
Node
}
from
'
tiptap
'
;
import
{
__
}
from
'
~/locale
'
;
// Transforms generated HTML back to GFM for Banzai::Filter::TableOfContentsFilter
export
default
class
TableOfContents
extends
Node
{
...
...
@@ -22,7 +23,7 @@ export default class TableOfContents extends Node {
priority
:
51
,
},
],
toDOM
:
()
=>
[
'
p
'
,
{
class
:
'
table-of-contents
'
},
'
Table of Contents
'
],
toDOM
:
()
=>
[
'
p
'
,
{
class
:
'
table-of-contents
'
},
__
(
'
Table of Contents
'
)
],
};
}
...
...
app/assets/javascripts/behaviors/preview_markdown.js
View file @
a627210a
...
...
@@ -22,7 +22,7 @@ function MarkdownPreview() {}
// Minimum number of users referenced before triggering a warning
MarkdownPreview
.
prototype
.
referenceThreshold
=
10
;
MarkdownPreview
.
prototype
.
emptyMessage
=
'
Nothing to preview.
'
;
MarkdownPreview
.
prototype
.
emptyMessage
=
__
(
'
Nothing to preview.
'
)
;
MarkdownPreview
.
prototype
.
ajaxCache
=
{};
...
...
@@ -40,7 +40,7 @@ MarkdownPreview.prototype.showPreview = function($form) {
preview
.
text
(
this
.
emptyMessage
);
this
.
hideReferencedUsers
(
$form
);
}
else
{
preview
.
addClass
(
'
md-preview-loading
'
).
text
(
'
Loading...
'
);
preview
.
addClass
(
'
md-preview-loading
'
).
text
(
__
(
'
Loading...
'
)
);
this
.
fetchMarkdownPreview
(
mdText
,
url
,
...
...
app/assets/javascripts/behaviors/quick_submit.js
View file @
a627210a
import
$
from
'
jquery
'
;
import
'
../commons/bootstrap
'
;
import
{
isInIssuePage
}
from
'
../lib/utils/common_utils
'
;
import
{
__
}
from
'
~/locale
'
;
// Quick Submit behavior
//
...
...
@@ -65,7 +66,9 @@ $(document).on(
}
const
$this
=
$
(
this
);
const
title
=
isMac
()
?
'
You can also press ⌘-Enter
'
:
'
You can also press Ctrl-Enter
'
;
const
title
=
isMac
()
?
__
(
'
You can also press ⌘-Enter
'
)
:
__
(
'
You can also press Ctrl-Enter
'
);
$this
.
tooltip
({
container
:
'
body
'
,
...
...
locale/gitlab.pot
View file @
a627210a
...
...
@@ -3299,6 +3299,9 @@ msgstr ""
msgid "ConvDev Index"
msgstr ""
msgid "Copied"
msgstr ""
msgid "Copy %{http_label} clone URL"
msgstr ""
...
...
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