Skip to content

A full-featured CRM built with React, shadcn/ui, and Supabase.

Fix activitylog prefix

fzaninottoed9d1b16470a
diff --git a/src/components/atomic-crm/activity/ActivityLogCompanyCreated.tsx b/src/components/atomic-crm/activity/ActivityLogCompanyCreated.tsx
index 0d005f37..ad8f1138 100644
--- a/src/components/atomic-crm/activity/ActivityLogCompanyCreated.tsx
+++ b/src/components/atomic-crm/activity/ActivityLogCompanyCreated.tsx
@@ -18,18 +18,18 @@ export function ActivityLogCompanyCreated({
const { company } = activity;
return (
<div className="p-0">
- <div className="flex flex-row space-x-1 items-center w-full">
+ <div className="flex flex-row space-x-1 items-start w-full">
<CompanyAvatar width={20} height={20} record={company} />
<span className="text-muted-foreground text-sm flex-grow">
<ReferenceField source="sales_id" reference="sales" record={activity}>
<SaleName />
- </ReferenceField>
- &nbsp;added company&nbsp;
+ </ReferenceField>{" "}
+ added company{" "}
<Link to={`/companies/${company.id}/show`}>{company.name}</Link>
{context === "all" && (
<>
- &nbsp;
+ {" "}
<RelativeDate date={activity.date} />
</>
)}
diff --git a/src/components/atomic-crm/activity/ActivityLogContactCreated.tsx b/src/components/atomic-crm/activity/ActivityLogContactCreated.tsx
index b13ea757..69b45c0f 100644
--- a/src/components/atomic-crm/activity/ActivityLogContactCreated.tsx
+++ b/src/components/atomic-crm/activity/ActivityLogContactCreated.tsx
@@ -18,21 +18,22 @@ export function ActivityLogContactCreated({
const { contact } = activity;
return (
<div className="p-0">
- <div className="flex flex-row gap-2 items-center w-full">
+ <div className="flex flex-row gap-2 items-start w-full">
<Avatar width={20} height={20} record={contact} />
<span className="text-muted-foreground text-sm flex-grow">
<ReferenceField source="sales_id" reference="sales" record={activity}>
<SaleName />
- </ReferenceField>
- &nbsp;added&nbsp;
+ </ReferenceField>{" "}
+ added{" "}
<Link to={`/contacts/${contact.id}/show`}>
- {contact.first_name}&nbsp;{contact.last_name}
+ {contact.first_name} {contact.last_name}
</Link>
{context !== "company" && (
<>
{activity.company_id != null && (
<>
- &nbsp;to&nbsp;
+ {" "}
+ to{" "}
<ReferenceField
source="company_id"
reference="companies"
@@ -40,8 +41,7 @@ export function ActivityLogContactCreated({
link="show"
/>
</>
- )}
- &nbsp;
+ )}{" "}
<RelativeDate date={activity.date} />
</>
)}
diff --git a/src/components/atomic-crm/activity/ActivityLogContactNoteCreated.tsx b/src/components/atomic-crm/activity/ActivityLogContactNoteCreated.tsx
index 53bc49b7..6fb85e00 100644
--- a/src/components/atomic-crm/activity/ActivityLogContactNoteCreated.tsx
+++ b/src/components/atomic-crm/activity/ActivityLogContactNoteCreated.tsx
@@ -26,7 +26,7 @@ export function ActivityLogContactNoteCreated({
return (
<ActivityLogNote
header={
- <div className="flex items-center gap-2 w-full">
+ <div className="flex items-start gap-2 w-full">
<ReferenceField
source="contact_id"
reference="contacts"
@@ -42,20 +42,18 @@ export function ActivityLogContactNoteCreated({
record={activity}
>
<SaleName />
- </ReferenceField>
- &nbsp;added a note about&nbsp;
+ </ReferenceField>{" "}
+ added a note about{" "}
<ReferenceField
source="contact_id"
reference="contacts"
record={activity.contactNote}
>
- <TextField source="first_name" />
- &nbsp;
- <TextField source="last_name" />
+ <TextField source="first_name" /> <TextField source="last_name" />
</ReferenceField>
{context !== "company" && (
<>
- &nbsp;
+ {" "}
<RelativeDate date={activity.date} />
</>
)}
diff --git a/src/components/atomic-crm/activity/ActivityLogDealCreated.tsx b/src/components/atomic-crm/activity/ActivityLogDealCreated.tsx
index d859e957..acf76076 100644
--- a/src/components/atomic-crm/activity/ActivityLogDealCreated.tsx
+++ b/src/components/atomic-crm/activity/ActivityLogDealCreated.tsx
@@ -20,29 +20,27 @@ export function ActivityLogDealCreated({
const { deal } = activity;
return (
<div className="p-0">
- <div className="flex flex-row space-x-1 items-center w-full">
+ <div className="flex flex-row space-x-1 items-start w-full">
<div className="w-5 h-5 bg-gray-300 rounded-full" />
<span className="text-muted-foreground text-sm flex-grow">
<ReferenceField source="sales_id" reference="sales" record={activity}>
<SaleName />
- </ReferenceField>
- &nbsp;added deal&nbsp;
+ </ReferenceField>{" "}
+ added deal{" "}
{isMobile ? (
deal.name
) : (
<Link to={`/deals/${deal.id}/show`}>{deal.name}</Link>
- )}
- &nbsp;
+ )}{" "}
{context !== "company" && (
<>
- to&nbsp;
+ to{" "}
<ReferenceField
source="company_id"
reference="companies"
record={activity}
link="show"
- />
- &nbsp;
+ />{" "}
<RelativeDate date={activity.date} />
</>
)}
diff --git a/src/components/atomic-crm/activity/ActivityLogDealNoteCreated.tsx b/src/components/atomic-crm/activity/ActivityLogDealNoteCreated.tsx
index ab2432b2..120ac9b0 100644
--- a/src/components/atomic-crm/activity/ActivityLogDealNoteCreated.tsx
+++ b/src/components/atomic-crm/activity/ActivityLogDealNoteCreated.tsx
@@ -22,7 +22,7 @@ export function ActivityLogDealNoteCreated({
return (
<ActivityLogNote
header={
- <div className="flex flex-row items-center gap-2 flex-grow">
+ <div className="flex flex-row items-start gap-2 flex-grow">
<ReferenceField
source="deal_id"
reference="deals"
@@ -46,8 +46,8 @@ export function ActivityLogDealNoteCreated({
link={false}
>
<SaleName />
- </ReferenceField>
- &nbsp;added a note about deal&nbsp;
+ </ReferenceField>{" "}
+ added a note about deal{" "}
<ReferenceField
source="deal_id"
reference="deals"
@@ -56,7 +56,8 @@ export function ActivityLogDealNoteCreated({
/>
{context !== "company" && (
<>
- &nbsp;at&nbsp;
+ {" "}
+ at{" "}
<ReferenceField
source="deal_id"
reference="deals"
@@ -68,8 +69,7 @@ export function ActivityLogDealNoteCreated({
reference="companies"
link="show"
/>
- </ReferenceField>
- &nbsp;
+ </ReferenceField>{" "}
<RelativeDate date={activity.date} />
</>
)}