From 0a7db3b48cce5f064c20f280e345a8bf1feb5ecb Mon Sep 17 00:00:00 2001 From: "Danilo M." Date: Thu, 29 Oct 2026 10:12:17 +0100 Subject: companion: remove from the tree, archived as tag archive/companion The chibi 2B companion is retired for now. Its last state is kept in the signed tag archive/companion (the commit before this one), so it can be revisited with `git checkout archive/companion`; hypr-theme carries a tag of the same name for its compositor hooks (typing/delete events and the SUPER+\ bind). Removed with it, since nothing else used them: the Companion, phrases and artists settings pages, the five companion prefs in Prefs.qml and Prefs.ready, the wallpaper heart (Admired.qml's list), the assistant's replied() signal and cardTop, and the keybinds reminder's name for the code:49 bind. The design specs and plans under docs/ stay as history. Co-Authored-By: Claude Opus 5.5 --- desktop/modules/companion/ArtistsModule.qml | 67 ----------------------------- 1 file changed, 67 deletions(-) delete mode 100644 desktop/modules/companion/ArtistsModule.qml (limited to 'desktop/modules/companion/ArtistsModule.qml') diff --git a/desktop/modules/companion/ArtistsModule.qml b/desktop/modules/companion/ArtistsModule.qml deleted file mode 100644 index a0d23f4..0000000 --- a/desktop/modules/companion/ArtistsModule.qml +++ /dev/null @@ -1,67 +0,0 @@ -// Copyright (C) 2026 Danilo M. -// -// This program is free software; you can redistribute it and/or modify -// it under the terms of the GNU General Public License version 2 as -// published by the Free Software Foundation. -// -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. - -import QtQuick -import "../.." -import "../../companion/Lines.js" as Lines - -// The lines the companion says when a track by an artist she knows starts, -// matched as a case-insensitive substring of the player's artist. Same -// draft, Save and Reset as PhrasesModule, on Prefs.companionArtists and -// Lines.artists; the page's cls field holds the artist. -Module { - id: am - name: "artists" - label: "Companion artists" - // nf-fa-music, present in Inconsolata Nerd Font. - icon: "\uf001" - settings: true - group: "Companion" - keywords: ["companion", "artist", "music", "song", "track", "line", "say", "2b"] - searchItems: am.shown.map((a, i) => ({ text: a.cls + ": " + a.lines.join(" / "), key: "app:" + i })) - - property var draft: null - property bool resetting: false - readonly property var shown: am.draft ?? Lines.appList(Prefs.companionArtists, Lines.artists) - readonly property bool valid: am.shown.every(a => String(a.cls).trim() !== "" - && (a.lines || []).some(l => String(l).trim() !== "")) - dirty: am.draft !== null - - function edit(list) { am.draft = list; am.resetting = false; } - function reset() { am.draft = Lines.appList(null, Lines.artists); am.resetting = true; } - function save() { - if (am.resetting) Prefs.resetCompanionArtists(); - else Prefs.setCompanionArtists(Lines.toMap(am.draft)); - am.discard(); - } - function discard() { am.draft = null; am.resetting = false; } - - page: Component { - Page { - title: "Companion artists" - actions: Component { - SaveBar { dirty: am.dirty; valid: am.valid; note: "every artist needs a name and a phrase" - onSave: am.save(); onDiscard: am.discard() } - } - PhrasesPage { - width: parent.width - owner: am - intro: "When a track by an artist she knows starts or changes, she says one of their lines at " - + "random, under her 30 s line cooldown. The name matches any part of the player's artist, " - + "ignoring case, so \"daft punk\" also catches \"Daft Punk, Pharrell Williams\". " - + "Save applies at once." - keyHint: "artist, e.g. linkin park" - addText: "Add artist" - saved: Prefs.companionArtists - } - } - } -} -- cgit v1.2.3