StyledText.from constructor

StyledText.from(
  1. _TextWithAttr fragment
)

Implementation

factory StyledText.from(_TextWithAttr fragment) {
  return StyledText(
    fragment.text,
    fgColor: fragment.fg?.rgb?.toList(),
    bgColor: fragment.bg?.rgb?.toList(),
    bold: fragment.bold == true,
  );
}