scaler 1.0.0+1 copy "scaler: ^1.0.0+1" to clipboard
scaler: ^1.0.0+1 copied to clipboard

Set your width height on the basis of percentage of the screen. Its value will be between ( 0 -1 ) set the value between 0 to 1 for 0 to 100% scale to width/height of screen.

Scaler For Responsive UI ( Set width and height in percentage ) #

To design responsive UI. Set your width height on the basis of percentage of the screen. Its value will be between ( 0 -1 ) set the value between 0 to 1 for 0 to 100% scale to width/height of screen.

Responsive UI #

Now set your width and height based on screen percentage that will be scale according to screen you are using

How to use #


    @override
    Widget build(BuildContext context) {

      /**
       * Container with 25% width of screen 
       * and 25% height of screen
       */
      return Container(
        color: Colors.yellow,
        height: Scaler.height(25),
        width: Scaler.width(25),
      );
    }
  

5
likes
0
pub points
75%
popularity

Publisher

verified publisherdheeruapps.in

Set your width height on the basis of percentage of the screen. Its value will be between ( 0 -1 ) set the value between 0 to 1 for 0 to 100% scale to width/height of screen.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

cupertino_icons, flutter

More

Packages that depend on scaler