diff --git a/src/components/atoms/Box.module.css b/src/components/atoms/Box.module.css
index d9b08d2be..4c447e9ed 100644
--- a/src/components/atoms/Box.module.css
+++ b/src/components/atoms/Box.module.css
@@ -1,14 +1,16 @@
.box {
+ display: block;
background: var(--brand-white);
- padding: var(--spacer);
border-radius: var(--border-radius);
- border: 1px solid var(--brand-grey-light);
+ border: 1px solid var(--brand-grey-lighter);
+ box-shadow: 0 6px 15px 0 rgba(0, 0, 0, 0.05);
+ overflow: hidden;
+ padding: var(--spacer);
}
a.box:hover,
a.box:focus {
outline: 0;
- border-color: var(--brand-pink);
- /* box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1); */
- /* transform: translate3d(0, -2px, 0); */
+ transform: translate3d(0, -0.1rem, 0);
+ box-shadow: 0 10px 25px 0 rgba(0, 0, 0, 0.07);
}
diff --git a/src/components/atoms/Dropzone.module.css b/src/components/atoms/Dropzone.module.css
index 61e156f97..363a2530b 100644
--- a/src/components/atoms/Dropzone.module.css
+++ b/src/components/atoms/Dropzone.module.css
@@ -1,12 +1,16 @@
.dropzone {
- padding: 22px;
+ padding: var(--spacer);
text-align: center;
color: var(--color-secondary);
- border: 2px dashed var(--color-primary);
+ border: 0.1rem dashed var(--color-secondary);
+ font-size: var(--font-size-small);
+ border-radius: var(--border-radius);
}
+
.dragover {
- border-color: var(--color-secondary);
+ border-color: var(--color-primary);
}
+
.disabled {
}
diff --git a/src/components/atoms/Price.module.css b/src/components/atoms/Price.module.css
index a88de0f99..955c01c54 100644
--- a/src/components/atoms/Price.module.css
+++ b/src/components/atoms/Price.module.css
@@ -7,10 +7,10 @@
.price span {
font-weight: var(--font-weight-base);
color: var(--color-secondary);
- font-size: var(--font-size-small);
+ font-size: var(--font-size-base);
}
.small {
- transform: scale(0.8);
+ transform: scale(0.7);
transform-origin: left 80%;
}
diff --git a/src/components/atoms/Price.tsx b/src/components/atoms/Price.tsx
index f6f4e35a6..511aadf9f 100644
--- a/src/components/atoms/Price.tsx
+++ b/src/components/atoms/Price.tsx
@@ -1,7 +1,10 @@
-import React from 'react'
+import React, { ReactElement } from 'react'
import Web3 from 'web3'
+import classNames from 'classnames/bind'
import styles from './Price.module.css'
+const cx = classNames.bind(styles)
+
export default function Price({
price,
className,
@@ -10,11 +13,15 @@ export default function Price({
price: string
className?: string
small?: boolean
-}) {
- const classes = small
- ? `${styles.price} ${styles.small} ${className}`
- : `${styles.price} ${className}`
+}): ReactElement {
+ const styleClasses = cx({
+ price: true,
+ small: small,
+ [className]: className
+ })
+
const isFree = price === '0'
+
const displayPrice = isFree ? (
'Free'
) : (
@@ -23,5 +30,5 @@ export default function Price({
>
)
- return
{displayPrice}
+ return {displayPrice}
}
diff --git a/src/components/atoms/Status.module.css b/src/components/atoms/Status.module.css
index 4fccb0308..34dfcbfba 100644
--- a/src/components/atoms/Status.module.css
+++ b/src/components/atoms/Status.module.css
@@ -1,10 +1,10 @@
/* default: success, green circle */
.status {
- width: var(--font-size-small);
- height: var(--font-size-small);
+ width: var(--font-size-mini);
+ height: var(--font-size-mini);
border-radius: 50%;
display: inline-block;
- background: var(--green);
+ background: var(--brand-alert-green);
}
/* yellow triangle */
@@ -14,15 +14,15 @@
background: none;
width: 0;
height: 0;
- border-left: calc(var(--font-size-small) / 1.7) solid transparent;
- border-right: calc(var(--font-size-small) / 1.7) solid transparent;
- border-bottom: var(--font-size-small) solid var(--orange);
+ border-left: calc(var(--font-size-mini) / 1.7) solid transparent;
+ border-right: calc(var(--font-size-mini) / 1.7) solid transparent;
+ border-bottom: var(--font-size-mini) solid var(--brand-alert-orange);
}
/* red square */
.error {
composes: status;
border-radius: 0;
- background: var(--red);
+ background: var(--brand-alert-red);
text-transform: capitalize;
}
diff --git a/src/components/atoms/Status.tsx b/src/components/atoms/Status.tsx
index 7a14e7a3e..123f35d18 100644
--- a/src/components/atoms/Status.tsx
+++ b/src/components/atoms/Status.tsx
@@ -1,7 +1,7 @@
-import React from 'react'
+import React, { ReactElement } from 'react'
import styles from './Status.module.css'
-export default function Status({ state }: { state?: string }) {
+export default function Status({ state }: { state?: string }): ReactElement {
const classes =
state === 'error'
? styles.error
diff --git a/src/components/molecules/AssetTeaser.module.css b/src/components/molecules/AssetTeaser.module.css
index e33261eaf..d5a9e3375 100644
--- a/src/components/molecules/AssetTeaser.module.css
+++ b/src/components/molecules/AssetTeaser.module.css
@@ -7,7 +7,7 @@
composes: box from '../atoms/Box.module.css';
font-size: var(--font-size-small);
height: 100%;
- color: var(--brand-grey-dark);
+ color: var(--color-secondary);
position: relative;
/* for sticking footer to bottom */
display: flex;
@@ -18,59 +18,35 @@
overflow-wrap: break-word;
word-wrap: break-word;
word-break: break-all;
- margin-top: calc(var(--spacer) / 2);
/* for sticking footer to bottom */
flex: 1;
}
.title {
- font-size: var(--font-size-h4);
- color: var(--color-primary);
- margin-bottom: calc(var(--spacer) / 6);
-}
-
-.tags > * {
- font-size: var(--font-size-mini);
+ font-size: var(--font-size-large);
+ margin-bottom: calc(var(--spacer) / 4);
}
.foot {
- color: var(--color-secondary);
font-weight: var(--font-weight-bold);
margin-top: calc(var(--spacer) / 1.5);
- border-top: 1px solid var(--brand-grey-light);
+ border-top: 1px solid var(--brand-grey-lighter);
padding-top: calc(var(--spacer) / 3);
- display: flex;
- flex-wrap: wrap;
- justify-content: space-between;
- align-items: center;
}
.foot p {
margin: 0;
}
-.price {
- text-align: right;
-}
-
-p.copyright {
- width: 100%;
- font-weight: var(--font-weight-base);
- margin-bottom: 0;
- font-size: var(--font-size-mini);
- text-align: center;
- margin-top: calc(var(--spacer) / 3);
-}
-
.accessLabel {
- font-size: var(--font-size-small);
+ font-size: var(--font-size-mini);
width: auto;
position: absolute;
top: 0;
right: 0;
color: var(--brand-black);
background: var(--brand-grey-lighter);
- padding: 0.1px 0.5px 0.1px 0.5px;
- border-radius: 2px;
+ padding: 0.2rem 0.5rem;
+ border-bottom-left-radius: var(--border-radius);
}
diff --git a/src/components/molecules/AssetTeaser.tsx b/src/components/molecules/AssetTeaser.tsx
index b90b2f198..4c793119a 100644
--- a/src/components/molecules/AssetTeaser.tsx
+++ b/src/components/molecules/AssetTeaser.tsx
@@ -48,13 +48,7 @@ const AssetTeaser: React.FC = ({
diff --git a/src/components/molecules/PageHeader.module.css b/src/components/molecules/PageHeader.module.css
index f23a2284c..2cd697c68 100644
--- a/src/components/molecules/PageHeader.module.css
+++ b/src/components/molecules/PageHeader.module.css
@@ -4,6 +4,7 @@
}
.title {
+ font-size: var(--font-size-h2);
margin-top: 0;
margin-bottom: 0;
}
diff --git a/src/components/molecules/PageHeader.tsx b/src/components/molecules/PageHeader.tsx
index 01f8c452a..b3f627a6e 100644
--- a/src/components/molecules/PageHeader.tsx
+++ b/src/components/molecules/PageHeader.tsx
@@ -1,15 +1,23 @@
-import React from 'react'
+import React, { ReactElement } from 'react'
+import classNames from 'classnames/bind'
import styles from './PageHeader.module.css'
+const cx = classNames.bind(styles)
+
export default function PageHeader({
title,
description
}: {
title: string
description?: string
-}) {
+ center?: boolean
+}): ReactElement {
+ const styleClasses = cx({
+ header: true
+ })
+
return (
-
+
{title}
{description && {description}
}
diff --git a/src/components/molecules/Web3Feedback/index.module.css b/src/components/molecules/Web3Feedback/index.module.css
index 788dd471f..b85cba9b2 100644
--- a/src/components/molecules/Web3Feedback/index.module.css
+++ b/src/components/molecules/Web3Feedback/index.module.css
@@ -10,9 +10,6 @@
.statuscontainer {
flex-grow: 1;
}
-.statuscontainer h3 {
- margin-top: 0;
-}
.walletcontainer {
width: 35%;
diff --git a/src/components/organisms/AssetContent/MetaFull.module.css b/src/components/organisms/AssetContent/MetaFull.module.css
index f9d8586d2..35b51e49e 100644
--- a/src/components/organisms/AssetContent/MetaFull.module.css
+++ b/src/components/organisms/AssetContent/MetaFull.module.css
@@ -3,7 +3,7 @@
font-size: var(--font-size-small);
padding: var(--spacer);
border-radius: var(--border-radius);
- border: 1px solid var(--brand-grey-light);
+ background: var(--brand-grey-dimmed);
display: grid;
gap: var(--spacer);
grid-template-columns: 1fr 1fr;
@@ -11,5 +11,5 @@
.metaFull code {
/* magic number cause the code font has a bigger visual weight */
- font-size: 0.7rem;
+ font-size: 0.8rem;
}
diff --git a/src/components/organisms/AssetContent/index.module.css b/src/components/organisms/AssetContent/index.module.css
index a0ef532c1..3cf9ea7bd 100644
--- a/src/components/organisms/AssetContent/index.module.css
+++ b/src/components/organisms/AssetContent/index.module.css
@@ -2,6 +2,7 @@
display: grid;
gap: calc(var(--spacer) * 1.5);
position: relative;
+ margin-top: -1rem;
}
@media (min-width: 55rem) {
@@ -27,11 +28,6 @@
margin-bottom: 0;
}
-.sectionTitle {
- font-size: var(--font-size-large);
- color: var(--color-secondary);
-}
-
.buttonGroup {
margin-top: var(--spacer);
margin-bottom: var(--spacer);
diff --git a/src/components/organisms/AssetContent/index.tsx b/src/components/organisms/AssetContent/index.tsx
index 2606bd145..8069a65d5 100644
--- a/src/components/organisms/AssetContent/index.tsx
+++ b/src/components/organisms/AssetContent/index.tsx
@@ -51,10 +51,7 @@ export default function AssetContent({
-
Summary
{tags && tags.length > 0 &&
}
diff --git a/src/components/organisms/AssetList.tsx b/src/components/organisms/AssetList.tsx
index fd96655da..53385b566 100644
--- a/src/components/organisms/AssetList.tsx
+++ b/src/components/organisms/AssetList.tsx
@@ -38,7 +38,7 @@ const AssetList: React.FC
= ({ queryResult }) => {
return (
<>
- {queryResult.results &&
+ {queryResult &&
queryResult.results.map((ddo: DDO) => {
const { attributes }: MetaDataMarket = new DDO(
ddo
diff --git a/src/components/organisms/Compute.module.css b/src/components/organisms/Compute.module.css
index aa5609d5e..2e5ce5a6d 100644
--- a/src/components/organisms/Compute.module.css
+++ b/src/components/organisms/Compute.module.css
@@ -6,7 +6,7 @@
width: 100%;
margin-top: var(--spacer);
padding-top: var(--spacer);
- border-top: 1px solid var(--color-secondary);
+ border-top: 1px solid var(--brand-grey-lighter);
}
.compute {
@@ -14,22 +14,18 @@
display: flex;
flex-wrap: wrap;
}
+
.compute button {
margin-left: var(--spacer);
}
+
.compute button:first {
margin-left: 0px;
}
-.price {
- font-size: var(--font-size-h2);
- /* padding-bottom: var(--spacer); */
-}
.info {
+ margin-top: var(--spacer);
display: flex;
flex-direction: column;
width: 100%;
- /* padding-top: calc(var(--spacer) * 0.5);
- padding-bottom: var(--spacer);
- border-top: 1px solid var(--color-secondary); */
}
diff --git a/src/components/organisms/Compute.tsx b/src/components/organisms/Compute.tsx
index df7c1d702..5c4f62541 100644
--- a/src/components/organisms/Compute.tsx
+++ b/src/components/organisms/Compute.tsx
@@ -96,7 +96,7 @@ export default function Compute({
return (
-
+
diff --git a/src/components/organisms/Consume.module.css b/src/components/organisms/Consume.module.css
index 6bbd06cfc..616f83a67 100644
--- a/src/components/organisms/Consume.module.css
+++ b/src/components/organisms/Consume.module.css
@@ -13,9 +13,6 @@
flex-shrink: 0;
}
-.pricewrapper {
-}
-
.consume button {
margin-left: calc(var(--spacer) / 4);
}
@@ -25,18 +22,13 @@
}
.price {
- font-size: var(--font-size-h2);
margin-top: calc(var(--spacer) / 4);
margin-bottom: calc(var(--spacer) / 2);
}
-.price span {
- font-size: var(--font-size-large);
-}
-
.feedback {
width: 100%;
margin-top: calc(var(--spacer) / 1.5);
padding-top: calc(var(--spacer) / 1.5);
- border-top: 1px solid var(--brand-grey-light);
+ border-top: 1px solid var(--brand-grey-lighter);
}
diff --git a/src/components/organisms/Header.tsx b/src/components/organisms/Header.tsx
index 4487afe73..f0fea3b3a 100644
--- a/src/components/organisms/Header.tsx
+++ b/src/components/organisms/Header.tsx
@@ -1,11 +1,11 @@
-import React from 'react'
+import React, { ReactElement } from 'react'
import { Link } from 'gatsby'
import Menu from '../molecules/Menu'
import styles from './Header.module.css'
import { ReactComponent as Logo } from '@oceanprotocol/art/logo/logo.svg'
import { useSiteMetadata } from '../../hooks/useSiteMetadata'
-export default function Header() {
+export default function Header(): ReactElement {
const { siteTitle } = useSiteMetadata()
return (
diff --git a/src/components/pages/Home.module.css b/src/components/pages/Home.module.css
new file mode 100644
index 000000000..a20445c26
--- /dev/null
+++ b/src/components/pages/Home.module.css
@@ -0,0 +1,3 @@
+.grid {
+ composes: assetList from '../organisms/AssetList.module.css';
+}
diff --git a/src/components/pages/Home.tsx b/src/components/pages/Home.tsx
index 481501a66..1afd2f1b9 100644
--- a/src/components/pages/Home.tsx
+++ b/src/components/pages/Home.tsx
@@ -1,9 +1,9 @@
import React, { ReactElement } from 'react'
import SearchBar from '../molecules/SearchBar'
-import { DID } from '@oceanprotocol/squid'
-import { Link } from 'gatsby'
import shortid from 'shortid'
import { OceanAsset } from '../../@types/MetaData'
+import AssetTeaser from '../molecules/AssetTeaser'
+import styles from './Home.module.css'
export default function HomePage({
assets
@@ -16,13 +16,15 @@ export default function HomePage({
<>
{assets && (
-