-
Notifications
You must be signed in to change notification settings - Fork 5
JS Calculator Lab Pt1 Final #1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,135 @@ | ||
| table { | ||
| background-color: rgb(33, 33, 33); | ||
| border-radius: 15px; | ||
| width: 55%; | ||
| height: 55%; | ||
| border: solid; | ||
| padding: 3px; | ||
| padding-right: 9px; | ||
| } | ||
|
|
||
| input[type="button"] { | ||
| background-color: rgb(242, 170, 128); | ||
| border-radius: 10px; | ||
| color: black; | ||
| border: solid black 2px; | ||
| width: 100%; | ||
| height: 100%; | ||
| font-weight: 200; | ||
| font-size: 44px; | ||
| } | ||
|
|
||
| input[type="buttonacc"] { | ||
| background-color: rgb(64, 224, 208); | ||
| border-radius: 10px; | ||
| color: black; | ||
| border: solid black 2px; | ||
| width: 97%; | ||
| height: 100%; | ||
| font-weight: 200; | ||
| font-size: 44px; | ||
| text-align: center; | ||
| } | ||
|
|
||
| input[type="buttonsup"] { | ||
| background-color: rgb(242, 170, 128); | ||
| border-radius: 10px; | ||
| color: black; | ||
| border: solid black 2px; | ||
| width: 100%; | ||
| height: 100%; | ||
| font-weight: 200; | ||
| font-size: 44px; | ||
| } | ||
|
|
||
| input:hover { | ||
| background-color: slategray; | ||
| } | ||
|
|
||
| .square { | ||
| border: 1px solid rgb(50, 50, 50); | ||
| border-radius: 10px; | ||
| margin-left: 5px; | ||
| width: 945px; | ||
| height: 620px; | ||
| display: block; | ||
| padding: 20px; | ||
| } | ||
|
|
||
| .square::after { | ||
| content: attr(supscr); | ||
| vertical-align: super; | ||
| background-color: rgb(64, 224, 208); | ||
| border-radius: 10px; | ||
| color: black; | ||
| border: solid black 2px; | ||
| width: 97%; | ||
| height: 100%; | ||
| font-weight: 200; | ||
| font-size: 44px; | ||
| text-align: center; | ||
| } | ||
|
|
||
| .content { | ||
| background-color: transparent; | ||
| position: fixed; | ||
| width: 100%; | ||
| height: 100%; | ||
| } | ||
|
|
||
| input[type="text"] { | ||
| background-color: white; | ||
| border: solid black 2px; | ||
| width: 99%; | ||
| text-align: right; | ||
| font-weight: 200; | ||
| font-size: 44px; | ||
| } | ||
|
|
||
| .radDeg { | ||
| background-color: rgb(242, 170, 128); | ||
| border-radius: 10px; | ||
| color: black; | ||
| border: solid black 2px; | ||
| width: 100%; | ||
| height: 100%; | ||
| font-weight: 200; | ||
| font-size: 44px; | ||
| } | ||
|
|
||
| .sup { | ||
| vertical-align: super; | ||
| font-size: smaller; | ||
| background-color: rgb(64, 224, 208); | ||
| border-radius: 10px; | ||
| color: black; | ||
| border: solid black 2px; | ||
| width: 97%; | ||
| height: 100%; | ||
| font-weight: 200; | ||
| font-size: 44px; | ||
| text-align: center; | ||
| } | ||
|
|
||
| div[class="sup"]:hover { | ||
| background-color: slategray; | ||
| } | ||
|
|
||
| input[class="equals"] { | ||
| background-color: rgb(16, 115, 105); | ||
| color: whitesmoke; | ||
| border-radius: 10px; | ||
| border: solid black 2px; | ||
| width: 100%; | ||
| height: 100%; | ||
| font-weight: 200; | ||
| font-size: 44px; | ||
| } | ||
|
|
||
| input[class="equals"]:hover { | ||
| background-color: slategray; | ||
| } | ||
|
|
||
| a:active { | ||
| color: whitesmoke; | ||
| } |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,103 @@ | ||
| <!DOCTYPE html> | ||
| <html lang="en"> | ||
|
|
||
| <head> | ||
| <meta charset="utf-8"> | ||
| <link rel="stylesheet" href="index.css"> | ||
| <title>Elu's Calculator</title> | ||
| </head> | ||
|
|
||
| <body> | ||
| <div class="square"> | ||
| <h1><a href="indexStandard.html">Standard</a> | ||
| <a>| Scientific</a></h1> | ||
| <div class="content"> | ||
| <table> | ||
| <tr> | ||
| <td colspan="7"><input type="text" id="result" value="0" /></td> | ||
| </tr> | ||
| <div> | ||
| <tr> | ||
| <div> | ||
| <td colspan="2"> | ||
| <button class="radDeg"><a>Rad</a> | <a>Deg</a></button> | ||
| <!-- <span class="radDeg"> | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Remove commented out code before committed |
||
| <form> | ||
| <label for="rad">Rad</label> | ||
| <input id="rad" name="rad" type="radio" checked> | ||
| | | ||
| <label for="deg">Deg</label> | ||
| <input id="deg" name="deg" type="radio"> | ||
| </form> | ||
| </span> --> | ||
| <!-- --> | ||
| <!-- ORIG <input type="button" value="Rad | Deg" /> --> | ||
| <!-- <optgroup> | ||
| <option value="rad"></option> | ||
| <option value="deg"></option> | ||
| </optgroup> --> | ||
| </td> | ||
| <!-- <label for="hear">How did you hear about us?</label> | ||
| <select id="hear" name="hear"> | ||
| <optgroup label="Select One"> | ||
| <option value="search_engine">Search Engine</option> | ||
| <option value="social_media">Social Media</option> | ||
| <option value="recruiter">Recruiter</option> | ||
| </optgroup> | ||
| </select> --> | ||
| </div> | ||
| <td><input type="buttonacc" value="x!" /> </td> | ||
| <td><input type="buttonacc" value="(" /> </td> | ||
| <td><input type="buttonacc" value=")" /> </td> | ||
| <td><input type="buttonacc" value="%" /> </td> | ||
| <td><input type="buttonacc" value="AC" /> </td> | ||
| </tr> | ||
| </div> | ||
| <tr> | ||
| <td><input type="buttonacc" value="Inv" /> </td> | ||
| <td><input type="buttonacc" value="sin" /> </td> | ||
| <td><input type="buttonacc" value="ln" /> </td> | ||
| <td><input type="button" value="7" /> </td> | ||
| <td><input type="button" value="8" /> </td> | ||
| <td><input type="button" value="9" /> </td> | ||
| <td><input type="buttonacc" value="÷" /> </td> | ||
| </tr> | ||
| <tr> | ||
| <td><input type="buttonacc" value="π" /> </td> | ||
| <td><input type="buttonacc" value="cos" /> </td> | ||
| <td><input type="buttonacc" value="log" /> </td> | ||
| <td><input type="button" value="4" /> </td> | ||
| <td><input type="button" value="5" /> </td> | ||
| <td><input type="button" value="6" /> </td> | ||
| <td><input type="buttonacc" value="x" /> </td> | ||
| </tr> | ||
| <tr> | ||
| <td><input type="buttonacc" value="e" /> </td> | ||
| <td><input type="buttonacc" value="tan" /> </td> | ||
| <td><input type="buttonacc" value="√" /> </td> | ||
| <td><input type="button" value="1" /> </td> | ||
| <td><input type="button" value="2" /> </td> | ||
| <td><input type="button" value="3" /> </td> | ||
| <td><input type="buttonacc" value="-" /> </td> | ||
| </tr> | ||
| <tr> | ||
| <td><input type="buttonacc" value="Ans" /> </td> | ||
| <td><input type="buttonacc" value="EXP" /> </td> | ||
| <td> | ||
| <div class="sup">x<sup>y</sup></div> | ||
| </td> | ||
| <!-- <td><input class="sup" type="buttonacc" value="x(y)" /> </td> | ||
| <td><button supscr="y">x</button></td> | ||
| <button>x<sup>y</sup></button> | ||
| <sup class="buttonsup">y</sup> <var>a<sup>2</sup></var> --> | ||
| <td><input type="button" value="0" /> </td> | ||
| <td><input type="button" value="." /> </td> | ||
| <td><input class="equals" type="button" value="=" /> </td> | ||
| <td><input type="buttonacc" value="+" /> </td> | ||
| </tr> | ||
| </table> | ||
| </div> | ||
| </div> | ||
| </body> | ||
|
|
||
| </html> | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,54 @@ | ||
| <!DOCTYPE html> | ||
| <html lang="en"> | ||
|
|
||
| <head> | ||
| <meta charset="utf-8"> | ||
| <link rel="stylesheet" href="index.css"> | ||
| <title>Elu's Calculator</title> | ||
| </head> | ||
|
|
||
| <body> | ||
| <div class="square"> | ||
| <h1><a>Standard |</a> | ||
| <a href="indexScientific.html">Scientific</a></h1> | ||
| <div class="content"> | ||
| <table> | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Table layout (-5) |
||
| <tr> | ||
| <td colspan="4"><input type="text" id="result" value="0" /></td> | ||
| </tr> | ||
| <tr> | ||
| <td><input type="buttonacc" value="(" /> </td> | ||
| <td><input type="buttonacc" value=")" /> </td> | ||
| <td><input type="buttonacc" value="%" /> </td> | ||
| <td><input type="buttonacc" value="AC" /> </td> | ||
| </tr> | ||
| <tr> | ||
| <td><input type="button" value="7" /> </td> | ||
| <td><input type="button" value="8" /> </td> | ||
| <td><input type="button" value="9" /> </td> | ||
| <td><input type="buttonacc" value="÷" /> </td> | ||
| </tr> | ||
| <tr> | ||
| <td><input type="button" value="4" /> </td> | ||
| <td><input type="button" value="5" /> </td> | ||
| <td><input type="button" value="6" /> </td> | ||
| <td><input type="buttonacc" value="x" /> </td> | ||
| </tr> | ||
| <tr> | ||
| <td><input type="button" value="1" /> </td> | ||
| <td><input type="button" value="2" /> </td> | ||
| <td><input type="button" value="3" /> </td> | ||
| <td><input type="buttonacc" value="-" /> </td> | ||
| </tr> | ||
| <tr> | ||
| <td><input type="button" value="0" /> </td> | ||
| <td><input type="button" value="." /> </td> | ||
| <td><input class="equals" type="button" value="=" /> </td> | ||
| <td><input type="buttonacc" value="+" /> </td> | ||
| </tr> | ||
| </table> | ||
| </div> | ||
| </div> | ||
| </body> | ||
|
|
||
| </html> | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Great work, love the color scheme! Only issue was the table layout. 90% |
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You should never use a table to build a layout (-5)