Spotify for Fennec OS: native TV client
All checks were successful
release / release (push) Successful in 12m14s

Rust + Slint on sf-ui's Liquid Glass, with the page engine of Netflex TV.
librespot plays (GStreamer on the TV) and makes the TV a Spotify Connect
device; the Web API (token from the session) feeds the pages.

- Sign-in with the phone: a pairing code / QR code (spotify.com/pair,
  OAuth device flow) or picking the TV in the Spotify app (zeroconf).
- Home, search, library, playlist / album / liked songs / podcast pages,
  artist pages, settings; the user's picture top right.
- Now playing: seek, shuffle, repeat, like, synced lyrics, queue.
- package.sh builds x86-64 and aarch64 (Raspberry Pi); the Gitea CI
  releases both on a tag.
- tools/mock_server.py and SPOTIFY_MOCK for work without an account.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Tamas Csikel
2026-11-03 17:23:34 +01:00
commit 3a66e0c7c7
34 changed files with 17083 additions and 0 deletions

66
ui/overlays.slint Normal file
View File

@@ -0,0 +1,66 @@
// Overlays over any page: a picker (Select) and a toast. The page under them
// fades out first (Nothing-under-glass): app.slint dims it while one is open.
import { Tv, GlassRect, GlassPane, GlassMenu, MenuItem, Icon } from "@sf-ui/sf-ui.slint";
// A list to choose from, centred.
export component SelectOverlay inherits Rectangle {
in property <float> alpha;
in property <string> title;
in property <[MenuItem]> items;
in property <int> focus-index;
menu := GlassMenu {
x: (root.width - self.width) / 2;
y: (root.height - self.height) / 2;
width: 640 * Tv.u;
title: root.title;
items: root.items;
focused-index: root.focus-index;
alpha: root.alpha;
accent: #1ed760;
visible-rows: 9;
}
out property <[GlassRect]> glass: menu.glass;
}
// A short message at the bottom ("Elmentve", errors).
export component Toast inherits Rectangle {
in property <string> text;
in property <bool> bad;
out property <float> t: self.text != "" ? 1 : 0;
animate t { duration: 300ms; easing: cubic-bezier(0.3, 1.18, 0.4, 1); }
pane := GlassPane {
x: (root.width - self.width) / 2;
y: root.height - (64 + 96 * root.t) * Tv.u;
width: min(1400 * Tv.u, label.preferred-width + 140 * Tv.u);
height: 80 * Tv.u;
radius: self.height / 2;
frost: 2.4;
tint: Tv.smoke.with-alpha(0.5);
glow: root.bad ? Tv.danger : #ffffff;
lit: 0.3;
alpha: root.t;
HorizontalLayout {
padding-left: 36 * Tv.u;
padding-right: 36 * Tv.u;
spacing: 14 * Tv.u;
alignment: center;
opacity: root.t;
Icon {
y: (parent.height - self.height) / 2;
name: root.bad ? "warning" : "check";
size: 30 * Tv.u;
ink: root.bad ? Tv.danger-ink : Tv.ok-ink;
}
label := Text {
vertical-alignment: center;
text: root.text;
font-size: 25 * Tv.u;
font-weight: 600;
color: Tv.text;
overflow: elide;
}
}
}
out property <[GlassRect]> glass: [pane.glass];
}