Skip to content

Conversation

@sfc-gh-nbellante
Copy link
Contributor

@sfc-gh-nbellante sfc-gh-nbellante commented Jan 10, 2026

Describe your changes

Changed the microphone icon in the ChatInput component from the filled Mic icon to the outlined MicNone icon, updating the import from @emotion-icons/material-rounded to @emotion-icons/material-outlined.

Testing Plan

  • Updated snapshot tests for the chat input component with the new icon appearance
  • Verified the microphone icon displays correctly across different browsers (Chrome, Firefox, WebKit)
  • Confirmed the icon appears properly in both light and dark themes

Contribution License Agreement

By submitting this pull request you agree that all contributions to this project are made under the Apache 2.0 license.

@snyk-io
Copy link
Contributor

snyk-io bot commented Jan 10, 2026

Snyk checks have passed. No issues have been found so far.

Status Scanner Critical High Medium Low Total (0)
Open Source Security 0 0 0 0 0 issues
Licenses 0 0 0 0 0 issues

💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse.

@github-actions
Copy link
Contributor

github-actions bot commented Jan 10, 2026

✅ PR preview is ready!

Name Link
📦 Wheel file https://core-previews.s3-us-west-2.amazonaws.com/pr-13553/streamlit-1.52.2-py3-none-any.whl
📦 @streamlit/component-v2-lib Download from artifacts
🕹️ Preview app pr-13553.streamlit.app (☁️ Deploy here if not accessible)

Copy link
Contributor Author

This stack of pull requests is managed by Graphite. Learn more about stacking.

@sfc-gh-nbellante sfc-gh-nbellante added security-assessment-completed Security assessment has been completed for PR impact:users PR changes affect end users change:chore PR contains maintenance or housekeeping change labels Jan 10, 2026
@sfc-gh-nbellante sfc-gh-nbellante changed the title fix: use outlined mic icon in chat input [chore] Switch Mic icon from material-rounded to material-outlined package Jan 10, 2026
@sfc-gh-nbellante sfc-gh-nbellante added the ai-review If applied to PR or issue will run AI review workflow label Jan 11, 2026
@github-actions github-actions bot removed the ai-review If applied to PR or issue will run AI review workflow label Jan 11, 2026
@github-actions
Copy link
Contributor

Summary

This PR makes a simple visual change to the ChatInput component by switching the Mic icon import from @emotion-icons/material-rounded to @emotion-icons/material-outlined. This changes the microphone icon style from a rounded/filled appearance to an outlined appearance.

Code Quality

The change is minimal and straightforward:

import { Mic } from "@emotion-icons/material-outlined"

Positive observations:

  • The change follows an existing pattern in the codebase. The AudioInputActionButtons.tsx component already imports Mic from @emotion-icons/material-outlined, so this PR actually brings consistency across components that use the microphone icon.
  • Clean import organization - the Mic import is now in its own import statement separate from the material-rounded icons.

Design note: The codebase uses a mixed icon style strategy where different icon packages are used for different purposes. The Mic icon being outlined appears to be the intended design choice for audio input components.

Test Coverage

Existing coverage is adequate:

  • The ChatInput.test.tsx file contains comprehensive unit tests covering functionality, state management, keyboard interactions, file uploads, and audio recording lifecycle.
  • The st_chat_input_test.py E2E test file includes extensive visual snapshot tests that will capture the icon style change:
    • st_chat_input-with_audio
    • st_chat_input-audio_only
    • st_chat_input-audio_disabled
    • st_chat_input-column_audio
    • st_chat_input-column_audio_with_files
    • st_chat_input-mic_permission_denied
    • st_chat_input-recording_error
    • And many more audio-related snapshots

Note: The visual snapshot tests will require baseline updates since the icon style is changing. This is expected and CI will flag the snapshots that need to be regenerated. The PR author should ensure snapshot baselines are updated as part of this PR.

Backwards Compatibility

No breaking changes. This is a purely visual change that:

  • Does not modify any APIs
  • Does not change component behavior
  • Does not affect props or state management
  • Does not require any migration for users

Users may notice the microphone icon looks slightly different (outlined vs rounded), but this is a minor visual refinement that shouldn't impact any functionality.

Security & Risk

Very low risk. The change:

  • Only affects icon styling
  • Does not introduce any new dependencies (both icon packages are already in use)
  • Has no security implications
  • Cannot cause functional regressions

Recommendations

  1. Ensure snapshot baselines are updated: The E2E visual snapshot tests will fail until the new baselines reflecting the outlined mic icon are committed. Please regenerate and commit the updated snapshot images.

  2. Optional - Verify consistency: Consider verifying that the outlined mic icon visually aligns well with the surrounding UI elements (send button, file upload button) at various viewport sizes. The existing snapshot tests should cover this, but a quick manual verification wouldn't hurt.

Verdict

APPROVED: This is a low-risk, purely visual change that improves consistency by aligning the ChatInput component's mic icon with the existing pattern used in AudioInputActionButtons.tsx. The only action needed is to update the visual snapshot baselines that will be flagged by CI.


This is an automated AI review. Please verify the feedback and use your judgment.

@sfc-gh-nbellante sfc-gh-nbellante force-pushed the feat/chat-input-icons-v2 branch 3 times, most recently from 68a33de to d3e05b7 Compare January 11, 2026 20:43
@github-actions
Copy link
Contributor

