labmaker-plugin 0.0.15 → 0.0.16

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,10 +1,10 @@
1
- import { openBlock as o, createElementBlock as c, Fragment as y, createElementVNode as r, toDisplayString as A, resolveComponent as u, createBlock as w, withCtx as p, createVNode as C, withModifiers as x, createTextVNode as F, normalizeClass as v, createCommentVNode as d, normalizeStyle as H, renderList as T } from "vue";
2
- const S = (e, t) => {
3
- const s = e.__vccOpts || e;
4
- for (const [l, i] of t)
5
- s[l] = i;
6
- return s;
7
- }, j = {
1
+ import { openBlock as a, createElementBlock as u, Fragment as y, createElementVNode as f, toDisplayString as S, resolveComponent as g, createBlock as v, withCtx as _, createVNode as x, withModifiers as A, createTextVNode as T, normalizeClass as w, createCommentVNode as b, normalizeStyle as B, renderList as M, renderSlot as j } from "vue";
2
+ const C = (t, e) => {
3
+ const i = t.__vccOpts || t;
4
+ for (const [r, n] of e)
5
+ i[r] = n;
6
+ return i;
7
+ }, O = {
8
8
  props: ["custom-img"],
9
9
  data() {
10
10
  return {
@@ -13,32 +13,32 @@ const S = (e, t) => {
13
13
  },
14
14
  computed: {},
15
15
  methods: {
16
- fileUpload(e) {
17
- const s = e.target.files[0];
18
- this.fileProcess(s);
16
+ fileUpload(t) {
17
+ const i = t.target.files[0];
18
+ this.fileProcess(i);
19
19
  },
20
- fileProcess(e) {
21
- this.imgSRC = URL.createObjectURL(e);
20
+ fileProcess(t) {
21
+ this.imgSRC = URL.createObjectURL(t);
22
22
  }
23
23
  },
24
24
  mounted() {
25
25
  }
26
- }, B = /* @__PURE__ */ r("h1", null, "File Uploader", -1), O = { class: "image-uploader" }, L = /* @__PURE__ */ r("h1", null, "File Uploader", -1), q = { class: "your-file" }, V = ["src"];
27
- function E(e, t, s, l, i, n) {
28
- return o(), c(y, null, [
29
- B,
30
- r("div", O, [
31
- L,
32
- r("input", {
33
- onChange: t[0] || (t[0] = (...b) => n.fileUpload && n.fileUpload(...b)),
26
+ }, R = /* @__PURE__ */ f("h1", null, "File Uploader", -1), W = { class: "image-uploader" }, q = /* @__PURE__ */ f("h1", null, "File Uploader", -1), P = { class: "your-file" }, V = ["src"];
27
+ function N(t, e, i, r, n, s) {
28
+ return a(), u(y, null, [
29
+ R,
30
+ f("div", W, [
31
+ q,
32
+ f("input", {
33
+ onChange: e[0] || (e[0] = (...l) => s.fileUpload && s.fileUpload(...l)),
34
34
  type: "file",
35
35
  id: "file-upload",
36
36
  name: "fileUpload",
37
37
  accept: "image/*"
38
38
  }, null, 32),
39
- r("div", q, [
40
- r("img", {
41
- src: i.imgSRC,
39
+ f("div", P, [
40
+ f("img", {
41
+ src: n.imgSRC,
42
42
  alt: "",
43
43
  scrset: ""
44
44
  }, null, 8, V)
@@ -46,21 +46,21 @@ function E(e, t, s, l, i, n) {
46
46
  ])
47
47
  ], 64);
48
48
  }
49
- const P = /* @__PURE__ */ S(j, [["render", E]]);
50
- const D = {
49
+ const X = /* @__PURE__ */ C(O, [["render", N]]);
50
+ const Y = {
51
51
  props: ["title"],
52
52
  data() {
53
53
  return {};
54
54
  },
55
55
  computed: {}
56
56
  };
57
- function W(e, t, s, l, i, n) {
58
- return o(), c("header", null, [
59
- r("h1", null, A(s.title), 1)
57
+ function U(t, e, i, r, n, s) {
58
+ return a(), u("header", null, [
59
+ f("h1", null, S(i.title), 1)
60
60
  ]);
61
61
  }
62
- const U = /* @__PURE__ */ S(D, [["render", W]]);
63
- const N = {
62
+ const K = /* @__PURE__ */ C(Y, [["render", U]]);
63
+ const G = {
64
64
  data() {
65
65
  return {};
66
66
  },
@@ -76,31 +76,31 @@ const N = {
76
76
  }
77
77
  },
78
78
  methods: {
79
- handleCurrentChange(e) {
80
- this.$store.commit("setCurrentPage", e - 1);
79
+ handleCurrentChange(t) {
80
+ this.$store.commit("setCurrentPage", t - 1);
81
81
  },
82
- changePage(e) {
83
- console.log("headed to: ", e), this.$store.commit("setCurrentPage", e);
82
+ changePage(t) {
83
+ console.log("headed to: ", t), this.$store.commit("setCurrentPage", t);
84
84
  }
85
85
  }
86
86
  };
87
- function K(e, t, s, l, i, n) {
88
- const b = u("el-col"), m = u("el-button"), a = u("el-row");
89
- return o(), w(a, { gutter: 20 }, {
90
- default: p(() => [
91
- C(b, { span: 18 }),
92
- C(b, {
87
+ function Q(t, e, i, r, n, s) {
88
+ const l = g("el-col"), o = g("el-button"), c = g("el-row");
89
+ return a(), v(c, { gutter: 20 }, {
90
+ default: _(() => [
91
+ x(l, { span: 18 }),
92
+ x(l, {
93
93
  span: 6,
94
94
  class: "homeButtonContainer"
95
95
  }, {
96
- default: p(() => [
97
- C(m, {
96
+ default: _(() => [
97
+ x(o, {
98
98
  type: "primary ",
99
- onClick: t[0] || (t[0] = x((f) => n.changePage(0), ["stop"])),
99
+ onClick: e[0] || (e[0] = A((m) => s.changePage(0), ["stop"])),
100
100
  class: "homeButton"
101
101
  }, {
102
- default: p(() => [
103
- F("Return to Crime Screen")
102
+ default: _(() => [
103
+ T("Return to Crime Screen")
104
104
  ]),
105
105
  _: 1
106
106
  })
@@ -111,8 +111,8 @@ function K(e, t, s, l, i, n) {
111
111
  _: 1
112
112
  });
113
113
  }
114
- const I = /* @__PURE__ */ S(N, [["render", K]]);
115
- const R = {
114
+ const L = /* @__PURE__ */ C(G, [["render", Q]]);
115
+ const J = {
116
116
  props: ["content"],
117
117
  data() {
118
118
  return {};
@@ -123,8 +123,8 @@ const R = {
123
123
  }
124
124
  },
125
125
  methods: {
126
- pixelFormat(e) {
127
- return typeof e == "number" ? e + "px" : e;
126
+ pixelFormat(t) {
127
+ return typeof t == "number" ? t + "px" : t;
128
128
  },
129
129
  checkStepper() {
130
130
  this.$store.dispatch("lastPageFocus", {});
@@ -133,35 +133,35 @@ const R = {
133
133
  mounted() {
134
134
  this.checkStepper();
135
135
  }
136
- }, Q = { class: "image-container" }, Y = { class: "image" }, X = ["src", "alt"], G = ["innerHTML"], J = ["innerHTML"], Z = ["innerHTML"];
137
- function ee(e, t, s, l, i, n) {
138
- return o(), c("div", Q, [
139
- r("div", Y, [
140
- r("img", {
141
- src: s.content.src,
142
- alt: s.content.alt,
143
- class: v(s.content.class)
144
- }, null, 10, X),
145
- s.content.captionHeader ? (o(), c("span", {
136
+ }, Z = { class: "image-container" }, tt = { class: "image" }, et = ["src", "alt"], it = ["innerHTML"], st = ["innerHTML"], nt = ["innerHTML"];
137
+ function ot(t, e, i, r, n, s) {
138
+ return a(), u("div", Z, [
139
+ f("div", tt, [
140
+ f("img", {
141
+ src: i.content.src,
142
+ alt: i.content.alt,
143
+ class: w(i.content.class)
144
+ }, null, 10, et),
145
+ i.content.captionHeader ? (a(), u("span", {
146
146
  key: 0,
147
147
  class: "captionHeader",
148
- innerHTML: s.content.captionHeader
149
- }, null, 8, G)) : d("", !0),
150
- s.content.caption ? (o(), c("span", {
148
+ innerHTML: i.content.captionHeader
149
+ }, null, 8, it)) : b("", !0),
150
+ i.content.caption ? (a(), u("span", {
151
151
  key: 1,
152
152
  class: "caption",
153
- innerHTML: s.content.caption
154
- }, null, 8, J)) : d("", !0),
155
- s.content.copyright ? (o(), c("span", {
153
+ innerHTML: i.content.caption
154
+ }, null, 8, st)) : b("", !0),
155
+ i.content.copyright ? (a(), u("span", {
156
156
  key: 2,
157
- innerHTML: s.content.copyright,
157
+ innerHTML: i.content.copyright,
158
158
  class: "copyright"
159
- }, null, 8, Z)) : d("", !0)
159
+ }, null, 8, nt)) : b("", !0)
160
160
  ])
161
161
  ]);
162
162
  }
163
- const te = /* @__PURE__ */ S(R, [["render", ee], ["__scopeId", "data-v-6d545532"]]);
164
- const se = {
163
+ const rt = /* @__PURE__ */ C(J, [["render", ot], ["__scopeId", "data-v-6d545532"]]);
164
+ const at = {
165
165
  props: ["content"],
166
166
  //moduleLessonPage
167
167
  data() {
@@ -185,14 +185,14 @@ const se = {
185
185
  kHeight() {
186
186
  if (this.content.kalturaType === "video")
187
187
  if (this.content.height && this.content.height != "") {
188
- let e = this.content.height;
189
- return e.slice(-2) === "px" ? e.slice(0, -2) : this.content.height;
188
+ let t = this.content.height;
189
+ return t.slice(-2) === "px" ? t.slice(0, -2) : this.content.height;
190
190
  } else
191
191
  return this.video.height;
192
192
  else if (this.content.kalturaType === "audio")
193
193
  if (this.content.height && this.content.height != "") {
194
- let e = this.content.height;
195
- return e.slice(-2) === "px" ? e.slice(0, -2) : this.content.height;
194
+ let t = this.content.height;
195
+ return t.slice(-2) === "px" ? t.slice(0, -2) : this.content.height;
196
196
  } else
197
197
  return this.audio.height;
198
198
  else if (this.content.kalturaType === "audiobtn")
@@ -201,8 +201,8 @@ const se = {
201
201
  kWidth() {
202
202
  if (this.content.kalturaType === "video")
203
203
  if (this.content.width && this.content.width != "") {
204
- let e = this.content.width;
205
- return e.slice(-2) === "px" ? e.slice(0, -2) : this.content.width;
204
+ let t = this.content.width;
205
+ return t.slice(-2) === "px" ? t.slice(0, -2) : this.content.width;
206
206
  } else
207
207
  return this.video.width;
208
208
  else {
@@ -214,8 +214,8 @@ const se = {
214
214
  }
215
215
  },
216
216
  methods: {
217
- getButtonText(e) {
218
- return e === "video" ? this.showingText ? "Show Video" : "Show Text Version" : this.showingText ? "Show Audio" : "Show Text Version";
217
+ getButtonText(t) {
218
+ return t === "video" ? this.showingText ? "Show Video" : "Show Text Version" : this.showingText ? "Show Audio" : "Show Text Version";
219
219
  },
220
220
  textVersionCheck() {
221
221
  this.content.textVersion && this.content.textVersion.length > 1 && (this.hasText = !0);
@@ -223,8 +223,8 @@ const se = {
223
223
  kalturaLoad() {
224
224
  this.textVersionCheck();
225
225
  },
226
- kalturaMedia(e) {
227
- let t = {
226
+ kalturaMedia(t) {
227
+ let e = {
228
228
  uiconf_id: "35766781",
229
229
  partner_id: "2061901",
230
230
  entry_id: "",
@@ -232,7 +232,7 @@ const se = {
232
232
  width: "640",
233
233
  type: "video"
234
234
  };
235
- return t.entry_id = this.content.kalturaEntryId, this.content.kalturaType && (t.type = this.content.kalturaType), t.type === "audio" ? t.uiconf_id = "36511471" : t.type === "audiobtn" ? t.uiconf_id = "36582731" : t.type === "videocc" && (t.uiconf_id = "35766781"), this.content.standalone && this.$store.commit("setStepHold", !1), "https://cdnapisec.kaltura.com/p/" + t.partner_id + "/sp/" + t.partner_id + "00/embedIframeJs/uiconf_id/" + t.uiconf_id + "/partner_id/" + t.partner_id + "?iframeembed=true&playerId=Kaltura&entry_id=" + t.entry_id;
235
+ return e.entry_id = this.content.kalturaEntryId, this.content.kalturaType && (e.type = this.content.kalturaType), e.type === "audio" ? e.uiconf_id = "36511471" : e.type === "audiobtn" ? e.uiconf_id = "36582731" : e.type === "videocc" && (e.uiconf_id = "35766781"), this.content.standalone && this.$store.commit("setStepHold", !1), "https://cdnapisec.kaltura.com/p/" + e.partner_id + "/sp/" + e.partner_id + "00/embedIframeJs/uiconf_id/" + e.uiconf_id + "/partner_id/" + e.partner_id + "?iframeembed=true&playerId=Kaltura&entry_id=" + e.entry_id;
236
236
  },
237
237
  showKaltura() {
238
238
  this.showingKaltura = !0;
@@ -241,23 +241,23 @@ const se = {
241
241
  this.showingText = !this.showingText, this.buttonText = !this.buttonText;
242
242
  },
243
243
  tvCleaner() {
244
- let e = document.createElement("div");
245
- e.innerHTML = this.content.textVersion;
246
- for (let t = 0; t < e.children.length; t++) {
247
- let s = e.children[t];
248
- if (s.tagName == "DIV" && s.className == "panel-default" && s.children[0].dataset.toggle)
249
- for (let l = 0; l < s.children.length; l++) {
250
- let i = s.children[l];
251
- if (i.dataset.toggle == "collapse") {
252
- let n = {
253
- heading: i.innerHTML,
254
- body: s.children[l + 1].innerHTML
244
+ let t = document.createElement("div");
245
+ t.innerHTML = this.content.textVersion;
246
+ for (let e = 0; e < t.children.length; e++) {
247
+ let i = t.children[e];
248
+ if (i.tagName == "DIV" && i.className == "panel-default" && i.children[0].dataset.toggle)
249
+ for (let r = 0; r < i.children.length; r++) {
250
+ let n = i.children[r];
251
+ if (n.dataset.toggle == "collapse") {
252
+ let s = {
253
+ heading: n.innerHTML,
254
+ body: i.children[r + 1].innerHTML
255
255
  };
256
- this.textversionArray[t] = n;
256
+ this.textversionArray[e] = s;
257
257
  }
258
258
  }
259
259
  else
260
- this.textversionArray[t] = s.outerHTML;
260
+ this.textversionArray[e] = i.outerHTML;
261
261
  }
262
262
  }
263
263
  },
@@ -266,96 +266,96 @@ const se = {
266
266
  },
267
267
  mounted() {
268
268
  }
269
- }, ne = {
269
+ }, ct = {
270
270
  key: 0,
271
271
  class: "textVersion"
272
- }, oe = /* @__PURE__ */ r("h1", null, "Text Version", -1), ie = ["innerHTML"], ce = ["src", "width", "height"], le = ["src", "width", "height"], re = ["src", "width", "height"], ae = {
272
+ }, lt = /* @__PURE__ */ f("h1", null, "Text Version", -1), ht = ["innerHTML"], ut = ["src", "width", "height"], dt = ["src", "width", "height"], mt = ["src", "width", "height"], ft = {
273
273
  key: 2,
274
274
  class: "alert alert-danger"
275
275
  };
276
- function ue(e, t, s, l, i, n) {
277
- const b = u("el-button");
278
- return o(), c("div", {
279
- class: v(["kContainer", s.content.class])
276
+ function pt(t, e, i, r, n, s) {
277
+ const l = g("el-button");
278
+ return a(), u("div", {
279
+ class: w(["kContainer", i.content.class])
280
280
  }, [
281
- s.content.textVersion && i.showingText ? (o(), c("div", ne, [
282
- oe,
283
- r("div", {
284
- innerHTML: s.content.textVersion
285
- }, null, 8, ie)
286
- ])) : d("", !0),
287
- !i.showingText && s.content.kalturaEntryId ? (o(), c("div", {
281
+ i.content.textVersion && n.showingText ? (a(), u("div", ct, [
282
+ lt,
283
+ f("div", {
284
+ innerHTML: i.content.textVersion
285
+ }, null, 8, ht)
286
+ ])) : b("", !0),
287
+ !n.showingText && i.content.kalturaEntryId ? (a(), u("div", {
288
288
  key: 1,
289
289
  class: "mainVersion",
290
- style: H({ width: n.kWidth + "px", height: n.kHeight + "px" })
290
+ style: B({ width: s.kWidth + "px", height: s.kHeight + "px" })
291
291
  }, [
292
- s.content.kalturaType == "video" && !i.showingKaltura ? (o(), c("div", {
292
+ i.content.kalturaType == "video" && !n.showingKaltura ? (a(), u("div", {
293
293
  key: 0,
294
- class: v(["kPoster", { active: i.showingKaltura == !0 }]),
295
- style: H({ width: n.kWidth + "px", height: n.kHeight + "px" })
294
+ class: w(["kPoster", { active: n.showingKaltura == !0 }]),
295
+ style: B({ width: s.kWidth + "px", height: s.kHeight + "px" })
296
296
  }, [
297
- r("iframe", {
298
- onClick: t[0] || (t[0] = (...m) => n.showKaltura && n.showKaltura(...m)),
297
+ f("iframe", {
298
+ onClick: e[0] || (e[0] = (...o) => s.showKaltura && s.showKaltura(...o)),
299
299
  class: "videoIframe",
300
- src: n.kalturaMedia(s.content),
301
- width: n.kWidth + "px",
302
- height: n.kHeight + "px",
300
+ src: s.kalturaMedia(i.content),
301
+ width: s.kWidth + "px",
302
+ height: s.kHeight + "px",
303
303
  allowfullscreen: "",
304
304
  webkitallowfullscreen: "",
305
305
  mozAllowFullScreen: "",
306
306
  frameborder: "0"
307
- }, null, 8, ce)
308
- ], 6)) : d("", !0),
309
- s.content.kalturaType == "audio" ? (o(), c("div", {
307
+ }, null, 8, ut)
308
+ ], 6)) : b("", !0),
309
+ i.content.kalturaType == "audio" ? (a(), u("div", {
310
310
  key: 1,
311
- class: v(["kAudio", { active: i.showingKaltura == !0 }]),
312
- onClick: t[1] || (t[1] = (...m) => n.showKaltura && n.showKaltura(...m))
311
+ class: w(["kAudio", { active: n.showingKaltura == !0 }]),
312
+ onClick: e[1] || (e[1] = (...o) => s.showKaltura && s.showKaltura(...o))
313
313
  }, [
314
- r("iframe", {
314
+ f("iframe", {
315
315
  id: "my_iframe",
316
- src: n.kalturaMedia(s.content),
317
- width: n.kWidth + "px",
318
- height: n.kHeight + "px",
316
+ src: s.kalturaMedia(i.content),
317
+ width: s.kWidth + "px",
318
+ height: s.kHeight + "px",
319
319
  allowfullscreen: "",
320
320
  webkitallowfullscreen: "",
321
321
  mozAllowFullScreen: "",
322
322
  frameborder: "0"
323
- }, null, 8, le)
324
- ], 2)) : d("", !0),
325
- s.content.kalturaType == "audiobtn" ? (o(), c("div", {
323
+ }, null, 8, dt)
324
+ ], 2)) : b("", !0),
325
+ i.content.kalturaType == "audiobtn" ? (a(), u("div", {
326
326
  key: 2,
327
- class: v(["kAudiobtn", { active: i.showingKaltura == !0 }]),
328
- onClick: t[2] || (t[2] = (...m) => n.showKaltura && n.showKaltura(...m))
327
+ class: w(["kAudiobtn", { active: n.showingKaltura == !0 }]),
328
+ onClick: e[2] || (e[2] = (...o) => s.showKaltura && s.showKaltura(...o))
329
329
  }, [
330
- r("iframe", {
331
- src: n.kalturaMedia(s.content),
332
- width: i.audioBtn.width + "px",
333
- height: i.audioBtn.height + "px",
330
+ f("iframe", {
331
+ src: s.kalturaMedia(i.content),
332
+ width: n.audioBtn.width + "px",
333
+ height: n.audioBtn.height + "px",
334
334
  allowfullscreen: "",
335
335
  webkitallowfullscreen: "",
336
336
  mozAllowFullScreen: "",
337
337
  frameborder: "0"
338
- }, null, 8, re)
339
- ], 2)) : d("", !0)
340
- ], 4)) : d("", !0),
341
- s.content.kalturaEntryId == "" ? (o(), c("div", ae, "There is no Kaltura Entry ID")) : d("", !0),
342
- s.content.textVersion ? (o(), w(b, {
338
+ }, null, 8, mt)
339
+ ], 2)) : b("", !0)
340
+ ], 4)) : b("", !0),
341
+ i.content.kalturaEntryId == "" ? (a(), u("div", ft, "There is no Kaltura Entry ID")) : b("", !0),
342
+ i.content.textVersion ? (a(), v(l, {
343
343
  key: 3,
344
344
  size: "medium",
345
345
  type: "primary",
346
346
  "aria-label": "text version",
347
347
  class: "toggleSwitch ftSwitch btn btn-primary vidText",
348
- onClick: t[3] || (t[3] = x((m) => n.showText(s.content.kalturaType), ["stop"]))
348
+ onClick: e[3] || (e[3] = A((o) => s.showText(i.content.kalturaType), ["stop"]))
349
349
  }, {
350
- default: p(() => [
351
- F(A(n.getButtonText(s.content.kalturaType)), 1)
350
+ default: _(() => [
351
+ T(S(s.getButtonText(i.content.kalturaType)), 1)
352
352
  ]),
353
353
  _: 1
354
- })) : d("", !0)
354
+ })) : b("", !0)
355
355
  ], 2);
356
356
  }
357
- const he = /* @__PURE__ */ S(se, [["render", ue]]);
358
- const de = {
357
+ const gt = /* @__PURE__ */ C(at, [["render", pt]]);
358
+ const bt = {
359
359
  props: ["content"],
360
360
  data() {
361
361
  return {
@@ -380,64 +380,64 @@ const de = {
380
380
  },
381
381
  mounted() {
382
382
  }
383
- }, me = { class: "my-header" }, fe = ["id", "innerHTML"], be = ["innerHTML"], pe = { key: 1 }, _e = ["src"], ge = ["innerHTML"], ke = { class: "dialog-footer" };
384
- function ye(e, t, s, l, i, n) {
385
- const b = u("el-button"), m = u("el-dialog");
386
- return o(), w(m, {
387
- width: n.feedbackWidth,
388
- modelValue: i.show,
389
- "onUpdate:modelValue": t[1] || (t[1] = (a) => i.show = a),
390
- "before-close": n.feedbackClose
383
+ }, _t = { class: "my-header" }, kt = ["id", "innerHTML"], yt = ["innerHTML"], wt = { key: 1 }, vt = ["src"], xt = ["innerHTML"], Ct = { class: "dialog-footer" };
384
+ function St(t, e, i, r, n, s) {
385
+ const l = g("el-button"), o = g("el-dialog");
386
+ return a(), v(o, {
387
+ width: s.feedbackWidth,
388
+ modelValue: n.show,
389
+ "onUpdate:modelValue": e[1] || (e[1] = (c) => n.show = c),
390
+ "before-close": s.feedbackClose
391
391
  }, {
392
- header: p(({ close: a, titleId: f, titleClass: _ }) => [
393
- r("div", me, [
394
- r("h4", {
395
- id: f,
396
- class: v(_),
397
- innerHTML: n.feedbackHeader
398
- }, null, 10, fe)
392
+ header: _(({ close: c, titleId: m, titleClass: h }) => [
393
+ f("div", _t, [
394
+ f("h4", {
395
+ id: m,
396
+ class: w(h),
397
+ innerHTML: s.feedbackHeader
398
+ }, null, 10, kt)
399
399
  ])
400
400
  ]),
401
- footer: p(() => [
402
- r("span", ke, [
403
- C(b, {
401
+ footer: _(() => [
402
+ f("span", Ct, [
403
+ x(l, {
404
404
  size: "small",
405
405
  id: "feedbackClose",
406
406
  type: "primary",
407
- onClick: t[0] || (t[0] = x((a) => n.feedbackClose(), ["stop"]))
407
+ onClick: e[0] || (e[0] = A((c) => s.feedbackClose(), ["stop"]))
408
408
  }, {
409
- default: p(() => [
410
- F("Close")
409
+ default: _(() => [
410
+ T("Close")
411
411
  ]),
412
412
  _: 1
413
413
  })
414
414
  ])
415
415
  ]),
416
- default: p(() => [
417
- n.getShowFeedbackAttempts ? (o(), c(y, { key: 0 }, [
418
- s.content.feedbackAttempts ? (o(), c("p", {
416
+ default: _(() => [
417
+ s.getShowFeedbackAttempts ? (a(), u(y, { key: 0 }, [
418
+ i.content.feedbackAttempts ? (a(), u("p", {
419
419
  key: 0,
420
- innerHTML: s.content.feedbackAttempts
421
- }, null, 8, be)) : (o(), c("p", pe, "You have tried too many times, the correct answer has been provided for you."))
422
- ], 64)) : (o(), c(y, { key: 1 }, [
423
- s.content.feedbackImage ? (o(), c("img", {
420
+ innerHTML: i.content.feedbackAttempts
421
+ }, null, 8, yt)) : (a(), u("p", wt, "You have tried too many times, the correct answer has been provided for you."))
422
+ ], 64)) : (a(), u(y, { key: 1 }, [
423
+ i.content.feedbackImage ? (a(), u("img", {
424
424
  key: 0,
425
425
  class: "im-ButtonImage",
426
- src: s.content.feedbackImage,
426
+ src: i.content.feedbackImage,
427
427
  alt: "button image"
428
- }, null, 8, _e)) : d("", !0),
429
- r("p", {
430
- innerHTML: s.content.feedback
431
- }, null, 8, ge)
428
+ }, null, 8, vt)) : b("", !0),
429
+ f("p", {
430
+ innerHTML: i.content.feedback
431
+ }, null, 8, xt)
432
432
  ], 64))
433
433
  ]),
434
434
  _: 1
435
435
  }, 8, ["width", "modelValue", "before-close"]);
436
436
  }
437
- const z = /* @__PURE__ */ S(de, [["render", ye]]);
438
- const we = {
437
+ const I = /* @__PURE__ */ C(bt, [["render", St]]);
438
+ const At = {
439
439
  components: {
440
- Feedback: z
440
+ Feedback: I
441
441
  },
442
442
  inject: ["message"],
443
443
  props: ["content"],
@@ -454,60 +454,60 @@ const we = {
454
454
  }
455
455
  },
456
456
  methods: {
457
- pixelFormat(e) {
458
- return typeof e == "number" ? e + "px" : e;
457
+ pixelFormat(t) {
458
+ return typeof t == "number" ? t + "px" : t;
459
459
  },
460
- changePage(e, t) {
461
- e.pageLink ? this.$store.commit("setCurrentPage", e.pageLink) : e.feedback && (this.feedbackIndex = t, this.feedbackVisibility.indexOf(t) === -1 && this.feedbackVisibility.push(t), this.$store.commit("setShowFeedback", !0), this.content.hotspots.length - 1 === this.feedbackVisibility.length - 1 && (this.$store.commit("setStepHold", !1), this.$store.commit("setStepDone", !0)), setTimeout(() => {
460
+ changePage(t, e) {
461
+ t.pageLink ? this.$store.commit("setCurrentPage", t.pageLink) : t.feedback && (this.feedbackIndex = e, this.feedbackVisibility.indexOf(e) === -1 && this.feedbackVisibility.push(e), this.$store.commit("setShowFeedback", !0), this.content.hotspots.length - 1 === this.feedbackVisibility.length - 1 && (this.$store.commit("setStepHold", !1), this.$store.commit("setStepDone", !0)), setTimeout(() => {
462
462
  document.getElementById("feedbackClose") && document.getElementById("feedbackClose").focus();
463
463
  }));
464
464
  },
465
- showFeedback(e) {
466
- return !!(this.$store.getters.getShowFeedback && this.feedbackIndex === e);
465
+ showFeedback(t) {
466
+ return !!(this.$store.getters.getShowFeedback && this.feedbackIndex === t);
467
467
  }
468
468
  },
469
469
  beforeMount() {
470
470
  this.$store.commit("setStepDone", !1), this.$store.commit("setStepHold", !0);
471
471
  }
472
- }, Ce = { class: "imageMarker" }, ve = ["src", "alt"], Ae = { class: "hotspotArea" }, Se = ["src", "alt"], xe = { class: "im-buttonText" };
473
- function Fe(e, t, s, l, i, n) {
474
- const b = u("el-button"), m = u("Feedback");
475
- return o(), c("div", Ce, [
476
- r("img", {
477
- src: s.content.image,
478
- alt: s.content.imageAlt
479
- }, null, 8, ve),
480
- r("div", Ae, [
481
- (o(!0), c(y, null, T(s.content.hotspots, (a, f) => (o(), c(y, null, [
482
- C(b, {
483
- type: a.buttonType,
484
- onClick: x((_) => n.changePage(a, f), ["stop"]),
485
- id: "hotspot_" + f,
486
- class: v([["is-" + a.buttonShape, { noBG: a.buttonImage }, a.class], "hotspot"]),
487
- style: H({ top: n.pixelFormat(a.cordinatesX), left: n.pixelFormat(a.cordinatesY), width: n.pixelFormat(a.dimensionsW), height: n.pixelFormat(a.dimensionsH) }),
488
- icon: a.buttonIcon
472
+ }, Mt = { class: "imageMarker" }, Tt = ["src", "alt"], Ht = { class: "hotspotArea" }, Bt = ["src", "alt"], zt = { class: "im-buttonText" };
473
+ function $t(t, e, i, r, n, s) {
474
+ const l = g("el-button"), o = g("Feedback");
475
+ return a(), u("div", Mt, [
476
+ f("img", {
477
+ src: i.content.image,
478
+ alt: i.content.imageAlt
479
+ }, null, 8, Tt),
480
+ f("div", Ht, [
481
+ (a(!0), u(y, null, M(i.content.hotspots, (c, m) => (a(), u(y, null, [
482
+ x(l, {
483
+ type: c.buttonType,
484
+ onClick: A((h) => s.changePage(c, m), ["stop"]),
485
+ id: "hotspot_" + m,
486
+ class: w([["is-" + c.buttonShape, { noBG: c.buttonImage }, c.class], "hotspot"]),
487
+ style: B({ top: s.pixelFormat(c.cordinatesX), left: s.pixelFormat(c.cordinatesY), width: s.pixelFormat(c.dimensionsW), height: s.pixelFormat(c.dimensionsH) }),
488
+ icon: c.buttonIcon
489
489
  }, {
490
- default: p(() => [
491
- a.buttonImage ? (o(), c("img", {
490
+ default: _(() => [
491
+ c.buttonImage ? (a(), u("img", {
492
492
  key: 0,
493
493
  class: "im-ButtonImage",
494
- src: a.buttonImage,
495
- alt: "image marker " + Number(f + 1)
496
- }, null, 8, Se)) : d("", !0),
497
- r("span", xe, A(a.name), 1)
494
+ src: c.buttonImage,
495
+ alt: "image marker " + Number(m + 1)
496
+ }, null, 8, Bt)) : b("", !0),
497
+ f("span", zt, S(c.name), 1)
498
498
  ]),
499
499
  _: 2
500
500
  }, 1032, ["type", "onClick", "id", "class", "style", "icon"]),
501
- n.showFeedback(f) ? (o(), w(m, {
501
+ s.showFeedback(m) ? (a(), v(o, {
502
502
  key: 0,
503
- content: a
504
- }, null, 8, ["content"])) : d("", !0)
503
+ content: c
504
+ }, null, 8, ["content"])) : b("", !0)
505
505
  ], 64))), 256))
506
506
  ])
507
507
  ]);
508
508
  }
509
- const Te = /* @__PURE__ */ S(we, [["render", Fe], ["__scopeId", "data-v-3897bfb2"]]);
510
- const He = {
509
+ const Ft = /* @__PURE__ */ C(At, [["render", $t], ["__scopeId", "data-v-3897bfb2"]]);
510
+ const Lt = {
511
511
  props: ["content"],
512
512
  data() {
513
513
  return {
@@ -522,41 +522,41 @@ const He = {
522
522
  }
523
523
  },
524
524
  methods: {
525
- pixelFormat(e) {
526
- return typeof e == "number" ? e + "px" : e;
525
+ pixelFormat(t) {
526
+ return typeof t == "number" ? t + "px" : t;
527
527
  },
528
- changeImage(e) {
529
- this.imageReplaced = !0, this.imageSrc = this.content.hotspots[e].imageOverlay, this.imageAlt = this.content.hotspots[e].imageOverlayAlt, this.$store.commit("setStepHold", !1), this.$store.dispatch("lastPageFocus", {});
528
+ changeImage(t) {
529
+ this.imageReplaced = !0, this.imageSrc = this.content.hotspots[t].imageOverlay, this.imageAlt = this.content.hotspots[t].imageOverlayAlt, this.$store.commit("setStepHold", !1), this.$store.dispatch("lastPageFocus", {});
530
530
  }
531
531
  }
532
- }, Me = ["innerHTML"], $e = ["src", "alt"], Ie = { class: "hotspotArea" };
533
- function ze(e, t, s, l, i, n) {
534
- const b = u("el-col"), m = u("el-button"), a = u("el-row");
535
- return o(), w(a, { class: "imageReplacer" }, {
536
- default: p(() => [
537
- C(b, { span: 12 }, {
538
- default: p(() => [
539
- r("p", {
532
+ }, Dt = ["innerHTML"], It = ["src", "alt"], Et = { class: "hotspotArea" };
533
+ function jt(t, e, i, r, n, s) {
534
+ const l = g("el-col"), o = g("el-button"), c = g("el-row");
535
+ return a(), v(c, { class: "imageReplacer" }, {
536
+ default: _(() => [
537
+ x(l, { span: 12 }, {
538
+ default: _(() => [
539
+ f("p", {
540
540
  class: "imageReplacerDescription",
541
- innerHTML: s.content.description
542
- }, null, 8, Me)
541
+ innerHTML: i.content.description
542
+ }, null, 8, Dt)
543
543
  ]),
544
544
  _: 1
545
545
  }),
546
- C(b, { span: 12 }, {
547
- default: p(() => [
548
- r("img", {
546
+ x(l, { span: 12 }, {
547
+ default: _(() => [
548
+ f("img", {
549
549
  class: "im-ButtonImage",
550
- src: i.imageSrc,
551
- alt: i.imageAlt
552
- }, null, 8, $e),
553
- r("div", Ie, [
554
- (o(!0), c(y, null, T(s.content.hotspots, (f, _) => (o(), w(m, {
555
- type: f.buttonType,
556
- onClick: x((g) => n.changeImage(_), ["stop"]),
550
+ src: n.imageSrc,
551
+ alt: n.imageAlt
552
+ }, null, 8, It),
553
+ f("div", Et, [
554
+ (a(!0), u(y, null, M(i.content.hotspots, (m, h) => (a(), v(o, {
555
+ type: m.buttonType,
556
+ onClick: A((d) => s.changeImage(h), ["stop"]),
557
557
  class: "hotspot",
558
- style: H({ top: n.pixelFormat(f.cordinatesX), left: n.pixelFormat(f.cordinatesY), width: n.pixelFormat(f.dimensionsW), height: n.pixelFormat(f.dimensionsH) }),
559
- icon: f.buttonIcon
558
+ style: B({ top: s.pixelFormat(m.cordinatesX), left: s.pixelFormat(m.cordinatesY), width: s.pixelFormat(m.dimensionsW), height: s.pixelFormat(m.dimensionsH) }),
559
+ icon: m.buttonIcon
560
560
  }, null, 8, ["type", "onClick", "style", "icon"]))), 256))
561
561
  ])
562
562
  ]),
@@ -566,8 +566,8 @@ function ze(e, t, s, l, i, n) {
566
566
  _: 1
567
567
  });
568
568
  }
569
- const je = /* @__PURE__ */ S(He, [["render", ze], ["__scopeId", "data-v-02e047cd"]]);
570
- const Be = {
569
+ const Ot = /* @__PURE__ */ C(Lt, [["render", jt], ["__scopeId", "data-v-02e047cd"]]);
570
+ const Rt = {
571
571
  components: {},
572
572
  props: ["content"],
573
573
  data() {
@@ -597,38 +597,38 @@ const Be = {
597
597
  }
598
598
  },
599
599
  methods: {
600
- quizArrayCompleted(e) {
601
- return !(this.quizItemCompleted.includes(e) || e === 0);
600
+ quizArrayCompleted(t) {
601
+ return !(this.quizItemCompleted.includes(t) || t === 0);
602
602
  },
603
603
  prepareQuiz() {
604
- this.quizArray = this.content.quiz.split("*_").filter((e) => e), this.content.options.forEach((e, t) => {
605
- e.options ? e.random ? this.quizOptions.push(this.shuffle(e.options)) : this.quizOptions.push(e.options) : this.quizOptions.push(!1);
604
+ this.quizArray = this.content.quiz.split("*_").filter((t) => t), this.content.options.forEach((t, e) => {
605
+ t.options ? t.random ? this.quizOptions.push(this.shuffle(t.options)) : this.quizOptions.push(t.options) : this.quizOptions.push(!1);
606
606
  });
607
607
  },
608
- quizType(e) {
609
- return this.content.options[e] && this.content.options[e].type ? this.content.options[e].type : !1;
608
+ quizType(t) {
609
+ return this.content.options[t] && this.content.options[t].type ? this.content.options[t].type : !1;
610
610
  },
611
- quizDisplay(e) {
612
- return this.content.options[e] && this.content.options[e].display ? this.content.options[e].display : "Select";
611
+ quizDisplay(t) {
612
+ return this.content.options[t] && this.content.options[t].display ? this.content.options[t].display : "Select";
613
613
  },
614
- quizClass(e) {
615
- return this.content.options[e] && this.content.options[e].class ? this.content.options[e].class : "";
614
+ quizClass(t) {
615
+ return this.content.options[t] && this.content.options[t].class ? this.content.options[t].class : "";
616
616
  },
617
- shuffle(e) {
618
- let t = e.length, s;
619
- for (; t != 0; )
620
- s = Math.floor(Math.random() * t), t--, [e[t], e[s]] = [
621
- e[s],
622
- e[t]
617
+ shuffle(t) {
618
+ let e = t.length, i;
619
+ for (; e != 0; )
620
+ i = Math.floor(Math.random() * e), e--, [t[e], t[i]] = [
621
+ t[i],
622
+ t[e]
623
623
  ];
624
- return e;
624
+ return t;
625
625
  },
626
626
  choicesCheck() {
627
627
  if (this.getAttempt < this.content.attempts) {
628
- let e = !0, t = !1;
629
- this.input.length === 0 ? this.content.options[0].stopFlow && (t = !0, this.feedbackObject.feedbackHeader = this.content.options[0].notSelectedHeader, this.feedbackObject.feedback = this.content.options[0].notSelectedBody) : this.content.options.forEach((s, l) => {
630
- this.input[l] ? this.input[l] !== this.content.options[l].answer && (e = !1) : this.content.options[this.input.length].stopFlow && (t = !0, this.feedbackObject.feedbackHeader = this.content.options[this.input.length].notSelectedHeader, this.feedbackObject.feedback = this.content.options[this.input.length].notSelectedBody);
631
- }), this.$store.commit("setAttempts", this.getAttempt + 1), e === !0 && this.input.length === this.quizArray.length ? (this.choicesComplete(), this.feedbackObject.feedbackHeader = this.content.correctHeader, this.feedbackObject.feedback = this.content.correctFeedback) : (t || (this.feedbackObject.feedbackHeader = this.content.incorrectHeader, this.feedbackObject.feedback = this.content.incorrectFeedback), this.$store.commit("setAttempts", this.getAttempt + 1));
628
+ let t = !0, e = !1;
629
+ this.input.length === 0 ? this.content.options[0].stopFlow && (e = !0, this.feedbackObject.feedbackHeader = this.content.options[0].notSelectedHeader, this.feedbackObject.feedback = this.content.options[0].notSelectedBody) : this.content.options.forEach((i, r) => {
630
+ this.input[r] ? this.input[r] !== this.content.options[r].answer && (t = !1) : this.content.options[this.input.length].stopFlow && (e = !0, this.feedbackObject.feedbackHeader = this.content.options[this.input.length].notSelectedHeader, this.feedbackObject.feedback = this.content.options[this.input.length].notSelectedBody);
631
+ }), this.$store.commit("setAttempts", this.getAttempt + 1), t === !0 && this.input.length === this.quizArray.length ? (this.choicesComplete(), this.feedbackObject.feedbackHeader = this.content.correctHeader, this.feedbackObject.feedback = this.content.correctFeedback) : (e || (this.feedbackObject.feedbackHeader = this.content.incorrectHeader, this.feedbackObject.feedback = this.content.incorrectFeedback), this.$store.commit("setAttempts", this.getAttempt + 1));
632
632
  } else
633
633
  this.feedbackObject.feedbackAttempts = this.content.feedbackAttempts, this.$store.commit("setShowFeedbackAttempts", !0), this.choicesComplete();
634
634
  this.$store.commit("setShowFeedback", !0), setTimeout(() => {
@@ -636,12 +636,12 @@ const Be = {
636
636
  });
637
637
  },
638
638
  choicesComplete() {
639
- this.quizArray.forEach((e, t) => {
640
- this.input[t] ? this.input[t] = this.content.options[t].answer : this.input.push(this.content.options[t].answer), this.quizItemCompleted.push(t + 1);
639
+ this.quizArray.forEach((t, e) => {
640
+ this.input[e] ? this.input[e] = this.content.options[e].answer : this.input.push(this.content.options[e].answer), this.quizItemCompleted.push(e + 1);
641
641
  }), this.$store.commit("setStepDone", !0), this.$store.commit("setStepHold", !1);
642
642
  },
643
- choicesMade(e) {
644
- this.quizItemCompleted.includes(e + 1) === !1 && this.quizItemCompleted.push(e + 1);
643
+ choicesMade(t) {
644
+ this.quizItemCompleted.includes(t + 1) === !1 && this.quizItemCompleted.push(t + 1);
645
645
  },
646
646
  showFeedback() {
647
647
  return !!this.$store.getters.getShowFeedback;
@@ -649,9 +649,9 @@ const Be = {
649
649
  },
650
650
  mounted() {
651
651
  if (this.prepareQuiz(), this.$store.getters.getDirections.display === !1) {
652
- let e = document.getElementsByClassName("selectableButton");
652
+ let t = document.getElementsByClassName("selectableButton");
653
653
  setTimeout(() => {
654
- e[0].focus();
654
+ t[0].focus();
655
655
  });
656
656
  }
657
657
  },
@@ -659,69 +659,69 @@ const Be = {
659
659
  this.$store.commit("setStepDone", !1), this.$store.commit("setAttempts", 0), this.feedbackIndex = -1, this.content.attempts && (this.totalAttempts = this.content.attempts);
660
660
  }
661
661
  };
662
- function Oe(e, t, s, l, i, n) {
663
- const b = u("el-option"), m = u("el-select"), a = u("el-date-picker"), f = u("el-button"), _ = u("lab-feedback");
664
- return o(), c("div", {
665
- class: v(["drop-down", s.content.class])
662
+ function Wt(t, e, i, r, n, s) {
663
+ const l = g("el-option"), o = g("el-select"), c = g("el-date-picker"), m = g("el-button"), h = g("lab-feedback");
664
+ return a(), u("div", {
665
+ class: w(["drop-down", i.content.class])
666
666
  }, [
667
- r("p", null, [
668
- (o(!0), c(y, null, T(i.quizArray, (g, h) => (o(), c(y, null, [
669
- r("span", {
670
- class: v(n.quizClass(h))
667
+ f("p", null, [
668
+ (a(!0), u(y, null, M(n.quizArray, (d, p) => (a(), u(y, null, [
669
+ f("span", {
670
+ class: w(s.quizClass(p))
671
671
  }, [
672
- r("span", {
673
- class: v("quizText quizSection_" + h)
674
- }, A(g) + " ", 3),
675
- n.quizType(h) === "choose" ? (o(), w(m, {
672
+ f("span", {
673
+ class: w("quizText quizSection_" + p)
674
+ }, S(d) + " ", 3),
675
+ s.quizType(p) === "choose" ? (a(), v(o, {
676
676
  key: 0,
677
- onChange: (k) => n.choicesMade(h),
678
- modelValue: i.input[h],
679
- "onUpdate:modelValue": (k) => i.input[h] = k,
680
- placeholder: n.quizDisplay(h)
677
+ onChange: (k) => s.choicesMade(p),
678
+ modelValue: n.input[p],
679
+ "onUpdate:modelValue": (k) => n.input[p] = k,
680
+ placeholder: s.quizDisplay(p)
681
681
  }, {
682
- default: p(() => [
683
- n.quizArrayCompleted(h) ? d("", !0) : (o(!0), c(y, { key: 0 }, T(i.quizOptions[h], (k) => (o(), w(b, {
682
+ default: _(() => [
683
+ s.quizArrayCompleted(p) ? b("", !0) : (a(!0), u(y, { key: 0 }, M(n.quizOptions[p], (k) => (a(), v(l, {
684
684
  key: k,
685
685
  label: k,
686
686
  value: k
687
687
  }, null, 8, ["label", "value"]))), 128))
688
688
  ]),
689
689
  _: 2
690
- }, 1032, ["onChange", "modelValue", "onUpdate:modelValue", "placeholder"])) : d("", !0),
691
- n.quizType(h) === "date" ? (o(), w(a, {
690
+ }, 1032, ["onChange", "modelValue", "onUpdate:modelValue", "placeholder"])) : b("", !0),
691
+ s.quizType(p) === "date" ? (a(), v(c, {
692
692
  key: 1,
693
- onChange: (k) => n.choicesMade(h),
694
- modelValue: i.input[h],
695
- "onUpdate:modelValue": (k) => i.input[h] = k,
693
+ onChange: (k) => s.choicesMade(p),
694
+ modelValue: n.input[p],
695
+ "onUpdate:modelValue": (k) => n.input[p] = k,
696
696
  type: "date",
697
- placeholder: n.quizDisplay(h),
698
- format: s.content.options[h].format,
699
- "value-format": s.content.options[h].format,
700
- disabled: n.quizArrayCompleted(h)
701
- }, null, 8, ["onChange", "modelValue", "onUpdate:modelValue", "placeholder", "format", "value-format", "disabled"])) : d("", !0)
697
+ placeholder: s.quizDisplay(p),
698
+ format: i.content.options[p].format,
699
+ "value-format": i.content.options[p].format,
700
+ disabled: s.quizArrayCompleted(p)
701
+ }, null, 8, ["onChange", "modelValue", "onUpdate:modelValue", "placeholder", "format", "value-format", "disabled"])) : b("", !0)
702
702
  ], 2),
703
- F("  ")
703
+ T("  ")
704
704
  ], 64))), 256))
705
705
  ]),
706
- C(f, {
706
+ x(m, {
707
707
  size: "small",
708
708
  type: "primary",
709
709
  class: "drop-down-submit",
710
- onClick: t[0] || (t[0] = (g) => n.choicesCheck())
710
+ onClick: e[0] || (e[0] = (d) => s.choicesCheck())
711
711
  }, {
712
- default: p(() => [
713
- F("Submit")
712
+ default: _(() => [
713
+ T("Submit")
714
714
  ]),
715
715
  _: 1
716
716
  }),
717
- n.showFeedback() ? (o(), w(_, {
717
+ s.showFeedback() ? (a(), v(h, {
718
718
  key: 0,
719
- content: i.feedbackObject
720
- }, null, 8, ["content"])) : d("", !0)
719
+ content: n.feedbackObject
720
+ }, null, 8, ["content"])) : b("", !0)
721
721
  ], 2);
722
722
  }
723
- const Le = /* @__PURE__ */ S(Be, [["render", Oe]]);
724
- const qe = {
723
+ const qt = /* @__PURE__ */ C(Rt, [["render", Wt]]);
724
+ const Pt = {
725
725
  components: {},
726
726
  props: ["content"],
727
727
  data() {
@@ -752,20 +752,20 @@ const qe = {
752
752
  this.quizArray = this.content.quiz.split("*_");
753
753
  },
754
754
  choicesCheck() {
755
- this.getAttempt < this.content.attempts ? (this.input.forEach((e, t) => {
756
- if (this.content.answers[t] === e)
757
- this.correctChoices.includes(t) === !1 && this.correctChoices.push(t);
758
- else if (this.correctChoices.includes(t) === !0) {
759
- let s = this.correctChoices.indexOf(t);
760
- this.correctChoices.splice(s, 1);
755
+ this.getAttempt < this.content.attempts ? (this.input.forEach((t, e) => {
756
+ if (this.content.answers[e] === t)
757
+ this.correctChoices.includes(e) === !1 && this.correctChoices.push(e);
758
+ else if (this.correctChoices.includes(e) === !0) {
759
+ let i = this.correctChoices.indexOf(e);
760
+ this.correctChoices.splice(i, 1);
761
761
  }
762
762
  }), this.input.length === 0 ? (this.feedbackObject.feedbackHeader = "You did not enter an answer", this.feedbackObject.feedback = "Please enter your choice in the input field") : this.correctChoices.length === this.content.answers.length ? (this.choicesComplete(), this.feedbackObject.feedbackHeader = this.content.correctHeader, this.feedbackObject.feedback = this.content.correctFeedback) : (this.$store.commit("setAttempts", this.getAttempt + 1), this.feedbackObject.feedbackHeader = this.content.incorrectHeader, this.feedbackObject.feedback = this.content.incorrectFeedback)) : (this.feedbackObject.feedbackAttempts = this.content.feedbackAttempts, this.$store.commit("setShowFeedbackAttempts", !0), this.choicesComplete()), this.$store.commit("setShowFeedback", !0), setTimeout(() => {
763
763
  document.getElementById("feedbackClose") && document.getElementById("feedbackClose").focus();
764
764
  });
765
765
  },
766
766
  choicesComplete() {
767
- this.input.forEach((e, t) => {
768
- this.input[t] = this.content.answers[t];
767
+ this.input.forEach((t, e) => {
768
+ this.input[e] = this.content.answers[e];
769
769
  }), this.$store.commit("setStepDone", !0), this.$store.commit("setStepHold", !1);
770
770
  },
771
771
  showFeedback() {
@@ -774,9 +774,9 @@ const qe = {
774
774
  },
775
775
  mounted() {
776
776
  if (this.prepareQuiz(), this.$store.getters.getDirections.display === !1) {
777
- let e = document.getElementsByClassName("selectableButton");
777
+ let t = document.getElementsByClassName("selectableButton");
778
778
  setTimeout(() => {
779
- e[0].focus();
779
+ t[0].focus();
780
780
  });
781
781
  }
782
782
  },
@@ -784,42 +784,42 @@ const qe = {
784
784
  this.$store.commit("setStepDone", !1), this.$store.commit("setAttempts", 0), this.feedbackIndex = -1, this.content.attempts && (this.totalAttempts = this.content.attempts);
785
785
  }
786
786
  };
787
- function Ve(e, t, s, l, i, n) {
788
- const b = u("el-input"), m = u("el-button"), a = u("lab-feedback");
789
- return o(), c("div", {
790
- class: v(["fill-blank", s.content.class])
787
+ function Vt(t, e, i, r, n, s) {
788
+ const l = g("el-input"), o = g("el-button"), c = g("lab-feedback");
789
+ return a(), u("div", {
790
+ class: w(["fill-blank", i.content.class])
791
791
  }, [
792
- r("p", null, [
793
- (o(!0), c(y, null, T(i.quizArray, (f, _) => (o(), c(y, null, [
794
- F(A(f), 1),
795
- _ < n.quizArrayCount ? (o(), w(b, {
792
+ f("p", null, [
793
+ (a(!0), u(y, null, M(n.quizArray, (m, h) => (a(), u(y, null, [
794
+ T(S(m), 1),
795
+ h < s.quizArrayCount ? (a(), v(l, {
796
796
  key: 0,
797
- modelValue: i.input[_],
798
- "onUpdate:modelValue": (g) => i.input[_] = g,
797
+ modelValue: n.input[h],
798
+ "onUpdate:modelValue": (d) => n.input[h] = d,
799
799
  placeholder: "Please input",
800
800
  size: "small"
801
- }, null, 8, ["modelValue", "onUpdate:modelValue"])) : d("", !0)
801
+ }, null, 8, ["modelValue", "onUpdate:modelValue"])) : b("", !0)
802
802
  ], 64))), 256))
803
803
  ]),
804
- C(m, {
804
+ x(o, {
805
805
  size: "small",
806
806
  type: "primary",
807
807
  class: "fill-blank-submit",
808
- onClick: t[0] || (t[0] = (f) => n.choicesCheck())
808
+ onClick: e[0] || (e[0] = (m) => s.choicesCheck())
809
809
  }, {
810
- default: p(() => [
811
- F("Submit")
810
+ default: _(() => [
811
+ T("Submit")
812
812
  ]),
813
813
  _: 1
814
814
  }),
815
- n.showFeedback() ? (o(), w(a, {
815
+ s.showFeedback() ? (a(), v(c, {
816
816
  key: 0,
817
- content: i.feedbackObject
818
- }, null, 8, ["content"])) : d("", !0)
817
+ content: n.feedbackObject
818
+ }, null, 8, ["content"])) : b("", !0)
819
819
  ], 2);
820
820
  }
821
- const Ee = /* @__PURE__ */ S(qe, [["render", Ve]]);
822
- const Pe = {
821
+ const Nt = /* @__PURE__ */ C(Pt, [["render", Vt]]);
822
+ const Xt = {
823
823
  components: {},
824
824
  props: ["content"],
825
825
  data() {
@@ -847,97 +847,97 @@ const Pe = {
847
847
  rightColWidth() {
848
848
  return this.content.leftColWidth ? this.content.leftColWidth < 24 ? 24 - this.content.leftColWidth : 24 : 12;
849
849
  },
850
- pixelFormat(e) {
851
- return typeof e == "number" ? e + "px" : e;
850
+ pixelFormat(t) {
851
+ return typeof t == "number" ? t + "px" : t;
852
852
  },
853
853
  choicesComplete() {
854
- let e = document.querySelectorAll(".selectableButton");
855
- for (let t = 0; t < e.length; t++)
856
- e[t].classList.add("is-failure"), e[t].setAttribute("disabled", !0), this.content.choices[t].correct && e[t].classList.add("is-success");
854
+ let t = document.querySelectorAll(".selectableButton");
855
+ for (let e = 0; e < t.length; e++)
856
+ t[e].classList.add("is-failure"), t[e].setAttribute("disabled", !0), this.content.choices[e].correct && t[e].classList.add("is-success");
857
857
  this.$store.commit("setStepDone", !0), this.$store.commit("setStepHold", !1);
858
858
  },
859
- choicesCheck(e) {
860
- this.getAttempt < Number(this.content.attempts) ? this.content.choices[e].correct === !0 ? (console.log(" it was true"), this.choicesComplete()) : this.$store.commit("setAttempts", this.getAttempt + 1) : (this.content.choices[e].correct !== !0 && this.$store.commit("setShowFeedbackAttempts", !0), this.choicesComplete()), this.feedbackIndex = e, this.$store.commit("setShowFeedback", !0), setTimeout(() => {
859
+ choicesCheck(t) {
860
+ this.getAttempt < Number(this.content.attempts) ? this.content.choices[t].correct === !0 ? (console.log(" it was true"), this.choicesComplete()) : this.$store.commit("setAttempts", this.getAttempt + 1) : (this.content.choices[t].correct !== !0 && this.$store.commit("setShowFeedbackAttempts", !0), this.choicesComplete()), this.feedbackIndex = t, this.$store.commit("setShowFeedback", !0), setTimeout(() => {
861
861
  document.getElementById("feedbackClose") && document.getElementById("feedbackClose").focus();
862
862
  });
863
863
  },
864
864
  shuffledChoices() {
865
- let e = this.content.choices;
866
- for (let t = e.length - 1; t > 0; t--) {
867
- const s = Math.floor(Math.random() * (t + 1));
868
- [e[t], e[s]] = [e[s], e[t]];
865
+ let t = this.content.choices;
866
+ for (let e = t.length - 1; e > 0; e--) {
867
+ const i = Math.floor(Math.random() * (e + 1));
868
+ [t[e], t[i]] = [t[i], t[e]];
869
869
  }
870
- this.content.choices = e;
870
+ this.content.choices = t;
871
871
  },
872
- showFeedback(e) {
873
- return this.$store.getters.getShowFeedback && this.feedbackIndex === e ? (this.content.choices[e].correct && this.choicesComplete(), !0) : !1;
872
+ showFeedback(t) {
873
+ return this.$store.getters.getShowFeedback && this.feedbackIndex === t ? (this.content.choices[t].correct && this.choicesComplete(), !0) : !1;
874
874
  }
875
875
  },
876
876
  mounted() {
877
877
  if (this.$store.getters.getDirections.display === !1) {
878
- let e = document.getElementsByClassName("selectableButton");
878
+ let t = document.getElementsByClassName("selectableButton");
879
879
  setTimeout(() => {
880
- e[0].focus();
880
+ t[0].focus();
881
881
  });
882
882
  }
883
883
  },
884
884
  beforeMount() {
885
885
  this.$store.commit("setStepDone", !1), this.$store.commit("setAttempts", 0), this.feedbackIndex = -1, this.shuffledChoices(), this.content.attempts && (this.totalAttempts = this.content.attempts);
886
886
  }
887
- }, De = ["innerHTML"], We = { class: "buttonSpan" }, Ue = ["src", "alt"], Ne = { class: "selectable-buttonText" };
888
- function Ke(e, t, s, l, i, n) {
889
- const b = u("lab-image"), m = u("el-col"), a = u("el-divider"), f = u("el-button"), _ = u("lab-feedback"), g = u("el-row");
890
- return o(), w(g, {
891
- id: s.content.id,
892
- class: v(["selectable", s.content.classes])
887
+ }, Yt = ["innerHTML"], Ut = { class: "buttonSpan" }, Kt = ["src", "alt"], Gt = { class: "selectable-buttonText" };
888
+ function Qt(t, e, i, r, n, s) {
889
+ const l = g("lab-image"), o = g("el-col"), c = g("el-divider"), m = g("el-button"), h = g("lab-feedback"), d = g("el-row");
890
+ return a(), v(d, {
891
+ id: i.content.id,
892
+ class: w(["selectable", i.content.classes])
893
893
  }, {
894
- default: p(() => [
895
- C(m, {
896
- span: n.leftColWidth(e.index)
894
+ default: _(() => [
895
+ x(o, {
896
+ span: s.leftColWidth(t.index)
897
897
  }, {
898
- default: p(() => [
899
- s.content.directions ? (o(), c("p", {
898
+ default: _(() => [
899
+ i.content.directions ? (a(), u("p", {
900
900
  key: 0,
901
- innerHTML: s.content.directions
902
- }, null, 8, De)) : d("", !0),
903
- s.content.image ? (o(), w(b, {
901
+ innerHTML: i.content.directions
902
+ }, null, 8, Yt)) : b("", !0),
903
+ i.content.image ? (a(), v(l, {
904
904
  key: 1,
905
- content: s.content.image
906
- }, null, 8, ["content"])) : d("", !0)
905
+ content: i.content.image
906
+ }, null, 8, ["content"])) : b("", !0)
907
907
  ]),
908
908
  _: 1
909
909
  }, 8, ["span"]),
910
- C(m, {
911
- span: n.rightColWidth(e.index),
910
+ x(o, {
911
+ span: s.rightColWidth(t.index),
912
912
  class: "selectArea"
913
913
  }, {
914
- default: p(() => [
915
- (o(!0), c(y, null, T(s.content.choices, (h, k) => (o(), c(y, null, [
916
- !s.content.noDivider && k > 0 ? (o(), w(a, { key: 0 })) : d("", !0),
917
- C(f, {
914
+ default: _(() => [
915
+ (a(!0), u(y, null, M(i.content.choices, (p, k) => (a(), u(y, null, [
916
+ !i.content.noDivider && k > 0 ? (a(), v(c, { key: 0 })) : b("", !0),
917
+ x(m, {
918
918
  size: "small",
919
919
  type: "primary",
920
920
  class: "selectableButton",
921
- style: H({ width: n.pixelFormat(s.content.choiceWidth), height: n.pixelFormat(s.content.choiceHeight) }),
922
- onClick: (M) => n.choicesCheck(k)
921
+ style: B({ width: s.pixelFormat(i.content.choiceWidth), height: s.pixelFormat(i.content.choiceHeight) }),
922
+ onClick: (H) => s.choicesCheck(k)
923
923
  }, {
924
- default: p(() => [
925
- r("div", We, [
926
- h.image ? (o(), c("img", {
924
+ default: _(() => [
925
+ f("div", Ut, [
926
+ p.image ? (a(), u("img", {
927
927
  key: 0,
928
928
  class: "im-ButtonImage",
929
- src: h.image,
930
- alt: h.alt ? h.alt : "button image"
931
- }, null, 8, Ue)) : d("", !0),
932
- r("span", Ne, A(h.text), 1)
929
+ src: p.image,
930
+ alt: p.alt ? p.alt : "button image"
931
+ }, null, 8, Kt)) : b("", !0),
932
+ f("span", Gt, S(p.text), 1)
933
933
  ])
934
934
  ]),
935
935
  _: 2
936
936
  }, 1032, ["style", "onClick"]),
937
- n.showFeedback(k) ? (o(), w(_, {
937
+ s.showFeedback(k) ? (a(), v(h, {
938
938
  key: 1,
939
- content: h
940
- }, null, 8, ["content"])) : d("", !0)
939
+ content: p
940
+ }, null, 8, ["content"])) : b("", !0)
941
941
  ], 64))), 256))
942
942
  ]),
943
943
  _: 1
@@ -946,8 +946,8 @@ function Ke(e, t, s, l, i, n) {
946
946
  _: 1
947
947
  }, 8, ["id", "class"]);
948
948
  }
949
- const Re = /* @__PURE__ */ S(Pe, [["render", Ke], ["__scopeId", "data-v-bc83f1c6"]]);
950
- const Qe = {
949
+ const Jt = /* @__PURE__ */ C(Xt, [["render", Qt], ["__scopeId", "data-v-bc83f1c6"]]);
950
+ const Zt = {
951
951
  components: {},
952
952
  props: ["content"],
953
953
  data() {
@@ -972,11 +972,11 @@ const Qe = {
972
972
  methods: {
973
973
  choicesCheck() {
974
974
  if (this.getAttempt < this.content.attempts) {
975
- let e = !1;
976
- this.content.answers.forEach((t, s) => {
977
- let l = t.toLowerCase();
978
- this.input.toLowerCase().includes(l) || (e = !0);
979
- }), e ? (this.$store.commit("setAttempts", this.getAttempt + 1), this.feedbackObject.feedbackHeader = this.content.incorrectHeader, this.feedbackObject.feedback = this.content.incorrectFeedback) : (this.choicesComplete(), this.feedbackObject.feedbackHeader = this.content.correctHeader, this.feedbackObject.feedback = this.content.correctFeedback);
975
+ let t = !1;
976
+ this.content.answers.forEach((e, i) => {
977
+ let r = e.toLowerCase();
978
+ this.input.toLowerCase().includes(r) || (t = !0);
979
+ }), t ? (this.$store.commit("setAttempts", this.getAttempt + 1), this.feedbackObject.feedbackHeader = this.content.incorrectHeader, this.feedbackObject.feedback = this.content.incorrectFeedback) : (this.choicesComplete(), this.feedbackObject.feedbackHeader = this.content.correctHeader, this.feedbackObject.feedback = this.content.correctFeedback);
980
980
  } else
981
981
  this.feedbackObject.feedbackAttempts = this.content.feedbackAttempts, this.$store.commit("setShowFeedbackAttempts", !0), this.choicesComplete();
982
982
  this.$store.commit("setShowFeedback", !0), setTimeout(() => {
@@ -992,9 +992,9 @@ const Qe = {
992
992
  },
993
993
  mounted() {
994
994
  if (this.$store.getters.getDirections.display === !1) {
995
- let e = document.getElementsByClassName("selectableButton");
995
+ let t = document.getElementsByClassName("selectableButton");
996
996
  setTimeout(() => {
997
- e[0].focus();
997
+ t[0].focus();
998
998
  });
999
999
  }
1000
1000
  },
@@ -1002,38 +1002,38 @@ const Qe = {
1002
1002
  this.$store.commit("setStepDone", !1), this.$store.commit("setAttempts", 0), this.feedbackIndex = -1, this.content.attempts && (this.totalAttempts = this.content.attempts);
1003
1003
  }
1004
1004
  };
1005
- function Ye(e, t, s, l, i, n) {
1006
- const b = u("el-input"), m = u("el-button"), a = u("lab-feedback");
1007
- return o(), c("div", {
1008
- class: v(["textbox", s.content.class])
1005
+ function te(t, e, i, r, n, s) {
1006
+ const l = g("el-input"), o = g("el-button"), c = g("lab-feedback");
1007
+ return a(), u("div", {
1008
+ class: w(["textbox", i.content.class])
1009
1009
  }, [
1010
- r("p", null, A(s.content.quiz), 1),
1011
- C(b, {
1012
- modelValue: i.input,
1013
- "onUpdate:modelValue": t[0] || (t[0] = (f) => i.input = f),
1010
+ f("p", null, S(i.content.quiz), 1),
1011
+ x(l, {
1012
+ modelValue: n.input,
1013
+ "onUpdate:modelValue": e[0] || (e[0] = (m) => n.input = m),
1014
1014
  autosize: { minRows: 4, maxRows: 8 },
1015
1015
  type: "textarea",
1016
1016
  placeholder: "Please input"
1017
1017
  }, null, 8, ["modelValue"]),
1018
- C(m, {
1018
+ x(o, {
1019
1019
  size: "small",
1020
1020
  type: "primary",
1021
1021
  class: "fill-blank-submit",
1022
- onClick: t[1] || (t[1] = (f) => n.choicesCheck())
1022
+ onClick: e[1] || (e[1] = (m) => s.choicesCheck())
1023
1023
  }, {
1024
- default: p(() => [
1025
- F("Submit")
1024
+ default: _(() => [
1025
+ T("Submit")
1026
1026
  ]),
1027
1027
  _: 1
1028
1028
  }),
1029
- n.showFeedback() ? (o(), w(a, {
1029
+ s.showFeedback() ? (a(), v(c, {
1030
1030
  key: 0,
1031
- content: i.feedbackObject
1032
- }, null, 8, ["content"])) : d("", !0)
1031
+ content: n.feedbackObject
1032
+ }, null, 8, ["content"])) : b("", !0)
1033
1033
  ], 2);
1034
1034
  }
1035
- const Xe = /* @__PURE__ */ S(Qe, [["render", Ye]]);
1036
- const Ge = {
1035
+ const ee = /* @__PURE__ */ C(Zt, [["render", te]]);
1036
+ const ie = {
1037
1037
  components: {},
1038
1038
  props: ["content"],
1039
1039
  data() {
@@ -1060,43 +1060,43 @@ const Ge = {
1060
1060
  }
1061
1061
  },
1062
1062
  methods: {
1063
- showSub(e) {
1064
- let t = document.getElementById(e);
1065
- t.classList.contains("jl-menu-sub_show") ? (this.showMenuOverlay = !1, this.hideSubs()) : (this.showMenuOverlay = !0, t.classList.add("jl-menu-sub_show"));
1063
+ showSub(t) {
1064
+ let e = document.getElementById(t);
1065
+ e.classList.contains("jl-menu-sub_show") ? (this.showMenuOverlay = !1, this.hideSubs()) : (this.showMenuOverlay = !0, e.classList.add("jl-menu-sub_show"));
1066
1066
  },
1067
- showSubSub(e) {
1068
- let t = document.getElementById(e);
1069
- t.classList.contains("jl-menu-sub-sub_show") ? (this.showMenuOverlay = !1, this.hideSubs()) : (this.showMenuOverlay = !0, t.classList.add("jl-menu-sub-sub_show"));
1067
+ showSubSub(t) {
1068
+ let e = document.getElementById(t);
1069
+ e.classList.contains("jl-menu-sub-sub_show") ? (this.showMenuOverlay = !1, this.hideSubs()) : (this.showMenuOverlay = !0, e.classList.add("jl-menu-sub-sub_show"));
1070
1070
  },
1071
1071
  hideSubs() {
1072
1072
  this.showMenuOverlay = !1;
1073
- let e = document.getElementsByClassName("jl-menu-sub_show");
1074
- for (; e.length > 0; )
1075
- e[0].classList.remove("jl-menu-sub_show");
1076
- let t = document.getElementsByClassName("jl-menu-sub-sub_show");
1073
+ let t = document.getElementsByClassName("jl-menu-sub_show");
1077
1074
  for (; t.length > 0; )
1078
- t[0].classList.remove("jl-menu-sub-sub_show");
1075
+ t[0].classList.remove("jl-menu-sub_show");
1076
+ let e = document.getElementsByClassName("jl-menu-sub-sub_show");
1077
+ for (; e.length > 0; )
1078
+ e[0].classList.remove("jl-menu-sub-sub_show");
1079
1079
  },
1080
- choicesCheck(e) {
1080
+ choicesCheck(t) {
1081
1081
  this.hideSubs();
1082
- let t = !1, s = "";
1082
+ let e = !1, i = "";
1083
1083
  if (this.getAttempt < this.content.attempts) {
1084
- if (typeof e == "string") {
1085
- let l = e.split("-");
1086
- l.forEach((i, n) => {
1087
- l[n] = Number(i);
1088
- }), l.length === 2 ? this.content.menu[l[0]].subMenu[l[1]].correct && (this.content.menu[l[0]].subMenu[l[1]].page && (s = this.content.menu[l[0]].subMenu[l[1]].page), t = !0) : l.length === 3 && this.content.menu[l[0]].subMenu[l[1]].subMenu[l[2]].correct && (this.content.menu[l[0]].subMenu[l[1]].subMenu[l[2]].page && (s = this.content.menu[l[0]].subMenu[l[1]].subMenu[l[2]].page), t = !0);
1084
+ if (typeof t == "string") {
1085
+ let r = t.split("-");
1086
+ r.forEach((n, s) => {
1087
+ r[s] = Number(n);
1088
+ }), r.length === 2 ? this.content.menu[r[0]].subMenu[r[1]].correct && (this.content.menu[r[0]].subMenu[r[1]].page && (i = this.content.menu[r[0]].subMenu[r[1]].page), e = !0) : r.length === 3 && this.content.menu[r[0]].subMenu[r[1]].subMenu[r[2]].correct && (this.content.menu[r[0]].subMenu[r[1]].subMenu[r[2]].page && (i = this.content.menu[r[0]].subMenu[r[1]].subMenu[r[2]].page), e = !0);
1089
1089
  } else
1090
- this.content.menu[e].correct && (this.content.menu[e].page && (s = this.content.menu[e].page), t = !0);
1091
- t ? (this.choicesComplete(s), this.feedbackObject.feedbackHeader = this.content.correctHeader, this.feedbackObject.feedback = this.content.correctFeedback) : (this.$store.commit("setAttempts", this.getAttempt + 1), this.feedbackObject.feedbackHeader = this.content.incorrectHeader, this.feedbackObject.feedback = this.content.incorrectFeedback);
1090
+ this.content.menu[t].correct && (this.content.menu[t].page && (i = this.content.menu[t].page), e = !0);
1091
+ e ? (this.choicesComplete(i), this.feedbackObject.feedbackHeader = this.content.correctHeader, this.feedbackObject.feedback = this.content.correctFeedback) : (this.$store.commit("setAttempts", this.getAttempt + 1), this.feedbackObject.feedbackHeader = this.content.incorrectHeader, this.feedbackObject.feedback = this.content.incorrectFeedback);
1092
1092
  } else
1093
1093
  this.$store.commit("setShowFeedbackAttempts", !0), this.choicesComplete();
1094
- s === "" && this.$store.commit("setShowFeedback", !0), setTimeout(() => {
1094
+ i === "" && this.$store.commit("setShowFeedback", !0), setTimeout(() => {
1095
1095
  document.getElementById("feedbackClose") && document.getElementById("feedbackClose").focus();
1096
1096
  });
1097
1097
  },
1098
- choicesComplete(e) {
1099
- this.$store.commit("setStepDone", !0), this.$store.commit("setStepHold", !1), e !== "" && this.$store.commit("setCurrentPage", e);
1098
+ choicesComplete(t) {
1099
+ this.$store.commit("setStepDone", !0), this.$store.commit("setStepHold", !1), t !== "" && this.$store.commit("setCurrentPage", t);
1100
1100
  },
1101
1101
  showFeedback() {
1102
1102
  return !!this.$store.getters.getShowFeedback;
@@ -1109,114 +1109,780 @@ const Ge = {
1109
1109
  beforeMount() {
1110
1110
  this.$store.commit("setStepDone", !1), this.$store.commit("setAttempts", 0), this.feedbackIndex = -1, this.content.attempts && (this.totalAttempts = this.content.attempts);
1111
1111
  }
1112
- }, Je = { key: 0 }, Ze = ["index", "onClick"], et = { class: "jl-menu-sub__title" }, tt = ["id"], st = ["index", "onClick"], nt = { class: "jl-menu-sub-sub__title" }, ot = ["id"], it = ["index", "onClick"], ct = ["onClick"], lt = {
1112
+ }, se = { key: 0 }, ne = ["index", "onClick"], oe = { class: "jl-menu-sub__title" }, re = ["id"], ae = ["index", "onClick"], ce = { class: "jl-menu-sub-sub__title" }, le = ["id"], he = ["index", "onClick"], ue = ["onClick"], de = {
1113
1113
  key: 1,
1114
1114
  class: "jl-menu-item"
1115
- }, rt = ["index", "onClick"];
1116
- function at(e, t, s, l, i, n) {
1117
- const b = u("CaretBottom"), m = u("el-icon"), a = u("CaretRight"), f = u("lab-feedback");
1118
- return o(), c("div", {
1119
- class: v(["menu-chooser", s.content.class])
1115
+ }, me = ["index", "onClick"];
1116
+ function fe(t, e, i, r, n, s) {
1117
+ const l = g("CaretBottom"), o = g("el-icon"), c = g("CaretRight"), m = g("lab-feedback");
1118
+ return a(), u("div", {
1119
+ class: w(["menu-chooser", i.content.class])
1120
1120
  }, [
1121
- i.showMenuOverlay ? (o(), c("div", {
1121
+ n.showMenuOverlay ? (a(), u("div", {
1122
1122
  key: 0,
1123
1123
  class: "nav-mask",
1124
- onClick: t[0] || (t[0] = (..._) => n.hideSubs && n.hideSubs(..._))
1125
- })) : d("", !0),
1126
- r("p", null, A(s.content.quiz), 1),
1127
- r("div", {
1124
+ onClick: e[0] || (e[0] = (...h) => s.hideSubs && s.hideSubs(...h))
1125
+ })) : b("", !0),
1126
+ f("p", null, S(i.content.quiz), 1),
1127
+ f("div", {
1128
1128
  class: "jl-menu",
1129
- onSelect: t[1] || (t[1] = (..._) => n.choicesCheck && n.choicesCheck(..._))
1129
+ onSelect: e[1] || (e[1] = (...h) => s.choicesCheck && s.choicesCheck(...h))
1130
1130
  }, [
1131
- (o(!0), c(y, null, T(s.content.menu, (_, g) => (o(), c(y, null, [
1132
- _.subMenu ? (o(), c("div", Je, [
1133
- r("button", {
1134
- class: v("jl-menu-sub sub-" + g),
1135
- index: g,
1131
+ (a(!0), u(y, null, M(i.content.menu, (h, d) => (a(), u(y, null, [
1132
+ h.subMenu ? (a(), u("div", se, [
1133
+ f("button", {
1134
+ class: w("jl-menu-sub sub-" + d),
1135
+ index: d,
1136
1136
  tabindex: "0",
1137
1137
  role: "menuitem",
1138
- onClick: x((h) => n.showSub("sub-" + g), ["stop"])
1138
+ onClick: A((p) => s.showSub("sub-" + d), ["stop"])
1139
1139
  }, [
1140
- r("div", et, [
1141
- F(A(_.name) + " ", 1),
1142
- C(m, null, {
1143
- default: p(() => [
1144
- C(b)
1140
+ f("div", oe, [
1141
+ T(S(h.name) + " ", 1),
1142
+ x(o, null, {
1143
+ default: _(() => [
1144
+ x(l)
1145
1145
  ]),
1146
1146
  _: 1
1147
1147
  })
1148
1148
  ])
1149
- ], 10, Ze),
1150
- r("div", {
1149
+ ], 10, ne),
1150
+ f("div", {
1151
1151
  class: "jl-menu-sub-menu",
1152
- id: "sub-" + g
1152
+ id: "sub-" + d
1153
1153
  }, [
1154
- (o(!0), c(y, null, T(_.subMenu, (h, k) => (o(), c(y, null, [
1155
- h.subMenu ? (o(), c(y, { key: 0 }, [
1156
- r("button", {
1157
- class: v("jl-menu-sub-sub sub-sub-" + k),
1158
- index: g + "-" + k,
1154
+ (a(!0), u(y, null, M(h.subMenu, (p, k) => (a(), u(y, null, [
1155
+ p.subMenu ? (a(), u(y, { key: 0 }, [
1156
+ f("button", {
1157
+ class: w("jl-menu-sub-sub sub-sub-" + k),
1158
+ index: d + "-" + k,
1159
1159
  tabindex: "0",
1160
1160
  role: "menuitem",
1161
- onClick: x((M) => n.showSubSub("sub-sub-" + g), ["stop"])
1161
+ onClick: A((H) => s.showSubSub("sub-sub-" + d), ["stop"])
1162
1162
  }, [
1163
- r("div", nt, [
1164
- F(A(h.name), 1),
1165
- C(m, null, {
1166
- default: p(() => [
1167
- C(a)
1163
+ f("div", ce, [
1164
+ T(S(p.name), 1),
1165
+ x(o, null, {
1166
+ default: _(() => [
1167
+ x(c)
1168
1168
  ]),
1169
1169
  _: 1
1170
1170
  })
1171
1171
  ])
1172
- ], 10, st),
1173
- r("div", {
1172
+ ], 10, ae),
1173
+ f("div", {
1174
1174
  class: "jl-menu-sub-sub-menu",
1175
- id: "sub-sub-" + g
1175
+ id: "sub-sub-" + d
1176
1176
  }, [
1177
- (o(!0), c(y, null, T(h.subMenu, (M, $) => (o(), c("button", {
1177
+ (a(!0), u(y, null, M(p.subMenu, (H, z) => (a(), u("button", {
1178
1178
  class: "jl-menu-sub-sub-item",
1179
- index: g + "-" + k + "-" + $,
1179
+ index: d + "-" + k + "-" + z,
1180
1180
  tabindex: "0",
1181
1181
  role: "menuitem",
1182
- onClick: x((ht) => n.choicesCheck(g + "-" + k + "-" + $), ["stop"])
1182
+ onClick: A(($) => s.choicesCheck(d + "-" + k + "-" + z), ["stop"])
1183
1183
  }, [
1184
- r("div", null, A(M.name), 1)
1185
- ], 8, it))), 256))
1186
- ], 8, ot)
1187
- ], 64)) : (o(), c("button", {
1184
+ f("div", null, S(H.name), 1)
1185
+ ], 8, he))), 256))
1186
+ ], 8, le)
1187
+ ], 64)) : (a(), u("button", {
1188
1188
  key: 1,
1189
1189
  class: "jl-menu-sub-item",
1190
1190
  tabindex: "0",
1191
1191
  role: "menuitem",
1192
- onClick: x((M) => n.choicesCheck(g + "-" + k), ["stop"])
1192
+ onClick: A((H) => s.choicesCheck(d + "-" + k), ["stop"])
1193
1193
  }, [
1194
- r("div", null, A(h.name), 1)
1195
- ], 8, ct))
1194
+ f("div", null, S(p.name), 1)
1195
+ ], 8, ue))
1196
1196
  ], 64))), 256))
1197
- ], 8, tt)
1198
- ])) : (o(), c("div", lt, [
1199
- r("button", {
1197
+ ], 8, re)
1198
+ ])) : (a(), u("div", de, [
1199
+ f("button", {
1200
1200
  class: "jl-menu-item",
1201
- index: g,
1201
+ index: d,
1202
1202
  tabindex: "0",
1203
1203
  role: "menuitem",
1204
- onClick: x((h) => n.choicesCheck(g), ["stop"])
1205
- }, A(_.name), 9, rt)
1204
+ onClick: A((p) => s.choicesCheck(d), ["stop"])
1205
+ }, S(h.name), 9, me)
1206
1206
  ]))
1207
1207
  ], 64))), 256))
1208
1208
  ], 32),
1209
- n.showFeedback() ? (o(), w(f, {
1209
+ s.showFeedback() ? (a(), v(m, {
1210
1210
  key: 1,
1211
- content: i.feedbackObject
1212
- }, null, 8, ["content"])) : d("", !0)
1211
+ content: n.feedbackObject
1212
+ }, null, 8, ["content"])) : b("", !0)
1213
1213
  ], 2);
1214
1214
  }
1215
- const ut = /* @__PURE__ */ S(Ge, [["render", at]]), mt = {
1216
- install: (e, t) => {
1217
- e.component("special-uploader", P), e.component("lab-header", U), e.component("lab-footer", I), e.component("lab-drawer", I), e.component("lab-image", te), e.component("lab-kaltura", he), e.component("lab-image-marker", Te), e.component("lab-image-replacer", je), e.component("lab-feedback", z), e.component("lab-drop-down", Le), e.component("lab-fill-blank", Ee), e.component("lab-selectable", Re), e.component("lab-textbox", Xe), e.component("lab-menu_chooser", ut);
1215
+ const pe = /* @__PURE__ */ C(ie, [["render", fe]]);
1216
+ const D = {
1217
+ y: {
1218
+ t: "top",
1219
+ m: "marginTop",
1220
+ b: "bottom"
1221
+ },
1222
+ x: {
1223
+ l: "left",
1224
+ m: "marginLeft",
1225
+ r: "right"
1226
+ }
1227
+ };
1228
+ function ge(t) {
1229
+ t.forEach((e, i) => {
1230
+ document.documentElement.addEventListener(i, e);
1231
+ });
1232
+ }
1233
+ function be(t) {
1234
+ t.forEach((e, i) => {
1235
+ document.documentElement.removeEventListener(i, e);
1236
+ });
1237
+ }
1238
+ const _e = {
1239
+ name: "vue-drag-resize",
1240
+ emits: ["clicked", "dragging", "dragstop", "resizing", "resizestop", "activated", "deactivated"],
1241
+ props: {
1242
+ stickSize: {
1243
+ type: Number,
1244
+ default: 8
1245
+ },
1246
+ parentScaleX: {
1247
+ type: Number,
1248
+ default: 1
1249
+ },
1250
+ parentScaleY: {
1251
+ type: Number,
1252
+ default: 1
1253
+ },
1254
+ isActive: {
1255
+ type: Boolean,
1256
+ default: !1
1257
+ },
1258
+ preventActiveBehavior: {
1259
+ type: Boolean,
1260
+ default: !1
1261
+ },
1262
+ isDraggable: {
1263
+ type: Boolean,
1264
+ default: !0
1265
+ },
1266
+ isResizable: {
1267
+ type: Boolean,
1268
+ default: !0
1269
+ },
1270
+ aspectRatio: {
1271
+ type: Boolean,
1272
+ default: !1
1273
+ },
1274
+ parentLimitation: {
1275
+ type: Boolean,
1276
+ default: !1
1277
+ },
1278
+ snapToGrid: {
1279
+ type: Boolean,
1280
+ default: !1
1281
+ },
1282
+ gridX: {
1283
+ type: Number,
1284
+ default: 50,
1285
+ validator(t) {
1286
+ return t >= 0;
1287
+ }
1288
+ },
1289
+ gridY: {
1290
+ type: Number,
1291
+ default: 50,
1292
+ validator(t) {
1293
+ return t >= 0;
1294
+ }
1295
+ },
1296
+ parentW: {
1297
+ type: Number,
1298
+ default: 0,
1299
+ validator(t) {
1300
+ return t >= 0;
1301
+ }
1302
+ },
1303
+ parentH: {
1304
+ type: Number,
1305
+ default: 0,
1306
+ validator(t) {
1307
+ return t >= 0;
1308
+ }
1309
+ },
1310
+ w: {
1311
+ type: [String, Number],
1312
+ default: 200,
1313
+ validator(t) {
1314
+ return typeof t == "string" ? t === "auto" : t >= 0;
1315
+ }
1316
+ },
1317
+ h: {
1318
+ type: [String, Number],
1319
+ default: 200,
1320
+ validator(t) {
1321
+ return typeof t == "string" ? t === "auto" : t >= 0;
1322
+ }
1323
+ },
1324
+ minw: {
1325
+ type: Number,
1326
+ default: 50,
1327
+ validator(t) {
1328
+ return t >= 0;
1329
+ }
1330
+ },
1331
+ minh: {
1332
+ type: Number,
1333
+ default: 50,
1334
+ validator(t) {
1335
+ return t >= 0;
1336
+ }
1337
+ },
1338
+ x: {
1339
+ type: Number,
1340
+ default: 0,
1341
+ validator(t) {
1342
+ return typeof t == "number";
1343
+ }
1344
+ },
1345
+ y: {
1346
+ type: Number,
1347
+ default: 0,
1348
+ validator(t) {
1349
+ return typeof t == "number";
1350
+ }
1351
+ },
1352
+ z: {
1353
+ type: [String, Number],
1354
+ default: "auto",
1355
+ validator(t) {
1356
+ return typeof t == "string" ? t === "auto" : t >= 0;
1357
+ }
1358
+ },
1359
+ dragHandle: {
1360
+ type: String,
1361
+ default: null
1362
+ },
1363
+ dragCancel: {
1364
+ type: String,
1365
+ default: null
1366
+ },
1367
+ sticks: {
1368
+ type: Array,
1369
+ default() {
1370
+ return ["tl", "tm", "tr", "mr", "br", "bm", "bl", "ml"];
1371
+ }
1372
+ },
1373
+ axis: {
1374
+ type: String,
1375
+ default: "both",
1376
+ validator(t) {
1377
+ return ["x", "y", "both", "none"].indexOf(t) !== -1;
1378
+ }
1379
+ },
1380
+ contentClass: {
1381
+ type: String,
1382
+ required: !1,
1383
+ default: ""
1384
+ }
1385
+ },
1386
+ data() {
1387
+ return {
1388
+ fixAspectRatio: null,
1389
+ active: null,
1390
+ zIndex: null,
1391
+ parentWidth: null,
1392
+ parentHeight: null,
1393
+ left: null,
1394
+ top: null,
1395
+ right: null,
1396
+ bottom: null,
1397
+ minHeight: null
1398
+ };
1399
+ },
1400
+ beforeCreate() {
1401
+ this.stickDrag = !1, this.bodyDrag = !1, this.dimensionsBeforeMove = { pointerX: 0, pointerY: 0, x: 0, y: 0, w: 0, h: 0 }, this.limits = {
1402
+ left: { min: null, max: null },
1403
+ right: { min: null, max: null },
1404
+ top: { min: null, max: null },
1405
+ bottom: { min: null, max: null }
1406
+ }, this.currentStick = null;
1407
+ },
1408
+ mounted() {
1409
+ this.parentElement = this.$el.parentNode, this.parentWidth = this.parentW ? this.parentW : this.parentElement.clientWidth, this.parentHeight = this.parentH ? this.parentH : this.parentElement.clientHeight, this.left = this.x, this.top = this.y, this.right = this.parentWidth - (this.w === "auto" ? this.$refs.container.scrollWidth : this.w) - this.left, this.bottom = this.parentHeight - (this.h === "auto" ? this.$refs.container.scrollHeight : this.h) - this.top, this.domEvents = /* @__PURE__ */ new Map([
1410
+ ["mousemove", this.move],
1411
+ ["mouseup", this.up],
1412
+ ["mouseleave", this.up],
1413
+ ["mousedown", this.deselect],
1414
+ ["touchmove", this.move],
1415
+ ["touchend", this.up],
1416
+ ["touchcancel", this.up],
1417
+ ["touchstart", this.up]
1418
+ ]), ge(this.domEvents), this.dragHandle && [...this.$el.querySelectorAll(this.dragHandle)].forEach((t) => {
1419
+ t.setAttribute("data-drag-handle", this._uid);
1420
+ }), this.dragCancel && [...this.$el.querySelectorAll(this.dragCancel)].forEach((t) => {
1421
+ t.setAttribute("data-drag-cancel", this._uid);
1422
+ });
1423
+ },
1424
+ beforeUnmount() {
1425
+ be(this.domEvents);
1426
+ },
1427
+ methods: {
1428
+ deselect() {
1429
+ this.preventActiveBehavior || (this.active = !1);
1430
+ },
1431
+ move(t) {
1432
+ if (!this.stickDrag && !this.bodyDrag)
1433
+ return;
1434
+ t.stopPropagation();
1435
+ const e = typeof t.pageX < "u" ? t.pageX : t.touches[0].pageX, i = typeof t.pageY < "u" ? t.pageY : t.touches[0].pageY, { dimensionsBeforeMove: r } = this, n = {
1436
+ x: (r.pointerX - e) / this.parentScaleX,
1437
+ y: (r.pointerY - i) / this.parentScaleY
1438
+ };
1439
+ if (this.stickDrag && this.stickMove(n), this.bodyDrag) {
1440
+ if (this.axis === "x")
1441
+ n.y = 0;
1442
+ else if (this.axis === "y")
1443
+ n.x = 0;
1444
+ else if (this.axis === "none")
1445
+ return;
1446
+ this.bodyMove(n);
1447
+ }
1448
+ },
1449
+ up(t) {
1450
+ this.stickDrag ? this.stickUp(t) : this.bodyDrag && this.bodyUp(t);
1451
+ },
1452
+ bodyDown(t) {
1453
+ const { target: e, button: i } = t;
1454
+ if (this.preventActiveBehavior || (this.active = !0), i && i !== 0 || (this.$emit("clicked", t), !this.active) || this.dragHandle && e.getAttribute("data-drag-handle") !== this._uid.toString() || this.dragCancel && e.getAttribute("data-drag-cancel") === this._uid.toString())
1455
+ return;
1456
+ typeof t.stopPropagation < "u" && t.stopPropagation(), typeof t.preventDefault < "u" && t.preventDefault(), this.isDraggable && (this.bodyDrag = !0);
1457
+ const r = typeof t.pageX < "u" ? t.pageX : t.touches[0].pageX, n = typeof t.pageY < "u" ? t.pageY : t.touches[0].pageY;
1458
+ this.saveDimensionsBeforeMove({ pointerX: r, pointerY: n }), this.parentLimitation && (this.limits = this.calcDragLimitation());
1459
+ },
1460
+ bodyMove(t) {
1461
+ const { dimensionsBeforeMove: e, parentWidth: i, parentHeight: r, gridX: n, gridY: s, width: l, height: o } = this;
1462
+ let c = e.top - t.y, m = e.bottom + t.y, h = e.left - t.x, d = e.right + t.x;
1463
+ if (this.snapToGrid) {
1464
+ let p = !0, k = !0, H = c - Math.floor(c / s) * s, z = r - m - Math.floor((r - m) / s) * s, $ = h - Math.floor(h / n) * n, F = i - d - Math.floor((i - d) / n) * n;
1465
+ H > s / 2 && (H -= s), z > s / 2 && (z -= s), $ > n / 2 && ($ -= n), F > n / 2 && (F -= n), Math.abs(z) < Math.abs(H) && (p = !1), Math.abs(F) < Math.abs($) && (k = !1), c -= p ? H : z, m = r - o - c, h -= k ? $ : F, d = i - l - h;
1466
+ }
1467
+ ({
1468
+ newLeft: this.left,
1469
+ newRight: this.right,
1470
+ newTop: this.top,
1471
+ newBottom: this.bottom
1472
+ } = this.rectCorrectionByLimit({ newLeft: h, newRight: d, newTop: c, newBottom: m })), this.$emit("dragging", this.rect);
1473
+ },
1474
+ bodyUp() {
1475
+ this.bodyDrag = !1, this.$emit("dragging", this.rect), this.$emit("dragstop", this.rect), this.dimensionsBeforeMove = { pointerX: 0, pointerY: 0, x: 0, y: 0, w: 0, h: 0 }, this.limits = {
1476
+ left: { min: null, max: null },
1477
+ right: { min: null, max: null },
1478
+ top: { min: null, max: null },
1479
+ bottom: { min: null, max: null }
1480
+ };
1481
+ },
1482
+ stickDown(t, e, i = !1) {
1483
+ if ((!this.isResizable || !this.active) && !i)
1484
+ return;
1485
+ this.stickDrag = !0;
1486
+ const r = typeof e.pageX < "u" ? e.pageX : e.touches[0].pageX, n = typeof e.pageY < "u" ? e.pageY : e.touches[0].pageY;
1487
+ this.saveDimensionsBeforeMove({ pointerX: r, pointerY: n }), this.currentStick = t, this.limits = this.calcResizeLimits();
1488
+ },
1489
+ saveDimensionsBeforeMove({ pointerX: t, pointerY: e }) {
1490
+ this.dimensionsBeforeMove.pointerX = t, this.dimensionsBeforeMove.pointerY = e, this.dimensionsBeforeMove.left = this.left, this.dimensionsBeforeMove.right = this.right, this.dimensionsBeforeMove.top = this.top, this.dimensionsBeforeMove.bottom = this.bottom, this.dimensionsBeforeMove.width = this.width, this.dimensionsBeforeMove.height = this.height, this.aspectFactor = this.width / this.height;
1491
+ },
1492
+ stickMove(t) {
1493
+ const {
1494
+ currentStick: e,
1495
+ dimensionsBeforeMove: i,
1496
+ gridY: r,
1497
+ gridX: n,
1498
+ snapToGrid: s,
1499
+ parentHeight: l,
1500
+ parentWidth: o
1501
+ } = this;
1502
+ let c = i.top, m = i.bottom, h = i.left, d = i.right;
1503
+ switch (e[0]) {
1504
+ case "b":
1505
+ m = i.bottom + t.y, s && (m = l - Math.round((l - m) / r) * r);
1506
+ break;
1507
+ case "t":
1508
+ c = i.top - t.y, s && (c = Math.round(c / r) * r);
1509
+ break;
1510
+ }
1511
+ switch (e[1]) {
1512
+ case "r":
1513
+ d = i.right + t.x, s && (d = o - Math.round((o - d) / n) * n);
1514
+ break;
1515
+ case "l":
1516
+ h = i.left - t.x, s && (h = Math.round(h / n) * n);
1517
+ break;
1518
+ }
1519
+ ({
1520
+ newLeft: h,
1521
+ newRight: d,
1522
+ newTop: c,
1523
+ newBottom: m
1524
+ } = this.rectCorrectionByLimit({ newLeft: h, newRight: d, newTop: c, newBottom: m })), this.aspectRatio && ({
1525
+ newLeft: h,
1526
+ newRight: d,
1527
+ newTop: c,
1528
+ newBottom: m
1529
+ } = this.rectCorrectionByAspectRatio({ newLeft: h, newRight: d, newTop: c, newBottom: m })), this.left = h, this.right = d, this.top = c, this.bottom = m, this.$emit("resizing", this.rect);
1530
+ },
1531
+ stickUp() {
1532
+ this.stickDrag = !1, this.dimensionsBeforeMove = {
1533
+ pointerX: 0,
1534
+ pointerY: 0,
1535
+ x: 0,
1536
+ y: 0,
1537
+ w: 0,
1538
+ h: 0
1539
+ }, this.limits = {
1540
+ left: { min: null, max: null },
1541
+ right: { min: null, max: null },
1542
+ top: { min: null, max: null },
1543
+ bottom: { min: null, max: null }
1544
+ }, this.$emit("resizing", this.rect), this.$emit("resizestop", this.rect);
1545
+ },
1546
+ calcDragLimitation() {
1547
+ const { parentWidth: t, parentHeight: e } = this;
1548
+ return {
1549
+ left: { min: 0, max: t - this.width },
1550
+ right: { min: 0, max: t - this.width },
1551
+ top: { min: 0, max: e - this.height },
1552
+ bottom: { min: 0, max: e - this.height }
1553
+ };
1554
+ },
1555
+ calcResizeLimits() {
1556
+ const { aspectFactor: t, width: e, height: i, bottom: r, top: n, left: s, right: l } = this;
1557
+ let { minh: o, minw: c } = this;
1558
+ const m = this.parentLimitation ? 0 : null;
1559
+ this.aspectRatio && (c / o > t ? o = c / t : c = t * o);
1560
+ const h = {
1561
+ left: { min: m, max: s + (e - c) },
1562
+ right: { min: m, max: l + (e - c) },
1563
+ top: { min: m, max: n + (i - o) },
1564
+ bottom: { min: m, max: r + (i - o) }
1565
+ };
1566
+ if (this.aspectRatio) {
1567
+ const d = {
1568
+ left: {
1569
+ min: s - Math.min(n, r) * t * 2,
1570
+ max: s + (i - o) / 2 * t * 2
1571
+ },
1572
+ right: {
1573
+ min: l - Math.min(n, r) * t * 2,
1574
+ max: l + (i - o) / 2 * t * 2
1575
+ },
1576
+ top: {
1577
+ min: n - Math.min(s, l) / t * 2,
1578
+ max: n + (e - c) / 2 / t * 2
1579
+ },
1580
+ bottom: {
1581
+ min: r - Math.min(s, l) / t * 2,
1582
+ max: r + (e - c) / 2 / t * 2
1583
+ }
1584
+ };
1585
+ this.currentStick[0] === "m" ? (h.left = {
1586
+ min: Math.max(h.left.min, d.left.min),
1587
+ max: Math.min(h.left.max, d.left.max)
1588
+ }, h.right = {
1589
+ min: Math.max(h.right.min, d.right.min),
1590
+ max: Math.min(h.right.max, d.right.max)
1591
+ }) : this.currentStick[1] === "m" && (h.top = {
1592
+ min: Math.max(h.top.min, d.top.min),
1593
+ max: Math.min(h.top.max, d.top.max)
1594
+ }, h.bottom = {
1595
+ min: Math.max(h.bottom.min, d.bottom.min),
1596
+ max: Math.min(h.bottom.max, d.bottom.max)
1597
+ });
1598
+ }
1599
+ return h;
1600
+ },
1601
+ sideCorrectionByLimit(t, e) {
1602
+ let i = e;
1603
+ return t.min !== null && e < t.min ? i = t.min : t.max !== null && t.max < e && (i = t.max), i;
1604
+ },
1605
+ rectCorrectionByLimit(t) {
1606
+ const { limits: e } = this;
1607
+ let { newRight: i, newLeft: r, newBottom: n, newTop: s } = t;
1608
+ return r = this.sideCorrectionByLimit(e.left, r), i = this.sideCorrectionByLimit(e.right, i), s = this.sideCorrectionByLimit(e.top, s), n = this.sideCorrectionByLimit(e.bottom, n), {
1609
+ newLeft: r,
1610
+ newRight: i,
1611
+ newTop: s,
1612
+ newBottom: n
1613
+ };
1614
+ },
1615
+ rectCorrectionByAspectRatio(t) {
1616
+ let { newLeft: e, newRight: i, newTop: r, newBottom: n } = t;
1617
+ const { parentWidth: s, parentHeight: l, currentStick: o, aspectFactor: c, dimensionsBeforeMove: m } = this;
1618
+ let h = s - e - i, d = l - r - n;
1619
+ if (o[1] === "m") {
1620
+ const p = d - m.height;
1621
+ e -= p * c / 2, i -= p * c / 2;
1622
+ } else if (o[0] === "m") {
1623
+ const p = h - m.width;
1624
+ r -= p / c / 2, n -= p / c / 2;
1625
+ } else
1626
+ h / d > c ? (h = c * d, o[1] === "l" ? e = s - i - h : i = s - e - h) : (d = h / c, o[0] === "t" ? r = l - n - d : n = l - r - d);
1627
+ return { newLeft: e, newRight: i, newTop: r, newBottom: n };
1628
+ }
1629
+ },
1630
+ computed: {
1631
+ positionStyle() {
1632
+ return {
1633
+ top: this.top + "px",
1634
+ left: this.left + "px",
1635
+ zIndex: this.zIndex
1636
+ };
1637
+ },
1638
+ sizeStyle() {
1639
+ return {
1640
+ width: this.width + "px",
1641
+ height: this.height + "px"
1642
+ };
1643
+ },
1644
+ vdrStick() {
1645
+ return (t) => {
1646
+ const e = {
1647
+ width: `${this.stickSize / this.parentScaleX}px`,
1648
+ height: `${this.stickSize / this.parentScaleY}px`
1649
+ };
1650
+ return e[D.y[t[0]]] = `${this.stickSize / this.parentScaleX / -2}px`, e[D.x[t[1]]] = `${this.stickSize / this.parentScaleX / -2}px`, e;
1651
+ };
1652
+ },
1653
+ width() {
1654
+ return this.parentWidth - this.left - this.right;
1655
+ },
1656
+ height() {
1657
+ return this.parentHeight - this.top - this.bottom;
1658
+ },
1659
+ rect() {
1660
+ return {
1661
+ left: Math.round(this.left),
1662
+ top: Math.round(this.top),
1663
+ width: Math.round(this.width),
1664
+ height: Math.round(this.height)
1665
+ };
1666
+ }
1667
+ },
1668
+ watch: {
1669
+ active(t) {
1670
+ t ? this.$emit("activated") : this.$emit("deactivated");
1671
+ },
1672
+ isActive: {
1673
+ immediate: !0,
1674
+ handler(t) {
1675
+ this.active = t;
1676
+ }
1677
+ },
1678
+ z: {
1679
+ immediate: !0,
1680
+ handler(t) {
1681
+ (t >= 0 || t === "auto") && (this.zIndex = t);
1682
+ }
1683
+ },
1684
+ x: {
1685
+ handler(t, e) {
1686
+ if (this.stickDrag || this.bodyDrag || t === this.left)
1687
+ return;
1688
+ const i = e - t;
1689
+ this.bodyDown({ pageX: this.left, pageY: this.top }), this.bodyMove({ x: i, y: 0 }), this.$nextTick(() => {
1690
+ this.bodyUp();
1691
+ });
1692
+ }
1693
+ },
1694
+ y: {
1695
+ handler(t, e) {
1696
+ if (this.stickDrag || this.bodyDrag || t === this.top)
1697
+ return;
1698
+ const i = e - t;
1699
+ this.bodyDown({ pageX: this.left, pageY: this.top }), this.bodyMove({ x: 0, y: i }), this.$nextTick(() => {
1700
+ this.bodyUp();
1701
+ });
1702
+ }
1703
+ },
1704
+ w: {
1705
+ handler(t, e) {
1706
+ if (this.stickDrag || this.bodyDrag || t === this.width)
1707
+ return;
1708
+ const i = "mr", r = e - t;
1709
+ this.stickDown(i, { pageX: this.right, pageY: this.top + this.height / 2 }, !0), this.stickMove({ x: r, y: 0 }), this.$nextTick(() => {
1710
+ this.stickUp();
1711
+ });
1712
+ }
1713
+ },
1714
+ h: {
1715
+ handler(t, e) {
1716
+ if (this.stickDrag || this.bodyDrag || t === this.height)
1717
+ return;
1718
+ const i = "bm", r = e - t;
1719
+ this.stickDown(i, { pageX: this.left + this.width / 2, pageY: this.bottom }, !0), this.stickMove({ x: 0, y: r }), this.$nextTick(() => {
1720
+ this.stickUp();
1721
+ });
1722
+ }
1723
+ },
1724
+ parentW(t) {
1725
+ this.right = t - this.width - this.left, this.parentWidth = t;
1726
+ },
1727
+ parentH(t) {
1728
+ this.bottom = t - this.height - this.top, this.parentHeight = t;
1729
+ }
1730
+ }
1731
+ }, ke = ["onMousedown", "onTouchstart"];
1732
+ function ye(t, e, i, r, n, s) {
1733
+ return a(), u("div", {
1734
+ class: w(["vdr", `${n.active || i.isActive ? "active" : "inactive"} ${i.contentClass ? i.contentClass : ""}`]),
1735
+ style: B(s.positionStyle),
1736
+ onMousedown: e[0] || (e[0] = (l) => s.bodyDown(l)),
1737
+ onTouchstart: e[1] || (e[1] = (l) => s.bodyDown(l)),
1738
+ onTouchend: e[2] || (e[2] = (l) => s.up(l)),
1739
+ ref: "container",
1740
+ tabindex: "0"
1741
+ }, [
1742
+ f("div", {
1743
+ style: B(s.sizeStyle),
1744
+ class: "content-container",
1745
+ ref: "container2"
1746
+ }, [
1747
+ j(t.$slots, "default")
1748
+ ], 4),
1749
+ (a(!0), u(y, null, M(i.sticks, (l) => (a(), u("div", {
1750
+ class: w(["vdr-stick", ["vdr-stick-" + l, i.isResizable ? "" : "not-resizable"]]),
1751
+ onMousedown: A((o) => s.stickDown(l, o), ["stop", "prevent"]),
1752
+ onTouchstart: A((o) => s.stickDown(l, o), ["stop", "prevent"]),
1753
+ style: B(s.vdrStick(l))
1754
+ }, null, 46, ke))), 256))
1755
+ ], 38);
1756
+ }
1757
+ const E = /* @__PURE__ */ C(_e, [["render", ye]]);
1758
+ const we = {
1759
+ components: {
1760
+ VueDragResize: E
1761
+ },
1762
+ props: ["content"],
1763
+ data() {
1764
+ return {};
1765
+ },
1766
+ watch: {},
1767
+ computed: {
1768
+ getLastPage() {
1769
+ return !!this.$store.getters.getLastPage;
1770
+ }
1771
+ },
1772
+ methods: {
1773
+ onResizstop(t) {
1774
+ console.log("i have stopped resizing", t);
1775
+ },
1776
+ onDragstop(t) {
1777
+ },
1778
+ reset() {
1779
+ this.listOne = [];
1780
+ },
1781
+ getParentWidth() {
1782
+ let t = document.getElementsByClassName("fridgemagnet");
1783
+ setTimeout(() => t[0].offsetWidth);
1784
+ },
1785
+ getParentHeight() {
1786
+ let t = document.getElementsByClassName("fridgemagnet");
1787
+ setTimeout(() => t[0].offsetHeight);
1788
+ },
1789
+ keyboardMove(t) {
1790
+ for (let e of t)
1791
+ document.getElementById(e.id).addEventListener("focusin", (r) => {
1792
+ let n = document.getElementsByClassName("fridgemagnet");
1793
+ addEventListener("keydown", function(s) {
1794
+ let l = document.getElementById(s.target.id);
1795
+ if (s.altKey && s.key === "ArrowLeft") {
1796
+ let o = Number(l.style.left.slice(0, -2));
1797
+ o - 10 < 0 ? l.style.left = `${o}px` : l.style.left = `${o - 10}px`;
1798
+ }
1799
+ if (s.altKey && s.key === "ArrowRight") {
1800
+ let o = Number(l.style.left.slice(0, -2));
1801
+ o + 10 > n[0].offsetWidth - 50 ? l.style.left = `${o}px` : l.style.left = `${o + 10}px`;
1802
+ }
1803
+ if (s.altKey && s.key === "ArrowUp") {
1804
+ let o = Number(l.style.top.slice(0, -2));
1805
+ o + 10 < 0 ? l.style.top = `${o}px` : l.style.top = `${o - 10}px`;
1806
+ }
1807
+ if (s.altKey && s.key === "ArrowDown") {
1808
+ let o = Number(l.style.top.slice(0, -2));
1809
+ o + 10 > n[0].offsetHeight - 80 ? l.style.top = `${o}px` : l.style.top = `${o + 10}px`;
1810
+ }
1811
+ });
1812
+ });
1813
+ }
1814
+ },
1815
+ mounted() {
1816
+ let t = document.getElementsByClassName("vdr");
1817
+ setTimeout(() => {
1818
+ t[0].focus();
1819
+ }), this.keyboardMove(t);
1820
+ },
1821
+ beforeMount() {
1822
+ }
1823
+ }, ve = { class: "fridgemagnet" }, xe = ["innerHTML"], Ce = ["src", "alt"], Se = ["id", "src", "alt"], Ae = ["innerHTML"];
1824
+ function Me(t, e, i, r, n, s) {
1825
+ const l = g("VueDragResize");
1826
+ return a(), u("div", ve, [
1827
+ i.content.directions ? (a(), u("p", {
1828
+ key: 0,
1829
+ innerHTML: i.content.directions
1830
+ }, null, 8, xe)) : b("", !0),
1831
+ f("img", {
1832
+ src: i.content.image,
1833
+ alt: i.content.imageAlt
1834
+ }, null, 8, Ce),
1835
+ f("div", {
1836
+ class: w(["fridge", i.content.class, i.content.noOutline ? "no_outline" : ""])
1837
+ }, [
1838
+ (a(!0), u(y, null, M(i.content.magnets, (o, c) => (a(), v(l, {
1839
+ id: "vdr_" + c,
1840
+ isActive: !0,
1841
+ w: o.width ? o.width : 50,
1842
+ minw: o.minWidth ? o.minWidth : 50,
1843
+ h: o.height ? o.height : 50,
1844
+ minh: o.minHeight ? o.minHeight : 50,
1845
+ x: o.x ? o.x : 0,
1846
+ y: o.y ? o.y : 60 * c,
1847
+ class: w(o.class),
1848
+ parentLimitation: !0,
1849
+ parentW: o.parentwidth ? o.parentwidth : s.getParentWidth(),
1850
+ parentH: o.parentheight ? o.parentheight : s.getParentHeight(),
1851
+ isResizable: o.resizable,
1852
+ isDraggable: o.draggable,
1853
+ snapToGrid: o.snap,
1854
+ gridX: o.snapX,
1855
+ gridY: o.snapY,
1856
+ dragHandle: o.handle,
1857
+ onResizing: t.resize,
1858
+ onDragging: t.resize,
1859
+ aspectRatio: !0,
1860
+ onResizestop: s.onResizstop,
1861
+ onDragstop: s.onDragstop,
1862
+ sticks: ["tl", "bl", "tr", "br"]
1863
+ }, {
1864
+ default: _(() => [
1865
+ o.image ? (a(), u("img", {
1866
+ key: 0,
1867
+ id: o.index,
1868
+ src: o.image,
1869
+ alt: o.imageAlt
1870
+ }, null, 8, Se)) : b("", !0),
1871
+ o.text ? (a(), u("p", {
1872
+ key: 1,
1873
+ innerHTML: o.text
1874
+ }, null, 8, Ae)) : b("", !0)
1875
+ ]),
1876
+ _: 2
1877
+ }, 1032, ["id", "w", "minw", "h", "minh", "x", "y", "class", "parentW", "parentH", "isResizable", "isDraggable", "snapToGrid", "gridX", "gridY", "dragHandle", "onResizing", "onDragging", "onResizestop", "onDragstop"]))), 256))
1878
+ ], 2)
1879
+ ]);
1880
+ }
1881
+ const Te = /* @__PURE__ */ C(we, [["render", Me]]), Be = {
1882
+ install: (t, e) => {
1883
+ t.component("special-uploader", X), t.component("lab-header", K), t.component("lab-footer", L), t.component("lab-drawer", L), t.component("lab-image", rt), t.component("lab-kaltura", gt), t.component("lab-image-marker", Ft), t.component("lab-image-replacer", Ot), t.component("lab-feedback", I), t.component("lab-drop-down", qt), t.component("lab-fill-blank", Nt), t.component("lab-selectable", Jt), t.component("lab-textbox", ee), t.component("lab-menu_chooser", pe), t.component("lab-drag-resize", E), t.component("lab-fridgemagnet", Te);
1218
1884
  }
1219
1885
  };
1220
1886
  export {
1221
- mt as default
1887
+ Be as default
1222
1888
  };