@grafana/sql 0.0.0 → 13.0.0-23483592685
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/CHANGELOG.md +3 -0
- package/README.md +10 -0
- package/dist/cjs/ResponseParser.cjs +29 -0
- package/dist/cjs/ResponseParser.cjs.map +1 -0
- package/dist/cjs/SQLVariableEditor.cjs +86 -0
- package/dist/cjs/SQLVariableEditor.cjs.map +1 -0
- package/dist/cjs/SQLVariableSupport.cjs +40 -0
- package/dist/cjs/SQLVariableSupport.cjs.map +1 -0
- package/dist/cjs/SQLVariableUtils.cjs +75 -0
- package/dist/cjs/SQLVariableUtils.cjs.map +1 -0
- package/dist/cjs/components/ConfirmModal.cjs +56 -0
- package/dist/cjs/components/ConfirmModal.cjs.map +1 -0
- package/dist/cjs/components/DatasetSelector.cjs +48 -0
- package/dist/cjs/components/DatasetSelector.cjs.map +1 -0
- package/dist/cjs/components/QueryEditor.cjs +124 -0
- package/dist/cjs/components/QueryEditor.cjs.map +1 -0
- package/dist/cjs/components/QueryEditorLazy.cjs +44 -0
- package/dist/cjs/components/QueryEditorLazy.cjs.map +1 -0
- package/dist/cjs/components/QueryHeader.cjs +294 -0
- package/dist/cjs/components/QueryHeader.cjs.map +1 -0
- package/dist/cjs/components/TableSelector.cjs +41 -0
- package/dist/cjs/components/TableSelector.cjs.map +1 -0
- package/dist/cjs/components/configuration/ConnectionLimits.cjs +162 -0
- package/dist/cjs/components/configuration/ConnectionLimits.cjs.map +1 -0
- package/dist/cjs/components/configuration/Divider.cjs +25 -0
- package/dist/cjs/components/configuration/Divider.cjs.map +1 -0
- package/dist/cjs/components/configuration/MaxLifetimeField.cjs +41 -0
- package/dist/cjs/components/configuration/MaxLifetimeField.cjs.map +1 -0
- package/dist/cjs/components/configuration/MaxOpenConnectionsField.cjs +53 -0
- package/dist/cjs/components/configuration/MaxOpenConnectionsField.cjs.map +1 -0
- package/dist/cjs/components/configuration/NumberInput.cjs +37 -0
- package/dist/cjs/components/configuration/NumberInput.cjs.map +1 -0
- package/dist/cjs/components/configuration/TLSSecretsConfig.cjs +106 -0
- package/dist/cjs/components/configuration/TLSSecretsConfig.cjs.map +1 -0
- package/dist/cjs/components/configuration/useMigrateDatabaseFields.cjs +52 -0
- package/dist/cjs/components/configuration/useMigrateDatabaseFields.cjs.map +1 -0
- package/dist/cjs/components/query-editor-raw/QueryEditorRaw.cjs +40 -0
- package/dist/cjs/components/query-editor-raw/QueryEditorRaw.cjs.map +1 -0
- package/dist/cjs/components/query-editor-raw/QueryToolbox.cjs +108 -0
- package/dist/cjs/components/query-editor-raw/QueryToolbox.cjs.map +1 -0
- package/dist/cjs/components/query-editor-raw/QueryValidator.cjs +100 -0
- package/dist/cjs/components/query-editor-raw/QueryValidator.cjs.map +1 -0
- package/dist/cjs/components/query-editor-raw/RawEditor.cjs +116 -0
- package/dist/cjs/components/query-editor-raw/RawEditor.cjs.map +1 -0
- package/dist/cjs/components/visual-query-builder/AwesomeQueryBuilder.cjs +273 -0
- package/dist/cjs/components/visual-query-builder/AwesomeQueryBuilder.cjs.map +1 -0
- package/dist/cjs/components/visual-query-builder/GroupByRow.cjs +69 -0
- package/dist/cjs/components/visual-query-builder/GroupByRow.cjs.map +1 -0
- package/dist/cjs/components/visual-query-builder/OrderByRow.cjs +82 -0
- package/dist/cjs/components/visual-query-builder/OrderByRow.cjs.map +1 -0
- package/dist/cjs/components/visual-query-builder/Preview.cjs +55 -0
- package/dist/cjs/components/visual-query-builder/Preview.cjs.map +1 -0
- package/dist/cjs/components/visual-query-builder/SQLGroupByRow.cjs +18 -0
- package/dist/cjs/components/visual-query-builder/SQLGroupByRow.cjs.map +1 -0
- package/dist/cjs/components/visual-query-builder/SQLOrderByRow.cjs +18 -0
- package/dist/cjs/components/visual-query-builder/SQLOrderByRow.cjs.map +1 -0
- package/dist/cjs/components/visual-query-builder/SQLWhereRow.cjs +56 -0
- package/dist/cjs/components/visual-query-builder/SQLWhereRow.cjs.map +1 -0
- package/dist/cjs/components/visual-query-builder/SelectColumn.cjs +30 -0
- package/dist/cjs/components/visual-query-builder/SelectColumn.cjs.map +1 -0
- package/dist/cjs/components/visual-query-builder/SelectCustomFunctionParameters.cjs +135 -0
- package/dist/cjs/components/visual-query-builder/SelectCustomFunctionParameters.cjs.map +1 -0
- package/dist/cjs/components/visual-query-builder/SelectFunctionParameters.cjs +142 -0
- package/dist/cjs/components/visual-query-builder/SelectFunctionParameters.cjs.map +1 -0
- package/dist/cjs/components/visual-query-builder/SelectRow.cjs +184 -0
- package/dist/cjs/components/visual-query-builder/SelectRow.cjs.map +1 -0
- package/dist/cjs/components/visual-query-builder/VisualEditor.cjs +43 -0
- package/dist/cjs/components/visual-query-builder/VisualEditor.cjs.map +1 -0
- package/dist/cjs/components/visual-query-builder/WhereRow.cjs +84 -0
- package/dist/cjs/components/visual-query-builder/WhereRow.cjs.map +1 -0
- package/dist/cjs/constants.cjs +77 -0
- package/dist/cjs/constants.cjs.map +1 -0
- package/dist/cjs/datasource/SqlDatasource.cjs +188 -0
- package/dist/cjs/datasource/SqlDatasource.cjs.map +1 -0
- package/dist/cjs/defaults.cjs +32 -0
- package/dist/cjs/defaults.cjs.map +1 -0
- package/dist/cjs/expressions.cjs +23 -0
- package/dist/cjs/expressions.cjs.map +1 -0
- package/dist/cjs/index.cjs +48 -0
- package/dist/cjs/index.cjs.map +1 -0
- package/dist/cjs/loadResources.cjs +49 -0
- package/dist/cjs/loadResources.cjs.map +1 -0
- package/dist/cjs/locales/cs-CZ/grafana-sql.json.cjs +165 -0
- package/dist/cjs/locales/cs-CZ/grafana-sql.json.cjs.map +1 -0
- package/dist/cjs/locales/de-DE/grafana-sql.json.cjs +165 -0
- package/dist/cjs/locales/de-DE/grafana-sql.json.cjs.map +1 -0
- package/dist/cjs/locales/en-US/grafana-sql.json.cjs +165 -0
- package/dist/cjs/locales/en-US/grafana-sql.json.cjs.map +1 -0
- package/dist/cjs/locales/es-ES/grafana-sql.json.cjs +165 -0
- package/dist/cjs/locales/es-ES/grafana-sql.json.cjs.map +1 -0
- package/dist/cjs/locales/fr-FR/grafana-sql.json.cjs +165 -0
- package/dist/cjs/locales/fr-FR/grafana-sql.json.cjs.map +1 -0
- package/dist/cjs/locales/hu-HU/grafana-sql.json.cjs +165 -0
- package/dist/cjs/locales/hu-HU/grafana-sql.json.cjs.map +1 -0
- package/dist/cjs/locales/id-ID/grafana-sql.json.cjs +165 -0
- package/dist/cjs/locales/id-ID/grafana-sql.json.cjs.map +1 -0
- package/dist/cjs/locales/it-IT/grafana-sql.json.cjs +165 -0
- package/dist/cjs/locales/it-IT/grafana-sql.json.cjs.map +1 -0
- package/dist/cjs/locales/ja-JP/grafana-sql.json.cjs +165 -0
- package/dist/cjs/locales/ja-JP/grafana-sql.json.cjs.map +1 -0
- package/dist/cjs/locales/ko-KR/grafana-sql.json.cjs +165 -0
- package/dist/cjs/locales/ko-KR/grafana-sql.json.cjs.map +1 -0
- package/dist/cjs/locales/nl-NL/grafana-sql.json.cjs +165 -0
- package/dist/cjs/locales/nl-NL/grafana-sql.json.cjs.map +1 -0
- package/dist/cjs/locales/pl-PL/grafana-sql.json.cjs +165 -0
- package/dist/cjs/locales/pl-PL/grafana-sql.json.cjs.map +1 -0
- package/dist/cjs/locales/pt-BR/grafana-sql.json.cjs +165 -0
- package/dist/cjs/locales/pt-BR/grafana-sql.json.cjs.map +1 -0
- package/dist/cjs/locales/pt-PT/grafana-sql.json.cjs +165 -0
- package/dist/cjs/locales/pt-PT/grafana-sql.json.cjs.map +1 -0
- package/dist/cjs/locales/ru-RU/grafana-sql.json.cjs +165 -0
- package/dist/cjs/locales/ru-RU/grafana-sql.json.cjs.map +1 -0
- package/dist/cjs/locales/sv-SE/grafana-sql.json.cjs +165 -0
- package/dist/cjs/locales/sv-SE/grafana-sql.json.cjs.map +1 -0
- package/dist/cjs/locales/tr-TR/grafana-sql.json.cjs +165 -0
- package/dist/cjs/locales/tr-TR/grafana-sql.json.cjs.map +1 -0
- package/dist/cjs/locales/zh-Hans/grafana-sql.json.cjs +165 -0
- package/dist/cjs/locales/zh-Hans/grafana-sql.json.cjs.map +1 -0
- package/dist/cjs/locales/zh-Hant/grafana-sql.json.cjs +165 -0
- package/dist/cjs/locales/zh-Hant/grafana-sql.json.cjs.map +1 -0
- package/dist/cjs/types.cjs +24 -0
- package/dist/cjs/types.cjs.map +1 -0
- package/dist/cjs/utils/formatSQL.cjs +19 -0
- package/dist/cjs/utils/formatSQL.cjs.map +1 -0
- package/dist/cjs/utils/getColumnsWithIndices.cjs +33 -0
- package/dist/cjs/utils/getColumnsWithIndices.cjs.map +1 -0
- package/dist/cjs/utils/logging.cjs +11 -0
- package/dist/cjs/utils/logging.cjs.map +1 -0
- package/dist/cjs/utils/migration.cjs +24 -0
- package/dist/cjs/utils/migration.cjs.map +1 -0
- package/dist/cjs/utils/sql.utils.cjs +75 -0
- package/dist/cjs/utils/sql.utils.cjs.map +1 -0
- package/dist/cjs/utils/testHelpers.cjs +31 -0
- package/dist/cjs/utils/testHelpers.cjs.map +1 -0
- package/dist/cjs/utils/useSqlChange.cjs +22 -0
- package/dist/cjs/utils/useSqlChange.cjs.map +1 -0
- package/dist/esm/ResponseParser.mjs +25 -0
- package/dist/esm/ResponseParser.mjs.map +1 -0
- package/dist/esm/SQLVariableEditor.mjs +82 -0
- package/dist/esm/SQLVariableEditor.mjs.map +1 -0
- package/dist/esm/SQLVariableSupport.mjs +36 -0
- package/dist/esm/SQLVariableSupport.mjs.map +1 -0
- package/dist/esm/SQLVariableUtils.mjs +68 -0
- package/dist/esm/SQLVariableUtils.mjs.map +1 -0
- package/dist/esm/components/ConfirmModal.mjs +52 -0
- package/dist/esm/components/ConfirmModal.mjs.map +1 -0
- package/dist/esm/components/DatasetSelector.mjs +44 -0
- package/dist/esm/components/DatasetSelector.mjs.map +1 -0
- package/dist/esm/components/QueryEditor.mjs +122 -0
- package/dist/esm/components/QueryEditor.mjs.map +1 -0
- package/dist/esm/components/QueryEditorLazy.mjs +38 -0
- package/dist/esm/components/QueryEditorLazy.mjs.map +1 -0
- package/dist/esm/components/QueryHeader.mjs +290 -0
- package/dist/esm/components/QueryHeader.mjs.map +1 -0
- package/dist/esm/components/TableSelector.mjs +37 -0
- package/dist/esm/components/TableSelector.mjs.map +1 -0
- package/dist/esm/components/configuration/ConnectionLimits.mjs +158 -0
- package/dist/esm/components/configuration/ConnectionLimits.mjs.map +1 -0
- package/dist/esm/components/configuration/Divider.mjs +21 -0
- package/dist/esm/components/configuration/Divider.mjs.map +1 -0
- package/dist/esm/components/configuration/MaxLifetimeField.mjs +37 -0
- package/dist/esm/components/configuration/MaxLifetimeField.mjs.map +1 -0
- package/dist/esm/components/configuration/MaxOpenConnectionsField.mjs +49 -0
- package/dist/esm/components/configuration/MaxOpenConnectionsField.mjs.map +1 -0
- package/dist/esm/components/configuration/NumberInput.mjs +33 -0
- package/dist/esm/components/configuration/NumberInput.mjs.map +1 -0
- package/dist/esm/components/configuration/TLSSecretsConfig.mjs +102 -0
- package/dist/esm/components/configuration/TLSSecretsConfig.mjs.map +1 -0
- package/dist/esm/components/configuration/useMigrateDatabaseFields.mjs +48 -0
- package/dist/esm/components/configuration/useMigrateDatabaseFields.mjs.map +1 -0
- package/dist/esm/components/query-editor-raw/QueryEditorRaw.mjs +36 -0
- package/dist/esm/components/query-editor-raw/QueryEditorRaw.mjs.map +1 -0
- package/dist/esm/components/query-editor-raw/QueryToolbox.mjs +104 -0
- package/dist/esm/components/query-editor-raw/QueryToolbox.mjs.map +1 -0
- package/dist/esm/components/query-editor-raw/QueryValidator.mjs +96 -0
- package/dist/esm/components/query-editor-raw/QueryValidator.mjs.map +1 -0
- package/dist/esm/components/query-editor-raw/RawEditor.mjs +108 -0
- package/dist/esm/components/query-editor-raw/RawEditor.mjs.map +1 -0
- package/dist/esm/components/visual-query-builder/AwesomeQueryBuilder.mjs +266 -0
- package/dist/esm/components/visual-query-builder/AwesomeQueryBuilder.mjs.map +1 -0
- package/dist/esm/components/visual-query-builder/GroupByRow.mjs +65 -0
- package/dist/esm/components/visual-query-builder/GroupByRow.mjs.map +1 -0
- package/dist/esm/components/visual-query-builder/OrderByRow.mjs +78 -0
- package/dist/esm/components/visual-query-builder/OrderByRow.mjs.map +1 -0
- package/dist/esm/components/visual-query-builder/Preview.mjs +51 -0
- package/dist/esm/components/visual-query-builder/Preview.mjs.map +1 -0
- package/dist/esm/components/visual-query-builder/SQLGroupByRow.mjs +14 -0
- package/dist/esm/components/visual-query-builder/SQLGroupByRow.mjs.map +1 -0
- package/dist/esm/components/visual-query-builder/SQLOrderByRow.mjs +14 -0
- package/dist/esm/components/visual-query-builder/SQLOrderByRow.mjs.map +1 -0
- package/dist/esm/components/visual-query-builder/SQLWhereRow.mjs +51 -0
- package/dist/esm/components/visual-query-builder/SQLWhereRow.mjs.map +1 -0
- package/dist/esm/components/visual-query-builder/SelectColumn.mjs +26 -0
- package/dist/esm/components/visual-query-builder/SelectColumn.mjs.map +1 -0
- package/dist/esm/components/visual-query-builder/SelectCustomFunctionParameters.mjs +131 -0
- package/dist/esm/components/visual-query-builder/SelectCustomFunctionParameters.mjs.map +1 -0
- package/dist/esm/components/visual-query-builder/SelectFunctionParameters.mjs +138 -0
- package/dist/esm/components/visual-query-builder/SelectFunctionParameters.mjs.map +1 -0
- package/dist/esm/components/visual-query-builder/SelectRow.mjs +180 -0
- package/dist/esm/components/visual-query-builder/SelectRow.mjs.map +1 -0
- package/dist/esm/components/visual-query-builder/VisualEditor.mjs +39 -0
- package/dist/esm/components/visual-query-builder/VisualEditor.mjs.map +1 -0
- package/dist/esm/components/visual-query-builder/WhereRow.mjs +80 -0
- package/dist/esm/components/visual-query-builder/WhereRow.mjs.map +1 -0
- package/dist/esm/constants.mjs +71 -0
- package/dist/esm/constants.mjs.map +1 -0
- package/dist/esm/datasource/SqlDatasource.mjs +184 -0
- package/dist/esm/datasource/SqlDatasource.mjs.map +1 -0
- package/dist/esm/defaults.mjs +28 -0
- package/dist/esm/defaults.mjs.map +1 -0
- package/dist/esm/expressions.mjs +18 -0
- package/dist/esm/expressions.mjs.map +1 -0
- package/dist/esm/index.mjs +22 -0
- package/dist/esm/index.mjs.map +1 -0
- package/dist/esm/loadResources.mjs +43 -0
- package/dist/esm/loadResources.mjs.map +1 -0
- package/dist/esm/locales/cs-CZ/grafana-sql.json.mjs +163 -0
- package/dist/esm/locales/cs-CZ/grafana-sql.json.mjs.map +1 -0
- package/dist/esm/locales/de-DE/grafana-sql.json.mjs +163 -0
- package/dist/esm/locales/de-DE/grafana-sql.json.mjs.map +1 -0
- package/dist/esm/locales/en-US/grafana-sql.json.mjs +163 -0
- package/dist/esm/locales/en-US/grafana-sql.json.mjs.map +1 -0
- package/dist/esm/locales/es-ES/grafana-sql.json.mjs +163 -0
- package/dist/esm/locales/es-ES/grafana-sql.json.mjs.map +1 -0
- package/dist/esm/locales/fr-FR/grafana-sql.json.mjs +163 -0
- package/dist/esm/locales/fr-FR/grafana-sql.json.mjs.map +1 -0
- package/dist/esm/locales/hu-HU/grafana-sql.json.mjs +163 -0
- package/dist/esm/locales/hu-HU/grafana-sql.json.mjs.map +1 -0
- package/dist/esm/locales/id-ID/grafana-sql.json.mjs +163 -0
- package/dist/esm/locales/id-ID/grafana-sql.json.mjs.map +1 -0
- package/dist/esm/locales/it-IT/grafana-sql.json.mjs +163 -0
- package/dist/esm/locales/it-IT/grafana-sql.json.mjs.map +1 -0
- package/dist/esm/locales/ja-JP/grafana-sql.json.mjs +163 -0
- package/dist/esm/locales/ja-JP/grafana-sql.json.mjs.map +1 -0
- package/dist/esm/locales/ko-KR/grafana-sql.json.mjs +163 -0
- package/dist/esm/locales/ko-KR/grafana-sql.json.mjs.map +1 -0
- package/dist/esm/locales/nl-NL/grafana-sql.json.mjs +163 -0
- package/dist/esm/locales/nl-NL/grafana-sql.json.mjs.map +1 -0
- package/dist/esm/locales/pl-PL/grafana-sql.json.mjs +163 -0
- package/dist/esm/locales/pl-PL/grafana-sql.json.mjs.map +1 -0
- package/dist/esm/locales/pt-BR/grafana-sql.json.mjs +163 -0
- package/dist/esm/locales/pt-BR/grafana-sql.json.mjs.map +1 -0
- package/dist/esm/locales/pt-PT/grafana-sql.json.mjs +163 -0
- package/dist/esm/locales/pt-PT/grafana-sql.json.mjs.map +1 -0
- package/dist/esm/locales/ru-RU/grafana-sql.json.mjs +163 -0
- package/dist/esm/locales/ru-RU/grafana-sql.json.mjs.map +1 -0
- package/dist/esm/locales/sv-SE/grafana-sql.json.mjs +163 -0
- package/dist/esm/locales/sv-SE/grafana-sql.json.mjs.map +1 -0
- package/dist/esm/locales/tr-TR/grafana-sql.json.mjs +163 -0
- package/dist/esm/locales/tr-TR/grafana-sql.json.mjs.map +1 -0
- package/dist/esm/locales/zh-Hans/grafana-sql.json.mjs +163 -0
- package/dist/esm/locales/zh-Hans/grafana-sql.json.mjs.map +1 -0
- package/dist/esm/locales/zh-Hant/grafana-sql.json.mjs +163 -0
- package/dist/esm/locales/zh-Hant/grafana-sql.json.mjs.map +1 -0
- package/dist/esm/types.mjs +18 -0
- package/dist/esm/types.mjs.map +1 -0
- package/dist/esm/utils/formatSQL.mjs +11 -0
- package/dist/esm/utils/formatSQL.mjs.map +1 -0
- package/dist/esm/utils/getColumnsWithIndices.mjs +29 -0
- package/dist/esm/utils/getColumnsWithIndices.mjs.map +1 -0
- package/dist/esm/utils/logging.mjs +7 -0
- package/dist/esm/utils/logging.mjs.map +1 -0
- package/dist/esm/utils/migration.mjs +22 -0
- package/dist/esm/utils/migration.mjs.map +1 -0
- package/dist/esm/utils/sql.utils.mjs +66 -0
- package/dist/esm/utils/sql.utils.mjs.map +1 -0
- package/dist/esm/utils/testHelpers.mjs +27 -0
- package/dist/esm/utils/testHelpers.mjs.map +1 -0
- package/dist/esm/utils/useSqlChange.mjs +18 -0
- package/dist/esm/utils/useSqlChange.mjs.map +1 -0
- package/dist/types/ResponseParser.d.ts +5 -0
- package/dist/types/SQLVariableEditor.d.ts +5 -0
- package/dist/types/SQLVariableSupport.d.ts +11 -0
- package/dist/types/SQLVariableUtils.d.ts +6 -0
- package/dist/types/components/ConfirmModal.d.ts +8 -0
- package/dist/types/components/DatasetSelector.d.ts +11 -0
- package/dist/types/components/ErrorBoundary.d.ts +12 -0
- package/dist/types/components/QueryEditor.d.ts +8 -0
- package/dist/types/components/QueryEditorLazy.d.ts +2 -0
- package/dist/types/components/QueryHeader.d.ts +16 -0
- package/dist/types/components/SqlComponents.testHelpers.d.ts +65 -0
- package/dist/types/components/TableSelector.d.ts +10 -0
- package/dist/types/components/configuration/ConnectionLimits.d.ts +8 -0
- package/dist/types/components/configuration/Divider.d.ts +1 -0
- package/dist/types/components/configuration/MaxLifetimeField.d.ts +8 -0
- package/dist/types/components/configuration/MaxOpenConnectionsField.d.ts +8 -0
- package/dist/types/components/configuration/NumberInput.d.ts +8 -0
- package/dist/types/components/configuration/TLSSecretsConfig.d.ts +9 -0
- package/dist/types/components/configuration/useMigrateDatabaseFields.d.ts +7 -0
- package/dist/types/components/index.d.ts +1 -0
- package/dist/types/components/query-editor-raw/QueryEditorRaw.d.ts +15 -0
- package/dist/types/components/query-editor-raw/QueryToolbox.d.ts +10 -0
- package/dist/types/components/query-editor-raw/QueryValidator.d.ts +9 -0
- package/dist/types/components/query-editor-raw/RawEditor.d.ts +9 -0
- package/dist/types/components/visual-query-builder/AwesomeQueryBuilder.d.ts +6 -0
- package/dist/types/components/visual-query-builder/GroupByRow.d.ts +9 -0
- package/dist/types/components/visual-query-builder/OrderByRow.d.ts +10 -0
- package/dist/types/components/visual-query-builder/Preview.d.ts +6 -0
- package/dist/types/components/visual-query-builder/SQLGroupByRow.d.ts +11 -0
- package/dist/types/components/visual-query-builder/SQLOrderByRow.d.ts +11 -0
- package/dist/types/components/visual-query-builder/SQLWhereRow.d.ts +12 -0
- package/dist/types/components/visual-query-builder/SelectColumn.d.ts +8 -0
- package/dist/types/components/visual-query-builder/SelectCustomFunctionParameters.d.ts +11 -0
- package/dist/types/components/visual-query-builder/SelectFunctionParameters.d.ts +11 -0
- package/dist/types/components/visual-query-builder/SelectRow.d.ts +10 -0
- package/dist/types/components/visual-query-builder/VisualEditor.d.ts +8 -0
- package/dist/types/components/visual-query-builder/WhereRow.d.ts +9 -0
- package/dist/types/components/visual-query-builder/index.d.ts +1 -0
- package/dist/types/constants.d.ts +12 -0
- package/dist/types/datasource/SqlDatasource.d.ts +38 -0
- package/dist/types/defaults.d.ts +3 -0
- package/dist/types/expressions.d.ts +51 -0
- package/dist/types/index.d.ts +21 -0
- package/dist/types/loadResources.d.ts +2 -0
- package/dist/types/types.d.ts +152 -0
- package/dist/types/utils/formatSQL.d.ts +1 -0
- package/dist/types/utils/getColumnsWithIndices.d.ts +3 -0
- package/dist/types/utils/logging.d.ts +2 -0
- package/dist/types/utils/migration.d.ts +3 -0
- package/dist/types/utils/sql.utils.d.ts +21 -0
- package/dist/types/utils/testHelpers.d.ts +2 -0
- package/dist/types/utils/useSqlChange.d.ts +10 -0
- package/package.json +80 -4
|
@@ -0,0 +1,163 @@
|
|
|
1
|
+
var grafanaSql = {
|
|
2
|
+
"grafana-sql": {
|
|
3
|
+
components: {
|
|
4
|
+
"confirm-modal": {
|
|
5
|
+
"builder-mode": "Oluşturucu modu, kodda yapılan değişiklikleri görüntülemez. Sorgu oluşturucu, oluşturucu modunda yaptığınız son değişiklikleri görüntüler.",
|
|
6
|
+
cancel: "İptal et",
|
|
7
|
+
clipboard: "Kodunuzu panoya kopyalamak istiyor musunuz?",
|
|
8
|
+
"copy-code-and-switch": "Kodu kopyala ve geçiş yap",
|
|
9
|
+
"discard-code-and-switch": "Kodu sil ve geçiş yap",
|
|
10
|
+
warning: "Uyarı"
|
|
11
|
+
},
|
|
12
|
+
"connection-limits": {
|
|
13
|
+
"auto-max-idle": "Otomatik maksimum boşta bağlantı sayısı",
|
|
14
|
+
"content-auto-max-idle": "",
|
|
15
|
+
"content-max-idle": "Boşta bağlantı havuzunda tutulacak maksimum bağlantı sayısıdır. <i>Maksimum açık bağlantı</i> değeri 0'dan büyük ve <i>Maksimum boşta bağlantı</i> değerinden küçükse <i>Maksimum boşta bağlantı</i> değeri, <i>Maksimum açık bağlantı</i>değerine düşürülür. 0 olarak ayarlanırsa boşta bağlantılar tutulmaz.",
|
|
16
|
+
"content-max-lifetime": "Saniye cinsinden bir bağlantının yeniden kullanılabileceği maksimum süre. 0 olarak ayarlanırsa bağlantılar süresiz olarak yeniden kullanılır.",
|
|
17
|
+
"content-max-open": "",
|
|
18
|
+
"max-idle": "Maks. boşta",
|
|
19
|
+
"max-lifetime": "Maksimum kullanım süresi",
|
|
20
|
+
"max-open": "Maks. açık",
|
|
21
|
+
"title-connection-limits": "Bağlantı sınırları"
|
|
22
|
+
},
|
|
23
|
+
"dataset-selector": {
|
|
24
|
+
"aria-label-dataset-selector": "Veri kümesi seçici"
|
|
25
|
+
},
|
|
26
|
+
"error-boundary": {
|
|
27
|
+
"fall-back": {
|
|
28
|
+
error: "Hata"
|
|
29
|
+
}
|
|
30
|
+
},
|
|
31
|
+
"get-custom-operators": {
|
|
32
|
+
"custom-operators": {
|
|
33
|
+
label: {
|
|
34
|
+
macros: "Makrolar"
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
},
|
|
38
|
+
"make-render-column": {
|
|
39
|
+
"render-column": {
|
|
40
|
+
"aria-label-group-by": "Gruplama ölçütü",
|
|
41
|
+
"title-remove-group-by-column": "Grubu sütuna göre kaldır"
|
|
42
|
+
}
|
|
43
|
+
},
|
|
44
|
+
"order-by-row": {
|
|
45
|
+
"aria-label-order-by": "Sıralama ölçütü",
|
|
46
|
+
"label-limit": "Sınırlama",
|
|
47
|
+
"label-offset": "Ofset",
|
|
48
|
+
"label-order-by": "Sıralama ölçütü"
|
|
49
|
+
},
|
|
50
|
+
preview: {
|
|
51
|
+
"label-element": {
|
|
52
|
+
preview: "Ön izleme",
|
|
53
|
+
"tooltip-copy-to-clipboard": "Panoya kopyala"
|
|
54
|
+
}
|
|
55
|
+
},
|
|
56
|
+
"query-header": {
|
|
57
|
+
"content-invalid-query": "",
|
|
58
|
+
"editor-modes": {
|
|
59
|
+
"label-builder": "Oluşturucu",
|
|
60
|
+
"label-code": "Kod"
|
|
61
|
+
},
|
|
62
|
+
"label-dataset": "Veri kümesi",
|
|
63
|
+
"label-filter": "Filtreleyin",
|
|
64
|
+
"label-format": "Biçim",
|
|
65
|
+
"label-group": "Grup",
|
|
66
|
+
"label-order": "Sipariş",
|
|
67
|
+
"label-preview": "Ön izleme",
|
|
68
|
+
"label-table": "Tablo",
|
|
69
|
+
"placeholder-select-format": "Biçimi seçin",
|
|
70
|
+
"run-query": "Sorgu çalıştır"
|
|
71
|
+
},
|
|
72
|
+
"query-meta": {
|
|
73
|
+
variables: {
|
|
74
|
+
textField: "Metin Alanı",
|
|
75
|
+
valueField: "Değer Alanı"
|
|
76
|
+
}
|
|
77
|
+
},
|
|
78
|
+
"query-toolbox": {
|
|
79
|
+
"content-hit-ctrlcmdreturn-to-run-query": "Sorguyu çalıştırmak için CTRL/CMD+Return tuşlarına basın",
|
|
80
|
+
"tooltip-collapse": "Düzenleyiciyi daralt",
|
|
81
|
+
"tooltip-expand": "Düzenleyiciyi genişlet",
|
|
82
|
+
"tooltip-format-query": "Sorguyu biçimlendir"
|
|
83
|
+
},
|
|
84
|
+
"query-validator": {
|
|
85
|
+
"query-will-process": "<0></0> Bu sorgu çalıştırıldığında <strong>{{bytes}}</strong> veri işlenecek.",
|
|
86
|
+
"validating-query": "Sorgu doğrulanıyor..."
|
|
87
|
+
},
|
|
88
|
+
"raw-editor": {
|
|
89
|
+
"render-placeholder": {
|
|
90
|
+
"editing-in-expanded-code-editor": "Genişletilmiş kod düzenleyicide düzenleme"
|
|
91
|
+
},
|
|
92
|
+
"title-query-num": "{{queryNum}}. sorgu"
|
|
93
|
+
},
|
|
94
|
+
"select-column": {
|
|
95
|
+
"label-column": "Sütun"
|
|
96
|
+
},
|
|
97
|
+
"select-custom-function-parameters": {
|
|
98
|
+
"aria-label-parameter": "{{columnIndex}} sütunu için {{index}} parametresi ",
|
|
99
|
+
"render-parameters": {
|
|
100
|
+
params: {
|
|
101
|
+
"title-remove-parameter": "Parametreyi kaldır"
|
|
102
|
+
}
|
|
103
|
+
},
|
|
104
|
+
"title-add-parameter": "Parametre ekle"
|
|
105
|
+
},
|
|
106
|
+
"select-row": {
|
|
107
|
+
"aggregate-options": {
|
|
108
|
+
options: {
|
|
109
|
+
label: {
|
|
110
|
+
aggregations: "Toplamalar",
|
|
111
|
+
macros: "Makrolar"
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
},
|
|
115
|
+
label: {
|
|
116
|
+
time: "zaman",
|
|
117
|
+
value: "değer"
|
|
118
|
+
},
|
|
119
|
+
"label-alias": "Takma isim",
|
|
120
|
+
"label-data-operations": "Veri işlemleri",
|
|
121
|
+
"title-add-column": "Sütun ekle",
|
|
122
|
+
"title-remove-column": "Sütunu kaldır"
|
|
123
|
+
},
|
|
124
|
+
settings: {
|
|
125
|
+
"aria-label-conjunction": "Birleşim",
|
|
126
|
+
"aria-label-field": "Alan",
|
|
127
|
+
"aria-label-operator": "İşleç",
|
|
128
|
+
"title-button-filter": "{{ buttonLabel }} filtresi"
|
|
129
|
+
},
|
|
130
|
+
"sql-query-editor-lazy": {
|
|
131
|
+
"text-loading-editor": "Düzenleyici yükleniyor"
|
|
132
|
+
},
|
|
133
|
+
"table-selector": {
|
|
134
|
+
"aria-label-table-selector": "Tablo seçici",
|
|
135
|
+
"placeholder-loading": "Tablolar yükleniyor",
|
|
136
|
+
"placeholder-select-table": "Tablo seçin"
|
|
137
|
+
},
|
|
138
|
+
"tlssecrets-config": {
|
|
139
|
+
"content-tlsssl-client-certificate": "Bir TLS/SSL istemci sertifikasıyla kimlik doğrulamak için istemci sertifikasını burada sağlayın.",
|
|
140
|
+
"content-tlsssl-client-key": "Bir istemci TLS/SSL sertifikasıyla kimlik doğrulamak için anahtarı burada sağlayın.",
|
|
141
|
+
"content-tlsssl-root-certificate": "Seçilen TLS/SSL modu bir sunucu kök sertifikası gerektiriyorsa onu da burada sağlayın",
|
|
142
|
+
"tlsssl-client-certificate": "TLS/SSL İstemci Sertifikası",
|
|
143
|
+
"tlsssl-client-key": "TLS/SSL İstemci Anahtarı",
|
|
144
|
+
"tlsssl-root-certificate": "TLS/SSL Kök Sertifikası"
|
|
145
|
+
},
|
|
146
|
+
"visual-editor": {
|
|
147
|
+
"label-filter-by-column-value": "Sütun değerine göre filtreleyin",
|
|
148
|
+
"label-group-by-column": "Sütuna göre gruplayın"
|
|
149
|
+
},
|
|
150
|
+
widgets: {
|
|
151
|
+
"aria-label-macros-value-selector": "Makro değer seçici"
|
|
152
|
+
}
|
|
153
|
+
},
|
|
154
|
+
utils: {
|
|
155
|
+
"get-columns-width-indices": {
|
|
156
|
+
"label-selected-columns": "Seçilen sütunlar"
|
|
157
|
+
}
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
};
|
|
161
|
+
|
|
162
|
+
export { grafanaSql as default };
|
|
163
|
+
//# sourceMappingURL=grafana-sql.json.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"grafana-sql.json.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -0,0 +1,163 @@
|
|
|
1
|
+
var grafanaSql = {
|
|
2
|
+
"grafana-sql": {
|
|
3
|
+
components: {
|
|
4
|
+
"confirm-modal": {
|
|
5
|
+
"builder-mode": "生成器模式不显示代码中所做的更改。查询生成器将显示您在生成器模式下所做的最后一次更改。",
|
|
6
|
+
cancel: "取消",
|
|
7
|
+
clipboard: "您想将代码复制到剪贴板吗?",
|
|
8
|
+
"copy-code-and-switch": "复制代码并切换",
|
|
9
|
+
"discard-code-and-switch": "丢弃代码并切换",
|
|
10
|
+
warning: "警告"
|
|
11
|
+
},
|
|
12
|
+
"connection-limits": {
|
|
13
|
+
"auto-max-idle": "自动最大空闲",
|
|
14
|
+
"content-auto-max-idle": "",
|
|
15
|
+
"content-max-idle": "空闲连接池中的最大连接数。如果<i>最大打开连接数</i>大于 0 但小于<i>最大空闲连接数</i>,则<i>最大空闲连接数</i>将减少,以匹配<i>最大打开连接数</i>限制。如果设置为 0,则不保留任何空闲连接。",
|
|
16
|
+
"content-max-lifetime": "连接可以重复使用的最长时间(秒)。如果设置为 0,则连接将永久重复使用。",
|
|
17
|
+
"content-max-open": "",
|
|
18
|
+
"max-idle": "最大空闲",
|
|
19
|
+
"max-lifetime": "最大生命周期",
|
|
20
|
+
"max-open": "最大打开",
|
|
21
|
+
"title-connection-limits": "连接限制"
|
|
22
|
+
},
|
|
23
|
+
"dataset-selector": {
|
|
24
|
+
"aria-label-dataset-selector": "数据集选择器"
|
|
25
|
+
},
|
|
26
|
+
"error-boundary": {
|
|
27
|
+
"fall-back": {
|
|
28
|
+
error: "错误"
|
|
29
|
+
}
|
|
30
|
+
},
|
|
31
|
+
"get-custom-operators": {
|
|
32
|
+
"custom-operators": {
|
|
33
|
+
label: {
|
|
34
|
+
macros: "宏指令"
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
},
|
|
38
|
+
"make-render-column": {
|
|
39
|
+
"render-column": {
|
|
40
|
+
"aria-label-group-by": "分组依据",
|
|
41
|
+
"title-remove-group-by-column": "按列移除组"
|
|
42
|
+
}
|
|
43
|
+
},
|
|
44
|
+
"order-by-row": {
|
|
45
|
+
"aria-label-order-by": "排序条件",
|
|
46
|
+
"label-limit": "限制",
|
|
47
|
+
"label-offset": "偏移",
|
|
48
|
+
"label-order-by": "排序条件"
|
|
49
|
+
},
|
|
50
|
+
preview: {
|
|
51
|
+
"label-element": {
|
|
52
|
+
preview: "预览",
|
|
53
|
+
"tooltip-copy-to-clipboard": "复制到剪贴板"
|
|
54
|
+
}
|
|
55
|
+
},
|
|
56
|
+
"query-header": {
|
|
57
|
+
"content-invalid-query": "",
|
|
58
|
+
"editor-modes": {
|
|
59
|
+
"label-builder": "构建器",
|
|
60
|
+
"label-code": "代码"
|
|
61
|
+
},
|
|
62
|
+
"label-dataset": "数据集",
|
|
63
|
+
"label-filter": "筛选条件",
|
|
64
|
+
"label-format": "格式",
|
|
65
|
+
"label-group": "组",
|
|
66
|
+
"label-order": "顺序",
|
|
67
|
+
"label-preview": "预览",
|
|
68
|
+
"label-table": "表格",
|
|
69
|
+
"placeholder-select-format": "选择格式",
|
|
70
|
+
"run-query": "运行查询"
|
|
71
|
+
},
|
|
72
|
+
"query-meta": {
|
|
73
|
+
variables: {
|
|
74
|
+
textField: "文本字段",
|
|
75
|
+
valueField: "值字段"
|
|
76
|
+
}
|
|
77
|
+
},
|
|
78
|
+
"query-toolbox": {
|
|
79
|
+
"content-hit-ctrlcmdreturn-to-run-query": "按 CTRL/CMD+Return 运行查询",
|
|
80
|
+
"tooltip-collapse": "折叠编辑器",
|
|
81
|
+
"tooltip-expand": "展开编辑器",
|
|
82
|
+
"tooltip-format-query": "格式化查询"
|
|
83
|
+
},
|
|
84
|
+
"query-validator": {
|
|
85
|
+
"query-will-process": "<0></0> 此查询将在运行时处理 <strong>{{bytes}}</strong>。",
|
|
86
|
+
"validating-query": "正在验证查询..."
|
|
87
|
+
},
|
|
88
|
+
"raw-editor": {
|
|
89
|
+
"render-placeholder": {
|
|
90
|
+
"editing-in-expanded-code-editor": "在展开的代码编辑器中编辑"
|
|
91
|
+
},
|
|
92
|
+
"title-query-num": "查询 {{queryNum}}"
|
|
93
|
+
},
|
|
94
|
+
"select-column": {
|
|
95
|
+
"label-column": "列"
|
|
96
|
+
},
|
|
97
|
+
"select-custom-function-parameters": {
|
|
98
|
+
"aria-label-parameter": "{{columnIndex}} 列的参数 {{index}}",
|
|
99
|
+
"render-parameters": {
|
|
100
|
+
params: {
|
|
101
|
+
"title-remove-parameter": "移除参数"
|
|
102
|
+
}
|
|
103
|
+
},
|
|
104
|
+
"title-add-parameter": "添加参数"
|
|
105
|
+
},
|
|
106
|
+
"select-row": {
|
|
107
|
+
"aggregate-options": {
|
|
108
|
+
options: {
|
|
109
|
+
label: {
|
|
110
|
+
aggregations: "聚合",
|
|
111
|
+
macros: "宏指令"
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
},
|
|
115
|
+
label: {
|
|
116
|
+
time: "时间",
|
|
117
|
+
value: "值"
|
|
118
|
+
},
|
|
119
|
+
"label-alias": "别名",
|
|
120
|
+
"label-data-operations": "数据操作",
|
|
121
|
+
"title-add-column": "添加列",
|
|
122
|
+
"title-remove-column": "移除列"
|
|
123
|
+
},
|
|
124
|
+
settings: {
|
|
125
|
+
"aria-label-conjunction": "连词",
|
|
126
|
+
"aria-label-field": "字段",
|
|
127
|
+
"aria-label-operator": "运算符",
|
|
128
|
+
"title-button-filter": "{{ buttonLabel }}筛选器"
|
|
129
|
+
},
|
|
130
|
+
"sql-query-editor-lazy": {
|
|
131
|
+
"text-loading-editor": "正在加载编辑器"
|
|
132
|
+
},
|
|
133
|
+
"table-selector": {
|
|
134
|
+
"aria-label-table-selector": "表选择器",
|
|
135
|
+
"placeholder-loading": "正在加载表格",
|
|
136
|
+
"placeholder-select-table": "选择表格"
|
|
137
|
+
},
|
|
138
|
+
"tlssecrets-config": {
|
|
139
|
+
"content-tlsssl-client-certificate": "要使用 TLS/SSL 客户端证书进行身份验证,请在此处提供客户端证书。",
|
|
140
|
+
"content-tlsssl-client-key": "要使用客户端 TLS/SSL 证书进行身份验证,请在此处提供密钥。",
|
|
141
|
+
"content-tlsssl-root-certificate": "如果所选的 TLS/SSL 模式需要服务器根证书,请在此处提供",
|
|
142
|
+
"tlsssl-client-certificate": "TLS/SSL 客户端证书",
|
|
143
|
+
"tlsssl-client-key": "TLS 客户端密钥",
|
|
144
|
+
"tlsssl-root-certificate": "TLS/SSL 根证书"
|
|
145
|
+
},
|
|
146
|
+
"visual-editor": {
|
|
147
|
+
"label-filter-by-column-value": "按列值筛选",
|
|
148
|
+
"label-group-by-column": "按列分组"
|
|
149
|
+
},
|
|
150
|
+
widgets: {
|
|
151
|
+
"aria-label-macros-value-selector": "宏值选择器"
|
|
152
|
+
}
|
|
153
|
+
},
|
|
154
|
+
utils: {
|
|
155
|
+
"get-columns-width-indices": {
|
|
156
|
+
"label-selected-columns": "选定的列"
|
|
157
|
+
}
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
};
|
|
161
|
+
|
|
162
|
+
export { grafanaSql as default };
|
|
163
|
+
//# sourceMappingURL=grafana-sql.json.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"grafana-sql.json.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -0,0 +1,163 @@
|
|
|
1
|
+
var grafanaSql = {
|
|
2
|
+
"grafana-sql": {
|
|
3
|
+
components: {
|
|
4
|
+
"confirm-modal": {
|
|
5
|
+
"builder-mode": "編輯模式不會顯示在程式碼中的變更。查詢編輯器將顯示您在編輯器模式下所做的最後變更。",
|
|
6
|
+
cancel: "取消",
|
|
7
|
+
clipboard: "要將程式碼複製到剪貼簿嗎?",
|
|
8
|
+
"copy-code-and-switch": "複製程式碼並切換",
|
|
9
|
+
"discard-code-and-switch": "捨棄程式碼並切換",
|
|
10
|
+
warning: "警告"
|
|
11
|
+
},
|
|
12
|
+
"connection-limits": {
|
|
13
|
+
"auto-max-idle": "自動最大閒置時間",
|
|
14
|
+
"content-auto-max-idle": "",
|
|
15
|
+
"content-max-idle": "閒置連線池中的最大連線數。若<i>最大開啟連線數</i>大於 0,但小於<i>最大閒置連線數</i>,則<i>最大閒置連線數</i>將會縮減,以符合<i>最大開啟連線數</i>限制。若設定為 0,則不會保留任何閒置連線數。",
|
|
16
|
+
"content-max-lifetime": "可以重複使用連線的最長時間(秒)。若設定為 0,則會永遠重複使用連線。",
|
|
17
|
+
"content-max-open": "",
|
|
18
|
+
"max-idle": "最大閒置",
|
|
19
|
+
"max-lifetime": "最大存活期",
|
|
20
|
+
"max-open": "最大開啟數量",
|
|
21
|
+
"title-connection-limits": "連線限制"
|
|
22
|
+
},
|
|
23
|
+
"dataset-selector": {
|
|
24
|
+
"aria-label-dataset-selector": "資料集選擇器"
|
|
25
|
+
},
|
|
26
|
+
"error-boundary": {
|
|
27
|
+
"fall-back": {
|
|
28
|
+
error: "錯誤"
|
|
29
|
+
}
|
|
30
|
+
},
|
|
31
|
+
"get-custom-operators": {
|
|
32
|
+
"custom-operators": {
|
|
33
|
+
label: {
|
|
34
|
+
macros: "巨集"
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
},
|
|
38
|
+
"make-render-column": {
|
|
39
|
+
"render-column": {
|
|
40
|
+
"aria-label-group-by": "分組依據",
|
|
41
|
+
"title-remove-group-by-column": "按欄位移除群組"
|
|
42
|
+
}
|
|
43
|
+
},
|
|
44
|
+
"order-by-row": {
|
|
45
|
+
"aria-label-order-by": "排序方式",
|
|
46
|
+
"label-limit": "限制",
|
|
47
|
+
"label-offset": "位移量",
|
|
48
|
+
"label-order-by": "排序方式"
|
|
49
|
+
},
|
|
50
|
+
preview: {
|
|
51
|
+
"label-element": {
|
|
52
|
+
preview: "預覽",
|
|
53
|
+
"tooltip-copy-to-clipboard": "複製至剪貼簿"
|
|
54
|
+
}
|
|
55
|
+
},
|
|
56
|
+
"query-header": {
|
|
57
|
+
"content-invalid-query": "",
|
|
58
|
+
"editor-modes": {
|
|
59
|
+
"label-builder": "建立器",
|
|
60
|
+
"label-code": "代碼"
|
|
61
|
+
},
|
|
62
|
+
"label-dataset": "資料集",
|
|
63
|
+
"label-filter": "篩選",
|
|
64
|
+
"label-format": "格式",
|
|
65
|
+
"label-group": "群組",
|
|
66
|
+
"label-order": "排序",
|
|
67
|
+
"label-preview": "預覽",
|
|
68
|
+
"label-table": "表格",
|
|
69
|
+
"placeholder-select-format": "選擇格式",
|
|
70
|
+
"run-query": "執行查詢"
|
|
71
|
+
},
|
|
72
|
+
"query-meta": {
|
|
73
|
+
variables: {
|
|
74
|
+
textField: "文字欄位",
|
|
75
|
+
valueField: "值欄位"
|
|
76
|
+
}
|
|
77
|
+
},
|
|
78
|
+
"query-toolbox": {
|
|
79
|
+
"content-hit-ctrlcmdreturn-to-run-query": "按下 CTRL/CMD + Return 執行查詢",
|
|
80
|
+
"tooltip-collapse": "收合編輯器",
|
|
81
|
+
"tooltip-expand": "展開編輯器",
|
|
82
|
+
"tooltip-format-query": "格式化查詢"
|
|
83
|
+
},
|
|
84
|
+
"query-validator": {
|
|
85
|
+
"query-will-process": "<0></0>此查詢將在執行時處理 <strong>{{bytes}}</strong>。",
|
|
86
|
+
"validating-query": "正在驗證查詢…"
|
|
87
|
+
},
|
|
88
|
+
"raw-editor": {
|
|
89
|
+
"render-placeholder": {
|
|
90
|
+
"editing-in-expanded-code-editor": "在展開的程式碼編輯器中編輯"
|
|
91
|
+
},
|
|
92
|
+
"title-query-num": "查詢 {{queryNum}}"
|
|
93
|
+
},
|
|
94
|
+
"select-column": {
|
|
95
|
+
"label-column": "欄位"
|
|
96
|
+
},
|
|
97
|
+
"select-custom-function-parameters": {
|
|
98
|
+
"aria-label-parameter": "欄位 {{columnIndex}} 的參數 {{index}}",
|
|
99
|
+
"render-parameters": {
|
|
100
|
+
params: {
|
|
101
|
+
"title-remove-parameter": "移除參數"
|
|
102
|
+
}
|
|
103
|
+
},
|
|
104
|
+
"title-add-parameter": "新增參數"
|
|
105
|
+
},
|
|
106
|
+
"select-row": {
|
|
107
|
+
"aggregate-options": {
|
|
108
|
+
options: {
|
|
109
|
+
label: {
|
|
110
|
+
aggregations: "聚合",
|
|
111
|
+
macros: "巨集"
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
},
|
|
115
|
+
label: {
|
|
116
|
+
time: "時間",
|
|
117
|
+
value: "值"
|
|
118
|
+
},
|
|
119
|
+
"label-alias": "別名",
|
|
120
|
+
"label-data-operations": "資料操作",
|
|
121
|
+
"title-add-column": "新增欄位",
|
|
122
|
+
"title-remove-column": "移除欄位"
|
|
123
|
+
},
|
|
124
|
+
settings: {
|
|
125
|
+
"aria-label-conjunction": "連接條件",
|
|
126
|
+
"aria-label-field": "欄位",
|
|
127
|
+
"aria-label-operator": "運算子",
|
|
128
|
+
"title-button-filter": "{{ buttonLabel }} 篩選條件"
|
|
129
|
+
},
|
|
130
|
+
"sql-query-editor-lazy": {
|
|
131
|
+
"text-loading-editor": "正在載入編輯器"
|
|
132
|
+
},
|
|
133
|
+
"table-selector": {
|
|
134
|
+
"aria-label-table-selector": "表格選擇器",
|
|
135
|
+
"placeholder-loading": "載入表格…",
|
|
136
|
+
"placeholder-select-table": "選擇表格"
|
|
137
|
+
},
|
|
138
|
+
"tlssecrets-config": {
|
|
139
|
+
"content-tlsssl-client-certificate": "若要使用 TLS/SSL 用戶端憑證進行驗證,請在此提供用戶端憑證。",
|
|
140
|
+
"content-tlsssl-client-key": "若要使用用戶端 TLS/SSL 憑證進行驗證,請在此提供金鑰。",
|
|
141
|
+
"content-tlsssl-root-certificate": "若所選的 TLS/SSL 模式需要伺服器根憑證,請在此提供",
|
|
142
|
+
"tlsssl-client-certificate": "TLS/SSL 用戶端憑證",
|
|
143
|
+
"tlsssl-client-key": "TLS/SSL 用戶端金鑰",
|
|
144
|
+
"tlsssl-root-certificate": "TLS/SSL 根憑證"
|
|
145
|
+
},
|
|
146
|
+
"visual-editor": {
|
|
147
|
+
"label-filter-by-column-value": "按欄位數值篩選",
|
|
148
|
+
"label-group-by-column": "按欄位分組"
|
|
149
|
+
},
|
|
150
|
+
widgets: {
|
|
151
|
+
"aria-label-macros-value-selector": "巨集值選擇器"
|
|
152
|
+
}
|
|
153
|
+
},
|
|
154
|
+
utils: {
|
|
155
|
+
"get-columns-width-indices": {
|
|
156
|
+
"label-selected-columns": "選取的欄位"
|
|
157
|
+
}
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
};
|
|
161
|
+
|
|
162
|
+
export { grafanaSql as default };
|
|
163
|
+
//# sourceMappingURL=grafana-sql.json.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"grafana-sql.json.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { toOption as toOption$1 } from '@grafana/data';
|
|
2
|
+
|
|
3
|
+
"use strict";
|
|
4
|
+
var _a;
|
|
5
|
+
var QueryFormat = /* @__PURE__ */ ((QueryFormat2) => {
|
|
6
|
+
QueryFormat2["Timeseries"] = "time_series";
|
|
7
|
+
QueryFormat2["Table"] = "table";
|
|
8
|
+
return QueryFormat2;
|
|
9
|
+
})(QueryFormat || {});
|
|
10
|
+
const QUERY_FORMAT_OPTIONS = [
|
|
11
|
+
{ label: "Time series", value: "time_series" /* Timeseries */ },
|
|
12
|
+
{ label: "Table", value: "table" /* Table */ }
|
|
13
|
+
];
|
|
14
|
+
const backWardToOption = (value) => ({ label: value, value });
|
|
15
|
+
const toOption = (_a = toOption$1) != null ? _a : backWardToOption;
|
|
16
|
+
|
|
17
|
+
export { QUERY_FORMAT_OPTIONS, QueryFormat, toOption };
|
|
18
|
+
//# sourceMappingURL=types.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.mjs","sources":["../../src/types.ts"],"sourcesContent":["import { JsonTree } from '@react-awesome-query-builder/ui';\n\nimport {\n DataFrame,\n DataQuery,\n DataSourceJsonData,\n MetricFindValue,\n SelectableValue,\n TimeRange,\n toOption as toOptionFromData,\n} from '@grafana/data';\nimport { CompletionItemKind, EditorMode, LanguageDefinition } from '@grafana/plugin-ui';\n\nimport { QueryWithDefaults } from './defaults';\nimport {\n QueryEditorFunctionExpression,\n QueryEditorGroupByExpression,\n QueryEditorPropertyExpression,\n} from './expressions';\n\nexport interface SqlQueryForInterpolation {\n dataset?: string;\n alias?: string;\n format?: QueryFormat;\n rawSql?: string;\n refId: string;\n hide?: boolean;\n}\n\nexport interface SQLConnectionLimits {\n maxOpenConns: number;\n maxIdleConns: number;\n maxIdleConnsAuto: boolean;\n connMaxLifetime: number;\n}\n\nexport interface SQLOptions extends SQLConnectionLimits, DataSourceJsonData {\n tlsAuth: boolean;\n tlsAuthWithCACert: boolean;\n timezone: string;\n tlsSkipVerify: boolean;\n user: string;\n database: string;\n url: string;\n timeInterval: string;\n}\n\nexport enum QueryFormat {\n Timeseries = 'time_series',\n Table = 'table',\n}\n\nexport type SQLQueryMeta = { valueField?: string; textField?: string };\n\nexport interface SQLQuery extends DataQuery {\n alias?: string;\n format?: QueryFormat;\n rawSql?: string;\n dataset?: string;\n table?: string;\n sql?: SQLExpression;\n editorMode?: EditorMode;\n rawQuery?: boolean;\n meta?: SQLQueryMeta;\n}\n\nexport type SQLVariableQuery = { query: string } & SQLQuery;\n\nexport interface NameValue {\n name: string;\n value: string;\n}\n\nexport type SQLFilters = NameValue[];\n\nexport interface SQLExpression {\n columns?: QueryEditorFunctionExpression[];\n whereJsonTree?: JsonTree;\n whereString?: string;\n filters?: SQLFilters;\n groupBy?: QueryEditorGroupByExpression[];\n orderBy?: QueryEditorPropertyExpression;\n orderByDirection?: 'ASC' | 'DESC';\n limit?: number;\n offset?: number;\n}\n\nexport interface TableSchema {\n name?: string;\n schema?: TableFieldSchema[];\n}\n\nexport interface TableFieldSchema {\n name: string;\n description?: string;\n type: string;\n repeated: boolean;\n schema: TableFieldSchema[];\n}\n\nexport interface QueryRowFilter {\n filter: boolean;\n group: boolean;\n order: boolean;\n preview: boolean;\n}\n\nexport const QUERY_FORMAT_OPTIONS = [\n { label: 'Time series', value: QueryFormat.Timeseries },\n { label: 'Table', value: QueryFormat.Table },\n];\n\nconst backWardToOption = (value: string) => ({ label: value, value });\n\nexport const toOption = toOptionFromData ?? backWardToOption;\n\nexport interface ResourceSelectorProps {\n disabled?: boolean;\n className?: string;\n applyDefault?: boolean;\n}\n// React Awesome Query builder field types.\n// These are responsible for rendering the correct UI for the field.\nexport type RAQBFieldTypes = 'text' | 'number' | 'boolean' | 'datetime' | 'date' | 'time';\n\nexport interface SQLSelectableValue extends SelectableValue {\n type?: string;\n raqbFieldType?: RAQBFieldTypes;\n}\n\nexport interface DB {\n init?: (datasourceId?: string) => Promise<boolean>;\n datasets: () => Promise<string[]>;\n tables: (dataset?: string) => Promise<string[]>;\n fields: (query: SQLQuery, order?: boolean) => Promise<SQLSelectableValue[]>;\n validateQuery: (query: SQLQuery, range?: TimeRange) => Promise<ValidationResults>;\n dispose?: (dsID?: string) => void;\n lookup?: (path?: string) => Promise<Array<{ name: string; completion: string }>>;\n getEditorLanguageDefinition: () => LanguageDefinition;\n toRawSql: (query: SQLQuery) => string;\n functions: () => Func[];\n}\n\nexport interface FuncParameter {\n name: string;\n required?: boolean;\n options?: (query: SQLQuery) => Promise<SelectableValue[]>;\n}\nexport interface Func {\n name: string;\n parameters?: FuncParameter[];\n description?: string;\n}\n\nexport interface QueryEditorProps {\n db: DB;\n query: QueryWithDefaults;\n onChange: (query: SQLQuery) => void;\n range?: TimeRange;\n}\n\nexport interface ValidationResults {\n query: SQLQuery;\n rawSql?: string;\n error: string;\n isError: boolean;\n isValid: boolean;\n statistics?: {\n TotalBytesProcessed: number;\n } | null;\n}\n\nexport interface SqlQueryModel {\n quoteLiteral: (v: string) => string;\n}\n\nexport interface ResponseParser {\n transformMetricFindResponse: (frame: DataFrame) => MetricFindValue[];\n}\n\nexport interface MetaDefinition {\n name: string;\n completion?: string;\n kind: CompletionItemKind;\n}\n\nexport type SQLDialect = 'postgres' | 'influx' | 'other';\n"],"names":["QueryFormat","toOptionFromData"],"mappings":";;;AAAA,IAAA,EAAA;AA+CO,IAAK,WAAA,qBAAAA,YAAAA,KAAL;AACL,EAAAA,aAAA,YAAA,CAAA,GAAa,aAAA;AACb,EAAAA,aAAA,OAAA,CAAA,GAAQ,OAAA;AAFE,EAAA,OAAAA,YAAAA;AAAA,CAAA,EAAA,WAAA,IAAA,EAAA;AA4DL,MAAM,oBAAA,GAAuB;AAAA,EAClC,EAAE,KAAA,EAAO,aAAA,EAAe,KAAA,EAAO,aAAA,mBAAuB;AAAA,EACtD,EAAE,KAAA,EAAO,OAAA,EAAS,KAAA,EAAO,OAAA;AAC3B;AAEA,MAAM,mBAAmB,CAAC,KAAA,MAAmB,EAAE,KAAA,EAAO,OAAO,KAAA,EAAM,CAAA;AAE5D,MAAM,YAAW,EAAA,GAAAC,UAAA,KAAA,IAAA,GAAA,EAAA,GAAoB;;;;"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import sqlFormatter from 'sql-formatter-plus';
|
|
2
|
+
|
|
3
|
+
"use strict";
|
|
4
|
+
function formatSQL(q) {
|
|
5
|
+
return sqlFormatter.format(q).replace(/(\$ \{ .* \})|(\$ __)|(\$ \w+)/g, (m) => {
|
|
6
|
+
return m.replace(/\s/g, "");
|
|
7
|
+
});
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
export { formatSQL };
|
|
11
|
+
//# sourceMappingURL=formatSQL.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"formatSQL.mjs","sources":["../../../src/utils/formatSQL.ts"],"sourcesContent":["// @ts-ignore\nimport sqlFormatter from 'sql-formatter-plus';\n\nexport function formatSQL(q: string) {\n return sqlFormatter.format(q).replace(/(\\$ \\{ .* \\})|(\\$ __)|(\\$ \\w+)/g, (m: string) => {\n return m.replace(/\\s/g, '');\n });\n}\n"],"names":[],"mappings":";;;AAGO,SAAS,UAAU,CAAA,EAAW;AACnC,EAAA,OAAO,aAAa,MAAA,CAAO,CAAC,EAAE,OAAA,CAAQ,iCAAA,EAAmC,CAAC,CAAA,KAAc;AACtF,IAAA,OAAO,CAAA,CAAE,OAAA,CAAQ,KAAA,EAAO,EAAE,CAAA;AAAA,EAC5B,CAAC,CAAA;AACH;;;;"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { t } from '@grafana/i18n';
|
|
2
|
+
|
|
3
|
+
"use strict";
|
|
4
|
+
function getColumnsWithIndices(query, fields) {
|
|
5
|
+
var _a;
|
|
6
|
+
if (!fields || !((_a = query.sql) == null ? void 0 : _a.columns)) {
|
|
7
|
+
return fields;
|
|
8
|
+
}
|
|
9
|
+
const options = query.sql.columns.map((c, i) => {
|
|
10
|
+
var _a2, _b;
|
|
11
|
+
const value = c.name ? `${c.name}(${(_a2 = c.parameters) == null ? void 0 : _a2.map((p) => p.name).join(", ")})` : (_b = c.parameters) == null ? void 0 : _b.map((p) => p.name).join(", ");
|
|
12
|
+
return {
|
|
13
|
+
value,
|
|
14
|
+
label: `${i + 1} - ${value}`
|
|
15
|
+
};
|
|
16
|
+
});
|
|
17
|
+
return [
|
|
18
|
+
{
|
|
19
|
+
value: "",
|
|
20
|
+
label: t("grafana-sql.utils.get-columns-width-indices.label-selected-columns", "Selected columns"),
|
|
21
|
+
options,
|
|
22
|
+
expanded: true
|
|
23
|
+
},
|
|
24
|
+
...fields
|
|
25
|
+
];
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
export { getColumnsWithIndices };
|
|
29
|
+
//# sourceMappingURL=getColumnsWithIndices.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"getColumnsWithIndices.mjs","sources":["../../../src/utils/getColumnsWithIndices.ts"],"sourcesContent":["import { SelectableValue } from '@grafana/data';\nimport { t } from '@grafana/i18n';\n\nimport { SQLQuery } from '../types';\n\nexport function getColumnsWithIndices(query: SQLQuery, fields: SelectableValue[]): SelectableValue[] {\n if (!fields || !query.sql?.columns) {\n return fields;\n }\n\n const options = query.sql.columns.map((c, i) => {\n const value = c.name\n ? `${c.name}(${c.parameters?.map((p) => p.name).join(', ')})`\n : c.parameters?.map((p) => p.name).join(', ');\n return {\n value,\n label: `${i + 1} - ${value}`,\n };\n });\n\n return [\n {\n value: '',\n label: t('grafana-sql.utils.get-columns-width-indices.label-selected-columns', 'Selected columns'),\n options,\n expanded: true,\n },\n ...fields,\n ];\n}\n"],"names":["_a"],"mappings":";;;AAKO,SAAS,qBAAA,CAAsB,OAAiB,MAAA,EAA8C;AALrG,EAAA,IAAA,EAAA;AAME,EAAA,IAAI,CAAC,MAAA,IAAU,EAAA,CAAC,EAAA,GAAA,KAAA,CAAM,GAAA,KAAN,mBAAW,OAAA,CAAA,EAAS;AAClC,IAAA,OAAO,MAAA;AAAA,EACT;AAEA,EAAA,MAAM,UAAU,KAAA,CAAM,GAAA,CAAI,QAAQ,GAAA,CAAI,CAAC,GAAG,CAAA,KAAM;AAVlD,IAAA,IAAAA,GAAAA,EAAA,EAAA;AAWI,IAAA,MAAM,KAAA,GAAQ,CAAA,CAAE,IAAA,GACZ,CAAA,EAAG,CAAA,CAAE,IAAI,CAAA,CAAA,EAAA,CAAIA,GAAAA,GAAA,CAAA,CAAE,UAAA,KAAF,IAAA,GAAA,KAAA,CAAA,GAAAA,GAAAA,CAAc,GAAA,CAAI,CAAC,CAAA,KAAM,CAAA,CAAE,IAAA,CAAA,CAAM,IAAA,CAAK,IAAA,CAAK,CAAA,CAAA,CAAA,GAAA,CACxD,EAAA,GAAA,CAAA,CAAE,UAAA,KAAF,IAAA,GAAA,KAAA,CAAA,GAAA,EAAA,CAAc,GAAA,CAAI,CAAC,CAAA,KAAM,CAAA,CAAE,IAAA,CAAA,CAAM,IAAA,CAAK,IAAA,CAAA;AAC1C,IAAA,OAAO;AAAA,MACL,KAAA;AAAA,MACA,KAAA,EAAO,CAAA,EAAG,CAAA,GAAI,CAAC,MAAM,KAAK,CAAA;AAAA,KAC5B;AAAA,EACF,CAAC,CAAA;AAED,EAAA,OAAO;AAAA,IACL;AAAA,MACE,KAAA,EAAO,EAAA;AAAA,MACP,KAAA,EAAO,CAAA,CAAE,oEAAA,EAAsE,kBAAkB,CAAA;AAAA,MACjG,OAAA;AAAA,MACA,QAAA,EAAU;AAAA,KACZ;AAAA,IACA,GAAG;AAAA,GACL;AACF;;;;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"logging.mjs","sources":["../../../src/utils/logging.ts"],"sourcesContent":["import { createMonitoringLogger, MonitoringLogger } from '@grafana/runtime';\n\nexport const sqlPluginLogger: MonitoringLogger = createMonitoringLogger('features.plugins.sql');\n"],"names":[],"mappings":";;;AAEO,MAAM,eAAA,GAAoC,uBAAuB,sBAAsB;;;;"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { applyQueryDefaults } from '../defaults.mjs';
|
|
2
|
+
|
|
3
|
+
"use strict";
|
|
4
|
+
function migrateAnnotation(annotation) {
|
|
5
|
+
var _a;
|
|
6
|
+
const oldQuery = typeof annotation.rawQuery === "string" ? annotation.rawQuery : null;
|
|
7
|
+
if (!oldQuery) {
|
|
8
|
+
return annotation;
|
|
9
|
+
}
|
|
10
|
+
const newQuery = applyQueryDefaults({ refId: "Annotation", ...(_a = annotation.target) != null ? _a : {}, rawSql: oldQuery });
|
|
11
|
+
return {
|
|
12
|
+
...annotation,
|
|
13
|
+
rawQuery: void 0,
|
|
14
|
+
workspace: void 0,
|
|
15
|
+
subscription: void 0,
|
|
16
|
+
queryType: void 0,
|
|
17
|
+
target: newQuery
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
export { migrateAnnotation as default };
|
|
22
|
+
//# sourceMappingURL=migration.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"migration.mjs","sources":["../../../src/utils/migration.ts"],"sourcesContent":["import { AnnotationQuery } from '@grafana/data';\n\nimport { applyQueryDefaults } from '../defaults';\nimport { SQLQuery } from '../types';\n\nexport default function migrateAnnotation(annotation: AnnotationQuery<SQLQuery>) {\n const oldQuery = typeof annotation.rawQuery === 'string' ? annotation.rawQuery : null;\n\n if (!oldQuery) {\n return annotation;\n }\n\n const newQuery = applyQueryDefaults({ refId: 'Annotation', ...(annotation.target ?? {}), rawSql: oldQuery });\n\n return {\n ...annotation,\n rawQuery: undefined,\n workspace: undefined,\n subscription: undefined,\n queryType: undefined,\n target: newQuery,\n };\n}\n"],"names":[],"mappings":";;;AAKA,SAAwB,kBAAkB,UAAA,EAAuC;AALjF,EAAA,IAAA,EAAA;AAME,EAAA,MAAM,WAAW,OAAO,UAAA,CAAW,QAAA,KAAa,QAAA,GAAW,WAAW,QAAA,GAAW,IAAA;AAEjF,EAAA,IAAI,CAAC,QAAA,EAAU;AACb,IAAA,OAAO,UAAA;AAAA,EACT;AAEA,EAAA,MAAM,QAAA,GAAW,kBAAA,CAAmB,EAAE,KAAA,EAAO,YAAA,EAAc,GAAA,CAAI,EAAA,GAAA,UAAA,CAAW,MAAA,KAAX,IAAA,GAAA,EAAA,GAAqB,EAAC,EAAI,MAAA,EAAQ,UAAU,CAAA;AAE3G,EAAA,OAAO;AAAA,IACL,GAAG,UAAA;AAAA,IACH,QAAA,EAAU,KAAA,CAAA;AAAA,IACV,SAAA,EAAW,KAAA,CAAA;AAAA,IACX,YAAA,EAAc,KAAA,CAAA;AAAA,IACd,SAAA,EAAW,KAAA,CAAA;AAAA,IACX,MAAA,EAAQ;AAAA,GACV;AACF;;;;"}
|