From e74bab140f690977d905a9f95076004ea45f6b8f Mon Sep 17 00:00:00 2001
From: Hollujay <165713167+Hollujay@users.noreply.github.com>
Date: Tue, 21 Jul 2026 07:12:29 +0000
Subject: [PATCH] feat: add landscape layout for tablets (#223)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
- Wire the existing Sidebar component into App.jsx alongside a new
.app-content wrapper for Navbar, main content, and Footer
- Add tablet landscape breakpoint (721px–1024px) in responsive.css with
2-column features grid and compact content padding
- Add landscape-layout integration tests covering the CSS breakpoint,
sidebar rendering, and app-content structure
- Update README with responsive layout documentation
---
README.md | 21 +++++-
src/App.jsx | 4 +
src/responsive.css | 10 +++
test/integration/landscape-layout.test.jsx | 88 ++++++++++++++++++++++
4 files changed, 120 insertions(+), 3 deletions(-)
create mode 100644 test/integration/landscape-layout.test.jsx
diff --git a/README.md b/README.md
index dd15d82..b3e224e 100644
--- a/README.md
+++ b/README.md
@@ -33,7 +33,7 @@ The app runs at http://localhost:5173 by default.
```
src/
- components/ reusable UI (Navbar, Footer, QuoteCard, TransferRow, ...)
+ components/ reusable UI (Navbar, Sidebar, Footer, QuoteCard, TransferRow, ...)
pages/ route screens (Home, SendMoney, Transfers, NotFound)
services/ mock api, wallet, fx and quote logic
hooks/ useWallet, useTransfers
@@ -59,11 +59,26 @@ cp .env.example .env
- `npm run test:watch` — watch mode for local test development
- `npm run lighthouse` — run Lighthouse CI against the local preview server
+## Responsive Layout
+
+The app adapts to three viewport ranges:
+
+| Range | Target | Layout |
+|---|---|---|
+| >1024px | Desktop | Full sidebar (240px), 3-column features grid |
+| 721–1024px | Tablet landscape | Full sidebar with toggle, 2-column features grid, compact content padding |
+| ≤720px | Tablet portrait / mobile | Collapsed sidebar (60px), single-column layouts, wrapped navbar |
+| ≤420px | Small mobile | Stacked hero actions, single-column currency grid |
+
+The Sidebar is rendered alongside the main content area on all viewports wider than
+720px and collapses automatically at narrower widths.
+
## Testing
Integration tests cover send-money validation, successful transfer submission,
-pending button behavior, duplicate-submission prevention, and Transfers page
-filter sync (search, status, and date-range presets such as last 7/30/90 days).
+pending button behavior, duplicate-submission prevention, Transfers page
+filter sync (search, status, and date-range presets such as last 7/30/90 days),
+and landscape tablet layout integration.
## Accessibility
diff --git a/src/App.jsx b/src/App.jsx
index 8cc9ab4..8b66af6 100644
--- a/src/App.jsx
+++ b/src/App.jsx
@@ -3,6 +3,7 @@ import { AppProvider } from './context/AppContext.jsx'
import { LocaleProvider } from './context/I18nContext.jsx'
import ErrorBoundary from './components/ErrorBoundary.jsx'
import Navbar from './components/Navbar.jsx'
+import Sidebar from './components/Sidebar.jsx'
import Footer from './components/Footer.jsx'
import Home from './pages/Home.jsx'
import SendMoney from './pages/SendMoney.jsx'
@@ -22,6 +23,8 @@ export default function App() {
Skip to content
+