Skip to content

Commit

Permalink
Scope floating ui portal (#4385)
Browse files Browse the repository at this point in the history
  • Loading branch information
origami-z authored Dec 12, 2024
1 parent 07528aa commit dedbade
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
5 changes: 5 additions & 0 deletions .changeset/modern-chefs-knock.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@salt-ds/core": patch
---

Fixed Salt Provider in floating ui adding extra attributes to root when mixing styling options.
4 changes: 2 additions & 2 deletions packages/core/src/utils/useFloatingUI/useFloatingUI.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ const DefaultFloatingComponent = forwardRef<
if (focusManagerProps && open) {
return (
<FloatingPortal>
<ChosenSaltProvider>
<ChosenSaltProvider applyClassesTo="scope">
<FloatingFocusManager {...focusManagerProps}>
<div style={style} {...rest} ref={ref} />
</FloatingFocusManager>
Expand All @@ -85,7 +85,7 @@ const DefaultFloatingComponent = forwardRef<

return open ? (
<FloatingPortal>
<ChosenSaltProvider>
<ChosenSaltProvider applyClassesTo="scope">
<div style={style} {...rest} ref={ref} />
</ChosenSaltProvider>
</FloatingPortal>
Expand Down

0 comments on commit dedbade

Please sign in to comment.