Skip to content

🐛图标设置悬浮显示, 在选中单元格后,再悬浮上去,图标不显示 #2929

@misswangkang

Description

@misswangkang

🏷 Version

Package Version
@antv/s2 1.54.4
@antv/s2-react
@antv/s2-vue

Sheet Type

  • PivotSheet
  • TableSheet
  • GridAnalysisSheet
  • StrategySheet
  • EditableSheet

🖋 Description

headerActionIcons 设置 defaultHide =true ,如果点击单元格选中后,再悬浮到单元格上,图标不显示

⌨️ Code Snapshots

官网案例,修改了defaultHide =true

import { PivotSheet, S2Options } from '@antv/s2';
import '@antv/s2/dist/style.min.css';

fetch(
'https://gw.alipayobjects.com/os/bmw-prod/2a5dbbc8-d0a7-4d02-b7c9-34f6ca63cff6.json',
)
.then((res) => res.json())
.then(async (dataCfg) => {
const container = document.getElementById('container');

const s2Options: S2Options = {
  width: 600,
  height: 480,
  customSVGIcons: [
    {
      name: 'Filter',
      src: 'https://gw.alipayobjects.com/zos/antfincdn/gu1Fsz3fw0/filter%26sort_filter.svg',
    },
  ],
  showDefaultHeaderActionIcon: false,
  headerActionIcons: [
    {
      icons: ['Filter'],
      belongsCell: 'colCell',
      defaultHide: true,
     
      onClick: (options) => {
       
      },
    },
  
  ],
  style: {
    colCell: {
      hideValue: true,
    },
  },
};

const s2 = new PivotSheet(container, dataCfg, s2Options);

await s2.render();

});

🔗 Reproduce Link

🤔 Steps to Reproduce

😊 Expected Behavior

😅 Current Behavior

💻 System information

Environment Info
System
Browser

Metadata

Metadata

Assignees

Labels

⚡ enhancement功能增强💤 inactive不活跃的 Issue 或 PR, 30天没有回复

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions