For #9730: Add Login Dialog Prompt telemetry
parent
1497e4886e
commit
4b646c03cb
|
@ -471,6 +471,52 @@ context_menu:
|
|||
- fenix-core@mozilla.com
|
||||
expires: "2020-10-01"
|
||||
|
||||
login_dialog:
|
||||
displayed:
|
||||
type: event
|
||||
description: |
|
||||
The login dialog prompt was displayed
|
||||
bugs:
|
||||
- https://github.com/mozilla-mobile/fenix/issues/9730
|
||||
data_reviews:
|
||||
- https://github.com/mozilla-mobile/fenix/pull/13050
|
||||
notification_emails:
|
||||
- fenix-core@mozilla.com
|
||||
expires: "2021-02-01"
|
||||
cancelled:
|
||||
type: event
|
||||
description: |
|
||||
The login dialog prompt was cancelled
|
||||
bugs:
|
||||
- https://github.com/mozilla-mobile/fenix/issues/9730
|
||||
data_reviews:
|
||||
- https://github.com/mozilla-mobile/fenix/pull/13050
|
||||
notification_emails:
|
||||
- fenix-core@mozilla.com
|
||||
expires: "2021-02-01"
|
||||
saved:
|
||||
type: event
|
||||
description: |
|
||||
The login dialog prompt "save" button was pressed
|
||||
bugs:
|
||||
- https://github.com/mozilla-mobile/fenix/issues/9730
|
||||
data_reviews:
|
||||
- https://github.com/mozilla-mobile/fenix/pull/13050
|
||||
notification_emails:
|
||||
- fenix-core@mozilla.com
|
||||
expires: "2021-02-01"
|
||||
never_save:
|
||||
type: event
|
||||
description: |
|
||||
The login dialog prompt "never save" button was pressed
|
||||
bugs:
|
||||
- https://github.com/mozilla-mobile/fenix/issues/9730
|
||||
data_reviews:
|
||||
- https://github.com/mozilla-mobile/fenix/pull/13050
|
||||
notification_emails:
|
||||
- fenix-core@mozilla.com
|
||||
expires: "2021-02-01"
|
||||
|
||||
find_in_page:
|
||||
opened:
|
||||
type: event
|
||||
|
|
|
@ -24,6 +24,7 @@ import org.mozilla.fenix.GleanMetrics.ErrorPage
|
|||
import org.mozilla.fenix.GleanMetrics.Events
|
||||
import org.mozilla.fenix.GleanMetrics.FindInPage
|
||||
import org.mozilla.fenix.GleanMetrics.History
|
||||
import org.mozilla.fenix.GleanMetrics.LoginDialog
|
||||
import org.mozilla.fenix.GleanMetrics.Logins
|
||||
import org.mozilla.fenix.GleanMetrics.MediaNotification
|
||||
import org.mozilla.fenix.GleanMetrics.MediaState
|
||||
|
@ -140,6 +141,18 @@ private val Event.wrapper: EventWrapper<*>?
|
|||
{ SearchShortcuts.selected.record(it) },
|
||||
{ SearchShortcuts.selectedKeys.valueOf(it) }
|
||||
)
|
||||
is Event.LoginDialogPromptDisplayed -> EventWrapper<NoExtraKeys>(
|
||||
{ LoginDialog.displayed.record(it) }
|
||||
)
|
||||
is Event.LoginDialogPromptCancelled -> EventWrapper<NoExtraKeys>(
|
||||
{ LoginDialog.cancelled.record(it) }
|
||||
)
|
||||
is Event.LoginDialogPromptSave -> EventWrapper<NoExtraKeys>(
|
||||
{ LoginDialog.saved.record(it) }
|
||||
)
|
||||
is Event.LoginDialogPromptNeverSave -> EventWrapper<NoExtraKeys>(
|
||||
{ LoginDialog.neverSave.record(it) }
|
||||
)
|
||||
is Event.FindInPageOpened -> EventWrapper<NoExtraKeys>(
|
||||
{ FindInPage.opened.record(it) }
|
||||
)
|
||||
|
|
|
@ -21,6 +21,7 @@ import mozilla.components.feature.customtabs.CustomTabsFacts
|
|||
import mozilla.components.feature.downloads.facts.DownloadsFacts
|
||||
import mozilla.components.feature.findinpage.facts.FindInPageFacts
|
||||
import mozilla.components.feature.media.facts.MediaFacts
|
||||
import mozilla.components.feature.prompts.dialog.LoginDialogFacts
|
||||
import mozilla.components.support.base.Component
|
||||
import mozilla.components.support.base.facts.Action
|
||||
import mozilla.components.support.base.facts.Fact
|
||||
|
@ -185,6 +186,11 @@ sealed class Event {
|
|||
object OnboardingFinish : Event()
|
||||
object ChangedToDefaultBrowser : Event()
|
||||
|
||||
object LoginDialogPromptDisplayed : Event()
|
||||
object LoginDialogPromptCancelled : Event()
|
||||
object LoginDialogPromptSave : Event()
|
||||
object LoginDialogPromptNeverSave : Event()
|
||||
|
||||
object ContextualHintETPDisplayed : Event()
|
||||
object ContextualHintETPDismissed : Event()
|
||||
object ContextualHintETPOutsideTap : Event()
|
||||
|
@ -514,6 +520,11 @@ sealed class Event {
|
|||
}
|
||||
|
||||
private fun Fact.toEvent(): Event? = when (Pair(component, item)) {
|
||||
Component.FEATURE_PROMPTS to LoginDialogFacts.Items.DISPLAY -> Event.LoginDialogPromptDisplayed
|
||||
Component.FEATURE_PROMPTS to LoginDialogFacts.Items.CANCEL -> Event.LoginDialogPromptCancelled
|
||||
Component.FEATURE_PROMPTS to LoginDialogFacts.Items.NEVER_SAVE -> Event.LoginDialogPromptNeverSave
|
||||
Component.FEATURE_PROMPTS to LoginDialogFacts.Items.SAVE -> Event.LoginDialogPromptSave
|
||||
|
||||
Component.FEATURE_FINDINPAGE to FindInPageFacts.Items.CLOSE -> Event.FindInPageClosed
|
||||
Component.FEATURE_FINDINPAGE to FindInPageFacts.Items.INPUT -> Event.FindInPageSearchCommitted
|
||||
Component.FEATURE_CONTEXTMENU to ContextMenuFacts.Items.ITEM -> {
|
||||
|
|
|
@ -118,6 +118,10 @@ The following metrics are added to the ping:
|
|||
| history.removed |[event](https://mozilla.github.io/glean/book/user/metrics/event.html) |A user removed a history item |[1](https://github.com/mozilla-mobile/fenix/pull/3940)||2020-10-01 | |
|
||||
| history.removed_all |[event](https://mozilla.github.io/glean/book/user/metrics/event.html) |A user removed all history items |[1](https://github.com/mozilla-mobile/fenix/pull/3940)||2020-10-01 | |
|
||||
| history.shared |[event](https://mozilla.github.io/glean/book/user/metrics/event.html) |A user shared a history item |[1](https://github.com/mozilla-mobile/fenix/pull/3940)||2020-10-01 | |
|
||||
| login_dialog.cancelled |[event](https://mozilla.github.io/glean/book/user/metrics/event.html) |The login dialog prompt was cancelled |[1](https://github.com/mozilla-mobile/fenix/pull/13050)||2021-02-01 | |
|
||||
| login_dialog.displayed |[event](https://mozilla.github.io/glean/book/user/metrics/event.html) |The login dialog prompt was displayed |[1](https://github.com/mozilla-mobile/fenix/pull/13050)||2021-02-01 | |
|
||||
| login_dialog.never_save |[event](https://mozilla.github.io/glean/book/user/metrics/event.html) |The login dialog prompt "never save" button was pressed |[1](https://github.com/mozilla-mobile/fenix/pull/13050)||2021-02-01 | |
|
||||
| login_dialog.saved |[event](https://mozilla.github.io/glean/book/user/metrics/event.html) |The login dialog prompt "save" button was pressed |[1](https://github.com/mozilla-mobile/fenix/pull/13050)||2021-02-01 | |
|
||||
| logins.copy_login |[event](https://mozilla.github.io/glean/book/user/metrics/event.html) |A user copied a piece of a login in saved logins |[1](https://github.com/mozilla-mobile/fenix/pull/6352)||2020-10-01 | |
|
||||
| logins.delete_saved_login |[event](https://mozilla.github.io/glean/book/user/metrics/event.html) |A user confirms delete of a saved login |[1](https://github.com/mozilla-mobile/fenix/issues/11208)||2020-10-01 | |
|
||||
| logins.open_individual_login |[event](https://mozilla.github.io/glean/book/user/metrics/event.html) |A user accessed an individual login in saved logins |[1](https://github.com/mozilla-mobile/fenix/pull/6352)||2020-10-01 | |
|
||||
|
|
Loading…
Reference in New Issue