2025-02-03 23:32:00 +08:00
|
|
|
import 'package:flutter/widgets.dart';
|
2024-12-09 01:40:39 +08:00
|
|
|
import 'package:freezed_annotation/freezed_annotation.dart';
|
|
|
|
|
|
|
|
|
|
part 'generated/widget.freezed.dart';
|
|
|
|
|
|
|
|
|
|
@freezed
|
|
|
|
|
class ActivateState with _$ActivateState {
|
|
|
|
|
const factory ActivateState({
|
|
|
|
|
required bool active,
|
|
|
|
|
}) = _ActivateState;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@freezed
|
|
|
|
|
class CommonMessage with _$CommonMessage {
|
|
|
|
|
const factory CommonMessage({
|
|
|
|
|
required String id,
|
|
|
|
|
required String text,
|
|
|
|
|
@Default(Duration(seconds: 3)) Duration duration,
|
|
|
|
|
}) = _CommonMessage;
|
|
|
|
|
}
|
2025-02-03 23:32:00 +08:00
|
|
|
|
|
|
|
|
@freezed
|
|
|
|
|
class CommonAppBarState with _$CommonAppBarState {
|
|
|
|
|
const factory CommonAppBarState({
|
|
|
|
|
@Default([]) List<Widget> actions,
|
|
|
|
|
Function(String)? onSearch,
|
|
|
|
|
@Default(false) bool searching,
|
|
|
|
|
}) = _CommonAppBarState;
|
|
|
|
|
}
|