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

Metrics opt-out UI functionality #568

Merged
merged 5 commits into from
Aug 23, 2023
Merged

Metrics opt-out UI functionality #568

merged 5 commits into from
Aug 23, 2023

Conversation

halgari
Copy link
Collaborator

@halgari halgari commented Aug 22, 2023

resolves #451

This PR provides the following:

  • GlobalSettingsManager - a manager for setting app-wide settings, like metrics opt-in/opt-out. Settings are put in a global datastore and each setting has its own ID
  • UI components - Overlay view/view model for asking the users if they want to opt-in/opt-out
  • Calls to the overlay in the MainWindowViewModel, that checks to see if the user has been asked about metrics and displays the UI if they haven't. If we want to reset the opt-in settings we need only delete their answer from the settings manager. No answer means no metrics

Example of Behavior:

rider64_bZThkFu3m6

@github-actions
Copy link
Contributor

This PR conflicts with main. You need to rebase the PR before it can be merged.

@github-actions
Copy link
Contributor

This PR doesn't conflict with main anymore. It can be merged after all status checks have passed and it has been reviewed.

@codecov
Copy link

codecov bot commented Aug 23, 2023

Codecov Report

Merging #568 (5c1f4a8) into main (d84e5e5) will increase coverage by 0.25%.
The diff coverage is 88.19%.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #568      +/-   ##
==========================================
+ Coverage   67.85%   68.11%   +0.25%     
==========================================
  Files         595      602       +7     
  Lines       16065    16204     +139     
  Branches     1097     1103       +6     
==========================================
+ Hits        10901    11037     +136     
- Misses       4880     4883       +3     
  Partials      284      284              
Flag Coverage Δ
Linux 67.40% <88.19%> (+0.31%) ⬆️
Windows 67.21% <88.19%> (+0.19%) ⬆️
clean_environment_tests 68.10% <88.19%> (+0.25%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Changed Coverage Δ
src/NexusMods.App.UI/App.axaml 66.66% <ø> (ø)
...rc/NexusMods.App.UI/Resources/Language.Designer.cs 48.71% <26.31%> (-17.95%) ⬇️
...lays/MetricsOptIn/MetricsOptInDesignerViewModel.cs 90.00% <90.00%> (ø)
....UI/Overlays/MetricsOptIn/MetricsOptInViewModel.cs 91.30% <91.30%> (ø)
...NexusMods.App.UI/Theme/ButtonStyles/Hyperlink.xaml 91.66% <91.66%> (ø)
...c/MessageBox/OkCancel/MessageBoxOkCancelView.axaml 100.00% <100.00%> (ø)
...pp.UI/Overlays/MetricsOptIn/MetricsOptInView.axaml 100.00% <100.00%> (ø)
...UI/Overlays/MetricsOptIn/MetricsOptInView.axaml.cs 100.00% <100.00%> (ø)
src/NexusMods.App.UI/Overlays/OverlayController.cs 84.78% <100.00%> (+0.33%) ⬆️
src/NexusMods.App.UI/Services.cs 97.77% <100.00%> (+0.05%) ⬆️
... and 6 more

... and 4 files with indirect coverage changes

Copy link
Member

@Sewer56 Sewer56 left a comment

Choose a reason for hiding this comment

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

Looks fine to me.

@halgari halgari merged commit 42aeda6 into main Aug 23, 2023
7 checks passed
@halgari halgari deleted the 451-metrics-opt-out branch August 23, 2023 13:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants