Skip to content

Conversation

@laurmaedje
Copy link
Member

@laurmaedje laurmaedje commented Jun 20, 2025

This PR introduces a typed API for constructing HTML elements in Typst. This makes for a much more convenient way of constructing HTML elements than the raw html.elem API.

Examples

Here are a few examples for elements, just to showcase how typed the API is:

#html.div(role: "article")[My article ...]
#html.time(datetime: datetime.today())
#html.span[A bit of text]
#html.input(accept: ("image/jpeg", "image/png"))
#html.meter(low: 3.4, high: 7.9)
#html.link(rel: "icon", color: red)
#html.form(autocomplete: false)
#html.img(
  src: "image.png",
  alt: "My wonderful image",
  srcset: (
    (src: "/image-120px.png", width: 120),
    (src: "/image-60px.png", width: 60),
  ),
)

This will yield the following HTML elements.

<div role="article">My article …</div>
<time datetime="1970-01-01"></time>
<span>A bit of text</span>
<input accept="image/jpeg, image/png" />
<meter low="3.4" high="7.9"></meter>
<link rel="icon" color="#ff4136">
<form autocomplete="off"></form>
<img
  src="image.png"
  alt="My wonderful image"
  srcset="/image-120px.png 120w, /image-60px.png 60w"
/>

As you can see, the API expresses each HTML attribute with its best fitting Typst type (colors, datetimes, integers, sometimes structured dictionaries, etc.), so that you can just work with the native types. No need to convert stuff to strings all the time or bother figuring out whether HTML uses "true", "on", "yes", or just the presence of an attribute to express true this time around.

On top of the specific and global HTML attributes, the API also includes the ARIA accessibility attributes.

Error messages also work as you would expect:

error: expected array, "additions", "additions text", "all", "removals", or "text"
  ┌─ hi.typ:1:26
  │
1 │ #html.link(aria-relevant: "nope")
  │                           ^^^^^^

Implementation

The data backing this API lives in crates/typst-library/src/html/generated.rs and is auto-generated from the HTML specification. The code responsible for generating this file lives in tools/codegen/src/html.rs. It automatically downloads the HTML (and a few other) specifications and extracts all the information it needs. The information is mostly taken from the Index section of the spec, but some stuff is scraped from elsewhere.

In the specification, the valid values for each HTML attribute are described in human-readable text. These descriptions are matched against a bunch of regular expressions during codegen to figure out the best Typst type. In the end, each attribute is assigned a Rust type like Str, NonZeroU64, or TokenList<f64, ' '>. The latter would mean that the attribute should be expressed as an array of floats in Typst and turned into a space-separated string in HTML. Among other things, codegen also automatically extracts stringy enums for attributes that follow such patterns. This results in a type like StrEnum<282, 285>, meaning that HTML defines 3 valid strings for this attribute and those can be found in generated::ATTR_STRINGS[282..285] (sometimes alongside descriptions, when those were conveniently available for scraping).

A type that can be used as an attribute implements the standard Reflect & FromValue traits used across Typst and on top of that IntoAttr (or sometimes IntoOptionalAttr if false means the attribute should be omitted). The latter traits are used to serialize the value into an HTML attribute string. Since all types used for attributes implement the standard reflection trait, all the information is also automatically available for docs, autocomplete, and error messages.

From the data, the functions are dynamically built during creation of the Library struct. This makes them very lightweight in terms of crate compile time in comparison to a design that would attempt to generate functions for everything at compile time via macros. Supporting this required minor changes to how native functions work. They are now backed by &'static dyn Fn(..) -> .. instead of fn(..) -> ...

Unresolved questions

  • Currently all attributes have their exact HTML names. Should we convert them to kebab-case (just like JS converts them to camelCase)? (Conclusion: No)

@T0mstone
Copy link
Contributor

I don't see a copyright notice, but I think one will be necessary given that the HTML spec is licensed under CC BY and this includes pieces of it verbatim into our source code.

@laurmaedje
Copy link
Member Author

