History

{history.length} saved
{#if history.length > 0} {/if}
{#if filtered.length === 0} {:else}
{#each visibleItems as { item, top, height, preview } (item.id)}
toggleExpand(item.id)} onkeydown={(e) => { if (e.key === "Enter" || e.key === " ") { e.preventDefault(); toggleExpand(item.id); } }} role="button" tabindex="0" aria-expanded={expandedId === item.id} > {#if item.audioPath} {:else}
{/if}

{preview?.text || compactPreviewText(item)}

{#if item.duration} {formatDuration(item.duration)} {/if} {#if item.source && item.source.toLowerCase().includes("file")} {item.date}
{#if expandedId === item.id}
{#if item.audioPath && playingId === item.id}
{formatTime(currentTime)} / {formatTime(duration)} e.stopPropagation()} />
{#each PLAYBACK_SPEEDS as speed} {/each}
{/if}

{item.text}

{#if item.audioPath && item.segments && item.segments.length > 0} {/if}
{/if}
{/each}
{/if}