import Link from 'next/link'; import Image from 'next/image'; import { getArtworks, getEvents, Artwork, Event } from '@/lib/directus'; import { ArtworkCard } from '@/components/artwork-card'; import { WisdomWordsCarousel } from '@/components/wisdom-words-carousel'; export const revalidate = 60; async function getFeaturedArtworks(): Promise { try { // Fetch more than needed and prefer artworks with images const artworks = await getArtworks({ status: 'published', limit: 50 }); const withImages = artworks.filter((a) => a.image); // Return up to 6 artworks that have images, or fall back to whatever is available return withImages.length >= 6 ? withImages.slice(0, 6) : artworks.slice(0, 6); } catch (error) { console.error('Error fetching artworks:', error); return []; } } async function getUpcomingEvents(): Promise { try { const events = await getEvents({ status: 'published', limit: 4 }); return events; } catch (error) { console.error('Error fetching events:', error); return []; } } function formatEventDate(start?: string, end?: string): string { if (!start) return ''; const s = new Date(start); const opts: Intl.DateTimeFormatOptions = { year: 'numeric', month: 'short', day: 'numeric' }; if (!end) return s.toLocaleDateString('en-GB', opts); const e = new Date(end); return `${s.toLocaleDateString('en-GB', opts)} - ${e.toLocaleDateString('en-GB', opts)}`; } export default async function HomePage() { const [artworks, upcomingEvents] = await Promise.all([ getFeaturedArtworks(), getUpcomingEvents(), ]); // Wisdom words gallery - all quote images from original site const wisdomImages = [ { src: '/images/wisdom-1.png', alt: 'Thich Nhat Hanh quote' }, { src: '/images/wisdom-2.png', alt: 'Call it clan quote' }, { src: '/images/wisdom-3.png', alt: 'James Baldwin quote' }, { src: '/images/wisdom-4.png', alt: 'David Whyte quote' }, { src: '/images/wisdom-5.png', alt: 'Gilbert duty quote' }, { src: '/images/wisdom-6.png', alt: 'Rumi light quote' }, { src: '/images/wisdom-7.png', alt: 'Jane Howard quote' }, { src: '/images/wisdom-8.png', alt: 'Katheryn quote - celebrates' }, { src: '/images/wisdom-9.png', alt: 'Katheryn quote - story' }, { src: '/images/wisdom-10.png', alt: 'Katheryn quote - viewers' }, { src: '/images/wisdom-11.jpg', alt: 'IYOS FB quote' }, { src: '/images/wisdom-12.jpg', alt: 'Oliver quote' }, { src: '/images/wisdom-13.png', alt: 'Walt Whitman quote' }, { src: '/images/wisdom-14.jpg', alt: 'Light quote' }, { src: '/images/wisdom-15.jpg', alt: 'Alan Watts quote' }, { src: '/images/wisdom-16.png', alt: 'Katheryn beauty quote' }, ]; // Instagram feed images const instagramImages = [ { src: '/images/instagram-1.jpg', alt: 'Instagram 1' }, { src: '/images/instagram-2.jpg', alt: 'Instagram 2' }, { src: '/images/instagram-3.jpg', alt: 'Instagram 3' }, { src: '/images/instagram-4.jpg', alt: 'Instagram 4' }, { src: '/images/instagram-5.jpg', alt: 'Instagram 5' }, { src: '/images/instagram-6.jpg', alt: 'Instagram 6' }, ]; return (
{/* HERO - Full screen portrait with quote overlay (matching Squarespace original) */}
{/* Background Image */} Katheryn Trenshaw {/* Overlay */}
{/* Content */}
Working with Katheryn Trenshaw is fun and illuminating. It has served the unfolding of my deep remembering. Artist, healer, transformer; Katheryn embodies what she teaches.
— DJ, Counsellor, Maine, USA
{/* Social Icons */}
{/* Scroll Indicator */}
Scroll
{/* Tagline - Passionate Presence Center */}

Passionate Presence Center
for Creative Expression

Katheryn Trenshaw

{/* ARTWORK Section */}

ARTWORK

Paintings Store

{artworks.length > 0 ? (
{artworks.map((artwork, index) => ( ))}
) : ( /* Static fallback - featured paintings from Squarespace */
{[ { src: 'https://images.squarespace-cdn.com/content/v1/5aef40c1cc8feda235a99bb6/1598803728300-94MWPCAF8LXZF2OB1K4Y/image-asset.jpeg', alt: 'Autumn Offerings' }, { src: 'https://images.squarespace-cdn.com/content/v1/5aef40c1cc8feda235a99bb6/1605636339005-KXP5FWW72I8KV6KNEPU8/%3Cuntitled%3EChoose+Love%2C+Choose+Life.jpg', alt: 'Choose Love, Choose Life' }, { src: 'https://images.squarespace-cdn.com/content/v1/5aef40c1cc8feda235a99bb6/1605636369170-918IHIE2QG2X8559QZI9/%3Cuntitled%3EKT1050--At_the_Stillpoint.jpg', alt: 'At the Stillpoint' }, { src: 'https://images.squarespace-cdn.com/content/v1/5aef40c1cc8feda235a99bb6/1605636398212-Z28TYI1OMR1O6LDO1B9R/%3Cuntitled%3EKT1283--Ecstasy+of+Belonging.jpg', alt: 'Ecstasy of Belonging' }, { src: 'https://images.squarespace-cdn.com/content/v1/5aef40c1cc8feda235a99bb6/1605636452434-S4AS1X4N6FW242BNPYSH/%3Cuntitled%3EKT1033--Births+Blessing+Way.jpg', alt: 'Birth\'s Blessing Way' }, { src: 'https://images.squarespace-cdn.com/content/v1/5aef40c1cc8feda235a99bb6/1605636538275-DBY1CPYS9K1IXM6D0FBK/%3Cuntitled%3ESpiralling+into+Starlight.jpg', alt: 'Spiralling into Starlight' }, ].map((img, index) => (
{img.alt}

{img.alt}

))}
)}
View Store
{/* IN YOUR OWN SKIN Section - Video Background */}
{/* YouTube Video Background */}