@grafana/plugin-ui 0.10.6 → 0.10.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/cjs/index.d.cts
CHANGED
|
@@ -645,8 +645,7 @@ interface GroupByRowProps {
|
|
|
645
645
|
}
|
|
646
646
|
declare function GroupByRow({ sql, columns, onSqlChange }: GroupByRowProps): React.JSX.Element;
|
|
647
647
|
|
|
648
|
-
|
|
649
|
-
}
|
|
648
|
+
type AccessoryButtonProps = ButtonProps & {};
|
|
650
649
|
declare const AccessoryButton: ({ className, ...props }: AccessoryButtonProps) => React.JSX.Element;
|
|
651
650
|
|
|
652
651
|
interface EditorFieldGroupProps {
|
|
@@ -800,9 +799,9 @@ type RunQueryButtonProps = {
|
|
|
800
799
|
};
|
|
801
800
|
declare const RunQueryButton: ({ ariaLabel, queryRunning, queryInvalid, invalidQueryTooltip, disabled, onClick, dataTestId, }: RunQueryButtonProps) => React.JSX.Element;
|
|
802
801
|
|
|
803
|
-
type Props$o = Omit<React.ComponentProps<typeof InlineLabel>, 'children'> & {
|
|
802
|
+
type Props$o = Omit<React.ComponentProps<typeof InlineLabel>, 'children' | 'onChange'> & {
|
|
804
803
|
dataSourceConfig: DataSourceSettings<any, any>;
|
|
805
|
-
onChange: (config: DataSourceSettings) => void;
|
|
804
|
+
onChange: (config: DataSourceSettings<any, any>) => void;
|
|
806
805
|
labelWidth: number;
|
|
807
806
|
};
|
|
808
807
|
declare const SecureSocksProxyToggle: ({ labelWidth, ...props }: Props$o) => any;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SecureSocksProxyToggle.js","sources":["../../../../src/components/ConfigEditor/SecureSocksProxyToggle.tsx"],"sourcesContent":["import React from 'react';\nimport { type InlineLabel as OriginalInlineLabel, InlineField, InlineSwitch } from '@grafana/ui';\nimport { config } from '@grafana/runtime';\nimport { type DataSourceSettings } from '@grafana/data';\n\ntype Props = Omit<React.ComponentProps<typeof OriginalInlineLabel>, 'children'> & {\n dataSourceConfig: DataSourceSettings<any, any>;\n onChange: (config: DataSourceSettings) => void;\n labelWidth: number;\n};\n\nexport const SecureSocksProxyToggle = ({ labelWidth = 10, ...props }: Props) => {\n const { dataSourceConfig, onChange } = props;\n const handleSwitchChange = (e: React.ChangeEvent<HTMLInputElement>) => {\n onChange({\n ...dataSourceConfig,\n jsonData: {\n ...dataSourceConfig.jsonData,\n enableSecureSocksProxy: e.target.checked,\n },\n });\n };\n\n return (\n (config as any).secureSocksDSProxyEnabled && (\n <div>\n <div className=\"gf-form\">\n <div className=\"gf-form gf-form-inline\">\n <InlineField\n htmlFor=\"secureSocksProxyEnabled\"\n label=\"Secure Socks Proxy Enabled\"\n labelWidth={labelWidth}\n tooltip={\n <>\n Proxy the datasource connection through the secure socks proxy to a different network. To learn more\n about configuring the datasource connection proxy,{' '}\n <a\n href=\"https://grafana.com/docs/grafana/latest/setup-grafana/configure-grafana/proxy/\"\n target=\"_blank\"\n rel=\"noopener noreferrer\"\n >\n click here.\n </a>\n </>\n }\n >\n <InlineSwitch\n id=\"secureSocksProxyEnabled\"\n value={dataSourceConfig.jsonData.enableSecureSocksProxy}\n onChange={handleSwitchChange}\n />\n </InlineField>\n </div>\n </div>\n </div>\n )\n );\n};\n"],"names":["React"],"mappings":";;;;;AAWO,MAAM,yBAAyB,CAAC,EAAE,aAAa,EAAI,EAAA,GAAG,OAAmB,KAAA;AAC9E,EAAM,MAAA,EAAE,gBAAkB,EAAA,QAAA,EAAa,GAAA,KAAA;AACvC,EAAM,MAAA,kBAAA,GAAqB,CAAC,CAA2C,KAAA;AACrE,IAAS,QAAA,CAAA;AAAA,MACP,GAAG,gBAAA;AAAA,MACH,QAAU,EAAA;AAAA,QACR,GAAG,gBAAiB,CAAA,QAAA;AAAA,QACpB,sBAAA,EAAwB,EAAE,MAAO,CAAA;AAAA;AACnC,KACD,CAAA;AAAA,GACH;AAEA,EACG,OAAA,MAAA,CAAe,yBACd,oBAAAA,cAAA,CAAA,aAAA,CAAC,KACC,EAAA,IAAA,kBAAAA,cAAA,CAAA,aAAA,CAAC,KAAI,EAAA,EAAA,SAAA,EAAU,SACb,EAAA,kBAAAA,cAAA,CAAA,aAAA,CAAC,KAAI,EAAA,EAAA,SAAA,EAAU,wBACb,EAAA,kBAAAA,cAAA,CAAA,aAAA;AAAA,IAAC,WAAA;AAAA,IAAA;AAAA,MACC,OAAQ,EAAA,yBAAA;AAAA,MACR,KAAM,EAAA,4BAAA;AAAA,MACN,UAAA;AAAA,MACA,OAAA,kBACIA,cAAA,CAAA,aAAA,CAAAA,cAAA,CAAA,QAAA,EAAA,IAAA,EAAA,yJAAA,EAEmD,GACnD,kBAAAA,cAAA,CAAA,aAAA;AAAA,QAAC,GAAA;AAAA,QAAA;AAAA,UACC,IAAK,EAAA,gFAAA;AAAA,UACL,MAAO,EAAA,QAAA;AAAA,UACP,GAAI,EAAA;AAAA,SAAA;AAAA,QACL;AAAA,OAGH;AAAA,KAAA;AAAA,oBAGFA,cAAA,CAAA,aAAA;AAAA,MAAC,YAAA;AAAA,MAAA;AAAA,QACC,EAAG,EAAA,yBAAA;AAAA,QACH,KAAA,EAAO,iBAAiB,QAAS,CAAA,sBAAA;AAAA,QACjC,QAAU,EAAA;AAAA;AAAA;AACZ,GAEJ,CACF,CACF,CAAA;AAGN;;;;"}
|
|
1
|
+
{"version":3,"file":"SecureSocksProxyToggle.js","sources":["../../../../src/components/ConfigEditor/SecureSocksProxyToggle.tsx"],"sourcesContent":["import React from 'react';\nimport { type InlineLabel as OriginalInlineLabel, InlineField, InlineSwitch } from '@grafana/ui';\nimport { config } from '@grafana/runtime';\nimport { type DataSourceSettings } from '@grafana/data';\n\ntype Props = Omit<React.ComponentProps<typeof OriginalInlineLabel>, 'children' | 'onChange'> & {\n dataSourceConfig: DataSourceSettings<any, any>;\n onChange: (config: DataSourceSettings<any, any>) => void;\n labelWidth: number;\n};\n\nexport const SecureSocksProxyToggle = ({ labelWidth = 10, ...props }: Props) => {\n const { dataSourceConfig, onChange } = props;\n const handleSwitchChange = (e: React.ChangeEvent<HTMLInputElement>) => {\n onChange({\n ...dataSourceConfig,\n jsonData: {\n ...dataSourceConfig.jsonData,\n enableSecureSocksProxy: e.target.checked,\n },\n });\n };\n\n return (\n (config as any).secureSocksDSProxyEnabled && (\n <div>\n <div className=\"gf-form\">\n <div className=\"gf-form gf-form-inline\">\n <InlineField\n htmlFor=\"secureSocksProxyEnabled\"\n label=\"Secure Socks Proxy Enabled\"\n labelWidth={labelWidth}\n tooltip={\n <>\n Proxy the datasource connection through the secure socks proxy to a different network. To learn more\n about configuring the datasource connection proxy,{' '}\n <a\n href=\"https://grafana.com/docs/grafana/latest/setup-grafana/configure-grafana/proxy/\"\n target=\"_blank\"\n rel=\"noopener noreferrer\"\n >\n click here.\n </a>\n </>\n }\n >\n <InlineSwitch\n id=\"secureSocksProxyEnabled\"\n value={dataSourceConfig.jsonData.enableSecureSocksProxy}\n onChange={handleSwitchChange}\n />\n </InlineField>\n </div>\n </div>\n </div>\n )\n );\n};\n"],"names":["React"],"mappings":";;;;;AAWO,MAAM,yBAAyB,CAAC,EAAE,aAAa,EAAI,EAAA,GAAG,OAAmB,KAAA;AAC9E,EAAM,MAAA,EAAE,gBAAkB,EAAA,QAAA,EAAa,GAAA,KAAA;AACvC,EAAM,MAAA,kBAAA,GAAqB,CAAC,CAA2C,KAAA;AACrE,IAAS,QAAA,CAAA;AAAA,MACP,GAAG,gBAAA;AAAA,MACH,QAAU,EAAA;AAAA,QACR,GAAG,gBAAiB,CAAA,QAAA;AAAA,QACpB,sBAAA,EAAwB,EAAE,MAAO,CAAA;AAAA;AACnC,KACD,CAAA;AAAA,GACH;AAEA,EACG,OAAA,MAAA,CAAe,yBACd,oBAAAA,cAAA,CAAA,aAAA,CAAC,KACC,EAAA,IAAA,kBAAAA,cAAA,CAAA,aAAA,CAAC,KAAI,EAAA,EAAA,SAAA,EAAU,SACb,EAAA,kBAAAA,cAAA,CAAA,aAAA,CAAC,KAAI,EAAA,EAAA,SAAA,EAAU,wBACb,EAAA,kBAAAA,cAAA,CAAA,aAAA;AAAA,IAAC,WAAA;AAAA,IAAA;AAAA,MACC,OAAQ,EAAA,yBAAA;AAAA,MACR,KAAM,EAAA,4BAAA;AAAA,MACN,UAAA;AAAA,MACA,OAAA,kBACIA,cAAA,CAAA,aAAA,CAAAA,cAAA,CAAA,QAAA,EAAA,IAAA,EAAA,yJAAA,EAEmD,GACnD,kBAAAA,cAAA,CAAA,aAAA;AAAA,QAAC,GAAA;AAAA,QAAA;AAAA,UACC,IAAK,EAAA,gFAAA;AAAA,UACL,MAAO,EAAA,QAAA;AAAA,UACP,GAAI,EAAA;AAAA,SAAA;AAAA,QACL;AAAA,OAGH;AAAA,KAAA;AAAA,oBAGFA,cAAA,CAAA,aAAA;AAAA,MAAC,YAAA;AAAA,MAAA;AAAA,QACC,EAAG,EAAA,yBAAA;AAAA,QACH,KAAA,EAAO,iBAAiB,QAAS,CAAA,sBAAA;AAAA,QACjC,QAAU,EAAA;AAAA;AAAA;AACZ,GAEJ,CACF,CACF,CAAA;AAGN;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AccessoryButton.js","sources":["../../../../src/components/QueryEditor/AccessoryButton.tsx"],"sourcesContent":["import { css, cx } from '@emotion/css';\nimport React from 'react';\n\nimport { type GrafanaTheme2 } from '@grafana/data';\nimport { Button, type ButtonProps, useStyles2 } from '@grafana/ui';\n\
|
|
1
|
+
{"version":3,"file":"AccessoryButton.js","sources":["../../../../src/components/QueryEditor/AccessoryButton.tsx"],"sourcesContent":["import { css, cx } from '@emotion/css';\nimport React from 'react';\n\nimport { type GrafanaTheme2 } from '@grafana/data';\nimport { Button, type ButtonProps, useStyles2 } from '@grafana/ui';\n\ntype AccessoryButtonProps = ButtonProps & {};\n\nexport const AccessoryButton = ({ className, ...props }: AccessoryButtonProps) => {\n const styles = useStyles2(getButtonStyles);\n\n return <Button {...props} className={cx(className, styles.button)} />;\n};\n\nconst getButtonStyles = (theme: GrafanaTheme2) => ({\n button: css({\n paddingLeft: theme.spacing(3 / 2),\n paddingRight: theme.spacing(3 / 2),\n }),\n});\n"],"names":["React"],"mappings":";;;;;AAQO,MAAM,kBAAkB,CAAC,EAAE,SAAW,EAAA,GAAG,OAAkC,KAAA;AAChF,EAAM,MAAA,MAAA,GAAS,WAAW,eAAe,CAAA;AAEzC,EAAO,uBAAAA,cAAA,CAAA,aAAA,CAAC,UAAQ,GAAG,KAAA,EAAO,WAAW,EAAG,CAAA,SAAA,EAAW,MAAO,CAAA,MAAM,CAAG,EAAA,CAAA;AACrE;AAEA,MAAM,eAAA,GAAkB,CAAC,KAA0B,MAAA;AAAA,EACjD,QAAQ,GAAI,CAAA;AAAA,IACV,WAAa,EAAA,KAAA,CAAM,OAAQ,CAAA,CAAA,GAAI,CAAC,CAAA;AAAA,IAChC,YAAc,EAAA,KAAA,CAAM,OAAQ,CAAA,CAAA,GAAI,CAAC;AAAA,GAClC;AACH,CAAA,CAAA;;;;"}
|
package/dist/esm/index.d.ts
CHANGED
|
@@ -645,8 +645,7 @@ interface GroupByRowProps {
|
|
|
645
645
|
}
|
|
646
646
|
declare function GroupByRow({ sql, columns, onSqlChange }: GroupByRowProps): React.JSX.Element;
|
|
647
647
|
|
|
648
|
-
|
|
649
|
-
}
|
|
648
|
+
type AccessoryButtonProps = ButtonProps & {};
|
|
650
649
|
declare const AccessoryButton: ({ className, ...props }: AccessoryButtonProps) => React.JSX.Element;
|
|
651
650
|
|
|
652
651
|
interface EditorFieldGroupProps {
|
|
@@ -800,9 +799,9 @@ type RunQueryButtonProps = {
|
|
|
800
799
|
};
|
|
801
800
|
declare const RunQueryButton: ({ ariaLabel, queryRunning, queryInvalid, invalidQueryTooltip, disabled, onClick, dataTestId, }: RunQueryButtonProps) => React.JSX.Element;
|
|
802
801
|
|
|
803
|
-
type Props$o = Omit<React.ComponentProps<typeof InlineLabel>, 'children'> & {
|
|
802
|
+
type Props$o = Omit<React.ComponentProps<typeof InlineLabel>, 'children' | 'onChange'> & {
|
|
804
803
|
dataSourceConfig: DataSourceSettings<any, any>;
|
|
805
|
-
onChange: (config: DataSourceSettings) => void;
|
|
804
|
+
onChange: (config: DataSourceSettings<any, any>) => void;
|
|
806
805
|
labelWidth: number;
|
|
807
806
|
};
|
|
808
807
|
declare const SecureSocksProxyToggle: ({ labelWidth, ...props }: Props$o) => any;
|
package/package.json
CHANGED
|
@@ -1,7 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@grafana/plugin-ui",
|
|
3
|
-
"version": "0.10.
|
|
4
|
-
"repository":
|
|
3
|
+
"version": "0.10.8",
|
|
4
|
+
"repository": {
|
|
5
|
+
"type": "git",
|
|
6
|
+
"url": "git+ssh://git@github.com/grafana/plugin-ui.git"
|
|
7
|
+
},
|
|
5
8
|
"author": "Grafana Labs",
|
|
6
9
|
"type": "module",
|
|
7
10
|
"main": "dist/cjs/index.cjs",
|
|
@@ -83,7 +86,7 @@
|
|
|
83
86
|
"chance": "^1.1.7",
|
|
84
87
|
"copyfiles": "^2.4.1",
|
|
85
88
|
"cspell": "^8.14.4",
|
|
86
|
-
"esbuild": "^0.25.
|
|
89
|
+
"esbuild": "^0.25.3",
|
|
87
90
|
"eslint": "^8.52.0",
|
|
88
91
|
"eslint-config-prettier": "^8.8.0",
|
|
89
92
|
"eslint-plugin-jsdoc": "^46.8.2",
|