prlg-ui 1.8.325 → 1.8.327
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/Image-DxBnhta_.js +195 -0
- package/dist/Image-DyYO6Izz.cjs +1 -0
- package/dist/blocks/index.cjs.js +1 -1
- package/dist/blocks/index.es.js +74 -74
- package/dist/{dayjs.util-w9plG3H0.cjs → dayjs.util-B2JdCXIm.cjs} +1 -1
- package/dist/{dayjs.util-BZJcKPbc.js → dayjs.util-CgY84kVQ.js} +1 -1
- package/dist/eventBus.util-DHkO4j-V.cjs +1 -0
- package/dist/{eventBus.util-msbJpg6N.js → eventBus.util-DjOylFpN.js} +24 -24
- package/dist/{index-DpwRE3qr.js → index-DwbPNNPc.js} +6 -26
- package/dist/{index-Dp7bcaNg.cjs → index-qggSVcEG.cjs} +2 -20
- package/dist/parseFileSize.util-0SyKuE4n.cjs +1 -0
- package/dist/parseFileSize.util-DTzvlV7u.js +641 -0
- package/dist/prlg-ui.cjs.js +1 -1
- package/dist/prlg-ui.css +1 -1
- package/dist/prlg-ui.es.js +2765 -2765
- package/dist/reka-ui/index.cjs.js +5 -5
- package/dist/reka-ui/index.es.js +3117 -3114
- package/dist/rekaUI.d.ts +113 -92
- package/dist/{uploadFile.util-CCrV2jIp.cjs → uploadFile.util-CbQSY2xi.cjs} +1 -1
- package/dist/{uploadFile.util-c_UlO-OQ.js → uploadFile.util-vM81SK0i.js} +1 -1
- package/dist/utils/index.cjs.js +1 -1
- package/dist/utils/index.es.js +4 -4
- package/package.json +1 -1
- package/dist/Image-Ctgju863.js +0 -195
- package/dist/Image-DLJh4B68.cjs +0 -1
- package/dist/eventBus.util-K9Yq6hZm.cjs +0 -1
- package/dist/fonts/Inter/.DS_Store +0 -0
- package/dist/parseFileSize.util-CaHpLGi2.js +0 -758
- package/dist/parseFileSize.util-D9hMoJaT.cjs +0 -1
|
@@ -0,0 +1,195 @@
|
|
|
1
|
+
import { defineComponent as F, useId as x, ref as k, computed as z, onMounted as h, createElementBlock as i, openBlock as t, normalizeClass as p, createCommentVNode as o, createBlock as $, createVNode as I, unref as d, resolveDynamicComponent as M, toDisplayString as _, Teleport as E, Transition as V, withCtx as O, normalizeStyle as T, createElementVNode as m, useTemplateRef as N, Fragment as j } from "vue";
|
|
2
|
+
import { F as D, E as P, W as R, P as W, C, _ as w, a as q } from "./FileIcon-maHE2Nhr.js";
|
|
3
|
+
import { h as B } from "./parseFileSize.util-DTzvlV7u.js";
|
|
4
|
+
import { g as A, u as G } from "./typeFile.util-DerifWNY.js";
|
|
5
|
+
const H = {
|
|
6
|
+
key: 1,
|
|
7
|
+
class: "file__title"
|
|
8
|
+
}, J = {
|
|
9
|
+
key: 2,
|
|
10
|
+
class: "file__info"
|
|
11
|
+
}, K = {
|
|
12
|
+
key: 0,
|
|
13
|
+
class: "file__type"
|
|
14
|
+
}, L = {
|
|
15
|
+
key: 1,
|
|
16
|
+
class: "file__info-separator"
|
|
17
|
+
}, Q = {
|
|
18
|
+
key: 2,
|
|
19
|
+
class: "file__size"
|
|
20
|
+
}, U = /* @__PURE__ */ F({
|
|
21
|
+
__name: "File",
|
|
22
|
+
props: {
|
|
23
|
+
file: {},
|
|
24
|
+
viewName: { type: Boolean, default: !1 },
|
|
25
|
+
outlined: { type: Boolean, default: !0 },
|
|
26
|
+
removable: { type: Boolean }
|
|
27
|
+
},
|
|
28
|
+
emits: ["remove"],
|
|
29
|
+
setup(e, { emit: v }) {
|
|
30
|
+
const u = v, a = x(), l = k(null);
|
|
31
|
+
async function s(r, c = "image") {
|
|
32
|
+
const y = await (await fetch(r)).blob(), b = y.type.split("/")[1] || "", S = b ? `${c}.${b}` : c;
|
|
33
|
+
return new File([y], S, { type: y.type });
|
|
34
|
+
}
|
|
35
|
+
const n = z(() => l.value && l.value.mime ? A(l.value.mime) : null), f = z(() => {
|
|
36
|
+
switch (n.value) {
|
|
37
|
+
case "pdf":
|
|
38
|
+
return W;
|
|
39
|
+
case "word":
|
|
40
|
+
return R;
|
|
41
|
+
case "excel":
|
|
42
|
+
return P;
|
|
43
|
+
case "other":
|
|
44
|
+
default:
|
|
45
|
+
return D;
|
|
46
|
+
}
|
|
47
|
+
});
|
|
48
|
+
return h(async () => {
|
|
49
|
+
if (typeof e.file == "string") {
|
|
50
|
+
const r = await s(e.file);
|
|
51
|
+
l.value = {
|
|
52
|
+
id: a,
|
|
53
|
+
url: e.file,
|
|
54
|
+
name: r.name,
|
|
55
|
+
mime: r.type,
|
|
56
|
+
size: r.size
|
|
57
|
+
};
|
|
58
|
+
} else
|
|
59
|
+
l.value = e.file;
|
|
60
|
+
}), (r, c) => (t(), i("div", {
|
|
61
|
+
class: p(["file", { "file--outlined": e.outlined }])
|
|
62
|
+
}, [
|
|
63
|
+
e.removable && typeof e.file != "string" ? (t(), i("button", {
|
|
64
|
+
key: 0,
|
|
65
|
+
class: "file__remove",
|
|
66
|
+
onClick: c[0] || (c[0] = (g) => u("remove", e.file))
|
|
67
|
+
}, [
|
|
68
|
+
I(d(C))
|
|
69
|
+
])) : o("", !0),
|
|
70
|
+
(t(), $(M(f.value), { class: "file__icon" })),
|
|
71
|
+
l.value && l.value.name && e.viewName ? (t(), i("div", H, _(l.value ? l.value.name.split(".")[0] : "unknown"), 1)) : o("", !0),
|
|
72
|
+
l.value ? (t(), i("div", J, [
|
|
73
|
+
l.value.mime ? (t(), i("div", K, _(n.value), 1)) : o("", !0),
|
|
74
|
+
l.value.mime && l.value.size ? (t(), i("div", L)) : o("", !0),
|
|
75
|
+
l.value.size ? (t(), i("div", Q, _(l.value ? d(B)(l.value.size) : "0 Б"), 1)) : o("", !0)
|
|
76
|
+
])) : o("", !0)
|
|
77
|
+
], 2));
|
|
78
|
+
}
|
|
79
|
+
}), re = /* @__PURE__ */ w(U, [["__scopeId", "data-v-7c3d1c11"]]), X = { class: "image-full-modal__wrapper" }, Y = { class: "image-full-modal__header" }, Z = { class: "image-full-modal__main" }, ee = ["src", "alt"], le = /* @__PURE__ */ F({
|
|
80
|
+
__name: "ImageFullModal",
|
|
81
|
+
props: {
|
|
82
|
+
src: {},
|
|
83
|
+
alt: {}
|
|
84
|
+
},
|
|
85
|
+
setup(e, { expose: v }) {
|
|
86
|
+
const u = k(!1), { zIndex: a } = G("modal");
|
|
87
|
+
return v({
|
|
88
|
+
open: () => {
|
|
89
|
+
u.value = !0;
|
|
90
|
+
},
|
|
91
|
+
close: () => {
|
|
92
|
+
u.value = !1;
|
|
93
|
+
}
|
|
94
|
+
}), (l, s) => (t(), $(E, { to: "body" }, [
|
|
95
|
+
I(V, { name: "fade" }, {
|
|
96
|
+
default: O(() => [
|
|
97
|
+
u.value ? (t(), i("div", {
|
|
98
|
+
key: 0,
|
|
99
|
+
class: "image-full-modal",
|
|
100
|
+
style: T({ zIndex: d(a)?.zIndex })
|
|
101
|
+
}, [
|
|
102
|
+
m("div", {
|
|
103
|
+
class: "image-full-modal__overlay",
|
|
104
|
+
onClick: s[0] || (s[0] = (n) => u.value = !1)
|
|
105
|
+
}),
|
|
106
|
+
m("div", X, [
|
|
107
|
+
m("div", Y, [
|
|
108
|
+
m("button", {
|
|
109
|
+
class: "image-full-modal__close",
|
|
110
|
+
onClick: s[1] || (s[1] = (n) => u.value = !1)
|
|
111
|
+
}, [
|
|
112
|
+
I(d(C))
|
|
113
|
+
])
|
|
114
|
+
]),
|
|
115
|
+
m("div", Z, [
|
|
116
|
+
m("img", {
|
|
117
|
+
src: e.src,
|
|
118
|
+
alt: e.alt
|
|
119
|
+
}, null, 8, ee)
|
|
120
|
+
]),
|
|
121
|
+
s[2] || (s[2] = m("div", { class: "image-full-modal__footer" }, null, -1))
|
|
122
|
+
])
|
|
123
|
+
], 4)) : o("", !0)
|
|
124
|
+
]),
|
|
125
|
+
_: 1
|
|
126
|
+
})
|
|
127
|
+
]));
|
|
128
|
+
}
|
|
129
|
+
}), te = /* @__PURE__ */ w(le, [["__scopeId", "data-v-26b5c867"]]), ae = ["src", "alt"], ie = {
|
|
130
|
+
key: 1,
|
|
131
|
+
class: "image__info"
|
|
132
|
+
}, se = {
|
|
133
|
+
key: 0,
|
|
134
|
+
class: "image__size"
|
|
135
|
+
}, ne = /* @__PURE__ */ F({
|
|
136
|
+
__name: "Image",
|
|
137
|
+
props: {
|
|
138
|
+
file: {},
|
|
139
|
+
alt: {},
|
|
140
|
+
size: { default: "medium" },
|
|
141
|
+
fullScreen: { type: Boolean },
|
|
142
|
+
viewInfo: { type: Boolean, default: !1 }
|
|
143
|
+
},
|
|
144
|
+
setup(e) {
|
|
145
|
+
const v = x(), u = N("imageFullModal"), a = k(null);
|
|
146
|
+
async function l(n, f = "image") {
|
|
147
|
+
const c = await (await fetch(n)).blob(), g = c.type.split("/")[1] || "", y = g ? `${f}.${g}` : f;
|
|
148
|
+
return new File([c], y, { type: c.type });
|
|
149
|
+
}
|
|
150
|
+
const s = z(() => typeof e.file == "string" ? e.file : e.file.url);
|
|
151
|
+
return h(async () => {
|
|
152
|
+
if (e.viewInfo)
|
|
153
|
+
if (typeof e.file == "string") {
|
|
154
|
+
const n = await l(e.file);
|
|
155
|
+
a.value = {
|
|
156
|
+
id: v,
|
|
157
|
+
url: e.file,
|
|
158
|
+
name: n.name,
|
|
159
|
+
mime: n.type,
|
|
160
|
+
size: n.size
|
|
161
|
+
};
|
|
162
|
+
} else
|
|
163
|
+
a.value = e.file;
|
|
164
|
+
}), (n, f) => (t(), i(j, null, [
|
|
165
|
+
m("div", {
|
|
166
|
+
class: p(["image", `image--${e.size}`, { "image--full-screen": e.fullScreen }])
|
|
167
|
+
}, [
|
|
168
|
+
e.fullScreen ? (t(), i("div", {
|
|
169
|
+
key: 0,
|
|
170
|
+
class: "image__overlay",
|
|
171
|
+
onClick: f[0] || (f[0] = (r) => u.value?.open())
|
|
172
|
+
}, [
|
|
173
|
+
I(d(q))
|
|
174
|
+
])) : o("", !0),
|
|
175
|
+
m("img", {
|
|
176
|
+
src: s.value,
|
|
177
|
+
alt: e.alt
|
|
178
|
+
}, null, 8, ae),
|
|
179
|
+
e.viewInfo && a.value && (a.value.mime || a.value.size) && e.size === "large" ? (t(), i("div", ie, [
|
|
180
|
+
a.value.size ? (t(), i("div", se, _(a.value ? d(B)(a.value.size) : "0 Б"), 1)) : o("", !0)
|
|
181
|
+
])) : o("", !0)
|
|
182
|
+
], 2),
|
|
183
|
+
e.fullScreen ? (t(), $(te, {
|
|
184
|
+
key: 0,
|
|
185
|
+
ref: "imageFullModal",
|
|
186
|
+
src: s.value,
|
|
187
|
+
alt: e.alt
|
|
188
|
+
}, null, 8, ["src", "alt"])) : o("", !0)
|
|
189
|
+
], 64));
|
|
190
|
+
}
|
|
191
|
+
}), fe = /* @__PURE__ */ w(ne, [["__scopeId", "data-v-903c99cc"]]);
|
|
192
|
+
export {
|
|
193
|
+
re as F,
|
|
194
|
+
fe as I
|
|
195
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const e=require("vue"),i=require("./FileIcon-BE4ItwkK.cjs"),y=require("./parseFileSize.util-0SyKuE4n.cjs"),k=require("./typeFile.util-CwOoIMBz.cjs"),B={key:1,class:"file__title"},p={key:2,class:"file__info"},_={key:0,class:"file__type"},I={key:1,class:"file__info-separator"},V={key:2,class:"file__size"},z=e.defineComponent({__name:"File",props:{file:{},viewName:{type:Boolean,default:!1},outlined:{type:Boolean,default:!0},removable:{type:Boolean}},emits:["remove"],setup(l,{emit:u}){const c=u,o=e.useId(),t=e.ref(null);async function n(r,s="image"){const d=await(await fetch(r)).blob(),v=d.type.split("/")[1]||"",g=v?`${s}.${v}`:s;return new File([d],g,{type:d.type})}const a=e.computed(()=>t.value&&t.value.mime?k.getFileTypeByMime(t.value.mime):null),m=e.computed(()=>{switch(a.value){case"pdf":return i.PdfIcon;case"word":return i.WordIcon;case"excel":return i.ExcelIcon;case"other":default:return i.FileIcon}});return e.onMounted(async()=>{if(typeof l.file=="string"){const r=await n(l.file);t.value={id:o,url:l.file,name:r.name,mime:r.type,size:r.size}}else t.value=l.file}),(r,s)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["file",{"file--outlined":l.outlined}])},[l.removable&&typeof l.file!="string"?(e.openBlock(),e.createElementBlock("button",{key:0,class:"file__remove",onClick:s[0]||(s[0]=f=>c("remove",l.file))},[e.createVNode(e.unref(i.CloseIcon))])):e.createCommentVNode("",!0),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(m.value),{class:"file__icon"})),t.value&&t.value.name&&l.viewName?(e.openBlock(),e.createElementBlock("div",B,e.toDisplayString(t.value?t.value.name.split(".")[0]:"unknown"),1)):e.createCommentVNode("",!0),t.value?(e.openBlock(),e.createElementBlock("div",p,[t.value.mime?(e.openBlock(),e.createElementBlock("div",_,e.toDisplayString(a.value),1)):e.createCommentVNode("",!0),t.value.mime&&t.value.size?(e.openBlock(),e.createElementBlock("div",I)):e.createCommentVNode("",!0),t.value.size?(e.openBlock(),e.createElementBlock("div",V,e.toDisplayString(t.value?e.unref(y.formatFileSize)(t.value.size):"0 Б"),1)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)],2))}}),C=i._export_sfc(z,[["__scopeId","data-v-7c3d1c11"]]),N={class:"image-full-modal__wrapper"},E={class:"image-full-modal__header"},F={class:"image-full-modal__main"},$=["src","alt"],w=e.defineComponent({__name:"ImageFullModal",props:{src:{},alt:{}},setup(l,{expose:u}){const c=e.ref(!1),{zIndex:o}=k.useOverlay("modal");return u({open:()=>{c.value=!0},close:()=>{c.value=!1}}),(t,n)=>(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"fade"},{default:e.withCtx(()=>[c.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:"image-full-modal",style:e.normalizeStyle({zIndex:e.unref(o)?.zIndex})},[e.createElementVNode("div",{class:"image-full-modal__overlay",onClick:n[0]||(n[0]=a=>c.value=!1)}),e.createElementVNode("div",N,[e.createElementVNode("div",E,[e.createElementVNode("button",{class:"image-full-modal__close",onClick:n[1]||(n[1]=a=>c.value=!1)},[e.createVNode(e.unref(i.CloseIcon))])]),e.createElementVNode("div",F,[e.createElementVNode("img",{src:l.src,alt:l.alt},null,8,$)]),n[2]||(n[2]=e.createElementVNode("div",{class:"image-full-modal__footer"},null,-1))])],4)):e.createCommentVNode("",!0)]),_:1})]))}}),b=i._export_sfc(w,[["__scopeId","data-v-26b5c867"]]),x=["src","alt"],S={key:1,class:"image__info"},h={key:0,class:"image__size"},M=e.defineComponent({__name:"Image",props:{file:{},alt:{},size:{default:"medium"},fullScreen:{type:Boolean},viewInfo:{type:Boolean,default:!1}},setup(l){const u=e.useId(),c=e.useTemplateRef("imageFullModal"),o=e.ref(null);async function t(a,m="image"){const s=await(await fetch(a)).blob(),f=s.type.split("/")[1]||"",d=f?`${m}.${f}`:m;return new File([s],d,{type:s.type})}const n=e.computed(()=>typeof l.file=="string"?l.file:l.file.url);return e.onMounted(async()=>{if(l.viewInfo)if(typeof l.file=="string"){const a=await t(l.file);o.value={id:u,url:l.file,name:a.name,mime:a.type,size:a.size}}else o.value=l.file}),(a,m)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",{class:e.normalizeClass(["image",`image--${l.size}`,{"image--full-screen":l.fullScreen}])},[l.fullScreen?(e.openBlock(),e.createElementBlock("div",{key:0,class:"image__overlay",onClick:m[0]||(m[0]=r=>c.value?.open())},[e.createVNode(e.unref(i.EyeIcon))])):e.createCommentVNode("",!0),e.createElementVNode("img",{src:n.value,alt:l.alt},null,8,x),l.viewInfo&&o.value&&(o.value.mime||o.value.size)&&l.size==="large"?(e.openBlock(),e.createElementBlock("div",S,[o.value.size?(e.openBlock(),e.createElementBlock("div",h,e.toDisplayString(o.value?e.unref(y.formatFileSize)(o.value.size):"0 Б"),1)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)],2),l.fullScreen?(e.openBlock(),e.createBlock(b,{key:0,ref:"imageFullModal",src:n.value,alt:l.alt},null,8,["src","alt"])):e.createCommentVNode("",!0)],64))}}),D=i._export_sfc(M,[["__scopeId","data-v-903c99cc"]]);exports.File=C;exports.Image=D;
|
package/dist/blocks/index.cjs.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),f=require("../Image-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),f=require("../Image-DyYO6Izz.cjs"),m=require("../FileIcon-BE4ItwkK.cjs"),v=require("../typeFile.util-CwOoIMBz.cjs"),u=require("../SendIcon-CH6S0QWh.cjs"),h=require("../dayjs.util-B2JdCXIm.cjs"),k=require("../uploadFile.util-CbQSY2xi.cjs"),g={class:"chat-file__content"},B=e.defineComponent({__name:"ChatFile",props:{file:{}},emits:["deleteFile"],setup(t,{emit:n}){const i=n,s=e.computed(()=>URL.createObjectURL(t.file));return(l,c)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["chat-file",{"chat-file--image":e.unref(v.getFileTypeByMime)(t.file.type)==="image"}])},[e.createElementVNode("button",{class:"chat-file__delete",onClick:c[0]||(c[0]=r=>i("deleteFile",t.file))},[e.createVNode(e.unref(m.CloseIcon))]),e.createElementVNode("div",g,[e.unref(v.getFileTypeByMime)(t.file.type)==="image"?(e.openBlock(),e.createBlock(e.unref(f.Image),{key:0,file:s.value,size:"large",fullScreen:""},null,8,["file"])):(e.openBlock(),e.createBlock(e.unref(f.File),{key:1,file:s.value,outlined:!1},null,8,["file"]))])],2))}}),y=m._export_sfc(B,[["__scopeId","data-v-12b8458b"]]),_={class:"chat-field-actions"},b={ref:"overlay",class:"chat-field-actions__overlay"},C=["onClick"],x={class:"chat-field-actions__overlay-item__label"},V=["disabled"],p=e.defineComponent({__name:"ChatFieldActions",props:e.mergeModels({actions:{},disabled:{type:Boolean,default:!1},multiple:{type:Boolean,default:!0}},{modelValue:{},modelModifiers:{}}),emits:["update:modelValue"],setup(t){const n=e.useModel(t,"modelValue"),i=e.useTemplateRef("button"),s=e.useTemplateRef("overlay"),l=e.ref(!1),c=e.reactive({image:{icon:e.shallowRef(u.ImageIcon),label:"Добавить изображение"},file:{icon:e.shallowRef(m.FileIcon),label:"Добавить файл"}}),r=o=>{k.openFileDialog({accept:o==="image"?["image"]:["pdf","excel","word"],maxFileSize:"5mb",maxFiles:1}).then(a=>{n.value?n.value=t.multiple?[...n.value,...a]:a:n.value=[...a],l.value=!1})};return e.onMounted(()=>{h.onClickOutside(s.value,()=>{l.value=!1},{ignore:[i.value]})}),(o,a)=>(e.openBlock(),e.createElementBlock("div",_,[e.createVNode(e.Transition,{name:"slide-up"},{default:e.withCtx(()=>[e.withDirectives(e.createElementVNode("div",b,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.actions,d=>(e.openBlock(),e.createElementBlock("div",{class:"chat-field-actions__overlay-item",key:d,onClick:D=>r(d)},[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(c[d].icon),{class:"chat-field-actions__overlay-item__icon"})),e.createElementVNode("span",x,e.toDisplayString(c[d].label),1)],8,C))),128))],512),[[e.vShow,l.value]])]),_:1}),e.createElementVNode("button",{ref:"button",onClick:a[0]||(a[0]=d=>l.value=!l.value),class:e.normalizeClass(["chat-field-actions__button",{"chat-field-actions__button--active":l.value}]),disabled:t.disabled},[e.createVNode(e.unref(u.PlusRoundedIcon))],10,V)]))}}),F=m._export_sfc(p,[["__scopeId","data-v-62b95e1b"]]),E={class:"chat-field"},N={key:0,class:"chat-field__files"},M={class:"chat-field__wrapper"},T=["maxlength","placeholder"],$={key:1,class:"chat-field__footer"},I={key:1,class:"chat-field__char-count"},S=e.defineComponent({__name:"ChatField",props:e.mergeModels({viewActions:{type:Boolean,default:!1},actions:{default:()=>["file","image"]},placeholder:{default:"Введите сообщение"},maxLength:{},smallText:{},error:{type:Boolean},errorText:{},disabled:{type:Boolean,default:!1}},{message:{required:!0},messageModifiers:{},files:{},filesModifiers:{}}),emits:e.mergeModels(["sendMessage"],["update:message","update:files"]),setup(t,{emit:n}){const i=n,s=e.useModel(t,"message"),l=e.useModel(t,"files"),c=r=>{l.value&&(l.value=l.value.filter(o=>o.name!==r.name))};return(r,o)=>(e.openBlock(),e.createElementBlock("div",E,[l.value&&l.value.length>0?(e.openBlock(),e.createElementBlock("div",N,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.value,a=>(e.openBlock(),e.createBlock(y,{key:a.name,file:a,onDeleteFile:c},null,8,["file"]))),128))])):e.createCommentVNode("",!0),e.createElementVNode("div",M,[t.viewActions&&t.actions.length>0?(e.openBlock(),e.createBlock(F,{key:0,modelValue:l.value,"onUpdate:modelValue":o[0]||(o[0]=a=>l.value=a),actions:t.actions,disabled:t.disabled},null,8,["modelValue","actions","disabled"])):e.createCommentVNode("",!0),e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":o[1]||(o[1]=a=>s.value=a),class:"chat-field__input",maxlength:t.maxLength,placeholder:t.placeholder},null,8,T),[[e.vModelText,s.value]]),e.createElementVNode("button",{class:"chat-field__button",onClick:o[2]||(o[2]=a=>i("sendMessage"))},[e.createVNode(e.unref(u.SendIcon))])]),t.smallText||t.error&&t.errorText||t.maxLength?(e.openBlock(),e.createElementBlock("div",$,[t.smallText||t.error&&t.errorText?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["chat-field__small",{"chat-field__small--error":t.error}])},e.toDisplayString(t.error?t.errorText:t.smallText),3)):e.createCommentVNode("",!0),t.maxLength?(e.openBlock(),e.createElementBlock("div",I,e.toDisplayString(s.value.length)+" / "+e.toDisplayString(t.maxLength),1)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)]))}}),w={class:"bonus-summary"},L=e.defineComponent({__name:"BonusSummary",setup(t){return(n,i)=>(e.openBlock(),e.createElementBlock("div",w,[e.createVNode(e.unref(u.BonusIcon),{class:"bonus-summary__icon"}),i[0]||(i[0]=e.createElementVNode("div",{class:"bonus-summary__number"},"123",-1))]))}});exports.BonusSummary=L;exports.ChatField=S;
|
package/dist/blocks/index.es.js
CHANGED
|
@@ -1,36 +1,36 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { I as
|
|
1
|
+
import { defineComponent as y, computed as V, createElementBlock as i, openBlock as l, normalizeClass as C, unref as u, createElementVNode as n, createVNode as h, createBlock as _, mergeModels as b, useModel as x, useTemplateRef as F, ref as L, reactive as w, shallowRef as k, onMounted as S, Transition as R, withCtx as p, withDirectives as B, Fragment as I, renderList as T, resolveDynamicComponent as D, toDisplayString as g, vShow as U, createCommentVNode as v, vModelText as z } from "vue";
|
|
2
|
+
import { I as N, F as O } from "../Image-DxBnhta_.js";
|
|
3
3
|
import { C as A, _ as M, F as E } from "../FileIcon-maHE2Nhr.js";
|
|
4
4
|
import { g as $ } from "../typeFile.util-DerifWNY.js";
|
|
5
5
|
import { I as P, P as j, S as q, B as H } from "../SendIcon-Cqdt2QWN.js";
|
|
6
|
-
import { o as G } from "../dayjs.util-
|
|
7
|
-
import { o as J } from "../uploadFile.util-
|
|
8
|
-
const K = { class: "chat-file__content" }, Q = /* @__PURE__ */
|
|
6
|
+
import { o as G } from "../dayjs.util-CgY84kVQ.js";
|
|
7
|
+
import { o as J } from "../uploadFile.util-vM81SK0i.js";
|
|
8
|
+
const K = { class: "chat-file__content" }, Q = /* @__PURE__ */ y({
|
|
9
9
|
__name: "ChatFile",
|
|
10
10
|
props: {
|
|
11
11
|
file: {}
|
|
12
12
|
},
|
|
13
13
|
emits: ["deleteFile"],
|
|
14
|
-
setup(
|
|
15
|
-
const
|
|
16
|
-
return (
|
|
17
|
-
class: C(["chat-file", { "chat-file--image":
|
|
14
|
+
setup(e, { emit: o }) {
|
|
15
|
+
const c = o, d = V(() => URL.createObjectURL(e.file));
|
|
16
|
+
return (t, r) => (l(), i("div", {
|
|
17
|
+
class: C(["chat-file", { "chat-file--image": u($)(e.file.type) === "image" }])
|
|
18
18
|
}, [
|
|
19
19
|
n("button", {
|
|
20
20
|
class: "chat-file__delete",
|
|
21
|
-
onClick:
|
|
21
|
+
onClick: r[0] || (r[0] = (m) => c("deleteFile", e.file))
|
|
22
22
|
}, [
|
|
23
|
-
|
|
23
|
+
h(u(A))
|
|
24
24
|
]),
|
|
25
25
|
n("div", K, [
|
|
26
|
-
|
|
26
|
+
u($)(e.file.type) === "image" ? (l(), _(u(N), {
|
|
27
27
|
key: 0,
|
|
28
|
-
file:
|
|
28
|
+
file: d.value,
|
|
29
29
|
size: "large",
|
|
30
30
|
fullScreen: ""
|
|
31
|
-
}, null, 8, ["file"])) : (
|
|
31
|
+
}, null, 8, ["file"])) : (l(), _(u(O), {
|
|
32
32
|
key: 1,
|
|
33
|
-
file:
|
|
33
|
+
file: d.value,
|
|
34
34
|
outlined: !1
|
|
35
35
|
}, null, 8, ["file"]))
|
|
36
36
|
])
|
|
@@ -39,9 +39,9 @@ const K = { class: "chat-file__content" }, Q = /* @__PURE__ */ g({
|
|
|
39
39
|
}), W = /* @__PURE__ */ M(Q, [["__scopeId", "data-v-12b8458b"]]), X = { class: "chat-field-actions" }, Y = {
|
|
40
40
|
ref: "overlay",
|
|
41
41
|
class: "chat-field-actions__overlay"
|
|
42
|
-
}, Z = ["onClick"], ee = { class: "chat-field-actions__overlay-item__label" },
|
|
42
|
+
}, Z = ["onClick"], ee = { class: "chat-field-actions__overlay-item__label" }, te = ["disabled"], le = /* @__PURE__ */ y({
|
|
43
43
|
__name: "ChatFieldActions",
|
|
44
|
-
props: /* @__PURE__ */
|
|
44
|
+
props: /* @__PURE__ */ b({
|
|
45
45
|
actions: {},
|
|
46
46
|
disabled: { type: Boolean, default: !1 },
|
|
47
47
|
multiple: { type: Boolean, default: !0 }
|
|
@@ -50,8 +50,8 @@ const K = { class: "chat-file__content" }, Q = /* @__PURE__ */ g({
|
|
|
50
50
|
modelModifiers: {}
|
|
51
51
|
}),
|
|
52
52
|
emits: ["update:modelValue"],
|
|
53
|
-
setup(
|
|
54
|
-
const
|
|
53
|
+
setup(e) {
|
|
54
|
+
const o = x(e, "modelValue"), c = F("button"), d = F("overlay"), t = L(!1), r = w({
|
|
55
55
|
image: {
|
|
56
56
|
icon: k(P),
|
|
57
57
|
label: "Добавить изображение"
|
|
@@ -60,59 +60,59 @@ const K = { class: "chat-file__content" }, Q = /* @__PURE__ */ g({
|
|
|
60
60
|
icon: k(E),
|
|
61
61
|
label: "Добавить файл"
|
|
62
62
|
}
|
|
63
|
-
}),
|
|
63
|
+
}), m = (s) => {
|
|
64
64
|
J({
|
|
65
65
|
accept: s === "image" ? ["image"] : ["pdf", "excel", "word"],
|
|
66
66
|
maxFileSize: "5mb",
|
|
67
67
|
maxFiles: 1
|
|
68
|
-
}).then((
|
|
69
|
-
|
|
68
|
+
}).then((a) => {
|
|
69
|
+
o.value ? o.value = e.multiple ? [...o.value, ...a] : a : o.value = [...a], t.value = !1;
|
|
70
70
|
});
|
|
71
71
|
};
|
|
72
72
|
return S(() => {
|
|
73
|
-
G(
|
|
74
|
-
|
|
75
|
-
}, { ignore: [
|
|
76
|
-
}), (s,
|
|
77
|
-
|
|
78
|
-
default:
|
|
73
|
+
G(d.value, () => {
|
|
74
|
+
t.value = !1;
|
|
75
|
+
}, { ignore: [c.value] });
|
|
76
|
+
}), (s, a) => (l(), i("div", X, [
|
|
77
|
+
h(R, { name: "slide-up" }, {
|
|
78
|
+
default: p(() => [
|
|
79
79
|
B(n("div", Y, [
|
|
80
|
-
(
|
|
80
|
+
(l(!0), i(I, null, T(e.actions, (f) => (l(), i("div", {
|
|
81
81
|
class: "chat-field-actions__overlay-item",
|
|
82
82
|
key: f,
|
|
83
|
-
onClick: (
|
|
83
|
+
onClick: (re) => m(f)
|
|
84
84
|
}, [
|
|
85
|
-
(
|
|
86
|
-
n("span", ee,
|
|
85
|
+
(l(), _(D(r[f].icon), { class: "chat-field-actions__overlay-item__icon" })),
|
|
86
|
+
n("span", ee, g(r[f].label), 1)
|
|
87
87
|
], 8, Z))), 128))
|
|
88
88
|
], 512), [
|
|
89
|
-
[
|
|
89
|
+
[U, t.value]
|
|
90
90
|
])
|
|
91
91
|
]),
|
|
92
92
|
_: 1
|
|
93
93
|
}),
|
|
94
94
|
n("button", {
|
|
95
95
|
ref: "button",
|
|
96
|
-
onClick:
|
|
97
|
-
class: C(["chat-field-actions__button", { "chat-field-actions__button--active":
|
|
98
|
-
disabled:
|
|
96
|
+
onClick: a[0] || (a[0] = (f) => t.value = !t.value),
|
|
97
|
+
class: C(["chat-field-actions__button", { "chat-field-actions__button--active": t.value }]),
|
|
98
|
+
disabled: e.disabled
|
|
99
99
|
}, [
|
|
100
|
-
|
|
101
|
-
], 10,
|
|
100
|
+
h(u(j))
|
|
101
|
+
], 10, te)
|
|
102
102
|
]));
|
|
103
103
|
}
|
|
104
|
-
}),
|
|
104
|
+
}), ae = /* @__PURE__ */ M(le, [["__scopeId", "data-v-62b95e1b"]]), se = { class: "chat-field" }, ie = {
|
|
105
105
|
key: 0,
|
|
106
106
|
class: "chat-field__files"
|
|
107
|
-
},
|
|
107
|
+
}, oe = { class: "chat-field__wrapper" }, ne = ["maxlength", "placeholder"], ce = {
|
|
108
108
|
key: 1,
|
|
109
109
|
class: "chat-field__footer"
|
|
110
110
|
}, de = {
|
|
111
111
|
key: 1,
|
|
112
112
|
class: "chat-field__char-count"
|
|
113
|
-
},
|
|
113
|
+
}, be = /* @__PURE__ */ y({
|
|
114
114
|
__name: "ChatField",
|
|
115
|
-
props: /* @__PURE__ */
|
|
115
|
+
props: /* @__PURE__ */ b({
|
|
116
116
|
viewActions: { type: Boolean, default: !1 },
|
|
117
117
|
actions: { default: () => ["file", "image"] },
|
|
118
118
|
placeholder: { default: "Введите сообщение" },
|
|
@@ -127,61 +127,61 @@ const K = { class: "chat-file__content" }, Q = /* @__PURE__ */ g({
|
|
|
127
127
|
files: {},
|
|
128
128
|
filesModifiers: {}
|
|
129
129
|
}),
|
|
130
|
-
emits: /* @__PURE__ */
|
|
131
|
-
setup(
|
|
132
|
-
const
|
|
133
|
-
|
|
130
|
+
emits: /* @__PURE__ */ b(["sendMessage"], ["update:message", "update:files"]),
|
|
131
|
+
setup(e, { emit: o }) {
|
|
132
|
+
const c = o, d = x(e, "message"), t = x(e, "files"), r = (m) => {
|
|
133
|
+
t.value && (t.value = t.value.filter((s) => s.name !== m.name));
|
|
134
134
|
};
|
|
135
|
-
return (
|
|
136
|
-
|
|
137
|
-
(
|
|
138
|
-
key:
|
|
139
|
-
file:
|
|
140
|
-
onDeleteFile:
|
|
135
|
+
return (m, s) => (l(), i("div", se, [
|
|
136
|
+
t.value && t.value.length > 0 ? (l(), i("div", ie, [
|
|
137
|
+
(l(!0), i(I, null, T(t.value, (a) => (l(), _(W, {
|
|
138
|
+
key: a.name,
|
|
139
|
+
file: a,
|
|
140
|
+
onDeleteFile: r
|
|
141
141
|
}, null, 8, ["file"]))), 128))
|
|
142
|
-
])) :
|
|
143
|
-
n("div",
|
|
144
|
-
e.viewActions && e.actions.length > 0 ? (
|
|
142
|
+
])) : v("", !0),
|
|
143
|
+
n("div", oe, [
|
|
144
|
+
e.viewActions && e.actions.length > 0 ? (l(), _(ae, {
|
|
145
145
|
key: 0,
|
|
146
|
-
modelValue:
|
|
147
|
-
"onUpdate:modelValue": s[0] || (s[0] = (
|
|
146
|
+
modelValue: t.value,
|
|
147
|
+
"onUpdate:modelValue": s[0] || (s[0] = (a) => t.value = a),
|
|
148
148
|
actions: e.actions,
|
|
149
149
|
disabled: e.disabled
|
|
150
|
-
}, null, 8, ["modelValue", "actions", "disabled"])) :
|
|
150
|
+
}, null, 8, ["modelValue", "actions", "disabled"])) : v("", !0),
|
|
151
151
|
B(n("input", {
|
|
152
|
-
"onUpdate:modelValue": s[1] || (s[1] = (
|
|
152
|
+
"onUpdate:modelValue": s[1] || (s[1] = (a) => d.value = a),
|
|
153
153
|
class: "chat-field__input",
|
|
154
154
|
maxlength: e.maxLength,
|
|
155
155
|
placeholder: e.placeholder
|
|
156
156
|
}, null, 8, ne), [
|
|
157
|
-
[
|
|
157
|
+
[z, d.value]
|
|
158
158
|
]),
|
|
159
159
|
n("button", {
|
|
160
160
|
class: "chat-field__button",
|
|
161
|
-
onClick: s[2] || (s[2] = (
|
|
161
|
+
onClick: s[2] || (s[2] = (a) => c("sendMessage"))
|
|
162
162
|
}, [
|
|
163
|
-
|
|
163
|
+
h(u(q))
|
|
164
164
|
])
|
|
165
165
|
]),
|
|
166
|
-
e.smallText || e.error && e.errorText || e.maxLength ? (
|
|
167
|
-
e.smallText || e.error && e.errorText ? (
|
|
166
|
+
e.smallText || e.error && e.errorText || e.maxLength ? (l(), i("div", ce, [
|
|
167
|
+
e.smallText || e.error && e.errorText ? (l(), i("div", {
|
|
168
168
|
key: 0,
|
|
169
169
|
class: C(["chat-field__small", { "chat-field__small--error": e.error }])
|
|
170
|
-
},
|
|
171
|
-
e.maxLength ? (
|
|
172
|
-
])) :
|
|
170
|
+
}, g(e.error ? e.errorText : e.smallText), 3)) : v("", !0),
|
|
171
|
+
e.maxLength ? (l(), i("div", de, g(d.value.length) + " / " + g(e.maxLength), 1)) : v("", !0)
|
|
172
|
+
])) : v("", !0)
|
|
173
173
|
]));
|
|
174
174
|
}
|
|
175
|
-
}), ue = { class: "bonus-summary" },
|
|
175
|
+
}), ue = { class: "bonus-summary" }, xe = /* @__PURE__ */ y({
|
|
176
176
|
__name: "BonusSummary",
|
|
177
|
-
setup(
|
|
178
|
-
return (
|
|
179
|
-
|
|
180
|
-
|
|
177
|
+
setup(e) {
|
|
178
|
+
return (o, c) => (l(), i("div", ue, [
|
|
179
|
+
h(u(H), { class: "bonus-summary__icon" }),
|
|
180
|
+
c[0] || (c[0] = n("div", { class: "bonus-summary__number" }, "123", -1))
|
|
181
181
|
]));
|
|
182
182
|
}
|
|
183
183
|
});
|
|
184
184
|
export {
|
|
185
|
-
|
|
186
|
-
|
|
185
|
+
xe as BonusSummary,
|
|
186
|
+
be as ChatField
|
|
187
187
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const l=require("vue"),e=require("./parseFileSize.util-
|
|
1
|
+
"use strict";const l=require("vue"),e=require("./parseFileSize.util-0SyKuE4n.cjs"),u=new WeakMap;function m(n){const o=l.unref(n);return o?.$el??o}function p(n){return typeof n=="string"?document.querySelector(n):m(n)}function g(n,o,f={}){const r=p(n);if(!r)return()=>{};const d=u.get(r);d&&(d(),u.delete(r));const s=a=>{const i=a.target instanceof Node?a.target:null;if(!i)return;const y=(l.toValue(f.ignore)??[]).map(t=>typeof t=="string"?document.querySelector(t):m(t)).filter(t=>t!=null);r.contains(i)||y.some(t=>t.contains(i))||o(a)};document.addEventListener("mousedown",s,{capture:!0}),document.addEventListener("touchstart",s,{capture:!0});const c=()=>{document.removeEventListener("mousedown",s,{capture:!0}),document.removeEventListener("touchstart",s,{capture:!0}),u.delete(r)};return u.set(r,c),c}e.dayjs.extend(e.localizedFormat);e.dayjs.extend(e.relativeTime);e.dayjs.extend(e.isToday);e.dayjs.extend(e.isBetween);e.dayjs.extend(e.isSameOrBefore);e.dayjs.extend(e.isSameOrAfter);e.dayjs.extend(e.duration);e.dayjs.extend(e.customParseFormat);e.dayjs.extend(e.dayOfYear);e.dayjs.locale("ru");exports.onClickOutside=g;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { toValue as p, unref as g } from "vue";
|
|
2
|
-
import { d as e, l as x, r as v, i as y, a as E, b as w, c as L, e as O, f as S, g as T } from "./parseFileSize.util-
|
|
2
|
+
import { d as e, l as x, r as v, i as y, a as E, b as w, c as L, e as O, f as S, g as T } from "./parseFileSize.util-DTzvlV7u.js";
|
|
3
3
|
const a = /* @__PURE__ */ new WeakMap();
|
|
4
4
|
function m(n) {
|
|
5
5
|
const o = g(n);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const l=require("vue");let r=null,c=0;function a(){const e=window.scrollY;return document.body.style.position="fixed",document.body.style.top=`-${e}px`,()=>{document.body.style.position="",document.body.style.top="",window.scrollTo(0,e)}}const d=()=>{c++,c===1&&!r&&(r=a())},u=()=>{c>0&&c--,c===0&&r&&(r(),r=null)},i=()=>({unlockScroll:u,lockScroll:d}),f=["data-layer"],y=l.defineComponent({__name:"Portal",props:{overlayType:{default:"modal"},teleport:{type:Boolean,default:!0},target:{default:"body"},zIndex:{},show:{type:Boolean,default:!0},parentId:{}},setup(e){const t=e,n=l.computed(()=>{if(t.zIndex)return t.zIndex});return(o,s)=>e.show?(l.openBlock(),l.createBlock(l.Teleport,{key:0,to:e.target,disabled:!e.teleport},[l.createElementVNode("div",{style:l.normalizeStyle({zIndex:n.value,position:"relative",isolation:"isolate"}),"data-layer":e.overlayType},[l.renderSlot(o.$slots,"default")],12,f)],8,["to","disabled"])):l.createCommentVNode("",!0)}});function p(){const e=new Map;return{on(t,n){const o=e.get(t)||[];o.push(n),e.set(t,o)},off(t,n){const o=e.get(t);o&&e.set(t,o.filter(s=>s!==n))},emit(t,n){const o=e.get(t);o&&o.forEach(s=>s(n))},clear(){e.clear()}}}exports.EventBus=p;exports._sfc_main=y;exports.useBodyScroll=i;
|
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
import { defineComponent as
|
|
1
|
+
import { defineComponent as s, computed as c, createBlock as d, createCommentVNode as i, openBlock as u, Teleport as f, createElementVNode as p, normalizeStyle as y, renderSlot as m } from "vue";
|
|
2
2
|
let n = null, r = 0;
|
|
3
3
|
function S() {
|
|
4
|
-
const
|
|
5
|
-
return document.body.style.position = "fixed", document.body.style.top = `-${
|
|
6
|
-
document.body.style.position = "", document.body.style.top = "", window.scrollTo(0,
|
|
4
|
+
const e = window.scrollY;
|
|
5
|
+
return document.body.style.position = "fixed", document.body.style.top = `-${e}px`, () => {
|
|
6
|
+
document.body.style.position = "", document.body.style.top = "", window.scrollTo(0, e);
|
|
7
7
|
};
|
|
8
8
|
}
|
|
9
9
|
const h = () => {
|
|
10
10
|
r++, r === 1 && !n && (n = S());
|
|
11
11
|
}, b = () => {
|
|
12
12
|
r > 0 && r--, r === 0 && n && (n(), n = null);
|
|
13
|
-
},
|
|
13
|
+
}, x = () => ({
|
|
14
14
|
unlockScroll: b,
|
|
15
15
|
lockScroll: h
|
|
16
|
-
}), v = ["data-layer"],
|
|
16
|
+
}), v = ["data-layer"], k = /* @__PURE__ */ s({
|
|
17
17
|
__name: "Portal",
|
|
18
18
|
props: {
|
|
19
19
|
overlayType: { default: "modal" },
|
|
@@ -23,16 +23,16 @@ const h = () => {
|
|
|
23
23
|
show: { type: Boolean, default: !0 },
|
|
24
24
|
parentId: {}
|
|
25
25
|
},
|
|
26
|
-
setup(
|
|
27
|
-
const t =
|
|
26
|
+
setup(e) {
|
|
27
|
+
const t = e, l = c(() => {
|
|
28
28
|
if (t.zIndex) return t.zIndex;
|
|
29
29
|
});
|
|
30
|
-
return (
|
|
30
|
+
return (o, a) => e.show ? (u(), d(f, {
|
|
31
31
|
key: 0,
|
|
32
32
|
to: e.target,
|
|
33
33
|
disabled: !e.teleport
|
|
34
34
|
}, [
|
|
35
|
-
|
|
35
|
+
p("div", {
|
|
36
36
|
style: y({
|
|
37
37
|
zIndex: l.value,
|
|
38
38
|
position: "relative",
|
|
@@ -40,36 +40,36 @@ const h = () => {
|
|
|
40
40
|
}),
|
|
41
41
|
"data-layer": e.overlayType
|
|
42
42
|
}, [
|
|
43
|
-
m(
|
|
43
|
+
m(o.$slots, "default")
|
|
44
44
|
], 12, v)
|
|
45
45
|
], 8, ["to", "disabled"])) : i("", !0);
|
|
46
46
|
}
|
|
47
47
|
});
|
|
48
|
-
function
|
|
49
|
-
const
|
|
48
|
+
function B() {
|
|
49
|
+
const e = /* @__PURE__ */ new Map();
|
|
50
50
|
return {
|
|
51
51
|
on(t, l) {
|
|
52
|
-
const
|
|
53
|
-
|
|
52
|
+
const o = e.get(t) || [];
|
|
53
|
+
o.push(l), e.set(t, o);
|
|
54
54
|
},
|
|
55
55
|
off(t, l) {
|
|
56
|
-
const
|
|
57
|
-
|
|
56
|
+
const o = e.get(t);
|
|
57
|
+
o && e.set(
|
|
58
58
|
t,
|
|
59
|
-
|
|
59
|
+
o.filter((a) => a !== l)
|
|
60
60
|
);
|
|
61
61
|
},
|
|
62
62
|
emit(t, l) {
|
|
63
|
-
const
|
|
64
|
-
|
|
63
|
+
const o = e.get(t);
|
|
64
|
+
o && o.forEach((a) => a(l));
|
|
65
65
|
},
|
|
66
66
|
clear() {
|
|
67
|
-
|
|
67
|
+
e.clear();
|
|
68
68
|
}
|
|
69
69
|
};
|
|
70
70
|
}
|
|
71
71
|
export {
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
72
|
+
B as E,
|
|
73
|
+
k as _,
|
|
74
|
+
x as u
|
|
75
75
|
};
|