@modern-js/plugin-tailwindcss 0.0.0-next-20240724064042 → 0.0.0-next-20240724085614

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.
@@ -41,7 +41,7 @@ const useDesignTokens = () => (0, import_react.useContext)(DesignTokenContext);
41
41
  const designTokenPlugin = (options = {}) => ({
42
42
  name: "@modern-js/plugin-design-token",
43
43
  setup: () => ({
44
- hoc({ App, config }, next) {
44
+ wrapRoot(App) {
45
45
  const DesignTokenAppWrapper = (props) => {
46
46
  const { token = {}, useStyledComponentsThemeProvider = false, useDesignTokenContext = false } = options;
47
47
  if (useStyledComponentsThemeProvider && useDesignTokenContext) {
@@ -76,10 +76,7 @@ const designTokenPlugin = (options = {}) => ({
76
76
  });
77
77
  }
78
78
  };
79
- return next({
80
- App: DesignTokenAppWrapper,
81
- config
82
- });
79
+ return DesignTokenAppWrapper;
83
80
  }
84
81
  })
85
82
  });
@@ -11,8 +11,7 @@ var designTokenPlugin = function() {
11
11
  name: "@modern-js/plugin-design-token",
12
12
  setup: function() {
13
13
  return {
14
- hoc: function hoc(param, next) {
15
- var App = param.App, config = param.config;
14
+ wrapRoot: function wrapRoot(App) {
16
15
  var DesignTokenAppWrapper = function(props) {
17
16
  var _options_token = options.token, token = _options_token === void 0 ? {} : _options_token, _options_useStyledComponentsThemeProvider = options.useStyledComponentsThemeProvider, useStyledComponentsThemeProvider = _options_useStyledComponentsThemeProvider === void 0 ? false : _options_useStyledComponentsThemeProvider, _options_useDesignTokenContext = options.useDesignTokenContext, useDesignTokenContext = _options_useDesignTokenContext === void 0 ? false : _options_useDesignTokenContext;
18
17
  if (useStyledComponentsThemeProvider && useDesignTokenContext) {
@@ -39,10 +38,7 @@ var designTokenPlugin = function() {
39
38
  return /* @__PURE__ */ _jsx(App, _object_spread({}, props));
40
39
  }
41
40
  };
42
- return next({
43
- App: DesignTokenAppWrapper,
44
- config
45
- });
41
+ return DesignTokenAppWrapper;
46
42
  }
47
43
  };
48
44
  }
@@ -5,7 +5,7 @@ const useDesignTokens = () => useContext(DesignTokenContext);
5
5
  const designTokenPlugin = (options = {}) => ({
6
6
  name: "@modern-js/plugin-design-token",
7
7
  setup: () => ({
8
- hoc({ App, config }, next) {
8
+ wrapRoot(App) {
9
9
  const DesignTokenAppWrapper = (props) => {
10
10
  const { token = {}, useStyledComponentsThemeProvider = false, useDesignTokenContext = false } = options;
11
11
  if (useStyledComponentsThemeProvider && useDesignTokenContext) {
@@ -40,10 +40,7 @@ const designTokenPlugin = (options = {}) => ({
40
40
  });
41
41
  }
42
42
  };
43
- return next({
44
- App: DesignTokenAppWrapper,
45
- config
46
- });
43
+ return DesignTokenAppWrapper;
47
44
  }
48
45
  })
49
46
  });
package/package.json CHANGED
@@ -15,7 +15,7 @@
15
15
  "modern",
16
16
  "modern.js"
17
17
  ],
18
- "version": "0.0.0-next-20240724064042",
18
+ "version": "0.0.0-next-20240724085614",
19
19
  "jsnext:source": "./src/index.ts",
20
20
  "types": "./dist/types/index.d.ts",
21
21
  "main": "./dist/cjs/index.js",
@@ -49,8 +49,8 @@
49
49
  "dependencies": {
50
50
  "babel-plugin-macros": "3.1.0",
51
51
  "@swc/helpers": "0.5.3",
52
- "@modern-js/utils": "0.0.0-next-20240724064042",
53
- "@modern-js/node-bundle-require": "0.0.0-next-20240724064042"
52
+ "@modern-js/utils": "0.0.0-next-20240724085614",
53
+ "@modern-js/node-bundle-require": "0.0.0-next-20240724085614"
54
54
  },
55
55
  "devDependencies": {
56
56
  "@types/jest": "^29",
@@ -60,17 +60,17 @@
60
60
  "jest": "^29",
61
61
  "react": "^18",
62
62
  "postcss": "^8.4.35",
63
- "@modern-js/runtime": "0.0.0-next-20240724064042",
64
- "@modern-js/module-tools": "0.0.0-next-20240724064042",
65
- "@modern-js/core": "0.0.0-next-20240724064042",
66
- "@modern-js/types": "0.0.0-next-20240724064042",
67
- "@modern-js/app-tools": "0.0.0-next-20240724064042",
68
- "@scripts/build": "0.0.0-next-20240724064042",
69
- "@scripts/jest-config": "0.0.0-next-20240724064042"
63
+ "@modern-js/core": "0.0.0-next-20240724085614",
64
+ "@modern-js/module-tools": "0.0.0-next-20240724085614",
65
+ "@scripts/build": "0.0.0-next-20240724085614",
66
+ "@modern-js/types": "0.0.0-next-20240724085614",
67
+ "@modern-js/runtime": "0.0.0-next-20240724085614",
68
+ "@modern-js/app-tools": "0.0.0-next-20240724085614",
69
+ "@scripts/jest-config": "0.0.0-next-20240724085614"
70
70
  },
71
71
  "peerDependencies": {
72
72
  "tailwindcss": ">= 2.0.0 || >= 3.0.0",
73
- "@modern-js/runtime": "0.0.0-next-20240724064042"
73
+ "@modern-js/runtime": "0.0.0-next-20240724085614"
74
74
  },
75
75
  "peerDependenciesMeta": {
76
76
  "@modern-js/runtime": {