1234567891011121314151617 |
- import React from "react";
- import { connect } from "react-redux";
- import icon from "../icon.jpg";
- function AvaLogo({px, mrgn, link}) {
- // Import result is the URL of your image
- return (
- <img src={link ? "http://localhost:3000/" + link : icon} className="ava" style={{ width: px, marginRight: mrgn, borderRadius: "50%" }}/>
- );
- }
- const ConnectedAvaLogo = connect((state) => ({
- link: state?.promise?.findUser?.payload?.data?.UserFindOne?.avatar?.url,
- }))(AvaLogo);
- //'http://localhost:3000/images/5d6600e2254cff050d32c6967bcf3104'
- export default ConnectedAvaLogo;
|