# Theme Grounds

## Package docs status

This page is generated from package source documentation in `the Capell packages repository` and the checked-in manifest. Source documentation is not distribution status. Before running a Composer command, verify that the exact package and compatible 1.x release are available through public Packagist or the authenticated marketplace account.

| Field | Value |
| --- | --- |
| Composer package | `capell-app/theme-grounds` |
| Package slug | `theme-grounds` |
| Product group | Capell Themes |
| Tier | premium |
| Bundle | `themes` |
| Runtime contexts | `frontend` |
| Capell version | `^1.0` |
| Catalogue role | extension |
| Release channel | Labs |
| Source repository | `capell-app/packages` |
| Source path | `packages/theme-grounds` |
| Docs source | `packages/theme-grounds/docs` |
| Manifest | [`capell.json`](https://github.com/capell-app/packages/edit/main/packages/theme-grounds/capell.json) |

<!-- prettier-ignore-start -->

## What This Plugin Adds

Theme Grounds is an **Available**, **No schema impact** Capell theme in the **Capell Themes** product group. It ships as `capell-app/theme-grounds` and extends these surfaces: frontend.

Theme Grounds adds an accessible illustrated place map, landmark sections, wayfinding, directories, visit planning, and mobile district navigation for organisations with a real campus, yard, market, or venue.

Editors compose ordinary Layout Builder sections while visitors receive a complete list fallback that becomes a pan-and-zoom map on capable desktops and a district strip on phones.

Evidence: [`src/GroundsThemeServiceProvider.php`](src/GroundsThemeServiceProvider.php), [`src/Enums/WidgetComponentEnum.php`](src/Enums/WidgetComponentEnum.php), [`resources/views/sections/hero--world.blade.php`](resources/views/sections/hero--world.blade.php), [`resources/views/sections/landmark-plot.blade.php`](resources/views/sections/landmark-plot.blade.php), [`src/Support/Demo/GroundsDemoContent.php`](src/Support/Demo/GroundsDemoContent.php), [`resources/js/grounds-frontend.js`](resources/js/grounds-frontend.js), [`resources/css/theme-grounds.css`](resources/css/theme-grounds.css).

Status details:

- Status: Available
- Tier: premium
- Bundle: themes
- Composer package: `capell-app/theme-grounds`
- Namespace: `Capell\ThemeGrounds`
- Theme key: `grounds`

## Why It Matters

**For developers:** The package keeps its camera, rendering, build output, and optional integrations inside a cache-safe theme boundary using Foundation's shared frontend resource contract.

**For teams:** Place-based teams can explain what is where, who works there, when to visit, and how to arrive without maintaining a separate map application.

Evidence: [`src/GroundsThemeServiceProvider.php`](src/GroundsThemeServiceProvider.php), [`src/View/Components/SectionDispatcher.php`](src/View/Components/SectionDispatcher.php), [`build.mjs`](build.mjs), [`resources/views/sections/minimap-nav.blade.php`](resources/views/sections/minimap-nav.blade.php), [`resources/views/sections/content-listing--district.blade.php`](resources/views/sections/content-listing--district.blade.php), [`resources/views/sections/cta--gatehouse.blade.php`](resources/views/sections/cta--gatehouse.blade.php).

## Screens And Workflow

Screenshot contract: `docs/screenshots.json`.

<span class="theme-aware-image">
  <img class="theme-aware-image__light" src="screenshots/grounds-homepage.png" alt="Grounds Homepage" loading="lazy" />
  <img class="theme-aware-image__dark" src="screenshots/grounds-homepage-dark.png" alt="Grounds Homepage" loading="lazy" />
</span>

<span class="theme-aware-image">
  <img class="theme-aware-image__light" src="screenshots/grounds-homepage-mobile.png" alt="Grounds Homepage - Mobile District Strip" loading="lazy" />
  <img class="theme-aware-image__dark" src="screenshots/grounds-homepage-mobile-dark.png" alt="Grounds Homepage - Mobile District Strip" loading="lazy" />
</span>

- Grounds Homepage (frontend, required).
- Grounds Homepage - Mobile District Strip (frontend, required).
- Grounds Resident Directory (frontend, required).
- Grounds Resident Detail (frontend, required).
- Grounds Tuesday Tour (frontend, required).

## Technical Shape

- Service providers: `Capell\ThemeGrounds\GroundsThemeServiceProvider`.
- Actions: `InstallGroundsThemeDemoAction`.
- Data objects: `LandmarkPositionData`.
- Command signatures: `capell:theme-grounds-demo`.
- Console command classes: `DemoCommand`.
- Manifest contributions: `admin-page: Capell\ThemeGrounds\Manifest\ThemeManagementPageContribution`.
- Health checks: `Capell\ThemeGrounds\Health\ThemeGroundsHealthCheck`.
- Blade views: `packages/theme-grounds/resources/views/components/blog-notice-source.blade.php`, `packages/theme-grounds/resources/views/components/contact-path.blade.php`, `packages/theme-grounds/resources/views/components/district-search.blade.php`, `packages/theme-grounds/resources/views/components/events-source.blade.php`, `packages/theme-grounds/resources/views/components/media-experience.blade.php`, `packages/theme-grounds/resources/views/components/newsletter-band.blade.php`, `packages/theme-grounds/resources/views/components/visit-planner-path.blade.php`, `packages/theme-grounds/resources/views/footer.blade.php`, `packages/theme-grounds/resources/views/header/index.blade.php`, `packages/theme-grounds/resources/views/page.blade.php`, `packages/theme-grounds/resources/views/sections/content-listing--district.blade.php`, `packages/theme-grounds/resources/views/sections/content-listing.blade.php`, `and 13 more`.
- Cache tags: `theme-grounds`.

## Data Model

This theme has no schema impact. It relies on core Capell site, page, locale, and theme records instead of declaring package-owned tables.

## Install Impact

- Required packages: `capell-app/core`, `capell-app/theme-foundation`, `capell-app/frontend`, `capell-app/layout-builder`.
- Admin navigation: declares `admin-page: ThemeManagementPageContribution`; each Filament page or resource controls its own navigation visibility.
- Admin/editor extensions: none declared.
- Permissions: none declared in `capell.json`.
- Public routes: none declared.
- Database changes: no package migrations declared.
- Config: no package config files.
- Settings: no package settings declared.
- Queues or schedules: none declared.
- Cache tags: `theme-grounds`.
- Commands: `capell:theme-grounds-demo`.

## Common Pitfalls

- Keep required Capell packages on compatible v4 releases: `capell-app/core`, `capell-app/theme-foundation`, `capell-app/frontend`, `capell-app/layout-builder`.
- Keep public Blade and cached HTML free of authoring markers, model IDs, permissions, signed editor URLs, and lazy database queries.
- Custom write integrations must preserve invalidation for `theme-grounds` cache tags.

## Troubleshooting

| Symptom | Likely cause | Check | Fix |
| --- | --- | --- | --- |
| Package surface is missing after install | Provider or manifest is not loaded | Confirm `capell.json`, package `composer.json`, and provider registration | Reinstall the package, refresh Composer autoload, and clear host caches |
| Public output leaks unexpected state | Render data, cache variation, or authoring boundary has regressed | Check public Blade, cache tags, and public-output safety tests | Move data loading out of Blade and rerun the package public-output tests |

## Quick Start

1. Install the package: `composer require capell-app/theme-grounds`.
2. No package-specific setup command or migrations are declared.
3. Open the Grounds Homepage and confirm the public output renders without admin state.

## Next Steps

- [Package docs](README.md)
- [Overview](overview.md)
- [Troubleshooting](#troubleshooting)
- [Screenshot contract](screenshots.json)
- [Marketplace assets](assets/marketplace/)
- [Capell content language plan](../../docs/CONTENT_LANGUAGE_PLAN.md)
- [Capell documentation design system](../../docs/DESIGN_SYSTEM.md)
- [Capell and package ERD notes](../../docs/erd/capell-and-package-erds.md)
- Related packages: [Theme Foundation](../theme-foundation/README.md), [Layout Builder](../layout-builder/README.md), [Blog](../blog/README.md), [Bookings](../bookings/README.md), [Comments](../comments/README.md), [Events](../events/README.md), [Form Builder](../form-builder/README.md), [Newsletter](../newsletter/README.md), [Search](../search/README.md), [Widget Location Map](../widget-location-map/README.md), [Widget Slideshow](../widget-slideshow/README.md).
- Focused tests: `vendor/bin/pest packages/theme-grounds/tests --configuration=phpunit.xml`.

<!-- prettier-ignore-end -->