diff --git a/bun.lock b/bun.lock index b9597f5ea..25d9baffe 100644 --- a/bun.lock +++ b/bun.lock @@ -26,6 +26,7 @@ "class-variance-authority": "^0.7.1", "clsx": "^2.1.1", "cmdk": "^1.1.1", + "codemirror": "5.65.20", "drizzle-orm": "^0.45.2", "envalid": "8.2.0", "express": "^4.19.2", @@ -62,6 +63,7 @@ "@storybook/addon-docs": "10.6.3", "@storybook/react-vite": "10.6.3", "@tailwindcss/vite": "^4.3.3", + "@types/codemirror": "5.60.15", "@types/express": "^4.17.21", "@types/less": "^3.0.8", "@types/node": "^20.14.10", @@ -855,6 +857,8 @@ "@types/chai": ["@types/chai@5.2.3", "", { "dependencies": { "@types/deep-eql": "*", "assertion-error": "^2.0.1" } }, "sha512-Mw558oeA9fFbv65/y4mHtXDs9bPnFMZAL/jxdPFUpOHHIXX91mcgEHbS5Lahr+pwZFR8A7GQleRWeI6cGFC2UA=="], + "@types/codemirror": ["@types/codemirror@5.60.15", "", { "dependencies": { "@types/tern": "*" } }, "sha512-dTOvwEQ+ouKJ/rE9LT1Ue2hmP6H1mZv5+CCnNWu2qtiOe2LQa9lCprEY20HxiDmV/Bxh+dXjywmy5aKvoGjULA=="], + "@types/connect": ["@types/connect@3.4.38", "", { "dependencies": { "@types/node": "*" } }, "sha512-K6uROf1LD88uDQqJCktA4yzL1YYAK6NgfsI0v/mTgyPKWsX1CnJ0XPSDhViejru1GcRkLWb8RlzFYJRqGUbaug=="], "@types/d3": ["@types/d3@7.4.3", "", { "dependencies": { "@types/d3-array": "*", "@types/d3-axis": "*", "@types/d3-brush": "*", "@types/d3-chord": "*", "@types/d3-color": "*", "@types/d3-contour": "*", "@types/d3-delaunay": "*", "@types/d3-dispatch": "*", "@types/d3-drag": "*", "@types/d3-dsv": "*", "@types/d3-ease": "*", "@types/d3-fetch": "*", "@types/d3-force": "*", "@types/d3-format": "*", "@types/d3-geo": "*", "@types/d3-hierarchy": "*", "@types/d3-interpolate": "*", "@types/d3-path": "*", "@types/d3-polygon": "*", "@types/d3-quadtree": "*", "@types/d3-random": "*", "@types/d3-scale": "*", "@types/d3-scale-chromatic": "*", "@types/d3-selection": "*", "@types/d3-shape": "*", "@types/d3-time": "*", "@types/d3-time-format": "*", "@types/d3-timer": "*", "@types/d3-transition": "*", "@types/d3-zoom": "*" } }, "sha512-lZXZ9ckh5R8uiFVt8ogUNf+pIrK4EsWrx2Np75WvF/eTpJ0FMHNhjXk8CKEx/+gpHbNQyJWehbFaTvqmHWB3ww=="], @@ -965,6 +969,8 @@ "@types/serve-static": ["@types/serve-static@1.15.10", "", { "dependencies": { "@types/http-errors": "*", "@types/node": "*", "@types/send": "<1" } }, "sha512-tRs1dB+g8Itk72rlSI2ZrW6vZg0YrLI81iQSTkMmOqnqCaNr/8Ek4VwWcN5vZgCYWbg/JJSGBlUaYGAOP73qBw=="], + "@types/tern": ["@types/tern@0.23.9", "", { "dependencies": { "@types/estree": "*" } }, "sha512-ypzHFE/wBzh+BlH6rrBgS5I/Z7RD21pGhZ2rltb/+ZrVM1awdZwjx7hE5XfuYgHWk9uvV5HLZN3SloevCAp3Bw=="], + "@types/trusted-types": ["@types/trusted-types@2.0.7", "", {}, "sha512-ScaPdn1dQczgbl0QFTeTOmVHFULt394XJgOQNoyVhZ6r2vLnMLJfBPd53SB52T/3G36VI1/g2MZaX0cwDuXsfw=="], "@types/validate-npm-package-name": ["@types/validate-npm-package-name@4.0.2", "", {}, "sha512-lrpDziQipxCEeK5kWxvljWYhUvOiB2A9izZd9B2AFarYAkqZshb4lPbRs7zKEic6eGtH8V/2qJW+dPp9OtF6bw=="], @@ -1131,6 +1137,8 @@ "code-block-writer": ["code-block-writer@13.0.3", "", {}, "sha512-Oofo0pq3IKnsFtuHqSF7TqBfr71aeyZDVJ0HpmqB7FBM2qEigL0iPONSCZSO9pE9dZTAxANe5XHG9Uy0YMv8cg=="], + "codemirror": ["codemirror@5.65.20", "", {}, "sha512-i5dLDDxwkFCbhjvL2pNjShsojoL3XHyDwsGv1jqETUoW+lzpBKKqNTUWgQwVAOa0tUm4BwekT455ujafi8payA=="], + "color": ["color@4.2.3", "", { "dependencies": { "color-convert": "^2.0.1", "color-string": "^1.9.0" } }, "sha512-1rXeuUUiGGrykh+CeBdu5Ie7OJwinCgQY0bc7GCRxy5xVHy+moaqkpL/jqQq0MtQOeYcrqEz4abc5f0KtU7W4A=="], "color-convert": ["color-convert@2.0.1", "", { "dependencies": { "color-name": "~1.1.4" } }, "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ=="], diff --git a/docs/launch/README.md b/docs/launch/README.md index 986398bc3..110fa0ce0 100644 --- a/docs/launch/README.md +++ b/docs/launch/README.md @@ -1,80 +1,25 @@ -# Desktop app: commercial release plan +# Desktop app release plan -Status: **preparation; not ready for sale or distribution**. Updated 2026-11-11. +Status: **preparation; no updated listing submission or release is verified.** Updated 2026-11-18. -The working tracker is [launch epic #26](https://github.com/ZenUml/doop/issues/26), with active execution issues #17–25. Issue #16 is closed as an owner decision: Apple In-App Purchase through the Mac App Store is the selected channel. That decision does not resolve the separate AGPL/source/notices review required before distribution. +## Product and commercial decision -The owner approved a gradual transition from ZenUML to the **Diagramly** brand and reuse of the existing Mac App Store app record, app ID `1602636196`, bundle ID `com.zenuml.app`. No public listing metadata has been changed and no new app record has been created. Apple In-App Purchase through the Mac App Store remains the selected channel. No live product or purchase is verified, and no final signed Mac App Store build has been produced. +Update the existing paid ZenUML Mac App Store app (`com.zenuml.app`, record ID `1602636196`) and introduce Diagramly branding gradually. Keep the current app record, paid-app model and price. No price change, subscription, in-app purchase, or Diagramly cloud-AI offer is part of this v1. A current public iTunes lookup confirms the US price is $29.99 USD; the Australia price remains unverified. Check App Store Connect before publishing price details. -## Product direction +The proposed v1 focuses on local editing: source editing with live preview, opening a board diagram in its own editor by double-click, Pages tabs within each diagram, ZenUML and Mermaid, import of an older ZenUML JSON library, and a customer-provided MCP client. Customers provide and configure their MCP client and any related AI provider account. Do not promise cloud AI, cloud sync, purchase restore, or unverified export formats. -The owner selected **Diagramly** as the product brand, with a gradual transition from the existing ZenUML listing. The existing app record and bundle identity remain the update path; do not create a second listing or change customer-facing store metadata until the migration and paid-customer rights plan is reviewed. The candidate icon is still a design asset, not a confirmed shipping icon. +## Current evidence -The planned local product is for developers and technical teams who need editable Mermaid and ZenUML diagrams, a document/page library, and a way to work with their own AI agent. Its first useful jobs are to create and revise diagrams, import an older ZenUML library, and connect a compatible external MCP client. The external client uses its own AI account, model access and billing. Desktop sign-in, MCP authorization and Apple purchases are separate identities; people must authorize the expected Diagramly account where the client requests it. +`origin/main` is `8011907`, including PR #32 (`079a82a`) and PR #34's development signing fix. The focused editor and Pages implementation through `74eb200` is integrated locally on `codex/release-integration-local-20261118`; it is not in `origin/main` or a released candidate. Verify the exact candidate before treating this copy as shipping behavior. -The desktop MCP service is intended to bind to loopback on the same Mac. It is not a network-wide MCP service. Local documents do not silently become cloud documents. Paid Diagramly cloud services remain unavailable until account access, server-side entitlements, metering and Apple purchases work together. +A public iTunes lookup reports the existing listing as “Sequence Diagram Tool | ZenUML”, version 1.0.7, $29.99 USD in the US storefront, seller Peng Xiao. The `/desktop` URL returned 404. `/desktop/support` returned HTTP 200; its content was checked for legacy import steps and the 10 MB limit, renderer-error troubleshooting, external agent/provider billing, and a support email. The distribution certificate is available, but App Store Connect login is incomplete, so the latest build and submission history remain unchecked. No listing change or submission is recorded here. Read [execution status](execution-status.md) for the candidate gates and [pricing](pricing.md) for the pricing decision. -The import path supports the legacy ZenUML JSON library export and a reviewed recovery copy of the old Chromium library. See [legacy upgrade and local rights](legacy-upgrade.md). It is an explicit import, not an account or workspace merge. The earlier Doop Desktop preview uses a separate app container; Diagramly does not automatically copy its data. Keep the old app and its data until an explicit export/import has been checked. Portable backups omit version history, comments and external image files; keep those separately. Before any new subscription gate is enabled, define and verify how existing purchasers retain the primary functionality they paid for. Apple Guideline 3.1.2(a) says an app changing to a subscription model must not remove primary functionality existing users already paid for. +## Release gates -## Commercial decisions and current evidence +- Confirm App Store Connect record, seller, current availability and current US/AU prices; preserve the existing price. +- Integrate and verify the focused source editor, live preview, board double-click behavior and Pages tabs on the release candidate. +- Verify ZenUML and Mermaid editing, legacy ZenUML JSON import, save/reopen, and the customer-provided MCP flow on the exact signed Mac App Store build. +- Verify bundle identity, signing, provisioning, privacy disclosures, support details, third-party notices, and App Review materials. +- Capture screenshots from the candidate and remove claims that do not pass acceptance. Do not publish a listing or claim submission until it is actually done. -| Area | Decision or intended behavior | Current evidence and remaining work | -| --------------- | ----------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| Desktop payment | Apple In-App Purchase through StoreKit; selected in closed issue #16 | Paid Apps Agreement was accepted and verified active on 2026-11-10. Native StoreKit bridge and purchase UI are implemented. No live products are configured; simulator verification returned StoreKit error code 3. | -| Distribution | Reuse the existing Mac App Store record `1602636196` (`com.zenuml.app`); Apple supplies updates | The dedicated profile retains `com.zenuml.app`, ZenUML 1.1.0 build 41. Final sandbox acceptance, fresh Apple signing and submission eligibility remain pending. No listing metadata has changed. | -| Local core | Local Mermaid/ZenUML editing, import, save/restore and external MCP | Product-profile UI/API and backup code are in progress and have focused test evidence. Clean-machine and final signed sandbox acceptance remain. | -| Paid offer | One Pro tier with monthly and annual options | $9.99 monthly and $99.99 annual are planning targets only. No price is shown here as live; verify StoreKit price points, costs, entitlements and products before sale. See [pricing](pricing.md). | -| Identity | Apple purchase identity and Diagramly sign-in are separate | Connection and purchase-context API work exists in a separate backend branch and remains default-off; integration and live verification are pending. See [Apple payments](apple-payments.md). | -| Name and icon | Diagramly brand, introduced gradually on the existing ZenUML listing | Brand direction is approved. The existing listing remains unchanged until the paid-customer rights and migration plan is verified. The candidate icon is not yet approved for the shipping build. | -| Public support | `/desktop` and `/desktop/support` explain the pre-launch offer and migration boundaries | Pages are committed locally in branch `codex/desktop-marketing` (`bd17c5ee6`); they are not deployed. There is no published Desktop response-time promise. | - -Product copy uses Document → Page → Diagram as interface vocabulary. Keep storage and protocol names compatible; see [terminology issue #15](https://github.com/ZenUml/doop/issues/15). - -## Issue #16 decision and continuing licence work - -Issue #16 is closed because the owner selected the Mac App Store and Apple In-App Purchase. This closes the channel-choice question only. The root AGPL licence, modified-source publication obligations, third-party notices, and compatibility of the chosen channel still require a qualified release review. Do not assume that attaching the upstream repository satisfies source obligations, that an App Store EULA resolves compatibility, or that the remote Diagramly service shares the app's licence boundary. Preserve `LICENSE` and all third-party notices throughout packaging and review. - -## Evidence and release gates - -The current evidence and open dependencies are recorded in [execution-status.md](execution-status.md). The local release audit is [audit-release.mjs](audit-release.mjs). It reads the dedicated App Store profile rather than treating the upstream Doop template config as the selected product profile: - -```sh -node docs/launch/audit-release.mjs \ - --bundle "/absolute/path/to/ZenUML.app" \ - --output /tmp/diagramly-release-audit.json -``` - -Replace the example path with the exact packaged update. Earlier preview artifacts use a separate identifier and are not release candidates. An audit without a new candidate remains blocked. `current-readiness.json` is a prior snapshot and must not be treated as evidence for the final bundle; refresh it only after the exact final candidate has been built. - -The audit checks configuration and bundle facts. Static profile or source-file presence does not prove StoreKit behavior, server verification, sandbox compliance, App Review acceptance, or release readiness. Exit 2 means a known blocker; exit 0 means further human and end-to-end review is still required. `releaseReady` remains false. - -The App Store profile retains product name `ZenUML`, identifier `com.zenuml.app`, version 1.1.0 build 41, no self-updater and an Apple-delivered update policy. Diagramly branding is introduced gradually within this existing update path. The base Tauri config intentionally remains the upstream Doop profile for other builds. The local bundle path uses the dedicated candidate profile and `app-store` Cargo feature. - -Current release gates include: - -- source/licence/notices and distribution-channel review; -- final production profile build, signing, provisioning and bundle verification; -- StoreKit product configuration, live purchase/restore/manage testing, and server-side signed transaction verification; -- confirmation and implementation of existing paid customers' access to the primary functionality they purchased before any subscription gate is enabled; -- completion and review of the default-off Diagramly connection/entitlement integration; -- privacy and local-security review, including loopback MCP and generated content; -- clean-machine install, migration, backup/restore, account switching and failure acceptance; -- public support/listing publication and App Store review materials. - -The bundle-allocation measurement of 1,187 MiB included development dependencies. It is not the signed download size or a reclaimable-space estimate. - -## Delivery order - -1. Complete source/licence/notices review and confirm the shipping capability set. Keep legacy data and the current app usable. -2. Finish the dedicated production build, identity/container migration and local-data recovery checks. -3. Complete account-bound StoreKit delivery, server verification, restore, notifications, product configuration and real sandbox acceptance. Confirm service costs before publishing an allowance or price. -4. Run clean-install, upgrade, offline-start, account-switch, MCP, import, backup/restore and purchase-failure acceptance on the exact signed build. -5. Deploy reviewed `/desktop` and `/desktop/support` content; finish App Store metadata, privacy disclosures, review instructions and private beta. Submit only the reviewed candidate after all gates pass. - -## Ownership and operating evidence - -Prepare reviewable work before any necessary account-holder action. Keep credentials, private account details, banking/tax details, signing secrets and customer data out of this directory. Do not accept legal contracts, alter bank/tax settings, spend money, contact customers, upload a build or publish a release without the required authorization. - -Measure first diagrams saved and reopened, successful source edits, visible MCP edits, imported pages remaining editable, retained weekly editors, verified purchases, refunds and net proceeds after usage costs. App opens, button clicks, a token in storage and gross sales do not establish those outcomes. - -See [Apple payments](apple-payments.md), [pricing](pricing.md), [listing and screenshots](listing.md), [operations](operations.md), [support playbook](support-playbook.md), [launch issues](issues.json) and [execution status](execution-status.md). +`current-readiness.json` is a prior snapshot. Keep release readiness false until the exact signed candidate passes the audit and human acceptance. See [listing and screenshots](listing.md), [support playbook](support-playbook.md), and [release issues](issues.json). diff --git a/docs/launch/execution-status.md b/docs/launch/execution-status.md index b329b0bfb..bf9429ceb 100644 --- a/docs/launch/execution-status.md +++ b/docs/launch/execution-status.md @@ -1,19 +1,21 @@ # Desktop app execution status -Updated 2026-11-17. **Not yet ready for App Store submission.** +Updated 2026-11-18. **Draft only; App Store submission has not been verified.** -## Desktop candidate +## Product and listing -- PR #32 prepares the existing ZenUML app (`com.zenuml.app`) for the Diagramly transition. It includes the renamed Claude extension, local MCP connection, title persistence and desktop workflow fixes. The PR has not yet been merged. -- The full JavaScript test run passed 3,071 tests with 19 skipped on commit `27025de`; later port and workflow changes have focused checks. The renamed extension was installed in Claude Desktop and used to read and edit an isolated test diagram, which was reopened in the desktop app. -- A sandboxed debug build showed the port-conflict message and restarted on its saved port once the conflict was removed. This does not verify automatic port discovery or a signed App Store build. -- Existing legacy diagrams have been imported and edited in an isolated build, including a synthetic diagram with two pages. A final candidate still needs a practical upgrade/import check. +- The release direction is to update the existing paid ZenUML Mac App Store app, bundle ID `com.zenuml.app` (record ID `1602636196`), and introduce Diagramly branding gradually. No new listing or price change is authorized. +- `origin/main` is at `8011907` and includes the merge of PR #32 (`079a82a`) and the local StoreKit development-signing change in #34. These commits do not establish that a candidate was uploaded or submitted. +- A current public iTunes lookup reports the existing US listing as “Sequence Diagram Tool | ZenUML”, version 1.0.7, priced at $29.99 USD, with seller Peng Xiao. The Australia price is unverified. The `/desktop` marketing URL returned 404. `/desktop/support` returned HTTP 200; its content was checked for legacy import steps and the 10 MB limit, renderer-error troubleshooting, external agent/provider billing, and a support email. App Store Connect submission and build history remain unverified because login is incomplete. +- The proposed v1 is local diagram editing with a source editor and live preview; opening a board diagram in its own editor by double-click; per-diagram Pages tabs; ZenUML and Mermaid; importing an older ZenUML JSON library; and connecting an MCP client the customer provides and configures. +- The focused editor and Pages implementation through `74eb200` is integrated locally on `codex/release-integration-local-20261118`, but remains outside `origin/main` and has not been verified on a released candidate. Treat the listing as proposed copy until the exact release build is checked. +- Do not describe Diagramly cloud AI, a Diagramly subscription, in-app purchases, cloud sync, or purchase restore as part of this v1. Do not claim unverified export formats. -## Payments and release +## Release state to verify -- Apple In-App Purchase remains the desktop payment channel. The native purchase bridge exists; real Apple Sandbox purchase, restore and renewal have not been verified. -- Backend Apple entitlement integration is on a separate branch. Its isolated database tests passed, while CI and production integration remain open. Do not enable the Apple gate or claim production readiness based on local tests alone. -- An unsigned macOS review bundle exists; the final source revision has not been signed or uploaded. The current local keychain lacks the required Mac App Store distribution identities. Confirm the App Store Connect product, provisioning and build-number state before packaging. -- Store listing, screenshots, pricing and support materials remain drafts. Confirm claims against the actual release candidate and complete the Apple review information before submission. +- Current App Store Connect listing status, app availability, seller, version/build, and current storefront prices have not been checked for this update. Keep the existing paid app and price; record the actual US and AU prices only after checking the live listing. +- No listing change or submission is recorded here. Draft metadata and screenshots still need review against the candidate. The distribution certificate is available, but App Store Connect login is incomplete; uploaded-build and submission status remain unchecked. Verify provisioning and final signing against the candidate. +- Complete a clean install and existing-app update check, source editing and preview, board double-click into the independent editor, Pages tabs, both diagram languages, legacy JSON import, customer-owned MCP connection, save/reopen, and relevant failure paths on the exact signed Mac App Store build. +- Check signing, provisioning, bundle identity, privacy disclosures, third-party notices, support contact, and review notes before submission. Keep `releaseReady` false until the exact candidate passes the release audit and human acceptance. -`docs/launch/current-readiness.json` is not updated by this snapshot. Keep `releaseReady` false until the actual release candidate is verified. +`docs/launch/current-readiness.json` is a prior snapshot, not evidence for a new candidate. Refresh it only after checking the exact build. diff --git a/docs/launch/listing.md b/docs/launch/listing.md index a332de21c..27f773598 100644 --- a/docs/launch/listing.md +++ b/docs/launch/listing.md @@ -1,34 +1,36 @@ # Store listing and creative brief -Draft only; no listing submitted. Machine-readable copy is in [store-listing.json](store-listing.json). Name, subtitle, keywords and promotional text must pass the App Store Connect limits again at upload time. Final claims must match the exact release. +Draft only; no listing change or submission is recorded. Machine-readable copy is in [store-listing.json](store-listing.json). Confirm current App Store Connect limits and verify every claim against the exact signed build before submission. -## Brand +## Brand and existing listing -Product brand direction: Diagramly, introduced gradually from the existing ZenUML listing. This draft proposes the listing name “Diagramly Desktop” and subtitle “Mermaid & ZenUML diagrams”; it has not been submitted and no current App Store metadata has changed. Reuse the existing app record and bundle ID (`1602636196`, `com.zenuml.app`). Candidate icon: [SVG master](assets/icon-v1/diagramly-desktop.svg), [size preview](assets/icon-v1/preview.png), [macOS ICNS](assets/icon-v1/icon.icns), and square PNGs from 16 through 1024 pixels. The same candidate is staged at `desktop/src-tauri/icons/` for the native package. Root Tauri identity/configuration still needs to match the existing record and validate the App Store profile; this does not install the icon into a shipping build. +Introduce Diagramly gradually through the existing paid ZenUML Mac App Store app record (`1602636196`, bundle ID `com.zenuml.app`). Keep its current price; current US and AU prices are still to be confirmed. This draft does not represent an uploaded listing or a submitted update. -The icon uses a diagram-node D in Diagramly's blue/violet/pink palette. It is an original vector candidate drawn in code; no external image-generation service was used. The source is square and full bleed; the preview applies a rounded presentation only. Regenerate outputs on macOS with `node docs/launch/assets/icon-v1/generate.mjs` (requires the repository's `sharp` dependency and Apple `iconutil`). Verify name availability, brand rights and contrast at small sizes before submission. +The candidate icon is a design asset, not a confirmed shipping icon: [SVG master](assets/icon-v1/diagramly-desktop.svg), [size preview](assets/icon-v1/preview.png), [macOS ICNS](assets/icon-v1/icon.icns). Confirm the listing name, icon and metadata against the existing record before use. -The copy in [store-listing.json](store-listing.json) describes local ZenUML and Mermaid editing, local document/page persistence, compatible MCP clients and import of the older ZenUML JSON library. It makes no cloud-AI or subscription availability claim. Validate all four workflows on the exact signed build; any unsupported or unstable workflow must be removed from the listing. +## Proposed v1 claims -## Screenshot sequence +The copy proposes a local ZenUML and Mermaid editor with source editing and live preview; double-clicking a board diagram to open it in a separate editor; Pages tabs within a diagram; import of an older ZenUML JSON library; and connection to a customer-provided MCP client. The customer supplies and configures that client and any AI provider account. Do not imply Diagramly cloud AI, subscription billing, cloud sync, or verified purchase restore. + +Do not list export formats or claim that an export workflow is available until each format is checked on the exact release build. Confirm the supported ZenUML JSON import format and handling of imported Pages on that build. -Capture actual screens from the shipping build with synthetic documents, after the agreed UI cleanup. Use current Apple size requirements from App Store Connect at upload time. Do not manufacture screenshots of unimplemented cloud features. +## Screenshot sequence -| Order | Message | Actual product evidence to capture | -| ----- | ------------------------------------------ | ------------------------------------------------------------------------------------- | -| 1 | Architecture diagrams you can keep editing | A clean, readable synthetic system diagram and editable source | -| 2 | Revise the source, see the result | A concrete before/after source edit with a visible changed message/node | -| 3 | Work with your AI agent | A real MCP edit appearing on the correct document; no private prompt, token or email | -| 4 | Bring your ZenUML library | Synthetic exported library preview, multiple pages and subsequent source edit | -| 5 | Keep your work organized | Documents/pages using the approved terminology; save/reopen evidence | -| 6 | Optional cloud assistance | Only if implemented: a verified cloud task and accurate Apple subscription experience | +Capture actual screens from the signed candidate using synthetic diagrams and documents. Do not depict unavailable cloud features or unverified export formats. -Synthetic source files and a legacy import fixture are in [demo-fixtures](demo-fixtures/). Demo script: open the checkout Mermaid source, add an inventory call through the editor, request one MCP revision, import `legacy-library.json`, edit a page, restart and reopen. Record which steps work on the shipping build before capturing actual screenshots or editing a short product video. No private legacy export or personal QA account appears in marketing. +| Order | Message | Evidence to capture | +| ----- | ------------------------------------------ | ------------------------------------------------------------------ | +| 1 | Edit the source and see the diagram update | Source editor and live preview showing one concrete edit | +| 2 | Open a diagram from your board | Double-click action and the independent editor for that diagram | +| 3 | Keep related views in Pages | Page tabs inside one diagram and switching between pages | +| 4 | Use ZenUML or Mermaid | One synthetic diagram of each supported language | +| 5 | Bring an older ZenUML library | JSON import with imported documents and Pages reviewed | +| 6 | Connect your MCP client | A real customer-configured MCP edit appearing in the local diagram | -## Public pages and review package +Use [demo-fixtures](demo-fixtures/) only as synthetic inputs. Record which steps pass on the shipping candidate before capturing screenshots or video. Remove private prompts, credentials, emails and customer work. -Proposed desktop landing/support URLs are not deployed. Existing [privacy](https://diagramly.ai/legal/privacy-policy), [terms](https://diagramly.ai/legal/terms) and [refund policy](https://diagramly.ai/legal/refund-policy) pages resolve, but desktop coverage and Apple purchase wording require review. Do not mark legal requirements complete merely because these URLs return content. Internal response templates and incident fields are in [support-playbook.md](support-playbook.md); they are not public support pages or an SLA. +## App Review materials -Explain the local server, loopback-only MCP access, exact JSON import format, external-agent connection, sandbox permissions, account linking, purchase/restore and account deletion in App Review notes. Supply safe demo access for cloud features where required; never supply an owner's account or production token. Prepare age rating, privacy labels, export-compliance answers, third-party notices, support contact and subscription review information from verified implementation facts. Event definitions and weekly review rules are in [measurement-plan.md](measurement-plan.md); no telemetry is configured by that plan. +Confirm the current public support and privacy URLs, seller details, support contact, privacy disclosures, age rating, export-compliance answers and third-party notices from the shipping candidate. The proposed `/desktop` landing page returned 404. `/desktop/support` returned HTTP 200; its content was checked for legacy import steps and the 10 MB limit, renderer-error troubleshooting, external agent/provider billing, and a support email. Recheck the live page before submission. Describe the customer-configured MCP flow and local data handling accurately. Do not include Diagramly cloud-AI, subscription, in-app purchase, purchase-restore, or unverified export claims. -Store requirements reference: [Apple app information](https://developer.apple.com/help/app-store-connect/reference/app-information/app-information/) and [App Review Guidelines](https://developer.apple.com/app-store/review/guidelines/). Recheck before submission. +Store requirements: [Apple app information](https://developer.apple.com/help/app-store-connect/reference/app-information/app-information/) and [App Review Guidelines](https://developer.apple.com/app-store/review/guidelines/). Recheck before submission. diff --git a/docs/launch/pricing.md b/docs/launch/pricing.md index b04414489..781bf7266 100644 --- a/docs/launch/pricing.md +++ b/docs/launch/pricing.md @@ -1,52 +1,15 @@ -# Pricing and unit economics +# Pricing and storefront status -Status: proposed desktop offer, no live price changes. Payment decision: Apple In-App Purchase, 2026-11-11. +Status: **existing paid Mac App Store app; current price not verified for this update.** No price change is proposed or authorized. -## Initial offer +## Decision -| Offer | Proposed US price | Benefit and boundary | -| ----------- | ------------------------------ | ----------------------------------------------------------------------------------------------------------------------------- | -| Local | Free download | Local Mermaid/ZenUML create, import, edit and save; external MCP connection. External agent costs belong to its own provider. | -| Pro monthly | $9.99 / month | Metered Diagramly cloud AI and paid cloud benefits after integration and cost verification | -| Pro annual | $99.99 / year, billed annually | Same service, annual commitment; monthly equivalent about $8.33, not a monthly charge | +Continue the existing ZenUML paid Mac App Store listing (`com.zenuml.app`, record ID `1602636196`) and transition its branding gradually to Diagramly. Keep the current storefront price and paid-app model. Do not add a subscription, in-app purchase, or Diagramly cloud-AI charge to this release. -Use one subscription group with monthly and annual alternatives; avoid multiple overlapping new desktop tiers at launch. These are working USD targets, not registered products or verified available Apple price points. StoreKit's localized product data must supply the actual price shown to customers. No free trial or lifetime/unlimited AI promise is included in this proposal. +A current public iTunes lookup for app ID `1602636196` confirms the US storefront price is **$29.99 USD**. The Australia storefront price has not been checked and remains **unverified**. Confirm both storefront prices in App Store Connect before preparing metadata. Do not change the price as part of this documentation update. -The owner approved reuse of the existing paid Mac App Store app record. Preserve the primary functionality existing purchasers paid for before enabling subscription gates. Apple App Review Guideline 3.1.2(a) says changing an existing app to a subscription model must not take away those paid-for primary features. Define and test how prior purchasers retain access before configuring a new paid offer; new recurring cloud services can be considered separately after entitlement and policy review. +## Product boundary -## Product catalogue decision checklist +The proposed v1 is local editing and preview for ZenUML and Mermaid, an independent editor for a board diagram opened by double-click, Pages tabs within a diagram, import of an older ZenUML JSON library, and an MCP connection configured by the customer. The customer supplies their MCP client and any associated AI account or provider billing. Diagramly cloud AI and recurring billing are outside this release scope. -Keep the catalogue to one auto-renewable Pro subscription group with monthly and annual durations. Before the App Store Connect owner creates products, record the final bundle ID, seller, subscription-group display name, immutable product identifiers, exact benefits, renewal wording, localization set, tax category and support/refund destinations. Treat product IDs and group membership as durable public billing contracts. Do not create placeholder live products to test copy. - -The $9.99 monthly and $99.99 annual amounts are USD targets for review only. Verify that Apple offers the desired price points in App Store Connect, check the localized customer price and billing period returned by StoreKit, and show that returned value in every purchase surface. No product is currently configured. The app cannot sell Pro until purchase, server verification, entitlement grant/expiry/refund handling and Restore Purchases all work end to end. - -Before fixing the paid allowance, map each included cloud operation to actual provider and infrastructure cost, choose a server-enforced monthly cap, measure high-percentile use, and prove that the cap protects the conservative proceeds case. Keep local editing and customer-owned external MCP providers outside the Diagramly cloud allowance. - -Pro should initially map to a clearly defined, server-enforced allowance compatible with Diagramly Basic. Determine the actual models, credit-to-cost mapping, reset schedule and limits before publishing a numeric allowance. Preserve existing Plus customer access; do not silently downgrade website subscribers or create a second subscription for them. Entitlement mapping is a launch gate, not a new label on the old Doop plan. - -## Existing baseline and market context - -The public Diagramly catalogue checked on 2026-11-11 lists Basic $9.99/month or $99/year, and Plus $19.99/month or $179/year: [public API](https://diagramly.ai/api/billing.plans), [saved normalized baseline](public-price-baseline.json). The website also advertises promotional prices; these are not the proposed App Store prices. Checkout, taxes and promo eligibility were not tested. Existing website billing remains unchanged. - -For context, [Mermaid's public pricing](https://mermaid.ai/pricing) lists Plus at $10/user/month and Premium at $20/user/month when billed annually. This supports testing a $9.99 entry offer; it does not prove willingness to pay or feature equivalence. Validate the offer with actual activation, repeat use and paid retention before adding more tiers or discounts. - -## Apple proceeds scenarios - -Apple's [subscription overview](https://developer.apple.com/app-store/subscriptions/) describes standard subscription proceeds of 70% initially and 85% after one year of paid service, minus applicable taxes. The [Small Business Program](https://developer.apple.com/app-store/small-business-program/) has a reduced 15% commission for approved eligible developers. Our enrollment and contract rate have not been verified. Budget both scenarios; do not assume we receive the reduced rate. - -Illustrative proceeds below exclude taxes, refunds, currency adjustments and all service costs: - -| Proposed price | At 30% commission | At 15% commission | -| -------------- | ------------------------------ | ------------------------------- | -| $9.99 monthly | $6.993 / month | $8.4915 / month | -| $99.99 annual | $69.993 / year ($5.8328/month) | $84.9915 / year ($7.0826/month) | - -Planning rule: test whether AI, rendering, storage and support variable costs fit within 30% of these proceeds. That leaves a proposed 70% contribution margin before fixed costs, not an observed margin. The conservative annual scenario allows about **$1.75/customer/month** of variable cost under that assumption. Meter real job costs and heavy-user tails; a monthly credit count without cost mapping cannot establish profitability. - -Annual cash arrives on an annual schedule while cloud costs continue monthly. Reserve enough proceeds to serve prepaid customers and handle refunds; do not treat the first payout as earned monthly margin. Reconcile actual Apple financial reports before making pricing decisions. - -## Activation and conversion - -Let customers complete and reopen one useful local diagram before showing a contextual paid cloud offer. Present the relevant cloud benefit, actual price, allowance and renewal terms. Show Restore Purchases and Manage Subscription. Do not block access to imported documents or use a misleading connected-AI indicator to force a purchase. - -Measure saved/reopened diagrams, successful revisions, retained weekly editors, paywall-to-verified-purchase conversion, 30-day paid retention, refunds, and net contribution. Use sample sizes and cohorts; no invented revenue forecasts or guaranteed conversion target. +No price, discount, subscription duration, trial, cloud allowance, or renewal term should appear in new copy. Do not imply that purchase restore or other commerce behavior has been verified. Preserve the existing paid-app listing and price while release readiness is checked. diff --git a/docs/launch/store-listing.json b/docs/launch/store-listing.json index 0dafc0580..850cabe3c 100644 --- a/docs/launch/store-listing.json +++ b/docs/launch/store-listing.json @@ -6,28 +6,28 @@ "primaryCategory": "Productivity", "secondaryCategory": "Developer Tools", "keywords": "mermaid,zenuml,sequence,flowchart,architecture,uml,diagram,mcp", - "promotionalText": "Create editable Mermaid and ZenUML diagrams on your Mac. Keep your documents local and connect a compatible MCP client to revise them.", - "description": "Diagramly Desktop is a local workspace for editable ZenUML and Mermaid diagrams.\n\nCREATE AND EDIT\nWrite ZenUML or Mermaid source and see the diagram update. Organize work in documents and pages, then save and reopen it on your Mac.\n\nCONNECT YOUR AI AGENT\nConnect a compatible MCP client to the desktop app and let it read or update the open diagram. Your MCP client and any AI model may require a separate account or subscription.\n\nIMPORT A ZENUML LIBRARY\nImport the JSON library exported by the older ZenUML desktop app. Review imported documents and pages, then continue editing their diagram source. Import reports identify styles that need attention.\n\nLOCAL BY DEFAULT\nYour documents stay on your Mac unless you choose to connect an external service or agent. Diagramly cloud AI, account entitlements and Apple subscriptions are not available in this release draft.\n\nThis draft describes the local desktop spike. Confirm every claim against the signed App Store build before submission.", + "promotionalText": "Edit ZenUML and Mermaid diagrams on your Mac. Write source, see a live preview, and connect an MCP client you provide.", + "description": "Diagramly Desktop is a local editor for ZenUML and Mermaid diagrams on your Mac.\n\nEDIT WITH A LIVE PREVIEW\nWrite or change diagram source and see the rendered result update. Open a diagram from your board in its own editor with a double-click.\n\nORGANIZE WITH PAGES\nKeep related views in Pages tabs within a diagram.\n\nBRING YOUR ZENUML LIBRARY\nImport a library exported as JSON by the older ZenUML desktop app, then continue working with its diagrams and pages.\n\nCONNECT YOUR MCP CLIENT\nConnect an MCP client that you provide and configure to work with your local diagram. You are responsible for the client and any AI provider account or charges it requires.\n\nThis proposed update continues the existing paid ZenUML Mac app listing as Diagramly Desktop. It does not add Diagramly cloud AI, a subscription, or in-app purchases. Confirm all features and wording against the signed release build before submission.", "supportUrl": "https://diagramly.ai/desktop/support", "marketingUrl": "https://diagramly.ai/desktop", "privacyPolicyUrl": "https://diagramly.ai/legal/privacy-policy", "termsUrl": "https://diagramly.ai/legal/terms", "refundPolicyUrl": "https://diagramly.ai/legal/refund-policy", - "urlStatus": "Desktop marketing and support pages are proposed and not deployed. Existing legal pages resolve but need desktop and Apple purchase coverage review.", - "bundleId": null, + "urlStatus": "The proposed /desktop URL returned 404. /desktop/support returned HTTP 200; content was checked for legacy import steps and the 10 MB limit, renderer-error troubleshooting, external agent/provider billing, and a support email. Desktop coverage of the legal pages is unverified; recheck the live page before submission.", + "bundleId": "com.zenuml.app", "sku": null, "copyright": "Confirm seller identity and third-party attribution before submission.", - "releaseNotes": "Initial release. Replace with tested release contents before submission.", - "reviewNotes": "Not submission-ready. Provide a synthetic local demo, exact supported import format, MCP connection steps, sandbox explanations, third-party notices and verified account or purchase flows. Do not provide personal accounts or customer diagrams.", + "releaseNotes": "Draft update notes: Edit ZenUML and Mermaid source with a live preview. Open a board diagram in its own editor, organize its views in Pages tabs, import an older ZenUML JSON library, and connect an MCP client you provide. Finalize after checking these changes on the signed release build.", + "reviewNotes": "Draft only; not submitted. Confirm the existing listing record and current price in App Store Connect. Provide review steps for local source editing, the board-to-editor double-click, Pages tabs, ZenUML and Mermaid, the supported legacy ZenUML JSON import, and a customer-configured MCP client. Use a synthetic local demo. Do not imply Diagramly cloud AI, subscription, in-app purchase, purchase restore, or unverified export formats.", "claimLimits": [ - "Do not claim cloud AI, Diagramly account entitlements, Apple subscriptions, purchase restore or cloud sync are available until implemented and verified.", - "Only claim ZenUML, Mermaid, MCP and legacy import workflows that pass acceptance on the exact signed release build.", - "Do not advertise PlantUML, Draw.io, PDF, SVG or native source-file export until each is verified in the signed release build.", - "Do not describe the debug spike as an approved, notarized or published release.", - "Use only synthetic documents in marketing material. Remove emails, credentials, private libraries and customer work.", - "Apple In-App Purchase is the selected channel, not a live integration. Use localized StoreKit prices only after products are configured and verified." + "The current public iTunes lookup confirms the existing US storefront price is $29.99 USD. Australia pricing is unverified. Preserve the price and confirm current storefront values in App Store Connect before publishing price information.", + "Do not claim listing changes have been submitted or approved until App Store Connect confirms that state.", + "Verify the source editor, live preview, board double-click, Pages, ZenUML, Mermaid, legacy JSON import and customer-configured MCP flow on the exact signed release build.", + "Do not claim Diagramly cloud AI, subscriptions, in-app purchases, cloud sync, purchase restore, or any export format in this release.", + "Do not describe a development build as signed for distribution, approved, or published.", + "Use synthetic documents and credentials in review and marketing material." ], - "paymentChannel": "apple-in-app-purchase", + "paymentChannel": "existing-paid-app-storefront-price-to-be-verified", "distributionChannel": "mac-app-store", - "commerceStatus": "Apple payments were selected. StoreKit, products and backend transaction verification are not implemented." + "commerceStatus": "Existing paid app; preserve current price. Public iTunes lookup confirms US price $29.99 USD; Australia price and App Store Connect build/submission state are unverified. No subscription or in-app purchase is part of the proposed v1." } diff --git a/package.json b/package.json index 77d4fdd4f..ab08e2b77 100644 --- a/package.json +++ b/package.json @@ -54,6 +54,7 @@ "class-variance-authority": "^0.7.1", "clsx": "^2.1.1", "cmdk": "^1.1.1", + "codemirror": "5.65.20", "drizzle-orm": "^0.45.2", "envalid": "8.2.0", "express": "^4.19.2", @@ -90,6 +91,7 @@ "@storybook/addon-docs": "10.6.3", "@storybook/react-vite": "10.6.3", "@tailwindcss/vite": "^4.3.3", + "@types/codemirror": "5.60.15", "@types/express": "^4.17.21", "@types/less": "^3.0.8", "@types/node": "^20.14.10", diff --git a/shared/diagramFrame.ts b/shared/diagramFrame.ts index 0c92eafda..ae5c631b5 100644 --- a/shared/diagramFrame.ts +++ b/shared/diagramFrame.ts @@ -195,6 +195,7 @@ async function sync() { await renderDiagram(mount, source) if (!current()) return root.setAttribute('${DIAGRAM_STATE_ATTR}', 'rendered') + parent.postMessage({ type: 'diagramly:diagram-render-state', state: 'rendered', source }, '*') // WebKit may suspend animation frames in a hidden or occluded iframe. // Measuring a completed render must not hold the source-update lock forever. await new Promise((resolve) => { @@ -215,6 +216,7 @@ async function sync() { if (!current()) return /* the last good diagram stays up while the source does not parse */ root.setAttribute('${DIAGRAM_STATE_ATTR}', 'error') + parent.postMessage({ type: 'diagramly:diagram-render-state', state: 'error', source }, '*') console.error(error) } finally { busy = false diff --git a/src/components/ConnectModal.tsx b/src/components/ConnectModal.tsx index 83c1dd8d0..bd29da949 100644 --- a/src/components/ConnectModal.tsx +++ b/src/components/ConnectModal.tsx @@ -205,7 +205,7 @@ function agentSteps( case 'claude': if (claudeConnection === 'desktop') { return { - lede: t('connect.claudeDesktopLede'), + lede: t(isDesktopShell() ? 'connect.localClaudeDesktopLede' : 'connect.claudeDesktopLede'), steps: [ { title: t('connect.claudeDesktopAddTitle'), @@ -213,8 +213,8 @@ function agentSteps( action: , }, { - title: t('connect.claudeDesktopConnectTitle'), - body: t('connect.claudeDesktopConnectBody'), + title: t(isDesktopShell() ? 'connect.localLibraryConnectTitle' : 'connect.claudeDesktopConnectTitle'), + body: t(isDesktopShell() ? 'connect.localClaudeDesktopConnectBody' : 'connect.claudeDesktopConnectBody'), }, { ...pointAt, @@ -322,7 +322,7 @@ function agentSteps( {t('connect.chatgptAddReview')} {/* ChatGPT's own button label */} Create as a plugin - {t('connect.chatgptAddAfter')} + {t(isDesktopShell() ? 'connect.localChatgptAddAfter' : 'connect.chatgptAddAfter')} ), code: mcpUrl, @@ -472,6 +472,12 @@ function AgentSteps({ /> )} + {isDesktopShell() && + agent !== 'headless' && + !(agent === 'claude' && claudeConnection === 'desktop') && + !(agent === 'mcp' && mcpConnection === 'key') && ( +

