Skip to content

Conversation

@OEvgeny
Copy link
Collaborator

@OEvgeny OEvgeny commented Jan 19, 2026

Fixes #

Changelog Entry

  • (Experimental) Added custom variants support for botframework-webchat-fluent-theme package, in PR #5675, by @OEvgeny

Description

This adds an ability to pass custom variants for fluent theme to customize further components themed through either composition of existing and custom variants or custom variants.

Design

We intentionally reserve single word variants for our use. Custom variant should contain 2+ class names separated by space.

The design is pretty straightforward:

  • allow passing custom string to the variant field which contains a space character
  • when processing variants, we fallback to the string passed

As a side effect this allows to use class names provided by useStyles as a variant name essentially allowing theme authors to encapsulate variant adjustments into a CSS module similarly to how Web Chat CSS Modules pipeline works.

Specific Changes

  • relaxed variant validation to allow multiple strings
  • added a custom theme derived from the copilot-deprecated variant
  • brought back copilot-deprecated tests with previous snapshots
  • exposed components required for handling message header
  • added custom part grouping decorator for the custom variant to match old snapshots

--

  • I have added tests and executed them locally
  • I have updated CHANGELOG.md
  • I have updated documentation

Review Checklist

This section is for contributors to review your work.

  • Accessibility reviewed (tab order, content readability, alt text, color contrast)
  • Browser and platform compatibilities reviewed
  • CSS styles reviewed (minimal rules, no z-index)
  • Documents reviewed (docs, samples, live demo)
  • Internationalization reviewed (strings, unit formatting)
  • package.json and package-lock.json reviewed
  • Security reviewed (no data URIs, check for nonce leak)
  • Tests reviewed (coverage, legitimacy)

@OEvgeny OEvgeny marked this pull request as ready for review January 19, 2026 20:43
@OEvgeny OEvgeny requested a review from compulim January 21, 2026 01:48
@OEvgeny OEvgeny enabled auto-merge (squash) January 21, 2026 01:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants