{#if loading}

Review to Ready

Loading slab…

{:else if loadError}

Review to Ready

{:else}

Review to Ready

Length
{fmt1(capture?.lengthIn ?? slab?.length_in ?? 0)}″
Thickness
{fmt1(capture?.thicknessIn ?? slab?.thickness_in ?? 0)}″
Sqft / Bdft
{fmt2(capture?.sqft ?? slab?.sqft ?? 0)} / {fmt2(capture?.bdft ?? slab?.bdft ?? 0)}
{#if photosLoaded && photos.length}

Tap a photo to keep or remove it · drag to reorder · leftmost photo = primary

{#each photos as p, i (p.id)}
toggleKeep(p.id)} on:keydown={(e) => { if (e.key === 'Enter' || e.key === ' ') { e.preventDefault(); toggleKeep(p.id); } }} on:dragstart={(e) => onDragStart(e, i)} on:dragover={onDragOver} on:drop={(e) => onDrop(e, i)} > {roleLabel(p.role)} {#if p.id === primaryId} PRIMARY {/if} {#if p.required} REQUIRED {/if}
{/each}
{#if lineupMissing.length} {/if} {#if persistError}{/if}
{/if} {#if settings?.inference_enabled}
{#if aiNote}

{aiNote}

{/if}
{/if}
{#if primaryOpts.length}
Primary wood category drives title
{#each primaryOpts as o (o.id)} {/each}

Primary selects the title & short-description pattern (METADATA-85). Secondary categories feed the description. Default = first selected.

{/if}
(figureIds = toggleMulti(figureIds, id))} on:commit={commitReview} />
(figTagIds = toggleMulti(figTagIds, id))} on:commit={commitReview} />
(featTagIds = toggleMulti(featTagIds, id))} on:commit={commitReview} />
{#if canCreateDesc}
{/if} {#if genError}{/if} {#if createError}{/if}
{#if sku && !/^[A-Za-z0-9-]{3,24}$/.test(sku)}

SKU must be 3–24 alphanumerics or hyphens.

{/if}
{#if reviewBusy}
Checking readiness…
{:else if review}
{ready() && lineupValid ? 'Ready to publish' : `Not ready — ${[ ...review.missing, ...lineupMissing.map(roleLabel), ].length} field${[...review.missing, ...lineupMissing.map(roleLabel)].length === 1 ? '' : 's'} remaining`}
{#if !(ready() && lineupValid)}

Missing: {[...review.missing, ...lineupMissing.map(roleLabel)].join(', ')}

{/if} {/if} {#if reviewError}{/if}
{/if}