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 Modernizr #4273

Merged
merged 2 commits into from
Oct 3, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@

## Unreleased

* **BREAKING:** Remove Modernizr ([PR #4273](https://github.com/alphagov/govuk_publishing_components/pull/4273))
* Update accessibility criteria in component docs ([PR #4242](https://github.com/alphagov/govuk_publishing_components/pull/4242))
* Show all big_number symbol types in our docs ([PR #4271](https://github.com/alphagov/govuk_publishing_components/pull/4271))
* Remove incorrect search component example ([PR #4253](https://github.com/alphagov/govuk_publishing_components/pull/4253))
Expand Down
1 change: 0 additions & 1 deletion app/assets/config/govuk_publishing_components_manifest.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,5 @@
//= link_directory ../javascripts/govuk_publishing_components

// Pre-compile these specific files
//= link govuk_publishing_components/vendor/modernizr.js
//= link govuk_publishing_components/vendor/lux/lux-reporter.js
//= link govuk_publishing_components/vendor/lux/lux-measurer.js

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@
<%= csrf_meta_tags %>
<%= favicon_link_tag "govuk_publishing_components/favicon-#{environment}.png" %>
<%= stylesheet_link_tag css_filename, media: "all" %>
<%= javascript_include_tag "govuk_publishing_components/vendor/modernizr" %>
<% if GovukPublishingComponents::Config.use_es6_components %>
<%= javascript_include_tag js_module_filename, type: "module" %>
<% end %>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,6 @@
<%= stylesheet_link_tag "component_guide/application", media: "all" %>
<%= yield :application_stylesheet %>
<%= render_component_stylesheets %>

<%= javascript_include_tag "govuk_publishing_components/vendor/modernizr" %>
<%= yield :extra_headers %>
</head>
<body class="gem-c-layout-for-admin govuk-template__body <%= 'hide-header-and-footer' if @preview %>">
Expand Down
3 changes: 0 additions & 3 deletions spec/components/layout_for_admin_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ def component_name
end

it "can receive a custom js filename" do
allow_any_instance_of(ActionView::Base).to receive(:javascript_include_tag).with("govuk_publishing_components/vendor/modernizr")
expect_any_instance_of(ActionView::Base).to receive(:javascript_include_tag).with("admin").once

render_component(
Expand All @@ -36,7 +35,6 @@ def component_name
end

it "can receive a custom js filename for es6 " do
allow_any_instance_of(ActionView::Base).to receive(:javascript_include_tag).with("govuk_publishing_components/vendor/modernizr")
allow_any_instance_of(ActionView::Base).to receive(:javascript_include_tag).with("application")
expect_any_instance_of(ActionView::Base).to receive(:javascript_include_tag).with("es6-bundle", { type: "module" }).once

Expand All @@ -48,7 +46,6 @@ def component_name
end

it "can use the default filename for es6 components" do
allow_any_instance_of(ActionView::Base).to receive(:javascript_include_tag).with("govuk_publishing_components/vendor/modernizr")
allow_any_instance_of(ActionView::Base).to receive(:javascript_include_tag).with("application")
expect_any_instance_of(ActionView::Base).to receive(:javascript_include_tag).with("es6-components", { type: "module" }).once

Expand Down
Loading