AmitDiwan has Published 10744 Articles

Specify Word Breaking Rules using CSS3

AmitDiwan

AmitDiwan

Updated on 27-Dec-2023 16:34:01

191 Views

To specify word breaking rules in CSS3, use the word-break property. This property is used to break the line. Let us see the syntax − word-break: value; The values include normal − The default line break rules. break-all − The word is broken at any character ... Read More

Some Lesser-Known CSS Properties for Form Input Fields

AmitDiwan

AmitDiwan

Updated on 27-Dec-2023 16:32:36

185 Views

CSS caret-color, pointer-events and tab-size are some of the lesser-known properties for form input fields. caret-color property allows us specify color of blinking caret while pointer-events can help prevent the users to find an element. Finally, tab-size sets the amount of white space used by tab. The following examples illustrate ... Read More

Smooth Scrolling with Pure CSS

AmitDiwan

AmitDiwan

Updated on 27-Dec-2023 16:31:01

472 Views

The CSS scroll-behavior property allows us to change the behavior of scroll. The following are the values are set within the scrolling box − auto − A scroll effect is set between the elements within the scrolling box. Smooth − A smooth animated scroll effect is set between the ... Read More

Setting the size of the radial gradients using CSS

AmitDiwan

AmitDiwan

Updated on 27-Dec-2023 16:29:59

1K+ Views

To set the size of the radial gradient, use the radial-gradient() function. This function sets a radial gradient as the background image. The second parameter in the function is to be set as the size you want as in the below example − background-image: radial-gradient(40% 50px at center, rgb(30, ... Read More

Setting the Location Color Stops using CSS

AmitDiwan

AmitDiwan

Updated on 27-Dec-2023 16:27:33

215 Views

To create linear gradient, use the linear-gradient() method of the background-image property. Syntax The following is the syntax − background-image: linear-gradient(angle, color-stop1, color-stop2); The location at color stops can be set as a percentage or absolute length. For example, for linear gradient. The color stops are the colors ... Read More

Setting the Image Brightness using CSS3

AmitDiwan

AmitDiwan

Updated on 27-Dec-2023 16:24:14

16K+ Views

To set image brightness in CSS, use filter brightness (%). Remember, the value 0 makes the image black, 100% is for original image and default. Rest, you can set any value of your choice, but values above 100% would make the image brighter. The filter property is used to set ... Read More

Setting Text Alignment using CSS

AmitDiwan

AmitDiwan

Updated on 27-Dec-2023 16:22:31

224 Views

We can align the text in html documents using CSS text-align property for horizontal alignment and CSS padding-top with CSS padding-bottom, or CSS line-height for vertical alignment. The writing-mode can also be used for this property. Syntax The following is the syntax for above mentioned CSS properties − Selector ... Read More

Setting Tab Sizes in HTML with CSS tab-size Property

AmitDiwan

AmitDiwan

Updated on 27-Dec-2023 16:19:55

655 Views

CSS tab-size property allows us to set the amount of whitespace used in tabs. The width of the tab character can be customized easily. The value set for the tab size is in spaces. Let us see the syntax. Syntax tab-size: value; The value above is the ... Read More

Setting Spaces between Letters with CSS letter-spacing Property

AmitDiwan

AmitDiwan

Updated on 27-Dec-2023 16:17:32

268 Views

Using the CSS letter-spacing property, we can specify the amount of space between letters of text. The letter spacing can be set in px, em, etc. length units. Let us see the syntax. Syntax The following is the syntax of the letter-spacing property − letter-spacing: value; The value ... Read More

Setting Margins for Individual Sides using CSS

AmitDiwan

AmitDiwan

Updated on 27-Dec-2023 16:16:19

320 Views

CSS allows us to control the space around individual sides of an element. The CSS margin property is a shorthand for the following properties: margin-top, margin-right, margin-bottom and margin-left. Syntax The syntax of CSS margin property is as follows − Selector { margin-top: /*value*/ ... Read More

Advertisements