docs: remove position: relative from menu demos
This commit is contained in:
@@ -24,7 +24,7 @@ export default () => {
|
||||
})
|
||||
|
||||
return (
|
||||
<div style={{ position: 'relative' }}>
|
||||
<>
|
||||
{editor && <BubbleMenu className="bubble-menu" tippyOptions={{ duration: 100 }} editor={editor}>
|
||||
<button
|
||||
onClick={() => editor.chain().focus().toggleBold().run()}
|
||||
@@ -68,6 +68,6 @@ export default () => {
|
||||
</FloatingMenu>}
|
||||
|
||||
<EditorContent editor={editor} />
|
||||
</div>
|
||||
</>
|
||||
)
|
||||
}
|
||||
|
||||
@@ -1,6 +1,11 @@
|
||||
<template>
|
||||
<div style="position: relative">
|
||||
<bubble-menu class="bubble-menu" :tippy-options="{ duration: 100 }" :editor="editor" v-if="editor">
|
||||
<div>
|
||||
<bubble-menu
|
||||
class="bubble-menu"
|
||||
:tippy-options="{ duration: 100 }"
|
||||
:editor="editor"
|
||||
v-if="editor"
|
||||
>
|
||||
<button @click="editor.chain().focus().toggleBold().run()" :class="{ 'is-active': editor.isActive('bold') }">
|
||||
Bold
|
||||
</button>
|
||||
@@ -12,7 +17,12 @@
|
||||
</button>
|
||||
</bubble-menu>
|
||||
|
||||
<floating-menu class="floating-menu" :tippy-options="{ duration: 100 }" :editor="editor" v-if="editor">
|
||||
<floating-menu
|
||||
class="floating-menu"
|
||||
:tippy-options="{ duration: 100 }"
|
||||
:editor="editor"
|
||||
v-if="editor"
|
||||
>
|
||||
<button @click="editor.chain().focus().toggleHeading({ level: 1 }).run()" :class="{ 'is-active': editor.isActive('heading', { level: 1 }) }">
|
||||
H1
|
||||
</button>
|
||||
|
||||
@@ -16,7 +16,7 @@ export default () => {
|
||||
})
|
||||
|
||||
return (
|
||||
<div style={{ position: 'relative' }}>
|
||||
<>
|
||||
{editor && <BubbleMenu editor={editor}>
|
||||
<button
|
||||
onClick={() => editor.chain().focus().toggleBold().run()}
|
||||
@@ -38,6 +38,6 @@ export default () => {
|
||||
</button>
|
||||
</BubbleMenu>}
|
||||
<EditorContent editor={editor} />
|
||||
</div>
|
||||
</>
|
||||
)
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<div style="position: relative">
|
||||
<div>
|
||||
<bubble-menu :editor="editor" v-if="editor">
|
||||
<button @click="editor.chain().focus().toggleBold().run()" :class="{ 'is-active': editor.isActive('bold') }">
|
||||
bold
|
||||
|
||||
@@ -17,7 +17,7 @@ export default () => {
|
||||
})
|
||||
|
||||
return (
|
||||
<div style={{ position: 'relative' }}>
|
||||
<>
|
||||
{editor && <FloatingMenu editor={editor}>
|
||||
<button
|
||||
onClick={() => editor.chain().focus().toggleHeading({ level: 1 }).run()}
|
||||
@@ -39,6 +39,6 @@ export default () => {
|
||||
</button>
|
||||
</FloatingMenu>}
|
||||
<EditorContent editor={editor} />
|
||||
</div>
|
||||
</>
|
||||
)
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<template>
|
||||
<div style="position: relative">
|
||||
<div>
|
||||
<floating-menu :editor="editor" v-if="editor">
|
||||
<button @click="editor.chain().focus().toggleHeading({ level: 1 }).run()" :class="{ 'is-active': editor.isActive('heading', { level: 1 }) }">
|
||||
h1
|
||||
|
||||
Reference in New Issue
Block a user