yaru_widgets 2.0.0-beta-4 copy "yaru_widgets: ^2.0.0-beta-4" to clipboard
yaru_widgets: ^2.0.0-beta-4 copied to clipboard

discontinuedreplaced by: yaru

Common flutter widgets useful for building desktop and web applications.

example/lib/main.dart

import 'package:connectivity_plus/connectivity_plus.dart';
import 'package:flutter/material.dart';
import 'package:ubuntu_service/ubuntu_service.dart';
import 'package:yaru/yaru.dart';
import 'package:yaru_widgets/yaru_widgets.dart';

import 'example.dart';
import 'theme.dart';

Future<void> main() async {
  await YaruWindowTitleBar.ensureInitialized();

  registerService<Connectivity>(Connectivity.new);
  runApp(
    InheritedYaruVariant(
      child: const Home(),
    ),
  );
}

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

  @override
  Widget build(BuildContext context) {
    return YaruTheme(
      data: YaruThemeData(
        variant: InheritedYaruVariant.of(context),
      ),
      builder: (context, yaru, child) {
        return MaterialApp(
          title: 'Yaru Widgets',
          debugShowCheckedModeBanner: false,
          theme: yaru.theme,
          darkTheme: yaru.darkTheme,
          home: Example.create(context),
        );
      },
    );
  }
}
59
likes
0
points
235
downloads

Publisher

verified publisherubuntu.com

Weekly Downloads

Common flutter widgets useful for building desktop and web applications.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

flutter, window_manager, yaru, yaru_colors, yaru_icons

More

Packages that depend on yaru_widgets