mirror of
https://0xacab.org/sutty/sutty
synced 2024-11-15 06:11:41 +00:00
editor: borrar código usando createObjectURL
está deprecado por Chrome y de todas formas hay cosas que no funcionaban por el content policy. hay algunos lugares en los que se podría arreglar (con MediaStream) pero IMO no tiene sentido
This commit is contained in:
parent
8887932bee
commit
0c844a5c94
1 changed files with 0 additions and 4 deletions
|
@ -259,7 +259,6 @@ const typesWithProperties = {
|
||||||
|
|
||||||
const file = imgFileEl.files[0]
|
const file = imgFileEl.files[0]
|
||||||
|
|
||||||
imgEl.src = URL.createObjectURL(file)
|
|
||||||
imgEl.dataset.editorLoading = true
|
imgEl.dataset.editorLoading = true
|
||||||
uploadFile(file)
|
uploadFile(file)
|
||||||
.then(url => {
|
.then(url => {
|
||||||
|
@ -321,7 +320,6 @@ const typesWithProperties = {
|
||||||
|
|
||||||
const audioEl = figureEl.querySelector('audio')
|
const audioEl = figureEl.querySelector('audio')
|
||||||
|
|
||||||
audioEl.src = URL.createObjectURL(file)
|
|
||||||
audioEl.dataset.editorLoading = true
|
audioEl.dataset.editorLoading = true
|
||||||
uploadFile(file)
|
uploadFile(file)
|
||||||
.then(url => {
|
.then(url => {
|
||||||
|
@ -361,7 +359,6 @@ const typesWithProperties = {
|
||||||
const file = videoFileEl.files[0]
|
const file = videoFileEl.files[0]
|
||||||
|
|
||||||
videoEl.poster = ""
|
videoEl.poster = ""
|
||||||
videoEl.src = URL.createObjectURL(file)
|
|
||||||
videoEl.dataset.editorLoading = true
|
videoEl.dataset.editorLoading = true
|
||||||
uploadFile(file)
|
uploadFile(file)
|
||||||
.then(url => {
|
.then(url => {
|
||||||
|
@ -401,7 +398,6 @@ const typesWithProperties = {
|
||||||
const file = pdfFileEl.files[0]
|
const file = pdfFileEl.files[0]
|
||||||
const pdfEl = figureEl.children[0]
|
const pdfEl = figureEl.children[0]
|
||||||
|
|
||||||
pdfEl.src = URL.createObjectURL(file)
|
|
||||||
pdfEl.dataset.editorLoading = true
|
pdfEl.dataset.editorLoading = true
|
||||||
uploadFile(file)
|
uploadFile(file)
|
||||||
.then(url => {
|
.then(url => {
|
||||||
|
|
Loading…
Reference in a new issue