@elice/material-assignment 1.240805.0 → 1.240806.0-pdf.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (21) hide show
  1. package/cjs/components/material-assignment-admin/MaterialAssignmentAdmin.d.ts +2 -4
  2. package/cjs/components/material-assignment-admin/MaterialAssignmentAdmin.js +6 -7
  3. package/cjs/components/material-assignment-admin/MaterialAssignmentAdminContent.js +58 -185
  4. package/cjs/components/material-assignment-admin/MaterialAssignmentAdminContentTa.js +33 -110
  5. package/es/components/material-assignment-admin/MaterialAssignmentAdmin.d.ts +2 -4
  6. package/es/components/material-assignment-admin/MaterialAssignmentAdmin.js +7 -8
  7. package/es/components/material-assignment-admin/MaterialAssignmentAdminContent.js +59 -186
  8. package/es/components/material-assignment-admin/MaterialAssignmentAdminContentTa.js +34 -111
  9. package/package.json +4 -4
  10. package/cjs/components/material-assignment-admin/locales/en.json.js +0 -7
  11. package/cjs/components/material-assignment-admin/locales/index.d.ts +0 -4
  12. package/cjs/components/material-assignment-admin/locales/index.js +0 -13
  13. package/cjs/components/material-assignment-admin/locales/ja.json.js +0 -7
  14. package/cjs/components/material-assignment-admin/locales/ko.json.js +0 -7
  15. package/cjs/components/material-assignment-admin/locales/th.json.js +0 -7
  16. package/es/components/material-assignment-admin/locales/en.json.js +0 -3
  17. package/es/components/material-assignment-admin/locales/index.d.ts +0 -4
  18. package/es/components/material-assignment-admin/locales/index.js +0 -4
  19. package/es/components/material-assignment-admin/locales/ja.json.js +0 -3
  20. package/es/components/material-assignment-admin/locales/ko.json.js +0 -3
  21. package/es/components/material-assignment-admin/locales/th.json.js +0 -3
@@ -26,7 +26,6 @@ var MaterialAssignmentAdminContentTa = function MaterialAssignmentAdminContentTa
26
26
  userId = _ref.userId,
27
27
  adminUserId = _ref.adminUserId;
28
28
  var _a;
29
- var intl$1 = intl.useRawEliceIntl();
30
29
  // Form
