# Demos

The same three views, a household-chores **dashboard**, an **account settings** form and a
warehouse **orders** admin view, built six ways to show that domestic-ui works with plain HTML and with common frameworks.
Every view uses the same native markup, the `stack`, `cluster` and `grid` layout primitives, and
the [atom APIs](https://github.com/odonckers/domestic-ui/blob/main/css/components/atoms/README.md): `data-text`, `data-button`, `data-field`,
`data-badge` and the `role="switch"` checkbox, written exactly as in
[`examples/atoms/`](https://domestic-ui.odonckers.dev/atoms/index.md). Every view sits in the
[app shell](https://domestic-ui.odonckers.dev/patterns/app-shell.md) (`<dui-app-shell>`: app bar with a `<dui-menu>`, main
navigation, footer). The orders view follows [`examples/app-shell.html`](https://domestic-ui.odonckers.dev/patterns/app-shell.md):
a page header, a filter bar with two [`<dui-combobox>`](https://github.com/odonckers/domestic-ui/blob/main/web-components/dui-combobox.js)
typeaheads, a `<dui-table>` data table with a `data-density` toggle, and the selected order in the
order details sidebar as a `data-list-detail` list and detail.

Source and run instructions are on GitHub.

- **Accessibility checker** ([`demos/a11y/`](https://github.com/odonckers/domestic-ui/tree/main/demos/a11y)): Checks the built demo apps the same way the repository checks `examples/`: Playwright with [axe](https://github.com/dequelabs/axe-core) (tags `wcag2a`, `wcag2aa`, `wcag21a`, `wcag21aa`, `wcag22aa`), in light and dark, with every `<details>` opened and checked again.
- **Angular** ([`demos/angular/`](https://github.com/odonckers/domestic-ui/tree/main/demos/angular)): The dashboard, account settings and orders views in Angular 22: standalone components, three routes (`''`, `'settings'` and `'orders'`) with Angular Router, a `title` per route, and `routerLinkActive` with `ariaCurrentWhenActive="page"` for the current link.
- **Astro** ([`demos/astro/`](https://github.com/odonckers/domestic-ui/tree/main/demos/astro)): The dashboard, account settings and orders views as three static Astro pages (`src/pages/index.astro`, `src/pages/settings.astro` and `src/pages/orders.astro`) sharing `src/layouts/Base.astro`.
- **React** ([`demos/react/`](https://github.com/odonckers/domestic-ui/tree/main/demos/react)): The dashboard, account settings and orders views in React 19 with Vite, as a three-page [multi-page app](https://vite.dev/guide/build#multi-page-app) (`index.html`, `settings.html` and `orders.html`).
- **Svelte** ([`demos/svelte/`](https://github.com/odonckers/domestic-ui/tree/main/demos/svelte)): The dashboard, account settings and orders views in Svelte 5 with Vite, as a three-page [multi-page app](https://vite.dev/guide/build#multi-page-app) (`index.html`, `settings.html` and `orders.html`).
- **Plain HTML** ([`demos/vanilla/`](https://github.com/odonckers/domestic-ui/tree/main/demos/vanilla)): The dashboard, account settings and orders views as three static HTML files, with no build step.
- **Vue** ([`demos/vue/`](https://github.com/odonckers/domestic-ui/tree/main/demos/vue)): The dashboard, account settings and orders views in Vue 3 with Vite, as a three-page [multi-page app](https://vite.dev/guide/build#multi-page-app) (`index.html`, `settings.html` and `orders.html`) of single-file components.

## Views

The plain HTML views run live on this site (each **Open live** link). The framework apps need a build; run them locally as [`demos/README.md`](https://github.com/odonckers/domestic-ui/blob/main/demos/README.md) explains.

- **Dashboard**: Household chores: counts due, overdue and done, household members, and a table of upcoming chores with a filter disclosure. [Open live](https://domestic-ui.odonckers.dev/demos/vanilla/index.html). Source: [Plain HTML](https://github.com/odonckers/domestic-ui/blob/main/demos/vanilla/index.html), [React](https://github.com/odonckers/domestic-ui/blob/main/demos/react/src/DashboardPage.tsx), [Angular](https://github.com/odonckers/domestic-ui/tree/main/demos/angular/src/app/dashboard), [Astro](https://github.com/odonckers/domestic-ui/blob/main/demos/astro/src/pages/index.astro), [Vue](https://github.com/odonckers/domestic-ui/blob/main/demos/vue/src/DashboardPage.vue), [Svelte](https://github.com/odonckers/domestic-ui/blob/main/demos/svelte/src/DashboardPage.svelte).
- **Account settings**: A long form in titled sections: profile, region, email frequency, notification switches and a note for the household, with Save and Cancel in an action bar. [Open live](https://domestic-ui.odonckers.dev/demos/vanilla/settings.html). Source: [Plain HTML](https://github.com/odonckers/domestic-ui/blob/main/demos/vanilla/settings.html), [React](https://github.com/odonckers/domestic-ui/blob/main/demos/react/src/SettingsPage.tsx), [Angular](https://github.com/odonckers/domestic-ui/tree/main/demos/angular/src/app/settings), [Astro](https://github.com/odonckers/domestic-ui/blob/main/demos/astro/src/pages/settings.astro), [Vue](https://github.com/odonckers/domestic-ui/blob/main/demos/vue/src/SettingsPage.vue), [Svelte](https://github.com/odonckers/domestic-ui/blob/main/demos/svelte/src/SettingsPage.svelte).
- **Orders**: A warehouse admin view: page header, filter bar with typeaheads, a data table with a density toggle, and the selected order in the auxiliary sidebar. [Open live](https://domestic-ui.odonckers.dev/demos/vanilla/orders.html). Source: [Plain HTML](https://github.com/odonckers/domestic-ui/blob/main/demos/vanilla/orders.html), [React](https://github.com/odonckers/domestic-ui/blob/main/demos/react/src/OrdersPage.tsx), [Angular](https://github.com/odonckers/domestic-ui/tree/main/demos/angular/src/app/orders), [Astro](https://github.com/odonckers/domestic-ui/blob/main/demos/astro/src/pages/orders.astro), [Vue](https://github.com/odonckers/domestic-ui/blob/main/demos/vue/src/OrdersPage.vue), [Svelte](https://github.com/odonckers/domestic-ui/blob/main/demos/svelte/src/OrdersPage.svelte).
