diff --git a/frontend/src/components/Dashboard/Tiles/Tile/Tile.tsx b/frontend/src/components/Dashboard/Tiles/Tile/Tile.tsx
index a3735e253..541dc9b74 100644
--- a/frontend/src/components/Dashboard/Tiles/Tile/Tile.tsx
+++ b/frontend/src/components/Dashboard/Tiles/Tile/Tile.tsx
@@ -1,7 +1,11 @@
import Link from 'next/link';
-import { StyledTile, TileArrow, TileBlob } from '@/components/Dashboard/Tiles/Tile/styles';
-import Flex from '@/components/Primitives/Layout/Flex/Flex';
+import {
+ StyledTile,
+ TileArrow,
+ TileBlob,
+ TileTextContainer,
+} from '@/components/Dashboard/Tiles/Tile/styles';
import Text from '@/components/Primitives/Text/Text';
export type TileProps = {
@@ -11,35 +15,19 @@ export type TileProps = {
color: 'purple' | 'blue' | 'yellow';
};
-const Tile = ({ link, title, count, color }: TileProps) => {
- const styles =
- color === 'yellow'
- ? {
- width: '127px',
- height: '76px',
- bottom: '-1px',
- }
- : {
- width: '100px',
- height: '100px',
- top: '0',
- };
-
- return (
-
-
-
-
- {title}
-
- {count}
-
-
-
-
-
-
- );
-};
+const Tile = ({ link, title, count, color }: TileProps) => (
+
+
+
+
+
+ {title}
+
+ {count}
+
+
+
+
+);
export default Tile;
diff --git a/frontend/src/components/Dashboard/Tiles/Tile/styles.tsx b/frontend/src/components/Dashboard/Tiles/Tile/styles.tsx
index 33f2b0e04..0bfaa63c9 100644
--- a/frontend/src/components/Dashboard/Tiles/Tile/styles.tsx
+++ b/frontend/src/components/Dashboard/Tiles/Tile/styles.tsx
@@ -1,11 +1,17 @@
import Icon from '@/components/Primitives/Icons/Icon/Icon';
+import Flex from '@/components/Primitives/Layout/Flex/Flex';
import { styled } from '@/styles/stitches/stitches.config';
-const StyledTile = styled('div', {
+const StyledTile = styled(Flex, {
position: 'relative',
borderRadius: '$12',
color: '$primary50',
backgroundColor: '$primary800',
+ overflow: 'hidden',
+
+ py: '$20',
+ px: '$24',
+
h3: {
margin: 0,
color: 'white',
@@ -13,22 +19,44 @@ const StyledTile = styled('div', {
lineHeight: '$36',
fontWeight: '$bold',
},
+
'@hover': {
cursor: 'pointer',
},
});
const TileArrow = styled(Icon, {
- position: 'absolute',
- right: '$20',
- top: '50%',
- bottom: '$-1',
color: '$black',
+ position: 'relative', // Force it to be above TileBlob
+ alignSelf: 'flex-end',
});
const TileBlob = styled(Icon, {
position: 'absolute',
right: '$-1',
+
+ width: '$100 !important',
+ height: '$100 !important',
+
+ top: 0,
+
+ variants: {
+ color: {
+ yellow: {
+ width: '$127 !important',
+ height: '$76 !important',
+ bottom: 0,
+ top: 'unset',
+ },
+ purple: {},
+ blue: {},
+ },
+ },
+});
+
+const TileTextContainer = styled(Flex, {
+ position: 'relative', // Force it to be above TileBlob
+ textShadow: '-1px 0 black, 0 1px black, 1px 0 black, 0 -1px black', // Text borders so that it can be visible when above the TileBlob
});
-export { StyledTile, TileArrow, TileBlob };
+export { StyledTile, TileArrow, TileBlob, TileTextContainer };
diff --git a/frontend/src/components/Dashboard/Tiles/Tiles.tsx b/frontend/src/components/Dashboard/Tiles/Tiles.tsx
index 771375481..735e98c39 100644
--- a/frontend/src/components/Dashboard/Tiles/Tiles.tsx
+++ b/frontend/src/components/Dashboard/Tiles/Tiles.tsx
@@ -1,5 +1,7 @@
-import { TileContainer } from '@/components/Dashboard/Tiles/styles';
+import React from 'react';
+
import Tile from '@/components/Dashboard/Tiles/Tile/Tile';
+import Flex from '@/components/Primitives/Layout/Flex/Flex';
import { HeaderInfo } from '@/types/dashboard/header.info';
import { BOARDS_ROUTE, TEAMS_ROUTE, USERS_ROUTE } from '@/utils/routes';
@@ -8,11 +10,11 @@ export type TilesProps = {
};
const Tiles = ({ data }: TilesProps) => (
-
+ *': { flex: 1 } }} gap="26" wrap="wrap">
-
+
);
export default Tiles;
diff --git a/frontend/src/components/Dashboard/Tiles/styles.tsx b/frontend/src/components/Dashboard/Tiles/styles.tsx
deleted file mode 100644
index 7d7cd57b0..000000000
--- a/frontend/src/components/Dashboard/Tiles/styles.tsx
+++ /dev/null
@@ -1,9 +0,0 @@
-import { styled } from '@/styles/stitches/stitches.config';
-
-const TileContainer = styled('section', {
- display: 'grid',
- gap: '$29',
- gridTemplateColumns: 'repeat(3, 1fr)',
-});
-
-export { TileContainer };