Skip to content

Commit 488ce72

Browse files
compulimOEvgeny
andauthored
Supports multi-dimenstional grouping (#5471)
* Upgrade avatar tests * Refactor RenderingElements * Refactor Sender/StatusGrouping * Fix infinite loop * Remove break * Fix grouping and remove comment * Refactor logics to TranscriptActivity * Clean up * Clean up * Allow non-standard group name * Rename * Fix wrong activityElementMapRef * Clean up * FIx livestream * Fix performance * Move to useRenderingActivityKeys * Remove obsoleted ActivityTree context * Move ActivityTree down the tree * Add new <TranscriptDOMComposer> * Rename composer * Refactor createContextAndHook * Clean up * Clean up * Clean up * Refactor to ActivitiesWithGroupContainer * Simplify * Simplify * Clean up error message * Prepare for group container middleware * Add activity grouping middleware * Add `useGetRenderActivtiyCallback` instead of exposing `activityWithRenderer` * Clean up * Add groupActivitiesBy * Clean up * Add test of disabling sender/status * Add tests for groupActivitiesBy * Typo * Fix undefined activityGroupingDecorationMiddleware * Fix BasicTranscript should not render if no activities * Fix flaky tests * Clean up * Add tests * Update label position * Move to the unified decorator middleware * Ignore errors * Fix test * Concatenate middleware * Add init * Flip the decorator order * Flip order * Flip decorator order * Remove commented code * Allow removal of key * Allow removal of sender/status * Prettier * Clean up * Sort * Add test * Use valibot * Remove as map for simplicity * Add type * Add exports * Use fat arrow * Simplify * Add priority to DecoratorComposer * Add built-in * Rectify undefined groupActivities * Add internal/LowPriorityDecoratorComposer * Rename decorators * Rename to groupingName * Move <DecoratorComposer> after Fluent * Wait for scroll stabilize * Use emulator * Refactor useGroupActivities into its own context * Run groupActivities recursively * Nested grouping * Nested grouping * Allow middleware to return undefined * Add docs * Remove unneeded coalesce * Add readonly * Move default middleware * Add entry * Allow middleware to opt out after setup * Verbosity on entry * Clean up * Update test * Fix flaky * Use newer version of groupActivitiesMiddleware * Clean up * Use <DecoratorComposer> * Rename types * Sort * Sort * Style --------- Co-authored-by: Eugene <EOlonov@gmail.com>
1 parent 5e12798 commit 488ce72

File tree

164 files changed

+3500
-1377
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

164 files changed

+3500
-1377
lines changed

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ Notes: web developers are advised to use [`~` (tilde range)](https://github.com/
3232
- Please refer to PR [#5330](https://github.com/microsoft/BotFramework-WebChat/pull/5330) for details
3333
- HTML sanitizer is moved from `renderMarkdown` to HTML content transformer middleware, please refer to PR [#5338](https://github.com/microsoft/BotFramework-WebChat/pull/5338)
3434
- If you customized `renderMarkdown` with a custom HTML sanitizer, please move the HTML sanitizer to the new HTML content transformer middleware
35+
- `useGroupActivities` hook is being deprecated in favor of the `useGroupActivitiesByName` hook. The hook will be removed on or after 2027-05-04
3536

3637
### Added
3738

@@ -86,6 +87,10 @@ Notes: web developers are advised to use [`~` (tilde range)](https://github.com/
8687
- Added sliding dots typing indicator in Fluent theme, in PR [#5447](https://github.com/microsoft/BotFramework-WebChat/pull/5447) and PR [#5448](https://github.com/microsoft/BotFramework-WebChat/pull/5448), by [@compulim](https://github.com/compulim)
8788
- (Experimental) Add an ability to pass `completion` prop into Fluent send box and expose the component, in PR [#5466](https://github.com/microsoft/BotFramework-WebChat/pull/5466), by [@OEvgeny](https://github.com/OEvgeny)
8889
- Added feedback form for like/dislike button when `feedbackActionsPlacement` is `"activity-actions"`, in PR [#5460](https://github.com/microsoft/BotFramework-WebChat/pull/5460), PR [#5469](https://github.com/microsoft/BotFramework-WebChat/pull/5469), and PR [5470](https://github.com/microsoft/BotFramework-WebChat/pull/5470) by [@lexi-taylor](https://github.com/lexi-taylor) and [@OEvgeny](https://github.com/OEvgeny)
90+
- Added multi-dimensional grouping, `styleOptions.groupActivitiesBy`, and `useGroupActivitiesByName` hook, in PR [#5471](https://github.com/microsoft/BotFramework-WebChat/pull/5471), by [@compulim](https://github.com/compulim)
91+
- Existing behavior will be kept and activities will be grouped by `sender` followed by `status`
92+
- `useGroupActivitiesByName` is favored over the existing `useGroupActivities` hook for performance reason
93+
- Middleware which support the new grouping name init argument should only compute the grouping if they match the grouping name, or the grouping name is not specified, otherwise, should do nothing and call the downstream middleware
8994

9095
### Changed
9196

__tests__/customizableAvatar.js

Lines changed: 0 additions & 347 deletions
This file was deleted.

0 commit comments

Comments
 (0)