Skip to content

Commit 806afd1

Browse files
authored
Firefly-1506: Merge pull request #1576 from Caltech-IPAC/FIREFLY-1506-dark
Firefly-1506: Update buttons to material icons
2 parents 7b05f1b + bafcfd1 commit 806afd1

File tree

1 file changed

+7
-14
lines changed

1 file changed

+7
-14
lines changed

src/firefly/js/charts/ui/PlotlyToolbar.jsx

Lines changed: 7 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -22,15 +22,13 @@ import {
2222
} from '../../visualize/MultiViewCntlr.js';
2323
import {ListBoxInputFieldView} from 'firefly/ui/ListBoxInputField';
2424
import {
25-
AddItem, CheckedClearButton, ClearFilterButton, ExpandButton, FilterButton, RestoreButton, SaveButton,
26-
SettingsButton, Zoom1XIcon, ZoomUpIcon,
25+
AddItem, CheckedButton, CheckedClearButton, ClearFilterButton, ExpandButton,
26+
FilterAddButton, FilterButton, RestoreButton, SaveButton, SettingsButton, Zoom1XIcon, ZoomUpIcon,
2727
} from '../../visualize/ui/Buttons.jsx';
2828

2929
import SelectIco from 'html/images/icons-2014/select.png';
3030
import TurntableIco from 'html/images/turntable-tmp.png';
3131
import OrbitalIco from 'html/images/orbital-tmp.png';
32-
import ApplySelectIco from 'html/images/icons-2014/24x24_Checkmark.png';
33-
import ApplyFilterIco from 'html/images/icons-2014/24x24_FilterAdd.png';
3432
import PanToolOutlinedIco from '@mui/icons-material/PanToolOutlined';
3533

3634
export function PlotlyToolbar({chartId, expandable}) {
@@ -182,10 +180,10 @@ function SelectionPart({chartId, hasFilter, hasSelection, hasSelected, tbl_id})
182180
}
183181
return (
184182
<>
185-
{hasFilter && <ClearFilter {...{tbl_id}} />}
183+
{showSelectSelection && <SelectSelection {...{chartId}} />}
186184
{hasSelected && <ClearSelected {...{chartId}} />}
187185
{hasSelection && <FilterSelection {...{chartId}} />}
188-
{showSelectSelection && <SelectSelection {...{chartId}} />}
186+
{hasFilter && <ClearFilter {...{tbl_id}} />}
189187
</>
190188
);
191189
}
@@ -349,9 +347,8 @@ export function ActiveTraceSelect({sx={}, chartId, activeTrace}) {
349347

350348
function FilterSelection({chartId}) {
351349
return (
352-
<IconButton onClick={() => dispatchChartFilterSelection({chartId})}
353-
title='Filter on the selected points'
354-
><img src={ApplyFilterIco}/></IconButton>
350+
<FilterAddButton onClick={() => dispatchChartFilterSelection({chartId})}
351+
title='Filter on the selected points'/>
355352
);
356353
}
357354

@@ -360,11 +357,7 @@ function SelectSelection({chartId}) {
360357
const selIndexes = get(getChartData(chartId), 'selection.points', []);
361358
dispatchChartSelect({chartId, selIndexes, chartTrigger: true});
362359
};
363-
return (
364-
<IconButton onClick={onClick}
365-
title='Select the enclosed points'
366-
><img src={ApplySelectIco}/></IconButton>
367-
);
360+
return ( <CheckedButton onClick={onClick} title='Select the enclosed points'/> );
368361
}
369362

370363
function ClearSelected({chartId}) {

0 commit comments

Comments
 (0)