From 31f7af06859b32f124f0ba99420bfc79aeae4b04 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Hugo=20H=C3=A4ggmark?= Date: Mon, 16 Jun 2025 06:06:42 +0200 Subject: [PATCH] Plugins: adds read-only props to DataSourcePluginSettings (#105713) --- .../datasources/components/DataSourcePluginSettings.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/public/app/features/datasources/components/DataSourcePluginSettings.tsx b/public/app/features/datasources/components/DataSourcePluginSettings.tsx index 013625eaa55..0dfd48bb5bf 100644 --- a/public/app/features/datasources/components/DataSourcePluginSettings.tsx +++ b/public/app/features/datasources/components/DataSourcePluginSettings.tsx @@ -1,6 +1,7 @@ import { createElement, PureComponent } from 'react'; import { DataSourcePluginMeta, DataSourceSettings } from '@grafana/data'; +import { readOnlyCopy } from 'app/features/plugins/extensions/utils'; import { GenericDataSourcePlugin } from '../types'; @@ -33,7 +34,7 @@ export class DataSourcePluginSettings extends PureComponent {
{plugin.components.ConfigEditor && createElement(plugin.components.ConfigEditor, { - options: dataSource, + options: readOnlyCopy(dataSource), onOptionsChange: this.onModelChanged, })}