@datum-cloud/activity-ui 0.6.0-dev.5b51180 → 0.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@datum-cloud/activity-ui",
3
- "version": "0.6.0-dev.5b51180",
3
+ "version": "0.6.0",
4
4
  "description": "React components for Kubernetes Activity",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.esm.js",
@@ -1,15 +0,0 @@
1
- import type { Activity } from "../types/activity";
2
- export interface ActivityDigestSummaryProps {
3
- /** Activities currently loaded in the feed (the loaded page(s), not necessarily the full range) */
4
- activities: Activity[];
5
- /** Additional CSS class */
6
- className?: string;
7
- }
8
- /**
9
- * Thin stat strip summarizing the activities currently loaded in the feed —
10
- * e.g. "18 changes · 3 people · 1 system". Computed client-side over the
11
- * loaded/paginated activities; it is a quick-glance headline, not a
12
- * full-range aggregate (that would require a backend facet query).
13
- */
14
- export declare function ActivityDigestSummary({ activities, className }: ActivityDigestSummaryProps): import("react/jsx-runtime").JSX.Element | null;
15
- //# sourceMappingURL=ActivityDigestSummary.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ActivityDigestSummary.d.ts","sourceRoot":"","sources":["../../src/components/ActivityDigestSummary.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAElD,MAAM,WAAW,0BAA0B;IACzC,mGAAmG;IACnG,UAAU,EAAE,QAAQ,EAAE,CAAC;IACvB,2BAA2B;IAC3B,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED;;;;;GAKG;AACH,wBAAgB,qBAAqB,CAAC,EAAE,UAAU,EAAE,SAAc,EAAE,EAAE,0BAA0B,kDAgC/F"}
@@ -1,23 +0,0 @@
1
- import type { ResourceLinkResolver, TenantLinkResolver, TenantRenderer } from "../types/activity";
2
- import type { ActivityGroup } from "../lib/groupActivities";
3
- export interface ActivityFeedGroupItemProps {
4
- /** The group to render — a run of consecutive, same verb/kind/actor/tenant activities */
5
- group: ActivityGroup;
6
- resourceLinkResolver?: ResourceLinkResolver;
7
- tenantLinkResolver?: TenantLinkResolver;
8
- tenantRenderer?: TenantRenderer;
9
- onActorClick?: (actorName: string) => void;
10
- onActivityClick?: (activity: ActivityGroup["activities"][number]) => void;
11
- /** Whether this is the last group in the list (hides bottom border) */
12
- isLast?: boolean;
13
- }
14
- /**
15
- * ActivityFeedGroupItem renders a run of consecutive same verb/kind/actor
16
- * activities (see `groupActivities`) as a single collapsed row in the
17
- * "digest" timeline. A group of size 1 renders exactly like a normal
18
- * `ActivityFeedItem` — no visual change for ungrouped activities. Larger
19
- * groups render a synthesized summary ("{actor} created 12 DNS records")
20
- * that expands to reveal the individual activities underneath.
21
- */
22
- export declare function ActivityFeedGroupItem({ group, resourceLinkResolver, tenantLinkResolver, tenantRenderer, onActorClick, onActivityClick, isLast, }: ActivityFeedGroupItemProps): import("react/jsx-runtime").JSX.Element;
23
- //# sourceMappingURL=ActivityFeedGroupItem.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"ActivityFeedGroupItem.d.ts","sourceRoot":"","sources":["../../src/components/ActivityFeedGroupItem.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EACV,oBAAoB,EACpB,kBAAkB,EAClB,cAAc,EACf,MAAM,mBAAmB,CAAC;AAC3B,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAQ5D,MAAM,WAAW,0BAA0B;IACzC,yFAAyF;IACzF,KAAK,EAAE,aAAa,CAAC;IACrB,oBAAoB,CAAC,EAAE,oBAAoB,CAAC;IAC5C,kBAAkB,CAAC,EAAE,kBAAkB,CAAC;IACxC,cAAc,CAAC,EAAE,cAAc,CAAC;IAChC,YAAY,CAAC,EAAE,CAAC,SAAS,EAAE,MAAM,KAAK,IAAI,CAAC;IAC3C,eAAe,CAAC,EAAE,CAAC,QAAQ,EAAE,aAAa,CAAC,YAAY,CAAC,CAAC,MAAM,CAAC,KAAK,IAAI,CAAC;IAC1E,uEAAuE;IACvE,MAAM,CAAC,EAAE,OAAO,CAAC;CAClB;AAkBD;;;;;;;GAOG;AACH,wBAAgB,qBAAqB,CAAC,EACpC,KAAK,EACL,oBAAoB,EACpB,kBAAkB,EAClB,cAAc,EACd,YAAY,EACZ,eAAe,EACf,MAAc,GACf,EAAE,0BAA0B,2CA0G5B"}
@@ -1,40 +0,0 @@
1
- import type { Activity, Tenant } from '../types/activity';
2
- import { type NormalizedVerb } from './verb';
3
- /**
4
- * A run of consecutive activities that share a verb, resource kind, actor,
5
- * and tenant — e.g. a burst of DNS records created by the same controller
6
- * in one reconcile. A group of size 1 wraps a single ungrouped activity.
7
- */
8
- export interface ActivityGroup {
9
- key: string;
10
- verb: NormalizedVerb;
11
- kind: string;
12
- actorName: string;
13
- actorDisplayName?: string;
14
- tenant?: Tenant;
15
- activities: Activity[];
16
- count: number;
17
- /** Timestamp of the most recent activity in the group (activities are newest-first). */
18
- latestTimestamp?: string;
19
- }
20
- /**
21
- * Group consecutive activities that share verb + resource kind + actor +
22
- * tenant. Activities are assumed to already be sorted newest-first (as
23
- * returned by `useActivityFeed`); only adjacent items are merged, so a
24
- * burst of matching activities collapses into one group without needing
25
- * any time-window heuristics.
26
- */
27
- export declare function groupActivities(activities: Activity[]): ActivityGroup[];
28
- export interface ActivityDaySection {
29
- /** Day label, e.g. "Today", "Yesterday", or a formatted date */
30
- label: string;
31
- groups: ActivityGroup[];
32
- }
33
- /**
34
- * Bucket activities into calendar-day sections (Today / Yesterday / a
35
- * formatted date), then group consecutive matching activities within each
36
- * day. Bucketing by day first (rather than grouping across the whole list)
37
- * keeps a group from silently spanning a day boundary.
38
- */
39
- export declare function groupActivitiesByDay(activities: Activity[]): ActivityDaySection[];
40
- //# sourceMappingURL=groupActivities.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"groupActivities.d.ts","sourceRoot":"","sources":["../../src/lib/groupActivities.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAC1D,OAAO,EAA8B,KAAK,cAAc,EAAE,MAAM,QAAQ,CAAC;AAEzE;;;;GAIG;AACH,MAAM,WAAW,aAAa;IAC5B,GAAG,EAAE,MAAM,CAAC;IACZ,IAAI,EAAE,cAAc,CAAC;IACrB,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,EAAE,MAAM,CAAC;IAClB,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,UAAU,EAAE,QAAQ,EAAE,CAAC;IACvB,KAAK,EAAE,MAAM,CAAC;IACd,wFAAwF;IACxF,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B;AAaD;;;;;;GAMG;AACH,wBAAgB,eAAe,CAAC,UAAU,EAAE,QAAQ,EAAE,GAAG,aAAa,EAAE,CA4BvE;AAED,MAAM,WAAW,kBAAkB;IACjC,gEAAgE;IAChE,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,aAAa,EAAE,CAAC;CACzB;AAWD;;;;;GAKG;AACH,wBAAgB,oBAAoB,CAAC,UAAU,EAAE,QAAQ,EAAE,GAAG,kBAAkB,EAAE,CAwBjF"}
@@ -1,22 +0,0 @@
1
- import type { ElementType } from 'react';
2
- /**
3
- * Extract verb from activity summary (e.g., "alice created HTTPProxy" -> "created")
4
- */
5
- export declare function extractVerb(summary: string): string;
6
- export type NormalizedVerb = 'create' | 'update' | 'delete' | 'other';
7
- /**
8
- * Normalize a verb to a canonical form used for coloring/icons/grouping.
9
- */
10
- export declare function normalizeVerb(verb: string): NormalizedVerb;
11
- /**
12
- * Get icon container + icon color classes based on verb
13
- */
14
- export declare function getActionIconClasses(verb: string): {
15
- container: string;
16
- icon: string;
17
- };
18
- /**
19
- * Get the Lucide icon component for the timeline node based on verb
20
- */
21
- export declare function getTimelineIcon(verb: string): ElementType;
22
- //# sourceMappingURL=verb.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"verb.d.ts","sourceRoot":"","sources":["../../src/lib/verb.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,OAAO,CAAC;AAEzC;;GAEG;AACH,wBAAgB,WAAW,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,CAMnD;AAED,MAAM,MAAM,cAAc,GAAG,QAAQ,GAAG,QAAQ,GAAG,QAAQ,GAAG,OAAO,CAAC;AAEtE;;GAEG;AACH,wBAAgB,aAAa,CAAC,IAAI,EAAE,MAAM,GAAG,cAAc,CAa1D;AAED;;GAEG;AACH,wBAAgB,oBAAoB,CAAC,IAAI,EAAE,MAAM,GAAG;IAAE,SAAS,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAA;CAAE,CAwBtF;AAED;;GAEG;AACH,wBAAgB,eAAe,CAAC,IAAI,EAAE,MAAM,GAAG,WAAW,CAYzD"}