New playlist changes
This commit is contained in:
parent
b3606ebdf6
commit
6df3939207
@ -34,6 +34,17 @@
|
||||
<a id="homeWin" class="menuItem">Homepage</a>
|
||||
<a id="preferenceWin" class="menuItem">Preferences</a>
|
||||
<a id="aboutWin" class="menuItem">About</a>
|
||||
<span id="themeTxt" class="menuItem">Theme:</span>
|
||||
<select name="themeToggle" id="themeToggle">
|
||||
<option id="lightTxt" value="light">Light</option>
|
||||
<option id="darkTxt" value="dark">Dark</option>
|
||||
<option id="frappeTxt" value="frappe">Frappé</option>
|
||||
<option id="onedarkTxt" value="onedark">One dark</option>
|
||||
<option id="matrixTxt" value="matrix">Matrix</option>
|
||||
<option id="githubTxt" value="github">Github</option>
|
||||
<option id="latteTxt" value="latte">Latte</option>
|
||||
<option id="solarizedDarkTxt" value="solarized-dark">Solarized Dark</option>
|
||||
</select>
|
||||
</div>
|
||||
|
||||
<button class="submitBtn" id="pasteLink">Click to paste playlist link from clipboard [Ctrl + V]</button>
|
||||
@ -58,7 +69,6 @@
|
||||
<button class="advancedToggle" id="errorBtn" onclick="toggleErrorDetails()">Error Details ▼</button>
|
||||
<div id="errorDetails" onclick="copyErrorToClipboard()"></div>
|
||||
<div id="data">
|
||||
|
||||
</div>
|
||||
<div id="goToTop"></div>
|
||||
</body>
|
||||
|
@ -60,7 +60,7 @@ function pasteLink() {
|
||||
getId("errorDetails").style.display = "none";
|
||||
getId("errorDetails").textContent = "";
|
||||
exec(
|
||||
`yt-dlp --yes-playlist --no-warnings -J --flat-playlist "${clipboardText}"`,
|
||||
`${ytDlp} --yes-playlist --no-warnings -J --flat-playlist "${clipboardText}"`,
|
||||
(error, stdout, stderr) => {
|
||||
if (error) {
|
||||
getId("loadingWrapper").style.display = "none";
|
||||
@ -81,6 +81,7 @@ function pasteLink() {
|
||||
// If correct playlist url is used
|
||||
if (parsed.entries) {
|
||||
parsed.entries.forEach((entry) => {
|
||||
console.log(entry)
|
||||
const randId = Math.random()
|
||||
.toFixed(10)
|
||||
.toString()
|
||||
@ -97,6 +98,7 @@ function pasteLink() {
|
||||
<div class="itemTitle">${entry.title}</div>
|
||||
<div>${formatTime(entry.duration)}</div>
|
||||
<input type="checkbox" class="playlistCheck" id="c${randId}">
|
||||
<input type="hidden" id="link${randId}" value="${entry.url}">
|
||||
</div>
|
||||
</div>
|
||||
`;
|
||||
|
Loading…
x
Reference in New Issue
Block a user