# Mobile Menu (Basic)

> Mobile off-canvas drawer paired with `HeaderBasic`, hosting links, a social row, locale selector, and dark-mode toggle.

## Playground

An interactive playground for MobileMenuBasic is embedded above. Open the canonical story on Storybook: [https://storybook.laioutr.cloud/?path=/story/ui-features-mobilemenubasic--default](https://storybook.laioutr.cloud/?path=/story/ui-features-mobilemenubasic--default)

## Overview

`MobileMenuBasic` is the touch-optimized off-canvas drawer that pairs with [`HeaderBasic`](/laioutr-ui/navigation/header-basic). It hosts the mobile navigation list, an optional social row, a locale selector, and a dark-mode toggle. The drawer renders inside a `Sheet`, so focus trap and Escape-to-close come from the underlying reka-ui Dialog. Press-state feedback on link items uses the CSS `:active` pseudo-class.

Pass items, social links, locale select, and the mode switcher as props on `MobileMenuBasic` itself, then mount it inside [`HeaderBasic`](/laioutr-ui/navigation/header-basic)'s `mobile` slot.

## Key Business & UX Benefits

- Touch-optimized drawer with main content visible behind it keeps mobile users grounded, so they can browse without losing context on the page they came from.
- Focus is trapped while the drawer is open, which removes a common accessibility failure and keeps keyboard and screen-reader users on a clean path.
- Locale switching, dark mode, and social links share one mobile surface, so secondary controls do not fight for space in the main header on small screens.
- Configured once in Studio and reused across pages, so marketing changes ship without engineering tickets.

<tip>

Pro-Tip from Larry: Share the same items array between `MobileMenuBasic` and the desktop menu component so both views stay in sync from a single config.

</tip>

## Usage

#### Example: LMobileMenuBasic

Live preview: [https://storybook.laioutr.cloud/?path=/story/ui-features-mobilemenubasic--default&globals=viewport:xs](https://storybook.laioutr.cloud/?path=/story/ui-features-mobilemenubasic--default&globals=viewport:xs)

## Feature List

<features :items="["Off-canvas drawer renders inside a `Sheet`, inheriting focus trap and Escape-to-close from the underlying reka-ui Dialog","Touch-optimized list with `:active` press-state feedback for tappable feel on mobile","Hosts mobile navigation links, optional social row, locale selector, and a dark-mode toggle inside one surface","Pairs with `HeaderBasic` — mount it inside the header's `mobile` slot","Exposes items, social links, locale select, and the mode switcher as props for direct configuration","Main content stays visible behind the drawer so mobile users keep context on the page they came from"]">



</features>

## API Reference

#### Props

```json
{"type":"object","properties":{"open":{"type":"boolean"},"menuItems":{"type":"array","items":{"type":"object","properties":{"label":{"type":"string"},"href":{"type":"string"},"saleDesign":{"type":"boolean"},"icon":{"type":["string","undefined"]},"hasSubmenu":{"type":["boolean","undefined"]},"subMenuItems":{"type":["MenuItem[]","undefined"]}},"additionalProperties":false,"required":["label"]}},"hasLanguageSwitcher":{"type":"boolean"},"hasDarkModeSwitcher":{"type":"boolean"},"socialLinks":{"type":"object","properties":{"backgroundColor":{"type":"string"},"textColor":{"type":["string","undefined"]},"text":{"type":["string","undefined"]},"icons":{"type":"array","items":{"type":"object","properties":{"icon":{"type":"string"},"label":{"type":["string","undefined"]},"href":{"type":"string"}},"additionalProperties":false,"required":["icon","href"]}}},"additionalProperties":false},"background":{"enum":["solid","transparent"],"type":"string"},"hasGlassEffect":{"type":"boolean"},"banner":{"type":"object","properties":{"title":{"type":"string"},"content":{"type":"string"},"ctaLink":{"type":"string"},"ctaText":{"type":"string"}},"additionalProperties":false,"required":["title","content","ctaLink","ctaText"]},"currentLocale":{"type":"string"},"availableLocales":{"type":"array","items":{"type":"object","properties":{"code":{"type":"string"},"endonym":{"type":"string"},"regionCode":{"type":"string"},"languageHint":{"type":"string"}},"additionalProperties":false,"required":["code","endonym","regionCode"]}}},"required":["open"]}
```

#### Events

```json
[{"name":"update:open","description":"","tags":[],"type":"[value: boolean]","signature":"(event: \"update:open\", value: boolean): void","schema":[{"kind":"enum","type":"boolean","schema":["false","true"]}]},{"name":"localeChange","description":"","tags":[],"type":"[locale: string]","signature":"(event: \"localeChange\", locale: string): void","schema":["string"]}]
```
