From e4d978965e1249fa61da8e42f679fb85db872e57 Mon Sep 17 00:00:00 2001 From: "Danilo M." Date: Wed, 18 Nov 2026 14:12:55 +0100 Subject: feat(xbox): profile background behind profile and consoles Xbox's profile background is the gamerpic blurred. The tab shows it behind the profile and console cards, greyscale and multiplied over the UDT accent under a base fade, so the theme keeps every colour. Co-Authored-By: Claude Opus 5.5 --- static/modules/xbox.js | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'static/modules') diff --git a/static/modules/xbox.js b/static/modules/xbox.js index ddfb252..7c569ed 100644 --- a/static/modules/xbox.js +++ b/static/modules/xbox.js @@ -244,18 +244,23 @@ function render(box, st) { box.textContent = ""; const p = st.profile ?? {}; const head = h("div", "xb-head"); + // Xbox's profile background is the gamerpic blurred; here only its light and shade, tinted by UDT, + // behind the profile and the consoles. + const hero = h("div", "xb-hero"); + if (p.pic) hero.style.setProperty("--xb-bg", `url(${JSON.stringify(p.pic)})`); const who = h("div", "xb-who"); who.append(h("div", "xb-tag", p.gamertag ?? ""), h("div", "xb-pres", presenceLine(st))); head.append(img(p.pic, "xb-pic"), who, h("div", "xb-score num", `${p.gamerscore ?? 0} G`)); - box.append(head); - if (st.stale) box.append(h("div", "xb-stale", "Xbox Live is not answering; this is the last data.")); + hero.append(head); + if (st.stale) hero.append(h("div", "xb-stale", "Xbox Live is not answering; this is the last data.")); const top = h("div", "xb-top"); if (st.playing) top.append(nowPlaying(st)); for (const c of st.consoles ?? []) top.append(consoleCard(c, st.apps?.[c.id])); if (!st.consoles?.length && st.reason?.startsWith("consoles")) { top.append(h("div", "xb-stale", "Console control is unavailable: Xbox Live refused the console list.")); } - box.append(top); + hero.append(top); + box.append(hero); box.append(h("div", "xb-section", "Games")); const games = h("div", "xb-games"); -- cgit v1.2.3