dev: update nightly (#2149)
Some checks are pending
tinymist::ci / prepare-build (push) Waiting to run
tinymist::ci / announce (push) Blocked by required conditions
tinymist::ci / build (push) Blocked by required conditions
tinymist::ci / Duplicate Actions Detection (push) Waiting to run
tinymist::ci / Check Clippy, Formatting, Completion, Documentation, and Tests (Linux) (push) Waiting to run
tinymist::ci / Check Minimum Rust version and Tests (Windows) (push) Waiting to run

Update typst to
b14c08e97a
This commit is contained in:
ParaN3xus 2025-10-05 16:59:54 +08:00 committed by GitHub
parent 9184ef097a
commit bf3d8762da
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
10 changed files with 59 additions and 92 deletions

88
Cargo.lock generated
View file

@ -242,19 +242,6 @@ dependencies = [
"unscanny",
]
[[package]]
name = "biblatex"
version = "0.11.0"
source = "git+https://github.com/typst/biblatex.git#4ed6a780d878e76512e41ccfaa899e34f5589f04"
dependencies = [
"paste",
"roman-numerals-rs",
"strum 0.27.2",
"unic-langid",
"unicode-normalization",
"unscanny",
]
[[package]]
name = "bincode"
version = "1.3.3"
@ -516,15 +503,6 @@ dependencies = [
"half",
]
[[package]]
name = "citationberg"
version = "0.5.0"
source = "git+https://github.com/typst/citationberg.git?rev=35cc83fb325d22c9b5bd5c7fc1d8e79897308076#35cc83fb325d22c9b5bd5c7fc1d8e79897308076"
dependencies = [
"quick-xml",
"serde",
]
[[package]]
name = "citationberg"
version = "0.6.1"
@ -1632,35 +1610,15 @@ dependencies = [
"hashbrown 0.14.5",
]
[[package]]
name = "hayagriva"
version = "0.8.1"
source = "git+https://github.com/typst/hayagriva?rev=03ae2acf#03ae2acf168e65604e74f0361e74ba4ef7689f16"
dependencies = [
"biblatex 0.11.0 (git+https://github.com/typst/biblatex.git)",
"ciborium",
"citationberg 0.5.0",
"indexmap 2.11.4",
"numerals",
"paste",
"serde",
"serde_yaml",
"thiserror 1.0.69",
"unic-langid",
"unicode-segmentation",
"unscanny",
"url",
]
[[package]]
name = "hayagriva"
version = "0.9.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "1cb69425736f184173b3ca6e27fcba440a61492a790c786b1c6af7e06a03e575"
dependencies = [
"biblatex 0.11.0 (registry+https://github.com/rust-lang/crates.io-index)",
"biblatex 0.11.0",
"ciborium",
"citationberg 0.6.1",
"citationberg",
"indexmap 2.11.4",
"paste",
"roman-numerals-rs",
@ -3496,7 +3454,7 @@ dependencies = [
[[package]]
name = "reflexo"
version = "0.6.1-rc3"
source = "git+https://github.com/ParaN3xus/typst.ts/?rev=0272834031acd7002413bf68b166dddcc7f7cdb5#0272834031acd7002413bf68b166dddcc7f7cdb5"
source = "git+https://github.com/ParaN3xus/typst.ts/?branch=nightly#0272834031acd7002413bf68b166dddcc7f7cdb5"
dependencies = [
"base64",
"bitvec",
@ -3522,7 +3480,7 @@ dependencies = [
[[package]]
name = "reflexo-typst"
version = "0.6.1-rc3"
source = "git+https://github.com/ParaN3xus/typst.ts/?rev=0272834031acd7002413bf68b166dddcc7f7cdb5#0272834031acd7002413bf68b166dddcc7f7cdb5"
source = "git+https://github.com/ParaN3xus/typst.ts/?branch=nightly#0272834031acd7002413bf68b166dddcc7f7cdb5"
dependencies = [
"codespan-reporting",
"comemo",
@ -3554,7 +3512,7 @@ dependencies = [
[[package]]
name = "reflexo-typst2vec"
version = "0.6.1-rc3"
source = "git+https://github.com/ParaN3xus/typst.ts/?rev=0272834031acd7002413bf68b166dddcc7f7cdb5#0272834031acd7002413bf68b166dddcc7f7cdb5"
source = "git+https://github.com/ParaN3xus/typst.ts/?branch=nightly#0272834031acd7002413bf68b166dddcc7f7cdb5"
dependencies = [
"bitvec",
"comemo",
@ -3582,7 +3540,7 @@ dependencies = [
[[package]]
name = "reflexo-vec2svg"
version = "0.6.1-rc3"
source = "git+https://github.com/ParaN3xus/typst.ts/?rev=0272834031acd7002413bf68b166dddcc7f7cdb5#0272834031acd7002413bf68b166dddcc7f7cdb5"
source = "git+https://github.com/ParaN3xus/typst.ts/?branch=nightly#0272834031acd7002413bf68b166dddcc7f7cdb5"
dependencies = [
"base64",
"comemo",
@ -4942,7 +4900,7 @@ dependencies = [
"dirs",
"ecow",
"ena",
"hayagriva 0.8.1",
"hayagriva",
"hex",
"if_chain",
"indexmap 2.11.4",
@ -5465,7 +5423,7 @@ dependencies = [
[[package]]
name = "typst"
version = "0.14.0"
source = "git+https://github.com/ParaN3xus/typst.git?rev=575b4b779c29bffc439513491ffbeb4ed917bcc7#575b4b779c29bffc439513491ffbeb4ed917bcc7"
source = "git+https://github.com/ParaN3xus/typst.git?branch=nightly#575b4b779c29bffc439513491ffbeb4ed917bcc7"
dependencies = [
"comemo",
"ecow",
@ -5484,7 +5442,7 @@ dependencies = [
[[package]]
name = "typst-ansi-hl"
version = "0.4.0"
source = "git+https://github.com/ParaN3xus/typst-ansi-hl.git?rev=e1123242c62d3ca5da7fb4e7ec0a00bf2aafb614#e1123242c62d3ca5da7fb4e7ec0a00bf2aafb614"
source = "git+https://github.com/ParaN3xus/typst-ansi-hl.git?branch=nightly#e1123242c62d3ca5da7fb4e7ec0a00bf2aafb614"
dependencies = [
"ansi_colours",
"syntect",
@ -5502,7 +5460,7 @@ source = "git+https://github.com/typst/typst-assets?rev=fbf00f9#fbf00f9539fdb082
[[package]]
name = "typst-eval"
version = "0.14.0"
source = "git+https://github.com/ParaN3xus/typst.git?rev=575b4b779c29bffc439513491ffbeb4ed917bcc7#575b4b779c29bffc439513491ffbeb4ed917bcc7"
source = "git+https://github.com/ParaN3xus/typst.git?branch=nightly#575b4b779c29bffc439513491ffbeb4ed917bcc7"
dependencies = [
"comemo",
"ecow",
@ -5521,7 +5479,7 @@ dependencies = [
[[package]]
name = "typst-html"
version = "0.14.0"
source = "git+https://github.com/ParaN3xus/typst.git?rev=575b4b779c29bffc439513491ffbeb4ed917bcc7#575b4b779c29bffc439513491ffbeb4ed917bcc7"
source = "git+https://github.com/ParaN3xus/typst.git?branch=nightly#575b4b779c29bffc439513491ffbeb4ed917bcc7"
dependencies = [
"bumpalo",
"comemo",
@ -5541,7 +5499,7 @@ dependencies = [
[[package]]
name = "typst-layout"
version = "0.14.0"
source = "git+https://github.com/ParaN3xus/typst.git?rev=575b4b779c29bffc439513491ffbeb4ed917bcc7#575b4b779c29bffc439513491ffbeb4ed917bcc7"
source = "git+https://github.com/ParaN3xus/typst.git?branch=nightly#575b4b779c29bffc439513491ffbeb4ed917bcc7"
dependencies = [
"az",
"bumpalo",
@ -5575,7 +5533,7 @@ dependencies = [
[[package]]
name = "typst-library"
version = "0.14.0"
source = "git+https://github.com/ParaN3xus/typst.git?rev=575b4b779c29bffc439513491ffbeb4ed917bcc7#575b4b779c29bffc439513491ffbeb4ed917bcc7"
source = "git+https://github.com/ParaN3xus/typst.git?branch=nightly#575b4b779c29bffc439513491ffbeb4ed917bcc7"
dependencies = [
"az",
"bitflags 2.9.4",
@ -5589,7 +5547,7 @@ dependencies = [
"flate2",
"fontdb 0.23.0",
"glidesort",
"hayagriva 0.9.1",
"hayagriva",
"hayro-syntax",
"icu_properties 1.5.1",
"icu_provider 1.5.0",
@ -5640,7 +5598,7 @@ dependencies = [
[[package]]
name = "typst-macros"
version = "0.14.0"
source = "git+https://github.com/ParaN3xus/typst.git?rev=575b4b779c29bffc439513491ffbeb4ed917bcc7#575b4b779c29bffc439513491ffbeb4ed917bcc7"
source = "git+https://github.com/ParaN3xus/typst.git?branch=nightly#575b4b779c29bffc439513491ffbeb4ed917bcc7"
dependencies = [
"heck",
"proc-macro2",
@ -5651,7 +5609,7 @@ dependencies = [
[[package]]
name = "typst-pdf"
version = "0.14.0"
source = "git+https://github.com/ParaN3xus/typst.git?rev=575b4b779c29bffc439513491ffbeb4ed917bcc7#575b4b779c29bffc439513491ffbeb4ed917bcc7"
source = "git+https://github.com/ParaN3xus/typst.git?branch=nightly#575b4b779c29bffc439513491ffbeb4ed917bcc7"
dependencies = [
"az",
"bytemuck",
@ -5676,7 +5634,7 @@ dependencies = [
[[package]]
name = "typst-realize"
version = "0.14.0"
source = "git+https://github.com/ParaN3xus/typst.git?rev=575b4b779c29bffc439513491ffbeb4ed917bcc7#575b4b779c29bffc439513491ffbeb4ed917bcc7"
source = "git+https://github.com/ParaN3xus/typst.git?branch=nightly#575b4b779c29bffc439513491ffbeb4ed917bcc7"
dependencies = [
"arrayvec",
"bumpalo",
@ -5693,7 +5651,7 @@ dependencies = [
[[package]]
name = "typst-render"
version = "0.14.0"
source = "git+https://github.com/ParaN3xus/typst.git?rev=575b4b779c29bffc439513491ffbeb4ed917bcc7#575b4b779c29bffc439513491ffbeb4ed917bcc7"
source = "git+https://github.com/ParaN3xus/typst.git?branch=nightly#575b4b779c29bffc439513491ffbeb4ed917bcc7"
dependencies = [
"bytemuck",
"comemo",
@ -5723,7 +5681,7 @@ dependencies = [
[[package]]
name = "typst-svg"
version = "0.14.0"
source = "git+https://github.com/ParaN3xus/typst.git?rev=575b4b779c29bffc439513491ffbeb4ed917bcc7#575b4b779c29bffc439513491ffbeb4ed917bcc7"
source = "git+https://github.com/ParaN3xus/typst.git?branch=nightly#575b4b779c29bffc439513491ffbeb4ed917bcc7"
dependencies = [
"base64",
"comemo",
@ -5763,7 +5721,7 @@ dependencies = [
[[package]]
name = "typst-syntax"
version = "0.14.0"
source = "git+https://github.com/ParaN3xus/typst.git?rev=575b4b779c29bffc439513491ffbeb4ed917bcc7#575b4b779c29bffc439513491ffbeb4ed917bcc7"
source = "git+https://github.com/ParaN3xus/typst.git?branch=nightly#575b4b779c29bffc439513491ffbeb4ed917bcc7"
dependencies = [
"ecow",
"rustc-hash 2.1.1",
@ -5792,7 +5750,7 @@ dependencies = [
[[package]]
name = "typst-timing"
version = "0.14.0"
source = "git+https://github.com/ParaN3xus/typst.git?rev=575b4b779c29bffc439513491ffbeb4ed917bcc7#575b4b779c29bffc439513491ffbeb4ed917bcc7"
source = "git+https://github.com/ParaN3xus/typst.git?branch=nightly#575b4b779c29bffc439513491ffbeb4ed917bcc7"
dependencies = [
"parking_lot",
"serde",
@ -5816,7 +5774,7 @@ dependencies = [
[[package]]
name = "typst-utils"
version = "0.14.0"
source = "git+https://github.com/ParaN3xus/typst.git?rev=575b4b779c29bffc439513491ffbeb4ed917bcc7#575b4b779c29bffc439513491ffbeb4ed917bcc7"
source = "git+https://github.com/ParaN3xus/typst.git?branch=nightly#575b4b779c29bffc439513491ffbeb4ed917bcc7"
dependencies = [
"once_cell",
"portable-atomic",
@ -5845,7 +5803,7 @@ dependencies = [
[[package]]
name = "typstyle-core"
version = "0.13.17"
source = "git+https://github.com/ParaN3xus/typstyle/?rev=8af51a65fa3ea2b210337c126fd800ca62a5ac7d#8af51a65fa3ea2b210337c126fd800ca62a5ac7d"
source = "git+https://github.com/ParaN3xus/typstyle/?branch=nightly#8af51a65fa3ea2b210337c126fd800ca62a5ac7d"
dependencies = [
"ecow",
"itertools 0.14.0",

View file

@ -99,7 +99,7 @@ rpds = "1"
biblatex = "0.10"
cmark-writer = { version = "=0.7.7", features = ["gfm"] }
docx-rs = { version = "0.4.18-rc19", git = "https://github.com/Myriad-Dreamin/docx-rs", default-features = false, rev = "db49a729f68dbdb9e8e91857fbb1c3d414209871" }
hayagriva = { git = "https://github.com/typst/hayagriva", rev = "03ae2acf" }
hayagriva = "0.9.1"
hex = "0.4.3"
flate2 = "1"
# typst can only support these formats.
@ -275,19 +275,19 @@ extend-exclude = ["/.git", "fixtures"]
# These patches use a different version of `typst`, which only exports some private functions and information for code analysis.
#
# A regular build MUST use `tag` or `rev` to specify the version of the patched crate to ensure stability.
typst = { git = "https://github.com/ParaN3xus/typst.git", rev = "575b4b779c29bffc439513491ffbeb4ed917bcc7" }
typst-macros = { git = "https://github.com/ParaN3xus/typst.git", rev = "575b4b779c29bffc439513491ffbeb4ed917bcc7" }
typst-library = { git = "https://github.com/ParaN3xus/typst.git", rev = "575b4b779c29bffc439513491ffbeb4ed917bcc7" }
typst-html = { git = "https://github.com/ParaN3xus/typst.git", rev = "575b4b779c29bffc439513491ffbeb4ed917bcc7" }
typst-timing = { git = "https://github.com/ParaN3xus/typst.git", rev = "575b4b779c29bffc439513491ffbeb4ed917bcc7" }
typst-svg = { git = "https://github.com/ParaN3xus/typst.git", rev = "575b4b779c29bffc439513491ffbeb4ed917bcc7" }
typst-render = { git = "https://github.com/ParaN3xus/typst.git", rev = "575b4b779c29bffc439513491ffbeb4ed917bcc7" }
typst-pdf = { git = "https://github.com/ParaN3xus/typst.git", rev = "575b4b779c29bffc439513491ffbeb4ed917bcc7" }
typst-syntax = { git = "https://github.com/ParaN3xus/typst.git", rev = "575b4b779c29bffc439513491ffbeb4ed917bcc7" }
typst-eval = { git = "https://github.com/ParaN3xus/typst.git", rev = "575b4b779c29bffc439513491ffbeb4ed917bcc7" }
typst = { git = "https://github.com/ParaN3xus/typst.git", branch = "nightly" }
typst-macros = { git = "https://github.com/ParaN3xus/typst.git", branch = "nightly" }
typst-library = { git = "https://github.com/ParaN3xus/typst.git", branch = "nightly" }
typst-html = { git = "https://github.com/ParaN3xus/typst.git", branch = "nightly" }
typst-timing = { git = "https://github.com/ParaN3xus/typst.git", branch = "nightly" }
typst-svg = { git = "https://github.com/ParaN3xus/typst.git", branch = "nightly" }
typst-render = { git = "https://github.com/ParaN3xus/typst.git", branch = "nightly" }
typst-pdf = { git = "https://github.com/ParaN3xus/typst.git", branch = "nightly" }
typst-syntax = { git = "https://github.com/ParaN3xus/typst.git", branch = "nightly" }
typst-eval = { git = "https://github.com/ParaN3xus/typst.git", branch = "nightly" }
typst-ansi-hl = { git = "https://github.com/ParaN3xus/typst-ansi-hl.git", rev = "e1123242c62d3ca5da7fb4e7ec0a00bf2aafb614" }
typstyle-core = { git = "https://github.com/ParaN3xus/typstyle/", rev = "8af51a65fa3ea2b210337c126fd800ca62a5ac7d" }
typst-ansi-hl = { git = "https://github.com/ParaN3xus/typst-ansi-hl.git", branch = "nightly" }
typstyle-core = { git = "https://github.com/ParaN3xus/typstyle/", branch = "nightly" }
# These patches use local `typst` for development.
# typst = { path = "../typst/crates/typst" }
@ -303,9 +303,9 @@ typstyle-core = { git = "https://github.com/ParaN3xus/typstyle/", rev = "8af51a6
# These patches use a different version of `reflexo`.
#
# A regular build MUST use `tag` or `rev` to specify the version of the patched crate to ensure stability.
reflexo = { git = "https://github.com/ParaN3xus/typst.ts/", rev = "0272834031acd7002413bf68b166dddcc7f7cdb5" }
reflexo-typst = { git = "https://github.com/ParaN3xus/typst.ts/", rev = "0272834031acd7002413bf68b166dddcc7f7cdb5" }
reflexo-vec2svg = { git = "https://github.com/ParaN3xus/typst.ts/", rev = "0272834031acd7002413bf68b166dddcc7f7cdb5" }
reflexo = { git = "https://github.com/ParaN3xus/typst.ts/", branch = "nightly" }
reflexo-typst = { git = "https://github.com/ParaN3xus/typst.ts/", branch = "nightly" }
reflexo-vec2svg = { git = "https://github.com/ParaN3xus/typst.ts/", branch = "nightly" }
# These patches use local `reflexo` for development.
# reflexo = { path = "../typst.ts/crates/reflexo/" }

View file

@ -5,9 +5,9 @@ use std::collections::BTreeMap;
use std::sync::Arc;
use ecow::{eco_format, eco_vec, EcoString, EcoVec};
use typst::foundations::{Closure, Func};
use typst::foundations::{Closure, ClosureNode, Func};
use typst::syntax::ast;
use typst::syntax::ast::AstNode;
use typst::syntax::{ast, SyntaxKind};
use typst::utils::LazyHash;
// use super::{BoundChecker, Definition};
@ -276,11 +276,18 @@ fn analyze_closure_signature(
closure: Arc<LazyHash<Closure>>,
add_param: &mut impl FnMut(Interned<ParamTy>),
) {
log::trace!("closure signature for: {:?}", closure.node.kind());
log::trace!(
"closure signature for: {:?}",
match &closure.node {
ClosureNode::Closure(node) => node,
ClosureNode::Context(node) => node,
}
.kind()
);
let closure = &closure.node;
let closure_ast = match closure.kind() {
SyntaxKind::Closure => closure.cast::<ast::Closure>().unwrap(),
let closure_ast = match closure {
ClosureNode::Closure(node) => node.cast::<ast::Closure>().unwrap(),
_ => return,
};

View file

@ -851,6 +851,7 @@ mod tests {
https://typst.app/docs/reference/model/terms/
https://typst.app/docs/reference/model/terms/#definitions-item
https://typst.app/docs/reference/model/title/
https://typst.app/docs/reference/pdf/artifact/
https://typst.app/docs/reference/pdf/attach/
https://typst.app/docs/reference/text/highlight/
https://typst.app/docs/reference/text/linebreak/

View file

@ -18,7 +18,7 @@ input_file: crates/tinymist-query/src/fixtures/completion/element_where.typ
"labelDetails": {
"description": "content | none"
},
"sortText": "000",
"sortText": "001",
"textEdit": {
"newText": "caption: ${1:}",
"range": {

View file

@ -11,7 +11,7 @@ input_file: crates/tinymist-query/src/fixtures/completion/raw_lang.typ
{
"kind": 21,
"label": "Typst",
"sortText": "145",
"sortText": "148",
"textEdit": {
"newText": "typ",
"range": {

View file

@ -11,7 +11,7 @@ input_file: crates/tinymist-query/src/fixtures/completion/raw_lang_middle.typ
{
"kind": 21,
"label": "Typst",
"sortText": "145",
"sortText": "148",
"textEdit": {
"newText": "typ",
"range": {

View file

@ -11,7 +11,7 @@ input_file: crates/tinymist-query/src/fixtures/completion/raw_lang_middle_lower.
{
"kind": 21,
"label": "Typst",
"sortText": "145",
"sortText": "148",
"textEdit": {
"newText": "typ",
"range": {

View file

@ -15,6 +15,7 @@ Ref: `fig:test1`
```typc
figure(
body: [Test1],
alt: none,
placement: none,
scope: "column",
caption: none,

View file

@ -22,7 +22,7 @@ fn test_lsp() {
});
let hash = replay_log(&root.join("neovim"));
insta::assert_snapshot!(hash, @"siphash128_13:5ddf9a21b008a47bc860847fb6695edc");
insta::assert_snapshot!(hash, @"siphash128_13:37494c30b1b74469233b09f063b139a8");
}
{
@ -33,7 +33,7 @@ fn test_lsp() {
});
let hash = replay_log(&root.join("vscode"));
insta::assert_snapshot!(hash, @"siphash128_13:cda309d2e377649fb2b0cd75ad7608c3");
insta::assert_snapshot!(hash, @"siphash128_13:38d2e27c6858270675f5752d89040852");
}
}