Skip to content

feat(ai): configurable channel blocklist dashboard UI#256

Merged
BillChirico merged 1 commit intomainfrom
feat/issue-180
Mar 7, 2026
Merged

feat(ai): configurable channel blocklist dashboard UI#256
BillChirico merged 1 commit intomainfrom
feat/issue-180

Conversation

@BillChirico
Copy link
Collaborator

Summary

The backend isChannelBlocked() and config support were already in place. This PR adds the dashboard description text that was missing from the blocked channels selector.

The backend reads config.ai.blockedChannelIds (already wired in messageCreate and triage). The dashboard ChannelSelector was merged via #253. This PR closes the gap with proper help text.

Closes #180

Add the helper text 'The bot will not read messages, respond, or run
triage in these channels' below the Blocked Channels label, matching
the spec in Issue #180.

Closes #180
Copilot AI review requested due to automatic review settings March 7, 2026 16:23
@BillChirico BillChirico added this to the v0.1.0 - "Big Boy MVP" milestone Mar 7, 2026
@BillChirico BillChirico added priority: medium Medium priority type: feature New feature scope: ai AI-related features labels Mar 7, 2026
@github-project-automation github-project-automation bot moved this to Backlog in Volvox.Bot Mar 7, 2026
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Mar 7, 2026

📝 Walkthrough

Summary by CodeRabbit

  • Style
    • Restructured the blocked channels configuration section in the AI Chat settings editor to improve markup organization and styling flexibility. The descriptive text now appears in a dedicated paragraph element below the input field, enhancing semantic HTML structure, keyboard navigation support, and providing better visual presentation control options.

Walkthrough

The pull request restructures the DOM layout of the blocked channels UI in the dashboard config editor by wrapping the label and input field in a container div and moving the descriptive text into a separate paragraph element below.

Changes

Cohort / File(s) Summary
AI Config UI Structure
web/src/components/dashboard/config-editor.tsx
Restructured blocked channels input markup by wrapping the label and input in a div container and relocating the descriptive text to a dedicated paragraph element beneath the label.

Possibly related PRs

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Linked Issues check ⚠️ Warning The PR partially addresses issue #180 by adding dashboard UI help text for the blocked channels selector, but does not implement all requirements like config schema changes, backend validation, or triage/AI module checks. Complete the remaining issue #180 objectives: implement blockedChannels in config schema, add backend validation, check blocked channels in triage and AI modules, and add tests.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately describes the main change: adding dashboard UI for the configurable AI channel blocklist, which aligns with the PR's objective of adding missing dashboard description text.
Description check ✅ Passed The description clearly explains the change: adding missing dashboard description text for the blocked channels selector, with context about existing backend support and related PR #253.
Out of Scope Changes check ✅ Passed The change is narrowly scoped to adding dashboard UI description text for the already-merged ChannelSelector component; no out-of-scope modifications are present.
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
  • 📝 Generate docstrings (stacked PR)
  • 📝 Generate docstrings (commit on current branch)
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch feat/issue-180
  • 🛠️ Publish Changes: Commit on current branch
  • 🛠️ Publish Changes: Create PR

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@coveralls
Copy link

Coverage Status

coverage: 87.484%. remained the same
when pulling 9a0d093 on feat/issue-180
into aab414b on main.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
web/src/components/dashboard/config-editor.tsx (1)

1033-1049: ⚠️ Potential issue | 🟠 Major

Complete the blocked-channel hint and bind it to the selector.

This copy still misses the allowed-vs-blocked precedence called out in issue #180, so admins won't learn what happens when both lists are configured. Also, now that the help text sits outside the <label>, it should be exposed via the selector's accessible description.

Suggested change
-                  <div className="space-y-2">
+                  <div className="space-y-2">
                     <label htmlFor="ai-blocked-channels" className="block">
                       <span className="text-sm font-medium">Blocked Channels</span>
                     </label>
