Добавил кубик
This commit is contained in:
@@ -1,21 +0,0 @@
|
|||||||
MIT License
|
|
||||||
|
|
||||||
Copyright (c) 2026 Ilia Miheev
|
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
||||||
of this software and associated documentation files (the "Software"), to deal
|
|
||||||
in the Software without restriction, including without limitation the rights
|
|
||||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
||||||
copies of the Software, and to permit persons to whom the Software is
|
|
||||||
furnished to do so, subject to the following conditions:
|
|
||||||
|
|
||||||
The above copyright notice and this permission notice shall be included in all
|
|
||||||
copies or substantial portions of the Software.
|
|
||||||
|
|
||||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
||||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
||||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
||||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
||||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
||||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
||||||
SOFTWARE.
|
|
||||||
BIN
Binary file not shown.
|
After Width: | Height: | Size: 10 KiB |
+23
@@ -0,0 +1,23 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="ru">
|
||||||
|
<head>
|
||||||
|
<meta charset="UTF-8" />
|
||||||
|
<link rel="icon" href="./favicon.ico" type="image/x-icon">
|
||||||
|
<title>beautiful-cube</title>
|
||||||
|
<link rel="stylesheet" href="./style.css" />
|
||||||
|
</head>
|
||||||
|
|
||||||
|
<body>
|
||||||
|
<h1>beautiful-cube</h1>
|
||||||
|
<div id="wrapper">
|
||||||
|
<div class="cube">
|
||||||
|
<div class="face front">front</div>
|
||||||
|
<div class="face back">back</div>
|
||||||
|
<div class="face left">left</div>
|
||||||
|
<div class="face right">right</div>
|
||||||
|
<div class="face top">top</div>
|
||||||
|
<div class="face bottom">bottom</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
@@ -0,0 +1,81 @@
|
|||||||
|
* {
|
||||||
|
margin: 0;
|
||||||
|
padding: 0;
|
||||||
|
box-sizing: border-box;
|
||||||
|
}
|
||||||
|
|
||||||
|
::selection {
|
||||||
|
background-color: orangered;
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
|
||||||
|
body {
|
||||||
|
background-color: #222;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
justify-content: center;
|
||||||
|
align-items: center;
|
||||||
|
height: 100vh;
|
||||||
|
overflow: hidden;
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
|
||||||
|
h1 {
|
||||||
|
position: fixed;
|
||||||
|
top: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
#wrapper {
|
||||||
|
perspective: 600px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.cube {
|
||||||
|
width: 200px;
|
||||||
|
height: 200px;
|
||||||
|
transform-style: preserve-3d;
|
||||||
|
animation: rotateCube 6s infinite linear;
|
||||||
|
}
|
||||||
|
|
||||||
|
.face {
|
||||||
|
position: absolute;
|
||||||
|
width: 200px;
|
||||||
|
height: 200px;
|
||||||
|
border: 2px solid orangered;
|
||||||
|
text-align: center;
|
||||||
|
padding-top: 50%;
|
||||||
|
font-size: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.front {
|
||||||
|
transform: rotateY(0deg) translateZ(100px);
|
||||||
|
}
|
||||||
|
|
||||||
|
.back {
|
||||||
|
transform: rotateY(180deg) translateZ(100px);
|
||||||
|
}
|
||||||
|
|
||||||
|
.left {
|
||||||
|
transform: rotateY(-90deg) translateZ(100px);
|
||||||
|
}
|
||||||
|
|
||||||
|
.right {
|
||||||
|
transform: rotateY(90deg) translateZ(100px);
|
||||||
|
}
|
||||||
|
|
||||||
|
.top {
|
||||||
|
transform: rotateX(90deg) translateZ(100px);
|
||||||
|
}
|
||||||
|
|
||||||
|
.bottom {
|
||||||
|
transform: rotateX(-90deg) translateZ(100px);
|
||||||
|
}
|
||||||
|
|
||||||
|
@keyframes rotateCube {
|
||||||
|
0% {
|
||||||
|
transform: rotateX(0deg);
|
||||||
|
}
|
||||||
|
|
||||||
|
100% {
|
||||||
|
transform: rotateX(360deg) rotateY(360deg);
|
||||||
|
}
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user