@janiscommerce/ui-web 1.7.0-beta.2 → 1.8.0

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
@@ -7,17 +7,23 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
7
7
 
8
8
  ## [Unreleased]
9
9
 
10
- ## [1.7.0-beta.2] - 2026-01-06
10
+ ## [1.8.0] - 2026-02-03
11
11
 
12
- ### Added
12
+ ### Added:
13
13
 
14
- - ref to wrapper element in Collapse component, data-is-opened attribute to handle Collapse opening and closing
14
+ - brush icon
15
15
 
16
- ## [1.6.0-beta.1] - 2026-01-06
16
+ ## [1.7.0] - 2026-01-12
17
17
 
18
18
  ### Added
19
19
 
20
- - isExpanding state, data-is-expanding attribute to Collapse component
20
+ - ref to wrapper element in Collapse component
21
+ - data-is-opened attribute to handle Collapse opening and closing states dynamically
22
+
23
+ ### Changed
24
+
25
+ - Refactored collapseState useMemo to include data-is-opened attribute updates in expandStart and collapseEnd handlers
26
+ - Removed isOpen prop from styled.Wrapper and styled.HeaderWrapper components in favor of data-is-opened attribute
21
27
 
22
28
  ## [1.6.0] - 2025-11-28
23
29
 
package/dist/index.esm.js CHANGED
@@ -5867,6 +5867,10 @@ var briefcase = {
5867
5867
  path: "M831.81 341.175h-639.833c-58.813 0-106.667 47.854-106.667 106.667v341.167c0 58.813 47.854 106.667 106.667 106.667h639.833c58.813 0 106.667-47.854 106.667-106.667v-341.167c0-58.813-47.854-106.667-106.667-106.667zM895.81 789.009c0 35.292-28.708 64-64 64h-639.833c-35.292 0-64-28.708-64-64v-341.167c0-35.292 28.708-64 64-64h639.833c35.292 0 64 28.708 64 64v341.167zM298.456 276.759v-42.833c0-58.813 47.854-106.667 106.667-106.667h211.833c59.729 0 108.312 47.646 108.312 106.208v42.833c0 11.792-9.542 21.333-21.333 21.333s-21.333-9.542-21.333-21.333v-42.834c0-35.042-29.458-63.542-65.646-63.542h-211.833c-35.292 0-64 28.708-64 64v42.833c0 11.792-9.542 21.333-21.333 21.333s-21.333-9.542-21.333-21.333zM768.31 532.759c0 11.792-9.542 21.333-21.333 21.333h-469.354c-11.792 0-21.333-9.542-21.333-21.333s9.542-21.333 21.333-21.333h469.354c11.792 0 21.333 9.542 21.333 21.333zM767.477 703.717c0 11.792-9.542 21.333-21.333 21.333h-468.979c-11.792 0-21.333-9.542-21.333-21.333s9.542-21.333 21.333-21.333h468.979c11.792 0 21.333 9.542 21.333 21.333z",
5868
5868
  size: 24
5869
5869
  };
5870
+ var brush = {
5871
+ path: "M905.091 175.721C901.968 153.743 890.299 143.43 884.466 139.549C858.798 119.968 752.093 97.438 382.843 493.533C382.071 494.361 381.751 495.402 381.137 496.311C380.689 496.964 379.972 497.352 379.596 498.056L340.573 571.297C322.039 564.396 303.442 560.814 284.842 562.282C230.886 566.344 197.384 605.017 191.927 611.788C145.01 663.162 182.22 730.017 185.011 734.723C185.429 735.368 195.387 751.013 179.763 779.681C162.261 811.724 136.844 817.015 136.1 817.16C127.138 818.619 120.098 825.578 118.515 834.512C116.932 843.446 121.181 852.406 129.096 856.822C176.887 883.592 219.054 893.324 255.138 893.324C350.928 893.324 403.72 824.656 404.262 823.926C438.177 780.235 453.58 738.525 451.699 700.782L536.844 656.157C537.489 655.82 537.838 655.163 538.44 654.766C539.413 654.126 540.501 653.746 541.388 652.927C790.89 422.572 916.632 257.555 905.091 175.721ZM370.385 797.994C367.509 801.765 304.469 882.358 187.135 837.567C197.566 828.922 208.234 816.963 217.237 800.544C240.72 756.953 229.555 722.711 220.927 711.817C219.967 710.068 197.384 668.566 223.761 640.183C224.179 639.743 224.635 639.163 225.011 638.68C225.262 638.369 249.804 607.474 288.511 604.786C318.096 602.559 350.595 617.766 383.594 649.701C422.219 687.056 417.842 736.869 370.385 797.994ZM441.283 658.055C434.754 644.209 425.708 631.073 413.253 619.032C401.732 607.887 390.148 598.687 378.534 590.777L403.67 543.594L491.382 631.803L441.283 658.055ZM527.44 607.534L428.142 507.707C628.59 295.404 823.63 143.191 860.392 174.695C860.435 174.738 863.349 177.738 863.182 187.718C862.568 220.776 827.778 327.698 527.44 607.534Z",
5872
+ size: 24
5873
+ };
5870
5874
  var calendar = {
5871
5875
  path: "M873.914 214.689h-105.167v-64.5c0-11.792-9.542-21.333-21.333-21.333s-21.333 9.542-21.333 21.333v64.5h-192.229v-64.5c0-11.792-9.542-21.333-21.333-21.333s-21.333 9.542-21.333 21.333v64.5h-192.021v-64.5c0-11.792-9.542-21.333-21.333-21.333s-21.333 9.542-21.333 21.333v64.5h-106.417c-35.146 0-63.729 28.583-63.729 63.729v553c0 35.146 28.583 63.729 63.729 63.729h723.833c35.146 0 63.729-28.583 63.729-63.729v-553c0-35.146-28.583-63.729-63.729-63.729zM894.977 831.418c0 11.604-9.458 21.062-21.062 21.062h-723.833c-11.604 0-21.062-9.458-21.062-21.062v-553c0-11.604 9.458-21.062 21.062-21.062h106.417v20.875c0 11.792 9.542 21.333 21.333 21.333s21.333-9.542 21.333-21.333v-20.875h192.021v20.875c0 11.792 9.542 21.333 21.333 21.333s21.333-9.542 21.333-21.333v-20.875h192.229v20.875c0 11.792 9.542 21.333 21.333 21.333s21.333-9.542 21.333-21.333v-20.875h105.167c11.604 0 21.062 9.458 21.062 21.062v553zM852.748 448.105c0 11.792-9.542 21.333-21.333 21.333h-638.979c-11.792 0-21.333-9.542-21.333-21.333s9.542-21.333 21.333-21.333h638.979c11.792 0 21.333 9.542 21.333 21.333z",
5872
5876
  size: 24
@@ -6773,6 +6777,7 @@ var icons = {
6773
6777
  box_small: box_small,
6774
6778
  box_term: box_term,
6775
6779
  briefcase: briefcase,
6780
+ brush: brush,
6776
6781
  calendar: calendar,
6777
6782
  calendar_dates: calendar_dates,
6778
6783
  calendar_edit: calendar_edit,
@@ -36305,10 +36310,11 @@ var Collapse = function Collapse(_ref) {
36305
36310
  setIsOpenState = _useState2[1];
36306
36311
 
36307
36312
  var collapseState = useMemo(function () {
36308
- var collapseElement = collapseRef.current;
36309
36313
  return {
36310
36314
  expandStart: function expandStart() {
36311
- collapseElement.setAttribute('data-is-opened', true);
36315
+ var _collapseRef$current;
36316
+
36317
+ (_collapseRef$current = collapseRef.current) === null || _collapseRef$current === void 0 || _collapseRef$current.setAttribute('data-is-opened', String(true));
36312
36318
  expandStartHandler();
36313
36319
  },
36314
36320
  expanding: expandingHandler,
@@ -36316,8 +36322,10 @@ var Collapse = function Collapse(_ref) {
36316
36322
  collapseStart: collapseStartHandler,
36317
36323
  collapsing: collapsingHandler,
36318
36324
  collapseEnd: function collapseEnd() {
36325
+ var _collapseRef$current2;
36326
+
36319
36327
  collapseEndHandler();
36320
- collapseElement.setAttribute('data-is-opened', false);
36328
+ (_collapseRef$current2 = collapseRef.current) === null || _collapseRef$current2 === void 0 || _collapseRef$current2.setAttribute('data-is-opened', String(false));
36321
36329
  }
36322
36330
  };
36323
36331
  }, [expandStartHandler, expandingHandler, expandEndHandler, collapseStartHandler, collapsingHandler, collapseEndHandler]);
@@ -36362,7 +36370,9 @@ var Collapse = function Collapse(_ref) {
36362
36370
  disabled: disabled
36363
36371
  };
36364
36372
  useEffect(function () {
36365
- collapseRef.current.setAttribute('data-is-opened', isOpenState);
36373
+ var _collapseRef$current3;
36374
+
36375
+ if (collapseRef.current) (_collapseRef$current3 = collapseRef.current) === null || _collapseRef$current3 === void 0 || _collapseRef$current3.setAttribute('data-is-opened', String(isOpen));
36366
36376
  setIsOpenState(isOpen);
36367
36377
  }, [isOpen]);
36368
36378
  if (!renderHeader || !isFunction(renderHeader) || !renderContent || !isFunction(renderContent)) return null;