1.0.0-alpha.13 • Published 5 years ago

sanity-web-styles v1.0.0-alpha.13

Weekly downloads
15
License
MIT
Repository
github
Last release
5 years ago

sanity-web-styles

Shared base styles, custom media and custom properties for web apps on Sanity.io.

npm install sanity-io/sanity-web-styles

npm version

Usage

To use the custom media and custom variables, configure your project using .postcssrc:

{
  "plugins": {
    "postcss-import": {},
    "postcss-preset-env": {
      "importFrom": [
        "node_modules/sanity-web-styles/src/custom-media.css",
        "node_modules/sanity-web-styles/src/custom-properties.css"
      ],
      "stage": 3,
      "features": {
        "nesting-rules": true,
        "custom-media-queries": {
          "preserve": false
        },
        "custom-properties": {
          "preserve": false
        }
      }
    }
  }
}

Import dist/sanity.css in your base CSS file:

@import "sanity-web-styles";

License

MIT © Sanity.io