import { css } from '@emotion/css'; import React, { ReactElement } from 'react'; import { GrafanaTheme } from '@grafana/data'; import { Icon, useStyles } from '@grafana/ui'; import { ResultInfo } from './types'; interface Props { editURL: string; target: ResultInfo; } export function DashboardQueryRow({ editURL, target }: Props): ReactElement { const style = useStyles(getStyles); return (
{`${target.refId}:`}
{target.query}  
); } function getStyles(theme: GrafanaTheme) { return { logo: css` label: logo; margin-right: ${theme.spacing.sm}; `, queryEditorRowHeader: css` label: queryEditorRowHeader; display: flex; padding: 4px 8px; flex-flow: row wrap; background: ${theme.colors.bg2}; align-items: center; `, }; }