31
30
  var gradeEditFormMethods = reactHookForm.useForm({
32
31
  defaultValues: {
@@ -155,18 +154,14 @@ var MaterialAssignmentAdminContentTa = function MaterialAssignmentAdminContentTa
155
154
  });
156
155
  case 4:
157
156
  fetchMyGrade();
158
- blocks.Notification.success(intl$1.formatMessage({
159
- id: 'materialAssignment.notify.success'
160
- }));
157
+ blocks.Notification.success('저장되었습니다');
161
158
  _context.next = 12;
162
159
  break;
163
160
  case 8:
164
161
  _context.prev = 8;
165
162
  _context.t0 = _context["catch"](1);
166
163
  console.error(_context.t0);
167
- blocks.Notification.error(intl$1.formatMessage({
168
- id: 'materialAssignment.notify.error'
169
- }));
164
+ blocks.Notification.error('오류가 발생했습니다.');
170
165
  case 12:
171
166
  _context.prev = 12;
172
167
  setShowGradeEditModal(false);
@@ -215,27 +210,17 @@ var MaterialAssignmentAdminContentTa = function MaterialAssignmentAdminContentTa
215
210
  children: [jsxRuntime.jsx(blocks.Text, {
216
211
  size: "tiny",
217
212
  role: "gray4",
218
- children: intl$1.formatMessage({
219
- id: 'materialAssignment.score'
220
- })
213
+ children: "\uC810\uC218"
221
214
  }), jsxRuntime.jsx(blocks.Text, {
222
215
  size: "small",
223
216
  role: "white",
224
- children: (gradeResult === null || gradeResult === void 0 ? void 0 : gradeResult.score) && isScoreFinalized ? "".concat(intl$1.formatMessage({
225
- id: 'materialAssignment.table.column.score'
226
- }, {
227
- score: gradeResult.score
228
- })).concat(intl$1.formatMessage({
229
- id: 'materialAssignment.reveal'
230
- })) : '--'
217
+ children: (gradeResult === null || gradeResult === void 0 ? void 0 : gradeResult.score) && isScoreFinalized ? "".concat(gradeResult.score, "\uC810(\uACF5\uAC1C\uB428)") : '--'
231
218
  })]
232
219
  }), jsxRuntime.jsxs(MaterialAssignmentAdmin_styled.StyledMaterialAssignmentAdminHeaderCell, {
233
220
  children: [jsxRuntime.jsx(blocks.Text, {
234
221
  size: "tiny",
235
222
  role: "gray4",
236
- children: intl$1.formatMessage({
237
- id: 'materialAssignment.table.column.lastSubmitDatetime'
238
- })
223
+ children: "\uC81C\uCD9C \uC77C\uC2DC"
239
224
  }), jsxRuntime.jsx(blocks.Text, {
240
225
  size: "small",
241
226
  role: "white",
@@ -260,17 +245,13 @@ var MaterialAssignmentAdminContentTa = function MaterialAssignmentAdminContentTa
260
245
  role: "navy1",
261
246
  size: "small",
262
247
  lineHeight: "1.375rem",
263
- children: user ? "".concat(user.fullname, " ").concat(intl$1.formatMessage({
264
- id: 'materialAssignment.username.subfix'
265
- })) : null
248
+ children: user ? "".concat(user.fullname, " \uB2D8\uC758 \uC810\uC218") : null
266
249
  }), jsxRuntime.jsx(blocks.Hspace, {
267
250
  width: 0.25
268
251
  }), jsxRuntime.jsx(blocks.Tooltip, {
269
252
  useMaxWidth: true,
270
253
  placement: "top",
271
- title: intl$1.formatMessage({
272
- id: 'materialAssignment.modal.grade-result.tooltip'
273
- }),
254
+ title: '최종 점수는 관리자가 모든 채점자의 점수를 고려하여 반영한 후 공개됩니다.',
274
255
  children: jsxRuntime.jsx(blocks.Icon, {
275
256
  icon: icons.eilStatusInfo,
276
257
  color: designTokens.base.color.navy1
@@ -280,13 +261,7 @@ var MaterialAssignmentAdminContentTa = function MaterialAssignmentAdminContentTa
280
261
  }), jsxRuntime.jsx(blocks.Text, {
281
262
  bold: true,
282
263
  role: "white",
283
- children: (gradeResult === null || gradeResult === void 0 ? void 0 : gradeResult.score) && isScoreFinalized ? "".concat(intl$1.formatMessage({
284
- id: 'materialAssignment.table.column.score'
285
- }, {
286
- score: gradeResult.score
287
- })).concat(intl$1.formatMessage({
288
- id: 'materialAssignment.reveal'
289
- })) : '--'
264
+ children: (gradeResult === null || gradeResult === void 0 ? void 0 : gradeResult.score) && isScoreFinalized ? "".concat(gradeResult.score, "\uC810(\uACF5\uAC1C\uB428)") : '--'
290
265
  })]
291
266
  })
292
267
  });
@@ -302,36 +277,28 @@ var MaterialAssignmentAdminContentTa = function MaterialAssignmentAdminContentTa
302
277
  bold: true,
303
278
  role: "danger",
304
279
  size: "small",
305
- children: intl$1.formatMessage({
306
- id: 'materialAssignment.status.deadlineExpired'
307
- })
280
+ children: "\uC81C\uCD9C \uAE30\uD55C \uB9CC\uB8CC"
308
281
  });
309
282
  case isScoreFinalized:
310
283
  return jsxRuntime.jsx(blocks.Text, {
311
284
  bold: true,
312
285
  role: "lightpurple",
313
286
  size: "small",
314
- children: intl$1.formatMessage({
315
- id: 'materialAssignment.status.graded'
316
- })
287
+ children: "\uCC44\uC810 \uC644\uB8CC"
317
288
  });
318
289
  case isUserSubmitted:
319
290
  return jsxRuntime.jsx(blocks.Text, {
320
291
  bold: true,
321
292
  role: "success",
322
293
  size: "small",
323
- children: intl$1.formatMessage({
324
- id: 'materialAssignment.status.submitted'
325
- })
294
+ children: "\uC81C\uCD9C\uB428"
326
295
  });
327
296
  case !isUserSubmitted:
328
297
  return jsxRuntime.jsx(blocks.Text, {
329
298
  bold: true,
330
299
  role: "warning",
331
300
  size: "small",
332
- children: intl$1.formatMessage({
333
- id: 'materialAssignment.status.noSubmitted'
334
- })
301
+ children: "\uBBF8\uC81C\uCD9C"
335
302
  });
