diff --git a/Telegram/Resources/animations/stats_boosts.tgs b/Telegram/Resources/animations/stats_boosts.tgs
new file mode 100644
index 000000000..10ba08cf2
Binary files /dev/null and b/Telegram/Resources/animations/stats_boosts.tgs differ
diff --git a/Telegram/Resources/animations/stats_earn.tgs b/Telegram/Resources/animations/stats_earn.tgs
new file mode 100644
index 000000000..d66fa990a
Binary files /dev/null and b/Telegram/Resources/animations/stats_earn.tgs differ
diff --git a/Telegram/Resources/langs/lang.strings b/Telegram/Resources/langs/lang.strings
index 3924a85f6..1b6ab0ea1 100644
--- a/Telegram/Resources/langs/lang.strings
+++ b/Telegram/Resources/langs/lang.strings
@@ -5179,6 +5179,10 @@ https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
"lng_stats_loading" = "Loading stats...";
"lng_stats_loading_subtext" = "Please wait a few moments while we generate your stats.";
+"lng_stats_boosts_loading" = "Loading boosts list...";
+"lng_stats_boosts_loading_subtext" = "Please wait a few moments while we generate your stats.";
+"lng_stats_earn_loading" = "Loading rewards info...";
+"lng_stats_earn_loading_subtext" = "Please wait a few moments while we generate your stats.";
"lng_chart_title_member_count" = "Growth";
"lng_chart_title_join" = "Followers";
diff --git a/Telegram/Resources/qrc/telegram/animations.qrc b/Telegram/Resources/qrc/telegram/animations.qrc
index af3e89fb6..0d6663d8f 100644
--- a/Telegram/Resources/qrc/telegram/animations.qrc
+++ b/Telegram/Resources/qrc/telegram/animations.qrc
@@ -11,6 +11,8 @@
../../animations/ttl.tgs
../../animations/discussion.tgs
../../animations/stats.tgs
+ ../../animations/stats_boosts.tgs
+ ../../animations/stats_earn.tgs
../../animations/voice_ttl_idle.tgs
../../animations/voice_ttl_start.tgs
../../animations/palette.tgs
diff --git a/Telegram/SourceFiles/info/bot/earn/info_bot_earn_list.cpp b/Telegram/SourceFiles/info/bot/earn/info_bot_earn_list.cpp
index cbe32faf5..aac6f38ee 100644
--- a/Telegram/SourceFiles/info/bot/earn/info_bot_earn_list.cpp
+++ b/Telegram/SourceFiles/info/bot/earn/info_bot_earn_list.cpp
@@ -87,6 +87,7 @@ void InnerWidget::load() {
Info::Statistics::FillLoading(
this,
+ Info::Statistics::LoadingType::Earn,
_loaded.events_starting_with(false) | rpl::map(!rpl::mappers::_1),
_showFinished.events());
diff --git a/Telegram/SourceFiles/info/channel_statistics/boosts/info_boosts_inner_widget.cpp b/Telegram/SourceFiles/info/channel_statistics/boosts/info_boosts_inner_widget.cpp
index 6234ab010..cddb8d9a3 100644
--- a/Telegram/SourceFiles/info/channel_statistics/boosts/info_boosts_inner_widget.cpp
+++ b/Telegram/SourceFiles/info/channel_statistics/boosts/info_boosts_inner_widget.cpp
@@ -273,6 +273,7 @@ void InnerWidget::load() {
Info::Statistics::FillLoading(
this,
+ Info::Statistics::LoadingType::Boosts,
_loaded.events_starting_with(false) | rpl::map(!rpl::mappers::_1),
_showFinished.events());
diff --git a/Telegram/SourceFiles/info/channel_statistics/earn/info_channel_earn_list.cpp b/Telegram/SourceFiles/info/channel_statistics/earn/info_channel_earn_list.cpp
index c96dac4ea..707a045cd 100644
--- a/Telegram/SourceFiles/info/channel_statistics/earn/info_channel_earn_list.cpp
+++ b/Telegram/SourceFiles/info/channel_statistics/earn/info_channel_earn_list.cpp
@@ -287,6 +287,7 @@ void InnerWidget::load() {
Info::Statistics::FillLoading(
this,
+ Info::Statistics::LoadingType::Earn,
_loaded.events_starting_with(false) | rpl::map(!rpl::mappers::_1),
_showFinished.events());
diff --git a/Telegram/SourceFiles/info/statistics/info_statistics_inner_widget.cpp b/Telegram/SourceFiles/info/statistics/info_statistics_inner_widget.cpp
index 6e5803114..193622135 100644
--- a/Telegram/SourceFiles/info/statistics/info_statistics_inner_widget.cpp
+++ b/Telegram/SourceFiles/info/statistics/info_statistics_inner_widget.cpp
@@ -560,6 +560,7 @@ void FillOverview(
void FillLoading(
not_null container,
+ LoadingType type,
rpl::producer toggleOn,
rpl::producer<> showFinished) {
const auto emptyWrap = container->add(
@@ -569,9 +570,14 @@ void FillLoading(
emptyWrap->toggleOn(std::move(toggleOn), anim::type::instant);
const auto content = emptyWrap->entity();
+ const auto iconName = (type == LoadingType::Boosts)
+ ? u"stats_boosts"_q
+ : (type == LoadingType::Earn)
+ ? u"stats_earn"_q
+ : u"stats"_q;
auto icon = ::Settings::CreateLottieIcon(
content,
- { .name = u"stats"_q, .sizeOverride = Size(st::changePhoneIconSize) },
+ { .name = iconName, .sizeOverride = Size(st::changePhoneIconSize) },
st::settingsBlockedListIconPadding);
(
@@ -586,7 +592,11 @@ void FillLoading(
content,
object_ptr(
content,
- tr::lng_stats_loading(),
+ (type == LoadingType::Boosts)
+ ? tr::lng_stats_boosts_loading()
+ : (type == LoadingType::Earn)
+ ? tr::lng_stats_earn_loading()
+ : tr::lng_stats_loading(),
st::changePhoneTitle)),
st::changePhoneTitlePadding + st::boxRowPadding);
@@ -595,7 +605,11 @@ void FillLoading(
content,
object_ptr(
content,
- tr::lng_stats_loading_subtext(),
+ (type == LoadingType::Boosts)
+ ? tr::lng_stats_boosts_loading_subtext()
+ : (type == LoadingType::Earn)
+ ? tr::lng_stats_earn_loading_subtext()
+ : tr::lng_stats_loading_subtext(),
st::statisticsLoadingSubtext)),
st::changePhoneDescriptionPadding + st::boxRowPadding);
@@ -626,6 +640,7 @@ void InnerWidget::load() {
FillLoading(
inner,
+ Info::Statistics::LoadingType::Statistic,
_loaded.events_starting_with(false) | rpl::map(!rpl::mappers::_1),
_showFinished.events());
diff --git a/Telegram/SourceFiles/info/statistics/info_statistics_inner_widget.h b/Telegram/SourceFiles/info/statistics/info_statistics_inner_widget.h
index c0a31231e..8da4fd007 100644
--- a/Telegram/SourceFiles/info/statistics/info_statistics_inner_widget.h
+++ b/Telegram/SourceFiles/info/statistics/info_statistics_inner_widget.h
@@ -21,8 +21,15 @@ namespace Info::Statistics {
class Memento;
class MessagePreview;
+enum class LoadingType {
+ Statistic,
+ Boosts,
+ Earn,
+};
+
void FillLoading(
not_null container,
+ LoadingType type,
rpl::producer toggleOn,
rpl::producer<> showFinished);