Skip to content
shadcn.io

shadcn.io is not affiliated with official shadcn/ui

Full-Bleed Version Banner Block for React

An upgrade band for a UI kit: a tinted strip that shows the version you run next to the latest, v3.9.2 to v4.0, a short note and a link to the changelog.

Framework
UI library

Preview

Preview width

Installation

Part of Pro
Pro unlocks the code and one-line install of every Pro button and text effect, plus the MCP for your AI editor.
Have Pro already? Sign in to open it.Opens here as soon as you're Pro.

Overview

A full-bleed version banner for React with Base UI. A faint tint of the theme's muted colour runs across the whole width of the page, and on it one centred line shows where the project stands: the installed version in a muted mono chip, an arrow that turns around in right-to-left layouts, and the latest version in a bolder chip, v3.9.2 to v4.0. Next to them a short note in the muted tone (Fjordship's upgrade takes two minutes with no breaking changes) and an underlined link to the changelog. A screen reader hears "v3.9.2 to v4.0". The strip is 44 pixels tall on a desktop and wraps to two lines at most on a phone, on the page's drafting lines: the rails and a top rule with plus marks. It follows the theme, with no black panel. Built from Guides and Badge. For release nudges, deprecation notices and in-app upgrade prompts.

FAQ

Where does the installed version come from?

It's typed data at the top of the file (UPGRADE.installed), because a block can't read your project. In your app, pass it in from your build (an environment variable, package.json) or from your account data, and hide the banner when it equals latest. The versions sit in bdi elements so they keep their order in a right-to-left page.

How do I change the copy?

Edit UPGRADE: installed, latest, the note (note), the link's words (link) and its destination (href). The chips, the note and the link flow as one piece of text, so on a 320-pixel phone they wrap onto a second line; keep the note to about 45 characters so two lines are enough.

How do the two chips differ?

Both are outline Badges in mono. The installed one is muted, so it recedes; the latest has the background colour behind it, a stronger border and medium weight, so it stands out. No primary colour is involved: the emphasis is weight and contrast, and it works in light and dark.

Does it follow my theme?

Yes. Every colour is a token: bg-muted/50 for the tint, the muted and foreground tones for text and chips. There is no dark scope and no bg-foreground panel.

How does it line up with my navbar and hero?

The tint is on the full-width section and the line sits in the same max-w-6xl page column as every block. The Guides layer draws the rails and one rule along the top with a plus on each crossing, and no bottom rule: the block below draws that line, so a stack never doubles it.

  • Pro

    A slim announcement strip for a writing app's release: one centred line with the version, the news and an underlined link, and a ghost button that folds the strip away.

  • Pro

    A top bar for a collaborative editor with an outline New chip, one line of news and a See it button that opens a popover preview of the feature, with a close at the end.

  • Pro

    A launch band for a design tool: a tinted strip with a centred line, a Launch week chip whose outline a light sweeps three times, and a link to the keynote.

  • Pro

    A release banner for a release-management tool: the latest version set large at the start, and the three before it as a numbered list at the end, split by a solid divider.

  • Pro

    A slim release band between solid rails: a version badge, the headline change, a Shine Button to the notes and a disclosure that opens a second band of three change cells.

  • Pro

    A platform-update band for a code review tool: a tinted strip whose start edge carries a 2 px bar, with a Platform update chip, one sentence and a link to the release notes.