@elice/material-runbox 1.260820.1 → 1.260825.0-runboxusability.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cjs/components/material-runbox/MaterialRunboxContent.js +1 -2
- package/cjs/components/material-runbox/MaterialRunboxHeader.js +12 -29
- package/cjs/components/material-runbox/actions/MaterialRunboxActionMenu.d.ts +3 -1
- package/cjs/components/material-runbox/actions/MaterialRunboxActionMenu.js +17 -1
- package/cjs/components/material-runbox/hooks/index.d.ts +1 -0
- package/cjs/components/material-runbox/hooks/index.js +4 -0
- package/cjs/components/material-runbox/hooks/useRunboxSessionEndWarning.d.ts +18 -0
- package/cjs/components/material-runbox/hooks/useRunboxSessionEndWarning.js +67 -0
- package/cjs/components/material-runbox/locales/en.json.js +1 -1
- package/cjs/components/material-runbox/locales/ja.json.js +1 -1
- package/cjs/components/material-runbox/locales/ko.json.js +1 -1
- package/cjs/components/material-runbox/locales/th.json.js +1 -1
- package/cjs/components/material-runbox/status/MaterialRunboxStatusButton.d.ts +18 -0
- package/cjs/components/material-runbox/status/MaterialRunboxStatusButton.js +88 -0
- package/cjs/components/material-runbox/status/MaterialRunboxStatusConnectionItem.d.ts +11 -0
- package/cjs/components/material-runbox/status/MaterialRunboxStatusConnectionItem.js +32 -0
- package/cjs/components/material-runbox/status/MaterialRunboxStatusPopover.d.ts +17 -0
- package/cjs/components/material-runbox/status/MaterialRunboxStatusPopover.js +134 -0
- package/cjs/components/material-runbox/status/MaterialRunboxStatusResourceItem.d.ts +11 -0
- package/cjs/components/material-runbox/status/MaterialRunboxStatusResourceItem.js +42 -0
- package/cjs/components/material-runbox/status/index.d.ts +4 -0
- package/cjs/components/material-runbox/status/index.js +9 -0
- package/cjs/components/material-runbox/timer/MaterialRunboxQuotaAlmostEndDialog.d.ts +11 -0
- package/cjs/components/material-runbox/timer/MaterialRunboxQuotaAlmostEndDialog.js +116 -0
- package/cjs/components/material-runbox/timer/MaterialRunboxQuotaAmount.d.ts +13 -0
- package/cjs/components/material-runbox/timer/MaterialRunboxQuotaAmount.js +56 -0
- package/cjs/components/material-runbox/timer/MaterialRunboxQuotaPerSessionAlmostEndDialog.d.ts +12 -0
- package/cjs/components/material-runbox/timer/MaterialRunboxQuotaPerSessionAlmostEndDialog.js +117 -0
- package/cjs/components/material-runbox/timer/MaterialRunboxQuotaTimePart.d.ts +15 -0
- package/cjs/components/material-runbox/timer/MaterialRunboxQuotaTimePart.js +50 -0
- package/cjs/components/material-runbox/timer/MaterialRunboxTimer.d.ts +6 -0
- package/cjs/components/material-runbox/timer/MaterialRunboxTimer.js +20 -16
- package/cjs/components/material-runbox/timer/MaterialRunboxTimerDetailPopover.js +19 -81
- package/es/components/material-runbox/MaterialRunboxContent.js +1 -2
- package/es/components/material-runbox/MaterialRunboxHeader.js +13 -30
- package/es/components/material-runbox/actions/MaterialRunboxActionMenu.d.ts +3 -1
- package/es/components/material-runbox/actions/MaterialRunboxActionMenu.js +19 -3
- package/es/components/material-runbox/hooks/index.d.ts +1 -0
- package/es/components/material-runbox/hooks/index.js +1 -0
- package/es/components/material-runbox/hooks/useRunboxSessionEndWarning.d.ts +18 -0
- package/es/components/material-runbox/hooks/useRunboxSessionEndWarning.js +63 -0
- package/es/components/material-runbox/locales/en.json.js +1 -1
- package/es/components/material-runbox/locales/ja.json.js +1 -1
- package/es/components/material-runbox/locales/ko.json.js +1 -1
- package/es/components/material-runbox/locales/th.json.js +1 -1
- package/es/components/material-runbox/status/MaterialRunboxStatusButton.d.ts +18 -0
- package/es/components/material-runbox/status/MaterialRunboxStatusButton.js +80 -0
- package/es/components/material-runbox/status/MaterialRunboxStatusConnectionItem.d.ts +11 -0
- package/es/components/material-runbox/status/MaterialRunboxStatusConnectionItem.js +28 -0
- package/es/components/material-runbox/status/MaterialRunboxStatusPopover.d.ts +17 -0
- package/es/components/material-runbox/status/MaterialRunboxStatusPopover.js +130 -0
- package/es/components/material-runbox/status/MaterialRunboxStatusResourceItem.d.ts +11 -0
- package/es/components/material-runbox/status/MaterialRunboxStatusResourceItem.js +38 -0
- package/es/components/material-runbox/status/index.d.ts +4 -0
- package/es/components/material-runbox/status/index.js +2 -0
- package/es/components/material-runbox/timer/MaterialRunboxQuotaAlmostEndDialog.d.ts +11 -0
- package/es/components/material-runbox/timer/MaterialRunboxQuotaAlmostEndDialog.js +112 -0
- package/es/components/material-runbox/timer/MaterialRunboxQuotaAmount.d.ts +13 -0
- package/es/components/material-runbox/timer/MaterialRunboxQuotaAmount.js +52 -0
- package/es/components/material-runbox/timer/MaterialRunboxQuotaPerSessionAlmostEndDialog.d.ts +12 -0
- package/es/components/material-runbox/timer/MaterialRunboxQuotaPerSessionAlmostEndDialog.js +113 -0
- package/es/components/material-runbox/timer/MaterialRunboxQuotaTimePart.d.ts +15 -0
- package/es/components/material-runbox/timer/MaterialRunboxQuotaTimePart.js +46 -0
- package/es/components/material-runbox/timer/MaterialRunboxTimer.d.ts +6 -0
- package/es/components/material-runbox/timer/MaterialRunboxTimer.js +19 -15
- package/es/components/material-runbox/timer/MaterialRunboxTimerDetailPopover.js +15 -77
- package/package.json +8 -8
- package/cjs/assets/runbox_logo.png.js +0 -7
- package/cjs/components/material-runbox/MaterialRunboxFooter.d.ts +0 -4
- package/cjs/components/material-runbox/MaterialRunboxFooter.js +0 -64
- package/cjs/components/material-runbox/timer/MaterialRunboxAlmostEndSnackbars.d.ts +0 -6
- package/cjs/components/material-runbox/timer/MaterialRunboxAlmostEndSnackbars.js +0 -90
- package/es/assets/runbox_logo.png.js +0 -3
- package/es/components/material-runbox/MaterialRunboxFooter.d.ts +0 -4
- package/es/components/material-runbox/MaterialRunboxFooter.js +0 -56
- package/es/components/material-runbox/timer/MaterialRunboxAlmostEndSnackbars.d.ts +0 -6
- package/es/components/material-runbox/timer/MaterialRunboxAlmostEndSnackbars.js +0 -86
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
var messageKo = {"common.cancel":"취소","material.tutoring.runbox_confirm_dialog.action.confirm":"진행","material.tutoring.runbox_confirm_dialog.content":"현재 {_termCourseRoleStudent}이/가 실행 중인 런박스 환경입니다. 접속할 경우 남은 런타임 전체 사용 시간이 줄어듭니다. 계속 진행하시겠습니까?","material.tutoring.runbox_confirm_dialog.title":"실행 중인 런박스","runbox.action.autoShutdown.title":"항상 켜두기","runbox.action.autoShutdown.tooltip":"현재 이탈 시 종료되는 실습으로 해당 기능을 사용할 수 없습니다.","runbox.action.grade.dialog.description.error":"코드 또는 제출 파일에 문제가 있어 제출에 실패했습니다.\n아래 오류 메시지를 참고하여 제출 형식이 요구사항에 맞는지 확인한 뒤, 다시 제출해주세요.","runbox.action.grade.dialog.description.success":"채점이 완료되었습니다.","runbox.action.grade.dialog.title":"채점 결과","runbox.action.grade.noti.error":"코드를 채점하는 도중 오류가 발생했습니다.","runbox.action.grade.title":"제출","runbox.action.grade.tooltip.onProgress":"코드 채점이 진행 중 입니다. 잠시만 기다려 주세요. 실습에 따라 채점이 최대 3분까지 소요될 수 있습니다.","runbox.action.reset.dialog.actions.confirm":"초기화","runbox.action.reset.dialog.isolated.description":"런박스 코드를 초기화하시겠습니까? 초기화 시 학습{_termLibraryLecturePage}의 코드가 기본 코드로 덮어씌워집니다.\n초기화 이후 런박스 세션이 새로고침 됩니다.","runbox.action.reset.dialog.shared.description":"런박스 코드를 초기화하시겠습니까? 초기화 시 팀원들의 화면에서도 작성한 코드가 기본 코드로 덮어씌워집니다. 초기화 이후 런박스 세션이 새로고침 됩니다.","runbox.action.reset.noti.error":"런박스 코드를 초기화 하는 중에 오류가 발생했습니다.","runbox.action.reset.title":"코드 초기화","runbox.action.restart.dialog.actions.confirm":"재시작","runbox.action.restart.dialog.isolated.description":"런박스를 재시작 하시겠습니까?","runbox.action.restart.dialog.shared.description":"팀원들의 화면에서도 런박스가 재시작 됩니다. 런박스를 재시작하시겠습니까?","runbox.action.restart.title":"런박스 재시작","runbox.action.share.snackbar.copied.fail":"런박스 URL을 복사에 실패했습니다. 다시 시도해주세요.","runbox.action.share.snackbar.copied.success":"런박스 URL을 복사하였습니다.","runbox.action.share.title":"런박스 URL 복사","runbox.action.submitCountInfo.dialog.description":"제출 횟수 제한을 초과했습니다.","runbox.action.submitCountInfo.dialog.title":"제출 횟수 제한","runbox.action.submitCountInfo.tooltip.disabled":"제출 횟수를 모두 사용했습니다.","runbox.action.submitLog.dialog.download.tooltip":"제출 파일 다운로드","runbox.action.submitLog.dialog.title":"제출 이력","runbox.action.submitLog.empty":"제출 이력이 존재하지 않습니다.","runbox.action.submitLog.title":"런박스 제출 이력","runbox.action.disconnect.dialog.title":"런박스 연결 해제","runbox.action.disconnect.dialog.description":"현재 실습을 진행중 입니다. 런박스를 연결 해제하시겠습니까?\n저장하지 않은 내용이 있다면 먼저 저장해 주세요.","runbox.action.disconnect.dialog.disconnect":"연결 해제","runbox.action.disconnect.title":"연결 해제","runbox.action.menu.title":"더보기","runbox.alert.title":"현재 학생이 실행 중인 환경에 접속하였기 때문에, 런타임 전체 사용 시간이 차감되고 있습니다. 학생이 런박스를 종료하더라도, 튜터링을 진행하면 시간이 계속 차감되니 유의해 주세요.","runbox.common.close":"닫기","runbox.common.retry":"재시도","runbox.common.score":"{score}점","runbox.common.support":"고객센터","runbox.common.connect":"연결하기","runbox.context.command.ping.error":"런박스 작업을 수행하는 도중 오류가 발생했습니다.","runbox.header.submitInfo":"{isIndividual, select, true {} other {팀}} 제출 횟수 | {isDailyLimitEnabled, select, true {오늘} other {}} {remainCount}/{totalCount}회 남음","runbox.timer.title":"남은 시간","runbox.timer.unlimited":"제한없음","runbox.timer.tooltip.title":"시간 안내 보기","runbox.timer.popover.title":"런박스 사용 시간 안내","runbox.timer.popover.description":"{user}님의 런박스 총 사용 시간입니다.\n연결 중에는 시간이 계속 차감되며, 연결을 종료하거나 수업을 나가면 차감이 멈춥니다.","runbox.timer.popover.quota.title":"총 사용 가능 시간","runbox.timer.popover.quota_per_session.title":"이번
|
|
1
|
+
var messageKo = {"common.cancel":"취소","material.tutoring.runbox_confirm_dialog.action.confirm":"진행","material.tutoring.runbox_confirm_dialog.content":"현재 {_termCourseRoleStudent}이/가 실행 중인 런박스 환경입니다. 접속할 경우 남은 런타임 전체 사용 시간이 줄어듭니다. 계속 진행하시겠습니까?","material.tutoring.runbox_confirm_dialog.title":"실행 중인 런박스","runbox.action.autoShutdown.title":"항상 켜두기","runbox.action.autoShutdown.tooltip":"현재 이탈 시 종료되는 실습으로 해당 기능을 사용할 수 없습니다.","runbox.action.grade.dialog.description.error":"코드 또는 제출 파일에 문제가 있어 제출에 실패했습니다.\n아래 오류 메시지를 참고하여 제출 형식이 요구사항에 맞는지 확인한 뒤, 다시 제출해주세요.","runbox.action.grade.dialog.description.success":"채점이 완료되었습니다.","runbox.action.grade.dialog.title":"채점 결과","runbox.action.grade.noti.error":"코드를 채점하는 도중 오류가 발생했습니다.","runbox.action.grade.title":"제출","runbox.action.grade.tooltip.onProgress":"코드 채점이 진행 중 입니다. 잠시만 기다려 주세요. 실습에 따라 채점이 최대 3분까지 소요될 수 있습니다.","runbox.action.reset.dialog.actions.confirm":"초기화","runbox.action.reset.dialog.isolated.description":"런박스 코드를 초기화하시겠습니까? 초기화 시 학습{_termLibraryLecturePage}의 코드가 기본 코드로 덮어씌워집니다.\n초기화 이후 런박스 세션이 새로고침 됩니다.","runbox.action.reset.dialog.shared.description":"런박스 코드를 초기화하시겠습니까? 초기화 시 팀원들의 화면에서도 작성한 코드가 기본 코드로 덮어씌워집니다. 초기화 이후 런박스 세션이 새로고침 됩니다.","runbox.action.reset.noti.error":"런박스 코드를 초기화 하는 중에 오류가 발생했습니다.","runbox.action.reset.title":"코드 초기화","runbox.action.restart.dialog.actions.confirm":"재시작","runbox.action.restart.dialog.isolated.description":"런박스를 재시작 하시겠습니까?","runbox.action.restart.dialog.shared.description":"팀원들의 화면에서도 런박스가 재시작 됩니다. 런박스를 재시작하시겠습니까?","runbox.action.restart.title":"런박스 재시작","runbox.action.share.snackbar.copied.fail":"런박스 URL을 복사에 실패했습니다. 다시 시도해주세요.","runbox.action.share.snackbar.copied.success":"런박스 URL을 복사하였습니다.","runbox.action.share.title":"런박스 URL 복사","runbox.action.submitCountInfo.dialog.description":"제출 횟수 제한을 초과했습니다.","runbox.action.submitCountInfo.dialog.title":"제출 횟수 제한","runbox.action.submitCountInfo.tooltip.disabled":"제출 횟수를 모두 사용했습니다.","runbox.action.submitLog.dialog.download.tooltip":"제출 파일 다운로드","runbox.action.submitLog.dialog.title":"제출 이력","runbox.action.submitLog.empty":"제출 이력이 존재하지 않습니다.","runbox.action.submitLog.title":"런박스 제출 이력","runbox.action.disconnect.dialog.title":"런박스 연결 해제","runbox.action.disconnect.dialog.description":"현재 실습을 진행중 입니다. 런박스를 연결 해제하시겠습니까?\n저장하지 않은 내용이 있다면 먼저 저장해 주세요.","runbox.action.disconnect.dialog.disconnect":"연결 해제","runbox.action.disconnect.title":"연결 해제","runbox.action.menu.title":"더보기","runbox.alert.title":"현재 학생이 실행 중인 환경에 접속하였기 때문에, 런타임 전체 사용 시간이 차감되고 있습니다. 학생이 런박스를 종료하더라도, 튜터링을 진행하면 시간이 계속 차감되니 유의해 주세요.","runbox.common.close":"닫기","runbox.common.retry":"재시도","runbox.common.score":"{score}점","runbox.common.support":"고객센터","runbox.common.connect":"연결하기","runbox.context.command.ping.error":"런박스 작업을 수행하는 도중 오류가 발생했습니다.","runbox.header.submitInfo":"{isIndividual, select, true {} other {팀}} 제출 횟수 | {isDailyLimitEnabled, select, true {오늘} other {}} {remainCount}/{totalCount}회 남음","runbox.timer.title":"남은 시간","runbox.timer.unlimited":"제한없음","runbox.timer.tooltip.title":"시간 안내 보기","runbox.timer.popover.title":"런박스 사용 시간 안내","runbox.timer.popover.description":"{user}님의 런박스 총 사용 시간입니다.\n연결 중에는 시간이 계속 차감되며, 연결을 종료하거나 수업을 나가면 차감이 멈춥니다.","runbox.timer.popover.quota.title":"총 사용 가능 시간","runbox.timer.popover.quota_per_session.title":"이번 접속에서 사용할 수 있는 시간","runbox.timer.popover.quota_per_session.description":"한 번 접속하면 최대 {time}까지 사용할 수 있습니다. 총 사용 가능 시간이 남아 있으면 다시 접속해 이어서 실습할 수 있습니다.","runbox.timer.popover.quota.disconnect":"연결 해제","runbox.timer.popover.do_not_open":"런박스 실습 시 해당 팝업을 열지않기","runbox.timer.almost_end.dialog.quota.title":"총 사용 가능 시간 {time} 남았습니다.","runbox.timer.almost_end.dialog.quota.description":"총 사용 가능 시간이 모두 소진되면 실습이 종료되며, 더 이상 접속할 수 없습니다.\n작업 중인 내용은 저장 후 종료해 주세요. 저장하지 않은 내용은 사라질 수 있습니다.","runbox.timer.almost_end.dialog.quota_per_session.title":"이번 접속 시간이 {time} 남았습니다.","runbox.timer.almost_end.dialog.quota_per_session.description":"접속 시간이 종료되면 연결이 종료됩니다. 총 사용 가능 시간이 남아 있으면 다시 접속해 이어서 실습할 수 있습니다.\n작업 중인 내용은 저장 후 종료해 주세요. 저장한 파일은 다시 접속해도 유지되며, 저장하지 않은 내용은 사라질 수 있습니다.","runbox.timer.almost_end.dialog.confirm":"계속하기","runbox.disk.almost_full.snackbar.almost_full":"디스크 잔여 용량이 {capacity}입니다. 용량이 모두 소진되면 실습이 종료되니,\n진행 중인 작업을 지금 저장해 주세요.","runbox.runtime.message.lxp_plan_required":"현재 기관에서는 런박스 수업 자료를 학습할 수 없습니다.\n자세한 사항은 기관 관리자에게 문의하세요.","runbox.runtime.message.runbox_unavailable":"런박스 사용 불가","runbox.runtime.message.startError":"런박스를 시작하는 중에 오류가 발생했습니다.","runbox.runtime.overlay.assigned.description":"(3 / 3)\n런박스가 실행 중입니다.\n잠시만 기다려주세요!","runbox.runtime.overlay.assigned.description_timeout":"(3 / 3)\n런박스를 실행하는데\n예상보다 시간이 소요되고 있습니다.\n새로고침하지 말고 조금만 더 기다려주세요!","runbox.runtime.overlay.queued.description":"(2 / 3)\n현재 {waiters}번째 대기 중입니다...","runbox.runtime.overlay.queued.description_zero":"(2 / 3)\n곧 런박스가 실행됩니다.","runbox.runtime.overlay.terminated.description.default":"런박스 실습을 진행하시려면, 연결하기 버튼을 눌러주세요.","runbox.runtime.overlay.terminated.description.os_disk_is_full":"디스크 용량을 모두 소진하여 실습이 종료되었습니다.","runbox.runtime.overlay.terminated.description.quota_exceeded":"런타임 사용시간이 만료되어 런타임이 종료되었습니다.","runbox.runtime.overlay.terminated.description.quota_per_session_exceeded":"런박스 세션당 사용시간이 만료되어 런타임이 종료되었습니다.\n런박스를 재접속하려면 아래 버튼을 눌러주세요.","runbox.runtime.overlay.terminated.title":"연결 해제","runbox.runtime.overlay.terminated.connect":"연결하기","runbox.runtime.overlay.terminated.unlimited":"제한 없음","runbox.runtime.overlay.terminated.contact":"고객센터 문의하기","runbox.runtime.overlay.terminated.quota.total":"전체 사용 가능 시간","runbox.runtime.overlay.terminated.quota.used":"총 사용 시간","runbox.runtime.overlay.terminated.disk.total":"전체 디스크","runbox.runtime.overlay.terminated.disk.used":"총 사용 디스크","runbox.runtime.overlay.conflicted.description":"이 런박스 실습을 연결하면 다른 수업자료의 런박스는 종료됩니다.\n저장하지 않은 내용이 있다면 먼저 저장해 주세요.","runbox.runtime.overlay.conflicted.title":"현재 다른 수업자료에 런박스가 연결되어 있습니다","runbox.runtime.dialog.change_material.title":"런박스 연결 변경 안내","runbox.runtime.dialog.change_material.description":"이 런박스 실습을 연결하면 다른 수업자료의 런박스는 종료됩니다. 계속하시겠습니까?","runbox.status.button.title":"연결 상태 및 리소스","runbox.status.network":"네트워크 상태","runbox.status.runtime.connected":"런타임 연결됨","runbox.status.runtime.disconnected":"런타임 연결 끊김"};
|
|
2
2
|
|
|
3
3
|
export { messageKo as default };
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
var th = {"common.cancel":"ยกเลิก","material.tutoring.runbox_confirm_dialog.action.confirm":"ดำเนินการ","material.tutoring.runbox_confirm_dialog.content":"ขณะนี้นักเรียน {_termCourseRoleStudent} กำลังทำงานในสภาพแวดล้อม Runbox หากคุณเชื่อมต่อ เวลาที่เหลือสำหรับการใช้งานรันไทม์ทั้งหมดจะลดลง คุณต้องการดำเนินการต่อหรือไม่?","material.tutoring.runbox_confirm_dialog.title":"รันบ็อกซ์กำลังทำงาน","runbox.action.autoShutdown.title":"เปิดตลอดเวลา","runbox.action.autoShutdown.tooltip":"คุณสมบัตินี้ไม่สามารถใช้งานได้ในเซสชันนี้ เนื่องจากมีการตั้งค่าให้ปิดการทำงานอัตโนมัติเมื่อออก","runbox.action.grade.dialog.description.error":"มีปัญหาในโค้ดหรือไฟล์ที่ส่ง\nกรุณาตรวจสอบข้อความข้อผิดพลาดด้านล่างและตรวจสอบว่ารูปแบบการส่งตรงกับความต้องการ จากนั้นส่งอีกครั้ง","runbox.action.grade.dialog.description.success":"การจัดเกรดเสร็จสมบูรณ์เรียบร้อยแล้ว","runbox.action.grade.dialog.title":"ผลการประเมินผลการเรียน","runbox.action.grade.noti.error":"เกิดข้อผิดพลาดขึ้นในขณะที่ทำการตรวจคะแนนของโค้ด","runbox.action.grade.title":"ส่ง","runbox.action.grade.tooltip.onProgress":"กำลังให้คะแนนโค้ด โปรดรอสักครู่ การให้คะแนนอาจใช้เวลาสูงสุด 3 นาที ขึ้นอยู่กับประเภทของการฝึกอบรม","runbox.action.reset.dialog.actions.confirm":"รีเซ็ต","runbox.action.reset.dialog.isolated.description":"ต้องการรีเซ็ตโค้ด Runbox หรือไม่? การรีเซ็ตจะแทนที่โค้ดของคุณด้วยโค้ดเริ่มต้นของหน้าเรียน {_termLibraryLecturePage} \nเซสชัน Runbox จะรีเฟรชหลังจากรีเซ็ต","runbox.action.reset.dialog.shared.description":"คุณต้องการรีเซ็ตโค้ดของ Runbox หรือไม่? หากทำการรีเซ็ต โค้ดที่ทีมเขียนไว้จะถูกเขียนทับด้วยโค้ดเริ่มต้น และเซสชันของ Runbox จะถูกรีเฟรชหลังจากนั้น","runbox.action.reset.noti.error":"เกิดข้อผิดพลาดระหว่างการรีเซ็ตโค้ด Runbox","runbox.action.reset.title":"รีเซ็ตโค้ด","runbox.action.restart.dialog.actions.confirm":"เริ่มต้นใหม่","runbox.action.restart.dialog.isolated.description":"ต้องการเริ่มต้น Runbox ใหม่หรือไม่?","runbox.action.restart.dialog.shared.description":"Runbox จะเริ่มต้นใหม่บนหน้าจอของเพื่อนร่วมทีมด้วย คุณต้องการเริ่มต้น Runbox ใหม่หรือไม่?","runbox.action.restart.title":"เริ่มต้น Runbox ใหม่","runbox.action.share.snackbar.copied.fail":"ล้มเหลวในการคัดลอก URL Runbox กรุณาลองอีกครั้ง","runbox.action.share.snackbar.copied.success":"คัดลอก URL Runbox สำเร็จ","runbox.action.share.title":"คัดลอก URL Runbox","runbox.action.submitCountInfo.dialog.description":"คุณใช้จำนวนครั้งในการส่งเกินขีดจำกัดแล้ว","runbox.action.submitCountInfo.dialog.title":"ข้อจำกัดจำนวนครั้งในการส่ง","runbox.action.submitCountInfo.tooltip.disabled":"คุณใช้จำนวนครั้งในการส่งทั้งหมดแล้ว","runbox.action.submitLog.dialog.download.tooltip":"ดาวน์โหลดไฟล์ที่ส่ง","runbox.action.submitLog.dialog.title":"ประวัติการส่ง","runbox.action.submitLog.empty":"ไม่มีประวัติการส่ง","runbox.action.submitLog.title":"ประวัติการส่ง Runbox","runbox.action.disconnect.dialog.title":"ยกเลิกการเชื่อมต่อ Runbox","runbox.action.disconnect.dialog.description":"คุณกำลังอยู่ในระหว่างการฝึกปฏิบัติ ต้องการยกเลิกการเชื่อมต่อ Runbox หรือไม่?\nหากมีงานที่ยังไม่ได้บันทึก กรุณาบันทึกก่อน","runbox.action.disconnect.dialog.disconnect":"ยกเลิกการเชื่อมต่อ","runbox.action.disconnect.title":"ยกเลิกการเชื่อมต่อ","runbox.action.menu.title":"เพิ่มเติม","runbox.alert.title":"คุณได้เชื่อมต่อกับสภาพแวดล้อมที่นักเรียนกำลังทำงานอยู่ และเวลาใช้งานรันไทม์ทั้งหมดกำลังถูกหัก โปรดทราบว่าหากนักเรียนออกจากรันบ็อกซ์ แต่การให้คำปรึกษายังดำเนินต่อไป เวลาจะยังคงถูกหัก","runbox.common.close":"ปิด","runbox.common.retry":"ลองใหม่","runbox.common.score":"{score} คะแนน","runbox.common.support":"สนับสนุน","runbox.common.connect":"เชื่อมต่อ","runbox.context.command.ping.error":"เกิดข้อผิดพลาดขณะดำเนินการ Runbox","runbox.header.submitInfo":"{isIndividual, select, true {การส่งแบบส่วนตัว} other {การส่งแบบทีม}} | {remainCount}/{totalCount} ครั้งที่เหลือ | {isDailyLimitEnabled, select, true {วันนี้} other {}} ","runbox.timer.title":"เวลาที่เหลือ","runbox.timer.unlimited":"ไม่จำกัด","runbox.timer.tooltip.title":"ดูข้อมูลเวลา","runbox.timer.popover.title":"คู่มือเวลาใช้งาน Runbox","runbox.timer.popover.description":"นี่คือเวลาใช้งาน Runbox ทั้งหมดของ {user}\nเวลาจะถูกหักออกอย่างต่อเนื่องขณะเชื่อมต่อ ยกเลิกการเชื่อมต่อหรือออกจากบทเรียนเพื่อหยุดการหักเวลา","runbox.timer.popover.quota.title":"เวลาที่สามารถใช้งานได้ทั้งหมด","runbox.timer.popover.quota_per_session.title":"
|
|
1
|
+
var th = {"common.cancel":"ยกเลิก","material.tutoring.runbox_confirm_dialog.action.confirm":"ดำเนินการ","material.tutoring.runbox_confirm_dialog.content":"ขณะนี้นักเรียน {_termCourseRoleStudent} กำลังทำงานในสภาพแวดล้อม Runbox หากคุณเชื่อมต่อ เวลาที่เหลือสำหรับการใช้งานรันไทม์ทั้งหมดจะลดลง คุณต้องการดำเนินการต่อหรือไม่?","material.tutoring.runbox_confirm_dialog.title":"รันบ็อกซ์กำลังทำงาน","runbox.action.autoShutdown.title":"เปิดตลอดเวลา","runbox.action.autoShutdown.tooltip":"คุณสมบัตินี้ไม่สามารถใช้งานได้ในเซสชันนี้ เนื่องจากมีการตั้งค่าให้ปิดการทำงานอัตโนมัติเมื่อออก","runbox.action.grade.dialog.description.error":"มีปัญหาในโค้ดหรือไฟล์ที่ส่ง\nกรุณาตรวจสอบข้อความข้อผิดพลาดด้านล่างและตรวจสอบว่ารูปแบบการส่งตรงกับความต้องการ จากนั้นส่งอีกครั้ง","runbox.action.grade.dialog.description.success":"การจัดเกรดเสร็จสมบูรณ์เรียบร้อยแล้ว","runbox.action.grade.dialog.title":"ผลการประเมินผลการเรียน","runbox.action.grade.noti.error":"เกิดข้อผิดพลาดขึ้นในขณะที่ทำการตรวจคะแนนของโค้ด","runbox.action.grade.title":"ส่ง","runbox.action.grade.tooltip.onProgress":"กำลังให้คะแนนโค้ด โปรดรอสักครู่ การให้คะแนนอาจใช้เวลาสูงสุด 3 นาที ขึ้นอยู่กับประเภทของการฝึกอบรม","runbox.action.reset.dialog.actions.confirm":"รีเซ็ต","runbox.action.reset.dialog.isolated.description":"ต้องการรีเซ็ตโค้ด Runbox หรือไม่? การรีเซ็ตจะแทนที่โค้ดของคุณด้วยโค้ดเริ่มต้นของหน้าเรียน {_termLibraryLecturePage} \nเซสชัน Runbox จะรีเฟรชหลังจากรีเซ็ต","runbox.action.reset.dialog.shared.description":"คุณต้องการรีเซ็ตโค้ดของ Runbox หรือไม่? หากทำการรีเซ็ต โค้ดที่ทีมเขียนไว้จะถูกเขียนทับด้วยโค้ดเริ่มต้น และเซสชันของ Runbox จะถูกรีเฟรชหลังจากนั้น","runbox.action.reset.noti.error":"เกิดข้อผิดพลาดระหว่างการรีเซ็ตโค้ด Runbox","runbox.action.reset.title":"รีเซ็ตโค้ด","runbox.action.restart.dialog.actions.confirm":"เริ่มต้นใหม่","runbox.action.restart.dialog.isolated.description":"ต้องการเริ่มต้น Runbox ใหม่หรือไม่?","runbox.action.restart.dialog.shared.description":"Runbox จะเริ่มต้นใหม่บนหน้าจอของเพื่อนร่วมทีมด้วย คุณต้องการเริ่มต้น Runbox ใหม่หรือไม่?","runbox.action.restart.title":"เริ่มต้น Runbox ใหม่","runbox.action.share.snackbar.copied.fail":"ล้มเหลวในการคัดลอก URL Runbox กรุณาลองอีกครั้ง","runbox.action.share.snackbar.copied.success":"คัดลอก URL Runbox สำเร็จ","runbox.action.share.title":"คัดลอก URL Runbox","runbox.action.submitCountInfo.dialog.description":"คุณใช้จำนวนครั้งในการส่งเกินขีดจำกัดแล้ว","runbox.action.submitCountInfo.dialog.title":"ข้อจำกัดจำนวนครั้งในการส่ง","runbox.action.submitCountInfo.tooltip.disabled":"คุณใช้จำนวนครั้งในการส่งทั้งหมดแล้ว","runbox.action.submitLog.dialog.download.tooltip":"ดาวน์โหลดไฟล์ที่ส่ง","runbox.action.submitLog.dialog.title":"ประวัติการส่ง","runbox.action.submitLog.empty":"ไม่มีประวัติการส่ง","runbox.action.submitLog.title":"ประวัติการส่ง Runbox","runbox.action.disconnect.dialog.title":"ยกเลิกการเชื่อมต่อ Runbox","runbox.action.disconnect.dialog.description":"คุณกำลังอยู่ในระหว่างการฝึกปฏิบัติ ต้องการยกเลิกการเชื่อมต่อ Runbox หรือไม่?\nหากมีงานที่ยังไม่ได้บันทึก กรุณาบันทึกก่อน","runbox.action.disconnect.dialog.disconnect":"ยกเลิกการเชื่อมต่อ","runbox.action.disconnect.title":"ยกเลิกการเชื่อมต่อ","runbox.action.menu.title":"เพิ่มเติม","runbox.alert.title":"คุณได้เชื่อมต่อกับสภาพแวดล้อมที่นักเรียนกำลังทำงานอยู่ และเวลาใช้งานรันไทม์ทั้งหมดกำลังถูกหัก โปรดทราบว่าหากนักเรียนออกจากรันบ็อกซ์ แต่การให้คำปรึกษายังดำเนินต่อไป เวลาจะยังคงถูกหัก","runbox.common.close":"ปิด","runbox.common.retry":"ลองใหม่","runbox.common.score":"{score} คะแนน","runbox.common.support":"สนับสนุน","runbox.common.connect":"เชื่อมต่อ","runbox.context.command.ping.error":"เกิดข้อผิดพลาดขณะดำเนินการ Runbox","runbox.header.submitInfo":"{isIndividual, select, true {การส่งแบบส่วนตัว} other {การส่งแบบทีม}} | {remainCount}/{totalCount} ครั้งที่เหลือ | {isDailyLimitEnabled, select, true {วันนี้} other {}} ","runbox.timer.title":"เวลาที่เหลือ","runbox.timer.unlimited":"ไม่จำกัด","runbox.timer.tooltip.title":"ดูข้อมูลเวลา","runbox.timer.popover.title":"คู่มือเวลาใช้งาน Runbox","runbox.timer.popover.description":"นี่คือเวลาใช้งาน Runbox ทั้งหมดของ {user}\nเวลาจะถูกหักออกอย่างต่อเนื่องขณะเชื่อมต่อ ยกเลิกการเชื่อมต่อหรือออกจากบทเรียนเพื่อหยุดการหักเวลา","runbox.timer.popover.quota.title":"เวลาที่สามารถใช้งานได้ทั้งหมด","runbox.timer.popover.quota_per_session.title":"เวลาที่ใช้ได้ในการเชื่อมต่อครั้งนี้","runbox.timer.popover.quota_per_session.description":"การเชื่อมต่อหนึ่งครั้งใช้ได้สูงสุด {time} หากยังมีเวลาใช้งานทั้งหมดเหลืออยู่ คุณสามารถเชื่อมต่อใหม่เพื่อฝึกปฏิบัติต่อได้","runbox.timer.popover.quota.disconnect":"ตัดการเชื่อมต่อ","runbox.timer.popover.do_not_open":"ไม่แสดงป๊อปอัปนี้เมื่อเริ่มเซสชัน","runbox.timer.almost_end.dialog.quota.title":"เหลือเวลาใช้งานทั้งหมด {time}","runbox.timer.almost_end.dialog.quota.description":"เมื่อเวลาใช้งานทั้งหมดหมดลง การฝึกปฏิบัติจะสิ้นสุดและไม่สามารถเชื่อมต่อได้อีก\nกรุณาบันทึกงานของคุณก่อนสิ้นสุด งานที่ไม่ได้บันทึกอาจสูญหาย","runbox.timer.almost_end.dialog.quota_per_session.title":"เหลือเวลาในการเชื่อมต่อครั้งนี้ {time}","runbox.timer.almost_end.dialog.quota_per_session.description":"เมื่อเวลาเชื่อมต่อสิ้นสุด ระบบจะตัดการเชื่อมต่อ หากยังมีเวลาใช้งานทั้งหมดเหลืออยู่ คุณสามารถเชื่อมต่อใหม่เพื่อฝึกปฏิบัติต่อได้\nกรุณาบันทึกงานของคุณก่อนสิ้นสุด ไฟล์ที่บันทึกไว้จะยังคงอยู่เมื่อเชื่อมต่อใหม่ แต่งานที่ไม่ได้บันทึกอาจสูญหาย","runbox.timer.almost_end.dialog.confirm":"ดำเนินการต่อ","runbox.disk.almost_full.snackbar.almost_full":"พื้นที่ดิสก์ที่เหลืออยู่คือ {capacity} หากพื้นที่หมด การฝึกปฏิบัติจะสิ้นสุดลง กรุณาบันทึกงานที่กำลังทำอยู่ตอนนี้","runbox.runtime.message.lxp_plan_required":"ขณะนี้สถาบันของคุณไม่รองรับการใช้งานสื่อการเรียนการสอน Runbox\nโปรดติดต่อผู้ดูแลระบบของสถาบันของคุณสำหรับข้อมูลเพิ่มเติม","runbox.runtime.message.runbox_unavailable":"ไม่สามารถใช้ Runbox ได้","runbox.runtime.message.startError":"เกิดข้อผิดพลาดขณะเริ่ม Runbox","runbox.runtime.overlay.assigned.description":"(3 / 3)\nRunbox กำลังทำงานอยู่\nกรุณารอสักครู่!","runbox.runtime.overlay.assigned.description_timeout":"(3 / 3)\nRunbox ใช้เวลานานกว่าที่คาดไว้ในการทำงาน\nกรุณาอย่ารีเฟรชและรอสักครู่!","runbox.runtime.overlay.queued.description":"(2 / 3)\nกำลังรอคิวอยู่ที่ {waiters}...","runbox.runtime.overlay.queued.description_zero":"(2 / 3)\nRunbox ของคุณจะเริ่มทำงานเร็วๆ นี้","runbox.runtime.overlay.terminated.description.default":"หากต้องการดำเนินการฝึก Runbox ต่อ กรุณาคลิกปุ่มเชื่อมต่อ","runbox.runtime.overlay.terminated.description.os_disk_is_full":"พื้นที่ดิสก์ถูกใช้งานจนหมดแล้ว การฝึกปฏิบัติได้สิ้นสุดลง","runbox.runtime.overlay.terminated.description.quota_exceeded":"รันไทม์ถูกยกเลิกเนื่องจากเวลาการใช้งานหมดอายุแล้ว","runbox.runtime.overlay.terminated.description.quota_per_session_exceeded":"รันไทม์ถูกยกเลิกเนื่องจากเวลาการใช้งานต่อเซสชันหมดอายุแล้ว\nหากต้องการเชื่อมต่อกับ Runbox อีกครั้ง กรุณากดปุ่มด้านล่าง","runbox.runtime.overlay.terminated.title":"การเชื่อมต่อถูกยกเลิก","runbox.runtime.overlay.terminated.connect":"เชื่อมต่อ","runbox.runtime.overlay.terminated.unlimited":"ไม่จำกัด","runbox.runtime.overlay.terminated.contact":"ติดต่อฝ่ายบริการลูกค้า","runbox.runtime.overlay.terminated.quota.total":"เวลาที่สามารถใช้งานได้ทั้งหมด","runbox.runtime.overlay.terminated.quota.used":"เวลาที่ใช้ไปทั้งหมด","runbox.runtime.overlay.terminated.disk.total":"พื้นที่ดิสก์ทั้งหมด","runbox.runtime.overlay.terminated.disk.used":"พื้นที่ดิสก์ที่ใช้ไปทั้งหมด","runbox.runtime.overlay.conflicted.description":"การเชื่อมต่อกับการฝึก Runbox นี้จะยุติการทำงานของ Runbox ในสื่อการสอนอื่น\nกรุณาบันทึกงานที่ยังไม่ได้บันทึกก่อน","runbox.runtime.overlay.conflicted.title":"ขณะนี้ Runbox เชื่อมต่อกับสื่อการสอนอื่นอยู่","runbox.runtime.dialog.change_material.title":"ประกาศการเปลี่ยนการเชื่อมต่อ Runbox","runbox.runtime.dialog.change_material.description":"การเชื่อมต่อกับการฝึก Runbox นี้จะยุติการทำงานของ Runbox ในสื่อการสอนอื่น คุณต้องการดำเนินการต่อหรือไม่?","runbox.status.button.title":"สถานะการเชื่อมต่อและทรัพยากร","runbox.status.network":"สถานะเครือข่าย","runbox.status.runtime.connected":"รันไทม์เชื่อมต่อแล้ว","runbox.status.runtime.disconnected":"รันไทม์ถูกตัดการเชื่อมต่อ"};
|
|
2
2
|
|
|
3
3
|
export { th as default };
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export interface MaterialRunboxStatusButtonProps {
|
|
3
|
+
/**
|
|
4
|
+
* Bottom action slot of the popover.
|
|
5
|
+
*
|
|
6
|
+
* NOTICE: the "실습 환경 초기화" button is out of scope for PLAT-4181.
|
|
7
|
+
* PLAT-4184 injects it here.
|
|
8
|
+
*/
|
|
9
|
+
bottomAction?: React.ReactNode;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* Opens the runbox connection/resource status popover.
|
|
13
|
+
*
|
|
14
|
+
* Replaces the always-visible resource stats of the removed footer,
|
|
15
|
+
* so the numbers are only shown on explicit request. (`[R-5]` `[R-6]`)
|
|
16
|
+
*/
|
|
17
|
+
declare const MaterialRunboxStatusButton: React.FC<MaterialRunboxStatusButtonProps>;
|
|
18
|
+
export default MaterialRunboxStatusButton;
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
import { slicedToArray as _slicedToArray, defineProperty as _defineProperty } from '../../../_virtual/_rollupPluginBabelHelpers.js';
|
|
2
|
+
import { jsxs, Fragment, jsx } from 'react/jsx-runtime';
|
|
3
|
+
import React from 'react';
|
|
4
|
+
import { useRawEliceIntl } from '@elice/intl';
|
|
5
|
+
import { EliceIcon } from '@elice/mui-elements';
|
|
6
|
+
import { useEliceRunboxRunning } from '@elice/runbox-client';
|
|
7
|
+
import { faAngleDown, faWifi } from '@fortawesome/pro-solid-svg-icons';
|
|
8
|
+
import { Button, buttonClasses } from '@mui/material';
|
|
9
|
+
import MaterialRunboxStatusPopover from './MaterialRunboxStatusPopover.js';
|
|
10
|
+
|
|
11
|
+
//
|
|
12
|
+
//
|
|
13
|
+
//
|
|
14
|
+
/**
|
|
15
|
+
* Opens the runbox connection/resource status popover.
|
|
16
|
+
*
|
|
17
|
+
* Replaces the always-visible resource stats of the removed footer,
|
|
18
|
+
* so the numbers are only shown on explicit request. (`[R-5]` `[R-6]`)
|
|
19
|
+
*/
|
|
20
|
+
var MaterialRunboxStatusButton = function MaterialRunboxStatusButton(_ref) {
|
|
21
|
+
var bottomAction = _ref.bottomAction;
|
|
22
|
+
var intl = useRawEliceIntl();
|
|
23
|
+
var _useEliceRunboxRunnin = useEliceRunboxRunning(),
|
|
24
|
+
status = _useEliceRunboxRunnin.status;
|
|
25
|
+
var _React$useState = React.useState(null),
|
|
26
|
+
_React$useState2 = _slicedToArray(_React$useState, 2),
|
|
27
|
+
anchorEl = _React$useState2[0],
|
|
28
|
+
setAnchorEl = _React$useState2[1];
|
|
29
|
+
var isRunboxRunning = status === 'running';
|
|
30
|
+
/**
|
|
31
|
+
*
|
|
32
|
+
*/
|
|
33
|
+
var handleClose = function handleClose() {
|
|
34
|
+
setAnchorEl(null);
|
|
35
|
+
};
|
|
36
|
+
//
|
|
37
|
+
//
|
|
38
|
+
//
|
|
39
|
+
return jsxs(Fragment, {
|
|
40
|
+
children: [jsx(Button, {
|
|
41
|
+
variant: "text",
|
|
42
|
+
size: "small",
|
|
43
|
+
startIcon: jsx(EliceIcon, {
|
|
44
|
+
icon: faWifi
|
|
45
|
+
}),
|
|
46
|
+
endIcon: jsx(EliceIcon, {
|
|
47
|
+
icon: faAngleDown
|
|
48
|
+
}),
|
|
49
|
+
sx: _defineProperty({}, "& .".concat(buttonClasses.startIcon), {
|
|
50
|
+
color: isRunboxRunning ? 'success.main' : 'text.disabled'
|
|
51
|
+
}),
|
|
52
|
+
onClick: function onClick(e) {
|
|
53
|
+
return setAnchorEl(function (prev) {
|
|
54
|
+
return prev ? null : e.currentTarget;
|
|
55
|
+
});
|
|
56
|
+
},
|
|
57
|
+
children: intl.formatMessage({
|
|
58
|
+
id: 'runbox.status.button.title'
|
|
59
|
+
})
|
|
60
|
+
}), jsx(MaterialRunboxStatusPopover, {
|
|
61
|
+
open: Boolean(anchorEl),
|
|
62
|
+
anchorEl: anchorEl,
|
|
63
|
+
anchorOrigin: {
|
|
64
|
+
vertical: 'bottom',
|
|
65
|
+
horizontal: 'left'
|
|
66
|
+
},
|
|
67
|
+
transformOrigin: {
|
|
68
|
+
vertical: 'top',
|
|
69
|
+
horizontal: 'left'
|
|
70
|
+
},
|
|
71
|
+
sx: {
|
|
72
|
+
marginTop: '0.5rem'
|
|
73
|
+
},
|
|
74
|
+
bottomAction: bottomAction,
|
|
75
|
+
onClose: handleClose
|
|
76
|
+
})]
|
|
77
|
+
});
|
|
78
|
+
};
|
|
79
|
+
|
|
80
|
+
export { MaterialRunboxStatusButton as default };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type React from 'react';
|
|
2
|
+
export interface MaterialRunboxStatusConnectionItemProps {
|
|
3
|
+
/** Leading icon element. */
|
|
4
|
+
icon: React.ReactNode;
|
|
5
|
+
/** Row label. */
|
|
6
|
+
label: React.ReactNode;
|
|
7
|
+
/** Whether the subject is connected. Drives the icon color. */
|
|
8
|
+
connected: boolean;
|
|
9
|
+
}
|
|
10
|
+
declare const MaterialRunboxStatusConnectionItem: React.FC<MaterialRunboxStatusConnectionItemProps>;
|
|
11
|
+
export default MaterialRunboxStatusConnectionItem;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
2
|
+
import { Stack, Typography } from '@mui/material';
|
|
3
|
+
|
|
4
|
+
//
|
|
5
|
+
//
|
|
6
|
+
//
|
|
7
|
+
var MaterialRunboxStatusConnectionItem = function MaterialRunboxStatusConnectionItem(_ref) {
|
|
8
|
+
var icon = _ref.icon,
|
|
9
|
+
label = _ref.label,
|
|
10
|
+
connected = _ref.connected;
|
|
11
|
+
return jsxs(Stack, {
|
|
12
|
+
direction: "row",
|
|
13
|
+
alignItems: "center",
|
|
14
|
+
gap: "0.75rem",
|
|
15
|
+
padding: "0.625rem 0.75rem",
|
|
16
|
+
children: [jsx(Typography, {
|
|
17
|
+
component: "span",
|
|
18
|
+
display: "inline-flex",
|
|
19
|
+
color: connected ? 'success.main' : 'text.disabled',
|
|
20
|
+
children: icon
|
|
21
|
+
}), jsx(Typography, {
|
|
22
|
+
variant: "body2",
|
|
23
|
+
children: label
|
|
24
|
+
})]
|
|
25
|
+
});
|
|
26
|
+
};
|
|
27
|
+
|
|
28
|
+
export { MaterialRunboxStatusConnectionItem as default };
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import type { PopoverProps } from '@mui/material';
|
|
2
|
+
import type React from 'react';
|
|
3
|
+
export interface MaterialRunboxStatusPopoverProps extends Omit<PopoverProps, 'open' | 'onClose' | 'children'> {
|
|
4
|
+
/** Whether the popover is open. */
|
|
5
|
+
open: boolean;
|
|
6
|
+
/** Called when the popover requests to be closed. */
|
|
7
|
+
onClose: () => void;
|
|
8
|
+
/**
|
|
9
|
+
* Bottom action slot.
|
|
10
|
+
*
|
|
11
|
+
* NOTICE: the "실습 환경 초기화" button is out of scope for PLAT-4181.
|
|
12
|
+
* PLAT-4184 injects it here.
|
|
13
|
+
*/
|
|
14
|
+
bottomAction?: React.ReactNode;
|
|
15
|
+
}
|
|
16
|
+
declare const MaterialRunboxStatusPopover: React.FC<MaterialRunboxStatusPopoverProps>;
|
|
17
|
+
export default MaterialRunboxStatusPopover;
|
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
import { __rest } from 'tslib';
|
|
2
|
+
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
3
|
+
import { useNetworkState } from 'react-use';
|
|
4
|
+
import { useRawEliceIntl } from '@elice/intl';
|
|
5
|
+
import { EliceIcon } from '@elice/mui-elements';
|
|
6
|
+
import { useEliceRunboxRunning, useEliceRunboxContainerStats } from '@elice/runbox-client';
|
|
7
|
+
import { faWifiSlash, faWifi, faLinkSimple, faLinkSimpleSlash, faMicrochip, faMemory, faArrowUpRight, faArrowDownLeft, faDiscDrive } from '@fortawesome/pro-solid-svg-icons';
|
|
8
|
+
import { Popover, Stack, Divider } from '@mui/material';
|
|
9
|
+
import MaterialRunboxStatusConnectionItem from './MaterialRunboxStatusConnectionItem.js';
|
|
10
|
+
import MaterialRunboxStatusResourceItem from './MaterialRunboxStatusResourceItem.js';
|
|
11
|
+
|
|
12
|
+
//
|
|
13
|
+
//
|
|
14
|
+
//
|
|
15
|
+
var POPOVER_WIDTH = '15.25rem'; // 244px
|
|
16
|
+
//
|
|
17
|
+
//
|
|
18
|
+
//
|
|
19
|
+
var MaterialRunboxStatusPopover = function MaterialRunboxStatusPopover(_a) {
|
|
20
|
+
var open = _a.open,
|
|
21
|
+
onClose = _a.onClose,
|
|
22
|
+
bottomAction = _a.bottomAction,
|
|
23
|
+
props = __rest(_a, ["open", "onClose", "bottomAction"]);
|
|
24
|
+
var intl = useRawEliceIntl();
|
|
25
|
+
var _useEliceRunboxRunnin = useEliceRunboxRunning(),
|
|
26
|
+
status = _useEliceRunboxRunnin.status;
|
|
27
|
+
var _useNetworkState = useNetworkState(),
|
|
28
|
+
online = _useNetworkState.online;
|
|
29
|
+
var contStats = useEliceRunboxContainerStats();
|
|
30
|
+
var stats = contStats ? contStats[contStats.length - 1] : null;
|
|
31
|
+
var isRunboxRunning = status === 'running';
|
|
32
|
+
//
|
|
33
|
+
//
|
|
34
|
+
//
|
|
35
|
+
return jsx(Popover, Object.assign({
|
|
36
|
+
open: open,
|
|
37
|
+
onClose: onClose
|
|
38
|
+
}, props, {
|
|
39
|
+
children: jsxs(Stack, {
|
|
40
|
+
direction: "column",
|
|
41
|
+
padding: "0.75rem 0",
|
|
42
|
+
width: POPOVER_WIDTH,
|
|
43
|
+
bgcolor: "background.paper",
|
|
44
|
+
children: [jsxs(Stack, {
|
|
45
|
+
direction: "column",
|
|
46
|
+
children: [jsx(MaterialRunboxStatusConnectionItem, {
|
|
47
|
+
icon: jsx(EliceIcon, {
|
|
48
|
+
icon: online === false ? faWifiSlash : faWifi
|
|
49
|
+
}),
|
|
50
|
+
label: intl.formatMessage({
|
|
51
|
+
id: 'runbox.status.network'
|
|
52
|
+
}),
|
|
53
|
+
// `online` is undefined while unknown — only mark it down when known offline.
|
|
54
|
+
connected: online !== false
|
|
55
|
+
}), jsx(MaterialRunboxStatusConnectionItem, {
|
|
56
|
+
icon: jsx(EliceIcon, {
|
|
57
|
+
icon: isRunboxRunning ? faLinkSimple : faLinkSimpleSlash
|
|
58
|
+
}),
|
|
59
|
+
label: intl.formatMessage({
|
|
60
|
+
id: isRunboxRunning ? 'runbox.status.runtime.connected' : 'runbox.status.runtime.disconnected'
|
|
61
|
+
}),
|
|
62
|
+
connected: isRunboxRunning
|
|
63
|
+
})]
|
|
64
|
+
}), stats ? jsxs(Fragment, {
|
|
65
|
+
children: [jsx(Divider, {
|
|
66
|
+
sx: {
|
|
67
|
+
margin: '0.75rem'
|
|
68
|
+
}
|
|
69
|
+
}), jsxs(Stack, {
|
|
70
|
+
direction: "column",
|
|
71
|
+
children: [jsx(MaterialRunboxStatusResourceItem, {
|
|
72
|
+
icon: jsx(EliceIcon, {
|
|
73
|
+
icon: faMicrochip
|
|
74
|
+
}),
|
|
75
|
+
label: "CPU",
|
|
76
|
+
value: intl.formatNumber(stats.avgCpu, {
|
|
77
|
+
style: 'percent',
|
|
78
|
+
maximumFractionDigits: 2
|
|
79
|
+
})
|
|
80
|
+
}), jsx(MaterialRunboxStatusResourceItem, {
|
|
81
|
+
icon: jsx(EliceIcon, {
|
|
82
|
+
icon: faMemory
|
|
83
|
+
}),
|
|
84
|
+
label: "Memory",
|
|
85
|
+
value: "".concat(intl.formatDataSize(stats.memCurrent, {
|
|
86
|
+
unitSystem: 'iec',
|
|
87
|
+
maximumFractionDigits: 2
|
|
88
|
+
}), " / ").concat(intl.formatDataSize(stats.memTotal, {
|
|
89
|
+
unitSystem: 'iec',
|
|
90
|
+
maximumFractionDigits: 2
|
|
91
|
+
}))
|
|
92
|
+
}), jsx(MaterialRunboxStatusResourceItem, {
|
|
93
|
+
icon: jsx(EliceIcon, {
|
|
94
|
+
icon: faArrowUpRight
|
|
95
|
+
}),
|
|
96
|
+
label: "UP",
|
|
97
|
+
value: "".concat(intl.formatDataSize(stats.netOutPsec, {
|
|
98
|
+
unitSystem: 'iec'
|
|
99
|
+
}), "/s")
|
|
100
|
+
}), jsx(MaterialRunboxStatusResourceItem, {
|
|
101
|
+
icon: jsx(EliceIcon, {
|
|
102
|
+
icon: faArrowDownLeft
|
|
103
|
+
}),
|
|
104
|
+
label: "DOWN",
|
|
105
|
+
value: "".concat(intl.formatDataSize(stats.netInPsec, {
|
|
106
|
+
unitSystem: 'iec'
|
|
107
|
+
}), "/s")
|
|
108
|
+
}), jsx(MaterialRunboxStatusResourceItem, {
|
|
109
|
+
icon: jsx(EliceIcon, {
|
|
110
|
+
icon: faDiscDrive
|
|
111
|
+
}),
|
|
112
|
+
label: "DISK",
|
|
113
|
+
value: "".concat(intl.formatDataSize(stats.diskCurrent, {
|
|
114
|
+
unitSystem: 'iec',
|
|
115
|
+
maximumFractionDigits: 2
|
|
116
|
+
}), " / ").concat(intl.formatDataSize(stats.diskTotal, {
|
|
117
|
+
unitSystem: 'iec',
|
|
118
|
+
maximumFractionDigits: 2
|
|
119
|
+
}))
|
|
120
|
+
})]
|
|
121
|
+
})]
|
|
122
|
+
}) : null, bottomAction ? jsx(Stack, {
|
|
123
|
+
padding: "0.75rem 0.75rem 0",
|
|
124
|
+
children: bottomAction
|
|
125
|
+
}) : null]
|
|
126
|
+
})
|
|
127
|
+
}));
|
|
128
|
+
};
|
|
129
|
+
|
|
130
|
+
export { MaterialRunboxStatusPopover as default };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type React from 'react';
|
|
2
|
+
export interface MaterialRunboxStatusResourceItemProps {
|
|
3
|
+
/** Leading icon element. */
|
|
4
|
+
icon: React.ReactNode;
|
|
5
|
+
/** Resource label, e.g. `CPU`. */
|
|
6
|
+
label: React.ReactNode;
|
|
7
|
+
/** Formatted value, e.g. `438.33 MiB / 4 GiB`. */
|
|
8
|
+
value: React.ReactNode;
|
|
9
|
+
}
|
|
10
|
+
declare const MaterialRunboxStatusResourceItem: React.FC<MaterialRunboxStatusResourceItemProps>;
|
|
11
|
+
export default MaterialRunboxStatusResourceItem;
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
2
|
+
import { Stack, Typography } from '@mui/material';
|
|
3
|
+
|
|
4
|
+
//
|
|
5
|
+
//
|
|
6
|
+
//
|
|
7
|
+
var MaterialRunboxStatusResourceItem = function MaterialRunboxStatusResourceItem(_ref) {
|
|
8
|
+
var icon = _ref.icon,
|
|
9
|
+
label = _ref.label,
|
|
10
|
+
value = _ref.value;
|
|
11
|
+
return jsxs(Stack, {
|
|
12
|
+
direction: "row",
|
|
13
|
+
alignItems: "flex-start",
|
|
14
|
+
gap: "0.75rem",
|
|
15
|
+
padding: "0.375rem 0.75rem",
|
|
16
|
+
children: [jsx(Typography, {
|
|
17
|
+
component: "span",
|
|
18
|
+
display: "inline-flex",
|
|
19
|
+
color: "text.secondary",
|
|
20
|
+
paddingTop: "0.5rem",
|
|
21
|
+
children: icon
|
|
22
|
+
}), jsxs(Stack, {
|
|
23
|
+
direction: "column",
|
|
24
|
+
children: [jsx(Typography, {
|
|
25
|
+
variant: "body2",
|
|
26
|
+
fontWeight: "bold",
|
|
27
|
+
children: label
|
|
28
|
+
}), jsx(Typography, {
|
|
29
|
+
variant: "caption",
|
|
30
|
+
color: "text.secondary",
|
|
31
|
+
fontFamily: "'JetBrains Mono', monospace",
|
|
32
|
+
children: value
|
|
33
|
+
})]
|
|
34
|
+
})]
|
|
35
|
+
});
|
|
36
|
+
};
|
|
37
|
+
|
|
38
|
+
export { MaterialRunboxStatusResourceItem as default };
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export { default as MaterialRunboxStatusButton } from './MaterialRunboxStatusButton';
|
|
2
|
+
export { default as MaterialRunboxStatusPopover } from './MaterialRunboxStatusPopover';
|
|
3
|
+
export type { MaterialRunboxStatusButtonProps } from './MaterialRunboxStatusButton';
|
|
4
|
+
export type { MaterialRunboxStatusPopoverProps } from './MaterialRunboxStatusPopover';
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
interface MaterialRunboxQuotaAlmostEndDialogProps {
|
|
2
|
+
open: boolean;
|
|
3
|
+
onClose: () => void;
|
|
4
|
+
}
|
|
5
|
+
/**
|
|
6
|
+
* Warns the learner that the *total* available time is about to run out.
|
|
7
|
+
*
|
|
8
|
+
* Once it does, the practice ends for good — there is no reconnecting.
|
|
9
|
+
*/
|
|
10
|
+
declare const MaterialRunboxQuotaAlmostEndDialog: React.FC<MaterialRunboxQuotaAlmostEndDialogProps>;
|
|
11
|
+
export default MaterialRunboxQuotaAlmostEndDialog;
|
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
2
|
+
import { useRawEliceIntl } from '@elice/intl';
|
|
3
|
+
import { useEliceRunboxQuota } from '@elice/runbox-client';
|
|
4
|
+
import { Dialog, DialogTitle, DialogContent, Stack, Card, Typography, Divider, DialogActions, Button } from '@mui/material';
|
|
5
|
+
import { QUOTA_ALMOST_END_MINUTES, QUOTA_PER_SESSION_ALMOST_END_MINUTES } from '../hooks/useRunboxSessionEndWarning.js';
|
|
6
|
+
import MaterialRunboxQuotaAmount from './MaterialRunboxQuotaAmount.js';
|
|
7
|
+
|
|
8
|
+
//
|
|
9
|
+
//
|
|
10
|
+
//
|
|
11
|
+
/**
|
|
12
|
+
* Warns the learner that the *total* available time is about to run out.
|
|
13
|
+
*
|
|
14
|
+
* Once it does, the practice ends for good — there is no reconnecting.
|
|
15
|
+
*/
|
|
16
|
+
var MaterialRunboxQuotaAlmostEndDialog = function MaterialRunboxQuotaAlmostEndDialog(_ref) {
|
|
17
|
+
var open = _ref.open,
|
|
18
|
+
onClose = _ref.onClose;
|
|
19
|
+
var intl = useRawEliceIntl();
|
|
20
|
+
var _useEliceRunboxQuota = useEliceRunboxQuota(),
|
|
21
|
+
quotaInfo = _useEliceRunboxQuota.quotaInfo,
|
|
22
|
+
quotaPerSessionInfo = _useEliceRunboxQuota.quotaPerSessionInfo;
|
|
23
|
+
if (quotaInfo.isUnlimited) {
|
|
24
|
+
return null;
|
|
25
|
+
}
|
|
26
|
+
var isQuotaAlmostEnd = quotaInfo.remainingQuota <= QUOTA_ALMOST_END_MINUTES;
|
|
27
|
+
var isQuotaPerSessionAlmostEnd = !quotaPerSessionInfo.isUnlimited && quotaPerSessionInfo.remainingQuota <= QUOTA_PER_SESSION_ALMOST_END_MINUTES;
|
|
28
|
+
return jsxs(Dialog, {
|
|
29
|
+
fullWidth: true,
|
|
30
|
+
maxWidth: "xs",
|
|
31
|
+
open: open,
|
|
32
|
+
onClose: onClose,
|
|
33
|
+
children: [jsx(DialogTitle, {
|
|
34
|
+
children: intl.formatMessage({
|
|
35
|
+
id: 'runbox.timer.almost_end.dialog.quota.title'
|
|
36
|
+
}, {
|
|
37
|
+
time: intl.formatNumber(QUOTA_ALMOST_END_MINUTES, {
|
|
38
|
+
style: 'unit',
|
|
39
|
+
unit: 'minute',
|
|
40
|
+
unitDisplay: 'short'
|
|
41
|
+
})
|
|
42
|
+
})
|
|
43
|
+
}), jsx(DialogContent, {
|
|
44
|
+
children: jsxs(Stack, {
|
|
45
|
+
direction: "column",
|
|
46
|
+
gap: "1.5rem",
|
|
47
|
+
children: [jsxs(Card, {
|
|
48
|
+
sx: {
|
|
49
|
+
bgcolor: 'background.neutral'
|
|
50
|
+
},
|
|
51
|
+
children: [jsxs(Stack, {
|
|
52
|
+
direction: "column",
|
|
53
|
+
gap: "0.5rem",
|
|
54
|
+
padding: "1rem",
|
|
55
|
+
bgcolor: isQuotaAlmostEnd ? 'warning.opacity03' : undefined,
|
|
56
|
+
children: [jsx(Typography, {
|
|
57
|
+
variant: "body2",
|
|
58
|
+
fontWeight: "bold",
|
|
59
|
+
children: intl.formatMessage({
|
|
60
|
+
id: 'runbox.timer.popover.quota.title'
|
|
61
|
+
})
|
|
62
|
+
}), jsx(MaterialRunboxQuotaAmount, {
|
|
63
|
+
remainingQuota: quotaInfo.remainingQuota,
|
|
64
|
+
quota: quotaInfo.quota,
|
|
65
|
+
color: isQuotaAlmostEnd ? 'warning.main' : 'success.main'
|
|
66
|
+
})]
|
|
67
|
+
}), jsx(Divider, {}), jsxs(Stack, {
|
|
68
|
+
direction: "column",
|
|
69
|
+
gap: "0.5rem",
|
|
70
|
+
padding: "1rem",
|
|
71
|
+
bgcolor: isQuotaPerSessionAlmostEnd ? 'warning.opacity03' : undefined,
|
|
72
|
+
children: [jsx(Typography, {
|
|
73
|
+
variant: "body2",
|
|
74
|
+
fontWeight: "bold",
|
|
75
|
+
children: intl.formatMessage({
|
|
76
|
+
id: 'runbox.timer.popover.quota_per_session.title'
|
|
77
|
+
})
|
|
78
|
+
}), quotaPerSessionInfo.isUnlimited ? jsx(Typography, {
|
|
79
|
+
component: "span",
|
|
80
|
+
variant: "h5",
|
|
81
|
+
fontWeight: "extraBold",
|
|
82
|
+
children: intl.formatMessage({
|
|
83
|
+
id: 'runbox.timer.unlimited'
|
|
84
|
+
})
|
|
85
|
+
}) : jsx(MaterialRunboxQuotaAmount, {
|
|
86
|
+
remainingQuota: quotaPerSessionInfo.remainingQuota,
|
|
87
|
+
quota: quotaPerSessionInfo.quota,
|
|
88
|
+
color: isQuotaPerSessionAlmostEnd ? 'warning.main' : 'success.main'
|
|
89
|
+
})]
|
|
90
|
+
})]
|
|
91
|
+
}), jsx(Typography, {
|
|
92
|
+
variant: "body2",
|
|
93
|
+
whiteSpace: "pre-line",
|
|
94
|
+
children: intl.formatMessage({
|
|
95
|
+
id: 'runbox.timer.almost_end.dialog.quota.description'
|
|
96
|
+
})
|
|
97
|
+
})]
|
|
98
|
+
})
|
|
99
|
+
}), jsx(DialogActions, {
|
|
100
|
+
children: jsx(Button, {
|
|
101
|
+
variant: "contained",
|
|
102
|
+
color: "inherit",
|
|
103
|
+
onClick: onClose,
|
|
104
|
+
children: intl.formatMessage({
|
|
105
|
+
id: 'runbox.timer.almost_end.dialog.confirm'
|
|
106
|
+
})
|
|
107
|
+
})
|
|
108
|
+
})]
|
|
109
|
+
});
|
|
110
|
+
};
|
|
111
|
+
|
|
112
|
+
export { MaterialRunboxQuotaAlmostEndDialog as default };
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export interface MaterialRunboxQuotaAmountProps {
|
|
2
|
+
/** Remaining time, in minutes. */
|
|
3
|
+
remainingQuota: number;
|
|
4
|
+
/** Total granted time, in minutes. */
|
|
5
|
+
quota: number;
|
|
6
|
+
/** Color of the remaining time. */
|
|
7
|
+
color?: string;
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* Renders `<remaining> / <total>`, e.g. `4시간 11분 / 5시간`.
|
|
11
|
+
*/
|
|
12
|
+
declare const MaterialRunboxQuotaAmount: React.FC<MaterialRunboxQuotaAmountProps>;
|
|
13
|
+
export default MaterialRunboxQuotaAmount;
|