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
Léo-Paul Géneau
gitlab-ce
Commits
5104098f
Commit
5104098f
authored
Jun 15, 2018
by
Isaac Smith
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix #47796 "Web IDE autocomplete should be disabled in markdown files"
parent
15ad1a97
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
25 additions
and
0 deletions
+25
-0
app/assets/javascripts/ide/lib/editor_options.js
app/assets/javascripts/ide/lib/editor_options.js
+1
-0
changelogs/unreleased/fix-web-ide-disable-markdown-autocomplete.yml
.../unreleased/fix-web-ide-disable-markdown-autocomplete.yml
+5
-0
spec/javascripts/ide/lib/editor_spec.js
spec/javascripts/ide/lib/editor_spec.js
+19
-0
No files found.
app/assets/javascripts/ide/lib/editor_options.js
View file @
5104098f
...
@@ -12,5 +12,6 @@ export const defaultEditorOptions = {
...
@@ -12,5 +12,6 @@ export const defaultEditorOptions = {
export
default
[
export
default
[
{
{
readOnly
:
model
=>
!!
model
.
file
.
file_lock
,
readOnly
:
model
=>
!!
model
.
file
.
file_lock
,
quickSuggestions
:
model
=>
!
(
model
.
language
===
'
markdown
'
),
},
},
];
];
changelogs/unreleased/fix-web-ide-disable-markdown-autocomplete.yml
0 → 100644
View file @
5104098f
---
title
:
Disabled Web IDE autocomplete suggestions for Markdown files.
merge_request
:
author
:
Isaac Smith
type
:
fixed
spec/javascripts/ide/lib/editor_spec.js
View file @
5104098f
...
@@ -263,4 +263,23 @@ describe('Multi-file editor library', () => {
...
@@ -263,4 +263,23 @@ describe('Multi-file editor library', () => {
expect
(
instance
.
isDiffEditorType
).
toBe
(
false
);
expect
(
instance
.
isDiffEditorType
).
toBe
(
false
);
});
});
});
});
it
(
'
sets quickSuggestions to false when language is markdown
'
,
()
=>
{
instance
.
createInstance
(
holder
);
spyOn
(
instance
.
instance
,
'
updateOptions
'
).
and
.
callThrough
();
const
model
=
instance
.
createModel
({
...
file
(),
key
:
'
index.md
'
,
path
:
'
index.md
'
,
});
instance
.
attachModel
(
model
);
expect
(
instance
.
instance
.
updateOptions
).
toHaveBeenCalledWith
({
readOnly
:
false
,
quickSuggestions
:
false
,
});
});
});
});
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