@1024pix/epreuves-components 0.9.6 → 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/dist/{ImageQuiz.ce-CAWRCnWK.js → ImageQuiz.ce-BbfMcldf.js} +14 -14
- package/dist/LLMMessage.ce-DBgXmxn9.js +89 -0
- package/dist/Loading.ce-BRzyhDRe.js +14 -0
- package/dist/NavigationButton.ce-RaQYJjPs.js +98 -0
- package/dist/{_plugin-vue_export-helper-DLH45Sxm.js → _plugin-vue_export-helper-CGpZIhKK.js} +23 -23
- package/dist/components/complete-phrase.ce.js.js +100 -0
- package/dist/components/image-quiz.ce.js.js +2 -2
- package/dist/components/image-quizzes.ce.js.js +2 -2
- package/dist/components/llm-compare-messages.ce.js.js +38 -33
- package/dist/components/llm-messages.ce.js.js +5 -4
- package/dist/components/llm-prompt-select.ce.js.js +5 -5
- package/dist/components/message-conversation.ce.js.js +52 -55
- package/dist/components/pix-carousel.ce.js.js +40 -39
- package/dist/components/pix-cursor.ce.js.js +17 -16
- package/dist/i18n-DZYcdfDF.js +1407 -0
- package/dist/index.js +1 -0
- package/dist/metadata.js +11 -8
- package/dist/shadow-dom-BdDj1I6f.js +9 -0
- package/package.json +1 -1
- package/dist/NavigationButton.ce-DrjZmR37.js +0 -1502
- package/dist/shadow-dom-BtcBGuOh.js +0 -89
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { a as B, r as N,
|
|
2
|
-
function
|
|
1
|
+
import { a as B, r as N, y as I, c as d, o as m, z as b, A as f, B as g, v as y, f as h, m as q, t as x, _ as P, q as p, C as L, D as F, F as k, b as O, e as A } from "./_plugin-vue_export-helper-CGpZIhKK.js";
|
|
2
|
+
function M(i, u = T) {
|
|
3
3
|
const a = [...i];
|
|
4
4
|
for (let n = a.length - 1; n > 0; n--) {
|
|
5
5
|
const l = u() % (n + 1);
|
|
@@ -7,10 +7,10 @@ function T(i, u = A) {
|
|
|
7
7
|
}
|
|
8
8
|
return a;
|
|
9
9
|
}
|
|
10
|
-
function
|
|
10
|
+
function T() {
|
|
11
11
|
return Math.floor(Math.random() * 2 ** 32);
|
|
12
12
|
}
|
|
13
|
-
const
|
|
13
|
+
const D = ["aria-labelledby", "aria-selected", "tabindex"], K = { key: 0 }, Q = ["id"], R = ["id"], E = /* @__PURE__ */ B({
|
|
14
14
|
__name: "ImageOption.ce",
|
|
15
15
|
props: {
|
|
16
16
|
choice: { type: Object },
|
|
@@ -43,7 +43,7 @@ const K = ["aria-labelledby", "aria-selected", "tabindex"], Q = { key: 0 }, R =
|
|
|
43
43
|
t[3] || (t[3] = b(f((r) => o.$emit("next"), ["stop", "prevent"]), ["down", "right"]))
|
|
44
44
|
]
|
|
45
45
|
}, [
|
|
46
|
-
o.choice.image ? (m(), d("figure",
|
|
46
|
+
o.choice.image ? (m(), d("figure", K, [
|
|
47
47
|
h("img", q(o.choice.image, {
|
|
48
48
|
class: o.imageClass,
|
|
49
49
|
alt: ""
|
|
@@ -51,12 +51,12 @@ const K = ["aria-labelledby", "aria-selected", "tabindex"], Q = { key: 0 }, R =
|
|
|
51
51
|
h("figcaption", {
|
|
52
52
|
class: y(o.nameClass),
|
|
53
53
|
id: g(s)
|
|
54
|
-
}, x(o.choice.name), 11,
|
|
54
|
+
}, x(o.choice.name), 11, Q)
|
|
55
55
|
])) : (m(), d("span", {
|
|
56
56
|
key: 1,
|
|
57
57
|
id: g(s)
|
|
58
|
-
}, x(o.choice.name), 9,
|
|
59
|
-
], 42,
|
|
58
|
+
}, x(o.choice.name), 9, R))
|
|
59
|
+
], 42, D));
|
|
60
60
|
}
|
|
61
61
|
}), V = '.image-option{display:flex;position:relative;flex-direction:column;align-items:center;justify-content:center;margin:.5rem;border:solid 2px #c1c7d0;border-radius:10px;background:#fff;width:calc(20% - 2em);min-width:150px;padding:1rem}.image-option--max4{width:calc(25% - 2em);min-width:175px}.image-option--max3{width:calc(33% - 2em)}.image-option--max2{width:calc(50% - 2em);min-width:300px}.image-option--max1{width:calc(100% - 4em);min-width:300px}.image-option:hover{cursor:pointer;box-shadow:0 3px 10px #0000001a;transform:scale(1.04);transition:transform ease-in .1s}.image-option:focus{outline:none;box-shadow:5px 5px #ffbe00,-5px 5px #ffbe00,5px -5px #ffbe00,-5px -5px #ffbe00}.image-option[aria-selected=true]{border-color:#3d68ff}.image-option[aria-selected=true]:after{content:"";position:absolute;width:calc(100% + 2px);height:calc(100% + 2px);background:#3d68ff4d;border-radius:10px;z-index:3}.image-option figure{align-items:center;display:flex;flex-direction:column;height:100%;justify-content:center;margin:0;text-align:center;width:100%}.image-option figure img{max-width:100%;height:auto}.image-option figure img.icon{max-height:100px;width:auto}.image-option figure img.medium{max-width:50%;height:auto}.image-option figure figcaption{margin:1ex}', G = /* @__PURE__ */ P(E, [["styles", [V]]]), H = ["id"], J = ["aria-multiselectable", "aria-labelledby"], U = /* @__PURE__ */ B({
|
|
62
62
|
__name: "ImageQuiz.ce",
|
|
@@ -72,7 +72,7 @@ const K = ["aria-labelledby", "aria-selected", "tabindex"], Q = { key: 0 }, R =
|
|
|
72
72
|
},
|
|
73
73
|
emits: ["answer"],
|
|
74
74
|
setup(i, { emit: u }) {
|
|
75
|
-
const a = u, n = p(() => i.hideChoicesName ? "sr-only" : ""), l = p(() => i.orderChoices ? i.choices :
|
|
75
|
+
const a = u, n = p(() => i.hideChoicesName ? "sr-only" : ""), l = p(() => i.orderChoices ? i.choices : M(i.choices)), s = N(new Array(i.choices.length).fill(!1)), o = p(() => l.value.filter((e, $) => s.value[$])), t = p(() => o.value.map((e) => e.response ?? e.name).sort().join(",")), r = I();
|
|
76
76
|
L(t, () => {
|
|
77
77
|
a("answer", t.value);
|
|
78
78
|
}, { immediate: !1 });
|
|
@@ -86,7 +86,7 @@ const K = ["aria-labelledby", "aria-selected", "tabindex"], Q = { key: 0 }, R =
|
|
|
86
86
|
function C(e) {
|
|
87
87
|
e = (e + i.choices.length) % i.choices.length, i.multiple || w(e), v.value[e].focus();
|
|
88
88
|
}
|
|
89
|
-
return (e, $) => (m(), d(
|
|
89
|
+
return (e, $) => (m(), d(k, null, [
|
|
90
90
|
h("label", {
|
|
91
91
|
id: g(r),
|
|
92
92
|
class: y(["image-quiz-label", { "sr-only": !e.showName }])
|
|
@@ -98,7 +98,7 @@ const K = ["aria-labelledby", "aria-selected", "tabindex"], Q = { key: 0 }, R =
|
|
|
98
98
|
"aria-labelledby": g(r),
|
|
99
99
|
"aria-orientation": "horizontal"
|
|
100
100
|
}, [
|
|
101
|
-
(m(!0), d(
|
|
101
|
+
(m(!0), d(k, null, O(l.value, (j, c) => (m(), A(G, {
|
|
102
102
|
ref_for: !0,
|
|
103
103
|
ref_key: "options",
|
|
104
104
|
ref: v,
|
|
@@ -109,9 +109,9 @@ const K = ["aria-labelledby", "aria-selected", "tabindex"], Q = { key: 0 }, R =
|
|
|
109
109
|
"image-class": i.imageChoicesSize,
|
|
110
110
|
selected: s.value[c],
|
|
111
111
|
"tab-focusable": c === S.value,
|
|
112
|
-
onToggle: (
|
|
113
|
-
onNext: (
|
|
114
|
-
onPrevious: (
|
|
112
|
+
onToggle: (z) => w(c),
|
|
113
|
+
onNext: (z) => C(c + 1),
|
|
114
|
+
onPrevious: (z) => C(c - 1)
|
|
115
115
|
}, null, 8, ["choice", "max-choices-per-line", "name-class", "image-class", "selected", "tab-focusable", "onToggle", "onNext", "onPrevious"]))), 128))
|
|
116
116
|
], 8, J)
|
|
117
117
|
], 64));
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
import { _ as b, c as n, o as t, f as s, a as m, q as d, v as g, e as r, x as l, g as u, t as p } from "./_plugin-vue_export-helper-CGpZIhKK.js";
|
|
2
|
+
import { L as f } from "./Loading.ce-BRzyhDRe.js";
|
|
3
|
+
const h = {}, C = {
|
|
4
|
+
height: "1rem",
|
|
5
|
+
width: "auto",
|
|
6
|
+
"aria-hidden": "true",
|
|
7
|
+
role: "img",
|
|
8
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
9
|
+
viewBox: "0 0 448 512"
|
|
10
|
+
};
|
|
11
|
+
function x(o, e) {
|
|
12
|
+
return t(), n("svg", C, e[0] || (e[0] = [
|
|
13
|
+
s("path", {
|
|
14
|
+
fill: "currentColor",
|
|
15
|
+
d: "M364.2 83.8c-24.4-24.4-64-24.4-88.4 0l-184 184c-42.1 42.1-42.1 110.3 0 152.4s110.3 42.1 152.4 0l152-152c10.9-10.9 28.7-10.9 39.6 0s10.9 28.7 0 39.6l-152 152c-64 64-167.6 64-231.6 0s-64-167.6 0-231.6l184-184c46.3-46.3 121.3-46.3 167.6 0s46.3 121.3 0 167.6l-176 176c-28.6 28.6-75 28.6-103.6 0s-28.6-75 0-103.6l144-144c10.9-10.9 28.7-10.9 39.6 0s10.9 28.7 0 39.6l-144 144c-6.7 6.7-6.7 17.7 0 24.4s17.7 6.7 24.4 0l176-176c24.4-24.4 24.4-64 0-88.4z"
|
|
16
|
+
}, null, -1)
|
|
17
|
+
]));
|
|
18
|
+
}
|
|
19
|
+
const y = /* @__PURE__ */ b(h, [["render", x]]), v = {}, w = {
|
|
20
|
+
width: "24",
|
|
21
|
+
height: "24",
|
|
22
|
+
viewBox: "0 0 24 24",
|
|
23
|
+
fill: "none",
|
|
24
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
25
|
+
};
|
|
26
|
+
function _(o, e) {
|
|
27
|
+
return t(), n("svg", w, e[0] || (e[0] = [
|
|
28
|
+
s("path", {
|
|
29
|
+
d: "M5.88 17.0103C6.73 16.3683 7.676 15.8638 8.718 15.4968C9.76 15.1298 10.8544 14.9463 12.0012 14.9463C13.1481 14.9463 14.2451 15.1328 15.2922 15.5058C16.3394 15.8788 17.282 16.3823 18.12 17.0163C18.6915 16.3289 19.1357 15.5629 19.4527 14.7183C19.7697 13.8734 19.9282 12.9673 19.9282 12C19.9282 9.80717 19.1551 7.93759 17.6087 6.39125C16.0624 4.84492 14.1928 4.07175 12 4.07175C9.80717 4.07175 7.93758 4.84492 6.39125 6.39125C4.84492 7.93759 4.07175 9.80717 4.07175 12C4.07175 12.9633 4.22925 13.8674 4.54425 14.7123C4.85925 15.5569 5.3045 16.3229 5.88 17.0103ZM12 13.0538C11.0007 13.0538 10.1596 12.7133 9.47675 12.0323C8.79375 11.3513 8.45225 10.5112 8.45225 9.512C8.45225 8.51267 8.79375 7.6715 9.47675 6.9885C10.1596 6.30567 11.0007 5.96425 12 5.96425C12.9993 5.96425 13.8404 6.30567 14.5232 6.9885C15.2062 7.6715 15.5477 8.51267 15.5477 9.512C15.5477 10.5112 15.2062 11.3513 14.5232 12.0323C13.8404 12.7133 12.9993 13.0538 12 13.0538ZM11.9995 22.2033C10.5887 22.2033 9.26292 21.9358 8.02225 21.4008C6.78175 20.8658 5.7015 20.1383 4.7815 19.2185C3.86167 18.2985 3.13425 17.2181 2.59925 15.9773C2.06425 14.7363 1.79675 13.4103 1.79675 11.9995C1.79675 10.5887 2.06425 9.26292 2.59925 8.02225C3.13425 6.78175 3.86167 5.7015 4.7815 4.7815C5.7015 3.86167 6.78192 3.13425 8.02275 2.59925C9.26375 2.06425 10.5897 1.79675 12.0005 1.79675C13.4113 1.79675 14.7371 2.06425 15.9777 2.59925C17.2182 3.13425 18.2985 3.86167 19.2185 4.7815C20.1383 5.7015 20.8657 6.78192 21.4008 8.02275C21.9358 9.26375 22.2032 10.5897 22.2032 12.0005C22.2032 13.4113 21.9358 14.7371 21.4008 15.9778C20.8657 17.2183 20.1383 18.2985 19.2185 19.2185C18.2985 20.1383 17.2181 20.8658 15.9773 21.4008C14.7362 21.9358 13.4103 22.2033 11.9995 22.2033ZM12 19.9283C12.8633 19.9283 13.6747 19.8041 14.4342 19.5558C15.1936 19.3074 15.8982 18.9495 16.5482 18.482C15.8904 18.0107 15.1867 17.6518 14.4372 17.4055C13.6877 17.159 12.8753 17.0358 12 17.0358C11.1247 17.0358 10.3132 17.159 9.56575 17.4055C8.81825 17.6518 8.1155 18.0107 7.4575 18.482C8.1075 18.9495 8.81125 19.3074 9.56875 19.5558C10.3262 19.8041 11.1367 19.9283 12 19.9283ZM12 10.9643C12.4173 10.9643 12.7637 10.8265 13.0392 10.551C13.3146 10.2757 13.4523 9.92934 13.4523 9.512C13.4523 9.0945 13.3146 8.74709 13.0392 8.46975C12.7637 8.19242 12.4173 8.05375 12 8.05375C11.5827 8.05375 11.2362 8.19242 10.9607 8.46975C10.6854 8.74709 10.5477 9.0945 10.5477 9.512C10.5477 9.92934 10.6854 10.2757 10.9607 10.551C11.2362 10.8265 11.5827 10.9643 12 10.9643Z",
|
|
30
|
+
fill: "white"
|
|
31
|
+
}, null, -1)
|
|
32
|
+
]));
|
|
33
|
+
}
|
|
34
|
+
const k = /* @__PURE__ */ b(v, [["render", _]]), L = {}, M = {
|
|
35
|
+
width: "11",
|
|
36
|
+
height: "18",
|
|
37
|
+
viewBox: "0 0 11 18",
|
|
38
|
+
fill: "none",
|
|
39
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
40
|
+
};
|
|
41
|
+
function $(o, e) {
|
|
42
|
+
return t(), n("svg", M, e[0] || (e[0] = [
|
|
43
|
+
s("path", {
|
|
44
|
+
d: "M1.98601 18C0.447922 18 0.403919 17.7815 1.32681 16.602L6.60042 10.1796C6.99592 9.69905 7.21568 9.3058 7.21568 8.99997C7.21568 8.65046 6.99592 8.25727 6.60042 7.82039L1.32681 1.39804C0.403919 0.218468 0.447922 0 1.98601 0H2.5134C4.05149 0 4.62282 0.305829 5.54571 1.39804L9.58879 6.29125C11.3028 8.25727 11.3028 9.74273 9.58879 11.7088L5.54571 16.602C4.62282 17.6942 4.05149 18 2.5134 18H1.98601Z",
|
|
45
|
+
fill: "white"
|
|
46
|
+
}, null, -1)
|
|
47
|
+
]));
|
|
48
|
+
}
|
|
49
|
+
const z = /* @__PURE__ */ b(L, [["render", $]]), q = { class: "avatar" }, B = { class: "bubble" }, Z = ["innerHTML"], N = {
|
|
50
|
+
key: 1,
|
|
51
|
+
class: "attachment-label"
|
|
52
|
+
}, H = /* @__PURE__ */ m({
|
|
53
|
+
__name: "LLMMessage.ce",
|
|
54
|
+
props: {
|
|
55
|
+
name: { type: String },
|
|
56
|
+
message: { type: Object }
|
|
57
|
+
},
|
|
58
|
+
setup(o) {
|
|
59
|
+
const e = o, c = d(() => e.message.direction === "outbound"), i = d(() => {
|
|
60
|
+
if (e.message.content)
|
|
61
|
+
return e.name ? `<strong>${e.name}</strong> : ${e.message.content}` : e.message.content;
|
|
62
|
+
});
|
|
63
|
+
return (a, A) => (t(), n("div", {
|
|
64
|
+
class: g(["message", a.message.direction])
|
|
65
|
+
}, [
|
|
66
|
+
s("span", q, [
|
|
67
|
+
c.value ? (t(), r(k, { key: 0 })) : (t(), r(z, { key: 1 }))
|
|
68
|
+
]),
|
|
69
|
+
a.message.isLoading ? (t(), r(f, {
|
|
70
|
+
key: 0,
|
|
71
|
+
class: "loader"
|
|
72
|
+
})) : l("", !0),
|
|
73
|
+
s("div", B, [
|
|
74
|
+
i.value ? (t(), n("div", {
|
|
75
|
+
key: 0,
|
|
76
|
+
innerHTML: i.value,
|
|
77
|
+
class: "content"
|
|
78
|
+
}, null, 8, Z)) : l("", !0),
|
|
79
|
+
a.message.attachmentName && c.value ? (t(), n("p", N, [
|
|
80
|
+
s("span", null, p(a.message.attachmentName), 1),
|
|
81
|
+
u(y)
|
|
82
|
+
])) : l("", !0)
|
|
83
|
+
])
|
|
84
|
+
], 2));
|
|
85
|
+
}
|
|
86
|
+
}), j = ".message{display:flex;width:90%;gap:12px;align-items:start}.message .avatar{align-items:center;aspect-ratio:1/1;background-color:#1c825d;border-radius:8px;display:flex;justify-content:center;margin-top:2px;padding:4px;width:32px;height:32px}.message .loader{margin-top:14px}.message .bubble .content{--background: #efefef;--focus: #0096bfab;--border: #dbdbdb;box-sizing:border-box;font-size:14px;color:#253858;line-height:20px}.message .bubble .content p{margin:0;word-wrap:break-word}.message .bubble .content h1{font-size:1.8em}.message .bubble .content h2{font-size:1.4em}.message .bubble .content h3{font-size:1.2em}.message .bubble .content h1,.message .bubble .content h2,.message .bubble .content h3,.message .bubble .content h4,.message .bubble .content h5,.message .bubble .content h6{margin-bottom:12px;color:#000}.message .bubble .content strong{color:#000}.message .bubble .content h1,.message .bubble .content h2,.message .bubble .content h3,.message .bubble .content h4,.message .bubble .content h5,.message .bubble .content h6,.message .bubble .content b,.message .bubble .content strong,.message .bubble .content th{font-weight:600}.message .bubble .content q:before{content:none}.message .bubble .content q:after{content:none}.message .bubble .content blockquote,.message .bubble .content q{border-left:4px solid var(--focus);margin:1.5em 0;padding:.5em 1em;font-style:italic}.message .bubble .content blockquote>footer{font-style:normal;border:0}.message .bubble .content blockquote cite{font-style:normal}.message .bubble .content mark{background-color:#ff0;border-radius:2px;padding:0 2px;color:#000}.message .bubble .content code{background:var(--background);color:#000;padding:2.5px 5px;border-radius:6px;font-size:1em}.message .bubble .content hr{border:none;border-top:1px solid var(--border)}.message .bubble .content table{border-collapse:collapse;margin-bottom:10px;width:100%;table-layout:fixed;border:1px solid #dbdbdb;border-radius:8px}.message .bubble .content table caption{text-align:left}.message .bubble .content td,.message .bubble .content th{padding:6px;text-align:left;vertical-align:top;word-wrap:break-word;border-right:1px solid var(--border)}.message .bubble .content thead{border-bottom:1px solid var(--border)}.message .bubble .content tfoot{border-top:1px solid var(--border)}.message .bubble .content tbody tr:nth-child(2n){background-color:#efefef}.message .bubble .content tbody tr:nth-child(2n) button{background-color:#f7f7f7}.message .bubble .content tbody tr:nth-child(2n) button:hover{background-color:#fff}.message .bubble .content details{display:flex;flex-direction:column;align-items:flex-start;background-color:#f7f7f7;padding:10px 10px 0;margin:1em 0;border-radius:6px;overflow:hidden}.message .bubble .content details[open]{padding:10px}.message .bubble .content details>:last-child{margin-bottom:0}.message .bubble .content details[open] summary{margin-bottom:10px}.message .bubble .content summary{display:list-item;background-color:#efefef;padding:10px;margin:-10px -10px 0;cursor:pointer;outline:none}.message .bubble .content summary:hover,.message .bubble .content summary:focus{text-decoration:underline}.message .bubble .content details>:not(summary){margin-top:0}.message .bubble .content summary::-webkit-details-marker{color:#363636}.message .bubble .content ul{list-style-type:disc;list-style-position:inside}.message .bubble .content ol{list-style-type:decimal}.message .bubble .attachment-label{display:flex;align-items:center;gap:.5rem;font-size:.8rem;font-style:italic;justify-content:end;margin:1rem}.message.outbound{align-self:end;flex-direction:row-reverse}.message.outbound .avatar{background-color:#957ee8}.message.outbound .bubble{background:#cec3f4;border-radius:16px;padding:8px 16px}", T = /* @__PURE__ */ b(H, [["styles", [j]]]);
|
|
87
|
+
export {
|
|
88
|
+
T as L
|
|
89
|
+
};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { _ as o, c as a, o as r, f as s } from "./_plugin-vue_export-helper-CGpZIhKK.js";
|
|
2
|
+
const n = ".loader{width:8px;aspect-ratio:1;border-radius:50%;animation:l5 1s infinite linear alternate;transform:translate(100%)}@keyframes l5{0%{box-shadow:13px 0 #000,-13px 0 #0002;background:#000}33%{box-shadow:13px 0 #000,-13px 0 #0002;background:#0002}66%{box-shadow:13px 0 #0002,-13px 0 #000;background:#0002}to{box-shadow:13px 0 #0002,-13px 0 #000;background:#000}}@media (prefers-reduced-motion: reduce){.loader{display:none}}", t = {}, d = {
|
|
3
|
+
class: "loader",
|
|
4
|
+
role: "alert"
|
|
5
|
+
};
|
|
6
|
+
function c(l, e) {
|
|
7
|
+
return r(), a("div", d, e[0] || (e[0] = [
|
|
8
|
+
s("p", { class: "sr-only" }, "Chargement...", -1)
|
|
9
|
+
]));
|
|
10
|
+
}
|
|
11
|
+
const p = /* @__PURE__ */ o(t, [["render", c], ["styles", [n]]]);
|
|
12
|
+
export {
|
|
13
|
+
p as L
|
|
14
|
+
};
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
import { a as f, r as g, y as w, c as h, o as i, f as l, v as C, B as b, t as m, m as x, A as y, H as _, _ as s, e as c, I as k } from "./_plugin-vue_export-helper-CGpZIhKK.js";
|
|
2
|
+
const $ = { class: "tooltip-container" }, B = ["id"], L = ["aria-labelledby", "aria-disabled"], z = /* @__PURE__ */ f({
|
|
3
|
+
inheritAttrs: !1,
|
|
4
|
+
__name: "ButtonTooltip.ce",
|
|
5
|
+
props: {
|
|
6
|
+
disabled: { type: Boolean, default: !1 },
|
|
7
|
+
label: { type: String },
|
|
8
|
+
tooltipPosition: { default: "top", type: String }
|
|
9
|
+
},
|
|
10
|
+
emits: ["click"],
|
|
11
|
+
setup(a, { emit: t }) {
|
|
12
|
+
const e = g(!0), p = w(), u = t;
|
|
13
|
+
function n(o) {
|
|
14
|
+
e.value = o;
|
|
15
|
+
}
|
|
16
|
+
function v() {
|
|
17
|
+
a.disabled || u("click");
|
|
18
|
+
}
|
|
19
|
+
return (o, r) => (i(), h("div", $, [
|
|
20
|
+
l("p", {
|
|
21
|
+
id: b(p),
|
|
22
|
+
class: C(["tooltip", {
|
|
23
|
+
"sr-only": e.value || o.disabled,
|
|
24
|
+
[`${o.tooltipPosition}`]: !0
|
|
25
|
+
}])
|
|
26
|
+
}, m(o.label), 11, B),
|
|
27
|
+
l("button", x(o.$attrs, {
|
|
28
|
+
onMouseenter: r[0] || (r[0] = (d) => n(!1)),
|
|
29
|
+
onMouseleave: r[1] || (r[1] = (d) => n(!0)),
|
|
30
|
+
onFocusin: r[2] || (r[2] = (d) => n(!1)),
|
|
31
|
+
onFocusout: r[3] || (r[3] = (d) => n(!0)),
|
|
32
|
+
onClick: y(v, ["stop"]),
|
|
33
|
+
"aria-labelledby": b(p),
|
|
34
|
+
"aria-disabled": o.disabled,
|
|
35
|
+
class: { disabled: o.disabled }
|
|
36
|
+
}), [
|
|
37
|
+
_(o.$slots, "default")
|
|
38
|
+
], 16, L)
|
|
39
|
+
]));
|
|
40
|
+
}
|
|
41
|
+
}), S = '*{--pix-neutral-800: #253858}.sr-only{position:absolute;width:1px;height:1px;padding:0;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}.tooltip-container{position:relative;display:grid}.tooltip-container .tooltip{position:absolute;padding:5px 7px;background:var(--pix-neutral-800);color:#fff;border-radius:4px;z-index:400;margin:0;--horizontal-shift: 12px;--tooltip-gap: 1px;--arrow-height: 6px;--arrow-width: 5px}.tooltip-container .tooltip:before{content:"";position:absolute}.tooltip-container .tooltip.top{bottom:calc(100% + var(--tooltip-gap) + var(--arrow-height));left:50%;transform:translate(calc(var(--horizontal-shift) * -1))}.tooltip-container .tooltip.top:before{top:100%;left:calc(var(--horizontal-shift) - var(--arrow-width));border-right:var(--arrow-width) solid transparent;border-left:var(--arrow-width) solid transparent;border-top:var(--arrow-height) solid var(--pix-neutral-800)}.tooltip-container .tooltip.bottom{top:calc(100% + var(--tooltip-gap) + var(--arrow-height));left:50%;transform:translate(calc(var(--horizontal-shift) * -1))}.tooltip-container .tooltip.bottom:before{bottom:100%;left:calc(var(--horizontal-shift) - var(--arrow-width));border-right:var(--arrow-width) solid transparent;border-left:var(--arrow-width) solid transparent;border-bottom:var(--arrow-height) solid var(--pix-neutral-800)}.tooltip-container .tooltip.left{right:calc(100% + var(--tooltip-gap) + var(--arrow-height));top:50%;transform:translateY(-50%)}.tooltip-container .tooltip.left:before{left:100%;top:50%;transform:translateY(-50%);border-top:var(--arrow-width) solid transparent;border-bottom:var(--arrow-width) solid transparent;border-left:var(--arrow-height) solid var(--pix-neutral-800)}.tooltip-container .tooltip.right{left:calc(100% + var(--tooltip-gap) + var(--arrow-height));top:50%;transform:translateY(-50%)}.tooltip-container .tooltip.right:before{right:100%;top:50%;transform:translateY(-50%);border-top:var(--arrow-width) solid transparent;border-bottom:var(--arrow-width) solid transparent;border-right:var(--arrow-height) solid var(--pix-neutral-800)}.tooltip-container button:hover{cursor:pointer}.tooltip-container button.disabled{color:#797e89;cursor:not-allowed;border-color:transparent;background:transparent}', H = /* @__PURE__ */ s(z, [["styles", [S]]]), M = {}, P = {
|
|
42
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
43
|
+
width: "16",
|
|
44
|
+
height: "16",
|
|
45
|
+
viewBox: "0 0 16 16",
|
|
46
|
+
fill: "inherit"
|
|
47
|
+
};
|
|
48
|
+
function A(a, t) {
|
|
49
|
+
return i(), h("svg", P, t[0] || (t[0] = [
|
|
50
|
+
l("path", {
|
|
51
|
+
d: "M10.5642 8.75826H3.28958C3.07681 8.75826 2.89719 8.68509 2.75075 8.53875C2.60442 8.39231 2.53125 8.2127 2.53125 7.99992C2.53125 7.78714 2.60442 7.60753 2.75075 7.46109C2.89719 7.31475 3.07681 7.24159 3.28958 7.24159H10.5642L7.45292 4.13042C7.30103 3.97842 7.22719 3.80025 7.23142 3.59592C7.23564 3.39159 7.31369 3.21348 7.46558 3.06159C7.61758 2.9207 7.79575 2.84814 8.00008 2.84392C8.20442 2.8397 8.38258 2.91353 8.53458 3.06542L12.9346 7.46542C13.0091 7.54009 13.0636 7.62298 13.0981 7.71409C13.1325 7.80509 13.1498 7.90037 13.1498 7.99992C13.1498 8.09948 13.1325 8.19475 13.0981 8.28575C13.0636 8.37687 13.0091 8.45975 12.9346 8.53442L8.53058 12.9383C8.38703 13.0818 8.21164 13.1536 8.00442 13.1536C7.79719 13.1536 7.61758 13.0818 7.46558 12.9383C7.31369 12.7864 7.23775 12.6061 7.23775 12.3976C7.23775 12.189 7.31369 12.0088 7.46558 11.8568L10.5642 8.75826Z",
|
|
52
|
+
fill: "inherit"
|
|
53
|
+
}, null, -1)
|
|
54
|
+
]));
|
|
55
|
+
}
|
|
56
|
+
const N = /* @__PURE__ */ s(M, [["render", A]]), Y = {}, T = {
|
|
57
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
58
|
+
width: "16",
|
|
59
|
+
height: "16",
|
|
60
|
+
viewBox: "0 0 16 16",
|
|
61
|
+
fill: "inherit"
|
|
62
|
+
};
|
|
63
|
+
function F(a, t) {
|
|
64
|
+
return i(), h("svg", T, t[0] || (t[0] = [
|
|
65
|
+
l("path", {
|
|
66
|
+
d: "M5.4356 8.75868L8.54693 11.8698C8.69882 12.0218 8.77265 12.2 8.76843 12.4043C8.76421 12.6087 8.68615 12.7868 8.53426 12.9387C8.38226 13.0796 8.2041 13.1521 7.99976 13.1563C7.79543 13.1606 7.61726 13.0867 7.46526 12.9348L3.06526 8.53485C2.99071 8.46018 2.93621 8.37729 2.90176 8.28618C2.86732 8.19518 2.8501 8.0999 2.8501 8.00035C2.8501 7.90079 2.86732 7.80551 2.90176 7.71451C2.93621 7.6234 2.99071 7.54051 3.06526 7.46585L7.46926 3.06201C7.61282 2.91846 7.78821 2.84668 7.99543 2.84668C8.20265 2.84668 8.38226 2.91846 8.53426 3.06201C8.68615 3.2139 8.7621 3.39412 8.7621 3.60268C8.7621 3.81124 8.68615 3.99151 8.53426 4.14351L5.4356 7.24201H12.7103C12.923 7.24201 13.1027 7.31518 13.2491 7.46151C13.3954 7.60796 13.4686 7.78757 13.4686 8.00035C13.4686 8.21312 13.3954 8.39274 13.2491 8.53918C13.1027 8.68551 12.923 8.75868 12.7103 8.75868H5.4356Z",
|
|
67
|
+
fill: "inherit"
|
|
68
|
+
}, null, -1)
|
|
69
|
+
]));
|
|
70
|
+
}
|
|
71
|
+
const I = /* @__PURE__ */ s(Y, [["render", F]]), Z = /* @__PURE__ */ f({
|
|
72
|
+
__name: "NavigationButton.ce",
|
|
73
|
+
props: {
|
|
74
|
+
disabled: { type: Boolean },
|
|
75
|
+
label: { type: String },
|
|
76
|
+
tooltipPosition: { type: String },
|
|
77
|
+
direction: { type: String }
|
|
78
|
+
},
|
|
79
|
+
emits: ["click"],
|
|
80
|
+
setup(a) {
|
|
81
|
+
return (t, e) => (i(), c(H, {
|
|
82
|
+
class: "button",
|
|
83
|
+
onClick: e[0] || (e[0] = (p) => t.$emit("click")),
|
|
84
|
+
"tooltip-position": t.tooltipPosition,
|
|
85
|
+
label: t.label,
|
|
86
|
+
disabled: t.disabled
|
|
87
|
+
}, {
|
|
88
|
+
default: k(() => [
|
|
89
|
+
t.direction === "next" ? (i(), c(N, { key: 0 })) : (i(), c(I, { key: 1 }))
|
|
90
|
+
]),
|
|
91
|
+
_: 1
|
|
92
|
+
}, 8, ["tooltip-position", "label", "disabled"]));
|
|
93
|
+
}
|
|
94
|
+
}), j = "*{--pix-neutral-800: #253858;color:var(--pix-neutral-800)}.button{border-radius:100%;padding:4px;width:32px;height:32px;background:transparent;border:1px var(--pix-neutral-800) solid;aspect-ratio:1/1;fill:var(--pix-neutral-800);display:flex;align-items:center;justify-content:center}.button:hover{background:#c3d0ff}.button:active{background:#cdd1d9}", E = /* @__PURE__ */ s(Z, [["styles", [j]]]);
|
|
95
|
+
export {
|
|
96
|
+
H as B,
|
|
97
|
+
E as N
|
|
98
|
+
};
|
package/dist/{_plugin-vue_export-helper-DLH45Sxm.js → _plugin-vue_export-helper-CGpZIhKK.js}
RENAMED
|
@@ -4137,17 +4137,17 @@ const jl = (e, t) => {
|
|
|
4137
4137
|
return s;
|
|
4138
4138
|
};
|
|
4139
4139
|
export {
|
|
4140
|
-
|
|
4141
|
-
|
|
4142
|
-
|
|
4143
|
-
|
|
4144
|
-
|
|
4140
|
+
Nl as A,
|
|
4141
|
+
ri as B,
|
|
4142
|
+
as as C,
|
|
4143
|
+
Sl as D,
|
|
4144
|
+
Kr as E,
|
|
4145
4145
|
he as F,
|
|
4146
|
-
|
|
4147
|
-
|
|
4148
|
-
|
|
4149
|
-
|
|
4150
|
-
|
|
4146
|
+
Ns as G,
|
|
4147
|
+
El as H,
|
|
4148
|
+
Fr as I,
|
|
4149
|
+
vl as J,
|
|
4150
|
+
Fl as K,
|
|
4151
4151
|
jl as _,
|
|
4152
4152
|
jr as a,
|
|
4153
4153
|
Tl as b,
|
|
@@ -4157,22 +4157,22 @@ export {
|
|
|
4157
4157
|
ji as f,
|
|
4158
4158
|
ge as g,
|
|
4159
4159
|
Cl as h,
|
|
4160
|
-
|
|
4161
|
-
|
|
4162
|
-
|
|
4163
|
-
|
|
4160
|
+
Ft as i,
|
|
4161
|
+
Mo as j,
|
|
4162
|
+
ul as k,
|
|
4163
|
+
Pl as l,
|
|
4164
4164
|
Io as m,
|
|
4165
|
-
|
|
4165
|
+
ci as n,
|
|
4166
4166
|
Es as o,
|
|
4167
|
-
|
|
4168
|
-
|
|
4167
|
+
oo as p,
|
|
4168
|
+
Uo as q,
|
|
4169
4169
|
xl as r,
|
|
4170
|
-
|
|
4170
|
+
Sr as s,
|
|
4171
4171
|
er as t,
|
|
4172
|
-
|
|
4173
|
-
|
|
4172
|
+
Il as u,
|
|
4173
|
+
Ds as v,
|
|
4174
4174
|
Al as w,
|
|
4175
|
-
|
|
4176
|
-
|
|
4177
|
-
|
|
4175
|
+
Rl as x,
|
|
4176
|
+
wl as y,
|
|
4177
|
+
Dl as z
|
|
4178
4178
|
};
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
import { a as w, c as i, o as a, f as e, t as s, G as C, _ as x, r as p, g, F as f, b as v, v as P, e as B, d as A } from "../_plugin-vue_export-helper-CGpZIhKK.js";
|
|
2
|
+
import { a as M, i as h, b as z } from "../i18n-DZYcdfDF.js";
|
|
3
|
+
import { L as y } from "../LLMMessage.ce-DBgXmxn9.js";
|
|
4
|
+
const N = {
|
|
5
|
+
"complete-phrase": { iaSuggestions: "🧠 Suggestions de l'IA", explanation: "La barre indique la probabilité de chaque mot. Plus elle est longue, plus le mot est probable dans ce contexte.", ariaLabelDescription: "Le mot {{name}} a une probabilité de {{percent}}%", clickHereButton: "Cliquez ici pour voir ce que l'IA va compléter", successfullyCompletedSentence: "🎉 Phrase complétée avec succès !" }
|
|
6
|
+
}, I = { class: "probability-bar" }, T = { "aria-hidden": "true" }, q = { class: "sr-only" }, E = /* @__PURE__ */ w({
|
|
7
|
+
__name: "ProbabilityBar.ce",
|
|
8
|
+
props: {
|
|
9
|
+
name: { type: String },
|
|
10
|
+
percent: { type: Number }
|
|
11
|
+
},
|
|
12
|
+
setup(n) {
|
|
13
|
+
return (o, r) => (a(), i("div", I, [
|
|
14
|
+
e("p", T, s(o.name), 1),
|
|
15
|
+
e("p", q, s(o.$t("complete-phrase.ariaLabelDescription", { name: o.name, percent: o.percent })), 1),
|
|
16
|
+
e("div", {
|
|
17
|
+
style: C(`width: ${o.percent}%`),
|
|
18
|
+
class: "probability-bar__percent",
|
|
19
|
+
"aria-hidden": "true"
|
|
20
|
+
}, null, 4),
|
|
21
|
+
r[0] || (r[0] = e("div", {
|
|
22
|
+
class: "probability-bar__background",
|
|
23
|
+
"aria-hidden": "true"
|
|
24
|
+
}, null, -1))
|
|
25
|
+
]));
|
|
26
|
+
}
|
|
27
|
+
}), D = ".probability-bar[data-v-f5414745]{position:relative;padding-bottom:10px;border-bottom:1px solid #cbcbcb}.probability-bar__percent[data-v-f5414745]{position:absolute;left:0;z-index:2;height:5px;border-radius:5px;background-color:#235386}.probability-bar__background[data-v-f5414745]{position:absolute;left:0;z-index:1;width:100%;height:5px;border-radius:5px;background-color:#92a1b2}.probability-bar p[data-v-f5414745]{margin-bottom:0}.sr-only[data-v-f5414745]{position:absolute;width:1px;height:1px;padding:0;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}", F = /* @__PURE__ */ x(E, [["styles", [D]], ["__scopeId", "data-v-f5414745"]]), O = { class: "container" }, R = { class: "container__left-side" }, j = { class: "container__conversation" }, G = ["aria-describedby"], H = {
|
|
28
|
+
key: 1,
|
|
29
|
+
class: "container__successSentence"
|
|
30
|
+
}, V = { class: "container__right-side" }, W = ["aria-level"], J = { "aria-hidden": "true" }, K = { class: "probabilities" }, Q = ["id", "aria-hidden"], U = /* @__PURE__ */ w({
|
|
31
|
+
__name: "CompletePhrase.ce",
|
|
32
|
+
props: {
|
|
33
|
+
listOfProbabilityBarsLists: { type: Array },
|
|
34
|
+
userMessage: { type: String },
|
|
35
|
+
llmMessage: { type: String },
|
|
36
|
+
wordsToAdd: { type: Array },
|
|
37
|
+
titleLevel: { type: Number }
|
|
38
|
+
},
|
|
39
|
+
setup(n, { expose: o }) {
|
|
40
|
+
const r = n, l = p(0), u = p(r.llmMessage), b = p(!1), d = p(r.wordsToAdd);
|
|
41
|
+
function k() {
|
|
42
|
+
b.value = !1, u.value = r.llmMessage, d.value = r.wordsToAdd, l.value = 0;
|
|
43
|
+
}
|
|
44
|
+
function S() {
|
|
45
|
+
d.value.length === 1 && (b.value = !0), l.value += 1;
|
|
46
|
+
const [t, ...m] = d.value;
|
|
47
|
+
d.value = m, u.value += `<span style="font-weight: bold;">${t} </span>`;
|
|
48
|
+
}
|
|
49
|
+
return o({
|
|
50
|
+
reset: k
|
|
51
|
+
}), (t, m) => (a(), i("div", O, [
|
|
52
|
+
e("div", R, [
|
|
53
|
+
e("div", j, [
|
|
54
|
+
g(y, {
|
|
55
|
+
class: "container__message",
|
|
56
|
+
message: { content: t.userMessage, direction: "outbound" }
|
|
57
|
+
}, null, 8, ["message"]),
|
|
58
|
+
g(y, {
|
|
59
|
+
class: "container__message",
|
|
60
|
+
message: { content: u.value, direction: "inbound" }
|
|
61
|
+
}, null, 8, ["message"])
|
|
62
|
+
]),
|
|
63
|
+
b.value ? (a(), i("p", H, s(t.$t("complete-phrase.successfullyCompletedSentence")), 1)) : (a(), i("button", {
|
|
64
|
+
key: 0,
|
|
65
|
+
onClick: S,
|
|
66
|
+
class: "container__button",
|
|
67
|
+
"aria-describedby": `currentProbability${l.value}`
|
|
68
|
+
}, s(t.$t("complete-phrase.clickHereButton")), 9, G))
|
|
69
|
+
]),
|
|
70
|
+
e("div", V, [
|
|
71
|
+
e("div", {
|
|
72
|
+
class: "container__title",
|
|
73
|
+
role: "header",
|
|
74
|
+
"aria-level": t.titleLevel
|
|
75
|
+
}, s(t.$t("complete-phrase.iaSuggestions")), 9, W),
|
|
76
|
+
e("p", J, s(t.$t("complete-phrase.explanation")), 1),
|
|
77
|
+
e("div", K, [
|
|
78
|
+
(a(!0), i(f, null, v(t.listOfProbabilityBarsLists, ($, c) => (a(), i("div", {
|
|
79
|
+
class: P(["probability", { hidden: c !== l.value }]),
|
|
80
|
+
key: c,
|
|
81
|
+
id: `currentProbability${c}`,
|
|
82
|
+
"aria-hidden": c !== l.value
|
|
83
|
+
}, [
|
|
84
|
+
(a(!0), i(f, null, v($, (_, L) => (a(), B(F, {
|
|
85
|
+
name: _.name,
|
|
86
|
+
percent: _.percent,
|
|
87
|
+
key: L
|
|
88
|
+
}, null, 8, ["name", "percent"]))), 128))
|
|
89
|
+
], 10, Q))), 128))
|
|
90
|
+
])
|
|
91
|
+
])
|
|
92
|
+
]));
|
|
93
|
+
}
|
|
94
|
+
}), X = "[data-v-f0837864]{--pix-neutral-800: #253858;font-family:Nunito,Roboto,sans-serif;color:var(--pix-neutral-800)}.container[data-v-f0837864]{display:grid;grid-row:auto;gap:10px}.container__conversation[data-v-f0837864]{display:flex;flex-direction:column;background:#fff;padding:1rem;border-radius:10px;margin-bottom:1rem;border:solid 1px lightgrey}.container__title[data-v-f0837864]{font-size:1.2rem;font-weight:700}.container .probabilities[data-v-f0837864]{display:grid}.container .probability[data-v-f0837864]{grid-row:1;grid-column:1}.container__right-side[data-v-f0837864]{grid-column:2;grid-row:1}.container__right-side h2[data-v-f0837864]{margin-top:0}.container__right-side .hidden[data-v-f0837864]{visibility:hidden;grid-row:1;grid-column:1}.container__left-side[data-v-f0837864]{grid-column:1;grid-row:1}.container__message[data-v-f0837864]{margin-bottom:20px}.container__successSentence[data-v-f0837864]{width:90%;background-color:#cec3f4;padding:.8rem .5rem;border-radius:10px}.container__button[data-v-f0837864]{width:90%;border:none;padding:1.2rem 1rem;background:#355ac4;color:#fff;border-radius:10px;font-weight:700}.container__button[data-v-f0837864]:hover{background:#2b3c77;cursor:pointer}@media (max-width: 600px){.container[data-v-f0837864]{display:flex;flex-wrap:wrap}}", Y = /* @__PURE__ */ x(U, [["styles", [X]], ["__scopeId", "data-v-f0837864"]]);
|
|
95
|
+
M(/* @__PURE__ */ Object.assign({ "./locales/fr.json": N })).catch((n) => console.error(n));
|
|
96
|
+
window.customElements.define("complete-phrase", A(Y, {
|
|
97
|
+
configureApp(n) {
|
|
98
|
+
h.changeLanguage(document?.documentElement?.lang || navigator.language), n.use(z, { i18next: h });
|
|
99
|
+
}
|
|
100
|
+
}));
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { d as e } from "../_plugin-vue_export-helper-
|
|
2
|
-
import { I as m } from "../ImageQuiz.ce-
|
|
1
|
+
import { d as e } from "../_plugin-vue_export-helper-CGpZIhKK.js";
|
|
2
|
+
import { I as m } from "../ImageQuiz.ce-BbfMcldf.js";
|
|
3
3
|
window.customElements.define("image-quiz", e(m));
|
|
4
4
|
window.customElements.define("qcu-image", e(m));
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { a as l, r as f, w, c as z, o as t, b as p, e as d, m as g, F as v, d as _ } from "../_plugin-vue_export-helper-
|
|
2
|
-
import { I as A } from "../ImageQuiz.ce-
|
|
1
|
+
import { a as l, r as f, w, c as z, o as t, b as p, e as d, m as g, F as v, d as _ } from "../_plugin-vue_export-helper-CGpZIhKK.js";
|
|
2
|
+
import { I as A } from "../ImageQuiz.ce-BbfMcldf.js";
|
|
3
3
|
const h = /* @__PURE__ */ l({
|
|
4
4
|
__name: "ImageQuizzes.ce",
|
|
5
5
|
props: {
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
import { a as
|
|
2
|
-
import {
|
|
3
|
-
|
|
1
|
+
import { a as m, c as r, o as a, f as e, t as n, F as t, b as p, g as i, _ as c, d as g } from "../_plugin-vue_export-helper-CGpZIhKK.js";
|
|
2
|
+
import { L as l } from "../LLMMessage.ce-DBgXmxn9.js";
|
|
3
|
+
import { p as u } from "../shadow-dom-BdDj1I6f.js";
|
|
4
|
+
const f = {
|
|
4
5
|
class: "header",
|
|
5
6
|
"aria-hidden": "true"
|
|
6
|
-
}, h = { class: "sr-only" },
|
|
7
|
+
}, h = { class: "title-1" }, v = { class: "title-2" }, y = { class: "sr-only" }, _ = { class: "llm-compare-messages" }, w = { "aria-hidden": "true" }, b = /* @__PURE__ */ m({
|
|
7
8
|
__name: "LLMCompareMessages.ce",
|
|
8
9
|
props: {
|
|
9
10
|
conversation1: { type: Object },
|
|
@@ -11,42 +12,46 @@ const g = {
|
|
|
11
12
|
userName: { type: String },
|
|
12
13
|
messages: { type: Array }
|
|
13
14
|
},
|
|
14
|
-
setup(
|
|
15
|
-
return
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
15
|
+
setup(L) {
|
|
16
|
+
return u(), (o, N) => (a(), r(t, null, [
|
|
17
|
+
e("div", f, [
|
|
18
|
+
e("div", null, [
|
|
19
|
+
e("p", h, n(o.conversation1.title), 1)
|
|
20
|
+
]),
|
|
21
|
+
e("div", null, [
|
|
22
|
+
e("p", v, n(o.conversation2.title), 1)
|
|
23
|
+
])
|
|
19
24
|
]),
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
(
|
|
23
|
-
key:
|
|
25
|
+
e("p", y, " Comparaison entre la conversation " + n(o.conversation1.title) + " et la conversation " + n(o.conversation2.title), 1),
|
|
26
|
+
e("div", _, [
|
|
27
|
+
(a(!0), r(t, null, p(o.messages, (s, d) => (a(), r("div", {
|
|
28
|
+
key: d,
|
|
24
29
|
class: "llm-compare-messages__row"
|
|
25
30
|
}, [
|
|
26
|
-
Array.isArray(
|
|
27
|
-
|
|
28
|
-
i(
|
|
29
|
-
message:
|
|
30
|
-
name:
|
|
31
|
+
Array.isArray(s) ? (a(), r(t, { key: 0 }, [
|
|
32
|
+
e("div", null, [
|
|
33
|
+
i(l, {
|
|
34
|
+
message: s[0],
|
|
35
|
+
name: o.conversation1.llmName
|
|
31
36
|
}, null, 8, ["message", "name"])
|
|
32
37
|
]),
|
|
33
|
-
|
|
34
|
-
i(
|
|
35
|
-
message:
|
|
36
|
-
name:
|
|
38
|
+
e("div", null, [
|
|
39
|
+
i(l, {
|
|
40
|
+
message: s[1],
|
|
41
|
+
name: o.conversation2.llmName
|
|
37
42
|
}, null, 8, ["message", "name"])
|
|
38
43
|
])
|
|
39
|
-
], 64)) : (
|
|
40
|
-
|
|
41
|
-
i(
|
|
42
|
-
message:
|
|
43
|
-
name:
|
|
44
|
+
], 64)) : (a(), r(t, { key: 1 }, [
|
|
45
|
+
e("div", null, [
|
|
46
|
+
i(l, {
|
|
47
|
+
message: s,
|
|
48
|
+
name: o.userName
|
|
44
49
|
}, null, 8, ["message", "name"])
|
|
45
50
|
]),
|
|
46
|
-
|
|
47
|
-
i(
|
|
48
|
-
message:
|
|
49
|
-
name:
|
|
51
|
+
e("div", w, [
|
|
52
|
+
i(l, {
|
|
53
|
+
message: s,
|
|
54
|
+
name: o.userName
|
|
50
55
|
}, null, 8, ["message", "name"])
|
|
51
56
|
])
|
|
52
57
|
], 64))
|
|
@@ -54,5 +59,5 @@ const g = {
|
|
|
54
59
|
])
|
|
55
60
|
], 64));
|
|
56
61
|
}
|
|
57
|
-
}),
|
|
58
|
-
window.customElements.define("llm-compare-messages",
|
|
62
|
+
}), x = '*{box-sizing:border-box}:host{display:grid;gap:8px;grid-template-columns:1fr 1fr;grid-template-rows:auto auto}:host:after{content:"";grid-row:2;grid-column:1;border-radius:8px;border:1px solid #452D9D;background:#fff}:host:before{content:"";grid-row:2;grid-column:2;border-radius:8px;border:solid 1px #a16207;background:#fff}.llm-compare-messages{grid-row:2;grid-column:1/span 2;display:flex;flex-direction:column;gap:24px;position:relative;overflow-y:scroll;padding:6px;max-height:460px}.llm-compare-messages__row{display:flex;flex-direction:row;gap:32px}.llm-compare-messages__row>div{display:flex;flex-direction:column;width:50%}.header{display:flex;grid-row:1;grid-column:1/span 2}.header div{display:flex;width:50%;justify-content:center;align-items:center;padding:0 1rem}.header p{font-family:Nunito,sans-serif;font-size:1.25rem;font-style:normal;font-weight:700;line-height:1.75rem;margin:0;padding:8px 32px;background:#cec3f4;width:fit-content;border:1px solid #452D9D;border-radius:8px;text-align:center}.header p.title-2{border-color:#a16207;background:#fffec0}.sr-only{position:absolute;width:1px;height:1px;padding:0;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}', k = /* @__PURE__ */ c(b, [["styles", [x]]]);
|
|
63
|
+
window.customElements.define("llm-compare-messages", g(k));
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { a as m,
|
|
2
|
-
import {
|
|
1
|
+
import { a as m, k as i, l as p, c as o, o as e, F as d, b as g, e as u, _ as f, d as h } from "../_plugin-vue_export-helper-CGpZIhKK.js";
|
|
2
|
+
import { L as _ } from "../LLMMessage.ce-DBgXmxn9.js";
|
|
3
|
+
import { p as x } from "../shadow-dom-BdDj1I6f.js";
|
|
3
4
|
const b = {
|
|
4
5
|
class: "llm-messages",
|
|
5
6
|
"aria-live": "polite"
|
|
@@ -10,7 +11,7 @@ const b = {
|
|
|
10
11
|
},
|
|
11
12
|
setup(t) {
|
|
12
13
|
const a = t;
|
|
13
|
-
|
|
14
|
+
x();
|
|
14
15
|
const s = i();
|
|
15
16
|
function r() {
|
|
16
17
|
s.scrollTop = s.scrollHeight;
|
|
@@ -18,7 +19,7 @@ const b = {
|
|
|
18
19
|
return p(async () => {
|
|
19
20
|
a.messages, r();
|
|
20
21
|
}), (l, w) => (e(), o("div", b, [
|
|
21
|
-
(e(!0), o(d, null,
|
|
22
|
+
(e(!0), o(d, null, g(l.messages, (n, c) => (e(), u(_, {
|
|
22
23
|
key: c,
|
|
23
24
|
message: n
|
|
24
25
|
}, null, 8, ["message"]))), 128))
|