diff --git a/src/_components/nav.vto b/src/_components/nav.vto
index 12c02cb3..903353e0 100644
--- a/src/_components/nav.vto
+++ b/src/_components/nav.vto
@@ -44,6 +44,10 @@
Browsing
+
+ Themes
+
+
diff --git a/src/_data/facets.json b/src/_data/facets.json
index a3680008..629808d4 100644
--- a/src/_data/facets.json
+++ b/src/_data/facets.json
@@ -69,22 +69,29 @@
"desc": "Import data from Diffuse v3."
},
{
- "url": "themes/webamp/browser/facet/index.html",
- "title": "Webamp / Browser",
+ "url": "themes/winamp/facet/index.html",
+ "title": "Winamp",
+ "category": "Themes",
+ "featured": true,
+ "desc": "Windows 98 inspired theme that uses the Webamp player in combination with Diffuse."
+ },
+ {
+ "url": "themes/winamp/browser/facet/index.html",
+ "title": "Winamp / Browser",
"category": "Browsing",
"featured": true,
"desc": "Collection browser and search."
},
{
- "url": "themes/webamp/configurators/input/facet/index.html",
- "title": "Webamp / Input Configurator",
+ "url": "themes/winamp/configurators/input/facet/index.html",
+ "title": "Winamp / Input Configurator",
"category": "Data",
"featured": true,
"desc": "Add your audio sources."
},
{
- "url": "themes/webamp/configurators/output/facet/index.html",
- "title": "Webamp / Output Configurator",
+ "url": "themes/winamp/configurators/output/facet/index.html",
+ "title": "Winamp / Output Configurator",
"category": "Data",
"featured": true,
"desc": "Manage your data storage."
diff --git a/src/components/orchestrator/process-tracks/worker.js b/src/components/orchestrator/process-tracks/worker.js
index c70dcca0..a9d25f2c 100644
--- a/src/components/orchestrator/process-tracks/worker.js
+++ b/src/components/orchestrator/process-tracks/worker.js
@@ -60,7 +60,7 @@ export async function process({ data, ports }) {
async (promise, track) => {
const acc = await promise;
- if (track.tags && track.stats) {
+ if ((track.tags && track.stats) || track.kind === "placeholder") {
processed++;
$progress.value = { processed, total: tracks.length };
return [...acc, track];
diff --git a/src/themes/webamp/index.vto b/src/themes/webamp/index.vto
deleted file mode 100644
index ebf06fd3..00000000
--- a/src/themes/webamp/index.vto
+++ /dev/null
@@ -1,194 +0,0 @@
----
-layout: layouts/diffuse.vto
-base: ../../
-
-styles:
- - themes/webamp/fonts.css
- - themes/webamp/index.css
----
-
-
-
-
-
-
-
-
-
-
-
- Manage audio inputs
-
-
-
-
-
-
-
- Manage user data
-
-
-
-
-
-
-
- Browse collection
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/src/themes/webamp/98-extra.css b/src/themes/winamp/98-extra.css
similarity index 100%
rename from src/themes/webamp/98-extra.css
rename to src/themes/winamp/98-extra.css
diff --git a/src/themes/webamp/98-vars.css b/src/themes/winamp/98-vars.css
similarity index 100%
rename from src/themes/webamp/98-vars.css
rename to src/themes/winamp/98-vars.css
diff --git a/src/themes/webamp/browser/element.js b/src/themes/winamp/browser/element.js
similarity index 99%
rename from src/themes/webamp/browser/element.js
rename to src/themes/winamp/browser/element.js
index 22a7f3ad..1d1e9267 100644
--- a/src/themes/webamp/browser/element.js
+++ b/src/themes/winamp/browser/element.js
@@ -290,7 +290,7 @@ class Browser extends DiffuseElement {
-
+
diff --git a/src/themes/webamp/browser/facet/index.inline.js b/src/themes/winamp/browser/facet/index.inline.js
similarity index 89%
rename from src/themes/webamp/browser/facet/index.inline.js
rename to src/themes/winamp/browser/facet/index.inline.js
index 6a63a899..0f0a2a79 100644
--- a/src/themes/webamp/browser/facet/index.inline.js
+++ b/src/themes/winamp/browser/facet/index.inline.js
@@ -1,5 +1,5 @@
import foundation from "~/common/foundation.js";
-import BrowserElement from "~/themes/webamp/browser/element.js";
+import BrowserElement from "~/themes/winamp/browser/element.js";
const [out, que, scp, trc] = await Promise.all([
foundation.orchestrator.output(),
diff --git a/src/themes/webamp/common/ui.js b/src/themes/winamp/common/ui.js
similarity index 100%
rename from src/themes/webamp/common/ui.js
rename to src/themes/winamp/common/ui.js
diff --git a/src/themes/webamp/configurators/input/element.js b/src/themes/winamp/configurators/input/element.js
similarity index 99%
rename from src/themes/webamp/configurators/input/element.js
rename to src/themes/winamp/configurators/input/element.js
index 6517ac92..63c04faf 100644
--- a/src/themes/webamp/configurators/input/element.js
+++ b/src/themes/winamp/configurators/input/element.js
@@ -318,10 +318,14 @@ class InputConfig extends DiffuseElement {
};
const existingTracksCol = this.$output.value?.tracks.collection();
- const existingTracks = existingTracksCol?.state === "loaded" ? existingTracksCol.data : [];
+ const existingTracks = existingTracksCol?.state === "loaded"
+ ? existingTracksCol.data
+ : [];
+
await this.$output.value?.tracks.save([...existingTracks, track]);
this.$tab.value = "overview";
+ this.#processSources();
}
/**
@@ -340,10 +344,10 @@ class InputConfig extends DiffuseElement {
render({ html }) {
return html`
-
+
-
+
diff --git a/src/themes/webamp/configurators/input/facet/index.inline.js b/src/themes/winamp/configurators/input/facet/index.inline.js
similarity index 90%
rename from src/themes/webamp/configurators/input/facet/index.inline.js
rename to src/themes/winamp/configurators/input/facet/index.inline.js
index d7d7a600..4b16ffd3 100644
--- a/src/themes/webamp/configurators/input/facet/index.inline.js
+++ b/src/themes/winamp/configurators/input/facet/index.inline.js
@@ -1,5 +1,5 @@
import foundation from "~/common/foundation.js";
-import InputConfigElement from "~/themes/webamp/configurators/input/element.js";
+import InputConfigElement from "~/themes/winamp/configurators/input/element.js";
const [inp, out, pro, sou] = await Promise.all([
foundation.orchestrator.input(),
diff --git a/src/themes/webamp/configurators/output/element.js b/src/themes/winamp/configurators/output/element.js
similarity index 99%
rename from src/themes/webamp/configurators/output/element.js
rename to src/themes/winamp/configurators/output/element.js
index 2ba1fc52..3af4af93 100644
--- a/src/themes/webamp/configurators/output/element.js
+++ b/src/themes/winamp/configurators/output/element.js
@@ -283,10 +283,10 @@ class OutputConfig extends DiffuseElement {
render({ html }) {
return html`
-
+
-
+
diff --git a/src/themes/webamp/configurators/output/facet/index.inline.js b/src/themes/winamp/configurators/output/facet/index.inline.js
similarity index 80%
rename from src/themes/webamp/configurators/output/facet/index.inline.js
rename to src/themes/winamp/configurators/output/facet/index.inline.js
index a35ebea8..40dfa6ed 100644
--- a/src/themes/webamp/configurators/output/facet/index.inline.js
+++ b/src/themes/winamp/configurators/output/facet/index.inline.js
@@ -1,5 +1,5 @@
import foundation from "~/common/foundation.js";
-import OutputConfigElement from "~/themes/webamp/configurators/output/element.js";
+import OutputConfigElement from "~/themes/winamp/configurators/output/element.js";
const out = await foundation.orchestrator.output();
diff --git a/src/themes/webamp/facet.css b/src/themes/winamp/facet.css
similarity index 100%
rename from src/themes/webamp/facet.css
rename to src/themes/winamp/facet.css
diff --git a/src/themes/winamp/facet/index.html b/src/themes/winamp/facet/index.html
new file mode 100644
index 00000000..82c05f00
--- /dev/null
+++ b/src/themes/winamp/facet/index.html
@@ -0,0 +1,142 @@
+
+
+
+
+
+
+
+
+
+
+
+
+ Manage audio inputs
+
+
+
+
+
+
+
+ Manage user data
+
+
+
+
+
+
+
+ Browse collection
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/themes/webamp/index.js b/src/themes/winamp/facet/index.inline.js
similarity index 77%
rename from src/themes/webamp/index.js
rename to src/themes/winamp/facet/index.inline.js
index f4ba2c5a..5804600e 100644
--- a/src/themes/webamp/index.js
+++ b/src/themes/winamp/facet/index.inline.js
@@ -1,37 +1,25 @@
-import "~/components/engine/scope/element.js";
-import "~/components/input/opensubsonic/element.js";
-import "~/components/input/s3/element.js";
-import "~/components/orchestrator/input/element.js";
-import "~/components/orchestrator/output/element.js";
-import "~/components/orchestrator/process-tracks/element.js";
-import "~/components/orchestrator/sources/element.js";
-import "~/components/processor/metadata/element.js";
-
-import * as Input from "~/components/configurator/input/element.js";
-import * as Queue from "~/components/engine/queue/element.js";
-import * as Search from "~/components/processor/search/element.js";
-import * as ScopedTracks from "~/components/orchestrator/scoped-tracks/element.js";
-
-import { component } from "~/common/element.js";
+import foundation from "~/common/foundation.js";
import { effect, untracked } from "~/common/signal.js";
-import "./browser/element.js";
-import "./configurators/input/element.js";
-import "./configurators/output/element.js";
-import "./window/element.js";
-
-import WindowManager from "./window-manager/element.js";
-import WebampElement from "./webamp/element.js";
+import WindowManager from "~/themes/winamp/window-manager/element.js";
+import WebampElement from "~/themes/winamp/webamp/element.js";
/**
* @import {OutputElement} from "~/components/output/types.d.ts"
* @import {Track} from "~/definitions/types.d.ts"
*/
-const input = component(Input);
-const queue = component(Queue);
-const search = component(Search);
-const scopedTracks = component(ScopedTracks);
+const input = await foundation.orchestrator.input();
+const queue = await foundation.engine.queue();
+const scopedTracks = await foundation.orchestrator.scopedTracks();
+
+await foundation.orchestrator.sources();
+await foundation.orchestrator.processTracks({ disableWhenReady: true });
+
+await import("~/themes/winamp/browser/element.js");
+await import("~/themes/winamp/configurators/input/element.js");
+await import("~/themes/winamp/configurators/output/element.js");
+await import("~/themes/winamp/window/element.js");
/** @type {OutputElement | null} */
const output = document.querySelector("#output");
@@ -144,8 +132,8 @@ effect(() => {
const col = output.tracks.collection();
if (col.state !== "loaded") return;
- const fingerprintSearch = search.supplyFingerprint();
- if (fingerprintSearch === undefined) return;
+ // const fingerprintSearch = search.supplyFingerprint();
+ // if (fingerprintSearch === undefined) return;
const fingerprintQueue = queue.supplyFingerprint();
if (fingerprintQueue === undefined) return;
diff --git a/src/themes/webamp/fonts.css b/src/themes/winamp/fonts.css
similarity index 100%
rename from src/themes/webamp/fonts.css
rename to src/themes/winamp/fonts.css
diff --git a/src/themes/webamp/index.css b/src/themes/winamp/index.css
similarity index 100%
rename from src/themes/webamp/index.css
rename to src/themes/winamp/index.css
diff --git a/src/themes/webamp/webamp/element.js b/src/themes/winamp/webamp/element.js
similarity index 100%
rename from src/themes/webamp/webamp/element.js
rename to src/themes/winamp/webamp/element.js
diff --git a/src/themes/webamp/window-manager/element.js b/src/themes/winamp/window-manager/element.js
similarity index 100%
rename from src/themes/webamp/window-manager/element.js
rename to src/themes/winamp/window-manager/element.js
diff --git a/src/themes/webamp/window/element.js b/src/themes/winamp/window/element.js
similarity index 100%
rename from src/themes/webamp/window/element.js
rename to src/themes/winamp/window/element.js