Skip to content

Commit

Permalink
🐛 Fixed issue with typescript
Browse files Browse the repository at this point in the history
  • Loading branch information
abdheshnayak committed Feb 14, 2024
1 parent b4ae2ae commit b823244
Show file tree
Hide file tree
Showing 11 changed files with 25 additions and 23 deletions.
12 changes: 12 additions & 0 deletions lib/client/components/logger/dummy.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
export const logsMockData = [
'nnQhCA0QTSuukrRA',
'0dlRACNaaPWkx3hBmZNksKoR',
'9BLDLfyAHeCTjoUgLshkJ9eWpqfUkLEf',
'TaJLEEhzWZvd6wt74fWe9oH9G7rhuzRO0ZZDFH49',
'o2Znr1VqxwlnFcyOe8S78z1HXrwIUcrnGdpXoEj2smsD6d',
'5EIOShSO5vqfRojDxuRzdr0S5ILjQ65TuMEm7o6Q75maqJqKCnAj9L',
'wfS7vAAvVY5BGhku2HE9Xnc7tF8wjH913u0i0f2JbOvXuvibfsFtbYnzC9ghk',
'eBfcNEUnIcTDceQGc3jAoZdOno977hMQ5Hfd8LNrrnm9ZVnZpQyMl5Hf3FbTqthhIMdvzs',
'jInteYIHeEBT7ZMKnNUbACPPs7YAUdnzegotEOzWkexdT1reZbzASBkb0LCx4k048gj2kUznyRvea45',
'SQpMBRSCEvC2EWIq2eQ21ljhQkx7hi3t9WNgMpLI0vuaeaUTTcIDXYPqorSJUiGmvQ9R1uQ0x9O0z0fVCNvGYehoaAEYp',
];
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,12 @@ import {
} from '~/root/lib/client/helpers/search-filter';
import useClass from '~/root/lib/client/hooks/use-class';
import { useSocketLogs } from '~/root/lib/client/helpers/socket/useSockLogs';
import { generatePlainColor } from '../color-generator';
import Pulsable from '../pulsable';
import { logsMockData } from '../../dummy/data';
import Pulsable from '~/components/atoms/pulsable';
import { generatePlainColor } from '~/root/lib/utils/color-generator';
import { logsMockData } from './dummy';
// import { generatePlainColor } from '../color-generator';
// import Pulsable from '../pulsable';
// import { logsMockData } from '../../dummy/data';

