diff --git a/Gemfile.lock b/Gemfile.lock index 3dcbc2547..1d8dd04e5 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -127,7 +127,7 @@ GEM sass-embedded (~> 1.63) database_cleaner (2.0.2) database_cleaner-active_record (>= 2, < 3) - database_cleaner-active_record (2.1.0) + database_cleaner-active_record (2.2.0) activerecord (>= 5.a) database_cleaner-core (~> 2.0.0) database_cleaner-core (2.0.1) @@ -154,7 +154,7 @@ GEM faraday (~> 2.0) friendly_id (5.5.1) activerecord (>= 4.0.0) - gds-api-adapters (96.0.1) + gds-api-adapters (96.0.2) addressable link_header null_logger @@ -174,6 +174,21 @@ GEM google-protobuf (4.27.2) bigdecimal rake (>= 13) + google-protobuf (4.27.2-aarch64-linux) + bigdecimal + rake (>= 13) + google-protobuf (4.27.2-arm64-darwin) + bigdecimal + rake (>= 13) + google-protobuf (4.27.2-x86-linux) + bigdecimal + rake (>= 13) + google-protobuf (4.27.2-x86_64-darwin) + bigdecimal + rake (>= 13) + google-protobuf (4.27.2-x86_64-linux) + bigdecimal + rake (>= 13) googleapis-common-protos-types (1.15.0) google-protobuf (>= 3.18, < 5.a) govuk_app_config (9.13.1) @@ -191,7 +206,7 @@ GEM govuk_personalisation (0.16.0) plek (>= 1.9.0) rails (>= 6, < 8) - govuk_publishing_components (39.2.4) + govuk_publishing_components (40.0.0) govuk_app_config govuk_personalisation (>= 0.7.0) kramdown @@ -206,7 +221,7 @@ GEM redis (< 5) redis-namespace (~> 1.6) sidekiq (~> 6.5, >= 6.5.12) - graphql (2.3.5) + graphql (2.3.9) base64 graphql-client (0.23.0) activesupport (>= 3.0) @@ -247,11 +262,10 @@ GEM method_source (1.1.0) mime-types (3.5.2) mime-types-data (~> 3.2015) - mime-types-data (3.2024.0604) + mime-types-data (3.2024.0702) mini_mime (1.1.5) - mini_portile2 (2.8.7) minitest (5.24.1) - mocha (2.4.1) + mocha (2.4.2) ruby2_keywords (>= 0.0.5) msgpack (1.7.2) multi_xml (0.7.1) @@ -272,8 +286,17 @@ GEM net-protocol netrc (0.11.0) nio4r (2.7.3) - nokogiri (1.16.6) - mini_portile2 (~> 2.8.2) + nokogiri (1.16.6-aarch64-linux) + racc (~> 1.4) + nokogiri (1.16.6-arm-linux) + racc (~> 1.4) + nokogiri (1.16.6-arm64-darwin) + racc (~> 1.4) + nokogiri (1.16.6-x86-linux) + racc (~> 1.4) + nokogiri (1.16.6-x86_64-darwin) + racc (~> 1.4) + nokogiri (1.16.6-x86_64-linux) racc (~> 1.4) null_logger (0.0.1) oauth2 (2.0.9) @@ -499,7 +522,7 @@ GEM opentelemetry-semantic_conventions (1.10.0) opentelemetry-api (~> 1.0) parallel (1.25.1) - parser (3.3.3.0) + parser (3.3.4.0) ast (~> 2.4.1) racc plek (5.2.0) @@ -581,7 +604,7 @@ GEM http-cookie (>= 1.0.2, < 2.0) mime-types (>= 1.16, < 4.0) netrc (~> 0.8) - rexml (3.3.1) + rexml (3.3.2) strscan rouge (4.3.0) rubocop (1.64.1) @@ -617,9 +640,26 @@ GEM rubocop (~> 1.61) ruby-progressbar (1.13.0) ruby2_keywords (0.0.5) - sass-embedded (1.77.5) - google-protobuf (>= 3.25, < 5.0) - rake (>= 13) + sass-embedded (1.77.8-aarch64-linux-gnu) + google-protobuf (~> 4.26) + sass-embedded (1.77.8-aarch64-linux-musl) + google-protobuf (~> 4.26) + sass-embedded (1.77.8-arm-linux-gnueabihf) + google-protobuf (~> 4.26) + sass-embedded (1.77.8-arm-linux-musleabihf) + google-protobuf (~> 4.26) + sass-embedded (1.77.8-arm64-darwin) + google-protobuf (~> 4.26) + sass-embedded (1.77.8-x86-linux-gnu) + google-protobuf (~> 4.26) + sass-embedded (1.77.8-x86-linux-musl) + google-protobuf (~> 4.26) + sass-embedded (1.77.8-x86_64-darwin) + google-protobuf (~> 4.26) + sass-embedded (1.77.8-x86_64-linux-gnu) + google-protobuf (~> 4.26) + sass-embedded (1.77.8-x86_64-linux-musl) + google-protobuf (~> 4.26) sawyer (0.9.2) addressable (>= 2.3.5) faraday (>= 0.17.3, < 3) @@ -683,7 +723,19 @@ GEM zeitwerk (2.6.16) PLATFORMS - ruby + aarch64-linux + aarch64-linux-gnu + aarch64-linux-musl + arm-linux + arm-linux-gnueabihf + arm-linux-musleabihf + arm64-darwin + x86-linux + x86-linux-gnu + x86-linux-musl + x86_64-darwin + x86_64-linux-gnu + x86_64-linux-musl DEPENDENCIES active_model_serializers @@ -727,4 +779,4 @@ DEPENDENCIES webmock BUNDLED WITH - 2.5.5 + 2.5.6 diff --git a/app/assets/config/manifest.js b/app/assets/config/manifest.js index 79c9df477..a0b3e4d26 100644 --- a/app/assets/config/manifest.js +++ b/app/assets/config/manifest.js @@ -1,4 +1,5 @@ //= link_tree ../images //= link application.js //= link admin.js +//= link es6-components.js //= link_tree ../builds diff --git a/app/assets/javascripts/es6-components.js b/app/assets/javascripts/es6-components.js new file mode 100644 index 000000000..2f1781dea --- /dev/null +++ b/app/assets/javascripts/es6-components.js @@ -0,0 +1,11 @@ +// These modules from govuk_publishing_components +// depend on govuk-frontend modules. govuk-frontend +// now targets browsers that support `type="module"`. +// +// To gracefully prevent execution of these scripts +// on browsers that don't support ES6, this script +// should be included in a `type="module"` script tag +// which will ensure they are never loaded. + +//= require govuk_publishing_components/components/button +//= require govuk_publishing_components/components/tabs diff --git a/app/views/layouts/application.html.erb b/app/views/layouts/application.html.erb index bcdc1ea3c..51367a16f 100644 --- a/app/views/layouts/application.html.erb +++ b/app/views/layouts/application.html.erb @@ -1,6 +1,7 @@ <% content_for :head do %> <%= csrf_meta_tag %> <%= javascript_include_tag "admin" %> + <%= javascript_include_tag 'es6-components', type: "module" %> <% end %> <%= render "govuk_publishing_components/components/layout_for_admin", {