Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
Leonavichus committed Mar 30, 2023
1 parent f9e6ffd commit af89ab4
Show file tree
Hide file tree
Showing 4 changed files with 222 additions and 208 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ An application for viewing the weather in your city
- Просмотр погоды по часам
- Просмотр погоды на неделю
- Просмотр подробных данных о погоде
- Локализация (ru/en/it/de)
- Локализация (ru/en/it/de/fr/tr)
- Кэширование данных
- Выбор города самостоятельно
- Добавление карточек других городов
Expand All @@ -32,7 +32,7 @@ The following options are provided:
- View weather by hour
- View the weather for the week
- View detailed weather data
- Localization (ru/en/it/de)
- Localization (ru/en/it/de/fr/tr)
- Data caching
- Choose the city yourself
- Adding cards of other cities
Expand Down
31 changes: 15 additions & 16 deletions lib/app/modules/card_weather.dart
Original file line number Diff line number Diff line change
Expand Up @@ -113,27 +113,26 @@ class _CardWeatherState extends State<CardWeather> {
onDismissed: (DismissDirection direction) {
locationController.deleteCardWeather(weatherCardList);
},
child: Obx(
() => locationController.isLoading.isFalse
? CardDescWeather(
time: weatherCardList.time!,
weather: weatherCardList.weathercode!,
degree: weatherCardList.temperature2M!,
district: weatherCardList.district!,
city: weatherCardList.city!,
timezone: weatherCardList.timezone!,
)
: const MyShimmer(
hight: 110,
edgeInsetsMargin: EdgeInsets.symmetric(
vertical: 8, horizontal: 10),
),
child: CardDescWeather(
time: weatherCardList.time!,
weather: weatherCardList.weathercode!,
degree: weatherCardList.temperature2M!,
district: weatherCardList.district!,
city: weatherCardList.city!,
timezone: weatherCardList.timezone!,
),
);
},
);
} else {
return const SizedBox.shrink();
return ListView.builder(
itemCount: 10,
itemBuilder: (context, index) => const MyShimmer(
hight: 110,
edgeInsetsMargin:
EdgeInsets.symmetric(vertical: 8, horizontal: 10),
),
);
}
}
},
Expand Down
Loading

0 comments on commit af89ab4

Please sign in to comment.