margin: Margins

View source: R/design-spacing.R

marginR Documentation

Margins

Description

The margin utilty changes the outer spacing of a tag element. The margin of a tag element is the space outside and around the tag element, its border, and its content. All arguments default to NULL, in which case they are ignored.

Usage

margin(x, all = NULL, top = NULL, right = NULL, bottom = NULL, left = NULL)

Arguments

x

A tag element or .style pronoun.

all, top, right, bottom, left

A responsive argument. One of -5:5 or "auto" specifying a margin for one or more sides of the tag element. 0 removes all outer space, 5 adds the most space, and negative values will consume space pulling the element in that direction.

Examples


div() %>% margin(2)
# ->
div() %>% cascadess::margin_all(2)


nteetor/dull documentation built on Nov. 7, 2024, 2:11 p.m.