diff --git a/src/Card/CardSet.tsx b/src/Card/CardSet.tsx index ed5e39f0e..823acf647 100644 --- a/src/Card/CardSet.tsx +++ b/src/Card/CardSet.tsx @@ -1,19 +1,13 @@ -import React from "react"; import styled from "styled-components"; import { space } from "styled-system"; -import { Box } from "../Box"; -import { BoxProps } from "../Box/Box"; -import Card from "./Card"; +import { Flex } from "../Flex"; -const UnstyledCardSet = ({ children = [], ...props }: BoxProps) => {children}; - -const CardSet = styled(UnstyledCardSet)(space, ({ theme }) => ({ - [`${Card}`]: { - marginBottom: theme.space.x1, - "&:last-child": { - marginBottom: theme.space.none, - }, - }, -})); +const CardSet = styled(Flex)( + ({ theme }) => ({ + flexDirection: "column", + gap: theme.space.x1, + }), + space +); export default CardSet;