fmt(js): npm run fix on merge (#69048)

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
This commit is contained in:
hermes-seaeye[bot] 2026-07-22 02:30:39 +00:00 committed by GitHub
parent 367810a942
commit 5c4c419307
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 9 additions and 4 deletions

View file

@ -2,7 +2,10 @@ import { beforeEach, describe, expect, it } from 'vitest'
import { $backendThemes, $pendingSkinApply, __resetBackendSkinSync, ingestBackendSkin } from './backend-sync'
const skin = (name: string) => ({ name, colors: { background: '#101020', ui_accent: '#ff33aa', banner_text: '#eeeeee' } })
const skin = (name: string) => ({
name,
colors: { background: '#101020', ui_accent: '#ff33aa', banner_text: '#eeeeee' }
})
describe('ingestBackendSkin', () => {
beforeEach(() => __resetBackendSkinSync())

View file

@ -47,7 +47,7 @@ export function __resetBackendSkinSync(): void {
* change. Built-in names keep the desktop's own palette but can still be applied.
*/
export function ingestBackendSkin(skin: HermesSkin | undefined | null, { apply }: { apply: boolean }): void {
const name = (skin && typeof skin === 'object' ? skin.name ?? '' : '').trim()
const name = (skin && typeof skin === 'object' ? (skin.name ?? '') : '').trim()
if (!name) {
return

View file

@ -68,8 +68,10 @@ export function skinToDesktopTheme(skin: HermesSkin): DesktopTheme | null {
const sidebar = mix(background, foreground, dark ? 0.02 : 0.012)
const accent = ensureContrast(accentSeed, sidebar, ACCENT_MIN_CONTRAST)
const border = pick(colors, ['ui_border', 'banner_border'], background) ?? mix(background, foreground, dark ? 0.16 : 0.14)
const mutedForeground = pick(colors, ['banner_dim', 'session_border'], background) ?? mix(foreground, background, 0.45)
const border =
pick(colors, ['ui_border', 'banner_border'], background) ?? mix(background, foreground, dark ? 0.16 : 0.14)
const mutedForeground =
pick(colors, ['banner_dim', 'session_border'], background) ?? mix(foreground, background, 0.45)
const destructive = pick(colors, ['ui_error'], background) ?? '#e25563'
const palette: DesktopThemeColors = {