Skip to content

Commit

Permalink
Merge pull request #310 from defuncart/chore/remove-dev-releases
Browse files Browse the repository at this point in the history
chore: Remove dev releases
  • Loading branch information
aguilaair authored Feb 22, 2024
2 parents 88af982 + d85aa63 commit 356124b
Show file tree
Hide file tree
Showing 26 changed files with 2 additions and 54 deletions.
3 changes: 1 addition & 2 deletions lib/src/modules/common/constants.dart
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ const kNavigationWidth = 65.0;
const kNavigationWidthExtended = 180.0;

/// Channels without master
const kReleaseChannels = ['stable', 'beta', 'dev'];
const kReleaseChannels = ['stable', 'beta'];

/// Master channel
const kMasterChannel = 'master';
Expand All @@ -35,6 +35,5 @@ const kFlutterTagsUrl = 'https://github.com/flutter/flutter/releases/tag/';
Map<String, String> channelDescriptions(BuildContext context) => {
'stable': context.i18n('modules:common.stableChannelDescription'),
'beta': context.i18n('modules:common.betaChannelDescription'),
'dev': context.i18n('modules:common.devChannelDescription'),
'master': context.i18n('modules:common.masterChannelDescription'),
};
3 changes: 0 additions & 3 deletions lib/src/modules/releases/releases.provider.dart
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,6 @@ final getVersionProvider = Provider.family<ReleaseDto?, String?>(
enum Filter {
beta,
stable,
dev,
all,
}

Expand All @@ -214,8 +213,6 @@ Filter filterFromName(String name) {
switch (name) {
case 'stable':
return Filter.stable;
case 'dev':
return Filter.dev;
case 'beta':
return Filter.beta;
case 'all':
Expand Down
16 changes: 0 additions & 16 deletions lib/src/modules/search/components/search_results_list.dart
Original file line number Diff line number Diff line change
Expand Up @@ -96,22 +96,6 @@ class SearchResultsList extends StatelessWidget {
),
],
),
SliverSection(
shouldDisplay: results.devReleases.isNotEmpty,
slivers: [
SliverPersistentHeader(
delegate: SliverHeaderDelegate(
title: context.i18n('modules:search.components.devReleases'),
count: results.devReleases.length,
),
),
SliverList(
delegate: SliverChildBuilderDelegate((context, index) {
return ReleaseListItem(results.devReleases[index]);
}, childCount: results.devReleases.length),
),
],
),
],
),
);
Expand Down
12 changes: 1 addition & 11 deletions lib/src/modules/search/search.provider.dart
Original file line number Diff line number Diff line change
Expand Up @@ -40,25 +40,20 @@ class SearchResults {
/// Beta Releases
final List<VersionDto> betaReleases;

/// Dev Releases
final List<VersionDto> devReleases;

/// Constructor
SearchResults({
this.projects = const [],
this.channels = const [],
this.stableReleases = const [],
this.betaReleases = const [],
this.devReleases = const [],
});

/// No results
bool get isEmpty {
return projects.isEmpty &&
channels.isEmpty &&
stableReleases.isEmpty &&
betaReleases.isEmpty &&
devReleases.isEmpty;
betaReleases.isEmpty;
}
}

