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
9b7d9365
Commit
9b7d9365
authored
Sep 08, 2021
by
Axel García
Committed by
Axel Garcia
Sep 13, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use track_action for data attributes on HAML files
This also updates the related specs
parent
825eec24
Changes
24
Show whitespace changes
Inline
Side-by-side
Showing
24 changed files
with
61 additions
and
61 deletions
+61
-61
app/helpers/issuables_helper.rb
app/helpers/issuables_helper.rb
+1
-1
app/helpers/nav/new_dropdown_helper.rb
app/helpers/nav/new_dropdown_helper.rb
+9
-9
app/helpers/nav/top_nav_helper.rb
app/helpers/nav/top_nav_helper.rb
+2
-2
app/views/devise/shared/_tabs_normal.html.haml
app/views/devise/shared/_tabs_normal.html.haml
+1
-1
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
+4
-4
app/views/layouts/header/_new_dropdown.html.haml
app/views/layouts/header/_new_dropdown.html.haml
+1
-1
app/views/projects/_import_project_pane.html.haml
app/views/projects/_import_project_pane.html.haml
+1
-1
app/views/projects/_new_project_fields.html.haml
app/views/projects/_new_project_fields.html.haml
+6
-6
app/views/projects/project_templates/_template.html.haml
app/views/projects/project_templates/_template.html.haml
+2
-2
app/views/search/results/_commit.html.haml
app/views/search/results/_commit.html.haml
+1
-1
app/views/shared/_help_dropdown_forum_link.html.haml
app/views/shared/_help_dropdown_forum_link.html.haml
+1
-1
app/views/shared/_visibility_radios.html.haml
app/views/shared/_visibility_radios.html.haml
+1
-1
app/views/shared/issuable/_sidebar.html.haml
app/views/shared/issuable/_sidebar.html.haml
+1
-1
app/views/shared/issuable/form/_type_selector.html.haml
app/views/shared/issuable/form/_type_selector.html.haml
+1
-1
ee/app/helpers/ee/nav/new_dropdown_helper.rb
ee/app/helpers/ee/nav/new_dropdown_helper.rb
+1
-1
ee/app/views/layouts/header/_ee_subscribable_banner.html.haml
...pp/views/layouts/header/_ee_subscribable_banner.html.haml
+4
-4
ee/app/views/layouts/header/_user_notification_dot.html.haml
ee/app/views/layouts/header/_user_notification_dot.html.haml
+1
-1
ee/app/views/projects/_new_ci_cd_only_project_pane.html.haml
ee/app/views/projects/_new_ci_cd_only_project_pane.html.haml
+2
-2
ee/app/views/registrations/groups_projects/new.html.haml
ee/app/views/registrations/groups_projects/new.html.haml
+4
-4
ee/app/views/registrations/projects/new.html.haml
ee/app/views/registrations/projects/new.html.haml
+4
-4
ee/spec/helpers/nav/new_dropdown_helper_spec.rb
ee/spec/helpers/nav/new_dropdown_helper_spec.rb
+1
-1
spec/helpers/nav/new_dropdown_helper_spec.rb
spec/helpers/nav/new_dropdown_helper_spec.rb
+9
-9
spec/helpers/nav/top_nav_helper_spec.rb
spec/helpers/nav/top_nav_helper_spec.rb
+2
-2
No files found.
app/helpers/issuables_helper.rb
View file @
9b7d9365
...
...
@@ -373,7 +373,7 @@ module IssuablesHelper
is_collapsed:
is_collapsed
,
track_label:
"right_sidebar"
,
track_property:
"update_todo"
,
track_
event
:
"click_button"
,
track_
action
:
"click_button"
,
track_value:
""
}
end
...
...
app/helpers/nav/new_dropdown_helper.rb
View file @
9b7d9365
...
...
@@ -32,7 +32,7 @@ module Nav
id:
'new_project'
,
title:
_
(
'New project/repository'
),
href:
new_project_path
(
namespace_id:
group
.
id
),
data:
{
track_
event
:
'click_link_new_project_group'
,
track_label:
'plus_menu_dropdown'
}
data:
{
track_
action
:
'click_link_new_project_group'
,
track_label:
'plus_menu_dropdown'
}
)
)
end
...
...
@@ -43,7 +43,7 @@ module Nav
id:
'new_subgroup'
,
title:
_
(
'New subgroup'
),
href:
new_group_path
(
parent_id:
group
.
id
),
data:
{
track_
event
:
'click_link_new_subgroup'
,
track_label:
'plus_menu_dropdown'
}
data:
{
track_
action
:
'click_link_new_subgroup'
,
track_label:
'plus_menu_dropdown'
}
)
)
end
...
...
@@ -74,7 +74,7 @@ module Nav
id:
'new_issue'
,
title:
_
(
'New issue'
),
href:
new_project_issue_path
(
project
),
data:
{
track_
event
:
'click_link_new_issue'
,
track_label:
'plus_menu_dropdown'
,
qa_selector:
'new_issue_link'
}
data:
{
track_
action
:
'click_link_new_issue'
,
track_label:
'plus_menu_dropdown'
,
qa_selector:
'new_issue_link'
}
)
)
end
...
...
@@ -85,7 +85,7 @@ module Nav
id:
'new_mr'
,
title:
_
(
'New merge request'
),
href:
project_new_merge_request_path
(
merge_project
),
data:
{
track_
event
:
'click_link_new_mr'
,
track_label:
'plus_menu_dropdown'
}
data:
{
track_
action
:
'click_link_new_mr'
,
track_label:
'plus_menu_dropdown'
}
)
)
end
...
...
@@ -96,7 +96,7 @@ module Nav
id:
'new_snippet'
,
title:
_
(
'New snippet'
),
href:
new_project_snippet_path
(
project
),
data:
{
track_
event
:
'click_link_new_snippet_project'
,
track_label:
'plus_menu_dropdown'
}
data:
{
track_
action
:
'click_link_new_snippet_project'
,
track_label:
'plus_menu_dropdown'
}
)
)
end
...
...
@@ -124,7 +124,7 @@ module Nav
id:
'general_new_project'
,
title:
_
(
'New project/repository'
),
href:
new_project_path
,
data:
{
track_
event
:
'click_link_new_project'
,
track_label:
'plus_menu_dropdown'
,
qa_selector:
'global_new_project_link'
}
data:
{
track_
action
:
'click_link_new_project'
,
track_label:
'plus_menu_dropdown'
,
qa_selector:
'global_new_project_link'
}
)
)
end
...
...
@@ -135,7 +135,7 @@ module Nav
id:
'general_new_group'
,
title:
_
(
'New group'
),
href:
new_group_path
,
data:
{
track_
event
:
'click_link_new_group'
,
track_label:
'plus_menu_dropdown'
}
data:
{
track_
action
:
'click_link_new_group'
,
track_label:
'plus_menu_dropdown'
}
)
)
end
...
...
@@ -146,7 +146,7 @@ module Nav
id:
'general_new_snippet'
,
title:
_
(
'New snippet'
),
href:
new_snippet_path
,
data:
{
track_
event
:
'click_link_new_snippet_parent'
,
track_label:
'plus_menu_dropdown'
,
qa_selector:
'global_new_snippet_link'
}
data:
{
track_
action
:
'click_link_new_snippet_parent'
,
track_label:
'plus_menu_dropdown'
,
qa_selector:
'global_new_snippet_link'
}
)
)
end
...
...
@@ -164,7 +164,7 @@ module Nav
emoji:
(
'shaking_hands'
if
experiment_enabled?
(
:invite_members_new_dropdown
)),
href:
href
,
data:
{
track_
event
:
'click_link'
,
track_
action
:
'click_link'
,
track_label:
tracking_label
,
track_property:
experiment_tracking_category_and_group
(
:invite_members_new_dropdown
)
}
...
...
app/helpers/nav/top_nav_helper.rb
View file @
9b7d9365
...
...
@@ -98,7 +98,7 @@ module Nav
builder
.
add_primary_menu_item_with_shortcut
(
active:
nav
==
'project'
||
active_nav_link?
(
path:
%w[root#index projects#trending projects#starred dashboard/projects#index]
),
css_class:
'qa-projects-dropdown'
,
data:
{
track_label:
"projects_dropdown"
,
track_
event
:
"click_dropdown"
},
data:
{
track_label:
"projects_dropdown"
,
track_
action
:
"click_dropdown"
},
view:
PROJECTS_VIEW
,
shortcut_href:
dashboard_projects_path
,
**
projects_menu_item_attrs
...
...
@@ -112,7 +112,7 @@ module Nav
builder
.
add_primary_menu_item_with_shortcut
(
active:
nav
==
'group'
||
active_nav_link?
(
path:
%w[dashboard/groups explore/groups]
),
css_class:
'qa-groups-dropdown'
,
data:
{
track_label:
"groups_dropdown"
,
track_
event
:
"click_dropdown"
},
data:
{
track_label:
"groups_dropdown"
,
track_
action
:
"click_dropdown"
},
view:
GROUPS_VIEW
,
shortcut_href:
dashboard_groups_path
,
**
groups_menu_item_attrs
...
...
app/views/devise/shared/_tabs_normal.html.haml
View file @
9b7d9365
...
...
@@ -6,4 +6,4 @@
%a
.nav-link.active
{
href:
'#login-pane'
,
data:
{
toggle:
'tab'
,
qa_selector:
'sign_in_tab'
},
role:
'tab'
}=
tab_title
-
if
render_signup_link
&&
allow_signup?
%li
.nav-item
{
role:
'presentation'
}
%a
.nav-link
{
href:
'#register-pane'
,
data:
{
track_label:
'sign_in_register'
,
track_property:
''
,
track_
event
:
'click_button'
,
track_value:
''
,
toggle:
'tab'
,
qa_selector:
'register_tab'
},
role:
'tab'
}
Register
%a
.nav-link
{
href:
'#register-pane'
,
data:
{
track_label:
'sign_in_register'
,
track_property:
''
,
track_
action
:
'click_button'
,
track_value:
''
,
toggle:
'tab'
,
qa_selector:
'register_tab'
},
role:
'tab'
}
Register
app/views/layouts/_search.html.haml
View file @
9b7d9365
.search.search-form
{
data:
{
track_label:
"navbar_search"
,
track_
event
:
"activate_form_input"
,
track_value:
""
}
}
.search.search-form
{
data:
{
track_label:
"navbar_search"
,
track_
action
:
"activate_form_input"
,
track_value:
""
}
}
=
form_tag
search_path
,
method: :get
,
class:
'form-inline form-control'
do
|
_f
|
.search-input-container
.search-input-wrap
...
...
app/views/layouts/header/_default.html.haml
View file @
9b7d9365
...
...
@@ -45,7 +45,7 @@
=
link_to
assigned_issues_dashboard_path
,
title:
_
(
'Issues'
),
class:
'dashboard-shortcuts-issues'
,
aria:
{
label:
_
(
'Issues'
)
},
data:
{
qa_selector:
'issues_shortcut_button'
,
toggle:
'tooltip'
,
placement:
'bottom'
,
track_label:
'main_navigation'
,
track_
event
:
'click_issues_link'
,
track_
action
:
'click_issues_link'
,
track_property:
'navigation'
,
container:
'body'
}
do
=
sprite_icon
(
'issues'
)
...
...
@@ -59,7 +59,7 @@
toggle:
"dropdown"
,
placement:
'bottom'
,
track_label:
'main_navigation'
,
track_
event
:
'click_merge_link'
,
track_
action
:
'click_merge_link'
,
track_property:
'navigation'
,
container:
'body'
}
do
=
sprite_icon
(
'git-merge'
)
...
...
@@ -85,7 +85,7 @@
=
link_to
dashboard_todos_path
,
title:
_
(
'To-Do List'
),
aria:
{
label:
_
(
'To-Do List'
)
},
class:
'shortcuts-todos'
,
data:
{
qa_selector:
'todos_shortcut_button'
,
toggle:
'tooltip'
,
placement:
'bottom'
,
track_label:
'main_navigation'
,
track_
event
:
'click_to_do_link'
,
track_
action
:
'click_to_do_link'
,
track_property:
'navigation'
,
container:
'body'
}
do
=
sprite_icon
(
'todo-done'
)
...
...
@@ -101,7 +101,7 @@
.dropdown-menu.dropdown-menu-right
=
render
'layouts/header/help_dropdown'
-
if
header_link?
(
:user_dropdown
)
%li
.nav-item.header-user.js-nav-user-dropdown.dropdown
{
data:
{
track_label:
"profile_dropdown"
,
track_
event
:
"click_dropdown"
,
track_value:
""
,
qa_selector:
'user_menu'
},
class:
(
'mr-0'
if
has_impersonation_link
)
}
%li
.nav-item.header-user.js-nav-user-dropdown.dropdown
{
data:
{
track_label:
"profile_dropdown"
,
track_
action
:
"click_dropdown"
,
track_value:
""
,
qa_selector:
'user_menu'
},
class:
(
'mr-0'
if
has_impersonation_link
)
}
=
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"
,
alt:
current_user
.
name
=
render_if_exists
'layouts/header/user_notification_dot'
,
project:
project
,
namespace:
group
...
...
app/views/layouts/header/_new_dropdown.html.haml
View file @
9b7d9365
...
...
@@ -6,7 +6,7 @@
-
return
if
menu_sections
.
empty?
%li
.header-new.dropdown
{
class:
top_class
,
data:
{
track_label:
"new_dropdown"
,
track_
event
:
"click_dropdown"
}
}
%li
.header-new.dropdown
{
class:
top_class
,
data:
{
track_label:
"new_dropdown"
,
track_
action
:
"click_dropdown"
}
}
=
link_to
new_project_path
,
class:
"header-new-dropdown-toggle has-tooltip"
,
id:
"js-onboarding-new-project-link"
,
title:
title
,
ref:
'tooltip'
,
aria:
{
label:
title
},
data:
{
toggle:
'dropdown'
,
placement:
'bottom'
,
container:
'body'
,
display:
'static'
,
qa_selector:
'new_menu_toggle'
}
do
=
sprite_icon
(
'plus-square'
)
=
sprite_icon
(
'chevron-down'
,
css_class:
'caret-down'
)
...
...
app/views/projects/_import_project_pane.html.haml
View file @
9b7d9365
...
...
@@ -76,7 +76,7 @@
-
if
phabricator_import_enabled?
%div
=
link_to
new_import_phabricator_path
,
class:
'gl-button btn-default btn import_phabricator'
,
data:
{
track_label:
"
#{
track_label
}
"
,
track_
event
:
"click_button"
,
track_property:
"phabricator"
}
do
=
link_to
new_import_phabricator_path
,
class:
'gl-button btn-default btn import_phabricator'
,
data:
{
track_label:
"
#{
track_label
}
"
,
track_
action
:
"click_button"
,
track_property:
"phabricator"
}
do
.gl-button-icon
=
custom_icon
(
'issues'
)
=
_
(
"Phabricator Tasks"
)
...
...
app/views/projects/_new_project_fields.html.haml
View file @
9b7d9365
...
...
@@ -8,7 +8,7 @@
.form-group.project-name.col-sm-12
=
f
.
label
:name
,
class:
'label-bold'
do
%span
=
_
(
"Project name"
)
=
f
.
text_field
:name
,
placeholder:
"My awesome project"
,
class:
"form-control gl-form-input input-lg"
,
data:
{
track_label:
"
#{
track_label
}
"
,
track_
event
:
"activate_form_input"
,
track_property:
"project_name"
,
track_value:
""
},
required:
true
,
aria:
{
required:
true
}
=
f
.
text_field
:name
,
placeholder:
"My awesome project"
,
class:
"form-control gl-form-input input-lg"
,
data:
{
track_label:
"
#{
track_label
}
"
,
track_
action
:
"activate_form_input"
,
track_property:
"project_name"
,
track_value:
""
},
required:
true
,
aria:
{
required:
true
}
.form-group.project-path.col-sm-6
=
f
.
label
:namespace_id
,
class:
'label-bold'
do
%span
=
_
(
'Project URL'
)
...
...
@@ -26,7 +26,7 @@
display_path:
true
,
extra_group:
namespace_id
),
{},
{
class:
'select2 js-select-namespace qa-project-namespace-select block-truncated'
,
data:
{
track_label:
"
#{
track_label
}
"
,
track_
event
:
"activate_form_input"
,
track_property:
"project_path"
,
track_value:
""
,
qa_selector:
"select_namespace_dropdown"
}})
{
class:
'select2 js-select-namespace qa-project-namespace-select block-truncated'
,
data:
{
track_label:
"
#{
track_label
}
"
,
track_
action
:
"activate_form_input"
,
track_property:
"project_path"
,
track_value:
""
,
qa_selector:
"select_namespace_dropdown"
}})
-
else
.input-group-prepend.static-namespace.flex-shrink-0.has-tooltip
{
title:
user_url
(
current_user
.
username
)
+
'/'
}
.input-group-text.border-0
...
...
@@ -45,7 +45,7 @@
.form-group
=
f
.
label
:description
,
class:
'label-bold'
do
=
s_
(
'ProjectsNew|Project description %{tag_start}(optional)%{tag_end}'
).
html_safe
%
{
tag_start:
'<span>'
.
html_safe
,
tag_end:
'</span>'
.
html_safe
}
=
f
.
text_area
:description
,
placeholder:
s_
(
'ProjectsNew|Description format'
),
class:
"form-control gl-form-input"
,
rows:
3
,
maxlength:
250
,
data:
{
track_label:
"
#{
track_label
}
"
,
track_
event
:
"activate_form_input"
,
track_property:
"project_description"
,
track_value:
""
}
=
f
.
text_area
:description
,
placeholder:
s_
(
'ProjectsNew|Description format'
),
class:
"form-control gl-form-input"
,
rows:
3
,
maxlength:
250
,
data:
{
track_label:
"
#{
track_label
}
"
,
track_
action
:
"activate_form_input"
,
track_property:
"project_description"
,
track_value:
""
}
=
f
.
label
:visibility_level
,
class:
'label-bold'
do
=
s_
(
'ProjectsNew|Visibility Level'
)
...
...
@@ -56,12 +56,12 @@
.form-group.row.initialize-with-readme-setting
%div
{
:class
=>
"col-sm-12"
}
.form-check
=
check_box_tag
'project[initialize_with_readme]'
,
'1'
,
true
,
class:
'form-check-input'
,
data:
{
qa_selector:
"initialize_with_readme_checkbox"
,
track_label:
"
#{
track_label
}
"
,
track_
event
:
"activate_form_input"
,
track_property:
"init_with_readme"
,
track_value:
""
}
=
check_box_tag
'project[initialize_with_readme]'
,
'1'
,
true
,
class:
'form-check-input'
,
data:
{
qa_selector:
"initialize_with_readme_checkbox"
,
track_label:
"
#{
track_label
}
"
,
track_
action
:
"activate_form_input"
,
track_property:
"init_with_readme"
,
track_value:
""
}
=
label_tag
'project[initialize_with_readme]'
,
class:
'form-check-label'
do
.option-title
%strong
=
s_
(
'ProjectsNew|Initialize repository with a README'
)
.option-description
=
s_
(
'ProjectsNew|Allows you to immediately clone this project’s repository. Skip this if you plan to push up an existing repository.'
)
=
f
.
submit
_
(
'Create project'
),
class:
"btn gl-button btn-confirm"
,
data:
{
track_label:
"
#{
track_label
}
"
,
track_
event
:
"click_button"
,
track_property:
"create_project"
,
track_value:
""
}
=
link_to
_
(
'Cancel'
),
dashboard_projects_path
,
class:
'btn gl-button btn-default btn-cancel'
,
data:
{
track_label:
"
#{
track_label
}
"
,
track_
event
:
"click_button"
,
track_property:
"cancel"
,
track_value:
""
}
=
f
.
submit
_
(
'Create project'
),
class:
"btn gl-button btn-confirm"
,
data:
{
track_label:
"
#{
track_label
}
"
,
track_
action
:
"click_button"
,
track_property:
"create_project"
,
track_value:
""
}
=
link_to
_
(
'Cancel'
),
dashboard_projects_path
,
class:
'btn gl-button btn-default btn-cancel'
,
data:
{
track_label:
"
#{
track_label
}
"
,
track_
action
:
"click_button"
,
track_property:
"cancel"
,
track_value:
""
}
app/views/projects/project_templates/_template.html.haml
View file @
9b7d9365
...
...
@@ -8,9 +8,9 @@
.text-muted
=
template
.
description
.controls.d-flex.align-items-center
%a
.btn.gl-button.btn-default.gl-mr-3
{
href:
template
.
preview
,
rel:
'noopener noreferrer'
,
target:
'_blank'
,
data:
{
track_label:
"template_preview"
,
track_property:
template
.
name
,
track_
event
:
"click_button"
,
track_value:
""
}
}
%a
.btn.gl-button.btn-default.gl-mr-3
{
href:
template
.
preview
,
rel:
'noopener noreferrer'
,
target:
'_blank'
,
data:
{
track_label:
"template_preview"
,
track_property:
template
.
name
,
track_
action
:
"click_button"
,
track_value:
""
}
}
=
_
(
"Preview"
)
%label
.btn.gl-button.btn-confirm.template-button.choose-template.gl-mb-0
{
for:
template
.
name
}
%input
{
type:
"radio"
,
autocomplete:
"off"
,
name:
"project[template_name]"
,
id:
template
.
name
,
value:
template
.
name
,
data:
{
track_label:
"template_use"
,
track_property:
template
.
name
,
track_
event
:
"click_button"
,
track_value:
""
}
}
%input
{
type:
"radio"
,
autocomplete:
"off"
,
name:
"project[template_name]"
,
id:
template
.
name
,
value:
template
.
name
,
data:
{
track_label:
"template_use"
,
track_property:
template
.
name
,
track_
action
:
"click_button"
,
track_value:
""
}
}
%span
{
data:
{
qa_selector:
'use_template_button'
}
}
=
_
(
"Use template"
)
app/views/search/results/_commit.html.haml
View file @
9b7d9365
=
render
'projects/commits/commit'
,
project:
commit
.
project
,
commit:
commit
,
ref:
nil
,
show_project_name:
@project
.
nil?
,
link_data_attrs:
{
track_
event
:
'click_text'
,
track_label:
'commit_title'
,
track_property:
'search_result'
}
=
render
'projects/commits/commit'
,
project:
commit
.
project
,
commit:
commit
,
ref:
nil
,
show_project_name:
@project
.
nil?
,
link_data_attrs:
{
track_
action
:
'click_text'
,
track_label:
'commit_title'
,
track_property:
'search_result'
}
app/views/shared/_help_dropdown_forum_link.html.haml
View file @
9b7d9365
=
link_to
_
(
"Community forum"
),
"https://forum.gitlab.com/"
,
target:
'_blank'
,
class:
'text-nowrap'
,
rel:
'noopener noreferrer'
,
data:
{
'track_
event
'
:
'click_forum'
,
'track_property'
:
'question_menu'
}
rel:
'noopener noreferrer'
,
data:
{
'track_
action
'
:
'click_forum'
,
'track_property'
:
'question_menu'
}
app/views/shared/_visibility_radios.html.haml
View file @
9b7d9365
...
...
@@ -3,7 +3,7 @@
-
available_visibility_levels
.
each
do
|
level
|
.form-check
=
form
.
radio_button
model_method
,
level
,
checked:
(
selected_level
==
level
),
class:
'form-check-input'
,
data:
{
track_label:
"blank_project"
,
track_
event
:
"activate_form_input"
,
track_property:
"
#{
model_method
}
_
#{
level
}
"
,
track_value:
""
,
qa_selector:
"
#{
visibility_level_label
(
level
).
downcase
}
_radio"
}
=
form
.
radio_button
model_method
,
level
,
checked:
(
selected_level
==
level
),
class:
'form-check-input'
,
data:
{
track_label:
"blank_project"
,
track_
action
:
"activate_form_input"
,
track_property:
"
#{
model_method
}
_
#{
level
}
"
,
track_value:
""
,
qa_selector:
"
#{
visibility_level_label
(
level
).
downcase
}
_radio"
}
=
form
.
label
"
#{
model_method
}
_
#{
level
}
"
,
class:
'form-check-label'
do
=
visibility_level_icon
(
level
)
.option-title
...
...
app/views/shared/issuable/_sidebar.html.haml
View file @
9b7d9365
...
...
@@ -88,7 +88,7 @@
=
custom_icon
(
'icon_arrow_right'
)
.dropdown.sidebar-move-issue-dropdown.hide-collapsed
%button
.gl-button.btn.btn-default.btn-block.js-sidebar-dropdown-toggle.js-move-issue
{
type:
'button'
,
data:
{
toggle:
'dropdown'
,
display:
'static'
,
track_label:
"right_sidebar"
,
track_property:
"move_issue"
,
track_
event
:
"click_button"
,
track_value:
""
}
}
data:
{
toggle:
'dropdown'
,
display:
'static'
,
track_label:
"right_sidebar"
,
track_property:
"move_issue"
,
track_
action
:
"click_button"
,
track_value:
""
}
}
=
_
(
'Move issue'
)
.dropdown-menu.dropdown-menu-selectable.dropdown-extended-height
=
dropdown_title
(
_
(
'Move issue'
))
...
...
app/views/shared/issuable/form/_type_selector.html.haml
View file @
9b7d9365
...
...
@@ -21,7 +21,7 @@
%li
.js-filter-issuable-type
=
link_to
new_project_issue_path
(
@project
),
class:
(
"is-active"
if
issuable
.
issue?
)
do
#{
sprite_icon
(
work_item_type_icon
(
:issue
),
css_class:
'gl-icon'
)
}
#{
_
(
"Issue"
)
}
%li
.js-filter-issuable-type
{
data:
{
track:
{
event
:
"select_issue_type_incident"
,
label:
"select_issue_type_incident_dropdown_option"
}
}
}
%li
.js-filter-issuable-type
{
data:
{
track:
{
action
:
"select_issue_type_incident"
,
label:
"select_issue_type_incident_dropdown_option"
}
}
}
=
link_to
new_project_issue_path
(
@project
,
{
issuable_template:
'incident'
,
issue:
{
issue_type:
'incident'
}
}),
class:
(
"is-active"
if
issuable
.
incident?
)
do
#{
sprite_icon
(
work_item_type_icon
(
:incident
),
css_class:
'gl-icon'
)
}
#{
_
(
"Incident"
)
}
...
...
ee/app/helpers/ee/nav/new_dropdown_helper.rb
View file @
9b7d9365
...
...
@@ -14,7 +14,7 @@ module EE
id:
'create_epic'
,
title:
_
(
'New epic'
),
href:
new_group_epic_path
(
group
),
data:
{
track_
event
:
'click_link_new_epic'
,
track_label:
'plus_menu_dropdown'
}
data:
{
track_
action
:
'click_link_new_epic'
,
track_label:
'plus_menu_dropdown'
}
)
end
end
...
...
ee/app/views/layouts/header/_ee_subscribable_banner.html.haml
View file @
9b7d9365
...
...
@@ -4,7 +4,7 @@
-
if
message
.
present?
&&
subscribable
.
present?
.container-fluid.container-limited.pt-3
.gl-alert.gitlab-ee-license-banner.hidden.js-gitlab-ee-license-banner.gl-pb-7.gl-border-1.gl-border-solid.gl-border-gray-100.gl-rounded-base
{
role:
'alert'
,
data:
{
license_expiry:
subscribable
.
expires_at
}
}
%button
.gl-alert-dismiss
{
type:
'button'
,
'aria-label'
=>
'Dismiss'
,
data:
{
track_
event
:
'click_button'
,
track_label:
'dismiss_subscribable_banner'
}
}
%button
.gl-alert-dismiss
{
type:
'button'
,
'aria-label'
=>
'Dismiss'
,
data:
{
track_
action
:
'click_button'
,
track_label:
'dismiss_subscribable_banner'
}
}
=
sprite_icon
(
'close'
,
css_class:
'gl-icon js-close'
)
.gl-display-flex.gl-flex-direction-row.gl-align-items-center
.gl-pr-6.gl-pl-5.gl-pt-3.gl-display-none.gl-sm-display-block
...
...
@@ -19,7 +19,7 @@
=
message
-
if
subscribable
.
block_changes?
=
link_to
_
(
'Upgrade your plan'
),
upgrade_subscription_path
,
class:
'btn gl-button btn-confirm'
,
data:
{
track_
event
:
'click_text'
,
track_label:
'subscribable_action'
,
track_property:
'upgrade'
}
=
link_to
_
(
'Upgrade your plan'
),
upgrade_subscription_path
,
class:
'btn gl-button btn-confirm'
,
data:
{
track_
action
:
'click_text'
,
track_label:
'subscribable_action'
,
track_property:
'upgrade'
}
-
else
=
link_to
_
(
'Renew subscription'
),
renew_subscription_path
,
class:
'btn gl-button btn-confirm gl-mr-3 gl-mb-2'
,
data:
{
track_
event
:
'click_text'
,
track_label:
'subscribable_action'
,
track_property:
'renew'
}
=
link_to
_
(
"That's OK, I don't want to renew"
),
'#'
,
data:
{
track_
event
:
'click_text'
,
track_label:
'subscribable_action'
,
track_property:
'thats_ok'
},
'aria-label'
=>
'Dismiss'
,
class:
'btn gl-button btn-info btn-info-secondary js-close gl-mb-2'
=
link_to
_
(
'Renew subscription'
),
renew_subscription_path
,
class:
'btn gl-button btn-confirm gl-mr-3 gl-mb-2'
,
data:
{
track_
action
:
'click_text'
,
track_label:
'subscribable_action'
,
track_property:
'renew'
}
=
link_to
_
(
"That's OK, I don't want to renew"
),
'#'
,
data:
{
track_
action
:
'click_text'
,
track_label:
'subscribable_action'
,
track_property:
'thats_ok'
},
'aria-label'
=>
'Dismiss'
,
class:
'btn gl-button btn-info btn-info-secondary js-close gl-mb-2'
ee/app/views/layouts/header/_user_notification_dot.html.haml
View file @
9b7d9365
-
return
unless
show_pipeline_minutes_notification_dot?
(
project
,
namespace
)
%span
.notification-dot.rounded-circle.gl-absolute.gl-visibility-visible
{
data:
{
track_label:
"show_buy_ci_minutes_notification"
,
track_property:
current_user
.
namespace
.
actual_plan_name
,
track_
event
:
'render'
}
}
%span
.notification-dot.rounded-circle.gl-absolute.gl-visibility-visible
{
data:
{
track_label:
"show_buy_ci_minutes_notification"
,
track_property:
current_user
.
namespace
.
actual_plan_name
,
track_
action
:
'render'
}
}
ee/app/views/projects/_new_ci_cd_only_project_pane.html.haml
View file @
9b7d9365
...
...
@@ -19,12 +19,12 @@
.import-buttons
%div
-
if
github_import_enabled?
=
link_to
new_import_github_path
(
ci_cd_only:
true
),
class:
'btn gl-button btn-default js-import-github'
,
data:
{
track_label:
"
#{
track_label
}
"
,
track_property:
'github'
,
track_
event
:
"click_button"
,
track_value:
""
}
do
=
link_to
new_import_github_path
(
ci_cd_only:
true
),
class:
'btn gl-button btn-default js-import-github'
,
data:
{
track_label:
"
#{
track_label
}
"
,
track_property:
'github'
,
track_
action
:
"click_button"
,
track_value:
""
}
do
=
sprite_icon
(
'github'
,
css_class:
'gl-button-icon'
)
GitHub
%div
-
if
git_import_enabled?
%button
.btn.gl-button.btn-default.btn-svg.js-toggle-button.js-import-git-toggle-button
{
type:
"button"
,
data:
{
toggle_open_class:
'active'
,
track_label:
"#{track_label}"
,
track_property:
'repo_url'
,
track_
event
:
"click_button"
,
track_value:
""
}
}
%button
.btn.gl-button.btn-default.btn-svg.js-toggle-button.js-import-git-toggle-button
{
type:
"button"
,
data:
{
toggle_open_class:
'active'
,
track_label:
"#{track_label}"
,
track_property:
'repo_url'
,
track_
action
:
"click_button"
,
track_value:
""
}
}
=
sprite_icon
(
'link'
,
css_class:
'gl-button-icon'
)
=
_
(
'Repo by URL'
)
.col-lg-12
...
...
ee/app/views/registrations/groups_projects/new.html.haml
View file @
9b7d9365
...
...
@@ -19,10 +19,10 @@
.js-toggle-container.gl-w-full
%ul
.nav.nav-tabs.nav-links.gitlab-tabs.js-group-project-tabs
{
role:
'tablist'
}
%li
.nav-item
{
role:
'presentation'
}
%a
#blank-project-tab
.nav-link.active
{
href:
'#blank-project-pane'
,
data:
{
toggle:
'tab'
,
track_label:
'blank_project'
,
track_
event
:
'click_tab'
,
track_value:
''
},
role:
'tab'
}
%a
#blank-project-tab
.nav-link.active
{
href:
'#blank-project-pane'
,
data:
{
toggle:
'tab'
,
track_label:
'blank_project'
,
track_
action
:
'click_tab'
,
track_value:
''
},
role:
'tab'
}
%span
=
s_
(
'ProjectsNew|Create'
)
%li
.nav-item
{
role:
'presentation'
}
%a
#import-project-tab
.nav-link
{
href:
'#import-project-pane'
,
data:
{
toggle:
'tab'
,
track_label:
'import_project'
,
track_
event
:
'click_tab'
,
track_value:
''
},
role:
'tab'
}
%a
#import-project-tab
.nav-link
{
href:
'#import-project-pane'
,
data:
{
toggle:
'tab'
,
track_label:
'import_project'
,
track_
action
:
'click_tab'
,
track_value:
''
},
role:
'tab'
}
%span
=
s_
(
'ProjectsNew|Import'
)
.tab-content.gitlab-tab-content.gl-bg-white.js-group-project-tab-contents
...
...
@@ -55,7 +55,7 @@
.form-group.project-name.col-sm-12
=
pf
.
label
:name
,
class:
'gl-font-weight-bold'
do
%span
=
_
(
'Project name'
)
=
pf
.
text_field
:name
,
id:
'blank_project_name'
,
class:
'form-control js-project-path-source'
,
required:
true
,
data:
{
track_label:
'blank_project'
,
track_
event
:
'activate_form_input'
,
track_property:
'project_name'
,
track_value:
''
}
=
pf
.
text_field
:name
,
id:
'blank_project_name'
,
class:
'form-control js-project-path-source'
,
required:
true
,
data:
{
track_label:
'blank_project'
,
track_
action
:
'activate_form_input'
,
track_property:
'project_name'
,
track_value:
''
}
%p
.form-text.gl-text-center
=
_
(
'Your project will be created at:'
)
...
...
@@ -68,7 +68,7 @@
%p
.form-text.text-muted.gl-text-center
{
class:
'gl-mb-5!'
}
=
_
(
'You can always change your URL later'
)
=
submit_tag
_
(
'Create project'
),
class:
'btn gl-button btn-success btn-block'
,
data:
{
track_label:
'blank_project'
,
track_
event
:
'click_button'
,
track_property:
'create_project'
,
track_value:
''
}
=
submit_tag
_
(
'Create project'
),
class:
'btn gl-button btn-success btn-block'
,
data:
{
track_label:
'blank_project'
,
track_
action
:
'click_button'
,
track_property:
'create_project'
,
track_value:
''
}
#import-project-pane
.tab-pane.import-project-pane.js-toggle-container
{
role:
'tabpanel'
}
-
if
import_sources_enabled?
...
...
ee/app/views/registrations/projects/new.html.haml
View file @
9b7d9365
...
...
@@ -16,10 +16,10 @@
.js-toggle-container.gl-w-full
%ul
.nav.nav-tabs.nav-links.gitlab-tabs
{
role:
'tablist'
}
%li
.nav-item
{
role:
'presentation'
}
%a
#blank-project-tab
.nav-link.active
{
href:
'#blank-project-pane'
,
data:
{
toggle:
'tab'
,
track_label:
'blank_project'
,
track_
event
:
'click_tab'
,
track_value:
''
},
role:
'tab'
}
%a
#blank-project-tab
.nav-link.active
{
href:
'#blank-project-pane'
,
data:
{
toggle:
'tab'
,
track_label:
'blank_project'
,
track_
action
:
'click_tab'
,
track_value:
''
},
role:
'tab'
}
%span
=
s_
(
'ProjectsNew|Create'
)
%li
.nav-item
{
role:
'presentation'
}
%a
#import-project-tab
.nav-link
{
href:
'#import-project-pane'
,
data:
{
toggle:
'tab'
,
track_label:
'import_project'
,
track_
event
:
'click_tab'
,
track_value:
''
},
role:
'tab'
}
%a
#import-project-tab
.nav-link
{
href:
'#import-project-pane'
,
data:
{
toggle:
'tab'
,
track_label:
'import_project'
,
track_
action
:
'click_tab'
,
track_value:
''
},
role:
'tab'
}
%span
=
s_
(
'ProjectsNew|Import'
)
.tab-content.gitlab-tab-content.gl-bg-white
...
...
@@ -31,7 +31,7 @@
.form-group.project-name.col-sm-12
=
f
.
label
:name
,
class:
'gl-font-weight-bold'
do
%span
=
_
(
'Project name'
)
=
f
.
text_field
:name
,
class:
'form-control'
,
autofocus:
true
,
data:
{
track_label:
'blank_project'
,
track_
event
:
'activate_form_input'
,
track_property:
'project_name'
,
track_value:
''
}
=
f
.
text_field
:name
,
class:
'form-control'
,
autofocus:
true
,
data:
{
track_label:
'blank_project'
,
track_
action
:
'activate_form_input'
,
track_property:
'project_name'
,
track_value:
''
}
.form-text.text-muted
=
_
(
'You can always edit this later'
)
.form-group.col-sm-12
=
f
.
label
:path
,
class:
'gl-font-weight-bold'
do
...
...
@@ -47,7 +47,7 @@
=
link_to
sprite_icon
(
'question-o'
),
help_page_path
(
'public_access/public_access'
),
aria:
{
label:
'Documentation for Visibility Level'
},
target:
'_blank'
,
rel:
'noopener noreferrer'
=
render
'shared/visibility_level'
,
f:
f
,
visibility_level:
visibility_level
.
to_i
,
can_change_visibility_level:
true
,
form_model:
@project
,
with_label:
false
=
f
.
submit
_
(
'Create project'
),
class:
'btn gl-button btn-success btn-block'
,
data:
{
track_label:
'blank_project'
,
track_
event
:
'click_button'
,
track_property:
'create_project'
,
track_value:
''
}
=
f
.
submit
_
(
'Create project'
),
class:
'btn gl-button btn-success btn-block'
,
data:
{
track_label:
'blank_project'
,
track_
action
:
'click_button'
,
track_property:
'create_project'
,
track_value:
''
}
#import-project-pane
.tab-pane.import-project-pane.js-toggle-container
{
role:
'tabpanel'
}
-
if
import_sources_enabled?
...
...
ee/spec/helpers/nav/new_dropdown_helper_spec.rb
View file @
9b7d9365
...
...
@@ -24,7 +24,7 @@ RSpec.describe Nav::NewDropdownHelper do
id:
'create_epic'
,
title:
'New epic'
,
href:
"/groups/
#{
group
.
path
}
/-/epics/new"
,
data:
{
track_
event
:
'click_link_new_epic'
,
track_label:
'plus_menu_dropdown'
}
data:
{
track_
action
:
'click_link_new_epic'
,
track_label:
'plus_menu_dropdown'
}
)
]
})
...
...
spec/helpers/nav/new_dropdown_helper_spec.rb
View file @
9b7d9365
...
...
@@ -51,7 +51,7 @@ RSpec.describe Nav::NewDropdownHelper do
title:
'Invite members'
,
href:
expected_href
,
data:
{
track_
event
:
'click_link'
,
track_
action
:
'click_link'
,
track_label:
'test_tracking_label'
,
track_property: :invite_members_new_dropdown
}
...
...
@@ -104,7 +104,7 @@ RSpec.describe Nav::NewDropdownHelper do
id:
'general_new_project'
,
title:
'New project/repository'
,
href:
'/projects/new'
,
data:
{
track_
event
:
'click_link_new_project'
,
track_label:
'plus_menu_dropdown'
,
qa_selector:
'global_new_project_link'
}
data:
{
track_
action
:
'click_link_new_project'
,
track_label:
'plus_menu_dropdown'
,
qa_selector:
'global_new_project_link'
}
)
)
)
...
...
@@ -122,7 +122,7 @@ RSpec.describe Nav::NewDropdownHelper do
id:
'general_new_group'
,
title:
'New group'
,
href:
'/groups/new'
,
data:
{
track_
event
:
'click_link_new_group'
,
track_label:
'plus_menu_dropdown'
}
data:
{
track_
action
:
'click_link_new_group'
,
track_label:
'plus_menu_dropdown'
}
)
)
)
...
...
@@ -140,7 +140,7 @@ RSpec.describe Nav::NewDropdownHelper do
id:
'general_new_snippet'
,
title:
'New snippet'
,
href:
'/-/snippets/new'
,
data:
{
track_
event
:
'click_link_new_snippet_parent'
,
track_label:
'plus_menu_dropdown'
,
qa_selector:
'global_new_snippet_link'
}
data:
{
track_
action
:
'click_link_new_snippet_parent'
,
track_label:
'plus_menu_dropdown'
,
qa_selector:
'global_new_snippet_link'
}
)
)
)
...
...
@@ -178,7 +178,7 @@ RSpec.describe Nav::NewDropdownHelper do
id:
'new_project'
,
title:
'New project/repository'
,
href:
"/projects/new?namespace_id=
#{
group
.
id
}
"
,
data:
{
track_
event
:
'click_link_new_project_group'
,
track_label:
'plus_menu_dropdown'
}
data:
{
track_
action
:
'click_link_new_project_group'
,
track_label:
'plus_menu_dropdown'
}
)
)
)
...
...
@@ -196,7 +196,7 @@ RSpec.describe Nav::NewDropdownHelper do
id:
'new_subgroup'
,
title:
'New subgroup'
,
href:
"/groups/new?parent_id=
#{
group
.
id
}
"
,
data:
{
track_
event
:
'click_link_new_subgroup'
,
track_label:
'plus_menu_dropdown'
}
data:
{
track_
action
:
'click_link_new_subgroup'
,
track_label:
'plus_menu_dropdown'
}
)
)
)
...
...
@@ -245,7 +245,7 @@ RSpec.describe Nav::NewDropdownHelper do
id:
'new_issue'
,
title:
'New issue'
,
href:
"/
#{
project
.
path_with_namespace
}
/-/issues/new"
,
data:
{
track_
event
:
'click_link_new_issue'
,
track_label:
'plus_menu_dropdown'
,
qa_selector:
'new_issue_link'
}
data:
{
track_
action
:
'click_link_new_issue'
,
track_label:
'plus_menu_dropdown'
,
qa_selector:
'new_issue_link'
}
)
)
)
...
...
@@ -263,7 +263,7 @@ RSpec.describe Nav::NewDropdownHelper do
id:
'new_mr'
,
title:
'New merge request'
,
href:
"/
#{
merge_project
.
path_with_namespace
}
/-/merge_requests/new"
,
data:
{
track_
event
:
'click_link_new_mr'
,
track_label:
'plus_menu_dropdown'
}
data:
{
track_
action
:
'click_link_new_mr'
,
track_label:
'plus_menu_dropdown'
}
)
)
)
...
...
@@ -281,7 +281,7 @@ RSpec.describe Nav::NewDropdownHelper do
id:
'new_snippet'
,
title:
'New snippet'
,
href:
"/
#{
project
.
path_with_namespace
}
/-/snippets/new"
,
data:
{
track_
event
:
'click_link_new_snippet_project'
,
track_label:
'plus_menu_dropdown'
}
data:
{
track_
action
:
'click_link_new_snippet_project'
,
track_label:
'plus_menu_dropdown'
}
)
)
)
...
...
spec/helpers/nav/top_nav_helper_spec.rb
View file @
9b7d9365
...
...
@@ -142,7 +142,7 @@ RSpec.describe Nav::TopNavHelper do
expected_primary
=
::
Gitlab
::
Nav
::
TopNavMenuItem
.
build
(
css_class:
'qa-projects-dropdown'
,
data:
{
track_
event
:
'click_dropdown'
,
track_
action
:
'click_dropdown'
,
track_label:
'projects_dropdown'
},
icon:
'project'
,
...
...
@@ -248,7 +248,7 @@ RSpec.describe Nav::TopNavHelper do
expected_primary
=
::
Gitlab
::
Nav
::
TopNavMenuItem
.
build
(
css_class:
'qa-groups-dropdown'
,
data:
{
track_
event
:
'click_dropdown'
,
track_
action
:
'click_dropdown'
,
track_label:
'groups_dropdown'
},
icon:
'group'
,
...
...
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