{#if state !== "collapsed"} { if (onclose !== undefined) { onclose(); } else { state = "collapsed"; } }} {disableAttachments} submit={async ({ comment, embeds }) => { try { state = "submit"; await submit(comment, Array.from(embeds.values())); } finally { state = "collapsed"; } }} /> {:else}
{ e.preventDefault(); e.stopPropagation(); state = "expanded"; if (onexpand !== undefined) { onexpand(); } }}>
{placeholder}
{/if}