UI/UX-Prototyp der Analytics-Dashboards in HiveGrid, fachlich auf einen SHK-/Handwerksbetrieb zugeschnitten. Ziel ist die Übergabe an die Entwicklung, nicht der Produktivbetrieb. Inhalt: sechs Seiten (Übersicht, Finanzen, Aufträge, Kunden, Team, Komponenten), 26 KPIs, neun Chart-Bausteine, Filtersystem mit seitenabhängiger Relevanz und ein deterministischer Demo-Datensatz (420 Kunden, 1.900 Aufträge, Stichtag 30.07.2026). Drei Quellen sind zusammengeführt: die fachliche Planung mit dem Branchenpartner (Januar 2026), die Subframe-Komponentenbibliothek aus dem HiveGrid-Pitch und IBM Carbon Data Visualization für die Diagrammregeln. Herkunft und bewusste Abweichungen stehen in docs/HERKUNFT.md. Dokumentation: README, HANDOVER (was echte Logik braucht), docs/DESIGN-SYSTEM, KPI-KATALOG, DATENMODELL, NAVIGATION, HERKUNFT, ZIELSYSTEM (Einbauort in HiveGrid Cloud) und LEITPLANKEN (welche Cloud-Screens als Vorbild taugen). Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01QPeZNwSeU7qG3RRCwaxEZX
77 lines
2.2 KiB
TypeScript
77 lines
2.2 KiB
TypeScript
"use client";
|
|
/*
|
|
* Documentation:
|
|
* Progress Circle — https://app.subframe.com/f023064a5ca0/library?component=Progress+Circle_91a72105-500a-46e2-997b-7e8cd29b5f81
|
|
*/
|
|
|
|
import React from "react";
|
|
import { FeatherAlertTriangle } from "@subframe/core";
|
|
import { FeatherCheck } from "@subframe/core";
|
|
import * as SubframeUtils from "../../utils";
|
|
|
|
export interface ProgressCircleRootProps
|
|
extends React.HTMLAttributes<HTMLDivElement> {
|
|
state?: "default" | "uploading" | "success" | "error";
|
|
value?: number;
|
|
statusText?: React.ReactNode;
|
|
className?: string;
|
|
}
|
|
|
|
const ProgressCircleRoot = React.forwardRef<
|
|
HTMLDivElement,
|
|
ProgressCircleRootProps
|
|
>(function ProgressCircleRoot(
|
|
{
|
|
state = "default",
|
|
value = 30,
|
|
statusText,
|
|
className,
|
|
...otherProps
|
|
}: ProgressCircleRootProps,
|
|
ref
|
|
) {
|
|
return (
|
|
<div
|
|
className={SubframeUtils.twClassNames(
|
|
"group/91a72105 flex h-14 w-14 items-center justify-center rounded-[9999px] border-2 border-solid border-border-default group/mtpcircle relative",
|
|
{
|
|
"border-2 border-solid border-border-negative-solid":
|
|
state === "error",
|
|
"border-2 border-solid border-border-positive-solid":
|
|
state === "success",
|
|
"border-2 border-solid border-brand-solid-default":
|
|
state === "uploading",
|
|
},
|
|
className
|
|
)}
|
|
ref={ref}
|
|
{...otherProps}
|
|
>
|
|
{statusText ? (
|
|
<div
|
|
className={SubframeUtils.twClassNames(
|
|
"flex items-center justify-center",
|
|
{ hidden: state === "error" || state === "success" }
|
|
)}
|
|
>
|
|
{statusText}
|
|
</div>
|
|
) : null}
|
|
<FeatherCheck
|
|
className={SubframeUtils.twClassNames(
|
|
"hidden font-['Instrument_Sans'] text-[24px] font-[500] leading-[24px] text-icon-feedback-positive",
|
|
{ "inline-flex": state === "success" }
|
|
)}
|
|
/>
|
|
<FeatherAlertTriangle
|
|
className={SubframeUtils.twClassNames(
|
|
"hidden font-['Instrument_Sans'] text-[24px] font-[500] leading-[24px] text-icon-feedback-negative",
|
|
{ "inline-flex": state === "error" }
|
|
)}
|
|
/>
|
|
</div>
|
|
);
|
|
});
|
|
|
|
export const ProgressCircle = ProgressCircleRoot;
|