catppuccin / catppuccin/typst

Refactor `tidy` package dependency usage

Open
#62 1 comment 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
Typst
Stars
73
Forks
2
PR merge metrics
No merged PRs in 30d

Description

### Is there an existing issue outlining your improvement?

- [x] I have searched the existing issues and my improvement has not been raised yet.

### What would you like to see added and/or changed?

Currently, we use [Tidy](https://typst.app/universe/package/tidy/) to generate documentation. I have been thinking about cleaning something up in the `catppuccin` package, which exposes some tooling to make the document theming possible, but it really should be its own package that depends on catppuccin.

`Tidy` isn't well optimised to allow custom styling and, as a result, the current files [tidy/styles.typ](https://github.com/catppuccin/typst/blob/main/src/tidy/styles.typ) and [tidy/show-module.typ](https://github.com/catppuccin/typst/blob/main/src/tidy/show-module.typ) are not overly flexible. Furthermore, I believe `show-module` is a little outdated.

This issue would require completing two tasks:
- [ ] Refactor `show-module.typ` to be up-to-date and allow passthrough of additional arguments.
- [ ] Revisit `styles.typ`. Can this, along with `show-modules.typ`, be improved? At the very least, it should be slightly more flexible. Tidy already isn't flexible, so allowing a bit of modularity prevents users from needing to effectively copy/paste our src to make additions (e.g., doc type colours).

Contributor guide

Open the contributing guide

Research direction

Start by reading src/tidy/show-module.typ and src/tidy/styles.typ, then trace how Tidy and show-modules.typ are used in the documentation setup. Compare show-module.typ with the current Tidy interface and identify the required passthrough and modularity changes. Done means both listed refactoring tasks are addressed without requiring users to copy the package sources.

Written by the indexing model from the issue text.

Assessment

Domain
documentation, tooling
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.