Skip to content

Commit

Permalink
chore: APP-2462 PR feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
babarella committed Sep 29, 2023
1 parent f38eaa7 commit ea52216
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions src/components/headers/headerDao.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,7 @@ export const HeaderDao: React.FC<HeaderDaoProps> = ({
favorited = false,
links = [],
translation,
// eslint-disable-next-line @typescript-eslint/no-empty-function
onCopy = () => {},
onCopy,
onFavoriteClick,
}) => {
const [showAll, setShowAll] = useState(true);
Expand Down Expand Up @@ -103,15 +102,15 @@ export const HeaderDao: React.FC<HeaderDaoProps> = ({
const result = [
{
component: (
<CredentialsDropdownItem key={2} onClick={() => onCopy(daoAddress)}>
<CredentialsDropdownItem key={2} onClick={() => onCopy?.(daoAddress)}>
{shortenAddress(daoAddress)}
<StyledCopyIcon />
</CredentialsDropdownItem>
),
},
{
component: (
<CredentialsDropdownItem key={3} isLast onClick={() => onCopy(`https://${daoUrl}`)}>
<CredentialsDropdownItem key={3} isLast onClick={() => onCopy?.(`https://${daoUrl}`)}>
{shortenDaoUrl(daoUrl)}
<StyledCopyIcon />
</CredentialsDropdownItem>
Expand All @@ -122,7 +121,7 @@ export const HeaderDao: React.FC<HeaderDaoProps> = ({
if (daoEnsName) {
result.unshift({
component: (
<CredentialsDropdownItem key={1} onClick={() => onCopy(daoEnsName)}>
<CredentialsDropdownItem key={1} onClick={() => onCopy?.(daoEnsName)}>
{daoEnsName}
<StyledCopyIcon />
</CredentialsDropdownItem>
Expand Down

0 comments on commit ea52216

Please sign in to comment.