mirror of
https://github.com/apache/superset.git
synced 2026-05-07 08:54:23 +00:00
fix(plugin-chart-table): Invalid d3Formatter on String column (#23515)
This commit is contained in:
@@ -97,6 +97,7 @@ describe('plugin-chart-table', () => {
|
||||
// should successful rerender with new props
|
||||
const cells = tree.find('td');
|
||||
expect(tree.find('th').eq(1).text()).toEqual('Sum of Num');
|
||||
expect(cells.eq(0).text()).toEqual('Michael');
|
||||
expect(cells.eq(2).text()).toEqual('12.346%');
|
||||
expect(cells.eq(4).text()).toEqual('2.47k');
|
||||
});
|
||||
|
||||
@@ -144,6 +144,20 @@ const advanced: TableChartProps = {
|
||||
...basicFormData,
|
||||
metrics: ['sum__num'],
|
||||
percent_metrics: ['pct_nice'],
|
||||
column_config: {
|
||||
name: {
|
||||
d3NumberFormat: '.3s',
|
||||
},
|
||||
sum__num: {
|
||||
d3NumberFormat: '.3s',
|
||||
},
|
||||
pct_nice: {
|
||||
d3NumberFormat: '.3s',
|
||||
},
|
||||
'abc.com': {
|
||||
d3NumberFormat: '.3s',
|
||||
},
|
||||
},
|
||||
},
|
||||
queriesData: [
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user