Jump to content

IdeaCms/SPEC

From MindAttic Docs

IdeaCms — Product specification

The complete product, written down before it is built (owner, 2026-11-30, MAT-T360). Every epic, feature and story the finished product will have is listed here, built or not. The ticket tree mirrors this file one to one: every ID below is a ticket. Nothing gets built unless it is here, and anything taken out of here is closed wont-do in the tree. docs/RELEASE.md says which part of this the current milestone delivers.

1. Product definition

Place in the ecosystem: a product (Apps) in the MindAttic ecosystem: the owner's CMS. It owns no platform concern: sign-in from MindAttic.Authentication, settings and keys from MindAttic.Vault, files from MindAttic.Storage, logging from MindAttic.Log.

IdeaCms is a single-deployment Blazor Server CMS for .NET 10 that hosts many pages and goes live the moment a signed .idea package is uploaded, with no redeploy and no app restart. A Page is free-form markup, a Theme wraps it, Plugins add page-wide behaviour and Components render where their tag is placed; versions are whole numbers that coexist, and a bad reference degrades to a placeholder, never a crash. It is the owner's own CMS, run as an internal app from R:\MindAttic\Apps\IdeaCms against local SQL Server. The finished product is the 1.1 CMS: everything in docs/USER_STORIES.md built, local-only, documented and signed off.

2. Scope boundary

2.1 In the product

  • Data pages and Code pages rendered through one catch-all PageHost, sanitized by trust level.
  • The .idea package: manifest, signing, packing, versioned install, NuGet fetch, the ma-idea CLI.
  • Themes (light and dark), Plugins and Components, with the 53-package first-party library in library/.
  • Versioning, temporal page history, the Admin Inbox and graceful degradation.
  • Media storage (local disk; the Azure Blob provider stays in code), idealist export/import, multi-domain sites.
  • The admin (Monaco editor, Page Properties, packages, sites, onboarding tours) and sign-in through MindAttic.Authentication with emailed password reset.
  • Local deploy to R: through the shared run menu, local SQL Server, vendored private packages.

2.2 Never in the product

  • Public hosting on Azure, and the hourly-reset public demo (old stories IDEA-US-J4 one-command provisioning, J5 CI deploy to App Service, J6 Turnstile demo): retired with Azure on 2026-11-26 (MAT-T297); IDEA-T88 removes what remains.
  • A Hetzner or other server move (IDEA-T75..T77, closed wont-do): IdeaCms is an internal local app.
  • Zones, panes, slots or grid layouts; SemVer; per-page routing; WebAssembly for uploaded packages: the BIBLE's "What it is NOT" (§3).
  • New citizen kinds, new admin panels or new package formats beyond the stories below.
  • Open-ended sweeps: exhaustive bughunts, "run the whole suite until green" loops, cleanup passes, and broad unit-test backfill for untested classes (the 2026-10-14 coverage audit, IDEA-T3..T13, T61..T69).

3. Users and roles

  • Author: writes pages in the admin (Monaco, Page Properties, citizen tags); with the Cms.AuthorRawMarkup claim their pages carry Author trust.
  • Operator / Admin: installs and retires packages, manages sites, triages the Admin Inbox, signs in with the Admin role.
  • Citizen-Dev: builds Themes, Plugins and Components as .idea packages in library/ or elsewhere.
  • Visitor: reads the rendered pages.
  • Maintainer: the owner and agents building and deploying the engine.

4. Requirements

Status is built (closed ticket, with evidence) or MS-n: the milestone in §7 that delivers it. Every unbuilt story is approved and prioritised in build order; the planner splits a story into tasks when the queue reaches it. Built stories carry their old IDEA-US-* story ID and the tests that verify them.

E1. Page authoring and rendering — IDEA-T109 — built

Authors compose pages from citizen tags in free markup; every body is sanitized, assets cascade in order and the right page answers every route.

F1.1 Citizen tags and pages — IDEA-T110 — built

  • S1.1.1 Citizen tags in markup — IDEA-T111 — built As an Author, I can place a <Kind.Key /> tag (optionally data-version="n") in free-form markup and have it resolve to the right citizen, so I compose without zones. Acceptance:
    • Given a body with citizen tags, When the reference parser runs, Then dotted, short-form and kind-attribute tags parse to the right (Kind,Key,Version); an unknown kind never becomes a Page reference; any stored brace token is migrated to a tag. Evidence: IDEA-US-A1, verified by RenderGuardTests.TryParseTag_ShortForm_WithVersionAndDottedKey, RenderGuardTests.Parse_DottedTag_CollectedWithCorrectKind, RenderGuardTests.Parse_PascalTag_WithUnrecognisedKind_StillDefaultsToComponent, LegacyTokenMigrationTests.
  • S1.1.2 CmsInclude render parity — IDEA-T112 — built As a Visitor, a code-page <CmsInclude> and a data-page tag render identically for Resolved/Missing/Disabled outcomes, so the authoring path doesn't change behavior. Evidence: IDEA-US-A2, verified by CmsIncludeParityTests.CmsInclude_MatchesDataPageInclude.
  • S1.1.3 Write-time author trust — IDEA-T113 — built As an Author with the Cms.AuthorRawMarkup claim, my page is stamped Author trust at write time (without it, Untrusted), and my deliberate JavaScript runs from the Page JS field. Acceptance:
    • Given a save, When the writer holds/doesn't hold the claim, Then BodyTrust is Author/Untrusted and the author Uid is captured (truncated to 64). Evidence: IDEA-US-A3, verified by PageAuthoringTests.Stamp_WithClaim_IsAuthor_AndCapturesUid, Stamp_WithoutClaim_IsUntrusted, Stamp_TruncatesUidTo64.
  • S1.1.4 Sanitized page bodies — IDEA-T114 — built As a Visitor, every page body is sanitized before it renders: no script, handler, executable URL, frame, form or style element survives at any trust level; Author pages keep their citizen tags and settings, Untrusted pages keep none. Evidence: IDEA-US-A4, verified by RawContentGateTests: Author_ScriptStyleHandlersAndFrames_AreStripped, Author_KeepsCitizenTagsAndTheirSettings_ButNotHandlersOrScriptUrls, Author_KeepsSanitizedInlineStyleAndCustomProperties, Untrusted_DropsCitizenTags, Untrusted_StripsScriptTag, Untrusted_NeutralizesJavascriptUri; RawTextElementFrameTests.FreeFormPage_EmitsStyleAndScriptAsSingleMarkupFrames.
  • S1.1.5 Page CRUD and publishing — IDEA-T115 — built As an Author, I can CRUD pages with soft-delete and publish/enable under the Admin policy. Evidence: IDEA-US-A5, verified by PageAdminServiceTests, AdminServiceContractTests.
  • S1.1.6 Seeded Frontpage data page — IDEA-T116 — built As a Visitor, the seeded Frontpage Data page renders its library components through its theme; the seed creates it, migrates a stock compiled copy to the Data page, and never overwrites an admin-authored one. Evidence: IDEA-US-A6, verified by SeededPageRenderTests: SeedBodyTags_ParseToCorrectKind_FloatingVersion, FrontpageBody_AllSeedTokens_ParseFromTheRealSeededPage, Seed_MigratesStockCodeFrontpage_ToDataPage_ButNeverAnAdminPage, SeedBody_InstalledTabsComponent_ExpandsToResolvedFrame.
  • S1.1.7 Empty route forwards home — IDEA-T117 — built As a Visitor, navigating to the application with no route forwards me to the site's front page: the Site-scope page.frontpage setting, else the Host-scope one (default frontpage); the stock home page is soft-disabled by the seed. Evidence: IDEA-US-A7, verified by SeededPageRenderTests.Seed_SoftDisablesStockHomePage_AndNeverAnEditedOne; the forward observed live — GET / → 302 → /frontpage.

