mcalc/index.html

84 lines
2.6 KiB
HTML
Raw Normal View History

2025-12-12 04:49:34 +00:00
<!--
Copyright (C) 2025 filifa
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <https://www.gnu.org/licenses/>.
-->
2025-12-12 04:49:34 +00:00
<!doctype html>
<html lang="en-US">
<head>
<meta charset="utf-8" />
2025-12-12 04:49:34 +00:00
<meta name="viewport" content="width=device-width,initial-scale=1">
2025-12-12 04:49:34 +00:00
<link rel="stylesheet" href="styles.css" />
2025-12-12 04:49:34 +00:00
<title>mcalc</title>
</head>
<body>
2025-12-12 04:49:34 +00:00
<div id="calculator">
2025-12-12 04:49:34 +00:00
<div id="input-row">
2025-12-12 04:49:34 +00:00
<div id="expr-box">
<label id="expr-label" for="expr">Expression</label>
<input id="expr" required type="text" inputmode="none" />
</div>
2025-12-12 04:49:34 +00:00
2025-12-12 04:49:34 +00:00
<div id="modulus-box">
<label id="modulus-label" for="modulus">mod</label>
<input id="modulus" required type="text" inputmode="numeric" pattern="\d+" />
2025-12-12 04:49:34 +00:00
</div>
2025-12-12 04:49:34 +00:00
</div>
2025-12-12 04:49:34 +00:00
2025-12-12 04:49:34 +00:00
<output id="result" for="expr modulus"></output>
2025-12-12 04:49:34 +00:00
<div id="extra-buttons">
2025-12-12 04:49:34 +00:00
<button id="ord" type="button">ord</button>
2025-12-12 04:49:34 +00:00
<button id="sqrt" type="button"></button>
<button id="inv" type="button">x<sup>-1</sup></button>
<button id="pow" type="button">^</button>
</div>
2025-12-12 04:49:34 +00:00
2025-12-12 04:49:34 +00:00
<div id="main-buttons">
<button id="clear" type="button">C</button>
<button id="lparen" type="button">(</button>
<button id="rparen" type="button">)</button>
<div id="numerals">
2025-12-12 04:49:34 +00:00
<button id="seven" type="button">7</button>
<button id="eight" type="button">8</button>
<button id="nine" type="button">9</button>
2025-12-12 04:49:34 +00:00
2025-12-12 04:49:34 +00:00
<button id="four" type="button">4</button>
<button id="five" type="button">5</button>
<button id="six" type="button">6</button>
2025-12-12 04:49:34 +00:00
2025-12-12 04:49:34 +00:00
<button id="one" type="button">1</button>
<button id="two" type="button">2</button>
<button id="three" type="button">3</button>
2025-12-12 04:49:34 +00:00
2025-12-12 04:49:34 +00:00
<button id="zero" type="button">0</button>
2025-12-12 04:49:34 +00:00
<button id="backspace" type="button"></button>
2025-12-12 04:49:34 +00:00
</div>
<div id="operators">
<button id="divide" type="button">/</button>
<button id="times" type="button">*</button>
<button id="minus" type="button">-</button>
<button id="plus" type="button">+</button>
<button id="enter" type="button"></button>
</div>
</div>
2025-12-12 04:49:34 +00:00
</div>
2025-12-12 04:49:34 +00:00
<script type="module" src="main.js"></script>
</body>
</html>