Collaboration Pack
motiq/collaboration-packFreeBlock
The complete Collaboration Pack — installs the Collaborative Review Workspace block and its four components (Live Presence Stack, Activity Stream, Approval Workflow, Comment Thread) as editable source, deduping shared utilities.
Install it
npx shadcn@latest add https://www.motiq.dev/r/collaboration-pack.jsonSource
1"use client";23import * as React from "react";45import { cn } from "@/lib/utils";6import { getStatusMeta, statusVars } from "@/lib/motiq";78import {9 LivePresenceStack,10 type PresenceUser,11} from "@/components/motiq/live-presence-stack";12import {13 ApprovalWorkflow,14 type ApprovalWorkflowData,15 type ApprovalAction,16 type ActionContext,17 type ApprovalStatus,18 type Decision,19 type Reviewer,20 type WorkflowStage,21} from "@/components/motiq/approval-workflow";22import {23 CommentThread,24 type Comment,25 type CommentAuthor,26 type CommentDraft,27} from "@/components/motiq/comment-thread";28import {29 ActivityStream,30 type ActivityEvent,31 type ActivityActor,32} from "@/components/motiq/activity-stream";3334/* --------------------------------------------------------------------------35 * CollaborativeReviewWorkspace — a composed review surface that wires four36 * released collaboration components into one realistic screen: the presence of37 * who's here, an app-owned approval workflow as the main column, the discussion38 * thread under it, and an activity feed as the right rail.39 *40 * It owns a small in-memory demo state machine that connects the components'41 * callbacks: approving a stage advances the workflow AND appends an activity42 * event; posting a comment appears in the thread AND the activity; resolving the43 * discussion updates the thread AND records it. Preset buttons load the review44 * lifecycle states so you can see every phase without scripting.45 *46 * Presentation only — clearly fictional users, no real persistence or47 * authorization. In a real app you would replace the demo state with your own48 * data source and let these same callbacks drive real mutations. Clean-room49 * original.50 * ----------------------------------------------------------------------- */5152const MIN = 60_000;53const HOUR = 3_600_000;54const DAY = 86_400_000;55/** Fixed epoch anchoring the demo timeline for the first render (never Date.now56 * during render/init). Re-anchored to the real clock in a mount effect so the57 * relative timestamps read naturally. */58const T0 = 1_800_000_000_000;5960const VIEWER_ID = "you";6162/* -- fictional cast ------------------------------------------------------ */6364const PEOPLE = {65 you: { id: "you", name: "You" },66 mira: { id: "mira", name: "Mira Delacroix" },67 devon: { id: "devon", name: "Devon Achebe" },68 rosa: { id: "rosa", name: "Rosa Whitfield" },69 kai: { id: "kai", name: "Kai Ferreira" },70 june: { id: "june", name: "June Park" },71// … truncated
What it pulls in
npm packages
Other registry items
Files it writes
More from motiq
All 100 items| Component | Registry | Kind | Access | Installs | Command |
|---|---|---|---|---|---|
| Agent Operations Heroagent-operations-hero | motiq | Blocks | Free | 1 dep | |
| AI Agent Workspaceai-agent-workspace | motiq | Blocks | Free | 1 dep | |
| AI Interface Packai-interface-pack | motiq | Blocks | Free | 1 dep | |
| Collaborative Launch Herocollaborative-launch-hero | motiq | Blocks | Free | 1 dep | |
| Collaborative Review Workspacecollaborative-review-workspace | motiq | Blocks | Free | 1 dep | |
| Data Motion Packdata-motion-pack | motiq | Blocks | Free | 1 dep | |
| Deployment Command Centerdeployment-command-center | motiq | Blocks | Free | 1 dep | |
| Deployment Control Herodeployment-control-hero | motiq | Blocks | Free | 1 dep |
