-
Notifications
You must be signed in to change notification settings - Fork 53
fix: (ListItem) - Fix endMedia to not be removed from DOM on mouseleave for ListItem #278
Conversation
Codecov Report
@@ Coverage Diff @@
## master #278 +/- ##
==========================================
+ Coverage 91.72% 91.77% +0.05%
==========================================
Files 41 41
Lines 1341 1325 -16
Branches 172 194 +22
==========================================
- Hits 1230 1216 -14
+ Misses 107 105 -2
Partials 4 4
Continue to review full report at Codecov.
|
@musingh1 the same would need to be done for focus state if the user is using keyboard. Would you mind adding following commit to the PR: feature/mukul/fix-listitem-styles...feat/listitem-focus-styles or should we create a followup PR after this one is merged? |
docs/src/examples/components/List/Content/ListExampleEndMedia.tsx
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lets address comments before merging that.
Also, there are couple problems appearing when List Item example is rendered in Docs:
- Received
true
for a non-boolean attributeselection
. .. - child in an array or iterator should have a unique "key" prop
Lets address them as well before merging (I may assist in that :).
…m/stardust-ui/react into feature/mukul/fix-listitem-styles
Earlier, we were listening for mouseEnter and mouseLeave, maintaining the isHovering state and only showing the endMedia when the item is hovered. This breaks the scenarios where endMedia is a Popup. Once the Popup is triggered we want the content to stay even after the user leaves the list item (e.g. points to the popup content).
So now, if provided we will always render all the media's and in Teams theme control the display of endMedia, headerMedia etc through styles.