MCPcopy Create free account
hub / github.com/adobe/react-spectrum / centerPadding

Function centerPadding

packages/@react-spectrum/s2/src/style-utils.ts:34–36  ·  view source on GitHub ↗
(minHeight: string = 'self(minHeight)')

Source from the content-addressed store, hash-verified

32 * @returns A CSS `calc()` expression wrapped as an arbitrary style value.
33 */
34export function centerPadding(minHeight: string = 'self(minHeight)'): `[${string}]` {
35 return `[calc((${minHeight} - self(borderTopWidth, 0px) - self(borderBottomWidth, 0px) - 1lh) / 2)]`;
36}
37
38function fontRelative(base: number, baseFontSize = 14): `[${string}]` {
39 return `[${internalFontRelative(base, baseFontSize)}]`;

Callers 10

Disclosure.tsxFile · 0.90
Tooltip.tsxFile · 0.90
TextAreaInputFunction · 0.90
Menu.tsxFile · 0.90
ComboBox.tsxFile · 0.90
TableView.tsxFile · 0.90
barFunction · 0.90
fieldFunction · 0.85
controlFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected