Skip to content

Conversation

@Alexzjt
Copy link
Contributor

@Alexzjt Alexzjt commented Dec 26, 2025

👀 PR includes

✨ Feature

  • New feature

🎨 Enhance

  • Code style optimization
  • Refactoring
  • Change the UI
  • Improve the performance
  • Type optimization

🐛 Bugfix

  • Solve the issue and close #0

🔧 Chore

  • Test case
  • Docs / demos update
  • CI / workflow
  • Release version
  • Other ()

📝 Description

🖼️ Screenshot

Before After

🔗 Related issue link

🔍 Self-Check before the merge

  • Add or update relevant docs.
  • Add or update relevant demos.
  • Add or update test case.
  • Add or update relevant TypeScript definitions.

@github-actions
Copy link
Contributor

你好 @Alexzjt,非常感谢你的贡献.
为了让代码更健壮, 请根据 贡献指南 补充相应单元测试 (文档改动或其他特殊场景除外), 如果有 API 改动, 请修改 相应的文档.
同时请检查 linttest 相关 CI 是否通过, 如果失败, 请点击 [Details] 按钮查看, 并根据日志修复.

Hello, @Alexzjt, Thanks for your contribution. In order to make the code more robust, please add the corresponding unit tests, and update the docs if there are API changes.
At the same time, please check whether the CI related to lint and test passes. If the CI fails, please click [Details] button to check and repair according to the log.

@github-actions github-actions bot added the pr(fix) bug fix label Dec 26, 2025
@github-actions github-actions bot added the next 2.0-next 版本的问题 label Dec 26, 2025
@gemini-code-assist
Copy link
Contributor

Summary of Changes

Hello @Alexzjt, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

此拉取请求主要修复了 TableSheet 在单元格复用滚动后,系列号单元格及其他普通单元格样式可能出现异常的缺陷。核心改动在于重构了系列号单元格的文本样式获取逻辑,将其上移至基类 TableDataCell 以适应单元格复用机制。此外,还更新了性能对比示例的配置,以启用实验性的单元格复用功能,并修正了一处文档链接。

Highlights

  • 修复系列号单元格样式异常: 解决了在 TableSheet 中,当单元格复用滚动后,系列号单元格样式显示异常的问题。
  • 优化样式获取逻辑: 将系列号单元格的文本样式获取逻辑从 TableSeriesNumberCell 迁移到其父类 TableDataCell 中,确保在单元格复用场景下样式能够正确应用,避免了潜在的样式错误。
  • 更新性能对比示例配置: 在多个性能对比示例中,显式启用了 experimentalReuseCell 特性,并禁用了默认的头部操作图标,以更好地测试和展示单元格复用功能。
  • 文档链接修正: 修复了 base-concept.zh.md 文档中一个示例链接的路径问题。
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

Copy link
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

这个 PR 修复了 TableSheet 在滚动和单元格复用后,序号单元格和普通单元格样式异常的问题。核心改动是将序号单元格的样式逻辑从 TableSeriesNumberCell 移至其父类 TableDataCell 中,通过判断 meta.valueField 来应用正确的样式。这个方法很巧妙地解决了单元格复用时,由于 TableDataCell 实例被复用于渲染序号列而导致样式不正确的问题。此外,PR 还修复了一个文档中的链接问题。整体来看,代码改动清晰、合理。我只发现一个可以改进的小地方,以增强代码的健壮性。

@codecov-commenter
Copy link

codecov-commenter commented Dec 26, 2025

Codecov Report

❌ Patch coverage is 88.88889% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 79.13%. Comparing base (ecdc9c8) to head (d815b1e).
⚠️ Report is 742 commits behind head on next.

Files with missing lines Patch % Lines
packages/s2-core/src/cell/table-data-cell.ts 87.50% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             next    #3272      +/-   ##
==========================================
+ Coverage   75.77%   79.13%   +3.36%     
==========================================
  Files         257      222      -35     
  Lines       11994    12185     +191     
  Branches     2464     2737     +273     
==========================================
+ Hits         9088     9643     +555     
+ Misses       1398      887     -511     
- Partials     1508     1655     +147     

☔ 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.

@github-actions
Copy link
Contributor

Size Change: +17 B (0%)

Total Size: 720 kB

Filename Size Change
./packages/s2-core/dist/s2-extends.min.js 207 kB +12 B (+0.01%)
./packages/s2-core/dist/s2.min.js 306 kB +5 B (0%)
ℹ️ View Unchanged
Filename Size
./packages/s2-core/dist/s2.min.css 583 B
./packages/s2-react-components/dist/s2-react-components.min.css 2.55 kB
./packages/s2-react-components/dist/s2-react-components.min.js 124 kB
./packages/s2-react/dist/s2-react.min.css 1.3 kB
./packages/s2-react/dist/s2-react.min.js 38.5 kB
./packages/s2-vue/dist/s2-vue.min.css 1.59 kB
./packages/s2-vue/dist/s2-vue.min.js 38.3 kB

compressed-size-action

@Alexzjt Alexzjt merged commit 8779bdd into next Dec 26, 2025
14 checks passed
@Alexzjt Alexzjt deleted the fix/reuse branch December 26, 2025 08:16
@lijinke666
Copy link
Member

🎉 This PR is included in version @antv/s2-v2.4.13 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

next 2.0-next 版本的问题 pr(fix) bug fix released on @latest

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants