add buttons to note editor

This commit is contained in:
2023-05-12 20:15:41 +02:00
parent 606a1f99d2
commit 1381bc0f29
4 changed files with 34 additions and 16 deletions

View File

@@ -32,8 +32,9 @@ const references = computed<Note[]>(() => {
</script> </script>
<template> <template>
<div class="flex flex-col"> <div class="flex flex-col">
<div class="flex items-center mb-2">
<h1 <h1
class="mb-2 flex items-center rounded-md text-3xl font-semibold hover:bg-gray-200" class="flex flex-1 items-center rounded-md text-3xl font-semibold hover:bg-gray-200 mr-2"
> >
<i <i
class="fas fa-fw fa-home mr-2 text-base text-secondary opacity-40" class="fas fa-fw fa-home mr-2 text-base text-secondary opacity-40"
@@ -45,6 +46,15 @@ const references = computed<Note[]>(() => {
v-model="noteTitle" v-model="noteTitle"
/> />
</h1> </h1>
<div class="btn-group flex items-center">
<button class="btn-sm btn">
<i class="fas fa-fw fa-trash" />
</button>
<button class="btn-sm btn">
<i class="fas fa-fw fa-sitemap" />
</button>
</div>
</div>
<NoteEditor <NoteEditor
class="h-100 flex-1 overflow-auto" class="h-100 flex-1 overflow-auto"
:note="activeNote" :note="activeNote"
@@ -75,3 +85,11 @@ const references = computed<Note[]>(() => {
</div> </div>
</div> </div>
</template> </template>
<style scoped lang="scss">
.btn-group .btn {
@apply border-[1px] border-neutral-200 text-opacity-70;
&:not(:first-child) {
@apply ml-[-1px];
}
}
</style>

View File

@@ -118,7 +118,7 @@ const createLink = (link: string) => {
<template> <template>
<div class="relative" ref="editorElement"> <div class="relative" ref="editorElement">
<CKEditor <CKEditor
class="h-full" class="h-full text-[110%] font-light"
:editor="editor" :editor="editor"
v-model="editorData" v-model="editorData"
:config="editorConfig" :config="editorConfig"

View File

@@ -2,6 +2,7 @@
@tailwind components; @tailwind components;
@tailwind utilities; @tailwind utilities;
@import '@fontsource/source-sans-pro'; @import '@fontsource/source-sans-pro';
@import '@fontsource/source-sans-pro/300';
body, body,
body > div, body > div,
@@ -11,7 +12,6 @@ html {
body { body {
font-family: 'Source Sans Pro', sans-serif; font-family: 'Source Sans Pro', sans-serif;
font-size: 110%;
overflow-y: auto; overflow-y: auto;
} }

View File

@@ -35,7 +35,7 @@ export default {
primary: '#1E4BC4', primary: '#1E4BC4',
secondary: '#F000B8', secondary: '#F000B8',
accent: '#37CDBE', accent: '#37CDBE',
neutral: '#3D4451', neutral: '#F7F7F7',
'base-100': '#FFFFFF', 'base-100': '#FFFFFF',
info: '#3ABFF8', info: '#3ABFF8',
success: '#36D399', success: '#36D399',