Keep only example workflows in default/, move site-specific YAMLs to gitignored local/, remove the duplicate get-current-time plugin install, document personal plugins, clarify PM2 ecosystem usage, add shared Vitest and web ESLint, and extract OpsStatusCard for ops cards. Co-authored-by: Cursor <cursoragent@cursor.com>
47 lines
1.1 KiB
React
47 lines
1.1 KiB
React
import { LuCircleCheck, LuCircleX } from "react-icons/lu";
|
|
import { OpsStatusCard } from "./OpsStatusCard.jsx";
|
|
|
|
export function HttpProcessCard({
|
|
httpOnline,
|
|
onStart,
|
|
onStop,
|
|
startPending = false,
|
|
stopPending = false,
|
|
}) {
|
|
return (
|
|
<OpsStatusCard
|
|
title="HTTP process"
|
|
actions={
|
|
httpOnline ? (
|
|
<button
|
|
type="button"
|
|
className="btn btn-sm btn-warning"
|
|
disabled={stopPending}
|
|
onClick={onStop}
|
|
>
|
|
Stop HTTP
|
|
</button>
|
|
) : (
|
|
<button
|
|
type="button"
|
|
className="btn btn-sm btn-primary"
|
|
disabled={startPending}
|
|
onClick={onStart}
|
|
>
|
|
Start HTTP
|
|
</button>
|
|
)
|
|
}
|
|
>
|
|
<div className="flex items-center gap-2">
|
|
{httpOnline ? (
|
|
<LuCircleCheck className="size-6 text-success" aria-hidden />
|
|
) : (
|
|
<LuCircleX className="size-6 text-error" aria-hidden />
|
|
)}
|
|
<span>{httpOnline ? "Running" : "Stopped"}</span>
|
|
</div>
|
|
</OpsStatusCard>
|
|
);
|
|
}
|