A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://www.w3resource.com/html-css-exercise/css-properties/border-bottom-animatable-answer.php below:

Website Navigation


CSS Properties: How to specify the border bottom color is animatable?

CSS Properties: How to specify the border bottom color is animatable?Last update on February 20 2024 12:25:52 (UTC/GMT +8 hours)

Go to Exercise page

Solution:

HTML Code:

<!DOCTYPE html><!-- Declaration of HTML5 document type -->
<html>
<head>
<title>How to specify the border bottom color is animatable</title><!-- Title of the HTML document -->
<style>/* CSS style start*/
#DIV {
width: 150px; /* Setting the width of the div with ID "DIV" */
height: 100px; /* Setting the height of the div with ID "DIV" */
border: 10px solid black; /* Setting a solid black border with a width of 10 pixels for the div with ID "DIV" */
-webkit-animation: mymove 5s infinite; /* Applying a WebKit animation named "mymove" with a duration of 5 seconds and infinite repetition to the div with ID "DIV" */
animation: mymove 5s infinite; /* Applying an animation named "mymove" with a duration of 5 seconds and infinite repetition to the div with ID "DIV" */
 }
@keyframes mymove {
50% {border-bottom-color: #CC63FF;} /* Defining a keyframe animation named "mymove" where at 50% of the animation duration, the border bottom color changes to #CC63FF */
}
</style>
</head>
<body>
<div id="DIV">CSS, stands for Cascading Style Sheet is a computer language to describe presentation.</div><!-- Div element with ID "DIV" containing text content -->
</body>
</html>

Explanation:

Live Demo:

See the Pen border-bottom-animatable-answer by w3resource (@w3resource) on CodePen.


x

See the solution in the browser

Supported browser

Go to Exercise page

What is the difficulty level of this exercise?

Test your Programming skills with w3resource's quiz.




RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4