parent
522df86976
commit
029efe7c0a
1 changed files with 225 additions and 70 deletions
17
lib/models/content/tombstone.dart
Normal file
17
lib/models/content/tombstone.dart
Normal file
|
|
@ -0,0 +1,17 @@
|
|||
import "package:freezed_annotation/freezed_annotation.dart";
|
||||
import "package:nexus/models/content/content.dart";
|
||||
part "tombstone.freezed.dart";
|
||||
part "tombstone.g.dart";
|
||||
|
||||
@Freezed(toJson: false, fromJson: false)
|
||||
@JsonSerializable()
|
||||
class const TombstoneContent({
|
||||
final String body = "",
|
||||
required final String replacementRoom,
|
||||
}) extends Content with _$TombstoneContent {
|
||||
@override
|
||||
Map<String, Object?> toJson() => _$TombstoneContentToJson(this);
|
||||
|
||||
factory TombstoneContent.fromJson(Map<String, Object?> json) =>
|
||||
_$TombstoneContentFromJson(json);
|
||||
}
|
||||
Loading…
Reference in a new issue