DatePickerWithInput: Set zIndex for popover correctly (#84154)

set zIndex for popover correctly
This commit is contained in:
Ashley Harrison
2024-03-11 11:35:59 +00:00
committed by GitHub
parent 8206a23061
commit 0280fac0e3
@@ -2,7 +2,7 @@ import { css } from '@emotion/css';
import { autoUpdate, flip, shift, useClick, useDismiss, useFloating, useInteractions } from '@floating-ui/react';
import React, { ChangeEvent, useState } from 'react';
import { dateTime } from '@grafana/data';
import { GrafanaTheme2, dateTime } from '@grafana/data';
import { useStyles2 } from '../../../themes';
import { Props as InputProps, Input } from '../../Input/Input';
@@ -100,7 +100,7 @@ export const DatePickerWithInput = ({
);
};
const getStyles = () => {
const getStyles = (theme: GrafanaTheme2) => {
return {
container: css({
position: 'relative',
@@ -113,7 +113,7 @@ const getStyles = () => {
},
}),
popover: css({
zIndex: 1,
zIndex: theme.zIndex.tooltip,
}),
};
};