Skip to content

Commit 16eb0d5

Browse files
content: add border radius for code blocks
matching the web frontend
1 parent b069c72 commit 16eb0d5

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

lib/widgets/content.dart

+4-2
Original file line numberDiff line numberDiff line change
@@ -273,7 +273,8 @@ class CodeBlock extends StatelessWidget {
273273
color: Colors.white,
274274
border: Border.all(
275275
width: 1,
276-
color: const HSLColor.fromAHSL(0.15, 0, 0, 0).toColor())),
276+
color: const HSLColor.fromAHSL(0.15, 0, 0, 0).toColor()),
277+
borderRadius: BorderRadius.circular(4)),
277278
child: SingleChildScrollViewWithScrollbar(
278279
scrollDirection: Axis.horizontal,
279280
child: Text(text, style: _kCodeBlockStyle)));
@@ -296,7 +297,8 @@ class CodeBlockHighlighted extends StatelessWidget {
296297
color: Colors.white,
297298
border: Border.all(
298299
width: 1,
299-
color: const HSLColor.fromAHSL(0.15, 0, 0, 0).toColor())),
300+
color: const HSLColor.fromAHSL(0.15, 0, 0, 0).toColor()),
301+
borderRadius: BorderRadius.circular(4)),
300302
child: SingleChildScrollViewWithScrollbar(
301303
scrollDirection: Axis.horizontal,
302304
child: Text.rich(_builder.build())));

0 commit comments

Comments
 (0)