Skip to content

Commit

Permalink
Merge pull request #33 from nihalsaran/main
Browse files Browse the repository at this point in the history
test small d
  • Loading branch information
ishantdei authored Oct 8, 2024
2 parents 67a6336 + d111284 commit 33f41c5
Show file tree
Hide file tree
Showing 20 changed files with 715 additions and 12 deletions.
4 changes: 1 addition & 3 deletions experiment/simulation/LettersPage/SmaA/a.css
Original file line number Diff line number Diff line change
Expand Up @@ -211,11 +211,9 @@ body {
display: none;
justify-content: start;
z-index: 0;

height: 10%;
bottom: 40%;
top: 80%;
font-size: 150%;

}

.next-exp {
Expand Down
2 changes: 1 addition & 1 deletion experiment/simulation/LettersPage/SmaA/a.html
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ <h1 class="rules">Rules-</h1>
<!-- <img id="stroke3" src="stroke2.png" >-->
</div>

<h1 class="congrats" id="congrats">Congrats you have learnt to draw Letter A</h1>
<h1 class="congrats" id="congrats">Congrats you have learnt to draw Letter a</h1>

<a href="../../Lowercase.html" >
<button class="next-exp" id="button">Next Letter</button>
Expand Down
1 change: 1 addition & 0 deletions experiment/simulation/LettersPage/SmaA/a.js
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,7 @@ function stopDrawing(e) {
dot2.style.display = 'none';
dot4.style.display = 'none';
button.style.display = 'block';
congrats.style.display = 'block';
break;
}

Expand Down
3 changes: 1 addition & 2 deletions experiment/simulation/LettersPage/SmaB/b.css
Original file line number Diff line number Diff line change
Expand Up @@ -83,9 +83,8 @@
display: none;
justify-content: start;
z-index: 0;

height: 10%;
bottom: 40%;
top: 80%;
font-size: 150%;

}
Expand Down
2 changes: 1 addition & 1 deletion experiment/simulation/LettersPage/SmaB/b.html
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ <h1 class="rules">Rules-</h1>
<!-- <img id="stroke3" src="stroke2.png" >-->
</div>

<h1 class="congrats" id="congrats">Congrats you have learnt to draw Letter A</h1>
<h1 class="congrats" id="congrats">Congrats you have learnt to draw Letter b</h1>

<a href="../../Lowercase.html" >
<button class="next-exp" id="button">Next Letter</button>
Expand Down
1 change: 1 addition & 0 deletions experiment/simulation/LettersPage/SmaB/b.js
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,7 @@ function stopDrawing(e) {
dot1.style.display = 'none';
dot3.style.display = 'none';
button.style.display = 'block';
congrats.style.display = 'block';
break;
}

Expand Down
3 changes: 1 addition & 2 deletions experiment/simulation/LettersPage/SmaC/c.css
Original file line number Diff line number Diff line change
Expand Up @@ -210,9 +210,8 @@ body {
display: none;
justify-content: start;
z-index: 0;

height: 10%;
bottom: 40%;
top: 80%;
font-size: 150%;

}
Expand Down
2 changes: 1 addition & 1 deletion experiment/simulation/LettersPage/SmaC/c.html
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ <h1 class="rules">Rules-</h1>
<img id="stroke3" src="stroke2.png" >-->
</div>

<h1 class="congrats" id="congrats">Congrats you have learnt to draw Letter A</h1>
<h1 class="congrats" id="congrats">Congrats you have learnt to draw Letter c</h1>

<a href="../../Lowercase.html" >
<button class="next-exp" id="button">Next Letter</button>
Expand Down
1 change: 1 addition & 0 deletions experiment/simulation/LettersPage/SmaC/c.js
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ function stopDrawing(e) {
console.log('Stopped drawing near', dot1.id);
arrow1.style.display = 'none'; // Hide the arro
button.style.display = 'block';
congrats.style.display = 'block';
nextConnection = ''; // All connections done
ctx.clearRect(0, 0, canvas.width, canvas.height);
} else {
Expand Down
Binary file added experiment/simulation/LettersPage/SmaD/O1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added experiment/simulation/LettersPage/SmaD/d-new.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
232 changes: 232 additions & 0 deletions experiment/simulation/LettersPage/SmaD/d.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,232 @@
body {
display: flex;
justify-content: center;
/* Center horizontally */
align-items: center;
/* Center vertically */
height: 100vh;
/* Full height of the viewport */
margin: 0;
/* Remove default margin */
}

#canvas-container {
position: relative;
width: 400px;
height: 400px;
border: 1px solid black;
display: flex;
justify-content: center;
align-items: center;
}

#canvas {
position: absolute;
top: 0;
left: 0;
border: 1px solid black;
z-index: 10;
cursor: url('data:image/x-icon;base64,AAACAAEAICAQAAAAAADoAgAAFgAAACgAAAAgAAAAQAAAAAEABAAAAAAAAAIAAAAAAAAAAAAAEAAAAAAAAAAAAAAAhYWFAPqv6ADgm4sASkpKAJ/l7QAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACIAAAAAAAAAAAAAAAAAAAEiIAAAAAAAAAAAAAAAAAAxEiIAAAAAAAAAAAAAAAADMxEgAAAAAAAAAAAAAAAAMzMxAAAAAAAAAAAAAAAAAzMzMAAAAAAAAAAAAAAAADMzMwAAAAAAAAAAAAAAAAMzMzAAAAAAAAAAAAAAAAAzMzMAAAAAAAAAAAAAAAADMzMwAAAAAAAAAAAAAAAABTMzAAAAAAAAAAAAAAAAAFVTMAAAAAAAAAAAAAAAAABFVQAAAAAAAAAAAAAAAAAARAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAD///////////////////////////////////////////////////////////////////////////////////////P////h////wP///4H///8D///+B////A////gf///wP///4H///+D////B////w////8///////////////w=='), auto;
}

