tiptapify 0.0.11 → 0.0.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (107) hide show
  1. package/README.md +9 -4
  2. package/dist/tiptapify.css +1 -1
  3. package/dist/tiptapify.mjs +47819 -28736
  4. package/dist/tiptapify.umd.js +78 -38
  5. package/index.d.ts +2 -2
  6. package/package.json +49 -45
  7. package/src/components/MenuBubble.vue +8 -8
  8. package/src/components/Tiptapify.vue +4 -5
  9. package/src/components/Toolbar/Group.vue +2 -2
  10. package/src/components/Toolbar/GroupBtn.vue +11 -8
  11. package/src/components/Toolbar/GroupDropdown.vue +3 -17
  12. package/src/components/Toolbar/Index.vue +13 -10
  13. package/src/components/Toolbar/Items.vue +3 -6
  14. package/src/components/Toolbar/Toggle.vue +2 -4
  15. package/src/components/Toolbar/defaultExtensionComponents.ts +34 -13
  16. package/src/components/Toolbar/items.ts +43 -60
  17. package/src/components/UI/BtnIcon.vue +24 -0
  18. package/src/components/UI/{Dialog.vue → TiptapifyDialog.vue} +4 -3
  19. package/src/components/editorExtensions.ts +16 -1
  20. package/src/components/index.ts +8 -2
  21. package/src/composables/Toolbar/Actions/useRedo.ts +23 -0
  22. package/src/composables/Toolbar/Actions/useUndo.ts +23 -0
  23. package/src/composables/Toolbar/Alignment/useAlignmentCenter.ts +24 -0
  24. package/src/composables/Toolbar/Alignment/useAlignmentJustify.ts +24 -0
  25. package/src/composables/Toolbar/Alignment/useAlignmentLeft.ts +24 -0
  26. package/src/composables/Toolbar/Alignment/useAlignmentRight.ts +24 -0
  27. package/src/composables/Toolbar/Format/useBold.ts +24 -0
  28. package/src/composables/Toolbar/Format/useItalic.ts +24 -0
  29. package/src/composables/Toolbar/Format/useStrike.ts +24 -0
  30. package/src/composables/Toolbar/Format/useUnderline.ts +24 -0
  31. package/src/composables/Toolbar/FormatExtra/useBlockquote.ts +24 -0
  32. package/src/composables/Toolbar/FormatExtra/useCode.ts +24 -0
  33. package/src/composables/Toolbar/FormatExtra/useCodeBlock.ts +24 -0
  34. package/src/composables/Toolbar/FormatExtra/useSub.ts +24 -0
  35. package/src/composables/Toolbar/FormatExtra/useSup.ts +24 -0
  36. package/src/composables/Toolbar/List/useBullet.ts +23 -0
  37. package/src/composables/Toolbar/List/useIndent.ts +24 -0
  38. package/src/composables/Toolbar/List/useNumbered.ts +23 -0
  39. package/src/composables/Toolbar/List/useOutdent.ts +24 -0
  40. package/src/composables/Toolbar/List/useTask.ts +23 -0
  41. package/src/composables/Toolbar/Media/useEmoji.ts +20 -0
  42. package/src/composables/Toolbar/Media/useImage.ts +24 -0
  43. package/src/composables/Toolbar/Media/useLink.ts +24 -0
  44. package/src/composables/Toolbar/Media/useTable.ts +188 -0
  45. package/src/composables/Toolbar/Misc/useBreak.ts +21 -0
  46. package/src/composables/Toolbar/Misc/useFormatClear.ts +23 -0
  47. package/src/composables/Toolbar/Misc/useInvisibleCharacters.ts +23 -0
  48. package/src/composables/Toolbar/Misc/useLine.ts +21 -0
  49. package/src/composables/Toolbar/Misc/usePreview.ts +20 -0
  50. package/src/composables/Toolbar/Misc/useSource.ts +21 -0
  51. package/src/composables/Toolbar/Style/useColor.ts +36 -0
  52. package/src/composables/Toolbar/Style/useFontFamily.ts +49 -0
  53. package/src/composables/Toolbar/Style/useFontSize.ts +50 -0
  54. package/src/composables/Toolbar/Style/useHeading.ts +64 -0
  55. package/src/composables/Toolbar/Style/useHighlight.ts +36 -0
  56. package/src/composables/Toolbar/Style/useLineHeight.ts +49 -0
  57. package/src/composables/Toolbar/useActionsItems.ts +5 -31
  58. package/src/composables/Toolbar/useAlignmentItems.ts +9 -59
  59. package/src/composables/Toolbar/useFormatExtraItems.ts +11 -72
  60. package/src/composables/Toolbar/useFormatItems.ts +9 -59
  61. package/src/composables/Toolbar/useListItems.ts +11 -69
  62. package/src/composables/Toolbar/useMediaItems.ts +9 -209
  63. package/src/composables/Toolbar/useMiscItems.ts +13 -58
  64. package/src/composables/Toolbar/useStyleItems.ts +14 -228
  65. package/src/extensions/components/Emoji.vue +109 -0
  66. package/src/extensions/components/ImageDialog.vue +7 -3
  67. package/src/extensions/components/LinkDialog.vue +7 -3
  68. package/src/extensions/components/PreviewDialog.vue +11 -4
  69. package/src/extensions/components/ShowSourceDialog.vue +7 -4
  70. package/src/extensions/components/StyleColor.vue +2 -2
  71. package/src/extensions/components/slashCommands/CommandsList.vue +1 -4
  72. package/src/extensions/emoji/activities.ts +770 -0
  73. package/src/extensions/emoji/animals_and_nature.ts +1330 -0
  74. package/src/extensions/emoji/component.ts +74 -0
  75. package/src/extensions/emoji/flags.ts +2210 -0
  76. package/src/extensions/emoji/food_and_drink.ts +1066 -0
  77. package/src/extensions/emoji/index.ts +63 -0
  78. package/src/extensions/emoji/objects.ts +2514 -0
  79. package/src/extensions/emoji/people_and_body.ts +3986 -0
  80. package/src/extensions/emoji/smileys_and_emotion.ts +1482 -0
  81. package/src/extensions/emoji/symbols.ts +2242 -0
  82. package/src/extensions/emoji/travel_and_places.ts +2138 -0
  83. package/src/extensions/image.ts +2 -1
  84. package/src/extensions/link.ts +2 -1
  85. package/src/extensions/preview.ts +2 -1
  86. package/src/extensions/view-source.ts +2 -1
  87. package/src/i18n/index.ts +1 -0
  88. package/src/i18n/locales/ch.json +14 -1
  89. package/src/i18n/locales/cz.json +14 -1
  90. package/src/i18n/locales/de.json +14 -1
  91. package/src/i18n/locales/en.json +14 -1
  92. package/src/i18n/locales/es.json +14 -1
  93. package/src/i18n/locales/fr.json +14 -1
  94. package/src/i18n/locales/it.json +14 -1
  95. package/src/i18n/locales/la.json +14 -1
  96. package/src/i18n/locales/lt.json +14 -1
  97. package/src/i18n/locales/nl.json +14 -1
  98. package/src/i18n/locales/pl.json +14 -1
  99. package/src/i18n/locales/pt.json +14 -1
  100. package/src/i18n/locales/ru.json +14 -1
  101. package/src/i18n/locales/se.json +14 -1
  102. package/src/i18n/locales/ua.json +14 -1
  103. package/src/index.ts +3 -1
  104. package/src/types/extensionComponents.ts +22 -0
  105. package/src/types/toolbarItems.ts +43 -0
  106. package/src/types/toolbarSections.ts +11 -0
  107. package/src/types/overridable-extensions.ts +0 -6
