Skip to content
/ uiscale Public

[ Dart - Flutter ] Develop consistent responsive UI layouts with Flutter across various devices ensuring adaptability to dynamic screen dimensions, padding and aspect ratios. ⛱️

License

Notifications You must be signed in to change notification settings

Yodart/uiscale

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

UIScale

Flutter Pub Version License

UIScale is a versatile utility class for Flutter applications that simplifies the process of creating responsive user interfaces (UIs). It provides the tools you need to adapt your UI elements based on the characteristics of the device's screen, making it easier to maintain a consistent user experience across a variety of devices and screen sizes.

Installation: Add uiscale to your pubspec.yaml file under dependencies:

dependencies:
   uiscale: ^1.0.0  # Replace with the latest version

Getting Started

  1. Import the uiscale package into your Flutter project:
import 'package:uiscale/uiscale.dart';
  1. Initialize UIScale during your app's initialization:

⚠️ Ensure that the init method is called during the application initialization phase to correctly configure UIScale.

UIScale.init(context);
  1. Use UIScale methods to scale your UI components based on device characteristics.
// Scale the width of a container to 50% of the device's width
final double containerWidth = UIScale.width(50);

// Scale the height of an image to 30% of the device's height
final double imageHeight = UIScale.height(30);

About

[ Dart - Flutter ] Develop consistent responsive UI layouts with Flutter across various devices ensuring adaptability to dynamic screen dimensions, padding and aspect ratios. ⛱️

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Languages