@dialpad/dialtone 9.126.1 → 9.126.2
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.
- package/dist/css/dialtone-default-theme.css +1 -1
- package/dist/css/dialtone-default-theme.min.css +1 -1
- package/dist/css/dialtone.css +1 -1
- package/dist/css/dialtone.min.css +1 -1
- package/dist/tokens/doc.json +26155 -26155
- package/dist/vue2/component-documentation.json +1 -1
- package/dist/vue2/lib/message-input/message-input.cjs +1 -1
- package/dist/vue2/lib/message-input/message-input.cjs.map +1 -1
- package/dist/vue2/lib/message-input/message-input.js +29 -7
- package/dist/vue2/lib/message-input/message-input.js.map +1 -1
- package/dist/vue2/lib/rich-text-editor/rich-text-editor.cjs +1 -1
- package/dist/vue2/lib/rich-text-editor/rich-text-editor.cjs.map +1 -1
- package/dist/vue2/lib/rich-text-editor/rich-text-editor.js +73 -44
- package/dist/vue2/lib/rich-text-editor/rich-text-editor.js.map +1 -1
- package/dist/vue2/types/components/rich_text_editor/extensions/slash_command/slash_command.d.ts.map +1 -1
- package/dist/vue2/types/components/rich_text_editor/rich_text_editor.vue.d.ts +1 -1
- package/dist/vue2/types/components/rich_text_editor/rich_text_editor.vue.d.ts.map +1 -1
- package/dist/vue2/types/recipes/conversation_view/message_input/message_input.vue.d.ts.map +1 -1
- package/dist/vue3/component-documentation.json +1 -1
- package/dist/vue3/lib/message-input/message-input.cjs +1 -1
- package/dist/vue3/lib/message-input/message-input.cjs.map +1 -1
- package/dist/vue3/lib/message-input/message-input.js +88 -67
- package/dist/vue3/lib/message-input/message-input.js.map +1 -1
- package/dist/vue3/lib/rich-text-editor/rich-text-editor.cjs +1 -1
- package/dist/vue3/lib/rich-text-editor/rich-text-editor.cjs.map +1 -1
- package/dist/vue3/lib/rich-text-editor/rich-text-editor.js +48 -19
- package/dist/vue3/lib/rich-text-editor/rich-text-editor.js.map +1 -1
- package/dist/vue3/types/components/rich_text_editor/extensions/slash_command/slash_command.d.ts.map +1 -1
- package/dist/vue3/types/components/rich_text_editor/rich_text_editor.vue.d.ts +2 -1
- package/dist/vue3/types/components/rich_text_editor/rich_text_editor.vue.d.ts.map +1 -1
- package/dist/vue3/types/recipes/conversation_view/message_input/message_input.vue.d.ts.map +1 -1
- package/package.json +3 -3
|
@@ -24,14 +24,14 @@ import ve from "@tiptap/extension-font-family";
|
|
|
24
24
|
import { PluginKey as T, Plugin as Re } from "@tiptap/pm/state";
|
|
25
25
|
import $e from "@tiptap/suggestion";
|
|
26
26
|
import { emojiPattern as W } from "regex-combined-emojis";
|
|
27
|
-
import { resolveComponent as d, openBlock as l, createBlock as m, withCtx as u, createVNode as f, createElementBlock as _, withDirectives as Me, createElementVNode as w, Fragment as
|
|
27
|
+
import { resolveComponent as d, openBlock as l, createBlock as m, withCtx as u, createVNode as f, createElementBlock as _, withDirectives as Me, createElementVNode as w, Fragment as Oe, renderList as Ie, normalizeClass as z, withModifiers as Pe, resolveDynamicComponent as Be, vShow as Ae, createTextVNode as k, toDisplayString as p, markRaw as M, createCommentVNode as x, mergeProps as De } from "vue";
|
|
28
28
|
import { _ as g } from "../../_plugin-vue_export-helper-CHgC5LLL.js";
|
|
29
29
|
import X from "../emoji/emoji.js";
|
|
30
30
|
import { stringToUnicode as je, codeToEmojiData as H, emojiRegex as He, emojiShortCodeRegex as Ne } from "../../common/emoji/index.js";
|
|
31
31
|
import { emojisIndexed as Fe } from "@dialpad/dialtone-emojis";
|
|
32
32
|
import Ve from "../list-item/list-item.js";
|
|
33
|
-
import
|
|
34
|
-
import
|
|
33
|
+
import O from "../stack/stack.js";
|
|
34
|
+
import I from "tippy.js";
|
|
35
35
|
import { linkRegex as qe, getPhoneNumberRegex as Ke, returnFirstEl as F, warnIfUnmounted as Ue } from "../../common/utils/index.js";
|
|
36
36
|
import We from "@tiptap/extension-image";
|
|
37
37
|
import N from "@tiptap/extension-mention";
|
|
@@ -144,7 +144,7 @@ function st(e, t, o, n, r, i) {
|
|
|
144
144
|
const s = d("dt-list-item");
|
|
145
145
|
return l(), _("div", rt, [
|
|
146
146
|
Me(w("ul", it, [
|
|
147
|
-
(l(!0), _(
|
|
147
|
+
(l(!0), _(Oe, null, Ie(o.items, (a, c) => (l(), m(s, {
|
|
148
148
|
key: a.id,
|
|
149
149
|
class: z([
|
|
150
150
|
"d-suggestion-list__item",
|
|
@@ -169,7 +169,7 @@ const P = /* @__PURE__ */ g(ot, [["render", st]]), at = {
|
|
|
169
169
|
name: "EmojiSuggestion",
|
|
170
170
|
components: {
|
|
171
171
|
DtEmoji: X,
|
|
172
|
-
DtStack:
|
|
172
|
+
DtStack: O
|
|
173
173
|
},
|
|
174
174
|
props: {
|
|
175
175
|
item: {
|
|
@@ -244,7 +244,7 @@ const ct = /* @__PURE__ */ g(at, [["render", lt]]), B = {
|
|
|
244
244
|
...n
|
|
245
245
|
},
|
|
246
246
|
editor: n.editor
|
|
247
|
-
}), n.clientRect && (t =
|
|
247
|
+
}), n.clientRect && (t = I("body", {
|
|
248
248
|
getReferenceClientRect: n.clientRect,
|
|
249
249
|
appendTo: () => document.body,
|
|
250
250
|
content: e.element,
|
|
@@ -614,7 +614,7 @@ const Rt = /* @__PURE__ */ g(Lt, [["render", vt]]), $t = N.extend({
|
|
|
614
614
|
}
|
|
615
615
|
}
|
|
616
616
|
};
|
|
617
|
-
function
|
|
617
|
+
function Ot(e, t, o, n, r, i) {
|
|
618
618
|
const s = d("dt-link"), a = d("node-view-wrapper");
|
|
619
619
|
return l(), m(a, { class: "d-d-inline-block" }, {
|
|
620
620
|
default: u(() => [
|
|
@@ -628,10 +628,10 @@ function It(e, t, o, n, r, i) {
|
|
|
628
628
|
_: 1
|
|
629
629
|
});
|
|
630
630
|
}
|
|
631
|
-
const
|
|
631
|
+
const It = /* @__PURE__ */ g(Mt, [["render", Ot]]), Pt = N.extend({
|
|
632
632
|
name: "channel",
|
|
633
633
|
addNodeView() {
|
|
634
|
-
return $(
|
|
634
|
+
return $(It);
|
|
635
635
|
},
|
|
636
636
|
parseHTML() {
|
|
637
637
|
return [
|
|
@@ -670,7 +670,9 @@ const Ot = /* @__PURE__ */ g(Mt, [["render", It]]), Pt = N.extend({
|
|
|
670
670
|
components: {
|
|
671
671
|
NodeViewWrapper: L
|
|
672
672
|
},
|
|
673
|
-
props:
|
|
673
|
+
props: {
|
|
674
|
+
...v
|
|
675
|
+
},
|
|
674
676
|
emits: ["selected-command"],
|
|
675
677
|
computed: {
|
|
676
678
|
text() {
|
|
@@ -678,7 +680,11 @@ const Ot = /* @__PURE__ */ g(Mt, [["render", It]]), Pt = N.extend({
|
|
|
678
680
|
}
|
|
679
681
|
},
|
|
680
682
|
created() {
|
|
681
|
-
|
|
683
|
+
var o, n, r;
|
|
684
|
+
const e = this.$props.node.attrs.command;
|
|
685
|
+
this.$emit("selected-command", e);
|
|
686
|
+
const t = (r = (n = (o = this.editor) == null ? void 0 : o.storage) == null ? void 0 : n["slash-commands"]) == null ? void 0 : r.onSelectedCommand;
|
|
687
|
+
t && typeof t == "function" && t(e);
|
|
682
688
|
}
|
|
683
689
|
};
|
|
684
690
|
function At(e, t, o, n, r, i) {
|
|
@@ -701,6 +707,18 @@ const Dt = /* @__PURE__ */ g(Bt, [["render", At]]), jt = (e, t) => [...e.matchAl
|
|
|
701
707
|
name: "slash-commands",
|
|
702
708
|
group: "inline",
|
|
703
709
|
inline: !0,
|
|
710
|
+
addOptions() {
|
|
711
|
+
var e;
|
|
712
|
+
return {
|
|
713
|
+
...(e = this.parent) == null ? void 0 : e.call(this),
|
|
714
|
+
onSelectedCommand: null
|
|
715
|
+
};
|
|
716
|
+
},
|
|
717
|
+
addStorage() {
|
|
718
|
+
return {
|
|
719
|
+
onSelectedCommand: this.options.onSelectedCommand
|
|
720
|
+
};
|
|
721
|
+
},
|
|
704
722
|
addNodeView() {
|
|
705
723
|
return $(Dt);
|
|
706
724
|
},
|
|
@@ -766,7 +784,7 @@ const Dt = /* @__PURE__ */ g(Bt, [["render", At]]), jt = (e, t) => [...e.matchAl
|
|
|
766
784
|
name: "MentionSuggestion",
|
|
767
785
|
components: {
|
|
768
786
|
DtAvatar: Je,
|
|
769
|
-
DtStack:
|
|
787
|
+
DtStack: O
|
|
770
788
|
},
|
|
771
789
|
props: {
|
|
772
790
|
item: {
|
|
@@ -870,7 +888,7 @@ const Ut = /* @__PURE__ */ g(Nt, [["render", Kt]]), Wt = {
|
|
|
870
888
|
...n
|
|
871
889
|
},
|
|
872
890
|
editor: n.editor
|
|
873
|
-
}), n.clientRect && (t =
|
|
891
|
+
}), n.clientRect && (t = I("body", {
|
|
874
892
|
getReferenceClientRect: n.clientRect,
|
|
875
893
|
appendTo: () => document.body,
|
|
876
894
|
content: e.element,
|
|
@@ -907,7 +925,7 @@ const Ut = /* @__PURE__ */ g(Nt, [["render", Kt]]), Wt = {
|
|
|
907
925
|
compatConfig: { MODE: 3 },
|
|
908
926
|
name: "ChannelSuggestion",
|
|
909
927
|
components: {
|
|
910
|
-
DtStack:
|
|
928
|
+
DtStack: O,
|
|
911
929
|
DtIconHash: Ye,
|
|
912
930
|
DtIconLock: Ge
|
|
913
931
|
},
|
|
@@ -958,7 +976,7 @@ const Jt = /* @__PURE__ */ g(zt, [["render", Xt]]), Yt = {
|
|
|
958
976
|
...n
|
|
959
977
|
},
|
|
960
978
|
editor: n.editor
|
|
961
|
-
}), n.clientRect && (t =
|
|
979
|
+
}), n.clientRect && (t = I("body", {
|
|
962
980
|
getReferenceClientRect: n.clientRect,
|
|
963
981
|
appendTo: () => document.body,
|
|
964
982
|
content: e.element,
|
|
@@ -1039,7 +1057,7 @@ const nn = /* @__PURE__ */ g(Gt, [["render", tn]]), on = {
|
|
|
1039
1057
|
...n
|
|
1040
1058
|
},
|
|
1041
1059
|
editor: n.editor
|
|
1042
|
-
}), n.clientRect && (t =
|
|
1060
|
+
}), n.clientRect && (t = I("body", {
|
|
1043
1061
|
getReferenceClientRect: n.clientRect,
|
|
1044
1062
|
appendTo: () => document.body,
|
|
1045
1063
|
content: e.element,
|
|
@@ -1079,7 +1097,7 @@ const nn = /* @__PURE__ */ g(Gt, [["render", tn]]), on = {
|
|
|
1079
1097
|
EditorContent: G,
|
|
1080
1098
|
BubbleMenu: Q,
|
|
1081
1099
|
DtButton: Ze,
|
|
1082
|
-
DtStack:
|
|
1100
|
+
DtStack: O
|
|
1083
1101
|
},
|
|
1084
1102
|
props: {
|
|
1085
1103
|
/**
|
|
@@ -1409,7 +1427,13 @@ const nn = /* @__PURE__ */ g(Gt, [["render", tn]]), on = {
|
|
|
1409
1427
|
* @event selected
|
|
1410
1428
|
* @type {String}
|
|
1411
1429
|
*/
|
|
1412
|
-
"selected"
|
|
1430
|
+
"selected",
|
|
1431
|
+
/**
|
|
1432
|
+
* Event fired when a slash command is selected
|
|
1433
|
+
* @event selected-command
|
|
1434
|
+
* @type {String}
|
|
1435
|
+
*/
|
|
1436
|
+
"selected-command"
|
|
1413
1437
|
],
|
|
1414
1438
|
data() {
|
|
1415
1439
|
return {
|
|
@@ -1476,7 +1500,12 @@ const nn = /* @__PURE__ */ g(Gt, [["render", tn]]), on = {
|
|
|
1476
1500
|
}
|
|
1477
1501
|
if (this.slashCommandSuggestion) {
|
|
1478
1502
|
const n = { ...this.slashCommandSuggestion, ...on };
|
|
1479
|
-
e.push(Ht.configure({
|
|
1503
|
+
e.push(Ht.configure({
|
|
1504
|
+
suggestion: n,
|
|
1505
|
+
onSelectedCommand: (r) => {
|
|
1506
|
+
this.$emit("selected-command", r);
|
|
1507
|
+
}
|
|
1508
|
+
}));
|
|
1480
1509
|
}
|
|
1481
1510
|
return e.push(gt), e.push(Te.configure({
|
|
1482
1511
|
types: ["paragraph"]
|