[Feature] 支持以行列key的形式上来设置单元格自定义样式
Open
Nobody has claimed this yet.
feature
- Dominant language
- TypeScript
- Stars
- 3.7k
- Forks
- 486
- Avg merge
- 1d 19h
- Merged PRs (30d)
- 16
Description
What problem does this feature solve?
目前设置单元格自定义样式时,行列是数字序号,当ListTable的Tree模式下为单元格设置自定义样式的时候,tree的展开和收起会导致自定义样式漂移到其他单元格
What does the proposed API look like?
const option = {
customCellStyle: [
{
id: 'custom-1',
style: {
//...
}
},
],
customCellStyleArrangement: [
{
customStyleId: 'custom-1',
cellPosition: {
col: 'a',
row: 'row1'
}
},
{
customStyleId: 'custom-1',
cellPosition: {
col: ['b', 'c'],
row: ['row2', 'row3'],
}
},
],
records: [
{
field: 'row1',
data:{
col1: 1,
col2: 2,
col3: 3
},
},{
field: 'row2',
data:{
col1: 1,
col2: 2,
col3: 3
},
}
],
columns:[
{
field: 'col1',
title: 'col 1'
},{
field: 'col2',
title: 'col 2'
},{
field: 'col3',
title: 'col 3'
}
],
widthMode: 'standard'
};
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing the existing customCellStyle and customCellStyleArrangement handling in the TypeScript table implementation. Check how cell positions are resolved in ListTable tree mode, then verify that row and column keys, including arrays of keys, keep styles attached after expanding and collapsing nodes. Done means the proposed keyed API works without style drift.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- data-visualization, frontend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100