github-actions bot commented Jan 11, 2026

📉 Frontend coverage change detected

The frontend unit test (vitest) coverage has decreased by 0.0000%

  • Current PR: 86.5900% (12826 lines, 1719 missed)
  • Latest develop: 86.5900% (12826 lines, 1719 missed)

✅ Coverage change is within normal range.

📊 View detailed coverage comparison

@sfc-gh-nbellante sfc-gh-nbellante force-pushed the feat/chat-input-icons-v2 branch from 090af58 to 5a74fd6 Compare January 11, 2026 21:36
@sfc-gh-nbellante sfc-gh-nbellante changed the title [chore] Switch Mic icon from material-rounded to material-outlined package [chore] Switch Mic icon Jan 12, 2026
@sfc-gh-nbellante sfc-gh-nbellante changed the title [chore] Switch Mic icon [polish] Replace Mic icon with MicNone icon in st.chat_input Jan 12, 2026
@sfc-gh-nbellante sfc-gh-nbellante added the ai-review If applied to PR or issue will run AI review workflow label Jan 12, 2026
@github-actions github-actions bot removed the ai-review If applied to PR or issue will run AI review workflow label Jan 12, 2026
@github-actions
Copy link
Contributor

Summary

This PR makes a simple visual change to the st.chat_input widget by replacing the filled Mic icon (from @emotion-icons/material-rounded) with the outlined MicNone icon (from @emotion-icons/material-outlined). This is a purely cosmetic change that updates the microphone button appearance when audio recording is enabled.

Changes:

  • frontend/lib/src/components/widgets/ChatInput/ChatInput.tsx: Changed the icon import and usage from Mic to MicNone
  • 32 e2e snapshot files: Updated to reflect the new icon appearance

Code Quality

The code changes are clean and minimal:

import { MicNone } from "@emotion-icons/material-outlined"
<Icon
  content={MicNone}
  size="xl"
  color="inherit"
/>

Positive observations:

  • The import uses @emotion-icons/material-outlined, which is already a dependency in the frontend package ("@emotion-icons/material-outlined": "^3.14.0") and is used in 21 other files across the codebase
  • The change is focused and doesn't introduce any unnecessary modifications
  • The icon usage pattern follows existing conventions in the component

No issues identified.

Test Coverage

The test coverage is appropriate for this change:

  • E2E Snapshot Tests: All 32 snapshot files covering the microphone icon have been updated. The snapshots cover:

    • Multiple browsers: Chromium, Firefox, WebKit
    • Both light and dark themes
    • Various states: disabled, with text, with files, in columns, after clear, etc.
  • Unit Tests: The existing ChatInput.test.tsx tests don't need modification as they test functionality, not visual appearance. The unit tests use mocked controllers and don't render actual icons.

  • No new tests required: This is a visual-only change with no behavior modifications.

Backwards Compatibility

Fully backwards compatible

  • No API changes
  • No behavior changes
  • No changes to props, state management, or widget communication
  • Users will simply see an outlined microphone icon instead of a filled one

Security & Risk

No security concerns

  • Uses an existing, already-trusted dependency
  • No changes to data handling, validation, or communication
  • Simple icon swap with no logic changes

Risk Assessment: Very Low

  • The change is isolated to icon rendering
  • All existing functionality is preserved
  • Comprehensive snapshot tests verify the visual change across browsers and themes

Recommendations

No changes required. The PR is well-executed:

  1. ✅ Uses existing dependency - no new packages introduced
  2. ✅ Follows existing code patterns
  3. ✅ Appropriate test coverage via snapshot updates
  4. ✅ No unnecessary changes
  5. ✅ Clear and accurate PR description

Verdict

APPROVED: This is a clean, focused visual polish change that replaces the filled microphone icon with an outlined variant. The implementation is correct, uses existing dependencies, and has appropriate snapshot test coverage across browsers and themes.


This is an automated AI review. Please verify the feedback and use your judgment.

@sfc-gh-nbellante sfc-gh-nbellante marked this pull request as ready for review January 12, 2026 00:34
Copilot AI review requested due to automatic review settings January 12, 2026 00:34
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.

Pull request overview

This pull request updates the microphone icon in the ChatInput component from a filled Mic icon to an outlined MicNone icon, improving visual consistency with the application's design language.

Changes:

  • Replaced the microphone icon import from @emotion-icons/material-rounded (Mic) to @emotion-icons/material-outlined (MicNone)
  • Updated the icon reference in the component JSX
  • Regenerated snapshot tests for all browser/theme combinations to reflect the new icon appearance

Reviewed changes

Copilot reviewed 1 out of 33 changed files in this pull request and generated no comments.

File Description
frontend/lib/src/components/widgets/ChatInput/ChatInput.tsx Updated icon import and usage from filled Mic to outlined MicNone
e2e_playwright/snapshots/linux/st_chat_input_test/*.png Updated visual regression test snapshots across all browsers (webkit, firefox, chromium) and themes (light, dark)

@sfc-gh-nbellante sfc-gh-nbellante merged commit 6323f42 into develop Jan 12, 2026
60 checks passed
@sfc-gh-nbellante sfc-gh-nbellante deleted the feat/chat-input-icons-v2 branch January 12, 2026 16:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

change:chore PR contains maintenance or housekeeping change impact:users PR changes affect end users security-assessment-completed Security assessment has been completed for PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants