Skip to content

chore: update version to 0.13.9 and reflect changes in dependencies #304

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 25, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,23 @@
# Changelog

## v0.13.9 - [2025-05-25]

- Feature: typstyle now evaluates simple constant expressions for table columns. This enhancement allows for better column count calculation in tables. For example, if you have a table with a column count defined as `((1fr,) * 2 + 2 * (auto,)) * 3`, typstyle will now correctly interpret this as 12 columns.

- Feature: typstyle now uses soft wrapping for import items. Import statements with long lists of items will now wrap more compact. This aligns with rustfmt's approach to formatting long import lists.

- Feature: typstyle no longer collapses consecutive spaces in markup by default. This change preserves intentional spacing in markup content, maintaining the author's formatting intentions.

- Feature: typstyle no longer adds padding to the last cell in math alignments. For example, in `cases()` expressions, the formatter will no longer add trailing spaces after the last cell, keeping comments properly aligned without unnecessary padding.

- Enhancement: typstyle now formats tables in most cases, and format headers and footers as tables. This major enhancement provides better support for complex table structures.

- Enhancement: improved detection of table and grid elements. Special rows (`header`, `footer`) and cells (`cell`, `hline`, `vline`) are now recognized without needing the `grid.` or `table.` prefix.

- Bug fix: typstyle now preserves backslashes in single-row aligned math equations. This addresses a missed case from #294 where expressions like `math.equation($ 1 & 2 \ $.body + $ & 4 \ $.body)` would incorrectly have their backslashes removed.

- Bug fix: typstyle now handles escape hatch comments (`@typstyle off`) better in corner cases. Previously, escape hatch did not work for `ArrayItem`, `DictItem`, `Param`, and `DestructuringItem`. Additionally, `@typstyle off` no longer penetrates comments, and when it appears before `Code` or `Math`, it now only applies to the first non-trivial child instead of the whole syntax node.

## v0.13.8 - [2025-05-21]

- Bug fix: typstyle previously will break inline equations if they has alignments. Now it is fixed. It will never add paddings to align inline equations now.
Expand Down
8 changes: 4 additions & 4 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ members = ["crates/*", "tests"]
default-members = ["crates/typstyle"]

[workspace.package]
version = "0.13.8"
version = "0.13.9"
rust-version = "1.83"
edition = "2021"
authors = ["Wenzhuo Liu"]
Expand All @@ -14,8 +14,8 @@ repository = "https://github.com/Enter-tainer/typstyle"
homepage = "https://enter-tainer.github.io/typstyle/"

[workspace.dependencies]
typstyle-core = { path = "crates/typstyle-core", version = "0.13.8" }
typstyle = { path = "crates/typstyle", version = "0.13.8" }
typstyle-core = { path = "crates/typstyle-core", version = "0.13.9" }
typstyle = { path = "crates/typstyle", version = "0.13.9" }
typstyle-consistency = { path = "crates/typstyle-consistency" }

# Used in core
Expand Down
Loading