okami.mom/strata

git clone https://git.nkp.pet/okami.mom/strata

Niko1221Merge branch 'f-split-int' into f-split-vision7c5e84612

main
597 B11 linesraw
1import { tr } from '../lib/i18n';
2import { go, useLifecycle } from '../lib/store';
3import { Btn } from './ui';
4export function LifecycleNotice({ showScope = true }: {
5    showScope?: boolean;
6}) {
7    const status = useLifecycle();
8    if (!showScope && status.allowed)
9        return null;
10    return <div className="lifecycle-notice small muted">{tr(showScope ? <span>{tr("Global \u00B7 all chats")}</span> : null)}{tr(!status.allowed ? <><span role="status">{tr(status.reason)}</span><Btn size="sm" variant="ghost" onClick={() => go('serving')}>{tr("View requests")}</Btn></> : null)}</div>;
11}