{"id":65329,"student_id":2008,"content":"{\"html\":\"\u003c!DOCTYPE html\u003e\\n\u003chtml\u003e\\n\u003chead\u003e\\n\\t\u003ctitle\u003eDocument\u003c/title\u003e\\n \u003clink rel=\\\"stylesheet\\\" href=\\\"https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css\\\"\u003e\\n \u003cscript src=\\\"https://code.jquery.com/jquery-3.2.1.slim.min.js\\\"\u003e\u003c/script\u003e\\n \u003cscript src=\\\"https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.12.9/umd/popper.min.js\\\"\u003e\u003c/script\u003e\\n \u003cscript src=\\\"https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/js/bootstrap.min.js\\\"\u003e\u003c/script\u003e\\n\u003c/head\u003e\\n\u003cbody class=\\\"p-3\\\"\u003e\\n \u003cimg src=\\\"tomato.png\\\" class=\\\"tomato-sm\\\"\u003e x\u003cspan class=\\\"js-collect\\\"\u003e0\u003c/span\u003e\\n \u003cdiv class=\\\"center\\\"\u003e\\n \u003cimg src=\\\"tomato.png\\\" class=\\\"tomato-lg js-tomato\\\"\u003e\\n \u003cp class=\\\"timer js-timer\\\"\u003e00:00\u003c/p\u003e\\n \u003cbutton class=\\\"btn btn-danger js-start\\\"\u003erun\u003c/button\u003e\\n \u003c/div\u003e\\n\u003c/body\u003e\\n\u003c/html\u003e\",\"css\":\"body {\\n background-color: #f7df56;\\n font-family: Monaco;\\n}\\n\\n.center {\\n text-align: center;\\n position: absolute;\\n top: 50vh;\\n left: 50vw;\\n color: rgba(255,255,255,.7);\\n transform: translate(-50%, -50%);\\n}\\n\\n.timer {\\n font-size: 5em;\\n font-weight: bold;\\n}\\n\\n.tomato-sm {\\n width: 20px;\\n}\\n\\n.tomato-lg:hover {\\n transform: scale(1.3);\\n}\\n\",\"js\":\"$(\\\".js-tomato\\\").hide()\\nvar waitWork = 0\\nvar working = 1\\nvar waitRest = 2\\nvar rest = 3\\nvar status = waitWork\\nvar time = 5;\\nvar collect = DB.variables.tomatos || 0 \\n$(\\\".js-collect\\\").text(collect)\\nsetInterval(function() {\\n if (status == working || status == rest) {\\n time--\\n if (time == 0) {\\n $(\\\".js-start\\\").show()\\n if (status == working) {\\n status = waitRest;\\n $(\\\".js-start\\\").text(\\\"開始休息\\\");\\n \\n } else {\\n $(\\\".js-tomato\\\").show()\\n status = waitWork;\\n $(\\\".js-start\\\").hide()\\n $(\\\".js-start\\\").text(\\\"開始工作\\\");\\n }\\n }\\n }\\n var min = Math.floor(time/60)\\n var sec = time%60\\n $(\\\".js-timer\\\").text(`${min}:${sec}`)\\n}, 1000);\\n\\n\\n$(\\\".js-start\\\").click(function() {\\n if (status == waitWork) {\\n time = 5\\n status = working\\n }\\n if (status == waitRest) {\\n time = 3\\n status = rest\\n }\\n $(\\\".js-start\\\").hide();\\n})\\n$(\\\".js-tomato\\\").on(\\\"click\\\", function(){\\n collect++\\n DB.variables.set('tomatos',collect)\\n $(\\\".js-collect\\\").text(collect)\\n$(\\\".js-tomato\\\").hide()\\n$(\\\".js-start\\\").show()\\n$(\\\".js-start\\\").text(\\\"開始工作\\\")\\n})\"}","created_at":"2019-05-04T10:10:39.021+08:00","updated_at":"2019-10-17T17:36:57.162+08:00","name":"番茄時鐘 副本","language":"web","screenshot":{"url":"https://cdn5.koding.school/uploads/project/screenshot/65329/d127a04d813b473d9597a98b7cdfcc99.jpg"},"parent_id":22503,"plugin":"","description":null,"note":null,"status":"public","like_student_ids":[],"is_featured":false,"views":98,"hashid":"kdmsv6jq","is_content_changed":false,"review_status":"unsubmitted","submitted_at":null,"reviewed_at":null,"advise":null,"is_deleted":false}
[{"id":1146781,"file_name":"tomato.png","project_id":65329,"asset_id":51614,"created_at":"2019-05-04T11:01:37.099+08:00","updated_at":"2019-05-04T11:27:21.221+08:00"}]
橘蘋學習平台
我的作品
檢視專案頁
匯出
複製
匯入
刪除
下載 Android APP (APK)
截圖
前往網站頁面
繁中
简中
English
日本語
1:1:1
1:1
全寬
用手機掃描下方 QRCode 進行安裝
或您也可以
下載 APK
到這台電腦
用手機掃描下方 QRCode 進行安裝
或您也可以
下載 APK
到這台電腦