336
303
  }
337
304
  }();
@@ -375,17 +342,13 @@ var MaterialAssignmentAdminContentTa = function MaterialAssignmentAdminContentTa
375
342
  children: jsxRuntime.jsxs("tbody", {
376
343
  children: [jsxRuntime.jsxs("tr", {
377
344
  children: [jsxRuntime.jsx("td", {
378
- children: intl$1.formatMessage({
379
- id: 'materialAssignment.table.column.status'
380
- })
345
+ children: "\uC0C1\uD0DC"
381
346
  }), jsxRuntime.jsx("td", {
382
347
  children: statusText
383
348
  })]
384
349
  }), jsxRuntime.jsxs("tr", {
385
350
  children: [jsxRuntime.jsx("td", {
386
- children: intl$1.formatMessage({
387
- id: 'materialAssignment.table.column.deadlineDatetime'
388
- })
351
+ children: "\uACFC\uC81C \uC81C\uCD9C \uAE30\uD55C"
389
352
  }), jsxRuntime.jsx("td", {
390
353
  children: jsxRuntime.jsx(intl.FormattedDate, {
391
354
  value: materialAssignment === null || materialAssignment === void 0 ? void 0 : materialAssignment.closeDatetime,
@@ -395,9 +358,7 @@ var MaterialAssignmentAdminContentTa = function MaterialAssignmentAdminContentTa
395
358
  })]
396
359
  }), jsxRuntime.jsxs("tr", {
397
360
  children: [jsxRuntime.jsx("td", {
398
- children: intl$1.formatMessage({
399
- id: 'materialAssignment.table.column.lastSubmitDatetime'
400
- })
361
+ children: "\uC81C\uCD9C \uC77C\uC2DC"
401
362
  }), jsxRuntime.jsx("td", {
402
363
  children: userSubmission ? jsxRuntime.jsx(intl.FormattedDate, {
403
364
  value: userSubmission.createdDatetime,
@@ -407,9 +368,7 @@ var MaterialAssignmentAdminContentTa = function MaterialAssignmentAdminContentTa
407
368
  })]
408
369
  }), jsxRuntime.jsxs("tr", {
409
370
  children: [jsxRuntime.jsx("td", {
410
- children: intl$1.formatMessage({
411
- id: 'materialAssignment.table.column.uploadedAssignments'
412
- })
371
+ children: "\uC5C5\uB85C\uB4DC\uB41C \uACFC\uC81C"
413
372
  }), jsxRuntime.jsx("td", {
414
373
  children: submissionAttachment
415
374
  })]
@@ -422,17 +381,11 @@ var MaterialAssignmentAdminContentTa = function MaterialAssignmentAdminContentTa
422
381
  var tooltipTitle = function () {
423
382
  switch (true) {
424
383
  case isScoreFinalized:
425
- return intl$1.formatMessage({
426
- id: 'materialAssignment.grade-list.tooltip.scoreFinalized'
427
- });
384
+ return '공개 이후 채점이 불가합니다.';
428
385
  case !isAssignmentClosed:
429
- return intl$1.formatMessage({
430
- id: 'materialAssignment.grade-list.tooltip.not-submitted'
431
- });
386
+ return '제출 기한이 지난 이후 채점할 수 있습니다.';
432
387
  case !isUserSubmitted:
433
- return intl$1.formatMessage({
434
- id: 'materialAssignment.grade-list.tooltip.user-submitted'
435
- });
388
+ return '미제출인 경우 채점할 수 없습니다.';
436
389
  }
437
390
  }();
438
391
  return jsxRuntime.jsxs(blocks.Flex, {
@@ -449,17 +402,13 @@ var MaterialAssignmentAdminContentTa = function MaterialAssignmentAdminContentTa
449
402
  bold: true,
450
403
  role: "white",
451
404
  lineHeight: 1.375,
452
- children: intl$1.formatMessage({
453
- id: 'materialAssignment.my-grading'
454
- })
405
+ children: "\uB0B4 \uCC44\uC810"
455
406
  }), jsxRuntime.jsx(blocks.Text, {
456
407
  block: true,
457
408
  size: "tiny",
458
409
  role: "navy3",
459
410
  lineHeight: 1.6,
460
- children: intl$1.formatMessage({
461
- id: 'materialAssignment.view.information.related'
462
- })
411
+ children: "\uB0B4\uAC00 \uB9E4\uAE34 \uD3C9\uAC00\uC640 \uAD00\uB828\uB41C \uC815\uBCF4\uB97C \uBCFC \uC218 \uC788\uC2B5\uB2C8\uB2E4."
463
412
  })]
464
413
  }), jsxRuntime.jsx(blocks.Tooltip, {
465
414
  placement: "top",
@@ -471,9 +420,7 @@ var MaterialAssignmentAdminContentTa = function MaterialAssignmentAdminContentTa
471
420
  role: "lightpurple",
472
421
  disabled: isGradeEditDisabled,
473
422
  onClick: handleGradeEditClick,
474
- children: intl$1.formatMessage({
475
- id: Boolean(myGrade) ? 'materialAssignment.edit-grading' : 'materialAssignment.start-grading'
476
- })
423
+ children: Boolean(myGrade) ? '내 채점 수정' : '내 채점 시작'
477
424
  })
478
425
  })
479
426
  })]
@@ -481,23 +428,15 @@ var MaterialAssignmentAdminContentTa = function MaterialAssignmentAdminContentTa
481
428
  height: 0.75
482
429
  }), jsxRuntime.jsx(blocks.TableNext, {
483
430
  dark: true,
484
- emptyMessage: intl$1.formatMessage({
485
- id: 'materialAssignment.table.empty-smg.grading-not-start'
486
- }),
431
+ emptyMessage: "\uC544\uC9C1 \uCC44\uC810\uC744 \uC2DC\uC791\uD558\uC9C0 \uC54A\uC558\uC2B5\uB2C8\uB2E4.",
487
432
  columns: [{
488
- Header: intl$1.formatMessage({
489
- id: 'materialAssignment.table-col.fullname'
490
- }),
433
+ Header: '채점자명',
491
434
  accessor: 'fullname'
492
435
  }, {
493
- Header: intl$1.formatMessage({
494
- id: 'materialAssignment.table.column.assignmentScore'
495
- }),
436
+ Header: '과제 점수',
496
437
  accessor: 'grade'
497
438
  }, {
498
- Header: intl$1.formatMessage({
499
- id: 'materialAssignment.table-col.grade-datetime'
500
- }),
439
+ Header: '채점 일시',
501
440
  accessor: 'created',
502
441
  textAlign: 'left'
503
442
  }],
@@ -533,22 +472,16 @@ var MaterialAssignmentAdminContentTa = function MaterialAssignmentAdminContentTa
533
472
  return null;
534
473
  }
535
474
  return jsxRuntime.jsxs(blocks.Modal, {
536
- title: intl$1.formatMessage({
537
- id: Boolean(myGrade) ? 'materialAssignment.edit-grading' : 'materialAssignment.grading-assignments'
538
- }),
475
+ title: Boolean(myGrade) ? '내 채점 수정' : '과제 채점',
539
476
  footerButtons: [{
540
- label: intl$1.formatMessage({
541
- id: 'materialAssignment.modal.button.confirm'
542
- }),
477
+ label: '확인',
543
478
  size: 'small',
544
479
  role: 'primary',
545
480
  loading: gradeEditFormMethods.formState.isSubmitting,
546
481
  disabled: gradeEditFormMethods.formState.isSubmitting || !gradeEditFormMethods.formState.isValid,
547
482
  onClick: handleGradeEditSubmit
548
483
  }, {
549
- label: intl$1.formatMessage({
550
- id: 'materialAssignment.modal.button.cancel'
551
- }),
484
+ label: '취소',
552
485
  size: 'small',
553
486
  role: 'gray1',
554
487
  onClick: function onClick() {
@@ -562,9 +495,7 @@ var MaterialAssignmentAdminContentTa = function MaterialAssignmentAdminContentTa
562
495
  bold: true,
563
496
  block: true,
564
497
  required: true,
565
- children: intl$1.formatMessage({
566
- id: 'materialAssignment.score'
567
- })
498
+ children: "\uC810\uC218"
568
499
  }), jsxRuntime.jsx(blocks.Vspace, {
569
500
  height: 0.5
570
501
  }), jsxRuntime.jsxs(blocks.Flex, {
@@ -593,26 +524,18 @@ var MaterialAssignmentAdminContentTa = function MaterialAssignmentAdminContentTa
593
524
  bold: true,
594
525
  role: "gray9",
595
526
  size: "small",
596
- children: intl$1.formatMessage({
597
- id: 'materialAssignment.dot'
598
- })
527
+ children: "\uC810"
599
528
  }), jsxRuntime.jsx(blocks.Text, {
600
529
  role: "gray6",
601
530
  size: "small",
602
- children: intl$1.formatMessage({
603
- id: 'materialAssignment.table.column.totalPoint'
604
- }, {
605
- point: 100
606
- })
531
+ children: ' / 100점 만점'
607
532
  })]
608
533
  }), jsxRuntime.jsx(blocks.Vspace, {
609
534
  height: 1.25
610
535
  }), jsxRuntime.jsx(blocks.Label, {
611
536
  bold: true,
612
537
  block: true,
613
- children: intl$1.formatMessage({
614
- id: 'materialAssignment.table.header.feedback'
615
- })
538
+ children: "\uD53C\uB4DC\uBC31"
616
539
  }), jsxRuntime.jsx(blocks.Vspace, {
617
540
  height: 0.5
618
541
  }), jsxRuntime.jsx(reactHookForm.Controller, {
@@ -10,7 +10,5 @@ export interface MaterialAssignmentAdminProps {
10
10
  courseRole: enums.CourseRole;
11
11
  updateMaterialUserBrowserResponse?: (userId: number) => void;
12
12
  }
13
- declare const _default: React.ForwardRefExoticComponent<Omit<import("@elice/intl").IntlComponentExtraProps & Omit<import("@elice/intl").IntlComponentExtraProps & Omit<MaterialAssignmentAdminProps, keyof import("@elice/intl").IntlComponentExtraProps | "__intl"> & {
14
- __intl: import("@elice/intl").EliceIntlShape;
15
- } & React.RefAttributes<MaterialAssignmentAdminApis>, keyof import("@elice/intl").IntlComponentExtraProps | "__intl">, "ref"> & React.RefAttributes<MaterialAssignmentAdminApis>>;
16
- export default _default;
13
+ declare const MaterialAssignmentAdmin: React.ForwardRefExoticComponent<MaterialAssignmentAdminProps & React.RefAttributes<MaterialAssignmentAdminApis>>;
14
+ export default MaterialAssignmentAdmin;
@@ -2,18 +2,17 @@ import { jsx } from 'react/jsx-runtime';
2
2
  import { forwardRef } from 'react';
3
3
  import { config } from '@elice/api-client';
4
4
  import { Flex, Spinner } from '@elice/blocks';
5
- import { RawEliceIntlProvider, IntlComponentBuilder } from '@elice/intl';
5
+ import { IntlProvider } from '@elice/intl';
6
6
  import { useMaterialConfigApiClientUpdate } from '@elice/material-shared-utils';
7
7
  import { enums } from '@elice/types';
8
8
  import classnames from 'classnames';
9
- import messageEn from './locales/en.json.js';
10
- import messageKo from './locales/ko.json.js';
11
9
  import MaterialAssignmentAdminContent from './MaterialAssignmentAdminContent.js';
12
10
  import MaterialAssignmentAdminContentTa from './MaterialAssignmentAdminContentTa.js';
13
11
  import { StyledMaterialAssignmentAdminContainer } from './MaterialAssignmentAdmin.styled.js';
14
12
 
15
13
  var MaterialAssignmentAdmin = forwardRef(function (_ref, ref) {
16
- var __intl = _ref.__intl,
14
+ var _ref$locale = _ref.locale,
15
+ locale = _ref$locale === void 0 ? 'en' : _ref$locale,
17
16
  className = _ref.className,
18
17
  materialAssignmentId = _ref.materialAssignmentId,
19
18
  userId = _ref.userId,
@@ -48,12 +47,12 @@ var MaterialAssignmentAdmin = forwardRef(function (_ref, ref) {
48
47
  };
49
48
  return jsx(StyledMaterialAssignmentAdminContainer, {
50
49
  className: classnames(prefixCls, className),
51
- children: jsx(RawEliceIntlProvider, {
52
- value: __intl,
50
+ children: jsx(IntlProvider, {
51
+ locale: locale,
52
+ defaultLocale: "en",
53
53
  children: renderContent()
54
54
  })
55
55
  });
56
56
  });
57
- var MaterialAssignmentAdmin$1 = new IntlComponentBuilder(MaterialAssignmentAdmin).add('en', messageEn).add('ko', messageKo).addAsync('th', import('./locales/th.json.js')).addAsync('ja', import('./locales/ja.json.js')).build();
58
57
 
59
- export { MaterialAssignmentAdmin$1 as default };
58
+ export { MaterialAssignmentAdmin as default };