{#if show_share_button && value !== null && value.length > 0}
{/if}
{#if value !== null && value.length > 0} {#each value as message_pair, i} {#each message_pair as message, j} {#if message !== null}
{#if avatar_images[j] !== null}
{/if}
handle_select(i, j, message)} on:keydown={(e) => { if (e.key === "Enter") { handle_select(i, j, message); } }} dir={rtl ? "rtl" : "ltr"} aria-label={(j == 0 ? "user" : "bot") + "'s message: " + (typeof message === "string" ? message : `a file of type ${message.file?.mime_type}, ${ message.file?.alt_text ?? message.file?.orig_name ?? "" }`)} > {#if typeof message === "string"}
{:else if message !== null && message.file?.mime_type?.includes("audio")}
{:else if message !== null && message.file?.mime_type?.includes("video")}
{:else if message !== null && message.file?.mime_type?.includes("image")}
{:else if message !== null && message.file?.url !== null}
{message.file?.orig_name || message.file?.path}
{/if}
{#if (likeable && j !== 0) || (show_copy_button && message && typeof message === "string")}
{#if likeable && j == 1}
handle_like(i, j, message, selected)} /> {/if} {#if show_copy_button && message && typeof message === "string"}
{/if}
{/if}
{/if} {/each} {/each} {#if pending_message}
{/if} {:else if placeholder !== null}
{/if}