"use client"; import { useMemo, useState } from "react"; import Link from "next/link"; // ---------- Types ---------- export type CarePlan = { id: string; name: string; bestFor: string; monthlyPrice: number; yearlyDiscount: number; // 0.1 = 10% outcomes: readonly string[]; inclusions: readonly string[]; sla: string; cta: { label: string; href: string }; popular?: boolean; contactOnly?: boolean; }; export type VPSPlan = { id: "solo" | "team" | "dedicated"; name: string; price: number | null; // null = custom specs: string; bestFor: string; }; export type MCPlan = { id: "starter" | "pro" | "network"; name: string; price: number | null; specs: string; typical: string; features: readonly string[]; }; // ---------- Main Component ---------- export default function PricingConfigurator({ carePlans, vpsPlans, minecraftPlans, }: { carePlans: readonly CarePlan[]; vpsPlans: readonly VPSPlan[]; minecraftPlans: readonly MCPlan[]; }) { const [tab, setTab] = useState<"care" | "vps" | "mc">("care"); const [billing, setBilling] = useState<"monthly" | "yearly">("monthly"); const [vpsOwnership, setVpsOwnership] = useState<"managed" | "owned">("managed"); return (
{ownership === "managed" ? "We host & bill the VPS on our platform. Management included." : "Provisioned into your cloud account via secure connect. You retain ownership."}
Backups with restore tests, tuning & monitoring included. Networks & modpacks may require custom sizing.