chore: merge main, resolve biome formatting conflicts

Merge origin/main into feat/external-2fa-codes. Resolve formatting
conflicts caused by biome rollout; preserve both feature streams:
PR's external 2FA token + signing-session 2FA proof additions plus
main's RateLimit/RecipientExpired/signingReminders/date-auto-insert.

In complete-document-with-token.ts, drop the duplicate early
field-fetching block introduced when main moved that logic later
with date auto-insert support; keep the EXTERNAL_TWO_FACTOR_AUTH
check using derivedRecipientActionAuth.
This commit is contained in:
ephraimduncan
2026-05-12 11:46:11 +00:00
parent 9194884fbe
commit 138d663c25
1959 changed files with 93488 additions and 47038 deletions
@@ -1,10 +1,10 @@
import { expect, test } from '@playwright/test';
import { WebhookCallStatus, WebhookTriggerEvents } from '@prisma/client';
import { NEXT_PUBLIC_WEBAPP_URL } from '@documenso/lib/constants/app';
import { alphaid } from '@documenso/lib/universal/id';
import { prisma } from '@documenso/prisma';
import { seedBlankDocument } from '@documenso/prisma/seed/documents';
import { seedUser } from '@documenso/prisma/seed/users';
import { expect, test } from '@playwright/test';
import { WebhookCallStatus, WebhookTriggerEvents } from '@prisma/client';
import { apiSignin, apiSignout } from '../fixtures/authentication';
import { expectTextToBeVisible, openDropdownMenu } from '../fixtures/generic';
@@ -279,8 +279,8 @@ test('[WEBHOOKS]: cannot see unrelated webhooks', async ({ page }) => {
const user1Data = await seedUser();
const user2Data = await seedUser();
const webhookUrl1 = `https://example.com/webhook-team1-${Date.now()}`;
const webhookUrl2 = `https://example.com/webhook-team2-${Date.now()}`;
const webhookUrl1 = `https://example.com/webhook-team1-${alphaid(12)}`;
const webhookUrl2 = `https://example.com/webhook-team2-${alphaid(12)}`;
// Create webhooks for both teams with DOCUMENT_CREATED event
const webhook1 = await seedWebhook({
@@ -339,9 +339,7 @@ test('[WEBHOOKS]: cannot see unrelated webhooks', async ({ page }) => {
await expect(page.getByText(webhookUrl2)).not.toBeVisible();
// Navigate to team1's webhook logs page
await page.goto(
`${NEXT_PUBLIC_WEBAPP_URL()}/t/${user1Data.team.url}/settings/webhooks/${webhook1.id}`,
);
await page.goto(`${NEXT_PUBLIC_WEBAPP_URL()}/t/${user1Data.team.url}/settings/webhooks/${webhook1.id}`);
// Verify user1 can see their webhook logs
// The webhook call should be visible in the table
@@ -362,18 +360,14 @@ test('[WEBHOOKS]: cannot see unrelated webhooks', async ({ page }) => {
await expect(page.getByText(webhookUrl1)).not.toBeVisible();
// Navigate to team2's webhook logs page
await page.goto(
`${NEXT_PUBLIC_WEBAPP_URL()}/t/${user2Data.team.url}/settings/webhooks/${webhook2.id}`,
);
await page.goto(`${NEXT_PUBLIC_WEBAPP_URL()}/t/${user2Data.team.url}/settings/webhooks/${webhook2.id}`);
// Verify user2 cannot see team1's webhook logs
// The webhook call from team1 should not be visible
await expect(page.getByText(webhookCall1.id)).not.toBeVisible();
// Attempt to access user1's webhook detail page directly via URL
await page.goto(
`${NEXT_PUBLIC_WEBAPP_URL()}/t/${user2Data.team.url}/settings/webhooks/${webhook1.id}`,
);
await page.goto(`${NEXT_PUBLIC_WEBAPP_URL()}/t/${user2Data.team.url}/settings/webhooks/${webhook1.id}`);
// Verify access is denied - should show error or redirect
// Based on the component, it shows a 404 error page