stilo 2.0.0 copy "stilo: ^2.0.0" to clipboard
stilo: ^2.0.0 copied to clipboard

Stilo is a utility-first Flutter library that gives you all of the building constants you need to build designs without defining common styles

example/main.dart

import 'package:flutter/material.dart';
import 'package:stilo/stilo.dart';

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

class MyApp extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Flutter Demo',
      theme: ThemeData(
        primarySwatch: Colors.blue,
      ),
      home: MyHomePage(),
    );
  }
}

class MyHomePage extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        title: Text('Stilo Example App'),
      ),
      body: Column(
        children: [
          Row(
            children: [
              Padding(
                padding: StiloEdge.left4,
                child: Container(
                  width: StiloWidth.w64,
                  height: StiloHeight.h64,
                  decoration: BoxDecoration(
                    borderRadius: StiloBorderRadius.allXl2,
                    color: StiloColor.blue[500],
                    boxShadow: StiloBoxShadow.md,
                  ),
                ),
              ),
              StiloSpacing.horiz5,
              Expanded(
                child: Container(
                  height: StiloHeight.h64,
                  decoration: BoxDecoration(
                    borderRadius: StiloBorderRadius.leftLg,
                    color: StiloColor.red[500],
                    boxShadow: StiloBoxShadow.sm,
                  ),
                ),
              ),
            ],
          ),
          StiloSpacing.vert10,
          Row(
            children: [
              Expanded(
                child: Padding(
                  padding: StiloEdge.horiz5,
                  child: Container(
                    height: StiloHeight.h64,
                    decoration: BoxDecoration(
                      border: StiloBorder.all4(StiloColor.black50),
                      borderRadius: StiloBorderRadius.allXl3,
                      color: StiloColor.green[500],
                      boxShadow: StiloBoxShadow.xl2,
                    ),
                    child: Center(
                      child: StiloTransformRotate.rotate45Neg(
                        child: Text(
                          'Hello World',
                          style: TextStyle(
                            fontSize: StiloFontSize.xl5,
                            fontWeight: StiloFontWeight.semiBold,
                          ),
                        ),
                      ),
                    ),
                  ),
                ),
              ),
            ],
          ),
        ],
      ),
    );
  }
}
16
likes
150
pub points
32%
popularity

Publisher

unverified uploader

Stilo is a utility-first Flutter library that gives you all of the building constants you need to build designs without defining common styles

Homepage
Repository (GitHub)
View/report issues

Documentation

Documentation
API reference

License

MIT (license)

Dependencies

flutter

More

Packages that depend on stilo