F1.2 Page authoring tools — IDEA-T118 — built

  • S1.2.1 Theme from Page Properties — IDEA-T119 — built As an Author, I set a page's Theme from a dropdown in the collapsible Page Properties panel, so theme assignment is metadata, not markup. Evidence: IDEA-US-G1, verified by AdminAssignmentTests.CatalogFilter_Theme_ReturnsOnlyThemes, AdminAssignmentTests.ThemeToken_PinnedVersion_ParsesBack; the panel UI is browser-confirmed.
  • S1.2.2 Page SEO title and description — IDEA-T120 — built As an Author, I can set a custom SEO Title and Description for a page. Evidence: IDEA-US-G2, verified by PageAdminServiceTests: Save_WithSeoFields_PersistsThroughGetAsync, Save_WithNullSeoFields_ReturnsNullOnLoad.
  • S1.2.3 Library lives beside engine — IDEA-T121 — built As a Citizen-Dev, the first-party library lives in the same git repo as the engine (library/) without coupling the two build graphs. Evidence: IDEA-US-G3, verified by Abstractions types used by library citizens are exercised by PackerTests and ManifestAssetPackerTests; ma-idea verify is green across all 53 .ideas.
  • S1.2.4 Generated instance settings editor — IDEA-T122 — built As an Author, I configure each citizen instance on a page — a component's tag attributes, or the theme/plugin/code-page slots — from a generated editor, and share configuration by Copy/Paste between instances of the same citizen. Evidence: IDEA-US-G4, verified by InstanceSettingsTests, BodyTagIndexTests, InstanceClipboardTests, IdeaListTests.RoundTrip_CarriesThemeAndPluginInstanceSettings.
  • S1.2.5 Role-gated page workflow — IDEA-T123 — built As an Author, I can move a page through a named workflow whose transitions are role-gated, and only the Published state publishes it. Evidence: IDEA-US-G5, verified by WorkflowServiceTests.
  • S1.2.6 Old slugs redirect 301 — IDEA-T124 — built As a Visitor, an old or vanity slug answers 301 to the page's current slug. Evidence: IDEA-US-G6, verified by SlugRedirectServiceTests.
  • S1.2.7 Instance settings history — IDEA-T125 — built As an Author, tagless instance settings keep a version history and roll back. Evidence: IDEA-US-G7, verified by WidgetInstanceSettingsServiceTests.

F1.3 Asset cascade and runtime load — IDEA-T126 — built

  • S1.3.1 Collectible package load contexts — IDEA-T127 — built As an Operator, a .idea citizen loads through a per-package collectible ALC; host types unify by reference identity and others delegate to the default resolver. Evidence: IDEA-US-E1, verified by AlcAwareTypeResolverTests, CmsPackageLoadContextTests.
  • S1.3.2 Ordered, deduped head assets — IDEA-T128 — built As an Author, a page's citizen css/scripts are ordered, deduped, and hoisted into <head>, fed by the manifest→Extra data path. Evidence: IDEA-US-E2, verified by PageAssetCollectorTests, AssetDataPathTests.Install_Then_Reload_SurfacesManifestCssScripts_OntoDescriptorExtra, UsesDeclarationTests.Collect_FromUses_HoistsReferencedCitizenAssets.
  • S1.3.3 Uses declarations parse — IDEA-T129 — built As a Citizen-Dev, a [Uses]/uses[] declaration parses (bare floats, pinned, case-insensitive kind, rejects malformed) and drives hoisting + the delete-guard. Evidence: IDEA-US-E3, verified by UsesDeclarationTests.TryParseUse_BareKey_FloatsToLatest, UsesDeclarationTests.TryParseUse_RejectsMalformed.
  • S1.3.4 Corrupt manifest tolerated on reload — IDEA-T130 — built As an Operator, a corrupt manifest during reload doesn't abort the reload — it leaves that descriptor's Extra null. Evidence: IDEA-US-E4, verified by AssetDataPathTests.CorruptManifestJson_DoesNotAbortReload_LeavesThatExtraNull.
  • S1.3.5 Cascade layers order tiers — IDEA-T131 — built As an Author, tiers win by cascade layer — Global → Theme → Page → Component — so I never need !important to beat a lower tier, and a Component keeps its own look on any page. Evidence: IDEA-US-E5, verified by CmsHeadCssLayerTests.LayerOrderStatement_IsEmittedOnceAndFirst_EvenWhenAllTiersAreEmpty, CmsHeadCssLayerTests.ComponentLayer_IsDeclaredAfterPageLayer_SoComponentWinsPrecedence, FreeFormPageCssTests.
  • S1.3.6 Untrusted CSS merge and lint — IDEA-T132 — built As an Author, saving Untrusted page CSS collapses same-selector duplicate blocks into one without touching anything else, and I am warned about a shorthand that overrides some of its longhands. Evidence: IDEA-US-E6, verified by CssConflictMergerTests, CssShorthandLinterTests.

