Skip to content

Commit

Permalink
Merge pull request #2938 from alphagov/ga4-change-print-type
Browse files Browse the repository at this point in the history
Change GA4 type from 'content' to 'print page' on print links
  • Loading branch information
AshGDS authored Oct 4, 2023
2 parents ff207e0 + 1b89688 commit aea97f6
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion app/views/content_items/guide.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@
data-module="ga4-link-tracker"
data-ga4-link="<%= {
event_name: "navigation",
type: "content",
type: "print page",
section: "Footer",
text: t("multi_page.print_entire_guide", locale: :en)
}.to_json %>">
Expand Down
2 changes: 1 addition & 1 deletion app/views/content_items/travel_advice.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@
data-module="ga4-link-tracker"
data-ga4-link="<%= {
event_name: "navigation",
type: "content",
type: "print page",
section: "Footer",
text: t("multi_page.print_entire_guide", locale: :en)
}.to_json %>"><%= t("multi_page.print_entire_guide") %></a>
Expand Down
2 changes: 1 addition & 1 deletion test/integration/guide_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ class GuideTest < ActionDispatch::IntegrationTest

expected_ga4_json = {
event_name: "navigation",
type: "content",
type: "print page",
section: "Footer",
text: "View a printable version of the whole guide",
}.to_json
Expand Down
2 changes: 1 addition & 1 deletion test/integration/travel_advice_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ class TravelAdviceTest < ActionDispatch::IntegrationTest

expected_ga4_json = {
event_name: "navigation",
type: "content",
type: "print page",
section: "Footer",
text: "View a printable version of the whole guide",
}.to_json
Expand Down

0 comments on commit aea97f6

Please sign in to comment.