feat : button , outlined button

fab button , fab outlined button ,
input , pagination widget's
This commit is contained in:
2025-04-06 15:39:00 +03:30
parent 822e22d541
commit 50cc84461e
34 changed files with 3150 additions and 27 deletions

View File

@@ -0,0 +1,24 @@
import 'package:flutter/material.dart';
extension ColorUtils on Color {
Color _darken([double amount = 0.1]) {
assert(amount >= 0 && amount <= 1, 'مقدار تیرگی باید بین 0 و 1 باشد');
final hslColor = HSLColor.fromColor(this);
final newLightness = (hslColor.lightness - amount).clamp(0.0, 1.0);
final hslDarkerColor = hslColor.withLightness(newLightness);
return hslDarkerColor.toColor();
}
get disabledColor{
return withAlpha(38);
}
get hoverColor{
return _darken(0.5);
}
get pressedColor{
return _darken(0.10);
}
}