@1024pix/epreuves-components 1.2.0 → 1.3.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/schema.js CHANGED
@@ -2,6 +2,24 @@ import e from "joi";
2
2
  const n = e.object({
3
3
  titleLevel: e.number().required()
4
4
  }), a = e.object({
5
+ image: e.object({
6
+ src: e.string().required(),
7
+ alt: e.string().required(),
8
+ width: e.number().optional(),
9
+ height: e.number().optional()
10
+ }).required().unknown(!0),
11
+ areas: e.array().items(e.object({
12
+ shape: e.string().valid("rect").required(),
13
+ coords: e.object({
14
+ x1: e.number().required(),
15
+ y1: e.number().required(),
16
+ x2: e.number().required(),
17
+ y2: e.number().required()
18
+ }).required(),
19
+ info: e.string().required(),
20
+ tooltipPosition: e.string().valid("bottom").optional()
21
+ }).required()).required().min(1)
22
+ }), u = e.object({
5
23
  titleLevel: e.number().required(),
6
24
  listOfProbabilityBarsLists: e.array().items(
7
25
  e.array().items(
@@ -30,7 +48,7 @@ const n = e.object({
30
48
  response: e.string().optional()
31
49
  }).required()
32
50
  ).required()
33
- }).required(), u = e.object({
51
+ }).required(), d = e.object({
34
52
  quizzes: e.array().items(i).required()
35
53
  }).required(), c = e.object({
36
54
  title: e.string().required(),
@@ -45,7 +63,7 @@ const n = e.object({
45
63
  }).unknown(!0).optional()
46
64
  })
47
65
  ).required()
