2022-04-22 08:33:13 -05:00
|
|
|
import React from 'react';
|
|
|
|
|
2020-03-25 06:25:39 -05:00
|
|
|
import { DataSourcePluginOptionsEditorProps } from '@grafana/data';
|
|
|
|
import { DataSourceHttpSettings } from '@grafana/ui';
|
2021-10-06 14:39:14 -05:00
|
|
|
import { NodeGraphSettings } from 'app/core/components/NodeGraphSettings';
|
2022-02-22 16:17:45 -06:00
|
|
|
import { TraceToLogsSettings } from 'app/core/components/TraceToLogs/TraceToLogsSettings';
|
2020-03-25 06:25:39 -05:00
|
|
|
|
|
|
|
export type Props = DataSourcePluginOptionsEditorProps;
|
|
|
|
|
|
|
|
export const ConfigEditor: React.FC<Props> = ({ options, onOptionsChange }) => {
|
|
|
|
return (
|
2020-12-10 12:42:43 -06:00
|
|
|
<>
|
|
|
|
<DataSourceHttpSettings
|
|
|
|
defaultUrl="http://localhost:9411"
|
|
|
|
dataSourceConfig={options}
|
2021-01-18 10:31:32 -06:00
|
|
|
showAccessOptions={false}
|
2020-12-10 12:42:43 -06:00
|
|
|
onChange={onOptionsChange}
|
|
|
|
/>
|
|
|
|
|
2021-10-06 14:39:14 -05:00
|
|
|
<div className="gf-form-group">
|
|
|
|
<TraceToLogsSettings options={options} onOptionsChange={onOptionsChange} />
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div className="gf-form-group">
|
|
|
|
<NodeGraphSettings options={options} onOptionsChange={onOptionsChange} />
|
|
|
|
</div>
|
2020-12-10 12:42:43 -06:00
|
|
|
</>
|
2020-03-25 06:25:39 -05:00
|
|
|
);
|
|
|
|
};
|