import TiptapVuetify from '~/components/TiptapVuetify.vue' ; import theme from '~/configs/theme' ; import { OptionsInterface , PluginInterface } from '../types' ; import ConsoleLogger from '~/logging/ConsoleLogger' ; export * from '~/extensions/nativeExtensions/index' ; export { TiptapVuetify } ; export const TiptapVuetifyPlugin = new ( class Plugin implements PluginInterface < OptionsInterface > { vuetify ; installed = false ; get vuetifyLang ( ) { return this . vuetify . framework . lang . current ; } install ( VueFuncConstructor , options ? ) { if ( ! options || ! options . vuetify ) { ConsoleLogger . error ( 'Please, specify in options the Vuetify Object ("vuetify" property)' ) ; return ; } const { vuetify : vuetifyFramework , iconsGroup = theme . defaultIconsGroup } = options ; VueFuncConstructor . prototype . tiptapVuetifyPlugin = TiptapVuetifyPlugin ; VueFuncConstructor . prototype . $tiptapVuetify = { iconsGroup } ; this . vuetify = vuetifyFramework ; this . installed = true ; } } ) ( ) ; ( function autoInstall ( ) { let globalScope = null ; if ( typeof window !== 'undefined' ) { globalScope = window ; } else if ( typeof global !== 'undefined' ) { globalScope = global ; } if ( globalScope && globalScope . Vue ) { globalScope . Vue . use ( TiptapVuetifyPlugin , { vuetify : globalScope . vuetify , ... globalScope . tiptapVuetifyPluginOptions } ) ; globalScope . Vue . component ( 'tiptap-vuetify' , TiptapVuetify ) ; } } ) ( ) ;