Skip to content

feat: add variantOffsets to TolgeeFormat#5

Merged
Anty0 merged 1 commit into
mainfrom
jirikuchynka/qa-checks
Mar 16, 2026
Merged

feat: add variantOffsets to TolgeeFormat#5
Anty0 merged 1 commit into
mainfrom
jirikuchynka/qa-checks

Conversation

@Anty0
Copy link
Copy Markdown
Member

@Anty0 Anty0 commented Mar 16, 2026

Summary

  • Adds variantOffsets field to TolgeeFormat — a map of each plural variant's content start position within the source ICU string
  • Offsets are extracted from the Lezer parser's VariantContent node positions during plural parsing in getTolgeePlurals()
  • Needed by the QA checks feature in tolgee-platform to map issue positions between per-variant and full-ICU coordinate spaces

Expose the character offset of each plural variant's content within the
source ICU string. Offsets are extracted from the Lezer parser's
VariantContent node positions during plural parsing, ensuring they are
always consistent with the variant text extraction.

This is needed by the QA checks feature to map issue positions between
per-variant and full-ICU coordinate spaces.
@Anty0 Anty0 requested review from JanCizmar and dkrizan March 16, 2026 10:50
@Anty0 Anty0 merged commit 9cf3dfe into main Mar 16, 2026
2 checks passed
github-actions Bot pushed a commit that referenced this pull request Mar 17, 2026
# [1.16.0](v1.15.2...v1.16.0) (2026-03-17)

### Features

* add variantOffsets to TolgeeFormat ([#5](#5)) ([9cf3dfe](9cf3dfe))
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.

2 participants