{t('connect.localLibraryBrowserApproval')}

+ )}
    {steps.map((step, i) => (
  1. void + onSave: () => void +}) { + const textarea = useRef(null) + const editor = useRef(null) + const callbacks = useRef({ onChange, onSave }) + useLayoutEffect(() => { + callbacks.current = { onChange, onSave } + }) + + useLayoutEffect(() => { + if (!textarea.current) return + const config: EditorConfiguration = { + mode: `diagramly-${kind}`, + lineNumbers: true, + tabSize: 2, + indentUnit: 2, + indentWithTabs: false, + autofocus: true, + autoCloseBrackets: true, + matchBrackets: true, + gutters: ['CodeMirror-linenumbers'], + extraKeys: { + Tab(cm) { + if (cm.somethingSelected()) cm.indentSelection('add') + else cm.execCommand('insertSoftTab') + }, + 'Shift-Tab': (cm) => cm.indentSelection('subtract'), + 'Ctrl-S': () => callbacks.current.onSave(), + 'Cmd-S': () => callbacks.current.onSave(), + 'Ctrl-/': 'toggleComment', + 'Cmd-/': 'toggleComment', + 'Ctrl-F': 'find', + 'Cmd-F': 'find', + }, + } + const cm = CodeMirror.fromTextArea(textarea.current, config) + editor.current = cm + cm.on('change', (instance) => callbacks.current.onChange(instance.getValue())) + const refresh = () => cm.refresh() + window.addEventListener('resize', refresh) + const frame = window.requestAnimationFrame(refresh) + return () => { + window.cancelAnimationFrame(frame) + window.removeEventListener('resize', refresh) + cm.toTextArea() + editor.current = null + } + }, [kind]) + + useEffect(() => { + editor.current?.setOption('lineWrapping', wrap) + }, [wrap]) + + useEffect(() => { + const cm = editor.current + if (cm && cm.getValue() !== value) cm.setValue(value) + }, [value]) + + return ( +