When to Come Year Chart

When to come

Theyearbythewater

Sea22°C
Sun12hours a day

Our favorite month: warm water and quiet coves.

We are open
JanFebMarAprMayJunJulAugSepOctNovDec
About this block

When to Come Year ChartPRO

A when-to-visit section for a seasonal hotel: two smooth lines for sea temperature and daily sunshine draw across the twelve months under a bracket marking the open season, and hovering a month glides a marker along both lines while the large serif figures roll over and a short note says what that month is like at the house.

Hotel49: When to Come Year Chart

Two smooth lines for sea temperature and daily sunshine draw across the months under a bracket marking the open season, and hovering a month glides a marker along both lines while the large serif figures roll over and a note describes that month.

Upgrade to Pro

Pro blocks install through the shadcn CLI with your license key and ship their full source. Docs and live previews stay open to everyone, so you can read every block's details first.

Upgrade Now

Installation

Swap YOUR_EMAIL and YOUR_KEY for the email and license key on your account. Find your license key on your account page.

Radix flavor

bash
npx shadcn add "https://beste.dev/r/hotel49?email=YOUR_EMAIL&license_key=YOUR_KEY"

Base UI flavor

bash
npx shadcn add "https://beste.dev/r-base/hotel49?email=YOUR_EMAIL&license_key=YOUR_KEY"

This installs the block to components/beste/block/hotel49.tsx plus the text1 word stagger it uses for the heading.

Quick start

The installed file exports hotel49Demo alongside the block: the exact props behind the preview above. Spread it to get a working section in one line.

tsx
import { Hotel49, hotel49Demo } from "@/components/beste/block/hotel49";

export default function Page() {
  return <Hotel49 {...hotel49Demo} />;
}

Then replace the demo with your own props. Written out, a trimmed setup looks like this:

tsx
import { Hotel49 } from "@/components/beste/block/hotel49";

export default function Page() {
  return (
    <Hotel49
      eyebrow="When to come"
      heading="The year by the water"
      months={[
        { label: "Mar", sea: 16, sun: 6, open: false },
        { label: "Apr", sea: 17, sun: 8, open: true, note: "Wildflowers on every wall, and the sea is for the brave." },
        { label: "May", sea: 19, sun: 10, open: true, note: "Long lunches outside and the first real swims." },
        { label: "Jun", sea: 22, sun: 12, open: true, note: "Our favorite month: warm water and quiet coves." },
        { label: "Nov", sea: 19, sun: 5, open: false },
      ]}
      initialMonth={3}
      closedNote="The house rests and the island belongs to the fishermen."
      labels={{ sea: "Sea", sun: "Sun", seaUnit: "°C", sunUnit: "hours a day", open: "We are open", chart: "Sea temperature and daily sunshine through the year" }}
    />
  );
}

Props

PropTypeDefaultDescription
eyebrowstring–Small line above the heading
headingstring–Section heading, through Text1
monthsMonth[][]One chart column per month, in order
initialMonthnumber0Index of the month selected on load
closedNotestring–Note shown for any month with open: false
labelsLabels–Screen reader names, units and the open season label; the figures panel needs it
classNamestring–Extra classes for the outer <section>
ts
type Month = {
  label: string;
  sea: number;
  sun: number;
  open: boolean;
  note?: string;
};

type Labels = {
  sea: string;
  sun: string;
  seaUnit: string;
  sunUnit: string;
  open: string;
  chart?: string;
};

Behavior notes

  • Each line is a Catmull-Rom curve that passes through every month's value exactly. Sea is scaled into the upper band and sun into the lower band, each between its own minimum and maximum, so the curves never overlap and absolute values are not to scale.
  • The bracket spans from the first to the last month with open: true; months in between that are closed still fall under it. It is not drawn if no month is open.
  • Each month is an invisible full-height button over the chart, selected on hover, focus or click. The marker line and the two dots glide to it over 0.7 seconds, and the figures roll vertically to the new values.
  • The note shows the month's note when open and closedNote when closed. The figures panel is an aria-live="polite" region and only renders when labels is passed.
  • The sea figure appends seaUnit directly to the number; the sun figure prints sunUnit as a separate small label.
  • With reduced motion the curves render fully drawn, the marker jumps instead of gliding and the figures swap with a fade.

More Hotel blocks

View all Hotel
PRO

hotel27

Seasons to Visit

PRO

hotel11

Seasonal Stay Offers

PRO

hotel25

A Day at the House Timeline

Get Pro