/* global React */
// Place detail โ data-driven from assets/attractions.json (?slug=...)
const { useState, useEffect } = React;
const NS_A = window.GamekeepersCottageDesignSystem_070bc7;
const { Eyebrow, Button, Card, Badge, Rating } = NS_A;
const Photo = window.GKPhoto;
const useShell = window.GKuseShell;
const useReviews = window.GKuseReviews;
const reviewStats = window.GKreviewStats;
const IMG = window.GK_IMG;
// Places loader (mirrors Explore) โ assets/attractions.json, then embedded fallback.
let _attrCache = null, _attrPromise = null;
function loadAttractions() {
if (_attrCache) return Promise.resolve(_attrCache);
if (_attrPromise) return _attrPromise;
_attrPromise = (async () => {
try {
const res = await fetch('assets/attractions.json', { cache: 'no-store' });
if (res.ok) { const d = await res.json(); if (d && Array.isArray(d.places)) { _attrCache = d.places; return _attrCache; } }
} catch (e) { /* fall through */ }
if (window.GK_ATTRACTIONS && Array.isArray(window.GK_ATTRACTIONS.places)) { _attrCache = window.GK_ATTRACTIONS.places; return _attrCache; }
_attrCache = [];
return _attrCache;
})();
return _attrPromise;
}
function useAttractions() {
const initial = _attrCache || (window.GK_ATTRACTIONS && window.GK_ATTRACTIONS.places) || [];
const [list, setList] = useState(initial);
useEffect(() => { let live = true; loadAttractions().then(a => { if (live) setList(a); }); return () => { live = false; }; }, []);
return list;
}
function CottageRating() {
const s = reviewStats(useReviews());
return s.count > 0 ?
We couldn't find that place โ it may have been moved or removed.
{place.intro}
} {(place.sections || []).map((s, i) => ({s.text}
The Gamekeeper's Cottage is hidden in its own hundred-acre wood, an easy drive from here.
The Wood, Southwold Rd, Brampton, Beccles NR34 8DW