fix: replace invalid orientation parameter with flipped in Typst templates

- Replace orientation: orientation with flipped: orientation == "landscape"
- Add conditional width: auto for single-page landscape exports
- Ensure all templates use correct Typst page() parameters
- Fix compilation errors in modern, article, report, and default templates

Resolves Typst compilation error: "unexpected argument: orientation"

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Jarvis committed 2025-09-03 10:49:19 +02:00
1 parent 9039b90bb5
commit 305df30c85
4 files changed
+32 -8

No files matched your search

+8 -2
View File
@@ -105,9 +105,15 @@
// Set page layout with conditional height based on export format
set page(
paper: paper,
orientation: orientation,
flipped: orientation == "landscape",
margin: page-margin,
..if export_format == "single-page" { (height: auto,) } else { (:) },
..if export_format == "single-page" and orientation == "landscape" {
(width: auto,)
} else if export_format == "single-page" {
(height: auto,)
} else {
(:)
},
numbering: pagenumbering,
header: context {
let page-num = counter(page).get().first()