# Page Break

Forces a page break in the document.

> For the complete documentation index, see [llms.txt](/llms.txt). Markdown variants are available by appending `.md` to any docs URL. An agent skill is available at [/.well-known/agent-skills/site-skill.md](/.well-known/agent-skills/site-skill.md).

## Installation

```bash
npx shadcn@latest add @angular-pdfcn/takumi/page-break
```

To install manually, add the dependencies:

```bash
npm install takumi-pdf @takumi-rs/helpers
```

Then copy these files into your project and update the import paths to match your setup:

- `components/pdf/page-break/page-break.ts`
- `lib/resolve-color.ts`
- `components/pdf/theme-provider.ts`
- `lib/pdf-renderer.ts`
- `lib/pdf-primitives.ts`
- `lib/render.ts`
- `lib/pdf-themes/professional.ts`
- `lib/pdf-themes/primitives.ts`
- `types/pdf-themes.ts`
- `types/pdf-components.ts`

## Usage

```ts
import { Component } from "@angular/core";

import { PdfHeading } from "@/components/pdf/heading/heading";
import { PdfPageBreak } from "@/components/pdf/page-break/page-break";
import { PdfText } from "@/components/pdf/text/text";
import { PdfcnThemeProvider } from "@/components/pdf/theme-provider";
import {
  TakumiDocument,
  TakumiPage,
  TakumiView,
} from "@/lib/pdf-primitives";

@Component({
  imports: [
    TakumiDocument,
    TakumiPage,
    TakumiView,
    PdfcnThemeProvider,
    PdfHeading,
    PdfPageBreak,
    PdfText,
  ],
  template: `
    <takumi-document>
      <takumi-page size="A4">
        <pdf-theme-provider>
          <takumi-view>
            <pdf-heading [level]="1">Section 1</pdf-heading>
            <pdf-text>Content on the first page.</pdf-text>
            <pdf-page-break />
            <pdf-heading [level]="1">Section 2</pdf-heading>
            <pdf-text>Content on the second page.</pdf-text>
          </takumi-view>
        </pdf-theme-provider>
      </takumi-page>
    </takumi-document>
  `,
})
export class PageBreakDemo {}
```

## API Reference

### PdfPageBreak

| Input   | Type    | Default |
| ------- | ------- | ------- |
| `style` | `Style` | -       |