{#if embeds && Array.isArray(embeds) && embeds.length > 0}
{attributes.name}
{#each embeds as embed, idx}
{/each}
{:else}
{#if open}
{#if args}
{$i18n.t('Input')}
{#if parsedArgs}
{#each Object.entries(parsedArgs) as [key, value]}
{key}
{typeof value === 'object' ? JSON.stringify(value) : value}
{/each}
{:else}
{/if}
{/if}
{#if isDone && result}
{/if}
{/if}
{/if}
{#if isDone}
{#if typeof files === 'object'}
{#each files ?? [] as file, idx}
{#if typeof file === 'string'}
{#if file.startsWith('data:image/')}
{/if}
{:else if typeof file === 'object'}
{#if (file.type === 'image' || (file?.content_type ?? '').startsWith('image/')) && file.url}
{/if}
{/if}
{/each}
{/if}
{/if}