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
Boxiang Sun
gitlab-ce
Commits
322643e7
Commit
322643e7
authored
Dec 18, 2017
by
Annabel Dunstone Gray
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Hide toolbar in markdown preview mode
parent
f7a9ced2
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
25 additions
and
11 deletions
+25
-11
app/assets/javascripts/vue_shared/components/markdown/header.vue
...ets/javascripts/vue_shared/components/markdown/header.vue
+2
-1
app/assets/stylesheets/framework/markdown_area.scss
app/assets/stylesheets/framework/markdown_area.scss
+17
-9
app/controllers/concerns/with_performance_bar.rb
app/controllers/concerns/with_performance_bar.rb
+1
-1
changelogs/unreleased/40063-markdown-editor-improvements.yml
changelogs/unreleased/40063-markdown-editor-improvements.yml
+5
-0
No files found.
app/assets/javascripts/vue_shared/components/markdown/header.vue
View file @
322643e7
...
@@ -72,7 +72,8 @@
...
@@ -72,7 +72,8 @@
Preview
Preview
</a>
</a>
</li>
</li>
<li
class=
"md-header-toolbar"
>
<li
class=
"md-header-toolbar"
:class=
"
{ active: !previewMarkdown }">
<toolbar-button
<toolbar-button
tag=
"**"
tag=
"**"
button-title=
"Add bold text"
button-title=
"Add bold text"
...
...
app/assets/stylesheets/framework/markdown_area.scss
View file @
322643e7
...
@@ -82,8 +82,14 @@
...
@@ -82,8 +82,14 @@
}
}
}
}
.md-header-toolbar
{
.nav-links
{
li
.md-header-toolbar
{
margin-left
:
auto
;
margin-left
:
auto
;
display
:
none
;
&
.active
{
display
:
block
;
}
@media
(
max-width
:
$screen-xs-max
)
{
@media
(
max-width
:
$screen-xs-max
)
{
flex
:
none
;
flex
:
none
;
...
@@ -93,8 +99,10 @@
...
@@ -93,8 +99,10 @@
padding-top
:
$gl-padding-top
;
padding-top
:
$gl-padding-top
;
padding-bottom
:
$gl-padding-top
;
padding-bottom
:
$gl-padding-top
;
}
}
}
}
}
.referenced-users
{
.referenced-users
{
color
:
$gl-text-color
;
color
:
$gl-text-color
;
padding-top
:
10px
;
padding-top
:
10px
;
...
...
app/controllers/concerns/with_performance_bar.rb
View file @
322643e7
...
@@ -6,7 +6,7 @@ module WithPerformanceBar
...
@@ -6,7 +6,7 @@ module WithPerformanceBar
end
end
def
peek_enabled?
def
peek_enabled?
return
true
if
Rails
.
env
.
development?
#
return true if Rails.env.development?
return
false
unless
Gitlab
::
PerformanceBar
.
enabled?
(
current_user
)
return
false
unless
Gitlab
::
PerformanceBar
.
enabled?
(
current_user
)
if
RequestStore
.
active?
if
RequestStore
.
active?
...
...
changelogs/unreleased/40063-markdown-editor-improvements.yml
0 → 100644
View file @
322643e7
---
title
:
Hide markdown toolbar in preview mode
merge_request
:
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