import React, { FC } from 'react'; import { selectors } from '@grafana/e2e-selectors'; import { Button, LinkButton } from '@grafana/ui'; import { contextSrv } from 'app/core/core'; import { AccessControlAction } from 'app/types/'; export interface Props { exploreUrl: string; canSave: boolean; canDelete: boolean; onDelete: () => void; onSubmit: (event: any) => void; onTest: (event: any) => void; } const ButtonRow: FC = ({ canSave, canDelete, onDelete, onSubmit, onTest, exploreUrl }) => { const canExploreDataSources = contextSrv.hasPermission(AccessControlAction.DataSourcesExplore); return (
Explore {canSave && ( )} {!canSave && ( )}
); }; export default ButtonRow;