Skip to content
代码片段 群组 项目
未验证 提交 2abcce41 编辑于 作者: Ankit Panchal's avatar Ankit Panchal 提交者: GitLab
浏览文件

Remove snowplow property/label from some events Frontend

上级 e546214b
No related branches found
No related tags found
无相关合并请求
显示
10 个添加12 个删除
.js-blob-result.gl-mt-3.gl-mb-5{ data: { testid: 'result-item-content' } }
.file-holder.file-holder-top-border
.js-file-title.file-title{ data: { testid: 'file-title-content' } }
= link_to blob_link, data: { event_tracking: 'click_search_result', event_label: @scope, event_value: position, event_property: @search_term } do
= link_to blob_link, data: { event_tracking: 'click_search_result', event_label: @scope, event_value: position } do
= sprite_icon('document')
%strong
= search_blob_title(project, path)
......
- index = local_assigns.fetch(:index, nil)
- position = index + 1
= render 'projects/commits/commit', project: commit.project, commit: commit, ref: nil, show_project_name: @project.nil?, link_data_attrs: { event_tracking: 'click_search_result', event_label: @scope, event_value: position, event_property: @search_term }
= render 'projects/commits/commit', project: commit.project, commit: commit, ref: nil, show_project_name: @project.nil?, link_data_attrs: { event_tracking: 'click_search_result', event_label: @scope, event_value: position }
......@@ -5,7 +5,7 @@
%span.gl-flex.gl-items-center
= gl_badge_tag issuable_state_text(issuable), variant: issuable_state_to_badge_class(issuable)
= sprite_icon('eye-slash', css_class: 'gl-text-secondary gl-ml-2') if issuable.respond_to?(:confidential?) && issuable.confidential?
= link_to issuable_path(issuable), data: { event_tracking: 'click_search_result', event_label: @scope, event_value: position, event_property: @search_term }, class: 'gl-w-full' do
= link_to issuable_path(issuable), data: { event_tracking: 'click_search_result', event_label: @scope, event_value: position }, class: 'gl-w-full' do
%span.term.str-truncated.gl-font-bold.gl-ml-2= simple_search_highlight_and_truncate(issuable.title, @search_term)
.gl-text-secondary.gl-mb-3.gl-mt-2.gl-text-sm
= issuable_project_reference(issuable)
......
......@@ -3,7 +3,7 @@
- position = index + 1
.search-result-row
= link_to project_milestone_path(milestone.project, milestone), class: 'gl-font-bold gl-text-default', data: { event_tracking: 'click_search_result', event_label: @scope, event_value: position, event_property: @search_term } do
= link_to project_milestone_path(milestone.project, milestone), class: 'gl-font-bold gl-text-default', data: { event_tracking: 'click_search_result', event_label: @scope, event_value: position } do
%span.term.str-truncated= simple_search_highlight_and_truncate(milestone.title, @search_term)
- if milestone.project_milestone?
......
......@@ -22,7 +22,7 @@
- else
%span #{note.noteable_type.titleize} ##{noteable_identifier}
·
= link_to note.noteable.title, note_url, data: { event_tracking: 'click_search_result', event_label: @scope, event_value: position, event_property: @search_term }
= link_to note.noteable.title, note_url, data: { event_tracking: 'click_search_result', event_label: @scope, event_value: position }
.note-search-result
.term
......
......@@ -4,7 +4,7 @@
.search-result-row
%h4
= link_to gitlab_snippet_path(snippet_title), data: { event_tracking: 'click_search_result', event_label: @scope, event_value: position, event_property: @search_term } do
= link_to gitlab_snippet_path(snippet_title), data: { event_tracking: 'click_search_result', event_label: @scope, event_value: position } do
= truncate(snippet_title.title, length: 60)
= snippet_badge(snippet_title)
%span.gl-text-primary.monospace.tiny.gl-float-right.term
......
......@@ -7,7 +7,7 @@
%div{ class: '!gl-inline-flex' }
= render Pajamas::AvatarComponent.new(user, size: 32, alt: '')
.gl-ml-3{ class: '!gl-text-left' }
= link_to user_path(user), class: 'gl-text-primary', data: { event_tracking: 'click_search_result', event_label: @scope, event_value: position, event_property: @search_term } do
= link_to user_path(user), class: 'gl-text-primary', data: { event_tracking: 'click_search_result', event_label: @scope, event_value: position } do
.gl-inline-block.gl-font-bold= simple_search_highlight_and_truncate(user.name, @search_term)
= user_status(user)
%div{ class: '!gl-text-left' }= simple_search_highlight_and_truncate(user.to_reference, @search_term)
......
......@@ -4,7 +4,7 @@
%div{ class: 'search-result-row !gl-pb-3 gl-mt-5 !gl-mb-0' }
%span.gl-flex.gl-items-center
= link_to wiki_blob_link(wiki_blob), data: { event_tracking: 'click_search_result', event_label: @scope, event_value: position, event_property: @search_term }, class: 'gl-w-full' do
= link_to wiki_blob_link(wiki_blob), data: { event_tracking: 'click_search_result', event_label: @scope, event_value: position }, class: 'gl-w-full' do
%span.term.str-truncated.gl-font-bold= ::Wiki.canonicalize_filename(wiki_blob.path)
.description.term.col-sm-10.gl-px-0
= simple_search_highlight_and_truncate(wiki_blob.data, @search_term)
......@@ -34,7 +34,6 @@ export default {
trackCTAClick() {
this.track(TRACK_PROMOTION_BANNER_CTA_CLICK_ACTION, {
label: TRACK_PROMOTION_BANNER_CTA_CLICK_LABEL,
property: this.projectFullPath,
});
},
},
......
......@@ -9,7 +9,7 @@
- else
= gl_badge_tag _('Open'), variant: :success
= sprite_icon('eye-slash', css_class: 'gl-text-secondary gl-ml-2') if epic.confidential?
= link_to group_epic_path(epic.group, epic), data: { event_tracking: 'click_search_result', event_label: @scope, event_value: position, event_property: @search_term }, class: 'gl-w-full' do
= link_to group_epic_path(epic.group, epic), data: { event_tracking: 'click_search_result', event_label: @scope, event_value: position }, class: 'gl-w-full' do
%span.term.str-truncated.gl-font-bold.gl-ml-2= epic.title
.gl-text-secondary.gl-mb-3.gl-text-sm
= sprintf(s_('%{group_name}&%{epic_iid} · created %{epic_created} by %{author}'), { group_name: epic.group.full_name, epic_iid: epic.iid, epic_created: time_ago_with_tooltip(epic.created_at, placement: 'bottom'), author: link_to_member(epic.author, avatar: false) }).html_safe
......
......@@ -9,7 +9,7 @@
- else
= gl_badge_tag _('Open'), variant: :success
= sprite_icon('eye-slash', css_class: 'gl-text-secondary gl-ml-2') if work_item.confidential?
= link_to group_work_item_path(work_item.namespace, work_item), data: { event_tracking: 'click_search_result', event_label: @scope, event_value: position, event_property: @search_term }, class: 'gl-w-full' do
= link_to group_work_item_path(work_item.namespace, work_item), data: { event_tracking: 'click_search_result', event_label: @scope, event_value: position }, class: 'gl-w-full' do
%span.term.str-truncated.gl-font-bold.gl-ml-2= work_item.title
.gl-text-secondary.gl-mb-3.gl-text-sm
= sprintf(s_('%{group_name}&%{work_item_iid} · created %{work_item_created} by %{author}'), { group_name: work_item.namespace.full_name, work_item_iid: work_item.iid, work_item_created: time_ago_with_tooltip(work_item.created_at, placement: 'bottom'), author: link_to_member(work_item.author, avatar: false) }).html_safe
......
......@@ -95,7 +95,6 @@ describe('Security training promo component', () => {
expect(trackingSpy).toHaveBeenCalledWith(undefined, TRACK_PROMOTION_BANNER_CTA_CLICK_ACTION, {
label: TRACK_PROMOTION_BANNER_CTA_CLICK_LABEL,
property: PROJECT_FULL_PATH,
});
});
});
......
0% 加载中 .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册