Skip to content

Commit

Permalink
Update dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
olehmell committed Nov 29, 2023
1 parent 50af903 commit edc54ce
Show file tree
Hide file tree
Showing 11 changed files with 1,734 additions and 136 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/check-build-front.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jobs:

strategy:
matrix:
node-version: [16.x]
node-version: [18.x]

steps:
- uses: actions/checkout@v4
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM node:16-alpine3.16 as builder
FROM node:18-alpine3.18 as builder

ARG GH_BACKEND_URL
ARG GH_IPFS_URL
Expand Down
4 changes: 2 additions & 2 deletions docker/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM node:16-alpine3.16 as builder
FROM node:18-alpine3.18 as builder

ARG GH_BACKEND_URL
ARG GH_IPFS_URL
Expand All @@ -22,7 +22,7 @@ RUN set -x \
&& mv ci.env .env \
&& NODE_ENV=production yarn build

FROM gcr.io/distroless/nodejs:16 AS runner
FROM gcr.io/distroless/nodejs:18 AS runner

ARG GH_BACKEND_URL
ARG GH_IPFS_URL
Expand Down
10 changes: 2 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,18 +52,12 @@
"typescript": "4.9.5"
},
"resolutions": {
"@types/react": "^17.x.x",
"@polkadot/types": "10.9.1",
"@polkadot/api": "10.9.1",
"@polkadot/util": "12.5.1",
"@polkadot/keyring": "12.5.1",
"@polkadot/x-bigint": "12.5.1",
"@polkadot/util-crypto": "12.5.1"
"@types/react": "^17.x.x"
},
"dependencies": {
"@amplitude/analytics-browser": "^2.2.2",
"@ant-design/charts": "^1.2.14",
"@ant-design/icons": "^4.6.2",
"@ant-design/icons": "4.6.2",
"@blazity/next-image-proxy": "^1.0.2",
"@floating-ui/react": "^0.25.1",
"@google/model-viewer": "^1.10.1",
Expand Down
2 changes: 1 addition & 1 deletion src/api/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ type GetParams = {
type SendGetRequestProps = {
params: GetParams
onFailReturnedValue: any
onFailedText: string,
onFailedText: string
timeout?: number
}

Expand Down
52 changes: 25 additions & 27 deletions src/components/accountDashboard/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,34 +25,32 @@ const TotalSection = ({
loading,
}: TotalSectionProps) => {
return (
<>
<div className={styles.BalanceBlock}>
<MutedSpan className={styles.FontSmall}>
{title}
{description && (
<Tooltip className='ml-2' title={description}>
<QuestionCircleOutlined />
</Tooltip>
)}
</MutedSpan>

{loading ? (
<Skeleton
active
title={false}
paragraph={{ rows: 1, className: styles.SkeletonParagraph }}
className={styles.Skeleton}
/>
) : (
<BalanceView
value={totalBalance.toString()}
symbol='$'
startWithSymbol
className={styles.FontLarge}
/>
<div className={styles.BalanceBlock}>
<MutedSpan className={styles.FontSmall}>
{title}
{description && (
<Tooltip className='ml-2' title={description}>
<QuestionCircleOutlined />
</Tooltip>
)}
</div>
</>
</MutedSpan>

{loading ? (
<Skeleton
active
title={false}
paragraph={{ rows: 1, className: styles.SkeletonParagraph }}
className={styles.Skeleton}
/>
) : (
<BalanceView
value={totalBalance.toString()}
symbol='$'
startWithSymbol
className={styles.FontLarge}
/>
)}
</div>
)
}

Expand Down
3 changes: 1 addition & 2 deletions src/components/common/balances/Balance.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import React from 'react'
import { formatBalance } from '@polkadot/util'
import BN from 'bn.js'
import { formatBalance, BN } from '@polkadot/util'
import { Compact } from '@polkadot/types'

// for million, 2 * 3-grouping + comma
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
import React from 'react'
import { Button, Col, FormInstance, Input, Row } from 'antd'
import { Form } from 'antd'
import { Button, Col, FormInstance, Input, Row, Form } from 'antd'
import BigNumber from 'bignumber.js'
import { nonEmptyStr } from '@subsocial/utils'
import BN from 'bn.js'
import { useTranslation } from 'react-i18next'
import { ChainInfo } from '../../../../rtk/features/multiChainInfo/types'
import { FormatBalance } from '../../../common/balances/Balance'
Expand All @@ -13,6 +11,7 @@ import { convertToBalanceWithDecimal } from '../../../common/balances/utils'
import styles from '../StakingTable.module.sass'
import { Action } from './StakingActionButtons'
import { BIGNUMBER_ZERO } from '../../../../config/app/consts'
import { BN } from '@polkadot/util'

type StakeAmountInputProps = {
form: FormInstance
Expand Down
1 change: 0 additions & 1 deletion src/pages/_app.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ import 'src/styles/subsocial.scss'
import 'src/styles/subsocial-mobile.scss'

import React, { useEffect } from 'react'
import Head from 'next/head'
import { GoogleAnalytics } from 'nextjs-google-analytics'
import NextLayout from '../layout/NextLayout'
import { wrapper } from '../rtk/app/store'
Expand Down
3 changes: 1 addition & 2 deletions src/utils/balance.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import BN from 'bn.js'
import { BN_ZERO } from '@polkadot/util'
import { BN_ZERO, BN } from '@polkadot/util'
import { AccountInfoByChain } from 'src/components/identity/types'

export const getTransferableBalance = (
Expand Down
Loading

0 comments on commit edc54ce

Please sign in to comment.