Feedback
Invites user feedback on the current page.
This component is designed to sit at the bottom of pages on GOV.UK to allow users to submit feedback on that page.
This component uses JavaScript for expanding and collapsing and also for submitting form responses. This code is not compatible with Internet Explorer, so IE11 and down do not use JavaScript to submit the forms, instead falling back to a normal form submission.
How it looks (preview) (preview all)
Is this page useful?
Help us improve GOV.UK
To help us improve GOV.UK, we’d like to know more about your visit today. Please fill in this survey (opens in a new tab).
How to call this component
<%= render "govuk_publishing_components/components/feedback", {} %>
Accessibility acceptance criteria
The form must:
- be functional and accessible with JavaScript disabled
- be usable and accessible with stylesheets disabled
Form elements in the component must:
- accept focus
- be focusable with a keyboard
- be usable with a keyboard
- be usable with touch
- indicate when they have focus
- be recognisable as form input elements
- have correctly associated labels
- be of the appropriate type for their use, e.g. password inputs should be of type
password
Links in the component must:
- accept focus
- be focusable with a keyboard
- be usable with a keyboard
- indicate when they have focus
- change in appearance when touched (in the touch-down state)
- change in appearance when hovered
- be usable with touch
- be usable with voice commands
- have visible text
- have meaningful text
Other examples
Standard options
This component uses the component wrapper helper. It accepts the following options and applies them to the parent element of the component. See the component wrapper helper documentation for more detail.
id
- accepts a string for the element ID attributedata_attributes
- accepts a hash of data attributesaria
- accepts a hash of aria attributesclasses
- accepts a space separated string of classes, these should not be used for styling and must be prefixed withjs-
role
- accepts a space separated string of roleslang
- accepts a language attribute valueopen
- accepts an open attribute value (true or false)hidden
- accepts an empty string, ‘hidden’, or ‘until-found’tabindex
- accepts an integer. The integer can also be passed as a string.dir
- accepts ‘rtl’, ‘ltr’, or ‘auto’.
With ga4 tracking disabled (preview)
Disables GA4 tracking on the feedback component. Tracking is enabled by default, which adds a data module and data-attributes with JSONs to the feedback buttons. See the ga4-event-tracker documentation for more information.
Is this page useful?
Help us improve GOV.UK
To help us improve GOV.UK, we’d like to know more about your visit today. Please fill in this survey (opens in a new tab).
<%= render "govuk_publishing_components/components/feedback", {
disable_ga4: true
} %>