laurmaedje commented Jun 20, 2025

Right, I thought about that and then forgot about it. I'll add it.

Edit: Added in typst/typst-assets@a70ec89

@Myriad-Dreamin
Copy link
Contributor

Myriad-Dreamin commented Jun 20, 2025

I used @vscode/web-custom-data to generate my typed HTML typst module. Using the json files from the package will help reproducible code generation (by locking version of npm package to use) and avoid souping data from HTML files.

@MDLC01
Copy link
Collaborator

MDLC01 commented Jun 20, 2025

Why did you chose to include the generated file in the repo instead of generating it as part of a build.rs script?

@laurmaedje
Copy link
Member Author

because the necessary specs would otherwise need to be checked in to keep things reproducible. I didn't want that in general but also because they weigh >15MB in total. and the API will be rarely updated so it's a bit of a waste to have everybody keep rerunning the codegen (which is not at all written to be efficient).

@laurmaedje
Copy link
Member Author

I agree that it seems unsatisfactory to check in generated code but it's the lesser evil here I think

@MDLC01
Copy link
Collaborator

MDLC01 commented Jun 20, 2025

Would it be possible have the generated stuff in typst-assets in some way, and then import that here and convert it to the right format (because typst-assets does not have access to the types defined here AFAIK)? Somehow it feels less problematic to me to have generated content as part of a separate repo. But maybe it isn't that important.

@PartyWumpus
Copy link

PartyWumpus commented Jun 21, 2025

This looks like it won't provide any way to include data-* attributes (or any kind of non-standard attribute in general). Is this omission intentional?

@laurmaedje
Copy link
Member Author

laurmaedje commented Jun 21, 2025

Would it be possible have the generated stuff in typst-assets in some way, and then import that here and convert it to the right format (because typst-assets does not have access to the types defined here AFAIK)? Somehow it feels less problematic to me to have generated content as part of a separate repo. But maybe it isn't that important.

@MDLC01 I had considered having this in another crate and the difficulty was indeed the types. I didn't manage to find a clean solution. However, with the hindsight of building the whole type-based machinery, I was able to do it after all while reusing almost all of the previous code with some adaptions. The codegen and data now lives in typst/typst-assets#10, which I also much prefer over having it here. :)

The one downside is that it's impossible to have the tag and attribute constants in another crate (as these types live here and depend on PicoStr) and it's not possible to generate module items with const fns. I just added these to the code manually now. They are much easier to maintain by hand than the element to attribute mappings and attribute types. And they are not user-facing, they are just for the convenience of having compile time constant tag names available in code that needs to match on tags and such. So if some tag or attribute is missing, it's not a big deal.

@laurmaedje
Copy link
Member Author

laurmaedje commented Jun 21, 2025

This looks like it won't provide any way to include data-* attributes (or any kind of non-standard attribute in general). Is this omission intentional?

@PartyWumpus Good call. @reknih and I had discussed that, but I then forgot about it again. We were considering to support a data dictionary alongside the other global attributes. As for non-standard attributes, we could in theory also support an attrs escape hatch, but I'm not sure it's really a good idea. There is always html.elem for full control.

@laurmaedje
Copy link
Member Author

laurmaedje commented Jun 21, 2025

I used @vscode/web-custom-data to generate my typed HTML typst module. Using the json files from the package will help reproducible code generation (by locking version of npm package to use) and avoid souping data from HTML files.

@Myriad-Dreamin I attempted to switch from spec scraping to using @vscode/web-custom-data and @webref/idl, but hit various problems:

  • The <area hreflang> attribute is listed in it (with no docs) even though it does not actually exist

  • Various attributes do not have documentation

  • The value sets are the most useful part because it's the most annoying part to scrape. But somehow they are not always correctly applied. E.g. <img referrerpolicy> has one, but <a referrerpolicy> doesn't.

You can also observe all of these problems in VS Code. I was already sort of convinced to switch to the VS Code data set, but it just doesn't feel very polished to me. I'm not saying that my mappings are bug-free, but at least if we find a bug it's easy to fix. If something is missing or wrong in this data set, you either have to hand-fill it, give up, or also parse the spec in addition. When just parsing the spec right away, we have full control and all information.

