wecool-chat 0.8.0 → 0.10.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.md +83 -0
- package/README.ja.md +234 -20
- package/README.md +419 -21
- package/dist/CopyIndicator-RR3hSsBA.js +51 -0
- package/dist/MarkdownBody-EIz0jnQy.js +14910 -0
- package/dist/VoiceControls-A7N4uPTo.js +146 -0
- package/dist/VoiceRuntime-DrYjNkZK.js +459 -0
- package/dist/abort-BjeyCmGn.js +6 -0
- package/dist/blank-line-CUDmZ-mX.js +143 -0
- package/dist/{browser-Cgo1GySj.js → browser-M7mS-hAN.js} +5 -5
- package/dist/clsx-Cf23UI1w.js +16 -0
- package/dist/core/client.d.ts +37 -4
- package/dist/core/client.d.ts.map +1 -1
- package/dist/core/consume-stream.d.ts.map +1 -1
- package/dist/core/error-reporter.d.ts +59 -0
- package/dist/core/error-reporter.d.ts.map +1 -0
- package/dist/core/global-error-capture.d.ts +10 -0
- package/dist/core/global-error-capture.d.ts.map +1 -0
- package/dist/core/i18n/messages.d.ts +139 -1
- package/dist/core/i18n/messages.d.ts.map +1 -1
- package/dist/core/sanitize-user-message.d.ts +11 -0
- package/dist/core/sanitize-user-message.d.ts.map +1 -0
- package/dist/core/stream-state.d.ts.map +1 -1
- package/dist/core/tool-confirmation.d.ts +35 -0
- package/dist/core/tool-confirmation.d.ts.map +1 -0
- package/dist/core/tool-runner.d.ts +8 -0
- package/dist/core/tool-runner.d.ts.map +1 -1
- package/dist/core/types.d.ts +123 -0
- package/dist/core/types.d.ts.map +1 -1
- package/dist/core/widget-origin.d.ts +33 -0
- package/dist/core/widget-origin.d.ts.map +1 -0
- package/dist/createLucideIcon-C7wGkK-Q.js +43 -0
- package/dist/default-sNAxTmdF.js +8 -0
- package/dist/index.css +2 -2
- package/dist/index.d.ts +3 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +7548 -26290
- package/dist/jsx-runtime-Cyy0mp0f.js +328 -0
- package/dist/lib-DG_DjiCr.js +15 -0
- package/dist/loader.d.ts +12 -0
- package/dist/loader.d.ts.map +1 -0
- package/dist/messages-FvtWi3lI.js +247 -0
- package/dist/observe/__tests__/format.test.d.ts +2 -0
- package/dist/observe/__tests__/format.test.d.ts.map +1 -0
- package/dist/observe/__tests__/http.test.d.ts +2 -0
- package/dist/observe/__tests__/http.test.d.ts.map +1 -0
- package/dist/observe/__tests__/index.test.d.ts +2 -0
- package/dist/observe/__tests__/index.test.d.ts.map +1 -0
- package/dist/observe/__tests__/js-error.test.d.ts +2 -0
- package/dist/observe/__tests__/js-error.test.d.ts.map +1 -0
- package/dist/observe/__tests__/redact.test.d.ts +2 -0
- package/dist/observe/__tests__/redact.test.d.ts.map +1 -0
- package/dist/observe/__tests__/ring-buffer.test.d.ts +2 -0
- package/dist/observe/__tests__/ring-buffer.test.d.ts.map +1 -0
- package/dist/observe/format.d.ts +10 -0
- package/dist/observe/format.d.ts.map +1 -0
- package/dist/observe/index.d.ts +33 -0
- package/dist/observe/index.d.ts.map +1 -0
- package/dist/observe/observers/http.d.ts +24 -0
- package/dist/observe/observers/http.d.ts.map +1 -0
- package/dist/observe/observers/js-error.d.ts +22 -0
- package/dist/observe/observers/js-error.d.ts.map +1 -0
- package/dist/observe/redact.d.ts +27 -0
- package/dist/observe/redact.d.ts.map +1 -0
- package/dist/observe/ring-buffer.d.ts +20 -0
- package/dist/observe/ring-buffer.d.ts.map +1 -0
- package/dist/observe/types.d.ts +25 -0
- package/dist/observe/types.d.ts.map +1 -0
- package/dist/plugin/registry.d.ts.map +1 -1
- package/dist/plugin/types.d.ts +19 -1
- package/dist/plugin/types.d.ts.map +1 -1
- package/dist/plugins/page-reader/__tests__/get-meta.test.d.ts +2 -0
- package/dist/plugins/page-reader/__tests__/get-meta.test.d.ts.map +1 -0
- package/dist/plugins/page-reader/__tests__/index.test.d.ts +2 -0
- package/dist/plugins/page-reader/__tests__/index.test.d.ts.map +1 -0
- package/dist/plugins/page-reader/__tests__/read-content.test.d.ts +2 -0
- package/dist/plugins/page-reader/__tests__/read-content.test.d.ts.map +1 -0
- package/dist/plugins/page-reader/__tests__/scroll.test.d.ts +2 -0
- package/dist/plugins/page-reader/__tests__/scroll.test.d.ts.map +1 -0
- package/dist/plugins/page-reader/index.d.ts +18 -0
- package/dist/plugins/page-reader/index.d.ts.map +1 -0
- package/dist/plugins/page-reader/tools/get-meta.d.ts +29 -0
- package/dist/plugins/page-reader/tools/get-meta.d.ts.map +1 -0
- package/dist/plugins/page-reader/tools/read-content.d.ts +34 -0
- package/dist/plugins/page-reader/tools/read-content.d.ts.map +1 -0
- package/dist/plugins/page-reader/tools/scroll.d.ts +29 -0
- package/dist/plugins/page-reader/tools/scroll.d.ts.map +1 -0
- package/dist/plugins/page-reader.d.ts +2 -0
- package/dist/plugins/page-reader.js +230 -0
- package/dist/plugins/qrcode/tool.d.ts.map +1 -1
- package/dist/plugins/qrcode.js +52 -42
- package/dist/plugins/shared/abort.d.ts +7 -0
- package/dist/plugins/shared/abort.d.ts.map +1 -0
- package/dist/remark-gfm-Bzy1u34W.js +1962 -0
- package/dist/remark-parse-BnwSmQr-.js +2486 -0
- package/dist/stable-prefix-BHsGj4tL.js +21 -0
- package/dist/ui/builtin-tools/get-current-page-info.d.ts.map +1 -1
- package/dist/ui/builtin-tools/index.d.ts +1 -1
- package/dist/ui/builtin-tools/index.d.ts.map +1 -1
- package/dist/ui/builtin-tools/merge-builtin-tools.d.ts +9 -0
- package/dist/ui/builtin-tools/merge-builtin-tools.d.ts.map +1 -1
- package/dist/ui/commands/builtin-commands.d.ts +46 -0
- package/dist/ui/commands/builtin-commands.d.ts.map +1 -0
- package/dist/ui/components/ChatErrorBoundary.d.ts +30 -0
- package/dist/ui/components/ChatErrorBoundary.d.ts.map +1 -0
- package/dist/ui/components/ChatFooter.d.ts +32 -2
- package/dist/ui/components/ChatFooter.d.ts.map +1 -1
- package/dist/ui/components/ChatHeader.d.ts +13 -2
- package/dist/ui/components/ChatHeader.d.ts.map +1 -1
- package/dist/ui/components/ChatHeaderMenu.d.ts +28 -2
- package/dist/ui/components/ChatHeaderMenu.d.ts.map +1 -1
- package/dist/ui/components/ChatPanel.d.ts +38 -4
- package/dist/ui/components/ChatPanel.d.ts.map +1 -1
- package/dist/ui/components/ChatWidget.d.ts +1 -1
- package/dist/ui/components/ChatWidget.d.ts.map +1 -1
- package/dist/ui/components/CommandConfirmationCard.d.ts +28 -0
- package/dist/ui/components/CommandConfirmationCard.d.ts.map +1 -0
- package/dist/ui/components/CommandOverlays.d.ts +40 -0
- package/dist/ui/components/CommandOverlays.d.ts.map +1 -0
- package/dist/ui/components/CommandPalette.d.ts +25 -0
- package/dist/ui/components/CommandPalette.d.ts.map +1 -0
- package/dist/ui/components/FooterActions.d.ts +18 -0
- package/dist/ui/components/FooterActions.d.ts.map +1 -0
- package/dist/ui/components/HelpDialogContent.d.ts +7 -0
- package/dist/ui/components/HelpDialogContent.d.ts.map +1 -0
- package/dist/ui/components/MessageList.d.ts +12 -1
- package/dist/ui/components/MessageList.d.ts.map +1 -1
- package/dist/ui/components/MessageRow.d.ts +7 -1
- package/dist/ui/components/MessageRow.d.ts.map +1 -1
- package/dist/ui/components/MessageRowActions.d.ts +9 -3
- package/dist/ui/components/MessageRowActions.d.ts.map +1 -1
- package/dist/ui/components/MicButton.d.ts +11 -0
- package/dist/ui/components/MicButton.d.ts.map +1 -0
- package/dist/ui/components/ResizeHandles.d.ts +15 -0
- package/dist/ui/components/ResizeHandles.d.ts.map +1 -0
- package/dist/ui/components/ToolConfirmationCard.d.ts +22 -0
- package/dist/ui/components/ToolConfirmationCard.d.ts.map +1 -0
- package/dist/ui/components/ToolConfirmationRecord.d.ts +16 -0
- package/dist/ui/components/ToolConfirmationRecord.d.ts.map +1 -0
- package/dist/ui/components/ToolsDialogContent.d.ts +20 -0
- package/dist/ui/components/ToolsDialogContent.d.ts.map +1 -0
- package/dist/ui/components/VoiceControls.d.ts +22 -0
- package/dist/ui/components/VoiceControls.d.ts.map +1 -0
- package/dist/ui/components/VoiceLoopStatusBar.d.ts +17 -0
- package/dist/ui/components/VoiceLoopStatusBar.d.ts.map +1 -0
- package/dist/ui/components/VoiceLoopToggle.d.ts +15 -0
- package/dist/ui/components/VoiceLoopToggle.d.ts.map +1 -0
- package/dist/ui/components/VoiceRuntime.d.ts +16 -0
- package/dist/ui/components/VoiceRuntime.d.ts.map +1 -0
- package/dist/ui/components/WidgetDialog.d.ts +22 -0
- package/dist/ui/components/WidgetDialog.d.ts.map +1 -0
- package/dist/ui/components/lazy-voice.d.ts +19 -0
- package/dist/ui/components/lazy-voice.d.ts.map +1 -0
- package/dist/ui/components/markdown/MarkdownBody.d.ts +28 -0
- package/dist/ui/components/markdown/MarkdownBody.d.ts.map +1 -0
- package/dist/ui/components/markdown/MarkdownMessage.d.ts +12 -13
- package/dist/ui/components/markdown/MarkdownMessage.d.ts.map +1 -1
- package/dist/ui/hooks/conversationPersistence.d.ts +21 -0
- package/dist/ui/hooks/conversationPersistence.d.ts.map +1 -0
- package/dist/ui/hooks/resize-geometry.d.ts +42 -0
- package/dist/ui/hooks/resize-geometry.d.ts.map +1 -0
- package/dist/ui/hooks/use-command-execution.d.ts +60 -0
- package/dist/ui/hooks/use-command-execution.d.ts.map +1 -0
- package/dist/ui/hooks/use-command-palette.d.ts +45 -0
- package/dist/ui/hooks/use-command-palette.d.ts.map +1 -0
- package/dist/ui/hooks/use-fullscreen.d.ts +21 -0
- package/dist/ui/hooks/use-fullscreen.d.ts.map +1 -0
- package/dist/ui/hooks/use-global-error-capture.d.ts +16 -0
- package/dist/ui/hooks/use-global-error-capture.d.ts.map +1 -0
- package/dist/ui/hooks/use-locale-preference.d.ts +14 -0
- package/dist/ui/hooks/use-locale-preference.d.ts.map +1 -0
- package/dist/ui/hooks/use-menu-keyboard.d.ts +7 -1
- package/dist/ui/hooks/use-menu-keyboard.d.ts.map +1 -1
- package/dist/ui/hooks/use-message-history.d.ts +14 -0
- package/dist/ui/hooks/use-message-history.d.ts.map +1 -1
- package/dist/ui/hooks/use-mic-button.d.ts +29 -0
- package/dist/ui/hooks/use-mic-button.d.ts.map +1 -0
- package/dist/ui/hooks/use-send-message.d.ts +6 -0
- package/dist/ui/hooks/use-send-message.d.ts.map +1 -1
- package/dist/ui/hooks/use-speak-message.d.ts +26 -0
- package/dist/ui/hooks/use-speak-message.d.ts.map +1 -0
- package/dist/ui/hooks/use-tool-confirmation.d.ts +22 -0
- package/dist/ui/hooks/use-tool-confirmation.d.ts.map +1 -0
- package/dist/ui/hooks/use-tool-runner.d.ts +17 -2
- package/dist/ui/hooks/use-tool-runner.d.ts.map +1 -1
- package/dist/ui/hooks/use-visitor-id.d.ts +22 -0
- package/dist/ui/hooks/use-visitor-id.d.ts.map +1 -0
- package/dist/ui/hooks/use-voice-input.d.ts +38 -0
- package/dist/ui/hooks/use-voice-input.d.ts.map +1 -0
- package/dist/ui/hooks/use-voice-loop-speech.d.ts +38 -0
- package/dist/ui/hooks/use-voice-loop-speech.d.ts.map +1 -0
- package/dist/ui/hooks/use-voice-loop.d.ts +12 -0
- package/dist/ui/hooks/use-voice-loop.d.ts.map +1 -0
- package/dist/ui/hooks/use-voice-runtime-snapshot.d.ts +19 -0
- package/dist/ui/hooks/use-voice-runtime-snapshot.d.ts.map +1 -0
- package/dist/ui/hooks/use-voice-runtime.d.ts +29 -0
- package/dist/ui/hooks/use-voice-runtime.d.ts.map +1 -0
- package/dist/ui/hooks/useChatStream.d.ts +19 -0
- package/dist/ui/hooks/useChatStream.d.ts.map +1 -1
- package/dist/ui/hooks/useConversationList.d.ts +12 -1
- package/dist/ui/hooks/useConversationList.d.ts.map +1 -1
- package/dist/ui/hooks/useDraggablePanel.d.ts +2 -0
- package/dist/ui/hooks/useDraggablePanel.d.ts.map +1 -1
- package/dist/ui/hooks/useResizablePanel.d.ts +48 -0
- package/dist/ui/hooks/useResizablePanel.d.ts.map +1 -0
- package/dist/ui/utils/speech-text.d.ts +29 -0
- package/dist/ui/utils/speech-text.d.ts.map +1 -0
- package/dist/ui/utils/voice-locale.d.ts +3 -0
- package/dist/ui/utils/voice-locale.d.ts.map +1 -0
- package/dist/ui/utils/voice-loop-cue.d.ts +23 -0
- package/dist/ui/utils/voice-loop-cue.d.ts.map +1 -0
- package/dist/ui/utils/voice-loop-status.d.ts +17 -0
- package/dist/ui/utils/voice-loop-status.d.ts.map +1 -0
- package/dist/ui/utils/voice-loop-types.d.ts +40 -0
- package/dist/ui/utils/voice-loop-types.d.ts.map +1 -0
- package/dist/ui/utils/voice-runtime.d.ts +38 -0
- package/dist/ui/utils/voice-runtime.d.ts.map +1 -0
- package/dist/ui/utils/voice-support.d.ts +9 -0
- package/dist/ui/utils/voice-support.d.ts.map +1 -0
- package/dist/unified-DctkAd9P.js +518 -0
- package/dist/use-voice-input-LtJJz-zQ.js +102 -0
- package/dist/version.d.ts +17 -0
- package/dist/version.d.ts.map +1 -0
- package/dist/voice-runtime-F5NxN_0m.js +11 -0
- package/dist/voice-support-BeOiOzcn.js +9 -0
- package/package.json +41 -23
- package/dist/messages-B7Kpa6yx.js +0 -117
|
@@ -0,0 +1,328 @@
|
|
|
1
|
+
import { a as V, r as C, t as F } from "./messages-FvtWi3lI.js";
|
|
2
|
+
var x = /* @__PURE__ */ C(((n) => {
|
|
3
|
+
var l = /* @__PURE__ */ Symbol.for("react.transitional.element"), A = /* @__PURE__ */ Symbol.for("react.portal"), R = /* @__PURE__ */ Symbol.for("react.fragment"), S = /* @__PURE__ */ Symbol.for("react.strict_mode"), a = /* @__PURE__ */ Symbol.for("react.profiler"), v = /* @__PURE__ */ Symbol.for("react.consumer"), y = /* @__PURE__ */ Symbol.for("react.context"), T = /* @__PURE__ */ Symbol.for("react.forward_ref"), b = /* @__PURE__ */ Symbol.for("react.suspense"), z = /* @__PURE__ */ Symbol.for("react.memo"), H = /* @__PURE__ */ Symbol.for("react.lazy"), G = /* @__PURE__ */ Symbol.for("react.activity"), O = Symbol.iterator;
|
|
4
|
+
function B(t) {
|
|
5
|
+
return t === null || typeof t != "object" ? null : (t = O && t[O] || t["@@iterator"], typeof t == "function" ? t : null);
|
|
6
|
+
}
|
|
7
|
+
var M = {
|
|
8
|
+
isMounted: function() {
|
|
9
|
+
return !1;
|
|
10
|
+
},
|
|
11
|
+
enqueueForceUpdate: function() {
|
|
12
|
+
},
|
|
13
|
+
enqueueReplaceState: function() {
|
|
14
|
+
},
|
|
15
|
+
enqueueSetState: function() {
|
|
16
|
+
}
|
|
17
|
+
}, $ = Object.assign, Y = {};
|
|
18
|
+
function E(t, e, u) {
|
|
19
|
+
this.props = t, this.context = e, this.refs = Y, this.updater = u || M;
|
|
20
|
+
}
|
|
21
|
+
E.prototype.isReactComponent = {}, E.prototype.setState = function(t, e) {
|
|
22
|
+
if (typeof t != "object" && typeof t != "function" && t != null) throw Error("takes an object of state variables to update or a function which returns an object of state variables.");
|
|
23
|
+
this.updater.enqueueSetState(this, t, e, "setState");
|
|
24
|
+
}, E.prototype.forceUpdate = function(t) {
|
|
25
|
+
this.updater.enqueueForceUpdate(this, t, "forceUpdate");
|
|
26
|
+
};
|
|
27
|
+
function N() {
|
|
28
|
+
}
|
|
29
|
+
N.prototype = E.prototype;
|
|
30
|
+
function d(t, e, u) {
|
|
31
|
+
this.props = t, this.context = e, this.refs = Y, this.updater = u || M;
|
|
32
|
+
}
|
|
33
|
+
var P = d.prototype = new N();
|
|
34
|
+
P.constructor = d, $(P, E.prototype), P.isPureReactComponent = !0;
|
|
35
|
+
var k = Array.isArray;
|
|
36
|
+
function w() {
|
|
37
|
+
}
|
|
38
|
+
var i = {
|
|
39
|
+
H: null,
|
|
40
|
+
A: null,
|
|
41
|
+
T: null,
|
|
42
|
+
S: null
|
|
43
|
+
}, I = Object.prototype.hasOwnProperty;
|
|
44
|
+
function j(t, e, u) {
|
|
45
|
+
var r = u.ref;
|
|
46
|
+
return {
|
|
47
|
+
$$typeof: l,
|
|
48
|
+
type: t,
|
|
49
|
+
key: e,
|
|
50
|
+
ref: r !== void 0 ? r : null,
|
|
51
|
+
props: u
|
|
52
|
+
};
|
|
53
|
+
}
|
|
54
|
+
function W(t, e) {
|
|
55
|
+
return j(t.type, e, t.props);
|
|
56
|
+
}
|
|
57
|
+
function g(t) {
|
|
58
|
+
return typeof t == "object" && t !== null && t.$$typeof === l;
|
|
59
|
+
}
|
|
60
|
+
function J(t) {
|
|
61
|
+
var e = {
|
|
62
|
+
"=": "=0",
|
|
63
|
+
":": "=2"
|
|
64
|
+
};
|
|
65
|
+
return "$" + t.replace(/[=:]/g, function(u) {
|
|
66
|
+
return e[u];
|
|
67
|
+
});
|
|
68
|
+
}
|
|
69
|
+
var L = /\/+/g;
|
|
70
|
+
function h(t, e) {
|
|
71
|
+
return typeof t == "object" && t !== null && t.key != null ? J("" + t.key) : e.toString(36);
|
|
72
|
+
}
|
|
73
|
+
function Q(t) {
|
|
74
|
+
switch (t.status) {
|
|
75
|
+
case "fulfilled":
|
|
76
|
+
return t.value;
|
|
77
|
+
case "rejected":
|
|
78
|
+
throw t.reason;
|
|
79
|
+
default:
|
|
80
|
+
switch (typeof t.status == "string" ? t.then(w, w) : (t.status = "pending", t.then(function(e) {
|
|
81
|
+
t.status === "pending" && (t.status = "fulfilled", t.value = e);
|
|
82
|
+
}, function(e) {
|
|
83
|
+
t.status === "pending" && (t.status = "rejected", t.reason = e);
|
|
84
|
+
})), t.status) {
|
|
85
|
+
case "fulfilled":
|
|
86
|
+
return t.value;
|
|
87
|
+
case "rejected":
|
|
88
|
+
throw t.reason;
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
throw t;
|
|
92
|
+
}
|
|
93
|
+
function p(t, e, u, r, o) {
|
|
94
|
+
var s = typeof t;
|
|
95
|
+
(s === "undefined" || s === "boolean") && (t = null);
|
|
96
|
+
var f = !1;
|
|
97
|
+
if (t === null) f = !0;
|
|
98
|
+
else switch (s) {
|
|
99
|
+
case "bigint":
|
|
100
|
+
case "string":
|
|
101
|
+
case "number":
|
|
102
|
+
f = !0;
|
|
103
|
+
break;
|
|
104
|
+
case "object":
|
|
105
|
+
switch (t.$$typeof) {
|
|
106
|
+
case l:
|
|
107
|
+
case A:
|
|
108
|
+
f = !0;
|
|
109
|
+
break;
|
|
110
|
+
case H:
|
|
111
|
+
return f = t._init, p(f(t._payload), e, u, r, o);
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
if (f) return o = o(t), f = r === "" ? "." + h(t, 0) : r, k(o) ? (u = "", f != null && (u = f.replace(L, "$&/") + "/"), p(o, e, u, "", function(K) {
|
|
115
|
+
return K;
|
|
116
|
+
})) : o != null && (g(o) && (o = W(o, u + (o.key == null || t && t.key === o.key ? "" : ("" + o.key).replace(L, "$&/") + "/") + f)), e.push(o)), 1;
|
|
117
|
+
f = 0;
|
|
118
|
+
var _ = r === "" ? "." : r + ":";
|
|
119
|
+
if (k(t)) for (var c = 0; c < t.length; c++) r = t[c], s = _ + h(r, c), f += p(r, e, u, s, o);
|
|
120
|
+
else if (c = B(t), typeof c == "function") for (t = c.call(t), c = 0; !(r = t.next()).done; ) r = r.value, s = _ + h(r, c++), f += p(r, e, u, s, o);
|
|
121
|
+
else if (s === "object") {
|
|
122
|
+
if (typeof t.then == "function") return p(Q(t), e, u, r, o);
|
|
123
|
+
throw e = String(t), Error("Objects are not valid as a React child (found: " + (e === "[object Object]" ? "object with keys {" + Object.keys(t).join(", ") + "}" : e) + "). If you meant to render a collection of children, use an array instead.");
|
|
124
|
+
}
|
|
125
|
+
return f;
|
|
126
|
+
}
|
|
127
|
+
function m(t, e, u) {
|
|
128
|
+
if (t == null) return t;
|
|
129
|
+
var r = [], o = 0;
|
|
130
|
+
return p(t, r, "", "", function(s) {
|
|
131
|
+
return e.call(u, s, o++);
|
|
132
|
+
}), r;
|
|
133
|
+
}
|
|
134
|
+
function X(t) {
|
|
135
|
+
if (t._status === -1) {
|
|
136
|
+
var e = t._result;
|
|
137
|
+
e = e(), e.then(function(u) {
|
|
138
|
+
(t._status === 0 || t._status === -1) && (t._status = 1, t._result = u);
|
|
139
|
+
}, function(u) {
|
|
140
|
+
(t._status === 0 || t._status === -1) && (t._status = 2, t._result = u);
|
|
141
|
+
}), t._status === -1 && (t._status = 0, t._result = e);
|
|
142
|
+
}
|
|
143
|
+
if (t._status === 1) return t._result.default;
|
|
144
|
+
throw t._result;
|
|
145
|
+
}
|
|
146
|
+
var U = typeof reportError == "function" ? reportError : function(t) {
|
|
147
|
+
if (typeof window == "object" && typeof window.ErrorEvent == "function") {
|
|
148
|
+
var e = new window.ErrorEvent("error", {
|
|
149
|
+
bubbles: !0,
|
|
150
|
+
cancelable: !0,
|
|
151
|
+
message: typeof t == "object" && t !== null && typeof t.message == "string" ? String(t.message) : String(t),
|
|
152
|
+
error: t
|
|
153
|
+
});
|
|
154
|
+
if (!window.dispatchEvent(e)) return;
|
|
155
|
+
} else if (typeof process == "object" && typeof process.emit == "function") {
|
|
156
|
+
process.emit("uncaughtException", t);
|
|
157
|
+
return;
|
|
158
|
+
}
|
|
159
|
+
console.error(t);
|
|
160
|
+
}, Z = {
|
|
161
|
+
map: m,
|
|
162
|
+
forEach: function(t, e, u) {
|
|
163
|
+
m(t, function() {
|
|
164
|
+
e.apply(this, arguments);
|
|
165
|
+
}, u);
|
|
166
|
+
},
|
|
167
|
+
count: function(t) {
|
|
168
|
+
var e = 0;
|
|
169
|
+
return m(t, function() {
|
|
170
|
+
e++;
|
|
171
|
+
}), e;
|
|
172
|
+
},
|
|
173
|
+
toArray: function(t) {
|
|
174
|
+
return m(t, function(e) {
|
|
175
|
+
return e;
|
|
176
|
+
}) || [];
|
|
177
|
+
},
|
|
178
|
+
only: function(t) {
|
|
179
|
+
if (!g(t)) throw Error("React.Children.only expected to receive a single React element child.");
|
|
180
|
+
return t;
|
|
181
|
+
}
|
|
182
|
+
};
|
|
183
|
+
n.Activity = G, n.Children = Z, n.Component = E, n.Fragment = R, n.Profiler = a, n.PureComponent = d, n.StrictMode = S, n.Suspense = b, n.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE = i, n.__COMPILER_RUNTIME = {
|
|
184
|
+
__proto__: null,
|
|
185
|
+
c: function(t) {
|
|
186
|
+
return i.H.useMemoCache(t);
|
|
187
|
+
}
|
|
188
|
+
}, n.cache = function(t) {
|
|
189
|
+
return function() {
|
|
190
|
+
return t.apply(null, arguments);
|
|
191
|
+
};
|
|
192
|
+
}, n.cacheSignal = function() {
|
|
193
|
+
return null;
|
|
194
|
+
}, n.cloneElement = function(t, e, u) {
|
|
195
|
+
if (t == null) throw Error("The argument must be a React element, but you passed " + t + ".");
|
|
196
|
+
var r = $({}, t.props), o = t.key;
|
|
197
|
+
if (e != null) for (s in e.key !== void 0 && (o = "" + e.key), e) !I.call(e, s) || s === "key" || s === "__self" || s === "__source" || s === "ref" && e.ref === void 0 || (r[s] = e[s]);
|
|
198
|
+
var s = arguments.length - 2;
|
|
199
|
+
if (s === 1) r.children = u;
|
|
200
|
+
else if (1 < s) {
|
|
201
|
+
for (var f = Array(s), _ = 0; _ < s; _++) f[_] = arguments[_ + 2];
|
|
202
|
+
r.children = f;
|
|
203
|
+
}
|
|
204
|
+
return j(t.type, o, r);
|
|
205
|
+
}, n.createContext = function(t) {
|
|
206
|
+
return t = {
|
|
207
|
+
$$typeof: y,
|
|
208
|
+
_currentValue: t,
|
|
209
|
+
_currentValue2: t,
|
|
210
|
+
_threadCount: 0,
|
|
211
|
+
Provider: null,
|
|
212
|
+
Consumer: null
|
|
213
|
+
}, t.Provider = t, t.Consumer = {
|
|
214
|
+
$$typeof: v,
|
|
215
|
+
_context: t
|
|
216
|
+
}, t;
|
|
217
|
+
}, n.createElement = function(t, e, u) {
|
|
218
|
+
var r, o = {}, s = null;
|
|
219
|
+
if (e != null) for (r in e.key !== void 0 && (s = "" + e.key), e) I.call(e, r) && r !== "key" && r !== "__self" && r !== "__source" && (o[r] = e[r]);
|
|
220
|
+
var f = arguments.length - 2;
|
|
221
|
+
if (f === 1) o.children = u;
|
|
222
|
+
else if (1 < f) {
|
|
223
|
+
for (var _ = Array(f), c = 0; c < f; c++) _[c] = arguments[c + 2];
|
|
224
|
+
o.children = _;
|
|
225
|
+
}
|
|
226
|
+
if (t && t.defaultProps) for (r in f = t.defaultProps, f) o[r] === void 0 && (o[r] = f[r]);
|
|
227
|
+
return j(t, s, o);
|
|
228
|
+
}, n.createRef = function() {
|
|
229
|
+
return { current: null };
|
|
230
|
+
}, n.forwardRef = function(t) {
|
|
231
|
+
return {
|
|
232
|
+
$$typeof: T,
|
|
233
|
+
render: t
|
|
234
|
+
};
|
|
235
|
+
}, n.isValidElement = g, n.lazy = function(t) {
|
|
236
|
+
return {
|
|
237
|
+
$$typeof: H,
|
|
238
|
+
_payload: {
|
|
239
|
+
_status: -1,
|
|
240
|
+
_result: t
|
|
241
|
+
},
|
|
242
|
+
_init: X
|
|
243
|
+
};
|
|
244
|
+
}, n.memo = function(t, e) {
|
|
245
|
+
return {
|
|
246
|
+
$$typeof: z,
|
|
247
|
+
type: t,
|
|
248
|
+
compare: e === void 0 ? null : e
|
|
249
|
+
};
|
|
250
|
+
}, n.startTransition = function(t) {
|
|
251
|
+
var e = i.T, u = {};
|
|
252
|
+
i.T = u;
|
|
253
|
+
try {
|
|
254
|
+
var r = t(), o = i.S;
|
|
255
|
+
o !== null && o(u, r), typeof r == "object" && r !== null && typeof r.then == "function" && r.then(w, U);
|
|
256
|
+
} catch (s) {
|
|
257
|
+
U(s);
|
|
258
|
+
} finally {
|
|
259
|
+
e !== null && u.types !== null && (e.types = u.types), i.T = e;
|
|
260
|
+
}
|
|
261
|
+
}, n.unstable_useCacheRefresh = function() {
|
|
262
|
+
return i.H.useCacheRefresh();
|
|
263
|
+
}, n.use = function(t) {
|
|
264
|
+
return i.H.use(t);
|
|
265
|
+
}, n.useActionState = function(t, e, u) {
|
|
266
|
+
return i.H.useActionState(t, e, u);
|
|
267
|
+
}, n.useCallback = function(t, e) {
|
|
268
|
+
return i.H.useCallback(t, e);
|
|
269
|
+
}, n.useContext = function(t) {
|
|
270
|
+
return i.H.useContext(t);
|
|
271
|
+
}, n.useDebugValue = function() {
|
|
272
|
+
}, n.useDeferredValue = function(t, e) {
|
|
273
|
+
return i.H.useDeferredValue(t, e);
|
|
274
|
+
}, n.useEffect = function(t, e) {
|
|
275
|
+
return i.H.useEffect(t, e);
|
|
276
|
+
}, n.useEffectEvent = function(t) {
|
|
277
|
+
return i.H.useEffectEvent(t);
|
|
278
|
+
}, n.useId = function() {
|
|
279
|
+
return i.H.useId();
|
|
280
|
+
}, n.useImperativeHandle = function(t, e, u) {
|
|
281
|
+
return i.H.useImperativeHandle(t, e, u);
|
|
282
|
+
}, n.useInsertionEffect = function(t, e) {
|
|
283
|
+
return i.H.useInsertionEffect(t, e);
|
|
284
|
+
}, n.useLayoutEffect = function(t, e) {
|
|
285
|
+
return i.H.useLayoutEffect(t, e);
|
|
286
|
+
}, n.useMemo = function(t, e) {
|
|
287
|
+
return i.H.useMemo(t, e);
|
|
288
|
+
}, n.useOptimistic = function(t, e) {
|
|
289
|
+
return i.H.useOptimistic(t, e);
|
|
290
|
+
}, n.useReducer = function(t, e, u) {
|
|
291
|
+
return i.H.useReducer(t, e, u);
|
|
292
|
+
}, n.useRef = function(t) {
|
|
293
|
+
return i.H.useRef(t);
|
|
294
|
+
}, n.useState = function(t) {
|
|
295
|
+
return i.H.useState(t);
|
|
296
|
+
}, n.useSyncExternalStore = function(t, e, u) {
|
|
297
|
+
return i.H.useSyncExternalStore(t, e, u);
|
|
298
|
+
}, n.useTransition = function() {
|
|
299
|
+
return i.H.useTransition();
|
|
300
|
+
}, n.version = "19.2.8";
|
|
301
|
+
})), tt = /* @__PURE__ */ C(((n, l) => {
|
|
302
|
+
l.exports = x();
|
|
303
|
+
})), q = /* @__PURE__ */ V(tt(), 1), D = (0, q.createContext)(F()), rt = D.Provider, ut = () => (0, q.useContext)(D), et = /* @__PURE__ */ C(((n) => {
|
|
304
|
+
var l = /* @__PURE__ */ Symbol.for("react.transitional.element"), A = /* @__PURE__ */ Symbol.for("react.fragment");
|
|
305
|
+
function R(S, a, v) {
|
|
306
|
+
var y = null;
|
|
307
|
+
if (v !== void 0 && (y = "" + v), a.key !== void 0 && (y = "" + a.key), "key" in a) {
|
|
308
|
+
v = {};
|
|
309
|
+
for (var T in a) T !== "key" && (v[T] = a[T]);
|
|
310
|
+
} else v = a;
|
|
311
|
+
return a = v.ref, {
|
|
312
|
+
$$typeof: l,
|
|
313
|
+
type: S,
|
|
314
|
+
key: y,
|
|
315
|
+
ref: a !== void 0 ? a : null,
|
|
316
|
+
props: v
|
|
317
|
+
};
|
|
318
|
+
}
|
|
319
|
+
n.Fragment = A, n.jsx = R, n.jsxs = R;
|
|
320
|
+
})), ot = /* @__PURE__ */ C(((n, l) => {
|
|
321
|
+
l.exports = et();
|
|
322
|
+
}));
|
|
323
|
+
export {
|
|
324
|
+
tt as i,
|
|
325
|
+
rt as n,
|
|
326
|
+
ut as r,
|
|
327
|
+
ot as t
|
|
328
|
+
};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
function o(n) {
|
|
2
|
+
return !n || typeof n != "object" ? "" : "position" in n || "type" in n ? t(n.position) : "start" in n || "end" in n ? t(n) : "line" in n || "column" in n ? i(n) : "";
|
|
3
|
+
}
|
|
4
|
+
function i(n) {
|
|
5
|
+
return r(n && n.line) + ":" + r(n && n.column);
|
|
6
|
+
}
|
|
7
|
+
function t(n) {
|
|
8
|
+
return i(n && n.start) + "-" + i(n && n.end);
|
|
9
|
+
}
|
|
10
|
+
function r(n) {
|
|
11
|
+
return n && typeof n == "number" ? n : 1;
|
|
12
|
+
}
|
|
13
|
+
export {
|
|
14
|
+
o as t
|
|
15
|
+
};
|
package/dist/loader.d.ts
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 配信版ウィジェット (widget.js) の自己起動エントリ。
|
|
3
|
+
*
|
|
4
|
+
* `<script src=".../v1/widget.js" data-api-key="...">` の 1 行だけで動くよう、
|
|
5
|
+
* 自身の `<script>` タグの `data-*` 属性から設定を読み取り `initWecoolChat` を呼ぶ。
|
|
6
|
+
* npm 版 (`import { initWecoolChat }`) の公開 API は一切変えず、この loader は
|
|
7
|
+
* その薄い自己起動ラッパに徹する。
|
|
8
|
+
*
|
|
9
|
+
* ビルドは `vite.config.loader.ts` が IIFE + CSS 内包の単一ファイル dist/widget.js に固める。
|
|
10
|
+
*/
|
|
11
|
+
export {};
|
|
12
|
+
//# sourceMappingURL=loader.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"loader.d.ts","sourceRoot":"","sources":["../src/loader.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG"}
|
|
@@ -0,0 +1,247 @@
|
|
|
1
|
+
var m = Object.create, i = Object.defineProperty, v = Object.getOwnPropertyDescriptor, h = Object.getOwnPropertyNames, L = Object.getPrototypeOf, p = Object.prototype.hasOwnProperty, b = (e, o) => () => (o || (e((o = { exports: {} }).exports, o), e = null), o.exports), f = (e, o) => {
|
|
2
|
+
let n = {};
|
|
3
|
+
for (var a in e)
|
|
4
|
+
i(n, a, {
|
|
5
|
+
get: e[a],
|
|
6
|
+
enumerable: !0
|
|
7
|
+
});
|
|
8
|
+
return o || i(n, Symbol.toStringTag, { value: "Module" }), n;
|
|
9
|
+
}, C = (e, o, n, a) => {
|
|
10
|
+
if (o && typeof o == "object" || typeof o == "function")
|
|
11
|
+
for (var c = h(o), r = 0, g = c.length, t; r < g; r++)
|
|
12
|
+
t = c[r], !p.call(e, t) && t !== n && i(e, t, {
|
|
13
|
+
get: ((u) => o[u]).bind(null, t),
|
|
14
|
+
enumerable: !(a = v(o, t)) || a.enumerable
|
|
15
|
+
});
|
|
16
|
+
return e;
|
|
17
|
+
}, y = (e, o, n) => (n = e != null ? m(L(e)) : {}, C(o || !e || !e.__esModule || !p.call(e, "default") ? i(n, "default", {
|
|
18
|
+
value: e,
|
|
19
|
+
enumerable: !0
|
|
20
|
+
}) : n, e)), d = {
|
|
21
|
+
inputPlaceholder: "メッセージを入力...",
|
|
22
|
+
emptyState: "メッセージを入力してください",
|
|
23
|
+
errorGeneric: "エラーが発生しました。しばらくしてからお試しください。",
|
|
24
|
+
stopButton: "停止",
|
|
25
|
+
sendButton: "送信",
|
|
26
|
+
newConversationAction: "新しい会話を始める",
|
|
27
|
+
closeButton: "閉じる",
|
|
28
|
+
closeChat: "チャットを閉じる",
|
|
29
|
+
openChat: "チャットを開く",
|
|
30
|
+
responseStoppedAnnouncement: "応答を停止しました",
|
|
31
|
+
messageActionsToggle: "メッセージアクションを表示",
|
|
32
|
+
regenerateLabel: "再生成",
|
|
33
|
+
regenerateAria: "メッセージを再生成",
|
|
34
|
+
copyLabel: "コピー",
|
|
35
|
+
copiedLabel: "コピーしました",
|
|
36
|
+
copyMessageAria: "メッセージをコピー",
|
|
37
|
+
copyMessageAnnouncement: "メッセージをコピーしました",
|
|
38
|
+
copyCodeAria: "コードをコピー",
|
|
39
|
+
copyCodeAnnouncement: "コードをコピーしました",
|
|
40
|
+
editLabel: "編集",
|
|
41
|
+
editMessageAria: "メッセージを編集",
|
|
42
|
+
cancelEditLabel: "キャンセル",
|
|
43
|
+
cancelEditAria: "編集をキャンセル",
|
|
44
|
+
saveEditAria: "編集を保存して送信",
|
|
45
|
+
chatDialogTitle: "wecool チャット",
|
|
46
|
+
chatDialogDescription: "AI チャットアシスタント",
|
|
47
|
+
messageLogLabel: "チャット履歴",
|
|
48
|
+
loadingAnnouncement: "AI が応答を生成中",
|
|
49
|
+
inputLabel: "メッセージを入力",
|
|
50
|
+
downloadAttachment: "ダウンロード",
|
|
51
|
+
dragHandleLabel: "ドラッグまたは矢印キーでウィンドウを移動",
|
|
52
|
+
resizeHandleLabel: "ドラッグまたは矢印キーでウィンドウのサイズを変更",
|
|
53
|
+
resetPositionButton: "位置とサイズをリセット",
|
|
54
|
+
settingsMenuToggle: "設定メニューを開く",
|
|
55
|
+
fullscreenToggle: "全画面表示",
|
|
56
|
+
fullscreenOn: "全画面表示 オン",
|
|
57
|
+
fullscreenOff: "全画面表示 オフ",
|
|
58
|
+
newConversationOption: "+ 新しい会話",
|
|
59
|
+
conversationSelectLabel: "会話を選択",
|
|
60
|
+
stopFallbackUserMessage: "処理を中断しました。",
|
|
61
|
+
maxTurnsReached: "最大試行回数に達しました。条件を変えてもう一度お試しください。",
|
|
62
|
+
errorMessageTooLong: "メッセージが長すぎます。10,000 文字以内に収めてください。",
|
|
63
|
+
errorInvalidRequest: "リクエストの形式が正しくありません。",
|
|
64
|
+
errorRateLimit: "アクセスが集中しています。1 分ほど待ってからもう一度お試しください。",
|
|
65
|
+
errorDailyLimit: "本日の利用上限に達しました。明日以降にもう一度お試しください。",
|
|
66
|
+
errorMonthlyLimit: "今月の利用上限に達しました。プランの利用状況をご確認ください。",
|
|
67
|
+
qrcodeStopTextTooLong: "テキストが長すぎます。{max} 文字以内に収めてもう一度お試しください。",
|
|
68
|
+
toolConfirmationPrompt: "この操作を実行しますか?",
|
|
69
|
+
toolConfirmationApprove: "実行する",
|
|
70
|
+
toolConfirmationCancel: "キャンセル",
|
|
71
|
+
toolConfirmationRegionLabel: "操作の実行確認",
|
|
72
|
+
toolConfirmationApprovedLabel: "実行を承認しました",
|
|
73
|
+
toolConfirmationDeclinedLabel: "キャンセルしました",
|
|
74
|
+
commandPaletteLabel: "コマンド",
|
|
75
|
+
commandToolsDescription: "このAIができること",
|
|
76
|
+
commandClearDescription: "会話をクリア",
|
|
77
|
+
commandNewDescription: "新しい会話を始める",
|
|
78
|
+
commandLangJaDescription: "表示を日本語に切り替え",
|
|
79
|
+
commandLangEnDescription: "表示を英語に切り替え",
|
|
80
|
+
commandHelpDescription: "コマンドの使い方",
|
|
81
|
+
toolsDialogTitle: "このAIができること",
|
|
82
|
+
toolsDialogDescription: "利用できる操作と、聞き方の例の一覧です。例を選ぶと入力欄に挿入されます。",
|
|
83
|
+
toolsDialogEmpty: "利用できるツールはありません。",
|
|
84
|
+
helpDialogTitle: "コマンドの使い方",
|
|
85
|
+
helpDialogDescription: "入力欄の先頭で / を入力すると、以下のコマンドを実行できます。",
|
|
86
|
+
commandClearConfirmMessage: "会話の表示をクリアして新しい会話を始めます。よろしいですか?",
|
|
87
|
+
commandClearConfirmApprove: "クリアする",
|
|
88
|
+
commandClearConfirmCancel: "キャンセル",
|
|
89
|
+
commandClearConfirmRegionLabel: "会話クリアの確認",
|
|
90
|
+
resetHistoryMenuItem: "すべての履歴をこのブラウザから消す",
|
|
91
|
+
resetHistoryConfirmMessage: "このブラウザから会話履歴と入力履歴が見えなくなります。サーバー上の会話データは保持期間の経過後に自動削除されます。この操作は取り消せません。よろしいですか?",
|
|
92
|
+
resetHistoryConfirmRegionLabel: "履歴削除の確認",
|
|
93
|
+
deleteConversationMenuItem: "この会話を削除",
|
|
94
|
+
deleteConversationConfirmMessage: "表示中の会話をサーバーから完全に削除します。この操作は取り消せません。よろしいですか?",
|
|
95
|
+
deleteConversationConfirmRegionLabel: "会話削除の確認",
|
|
96
|
+
deleteConversationFailed: "会話の削除に失敗しました。しばらくしてからもう一度お試しください。",
|
|
97
|
+
voiceInputButtonAria: "音声入力",
|
|
98
|
+
voiceInputListeningAria: "聞き取り中(クリックで停止)",
|
|
99
|
+
voiceInputListeningAnnouncement: "聞き取り中です",
|
|
100
|
+
voiceInputErrorPermissionDenied: "マイクの使用が許可されていません",
|
|
101
|
+
voiceInputErrorNoMatch: "聞き取れませんでした",
|
|
102
|
+
voiceInputErrorTimeout: "発話が検出されませんでした",
|
|
103
|
+
voiceInputErrorNetwork: "通信エラーが発生しました",
|
|
104
|
+
voiceInputErrorDeviceUnavailable: "マイクを使用できません",
|
|
105
|
+
voiceInputErrorLanguageUnsupported: "この言語は音声入力に対応していません",
|
|
106
|
+
voiceLoopStartCue: "どうぞ",
|
|
107
|
+
voiceLoopToggleStartAria: "継続音声モードを開始",
|
|
108
|
+
voiceLoopToggleStopAria: "継続音声モードを終了",
|
|
109
|
+
voiceLoopStatusListening: "聞いています",
|
|
110
|
+
voiceLoopStatusThinking: "考えています",
|
|
111
|
+
voiceLoopStatusSpeaking: "話しています",
|
|
112
|
+
voiceLoopStatusAwaitingConfirmation: "確認を待っています",
|
|
113
|
+
voiceLoopStopButton: "終了",
|
|
114
|
+
voiceLoopEndedSilence: "しばらく聞き取れなかったため、継続音声モードを終了しました",
|
|
115
|
+
voiceLoopEndedNetwork: "通信に失敗したため、継続音声モードを終了しました",
|
|
116
|
+
voiceLoopEndedPermission: "マイクの使用が許可されていないため、継続音声モードを終了しました",
|
|
117
|
+
voiceLoopEndedDevice: "マイクを使用できないため、継続音声モードを終了しました",
|
|
118
|
+
voiceLoopEndedLanguage: "この言語は音声入力に対応していないため、継続音声モードを終了しました",
|
|
119
|
+
speechCodeBlockLabel: "コードブロック",
|
|
120
|
+
speechTableLabel: "表",
|
|
121
|
+
speechTruncatedNotice: "長いため、この先の読み上げを省略します",
|
|
122
|
+
speakMessageLabel: "読み上げ",
|
|
123
|
+
speakMessageAria: "メッセージを読み上げる",
|
|
124
|
+
stopSpeakingLabel: "停止",
|
|
125
|
+
stopSpeakingAria: "読み上げを停止"
|
|
126
|
+
}, l = {
|
|
127
|
+
ja: d,
|
|
128
|
+
en: {
|
|
129
|
+
inputPlaceholder: "Type a message...",
|
|
130
|
+
emptyState: "Type a message to get started",
|
|
131
|
+
errorGeneric: "An error occurred. Please try again later.",
|
|
132
|
+
stopButton: "Stop",
|
|
133
|
+
sendButton: "Send",
|
|
134
|
+
newConversationAction: "Start a new conversation",
|
|
135
|
+
closeButton: "Close",
|
|
136
|
+
closeChat: "Close chat",
|
|
137
|
+
openChat: "Open chat",
|
|
138
|
+
responseStoppedAnnouncement: "Response stopped",
|
|
139
|
+
messageActionsToggle: "Show message actions",
|
|
140
|
+
regenerateLabel: "Regenerate",
|
|
141
|
+
regenerateAria: "Regenerate message",
|
|
142
|
+
copyLabel: "Copy",
|
|
143
|
+
copiedLabel: "Copied",
|
|
144
|
+
copyMessageAria: "Copy message",
|
|
145
|
+
copyMessageAnnouncement: "Message copied",
|
|
146
|
+
copyCodeAria: "Copy code",
|
|
147
|
+
copyCodeAnnouncement: "Code copied",
|
|
148
|
+
editLabel: "Edit",
|
|
149
|
+
editMessageAria: "Edit message",
|
|
150
|
+
cancelEditLabel: "Cancel",
|
|
151
|
+
cancelEditAria: "Cancel editing",
|
|
152
|
+
saveEditAria: "Save edit",
|
|
153
|
+
chatDialogTitle: "wecool chat",
|
|
154
|
+
chatDialogDescription: "AI chat assistant",
|
|
155
|
+
messageLogLabel: "Chat history",
|
|
156
|
+
loadingAnnouncement: "AI is generating a response",
|
|
157
|
+
inputLabel: "Type a message",
|
|
158
|
+
downloadAttachment: "Download",
|
|
159
|
+
dragHandleLabel: "Drag or use arrow keys to move the window",
|
|
160
|
+
resizeHandleLabel: "Drag or use arrow keys to resize the window",
|
|
161
|
+
resetPositionButton: "Reset position and size",
|
|
162
|
+
settingsMenuToggle: "Open settings menu",
|
|
163
|
+
fullscreenToggle: "Fullscreen",
|
|
164
|
+
fullscreenOn: "Fullscreen on",
|
|
165
|
+
fullscreenOff: "Fullscreen off",
|
|
166
|
+
newConversationOption: "+ New conversation",
|
|
167
|
+
conversationSelectLabel: "Select conversation",
|
|
168
|
+
stopFallbackUserMessage: "The action was stopped.",
|
|
169
|
+
maxTurnsReached: "Reached the maximum tool retry limit. Please try again with different input.",
|
|
170
|
+
errorMessageTooLong: "Message is too long. Please keep it within 10,000 characters.",
|
|
171
|
+
errorInvalidRequest: "The request format is invalid.",
|
|
172
|
+
errorRateLimit: "Too many requests right now. Please wait about a minute and try again.",
|
|
173
|
+
errorDailyLimit: "The daily usage limit has been reached. Please try again tomorrow.",
|
|
174
|
+
errorMonthlyLimit: "The monthly usage limit has been reached. Please check your plan usage.",
|
|
175
|
+
qrcodeStopTextTooLong: "The text is too long. Please shorten it to within {max} characters and try again.",
|
|
176
|
+
toolConfirmationPrompt: "Do you want to run this action?",
|
|
177
|
+
toolConfirmationApprove: "Run",
|
|
178
|
+
toolConfirmationCancel: "Cancel",
|
|
179
|
+
toolConfirmationRegionLabel: "Action confirmation",
|
|
180
|
+
toolConfirmationApprovedLabel: "Approved",
|
|
181
|
+
toolConfirmationDeclinedLabel: "Cancelled",
|
|
182
|
+
commandPaletteLabel: "Commands",
|
|
183
|
+
commandToolsDescription: "What this AI can do",
|
|
184
|
+
commandClearDescription: "Clear the conversation",
|
|
185
|
+
commandNewDescription: "Start a new conversation",
|
|
186
|
+
commandLangJaDescription: "Switch the display to Japanese",
|
|
187
|
+
commandLangEnDescription: "Switch the display to English",
|
|
188
|
+
commandHelpDescription: "How to use commands",
|
|
189
|
+
toolsDialogTitle: "What you can ask",
|
|
190
|
+
toolsDialogDescription: "A list of available actions and example prompts. Select an example to insert it into the input.",
|
|
191
|
+
toolsDialogEmpty: "No tools are available.",
|
|
192
|
+
helpDialogTitle: "How to use commands",
|
|
193
|
+
helpDialogDescription: "Type / at the start of the input field to run one of the commands below.",
|
|
194
|
+
commandClearConfirmMessage: "This will clear the current conversation from view and start a new one. Continue?",
|
|
195
|
+
commandClearConfirmApprove: "Clear",
|
|
196
|
+
commandClearConfirmCancel: "Cancel",
|
|
197
|
+
commandClearConfirmRegionLabel: "Confirm clearing the conversation",
|
|
198
|
+
resetHistoryMenuItem: "Clear all history from this browser",
|
|
199
|
+
resetHistoryConfirmMessage: "Your conversation history and input history will no longer be accessible from this browser. Conversation data on the server is automatically deleted after the retention period. This action cannot be undone. Are you sure?",
|
|
200
|
+
resetHistoryConfirmRegionLabel: "Confirm clearing history from this browser",
|
|
201
|
+
deleteConversationMenuItem: "Delete this conversation",
|
|
202
|
+
deleteConversationConfirmMessage: "This will permanently delete the current conversation from the server. This action cannot be undone. Are you sure?",
|
|
203
|
+
deleteConversationConfirmRegionLabel: "Confirm deleting this conversation",
|
|
204
|
+
deleteConversationFailed: "Failed to delete the conversation. Please try again later.",
|
|
205
|
+
voiceInputButtonAria: "Voice input",
|
|
206
|
+
voiceInputListeningAria: "Listening (click to stop)",
|
|
207
|
+
voiceInputListeningAnnouncement: "Listening",
|
|
208
|
+
voiceInputErrorPermissionDenied: "Microphone access was denied",
|
|
209
|
+
voiceInputErrorNoMatch: "No speech was recognized",
|
|
210
|
+
voiceInputErrorTimeout: "No speech was detected",
|
|
211
|
+
voiceInputErrorNetwork: "A network error occurred",
|
|
212
|
+
voiceInputErrorDeviceUnavailable: "The microphone could not be used",
|
|
213
|
+
voiceInputErrorLanguageUnsupported: "Voice input is not available for this language",
|
|
214
|
+
voiceLoopStartCue: "Go ahead",
|
|
215
|
+
voiceLoopToggleStartAria: "Start continuous voice mode",
|
|
216
|
+
voiceLoopToggleStopAria: "Stop continuous voice mode",
|
|
217
|
+
voiceLoopStatusListening: "Listening",
|
|
218
|
+
voiceLoopStatusThinking: "Thinking",
|
|
219
|
+
voiceLoopStatusSpeaking: "Speaking",
|
|
220
|
+
voiceLoopStatusAwaitingConfirmation: "Waiting for your confirmation",
|
|
221
|
+
voiceLoopStopButton: "Stop",
|
|
222
|
+
voiceLoopEndedSilence: "Continuous voice mode ended because nothing was heard for a while",
|
|
223
|
+
voiceLoopEndedNetwork: "Continuous voice mode ended because of a network problem",
|
|
224
|
+
voiceLoopEndedPermission: "Continuous voice mode ended because microphone access was denied",
|
|
225
|
+
voiceLoopEndedDevice: "Continuous voice mode ended because the microphone could not be used",
|
|
226
|
+
voiceLoopEndedLanguage: "Continuous voice mode ended because this language is not supported",
|
|
227
|
+
speechCodeBlockLabel: "code block",
|
|
228
|
+
speechTableLabel: "table",
|
|
229
|
+
speechTruncatedNotice: "The rest is too long to read aloud.",
|
|
230
|
+
speakMessageLabel: "Read aloud",
|
|
231
|
+
speakMessageAria: "Read message aloud",
|
|
232
|
+
stopSpeakingLabel: "Stop",
|
|
233
|
+
stopSpeakingAria: "Stop reading aloud"
|
|
234
|
+
}
|
|
235
|
+
}, A = (e) => e && l[e] ? l[e] : d, s = (e) => e !== void 0 && e.length > 0 ? e : void 0, w = (e, o) => {
|
|
236
|
+
if (e === void 0) return;
|
|
237
|
+
if (typeof e == "string") return s(e);
|
|
238
|
+
const n = o === "ja" ? "en" : "ja";
|
|
239
|
+
return s(e[o]) ?? s(e[n]);
|
|
240
|
+
};
|
|
241
|
+
export {
|
|
242
|
+
y as a,
|
|
243
|
+
f as i,
|
|
244
|
+
w as n,
|
|
245
|
+
b as r,
|
|
246
|
+
A as t
|
|
247
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"format.test.d.ts","sourceRoot":"","sources":["../../../src/observe/__tests__/format.test.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"http.test.d.ts","sourceRoot":"","sources":["../../../src/observe/__tests__/http.test.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.test.d.ts","sourceRoot":"","sources":["../../../src/observe/__tests__/index.test.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"js-error.test.d.ts","sourceRoot":"","sources":["../../../src/observe/__tests__/js-error.test.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"redact.test.d.ts","sourceRoot":"","sources":["../../../src/observe/__tests__/redact.test.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ring-buffer.test.d.ts","sourceRoot":"","sources":["../../../src/observe/__tests__/ring-buffer.test.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { ObservedEvent } from './types';
|
|
2
|
+
/**
|
|
3
|
+
* 観測イベントを LLM へ渡す英語の構造化ブロックに整形する。
|
|
4
|
+
* redact はこの段で適用する(バッファには生値を保持し、送信時にのみマスク)。
|
|
5
|
+
*
|
|
6
|
+
* @param events - リングバッファのスナップショット
|
|
7
|
+
* @returns 背景情報ブロック。イベントが 0 件なら空文字(呼び出し側は付与しない)
|
|
8
|
+
*/
|
|
9
|
+
export declare const formatObserveContext: (events: readonly ObservedEvent[]) => string;
|
|
10
|
+
//# sourceMappingURL=format.d.ts.map
|