@dialpad/dialtone-vue 2.123.0 → 2.124.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.
- package/CHANGELOG.json +1 -1
- package/CHANGELOG.md +24 -0
- package/dist/dialtone-vue.cjs +1 -1
- package/dist/dialtone-vue.js +5 -5
- package/dist/emoji.cjs +1 -1
- package/dist/emoji.js +3 -3
- package/dist/{emoji_picker-RVVypenL.js → emoji_picker-kiTOKaq8.js} +1 -1
- package/dist/{emoji_picker-vs3kVT4C.cjs → emoji_picker-njWWAm6V.cjs} +1 -1
- package/dist/{emoji_text_wrapper-D8sO5OFj.js → emoji_text_wrapper-48ClwKvf.js} +1 -1
- package/dist/{emoji_text_wrapper-Rk9EMvo8.cjs → emoji_text_wrapper-ZlynvHnd.cjs} +1 -1
- package/dist/{index-5kIwGgwp.js → index-OF94C6nQ.js} +993 -976
- package/dist/index-Wx7Jagcr.cjs +1 -0
- package/dist/message_input.cjs +1 -1
- package/dist/message_input.js +52 -36
- package/dist/{rich_text_editor-750LBgdo.js → rich_text_editor-9sMob7ck.js} +6 -6
- package/dist/{rich_text_editor-q9e-ZDwe.cjs → rich_text_editor-Eh5kYokw.cjs} +15 -15
- package/dist/types/components/rich_text_editor/extensions/mentions/suggestion.d.ts +1 -0
- package/dist/types/components/rich_text_editor/extensions/mentions/suggestion.d.ts.map +1 -1
- package/dist/types/recipes/conversation_view/message_input/message_input.vue.d.ts +2 -2
- package/package.json +5 -5
- package/dist/index-FZJBS_ti.cjs +0 -1
package/dist/message_input.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("./rich_text_editor-Eh5kYokw.cjs"),o=require("./index-Wx7Jagcr.cjs"),l=require("./emoji_picker-njWWAm6V.cjs"),r=require("./tooltip-i2wxFIIi.cjs");require("vue");const u={name:"DtRecipeMessageInput",components:{DtButton:o.DtButton,DtEmojiPicker:l.DtEmojiPicker,DtIcon:o.DtIcon,DtInput:o.DtInput,DtPopover:a.DtPopover,DtRichTextEditor:a.DtRichTextEditor,DtTooltip:r.DtTooltip},mixins:[],inheritAttrs:!1,props:{value:{type:[Object,String],default:""},editable:{type:Boolean,default:!0},inputAriaLabel:{type:String,required:!0,default:""},inputClass:{type:String,default:""},autoFocus:{type:[Boolean,String,Number],default:!1,validator(t){return typeof t=="string"?a.RICH_TEXT_EDITOR_AUTOFOCUS_TYPES.includes(t):!0}},outputFormat:{type:String,default:"text",validator(t){return a.RICH_TEXT_EDITOR_OUTPUT_FORMATS.includes(t)}},link:{type:[Boolean,Object],default:!1},placeholder:{type:String,default:""},disableSend:{type:Boolean,default:!1},maxHeight:{type:String,default:"unset"},showEmojiPicker:{type:Boolean,default:!0},emojiPickerProps:{type:Object,default:()=>({}),validate(t){return["searchNoResultsLabel","searchResultsLabel","searchPlaceholderLabel","skinSelectorButtonTooltipLabel","tabSetLabels"].every(e=>t[e]!=null)}},emojiTooltipMessage:{type:String,default:"Emoji"},emojiButtonAriaLabel:{type:String,default:"emoji button"},showCharacterLimit:{type:[Boolean,Object],default:()=>({count:1500,warning:500,message:""})},showImagePicker:{type:[Boolean,Object],default:()=>({tooltipLabel:"Attach Image",ariaLabel:"image button"})},showSend:{type:[Boolean,Object],default:()=>({icon:"send"})},showCancel:{type:[Boolean,Object],default:()=>({text:"Cancel"})},mentionSuggestion:{type:Object,default:null}},emits:["submit","select-media","add-media","paste-media","cancel","skin-tone","selected-emoji","focus","blur","input"],data(){return{internalInputValue:this.value,hasFocus:!1,imagePickerFocus:!1,emojiPickerFocus:!1,sendButtonFocus:!1,emojiPickerOpened:!1}},computed:{inputLength(){return this.internalInputValue.length},displayCharacterLimitWarning(){return!!this.showCharacterLimit&&this.showCharacterLimit.count-this.inputLength<=this.showCharacterLimit.warning},characterLimitTooltipEnabled(){return this.showCharacterLimit.message&&this.showCharacterLimit.count-this.inputLength<0},isSendDisabled(){return this.disableSend||this.showCharacterLimit&&this.inputLength>this.showCharacterLimit.count},computedCloseButtonProps(){return{ariaLabel:"Close"}},emojiPickerHovered(){return this.emojiPickerFocus||this.emojiPickerOpened}},watch:{value(t){this.internalInputValue=t}},methods:{onDrag(t){t.stopPropagation(),t.preventDefault()},onDrop(t){t.stopPropagation(),t.preventDefault();const e=t.dataTransfer,n=Array.from(e.files);this.$emit("add-media",n)},onPaste(t){if(t.clipboardData.files.length){t.stopPropagation(),t.preventDefault();const e=[...t.clipboardData.files];this.$emit("paste-media",e)}},onSkinTone(t){this.$emit("skin-tone",t)},onSelectEmoji(t){if(!t){this.emojiPickerOpened=!1;return}this.$refs.richTextEditor.editor.commands.insertContent({type:"emoji",attrs:{code:t.shortname}}),this.emojiPickerOpened=!1,this.$emit("selected-emoji",t)},onSelectImage(){this.$refs.messageInputImageUpload.$refs.input.click()},onImageUpload(){this.$emit("select-media",this.$refs.messageInputImageUpload.$refs.input.files)},toggleEmojiPicker(){this.emojiPickerOpened=!this.emojiPickerOpened},onSend(){this.isSendDisabled||this.$emit("submit",this.internalInputValue)},onCancel(){this.$emit("cancel")},onFocus(t){var e;this.hasFocus=!0,(e=this.$refs.richTextEditor)==null||e.focusEditor(),this.$emit("focus",t)},onBlur(t){this.hasFocus=!1,this.$emit("blur",t)},onInput(t){this.$emit("input",t)}}};var c=function(){var e=this,n=e._self._c;return n("div",{class:["d-d-flex","d-fd-column","d-bar8","d-baw1","d-ba","d-c-text",{"d-bc-bold d-bs-sm":e.hasFocus,"d-bc-default":!e.hasFocus}],attrs:{"data-qa":"dt-message-input",role:"presentation"},on:{click:function(i){var s;(s=e.$refs.richTextEditor)==null||s.focusEditor()},"drag-enter":e.onDrag,"drag-over":e.onDrag,drop:e.onDrop,keydown:function(i){return!i.type.indexOf("key")&&e._k(i.keyCode,"enter",13,i.key,"Enter")||i.ctrlKey||i.shiftKey||i.altKey||i.metaKey?null:e.onSend.apply(null,arguments)},paste:e.onPaste}},[n("div",{staticClass:"d-of-auto d-mx16 d-mt8 d-mb4",style:{"max-height":e.maxHeight}},[n("dt-rich-text-editor",e._b({ref:"richTextEditor",attrs:{editable:e.editable,"input-aria-label":e.inputAriaLabel,"input-class":e.inputClass,"output-format":e.outputFormat,"auto-focus":e.autoFocus,link:e.link,placeholder:e.placeholder,"mention-suggestion":e.mentionSuggestion},on:{focus:e.onFocus,blur:e.onBlur,input:function(i){return e.onInput(i)}},model:{value:e.internalInputValue,callback:function(i){e.internalInputValue=i},expression:"internalInputValue"}},"dt-rich-text-editor",e.$attrs,!1))],1),e._t("middle"),n("section",{staticClass:"d-d-flex d-jc-space-between d-mx8 d-my4"},[n("div",{staticClass:"d-d-flex"},[e.showImagePicker?n("dt-tooltip",{attrs:{placement:"top-start",message:e.showImagePicker.tooltipLabel,offset:[-4,-4]},scopedSlots:e._u([{key:"anchor",fn:function(){return[n("dt-button",{attrs:{"data-qa":"dt-message-input-image-btn",size:"sm",circle:"",kind:e.imagePickerFocus?"default":"muted",importance:"clear","aria-label":e.showImagePicker.ariaLabel},on:{click:e.onSelectImage,mouseenter:function(i){e.imagePickerFocus=!0},mouseleave:function(i){e.imagePickerFocus=!1},focus:function(i){e.imagePickerFocus=!0},blur:function(i){e.imagePickerFocus=!1}},scopedSlots:e._u([{key:"icon",fn:function(){return[n("dt-icon",{attrs:{name:"image",size:"300"}})]},proxy:!0}],null,!1,2561380377)}),n("dt-input",{ref:"messageInputImageUpload",staticClass:"d-ps-absolute",attrs:{"data-qa":"dt-message-input-image-input",type:"file",multiple:"",hidden:""},on:{input:e.onImageUpload}})]},proxy:!0}],null,!1,3687934814)}):e._e(),e.showEmojiPicker?n("dt-popover",{attrs:{"data-qa":"dt-message-input-emoji-picker-popover",open:e.emojiPickerOpened,"initial-focus-element":"#searchInput",padding:"none"},on:{opened:i=>{e.emojiPickerOpened=i}},scopedSlots:e._u([{key:"anchor",fn:function(){return[n("dt-tooltip",{attrs:{message:e.emojiTooltipMessage,offset:[0,-4]},scopedSlots:e._u([{key:"anchor",fn:function(){return[n("dt-button",{attrs:{"data-qa":"dt-message-input-emoji-picker-btn",size:"sm",circle:"",kind:e.emojiPickerHovered?"default":"muted",importance:"clear","aria-label":e.emojiButtonAriaLabel,offset:[0,0]},on:{click:e.toggleEmojiPicker,mouseenter:function(i){e.emojiPickerFocus=!0},mouseleave:function(i){e.emojiPickerFocus=!1},focus:function(i){e.emojiPickerFocus=!0},blur:function(i){e.emojiPickerFocus=!1}},scopedSlots:e._u([{key:"icon",fn:function(){return[n("dt-icon",{attrs:{name:e.emojiPickerHovered?"very-satisfied":"satisfied",size:"300"}})]},proxy:!0}],null,!1,352772906)})]},proxy:!0}],null,!1,3933528398)})]},proxy:!0},{key:"content",fn:function(){return[n("dt-emoji-picker",e._b({on:{"skin-tone":e.onSkinTone,"selected-emoji":e.onSelectEmoji}},"dt-emoji-picker",e.emojiPickerProps,!1))]},proxy:!0}],null,!1,1278205067)}):e._e()],1),n("div",{staticClass:"d-d-flex"},[e.showCharacterLimit?n("dt-tooltip",{staticClass:"dt-message-input--remaining-char-tooltip",attrs:{placement:"top-end",enabled:e.characterLimitTooltipEnabled,message:e.showCharacterLimit.message,offset:[10,-8]},scopedSlots:e._u([{key:"anchor",fn:function(){return[n("p",{directives:[{name:"show",rawName:"v-show",value:e.displayCharacterLimitWarning,expression:"displayCharacterLimitWarning"}],staticClass:"d-fc-error d-mr16 dt-message-input--remaining-char",attrs:{"data-qa":"dt-message-input-character-limit"}},[e._v(" "+e._s(e.showCharacterLimit.count-e.inputLength)+" ")])]},proxy:!0}],null,!1,2591914334)}):e._e(),e.showCancel?n("dt-button",{staticClass:"dt-message-input--cancel-button",attrs:{"data-qa":"dt-message-input-cancel-button",size:"sm",kind:"muted",importance:"clear","aria-label":e.showCancel.ariaLabel},on:{click:e.onCancel}},[n("p",[e._v(e._s(e.showCancel.text))])]):e._e(),e.showSend?n("dt-tooltip",{attrs:{placement:"top-end",enabled:!e.showSend,message:e.showSend.tooltipLabel,show:!e.isSendDisabled&&e.sendButtonFocus,offset:[6,-8]},scopedSlots:e._u([{key:"anchor",fn:function(){return[n("dt-button",{class:["d-btn--circle",{"message-input-button__disabled d-fc-muted":e.isSendDisabled}],attrs:{"data-qa":"dt-message-input-send-btn",size:"sm",kind:"default",importance:"primary","aria-label":e.showSend.ariaLabel,"aria-disabled":e.isSendDisabled},on:{click:e.onSend,mouseenter:function(i){e.sendButtonFocus=!0},mouseleave:function(i){e.sendButtonFocus=!1},focus:function(i){e.sendButtonFocus=!0},blur:function(i){e.sendButtonFocus=!1}},scopedSlots:e._u([e.showSend.icon?{key:"icon",fn:function(){return[n("dt-icon",{attrs:{name:e.showSend.icon,size:"300"}})]},proxy:!0}:null],null,!0)},[e.showSend.text?[n("p",[e._v(e._s(e.showSend.text))])]:e._e()],2)]},proxy:!0}],null,!1,2968465028)}):e._e()],1)])],2)},d=[],p=r.normalizeComponent(u,c,d,!1,null,null,null,null);const m=p.exports;exports.DtRichTextEditor=a.DtRichTextEditor;exports.RICH_TEXT_EDITOR_AUTOFOCUS_TYPES=a.RICH_TEXT_EDITOR_AUTOFOCUS_TYPES;exports.RICH_TEXT_EDITOR_OUTPUT_FORMATS=a.RICH_TEXT_EDITOR_OUTPUT_FORMATS;exports.DtRecipeMessageInput=m;
|
package/dist/message_input.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { D as o, a as s, R as r, b as l } from "./rich_text_editor-
|
|
2
|
-
import { t as u, w as c, x as d } from "./index-
|
|
3
|
-
import { D as m } from "./emoji_picker-
|
|
1
|
+
import { D as o, a as s, R as r, b as l } from "./rich_text_editor-9sMob7ck.js";
|
|
2
|
+
import { t as u, w as c, x as d } from "./index-OF94C6nQ.js";
|
|
3
|
+
import { D as m } from "./emoji_picker-kiTOKaq8.js";
|
|
4
4
|
import { n as p, D as f } from "./tooltip-88U5vFMA.js";
|
|
5
5
|
import "vue";
|
|
6
6
|
const h = {
|
|
@@ -208,6 +208,13 @@ const h = {
|
|
|
208
208
|
* @type {Array}
|
|
209
209
|
*/
|
|
210
210
|
"add-media",
|
|
211
|
+
/**
|
|
212
|
+
* Fires when media is pasted into the message input
|
|
213
|
+
*
|
|
214
|
+
* @event paste-media
|
|
215
|
+
* @type {Array}
|
|
216
|
+
*/
|
|
217
|
+
"paste-media",
|
|
211
218
|
/**
|
|
212
219
|
* Fires when cancel button is pressed (only on edit mode)
|
|
213
220
|
*
|
|
@@ -279,9 +286,6 @@ const h = {
|
|
|
279
286
|
},
|
|
280
287
|
emojiPickerHovered() {
|
|
281
288
|
return this.emojiPickerFocus || this.emojiPickerOpened;
|
|
282
|
-
},
|
|
283
|
-
sendButtonKind() {
|
|
284
|
-
return this.isSendDisabled ? "muted" : "default";
|
|
285
289
|
}
|
|
286
290
|
},
|
|
287
291
|
watch: {
|
|
@@ -295,8 +299,15 @@ const h = {
|
|
|
295
299
|
},
|
|
296
300
|
onDrop(t) {
|
|
297
301
|
t.stopPropagation(), t.preventDefault();
|
|
298
|
-
const e = t.dataTransfer,
|
|
299
|
-
this.$emit("add-media",
|
|
302
|
+
const e = t.dataTransfer, i = Array.from(e.files);
|
|
303
|
+
this.$emit("add-media", i);
|
|
304
|
+
},
|
|
305
|
+
onPaste(t) {
|
|
306
|
+
if (t.clipboardData.files.length) {
|
|
307
|
+
t.stopPropagation(), t.preventDefault();
|
|
308
|
+
const e = [...t.clipboardData.files];
|
|
309
|
+
this.$emit("paste-media", e);
|
|
310
|
+
}
|
|
300
311
|
},
|
|
301
312
|
onSkinTone(t) {
|
|
302
313
|
this.$emit("skin-tone", t);
|
|
@@ -329,7 +340,8 @@ const h = {
|
|
|
329
340
|
this.$emit("cancel");
|
|
330
341
|
},
|
|
331
342
|
onFocus(t) {
|
|
332
|
-
|
|
343
|
+
var e;
|
|
344
|
+
this.hasFocus = !0, (e = this.$refs.richTextEditor) == null || e.focusEditor(), this.$emit("focus", t);
|
|
333
345
|
},
|
|
334
346
|
onBlur(t) {
|
|
335
347
|
this.hasFocus = !1, this.$emit("blur", t);
|
|
@@ -349,37 +361,38 @@ var g = function() {
|
|
|
349
361
|
"d-ba",
|
|
350
362
|
"d-c-text",
|
|
351
363
|
{ "d-bc-bold d-bs-sm": e.hasFocus, "d-bc-default": !e.hasFocus }
|
|
352
|
-
], attrs: { "data-qa": "dt-message-input", role: "presentation" }, on: { click: function(
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
364
|
+
], attrs: { "data-qa": "dt-message-input", role: "presentation" }, on: { click: function(a) {
|
|
365
|
+
var n;
|
|
366
|
+
(n = e.$refs.richTextEditor) == null || n.focusEditor();
|
|
367
|
+
}, "drag-enter": e.onDrag, "drag-over": e.onDrag, drop: e.onDrop, keydown: function(a) {
|
|
368
|
+
return !a.type.indexOf("key") && e._k(a.keyCode, "enter", 13, a.key, "Enter") || a.ctrlKey || a.shiftKey || a.altKey || a.metaKey ? null : e.onSend.apply(null, arguments);
|
|
369
|
+
}, paste: e.onPaste } }, [i("div", { staticClass: "d-of-auto d-mx16 d-mt8 d-mb4", style: { "max-height": e.maxHeight } }, [i("dt-rich-text-editor", e._b({ ref: "richTextEditor", attrs: { editable: e.editable, "input-aria-label": e.inputAriaLabel, "input-class": e.inputClass, "output-format": e.outputFormat, "auto-focus": e.autoFocus, link: e.link, placeholder: e.placeholder, "mention-suggestion": e.mentionSuggestion }, on: { focus: e.onFocus, blur: e.onBlur, input: function(a) {
|
|
370
|
+
return e.onInput(a);
|
|
371
|
+
} }, model: { value: e.internalInputValue, callback: function(a) {
|
|
372
|
+
e.internalInputValue = a;
|
|
360
373
|
}, expression: "internalInputValue" } }, "dt-rich-text-editor", e.$attrs, !1))], 1), e._t("middle"), i("section", { staticClass: "d-d-flex d-jc-space-between d-mx8 d-my4" }, [i("div", { staticClass: "d-d-flex" }, [e.showImagePicker ? i("dt-tooltip", { attrs: { placement: "top-start", message: e.showImagePicker.tooltipLabel, offset: [-4, -4] }, scopedSlots: e._u([{ key: "anchor", fn: function() {
|
|
361
|
-
return [i("dt-button", { attrs: { "data-qa": "dt-message-input-image-btn", size: "sm", circle: "", kind: e.imagePickerFocus ? "default" : "muted", importance: "clear", "aria-label": e.showImagePicker.ariaLabel }, on: { click: e.onSelectImage, mouseenter: function(
|
|
374
|
+
return [i("dt-button", { attrs: { "data-qa": "dt-message-input-image-btn", size: "sm", circle: "", kind: e.imagePickerFocus ? "default" : "muted", importance: "clear", "aria-label": e.showImagePicker.ariaLabel }, on: { click: e.onSelectImage, mouseenter: function(a) {
|
|
362
375
|
e.imagePickerFocus = !0;
|
|
363
|
-
}, mouseleave: function(
|
|
376
|
+
}, mouseleave: function(a) {
|
|
364
377
|
e.imagePickerFocus = !1;
|
|
365
|
-
}, focus: function(
|
|
378
|
+
}, focus: function(a) {
|
|
366
379
|
e.imagePickerFocus = !0;
|
|
367
|
-
}, blur: function(
|
|
380
|
+
}, blur: function(a) {
|
|
368
381
|
e.imagePickerFocus = !1;
|
|
369
382
|
} }, scopedSlots: e._u([{ key: "icon", fn: function() {
|
|
370
383
|
return [i("dt-icon", { attrs: { name: "image", size: "300" } })];
|
|
371
384
|
}, proxy: !0 }], null, !1, 2561380377) }), i("dt-input", { ref: "messageInputImageUpload", staticClass: "d-ps-absolute", attrs: { "data-qa": "dt-message-input-image-input", type: "file", multiple: "", hidden: "" }, on: { input: e.onImageUpload } })];
|
|
372
|
-
}, proxy: !0 }], null, !1, 3687934814) }) : e._e(), e.showEmojiPicker ? i("dt-popover", { attrs: { "data-qa": "dt-message-input-emoji-picker-popover", open: e.emojiPickerOpened, "initial-focus-element": "#searchInput", padding: "none" }, on: { opened: (
|
|
373
|
-
e.emojiPickerOpened =
|
|
385
|
+
}, proxy: !0 }], null, !1, 3687934814) }) : e._e(), e.showEmojiPicker ? i("dt-popover", { attrs: { "data-qa": "dt-message-input-emoji-picker-popover", open: e.emojiPickerOpened, "initial-focus-element": "#searchInput", padding: "none" }, on: { opened: (a) => {
|
|
386
|
+
e.emojiPickerOpened = a;
|
|
374
387
|
} }, scopedSlots: e._u([{ key: "anchor", fn: function() {
|
|
375
388
|
return [i("dt-tooltip", { attrs: { message: e.emojiTooltipMessage, offset: [0, -4] }, scopedSlots: e._u([{ key: "anchor", fn: function() {
|
|
376
|
-
return [i("dt-button", { attrs: { "data-qa": "dt-message-input-emoji-picker-btn", size: "sm", circle: "", kind: e.emojiPickerHovered ? "default" : "muted", importance: "clear", "aria-label": e.emojiButtonAriaLabel, offset: [0, 0] }, on: { click: e.toggleEmojiPicker, mouseenter: function(
|
|
389
|
+
return [i("dt-button", { attrs: { "data-qa": "dt-message-input-emoji-picker-btn", size: "sm", circle: "", kind: e.emojiPickerHovered ? "default" : "muted", importance: "clear", "aria-label": e.emojiButtonAriaLabel, offset: [0, 0] }, on: { click: e.toggleEmojiPicker, mouseenter: function(a) {
|
|
377
390
|
e.emojiPickerFocus = !0;
|
|
378
|
-
}, mouseleave: function(
|
|
391
|
+
}, mouseleave: function(a) {
|
|
379
392
|
e.emojiPickerFocus = !1;
|
|
380
|
-
}, focus: function(
|
|
393
|
+
}, focus: function(a) {
|
|
381
394
|
e.emojiPickerFocus = !0;
|
|
382
|
-
}, blur: function(
|
|
395
|
+
}, blur: function(a) {
|
|
383
396
|
e.emojiPickerFocus = !1;
|
|
384
397
|
} }, scopedSlots: e._u([{ key: "icon", fn: function() {
|
|
385
398
|
return [i("dt-icon", { attrs: { name: e.emojiPickerHovered ? "very-satisfied" : "satisfied", size: "300" } })];
|
|
@@ -390,20 +403,23 @@ var g = function() {
|
|
|
390
403
|
}, proxy: !0 }], null, !1, 1278205067) }) : e._e()], 1), i("div", { staticClass: "d-d-flex" }, [e.showCharacterLimit ? i("dt-tooltip", { staticClass: "dt-message-input--remaining-char-tooltip", attrs: { placement: "top-end", enabled: e.characterLimitTooltipEnabled, message: e.showCharacterLimit.message, offset: [10, -8] }, scopedSlots: e._u([{ key: "anchor", fn: function() {
|
|
391
404
|
return [i("p", { directives: [{ name: "show", rawName: "v-show", value: e.displayCharacterLimitWarning, expression: "displayCharacterLimitWarning" }], staticClass: "d-fc-error d-mr16 dt-message-input--remaining-char", attrs: { "data-qa": "dt-message-input-character-limit" } }, [e._v(" " + e._s(e.showCharacterLimit.count - e.inputLength) + " ")])];
|
|
392
405
|
}, proxy: !0 }], null, !1, 2591914334) }) : e._e(), e.showCancel ? i("dt-button", { staticClass: "dt-message-input--cancel-button", attrs: { "data-qa": "dt-message-input-cancel-button", size: "sm", kind: "muted", importance: "clear", "aria-label": e.showCancel.ariaLabel }, on: { click: e.onCancel } }, [i("p", [e._v(e._s(e.showCancel.text))])]) : e._e(), e.showSend ? i("dt-tooltip", { attrs: { placement: "top-end", enabled: !e.showSend, message: e.showSend.tooltipLabel, show: !e.isSendDisabled && e.sendButtonFocus, offset: [6, -8] }, scopedSlots: e._u([{ key: "anchor", fn: function() {
|
|
393
|
-
return [i("dt-button", { class:
|
|
394
|
-
"
|
|
395
|
-
|
|
406
|
+
return [i("dt-button", { class: [
|
|
407
|
+
"d-btn--circle",
|
|
408
|
+
{
|
|
409
|
+
"message-input-button__disabled d-fc-muted": e.isSendDisabled
|
|
410
|
+
}
|
|
411
|
+
], attrs: { "data-qa": "dt-message-input-send-btn", size: "sm", kind: "default", importance: "primary", "aria-label": e.showSend.ariaLabel, "aria-disabled": e.isSendDisabled }, on: { click: e.onSend, mouseenter: function(a) {
|
|
396
412
|
e.sendButtonFocus = !0;
|
|
397
|
-
}, mouseleave: function(
|
|
413
|
+
}, mouseleave: function(a) {
|
|
398
414
|
e.sendButtonFocus = !1;
|
|
399
|
-
}, focus: function(
|
|
415
|
+
}, focus: function(a) {
|
|
400
416
|
e.sendButtonFocus = !0;
|
|
401
|
-
}, blur: function(
|
|
417
|
+
}, blur: function(a) {
|
|
402
418
|
e.sendButtonFocus = !1;
|
|
403
419
|
} }, scopedSlots: e._u([e.showSend.icon ? { key: "icon", fn: function() {
|
|
404
420
|
return [i("dt-icon", { attrs: { name: e.showSend.icon, size: "300" } })];
|
|
405
421
|
}, proxy: !0 } : null], null, !0) }, [e.showSend.text ? [i("p", [e._v(e._s(e.showSend.text))])] : e._e()], 2)];
|
|
406
|
-
}, proxy: !0 }], null, !1,
|
|
422
|
+
}, proxy: !0 }], null, !1, 2968465028) }) : e._e()], 1)])], 2);
|
|
407
423
|
}, b = [], k = /* @__PURE__ */ p(
|
|
408
424
|
h,
|
|
409
425
|
g,
|
|
@@ -414,9 +430,9 @@ var g = function() {
|
|
|
414
430
|
null,
|
|
415
431
|
null
|
|
416
432
|
);
|
|
417
|
-
const
|
|
433
|
+
const v = k.exports;
|
|
418
434
|
export {
|
|
419
|
-
|
|
435
|
+
v as DtRecipeMessageInput,
|
|
420
436
|
s as DtRichTextEditor,
|
|
421
437
|
r as RICH_TEXT_EDITOR_AUTOFOCUS_TYPES,
|
|
422
438
|
l as RICH_TEXT_EDITOR_OUTPUT_FORMATS
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { n as ee, g as Ti, d as Ya, u as Xa, e as Qa, P as Za, h as As, i as ec, j as tc, k as nc, l as rc, m as ic, o as sc, p as oc, q as lc, T as Ns, t as sl, r as ac, s as cc } from "./tooltip-88U5vFMA.js";
|
|
2
2
|
import De from "vue";
|
|
3
|
-
import { B as uc, w as hr, I as dc, L as fc, C as hc, t as ol, D as ll, E as pc, m as mc, o as al } from "./index-
|
|
3
|
+
import { B as uc, w as hr, I as dc, L as fc, C as hc, t as ol, D as ll, E as pc, m as mc, o as al } from "./index-OF94C6nQ.js";
|
|
4
4
|
const Lt = {
|
|
5
5
|
BUSY: "busy",
|
|
6
6
|
AWAY: "away",
|
|
@@ -15559,7 +15559,7 @@ const hy = {
|
|
|
15559
15559
|
this.command(e);
|
|
15560
15560
|
return;
|
|
15561
15561
|
case "mention":
|
|
15562
|
-
this.command({ name: e.name, id: e.
|
|
15562
|
+
this.command({ name: e.name, id: e.id, avatarSrc: e.avatarSrc });
|
|
15563
15563
|
break;
|
|
15564
15564
|
}
|
|
15565
15565
|
}
|
|
@@ -16060,7 +16060,7 @@ const qy = Vy.exports, Wy = Fy.extend({
|
|
|
16060
16060
|
};
|
|
16061
16061
|
},
|
|
16062
16062
|
renderText({ node: n }) {
|
|
16063
|
-
return
|
|
16063
|
+
return `@${n.attrs.id}`;
|
|
16064
16064
|
},
|
|
16065
16065
|
renderHTML({ HTMLAttributes: n }) {
|
|
16066
16066
|
return ["mention-component", B(this.options.HTMLAttributes, n), 0];
|
|
@@ -16103,7 +16103,7 @@ const qy = Vy.exports, Wy = Fy.extend({
|
|
|
16103
16103
|
};
|
|
16104
16104
|
var Yy = function() {
|
|
16105
16105
|
var e = this, t = e._self._c;
|
|
16106
|
-
return t("dt-stack", { attrs: { direction: "row", gap: "400" } }, [t("dt-avatar", { attrs: { "full-name": e.name, "image-src": e.avatarSrc, "image-alt":
|
|
16106
|
+
return t("dt-stack", { attrs: { direction: "row", gap: "400" } }, [t("dt-avatar", { attrs: { "full-name": e.name, "image-src": e.avatarSrc, "image-alt": e.name, size: "xs" } }), e._v(" " + e._s(e.name) + " ")], 1);
|
|
16107
16107
|
}, Xy = [], Qy = /* @__PURE__ */ ee(
|
|
16108
16108
|
Gy,
|
|
16109
16109
|
Yy,
|
|
@@ -16118,6 +16118,7 @@ const Zy = Qy.exports, e0 = {
|
|
|
16118
16118
|
// This function comes from the user and passed to the editor directly.
|
|
16119
16119
|
// This will also activate the mention plugin on the editor
|
|
16120
16120
|
// items: ({ query }) => { return [] },
|
|
16121
|
+
allowSpaces: !0,
|
|
16121
16122
|
render: () => {
|
|
16122
16123
|
let n, e;
|
|
16123
16124
|
return {
|
|
@@ -16146,8 +16147,7 @@ const Zy = Qy.exports, e0 = {
|
|
|
16146
16147
|
});
|
|
16147
16148
|
},
|
|
16148
16149
|
onKeyDown(t) {
|
|
16149
|
-
|
|
16150
|
-
return t.event.key === "Escape" ? (e[0].hide(), !0) : (r = n.ref) == null ? void 0 : r.onKeyDown(t);
|
|
16150
|
+
return t.event.key === "Escape" ? (e[0].hide(), !0) : n == null ? void 0 : n.ref.onKeyDown(t);
|
|
16151
16151
|
},
|
|
16152
16152
|
onExit() {
|
|
16153
16153
|
e[0].destroy(), n.destroy();
|