Skip to content

Fallbacks for the W3C CSS generic system-ui font-family.

License

Notifications You must be signed in to change notification settings

dashed/system-ui

Repository files navigation

system-ui Build Status npm version

Greenkeeper badge

Fallbacks for the W3C CSS generic system-ui font-family.

Adapted from: https://github.com/JLHwung/postcss-font-family-system-ui

Install

$ yarn add system-ui
# npm v5+
$ npm install system-ui
# before npm v5
$ npm install --save system-ui

Usage

import system_ui from "system-ui";
import { injectGlobal } from "styled-components";

// system_ui == "system-ui, -apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Oxygen, Ubuntu, Cantarell, Fira Sans, Droid Sans, Helvetica Neue"

injectGlobal`
  body {
    font-family: ${system_ui}, sans-serif;
    font-size: 16px;

    color: #000;
  }
`;

Chores

  • Build: yarn build

  • Pretty: yarn pretty

License

MIT.

About

Fallbacks for the W3C CSS generic system-ui font-family.

Topics

Resources

License

Code of conduct

Stars

Watchers

Forks

Packages

No packages published