Skip to content

Replace theme with Tailwind CSS + Alpine.js#22

Merged
drmowinckels merged 11 commits intomainfrom
feat/tailwind-theme
Mar 23, 2026
Merged

Replace theme with Tailwind CSS + Alpine.js#22
drmowinckels merged 11 commits intomainfrom
feat/tailwind-theme

Conversation

@drmowinckels
Copy link
Contributor

Summary

  • New capro-tw theme replacing Bootstrap 4 + jQuery with Tailwind CSS 4 + Alpine.js
  • Self-hosted fonts (Space Grotesk, Spectral) via @fontsource — no Google Fonts CDN
  • FontAwesome compiled from SCSS with deferred loading
  • Client-side publication fetching via OpenAlex API (replaces R script + GitHub Action)
  • WebP image conversion throughout
  • All vendor assets pre-built via npm postinstall — site users only need Hugo

Lighthouse scores (old → new)

Performance Accessibility Best Practices SEO
Homepage 53 → 89 79 → 100 96 → 100 92 → 83*
Team page 65 → 82 50 → 100 92 → 100 83 → 83

*SEO dip is rel=canonical pointing to localhost in dev — resolves in production.

Eliminated dependencies

jQuery, Bootstrap 4 CSS+JS, Shuffle.js, Slick carousel, Magnific Popup, Lozad.js, Google Fonts CDN, R scholar package, weekly GitHub Action

Architecture

  • npm install in themes/capro-tw/ builds everything (postinstall)
  • Tailwind scans layout templates via @source directive
  • Alpine.js handles nav toggle, portfolio filtering, testimonial scroll
  • IntersectionObserver for scroll reveal and counter animations

Test plan

  • Verify hugo build succeeds
  • Check all homepage sections render correctly
  • Test team member pages with ORCID publication loading
  • Test Norwegian language version
  • Test mobile responsive layout
  • Verify portfolio filtering works
  • Test testimonial horizontal scroll with chevrons

🤖 Generated with Claude Code

drmowinckels and others added 2 commits March 22, 2026 22:25
Replace the Bootstrap 4 + jQuery theme with a modern stack:
- Tailwind CSS 4 with CSS-first configuration and design tokens
- Alpine.js for interactive components (nav, portfolio filter, testimonials)
- Self-hosted fonts via @fontsource (Space Grotesk, Spectral)
- FontAwesome compiled from SCSS, deferred loading
- Vanilla JS for scroll reveal and counter animations
- WebP image conversion throughout
- Client-side publication fetching via OpenAlex API (replaces R/GH Action pipeline)

Performance: Lighthouse homepage 53→89, team page 65→82
Accessibility: 100 on both pages
Best Practices: 100 on both pages

Removes gscholar_id from team member front matter (publications
now fetched client-side using ORCID IDs from social links).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@github-actions
Copy link

The PR has been deployed as a preview.
Please double check it looks ok before merging.

- Remove R publication pipeline (scripts/get_pubs.R, weekly GH Action, data/team/pubs/)
- Update CI workflows to install Node.js and theme npm deps
- Remove weekly cron schedule (no longer needed without R fetching)
- Remove libcurl system dependency (was only for R)
- Fix misspelled config filename (langauges → languages)
- Fix Norwegian language config YAML indentation
- Add node_modules/ to .gitignore

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@github-actions
Copy link

The PR has been deployed as a preview.
Please double check it looks ok before merging.

- About: larger hexagons (160px), teal headings, more card padding
- Services: restore distinctive offset shadow, teal headings, muted icons
- Counters: dark card boxes around each counter item
- Add theme attribution to Themefisher's Timer theme in theme.toml

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@github-actions
Copy link

The PR has been deployed as a preview.
Please double check it looks ok before merging.

- Remove hover effect from service blocks (no associated action)
- Increase service block padding and soften offset shadow
- Alternate bg-dark/bg-grey across homepage sections
- Single-word section titles render in grey, not red accent
- Counter cards with dark background boxes

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@github-actions
Copy link

The PR has been deployed as a preview.
Please double check it looks ok before merging.

- Add SVG wave lines (primary red curves) to hero bottom, CTA edges, and footer top
- Match original theme styling: larger hexagons, service offset shadows, counter cards
- Portfolio cards with white image area, hover overlay with search circle, dark meta
- Team cards with border, red highlight on hover
- Section heading divider matches original (grey line with centered red bar)
- Alternating section backgrounds (dark/grey)
- Tighten footer spacing between waves and content

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@github-actions
Copy link

The PR has been deployed as a preview.
Please double check it looks ok before merging.

drmowinckels and others added 2 commits March 23, 2026 20:35
The CTA section already has a "Book a consultation" button.
Simplify contact to just the content text and address details.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Contact section now shows address details on the left and the
booking card on the right. The markdown content with inline
booking link is removed to avoid duplication.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@github-actions
Copy link

The PR has been deployed as a preview.
Please double check it looks ok before merging.

1 similar comment
@github-actions
Copy link

The PR has been deployed as a preview.
Please double check it looks ok before merging.

- Add interactive OpenStreetMap via Leaflet.js with red marker
- Leaflet loaded on demand (no API key needed)
- Team cards with subtle border, red on hover
- Footer spacing tightened

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@github-actions
Copy link

The PR has been deployed as a preview.
Please double check it looks ok before merging.

- Add leaflet as npm dependency
- Sync Leaflet JS, CSS, and images via postinstall
- Load from local vendor files with SRI integrity
- Remove CDN loading from map.js

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@github-actions
Copy link

The PR has been deployed as a preview.
Please double check it looks ok before merging.

Resolve conflict: langauges.no.yaml was renamed to languages.no.yaml
in this branch and fixed in main. Keep the renamed version.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@drmowinckels drmowinckels merged commit ea6e077 into main Mar 23, 2026
1 check passed
@drmowinckels drmowinckels deleted the feat/tailwind-theme branch March 23, 2026 20:46
@github-actions
Copy link

The PR has been deployed as a preview.
Please double check it looks ok before merging.

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.

1 participant