Fixed #480 In Secure-mode, "Need help" icon shows User profile image (#490)

This commit is contained in:
Sachin Chaurasiya 2021-09-14 19:17:35 +05:30 committed by GitHub
parent cb5e2196be
commit 4344a1ea19
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 21 additions and 24 deletions

View File

@ -206,7 +206,7 @@ const Appbar: React.FC = (): JSX.Element => {
icon={
<SVGIcons
alt="Doc icon"
className="tw-align-middle tw-mr-1"
className="tw-align-middle tw-mt-0.5 tw-mr-1"
icon={Icons.HELP_CIRCLE}
width="16"
/>
@ -226,14 +226,25 @@ const Appbar: React.FC = (): JSX.Element => {
},
]}
icon={
<IconDefaultUserProfile
className=""
style={{
height: '24px',
width: '24px',
borderRadius: '50%',
}}
/>
<>
{appState.userDetails.profile?.images.image512 ? (
<div className="profile-image">
<img
alt="user"
src={appState.userDetails.profile.images.image512}
/>
</div>
) : (
<IconDefaultUserProfile
className=""
style={{
height: '24px',
width: '24px',
borderRadius: '50%',
}}
/>
)}
</>
}
label=""
type="link"

View File

@ -17,7 +17,6 @@
import PropTypes from 'prop-types';
import React, { useState } from 'react';
import AppState from '../../AppState';
import { activeLink, normalLink } from '../../utils/styleconstant';
import { dropdownIcon as DropdownIcon } from '../../utils/svgconstant';
import AnchorDropDownList from './AnchorDropDownList';
@ -102,20 +101,7 @@ const DropDown: React.FC<DropDownProp> = ({
</>
) : (
<>
{Icon && (
<div className="">
{AppState.userDetails.profile?.images.image512 ? (
<div className="profile-image">
<img
alt="user"
src={AppState.userDetails.profile.images.image512}
/>
</div>
) : (
Icon
)}
</div>
)}
{Icon && Icon}
{label && (
<p
className="hover:tw-underline"