File size: 7,346 Bytes
15975c4
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
import { useState } from 'react';
import { Stack, Typography, Card, CardContent, CardMedia, CardHeader, Collapse, CardActions, Button, IconButton, Avatar } from '@mui/material';

import FavoriteIcon from "@mui/icons-material/FavoriteOutlined";
import ShareIcon from "@mui/icons-material/ShareOutlined";
import ExpandMoreIcon from "@mui/icons-material/ExpandMoreOutlined";
import ExpandLessIcon from "@mui/icons-material/ExpandLessOutlined";
import MoreVertIcon from "@mui/icons-material/MoreVertOutlined";

export const CardView = () => {
    const [expanded, setExpanded] = useState(false);

    const handleExpandClick = () => {
        setExpanded(!expanded);
    }

    return (
        <Stack spacing={3}>
            <Typography variant="h6" fontWeight="bold">
                Cards
            </Typography>
            <Stack direction='row' spacing={2} flexWrap={'wrap'}>
                <Card variant="elevation">
                    <CardContent>
                        <Typography gutterBottom variant="h5">
                            Play relaxing songs
                        </Typography>
                        <Typography variant="body2">
                            From your recent favorites
                        </Typography>
                    </CardContent>
                    <CardActions sx={{ display: 'flex', justifyContent: 'flex-end' }}>
                        <Button variant="filled" size="small">Get started</Button>
                    </CardActions>
                </Card>
                <Card variant="filled">
                    <CardContent>
                        <Typography gutterBottom variant="h5" >
                            Play relaxing songs
                        </Typography>
                        <Typography variant="body2">
                            From your recent favorites
                        </Typography>
                    </CardContent>
                    <CardActions sx={{ display: 'flex', justifyContent: 'flex-end' }}>
                        <Button variant="outlined" sx={{ background: (theme) => theme.palette.surfaceContainer.main }} >
                            Get started
                        </Button>
                    </CardActions>
                </Card>
                <Card variant="outlined">
                    <CardContent>
                        <Typography gutterBottom variant="h5" >
                            Play relaxing songs
                        </Typography>
                        <Typography variant="body2">
                            From your recent favorites
                        </Typography>
                    </CardContent>
                    <CardActions sx={{ display: 'flex', justifyContent: 'flex-end' }}>
                        <Button variant="tonal" size="small">Get started</Button>
                    </CardActions>
                </Card>
            </Stack>
            <Stack>
                <Card sx={{ maxWidth: 345, px: 0, paddingTop: 0 }} variant="elevation">
                    <CardMedia sx={{ height: 0, paddingTop: '56.25%', borderRadius: 5 }}
                        image="https://material-ui.com/static/images/cards/paella.jpg"
                        title="Paella dish"
                    />
                    <CardHeader
                        avatar={<Avatar sx={{ background: (theme) => theme.palette.primary.main, color: (theme) => theme.palette.primary.contrastText }}>R</Avatar>}
                        action={
                            <IconButton color="inherit">
                                <MoreVertIcon />
                            </IconButton>
                        }
                        title="Shrimp and Chorizo Paella"
                        subheader="September 14, 2016"
                    />
                    <CardContent>
                        <Typography variant="body2" component="p" color="textPrimary">
                            This impressive paella is a perfect party dish and a fun meal to
                            cook together with your guests. Add 1 cup of frozen peas along
                            with the mussels, if you like.
                        </Typography>
                    </CardContent>
                    <CardActions disableSpacing>
                        <IconButton color="inherit">
                            <FavoriteIcon />
                        </IconButton>
                        <IconButton color="inherit">
                            <ShareIcon />
                        </IconButton>
                        <IconButton color="inherit"
                            onClick={handleExpandClick}
                            aria-expanded={expanded}
                            aria-label="show more"
                        >
                            {expanded ? <ExpandLessIcon /> : <ExpandMoreIcon />}
                        </IconButton>
                    </CardActions>
                    <Collapse in={expanded} timeout="auto" unmountOnExit>
                        <CardContent>
                            <Typography paragraph>Method:</Typography>
                            <Typography paragraph>
                                Heat 1/2 cup of the broth in a pot until simmering, add saffron
                                and set aside for 10 minutes.
                            </Typography>
                            <Typography paragraph>
                                Heat oil in a (14- to 16-inch) paella pan or a large, deep
                                skillet over medium-high heat. Add chicken, shrimp and chorizo,
                                and cook, stirring occasionally until lightly browned, 6 to 8
                                minutes. Transfer shrimp to a large plate and set aside, leaving
                                chicken and chorizo in the pan. Add pimentón, bay leaves,
                                garlic, tomatoes, onion, salt and pepper, and cook, stirring
                                often until thickened and fragrant, about 10 minutes. Add
                                saffron broth and remaining 4 1/2 cups chicken broth; bring to a
                                boil.
                            </Typography>
                            <Typography paragraph>
                                Add rice and stir very gently to distribute. Top with artichokes
                                and peppers, and cook without stirring, until most of the liquid
                                is absorbed, 15 to 18 minutes. Reduce heat to medium-low, add
                                reserved shrimp and mussels, tucking them down into the rice,
                                and cook again without stirring, until mussels have opened and
                                rice is just tender, 5 to 7 minutes more. (Discard any mussels
                                that don’t open.)
                            </Typography>
                            <Typography>
                                Set aside off of the heat to let rest for 10 minutes, and then
                                serve.
                            </Typography>
                        </CardContent>
                    </Collapse>
                </Card>
            </Stack>
        </Stack>
    );
}