1
- import { type Interpolation , type Theme , useTheme } from "@emotion/react" ;
2
1
import Button from "@mui/material/Button" ;
3
2
import type { WorkspaceAgent , WorkspaceResource } from "api/typesGenerated" ;
4
3
import { DropdownArrow } from "components/DropdownArrow/DropdownArrow" ;
@@ -16,7 +15,6 @@ interface ResourcesProps {
16
15
}
17
16
18
17
export const Resources : FC < ResourcesProps > = ( { resources, agentRow } ) => {
19
- const theme = useTheme ( ) ;
20
18
const [ shouldDisplayHideResources , setShouldDisplayHideResources ] =
21
19
useState ( false ) ;
22
20
const displayResources = shouldDisplayHideResources
@@ -31,7 +29,7 @@ export const Resources: FC<ResourcesProps> = ({ resources, agentRow }) => {
31
29
< Stack
32
30
direction = "column"
33
31
spacing = { 0 }
34
- css = { { background : theme . palette . background . default } }
32
+ className = "bg-surface-primary"
35
33
>
36
34
{ displayResources . map ( ( resource ) => (
37
35
< ResourceCard
@@ -41,9 +39,9 @@ export const Resources: FC<ResourcesProps> = ({ resources, agentRow }) => {
41
39
/>
42
40
) ) }
43
41
{ hasHideResources && (
44
- < div css = { styles . buttonWrapper } >
42
+ < div className = "flex items-center justify-center mt-4" >
45
43
< Button
46
- css = { styles . showMoreButton }
44
+ className = "rounded-full w-full max-w-[260px]"
47
45
size = "small"
48
46
onClick = { ( ) => setShouldDisplayHideResources ( ( v ) => ! v ) }
49
47
>
@@ -55,18 +53,3 @@ export const Resources: FC<ResourcesProps> = ({ resources, agentRow }) => {
55
53
</ Stack >
56
54
) ;
57
55
} ;
58
-
59
- const styles = {
60
- buttonWrapper : {
61
- display : "flex" ,
62
- alignItems : "center" ,
63
- justifyContent : "center" ,
64
- marginTop : 16 ,
65
- } ,
66
-
67
- showMoreButton : {
68
- borderRadius : 9999 ,
69
- width : "100%" ,
70
- maxWidth : 260 ,
71
- } ,
72
- } satisfies Record < string , Interpolation < Theme > > ;
0 commit comments