48
- }).required(), d = e.object({
66
+ }).required(), l = e.object({
49
67
  titleLevel: e.number().required(),
50
68
  title: e.string().required(),
51
69
  author: e.string().required(),
@@ -53,11 +71,11 @@ const n = e.object({
53
71
  paragraphs: e.array().items(e.string().required()),
54
72
  highlightedSentence: e.string().required(),
55
73
  colorOfHighlightSentence: e.string().required()
56
- }), l = e.object({
74
+ }), m = e.object({
57
75
  name: e.string().allow("").required(),
58
76
  attribution: e.string().allow("").required(),
59
77
  url: e.string().allow("").required()
60
- }), m = e.object({
78
+ }), g = e.object({
61
79
  title: e.string().required(),
62
80
  description: e.string().allow("").required(),
63
81
  displayWidth: e.number().min(0).optional(),
@@ -65,12 +83,12 @@ const n = e.object({
65
83
  src: e.string().required(),
66
84
  alt: e.string().required()
67
85
  }).required(),
68
- license: l.optional()
69
- }), g = e.object({
86
+ license: m.optional()
87
+ }), q = e.object({
70
88
  title: e.string().required(),
71
89
  description: e.string().allow("").required(),
72
90
  text: e.string().required()
73
- }), q = e.object({
91
+ }), b = e.object({
74
92
  title: e.string().required(),
75
93
  description: e.string().allow("").required(),
76
94
  displayHeight: e.number().min(0).optional(),
@@ -79,13 +97,13 @@ const n = e.object({
79
97
  src: e.string().required(),
80
98
  alt: e.string().required()
81
99
  }).required()
82
- }), b = e.object({
100
+ }), p = e.object({
83
101
  type: e.string().valid("image", "image-text", "text").required(),
84
102
  slides: e.alternatives().conditional("type", {
85
103
  switch: [
86
- { is: "image", then: e.array().items(m) },
87
- { is: "image-text", then: e.array().items(q) },
88
- { is: "text", then: e.array().items(g) }
104
+ { is: "image", then: e.array().items(g) },
105
+ { is: "image-text", then: e.array().items(b) },
106
+ { is: "text", then: e.array().items(q) }
89
107
  ]
90
108
  }).required(),
91
109
  aspectRatio: e.number().min(0).required(),
@@ -93,7 +111,7 @@ const n = e.object({
93
111
  titleLevel: e.number().integer().min(0).max(6).optional(),
94
112
  disableAnimation: e.boolean().required(),
95
113
  disableLoop: e.boolean().optional()
96
- }).meta({ title: "pix-carousel" }).required(), p = e.object({
114
+ }).meta({ title: "pix-carousel" }).required(), _ = e.object({
97
115
  options: e.array().items(e.object({
98
116
  label: e.string().required(),
99
117
  feedback: e.object({
@@ -104,25 +122,25 @@ const n = e.object({
104
122
  }), r = e.object({
105
123
  title: e.string().required(),
106
124
  llmName: e.string().required()
107
- }).required(), _ = e.object({
125
+ }).required(), j = e.object({
108
126
  direction: e.string().valid("inbound").required(),
109
127
  content: e.string().required()
110
- }).required(), j = e.object({
128
+ }).required(), h = e.object({
111
129
  direction: e.string().valid("outbound").required(),
112
130
  content: e.string().required()
113
- }).required(), h = e.object({
131
+ }).required(), v = e.object({
114
132
  conversation1: r,
115
133
  conversation2: r,
116
134
  userName: e.string().required(),
117
135
  messages: e.array().items(
118
- e.alternatives(j, e.array().items(_).min(2).max(2).required())
136
+ e.alternatives(h, e.array().items(j).min(2).max(2).required())
119
137
  ).required()
120
138
  }).required(), t = e.object({
121
139
  direction: e.string().valid("inbound", "outbound").required(),
122
140
  content: e.string().required()
123
- }), v = e.object({
141
+ }), x = e.object({
124
142
  messages: e.array().items(t.required()).required()
125
- }).required(), x = e.object({
143
+ }).required(), y = e.object({
126
144
  speed: e.number().default(20).min(0).optional(),
127
145
  messages: e.array().items(t).required(),
128
146
  prompts: e.array().items(
@@ -131,16 +149,16 @@ const n = e.object({
131
149
  response: e.string().required()
132
150
  }).required()
133
151
  ).required()
134
- }).required(), y = e.object({
152
+ }).required(), w = e.object({
135
153
  titleLevel: e.number().optional(),
136
154
  successImage: e.string().required(),
137
155
  failImage: e.string().required(),
138
156
  infoImage: e.string().required(),
139
157
  searchImage: e.string().required()
140
- }), f = /* @__PURE__ */ Object.assign({ "./calcul-impact/calcul-impact.schema.js": n, "./complete-phrase/complete-phrase.schema.js": a, "./image-quiz/image-quiz.schema.js": i, "./image-quiz/image-quizzes.schema.js": u, "./message-conversation/message-conversation.schema.js": c, "./pix-article/pix-article.schema.js": d, "./pix-carousel/pix-carousel.schema.js": b, "./pix-cursor/pix-cursor.schema.js": p, "./pix-llm/llm-compare-messages.schema.js": h, "./pix-llm/llm-messages.schema.js": v, "./pix-llm/llm-prompt-select.schema.js": x, "./qcm-deepfake/qcm-deepfake.schema.js": y }), S = Object.fromEntries(Object.entries(f).map(([s, o]) => [
158
+ }), f = /* @__PURE__ */ Object.assign({ "./calcul-impact/calcul-impact.schema.js": n, "./clickable-image/clickable-image.schema.js": a, "./complete-phrase/complete-phrase.schema.js": u, "./image-quiz/image-quiz.schema.js": i, "./image-quiz/image-quizzes.schema.js": d, "./message-conversation/message-conversation.schema.js": c, "./pix-article/pix-article.schema.js": l, "./pix-carousel/pix-carousel.schema.js": p, "./pix-cursor/pix-cursor.schema.js": _, "./pix-llm/llm-compare-messages.schema.js": v, "./pix-llm/llm-messages.schema.js": x, "./pix-llm/llm-prompt-select.schema.js": y, "./qcm-deepfake/qcm-deepfake.schema.js": w }), k = Object.fromEntries(Object.entries(f).map(([s, o]) => [
141
159
  s.replace(/^.*\/([^/]+)\.schema\.js$/, "$1"),
142
160
  o
143
161
  ]));
144
162
  export {
145
- S as schema
163
+ k as schema
146
164
  };
@@ -1,4 +1,4 @@
1
- import { u as t, p as s } from "./_plugin-vue_export-helper-CXkSGj2f.js";
1
+ import { u as t, p as s } from "./_plugin-vue_export-helper-DK91u00G.js";
2
2
  const a = Symbol("shadowRoot");
3
3
  function r() {
4
4
  const o = t();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@1024pix/epreuves-components",
3
- "version": "1.2.0",
3
+ "version": "1.3.0",
4
4
  "description": "A collection of interactive components to be used in Pix challenges or modules",
5
5
  "exports": {
6
6
  ".": "./dist/index.js",