{"id":29215270,"url":"https://github.com/christopherkenny/projector-themes","last_synced_at":"2026-02-07T06:02:07.422Z","repository":{"id":300135981,"uuid":"956856273","full_name":"christopherkenny/projector-themes","owner":"christopherkenny","description":"Themes to style the projector Quarto template with Typst","archived":false,"fork":false,"pushed_at":"2025-06-23T18:21:34.000Z","size":1742,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-07-30T01:11:51.276Z","etag":null,"topics":["presentation","quarto","quartopub","typst","typst-lang"],"latest_commit_sha":null,"homepage":"","language":"Typst","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/christopherkenny.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-03-29T01:42:26.000Z","updated_at":"2025-06-23T18:21:37.000Z","dependencies_parsed_at":null,"dependency_job_id":"c5248856-47ff-4d70-ad0d-0920e2cdb595","html_url":"https://github.com/christopherkenny/projector-themes","commit_stats":null,"previous_names":["christopherkenny/projector-themes"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/christopherkenny/projector-themes","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/christopherkenny%2Fprojector-themes","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/christopherkenny%2Fprojector-themes/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/christopherkenny%2Fprojector-themes/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/christopherkenny%2Fprojector-themes/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/christopherkenny","download_url":"https://codeload.github.com/christopherkenny/projector-themes/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/christopherkenny%2Fprojector-themes/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29187938,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-07T05:07:31.176Z","status":"ssl_error","status_checked_at":"2026-02-07T05:06:15.227Z","response_time":63,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["presentation","quarto","quartopub","typst","typst-lang"],"created_at":"2025-07-03T00:09:08.904Z","updated_at":"2026-02-07T06:02:07.401Z","avatar_url":"https://github.com/christopherkenny.png","language":"Typst","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Themes for `projector` \u003cimg src='https://raw.githubusercontent.com/christopherkenny/projector/refs/heads/main/projector.png' align=\"right\" height=\"150\" /\u003e\n\n[`projector`](https://github.com/christopherkenny/projector) is a Quarto extension for making slides with [polylux](https://github.com/andreasKroepelin/polylux).\nThe design of the extension does not make it compatible with Polylux's design templates.\nHowever, styling can be done (relatively) easily through the `theme` YAML option.\n\nThis repo contains several themes for `projector`.\nCurrently supported themes are listed below:\n\n| theme      | description |\n| ---------- | ----------- |\n| coding     | A minimal theme using [GitHub Monaspace](https://github.com/githubnext/monaspace) fonts |\n| cousteau   | A blue, nautical theme based on [`mattblackwell/cousteau`](https://github.com/mattblackwell/cousteau) for beamer |\n| darker     | A dark theme with compact sans serif fonts  |\n| friendly   | A theme with whimsy based on [`polylux-typ/friendly`](https://github.com/polylux-typ/friendly) |\n| metropolis | A modern theme based on [`polylux-typ/metropolis`](https://github.com/polylux-typ/metropolis) and a [beamer template of the same name](https://github.com/matze/mtheme) |\n| techy      | A bright, futuristic theme overusing monospace sans serif fonts |\n| university | A professional, academic theme allowing for two color accents based on [`polylux-typ/polylux`'s university theme](https://github.com/polylux-typ/polylux) |\n\n## Using a template\n\nEach template comes with a pair of files necessary to use the theme.\nThe `*.yaml` will contain any settings that should be used in the YAML of your Quarto file.\nThe `*.typ` file should be placed in the directory of your Quarto file and then added to the `theme` YAML argument in the Quarto file.\n\n## Contributing a theme\n\nTo contribute a theme, please submit a pull request.\nThe `template` folder contains a template theme file.\nEach of these files should be edited to supply your theme.\n\n- `readme.md`: This should contain a short description of the theme. If there is any necessary attribution, please include details here.\n- `template.yaml`: This should set any YAML options to be used in Quarto.\n- `template.typ`: This should include any relevant Typst code to set up your theme. This includes copies of default definitions. Please remove those if you do not want to edit them.\n- `LICENSE`: This should contain any necessary license details. Notably, adopting themes from Tex or other Typst templates may require attribution in this. If possible, I recommend using the MIT-0 license for themes of this kind.\n\nThen a thumbnail should be included. To create one:\n\n1. Render the `template.qmd` with your theme.\n2. Create a png with dpi = 150 version of the first six slides in the order:\n\n```\n1 2\n3 4\n5 6\n```\n\nAn R function to do this is:\n\n```r\ngenerate_thumbnail \u003c- function(theme, pdf_file = 'template.pdf', dpi = 150) {\n  if (missing(theme)) {\n    stop('`theme` must be provided. e.g. `\"metropolis\"`.')\n  }\n  pages \u003c- lapply(1:6, function(i) {\n    pdftools::pdf_render_page(pdf_file, page = i, dpi = 150) |\u003e\n    magick::image_read()\n  })\n\n  thumbnail \u003c- magick::image_append(\n    c(\n      magick::image_append(c(pages[[1]], pages[[3]], pages[[5]]), stack = TRUE),\n      magick::image_append(c(pages[[2]], pages[[4]], pages[[6]]), stack = TRUE)\n    )\n  )\n\n  magick::image_write(thumbnail, path = paste0(theme, '.png'), density = 150)\n}\n\n```\n\n\n\n### Details of the `.yaml` file\n\n`projector` includes several custom arguments that can be supplied in the YAML header.\n\n- `mainfont`: sets font (see options with `quarto typst fonts`)\n- `margin`: sets page margins\n- `papersize`: the paper size to use (choices listed [here](https://typst.app/docs/reference/layout/page/))\n- `toc`: whether to display the table of contents\n- `toc_title`: title of the table of contents\n- `background-image`: the path to an image to put as the background\n- `theme`: a file name containing your customizations\n\nThese arguments take precedence over any settings in the `.typ` file.\nAll `.yaml` files should contain a `theme` argument at a minimum.\n\n### Details of the `.typ` file\n\nWithin the `.typ` file, you should include all of your styling choices within a function called `projector-theme(doc)`.\nAny styling choices should be applied within the function.\nThe file may contain any valid Typst code, including using other packages available on [Typst Universe](https://typst.app/universe/).\nThe contents of the file will be dropped into the template verbatim.\nThe current definitions file imports `polylux` and `fontawesome`by default.\n\nIn Typst syntax, the style will be applied as follows:\n\n```typst\nshow: projector-theme\n```\n\nIf `theme` is set in the YAML, this line will be run so it must include a definition for `projector-theme(doc)`.\n\nFurther, all YAML options are applied *after* the theme file is used.\nAs such, if you want to edit things controlled by the YAML, such as the font, you *must* do this via the YAML, not by the `.typ` file.\nLater definitions take precedence, so you will see no changes, but it will *silently* change nothing, as the code is still valid.\n\nTo modify the title, TOC, or section slides, you need to adjust them in your template file.\nRedefine the functions that produce them with your own version.\n\nThe function signatures should be as follows:\n\n- `title-slide(title, subtitle, authors, date)`\n- `toc-slide(toc_title)`\n- `section-slide(name)`\n\nEach of these slide calls should return a slide, via a call to `polylux-slide[]`.\nThe one exception is if you want it to *not* do anything.\nFor example, if you don't want a section slide, then return `{}`.\nYou do not need to use the arguments to these functions, but the signatures must match exactly or you'll get a compilation error.\n\nThe `toc-slide` function should contain a call to `#polylux-outline()` if you want the default outline included.\nThe `section-slide` function should contain a call to`#utils.register-section(name)` to register the section.\n\nFinally, if you just want to change the title, toc, or section slides, you can use a call to `projector-theme` that is empty.\nSpecifically, include the following:\n\n```typst\nprojector-theme(doc) = {\n  doc\n}\n```\nThe function must be present, but it doesn't have to do anything.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchristopherkenny%2Fprojector-themes","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fchristopherkenny%2Fprojector-themes","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchristopherkenny%2Fprojector-themes/lists"}