Skip to content

Commit

Permalink
fix: Add missing props types on Document element (#2232)
Browse files Browse the repository at this point in the history
* add missing props types

* Update index.d.ts

fix: #2231 (comment)

* changeset

---------

Co-authored-by: Dmitry Ivakhnenko <jeetiss@yandex.ru>
  • Loading branch information
wneel and jeetiss authored Mar 13, 2023
1 parent 1f09582 commit 5832ff2
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
5 changes: 5 additions & 0 deletions .changeset/forty-forks-divide.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@react-pdf/renderer': patch
---

Add missing props types on `Document` component
5 changes: 5 additions & 0 deletions packages/renderer/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ import {
HyphenationCallback,
SVGPresentationAttributes,
Bookmark,
PageLayout,
PageMode,
} from '@react-pdf/types';

declare namespace ReactPDF {
Expand All @@ -20,6 +22,7 @@ declare namespace ReactPDF {
}

interface DocumentProps {
style?: Style | Style[];
title?: string;
author?: string;
subject?: string;
Expand All @@ -28,6 +31,8 @@ declare namespace ReactPDF {
producer?: string;
language?: string;
pdfVersion?: PDFVersion;
pageMode?: PageMode;
pageLayout ?: PageLayout;
onRender?: (props: OnRenderProps) => any;
}

Expand Down

0 comments on commit 5832ff2

Please sign in to comment.