-                    <p className="text-xs text-muted-foreground">
-                      The bot will not read messages, respond, or run triage in these channels.
+                    <p id="ai-blocked-channels-hint" className="text-xs text-muted-foreground">
+                      If allowed channels are configured, AI only runs in those channels. Any
+                      channel selected here is always excluded from reading, replies, and triage.
                     </p>
                     <ChannelSelector
                       id="ai-blocked-channels"
+                      aria-describedby="ai-blocked-channels-hint"
                       guildId={guildId}
                       selected={(draftConfig.ai?.blockedChannelIds ?? []) as string[]}
                       onChange={updateAiBlockedChannels}
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@web/src/components/dashboard/config-editor.tsx` around lines 1033 - 1049, The
help text for blocked channels is missing the allowed-vs-blocked precedence and
is not exposed to assistive tech; update the copy to mention that allowed
(whitelisted) channels take precedence over blocked channels (e.g., "If a
channel is both allowed and blocked, allowed takes precedence") and bind the
help paragraph to the ChannelSelector by giving the paragraph an id (e.g.,
"ai-blocked-channels-desc") and passing that id via the ChannelSelector's
aria-describedby prop; ensure ChannelSelector usage (id="ai-blocked-channels",
selected={(draftConfig.ai?.blockedChannelIds ?? []) as string[]},
onChange={updateAiBlockedChannels}, disabled={saving}) is unchanged except for
adding aria-describedby and the revised help text.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Outside diff comments:
In `@web/src/components/dashboard/config-editor.tsx`:
- Around line 1033-1049: The help text for blocked channels is missing the
allowed-vs-blocked precedence and is not exposed to assistive tech; update the
copy to mention that allowed (whitelisted) channels take precedence over blocked
channels (e.g., "If a channel is both allowed and blocked, allowed takes
precedence") and bind the help paragraph to the ChannelSelector by giving the
paragraph an id (e.g., "ai-blocked-channels-desc") and passing that id via the
ChannelSelector's aria-describedby prop; ensure ChannelSelector usage
(id="ai-blocked-channels", selected={(draftConfig.ai?.blockedChannelIds ?? [])
as string[]}, onChange={updateAiBlockedChannels}, disabled={saving}) is
unchanged except for adding aria-describedby and the revised help text.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

Run ID: 08960a04-71e0-457f-8f33-87c23ece0e81

📥 Commits

Reviewing files that changed from the base of the PR and between aab414b and 9a0d093.

📒 Files selected for processing (1)
  • web/src/components/dashboard/config-editor.tsx
📜 Review details
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (2)
  • GitHub Check: Greptile Review
  • GitHub Check: Docker Build Validation
🧰 Additional context used
📓 Path-based instructions (2)
**/*.{js,mjs,jsx,ts,tsx}

📄 CodeRabbit inference engine (AGENTS.md)

**/*.{js,mjs,jsx,ts,tsx}: Use single quotes for strings in code, double quotes only allowed in JSON files
Always end statements with semicolons
Use 2-space indentation, enforced by Biome

Files:

  • web/src/components/dashboard/config-editor.tsx
web/**/*.{ts,tsx}

📄 CodeRabbit inference engine (AGENTS.md)

Next.js 16 web dashboard uses App Router with Discord OAuth2 authentication, dark/light theme support, and mobile-responsive design

Files:

  • web/src/components/dashboard/config-editor.tsx
🧠 Learnings (4)
📚 Learning: 2026-03-07T15:34:56.495Z
Learnt from: CR
Repo: VolvoxLLC/volvox-bot PR: 0
File: CLAUDE.md:0-0
Timestamp: 2026-03-07T15:34:56.495Z
Learning: Applies to web/src/components/dashboard/config-workspace/**/*.{js,jsx,ts,tsx} : Refactor config feature presentation to use reusable `SettingsFeatureCard` pattern with structure: header + master toggle + Basic/Advanced blocks

Applied to files:

  • web/src/components/dashboard/config-editor.tsx
📚 Learning: 2026-03-07T15:34:56.495Z
Learnt from: CR
Repo: VolvoxLLC/volvox-bot PR: 0
File: CLAUDE.md:0-0
Timestamp: 2026-03-07T15:34:56.495Z
Learning: Applies to web/src/components/dashboard/config-workspace/**/*.{js,jsx,ts,tsx} : Web dashboard config editor must use category workspace navigation with categories: `AI & Automation`, `Onboarding & Growth`, `Moderation & Safety`, `Community Tools`, `Support & Integrations` located in `web/src/components/dashboard/config-workspace/`

Applied to files:

  • web/src/components/dashboard/config-editor.tsx
📚 Learning: 2026-03-07T15:34:56.495Z
Learnt from: CR
Repo: VolvoxLLC/volvox-bot PR: 0
File: CLAUDE.md:0-0
Timestamp: 2026-03-07T15:34:56.495Z
Learning: Applies to web/src/components/dashboard/config-workspace/**/*.{js,jsx,ts,tsx} : Config editor save contract must maintain: global save/discard, diff-modal confirmation, per-section PATCH batching, and partial-failure behavior

Applied to files:

  • web/src/components/dashboard/config-editor.tsx
📚 Learning: 2026-03-07T15:34:56.495Z
Learnt from: CR
Repo: VolvoxLLC/volvox-bot PR: 0
File: CLAUDE.md:0-0
Timestamp: 2026-03-07T15:34:56.495Z
Learning: Applies to web/src/components/dashboard/config-workspace/**/*.{js,jsx,ts,tsx} : Config editor must implement metadata-driven config search with cross-category quick jump, focus/scroll targeting, and auto-open advanced sections when search hits advanced controls

Applied to files:

  • web/src/components/dashboard/config-editor.tsx

@github-project-automation github-project-automation bot moved this from Backlog to In Review in Volvox.Bot Mar 7, 2026
@greptile-apps
Copy link

greptile-apps bot commented Mar 7, 2026

Greptile Summary

This PR successfully closes the UI gap for the AI blocked channels feature by adding descriptive help text and ensuring correct HTML semantics:

Changes Made:

  • Adds clear description: "The bot will not read messages, respond, or run triage in these channels."
  • Fixes HTML structure: The <ChannelSelector> is no longer wrapped inside a <label> element (which was semantically incorrect for this use case), and the label now correctly points to the selector's trigger button via htmlFor/id attributes
  • The ChannelSelector component properly applies the id prop to its internal trigger button, ensuring the label-button association works correctly

The implementation aligns with the existing backend support for config.ai.blockedChannelIds and correctly wires the UI to work with the configured feature. The change is minimal, focused, and UI-only with no new logic paths.

Confidence Score: 5/5

  • Safe to merge — minimal UI-only changes with correct HTML semantics and no new logic paths.
  • The PR introduces only descriptive UI text and corrects the HTML structure (label association with the ChannelSelector button). The change is focused, well-contained to a single component, and integrates with already-implemented backend configuration support. No new logic, no breaking changes, no edge cases.
  • No files require special attention

Last reviewed commit: 9a0d093

@BillChirico BillChirico merged commit 89dd4c0 into main Mar 7, 2026
20 of 21 checks passed
@BillChirico BillChirico deleted the feat/issue-180 branch March 7, 2026 16:44
@github-project-automation github-project-automation bot moved this from In Review to Done in Volvox.Bot Mar 7, 2026
@github-actions
Copy link
Contributor

github-actions bot commented Mar 7, 2026

🧹 Preview Environment Cleaned Up

The Railway preview environment for this PR has been removed.

Environment: pr-256

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

priority: medium Medium priority scope: ai AI-related features type: feature New feature

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

feat: configurable AI channel blocklist

3 participants