export type ILog = {
podName: string;
Expand Down
2 changes: 1 addition & 1 deletion lib/client/helpers/socket/useSockLogs.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { useEffect, useState } from 'react';
import { dayjs } from '~/components/molecule/dayjs';
import { ILog } from '~/console/components/logger';
import { ISocketResp, useSubscribe } from './context';
import { ILog } from '../../components/logger';

interface IuseLog {
account: string;
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/apps/console/components/console-avatar.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { Avatar } from '~/components/atoms/avatar';
import { titleCase } from '~/components/utils';
import generateColor from './color-generator';
import generateColor from '~/root/lib/utils/color-generator';

const ConsoleAvatar = ({
name,
Expand Down
13 changes: 0 additions & 13 deletions src/apps/console/dummy/data.js
Original file line number Diff line number Diff line change
Expand Up @@ -720,16 +720,3 @@ export const dummyData = {
},
],
};

export const logsMockData = [
'nnQhCA0QTSuukrRA',
'0dlRACNaaPWkx3hBmZNksKoR',
'9BLDLfyAHeCTjoUgLshkJ9eWpqfUkLEf',
'TaJLEEhzWZvd6wt74fWe9oH9G7rhuzRO0ZZDFH49',
'o2Znr1VqxwlnFcyOe8S78z1HXrwIUcrnGdpXoEj2smsD6d',
'5EIOShSO5vqfRojDxuRzdr0S5ILjQ65TuMEm7o6Q75maqJqKCnAj9L',
'wfS7vAAvVY5BGhku2HE9Xnc7tF8wjH913u0i0f2JbOvXuvibfsFtbYnzC9ghk',
'eBfcNEUnIcTDceQGc3jAoZdOno977hMQ5Hfd8LNrrnm9ZVnZpQyMl5Hf3FbTqthhIMdvzs',
'jInteYIHeEBT7ZMKnNUbACPPs7YAUdnzegotEOzWkexdT1reZbzASBkb0LCx4k048gj2kUznyRvea45',
'SQpMBRSCEvC2EWIq2eQ21ljhQkx7hi3t9WNgMpLI0vuaeaUTTcIDXYPqorSJUiGmvQ9R1uQ0x9O0z0fVCNvGYehoaAEYp',
];
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@ import { useState } from 'react';
import { dayjs } from '~/components/molecule/dayjs';
import { parseValue } from '~/console/page-components/util';
import { ApexOptions } from 'apexcharts';
import LogComp from '~/console/components/logger';
import { parseName } from '~/console/server/r-utils/common';
import { Clock, ListNumbers } from '@jengaicons/react';
import { cn } from '~/components/utils';
import { useDataState } from '~/console/page-components/common-state';
import { observeUrl } from '~/root/lib/configs/base-url.cjs';
import { IAppContext } from '../_layout';
import LogComp from '~/root/lib/client/components/logger';

const LogsAndMetrics = () => {
const { app, project, account } = useOutletContext<IAppContext>();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ import { Link, useOutletContext } from '@remix-run/react';
import { IStatus, listRender } from '~/console/components/commons';
import { listStatus } from '~/console/components/sync-status';
import AnimateHide from '~/components/atoms/animate-hide';
import LogComp from '~/console/components/logger';
import { ISetState } from '~/console/page-components/app-states';
import { Button } from '~/components/atoms/button';
import { dayjs } from '~/components/molecule/dayjs';
Expand All @@ -39,6 +38,7 @@ import {
findNodePlanWithSpec,
} from './nodepool-utils';
import { IAccountContext } from '../../../_layout';
import LogComp from '~/root/lib/client/components/logger';

const RESOURCE_NAME = 'nodepool';
type BaseType = ExtractNodeType<INodepools>;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,12 @@ import {
parseUpdateOrCreatedBy,
parseUpdateOrCreatedOn,
} from '~/console/server/r-utils/common';
import LogComp from '~/console/components/logger';
import { renderCloudProvider } from '~/console/utils/commons';
import { CommonTabs } from '~/console/components/common-navbar-tabs';
import { DetailItem } from '~/console/components/commons';
import { INodepool } from '~/console/server/gql/queries/nodepool-queries';
import { IAccountContext } from '../../../_layout';
import LogComp from '~/root/lib/client/components/logger';

const ClusterTabs = () => {
const { account, cluster } = useParams();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@ import Chart from '~/console/components/charts/charts-client';
import { useState } from 'react';
import { dayjs } from '~/components/molecule/dayjs';
import { ApexOptions } from 'apexcharts';
import LogComp from '~/console/components/logger';
import { parseName } from '~/console/server/r-utils/common';
import { Clock, ListNumbers } from '@jengaicons/react';
import { cn } from '~/components/utils';
import { useDataState } from '~/console/page-components/common-state';
import { IClusterContext } from '../../_layout';
import LogComp from '~/root/lib/client/components/logger';

const LogsAndMetrics = () => {
const { cluster, account } = useOutletContext<IClusterContext>();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ import {
import { useOutletContext } from '@remix-run/react';
import { IBuildRuns } from '~/console/server/gql/queries/build-run-queries';
import AnimateHide from '~/components/atoms/animate-hide';
import LogComp from '~/console/components/logger';
import { Button } from '~/components/atoms/button';
import {
CheckCircleFill,
Expand All @@ -27,6 +26,7 @@ import {
} from '@jengaicons/react';
import dayjs from 'dayjs';
import { IAccountContext } from '../../../_layout';
import LogComp from '~/root/lib/client/components/logger';

const RESOURCE_NAME = 'build run';
type BaseType = ExtractNodeType<IBuildRuns>;
Expand Down

0 comments on commit b823244

Please sign in to comment.