diff --git a/website/app/clubs/[clubId]/manage/ranks-roles/page.tsx b/website/app/clubs/[clubId]/manage/ranks-roles/page.tsx index 79da603..bb58545 100644 --- a/website/app/clubs/[clubId]/manage/ranks-roles/page.tsx +++ b/website/app/clubs/[clubId]/manage/ranks-roles/page.tsx @@ -135,7 +135,7 @@ export default function ClubFounderRanksRolesPage({ params }: PageProps) { pendingApplicationsCount={0} upcomingRidesCount={0} > -
+
{/* Header */}
diff --git a/website/components/founder-portal/founder-applications.tsx b/website/components/founder-portal/founder-applications.tsx index e0722d0..dc7eda9 100644 --- a/website/components/founder-portal/founder-applications.tsx +++ b/website/components/founder-portal/founder-applications.tsx @@ -169,7 +169,7 @@ export function FounderApplications({ } return ( -
+
{/* 1. PAGE HEADER */}
diff --git a/website/components/founder-portal/founder-profile-editor.tsx b/website/components/founder-portal/founder-profile-editor.tsx index 56b5461..2c3d9df 100644 --- a/website/components/founder-portal/founder-profile-editor.tsx +++ b/website/components/founder-portal/founder-profile-editor.tsx @@ -134,7 +134,7 @@ export function FounderProfileEditor({ } return ( -
+
{/* 3. PAGE HEADER */}
diff --git a/website/tests/founder-portal.test.cjs b/website/tests/founder-portal.test.cjs index 5caea7e..b0d23dc 100644 --- a/website/tests/founder-portal.test.cjs +++ b/website/tests/founder-portal.test.cjs @@ -1040,7 +1040,33 @@ async function runAllTests() { console.log(' PASS: FP-16 Tests A through N verified (Route exists, Owner/Admin access, Member denial, Unauth denial, discovery-pending production state, unsupported broad query absent, actions disabled, model corrections, privacy notice, dev-gated preview, production fixture isolation, Sidebar/TopBar, fixtures valid).'); - console.log('--- ALL FOUNDER PORTAL TESTS PASSED (25/25) ---'); + // ========================================================================= + // TEST 26: Founder Portal Page Width Normalization Invariant + // ========================================================================= + console.log('Testing: Founder Portal page width normalization across Profile, Applications, and Ranks & Roles...'); + + const profileEditorSrc = fs.readFileSync(path.resolve(__dirname, '../components/founder-portal/founder-profile-editor.tsx'), 'utf8'); + const appNormalizedSrc = fs.readFileSync(path.resolve(__dirname, '../components/founder-portal/founder-applications.tsx'), 'utf8'); + const ranksPageSrc = fs.readFileSync(path.resolve(__dirname, '../app/clubs/[clubId]/manage/ranks-roles/page.tsx'), 'utf8'); + + // Assert Profile Editor canvas normalization + assert(!profileEditorSrc.includes('max-w-6xl mx-auto'), 'founder-profile-editor.tsx must NOT contain restrictive max-w-6xl mx-auto container'); + assert(!profileEditorSrc.includes('max-w-7xl mx-auto'), 'founder-profile-editor.tsx must NOT contain max-w-7xl mx-auto container'); + assert(profileEditorSrc.includes('
'), 'founder-profile-editor.tsx must use w-full canvas matching Overview'); + + // Assert Applications canvas normalization + assert(!appNormalizedSrc.includes('max-w-6xl mx-auto'), 'founder-applications.tsx must NOT contain restrictive max-w-6xl mx-auto container'); + assert(!appNormalizedSrc.includes('max-w-7xl mx-auto'), 'founder-applications.tsx must NOT contain max-w-7xl mx-auto container'); + assert(appNormalizedSrc.includes('
'), 'founder-applications.tsx must use w-full canvas matching Overview'); + + // Assert Ranks & Roles canvas normalization + assert(!ranksPageSrc.includes('max-w-6xl mx-auto'), 'ranks-roles/page.tsx must NOT contain restrictive max-w-6xl mx-auto container'); + assert(!ranksPageSrc.includes('max-w-7xl mx-auto'), 'ranks-roles/page.tsx must NOT contain max-w-7xl mx-auto container'); + assert(ranksPageSrc.includes('
'), 'ranks-roles/page.tsx must use w-full canvas matching Overview'); + + console.log(' PASS: Page width normalization verified (Profile, Applications, Ranks & Roles all use w-full canvas without restrictive max-w-6xl caps).'); + + console.log('--- ALL FOUNDER PORTAL TESTS PASSED (26/26) ---'); } runAllTests().catch((err) => {