diff --git a/package-lock.json b/package-lock.json index d9559f0..6c75b77 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,17 +1,17 @@ { "name": "@oceanprotocol/uploader-ui-lib", - "version": "0.1.5", + "version": "0.2.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@oceanprotocol/uploader-ui-lib", - "version": "0.1.5", + "version": "0.2.0", "license": "Apache-2.0", "dependencies": { "@ethersproject/units": "^5.7.0", "@oceanprotocol/typographies": "^0.1.0", - "@oceanprotocol/uploader": "^0.0.2-alpha.31", + "@oceanprotocol/uploader": "^0.0.2-alpha.32", "@tippyjs/react": "^4.2.6", "@types/react": "^17.0.59", "ajv": "^8.12.0", @@ -3946,9 +3946,9 @@ "integrity": "sha512-kMsZsqvzpz9KzVbVZzllwhPoIC3zbqsdRrClagZL/C2PHzgLrKGC1kYn3gPt0RMIFg9ZjrwieKaxlgIK9i9zzg==" }, "node_modules/@oceanprotocol/uploader": { - "version": "0.0.2-alpha.31", - "resolved": "https://registry.npmjs.org/@oceanprotocol/uploader/-/uploader-0.0.2-alpha.31.tgz", - "integrity": "sha512-YPwlepRggSpbw0lZ3ypirYo0nuN796Su3xBMbWIVe5zz+ax0FR+FTYjGd3YDwjFecAwn0Cr5/g7YI29NrB1jCA==", + "version": "0.0.2-alpha.32", + "resolved": "https://registry.npmjs.org/@oceanprotocol/uploader/-/uploader-0.0.2-alpha.32.tgz", + "integrity": "sha512-XQzSgRR71uLfxh7Lu7nwP8Zu56B3aeX36olg1e2MetfMjfba+zNNXhewkg9JcYaBA3IvFtAJpayRWT08WQGApg==", "dependencies": { "arweave": "^1.14.4", "axios": "^1.4.0", diff --git a/package.json b/package.json index dad6e63..91a4461 100644 --- a/package.json +++ b/package.json @@ -50,7 +50,7 @@ "dependencies": { "@ethersproject/units": "^5.7.0", "@oceanprotocol/typographies": "^0.1.0", - "@oceanprotocol/uploader": "^0.0.2-alpha.31", + "@oceanprotocol/uploader": "^0.0.2-alpha.32", "@tippyjs/react": "^4.2.6", "@types/react": "^17.0.59", "ajv": "^8.12.0", diff --git a/src/components/TabsFile/index.tsx b/src/components/TabsFile/index.tsx index e0414c6..893b8c2 100644 --- a/src/components/TabsFile/index.tsx +++ b/src/components/TabsFile/index.tsx @@ -73,6 +73,7 @@ export default function TabsFile({ const [uploadStatusResponse, setUploadStatusResponse] = useState('') const [ddoLink, setDDOLink] = useState('') + console.log('quote tokenAmount', quote) const mockedDataHistory = [ { quoteId: '93254d6a389ca6eb07ff548810b27eb1', @@ -218,6 +219,8 @@ export default function TabsFile({ }) console.log('Quote result:', quoteResult) setQuote(quoteResult) + console.log('quoteResult.tokenAmount', quoteResult.tokenAmount) + console.log('quote tokenAmount', quote) // Check if user has wrapped matic in their wallet const quotePrice = BigInt(quoteResult.tokenAmount) @@ -286,10 +289,12 @@ export default function TabsFile({ }: any) => { try { console.log('uploading: ', { quoteId, payment, quoteFee, files, type }) + console.log('String(quoteFee)', String(quoteFee)) + const newQuoteFee = BigInt(quoteFee) + BigInt(3000000000000000) const quoteAndUploadResult: any = await uploaderClient.uploadBrowser( quoteId, payment, - String(quoteFee), + String(newQuoteFee), files as FileList, type ) @@ -357,6 +362,7 @@ export default function TabsFile({ case 'upload': setUploadIsLoading(true) // Upload File + console.log('String(quote.tokenAmount)', String(quote.tokenAmount)) await getUpload({ quoteId: quote.quoteId, payment: quote.tokenAddress,