Skip to content

Commit

Permalink
🐛 (editor) Fix variables dropdown behind modal
Browse files Browse the repository at this point in the history
Closes #213
  • Loading branch information
baptisteArno committed Jan 6, 2023
1 parent 3f7e1ce commit b455078
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
3 changes: 2 additions & 1 deletion apps/builder/src/components/VariableSearchInput.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ export const VariableSearchInput = ({
const [keyboardFocusIndex, setKeyboardFocusIndex] = useState<
number | undefined
>()
const dropdownRef = useRef(null)
const dropdownRef = useRef<HTMLDivElement>(null)
const inputRef = useRef<HTMLInputElement>(null)
const createVariableItemRef = useRef<HTMLButtonElement | null>(null)
const itemsRef = useRef<(HTMLButtonElement | null)[]>([])
Expand All @@ -70,6 +70,7 @@ export const VariableSearchInput = ({

useEffect(() => {
if (isDefaultOpen) onOpen()

// eslint-disable-next-line react-hooks/exhaustive-deps
}, [])

Expand Down
1 change: 1 addition & 0 deletions apps/builder/src/lib/theme.ts
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ const Popover = createMultiStyleConfigHelpers(
popper: {
width: 'fit-content',
maxWidth: 'fit-content',
zIndex: 'popover',
},
content: {
bg: colorMode === 'dark' ? 'gray.800' : 'white',
Expand Down

0 comments on commit b455078

Please sign in to comment.