.dot {
position: absolute;
width: 10px;
height: 10px;
background-color: red;
border-radius: 50%;
transform: translate(-50%, -50%);
}


#stroke1 {

display: none;
position: absolute;
top: 81px;
left: 83px;
width: 195px;
height: 238px;
z-index: -1;


}

#stroke2 {

display: none;
position: absolute;
top: 0px;
left: 262px;
width: 13px;
height: 313px;
transform: rotate(180deg);

}

#stroke3 {

display: none;
position: absolute;
top: 187px;
left: 140px;
width: 170px;
height: 132px;

}

#sbox {
position: relative;
left: 115px;
width: 400px;
height: 400px;
z-index: -2;
display: none;
}

#trace {
position: relative;
bottom: 20px;
right: 90px;
width: 600px;
height: 550px;
z-index: -10;
}

.arrrow1 {
position: absolute;
top: 255px;
left: 170px;
width: 80px;
height: 180px;
transform: rotate(270deg) scalex(-1);
z-index: 1;
}

.arrrow2 {

position: absolute;
top: 85px;
left: 290px;
width: 40px;
height: 230px;
transform: rotate(180deg);
z-index: 0;
}

.arrrow3 {
display: none;
position: absolute;
top: 200px;
left: 310px;
width: 20px;
height: 110px;
transform: rotate(180deg);
z-index: 0;
}

* {
margin: 0;
padding: 0;
font-family: Arial, Helvetica, sans-serif;
box-sizing: border-box; /* Ensures padding and border are included in width/height calculations */
z-index: -4;
}

.simulation-container {
background-color: rgba(220, 229, 236, 1);
width: 100%; /* Responsive width */
max-width: 1000px; /* Max width to maintain design integrity */
min-height: 800px; /* Minimum height */
margin: 20px auto; /* Auto margins for centering */
z-index: 0;
display: grid;
justify-items: center;

}

.title {
margin: 0;
padding: 5px;
letter-spacing: 0.1em;
background-color: rgb(0, 140, 255);
color: white;
display: flex;
justify-content: center;
width: 100%; /* Ensure it fills the container */
height: 60%;
}

.instruction-main {
position: relative;
display: grid;
justify-content: center;
z-index: 0;
font-family: Georgia, 'Times New Roman', Times, serif;
height: 10%;
bottom: 40%;
font-size: 50px;
margin-top: 20px;
}

.instruction-main1 {
position: relative;
display: grid;
justify-content: center;
z-index: 0;
bottom: 100%;
height: 10%;


}

.rules {
position: relative;
display: flex;
justify-content: start;
z-index: 0;

height: 10%;
bottom: 45px;
font-size: 150%;
left: -40%;
}

.rule {
position: relative;
display: flex;
justify-content: start;
z-index: 0;
font-family: Georgia, 'Times New Roman', Times, serif;


left: -100px;
bottom: 80px;

}

.congrats {
position: relative;
display: none;
justify-content: start;
z-index: 0;
height: 10%;
top: 80%;
font-size: 150%;

}

.next-exp {
position: absolute;
display: none;
left: 75%;
transform: translateX(-50%); /* Centering button horizontally */
padding: 10px 15px;
color: white;
background-color: rgb(20, 117, 228);
font-weight: 600;
border: none;
border-radius: 4px;
cursor: pointer;
bottom: 30px;
}
59 changes: 59 additions & 0 deletions experiment/simulation/LettersPage/SmaD/d.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
<!DOCTYPE html>
<html>

<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<link href="https://fonts.googleapis.com/css2?family=Open+Sans&amp;family=Raleway&amp;display=swap"
rel="stylesheet" />
<link rel="icon" href="images/favicon.ico" />
<link rel="stylesheet" href="../../css/header.css" />

<link rel="stylesheet" href="d.css" />


<title>Virtual Labs</title>
</head>

<body>


<div class="simulation-container">

<h2 class="title">Lettering</h2>
<h3 class="instruction-main"> Letter d</h3>

<h1 class="rules">Rules-</h1>
<p class="rule">1] Draw the line in the direction of the arrow on the trace of the letter.</p>
<p class="rule">2] To draw, click on the starting point and drag the cursor to end point .</p>

<div id="canvas-container">
<canvas id="canvas" width="400" height="400"></canvas>
<div class="dot" id="dot3" style="top: 258px; left: 110px;"></div>
<div class="dot" id="dot4" style="top: 305px; left: 269px;"></div>
<div class="dot" id="dot1" style="top: 145px; left: 110px;"></div>
<div class="dot" id="dot2" style="top: 7px; left: 269px;"></div>
<img id="sbox" src="sboxx.png">
<img id="trace" src="d-new.png">
<img class="arrrow1" id="arrow1" src="curved arrow.gif" alt="Overlay Image">
<img class="arrrow2" id="arrow2" src="without-bg.gif" alt="Overlay Image">
<!-- <img class="arrrow3" id="arrow3" src="without-bg.gif" alt="Overlay Image"> -->
<img id="stroke1" src="O1.png">
<img id="stroke2" src="stroke11.png">
<!-- <img id="stroke3" src="stroke2.png" >-->
</div>

<h1 class="congrats" id="congrats">Congrats you have learnt to draw Letter d</h1>

<a href="../../Lowercase.html" >
<button class="next-exp" id="button">Next Letter</button>
</a>

</div>
<!-- Your code goes here-->

<!-- Add JS at the bottom of HTML file -->
<script src="d.js"></script>
</body>

</html>
Loading

0 comments on commit 33f41c5

Please sign in to comment.