Browse Source

decruft: subset Bootstrap to used partials (−49 KB CSS)

styles.scss now imports only the Bootstrap 5 parts the theme uses (grid,
containers, offcanvas, carousel, nav/navbar, forms, buttons, tables, list-group,
card, utilities API) instead of the full framework. Dropped: dropdown,
button-group, accordion, breadcrumb, pagination, badge, alert, progress, toasts,
modal, tooltip, popover, spinners, placeholders. Added variables-dark to the
foundation for correct map ordering; removed the stale BS4-era commented import
list. v4-style.min.css 393 → 344 KB. (Full Bootstrap removal is the end-state;
this is the no-markup-change interim win.)
windhamdavid 1 week ago
parent
commit
76f5f675e9
3 changed files with 44 additions and 42 deletions
  1. 15 0
      _claude/notes/upgrade-plan.md
  2. 29 42
      css/styles.scss
  3. 0 0
      v4-style.min.css

+ 15 - 0
_claude/notes/upgrade-plan.md

@@ -127,6 +127,21 @@ font + ~2000 CSS rules + the npm dep all gone). `v4-style.min.css` **472 → 393
   that have it; self-host woff2 for niche ones (Computer Modern). Declare all in `theme.json`
   that have it; self-host woff2 for niche ones (Computer Modern). Declare all in `theme.json`
   `fontFamilies`. (User may add a couple more display fonts.)
   `fontFamilies`. (User may add a couple more display fonts.)
 
 
