JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 14
  • Score
    100M100P100Q52999F
  • License MIT

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

Package Exports

  • sanity-web-styles

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (sanity-web-styles) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

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