Created
July 21, 2025 09:53
-
-
Save Aestheticsuraj234/0825d2ea19cc34928afe67e37c477828 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!DOCTYPE html> | |
| <html lang="en"> | |
| <head> | |
| <meta charset="UTF-8"> | |
| <title>Kaya Loader</title> | |
| <style> | |
| body { | |
| background: #fff; | |
| display: flex; | |
| justify-content: center; | |
| align-items: center; | |
| height: 100vh; | |
| } | |
| .loader-container { | |
| width: 180px; | |
| height: 60px; | |
| } | |
| .kaya-svg { | |
| width: 100%; | |
| height: 100%; | |
| display: block; | |
| } | |
| /* Animate the fill rectangle inside the house */ | |
| #fillRect { | |
| transition: y 0.4s, height 0.4s; | |
| } | |
| </style> | |
| </head> | |
| <body> | |
| <div class="loader-container"> | |
| <svg class="kaya-svg" viewBox="0 0 300 100"> | |
| <!-- Main K shape (stylized) --> | |
| <polygon points="10,90 10,10 40,10 40,55 75,10 95,10 50,70 95,90 75,90 40,60 40,90" | |
| fill="#ccc"/> | |
| <!-- House outline --> | |
| <rect x="30" y="30" width="40" height="40" fill="#fff" stroke="#ccc" stroke-width="2"/> | |
| <!-- Filling (animated) --> | |
| <clipPath id="house-clip"> | |
| <rect x="30" y="30" width="40" height="40"/> | |
| </clipPath> | |
| <rect id="fillRect" x="30" y="70" width="40" height="0" fill="#F5B967" clip-path="url(#house-clip)"/> | |
| <!-- Window --> | |
| <rect x="45" y="45" width="10" height="10" fill="#fff"/> | |
| <line x1="50" y1="45" x2="50" y2="55" stroke="#F5B967" stroke-width="1"/> | |
| <line x1="45" y1="50" x2="55" y2="50" stroke="#F5B967" stroke-width="1"/> | |
| <!-- The text "KAYA" in background (optional, faded) --> | |
| <text x="80" y="75" fill="#eee" font-size="70" font-family="serif" letter-spacing="15">KAYA</text> | |
| </svg> | |
| </div> | |
| <script> | |
| // JavaScript to animate the fillRect (fills from bottom up) | |
| let progress = 0; | |
| function animateFill() { | |
| progress += 1; // percentage | |
| let maxH = 40; // max height for the house rect | |
| let newH = maxH * (progress / 100); | |
| let newY = 70 - newH; | |
| document.getElementById('fillRect').setAttribute('y', newY); | |
| document.getElementById('fillRect').setAttribute('height', newH); | |
| if (progress < 100) { | |
| requestAnimationFrame(animateFill); | |
| } | |
| } | |
| animateFill(); | |
| </script> | |
| </body> | |
| </html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment