Skip to content

Add missing theme infrastructure to opposition motions articles (EN + SV)#1036

Merged
pethers merged 2 commits into
main-98b3b2c36ded3082from
copilot/sub-pr-1016
Mar 11, 2026
Merged

Add missing theme infrastructure to opposition motions articles (EN + SV)#1036
pethers merged 2 commits into
main-98b3b2c36ded3082from
copilot/sub-pr-1016

Conversation

Copilot AI commented Mar 11, 2026

Copy link
Copy Markdown
Contributor

Both news/2026-03-11-opposition-motions-{en,sv}.html were missing the three-part theme system present in all recent news pages, causing flash-of-wrong-theme on load and no theme toggle for users.

Changes

  • <head> — Added theme-init.js after the stylesheet link (anti-flash script)
  • <body> open — Added #theme-toggle button after skip-link, with localised labels (EN: "Switch to dark/light theme", SV: "Byt till mörkt/ljust tema")
  • <body> close — Added theme-toggle.js after existing back-to-top.js

Aligns both articles with the template established in 2026-03-11-committee-reports-{en,sv}.html.

<!-- <head> -->
<link rel="stylesheet" href="../styles.css">
<script src="../js/theme-init.js"></script>  <!-- ← added -->

<!-- <body> open -->
<a href="#main-content" class="skip-link"></a>
<button id="theme-toggle" ></button>       <!-- ← added -->

<!-- <body> close -->
<script src="../js/back-to-top.js"></script>
<script src="../js/theme-toggle.js"></script> <!-- ← added -->

✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

…ggle.js) to EN and SV opposition-motions articles

Co-authored-by: pethers <1726836+pethers@users.noreply.github.com>
Copilot AI changed the title [WIP] Add opposition motions articles for 2026-03-11 (EN, SV) Add missing theme infrastructure to opposition motions articles (EN + SV) Mar 11, 2026
@pethers
pethers marked this pull request as ready for review March 11, 2026 10:47
@pethers
pethers merged commit 07917cc into main-98b3b2c36ded3082 Mar 11, 2026
@pethers
pethers deleted the copilot/sub-pr-1016 branch March 11, 2026 10:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants