Files
plezy/test/test_helpers/theme.dart
edde746 5fe1e6dc65 refactor(ui): delete unwired log output, dead notifier filters, and never-passed widget params
MemoryLogOutput extended LogOutput but was never wired as a Logger output (storage happens in the printer); DeletionNotifier/WatchStateNotifier's forServer/forItem filtered streams and WatchStateEvent.mediaType had no production consumers (tests now filter .stream directly); context.hiddenLibraries/profileSettings and toPlexUrl had zero call sites; MonoTokens.splashFactory was never read; OptimizedMediaImage's enableTranscoding/cacheKey chains, FocusableMediaCard.width/height/forceGridMode, TvBrowseRail's constant-zero gap functions, and media_image_helper's scaleFactor were never varied by any caller. The sha1 LRU stays (rebuild-hot artwork URLs); TvRailTrailing.none and the mono-theme copyWith stay live (lerp delegates to copyWith). Also carries the MusicPlayContext.id argument drops in the music screens and remaining sweep test updates.
2026-08-17 19:02:25 +02:00

45 lines
1.2 KiB
Dart

import 'package:flutter/material.dart';
import 'package:plezy/theme/mono_tokens.dart';
/// Default [MonoTokens] for widget tests: production-shaped metrics with
/// 1ms animations, so a single `pump` settles the tree.
///
/// Use as `ThemeData(extensions: const [testMonoTokens])`.
const testMonoTokens = MonoTokens(
radiusSm: 8,
radiusMd: 12,
radiusLg: 20,
radiusXs: 5,
groupGap: 2,
space: 8,
fast: Duration(milliseconds: 1),
normal: Duration(milliseconds: 1),
slow: Duration(milliseconds: 1),
expressive: Duration(milliseconds: 1),
bg: Colors.black,
surface: Colors.black,
outline: Colors.white24,
text: Colors.white,
textMuted: Colors.white70,
);
/// [testMonoTokens] with realistic animation durations, for tests that step
/// through intermediate frames instead of settling straight to the end state.
const testMonoTokensAnimated = MonoTokens(
radiusSm: 4,
radiusMd: 8,
radiusLg: 20,
radiusXs: 5,
groupGap: 2,
space: 8,
fast: Duration(milliseconds: 100),
normal: Duration(milliseconds: 200),
slow: Duration(milliseconds: 300),
expressive: Duration(milliseconds: 300),
bg: Colors.black,
surface: Color(0xFF111111),
outline: Color(0xFF333333),
text: Colors.white,
textMuted: Color(0xFFAAAAAA),
);