feat : new segment logic

This commit is contained in:
2025-07-21 09:16:13 +03:30
parent e4740f786e
commit e3a808383e
3 changed files with 109 additions and 7 deletions

View File

@@ -14,7 +14,7 @@ class OverlayDropdownWidget<T> extends StatefulWidget {
final Widget Function(T? selected) labelBuilder;
final void Function(T selected)? onChanged;
final EdgeInsets? contentPadding;
final bool isDisabled;
const OverlayDropdownWidget({
super.key,
required this.items,
@@ -27,6 +27,7 @@ class OverlayDropdownWidget<T> extends StatefulWidget {
this.height,
this.background,
this.hasDropIcon = true,
this.isDisabled = false,
});
@override
@@ -123,9 +124,11 @@ class _OverlayDropdownState<T> extends State<OverlayDropdownWidget<T>> {
Widget build(BuildContext context) {
return GestureDetector(
key: _key,
onTap: () {
_isOpen.value ? _removeOverlay() : _showOverlay();
},
onTap: widget.isDisabled
? null
: () {
_isOpen.value ? _removeOverlay() : _showOverlay();
},
child: Container(
height: widget.height?.toDouble() ?? 40,
width: Get.width,