F1.4 Themes and modes — IDEA-T133 — built

The automated contrast proof is S8.1.1, in the 1.1 milestone.

  • S1.4.1 Light and dark theme palettes — IDEA-T134 — built As a Visitor, every theme has an AA-compliant light and dark palette; the site's default mode applies on first visit, my toggle choice persists, and neither flashes the wrong mode. Evidence: IDEA-US-N1, verified by no automated test: contrast was checked by hand with a WCAG relative-luminance script against every theme × mode × text/muted/link/button pair.

E2. Signed packages and versions — IDEA-T135 — built

Signed .idea packages install idempotently with whole-number versions, pinned or floating references, history and graceful degradation.

F2.1 The .idea package and install — IDEA-T136 — built

  • S2.1.1 Validated idea manifests — IDEA-T137 — built As a Citizen-Dev, the .idea manifest kernel reads and validates with explicit errors, rejecting host assemblies in bin/ and retired categories. Evidence: IDEA-US-D1, verified by ManifestReaderTests, ManifestValidatorTests, IdeaArchiveReaderTests.
  • S2.1.2 Lossless reflection-only packing — IDEA-T138 — built As a Citizen-Dev, packing is reflection-only and lossless/forward-compatible, with SHA-256 integrity and a zip-slip-guarded reader. Evidence: IDEA-US-D2, verified by PackerTests, ManifestAssetPackerTests, Sha256HasherTests, PackageExtractorTests.
  • S2.1.3 Whole-number version resolver — IDEA-T139 — built As an Operator, the whole-number version/collision resolver picks the active version, refuses downgrades, and refuses a compiled-citizen collision without confirmation. Evidence: IDEA-US-D3, verified by PackageVersionResolverTests.
  • S2.1.4 Idempotent package install — IDEA-T140 — built As an Operator, installing a .idea is idempotent: it registers the InstalledPackage row + a mirrored catalog row, retains prior versions on upgrade, soft-disables, and reloads the catalog. Evidence: IDEA-US-D4, verified by PackageInstallServiceTests, SeedOnInstallTests.
  • S2.1.5 Package blobs kept verbatim — IDEA-T141 — built As an Operator, a package blob is kept verbatim in a blob store for re-share/rollback. Evidence: IDEA-US-D5, verified by LocalFilePackageBlobStoreTests.
  • S2.1.6 Local folder package source — IDEA-T142 — built As an Operator, a local folder source discovers packable .idea candidates. Evidence: IDEA-US-D6, verified by LocalFolderPackageSourceTests.
  • S2.1.7 Only signed packages install — IDEA-T143 — built As an Operator, only a .idea signed by the host-trusted certificate installs, whatever path its bytes took. Evidence: IDEA-US-D7, verified by PackageSignerTests; PackageInstallServiceTests: Install_UnsignedPackage_ThrowsPackageSignatureException_NoRowsWritten, Install_TamperedPackage_ThrowsPackageSignatureException_NoRowsWritten, Install_UntrustedSigner_ThrowsPackageSignatureException; VaultPackageSigningTrustTests.
  • S2.1.8 Same-version conflict reported — IDEA-T144 — built As an Operator, re-publishing the same version with different content is a conflict I am told about, not a silent no-op, while a re-sign of unchanged content is a no-op. Evidence: IDEA-US-D8, verified by PackageInstallServiceTests.Install_HashConflict_ThrowsInstallException_AndRaisesAdminInboxAlert, PackageInstallServiceTests.Install_SameVersion_SameContent_ReSignedDifferently_IsStillANoOp, PackageVersionResolverTests.SameVersion_DifferentHash_IsAConflict_NotANoOp.
  • S2.1.9 Unmet requirements refused — IDEA-T145 — built As an Operator, a package whose requires[] is unmet, or whose minHostVersion exceeds the host, is refused with nothing written. Evidence: IDEA-US-D9, verified by PackageInstallServiceTests.Requires_Missing_ThrowsInstallException_NoRowsWritten, PackageInstallServiceTests.Requires_AllPresent_InstallSucceeds, ManifestValidatorTests.
  • S2.1.10 Idealist entries fetched from NuGet — IDEA-T146 — built As an Operator, an .idealist entry not present locally is fetched from a NuGet feed (MindAttic.Ideas.{Category}.{Key} at {n}.0.0) and cached. Evidence: IDEA-US-D10, verified by NuGetIdeaListPackageResolverTests against a fake fetcher; the live GitHub Packages fetch is not automated.

