@tailwindcss/postcss 4.0.0-alpha.5 → 4.0.0-alpha.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -2,6 +2,9 @@ import postcss from 'postcss';
2
2
 
3
3
  type PluginOptions = {
4
4
  base?: string;
5
+ optimize?: boolean | {
6
+ minify?: boolean;
7
+ };
5
8
  };
6
9
  declare const _default: postcss.PluginCreator<PluginOptions>;
7
10
 
package/dist/index.js CHANGED
@@ -1,3 +1,3 @@
1
- "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } }var _oxide = require('@tailwindcss/oxide');var _postcss = require('postcss'); var _postcss2 = _interopRequireDefault(_postcss);var _postcssimport = require('postcss-import'); var _postcssimport2 = _interopRequireDefault(_postcssimport);var _tailwindcss = require('tailwindcss');function b(r={}){let a=_nullishCoalesce(r.base, () => (process.cwd()));return{postcssPlugin:"tailwindcss-v4",plugins:[_postcssimport2.default.call(void 0, ),(s,t)=>{let i=!1,n=!1;if(s.walkAtRules(e=>{if(e.name==="apply")i=!0;else if(e.name==="tailwind")return i=!0,n=!0,!1}),!n&&!i)return;function p(e){s.removeAll(),s.append(_postcss2.default.parse(_tailwindcss.optimizeCss.call(void 0, e),t.opts))}if(!n){p(_tailwindcss.compile.call(void 0, s.toString(),[]));return}let{candidates:o,files:c,globs:f}=_oxide.scanDir.call(void 0, {base:a,globs:!0});for(let e of c)t.messages.push({type:"dependency",plugin:"tailwindcss-v4",file:e,parent:t.opts.from});for(let{base:e,glob:g}of f)t.messages.push({type:"dir-dependency",plugin:"tailwindcss-v4",dir:e,glob:g,parent:t.opts.from});p(_tailwindcss.compile.call(void 0, s.toString(),o))}]}}var v=Object.assign(b,{postcss:!0});exports.default = v;
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } }var _oxide = require('@tailwindcss/oxide');var _postcss = require('postcss'); var _postcss2 = _interopRequireDefault(_postcss);var _postcssimport = require('postcss-import'); var _postcssimport2 = _interopRequireDefault(_postcssimport);var _tailwindcss = require('tailwindcss');function w(l={}){let f=_nullishCoalesce(l.base, () => (process.cwd())),n=_nullishCoalesce(l.optimize, () => (process.env.NODE_ENV==="production"));return{postcssPlugin:"tailwindcss-v4",plugins:[_postcssimport2.default.call(void 0, ),(i,s)=>{let p=!1,o=!1;if(i.walkAtRules(e=>{if(e.name==="apply")p=!0;else if(e.name==="tailwind")return p=!0,o=!0,!1}),!o&&!p)return;function a(e){i.removeAll();let t=e;n&&(t=_tailwindcss.optimizeCss.call(void 0, t,{minify:typeof n=="object"?n.minify:!1})),i.append(_postcss2.default.parse(t,s.opts))}if(!o){a(_tailwindcss.compile.call(void 0, i.toString(),[]));return}let{candidates:c,files:m,globs:u}=_oxide.scanDir.call(void 0, {base:f,globs:!0});for(let e of m)s.messages.push({type:"dependency",plugin:"tailwindcss-v4",file:e,parent:s.opts.from});for(let{base:e,glob:t}of u)s.messages.push({type:"dir-dependency",plugin:"tailwindcss-v4",dir:e,glob:t,parent:s.opts.from});a(_tailwindcss.compile.call(void 0, i.toString(),c))}]}}var h=Object.assign(w,{postcss:!0});exports.default = h;
2
2
 
3
3
  module.exports = exports.default;
package/package.json CHANGED
@@ -1,14 +1,22 @@
1
1
  {
2
2
  "name": "@tailwindcss/postcss",
3
- "version": "4.0.0-alpha.5",
3
+ "version": "4.0.0-alpha.7",
4
4
  "description": "PostCSS plugin for Tailwind CSS, a utility-first CSS framework for rapidly building custom user interfaces",
5
5
  "license": "MIT",
6
- "repository": "https://github.com/tailwindlabs/tailwindcss.git",
6
+ "repository": {
7
+ "type": "git",
8
+ "url": "git+https://github.com/tailwindlabs/tailwindcss.git",
9
+ "directory": "packages/@tailwindcss-postcss"
10
+ },
7
11
  "bugs": "https://github.com/tailwindlabs/tailwindcss/issues",
8
12
  "homepage": "https://tailwindcss.com",
9
13
  "files": [
10
14
  "dist/"
11
15
  ],
16
+ "publishConfig": {
17
+ "provenance": true,
18
+ "access": "public"
19
+ },
12
20
  "exports": {
13
21
  ".": {
14
22
  "types": "./dist/index.d.ts",
@@ -17,8 +25,8 @@
17
25
  },
18
26
  "dependencies": {
19
27
  "postcss-import": "^16.0.0",
20
- "@tailwindcss/oxide": "4.0.0-alpha.5",
21
- "tailwindcss": "4.0.0-alpha.5"
28
+ "@tailwindcss/oxide": "4.0.0-alpha.7",
29
+ "tailwindcss": "4.0.0-alpha.7"
22
30
  },
23
31
  "devDependencies": {
24
32
  "@types/node": "^20.11.17",