govuk_publishing_components 35.4.0 → 35.5.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/assets/javascripts/govuk_publishing_components/analytics-ga4/ga4-form-tracker.js +1 -1
- data/app/assets/javascripts/govuk_publishing_components/analytics-ga4/ga4-link-tracker.js +3 -0
- data/app/assets/javascripts/govuk_publishing_components/analytics-ga4/ga4-specialist-link-tracker.js +3 -0
- data/app/views/govuk_publishing_components/components/_share_links.html.erb +2 -2
- data/app/views/govuk_publishing_components/components/_step_by_step_nav.html.erb +2 -1
- data/lib/govuk_publishing_components/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 83d143fc56ad285e250659a050cb73b185176316d43f40293199ea6cc673c120
|
4
|
+
data.tar.gz: b8b9d0b29c550c0abc91be533b38cf3c9b62bd42039c1d31d66ec06883ba9be1
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0ebadf89e85215996356032d2f1f1d8e9faaec6287048c61a729da84a28e29dee5f509f6ece7db95341f0ca8e19815172d6d4898a6a624329525c5b36713fefc
|
7
|
+
data.tar.gz: 1a13f99b6d61d29e6e1c7c62d89dce9b8b2ee7dbfd5f026e6f0d80502ccd8d90180c990d6f86525c97ccb0816083ea22facfdf84e582e0f8c0765da5e153d732
|
@@ -43,7 +43,7 @@ window.GOVUK.Modules = window.GOVUK.Modules || {};
|
|
43
43
|
|
44
44
|
var formInputs = this.getFormInputs()
|
45
45
|
var formData = this.getInputValues(formInputs)
|
46
|
-
data.text = this.combineGivenAnswers(formData) || 'No answer given'
|
46
|
+
data.text = data.text || (this.combineGivenAnswers(formData) || 'No answer given')
|
47
47
|
|
48
48
|
var schemas = new window.GOVUK.analyticsGa4.Schemas()
|
49
49
|
var schema = schemas.mergeProperties(data, 'event_data')
|
@@ -82,6 +82,9 @@ window.GOVUK.Modules = window.GOVUK.Modules || {};
|
|
82
82
|
var text = data.text || event.target.textContent
|
83
83
|
data.text = window.GOVUK.analyticsGa4.core.trackFunctions.removeLinesAndExtraSpaces(text)
|
84
84
|
data.text = this.PIIRemover.stripPIIWithOverride(data.text, true, true)
|
85
|
+
if (!data.text && (element.querySelector('img') || element.querySelector('svg'))) {
|
86
|
+
data.text = 'image'
|
87
|
+
}
|
85
88
|
var url = data.url || this.findLink(event.target).getAttribute('href')
|
86
89
|
data.url = window.GOVUK.analyticsGa4.core.trackFunctions.removeCrossDomainParams(this.PIIRemover.stripPIIWithOverride(url, true, true))
|
87
90
|
data.link_domain = window.GOVUK.analyticsGa4.core.trackFunctions.populateLinkDomain(data.url)
|
data/app/assets/javascripts/govuk_publishing_components/analytics-ga4/ga4-specialist-link-tracker.js
CHANGED
@@ -77,6 +77,9 @@ window.GOVUK.analyticsGa4.analyticsModules = window.GOVUK.analyticsGa4.analytics
|
|
77
77
|
|
78
78
|
data.text = window.GOVUK.analyticsGa4.core.trackFunctions.removeLinesAndExtraSpaces(element.textContent)
|
79
79
|
data.text = mailToLink ? data.text : this.PIIRemover.stripPIIWithOverride(data.text, true, true)
|
80
|
+
if (!data.text && (element.querySelector('img') || element.querySelector('svg'))) {
|
81
|
+
data.text = 'image'
|
82
|
+
}
|
80
83
|
data.method = window.GOVUK.analyticsGa4.core.trackFunctions.getClickType(event)
|
81
84
|
|
82
85
|
var schemas = new window.GOVUK.analyticsGa4.Schemas()
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: govuk_publishing_components
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 35.
|
4
|
+
version: 35.5.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- GOV.UK Dev
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-05-
|
11
|
+
date: 2023-05-31 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: govuk_app_config
|