Commit graph

10 commits

Author SHA1 Message Date
Myriad-Dreamin
d4d8345166
fix: match special identifiers in calls (#1125) 2025-01-07 14:20:00 +08:00
Myriad-Dreamin
03ac73bd52
feat: change some names of textmate scopes (#1119)
* feat: change some special kind of string tokens

* feat: change some special kind of constant tokens

* feat: change some special kind of keyword tokens

* test: update snapshot
2025-01-07 14:00:21 +08:00
Myriad-Dreamin
e95e4284b1
fix: match brackets in content block recursively (#856)
* feat: only match brackets in content block

* test: update snapshot
2024-11-19 23:28:12 +08:00
Myriad-Dreamin
b1efa88161
feat: improve syntax highlighting (#724)
* dev: simplify if statement handling

* dev: parse blocks in if/for/while more consistently

* feat: improve context expression parsing

* feat: improve context expression parsing

* feat: improve parameter clause parsing
2024-10-22 21:41:20 +08:00
Myriad-Dreamin
24751130a5
feat: parse for clause correctly (#642)
* fix: unchanged snapshots

* feat: parse for clause correctly
2024-10-07 13:13:42 +08:00
Myriad-Dreamin
2e39afde78
fix: better grammar on incomplete AST (#140)
* dev: error tolerance on editing let/show statements

* dev: error tolerance on editing if/show statements

* dev: error tolerance on editing while/for statements

* dev: error tolerance on editing if/while/for statements

* dev: better token for and or not
2024-04-01 01:51:42 +08:00
Myriad-Dreamin
90ef2e6f72
dev: improve punctuation and keyword token kinds (#133)
* dev: improve punctuation and keyword token kinds

* dev: improve punctuation and keyword token kinds
2024-03-30 20:04:34 +08:00
Myriad-Dreamin
2e7c7732dc
feat: mark correct expression boundary on all testing files from typst/typst (#85)
* fix: comment and set rules

* fix: losen for rules

* fix: chore field, escape

* fix: hash termination

* dev: handle math mode

* fix: terminate expressions on right braces

* dev: match spread operator

* dev: remove complex check on if

* dev: add two bugs

* dev: fix if/while conditions

* fix: terminate expressions on right braces 2
2024-03-23 01:19:43 +08:00
Myriad-Dreamin
14ef2e78e2
feat: provide more robust syntax highlight for expressions in markup context (#80)
* dev: robust if syntax

* dev: robust for syntax

* dev: if/for with content blocks

* dev: robust while syntax

* dev: lift identifier matchers

* dev: update test case

* dev: robust call syntax

* dev: robust arrow func syntax

* dev: robust set syntax

* dev: robust show syntax

* dev: robust let syntax

* dev: robust string literal syntax

* dev: robust include syntax

* dev: robust import syntax

* dev: expression continuation

* dev: error tolerance

* dev: robust inline/blocky raw syntax

* dev: chore fixes

* dev: fix call and raw

* dev: fix some markup

* dev: refactor many markup patterns

* dev: final touches

* dev: remove unused dep
2024-03-21 17:52:51 +08:00
Myriad-Dreamin
a3948df5da
feat: init syntax library for function hover tip (#77)
* dev: introduce upstream tooltip

* feat: basic function definition

* feat: init syntax library

* abandon

* build: run syntax building

* fix: let expression

* fix: markup in code

* fix: raw code
2024-03-20 12:18:57 +08:00