Skip to content

shellhong6/flutter_stretchable_text_view

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Aug 26, 2019
ddca88b · Aug 26, 2019

History

9 Commits
Aug 23, 2019
Aug 23, 2019
Aug 23, 2019
Aug 26, 2019
Aug 23, 2019
Aug 23, 2019
Aug 23, 2019
Aug 23, 2019
Aug 23, 2019
Aug 23, 2019
Aug 23, 2019

Repository files navigation

flutter_stretchable_text_view

a library for stretchable and shrinkable text view.

  • just like the image below:

How to Use

# add this line to your dependencies
flutter_stretchable_text_view: ^1.0.0+1
import 'package:flutter_stretchable_text_view/main.dart';
// simple demo
StretchableTextView(
  text: 'your text...'
)
// complex demo
StretchableTextView(
  maxLines: 4, // default value is 3
  suffix: '......', // default value is ...
  spreadBtn: TextSpan(
    text: 'more', // default value is 更多
    style: TextStyle(
      color: Colors.blueGrey,
    ),
  ),
  textStyle: TextStyle(
    height: 1.2,
    fontSize: 12,
    color: Colors.black,
  ),
  text: 'your text...'
)
  • getting example about flutter app, view: books_app

Show some ❤️ and star the repo to support the project

Releases

No releases published

Packages

No packages published