diff --git a/Directory.Build.props b/Directory.Build.props index fbff96b..8b8c1c2 100644 --- a/Directory.Build.props +++ b/Directory.Build.props @@ -3,7 +3,7 @@ 0.1.0 - alpha.1 + alpha.2 diff --git a/docs/ARCHITECTURE.md b/docs/ARCHITECTURE.md index 7c223d9..aeef892 100644 --- a/docs/ARCHITECTURE.md +++ b/docs/ARCHITECTURE.md @@ -210,7 +210,7 @@ All packages share a single version defined in `Directory.Build.props`: ```xml 0.1.0 -alpha.1 +alpha.2 ``` The build stamps it into the assemblies, and component metadata reads it from there at runtime, diff --git a/docs/COMPONENTS.md b/docs/COMPONENTS.md index f114174..b351040 100644 --- a/docs/COMPONENTS.md +++ b/docs/COMPONENTS.md @@ -67,8 +67,8 @@ your background so the splash-to-app transition doesn't flash the template's pur ## Avalonia -Every component on this page has an Avalonia version, installed by the same CLI commands. The -Avalonia templates are not on NuGet yet: they ship with the next release. +Every component on this page has an Avalonia version, installed by the same CLI commands +(since `0.1.0-alpha.2`). Overlays use Avalonia's `Popup` in the window's overlay layer: the content stays in the logical tree (theme, DataContext and `FindParentOfType` work as declared), dropdowns and popovers get diff --git a/docs/COMPONENTS_ROADMAP.md b/docs/COMPONENTS_ROADMAP.md index b6a4bfe..b76b872 100644 --- a/docs/COMPONENTS_ROADMAP.md +++ b/docs/COMPONENTS_ROADMAP.md @@ -2,9 +2,9 @@ Prioritized list of components to create for ShellUI Native, aligned with [ShellUI Components](https://github.com/shellui/shell-ui) patterns. All components should follow **compositional patterns** using Dependencies (parent + sub-components) instead of monolithic ChildContent. -Last revised: **2026-10-07** (first prerelease, `0.1.0-alpha.1`). +Last revised: **2026-10-11** (second prerelease, `0.1.0-alpha.2`). -**Status at a glance:** P0–P6 ✅ done · P7 partly done · shipped as `0.1.0-alpha.1` (58 families, 89 CLI targets) · **Avalonia (Phase 2): every component ported, not released yet**. +**Status at a glance:** P0–P6 ✅ done · P7 done except chart · `0.1.0-alpha.2`: 63 families, 94 CLI targets, each for MAUI and Avalonia. --- @@ -289,9 +289,9 @@ public static T? FindParentOfType(this Element element) where T : Element [RELEASE_NOTES.md](./RELEASE_NOTES.md)): P0–P5, P6 context-menu / carousel / stepper, and the P7 items marked ✅ above — 58 families, 89 CLI targets, MAUI only. -**Next — Phase 2 (Avalonia).** Port in the same order as MAUI (P0 → P1 first), reusing the -component APIs, tokens and sizing contract. MAUI is far ahead, so new MAUI components wait -until Avalonia has P0 + P1. +**Shipped in `0.1.0-alpha.2`:** Phase 2 (an Avalonia version of every component), then +resizable, navbar, sidebar, date-range-picker and file-upload on both platforms — 63 families, +94 CLI targets. From here on a component lands on both platforms together. -**Backlog after that:** chart (P7); and the ShellUI Blazor targets not yet ported (button-group, +**Backlog:** chart (P7); and the ShellUI Blazor targets not yet ported (button-group, input-group, command / command-palette, menubar, navigation-menu, data-table, …). diff --git a/docs/DEVELOPMENT_PLAN.md b/docs/DEVELOPMENT_PLAN.md index 5324a98..a500c04 100644 --- a/docs/DEVELOPMENT_PLAN.md +++ b/docs/DEVELOPMENT_PLAN.md @@ -4,7 +4,7 @@ Living document tracking **branches**, **phases**, and **feature implementations ShellUI Native. Companion to [PLAN.md](./PLAN.md) (long-term strategy) and [COMPONENTS_ROADMAP.md](./COMPONENTS_ROADMAP.md) (prioritized component backlog). -Last revised: **2026-10-07** (Phase 1e merged; `0.1.0-alpha.1` release prep). +Last revised: **2026-10-11** (Phase 2 merged; `0.1.0-alpha.2` release prep). --- @@ -16,9 +16,9 @@ Short-lived sub-branches (`feat//`) cut off the phase branch and m into it, not directly into `main`. ``` -main ← Phase 1a (2026-07-05), 1b (PR #2), 1c + 1d (PR #3), 1e (PR #4), brand mark (PR #5) merged - └─ chore/release-v0.1.0-alpha.1 ← first prerelease (active) - └─ feat/avalonia-implementation ← Phase 2 (next) — Avalonia templates + reference impl +main ← Phase 1 (PRs #1–#5), release 0.1.0-alpha.1 (PR #6), Phase 2 Avalonia (PRs #7–#13), + layout, navigation and pickers on both platforms (PR #14) merged + └─ chore/release-v0.1.0-alpha.2 ← second prerelease, the first with Avalonia (active) └─ feat/winui ← Phase 3 (conditional) ``` @@ -35,8 +35,8 @@ main ← Phase 1a (2026-07-05), 1b (PR #2), 1c + 1d (PR #3), 1e (PR #4), brand | Branch | Base | Status | Purpose | |--------|------|--------|---------| -| `main` | — | Phase 1a–1e, release `0.1.0-alpha.1`, Phase 2 merged: every component has an Avalonia version | 92 registry entries (89 CLI targets, 58 families), each with MAUI and Avalonia content | -| `feat/p6-layout-navigation` | `main` | **Active** | resizable, navbar, sidebar (finishes P6), date-range-picker and file-upload (P7), each for MAUI and Avalonia | +| `main` | — | Phase 1, release `0.1.0-alpha.1`, Phase 2 and PR #14 merged | 97 registry entries (94 CLI targets, 63 families), each with MAUI and Avalonia content | +| `chore/release-v0.1.0-alpha.2` | `main` | **Active** | Second prerelease: the first with Avalonia, plus five new components | --- @@ -434,7 +434,26 @@ After merge: tag `v0.1.0-alpha.1` on `main` and push the tag. --- -## Phase 2 — Avalonia (active; one branch per tier, `feat/avalonia-p7-remaining` now) +## Release `0.1.0-alpha.2` — `chore/release-v0.1.0-alpha.2` (**active**) + +Second NuGet prerelease of `ShellUI.Native.CLI`: the first with Avalonia templates, plus +resizable, navbar, sidebar, date-range-picker and file-upload on both platforms. + +- [x] `Directory.Build.props` → `0.1.0` + `alpha.2` +- [x] [RELEASE_NOTES.md](./RELEASE_NOTES.md) section, with the upgrade note for `calendar` +- [x] Install docs cover Avalonia (README, QUICKSTART, the CLI package README) +- [x] README version badge is static, set by `prepare-release.ps1` (the live NuGet badge + sometimes failed to load on GitHub) +- [x] The packed tool, installed from the `.nupkg`, outside the repo: `init` and all 94 CLI + targets added together in a fresh Avalonia app and in a fresh `dotnet new maui` app (Windows + target), each building with 0 warnings; `update calendar` fixes a project that has the + alpha.1 Calendar + +After merge: tag `v0.1.0-alpha.2` on `main` and push the tag. + +--- + +## Phase 2 — Avalonia (**merged**, PRs #7–#14; released in `0.1.0-alpha.2`) Cross-desktop (Windows + macOS + Linux) from one XAML codebase. diff --git a/docs/PLAN.md b/docs/PLAN.md index 67d1124..cae6cbc 100644 --- a/docs/PLAN.md +++ b/docs/PLAN.md @@ -25,15 +25,15 @@ ShellUI Native brings the same beautiful, accessible, and customizable component ### Phase 1: MAUI (Primary Focus) - **Target:** .NET MAUI (iOS, Android, Windows, macOS) on .NET 10 - **Components:** 50+ native controls -- **Status:** First prerelease `0.1.0-alpha.1` — 58 component families (89 CLI targets), - P0–P5 complete, P6 partly; remaining work tracked in +- **Status:** Released since `0.1.0-alpha.1`; `0.1.0-alpha.2` has 63 component families + (94 CLI targets), P0–P6 complete; remaining work tracked in [COMPONENTS_ROADMAP.md](./COMPONENTS_ROADMAP.md). ### Phase 2: Avalonia UI - **Target:** Windows, macOS, Linux (desktop-first; mobile/WASM heads are stretch goals) - **Components:** 50+ controls, mirrored 1:1 with the MAUI set once that set stabilizes -- **Status:** Planned — starts after MAUI hits P0+P1 parity and Template System v2 lands. - Supersedes the former WPF phase. +- **Status:** Released in `0.1.0-alpha.2` — every component has an Avalonia version; checked + on Windows. Supersedes the former WPF phase. - **Why now and not later:** the template/pattern work only needs to be proven once (on MAUI); porting to Avalonia is mechanical translation of the same component contracts, and doing it before the template system calcifies around MAUI-only assumptions is cheaper than retrofitting @@ -147,7 +147,7 @@ dotnet tool install -g ShellUI.Native.CLI --prerelease ```bash shellui-native init # Initialize project (creates shellui-native.json) shellui-native add # Add components (copies to Components/UI/) -shellui-native list # List available components (89 targets) +shellui-native list # List available components (94 targets) shellui-native remove # Remove components shellui-native update # Update components to latest version ``` @@ -162,7 +162,7 @@ shellui-native update # Update components to latest version "installedComponents": [ { "name": "button", - "version": "0.1.0-alpha.1", + "version": "0.1.0-alpha.2", "platform": "MAUI", "installedAt": "2026-01-11T...", "isCustomized": false diff --git a/docs/QUICKSTART.md b/docs/QUICKSTART.md index 5de469e..0f8ec8f 100644 --- a/docs/QUICKSTART.md +++ b/docs/QUICKSTART.md @@ -5,7 +5,7 @@ Get started with ShellUI Native in under 5 minutes. ## Prerequisites - .NET 10.0 SDK (see [global.json](../global.json)) -- A .NET MAUI project (`dotnet new maui`); Avalonia support is the next phase (see [DEVELOPMENT_PLAN.md](./DEVELOPMENT_PLAN.md)) +- A .NET MAUI project (`dotnet new maui`) or an Avalonia 12 project (`dotnet new avalonia.app`) ## Installation @@ -36,8 +36,8 @@ This will: - Create `shellui-native.json` configuration - Generate theme resources (MAUI) -> Templates exist for MAUI only so far. In an Avalonia, WinUI or WPF project, `init` skips the -> `Shell.cs` utility and `add` reports that the component has no template for that platform. +> Templates exist for MAUI and Avalonia. In a WinUI or WPF project, `init` skips the `Shell.cs` +> utility and `add` reports that the component has no template for that platform. ### 4. Add Components @@ -54,7 +54,7 @@ shellui-native add button,input,card ### 5. Load the Theme -Publish the theme tokens before the first page loads, in `App.xaml.cs`: +Publish the theme tokens before the first page loads. In a MAUI app, in `App.xaml.cs`: ```csharp public App() @@ -64,6 +64,16 @@ public App() } ``` +In an Avalonia app, in `App.axaml.cs`: + +```csharp +public override void Initialize() +{ + AvaloniaXamlLoader.Load(this); + Components.UI.ShellTheme.EnsureInitialized(); +} +``` + Components also do this on first use, but calling it early lets your own `{DynamicResource ShellUI*}` references resolve on the first page. See [COMPONENTS.md § Theming](./COMPONENTS.md#theming) for switching and customizing the theme. @@ -83,6 +93,10 @@ Components also do this on first use, but calling it early lets your own ``` +In Avalonia the namespace is `xmlns:ui="using:YourProject.Components.UI"`; the components have +the same names and properties. See [COMPONENTS.md § Avalonia](./COMPONENTS.md#avalonia) for the +few differences. + ## Common Commands | Command | Description | diff --git a/docs/README.md b/docs/README.md index f622a80..bd03527 100644 --- a/docs/README.md +++ b/docs/README.md @@ -10,11 +10,11 @@

