Skip to content

Commit

Permalink
fix: bring back ttf fonts for invoices
Browse files Browse the repository at this point in the history
  • Loading branch information
nijel committed Dec 19, 2024
1 parent 2ecaf4e commit 33cbd50
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 0 deletions.
13 changes: 13 additions & 0 deletions scripts/fonts.toml
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
[source-code-woff2]
# Used in CSS
destination = "weblate_web/static/vendor/font-source/WOFF2/TTF"
extract = [
"WOFF2/TTF/SourceCodePro-Bold.ttf.woff2",
Expand All @@ -12,7 +13,19 @@ url = "https://github.com/adobe-fonts/source-code-pro/releases/download/{version
# renovate: datasource=github-releases depName=adobe-fonts/source-code-pro
version = "2.042R-u/1.062R-i/1.026R-vf"

[source-sans-ttf]
# Used for PDF rendering
destination = "weblate_web/static/vendor/font-source/TTF"
extract = [
"TTF/SourceSans3-Bold.ttf",
"TTF/SourceSans3-Regular.ttf"
]
url = "https://github.com/adobe-fonts/source-sans/releases/download/{version}/TTF-source-sans-{version}.zip"
# renovate: datasource=github-releases depName=adobe-fonts/source-sans
version = "3.052R"

[source-sans-woff2]
# Used in CSS
destination = "weblate_web/static/vendor/font-source/WOFF2/TTF"
extract = [
"WOFF2/TTF/SourceSans3-Black.ttf.woff2",
Expand Down
1 change: 1 addition & 0 deletions scripts/update-fonts
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ for name, font in FONTS.items():
**font,
)
destination = Path(font["destination"])
destination.mkdir(parents=True, exist_ok=True)
print(f"Download {url}...")
response = requests.get(url, timeout=30)
response.raise_for_status()
Expand Down
Binary file not shown.
Binary file not shown.

0 comments on commit 33cbd50

Please sign in to comment.