autocomplete styling

This commit is contained in:
2023-05-04 23:48:39 +02:00
parent e606296585
commit 38a6255e77
6 changed files with 84 additions and 28 deletions

View File

@@ -15,6 +15,7 @@ import AutoformatPlugin from '@ckeditor/ckeditor5-autoformat/src/autoformat'
import ContextedPlugin from '@/ckeditor/ContextedPlugin'
import { mdToHtml } from '@/utils/markdown'
import { activeNote, getNoteByTitle } from '@/composables/useNotes'
import Autocomplete from '@/components/Autocomplete.vue'
const props = defineProps<{
note: Note
@@ -92,13 +93,12 @@ const handleAutocomplete = (event: any) => {
@click="handleClick"
@contexted-link-autocomplete="handleAutocomplete"
></CKEditor>
<div
class="absolute mt-1 border-red-500 bg-primary text-white"
:style="autocompleteStyle"
<Autocomplete
v-if="showAutocomplete"
>
{{ autocompleteText }}
</div>
:autocomplete-text="autocompleteText"
:style="autocompleteStyle"
class="absolute mt-1 w-[250px]"
/>
</div>
</template>
<style>