diff --git a/lib/dashbot/widgets/content_renderer.dart b/lib/dashbot/widgets/content_renderer.dart index 43b83ecd..7eaefa9b 100644 --- a/lib/dashbot/widgets/content_renderer.dart +++ b/lib/dashbot/widgets/content_renderer.dart @@ -1,5 +1,6 @@ // lib/dashbot/widgets/content_renderer.dart import 'dart:convert'; +import 'package:apidash_design_system/apidash_design_system.dart'; import 'package:flutter/material.dart'; import 'package:flutter_highlight/flutter_highlight.dart'; import 'package:flutter_highlight/themes/monokai-sublime.dart'; @@ -78,9 +79,8 @@ Widget _renderCodeBlock( color: Theme.of(context).colorScheme.surfaceContainerLow, child: SelectableText( prettyJson, - style: const TextStyle( - fontFamily: 'monospace', - fontSize: 12, + style: kCodeStyle.copyWith( + fontSize: Theme.of(context).textTheme.bodyMedium?.fontSize, ), ), ); @@ -96,9 +96,8 @@ Widget _renderCodeBlock( code, language: language, theme: monokaiSublimeTheme, - textStyle: const TextStyle( - fontFamily: 'monospace', - fontSize: 12, + textStyle: kCodeStyle.copyWith( + fontSize: Theme.of(context).textTheme.bodyMedium?.fontSize, ), ), ); @@ -117,9 +116,8 @@ Widget _renderFallbackCode( color: Theme.of(context).colorScheme.surfaceContainerLow, child: SelectableText( code, - style: const TextStyle( - fontFamily: 'monospace', - fontSize: 12, + style: kCodeStyle.copyWith( + fontSize: Theme.of(context).textTheme.bodyMedium?.fontSize, color: Colors.red, ), ), diff --git a/lib/dashbot/widgets/test_runner_widget.dart b/lib/dashbot/widgets/test_runner_widget.dart index 59aacbdf..ded2d4ef 100644 --- a/lib/dashbot/widgets/test_runner_widget.dart +++ b/lib/dashbot/widgets/test_runner_widget.dart @@ -1,5 +1,6 @@ import 'dart:convert'; import 'package:apidash_core/apidash_core.dart' as http; +import 'package:apidash_design_system/apidash_design_system.dart'; import 'package:flutter/material.dart'; import 'package:flutter/services.dart'; import 'package:flutter_riverpod/flutter_riverpod.dart'; @@ -251,7 +252,7 @@ class _TestRunnerWidgetState extends ConsumerState { width: double.infinity, child: SelectableText( test['command'], - style: const TextStyle(fontFamily: 'monospace'), + style: kCodeStyle, ), ), if (hasResult) ...[