artic_widgets 0.0.4 copy "artic_widgets: ^0.0.4" to clipboard
artic_widgets: ^0.0.4 copied to clipboard

A collection of custom widgets for building beautiful and functional Flutter applications.

example/lib/main.dart

import 'package:flutter/material.dart';
import 'package:artic_widgets/artic_widgets.dart'; // Import your package
import 'Buttons/flat_button.dart';
import 'Buttons/circle_hold_button.dart';
import 'Buttons/rectangle_button.dart';
import 'Buttons/circle_button.dart';

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

class MyApp extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      debugShowCheckedModeBanner: false,
      theme: ThemeData(
        primaryColor: Color(0xFF8A2BE2), // Violet color (Purple variant)
        colorScheme: ColorScheme.light(
          primary: Color(0xFF8A2BE2), // Violet color (Purple variant)
          secondary: Color(0xFFE6E6FA), // Lavender color
        ),
        appBarTheme: AppBarTheme(
          backgroundColor: Color(0xFF8A2BE2), // Purple background for AppBar
          titleTextStyle: TextStyle(
            color: Colors.white,
            fontWeight: FontWeight.bold,
            fontSize: 24,
          ),
        ),
        scaffoldBackgroundColor: Color(0xFF070043), // Dark grayish-blue background for Scaffold
        textTheme: TextTheme(
          bodyLarge: TextStyle(
            color: Colors.blue.shade800, // Blue text color
            fontSize: 16,
            fontWeight: FontWeight.w600,
          ),
          titleLarge: TextStyle(
            color: Colors.white, // White text for titles
            fontWeight: FontWeight.bold,
            fontSize: 22,
          ),
        ),
        buttonTheme: ButtonThemeData(
          buttonColor: Color(0xFF8A2BE2), // Violet button color
        ),
        inputDecorationTheme: InputDecorationTheme(
          focusedBorder: OutlineInputBorder(
            borderSide: BorderSide(color: Color(0xFF8A2BE2)), // Purple border color
          ),
        ),
      ),
      home: MyHomePage(),  // Starting page
    );
  }
}

class MyHomePage extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        title: Text("Artic Widgets"),
      ),
      body:
        ExpandableList(sections: [
            Section(title: "Button", items: [
              Item(title: "Flat button", onTap: (){
                Navigator.push(
                  context, // The correct context for navigation
                  MaterialPageRoute(builder: (context) => FlatButtonPage()),
                );
              }),
              Item(title: "Circle Button", onTap: (){
                Navigator.push(
                  context, // The correct context for navigation
                  MaterialPageRoute(builder: (context) => CircleButtonPage()),
                );
              }),
              Item(title: "Circle Hold Button", onTap: (){
                Navigator.push(
                  context, // The correct context for navigation
                  MaterialPageRoute(builder: (context) => CHoldButtonPage()),
                );
              }),
              Item(title: "Square Button", onTap: (){
                Navigator.push(
                  context, // The correct context for navigation
                  MaterialPageRoute(builder: (context) => SquareButtonPage()),
                );
              })
            ])
          ]),


    );
  }
}
0
likes
130
points
32
downloads

Publisher

unverified uploader

Weekly Downloads

A collection of custom widgets for building beautiful and functional Flutter applications.

Homepage

Documentation

API reference

License

MIT (license)

Dependencies

flutter, google_fonts

More

Packages that depend on artic_widgets