feat : dynamic form navigation

This commit is contained in:
2025-04-26 16:50:19 +03:30
parent 6e6d2b22f6
commit c10ddaf0d5
11 changed files with 568 additions and 369 deletions

View File

@@ -0,0 +1,26 @@
extension ListExtensions<T> on List<T> {
void toggle(T item) {
if (contains(item)) {
if (length > 1) {
remove(item);
}
} else {
add(item);
}
}
void ensureContainsAtStart(T item) {
if (!contains(item)) {
insert(0, item);
}
}
void removeIfPresent(T item) {
remove(item);
}
void resetWith(T item) {
clear();
add(item);
}
}

View File

@@ -1 +1,2 @@
export 'color_utils.dart';
export 'color_utils.dart';
export 'list_extensions.dart';