{#if filteredItems.length > 0 || query.startsWith('http')} {#each filteredItems as item, idx} {#if idx === 0 || item?.type !== items[idx - 1]?.type}