useRounded

Commons
stable

Resolves the `rounded` prop to border-radius classes and inline styles. Supports the modern utility taxonomy (xs/sm/md/lg/xl/none/full), the legacy named variants (x-small/small/default/medium/large/x-large/shaped), numbers and free-form CSS values.

API

Signature

Full TypeScript signature sourced from the composable file.

typescript

Inline roundedStyles is always emitted alongside the class because component scoped rules (specificity 0,2,0) routinely win over utility classes (0,1,0). The inline style lands at specificity 1,0,0 and wins everywhere.

Consumed interfaces

IRoundedProps

API

Parameters

Input parameters accepted by this composable.

props
required
IRoundedProps | Ref<boolean | number | string | TRounded | null | undefined>
Either the component props object or a plain Ref. Reads the `rounded` value.
name
string
getCurrentInstanceName()
Component name prefix for the `{name}--rounded-*` legacy classes.

API

Return values

Properties and methods exposed by the composable return object.

roundedClasses
Utility classes (origam--rounded-*) for modern rungs, or component-local classes for legacy named variants.
roundedStyles
Inline border-radius declaration. Always emitted alongside the class to win cascade specificity battles against scoped component rules.

Usage

Examples

Ready-to-paste usage snippets.

Radius presets

vue