Browse Source

refactor(gui): popup size correction and destroy popup on hide

Signed-off-by: Pranav C <pranavxc@gmail.com>
pull/4630/head
Pranav C 2 years ago
parent
commit
3ec9de4214
  1. 9
      packages/nc-gui/components/dashboard/TreeView.vue
  2. 4
      packages/nc-gui/components/general/EmojiIcons.vue

9
packages/nc-gui/components/dashboard/TreeView.vue

@ -565,15 +565,8 @@ const setIcon = (icon: string, table: TableType) => {
<template #title>{{ table.table_name }}</template> <template #title>{{ table.table_name }}</template>
<div class="flex items-center gap-2 h-full" @contextmenu="setMenuContext('table', table)"> <div class="flex items-center gap-2 h-full" @contextmenu="setMenuContext('table', table)">
<div class="flex w-auto" :data-testid="`tree-view-table-draggable-handle-${table.title}`"> <div class="flex w-auto" :data-testid="`tree-view-table-draggable-handle-${table.title}`">
<a-dropdown trigger="click" @click.stop> <a-dropdown trigger="click" @click.stop destroy-popup-on-hide>
<div @click.stop> <div @click.stop>
<!-- <MdiDrag
v-if="isUIAllowed('treeview-drag-n-drop')"
:class="`nc-child-draggable-icon-${table.title}`"
class="nc-drag-icon text-xs hidden group-hover:block transition-opacity opacity-0 group-hover:opacity-100 text-gray-500 cursor-move"
@click.stop.prevent
/> -->
<a-tooltip> <a-tooltip>
<span v-if="table.meta?.icon" :key="table.meta?.icon"> <span v-if="table.meta?.icon" :key="table.meta?.icon">
<Icon :key="table.meta?.icon" class="text-xl" :icon="table.meta?.icon"></Icon> <Icon :key="table.meta?.icon" class="text-xl" :icon="table.meta?.icon"></Icon>

4
packages/nc-gui/components/general/EmojiIcons.vue

@ -26,9 +26,9 @@ const selectIcon = (icon: string) => {
</script> </script>
<template> <template>
<div class="p-1 w-70 h-75 flex flex-col gap-1 justify-start"> <div class="p-1 w-[280px] h-[280px] flex flex-col gap-1 justify-start">
<div @click.stop> <div @click.stop>
<input v-model="search" class="p-1 border-1 w-full overflow-y-auto" placeholder="Search" @input="toIndex = 60" /> <input v-model="search" class="p-1 text-xs border-1 w-full overflow-y-auto" placeholder="Search" @input="toIndex = 60" />
</div> </div>
<div class="flex gap-1 flex-wrap w-full flex-shrink overflow-y-auto scrollbar-thin-dull"> <div class="flex gap-1 flex-wrap w-full flex-shrink overflow-y-auto scrollbar-thin-dull">
<div v-for="icon of filteredIcons" :key="icon" @click="selectIcon(icon)"> <div v-for="icon of filteredIcons" :key="icon" @click="selectIcon(icon)">

Loading…
Cancel
Save