feat(showcase): init video background

This commit is contained in:
Haoyu Xu
2023-12-30 16:24:55 -05:00
parent 2302db45ae
commit cdd12a3d68
2 changed files with 16 additions and 0 deletions

View File

@@ -359,6 +359,16 @@ export default class Settings {
window.music.resetMusic()
}
setVideoFromWE(url) {
const type = url.split(".").pop()
document.getElementById("custom_video_background_clear").disabled = false
}
resetVideo() {
document.getElementById("custom_video_background").value = ""
document.getElementById("custom_video_background_clear").disabled = true
}
#insertHTML() {
this.#el.innerHTML = `
<div>
@@ -410,6 +420,11 @@ export default class Settings {
<input type="file" id="custom_background" accept="image/*"/>
<button type="button" disabled id="custom_background_clear" disabled>Clear</button>
</div>
<div>
<label for="custom_video_background"> Custom Video Background (Store Locally)</label>
<input type="file" id="custom_video_background" accept="video/*"/>
<button type="button" disabled id="custom_video_background_clear" disabled>Clear</button>
</div>
</div>
<div>
<label for="voice">Voice</label>