{ dispatch('update', e.detail); }} on:code={(e) => { const { lang } = e.detail; console.log('code', lang); if (['html', 'svg'].includes(lang) && !$mobile) { showArtifacts.set(true); showControls.set(true); } }} />
{#if floatingButtons}
{ const selection = window.getSelection(); dispatch('explain', selection.toString()); // Clear selection selection.removeAllRanges(); buttonsContainerElement.style.display = 'none'; }} >
Explain
{/if}