{ if (detailsEl.hasAttribute("open")) { detailsEl.removeAttribute("open"); } }} > Tools ({activeToolCount})
Available tools {#if isHuggingChat} {/if}
{#if $page.data.enableCommunityTools} new Browse community tools ({$page.data.communityToolCount ?? 0}) {/if} {#each tools as tool} {@const isChecked = $settings?.tools?.includes(tool._id)}
{#if tool.type === "community"} { await settings.instantSet({ tools: $settings?.tools?.filter((t) => t !== tool._id) ?? [], }); }} /> {:else} { if (isChecked) { await settings.instantSet({ tools: ($settings?.tools ?? []).filter((t) => t !== tool._id), }); } else { await settings.instantSet({ tools: [...($settings?.tools ?? []), tool._id], }); } }} /> {/if} {#if tool.type === "community"} {/if}
{/each}