flutter_ellipsis_text 1.0.1 copy "flutter_ellipsis_text: ^1.0.1" to clipboard
flutter_ellipsis_text: ^1.0.1 copied to clipboard

Flutter ellipsis text that makes all lines of text visible by clicking when they cannot be shown.

example/example.dart

import 'package:flutter/material.dart';
import 'package:flutter_ellipsis_text/flutter_ellipsis_text.dart';

void main() {
  runApp(const ExampleApp());
}

class ExampleApp extends StatelessWidget {
  const ExampleApp({super.key});

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Example',
      theme: ThemeData(
        primarySwatch: Colors.blue,
      ),
      home: const ExamplePage(),
    );
  }
}

class ExamplePage extends StatelessWidget {
  const ExamplePage({super.key});

  @override
  Widget build(BuildContext context) {

    return Scaffold(
      appBar: AppBar(
        title: const Text('Example'),
      ),
      body: Center(
        child: Padding(
          padding: const EdgeInsets.all(16.0),
          child: Column(
            mainAxisAlignment: MainAxisAlignment.start,
            children: const <Widget>[
              EllipsisText(
                text: "Lorem Ipsum is simply dummy text of the printing and typesetting industry. "
                    "Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, "
                    "when an unknown printer took a galley of type and scrambled it to make a type specimen book. "
                    "It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged.",
                ellipsis: "..show more",
                maxLines: 2,
              )
            ],
          ),
        ),
      ),
    );
  }
}
3
likes
140
points
76
downloads

Publisher

verified publishertyrannoapartment.com

Weekly Downloads

Flutter ellipsis text that makes all lines of text visible by clicking when they cannot be shown.

Homepage
Repository (GitHub)

Documentation

API reference

License

MIT (license)

Dependencies

flutter

More

Packages that depend on flutter_ellipsis_text