rounded static method

dynamic rounded({
  1. double? radiusSize,
  2. Color? colorBackground = Colors.transparent,
  3. BorderRadius? radiusBorder,
  4. Color? colorLine,
})

Implementation

static rounded({
  double? radiusSize ,
  Color? colorBackground = Colors.transparent,
  BorderRadius? radiusBorder, //see class "BorderRadiusTools"
  Color? colorLine ,}) {

  //set default
  radiusSize ??= DSDimen.ds_size_corner_level_2;
  colorBackground ??= DSColor.cardview_background_color  ;
  colorLine ??= DSColor.cardview_boarderLine  ;

  //set default radius
  var objRadius = Radius.circular( radiusSize );
  var radiusDefault = BorderRadius.all(  objRadius );
  radiusBorder ??= radiusDefault;

  //decoration
  var dec_container_radius = BoxDecoration(
      border: Border.all(color: colorLine ) ,
      borderRadius: radiusBorder,
      color: colorBackground                                                          //background color
  );

  return dec_container_radius;
}