Skip to content

feat: add zero-build dashproof-lite + dashmint-lite single-file companions#71

Merged
thephez merged 9 commits intomainfrom
feat/example-app-dashproof-lite
Apr 30, 2026
Merged

feat: add zero-build dashproof-lite + dashmint-lite single-file companions#71
thephez merged 9 commits intomainfrom
feat/example-app-dashproof-lite

Conversation

@thephez
Copy link
Copy Markdown
Collaborator

@thephez thephez commented Apr 30, 2026

Summary

  • Add public/dashproof-lite.html (read-only Verify + History) and public/dashmint-lite.html (read-only card browser with Marketplace-only toggle) to the existing example apps.
  • Both are single-file, zero-build pages that load @dashevo/evo-sdk directly from esm.sh — no bundler, no install, no React. They visually echo the React apps' light-mode shells and serve as a minimal learning reference for the SDK query patterns each app uses.
  • Each ships at <owner>.github.io/<repo>/<app>/<app>-lite.html automatically — the existing deploy-example-apps.yml workflow needs no changes because Vite copies public/* into dist/ on build.
  • Each app's CLAUDE.md gets a one-line pointer to its *-lite.html so the file is discoverable next to src/dash, test, etc.

Summary by CodeRabbit

  • New Features

    • Added standalone DashMint Lite page for read-only NFT card browsing with marketplace filtering.
    • Added standalone DashProof Lite page for proof verification and history queries.
  • Tests

    • Added end-to-end test suite for DashProof Lite features.
  • Documentation

    • Updated project documentation to reference new companion pages.

thephez and others added 7 commits April 29, 2026 16:01
Mirror the React app's sidebar layout (logo, nav, connection dot) and
render verify/history results as structured anchor cards instead of raw
JSON, keeping the file fully self-contained.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
… comments

Strip the full theme/anchor-card UI back to a bare-bones sidebar shell, group
the Dash Platform SDK calls (connect + queries) into a labeled top section,
and add comments throughout to make it readable as a learning example.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Reorder dashproof-lite.html so the Dash Platform SDK surface (connect +
queries) is grouped at the top of the script, and replace the raw JSON
output with simple per-anchor cards (title row + definition list).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Pull Inter from Google Fonts, switch the active-nav indicator to a left
accent bar, tint section panels with a soft shadow, and bump radii/text
colors to match the React app's surface palette.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Move the single-file companion into public/ so Vite copies it into the
React app's dist/ on deploy. Add a one-line pointer in the app's
CLAUDE.md so it's discoverable alongside src/dash, test, and e2e.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Mirrors the dashproof-lite pattern: zero-build companion served from
public/, loads @dashevo/evo-sdk from esm.sh, queries the card contract
read-only, and renders results as a responsive grid of rarity-tinted
tiles with attack/defense stats and a marketplace toggle.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Apr 30, 2026

Warning

Rate limit exceeded

@thephez has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 34 minutes and 21 seconds before requesting another review.

To keep reviews running without waiting, you can enable usage-based add-on for your organization. This allows additional reviews beyond the hourly cap. Account admins can enable it under billing.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: a54da35a-c569-47c8-b359-37370cc53b1b

📥 Commits

Reviewing files that changed from the base of the PR and between 7dd9e6a and 97c1eeb.

📒 Files selected for processing (2)
  • example-apps/dashmint-lab/public/dashmint-lite.html
  • example-apps/dashproof-lab/public/dashproof-lite.html
📝 Walkthrough

Walkthrough

Two companion "lite" HTML pages are introduced for DashMint and DashProof example apps—single-file, browser-based UIs that connect to Dash Platform testnet in read-only mode. Supporting configuration updates, documentation, and Playwright tests for DashProof are included.

Changes

Cohort / File(s) Summary
DashMint Lite
example-apps/dashmint-lab/.prettierignore, example-apps/dashmint-lab/CLAUDE.md, example-apps/dashmint-lab/public/dashmint-lite.html
Introduces standalone HTML page for read-only NFT card browsing with "All cards" and "Marketplace only" toggle, connecting to testnet via EvoSDK.testnetTrusted() and querying the card contract.
DashProof Lite
example-apps/dashproof-lab/.prettierignore, example-apps/dashproof-lab/CLAUDE.md, example-apps/dashproof-lab/public/dashproof-lite.html
Introduces standalone HTML page for proof verification (SHA-256 hashing) and anchor history queries by chainId, with connection status and error handling.
DashProof Testing
example-apps/dashproof-lab/e2e/lite.spec.ts
New Playwright test suite validating lite page testnet connection, file verification flow, anchor queries, miss scenarios, and tab switching behavior.

Sequence Diagram(s)

sequenceDiagram
    participant Browser as Browser Client
    participant SDK as EvoSDK
    participant Platform as Dash Platform<br/>(Testnet)

    Browser->>Browser: On Page Load
    Browser->>SDK: testnetTrusted()
    SDK->>Platform: Connect
    Platform-->>SDK: Connected
    SDK-->>Browser: Ready
    Browser->>Browser: Display "Connected to testnet"

    alt All Cards Mode
        Browser->>Browser: User clicks Refresh
        Browser->>SDK: Query card contract<br/>(limit: 100)
        SDK->>Platform: Fetch documents
        Platform-->>SDK: Card documents
        SDK-->>Browser: Normalized results
    else Marketplace Only Mode
        Browser->>Browser: User clicks Refresh
        Browser->>SDK: Query card contract<br/>(limit: 100)
        SDK->>Platform: Fetch documents
        Platform-->>SDK: Card documents
        SDK-->>Browser: Normalized results
        Browser->>Browser: Filter: $price > 0
    end

    Browser->>Browser: Render card tiles<br/>(stats, rarity, price)
    Browser->>Browser: Display count & status
Loading
sequenceDiagram
    participant Browser as Browser Client
    participant SHA as Browser SHA-256
    participant SDK as EvoSDK
    participant Platform as Dash Platform<br/>(Testnet)

    Browser->>Browser: On Page Load
    Browser->>SDK: testnetTrusted()
    SDK->>Platform: Connect
    Platform-->>SDK: Connected
    SDK-->>Browser: Ready

    alt Verify Proof Tab
        Browser->>Browser: User selects file
        Browser->>SHA: Hash file (SHA-256)
        SHA-->>Browser: Hex digest
        Browser->>Browser: Encode to base64
        Browser->>SDK: Query anchor by entryHash
        SDK->>Platform: Fetch anchor record
        Platform-->>SDK: Anchor document(s)
        SDK-->>Browser: Result
        Browser->>Browser: Render anchor card<br/>(fixture name, hash)
    else History by ChainId Tab
        Browser->>Browser: User enters chainId
        Browser->>SDK: Query anchors by chainId
        SDK->>Platform: Fetch anchor records
        Platform-->>SDK: Anchor documents
        SDK-->>Browser: Results (newest-first)
        Browser->>Browser: Render history cards
    end

    Browser->>Browser: Display status &<br/>handle errors
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~28 minutes

Poem

🐰 Two lite pages hop into the fray,
DashMint cards and proofs on display,
Browser-bound magic, no build in sight,
SDK whispering through the night,
Simple and swift, the lite way's bright! ✨

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately and concisely describes the main change: adding two new zero-build single-file companion pages (dashproof-lite and dashmint-lite) to the repository.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/example-app-dashproof-lite

Warning

Review ran into problems

🔥 Problems

Timed out fetching pipeline failures after 30000ms


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
Review rate limit: 0/1 reviews remaining, refill in 34 minutes and 21 seconds.

Comment @coderabbitai help to get the list of available commands and usage tips.

…om Prettier

Cover the single-file companion's read-only flows (connect, verify match/miss,
history hit/miss, tab switching) against live testnet via the existing
dashproof-lab Playwright config. Also pin the hand-tuned dashproof-lite and
dashmint-lite HTML files in their respective .prettierignore so npm run format
stops doubling their line count.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@thephez thephez marked this pull request as ready for review April 30, 2026 14:28
Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 3

🧹 Nitpick comments (1)
example-apps/dashproof-lab/e2e/lite.spec.ts (1)

27-27: ⚡ Quick win

Mark this suite parallel to match the repo's read-only E2E convention.

These tests only read, so leaving the suite at Playwright's default serial mode makes the new lite coverage slower than the rest of the read-only specs.

Suggested change
 test.describe("dashproof-lite (single-file companion)", () => {
+  test.describe.configure({ mode: "parallel" });

As per coding guidelines, "Read-only specs in e2e/ tests run in parallel; anchor-write specs are forced serial via test.describe.configure({ mode: "serial" }) to avoid concurrent writes to the same identity."

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@example-apps/dashproof-lab/e2e/lite.spec.ts` at line 27, Mark the test suite
for parallel execution by configuring the Playwright describe block: inside the
existing test.describe("dashproof-lite (single-file companion)", ...) block call
test.describe.configure({ mode: "parallel" }) (or equivalently configure the
describe before tests run) so the suite runs in parallel with other read-only
e2e specs; update the describe around the symbol test.describe("dashproof-lite
(single-file companion)", ...) to include this configuration.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@example-apps/dashmint-lab/public/dashmint-lite.html`:
- Around line 137-147: The marketplace currently only queries the first page
(limit:100) in listAllCards(), causing priced cards beyond that page to be
missing; update listAllCards (and the similar logic around render/market at the
other occurrence) to paginate through the contract results until no more pages
(collecting all documents before calling normalizeCards and client-side market
filtering) or, if full pagination is undesirable, change the UI/text to clearly
label the view as a "first-page sample" so users know results are limited;
locate listAllCards and the render/market filtering code to implement pagination
or add the sample label.

In `@example-apps/dashproof-lab/public/dashproof-lite.html`:
- Around line 95-97: The history view currently calls listByChain() but only
fetches the first page (100 items) so the UI is silently truncated; update the
code that builds the "History by chainId" view (referencing listByChain and the
chain-id input/button handlers) to either iterate pagination until no next page
(calling listByChain repeatedly with the returned continuation token/page
parameter and appending results) or explicitly surface that the view is capped
(change the heading/description and add a "Load more" button that requests the
next page). Ensure you append additional anchors to the existing list rather
than replacing it and preserve any existing sort order/state so users can
request subsequent pages or see a clear “showing first 100” note.
- Around line 119-122: Update the unpinned esm.sh import to a fixed SDK version:
replace the bare import of EvoSDK ("import { EvoSDK } from
'https://esm.sh/@dashevo/evo-sdk';") with the versioned package specifier used
by the apps (e.g. "import { EvoSDK } from
'https://esm.sh/@dashevo/evo-sdk@3.1.0-dev.1';") in this file and make the
identical change in public/dashmint-lite.html so both lite pages pin the same
`@dashevo/evo-sdk`@3.1.0-dev.1 version for reproducible deployments.

---

Nitpick comments:
In `@example-apps/dashproof-lab/e2e/lite.spec.ts`:
- Line 27: Mark the test suite for parallel execution by configuring the
Playwright describe block: inside the existing test.describe("dashproof-lite
(single-file companion)", ...) block call test.describe.configure({ mode:
"parallel" }) (or equivalently configure the describe before tests run) so the
suite runs in parallel with other read-only e2e specs; update the describe
around the symbol test.describe("dashproof-lite (single-file companion)", ...)
to include this configuration.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 03df13b6-e85a-407e-92d6-50c380fe8d82

📥 Commits

Reviewing files that changed from the base of the PR and between 7c981f3 and 7dd9e6a.

📒 Files selected for processing (7)
  • example-apps/dashmint-lab/.prettierignore
  • example-apps/dashmint-lab/CLAUDE.md
  • example-apps/dashmint-lab/public/dashmint-lite.html
  • example-apps/dashproof-lab/.prettierignore
  • example-apps/dashproof-lab/CLAUDE.md
  • example-apps/dashproof-lab/e2e/lite.spec.ts
  • example-apps/dashproof-lab/public/dashproof-lite.html

Comment thread example-apps/dashmint-lab/public/dashmint-lite.html
Comment thread example-apps/dashproof-lab/public/dashproof-lite.html
Comment thread example-apps/dashproof-lab/public/dashproof-lite.html Outdated
Both lite pages were importing @dashevo/evo-sdk via the bare esm.sh
specifier, silently following the npm latest tag. Pin to 3.1.0-dev.1
so they track the same SDK version each app's package.json depends on.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@thephez thephez merged commit c07cb08 into main Apr 30, 2026
3 checks passed
@thephez thephez deleted the feat/example-app-dashproof-lite branch April 30, 2026 14:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant