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
6b80d13e
Commit
6b80d13e
authored
Jul 21, 2017
by
Fatih Acet
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
IssueNotesRefactor: Add dropzone required elements and fix dropdown selector.
parent
cbdbd246
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
49 additions
and
12 deletions
+49
-12
app/assets/javascripts/dropzone_input.js
app/assets/javascripts/dropzone_input.js
+2
-2
app/assets/javascripts/vue_shared/components/markdown/toolbar.vue
...ts/javascripts/vue_shared/components/markdown/toolbar.vue
+47
-10
No files found.
app/assets/javascripts/dropzone_input.js
View file @
6b80d13e
...
...
@@ -129,7 +129,7 @@ window.DropzoneInput = (function() {
// removeAllFiles(true) stops uploading files (if any)
// and remove them from dropzone files queue.
$cancelButton
.
on
(
'
click
'
,
(
e
)
=>
{
const
target
=
e
.
target
.
closest
(
'
form
'
).
querySelector
(
'
.div-dropzone
'
);
const
target
=
e
.
target
.
closest
(
'
.js-main-target-
form
'
).
querySelector
(
'
.div-dropzone
'
);
e
.
preventDefault
();
e
.
stopPropagation
();
...
...
@@ -141,7 +141,7 @@ window.DropzoneInput = (function() {
// and add that files to the dropzone files queue again.
// addFile() adds file to dropzone files queue and upload it.
$retryLink
.
on
(
'
click
'
,
(
e
)
=>
{
const
dropzoneInstance
=
Dropzone
.
forElement
(
e
.
target
.
closest
(
'
form
'
).
querySelector
(
'
.div-dropzone
'
));
const
dropzoneInstance
=
Dropzone
.
forElement
(
e
.
target
.
closest
(
'
.js-main-target-
form
'
).
querySelector
(
'
.div-dropzone
'
));
const
failedFiles
=
dropzoneInstance
.
files
;
e
.
preventDefault
();
...
...
app/assets/javascripts/vue_shared/components/markdown/toolbar.vue
View file @
6b80d13e
...
...
@@ -19,15 +19,52 @@
Markdown is supported
</a>
</div>
<button
class=
"toolbar-button markdown-selector"
type=
"button"
tabindex=
"-1"
>
<i
class=
"fa fa-file-image-o toolbar-button-icon"
aria-hidden=
"true"
>
</i>
Attach a file
</button>
<span
class=
"uploading-container"
>
<span
class=
"uploading-progress-container hide"
>
<i
class=
"fa fa-file-image-o toolbar-button-icon"
aria-hidden=
"true"
></i>
<span
class=
"attaching-file-message"
></span>
<span
class=
"uploading-progress"
>
0%
</span>
<span
class=
"uploading-spinner"
>
<i
class=
"fa fa-spinner fa-spin toolbar-button-icon"
aria-hidden=
"true"
></i>
</span>
</span>
<span
class=
"uploading-error-container hide"
>
<span
class=
"uploading-error-icon"
>
<i
class=
"fa fa-file-image-o toolbar-button-icon"
aria-hidden=
"true"
></i>
</span>
<span
class=
"uploading-error-message"
></span>
<button
class=
"retry-uploading-link"
type=
"button"
>
Try again
</button>
or
<button
class=
"attach-new-file markdown-selector"
type=
"button"
>
attach a new file
</button>
</span>
<button
class=
"markdown-selector button-attach-file"
tabindex=
"-1"
type=
"button"
>
<i
class=
"fa fa-file-image-o toolbar-button-icon"
aria-hidden=
"true"
></i>
Attach a file
</button>
<button
class=
"btn btn-default btn-xs hide button-cancel-uploading-files"
type=
"button"
>
Cancel
</button>
</span>
</div>
</
template
>
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