@dialpad/dialtone 9.139.0 → 9.140.0

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 (97) hide show
  1. package/dist/tokens/doc.json +59091 -59091
  2. package/dist/vue2/component-documentation.json +1 -1
  3. package/dist/vue2/lib/emoji-picker/emoji-picker.cjs.map +1 -1
  4. package/dist/vue2/lib/emoji-picker/emoji-picker.js.map +1 -1
  5. package/dist/vue2/lib/emoji-row/emoji-row.cjs +1 -1
  6. package/dist/vue2/lib/emoji-row/emoji-row.cjs.map +1 -1
  7. package/dist/vue2/lib/emoji-row/emoji-row.js +1 -1
  8. package/dist/vue2/lib/emoji-row/emoji-row.js.map +1 -1
  9. package/dist/vue2/lib/message-input/message-input.cjs +1 -1
  10. package/dist/vue2/lib/message-input/message-input.cjs.map +1 -1
  11. package/dist/vue2/lib/message-input/message-input.js +26 -18
  12. package/dist/vue2/lib/message-input/message-input.js.map +1 -1
  13. package/dist/vue2/lib/pagination/pagination.cjs +1 -1
  14. package/dist/vue2/lib/pagination/pagination.cjs.map +1 -1
  15. package/dist/vue2/lib/pagination/pagination.js +6 -3
  16. package/dist/vue2/lib/pagination/pagination.js.map +1 -1
  17. package/dist/vue2/lib/rich-text-editor/channel-suggestion.cjs.map +1 -1
  18. package/dist/vue2/lib/rich-text-editor/channel-suggestion.js.map +1 -1
  19. package/dist/vue2/lib/rich-text-editor/rich-text-editor-constants.cjs +1 -1
  20. package/dist/vue2/lib/rich-text-editor/rich-text-editor-constants.cjs.map +1 -1
  21. package/dist/vue2/lib/rich-text-editor/rich-text-editor-constants.js +2 -1
  22. package/dist/vue2/lib/rich-text-editor/rich-text-editor-constants.js.map +1 -1
  23. package/dist/vue2/lib/rich-text-editor/rich-text-editor.cjs +13 -4
  24. package/dist/vue2/lib/rich-text-editor/rich-text-editor.cjs.map +1 -1
  25. package/dist/vue2/lib/rich-text-editor/rich-text-editor.js +356 -225
  26. package/dist/vue2/lib/rich-text-editor/rich-text-editor.js.map +1 -1
  27. package/dist/vue2/lib/tooltip/tooltip.cjs +1 -1
  28. package/dist/vue2/lib/tooltip/tooltip.cjs.map +1 -1
  29. package/dist/vue2/lib/tooltip/tooltip.js +1 -1
  30. package/dist/vue2/lib/tooltip/tooltip.js.map +1 -1
  31. package/dist/vue2/lib/tooltip-directive/tooltip.cjs +1 -1
  32. package/dist/vue2/lib/tooltip-directive/tooltip.cjs.map +1 -1
  33. package/dist/vue2/lib/tooltip-directive/tooltip.js +19 -14
  34. package/dist/vue2/lib/tooltip-directive/tooltip.js.map +1 -1
  35. package/dist/vue2/localization/ja-JP.cjs +2 -0
  36. package/dist/vue2/localization/ja-JP.cjs.map +1 -1
  37. package/dist/vue2/localization/ja-JP.js +2 -0
  38. package/dist/vue2/localization/ja-JP.js.map +1 -1
  39. package/dist/vue2/types/components/pagination/pagination.vue.d.ts.map +1 -1
  40. package/dist/vue2/types/components/rich_text_editor/extensions/mentions/mention.d.ts.map +1 -1
  41. package/dist/vue2/types/components/rich_text_editor/rich_text_editor.vue.d.ts +21 -1
  42. package/dist/vue2/types/components/rich_text_editor/rich_text_editor.vue.d.ts.map +1 -1
  43. package/dist/vue2/types/components/rich_text_editor/rich_text_editor_constants.d.ts.map +1 -1
  44. package/dist/vue2/types/directives/tooltip_directive/tooltip.d.ts.map +1 -1
  45. package/dist/vue2/types/recipes/conversation_view/emoji_row/emoji_row.vue.d.ts.map +1 -1
  46. package/dist/vue2/types/recipes/conversation_view/message_input/message_input.vue.d.ts +2 -1
  47. package/dist/vue2/types/recipes/conversation_view/message_input/message_input.vue.d.ts.map +1 -1
  48. package/dist/vue3/component-documentation.json +1 -1
  49. package/dist/vue3/lib/emoji-picker/emoji-picker.cjs.map +1 -1
  50. package/dist/vue3/lib/emoji-picker/emoji-picker.js.map +1 -1
  51. package/dist/vue3/lib/emoji-row/emoji-row.cjs +1 -1
  52. package/dist/vue3/lib/emoji-row/emoji-row.cjs.map +1 -1
  53. package/dist/vue3/lib/emoji-row/emoji-row.js +5 -4
  54. package/dist/vue3/lib/emoji-row/emoji-row.js.map +1 -1
  55. package/dist/vue3/lib/message-input/message-input.cjs +1 -1
  56. package/dist/vue3/lib/message-input/message-input.cjs.map +1 -1
  57. package/dist/vue3/lib/message-input/message-input.js +37 -28
  58. package/dist/vue3/lib/message-input/message-input.js.map +1 -1
  59. package/dist/vue3/lib/pagination/pagination.cjs +1 -1
  60. package/dist/vue3/lib/pagination/pagination.cjs.map +1 -1
  61. package/dist/vue3/lib/pagination/pagination.js +37 -32
  62. package/dist/vue3/lib/pagination/pagination.js.map +1 -1
  63. package/dist/vue3/lib/rich-text-editor/channel-suggestion.cjs.map +1 -1
  64. package/dist/vue3/lib/rich-text-editor/channel-suggestion.js.map +1 -1
  65. package/dist/vue3/lib/rich-text-editor/rich-text-editor-constants.cjs +1 -1
  66. package/dist/vue3/lib/rich-text-editor/rich-text-editor-constants.cjs.map +1 -1
  67. package/dist/vue3/lib/rich-text-editor/rich-text-editor-constants.js +2 -1
  68. package/dist/vue3/lib/rich-text-editor/rich-text-editor-constants.js.map +1 -1
  69. package/dist/vue3/lib/rich-text-editor/rich-text-editor.cjs +15 -6
  70. package/dist/vue3/lib/rich-text-editor/rich-text-editor.cjs.map +1 -1
  71. package/dist/vue3/lib/rich-text-editor/rich-text-editor.js +421 -278
  72. package/dist/vue3/lib/rich-text-editor/rich-text-editor.js.map +1 -1
  73. package/dist/vue3/lib/tooltip/tooltip.cjs +1 -1
  74. package/dist/vue3/lib/tooltip/tooltip.cjs.map +1 -1
  75. package/dist/vue3/lib/tooltip/tooltip.js +1 -1
  76. package/dist/vue3/lib/tooltip/tooltip.js.map +1 -1
  77. package/dist/vue3/lib/tooltip-directive/tooltip.cjs +1 -1
  78. package/dist/vue3/lib/tooltip-directive/tooltip.cjs.map +1 -1
  79. package/dist/vue3/lib/tooltip-directive/tooltip.js +19 -14
  80. package/dist/vue3/lib/tooltip-directive/tooltip.js.map +1 -1
  81. package/dist/vue3/localization/ja-JP.cjs +2 -0
  82. package/dist/vue3/localization/ja-JP.cjs.map +1 -1
  83. package/dist/vue3/localization/ja-JP.js +2 -0
  84. package/dist/vue3/localization/ja-JP.js.map +1 -1
  85. package/dist/vue3/types/components/pagination/pagination.vue.d.ts.map +1 -1
  86. package/dist/vue3/types/components/rich_text_editor/extensions/channels/ChannelComponent.vue.d.ts +1 -1
  87. package/dist/vue3/types/components/rich_text_editor/extensions/channels/ChannelComponent.vue.d.ts.map +1 -1
  88. package/dist/vue3/types/components/rich_text_editor/extensions/mentions/mention.d.ts.map +1 -1
  89. package/dist/vue3/types/components/rich_text_editor/rich_text_editor.vue.d.ts +22 -1
  90. package/dist/vue3/types/components/rich_text_editor/rich_text_editor.vue.d.ts.map +1 -1
  91. package/dist/vue3/types/components/rich_text_editor/rich_text_editor_constants.d.ts.map +1 -1
  92. package/dist/vue3/types/components/tooltip/tooltip.vue.d.ts.map +1 -1
  93. package/dist/vue3/types/directives/tooltip_directive/tooltip.d.ts.map +1 -1
  94. package/dist/vue3/types/recipes/conversation_view/emoji_row/emoji_row.vue.d.ts.map +1 -1
  95. package/dist/vue3/types/recipes/conversation_view/message_input/message_input.vue.d.ts +3 -1
  96. package/dist/vue3/types/recipes/conversation_view/message_input/message_input.vue.d.ts.map +1 -1
  97. package/package.json +3 -7
@@ -1,61 +1,62 @@
1
- import { nodeViewProps as L, NodeViewWrapper as R, VueRenderer as v, VueNodeViewRenderer as O, BubbleMenu as G, EditorContent as Q, Editor as Z } from "../../node_modules/@tiptap/vue-3.js";
2
- import { Node as ee, nodePasteRule as P, InputRule as te, mergeAttributes as b, getMarksBetween as ne, combineTransactionSteps as oe, getChangedRanges as re, findChildrenInRange as ie, Mark as se, nodeInputRule as ae, Extension as le } from "@tiptap/core";
3
- import ce from "@tiptap/extension-blockquote";
4
- import de from "@tiptap/extension-code-block";
1
+ import { nodeViewProps as $, NodeViewWrapper as R, VueRenderer as v, VueNodeViewRenderer as I, BubbleMenu as G, EditorContent as Q, Editor as Z } from "../../node_modules/@tiptap/vue-3.js";
2
+ import { Node as ee, nodePasteRule as A, InputRule as te, mergeAttributes as b, getMarksBetween as ne, combineTransactionSteps as oe, getChangedRanges as re, findChildrenInRange as se, Mark as ie, nodeInputRule as ae, Extension as ce } from "@tiptap/core";
3
+ import de from "@tiptap/extension-blockquote";
4
+ import le from "@tiptap/extension-code-block";
5
5
  import ue from "@tiptap/extension-code";