Beyond that:

  • Many attributes have no value sets. As you mentioned, it's possible to use @webref/idl to get the JS types. However, mapping tag names to IDL interfaces seems non-trivial, e.g. getting from td to HtmlTableCellElement. At least I found no such mapping in @webref/idl or @vscode/web-custom-data.

  • Value sets don't tell you whether the attribute is actually a token list. E.g. the sandbox attribute has a value set but actually allows multiple of the listed strings, and it should allow an array in Typst. This could probably be resolved by inspecting the IDL and seeing that it is a DOMTokenList though.

  • Even if you manage to map all attributes to IDL attributes, the IDL attributes are sometimes less typed than I'd like (e.g. coords is a DOMString even though it actually represents an array of floats and does so in my mapping).

And dealing with the IDL feels somehow even more painful than scraping the spec, in part because @webref/idl is really not well documented, but also because the interfaces can have inheritance, mixins, etc.

@PartyWumpus
Copy link

As for non-standard attributes, we could in theory also support an attrs escape hatch, but I'm not sure it's really a good idea. There is always html.elem for full control.

I think having any way of doing an escape hatch for non standard attributes would end up being a little odd at best (when html.elem exists fine) and I think won't be particularly common, just wanted to make sure it'd been considered.

We were considered to support a data dictionary alongside the other global attributes.

I think this however is probably a good idea? I'm not really sure how much people need there is though, and it would be unlike the rest of the interface...

Importantly both of those could be added Later™ so probably easiest to just leave em out for now add them later if it ends up being needed.

@MDLC01
Copy link
Collaborator

MDLC01 commented Jun 22, 2025

Would it be possible to accept a sink that only allows named arguments whose name starts with "data-"? I can think of the following issues with that: error messages, quality of auto-completion, and documentation. With a bit of work, all those issues could probably be solved. But of course this would be more work than just accepting a data dictionary.

@laurmaedje
Copy link
Member Author

It wouldn't be too hard I think. Truly not sure whether I like it better or not though.

@wrzian
Copy link
Contributor

wrzian commented Jun 22, 2025

Currently all attributes have their exact HTML names. Should we convert them to kebab-case (just like JS converts them to camelCase)?

I think we should use the exact HTML names to avoid confusion and make it easier to predict.

One reason is that I don't think we should add dashes to aria attrs with multiple words, i.e. aria-activedescendant because aria-active-descendant is just horrible. And then choosing to add dashes to e.g. popovertarget would feel inconsistent.

For prediction, I think there would be ambiguity on what counts as a word boundary. If a dev already knows the popovertarget attribute, I could see them expecting either popover-target or pop-over-target to be the kebab-case name. While I feel the first option is best, that choice seems subjective and I would rather delegate authority to the spec.

@laurmaedje
Copy link
Member Author

@wrzian We would choose the same word boundaries as JS, so at least there would be some precedent. But I've discussed this with @reknih and we've also agreed that it's better to just keep the exact HTML names. It's a bit pointless.


Regarding the data attributes: I will leave them out for now because we are undecided as of yet whether it should be a data dictionary or an argument sink with data-* arguments.

