{#if !webcam_accessed}
access_webcam()} />
{:else}
{#if mode === "video" || streaming} {#if streaming && stream_state === "waiting"}
{i18n("audio.waiting")}
{:else if (streaming && stream_state === "open") || (!streaming && recording)}
{i18n("audio.stop")}
{:else}
{i18n("audio.record")}
{/if} {:else}
{/if}
{#if !recording}
(options_open = true)} aria-label="select input source" >
{/if}
{#if options_open && selected_device}
(options_open = false)} >
{#if available_video_devices.length === 0}
{i18n("common.no_devices")}
{:else} {#each available_video_devices as device}
{device.label}
{/each} {/if}
{/if} {/if}