@1024pix/epreuves-components 0.9.7 → 0.10.1
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-CoHr8kTK.js → ImageQuiz.ce-BbfMcldf.js} +12 -12
- package/dist/{LLMMessage.ce-DHyl5CcV.js → LLMMessage.ce-DUUayymi.js} +5 -5
- package/dist/{Loading.ce-B_mSjXBH.js → Loading.ce-BsBClsn3.js} +2 -2
- package/dist/NavigationButton.ce-RaQYJjPs.js +98 -0
- package/dist/{_plugin-vue_export-helper-OrrhezDE.js → _plugin-vue_export-helper-CGpZIhKK.js} +17 -17
- package/dist/components/complete-phrase.ce.js.js +65 -67
- 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 -34
- package/dist/components/llm-messages.ce.js.js +3 -3
- package/dist/components/llm-prompt-select.ce.js.js +5 -5
- package/dist/components/message-conversation.ce.js.js +14 -14
- package/dist/components/pix-carousel.ce.js.js +101 -96
- package/dist/components/pix-cursor.ce.js.js +15 -15
- package/dist/{ButtonTooltip.ce-DJWPmZEW.js → i18n-DZYcdfDF.js} +370 -411
- package/dist/{shadow-dom-Bfma-Uia.js → shadow-dom-BdDj1I6f.js} +1 -1
- package/package.json +1 -1
- package/dist/NavigationButton.ce-CObYL4XH.js +0 -59
|
@@ -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 D = ["aria-labelledby", "aria-selected", "tabindex"],
|
|
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,22 +43,22 @@ const D = ["aria-labelledby", "aria-selected", "tabindex"], E = { key: 0 }, K =
|
|
|
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",
|
|
47
|
-
h("img",
|
|
46
|
+
o.choice.image ? (m(), d("figure", K, [
|
|
47
|
+
h("img", q(o.choice.image, {
|
|
48
48
|
class: o.imageClass,
|
|
49
49
|
alt: ""
|
|
50
50
|
}), null, 16),
|
|
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,
|
|
58
|
+
}, x(o.choice.name), 9, R))
|
|
59
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",
|
|
63
63
|
props: {
|
|
64
64
|
multiple: { type: Boolean, default: !1 },
|
|
@@ -72,8 +72,8 @@ const D = ["aria-labelledby", "aria-selected", "tabindex"], E = { key: 0 }, K =
|
|
|
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 :
|
|
76
|
-
|
|
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
|
+
L(t, () => {
|
|
77
77
|
a("answer", t.value);
|
|
78
78
|
}, { immediate: !1 });
|
|
79
79
|
const S = p(() => {
|
|
@@ -98,7 +98,7 @@ const D = ["aria-labelledby", "aria-selected", "tabindex"], E = { key: 0 }, K =
|
|
|
98
98
|
"aria-labelledby": g(r),
|
|
99
99
|
"aria-orientation": "horizontal"
|
|
100
100
|
}, [
|
|
101
|
-
(m(!0), d(k, null, O(l.value, (j, c) => (m(),
|
|
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,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { _ as b, c as n, o as t, f as s, a as m,
|
|
2
|
-
import { L as f } from "./Loading.ce-
|
|
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-BsBClsn3.js";
|
|
3
3
|
const h = {}, C = {
|
|
4
4
|
height: "1rem",
|
|
5
5
|
width: "auto",
|
|
@@ -46,7 +46,7 @@ function $(o, e) {
|
|
|
46
46
|
}, null, -1)
|
|
47
47
|
]));
|
|
48
48
|
}
|
|
49
|
-
const z = /* @__PURE__ */ b(L, [["render", $]]),
|
|
49
|
+
const z = /* @__PURE__ */ b(L, [["render", $]]), q = { class: "avatar" }, B = { class: "bubble" }, Z = ["innerHTML"], N = {
|
|
50
50
|
key: 1,
|
|
51
51
|
class: "attachment-label"
|
|
52
52
|
}, H = /* @__PURE__ */ m({
|
|
@@ -63,14 +63,14 @@ const z = /* @__PURE__ */ b(L, [["render", $]]), B = { class: "avatar" }, q = {
|
|
|
63
63
|
return (a, A) => (t(), n("div", {
|
|
64
64
|
class: g(["message", a.message.direction])
|
|
65
65
|
}, [
|
|
66
|
-
s("span",
|
|
66
|
+
s("span", q, [
|
|
67
67
|
c.value ? (t(), r(k, { key: 0 })) : (t(), r(z, { key: 1 }))
|
|
68
68
|
]),
|
|
69
69
|
a.message.isLoading ? (t(), r(f, {
|
|
70
70
|
key: 0,
|
|
71
71
|
class: "loader"
|
|
72
72
|
})) : l("", !0),
|
|
73
|
-
s("div",
|
|
73
|
+
s("div", B, [
|
|
74
74
|
i.value ? (t(), n("div", {
|
|
75
75
|
key: 0,
|
|
76
76
|
innerHTML: i.value,
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { _ as o, c as a, o as r, f as s } from "./_plugin-vue_export-helper-
|
|
1
|
+
import { _ as o, c as a, o as r, f as s } from "./_plugin-vue_export-helper-CGpZIhKK.js";
|
|
2
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
3
|
class: "loader",
|
|
4
4
|
role: "alert"
|
|
5
5
|
};
|
|
6
6
|
function c(l, e) {
|
|
7
7
|
return r(), a("div", d, e[0] || (e[0] = [
|
|
8
|
-
s("p", { class: "sr-only" }, "Chargement...", -1)
|
|
8
|
+
s("p", { class: "sr-only" }, " Chargement... ", -1)
|
|
9
9
|
]));
|
|
10
10
|
}
|
|
11
11
|
const p = /* @__PURE__ */ o(t, [["render", c], ["styles", [n]]]);
|
|
@@ -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-OrrhezDE.js → _plugin-vue_export-helper-CGpZIhKK.js}
RENAMED
|
@@ -4137,15 +4137,15 @@ 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
|
-
|
|
4146
|
+
Ns as G,
|
|
4147
|
+
El as H,
|
|
4148
|
+
Fr as I,
|
|
4149
4149
|
vl as J,
|
|
4150
4150
|
Fl as K,
|
|
4151
4151
|
jl as _,
|
|
@@ -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
4167
|
oo as p,
|
|
4168
|
-
|
|
4168
|
+
Uo as q,
|
|
4169
4169
|
xl as r,
|
|
4170
4170
|
Sr as s,
|
|
4171
4171
|
er as t,
|
|
4172
4172
|
Il as u,
|
|
4173
|
-
|
|
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
|
};
|
|
@@ -1,102 +1,100 @@
|
|
|
1
|
-
import { a as
|
|
2
|
-
import {
|
|
3
|
-
import { L as
|
|
4
|
-
const
|
|
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
|
|
6
|
-
},
|
|
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-DUUayymi.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
7
|
__name: "ProbabilityBar.ce",
|
|
8
8
|
props: {
|
|
9
9
|
name: { type: String },
|
|
10
10
|
percent: { type: Number }
|
|
11
11
|
},
|
|
12
|
-
setup(
|
|
13
|
-
return (o,
|
|
14
|
-
e("p",
|
|
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),
|
|
15
16
|
e("div", {
|
|
16
|
-
style:
|
|
17
|
+
style: C(`width: ${o.percent}%`),
|
|
17
18
|
class: "probability-bar__percent",
|
|
18
|
-
"aria-
|
|
19
|
-
}, null,
|
|
20
|
-
|
|
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))
|
|
21
25
|
]));
|
|
22
26
|
}
|
|
23
|
-
}),
|
|
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 = {
|
|
24
28
|
key: 1,
|
|
25
29
|
class: "container__successSentence"
|
|
26
|
-
},
|
|
30
|
+
}, V = { class: "container__right-side" }, W = ["aria-level"], J = { "aria-hidden": "true" }, K = { class: "probabilities" }, Q = ["id", "aria-hidden"], U = /* @__PURE__ */ w({
|
|
27
31
|
__name: "CompletePhrase.ce",
|
|
28
32
|
props: {
|
|
29
33
|
listOfProbabilityBarsLists: { type: Array },
|
|
30
34
|
userMessage: { type: String },
|
|
31
35
|
llmMessage: { type: String },
|
|
32
|
-
wordsToAdd: { type: Array }
|
|
36
|
+
wordsToAdd: { type: Array },
|
|
37
|
+
titleLevel: { type: Number }
|
|
33
38
|
},
|
|
34
|
-
setup(
|
|
35
|
-
const
|
|
36
|
-
function
|
|
37
|
-
b.value = !1,
|
|
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;
|
|
38
43
|
}
|
|
39
|
-
function
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
}
|
|
44
|
-
l.value += 1;
|
|
45
|
-
const [a, ...m] = c.value;
|
|
46
|
-
c.value = m, p.value += `<span style="font-weight: bold;">${a} </span>`;
|
|
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>`;
|
|
47
48
|
}
|
|
48
49
|
return o({
|
|
49
|
-
reset:
|
|
50
|
-
}), (
|
|
51
|
-
e("div",
|
|
52
|
-
e("div",
|
|
53
|
-
|
|
50
|
+
reset: k
|
|
51
|
+
}), (t, m) => (a(), i("div", O, [
|
|
52
|
+
e("div", R, [
|
|
53
|
+
e("div", j, [
|
|
54
|
+
g(y, {
|
|
54
55
|
class: "container__message",
|
|
55
|
-
message: { content:
|
|
56
|
-
}, null, 8, ["message"])
|
|
57
|
-
|
|
58
|
-
e("div", null, [
|
|
59
|
-
f(w, {
|
|
56
|
+
message: { content: t.userMessage, direction: "outbound" }
|
|
57
|
+
}, null, 8, ["message"]),
|
|
58
|
+
g(y, {
|
|
60
59
|
class: "container__message",
|
|
61
|
-
message: { content:
|
|
60
|
+
message: { content: u.value, direction: "inbound" }
|
|
62
61
|
}, null, 8, ["message"])
|
|
63
62
|
]),
|
|
64
|
-
b.value ? (
|
|
63
|
+
b.value ? (a(), i("p", H, s(t.$t("complete-phrase.successfullyCompletedSentence")), 1)) : (a(), i("button", {
|
|
65
64
|
key: 0,
|
|
66
|
-
onClick:
|
|
65
|
+
onClick: S,
|
|
67
66
|
class: "container__button",
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
}, {
|
|
71
|
-
default: P(() => [
|
|
72
|
-
A(i(a.$t("complete-phrase.clickHereButton")), 1)
|
|
73
|
-
]),
|
|
74
|
-
_: 1
|
|
75
|
-
}, 8, ["label"]))
|
|
67
|
+
"aria-describedby": `currentProbability${l.value}`
|
|
68
|
+
}, s(t.$t("complete-phrase.clickHereButton")), 9, G))
|
|
76
69
|
]),
|
|
77
|
-
e("div",
|
|
78
|
-
e("
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
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
|
|
85
83
|
}, [
|
|
86
|
-
(
|
|
87
|
-
name:
|
|
88
|
-
percent:
|
|
89
|
-
key:
|
|
84
|
+
(a(!0), i(f, null, v($, (_, L) => (a(), B(F, {
|
|
85
|
+
name: _.name,
|
|
86
|
+
percent: _.percent,
|
|
87
|
+
key: L
|
|
90
88
|
}, null, 8, ["name", "percent"]))), 128))
|
|
91
|
-
], 10,
|
|
89
|
+
], 10, Q))), 128))
|
|
92
90
|
])
|
|
93
91
|
])
|
|
94
92
|
]));
|
|
95
93
|
}
|
|
96
|
-
}),
|
|
97
|
-
|
|
98
|
-
window.customElements.define("complete-phrase",
|
|
99
|
-
configureApp(
|
|
100
|
-
|
|
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 });
|
|
101
99
|
}
|
|
102
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,10 +1,10 @@
|
|
|
1
|
-
import { a as
|
|
2
|
-
import { L as
|
|
3
|
-
import { p as u } from "../shadow-dom-
|
|
4
|
-
const
|
|
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-DUUayymi.js";
|
|
3
|
+
import { p as u } from "../shadow-dom-BdDj1I6f.js";
|
|
4
|
+
const f = {
|
|
5
5
|
class: "header",
|
|
6
6
|
"aria-hidden": "true"
|
|
7
|
-
}, 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({
|
|
8
8
|
__name: "LLMCompareMessages.ce",
|
|
9
9
|
props: {
|
|
10
10
|
conversation1: { type: Object },
|
|
@@ -12,42 +12,46 @@ const g = {
|
|
|
12
12
|
userName: { type: String },
|
|
13
13
|
messages: { type: Array }
|
|
14
14
|
},
|
|
15
|
-
setup(
|
|
16
|
-
return u(), (
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
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
|
+
])
|
|
20
24
|
]),
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
(
|
|
24
|
-
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,
|
|
25
29
|
class: "llm-compare-messages__row"
|
|
26
30
|
}, [
|
|
27
|
-
Array.isArray(
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
message:
|
|
31
|
-
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
|
|
32
36
|
}, null, 8, ["message", "name"])
|
|
33
37
|
]),
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
message:
|
|
37
|
-
name:
|
|
38
|
+
e("div", null, [
|
|
39
|
+
i(l, {
|
|
40
|
+
message: s[1],
|
|
41
|
+
name: o.conversation2.llmName
|
|
38
42
|
}, null, 8, ["message", "name"])
|
|
39
43
|
])
|
|
40
|
-
], 64)) : (
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
message:
|
|
44
|
-
name:
|
|
44
|
+
], 64)) : (a(), r(t, { key: 1 }, [
|
|
45
|
+
e("div", null, [
|
|
46
|
+
i(l, {
|
|
47
|
+
message: s,
|
|
48
|
+
name: o.userName
|
|
45
49
|
}, null, 8, ["message", "name"])
|
|
46
50
|
]),
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
message:
|
|
50
|
-
name:
|
|
51
|
+
e("div", w, [
|
|
52
|
+
i(l, {
|
|
53
|
+
message: s,
|
|
54
|
+
name: o.userName
|
|
51
55
|
}, null, 8, ["message", "name"])
|
|
52
56
|
])
|
|
53
57
|
], 64))
|
|
@@ -55,5 +59,5 @@ const g = {
|
|
|
55
59
|
])
|
|
56
60
|
], 64));
|
|
57
61
|
}
|
|
58
|
-
}),
|
|
59
|
-
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,6 +1,6 @@
|
|
|
1
|
-
import { a as m,
|
|
2
|
-
import { L as _ } from "../LLMMessage.ce-
|
|
3
|
-
import { p as x } from "../shadow-dom-
|
|
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-DUUayymi.js";
|
|
3
|
+
import { p as x } from "../shadow-dom-BdDj1I6f.js";
|
|
4
4
|
const b = {
|
|
5
5
|
class: "llm-messages",
|
|
6
6
|
"aria-live": "polite"
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a as v, r as
|
|
1
|
+
import { a as v, r as c, h, c as i, o as d, g as y, f as l, j as w, F as f, b as k, t as S, _ as C, d as L } from "../_plugin-vue_export-helper-CGpZIhKK.js";
|
|
2
2
|
import "./llm-messages.ce.js.js";
|
|
3
3
|
const N = { class: "prompt-select" }, P = { class: "prompt-select__options" }, B = ["disabled", "onClick"], E = /* @__PURE__ */ v({
|
|
4
4
|
__name: "LLMPromptSelect.ce",
|
|
@@ -8,10 +8,10 @@ const N = { class: "prompt-select" }, P = { class: "prompt-select__options" }, B
|
|
|
8
8
|
speed: { type: Number }
|
|
9
9
|
},
|
|
10
10
|
setup(_, { expose: b }) {
|
|
11
|
-
const o = _, s =
|
|
11
|
+
const o = _, s = c(o.messages), m = c(o.prompts.map((e) => ({
|
|
12
12
|
...e,
|
|
13
13
|
disabled: !1
|
|
14
|
-
}))), r =
|
|
14
|
+
}))), r = c(!1);
|
|
15
15
|
function g() {
|
|
16
16
|
s.value = o.messages, m.value = o.prompts.map((e) => ({
|
|
17
17
|
...e,
|
|
@@ -45,7 +45,7 @@ const N = { class: "prompt-select" }, P = { class: "prompt-select__options" }, B
|
|
|
45
45
|
}
|
|
46
46
|
return (e, t) => {
|
|
47
47
|
const a = h("llm-messages");
|
|
48
|
-
return d(),
|
|
48
|
+
return d(), i(f, null, [
|
|
49
49
|
y(a, { messages: s.value }, null, 8, ["messages"]),
|
|
50
50
|
l("div", N, [
|
|
51
51
|
t[0] || (t[0] = l("p", { class: "prompt-select__label" }, [
|
|
@@ -53,7 +53,7 @@ const N = { class: "prompt-select" }, P = { class: "prompt-select__options" }, B
|
|
|
53
53
|
l("span", { class: "sr-only" }, " une fois sélectionnés, les prompts ne sont plus disponibles. ")
|
|
54
54
|
], -1)),
|
|
55
55
|
l("div", P, [
|
|
56
|
-
(d(!0),
|
|
56
|
+
(d(!0), i(f, null, k(m.value, (n, p) => (d(), i("button", {
|
|
57
57
|
key: p,
|
|
58
58
|
disabled: n.disabled || r.value,
|
|
59
59
|
onClick: (u) => x(n)
|