Skip to content

Commit

Permalink
Add instagram to our card in the dashboard page (#879)
Browse files Browse the repository at this point in the history
* add instagram to our card in the dashboard page

* update the email

* [BOT] Applying version.

* [BOT] Applying format.

* update Has card aboutUs displayed properly Test for the new Instagram IconButton

* [BOT] Update golden files

* fix duplicated import

* try fix

* [BOT] Applying version.

---------

Co-authored-by: AmineMihoubi <[email protected]>
Co-authored-by: clubapplets-server <[email protected]>
  • Loading branch information
3 people authored Nov 9, 2023
1 parent da2b56f commit f505e43
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 3 deletions.
3 changes: 2 additions & 1 deletion lib/core/constants/urls.dart
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,9 @@ class Urls {
static const String clubWebsite = "https://clubapplets.ca/";
static const String clubGithub = "https://github.com/ApplETS";
static const String clubFacebook = "https://facebook.com/ClubApplETS";
static const String clubInstagram = "https://www.instagram.com/clubapplets";
static const String clubTwitter = "https://twitter.com/ClubApplETS";
static const String clubEmail = "mailto:info@clubapplets.ca";
static const String clubEmail = "mailto:ApplETS@etsmtl.ca";
static const String clubYoutube =
"https://youtube.com/channel/UCiSzzfW1bVbE_0KcEZO52ew";
static const String clubDiscord = "https://discord.gg/adMkWptn6Y";
Expand Down
11 changes: 11 additions & 0 deletions lib/ui/views/dashboard_view.dart
Original file line number Diff line number Diff line change
Expand Up @@ -165,6 +165,17 @@ class _DashboardViewState extends State<DashboardView>
color: Colors.white,
),
),
IconButton(
onPressed: () {
_analyticsService.logEvent(tag, "Instagram clicked");
Utils.launchURL(
Urls.clubInstagram, AppIntl.of(context));
},
icon: const FaIcon(
FontAwesomeIcons.instagram,
color: Colors.white,
),
),
IconButton(
onPressed: () {
_analyticsService.logEvent(tag, "Github clicked");
Expand Down
2 changes: 1 addition & 1 deletion pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ description: The 4th generation of ÉTSMobile, the main gateway between the Éco
# pub.dev using `pub publish`. This is preferred for private packages.
publish_to: 'none' # Remove this line if you wish to publish to pub.dev

version: 4.28.4+1
version: 4.29.0+1

environment:
sdk: ">=2.10.0 <3.0.0"
Expand Down
2 changes: 1 addition & 1 deletion test/ui/views/dashboard_view_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -316,7 +316,7 @@ void main() {

// Find aboutUs card Link Buttons
final aboutUsLinkButtons = find.byType(IconButton);
expect(aboutUsLinkButtons, findsNWidgets(5));
expect(aboutUsLinkButtons, findsNWidgets(6));
});

testWidgets("Has card schedule displayed today's events properly",
Expand Down
Binary file modified test/ui/views/goldenFiles/dashboardView_appletsCard_1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit f505e43

Please sign in to comment.