Alert
Maintenance Alert
A scheduled maintenance notice: the time window in its own pill and a list of what will be unavailable. The tone is neutral — maintenance is not an outage.
- alert
- maintenance
- schedule
- downtime
Preview
Use it with AI
- 1. Copy the link.
- 2. Write to your agent in your own words and drop the link into the sentence.
- 3. The agent opens the link and installs the component from the registry.
put this in the header: https://vibeui.ru/c/alert-017?lang=en
- Публикация
- Загрузка медиа
- Экспорт
Show the full instructions
What the link says, spelled out. Use it when your agent cannot open links — paste this text instead.
# Install and place "alert-017" (Maintenance Alert) from VibeUI
## 1. Install first — do not skip, do not recreate
Run this exact command before writing any code:
npx shadcn@latest add https://vibeui.ru/r/alert-017.json
Registry item: https://vibeui.ru/r/alert-017.json
Installs to: components/vibeui/alert-017.tsx (the exact path follows this project's components.json aliases).
npm dependencies: none.
Registry dependencies: none.
Install it from the registry. Do not recreate it from the description,
do not substitute a similar component from another library, and do not
rewrite it to match the project's existing style.
## 2. What it is
A scheduled maintenance notice: the time window in its own pill and a list of what will be unavailable. The tone is neutral — maintenance is not an outage.
A maintenance notice: a CSS calendar mark, a heading, the time window in a monospaced pill, an explanation, pills for the affected services and a details link. Neutral tone, no red. Zero dependencies, one file, its own palette.
## 3. How to use it
import { Alert017 } from "@/components/vibeui/alert-017"
<Alert017
window="14 March, 02:00–04:00 UTC"
affected={["Publishing", "Export"]}
/>
Read the installed file for the full prop list.
## 4. Where to place it
This is a small inline component. Put it exactly where the user asked,
inside the existing markup. Do not create a new page, section or
wrapper for it. If a similar control already sits in that spot,
replace it instead of adding a second one.
Placement: ___
(The user fills this line in. If it is still blank, ask where to put it
instead of guessing.)
## 5. Keep exactly as installed
- the local --vibeui-alert-017-* palette — do not swap it for your theme tokens (bg-warning, bg-destructive and the like)
- the neutral tone: planned work dressed in outage colours generates needless support tickets
- the time window in its own monospaced pill — people copy it into a calendar
- the affected list as pills rather than a comma-separated line: enumerations are read one by one
- the CSS calendar mark instead of an icon library
- role="status" rather than alert: an advance notice should not interrupt reading
- the <style> block inside the component — it holds the palette and the mark
## 6. You may change
- window — the date and time with a timezone
- the title and description copy
- affected — what will be unavailable
- detailsLabel and detailsHref — the details link
- width and outer spacing through className
## 7. Rules
- The timezone in the window is mandatory: "02:00–04:00" without one is read as local everywhere.
- Say what keeps working, not only what stops: otherwise people assume the worst.
- The component tracks no clock and does not disappear when the window ends.
- Do not lift the CSS variables into globals.css: the component has to stay a single file.
## 8. Verify
- it renders with no console errors;
- it looks like the preview on the VibeUI page you copied this from;
- if it does not, you changed something listed in section 5 — put it back.For developers
npx shadcn@latest add https://vibeui.ru/r/alert-017.jsonhttps://vibeui.ru/r/alert-017.jsonКомпонент самодостаточен: один файл, без зависимостей, собственная палитра в локальных переменных --vibeui-alert-017-*. Значок-календарь нарисован рамкой и двумя штрихами на псевдоэлементах: иконочная библиотека не нужна. Время работ вынесено в моноширинную плашку — его переписывают в календарь, поэтому оно не должно теряться в абзаце. Затронутые сервисы перечислены плашками, а не строкой через запятую.
Component source
The same file your agent installs. Here in case you would rather copy it by hand.
import type { ComponentPropsWithoutRef, CSSProperties } from "react"
export type Alert017Props = Omit<
ComponentPropsWithoutRef<"div">,
"title" | "children"
> & {
title?: string
description?: string
/** Дата и окно работ: «14 марта, 02:00–04:00 МСК». */
window?: string
/** Что именно будет недоступно, по пунктам. */
affected?: string[]
detailsLabel?: string
detailsHref?: string
}
// Идея компонента: предупреждение о плановых работах. Здесь важно не «что-то
// сломается», а когда и что именно: время вынесено отдельной строкой в рамке,
// а список затронутого — пунктами. Тон нейтральный: плановые работы это не
// авария, и красный цвет вызвал бы лишние звонки в поддержку.
const STYLES = `
:where([data-vibeui-block="alert-017"]){
--vibeui-alert-017-fg:oklch(0.22 0.014 265);
--vibeui-alert-017-muted:oklch(0.5 0.014 265);
--vibeui-alert-017-bg:oklch(1 0 0);
--vibeui-alert-017-panel:oklch(0.97 0.004 265);
--vibeui-alert-017-border:oklch(0.9 0.006 265);
--vibeui-alert-017-accent:oklch(0.55 0.09 250);
--vibeui-alert-017-radius:0.875rem;
--vibeui-alert-017-mono:ui-monospace,SFMono-Regular,Menlo,Consolas,"Liberation Mono",monospace;
--vibeui-alert-017-font:ui-sans-serif,system-ui,-apple-system,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;
container-type:inline-size;
}
[data-vibeui-block="alert-017"]{
display:flex;gap:0.875rem;
width:100%;box-sizing:border-box;
padding:1rem 1.0625rem;
border:1px solid var(--vibeui-alert-017-border);
border-radius:var(--vibeui-alert-017-radius);
background:var(--vibeui-alert-017-bg);color:var(--vibeui-alert-017-fg);
font-family:var(--vibeui-alert-017-font);
}
/* Значок-календарь нарисован рамкой и двумя штрихами: иконка не нужна. */
[data-vibeui-block="alert-017"] [data-part="mark"]{
position:relative;flex:none;width:2rem;height:2rem;margin-top:0.125rem;
border:1.5px solid var(--vibeui-alert-017-accent);border-radius:0.5rem;
}
[data-vibeui-block="alert-017"] [data-part="mark"]::before{
content:"";position:absolute;left:0;right:0;top:0.4375rem;height:1.5px;
background:var(--vibeui-alert-017-accent);
}
[data-vibeui-block="alert-017"] [data-part="mark"]::after{
content:"";position:absolute;left:0.4375rem;top:-0.25rem;
width:1.5px;height:0.5rem;border-radius:1px;
background:var(--vibeui-alert-017-accent);
box-shadow:0.625rem 0 0 var(--vibeui-alert-017-accent);
}
[data-vibeui-block="alert-017"] [data-part="text"]{display:flex;flex-direction:column;gap:0.375rem;flex:1 1 auto;min-width:0}
[data-vibeui-block="alert-017"] [data-part="title"]{font-size:0.9375rem;font-weight:600;line-height:1.35}
/* Время в отдельной плашке моноширинными: его переписывают в календарь. */
[data-vibeui-block="alert-017"] [data-part="window"]{
align-self:flex-start;padding:0.25rem 0.5rem;border-radius:0.4375rem;
background:var(--vibeui-alert-017-panel);
border:1px solid var(--vibeui-alert-017-border);
font-family:var(--vibeui-alert-017-mono);font-size:0.75rem;font-weight:600;
}
[data-vibeui-block="alert-017"] [data-part="description"]{font-size:0.8125rem;line-height:1.55;color:var(--vibeui-alert-017-muted);max-width:60ch}
[data-vibeui-block="alert-017"] ul{margin:0;padding:0;list-style:none;display:flex;flex-wrap:wrap;gap:0.375rem}
[data-vibeui-block="alert-017"] li{
padding:0.125rem 0.4375rem;border-radius:0.3125rem;
background:var(--vibeui-alert-017-panel);
font-size:0.75rem;color:var(--vibeui-alert-017-muted);
}
[data-vibeui-block="alert-017"] [data-part="link"]{
align-self:flex-start;margin-top:0.125rem;
color:var(--vibeui-alert-017-accent);font-size:0.8125rem;font-weight:600;text-decoration:none;
border-bottom:1px solid transparent;transition:border-color .16s ease;
}
[data-vibeui-block="alert-017"] [data-part="link"]:hover{border-bottom-color:currentColor}
[data-vibeui-block="alert-017"] [data-part="link"]:focus-visible{outline:2px solid var(--vibeui-alert-017-accent);outline-offset:3px}
@container (max-width: 22rem){
[data-vibeui-block="alert-017"] [data-part="mark"]{display:none}
}
@media (prefers-reduced-motion:reduce){[data-vibeui-block="alert-017"] *{animation:none!important;transition:none!important}}
`
const DEFAULT_AFFECTED = ["Публикация", "Загрузка медиа", "Экспорт"]
/**
* Предупреждение о плановых работах: окно времени и список затронутого.
* Один файл, ноль зависимостей, собственная палитра.
*/
export function Alert017({
title = "Плановые работы на выходных",
description = "Обновляем хранилище. Опубликованные сайты продолжат работать — недоступной будет только панель управления.",
window: maintenanceWindow = "14 марта, 02:00–04:00 МСК",
affected = DEFAULT_AFFECTED,
detailsLabel = "Что именно меняем",
detailsHref = "#",
className,
style,
...props
}: Alert017Props) {
return (
<>
<style href="vibeui-alert-017" precedence="medium">
{STYLES}
</style>
<div
{...props}
data-vibeui-block="alert-017"
role="status"
className={className}
style={style as CSSProperties}
>
<span data-part="mark" aria-hidden="true" />
<div data-part="text">
<span data-part="title">{title}</span>
{maintenanceWindow ? (
<span data-part="window">{maintenanceWindow}</span>
) : null}
{description ? (
<span data-part="description">{description}</span>
) : null}
{affected.length ? (
<ul>
{affected.map((item) => (
<li key={item}>{item}</li>
))}
</ul>
) : null}
{detailsLabel ? (
<a data-part="link" href={detailsHref}>
{detailsLabel}
</a>
) : null}
</div>
</div>
</>
)
}