@nualang/nualang-ui-components 0.1.1315 → 0.1.1317

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.
@@ -123,7 +123,12 @@ function Bot({
123
123
  sm: "85%"
124
124
  },
125
125
  children: [/*#__PURE__*/_jsx(Avatar, {
126
- src: bot.picture
126
+ src: bot.picture || bot.botAvatar,
127
+ sx: {
128
+ display: "flex",
129
+ width: 32,
130
+ height: 32
131
+ }
127
132
  }), /*#__PURE__*/_jsx(ListItemText, {
128
133
  sx: {
129
134
  marginLeft: 2
@@ -206,7 +206,7 @@ function Roleplay({
206
206
  sm: "85%"
207
207
  },
208
208
  children: [/*#__PURE__*/_jsx(Avatar, {
209
- src: roleplay.picture,
209
+ src: roleplay.picture || roleplay.actor1 && roleplay.actor1.picture || roleplay.actor2 && roleplay.actor2.picture,
210
210
  sx: {
211
211
  display: "flex",
212
212
  width: 32,
@@ -13,6 +13,7 @@ import level2Rubric from '../../Dialogs/PDFViewer/rubrics/level2Rubric.pdf';
13
13
  import level3Rubric from '../../Dialogs/PDFViewer/rubrics/level3Rubric.pdf';
14
14
  import level4Rubric from '../../Dialogs/PDFViewer/rubrics/level4Rubric.pdf';
15
15
  import HelpOutlineIcon from "@mui/icons-material/HelpOutline";
16
+ import NualaCreating from "../../Misc/NualaCreating/NualaCreating";
16
17
  import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
17
18
  export default function FeedbackCard({
18
19
  t = x => x,
@@ -197,121 +198,139 @@ export default function FeedbackCard({
197
198
  boxShadow: 3,
198
199
  overflow: "hidden"
199
200
  },
200
- children: [/*#__PURE__*/_jsx(Box, {
201
+ children: [aiJustGenerated ? /*#__PURE__*/_jsxs(Grid, {
201
202
  sx: {
202
- px: 3,
203
- pt: 2,
204
- pb: 1,
205
- fontWeight: 600,
206
- color: "text.secondary"
203
+ ...(!aiJustGenerated && {
204
+ display: "none"
205
+ })
207
206
  },
208
- children: /*#__PURE__*/_jsxs(Grid, {
209
- container: true,
210
- alignItems: "center",
211
- spacing: 3,
212
- children: [/*#__PURE__*/_jsx(Grid, {
213
- size: {
214
- xs: 12,
215
- md: 2.5
216
- },
217
- children: /*#__PURE__*/_jsx(Typography, {
218
- variant: "subtitle2",
219
- children: t("student")
220
- })
221
- }), /*#__PURE__*/_jsx(Grid, {
222
- size: {
223
- xs: 12,
224
- md: 9.5
225
- },
226
- children: /*#__PURE__*/_jsxs(Box, {
227
- sx: {
228
- display: "flex",
229
- alignItems: "center"
207
+ mx: 2,
208
+ size: 12,
209
+ children: [/*#__PURE__*/_jsx(Typography, {
210
+ variant: "h6",
211
+ sx: {
212
+ mt: 2,
213
+ mb: 2
214
+ },
215
+ children: t("generating_feedback")
216
+ }), /*#__PURE__*/_jsx(NualaCreating, {})]
217
+ }) : /*#__PURE__*/_jsxs(_Fragment, {
218
+ children: [/*#__PURE__*/_jsx(Box, {
219
+ sx: {
220
+ px: 3,
221
+ pt: 2,
222
+ pb: 1,
223
+ fontWeight: 600,
224
+ color: "text.secondary"
225
+ },
226
+ children: /*#__PURE__*/_jsxs(Grid, {
227
+ container: true,
228
+ alignItems: "center",
229
+ spacing: 3,
230
+ children: [/*#__PURE__*/_jsx(Grid, {
231
+ size: {
232
+ xs: 12,
233
+ md: 2.5
230
234
  },
231
- children: [/*#__PURE__*/_jsx(Typography, {
235
+ children: /*#__PURE__*/_jsx(Typography, {
232
236
  variant: "subtitle2",
233
- children: t("feedback")
234
- }), /*#__PURE__*/_jsx(Tooltip, {
235
- title: t("rubric_info_desc"),
236
- children: /*#__PURE__*/_jsx(IconButton, {
237
- onClick: handleOpenPDF,
238
- color: "primary",
239
- "aria-label": t("rubric_info"),
240
- size: "small",
241
- children: /*#__PURE__*/_jsx(HelpOutlineIcon, {})
242
- })
243
- })]
244
- })
245
- })]
246
- })
247
- }), /*#__PURE__*/_jsx(CardContent, {
248
- sx: {
249
- px: 3,
250
- pt: 1
251
- },
252
- children: [...selectedMembers].sort((a, b) => {
253
- const aJoined = joinedMembers.includes(a.memberId);
254
- const bJoined = joinedMembers.includes(b.memberId);
255
- return aJoined === bJoined ? 0 : aJoined ? -1 : 1;
256
- }).map(student => {
257
- const isAbsent = hasSubmission && !joinedMembers.includes(student.memberId);
258
- const disabled = !hasSubmission || isAbsent;
259
- const studentFeedback = values.feedbackData[student.memberId] || {};
260
- return /*#__PURE__*/_jsx(Box, {
261
- sx: {
262
- py: 2
263
- },
264
- children: /*#__PURE__*/_jsxs(Grid, {
265
- container: true,
266
- alignItems: "flex-start",
267
- spacing: 3,
268
- children: [/*#__PURE__*/_jsx(Grid, {
269
- size: {
270
- xs: 12,
271
- md: 2.5
272
- },
273
- children: /*#__PURE__*/_jsxs(Box, {
237
+ children: t("student")
238
+ })
239
+ }), /*#__PURE__*/_jsx(Grid, {
240
+ size: {
241
+ xs: 12,
242
+ md: 9.5
243
+ },
244
+ children: /*#__PURE__*/_jsxs(Box, {
245
+ sx: {
274
246
  display: "flex",
275
- alignItems: "center",
276
- gap: 2,
277
- children: [/*#__PURE__*/_jsx(Avatar, {
278
- alt: student.username,
279
- src: student.userImage,
280
- sx: {
281
- width: 48,
282
- height: 48,
283
- filter: isAbsent ? "grayscale(100%)" : "none"
284
- }
285
- }), /*#__PURE__*/_jsx(Typography, {
286
- fontWeight: 600,
287
- sx: {
288
- color: isAbsent ? grey[500] : "text.primary"
289
- },
290
- children: student.username
291
- })]
292
- })
293
- }), /*#__PURE__*/_jsx(Grid, {
294
- size: {
295
- xs: 12,
296
- md: 9.5
247
+ alignItems: "center"
297
248
  },
298
- children: /*#__PURE__*/_jsx(TextField, {
299
- variant: "outlined",
300
- fullWidth: true,
301
- multiline: true,
302
- disabled: disabled,
303
- value: studentFeedback.feedbackText || "",
304
- onChange: e => {
305
- setFieldValue(`feedbackData.${student.memberId}.feedbackText`, e.target.value);
306
- setHasBeenEdited(true);
307
- setIsSubmitted(false);
249
+ children: [/*#__PURE__*/_jsx(Typography, {
250
+ variant: "subtitle2",
251
+ children: t("feedback")
252
+ }), /*#__PURE__*/_jsx(Tooltip, {
253
+ title: t("rubric_info_desc"),
254
+ children: /*#__PURE__*/_jsx(IconButton, {
255
+ onClick: handleOpenPDF,
256
+ color: "primary",
257
+ "aria-label": t("rubric_info"),
258
+ size: "small",
259
+ children: /*#__PURE__*/_jsx(HelpOutlineIcon, {})
260
+ })
261
+ })]
262
+ })
263
+ })]
264
+ })
265
+ }), /*#__PURE__*/_jsx(CardContent, {
266
+ sx: {
267
+ px: 3,
268
+ pt: 1
269
+ },
270
+ children: [...selectedMembers].sort((a, b) => {
271
+ const aJoined = joinedMembers.includes(a.memberId);
272
+ const bJoined = joinedMembers.includes(b.memberId);
273
+ return aJoined === bJoined ? 0 : aJoined ? -1 : 1;
274
+ }).map(student => {
275
+ const isAbsent = hasSubmission && !joinedMembers.includes(student.memberId);
276
+ const disabled = !hasSubmission || isAbsent;
277
+ const studentFeedback = values.feedbackData[student.memberId] || {};
278
+ return /*#__PURE__*/_jsx(Box, {
279
+ sx: {
280
+ py: 2
281
+ },
282
+ children: /*#__PURE__*/_jsxs(Grid, {
283
+ container: true,
284
+ alignItems: "flex-start",
285
+ spacing: 3,
286
+ children: [/*#__PURE__*/_jsx(Grid, {
287
+ size: {
288
+ xs: 12,
289
+ md: 2.5
290
+ },
291
+ children: /*#__PURE__*/_jsxs(Box, {
292
+ display: "flex",
293
+ alignItems: "center",
294
+ gap: 2,
295
+ children: [/*#__PURE__*/_jsx(Avatar, {
296
+ alt: student.username,
297
+ src: student.userImage,
298
+ sx: {
299
+ width: 48,
300
+ height: 48,
301
+ filter: isAbsent ? "grayscale(100%)" : "none"
302
+ }
303
+ }), /*#__PURE__*/_jsx(Typography, {
304
+ fontWeight: 600,
305
+ sx: {
306
+ color: isAbsent ? grey[500] : "text.primary"
307
+ },
308
+ children: student.username
309
+ })]
310
+ })
311
+ }), /*#__PURE__*/_jsx(Grid, {
312
+ size: {
313
+ xs: 12,
314
+ md: 9.5
308
315
  },
309
- placeholder: t("Write your feedback here")
310
- })
311
- })]
312
- })
313
- }, student.memberId);
314
- })
316
+ children: /*#__PURE__*/_jsx(TextField, {
317
+ variant: "outlined",
318
+ fullWidth: true,
319
+ multiline: true,
320
+ disabled: disabled,
321
+ value: studentFeedback.feedbackText || "",
322
+ onChange: e => {
323
+ setFieldValue(`feedbackData.${student.memberId}.feedbackText`, e.target.value);
324
+ setHasBeenEdited(true);
325
+ setIsSubmitted(false);
326
+ },
327
+ placeholder: t("Write your feedback here")
328
+ })
329
+ })]
330
+ })
331
+ }, student.memberId);
332
+ })
333
+ })]
315
334
  }), /*#__PURE__*/_jsxs(CardActions, {
316
335
  sx: {
317
336
  px: 3,
@@ -354,13 +373,13 @@ export default function FeedbackCard({
354
373
  },
355
374
  children: [/*#__PURE__*/_jsx(Button, {
356
375
  variant: "outlined",
357
- disabled: !hasSubmission,
376
+ disabled: !hasSubmission || aiJustGenerated,
358
377
  onClick: handleOpenRecordingDialog,
359
378
  children: t("view_recording")
360
379
  }), /*#__PURE__*/_jsx(Button, {
361
380
  variant: "contained",
362
381
  color: "secondary",
363
- disabled: !hasSubmission,
382
+ disabled: !hasSubmission || aiJustGenerated,
364
383
  onClick: handleGenerateAI,
365
384
  endIcon: /*#__PURE__*/_jsx(AutoFixHighIcon, {}),
366
385
  children: t("generate_feedback")
@@ -4,9 +4,15 @@ import Avatar from "@mui/material/Avatar";
4
4
  import AvatarGroup from "@mui/material/AvatarGroup";
5
5
  import Chip from "@mui/material/Chip";
6
6
  import Box from "@mui/material/Box";
7
- import { Card, CardActionArea, Divider, Button, Tooltip } from "@mui/material";
7
+ import { Card, CardActionArea, Divider, Button, Tooltip, IconButton } from "@mui/material";
8
8
  import PropTypes from "prop-types";
9
9
  import dayjs from "dayjs";
10
+ import PDFViewer from "../../Dialogs/PDFViewer/PDFViewer";
11
+ import level1Rubric from '../../Dialogs/PDFViewer/rubrics/level1Rubric.pdf';
12
+ import level2Rubric from '../../Dialogs/PDFViewer/rubrics/level2Rubric.pdf';
13
+ import level3Rubric from '../../Dialogs/PDFViewer/rubrics/level3Rubric.pdf';
14
+ import level4Rubric from '../../Dialogs/PDFViewer/rubrics/level4Rubric.pdf';
15
+ import HelpOutlineIcon from "@mui/icons-material/HelpOutline";
10
16
  import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
11
17
  export default function RecordingCard({
12
18
  isTeacher = false,
@@ -16,6 +22,9 @@ export default function RecordingCard({
16
22
  t = x => x
17
23
  }) {
18
24
  const [promptExpanded, setPromptExpanded] = useState(false);
25
+ const [openPDF, setOpenPDF] = useState(false);
26
+ const [pageNumber, setPageNumber] = useState(1);
27
+ const [scale, setScale] = useState(1);
19
28
  const selectedMembers = userData.filter(o1 => [recordingsListData?.userIds].flat().some(o2 => o1?.memberId === o2));
20
29
  const attendedMembers = selectedMembers.filter(attendee => recordingsListData?.joinedMembers?.includes(attendee?.memberId));
21
30
  const notAttendedMembers = selectedMembers.filter(attendee => !recordingsListData?.joinedMembers?.includes(attendee?.memberId));
@@ -28,6 +37,13 @@ export default function RecordingCard({
28
37
  if (diffDays < 0) dueText = t("past_due");else if (diffDays === 0) dueText = t("due_today");else if (diffDays === 1) dueText = t("due_tomorrow");else dueText = `${t("due_in")} ${diffDays} ${t("days")}`;
29
38
  return `${formattedDate} - ${dueText}`;
30
39
  };
40
+ const rubricMap = {
41
+ 1: level1Rubric,
42
+ 2: level2Rubric,
43
+ 3: level3Rubric,
44
+ 4: level4Rubric
45
+ };
46
+ const pdfUrl = rubricMap[recordingsListData?.level] || level1Rubric;
31
47
  const renderExpandableText = (text, expanded, setExpanded, maxChars = 150) => {
32
48
  if (!text) return null;
33
49
  const isLong = text.length > maxChars;
@@ -50,145 +66,177 @@ export default function RecordingCard({
50
66
  })]
51
67
  });
52
68
  };
53
- return /*#__PURE__*/_jsx(Card, {
54
- sx: {
55
- display: "flex",
56
- marginBottom: 2,
57
- boxShadow: 3
58
- },
59
- children: /*#__PURE__*/_jsx(CardActionArea, {
60
- component: "a",
61
- onClick: handleView,
62
- children: /*#__PURE__*/_jsxs(Box, {
63
- sx: {
64
- p: 2
65
- },
66
- children: [/*#__PURE__*/_jsxs(Box, {
69
+ const handleOpenPDF = () => {
70
+ setOpenPDF(true);
71
+ };
72
+ const handleClosePDF = () => {
73
+ setOpenPDF(false);
74
+ };
75
+ return /*#__PURE__*/_jsxs(_Fragment, {
76
+ children: [/*#__PURE__*/_jsx(Card, {
77
+ sx: {
78
+ display: "flex",
79
+ marginBottom: 2,
80
+ boxShadow: 3
81
+ },
82
+ children: /*#__PURE__*/_jsx(CardActionArea, {
83
+ component: "a",
84
+ onClick: handleView,
85
+ children: /*#__PURE__*/_jsxs(Box, {
67
86
  sx: {
68
- display: "flex",
69
- justifyContent: "space-between",
70
- alignItems: "center"
87
+ p: 2
71
88
  },
72
89
  children: [/*#__PURE__*/_jsxs(Box, {
73
90
  sx: {
74
91
  display: "flex",
75
- alignItems: "center",
76
- gap: 1
92
+ justifyContent: "space-between",
93
+ alignItems: "center"
77
94
  },
78
- children: [/*#__PURE__*/_jsx(Typography, {
79
- variant: "body1",
80
- fontWeight: 600,
95
+ children: [/*#__PURE__*/_jsxs(Box, {
96
+ sx: {
97
+ display: "flex",
98
+ alignItems: "center",
99
+ gap: 1
100
+ },
101
+ children: [/*#__PURE__*/_jsx(Typography, {
102
+ variant: "body1",
103
+ fontWeight: 600,
104
+ sx: {
105
+ color: "text.primary"
106
+ },
107
+ children: recordingsListData?.meetingTopic
108
+ }), recordingsListData?.feedbackText && /*#__PURE__*/_jsx(Chip, {
109
+ label: t("submission_graded"),
110
+ color: "success",
111
+ size: "small"
112
+ })]
113
+ }), /*#__PURE__*/_jsx(Typography, {
114
+ variant: "body2",
115
+ color: "text.secondary",
81
116
  sx: {
82
- color: "text.primary"
117
+ ml: 1.5,
118
+ fontWeight: 500
83
119
  },
84
- children: recordingsListData?.meetingTopic
85
- }), recordingsListData?.feedbackText && /*#__PURE__*/_jsx(Chip, {
86
- label: t("submission_graded"),
87
- color: "success",
88
- size: "small"
120
+ children: formatMeetingDueText(recordingsListData.timestamp, t)
89
121
  })]
90
- }), /*#__PURE__*/_jsx(Typography, {
91
- variant: "body2",
92
- color: "text.secondary",
122
+ }), /*#__PURE__*/_jsx(Divider, {
93
123
  sx: {
94
- ml: 1.5,
95
- fontWeight: 500
96
- },
97
- children: formatMeetingDueText(recordingsListData.timestamp, t)
98
- })]
99
- }), /*#__PURE__*/_jsx(Divider, {
100
- sx: {
101
- my: 1.5
102
- }
103
- }), /*#__PURE__*/_jsxs(Box, {
104
- sx: {
105
- display: "flex",
106
- justifyContent: "space-between",
107
- alignItems: "center",
108
- mb: 1.5
109
- },
110
- children: [/*#__PURE__*/_jsxs(Box, {
124
+ my: 1.5
125
+ }
126
+ }), /*#__PURE__*/_jsxs(Box, {
111
127
  sx: {
112
128
  display: "flex",
129
+ justifyContent: "space-between",
113
130
  alignItems: "center",
114
- gap: 1
131
+ mb: 1.5
115
132
  },
116
- children: [/*#__PURE__*/_jsx(AvatarGroup, {
117
- max: 4,
118
- spacing: -3,
133
+ children: [/*#__PURE__*/_jsxs(Box, {
119
134
  sx: {
120
135
  display: "flex",
121
- "& .MuiAvatar-root": {
122
- width: 40,
123
- height: 40,
124
- fontSize: "1rem"
125
- }
136
+ alignItems: "center",
137
+ gap: 1
126
138
  },
127
- children: attendedMembers.map(attendee => /*#__PURE__*/_jsx(Tooltip, {
128
- title: `${attendee?.username} - Present`,
129
- children: /*#__PURE__*/_jsx(Avatar, {
130
- alt: attendee?.username,
131
- src: attendee?.userImage
132
- })
133
- }, attendee?.memberId))
134
- }), notAttendedMembers.length > 0 && /*#__PURE__*/_jsx(AvatarGroup, {
135
- max: 4,
136
- spacing: -3,
139
+ children: [/*#__PURE__*/_jsx(AvatarGroup, {
140
+ max: 4,
141
+ spacing: -3,
142
+ sx: {
143
+ display: "flex",
144
+ "& .MuiAvatar-root": {
145
+ width: 40,
146
+ height: 40,
147
+ fontSize: "1rem"
148
+ }
149
+ },
150
+ children: attendedMembers.map(attendee => /*#__PURE__*/_jsx(Tooltip, {
151
+ title: `${attendee?.username} - Present`,
152
+ children: /*#__PURE__*/_jsx(Avatar, {
153
+ alt: attendee?.username,
154
+ src: attendee?.userImage
155
+ })
156
+ }, attendee?.memberId))
157
+ }), notAttendedMembers.length > 0 && /*#__PURE__*/_jsx(AvatarGroup, {
158
+ max: 4,
159
+ spacing: -3,
160
+ sx: {
161
+ display: "flex",
162
+ ml: 2,
163
+ "& .MuiAvatar-root": {
164
+ width: 40,
165
+ height: 40,
166
+ fontSize: "1rem",
167
+ filter: "grayscale(100%)"
168
+ }
169
+ },
170
+ children: notAttendedMembers.map(attendee => /*#__PURE__*/_jsx(Tooltip, {
171
+ title: `${attendee?.username} - Not Present`,
172
+ children: /*#__PURE__*/_jsx(Avatar, {
173
+ alt: attendee?.username,
174
+ src: attendee?.userImage
175
+ })
176
+ }, attendee?.memberId))
177
+ })]
178
+ }), /*#__PURE__*/_jsx(Button, {
179
+ variant: "contained",
180
+ color: "primary",
181
+ onClick: e => {
182
+ e.stopPropagation();
183
+ handleView();
184
+ },
185
+ sx: {
186
+ borderRadius: 2
187
+ },
188
+ children: t("view_submission")
189
+ })]
190
+ }), renderExpandableText(recordingsListData?.meetingPrompt, promptExpanded, setPromptExpanded), recordingsListData?.feedbackText && /*#__PURE__*/_jsxs(_Fragment, {
191
+ children: [/*#__PURE__*/_jsx(Divider, {
192
+ sx: {
193
+ my: 1.5,
194
+ width: "100%"
195
+ }
196
+ }), /*#__PURE__*/_jsxs(Box, {
137
197
  sx: {
138
198
  display: "flex",
139
- ml: 2,
140
- "& .MuiAvatar-root": {
141
- width: 40,
142
- height: 40,
143
- fontSize: "1rem",
144
- filter: "grayscale(100%)"
145
- }
199
+ alignItems: "center"
146
200
  },
147
- children: notAttendedMembers.map(attendee => /*#__PURE__*/_jsx(Tooltip, {
148
- title: `${attendee?.username} - Not Present`,
149
- children: /*#__PURE__*/_jsx(Avatar, {
150
- alt: attendee?.username,
151
- src: attendee?.userImage
201
+ children: [/*#__PURE__*/_jsx(Typography, {
202
+ variant: "subtitle2",
203
+ fontWeight: 600,
204
+ children: t("feedback")
205
+ }), /*#__PURE__*/_jsx(Tooltip, {
206
+ title: t("rubric_info_desc"),
207
+ children: /*#__PURE__*/_jsx(IconButton, {
208
+ color: "primary",
209
+ "aria-label": t("rubric_info"),
210
+ size: "small",
211
+ onClick: e => {
212
+ e.stopPropagation();
213
+ handleOpenPDF();
214
+ },
215
+ children: /*#__PURE__*/_jsx(HelpOutlineIcon, {})
152
216
  })
153
- }, attendee?.memberId))
217
+ })]
218
+ }), /*#__PURE__*/_jsx(Typography, {
219
+ variant: "body2",
220
+ color: "text.secondary",
221
+ sx: {
222
+ fontStyle: "italic",
223
+ whiteSpace: "pre-line"
224
+ },
225
+ children: recordingsListData.feedbackText
154
226
  })]
155
- }), /*#__PURE__*/_jsx(Button, {
156
- variant: "contained",
157
- color: "primary",
158
- onClick: e => {
159
- e.stopPropagation();
160
- handleView();
161
- },
162
- sx: {
163
- borderRadius: 2
164
- },
165
- children: t("view_submission")
166
- })]
167
- }), renderExpandableText(recordingsListData?.meetingPrompt, promptExpanded, setPromptExpanded), recordingsListData?.feedbackText && /*#__PURE__*/_jsxs(_Fragment, {
168
- children: [/*#__PURE__*/_jsx(Divider, {
169
- sx: {
170
- my: 1.5,
171
- width: "100%"
172
- }
173
- }), /*#__PURE__*/_jsx(Typography, {
174
- variant: "subtitle2",
175
- fontWeight: 600,
176
- sx: {
177
- mb: 0.5
178
- },
179
- children: t("feedback")
180
- }), /*#__PURE__*/_jsx(Typography, {
181
- variant: "body2",
182
- color: "text.secondary",
183
- sx: {
184
- fontStyle: "italic",
185
- whiteSpace: "pre-line"
186
- },
187
- children: recordingsListData.feedbackText
188
227
  })]
189
- })]
228
+ })
190
229
  })
191
- })
230
+ }), /*#__PURE__*/_jsx(PDFViewer, {
231
+ open: openPDF,
232
+ handleClose: handleClosePDF,
233
+ pdfUrl: pdfUrl,
234
+ pageNumber: pageNumber,
235
+ setPageNumber: setPageNumber,
236
+ scale: scale,
237
+ setScale: setScale,
238
+ t: t
239
+ })]
192
240
  });
193
241
  }
194
242
  RecordingCard.propTypes = {
@@ -1,5 +1,5 @@
1
1
  import { useMemo } from "react";
2
- import { Dialog, DialogContent, IconButton, Box, Typography, AppBar, Toolbar, CircularProgress } from "@mui/material";
2
+ import { Dialog, DialogContent, IconButton, Box, Typography, AppBar, Toolbar, CircularProgress, Skeleton } from "@mui/material";
3
3
  import CloseIcon from "@mui/icons-material/Close";
4
4
  import { red, orange, green, grey } from "@mui/material/colors";
5
5
  import FeedbackCard from "../../Cards/FeedbackCard/FeedbackCard";
@@ -162,23 +162,50 @@ export default function GroupFeedbackDialog({
162
162
  },
163
163
  children: [/*#__PURE__*/_jsx(Box, {
164
164
  sx: {
165
- display: "flex",
166
- flexDirection: "column",
167
- alignItems: "center",
168
- justifyContent: "center",
169
- maxWidth: "25%"
165
+ position: "relative",
166
+ width: "100%",
167
+ maxWidth: "300px"
170
168
  },
171
- children: /*#__PURE__*/_jsx("img", {
172
- src: editMeetingImages || editBackgroundImages || NualaHeadphonesBackground,
173
- alt: "Meeting Image",
174
- style: {
169
+ children: /*#__PURE__*/_jsxs(Box, {
170
+ sx: {
171
+ position: "relative",
175
172
  width: "100%",
176
- maxWidth: "300px",
177
- height: "auto",
178
- aspectRatio: "16 / 9",
179
- objectFit: "cover",
180
- borderRadius: "8px"
181
- }
173
+ paddingTop: "56.25%",
174
+ borderRadius: "8px",
175
+ overflow: "hidden"
176
+ },
177
+ children: [/*#__PURE__*/_jsx(Skeleton, {
178
+ variant: "rectangular",
179
+ sx: {
180
+ position: "absolute",
181
+ top: 0,
182
+ left: 0,
183
+ width: "100%",
184
+ height: "100%",
185
+ borderRadius: "8px",
186
+ zIndex: 0
187
+ }
188
+ }), /*#__PURE__*/_jsx("img", {
189
+ src: editMeetingImages || editBackgroundImages || NualaHeadphonesBackground,
190
+ alt: "Meeting Image",
191
+ onLoad: e => {
192
+ setTimeout(() => {
193
+ e.target.style.opacity = 1;
194
+ }, 500);
195
+ },
196
+ style: {
197
+ position: "absolute",
198
+ top: 0,
199
+ left: 0,
200
+ width: "100%",
201
+ height: "100%",
202
+ objectFit: "cover",
203
+ borderRadius: "8px",
204
+ opacity: 0,
205
+ transition: "opacity 0.5s ease",
206
+ zIndex: 1
207
+ }
208
+ })]
182
209
  })
183
210
  }), /*#__PURE__*/_jsxs(Box, {
184
211
  sx: {
@@ -80,6 +80,7 @@ const WordText = /*#__PURE__*/memo(props => {
80
80
  leaveDelay: 200,
81
81
  title: translatedText,
82
82
  children: /*#__PURE__*/_jsx("span", {
83
+ translate: "no",
83
84
  "data-text": value.trim(),
84
85
  children: value
85
86
  })
@@ -111,7 +111,8 @@ const useStyles = makeStyles()(theme => ({
111
111
  position: "relative",
112
112
  "@media print": {
113
113
  display: "none"
114
- }
114
+ },
115
+ paddingBottom: "60px"
115
116
  },
116
117
  moreOptions: {
117
118
  "@media print": {
@@ -1204,7 +1205,6 @@ function Classroom({
1204
1205
  onClick: () => {
1205
1206
  setIsCreateMeetingDialogOpen(true);
1206
1207
  },
1207
- title: t("schedule_discussion"),
1208
1208
  tabIndex: tabs.findIndex(tab => tab.id === "Discuss"),
1209
1209
  variant: "extended",
1210
1210
  disabled: !members || members.length === 0
@@ -1223,7 +1223,6 @@ function Classroom({
1223
1223
  onClick: () => {
1224
1224
  handleCreateAssignment();
1225
1225
  },
1226
- title: t("create_assignment"),
1227
1226
  tabIndex: tabs.findIndex(tab => tab.id === "Assignments"),
1228
1227
  variant: "extended",
1229
1228
  disabled: !members || members.length === 0 || !courses || courses.length === 0
@@ -1231,12 +1230,16 @@ function Classroom({
1231
1230
  const fabs = [[{
1232
1231
  color: "primary",
1233
1232
  className: null,
1234
- icon: /*#__PURE__*/_jsx(Add, {}),
1233
+ icon: /*#__PURE__*/_jsx(Add, {
1234
+ sx: {
1235
+ mr: 1
1236
+ }
1237
+ }),
1235
1238
  id: "add-courses-fab",
1239
+ buttonText: t("add_courses"),
1236
1240
  onClick: handleOpenCoursesModal,
1237
- title: t("add_courses"),
1238
1241
  tabIndex: tabs.findIndex(tab => tab.id === "Courses"),
1239
- variant: "circular"
1242
+ variant: "extended"
1240
1243
  }, vchatFab, assignmentsFab]];
1241
1244
  const initialTabValue = useMemo(() => {
1242
1245
  if (window.location.hash) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nualang/nualang-ui-components",
3
- "version": "0.1.1315",
3
+ "version": "0.1.1317",
4
4
  "type": "module",
5
5
  "main": "dist/index.js",
6
6
  "files": [