Krizaka UI
Krizaka UI
Composants

Force update screen

The blocking screen of a version that can no longer run: the mark, one sentence, one button to the store.

Web · ✓Mobile · ✓Bureau · ✓DépréciéRetours
import { ForceUpdateScreen } from "@krizaka/ui/force-update-screen";

Web et mobile — le même composant pour React et React Native. Déprécié : conservé pour les apps qui l'utilisent encore, retiré à sa prochaine version majeure.

Pourquoi il est là. The web entry has no user (ADR-006 audit, 2026-10-25). The native `ForceUpdateScreen`, used by mobile apps, stays.

DépréciéDepuis 3.55.0, retiré en 4.0.0. The web entry has no user (ADR-006 audit, 2026-10-25). The native `ForceUpdateScreen`, used by mobile apps, stays.

Quand l’utiliser

  • When the backend says updateMode: force or answers 426 Upgrade Required.
  • In place of the whole app: nothing behind it must be reachable.

Quand ne pas l’utiliser

  • When the installed version still works: invite, do not block.À la place : Update prompt
  • When the service is down on purpose.À la place : Maintenance screen

Installation

Installer

npm install @krizaka/ui @krizaka/tailwind @krizaka/tokens tailwindcss

Styles

@import "tailwindcss";
@import "@krizaka/tailwind";
@import "@krizaka/ui/tailwind.css";

Importer

import { ForceUpdateScreen } from "@krizaka/ui/force-update-screen";

Exemples

Default

The title, the sentence, the versions and the store button.

Props

The forced update: one thing to do, and the way to do it.

PropTypeDéfautDescription
onUpdaterequis() => void—Opens the store page.
titlerequisReactNode—The headline (“Update to keep going”).
updateLabelrequisstring—The button that updates (“Update the app”).
markReactNode—The product's mark or mascot (decorative).
messageReactNode—Why, in a sentence — the backend's localized message.
onRetry(() => void)—Checks the backend again.
retryLabelstring—A secondary way (“Check again”) once the update is installed — optional.
versionLabelReactNode—The versions, in words and mono (“You have 1.1.0 · 1.2.0 or later is required”).

Accessibilité

  • A main with the title as its h1; the update button takes focus at once.
  • The mark is decorative.

Bonnes pratiques

  • Say why in one sentence and give one way out: the store button.
  • Show the installed and the required version, in mono.
  • Offer “Check again” for the person who just updated from the store.

Générée depuis le code de @krizaka/ui 3.63.1 : son meta.ts, ses exemples et ses types.Modifier cette documentation sur GitHub

Sur cette page