Visit Us 1
Visit-us block: puts the place itself on a lit stage beside the address, tap-to-call and this week's hours, walks the visitor through the visit on one step trail, then asks one question that the booking button answers.
Use it in a prompt
Use content/visit-us from the FunnelDNA library. Follow the skill and theme contract. Ask me for the copy, images, and brand details you need; do not invent proof.
Paste into Claude or ChatGPT with FunnelDNA connected (MCP setup), or alongside the skill.
Use it in code
- Save
component.tsx(Code tab) ascomponents/funneldna/content/visit-us.tsx. - Import it and pass your copy and images (Props tab):
import { VisitUs } from "@/components/funneldna/content/visit-us"
It restyles from the theme tokens on any wrapper (Theme tab). The specimen source is a complete working example.
pieces/content/visit-us/component.tsx 369 lines
// layout: product-stage
// Visit-us block: puts the place itself on a lit stage beside the address, tap-to-call and this week's hours, walks the visitor through the visit on one step trail, then asks one question that the booking button answers.
import React from 'react'
import { CalendarCheck, Clock, MapPin, Phone } from 'lucide-react'
export type VisitUsHours = { day: string; hours: string }
export type VisitUsStep = { title: string; detail?: string }
export type VisitUsProps = {
headline?: string
/** Phrase inside the headline that gets one marker stroke. */
highlight?: string
subhead?: string
/** Slot `scene`: storefront, showroom or interior photo. Without it the block drops the stage. */
sceneImage?: string
sceneImageAlt?: string
/** Plain caption under the photo. */
caption?: string
businessName?: string
/** One string per address line. */
addressLines?: string[]
/** Parking, entrance or landmark note under the address. */
addressNote?: string
/** Maps link for the directions button; the button hides without it. */
directionsHref?: string
/** Phone number as it should read; the tap-to-call tile hides without it. */
phone?: string
/** Defaults to tel: plus the digits of `phone`. */
phoneHref?: string
/** Seven rows, Monday to Sunday, highlight today; any other count shows as a plain list. */
hours?: VisitUsHours[]
/** 0 = Monday … 6 = Sunday. Defaults to the visitor's own day. */
today?: number
visitHeading?: string
/** Two to four short items: what to bring or what happens at the visit. */
visitSteps?: VisitUsStep[]
/** The question the button answers. */
question?: string
actionLabel?: string
/** One short reassurance line under the button. */
actionNote?: string
href?: string
onAction?: (event: React.MouseEvent<HTMLElement>) => void
state?: 'default' | 'hover' | 'active' | 'disabled'
copy?: {
/** {day} is replaced by today's day name. */
today?: string
closed?: string
tableCaption?: string
directions?: string
phoneLabel?: string
newTab?: string
}
className?: string
}
const DEFAULT_COPY = {
today: 'Today · {day}',
closed: 'Closed',
tableCaption: 'Opening hours this week',
directions: 'Get directions',
phoneLabel: 'Tap to call',
newTab: '(opens in a new tab)',
}
export function VisitUs(props: VisitUsProps) {
const {
headline = 'Come see it for yourself',
highlight = 'for yourself',
subhead = 'Look around, ask your questions face to face and leave knowing exactly what to expect.',
sceneImage,
sceneImageAlt = '',
caption,
businessName,
addressLines = [],
addressNote,
directionsHref,
phone,
phoneHref,
hours = [],
visitHeading = 'Here’s what happens at your visit',
visitSteps = [],
question = 'Ready to see it in person?',
actionLabel = 'Yes, book my visit',
actionNote,
href,
onAction,
state = 'default',
className,
} = props
const copy = { ...DEFAULT_COPY, ...props.copy }
const titleId = React.useId()
const [localToday] = React.useState(() => (new Date().getDay() + 6) % 7)
const todayIndex = props.today ?? localToday
const weekly = hours.length === 7
const todayRow = weekly ? hours[todayIndex] : undefined
const closedWord = copy.closed.trim().toLowerCase()
const isClosed = (value: string) => value.trim().toLowerCase() === closedWord
const tel = phoneHref ?? (phone ? 'tel:' + phone.replace(/[^0-9+]/g, '') : undefined)
const disabled = state === 'disabled'
const ctaClass = ['cf-visit-us__cta', state === 'hover' && 'is-hover', state === 'active' && 'is-active'].filter(Boolean).join(' ')
const rootClass = ['cf-visit-us', sceneImage ? 'has-image' : 'no-image', className].filter(Boolean).join(' ')
const hasWhere = Boolean(businessName || addressLines.length)
const hasPlace = Boolean(hasWhere || directionsHref || phone)
const steps = visitSteps.slice(0, 4)
const delay = (ms: number): React.CSSProperties => ({ animationDelay: ms + 'ms' })
return (
<section className={rootClass} aria-labelledby={titleId}>
<style>{CSS}</style>
<div className='cf-visit-us__inner'>
<header className='cf-visit-us__head'>
<h2 id={titleId} className='cf-visit-us__title'>{withMarker(headline, highlight)}</h2>
{subhead ? <p className='cf-visit-us__sub' data-reveal='' style={delay(60)}>{subhead}</p> : null}
</header>
<div className='cf-visit-us__grid'>
{sceneImage ? (
<figure className='cf-visit-us__stage' data-reveal='' style={delay(80)}>
<div className='cf-visit-us__frame'>
<span className='cf-visit-us__plate' aria-hidden='true' />
<div className='cf-visit-us__photo'>
<img src={sceneImage} alt={sceneImageAlt} width={1200} height={900} />
</div>
</div>
{caption ? <figcaption className='cf-visit-us__caption'>{caption}</figcaption> : null}
</figure>
) : null}
{hasPlace ? (
<div className='cf-visit-us__place' data-reveal='' style={delay(140)}>
{hasWhere ? (
<div className='cf-visit-us__where'>
<span className='cf-visit-us__pin' aria-hidden='true'><MapPin /></span>
<div className='cf-visit-us__where-text'>
{businessName ? <h3 className='cf-visit-us__name'>{businessName}</h3> : null}
{addressLines.length ? (
<address className='cf-visit-us__address'>
{addressLines.map((line, i) => <span key={i}>{line}</span>)}
</address>
) : null}
{addressNote ? <p className='cf-visit-us__note'>{addressNote}</p> : null}
</div>
</div>
) : null}
{directionsHref ? (
<a className='cf-visit-us__directions' href={directionsHref} target='_blank' rel='noopener noreferrer'>
{copy.directions}
<span className='cf-visit-us__sr'> {copy.newTab}</span>
</a>
) : null}
{phone && tel ? (
<a className='cf-visit-us__phone' href={tel}>
<span className='cf-visit-us__phone-icon' aria-hidden='true'><Phone /></span>
<span className='cf-visit-us__phone-text'>
<span className='cf-visit-us__phone-label'>{copy.phoneLabel}</span>
<span className='cf-visit-us__phone-number'>{phone}</span>
</span>
</a>
) : null}
</div>
) : null}
{hours.length ? (
<div className='cf-visit-us__hours' data-reveal='' style={delay(200)}>
{todayRow ? (
<div className='cf-visit-us__today'>
<p className='cf-visit-us__today-label'>
<Clock aria-hidden='true' />
{copy.today.replace('{day}', todayRow.day)}
</p>
<p className={isClosed(todayRow.hours) ? 'cf-visit-us__today-hours is-closed' : 'cf-visit-us__today-hours'}>{todayRow.hours}</p>
</div>
) : null}
<table className='cf-visit-us__table'>
<caption className='cf-visit-us__sr'>{copy.tableCaption}</caption>
<tbody>
{hours.map((row, i) => {
const current = weekly && i === todayIndex
return (
<tr key={i} className={current ? 'is-today' : undefined} aria-current={current ? 'date' : undefined}>
<th scope='row'>{row.day}</th>
<td className={isClosed(row.hours) ? 'is-closed' : undefined}>{row.hours}</td>
</tr>
)
})}
</tbody>
</table>
</div>
) : null}
</div>
{steps.length ? (
<div className='cf-visit-us__visit' data-reveal='' style={delay(240)}>
<h3 className='cf-visit-us__visit-title'>{visitHeading}</h3>
<ol className='cf-visit-us__steps' style={{ ['--vu-steps' as string]: steps.length } as React.CSSProperties}>
{steps.map((step, i) => (
<li className='cf-visit-us__step' key={i}>
<span className='cf-visit-us__num' aria-hidden='true'>{i + 1}</span>
<span className='cf-visit-us__step-body'>
<span className='cf-visit-us__step-title'>{step.title}</span>
{step.detail ? <span className='cf-visit-us__step-detail'>{step.detail}</span> : null}
</span>
</li>
))}
</ol>
</div>
) : null}
<div className='cf-visit-us__close' data-reveal='' style={delay(280)}>
{question ? <h3 className='cf-visit-us__question'>{question}</h3> : null}
{href && !disabled ? (
<a className={ctaClass} href={href} onClick={onAction}>{actionLabel}</a>
) : (
<button type='button' className={ctaClass} disabled={disabled} onClick={onAction}>{actionLabel}</button>
)}
{actionNote ? (
<p className='cf-visit-us__cta-note'>
<CalendarCheck aria-hidden='true' />
{actionNote}
</p>
) : null}
</div>
</div>
</section>
)
}
export default VisitUs
function withMarker(text: string, phrase?: string): React.ReactNode {
if (!phrase) return text
const at = text.indexOf(phrase)
if (at < 0) return text
return (
<>
{text.slice(0, at)}
<span className='cf-visit-us__mark'>{phrase}</span>
{text.slice(at + phrase.length)}
</>
)
}
const CSS = `
.cf-visit-us{--vu-r:var(--radius,10px);--vu-shadow:var(--shadow,oklch(0.22 0.03 260));position:relative;overflow:hidden;background:var(--surface,#fff);color:var(--ink,#141b2d);font-family:var(--font-body,system-ui,sans-serif);padding:clamp(56px,7vw,104px) 20px}
.cf-visit-us *,.cf-visit-us *::before,.cf-visit-us *::after{box-sizing:border-box}
.cf-visit-us__inner{max-width:1240px;margin:0 auto}
.cf-visit-us__sr{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0}
.cf-visit-us__head{text-align:center;max-width:900px;margin:0 auto clamp(40px,5vw,64px)}
.cf-visit-us__title{margin:0 0 clamp(14px,1.4vw,22px);font-family:var(--font-display,inherit);font-weight:var(--display-weight,800);text-transform:var(--display-case,none);letter-spacing:var(--display-tracking,-0.02em);font-size:clamp(2.25rem,4.8vw,4.25rem);line-height:1.04;color:var(--ink);text-wrap:balance}
.cf-visit-us__mark{--vu-marker:color-mix(in oklch,var(--marker,#fae37c) 82%,transparent);background-image:linear-gradient(var(--vu-marker),var(--vu-marker));background-repeat:no-repeat;background-position:0 88%;background-size:100% .44em;padding:0 .07em;margin:0 -.07em;border-radius:.12em .28em .14em .3em;-webkit-box-decoration-break:clone;box-decoration-break:clone}
.cf-visit-us__sub{margin:0 auto;max-width:60ch;font-size:clamp(1.1rem,1.5vw,1.3rem);font-weight:500;line-height:1.5;color:var(--muted);text-wrap:pretty}
.cf-visit-us__grid{display:grid;grid-template-columns:minmax(0,1fr);gap:40px;grid-template-areas:'stage' 'place' 'hours'}
.cf-visit-us.no-image .cf-visit-us__grid{grid-template-areas:'place' 'hours'}
.cf-visit-us__stage{grid-area:stage;margin:0;width:100%;min-width:0}
.cf-visit-us__place{grid-area:place;min-width:0;display:flex;flex-direction:column;gap:16px}
.cf-visit-us__hours{grid-area:hours;min-width:0}
@media (min-width:720px){
.cf-visit-us__grid{grid-template-columns:minmax(0,1fr) minmax(0,1fr);column-gap:36px;row-gap:52px;align-items:start;grid-template-areas:'stage stage' 'place hours'}
.cf-visit-us.no-image .cf-visit-us__grid{grid-template-areas:'place hours'}
.cf-visit-us__stage{max-width:680px;justify-self:center}
}
@media (min-width:1180px){
.cf-visit-us.has-image .cf-visit-us__grid{grid-template-columns:minmax(0,1fr) minmax(0,1.35fr) minmax(0,1fr);grid-template-areas:'place stage hours';column-gap:clamp(32px,3vw,48px)}
.cf-visit-us.has-image .cf-visit-us__stage{max-width:none}
}
.cf-visit-us__frame{position:relative;padding:0 clamp(14px,2vw,24px) clamp(16px,1.8vw,22px)}
.cf-visit-us__plate{position:absolute;left:0;right:0;top:34%;bottom:0;border-radius:calc(var(--vu-r) * 1.8);background:var(--band,#1b2a44);box-shadow:inset 0 0 0 1px oklch(from var(--band-ink,#fff) l c h / 0.08),inset 0 1px 0 oklch(from var(--band,#1b2a44) calc(l + 0.14) c h / 0.8),0 2px 4px oklch(from var(--vu-shadow) l c h / 0.24),0 18px 30px -14px oklch(from var(--vu-shadow) l c h / 0.45)}
.cf-visit-us__photo{position:relative;aspect-ratio:4 / 3;border-radius:calc(var(--vu-r) * 1.4);overflow:hidden;background:color-mix(in oklch,var(--ink) 6%,var(--card));box-shadow:var(--shadow-lg,0 2px 4px oklch(0.22 0.03 260 / 0.22),0 12px 24px -8px oklch(0.22 0.03 260 / 0.32))}
.cf-visit-us__photo img{display:block;width:100%;height:100%;object-fit:cover;object-position:center}
.cf-visit-us__caption{margin:14px auto 0;max-width:52ch;text-align:center;font-size:.95rem;line-height:1.45;color:var(--muted);text-wrap:pretty}
.cf-visit-us__where{display:grid;grid-template-columns:46px minmax(0,1fr);gap:14px;align-items:start}
.cf-visit-us__pin{width:46px;height:46px;border-radius:999px;display:grid;place-items:center;background:color-mix(in oklch,var(--ink) 5%,var(--surface));color:var(--accent)}
.cf-visit-us__pin svg{width:22px;height:22px}
.cf-visit-us__where-text{min-width:0}
.cf-visit-us__name{margin:5px 0 8px;font-family:var(--font-display,inherit);font-weight:var(--display-weight,800);text-transform:var(--display-case,none);font-size:clamp(1.35rem,1.8vw,1.5rem);line-height:1.2;color:var(--ink);text-wrap:balance}
.cf-visit-us__address{display:flex;flex-direction:column;font-style:normal;font-size:1.08rem;line-height:1.5;color:var(--ink)}
.cf-visit-us__note{margin:6px 0 0;font-size:.95rem;line-height:1.45;color:var(--muted);text-wrap:pretty}
.cf-visit-us__directions{--vu-b2:var(--button-2-bg,var(--secondary,oklch(0.93 0.015 263)));display:flex;align-items:center;justify-content:center;width:100%;min-height:54px;margin-top:4px;padding:12px 20px;border:1px solid var(--button-2-border,transparent);border-radius:var(--button-radius,var(--vu-r));background:var(--vu-b2);color:var(--button-2-ink,var(--secondary-ink,var(--ink)));font-family:var(--button-font,var(--font-display,inherit));font-weight:var(--button-weight,800);text-transform:var(--button-case,none);font-size:1.05rem;line-height:1.2;text-align:center;text-decoration:none;box-shadow:var(--button-2-shadow, var(--shadow-sm))}
.cf-visit-us__directions:hover{background:oklch(from var(--vu-b2) calc(l - 0.04) c h)}
.cf-visit-us__directions:active{transform:translateY(1px)}
.cf-visit-us__phone{display:grid;grid-template-columns:48px minmax(0,1fr);align-items:center;gap:14px;min-height:80px;padding:14px 16px;border-radius:calc(var(--vu-r) * 1.2);background:color-mix(in oklch,var(--ink) 5%,var(--surface));color:var(--ink);text-decoration:none}
.cf-visit-us__phone-icon{width:48px;height:48px;border-radius:999px;display:grid;place-items:center;background:var(--card,#fff);color:var(--accent);box-shadow:var(--shadow-sm,0 1px 2px oklch(0.22 0.03 260 / 0.2))}
.cf-visit-us__phone-icon svg{width:22px;height:22px}
.cf-visit-us__phone-text{min-width:0}
.cf-visit-us__phone-label{display:block;font-size:.92rem;font-weight:600;line-height:1.3;color:var(--ink)}
.cf-visit-us__phone-number{display:block;margin-top:2px;font-family:var(--font-display,inherit);font-weight:var(--display-weight,800);font-size:clamp(1.35rem,1.9vw,1.6rem);line-height:1.2;letter-spacing:-0.01em;font-variant-numeric:lining-nums tabular-nums;white-space:nowrap;text-decoration:underline;text-decoration-thickness:2px;text-underline-offset:.18em;text-decoration-color:transparent}
.cf-visit-us__phone:hover{background:color-mix(in oklch,var(--ink) 8%,var(--surface))}
.cf-visit-us__phone:hover .cf-visit-us__phone-number{text-decoration-color:currentColor}
.cf-visit-us__phone:active{transform:scale(.99)}
.cf-visit-us__hours{padding:18px;background:var(--card,#fff);border:1px solid var(--card-border,color-mix(in oklch,var(--ink) 12%,transparent));border-radius:var(--card-radius,calc(var(--vu-r) * 1.4));box-shadow:var(--card-shadow,var(--shadow-md,0 1px 2px oklch(0.22 0.03 260 / 0.22),0 4px 10px -2px oklch(0.22 0.03 260 / 0.2)))}
.cf-visit-us__today{margin-bottom:12px;padding:14px 16px;border-radius:var(--vu-r);background:color-mix(in oklch,var(--accent-fill,var(--accent)) 10%,var(--card))}
.cf-visit-us__today-label{display:flex;align-items:center;gap:8px;margin:0;font-size:.98rem;font-weight:700;line-height:1.3;color:var(--ink)}
.cf-visit-us__today-label svg{flex:none;width:18px;height:18px;color:var(--accent)}
.cf-visit-us__today-hours{margin:8px 0 0;font-family:var(--font-display,inherit);font-weight:var(--display-weight,800);font-size:clamp(1.45rem,2vw,1.75rem);line-height:1.15;letter-spacing:-0.01em;font-variant-numeric:lining-nums tabular-nums;color:var(--ink);text-wrap:balance}
.cf-visit-us__table{width:100%;border-collapse:separate;border-spacing:0;font-size:1rem}
.cf-visit-us__table th,.cf-visit-us__table td{padding:9px 12px;border-bottom:1px solid oklch(from var(--ink) l c h / 0.1);line-height:1.35;color:var(--ink);vertical-align:top}
.cf-visit-us__table th{text-align:left;font-weight:700;white-space:nowrap}
.cf-visit-us__table td{text-align:right;font-weight:500;font-variant-numeric:lining-nums tabular-nums;text-wrap:balance}
.cf-visit-us__table tr:last-child > *{border-bottom-color:transparent}
.cf-visit-us__table tr.is-today > *{background:color-mix(in oklch,var(--accent-fill,var(--accent)) 10%,var(--card));font-weight:800;border-bottom-color:transparent}
.cf-visit-us__table tr.is-today > th{border-radius:var(--vu-r) 0 0 var(--vu-r)}
.cf-visit-us__table tr.is-today > td{border-radius:0 var(--vu-r) var(--vu-r) 0}
.cf-visit-us__table td.is-closed{color:var(--muted)}
.cf-visit-us__visit{margin-top:clamp(40px,5vw,60px);padding:clamp(22px,3vw,34px);border-radius:calc(var(--vu-r) * 1.4);background:color-mix(in oklch,var(--ink) 4%,var(--surface))}
.cf-visit-us__visit-title{margin:0 0 20px;font-family:var(--font-display,inherit);font-weight:var(--display-weight,800);text-transform:var(--display-case,none);font-size:clamp(1.25rem,1.7vw,1.5rem);line-height:1.25;color:var(--ink);text-wrap:balance}
.cf-visit-us__steps{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:18px}
.cf-visit-us__step{position:relative;display:grid;grid-template-columns:34px minmax(0,1fr);gap:14px;align-items:start}
.cf-visit-us__step:not(:last-child)::before{content:'';position:absolute;left:16px;top:42px;bottom:-12px;width:2px;border-radius:2px;background:oklch(from var(--ink) l c h / 0.16);transform-origin:top}
.cf-visit-us__num{width:34px;height:34px;border-radius:999px;display:grid;place-items:center;background:var(--band,#1b2a44);color:var(--band-ink,#fff);box-shadow:inset 0 0 0 1px oklch(from var(--band-ink,#fff) l c h / 0.16),var(--shadow-sm,0 1px 2px oklch(0.22 0.03 260 / 0.2));font-family:var(--font-body,inherit);font-weight:800;font-size:.98rem;line-height:1;font-variant-numeric:lining-nums tabular-nums}
.cf-visit-us__step-body{min-width:0}
.cf-visit-us__step-title{display:block;padding-top:6px;font-weight:700;font-size:1.05rem;line-height:1.35;color:var(--ink);text-wrap:pretty}
.cf-visit-us__step-detail{display:block;margin-top:3px;font-size:1rem;line-height:1.5;color:var(--muted);text-wrap:pretty}
@media (min-width:720px){
.cf-visit-us__steps{--vu-gap:clamp(24px,3vw,44px);display:grid;grid-template-columns:repeat(var(--vu-steps,3),minmax(0,1fr));gap:var(--vu-gap)}
.cf-visit-us__step{grid-template-columns:minmax(0,1fr);gap:14px}
.cf-visit-us__step:not(:last-child)::before{left:48px;right:calc(var(--vu-gap) * -1 + 12px);top:16px;bottom:auto;width:auto;height:2px;transform-origin:left}
.cf-visit-us__step-title{padding-top:0}
}
.cf-visit-us__close{display:flex;flex-direction:column;align-items:center;margin-top:clamp(48px,5.5vw,72px);text-align:center}
.cf-visit-us__question{margin:0 0 20px;font-family:var(--font-display,inherit);font-weight:var(--display-weight,800);text-transform:var(--display-case,none);font-size:clamp(1.55rem,2.8vw,2.25rem);line-height:1.15;color:var(--ink);text-wrap:balance}
.cf-visit-us__cta{--vu-bg:var(--button-bg,var(--cta,#d63a2f));--vu-bg2:var(--button-bg-2,var(--cta-2,#b52b22));appearance:none;display:inline-flex;align-items:center;justify-content:center;width:100%;max-width:480px;min-height:66px;margin:0 auto;padding:16px 30px;border:1px solid oklch(from var(--vu-bg2) calc(l - 0.05) c h);border-radius:var(--button-radius,var(--vu-r));background:linear-gradient(180deg,oklch(from var(--vu-bg) calc(l + 0.04) c h),var(--vu-bg2));color:var(--button-ink,var(--cta-ink,#fff));font-family:var(--button-font,var(--font-display,inherit));font-weight:var(--button-weight,800);text-transform:var(--button-case,none);font-size:clamp(1.2rem,1.9vw,1.45rem);line-height:1.15;letter-spacing:-0.005em;text-align:center;text-wrap:balance;text-decoration:none;text-shadow:var(--button-text-shadow,none);cursor:pointer;box-shadow:var(--button-shadow,inset 0 1px 0 oklch(from var(--vu-bg) calc(l + 0.14) c h / 0.7),inset 0 -3px 0 oklch(from var(--vu-bg) calc(l - 0.16) c h),0 1px 2px oklch(from var(--vu-shadow) l c h / 0.3),0 8px 16px -6px oklch(from var(--vu-shadow) l c h / 0.45))}
.cf-visit-us__cta:hover:not(:disabled),.cf-visit-us__cta.is-hover{transform:translateY(-1px);background:linear-gradient(180deg,oklch(from var(--vu-bg) calc(l - 0.01) c h),oklch(from var(--vu-bg2) calc(l - 0.05) c h))}
.cf-visit-us__cta:active:not(:disabled),.cf-visit-us__cta.is-active{transform:translateY(1px);background:linear-gradient(180deg,oklch(from var(--vu-bg) calc(l - 0.05) c h),oklch(from var(--vu-bg2) calc(l - 0.08) c h));box-shadow:inset 0 1px 0 oklch(from var(--vu-bg) calc(l + 0.08) c h / 0.5),inset 0 -1px 0 oklch(from var(--vu-bg) calc(l - 0.16) c h),0 1px 2px oklch(from var(--vu-shadow) l c h / 0.32)}
.cf-visit-us__cta:disabled{cursor:not-allowed;transform:none;background:var(--secondary,oklch(0.93 0.015 263));color:var(--secondary-ink,var(--ink));border-color:transparent;text-shadow:none;box-shadow:var(--button-2-shadow, var(--shadow-sm))}
.cf-visit-us__cta-note{margin:14px 0 0;max-width:46ch;font-size:.95rem;line-height:1.45;color:var(--muted);text-wrap:pretty}
.cf-visit-us__cta-note svg{display:inline-block;width:1.05em;height:1.05em;vertical-align:-.17em;margin-inline-end:.4em;color:var(--success)}
.cf-visit-us a:focus-visible,.cf-visit-us button:focus-visible{outline:3px solid var(--field-focus,var(--accent));outline-offset:3px}
@media (max-width:519px){
.cf-visit-us{padding:52px 16px 60px}
.cf-visit-us__grid{gap:34px}
.cf-visit-us__hours{padding:14px}
.cf-visit-us__table th,.cf-visit-us__table td{padding:9px 10px}
.cf-visit-us__visit{padding:20px 18px}
.cf-visit-us__cta{padding:16px 20px}
}
@media (prefers-reduced-motion:no-preference){
.cf-visit-us__mark{animation:cf-visit-us-swipe .7s cubic-bezier(.2,.7,.2,1) .25s both}
.cf-visit-us [data-reveal]{animation:cf-visit-us-rise .5s cubic-bezier(.2,.7,.2,1) both}
.cf-visit-us__photo img{animation:cf-visit-us-settle 1.1s cubic-bezier(.2,.7,.2,1) both}
.cf-visit-us__cta,.cf-visit-us__directions,.cf-visit-us__phone{transition:transform .16s ease,background-color .16s ease,box-shadow .16s ease}
.cf-visit-us__phone-number{transition:text-decoration-color .16s ease}
@supports (animation-timeline:view()){
.cf-visit-us__step:not(:last-child)::before{animation:cf-visit-us-trail-y linear both;animation-timeline:view();animation-range:entry 20% cover 45%}
@media (min-width:720px){
.cf-visit-us__step:not(:last-child)::before{animation-name:cf-visit-us-trail-x}
}
}
}
@keyframes cf-visit-us-swipe{from{background-size:0% .44em}to{background-size:100% .44em}}
@keyframes cf-visit-us-rise{from{opacity:.82;transform:translateY(8px)}to{opacity:1;transform:none}}
@keyframes cf-visit-us-settle{from{transform:scale(1.06)}to{transform:scale(1)}}
@keyframes cf-visit-us-trail-y{from{transform:scaleY(0)}to{transform:scaleY(1)}}
@keyframes cf-visit-us-trail-x{from{transform:scaleX(0)}to{transform:scaleX(1)}}
`
pieces/content/visit-us/specimen.tsx 43 lines
import __studioImagef3ae0619 from "../assets/b0754a223b11eea1.webp";
// Specimen: a fictional neighbourhood strength studio inviting a first visit.
import { VisitUs } from '../visit-us'
import type { VisitUsProps } from '../visit-us'
import { slot } from '../../slots'
export const states = ['default', 'hover', 'active', 'disabled']
export default function VisitUsSpecimen({ state = 'default' }: { state?: VisitUsProps['state'] }) {
return (
<VisitUs
state={state}
headline='See the studio before you sign up'
highlight='before you sign up'
subhead='Tour the training floor, meet a coach and try a short session. One visit tells you more than any web page.'
sceneImage={slot('scene', __studioImagef3ae0619)}
sceneImageAlt='The glass-fronted entrance of Harbor Street Strength in late-afternoon light'
caption='The front entrance on Harbor Street, with the training floor in full view'
businessName='Harbor Street Strength'
addressLines={['214 Harbor Street', 'Portland, ME 04101']}
addressNote='Free parking behind the building'
directionsHref='https://www.google.com/maps/search/?api=1&query=214+Harbor+Street+Portland+ME+04101'
phone='(555) 014-2290'
hours={[
{ day: 'Monday', hours: '6:00 am – 9:00 pm' },
{ day: 'Tuesday', hours: '6:00 am – 9:00 pm' },
{ day: 'Wednesday', hours: '6:00 am – 9:00 pm' },
{ day: 'Thursday', hours: '6:00 am – 9:00 pm' },
{ day: 'Friday', hours: '6:00 am – 8:00 pm' },
{ day: 'Saturday', hours: '8:00 am – 4:00 pm' },
{ day: 'Sunday', hours: 'Closed' },
]}
visitSteps={[
{ title: 'Tour the training floor', detail: 'See the space, the equipment and the class schedule.' },
{ title: 'Meet your coach', detail: 'Ten minutes to talk through your goals.' },
{ title: 'Try a short session', detail: 'Bring trainers and a water bottle. We supply the rest.' },
]}
question='Ready to see it for yourself?'
actionLabel='Yes, book my free visit'
actionNote='Takes 30 seconds to book · No obligation to join'
/>
)
}
| Name | Type | Details |
|---|---|---|
headline OptionalVisitUs |
string |
|
highlight OptionalVisitUs |
string |
|
subhead OptionalVisitUs |
string |
|
sceneImage OptionalVisitUs |
string |
|
sceneImageAlt OptionalVisitUs |
string |
|
caption OptionalVisitUs |
string |
|
businessName OptionalVisitUs |
string |
|
addressLines OptionalVisitUs |
string[] |
|
addressNote OptionalVisitUs |
string |
|
directionsHref OptionalVisitUs |
string |
|
phone OptionalVisitUs |
string |
|
phoneHref OptionalVisitUs |
string |
|
hours OptionalVisitUs |
VisitUsHours[] |
|
today OptionalVisitUs |
number |
|
visitHeading OptionalVisitUs |
string |
|
visitSteps OptionalVisitUs |
VisitUsStep[] |
|
question OptionalVisitUs |
string |
|
actionLabel OptionalVisitUs |
string |
|
actionNote OptionalVisitUs |
string |
|
href OptionalVisitUs |
string |
|
onAction OptionalVisitUs |
(event: React.MouseEvent<HTMLElement>) => void |
|
state OptionalVisitUs |
'default' | 'hover' | 'active' | 'disabled' |
|
copy OptionalVisitUs |
{
/** {day} is replaced by today's day name. */
today?: string
closed?: string
tableCaption?: string
directions?: string
phoneLabel?: string
newTab?: string
} |
|
className OptionalVisitUs |
string |
Theme roles it reads
Set by the theme bar, a preset or your brand. Colours come from the base tokens (--surface, --ink, --cta…) every piece uses.
--button-bg--button-bg-2--button-case--button-font--button-ink--button-radius--button-shadow--button-text-shadow--button-weight- Main CTA button: background, ink, font, weight, case, radius and shadow.
--button-2-bg--button-2-border--button-2-ink--button-2-shadow- Secondary button.
--card-border--card-radius--card-shadow- Cards and panels: radius, border and shadow.
--display-case--display-tracking--display-weight- Headlines: weight, letter case and tracking.
--field-focus- Form inputs: background, ink, border, radius and focus colour.
--marker- The highlighter colour behind key phrases.
Image slots
Filled from the brand’s images; the specimen ships its own defaults.
scene- A wide atmosphere photo behind or beside the copy.
-
b0754a223b11eea1.webp
image/webp · 307 KB