LegalBody

A content layout organism for Terms of Service, Privacy Policy, and other legal documents. Provides consistent typography, optional table of contents sidebar, and print support.

Basic Legal Document

With Table of Contents

Usage Example

<x-interface-frameworks.legal-body
    title="Privacy Policy"
    lastUpdated="2024-01-15"
    version="1.0"
>
    <x-slot:toc>
        <a href="#section1">Section 1</a>
        <a href="#section2">Section 2</a>
    </x-slot:toc>

    <h2 id="section1">Section 1</h2>
    <p>Content...</p>
</x-interface-frameworks.legal-body>

Props

Prop Type Default Description
title string '' Document title
lastUpdated string|null null Date string (any parseable format)
version string|null null Document version number
showToc boolean true Show table of contents sidebar
class string '' Additional CSS classes

Slots

Slot Description
default Main legal content (HTML with h2, h3, p, ul, etc.)
toc Table of contents links

Accessibility Features

  • Uses semantic article element for document content
  • Table of contents navigation has aria-label
  • Heading hierarchy maintained (h1 > h2 > h3)
  • Links have proper anchor IDs for navigation
  • Print-friendly styles included