Skip to content

Commit

Permalink
Merge pull request #3091 from alphagov/change-search-text-field-labels
Browse files Browse the repository at this point in the history
Change search text field labels
  • Loading branch information
jon-kirwan authored Jul 5, 2023
2 parents dc9dd03 + a9a9ad7 commit b534c24
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions app/models/content_item.rb
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,10 @@ def summary
content_item_hash["details"]["summary"]
end

def label_text
content_item_hash["details"]["label_text"]
end

def email_alert_signup
content_item_hash.dig("links", "email_alert_signup", 0)
end
Expand Down
2 changes: 1 addition & 1 deletion app/views/finders/_facet_collection.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
type: 'search',
value: result_set_presenter.user_supplied_keywords,
inline_label: false,
label_text: label_text
label_text: sanitize(content_item.label_text) || label_text
} %>
</div>
<% end %>
Expand Down

0 comments on commit b534c24

Please sign in to comment.