@laurmaedje laurmaedje added this pull request to the merge queue Jun 23, 2025
Merged via the queue into main with commit e9dc4bb Jun 23, 2025
14 checks passed
@laurmaedje laurmaedje deleted the html-typed branch June 23, 2025 09:39
Vanille-N pushed a commit to Vanille-N/typst that referenced this pull request Aug 14, 2025
hiandy24 pushed a commit to hiandy24/typst that referenced this pull request Sep 27, 2025
… upstream (#1)

* Numbering implementation refactor (typst#6122)

* Pin colspan and rowspan for blank cells (typst#6401)

* Clean up some parser comments (typst#6398)

* Autocomplete fixes for math mode (typst#6415)

* Update docs for gradient.repeat (typst#6385)

* Document how to escape lr delimiter auto-scaling (typst#6410)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Improve number lexing (typst#5969)

* Report errors in external files (typst#6308)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Table multiple headers and subheaders (typst#6168)

* Use the shaper in math (typst#6336)

* Standardize trailing slashes in docs route paths (typst#6420)

* Make a more descriptive definition of `module` (typst#6380)

* Specify which CSL style is not suitable for bibliographies (typst#6306)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Adjust source file API surface (typst#6423)

* Do not force `math.mid` elements to have the Large math class (typst#5980)

* List both YAML file extensions in bibliography docs (typst#6426)

* Fix panic when test source is not found in world (typst#6428)

* Use `codex::ModifierSet` (typst#6159)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Render `#super` as `<sup>`, `#sub` as `<sub>` in HTML (typst#6422)

* Warning when watching stdin (typst#6381)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Fix untidy Cargo.lock

* Warn when using variable fonts (typst#6425)

* Check that all translation files are added to TRANSLATIONS and ends with newline (typst#6424)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Unify `EvalMode` and `LexMode` into `SyntaxMode` (typst#6432)

* Consume `data` argument in `pdf.embed()` (typst#6435)

* Better error message for compile time string interning failure (typst#6439)

* Ensure that label repr is syntactically valid (typst#6456)

* Hint for label in both document and bibliography (typst#6457)

* Prefer `.yaml` over `.yml` in the docs (typst#6436)

* Fix align link in layout documentation (typst#6451)

* Fix param autocompletion false positive (typst#6475)

* Encode empty attributes with shorthand syntax

* Add `Duration::decompose`

* Generic casting for `Axes<T>`

* More type-safe color conversions

* Add  `typst_utils::display`

* Support for generating native functions at runtime

* Typed HTML API (typst#6476)

* Consistent codepoint formatting in HTML and PDF error messages

* Test runner support for HTML export errors

* Turn non-empty void element into export error

* Handle pre elements that start with a newline

* Extract `write_children` function

* Properly handle raw text elements

* Fix stroke cap of shapes with partial stroke (typst#5688)

* Adding Croatian translations entries (typst#6413)

* Rewrite `outline.indent` example (typst#6383)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Use ICU data to check if accent is bottom (typst#6393)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Add docs for `std` module (typst#6407)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Improve equation reference example (typst#6481)

* Add page reference customization example (typst#6480)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Bump `krilla` to current Git version (typst#6488)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Check that git tree is clean after build (typst#6495)

* Also fix encoding of `<textarea>` (typst#6497)

* Minor fixes to doc comments (typst#6500)

* Fix typos in page-setup.md (typst#6499)

* Support `in` operator on strings and modules (typst#6498)

* Consistent sizing for `html.frame` (typst#6505)

* Allow deprecating symbol variants (typst#6441)

* Disallow empty labels and references (typst#5776) (typst#6332)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Fix nested HTML frames (typst#6509)

* Basic support for text decoration functions in HTML (typst#6510)

* Improve sentence in guide for LaTeX users (typst#6511)

* Sort line items by logical order when constructing frame (typst#5887)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Fix panic when sampling across two coincident gradient stops (typst#6166)

* Bump `typst-dev-assets` (typst#6514)

* Acknowledgements (typst#6528)

* Support HTML tests in test-helper extension (typst#6504)

* Fix typo in Advanced Styling docs tutorial (typst#6517)

* Fix typo in PDF standard CLI help (typst#6518)

* Fix typo in PDF standard CLI help part 2 (typst#6531)

* Fix minor typo in `array.product` docs (typst#6532)

* Fix typos in calc module docs (typst#6535)

* Use "subs" and "sups" font features for typographic scripts (typst#5777)

* Use punctuation math class for Arabic comma (typst#6537)

* Remove duplicate language computation (typst#6557)

* Fix typo in PackageStorage (typst#6556)

* Fix nightly warnings (typst#6558)

* Fix minor typo in function docs (typst#6542)

* Refer to json function instead of deprecated json.decode in groups docs (typst#6552)

* Rewrite foundations of native elements (typst#6547)

* Target-specific native show rules (typst#6569)

* Construct library via extension trait instead of default & inherent impl (typst#6576)

* Move `html` module to `typst-html` crate (typst#6577)

* Fix typo of Typst domain in quote docs (typst#6573)

* Anti-alias clip paths (typst#6570)

* Use "displayed" instead of "repeated" to avoid ambiguity in numbering docs (typst#6565)

* Ignore spans when checking for RawElem equality (typst#6560)

* Add `default` argument for `str.first` and `str.last` (typst#6554)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Add completions subcommand (typst#6568)

* Update Swedish translations based on defaults used for LaTeX and cleveref (typst#6519)

* Move math styling to codex and add `math.scr` (typst#6309)

* More consistent `Packed<T>` to `Content` conversion methods (typst#6579)

* Support images in HTML export (typst#6578)

* Fix tooltip for figure reference (typst#6580)

* Complete movement of HTML export code to `typst-html` (typst#6584)

* Handle `lower` and `upper` in HTML export (typst#6585)

* Deduplicate labels for code completion (typst#6516)

* Fix regression in reference autocomplete (typst#6586)

* Use "whitespace" instead of "space" to denote block-level equation in docs (typst#6591)

* Fix minor typo in text docs (typst#6589)

* Rephrase docs for truncation of float/decimal to integer (typst#6543)

* HTML frame improvements (typst#6605)

* Change `enum.item.number` to `Smart` instead of `Option` (typst#6609)

* Support setting fonts repeatedly with different `covers` (typst#6604)

* Support intra-doc links in HTML (typst#6602)

* Partially automate span assignment in native show rule (typst#6613)

* Bump `zip` dependency (typst#6615)

* Restore timing scopes for native show rules (typst#6616)

* Slightly improve selector docs (typst#6544)

* Add show rule for smallcaps in HTML (typst#6600)

* Mention Tinymist in README.md (typst#6601)

* Fix documentation oneliners (typst#6608)

* Add rust-analyzer to flake devShell (typst#6618)

* Add Lithuanian translations (typst#6587)

* Bump CI Rust to 1.88

* Bump MSRV to 1.88

* Migrate to 2024 edition

* Fix 2024 clippy warnings

* Yeet `if_chain` macro

* Reformat with 2024 edition

* Add support for PDF embedding (typst#6623)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Add `pdf` extension to image autocompletions (typst#6643)

* Fix bounding box computation for lines in curves (typst#6647)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Lint for iterations over hash types (typst#6652)

* Create constructor methods for manifest types (typst#6625)

* Remove unnecessary `comemo` dependency in `typst-syntax` (typst#6668)

* Remove duplicate center alignment style for equations (typst#6667)

* Fix incorrect `vline.x` docs (typst#6657)

* Miscellaneous minor docs improvements (typst#6651)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Allow explicit autocomplete immediately after comma and colon (typst#6550)

* Improve Guide for LaTeX users, Query Function, and replace invisible emojis (typst#6620)

Co-authored-by: PgBiel <9021226+PgBiel@users.noreply.github.com>
Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Hint that deprecated items will be removed in `0.15.0` (typst#6617)

* Specify the standard smart quotes for `Arabic` (typst#6626)

* Use `rustc-hash` for hash maps and sets (typst#6678)

* Faster constraint checking in comemo (bumps comemo & krilla) (typst#6683)

* Add `--target` argument for `typst query` (typst#6405)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Require parentheses in all function-like sub/superscripts (typst#6442)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Fix several wrong anchors in `$` docs link resolution  (typst#6684)

* Add `cargo testit` alias for running integration tests (typst#6682)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Update guides welcome text to refer to list instead of specific guides (typst#6685)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Prevent broken glyph assemblies when font data is incorrect (typst#6688)

* Allow custom element names in HTML tag syntax  (typst#6676)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Add interface to disable timer (typst#6695)

Co-authored-by: Derived Cat <hooyuser@outlook.com>

* Add support for drawing COLR glyphs in SVG export (typst#6693)

* Apply aspect ratio correction for linear gradients in PDF export (typst#6689)

* Wrap raw blocks in `<code>` tag additionally to `<pre>` tag (typst#6701)

* Support for raw syntax highlighting in HTML export (typst#6691)

* Ensure that whitespace is not collapsed in inline raw blocks (typst#6703)

* Show aliases of citation styles in docs and completions (typst#6696)

* Correct CeTZ spelling (typst#6706)

* Add `title` element (typst#5618)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Make HTML data structures cheaper to clone (typst#6708)

* Move `par`, `box`, and `block` to show rules in HTML export (typst#6709)

* Support smartquotes in HTML export (typst#6710)

Co-authored-by: Malo <57839069+MDLC01@users.noreply.github.com>

* Avoid dangling reference output for HTML tests (typst#6711)

* Support multiple fonts in math (typst#6365)

* Add link to position field of grid.hline and grid.vline docs (typst#6670)

* Rename `pdf.embed` to `pdf.attach` (typst#6705)

* Include numbering in PDF bookmark (typst#6622)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Document escaping semicolon, valid identifiers, and `state` tips (typst#6674)

Co-authored-by: Andrew Voynov <37143421+Andrew15-5@users.noreply.github.com>
Co-authored-by: Yaksher <yaksher.git@gmail.com>
Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Ensure table headers trigger rowbreak (typst#6687)

* Fix phrasing of iff (if and only if) in docs (typst#6713)

* Remove redundant "This can be" from stroke docs of curve and polygon (typst#6715)

* Fix curve docs for fill (refer to curve instead of rectangle) (typst#6714)

* Add span to `html.frame` node (typst#6716)

* Fix return type of `missing_method` (typst#6718)

* Encoding fixes for HTML raw text elements (typst#6720)

* Update RelativeTo to include tiling in docs (typst#6730)

* Add missing "the" for cmyk function of color docs (typst#6731)

* Remove use of "last" and "end" for conic gradient circle docs (typst#6733)

* Fix broken links in docs (typst#6734)

* Simplify links in docs (typst#6732)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Bump hayro and krilla (typst#6741)

* Deduplicate fallback smart quotes (typst#6747)

* Move `is_inline` to `HtmlElem` (typst#6748)

* Move grid cell locator creation to GridLayouter (typst#6746)

* HTML whitespace protection (typst#6750)

* Improve code snippets in Table Guide (typst#6658)

* More accessible color scheme for raw blocks (typst#6754)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Use `stylistic-set: 1` in favor of `ss01` in docs and tests (typst#6766)

* Implement fraction styles: vertical, skewed, and horizontal. (typst#6672)

* Bump Rust to 1.89 in CI (typst#6775)

Co-authored-by: Drodt <daniel.drodt@tu-darmstadt.de>
Co-authored-by: Daniel Drodt <132357467+Drodt@users.noreply.github.com>

* Fix typo in doc on quotes parameter of smartquote (typst#6779)

* Fix logical order in bidirectional lines (typst#6796)

* Extract `trim_weak_spacing` function (typst#6797)

* Separate items for hyphens, fixing style of repeated hyphen (typst#6798)

* Fix Unicode mapping of hyphenation artifacts (typst#6799)

* Do not consider default ignorables when picking last resort font (typst#6805)

* Compute width of shaped text on-demand (typst#6806)

* Fix `sub` and `super` oneliners (typst#6791)

* Ensure that hyphenation is possible after a tag (typst#6807)

* Make links to `$grid` in `table` docs more specific (typst#6776)

Co-authored-by: PgBiel <9021226+PgBiel@users.noreply.github.com>

* Fix `repr` of `foo.with(..)` (typst#6773)

* Fix case in docs serialization (typst#6808)

* Add links and examples in the docs of `str` (typst#6751)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Hash page instead of frame for watch command (typst#6810)

* Update nix flake and use nixfmt (typst#6827)

* Update & fix tutorial part 3 & 4 example code (typst#6778)

* Improve docs on customizing `raw` (typst#6000)

Co-authored-by: Malo <57839069+MDLC01@users.noreply.github.com>
Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Better handle large numbers (u128/i128) in deserialization (typst#6836)

* Follow the comment on setting the `State`'s mask (typst#6642)

* Allow augment line at the beginning and end of a matrix (typst#5806)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Fix slicing last n elements using count (typst#6838)

* Fix auto hanging-indent for centered headings (typst#6839)

* Use rust-analyzer from fenix toolchain in flake (typst#6826)

* Type safety for logical indices in line layout (typst#6848)

* Load linked bitmap images in SVG images (typst#6794)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Fix CJ-Latin space at manual line breaks (typst#6700)

Co-authored-by: Laurenz Mädje <laurmaedje@gmail.com>

* Allow multi-character symbols (typst#6489)

Co-authored-by: Max <max@mkor.je>
Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Keep end of line whitespace glyphs (typst#6866)

* Fix punctuation in HTML placeholder (typst#6854)

* Unify and document the behaviours of `{json,yaml,toml,cbor}.encode` (typst#6743)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Improve docs of various numbering parameters (typst#6757)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Document and test `Sides<T>` parameters (typst#6862)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Remove unused `Styles::set_family` (typst#6879)

* Make clear that `Content::query_first` is naive (typst#6880)

* Ensure correct tag nesting with grouping rules (typst#6881)

* Avoid breaking after an empty frame (typst#6335)

* Add test for default ignorables before a breakpoint (typst#6782)

* Fix typos (typst#6878)

* Improve the docs on function params of `array.{sorted,dedup}` (typst#6756)

* Add a link from `math.vec` to `math.{arrow,bold}` in docs (typst#6867)

* Add a disclaimer about embedding PDFs (typst#6888)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Improve examples in the docs for under/over functions (typst#6889)

* Improve docs of `Celled<T>` params of `table` and `grid` (typst#6764)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Fix off by one in tag expansion (typst#6900)

* More useful `Debug` impls for `Tag` and `Location` (typst#6901)

* Fix potential crash in `Debug` impl of `Property` (typst#6902)

* Fix `Debug` impl for end tags (typst#6906)

* Make `select_where!` usable outside of typst-library (typst#6910)

* Fix footnote links in presence of styling (typst#6912)

* Consistently ignore styles for tags (typst#6911)

* Expand tags even a bit more around groupings (typst#6909)

* Don't warn for zero-sized horizontal spacing in HTML export

* Use `singleton!` for `HElem::hole`

* Add way to attach role to closest element in HTML export

* Add logical parent mechanism to HTML export

* Generalize mechanism for root styles to HTML export

* Support footnotes in HTML export

* Add `default` argument to `array.join` (typst#6932)

* Replace the non-existent `$math.arrow` with `$math.accent` in the docs for vector (typst#6918)

* Initial Hayagriva bump (typst#6920)

Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Use different colors for object keys and string-based values in JSON listings (typst#6873)

* Support for outline in HTML (typst#6606)

* Use Title Case for Doc Pages (typst#6936)

* Improve the docs for dictionary (typst#6899)

* Add an illustration for `par.{leading,spacing}` in docs (typst#6915)

Co-authored-by: Andrew Voynov <37143421+Andrew15-5@users.noreply.github.com>
Co-authored-by: Laurenz <laurmaedje@gmail.com>

* Initial plan

---------

Co-authored-by: Sam Ireson <107627922+samuelireson@users.noreply.github.com>
Co-authored-by: PgBiel <9021226+PgBiel@users.noreply.github.com>
Co-authored-by: Ian Wrzesinski <133046678+wrzian@users.noreply.github.com>
Co-authored-by: cAttte <26514199+cAttte@users.noreply.github.com>
Co-authored-by: Andrew Voynov <37143421+Andrew15-5@users.noreply.github.com>
Co-authored-by: Laurenz <laurmaedje@gmail.com>
Co-authored-by: Tobias Schmitz <tobiasschmitz2001@gmail.com>
Co-authored-by: Max <max@mkor.je>
Co-authored-by: 3w36zj6 <52315048+3w36zj6@users.noreply.github.com>
Co-authored-by: Malo <57839069+MDLC01@users.noreply.github.com>
Co-authored-by: T0mstone <39707032+T0mstone@users.noreply.github.com>
Co-authored-by: Lachlan Kermode <lachiekermode@gmail.com>
Co-authored-by: Y.D.X. <73375426+YDX-2147483647@users.noreply.github.com>
Co-authored-by: Ilia <43654815+istudyatuni@users.noreply.github.com>
Co-authored-by: Noam Zaks <63877260+noamzaks@users.noreply.github.com>
Co-authored-by: Wannes Malfait <46323945+WannesMalfait@users.noreply.github.com>
Co-authored-by: Ivica Nakić <ssemigr@gmail.com>
Co-authored-by: +merlan #flirora <flirora@flirora.xyz>
Co-authored-by: Connor K <sigstackfault@gmail.com>
Co-authored-by: Said A. <47973576+Daaiid@users.noreply.github.com>
Co-authored-by: Florian Bohlken <flibbo@gmail.com>
Co-authored-by: Robin <mewmew@users.noreply.github.com>
Co-authored-by: Adrián Delgado <11708972+adriandelgado@users.noreply.github.com>
Co-authored-by: frozolotl <44589151+frozolotl@users.noreply.github.com>
Co-authored-by: Jassiel Ovando <jassielovando@protonmail.com>
Co-authored-by: Patrick Massot <patrickmassot@free.fr>
Co-authored-by: Erik <tinger@tinger.dev>
Co-authored-by: pog102 <85764555+pog102@users.noreply.github.com>
Co-authored-by: Laurenz Stampfl <47084093+LaurenzV@users.noreply.github.com>
Co-authored-by: Niklas Eicker <git@nikl.me>
Co-authored-by: Marcono1234 <Marcono1234@users.noreply.github.com>
Co-authored-by: Igor Khanin <igor@khanin.biz>
Co-authored-by: hpcfzl <hopcfizl@gmail.com>
Co-authored-by: zefr0x <65136727+zefr0x@users.noreply.github.com>
Co-authored-by: Abdul-Rahman Sibahi <asibahi@users.noreply.github.com>
Co-authored-by: 枚鴉 <ling@omots.io>
Co-authored-by: Myriad-Dreamin <35292584+Myriad-Dreamin@users.noreply.github.com>
Co-authored-by: Derived Cat <hooyuser@outlook.com>
Co-authored-by: Sebastian Eberle <152992757+sebaseb98@users.noreply.github.com>
Co-authored-by: Johann Birnick <6528009+jbirnick@users.noreply.github.com>
Co-authored-by: Yaksher <yaksher.git@gmail.com>
Co-authored-by: Tau <git@alice-carroll.pet>
Co-authored-by: Martin Haug <mhaug@live.de>
Co-authored-by: Théophile Cailliau <tjbcg@pm.me>
Co-authored-by: Drodt <daniel.drodt@tu-darmstadt.de>
Co-authored-by: Daniel Drodt <132357467+Drodt@users.noreply.github.com>
Co-authored-by: ultimatile <ultimatile@users.noreply.github.com>
Co-authored-by: Poh <167305720+pohlrabi404@users.noreply.github.com>
Co-authored-by: Clemens Koza <clemens.koza@gmx.at>
Co-authored-by: Siddhant Agarwal <68201519+siddhantdev@users.noreply.github.com>
Co-authored-by: Philipp Niedermayer <eltos@outlook.de>
Co-authored-by: Toon Verstraelen <Toon.Verstraelen@UGent.be>
Co-authored-by: Eric Biedert <github@ericbiedert.de>
Co-authored-by: Jan Romann <jan.romann@uni-bremen.de>
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants