-
Notifications
You must be signed in to change notification settings - Fork 199
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: 修复手动排序在单行头且维值相似的场景不生效 #3019
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
@@ -108,8 +108,10 @@ export const sortByCustom = (params: SortActionParams): string[] => { | |||
const { sortByValues = [], originValues = [] } = params; | |||
|
|||
// 从 originValues 中过滤出所有包含 sortByValue 的 id | |||
const idWithPre = originValues.filter((originItem) => | |||
sortByValues.find((value) => endsWith(originItem, value)), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
原来使用 endSWidth
去匹配, 以单测的场景, 按 "测试" 手动排序, 如果维值是 "我是测试", 也会命中, 导致将 我是测试
排到最上方
Size Change: 0 B Total Size: 618 kB ℹ️ View Unchanged
|
🎉 This PR is included in version @antv/s2-v2.1.3 🎉 The release is available on: Your semantic-release bot 📦🚀 |
👀 PR includes
🐛 Bugfix
📝 Description
🖼️ Screenshot
🔗 Related issue link
🔍 Self-Check before the merge