native_ui 0.0.5

  • Installing
  • Versions
  • 58


NativeUI widget wrappers for Android and iOS.

This package is under development, some help is always welcome.

Getting Started

Import the native_ui package

To use the native_ui package, follow the package installation instructions.


Platform Native Button

Renders an iOS style button when the TargetPlatform is iOS and an Android style button when the TargetPlatform is Android.

    onPressed: _login(context),
    padding: const EdgeInsets.symmetric(vertical: 8.0),
    width: 86.0,
    child: Text(
      style: TextStyle(
          color: Colors.white, fontWeight: FontWeight.bold),


Render a Widget based on a boolean expression.

    condition: _isLogging,
    trueWidget: Text(
        style: Theme.of(context).textTheme.title,
    falseWidget: FlatButton(
        onPressed: () => {},
        child: Text(
          style: TextStyle(
              color: Theme.of(context).primaryColorDark,
              fontWeight: FontWeight.bold),


Unique widget for switch widgets between platforms.

  iOSChild: iOSButton(
    child: child,
    onPressed: onPressed,
    color: color,
    padding: padding,
    height: height,
    width: width,
  androidChild: MaterialButton(
    key: key,
    onPressed: onPressed,
    child: child,
    color: color,
    padding: padding,
    minWidth: width,
    height: height,


Please contribute sending feedback or reporting a bug, or sending a pull request. Thank you!

[0.0.2] - 31/05/2018

  • Button wrapper with native styles for Android and iOS
  • PlatformSwitcher widget
  • ConditionalBuilder widget

[0.0.3] - 01/06/2018

  • BSD License
  • API Docs
  • Child property is now required for Button widget.

[0.0.4] - 05/06/2018

  • Tests
  • iOS FormView and FormFieldView widgets.

[0.0.5] - 05/08/2018

  • Dart 2 compatibility.

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:

  native_ui: ^0.0.5

2. Install it

You can install packages from the command line:

with Flutter:

$ flutter packages get

Alternatively, your editor might support flutter packages get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:

import 'package:native_ui/native_ui.dart';
Version Uploaded Documentation Archive
0.0.5 Aug 5, 2018 Go to the documentation of native_ui 0.0.5 Download native_ui 0.0.5 archive
0.0.4 Jun 5, 2018 Go to the documentation of native_ui 0.0.4 Download native_ui 0.0.4 archive
0.0.3 Jun 1, 2018 Go to the documentation of native_ui 0.0.3 Download native_ui 0.0.3 archive
0.0.2 May 31, 2018 Go to the documentation of native_ui 0.0.2 Download native_ui 0.0.2 archive
Describes how popular the package is relative to other packages. [more]
Code health derived from static analysis. [more]
Reflects how tidy and up-to-date the package is. [more]
Weighted score of the above. [more]
Learn more about scoring.

We analyzed this package on Dec 5, 2018, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.1.0
  • pana: 0.12.7
  • Flutter: 1.0.0


Detected platforms: Flutter

References Flutter, and has no conflicting libraries.

Health issues and suggestions

Fix lib/src/ios/button.dart. (-25.38 points)

Analysis of lib/src/ios/button.dart failed with 1 error, 1 hint:

line 184 col 33: A value of type 'TickerFuture' can't be assigned to a variable of type 'Future<Null>'.

line 46 col 7: Name types using UpperCamelCase.

Maintenance suggestions

The description is too short. (-20 points)

Add more detail about the package, what it does and what is its target use case. Try to write at least 60 characters.

Maintain an example. (-10 points)

Create a short demo in the example/ directory to show how to use this package. Common file name patterns include: main.dart, example.dart or you could also use native_ui.dart.

Package is pre-v0.1 release. (-10 points)

While there is nothing inherently wrong with versions of 0.0.*, it usually means that the author is still experimenting with the general direction of the API.


Package Constraint Resolved Available
Direct dependencies
Dart SDK >=1.19.0 <3.0.0
flutter 0.0.0
Transitive dependencies
collection 1.14.11
meta 1.1.6
sky_engine 0.0.99
typed_data 1.1.6
vector_math 2.0.8
Dev dependencies