Skip to content

feat: add Tagalog (tl_PH) locale for pagination#688

Merged
afc163 merged 5 commits into
react-component:masterfrom
jinrong-ncu:master
May 14, 2026
Merged

feat: add Tagalog (tl_PH) locale for pagination#688
afc163 merged 5 commits into
react-component:masterfrom
jinrong-ncu:master

Conversation

@jinrong-ncu
Copy link
Copy Markdown
Contributor

@jinrong-ncu jinrong-ncu commented May 14, 2026

Summary by CodeRabbit

发布说明

  • 新功能
    • 添加菲律宾塔加洛语本地化支持,为分页用户界面元素提供完整的菲律宾语翻译,包括每页项目数、跳转功能、页码标签及导航按钮等。

Review Change Stack

@vercel
Copy link
Copy Markdown

vercel Bot commented May 14, 2026

Someone is attempting to deploy a commit to the React Component Team on Vercel.

A member of the Team first needs to authorize it.

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 14, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 01e2ff5d-670b-4e80-a2f8-146697bc17b4

📥 Commits

Reviewing files that changed from the base of the PR and between 5b45a61 and c4d72cf.

📒 Files selected for processing (1)
  • src/locale/tl_PH.ts
✅ Files skipped from review due to trivial changes (1)
  • src/locale/tl_PH.ts

概览

新增 src/locale/tl_PH.ts locale 模块,定义并导出 Tagalog(菲律宾语)分页 UI 文本,包括每页项目数、跳转、页码标签和前后导航等文案。

变更

菲律宾语 Locale

层级 / 文件 摘要
菲律宾语 locale 模块
src/locale/tl_PH.ts
导入 PaginationLocale 类型,定义包含分页 UI 元素的 Tagalog 文本对象(如"每页显示项数"、"跳转至"、"页"、"上一页"、"下一页"等),并作为默认导出。

相关 PR

  • react-component/pagination#656:两个 PR 均添加新的 locale 模块,定义并导出 PaginationLocale 分页文本对象(本 PR 为 tl_PH.ts,相关 PR 为 te_IN.ts),在本地化/模块层面直接相关。

  • react-component/pagination#658:两个 PR 都添加新的 src/locale/<lang>_<REGION>.ts 模块,导出 PaginationLocale 类型的 locale 常量,包含分页 UI 字符串映射。

预期代码审查工作量

🎯 1 (简单) | ⏱️ ~3 分钟

🐰 菲律宾语分页歌:
Tagalog 文案如春风和,
兔子跳页笑呵呵,
二十行代码轻飘然,
新 locale 添香阁!

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Title check ⚠️ Warning PR标题声称添加Filipino (fil_PH),但实际更改文件是tl_PH.ts,内容为Tagalog翻译,与标题中的fil_PH不符。 建议将标题改为'feat: add Tagalog (tl_PH) locale for pagination'以准确反映实际变更内容。
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 ESLint

If the error stems from missing dependencies, add them to the package.json file. For unrecoverable errors (e.g., due to private dependencies), disable the tool in the CodeRabbit configuration.

src/locale/tl_PH.ts

Oops! Something went wrong! :(

ESLint: 8.57.1

ESLint couldn't find the plugin "eslint-plugin-react".

(The package "eslint-plugin-react" was not found when loaded as a Node module from the directory "".)

It's likely that the plugin isn't installed correctly. Try reinstalling by running the following:

npm install eslint-plugin-react@latest --save-dev

The plugin "eslint-plugin-react" was referenced from the config file in ".eslintrc.js » /node_modules/.pnpm/@umijs+fabric@4.0.1_postcss@8.5.14/node_modules/@umijs/fabric/dist/eslint.js".

If you still can't figure out the problem, please stop by https://eslint.org/chat/help to chat with the team.

Tip

💬 Introducing Slack Agent: The best way for teams to turn conversations into code.

Slack Agent is built on CodeRabbit's deep understanding of your code, so your team can collaborate across the entire SDLC without losing context.

  • Generate code and open pull requests
  • Plan features and break down work
  • Investigate incidents and troubleshoot customer tickets together
  • Automate recurring tasks and respond to alerts with triggers
  • Summarize progress and report instantly

Built for teams:

  • Shared memory across your entire org—no repeating context
  • Per-thread sandboxes to safely plan and execute work
  • Governance built-in—scoped access, auditability, and budget controls

One agent for your entire SDLC. Right inside Slack.

👉 Get started


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces a new Filipino (Philippines) localization file for the pagination component. The review feedback suggests improving grammatical correctness by adding linkers to numeric phrases, using a more idiomatic term for 'Page Size', and adding a trailing newline for file consistency.

Comment thread src/locale/fil_PH.ts Outdated
Comment thread src/locale/fil_PH.ts Outdated
Comment thread src/locale/tl_PH.ts
jinrong-ncu and others added 3 commits May 14, 2026 14:15
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
@yoyo837
Copy link
Copy Markdown
Member

yoyo837 commented May 14, 2026

Review: Compatibility issue between fil_PH locale and dayjs ecosystem

Thanks for the contribution! Found a compatibility issue that needs discussion:

Core issue: dayjs does not support fil / fil_PH locale

  • dayjs only has tl-ph (Tagalog/Philippines), no fil or fil_PH (source)
  • antd also has no Filipino locale (neither fil_PH nor tl_PH)

If antd integrates this locale in the future, dayjs will not find a matching fil_PH locale, causing date formatting to fall back to English — resulting in mixed English/Filipino text in the pagination component.

Locale naming mismatch

Project Filipino locale name
This PR (rc-pagination) fil_PH
dayjs tl-ph (tl_PH)

The two use different ISO codes: fil (ISO 639-1) vs tl (ISO 639-2/T, Tagalog). In practice, Filipino is based on Tagalog and they refer to the same language.

Suggested approaches

  1. Use tl_PH instead — aligns with dayjs tl-ph, enabling direct integration with antd
  2. Open a PR on dayjs upstream first to add a fil locale, then proceed with this PR
  3. Keep fil_PH as-is — if fil is considered the more standard code, merge this PR first and handle the dayjs mapping separately in antd

I would suggest clarifying the direction before merging to avoid naming inconsistencies during antd integration.

@codecov
Copy link
Copy Markdown

codecov Bot commented May 14, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 99.03%. Comparing base (15341cc) to head (c4d72cf).

Additional details and impacted files
@@           Coverage Diff           @@
##           master     #688   +/-   ##
=======================================
  Coverage   99.03%   99.03%           
=======================================
  Files           3        3           
  Lines         312      312           
  Branches      140      140           
=======================================
  Hits          309      309           
  Misses          3        3           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

- Add Filipino (Tagalog) translation for pagination components.
- Use tl_PH instead of fil_PH to align with the ecosystem standards, ensuring compatibility with dayjs (tl-ph) and antd integration.
@afc163 afc163 merged commit a85aa10 into react-component:master May 14, 2026
7 of 8 checks passed
@yoyo837 yoyo837 changed the title feat: add Filipino (fil_PH) locale for pagination feat: add Tagalog (tl_PH) locale for pagination May 14, 2026
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.

3 participants