@@ -247,32 +247,30 @@ export function flattenBy(arr, key) {
247247 return flat
248248}
249249
250- function expandRows (
251- rows ,
252- { manualExpandedKey, expanded, expandSubRows = true }
250+ export function expandRows (
251+ rows ,
252+ { manualExpandedKey, expanded, expandSubRows = true }
253253) {
254- const expandedRows = [ ] ;
254+ const expandedRows = [ ]
255255
256- const handleRow = ( row , addToExpandedRows = true ) => {
257- row . isExpanded =
258- ( row . original && row . original [ manualExpandedKey ] ) || expanded [ row . id ] ;
256+ const handleRow = ( row , addToExpandedRows = true ) => {
257+ row . isExpanded =
258+ ( row . original && row . original [ manualExpandedKey ] ) || expanded [ row . id ]
259259
260- row . canExpand = row . subRows && ! ! row . subRows . length ;
260+ row . canExpand = row . subRows && ! ! row . subRows . length
261261
262- if ( addToExpandedRows ) {
263- expandedRows . push ( row ) ;
264- }
262+ if ( addToExpandedRows ) {
263+ expandedRows . push ( row )
264+ }
265265
266- if ( row . subRows && row . subRows . length && row . isExpanded ) {
267- row . subRows . forEach ( ( row ) => handleRow ( row , expandSubRows ) ) ;
268- }
269- } ;
266+ if ( row . subRows && row . subRows . length && row . isExpanded ) {
267+ row . subRows . forEach ( row => handleRow ( row , expandSubRows ) )
268+ }
269+ }
270270
271- rows . forEach ( ( row ) => handleRow ( row ) ) ;
271+ rows . forEach ( row => handleRow ( row ) )
272272
273- console . log ( "foidn" ) ;
274- rows . forEach ( ( row ) => console . log ( "---row" , row ) ) ;
275- return expandedRows ;
273+ return expandedRows
276274}
277275
278276export function getFilterMethod ( filter , userFilterTypes , filterTypes ) {
0 commit comments