ControlGroup

A container for grouping form controls together with connected styling, ideal for search bars and input combinations.

Import
import { ControlGroup, Input, Button } from "@sugarcoat/ui-nxt";
Usage
<ControlGroup>
<Input placeholder="Search..." />
<Button>Search</Button>
</ControlGroup>

Examples#

Basic Control Group#

Search Input with Button

With Select and Input#

Category Search

Sizes#

Control the size of all grouped elements with the size prop.

Extra Small
Small
Medium (Default)
Large

Block Width#

Make the control group span the full width of its container.

Full Width

Border Styles#

Solid Border
Dashed Border
No Border

Practical Examples#

URL Input
Quantity Selector
Copy to Clipboard

Props#

PropTypeDefaultDescription
size"xs" | "sm" | "md" | "lg""md"The size of the control group and its children
blockbooleanfalseWhether the control group spans full width
border"solid" | "dashed" | "none""solid"The border style of the control group
childrenReactNode-Form control components to group together
Customize Theme
Build your own sugarcoat/ui theme
PresetLime / Violet / Slate
Brand ColorLime
Accent ColorViolet
Gray ScaleSlate
Border RadiusLg