Expand All @@ -84,7 +79,6 @@ final searchResultsProvider = Provider((ref) {
final channelResults = <ChannelDto>[];
final stableReleaseResults = <VersionDto>[];
final betaReleaseResults = <VersionDto>[];
final devReleaseResults = <VersionDto>[];

// We look for multiple terms, make sure result only shows up once
final uniques = <String, bool>{};
Expand Down Expand Up @@ -141,9 +135,6 @@ final searchResultsProvider = Provider((ref) {
case Channel.beta:
betaReleaseResults.add(release);
break;
case Channel.dev:
devReleaseResults.add(release);
break;
default:

/// TODO: If this logic is removed, it should support passing actual Context
Expand Down Expand Up @@ -175,6 +166,5 @@ final searchResultsProvider = Provider((ref) {
projects: projectResults,
stableReleases: stableReleaseResults,
betaReleases: betaReleaseResults,
devReleases: devReleaseResults,
);
});
1 change: 0 additions & 1 deletion localizations/ar-SA/modules.json
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,6 @@
"channels": "القنوات",
"stableReleases": "الإصدارات المستقرة",
"betaReleases": "الإصدارات التجريبية",
"devReleases": "الإصدارات التجريبية \"مطورين\"",
"invalidChanel": "قناة غير صالحة"
}
},
Expand Down
1 change: 0 additions & 1 deletion localizations/bn-BD/modules.json
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,6 @@
"channels": "চ্যানেলসমূহ",
"stableReleases": "স্টেবল রিলিজেস",
"betaReleases": "বিটা রিলিজেস",
"devReleases": "ডেভ রিলিজেস",
"invalidChanel": "অবৈধ চ্যানেল"
}
},
Expand Down
1 change: 0 additions & 1 deletion localizations/de-DE/modules.json
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,6 @@
"channels": "Channels",
"stableReleases": "Stable Releases",
"betaReleases": "Beta Releases",
"devReleases": "Dev Releases",
"invalidChannel": "Ungültiger Channel"
}
},
Expand Down
1 change: 0 additions & 1 deletion localizations/en-GB/modules.json
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,6 @@
"channels": "Channels",
"stableReleases": "Stable Releases",
"betaReleases": "Beta Releases",
"devReleases": "Dev Releases",
"invalidChanel": "Invalid Channel"
}
},
Expand Down
1 change: 0 additions & 1 deletion localizations/en-US/modules.json
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,6 @@
"channels": "Channels",
"stableReleases": "Stable Releases",
"betaReleases": "Beta Releases",
"devReleases": "Dev Releases",
"invalidChanel": "Invalid Channel"
}
},
Expand Down
1 change: 0 additions & 1 deletion localizations/es-ES/modules.json
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,6 @@
"channels": "Canales",
"stableReleases": "Vesiones Estables",
"betaReleases": "Versiones Beta",
"devReleases": "Versiones Dev",
"invalidChanel": "Canal inválido"
}
},
Expand Down
1 change: 0 additions & 1 deletion localizations/fr-FR/modules.json
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,6 @@
"channels": "Branches",
"stableReleases": "Releases stables",
"betaReleases": "Releases beta",
"devReleases": "Releases dev",
"invalidChanel": "Branche invalide"
}
},
Expand Down
1 change: 0 additions & 1 deletion localizations/hi-IN/modules.json
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,6 @@
"channels": "चैनल",
"stableReleases": "स्टैबल रिलीज",
"betaReleases": "बीटा रिलीज",
"devReleases": "देव रिलीज",
"invalidChanel": "अमान्य चैनल"
}
},
Expand Down
1 change: 0 additions & 1 deletion localizations/id-ID/modules.json
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,6 @@
"channels": "Channel",
"stableReleases": "Rilis Stabil",
"betaReleases": "Rilis Beta",
"devReleases": "Rilis Dev",
"invalidChanel": "Channel Tidak Valid"
}
},
Expand Down
1 change: 0 additions & 1 deletion localizations/it-IT/modules.json
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,6 @@
"channels": "Canali",
"stableReleases": "Stable Releases",
"betaReleases": "Beta Releases",
"devReleases": "Dev Releases",
"invalidChanel": "Canale non valido"
}
},
Expand Down
1 change: 0 additions & 1 deletion localizations/ja-JP/modules.json
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,6 @@
"channels": "チャンネル",
"stableReleases": "Stableリリース",
"betaReleases": "Betaリリース",
"devReleases": "Devリリース",
"invalidChanel": "無効なチャンネル"
}
},
Expand Down
1 change: 0 additions & 1 deletion localizations/ko-KR/modules.json
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,6 @@
"channels": "채널",
"stableReleases": "안정 버전",
"betaReleases": "베타 버전",
"devReleases": "개발자 버전",
"invalidChanel": "유효하지 않은 버전"
}
},
Expand Down
1 change: 0 additions & 1 deletion localizations/pl-PL/modules.json
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,6 @@
"channels": "Kanały",
"stableReleases": "Wydania stabilne",
"betaReleases": "Wydania beta",
"devReleases": "Wydania developerskie",
"invalidChanel": "Niepoprawny kanał"
}
},
Expand Down
1 change: 0 additions & 1 deletion localizations/pt-BR/modules.json
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,6 @@
"channels": "Canais",
"stableReleases": "Releases Estáveis",
"betaReleases": "Releases Beta",
"devReleases": "Releases Dev",
"invalidChanel": "Canal inválido"
}
},
Expand Down
1 change: 0 additions & 1 deletion localizations/ru-RU/modules.json
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,6 @@
"channels": "Каналы",
"stableReleases": "Стабильные релизы",
"betaReleases": "Бета-релизы",
"devReleases": "Релизы разработчиков",
"invalidChanel": "Некорректный канал"
}
},
Expand Down
1 change: 0 additions & 1 deletion localizations/sv-SE/modules.json
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,6 @@
"channels": "Kaneler",
"stableReleases": "Stabil releaser",
"betaReleases": "Beta releaser",
"devReleases": "Dev releaser",
"invalidChanel": "Felaktig kanal"
}
},
Expand Down
1 change: 0 additions & 1 deletion localizations/tr-TR/modules.json
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,6 @@
"channels": "Kanallar",
"stableReleases": "Stabil Yayınlar",
"betaReleases": "Beta Yayınlar",
"devReleases": "Geliştirici Yayınlar",
"invalidChanel": "Geçersiz kanal"
}
},
Expand Down
1 change: 0 additions & 1 deletion localizations/uk-UA/modules.json
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,6 @@
"channels": "Канали",
"stableReleases": "Стабільні релізи",
"betaReleases": "Бета-релізи",
"devReleases": "Релізи розробників",
"invalidChanel": "Недійсний канал"
}
},
Expand Down
1 change: 0 additions & 1 deletion localizations/uz-CY/modules.json
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,6 @@
"channels": "Каналлар",
"stableReleases": "Барқарор нашрлар",
"betaReleases": "Бета нашрлар",
"devReleases": "Ишлаб чиқарувчи нашрлари",
"invalidChanel": "Яроқсиз канал"
}
},
Expand Down
1 change: 0 additions & 1 deletion localizations/uz-LA/modules.json
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,6 @@
"channels": "Kanallar",
"stableReleases": "Barqaror nashrlar",
"betaReleases": "Beta nashrlar",
"devReleases": "Ishlab chiqaruvchi nashrlari",
"invalidChanel": "Yaroqsiz kanal"
}
},
Expand Down
1 change: 0 additions & 1 deletion localizations/zh-CN/modules.json
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,6 @@
"channels": "渠道",
"stableReleases": "Stable 发行版",
"betaReleases": "Beta 发行版",
"devReleases": "Dev 发行版",
"invalidChanel": "无效渠道"
}
},
Expand Down
1 change: 0 additions & 1 deletion localizations/zh-TW/modules.json
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,6 @@
"channels": "通道",
"stableReleases": "Stable 發行版",
"betaReleases": "Beta 發行版",
"devReleases": "Dev 發行版",
"invalidChanel": "無效通道"
}
},
Expand Down

0 comments on commit 356124b

Please sign in to comment.