add picture to avatar, lint fixes

Signed-off-by: Lykke Axlin <lykkeaxlin@hotmail.com>

Co-authored-by: klaraab <klarabroman@live.se>
This commit is contained in:
Lykke Axlin
2021-10-12 16:35:35 +02:00
parent 1fb1f8d758
commit af4fd48b0b
9 changed files with 18 additions and 43 deletions
+1
View File
@@ -122,6 +122,7 @@ export class BazaarClient implements BazaarApi {
body: JSON.stringify({
entity_ref: stringifyEntityRef(entity),
user_id: this.identityApi.getUserId(),
picture: this.identityApi.getProfile()?.picture,
}),
});
}
@@ -28,6 +28,7 @@ import {
MenuList,
MenuItem,
ListItemText,
Link,
} from '@material-ui/core';
import {
Progress,
@@ -35,7 +36,6 @@ import {
IconLinkVerticalProps,
Avatar,
} from '@backstage/core-components';
import { Link } from 'react-router-dom';
import { useEntity } from '@backstage/plugin-catalog-react';
import { AboutField } from '@backstage/plugin-catalog';
import { StatusTag } from '../StatusTag';
@@ -95,6 +95,7 @@ export const EntityBazaarInfoCard = () => {
userId: obj.user_id,
entityRef: obj.entity_ref,
joinDate: obj.join_date,
picture: obj.picture,
};
return member;
@@ -299,10 +300,12 @@ export const EntityBazaarInfoCard = () => {
float: 'left',
marginRight: '0.3rem',
}}
picture={member.picture}
/>
<Link
className={classes.memberLink}
to={`http://github.com/${member.userId}`}
href={`http://github.com/${member.userId}`}
target="_blank"
>
{member?.userId}
</Link>
@@ -36,7 +36,8 @@ export const InputField = ({
placeholder,
required,
}: Props) => {
const label = inputType.charAt(0).toUpperCase() + inputType.slice(1);
const label =
inputType.charAt(0).toLocaleUpperCase('en-US') + inputType.slice(1);
return (
<Controller
@@ -30,7 +30,7 @@ type Props = {
};
export const InputSelector = ({ name, options, control, error }: Props) => {
const label = name.charAt(0).toUpperCase() + name.slice(1);
const label = name.charAt(0).toLocaleUpperCase('en-US') + name.slice(1);
return (
<Controller
+1
View File
@@ -20,6 +20,7 @@ export type Member = {
entityRef: EntityRef;
userId: string;
joinDate?: string;
picture?: string;
};
export type Status = 'ongoing' | 'proposed';