panels 0.0.3 copy "panels: ^0.0.3" to clipboard
panels: ^0.0.3 copied to clipboard

Panels is a flutter package that aims to provide a set of useful desktop UI panels that can move around, dock and tab like we expect in more robust desktop applications.

example/lib/main.dart

import 'package:flutter/material.dart';
import 'package:panels/panels.dart';
import 'package:panels/themes.dart';

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

class ExampleApplication extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      theme: ThemeData.dark().copyWith(primaryColor: Colors.purpleAccent),
      home: Example(),
    );
  }
}

class Example extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      body: PanelsTheme(
        data: PanelsThemeData(), // FrostedPanelsThemeData()
        child: PanelsManager(children: [MyCustomWidget()]),
      ),
    );
  }
}

class MyCustomWidget extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return Container(
        child: Center(
      child: Column(
        children: [
          Expanded(
            child: Center(
              child: Text("My Custom Widget"),
            ),
          ),
          Expanded(
            child: Center(
              child: MaterialButton(
                color: Theme.of(context).primaryColor,
                onPressed: () {
                  Panels.of(context).addPanel(widget: MyCustomWidget(), title: "Opened From MyCustomWidget()");
                },
                child: Text("Test"),
              ),
            ),
          )
        ],
      ),
    ));
  }
}
30
likes
110
pub points
44%
popularity

Publisher

verified publisherblankstdio.com

Panels is a flutter package that aims to provide a set of useful desktop UI panels that can move around, dock and tab like we expect in more robust desktop applications.

Repository (GitHub)
View/report issues

Documentation

API reference

License

BSD-3-Clause (LICENSE)

Dependencies

flutter

More

Packages that depend on panels