Platform 0.1.6 (contact security) + fidelity fixes from the port review

- .container back in @layer components so Tailwind's px-4 still wins; unlayered it had
  quietly widened the gutter on every page
- shadow-sm -> shadow-xs: Tailwind v4 renamed the scale, so the ported markup was giving
  every white card a heavier shadow than the live site
- route changes jump to the top again instead of smooth-scrolling
- preload the wordmark font and the hero image
This commit is contained in:
2026-07-23 06:09:38 -05:00
parent 292a8e3087
commit 5380f477ca
7 changed files with 18 additions and 18 deletions
+3
View File
@@ -7,6 +7,9 @@
<link rel="icon" media="(prefers-color-scheme: dark)" href="/images/resources/logo_dark.png"> <link rel="icon" media="(prefers-color-scheme: dark)" href="/images/resources/logo_dark.png">
<!-- Preconnect to the photo bucket so product images start loading a round-trip sooner. --> <!-- Preconnect to the photo bucket so product images start loading a round-trip sooner. -->
<link rel="preconnect" href="https://s3.thebennett.net" crossorigin> <link rel="preconnect" href="https://s3.thebennett.net" crossorigin>
<!-- The wordmark is set in these; without preloading they arrive late and the logo visibly reflows. -->
<link rel="preload" as="font" type="font/woff2" href="/src/fonts/raleway-latin.woff2" crossorigin>
<link rel="preload" as="image" href="https://s3.thebennett.net/itsthevine/images/gallery/Outside.webp" fetchpriority="high">
<!-- PageMetaController rewrites the title and the four meta tags below per route, so crawlers and <!-- PageMetaController rewrites the title and the four meta tags below per route, so crawlers and
link-preview scrapers get real per-page metadata instead of one generic shell. Keep the link-preview scrapers get real per-page metadata instead of one generic shell. Keep the
attribute order and quoting as-is — it matches on them. --> attribute order and quoting as-is — it matches on them. -->
+3 -1
View File
@@ -15,7 +15,9 @@ import NotFoundPage from '@/pages/NotFound';
const ScrollToTop = () => { const ScrollToTop = () => {
const { pathname, hash } = useLocation(); const { pathname, hash } = useLocation();
useEffect(() => { useEffect(() => {
if (!hash) window.scrollTo(0, 0); // 'instant' overrides the page's scroll-behavior:smooth, which is meant for the #visit
// anchor, not for landing on a new page.
if (!hash) window.scrollTo({ top: 0, behavior: 'instant' });
}, [pathname, hash]); }, [pathname, hash]);
return null; return null;
}; };
+7 -12
View File
@@ -70,18 +70,13 @@ body {
} }
} }
/* Deliberately unlayered so it overrides Tailwind's own `container` utility — the site's gutters are /* In @layer components, matching the old site. That ordering matters: a utility like `px-4` — which
part of the layout, not the breakpoint default. */ the markup applies alongside `container` on nearly every section — has to win over this, or every
.container { gutter on the site silently widens. */
max-width: 80rem; @layer components {
margin-inline: auto; .container {
padding-inline: 1rem; @apply max-w-7xl mx-auto px-4 sm:px-6 lg:px-8;
} }
@media (min-width: 40rem) {
.container { padding-inline: 1.5rem; }
}
@media (min-width: 64rem) {
.container { padding-inline: 2rem; }
} }
::selection { ::selection {
+1 -1
View File
@@ -50,7 +50,7 @@ const ContactPage = () => {
{/* Contact Form Section */} {/* Contact Form Section */}
<div className="container mx-auto px-4 pb-16 md:pb-24"> <div className="container mx-auto px-4 pb-16 md:pb-24">
<div className="max-w-2xl mx-auto bg-white p-8 md:p-10 rounded-3xl shadow-sm"> <div className="max-w-2xl mx-auto bg-white p-8 md:p-10 rounded-3xl shadow-xs">
<h2 className="font-adbhashitha text-2xl md:text-3xl text-bakery-900 mb-2">Get in touch</h2> <h2 className="font-adbhashitha text-2xl md:text-3xl text-bakery-900 mb-2">Get in touch</h2>
<p className="text-bakery-700 mb-8"> <p className="text-bakery-700 mb-8">
Or call us: <a href="tel:+13097010660" className="underline underline-offset-4 hover:text-bakery-600">(309) 701-0660</a> Or call us: <a href="tel:+13097010660" className="underline underline-offset-4 hover:text-bakery-600">(309) 701-0660</a>
+1 -1
View File
@@ -54,7 +54,7 @@ const HomePage = () => {
{['Cinnamon Rolls', 'Sugar Cookies', 'Cakes'].map((item) => ( {['Cinnamon Rolls', 'Sugar Cookies', 'Cakes'].map((item) => (
<div <div
key={item} key={item}
className="group text-center bg-white rounded-3xl overflow-hidden shadow-sm hover:shadow-lg hover:-translate-y-1 transition duration-300" className="group text-center bg-white rounded-3xl overflow-hidden shadow-xs hover:shadow-lg hover:-translate-y-1 transition duration-300"
> >
<div className="overflow-hidden"> <div className="overflow-hidden">
<img <img
+1 -1
View File
@@ -74,7 +74,7 @@ const ProductsPage = () => {
initial={{ opacity: 0 }} initial={{ opacity: 0 }}
animate={{ opacity: 1 }} animate={{ opacity: 1 }}
exit={{ opacity: 0 }} exit={{ opacity: 0 }}
className="group bg-white rounded-3xl overflow-hidden shadow-sm hover:shadow-lg hover:-translate-y-1 transition duration-300" className="group bg-white rounded-3xl overflow-hidden shadow-xs hover:shadow-lg hover:-translate-y-1 transition duration-300"
> >
{/* Image Container */} {/* Image Container */}
<div className="relative w-full overflow-hidden"> <div className="relative w-full overflow-hidden">
+2 -2
View File
@@ -7,7 +7,7 @@
<parent> <parent>
<groupId>net.thebennett.platform</groupId> <groupId>net.thebennett.platform</groupId>
<artifactId>platform-parent</artifactId> <artifactId>platform-parent</artifactId>
<version>0.1.5</version> <version>0.1.6</version>
<relativePath/> <relativePath/>
</parent> </parent>
@@ -22,7 +22,7 @@
<dependency> <dependency>
<groupId>net.thebennett.platform</groupId> <groupId>net.thebennett.platform</groupId>
<artifactId>platform-bom</artifactId> <artifactId>platform-bom</artifactId>
<version>0.1.5</version> <version>0.1.6</version>
<type>pom</type> <type>pom</type>
<scope>import</scope> <scope>import</scope>
</dependency> </dependency>