Skip to content

Items: prototype a first-class catalogue and safer picker flow - #3

Draft
Habdel-Edenfield wants to merge 6 commits into
Coldensjo:mainfrom
Habdel-Edenfield:agent/items-prototype
Draft

Items: prototype a first-class catalogue and safer picker flow#3
Habdel-Edenfield wants to merge 6 commits into
Coldensjo:mainfrom
Habdel-Edenfield:agent/items-prototype

Conversation

@Habdel-Edenfield

@Habdel-Edenfield Habdel-Edenfield commented Aug 16, 2026

Copy link
Copy Markdown
Contributor

Context

This Draft PR offers the Items work developed in the Linux fork as a substantial initial prototype and a request for upstream feedback.

The goal is to reuse MONx's existing item database, sprite protocol, filters and virtualized browsers, then expand them into a coherent item workflow. It is not a separate item system, a Linux-only UI, or a replacement for the original Windows-oriented application flow. Upstream may adopt it as-is, reshape the UX, or split it into smaller changes.

Although developed and manually exercised on Linux, the implementation lives in the shared React/Tauri UI and preserves the existing cross-platform protocol URL helpers.

Prototype preview

MONx Items prototype on Linux: a filtered item list on the left, structured details for mortal mace in the centre, and its client sprite preview on the right

Real Canary/OTServBR workspace on Linux. This records the current prototype for discussion; it is not a claim that the visual design is final.

What this changes

  • Makes Items a first-class, read-only catalogue:
    • virtualized sidebar list;
    • search and item filters;
    • structured centre-column details;
    • dedicated right-hand appearance preview;
    • animated client frames and X/Y/Z variants where available.
  • Moves loot, corpse and typeex selection into a shared modal while preserving the monster editor behind it.
  • Reuses that picker for the create wizard's corpse and loot steps.
  • Scopes the loot tray to one picker session and pins editor writes to the monster that opened it.
  • Keeps PreviewPanel monster-specific and selects a typed ItemPreviewPanel at the Workspace level.
  • Adds the corresponding Polish and Portuguese UI strings.

The item database remains read-only: this does not create, rename or modify items.xml, items.toml, items.srv, items.otb or client assets.

Safety fix carried by the prototype

The earlier tray could outlive the dialog and its target, allowing invisible stale contents to be committed after navigation. The final slice clears the tray at session boundaries, records the target document/file, removes the orphan global tray command, and invalidates the picker before navigation changes the selected monster.

Wizard picks are intentionally separate: they return ids to the mounted wizard and never own an editor transaction. Opening Used by... remains an inspection; only following a reference closes the picker before navigating.

Platform scope

This does not change Linux packaging, the Windows launcher or protocol selection. The existing monx:// / http://monx.localhost split remains authoritative.

Development and manual investigation used ./monx.sh on Linux/XWayland/WebKitGTK with a real Canary/OTServBR workspace: roughly 17,500 explicit item entries, about 38,000 expanded rows and 41,841 object appearances from a modern client bundle.

A small, separable Landing commit restores discoverability of that existing support by naming assets/ with catalog-content.json alongside legacy Tibia.dat + Tibia.spr. It changes guidance only, not client loading behavior.

Windows and legacy-client verification are still required before this leaves Draft.

Known limits and follow-ups

  • The catalogue and appearance summaries still load when Workspace mounts even if Items is never opened. Lazy catalogue loading is the next performance slice.
  • This is an initial product direction, not a claim that the final upstream UX is settled.
  • Legacy .spr/.dat, no-items.otb workspaces and Windows do not yet have recorded manual verification on this extracted branch.
  • No DOM/UI automation harness was added; a fresh manual smoke test of the extracted branch remains useful.
  • The read-only rail deliberately omits the old grid's drag, multi-select and context-menu interactions; edits move through the modal. Keyboard/focus accessibility still needs a dedicated audit.
  • The detail view structures common fields and presents remaining engine-specific attributes as raw data; it is not an item editor.
  • The sprite-cache and outfit-animation performance work is deliberately excluded and can follow as a separate companion PR.

The prototype boundary and invariants are recorded in ITEMS.md.

Base and dependencies

  • Base: Coldensjo/MONx:main at ae6503d / version 0.1.131.
  • Resulting version: 0.1.133.
  • No dependency on MapX or other experimental work from the fork.

Verification

Run on the isolated PR branch:

  • bun run i18n — 971 strings carried by Polish and Portuguese
  • bun run commands — 38 commands, no duplicate ids/chords
  • bun test — 161 passed
  • bun run build
  • cargo check --locked in src-tauri/
  • git diff --check

Before marking Ready for review:

  • Fresh Linux real-workflow smoke test from this extracted branch
  • Windows smoke test
  • Legacy .spr/.dat smoke test
  • Workspace without items.otb smoke test

Habdel-Edenfield and others added 3 commits August 15, 2026 23:04
Reuse the existing item database, filters, virtualized rows and sprite protocol to give Items a read-only sidebar list with centre-column details. Move loot, corpse and typeex selection into a shared modal that preserves the editor, and reuse that picker for the create wizard.

This is the first product-shaped prototype, not a new item engine or a write path for item/client files.

Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com>
Scope loot trays to one picker session and pin their writes to the monster that opened the dialog. Remove the now-invisible global tray command and make Used by navigation close the picker safely.

Bring the item detail view up to the editor's visual hierarchy and give Items a dedicated animated right-hand preview with client variants, bounded frame preloading, loading states and keyboard-accessible selection.
The client slot accepts both legacy Tibia.dat/Tibia.spr pairs and modern assets directories with catalog-content.json. Restore that discoverability on the upstream-based prototype branch and carry the dynamically translated hint in Polish and Portuguese.
Preserve the real Canary/Linux catalogue view used to discuss the initial prototype: virtualized list and filters, structured selected-item details, and the typed client-appearance preview in one frame.
Keep the real application capture discoverable from the durable prototype boundary, while making explicit that it records a discussion point rather than a final visual contract.
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