zeta_flutter_utils 1.1.1 copy "zeta_flutter_utils: ^1.1.1" to clipboard
zeta_flutter_utils: ^1.1.1 copied to clipboard

Utility functions for the Zeta Design System from Zebra Technologies.

example/example.md

Debounce #

/// Initialize Debouncer
final debouncer = Debounce(()=> print('Hello, world!'), duration: Duration(seconds: 1));

/// Reset timer with optional new callback
debouncer.debounce(newCallback: ()=> print('Later, world!'));

/// Cancel debouncer
debouncer.cancel();

Nothing #

    child: Nothing()

Extensions #

Iterable

Column(
    children: [
        Text('Hello'),
        Text('world'),
    ].divide(const Text('!')).toList(),
)

Column(
    children: [
        Text('Hello'),
        Text('world'),
    ].gap(40),
)

Widget


Text('Hello world').paddingAll(10);
Text('Hello world').paddingStart(10);
Text('Hello world').paddingEnd(10);
Text('Hello world').paddingTop(10);
Text('Hello world').paddingBottom(10);
Text('Hello world').paddingHorizontal(10);
Text('Hello world').paddingVertical(10);

Num

102.formatMaxChars(3); // 99+

String

'Zebra Employee'.initials; // ZE

'zebra'.capitalize; // Zebra

Platform #

// To check host platform:

if (PlatformIs.android)
if (PlatformIs.iOS)
if (PlatformIs.macOS)
if (PlatformIs.windows)
if (PlatformIs.linux)
if (PlatformIs.fuchsia)

// To check device type:
if (PlatformIs.mobile)
if (PlatformIs.desktop)

// To check if application is running on web:
if (PlatformIs.web)

1
likes
160
points
237
downloads

Publisher

verified publisherzebra.com

Weekly Downloads

Utility functions for the Zeta Design System from Zebra Technologies.

Homepage
Repository (GitHub)
View/report issues
Contributing

Documentation

API reference

License

MIT (license)

Dependencies

flutter, web

More

Packages that depend on zeta_flutter_utils