Browse Source

fix(nc-gui): grayed out disabled option select icon

pull/9265/head
Ramesh Mane 3 months ago
parent
commit
33319a1ba5
  1. 21
      packages/nc-gui/components/dashboard/settings/data-sources/CreateBase.vue
  2. 8
      packages/nc-gui/components/dashboard/settings/data-sources/EditBase.vue

21
packages/nc-gui/components/dashboard/settings/data-sources/CreateBase.vue

@ -540,10 +540,25 @@ const isIntgrationDisabled = (integration: IntegrationType = {}) => {
:disabled="isIntgrationDisabled(integration).isDisabled"
>
<div class="w-full flex gap-2 items-center" :data-testid="integration.title">
<GeneralIntegrationIcon v-if="integration?.sub_type" :type="integration.sub_type" />
<NcTooltip class="flex-1 truncate" :show-on-truncate-only="!isIntgrationDisabled(integration).isDisabled">
<GeneralIntegrationIcon
v-if="integration?.sub_type"
:type="integration.sub_type"
:style="{
filter: isIntgrationDisabled(integration).isDisabled
? 'grayscale(100%) brightness(115%)'
: undefined,
}"
/>
<NcTooltip
class="flex-1 truncate"
:show-on-truncate-only="!isIntgrationDisabled(integration).isDisabled"
>
<template #title>
{{ isIntgrationDisabled(integration).isDisabled ? isIntgrationDisabled(integration).msg : integration.title }}
{{
isIntgrationDisabled(integration).isDisabled
? isIntgrationDisabled(integration).msg
: integration.title
}}
</template>
{{ integration.title }}
</NcTooltip>

8
packages/nc-gui/components/dashboard/settings/data-sources/EditBase.vue

@ -415,7 +415,13 @@ function handleAutoScroll(scroll: boolean, className: string) {
>
<a-select-option v-for="integration in integrations" :key="integration.id" :value="integration.id">
<div class="w-full flex gap-2 items-center" :data-testid="integration.title">
<GeneralIntegrationIcon v-if="integration?.sub_type" :type="integration.sub_type" />
<GeneralIntegrationIcon
v-if="integration?.sub_type"
:type="integration.sub_type"
:style="{
filter: 'grayscale(100%) brightness(115%)',
}"
/>
<NcTooltip class="flex-1 truncate" show-on-truncate-only>
<template #title>
{{ integration.title }}

Loading…
Cancel
Save