We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
| Package | Version | | @antv/s2 | 1.49.1 |
PivotSheet
'' 使用hierarchyType: customTree 目录树时,想通过conditions配置表头的样式,使用后发现,插件内部生成的row【指标】这一格无法修改
https://s2-v1.antv.antgroup.com/zh/examples/custom/custom-tree/#custom-tree const s2Options = { width: 600, height: 480, hierarchyType: 'customTree', conditions: { text: [ { field: 'custom-node-1', mapping(value) { return { fill: 'red', }; }, }, ], background: [ { field: 'type', mapping(value) { return { fill: 'red', }; }, }, { field: 'sub_type', mapping(value) { return { fill: 'red', }; }, }, { field: 'measure-a', mapping(value) { return { fill: 'red', }; }, }, ], }, };
如何可以修改row【指标】这一格样式
The text was updated successfully, but these errors were encountered:
你好 @zj-93,请编辑你的 issue 标题, 一个言简意赅的 issue 标题可以节省大家的时间, 请不要将标题当做正文, 或者为空。
Hello, @zj-93, please edit your issue title. a concise issue title will save everyone time. please do not leave the title as the body or empty.
Sorry, something went wrong.
conditions 是用于字段标记的场景, 如果你只是想定制表头样式, 请考虑 主题配置 或 自定义单元格
[指标] 对应的单元格类型为 角头 (CornerCell)
s2.setTheme({ cornerCell: { cell: { ... }, text: {...} } })
class CustomCornerCell extends CornerCell { getBackgroundColor() { console.log(this.meta) return { backgroundColor: 'red', backgroundColorOpacity: 0.2, }; } }
lijinke666
No branches or pull requests
| Package | Version |
| @antv/s2 | 1.49.1 |
PivotSheet
🖋 Description
''
使用hierarchyType: customTree 目录树时,想通过conditions配置表头的样式,使用后发现,插件内部生成的row【指标】这一格无法修改
🔗 Reproduce Link
https://s2-v1.antv.antgroup.com/zh/examples/custom/custom-tree/#custom-tree
const s2Options = {
width: 600,
height: 480,
hierarchyType: 'customTree',
conditions: {
text: [
{
field: 'custom-node-1',
mapping(value) {
return {
fill: 'red',
};
},
},
],
background: [
{
field: 'type',
mapping(value) {
return {
fill: 'red',
};
},
},
{
field: 'sub_type',
mapping(value) {
return {
fill: 'red',
};
},
},
{
field: 'measure-a',
mapping(value) {
return {
fill: 'red',
};
},
},
],
},
};
😊 Expected Behavior
如何可以修改row【指标】这一格样式
😅 Current Behavior
The text was updated successfully, but these errors were encountered: