Skip to content
Klarhimmel UI

Review, page note

Review, page note previewReview, page note preview

Install

npx shadcn add @klarhimmel/review-page-note
DetailsAbout, usage, props and more

One page of a site review: its name and address, the page as it is now beside what we propose and why, up to five notes marked keep, change, add or remove (said in…

Import

Import

import Block from '@/components/klarhimmel/blocks/review-page-note';
Also called
  • review/page-note
About
One page of a site review: its name and address, the page as it is now beside what we propose and why, up to five notes marked keep, change, add or remove (said in words, with a shape), and an optional screenshot of the page now with a…
Category
A site review for a customer: the verdict with findings, and a note per page with what to keep, change, add or remove. New project? Set it up once: /get-started/installation.

Notes

When to use it

One page of a site review: the page as it is now beside what we propose, with up to five marked notes and an optional screenshot. For the overall verdict of the whole review, put review-summary first.

Writing for it

- pageName is required (80 characters) and is the h2 of the block. Use the page's own name, and put the path in pageUrl (200 characters) and the crawled address in sourceUrl. - Keep nowText and proposedText to the 300 characters they allow. State what is there, then what changes and why, so the two cards can be read side by side. - Each note takes a type of keep, change, add or remove and a text of up to 240 characters. Start the text with the element, for example the pricing table, so the type word and the text read as one line.

Watch out for

The block is strict: if any prop fails validation it shows a notice that the review could not be shown, never sample text. Empty fields are hidden, and the screenshot caption only appears together with an image.

Usage

The block in a page, with its default content (long lists shortened). Every prop is in the table below.

section.tsx
import { Theme } from '@/components/klarhimmel/theme/style';
import { BlockSurface } from '@/components/klarhimmel/blocks/surface';
import ReviewPageNote from '@/components/klarhimmel/blocks/review-page-note';

export default function Section() {
  return (
    <Theme theme="brand">
      <BlockSurface>
        <ReviewPageNote props={{
          "eyebrow": "Name the topic",
          "pageName": "Name the page",
          "pageUrl": "/om-oss/",
          "sourceUrl": "https://exempel.example/om-oss/",
          "nowTitle": "As is",
          "nowText": "Say in two sentences what the page holds today, what a visitor cannot find on it, and what gets in the way.",
          "proposedTitle": "Suggested",
          "proposedText": "Say in two sentences what the page should hold instead and how it helps the visitor act.",
          "replaces": "Replaces: name the old pages",
          "notesTitle": "Name the list of notes",
          "typeWords": {
            "keep": "Keep",
            "change": "Change",
            "add": "Add",
            "remove": "Remove"
          },
          "notes": [
            {
              "type": "keep",
              "text": "Say what to keep on the page, and why it works"
            },
            {
              "type": "change",
              "text": "Say what to change on the page, and how it should read"
            },
            {
              "type": "add",
              "text": "Say what to add to the page, and where it should sit"
            }
          ],
          "screenshot": {
            "src": "/pictures/scr-shell.avif",
            "alt": "An app shell with a side menu",
            "srcDark": "/pictures/scr-shell-dark.avif"
          },
          "screenshotCaption": "Say what the picture shows and when it was captured"
        }} />
      </BlockSurface>
    </Theme>
  );
}

Props

The type, default and text limit of every prop. On a real page, over-limit text is kept and checkSections flags it (Installation, Check a page before you ship); this live preview shows the default until it fits. The panel above edits all props.

PropTypeDefaultDescription
eyebrowstring'Name the topic'Text, up to 60 characters.
pageNamestring'Name the page'Text, up to 80 characters.
pageUrlstring'/om-oss/'Text, up to 200 characters.
sourceUrlstring'https://exempel.example/om-oss/'Text, up to 300 characters.
nowTitlestring'As is'Text, up to 40 characters.
nowTextstring'Say in two sentences what the page …'Text, up to 300 characters.
proposedTitlestring'Suggested'Text, up to 40 characters.
proposedTextstring'Say in two sentences what the page …'Text, up to 300 characters.
replacesstring'Replaces: name the old pages'Text, up to 160 characters.
notesTitlestring'Name the list of notes'Text, up to 60 characters.
typeWords{ keep, change, add, remove }{…}Fields: keep, change, add, remove.
notes{ type, text }[]4 itemsList of up to 5. Each item: type ('keep' | 'change' | 'add' | 'remove'), text.
screenshotMedia{…}See the type.
screenshotCaptionstring'Say what the picture shows and when…'Text, up to 160 characters.
headingLevel'1' | '2'-One of '1', '2'. Optional; empty is not rendered.