@substrate-system/css-util
v0.0.5
Published
[![install size](https://packagephobia.com/badge?p=@substrate-system/css-util)](https://packagephobia.com/result?p=@substrate-system/css-util) [![semantic versioning](https://img.shields.io/badge/semver-2.0.0-blue?logo=semver&style=flat-square)](https://s
Downloads
102
Readme
CSS util
Common CSS
install
npm i -S @substrate-system/css-util
use
This exposes CSS only.
Import CSS
import '@substrate-system/css-util'
Or minified:
import '@substrate-system/css-util/min'
pre-built
This package contains minified CSS files too. Copy them to a location that is accessible to your web server, then link to them in HTML.
copy
cp ./node_modules/@substrate-system/css-util/dist/index.min.css ./public/css-util.css
HTML
<head>
<link rel="stylesheet" href="./css-util.css">
</head>
<body>
<!-- ... -->
</body>
modules
visually-hidden
import '@substrate-system/css-util/visually-hidden'
// or minified
import '@substrate-system/css-util/min/visually-hidden'
Corresponds to the class .visaully-hidden
. This is explained in the article Accessible Icon Buttons. It is a utility class to hide content visually while keeping it screen-reader accessible.
arrow
Factor out the css for back / next arrows, so there is less duplication.
import '@substrate-system/css-util/arrow'
minified
import '@substrate-system/css-util/min/arrow'