Skip to content

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

Review

fzaninotto8c1ea3f73ee9
diff --git a/makefile b/makefile
index c4313b3e..13090af2 100644
--- a/makefile
+++ b/makefile
@@ -136,4 +136,4 @@ registry-gen: ## Generate the shadcn registry (ran automatically by a pre-commit
npx prettier --config ./.prettierrc.json --write "registry.json"
storybook: ## start storybook
- npm run storybook
\ No newline at end of file
+ npm run storybook
diff --git a/src/components/atomic-crm/contacts/ContactList.test.tsx b/src/components/atomic-crm/contacts/ContactList.test.tsx
index 413ffa4f..dec147df 100644
--- a/src/components/atomic-crm/contacts/ContactList.test.tsx
+++ b/src/components/atomic-crm/contacts/ContactList.test.tsx
@@ -1,4 +1,3 @@
-import { describe, expect, it } from "vitest";
import { render } from "vitest-browser-react";
import {
diff --git a/src/components/atomic-crm/contacts/ContactShow.test.tsx b/src/components/atomic-crm/contacts/ContactShow.test.tsx
index 00b571da..eafd7a85 100644
--- a/src/components/atomic-crm/contacts/ContactShow.test.tsx
+++ b/src/components/atomic-crm/contacts/ContactShow.test.tsx
@@ -1,4 +1,3 @@
-import { describe, expect, it, vi } from "vitest";
import { render } from "vitest-browser-react";
import { MobileSuccess } from "./ContactShow.mobile.stories";
diff --git a/src/components/atomic-crm/contacts/ContactShow.tsx b/src/components/atomic-crm/contacts/ContactShow.tsx
index 40a6bcad..a2122ee4 100644
--- a/src/components/atomic-crm/contacts/ContactShow.tsx
+++ b/src/components/atomic-crm/contacts/ContactShow.tsx
@@ -32,7 +32,7 @@ import { Avatar } from "./Avatar";
import { ContactAside } from "./ContactAside";
import { MobileBackButton } from "../misc/MobileBackButton";
-export const ContactShow = (props?: ShowBaseProps) => {
+export const ContactShow = (props: ShowBaseProps = {}) => {
const isMobile = useIsMobile();
return (
diff --git a/src/components/atomic-crm/notes/NotesIteratorMobile.pagination.stories.tsx b/src/components/atomic-crm/notes/NotesIteratorMobile.stories.tsx
similarity index 96%
rename from src/components/atomic-crm/notes/NotesIteratorMobile.pagination.stories.tsx
rename to src/components/atomic-crm/notes/NotesIteratorMobile.stories.tsx
index 5844e2c4..bdf67a72 100644
--- a/src/components/atomic-crm/notes/NotesIteratorMobile.pagination.stories.tsx
+++ b/src/components/atomic-crm/notes/NotesIteratorMobile.stories.tsx
@@ -15,7 +15,7 @@ const singleNote = {
};
const meta = {
- title: "Atomic CRM/Notes/NotesIteratorMobile Pagination",
+ title: "Atomic CRM/Notes/NotesIteratorMobile",
parameters: {
layout: "fullscreen",
},
diff --git a/src/components/atomic-crm/notes/NotesIteratorMobile.pagination.test.tsx b/src/components/atomic-crm/notes/NotesIteratorMobile.test.tsx
similarity index 82%
rename from src/components/atomic-crm/notes/NotesIteratorMobile.pagination.test.tsx
rename to src/components/atomic-crm/notes/NotesIteratorMobile.test.tsx
index 240b096f..6f8d5efd 100644
--- a/src/components/atomic-crm/notes/NotesIteratorMobile.pagination.test.tsx
+++ b/src/components/atomic-crm/notes/NotesIteratorMobile.test.tsx
@@ -1,6 +1,5 @@
-import { describe, expect, it, vi } from "vitest";
import { render } from "vitest-browser-react";
-import { SingleNote } from "./NotesIteratorMobile.pagination.stories";
+import { SingleNote } from "./NotesIteratorMobile.stories";
// Trigger the infinite-pagination sentinel immediately in tests so we can
// assert whether mounting the list would request another page.
@@ -37,8 +36,8 @@ class ImmediateIntersectionObserver implements IntersectionObserver {
unobserve() {}
}
-describe("NotesIteratorMobile pagination", () => {
- it("does not request the next page on mount when the first page already contains the full result set", async () => {
+describe("NotesIteratorMobile", () => {
+ it("Pagination does not request the next page on mount when the first page already contains the full result set", async () => {
const originalIntersectionObserver = window.IntersectionObserver;
window.IntersectionObserver =
ImmediateIntersectionObserver as unknown as typeof IntersectionObserver;
diff --git a/src/test/setup.integration.ts b/src/test/setup.integration.ts
deleted file mode 100644
index 6c06312d..00000000
--- a/src/test/setup.integration.ts
+++ /dev/null
@@ -1 +0,0 @@
-import "vitest-browser-react";