block / block/buzz

Desktop: channel browser renders every channel with '#' — private channels are indistinguishable from open ones (sidebar shows a lock)

Open Beginner friendly
#6,120 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Rust
Stars
32.7k
Forks
4.3k
Avg merge
1d 13h
Merged PRs (30d)
253

Description

## Summary

In the desktop channel browser ("Add channel" / browse dialog), every channel row is rendered with a hardcoded `#` prefix. `channel.visibility` is never read for presentation, so a **private** channel looks exactly like an **open** one. The sidebar, by contrast, renders a lock for private channels — so the same channel shows two different affordances in two places in the same window.

Checked against `main` @ `f956e6fe0`.

## Evidence

`desktop/src/features/channels/ui/ChannelBrowserDialog.tsx:792-798` — the row component `ChannelCard` emits a literal `#`:

```tsx



#


{channel.name}


```

`channel.visibility` appears exactly once in that file, in the filter and not in the rendering (`:183`):

```tsx
(channel.archivedAt ? channel.isMember : channel.visibility === "open" || channel.isMember)
```

The sidebar gets it right — `desktop/src/features/sidebar/ui/SidebarSection.tsx:242-244`:

```tsx
if (channel.visibility === "private") {
return ;
}
```

Note the browser also uses `#` for forum channels, while the sidebar uses `FileText` (`SidebarSection.tsx:246-248`) — same root cause: the row does not consult the channel's type or visibility at all.

## Reproduce

1. Create or join a private channel and a public channel in the same community.
2. Open the channel browser (Add channel).
3. Both rows show `#`. Nothing marks the private one as private.
4. The sidebar shows a lock on the private channel.

## Expected

The browser row uses the same icon logic as the sidebar: lock for `visibility === "private"`, `FileText` for forum channels, `#` otherwise. Extracting the existing sidebar helper would keep the two views from drifting again.

## Note on the filter

The filter itself is correct — a non-open channel only appears when `isMember` is true, so this is a labeling defect, not a disclosure of private channels the viewer is not in.

Contributor guide

Open the contributing guide

Research direction

Start by reading ChannelCard in desktop/src/features/channels/ui/ChannelBrowserDialog.tsx around lines 792-798, then compare its icon rendering with SidebarSection.tsx around lines 242-248. The browser is done when private channels show a lock, forum channels show FileText, and other channels retain #, matching the sidebar.

Written by the indexing model from the issue text.

Assessment

Tech stack
react, typescript
Domain
frontend
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Active
Clarity
Clearly specified
Newbie friendliness
84/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.