给列头设置了border后,单元格不能拖拽列宽了,并且经常报错 #2602
-
|
给列头自定义border后,单元格不能拖拽列宽了,并且经常报错 |
Beta Was this translation helpful? Give feedback.
Answered by
lijinke666
Mar 18, 2024
Replies: 1 comment 1 reply
-
|
基类的 S2/packages/s2-core/src/cell/base-cell.ts Lines 318 to 322 in 00bb610 class CustomColCell extends ColCell {
- getStyle() {
- const defaultStyle = super.getStyle()
- }
+ getStyle(name) {
+ const defaultStyle = super.getStyle(name)
+ }
} |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
Create-Peace
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment

基类的
getStyle有一个可选参数, 你如果重写的话需要透传, 不然拖拽热区的颜色拿不到, 这里的文档有误, 后续修改下S2/packages/s2-core/src/cell/base-cell.ts
Lines 318 to 322 in 00bb610
class CustomColCell extends ColCell { - getStyle() { - const defaultStyle = super.getStyle() - } + getStyle(name) { + const defaultStyle = super.getStyle(name) + } }