Skip to content

Commit

Permalink
chore: replace icon with img in new data source dialog
Browse files Browse the repository at this point in the history
  • Loading branch information
nextchamp-saqib committed Jan 25, 2024
1 parent 351c755 commit 19c74c8
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
7 changes: 6 additions & 1 deletion frontend/src/components/NewDialogWithTypes.vue
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,12 @@ const show = computed({
<div
class="rounded border p-4 text-gray-500 shadow-sm transition-all group-hover:scale-105"
>
<FeatherIcon :name="type.icon" class="h-6 w-6 text-gray-500" />
<FeatherIcon
v-if="type.icon"
:name="type.icon"
class="h-6 w-6 text-gray-500"
/>
<img v-if="type.imgSrc" :src="type.imgSrc" class="h-6 w-6" />
</div>
<div>
<div class="flex items-center space-x-2">
Expand Down
6 changes: 3 additions & 3 deletions frontend/src/datasource/DataSourceList.vue
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ const databaseTypes = ref([
{
label: 'MariaDB',
description: 'Connect to a MariaDB database',
icon: 'database',
imgSrc: '/src/assets/MariaDBIcon.png',
onClick: () => {
new_dialog.value = false
showConnectMariaDBDialog.value = true
Expand All @@ -110,7 +110,7 @@ const databaseTypes = ref([
{
label: 'PostgreSQL',
description: 'Connect to a PostgreSQL database',
icon: 'database',
imgSrc: '/src/assets/PostgreSQLIcon.png',
onClick: () => {
new_dialog.value = false
showConnectPostgreDBDialog.value = true
Expand All @@ -119,7 +119,7 @@ const databaseTypes = ref([
{
label: 'CSV',
description: 'Upload a CSV file',
icon: 'file',
imgSrc: '/src/assets/SheetIcon.png',
onClick: () => {
new_dialog.value = false
showCSVFileUploadDialog.value = true
Expand Down

0 comments on commit 19c74c8

Please sign in to comment.