{
  "$schema": "https://shadcn-vue.com/schema/registry-item.json",
  "name": "contract-redline-diff",
  "title": "Contract Redline Diff",
  "type": "registry:block",
  "files": [
    {
      "path": "packages/registry-vue/blocks/contract-redline-diff/ContractRedlineDiff.vue",
      "content": "<script setup lang=\"ts\">\nimport { computed, ref } from 'vue'\nimport type { HTMLAttributes } from 'vue'\nimport {\n  Check,\n  CheckCircle2,\n  Clock,\n  FileMinus2,\n  FilePlus2,\n  FileText,\n  History,\n  MessageSquare,\n  MessageSquareReply,\n  Scale,\n  Send,\n  X,\n  XCircle,\n} from 'lucide-vue-next'\nimport { cn } from '@/lib/utils'\nimport { Avatar, AvatarFallback } from '@/components/ui/avatar'\nimport { Badge } from '@/components/ui/badge'\nimport { Button } from '@/components/ui/button'\nimport { Card, CardContent, CardFooter, CardHeader, CardTitle } from '@/components/ui/card'\nimport { Separator } from '@/components/ui/separator'\n\nexport interface CommentItem {\n  id: string\n  clauseId: string\n  clauseTitle: string\n  authorName: string\n  authorRole: string\n  authorInitials: string\n  timestamp: string\n  commentText: string\n  proposedChange: string\n  status: 'pending' | 'resolved'\n  severity?: 'critical' | 'moderate' | 'standard'\n}\n\nexport interface RedlineStats {\n  additions: string\n  additionsSub: string\n  deletions: string\n  deletionsSub: string\n  openComments: number\n  resolvedComments: number\n  liabilityCap: string\n  liabilityCapSub: string\n}\n\nexport interface ContractRedlineDiffProps {\n  contractTitle?: string\n  counterparty?: string\n  counselFirm?: string\n  versionComparison?: string\n  initialStats?: RedlineStats\n  initialComments?: CommentItem[]\n  class?: HTMLAttributes['class']\n}\n\nconst props = withDefaults(defineProps<ContractRedlineDiffProps>(), {\n  contractTitle: 'Master Services Agreement · Redline Review v3.2 vs v3.1',\n  counterparty: 'Acme Enterprise Corp',\n  counselFirm: 'Davis Polk & Wardwell LLP',\n  versionComparison: 'v3.2 (Counterparty Redlines) vs v3.1 (Baseline Executed)',\n})\n\nconst defaultComments: CommentItem[] = [\n  {\n    id: 'c-1',\n    clauseId: 'clause-4-2',\n    clauseTitle: 'Section 4.2 · Service Level Agreement Credits',\n    authorName: 'Sarah Lin',\n    authorRole: 'Senior Counsel, Davis Polk & Wardwell LLP',\n    authorInitials: 'SL',\n    timestamp: '2 hours ago',\n    commentText:\n      'Acme enterprise infrastructure requires a 25% credit for downtime exceeding 4 hours given Tier-1 mission-critical workload dependency. We also propose extending the scheduled maintenance notice window to 7 business days.',\n    proposedChange: '25% monthly fee credit (was 10%) · 7 business days notice (was 48 hours)',\n    status: 'pending',\n    severity: 'critical',\n  },\n  {\n    id: 'c-2',\n    clauseId: 'clause-8-1',\n    clauseTitle: 'Section 8.1 · Limitation of Liability & Super-Cap',\n    authorName: 'Marcus Vance',\n    authorRole: 'VP Legal & AGC, Acme Enterprise Corp',\n    authorInitials: 'MV',\n    timestamp: '4 hours ago',\n    commentText:\n      'We cannot agree to a standard 12-month trailing fee liability cap due to GDPR Article 82 joint-controller exposure and confidential IP storage. A $2.5M aggregate super-cap is our committee floor for cloud vendor onboarding.',\n    proposedChange: 'Super-cap of $2,500,000 or 2.5x total contract value for data protection breaches',\n    status: 'pending',\n    severity: 'critical',\n  },\n  {\n    id: 'c-3',\n    clauseId: 'clause-12-3',\n    clauseTitle: 'Section 12.3 · Governing Law & Commercial Arbitration',\n    authorName: 'Elena Rostova',\n    authorRole: 'Partner, Technology Transactions Counsel',\n    authorInitials: 'ER',\n    timestamp: 'Yesterday at 17:45',\n    commentText:\n      'Replaced Delaware Chancery court litigation with AAA expedited commercial arbitration seated in New York to contain cross-border litigation exposure, expedite timeline, and guarantee reciprocal fee shifting.',\n    proposedChange: 'AAA Commercial Arbitration (New York, NY) + Prevailing party attorney fee shifting',\n    status: 'pending',\n    severity: 'moderate',\n  },\n  {\n    id: 'c-4',\n    clauseId: 'clause-2-4',\n    clauseTitle: 'Section 2.4 · Customer Data & AI Model Training',\n    authorName: 'David Kim',\n    authorRole: 'Lead In-House Commercial Counsel',\n    authorInitials: 'DK',\n    timestamp: 'Resolved 5 hours ago',\n    commentText:\n      'Provider confirmed in writing that customer telemetry is strictly quarantined and excluded from foundation LLM model training. Mutually agreed language inserted.',\n    proposedChange: 'Explicit carve-out prohibiting Customer Data ingestion into generative AI training sets',\n    status: 'resolved',\n    severity: 'standard',\n  },\n]\n\nconst comments = ref<CommentItem[]>(props.initialComments ? [...props.initialComments] : [...defaultComments])\nconst activeCommentId = ref<string>('c-1')\nconst selectedFilter = ref<'all' | 'pending' | 'resolved'>('all')\nconst replyingCommentId = ref<string | null>(null)\nconst replyDraftText = ref<string>('')\nconst actionBannerMessage = ref<string | null>(null)\n\nconst pendingCount = computed(() => comments.value.filter((c) => c.status === 'pending').length)\nconst resolvedCount = computed(() => comments.value.filter((c) => c.status === 'resolved').length)\n\nconst filteredComments = computed(() => {\n  if (selectedFilter.value === 'pending') {\n    return comments.value.filter((c) => c.status === 'pending')\n  }\n  if (selectedFilter.value === 'resolved') {\n    return comments.value.filter((c) => c.status === 'resolved')\n  }\n  return comments.value\n})\n\nfunction selectComment(id: string, clauseId?: string) {\n  activeCommentId.value = id\n  if (clauseId && typeof document !== 'undefined') {\n    const el = document.getElementById(clauseId)\n    if (el) {\n      el.scrollIntoView({ behavior: 'smooth', block: 'center' })\n    }\n  }\n}\n\nfunction toggleAcceptTweak(id: string) {\n  const comment = comments.value.find((c) => c.id === id)\n  if (comment) {\n    if (comment.status === 'pending') {\n      comment.status = 'resolved'\n      actionBannerMessage.value = `Accepted proposed language for \"${comment.clauseTitle}\"`\n    } else {\n      comment.status = 'pending'\n      actionBannerMessage.value = `Reopened review for \"${comment.clauseTitle}\"`\n    }\n  }\n}\n\nfunction handleAcceptAll() {\n  comments.value.forEach((c) => {\n    c.status = 'resolved'\n  })\n  actionBannerMessage.value = 'All 3 pending redlines and attorney comments have been accepted into draft v3.3'\n}\n\nfunction handleRejectAll() {\n  comments.value.forEach((c) => {\n    c.status = 'pending'\n  })\n  actionBannerMessage.value = 'Redline proposals flagged for revision. Counterparty notified of rejection.'\n}\n\nfunction toggleReply(id: string) {\n  if (replyingCommentId.value === id) {\n    replyingCommentId.value = null\n    replyDraftText.value = ''\n  } else {\n    replyingCommentId.value = id\n    replyDraftText.value = ''\n  }\n}\n\nfunction submitReply(id: string) {\n  if (!replyDraftText.value.trim()) return\n  actionBannerMessage.value = `Reply posted to counsel thread on ${comments.value.find((c) => c.id === id)?.clauseTitle}`\n  replyingCommentId.value = null\n  replyDraftText.value = ''\n}\n</script>\n\n<template>\n  <div data-slot=\"contract-redline-diff\" :class=\"cn('bg-background text-foreground w-full space-y-6', props.class)\">\n    <!-- Header Section -->\n    <header class=\"border-border bg-card rounded-xl border p-5 shadow-xs sm:p-6\">\n      <div class=\"flex flex-col gap-5 lg:flex-row lg:items-center lg:justify-between\">\n        <div class=\"space-y-2\">\n          <div class=\"flex flex-wrap items-center gap-2.5\">\n            <span class=\"text-muted-foreground font-mono text-xs tracking-wider uppercase\">\n              CLM Contract Workspace &bull; MSA-2026-0882\n            </span>\n            <Badge\n              v-if=\"pendingCount > 0\"\n              variant=\"outline\"\n              class=\"border-warning/30 bg-warning/10 text-warning font-mono text-xs font-semibold whitespace-normal\"\n            >\n              <span class=\"bg-warning mr-1.5 size-1.5 rounded-full\"></span>\n              {{ pendingCount }} Pending Redlines &bull; {{ resolvedCount }} Resolved\n            </Badge>\n            <Badge\n              wrap\n              v-else\n              variant=\"outline\"\n              class=\"border-success/30 bg-success/10 text-success font-mono text-xs font-semibold\"\n            >\n              <CheckCircle2 class=\"text-success mr-1 size-3\" aria-hidden=\"true\" />\n              All Changes Accepted &bull; Ready for Execution\n            </Badge>\n          </div>\n\n          <h1 class=\"text-foreground text-2xl font-bold tracking-tight sm:text-3xl\">\n            {{ props.contractTitle }}\n          </h1>\n\n          <div class=\"flex flex-wrap items-center gap-x-4 gap-y-1 text-xs sm:text-sm\">\n            <div class=\"text-muted-foreground flex items-center gap-1.5\">\n              <span class=\"text-foreground font-medium\">Counterparty:</span>\n              <span>{{ props.counterparty }}</span>\n            </div>\n            <span class=\"text-muted-foreground/40 hidden sm:inline\">&bull;</span>\n            <div class=\"text-muted-foreground flex items-center gap-1.5\">\n              <span class=\"text-foreground font-medium\">Outside Counsel:</span>\n              <span>{{ props.counselFirm }}</span>\n            </div>\n            <span class=\"text-muted-foreground/40 hidden sm:inline\">&bull;</span>\n            <div class=\"text-muted-foreground flex items-center gap-1.5\">\n              <History class=\"size-3.5\" aria-hidden=\"true\" />\n              <span>{{ props.versionComparison }}</span>\n            </div>\n          </div>\n        </div>\n\n        <!-- Header Action Controls -->\n        <div class=\"flex flex-wrap items-center gap-3\">\n          <Button variant=\"outline\" size=\"sm\" class=\"gap-1.5 text-xs font-medium\" @click=\"handleRejectAll\">\n            <XCircle class=\"text-muted-foreground size-4\" aria-hidden=\"true\" />\n            <span>Reject Changes</span>\n          </Button>\n\n          <Button variant=\"default\" size=\"sm\" class=\"gap-1.5 text-xs font-semibold shadow-xs\" @click=\"handleAcceptAll\">\n            <Check class=\"size-4\" aria-hidden=\"true\" />\n            <span>Accept All Changes</span>\n          </Button>\n        </div>\n      </div>\n\n      <!-- Action Feedback Banner -->\n      <div\n        v-if=\"actionBannerMessage\"\n        class=\"border-primary/20 bg-primary/5 mt-4 flex items-center justify-between rounded-lg border px-4 py-2.5 text-xs\"\n      >\n        <div class=\"text-foreground flex items-center gap-2 font-medium\">\n          <CheckCircle2 class=\"text-primary size-4 shrink-0\" aria-hidden=\"true\" />\n          <span>{{ actionBannerMessage }}</span>\n        </div>\n        <button\n          type=\"button\"\n          class=\"text-muted-foreground hover:text-foreground focus-visible:ring-ring rounded p-1 focus-visible:ring-2 focus-visible:outline-none\"\n          @click=\"actionBannerMessage = null\"\n          aria-label=\"Dismiss notification\"\n        >\n          <X class=\"size-3.5\" />\n        </button>\n      </div>\n    </header>\n\n    <!-- 4 Redline Summary Metric Cards -->\n    <section aria-label=\"Redline metrics overview\" class=\"grid grid-cols-1 gap-4 sm:grid-cols-2 lg:grid-cols-4\">\n      <!-- Metric 1: Additions / Insertions -->\n      <Card class=\"border-border bg-card shadow-xs\">\n        <CardHeader class=\"p-4 pb-2\">\n          <div class=\"flex items-center justify-between\">\n            <CardTitle class=\"text-muted-foreground text-xs font-medium tracking-wider uppercase\">\n              Additions / Insertions\n            </CardTitle>\n            <div class=\"bg-success/10 text-success rounded-md p-1.5\">\n              <FilePlus2 class=\"size-4\" aria-hidden=\"true\" />\n            </div>\n          </div>\n        </CardHeader>\n        <CardContent class=\"space-y-1 p-4 pt-0\">\n          <p class=\"text-success font-mono text-2xl font-bold tracking-tight\">+14 Clauses / Sentences</p>\n          <p class=\"text-muted-foreground text-xs leading-relaxed\">\n            +620 words &bull; Enhanced SLA credits, audit rights &amp; ML carve-outs\n          </p>\n        </CardContent>\n      </Card>\n\n      <!-- Metric 2: Deletions / Removals -->\n      <Card class=\"border-border bg-card shadow-xs\">\n        <CardHeader class=\"p-4 pb-2\">\n          <div class=\"flex items-center justify-between\">\n            <CardTitle class=\"text-muted-foreground text-xs font-medium tracking-wider uppercase\">\n              Deletions / Removals\n            </CardTitle>\n            <div class=\"bg-destructive/10 text-destructive rounded-md p-1.5\">\n              <FileMinus2 class=\"size-4\" aria-hidden=\"true\" />\n            </div>\n          </div>\n        </CardHeader>\n        <CardContent class=\"space-y-1 p-4 pt-0\">\n          <p class=\"text-destructive font-mono text-2xl font-bold tracking-tight\">-8 Clauses Struck Through</p>\n          <p class=\"text-muted-foreground text-xs leading-relaxed\">\n            -310 words &bull; Excised unilateral termination &amp; uncapped liability\n          </p>\n        </CardContent>\n      </Card>\n\n      <!-- Metric 3: Pending Review Comments -->\n      <Card class=\"border-border bg-card shadow-xs\">\n        <CardHeader class=\"p-4 pb-2\">\n          <div class=\"flex items-center justify-between\">\n            <CardTitle class=\"text-muted-foreground text-xs font-medium tracking-wider uppercase\">\n              Review Comments\n            </CardTitle>\n            <div class=\"bg-warning/10 text-warning rounded-md p-1.5\">\n              <MessageSquare class=\"size-4\" aria-hidden=\"true\" />\n            </div>\n          </div>\n        </CardHeader>\n        <CardContent class=\"space-y-1 p-4 pt-0\">\n          <p class=\"text-warning font-mono text-2xl font-bold tracking-tight\">\n            {{ pendingCount }} Open Counsel Comments\n          </p>\n          <p class=\"text-muted-foreground text-xs leading-relaxed\">\n            {{ resolvedCount }} resolved &bull; 2 require General Counsel sign-off\n          </p>\n        </CardContent>\n      </Card>\n\n      <!-- Metric 4: Liability Cap Shift -->\n      <Card class=\"border-border bg-card shadow-xs\">\n        <CardHeader class=\"p-4 pb-2\">\n          <div class=\"flex items-center justify-between\">\n            <CardTitle class=\"text-muted-foreground text-xs font-medium tracking-wider uppercase\">\n              Liability Cap Shift\n            </CardTitle>\n            <div class=\"bg-primary/10 text-primary rounded-md p-1.5\">\n              <Scale class=\"size-4\" aria-hidden=\"true\" />\n            </div>\n          </div>\n        </CardHeader>\n        <CardContent class=\"space-y-1 p-4 pt-0\">\n          <p class=\"text-primary font-mono text-2xl font-bold tracking-tight\">$1.0M &rarr; $2.5M Super-Cap</p>\n          <p class=\"text-muted-foreground text-xs leading-relaxed\">\n            Shifted from 1x annual fees to 2.5x aggregate contract liability\n          </p>\n        </CardContent>\n      </Card>\n    </section>\n\n    <!-- 2-Column Redline Workspace -->\n    <div class=\"grid grid-cols-1 gap-6 lg:grid-cols-12 lg:items-start\">\n      <!-- Left Column: Redlined Document Prose -->\n      <main class=\"space-y-6 lg:col-span-8\">\n        <div class=\"border-border bg-card rounded-xl border shadow-xs\">\n          <!-- Document Controls & Legend Top Bar -->\n          <div class=\"border-border bg-muted/40 flex flex-wrap items-center justify-between gap-3 border-b px-5 py-3.5\">\n            <div class=\"flex items-center gap-2\">\n              <FileText class=\"text-primary size-4\" aria-hidden=\"true\" />\n              <span class=\"text-foreground text-xs font-semibold sm:text-sm\">\n                Master Services Agreement (MSA) &bull; Draft v3.2\n              </span>\n            </div>\n\n            <!-- Visual Legend -->\n            <div class=\"flex flex-wrap items-center gap-3 text-xs\">\n              <div class=\"flex items-center gap-1.5\">\n                <span class=\"border-success/30 bg-success/20 inline-block h-3 w-5 rounded border\"></span>\n                <span class=\"text-muted-foreground\">Insertion (Acme Counsel)</span>\n              </div>\n              <div class=\"flex items-center gap-1.5\">\n                <span class=\"border-destructive/30 bg-destructive/20 inline-block h-3 w-5 rounded border\"></span>\n                <span class=\"text-muted-foreground\">Deletion (Struck Out)</span>\n              </div>\n            </div>\n          </div>\n\n          <!-- Document Content Body -->\n          <div class=\"divide-border space-y-8 divide-y px-5 py-6 sm:px-8\">\n            <!-- Section 2: Intellectual Property & Data Ownership -->\n            <section id=\"clause-2-4\" class=\"scroll-mt-6 space-y-3 pt-6 first:pt-0\">\n              <div class=\"flex flex-wrap items-center justify-between gap-2\">\n                <div class=\"flex items-center gap-2\">\n                  <h2 class=\"text-foreground text-sm font-bold tracking-tight sm:text-base\">\n                    Section 2 &bull; Intellectual Property &amp; Customer Data\n                  </h2>\n                  <Badge wrap variant=\"outline\" class=\"border-success/30 bg-success/10 text-success font-mono text-xs\">\n                    [RESOLVED] &bull; § 2.4 ML Carve-out\n                  </Badge>\n                </div>\n                <Button\n                  variant=\"ghost\"\n                  size=\"sm\"\n                  class=\"text-muted-foreground hover:text-foreground h-7 gap-1 px-2 text-xs\"\n                  @click=\"selectComment('c-4', 'clause-2-4')\"\n                >\n                  <MessageSquare class=\"text-success size-3.5\" />\n                  <span>View Resolution</span>\n                </Button>\n              </div>\n\n              <div class=\"border-border bg-muted/20 space-y-3 rounded-lg border p-4 text-xs leading-relaxed sm:text-sm\">\n                <p class=\"text-foreground\">\n                  <strong class=\"text-foreground font-semibold\">2.4 Proprietary Rights &amp; Restrictions.</strong>\n                  Customer retains all right, title, and interest in and to Customer Data, including all Intellectual\n                  Property Rights therein. Provider shall not acquire any ownership interest in or rights to Customer\n                  Data, except for the limited license granted herein to perform the Services.\n                  <span\n                    class=\"bg-success/10 text-success text-success rounded px-1 py-0.5 font-medium underline decoration-emerald-500/40\"\n                  >\n                    Under no circumstances shall Provider utilize, parse, vectorize, or ingest Customer Data,\n                    confidential telemetry, or user communications to train, fine-tune, or benchmark any public or\n                    proprietary artificial intelligence, large language, or algorithmic model without express prior\n                    written addendum.\n                  </span>\n                </p>\n              </div>\n            </section>\n\n            <!-- Section 4: Service Level Agreements -->\n            <section id=\"clause-4-2\" class=\"scroll-mt-6 space-y-3 pt-8\">\n              <div class=\"flex flex-wrap items-center justify-between gap-2\">\n                <div class=\"flex items-center gap-2\">\n                  <h2 class=\"text-foreground text-sm font-bold tracking-tight sm:text-base\">\n                    Section 4 &bull; Service Level Agreements &amp; Availability Commitments\n                  </h2>\n                  <Badge wrap variant=\"outline\" class=\"border-warning/30 bg-warning/10 text-warning font-mono text-xs\">\n                    [DIFF-4.2] &bull; 2 Pending Redlines\n                  </Badge>\n                </div>\n                <Button\n                  variant=\"outline\"\n                  size=\"sm\"\n                  :class=\"\n                    cn(\n                      'h-7 gap-1.5 px-2.5 text-xs',\n                      activeCommentId === 'c-1'\n                        ? 'border-primary bg-primary/10 text-primary font-semibold'\n                        : 'text-muted-foreground',\n                    )\n                  \"\n                  @click=\"selectComment('c-1', 'clause-4-2')\"\n                >\n                  <MessageSquare class=\"text-warning size-3.5\" />\n                  <span>Comment #1 &bull; Sarah Lin</span>\n                </Button>\n              </div>\n\n              <div\n                :class=\"\n                  cn(\n                    'border-border bg-card space-y-4 rounded-lg border p-4 text-xs leading-relaxed transition-colors sm:p-5 sm:text-sm',\n                    activeCommentId === 'c-1' ? 'ring-primary/40 ring-2' : '',\n                  )\n                \"\n              >\n                <p class=\"text-foreground\">\n                  <strong class=\"text-foreground font-semibold\">4.1 Monthly Uptime Commitment.</strong>\n                  Provider warrants that the Production Cloud Service will achieve a Monthly Uptime Percentage of no\n                  less than\n                  <span\n                    class=\"bg-destructive/10 text-destructive text-destructive rounded px-1 py-0.5 font-medium line-through decoration-rose-500/60\"\n                  >\n                    ninety-nine and one-half percent (99.5%)\n                  </span>\n                  <span\n                    class=\"bg-success/10 text-success text-success rounded px-1 py-0.5 font-medium underline decoration-emerald-500/40\"\n                  >\n                    ninety-nine and ninety-five hundredths percent (99.95%)\n                  </span>\n                  during each calendar billing month of the applicable Order Term (&ldquo;Service Level\n                  Standard&rdquo;).\n                </p>\n\n                <p class=\"text-foreground\">\n                  <strong class=\"text-foreground font-semibold\"\n                    >4.2 SLA Failure Remedies &amp; Maintenance Notice.</strong\n                  >\n                  If Provider fails to meet the Service Level Standard for any calendar month, Customer shall be\n                  entitled to an immediate credit against future invoices equal to\n                  <span\n                    class=\"bg-destructive/10 text-destructive text-destructive rounded px-1 py-0.5 font-medium line-through decoration-rose-500/60\"\n                  >\n                    ten percent (10%)\n                  </span>\n                  <span\n                    class=\"bg-success/10 text-success text-success rounded px-1 py-0.5 font-medium underline decoration-emerald-500/40\"\n                  >\n                    twenty-five percent (25%)\n                  </span>\n                  of the prorated monthly fees for such month. Scheduled Maintenance windows shall occur solely between\n                  01:00 and 04:00 UTC on Sunday mornings and require no less than\n                  <span\n                    class=\"bg-destructive/10 text-destructive text-destructive rounded px-1 py-0.5 font-medium line-through decoration-rose-500/60\"\n                  >\n                    forty-eight (48) hours\n                  </span>\n                  <span\n                    class=\"bg-success/10 text-success text-success rounded px-1 py-0.5 font-medium underline decoration-emerald-500/40\"\n                  >\n                    seven (7) business days\n                  </span>\n                  advance electronic notice to Customer&rsquo;s Lead SRE contact.\n                </p>\n              </div>\n            </section>\n\n            <!-- Section 8: Limitation of Liability -->\n            <section id=\"clause-8-1\" class=\"scroll-mt-6 space-y-3 pt-8\">\n              <div class=\"flex flex-wrap items-center justify-between gap-2\">\n                <div class=\"flex items-center gap-2\">\n                  <h2 class=\"text-foreground text-sm font-bold tracking-tight sm:text-base\">\n                    Section 8 &bull; Limitation of Liability &amp; Super-Cap Allocation\n                  </h2>\n                  <Badge\n                    wrap\n                    variant=\"outline\"\n                    class=\"border-destructive/30 bg-destructive/10 text-destructive font-mono text-xs font-semibold\"\n                  >\n                    [DIFF-8.1] &bull; HIGH IMPACT SHIFT\n                  </Badge>\n                </div>\n                <Button\n                  variant=\"outline\"\n                  size=\"sm\"\n                  :class=\"\n                    cn(\n                      'h-7 gap-1.5 px-2.5 text-xs',\n                      activeCommentId === 'c-2'\n                        ? 'border-primary bg-primary/10 text-primary font-semibold'\n                        : 'text-muted-foreground',\n                    )\n                  \"\n                  @click=\"selectComment('c-2', 'clause-8-1')\"\n                >\n                  <MessageSquare class=\"text-destructive size-3.5\" />\n                  <span>Comment #2 &bull; Marcus Vance</span>\n                </Button>\n              </div>\n\n              <div\n                :class=\"\n                  cn(\n                    'border-border bg-card space-y-4 rounded-lg border p-4 text-xs leading-relaxed transition-colors sm:p-5 sm:text-sm',\n                    activeCommentId === 'c-2' ? 'ring-primary/40 ring-2' : '',\n                  )\n                \"\n              >\n                <p class=\"text-foreground font-mono text-xs leading-relaxed uppercase\">\n                  <strong class=\"text-foreground font-bold\">8.1 AGGREGATE LIABILITY CAP.</strong>\n                  EXCEPT FOR LIABILITIES ARISING FROM A BREACH OF CONFIDENTIALITY UNDER SECTION 6, FRAUD, OR\n                  INDEMNIFICATION OBLIGATIONS UNDER SECTION 10, NEITHER PARTY&rsquo;S MAXIMUM AGGREGATE LIABILITY UNDER\n                  THIS AGREEMENT SHALL EXCEED\n                  <span\n                    class=\"bg-destructive/10 text-destructive text-destructive rounded px-1 py-0.5 font-medium line-through decoration-rose-500/60\"\n                  >\n                    THE TOTAL FEES ACTUALLY PAID BY CUSTOMER TO PROVIDER IN THE TWELVE (12) MONTHS PRECEDING THE EVENT\n                    GIVING RISE TO LIABILITY.\n                  </span>\n                  <span\n                    class=\"bg-success/10 text-success text-success rounded px-1 py-0.5 font-medium underline decoration-emerald-500/40\"\n                  >\n                    THE GREATER OF TWO MILLION FIVE HUNDRED THOUSAND UNITED STATES DOLLARS ($2,500,000 USD) OR TWO AND\n                    ONE-HALF TIMES (2.5X) THE AGGREGATE FEES PAYABLE OVER THE ENTIRE ORDER FORM DURATION\n                    (&ldquo;SUPER-CAP&rdquo;).\n                  </span>\n                </p>\n\n                <p class=\"text-foreground\">\n                  <strong class=\"text-foreground font-semibold\">8.2 Direct Damages Carve-Out.</strong>\n                  Notwithstanding anything to the contrary, the mutual waiver of consequential damages in Section 8.3\n                  shall not preclude or limit recovery of\n                  <span\n                    class=\"bg-success/10 text-success text-success rounded px-1 py-0.5 font-medium underline decoration-emerald-500/40\"\n                  >\n                    reasonable third-party forensic incident investigation expenses, statutory breach notification\n                    mailings, and credit monitoring services required under GDPR, HIPAA, or State Data Privacy laws.\n                  </span>\n                </p>\n              </div>\n            </section>\n\n            <!-- Section 12: Governing Law & Arbitration -->\n            <section id=\"clause-12-3\" class=\"scroll-mt-6 space-y-3 pt-8\">\n              <div class=\"flex flex-wrap items-center justify-between gap-2\">\n                <div class=\"flex items-center gap-2\">\n                  <h2 class=\"text-foreground text-sm font-bold tracking-tight sm:text-base\">\n                    Section 12 &bull; Governing Law, Venue &amp; Arbitration\n                  </h2>\n                  <Badge wrap variant=\"outline\" class=\"border-primary/30 bg-primary/10 text-primary font-mono text-xs\">\n                    [DIFF-12.3] &bull; Modified Venue\n                  </Badge>\n                </div>\n                <Button\n                  variant=\"outline\"\n                  size=\"sm\"\n                  :class=\"\n                    cn(\n                      'h-7 gap-1.5 px-2.5 text-xs',\n                      activeCommentId === 'c-3'\n                        ? 'border-primary bg-primary/10 text-primary font-semibold'\n                        : 'text-muted-foreground',\n                    )\n                  \"\n                  @click=\"selectComment('c-3', 'clause-12-3')\"\n                >\n                  <MessageSquare class=\"text-primary size-3.5\" />\n                  <span>Comment #3 &bull; Elena Rostova</span>\n                </Button>\n              </div>\n\n              <div\n                :class=\"\n                  cn(\n                    'border-border bg-card space-y-4 rounded-lg border p-4 text-xs leading-relaxed transition-colors sm:p-5 sm:text-sm',\n                    activeCommentId === 'c-3' ? 'ring-primary/40 ring-2' : '',\n                  )\n                \"\n              >\n                <p class=\"text-foreground\">\n                  <strong class=\"text-foreground font-semibold\">12.1 Applicable Law.</strong>\n                  This Agreement shall be governed by, construed, and enforced in accordance with the substantive laws\n                  of the State of Delaware, without reference to its conflict-of-law principles.\n                </p>\n\n                <p class=\"text-foreground\">\n                  <strong class=\"text-foreground font-semibold\"\n                    >12.3 Binding Commercial Arbitration &amp; Fee Recovery.</strong\n                  >\n                  Any controversy, dispute, or claim arising out of or relating to this Agreement, or the breach\n                  thereof, shall be resolved by\n                  <span\n                    class=\"bg-destructive/10 text-destructive text-destructive rounded px-1 py-0.5 font-medium line-through decoration-rose-500/60\"\n                  >\n                    the state or federal courts situated in Wilmington, Delaware.\n                  </span>\n                  <span\n                    class=\"bg-success/10 text-success text-success rounded px-1 py-0.5 font-medium underline decoration-emerald-500/40\"\n                  >\n                    binding arbitration administered by the American Arbitration Association (AAA) in accordance with\n                    its Commercial Arbitration Rules, before a single neutral arbitrator seated in the City and State of\n                    New York.\n                  </span>\n                  <span\n                    class=\"bg-success/10 text-success text-success rounded px-1 py-0.5 font-medium underline decoration-emerald-500/40\"\n                  >\n                    The prevailing party in any proceeding to enforce or interpret this Agreement shall be entitled to\n                    recover from the non-prevailing party all reasonable attorneys&rsquo; fees, arbitrator compensation,\n                    and expert witness disbursements incurred in connection therewith.\n                  </span>\n                </p>\n              </div>\n            </section>\n          </div>\n        </div>\n      </main>\n\n      <!-- Right Column: Attorney Comments & Negotiations Sidebar -->\n      <aside class=\"space-y-4 lg:sticky lg:top-6 lg:col-span-4\">\n        <div class=\"border-border bg-card space-y-4 rounded-xl border p-4 shadow-xs\">\n          <!-- Sidebar Header -->\n          <div class=\"flex items-center justify-between pb-1\">\n            <div class=\"flex items-center gap-2\">\n              <MessageSquare class=\"text-primary size-4\" aria-hidden=\"true\" />\n              <h2 class=\"text-foreground text-sm font-bold tracking-tight\">Counsel Comments &amp; Markups</h2>\n            </div>\n            <span class=\"text-muted-foreground font-mono text-xs font-medium\">\n              {{ filteredComments.length }} items\n            </span>\n          </div>\n\n          <!-- Filter Pills -->\n          <div class=\"bg-muted/60 flex items-center gap-1.5 rounded-lg p-1\">\n            <button\n              type=\"button\"\n              :class=\"\n                cn(\n                  'focus-visible:ring-ring flex-1 rounded-md px-2 py-1 text-xs font-medium transition-colors focus-visible:ring-2 focus-visible:outline-none',\n                  selectedFilter === 'all'\n                    ? 'bg-background text-foreground font-semibold shadow-xs'\n                    : 'text-muted-foreground hover:text-foreground',\n                )\n              \"\n              @click=\"selectedFilter = 'all'\"\n            >\n              All ({{ comments.length }})\n            </button>\n            <button\n              type=\"button\"\n              :class=\"\n                cn(\n                  'focus-visible:ring-ring flex-1 rounded-md px-2 py-1 text-xs font-medium transition-colors focus-visible:ring-2 focus-visible:outline-none',\n                  selectedFilter === 'pending'\n                    ? 'bg-background text-foreground font-semibold shadow-xs'\n                    : 'text-muted-foreground hover:text-foreground',\n                )\n              \"\n              @click=\"selectedFilter = 'pending'\"\n            >\n              Pending ({{ pendingCount }})\n            </button>\n            <button\n              type=\"button\"\n              :class=\"\n                cn(\n                  'focus-visible:ring-ring flex-1 rounded-md px-2 py-1 text-xs font-medium transition-colors focus-visible:ring-2 focus-visible:outline-none',\n                  selectedFilter === 'resolved'\n                    ? 'bg-background text-foreground font-semibold shadow-xs'\n                    : 'text-muted-foreground hover:text-foreground',\n                )\n              \"\n              @click=\"selectedFilter = 'resolved'\"\n            >\n              Resolved ({{ resolvedCount }})\n            </button>\n          </div>\n\n          <Separator />\n\n          <!-- Comments Feed -->\n          <div class=\"space-y-3.5\">\n            <Card\n              v-for=\"comment in filteredComments\"\n              :key=\"comment.id\"\n              role=\"button\"\n              tabindex=\"0\"\n              :aria-pressed=\"activeCommentId === comment.id\"\n              :class=\"\n                cn(\n                  'border-border hover:border-primary/40 focus-visible:ring-ring cursor-pointer transition-colors focus-visible:ring-2 focus-visible:outline-none',\n                  activeCommentId === comment.id ? 'border-primary/60 bg-muted/20 ring-primary/30 ring-1' : 'bg-card',\n                  comment.status === 'resolved' ? 'opacity-75' : '',\n                )\n              \"\n              @click=\"selectComment(comment.id, comment.clauseId)\"\n              @keydown.enter=\"selectComment(comment.id, comment.clauseId)\"\n              @keydown.space.prevent=\"selectComment(comment.id, comment.clauseId)\"\n            >\n              <CardHeader class=\"p-3.5 pb-2\">\n                <div class=\"flex flex-wrap items-start justify-between gap-2\">\n                  <div class=\"flex items-center gap-2.5\">\n                    <Avatar class=\"border-border size-7 border\">\n                      <AvatarFallback class=\"bg-primary/10 text-primary font-mono text-xs font-bold\">\n                        {{ comment.authorInitials }}\n                      </AvatarFallback>\n                    </Avatar>\n                    <div>\n                      <p class=\"text-foreground text-xs leading-none font-semibold\">\n                        {{ comment.authorName }}\n                      </p>\n                      <p class=\"text-muted-foreground mt-0.5 max-w-[170px] truncate text-xs\">\n                        {{ comment.authorRole }}\n                      </p>\n                    </div>\n                  </div>\n\n                  <Badge\n                    wrap\n                    variant=\"outline\"\n                    :class=\"\n                      cn(\n                        'shrink-0 font-mono text-xs',\n                        comment.status === 'resolved'\n                          ? 'border-success/30 bg-success/10 text-success'\n                          : 'border-warning/30 bg-warning/10 text-warning',\n                      )\n                    \"\n                  >\n                    {{ comment.status === 'resolved' ? 'Resolved' : 'Pending' }}\n                  </Badge>\n                </div>\n              </CardHeader>\n\n              <CardContent class=\"space-y-2.5 p-3.5 pt-0 text-xs\">\n                <!-- Clause context pill -->\n                <div class=\"bg-muted/50 text-muted-foreground rounded px-2 py-1 font-mono text-xs\">\n                  {{ comment.clauseTitle }}\n                </div>\n\n                <!-- Comment narrative -->\n                <p class=\"text-foreground leading-relaxed\">&ldquo;{{ comment.commentText }}&rdquo;</p>\n\n                <!-- Proposed change box -->\n                <div class=\"border-success/20 bg-success/5 rounded border p-2 text-xs\">\n                  <span class=\"text-success mb-0.5 block font-semibold\"> Proposed Redline Tweak: </span>\n                  <span class=\"text-muted-foreground\">\n                    {{ comment.proposedChange }}\n                  </span>\n                </div>\n\n                <div class=\"text-muted-foreground flex items-center justify-between pt-1 text-xs\">\n                  <span class=\"flex items-center gap-1\">\n                    <Clock class=\"size-3\" aria-hidden=\"true\" />\n                    {{ comment.timestamp }}\n                  </span>\n                </div>\n              </CardContent>\n\n              <CardFooter class=\"border-border bg-muted/10 flex items-center justify-between gap-2 border-t p-2.5\">\n                <Button variant=\"outline\" size=\"sm\" class=\"h-7 gap-1 text-xs\" @click.stop=\"toggleReply(comment.id)\">\n                  <MessageSquareReply class=\"text-muted-foreground size-3\" aria-hidden=\"true\" />\n                  <span>Reply</span>\n                </Button>\n\n                <Button\n                  :variant=\"comment.status === 'resolved' ? 'outline' : 'default'\"\n                  size=\"sm\"\n                  :class=\"\n                    cn('h-7 gap-1 text-xs', comment.status === 'resolved' ? 'text-muted-foreground' : 'font-medium')\n                  \"\n                  @click.stop=\"toggleAcceptTweak(comment.id)\"\n                >\n                  <Check class=\"size-3\" aria-hidden=\"true\" />\n                  <span>{{ comment.status === 'resolved' ? 'Reopen' : 'Accept Tweak' }}</span>\n                </Button>\n              </CardFooter>\n\n              <!-- Inline Thread Reply Input -->\n              <div\n                v-if=\"replyingCommentId === comment.id\"\n                class=\"border-border bg-background space-y-2 border-t p-3\"\n                @click.stop\n              >\n                <textarea\n                  v-model=\"replyDraftText\"\n                  placeholder=\"Draft reply to counsel thread...\"\n                  class=\"border-border bg-card placeholder:text-muted-foreground focus-visible:ring-ring w-full resize-none rounded-md border p-2 text-xs focus-visible:ring-2 focus-visible:outline-none\"\n                  rows=\"2\"\n                ></textarea>\n                <div class=\"flex items-center justify-end gap-2\">\n                  <Button variant=\"ghost\" size=\"sm\" class=\"h-6 px-2 text-xs\" @click=\"replyingCommentId = null\">\n                    Cancel\n                  </Button>\n                  <Button\n                    variant=\"default\"\n                    size=\"sm\"\n                    class=\"h-6 gap-1 px-2.5 text-xs font-semibold\"\n                    @click=\"submitReply(comment.id)\"\n                  >\n                    <Send class=\"size-3\" aria-hidden=\"true\" />\n                    <span>Send</span>\n                  </Button>\n                </div>\n              </div>\n            </Card>\n          </div>\n        </div>\n      </aside>\n    </div>\n  </div>\n</template>\n",
      "type": "registry:block",
      "target": "~/app/components/blocks/ContractRedlineDiff.vue"
    }
  ],
  "dependencies": [
    "lucide-vue-next"
  ],
  "devDependencies": [],
  "registryDependencies": [
    "https://uipkge.dev/r/vue/avatar.json",
    "https://uipkge.dev/r/vue/badge.json",
    "https://uipkge.dev/r/vue/button.json",
    "https://uipkge.dev/r/vue/card.json",
    "https://uipkge.dev/r/vue/separator.json"
  ],
  "description": "Ironclad and DocuSign CLM style legal contract redline diff viewer with clause additions, deletions, liability super-cap shift analysis, and attorney comments negotiations sidebar.",
  "categories": [
    "legal",
    "app",
    "management"
  ]
}