Skip to content

AI-native knowledge base & Evernote/Obsidian alternative with instant sync & native MCP. Free on Cloudflare or self-hosted via Docker.

test(web): align chrome assertions with the current workspace

tianma-ifd577ed74139c
diff --git a/apps/web/src/components/MemoListPane.test.mjs b/apps/web/src/components/MemoListPane.test.mjs
index c7a421e4..10beb9a1 100644
--- a/apps/web/src/components/MemoListPane.test.mjs
+++ b/apps/web/src/components/MemoListPane.test.mjs
@@ -24,7 +24,7 @@ describe("desktop memo list spacing", () => {
test("reserves matching desktop scrollbar gutters on both sides", () => {
const source = readFileSync(new URL("./MemoListPane.tsx", import.meta.url), "utf8");
- expect(source).toContain("lg:px-0 lg:pb-3 lg:[scrollbar-gutter:stable_both-edges]");
+ expect(source).toContain("lg:px-2 lg:py-2 lg:pb-3 lg:[scrollbar-gutter:stable_both-edges]");
});
});
diff --git a/apps/web/src/components/NotebookPane.test.mjs b/apps/web/src/components/NotebookPane.test.mjs
index 8d13382e..8f00f232 100644
--- a/apps/web/src/components/NotebookPane.test.mjs
+++ b/apps/web/src/components/NotebookPane.test.mjs
@@ -17,7 +17,7 @@ test("keeps the desktop create-note control compact with one neutral outline", (
expect(source).toContain('className="group flex h-12 max-w-[calc(100%-2.25rem)]');
expect(source).toContain('className="group relative flex h-12 min-w-9 flex-1');
expect(source).toContain('before:inset-y-2.5');
- expect(source).toContain('data-[state=open]:bg-emerald-50');
+ expect(source).toContain('data-[state=open]:bg-slate-100 data-[state=open]:text-slate-950');
expect(source).toContain('t("diagram.moreTypes")');
expect(source).toContain('group-data-[state=open]:rotate-180');
expect(source).toContain("edgeever-create-memo-split__more-label");
diff --git a/tests/note-sharing-menu.test.ts b/tests/note-sharing-menu.test.ts
index 19468dd2..fbdf7b72 100644
--- a/tests/note-sharing-menu.test.ts
+++ b/tests/note-sharing-menu.test.ts
@@ -17,8 +17,9 @@ describe("note sharing menu", () => {
expect(editorActionsSource).not.toContain("if (!effectiveReadOnly) setShareOpen(true)");
expect(editorSource).toContain("canShareMemo: Boolean(memo && !readOnly)");
expect(editorSource).toContain("{!readOnly && (\n <DropdownMenuItem");
- expect(editorSource).toContain('className="h-8 w-8 text-slate-500 sm:hidden"');
- expect(editorSource).toContain('title={t(isLocalMemoId(memo.id) ? "sharing.afterSync" : "sharing.action")}');
+ expect(editorSource).toContain('{!readOnly && (!mobileEditingActive || isMemoShared) && (');
+ expect(editorSource).toContain('className={cn("h-8 w-8", isMemoShared ? "text-slate-700" : "text-slate-500")}');
+ expect(editorSource).toContain('aria-label={t(isLocalMemoId(memo.id) ? "sharing.afterSync" : isMemoShared ? "sharing.manage" : "sharing.action")}');
});
test("explains why sharing a newly created local note is disabled", () => {