Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add rate the app link and share the app link in the settings page! #3704

Merged
merged 5 commits into from
Feb 21, 2023

Conversation

Sudhanva-Nadiger
Copy link
Contributor

What

  • added link for rating app link 🔗 which redirects the user to the app store or play store based on the platform, if there is an exception it shows the message that the app store does not exist.
  • added share the app link in the settings page, so user can share the app link to frnds

Screenshot

redirect.mp4

Fixes bug(s)

Part of

height: DEFAULT_ICON_SIZE,
width: DEFAULT_ICON_SIZE,
child: Image.asset(Platform.isIOS
? 'assets/app/app-store.png'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd be easier with SVG for size concerns

ListTile(
leading: const Icon(Icons.share),
title: const Text(
'Share Open Food Facts',
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

string to extract

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should I remove it, or should we add it here also ! There was a picture in the issue #2551 ,.i saw that and did this 😄.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think @teolemon means with extract to put it into app_en.arb

];
}

class _RateUs extends StatelessWidget {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is it conditional to the flavor ? We also build for fdroid, fyi

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I will check that ,

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you explain a bit more about "is it conditional to the flavor"?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If this also works with F-Droid and I think it does not

You can get the flavour using the global variable flavour (main.dart l.54) can be used everywhere in the code.

Or even better await ApplicationStore.openAppReview() we already have this function implemented, this way you don't even have to worry about this and we don't need store_redirect

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh coooll I will look into it and make changes !

Copy link
Member

@teolemon teolemon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We already have a "Share Open Food Facts button" in Contribute

@Sudhanva-Nadiger
Copy link
Contributor Author

Oh okay !! I will remove that !

- use preDEfined share button
- remove store_redirect
Copy link
Member

@M123-dev M123-dev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great, thanks @Sudhanva-Nadiger, looking forward to more reviews 😄

@M123-dev M123-dev merged commit 05fe427 into openfoodfacts:develop Feb 21, 2023
@Sudhanva-Nadiger
Copy link
Contributor Author

Thanks ❤️😄, same here ! I am learning alot by contributing to such a great project!!!!! Thanks @M123-dev @teolemon

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Introducing a simple "Rate app" link in settings
3 participants