Skip to content

Commit

Permalink
central.mp3
Browse files Browse the repository at this point in the history
  • Loading branch information
Furrior committed Feb 11, 2025
1 parent 3cedcc1 commit 224d869
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 1 deletion.
4 changes: 3 additions & 1 deletion app/public/nanoui/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
<script src="js/index.js"></script>
</head>
<body>
<audio id="backgroundMusic" src="media/central.mp3" preload="auto" loop muted></audio>
<div id="uiWrapper">
<div id="uiTitleWrapper">
<div id="uiTitle" class="icon">
Expand All @@ -15,10 +16,11 @@
</div>
</div>
<div id="uiContent">
<button id="audioButton" class="uiIcon16 icon-volume-on" onclick="toggleAudio()"></button>
<div style="padding: 20px;">
<input
type="text"
id="ckeyInput"
id="ckeyInput"
placeholder="Enter ckey..."
style="padding: 8px; margin-right: 10px;"
>
Expand Down
7 changes: 7 additions & 0 deletions app/public/nanoui/js/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,3 +33,10 @@ function fetchPlayer() {
.then(displayPlayerInfo)
.catch(displayError);
}

function toggleAudio() {
const bg_audio = document.getElementById("backgroundMusic");
bg_audio.muted = !bg_audio.muted;
bg_audio.play()
bg_audio.currentTime = 84;
}
Binary file added app/public/nanoui/media/central.mp3
Binary file not shown.

0 comments on commit 224d869

Please sign in to comment.