{"name":"@stitches/core","version":"0.1.0-canary.5","description":"The modern CSS-in-JS library","type":"module","typings":"types/index.d.ts","main":"dist/stitches.core.cjs.cjs","module":"dist/stitches.core.esm.mjs","unpkg":"dist/stitches.core.iife.js","license":"MIT","repository":{"type":"git","url":"git+https://github.com/modulz/stitches.git"},"homepage":"https://github.com/modulz/stitches#readme","bugs":{"url":"https://github.com/modulz/stitches/issues"},"contributors":[{"name":"Christian Alfoni","email":"christianalfoni@gmail.com"},{"name":"Pedro Duarte","email":"pedro@modulz.app"},{"name":"Abdulhadi Alhallak","email":"abdulhadi@modulz.app"},{"name":"Jonathan Neal","email":"jonathan@modulz.app"}],"publishConfig":{"access":"public"},"keywords":["component","components","create","css","css-in-js","global","globals","javascript","js","nesting","object","object-oriented","oo","oocss","oriented","scope","scoped","style","styled","styles","stylesheet","stylesheets","theme","themes","theming","token","tokens","type","typed","types","transform","ts","variable","variables"],"gitHead":"1ecaba8af46615e50a529bd91a3cdb1c261530a2","readme":"# Stitches Core\n\nNear-zero runtime, server-side rendering, multi-variant support, and best-in-class developer experience.\n\n## Get started\n\n```sh\nnpm install @stitches/core\n```\n\n```js\nimport createCss from '@stitches/core'\n\nconst sheet = createCss({\n  theme: {\n    colors: {\n      black: '#2f2f2f',\n      white: '#f3f3f3',\n    },\n  },\n})\n\nconst button = sheet.css({\n  all: 'unset',\n  boxShadow: '0 0 0 1px $black',\n  backgroundColor: '$black',\n  color: '$white',\n  padding: '.5em 1em',\n})\n\nconst alertButton = sheet.css(button, {\n  boxShadow: '0 0 0 1px red',\n})\n\nconsole.log(`<button class=\"${button}\">`) // html will include a unique class name for the button component\nconsole.log(`<style>${sheet}</style>`) // css will include a unique rule for the button component\n```\n\n## Configure an instance\n\n```js\nimport createCss from '@stitches/core'\n\nexport const { css } = createCss({\n  // adds a prefix to all classnames to avoid clashes\n  prefix: 'my-lib',\n\n  // maps tokens to properties\n  theme: {\n    colors: {\n      red: 'tomato',\n    },\n    space: {\n      0: '1rem',\n    },\n  },\n\n  // creates breakpoints with media queries\n  conditions: {\n    tablet: '@media (min-width: 700px)',\n  },\n\n  // creates or configures css properties\n  utils: {\n    mX: (value) => ({\n      marginLeft: value,\n      marginRight: value,\n    }),\n    mY: (value) => ({\n      marginTop: value,\n      marginBottom: value,\n    }),\n  },\n})\n\ncss({\n  // assigns a custom property that resolves `tomato`\n  color: '$red',\n\n  // assigns `0` to `margin-left` and `margin-right`\n  marginX: 0,\n\n  // assign \"blue\" when the breakpoint is matched\n  when: {\n    tablet: {\n      color: 'blue',\n    },\n  },\n})\n```\n\n## Themes\n\nCreate themes to override defaults:\n\n```js\nimport createCss from '@stitches/core'\n\nexport const { css } = createCss({\n  theme: {\n    colors: {\n      primary: 'tomato',\n    },\n  },\n})\n\nexport const curiousTheme = css.theme({\n  colors: {\n    primary: 'pink',\n  },\n})\n```\n","readmeFilename":"README.md","_id":"@stitches/core@0.1.0-canary.5","_nodeVersion":"15.5.0","_npmVersion":"lerna/3.22.1/node@v15.5.0+arm64 (darwin)","dist":{"integrity":"sha512-WfAVbKUcqAfg3tzLyZ5JnU1pHCOgHFKbJMhKcvSc/sdQPrQTk6nFs/X3V/FipUNTHXN0Ycw4+zP/VUFGaIPpzg==","shasum":"a0c32e33676606097c4841b3175cd1de7028e60f","tarball":"http://registry-npm.ywwl.com/@stitches/core/download/@stitches/core-0.1.0-canary.5.tgz","fileCount":9,"unpackedSize":420094,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJgK9OKCRA9TVsSAnZWagAAPDMP/A3UudVqiOWTCMknKRZH\neo59WyUo3pf/DytXmT1A+BnJLF6VtQXa7/nYtHzBtkGGAe20G4OYEcdGFptJ\nNsZ9n5t4jvO1NZDbOAv6F7IjiOjjCvTlcuBuvOfgjojlgkOofZbKFhuJHfaQ\nqlh45WWQ3yLfRAVcVG2Tf65DvXgq9mL02PqqNdChsRN2f1+BG2VbZfnIHDGc\n/rEjoTVwmxxM0Ri8Xb1jQj/vWsJ5ZvqyWixgtbhAGcbr1x7ZFDUPvsw9JzRC\nYPvBE5MCpU084PcrP64ppaUBeEAf8gt6STlyY69UtvK2VX5gl0eR7PtLILag\n4y10hMVCaOdm6fs0S3N+FG6SDIJT6IBkqbevrhYK3t24ut7UhgR5kf1LMwN9\nLbNGBoKiRa+lkejgmhF9E0/r1p/xYUOaim6wNU/YXy5oQ5xXeKWdxiERQlvZ\n2cPmRkUqGW3LNsveZdnwkgkTvF5wyOETtSmbqcMHlLupEQlgcD3ljSmblf5K\nCbiyrBjBusECvq1+KpDWS28xe28KO+TVhzXOyiuFeO8lkcJ16XoiFuxYkMuL\nPK7CctkDqOTbOVl+KjHDDDtBLs11f/bpk011EVCW4BK2i8b5OZZgPxgXp4kT\nU36A43KIoALnCiLvozv+0dnIMhgxt9MpQEXORN+695n03rgBW6ScK8YQrd2v\nRD5q\r\n=yxL4\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIClCxLDUr0FLwJJoltcB1ZmRKwLi9UspQ8LXX+8trRtFAiBD2xMlXfWFnjW65A3OyGmcB4i4DX/w28nF6ZshBp2OPQ=="}],"size":73280,"noattachment":false,"key":"/@stitches/core/-/@stitches/core-0.1.0-canary.5.tgz"},"_npmUser":{"name":"jonathantneal","email":"jonathantneal@hotmail.com"},"directories":{},"maintainers":[{"name":"jonathantneal","email":"jonathantneal@hotmail.com"},{"name":"colmtuite","email":"colmtuite@gmail.com"},{"name":"peduarte","email":"contact@peduarte.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/core_0.1.0-canary.5_1613484937639_0.6225869861865596"},"_hasShrinkwrap":false,"publish_time":1613484937798,"_cnpm_publish_time":1613484937798,"dist-tags":{"canary":"1.3.1-1","latest":"1.2.8"}}