F2.2 Versioning and history — IDEA-T147 — built

  • S2.2.1 Pinned or floating versions — IDEA-T148 — built As an Author, I pin a version (data-version="3") or float to the highest enabled version (omit it), so I juggle versions only when I care. Evidence: IDEA-US-B1, verified by ContentCatalogTests.FindLatest_StillPicksTheHighestVersion, PageAssetCollectorTests.PinnedVersion_ResolvesViaFind_FloatingResolvesToHighest.
  • S2.2.2 Guarded version delete — IDEA-T149 — built As an Operator, I cannot delete a version while any page pins it (body tag, uses[], theme pin or ActivePluginsJson); a floating reference blocks only when deleting would orphan it. Evidence: IDEA-US-B2, verified by ContentLifecycleServiceTests: PinnedVersion_AlwaysBlocks_AndListsSlug, FloatingReference_BlocksOnlyWhenItWouldOrphan, DisabledOrUnpublishedPage_IsNotABlockingReference, ActivePluginsJson_VersionedPin_BlocksDeletion, ThemePin_Blocks_AndThemeFloatFollowsOrphanRule; and UsesDeclarationTests.DeleteGuard_BlocksDeletingAComponentACompiledPagePins.
  • S2.2.3 Disable reloads the catalog — IDEA-T150 — built As an Operator, disabling a content version reloads the catalog so the tag then resolves as Disabled. Evidence: IDEA-US-B3, verified by ContentLifecycleServiceTests.SetEnabledFalse_ReloadsCatalog_SoResolveTagReportsDisabled.
  • S2.2.4 Data-layer integrity guards — IDEA-T151 — built As an Operator, the EF model guards reserved columns and a delete-guard projection, so integrity holds at the data layer. Evidence: IDEA-US-B4, verified by CmsModelGuardTests.
  • S2.2.5 Page history and rollback — IDEA-T152 — built As an Operator, I can inspect and roll back to any prior page state via temporal history in the Admin Page History panel. Evidence: IDEA-US-B5, verified by PageHistoryServiceTests: RestoreAsync_CopiesSnapshotContentFields_OntoCurrentPage, RestoreAsync_ReStampsTrust_FromRestoringUserClaims, RestoreAsync_NonAdminUser_StampsUntrusted, RestoreAsync_UnknownPage_ReturnsFalse; and the live PageHistorySqlServerTests.GetHistoryAsync_OnSqlServer_ReturnsOrderedTemporalVersions ([Explicit], LocalDB).

F2.3 Degradation and Admin Inbox — IDEA-T153 — built

  • S2.3.1 Deduped Admin Inbox messages — IDEA-T154 — built As an Operator, a missing/disabled dependency raises a deduped Admin Inbox message that collapses recurrences and reopens after resolution. Evidence: IDEA-US-C1, verified by AdminInboxServiceTests: RaiseAsync_SameDedupKey_CollapsesToOneRow, RaiseAsync_AfterResolve_ReopensToNew, UnreadCount_CountsOnlyNew.
  • S2.3.2 Render never throws on references — IDEA-T155 — built As a Visitor, the render thread never throws on a bad reference — it degrades to a placeholder that links to /admin/upload?missing=<reference> and fire-and-forgets the alert. Evidence: IDEA-US-C2, verified by RenderGuardTests: MissingInclude_RendersPlaceholder_AndRaisesOneMissingAlert, DisabledInclude_RendersPlaceholder_AndRaisesOneDisabledAlert, MissingPlaceholder_LinksToAdminUpload_WithTheMissingKey.

F2.4 Themes, plugins and components — IDEA-T156 — built

  • S2.4.1 Per-page plugin selection — IDEA-T157 — built As an Operator, I pick the Plugins active on a page from a checkbox list in Page Properties, or let the page inherit the site's plugins.default; an explicitly empty selection means none. Evidence: IDEA-US-H1, verified by EffectivePluginsTests: NoSelection_InheritsTheSiteDefaults, ExplicitEmptySelection_MeansNoPlugins, OwnSelection_Wins; ContentLifecycleServiceTests.ActivePluginsJson_VersionedPin_BlocksDeletion.
  • S2.4.2 Inline plugin activation — IDEA-T158 — built As an Author, I can place <Plugin.Tooltip /> inline in a page body to activate a Plugin on that page without going through the Admin selection. Evidence: IDEA-US-H2, verified by RenderGuardTests.Parse_DottedTag_CollectedWithCorrectKind, PageAssetsTests.CompiledPlugin_AllAssetsOf_HarvestsViaActivator.
  • S2.4.3 Nested component content — IDEA-T159 — built As a Citizen-Dev, Components nest: a paired tag passes its inner tags to the outer component as ChildContent. Evidence: IDEA-US-H4, verified by RenderGuardTests.Expander_NestedPascalTags_OuterReceivesInnerAsChildContent.
  • S2.4.4 Library of 53 packages — IDEA-T160 — built As a Citizen-Dev, the library's 53 .ideas are Themes (7), Plugins (15) and Components (31), each packing clean, and a retired category is a hard validation error. Evidence: IDEA-US-H5, verified by ShippedContentValidationTests.EveryShippedPackage_PassesCitizenValidation, ManifestValidatorTests.RetiredCategory_IsHardError.
  • S2.4.5 Plugin render slots — IDEA-T161 — built As a Citizen-Dev, a Plugin declares whether it renders before or after the body, and author order is kept within each slot. Evidence: IDEA-US-H6, verified by PluginSlotTests.
  • S2.4.6 Components list child pages — IDEA-T162 — built As a Citizen-Dev, a component can list another page's children (scoped to the site) and read their metadata in one query. Evidence: IDEA-US-H7, verified by PageTreeFeatureTests: ChildrenOf_PopulatesPageId_SoMetadataCanBeJoined, ChildrenOfSlug_ScopedToSite_ReturnsOnlyThatSitesChildren, ChildrenOfSlug_UnknownSite_FallsBackToTheUnscopedLookup, IPageTree_DefaultOverload_DelegatesToTheSlugOnlyForm; ComponentMetadataServiceTests.

E3. Media, portability and sites — IDEA-T163 — built

Managed media, idealist export and import between environments, and one deployment serving several domains.

F3.1 Media storage — IDEA-T164 — built