@@ -18,7 +18,8 @@ export const TiptapifyImage = Extension.create({
18
18
  showTiptapifyImage: () => ({ editor }) => {
19
19
  const event = new CustomEvent(`tiptapify-show-${name}`, {
20
20
  detail: {
21
- image: editor.getAttributes('image')
21
+ image: editor.getAttributes('image'),
22
+ editorId: editor.instanceId
22
23
  }
23
24
  })
24
25
 
@@ -19,7 +19,8 @@ export const TiptapifyLink = Link.extend({
19
19
  showLink: () => ({ editor }) => {
20
20
  const event = new CustomEvent(`tiptapify-show-${name}`, {
21
21
  detail: {
22
- link: editor.getAttributes('link')
22
+ link: editor.getAttributes('link'),
23
+ editorId: editor.instanceId
23
24
  }
24
25
  })
25
26
 
@@ -19,7 +19,8 @@ export const Preview = Extension.create({
19
19
  showPreview: () => ({ editor }) => {
20
20
  const event = new CustomEvent(`tiptapify-show-${name}`, {
21
21
  detail: {
22
- html: editor.getHTML()
22
+ html: editor.getHTML(),
23
+ editorId: editor.instanceId
23
24
  }
24
25
  })
25
26
 
@@ -27,7 +27,8 @@ export const ViewSource = Extension.create<ViewSourceOptions>({
27
27
  showSource: () => ({ editor }) => {
28
28
  const event = new CustomEvent('tiptapify-show-source', {
29
29
  detail: {
30
- html: editor.getHTML()
30
+ html: editor.getHTML(),
31
+ editorId: editor.instanceId
31
32
  }
32
33
  })
33
34
 
package/src/i18n/index.ts CHANGED
@@ -11,6 +11,7 @@ let _i18n: any = null
11
11
  export const getI18n = (locale: string) => {
12
12
  if (_i18n === null) {
13
13
  _i18n = createI18n({
14
+ legacy: false,
14
15
  locale: locale,
15
16
  fallbackLocale: 'en',
16
17
  messages
@@ -41,6 +41,18 @@
41
41
  "media": {
42
42
  "link": "外部链接",
43
43
  "image": "图片",
44
+ "emoji": {
45
+ "activities": "活动",
46
+ "animals_and_nature": "动物与自然",
47
+ "component": "组件",
48
+ "flags": "旗帜",
49
+ "food_and_drink": "食物与饮料",
50
+ "objects": "物品",
51
+ "people_and_body": "人物与身体",
52
+ "smileys_and_emotion": "笑脸与情感",
53
+ "symbols": "符号",
54
+ "travel_and_places": "旅行与地点"
55
+ },
44
56
  "tables": {
45
57
  "table": "表格",
46
58
  "insertTable": "插入表格",
@@ -110,7 +122,8 @@
110
122
  },
111
123
  "misc": {
112
124
  "source": "查看源代码",
113
- "preview": "预览"
125
+ "preview": "预览",
126
+ "toggleInvisibleCharacters": "显示/隐藏不可见字符"
114
127
  },
115
128
  "footer": {
116
129
  "words": "单词",
@@ -41,6 +41,18 @@
41
41
  "media": {
42
42
  "link": "Externí odkaz",
43
43
  "image": "Obrázek",
44
+ "emoji": {
45
+ "activities": "Aktivity",
46
+ "animals_and_nature": "Zvířata a příroda",
47
+ "component": "Komponenta",
48
+ "flags": "Vlajky",
49
+ "food_and_drink": "Jídlo a nápoje",
50
+ "objects": "Objekty",
51
+ "people_and_body": "Lidé a tělo",
52
+ "smileys_and_emotion": "Úsměvy a emoce",
53
+ "symbols": "Symboly",
54
+ "travel_and_places": "Cestování a místa"
55
+ },
44
56
  "tables": {
45
57
  "table": "Tabulka",
46
58
  "insertTable": "Vložit tabulku",
@@ -110,7 +122,8 @@
110
122
  },
111
123
  "misc": {
112
124
  "source": "Zobrazit zdrojový kód",
113
- "preview": "Náhled"
125
+ "preview": "Náhled",
126
+ "toggleInvisibleCharacters": "Zobrazit/skrýt neviditelné znaky"
114
127
  },
115
128
  "footer": {
116
129
  "words": "slova",
@@ -41,6 +41,18 @@
41
41
  "media": {
42
42
  "link": "Externer Link",
43
43
  "image": "Bild",
44
+ "emoji": {
45
+ "activities": "Aktivitäten",
46
+ "animals_and_nature": "Tiere & Natur",
47
+ "component": "Komponente",
48
+ "flags": "Flaggen",
49
+ "food_and_drink": "Essen und Trinken",
50
+ "objects": "Objekte",
51
+ "people_and_body": "Menschen & Körper",
52
+ "smileys_and_emotion": "Smileys und Emotionen",
53
+ "symbols": "Symbole",
54
+ "travel_and_places": "Reisen und Orte"
55
+ },
44
56
  "tables": {
45
57
  "table": "Tabelle",
46
58
  "insertTable": "Tabelle einfügen",
@@ -110,7 +122,8 @@
110
122
  },
111
123
  "misc": {
112
124
  "source": "Quellcode anzeigen",
113
- "preview": "Vorschau"
125
+ "preview": "Vorschau",
126
+ "toggleInvisibleCharacters": "Unsichtbare Zeichen anzeigen/ausblenden"
114
127
  },
115
128
  "footer": {
116
129
  "words": "Wörter",
@@ -41,6 +41,18 @@
41
41
  "media": {
42
42
  "link": "External link",
43
43
  "image": "Image",
44
+ "emoji": {
45
+ "activities": "Activities",
46
+ "animals_and_nature": "Animals & nature",
47
+ "component": "Component",
48
+ "flags": "Flags",
49
+ "food_and_drink": "Food and drink",
50
+ "objects": "Objects",
51
+ "people_and_body": "People & body",
52
+ "smileys_and_emotion": "Smileys and emotion",
53
+ "symbols": "Symbols",
54
+ "travel_and_places": "Travel and places"
55
+ },
44
56
  "tables": {
45
57
  "table": "Table",
46
58
  "insertTable": "Insert table",
@@ -110,7 +122,8 @@
110
122
  },
111
123
  "misc": {
112
124
  "source": "View source code",
113
- "preview": "Preview"
125
+ "preview": "Preview",
126
+ "toggleInvisibleCharacters": "Show/hide invisible characters"
114
127
  },
115
128
  "footer": {
116
129
  "words": "words",
@@ -41,6 +41,18 @@
41
41
  "media": {
42
42
  "link": "Enlace externo",
43
43
  "image": "Imagen",
44
+ "emoji": {
45
+ "activities": "Actividades",
46
+ "animals_and_nature": "Animales y naturaleza",
47
+ "component": "Componente",
48
+ "flags": "Banderas",
49
+ "food_and_drink": "Comida y bebida",
50
+ "objects": "Objetos",
51
+ "people_and_body": "Personas y cuerpo",
52
+ "smileys_and_emotion": "Caritas y emociones",
53
+ "symbols": "Símbolos",
54
+ "travel_and_places": "Viajes y lugares"
55
+ },
44
56
  "tables": {
45
57
  "table": "Tabla",
46
58
  "insertTable": "Insertar tabla",
@@ -110,7 +122,8 @@
110
122
  },
111
123
  "misc": {
112
124
  "source": "Ver código fuente",
113
- "preview": "Vista previa"
125
+ "preview": "Vista previa",
126
+ "toggleInvisibleCharacters": "Mostrar/ocultar caracteres invisibles"
114
127
  },
115
128
  "footer": {
116
129
  "words": "palabras",
@@ -42,6 +42,18 @@
42
42
  "media": {
43
43
  "link": "Lien externe",
44
44
  "image": "Image",
45
+ "emoji": {
46
+ "activities": "Activités",
47
+ "animals_and_nature": "Animaux et nature",
48
+ "component": "Composant",
49
+ "flags": "Drapeaux",
50
+ "food_and_drink": "Nourriture et boissons",
51
+ "objects": "Objets",
52
+ "people_and_body": "Personnes et corps",
53
+ "smileys_and_emotion": "Smileys et émotions",
54
+ "symbols": "Symboles",
55
+ "travel_and_places": "Voyages et lieux"
56
+ },
45
57
  "tables": {
46
58
  "table": "Tableau",
47
59
  "insertTable": "Insérer un tableau",
@@ -111,7 +123,8 @@
111
123
  },
112
124
  "misc": {
113
125
  "source": "Voir le code source",
114
- "preview": "Aperçu"
126
+ "preview": "Aperçu",
127
+ "toggleInvisibleCharacters": "Afficher/masquer les caractères invisibles"
115
128
  },
116
129
  "footer": {
117
130
  "words": "mots",
@@ -41,6 +41,18 @@
41
41
  "media": {
42
42
  "link": "Collegamento esterno",
43
43
  "image": "Immagine",
44
+ "emoji": {
45
+ "activities": "Attività",
46
+ "animals_and_nature": "Animali e natura",
47
+ "component": "Componente",
48
+ "flags": "Bandiere",
49
+ "food_and_drink": "Cibo e bevande",
50
+ "objects": "Oggetti",
51
+ "people_and_body": "Persone e corpo",
52
+ "smileys_and_emotion": "Faccine ed emozioni",
53
+ "symbols": "Simboli",
54
+ "travel_and_places": "Viaggi e luoghi"
55
+ },
44
56
  "tables": {
45
57
  "table": "Tabella",
46
58
  "insertTable": "Inserisci tabella",
@@ -110,7 +122,8 @@
110
122
  },
111
123
  "misc": {
112
124
  "source": "Visualizza codice sorgente",
113
- "preview": "Anteprima"
125
+ "preview": "Anteprima",
126
+ "toggleInvisibleCharacters": "Mostra/nascondi caratteri invisibili"
114
127
  },
115
128
  "footer": {
116
129
  "words": "parole",
@@ -41,6 +41,18 @@
41
41
  "media": {
42
42
  "link": "Nexus externus",
43
43
  "image": "Imago",
44
+ "emoji": {
45
+ "activities": "Activitates",
46
+ "animals_and_nature": "Animalia et natura",
47
+ "component": "Componens",
48
+ "flags": "Vexilla",
49
+ "food_and_drink": "Cibus et potus",
50
+ "objects": "Objecta",
51
+ "people_and_body": "Homines et corpus",
52
+ "smileys_and_emotion": "Risus et affectus",
53
+ "symbols": "Symbola",
54
+ "travel_and_places": "Iter et loca"
55
+ },
44
56
  "tables": {
45
57
  "table": "Tabula",
46
58
  "insertTable": "Tabulam inserere",
@@ -110,7 +122,8 @@
110
122
  },
111
123
  "misc": {
112
124
  "source": "Codicem fontem videre",
113
- "preview": "Praevisio"
125
+ "preview": "Praevisio",
126
+ "toggleInvisibleCharacters": "Ostende/cela characteres invisibiles"
114
127
  },
115
128
  "footer": {
116
129
  "words": "verba",
@@ -41,6 +41,18 @@
41
41
  "media": {
42
42
  "link": "Išorinė nuoroda",
43
43
  "image": "Paveikslas",
44
+ "emoji": {
45
+ "activities": "Veiklos",
46
+ "animals_and_nature": "Gyvūnai ir gamta",
47
+ "component": "Komponentas",
48
+ "flags": "Vėliavos",
49
+ "food_and_drink": "Maistas ir gėrimai",
50
+ "objects": "Objektai",
51
+ "people_and_body": "Žmonės ir kūnas",
52
+ "smileys_and_emotion": "Šypsenos ir emocijos",
53
+ "symbols": "Simboliai",
54
+ "travel_and_places": "Kelionės ir vietos"
55
+ },
44
56
  "tables": {
45
57
  "table": "Lentelė",
46
58
  "insertTable": "Įterpti lentelę",
@@ -110,7 +122,8 @@
110
122
  },
111
123
  "misc": {
112
124
  "source": "Žiūrėti išeities kodą",
113
- "preview": "Peržiūra"
125
+ "preview": "Peržiūra",
126
+ "toggleInvisibleCharacters": "Rodyti/slėpti nematomus simbolius"
114
127
  },
115
128
  "footer": {
116
129
  "words": "žodžiai",
@@ -41,6 +41,18 @@
41
41
  "media": {
42
42
  "link": "Externe link",
43
43
  "image": "Afbeelding",
44
+ "emoji": {
45
+ "activities": "Activiteiten",
46
+ "animals_and_nature": "Dieren en natuur",
47
+ "component": "Component",
48
+ "flags": "Vlaggen",
49
+ "food_and_drink": "Eten en drinken",
50
+ "objects": "Objecten",
51
+ "people_and_body": "Mensen en lichaam",
52
+ "smileys_and_emotion": "Smileys en emoties",
53
+ "symbols": "Symbolen",
54
+ "travel_and_places": "Reizen en plaatsen"
55
+ },
44
56
  "tables": {
45
57
  "table": "Tabel",
46
58
  "insertTable": "Tabel invoegen",
@@ -110,7 +122,8 @@
110
122
  },
111
123
  "misc": {
112
124
  "source": "Broncode bekijken",
113
- "preview": "Voorvertoning"
125
+ "preview": "Voorvertoning",
126
+ "toggleInvisibleCharacters": "Onzichtbare tekens tonen/verbergen"
114
127
  },
115
128
  "footer": {
116
129
  "words": "woorden",
@@ -41,6 +41,18 @@
41
41
  "media": {
42
42
  "link": "Link zewnętrzny",
43
43
  "image": "Obraz",
44
+ "emoji": {
45
+ "activities": "Aktywności",
46
+ "animals_and_nature": "Zwierzęta i natura",
47
+ "component": "Komponent",
48
+ "flags": "Flagi",
49
+ "food_and_drink": "Jedzenie i napoje",
50
+ "objects": "Obiekty",
51
+ "people_and_body": "Ludzie i ciało",
52
+ "smileys_and_emotion": "Buźki i emocje",
53
+ "symbols": "Symbole",
54
+ "travel_and_places": "Podróże i miejsca"
55
+ },
44
56
  "tables": {
45
57
  "table": "Tabela",
46
58
  "insertTable": "Wstaw tabelę",
@@ -110,7 +122,8 @@
110
122
  },
111
123
  "misc": {
112
124
  "source": "Pokaż kod źródłowy",
113
- "preview": "Podgląd"
125
+ "preview": "Podgląd",
126
+ "toggleInvisibleCharacters": "Pokaż/ukryj niewidoczne znaki"
114
127
  },
115
128
  "footer": {
116
129
  "words": "słowa",
@@ -41,6 +41,18 @@
41
41
  "media": {
42
42
  "link": "Link externo",
43
43
  "image": "Imagem",
44
+ "emoji": {
45
+ "activities": "Atividades",
46
+ "animals_and_nature": "Animais e natureza",
47
+ "component": "Componente",
48
+ "flags": "Bandeiras",
49
+ "food_and_drink": "Comida e bebida",
50
+ "objects": "Objetos",
51
+ "people_and_body": "Pessoas e corpo",
52
+ "smileys_and_emotion": "Smileys e emoções",
53
+ "symbols": "Símbolos",
54
+ "travel_and_places": "Viagens e lugares"
55
+ },
44
56
  "tables": {
45
57
  "table": "Tabela",
46
58
  "insertTable": "Inserir tabela",
@@ -110,7 +122,8 @@
110
122
  },
111
123
  "misc": {
112
124
  "source": "Ver código fonte",
113
- "preview": "Visualização"
125
+ "preview": "Visualização",
126
+ "toggleInvisibleCharacters": "Mostrar/ocultar caracteres invisíveis"
114
127
  },
115
128
  "footer": {
116
129
  "words": "palavras",
@@ -41,6 +41,18 @@
41
41
  "media": {
42
42
  "link": "Внешняя ссылка",
43
43
  "image": "Изображение",
44
+ "emoji": {
45
+ "activities": "Активности",
46
+ "animals_and_nature": "Животные и природа",
47
+ "component": "Компонент",
48
+ "flags": "Флаги",
49
+ "food_and_drink": "Еда и напитки",
50
+ "objects": "Объекты",
51
+ "people_and_body": "Люди и части тела",
52
+ "smileys_and_emotion": "Смайлики и эмоции",
53
+ "symbols": "Символы",
54
+ "travel_and_places": "Путешествия и места"
55
+ },
44
56
  "tables": {
45
57
  "table": "Таблица",
46
58
  "insertTable": "Вставить таблицу",
@@ -110,7 +122,8 @@
110
122
  },
111
123
  "misc": {
112
124
  "source": "Просмотр исходного кода",
113
- "preview": "Предпросмотр"
125
+ "preview": "Предпросмотр",
126
+ "toggleInvisibleCharacters": "Показать/скрыть невидимые символы"
114
127
  },
115
128
  "footer": {
116
129
  "words": "слова",
@@ -41,6 +41,18 @@
41
41
  "media": {
42
42
  "link": "Extern länk",
43
43
  "image": "Bild",
44
+ "emoji": {
45
+ "activities": "Aktiviteter",
46
+ "animals_and_nature": "Djur och natur",
47
+ "component": "Komponent",
48
+ "flags": "Flaggor",
49
+ "food_and_drink": "Mat och dryck",
50
+ "objects": "Objekt",
51
+ "people_and_body": "Människor och kropp",
52
+ "smileys_and_emotion": "Smileys och känslor",
53
+ "symbols": "Symboler",
54
+ "travel_and_places": "Resor och platser"
55
+ },
44
56
  "tables": {
45
57
  "table": "Tabell",
46
58
  "insertTable": "Sätt in tabell",
@@ -110,7 +122,8 @@
110
122
  },
111
123
  "misc": {
112
124
  "source": "Visa källkod",
113
- "preview": "Förhandsgranskning"
125
+ "preview": "Förhandsgranskning",
126
+ "toggleInvisibleCharacters": "Visa/dölj osynliga tecken"
114
127
  },
115
128
  "footer": {
116
129
  "words": "ord",
@@ -41,6 +41,18 @@
41
41
  "media": {
42
42
  "link": "Зовнішнє посилання",
43
43
  "image": "Зображення",
44
+ "emoji": {
45
+ "activities": "Активності",
46
+ "animals_and_nature": "Тварини та природа",
47
+ "component": "Компонент",
48
+ "flags": "Прапори",
49
+ "food_and_drink": "Їжа та напої",
50
+ "objects": "Об'єкти",
51
+ "people_and_body": "Люди та частини тіла",
52
+ "smileys_and_emotion": "Смайлики та емоції",
53
+ "symbols": "Символи",
54
+ "travel_and_places": "Подорожі та місця"
55
+ },
44
56
  "tables": {
45
57
  "table": "Таблиця",
46
58
  "insertTable": "Вставити таблицю",
@@ -110,7 +122,8 @@
110
122
  },
111
123
  "misc": {
112
124
  "source": "Перегляд вихідного коду",
113
- "preview": "Попередній перегляд"
125
+ "preview": "Попередній перегляд",
126
+ "toggleInvisibleCharacters": "Показати/приховати невидимі символи"
114
127
  },
115
128
  "footer": {
116
129
  "words": "слова",
package/src/index.ts CHANGED
@@ -1,5 +1,6 @@
1
1
  import { Plugin } from 'vue';
2
2
  import Tiptapify from '@tiptapify/components/Tiptapify.vue';
3
+ import TiptapifyDialog from '@tiptapify/components/UI/TiptapifyDialog.vue';
3
4
  import { getI18n } from "@tiptapify/i18n";
4
5
 
5
6
  interface PackageOptions {
@@ -11,8 +12,9 @@ const TiptapifyPlugin: Plugin = {
11
12
  const locale = options.locale || 'en'
12
13
  app.use(getI18n(locale));
13
14
  app.component('Tiptapify', Tiptapify);
15
+ app.component('TiptapifyDialog', TiptapifyDialog);
14
16
  }
15
17
  };
16
18
 
17
- export { Tiptapify };
19
+ export { Tiptapify, TiptapifyDialog };
18
20
  export default TiptapifyPlugin;
@@ -0,0 +1,22 @@
1
+ import { ToolbarSections } from "@tiptapify/types/toolbarSections";
2
+ import { ComputedRef } from "vue";
3
+
4
+ export enum ToolbarItemType {
5
+ dropdown = 'dropdown',
6
+ modal = 'modal',
7
+ }
8
+
9
+ export type extensionComponents = {
10
+ [key: string]: {
11
+ type: ToolbarItemType,
12
+ component: any,
13
+ extensions?: Array<any>,
14
+ componentProps?: any
15
+ props?: any
16
+ attrs?: any
17
+ section: ToolbarSections,
18
+ name: ComputedRef|string,
19
+ tooltip: ComputedRef|string,
20
+ icon: ComputedRef|string,
21
+ }
22
+ }
@@ -0,0 +1,43 @@
1
+ import { ComputedRef } from "vue";
2
+
3
+ type ToolbarItemAttrs = {
4
+ [key: string]: Function | any
5
+ }
6
+
7
+ type ToolbarItemProps = {
8
+ [key: string]: any
9
+ }
10
+
11
+ export type ToolbarItem = {
12
+ // type: ToolbarItemType,
13
+ name: string|number|ComputedRef<string>,
14
+ tooltip: string|ComputedRef<string>,
15
+ icon: string|ComputedRef<string>,
16
+ icon2?: string|ComputedRef<string>,
17
+ svg?: boolean,
18
+ noI18n?: boolean,
19
+ enabled: boolean,
20
+ component?: any,
21
+ modelValue?: any,
22
+ group?: boolean,
23
+ toggle?: boolean,
24
+ icon2Props?: ToolbarItemProps,
25
+ componentProps?: ToolbarItemProps,
26
+ props?: ToolbarItemProps,
27
+ attrs?: ToolbarItemAttrs,
28
+ children?: ToolbarItems|ToolbarItem[],
29
+ }
30
+
31
+ export type ToolbarItems = {
32
+ [key: string]: ToolbarItem
33
+ }
34
+
35
+ export type ToolbarItemSection = {
36
+ group?: boolean,
37
+ toggle?: boolean,
38
+ items: ToolbarItems | {},
39
+ }
40
+
41
+ export type ToolbarItemSections = {
42
+ [key: string]: ToolbarItemSection
43
+ }
@@ -0,0 +1,11 @@
1
+ export enum ToolbarSections {
2
+ actions = 'actions',
3
+ alignment = 'alignment',
4
+ extra = 'extra',
5
+ formatExtra = 'formatExtra',
6
+ format = 'format',
7
+ list = 'list',
8
+ media = 'media',
9
+ misc = 'misc',
10
+ style = 'style',
11
+ }
@@ -1,6 +0,0 @@
1
- export enum OverridableExtensions {
2
- link = 'link',
3
- image = 'image',
4
- }
5
-
6
- export interface extensionsComponents { [key: string]: { component: any, props?: any} }