advance_expansion_tile 1.0.2 copy "advance_expansion_tile: ^1.0.2" to clipboard
advance_expansion_tile: ^1.0.2 copied to clipboard

1. It allows you to manually collapse, exapnd or toggle expansion tile. It allows you to disable the click

example/lib/main.dart

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

import 'package:flutter/services.dart';
import 'package:advance_expansion_tile/advance_expansion_tile.dart';

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

class MyApp extends StatefulWidget {
  const MyApp({Key? key}) : super(key: key);

  @override
  State<MyApp> createState() => _MyAppState();
}

class _MyAppState extends State<MyApp> {
  ///it needed to manually collapse, exapnd or toggle Expansion tile
  final GlobalKey<AdvanceExpansionTileState> _globalKey = GlobalKey();

  @override
  void initState() {
    super.initState();
  }

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: Scaffold(
        appBar: AppBar(
          title: const Text('Plugin example app'),
        ),
        body: Column(
          children: [
            Padding(
              padding: const EdgeInsets.all(10.0),
              child: AdvanceExpansionTile(
                key: _globalKey,
                title: const Text("Expansion Tile Title"),
                decoration: BoxDecoration(
                    border: Border.all(color: Colors.black),
                    borderRadius: const BorderRadius.all(Radius.circular(10))),
                children: [
                  ClipRRect(
                    borderRadius: const BorderRadius.only(
                      bottomLeft: Radius.circular(10),
                      bottomRight: Radius.circular(10),
                    ),
                    child: Container(
                      height: 50,
                      color: Colors.green,
                    ),
                  ),
                ],
                onTap: () {},
              ),
            ),
          ],
        ),
        floatingActionButton: FloatingActionButton(
          onPressed: () {
            ///toggle expansion tile
            _globalKey.currentState?.toggle();
          },
          child: const Icon(Icons.add),
        ),
      ),
    );
  }
}
10
likes
90
points
376
downloads

Publisher

verified publisherwhizfy.ai

Weekly Downloads

1. It allows you to manually collapse, exapnd or toggle expansion tile. It allows you to disable the click

Repository (GitHub)
View/report issues

Documentation

API reference

License

BSD-3-Clause (license)

Dependencies

flutter, flutter_web_plugins, plugin_platform_interface

More

Packages that depend on advance_expansion_tile