@@ -81,23 +81,24 @@ class DefaultStreamCommandChip extends StatelessWidget {
8181 final effectiveBackgroundColor = chipTheme.backgroundColor ?? defaults.backgroundColor;
8282 final effectiveLabelColor = chipTheme.labelColor ?? defaults.labelColor;
8383 final effectiveIconColor = chipTheme.iconColor ?? defaults.iconColor;
84+ final effectiveMinHeight = chipTheme.minHeight ?? defaults.minHeight;
8485
8586 return Container (
8687 padding: defaults.padding,
8788 decoration: BoxDecoration (
8889 color: effectiveBackgroundColor,
8990 borderRadius: defaults.borderRadius,
9091 ),
91- constraints: const BoxConstraints (minHeight: 24 ),
92+ constraints: BoxConstraints (minHeight: effectiveMinHeight ),
9293 child: Row (
9394 mainAxisSize: MainAxisSize .min,
95+ spacing: defaults.spacing.xxxs,
9496 children: [
9597 Icon (
9698 context.streamIcons.thunder,
9799 size: 12 ,
98100 color: effectiveIconColor,
99101 ),
100- SizedBox (width: defaults.spacing.xxxs),
101102 MediaQuery .withNoTextScaling (
102103 child: Text (
103104 props.label,
@@ -106,8 +107,7 @@ class DefaultStreamCommandChip extends StatelessWidget {
106107 maxLines: 1 ,
107108 ),
108109 ),
109- if (props.onDismiss != null ) ...[
110- SizedBox (width: defaults.spacing.xxxs),
110+ if (props.onDismiss != null )
111111 GestureDetector (
112112 onTap: props.onDismiss,
113113 behavior: HitTestBehavior .opaque,
@@ -121,7 +121,6 @@ class DefaultStreamCommandChip extends StatelessWidget {
121121 ),
122122 ),
123123 ),
124- ],
125124 ],
126125 ),
127126 );
@@ -137,6 +136,7 @@ class _StreamCommandChipDefaults {
137136 late final _colorScheme = _context.streamColorScheme;
138137 late final _textTheme = _context.streamTextTheme;
139138 late final spacing = _context.streamSpacing;
139+ late final _radius = _context.streamRadius;
140140
141141 Color get backgroundColor => _colorScheme.backgroundInverse;
142142
@@ -146,10 +146,12 @@ class _StreamCommandChipDefaults {
146146
147147 TextStyle get labelStyle => _textTheme.metadataEmphasis;
148148
149+ double get minHeight => 24 ;
150+
149151 EdgeInsetsGeometry get padding => EdgeInsets .symmetric (
150152 horizontal: spacing.xs,
151153 vertical: spacing.xxxs,
152154 );
153155
154- BorderRadius get borderRadius => const BorderRadius .all (Radius . circular ( 9999 ) );
156+ BorderRadius get borderRadius => BorderRadius .all (_radius.max );
155157}
0 commit comments