From c749209172e7c5a97b112350f7a5125ca604e3e9 Mon Sep 17 00:00:00 2001 From: Gerard Burns Date: Tue, 27 Jun 2023 15:49:17 +0100 Subject: [PATCH] PR Feedback --- .../buttons/ExistingRelationshipButton.svelte | 2 +- .../Queries/RestImportQueriesModal.svelte | 2 +- .../_components/panels/Relationships.svelte | 2 +- .../panels/SaveDatasourceButton.svelte | 2 +- .../_components/panels/Tables/Controls.svelte | 2 +- .../_components/panels/Tooltip.svelte | 27 +++---------------- .../builder/src/stores/backend/datasources.js | 2 +- 7 files changed, 10 insertions(+), 29 deletions(-) diff --git a/packages/builder/src/components/backend/DataTable/buttons/ExistingRelationshipButton.svelte b/packages/builder/src/components/backend/DataTable/buttons/ExistingRelationshipButton.svelte index d0b0d9e68c..839c396614 100644 --- a/packages/builder/src/components/backend/DataTable/buttons/ExistingRelationshipButton.svelte +++ b/packages/builder/src/components/backend/DataTable/buttons/ExistingRelationshipButton.svelte @@ -23,7 +23,7 @@ } const afterSave = ({ action }) => { - notifications.success(`Relationship ${action} successfully.`) + notifications.success(`Relationship ${action} successfully`) dispatch("updatecolumns") } diff --git a/packages/builder/src/pages/builder/app/[application]/data/datasource/[datasourceId]/_components/panels/Queries/RestImportQueriesModal.svelte b/packages/builder/src/pages/builder/app/[application]/data/datasource/[datasourceId]/_components/panels/Queries/RestImportQueriesModal.svelte index 82a2aa8066..c11093a0ed 100644 --- a/packages/builder/src/pages/builder/app/[application]/data/datasource/[datasourceId]/_components/panels/Queries/RestImportQueriesModal.svelte +++ b/packages/builder/src/pages/builder/app/[application]/data/datasource/[datasourceId]/_components/panels/Queries/RestImportQueriesModal.svelte @@ -69,7 +69,7 @@ $goto(`./datasource/${datasourceId}`) } - notifications.success(`Imported successfully.`) + notifications.success("Imported successfully") return true } catch (error) { notifications.error("Error importing queries") diff --git a/packages/builder/src/pages/builder/app/[application]/data/datasource/[datasourceId]/_components/panels/Relationships.svelte b/packages/builder/src/pages/builder/app/[application]/data/datasource/[datasourceId]/_components/panels/Relationships.svelte index aa655ad878..384b87e11d 100644 --- a/packages/builder/src/pages/builder/app/[application]/data/datasource/[datasourceId]/_components/panels/Relationships.svelte +++ b/packages/builder/src/pages/builder/app/[application]/data/datasource/[datasourceId]/_components/panels/Relationships.svelte @@ -64,7 +64,7 @@ const afterSave = async ({ action }) => { await tablesStore.fetch() await datasourcesStore.fetch() - notifications.success(`Relationship ${action} successfully.`) + notifications.success(`Relationship ${action} successfully`) } const onError = async ({ action, err }) => { diff --git a/packages/builder/src/pages/builder/app/[application]/data/datasource/[datasourceId]/_components/panels/SaveDatasourceButton.svelte b/packages/builder/src/pages/builder/app/[application]/data/datasource/[datasourceId]/_components/panels/SaveDatasourceButton.svelte index c47475c01a..f53215b8ce 100644 --- a/packages/builder/src/pages/builder/app/[application]/data/datasource/[datasourceId]/_components/panels/SaveDatasourceButton.svelte +++ b/packages/builder/src/pages/builder/app/[application]/data/datasource/[datasourceId]/_components/panels/SaveDatasourceButton.svelte @@ -18,7 +18,7 @@ ) await datasources.update({ datasource: updatedDatasource, integration }) notifications.success( - `Datasource ${updatedDatasource.name} updated successfully.` + `Datasource ${updatedDatasource.name} updated successfully` ) } catch (error) { notifications.error(`Error saving datasource: ${error.message}`) diff --git a/packages/builder/src/pages/builder/app/[application]/data/datasource/[datasourceId]/_components/panels/Tables/Controls.svelte b/packages/builder/src/pages/builder/app/[application]/data/datasource/[datasourceId]/_components/panels/Tables/Controls.svelte index 9ab65865ed..881f39992a 100644 --- a/packages/builder/src/pages/builder/app/[application]/data/datasource/[datasourceId]/_components/panels/Tables/Controls.svelte +++ b/packages/builder/src/pages/builder/app/[application]/data/datasource/[datasourceId]/_components/panels/Tables/Controls.svelte @@ -15,7 +15,7 @@ async function updateDatasourceSchema() { try { await datasources.updateSchema(datasource, specificTables) - notifications.success(`Datasource ${name} tables updated successfully.`) + notifications.success(`Datasource ${name} tables updated successfully`) await tables.fetch() } catch (error) { notifications.error( diff --git a/packages/builder/src/pages/builder/app/[application]/data/datasource/[datasourceId]/_components/panels/Tooltip.svelte b/packages/builder/src/pages/builder/app/[application]/data/datasource/[datasourceId]/_components/panels/Tooltip.svelte index 62905fa714..bd409c4d89 100644 --- a/packages/builder/src/pages/builder/app/[application]/data/datasource/[datasourceId]/_components/panels/Tooltip.svelte +++ b/packages/builder/src/pages/builder/app/[application]/data/datasource/[datasourceId]/_components/panels/Tooltip.svelte @@ -1,30 +1,11 @@ - - - {title} - - - + window.open(href, "_blank")}> + {title} + diff --git a/packages/builder/src/stores/backend/datasources.js b/packages/builder/src/stores/backend/datasources.js index d7dc04332f..3d7c54a84c 100644 --- a/packages/builder/src/stores/backend/datasources.js +++ b/packages/builder/src/stores/backend/datasources.js @@ -100,7 +100,7 @@ export function createDatasourcesStore() { const create = async ({ integration, config }) => { const count = sourceCount(integration.name) - const nameModifier = count === 0 ? "" : `-${count + 1}` + const nameModifier = count === 0 ? "" : ` ${count + 1}` const datasource = { type: "datasource",