Skip to content

Commit 5ee1a89

Browse files
committed
fix: separate taps from CLI tools in package editor
Tap entries (type: 'tap') were incorrectly grouped under CLI tools. Now displayed in their own TAPS section with purple styling, matching the tap badge color used elsewhere.
1 parent 1ece4d8 commit 5ee1a89

File tree

1 file changed

+20
-1
lines changed

1 file changed

+20
-1
lines changed

src/lib/components/PackageManager.svelte

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,12 +88,14 @@
8888
const apps: string[] = [];
8989
const cli: string[] = [];
9090
const npm: string[] = [];
91+
const taps: string[] = [];
9192
for (const [pkg, type] of selectedPackages) {
9293
if (type === 'cask') apps.push(pkg);
9394
else if (type === 'npm') npm.push(pkg);
95+
else if (type === 'tap') taps.push(pkg);
9496
else cli.push(pkg);
9597
}
96-
return { apps, cli, npm };
98+
return { apps, cli, npm, taps };
9799
});
98100
99101
const presets = [
@@ -281,6 +283,23 @@
281283
</div>
282284
{/if}
283285

286+
{#if grouped.taps.length > 0}
287+
<div class="group">
288+
<div class="group-label">
289+
<span class="group-dot" style="background: #a855f7"></span>
290+
TAPS
291+
<span class="group-count">{grouped.taps.length}</span>
292+
</div>
293+
<div class="group-tags">
294+
{#each grouped.taps as pkg}
295+
<button class="tag tap" onclick={() => togglePackage(pkg, 'tap')}>
296+
{pkg}<span class="tag-x">&times;</span>
297+
</button>
298+
{/each}
299+
</div>
300+
</div>
301+
{/if}
302+
284303
{#if selectedPackages.size === 0}
285304
<div class="empty-packages">No packages selected. Choose a preset or search above.</div>
286305
{/if}

0 commit comments

Comments
 (0)