1- import {
2- Meta ,
3- Intro ,
4- Status ,
5- Props ,
6- Story ,
7- } from ' ../../../.storybook/components' ;
8- import * as Stories from ' ./utility.stories.tsx' ;
1+ import { Meta , Intro , Story , Status } from " ../../../.storybook/components" ;
2+ import * as Stories from " ./utility.stories" ;
3+
4+ <Meta of = { Stories } />
95
106# Utility classes
117
8+ <Status variant = " stable" />
9+
1210<Intro >
13- < Intro >
14- Utility classes provide reusable ` className ` values for applying some common Circuit UI styling patterns to elements and components.
15- </ Intro > </Intro >
11+ Utility classes provide reusable ` className ` values for applying some common
12+ Circuit UI styling patterns to elements and components.
13+ </Intro >
1614
1715## Usage
18- Import the ` utilClasses ` object from ` @sumup-oss/@circuit-ui ` and pass the desired utility class to the `className ` prop .
16+
17+ Import the ` utilClasses ` object from ` @sumup-oss/circuit-ui ` and pass the desired utility class to the `className ` prop .
1918
2019```tsx
21- import { utilClasses } from ' @sumup-oss/circuit-ui' ;
20+ import { utilClasses } from " @sumup-oss/circuit-ui" ;
2221
2322function MyComponent() {
24- return <div className = { utilClasses [' <className>' ]} />;
23+ return <div className = { utilClasses [" <className>" ]} />;
2524}
26-
2725```
2826
29- <Meta of={Stories} />
30-
3127## Center
32- `utilClasses.center`
3328
29+ `utilClasses.center`
3430
3531Pass the utility class to a parent element to center its children.
3632
3733<Story of={Stories.Center} />
3834
3935## Hide Visually
36+
4037`utilClasses.hideVisually`
4138
4239Visually hides an element while keeping it accessible to users
@@ -45,16 +42,16 @@ who rely on a screen reader.
4542<Story of={Stories.HideVisually} />
4643
4744## Hide scrollbar
45+
4846`utilClasses.hideScrollbar`
4947
5048Hides the browser scrollbar on a scrollable element, e.g. with overflow.
5149
5250<Story of={Stories.HideScrollbar} />
5351
54-
5552## Focus
56- `utilClasses.focusVisible` or `utilClasses.focusVisibleInset`
5753
54+ `utilClasses.focusVisible` or `utilClasses.focusVisibleInset`
5855
5956Shows a focus indicator when the browser determines that focus should be visible, such as during keyboard navigation.
6057
0 commit comments