@highlight-ui/utils-commons
Advanced tools
Comparing version 2.5.3 to 2.6.0-r18.0
@@ -30,5 +30,5 @@ 'use strict'; | ||
if (prefix === '$highlightUi$') { | ||
return "" + id; | ||
return "".concat(id); | ||
} | ||
return "" + prefix + id; | ||
return "".concat(prefix).concat(id); | ||
} | ||
@@ -55,3 +55,3 @@ var noop = function () {}; | ||
return metadata ? Object.keys(metadata).reduce(function (acc, key) { | ||
acc["data-" + kebabCase__default["default"](key)] = metadata[key] || ''; | ||
acc["data-".concat(kebabCase__default["default"](key))] = metadata[key] || ''; | ||
return acc; | ||
@@ -87,3 +87,3 @@ }, {}) : {}; | ||
return mapValues__default["default"](function (val) { | ||
return val + "-" + suffix; | ||
return "".concat(val, "-").concat(suffix); | ||
}, metadata); | ||
@@ -122,4 +122,4 @@ }); | ||
var componentName = getDisplayName(WrappedComponent); | ||
var deprecationMessage = "\u26A0\uFE0F Deprecation Warning: " + componentName + " is now deprecated."; | ||
var migrationGuideMessage = migrationGuideLink ? " See " + migrationGuideLink + " for migration guidance." : ''; | ||
var deprecationMessage = "\u26A0\uFE0F Deprecation Warning: ".concat(componentName, " is now deprecated."); | ||
var migrationGuideMessage = migrationGuideLink ? " See ".concat(migrationGuideLink, " for migration guidance.") : ''; | ||
var fullMessage = deprecationMessage + migrationGuideMessage; | ||
@@ -133,3 +133,3 @@ var DeprecatedComponent = function (props) { | ||
}; | ||
DeprecatedComponent.displayName = "withDeprecationWarning(" + componentName + ")"; | ||
DeprecatedComponent.displayName = "withDeprecationWarning(".concat(componentName, ")"); | ||
return DeprecatedComponent; | ||
@@ -136,0 +136,0 @@ } |
import React from 'react'; | ||
declare function withDeprecationWarning<P extends Record<string, unknown>>(WrappedComponent: React.ComponentType<P>, migrationGuideLink?: string): React.ComponentType<P>; | ||
declare function withDeprecationWarning<P extends Record<string, unknown>>(WrappedComponent: React.ComponentType<React.PropsWithChildren<P>>, migrationGuideLink?: string): React.ComponentType<React.PropsWithChildren<P>>; | ||
export default withDeprecationWarning; |
@@ -16,5 +16,5 @@ import kebabCase from 'lodash/fp/kebabCase'; | ||
if (prefix === '$highlightUi$') { | ||
return "" + id; | ||
return "".concat(id); | ||
} | ||
return "" + prefix + id; | ||
return "".concat(prefix).concat(id); | ||
} | ||
@@ -41,3 +41,3 @@ var noop = function () {}; | ||
return metadata ? Object.keys(metadata).reduce(function (acc, key) { | ||
acc["data-" + kebabCase(key)] = metadata[key] || ''; | ||
acc["data-".concat(kebabCase(key))] = metadata[key] || ''; | ||
return acc; | ||
@@ -73,3 +73,3 @@ }, {}) : {}; | ||
return mapValues(function (val) { | ||
return val + "-" + suffix; | ||
return "".concat(val, "-").concat(suffix); | ||
}, metadata); | ||
@@ -108,4 +108,4 @@ }); | ||
var componentName = getDisplayName(WrappedComponent); | ||
var deprecationMessage = "\u26A0\uFE0F Deprecation Warning: " + componentName + " is now deprecated."; | ||
var migrationGuideMessage = migrationGuideLink ? " See " + migrationGuideLink + " for migration guidance." : ''; | ||
var deprecationMessage = "\u26A0\uFE0F Deprecation Warning: ".concat(componentName, " is now deprecated."); | ||
var migrationGuideMessage = migrationGuideLink ? " See ".concat(migrationGuideLink, " for migration guidance.") : ''; | ||
var fullMessage = deprecationMessage + migrationGuideMessage; | ||
@@ -119,3 +119,3 @@ var DeprecatedComponent = function (props) { | ||
}; | ||
DeprecatedComponent.displayName = "withDeprecationWarning(" + componentName + ")"; | ||
DeprecatedComponent.displayName = "withDeprecationWarning(".concat(componentName, ")"); | ||
return DeprecatedComponent; | ||
@@ -122,0 +122,0 @@ } |
import React from 'react'; | ||
declare function withDeprecationWarning<P extends Record<string, unknown>>(WrappedComponent: React.ComponentType<P>, migrationGuideLink?: string): React.ComponentType<P>; | ||
declare function withDeprecationWarning<P extends Record<string, unknown>>(WrappedComponent: React.ComponentType<React.PropsWithChildren<P>>, migrationGuideLink?: string): React.ComponentType<React.PropsWithChildren<P>>; | ||
export default withDeprecationWarning; |
{ | ||
"name": "@highlight-ui/utils-commons", | ||
"version": "2.5.3", | ||
"version": "2.6.0-r18.0", | ||
"author": "Personio GmbH & Co. KG", | ||
@@ -24,10 +24,9 @@ "main": "dist/cjs/index.js", | ||
"devDependencies": { | ||
"@highlight-ui/configs-base-jest": "^3.1.4", | ||
"@highlight-ui/configs-base-tsconfig": "^3.2.3", | ||
"@highlight-ui/configs-base-jest": "^3.2.0-r18.0", | ||
"@highlight-ui/configs-base-tsconfig": "^3.3.0-r18.0", | ||
"@highlight-ui/configs-scripts": "^3.2.5", | ||
"@highlight-ui/utils-dev": "^1.1.20", | ||
"@testing-library/react": "12.1.5", | ||
"jest": "~27.2.3", | ||
"@highlight-ui/utils-dev": "^1.2.0-r18.0", | ||
"jest": "29.7.0", | ||
"lodash": "~4.17.21", | ||
"react": "17.0.2", | ||
"react": "18.2.0", | ||
"rimraf": "~3.0.2" | ||
@@ -37,8 +36,8 @@ }, | ||
"lodash": "~4.17.21", | ||
"react": "17.0.2" | ||
"react": "18.2.0" | ||
}, | ||
"dependencies": { | ||
"@highlight-ui/tokens": "^4.3.2" | ||
"@highlight-ui/tokens": "^4.3.0-r18.0" | ||
}, | ||
"gitHead": "579a2b9560f60b612de909659f38e1460f39173a" | ||
"gitHead": "5082727c3ee712c068ae49714fa9fc7e5dd0d3ad" | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
63628
8
2
+ Addedreact@18.2.0(transitive)
- Removedobject-assign@4.1.1(transitive)
- Removedreact@17.0.2(transitive)