A RetroSearch Logo

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

Search Query:

Showing content from https://webplatform.github.io/docs/css/selectors/pseudo-elements/first-line below:

::first-line ยท WebPlatform Docs

::first-line Summary

Represents the first line of an element. Note that the content of the first line varies depending on the available width and the styling of text (size, spacing).

Syntax
::first-line {}
Usage

The ::first-line pseudo-element can be attached to block-level elements. It can be attached to inline elements if you set the corresponding display property to block.

Examples

The following example puts the first line of any paragraph in bold text

p::first-line {
    font-weight: bold;
}

View live example

Notes Remarks

Only the following properties apply to the ::first-letter pseudo-element: background, clear, color, font, font-family, font-size, font-style, font-variant, font-weight, line-height, text-decoration, text-transform, vertical-align, and word-spacing

Related specifications
W3C CSS 2.1 Selectors
W3C Recommendation
W3C CSS Selectors Level 3
W3C Recommendation
Attributions

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