@@ -46,8 +46,8 @@ export default class DataBrowser extends React.Component {
4646 selectedCells : { list : new Set ( ) , rowStart : - 1 , rowEnd : - 1 , colStart : - 1 , colEnd : - 1 } ,
4747 firstSelectedCell : null ,
4848 selectedData : [ ] ,
49- numericSelectedData : [ ] , // Dados apenas numéricos para operações Sum
50- hasDateInSelection : false , // Flag para detectar se há datas na seleção
49+ numericSelectedData : [ ] , // Numeric data only for Sum operations
50+ hasDateInSelection : false , // Flag to detect if there are dates in selection
5151 prevClassName : props . className ,
5252 panelWidth : 300 ,
5353 isResizing : false ,
@@ -588,7 +588,7 @@ export default class DataBrowser extends React.Component {
588588 for ( let i = colStart ; i <= colEnd ; i ++ ) {
589589 const name = this . state . order [ i ] . name ;
590590 const columnType = this . props . columns [ name ] . type ;
591- // Permitir Number, Date, String (que pode conter números) para visualização
591+ // Allow Number, Date, String (which can contain numbers) for visualization
592592 if ( columnType !== 'Number' && columnType !== 'Date' && columnType !== 'String' ) {
593593 validColumns = false ;
594594 break ;
@@ -597,7 +597,7 @@ export default class DataBrowser extends React.Component {
597597
598598 const newSelection = new Set ( ) ;
599599 const selectedData = [ ] ;
600- let hasDateColumns = false ; // Flag para detectar se há colunas de data
600+ let hasDateColumns = false ; // Flag to detect if there are date columns
601601
602602 for ( let x = rowStart ; x <= rowEnd ; x ++ ) {
603603 let rowData = null ;
@@ -609,30 +609,30 @@ export default class DataBrowser extends React.Component {
609609 const value = rowData . attributes [ this . state . order [ y ] . name ] ;
610610 const columnType = this . props . columns [ this . state . order [ y ] . name ] . type ;
611611
612- // Incluir diferentes tipos de dados para visualização
612+ // Include different data types for visualization
613613 if ( columnType === 'Number' && typeof value === 'number' && ! isNaN ( value ) ) {
614614 selectedData . push ( value ) ;
615615 } else if ( columnType === 'Date' && value instanceof Date ) {
616616 selectedData . push ( value ) ;
617- hasDateColumns = true ; // Marcar que há datas
617+ hasDateColumns = true ; // Mark that there are dates
618618 } else if ( columnType === 'Date' && typeof value === 'string' && ! isNaN ( Date . parse ( value ) ) ) {
619619 selectedData . push ( new Date ( value ) ) ;
620- hasDateColumns = true ; // Marcar que há datas
620+ hasDateColumns = true ; // Mark that there are dates
621621 } else if ( columnType === 'String' && typeof value === 'string' ) {
622- // Para strings, incluir apenas se puderem ser interpretadas como números
622+ // For strings, include only if they can be interpreted as numbers
623623 const numValue = parseFloat ( value ) ;
624624 if ( ! isNaN ( numValue ) ) {
625625 selectedData . push ( numValue ) ;
626626 } else {
627- selectedData . push ( value ) ; // Incluir strings para labels em time series
627+ selectedData . push ( value ) ; // Include strings for labels in time series
628628 }
629629 }
630630 }
631631 newSelection . add ( `${ x } -${ y } ` ) ;
632632 }
633633 }
634634
635- // Criar array apenas com números para operações de soma (excluindo datas )
635+ // Create array with only numbers for sum operations (excluding dates )
636636 const numericData = selectedData . filter ( value =>
637637 typeof value === 'number' && ! isNaN ( value )
638638 ) ;
@@ -650,8 +650,8 @@ export default class DataBrowser extends React.Component {
650650 } ,
651651 selectedObjectId : undefined ,
652652 selectedData,
653- numericSelectedData : numericData , // Dados apenas numéricos para Sum
654- hasDateInSelection : hasDateColumns , // Flag para saber se há datas
653+ numericSelectedData : numericData , // Numeric data only for Sum
654+ hasDateInSelection : hasDateColumns , // Flag to know if there are dates
655655 } ) ;
656656 } else {
657657 this . setCurrent ( { row, col } ) ;
@@ -660,8 +660,8 @@ export default class DataBrowser extends React.Component {
660660 this . setState ( {
661661 selectedCells : { list : new Set ( ) , rowStart : - 1 , rowEnd : - 1 , colStart : - 1 , colEnd : - 1 } ,
662662 selectedData : [ ] ,
663- numericSelectedData : [ ] , // Limpar dados numéricos
664- hasDateInSelection : false , // Limpar flag de datas
663+ numericSelectedData : [ ] , // Clear numeric data
664+ hasDateInSelection : false , // Clear dates flag
665665 current : { row, col } ,
666666 firstSelectedCell : clickedCellKey ,
667667 } ) ;
0 commit comments