masamune_universal_ui 2.5.22 copy "masamune_universal_ui: ^2.5.22" to clipboard
masamune_universal_ui: ^2.5.22 copied to clipboard

The package provide a universal UI that aims to be written in one code on any platform.

example/lib/main.dart

// Dart imports:

// Flutter imports:
import 'package:flutter/material.dart';

// Package imports:
import 'package:masamune/masamune.dart';
import 'package:masamune_universal_ui/masamune_universal_ui.dart';

final List<MasamuneAdapter> masamuneAdapters = [
  const UniversalMasamuneAdapter()
];

void main() {
  runMasamuneApp(
    masamuneAdapters: masamuneAdapters,
    (adapters) => MasamuneApp(
      home: const UniversalUIPage(),
      title: "Flutter Demo",
      masamuneAdapters: adapters,
      theme: AppThemeData(
        primary: Colors.blue,
      ),
    ),
  );
}

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

  @override
  Widget build(BuildContext context) {
    return UniversalScaffold(
      appBar: const UniversalAppBar(
        title: Text("App Demo"),
      ),
      body: UniversalListView(children: [
        for (var i = 0; i < 10; i++)
          ListTile(
            title: Text("Title $i"),
            subtitle: Text("Subtitle $i"),
          ),
      ]),
    );
  }
}
9
likes
0
points
4.11k
downloads

Publisher

verified publishermathru.net

Weekly Downloads

The package provide a universal UI that aims to be written in one code on any platform.

Homepage
Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

flutter, katana, masamune, universal_platform, url_launcher

More

Packages that depend on masamune_universal_ui