This commit is contained in:
zyqunix 2025-06-12 11:05:12 +02:00
parent 1f81401632
commit 94ca706258
2 changed files with 32 additions and 43 deletions

View file

@ -1,5 +1,6 @@
<!DOCTYPE html> <!DOCTYPE html>
<html lang="en"> <html lang="en">
<head> <head>
<meta charset="UTF-8"> <meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0"> <meta name="viewport" content="width=device-width, initial-scale=1.0">
@ -7,23 +8,26 @@
<link rel="shortcut icon" href="https://rimgo.pussthecat.org/RFbdMMB.png" type="image/x-icon"> <link rel="shortcut icon" href="https://rimgo.pussthecat.org/RFbdMMB.png" type="image/x-icon">
<link rel="stylesheet" href="style.css"> <link rel="stylesheet" href="style.css">
</head> </head>
<body> <body>
<div id="offscreenalert">Copied to clipboard!</div> <div id="offscreenalert">Copied to clipboard!</div>
<div class="cards">
<button class="colors" id="colorButton">Get Random Color</button> <button class="colors" id="colorButton">Get Random Color</button>
<div class="input"> <div class="input">
<input class="colors" type="text" name="input color" id="colorInput" placeholder="Your Color" maxlength="7"> <input class="colors" type="text" name="input color" id="colorInput" placeholder="Your Color" maxlength="7">
<button class="inputButton" id="inputButton" type="button">Enter</button> <button class="inputButton" id="inputButton" type="button">Enter</button>
</div>
<p>Press the hexadecimal to copy the color!</p>
<p class="hint" id="hint"></p>
<div id="main" class="main">
<div id="fullColor">Press the button to get a color!</div>
</div>
</div> </div>
<p>Press the hexadecimal to copy the color!</p>
<p class="hint" id="hint"></p>
<div id="main" class="main">
<div id="fullColor">Press the button to get a color!</div>
</div>
<script src="index.js"></script> <script src="index.js"></script>
</body> </body>
</html> </html>

View file

@ -7,46 +7,31 @@ html {
button { button {
padding: 10px; padding: 10px;
font-size: 1em; font-size: 1em;
background-color: #c099ff; background-color: var(--mauve);
border-radius: 10px; border-radius: 10px;
border: 3px solid #d0aaff; border: 1px solid #d0aaff;
color: #191622; color: var(--mantle);
cursor: pointer; cursor: pointer;
} }
.cards {
text-align: center;
}
input { input {
padding: 10px; padding: 10px;
font-size: 1em; font-size: 1em;
background-color: #886db4; background-color: var(--mauve);
border-radius: 10px; border-radius: 10px;
border: 3px solid #644f84; border: 1px solid #644f84;
color: #191622; color: var(--mantle);
cursor: text; cursor: text;
outline: none; outline: none;
transition: background-color 0.25s, border 0.25s; transition: background-color 0.25s, border 0.25s;
} }
.inputButton {
padding: 10px;
font-size: 1em;
background-color: #886db4;
border-radius: 10px;
border: 3px solid #644f84;
color: #191622;
cursor: pointer;
outline: none;
transition: background-color 0.25s, border 0.25s;
}
input::placeholder { input::placeholder {
color: #3f3f3f; color: var(--surface1);
}
input:not(:placeholder-shown),
.inputButton:hover {
background-color: #a986e2;
border-radius: 10px;
border-color:rgb(168, 134, 209);
} }
p:not(.hint) { p:not(.hint) {
@ -55,7 +40,7 @@ p:not(.hint) {
button:hover { button:hover {
background-color: #cdadff; background-color: #cdadff;
border: 3px solid rgb(201, 161, 250); border: 1px solid rgb(201, 161, 250);
} }
button:active { button:active {
@ -64,9 +49,9 @@ button:active {
.main { .main {
padding: 150px 225px; padding: 150px 225px;
background-color: #3a3a3a; background-color: var(--surface0);
border-radius: 10px; border-radius: 10px;
border: 5px solid #3f3f3f; border: 1px solid #3f3f3f;
max-width: 450px; max-width: 450px;
max-height: 300px; max-height: 300px;
display: flex; display: flex;
@ -77,8 +62,8 @@ button:active {
#offscreenalert { #offscreenalert {
position: absolute; position: absolute;
padding: 20px; padding: 20px;
background-color: #3a3a3a; background-color: var(--surface0);
border: 3px solid #3f3f3f; border: 1px solid var(--surface1);
border-radius: 4px; border-radius: 4px;
top: -70px; top: -70px;
transition: 0.4s cubic-bezier(.68,-0.55,.27,1.55); transition: 0.4s cubic-bezier(.68,-0.55,.27,1.55);