Move to Flutter 3.47, use the improvements that come with this (#64)
Reviewed-on: #64
This commit is contained in:
parent
01b13b4764
commit
077044ec19
157 changed files with 1366 additions and 1457 deletions
|
|
@ -1,18 +1,19 @@
|
|||
import "package:freezed_annotation/freezed_annotation.dart";
|
||||
import "package:nexus/models/ms_duration.dart";
|
||||
|
||||
part "video.freezed.dart";
|
||||
part "video.g.dart";
|
||||
|
||||
@freezed
|
||||
abstract class VideoInfo with _$VideoInfo {
|
||||
/// Information for images, [size] is in bytes.
|
||||
const factory VideoInfo({
|
||||
@JsonKey(name: "h") int? height,
|
||||
@JsonKey(name: "w") int? width,
|
||||
@JsonKey(name: "mimetype") String? mimeType,
|
||||
@MSDuration() Duration? duration,
|
||||
int? size,
|
||||
}) = _VideoInfo;
|
||||
@Freezed(toJson: false, fromJson: false)
|
||||
@JsonSerializable()
|
||||
class const VideoInfo({
|
||||
@JsonKey(name: "h") final int? height,
|
||||
@JsonKey(name: "w") final int? width,
|
||||
@JsonKey(name: "mimetype") final String? mimeType,
|
||||
@MSDuration() final Duration? duration,
|
||||
final int? size,
|
||||
}) with _$VideoInfo {
|
||||
Map<String, Object?> toJson() => _$VideoInfoToJson(this);
|
||||
|
||||
factory VideoInfo.fromJson(Map<String, Object?> json) =>
|
||||
_$VideoInfoFromJson(json);
|
||||
|
|
|
|||
Loading…
Reference in a new issue