+ {#if strategy === 'static' && staticUrl}
+ {#if !imgError}
+

imgLoaded = true} onerror={() => imgError = true} />
+ {:else}
+
+
+ {glob.t('vcen.editor.view.imgLoadError')}
+ {staticUrl}
+
+ {/if}
+
+ {:else if strategy === 'dynamic' && resolvedUrl}
+ {#if !imgError}
+

imgLoaded = true} onerror={() => imgError = true} />
+ {:else}
+
+
+ {glob.t('vcen.editor.view.imgLoadError')}
+ {resolvedUrl}
+
+ {/if}
+ {#if resolution?.hasFallback}
+
fallback
+ {/if}
+
+ {:else if strategy === 'layers' && resolvedLayers.length > 0}
+ {#each resolvedLayers as layer, li (li)}
+ {#if !hiddenLayers.has(li)}
+

+ {/if}
+ {/each}
+ {#if resolution?.hasFallback}
+
fallback
+ {/if}
+
+ {:else if strategy === 'layers' && layers.length === 0}
+
+
+
{glob.t('vcen.editor.view.noLayers')}
+
+
+ {:else if strategy === 'dynamic'}
+
+
+ {#if dynTpl}
+
{dynTpl}
+ {:else}
+
{glob.t('vcen.editor.view.noTemplate')}
+ {/if}
+
+
+ {:else if strategy === 'api'}
+ {#if apiEp && !imgError}
+

imgLoaded = true} onerror={() => imgError = true} />
+ {:else if apiEp && imgError}
+
+
+ {glob.t('vcen.editor.view.imgLoadError')}
+ {apiEp}
+
+ {:else}
+
+
+
{glob.t('vcen.editor.view.noEndpoint')}
+
+ {/if}
+
+ {:else if strategy === 'd3'}
+
+
+ {#if d3Model}
+
{d3Model}
+ {:else}
+
{glob.t('vcen.editor.view.noModel')}
+ {/if}
+
+
+ {:else}
+
+
+
{pickingPos ? glob.t('vcen.editor.hotspot.clickToPosition') : glob.t('vcen.editor.view.noImage')}
+
+ {/if}
+
+
+ {#each (view.hotspots ?? []) as marker (marker.id)}
+ {@const isActive = activeHotspotId === marker.id}
+ {@const mX = typeof marker.posX === 'number' ? marker.posX : parseFloat(String(marker.posX)) || 0}
+ {@const mY = typeof marker.posY === 'number' ? marker.posY : parseFloat(String(marker.posY)) || 0}
+ {@const size = (marker.radius ?? 8) * 2}
+
+ {/each}
+
+
+ {#if showLayersPanel}
+
+
+
e.stopPropagation()}
+ >
+
+
+
+ {#if layersPanelOpen}
+
+ {#if resolvedLayers.length > 0}
+
+ {#each sortedLayerIndices as li (li)}
+ {@const layer = resolvedLayers[li]}
+ {@const hidden = hiddenLayers.has(li)}
+
+ {/each}
+ {:else}
+
+ {#each [...layers].sort((a, b) => (b.zIndex ?? 0) - (a.zIndex ?? 0)) as layer, li (li)}
+
+
+
z{layer.zIndex ?? 0}
+
{layer.attId || '—'}
+ {#if layer.condition}
+
if
+ {/if}
+
+ {/each}
+ {/if}
+
+ {/if}
+
+ {/if}
+
+
+
+ {view.width || '?'} × {view.height || '?'} px
+ {#if pickingPos}
+ {glob.t('vcen.editor.hotspot.clickToPosition')}
+ {/if}
+
+ {#if resolvedUrl || (strategy === 'static' && staticUrl)}
+
{resolvedUrl || staticUrl}
+ {/if}
+