Skip to content

[Website] Fix minor issues#9878

Merged
tobias-tengler merged 4 commits into
mainfrom
tte/website-polish
Jun 9, 2026
Merged

[Website] Fix minor issues#9878
tobias-tengler merged 4 commits into
mainfrom
tte/website-polish

Conversation

@tobias-tengler

Copy link
Copy Markdown
Member

No description provided.

Copilot AI review requested due to automatic review settings June 9, 2026 16:40
@tobias-tengler tobias-tengler merged commit 84a949f into main Jun 9, 2026
143 of 144 checks passed
@tobias-tengler tobias-tengler deleted the tte/website-polish branch June 9, 2026 16:44

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

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 applies a set of small website (Next.js) UX/performance tweaks and minor refactors: stabilizing local start behavior, improving nav/link loading characteristics, enhancing image/analytics loading, and modernizing the support contact flow.

Changes:

  • Refactors the header navigation into dedicated components/data and disables Next.js link prefetch in multiple UI components.
  • Improves perceived performance via LCP image preloading, smoother hash-navigation behavior (opt-in after first paint), and defers GTM to lazyOnload with preconnect hints.
  • Updates the support contact page to use a client-side form submission endpoint and adds GitHub star count fetching/caching for the header.

Reviewed changes

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

Show a summary per file
File Description
website-next/start-optimized.sh Ensures the script runs from the package root for consistent Yarn/Docker context resolution.
website-next/src/image-optimization/generate.mjs Improves orphan cleanup by also pruning remote original downloads.
website-next/src/helpers/githubStars.ts Adds GitHub repo stargazer count fetching with hourly revalidation.
website-next/src/design-system/Tag.tsx Disables link prefetch to reduce background navigation work.
website-next/src/design-system/Sidebar.tsx Disables link prefetch for sidebar links.
website-next/src/design-system/Picture.tsx Adds ReactDOM.preload for priority AVIF LCP candidates.
website-next/src/design-system/Pagination.tsx Disables link prefetch for pagination links.
website-next/src/components/header/navData.tsx Extracts header nav config/constants into a shared module.
website-next/src/components/header/HeaderNav.tsx Introduces a client header nav component with submenu behavior.
website-next/src/components/Header.tsx Refactors header to use new nav, renders blog image server-side, and displays GitHub star count.
website-next/src/components/EnableSmoothScroll.tsx Adds a client helper to enable smooth scrolling after first paint.
website-next/src/components/AnalyticsScripts.tsx Defers GTM from afterInteractive to lazyOnload and updates rationale.
website-next/package.json Updates ci-local to run the optimized start script.
website-next/app/layout.tsx Adds preconnect/dns-prefetch hints and mounts smooth-scroll enabler.
website-next/app/globals.css Makes smooth scrolling conditional on a runtime flag.
website-next/app/(content)/services/support/contact/page.tsx Moves the contact form UI into a dedicated client component.
website-next/app/(content)/services/support/contact/ContactForm.tsx Implements client-side validation + POST submission to support form API.
.github/workflows/publish-website-next.yml Broadens Next.js cache restore keys to improve cache hit rates.

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

message: string;
}

type FormErrors = Partial<Record<"name" | "email" | "company", string>>;
Comment on lines +55 to +68
function validate(): boolean {
const next: FormErrors = {};
if (data.name.trim().length < 2) {
next.name = "Name is required";
}
if (!EMAIL_REGEX.test(data.email)) {
next.email = "Please enter a valid email address";
}
if (data.company.trim().length < 2) {
next.company = "Company is required";
}
setErrors(next);
return Object.keys(next).length === 0;
}
Comment on lines +162 to +175
<div className="flex flex-col gap-1">
<label htmlFor="message" className="text-sm font-medium text-cc-ink">
Message
</label>
<textarea
id="message"
name="message"
rows={5}
value={data.message}
disabled={isSubmitting}
onChange={(e) => update("message", e.target.value)}
className={`${inputClasses} border-cc-card-border focus:border-fuchsia-500`}
/>
</div>
Comment on lines +12 to +17
useEffect(() => {
const id = requestAnimationFrame(() => {
document.documentElement.dataset.smoothScroll = "true";
});
return () => cancelAnimationFrame(id);
}, []);
Comment on lines +1 to +3
const GITHUB_REPO_API =
"https://api.github.com/repos/ChilliCream/graphql-platform";

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants