Skip to documentation content

Feature blocks

Feature sections that show a real part of the product at a size people can read.

Feature sections explain by showing. The pictures are product scenes drawn at a legible scale, and each one makes a single point. Replace them with crops of your own interface.

Open benefit columns

Three benefits with fine rules between them. No cards, so the words do the work.

npx honestui@latest add features-open-columns
features-open-columns.tsx
import * as React from "react"
import {
  FileCheck as FileCheckIcon,
  History as HistoryIcon,
  MessageSquare as MessageIcon,
} from "honestui/icons"

import {
  MarketingContainer,
  MarketingSection,
} from "@/components/marketing/foundation/section"
import { SectionHeading } from "@/components/marketing/foundation/section-heading"

interface ColumnFeature {
  icon: React.ComponentType<{ className?: string; strokeWidth?: number }>
  title: string
  description: string
}

interface FeaturesOpenColumnsProps {
  title?: React.ReactNode
  description?: React.ReactNode
  /** Three, with two or three lines each. */
  features?: ColumnFeature[]
  /** An anchor for links within the page. */
  id?: string
  className?: string
}

const DEFAULT_FEATURES: ColumnFeature[] = [
  {
    icon: MessageIcon,
    title: "Talk where the words are",
    description:
      "Comments attach to the sentence they are about and close when that sentence changes.",
  },
  {
    icon: FileCheckIcon,
    title: "Approve one exact version",
    description:
      "A yes belongs to the text you read. If the text changes, Recto asks you again.",
  },
  {
    icon: HistoryIcon,
    title: "Trace it a year later",
    description:
      "Every version stays, with the names, dates and reasons that led to the next one.",
  },
]

/** Three benefits between fine rules, for the space right after a hero. */
export function FeaturesOpenColumns({
  title = "Fewer threads, one answer.",
  description,
  features = DEFAULT_FEATURES,
  id,
  className,
}: FeaturesOpenColumnsProps) {
  const titleId = React.useId()

  return (
    <MarketingSection aria-labelledby={titleId} id={id} className={className}>
      <MarketingContainer>
        <SectionHeading titleId={titleId} title={title} description={description} />
        <ul className="m-0 mt-(--mkt-head-gap) grid list-none p-0 md:grid-cols-3">
          {features.map(({ icon: Icon, ...feature }) => (
            <li
              key={feature.title}
              className="border-t-[0.5px] border-(--mkt-line-strong) py-7 md:border-s-[0.5px] md:border-t-0 md:px-8 md:py-1 md:first:border-s-0 md:first:ps-0 md:last:pe-0 lg:px-10"
            >
              <Icon aria-hidden="true" className="size-6 text-(--mkt-ink)" strokeWidth={1.5} />
              <h3 data-slot="feature-title" className="mkt-title mt-6 text-(--mkt-ink) md:mt-10">
                {feature.title}
              </h3>
              <p className="mkt-body mt-2">{feature.description}</p>
            </li>
          ))}
        </ul>
      </MarketingContainer>
    </MarketingSection>
  )
}

export type { ColumnFeature, FeaturesOpenColumnsProps }
DetailGuidance
Use it forThe space right after a hero.
ContentThree features. Titles of two to five words and two or three lines each.
OptionalThe description under the heading.
StatesNone.
RequiresFoundation, Button
Goes well withSplit hero with product preview, Split feature spotlight

Split feature spotlight

One feature beside a picture of it. The three details name things a visitor can find in the picture.

npx honestui@latest add features-split-spotlight
features-split-spotlight.tsx
import * as React from "react"

import { cn } from "@/lib/utils"
import { TextLink } from "@/components/marketing/foundation/action-group"
import {
  ProductFrame,
  ProductStage,
  type StageGround,
} from "@/components/marketing/foundation/product-frame"
import {
  MarketingContainer,
  MarketingSection,
} from "@/components/marketing/foundation/section"
import { MarketingHeading } from "@/components/marketing/foundation/section-heading"
import { StageBackdrop } from "@/components/marketing/foundation/stage-backdrop"
import type {
  MarketingLink,
} from "@/components/marketing/foundation/types"
import { ApprovalPanelScene } from "@/components/marketing/scenes/approval-panel"
import { VersionCompareScene } from "@/components/marketing/scenes/version-compare"

interface SpotlightDetail {
  title: string
  description: string
}

interface FeaturesSplitSpotlightProps {
  title?: React.ReactNode
  description?: React.ReactNode
  /** Up to three. Each one names something the visitor can see in the picture. */
  details?: SpotlightDetail[]
  link?: MarketingLink
  /** Puts the picture on the left. */
  reverse?: boolean
  /** What the frame stands on: an image, an element, or null for a flat tint. */
  backdrop?: StageGround
  /** Replaces the default product scene. Positioned inside the stage. */
  visual?: React.ReactNode
  /** An anchor for links within the page. */
  id?: string
  className?: string
}

