diff --git a/apps/operate/common-util/functions/frontend-library.ts b/apps/operate/common-util/functions/frontend-library.ts index 8cf1dfed..8eb8e380 100644 --- a/apps/operate/common-util/functions/frontend-library.ts +++ b/apps/operate/common-util/functions/frontend-library.ts @@ -4,7 +4,9 @@ import { notifyError, } from '@autonolas/frontend-library'; -import { RPC_URLS, SUPPORTED_CHAINS } from 'common-util/config/wagmi'; +import { RPC_URLS } from 'libs/util-constants/src'; + +import { SUPPORTED_CHAINS } from 'common-util/config/wagmi'; export const getProvider = () => { const provider = getProviderFn(SUPPORTED_CHAINS, RPC_URLS); diff --git a/apps/operate/components/Contracts/hooks.ts b/apps/operate/components/Contracts/hooks.ts index edf7943d..0db09263 100644 --- a/apps/operate/components/Contracts/hooks.ts +++ b/apps/operate/components/Contracts/hooks.ts @@ -118,7 +118,7 @@ export const useStakingContractsList = () => { stakeRequired, availableOn: AVAILABLE_ON[item.account] || null, }; - }); + }) as StakingContract[]; } return []; }, [ diff --git a/apps/operate/components/Contracts/index.tsx b/apps/operate/components/Contracts/index.tsx index 007a481a..15aaa64f 100644 --- a/apps/operate/components/Contracts/index.tsx +++ b/apps/operate/components/Contracts/index.tsx @@ -1,5 +1,6 @@ import { DownOutlined, RightOutlined } from '@ant-design/icons'; -import { Button, Card, Flex, Table, TableColumnsType, Tag, Typography } from 'antd'; +import { Button, Card, Flex, Table, Tag, Typography } from 'antd'; +import { ColumnsType } from 'antd/es/table'; import Image from 'next/image'; import styled from 'styled-components'; import { StakingContract } from 'types'; @@ -43,11 +44,11 @@ const getAvailableOnData = (availableOn: StakingContract['availableOn']) => { return { icon, text, href }; }; -const columns: TableColumnsType = [ +const columns: ColumnsType = [ { title: 'Contract', dataIndex: 'metadata', - key: 'metadata', + key: 'address', render: (metadata) => {metadata.name || NA}, }, { diff --git a/apps/operate/types/index.ts b/apps/operate/types/index.ts index b512cce7..2b44b8bf 100644 --- a/apps/operate/types/index.ts +++ b/apps/operate/types/index.ts @@ -12,7 +12,7 @@ export type StakingContract = { metadata: Metadata; availableSlots: number; maxSlots: number; - apy: number; - stakeRequired: number; + apy: string; + stakeRequired: string; availableOn: 'pearl' | 'quickstart' | null; }; diff --git a/libs/ui-components/tsconfig.json b/libs/ui-components/tsconfig.json index f5b85657..a440e9d4 100644 --- a/libs/ui-components/tsconfig.json +++ b/libs/ui-components/tsconfig.json @@ -1,22 +1,26 @@ { "extends": "../../tsconfig.base.json", "compilerOptions": { - "module": "commonjs", - "forceConsistentCasingInFileNames": true, + "jsx": "preserve", + "allowJs": true, + "esModuleInterop": true, + "allowSyntheticDefaultImports": true, "strict": true, - "noImplicitOverride": true, - "noPropertyAccessFromIndexSignature": true, - "noImplicitReturns": true, - "noFallthroughCasesInSwitch": true - }, - "files": [], - "include": [], - "references": [ - { - "path": "./tsconfig.lib.json" - }, - { - "path": "./tsconfig.spec.json" + "forceConsistentCasingInFileNames": true, + "noEmit": true, + "resolveJsonModule": true, + "isolatedModules": true, + "incremental": true, + "plugins": [ + { + "name": "next" + } + ], + "types": ["jest", "node", "react", "react-dom"], + "paths": { + "libs/*": ["libs/*"] } - ] + }, + "include": ["**/*.ts", "**/*.tsx", "**/*.js", "**/*.jsx", "next-env.d.ts"], + "exclude": ["node_modules", "jest.config.js", "src/**/*.spec.ts", "src/**/*.test.ts"] }