6
6
  import me from "@tiptap/extension-document";
7
7
  import he from "@tiptap/extension-hard-break";
8
- import W from "@tiptap/extension-paragraph";
9
- import fe from "@tiptap/extension-placeholder";
10
- import pe from "@tiptap/extension-bold";
8
+ import U from "@tiptap/extension-paragraph";
9
+ import pe from "@tiptap/extension-placeholder";
10
+ import fe from "@tiptap/extension-bold";
11
11
  import ge from "@tiptap/extension-bullet-list";
12
12
  import _e from "@tiptap/extension-italic";
13
- import ye from "@tiptap/extension-link";
14
- import we from "@tiptap/extension-list-item";
15
- import ke from "@tiptap/extension-ordered-list";
16
- import xe from "@tiptap/extension-strike";
13
+ import ke from "@tiptap/extension-link";
14
+ import ye from "@tiptap/extension-list-item";
15
+ import we from "@tiptap/extension-ordered-list";
16
+ import Ce from "@tiptap/extension-strike";
17
17
  import be from "@tiptap/extension-underline";
18
- import Ce from "@tiptap/extension-text";
18
+ import xe from "@tiptap/extension-text";
19
19
  import Te from "@tiptap/extension-text-align";
20
20
  import Ee from "@tiptap/extension-history";
21
21
  import Se from "@tiptap/extension-text-style";
22
22
  import Le from "@tiptap/extension-color";
23
- import Re from "@tiptap/extension-font-family";
24
- import { PluginKey as T, Plugin as ve } from "@tiptap/pm/state";
25
- import Oe from "@tiptap/suggestion";
26
- import { emojiPattern as q } from "regex-combined-emojis";
27
- import { resolveComponent as d, createBlock as h, openBlock as l, withCtx as u, createVNode as p, createElementBlock as _, withDirectives as Ie, createElementVNode as w, Fragment as Be, renderList as Me, withModifiers as $e, normalizeClass as z, resolveDynamicComponent as Ae, vShow as De, createTextVNode as k, toDisplayString as m, markRaw as I, createCommentVNode as x, mergeProps as Pe } from "vue";
23
+ import $e from "@tiptap/extension-font-family";
24
+ import { PluginKey as T, Plugin as Re } from "@tiptap/pm/state";
25
+ import ve from "@tiptap/suggestion";
26
+ import { emojiPattern as W } from "regex-combined-emojis";
27
+ import { resolveComponent as l, createBlock as m, openBlock as d, withCtx as u, createVNode as f, createElementBlock as _, withDirectives as Ie, createElementVNode as k, Fragment as Me, renderList as Be, withModifiers as Ne, normalizeClass as z, resolveDynamicComponent as Oe, vShow as De, createTextVNode as C, toDisplayString as h, markRaw as M, createCommentVNode as w, mergeProps as Ae } from "vue";
28
28
  import { _ as g } from "../../_plugin-vue_export-helper-CHgC5LLL.js";
29
29
  import X from "../emoji/emoji.js";
30
- import { getEmojiData as je, emojiRegex as He, stringToUnicode as Ne, codeToEmojiData as H, emojiShortCodeRegex as Fe } from "../../common/emoji/index.js";
31
- import Ke from "../list-item/list-item.js";
32
- import B from "../stack/stack.js";
33
- import M from "tippy.js";
34
- import { getPhoneNumberRegex as Ve, linkRegex as Ue, warnIfUnmounted as We, returnFirstEl as F } from "../../common/utils/index.js";
35
- import qe from "@tiptap/extension-image";
36
- import N from "@tiptap/extension-mention";
30
+ import { getEmojiData as Pe, emojiRegex as je, stringToUnicode as He, codeToEmojiData as j, emojiShortCodeRegex as Ke } from "../../common/emoji/index.js";
31
+ import Fe from "../list-item/list-item.js";
32
+ import E from "../stack/stack.js";
33
+ import B from "tippy.js";
34
+ import { getPhoneNumberRegex as Ve, linkRegex as qe, warnIfUnmounted as Ue, returnFirstEl as K } from "../../common/utils/index.js";
35
+ import We from "@tiptap/extension-image";
36
+ import H from "@tiptap/extension-mention";
37
37
  import J from "../link/link.js";