The Azure Blob provider (S3.1.1, S3.1.2) stays in code through MindAttic.Storage.Azure but has no live account since 2026-11-26; local disk is the store in use.

  • S3.1.1 Pluggable media provider — IDEA-T165 — built As an Operator, I can point the CMS at Azure Blob Storage by setting Media:Provider=azure (plus Media:Azure:ConnectionString or BlobServiceUri), and every page keeps working untouched, because /_media/{uid} is the contract. An unknown provider or Azure without credentials fails at startup. Evidence: IDEA-US-I1, verified by MediaProviderSetupTests.NoConfiguration_KeepsTheLocalDiskStore, ProviderAzure_ReplacesTheStoreAndRegistersASigner, ProviderAzure_CarriesSignedUrlLifetimeThroughToTheEndpointOptions, ProviderAzure_WithoutCredentials_FailsClosed, UnknownProvider_FailsClosed.
  • S3.1.2 Ranged video delivery — IDEA-T166 — built As a Visitor, I can scrub through a video on a page, because /_media/{uid} 302s to a short-lived SAS URL and Azure serves the Range requests directly. Evidence: IDEA-US-I2, verified by MediaEndpointTests.RedirectsToASignedUrlWhenASignerIsRegistered, FallsBackToStreamingWhenTheSignerDeclines; AzureBlobMediaStoreIntegrationTests.SignedUrlServesTheBytesAndHonoursRangeRequests, SignedUrlExpires, PublicReadModeHandsOutThePlainUrlRebasedOnTheCdnOrigin.
  • S3.1.3 Streamed large uploads — IDEA-T167 — built As an Operator, I can upload a file far larger than memory without the app buffering it. Evidence: IDEA-US-I3, verified by LocalDiskMediaStoreTests.Upload_OverThreshold_SpillsToDiskWithIntactBytesAndHash, Upload_AtExactlyThreshold_StaysInline, ThresholdSpillStreamTests.SpillsOnceAndPreservesEveryByteInOrder, CopyAndHashMatchesAOneShotHashOverTheSameBytes, AzureBlobMediaStoreIntegrationTests.LargePayloadStreamsUpAndBackWithItsHashIntact.
  • S3.1.4 Cached asset delivery — IDEA-T168 — built As a Visitor, a repeat request for an unchanged asset costs no bytes, and a non-inline asset downloads under its real filename. Evidence: IDEA-US-I4, verified by MediaEndpointTests.ServesInlinePayloadWithEtagAndRangeSupport, RepeatRequestWithMatchingEtagIsNotModified, ServesAByteRangeOutOfALargeSpilledPayload, NonInlineTypeIsServedAsAnAttachment, UnknownUidIs404, DeletedItemIs404.
  • S3.1.5 Media upload from CLI — IDEA-T169 — built As an Operator, I can get a video into the CMS from the command line with --upload-media <file…> [--folder site] [--media-type video] [--dry-run]. Evidence: IDEA-US-I5, verified by UploadMediaCliTests.UploadsAVideoWithTheRightContentTypeAndMediaType, UploadsEveryFileUpToTheNextFlag, DryRunUploadsNothing, MissingFileFailsBeforeUploadingAnything, NoFilesIsAnError, UnknownExtensionFallsBackToOctetStream.
  • S3.1.6 Inline base64 extraction — IDEA-T170 — built As an Operator, --extract-media lifts inline base64 images out of page bodies and stylesheets into managed assets, deduplicated by content, leaving undecodable data inline and reported. Evidence: IDEA-US-I7, verified by ExtractMediaCliTests.

F3.2 Content portability — IDEA-T171 — built

  • S3.2.1 Idealist site export — IDEA-T172 — built As a Maintainer, I can move an authored site between environments, because --export-idealist writes pages, settings, per-component metadata and media into one .idealist and --import-idealist applies it. Evidence: IDEA-US-K1, verified by IdeaListTests.RoundTrip_PreservesTheAuthoredPage, SlugFilter_ExportsOnlyTheMatchingSubtree, PageTree_SurvivesOnParentUid, DryRunImport_WritesNothing.
  • S3.2.2 Import adopts seeded pages — IDEA-T173 — built As an Operator, importing into an independently seeded database adopts its pages instead of colliding with them, and importing into another site copies rather than moves. Evidence: IDEA-US-K2, verified by IdeaListTests.ImportAdoptsAnIndependentlySeededPage_BySlug_RatherThanDuplicatingIt, SecondImportUploadsNothingAndCreatesNothing, IntoSite_CopiesThePagesRatherThanMovingThemOffTheSiteThatHasThem.
  • S3.2.3 Media uids remapped on import — IDEA-T174 — built As an Author, every media reference still resolves after the move, because import rewrites media uids through an old→new map. Evidence: IDEA-US-K3, verified by IdeaListTests.MediaUidsAreRemapped_SoEveryReferenceStillResolves.
  • S3.2.4 Import cannot grant trust — IDEA-T175 — built As an Operator, an idealist cannot silently grant itself raw-markup trust: the import states how many pages carry Author trust and --untrusted downgrades them. Evidence: IDEA-US-K4, verified by IdeaListTests.UntrustedFlag_DowngradesAuthorTrust, AnIdeaListFromAFutureFormat_IsRefusedRatherThanPartiallyApplied, NotAnIdeaList_IsReportedRatherThanThrowing.
  • S3.2.5 Packages install before content — IDEA-T176 — built As an Operator, an idealist's Packages install in order before any content, and an unmet page Uses[] fails the whole apply with nothing written. Evidence: IDEA-US-K5, verified by IdeaListTests.Packages_InstallInListedOrder_LaterEntryCanRequireAnEarlierOne, PackagesFailure_AbortsBeforeAnyPageIsWritten, PageUsesUnmet_FailsLoudly_NoPartialApply, PackageResolver_SearchesMultipleDirectoriesInOrder_FirstMatchWins, ComposeIdealist_PackagesOnly_ProducesAnEmptySiteContentFreeArtifact.
  • S3.2.6 Startup library or idealist — IDEA-T177 — built As an Operator, a deployment with no idealist configured installs the whole library, and one with an idealist applies it and refuses to start if it fails. Evidence: IDEA-US-K6, verified by BootProvisioningTests.

