45 Commits

Author SHA1 Message Date
0ea1967d1d fix: Add hunger game analytics event and track it (#5004)
* fix:4682 Add hunger game analytics event and track it

* Update packages/smooth_app/lib/pages/preferences/user_preferences_contribute.dart

Co-authored-by: monsieurtanuki <fabrice_fontaine@hotmail.com>

---------

Co-authored-by: monsieurtanuki <fabrice_fontaine@hotmail.com>
2024-01-25 17:02:50 +01:00
0ddd5c6538 chore: upgraded flutter_map to 6.0.1 (#4757)
* chore: upgraded flutter_map to 6.0.1

Impacted files:
* `add_new_product_page.dart`: matomo upgrade
* `analytics_helper.dart`: matomo upgrade
* `camera_scan_page.dart`: matomo upgrade
* `forgot_password_page.dart`: matomo upgrade
* `knowledge_panel_page.dart`: matomo upgrade
* `knowledge_panel_world_map_card.dart`: flutter_map upgrade
* `login_page.dart`: matomo upgrade
* `main.dart`: matomo upgrade
* `new_product_page.dart`: matomo upgrade
* `personalized_ranking_page.dart`: matomo upgrade
* `product_list_page.dart`: matomo upgrade
* `product_query_page.dart`: matomo upgrade
* `pubspec.lock`: wtf
* `pubspec.yaml`: upgraded flutter_map to 6.0.1 (+ domino effect)
* `question_page.dart`: matomo upgrade
* `sign_up_page.dart`: matomo upgrade
* `user_preferences_page.dart`: matomo upgrade

* chore: upgrade flutter_map to 6.0.1

Impacted file:
* `mocks.dart`: matomo upgrade

* chore: unit test fix

* pubspec upgrade
2023-11-17 12:50:35 +01:00
5bac72068a fix: 4595 - no fast track if nutriscore is not applicable (#4599)
* fix: 4595 - no fast track if nutriscore is not applicable

* fix: 4595 - added ecoscore check, and matomo
2023-08-26 17:12:49 +02:00
d1a7e9e3d9 chore: Upgrade Sentry + add screenshots (#4566)
* Upgrade Sentry + add screenshots

* Upgrade iOS & macOS dependencies

* Remove unused variable
2023-08-17 11:30:38 +02:00
78884a6ad2 feat: App review in the "scan card" (#4450)
* App review in the "scan card"

* Add a keep alive to prevent many requests

* Add a missing call to super (for the KeepAlive mixin)

* Don't really understand what happened with this file 🤨
2023-08-05 17:27:59 +02:00
a6997733af feat: Robotoff question as a banner or a button (#4280)
* Robotoff question in a product, visible as a banner (at the bottom of the screen) or in a button (current implementation)
We split the users into two cohorts and we will have some Analytics to understand if one is better than the other.
The CongratsWidget is also improved by some animations and accessibility

* Now with a better animation
2023-07-29 19:28:12 +02:00
41e919129a feat: Product loading card (#4318) 2023-07-22 17:30:46 +02:00
b8b0a8f58b fix: Fix a regression with Matomo (#4326) 2023-07-17 13:36:47 +02:00
5a72a46fbf feat: Better support error when saving the picture locally (#4305) 2023-07-17 13:17:52 +02:00
7487b72af0 chore: Upgrade Matomo to 3.1 (#4000) 2023-07-16 18:49:07 +02:00
7dd3983f35 feat: Re-enable analytics on FDroid builds (#4289) 2023-07-13 09:18:05 +02:00
92505439c4 feat: 4163 - "incomplete product" card added to product summary (#4236)
* feat: 4163 - "incomplete product" card added to product summary

New files:
* `product_compatibility_header.dart`: Header showing the product compatibility (color + text). Used to be private in `summary_card.dart`.
* `product_incomplete_card.dart`: "Incomplete product!" card to be displayed in product summary, if relevant.
* `summary_attribute_group.dart`: Shows the attribute groups in a product summary card. Used to be private in `summary_card.dart`.

Impacted files:
* `add_new_product_page.dart`: added a constructor for product instead of barcode; added display parameters; now using new "nutrition field editor"
* `add_nutrition_button.dart`: minor refactoring
* `app_en.arb`: added 1 label for the "hey! please complete the product!" message
* `app_navigator.dart`: minor refactoring
* `edit_product_page.dart`: minor refactoring
* `nutrition_page_loaded.dart`: minor refactoring
* `product_field_editor.dart`: new "nutrition field editor"
* `smooth_product_card_not_found.dart`: minor refactoring
* `summary_card.dart`: refactored into additional files because the file was getting too big and possibly too confusing; added the "incomplete product" card (if relevant)

* feat: 4163 - after review

Impacted files:
* `app_en.arb`: changed the label
* `product_incomplete_card.dart`: changed the border radius

* feat: 4163 - after comment

Impacted files:
* `add_new_product_page.dart`: added an `AnalyticsEvent` in the constructors; simplified the constructors.
* `analytics_helper.dart`: added 2 events
* `product_incomplete_card.dart`: minor refactoring
* `summary_card.dart`: added a matomo

* feat: 4163 - after comment

Impacted files:
* `add_new_product_page.dart`: added an `AnalyticsEvent` in the constructors; simplified the constructors.
* `analytics_helper.dart`: added 2 events
* `product_incomplete_card.dart`: minor refactoring
* `summary_card.dart`: added a matomo

* feat: 4163 - new analytics category "fast track edit product"

Impacted files:
* `add_new_product_page.dart`: specific events for each case
* `analytics_helper.dart`: added 1 category and 4 events
2023-06-28 14:29:36 +02:00
7ac86dc4f8 feat: 3843 - matomo for new product page (#4217)
* feat: 3843 - matomo for new product page

Impacted files:
* `add_new_product_page.dart`: implemented the tracking of 6 events for matomo
* `analytics_helper.dart`: added 1 category and 6 related events for the "new product page"

* feat: 3843 - TraceableClientMixin
2023-06-20 17:44:16 +02:00
85fcde1b5c Force all "Hero" widgets to have a unique tag (#4124) 2023-06-15 12:24:33 +02:00
74c00ae50f feat: Allow to remove a product not found from the carousel (#4126)
* Allow to remove a product not found from the carousel

* Add an analytics event when the user removes an unknown product
2023-06-12 17:48:19 +02:00
abab9342a9 Improve how we manager consent in the app (#4118) 2023-06-11 09:18:09 +02:00
9f449486bb Add the current visitor ID of Matomo in the debug settings (#4095) 2023-06-07 20:09:02 +02:00
bfe1d60db9 Revert ""_allow" attribute was never initialized (#4087)" (#4090)
This reverts commit ba695dcad472f9892e6a2f33599b7276243cf2f7.
2023-06-06 21:37:21 +02:00
ba695dcad4 "_allow" attribute was never initialized (#4087) 2023-06-06 16:36:32 +02:00
4c44b06bcd feat: Support for deep links (#3995)
* Support for deep links on Android

* Deep links: Better support for network errors / unknown product

* iOS configuration for deep links

* Improve documentation

* Improve doc

* Support other domains

* Add an error page

* Upgrade to go_router 7.0.2

* Add some Sentry events

* Update packages/smooth_app/lib/helpers/extension_on_text_helper.dart

Co-authored-by: monsieurtanuki <fabrice_fontaine@hotmail.com>

* SizedBox -> EMPTY_WIDGET

* PreferencePageType: from name to tag

* Remove an unused async keyword

* Move internal app routes to an enum

* Add a clarification about `ProductLoaderPage`

* Update packages/smooth_app/lib/pages/navigator/app_navigator.dart

Co-authored-by: Pierre Slamich <pierre.slamich@gmail.com>

* Revert how we open the product addition/creation on the product not found card

---------

Co-authored-by: monsieurtanuki <fabrice_fontaine@hotmail.com>
Co-authored-by: Pierre Slamich <pierre.slamich@gmail.com>
2023-05-23 15:52:33 +02:00
63b65e6f79 fix: Stronger F-Droid analytics rules (#3902)
Co-authored-by: Cirrus CI <support@cirruslabs.org>
2023-04-24 19:43:34 +02:00
f7e42c762b chore: Shared common scanner (#3883)
* First movement

* devcotainer

* Lint fixes

* Shared visor

* Final moves

* Final lint fixes

* Empty widget, moved scan header

* Update scanner_ml_kit.dart

---------

Co-authored-by: Marvin Moeltgen
2023-04-18 21:05:28 +02:00
1734a20381 ci: Return to entrypoint based scanner (#3874)
* ci: Return to entrypoint based scanner

* Update basic_test.dart
2023-04-14 17:07:37 +02:00
54560fffdb fix: 3679 - reporting with a 000000000000 matomo user id (#3840)
* fix: test that if user opts out he/she will be
tracked with a user id of 0000000000000000

* fix: implement to make test work

* fix: Implement suggestions from review

* fix: change to init

Co-authored-by: monsieurtanuki <fabrice_fontaine@hotmail.com>

* fix: add comment

Co-authored-by: monsieurtanuki <fabrice_fontaine@hotmail.com>

* fix: add explicit optOut

Co-authored-by: monsieurtanuki <fabrice_fontaine@hotmail.com>

* fix: remove surplus statement

Co-authored-by: monsieurtanuki <fabrice_fontaine@hotmail.com>

* fix: remove test

* fix: use old imports

* fix: format with dart format

---------

Co-authored-by: markdurst <mark.durst@deutschebahn.com>
Co-authored-by: monsieurtanuki <fabrice_fontaine@hotmail.com>
2023-04-04 19:40:02 +02:00
0bf279473b fix: 3782 - more relevant check and matomo message (#3787)
Impacted files:
* `add_basic_details_page.dart`: unrelated typo fix
* `analytics_helper.dart`: added 2 events for matomo; unrelated typo fix
* `edit_product_page.dart`: unrelated typo fix
* `smooth_barcode_scanner_mlkit.dart`: added an `isStarting` check; now sends matomo instead of red snackbar; simplified
2023-03-20 14:29:37 +01:00
cd04400194 chore: Track edit events (#3755)
* track edit events

* flutter format

* fixed the logic for most edit events

* dart formatting

* typo fixes

* fix the bugs and simple input page

* Update packages/smooth_app/lib/helpers/analytics_helper.dart

Co-authored-by: Pierre Slamich <pierre.slamich@gmail.com>

* Update packages/smooth_app/lib/pages/product/edit_product_page.dart

* Update packages/smooth_app/lib/pages/product/new_product_page.dart

* remove the webview ^

* Update presubmit.yml

---------

Co-authored-by: Pierre Slamich <pierre.slamich@gmail.com>
Co-authored-by: monsieurtanuki <fabrice_fontaine@hotmail.com>
2023-03-16 18:36:48 +01:00
777f54cdf3 feat: Allow to share and view lists on web (#3757)
* feat: Allow to share and view lists on web

* formatting

* chore: Analytics

* Update temp_product_list_share_helper.dart

* Revert "Update temp_product_list_share_helper.dart"

This reverts commit a36473ae11caa74e3781caf84a1a828f7dcf07f4.

* localized
2023-03-09 18:05:51 +01:00
7e861f569e refactor: upgrade to off-dart 2.0.0 (#3495)
Impacted files:
* `paged_to_be_completed_product_query.dart`: renamed `State` as `ProductState`
* `paged_user_product_query.dart`: created local `UserSearchType` instead of deprecated off-dart `UserProductSearchType`; used `ProductSearchQueryConfiguration` instead of deprecated `UserProductSearchQueryConfiguration`
* `product_query.dart`: now that we use fully v3, we don't need the temporary field list for user-related queries with v2
* `pubspec.lock`: wtf
* `pubspec.yaml`: upgrade to off-dart 2.0.0
* `user_preferences_account.dart`: now using new local class `UserSearchType`
* and reduced all off-dart imports to a single `import 'package:openfoodfacts/openfoodfacts.dart';`
2023-01-02 16:10:52 +01:00
a35b7db371 ci: Show flavour in about this app and sentry (#3429)
Co-authored-by: Aman Raj <57723319+AshAman999@users.noreply.github.com>
2022-12-10 11:14:22 +01:00
1996907f74 chore: Matomo refactor (#3273)
* chore: Matomo refactor

* ci: add labeler for analytics

* fix: Review

Co-Authored-By: monsieurtanuki <11576431+monsieurtanuki@users.noreply.github.com>

* Revert play dart run

* Rename + added comments

Co-authored-by: Pierre Slamich <pierre@openfoodfacts.org>
Co-authored-by: monsieurtanuki <11576431+monsieurtanuki@users.noreply.github.com>
2022-11-08 18:02:53 +01:00
3dca648800 feat: #2852 - Matomo message when barcode is not found (#2854)
Impacted files:
* `analytics_helper.dart`: new method about barcode not found; fixed typos
* `barcode_product_query.dart`: added Matomo (and not Sentry) message when barcode is not found
2022-08-29 15:55:58 +02:00
f6f851179c feat: Show osm attribution + removed matomo_tracker fork (#2740)
* feat: Show osm attribution + removed matomo_tracker fork

* shorten attribution

* Added back contributors
2022-08-08 11:29:46 +02:00
347c39cf89 feat: Allow to share products (#2287)
* feat: Allow to send products

* Use getProductUri instead + matomo
2022-06-15 18:05:05 +02:00
8cdea111ea feat: Matomo refinements (#2264)
* feat: Matomo refinements

* Update login_page.dart
2022-06-14 16:04:10 +02:00
8ebda96dac fix: Matomo not sending requests (country) (#2132) 2022-06-01 23:17:46 +02:00
a08203edc1 fix: Analytics switch (#2029) 2022-05-28 09:45:49 +02:00
7242bedd43 fix: Matomo refactor (#2019)
* fix: Just a little reorder

* Matomo don't need context

* Update analytics_helper.dart

* Update product_query.dart
2022-05-27 11:15:10 +02:00
5cde54d5f5 Fix Matomo errors (#1988) 2022-05-25 19:54:33 +02:00
af5b76b5ff feat: refactor: Tracking overhaul (#1913)
* feat: refactor: Tracking overhaul

* fix: Removed our setter

* Not using extracted opt out key from package

* User id

* Update analytics_helper.dart

* Update main.dart

* Update packages/smooth_app/lib/pages/product/new_product_page.dart

Co-authored-by: monsieurtanuki <fabrice_fontaine@hotmail.com>

* Update packages/smooth_app/lib/pages/product/common/product_list_page.dart

Co-authored-by: monsieurtanuki <fabrice_fontaine@hotmail.com>

* Code review

Co-authored-by: monsieurtanuki <fabrice_fontaine@hotmail.com>
2022-05-25 16:33:38 +02:00
c3b44aced2 fix: Flutter 3.0 fixes (#1814)
* fix: Flutter 3.0 fixes

* Workflows

* Update gradle

* Automated fixes

* Manual async gap fixes

* Fix merge conflict reverts

* Format

* qr_code_scanner fixes
2022-05-12 16:07:22 +02:00
f570ada7fd feat: add sentry perf (#1616) 2022-04-22 19:37:28 +02:00
e23117de31 feat: #217 - onboarding screenshot generation. (#1529)
New files:
* `app_test.dart`: Onboarding screenshots.
* `screenshot_driver.dart`: Screenshot driver.

Impacted files:
* `analytics_helper.dart`: added a special case for screenshot init.
* `main.dart`: refactored for screenshots, and more specifically moved init code to be run before calling the app.
* `next_button.dart`: added a `Key` for test/screenshots
* `Podfile.lock`: wtf
* `pubspec.lock`: impacted by `pubspec.yaml`
* `pubspec.yaml`: added integration_test and flutter_driver to dev_dependencies; upgraded the version numbers.
2022-04-11 14:38:05 +02:00
1dc1454405 feat: #501 - added switches in preferences for crash and analytics reports (#1207)
Impacted files:
* `analytics_helper.dart`: added 2 static bool fields to say if we should or not send crash and analytics reports
* `main.dart`: init of the crash and analytics report flags
* `user_preferences.dart`: getters/setters for the report flags
* `user_preferences_profile.dart`: added switches for the report flags
2022-03-13 15:08:41 +01:00
23e09bca42 fix: Not starting fix (#1153) 2022-02-18 22:38:45 +01:00
7783e412e2 feat: Added core usage logging (#1147)
* feat: Initial tracking structure

* Added testing page

* Created track constructor

* Deleted unneccassary _trackConstructor params

* Finished start track

* Fix id + country

* Finished: trackScannedProduct

* Finished: trackProductPageOpen

* Finished: trackKnowledgePanelOpen

* Finished: trackOpenLink

* Finished: trackPersonalizedRanking

* Finished: trackSearch

* Added documentation + fixed imports

* Code review

* trackKnowledgePanelOpen

* Code review

* Update main.dart
2022-02-18 17:01:14 +01:00