Move to Flutter 3.47, use the improvements that come with this (#64)

Reviewed-on: #64
This commit is contained in:
Henry Hiles 2026-08-22 13:04:33 -04:00 committed by Henry Hiles
commit 077044ec19
157 changed files with 1366 additions and 1457 deletions

View file

@ -1,22 +1,23 @@
import "package:freezed_annotation/freezed_annotation.dart";
import "package:nexus/models/content/content.dart";
import "package:nexus/models/ms_duration.dart";
part "set_state.freezed.dart";
part "set_state.g.dart";
@freezed
abstract class SetStateRequest with _$SetStateRequest {
const factory SetStateRequest({
required String roomId,
required String type,
required String stateKey,
required Content content,
@Freezed(toJson: false, fromJson: false)
@JsonSerializable()
class const SetStateRequest({
required final String roomId,
required final String type,
required final String stateKey,
required final Content content,
@JsonKey(name: "delay_ms", includeIfNull: false)
@MSDuration()
@Default(null)
Duration? delay,
}) = _SetStateRequest;
@JsonKey(name: "delay_ms", includeIfNull: false)
@MSDuration()
final Duration? delay,
}) with _$SetStateRequest {
Map<String, Object?> toJson() => _$SetStateRequestToJson(this);
factory SetStateRequest.fromJson(Map<String, Object?> json) =>
_$SetStateRequestFromJson(json);