@1024pix/epreuves-components 0.9.3 → 0.9.5

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.
@@ -1,4 +1,4 @@
1
- import { d as e } from "../_plugin-vue_export-helper-IFwZcQZF.js";
2
- import { I as m } from "../ImageQuiz.ce-BCKCN6z2.js";
1
+ import { d as e } from "../_plugin-vue_export-helper-CGraGJnO.js";
2
+ import { I as m } from "../ImageQuiz.ce-CyuIHq11.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-IFwZcQZF.js";
2
- import { I as A } from "../ImageQuiz.ce-BCKCN6z2.js";
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-CGraGJnO.js";
2
+ import { I as A } from "../ImageQuiz.ce-CyuIHq11.js";
3
3
  const h = /* @__PURE__ */ l({
4
4
  __name: "ImageQuizzes.ce",
5
5
  props: {
@@ -1,12 +1,9 @@
1
- import { a as d, c as a, o as n, f as s, t, F as i, b as m, g as r, _ as p, d as f } from "../_plugin-vue_export-helper-IFwZcQZF.js";
2
- import { p as u, L as l } from "../LLMMessage.ce-Bwysr0wG.js";
1
+ import { a as d, c as o, o as n, f as s, t, F as l, b as p, g as i, _ as c, d as u } from "../_plugin-vue_export-helper-CGraGJnO.js";
2
+ import { p as f, L as r } from "../LLMMessage.ce-CrEM5b3d.js";
3
3
  const g = {
4
4
  class: "header",
5
5
  "aria-hidden": "true"
6
- }, h = { class: "sr-only" }, v = { class: "llm-compare-messages" }, _ = { class: "conversation1" }, y = { class: "conversation2" }, b = { class: "conversation1" }, w = {
7
- "aria-hidden": "true",
8
- class: "conversation2"
9
- }, x = /* @__PURE__ */ d({
6
+ }, h = { class: "sr-only" }, y = { class: "llm-compare-messages" }, v = { "aria-hidden": "true" }, _ = /* @__PURE__ */ d({
10
7
  __name: "LLMCompareMessages.ce",
11
8
  props: {
12
9
  conversation1: { type: Object },
@@ -14,41 +11,41 @@ const g = {
14
11
  userName: { type: String },
15
12
  messages: { type: Array }
16
13
  },
17
- setup(N) {
18
- return u(), (e, C) => (n(), a(i, null, [
14
+ setup(x) {
15
+ return f(), (e, L) => (n(), o(l, null, [
19
16
  s("div", g, [
20
17
  s("p", null, t(e.conversation1.title), 1),
21
18
  s("p", null, t(e.conversation2.title), 1)
22
19
  ]),
23
20
  s("p", h, " Comparaison entre la conversation " + t(e.conversation1.title) + " et la conversation " + t(e.conversation2.title), 1),
24
- s("div", v, [
25
- (n(!0), a(i, null, m(e.messages, (o, c) => (n(), a("div", {
26
- key: c,
21
+ s("div", y, [
22
+ (n(!0), o(l, null, p(e.messages, (a, m) => (n(), o("div", {
23
+ key: m,
27
24
  class: "llm-compare-messages__row"
28
25
  }, [
29
- Array.isArray(o) ? (n(), a(i, { key: 0 }, [
30
- s("div", _, [
31
- r(l, {
32
- message: o[0],
26
+ Array.isArray(a) ? (n(), o(l, { key: 0 }, [
27
+ s("div", null, [
28
+ i(r, {
29
+ message: a[0],
33
30
  name: e.conversation1.llmName
34
31
  }, null, 8, ["message", "name"])
35
32
  ]),
36
- s("div", y, [
37
- r(l, {
38
- message: o[1],
33
+ s("div", null, [
34
+ i(r, {
35
+ message: a[1],
39
36
  name: e.conversation2.llmName
40
37
  }, null, 8, ["message", "name"])
41
38
  ])
42
- ], 64)) : (n(), a(i, { key: 1 }, [
43
- s("div", b, [
44
- r(l, {
45
- message: o,
39
+ ], 64)) : (n(), o(l, { key: 1 }, [
40
+ s("div", null, [
41
+ i(r, {
42
+ message: a,
46
43
  name: e.userName
47
44
  }, null, 8, ["message", "name"])
48
45
  ]),
49
- s("div", w, [
50
- r(l, {
51
- message: o,
46
+ s("div", v, [
47
+ i(r, {
48
+ message: a,
52
49
  name: e.userName
53
50
  }, null, 8, ["message", "name"])
54
51
  ])
@@ -57,5 +54,5 @@ const g = {
57
54
  ])
58
55
  ], 64));
59
56
  }
60
- }), L = '*{box-sizing:border-box}:host{display:flex;flex-direction:column}.llm-compare-messages{display:flex;flex-direction:column;padding:24px;gap:24px;position:relative;height:100%;overflow:auto}.llm-compare-messages:after{content:"";position:absolute;height:100%;top:0;left:50%;border-left:dashed 1px grey}.llm-compare-messages__row{display:flex;flex-direction:row;justify-content:space-between}.llm-compare-messages__row>div{display:flex;flex-direction:column;width:calc(50% - 12px)}.conversation1 .inbound .bubble{background:#fff7da}.header{display:flex}.header p{background:#e6eaf2;display:flex;width:50%;justify-content:center;align-items:center;padding:1rem;margin:0;font-size:1.2rem;font-weight:700}.header p:first-child{background:#fff7da}.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__ */ p(x, [["styles", [L]]]);
61
- window.customElements.define("llm-compare-messages", f(k));
57
+ }), w = '*{box-sizing:border-box}:host{display:flex;flex-direction:column}.llm-compare-messages{display:flex;flex-direction:column;padding:24px 0;gap:24px;position:relative;height:100%;overflow:auto}.llm-compare-messages:after{content:"";position:absolute;height:100%;top:0;left:50%;border-left:dashed 1px grey}.llm-compare-messages__row{display:flex;flex-direction:row;justify-content:space-between}.llm-compare-messages__row>div{display:flex;flex-direction:column;width:calc(50% - 12px)}.header{display:flex}.header p{background:#e6eaf2;display:flex;width:50%;justify-content:center;align-items:center;padding:1rem;margin:0;font-size:1.2rem;font-weight:700}.header p:first-child{background:#fff7da}.sr-only{position:absolute;width:1px;height:1px;padding:0;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}', b = /* @__PURE__ */ c(_, [["styles", [w]]]);
58
+ window.customElements.define("llm-compare-messages", u(b));
@@ -1,9 +1,9 @@
1
- import { a as m, u as i, j as p, c as o, o as e, F as d, b as u, e as g, _ as f, d as h } from "../_plugin-vue_export-helper-IFwZcQZF.js";
2
- import { p as _, L as v } from "../LLMMessage.ce-Bwysr0wG.js";
3
- const y = {
1
+ import { a as m, u as i, j as p, c as o, o as e, F as d, b as u, e as g, _ as f, d as h } from "../_plugin-vue_export-helper-CGraGJnO.js";
2
+ import { p as _, L as x } from "../LLMMessage.ce-CrEM5b3d.js";
3
+ const b = {
4
4
  class: "llm-messages",
5
5
  "aria-live": "polite"
6
- }, L = /* @__PURE__ */ m({
6
+ }, v = /* @__PURE__ */ m({
7
7
  __name: "LLMMessages.ce",
8
8
  props: {
9
9
  messages: { type: Array }
@@ -12,17 +12,17 @@ const y = {
12
12
  const a = t;
13
13
  _();
14
14
  const s = i();
15
- function l() {
15
+ function r() {
16
16
  s.scrollTop = s.scrollHeight;
17
17
  }
18
18
  return p(async () => {
19
- a.messages, l();
20
- }), (r, B) => (e(), o("div", y, [
21
- (e(!0), o(d, null, u(r.messages, (n, c) => (e(), g(v, {
19
+ a.messages, r();
20
+ }), (l, w) => (e(), o("div", b, [
21
+ (e(!0), o(d, null, u(l.messages, (n, c) => (e(), g(x, {
22
22
  key: c,
23
23
  message: n
24
24
  }, null, 8, ["message"]))), 128))
25
25
  ]));
26
26
  }
27
- }), w = ":host{height:100%;overflow:auto;scroll-behavior:smooth}@media (prefers-reduced-motion: reduce){:host{scroll-behavior:auto}}.llm-messages{display:flex;flex-direction:column;gap:24px;padding:24px}", x = /* @__PURE__ */ f(L, [["styles", [w]]]);
28
- window.customElements.define("llm-messages", h(x));
27
+ }), y = "*{box-sizing:border-box}:host{height:100%;overflow:auto;scroll-behavior:smooth}@media (prefers-reduced-motion: reduce){:host{scroll-behavior:auto}}.llm-messages{display:flex;flex-direction:column;gap:29px;padding:24px}", L = /* @__PURE__ */ f(v, [["styles", [y]]]);
28
+ window.customElements.define("llm-messages", h(L));
@@ -1,19 +1,19 @@
1
- import { a as h, r as i, h as y, c, o as d, g as x, f as l, i as w, F as _, b as k, t as S, _ as C, d as L } from "../_plugin-vue_export-helper-IFwZcQZF.js";
1
+ import { a as v, r as i, h, c, o as d, g as y, f as l, i as w, F as f, b as k, t as S, _ as C, d as L } from "../_plugin-vue_export-helper-CGraGJnO.js";
2
2
  import "./llm-messages.ce.js.js";
3
- const N = { class: "prompt-select" }, P = { class: "prompt-select__options" }, B = ["disabled", "onClick"], E = /* @__PURE__ */ h({
3
+ const N = { class: "prompt-select" }, P = { class: "prompt-select__options" }, B = ["disabled", "onClick"], E = /* @__PURE__ */ v({
4
4
  __name: "LLMPromptSelect.ce",
5
5
  props: {
6
6
  messages: { type: Array },
7
7
  prompts: { type: Array },
8
8
  speed: { type: Number }
9
9
  },
10
- setup(f, { expose: b }) {
11
- const t = f, s = i(t.messages), m = i(t.prompts.map((e) => ({
10
+ setup(_, { expose: b }) {
11
+ const o = _, s = i(o.messages), m = i(o.prompts.map((e) => ({
12
12
  ...e,
13
13
  disabled: !1
14
14
  }))), r = i(!1);
15
15
  function g() {
16
- s.value = t.messages, m.value = t.prompts.map((e) => ({
16
+ s.value = o.messages, m.value = o.prompts.map((e) => ({
17
17
  ...e,
18
18
  disabled: !1
19
19
  })), r.value = !1;
@@ -21,8 +21,8 @@ const N = { class: "prompt-select" }, P = { class: "prompt-select__options" }, B
21
21
  b({
22
22
  reset: g
23
23
  });
24
- async function v(e) {
25
- const o = t.speed === 0 || window.matchMedia("(prefers-reduced-motion: reduce)").matches;
24
+ async function x(e) {
25
+ const t = o.speed === 0 || window.matchMedia("(prefers-reduced-motion: reduce)").matches;
26
26
  if (s.value = [
27
27
  ...s.value,
28
28
  {
@@ -31,37 +31,37 @@ const N = { class: "prompt-select" }, P = { class: "prompt-select__options" }, B
31
31
  },
32
32
  {
33
33
  direction: "inbound",
34
- content: o ? e.response : ""
34
+ content: t ? e.response : ""
35
35
  }
36
- ], e.disabled = !0, o) return;
36
+ ], e.disabled = !0, t) return;
37
37
  const a = s.value.length - 1;
38
38
  r.value = !0;
39
39
  const n = e.response.split(/(\s+|<[^>]+>)/);
40
40
  for (const p of n)
41
41
  await new Promise((u) => {
42
- setTimeout(u, t.speed ?? 20);
42
+ setTimeout(u, o.speed ?? 20);
43
43
  }), s.value = [...s.value], s.value[a].content += p;
44
44
  r.value = !1;
45
45
  }
46
- return (e, o) => {
47
- const a = y("llm-messages");
48
- return d(), c(_, null, [
49
- x(a, { messages: s.value }, null, 8, ["messages"]),
46
+ return (e, t) => {
47
+ const a = h("llm-messages");
48
+ return d(), c(f, null, [
49
+ y(a, { messages: s.value }, null, 8, ["messages"]),
50
50
  l("div", N, [
51
- o[0] || (o[0] = l("p", { class: "prompt-select__label" }, [
51
+ t[0] || (t[0] = l("p", { class: "prompt-select__label" }, [
52
52
  w(" Sélectionner un des prompts "),
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), c(_, null, k(m.value, (n, p) => (d(), c("button", {
56
+ (d(!0), c(f, null, k(m.value, (n, p) => (d(), c("button", {
57
57
  key: p,
58
58
  disabled: n.disabled || r.value,
59
- onClick: (u) => v(n)
59
+ onClick: (u) => x(n)
60
60
  }, S(n.prompt), 9, B))), 128))
61
61
  ])
62
62
  ])
63
63
  ], 64);
64
64
  };
65
65
  }
66
- }), M = ".sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);border:0}llm-messages{display:block;height:400px}.prompt-select{border-top:solid 1px grey;padding:24px}.prompt-select__label{margin-top:0;font-weight:700}.prompt-select__options{display:flex;gap:1rem;justify-content:left;padding-bottom:1rem;flex-wrap:wrap}.prompt-select__options>button{padding:.5rem 1.5rem;border:none;background:#cec3f4;border-radius:5px;font-size:1rem}.prompt-select__options>button:hover:not(:disabled){background:#9a8dc7;color:#fff;cursor:pointer}.prompt-select__options>button:disabled{cursor:not-allowed}", V = /* @__PURE__ */ C(E, [["styles", [M]]]);
66
+ }), M = ".sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);border:0}llm-messages{display:block;height:400px}.prompt-select{font-family:Roboto,sans-serif;border-top:solid 1px #253858;padding:16px 24px 24px}.prompt-select__label{margin-top:0;font-weight:700;color:#253858}.prompt-select__options{display:flex;gap:1rem;justify-content:left;flex-wrap:wrap}.prompt-select__options>button{padding:1rem 1.5rem;border:none;background:#cec3f4;border-radius:16px;border:1px solid #ffffff;color:#130261;font-size:.875rem;box-shadow:0 4px 12px -4px #957ee833}.prompt-select__options>button:hover:not(:disabled){background:#9a8dc7;color:#fff;cursor:pointer}.prompt-select__options>button:disabled{cursor:not-allowed;color:#1010104d}", V = /* @__PURE__ */ C(E, [["styles", [M]]]);
67
67
  window.customElements.define("llm-prompt-select", L(V));
@@ -1,13 +1,13 @@
1
- import { _ as f, c as i, o as t, a as x, r as D, l as v, C as S, q as h, x as u, f as p, i as b, t as _, g as $, F as y, b as w, e as M, d as A } from "../_plugin-vue_export-helper-IFwZcQZF.js";
2
- const C = ".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}}", B = {}, V = { class: "loader" };
3
- function E(n, s) {
4
- return t(), i("div", V);
1
+ import { _ as b, c as o, o as s, a as M, r as v, s as N, y as A, q as w, z as f, f as y, i as k, t as h, g as C, F as x, b as D, x as B, e as E, d as T } from "../_plugin-vue_export-helper-CGraGJnO.js";
2
+ const V = ".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}}", z = {}, F = { class: "loader" };
3
+ function I(t, l) {
4
+ return s(), o("div", F);
5
5
  }
6
- const F = /* @__PURE__ */ f(B, [["render", E], ["styles", [C]]]), z = ["part"], L = {
6
+ const L = /* @__PURE__ */ b(z, [["render", I], ["styles", [V]]]), j = ["part"], q = {
7
7
  key: 1,
8
8
  class: "message__loader message__content",
9
9
  "aria-hidden": "true"
10
- }, T = ["part"], j = { key: 0 }, q = /* @__PURE__ */ x({
10
+ }, O = ["part"], P = { key: 0 }, R = /* @__PURE__ */ M({
11
11
  __name: "Message.ce",
12
12
  props: {
13
13
  displaySender: { type: Boolean, default: !0 },
@@ -16,80 +16,97 @@ const F = /* @__PURE__ */ f(B, [["render", E], ["styles", [C]]]), z = ["part"],
16
16
  animationDuration: { type: Number },
17
17
  loadingDuration: { type: Number }
18
18
  },
19
- setup(n) {
20
- const s = D("hidden"), m = v(() => n.message.content.split(`
19
+ setup(t, { expose: l }) {
20
+ const n = v("hidden"), m = v([]), g = N(() => t.message.content.split(`
21
21
  `));
22
- function r(e) {
23
- return new Promise((a) => setTimeout(a, e));
22
+ function c(e) {
23
+ return new Promise((i) => {
24
+ const r = setTimeout(i, e);
25
+ m.value.push(r);
26
+ });
24
27
  }
25
- return S(async () => {
26
- await r(n.startAnimation), s.value = "loading", await r(n.loadingDuration), s.value = "visible", await r(n.animationDuration);
27
- }), (e, a) => (t(), i("div", {
28
- class: h(["message", [
28
+ async function u() {
29
+ await c(t.startAnimation), n.value = "loading", await c(t.loadingDuration), n.value = "visible", await c(t.animationDuration);
30
+ }
31
+ A(u);
32
+ async function a() {
33
+ n.value = "hidden", m.value.forEach(clearTimeout), await u();
34
+ }
35
+ return l({
36
+ reset: a
37
+ }), (e, i) => (s(), o("div", {
38
+ class: w(["message", [
29
39
  `message--${e.message.direction}`,
30
- { "hidden-state": s.value === "hidden" }
40
+ { "hidden-state": n.value === "hidden" }
31
41
  ]])
32
42
  }, [
33
- e.displaySender ? (t(), i("p", {
43
+ e.displaySender ? (s(), o("p", {
34
44
  key: 0,
35
45
  class: "message__sender",
36
46
  part: `sender ${e.message.direction}`
37
47
  }, [
38
- a[0] || (a[0] = p("span", { class: "sr-only" }, "Message de ", -1)),
39
- b(_(e.message.userName), 1)
40
- ], 8, z)) : u("", !0),
41
- s.value === "loading" ? (t(), i("div", L, [
42
- $(F)
43
- ])) : u("", !0),
44
- p("p", {
45
- class: h(["message__content", { "hidden-state": s.value !== "visible" }]),
48
+ i[0] || (i[0] = y("span", { class: "sr-only" }, "Message de ", -1)),
49
+ k(h(e.message.userName), 1)
50
+ ], 8, j)) : f("", !0),
51
+ n.value === "loading" ? (s(), o("div", q, [
52
+ C(L)
53
+ ])) : f("", !0),
54
+ y("p", {
55
+ class: w(["message__content", { "hidden-state": n.value !== "visible" }]),
46
56
  part: `message ${e.message.direction}`
47
57
  }, [
48
- (t(!0), i(y, null, w(m.value, (d, o) => (t(), i(y, { key: o }, [
49
- o > 0 ? (t(), i("br", j)) : u("", !0),
50
- b(" " + _(d), 1)
58
+ (s(!0), o(x, null, D(g.value, (r, d) => (s(), o(x, { key: d }, [
59
+ d > 0 ? (s(), o("br", P)) : f("", !0),
60
+ k(" " + h(r), 1)
51
61
  ], 64))), 128))
52
- ], 10, T)
62
+ ], 10, O)
53
63
  ], 2));
54
64
  }
55
- }), O = ".message{max-width:80%;position:relative}.message--incoming{align-self:start}.message--incoming .message__sender{padding-left:10px}.message--incoming .message__loader{left:10px}.message--incoming .message__content{background-color:#e8e8e8}.message--outgoing{align-self:end}.message--outgoing .message__sender{padding-right:10px;text-align:right}.message--outgoing .message__loader{right:10px}.message--outgoing .message__content{background-color:#d1eaff}.message__sender{color:#444;font-size:.8rem;font-weight:700;margin:0}.message__loader{position:absolute;width:24px}.message__content{border-radius:16px;margin:0;padding:10px 14px}.message__content:not(.hidden-state){animation:fade .3s ease-in-out both}.hidden-state{visibility:hidden}@keyframes fade{0%{opacity:0}to{opacity:1}}@media (prefers-reduced-motion: reduce){.message__content:not(.hidden-state){animation:none}.message__loader{display:none}.hidden-state{visibility:visible}}", P = /* @__PURE__ */ f(q, [["styles", [O]]]), G = { part: "conversation" }, H = { class: "sr-only" }, I = /* @__PURE__ */ x({
65
+ }), G = ".message{max-width:80%;position:relative}.message--incoming{align-self:start}.message--incoming .message__sender{padding-left:10px}.message--incoming .message__loader{left:10px}.message--incoming .message__content{background-color:#e8e8e8}.message--outgoing{align-self:end}.message--outgoing .message__sender{padding-right:10px;text-align:right}.message--outgoing .message__loader{right:10px}.message--outgoing .message__content{background-color:#d1eaff}.message__sender{color:#444;font-size:.8rem;font-weight:700;margin:0}.message__loader{position:absolute;width:24px}.message__content{border-radius:16px;margin:0;padding:10px 14px}.message__content:not(.hidden-state){animation:fade .3s ease-in-out both}.hidden-state{visibility:hidden}@keyframes fade{0%{opacity:0}to{opacity:1}}@media (prefers-reduced-motion: reduce){.message__content:not(.hidden-state){animation:none}.message__loader{display:none}.hidden-state{visibility:visible}}", H = /* @__PURE__ */ b(R, [["styles", [G]]]), J = { part: "conversation" }, K = { class: "sr-only" }, Q = /* @__PURE__ */ M({
56
66
  __name: "MessageConversation.ce",
57
67
  props: {
58
68
  title: { default: "Conversation par messages", type: String },
59
69
  messages: { type: Array },
60
70
  animationSpeed: { default: 20, type: Number }
61
71
  },
62
- setup(n) {
63
- const s = 50 * n.animationSpeed, m = v(
64
- () => n.messages.reduce(
65
- (e, a, d) => {
66
- const o = r(a);
67
- if (d === 0)
68
- return [{ message: a, displaySender: !0, startAnimation: 0, animationDuration: o }];
72
+ setup(t, { expose: l }) {
73
+ const n = 50 * t.animationSpeed, m = N(
74
+ () => t.messages.reduce(
75
+ (a, e, i) => {
76
+ const r = c(e);
77
+ if (i === 0)
78
+ return [{ message: e, displaySender: !0, startAnimation: 0, animationDuration: r }];
69
79
  const {
70
- message: l,
71
- startAnimation: c,
72
- animationDuration: g
73
- } = e.at(-1), k = a.direction !== l.direction || a.userName !== l.userName, N = c + g + s;
74
- return [...e, { message: a, displaySender: k, startAnimation: N, animationDuration: o }];
80
+ message: d,
81
+ startAnimation: p,
82
+ animationDuration: _
83
+ } = a.at(-1), S = e.direction !== d.direction || e.userName !== d.userName, $ = p + _ + n;
84
+ return [...a, { message: e, displaySender: S, startAnimation: $, animationDuration: r }];
75
85
  },
76
86
  []
77
87
  )
78
- );
79
- function r(e) {
80
- return e.content.length * n.animationSpeed;
88
+ ), g = B("messages");
89
+ function c(a) {
90
+ return a.content.length * t.animationSpeed;
91
+ }
92
+ function u() {
93
+ g.value.forEach((a) => a.reset());
81
94
  }
82
- return (e, a) => (t(), i("figure", G, [
83
- p("figcaption", H, _(e.title), 1),
84
- (t(!0), i(y, null, w(m.value, ({ message: d, displaySender: o, startAnimation: l, animationDuration: c }, g) => (t(), M(P, {
85
- message: d,
86
- "start-animation": l,
87
- "animation-duration": c,
88
- "loading-duration": s,
89
- "display-sender": o,
90
- key: g
95
+ return l({
96
+ reset: u
97
+ }), (a, e) => (s(), o("figure", J, [
98
+ y("figcaption", K, h(a.title), 1),
99
+ (s(!0), o(x, null, D(m.value, ({ message: i, displaySender: r, startAnimation: d, animationDuration: p }, _) => (s(), E(H, {
100
+ ref_for: !0,
101
+ ref: "messages",
102
+ message: i,
103
+ "start-animation": d,
104
+ "animation-duration": p,
105
+ "loading-duration": n,
106
+ "display-sender": r,
107
+ key: _
91
108
  }, null, 8, ["message", "start-animation", "animation-duration", "display-sender"]))), 128))
92
109
  ]));
93
110
  }
94
- }), J = "figure{background-color:#fff;border-radius:16px;display:flex;flex-direction:column;gap:8px;margin:0;padding:16px}.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__ */ f(I, [["styles", [J]]]);
95
- window.customElements.define("message-conversation", A(K));
111
+ }), U = "figure{background-color:#fff;border-radius:16px;display:flex;flex-direction:column;gap:8px;margin:0;padding:16px}.sr-only{position:absolute;width:1px;height:1px;padding:0;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}", W = /* @__PURE__ */ b(Q, [["styles", [U]]]);
112
+ window.customElements.define("message-conversation", T(W));
@@ -1,15 +1,15 @@
1
- import { a as j, l as H, c as I, o as E, q as y, f as Y, x as m, K as S, i as x, t as R, _ as c, r as G, A as L, g as U, L as V, k as d, s as J, p as C, F as z, b as P, e as s, d as a } from "../_plugin-vue_export-helper-IFwZcQZF.js";
2
- import { B as T, N as W, a as n, i as o, b as l } from "../NavigationButton.ce-CG654eMo.js";
1
+ import { a as j, s as H, c as I, o as E, q as y, f as Y, z as m, K as S, i as x, t as R, _ as c, r as G, v as L, g as U, L as V, k as d, C as J, p as C, F as z, b as P, e as s, d as a } from "../_plugin-vue_export-helper-CGraGJnO.js";
2
+ import { B as T, N as W, a as n, i as o, b as l } from "../NavigationButton.ce-qPk4D7sx.js";
3
3
  const t = {
4
- "pix-carousel": { license: "Image license", of: "{{ currentSlide }} of {{ slideLength }}", next: "Next", previous: "Previous", slide: "Slide", title: "Carousel" }
4
+ "pix-carousel": { license: "Image license", next: "Next", of: "{{ currentSlide }} of {{ slideLength }}", previous: "Previous", slide: "Slide", title: "Carousel" }
5
5
  }, K = {
6
- "pix-carousel": { license: "Licencia de imagen", of: "{{ currentSlide }} de {{ slideLength }}", next: "Siguiente", previous: "Anterior", slide: "Diapositiva", title: "Carrusel" }
6
+ "pix-carousel": { license: "Licencia de imagen", next: "Siguiente", of: "{{ currentSlide }} de {{ slideLength }}", previous: "Anterior", slide: "Diapositiva", title: "Carrusel" }
7
7
  }, X = {
8
8
  "pix-carousel": { license: "Licence de l’image", of: "{{ currentSlide }} sur {{ slideLength }}", next: "Suivant", previous: "Précédent", slide: "Diapositive", title: "Carrousel" }
9
9
  }, O = {
10
- "pix-carousel": { license: "Licenza d'immagine", of: "{{ currentSlide }} di {{ slideLength }}", next: "Avanti", previous: "Precedente", slide: "Diapositiva", title: "Galleria" }
10
+ "pix-carousel": { license: "Licenza d'immagine", next: "Avanti", of: "{{ currentSlide }} di {{ slideLength }}", previous: "Precedente", slide: "Diapositiva", title: "Galleria" }
11
11
  }, b = {
12
- "pix-carousel": { license: "Afbeeldingslicentie", of: "{{ currentSlide }} van {{ slideLength }}", next: "Volgende", previous: "Vorige", slide: "Dia", title: "Carrousel" }
12
+ "pix-carousel": { license: "Afbeeldingslicentie", next: "Volgende", of: "{{ currentSlide }} van {{ slideLength }}", previous: "Vorige", slide: "Dia", title: "Carrousel" }
13
13
  }, p = ["aria-level"], u = ["innerHTML"], r = {
14
14
  key: 1,
15
15
  class: "description"