form_floating_action_button 2.1.1 copy "form_floating_action_button: ^2.1.1" to clipboard
form_floating_action_button: ^2.1.1 copied to clipboard

A Floating Action Button that can be used in forms to provide loading and validation feedback

example/lib/main.dart

import 'package:flutter/material.dart';

import 'src/page_form_validate.dart';
import 'src/page_on_validate.dart';

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

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

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

class MyHomePage extends StatelessWidget {
  const MyHomePage({super.key, required this.title});

  final String title;

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        title: Text(title),
      ),
      body: Center(
        child: Column(
          mainAxisAlignment: MainAxisAlignment.center,
          children: <Widget>[
            ElevatedButton(
              onPressed: () {
                Navigator.of(context).push(
                  MaterialPageRoute(
                    builder: (context) {
                      return const PageOnValidate();
                    },
                  ),
                );
              },
              child: const Text('On Validate Example'),
            ),
            const SizedBox(height: 16.0),
            ElevatedButton(
              onPressed: () {
                Navigator.of(context).push(
                  MaterialPageRoute(
                    builder: (context) {
                      return const PageFormValidate();
                    },
                  ),
                );
              },
              child: const Text('Form Validate Example'),
            ),
          ],
        ),
      ),
    );
  }
}
20
likes
160
pub points
64%
popularity

Publisher

verified publisherpeifferinnovations.com

A Floating Action Button that can be used in forms to provide loading and validation feedback

Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (license)

Dependencies

flutter, vector_math

More

Packages that depend on form_floating_action_button