govuk_web_banners 1.2.1 → 1.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 72390441ea030c79a304774d614bafeea76076f348a7a18f1c91a0550d3b5e06
|
4
|
+
data.tar.gz: bb60e3fec30d355df9e3c2202f895b43ca96cd313c75703b16cf19d423e3c276
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: af4a88e99f13d25dd2ded6f765633771c709396690ebff903ad48dfc743f54e093555fbb55daa96f14937b51753e010234c43ffbdea46125a03e0b160383df9d
|
7
|
+
data.tar.gz: 004ae46414c0af964d0663c3a2a1bee921a6f7200cd545a9ca36f62695a77870d6fad34b9f8408a0198a6c5c574f316b495a123b5aa9a5543475dcea7b5e5308
|
data/README.md
CHANGED
@@ -206,17 +206,22 @@ banners:
|
|
206
206
|
- /foreign-travel-advice
|
207
207
|
start_date: 2024/10/21
|
208
208
|
end_date: 2024/11/18
|
209
|
+
image: hmrc
|
209
210
|
```
|
210
211
|
|
211
212
|
The required keys are `suggestion_text`, `suggestion_link_text`, and
|
212
213
|
`survey_url` (the values to appear in the banner), and `page_paths` (an array of
|
213
214
|
paths on which the banner should be shown).
|
214
215
|
|
215
|
-
Optional keys are
|
216
|
-
|
217
|
-
|
218
|
-
|
219
|
-
parsable as a YAML -> Date.
|
216
|
+
Optional keys are:
|
217
|
+
- `name` (an identifying name for this banner, not rendered
|
218
|
+
anywhere)
|
219
|
+
- `start_date` the banner becomes active at the *start* of the day specified.
|
220
|
+
Must be in the YYYY/MM/DD format parsable as a YAML -> Date.
|
221
|
+
- `end_date` (the banner stops being active at the *start* of the day
|
222
|
+
specified). Must be in the YYYY/MM/DD format parsable as a YAML -> Date.
|
223
|
+
- `image` an image name supported by the [interaction banner image option](https://components.publishing.service.gov.uk/component-guide/intervention#with_image)
|
224
|
+
Currently the only allowable value is `hmrc`.
|
220
225
|
|
221
226
|
### Validations on the recruitment banners config file
|
222
227
|
|
@@ -1,35 +1,81 @@
|
|
1
1
|
# Check README.md for how to format this file
|
2
2
|
banners:
|
3
|
-
- name: HMRC
|
3
|
+
- name: HMRC banner - Register VAT 2025/07/04
|
4
4
|
suggestion_text: "Help improve GOV.UK"
|
5
5
|
suggestion_link_text: "Sign up to take part in user research (opens in a new tab)"
|
6
|
-
survey_url: https://survey.take-part-in-research.service.gov.uk/jfe/form/SV_74GjifgnGv6GsMC?Source=
|
6
|
+
survey_url: https://survey.take-part-in-research.service.gov.uk/jfe/form/SV_74GjifgnGv6GsMC?Source=BannerList_HMRC_MTD_VAT_Registration
|
7
7
|
page_paths:
|
8
8
|
# government-frontend
|
9
|
-
- /
|
10
|
-
- /
|
11
|
-
- /
|
12
|
-
- /
|
13
|
-
|
14
|
-
|
15
|
-
|
9
|
+
- /register-for-vat
|
10
|
+
- /guidance/apply-for-an-exception-from-registering-for-vat
|
11
|
+
- /register-for-vat/how-register-for-vat
|
12
|
+
- /guidance/check-what-registering-for-vat-may-mean-for-your-business
|
13
|
+
- /government/publications/vat-notice-7001-should-i-be-registered-for-vat/vat-notice-7001-should-i-be-registered-for-vat
|
14
|
+
start_date: 2025/07/04
|
15
|
+
end_date: 2025/08/01
|
16
|
+
- name: HMRC banner - De-register VAT 2025/07/04
|
16
17
|
suggestion_text: "Help improve GOV.UK"
|
17
18
|
suggestion_link_text: "Sign up to take part in user research (opens in a new tab)"
|
18
|
-
survey_url: https://survey.take-part-in-research.service.gov.uk/jfe/form/SV_74GjifgnGv6GsMC?Source=
|
19
|
+
survey_url: https://survey.take-part-in-research.service.gov.uk/jfe/form/SV_74GjifgnGv6GsMC?Source=BannerList_HMRC_MTD_VAT_De-registration
|
19
20
|
page_paths:
|
20
21
|
# government-frontend
|
21
|
-
- /
|
22
|
-
|
23
|
-
|
24
|
-
|
22
|
+
- /register-for-vat/cancel-your-registration
|
23
|
+
- /government/publications/vat-notice-70011-cancelling-your-registration/vat-notice-70011-cancelling-your-registration
|
24
|
+
start_date: 2025/07/04
|
25
|
+
end_date: 2025/08/01
|
26
|
+
- name: HMRC banner - Payments 2025/07/04
|
25
27
|
suggestion_text: "Help improve GOV.UK"
|
26
28
|
suggestion_link_text: "Sign up to take part in user research (opens in a new tab)"
|
27
|
-
survey_url: https://survey.take-part-in-research.service.gov.uk/jfe/form/SV_74GjifgnGv6GsMC?Source=
|
29
|
+
survey_url: https://survey.take-part-in-research.service.gov.uk/jfe/form/SV_74GjifgnGv6GsMC?Source=BannerList_HMRC_MTD_VAT_Payments
|
28
30
|
page_paths:
|
29
31
|
# government-frontend
|
30
|
-
- /
|
31
|
-
- /hmrc-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
32
|
+
- /pay-vat
|
33
|
+
- /government/collections/paying-hmrc-detailed-information
|
34
|
+
start_date: 2025/07/04
|
35
|
+
end_date: 2025/08/01
|
36
|
+
- name: HMRC banner - Repayments 2025/07/04
|
37
|
+
suggestion_text: "Help improve GOV.UK"
|
38
|
+
suggestion_link_text: "Sign up to take part in user research (opens in a new tab)"
|
39
|
+
survey_url: https://survey.take-part-in-research.service.gov.uk/jfe/form/SV_74GjifgnGv6GsMC?Source=BannerList_HMRC_MTD_VAT_Repayments
|
40
|
+
page_paths:
|
41
|
+
# frontend
|
42
|
+
- /vat-repayments
|
43
|
+
start_date: 2025/07/04
|
44
|
+
end_date: 2025/08/01
|
45
|
+
- name: HMRC banner - Reporting 2025/07/04
|
46
|
+
suggestion_text: "Help improve GOV.UK"
|
47
|
+
suggestion_link_text: "Sign up to take part in user research (opens in a new tab)"
|
48
|
+
survey_url: https://survey.take-part-in-research.service.gov.uk/jfe/form/SV_74GjifgnGv6GsMC?Source=BannerList_HMRC_MTD_VAT_Reporting
|
49
|
+
page_paths:
|
50
|
+
# government-frontend
|
51
|
+
- /charge-reclaim-record-vat
|
52
|
+
- /charge-reclaim-record-vat/when-not-to-charge-vat
|
53
|
+
- /submit-vat-return
|
54
|
+
- /guidance/how-to-fill-in-and-submit-your-vat-return-vat-notice-70012
|
55
|
+
start_date: 2025/07/04
|
56
|
+
end_date: 2025/08/01
|
57
|
+
- name: HMRC banner - Flat Rate Scheme 2025/07/04
|
58
|
+
suggestion_text: "Help improve GOV.UK"
|
59
|
+
suggestion_link_text: "Sign up to take part in user research (opens in a new tab)"
|
60
|
+
survey_url: https://survey.take-part-in-research.service.gov.uk/jfe/form/SV_74GjifgnGv6GsMC?Source=BannerList_HMRC_MTD_VAT_Flat_rate_scheme
|
61
|
+
page_paths:
|
62
|
+
# government-frontend
|
63
|
+
- /vat-flat-rate-scheme
|
64
|
+
- /vat-flat-rate-scheme/how-much-you-pay
|
65
|
+
- /guidance/flat-rate-scheme-for-small-businesses-vat-notice-733--2
|
66
|
+
start_date: 2025/07/04
|
67
|
+
end_date: 2025/08/01
|
68
|
+
- name: HMRC banner - Misc 2025/07/04
|
69
|
+
suggestion_text: "Help improve GOV.UK"
|
70
|
+
suggestion_link_text: "Sign up to take part in user research (opens in a new tab)"
|
71
|
+
survey_url: https://survey.take-part-in-research.service.gov.uk/jfe/form/SV_74GjifgnGv6GsMC?Source=BannerList_HMRC_MTD_VAT_Misc
|
72
|
+
page_paths:
|
73
|
+
# government-frontend
|
74
|
+
- /guidance/check-when-you-can-expect-a-reply-from-hmrc
|
75
|
+
- /government/collections/vat-detailed-information
|
76
|
+
- /government/collections/vat-notices-numerical-order
|
77
|
+
- /guidance/vat-guide-notice-700
|
78
|
+
- /how-vat-works
|
79
|
+
- /government/collections/vat-forms
|
80
|
+
start_date: 2025/07/04
|
81
|
+
end_date: 2025/08/01
|
@@ -18,7 +18,7 @@ module GovukWebBanners
|
|
18
18
|
recruitment_banners_data["banners"].map { |attributes| RecruitmentBanner.new(attributes:) }
|
19
19
|
end
|
20
20
|
|
21
|
-
attr_reader :name, :suggestion_text, :suggestion_link_text, :survey_url, :page_paths, :start_date, :end_date
|
21
|
+
attr_reader :name, :suggestion_text, :suggestion_link_text, :survey_url, :page_paths, :start_date, :end_date, :image
|
22
22
|
|
23
23
|
def initialize(attributes:)
|
24
24
|
@name = attributes["name"]
|
@@ -28,6 +28,7 @@ module GovukWebBanners
|
|
28
28
|
@page_paths = attributes["page_paths"]
|
29
29
|
@start_date = attributes["start_date"] ? ActiveSupport::TimeZone[GovukWebBanners::TIME_ZONE].parse(attributes["start_date"]) : Time.at(0)
|
30
30
|
@end_date = attributes["end_date"] ? ActiveSupport::TimeZone[GovukWebBanners::TIME_ZONE].parse(attributes["end_date"]) : Time.now + 10.years
|
31
|
+
@image = attributes["image"]
|
31
32
|
end
|
32
33
|
|
33
34
|
# NB: .between? is inclusive. To make it exclude the end date, we set the end range as
|