const DEFAULT_DETAILS: SpotlightDetail[] = [
  {
    title: "One version, locked",
    description: "Approvals belong to a version. Change a word and the count starts again.",
  },
  {
    title: "A due date people can see",
    description: "Reviewers get one reminder the day before, and none after they answer.",
  },
  {
    title: "A record you can export",
    description: "Who approved what, and when, on one page your auditor can read.",
  },
]

function DefaultVisual() {
  return (
    <>
      <ProductFrame
        label="Version 4 of a returns policy, with two tracked changes."
        className="absolute start-[7%] top-[6%] hidden h-[26rem] w-[46rem] sm:block"
      >
        <VersionCompareScene />
      </ProductFrame>
      <ProductFrame
        label="An approval panel. Legal and Finance have approved. Support is due on Thursday at 17:00."
        className="relative mx-auto w-full max-w-[24rem] sm:absolute sm:end-[7%] sm:bottom-[5.5%] sm:w-[23rem]"
      >
        <ApprovalPanelScene />
      </ProductFrame>
    </>
  )
}

/** One feature, shown at a size where its text can be read. */
export function FeaturesSplitSpotlight({
  title = "Everyone signs the same page.",
  description = "Ask for approval and Recto holds that exact version still. People read it, answer it, and the document publishes itself when the last one says yes.",
  details = DEFAULT_DETAILS,
  link = { label: "How approvals work", href: "#approvals" },
  reverse = false,
  backdrop = <StageBackdrop />,
  visual,
  id,
  className,
}: FeaturesSplitSpotlightProps) {
  const titleId = React.useId()

  return (
    <MarketingSection aria-labelledby={titleId} id={id} className={className}>
      <MarketingContainer>
        <div className="grid items-stretch gap-x-[clamp(2.5rem,1rem+4vw,5rem)] gap-y-12 lg:grid-cols-12">
          <div
            className={cn(
              "flex flex-col lg:col-span-5 lg:py-3",
              reverse && "lg:order-last"
            )}
          >
            <MarketingHeading id={titleId}>{title}</MarketingHeading>
            <p className="mkt-lead mt-5">{description}</p>
            {link && <TextLink link={link} className="mt-6 self-start" />}

            <dl className="m-0 mt-auto pt-10">
              {details.map((detail) => (
                <div
                  key={detail.title}
                  className="border-t-[0.5px] border-(--mkt-line-strong) py-4.5 last:pb-0"
                >
                  <dt className="text-[1rem] leading-6 tracking-[-0.012em] [font-weight:500]">
                    {detail.title}
                  </dt>
                  <dd className="mkt-body m-0 mt-0.5 [font-size:0.9375rem]">
                    {detail.description}
                  </dd>
                </div>
              ))}
            </dl>
          </div>

          <ProductStage
            backdrop={backdrop}
            className="p-5 sm:h-[38rem] sm:p-0 lg:col-span-7 lg:h-[42rem]"
          >
            {visual ?? <DefaultVisual />}
          </ProductStage>
        </div>
      </MarketingContainer>
    </MarketingSection>
  )
}

export type { FeaturesSplitSpotlightProps, SpotlightDetail }
DetailGuidance
Use it forThe feature people buy you for.
ContentA short paragraph and up to three details of one sentence.
OptionalThe link, the details, the backdrop, and reverse to put the picture first.
StatesThe link arrow moves two pixels on hover.
RequiresFoundation, product scenes, Button
Goes well withQuiet logo row, Asymmetric feature grid

Asymmetric feature grid

A dominant panel with two or three beside it. The pictures differ on purpose: a list, a schedule, and a chart that starts at zero and labels its ends.

npx honestui@latest add features-asymmetric-grid
features-asymmetric-grid.tsx
import * as React from "react"

import { cn } from "@/lib/utils"
import { ProductFrame } from "@/components/marketing/foundation/product-frame"
import {
  MarketingContainer,
  MarketingSection,
} from "@/components/marketing/foundation/section"
import { SectionHeading } from "@/components/marketing/foundation/section-heading"
import { FileLibraryScene } from "@/components/marketing/scenes/file-library"
import { ReviewScheduleScene } from "@/components/marketing/scenes/review-schedule"
import { SignoffAnalyticsScene } from "@/components/marketing/scenes/signoff-analytics"

interface GridFeature {
  title: string
  description: string
  visual: React.ReactNode
}

