- {assets.length > 0 ? (
- assets.map((ddo) =>
)
+ {assetsWithPrices.length > 0 ? (
+ assetsWithPrices.map((assetWithPrice) => (
+
+ ))
) : (
No results found.
)}
@@ -52,6 +84,8 @@ const AssetList: React.FC
= ({
/>
)}
>
+ ) : (
+
)
}
diff --git a/src/components/pages/History/PublishedList.tsx b/src/components/pages/History/PublishedList.tsx
index 763e4f2ea..49f7a688a 100644
--- a/src/components/pages/History/PublishedList.tsx
+++ b/src/components/pages/History/PublishedList.tsx
@@ -1,7 +1,6 @@
import { Logger } from '@oceanprotocol/lib'
import { QueryResult } from '@oceanprotocol/lib/dist/node/metadatacache/MetadataCache'
import React, { ReactElement, useEffect, useState } from 'react'
-import Loader from '../../atoms/Loader'
import AssetList from '../../organisms/AssetList'
import axios from 'axios'
import { queryMetadata } from '../../../utils/aquarius'
@@ -48,14 +47,13 @@ export default function PublishedList(): ReactElement {
getPublished()
}, [accountId, page, config.metadataCacheUri])
- return isLoading ? (
-
- ) : accountId && queryResult ? (
+ return accountId ? (
{
setPage(newPage)
}}
diff --git a/src/components/pages/Home.module.css b/src/components/pages/Home.module.css
index 7491c49aa..e35169838 100644
--- a/src/components/pages/Home.module.css
+++ b/src/components/pages/Home.module.css
@@ -16,9 +16,3 @@
.section [class*='button'] {
margin-top: var(--spacer);
}
-
-.loaderWrap {
- display: flex;
- justify-content: center;
- align-items: center;
-}
diff --git a/src/components/pages/Home.tsx b/src/components/pages/Home.tsx
index eaab70ad1..401a3493c 100644
--- a/src/components/pages/Home.tsx
+++ b/src/components/pages/Home.tsx
@@ -7,7 +7,6 @@ import {
SearchQuery
} from '@oceanprotocol/lib/dist/node/metadatacache/MetadataCache'
import Container from '../atoms/Container'
-import Loader from '../atoms/Loader'
import { useOcean } from '../../providers/Ocean'
import Button from '../atoms/Button'
import Bookmarks from '../molecules/Bookmarks'
@@ -36,14 +35,6 @@ const queryLatest = {
sort: { created: -1 }
}
-function LoaderArea() {
- return (
-
-
-
- )
-}
-
function SectionQueryResult({
title,
query,
@@ -55,7 +46,6 @@ function SectionQueryResult({
}) {
const { config } = useOcean()
const [result, setResult] = useState()
- const [loading, setLoading] = useState(true)
useEffect(() => {
if (!config?.metadataCacheUri) return
@@ -69,7 +59,6 @@ function SectionQueryResult({
source.token
)
setResult(result)
- setLoading(false)
}
init()
@@ -81,11 +70,7 @@ function SectionQueryResult({
return (
{title}
- {loading ? (
-
- ) : (
- result &&
- )}
+
{action && action}
)
diff --git a/src/components/templates/Search/index.tsx b/src/components/templates/Search/index.tsx
index 0e4697d9a..f83e6efc0 100644
--- a/src/components/templates/Search/index.tsx
+++ b/src/components/templates/Search/index.tsx
@@ -82,19 +82,14 @@ export default function SearchPage({