LogContext: Fix setting wrong height for ElasticSearch (#62330)

fix wrong height for elastic
This commit is contained in:
Sven Grossmann 2023-01-27 15:41:16 +01:00 committed by GitHub
parent 5bdfbd93a5
commit df2db3bb23
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -35,9 +35,7 @@ interface LogRowContextProps {
}
const getLogRowContextStyles = (theme: GrafanaTheme2, wrapLogMessage?: boolean, datasourceUiHeight?: number) => {
if (config.featureToggles.logsContextDatasourceUi) {
datasourceUiHeight = datasourceUiHeight ?? 55;
} else {
if (!config.featureToggles.logsContextDatasourceUi || !datasourceUiHeight) {
datasourceUiHeight = 0;
}
/**
@ -178,7 +176,7 @@ const LogRowContextGroupHeader: React.FunctionComponent<LogRowContextGroupHeader
getLogRowContextUi,
runContextQuery,
}) => {
const [height, setHeight] = useState(50);
const [height, setHeight] = useState(0);
const datasourceUiRef = React.createRef<HTMLDivElement>();
const {
datasourceUi: dsUi,