Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove error-summary dependence on document.onload #1215

Merged
merged 2 commits into from
Mar 8, 2019
Merged

Remove error-summary dependence on document.onload #1215

merged 2 commits into from
Mar 8, 2019

Commits on Mar 8, 2019

  1. Remove error-summary dependence on document.onload

    The error-summary component is being initialised on an element using a `data-` attribute, which means that at the initialisation moment the element already exists is loaded in the DOM. Hence, we don't need to wait for `document.onload` to happen in order to set the focus on this element.
    
    Background: We're using the error-summary component in a modal dialogue and we're planning to re-initialise the GOVUK Frontend components within the modal using `GOVUKFrontend.initAll()` (yeah, we need to scope it, but I'll raise a separate PR for that).
    This component and `Tabs` are the only one relying on `document.onload` to happen.
    alex-ju authored and NickColley committed Mar 8, 2019
    Configuration menu
    Copy the full SHA
    f194d26 View commit details
    Browse the repository at this point in the history
  2. Update CHANGELOG

    NickColley committed Mar 8, 2019
    Configuration menu
    Copy the full SHA
    4178f34 View commit details
    Browse the repository at this point in the history