Improve tests (#871)
This commit is contained in:
@ -41,7 +41,7 @@ export function CompanyAccountOwnerCell({ company }: OwnProps) {
|
||||
<PersonChip
|
||||
id={company.accountOwner.id}
|
||||
name={company.accountOwner?.displayName ?? ''}
|
||||
picture={company.accountOwner?.avatarUrl ?? ''}
|
||||
pictureUrl={company.accountOwner?.avatarUrl ?? ''}
|
||||
/>
|
||||
) : (
|
||||
<></>
|
||||
|
||||
@ -10,7 +10,6 @@ import { GET_PIPELINE_PROGRESS, GET_PIPELINES } from '@/pipeline/queries';
|
||||
import { BoardCardContext } from '@/pipeline/states/BoardCardContext';
|
||||
import { pipelineProgressIdScopedState } from '@/pipeline/states/pipelineProgressIdScopedState';
|
||||
import { selectedBoardCardsState } from '@/pipeline/states/selectedBoardCardsState';
|
||||
import { ChipVariant } from '@/ui/chip/components/EntityChip';
|
||||
import { DateEditableField } from '@/ui/editable-field/variants/components/DateEditableField';
|
||||
import { NumberEditableField } from '@/ui/editable-field/variants/components/NumberEditableField';
|
||||
import { IconCurrencyDollar, IconProgressCheck } from '@/ui/icon';
|
||||
@ -177,9 +176,8 @@ export function CompanyBoardCard() {
|
||||
<CompanyChip
|
||||
id={company.id}
|
||||
name={company.name}
|
||||
clickable
|
||||
picture={getLogoUrlFromDomainName(company.domainName)}
|
||||
variant={ChipVariant.transparent}
|
||||
pictureUrl={getLogoUrlFromDomainName(company.domainName)}
|
||||
clickable={false}
|
||||
/>
|
||||
<StyledCheckboxContainer className="checkbox-container">
|
||||
<Checkbox
|
||||
|
||||
@ -1,29 +1,25 @@
|
||||
import { ChipVariant, EntityChip } from '@/ui/chip/components/EntityChip';
|
||||
import { EntityChip } from '@/ui/chip/components/EntityChip';
|
||||
|
||||
type OwnProps = {
|
||||
id: string;
|
||||
name: string;
|
||||
picture?: string;
|
||||
pictureUrl?: string;
|
||||
clickable?: boolean;
|
||||
variant?: ChipVariant;
|
||||
};
|
||||
|
||||
export function CompanyChip({
|
||||
id,
|
||||
name,
|
||||
picture,
|
||||
clickable,
|
||||
variant = ChipVariant.opaque,
|
||||
pictureUrl,
|
||||
clickable = true,
|
||||
}: OwnProps) {
|
||||
return (
|
||||
<EntityChip
|
||||
entityId={id}
|
||||
linkToEntity={`/companies/${id}`}
|
||||
linkToEntity={clickable ? `/companies/${id}` : undefined}
|
||||
name={name}
|
||||
avatarType="squared"
|
||||
clickable={clickable}
|
||||
picture={picture}
|
||||
variant={variant}
|
||||
pictureUrl={pictureUrl}
|
||||
/>
|
||||
);
|
||||
}
|
||||
|
||||
@ -38,7 +38,7 @@ export function CompanyEditableNameChipCell({ company }: OwnProps) {
|
||||
id={company.id}
|
||||
name={company.name}
|
||||
clickable
|
||||
picture={getLogoUrlFromDomainName(company.domainName)}
|
||||
pictureUrl={getLogoUrlFromDomainName(company.domainName)}
|
||||
/>
|
||||
}
|
||||
onSubmit={() =>
|
||||
|
||||
Reference in New Issue
Block a user