+**Bootstrap exit path (target: drop it entirely).** Audit (2026-06-21): `styles.scss` compiles the
+**full** framework (~200 KB bulk) but the theme uses a sliver — grid `.container/.row/.col-*` (279
+uses) + only **3 JS components**: offcanvas (nav), carousel (33 — studio/blog-front/about), tab (6 —
+studio). No modal/dropdown/collapse/tooltip. The bespoke homepage is already Bootstrap-independent
+(its `.container` is inline). Gating items for full removal:
+1. **Grid → block layout** — evaporates as each page becomes a block template; the chrome parts
+   (header/footer) convert to block/native layout.
+2. **Offcanvas nav → core Navigation block** (or ~native `<dialog>`+CSS). One component.
+3. **Carousel (+ studio's synced tabs) → the long pole** — no core block carousel; needs a small
+   custom block / CSS scroll-snap + minimal JS. Studio is the crux (carousel + tabs + backstretch +
+   DrawFillSVG = one bespoke unit). Blog-front + about carousels are simpler.
+End-of-migration outcome (gated by the bespoke pages + chrome converting). **Near-term win (no markup
+change):** subset `@import scss/bootstrap` → only used partials (drop modal/dropdown/tooltip/popover/
+accordion/toasts/etc.); utilities-map trimming is a later pass.
+
 **Remaining decruft (see [[dependencies]]):** FontMfizz → inline SVG · FA → FA-Pro sprite (the
 **Remaining decruft (see [[dependencies]]):** FontMfizz → inline SVG · FA → FA-Pro sprite (the
 font drops once classic templates migrate) · animate.css + WOW → CSS/IntersectionObserver ·
 font drops once classic templates migrate) · animate.css + WOW → CSS/IntersectionObserver ·
 fullcalendar → About-only/replace · Bootstrap full → subset to used components ·
 fullcalendar → About-only/replace · Bootstrap full → subset to used components ·

+ 29 - 42
css/styles.scss

@@ -19,8 +19,9 @@ need to test
 
 
 @import '../node_modules/bootstrap/scss/functions';
 @import '../node_modules/bootstrap/scss/functions';
 @import '../node_modules/bootstrap/scss/variables';
 @import '../node_modules/bootstrap/scss/variables';
-@import '../node_modules/bootstrap/scss/mixins';
+@import '../node_modules/bootstrap/scss/variables-dark';
 @import '../node_modules/bootstrap/scss/maps';
 @import '../node_modules/bootstrap/scss/maps';
+@import '../node_modules/bootstrap/scss/mixins';
 
 
 
 
 /***********************************************************
 /***********************************************************
@@ -55,49 +56,35 @@ $offcanvas-vertical-height: 100px !important;
 
 
 
 
 /***********************************************************
 /***********************************************************
-################## Bootstrap Complete ######################
+########## Bootstrap 5 — subset to used parts #############
+   Dropped (unused in the theme): dropdown, button-group,
+   accordion, breadcrumb, pagination, badge, alert, progress,
+   toasts, modal, tooltip, popover, spinners, placeholders.
+   Kept: grid + offcanvas + carousel + nav/navbar + forms/
+   buttons + tables + list-group + card + the utilities API.
+   (Was the full ~200 KB framework.)
 ************************************************************/
 ************************************************************/
 
 
-@import "../node_modules/bootstrap/scss/bootstrap";
-
-
-/***********************************************************
-################## Bootstrap Packages ######################
-************************************************************/
-//@import '../node_modules/bootstrap/scss/root';
-//@import '../node_modules/bootstrap/scss/reboot';
-//@import '../node_modules/bootstrap/scss/type';
-//@import '../node_modules/bootstrap/scss/images';
-//@import '../node_modules/bootstrap/scss/code';
-//@import '../node_modules/bootstrap/scss/grid';
-//@import '../node_modules/bootstrap/scss/tables';
-//@import '../node_modules/bootstrap/scss/forms';
-//@import '../node_modules/bootstrap/scss/buttons';
-//@import '../node_modules/bootstrap/scss/transitions';
-//@import '../node_modules/bootstrap/scss/dropdown';
-//@import '../node_modules/bootstrap/scss/button-group';
-//@import '../node_modules/bootstrap/scss/input-group'; // Requires forms
-//@import '../node_modules/bootstrap/scss/custom-forms';
-//@import '../node_modules/bootstrap/scss/nav';
-//@import '../node_modules/bootstrap/scss/navbar';
-//@import '../node_modules/bootstrap/scss/card';
-//@import '../node_modules/bootstrap/scss/breadcrumb';
-//@import '../node_modules/bootstrap/scss/pagination';
-//@import '../node_modules/bootstrap/scss/badge';
-//@import '../node_modules/bootstrap/scss/jumbotron';
-//@import '../node_modules/bootstrap/scss/alert';
-//@import '../node_modules/bootstrap/scss/progress';
-//@import '../node_modules/bootstrap/scss/media';
-//@import '../node_modules/bootstrap/scss/list-group';
-//@import '../node_modules/bootstrap/scss/close';
-//@import '../node_modules/bootstrap/scss/toasts';
-//@import '../node_modules/bootstrap/scss/modal'; // Requires transitions
-//@import '../node_modules/bootstrap/scss/tooltip';
-//@import '../node_modules/bootstrap/scss/popover';
-//@import '../node_modules/bootstrap/scss/carousel';
-//@import '../node_modules/bootstrap/scss/spinners';
-//@import '../node_modules/bootstrap/scss/utilities';
-//@import '../node_modules/bootstrap/scss/print';
+@import '../node_modules/bootstrap/scss/utilities';
+@import '../node_modules/bootstrap/scss/root';
+@import '../node_modules/bootstrap/scss/reboot';
+@import '../node_modules/bootstrap/scss/type';
+@import '../node_modules/bootstrap/scss/images';
+@import '../node_modules/bootstrap/scss/containers';
+@import '../node_modules/bootstrap/scss/grid';
+@import '../node_modules/bootstrap/scss/tables';
+@import '../node_modules/bootstrap/scss/forms';
+@import '../node_modules/bootstrap/scss/buttons';
+@import '../node_modules/bootstrap/scss/transitions';
+@import '../node_modules/bootstrap/scss/nav';
+@import '../node_modules/bootstrap/scss/navbar';
+@import '../node_modules/bootstrap/scss/card';
+@import '../node_modules/bootstrap/scss/list-group';
+@import '../node_modules/bootstrap/scss/close';
+@import '../node_modules/bootstrap/scss/carousel';
+@import '../node_modules/bootstrap/scss/offcanvas';
+@import '../node_modules/bootstrap/scss/helpers';
+@import '../node_modules/bootstrap/scss/utilities/api';
 
 
 /* Bootstrap Icons font dropped (2026-06-19): the header's 8 nav icons are now
 /* Bootstrap Icons font dropped (2026-06-19): the header's 8 nav icons are now
    inline SVG in parts/header.html, so the full icon font + its ~2000 CSS rules
    inline SVG in parts/header.html, so the full icon font + its ~2000 CSS rules

File diff suppressed because it is too large
+ 0 - 0
v4-style.min.css


Some files were not shown because too many files changed in this diff