-
-
Notifications
You must be signed in to change notification settings - Fork 365
feat(Table): can resize the fixed column #5223
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
Conversation
Reviewer's Guide by SourceryThis pull request enables resizing of fixed columns in the Table component. It introduces a new function to handle the resizing of adjacent fixed columns and modifies the existing resize logic to call this new function. Sequence diagram for fixed column resizing interactionsequenceDiagram
participant User
participant Table
participant ResizeHandler
participant FixedColumns
User->>Table: Drags column resizer
Table->>ResizeHandler: Trigger resize event
ResizeHandler->>ResizeHandler: Calculate new width
ResizeHandler->>Table: Update column width
alt Is Fixed Column
ResizeHandler->>FixedColumns: Call resizeNextFixedColumnWidth
FixedColumns->>FixedColumns: Update adjacent fixed columns
end
Table->>User: Display updated column widths
Class diagram for Table component with resizing featureclassDiagram
class Table {
+AllowResizing: bool
+RenderMode: TableRenderMode
+setResizeListener()
+setColumnResizingListen()
}
class TableColumn {
+Field: string
+Width: int
+Fixed: bool
+Filterable: bool
}
class ResizeHandler {
+resizeNextFixedColumnWidth(col, width)
-handleFixedRight()
-handleFixed()
}
Table *-- TableColumn
Table --> ResizeHandler
File-Level Changes
Assessment against linked issues
Possibly linked issues
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
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.
Hey @ArgoZhang - I've reviewed your changes - here's some feedback:
Overall Comments:
- Consider optimizing the column resize handler for large tables - updating individual cell styles for every row could impact performance. Consider batching updates or using a more efficient approach like CSS classes.
Here's what I looked at during the review
- 🟡 General issues: 2 issues found
- 🟢 Security: all looks good
- 🟢 Testing: all looks good
- 🟢 Complexity: all looks good
- 🟢 Documentation: all looks good
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #5223 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 635 635
Lines 28243 28243
Branches 4066 4066
=========================================
Hits 28243 28243 ☔ View full report in Codecov by Sentry. |
can resize the fixed column
Summary of the changes (Less than 80 chars)
简单描述你更改了什么, 不超过80个字符;如果有关联 Issue 请在下方填写相关编号
Description
fixes #3447
Regression?
[If yes, specify the version the behavior has regressed from]
[是否影响老版本]
Risk
[Justify the selection above]
Verification
Packaging changes reviewed?
☑️ Self Check before Merge
Summary by Sourcery
Enable resizing for fixed columns in tables.
New Features:
Tests: