gradients_button 0.0.1 copy "gradients_button: ^0.0.1" to clipboard
gradients_button: ^0.0.1 copied to clipboard

A Grdient flutter Button package.

Gradient Button #

Gradient button package lets you add a beautiful gradient to a button in your Flutter app.

Installation #

  1. Add the latest version of package to your pubspec.yaml (and rundart pub get):
dependencies:
  gradient_button: ^0.0.1
  1. Import the package and use it in your Flutter App.
import 'package:gradient_button/gradient_button.dart';

Example #

There are a number of properties that you can modify:

  • Button Text
  • width
  • Button Padding
  • Button TextStle
  • gradient (color1 and color2),

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

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      body: Padding(
        padding: const EdgeInsets.all(8.0),
        child: Column(
          mainAxisAlignment: MainAxisAlignment.center,
          children: [
            GradientButtton(
              width: MediaQuery.sizeOf(context).width,
              buttonText: "Continue",
              buttonTextStyle: TextStyle(color: Colors.white, fontSize: 16),
              colors: [Colors.red, Colors.green, Colors.blue],
              buttonPadding: EdgeInsets.symmetric(vertical: 15),
              onTap: () {},
            )
          ],
        ),
      ),
    );
  }
}

Next Goals #

  • ✅ Add more properties to the package..
1
likes
140
points
15
downloads

Publisher

unverified uploader

Weekly Downloads

A Grdient flutter Button package.

Repository (GitHub)
View/report issues

Documentation

API reference

License

BSD-3-Clause (license)

Dependencies

flutter

More

Packages that depend on gradients_button