π₯ π₯ π₯ A Free & Self-hostable Airtable Alternative
TypeScript airtableairtable-alternativeautomatic-apihacktoberfestlow-codeno-codeno-code-databaseno-code-platformpostgresqlrest-apirestful-apispreadsheetsqliteswagger
fix: keep directly opened create base mode selection design as dropdown
Ramesh Mane71315d59bf2c
diff --git a/packages/nc-gui/components/dashboard/TreeView/CreateProject/MenuItem.vue b/packages/nc-gui/components/dashboard/TreeView/CreateProject/MenuItem.vueindex 9555f3857a..b397a5193e 100644--- a/packages/nc-gui/components/dashboard/TreeView/CreateProject/MenuItem.vue+++ b/packages/nc-gui/components/dashboard/TreeView/CreateProject/MenuItem.vue@@ -1,9 +1,12 @@<script lang="ts" setup>+import { NcMenuItem } from "#components"+interface Props {label: stringsubtext?: stringicon?: IconMapKey+ variant?: 'dropdown' | 'modal'}withDefaults(defineProps<Props>(), {@@ -12,12 +15,16 @@ withDefaults(defineProps<Props>(), {</script><template>- <NcMenuItem :inner-class="`w-full ${$slots.subtext || subtext ? '!items-start' : ''}`">- <slot name="icon">- <GeneralIcon v-if="icon" :icon="icon" class="h-4 w-4 flex-none" :class="{- 'mt-0.5': $slots.subtext || subtext- }" />- </slot>+ <component :is="variant === 'modal' ? 'div' : NcMenuItem"+ :inner-class="`w-full ${$slots.subtext || subtext ? '!items-start' : ''}`"+ :class="`nc-create-project-menu-item-${variant}`">+ <div class="nc-icon-wrapper">+ <slot name="icon">+ <GeneralIcon v-if="icon" :icon="icon" class="h-4 w-4 flex-none" :class="{+ 'mt-0.5': $slots.subtext || subtext+ }" />+ </slot>+ </div><div class="nc-content-wrapper"><div class="nc-content-label">@@ -27,10 +34,23 @@ withDefaults(defineProps<Props>(), {<slot name="subtext">{{ subtext }}</slot></div></div>- </NcMenuItem>+ </component></template><style lang="scss" scoped>+.nc-icon-wrapper {+ @apply flex items-center justify-center h-4 w-4 children:flex-none;+}++.nc-create-project-menu-item-modal {+ @apply font-normal text-sm flex items-start gap-3 mx-1 px-2 py-1 rounded-md hover:bg-nc-bg-gray-light transition-colors cursor-pointer;++ .nc-content-wrapper {+ .nc-content-label {}++ }+}+.nc-content-wrapper {.nc-content-subtext {@apply text-tiny !leading-4 text-nc-content-gray-muted;