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
f530d19c
Commit
f530d19c
authored
Dec 21, 2018
by
Martin Wortschack
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Support navbar tracking
- Add tracking attributes to templates
parent
0a0c9282
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
5 additions
and
5 deletions
+5
-5
app/views/layouts/_search.html.haml
app/views/layouts/_search.html.haml
+1
-1
app/views/layouts/header/_default.html.haml
app/views/layouts/header/_default.html.haml
+1
-1
app/views/layouts/header/_new_dropdown.haml
app/views/layouts/header/_new_dropdown.haml
+1
-1
app/views/layouts/nav/_dashboard.html.haml
app/views/layouts/nav/_dashboard.html.haml
+2
-2
No files found.
app/views/layouts/_search.html.haml
View file @
f530d19c
...
...
@@ -2,7 +2,7 @@
-
group_data_attrs
=
{
group_path:
j
(
@group
.
path
),
name:
@group
.
name
,
issues_path:
issues_group_path
(
j
(
@group
.
path
)),
mr_path:
merge_requests_group_path
(
j
(
@group
.
path
))
}
-
if
@project
&&
@project
.
persisted?
-
project_data_attrs
=
{
project_path:
j
(
@project
.
path
),
name:
j
(
@project
.
name
),
issues_path:
project_issues_path
(
@project
),
mr_path:
project_merge_requests_path
(
@project
),
issues_disabled:
!
@project
.
issues_enabled?
}
.search.search-form
.search.search-form
{
data:
{
track_label:
"navbar_search"
,
track_event:
"activate_form_input"
}
}
=
form_tag
search_path
,
method: :get
,
class:
'form-inline'
do
|
f
|
.search-input-container
.search-input-wrap
...
...
app/views/layouts/header/_default.html.haml
View file @
f530d19c
...
...
@@ -60,7 +60,7 @@
.dropdown-menu.dropdown-menu-right
=
render
'layouts/header/help_dropdown'
-
if
header_link?
(
:user_dropdown
)
%li
.nav-item.header-user.dropdown
%li
.nav-item.header-user.dropdown
{
data:
{
track_label:
"profile_dropdown"
,
track_event:
"click_dropdown"
}
}
=
link_to
current_user
,
class:
user_dropdown_class
,
data:
{
toggle:
"dropdown"
}
do
=
image_tag
avatar_icon_for_user
(
current_user
,
23
),
width:
23
,
height:
23
,
class:
"header-user-avatar qa-user-avatar"
=
sprite_icon
(
'angle-down'
,
css_class:
'caret-down'
)
...
...
app/views/layouts/header/_new_dropdown.haml
View file @
f530d19c
%li
.header-new.dropdown
%li
.header-new.dropdown
{
data:
{
track_label:
"new_dropdown"
,
track_event:
"click_dropdown"
}
}
=
link_to
new_project_path
,
class:
"header-new-dropdown-toggle has-tooltip qa-new-menu-toggle"
,
title:
_
(
"New..."
),
ref:
'tooltip'
,
aria:
{
label:
_
(
"New..."
)
},
data:
{
toggle:
'dropdown'
,
placement:
'bottom'
,
container:
'body'
,
display:
'static'
}
do
=
sprite_icon
(
'plus-square'
,
size:
16
)
=
sprite_icon
(
'angle-down'
,
css_class:
'caret-down'
)
...
...
app/views/layouts/nav/_dashboard.html.haml
View file @
f530d19c
...
...
@@ -2,7 +2,7 @@
-# https://gitlab.com/gitlab-org/gitlab-ce/issues/49713 for more information.
%ul
.list-unstyled.navbar-sub-nav
-
if
dashboard_nav_link?
(
:projects
)
=
nav_link
(
path:
[
'root#index'
,
'projects#trending'
,
'projects#starred'
,
'dashboard/projects#index'
],
html_options:
{
id:
'nav-projects-dropdown'
,
class:
"home dropdown header-projects qa-projects-dropdown"
})
do
=
nav_link
(
path:
[
'root#index'
,
'projects#trending'
,
'projects#starred'
,
'dashboard/projects#index'
],
html_options:
{
id:
'nav-projects-dropdown'
,
class:
"home dropdown header-projects qa-projects-dropdown"
,
data:
{
track_label:
"projects_dropdown"
,
track_event:
"click_dropdown"
}
})
do
%button
{
type:
'button'
,
data:
{
toggle:
"dropdown"
}
}
=
_
(
'Projects'
)
=
sprite_icon
(
'angle-down'
,
css_class:
'caret-down'
)
...
...
@@ -10,7 +10,7 @@
=
render
"layouts/nav/projects_dropdown/show"
-
if
dashboard_nav_link?
(
:groups
)
=
nav_link
(
controller:
[
'dashboard/groups'
,
'explore/groups'
],
html_options:
{
id:
'nav-groups-dropdown'
,
class:
"home dropdown header-groups qa-groups-dropdown"
})
do
=
nav_link
(
controller:
[
'dashboard/groups'
,
'explore/groups'
],
html_options:
{
id:
'nav-groups-dropdown'
,
class:
"home dropdown header-groups qa-groups-dropdown"
,
data:
{
track_label:
"groups_dropdown"
,
track_event:
"click_dropdown"
}
})
do
%button
{
type:
'button'
,
data:
{
toggle:
"dropdown"
}
}
=
_
(
'Groups'
)
=
sprite_icon
(
'angle-down'
,
css_class:
'caret-down'
)
...
...
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