- Volksmusik
- Rund um die Uhr.
-
-
+
+ diff --git a/public/assets/stage_folx_v2.png b/public/assets/stage_folx_v2.png new file mode 100644 index 0000000..34566b8 Binary files /dev/null and b/public/assets/stage_folx_v2.png differ diff --git a/public/ds/fonts/Geog-BdIt.otf b/public/ds/fonts/Geog-BdIt.otf new file mode 100644 index 0000000..b21aa12 Binary files /dev/null and b/public/ds/fonts/Geog-BdIt.otf differ diff --git a/public/ds/fonts/Geog-LgIt.otf b/public/ds/fonts/Geog-LgIt.otf new file mode 100644 index 0000000..c0d43c6 Binary files /dev/null and b/public/ds/fonts/Geog-LgIt.otf differ diff --git a/public/ds/fonts/Geog-MdIt.otf b/public/ds/fonts/Geog-MdIt.otf new file mode 100644 index 0000000..3ce822e Binary files /dev/null and b/public/ds/fonts/Geog-MdIt.otf differ diff --git a/public/ds/fonts/Geog-RgIt.otf b/public/ds/fonts/Geog-RgIt.otf new file mode 100644 index 0000000..fdd00c7 Binary files /dev/null and b/public/ds/fonts/Geog-RgIt.otf differ diff --git a/public/ds/fonts/Geog-SbIt.otf b/public/ds/fonts/Geog-SbIt.otf new file mode 100644 index 0000000..4b1e25a Binary files /dev/null and b/public/ds/fonts/Geog-SbIt.otf differ diff --git a/public/ds/fonts/Geog-ThIt.otf b/public/ds/fonts/Geog-ThIt.otf new file mode 100644 index 0000000..88da47c Binary files /dev/null and b/public/ds/fonts/Geog-ThIt.otf differ diff --git a/public/ds/fonts/Geog-UlIt.otf b/public/ds/fonts/Geog-UlIt.otf new file mode 100644 index 0000000..10fd619 Binary files /dev/null and b/public/ds/fonts/Geog-UlIt.otf differ diff --git a/public/ds/fonts/Geogtq-Bd.otf b/public/ds/fonts/Geogtq-Bd.otf new file mode 100644 index 0000000..53b6778 Binary files /dev/null and b/public/ds/fonts/Geogtq-Bd.otf differ diff --git a/public/ds/fonts/Geogtq-Lg.otf b/public/ds/fonts/Geogtq-Lg.otf new file mode 100644 index 0000000..d226940 Binary files /dev/null and b/public/ds/fonts/Geogtq-Lg.otf differ diff --git a/public/ds/fonts/Geogtq-Md.otf b/public/ds/fonts/Geogtq-Md.otf new file mode 100644 index 0000000..7e9c51d Binary files /dev/null and b/public/ds/fonts/Geogtq-Md.otf differ diff --git a/public/ds/fonts/Geogtq-Rg.otf b/public/ds/fonts/Geogtq-Rg.otf new file mode 100644 index 0000000..220a57a Binary files /dev/null and b/public/ds/fonts/Geogtq-Rg.otf differ diff --git a/public/ds/fonts/Geogtq-Sb.otf b/public/ds/fonts/Geogtq-Sb.otf new file mode 100644 index 0000000..6bc8611 Binary files /dev/null and b/public/ds/fonts/Geogtq-Sb.otf differ diff --git a/public/ds/fonts/Geogtq-Th.otf b/public/ds/fonts/Geogtq-Th.otf new file mode 100644 index 0000000..10379bf Binary files /dev/null and b/public/ds/fonts/Geogtq-Th.otf differ diff --git a/public/ds/fonts/Geogtq-Ul.otf b/public/ds/fonts/Geogtq-Ul.otf new file mode 100644 index 0000000..7eb7c06 Binary files /dev/null and b/public/ds/fonts/Geogtq-Ul.otf differ diff --git a/public/ds/fonts/fonts.css b/public/ds/fonts/fonts.css new file mode 100644 index 0000000..d601719 --- /dev/null +++ b/public/ds/fonts/fonts.css @@ -0,0 +1,16 @@ +/* Geograph (Geogtq) — official brand typeface */ +@font-face { font-family: 'Geograph'; src: url('Geogtq-Ul.otf') format('opentype'); font-weight: 200; font-style: normal; font-display: swap; } +@font-face { font-family: 'Geograph'; src: url('Geogtq-Th.otf') format('opentype'); font-weight: 300; font-style: normal; font-display: swap; } +@font-face { font-family: 'Geograph'; src: url('Geogtq-Lg.otf') format('opentype'); font-weight: 400; font-style: normal; font-display: swap; } +@font-face { font-family: 'Geograph'; src: url('Geogtq-Rg.otf') format('opentype'); font-weight: 500; font-style: normal; font-display: swap; } +@font-face { font-family: 'Geograph'; src: url('Geogtq-Md.otf') format('opentype'); font-weight: 600; font-style: normal; font-display: swap; } +@font-face { font-family: 'Geograph'; src: url('Geogtq-Sb.otf') format('opentype'); font-weight: 700; font-style: normal; font-display: swap; } +@font-face { font-family: 'Geograph'; src: url('Geogtq-Bd.otf') format('opentype'); font-weight: 800; font-style: normal; font-display: swap; } + +@font-face { font-family: 'Geograph'; src: url('Geog-UlIt.otf') format('opentype'); font-weight: 200; font-style: italic; font-display: swap; } +@font-face { font-family: 'Geograph'; src: url('Geog-ThIt.otf') format('opentype'); font-weight: 300; font-style: italic; font-display: swap; } +@font-face { font-family: 'Geograph'; src: url('Geog-LgIt.otf') format('opentype'); font-weight: 400; font-style: italic; font-display: swap; } +@font-face { font-family: 'Geograph'; src: url('Geog-RgIt.otf') format('opentype'); font-weight: 500; font-style: italic; font-display: swap; } +@font-face { font-family: 'Geograph'; src: url('Geog-MdIt.otf') format('opentype'); font-weight: 600; font-style: italic; font-display: swap; } +@font-face { font-family: 'Geograph'; src: url('Geog-SbIt.otf') format('opentype'); font-weight: 700; font-style: italic; font-display: swap; } +@font-face { font-family: 'Geograph'; src: url('Geog-BdIt.otf') format('opentype'); font-weight: 800; font-style: italic; font-display: swap; } diff --git a/src/server.js b/src/server.js index 6ba07fe..f3c462c 100644 --- a/src/server.js +++ b/src/server.js @@ -116,6 +116,46 @@ app.get('/stream/:n/variant/:filename', (req, res) => { res.redirect(302, url); }); +// Now-Playing proxy: reads master.biba.live AirPlay monitor, maps Folx TV current item. +// song -> title (artist - title) +// spot+GENIUS-> "GENIUS" +// spot -> "Werbung" +// jingle/animation -> skipped (label null; client keeps last song) +const NOWPLAYING_URL = process.env.NOWPLAYING_URL || 'https://master.biba.live/api/live'; +const NOWPLAYING_STATION = process.env.NOWPLAYING_STATION || 'folx_tv'; + +function mapNowPlaying(np) { + if (!np) return { kind: 'none', label: null }; + const type = (np.play_type || '').toLowerCase(); + const camp = (np.campaign || '').toUpperCase(); + if (type === 'song') { + const artist = (np.artist || '').trim(); + const title = (np.display_title || np.title || '').trim(); + const label = artist ? `${artist} — ${title}` : title; + return { kind: 'song', label, artist, title, started_at: np.started_at }; + } + if (type === 'spot') { + if (camp === 'GENIUS') return { kind: 'genius', label: 'GENIUS', started_at: np.started_at }; + return { kind: 'werbung', label: 'Werbung', started_at: np.started_at }; + } + // jingle, animation (PASICA), contribution -> skip + return { kind: 'skip', label: null }; +} + +app.get('/api/now-playing', async (_req, res) => { + try { + const r = await fetch(NOWPLAYING_URL, { headers: { 'User-Agent': 'folx-live/1.0' } }); + if (!r.ok) return res.status(502).json({ ok: false, error: `origin ${r.status}` }); + const arr = await r.json(); + const row = Array.isArray(arr) ? arr.find(x => x.station_slug === NOWPLAYING_STATION) : null; + const mapped = mapNowPlaying(row && row.now_playing); + res.set('Cache-Control', 'no-cache, no-store, must-revalidate'); + res.json({ ok: true, station: NOWPLAYING_STATION, ...mapped }); + } catch (err) { + res.status(502).json({ ok: false, error: err.message }); + } +}); + app.get('/api/health', (_req, res) => { res.json({ ok: true, diff --git a/views/index.ejs b/views/index.ejs index 603814e..fc3d8bc 100644 --- a/views/index.ejs +++ b/views/index.ejs @@ -1,794 +1,187 @@ - +
- -
+