-
Notifications
You must be signed in to change notification settings - Fork 293
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
Dashboard sharing GA change events are raised when no change is made #5487
Comments
Following comms with @marrrmarrr confirming this is a 'Nice to Have' for launch, so dropping down to a P1 |
@hussain-t the The same applies to the suggested changes to |
Thanks, @aaemnnosttv. I have updated the IB. |
@hussain-t We shouldn't need to have key-specific conditions. This can probably work similar to the existing |
@hussain-t let's try to prioritize this one as one of the top-priority non-blocking issues for DS. |
Thanks, @aaemnnosttv. I have updated the IB. |
Thanks @hussain-t, this is almost there, just a few comments.
This instruction is a bit too low level and could produce in an incorrect result if the condition were to change between now and when the issue is executed. This would also be more resilient and easier to follow if described at a bit higher level, e.g. "ensure Finally, there is some |
Thanks for the suggestions, @aaemnnosttv 👍 The IB is updated. |
IB ✅ |
QA Update ✅Verified below listed scenarios.
Recording.128.mp4 |
Bug Description
In #5221 we added events for tracking interaction with the new dashboard sharing settings interface, including events for measuring the change to shared roles and sharing management.
These events are currently being triggered when their respective inputs are opened rather than by a change to the value.
Screenshots
Kapture.2022-06-30.at.16.32.36.mp4
Do not alter or remove anything below. The following sections will be managed by moderators only.
Acceptance criteria
Implementation Brief
In
assets/js/googlesitekit/modules/datastore/sharing-settings.js
, create a new selectorhaveModuleSharingSettingsChanged
with the following changes:moduleSlug
as required param andkeys
as optional param defaults tonull
.sharingSettings
andsavedSharingSettings
from the state.undefined
if either one is not loaded yet.haveSharingSettingsChanged
selector, except that it should compare thesharingSettings
andsavedSharingSettings
of the givenmoduleSlug
.keys
are provided, it should compare thesharingSettings
andsavedSharingSettings
of the givenmoduleSlug
for the givenkeys
.sharingSettings
andsavedSharingSettings
of the givenmoduleSlug
for all keys/properties.In
assets/js/components/dashboard-sharing/DashboardSharingSettings/Module.js
:haveModuleSharingSettingsChanged
selector.moduleSlug
and'management'
as themoduleSlug
andkeys
params.trackEvent
function within a newuseEffect
hook if thehaveModuleSharingSettingsChanged
selector returns true.management
from thegetSharingManagement
selector to the track event name.trackEvent
call from thehandleOnChange
callback and remove the unnecessary dependencies.In
assets/js/components/dashboard-sharing/UserRoleSelect.js
:haveModuleSharingSettingsChanged
selector.moduleSlug
and'sharedRoles'
as themoduleSlug
andkeys
params.toggleEditMode
callback, ensuretrackEvent
is called when the edit mode is being toggled off if thehaveModuleSharingSettingsChanged
selector returnstrue
.useCallback
dependencies appropriately.initialSharedRoles
state occurrences that are not used anymore, as the new selector will handle this.Test Coverage
haveModuleSharingSettingsChanged
selector.QA Brief
Changelog entry
The text was updated successfully, but these errors were encountered: