Skip to content

V2.5.0i#123

Merged
igor-starostenko merged 69 commits into
v2.5.0from
v2.5.0i
Jun 19, 2026
Merged

V2.5.0i#123
igor-starostenko merged 69 commits into
v2.5.0from
v2.5.0i

Conversation

@igor-starostenko

@igor-starostenko igor-starostenko commented Jun 18, 2026

Copy link
Copy Markdown
Owner

Changes

Image Optimization

  • BaseImage: Added Contentful image optimization via query params (?w=...&h=...)
  • Article: Constrained thumbnail dimensions to 800x450 max (from full Contentful resolution ~2560x1440)
  • Gallery: Added Contentful params in mapToPhotoAlbumFormat with constrained dimensions

Lighthouse Test

  • Now uses process.env.SITE_URL if set, otherwise falls back to siteConfig.siteUrl (https://igorstar.com)
  • Allows testing with different URLs via environment variable

Results

  • Image sizes reduced from ~455KB to ~85KB (72% reduction)
  • All Lighthouse tests passing
  • LCP improved from 11130ms to ~5400ms

Commits

  • docs: add Lighthouse test SITE_URL env variable documentation
  • test: use env variable for Lighthouse test URL with fallback
  • feat: add Contentful image optimization params in BaseImage
  • perf: constrain image dimensions for article thumbnails to 800x450
  • perf: add Contentful optimization in Gallery component
  • refactor: restore siteUrl to https://igorstar.com

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates Lighthouse testing configurability and improves perceived performance by adding Contentful image resizing parameters and adjusting image sizing behavior in UI components.

Changes:

  • Made Lighthouse test target configurable via SITE_URL and added additional skip guards for missing audits/categories.
  • Added Contentful w/h query params generation for images (BaseImage + Gallery) and introduced a sizes override prop for BaseImage.
  • Adjusted article thumbnail sizing to cap requested dimensions and set an explicit sizes attribute.

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
src/test/lighthouse.test.mjs Adds SITE_URL support and modifies Chrome launch flags/error handling for Lighthouse runs.
src/components/image/baseImage.jsx Adds Contentful resizing params and sizes override; changes how NextImage props are constructed.
src/components/gallery/gallery.jsx Adds Contentful resizing params for gallery images and computes a default sizes string.
src/components/article/article.jsx Caps thumbnail dimensions and adds a sizes attribute for responsive behavior.
readme.md Documents how to run Lighthouse tests with an override URL.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/components/image/baseImage.jsx
Comment thread src/components/image/baseImage.jsx Outdated
Comment thread src/components/gallery/gallery.jsx Outdated
Comment thread src/components/article/article.jsx Outdated
Comment thread src/test/lighthouse.test.mjs
Comment thread readme.md Outdated
igor-starostenko and others added 10 commits June 17, 2026 21:41
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 7 out of 7 changed files in this pull request and generated 2 comments.

Comment thread readme.md Outdated
Comment thread src/test/lighthouse.test.mjs

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 16 out of 17 changed files in this pull request and generated 4 comments.

Comment thread src/helpers/contentful.test.js
Comment thread src/helpers/contentful.test.js
Comment thread src/pages/[category]/[post].jsx Outdated
Comment thread src/components/gallery/gallery.jsx
igor-starostenko and others added 2 commits June 18, 2026 23:01
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
igor-starostenko and others added 2 commits June 18, 2026 23:02
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
hercules-igorstar and others added 10 commits June 19, 2026 06:08
- Add format and quality params to addContentfulParams
- Export addContentfulParams as named export
- Test format parameter (f=webp, f=png) - Test quality parameter (q=80, q=85, q=90) - Test both format and quality together - Test existing query params preservation - Test empty/null value handling
Changed 'separator' from mutable variable to computed inline values in catch block fallback
…ality

- Update expected params from f/q to fm/q (Contentful API change) - Default format is 'webp', quality is 30 per imageConfig - Fix hash fragment test to include default params

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 17 out of 18 changed files in this pull request and generated 3 comments.

Comment thread src/helpers/contentful.js
Comment thread src/helpers/contentful.js Outdated
Comment thread src/helpers/contentful.test.js Outdated
igor-starostenko and others added 5 commits June 19, 2026 02:13
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
@igor-starostenko igor-starostenko merged commit 953aeb6 into v2.5.0 Jun 19, 2026
1 check passed
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.

4 participants