interface FeaturesAsymmetricGridProps {
  title?: React.ReactNode
  description?: React.ReactNode
  /** The first is the main capability. Two or three more support it. */
  features?: GridFeature[]
  /** An anchor for links within the page. */
  id?: string
  className?: string
}

const DEFAULT_FEATURES: GridFeature[] = [
  {
    title: "Every document knows where it stands",
    description:
      "Draft, waiting, approved. The state is part of the document, so nobody has to ask which copy is current.",
    visual: (
      <ProductFrame
        label="A folder of policies. Each row shows a version and a status, such as one approval left."
        className="absolute inset-x-6 top-0 bottom-0 rounded-b-none md:inset-x-8 lg:end-[-4rem]"
      >
        <FileLibraryScene />
      </ProductFrame>
    ),
  },
  {
    title: "Reviews that fit the week",
    description: "See who reads when, and what the publish date is waiting for.",
    visual: (
      <ProductFrame
        label="A week of reviews. Legal and Finance are done, Support is reading now, publishing is on Friday."
        className="absolute inset-x-6 top-0 bottom-6 md:inset-x-8 md:bottom-8"
      >
        <ReviewScheduleScene />
      </ProductFrame>
    ),
  },
  {
    title: "A shorter wait, measured",
    description: "Median days from first draft to final approval, for any team.",
    visual: (
      <ProductFrame
        label="Sample data. Median days to sign-off fall from 9.2 in April to 3.4 in October."
        className="absolute inset-x-6 top-0 bottom-6 md:inset-x-8 md:bottom-8"
      >
        <SignoffAnalyticsScene />
      </ProductFrame>
    ),
  },
]

/** One dominant panel and two or three smaller ones, read top to bottom. */
export function FeaturesAsymmetricGrid({
  title = "From first draft to the copy on file.",
  description = "Recto keeps the document, the discussion and the decision in one place, so the last version is easy to find and easy to trust.",
  features = DEFAULT_FEATURES,
  id,
  className,
}: FeaturesAsymmetricGridProps) {
  const titleId = React.useId()
  const [main, ...rest] = features

  return (
    <MarketingSection aria-labelledby={titleId} id={id} className={className}>
      <MarketingContainer>
        <SectionHeading align="split" titleId={titleId} title={title} description={description} />

        <div className="mt-(--mkt-head-gap) grid gap-3 sm:gap-4 lg:grid-cols-12">
          {main && (
            <FeaturePanel
              feature={main}
              className={cn(
                "min-h-[31rem] lg:col-span-7",
                rest.length === 2 && "lg:row-span-2",
                rest.length === 3 && "lg:col-span-12 lg:min-h-[34rem]"
              )}
                    />
          )}
          {rest.map((feature) => (
            <FeaturePanel
              key={feature.title}
              feature={feature}
              className={cn(
                "min-h-[25rem]",
                rest.length === 3 ? "lg:col-span-4" : "lg:col-span-5"
              )}
            />
          ))}
        </div>
      </MarketingContainer>
    </MarketingSection>
  )
}

function FeaturePanel({
  feature,
  className,
}: {
  feature: GridFeature
  className?: string
}) {
  return (
    <article
      className={cn(
        "flex flex-col overflow-hidden rounded-(--mkt-radius-panel) bg-(--mkt-wash)",
        className
      )}
    >
      <div className={"p-6 md:p-8"}>
        <h3 data-slot="feature-title" className="mkt-title text-(--mkt-ink)">
          {feature.title}
        </h3>
        <p className="mkt-body mt-2 max-w-[27rem]">{feature.description}</p>
      </div>
      <div className="relative min-h-0 flex-1">{feature.visual}</div>
    </article>
  )
}

export type { FeaturesAsymmetricGridProps, GridFeature }
DetailGuidance
Use it forThe middle of a product page.
ContentOne main feature and two or three others. One or two lines each.
OptionalA third supporting panel, which moves the main one to its own row.
StatesNone.
RequiresFoundation, product scenes, Button
Goes well withSplit feature spotlight, Signature quote

Usage

Every prop has a default, so a block renders as soon as it is installed. Pass your own content to replace it.

import { FeaturesSplitSpotlight } from "@/components/marketing/features-split-spotlight"

<FeaturesSplitSpotlight
  title="Everyone signs the same page."
  details={[{ title: "One version, locked", description: "Approvals belong to a version." }]}
  visual={<ApprovalPreview />}
/>

FeaturesSplitSpotlight

PropTypeDefaultDescription
detailsSpotlightDetail[]–Up to three, each with a title and a description.
reversebooleanfalsePuts the picture on the left.
visualReactNode–Replaces the default scene. Positioned inside the stage.
backdropMarketingImage | ReactElement | null–What the frames stand on. Pass null for a flat tint.