Front End Technology Articles

Page 518 of 652

Perform Animation on the background-color property with CSS

karthikeya Boyini
karthikeya Boyini
Updated on 15-Mar-2026 193 Views

The CSS background-color property can be animated using CSS animations and keyframes to create smooth color transitions. This technique is commonly used to create hover effects, attention-grabbing elements, and interactive visual feedback. Syntax selector { background-color: initial-color; animation: animation-name duration timing-function iteration-count; } @keyframes animation-name { percentage { background-color: target-color; } } Example: Basic Background Color Animation The following example demonstrates a continuous background color animation that transitions from ...

Read More

Animated background with CSS

Chandu yadav
Chandu yadav
Updated on 15-Mar-2026 719 Views

CSS animated backgrounds allow you to create dynamic visual effects by changing background properties over time. The @keyframes rule defines the animation sequence, while the animation property applies it to elements. Syntax @keyframes animation-name { from { background: initial-state; } to { background: final-state; } } selector { animation: animation-name duration timing-function iteration-count; } Example: Color Transition Animation The following example demonstrates a smooth background color transition that cycles through different colors − ...

Read More

Set the initial length of a flex item with CSS

Samual Sam
Samual Sam
Updated on 15-Mar-2026 160 Views

The CSS flex-basis property sets the initial main size of a flex item before free space is distributed. It defines the default size of an element before the remaining space is distributed according to the flex factors. Syntax selector { flex-basis: value; } Possible Values ValueDescription autoDefault value. The length is equal to the length of the flexible item lengthA length unit (px, em, rem, etc.) specifying the initial length %A percentage of the parent container's main size contentSize based on the item's content Example The ...

Read More

Set how much a flex item will grow relative to the rest of the flex items with CSS

Samual Sam
Samual Sam
Updated on 15-Mar-2026 194 Views

The CSS flex-grow property controls how much a flex item will grow relative to the rest of the flex items inside a flex container. When there's extra space available, this property determines how that space is distributed among flex items. Syntax selector { flex-grow: number; } Possible Values ValueDescription 0Default value. Item will not grow. numberA positive number that defines the growth factor relative to other flex items. Example: Basic Flex Grow The following example demonstrates how flex-grow distributes extra space. The third item (Q3) has ...

Read More

Avoid wrapping flex items with CSS

Yaswanth Varma
Yaswanth Varma
Updated on 15-Mar-2026 5K+ Views

The CSS flexbox layout allows you to arrange elements in flexible containers. By default, flex items try to fit in a single line, but when they exceed the container width, they may wrap to new lines. To prevent this wrapping behavior, you can use the flex-wrap property with the nowrap value. Syntax .container { display: flex; flex-wrap: nowrap; } CSS flex-wrap Property The flex-wrap property controls whether flex items wrap onto multiple lines or stay on a single line. When set to nowrap, all flex items ...

Read More

Display the flex items with space between the lines in CSS

Lakshmi Srinivas
Lakshmi Srinivas
Updated on 15-Mar-2026 245 Views

The CSS justify-content property with the space-between value distributes flex items evenly across the main axis, placing the first item at the start and the last item at the end, with equal space between all items. Syntax selector { display: flex; justify-content: space-between; } Example You can try to run the following code to implement the space-between value − .mycontainer { ...

Read More

Wrap the flex items with CSS

karthikeya Boyini
karthikeya Boyini
Updated on 15-Mar-2026 224 Views

The CSS flex-wrap property controls whether flex items are forced onto a single line or can wrap onto multiple lines within a flex container. By default, flex items try to fit on one line, but wrapping allows them to break onto new lines when there isn't enough space. Syntax selector { flex-wrap: value; } Possible Values ValueDescription nowrapDefault. Items are laid out in a single line wrapItems wrap onto multiple lines if needed wrap-reverseItems wrap onto multiple lines in reverse order Example: Basic Flex Wrap The ...

Read More

CSS nav-left property

George John
George John
Updated on 15-Mar-2026 242 Views

The CSS nav-left property defines which element to focus on when the user presses the left arrow key on their keyboard or remote control. This property is primarily designed for TV browsers and devices where navigation is done using directional keys rather than a mouse. Syntax selector { nav-left: target-element; } Possible Values ValueDescription #idID of the element to navigate to when left key is pressed autoBrowser determines the next element automatically Example The following example creates a navigation system where pressing the left arrow key ...

Read More

Set the flex items horizontally from right to left with CSS

Samual Sam
Samual Sam
Updated on 15-Mar-2026 253 Views

Use the flex-direction property with row-reverse value to set the flex items horizontally from right to left. This property reverses the order of flex items while maintaining horizontal alignment. Syntax selector { display: flex; flex-direction: row-reverse; } Example You can try to run the following code to implement the row-reverse value − .mycontainer { display: flex; ...

Read More

Usage of CSS grid-auto-rows property

Chandu yadav
Chandu yadav
Updated on 15-Mar-2026 109 Views

The CSS grid-auto-rows property sets the default height for grid rows that are created automatically (implicitly) when grid items don't fit in the explicitly defined rows. This property is essential for controlling the sizing of rows in CSS Grid layouts. Syntax selector { grid-auto-rows: value; } Possible Values ValueDescription lengthFixed size in px, em, rem, etc. %Percentage of the grid container's height min-contentMinimum size needed to fit content max-contentMaximum size needed for content autoSize based on content (default) frFraction of available space Example: Fixed Row Height ...

Read More
Showing 5171–5180 of 6,519 articles
« Prev 1 516 517 518 519 520 652 Next »
Advertisements