Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
63ce368f
Commit
63ce368f
authored
Jun 25, 2019
by
Martin Wortschack
Committed by
Tim Zallmann
Jun 25, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add tracking events to onboarding app
- Add nav_source param to skipUrl for tracking
parent
387916af
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
29 additions
and
3 deletions
+29
-3
ee/app/assets/javascripts/onboarding/onboarding_helper/components/app.vue
...vascripts/onboarding/onboarding_helper/components/app.vue
+28
-2
ee/app/views/explore/onboarding/index.html.haml
ee/app/views/explore/onboarding/index.html.haml
+1
-1
No files found.
ee/app/assets/javascripts/onboarding/onboarding_helper/components/app.vue
View file @
63ce368f
...
...
@@ -2,10 +2,13 @@
import
_
from
'
underscore
'
;
import
{
mapState
,
mapActions
,
mapGetters
}
from
'
vuex
'
;
import
{
redirectTo
}
from
'
~/lib/utils/url_utility
'
;
import
Stats
from
'
ee/stats
'
;
import
OnboardingHelper
from
'
./onboarding_helper.vue
'
;
import
actionPopoverUtils
from
'
./../action_popover_utils
'
;
import
eventHub
from
'
../event_hub
'
;
const
TRACKING_CATEGORY
=
'
onboarding
'
;
export
default
{
components
:
{
OnboardingHelper
,
...
...
@@ -108,6 +111,10 @@ export default {
},
handleRestartStep
()
{
this
.
showExitTourContent
(
false
);
Stats
.
trackEvent
(
TRACKING_CATEGORY
,
'
click_link
'
,
{
label
:
this
.
getTrackingLabel
(),
property
:
'
restart_this_step
'
,
});
eventHub
.
$emit
(
'
onboardingHelper.hideActionPopover
'
);
},
handleSkipStep
()
{
...
...
@@ -115,6 +122,10 @@ export default {
const
{
selector
}
=
this
.
actionPopover
;
const
popoverEl
=
selector
?
document
.
querySelector
(
selector
)
:
null
;
if
(
popoverEl
)
{
Stats
.
trackEvent
(
TRACKING_CATEGORY
,
'
click_link
'
,
{
label
:
this
.
getTrackingLabel
(),
property
:
'
skip_this_step
'
,
});
popoverEl
.
click
();
}
}
...
...
@@ -166,9 +177,20 @@ export default {
return
;
}
// show action popover
Stats
.
trackEvent
(
TRACKING_CATEGORY
,
'
click_button
'
,
{
label
:
this
.
getTrackingLabel
(),
property
:
'
got_it
'
,
});
this
.
showActionPopover
();
},
handleShowExitTourContent
(
showExitTour
)
{
Stats
.
trackEvent
(
TRACKING_CATEGORY
,
'
click_link
'
,
{
label
:
this
.
getTrackingLabel
(),
property
:
'
exit_learn_gitlab
'
,
});
this
.
showExitTourContent
(
showExitTour
);
},
showExitTourContent
(
showExitTour
)
{
this
.
dismissPopover
=
false
;
this
.
showStepContent
=
true
;
...
...
@@ -184,6 +206,10 @@ export default {
afterAppearHook
()
{
this
.
initialShowPopover
=
true
;
},
getTrackingLabel
()
{
const
step
=
this
.
stepIndex
+
1
;
return
`part_
${
this
.
tourKey
}
_step_
${
step
}
`
;
},
},
};
</
script
>
...
...
@@ -204,7 +230,7 @@ export default {
@
clickPopoverButton=
"handleClickPopoverButton"
@
restartStep=
"handleRestartStep"
@
skipStep=
"handleSkipStep"
@
showExitTourContent=
"
s
howExitTourContent"
@
showExitTourContent=
"
handleS
howExitTourContent"
@
exitTour=
"handleExitTour"
/>
</transition>
...
...
ee/app/views/explore/onboarding/index.html.haml
View file @
63ce368f
.container.container-limited.limit-container-width.navless-container
#js-onboarding-welcome
{
data:
{
user_avatar_url:
avatar_icon_for_user
(
current_user
),
project_full_path:
@project
.
web_url
,
skip_url:
root_dashboard_path
,
from_help_menu:
params
[
:from_help_menu
]
}
}
#js-onboarding-welcome
{
data:
{
user_avatar_url:
avatar_icon_for_user
(
current_user
),
project_full_path:
@project
.
web_url
,
skip_url:
root_dashboard_path
(
nav_source:
"onboarding"
)
,
from_help_menu:
params
[
:from_help_menu
]
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment