headerBand static method
ShapePart
headerBand(
- String slotId, {
- String text = '',
- double extent = 40,
- DiagramColor fill = const DiagramColor(0xFFEAF1FF),
- DiagramColor? stroke,
- ShapePart? child,
A fixed-height, square-cornered band with a single-line slotId title,
or a custom child instead of the title.
Implementation
static ShapePart headerBand(
String slotId, {
String text = '',
double extent = 40,
DiagramColor fill = const DiagramColor(0xFFEAF1FF),
DiagramColor? stroke,
ShapePart? child,
}) => ShapeSized(
extent: extent,
child: ShapeSurface(
style: ShapeStyle(
fill: fill,
stroke: stroke ?? const ShapeStyle().stroke,
cornerRadius: 0,
strokeWidth: 1,
),
child:
child ??
ShapeText(
slotId,
text: text,
textType: PlainTextDefinition(maxLines: 1),
),
),
);