Refactor block component
This commit is contained in:
parent
b710f45b46
commit
74a194fe53
@ -1,6 +1,5 @@
|
||||
import { useState, useEffect } from "react";
|
||||
|
||||
import Block from "./components/block";
|
||||
import classNames from "classnames";
|
||||
|
||||
import Container from "components/services/widget/container";
|
||||
|
||||
@ -53,3 +52,17 @@ export default function Component({ service }) {
|
||||
</Container>
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
function Block({ children }) {
|
||||
return (
|
||||
<div
|
||||
className={classNames(
|
||||
"bg-theme-200/50 dark:bg-theme-900/20 rounded m-1 flex-1 flex flex-col items-center justify-center text-center p-1",
|
||||
"service-block"
|
||||
)}
|
||||
>
|
||||
{children}
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
@ -1,14 +0,0 @@
|
||||
import classNames from "classnames";
|
||||
|
||||
export default function Block({ children }) {
|
||||
return (
|
||||
<div
|
||||
className={classNames(
|
||||
"bg-theme-200/50 dark:bg-theme-900/20 rounded m-1 flex-1 flex flex-col items-center justify-center text-center p-1",
|
||||
"service-block"
|
||||
)}
|
||||
>
|
||||
{children}
|
||||
</div>
|
||||
);
|
||||
}
|
||||
Loading…
Reference in New Issue
Block a user