Добавил mock репозиторий

This commit is contained in:
Никита Потапов 2024-12-13 01:30:41 +04:00
parent 12cf583b35
commit 19f937922f

View File

@ -0,0 +1,90 @@
import 'package:pmu/data/repositories/api_interface.dart';
import 'package:pmu/domain/card.dart';
class MockUserRepository extends ApiInterface {
@override
Future<List<CardPostData>?> loadData() async {
return [
const CardPostData(
name: "Марьяна",
surname: "Ро",
description: "Люблю вечерами погамать в майн",
imageUrl: "https://placehold.co/600x400/png",
age: 21,
distance: 24.5,
isLiked: false),
const CardPostData(
name: "Константин",
surname: "Злобин",
description: "Веду канал в тг про криптожизнь",
imageUrl: "https://placehold.co/600x400/png",
age: 24,
distance: 478.3,
isLiked: false),
const CardPostData(
name: "Марьяна",
surname: "Ро",
description: "Люблю вечерами погамать в майн",
imageUrl: "https://placehold.co/600x400/png",
age: 21,
distance: 24.5,
isLiked: false),
const CardPostData(
name: "Константин",
surname: "Злобин",
description: "Веду канал в тг про криптожизнь",
imageUrl: "https://placehold.co/600x400/png",
age: 24,
distance: 478.3,
isLiked: false),
const CardPostData(
name: "Марьяна",
surname: "Ро",
description: "Люблю вечерами погамать в майн",
imageUrl: "https://placehold.co/600x400/png",
age: 21,
distance: 24.5,
isLiked: false),
const CardPostData(
name: "Константин",
surname: "Злобин",
description: "Веду канал в тг про криптожизнь",
imageUrl: "https://placehold.co/600x400/png",
age: 24,
distance: 478.3,
isLiked: false),
const CardPostData(
name: "Марьяна",
surname: "Ро",
description: "Люблю вечерами погамать в майн",
imageUrl: "https://placehold.co/600x400/png",
age: 21,
distance: 24.5,
isLiked: false),
const CardPostData(
name: "Константин",
surname: "Злобин",
description: "Веду канал в тг про криптожизнь",
imageUrl: "https://placehold.co/600x400/png",
age: 24,
distance: 478.3,
isLiked: false),
const CardPostData(
name: "Марьяна",
surname: "Ро",
description: "Люблю вечерами погамать в майн",
imageUrl: "https://placehold.co/600x400/png",
age: 21,
distance: 24.5,
isLiked: false),
const CardPostData(
name: "Константин",
surname: "Злобин",
description: "Веду канал в тг про криптожизнь",
imageUrl: "https://placehold.co/600x400/png",
age: 24,
distance: 478.3,
isLiked: false)
];
}
}