Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions .github/workflows/latest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,17 +39,22 @@ jobs:
run: |
python scripts/build_assets.py --output build/assets
typst compile --root . --font-path source/fonts --pdf-standard ua-1 manual/main.typ build/libresign-brand-manual.pdf
typst compile --root . --font-path source/fonts --pdf-standard ua-1 --input format=slides manual/main.typ build/libresign-brand-manual-slides.pdf
cp build/assets/libresign-logo.svg build/libresign-logo.svg
cp build/assets/libresign-logo.pdf build/libresign-logo.pdf
cp build/assets/libresign-logo.png build/libresign-logo.png
cp build/assets/libresign-logo-reversed.svg build/libresign-logo-reversed.svg
sha256sum build/libresign-brand-manual.pdf build/libresign-logo* > build/SHA256SUMS
sha256sum build/libresign-brand-manual.pdf build/libresign-brand-manual-slides.pdf build/libresign-logo* > build/SHA256SUMS
- name: Validate PDF/UA-1 with veraPDF
run: |
docker run --rm \
-v "$PWD/build:/data:ro" \
verapdf/cli:latest \
--flavour ua1 --format text /data/libresign-brand-manual.pdf
docker run --rm \
-v "$PWD/build:/data:ro" \
verapdf/cli:latest \
--flavour ua1 --format text /data/libresign-brand-manual-slides.pdf
- name: Move latest tag to this build
run: |
git tag -f latest "$GITHUB_SHA"
Expand All @@ -62,4 +67,4 @@ jobs:
gh release create latest --prerelease --title "Latest development build" --notes "Continuously updated development build from the main branch. This is not a versioned release."
fi
gh release edit latest --title "Latest development build" --notes "Continuously updated development build from the main branch. This is not a versioned release." --prerelease
gh release upload latest build/libresign-brand-manual.pdf build/libresign-logo.svg build/libresign-logo.pdf build/libresign-logo.png build/libresign-logo-reversed.svg build/SHA256SUMS --clobber
gh release upload latest build/libresign-brand-manual.pdf build/libresign-brand-manual-slides.pdf build/libresign-logo.svg build/libresign-logo.pdf build/libresign-logo.png build/libresign-logo-reversed.svg build/SHA256SUMS --clobber
9 changes: 8 additions & 1 deletion .github/workflows/manual.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,13 +49,20 @@ jobs:
- name: Build accessible PDF
run: |
typst compile --root . --font-path source/fonts --pdf-standard ua-1 manual/main.typ build/brand-manual.pdf
typst compile --root . --font-path source/fonts --pdf-standard ua-1 --input format=slides manual/main.typ build/brand-manual-slides.pdf
- name: Validate PDF/UA-1 with veraPDF
run: |
docker run --rm \
-v "$PWD/build:/data:ro" \
verapdf/cli:latest \
--flavour ua1 --format text /data/brand-manual.pdf
docker run --rm \
-v "$PWD/build:/data:ro" \
verapdf/cli:latest \
--flavour ua1 --format text /data/brand-manual-slides.pdf
- uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
name: brand-manual
path: build/brand-manual.pdf
path: |
build/brand-manual.pdf
build/brand-manual-slides.pdf
9 changes: 7 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,22 +27,27 @@ jobs:
run: |
python scripts/build_assets.py --output build/assets
typst compile --root . --font-path source/fonts --pdf-standard ua-1 manual/main.typ build/libresign-brand-manual.pdf
typst compile --root . --font-path source/fonts --pdf-standard ua-1 --input format=slides manual/main.typ build/libresign-brand-manual-slides.pdf
cp build/assets/libresign-logo.svg build/libresign-logo.svg
cp build/assets/libresign-logo.pdf build/libresign-logo.pdf
cp build/assets/libresign-logo.png build/libresign-logo.png
cp build/assets/libresign-logo-reversed.svg build/libresign-logo-reversed.svg
sha256sum build/libresign-brand-manual.pdf build/libresign-logo.svg build/libresign-logo.pdf build/libresign-logo.png build/libresign-logo-reversed.svg > build/SHA256SUMS
sha256sum build/libresign-brand-manual.pdf build/libresign-brand-manual-slides.pdf build/libresign-logo.svg build/libresign-logo.pdf build/libresign-logo.png build/libresign-logo-reversed.svg > build/SHA256SUMS
- name: Validate PDF/UA-1 with veraPDF
run: |
docker run --rm \
-v "$PWD/build:/data:ro" \
verapdf/cli:latest \
--flavour ua1 --format text /data/libresign-brand-manual.pdf
docker run --rm \
-v "$PWD/build:/data:ro" \
verapdf/cli:latest \
--flavour ua1 --format text /data/libresign-brand-manual-slides.pdf
- name: Publish versioned release
env:
GH_TOKEN: ${{ github.token }}
run: |
if ! gh release view "$GITHUB_REF_NAME" >/dev/null 2>&1; then
gh release create "$GITHUB_REF_NAME" --generate-notes --title "libresign brand $GITHUB_REF_NAME"
fi
gh release upload "$GITHUB_REF_NAME" build/libresign-brand-manual.pdf build/libresign-logo.svg build/libresign-logo.pdf build/libresign-logo.png build/libresign-logo-reversed.svg build/SHA256SUMS --clobber
gh release upload "$GITHUB_REF_NAME" build/libresign-brand-manual.pdf build/libresign-brand-manual-slides.pdf build/libresign-logo.svg build/libresign-logo.pdf build/libresign-logo.png build/libresign-logo-reversed.svg build/SHA256SUMS --clobber
10 changes: 10 additions & 0 deletions manual/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,14 @@ typst compile \
--pdf-standard ua-1 \
manual/main.typ \
build/brand-manual.pdf

