Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <div id="cont">
- <img class=cont src="https://data.whicdn.com/images/343458131/original.jpg">
- <div id="scroll">
- about me info info info edit the css of this text in #scroll or make a new class ~~
- </div>
- </div>
- <style>
- #cont {
- width: 300px;
- height: 170px;
- border-radius: 20px;
- border: 4px double #ffeaf6;
- padding: 0px;
- position: relative;
- overflow: hidden;
- }
- .cont {
- width: 100%;
- height: 100%;
- object-fit: cover;
- position: absolute;
- }
- #scroll {
- position: absolute;
- width: 94%;
- height: 150px;
- background: white;
- padding: 10px;
- border-radius: 16px;
- z-index: 99;
- top: 100%;
- transition: 1s ease;
- }
- #cont:hover #scroll {
- top: 0%;
- }
- </style>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement