Skip to content

feat(cli): blocks, numbered presets like ShellUI's dashboard-01 - #36

Merged
Shewart merged 2 commits into
feat/edge-menufrom
feat/blocks
Oct 16, 2026
Merged

Shewart merged 2 commits into
feat/edge-menufrom
feat/blocks

Conversation

@Shewart

@Shewart Shewart commented Oct 16, 2026

Copy link
Copy Markdown
Contributor

Description

Blocks: numbered presets built from components, like ShellUI's dashboard-01.

Stacked on the edge-menu PR (base feat/edge-menu); this PR adds two commits.

  • shellui-native add bottom-nav-01 writes one file to Components/Blocks/BottomNav01.cs (namespace <App>.Components.Blocks, next to Components/UI or Components/Native) and installs the components it uses. list shows blocks in a new Block category.
  • Six blocks, code-built views on MAUI and Avalonia:
    • bottom-nav-01: app shell with a raised Pay button and an avatar tab.
    • bottom-nav-02: Material 3 tab bar.
    • bottom-nav-03: floating tab bar that hides on scroll; only the active tab is labelled.
    • bottom-nav-04: compact capsule; the active tab widens with its label.
    • bottom-nav-05: the active tab rises into a circle; the bar hides on scroll.
    • edge-menu-01: a page with a solid tool dock on its right edge.
  • The bottom-nav blocks expose Pages (one view per tab Value), Nav and Show(value); 01 adds ActionClicked. edge-menu-01 exposes Page, Menu and ToolPicked.
  • scripts/sync-templates.py reads Components/Blocks in both demos; block templates install to ../Blocks/<Name>.cs.
  • Both demos have a Blocks section. The browser preview app (examples/Avalonia.Preview) compiles the blocks, so docs previews can use them.
  • Docs: docs/COMPONENTS.md "Blocks", CLI README, roadmap.

Type of Change

  • New feature (non-breaking change adding functionality)

Checklist

  • My code follows the project's style guidelines
  • I have performed a self-review of my code
  • I have added comments where necessary
  • I have updated the documentation (if applicable)
  • My changes generate no new warnings
  • I have tested on at least one platform (MAUI/WinUI/WPF)

Testing Done

  • Solution builds with 0 warnings; 1559 main tests (new BlockTests: registry, install path, namespaces with Components/UI and Components/Native) and 174 headless tests (smoke renders of every block) pass; format clean.
  • add bottom-nav-01 bottom-nav-03 bottom-nav-05 edge-menu-01 in a fresh Avalonia app and a fresh dotnet new maui app: four files in Components/Blocks, their components in Components/UI, both build 0/0 (MAUI on Windows and Android); list shows the blocks.
  • Preview app builds with a block preview.
  • Blocks checked in light and dark (Avalonia headless renders).

Shewatipa Tseisi added 2 commits October 16, 2026 16:30
Blocks are ready-made screens built from components. `add bottom-nav-01`
writes one file the user owns to Components/Blocks (namespace
<App>.Components.Blocks, next to Components/UI or Components/Native) and
installs the components it uses.

- bottom-nav-01: app shell, tab bar with a raised Pay button and an
  avatar tab (wallet app)
- bottom-nav-02: Material 3 tab bar
- bottom-nav-03: floating tab bar that hides on scroll, active label only
- bottom-nav-04: compact capsule, the active tab widens with its label
- bottom-nav-05: the active tab rises into a circle; hides on scroll
- edge-menu-01: a page with a solid tool dock on its right edge

The bottom-nav blocks expose Pages (one view per tab Value), Nav and
Show(value); 01 adds ActionClicked; edge-menu-01 exposes Page, Menu and
ToolPicked. Code-built views (no XAML), MAUI and Avalonia.

- ComponentCategory.Block; block templates install to ../Blocks/<Name>.cs
- sync-templates.py reads Components/Blocks in both demos
- Both demos show every block in a phone frame
- BlockTests (registry, install path, namespaces with Components/UI and
  Components/Native); the headless smoke test renders the blocks
- Docs: COMPONENTS.md "Blocks", CLI README, roadmap
A docs preview can show a block with xmlns:blocks="using:AvaloniaDemo.Components.Blocks".
@github-actions github-actions Bot added documentation Improvements or additions to documentation cli core templates examples labels Oct 16, 2026
@Shewart
Shewart marked this pull request as ready for review October 16, 2026 17:35
@Shewart
Shewart merged commit 7ba746c into feat/edge-menu Oct 16, 2026
2 checks passed
@Shewart Shewart mentioned this pull request Oct 16, 2026
8 tasks done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cli core documentation Improvements or additions to documentation examples templates

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant