@widergy/energy-ui 3.135.0 → 3.136.1

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/CHANGELOG.md CHANGED
@@ -1,3 +1,19 @@
1
+ ## [3.136.1](https://github.com/widergy/energy-ui/compare/v3.136.0...v3.136.1) (2026-02-05)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * [AXCH-9999] ci 3 ([#760](https://github.com/widergy/energy-ui/issues/760)) ([0ed5ff6](https://github.com/widergy/energy-ui/commit/0ed5ff6545e24a320d1bfa87c4cccc599f5f0cf8))
7
+ * ci configs ([#758](https://github.com/widergy/energy-ui/issues/758)) ([d48c6c6](https://github.com/widergy/energy-ui/commit/d48c6c6c4a76f905e35c42b1b013d7f0ff750e5d))
8
+ * more ci problemillas ([#759](https://github.com/widergy/energy-ui/issues/759)) ([460633c](https://github.com/widergy/energy-ui/commit/460633cb89f77a239da44e5d38ca16d4a2fb026f))
9
+
10
+ # [3.136.0](https://github.com/widergy/energy-ui/compare/v3.135.0...v3.136.0) (2026-02-05)
11
+
12
+
13
+ ### Features
14
+
15
+ * status component for cases ([#757](https://github.com/widergy/energy-ui/issues/757)) ([712d283](https://github.com/widergy/energy-ui/commit/712d28382895d4dbcd9ec3f2b141d8dab1689648))
16
+
1
17
  # [3.135.0](https://github.com/widergy/energy-ui/compare/v3.134.0...v3.135.0) (2026-02-04)
2
18
 
3
19
 
@@ -22,6 +22,7 @@ const VARIANTS = exports.VARIANTS = {
22
22
  warning: 'warning'
23
23
  };
24
24
  const TYPES = exports.TYPES = {
25
+ accent: 'accent',
25
26
  default: 'default',
26
27
  light: 'light',
27
28
  negative: 'negative'
@@ -37,8 +37,39 @@ const UTStatus = _ref => {
37
37
  withoutIcon
38
38
  } = _ref;
39
39
  const StatusIcon = Icon !== null && Icon !== void 0 ? Icon : (0, _theme.defaultIconMapper)(variant);
40
- const validAdornments = (0, _react.useMemo)(() => (0, _utils.validateAdornments)(adornments) ? adornments : [], [adornments]);
41
- const useValidAdornments = validAdornments.length > 0;
40
+ const {
41
+ leftAdornments,
42
+ rightAdornments
43
+ } = (0, _react.useMemo)(() => {
44
+ const left = [];
45
+ const right = [];
46
+ if (!(0, _utils.validateAdornments)(adornments)) return {
47
+ leftAdornments: left,
48
+ rightAdornments: right
49
+ };
50
+ adornments.forEach((item, index) => {
51
+ if (item.left || item.right) {
52
+ if (item.left) left.push({
53
+ ...item.left,
54
+ key: item.left.key || "".concat(item.left.name, "-left-").concat(index)
55
+ });
56
+ if (item.right) right.push({
57
+ ...item.right,
58
+ key: item.right.key || "".concat(item.right.name, "-right-").concat(index)
59
+ });
60
+ } else {
61
+ left.push({
62
+ ...item,
63
+ key: item.key || "".concat(item.name, "-").concat(index)
64
+ });
65
+ }
66
+ });
67
+ return {
68
+ leftAdornments: left,
69
+ rightAdornments: right
70
+ };
71
+ }, [adornments]);
72
+ const useValidAdornments = leftAdornments.length > 0 || rightAdornments.length > 0;
42
73
  const {
43
74
  IconComponent,
44
75
  ...iconProps
@@ -74,7 +105,7 @@ const UTStatus = _ref => {
74
105
  const StatusRender = /*#__PURE__*/_react.default.createElement("div", {
75
106
  className: "".concat(classes.root, " ").concat(className || '', " ").concat(area ? '' : classes.withoutArea, " ").concat(areaType === _constants.AREA_TYPES.SQUARE ? '' : classes.roundedArea),
76
107
  title: title
77
- }, useValidAdornments && validAdornments.map(renderAdornment), withoutIcon || useValidAdornments ? null : /*#__PURE__*/_react.default.createElement(IconComponent, iconProps), /*#__PURE__*/_react.default.createElement(_UTLabel.default, {
108
+ }, useValidAdornments && leftAdornments.map(renderAdornment), withoutIcon || useValidAdornments ? null : /*#__PURE__*/_react.default.createElement(IconComponent, iconProps), /*#__PURE__*/_react.default.createElement(_UTLabel.default, {
78
109
  className: classes.label,
79
110
  colorTheme: colorTheme,
80
111
  shade: type !== _constants.TYPES.negative ? '05' : undefined,
@@ -83,7 +114,7 @@ const UTStatus = _ref => {
83
114
  size
84
115
  }),
85
116
  weight: weight
86
- }, children));
117
+ }, children), useValidAdornments && rightAdornments.map(renderAdornment));
87
118
  return /*#__PURE__*/_react.default.createElement(_UTSkeleton.default, null, showTooltip ? /*#__PURE__*/_react.default.createElement(_UTTooltip.default, {
88
119
  content: tooltip,
89
120
  tippyProps: {
@@ -183,6 +183,7 @@ const getColorTheme = _ref8 => {
183
183
  variant
184
184
  } = _ref8;
185
185
  return {
186
+ [_constants.TYPES.accent]: _Palette.COLOR_THEMES.accent,
186
187
  [_constants.TYPES.default]: _Palette.COLOR_THEMES.dark,
187
188
  [_constants.TYPES.light]: variant !== _constants.VARIANTS.unassigned ? variant : _Palette.COLOR_THEMES.gray,
188
189
  [_constants.TYPES.negative]: _Palette.COLOR_THEMES.light
@@ -34,7 +34,12 @@ const getIconProps = _ref => {
34
34
  };
35
35
  };
36
36
  exports.getIconProps = getIconProps;
37
- const validateAdornments = adornments => adornments.every(adornment => _constants.COMPONENTS_MAPPER[adornment.name]);
37
+ const validateAdornments = adornments => adornments.every(adornment => {
38
+ if (adornment.left || adornment.right) {
39
+ return (!adornment.left || _constants.COMPONENTS_MAPPER[adornment.left.name]) && (!adornment.right || _constants.COMPONENTS_MAPPER[adornment.right.name]);
40
+ }
41
+ return _constants.COMPONENTS_MAPPER[adornment.name];
42
+ });
38
43
  exports.validateAdornments = validateAdornments;
39
44
  const interpreterSize = (size, classes) => {
40
45
  const {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@widergy/energy-ui",
3
- "version": "3.135.0",
3
+ "version": "3.136.1",
4
4
  "description": "Widergy Web Components",
5
5
  "author": "widergy",
6
6
  "license": "MIT",