From e3fb5ca19968eb35e28703ebcd75df70cd58c6b4 Mon Sep 17 00:00:00 2001 From: krwg Date: Fri, 24 Jul 2026 14:44:18 +0300 Subject: [PATCH 1/4] feat: NestUI 1.0 soft skin via floke-kit tokens Appearance toggle switches data-ui-skin while keeping layout and accent; extract appearance settings panel. --- CHANGELOG.md | 1 + main/config.js | 2 + renderer/appearance.js | 9 + renderer/call-window.html | 1 + renderer/group-call-window.html | 1 + renderer/i18n.js | 6 + renderer/index.html | 3 +- renderer/nest-ui.css | 177 ++++++++++++++++++++ renderer/settings-panels/appearance.js | 218 +++++++++++++++++++++++++ renderer/styles.css | 5 + renderer/ui.js | 198 ++-------------------- shared/floke-kit/README.md | 5 + shared/floke-kit/theme-tokens.css | 48 ++++++ 13 files changed, 485 insertions(+), 189 deletions(-) create mode 100644 renderer/nest-ui.css create mode 100644 renderer/settings-panels/appearance.js create mode 100644 shared/floke-kit/README.md create mode 100644 shared/floke-kit/theme-tokens.css diff --git a/CHANGELOG.md b/CHANGELOG.md index 4016074..65a73f2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -18,6 +18,7 @@ Development line **Morse**. No GitHub Release until explicitly cut — see [`doc ### Added +- **NestUI 1.0** — Settings → Appearance toggle for a soft Cultiva-like texture (`data-ui-skin=nest`) via `shared/floke-kit` tokens; layout unchanged; accent preserved. - **Vitest** core suite — UDP announce sign/verify round-trip, TCP line framing, EN/RU i18n key parity (`npm test` in CI). - **NSIS Setup wizard** — network tips page, richer welcome/finish, uninstall optional AppData wipe, publish repo `krwg/blip`. - **Release notes Markdown** — Settings → Updates renders GitHub release bodies (tables, images, links); click a release for a top sheet with the full notes. diff --git a/main/config.js b/main/config.js index 6a0754a..19776ef 100644 --- a/main/config.js +++ b/main/config.js @@ -123,6 +123,8 @@ const DEFAULT_CONFIG = { chatFontScale: 1, + uiSkin: 'pixel', + typingSoundEnabled: false, idleAwayMinutes: 5, diff --git a/renderer/appearance.js b/renderer/appearance.js index 151f71b..ec98401 100644 --- a/renderer/appearance.js +++ b/renderer/appearance.js @@ -122,6 +122,12 @@ export function labelBg(id) { return label === key ? id : label; } +export const UI_SKINS = ['pixel', 'nest']; + +export function normalizeUiSkin(raw) { + return raw === 'nest' ? 'nest' : 'pixel'; +} + export function normalizeCustomAccentHex(raw) { const s = String(raw || '').trim(); if (/^#[0-9A-Fa-f]{6}$/.test(s)) return s.toLowerCase(); @@ -150,11 +156,13 @@ export function applyAppearance(config) { const accent = normalizeAccentId(config?.accentId, config?.themeId); const bg = normalizeBgId(config?.animatedBgId); const effective = resolveEffectiveTheme(mode); + const skin = normalizeUiSkin(config?.uiSkin); html.dataset.themeMode = mode; html.dataset.theme = effective; html.dataset.accent = accent; html.dataset.animatedBg = bg; + html.dataset.uiSkin = skin; delete html.dataset.callWindow; html.dataset.reactiveBg = config?.reactiveBackground === true && bg !== 'none' ? '1' : '0'; @@ -189,6 +197,7 @@ export function applyCallWindowAppearance(config) { html.dataset.animatedBg = 'none'; html.dataset.callWindow = '1'; html.dataset.reactiveBg = '0'; + html.dataset.uiSkin = normalizeUiSkin(config?.uiSkin); applyCustomAccentVars(html, config); syncReducedMotion(config); } diff --git a/renderer/call-window.html b/renderer/call-window.html index ae507f0..655d60b 100644 --- a/renderer/call-window.html +++ b/renderer/call-window.html @@ -7,6 +7,7 @@ BLIP — Call +