Spacing

Set a dynamic scale for application whitespace.

Skeleton utilizes the power of Tailwind to provide a universal system for customizing spacing throughout your application. Enabling customization of this setting per each theme.

--spacing: 0.25rem

How It Works

In legacy versions of Skeleton, this was implement using custom mechanisms. However, starting Skeleton v3.0.0 and Tailwind 4.0.0, this now utilizes the official Tailwind Spacing property.

css
@layer theme {
	:root {
		--spacing: 0.25rem;
	}
}

With the added benefit this can be easily customized per Skeleton theme.

css
[data-theme='cerberus'] {
	--spacing: 0.25rem;
}

Supported Properties

The scaling system supports all relevant Tailwind utility classes, including, but not limited to:

padding, margin, width, minWidth, maxWidth, height, minHeight, maxHeight, gap, inset, space, translate

View page on GitHub