fix: rename key to pluginKey for menus

This commit is contained in:
Philipp Kühn
2021-08-13 12:33:06 +02:00
parent 8fd75bc4b6
commit 89d26f7cba
12 changed files with 40 additions and 40 deletions

View File

@@ -2,7 +2,7 @@ import Vue, { Component, PropType } from 'vue'
import { BubbleMenuPlugin, BubbleMenuPluginProps } from '@tiptap/extension-bubble-menu'
export interface BubbleMenuInterface extends Vue {
pluginKey: BubbleMenuPluginProps['key'],
pluginKey: BubbleMenuPluginProps['pluginKey'],
editor: BubbleMenuPluginProps['editor'],
tippyOptions: BubbleMenuPluginProps['tippyOptions'],
shouldShow: BubbleMenuPluginProps['shouldShow'],
@@ -13,7 +13,7 @@ export const BubbleMenu: Component = {
props: {
pluginKey: {
type: [String, Object as PropType<Exclude<BubbleMenuPluginProps['key'], string>>],
type: [String, Object as PropType<Exclude<BubbleMenuPluginProps['pluginKey'], string>>],
default: 'bubbleMenu',
},
@@ -43,7 +43,7 @@ export const BubbleMenu: Component = {
this.$nextTick(() => {
editor.registerPlugin(BubbleMenuPlugin({
key: this.pluginKey,
pluginKey: this.pluginKey,
editor,
element: this.$el as HTMLElement,
tippyOptions: this.tippyOptions,

View File

@@ -2,7 +2,7 @@ import Vue, { Component, PropType } from 'vue'
import { FloatingMenuPlugin, FloatingMenuPluginProps } from '@tiptap/extension-floating-menu'
export interface FloatingMenuInterface extends Vue {
pluginKey: FloatingMenuPluginProps['key'],
pluginKey: FloatingMenuPluginProps['pluginKey'],
tippyOptions: FloatingMenuPluginProps['tippyOptions'],
editor: FloatingMenuPluginProps['editor'],
shouldShow: FloatingMenuPluginProps['shouldShow'],
@@ -13,7 +13,7 @@ export const FloatingMenu: Component = {
props: {
pluginKey: {
type: [String, Object as PropType<Exclude<FloatingMenuPluginProps['key'], string>>],
type: [String, Object as PropType<Exclude<FloatingMenuPluginProps['pluginKey'], string>>],
default: 'floatingMenu',
},
@@ -43,7 +43,7 @@ export const FloatingMenu: Component = {
this.$nextTick(() => {
editor.registerPlugin(FloatingMenuPlugin({
key: this.pluginKey,
pluginKey: this.pluginKey,
editor,
element: this.$el as HTMLElement,
tippyOptions: this.tippyOptions,