Static preview. Server-backed interactions are available only in a local checkout.

Editor Preview Metadata

The editor_preview converter maps the trusted :spark: symbol and enables source-line attributes for editor scroll synchronization.

'symbols' => [
    'spark' => '<span class="carve-symbol">✦</span>',
],
'source_lines' => true,

Carve source

# Source-aware preview :spark:

Each rendered block carries its original 1-based line number, while
the configured symbol is replaced with trusted presentation HTML.

- Click a preview block
- Scroll the editor to its `data-source-line`

Rendered preview

Source-aware preview

Each rendered block carries its original 1-based line number, while the configured symbol is replaced with trusted presentation HTML.

  • Click a preview block
  • Scroll the editor to its data-source-line

Generated HTML

<section id="Source-aware-preview">
  <h1 data-source-line="1">Source-aware preview <span class="carve-symbol" aria-label="spark">✦</span></h1>
  <p data-source-line="3">Each rendered block carries its original 1-based line number, while
the configured symbol is replaced with trusted presentation HTML.</p>
  <ul data-source-line="6">
    <li data-source-line="6">Click a preview block</li>
    <li data-source-line="7">Scroll the editor to its <code>data-source-line</code></li>
  </ul>
</section>

Security boundary: symbol values are trusted configuration and are inserted as raw HTML. Never populate them from user content.