mirror of
https://github.com/He4eT/elseifplayer.git
synced 2026-05-04 17:07:22 +00:00
FileSelector: attach fileName to URL
This commit is contained in:
parent
c48d6ec305
commit
14f9c5be4c
1 changed files with 1 additions and 1 deletions
|
|
@ -4,7 +4,7 @@ export default function ({ emitName, emitURL }) {
|
||||||
const fileInputHandler = ({ target }) => {
|
const fileInputHandler = ({ target }) => {
|
||||||
const file = target.files[0]
|
const file = target.files[0]
|
||||||
emitName(file.name)
|
emitName(file.name)
|
||||||
emitURL(URL.createObjectURL(file))
|
emitURL(`${URL.createObjectURL(file)}#${file.name}`)
|
||||||
target.value = null
|
target.value = null
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue