Add link to company page (#727)

* Add link to company page

* Have company chip background color matchin the card's

* Revert "Have company chip background color matchin the card's"

This reverts commit 8e9575fd933f9efb8d6614ec7287d6be28b81f7e.

* Create chip variants

* Lint

* code style

* Fix tests

* Fix tests

* Fix tests

---------

Co-authored-by: Charles Bochet <charles@twenty.com>
This commit is contained in:
Emilien Chauvet
2023-07-18 00:14:56 -07:00
committed by GitHub
parent 349caacb9f
commit e1b5463841
5 changed files with 54 additions and 18 deletions

View File

@ -1,13 +1,20 @@
import { EntityChip } from '@/ui/chip/components/EntityChip';
import { ChipVariant, EntityChip } from '@/ui/chip/components/EntityChip';
type OwnProps = {
id: string;
name: string;
picture?: string;
clickable?: boolean;
variant?: ChipVariant;
};
export function CompanyChip({ id, name, picture, clickable }: OwnProps) {
export function CompanyChip({
id,
name,
picture,
clickable,
variant = ChipVariant.opaque,
}: OwnProps) {
return (
<EntityChip
entityId={id}
@ -16,6 +23,7 @@ export function CompanyChip({ id, name, picture, clickable }: OwnProps) {
avatarType="squared"
clickable={clickable}
picture={picture}
variant={variant}
/>
);
}