renderToString method
Render this item to a display string.
Implementation
String renderToString() => switch (this) {
_TextStatusItem(:final text) => text,
_KeyHintStatusItem(:final key, :final action) => '$key $action',
_ProgressStatusItem(:final current, :final total) => _progressText(
current,
total,
),
_SpinnerStatusItem(:final frameIndex) =>
_spinnerFrames[frameIndex % _spinnerFrames.length],
_SpacerStatusItem() => '',
_WidgetStatusItem() => '',
};