One design system, every platform.
- Copy-and-own native components for .NET MAUI, inspired by shadcn/ui. + Copy-and-own native components for .NET MAUI and Avalonia, inspired by shadcn/ui.

- ShellUI.Native.CLI on NuGet + ShellUI.Native.CLI v0.1.0-alpha.2 on NuGet MIT license

@@ -39,7 +39,7 @@ Unlike [ShellUI Blazor](https://shellui.dev/), **ShellUI Native does not use Tai # Install the CLI tool (prerelease) dotnet tool install -g ShellUI.Native.CLI --prerelease -# Initialize in your MAUI project +# Initialize in your MAUI or Avalonia project shellui-native init --yes # Add components @@ -53,8 +53,8 @@ shellui-native list | Platform | Status | .NET Version | |----------|--------|--------------| -| .NET MAUI | Available (`0.1.0-alpha.1`) — Android, iOS, Mac Catalyst, Windows | .NET 10.0 | -| Avalonia UI | Every component ported (Phase 2); not on NuGet yet, ships with the next release | .NET 10.0 (Avalonia 12) | +| .NET MAUI | Available since `0.1.0-alpha.1` — Android, iOS, Mac Catalyst, Windows | .NET 10.0 | +| Avalonia UI | Available since `0.1.0-alpha.2` — every component; checked on Windows | .NET 10.0 (Avalonia 12) | | WinUI 3 | Conditional (Phase 3) | .NET 10.0 | WPF is intentionally not on this list — it's recognized for project detection only, not an @@ -126,7 +126,7 @@ YourProject/ │ └── Shell.cs ├── Resources/ │ └── Styles/ -│ └── ShellUITheme.xaml +│ └── ShellUITheme.xaml # MAUI only └── shellui-native.json ``` diff --git a/docs/RELEASE_NOTES.md b/docs/RELEASE_NOTES.md index 58f8e07..2396fbb 100644 --- a/docs/RELEASE_NOTES.md +++ b/docs/RELEASE_NOTES.md @@ -1,5 +1,60 @@ # ShellUI Native Release Notes +# ShellUI Native v0.1.0-alpha.2 🧪 + +> Avalonia support and five new components. Every component now has a .NET MAUI and an Avalonia version, installed by the same commands. Still a prerelease, so install with `--prerelease`. Report issues via [GitHub Issues](https://github.com/shellui-dev/shellui-native/issues). + +## 📦 Install or update + +```bash +dotnet tool update -g ShellUI.Native.CLI --prerelease + +cd YourApp +shellui-native init --yes +shellui-native add button input card +``` + +Requires the .NET 10 SDK and a .NET MAUI or Avalonia 12 project. `init` detects which one it is. + +## 🟣 Avalonia + +- All 63 component families (94 CLI targets) have an Avalonia version, with the same names, properties and variants as MAUI. The few differences are listed in [COMPONENTS.md](https://github.com/shellui-dev/shellui-native/blob/main/docs/COMPONENTS.md#avalonia). +- Setup after `init`: call `Components.UI.ShellTheme.EnsureInitialized();` in `App.Initialize`, after `AvaloniaXamlLoader.Load(this);`, and add `xmlns:ui="using:YourApp.Components.UI"` to your XAML. `init` prints these steps. +- Overlays use Avalonia's `Popup`: menus and popovers flip above the trigger when there is no room below, a click outside or Escape closes them, and an open dialog, drawer or sheet keeps keyboard focus inside it. +- Keyboard: interactive parts are tab stops with shadcn's focus ring, and Enter / Space activate them. +- In an initialized project, `shellui-native list` shows the components for that project's platform. + +## ✨ New components + +For MAUI and Avalonia. + +| Component | What it is | +|---|---| +| `resizable` | Panels side by side or stacked, with a divider to drag. Each panel has a share of the space and a minimum size; groups nest. | +| `navbar` | A top bar with a brand, links and actions. Below 640px wide the links move into a menu under the bar. | +| `sidebar` | An app sidebar with groups and items that collapses to an icon rail. | +| `date-range-picker` | One calendar for a start and an end date. `Calendar` gains `RangeStart` and `RangeEnd`, which highlight a span of days. | +| `file-upload` | A drop zone that opens the platform file picker and lists the picked files. | + +## 🧰 CLI + +- `init` derives a valid namespace when the project file has no `RootNamespace`. + +## ⬆️ Upgrading from alpha.1 + +Components already in your project are not changed by installing the new tool. `date-range-picker` needs the new `Calendar`: if `calendar` is already in your project, run `shellui-native update calendar` before adding it. `update` rewrites the file, so reapply any edits you made to it. + +## ⚠️ Known limitations + +- Avalonia was checked on Windows. CI builds the Avalonia demo on Linux, Windows and macOS, but the components have not been run on macOS or Linux, or with touch. +- The five new components were checked on Windows (MAUI and Avalonia). On Android, iOS and Mac Catalyst they build but have not been run. +- `file-upload`: on MAUI, dropping files works on Windows only. The platform file dialog and file drop have not been tested beyond the build on either platform. +- iOS and Mac Catalyst build but have not been run on a device; Escape does not close overlays on Mac Catalyst yet. +- Very large MAUI pages on Windows can hit WinUI's layout-pass limit (`Layout cycle detected`). Split the page or keep sections hidden until needed; see [COMPONENTS.md](https://github.com/shellui-dev/shellui-native/blob/main/docs/COMPONENTS.md#long-pages-on-windows). +- The docs site (native.shellui.dev) is not live yet; see [COMPONENTS.md](https://github.com/shellui-dev/shellui-native/blob/main/docs/COMPONENTS.md) for usage. + +--- + # ShellUI Native v0.1.0-alpha.1 🧪 > The first public prerelease of ShellUI Native: shadcn-style, copy-and-own components for .NET MAUI, with the same design tokens as [ShellUI](https://shellui.dev/) for Blazor. It is a prerelease, so install with `--prerelease`. Report issues via [GitHub Issues](https://github.com/shellui-dev/shellui-native/issues). diff --git a/docs/RELEASING.md b/docs/RELEASING.md index cf3fe34..ac60b51 100644 --- a/docs/RELEASING.md +++ b/docs/RELEASING.md @@ -35,7 +35,7 @@ No `NUGET_API_KEY` secret is needed; delete an old one if it exists. ## Releasing a version -1. Set the version in `Directory.Build.props` (`ShellUINativeVersion` and `ShellUINativeVersionSuffix`). +1. Set the version in `Directory.Build.props` (`ShellUINativeVersion` and `ShellUINativeVersionSuffix`) and in the version badge at the top of [README.md](./README.md). `prepare-release.ps1 -Version 0.1.0 -Suffix alpha.2` does both, then tests and packs. 2. Add a `# ShellUI Native v` section to [RELEASE_NOTES.md](./RELEASE_NOTES.md). It becomes the GitHub release text. 3. Merge to `main`, then tag and push: diff --git a/prepare-release.ps1 b/prepare-release.ps1 index ab43261..ce05c03 100644 --- a/prepare-release.ps1 +++ b/prepare-release.ps1 @@ -22,6 +22,15 @@ $content = $content -replace '[^<]*