@matechat/core 1.4.0-alpha.1 → 1.4.0-alpha.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.
@@ -0,0 +1,49 @@
1
+ import "./index.css";
2
+ import { Comment as s, Text as a, Fragment as m, h as g, defineComponent as h, ref as v, withDirectives as C, cloneVNode as y } from "vue";
3
+ import { isObject as x } from "@vue/shared";
4
+ function p(e) {
5
+ return g("span", {}, e);
6
+ }
7
+ function c(e) {
8
+ for (const t of e) {
9
+ if (x(t)) {
10
+ if (t.type === s)
11
+ continue;
12
+ return t.type === "svg" || t.type === a ? p(t) : t.type === m ? c(t.children) : t;
13
+ }
14
+ return p(t);
15
+ }
16
+ return null;
17
+ }
18
+ const F = /* @__PURE__ */ h({
19
+ setup(e, t) {
20
+ const {
21
+ slots: r,
22
+ attrs: i,
23
+ expose: d
24
+ } = t, n = v();
25
+ return d({
26
+ triggerEl: n
27
+ }), () => {
28
+ var f;
29
+ const o = (f = r.default) == null ? void 0 : f.call(r, i);
30
+ if (!o)
31
+ return null;
32
+ const l = c(o);
33
+ return l ? C(y(l, i), [[{
34
+ mounted(u) {
35
+ n.value = u;
36
+ },
37
+ updated(u) {
38
+ n.value = u;
39
+ },
40
+ unmounted() {
41
+ n.value = null;
42
+ }
43
+ }]]) : null;
44
+ };
45
+ }
46
+ });
47
+ export {
48
+ F as PopperTrigger
49
+ };
package/mate-chat.js CHANGED
@@ -7,6 +7,7 @@ import { McList } from './List';
7
7
  import { useMcI18n, McLocale } from './Locale';
8
8
  import { McMarkdownCard } from './MarkdownCard';
9
9
  import { McMention } from './Mention';
10
+ import { PopperTrigger } from './PopperTrigger';
10
11
  import { McPrompt } from './Prompt';
11
12
 
12
13
  const installs = [
@@ -19,6 +20,7 @@ const installs = [
19
20
  McLocale,
20
21
  McMarkdownCard,
21
22
  McMention,
23
+ McPopperTrigger,
22
24
  McPrompt
23
25
  ];
24
26
 
@@ -37,6 +39,7 @@ export {
37
39
  McLocale,
38
40
  McMarkdownCard,
39
41
  McMention,
42
+ PopperTrigger,
40
43
  McPrompt
41
44
  };
42
45
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@matechat/core",
3
- "version": "1.4.0-alpha.1",
3
+ "version": "1.4.0-alpha.2",
4
4
  "license": "MIT",
5
5
  "description": "前端智能化场景解决方案UI库,轻松构建你的AI应用。",
6
6
  "keywords": [