@genpact/genome.mfe.mgtwin-app 1.1.274-alpha → 1.1.275-alpha
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/{ArrowLeftCircleIcon-ffddab7d.mjs → ArrowLeftCircleIcon-45250164.mjs} +1 -1
- package/dist/{AssessmentAMA-21b621e7.mjs → AssessmentAMA-faec09a0.mjs} +156 -156
- package/dist/{AssessmentSimulation-ca8ca5d8.mjs → AssessmentSimulation-772d1728.mjs} +5 -5
- package/dist/{EditSkillAdminData-1726697e.mjs → EditSkillAdminData-2d3ea527.mjs} +3 -3
- package/dist/{EditSkillData-edb14ff1.mjs → EditSkillData-d508c679.mjs} +3 -3
- package/dist/{HomeView-f309f686.mjs → HomeView-1e1113f5.mjs} +5 -5
- package/dist/{Loading-716fe740.mjs → Loading-000fa163.mjs} +1 -1
- package/dist/{LoadingSimulation-f9c181b5.mjs → LoadingSimulation-fcfccc93.mjs} +1 -1
- package/dist/{Modal-4710961f.mjs → Modal-1645738a.mjs} +1 -1
- package/dist/{PromptTesting-76c55d6f.mjs → PromptTesting-ede8ab87.mjs} +2 -2
- package/dist/{SkillAutomation-cfe4d86f.mjs → SkillAutomation-38a40c13.mjs} +3 -3
- package/dist/{SkillData-c38cd50b.mjs → SkillData-379df161.mjs} +3 -3
- package/dist/{UnderMaintenance-2b672baf.mjs → UnderMaintenance-de3dea98.mjs} +1 -1
- package/dist/{_commonjsHelpers-a50ade8d.mjs → _commonjsHelpers-fb050ae5.mjs} +1 -1
- package/dist/{api-18477be4.mjs → api-4d088800.mjs} +1 -1
- package/dist/{main-01ec390d.mjs → main-276ff0ff.mjs} +1027 -1027
- package/dist/mgtwin.es.min.js +1 -1
- package/dist/mgtwin.umd.min.js +10 -10
- package/dist/style.css +1 -1
- package/package.json +1 -1
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { _ as _e, a as he, L as ge } from "./LoadingSimulation-
|
|
2
|
-
import { _ as fe, Q as U, a as ve } from "./Modal-
|
|
3
|
-
import { d as M, r as d, H as
|
|
1
|
+
import { _ as _e, a as he, L as ge } from "./LoadingSimulation-fcfccc93.mjs";
|
|
2
|
+
import { _ as fe, Q as U, a as ve } from "./Modal-1645738a.mjs";
|
|
3
|
+
import { d as M, r as d, H as V, o as u, c as m, a as e, u as C, y as D, t as B, G as ye, p as H, g as z, C as O, z as xe, K as we, h as q, F as Ae, e as be, f as Q, b as S, k as ue, w as $e, m as ke, L as qe, q as T, s as Me, l as Ie } from "./main-276ff0ff.mjs";
|
|
4
4
|
import { _ as R } from "./_plugin-vue_export-helper-dad06003.mjs";
|
|
5
|
-
import { p as ie, g as de } from "./api-
|
|
5
|
+
import { p as ie, g as de } from "./api-4d088800.mjs";
|
|
6
6
|
import "./loadernew-ac153a51.mjs";
|
|
7
|
-
const Se = { class: "flex h-14 w-full flex-1 items-center justify-between bg-[#021c42] md:pr-6 lg:pr-6" }, Le = ["href"], Ee = /* @__PURE__ */
|
|
7
|
+
const Se = { class: "flex h-14 w-full flex-1 items-center justify-between bg-[#021c42] md:pr-6 lg:pr-6" }, Le = ["href"], Ee = /* @__PURE__ */ e("img", {
|
|
8
8
|
class: "h-11 w-auto cursor-pointer",
|
|
9
9
|
src: _e,
|
|
10
10
|
alt: "Genome Logo"
|
|
11
11
|
}, null, -1), Fe = [
|
|
12
12
|
Ee
|
|
13
|
-
], Te = ["href"], Re = /* @__PURE__ */
|
|
13
|
+
], Te = ["href"], Re = /* @__PURE__ */ e("img", {
|
|
14
14
|
class: "h-9 w-28 cursor-pointer md:w-36",
|
|
15
15
|
src: fe,
|
|
16
16
|
alt: "Aiguru Logo"
|
|
@@ -18,33 +18,33 @@ const Se = { class: "flex h-14 w-full flex-1 items-center justify-between bg-[#0
|
|
|
18
18
|
Re
|
|
19
19
|
], Be = /* @__PURE__ */ M({
|
|
20
20
|
__name: "headerAMA",
|
|
21
|
-
setup(
|
|
22
|
-
const
|
|
23
|
-
return
|
|
24
|
-
|
|
21
|
+
setup(r) {
|
|
22
|
+
const t = d(""), l = d("");
|
|
23
|
+
return V === "prod" ? t.value = "https://genome.genpact.com" : t.value = "https://genome-dev.genpact.com", V === "prod" ? l.value = "https://genome.genpact.com/#aiguru" : l.value = "https://genome-dev.genpact.com/#aiguru", (a, i) => (u(), m("nav", Se, [
|
|
24
|
+
e("a", {
|
|
25
25
|
class: "px-2 md:px-0 lg:px-0",
|
|
26
|
-
href:
|
|
26
|
+
href: t.value,
|
|
27
27
|
target: "_blank"
|
|
28
28
|
}, Fe, 8, Le),
|
|
29
|
-
|
|
29
|
+
e("a", {
|
|
30
30
|
class: "px-2 md:px-0 lg:px-0",
|
|
31
|
-
href:
|
|
31
|
+
href: l.value,
|
|
32
32
|
target: "_blank"
|
|
33
33
|
}, Ne, 8, Te)
|
|
34
34
|
]));
|
|
35
35
|
}
|
|
36
|
-
}), Ce = { class: "flex items-end justify-start" },
|
|
36
|
+
}), Ce = { class: "flex items-end justify-start" }, Pe = { class: "fontFormattingAMA w-full bg-gray-100 rounded-lg" }, je = { class: "w-full rounded-md px-3 py-2 text-lg font-bold text-black text-[18px] md:text-[22px]" }, Ue = { class: "w-full px-3 py-2 text-base text-black text-[12px] md:text-[16px] font-[550]" }, Qe = /* @__PURE__ */ e("br", null, null, -1), Ve = /* @__PURE__ */ M({
|
|
37
37
|
__name: "greetingsAMA",
|
|
38
|
-
setup(
|
|
39
|
-
const
|
|
40
|
-
return (w,
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
38
|
+
setup(r) {
|
|
39
|
+
const t = C(), l = ` Hi ${t.learnerName || "Expert"}, and welcome!`, a = D(() => l), i = D(() => t.welcomeMessage);
|
|
40
|
+
return (w, y) => (u(), m("section", null, [
|
|
41
|
+
e("div", Ce, [
|
|
42
|
+
e("div", Pe, [
|
|
43
|
+
e("div", je, B(a.value), 1),
|
|
44
|
+
e("div", Ue, B(i.value), 1)
|
|
45
45
|
])
|
|
46
46
|
]),
|
|
47
|
-
|
|
47
|
+
Qe
|
|
48
48
|
]));
|
|
49
49
|
}
|
|
50
50
|
}), De = { class: "fontFormattingAMA flex items-end justify-start py-2" }, He = { class: "line-break w-full bg-gray-100 p-3 text-sm text-black md:text-[15px] rounded-lg" }, ze = ["innerHTML"], Oe = /* @__PURE__ */ M({
|
|
@@ -55,19 +55,19 @@ const Se = { class: "flex h-14 w-full flex-1 items-center justify-between bg-[#0
|
|
|
55
55
|
required: !0
|
|
56
56
|
}
|
|
57
57
|
},
|
|
58
|
-
setup(
|
|
59
|
-
const
|
|
60
|
-
const
|
|
58
|
+
setup(r) {
|
|
59
|
+
const t = r, l = D(() => {
|
|
60
|
+
const a = t.answer.replace(/[*#]/g, "").replace(
|
|
61
61
|
/Assessment Rating & Feedback/g,
|
|
62
62
|
'<div style="font-size: 26px; font-weight: bold; text-decoration: underline;">Rating & Feedback</div>'
|
|
63
63
|
), i = /\[([^\]]+)\]\((https?:\/\/[^\s]+)\)/g;
|
|
64
|
-
return
|
|
64
|
+
return a.replace(i, (w, y, c) => `<a href="${c}" target="_blank" rel="noopener noreferrer" style="color: blue; text-decoration: underline;">${y}</a>`);
|
|
65
65
|
});
|
|
66
|
-
return (
|
|
67
|
-
|
|
68
|
-
|
|
66
|
+
return (a, i) => (u(), m("div", De, [
|
|
67
|
+
e("div", He, [
|
|
68
|
+
e("span", {
|
|
69
69
|
class: "fontFormattingAMA",
|
|
70
|
-
innerHTML:
|
|
70
|
+
innerHTML: l.value
|
|
71
71
|
}, null, 8, ze)
|
|
72
72
|
])
|
|
73
73
|
]));
|
|
@@ -81,21 +81,21 @@ const Ge = /* @__PURE__ */ R(Oe, [["__scopeId", "data-v-ebd005b7"]]), Ke = { cla
|
|
|
81
81
|
required: !0
|
|
82
82
|
}
|
|
83
83
|
},
|
|
84
|
-
setup(
|
|
85
|
-
return (
|
|
86
|
-
|
|
87
|
-
|
|
84
|
+
setup(r) {
|
|
85
|
+
return (t, l) => (u(), m("div", Ke, [
|
|
86
|
+
e("div", We, [
|
|
87
|
+
e("div", Ye, B(r.question), 1)
|
|
88
88
|
])
|
|
89
89
|
]));
|
|
90
90
|
}
|
|
91
|
-
}), Je = (
|
|
92
|
-
/* @__PURE__ */
|
|
93
|
-
/* @__PURE__ */
|
|
94
|
-
/* @__PURE__ */
|
|
95
|
-
], -1)), as = /* @__PURE__ */
|
|
91
|
+
}), Je = (r) => (H("data-v-12a02acf"), r = r(), z(), r), Xe = { class: "flex w-full flex-col items-start justify-start bg-white" }, es = { class: "bot-typing-animation gap-1" }, ss = { class: "block w-full text-lg italic text-gray-800" }, ts = /* @__PURE__ */ Je(() => /* @__PURE__ */ e("span", { class: "dot-animation" }, [
|
|
92
|
+
/* @__PURE__ */ e("span", null, "."),
|
|
93
|
+
/* @__PURE__ */ e("span", null, "."),
|
|
94
|
+
/* @__PURE__ */ e("span", null, ".")
|
|
95
|
+
], -1)), as = /* @__PURE__ */ ye('<div class="block w-full max-w-full items-stretch" data-v-12a02acf><div class="flex animate-pulse items-start justify-start space-x-4" data-v-12a02acf><div class="flex-1 space-y-6 py-1" data-v-12a02acf><div class="h-2 w-full rounded bg-gray-300" data-v-12a02acf></div><div class="space-y-3" data-v-12a02acf><div class="grid grid-cols-3 gap-4" data-v-12a02acf><div class="col-span-2 h-2 rounded bg-gray-300" data-v-12a02acf></div><div class="col-span-1 h-2 rounded bg-gray-300" data-v-12a02acf></div></div><div class="h-2 rounded bg-gray-300" data-v-12a02acf></div></div></div></div></div>', 1), os = /* @__PURE__ */ M({
|
|
96
96
|
__name: "LoadingResponseAMA",
|
|
97
|
-
setup(
|
|
98
|
-
const
|
|
97
|
+
setup(r) {
|
|
98
|
+
const t = d("Generating response"), l = d([
|
|
99
99
|
"This may take a few seconds",
|
|
100
100
|
"Fetching the best response for you",
|
|
101
101
|
"Thinking... give me a moment",
|
|
@@ -105,46 +105,46 @@ const Ge = /* @__PURE__ */ R(Oe, [["__scopeId", "data-v-ebd005b7"]]), Ke = { cla
|
|
|
105
105
|
"Compiling a response for you"
|
|
106
106
|
]);
|
|
107
107
|
return setTimeout(() => {
|
|
108
|
-
const
|
|
109
|
-
|
|
110
|
-
}, 15e3), (
|
|
111
|
-
|
|
112
|
-
|
|
108
|
+
const a = Math.floor(Math.random() * l.value.length);
|
|
109
|
+
t.value = l.value[a];
|
|
110
|
+
}, 15e3), (a, i) => (u(), m("div", Xe, [
|
|
111
|
+
e("div", es, [
|
|
112
|
+
e("div", ss, B(t.value), 1),
|
|
113
113
|
ts
|
|
114
114
|
]),
|
|
115
115
|
as
|
|
116
116
|
]));
|
|
117
117
|
}
|
|
118
118
|
});
|
|
119
|
-
const ns = /* @__PURE__ */ R(os, [["__scopeId", "data-v-12a02acf"]]),
|
|
119
|
+
const ns = /* @__PURE__ */ R(os, [["__scopeId", "data-v-12a02acf"]]), rs = { key: 0 }, ls = { key: 1 }, cs = {
|
|
120
120
|
key: 0,
|
|
121
121
|
class: "flex"
|
|
122
122
|
}, is = /* @__PURE__ */ M({
|
|
123
123
|
__name: "conversationAMA",
|
|
124
|
-
setup(
|
|
125
|
-
let
|
|
126
|
-
|
|
127
|
-
const
|
|
124
|
+
setup(r) {
|
|
125
|
+
let t = d(""), l = d("");
|
|
126
|
+
t.value = '<a style="color:#00AECF;"', l.value = '<ul style="list-style: disc !important; margin-left: 3.5rem !important; padding: 0;"';
|
|
127
|
+
const a = C(), i = d(), w = () => {
|
|
128
128
|
i.value.scrollTo(0, i.value.scrollHeight);
|
|
129
129
|
};
|
|
130
130
|
return O(() => {
|
|
131
131
|
var o;
|
|
132
|
-
const
|
|
133
|
-
console.log("New array===>", c),
|
|
134
|
-
}),
|
|
132
|
+
const y = document.getElementsByName("askQuestion"), c = Array.from(y);
|
|
133
|
+
console.log("New array===>", c), y.length && ((o = c == null ? void 0 : c.pop()) == null || o.scrollIntoView({ behavior: "smooth", block: "center" })), window.addEventListener("custom-event", w);
|
|
134
|
+
}), xe(() => {
|
|
135
135
|
var o;
|
|
136
|
-
const
|
|
137
|
-
console.log("New array===>", c),
|
|
136
|
+
const y = document.getElementsByName("askQuestion"), c = Array.from(y);
|
|
137
|
+
console.log("New array===>", c), y.length && ((o = c == null ? void 0 : c.pop()) == null || o.scrollIntoView({ behavior: "smooth", block: "center" }));
|
|
138
138
|
}), we(() => {
|
|
139
139
|
window.removeEventListener("custom-event", w);
|
|
140
|
-
}), (
|
|
140
|
+
}), (y, c) => (u(), m("div", {
|
|
141
141
|
ref_key: "nestedElement",
|
|
142
142
|
ref: i,
|
|
143
143
|
class: "smooth-scroll overflow-auto md:px-6 px-2"
|
|
144
144
|
}, [
|
|
145
|
-
q(
|
|
146
|
-
(u(!0), m(Ae, null, be(
|
|
147
|
-
o.question ? (u(), m("div",
|
|
145
|
+
q(Ve),
|
|
146
|
+
(u(!0), m(Ae, null, be(S(a).conversations, (o, A) => (u(), m("div", { key: A }, [
|
|
147
|
+
o.question ? (u(), m("div", rs, [
|
|
148
148
|
q(Ze, {
|
|
149
149
|
question: o.question,
|
|
150
150
|
c2question: o.c2question,
|
|
@@ -153,121 +153,121 @@ const ns = /* @__PURE__ */ R(os, [["__scopeId", "data-v-12a02acf"]]), ls = { key
|
|
|
153
153
|
name: "askQuestion",
|
|
154
154
|
"que-id": A
|
|
155
155
|
}, null, 8, ["question", "c2question", "show-feedback", "id", "que-id"])
|
|
156
|
-
])) :
|
|
157
|
-
o.answer ? (u(), m("div",
|
|
156
|
+
])) : Q("", !0),
|
|
157
|
+
o.answer ? (u(), m("div", ls, [
|
|
158
158
|
q(Ge, {
|
|
159
159
|
question: o == null ? void 0 : o.question,
|
|
160
160
|
c2question: o == null ? void 0 : o.c2question,
|
|
161
161
|
"show-sources": o == null ? void 0 : o.showSources,
|
|
162
162
|
questionId: o.id,
|
|
163
|
-
answer: o.answer.replaceAll("<a",
|
|
163
|
+
answer: o.answer.replaceAll("<a", S(t)).replaceAll("<ul", S(l)),
|
|
164
164
|
"show-feedback": o.showFeedback,
|
|
165
165
|
"related-ques": o.relatedQues,
|
|
166
166
|
"options-array": o.optionsArray,
|
|
167
167
|
"ans-id": A,
|
|
168
168
|
onCharTyped: w
|
|
169
169
|
}, null, 8, ["question", "c2question", "show-sources", "questionId", "answer", "show-feedback", "related-ques", "options-array", "ans-id"])
|
|
170
|
-
])) :
|
|
170
|
+
])) : Q("", !0)
|
|
171
171
|
]))), 128)),
|
|
172
|
-
|
|
172
|
+
S(a).dotLoader ? (u(), m("div", cs, [
|
|
173
173
|
q(ns)
|
|
174
|
-
])) :
|
|
174
|
+
])) : Q("", !0)
|
|
175
175
|
], 512));
|
|
176
176
|
}
|
|
177
177
|
});
|
|
178
|
-
const ds = /* @__PURE__ */ R(is, [["__scopeId", "data-v-f92feaf3"]]),
|
|
178
|
+
const ds = /* @__PURE__ */ R(is, [["__scopeId", "data-v-f92feaf3"]]), P = (r) => (H("data-v-7eef4de2"), r = r(), z(), r), us = { class: "z-3 absolute bottom-0 mt-4 w-full bg-white px-2 md:px-6" }, ps = { class: "py-2" }, ms = { class: "flex" }, _s = { class: "z-1 relative w-full" }, hs = { class: "relative w-full" }, gs = { class: "absolute inset-y-0 right-0 flex items-center md:pr-8 pr-3" }, fs = { key: 0 }, vs = /* @__PURE__ */ P(() => /* @__PURE__ */ e("path", { d: "M15.854.146a.5.5 0 0 1 .11.54l-5.819 14.547a.75.75 0 0 1-1.329.124l-3.178-4.995L.643 7.184a.75.75 0 0 1 .124-1.33L15.314.037a.5.5 0 0 1 .54.11ZM6.636 10.07l2.761 4.338L14.13 2.576 6.636 10.07Zm6.787-8.201L1.591 6.602l4.339 2.76 7.494-7.493Z" }, null, -1)), ys = [
|
|
179
179
|
vs
|
|
180
|
-
],
|
|
180
|
+
], xs = {
|
|
181
181
|
key: 1,
|
|
182
182
|
class: "tooltip"
|
|
183
|
-
}, ws = /* @__PURE__ */
|
|
183
|
+
}, ws = /* @__PURE__ */ P(() => /* @__PURE__ */ e("span", { class: "tooltiptext fontFormattingAMA" }, "Waiting for response", -1)), As = /* @__PURE__ */ P(() => /* @__PURE__ */ e("img", {
|
|
184
184
|
class: "w-7 h-7",
|
|
185
185
|
src: he,
|
|
186
186
|
alt: "watingIcon"
|
|
187
187
|
}, null, -1)), bs = [
|
|
188
188
|
ws,
|
|
189
189
|
As
|
|
190
|
-
], $s = { class: "flex justify-start gap-2 md:gap-1" }, ks = /* @__PURE__ */
|
|
191
|
-
/* @__PURE__ */
|
|
192
|
-
/* @__PURE__ */
|
|
190
|
+
], $s = { class: "flex justify-start gap-2 md:gap-1" }, ks = /* @__PURE__ */ P(() => /* @__PURE__ */ e("div", { class: "pt-1 text-start font-sans" }, [
|
|
191
|
+
/* @__PURE__ */ e("div", { class: "flex justify-start items-start text-[#161916] italic" }, " 10 questions remaining for the day "),
|
|
192
|
+
/* @__PURE__ */ e("div", { class: "text-xs font-bold text-gray-500 md:text-sm" }, " Note: AI-generated response may not be fully accurate; check with experts for critical information. ")
|
|
193
193
|
], -1)), qs = /* @__PURE__ */ M({
|
|
194
194
|
__name: "NewQuestionAMA",
|
|
195
|
-
setup(
|
|
196
|
-
const
|
|
197
|
-
|
|
198
|
-
const i = d(null), w = d(!1),
|
|
195
|
+
setup(r) {
|
|
196
|
+
const t = C(), l = ue(), a = d("");
|
|
197
|
+
t.question = "";
|
|
198
|
+
const i = d(null), w = d(!1), y = d(U), c = d(!1);
|
|
199
199
|
O(() => {
|
|
200
200
|
i.value.focus();
|
|
201
201
|
});
|
|
202
|
-
const o = ($) => new URLSearchParams(window.location.search).get($) || "", A = d(o("amaId")), K = d(o("corpusId")),
|
|
202
|
+
const o = ($) => new URLSearchParams(window.location.search).get($) || "", A = d(o("amaId")), K = d(o("corpusId")), I = ($) => {
|
|
203
203
|
const p = $.length;
|
|
204
|
-
|
|
204
|
+
y.value = U - p, w.value = p >= U;
|
|
205
205
|
}, N = async () => {
|
|
206
|
-
var $, p, k,
|
|
206
|
+
var $, p, k, f, x, b;
|
|
207
207
|
try {
|
|
208
|
-
if (
|
|
208
|
+
if (t.question.trim().length < 1) {
|
|
209
209
|
console.log("Please enter answer!");
|
|
210
210
|
return;
|
|
211
211
|
}
|
|
212
|
-
c.value = !0,
|
|
212
|
+
c.value = !0, t.dotLoader = !0;
|
|
213
213
|
const _ = {
|
|
214
|
-
question:
|
|
214
|
+
question: t.question
|
|
215
215
|
};
|
|
216
|
-
console.log("ques", _),
|
|
217
|
-
const
|
|
218
|
-
|
|
216
|
+
console.log("ques", _), t.conversations.push(_);
|
|
217
|
+
const v = d("");
|
|
218
|
+
v.value = t.question, t.question = "";
|
|
219
219
|
const n = {
|
|
220
220
|
amaId: A.value,
|
|
221
221
|
amaCorpusId: K.value,
|
|
222
|
-
past_messages:
|
|
223
|
-
question:
|
|
224
|
-
prompt:
|
|
222
|
+
past_messages: t.past_messages,
|
|
223
|
+
question: v.value,
|
|
224
|
+
prompt: t.generatedPrompt
|
|
225
225
|
}, h = await ie("/amaBotResponse", n);
|
|
226
226
|
if (((p = ($ = h == null ? void 0 : h.data) == null ? void 0 : $.body) == null ? void 0 : p.answer) === "") {
|
|
227
227
|
console.log("in the if case calling api again");
|
|
228
228
|
const g = await ie("/amaBotResponse", n);
|
|
229
|
-
|
|
229
|
+
t.addConversation((k = g.data) == null ? void 0 : k.body, "new");
|
|
230
230
|
} else
|
|
231
|
-
console.log("in the else case"),
|
|
232
|
-
console.log("ohr id asdf",
|
|
231
|
+
console.log("in the else case"), t.addConversation((f = h.data) == null ? void 0 : f.body, "new");
|
|
232
|
+
console.log("ohr id asdf", a.value), c.value = !1, t.dotLoader = !1;
|
|
233
233
|
} catch (_) {
|
|
234
|
-
if (console.error(_),
|
|
235
|
-
const
|
|
236
|
-
console.log("Error found!"), console.error((
|
|
234
|
+
if (console.error(_), t.dotLoader = !1, T.isAxiosError(_)) {
|
|
235
|
+
const v = _;
|
|
236
|
+
console.log("Error found!"), console.error((x = v.response) == null ? void 0 : x.data), l.setError(((b = v.response) == null ? void 0 : b.data).message);
|
|
237
237
|
} else
|
|
238
|
-
|
|
238
|
+
l.setError("There was an issue, please contact helpmate");
|
|
239
239
|
}
|
|
240
240
|
};
|
|
241
241
|
return ($, p) => (u(), m("div", us, [
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
c.value ? (u(), m("div",
|
|
242
|
+
e("div", ps, [
|
|
243
|
+
e("div", ms, [
|
|
244
|
+
e("div", _s, [
|
|
245
|
+
e("div", hs, [
|
|
246
|
+
e("div", gs, [
|
|
247
|
+
c.value ? (u(), m("div", xs, bs)) : (u(), m("div", fs, [
|
|
248
248
|
(u(), m("svg", {
|
|
249
249
|
onClick: p[0] || (p[0] = (k) => N()),
|
|
250
250
|
xmlns: "http://www.w3.org/2000/svg",
|
|
251
251
|
fill: "currentColor",
|
|
252
252
|
class: "bi bi-send ml-2 h-7 w-7 rotate-45 rounded",
|
|
253
253
|
viewBox: "0 0 16 16"
|
|
254
|
-
},
|
|
254
|
+
}, ys))
|
|
255
255
|
]))
|
|
256
256
|
]),
|
|
257
|
-
|
|
258
|
-
$e(
|
|
257
|
+
e("div", $s, [
|
|
258
|
+
$e(e("input", {
|
|
259
259
|
onKeyup: [
|
|
260
260
|
p[1] || (p[1] = qe((k) => c.value ? "" : N(), ["enter"])),
|
|
261
|
-
p[3] || (p[3] = (k) =>
|
|
261
|
+
p[3] || (p[3] = (k) => I(S(t).question))
|
|
262
262
|
],
|
|
263
|
-
"onUpdate:modelValue": p[2] || (p[2] = (k) =>
|
|
263
|
+
"onUpdate:modelValue": p[2] || (p[2] = (k) => S(t).question = k),
|
|
264
264
|
class: "fontFormattingAMA rounded-lg flex w-full border border-genpact-darkest-teal py-[18px] pl-[30px] pr-[70px]",
|
|
265
265
|
placeholder: "Write your answer here...",
|
|
266
266
|
type: "text",
|
|
267
267
|
ref_key: "AiSearch",
|
|
268
268
|
ref: i
|
|
269
269
|
}, null, 544), [
|
|
270
|
-
[ke,
|
|
270
|
+
[ke, S(t).question]
|
|
271
271
|
])
|
|
272
272
|
])
|
|
273
273
|
]),
|
|
@@ -278,27 +278,27 @@ const ds = /* @__PURE__ */ R(is, [["__scopeId", "data-v-f92feaf3"]]), j = (l) =>
|
|
|
278
278
|
]));
|
|
279
279
|
}
|
|
280
280
|
});
|
|
281
|
-
const Ms = /* @__PURE__ */ R(qs, [["__scopeId", "data-v-7eef4de2"]]), G = (
|
|
282
|
-
/* @__PURE__ */
|
|
283
|
-
/* @__PURE__ */
|
|
281
|
+
const Ms = /* @__PURE__ */ R(qs, [["__scopeId", "data-v-7eef4de2"]]), G = (r) => (H("data-v-600c5ec1"), r = r(), z(), r), Is = /* @__PURE__ */ G(() => /* @__PURE__ */ e("div", { class: "max-h-screen overflow-auto md:p-6 p-3 flex flex-col items-center justify-center gap-4 text-[#161916]" }, [
|
|
282
|
+
/* @__PURE__ */ e("div", { class: "text-2xl font-[700]" }, "Assessment Access Required"),
|
|
283
|
+
/* @__PURE__ */ e("h3", { className: "text-lg font-medium my-6 text-center text-gray-500" }, " You don't have access to this assessment. Please contact to administrator ")
|
|
284
284
|
], -1)), Ss = {
|
|
285
285
|
key: 1,
|
|
286
286
|
className: "h-screen flex flex-col items-stretch"
|
|
287
|
-
}, Ls = { class: "z-20" }, Es = /* @__PURE__ */ G(() => /* @__PURE__ */
|
|
287
|
+
}, Ls = { class: "z-20" }, Es = /* @__PURE__ */ G(() => /* @__PURE__ */ e("div", { class: "mt-6" }, null, -1)), Fs = { class: "flex h-full items-stretch overflow-hidden" }, Ts = { class: "mx-auto w-11/12 bg-white" }, Rs = { class: "relative flex h-full w-full flex-col items-stretch overflow-hidden" }, Ns = /* @__PURE__ */ G(() => /* @__PURE__ */ e("div", { class: "mt-[160px]" }, null, -1)), Bs = { class: "relative" }, Cs = /* @__PURE__ */ M({
|
|
288
288
|
__name: "AssessmentAMA",
|
|
289
|
-
setup(
|
|
290
|
-
const
|
|
289
|
+
setup(r) {
|
|
290
|
+
const t = d(!0), l = d(!1), a = C(), i = ue(), w = d(""), y = localStorage.getItem("accessToken");
|
|
291
291
|
let c = "", o = "", A = "";
|
|
292
|
-
const
|
|
293
|
-
|
|
292
|
+
const I = d(((f) => new URLSearchParams(window.location.search).get(f) || "")("amaId"));
|
|
293
|
+
a.amaSkillId = I.value ?? "";
|
|
294
294
|
const N = ["703331197", "703380812", "703331909", "703363051", "703319578"];
|
|
295
295
|
O(async () => {
|
|
296
|
-
|
|
296
|
+
t.value = !0, await $(), await k(), t.value = !1;
|
|
297
297
|
});
|
|
298
298
|
const $ = async () => {
|
|
299
|
-
var
|
|
299
|
+
var f, x, b, _, v;
|
|
300
300
|
try {
|
|
301
|
-
if (
|
|
301
|
+
if (I.value === null)
|
|
302
302
|
throw {
|
|
303
303
|
response: {
|
|
304
304
|
status: 424,
|
|
@@ -309,36 +309,36 @@ const Ms = /* @__PURE__ */ R(qs, [["__scopeId", "data-v-7eef4de2"]]), G = (l) =>
|
|
|
309
309
|
};
|
|
310
310
|
console.log("before calling get learner");
|
|
311
311
|
const n = await de(
|
|
312
|
-
`/getLearnerData?forSimulation=true&skillForSimulation=${
|
|
312
|
+
`/getLearnerData?forSimulation=true&skillForSimulation=${I.value}`
|
|
313
313
|
);
|
|
314
|
-
|
|
314
|
+
a.initialize(n.data), await p();
|
|
315
315
|
} catch (n) {
|
|
316
|
-
if (console.error(n),
|
|
316
|
+
if (console.error(n), t.value = !1, T.isAxiosError(n) && ((f = n.response) != null && f.status) || n && typeof n == "object" && "response" in n && n.response && typeof n.response == "object" && "status" in n.response && n.response.status) {
|
|
317
317
|
const h = n;
|
|
318
|
-
if (console.log("Error found!"), console.error((
|
|
319
|
-
|
|
318
|
+
if (console.log("Error found!"), console.error((x = h.response) == null ? void 0 : x.data), ((b = h.response) == null ? void 0 : b.status) === 424 || ((_ = h.response) == null ? void 0 : _.status) === 425) {
|
|
319
|
+
l.value = !0;
|
|
320
320
|
return;
|
|
321
321
|
}
|
|
322
|
-
i.setError(((
|
|
322
|
+
i.setError(((v = h.response) == null ? void 0 : v.data).message);
|
|
323
323
|
} else
|
|
324
324
|
i.setError("There was an issue, please contact helpmate");
|
|
325
325
|
}
|
|
326
326
|
}, p = async () => {
|
|
327
|
-
var
|
|
327
|
+
var f, x, b, _, v, n, h, L, g, F, W, Y, Z, J, X, ee, se, te, ae, oe, ne, re, le, ce;
|
|
328
328
|
console.log("Start getAssessmentDetails");
|
|
329
329
|
try {
|
|
330
|
-
|
|
331
|
-
const
|
|
332
|
-
console.log("response from GetAMA",
|
|
333
|
-
const
|
|
334
|
-
|
|
335
|
-
const pe =
|
|
330
|
+
V === "prod" ? c = `https://api-v2-dev.genpact.com/api/my-profile/ama-master/getAMADetailsById?id=${I.value}` : c = `https://api-v2-dev.genpact.com/api/my-profile/ama-master/getAMADetailsById?id=${I.value}`;
|
|
331
|
+
const s = await de(c);
|
|
332
|
+
console.log("response from GetAMA", s), w.value = (x = (f = s == null ? void 0 : s.data) == null ? void 0 : f.data) == null ? void 0 : x.name, a.welcomeMessage = (_ = (b = s == null ? void 0 : s.data) == null ? void 0 : b.data) == null ? void 0 : _.displayMsg, console.log("response from GetAMA skill Name", w.value), a.skillNameForSimulation = w.value, a.generatedPrompt = (n = (v = s == null ? void 0 : s.data) == null ? void 0 : v.data) == null ? void 0 : n.generatedPrompt, o = (L = (h = s == null ? void 0 : s.data) == null ? void 0 : h.data) == null ? void 0 : L.accessBand, A = (F = (g = s == null ? void 0 : s.data) == null ? void 0 : g.data) == null ? void 0 : F.accessOhrList;
|
|
333
|
+
const E = (Y = (W = s == null ? void 0 : s.data) == null ? void 0 : W.data) == null ? void 0 : Y.createdBy;
|
|
334
|
+
a.mcqType = (J = (Z = s == null ? void 0 : s.data) == null ? void 0 : Z.data) == null ? void 0 : J.mcqTypes, a.storeFinalFeedback = (ee = (X = s == null ? void 0 : s.data) == null ? void 0 : X.data) == null ? void 0 : ee.storeFinalFeedback, a.storeFinalScore = (te = (se = s == null ? void 0 : s.data) == null ? void 0 : se.data) == null ? void 0 : te.storeFinalScore, console.log("store mcqType====>", a.mcqType);
|
|
335
|
+
const pe = a == null ? void 0 : a.band_code;
|
|
336
336
|
console.log("accessBand , accessOhrList====>", o, A);
|
|
337
|
-
const
|
|
338
|
-
if (console.log("bands ,====>",
|
|
337
|
+
const j = (ae = o == null ? void 0 : o.split(",")) == null ? void 0 : ae.map((me) => me.trim());
|
|
338
|
+
if (console.log("bands ,====>", j), E === (a == null ? void 0 : a.ohr) || N.includes(a == null ? void 0 : a.ohr))
|
|
339
339
|
console.log("User has access to this assessment.");
|
|
340
340
|
else {
|
|
341
|
-
if (
|
|
341
|
+
if (j.length === 0 && A.length === 0)
|
|
342
342
|
throw console.log("Both bands and exceptionOHR are empty. Access denied."), {
|
|
343
343
|
response: {
|
|
344
344
|
status: 424,
|
|
@@ -347,7 +347,7 @@ const Ms = /* @__PURE__ */ R(qs, [["__scopeId", "data-v-7eef4de2"]]), G = (l) =>
|
|
|
347
347
|
}
|
|
348
348
|
}
|
|
349
349
|
};
|
|
350
|
-
if (
|
|
350
|
+
if (j.includes(pe) || A.includes(a == null ? void 0 : a.ohr))
|
|
351
351
|
console.log("User has access to this assessment.");
|
|
352
352
|
else
|
|
353
353
|
throw console.log("User does not have access to this assessment."), {
|
|
@@ -360,57 +360,57 @@ const Ms = /* @__PURE__ */ R(qs, [["__scopeId", "data-v-7eef4de2"]]), G = (l) =>
|
|
|
360
360
|
};
|
|
361
361
|
}
|
|
362
362
|
console.log("end getAssessmentDetails");
|
|
363
|
-
} catch (
|
|
364
|
-
if (console.error(
|
|
365
|
-
const
|
|
366
|
-
if (console.log("Error found!"), console.error((ne =
|
|
367
|
-
|
|
363
|
+
} catch (s) {
|
|
364
|
+
if (console.error(s), t.value = !1, T.isAxiosError(s) && ((oe = s.response) != null && oe.status) || s && typeof s == "object" && "response" in s && s.response && typeof s.response == "object" && "status" in s.response && s.response.status) {
|
|
365
|
+
const E = s;
|
|
366
|
+
if (console.log("Error found!"), console.error((ne = E.response) == null ? void 0 : ne.data), ((re = E.response) == null ? void 0 : re.status) === 424 || ((le = E.response) == null ? void 0 : le.status) === 425) {
|
|
367
|
+
l.value = !0;
|
|
368
368
|
return;
|
|
369
369
|
}
|
|
370
|
-
i.setError(((ce =
|
|
370
|
+
i.setError(((ce = E.response) == null ? void 0 : ce.data).message);
|
|
371
371
|
} else
|
|
372
372
|
i.setError("There was an issue, please contact helpmate");
|
|
373
373
|
}
|
|
374
374
|
}, k = async () => {
|
|
375
|
-
var
|
|
375
|
+
var f, x, b, _, v, n, h, L;
|
|
376
376
|
try {
|
|
377
377
|
const g = await T({
|
|
378
378
|
url: "https://api-v2-dev.genpact.com/api/delphi/v2/myprofile",
|
|
379
379
|
headers: {
|
|
380
|
-
authorization: `Bearer ${
|
|
380
|
+
authorization: `Bearer ${y}`,
|
|
381
381
|
"content-type": "application/json"
|
|
382
382
|
},
|
|
383
383
|
method: "get"
|
|
384
384
|
});
|
|
385
|
-
|
|
385
|
+
a.genomeFunctionValue = (b = (x = (f = g == null ? void 0 : g.data) == null ? void 0 : f.role_function) == null ? void 0 : x.function) == null ? void 0 : b.name, a.genomeRoleValue = (n = (v = (_ = g == null ? void 0 : g.data) == null ? void 0 : _.role_function) == null ? void 0 : v.role) == null ? void 0 : n.name, console.log("profile data", a.genomeFunctionValue, a.genomeRoleValue);
|
|
386
386
|
} catch (g) {
|
|
387
|
-
if (console.error(g),
|
|
387
|
+
if (console.error(g), t.value = !1, T.isAxiosError(g)) {
|
|
388
388
|
const F = g;
|
|
389
|
-
console.log("Error found!"), console.error((h = F.response) == null ? void 0 : h.data), i.setError(((
|
|
389
|
+
console.log("Error found!"), console.error((h = F.response) == null ? void 0 : h.data), i.setError(((L = F.response) == null ? void 0 : L.data).message);
|
|
390
390
|
} else
|
|
391
391
|
i.setError("There was an issue, please contact helpmate");
|
|
392
392
|
}
|
|
393
393
|
};
|
|
394
|
-
return (
|
|
395
|
-
q(ve, { "is-visible":
|
|
394
|
+
return (f, x) => (u(), m("section", null, [
|
|
395
|
+
q(ve, { "is-visible": l.value }, {
|
|
396
396
|
default: Me(() => [
|
|
397
397
|
Is
|
|
398
398
|
]),
|
|
399
399
|
_: 1
|
|
400
400
|
}, 8, ["is-visible"]),
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
401
|
+
e("div", null, [
|
|
402
|
+
t.value ? (u(), Ie(ge, { key: 0 })) : (u(), m("main", Ss, [
|
|
403
|
+
e("div", Ls, [
|
|
404
404
|
q(Be)
|
|
405
405
|
]),
|
|
406
406
|
Es,
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
407
|
+
e("div", Fs, [
|
|
408
|
+
e("div", Ts, [
|
|
409
|
+
e("div", Rs, [
|
|
410
410
|
q(ds),
|
|
411
411
|
Ns
|
|
412
412
|
]),
|
|
413
|
-
|
|
413
|
+
e("div", Bs, [
|
|
414
414
|
q(Ms)
|
|
415
415
|
])
|
|
416
416
|
])
|
|
@@ -420,7 +420,7 @@ const Ms = /* @__PURE__ */ R(qs, [["__scopeId", "data-v-7eef4de2"]]), G = (l) =>
|
|
|
420
420
|
]));
|
|
421
421
|
}
|
|
422
422
|
});
|
|
423
|
-
const Hs = /* @__PURE__ */ R(Cs, [["__scopeId", "data-v-
|
|
423
|
+
const Hs = /* @__PURE__ */ R(Cs, [["__scopeId", "data-v-600c5ec1"]]);
|
|
424
424
|
export {
|
|
425
425
|
Hs as default
|
|
426
426
|
};
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { _ as Cl, a as op, L as yl } from "./LoadingSimulation-
|
|
2
|
-
import { _ as Pl, a as ap, Q as kt, M as _a } from "./Modal-
|
|
3
|
-
import { d as Ee, r as b, H as Nt, o as O, c as N, a as P, k as yt, u as Me, C as Ut, q as ye, y as qo, h as me, s as cp, t as Ke, b as k, f as Pe, i as jn, I as Ki, F as Bo, e as Fo, w as Qo, J as Rl, p as Vn, g as $n, G as Xi, z as El, K as wl, n as zt, m as up, L as pp, l as Al } from "./main-
|
|
4
|
-
import { g as qn, p as St } from "./api-
|
|
5
|
-
import { c as B, a as Il, r as _l } from "./_commonjsHelpers-
|
|
1
|
+
import { _ as Cl, a as op, L as yl } from "./LoadingSimulation-fcfccc93.mjs";
|
|
2
|
+
import { _ as Pl, a as ap, Q as kt, M as _a } from "./Modal-1645738a.mjs";
|
|
3
|
+
import { d as Ee, r as b, H as Nt, o as O, c as N, a as P, k as yt, u as Me, C as Ut, q as ye, y as qo, h as me, s as cp, t as Ke, b as k, f as Pe, i as jn, I as Ki, F as Bo, e as Fo, w as Qo, J as Rl, p as Vn, g as $n, G as Xi, z as El, K as wl, n as zt, m as up, L as pp, l as Al } from "./main-276ff0ff.mjs";
|
|
4
|
+
import { g as qn, p as St } from "./api-4d088800.mjs";
|
|
5
|
+
import { c as B, a as Il, r as _l } from "./_commonjsHelpers-fb050ae5.mjs";
|
|
6
6
|
import { _ as Ht } from "./_plugin-vue_export-helper-dad06003.mjs";
|
|
7
7
|
import "./loadernew-ac153a51.mjs";
|
|
8
8
|
const Tl = { class: "flex h-14 w-full flex-1 items-center justify-between bg-[#021c42] md:pr-6 lg:pr-6" }, bl = ["href"], Ml = /* @__PURE__ */ P("img", {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { d as G, M as z, o as n, c as d, a as e, h as L, b as c, u as H, k as O, r, w as h, m as k, n as S, v as $, F as q, e as P, t as b, q as D, D as T, p as Y, g as J, i as F } from "./main-
|
|
1
|
+
import { d as G, M as z, o as n, c as d, a as e, h as L, b as c, u as H, k as O, r, w as h, m as k, n as S, v as $, F as q, e as P, t as b, q as D, D as T, p as Y, g as J, i as F } from "./main-276ff0ff.mjs";
|
|
2
2
|
import { _ as j } from "./loadernew-ac153a51.mjs";
|
|
3
|
-
import { p as B, g as Q } from "./api-
|
|
3
|
+
import { p as B, g as Q } from "./api-4d088800.mjs";
|
|
4
4
|
import { _ as X } from "./genome-Logo-white-ffcf2413.mjs";
|
|
5
|
-
import { r as Z } from "./ArrowLeftCircleIcon-
|
|
5
|
+
import { r as Z } from "./ArrowLeftCircleIcon-45250164.mjs";
|
|
6
6
|
import { _ as ee } from "./_plugin-vue_export-helper-dad06003.mjs";
|
|
7
7
|
const te = { className: "flex justify-between items-center gap-4 h-14" }, se = /* @__PURE__ */ e("div", { class: "font-bold text-base md:text-xl" }, "Back", -1), oe = /* @__PURE__ */ e("div", { class: "text-white font-bold md:text-xl text-base" }, "AI Guru Edit Skill Admin Data", -1), le = /* @__PURE__ */ e("img", {
|
|
8
8
|
class: "md:w-36 w-20",
|