F3.3 Multi-domain sites — IDEA-T178 — built

  • S3.3.1 Several domains, one deployment — IDEA-T179 — built As an Operator, one Ideas deployment can serve several domains, because ISiteResolver matches the request host against each site's HostBindings. Evidence: IDEA-US-L1, verified by SiteResolutionTests — hostname/port/wildcard/catch-all matching, precedence, IPv6 literals, stable tie-breaking.
  • S3.3.2 Single-site deployments unaffected — IDEA-T180 — built As an Operator, an existing single-site deployment is unaffected, because a site with no bindings still answers every hostname it is the default for. Evidence: IDEA-US-L2, verified by SiteResolutionTests.TheExistingSingleSiteInstallIsUnaffected, AnUnboundHostFallsBackToTheDefaultSite.
  • S3.3.3 Right site after interactivity — IDEA-T181 — built As a Visitor, the right site keeps answering after the page goes interactive, because the host is read from NavigationManager.BaseUri. Evidence: IDEA-US-L3, verified by SiteResolutionTests.PageHostReadsTheRequestHostFromNavigationManager_NotHttpContext.
  • S3.3.4 Bind domains in Admin — IDEA-T182 — built As an Admin, I can add and bind a domain without touching SQL in Admin → Sites. Evidence: IDEA-US-L4, verified by SiteResolutionTests.CreatingASite_NormalizesItsBindings_AndDoesNotStealDefault, TwoSitesCannotClaimTheSameHostname, TheDefaultSiteCannotBeDeleted_AndNeitherCanOneThatStillHasPages, MakeDefault_LeavesExactlyOneDefault, TheResolverAndTheAdminProbeAgree.
  • S3.3.5 One site per idealist — IDEA-T183 — built As a Maintainer, an idealist carries exactly one site and import creates that site by key rather than dumping onto the default. Evidence: IDEA-US-L5, verified by IdeaListTests.ExportCarriesOneSite_AndImportCreatesThatSiteRatherThanDumpingOntoTheDefault, ExportTakesOnlyTheNamedSitesPages, ExportWithAnUnknownSiteKey_FailsRatherThanExportingTheWrongSite.

E4. Admin, sign-in and tooling — IDEA-T184 — built

The admin panels, the ma-idea CLI, Monaco authoring, sign-in with password reset, and a clean supply chain.

