mirror of
https://github.com/foss42/apidash.git
synced 2025-07-04 15:28:20 +08:00
feat: add padding to scripts pane ui
This commit is contained in:
@ -23,17 +23,15 @@ class _ScriptsEditorPaneState extends ConsumerState<ScriptsEditorPane> {
|
|||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
final settings = ref.watch(settingsProvider);
|
final settings = ref.watch(settingsProvider);
|
||||||
return Container(
|
return Padding(
|
||||||
decoration: BoxDecoration(
|
padding: kPt5o10,
|
||||||
borderRadius: BorderRadius.circular(9),
|
|
||||||
color: Theme.of(context).colorScheme.surfaceContainerLowest,
|
|
||||||
),
|
|
||||||
child: CodeTheme(
|
child: CodeTheme(
|
||||||
data: CodeThemeData(
|
data: CodeThemeData(
|
||||||
styles: settings.isDark ? monokaiTheme : xcodeTheme,
|
styles: settings.isDark ? monokaiTheme : xcodeTheme,
|
||||||
),
|
),
|
||||||
child: SingleChildScrollView(
|
child: SingleChildScrollView(
|
||||||
child: CodeField(
|
child: CodeField(
|
||||||
|
minLines: 35,
|
||||||
readOnly: widget.readOnly,
|
readOnly: widget.readOnly,
|
||||||
smartDashesType: SmartDashesType.enabled,
|
smartDashesType: SmartDashesType.enabled,
|
||||||
smartQuotesType: SmartQuotesType.enabled,
|
smartQuotesType: SmartQuotesType.enabled,
|
||||||
@ -50,6 +48,13 @@ class _ScriptsEditorPaneState extends ConsumerState<ScriptsEditorPane> {
|
|||||||
textStyle: kCodeStyle.copyWith(
|
textStyle: kCodeStyle.copyWith(
|
||||||
fontSize: Theme.of(context).textTheme.bodyMedium?.fontSize,
|
fontSize: Theme.of(context).textTheme.bodyMedium?.fontSize,
|
||||||
),
|
),
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
borderRadius: BorderRadius.circular(9),
|
||||||
|
border: Border.all(
|
||||||
|
color: Theme.of(context).colorScheme.surfaceContainerHighest,
|
||||||
|
),
|
||||||
|
color: Theme.of(context).colorScheme.surfaceContainerLowest,
|
||||||
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
Reference in New Issue
Block a user