Skip to content

Commit bfb1e8e

Browse files
committed
online compiler
1 parent 3219d66 commit bfb1e8e

File tree

11 files changed

+146
-1976
lines changed

11 files changed

+146
-1976
lines changed

certify-images/10/certify_4.png

192 KB
Loading

readme.pdf

2.36 MB
Binary file not shown.

src/main/resources/static/client_assets/compiler/compiler.js

+98-738
Large diffs are not rendered by default.
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
const MY_API_KEY = '6984bdd544msh3d3fdce8861538fp11c2f0jsnd28103cc1b98';
2-
const MY_CHATGPT_API_KEY = '6984bdd544msh3d3fdce8861538fp11c2f0jsnd28103cc1b98';
1+
const MY_API_KEY = '90abad1031msh1a5eb4ae0b33da3p13b1d2jsn041b283eb960';
2+
const MY_CHATGPT_API_KEY = '90abad1031msh1a5eb4ae0b33da3p13b1d2jsn041b283eb960';
33
export {MY_API_KEY};
44
export {MY_CHATGPT_API_KEY};

src/main/resources/static/client_assets/compiler/practice.js

-1,228
This file was deleted.

src/main/resources/static/client_assets/js/chatbot.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ const generateResponse = async (chatElement) => {
2525
method: 'POST',
2626
headers: {
2727
'content-type': 'application/json',
28-
'X-RapidAPI-Key': 'f6166b0d6dmsh0b4b3260913831ep173798jsnfaedc18c2ed9',
28+
'X-RapidAPI-Key': '3d3cc8c0e5msh687819131cec01ep1cab2cjsn05148c7f621e',
2929
'X-RapidAPI-Host': 'open-ai21.p.rapidapi.com'
3030
},
3131
body: JSON.stringify({

src/main/resources/templates/client/online_compiler/index.html

+18-4
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,10 @@
9090
<textarea type="text" id="editor" class="form-control" aria-label="First name"></textarea>
9191
</div>
9292
</div>
93+
<div>
94+
<label for="Input" class="text-light mt-4 mb-2"></label>
95+
<textarea type="text" id="input" name="input" placeholder="Nhập input (nếu có)" class="form-control h-75"></textarea>
96+
</div>
9397
<section id="excuting" style="display: none"
9498
class="events__area pt-115 pb-120 p-relative">
9599
<div class="container">
@@ -105,10 +109,20 @@ <h2 class="section__title" id="loadingText">
105109
</div>
106110
</div>
107111
</section>
108-
<div>
109-
<label for="Input" class="text-light mt-4 mb-2"></label>
110-
<textarea type="text" id="input" placeholder="Nhập input (nếu có)" class="form-control h-75" aria-label="Last name"></textarea>
111-
</div>
112+
<!-- events area start -->
113+
<section id="result" style="display: none"
114+
class="events__area pt-115 pb-120 p-relative">
115+
<div class="events__shape">
116+
<img class="events-1-shape" alt="">
117+
</div>
118+
<div class="container">
119+
<div class="row" id="test-cases-container">
120+
121+
</div>
122+
</div>
123+
</section>
124+
<!-- events area end -->
125+
112126
</div>
113127
<!-- page title area end -->
114128
<button class="chatbot-toggler">

src/main/resources/templates/client/prepare/index.html

+24
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,30 @@ <h3 class="services__title"><a href="/problemSolving">Giải quyết vấn đề
4444
</div>
4545
</div>
4646
</div>
47+
<div class="col-xxl-3 col-xl-3 col-lg-3 col-md-6 col-sm-6">
48+
<div class="services__item footer-bg mb-30">
49+
<div class="services__icon">
50+
<svg viewBox="0 0 512 512">
51+
<path class="st0" d="M288,512c-76.5,0-138.7-62.2-138.7-138.7v-64c0-5.9,4.8-10.7,10.7-10.7h256c5.9,0,10.7,4.8,10.7,10.7v64 C426.7,449.8,364.5,512,288,512z M170.7,320v53.3c0,64.7,52.7,117.3,117.3,117.3S405.3,438,405.3,373.3V320H170.7z"/>
52+
<path class="st0" d="M458.7,426.7h-44.8c-5.9,0-10.7-4.8-10.7-10.7c0-5.9,4.8-10.7,10.7-10.7h44.8c8.6,0,16.6-3.3,22.4-9.4 c6.2-6.1,9.6-14,9.6-22.6c0-17.6-14.4-32-32-32h-37.3c-5.9,0-10.7-4.8-10.7-10.7s4.8-10.7,10.7-10.7h37.3 c29.4,0,53.3,23.9,53.3,53.3c0,14.4-5.6,27.8-15.8,37.7C486.5,421.1,473.1,426.7,458.7,426.7L458.7,426.7z"/>
53+
<path class="st0" d="M236.6,256c-3.3,0-6.6-1.5-8.6-4.4c-3.5-4.8-2.4-11.4,2.4-14.9c6.7-4.9,10.1-10.9,9.6-17.1 c-0.6-7-6.2-13.6-15.2-18c-16-7.7-25.9-20.6-27.2-35.3c-1.2-13.8,5.5-27,18.3-36.3c4.8-3.5,11.4-2.4,14.9,2.4 c3.5,4.8,2.4,11.4-2.4,14.9c-6.7,4.9-10.1,10.9-9.6,17.1c0.6,7,6.2,13.6,15.2,18c16,7.7,25.9,20.6,27.2,35.3 c1.2,13.8-5.5,27-18.3,36.3C241,255.3,238.8,256,236.6,256L236.6,256z"/>
54+
<path class="st0" d="M338,256c-3.3,0-6.6-1.5-8.6-4.4c-3.5-4.8-2.4-11.4,2.4-14.9c6.7-4.9,10.1-10.9,9.6-17.1 c-0.6-7-6.2-13.6-15.2-18c-16-7.7-25.9-20.6-27.2-35.3c-1.2-13.8,5.5-27,18.3-36.3c4.8-3.5,11.4-2.4,14.9,2.4 c3.5,4.8,2.4,11.4-2.4,14.9c-6.7,4.9-10.1,10.9-9.6,17.1c0.6,7,6.2,13.6,15.2,18c16,7.7,25.9,20.6,27.2,35.3 c1.2,13.8-5.5,27-18.3,36.3C342.3,255.3,340.1,256,338,256z"/>
55+
<path class="st0" d="M426.7,512H149.3c-5.9,0-10.7-4.8-10.7-10.7s4.8-10.7,10.7-10.7h277.3c5.9,0,10.7,4.8,10.7,10.7 S432.6,512,426.7,512z"/>
56+
<path class="st0" d="M32,442.1c-7.2,0-14.2-2.4-20-7c-7.6-6.1-12-15.3-12-25V66.3c0-12,6.9-23.2,17.6-28.5 c101.9-51.3,178-51.1,238.4,1.1c60.4-52.2,136.5-52.4,238.4-1.1c10.7,5.3,17.6,16.5,17.6,28.5v200.3c0,5.9-4.8,10.7-10.7,10.7 s-10.7-4.8-10.7-10.7V66.3c0-4-2.3-7.7-5.8-9.4c-97-48.9-167.3-47.6-221.5,4.1c-4.1,3.9-10.6,3.9-14.7,0 c-54.2-51.7-124.5-53-221.5-4.2c-3.6,1.8-5.8,5.5-5.8,9.5V410c0,3.3,1.5,6.4,4,8.4c1.5,1.2,4.7,3,9,2.1c25.7-6,46.7-9.8,65.9-12.1 c5.5-0.7,11.1,3.5,11.9,9.3c0.7,5.8-3.5,11.2-9.3,11.9c-18.4,2.2-38.6,6-63.7,11.8C36.7,441.9,34.3,442.1,32,442.1L32,442.1z"/>
57+
<path class="st0" d="M256,106.7c-5.9,0-10.7-4.8-10.7-10.7V53.3c0-5.9,4.8-10.7,10.7-10.7s10.7,4.8,10.7,10.7V96 C266.7,101.9,261.9,106.7,256,106.7z"/>
58+
</svg>
59+
</div>
60+
<div class="services__content">
61+
<h3 class="services__title"><a href="/problemSolving">Cấu trúc dữ liệu<br></a></h3>
62+
<p>Luyện tập giải thuật nên nâng cao trình độ lập trình của bạn</p>
63+
64+
<a href="/problemSolving" class="link-btn-2">
65+
<i class="far fa-arrow-right"></i>
66+
<i class="far fa-arrow-right"></i>
67+
</a>
68+
</div>
69+
</div>
70+
</div>
4771
<div th:each="language :${languages}" class="col-xxl-3 col-xl-3 col-lg-3 col-md-6 col-sm-6">
4872
<div class="services__item blue-bg-4 mb-30">
4973
<div class="services__icon">

src/main/resources/templates/client/problem/index.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -198,7 +198,7 @@ <h3 class="course__sidebar-title">DIFFICULTY</h3>
198198
</div>
199199
<div class="course__sidebar-widget grey-bg">
200200
<div class="course__sidebar-info">
201-
<h3 class="course__sidebar-title">SUBDOMAINS</h3>
201+
<h3 class="course__sidebar-title">Hashtag</h3>
202202
<ul>
203203
<li>
204204
<div class="course__sidebar-check mb-10 d-flex align-items-center">

src/main/resources/templates/client/problem/practice.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -711,7 +711,7 @@ <h2 style="font-size: 20px; color: #fff">Code Helper</h2>
711711
<script type="text/javascript" th:src="@{/client_assets/compiler/ddslick.js}"></script>
712712

713713
<script th:inline="javascript">
714-
const myApiKey = '6984bdd544msh3d3fdce8861538fp11c2f0jsnd28103cc1b98';
714+
const myApiKey = '90abad1031msh1a5eb4ae0b33da3p13b1d2jsn041b283eb960';
715715
const chatbotToggler = document.querySelector(".chatbot-toggler");
716716
const closeBtn = document.querySelector(".close-btn");
717717
closeBtn.addEventListener("click", () => document.body.classList.remove("show-chatbot"));

src/main/resources/templates/client/user/profile.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@ <h5 class="text-uppercase mb-0" th:text="${user.fullName}"></h5>
147147
<i class="fa fa-check"></i>
148148
</div>
149149
<div class="base-timeline-info">
150-
<a href="#" class="text-uppercase weight700 f12 text-purple">Cứng Chỉ</a>
150+
<a href="#" class="text-uppercase weight700 f12 text-purple">Chứng Chỉ</a>
151151
<span class="d-block" style="white-space: break-spaces" th:text="${user.certificates}">5 tasks for 29 january is completed successfully and no task pending</span>
152152
</div>
153153
</li>

0 commit comments

Comments
 (0)