mirror of
https://github.com/penpot/penpot.git
synced 2025-06-25 21:56:59 +02:00
Use html5 accept attribute for filter image types on upload forms.
This commit is contained in:
parent
cc53ba68b5
commit
f9366c3146
3 changed files with 3 additions and 0 deletions
|
@ -205,6 +205,7 @@
|
||||||
:multiple true
|
:multiple true
|
||||||
:ref "file-input"
|
:ref "file-input"
|
||||||
:value ""
|
:value ""
|
||||||
|
:accept "image/svg+xml"
|
||||||
:type "file"
|
:type "file"
|
||||||
:on-change on-file-selected}]]))
|
:on-change on-file-selected}]]))
|
||||||
|
|
||||||
|
|
|
@ -206,6 +206,7 @@
|
||||||
:multiple true
|
:multiple true
|
||||||
:ref "file-input"
|
:ref "file-input"
|
||||||
:value ""
|
:value ""
|
||||||
|
:accept "image/jpeg,image/png"
|
||||||
:type "file"
|
:type "file"
|
||||||
:on-change on-file-selected}]])))
|
:on-change on-file-selected}]])))
|
||||||
|
|
||||||
|
|
|
@ -81,6 +81,7 @@
|
||||||
[:span.text "Upload file"]
|
[:span.text "Upload file"]
|
||||||
[:input.upload-image-input
|
[:input.upload-image-input
|
||||||
{:style {:display "none"}
|
{:style {:display "none"}
|
||||||
|
:accept "image/jpeg,image/png"
|
||||||
:type "file"
|
:type "file"
|
||||||
:ref "input"
|
:ref "input"
|
||||||
:on-change on-files-selected}]]]
|
:on-change on-files-selected}]]]
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue