Skip to content

Commit

Permalink
feat: add style for visually hidden (kufu#963)
Browse files Browse the repository at this point in the history
* feat: add style for visually hidden

* chore: change variable name
  • Loading branch information
im36-123 committed Sep 7, 2020
1 parent f638d6b commit fda4ccf
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 1 deletion.
14 changes: 14 additions & 0 deletions src/constants.ts
@@ -1 +1,15 @@
import { css } from 'styled-components'

export const VISUALLY_HIDDEN_STYLE = css`
position: absolute;
width: 1px;
height: 1px;
margin: -1px;
border: 0;
padding: 0;
white-space: nowrap;
clip-path: inset(100%);
clip: rect(0 0 0 0);
overflow: hidden;
`
export const FONT_FAMILY = 'system-ui, sans-serif'
2 changes: 1 addition & 1 deletion src/index.ts
Expand Up @@ -87,7 +87,7 @@ export { defaultFrame } from './themes/createFrame'
export { defaultSize } from './themes/createSize'

// constants
export { FONT_FAMILY } from './constants'
export { FONT_FAMILY, VISUALLY_HIDDEN_STYLE } from './constants'

// utils
export { SequencePrefixIdProvider } from './hooks/useId'

0 comments on commit fda4ccf

Please sign in to comment.