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
Tatuya Kamada
gitlab-ce
Commits
d0c5ac4a
Commit
d0c5ac4a
authored
Mar 09, 2016
by
Florent Baldino
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Cache only last response in markdown preview
parent
af24645d
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
3 deletions
+7
-3
app/assets/javascripts/markdown_preview.js.coffee
app/assets/javascripts/markdown_preview.js.coffee
+2
-2
app/views/help/_shortcuts.html.haml
app/views/help/_shortcuts.html.haml
+5
-1
No files found.
app/assets/javascripts/markdown_preview.js.coffee
View file @
d0c5ac4a
...
@@ -25,7 +25,7 @@ class @MarkdownPreview
...
@@ -25,7 +25,7 @@ class @MarkdownPreview
renderMarkdown
:
(
text
,
success
)
->
renderMarkdown
:
(
text
,
success
)
->
return
unless
window
.
markdown_preview_path
return
unless
window
.
markdown_preview_path
return
success
(
@
ajaxCache
[
text
])
if
@
ajaxCache
[
text
]
return
success
(
@
ajaxCache
.
response
)
if
text
==
@
ajaxCache
.
text
$
.
ajax
$
.
ajax
type
:
'POST'
type
:
'POST'
...
@@ -33,7 +33,7 @@ class @MarkdownPreview
...
@@ -33,7 +33,7 @@ class @MarkdownPreview
data
:
{
text
:
text
}
data
:
{
text
:
text
}
dataType
:
'json'
dataType
:
'json'
success
:
(
response
)
=>
success
:
(
response
)
=>
@
ajaxCache
[
text
]
=
response
@
ajaxCache
=
text
:
text
,
response
:
response
success
(
response
)
success
(
response
)
hideReferencedUsers
:
(
form
)
->
hideReferencedUsers
:
(
form
)
->
...
...
app/views/help/_shortcuts.html.haml
View file @
d0c5ac4a
...
@@ -24,7 +24,11 @@
...
@@ -24,7 +24,11 @@
%td
Show this dialog
%td
Show this dialog
%tr
%tr
%td
.shortcut
%td
.shortcut
-
if
browser
.
mac?
.key
ctrl
⌘
p
-
else
.key
ctrl shift p
.key
ctrl shift p
%td
Toggle Markdown preview
%td
Toggle Markdown preview
%tbody
%tbody
%tr
%tr
...
...
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