Skip to content

Commit

Permalink
refactor: address review comment
Browse files Browse the repository at this point in the history
  • Loading branch information
ahmadshaheer committed Jan 30, 2025
1 parent 5cbdd3a commit 44cd538
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -6,18 +6,27 @@ import OverlayScrollbar from 'components/OverlayScrollbar/OverlayScrollbar';
import { LOCALSTORAGE } from 'constants/localStorage';
import ShowButton from 'container/LogsContextList/ShowButton';
import { useOptionsMenu } from 'container/OptionsMenu';
import { defaultLogsSelectedFields } from 'container/OptionsMenu/constants';
import { defaultLogsSelectedColumns } from 'container/OptionsMenu/constants';
import { FontSize } from 'container/OptionsMenu/types';
import { ORDERBY_FILTERS } from 'container/QueryBuilder/filters/OrderByFilter/config';
import { useQueryBuilder } from 'hooks/queryBuilder/useQueryBuilder';
import { useCallback, useEffect, useMemo, useState } from 'react';
import { Virtuoso } from 'react-virtuoso';
import { IField } from 'types/api/logs/fields';
import { ILog } from 'types/api/logs/log';
import { Query, TagFilter } from 'types/api/queryBuilder/queryBuilderData';
import { DataSource, StringOperators } from 'types/common/queryBuilder';

import { useContextLogData } from './useContextLogData';

const defaultLogsSelectedFields: IField[] = defaultLogsSelectedColumns.map(
(item) => ({
name: item.key,
type: item.type,
dataType: item.dataType,
}),
);

function ContextLogRenderer({
isEdit,
query,
Expand Down
9 changes: 0 additions & 9 deletions frontend/src/container/OptionsMenu/constants.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import { IField } from 'types/api/logs/fields';
import { DataTypes } from 'types/api/queryBuilder/queryAutocompleteResponse';

import { FontSize, OptionsQuery } from './types';
Expand Down Expand Up @@ -33,14 +32,6 @@ export const defaultLogsSelectedColumns = [
},
];

export const defaultLogsSelectedFields: IField[] = defaultLogsSelectedColumns.map(
(item) => ({
name: item.key,
type: item.type,
dataType: item.dataType,
}),
);

export const defaultTraceSelectedColumns = [
{
key: 'serviceName',
Expand Down

0 comments on commit 44cd538

Please sign in to comment.