{"_id":"@csstools/utilities-for-private-properties","_rev":"1757756","name":"@csstools/utilities-for-private-properties","description":"Utilities for private custom properties","dist-tags":{"latest":"1.0.1"},"maintainers":[{"name":"jonathantneal","email":"jonathantneal@hotmail.com"},{"name":"alaguna","email":"sombragriselros@gmail.com"},{"name":"romainmenke","email":"romainmenke@gmail.com"}],"time":{"modified":"2026-11-22T02:53:56.000Z","created":"2026-11-17T12:22:22.567Z","1.0.1":"2026-11-17T12:49:28.334Z","1.0.0":"2026-11-17T12:24:30.690Z","0.0.0-stage":"2026-11-17T12:22:22.567Z"},"users":{},"repository":{"url":"git+https://github.com/csstools/postcss-plugins.git","type":"git","directory":"packages/utilities-for-private-properties"},"versions":{"1.0.1":{"_id":"@csstools/utilities-for-private-properties@1.0.1","bugs":{"url":"https://github.com/csstools/postcss-plugins/issues"},"dist":{"shasum":"45d78cd62f783bc73f2076bc33ad4ba3d5f1001d","tarball":"http://registry-npm.ywwl.com/@csstools/utilities-for-private-properties/download/@csstools/utilities-for-private-properties-1.0.1.tgz","fileCount":6,"integrity":"sha512-3xvIQTdcmQIWhFFpp78sQZ9h4apCBpihx640EzLNYSxWcT9/MI/6QBZcGJ2GDtUdMdOutW7rT4YLDRPPiGO2QA==","signatures":[{"sig":"MEYCIQDiRPQ9Bk75E6MiZX4hItuS2qE0aBIxHNtzsyaz5QGfHQIhAIsAjql3O0926Uau/tredYgAihkEPuxAuTa9F7uN0mlR","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEYCIQCdUSxGY9xWKcr1pLQZAXMMtN/1drJ808EmAxtjH3+DcQIhALX2ntEwT2M5NuOjnqOxInKkDsSeH/StT7UatbPee1af"}],"unpackedSize":16367,"size":5816,"noattachment":false,"key":"/@csstools/utilities-for-private-properties/-/@csstools/utilities-for-private-properties-1.0.1.tgz"},"name":"@csstools/utilities-for-private-properties","type":"module","engines":{"node":">=20.19.0"},"exports":{".":{"types":"./dist/index.d.ts","default":"./dist/index.mjs"}},"funding":[{"url":"https://github.com/sponsors/csstools","type":"github"},{"url":"https://opencollective.com/csstools","type":"opencollective"}],"gitHead":"31c8d1466ff8d7d633563034b5bcbeabdc60a78f","license":"MIT-0","scripts":{},"version":"1.0.1","_npmUser":{"name":"romainmenke","email":"romainmenke@gmail.com"},"homepage":"https://github.com/csstools/postcss-plugins/tree/main/packages/utilities-for-private-properties#readme","keywords":["css","custom-property","postcss","private"],"repository":{"url":"git+https://github.com/csstools/postcss-plugins.git","type":"git","directory":"packages/utilities-for-private-properties"},"_npmVersion":"11.13.0","description":"Utilities for private custom properties","directories":{},"maintainers":[{"name":"jonathantneal","email":"jonathantneal@hotmail.com"},{"name":"alaguna","email":"sombragriselros@gmail.com"},{"name":"romainmenke","email":"romainmenke@gmail.com"}],"_nodeVersion":"26.1.0","contributors":[{"url":"https://antonio.laguna.es","name":"Antonio Laguna","email":"antonio@laguna.es"},{"name":"Romain Menke","email":"romainmenke@gmail.com"}],"dependencies":{"@csstools/generate-idents":"^1.0.0","@csstools/utilities-for-property-registrations":"^1.0.0"},"_hasShrinkwrap":false,"peerDependencies":{"postcss":"^8.4","@csstools/css-tokenizer":"^4.0.3","@csstools/css-parser-algorithms":"^4.0.3"},"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/utilities-for-private-properties_1.0.1_1794919768246_0.17405850378139331"},"publish_time":1794919768334,"_cnpm_publish_time":1794919768334},"1.0.0":{"name":"@csstools/utilities-for-private-properties","version":"1.0.0","keywords":["css","custom-property","postcss","private"],"license":"MIT-0","_id":"@csstools/utilities-for-private-properties@1.0.0","maintainers":[{"name":"jonathantneal","email":"jonathantneal@hotmail.com"},{"name":"alaguna","email":"sombragriselros@gmail.com"},{"name":"romainmenke","email":"romainmenke@gmail.com"}],"contributors":[{"url":"https://antonio.laguna.es","name":"Antonio Laguna","email":"antonio@laguna.es"},{"name":"Romain Menke","email":"romainmenke@gmail.com"}],"homepage":"https://github.com/csstools/postcss-plugins/tree/main/packages/utilities-for-private-properties#readme","bugs":{"url":"https://github.com/csstools/postcss-plugins/issues"},"dist":{"shasum":"14368b04d9ff259d43cd3bdffe82ac304344c74e","tarball":"http://registry-npm.ywwl.com/@csstools/utilities-for-private-properties/download/@csstools/utilities-for-private-properties-1.0.0.tgz","fileCount":6,"integrity":"sha512-uacTn0CW3t5DGGsX3wYbN7uD+Cx/Ab/xHi1WF8hBm6R+UeP8t5C+ivMmMk22roymoxq9tCBCa3emqxcqN2qP2g==","signatures":[{"sig":"MEUCIET3eojd5Ut2fr3jAesgwnCJyPBnx98YAytSqo0VYJHVAiEA4Qy071csfYY8oUGwfi4vMnqI+8Ttdu2KD/8D6bx7E+0=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"sig":"MEUCIAFheRgZ/4JbSMWfGGN0ur0AsfkG5hx0Zj1O/NTSJExwAiEA4MksLwwKKisTUuzEp3f0ZwFOKJXzIJWShiqYwX5fHFg=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":16725,"size":5861,"noattachment":false,"key":"/@csstools/utilities-for-private-properties/-/@csstools/utilities-for-private-properties-1.0.0.tgz"},"type":"module","engines":{"node":">=20.19.0"},"exports":{".":{"types":"./dist/index.d.ts","default":"./dist/index.mjs"}},"funding":[{"url":"https://github.com/sponsors/csstools","type":"github"},{"url":"https://opencollective.com/csstools","type":"opencollective"}],"gitHead":"ef429b42ff9fe3efd48a17d40d8377488a8930a2","scripts":{},"_npmUser":{"name":"romainmenke","email":"romainmenke@gmail.com"},"repository":{"url":"git+https://github.com/csstools/postcss-plugins.git","type":"git","directory":"packages/utilities-for-private-properties"},"_npmVersion":"11.13.0","description":"Utilities for private custom properties","directories":{},"_nodeVersion":"26.1.0","dependencies":{"@csstools/generate-idents":"^1.0.0","@csstools/utilities-for-property-registrations":"^0.0.0"},"_hasShrinkwrap":false,"peerDependencies":{"postcss":"^8.4","@csstools/css-tokenizer":"^4.0.3","@csstools/css-parser-algorithms":"^4.0.3"},"_npmOperationalInternal":{"tmp":"tmp/utilities-for-private-properties_1.0.0_1794918270582_0.14657041820898853","host":"s3://npm-registry-packages-npm-production"},"publish_time":1794918270690,"_cnpm_publish_time":1794918270690},"0.0.0-stage":{"name":"@csstools/utilities-for-private-properties","version":"0.0.0-stage","_id":"@csstools/utilities-for-private-properties@0.0.0-stage","stub":true,"maintainers":[{"name":"romainmenke","email":"romainmenke@gmail.com"}],"dist":{"shasum":"3ee859c9775a40e46cf42ec69345806ae7af0994","tarball":"http://registry-npm.ywwl.com/@csstools/utilities-for-private-properties/download/@csstools/utilities-for-private-properties-0.0.0-stage.tgz","fileCount":2,"integrity":"sha512-kzrSqm+JlT+u7kWn208i1thn9t2oo+RuJzobbElba/FFEkQ2EgpfTQai+wpdgs1x3lou19wkdikItrqTadtzMg==","signatures":[{"sig":"MEUCIGhMlWFjJzxlpnQol9wpmMTlogy0Eesoyh7uTXbdvAYmAiEA8oTijbC5pd/QV8da02TKD/OKKaNM5dFV3PYWlbEKbvA=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":364,"size":383,"noattachment":false,"key":"/@csstools/utilities-for-private-properties/-/@csstools/utilities-for-private-properties-0.0.0-stage.tgz"},"_npmUser":{"name":"romainmenke","email":"romainmenke@gmail.com"},"description":"Temporary package placeholder for staged publishing","directories":{},"publish_time":1794918142567,"_cnpm_publish_time":1794918142567}},"readme":"# Utilities for Private Properties <img src=\"https://postcss.github.io/postcss/logo.svg\" alt=\"for PostCSS\" width=\"90\" height=\"90\" align=\"right\">\n\n[<img alt=\"npm version\" src=\"https://img.shields.io/npm/v/@csstools/utilities-for-private-properties.svg\" height=\"20\">][npm-url]\n[<img alt=\"Build Status\" src=\"https://github.com/csstools/postcss-plugins/actions/workflows/test.yml/badge.svg?branch=main\" height=\"20\">][cli-url]\n[<img alt=\"Discord\" src=\"https://shields.io/badge/Discord-5865F2?logo=discord&logoColor=white\">][discord]\n\nTranspile `@private` rules and private custom property references.\n\n## API\n\n[Read the API docs](./docs/utilities-for-private-properties.md)\n\n## Usage\n\nAdd [Utilities for Private Properties] to your project:\n\n```bash\nnpm install @csstools/utilities-for-private-properties @csstools/css-parser-algorithms @csstools/css-tokenizer postcss --save-dev\n```\n\n```ts\nimport { createPrivatePropertyTranspiler } from '@csstools/utilities-for-private-properties';\n\nconst transpiler = createPrivatePropertyTranspiler({ namespace: 'p' });\n\nconst registrations = transpiler.transpile(root.nodes);\nroot.append(...registrations);\n```\n\nNodes that are substituted into a style rule but are not its children, for example the contents of\nan `@contents` block, can be transpiled in the scope of that style rule:\n\n```ts\ntranspiler.transpile(nodes, { scope: styleRule });\n```\n\nWith `preserve: true` the `@private` rules are kept and references inside `@apply` and `@contents`\nblocks are left alone. Transpiled declarations are still hoisted, so the original notation keeps\nworking where `@private` is supported.\n\n`@property` rules are hoisted out of `@layer`, `@media` and `@supports` group rules, and the\n`@layer`, `@media` and `@supports` conditions are kept. `@container`, `@scope` and\n`@starting-style` do not constrain name-defining at-rules, so registrations inside them are hoisted\nwithout those conditions.\n\n[cli-url]: https://github.com/csstools/postcss-plugins/actions/workflows/test.yml?query=workflow/test\n[discord]: https://discord.gg/bUadyRwkJS\n[npm-url]: https://www.npmjs.com/package/@csstools/utilities-for-private-properties\n\n[Utilities for Private Properties]: https://github.com/csstools/postcss-plugins/tree/main/packages/utilities-for-private-properties\n","_attachments":{},"homepage":"https://github.com/csstools/postcss-plugins/tree/main/packages/utilities-for-private-properties#readme","bugs":{"url":"https://github.com/csstools/postcss-plugins/issues"},"license":"MIT-0"}