22 lines
448 B
Dart
22 lines
448 B
Dart
class PrankSound {
|
|
final String title;
|
|
final String mp3Url;
|
|
final String preUrl;
|
|
bool isFavorite;
|
|
|
|
PrankSound({
|
|
required this.title,
|
|
required this.mp3Url,
|
|
required this.preUrl,
|
|
this.isFavorite = false,
|
|
});
|
|
|
|
factory PrankSound.fromJson(Map<String, dynamic> json) {
|
|
return PrankSound(
|
|
title: json['title'] ?? 'Sound Effect',
|
|
mp3Url: json['mp3Url'] ?? '',
|
|
preUrl: json['preUrl'] ?? '',
|
|
);
|
|
}
|
|
}
|