diff --git a/pyproject.toml b/pyproject.toml index 302f53042..38e95883d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -62,7 +62,7 @@ full = [ "typer>=0.24.1", # Command-line interface "watchdog>=6.0.0", # Monitor files for updates "typst>=0.14.8", # Render PDF from Typst source files - "rendercv-fonts>=0.5.1", # Font files for RenderCV + "rendercv-fonts>=0.5.2", # Font files for RenderCV "packaging>=26.0", # For version checking ] diff --git a/src/rendercv/renderer/templater/connections.py b/src/rendercv/renderer/templater/connections.py index 0823531c7..3396c389c 100644 --- a/src/rendercv/renderer/templater/connections.py +++ b/src/rendercv/renderer/templater/connections.py @@ -13,6 +13,7 @@ "LinkedIn": "linkedin", "GitHub": "github", "GitLab": "gitlab", + "HuggingFace": "hugging-face", "IMDB": "imdb", "Instagram": "instagram", "Mastodon": "mastodon", diff --git a/src/rendercv/schema/models/cv/social_network.py b/src/rendercv/schema/models/cv/social_network.py index 50fec3be4..02b749d12 100644 --- a/src/rendercv/schema/models/cv/social_network.py +++ b/src/rendercv/schema/models/cv/social_network.py @@ -16,6 +16,7 @@ "LinkedIn", "GitHub", "GitLab", + "HuggingFace", "IMDB", "Instagram", "ORCID", @@ -36,6 +37,7 @@ "LinkedIn": "https://linkedin.com/in/", "GitHub": "https://github.com/", "GitLab": "https://gitlab.com/", + "HuggingFace": "https://huggingface.co/", "IMDB": "https://imdb.com/name/", "Instagram": "https://instagram.com/", "ORCID": "https://orcid.org/", diff --git a/tests/renderer/conftest.py b/tests/renderer/conftest.py index 9d4a441f8..2b4675b74 100644 --- a/tests/renderer/conftest.py +++ b/tests/renderer/conftest.py @@ -143,6 +143,7 @@ def full_rendercv_model(testdata_dir: pathlib.Path) -> RenderCVModel: social_networks=[ SocialNetwork(network="LinkedIn", username="johndoe"), SocialNetwork(network="GitHub", username="johndoe"), + SocialNetwork(network="HuggingFace", username="johndoe"), SocialNetwork(network="IMDB", username="nm0000001"), SocialNetwork(network="Instagram", username="johndoe"), SocialNetwork(network="ORCID", username="0000-0000-0000-0000"), diff --git a/tests/renderer/testdata/test_html/full.html b/tests/renderer/testdata/test_html/full.html index 2f2fa1fed..c9ddb6600 100644 --- a/tests/renderer/testdata/test_html/full.html +++ b/tests/renderer/testdata/test_html/full.html @@ -47,6 +47,7 @@

John Doe's CV

  • Website: example.com
  • LinkedIn: johndoe
  • GitHub: johndoe
  • +
  • HuggingFace: johndoe
  • IMDB: nm0000001
  • Instagram: johndoe
  • ORCID: 0000-0000-0000-0000
  • diff --git a/tests/renderer/testdata/test_markdown/full.md b/tests/renderer/testdata/test_markdown/full.md index de8db82f7..a30a81612 100644 --- a/tests/renderer/testdata/test_markdown/full.md +++ b/tests/renderer/testdata/test_markdown/full.md @@ -6,6 +6,7 @@ - Website: [example.com](https://example.com/) - LinkedIn: [johndoe](https://linkedin.com/in/johndoe) - GitHub: [johndoe](https://github.com/johndoe) +- HuggingFace: [johndoe](https://huggingface.co/johndoe) - IMDB: [nm0000001](https://imdb.com/name/nm0000001) - Instagram: [johndoe](https://instagram.com/johndoe) - ORCID: [0000-0000-0000-0000](https://orcid.org/0000-0000-0000-0000) diff --git a/tests/renderer/testdata/test_pdf_png/classic_full.pdf b/tests/renderer/testdata/test_pdf_png/classic_full.pdf index d352424e5..f59b9970a 100644 Binary files a/tests/renderer/testdata/test_pdf_png/classic_full.pdf and b/tests/renderer/testdata/test_pdf_png/classic_full.pdf differ diff --git a/tests/renderer/testdata/test_pdf_png/ember_full.pdf b/tests/renderer/testdata/test_pdf_png/ember_full.pdf index 86ad3e7e6..c5457e4f2 100644 Binary files a/tests/renderer/testdata/test_pdf_png/ember_full.pdf and b/tests/renderer/testdata/test_pdf_png/ember_full.pdf differ diff --git a/tests/renderer/testdata/test_pdf_png/engineeringclassic_full.pdf b/tests/renderer/testdata/test_pdf_png/engineeringclassic_full.pdf index 733db72d8..ac5d54c79 100644 Binary files a/tests/renderer/testdata/test_pdf_png/engineeringclassic_full.pdf and b/tests/renderer/testdata/test_pdf_png/engineeringclassic_full.pdf differ diff --git a/tests/renderer/testdata/test_pdf_png/engineeringresumes_full.pdf b/tests/renderer/testdata/test_pdf_png/engineeringresumes_full.pdf index fe79f63e6..cd7d7406a 100644 Binary files a/tests/renderer/testdata/test_pdf_png/engineeringresumes_full.pdf and b/tests/renderer/testdata/test_pdf_png/engineeringresumes_full.pdf differ diff --git a/tests/renderer/testdata/test_pdf_png/harvard_full.pdf b/tests/renderer/testdata/test_pdf_png/harvard_full.pdf index 1e73c3fe0..c93eeb430 100644 Binary files a/tests/renderer/testdata/test_pdf_png/harvard_full.pdf and b/tests/renderer/testdata/test_pdf_png/harvard_full.pdf differ diff --git a/tests/renderer/testdata/test_pdf_png/ink_full.pdf b/tests/renderer/testdata/test_pdf_png/ink_full.pdf index e08d0fcab..795392cc0 100644 Binary files a/tests/renderer/testdata/test_pdf_png/ink_full.pdf and b/tests/renderer/testdata/test_pdf_png/ink_full.pdf differ diff --git a/tests/renderer/testdata/test_pdf_png/moderncv_full.pdf b/tests/renderer/testdata/test_pdf_png/moderncv_full.pdf index 19614eae0..9bd907a30 100644 Binary files a/tests/renderer/testdata/test_pdf_png/moderncv_full.pdf and b/tests/renderer/testdata/test_pdf_png/moderncv_full.pdf differ diff --git a/tests/renderer/testdata/test_pdf_png/opal_full.pdf b/tests/renderer/testdata/test_pdf_png/opal_full.pdf index 4f66583aa..82d8929d7 100644 Binary files a/tests/renderer/testdata/test_pdf_png/opal_full.pdf and b/tests/renderer/testdata/test_pdf_png/opal_full.pdf differ diff --git a/tests/renderer/testdata/test_pdf_png/sb2nov_full.pdf b/tests/renderer/testdata/test_pdf_png/sb2nov_full.pdf index 7605cf2a1..324aa5d39 100644 Binary files a/tests/renderer/testdata/test_pdf_png/sb2nov_full.pdf and b/tests/renderer/testdata/test_pdf_png/sb2nov_full.pdf differ diff --git a/tests/renderer/testdata/test_typst/classic_full.typ b/tests/renderer/testdata/test_typst/classic_full.typ index 562cd2126..e7ebcabdd 100644 --- a/tests/renderer/testdata/test_typst/classic_full.typ +++ b/tests/renderer/testdata/test_typst/classic_full.typ @@ -104,6 +104,7 @@ [#link("https://example.com/", icon: false, if-underline: false, if-color: false)[#connection-with-icon("link")[example.com]]], [#link("https://linkedin.com/in/johndoe", icon: false, if-underline: false, if-color: false)[#connection-with-icon("linkedin")[johndoe]]], [#link("https://github.com/johndoe", icon: false, if-underline: false, if-color: false)[#connection-with-icon("github")[johndoe]]], + [#link("https://huggingface.co/johndoe", icon: false, if-underline: false, if-color: false)[#connection-with-icon("hugging-face")[johndoe]]], [#link("https://imdb.com/name/nm0000001", icon: false, if-underline: false, if-color: false)[#connection-with-icon("imdb")[nm0000001]]], [#link("https://instagram.com/johndoe", icon: false, if-underline: false, if-color: false)[#connection-with-icon("instagram")[johndoe]]], [#link("https://orcid.org/0000-0000-0000-0000", icon: false, if-underline: false, if-color: false)[#connection-with-icon("orcid")[0000-0000-0000-0000]]], diff --git a/tests/renderer/testdata/test_typst/ember_full.typ b/tests/renderer/testdata/test_typst/ember_full.typ index 8037366e8..4a4775d65 100644 --- a/tests/renderer/testdata/test_typst/ember_full.typ +++ b/tests/renderer/testdata/test_typst/ember_full.typ @@ -104,6 +104,7 @@ [#link("https://example.com/", icon: false, if-underline: false, if-color: false)[example.com]], [#link("https://linkedin.com/in/johndoe", icon: false, if-underline: false, if-color: false)[johndoe]], [#link("https://github.com/johndoe", icon: false, if-underline: false, if-color: false)[johndoe]], + [#link("https://huggingface.co/johndoe", icon: false, if-underline: false, if-color: false)[johndoe]], [#link("https://imdb.com/name/nm0000001", icon: false, if-underline: false, if-color: false)[nm0000001]], [#link("https://instagram.com/johndoe", icon: false, if-underline: false, if-color: false)[johndoe]], [#link("https://orcid.org/0000-0000-0000-0000", icon: false, if-underline: false, if-color: false)[0000-0000-0000-0000]], diff --git a/tests/renderer/testdata/test_typst/engineeringclassic_full.typ b/tests/renderer/testdata/test_typst/engineeringclassic_full.typ index 3b40e52ad..8e6a364cf 100644 --- a/tests/renderer/testdata/test_typst/engineeringclassic_full.typ +++ b/tests/renderer/testdata/test_typst/engineeringclassic_full.typ @@ -104,6 +104,7 @@ [#link("https://example.com/", icon: false, if-underline: false, if-color: false)[#connection-with-icon("link")[example.com]]], [#link("https://linkedin.com/in/johndoe", icon: false, if-underline: false, if-color: false)[#connection-with-icon("linkedin")[johndoe]]], [#link("https://github.com/johndoe", icon: false, if-underline: false, if-color: false)[#connection-with-icon("github")[johndoe]]], + [#link("https://huggingface.co/johndoe", icon: false, if-underline: false, if-color: false)[#connection-with-icon("hugging-face")[johndoe]]], [#link("https://imdb.com/name/nm0000001", icon: false, if-underline: false, if-color: false)[#connection-with-icon("imdb")[nm0000001]]], [#link("https://instagram.com/johndoe", icon: false, if-underline: false, if-color: false)[#connection-with-icon("instagram")[johndoe]]], [#link("https://orcid.org/0000-0000-0000-0000", icon: false, if-underline: false, if-color: false)[#connection-with-icon("orcid")[0000-0000-0000-0000]]], diff --git a/tests/renderer/testdata/test_typst/engineeringresumes_full.typ b/tests/renderer/testdata/test_typst/engineeringresumes_full.typ index 2cbd73129..e0da61f77 100644 --- a/tests/renderer/testdata/test_typst/engineeringresumes_full.typ +++ b/tests/renderer/testdata/test_typst/engineeringresumes_full.typ @@ -104,6 +104,7 @@ [#link("https://example.com/", icon: false, if-underline: false, if-color: false)[example.com]], [#link("https://linkedin.com/in/johndoe", icon: false, if-underline: false, if-color: false)[linkedin.com\/in\/johndoe]], [#link("https://github.com/johndoe", icon: false, if-underline: false, if-color: false)[github.com\/johndoe]], + [#link("https://huggingface.co/johndoe", icon: false, if-underline: false, if-color: false)[huggingface.co\/johndoe]], [#link("https://imdb.com/name/nm0000001", icon: false, if-underline: false, if-color: false)[imdb.com\/name\/nm0000001]], [#link("https://instagram.com/johndoe", icon: false, if-underline: false, if-color: false)[instagram.com\/johndoe]], [#link("https://orcid.org/0000-0000-0000-0000", icon: false, if-underline: false, if-color: false)[orcid.org\/0000-0000-0000-0000]], diff --git a/tests/renderer/testdata/test_typst/harvard_full.typ b/tests/renderer/testdata/test_typst/harvard_full.typ index 84fe23711..3b531d8f0 100644 --- a/tests/renderer/testdata/test_typst/harvard_full.typ +++ b/tests/renderer/testdata/test_typst/harvard_full.typ @@ -104,6 +104,7 @@ [#link("https://example.com/", icon: false, if-underline: false, if-color: false)[example.com]], [#link("https://linkedin.com/in/johndoe", icon: false, if-underline: false, if-color: false)[johndoe]], [#link("https://github.com/johndoe", icon: false, if-underline: false, if-color: false)[johndoe]], + [#link("https://huggingface.co/johndoe", icon: false, if-underline: false, if-color: false)[johndoe]], [#link("https://imdb.com/name/nm0000001", icon: false, if-underline: false, if-color: false)[nm0000001]], [#link("https://instagram.com/johndoe", icon: false, if-underline: false, if-color: false)[johndoe]], [#link("https://orcid.org/0000-0000-0000-0000", icon: false, if-underline: false, if-color: false)[0000-0000-0000-0000]], diff --git a/tests/renderer/testdata/test_typst/ink_full.typ b/tests/renderer/testdata/test_typst/ink_full.typ index 268909fc1..c68b74b12 100644 --- a/tests/renderer/testdata/test_typst/ink_full.typ +++ b/tests/renderer/testdata/test_typst/ink_full.typ @@ -104,6 +104,7 @@ [#link("https://example.com/", icon: false, if-underline: false, if-color: false)[example.com]], [#link("https://linkedin.com/in/johndoe", icon: false, if-underline: false, if-color: false)[linkedin.com\/in\/johndoe]], [#link("https://github.com/johndoe", icon: false, if-underline: false, if-color: false)[github.com\/johndoe]], + [#link("https://huggingface.co/johndoe", icon: false, if-underline: false, if-color: false)[huggingface.co\/johndoe]], [#link("https://imdb.com/name/nm0000001", icon: false, if-underline: false, if-color: false)[imdb.com\/name\/nm0000001]], [#link("https://instagram.com/johndoe", icon: false, if-underline: false, if-color: false)[instagram.com\/johndoe]], [#link("https://orcid.org/0000-0000-0000-0000", icon: false, if-underline: false, if-color: false)[orcid.org\/0000-0000-0000-0000]], diff --git a/tests/renderer/testdata/test_typst/moderncv_full.typ b/tests/renderer/testdata/test_typst/moderncv_full.typ index a95087481..cef1b96c2 100644 --- a/tests/renderer/testdata/test_typst/moderncv_full.typ +++ b/tests/renderer/testdata/test_typst/moderncv_full.typ @@ -104,6 +104,7 @@ [#link("https://example.com/", icon: false, if-underline: false, if-color: false)[#connection-with-icon("link")[example.com]]], [#link("https://linkedin.com/in/johndoe", icon: false, if-underline: false, if-color: false)[#connection-with-icon("linkedin")[johndoe]]], [#link("https://github.com/johndoe", icon: false, if-underline: false, if-color: false)[#connection-with-icon("github")[johndoe]]], + [#link("https://huggingface.co/johndoe", icon: false, if-underline: false, if-color: false)[#connection-with-icon("hugging-face")[johndoe]]], [#link("https://imdb.com/name/nm0000001", icon: false, if-underline: false, if-color: false)[#connection-with-icon("imdb")[nm0000001]]], [#link("https://instagram.com/johndoe", icon: false, if-underline: false, if-color: false)[#connection-with-icon("instagram")[johndoe]]], [#link("https://orcid.org/0000-0000-0000-0000", icon: false, if-underline: false, if-color: false)[#connection-with-icon("orcid")[0000-0000-0000-0000]]], diff --git a/tests/renderer/testdata/test_typst/opal_full.typ b/tests/renderer/testdata/test_typst/opal_full.typ index 65d5a2135..3aa384779 100644 --- a/tests/renderer/testdata/test_typst/opal_full.typ +++ b/tests/renderer/testdata/test_typst/opal_full.typ @@ -104,6 +104,7 @@ [#link("https://example.com/", icon: false, if-underline: false, if-color: false)[#connection-with-icon("link")[example.com]]], [#link("https://linkedin.com/in/johndoe", icon: false, if-underline: false, if-color: false)[#connection-with-icon("linkedin")[johndoe]]], [#link("https://github.com/johndoe", icon: false, if-underline: false, if-color: false)[#connection-with-icon("github")[johndoe]]], + [#link("https://huggingface.co/johndoe", icon: false, if-underline: false, if-color: false)[#connection-with-icon("hugging-face")[johndoe]]], [#link("https://imdb.com/name/nm0000001", icon: false, if-underline: false, if-color: false)[#connection-with-icon("imdb")[nm0000001]]], [#link("https://instagram.com/johndoe", icon: false, if-underline: false, if-color: false)[#connection-with-icon("instagram")[johndoe]]], [#link("https://orcid.org/0000-0000-0000-0000", icon: false, if-underline: false, if-color: false)[#connection-with-icon("orcid")[0000-0000-0000-0000]]], diff --git a/tests/renderer/testdata/test_typst/sb2nov_full.typ b/tests/renderer/testdata/test_typst/sb2nov_full.typ index 3da34102f..f1df05780 100644 --- a/tests/renderer/testdata/test_typst/sb2nov_full.typ +++ b/tests/renderer/testdata/test_typst/sb2nov_full.typ @@ -104,6 +104,7 @@ [#link("https://example.com/", icon: false, if-underline: false, if-color: false)[example.com]], [#link("https://linkedin.com/in/johndoe", icon: false, if-underline: false, if-color: false)[linkedin.com\/in\/johndoe]], [#link("https://github.com/johndoe", icon: false, if-underline: false, if-color: false)[github.com\/johndoe]], + [#link("https://huggingface.co/johndoe", icon: false, if-underline: false, if-color: false)[huggingface.co\/johndoe]], [#link("https://imdb.com/name/nm0000001", icon: false, if-underline: false, if-color: false)[imdb.com\/name\/nm0000001]], [#link("https://instagram.com/johndoe", icon: false, if-underline: false, if-color: false)[instagram.com\/johndoe]], [#link("https://orcid.org/0000-0000-0000-0000", icon: false, if-underline: false, if-color: false)[orcid.org\/0000-0000-0000-0000]], diff --git a/tests/schema/models/cv/test_social_network.py b/tests/schema/models/cv/test_social_network.py index f29b72b43..44ea8899f 100644 --- a/tests/schema/models/cv/test_social_network.py +++ b/tests/schema/models/cv/test_social_network.py @@ -43,6 +43,7 @@ def test_rejects_invalid_networks_and_usernames(self, network, username): [ ("LinkedIn", "myusername", "https://linkedin.com/in/myusername"), ("GitHub", "myusername", "https://github.com/myusername"), + ("HuggingFace", "myusername", "https://huggingface.co/myusername"), ("IMDB", "nm0000001", "https://imdb.com/name/nm0000001"), ("Instagram", "myusername", "https://instagram.com/myusername"), ("ORCID", "0000-0000-0000-0000", "https://orcid.org/0000-0000-0000-0000"), diff --git a/uv.lock b/uv.lock index e956d6374..a9e110e6b 100644 --- a/uv.lock +++ b/uv.lock @@ -1258,7 +1258,7 @@ requires-dist = [ { name = "phonenumbers", specifier = ">=9.0.24" }, { name = "pydantic", extras = ["email"], specifier = ">=2.12.5" }, { name = "pydantic-extra-types", specifier = ">=2.11.0" }, - { name = "rendercv-fonts", marker = "extra == 'full'", specifier = ">=0.5.1" }, + { name = "rendercv-fonts", marker = "extra == 'full'", specifier = ">=0.5.2" }, { name = "ruamel-yaml", specifier = ">=0.19.1" }, { name = "typer", marker = "extra == 'full'", specifier = ">=0.24.1" }, { name = "typst", marker = "extra == 'full'", specifier = ">=0.14.8" },