FIND YOUR NEXT FEW LINES

Results for “width”

Small, practical examples. Search by task or narrow things down below.

30 snippets foundClear filters
CSSResponsive conditions & sizing

Adapt a component to its own container width

CSS: Container queries respond to a selected ancestor rather than the full viewport.

CSS✓ Tested
CSSBox dimensions & overflow

Cap a box’s width

CSS: Max-width constrains an otherwise larger declared width.

CSS✓ Tested
PowerShellDates & numeric validation

Compute beyond the fixed-width integer range

PowerShell: BigInteger keeps an exact result when ordinary integer types are too small.

PowerShell✓ Tested
CSSType & reading flow

Control tab width in preformatted content

CSS: Tab-size defines the interval of tab stops in a preformatted block.

CSS✓ Tested
JavaScriptNumbers & numeric validation

Display a number with a fixed decimal width

JavaScript: toFixed returns a formatted string rather than a numeric value.

JavaScript✓ Tested
TypeScriptNumbers & numeric validation

Display a number with a fixed decimal width

TypeScript: toFixed returns a formatted string rather than a numeric value.

TypeScript✓ Tested
CSSBox dimensions & overflow

Enforce a minimum width

CSS: Min-width can prevent a declared smaller width from taking effect.

CSS✓ Tested
CSSResponsive conditions & sizing

Enhance a layout above a minimum viewport width

CSS: A mobile-first min-width query adds columns when enough horizontal space is available.

CSS✓ Tested
CSSGetting Started

Include padding in an element’s width

CSS: Learn how to include padding in an element’s width in a complete browser example.

CSS✓ Tested
CSSInteraction & themes

Include padding in element width

Use border-box to keep CSS padding and borders inside the declared width.

CSS✓ Tested
CSSGetting Started

Limit a content column’s width

CSS: Learn how to limit a content column’s width in a complete browser example.

CSS✓ Tested
C#Text validation & encoding

Pad a numeric label to a fixed width

C#: Use a numeric format specifier to add leading zeroes.

C#✓ Tested