@hybridcore/ui 1.6.13 → 1.6.16

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.
Files changed (100) hide show
  1. package/dist/AccordionSummary-DUtr16g6.js +781 -0
  2. package/dist/Add-Bk8R160M.js +403 -0
  3. package/dist/Button-Cem3nbwc.js +357 -0
  4. package/dist/ButtonBase-DObmf4Q_.js +886 -0
  5. package/dist/Delete-CVJ6FeDn.js +203 -0
  6. package/dist/FormGroup-BRj1o7-E.js +89 -0
  7. package/dist/InputLabel-CjD30ZHz.js +341 -0
  8. package/dist/MenuItem-BKvRGLvM.js +233 -0
  9. package/dist/Modal-BVYydOr5.js +1156 -0
  10. package/dist/Paper-B1HV8GyO.js +582 -0
  11. package/dist/Select-Bfhvigsx.js +3914 -0
  12. package/dist/Source-BSZST_GH.js +4410 -0
  13. package/dist/SwitchBase-BEK49kdS.js +235 -0
  14. package/dist/Text-ChJRuaD8.js +2197 -0
  15. package/dist/TextField-Ca9ykixI.js +696 -0
  16. package/dist/TransitionGroupContext-Ja2CgIob.js +96 -0
  17. package/dist/Typography-D3X-Y5fh.js +178 -0
  18. package/dist/Vector-BmuhQO4p.js +3606 -0
  19. package/dist/Vector-DfTqQEln.js +1735 -0
  20. package/dist/WKT-2wsDT-nq.js +2310 -0
  21. package/dist/{_commonjsHelpers-BVfed4GL.js → _commonjsHelpers-BkfeUUK-.js} +2 -2
  22. package/dist/assertThisInitialized-C1dAyb4j.js +7 -0
  23. package/dist/assets/index.css +1 -1
  24. package/dist/assets/index2.css +1 -1
  25. package/dist/assets/index3.css +1 -0
  26. package/dist/assets/index4.css +1 -0
  27. package/dist/clsx-OuTLNxxd.js +16 -0
  28. package/dist/components/button/styled.js +1 -1
  29. package/dist/components/charts/_common/format.js +126 -82
  30. package/dist/components/charts/_common/tooltip.js +44 -35
  31. package/dist/components/charts/chart-wrapper/index.js +44 -43
  32. package/dist/components/charts/donut-chart/logic.js +53 -40
  33. package/dist/components/charts/drill-down-voronoi-treemap/logic.js +1 -1
  34. package/dist/components/charts/xy-chart/logic.js +135 -134
  35. package/dist/components/collapsible-card/index.js +30 -21
  36. package/dist/components/collapsible-card/styled.js +14 -16
  37. package/dist/components/color-picker/index.js +3358 -2228
  38. package/dist/components/color-picker/styled.js +7 -87
  39. package/dist/components/confirm/dialog.js +7 -89
  40. package/dist/components/confirm/index.js +1 -1
  41. package/dist/components/data-map/index.js +1 -1
  42. package/dist/components/data-map/logic.js +20 -20
  43. package/dist/components/data-security-selectors/dissemination-list/index.js +3117 -32
  44. package/dist/components/date-range-picker/index.js +454 -466
  45. package/dist/components/document-viewer/components/viewer/index.js +1 -1
  46. package/dist/components/duration-select/index.js +10 -10
  47. package/dist/components/duration-select/styled.js +1 -1
  48. package/dist/components/geometry-picker/coordinate/index.js +14 -14
  49. package/dist/components/geometry-picker/edit/index.js +1 -1
  50. package/dist/components/geometry-picker/geometry/index.js +1 -1
  51. package/dist/components/geometry-picker/kml/index.js +11 -11
  52. package/dist/components/geometry-picker/map/logic.js +3656 -145
  53. package/dist/components/geometry-picker/map/style.js +17 -18
  54. package/dist/components/geometry-picker/parser/coordinate-input/logic.js +1255 -43
  55. package/dist/components/heat-map/index.js +1 -1
  56. package/dist/components/heat-map/logic.js +1924 -77
  57. package/dist/components/instance-form/components/composite-matrix/components/json-editor/index.js +8737 -8722
  58. package/dist/components/instance-hierarchy-table/styled.js +16 -18
  59. package/dist/components/map/helpers/mapbox.js +15 -17
  60. package/dist/components/map/helpers/ol.js +27 -386
  61. package/dist/components/map/index.js +10 -11
  62. package/dist/components/map/logic.js +22 -22
  63. package/dist/components/map/styled.js +27 -31
  64. package/dist/components/phone-input/index.js +9 -10
  65. package/dist/components/property-mapping/index.js +1 -1
  66. package/dist/components/prr-map/index.js +1 -1
  67. package/dist/components/prr-map/logic.js +26 -27
  68. package/dist/components/raster-grid-map/index.js +1 -1
  69. package/dist/components/raster-grid-map/logic.js +57 -60
  70. package/dist/components/sortable-list/index.js +1264 -1091
  71. package/dist/components/template-form/components/property-list/index.js +32 -36
  72. package/dist/components/template-form/components/property-list/property-list-columns.js +17 -19
  73. package/dist/components/template-form/components/property-list/property-list-form.js +600 -137
  74. package/dist/components/template-form/components/recognition-property-list/index.js +36 -40
  75. package/dist/components/template-form/components/recognition-property-list/recognition-property-list-columns.js +9 -11
  76. package/dist/components/template-form/components/recognition-property-list/recognition-property-list-form.js +64 -57
  77. package/dist/components/tree-select/index.js +16 -16
  78. package/dist/createChainedFunction-C0nujS3O.js +9 -0
  79. package/dist/createSvgIcon-BghzB2Y9.js +93 -0
  80. package/dist/createSvgIcon-D7U1nd99.js +185 -0
  81. package/dist/debounce-46wSf_lW.js +15 -0
  82. package/dist/dialog-BtJhjyF5.js +664 -0
  83. package/dist/extends-C3382pL0.js +22 -0
  84. package/dist/formControlState-vgaj2ksH.js +10 -0
  85. package/dist/generateUtilityClasses-Cc-owZ4J.js +2971 -0
  86. package/dist/{index-C__OZmYy.js → index-CblbdqjE.js} +1 -1
  87. package/dist/index-DH6qsPBn.js +153 -0
  88. package/dist/index.esm-DAf19hyR.js +318 -0
  89. package/dist/main.d.ts +9 -1
  90. package/dist/math-Bvt2Ubuz.js +704 -0
  91. package/dist/ol-yOE-NV0X.js +7465 -0
  92. package/dist/ownerWindow-wg6foiOE.js +10 -0
  93. package/dist/setPrototypeOf-NPgp4cYc.js +8 -0
  94. package/dist/styled-DD4BkuVf.js +350 -0
  95. package/dist/useControlled-BYdyS7Pn.js +31 -0
  96. package/dist/useFormControl-CatNKXAi.js +10 -0
  97. package/dist/useId-BW-oWmul.js +19 -0
  98. package/dist/useSlot-u4t0X96G.js +42 -0
  99. package/package.json +1 -1
  100. package/dist/index.esm-UfGMjYOL.js +0 -197
@@ -1,4 +1,4 @@
1
- import { a as Ee } from "./_commonjsHelpers-BVfed4GL.js";
1
+ import { g as Ee } from "./_commonjsHelpers-BkfeUUK-.js";
2
2
  var ae = { exports: {} }, V = { exports: {} }, m = {};
3
3
  /** @license React v16.13.1
4
4
  * react-is.production.min.js
@@ -0,0 +1,153 @@
1
+ var P = { exports: {} }, e = {};
2
+ /**
3
+ * @license React
4
+ * react-is.production.js
5
+ *
6
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
7
+ *
8
+ * This source code is licensed under the MIT license found in the
9
+ * LICENSE file in the root directory of this source tree.
10
+ */
11
+ var d;
12
+ function y() {
13
+ if (d) return e;
14
+ d = 1;
15
+ var n = Symbol.for("react.transitional.element"), R = Symbol.for("react.portal"), T = Symbol.for("react.fragment"), s = Symbol.for("react.strict_mode"), i = Symbol.for("react.profiler"), f = Symbol.for("react.consumer"), u = Symbol.for("react.context"), a = Symbol.for("react.forward_ref"), E = Symbol.for("react.suspense"), c = Symbol.for("react.suspense_list"), l = Symbol.for("react.memo"), _ = Symbol.for("react.lazy"), S = Symbol.for("react.view_transition"), C = Symbol.for("react.client.reference");
16
+ function o(r) {
17
+ if (typeof r == "object" && r !== null) {
18
+ var m = r.$$typeof;
19
+ switch (m) {
20
+ case n:
21
+ switch (r = r.type, r) {
22
+ case T:
23
+ case i:
24
+ case s:
25
+ case E:
26
+ case c:
27
+ case S:
28
+ return r;
29
+ default:
30
+ switch (r = r && r.$$typeof, r) {
31
+ case u:
32
+ case a:
33
+ case _:
34
+ case l:
35
+ return r;
36
+ case f:
37
+ return r;
38
+ default:
39
+ return m;
40
+ }
41
+ }
42
+ case R:
43
+ return m;
44
+ }
45
+ }
46
+ }
47
+ return e.ContextConsumer = f, e.ContextProvider = u, e.Element = n, e.ForwardRef = a, e.Fragment = T, e.Lazy = _, e.Memo = l, e.Portal = R, e.Profiler = i, e.StrictMode = s, e.Suspense = E, e.SuspenseList = c, e.isContextConsumer = function(r) {
48
+ return o(r) === f;
49
+ }, e.isContextProvider = function(r) {
50
+ return o(r) === u;
51
+ }, e.isElement = function(r) {
52
+ return typeof r == "object" && r !== null && r.$$typeof === n;
53
+ }, e.isForwardRef = function(r) {
54
+ return o(r) === a;
55
+ }, e.isFragment = function(r) {
56
+ return o(r) === T;
57
+ }, e.isLazy = function(r) {
58
+ return o(r) === _;
59
+ }, e.isMemo = function(r) {
60
+ return o(r) === l;
61
+ }, e.isPortal = function(r) {
62
+ return o(r) === R;
63
+ }, e.isProfiler = function(r) {
64
+ return o(r) === i;
65
+ }, e.isStrictMode = function(r) {
66
+ return o(r) === s;
67
+ }, e.isSuspense = function(r) {
68
+ return o(r) === E;
69
+ }, e.isSuspenseList = function(r) {
70
+ return o(r) === c;
71
+ }, e.isValidElementType = function(r) {
72
+ return typeof r == "string" || typeof r == "function" || r === T || r === i || r === s || r === E || r === c || typeof r == "object" && r !== null && (r.$$typeof === _ || r.$$typeof === l || r.$$typeof === u || r.$$typeof === f || r.$$typeof === a || r.$$typeof === C || r.getModuleId !== void 0);
73
+ }, e.typeOf = o, e;
74
+ }
75
+ var t = {};
76
+ /**
77
+ * @license React
78
+ * react-is.development.js
79
+ *
80
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
81
+ *
82
+ * This source code is licensed under the MIT license found in the
83
+ * LICENSE file in the root directory of this source tree.
84
+ */
85
+ var A;
86
+ function p() {
87
+ return A || (A = 1, process.env.NODE_ENV !== "production" && function() {
88
+ function n(r) {
89
+ if (typeof r == "object" && r !== null) {
90
+ var m = r.$$typeof;
91
+ switch (m) {
92
+ case R:
93
+ switch (r = r.type, r) {
94
+ case s:
95
+ case f:
96
+ case i:
97
+ case c:
98
+ case l:
99
+ case C:
100
+ return r;
101
+ default:
102
+ switch (r = r && r.$$typeof, r) {
103
+ case a:
104
+ case E:
105
+ case S:
106
+ case _:
107
+ return r;
108
+ case u:
109
+ return r;
110
+ default:
111
+ return m;
112
+ }
113
+ }
114
+ case T:
115
+ return m;
116
+ }
117
+ }
118
+ }
119
+ var R = Symbol.for("react.transitional.element"), T = Symbol.for("react.portal"), s = Symbol.for("react.fragment"), i = Symbol.for("react.strict_mode"), f = Symbol.for("react.profiler"), u = Symbol.for("react.consumer"), a = Symbol.for("react.context"), E = Symbol.for("react.forward_ref"), c = Symbol.for("react.suspense"), l = Symbol.for("react.suspense_list"), _ = Symbol.for("react.memo"), S = Symbol.for("react.lazy"), C = Symbol.for("react.view_transition"), o = Symbol.for("react.client.reference");
120
+ t.ContextConsumer = u, t.ContextProvider = a, t.Element = R, t.ForwardRef = E, t.Fragment = s, t.Lazy = S, t.Memo = _, t.Portal = T, t.Profiler = f, t.StrictMode = i, t.Suspense = c, t.SuspenseList = l, t.isContextConsumer = function(r) {
121
+ return n(r) === u;
122
+ }, t.isContextProvider = function(r) {
123
+ return n(r) === a;
124
+ }, t.isElement = function(r) {
125
+ return typeof r == "object" && r !== null && r.$$typeof === R;
126
+ }, t.isForwardRef = function(r) {
127
+ return n(r) === E;
128
+ }, t.isFragment = function(r) {
129
+ return n(r) === s;
130
+ }, t.isLazy = function(r) {
131
+ return n(r) === S;
132
+ }, t.isMemo = function(r) {
133
+ return n(r) === _;
134
+ }, t.isPortal = function(r) {
135
+ return n(r) === T;
136
+ }, t.isProfiler = function(r) {
137
+ return n(r) === f;
138
+ }, t.isStrictMode = function(r) {
139
+ return n(r) === i;
140
+ }, t.isSuspense = function(r) {
141
+ return n(r) === c;
142
+ }, t.isSuspenseList = function(r) {
143
+ return n(r) === l;
144
+ }, t.isValidElementType = function(r) {
145
+ return typeof r == "string" || typeof r == "function" || r === s || r === f || r === i || r === c || r === l || typeof r == "object" && r !== null && (r.$$typeof === S || r.$$typeof === _ || r.$$typeof === a || r.$$typeof === u || r.$$typeof === E || r.$$typeof === o || r.getModuleId !== void 0);
146
+ }, t.typeOf = n;
147
+ }()), t;
148
+ }
149
+ process.env.NODE_ENV === "production" ? P.exports = y() : P.exports = p();
150
+ var Y = P.exports;
151
+ export {
152
+ Y as r
153
+ };
@@ -0,0 +1,318 @@
1
+ import ne, { useRef as ie, useState as L, useCallback as k, useEffect as F, isValidElement as oe, createRef as ae, cloneElement as P, PureComponent as ue } from "react";
2
+ import { findDOMNode as ce } from "react-dom";
3
+ import { c as H, g as Q } from "./_commonjsHelpers-BkfeUUK-.js";
4
+ function fe(e) {
5
+ var r = typeof e;
6
+ return e != null && (r == "object" || r == "function");
7
+ }
8
+ var A = fe, se = typeof H == "object" && H && H.Object === Object && H, de = se, le = de, he = typeof self == "object" && self && self.Object === Object && self, ve = le || he || Function("return this")(), Y = ve, ge = Y, pe = function() {
9
+ return ge.Date.now();
10
+ }, be = pe, me = /\s/;
11
+ function ye(e) {
12
+ for (var r = e.length; r-- && me.test(e.charAt(r)); )
13
+ ;
14
+ return r;
15
+ }
16
+ var Oe = ye, _e = Oe, we = /^\s+/;
17
+ function Re(e) {
18
+ return e && e.slice(0, _e(e) + 1).replace(we, "");
19
+ }
20
+ var Te = Re, Ee = Y, je = Ee.Symbol, Z = je, G = Z, ee = Object.prototype, Se = ee.hasOwnProperty, $e = ee.toString, x = G ? G.toStringTag : void 0;
21
+ function ze(e) {
22
+ var r = Se.call(e, x), n = e[x];
23
+ try {
24
+ e[x] = void 0;
25
+ var t = !0;
26
+ } catch {
27
+ }
28
+ var i = $e.call(e);
29
+ return t && (r ? e[x] = n : delete e[x]), i;
30
+ }
31
+ var xe = ze, Me = Object.prototype, ke = Me.toString;
32
+ function He(e) {
33
+ return ke.call(e);
34
+ }
35
+ var Pe = He, U = Z, Ie = xe, We = Pe, De = "[object Null]", Ae = "[object Undefined]", q = U ? U.toStringTag : void 0;
36
+ function Ce(e) {
37
+ return e == null ? e === void 0 ? Ae : De : q && q in Object(e) ? Ie(e) : We(e);
38
+ }
39
+ var Ne = Ce;
40
+ function Le(e) {
41
+ return e != null && typeof e == "object";
42
+ }
43
+ var Fe = Le, Ge = Ne, Ue = Fe, qe = "[object Symbol]";
44
+ function Be(e) {
45
+ return typeof e == "symbol" || Ue(e) && Ge(e) == qe;
46
+ }
47
+ var Xe = Be, Ve = Te, B = A, Je = Xe, X = NaN, Ke = /^[-+]0x[0-9a-f]+$/i, Qe = /^0b[01]+$/i, Ye = /^0o[0-7]+$/i, Ze = parseInt;
48
+ function et(e) {
49
+ if (typeof e == "number")
50
+ return e;
51
+ if (Je(e))
52
+ return X;
53
+ if (B(e)) {
54
+ var r = typeof e.valueOf == "function" ? e.valueOf() : e;
55
+ e = B(r) ? r + "" : r;
56
+ }
57
+ if (typeof e != "string")
58
+ return e === 0 ? e : +e;
59
+ e = Ve(e);
60
+ var n = Qe.test(e);
61
+ return n || Ye.test(e) ? Ze(e.slice(2), n ? 2 : 8) : Ke.test(e) ? X : +e;
62
+ }
63
+ var tt = et, rt = A, I = be, V = tt, nt = "Expected a function", it = Math.max, ot = Math.min;
64
+ function at(e, r, n) {
65
+ var t, i, d, g, s, p, c = 0, a = !1, u = !1, o = !0;
66
+ if (typeof e != "function")
67
+ throw new TypeError(nt);
68
+ r = V(r) || 0, rt(n) && (a = !!n.leading, u = "maxWait" in n, d = u ? it(V(n.maxWait) || 0, r) : d, o = "trailing" in n ? !!n.trailing : o);
69
+ function v(f) {
70
+ var w = t, j = i;
71
+ return t = i = void 0, c = f, g = e.apply(j, w), g;
72
+ }
73
+ function R(f) {
74
+ return c = f, s = setTimeout(l, r), a ? v(f) : g;
75
+ }
76
+ function y(f) {
77
+ var w = f - p, j = f - c, S = r - w;
78
+ return u ? ot(S, d - j) : S;
79
+ }
80
+ function T(f) {
81
+ var w = f - p, j = f - c;
82
+ return p === void 0 || w >= r || w < 0 || u && j >= d;
83
+ }
84
+ function l() {
85
+ var f = I();
86
+ if (T(f))
87
+ return b(f);
88
+ s = setTimeout(l, y(f));
89
+ }
90
+ function b(f) {
91
+ return s = void 0, o && t ? v(f) : (t = i = void 0, g);
92
+ }
93
+ function O() {
94
+ s !== void 0 && clearTimeout(s), c = 0, t = p = i = s = void 0;
95
+ }
96
+ function _() {
97
+ return s === void 0 ? g : b(I());
98
+ }
99
+ function E() {
100
+ var f = I(), w = T(f);
101
+ if (t = arguments, i = this, p = f, w) {
102
+ if (s === void 0)
103
+ return R(p);
104
+ if (u)
105
+ return clearTimeout(s), s = setTimeout(l, r), v(p);
106
+ }
107
+ return s === void 0 && (s = setTimeout(l, r)), g;
108
+ }
109
+ return E.cancel = O, E.flush = _, E;
110
+ }
111
+ var te = at;
112
+ const ut = /* @__PURE__ */ Q(te);
113
+ var ct = te, ft = A, st = "Expected a function";
114
+ function dt(e, r, n) {
115
+ var t = !0, i = !0;
116
+ if (typeof e != "function")
117
+ throw new TypeError(st);
118
+ return ft(n) && (t = "leading" in n ? !!n.leading : t, i = "trailing" in n ? !!n.trailing : i), ct(e, r, {
119
+ leading: t,
120
+ maxWait: r,
121
+ trailing: i
122
+ });
123
+ }
124
+ var lt = dt;
125
+ const ht = /* @__PURE__ */ Q(lt);
126
+ var W = function(e, r) {
127
+ return W = Object.setPrototypeOf || { __proto__: [] } instanceof Array && function(n, t) {
128
+ n.__proto__ = t;
129
+ } || function(n, t) {
130
+ for (var i in t) Object.prototype.hasOwnProperty.call(t, i) && (n[i] = t[i]);
131
+ }, W(e, r);
132
+ };
133
+ function vt(e, r) {
134
+ if (typeof r != "function" && r !== null)
135
+ throw new TypeError("Class extends value " + String(r) + " is not a constructor or null");
136
+ W(e, r);
137
+ function n() {
138
+ this.constructor = e;
139
+ }
140
+ e.prototype = r === null ? Object.create(r) : (n.prototype = r.prototype, new n());
141
+ }
142
+ var D = function() {
143
+ return D = Object.assign || function(r) {
144
+ for (var n, t = 1, i = arguments.length; t < i; t++) {
145
+ n = arguments[t];
146
+ for (var d in n) Object.prototype.hasOwnProperty.call(n, d) && (r[d] = n[d]);
147
+ }
148
+ return r;
149
+ }, D.apply(this, arguments);
150
+ };
151
+ function gt(e, r) {
152
+ var n = {};
153
+ for (var t in e) Object.prototype.hasOwnProperty.call(e, t) && r.indexOf(t) < 0 && (n[t] = e[t]);
154
+ if (e != null && typeof Object.getOwnPropertySymbols == "function")
155
+ for (var i = 0, t = Object.getOwnPropertySymbols(e); i < t.length; i++)
156
+ r.indexOf(t[i]) < 0 && Object.prototype.propertyIsEnumerable.call(e, t[i]) && (n[t[i]] = e[t[i]]);
157
+ return n;
158
+ }
159
+ var re = function(e, r, n, t) {
160
+ switch (r) {
161
+ case "debounce":
162
+ return ut(e, n, t);
163
+ case "throttle":
164
+ return ht(e, n, t);
165
+ default:
166
+ return e;
167
+ }
168
+ }, J = function(e) {
169
+ return typeof e == "function";
170
+ }, M = function() {
171
+ return typeof window > "u";
172
+ }, K = function(e) {
173
+ return e instanceof Element || e instanceof HTMLDocument;
174
+ };
175
+ (function(e) {
176
+ vt(r, e);
177
+ function r(n) {
178
+ var t = e.call(this, n) || this;
179
+ t.cancelHandler = function() {
180
+ t.resizeHandler && t.resizeHandler.cancel && (t.resizeHandler.cancel(), t.resizeHandler = null);
181
+ }, t.attachObserver = function() {
182
+ var c = t.props, a = c.targetRef, u = c.observerOptions;
183
+ if (!M()) {
184
+ a && a.current && (t.targetRef.current = a.current);
185
+ var o = t.getElement();
186
+ o && (t.observableElement && t.observableElement === o || (t.observableElement = o, t.resizeObserver.observe(o, u)));
187
+ }
188
+ }, t.getElement = function() {
189
+ var c = t.props, a = c.querySelector, u = c.targetDomEl;
190
+ if (M())
191
+ return null;
192
+ if (a)
193
+ return document.querySelector(a);
194
+ if (u && K(u))
195
+ return u;
196
+ if (t.targetRef && K(t.targetRef.current))
197
+ return t.targetRef.current;
198
+ var o = ce(t);
199
+ if (!o)
200
+ return null;
201
+ var v = t.getRenderType();
202
+ switch (v) {
203
+ case "renderProp":
204
+ return o;
205
+ case "childFunction":
206
+ return o;
207
+ case "child":
208
+ return o;
209
+ case "childArray":
210
+ return o;
211
+ default:
212
+ return o.parentElement;
213
+ }
214
+ }, t.createResizeHandler = function(c) {
215
+ var a = t.props, u = a.handleWidth, o = u === void 0 ? !0 : u, v = a.handleHeight, R = v === void 0 ? !0 : v, y = a.onResize;
216
+ if (!(!o && !R)) {
217
+ var T = function(l) {
218
+ var b = l.width, O = l.height;
219
+ t.state.width === b && t.state.height === O || t.state.width === b && !R || t.state.height === O && !o || (y == null || y(b, O), t.setState({ width: b, height: O }));
220
+ };
221
+ c.forEach(function(l) {
222
+ var b = l && l.contentRect || {}, O = b.width, _ = b.height, E = !t.skipOnMount && !M();
223
+ E && T({ width: O, height: _ }), t.skipOnMount = !1;
224
+ });
225
+ }
226
+ }, t.getRenderType = function() {
227
+ var c = t.props, a = c.render, u = c.children;
228
+ return J(a) ? "renderProp" : J(u) ? "childFunction" : oe(u) ? "child" : Array.isArray(u) ? "childArray" : "parent";
229
+ };
230
+ var i = n.skipOnMount, d = n.refreshMode, g = n.refreshRate, s = g === void 0 ? 1e3 : g, p = n.refreshOptions;
231
+ return t.state = {
232
+ width: void 0,
233
+ height: void 0
234
+ }, t.sizeRef = {
235
+ current: t.state
236
+ }, t.skipOnMount = i, t.targetRef = ae(), t.observableElement = null, M() || (t.resizeHandler = re(t.createResizeHandler, d, s, p), t.resizeObserver = new window.ResizeObserver(t.resizeHandler)), t;
237
+ }
238
+ return r.prototype.componentDidMount = function() {
239
+ this.attachObserver();
240
+ }, r.prototype.componentDidUpdate = function() {
241
+ this.attachObserver(), this.sizeRef.current = this.state;
242
+ }, r.prototype.componentWillUnmount = function() {
243
+ M() || (this.observableElement = null, this.resizeObserver.disconnect(), this.cancelHandler());
244
+ }, r.prototype.render = function() {
245
+ var n = this.props, t = n.render, i = n.children, d = n.nodeType, g = d === void 0 ? "div" : d, s = this.state, p = s.width, c = s.height, a = { width: p, height: c, targetRef: this.targetRef }, u = this.getRenderType();
246
+ switch (u) {
247
+ case "renderProp":
248
+ return t == null ? void 0 : t(a);
249
+ case "childFunction": {
250
+ var o = i;
251
+ return o == null ? void 0 : o(a);
252
+ }
253
+ case "child": {
254
+ var v = i;
255
+ if (v.type && typeof v.type == "string") {
256
+ a.targetRef;
257
+ var R = gt(a, ["targetRef"]);
258
+ return P(v, R);
259
+ }
260
+ return P(v, a);
261
+ }
262
+ case "childArray": {
263
+ var y = i;
264
+ return y.map(function(T) {
265
+ return !!T && P(T, a);
266
+ });
267
+ }
268
+ default:
269
+ return ne.createElement(g, null);
270
+ }
271
+ }, r;
272
+ })(ue);
273
+ function yt(e) {
274
+ var r = {}, n = r.skipOnMount, t = n === void 0 ? !1 : n, i = r.refreshMode, d = r.refreshRate, g = d === void 0 ? 1e3 : d, s = r.refreshOptions, p = r.handleWidth, c = p === void 0 ? !0 : p, a = r.handleHeight, u = a === void 0 ? !0 : a, o = r.targetRef, v = r.observerOptions, R = r.onResize, y = ie(t), T = L({
275
+ width: void 0,
276
+ height: void 0
277
+ }), l = T[0], b = T[1], O = L((o == null ? void 0 : o.current) || null), _ = O[0], E = O[1];
278
+ o && setTimeout(function() {
279
+ o.current !== _ && E(o.current);
280
+ }, 0);
281
+ var f = k(function(h) {
282
+ h !== _ && E(h);
283
+ }, [_]);
284
+ f.current = _;
285
+ var w = k(function(h, m) {
286
+ return !(h.width === m.width && h.height === m.height || h.width === m.width && !u || h.height === m.height && !c);
287
+ }, [c, u]), j = k(function(h) {
288
+ if (!(!c && !u)) {
289
+ if (y.current) {
290
+ y.current = !1;
291
+ return;
292
+ }
293
+ h.forEach(function(m) {
294
+ var z = (m == null ? void 0 : m.contentRect) || {}, $ = z.width, C = z.height;
295
+ b(function(N) {
296
+ return w(N, { width: $, height: C }) ? { width: $, height: C } : N;
297
+ });
298
+ });
299
+ }
300
+ }, [c, u, y, w]), S = k(re(j, i, g, s), [
301
+ j,
302
+ i,
303
+ g,
304
+ s
305
+ ]);
306
+ return F(function() {
307
+ var h;
308
+ return _ ? (h = new window.ResizeObserver(S), h.observe(_, v)) : (l.width || l.height) && b({ width: void 0, height: void 0 }), function() {
309
+ var m, z, $;
310
+ (m = h == null ? void 0 : h.disconnect) === null || m === void 0 || m.call(h), ($ = (z = S).cancel) === null || $ === void 0 || $.call(z);
311
+ };
312
+ }, [S, _]), F(function() {
313
+ R == null || R(l.width, l.height);
314
+ }, [l]), D({ ref: f }, l);
315
+ }
316
+ export {
317
+ yt as u
318
+ };
package/dist/main.d.ts CHANGED
@@ -233,6 +233,7 @@ export declare interface ChartDimension {
233
233
  export declare type ChartNameType =
234
234
  | "HeatLegend"
235
235
  | "XYChart"
236
+ | "XYChartHorizontal"
236
237
  | "MultipleValueAxes"
237
238
  | "PieChart"
238
239
  | "DonutChart"
@@ -2370,7 +2371,14 @@ export declare type XYChartComponentOverride<Theme = unknown> = {
2370
2371
  styleOverrides?: ComponentsOverrides_2<Theme>["HCXYChart"];
2371
2372
  };
2372
2373
 
2373
- export declare type XYChartProps = ChartProps;
2374
+ export declare type XYChartProps = ChartProps & {
2375
+ /**
2376
+ * Axis orientation. `"vertical"` (default) draws category on the X axis with
2377
+ * value columns rising on Y. `"horizontal"` flips them — category on Y, value
2378
+ * bars extending along X — producing a horizontal bar chart.
2379
+ */
2380
+ orientation?: "vertical" | "horizontal";
2381
+ };
2374
2382
 
2375
2383
  export { }
2376
2384