Files
plezy/lib/utils/text_input_diagnostics.dart
T

16 lines
554 B
Dart
Raw Normal View History

2026-05-21 00:42:19 +02:00
import 'app_logger.dart';
import 'platform_detector.dart';
class TextInputDiagnostics {
/// Compile-time switch: run with
/// `--dart-define=PLEZY_TEXT_INPUT_DIAGNOSTICS=true` to enable. Const so the
/// guarded branches (and their log-string interpolation) compile out of
/// every normal build.
static const bool enabled = bool.fromEnvironment('PLEZY_TEXT_INPUT_DIAGNOSTICS');
2026-05-21 00:42:19 +02:00
static void log(String source, String message) {
if (!enabled || !PlatformDetector.isTV()) return;
appLogger.i('TextInputDiag $source: $message');
}
}