domain_detail.html
html
sha256:1dd27e6d5c24550177b01b0a171e8375c07cf046b549e7683364706b6522d3bc
docs(#139): mark all 11 checklist items resolved, document …
Sonnet 5
12 days ago
| 1 | {% extends "musehub/base.html" %} |
| 2 | |
| 3 | {% block title %}{{ domain.display_name }} · Muse Domain{% endblock %} |
| 4 | |
| 5 | {# Strip container padding — hero is full-bleed, we control padding internally #} |
| 6 | {% block container_extra_class %} page-container{% endblock %} |
| 7 | |
| 8 | {% block page_json %}{"page": "domain-detail", "domainSlug": {{ domain.slug | tojson }}, "domainId": {{ domain.domain_id | tojson }}, "viewerType": {{ domain.viewer_type | tojson }}, "dimensions": {{ domain.dimensions | tojson }}}{% endblock %} |
| 9 | |
| 10 | {% block content %} |
| 11 | <div class="dd-page" data-domain-slug="{{ domain.slug }}"> |
| 12 | |
| 13 | {# ── Hero ────────────────────────────────────────────────────────────────── #} |
| 14 | <div class="ph-hero dd-hero"> |
| 15 | <div class="dd-hero__bg"></div> |
| 16 | <div class="ph-hero-inner"> |
| 17 | <div class="ph-hero-left"> |
| 18 | <div class="ph-hero-eyebrow"> |
| 19 | <span class="domain-badge">{{ domain.scoped_id }}</span> |
| 20 | {% if domain.is_verified %}<span class="dd-verified-badge">{{ icon("check", 11) }} Verified</span>{% endif %} |
| 21 | {% if domain.is_deprecated %}<span class="dd-deprecated-badge">{{ icon("alert", 11) }} Deprecated</span>{% endif %} |
| 22 | <span class="dd-version">v{{ domain.version }}</span> |
| 23 | </div> |
| 24 | <h1 class="ph-hero-title dd-hero__title"> |
| 25 | <span class="dd-hero__icon"> |
| 26 | {% if domain.slug == 'midi' %} |
| 27 | {{ icon("music", 28, "icon--light-stroke") }} |
| 28 | {% elif domain.slug == 'code' %} |
| 29 | {{ icon("code", 28, "icon--light-stroke") }} |
| 30 | {% else %} |
| 31 | {{ icon("target", 28, "icon--light-stroke") }} |
| 32 | {% endif %} |
| 33 | </span> |
| 34 | {{ domain.display_name }} |
| 35 | </h1> |
| 36 | <p class="ph-hero-sub">{{ domain.description }}</p> |
| 37 | <div class="ph-hero-actions"> |
| 38 | <button class="dd-hero-btn dd-hero-btn--primary dd-install-btn" id="dd-install-btn"> |
| 39 | {{ icon("download", 13) }} |
| 40 | Install Domain |
| 41 | </button> |
| 42 | <a href="?format=json" class="dd-hero-btn dd-hero-btn--ghost" target="_blank"> |
| 43 | JSON API |
| 44 | {{ icon("arrow-up-right", 11) }} |
| 45 | </a> |
| 46 | </div> |
| 47 | </div> |
| 48 | </div> |
| 49 | </div> |
| 50 | |
| 51 | {# ── Stats strip ─────────────────────────────────────────────────────────── #} |
| 52 | <div class="ph-stats-strip"> |
| 53 | <div class="ph-stat"> |
| 54 | <span class="ph-stat-value">{{ domain.dimensions | length }}</span> |
| 55 | <span class="ph-stat-label">Dimensions</span> |
| 56 | </div> |
| 57 | <div class="ph-stat"> |
| 58 | <span class="ph-stat-value">{{ repos_total }}</span> |
| 59 | <span class="ph-stat-label">Repositories</span> |
| 60 | </div> |
| 61 | <div class="ph-stat"> |
| 62 | <span class="ph-stat-value">{{ domain.viewer_type | replace("_", " ") | title }}</span> |
| 63 | <span class="ph-stat-label">Viewer</span> |
| 64 | </div> |
| 65 | <div class="ph-stat"> |
| 66 | <span class="ph-stat-value">{{ domain.merge_semantics | upper if domain.merge_semantics else "—" }}</span> |
| 67 | <span class="ph-stat-label">Merge</span> |
| 68 | </div> |
| 69 | {% if domain.kinds %} |
| 70 | <div class="ph-stat"> |
| 71 | <span class="ph-stat-value">{{ domain.kinds | length }}</span> |
| 72 | <span class="ph-stat-label">Kinds</span> |
| 73 | </div> |
| 74 | {% endif %} |
| 75 | {% if domain.supported_commands %} |
| 76 | <div class="ph-stat"> |
| 77 | <span class="ph-stat-value">{{ domain.supported_commands | length }}</span> |
| 78 | <span class="ph-stat-label">CLI Commands</span> |
| 79 | </div> |
| 80 | {% endif %} |
| 81 | </div> |
| 82 | |
| 83 | {# ── Body: content (narrow left), sidebar (wide right) ─────────────────── #} |
| 84 | <div class="ph-body"> |
| 85 | |
| 86 | {# ── Main content — col 1: 240px narrow left ───────────────────────────── #} |
| 87 | <div class="ph-content dd-main"> |
| 88 | |
| 89 | {# Live viewer preview — musehub#117 DOM_09/DOM_10/DOM_11. Renders the |
| 90 | domain's actual palette viewer (symbol_graph/piano_roll/generic), |
| 91 | parameterized only by the declared dimensions below — no per-domain |
| 92 | executable code runs here, ever. #} |
| 93 | <section class="ph-section"> |
| 94 | <div class="ph-section-title"> |
| 95 | {{ icon("eye", 13) }} |
| 96 | Live Preview |
| 97 | </div> |
| 98 | <p class="ph-section-desc"> |
| 99 | How this domain's {{ domain.viewer_type | replace("_", " ") }} viewer renders |
| 100 | its declared dimensions. |
| 101 | </p> |
| 102 | <div class="dd-viewer-preview" id="dd-viewer-preview"></div> |
| 103 | </section> |
| 104 | |
| 105 | {# Dimensions #} |
| 106 | {% if domain.dimensions %} |
| 107 | <section class="ph-section"> |
| 108 | <div class="ph-section-title"> |
| 109 | {{ icon("layers", 13) }} |
| 110 | Dimensions |
| 111 | <span class="ph-count">{{ domain.dimensions | length }}</span> |
| 112 | </div> |
| 113 | <p class="ph-section-desc"> |
| 114 | Each dimension is independently mergeable — two agents editing different |
| 115 | dimensions of the same snapshot never produce a conflict. |
| 116 | </p> |
| 117 | <div class="dd-dim-grid"> |
| 118 | {% for dim in domain.dimensions %} |
| 119 | {% set _icon_map = {'symbol': 'symbols', 'file': 'file-code', 'directory': 'folder', 'sequence': 'layers', 'harmony': 'music', 'structure': 'braces'} %} |
| 120 | <div class="dd-dim-card dd-dim-color-{{ loop.index0 % 8 }}"> |
| 121 | <div class="dd-dim-card__header"> |
| 122 | <span class="dd-dim-card__icon">{{ icon(_icon_map.get(dim.name, 'grid'), 14) }}</span> |
| 123 | <span class="dd-dim-card__name">{{ dim.name }}</span> |
| 124 | {% if dim.unit %}<span class="dd-dim-card__unit">{{ dim.unit }}</span>{% endif %} |
| 125 | </div> |
| 126 | {% if dim.description %}<p class="dd-dim-card__desc">{{ dim.description }}</p>{% endif %} |
| 127 | </div> |
| 128 | {% endfor %} |
| 129 | </div> |
| 130 | </section> |
| 131 | {% endif %} |
| 132 | |
| 133 | </div>{# /ph-content #} |
| 134 | |
| 135 | {# ── Sidebar — col 2: 1fr wide right ───────────────────────────────────── #} |
| 136 | <aside class="ph-sidebar"> |
| 137 | |
| 138 | {# Repos — wide grid needs the full right column #} |
| 139 | <section class="ph-section" id="dd-repos"> |
| 140 | <div class="ph-section-title"> |
| 141 | {{ icon("book-open", 13) }} |
| 142 | Public Repositories |
| 143 | <span class="ph-count">{{ repos_total }}</span> |
| 144 | </div> |
| 145 | {% if repos %} |
| 146 | <div class="rc-grid"> |
| 147 | {% for repo in repos %} |
| 148 | {% set enc = enrichments.get(repo.repo_id) if enrichments else none %} |
| 149 | {% include "musehub/partials/repo_card_enriched.html" %} |
| 150 | {% endfor %} |
| 151 | </div> |
| 152 | {% if repos_total > repos | length %} |
| 153 | <div class="dd-see-all"> |
| 154 | <a class="dd-hero-btn dd-hero-btn--ghost" href="/explore?domain={{ domain.scoped_id }}"> |
| 155 | See all {{ repos_total }} repositories |
| 156 | {{ icon("arrow-up-right", 11) }} |
| 157 | </a> |
| 158 | </div> |
| 159 | {% endif %} |
| 160 | {% else %} |
| 161 | <div class="dd-repos-empty"> |
| 162 | <div class="dd-repos-empty__icon"> |
| 163 | {{ icon("book-open", 32, "icon--light-stroke") }} |
| 164 | </div> |
| 165 | <p>No public repositories using this domain yet.</p> |
| 166 | </div> |
| 167 | {% endif %} |
| 168 | </section> |
| 169 | |
| 170 | <div class="ph-sidebar-section"> |
| 171 | <div class="ph-sidebar-heading">Install</div> |
| 172 | <p class="dd-sidebar-desc">Add this domain plugin to your Muse workspace.</p> |
| 173 | <div class="dd-terminal dd-terminal--compact"> |
| 174 | <div class="dd-terminal__chrome"> |
| 175 | <span class="dd-terminal__dot dd-terminal__dot--red"></span> |
| 176 | <span class="dd-terminal__dot dd-terminal__dot--yellow"></span> |
| 177 | <span class="dd-terminal__dot dd-terminal__dot--green"></span> |
| 178 | <button class="dd-copy-btn" data-copy-id="install-cmd" title="Copy">{{ icon("copy", 13) }}</button> |
| 179 | </div> |
| 180 | <pre class="dd-terminal__body" id="install-cmd">muse domains use {{ domain.scoped_id }}</pre> |
| 181 | </div> |
| 182 | </div> |
| 183 | |
| 184 | {% if domain.supported_commands %} |
| 185 | <div class="ph-sidebar-section"> |
| 186 | <div class="ph-sidebar-heading"> |
| 187 | {{ icon("terminal", 12) }} |
| 188 | CLI Commands |
| 189 | </div> |
| 190 | <div class="dd-terminal dd-terminal--compact"> |
| 191 | <div class="dd-terminal__chrome"> |
| 192 | <span class="dd-terminal__dot dd-terminal__dot--red"></span> |
| 193 | <span class="dd-terminal__dot dd-terminal__dot--yellow"></span> |
| 194 | <span class="dd-terminal__dot dd-terminal__dot--green"></span> |
| 195 | <span class="dd-terminal__title">muse</span> |
| 196 | <button class="dd-copy-btn" data-copy-id="cli-commands" title="Copy all">{{ icon("copy", 13) }}</button> |
| 197 | </div> |
| 198 | <pre class="dd-terminal__body" id="cli-commands">{% for cmd in domain.supported_commands %}$ {{ cmd }}{% if not loop.last %} |
| 199 | {% endif %}{% endfor %}</pre> |
| 200 | </div> |
| 201 | </div> |
| 202 | {% endif %} |
| 203 | |
| 204 | <div class="ph-sidebar-section"> |
| 205 | <div class="ph-sidebar-heading"> |
| 206 | {{ icon("zap", 12) }} |
| 207 | Agent & MCP |
| 208 | </div> |
| 209 | <p class="dd-sidebar-desc">Agents can discover and use this domain through the MuseHub MCP server — no configuration needed.</p> |
| 210 | <div class="dd-terminal dd-terminal--compact"> |
| 211 | <div class="dd-terminal__chrome"> |
| 212 | <span class="dd-terminal__dot dd-terminal__dot--red"></span> |
| 213 | <span class="dd-terminal__dot dd-terminal__dot--yellow"></span> |
| 214 | <span class="dd-terminal__dot dd-terminal__dot--green"></span> |
| 215 | <span class="dd-terminal__title">MCP</span> |
| 216 | <button class="dd-copy-btn" data-copy-id="mcp-snippet" title="Copy">{{ icon("copy", 13) }}</button> |
| 217 | </div> |
| 218 | <pre class="dd-terminal__body" id="mcp-snippet">// MCP tool — preferred for AI agents |
| 219 | musehub_read_domain(scoped_id="{{ domain.scoped_id }}") |
| 220 | |
| 221 | // REST API — for programmatic access |
| 222 | GET /api/domains/{{ domain.scoped_id }} |
| 223 | GET /api/domains/{{ domain.scoped_id }}/repos |
| 224 | |
| 225 | // MCP resource URI |
| 226 | muse://domains/{{ domain.author_slug }}/{{ domain.slug }} |
| 227 | |
| 228 | // Create a repo using this domain |
| 229 | musehub_create_repo( |
| 230 | name="my-project", |
| 231 | owner="myuser", |
| 232 | domain="{{ domain.scoped_id }}" |
| 233 | )</pre> |
| 234 | </div> |
| 235 | </div> |
| 236 | |
| 237 | {% if domain.kinds %} |
| 238 | <div class="ph-sidebar-section"> |
| 239 | <div class="ph-sidebar-heading">Kinds</div> |
| 240 | <div class="dd-artifact-list"> |
| 241 | {% for kind in domain.kinds %} |
| 242 | <span class="dd-artifact-badge">{{ kind }}</span> |
| 243 | {% endfor %} |
| 244 | </div> |
| 245 | </div> |
| 246 | {% endif %} |
| 247 | |
| 248 | {% if domain.manifest_hash %} |
| 249 | <div class="ph-sidebar-section"> |
| 250 | <div class="ph-sidebar-heading">Manifest Hash</div> |
| 251 | <p class="dd-sidebar-desc">Pin to this exact capability definition.</p> |
| 252 | <div class="dd-hash-block"> |
| 253 | <code class="dd-hash-code" id="manifest-hash">sha256:{{ domain.manifest_hash }}</code> |
| 254 | <button class="dd-hash-copy" data-copy-id="manifest-hash" title="Copy hash">{{ icon("copy", 12) }}</button> |
| 255 | </div> |
| 256 | </div> |
| 257 | {% endif %} |
| 258 | |
| 259 | <div class="ph-sidebar-section"> |
| 260 | <div class="ph-sidebar-heading">MCP Resource URI</div> |
| 261 | <div class="dd-hash-block"> |
| 262 | <code class="dd-hash-code" id="mcp-uri">muse://domains/{{ domain.author_slug }}/{{ domain.slug }}</code> |
| 263 | <button class="dd-hash-copy" data-copy-id="mcp-uri" title="Copy URI">{{ icon("copy", 12) }}</button> |
| 264 | </div> |
| 265 | </div> |
| 266 | |
| 267 | <div class="ph-sidebar-section"> |
| 268 | <div class="ph-sidebar-heading">Details</div> |
| 269 | <dl class="dd-meta-list"> |
| 270 | <dt>Author</dt><dd>@{{ domain.author_slug }}</dd> |
| 271 | <dt>Version</dt><dd>{{ domain.version }}</dd> |
| 272 | <dt>Viewer</dt><dd>{{ domain.viewer_type | replace("_", " ") | title }}</dd> |
| 273 | {% if domain.merge_semantics %}<dt>Merge</dt><dd>{{ domain.merge_semantics | upper }}</dd>{% endif %} |
| 274 | {% if domain.created_at %}<dt>Registered</dt><dd>{{ domain.created_at[:10] }}</dd>{% endif %} |
| 275 | </dl> |
| 276 | </div> |
| 277 | |
| 278 | </aside> |
| 279 | |
| 280 | </div>{# /ph-body #} |
| 281 | |
| 282 | </div>{# /dd-page #} |
| 283 | {% endblock %} |
File History
2 commits
sha256:1dd27e6d5c24550177b01b0a171e8375c07cf046b549e7683364706b6522d3bc
docs(#139): mark all 11 checklist items resolved, document …
Sonnet 5
12 days ago
sha256:649011bedd713e22f7dca4c4be94bdefbf3b10950d9fc80235928d0b0b823be8
docs: track issue #139 (two-column app-shell refactor) plan…
Sonnet 5
12 days ago