Skip to content

Commit e30fba2

Browse files
author
Nicolas Medeiros
committed
Use is-sorted class instead of custom inline style
1 parent b9c7546 commit e30fba2

File tree

1 file changed

+1
-9
lines changed

1 file changed

+1
-9
lines changed

src/scripts/Table.js

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -120,20 +120,12 @@ export const TableHeaderColumn = (props) => {
120120
'slds-text-title--caps slds-truncate', {
121121
'slds-is-sortable': sortable,
122122
'slds-is-resizable': resizable,
123+
'slds-is-sorted': sorted,
123124
[`slds-text-align--${align}`]: align,
124125
});
125126

126127
const style = { minWidth: width || 'auto' };
127128

128-
const buttonStyle = {};
129-
130-
// TODO: SLDS doesn't have class for selected so will wait
131-
if (sorted) {
132-
style.backgroundColor = '#F4F6F9';
133-
style.color = '#0070d2';
134-
buttonStyle.visibility = 'visible';
135-
}
136-
137129
const icon = sortDir === 'DESC' ? 'arrowdown' : 'arrowup';
138130

139131
return (

0 commit comments

Comments
 (0)