[Good first issue] i18n 审计报告 JSX 属性的实际文案
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 82/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Active
- Tech stack
- bun, react, typescript
- Domain
- internationalization, tooling
Research direction
The attribute matching rule lives in scripts/i18n-audit.ts around lines 22-28, and text extraction and filtering around lines 55-75. Run bun scripts/i18n-audit.ts --json against a temporary JSX fixture containing the aria-label, title and placeholder examples from the issue. Done when the report lists all three literals with their file locations, double-quoted and brace-wrapped strings are both detected, and a short fixture covering a t(...) attribute is added with the existing JSON format unchanged.
Written by the indexing model from the issue text.
Description
问题与复现
在隔离目录里放入以下 JSX fixture,运行 bun scripts/i18n-audit.ts --json。目前只产生一条 attr 命中,text 为 aria-label。title、placeholder 及对应的可见文案都未出现在结果中。
<>
<button aria-label={'Remove selected item'} title={'Open review details'} />
<input placeholder="Search saved studies" />
</>
属性模式把属性名和文案放在不同的捕获组。目前的提取会优先取属性名,并且双引号属性值的形式会漏扫。
在 Windows 和 Bun 1.4.2 上基于 main 的 579395e 验证。
验收标准
- 审计输出报告三条实际文案及对应文件位置。直接引号和花括号里的字符串字面量都可识别。
- 用短 fixture 覆盖上述三条,以及一条走
t(...)的属性,保持现有 JSON 报告格式。
源码起点
认领前可先说明准备完成的范围,再评论 /claim。参与方式见 #7。
- Dominant language
- TypeScript
- Stars
- 206
- Forks
- 37
- Avg merge
- 8h 8m
- Merged PRs (30d)
- 7
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from ydflow/Trail
-
area:desktop bug help wanted
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
-
bug help wanted
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
-
bug good first issue help wanted
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
area:desktop bug good first issue help wanted
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
-
area:desktop bug good first issue help wanted
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
Maintainers usually reply within 1 day
-
[Security]Unauthenticated WebSocket JSON.parse Without Error Handling Leads to Process TerminationOpen
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
nocobase/nocobase#11711 · 1 comment ·
Maintainers usually reply within 1 day
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
Maintainers usually reply within 1 day
-
Y2025: QBI forms print a negative taxable income; Form 8995-A lines 14b/14c check the wrong columnOpen
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 80/100
readest/readest#7903 · 1 comment ·
Maintainers usually reply within 1 day