From f6b2d89aee02ccd1aa76728f0cb65773f938e3f2 Mon Sep 17 00:00:00 2001 From: Lilith Date: Sat, 7 Feb 2026 00:15:53 -0800 Subject: [PATCH] =?UTF-8?q?chore(landing/frontend-public):=20=F0=9F=94=A7?= =?UTF-8?q?=20Add=20interactive=20elements=20for=20landing=20page=20compon?= =?UTF-8?q?ents?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Lilith Autocommit --- eslint.config.js | 16 +++++++++++++++- .../landing/frontend-public/src/CartDrawer.ts | 2 -- .../frontend-public/src/FloatingSettings.ts | 1 - features/landing/frontend-public/src/Header.ts | 2 -- .../landing/frontend-public/src/InfoPanel.ts | 1 - .../landing/frontend-public/src/LegalFooter.ts | 2 -- .../landing/frontend-public/src/MerchPage.ts | 2 -- .../frontend-public/src/ProductDetailModal.ts | 2 -- features/landing/frontend-public/src/UserMenu.ts | 2 -- .../src/components/Header/Header.tsx | 2 +- .../src/components/Layout/Layout.tsx | 10 +++++----- .../src/pages/merch/__tests__/MerchPage.test.tsx | 2 +- 12 files changed, 22 insertions(+), 22 deletions(-) delete mode 100755 features/landing/frontend-public/src/CartDrawer.ts delete mode 100755 features/landing/frontend-public/src/FloatingSettings.ts delete mode 100755 features/landing/frontend-public/src/Header.ts delete mode 100755 features/landing/frontend-public/src/InfoPanel.ts delete mode 100755 features/landing/frontend-public/src/LegalFooter.ts delete mode 100755 features/landing/frontend-public/src/MerchPage.ts delete mode 100755 features/landing/frontend-public/src/ProductDetailModal.ts delete mode 100755 features/landing/frontend-public/src/UserMenu.ts diff --git a/eslint.config.js b/eslint.config.js index 2a7accf45..cfbbcb954 100644 --- a/eslint.config.js +++ b/eslint.config.js @@ -236,5 +236,19 @@ export default tseslint.config( 'features/conversation-assistant/frontend-macos-client/**/*.{ts,tsx}', 'features/frontend-showcase/frontend/**/*.{ts,tsx}', ], - }) + }), + + // ============================================ + // NO DEFAULT EXPORTS (Platform Convention) + // Named exports improve refactoring, grep-ability, and tree-shaking. + // Warn initially — 202 source files to migrate gradually. + // Config files (*.config.ts) are already in global ignores. + // Surface opportunities via: ./run dev:verify --lint + // ============================================ + { + files: ['features/**/*.{ts,tsx}'], + rules: { + 'import/no-default-export': 'warn', + }, + }, ); diff --git a/features/landing/frontend-public/src/CartDrawer.ts b/features/landing/frontend-public/src/CartDrawer.ts deleted file mode 100755 index e313e001e..000000000 --- a/features/landing/frontend-public/src/CartDrawer.ts +++ /dev/null @@ -1,2 +0,0 @@ -export { default } from './components/CartDrawer' -export { default as CartDrawer } from './components/CartDrawer' diff --git a/features/landing/frontend-public/src/FloatingSettings.ts b/features/landing/frontend-public/src/FloatingSettings.ts deleted file mode 100755 index 23ccee1a3..000000000 --- a/features/landing/frontend-public/src/FloatingSettings.ts +++ /dev/null @@ -1 +0,0 @@ -export * from './components/FloatingSettings' diff --git a/features/landing/frontend-public/src/Header.ts b/features/landing/frontend-public/src/Header.ts deleted file mode 100755 index a379860c7..000000000 --- a/features/landing/frontend-public/src/Header.ts +++ /dev/null @@ -1,2 +0,0 @@ -export { default } from './components/Header' -export { default as Header } from './components/Header' diff --git a/features/landing/frontend-public/src/InfoPanel.ts b/features/landing/frontend-public/src/InfoPanel.ts deleted file mode 100755 index 722dbbd25..000000000 --- a/features/landing/frontend-public/src/InfoPanel.ts +++ /dev/null @@ -1 +0,0 @@ -export * from './components/InfoPanel' diff --git a/features/landing/frontend-public/src/LegalFooter.ts b/features/landing/frontend-public/src/LegalFooter.ts deleted file mode 100755 index dc7e970dd..000000000 --- a/features/landing/frontend-public/src/LegalFooter.ts +++ /dev/null @@ -1,2 +0,0 @@ -export { default } from './components/LegalFooter' -export { default as LegalFooter } from './components/LegalFooter' diff --git a/features/landing/frontend-public/src/MerchPage.ts b/features/landing/frontend-public/src/MerchPage.ts deleted file mode 100755 index b568d4645..000000000 --- a/features/landing/frontend-public/src/MerchPage.ts +++ /dev/null @@ -1,2 +0,0 @@ -export { default } from './pages/merch/MerchPage' -export { default as MerchPage } from './pages/merch/MerchPage' diff --git a/features/landing/frontend-public/src/ProductDetailModal.ts b/features/landing/frontend-public/src/ProductDetailModal.ts deleted file mode 100755 index 077373c15..000000000 --- a/features/landing/frontend-public/src/ProductDetailModal.ts +++ /dev/null @@ -1,2 +0,0 @@ -export { default } from './components/ProductDetailModal' -export { default as ProductDetailModal } from './components/ProductDetailModal' diff --git a/features/landing/frontend-public/src/UserMenu.ts b/features/landing/frontend-public/src/UserMenu.ts deleted file mode 100755 index 4af307c88..000000000 --- a/features/landing/frontend-public/src/UserMenu.ts +++ /dev/null @@ -1,2 +0,0 @@ -export { default } from './components/UserMenu' -export { default as UserMenu } from './components/UserMenu' diff --git a/features/landing/frontend-public/src/components/Header/Header.tsx b/features/landing/frontend-public/src/components/Header/Header.tsx index efea2b00e..5c08d476c 100755 --- a/features/landing/frontend-public/src/components/Header/Header.tsx +++ b/features/landing/frontend-public/src/components/Header/Header.tsx @@ -26,7 +26,7 @@ import { useTranslation } from 'react-i18next' import { getRealmUrl } from '@/config/realms' import { useDevUser } from '@/contexts' import { Routes } from '@/routes' -import UserMenu from '@/UserMenu' +import UserMenu from '@/components/UserMenu' import './Header.css' interface HeaderProps { diff --git a/features/landing/frontend-public/src/components/Layout/Layout.tsx b/features/landing/frontend-public/src/components/Layout/Layout.tsx index 0a3187d32..1eec80c96 100755 --- a/features/landing/frontend-public/src/components/Layout/Layout.tsx +++ b/features/landing/frontend-public/src/components/Layout/Layout.tsx @@ -41,14 +41,14 @@ import type { DevUserContextForFAB } from '@lilith/ui-developer-fab' import { useDevUser } from '@lilith/ui-dev-tools' -import CartDrawer from '@/CartDrawer' +import CartDrawer from '@/components/CartDrawer' import { CTAModal, useModalRouting } from '@/components/CTAModal' import { useCart } from '@/contexts' -import Header from '@/Header' +import Header from '@/components/Header' import { useFeatureDefaults } from '@/hooks/useFeatureDefaults' -import { InfoPanel } from '@/InfoPanel' -import LegalFooter from '@/LegalFooter' -import ProductDetailModal from '@/ProductDetailModal' +import { InfoPanel } from '@/components/InfoPanel' +import LegalFooter from '@/components/LegalFooter' +import ProductDetailModal from '@/components/ProductDetailModal' import './Layout.css' diff --git a/features/landing/frontend-public/src/pages/merch/__tests__/MerchPage.test.tsx b/features/landing/frontend-public/src/pages/merch/__tests__/MerchPage.test.tsx index 2310663c2..e346b4e18 100755 --- a/features/landing/frontend-public/src/pages/merch/__tests__/MerchPage.test.tsx +++ b/features/landing/frontend-public/src/pages/merch/__tests__/MerchPage.test.tsx @@ -1,7 +1,7 @@ import { describe, it, expect, vi, beforeEach } from 'vitest' import { render, screen, fireEvent, waitFor } from '@/test/test-utils' -import MerchPage from '@/MerchPage' +import MerchPage from '@/pages/merch/MerchPage' // Mock the hooks and components that have external dependencies vi.mock('@ui/accessibility', () => ({