File tree 2 files changed +18
-5
lines changed
2 files changed +18
-5
lines changed Original file line number Diff line number Diff line change 4
4
5
5
- [ Fix: Update Rack::File to Rack::Files in test specs] ( https://github.com/alphagov/tech-docs-gem/pull/394 )
6
6
7
+ - [ Fix: Use the service link as the start of the path to the favicon images] ( https://github.com/alphagov/tech-docs-gem/pull/391 )
8
+
7
9
## 4.2.0
8
10
9
11
## New features
Original file line number Diff line number Diff line change 11
11
12
12
< link rel ="canonical " href ="<%= meta_tags . canonical_url %> ">
13
13
<% if config [ :tech_docs ] [ :show_govuk_logo ] %>
14
- < link rel ="icon " sizes ="48x48 " href ="/assets/govuk/assets/images/favicon.ico ">
15
- < link rel ="icon " sizes ="any " href ="/assets/govuk/assets/images/favicon.svg " type ="image/svg+xml ">
16
- < link rel ="mask-icon " href ="/assets/govuk/assets/images/govuk-icon-mask.svg " color ="#0b0c0c ">
17
- < link rel ="apple-touch-icon " href ="/assets/govuk/assets/images/govuk-icon-180.png ">
18
- < link rel ="manifest " href ="/assets/govuk/assets/manifest.json ">
14
+ <%
15
+ if development?
16
+ path_prefix = '/'
17
+ else
18
+ path_prefix = config [ :tech_docs ] [ :service_link ] || '/'
19
+ # ensure service_link ends with a trailing '/'
20
+ if path_prefix [ -1 , 1 ] != '/'
21
+ path_prefix += '/'
22
+ end
23
+ end
24
+ %>
25
+ < link rel ="icon " sizes ="48x48 " href ="<%= path_prefix %> assets/govuk/assets/images/favicon.ico ">
26
+ < link rel ="icon " sizes ="any " href ="<%= path_prefix %> assets/govuk/assets/images/favicon.svg " type ="image/svg+xml ">
27
+ < link rel ="mask-icon " href ="<%= path_prefix %> assets/govuk/assets/images/govuk-icon-mask.svg " color ="#0b0c0c ">
28
+ < link rel ="apple-touch-icon " href ="<%= path_prefix %> assets/govuk/assets/images/govuk-icon-180.png ">
29
+ < link rel ="manifest " href ="<%= path_prefix %> assets/govuk/assets/manifest.json ">
19
30
<% else %>
20
31
< link rel ="icon " sizes ="48x48 " href ="/images/favicon.ico ">
21
32
< link rel ="icon " sizes ="any " href ="/images/favicon.svg " type ="image/svg+xml ">
You can’t perform that action at this time.
0 commit comments