Conversation
e3b5714 to
5966cd2
Compare
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR adds full support for list markup in the Typst-to-Textlint AST conversion, updates fixtures to reflect sorted keys and new list node shapes, and introduces integration tests for enforcing no trailing periods in list items.
- Introduce a
sortJsonKeyshelper to produce consistent, alphabetically sorted fixture outputs. - Update dozens of fixture files to reflect new list AST nodes and sorted JSON keys.
- Add integration tests and dependency for
textlint-rule-period-in-list-item.
Reviewed Changes
Copilot reviewed 26 out of 26 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| test/unit/update-fixtures.ts | Added sortJsonKeys to normalize AST outputs before writing JSON |
| test/unit/**/*.json (fixtures & AST dumps) | Regenerated fixtures with sorted keys and updated list node ranges |
| test/unit/fixtures/*/input.typ | Added new list-containing fixtures (nested lists, paragraphs) |
| test/integration/linting.test.ts | Imported and configured textlint-rule-period-in-list-item tests |
| test/integration/fixtures/.../main.typ | New smoke fixtures for list-item period rule |
| package.json | Added textlint-rule-period-in-list-item to dependencies |
Comments suppressed due to low confidence (2)
test/integration/linting.test.ts:10
- [nitpick] The aliases
textlintRulePresetJaTechnicalWritingRulesandtextlintRulePresetJaTechnicalWritingRulesConfigare quite verbose. Consider using shorter, descriptive names likejaRulesandjaConfigfor readability.
import {
test/unit/update-fixtures.ts:13
- [nitpick] Consider extracting
sortJsonKeysinto a shared test utilities module so that it can be reused across test files and reduce duplication.
const sortJsonKeys = (obj: any): any => {
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
close #14