typst compile \
--root . \
--font-path source/fonts \
--pdf-standard ua-1 \
--input format=slides \
manual/main.typ \
build/brand-manual-slides.pdf
```

The same asset generator is used by local builds, CI, the continuous `latest` release, and versioned releases.
Expand Down Expand Up @@ -61,3 +69,5 @@ For editor diagnostics, Tinymist is the recommended language server. Enable its
- avoid brand-specific dead code and unused exports in shared component files;
- keep source-derived technical diagrams outside Typst when geometry must remain authoritative; Typst should compose and scale those generated vectors;
- do not add a Typst package dependency when a small local function is sufficient.

The 16:9 PDF uses the same Typst source and brand rules. It is a widescreen reading format, not an abridged speaker deck; individual topics can flow onto more than one slide. Review both PDFs at their intended display size before publishing.
33 changes: 25 additions & 8 deletions manual/components.typ
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
// SPDX-FileCopyrightText: 2026 LibreSign contributors
// SPDX-License-Identifier: CC-BY-SA-4.0

#let slides = sys.inputs.at("format", default: "a4") == "slides"

#let motif(theme) = {
if theme.motif == "nodes" {
place(top + left, dx: -8mm, dy: -10mm, circle(radius: 18mm, fill: theme.accent))
Expand Down Expand Up @@ -117,7 +119,11 @@
]

#let manual-page(theme, kicker, title, body) = page(
margin: (left: 24mm, right: 22mm, top: 22mm, bottom: 20mm),
margin: if slides {
(left: 18mm, right: 18mm, top: 14mm, bottom: 12mm)
} else {
(left: 24mm, right: 22mm, top: 22mm, bottom: 20mm)
},
fill: theme.paper,
footer: context {
align(right, text(
Expand All @@ -128,33 +134,44 @@
))
},
)[
#place(left + top, dx: -24mm, dy: -22mm, rect(width: 4mm, height: 100% + 42mm, fill: theme.accent))
#place(
left + top,
dx: if slides { -18mm } else { -24mm },
dy: if slides { -14mm } else { -22mm },
rect(width: 4mm, height: 100% + if slides { 26mm } else { 42mm }, fill: theme.accent),
)
#text(font: theme.heading-font, size: 8.5pt, weight: "medium", fill: theme.accent)[#upper(kicker)]
#v(4mm)
#heading(level: 2, outlined: true, bookmarked: true, numbering: none)[
#text(font: theme.heading-font, size: 24pt, weight: "bold", fill: theme.ink)[#title]
#text(font: theme.heading-font, size: if slides { 26pt } else { 24pt }, weight: "bold", fill: theme.ink)[#title]
]
#v(6mm)
#body
]

#let logo-stage(theme, logo, alt, dark: false) = block(
width: 100%,
height: 78mm,
height: if slides { 56mm } else { 78mm },
fill: if dark { theme.ink } else { white },
radius: 4pt,
inset: 14mm,
inset: if slides { 9mm } else { 14mm },
)[
#align(center + horizon)[
#image(logo, width: 72%, height: 55mm, fit: "contain", alt: alt)
#image(
logo,
width: 72%,
height: if slides { 38mm } else { 55mm },
fit: "contain",
alt: alt,
)
]
]

#let swatch(name, hex, note: none) = grid(
columns: (30mm, 1fr),
gutter: 8mm,
align: horizon,
rect(width: 30mm, height: 18mm, fill: rgb(hex), radius: 2pt),
rect(width: 30mm, height: if slides { 12mm } else { 18mm }, fill: rgb(hex), radius: 2pt),
[
*#name* \
#raw(hex)
Expand All @@ -167,7 +184,7 @@

#let specimen(theme, family, role, sample, size: 24pt) = block(
width: 100%,
inset: 12pt,
inset: if slides { 8pt } else { 12pt },
fill: white,
radius: 4pt,
stroke: (paint: theme.soft, thickness: 0.6pt),
Expand Down
Loading
Loading