38
- import { RICH_TEXT_EDITOR_SUPPORTED_LINK_PROTOCOLS as K, RICH_TEXT_EDITOR_OUTPUT_FORMATS as ze, RICH_TEXT_EDITOR_AUTOFOCUS_TYPES as Xe } from "./rich-text-editor-constants.js";
39
- import Je from "../avatar/avatar.js";
40
- import Ye from "@dialpad/dialtone-icons/vue3/hash";
41
- import Ge from "@dialpad/dialtone-icons/vue3/lock";
42
- import Qe from "deep-equal";
43
- import { DialtoneLocalization as Ze } from "../../localization/index.js";
44
- import et from "../button/button.js";
45
- const tt = {
38
+ import { DtIconLock as ze } from "@dialpad/dialtone-icons/vue3";
39
+ import { RICH_TEXT_EDITOR_SUPPORTED_LINK_PROTOCOLS as F, RICH_TEXT_EDITOR_OUTPUT_FORMATS as Xe, RICH_TEXT_EDITOR_AUTOFOCUS_TYPES as Je } from "./rich-text-editor-constants.js";
40
+ import Ye from "../avatar/avatar.js";
41
+ import Ge from "@dialpad/dialtone-icons/vue3/hash";
42
+ import Qe from "@dialpad/dialtone-icons/vue3/lock";
43
+ import Ze from "deep-equal";
44
+ import { DialtoneLocalization as et } from "../../localization/index.js";
45
+ import tt from "../button/button.js";
46
+ const nt = {
46
47
  compatConfig: { MODE: 3 },
47
48
  name: "EmojiComponent",
48
49
  components: {
49
50
  NodeViewWrapper: R,
50
51
  DtEmoji: X
51
52
  },
52
- props: L
53
+ props: $
53
54
  };
54
- function nt(e, t, o, n, r, i) {
55
- const s = d("dt-emoji"), a = d("node-view-wrapper");
56
- return l(), h(a, { class: "d-d-inline-block d-va-bottom d-lh0" }, {
55
+ function ot(e, t, o, n, r, s) {
56
+ const i = l("dt-emoji"), a = l("node-view-wrapper");
57
+ return d(), m(a, { class: "d-d-inline-block d-va-bottom d-lh0" }, {
57
58
  default: u(() => [
58
- p(s, {
59
+ f(i, {
59
60
  size: "500",
60
61
  code: e.node.attrs.code
61
62
  }, null, 8, ["code"])
@@ -63,11 +64,11 @@ function nt(e, t, o, n, r, i) {
63
64
  _: 1
64
65
  });
65
66
  }
66
- const ot = /* @__PURE__ */ g(tt, [["render", nt]]), rt = {
67
+ const rt = /* @__PURE__ */ g(nt, [["render", ot]]), st = {
67
68
  compatConfig: { MODE: 3 },
68
69
  name: "SuggestionList",
69
70
  components: {
70
- DtListItem: Ke
71
+ DtListItem: Fe
71
72
  },
72
73
  props: {
73
74
  items: {
@@ -128,7 +129,7 @@ const ot = /* @__PURE__ */ g(tt, [["render", nt]]), rt = {
128
129
  this.command({ name: t.name, id: t.id, avatarSrc: t.avatarSrc });
129
130
  break;
130
131
  case "channel":
131
- this.command({ name: t.name, id: t.id });
132
+ this.command({ name: t.name, id: t.id, locked: t.locked });
132
133
  break;
133
134
  case "slash-command":
134
135
  this.command({ command: t.command });
@@ -136,26 +137,26 @@ const ot = /* @__PURE__ */ g(tt, [["render", nt]]), rt = {
136
137
  }
137
138
  }
138
139
  }
139
- }, it = { class: "d-popover__dialog d-suggestion-list__container" }, st = {
140
+ }, it = { class: "d-popover__dialog d-suggestion-list__container" }, at = {
140
141
  ref: "suggestionList",
141
142
  class: "d-suggestion-list"
142
143
  };
143
- function at(e, t, o, n, r, i) {
144
- const s = d("dt-list-item");
145
- return l(), _("div", it, [
146
- Ie(w("ul", st, [
147
- (l(!0), _(Be, null, Me(o.items, (a, c) => (l(), h(s, {
144
+ function ct(e, t, o, n, r, s) {
145
+ const i = l("dt-list-item");
146
+ return d(), _("div", it, [
147
+ Ie(k("ul", at, [
148
+ (d(!0), _(Me, null, Be(o.items, (a, c) => (d(), m(i, {
148
149
  key: a.id,
149
150
  class: z([
150
151
  "d-suggestion-list__item",
151
152
  { "d-list-item--highlighted": c === r.selectedIndex }
152
153
  ]),
153
154
  "navigation-type": "arrow-keys",
154
- onClick: (f) => i.selectItem(c),
155
- onKeydown: $e(i.onKeyDown, ["prevent"])
155
+ onClick: (p) => s.selectItem(c),
156
+ onKeydown: Ne(s.onKeyDown, ["prevent"])
156
157
  }, {
157
158
  default: u(() => [
158
- (l(), h(Ae(o.itemComponent), { item: a }, null, 8, ["item"]))
159
+ (d(), m(Oe(o.itemComponent), { item: a }, null, 8, ["item"]))
159
160
  ]),
160
161
  _: 2
161
162
  }, 1032, ["class", "onClick", "onKeydown"]))), 128))
@@ -164,12 +165,12 @@ function at(e, t, o, n, r, i) {
164
165
  ])
165
166
  ]);
166
167
  }
167
- const $ = /* @__PURE__ */ g(rt, [["render", at]]), lt = {
168
+ const N = /* @__PURE__ */ g(st, [["render", ct]]), dt = {
168
169
  compatConfig: { MODE: 3 },
169
170
  name: "EmojiSuggestion",
170
171
  components: {
171
172
  DtEmoji: X,
172
- DtStack: B
173
+ DtStack: E
173
174
  },
174
175
  props: {
175
176
  item: {
@@ -178,23 +179,23 @@ const $ = /* @__PURE__ */ g(rt, [["render", at]]), lt = {
178
179
  }
179
180
  }
180
181
  };
181
- function ct(e, t, o, n, r, i) {
182
- const s = d("dt-emoji"), a = d("dt-stack");
183
- return l(), h(a, {
182
+ function lt(e, t, o, n, r, s) {
183
+ const i = l("dt-emoji"), a = l("dt-stack");
184
+ return d(), m(a, {
184
185
  direction: "row",
185
186
  gap: "400"
186
187
  }, {
187
188
  default: u(() => [
188
- p(s, {
189
+ f(i, {
189
190
  size: "200",
190
191
  code: o.item.code
191
192
  }, null, 8, ["code"]),
192
- k(" " + m(o.item.code), 1)
193
+ C(" " + h(o.item.code), 1)
193
194
  ]),
194
195
  _: 1
195
196
  });
196
197
  }
197
- const dt = /* @__PURE__ */ g(lt, [["render", ct]]), A = {
198
+ const ut = /* @__PURE__ */ g(dt, [["render", lt]]), O = {
198
199
  name: "hideOnEsc",
199
200
  defaultValue: !0,
200
201
  fn({ hide: e }) {
@@ -210,15 +211,15 @@ const dt = /* @__PURE__ */ g(lt, [["render", ct]]), A = {
210
211
  }
211
212
  };
212
213
  }
213
- }, ut = 20, mt = (e, t, o) => {
214
+ }, mt = 20, ht = (e, t, o) => {
214
215
  var a, c;
215
- const n = (a = e.shortname) == null ? void 0 : a.replaceAll(":", ""), r = (c = t.shortname) == null ? void 0 : c.replaceAll(":", ""), i = n.startsWith(o), s = r.startsWith(o);
216
- return i && !s ? -1 : !i && s ? 1 : n.localeCompare(r);
217
- }, ht = {
216
+ const n = (a = e.shortname) == null ? void 0 : a.replaceAll(":", ""), r = (c = t.shortname) == null ? void 0 : c.replaceAll(":", ""), s = n.startsWith(o), i = r.startsWith(o);
217
+ return s && !i ? -1 : !s && i ? 1 : n.localeCompare(r);
218
+ }, pt = {
218
219
  items: ({ query: e }) => {
219
220
  if (e.length < 2)
220
221
  return [];
221
- const t = Object.values(je());
222
+ const t = Object.values(Pe());
222
223
  return e = e.toLowerCase(), t.filter(
223
224
  (n) => {
224
225
  var r;
@@ -226,32 +227,32 @@ const dt = /* @__PURE__ */ g(lt, [["render", ct]]), A = {
226
227
  n.name,
227
228
  (r = n.shortname) == null ? void 0 : r.replaceAll(":", ""),
228
229
  ...n.keywords || []
229
- ].some((i) => i && i.startsWith(e));
230
+ ].some((s) => s && s.startsWith(e));
230
231
  }
231
- ).splice(0, ut).sort((n, r) => mt(n, r, e)).map((n) => ({ code: n.shortname }));
232
+ ).splice(0, mt).sort((n, r) => ht(n, r, e)).map((n) => ({ code: n.shortname }));
232
233
  },
233
234
  command: ({ editor: e, range: t, props: o }) => {
234
- var i, s;
235
+ var s, i;
235
236
  const n = e.view.state.selection.$to.nodeAfter;
236
- ((i = n == null ? void 0 : n.text) == null ? void 0 : i.startsWith(" ")) && (t.to += 1), e.chain().focus().insertContentAt(t, [
237
+ ((s = n == null ? void 0 : n.text) == null ? void 0 : s.startsWith(" ")) && (t.to += 1), e.chain().focus().insertContentAt(t, [
237
238
  {
238
239
  type: "emoji",
239
240
  attrs: o
240
241
  }
241
- ]).run(), (s = window.getSelection()) == null || s.collapseToEnd();
242
+ ]).run(), (i = window.getSelection()) == null || i.collapseToEnd();
242
243
  },
243
244
  render: () => {
244
245
  let e, t, o = !1;
245
246
  return {
246
247
  onStart: (n) => {
247
- e = new v($, {
248
+ e = new v(N, {
248
249
  props: {
249
- itemComponent: I(dt),
250
+ itemComponent: M(ut),
250
251
  itemType: "emoji",
251
252
  ...n
252
253
  },
253
254
  editor: n.editor
254
- }), n.clientRect && (t = M("body", {
255
+ }), n.clientRect && (t = B("body", {
255
256
  getReferenceClientRect: n.clientRect,
256
257
  appendTo: () => document.body,
257
258
  content: e.element,
@@ -266,7 +267,7 @@ const dt = /* @__PURE__ */ g(lt, [["render", ct]]), A = {
266
267
  trigger: "manual",
267
268
  placement: "top-start",
268
269
  zIndex: 650,
269
- plugins: [A]
270
+ plugins: [O]
270
271
  }), n.items.length > 0 && (t == null || t[0].show()));
271
272
  },
272
273
  onUpdate(n) {
@@ -284,10 +285,10 @@ const dt = /* @__PURE__ */ g(lt, [["render", ct]]), A = {
284
285
  }
285
286
  };
286
287
  }
287
- }, ft = /(:\w+:)$/, pt = new RegExp(q + "$"), gt = (e) => {
288
- if (e && H(e[0]))
288
+ }, ft = /(:\w+:)$/, gt = new RegExp(W + "$"), _t = (e) => {
289
+ if (e && j(e[0]))
289
290
  return { text: e[2] || e[0] };
290
- }, _t = (e) => [...e.matchAll(Fe)].filter((o) => H(o[0])).map((o) => ({
291
+ }, kt = (e) => [...e.matchAll(Ke)].filter((o) => j(o[0])).map((o) => ({
291
292
  index: o.index,
292
293
  text: o[0],
293
294
  match: o
@@ -303,7 +304,7 @@ const dt = /* @__PURE__ */ g(lt, [["render", ct]]), A = {
303
304
  selectable: !1,
304
305
  atom: !0,
305
306
  addNodeView() {
306
- return O(ot);
307
+ return I(rt);
307
308
  },
308
309
  addAttributes() {
309
310
  return {
@@ -320,7 +321,7 @@ const dt = /* @__PURE__ */ g(lt, [["render", ct]]), A = {
320
321
  ];
321
322
  },
322
323
  renderText({ node: e }) {
323
- return Ne(H(e.attrs.code).unicode_output);
324
+ return He(j(e.attrs.code).unicode_output);
324
325
  },
325
326
  renderHTML({ HTMLAttributes: e }) {
326
327
  return ["emoji-component", b(this.options.HTMLAttributes, e)];
@@ -329,21 +330,21 @@ const dt = /* @__PURE__ */ g(lt, [["render", ct]]), A = {
329
330
  return [
330
331
  new te({
331
332
  find: (e) => {
332
- const t = e.match(ft) || e.match(pt);
333
+ const t = e.match(ft) || e.match(gt);
333
334
  if (t)
334
- return gt(t);
335
+ return _t(t);
335
336
  },
336
337
  handler: ({ state: e, range: t, match: o }) => {
337
- const { tr: n } = e, r = t.from, i = t.to;
338
- n.replaceWith(r, i, this.type.create({ code: o[0] }));
338
+ const { tr: n } = e, r = t.from, s = t.to;
339
+ n.replaceWith(r, s, this.type.create({ code: o[0] }));
339
340
  }
340
341
  })
341
342
  ];
342
343
  },
343
344
  addPasteRules() {
344
345
  return [
345
- P({
346
- find: _t,
346
+ A({
347
+ find: kt,
347
348
  type: this.type,
348
349
  getAttributes(e) {
349
350
  return {
@@ -351,8 +352,8 @@ const dt = /* @__PURE__ */ g(lt, [["render", ct]]), A = {
351
352
  };
352
353
  }
353
354
  }),
354
- P({
355
- find: He,
355
+ A({
356
+ find: je,
356
357
  type: this.type,
357
358
  getAttributes(e) {
358
359
  return {
@@ -364,12 +365,12 @@ const dt = /* @__PURE__ */ g(lt, [["render", ct]]), A = {
364
365
  },
365
366
  addProseMirrorPlugins() {
366
367
  return [
367
- Oe({
368
+ ve({
368
369
  char: ":",
369
370
  pluginKey: new T("emoji"),
370
371
  editor: this.editor,
371
372
  ...this.options.suggestion,
372
- ...ht
373
+ ...pt
373
374
  })
374
375
  ];
375
376
  },
@@ -377,10 +378,10 @@ const dt = /* @__PURE__ */ g(lt, [["render", ct]]), A = {
377
378
  return {
378
379
  Backspace: () => this.editor.commands.command(({ tr: e, state: t }) => {
379
380
  let o = !1;
380
- const { selection: n } = t, { empty: r, anchor: i } = n;
381
- return r ? (t.doc.nodesBetween(i - 1, i, (s, a) => {
382
- if (s.type.name === this.name)
383
- return o = !0, e.insertText("", a, a + s.nodeSize), !1;
381
+ const { selection: n } = t, { empty: r, anchor: s } = n;
382
+ return r ? (t.doc.nodesBetween(s - 1, s, (i, a) => {
383
+ if (i.type.name === this.name)
384
+ return o = !0, e.insertText("", a, a + i.nodeSize), !1;
384
385
  }), o) : !1;
385
386
  })
386
387
  };
@@ -394,10 +395,10 @@ function wt(e, t, o = () => !0) {
394
395
  o(e, r) && n.push(r);
395
396
  return n;
396
397
  }
397
- function kt(e, t) {
398
+ function Ct(e, t) {
398
399
  return !["#", "@"].includes(e.charAt(t.index)) && !["#", "@"].includes(e.charAt(t.index - 1));
399
400
  }
400
- function xt(e) {
401
+ function bt(e) {
401
402
  const t = new RegExp(
402
403
  "(?:" + [
403
404
  `[!?.,:;'"]`,
@@ -407,7 +408,7 @@ function xt(e) {
407
408
  );
408
409
  return e.replace(t, "");
409
410
  }
410
- function bt(e, t) {
411
+ function xt(e, t) {
411
412
  const o = e.slice(0, t + 1).search(/\S+\s*$/), n = e.slice(t).search(/\s/);
412
413
  if (n < 0) {
413
414
  const r = e.slice(o);
@@ -423,77 +424,77 @@ function bt(e, t) {
423
424
  to: n + t
424
425
  };
425
426
  }
426
- function j(e, t, o, n) {
427
- const r = bt(e, t);
427
+ function P(e, t, o, n) {
428
+ const r = xt(e, t);
428
429
  if (n.lastIndex = 0, !n.test(r.text))
429
430
  return r;
430
- const i = o === "left" ? r.from - 1 : r.to + 1;
431
- return i <= 0 || i >= e.length || i === t ? r : j(e, i, o, n);
431
+ const s = o === "left" ? r.from - 1 : r.to + 1;
432
+ return s <= 0 || s >= e.length || s === t ? r : P(e, s, o, n);
432
433
  }
433
- function Ct(e, t, o, n) {
434
- const r = Math.max(e.from - 1, 0), i = Math.min(e.to + 1, t.content.size), s = ne(r, i, t);
435
- for (const a of s)
434
+ function Tt(e, t, o, n) {
435
+ const r = Math.max(e.from - 1, 0), s = Math.min(e.to + 1, t.content.size), i = ne(r, s, t);
436
+ for (const a of i)
436
437
  a.mark.type === n && o.removeMark(a.from, a.to, n);
437
438
  }
438
439
  const V = Ve(1, 15);
439
- function U(e, t, o, n, r, i) {
440
+ function q(e, t, o, n, r, s) {
440
441
  if (!e)
441
442
  return;
442
- let s = o - t - 1;
443
- s = s < 0 ? 0 : s;
444
- const a = n - t, c = j(
443
+ let i = o - t - 1;
444
+ i = i < 0 ? 0 : i;
445
+ const a = n - t, c = P(
445
446
  e,
446
- s,
447
+ i,
447
448
  "left",
448
449
  V
449
- ), f = j(
450
+ ), p = P(
450
451
  e,
451
452
  a,
452
453
  "right",
453
454
  V
454
- ), y = e.slice(c.from, f.to);
455
- wt(y, Ue, kt).forEach((D) => {
456
- const C = xt(D[0]), S = t + c.from + D.index + 1, Y = S + C.length;
457
- r.addMark(S, Y, i.create());
455
+ ), y = e.slice(c.from, p.to);
456
+ wt(y, qe, Ct).forEach((D) => {
457
+ const x = bt(D[0]), L = t + c.from + D.index + 1, Y = L + x.length;
458
+ r.addMark(L, Y, s.create());
458
459
  });
459
460
  }
460
- function Tt(e) {
461
+ function Et(e) {
461
462
  let t = !1;
462
- return new ve({
463
+ return new Re({
463
464
  key: new T("autolink"),
464
465
  appendTransaction: (o, n, r) => {
465
- const i = o.some((y) => y.docChanged) && !n.doc.eq(r.doc);
466
- if (t && !i)
466
+ const s = o.some((y) => y.docChanged) && !n.doc.eq(r.doc);
467
+ if (t && !s)
467
468
  return;
468
- const { tr: s } = r, { textContent: a } = r.doc;
469
- t || U(a, 0, 0, a.length, s, e.type), t = !0;
469
+ const { tr: i } = r, { textContent: a } = r.doc;
470
+ t || q(a, 0, 0, a.length, i, e.type), t = !0;
470
471
  const c = oe(
471
472
  n.doc,
472
473
  [...o]
473
474
  );
474
- return re(c).forEach(({ oldRange: y, newRange: E }) => {
475
- Ct(E, r.doc, s, e.type), ie(
475
+ return re(c).forEach(({ oldRange: y, newRange: S }) => {
476
+ Tt(S, r.doc, i, e.type), se(
476
477
  r.doc,
477
- E,
478
- (C) => C.isTextblock
479
- ).forEach(({ node: C, pos: S }) => {
480
- U(
481
- C.textContent,
482
- S,
478
+ S,
479
+ (x) => x.isTextblock
480
+ ).forEach(({ node: x, pos: L }) => {
481
+ q(
482
+ x.textContent,
483
+ L,
483
484
  y.from,
484
- E.to,
485
- s,
485
+ S.to,
486
+ i,
486
487
  e.type
487
488
  );
488
489
  });
489
- }), s;
490
+ }), i;
490
491
  }
491
492
  });
492
493
  }
493
- const Et = {
494
+ const St = {
494
495
  class: "d-link d-c-text d-d-inline-block d-wb-break-all",
495
496
  rel: "noopener noreferrer nofollow"
496
- }, St = se.create({
497
+ }, Lt = ie.create({
497
498
  name: "CustomLink",
498
499
  renderHTML({ HTMLAttributes: e }) {
499
500
  return [
@@ -501,7 +502,7 @@ const Et = {
501
502
  b(
502
503
  this.options.HTMLAttributes,
503
504
  e,
504
- Et
505
+ St
505
506
  )
506
507
  ];
507
508
  },
@@ -510,10 +511,10 @@ const Et = {
510
511
  },
511
512
  addProseMirrorPlugins() {
512
513
  return [
513
- Tt({ type: this.type })
514
+ Et({ type: this.type })
514
515
  ];
515
516
  }
516
- }), Lt = qe.extend({
517
+ }), $t = We.extend({
517
518
  name: "ConfigurableImage",
518
519
  addAttributes() {
519
520
  return {
@@ -537,7 +538,7 @@ const Et = {
537
538
  }
538
539
  };
539
540
  }
540
- }).configure({ inline: !0, allowBase64: !0 }), Rt = W.extend({
541
+ }).configure({ inline: !0, allowBase64: !0 }), Rt = U.extend({
541
542
  parseHTML() {
542
543
  return [{ tag: "div" }];
543
544
  },
@@ -551,20 +552,20 @@ const Et = {
551
552
  NodeViewWrapper: R,
552
553
  DtLink: J
553
554
  },
554
- props: L,
555
+ props: $,
555
556
  computed: {
556
557
  text() {
557
558
  return "@" + this.$props.node.attrs.name;
558
559
  }
559
560
  }
560
561
  };
561
- function Ot(e, t, o, n, r, i) {
562
- const s = d("dt-link"), a = d("node-view-wrapper");
563
- return l(), h(a, { class: "d-d-inline-block" }, {
562
+ function It(e, t, o, n, r, s) {
563
+ const i = l("dt-link"), a = l("node-view-wrapper");
564
+ return d(), m(a, { class: "d-d-inline-block" }, {
564
565
  default: u(() => [
565
- p(s, { kind: "mention" }, {
566
+ f(i, { kind: "mention" }, {
566
567
  default: u(() => [
567
- k(m(i.text), 1)
568
+ C(h(s.text), 1)
568
569
  ]),
569
570
  _: 1
570
571
  })
@@ -572,9 +573,9 @@ function Ot(e, t, o, n, r, i) {
572
573
  _: 1
573
574
  });
574
575
  }
575
- const It = /* @__PURE__ */ g(vt, [["render", Ot]]), Bt = N.extend({
576
+ const Mt = /* @__PURE__ */ g(vt, [["render", It]]), Bt = H.extend({
576
577
  addNodeView() {
577
- return O(It);
578
+ return I(Mt);
578
579
  },
579
580
  parseHTML() {
580
581
  return [
@@ -593,6 +594,9 @@ const It = /* @__PURE__ */ g(vt, [["render", Ot]]), Bt = N.extend({
593
594
  },
594
595
  id: {
595
596
  default: ""
597
+ },
598
+ contactKey: {
599
+ default: ""
596
600
  }
597
601
  };
598
602
  },
@@ -607,27 +611,41 @@ const It = /* @__PURE__ */ g(vt, [["render", Ot]]), Bt = N.extend({
607
611
  char: "@",
608
612
  pluginKey: new T("mentionSuggestion")
609
613
  }
610
- }), Mt = {
614
+ }), Nt = {
611
615
  compatConfig: { MODE: 3 },
612
616
  name: "ChannelComponent",
613
617
  components: {
614
618
  NodeViewWrapper: R,
615
- DtLink: J
619
+ DtLink: J,
620
+ DtIconLock: ze,
621
+ DtStack: E
616
622
  },
617
- props: L,
623
+ props: $,
618
624
  computed: {
619
625
  text() {
620
- return "#" + this.$props.node.attrs.name;
626
+ return this.$props.node.attrs.locked ? this.$props.node.attrs.name : "#" + this.$props.node.attrs.name;
621
627
  }
622
628
  }
623
629
  };
624
- function $t(e, t, o, n, r, i) {
625
- const s = d("dt-link"), a = d("node-view-wrapper");
626
- return l(), h(a, { class: "d-d-inline-block" }, {
630
+ function Ot(e, t, o, n, r, s) {
631
+ const i = l("dt-icon-lock"), a = l("dt-stack"), c = l("dt-link"), p = l("node-view-wrapper");
632
+ return d(), m(p, { class: "d-d-inline-block" }, {
627
633
  default: u(() => [
628
- p(s, { kind: "mention" }, {
634
+ f(c, { kind: "mention" }, {
629
635
  default: u(() => [
630
- k(m(i.text), 1)
636
+ f(a, {
637
+ direction: "row",
638
+ gap: "0"
639
+ }, {
640
+ default: u(() => [
641
+ e.$props.node.attrs.locked ? (d(), m(i, {
642
+ key: 0,
643
+ size: "200"
644
+ })) : w("", !0),
645
+ k("span", null, h(s.text), 1)
646
+ ]),
647
+ _: 1
648
+ })
631
649
  ]),
632
650
  _: 1
633
651
  })
@@ -635,10 +653,10 @@ function $t(e, t, o, n, r, i) {
635
653
  _: 1
636
654
  });
637
655
  }
638
- const At = /* @__PURE__ */ g(Mt, [["render", $t]]), Dt = N.extend({
656
+ const Dt = /* @__PURE__ */ g(Nt, [["render", Ot]]), At = H.extend({
639
657
  name: "channel",
640
658
  addNodeView() {
641
- return O(At);
659
+ return I(Dt);
642
660
  },
643
661
  parseHTML() {
644
662
  return [
@@ -678,7 +696,7 @@ const At = /* @__PURE__ */ g(Mt, [["render", $t]]), Dt = N.extend({
678
696
  NodeViewWrapper: R
679
697
  },
680
698
  props: {
681
- ...L
699
+ ...$
682
700
  },
683
701
  emits: ["selected-command"],
684
702
  computed: {
@@ -694,23 +712,23 @@ const At = /* @__PURE__ */ g(Mt, [["render", $t]]), Dt = N.extend({
694
712
  t && typeof t == "function" && t(e);
695
713
  }
696
714
  };
697
- function jt(e, t, o, n, r, i) {
698
- const s = d("node-view-wrapper");
699
- return l(), h(s, { class: "d-d-inline-block" }, {
715
+ function jt(e, t, o, n, r, s) {
716
+ const i = l("node-view-wrapper");
717
+ return d(), m(i, { class: "d-d-inline-block" }, {
700
718
  default: u(() => [
701
- k(m(i.text), 1)
719
+ C(h(s.text), 1)
702
720
  ]),
703
721
  _: 1
704
722
  });
705
723
  }
706
- const Ht = /* @__PURE__ */ g(Pt, [["render", jt]]), Nt = (e, t) => [...e.matchAll(t)].map((n) => {
724
+ const Ht = /* @__PURE__ */ g(Pt, [["render", jt]]), Kt = (e, t) => [...e.matchAll(t)].map((n) => {
707
725
  let r = n[2];
708
726
  return r.endsWith(" ") || (r += " "), {
709
727
  index: n.index,
710
728
  text: r,
711
729
  match: n
712
730
  };
713
- }), Ft = N.extend({
731
+ }), Ft = H.extend({
714
732
  name: "slash-commands",
715
733
  group: "inline",
716
734
  inline: !0,
@@ -727,7 +745,7 @@ const Ht = /* @__PURE__ */ g(Pt, [["render", jt]]), Nt = (e, t) => [...e.matchAl
727
745
  };
728
746
  },
729
747
  addNodeView() {
730
- return O(Ht);
748
+ return I(Ht);
731
749
  },
732
750
  parseHTML() {
733
751
  return [
@@ -772,8 +790,8 @@ const Ht = /* @__PURE__ */ g(Pt, [["render", jt]]), Nt = (e, t) => [...e.matchAl
772
790
  var o;
773
791
  const e = (o = this.options.suggestion) == null ? void 0 : o.items({ query: "" }).map((n) => n.command), t = new RegExp(`^((?:\\/)(${e.join("|")})) ?$`, "g");
774
792
  return [
775
- P({
776
- find: (n) => Nt(n, t),
793
+ A({
794
+ find: (n) => Kt(n, t),
777
795
  type: this.type,
778
796
  getAttributes(n) {
779
797
  return { command: n[0].trim() };
@@ -786,12 +804,12 @@ const Ht = /* @__PURE__ */ g(Pt, [["render", jt]]), Nt = (e, t) => [...e.matchAl
786
804
  char: "/",
787
805
  pluginKey: new T("slashCommandSuggestion")
788
806
  }
789
- }), Kt = {
807
+ }), Vt = {
790
808
  compatConfig: { MODE: 3 },
791
809
  name: "MentionSuggestion",
792
810
  components: {
793
- DtAvatar: Je,
794
- DtStack: B
811
+ DtAvatar: Ye,
812
+ DtStack: E
795
813
  },
796
814
  props: {
797
815
  item: {
@@ -827,51 +845,51 @@ const Ht = /* @__PURE__ */ g(Pt, [["render", jt]]), Nt = (e, t) => [...e.matchAl
827
845
  return this.item.showDetails;
828
846
  }
829
847
  }
830
- }, Vt = { class: "d-mention-suggestion__name" }, Ut = {
848
+ }, qt = { class: "d-mention-suggestion__name" }, Ut = {
831
849
  key: 1,
832
850
  class: "d-mention-suggestion__divider"
833
851
  }, Wt = {
834
852
  key: 2,
835
853
  class: "d-mention-suggestion__status"
836
854
  };
837
- function qt(e, t, o, n, r, i) {
838
- const s = d("dt-avatar"), a = d("dt-stack");
839
- return l(), h(a, {
855
+ function zt(e, t, o, n, r, s) {
856
+ const i = l("dt-avatar"), a = l("dt-stack");
857
+ return d(), m(a, {
840
858
  direction: "row",
841
859
  class: "d-mention-suggestion__container",
842
860
  gap: "400"
843
861
  }, {
844
862
  default: u(() => [
845
- p(s, {
846
- "full-name": i.name,
847
- "image-src": i.avatarSrc,
848
- "image-alt": i.name,
849
- "show-presence": i.showDetails,
850
- presence: i.presence,
863
+ f(i, {
864
+ "full-name": s.name,
865
+ "image-src": s.avatarSrc,
866
+ "image-alt": s.name,
867
+ "show-presence": s.showDetails,
868
+ presence: s.presence,
851
869
  size: "sm"
852
870
  }, null, 8, ["full-name", "image-src", "image-alt", "show-presence", "presence"]),
853
- p(a, {
871
+ f(a, {
854
872
  class: "d-mention-suggestion__details-container",
855
873
  gap: "100"
856
874
  }, {
857
875
  default: u(() => [
858
- w("span", Vt, m(i.name), 1),
859
- i.showDetails ? (l(), h(a, {
876
+ k("span", qt, h(s.name), 1),
877
+ s.showDetails ? (d(), m(a, {
860
878
  key: 0,
861
879
  direction: "row",
862
880
  gap: "300",
863
881
  class: "d-label--sm-plain"
864
882
  }, {
865
883
  default: u(() => [
866
- i.presenceText ? (l(), _("span", {
884
+ s.presenceText ? (d(), _("span", {
867
885
  key: 0,
868
- class: z(["d-mention-suggestion__presence", [i.presenceFontColorClass]])
869
- }, m(i.presenceText), 3)) : x("", !0),
870
- i.status && i.presenceText ? (l(), _("div", Ut, " • ")) : x("", !0),
871
- i.status ? (l(), _("div", Wt, m(i.status), 1)) : x("", !0)
886
+ class: z(["d-mention-suggestion__presence", [s.presenceFontColorClass]])
887
+ }, h(s.presenceText), 3)) : w("", !0),
888
+ s.status && s.presenceText ? (d(), _("div", Ut, " • ")) : w("", !0),
889
+ s.status ? (d(), _("div", Wt, h(s.status), 1)) : w("", !0)
872
890
  ]),
873
891
  _: 1
874
- })) : x("", !0)
892
+ })) : w("", !0)
875
893
  ]),
876
894
  _: 1
877
895
  })
@@ -879,7 +897,7 @@ function qt(e, t, o, n, r, i) {
879
897
  _: 1
880
898
  });
881
899
  }
882
- const zt = /* @__PURE__ */ g(Kt, [["render", qt]]), Xt = {
900
+ const Xt = /* @__PURE__ */ g(Vt, [["render", zt]]), Jt = {
883
901
  // This function comes from the user and passed to the editor directly.
884
902
  // This will also activate the mention plugin on the editor
885
903
  // items: ({ query }) => { return [] },
@@ -888,14 +906,14 @@ const zt = /* @__PURE__ */ g(Kt, [["render", qt]]), Xt = {
888
906
  let e, t, o = !1;
889
907
  return {
890
908
  onStart: (n) => {
891
- e = new v($, {
909
+ e = new v(N, {
892
910
  props: {
893
- itemComponent: I(zt),
911
+ itemComponent: M(Xt),
894
912
  itemType: "mention",
895
913
  ...n
896
914
  },
897
915
  editor: n.editor
898
- }), n.clientRect && (t = M("body", {
916
+ }), n.clientRect && (t = B("body", {
899
917
  getReferenceClientRect: n.clientRect,
900
918
  appendTo: () => document.body,
901
919
  content: e.element,
@@ -910,7 +928,7 @@ const zt = /* @__PURE__ */ g(Kt, [["render", qt]]), Xt = {
910
928
  trigger: "manual",
911
929
  placement: "top-start",
912
930
  zIndex: 650,
913
- plugins: [A]
931
+ plugins: [O]
914
932
  }), n.items.length > 0 && (t == null || t[0].show()));
915
933
  },
916
934
  onUpdate(n) {
@@ -928,13 +946,13 @@ const zt = /* @__PURE__ */ g(Kt, [["render", qt]]), Xt = {
928
946
  }
929
947
  };
930
948
  }
931
- }, Jt = {
949
+ }, Yt = {
932
950
  compatConfig: { MODE: 3 },
933
951
  name: "ChannelSuggestion",
934
952
  components: {
935
- DtStack: B,
936
- DtIconHash: Ye,
937
- DtIconLock: Ge
953
+ DtStack: E,
954
+ DtIconHash: Ge,
955
+ DtIconLock: Qe
938
956
  },
939
957
  props: {
940
958
  item: {
@@ -948,26 +966,26 @@ const zt = /* @__PURE__ */ g(Kt, [["render", qt]]), Xt = {
948
966
  }
949
967
  }
950
968
  };
951
- function Yt(e, t, o, n, r, i) {
952
- const s = d("dt-icon-hash"), a = d("dt-icon-lock"), c = d("dt-stack");
953
- return l(), h(c, {
969
+ function Gt(e, t, o, n, r, s) {
970
+ const i = l("dt-icon-hash"), a = l("dt-icon-lock"), c = l("dt-stack");
971
+ return d(), m(c, {
954
972
  direction: "row",
955
973
  gap: "400"
956
974
  }, {
957
975
  default: u(() => [
958
- o.item.locked ? (l(), h(a, {
976
+ o.item.locked ? (d(), m(a, {
959
977
  key: 1,
960
978
  size: "300"
961
- })) : (l(), h(s, {
979
+ })) : (d(), m(i, {
962
980
  key: 0,
963
981
  size: "300"
964
982
  })),
965
- w("span", null, m(i.name), 1)
983
+ k("span", null, h(s.name), 1)
966
984
  ]),
967
985
  _: 1
968
986
  });
969
987
  }
970
- const Gt = /* @__PURE__ */ g(Jt, [["render", Yt]]), Qt = {
988
+ const Qt = /* @__PURE__ */ g(Yt, [["render", Gt]]), Zt = {
971
989
  // This function comes from the user and passed to the editor directly.
972
990
  // This will also activate the mention plugin on the editor
973
991
  // items: ({ query }) => { return [] },
@@ -976,14 +994,14 @@ const Gt = /* @__PURE__ */ g(Jt, [["render", Yt]]), Qt = {
976
994
  let e, t, o = !1;
977
995
  return {
978
996
  onStart: (n) => {
979
- e = new v($, {
997
+ e = new v(N, {
980
998
  props: {
981
- itemComponent: I(Gt),
999
+ itemComponent: M(Qt),
982
1000
  itemType: "channel",
983
1001
  ...n
984
1002
  },
985
1003
  editor: n.editor
986
- }), n.clientRect && (t = M("body", {
1004
+ }), n.clientRect && (t = B("body", {
987
1005
  getReferenceClientRect: n.clientRect,
988
1006
  appendTo: () => document.body,
989
1007
  content: e.element,
@@ -998,7 +1016,7 @@ const Gt = /* @__PURE__ */ g(Jt, [["render", Yt]]), Qt = {
998
1016
  trigger: "manual",
999
1017
  placement: "top-start",
1000
1018
  zIndex: 650,
1001
- plugins: [A]
1019
+ plugins: [O]
1002
1020
  }), n.items.length > 0 && (t == null || t[0].show()));
1003
1021
  },
1004
1022
  onUpdate(n) {
@@ -1016,7 +1034,7 @@ const Gt = /* @__PURE__ */ g(Jt, [["render", Yt]]), Qt = {
1016
1034
  }
1017
1035
  };
1018
1036
  }
1019
- }, Zt = {
1037
+ }, en = {
1020
1038
  compatConfig: { MODE: 3 },
1021
1039
  name: "SlashCommandSuggestion",
1022
1040
  props: {
@@ -1036,17 +1054,17 @@ const Gt = /* @__PURE__ */ g(Jt, [["render", Yt]]), Qt = {
1036
1054
  return this.item.parametersExample;
1037
1055
  }
1038
1056
  }
1039
- }, en = { class: "d-body--md-compact" }, tn = { key: 0 }, nn = { class: "d-body--sm d-fc-tertiary" };
1040
- function on(e, t, o, n, r, i) {
1041
- return l(), _("div", null, [
1042
- w("div", en, [
1043
- w("span", null, "/" + m(i.command), 1),
1044
- i.parametersExample ? (l(), _("span", tn, m(i.parametersExample), 1)) : x("", !0)
1057
+ }, tn = { class: "d-body--md-compact" }, nn = { key: 0 }, on = { class: "d-body--sm d-fc-tertiary" };
1058
+ function rn(e, t, o, n, r, s) {
1059
+ return d(), _("div", null, [
1060
+ k("div", tn, [
1061
+ k("span", null, "/" + h(s.command), 1),
1062
+ s.parametersExample ? (d(), _("span", nn, h(s.parametersExample), 1)) : w("", !0)
1045
1063
  ]),
1046
- w("div", nn, m(i.description), 1)
1064
+ k("div", on, h(s.description), 1)
1047
1065
  ]);
1048
1066
  }
1049
- const rn = /* @__PURE__ */ g(Zt, [["render", on]]), sn = {
1067
+ const sn = /* @__PURE__ */ g(en, [["render", rn]]), an = {
1050
1068
  // This function comes from the user and passed to the editor directly.
1051
1069
  // This will also activate the mention plugin on the editor
1052
1070
  // items: ({ query }) => { return [] },
@@ -1056,15 +1074,15 @@ const rn = /* @__PURE__ */ g(Zt, [["render", on]]), sn = {
1056
1074
  let e, t, o = !1;
1057
1075
  return {
1058
1076
  onStart: (n) => {
1059
- e = new v($, {
1077
+ e = new v(N, {
1060
1078
  parent: void 0,
1061
1079
  props: {
1062
- itemComponent: I(rn),
1080
+ itemComponent: M(sn),
1063
1081
  itemType: "slash-command",
1064
1082
  ...n
1065
1083
  },
1066
1084
  editor: n.editor
1067
- }), n.clientRect && (t = M("body", {
1085
+ }), n.clientRect && (t = B("body", {
1068
1086
  getReferenceClientRect: n.clientRect,
1069
1087
  appendTo: () => document.body,
1070
1088
  content: e.element,
@@ -1079,7 +1097,7 @@ const rn = /* @__PURE__ */ g(Zt, [["render", on]]), sn = {
1079
1097
  trigger: "manual",
1080
1098
  placement: "top-start",
1081
1099
  zIndex: 650,
1082
- plugins: [A]
1100
+ plugins: [O]
1083
1101
  }), n.items.length > 0 && (t == null || t[0].show()));
1084
1102
  },
1085
1103
  onUpdate(n) {
@@ -1097,14 +1115,14 @@ const rn = /* @__PURE__ */ g(Zt, [["render", on]]), sn = {
1097
1115
  }
1098
1116
  };
1099
1117
  }
1100
- }, an = {
1118
+ }, cn = {
1101
1119
  compatConfig: { MODE: 3 },
1102
1120
  name: "DtRichTextEditor",
1103
1121
  components: {
1104
1122
  EditorContent: Q,
1105
1123
  BubbleMenu: G,
1106
- DtButton: et,
1107
- DtStack: B
1124
+ DtButton: tt,
1125
+ DtStack: E
1108
1126
  },
1109
1127
  props: {
1110
1128
  /**
@@ -1176,20 +1194,20 @@ const rn = /* @__PURE__ */ g(Zt, [["render", on]]), sn = {
1176
1194
  type: [Boolean, String, Number],
1177
1195
  default: !1,
1178
1196
  validator(e) {
1179
- return typeof e == "string" ? Xe.includes(e) : !0;
1197
+ return typeof e == "string" ? Je.includes(e) : !0;
1180
1198
  }
1181
1199
  },
1182
1200
  /**
1183
1201
  * The output format that the editor uses when emitting the "@input" event.
1184
- * One of `text`, `json`, `html`. See https://tiptap.dev/guide/output for
1202
+ * One of `text`, `json`, `html`, `markdown`. See https://tiptap.dev/guide/output for
1185
1203
  * examples.
1186
- * @values text, json, html
1204
+ * @values text, json, html, markdown
1187
1205
  */
1188
1206
  outputFormat: {
1189
1207
  type: String,
1190
1208
  default: "html",
1191
1209
  validator(e) {
1192
- return ze.includes(e);
1210
+ return Xe.includes(e);
1193
1211
  }
1194
1212
  },
1195
1213
  /**
@@ -1397,6 +1415,12 @@ const rn = /* @__PURE__ */ g(Zt, [["render", on]]), sn = {
1397
1415
  * @type {String}
1398
1416
  */
1399
1417
  "text-input",
1418
+ /**
1419
+ * Input event always in markdown format.
1420
+ * @event input
1421
+ * @type {String}
1422
+ */
1423
+ "markdown-input",
1400
1424
  /**
1401
1425
  * Event to sync the value with the parent
1402
1426
  * @event update:value
@@ -1448,11 +1472,128 @@ const rn = /* @__PURE__ */ g(Zt, [["render", on]]), sn = {
1448
1472
  tippyOptions: {
1449
1473
  appendTo: () => {
1450
1474
  var e;
1451
- return (e = F(this.$refs.editor.$el).getRootNode()) == null ? void 0 : e.querySelector("body");
1475
+ return (e = K(this.$refs.editor.$el).getRootNode()) == null ? void 0 : e.querySelector("body");
1452
1476
  },
1453
1477
  placement: "top-start"
1454
1478
  },
1455
- i18n: new Ze()
1479
+ i18n: new et(),
1480
+ // JSON-to-markdown converter
1481
+ jsonToMarkdownConverter: {
1482
+ convertToMarkdown(e) {
1483
+ return this.processNode(e);
1484
+ },
1485
+ processNodeContent(e) {
1486
+ return e.content ? e.content.map((t) => this.processNode(t)).join("") : "";
1487
+ },
1488
+ processNode(e) {
1489
+ if (!e) return "";
1490
+ const o = {
1491
+ doc: (n) => this.processDocNode(n),
1492
+ paragraph: (n) => this.processParagraphNode(n),
1493
+ text: (n) => this.processTextNode(n),
1494
+ hardBreak: () => this.processHardBreakNode(),
1495
+ blockquote: (n) => this.processBlockquoteNode(n),
1496
+ bulletList: (n) => this.processBulletListNode(n),
1497
+ orderedList: (n) => this.processOrderedListNode(n),
1498
+ listItem: (n) => this.processListItemNode(n),
1499
+ codeBlock: (n) => this.processCodeBlockNode(n),
1500
+ mention: (n) => this.processMentionNode(n),
1501
+ channel: (n) => this.processChannelNode(n),
1502
+ "slash-commands": (n) => this.processSlashCommandsNode(n),
1503
+ emoji: (n) => this.processEmojiNode(n)
1504
+ }[e.type];
1505
+ return o ? o(e) : this.processUnknownNode(e);
1506
+ },
1507
+ processDocNode(e) {
1508
+ return this.processNodeContent(e);
1509
+ },
1510
+ processParagraphNode(e) {
1511
+ const t = this.processNodeContent(e);
1512
+ return t ? t + `
1513
+ ` : `
1514
+ `;
1515
+ },
1516
+ processTextNode(e) {
1517
+ let t = e.text || "";
1518
+ return e.marks && (t = this.applyMarks(t, e.marks)), t;
1519
+ },
1520
+ processHardBreakNode() {
1521
+ return `
1522
+ `;
1523
+ },
1524
+ processBlockquoteNode(e) {
1525
+ return this.processNodeContent(e).split(`
1526
+ `).map((o) => o ? `> ${o}` : ">").join(`
1527
+ `) + `
1528
+ `;
1529
+ },
1530
+ processBulletListNode(e) {
1531
+ return this.processNodeContent(e);
1532
+ },
1533
+ processOrderedListNode(e) {
1534
+ return e.content ? e.content.map((t, o) => this.processNode(t).replace(/^- /, `${o + 1}. `)).join("") : "";
1535
+ },
1536
+ processListItemNode(e) {
1537
+ const t = this.processNodeContent(e);
1538
+ return t ? `- ${t.replace(/\n$/, "")}
1539
+ ` : "";
1540
+ },
1541
+ processCodeBlockNode(e) {
1542
+ return `\`\`\`
1543
+ ${this.processNodeContent(e)}
1544
+ \`\`\``;
1545
+ },
1546
+ processMentionNode(e) {
1547
+ var r, s, i;
1548
+ const t = ((r = e.attrs) == null ? void 0 : r.name) || "", o = ((s = e.attrs) == null ? void 0 : s.id) || "", n = ((i = e.attrs) == null ? void 0 : i.contactKey) || "";
1549
+ return `<!-- @mention: {"id": "${o}", "contactKey": "${n}", "name": "${t}"} -->`;
1550
+ },
1551
+ processChannelNode(e) {
1552
+ var r, s, i;
1553
+ const t = ((r = e.attrs) == null ? void 0 : r.name) || "", o = ((s = e.attrs) == null ? void 0 : s.id) || "", n = ((i = e.attrs) == null ? void 0 : i.locked.toString()) || "";
1554
+ return `<!-- @channel: {"id": "${o}", "name": "${t}", "locked": "${n}"} -->`;
1555
+ },
1556
+ processSlashCommandsNode(e) {
1557
+ var n, r;
1558
+ const t = ((n = e.attrs) == null ? void 0 : n.command) || "", o = ((r = e.attrs) == null ? void 0 : r.parameters) || "";
1559
+ return `/${t}${o ? ` ${o}` : ""}`;
1560
+ },
1561
+ processEmojiNode(e) {
1562
+ var t;
1563
+ return ((t = e.attrs) == null ? void 0 : t.code) || "";
1564
+ },
1565
+ processUnknownNode(e) {
1566
+ return this.processNodeContent(e);
1567
+ },
1568
+ applyMarks(e, t) {
1569
+ let o = e;
1570
+ return [...t].sort((r, s) => {
1571
+ const i = { link: 0, bold: 1, italic: 2, strike: 3, code: 4 };
1572
+ return (i[r.type] || 5) - (i[s.type] || 5);
1573
+ }).forEach((r) => {
1574
+ var s;
1575
+ switch (r.type) {
1576
+ case "bold":
1577
+ o = `**${o}**`;
1578
+ break;
1579
+ case "italic":
1580
+ o = `*${o}*`;
1581
+ break;
1582
+ case "strike":
1583
+ o = `~~${o}~~`;
1584
+ break;
1585
+ case "code":
1586
+ o = `\`${o}\``;
1587
+ break;
1588
+ case "link": {
1589
+ const i = ((s = r.attrs) == null ? void 0 : s.href) || "";
1590
+ o = `[${o}](${i})`;
1591
+ break;
1592
+ }
1593
+ }
1594
+ }), o;
1595
+ }
1596
+ }
1456
1597
  };
1457
1598
  },
1458
1599
  computed: {
@@ -1469,15 +1610,15 @@ const rn = /* @__PURE__ */ g(Zt, [["render", on]]), sn = {
1469
1610
  },
1470
1611
  // eslint-disable-next-line complexity
1471
1612
  extensions() {
1472
- const e = [me, Ce, Ee, he];
1473
- e.push(this.useDivTags ? Rt : W), this.allowBold && e.push(pe), this.allowBlockquote && e.push(ce), this.allowBulletList && (e.push(ge), e.push(we.extend({
1613
+ const e = [me, xe, Ee, he];
1614
+ e.push(this.useDivTags ? Rt : U), this.allowBold && e.push(fe), this.allowBlockquote && e.push(de), this.allowBulletList && (e.push(ge), e.push(ye.extend({
1474
1615
  renderText({ node: n }) {
1475
1616
  return n.textContent;
1476
1617
  }
1477
- })), e.push(ke)), this.allowItalic && e.push(_e), this.allowStrike && e.push(xe), this.allowUnderline && e.push(be), this.placeholder && e.push(
1478
- fe.configure({ placeholder: this.placeholder })
1618
+ })), e.push(we)), this.allowItalic && e.push(_e), this.allowStrike && e.push(Ce), this.allowUnderline && e.push(be), this.placeholder && e.push(
1619
+ pe.configure({ placeholder: this.placeholder })
1479
1620
  );
1480
- const t = this, o = le.create({
1621
+ const t = this, o = ce.create({
1481
1622
  addKeyboardShortcuts() {
1482
1623
  return {
1483
1624
  "Shift-Enter": ({ editor: n }) => t.allowLineBreaks ? !1 : (n.commands.first(({ commands: r }) => [
@@ -1491,7 +1632,7 @@ const rn = /* @__PURE__ */ g(Zt, [["render", on]]), sn = {
1491
1632
  };
1492
1633
  }
1493
1634
  });
1494
- if (e.push(o), this.link && e.push(ye.extend({
1635
+ if (e.push(o), this.link && e.push(ke.extend({
1495
1636
  inclusive: !1,
1496
1637
  addKeyboardShortcuts() {
1497
1638
  return {
@@ -1504,17 +1645,17 @@ const rn = /* @__PURE__ */ g(Zt, [["render", on]]), sn = {
1504
1645
  },
1505
1646
  openOnClick: !1,
1506
1647
  autolink: !0,
1507
- protocols: K
1508
- })), this.customLink && e.push(this.getExtension(St, this.customLink)), this.mentionSuggestion) {
1509
- const n = { ...this.mentionSuggestion, ...Xt };
1648
+ protocols: F
1649
+ })), this.customLink && e.push(this.getExtension(Lt, this.customLink)), this.mentionSuggestion) {
1650
+ const n = { ...this.mentionSuggestion, ...Jt };
1510
1651
  e.push(Bt.configure({ suggestion: n }));
1511
1652
  }
1512
1653
  if (this.channelSuggestion) {
1513
- const n = { ...this.channelSuggestion, ...Qt };
1514
- e.push(Dt.configure({ suggestion: n }));
1654
+ const n = { ...this.channelSuggestion, ...Zt };
1655
+ e.push(At.configure({ suggestion: n }));
1515
1656
  }
1516
1657
  if (this.slashCommandSuggestion) {
1517
- const n = { ...this.slashCommandSuggestion, ...sn };
1658
+ const n = { ...this.slashCommandSuggestion, ...an };
1518
1659
  e.push(Ft.configure({
1519
1660
  suggestion: n,
1520
1661
  onSelectedCommand: (r) => {
@@ -1524,7 +1665,7 @@ const rn = /* @__PURE__ */ g(Zt, [["render", on]]), sn = {
1524
1665
  }
1525
1666
  return e.push(yt), e.push(Te.configure({
1526
1667
  types: ["paragraph"]
1527
- })), this.allowCode && e.push(ue), this.allowCodeblock && e.push(de.extend({
1668
+ })), this.allowCode && e.push(ue), this.allowCodeblock && e.push(le.extend({
1528
1669
  renderText({ node: n }) {
1529
1670
  return `\`\`\`
1530
1671
  ${n.textContent}
@@ -1534,7 +1675,7 @@ ${n.textContent}
1534
1675
  HTMLAttributes: {
1535
1676
  class: "d-rich-text-editor__code-block"
1536
1677
  }
1537
- })), this.allowInlineImages && e.push(Lt), (this.allowFontFamily || this.allowFontColor) && (e.push(Se), this.allowFontColor && e.push(Le), this.allowFontFamily && e.push(Re)), this.additionalExtensions.length && e.push(...this.additionalExtensions), e;
1678
+ })), this.allowInlineImages && e.push($t), (this.allowFontFamily || this.allowFontColor) && (e.push(Se), this.allowFontColor && e.push(Le), this.allowFontFamily && e.push($e)), this.additionalExtensions.length && e.push(...this.additionalExtensions), e;
1538
1679
  },
1539
1680
  inputAttrs() {
1540
1681
  const e = {
@@ -1574,7 +1715,7 @@ ${n.textContent}
1574
1715
  this.destroyEditor();
1575
1716
  },
1576
1717
  mounted() {
1577
- We(F(this.$el), this.$options.name), this.processValue(this.modelValue, !1);
1718
+ Ue(K(this.$el), this.$options.name), this.processValue(this.modelValue, !1);
1578
1719
  },
1579
1720
  methods: {
1580
1721
  createEditor() {
@@ -1617,9 +1758,9 @@ ${n.textContent}
1617
1758
  * @param editor the editor instance.
1618
1759
  */
1619
1760
  getSelectedLinkText(e) {
1620
- var a, c, f;
1621
- const { view: t, state: o } = e, { from: n, to: r } = t.state.selection, i = o.doc.textBetween(n, r, ""), s = this.editor.state.doc.nodeAt(n);
1622
- return s && ((f = (c = (a = s.marks) == null ? void 0 : a.at(0)) == null ? void 0 : c.type) == null ? void 0 : f.name) === "link" ? s.textContent : i;
1761
+ var a, c, p;
1762
+ const { view: t, state: o } = e, { from: n, to: r } = t.state.selection, s = o.doc.textBetween(n, r, ""), i = this.editor.state.doc.nodeAt(n);
1763
+ return i && ((p = (c = (a = i.marks) == null ? void 0 : a.at(0)) == null ? void 0 : c.type) == null ? void 0 : p.name) === "link" ? i.textContent : s;
1623
1764
  },
1624
1765
  editLink() {
1625
1766
  const e = this.getSelectedLinkText(this.editor), t = {
@@ -1638,23 +1779,21 @@ ${n.textContent}
1638
1779
  const e = this.editor.getAttributes("link").href;
1639
1780
  window.open(e, "_blank");
1640
1781
  },
1641
- // eslint-disable-next-line complexity
1642
- setLink(e, t, o, n = K, r) {
1643
- var a, c, f;
1782
+ setLink(e, t, o, n = F, r) {
1783
+ var a, c, p;
1644
1784
  if (!e) {
1645
1785
  this.removeLink();
1646
1786
  return;
1647
1787
  }
1648
1788
  n.find((y) => y.test(e)) || (e = `${r}${e}`), this.editor.chain().focus().extendMarkRange("link").run();
1649
- const s = (f = (c = (a = this.editor) == null ? void 0 : a.view) == null ? void 0 : c.state) == null ? void 0 : f.selection;
1650
- this.editor.chain().focus().insertContent(t).setTextSelection({ from: s.from, to: s.from + t.length }).setLink({ href: e, class: o.class }).run();
1789
+ const i = (p = (c = (a = this.editor) == null ? void 0 : a.view) == null ? void 0 : c.state) == null ? void 0 : p.selection;
1790
+ this.editor.chain().focus().insertContent(t).setTextSelection({ from: i.from, to: i.from + t.length }).setLink({ href: e, class: o.class }).run();
1651
1791
  },
1652
- // eslint-disable-next-line complexity
1653
1792
  processValue(e, t = !0) {
1654
1793
  const o = this.getOutput();
1655
- if (!(t && Qe(e, o))) {
1794
+ if (!(t && Ze(e, o))) {
1656
1795
  if (typeof e == "string" && this.outputFormat === "text") {
1657
- const n = new RegExp(`(${q})`, "g");
1796
+ const n = new RegExp(`(${W})`, "g");
1658
1797
  e = e == null ? void 0 : e.replace(n, '<emoji-component code="$1"></emoji-component>');
1659
1798
  }
1660
1799
  this.editor.commands.setContent(e, !1, { preserveWhitespace: "full" });
@@ -1666,10 +1805,10 @@ ${n.textContent}
1666
1805
  insertPlainTextWithHardBreaks(e, t) {
1667
1806
  const { tr: o } = e.state, { from: n, to: r } = e.state.selection;
1668
1807
  o.deleteRange(n, r);
1669
- const i = t.split(/\r?\n/);
1670
- let s = n;
1671
- for (let a = 0; a < i.length; a++)
1672
- a > 0 && (o.insert(s, e.state.schema.nodes.hardBreak.create()), s++), o.insertText(i[a], s), s += i[a].length;
1808
+ const s = t.split(/\r?\n/);
1809
+ let i = n;
1810
+ for (let a = 0; a < s.length; a++)
1811
+ a > 0 && (o.insert(i, e.state.schema.nodes.hardBreak.create()), i++), o.insertText(s[a], i), i += s[a].length;
1673
1812
  e.dispatch(o);
1674
1813
  },
1675
1814
  shouldPreserveLineBreaks(e, t) {
@@ -1737,6 +1876,8 @@ ${n.textContent}
1737
1876
  const n = this.editor.getText({ blockSeparator: `
1738
1877
  ` });
1739
1878
  this.$emit("text-input", n);
1879
+ const r = this.jsonToMarkdownConverter.convertToMarkdown(t);
1880
+ this.$emit("markdown-input", r);
1740
1881
  },
1741
1882
  /**
1742
1883
  * The Editor exposes event hooks that we have to map our emits into. See
@@ -1761,6 +1902,8 @@ ${n.textContent}
1761
1902
  return this.editor.getJSON();
1762
1903
  case "html":
1763
1904
  return this.editor.getHTML();
1905
+ case "markdown":
1906
+ return this.jsonToMarkdownConverter.convertToMarkdown(this.editor.getJSON());
1764
1907
  case "text":
1765
1908
  default:
1766
1909
  return this.editor.getText({ blockSeparator: `
@@ -1786,52 +1929,52 @@ ${n.textContent}
1786
1929
  this.editor.commands.focus();
1787
1930
  }
1788
1931
  }
1789
- }, ln = { class: "d-popover__dialog" };
1790
- function cn(e, t, o, n, r, i) {
1791
- const s = d("dt-button"), a = d("dt-stack"), c = d("bubble-menu"), f = d("editor-content");
1792
- return l(), _("div", null, [
1793
- r.editor && o.link && !o.hideLinkBubbleMenu ? (l(), h(c, {
1932
+ }, dn = { class: "d-popover__dialog" };
1933
+ function ln(e, t, o, n, r, s) {
1934
+ const i = l("dt-button"), a = l("dt-stack"), c = l("bubble-menu"), p = l("editor-content");
1935
+ return d(), _("div", null, [
1936
+ r.editor && o.link && !o.hideLinkBubbleMenu ? (d(), m(c, {
1794
1937
  key: 0,
1795
1938
  editor: r.editor,
1796
- "should-show": i.bubbleMenuShouldShow,
1939
+ "should-show": s.bubbleMenuShouldShow,
1797
1940
  "tippy-options": r.tippyOptions,
1798
1941
  style: { visibility: "visible" }
1799
1942
  }, {
1800
1943
  default: u(() => [
1801
- w("div", ln, [
1802
- p(a, {
1944
+ k("div", dn, [
1945
+ f(a, {
1803
1946
  direction: "row",
1804
1947
  class: "d-rich-text-editor-bubble-menu__button-stack",
1805
1948
  gap: "0"
1806
1949
  }, {
1807
1950
  default: u(() => [
1808
- p(s, {
1951
+ f(i, {
1809
1952
  kind: "muted",
1810
1953
  importance: "clear",
1811
- onClick: i.editLink
1954
+ onClick: s.editLink
1812
1955
  }, {
1813
1956
  default: u(() => [
1814
- k(m(r.i18n.$t("DIALTONE_RICH_TEXT_EDITOR_EDIT_BUTTON_LABEL")), 1)
1957
+ C(h(r.i18n.$t("DIALTONE_RICH_TEXT_EDITOR_EDIT_BUTTON_LABEL")), 1)
1815
1958
  ]),
1816
1959
  _: 1
1817
1960
  }, 8, ["onClick"]),
1818
- p(s, {
1961
+ f(i, {
1819
1962
  kind: "muted",
1820
1963
  importance: "clear",
1821
- onClick: i.openLink
1964
+ onClick: s.openLink
1822
1965
  }, {
1823
1966
  default: u(() => [
1824
- k(m(r.i18n.$t("DIALTONE_RICH_TEXT_EDITOR_OPEN_LINK_BUTTON_LABEL")), 1)
1967
+ C(h(r.i18n.$t("DIALTONE_RICH_TEXT_EDITOR_OPEN_LINK_BUTTON_LABEL")), 1)
1825
1968
  ]),
1826
1969
  _: 1
1827
1970
  }, 8, ["onClick"]),
1828
- p(s, {
1971
+ f(i, {
1829
1972
  kind: "danger",
1830
1973
  importance: "clear",
1831
- onClick: i.removeLink
1974
+ onClick: s.removeLink
1832
1975
  }, {
1833
1976
  default: u(() => [
1834
- k(m(r.i18n.$t("DIALTONE_RICH_TEXT_EDITOR_REMOVE_BUTTON_LABEL")), 1)
1977
+ C(h(r.i18n.$t("DIALTONE_RICH_TEXT_EDITOR_REMOVE_BUTTON_LABEL")), 1)
1835
1978
  ]),
1836
1979
  _: 1
1837
1980
  }, 8, ["onClick"])
@@ -1841,17 +1984,17 @@ function cn(e, t, o, n, r, i) {
1841
1984
  ])
1842
1985
  ]),
1843
1986
  _: 1
1844
- }, 8, ["editor", "should-show", "tippy-options"])) : x("", !0),
1845
- p(f, Pe({
1987
+ }, 8, ["editor", "should-show", "tippy-options"])) : w("", !0),
1988
+ f(p, Ae({
1846
1989
  ref: "editor",
1847
1990
  editor: r.editor,
1848
1991
  class: "d-rich-text-editor",
1849
1992
  "data-qa": "dt-rich-text-editor"
1850
- }, i.attrs), null, 16, ["editor"])
1993
+ }, s.attrs), null, 16, ["editor"])
1851
1994
  ]);
1852
1995
  }
1853
- const eo = /* @__PURE__ */ g(an, [["render", cn]]);
1996
+ const no = /* @__PURE__ */ g(cn, [["render", ln]]);
1854
1997
  export {
1855
- eo as default
1998
+ no as default
1856
1999
  };
1857
2000
  //# sourceMappingURL=rich-text-editor.js.map