* fix: 1815 - around context.mounted
The PR is about two related topics:
* Removing all the `ignore: use_build_context_synchronously`
* Replacing all the `State<StatefulWidget> widget` by `BuildContext context`, now that it's possible in flutter
* Update packages/smooth_app/lib/pages/onboarding/permissions_page.dart
* format fix
* work manager used for bg schedule
* removed swith case
* remove unwanted contrains and randomize the taskid
as image.others might fail
* added translations
* new product image upload working
* removed debug for work manager
* delete photo when uploaded
* use await keywords while initializing
* refactor the code
* fix show image after queed
* serialize and deserialze input data seperately
* add an instant product in the loacl db to
let the user not confuse
* added smooth random class
* use smooth random to generate 8 digits
* remove unneccesary await
* update the local db with a product if not yet
uploaded
* update local databse after sucessful
update into server
* don't refresh automatically after upload queed
* supply language code to work manager
* import app localizations
* small refactoring
* refactor the code for work manager
* iOS Config for WorkManager
* formatting
* suggestion by tolemon
Co-authored-by: Pierre Slamich <pierre.slamich@gmail.com>
* suggestion by tolemon
Co-authored-by: Pierre Slamich <pierre.slamich@gmail.com>
* suggestion by tolemon
Co-authored-by: Pierre Slamich <pierre.slamich@gmail.com>
* small fix
* add swith case to the workmanager
* efficient switch case
* Update packages/smooth_app/lib/l10n/app_en.arb
Suggested by tolemon
Co-authored-by: Pierre Slamich <pierre.slamich@gmail.com>
* minor fix
* Basic Input details add are now run in background
* basic details are now updated immediatly
even without internet
* nutrient edit task are now background
and also conflict when recheduling task is managed
* menu screen for background tasks and
nutrition edits are now backgrounded
* button for retry now works in the bg tasks screen
* formatting
* genaralised function for non image tasks
* should retry set default to false
* better mechanism for retries and refactor
* refactor and consts duration of 3s for snackbars
* now language country and user are properly dropped
* Update packages/smooth_app/ios/Runner/Info.plist
* Update packages/smooth_app/ios/Runner/AppDelegate.swift
* Error messages fixed
* custom workmanager dependencies added
* migrated basic detail task from work manager to
taskmanager
* chanages to do the product edit changes in bg
* dart format
* cleaned the function calls when doing bg task
* dao_task edited
* unnecessary methods removed
* use int as id instead of string
* added comments and made fields final
* used const variable instead of hardcoded ones
* get pending tasks from taskManager class
* refactor
* handled exceptions
* string instead of int
* remove unused plugin
* removed unnessary files
* update to localdatabase working without islotes
* suggestions left as comments on PR
* deleted unncessary Random class
* doc added
* Remove WorkManager iOS code
* reset publock
* reset publock
* remove harcoded color
* used duration constant class instead of harcoded
* make methods to generate taskId
* dart frmt
* changes as per the code review
* string buffer , var documentation and rename
* error fix
* refactor and spelling corrections
* /// instead of //
* dart ff formater
* more refactorings
* Update background_task_helper.dart
* dart ff fix
Co-authored-by: monsieurtanuki <fabrice_fontaine@hotmail.com>
Co-authored-by: Edouard Marquez <g123k@users.noreply.github.com>
Co-authored-by: Pierre Slamich <pierre.slamich@gmail.com>
Co-authored-by: Pierre Slamich <pierre@openfoodfacts.org>
Impacted files:
* `onboarding_loader.dart`: minor bug fix that prevented data cleaning after onboarding.
* `sample_product_data.json`: refreshed data from the server.
Deleted file:
* `sample_knowledge_panels.json`: now part of `sample_product_data.json`
Impacted files:
* `knowledge_panel_page_template.dart`: now using full product instead of just knowledge panels
* `onboarding_data_product.dart`: removed knowledge panels references as they're part of product now
* `onboarding_loader.dart`removed knowledge panels references
* `sample_product_data.json`: refreshed data including knowledge panels
Now that knowledge panels are an explicit field of product, we can simplify the code.
Deleted files:
* `onboarding_data_knowledge_panels.dart`
* `tmp.dart`
Impacted files:
* `knowledge_panels_template.dart`: now using the new `OnboardingDataProduct.forKnowledgePanels` constructor
* `onboarding_data_product.dart`: refactored in order to include knowledge panels as part of product
* `onboarding_loader.dart`: now using the new `OnboardingDataProduct` constructors
* `preferences_page.dart`: now using the new `OnboardingDataProduct.forProduct` constructor
* chore(develop): release 0.2.0
* added dark theme on personalized page
* Certain Changes
* Reverted changelog changes
* wrapped the circular progress indicator with center widget
* wrapped CircularProgressIndicator with Center Widget
* Added Floating ActionButton
* Added PopUp Menu Action
* Added Pop UP Action Button
* Added Pop-Up Action Button
* Added PopUp action menu
* Added PopUp action Menu
* Added Types
* Certain Changes
* Certain Changes
* No need of Positioned Widget
* Added Consent UI
* Added Consent UI
* certain Changes
* certain changes
* certain changes
* certain Chnages
* certain Chnages
* removed hardCoded boolean value
* changes made
* Added new Strings
* png file removed
* changed color
* changes made
* comma Added
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Marvin M <39344769+M123-dev@users.noreply.github.com>
Deleted files:
* `sample_eco_knowledge_panels.json`: replaced by new file `sample_knowledge_panels.json`
* `sample_health_knowledge_panels.json`: replaced by new file `sample_knowledge_panels.json`
New files:
* `abstract_onboarding_data.dart`: Abstraction of data we download, store and reuse at onboarding.
* `dao_string.dart`: Where we store strings.
* `loading_dialog.dart`: Dialog with a stop button, while a future is running.
* `onboarding_data_knowledge_panels.dart`: Helper around knowledge panels we download, store and reuse at onboarding.
* `onboarding_data_product.dart`: Helper around a product we download, store and reuse at onboarding.
* `onboarding_loader.dart`: Helper around data we download, store and reuse at onboarding.
* `sample_knowledge_panels.json`: json data downloaded today for en_US, cf. onboarding_data_knowledge_panels.dart
* `tmp.dart`: Fixes to off-dart.
Impacted files:
* `knowledge_panel_page_template.dart`: added parameters to 1. use the database (and downloaded data) and 2. limit the display to a given panel
* `knowlegde_panel_builder.dart`: added a method to display only one panel
* `local_database.dart`: added new dao `DaoString`
* `new_product_page.dart`: refactored
* `next_button.dart`: added an optional call to async methods at "next" time - e.g. data download
* `nutrition_page_loaded.dart`: now uses the new `LoadingDialog`
* `onboarding_flow_navigator.dart`: now using the database to get more relevant (previoulsy downloaded) data
* `preferences_page.dart`: now using previously downloaded data instead of assets
* `product_dialog_helper.dart`: now uses the new `LoadingDialog`
* `question_card.dart`: unrelated minor refactoring
* `sample_eco_card_page.dart`: now using previously downloaded data instead of assets, and displaying only the environment card
* `sample_health_card_page.dart`: now using previously downloaded data instead of assets, and displaying only the health card
* `sample_product_json.dart`: json data downloaded today for en_US, cf. onboarding_data_product.dart
* `sign_up_page.dart`: now uses the new `LoadingDialog`