Fix heading level in edit

This commit is contained in:
Benjamin Bädorf 2022-03-11 18:26:30 +01:00
parent 4ffafd4bb5
commit b4919d6c3e
No known key found for this signature in database
GPG key ID: 4406E80E13CD656C
4 changed files with 1 additions and 37 deletions

View file

@ -1,2 +0,0 @@
.sb-global-insert {
}

View file

@ -1,32 +0,0 @@
import { defineComponent } from 'vue';
import { ITreeNode } from '../types';
import { useBlockTree } from '../use-block-tree';
import { useActivation } from '../use-activation';
import { SbBlockPicker } from './BlockPicker';
import { SbButton } from './Button';
import './GlobalInsert.scss';
export const SbGlobalInsert = defineComponent({
name: 'sb-global-insert',
setup() {
const { blockTree } = useBlockTree();
const {
activate,
activeBlockId,
} = useActivation();
return () => (
blockTree.value
? <SbBlockPicker
class="sb-global-insert"
v-slots={{
default: ({ toggle }: { toggle: Function }) => <SbButton {...{ onClick: toggle }}>+</SbButton>,
}}
/>
: ''
);
},
});

View file

@ -4,7 +4,6 @@ import {
} from 'vue';
import { IBlockData } from '../types';
import { SbTreeBlockSelect } from './TreeBlockSelect';
import { SbGlobalInsert } from './GlobalInsert';
import './MainMenu.scss';
@ -22,7 +21,6 @@ export const SbMainMenu = defineComponent({
return () => (
<div class="sb-main-menu">
<SbTreeBlockSelect />
<SbGlobalInsert />
</div>
);
},

View file

@ -88,7 +88,7 @@ export default defineComponent({
const classes = computed(() => ({
'sb-heading': true,
'sb-heading_focused': localData.focused,
[`sb-heading_align${localData.align}`]: true,
[`sb-heading_align-${localData.align}`]: true,
[`sb-heading_${localData.level}`]: true,
}));