fix stretch + default notes
This commit is contained in:
@@ -81,7 +81,7 @@ export const setRootNote = (noteId: string) => {
|
||||
setActiveNote(noteId)
|
||||
}
|
||||
|
||||
export const setDefaultNotes = (defaultNotes: BaseNote[]) => {
|
||||
export const insertDefaultNotes = (defaultNotes: BaseNote[]) => {
|
||||
defaultNotes.forEach((defaultNote) => {
|
||||
baseNotes.value[defaultNote.id] = defaultNote
|
||||
})
|
||||
@@ -203,9 +203,8 @@ watch(
|
||||
} else if (activeNotesSource.value === 'firebase') {
|
||||
console.log('get notes from firebase')
|
||||
}
|
||||
if (Object.entries(baseNotes.value).length === 0) {
|
||||
setDefaultNotes(defaultNotes)
|
||||
}
|
||||
if (!rootNote.value) insertDefaultNotes(defaultNotes)
|
||||
|
||||
setActiveNote(rootNote.value?.id)
|
||||
},
|
||||
{ immediate: true }
|
||||
|
||||
@@ -5,12 +5,12 @@
|
||||
@import '@fontsource/source-sans-pro/300';
|
||||
|
||||
html {
|
||||
height: stretch;
|
||||
height: -webkit-fill-available;
|
||||
}
|
||||
|
||||
body {
|
||||
min-height: 100vh;
|
||||
min-height: stretch;
|
||||
min-height: -webkit-fill-available;
|
||||
font-family: 'Source Sans Pro', sans-serif;
|
||||
overflow-y: scroll;
|
||||
@apply flex flex-col bg-gray-100;
|
||||
|
||||
Reference in New Issue
Block a user