chip_radio_button 1.1.1 copy "chip_radio_button: ^1.1.1" to clipboard
chip_radio_button: ^1.1.1 copied to clipboard

Refresh look of radio button.

example/lib/main.dart

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

void main() => runApp(MyApp());

class MyApp extends StatelessWidget {
  // This widget is the root of your application.
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Flutter Hello World',
      home: MyHomePage(),
    );
  }
}

class MyHomePage extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        // The title text which will be shown on the action bar
        title: Text("Chips Demo"),
      ),
      body: Container(
        margin: EdgeInsets.symmetric(horizontal: 20, vertical: 40),
        height: double.infinity,
        child: ChipsFilter(
          selected: 1, // Select the second filter as default
          filters: [
            Filter(label: "A - Z", icon: Icons.assessment),
            Filter(label: "H - L", icon: Icons.ac_unit),
            Filter(label: "Reverse", icon: Icons.all_inclusive),
            Filter(label: "A - Z", icon: Icons.assessment),
            Filter(label: "H - L", icon: Icons.ac_unit),
            Filter(label: "Reverse", icon: Icons.all_inclusive),
          ],
          onTap: (index) {
            print('Index ' + index.toString());
          },
        ),
      ),
    );
  }
}
2
likes
0
pub points
52%
popularity

Publisher

unverified uploader

Refresh look of radio button.

Homepage

License

unknown (license)

Dependencies

flutter

More

Packages that depend on chip_radio_button