forked from Nexus/nexus
treewide: use dot shorthands where possible
Now this feature is stable, we should use it. I might have missed some usecases, but these can be added in future commits.
This commit is contained in:
parent
6281c1d13a
commit
d2ec5f035b
67 changed files with 391 additions and 534 deletions
|
|
@ -11,20 +11,20 @@ class CodeBlock extends StatelessWidget {
|
|||
Widget build(BuildContext context) {
|
||||
final theme = Theme.of(context);
|
||||
return ClipRRect(
|
||||
borderRadius: BorderRadius.all(Radius.circular(16)),
|
||||
borderRadius: .all(.circular(16)),
|
||||
child: ColoredBox(
|
||||
color: theme.colorScheme.surfaceContainerHighest,
|
||||
child: IntrinsicWidth(
|
||||
child: Column(
|
||||
children: [
|
||||
Row(
|
||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||
mainAxisAlignment: .spaceBetween,
|
||||
children: [
|
||||
Padding(
|
||||
padding: EdgeInsets.symmetric(horizontal: 8),
|
||||
padding: .symmetric(horizontal: 8),
|
||||
child: Text(
|
||||
lang.substring(0, min(lang.length, 15)),
|
||||
style: TextStyle(fontFamily: "monospace"),
|
||||
style: .new(fontFamily: "monospace"),
|
||||
),
|
||||
),
|
||||
TextButton.icon(
|
||||
|
|
@ -37,13 +37,13 @@ class CodeBlock extends StatelessWidget {
|
|||
ColoredBox(
|
||||
color: theme.colorScheme.surfaceContainerHigh,
|
||||
child: Container(
|
||||
constraints: BoxConstraints(minWidth: 250),
|
||||
padding: EdgeInsets.all(8),
|
||||
constraints: .new(minWidth: 250),
|
||||
padding: .all(8),
|
||||
child: SelectableText(
|
||||
code,
|
||||
minLines: 1,
|
||||
maxLines: 99,
|
||||
style: TextStyle(fontFamily: "monospace"),
|
||||
style: .new(fontFamily: "monospace"),
|
||||
),
|
||||
),
|
||||
),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue