Untitled

 avatar
unknown
dart
3 years ago
833 B
5
Indexable
static Widget buildTextWithOverflowTooltip(
      String fieldText, TextStyle textStyle) {
    return AutoSizeText(
      fieldText,
      maxLines: 1,
      maxFontSize: textStyle.fontSize!,
      minFontSize: textStyle.fontSize!,
      style: textStyle,
      overflowReplacement: Tooltip(
        decoration: BoxDecoration(
          color: const Color.fromRGBO(20, 20, 20, 1),
          border: Border.all(
            color: const Color.fromRGBO(53, 53, 53, 1),
          ),
          borderRadius: const BorderRadius.all(
            Radius.circular(4),
          ),
        ),
        textStyle: SharedStyles.defaultWhiteText,
        verticalOffset: 10,
        message: fieldText,
        child: Text(
          fieldText,
          overflow: TextOverflow.ellipsis,
          style: textStyle,
        ),
      ),
    );
  }
Editor is loading...