type_text 1.0.5 copy "type_text: ^1.0.5" to clipboard
type_text: ^1.0.5 copied to clipboard

A simple flutter widget that writes your texts like a typewriter.

Type Text #

showcase

A simple flutter widget that writes your texts like a typewriter.

Text(
    """Lorem ipsum dolor sit amet, consectetur adipiscing elit. 
    Sed at scelerisque dui, ut tristique neque. 
    Sed feugiat quis lacus non venenatis. 
    Sed ultricies tellus nunc.""",
    style: TextStyle(fontSize: 36),
)

Just change your Text widget into a TypeText widget and provide a Duration field.

TypeText(
    """Lorem ipsum dolor sit amet, consectetur adipiscing elit. 
    Sed at scelerisque dui, ut tristique neque. 
    Sed feugiat quis lacus non venenatis. 
    Sed ultricies tellus nunc.""",
    duration: const Duration(seconds: 5),
    style: TextStyle(fontSize: 36),
    onType: (progress) {
        
    },
    //You can use all the other Text widget fields
)

Or you can use it with a RichText.

TypeRichText(
    text: const TextSpan(
    text: 'Hello ',
    style: TextStyle(
        color: Colors.black,
    ),
    children: <TextSpan>[
        TextSpan(
        text: 'bold',
        style: TextStyle(
            fontWeight: FontWeight.bold, color: Colors.red),
        ),
        TextSpan(
        text: ' world!',
        style: TextStyle(color: Colors.blue),
        ),
    ],
    ),
    duration: const Duration(seconds: 1),
    onType: (progress) {
    debugPrint("Rich text %${(progress * 100).toStringAsFixed(0)} completed.");
    },
)
6
likes
150
points
98
downloads

Publisher

unverified uploader

Weekly Downloads

A simple flutter widget that writes your texts like a typewriter.

Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (license)

Dependencies

flutter

More

Packages that depend on type_text