@ant-design/cssinjs-utils
Advanced tools
@@ -1,2 +0,2 @@ | ||
| import React from 'react'; | ||
| import type React from 'react'; | ||
| import type { CSSInterpolation, CSSObject, TokenType } from '@ant-design/cssinjs'; | ||
@@ -3,0 +3,0 @@ import { useStyleRegister } from '@ant-design/cssinjs'; |
@@ -70,2 +70,3 @@ import _typeof from "@babel/runtime/helpers/esm/typeof"; | ||
| realToken = _useToken.realToken; | ||
| var csp = useCSP(); | ||
| useCSSVarRegister({ | ||
@@ -78,3 +79,6 @@ path: [component], | ||
| token: realToken, | ||
| scope: rootCls | ||
| scope: rootCls, | ||
| nonce: function nonce() { | ||
| return csp.nonce; | ||
| } | ||
| }, function () { | ||
@@ -81,0 +85,0 @@ var defaultToken = getDefaultComponentToken(component, realToken, getDefaultToken); |
@@ -1,2 +0,2 @@ | ||
| import React from 'react'; | ||
| import type React from 'react'; | ||
| import type { CSSInterpolation, CSSObject, TokenType } from '@ant-design/cssinjs'; | ||
@@ -3,0 +3,0 @@ import { useStyleRegister } from '@ant-design/cssinjs'; |
@@ -78,2 +78,3 @@ "use strict"; | ||
| realToken = _useToken.realToken; | ||
| var csp = useCSP(); | ||
| (0, _cssinjs.useCSSVarRegister)({ | ||
@@ -86,3 +87,6 @@ path: [component], | ||
| token: realToken, | ||
| scope: rootCls | ||
| scope: rootCls, | ||
| nonce: function nonce() { | ||
| return csp.nonce; | ||
| } | ||
| }, function () { | ||
@@ -89,0 +93,0 @@ var defaultToken = (0, _getDefaultComponentToken.default)(component, realToken, getDefaultToken); |
+2
-2
| { | ||
| "name": "@ant-design/cssinjs-utils", | ||
| "version": "2.1.1", | ||
| "version": "2.1.2", | ||
| "description": "A cssinjs util library to support Ant Design (antd) and its ecosystem libraries.", | ||
@@ -60,3 +60,3 @@ "keywords": [ | ||
| "dependencies": { | ||
| "@ant-design/cssinjs": "^2.1.0", | ||
| "@ant-design/cssinjs": "^2.1.2", | ||
| "@babel/runtime": "^7.23.2", | ||
@@ -63,0 +63,0 @@ "@rc-component/util": "^1.4.0" |
92166
0.23%2084
0.39%Updated