mirror of
https://github.com/D4M13N-D3V/comissions-app-ui.git
synced 2025-03-14 00:05:07 +00:00
added tooltips
This commit is contained in:
parent
f1514c39a8
commit
6cb5dbc2a9
@ -16,13 +16,14 @@ import AccordionDetails from '@mui/material/AccordionDetails';
|
||||
import ExpandMoreIcon from '@mui/icons-material/ExpandMore';
|
||||
import ArtistPortfolio from './artistPortfolio';
|
||||
import Button from '@mui/material/Button';
|
||||
import Tooltip from '@mui/material/Tooltip';
|
||||
import { useEffect, useState } from "react";
|
||||
import { fetchSeller } from "../services/DiscoveryService";
|
||||
|
||||
|
||||
import { IconButton } from '@mui/material';
|
||||
|
||||
const Artist = ({artistId}) => {
|
||||
const Artist = ({user, artistId}) => {
|
||||
const [sellerData, setSellerData] = useState([]);
|
||||
useEffect(() => {
|
||||
const getData = async () => {
|
||||
@ -53,8 +54,16 @@ const Artist = ({artistId}) => {
|
||||
</Grid>
|
||||
<Grid item xs={6} md={4}>
|
||||
<Grid item xs={6} md={4}>
|
||||
<Button color="secondary" variant='contained' sx={{width:150 }}>Request Order</Button>
|
||||
<Button href={"seller/"+artistId} color="primary" variant='contained' sx={{width:150, marginTop:2}}>View Profile</Button>
|
||||
<Button href={"seller/"+artistId} color="primary" variant='contained' sx={{width:150}}>View Profile</Button>
|
||||
{user ? (
|
||||
<Button color="secondary" variant='contained' sx={{ width: 150, marginTop:2 }}>Request Order</Button>
|
||||
) : (
|
||||
<Tooltip title="Log in order to place a request.">
|
||||
<span>
|
||||
<Button disabled color="secondary" variant='contained' sx={{ width: 150, marginTop:2 }}>Request Order</Button>
|
||||
</span>
|
||||
</Tooltip>
|
||||
)}
|
||||
</Grid>
|
||||
</Grid>
|
||||
<Grid item xs={12} md={12}>
|
||||
|
@ -62,7 +62,7 @@ const Home = () => {
|
||||
) : (
|
||||
<>
|
||||
{sellersData.map((item) => (
|
||||
<Artist artistId={item.id} />
|
||||
<Artist user={user} artistId={item.id} />
|
||||
))}
|
||||
</>
|
||||
)}
|
||||
|
Loading…
x
Reference in New Issue
Block a user