pptx-vue-viewer 2.13.0 → 2.13.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/CHANGELOG.md +12 -0
- package/dist/{AiChatPanel-B8Ql84M5.cjs → AiChatPanel-CtoBtOtB.cjs} +143 -139
- package/dist/AiChatPanel-CtoBtOtB.cjs.br +0 -0
- package/dist/AiChatPanel-CtoBtOtB.cjs.gz +0 -0
- package/dist/AiChatPanel-xSeCJVHJ.js +512 -0
- package/dist/AiChatPanel-xSeCJVHJ.js.br +0 -0
- package/dist/AiChatPanel-xSeCJVHJ.js.gz +0 -0
- package/dist/{dist-Pa1hVhzE.cjs → dist-CNLUj2f9.cjs} +6474 -6381
- package/dist/dist-CNLUj2f9.cjs.br +0 -0
- package/dist/dist-CNLUj2f9.cjs.gz +0 -0
- package/dist/{dist-CkupeMQB.js → dist-CrzKtRxp.js} +6374 -6281
- package/dist/dist-CrzKtRxp.js.br +0 -0
- package/dist/dist-CrzKtRxp.js.gz +0 -0
- package/dist/gif-encoder-N24YqPHj.js +2 -0
- package/dist/gif-encoder-N24YqPHj.js.br +0 -0
- package/dist/gif-encoder-N24YqPHj.js.gz +0 -0
- package/dist/gif-encoder-xPQiQFxW.cjs +2 -0
- package/dist/gif-encoder-xPQiQFxW.cjs.br +0 -0
- package/dist/gif-encoder-xPQiQFxW.cjs.gz +0 -0
- package/dist/index.cjs +1 -1
- package/dist/index.cjs.br +0 -0
- package/dist/index.cjs.gz +0 -0
- package/dist/index.js +3 -3
- package/dist/index.js.br +0 -0
- package/dist/index.js.gz +0 -0
- package/dist/internals.cjs +1 -1
- package/dist/internals.cjs.br +0 -0
- package/dist/internals.cjs.gz +0 -0
- package/dist/internals.js +2 -2
- package/dist/internals.js.br +0 -0
- package/dist/internals.js.gz +0 -0
- package/dist/{useViewerSettingsDialog-CY1t9MEH.cjs → useViewerSettingsDialog-BSsouEGv.cjs} +4023 -3940
- package/dist/useViewerSettingsDialog-BSsouEGv.cjs.br +0 -0
- package/dist/useViewerSettingsDialog-BSsouEGv.cjs.gz +0 -0
- package/dist/{useViewerSettingsDialog-B-QhCt02.js → useViewerSettingsDialog-CiRnHsjC.js} +3554 -3486
- package/dist/useViewerSettingsDialog-CiRnHsjC.js.br +0 -0
- package/dist/useViewerSettingsDialog-CiRnHsjC.js.gz +0 -0
- package/dist/viewer/components/ElementMediaBox.vue.d.ts.map +1 -1
- package/dist/viewer/components/PresentationMode.vue.d.ts.map +1 -1
- package/dist/viewer/components/ai/AiChatPanel.vue.d.ts.map +1 -1
- package/dist/viewer/components/ai/AiConversation.vue.d.ts.map +1 -1
- package/dist/viewer/composables/ai/useAiConversation.d.ts +3 -1
- package/dist/viewer/composables/ai/useAiConversation.d.ts.map +1 -1
- package/dist/viewer/composables/cross-slide-audio.d.ts +12 -0
- package/dist/viewer/composables/cross-slide-audio.d.ts.map +1 -0
- package/dist/viewer/composables/usePresentationVisibilityPause.d.ts +11 -0
- package/dist/viewer/composables/usePresentationVisibilityPause.d.ts.map +1 -0
- package/dist/viewer/composables/useSlideAutoAdvance.d.ts +7 -0
- package/dist/viewer/composables/useSlideAutoAdvance.d.ts.map +1 -1
- package/dist/viewer/index.cjs +1 -1
- package/dist/viewer/index.cjs.br +0 -0
- package/dist/viewer/index.cjs.gz +0 -0
- package/dist/viewer/index.js +3 -3
- package/dist/viewer/index.js.br +0 -0
- package/dist/viewer/index.js.gz +0 -0
- package/dist/{viewer-Bq3ngZeA.js → viewer-BVGVczOF.js} +9387 -9360
- package/dist/viewer-BVGVczOF.js.br +0 -0
- package/dist/viewer-BVGVczOF.js.gz +0 -0
- package/dist/{viewer-SRdb6B8w.cjs → viewer-CKGNkLtj.cjs} +5448 -5421
- package/dist/viewer-CKGNkLtj.cjs.br +0 -0
- package/dist/viewer-CKGNkLtj.cjs.gz +0 -0
- package/package.json +2 -2
- package/dist/AiChatPanel-B8Ql84M5.cjs.br +0 -0
- package/dist/AiChatPanel-B8Ql84M5.cjs.gz +0 -0
- package/dist/AiChatPanel-Pd17JAHM.js +0 -509
- package/dist/AiChatPanel-Pd17JAHM.js.br +0 -0
- package/dist/AiChatPanel-Pd17JAHM.js.gz +0 -0
- package/dist/dist-CkupeMQB.js.br +0 -0
- package/dist/dist-CkupeMQB.js.gz +0 -0
- package/dist/dist-Pa1hVhzE.cjs.br +0 -0
- package/dist/dist-Pa1hVhzE.cjs.gz +0 -0
- package/dist/gif-encoder-BclZ9xjR.cjs +0 -2
- package/dist/gif-encoder-BclZ9xjR.cjs.br +0 -0
- package/dist/gif-encoder-BclZ9xjR.cjs.gz +0 -0
- package/dist/gif-encoder-DNWK0lM2.js +0 -2
- package/dist/gif-encoder-DNWK0lM2.js.br +0 -0
- package/dist/gif-encoder-DNWK0lM2.js.gz +0 -0
- package/dist/useViewerSettingsDialog-B-QhCt02.js.br +0 -0
- package/dist/useViewerSettingsDialog-B-QhCt02.js.gz +0 -0
- package/dist/useViewerSettingsDialog-CY1t9MEH.cjs.br +0 -0
- package/dist/useViewerSettingsDialog-CY1t9MEH.cjs.gz +0 -0
- package/dist/viewer-Bq3ngZeA.js.br +0 -0
- package/dist/viewer-Bq3ngZeA.js.gz +0 -0
- package/dist/viewer-SRdb6B8w.cjs.br +0 -0
- package/dist/viewer-SRdb6B8w.cjs.gz +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,18 @@ All notable changes to this project are documented here.
|
|
|
4
4
|
This file is generated from [Conventional Commits](https://www.conventionalcommits.org)
|
|
5
5
|
by [git-cliff](https://git-cliff.org); do not edit it by hand.
|
|
6
6
|
|
|
7
|
+
## [2.13.1](https://github.com/ChristopherVR/pptx-viewer/releases/tag/pptx-vue-viewer@2.13.1) - 2026-08-05
|
|
8
|
+
|
|
9
|
+
### Dependencies
|
|
10
|
+
|
|
11
|
+
- **deps:** Bump ai from 7.0.48 to 7.0.44 ([#134](https://github.com/ChristopherVR/pptx-viewer/issues/134)) (by @dependabot[bot]) ([08a13e0](https://github.com/ChristopherVR/pptx-viewer/commit/08a13e076caa6d97e22bd706e57657407aef1dd8))
|
|
12
|
+
|
|
13
|
+
### Chores
|
|
14
|
+
|
|
15
|
+
- **deps-dev:** Update vite requirement from ^8.1.5 to ^8.2.0 ([#135](https://github.com/ChristopherVR/pptx-viewer/issues/135)) (by @dependabot[bot]) ([1e7e296](https://github.com/ChristopherVR/pptx-viewer/commit/1e7e2965eff8635dfa8b94fa196b89ed1d0fd0c7))
|
|
16
|
+
|
|
17
|
+
## [2.13.0](https://github.com/ChristopherVR/pptx-viewer/releases/tag/pptx-vue-viewer@2.13.0) - 2026-08-01
|
|
18
|
+
|
|
7
19
|
## [2.12.1](https://github.com/ChristopherVR/pptx-viewer/releases/tag/pptx-vue-viewer@2.12.1) - 2026-08-01
|
|
8
20
|
|
|
9
21
|
## [2.12.0](https://github.com/ChristopherVR/pptx-viewer/releases/tag/pptx-vue-viewer@2.12.0) - 2026-08-01
|
|
@@ -1,29 +1,29 @@
|
|
|
1
|
-
const e = require("./useViewerSettingsDialog-
|
|
2
|
-
let r = require("vue"), o = require("lucide-vue-next"), a = require("
|
|
3
|
-
var
|
|
1
|
+
const e = require("./useViewerSettingsDialog-BSsouEGv.cjs"), t = require("./viewer-CKGNkLtj.cjs");
|
|
2
|
+
let r = require("vue"), o = require("lucide-vue-next"), a = require("ai");
|
|
3
|
+
var n = /* @__PURE__ */ new Set([
|
|
4
4
|
"input-available",
|
|
5
5
|
"output-available",
|
|
6
6
|
"output-error"
|
|
7
7
|
]);
|
|
8
|
-
function
|
|
9
|
-
const i = (0, r.ref)(
|
|
10
|
-
i.value =
|
|
11
|
-
}, p = (
|
|
12
|
-
transport:
|
|
13
|
-
sendAutomaticallyWhen:
|
|
14
|
-
onError: (e) =>
|
|
15
|
-
onToolCall: async ({ toolCall:
|
|
16
|
-
const { toolName:
|
|
8
|
+
function l(e, o, l, s = {}) {
|
|
9
|
+
const i = (0, r.ref)(o.proposals.list()), c = () => {
|
|
10
|
+
i.value = o.proposals.list();
|
|
11
|
+
}, p = e({
|
|
12
|
+
transport: o.transport,
|
|
13
|
+
sendAutomaticallyWhen: o.sendAutomaticallyWhen,
|
|
14
|
+
onError: (e) => l.onError?.(e),
|
|
15
|
+
onToolCall: async ({ toolCall: e }) => {
|
|
16
|
+
const { toolName: t, toolCallId: r, input: a } = e, n = p.addToolOutput;
|
|
17
17
|
try {
|
|
18
18
|
n({
|
|
19
|
-
tool:
|
|
20
|
-
toolCallId:
|
|
21
|
-
output: await
|
|
19
|
+
tool: t,
|
|
20
|
+
toolCallId: r,
|
|
21
|
+
output: await o.executeToolCall(t, a)
|
|
22
22
|
});
|
|
23
23
|
} catch (e) {
|
|
24
24
|
n({
|
|
25
|
-
tool:
|
|
26
|
-
toolCallId:
|
|
25
|
+
tool: t,
|
|
26
|
+
toolCallId: r,
|
|
27
27
|
state: "output-error",
|
|
28
28
|
errorText: e instanceof Error ? e.message : String(e)
|
|
29
29
|
});
|
|
@@ -35,10 +35,10 @@ function s(e, o, s = {}) {
|
|
|
35
35
|
for (const r of function(e) {
|
|
36
36
|
const t = [];
|
|
37
37
|
for (const r of e) for (const e of r.parts) {
|
|
38
|
-
if (!(0,
|
|
38
|
+
if (!(0, a.isToolUIPart)(e) && !(0, a.isDynamicToolUIPart)(e)) continue;
|
|
39
39
|
const r = e, o = r.toolCallId ?? "";
|
|
40
|
-
0 !== o.length && void 0 !== r.input &&
|
|
41
|
-
toolName: (0,
|
|
40
|
+
0 !== o.length && void 0 !== r.input && n.has(r.state ?? "") && t.push({
|
|
41
|
+
toolName: (0, a.getToolOrDynamicToolName)(e),
|
|
42
42
|
toolCallId: o,
|
|
43
43
|
input: r.input
|
|
44
44
|
});
|
|
@@ -60,22 +60,22 @@ function s(e, o, s = {}) {
|
|
|
60
60
|
p.stop();
|
|
61
61
|
},
|
|
62
62
|
clearError: () => p.clearError(),
|
|
63
|
-
applyProposal: (
|
|
64
|
-
|
|
63
|
+
applyProposal: (e) => {
|
|
64
|
+
o.proposals.apply(e), c();
|
|
65
65
|
},
|
|
66
|
-
rejectProposal: (
|
|
67
|
-
|
|
66
|
+
rejectProposal: (e) => {
|
|
67
|
+
o.proposals.revert(e), c();
|
|
68
68
|
},
|
|
69
69
|
acceptAllProposals: () => {
|
|
70
|
-
|
|
70
|
+
o.proposals.acceptAll(), c();
|
|
71
71
|
}
|
|
72
72
|
};
|
|
73
73
|
}
|
|
74
|
-
var
|
|
74
|
+
var s = { class: "border-t border-border p-2" }, i = { class: "flex items-end gap-1.5 rounded-md border border-input bg-background px-2 py-1.5 focus-within:border-ring" }, c = ["placeholder", "aria-label"], p = ["title", "aria-label"], u = [
|
|
75
75
|
"disabled",
|
|
76
76
|
"title",
|
|
77
77
|
"aria-label"
|
|
78
|
-
],
|
|
78
|
+
], d = (0, r.defineComponent)({
|
|
79
79
|
__name: "AiComposer",
|
|
80
80
|
props: {
|
|
81
81
|
isStreaming: { type: Boolean },
|
|
@@ -84,17 +84,17 @@ var i = { class: "border-t border-border p-2" }, c = { class: "flex items-end ga
|
|
|
84
84
|
},
|
|
85
85
|
emits: ["send", "stop"],
|
|
86
86
|
setup(a, { emit: n }) {
|
|
87
|
-
const l = a,
|
|
87
|
+
const l = a, d = n, { t: m } = e.useI18n(), f = (0, r.ref)(""), x = (0, r.ref)(null), g = (0, r.computed)(() => f.value.trim().length > 0);
|
|
88
88
|
function k() {
|
|
89
89
|
const e = f.value.trim();
|
|
90
|
-
0 === e.length || l.isStreaming || (
|
|
90
|
+
0 === e.length || l.isStreaming || (d("send", e), f.value = "");
|
|
91
91
|
}
|
|
92
92
|
function y(e) {
|
|
93
93
|
"Enter" !== e.key || e.shiftKey || (e.preventDefault(), k());
|
|
94
94
|
}
|
|
95
95
|
return (0, r.watch)(() => l.prefillNonce, (e) => {
|
|
96
96
|
void 0 !== e && 0 !== e && (l.prefillText && (f.value = l.prefillText), (0, r.nextTick)(() => x.value?.focus()));
|
|
97
|
-
}), (e, a) => ((0, r.openBlock)(), (0, r.createElementBlock)("div",
|
|
97
|
+
}), (e, a) => ((0, r.openBlock)(), (0, r.createElementBlock)("div", s, [(0, r.createElementVNode)("div", i, [(0, r.withDirectives)((0, r.createElementVNode)("textarea", {
|
|
98
98
|
ref_key: "textareaRef",
|
|
99
99
|
ref: x,
|
|
100
100
|
"onUpdate:modelValue": a[0] || (a[0] = (e) => f.value = e),
|
|
@@ -103,14 +103,14 @@ var i = { class: "border-t border-border p-2" }, c = { class: "flex items-end ga
|
|
|
103
103
|
"aria-label": (0, r.unref)(m)("pptx.ai.placeholder"),
|
|
104
104
|
class: "max-h-32 min-h-[1.5rem] flex-1 resize-none bg-transparent text-[13px] text-foreground outline-none placeholder:text-muted-foreground",
|
|
105
105
|
onKeydown: y
|
|
106
|
-
}, null, 40,
|
|
106
|
+
}, null, 40, c), [[r.vModelText, f.value]]), l.isStreaming ? ((0, r.openBlock)(), (0, r.createElementBlock)("button", {
|
|
107
107
|
key: 0,
|
|
108
108
|
type: "button",
|
|
109
109
|
title: (0, r.unref)(m)("pptx.ai.stop"),
|
|
110
110
|
"aria-label": (0, r.unref)(m)("pptx.ai.stop"),
|
|
111
111
|
class: "shrink-0 rounded-sm p-1.5 text-muted-foreground transition-colors hover:bg-accent",
|
|
112
|
-
onClick: a[1] || (a[1] = (e) =>
|
|
113
|
-
}, [(0, r.createVNode)((0, r.unref)(o.Square), { class: "w-4 h-4" })], 8,
|
|
112
|
+
onClick: a[1] || (a[1] = (e) => d("stop"))
|
|
113
|
+
}, [(0, r.createVNode)((0, r.unref)(o.Square), { class: "w-4 h-4" })], 8, p)) : ((0, r.openBlock)(), (0, r.createElementBlock)("button", {
|
|
114
114
|
key: 1,
|
|
115
115
|
type: "button",
|
|
116
116
|
disabled: !g.value,
|
|
@@ -118,19 +118,19 @@ var i = { class: "border-t border-border p-2" }, c = { class: "flex items-end ga
|
|
|
118
118
|
"aria-label": (0, r.unref)(m)("pptx.ai.send"),
|
|
119
119
|
class: (0, r.normalizeClass)((0, r.unref)(t.cn)("shrink-0 rounded-sm p-1.5 transition-colors", g.value ? "bg-primary text-primary-foreground hover:bg-primary/90" : "text-muted-foreground/50")),
|
|
120
120
|
onClick: k
|
|
121
|
-
}, [(0, r.createVNode)((0, r.unref)(o.Send), { class: "w-4 h-4" })], 10,
|
|
121
|
+
}, [(0, r.createVNode)((0, r.unref)(o.Send), { class: "w-4 h-4" })], 10, u))])]));
|
|
122
122
|
}
|
|
123
|
-
}),
|
|
123
|
+
}), m = { class: "border-b border-border bg-secondary/30" }, f = { class: "flex flex-wrap items-center gap-1 px-2.5 py-1.5" }, x = { class: "text-[10px] font-semibold uppercase tracking-wide text-muted-foreground" }, g = ["title"], k = { class: "truncate" }, y = {
|
|
124
124
|
key: 0,
|
|
125
125
|
class: "rounded-full bg-primary/15 px-1.5 py-0.5 text-[10px] font-medium text-primary"
|
|
126
|
-
},
|
|
126
|
+
}, b = { class: "ml-auto flex items-center gap-0.5" }, v = [
|
|
127
127
|
"title",
|
|
128
128
|
"aria-label",
|
|
129
129
|
"aria-pressed"
|
|
130
|
-
],
|
|
130
|
+
], h = ["title", "aria-label"], B = ["title", "aria-label"], E = {
|
|
131
131
|
key: 0,
|
|
132
132
|
class: "flex items-center gap-2 border-t border-primary/20 bg-primary/5 px-2.5 py-1"
|
|
133
|
-
},
|
|
133
|
+
}, N = { class: "text-[11px] font-medium text-primary" }, C = (0, r.defineComponent)({
|
|
134
134
|
__name: "AiFocusBar",
|
|
135
135
|
props: {
|
|
136
136
|
targets: {},
|
|
@@ -153,15 +153,15 @@ var i = { class: "border-t border-border p-2" }, c = { class: "flex items-end ga
|
|
|
153
153
|
const e = p.value;
|
|
154
154
|
e && s("send-directive", `Merge the two selected tables (elementIdA=${e.elementIdA}, elementIdB=${e.elementIdB}) on slide ${e.slideIndex + 1} using merge_tables; stage it now, do not ask me to confirm.`);
|
|
155
155
|
}
|
|
156
|
-
return (e, n) => ((0, r.openBlock)(), (0, r.createElementBlock)("div",
|
|
157
|
-
(0, r.createElementVNode)("span",
|
|
156
|
+
return (e, n) => ((0, r.openBlock)(), (0, r.createElementBlock)("div", m, [(0, r.createElementVNode)("div", f, [
|
|
157
|
+
(0, r.createElementVNode)("span", x, (0, r.toDisplayString)((0, r.unref)(i)("pptx.ai.focusScope")), 1),
|
|
158
158
|
((0, r.openBlock)(!0), (0, r.createElementBlock)(r.Fragment, null, (0, r.renderList)(c.value, (e) => ((0, r.openBlock)(), (0, r.createElementBlock)("span", {
|
|
159
159
|
key: e.key,
|
|
160
160
|
class: (0, r.normalizeClass)((0, r.unref)(t.cn)("inline-flex max-w-[10rem] items-center rounded-full px-2 py-0.5 text-[11px]", a.hasPicks || a.isPinned ? "bg-primary/15 text-primary" : "bg-muted text-muted-foreground")),
|
|
161
161
|
title: e.title
|
|
162
|
-
}, [(0, r.createElementVNode)("span",
|
|
163
|
-
a.isPinned ? ((0, r.openBlock)(), (0, r.createElementBlock)("span",
|
|
164
|
-
(0, r.createElementVNode)("div",
|
|
162
|
+
}, [(0, r.createElementVNode)("span", k, (0, r.toDisplayString)(e.label), 1)], 10, g))), 128)),
|
|
163
|
+
a.isPinned ? ((0, r.openBlock)(), (0, r.createElementBlock)("span", y, (0, r.toDisplayString)((0, r.unref)(i)("pptx.ai.pinnedFocus")), 1)) : (0, r.createCommentVNode)("", !0),
|
|
164
|
+
(0, r.createElementVNode)("div", b, [
|
|
165
165
|
p.value ? ((0, r.openBlock)(), (0, r.createElementBlock)("button", {
|
|
166
166
|
key: 0,
|
|
167
167
|
type: "button",
|
|
@@ -175,7 +175,7 @@ var i = { class: "border-t border-border p-2" }, c = { class: "flex items-end ga
|
|
|
175
175
|
"aria-pressed": a.pickMode,
|
|
176
176
|
class: (0, r.normalizeClass)((0, r.unref)(t.cn)("rounded-sm p-1", a.pickMode ? "bg-primary text-primary-foreground" : "text-muted-foreground hover:bg-accent")),
|
|
177
177
|
onClick: n[0] || (n[0] = (e) => a.pickMode ? s("stop-pick") : s("start-pick"))
|
|
178
|
-
}, [(0, r.createVNode)((0, r.unref)(o.Crosshair), { class: "w-3.5 h-3.5" })], 10,
|
|
178
|
+
}, [(0, r.createVNode)((0, r.unref)(o.Crosshair), { class: "w-3.5 h-3.5" })], 10, v),
|
|
179
179
|
a.hasPicks ? ((0, r.openBlock)(), (0, r.createElementBlock)("button", {
|
|
180
180
|
key: 1,
|
|
181
181
|
type: "button",
|
|
@@ -183,7 +183,7 @@ var i = { class: "border-t border-border p-2" }, c = { class: "flex items-end ga
|
|
|
183
183
|
"aria-label": (0, r.unref)(i)("pptx.ai.pickClear"),
|
|
184
184
|
class: "rounded-sm p-1 text-muted-foreground hover:bg-accent",
|
|
185
185
|
onClick: n[1] || (n[1] = (e) => s("clear-picks"))
|
|
186
|
-
}, [(0, r.createVNode)((0, r.unref)(o.X), { class: "w-3.5 h-3.5" })], 8,
|
|
186
|
+
}, [(0, r.createVNode)((0, r.unref)(o.X), { class: "w-3.5 h-3.5" })], 8, h)) : ((0, r.openBlock)(), (0, r.createElementBlock)("button", {
|
|
187
187
|
key: 2,
|
|
188
188
|
type: "button",
|
|
189
189
|
title: a.isPinned ? (0, r.unref)(i)("pptx.ai.clearFocus") : (0, r.unref)(i)("pptx.ai.pinFocus"),
|
|
@@ -196,11 +196,11 @@ var i = { class: "border-t border-border p-2" }, c = { class: "flex items-end ga
|
|
|
196
196
|
})) : ((0, r.openBlock)(), (0, r.createBlock)((0, r.unref)(o.Pin), {
|
|
197
197
|
key: 1,
|
|
198
198
|
class: "w-3.5 h-3.5"
|
|
199
|
-
}))], 8,
|
|
199
|
+
}))], 8, B))
|
|
200
200
|
])
|
|
201
|
-
]), a.pickMode ? ((0, r.openBlock)(), (0, r.createElementBlock)("div",
|
|
201
|
+
]), a.pickMode ? ((0, r.openBlock)(), (0, r.createElementBlock)("div", E, [
|
|
202
202
|
(0, r.createVNode)((0, r.unref)(o.Crosshair), { class: "w-3.5 h-3.5 shrink-0 animate-pulse text-primary" }),
|
|
203
|
-
(0, r.createElementVNode)("span",
|
|
203
|
+
(0, r.createElementVNode)("span", N, (0, r.toDisplayString)((0, r.unref)(i)("pptx.ai.pickElementHint")), 1),
|
|
204
204
|
(0, r.createElementVNode)("button", {
|
|
205
205
|
type: "button",
|
|
206
206
|
class: "ml-auto rounded-sm bg-primary px-2 py-0.5 text-[11px] font-medium text-primary-foreground hover:bg-primary/90",
|
|
@@ -208,13 +208,13 @@ var i = { class: "border-t border-border p-2" }, c = { class: "flex items-end ga
|
|
|
208
208
|
}, (0, r.toDisplayString)((0, r.unref)(i)("pptx.ai.pickDone")), 1)
|
|
209
209
|
])) : (0, r.createCommentVNode)("", !0)]));
|
|
210
210
|
}
|
|
211
|
-
}),
|
|
211
|
+
}), V = { class: "text-[12px]" }, w = { class: "flex items-center gap-1.5" }, S = {
|
|
212
212
|
key: 0,
|
|
213
213
|
class: "mt-1 pl-5 text-[11px] text-destructive"
|
|
214
|
-
},
|
|
214
|
+
}, P = {
|
|
215
215
|
key: 1,
|
|
216
216
|
class: "group mt-0.5 pl-5"
|
|
217
|
-
},
|
|
217
|
+
}, T = { class: "cursor-pointer list-none text-[10px] text-muted-foreground/70 hover:text-muted-foreground" }, D = { class: "mt-0.5 break-words font-mono text-[10px] text-muted-foreground/80" }, A = (0, r.defineComponent)({
|
|
218
218
|
__name: "AiToolCallCard",
|
|
219
219
|
props: { part: {} },
|
|
220
220
|
setup(a) {
|
|
@@ -234,8 +234,8 @@ var i = { class: "border-t border-border p-2" }, c = { class: "flex items-end ga
|
|
|
234
234
|
notes: o.StickyNote,
|
|
235
235
|
tool: o.Wrench
|
|
236
236
|
}, i = (0, r.computed)(() => "output-error" === n.part.state), c = (0, r.computed)(() => "output-available" === n.part.state), p = (0, r.computed)(() => !i.value && !c.value), u = (0, r.computed)(() => t.describeToolActivity(n.part.toolName, n.part.input, p.value ? "present" : "past")), d = (0, r.computed)(() => s[u.value.icon] ?? o.Wrench), m = (0, r.computed)(() => t.summarizeToolArgs(n.part.input)), f = (0, r.computed)(() => i.value ? l("pptx.ai.toolFailed") : c.value ? l("pptx.ai.toolDone") : l("pptx.ai.toolRunning"));
|
|
237
|
-
return (e, a) => ((0, r.openBlock)(), (0, r.createElementBlock)("div",
|
|
238
|
-
(0, r.createElementVNode)("div",
|
|
237
|
+
return (e, a) => ((0, r.openBlock)(), (0, r.createElementBlock)("div", V, [
|
|
238
|
+
(0, r.createElementVNode)("div", w, [
|
|
239
239
|
((0, r.openBlock)(), (0, r.createBlock)((0, r.resolveDynamicComponent)(d.value), { class: (0, r.normalizeClass)((0, r.unref)(t.cn)("w-3.5 h-3.5 shrink-0", i.value ? "text-destructive" : "text-muted-foreground")) }, null, 8, ["class"])),
|
|
240
240
|
(0, r.createElementVNode)("span", { class: (0, r.normalizeClass)((0, r.unref)(t.cn)("truncate", i.value ? "text-destructive" : "text-foreground")) }, (0, r.toDisplayString)(u.value.label), 3),
|
|
241
241
|
(0, r.createElementVNode)("span", { class: (0, r.normalizeClass)((0, r.unref)(t.cn)("ml-auto inline-flex items-center gap-1 rounded-sm px-1.5 py-0.5 text-[10px]", i.value ? "bg-destructive/15 text-destructive" : c.value ? "bg-primary/10 text-primary" : "bg-muted text-muted-foreground")) }, [p.value ? ((0, r.openBlock)(), (0, r.createBlock)((0, r.unref)(o.LoaderCircle), {
|
|
@@ -249,26 +249,26 @@ var i = { class: "border-t border-border p-2" }, c = { class: "flex items-end ga
|
|
|
249
249
|
class: "w-3 h-3"
|
|
250
250
|
})), (0, r.createTextVNode)(" " + (0, r.toDisplayString)(f.value), 1)], 2)
|
|
251
251
|
]),
|
|
252
|
-
i.value && n.part.errorText ? ((0, r.openBlock)(), (0, r.createElementBlock)("div",
|
|
253
|
-
m.value ? ((0, r.openBlock)(), (0, r.createElementBlock)("details",
|
|
252
|
+
i.value && n.part.errorText ? ((0, r.openBlock)(), (0, r.createElementBlock)("div", S, (0, r.toDisplayString)(n.part.errorText), 1)) : (0, r.createCommentVNode)("", !0),
|
|
253
|
+
m.value ? ((0, r.openBlock)(), (0, r.createElementBlock)("details", P, [(0, r.createElementVNode)("summary", T, (0, r.toDisplayString)((0, r.unref)(l)("pptx.ai.toolDetails")), 1), (0, r.createElementVNode)("div", D, (0, r.toDisplayString)((0, r.unref)(t.toolLabel)(n.part.toolName)) + ": " + (0, r.toDisplayString)(m.value), 1)])) : (0, r.createCommentVNode)("", !0)
|
|
254
254
|
]));
|
|
255
255
|
}
|
|
256
|
-
}),
|
|
256
|
+
}), I = {
|
|
257
257
|
key: 0,
|
|
258
258
|
class: "flex flex-1 flex-col items-center justify-center gap-2 px-6 text-center"
|
|
259
|
-
},
|
|
259
|
+
}, F = { class: "text-sm font-medium text-foreground" }, _ = { class: "text-[12px] text-muted-foreground" }, j = {
|
|
260
260
|
key: 1,
|
|
261
261
|
class: "flex-1 space-y-3 overflow-y-auto px-3 py-3"
|
|
262
|
-
},
|
|
262
|
+
}, z = {
|
|
263
263
|
key: 0,
|
|
264
264
|
class: "flex gap-2"
|
|
265
|
-
}, L = ["aria-label"],
|
|
265
|
+
}, L = ["aria-label"], M = { class: "min-w-0 flex-1 space-y-1.5" }, R = {
|
|
266
266
|
key: 0,
|
|
267
267
|
class: "whitespace-pre-wrap break-words text-[13px] leading-relaxed text-foreground"
|
|
268
268
|
}, W = {
|
|
269
269
|
key: 0,
|
|
270
270
|
class: "flex items-center gap-2 pl-8 text-[12px] text-muted-foreground"
|
|
271
|
-
},
|
|
271
|
+
}, q = (0, r.defineComponent)({
|
|
272
272
|
__name: "AiMessageList",
|
|
273
273
|
props: {
|
|
274
274
|
messages: {},
|
|
@@ -278,12 +278,12 @@ var i = { class: "border-t border-border p-2" }, c = { class: "flex items-end ga
|
|
|
278
278
|
const n = a, { t: l } = e.useI18n(), s = (0, r.ref)(null);
|
|
279
279
|
return (0, r.watch)(() => [n.messages, n.isStreaming], () => {
|
|
280
280
|
(0, r.nextTick)(() => s.value?.scrollIntoView({ block: "end" }));
|
|
281
|
-
}, { deep: !0 }), (e, a) => 0 === n.messages.length ? ((0, r.openBlock)(), (0, r.createElementBlock)("div",
|
|
281
|
+
}, { deep: !0 }), (e, a) => 0 === n.messages.length ? ((0, r.openBlock)(), (0, r.createElementBlock)("div", I, [
|
|
282
282
|
(0, r.createVNode)((0, r.unref)(o.Sparkles), { class: "w-7 h-7 text-primary/70" }),
|
|
283
|
-
(0, r.createElementVNode)("p",
|
|
284
|
-
(0, r.createElementVNode)("p",
|
|
285
|
-
])) : ((0, r.openBlock)(), (0, r.createElementBlock)("div",
|
|
286
|
-
((0, r.openBlock)(!0), (0, r.createElementBlock)(r.Fragment, null, (0, r.renderList)(n.messages, (e) => ((0, r.openBlock)(), (0, r.createElementBlock)(r.Fragment, { key: e.id }, ["user" === e.role || (0, r.unref)(t.toRenderableParts)(e).length > 0 ? ((0, r.openBlock)(), (0, r.createElementBlock)("div",
|
|
283
|
+
(0, r.createElementVNode)("p", F, (0, r.toDisplayString)((0, r.unref)(l)("pptx.ai.emptyTitle")), 1),
|
|
284
|
+
(0, r.createElementVNode)("p", _, (0, r.toDisplayString)((0, r.unref)(l)("pptx.ai.emptyHint")), 1)
|
|
285
|
+
])) : ((0, r.openBlock)(), (0, r.createElementBlock)("div", j, [
|
|
286
|
+
((0, r.openBlock)(!0), (0, r.createElementBlock)(r.Fragment, null, (0, r.renderList)(n.messages, (e) => ((0, r.openBlock)(), (0, r.createElementBlock)(r.Fragment, { key: e.id }, ["user" === e.role || (0, r.unref)(t.toRenderableParts)(e).length > 0 ? ((0, r.openBlock)(), (0, r.createElementBlock)("div", z, [(0, r.createElementVNode)("div", {
|
|
287
287
|
class: (0, r.normalizeClass)((0, r.unref)(t.cn)("mt-0.5 flex h-6 w-6 shrink-0 items-center justify-center rounded-full", "user" === e.role ? "bg-secondary text-muted-foreground" : "bg-primary/15 text-primary")),
|
|
288
288
|
"aria-label": "user" === e.role ? (0, r.unref)(l)("pptx.ai.you") : (0, r.unref)(l)("pptx.ai.assistant")
|
|
289
289
|
}, ["user" === e.role ? ((0, r.openBlock)(), (0, r.createBlock)((0, r.unref)(o.User), {
|
|
@@ -292,7 +292,7 @@ var i = { class: "border-t border-border p-2" }, c = { class: "flex items-end ga
|
|
|
292
292
|
})) : ((0, r.openBlock)(), (0, r.createBlock)((0, r.unref)(o.Bot), {
|
|
293
293
|
key: 1,
|
|
294
294
|
class: "w-3.5 h-3.5"
|
|
295
|
-
}))], 10, L), (0, r.createElementVNode)("div",
|
|
295
|
+
}))], 10, L), (0, r.createElementVNode)("div", M, [((0, r.openBlock)(!0), (0, r.createElementBlock)(r.Fragment, null, (0, r.renderList)((0, r.unref)(t.toRenderableParts)(e), (e, t) => ((0, r.openBlock)(), (0, r.createElementBlock)(r.Fragment, { key: "tool" === e.kind && e.toolCallId || t }, ["text" === e.kind ? ((0, r.openBlock)(), (0, r.createElementBlock)("p", R, (0, r.toDisplayString)(e.text), 1)) : ((0, r.openBlock)(), (0, r.createBlock)(A, {
|
|
296
296
|
key: 1,
|
|
297
297
|
part: e
|
|
298
298
|
}, null, 8, ["part"]))], 64))), 128))])])) : (0, r.createCommentVNode)("", !0)], 64))), 128)),
|
|
@@ -307,23 +307,23 @@ var i = { class: "border-t border-border p-2" }, c = { class: "flex items-end ga
|
|
|
307
307
|
}, null, 512)
|
|
308
308
|
]));
|
|
309
309
|
}
|
|
310
|
-
}),
|
|
310
|
+
}), U = { class: "rounded-md border border-primary/40 bg-primary/5 p-2.5" }, $ = { class: "mb-1.5 text-[11px] font-semibold uppercase tracking-wide text-primary" }, H = { class: "text-[12px] font-medium text-foreground" }, O = {
|
|
311
311
|
key: 0,
|
|
312
312
|
class: "mt-1 max-h-40 space-y-0.5 overflow-y-auto text-[11px] text-muted-foreground"
|
|
313
|
-
},
|
|
313
|
+
}, X = { class: "mt-2 flex items-center gap-2" }, K = (0, r.defineComponent)({
|
|
314
314
|
__name: "AiProposalCard",
|
|
315
315
|
props: { proposal: {} },
|
|
316
316
|
emits: ["accept", "reject"],
|
|
317
317
|
setup(a, { emit: n }) {
|
|
318
318
|
const l = a, s = n, { t: i } = e.useI18n(), c = (0, r.computed)(() => l.proposal.summary.map(t.humanizeDiffLine));
|
|
319
|
-
return (e, t) => ((0, r.openBlock)(), (0, r.createElementBlock)("div",
|
|
320
|
-
(0, r.createElementVNode)("div",
|
|
321
|
-
(0, r.createElementVNode)("div",
|
|
322
|
-
c.value.length > 0 ? ((0, r.openBlock)(), (0, r.createElementBlock)("ul",
|
|
319
|
+
return (e, t) => ((0, r.openBlock)(), (0, r.createElementBlock)("div", U, [
|
|
320
|
+
(0, r.createElementVNode)("div", $, (0, r.toDisplayString)((0, r.unref)(i)("pptx.ai.proposedChange")), 1),
|
|
321
|
+
(0, r.createElementVNode)("div", H, (0, r.toDisplayString)(l.proposal.label), 1),
|
|
322
|
+
c.value.length > 0 ? ((0, r.openBlock)(), (0, r.createElementBlock)("ul", O, [((0, r.openBlock)(!0), (0, r.createElementBlock)(r.Fragment, null, (0, r.renderList)(c.value, (e, t) => ((0, r.openBlock)(), (0, r.createElementBlock)("li", {
|
|
323
323
|
key: t,
|
|
324
324
|
class: "break-words"
|
|
325
325
|
}, (0, r.toDisplayString)(e), 1))), 128))])) : (0, r.createCommentVNode)("", !0),
|
|
326
|
-
(0, r.createElementVNode)("div",
|
|
326
|
+
(0, r.createElementVNode)("div", X, [(0, r.createElementVNode)("button", {
|
|
327
327
|
type: "button",
|
|
328
328
|
class: "inline-flex items-center gap-1 rounded-sm bg-primary px-2 py-1 text-[11px] font-medium text-primary-foreground transition-colors hover:bg-primary/90",
|
|
329
329
|
onClick: t[0] || (t[0] = (e) => s("accept", l.proposal.id))
|
|
@@ -334,13 +334,13 @@ var i = { class: "border-t border-border p-2" }, c = { class: "flex items-end ga
|
|
|
334
334
|
}, [(0, r.createVNode)((0, r.unref)(o.X), { class: "w-3.5 h-3.5" }), (0, r.createTextVNode)(" " + (0, r.toDisplayString)((0, r.unref)(i)("pptx.ai.reject")), 1)])])
|
|
335
335
|
]));
|
|
336
336
|
}
|
|
337
|
-
}),
|
|
337
|
+
}), G = { class: "flex min-h-0 flex-1 flex-col" }, J = {
|
|
338
338
|
key: 0,
|
|
339
339
|
class: "mx-3 mb-2 flex items-start gap-2 rounded-md border border-destructive/40 bg-destructive/5 px-2.5 py-1.5 text-[12px] text-destructive"
|
|
340
|
-
},
|
|
340
|
+
}, Q = { class: "min-w-0 flex-1" }, Y = { class: "font-medium" }, Z = { class: "max-h-24 overflow-y-auto break-words text-[11px] opacity-80" }, ee = {
|
|
341
341
|
key: 1,
|
|
342
342
|
class: "max-h-[38%] space-y-2 overflow-y-auto border-t border-border bg-background px-3 py-2"
|
|
343
|
-
},
|
|
343
|
+
}, te = { class: "flex items-center justify-between" }, re = { class: "text-[11px] font-semibold uppercase tracking-wide text-muted-foreground" }, oe = (0, r.defineComponent)({
|
|
344
344
|
__name: "AiConversation",
|
|
345
345
|
props: {
|
|
346
346
|
session: {},
|
|
@@ -348,33 +348,34 @@ var i = { class: "border-t border-border p-2" }, c = { class: "flex items-end ga
|
|
|
348
348
|
bridge: {},
|
|
349
349
|
aiPanel: {}
|
|
350
350
|
},
|
|
351
|
-
setup(t) {
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
351
|
+
async setup(t) {
|
|
352
|
+
let a, n;
|
|
353
|
+
const s = t, { t: i } = e.useI18n(), { useChat: c } = ([a, n] = (0, r.withAsyncContext)(() => import("@ai-sdk/vue")), a = await a, n(), a), { messages: p, error: u, isStreaming: m, proposals: f, send: x, stop: g, clearError: k, applyProposal: y, rejectProposal: b, acceptAllProposals: v } = l(c, s.session, s.config, { onToolTarget: (e) => {
|
|
354
|
+
e && void 0 !== e.slideIndex && s.bridge.goToSlide(e.slideIndex), s.aiPanel.flashToolTarget(e);
|
|
355
|
+
} }), h = s.session.changeAnimator.subscribe((e) => {
|
|
356
|
+
e && s.bridge.goToSlide(e.slideIndex), s.aiPanel.showChangeBatch(e);
|
|
356
357
|
});
|
|
357
|
-
(0, r.onBeforeUnmount)(() =>
|
|
358
|
-
const
|
|
359
|
-
function
|
|
360
|
-
|
|
358
|
+
(0, r.onBeforeUnmount)(() => h());
|
|
359
|
+
const B = (0, r.computed)(() => s.aiPanel.pickTargets.value.length > 0), E = (0, r.computed)(() => B.value ? s.aiPanel.pickTargets.value : s.aiPanel.pinnedFocus.value ?? s.aiPanel.liveFocusTargets.value), N = (0, r.computed)(() => !B.value && null !== s.aiPanel.pinnedFocus.value);
|
|
360
|
+
function V(e) {
|
|
361
|
+
s.aiPanel.flashToolTarget(null), y(e);
|
|
361
362
|
}
|
|
362
|
-
function
|
|
363
|
-
|
|
363
|
+
function w() {
|
|
364
|
+
s.aiPanel.flashToolTarget(null), v();
|
|
364
365
|
}
|
|
365
|
-
return (e, t) => ((0, r.openBlock)(), (0, r.createElementBlock)("div",
|
|
366
|
-
(0, r.createVNode)(
|
|
367
|
-
targets:
|
|
368
|
-
slides:
|
|
369
|
-
"is-pinned":
|
|
370
|
-
"pick-mode":
|
|
371
|
-
"has-picks":
|
|
372
|
-
onPin:
|
|
373
|
-
onClearPin:
|
|
374
|
-
onStartPick:
|
|
375
|
-
onStopPick:
|
|
376
|
-
onClearPicks:
|
|
377
|
-
onSendDirective: (0, r.unref)(
|
|
366
|
+
return (e, t) => ((0, r.openBlock)(), (0, r.createElementBlock)("div", G, [
|
|
367
|
+
(0, r.createVNode)(C, {
|
|
368
|
+
targets: E.value,
|
|
369
|
+
slides: s.bridge.getSlides(),
|
|
370
|
+
"is-pinned": N.value,
|
|
371
|
+
"pick-mode": s.aiPanel.pickMode.value,
|
|
372
|
+
"has-picks": B.value,
|
|
373
|
+
onPin: s.aiPanel.pinFocus,
|
|
374
|
+
onClearPin: s.aiPanel.clearPinnedFocus,
|
|
375
|
+
onStartPick: s.aiPanel.startPicking,
|
|
376
|
+
onStopPick: s.aiPanel.stopPicking,
|
|
377
|
+
onClearPicks: s.aiPanel.clearPicks,
|
|
378
|
+
onSendDirective: (0, r.unref)(x)
|
|
378
379
|
}, null, 8, [
|
|
379
380
|
"targets",
|
|
380
381
|
"slides",
|
|
@@ -388,36 +389,36 @@ var i = { class: "border-t border-border p-2" }, c = { class: "flex items-end ga
|
|
|
388
389
|
"onClearPicks",
|
|
389
390
|
"onSendDirective"
|
|
390
391
|
]),
|
|
391
|
-
(0, r.createVNode)(
|
|
392
|
-
messages: (0, r.unref)(
|
|
393
|
-
"is-streaming": (0, r.unref)(
|
|
392
|
+
(0, r.createVNode)(q, {
|
|
393
|
+
messages: (0, r.unref)(p),
|
|
394
|
+
"is-streaming": (0, r.unref)(m)
|
|
394
395
|
}, null, 8, ["messages", "is-streaming"]),
|
|
395
|
-
(0, r.unref)(
|
|
396
|
+
(0, r.unref)(u) ? ((0, r.openBlock)(), (0, r.createElementBlock)("div", J, [
|
|
396
397
|
(0, r.createVNode)((0, r.unref)(o.TriangleAlert), { class: "mt-0.5 w-3.5 h-3.5 shrink-0" }),
|
|
397
|
-
(0, r.createElementVNode)("div",
|
|
398
|
+
(0, r.createElementVNode)("div", Q, [(0, r.createElementVNode)("div", Y, (0, r.toDisplayString)((0, r.unref)(i)("pptx.ai.errorPrefix")), 1), (0, r.createElementVNode)("div", Z, (0, r.toDisplayString)((0, r.unref)(u).message), 1)]),
|
|
398
399
|
(0, r.createElementVNode)("button", {
|
|
399
400
|
type: "button",
|
|
400
401
|
class: "shrink-0 rounded-sm px-1.5 py-0.5 text-[11px] underline-offset-2 hover:underline",
|
|
401
|
-
onClick: t[0] || (t[0] = (...e) => (0, r.unref)(
|
|
402
|
-
}, (0, r.toDisplayString)((0, r.unref)(
|
|
402
|
+
onClick: t[0] || (t[0] = (...e) => (0, r.unref)(k) && (0, r.unref)(k)(...e))
|
|
403
|
+
}, (0, r.toDisplayString)((0, r.unref)(i)("pptx.ai.retry")), 1)
|
|
403
404
|
])) : (0, r.createCommentVNode)("", !0),
|
|
404
|
-
(0, r.unref)(
|
|
405
|
+
(0, r.unref)(f).length > 0 ? ((0, r.openBlock)(), (0, r.createElementBlock)("div", ee, [(0, r.createElementVNode)("div", te, [(0, r.createElementVNode)("span", re, (0, r.toDisplayString)((0, r.unref)(i)("pptx.ai.pendingChanges", { count: (0, r.unref)(f).length })), 1), (0, r.unref)(f).length > 1 ? ((0, r.openBlock)(), (0, r.createElementBlock)("button", {
|
|
405
406
|
key: 0,
|
|
406
407
|
type: "button",
|
|
407
408
|
class: "rounded-sm bg-primary/90 px-2 py-0.5 text-[11px] font-medium text-primary-foreground hover:bg-primary",
|
|
408
|
-
onClick:
|
|
409
|
-
}, (0, r.toDisplayString)((0, r.unref)(
|
|
409
|
+
onClick: w
|
|
410
|
+
}, (0, r.toDisplayString)((0, r.unref)(i)("pptx.ai.acceptAll")), 1)) : (0, r.createCommentVNode)("", !0)]), ((0, r.openBlock)(!0), (0, r.createElementBlock)(r.Fragment, null, (0, r.renderList)((0, r.unref)(f), (e) => ((0, r.openBlock)(), (0, r.createBlock)(K, {
|
|
410
411
|
key: e.id,
|
|
411
412
|
proposal: e,
|
|
412
|
-
onAccept:
|
|
413
|
-
onReject: (0, r.unref)(
|
|
413
|
+
onAccept: V,
|
|
414
|
+
onReject: (0, r.unref)(b)
|
|
414
415
|
}, null, 8, ["proposal", "onReject"]))), 128))])) : (0, r.createCommentVNode)("", !0),
|
|
415
|
-
(0, r.createVNode)(
|
|
416
|
-
"is-streaming": (0, r.unref)(
|
|
417
|
-
"prefill-text":
|
|
418
|
-
"prefill-nonce":
|
|
419
|
-
onSend: (0, r.unref)(
|
|
420
|
-
onStop: (0, r.unref)(
|
|
416
|
+
(0, r.createVNode)(d, {
|
|
417
|
+
"is-streaming": (0, r.unref)(m),
|
|
418
|
+
"prefill-text": s.aiPanel.prefill.value.text,
|
|
419
|
+
"prefill-nonce": s.aiPanel.prefill.value.nonce,
|
|
420
|
+
onSend: (0, r.unref)(x),
|
|
421
|
+
onStop: (0, r.unref)(g)
|
|
421
422
|
}, null, 8, [
|
|
422
423
|
"is-streaming",
|
|
423
424
|
"prefill-text",
|
|
@@ -427,13 +428,13 @@ var i = { class: "border-t border-border p-2" }, c = { class: "flex items-end ga
|
|
|
427
428
|
])
|
|
428
429
|
]));
|
|
429
430
|
}
|
|
430
|
-
}),
|
|
431
|
+
}), ae = { class: "flex items-center gap-2 border-b border-border px-3 py-2" }, ne = { class: "text-sm font-semibold text-foreground" }, le = ["title", "aria-label"], se = {
|
|
431
432
|
key: 0,
|
|
432
433
|
class: "flex flex-1 flex-col items-center justify-center gap-2 text-muted-foreground"
|
|
433
|
-
},
|
|
434
|
+
}, ie = {
|
|
434
435
|
key: 1,
|
|
435
436
|
class: "flex flex-1 flex-col items-center justify-center gap-2 px-6 text-center"
|
|
436
|
-
},
|
|
437
|
+
}, ce = { class: "text-sm font-medium text-foreground" }, pe = { class: "text-[12px] text-muted-foreground" }, ue = { class: "flex flex-1 flex-col items-center justify-center gap-2 text-muted-foreground" }, de = (0, r.defineComponent)({
|
|
437
438
|
__name: "AiChatPanel",
|
|
438
439
|
props: {
|
|
439
440
|
bridge: {},
|
|
@@ -474,32 +475,35 @@ var i = { class: "border-t border-border p-2" }, c = { class: "flex items-end ga
|
|
|
474
475
|
"data-pptx-ai-panel": "",
|
|
475
476
|
class: "absolute right-0 top-0 z-30 flex h-full w-80 flex-col border-l border-border bg-card shadow-xl max-md:inset-x-0 max-md:top-auto max-md:bottom-0 max-md:h-[75dvh] max-md:w-full max-md:rounded-t-2xl max-md:border-l-0 max-md:border-t max-md:shadow-2xl",
|
|
476
477
|
style: (0, r.normalizeStyle)(d.value)
|
|
477
|
-
}, [(0, r.createElementVNode)("div",
|
|
478
|
+
}, [(0, r.createElementVNode)("div", ae, [
|
|
478
479
|
(0, r.createVNode)((0, r.unref)(o.Sparkles), { class: "w-4 h-4 text-primary" }),
|
|
479
|
-
(0, r.createElementVNode)("span",
|
|
480
|
+
(0, r.createElementVNode)("span", ne, (0, r.toDisplayString)((0, r.unref)(i)("pptx.ai.title")), 1),
|
|
480
481
|
(0, r.createElementVNode)("button", {
|
|
481
482
|
type: "button",
|
|
482
483
|
title: (0, r.unref)(i)("pptx.ai.close"),
|
|
483
484
|
"aria-label": (0, r.unref)(i)("pptx.ai.close"),
|
|
484
485
|
class: "ml-auto rounded-sm p-1 text-muted-foreground transition-colors hover:bg-accent",
|
|
485
486
|
onClick: t[0] || (t[0] = (e) => s("close"))
|
|
486
|
-
}, [(0, r.createVNode)((0, r.unref)(o.X), { class: "w-4 h-4" })], 8,
|
|
487
|
-
]), "checking" === (0, r.unref)(c) ? ((0, r.openBlock)(), (0, r.createElementBlock)("div",
|
|
487
|
+
}, [(0, r.createVNode)((0, r.unref)(o.X), { class: "w-4 h-4" })], 8, le)
|
|
488
|
+
]), "checking" === (0, r.unref)(c) ? ((0, r.openBlock)(), (0, r.createElementBlock)("div", se, [(0, r.createVNode)((0, r.unref)(o.LoaderCircle), { class: "w-5 h-5 animate-spin" })])) : "unavailable" === (0, r.unref)(c) || "error" === (0, r.unref)(c) ? ((0, r.openBlock)(), (0, r.createElementBlock)("div", ie, [
|
|
488
489
|
(0, r.createVNode)((0, r.unref)(o.TriangleAlert), { class: "w-6 h-6 text-muted-foreground" }),
|
|
489
|
-
(0, r.createElementVNode)("p",
|
|
490
|
-
(0, r.createElementVNode)("p",
|
|
491
|
-
])) : "ready" === (0, r.unref)(c) && (0, r.unref)(p) ? ((0, r.openBlock)(), (0, r.createBlock)(
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
490
|
+
(0, r.createElementVNode)("p", ce, (0, r.toDisplayString)((0, r.unref)(i)("pptx.ai.unavailableTitle")), 1),
|
|
491
|
+
(0, r.createElementVNode)("p", pe, (0, r.toDisplayString)((0, r.unref)(u)?.message ?? (0, r.unref)(i)("pptx.ai.unavailableHint")), 1)
|
|
492
|
+
])) : "ready" === (0, r.unref)(c) && (0, r.unref)(p) ? ((0, r.openBlock)(), (0, r.createBlock)(r.Suspense, { key: 2 }, {
|
|
493
|
+
fallback: (0, r.withCtx)(() => [(0, r.createElementVNode)("div", ue, [(0, r.createVNode)((0, r.unref)(o.LoaderCircle), { class: "w-5 h-5 animate-spin" })])]),
|
|
494
|
+
default: (0, r.withCtx)(() => [(0, r.createVNode)(oe, {
|
|
495
|
+
session: (0, r.unref)(p),
|
|
496
|
+
config: l.config,
|
|
497
|
+
bridge: l.bridge,
|
|
498
|
+
"ai-panel": f.value
|
|
499
|
+
}, null, 8, [
|
|
500
|
+
"session",
|
|
501
|
+
"config",
|
|
502
|
+
"bridge",
|
|
503
|
+
"ai-panel"
|
|
504
|
+
])]),
|
|
505
|
+
_: 1
|
|
506
|
+
})) : (0, r.createCommentVNode)("", !0)], 4));
|
|
503
507
|
}
|
|
504
508
|
});
|
|
505
509
|
exports.default = de;
|
|
Binary file
|
|
Binary file
|