F4.1 Admin and CLI — IDEA-T185 — built

  • S4.1.1 ma-idea package CLI — IDEA-T186 — built As an Operator, the ma-idea CLI can pack / inspect / list / install / verify / sign / nupkg. Evidence: IDEA-US-F1, verified by CLI in src/MindAttic.Ideas.Sdk; pack/validate/sign paths covered by PackerTests, ManifestValidatorTests, PackageSignerTests, ArgParserTests.
  • S4.1.2 Content admin and inbox triage — IDEA-T187 — built As an Operator, the Admin can enable/disable/guarded-delete content definitions and triage the Admin Inbox under the Admin policy. Evidence: IDEA-US-F2, verified by AdminServiceContractTests, UsersAdminContractTests, IdeasClaimsAugmentorTests.
  • S4.1.3 Theme, palette and package panels — IDEA-T188 — built As an Author, I have a theme picker, a component palette, an Assets panel and a Packages panel (installed blobs with content hash and admin-protected download); roles are managed at /users. Evidence: IDEA-US-F3, verified by AdminAssignmentTests: PluginToken_PinnedVersion_ParsesBack, ThemeToken_PinnedVersion_ParsesBack, CatalogFilter_Theme_ReturnsOnlyThemes, CatalogFilter_Plugin_ReturnsOnlyPlugins; PackageRegistryServiceTests.
  • S4.1.4 Packed idea renders end to end — IDEA-T189 — built As a Visitor, a real packed .idea renders end-to-end through the running host. Evidence: IDEA-US-F5, verified by RenderPipelineTests: Install_ThenReload_ThenExpand_ProducesResolvedFrame, Install_ThenExpand_UnknownToken_ProducesMissingFrame; live renders serve /_ideas/... mounts with zero placeholders.
  • S4.1.5 Compiled citizen assets harvested — IDEA-T190 — built As a Citizen-Dev, a compiled citizen's declared StylesheetUrls/ScriptUrls are harvested into <head> through the same PageAssetCollector path as package citizens. Evidence: IDEA-US-F6, verified by PageAssetsTests: CompiledPlugin_AllAssetsOf_HarvestsViaActivator, CompiledPlugin_UnresolvableType_ReturnsEmpty, PackagePlugin_AllAssetsOf_DelegatesToMountedManifestAssets.
  • S4.1.6 Official content as pages — IDEA-T191 — built As an Operator, official content lives in the first-party library and standalone frontends collapse into Pages: mindattic.com is the frontpage Data page and Legion.Frontend is the personas page, whose body is one <Component.LegionPersonas /> tag. Evidence: IDEA-US-F7, verified by SeededPageRenderTests.Seed_CreatesPersonasPage_CollapsingLegionFrontendIntoOneToken; /personas and /frontpage render live with zero placeholders.
  • S4.1.7 Monaco editor with completion — IDEA-T192 — built As an Author, I edit pages with Monaco and catalog-driven completion of citizen tags; tag attributes bind to typed [Parameter]s. Evidence: IDEA-US-F8, verified by MonacoEditorTokenTests: IntelliSenseTag_ParsesBackViaIncludeReferenceParser, IntelliSenseTag_InsertedInBody_ParsedByIncludeReferenceParser; IncludeAttributeCoercionTests (incl. Expand_TagAttributes_BindTyped_AndLeaveUnmatchedRaw); live Monaco interaction is browser-tested.
  • S4.1.8 Save-time authoring warnings — IDEA-T193 — built As an Author, saving a page tells me about unresolved tags, undeclared attributes, badly typed values and anything the sanitizer would strip; a library citizen with unsafe JS/CSS or malformed settings cannot be packed; CI checks every shipped package and seed page. Evidence: IDEA-US-F9, verified by PageMarkupValidatorTests, CitizenValidatorTests, ShippedContentValidationTests.EveryShippedPackage_PassesCitizenValidation, ShippedContentValidationTests.EverySeedPage_ValidatesAgainstTheShippedPackages.
  • S4.1.9 Package asset mount URLs — IDEA-T194 — built As a Citizen-Dev, a package that hard-codes its own asset URLs (Cyberspace's circuitboard textures) uses the mount the host serves it under, /_ideas/{Category}/{key}/{version}, and every file it names is in its assets; a stale category such as the retired Widget fails CI. Evidence: IDEA-US-F11, verified by ShippedContentValidationTests.EveryShippedPackage_SelfReferencingAssetUrls_MatchItsMountAndExist, EveryLibrarySource_SelfReferencingAssetUrls_MatchItsMountAndExist, SelfReferencingAssetUrlCheck_FlagsAWrongCategory.

F4.2 Sign-in and accounts — IDEA-T195 — built

  • S4.2.1 Sign in with Authentication — IDEA-T196 — built As an Operator, I sign in via MindAttic.Authentication; the Admin role carries the Cms.AuthorRawMarkup claim. Evidence: IDEA-US-F4, verified by IdeasClaimsAugmentorTests, CmsDbContextAuthModelTests; see HOUSE-LAW-7.
  • S4.2.2 Forgot password by email — IDEA-T197 — built As a user who forgot my password, I follow "Forgot password?" on /login, get an emailed link to this site's /account/reset page (absolute, from MindAttic:Auth:Reset:PublicBaseUrl: https://localhost:7207 in Development; the company site and the demo each set their own in infra/main.bicep), and setting a new password there replaces the old one. Mail is sent only when the Vault Notifications SMTP settings are configured. Evidence: IDEA-US-F10, verified by PasswordResetFlowTests.RequestReset_EmailsAnAbsoluteLinkToTheResetPage_WhichResetsThePassword, PasswordResetFlowTests.TheResetAndForgotPages_AreAnonymous, PasswordResetFlowTests.EachAzureSite_SetsItsOwnPublicBaseUrl.

F4.3 Build and supply chain — IDEA-T198 — built

  • S4.3.1 Vendored private packages — IDEA-T199 — built As a Maintainer, CI can restore and publish this repo without my dev box, because every private MindAttic package is vendored into lib/local-packages/ and nuget.config lists it first. Evidence: IDEA-US-J1, verified by DeploymentPackagingTests.EveryReferencedMindAtticPackageIsVendoredForCi, NugetConfigListsTheVendoredFeed, VendoredPackagesAreTrackedRatherThanGitIgnored.
  • S4.3.2 Database-free health endpoint — IDEA-T200 — built As an Operator, App Service can tell whether the site is alive, because /_health answers 200 without touching the database, as soon as the server listens, and reports whether the boot sequence has finished and which build is running. Evidence: IDEA-US-J2, verified by DeploymentPackagingTests.ProductionRequiresItsDataProtectionSettingsByName, DeployWorkflowPointsAtProjectsThatExist, StartupGateTests.HealthReportsReadinessAndBuild, StartupGateTests.BeforeReadinessOnlyHealthIsServed.
  • S4.3.3 No vulnerable dependencies — IDEA-T201 — built As a Maintainer, the engine ships with no known-vulnerable dependency, and the security floors cannot be silently reverted. Evidence: IDEA-US-J3, verified by DeploymentPackagingTests.SecurityPinnedPackagesAreNotDowngraded.

E5. Runs locally on the platform — IDEA-T94 — MS-9

IdeaCms runs entirely on the owner's machine: installed from the shared run menu, local SQL Server, no cloud code, and docs that describe it as it is (priority 900).

F5.1 Installed like every app — IDEA-T97 — MS-9

  • S5.1.1 IdeaCms on R: — IDEA-T89 — MS-9 Task: the shared run menu deploys Debug and Release to R:\MindAttic\Apps\IdeaCms and both launch.
  • S5.1.2 IdeaCms C: cleanup — IDEA-T90 — MS-9 Task: the old C:\Apps\Ideas deploy is deleted once R: runs.

F5.2 Local data store — IDEA-T98 — MS-9

  • S5.2.1 Local SQL defaults — IDEA-T104 — MS-9 Task: CmsDbContextFactory, the host fallback and tools/*.ps1 point at local SQL Server, no az login.

F5.3 Cloud-free codebase — IDEA-T99 — MS-9

  • S5.3.1 Remove Azure leftovers — IDEA-T88 — MS-9 Task: infra/provision.ps1, infra/migrate.ps1 and the production Azure Data Protection setup are removed.

F5.4 Docs describe the local app — IDEA-T102 — MS-9

  • S5.4.1 Overview matches the code — IDEA-T20 — MS-9 Task: docs/overview.md (the former README) describes the local app, setup, usage and commands as they are now.

F5.5 Deployment docs current — IDEA-T103 — MS-9

  • S5.5.1 Local deployment docs — IDEA-T105 — MS-9 Task: DEPLOYMENT.md, DEV_LOGIN.md and the BIBLE describe the R: deploy and local SQL, Azure marked retired.

E6. Pages render correctly and safely — IDEA-T95 — MS-9

Every public page renders as designed and refuses unsafe links (priority 800).

F6.1 Public pages render correctly — IDEA-T100 — MS-9

  • S6.1.1 Login page styling — IDEA-T38 — MS-9 Task: /login picks up the site fonts and styles.
  • S6.1.2 Frontpage observer error — IDEA-T49 — MS-9 Task: the frontpage IntersectionObserver rootMargin uses px, so the page loads without an error.
  • S6.2.1 Obfuscated script schemes — IDEA-T7 — MS-9 Task: IsUnsafeUrl strips control characters before its scheme check, with NUnit tests.

E8. Authoring complete — IDEA-T202 — MS-140

Authors theme, compose and add media to any page without code, on themes proven accessible; then 1.1 is polished and released. Starts after E5 and E6 (requires IDEA-T94, IDEA-T95).

F8.1 Proven accessible themes — IDEA-T203 — MS-140

  • S8.1.1 Automated theme contrast test — IDEA-T204 — MS-140 As a Maintainer, I want an automated WCAG contrast test over every library theme in light and dark mode, so that no theme change can quietly drop below AA. Acceptance:
    • Given every theme and mode, when the test computes relative luminance for text, muted, link and button pairs, then every pair meets AA (4.5:1 for text, 3:1 for large text and UI).
    • Given a palette change that breaks a pair, when the test runs, then it fails naming the theme, mode and pair.

F8.2 Inline theme override — IDEA-T205 — MS-140

  • S8.2.1 Inline theme tag override — IDEA-T206 — MS-140 As an Author, I can place <Theme.Cyberspace /> inline in a page body to override the page's Theme for that render without changing the Page Properties selection. Acceptance:
    • Given a page whose Properties theme is A and whose body holds <Theme.B />, when it renders, then theme B applies and Page Properties still says A.
    • Given an unknown or disabled theme tag, when the page renders, then it degrades like any bad reference and the page theme applies.

F8.3 Composable brochure page — IDEA-T207 — MS-140

  • S8.3.1 Brochure as data page — IDEA-T208 — MS-140 As a reader, /ideas is a Data page composed of discrete components rather than one compiled Component.IdeasBrochure, so the brochure can be edited without a redeploy. Acceptance:
    • Given the seeded site, when a visitor opens /ideas, then it renders from a Data page of discrete library components and looks as it does today.
    • Given an author edits a section of /ideas in the admin, when they save, then the change shows without a redeploy.

F8.4 Paste-to-asset media — IDEA-T209 — MS-140

  • S8.4.1 Paste images as assets — IDEA-T210 — MS-140 As an Author, I can hand the CMS pixels instead of a file path — paste a base64 image (or a clipboard capture) and have it become a stored asset with a /_media/{uid} URL, so base64 never reaches a page. Lands in MindAttic.Media, surfaced through the host CLI and the Admin Media panel. Lowest priority. Acceptance:
    • Given an author pastes a clipboard image in the Admin Media panel or page editor, when it is saved, then it is stored as an asset and the page gets a /_media/{uid} URL.
    • Given the host CLI receives base64 image data, when it imports it, then the same asset path is used and duplicates are deduplicated by content.

F8.5 Polish and release 1.1 — IDEA-T211 — MS-140

  • S8.5.1 IdeaCms 1.1 release — IDEA-T212 — MS-140 As the owner, I want IdeaCms 1.1 polished, documented and deployed, so that the finished CMS is what I run every day. Acceptance:
    • Given every 1.1 story is closed, when Release is deployed from the run menu, then it starts from R:\MindAttic\Apps\IdeaCms\Release against local SQL.
    • Given the docs, when read, then overview, BIBLE, SPEC and USER_STORIES describe 1.1 with no stale statement.
    • Given the owner runs the 1.1 flows, when satisfied, then they sign off the milestone.

Added by MAT-T477 (owner stories and cross-repo links)

  • T IDEA-T213 Drop MindAttic.Storage.Azure (feature IDEA-T99 Cloud-free codebase, MS-9): IdeaCms stores files on local disk through MindAttic.Storage; MindAttic.Storage's M.MDIA-T52 requires it.

5. Non-functional requirements

  • Platform: .NET 10, Blazor Server (Static or InteractiveServer for uploaded types), Windows, local SQL Server.
  • Safety: every page body is sanitized at every trust level; only packages signed by the host-trusted certificate install; a render never throws on a bad reference.
  • Data: temporal history on pages and instance settings; soft delete; reference-guarded version delete.
  • Secrets: keys and settings through MindAttic.Vault; none in the repo (placeholders only).
  • Dependencies: private MindAttic packages vendored in lib/local-packages; no known-vulnerable dependency.

6. Interfaces and dependencies

  • Platform owners (docs/ECOSYSTEM.md): credentials and settings — MindAttic.Vault; sign-in and reset — MindAttic.Authentication; files and media — MindAttic.Storage; logging — MindAttic.Log; shipping — the shared run menu.
  • Uses: MindAttic.Authentication (sign-in, reset), MindAttic.Vault (settings and keys), MindAttic.Storage and MindAttic.Storage.Azure (media), MindAttic.Log (logging), the shared run menu in MindAttic.Agency (deploy to R:).
  • Used by: nothing in the workspace consumes IdeaCms as a library; its .idea packages and the ma-idea CLI are its contract for package authors.

7. Release sequence

  1. MS-9 IdeaCms local 1.0 (active, docs/RELEASE.md): E5 runs locally on the platform, E6 pages render correctly and safely.
  2. MS-140 IdeaCms 1.1: authoring complete (planned): E8, ending with F8.5 polish and release. Reaching it finishes the product.

8. Change log

Date Change to scope Ticket
2026-11-30 Specification written from the BIBLE, USER_STORIES, RELEASE charter, code and ticket history; the four open USER_STORIES items became MS-140; Azure hosting stories moved to Never MAT-T384
2026-11-30 MAT-T462 single-source pass: 10 renamed; bucket epic E7 "Docs match reality" (IDEA-T96) dissolved, its features moved into E5 as F5.4/F5.5 and closed wont-do; "Known bug fixes" reframed as "Pages render correctly and safely"; MS-140 requires MS-9 (IDEA-T202 requires IDEA-T94, IDEA-T95) MAT-T469
2026-11-30 MAT-T477 owner story for MindAttic.Storage (M.MDIA-T52) MAT-T477
Part of IdeaCms.
From IdeaCms/docs/SPEC.md via MindAttic.Docs; synced automatically, so edit the repo, not this page.