@automattic/charts 1.0.1 → 1.1.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 +20 -0
- package/dist/{chunk-G3PMV62Z.js → chunk-5WRI5ZAA.js} +1 -6
- package/dist/{chunk-EMMSS5I5.cjs → chunk-DZUJEN5N.cjs} +2 -7
- package/dist/chunk-DZUJEN5N.cjs.map +1 -0
- package/dist/index.cjs +602 -1386
- package/dist/index.cjs.map +1 -1
- package/dist/index.css +36 -52
- package/dist/index.css.map +1 -1
- package/dist/index.d.cts +3 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.js +699 -1483
- package/dist/index.js.map +1 -1
- package/dist/visx/group/index.cjs +1 -1
- package/dist/visx/group/index.js +1 -1
- package/dist/visx/legend/index.cjs +1 -1
- package/dist/visx/legend/index.js +1 -1
- package/dist/visx/text/index.cjs +1 -1
- package/dist/visx/text/index.js +1 -1
- package/package.json +12 -11
- package/src/charts/conversion-funnel-chart/conversion-funnel-chart.module.scss +26 -42
- package/src/charts/conversion-funnel-chart/conversion-funnel-chart.tsx +18 -5
- package/src/charts/conversion-funnel-chart/test/conversion-funnel-chart.test.tsx +11 -0
- package/src/charts/leaderboard-chart/leaderboard-chart.module.scss +1 -1
- package/src/charts/leaderboard-chart/leaderboard-chart.tsx +2 -2
- package/src/charts/line-chart/line-chart.module.scss +3 -3
- package/src/charts/line-chart/private/line-chart-annotation-label-popover.tsx +2 -2
- package/src/charts/pie-chart/pie-chart.tsx +5 -3
- package/src/charts/pie-semi-circle-chart/pie-semi-circle-chart.module.scss +3 -3
- package/src/components/legend/private/base-legend.module.scss +2 -2
- package/src/components/tooltip/base-tooltip.module.scss +1 -1
- package/src/components/trend-indicator/trend-indicator.module.scss +2 -2
- package/src/hooks/use-chart-margin.tsx +1 -14
- package/src/providers/chart-context/global-charts-provider.tsx +13 -0
- package/src/providers/chart-context/test/chart-context.test.tsx +51 -0
- package/src/providers/chart-context/themes.ts +7 -1
- package/src/providers/chart-context/types.ts +1 -0
- package/src/types.ts +2 -0
- package/src/utils/index.ts +3 -0
- package/src/utils/resolve-font-size.ts +37 -0
- package/src/utils/test/resolve-css-var.test.ts +3 -5
- package/src/utils/test/resolve-font-size.test.ts +66 -0
- package/dist/chunk-EMMSS5I5.cjs.map +0 -1
- /package/dist/{chunk-G3PMV62Z.js.map → chunk-5WRI5ZAA.js.map} +0 -0
package/dist/index.cjs
CHANGED
|
@@ -4,159 +4,158 @@ var _chunk7OZEQ5HEcjs = require('./chunk-7OZEQ5HE.cjs');
|
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
7
|
-
|
|
8
|
-
var _chunkEMMSS5I5cjs = require('./chunk-EMMSS5I5.cjs');
|
|
7
|
+
var _chunkDZUJEN5Ncjs = require('./chunk-DZUJEN5N.cjs');
|
|
9
8
|
|
|
10
9
|
// ../../../node_modules/.pnpm/fast-deep-equal@3.1.3/node_modules/fast-deep-equal/index.js
|
|
11
|
-
var require_fast_deep_equal =
|
|
10
|
+
var require_fast_deep_equal = _chunkDZUJEN5Ncjs.__commonJS.call(void 0, {
|
|
12
11
|
"../../../node_modules/.pnpm/fast-deep-equal@3.1.3/node_modules/fast-deep-equal/index.js"(exports, module) {
|
|
13
12
|
"use strict";
|
|
14
|
-
module.exports = function equal(
|
|
15
|
-
if (
|
|
16
|
-
if (
|
|
17
|
-
if (
|
|
18
|
-
var length2,
|
|
19
|
-
if (Array.isArray(
|
|
20
|
-
length2 =
|
|
21
|
-
if (length2 !=
|
|
22
|
-
for (
|
|
23
|
-
if (!equal(
|
|
13
|
+
module.exports = function equal(a, b) {
|
|
14
|
+
if (a === b) return true;
|
|
15
|
+
if (a && b && typeof a == "object" && typeof b == "object") {
|
|
16
|
+
if (a.constructor !== b.constructor) return false;
|
|
17
|
+
var length2, i, keys;
|
|
18
|
+
if (Array.isArray(a)) {
|
|
19
|
+
length2 = a.length;
|
|
20
|
+
if (length2 != b.length) return false;
|
|
21
|
+
for (i = length2; i-- !== 0; )
|
|
22
|
+
if (!equal(a[i], b[i])) return false;
|
|
24
23
|
return true;
|
|
25
24
|
}
|
|
26
|
-
if (
|
|
27
|
-
if (
|
|
28
|
-
if (
|
|
29
|
-
keys = Object.keys(
|
|
25
|
+
if (a.constructor === RegExp) return a.source === b.source && a.flags === b.flags;
|
|
26
|
+
if (a.valueOf !== Object.prototype.valueOf) return a.valueOf() === b.valueOf();
|
|
27
|
+
if (a.toString !== Object.prototype.toString) return a.toString() === b.toString();
|
|
28
|
+
keys = Object.keys(a);
|
|
30
29
|
length2 = keys.length;
|
|
31
|
-
if (length2 !== Object.keys(
|
|
32
|
-
for (
|
|
33
|
-
if (!Object.prototype.hasOwnProperty.call(
|
|
34
|
-
for (
|
|
35
|
-
var key = keys[
|
|
36
|
-
if (!equal(
|
|
30
|
+
if (length2 !== Object.keys(b).length) return false;
|
|
31
|
+
for (i = length2; i-- !== 0; )
|
|
32
|
+
if (!Object.prototype.hasOwnProperty.call(b, keys[i])) return false;
|
|
33
|
+
for (i = length2; i-- !== 0; ) {
|
|
34
|
+
var key = keys[i];
|
|
35
|
+
if (!equal(a[key], b[key])) return false;
|
|
37
36
|
}
|
|
38
37
|
return true;
|
|
39
38
|
}
|
|
40
|
-
return
|
|
39
|
+
return a !== a && b !== b;
|
|
41
40
|
};
|
|
42
41
|
}
|
|
43
42
|
});
|
|
44
43
|
|
|
45
44
|
// ../../../node_modules/.pnpm/react-is@16.13.1/node_modules/react-is/cjs/react-is.production.min.js
|
|
46
|
-
var require_react_is_production_min =
|
|
45
|
+
var require_react_is_production_min = _chunkDZUJEN5Ncjs.__commonJS.call(void 0, {
|
|
47
46
|
"../../../node_modules/.pnpm/react-is@16.13.1/node_modules/react-is/cjs/react-is.production.min.js"(exports) {
|
|
48
47
|
"use strict";
|
|
49
|
-
var
|
|
50
|
-
var
|
|
51
|
-
var
|
|
52
|
-
var
|
|
53
|
-
var
|
|
54
|
-
var
|
|
55
|
-
var
|
|
56
|
-
var
|
|
57
|
-
var
|
|
58
|
-
var
|
|
59
|
-
var
|
|
60
|
-
var
|
|
61
|
-
var q =
|
|
62
|
-
var
|
|
63
|
-
var
|
|
64
|
-
var
|
|
65
|
-
var
|
|
66
|
-
var
|
|
67
|
-
var
|
|
68
|
-
function z(
|
|
69
|
-
if ("object" === typeof
|
|
70
|
-
var
|
|
71
|
-
switch (
|
|
72
|
-
case
|
|
73
|
-
switch (
|
|
74
|
-
case
|
|
75
|
-
case
|
|
76
|
-
case
|
|
77
|
-
case
|
|
78
|
-
case
|
|
79
|
-
case
|
|
80
|
-
return
|
|
48
|
+
var b = "function" === typeof Symbol && Symbol.for;
|
|
49
|
+
var c = b ? /* @__PURE__ */ Symbol.for("react.element") : 60103;
|
|
50
|
+
var d = b ? /* @__PURE__ */ Symbol.for("react.portal") : 60106;
|
|
51
|
+
var e = b ? /* @__PURE__ */ Symbol.for("react.fragment") : 60107;
|
|
52
|
+
var f = b ? /* @__PURE__ */ Symbol.for("react.strict_mode") : 60108;
|
|
53
|
+
var g = b ? /* @__PURE__ */ Symbol.for("react.profiler") : 60114;
|
|
54
|
+
var h = b ? /* @__PURE__ */ Symbol.for("react.provider") : 60109;
|
|
55
|
+
var k = b ? /* @__PURE__ */ Symbol.for("react.context") : 60110;
|
|
56
|
+
var l = b ? /* @__PURE__ */ Symbol.for("react.async_mode") : 60111;
|
|
57
|
+
var m = b ? /* @__PURE__ */ Symbol.for("react.concurrent_mode") : 60111;
|
|
58
|
+
var n = b ? /* @__PURE__ */ Symbol.for("react.forward_ref") : 60112;
|
|
59
|
+
var p = b ? /* @__PURE__ */ Symbol.for("react.suspense") : 60113;
|
|
60
|
+
var q = b ? /* @__PURE__ */ Symbol.for("react.suspense_list") : 60120;
|
|
61
|
+
var r = b ? /* @__PURE__ */ Symbol.for("react.memo") : 60115;
|
|
62
|
+
var t = b ? /* @__PURE__ */ Symbol.for("react.lazy") : 60116;
|
|
63
|
+
var v = b ? /* @__PURE__ */ Symbol.for("react.block") : 60121;
|
|
64
|
+
var w = b ? /* @__PURE__ */ Symbol.for("react.fundamental") : 60117;
|
|
65
|
+
var x = b ? /* @__PURE__ */ Symbol.for("react.responder") : 60118;
|
|
66
|
+
var y = b ? /* @__PURE__ */ Symbol.for("react.scope") : 60119;
|
|
67
|
+
function z(a) {
|
|
68
|
+
if ("object" === typeof a && null !== a) {
|
|
69
|
+
var u = a.$$typeof;
|
|
70
|
+
switch (u) {
|
|
71
|
+
case c:
|
|
72
|
+
switch (a = a.type, a) {
|
|
73
|
+
case l:
|
|
74
|
+
case m:
|
|
75
|
+
case e:
|
|
76
|
+
case g:
|
|
77
|
+
case f:
|
|
78
|
+
case p:
|
|
79
|
+
return a;
|
|
81
80
|
default:
|
|
82
|
-
switch (
|
|
83
|
-
case
|
|
84
|
-
case
|
|
85
|
-
case
|
|
86
|
-
case
|
|
87
|
-
case
|
|
88
|
-
return
|
|
81
|
+
switch (a = a && a.$$typeof, a) {
|
|
82
|
+
case k:
|
|
83
|
+
case n:
|
|
84
|
+
case t:
|
|
85
|
+
case r:
|
|
86
|
+
case h:
|
|
87
|
+
return a;
|
|
89
88
|
default:
|
|
90
|
-
return
|
|
89
|
+
return u;
|
|
91
90
|
}
|
|
92
91
|
}
|
|
93
|
-
case
|
|
94
|
-
return
|
|
92
|
+
case d:
|
|
93
|
+
return u;
|
|
95
94
|
}
|
|
96
95
|
}
|
|
97
96
|
}
|
|
98
|
-
function A(
|
|
99
|
-
return z(
|
|
100
|
-
}
|
|
101
|
-
exports.AsyncMode =
|
|
102
|
-
exports.ConcurrentMode =
|
|
103
|
-
exports.ContextConsumer =
|
|
104
|
-
exports.ContextProvider =
|
|
105
|
-
exports.Element =
|
|
106
|
-
exports.ForwardRef =
|
|
107
|
-
exports.Fragment =
|
|
108
|
-
exports.Lazy =
|
|
109
|
-
exports.Memo =
|
|
110
|
-
exports.Portal =
|
|
111
|
-
exports.Profiler =
|
|
112
|
-
exports.StrictMode =
|
|
113
|
-
exports.Suspense =
|
|
114
|
-
exports.isAsyncMode = function(
|
|
115
|
-
return A(
|
|
97
|
+
function A(a) {
|
|
98
|
+
return z(a) === m;
|
|
99
|
+
}
|
|
100
|
+
exports.AsyncMode = l;
|
|
101
|
+
exports.ConcurrentMode = m;
|
|
102
|
+
exports.ContextConsumer = k;
|
|
103
|
+
exports.ContextProvider = h;
|
|
104
|
+
exports.Element = c;
|
|
105
|
+
exports.ForwardRef = n;
|
|
106
|
+
exports.Fragment = e;
|
|
107
|
+
exports.Lazy = t;
|
|
108
|
+
exports.Memo = r;
|
|
109
|
+
exports.Portal = d;
|
|
110
|
+
exports.Profiler = g;
|
|
111
|
+
exports.StrictMode = f;
|
|
112
|
+
exports.Suspense = p;
|
|
113
|
+
exports.isAsyncMode = function(a) {
|
|
114
|
+
return A(a) || z(a) === l;
|
|
116
115
|
};
|
|
117
116
|
exports.isConcurrentMode = A;
|
|
118
|
-
exports.isContextConsumer = function(
|
|
119
|
-
return z(
|
|
117
|
+
exports.isContextConsumer = function(a) {
|
|
118
|
+
return z(a) === k;
|
|
120
119
|
};
|
|
121
|
-
exports.isContextProvider = function(
|
|
122
|
-
return z(
|
|
120
|
+
exports.isContextProvider = function(a) {
|
|
121
|
+
return z(a) === h;
|
|
123
122
|
};
|
|
124
|
-
exports.isElement = function(
|
|
125
|
-
return "object" === typeof
|
|
123
|
+
exports.isElement = function(a) {
|
|
124
|
+
return "object" === typeof a && null !== a && a.$$typeof === c;
|
|
126
125
|
};
|
|
127
|
-
exports.isForwardRef = function(
|
|
128
|
-
return z(
|
|
126
|
+
exports.isForwardRef = function(a) {
|
|
127
|
+
return z(a) === n;
|
|
129
128
|
};
|
|
130
|
-
exports.isFragment = function(
|
|
131
|
-
return z(
|
|
129
|
+
exports.isFragment = function(a) {
|
|
130
|
+
return z(a) === e;
|
|
132
131
|
};
|
|
133
|
-
exports.isLazy = function(
|
|
134
|
-
return z(
|
|
132
|
+
exports.isLazy = function(a) {
|
|
133
|
+
return z(a) === t;
|
|
135
134
|
};
|
|
136
|
-
exports.isMemo = function(
|
|
137
|
-
return z(
|
|
135
|
+
exports.isMemo = function(a) {
|
|
136
|
+
return z(a) === r;
|
|
138
137
|
};
|
|
139
|
-
exports.isPortal = function(
|
|
140
|
-
return z(
|
|
138
|
+
exports.isPortal = function(a) {
|
|
139
|
+
return z(a) === d;
|
|
141
140
|
};
|
|
142
|
-
exports.isProfiler = function(
|
|
143
|
-
return z(
|
|
141
|
+
exports.isProfiler = function(a) {
|
|
142
|
+
return z(a) === g;
|
|
144
143
|
};
|
|
145
|
-
exports.isStrictMode = function(
|
|
146
|
-
return z(
|
|
144
|
+
exports.isStrictMode = function(a) {
|
|
145
|
+
return z(a) === f;
|
|
147
146
|
};
|
|
148
|
-
exports.isSuspense = function(
|
|
149
|
-
return z(
|
|
147
|
+
exports.isSuspense = function(a) {
|
|
148
|
+
return z(a) === p;
|
|
150
149
|
};
|
|
151
|
-
exports.isValidElementType = function(
|
|
152
|
-
return "string" === typeof
|
|
150
|
+
exports.isValidElementType = function(a) {
|
|
151
|
+
return "string" === typeof a || "function" === typeof a || a === e || a === m || a === g || a === f || a === p || a === q || "object" === typeof a && null !== a && (a.$$typeof === t || a.$$typeof === r || a.$$typeof === h || a.$$typeof === k || a.$$typeof === n || a.$$typeof === w || a.$$typeof === x || a.$$typeof === y || a.$$typeof === v);
|
|
153
152
|
};
|
|
154
153
|
exports.typeOf = z;
|
|
155
154
|
}
|
|
156
155
|
});
|
|
157
156
|
|
|
158
157
|
// ../../../node_modules/.pnpm/react-is@16.13.1/node_modules/react-is/cjs/react-is.development.js
|
|
159
|
-
var require_react_is_development =
|
|
158
|
+
var require_react_is_development = _chunkDZUJEN5Ncjs.__commonJS.call(void 0, {
|
|
160
159
|
"../../../node_modules/.pnpm/react-is@16.13.1/node_modules/react-is/cjs/react-is.development.js"(exports) {
|
|
161
160
|
"use strict";
|
|
162
161
|
if (process.env.NODE_ENV !== "production") {
|
|
@@ -311,7 +310,7 @@ var require_react_is_development = _chunkEMMSS5I5cjs.__commonJS.call(void 0, {
|
|
|
311
310
|
});
|
|
312
311
|
|
|
313
312
|
// ../../../node_modules/.pnpm/react-is@16.13.1/node_modules/react-is/index.js
|
|
314
|
-
var require_react_is =
|
|
313
|
+
var require_react_is = _chunkDZUJEN5Ncjs.__commonJS.call(void 0, {
|
|
315
314
|
"../../../node_modules/.pnpm/react-is@16.13.1/node_modules/react-is/index.js"(exports, module) {
|
|
316
315
|
"use strict";
|
|
317
316
|
if (process.env.NODE_ENV === "production") {
|
|
@@ -323,7 +322,7 @@ var require_react_is = _chunkEMMSS5I5cjs.__commonJS.call(void 0, {
|
|
|
323
322
|
});
|
|
324
323
|
|
|
325
324
|
// ../../../node_modules/.pnpm/hoist-non-react-statics@3.3.2/node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js
|
|
326
|
-
var require_hoist_non_react_statics_cjs =
|
|
325
|
+
var require_hoist_non_react_statics_cjs = _chunkDZUJEN5Ncjs.__commonJS.call(void 0, {
|
|
327
326
|
"../../../node_modules/.pnpm/hoist-non-react-statics@3.3.2/node_modules/hoist-non-react-statics/dist/hoist-non-react-statics.cjs.js"(exports, module) {
|
|
328
327
|
"use strict";
|
|
329
328
|
var reactIs = require_react_is();
|
|
@@ -393,13 +392,13 @@ var require_hoist_non_react_statics_cjs = _chunkEMMSS5I5cjs.__commonJS.call(void
|
|
|
393
392
|
}
|
|
394
393
|
var targetStatics = getStatics(targetComponent);
|
|
395
394
|
var sourceStatics = getStatics(sourceComponent);
|
|
396
|
-
for (var
|
|
397
|
-
var key = keys[
|
|
395
|
+
for (var i = 0; i < keys.length; ++i) {
|
|
396
|
+
var key = keys[i];
|
|
398
397
|
if (!KNOWN_STATICS[key] && !(blacklist && blacklist[key]) && !(sourceStatics && sourceStatics[key]) && !(targetStatics && targetStatics[key])) {
|
|
399
398
|
var descriptor = getOwnPropertyDescriptor(sourceComponent, key);
|
|
400
399
|
try {
|
|
401
400
|
defineProperty(targetComponent, key, descriptor);
|
|
402
|
-
} catch (
|
|
401
|
+
} catch (e) {
|
|
403
402
|
}
|
|
404
403
|
}
|
|
405
404
|
}
|
|
@@ -411,231 +410,61 @@ var require_hoist_non_react_statics_cjs = _chunkEMMSS5I5cjs.__commonJS.call(void
|
|
|
411
410
|
});
|
|
412
411
|
|
|
413
412
|
// ../../../node_modules/.pnpm/fast-deep-equal@3.1.3/node_modules/fast-deep-equal/es6/index.js
|
|
414
|
-
var require_es6 =
|
|
413
|
+
var require_es6 = _chunkDZUJEN5Ncjs.__commonJS.call(void 0, {
|
|
415
414
|
"../../../node_modules/.pnpm/fast-deep-equal@3.1.3/node_modules/fast-deep-equal/es6/index.js"(exports, module) {
|
|
416
415
|
"use strict";
|
|
417
|
-
module.exports = function equal(
|
|
418
|
-
if (
|
|
419
|
-
if (
|
|
420
|
-
if (
|
|
421
|
-
var length2,
|
|
422
|
-
if (Array.isArray(
|
|
423
|
-
length2 =
|
|
424
|
-
if (length2 !=
|
|
425
|
-
for (
|
|
426
|
-
if (!equal(
|
|
416
|
+
module.exports = function equal(a, b) {
|
|
417
|
+
if (a === b) return true;
|
|
418
|
+
if (a && b && typeof a == "object" && typeof b == "object") {
|
|
419
|
+
if (a.constructor !== b.constructor) return false;
|
|
420
|
+
var length2, i, keys;
|
|
421
|
+
if (Array.isArray(a)) {
|
|
422
|
+
length2 = a.length;
|
|
423
|
+
if (length2 != b.length) return false;
|
|
424
|
+
for (i = length2; i-- !== 0; )
|
|
425
|
+
if (!equal(a[i], b[i])) return false;
|
|
427
426
|
return true;
|
|
428
427
|
}
|
|
429
|
-
if (
|
|
430
|
-
if (
|
|
431
|
-
for (
|
|
432
|
-
if (!
|
|
433
|
-
for (
|
|
434
|
-
if (!equal(
|
|
428
|
+
if (a instanceof Map && b instanceof Map) {
|
|
429
|
+
if (a.size !== b.size) return false;
|
|
430
|
+
for (i of a.entries())
|
|
431
|
+
if (!b.has(i[0])) return false;
|
|
432
|
+
for (i of a.entries())
|
|
433
|
+
if (!equal(i[1], b.get(i[0]))) return false;
|
|
435
434
|
return true;
|
|
436
435
|
}
|
|
437
|
-
if (
|
|
438
|
-
if (
|
|
439
|
-
for (
|
|
440
|
-
if (!
|
|
436
|
+
if (a instanceof Set && b instanceof Set) {
|
|
437
|
+
if (a.size !== b.size) return false;
|
|
438
|
+
for (i of a.entries())
|
|
439
|
+
if (!b.has(i[0])) return false;
|
|
441
440
|
return true;
|
|
442
441
|
}
|
|
443
|
-
if (ArrayBuffer.isView(
|
|
444
|
-
length2 =
|
|
445
|
-
if (length2 !=
|
|
446
|
-
for (
|
|
447
|
-
if (
|
|
442
|
+
if (ArrayBuffer.isView(a) && ArrayBuffer.isView(b)) {
|
|
443
|
+
length2 = a.length;
|
|
444
|
+
if (length2 != b.length) return false;
|
|
445
|
+
for (i = length2; i-- !== 0; )
|
|
446
|
+
if (a[i] !== b[i]) return false;
|
|
448
447
|
return true;
|
|
449
448
|
}
|
|
450
|
-
if (
|
|
451
|
-
if (
|
|
452
|
-
if (
|
|
453
|
-
keys = Object.keys(
|
|
449
|
+
if (a.constructor === RegExp) return a.source === b.source && a.flags === b.flags;
|
|
450
|
+
if (a.valueOf !== Object.prototype.valueOf) return a.valueOf() === b.valueOf();
|
|
451
|
+
if (a.toString !== Object.prototype.toString) return a.toString() === b.toString();
|
|
452
|
+
keys = Object.keys(a);
|
|
454
453
|
length2 = keys.length;
|
|
455
|
-
if (length2 !== Object.keys(
|
|
456
|
-
for (
|
|
457
|
-
if (!Object.prototype.hasOwnProperty.call(
|
|
458
|
-
for (
|
|
459
|
-
var key = keys[
|
|
460
|
-
if (!equal(
|
|
454
|
+
if (length2 !== Object.keys(b).length) return false;
|
|
455
|
+
for (i = length2; i-- !== 0; )
|
|
456
|
+
if (!Object.prototype.hasOwnProperty.call(b, keys[i])) return false;
|
|
457
|
+
for (i = length2; i-- !== 0; ) {
|
|
458
|
+
var key = keys[i];
|
|
459
|
+
if (!equal(a[key], b[key])) return false;
|
|
461
460
|
}
|
|
462
461
|
return true;
|
|
463
462
|
}
|
|
464
|
-
return
|
|
463
|
+
return a !== a && b !== b;
|
|
465
464
|
};
|
|
466
465
|
}
|
|
467
466
|
});
|
|
468
467
|
|
|
469
|
-
// ../../../node_modules/.pnpm/highlight-words-core@1.2.3/node_modules/highlight-words-core/dist/index.js
|
|
470
|
-
var require_dist = _chunkEMMSS5I5cjs.__commonJS.call(void 0, {
|
|
471
|
-
"../../../node_modules/.pnpm/highlight-words-core@1.2.3/node_modules/highlight-words-core/dist/index.js"(exports, module) {
|
|
472
|
-
module.exports = /******/
|
|
473
|
-
(function(modules) {
|
|
474
|
-
var installedModules = {};
|
|
475
|
-
function __webpack_require__(moduleId) {
|
|
476
|
-
if (installedModules[moduleId])
|
|
477
|
-
return installedModules[moduleId].exports;
|
|
478
|
-
var module2 = installedModules[moduleId] = {
|
|
479
|
-
/******/
|
|
480
|
-
exports: {},
|
|
481
|
-
/******/
|
|
482
|
-
id: moduleId,
|
|
483
|
-
/******/
|
|
484
|
-
loaded: false
|
|
485
|
-
/******/
|
|
486
|
-
};
|
|
487
|
-
modules[moduleId].call(module2.exports, module2, module2.exports, __webpack_require__);
|
|
488
|
-
module2.loaded = true;
|
|
489
|
-
return module2.exports;
|
|
490
|
-
}
|
|
491
|
-
__webpack_require__.m = modules;
|
|
492
|
-
__webpack_require__.c = installedModules;
|
|
493
|
-
__webpack_require__.p = "";
|
|
494
|
-
return __webpack_require__(0);
|
|
495
|
-
})([
|
|
496
|
-
/* 0 */
|
|
497
|
-
/***/
|
|
498
|
-
(function(module2, exports2, __webpack_require__) {
|
|
499
|
-
module2.exports = __webpack_require__(1);
|
|
500
|
-
}),
|
|
501
|
-
/* 1 */
|
|
502
|
-
/***/
|
|
503
|
-
(function(module2, exports2, __webpack_require__) {
|
|
504
|
-
"use strict";
|
|
505
|
-
Object.defineProperty(exports2, "__esModule", {
|
|
506
|
-
value: true
|
|
507
|
-
});
|
|
508
|
-
var _utils = __webpack_require__(2);
|
|
509
|
-
Object.defineProperty(exports2, "combineChunks", {
|
|
510
|
-
enumerable: true,
|
|
511
|
-
get: function get() {
|
|
512
|
-
return _utils.combineChunks;
|
|
513
|
-
}
|
|
514
|
-
});
|
|
515
|
-
Object.defineProperty(exports2, "fillInChunks", {
|
|
516
|
-
enumerable: true,
|
|
517
|
-
get: function get() {
|
|
518
|
-
return _utils.fillInChunks;
|
|
519
|
-
}
|
|
520
|
-
});
|
|
521
|
-
Object.defineProperty(exports2, "findAll", {
|
|
522
|
-
enumerable: true,
|
|
523
|
-
get: function get() {
|
|
524
|
-
return _utils.findAll;
|
|
525
|
-
}
|
|
526
|
-
});
|
|
527
|
-
Object.defineProperty(exports2, "findChunks", {
|
|
528
|
-
enumerable: true,
|
|
529
|
-
get: function get() {
|
|
530
|
-
return _utils.findChunks;
|
|
531
|
-
}
|
|
532
|
-
});
|
|
533
|
-
}),
|
|
534
|
-
/* 2 */
|
|
535
|
-
/***/
|
|
536
|
-
(function(module2, exports2) {
|
|
537
|
-
"use strict";
|
|
538
|
-
Object.defineProperty(exports2, "__esModule", {
|
|
539
|
-
value: true
|
|
540
|
-
});
|
|
541
|
-
var findAll2 = exports2.findAll = function findAll3(_ref2) {
|
|
542
|
-
var autoEscape = _ref2.autoEscape, _ref$caseSensitive = _ref2.caseSensitive, caseSensitive = _ref$caseSensitive === void 0 ? false : _ref$caseSensitive, _ref$findChunks = _ref2.findChunks, findChunks = _ref$findChunks === void 0 ? defaultFindChunks : _ref$findChunks, sanitize = _ref2.sanitize, searchWords = _ref2.searchWords, textToHighlight = _ref2.textToHighlight;
|
|
543
|
-
return fillInChunks({
|
|
544
|
-
chunksToHighlight: combineChunks({
|
|
545
|
-
chunks: findChunks({
|
|
546
|
-
autoEscape,
|
|
547
|
-
caseSensitive,
|
|
548
|
-
sanitize,
|
|
549
|
-
searchWords,
|
|
550
|
-
textToHighlight
|
|
551
|
-
})
|
|
552
|
-
}),
|
|
553
|
-
totalLength: textToHighlight ? textToHighlight.length : 0
|
|
554
|
-
});
|
|
555
|
-
};
|
|
556
|
-
var combineChunks = exports2.combineChunks = function combineChunks2(_ref2) {
|
|
557
|
-
var chunks = _ref2.chunks;
|
|
558
|
-
chunks = chunks.sort(function(first, second) {
|
|
559
|
-
return first.start - second.start;
|
|
560
|
-
}).reduce(function(processedChunks, nextChunk) {
|
|
561
|
-
if (processedChunks.length === 0) {
|
|
562
|
-
return [nextChunk];
|
|
563
|
-
} else {
|
|
564
|
-
var prevChunk = processedChunks.pop();
|
|
565
|
-
if (nextChunk.start < prevChunk.end) {
|
|
566
|
-
var endIndex = Math.max(prevChunk.end, nextChunk.end);
|
|
567
|
-
processedChunks.push({ highlight: false, start: prevChunk.start, end: endIndex });
|
|
568
|
-
} else {
|
|
569
|
-
processedChunks.push(prevChunk, nextChunk);
|
|
570
|
-
}
|
|
571
|
-
return processedChunks;
|
|
572
|
-
}
|
|
573
|
-
}, []);
|
|
574
|
-
return chunks;
|
|
575
|
-
};
|
|
576
|
-
var defaultFindChunks = function defaultFindChunks2(_ref3) {
|
|
577
|
-
var autoEscape = _ref3.autoEscape, caseSensitive = _ref3.caseSensitive, _ref3$sanitize = _ref3.sanitize, sanitize = _ref3$sanitize === void 0 ? defaultSanitize : _ref3$sanitize, searchWords = _ref3.searchWords, textToHighlight = _ref3.textToHighlight;
|
|
578
|
-
textToHighlight = sanitize(textToHighlight);
|
|
579
|
-
return searchWords.filter(function(searchWord) {
|
|
580
|
-
return searchWord;
|
|
581
|
-
}).reduce(function(chunks, searchWord) {
|
|
582
|
-
searchWord = sanitize(searchWord);
|
|
583
|
-
if (autoEscape) {
|
|
584
|
-
searchWord = escapeRegExpFn(searchWord);
|
|
585
|
-
}
|
|
586
|
-
var regex = new RegExp(searchWord, caseSensitive ? "g" : "gi");
|
|
587
|
-
var match2 = void 0;
|
|
588
|
-
while (match2 = regex.exec(textToHighlight)) {
|
|
589
|
-
var _start = match2.index;
|
|
590
|
-
var _end = regex.lastIndex;
|
|
591
|
-
if (_end > _start) {
|
|
592
|
-
chunks.push({ highlight: false, start: _start, end: _end });
|
|
593
|
-
}
|
|
594
|
-
if (match2.index === regex.lastIndex) {
|
|
595
|
-
regex.lastIndex++;
|
|
596
|
-
}
|
|
597
|
-
}
|
|
598
|
-
return chunks;
|
|
599
|
-
}, []);
|
|
600
|
-
};
|
|
601
|
-
exports2.findChunks = defaultFindChunks;
|
|
602
|
-
var fillInChunks = exports2.fillInChunks = function fillInChunks2(_ref4) {
|
|
603
|
-
var chunksToHighlight = _ref4.chunksToHighlight, totalLength = _ref4.totalLength;
|
|
604
|
-
var allChunks = [];
|
|
605
|
-
var append2 = function append3(start, end, highlight) {
|
|
606
|
-
if (end - start > 0) {
|
|
607
|
-
allChunks.push({
|
|
608
|
-
start,
|
|
609
|
-
end,
|
|
610
|
-
highlight
|
|
611
|
-
});
|
|
612
|
-
}
|
|
613
|
-
};
|
|
614
|
-
if (chunksToHighlight.length === 0) {
|
|
615
|
-
append2(0, totalLength, false);
|
|
616
|
-
} else {
|
|
617
|
-
var lastIndex = 0;
|
|
618
|
-
chunksToHighlight.forEach(function(chunk) {
|
|
619
|
-
append2(lastIndex, chunk.start, false);
|
|
620
|
-
append2(chunk.start, chunk.end, true);
|
|
621
|
-
lastIndex = chunk.end;
|
|
622
|
-
});
|
|
623
|
-
append2(lastIndex, totalLength, false);
|
|
624
|
-
}
|
|
625
|
-
return allChunks;
|
|
626
|
-
};
|
|
627
|
-
function defaultSanitize(string) {
|
|
628
|
-
return string;
|
|
629
|
-
}
|
|
630
|
-
function escapeRegExpFn(string) {
|
|
631
|
-
return string.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g, "\\$&");
|
|
632
|
-
}
|
|
633
|
-
})
|
|
634
|
-
/******/
|
|
635
|
-
]);
|
|
636
|
-
}
|
|
637
|
-
});
|
|
638
|
-
|
|
639
468
|
// src/charts/bar-chart/bar-chart.tsx
|
|
640
469
|
var _numberformatters = require('@automattic/number-formatters');
|
|
641
470
|
var _pattern = require('@visx/pattern');
|
|
@@ -979,8 +808,8 @@ var parseHslString = (hslString) => {
|
|
|
979
808
|
if (isNaN(parsed.h) && isNaN(parsed.s) && isNaN(parsed.l)) {
|
|
980
809
|
return null;
|
|
981
810
|
}
|
|
982
|
-
const
|
|
983
|
-
return [
|
|
811
|
+
const h = isNaN(parsed.h) ? 0 : (parsed.h % 360 + 360) % 360;
|
|
812
|
+
return [h, parsed.s * 100, parsed.l * 100];
|
|
984
813
|
};
|
|
985
814
|
var parseRgbString = (rgbString) => {
|
|
986
815
|
const lower = rgbString.toLowerCase().trim();
|
|
@@ -1002,10 +831,10 @@ var normalizeColorToHex = (color, element, resolveCss, _depth = 0) => {
|
|
|
1002
831
|
}
|
|
1003
832
|
const trimmed = color.trim().toLowerCase();
|
|
1004
833
|
if (/^#[0-9a-f]{3}$/i.test(trimmed)) {
|
|
1005
|
-
const
|
|
1006
|
-
const
|
|
1007
|
-
const
|
|
1008
|
-
return `#${
|
|
834
|
+
const r = trimmed[1];
|
|
835
|
+
const g = trimmed[2];
|
|
836
|
+
const b = trimmed[3];
|
|
837
|
+
return `#${r}${r}${g}${g}${b}${b}`;
|
|
1009
838
|
}
|
|
1010
839
|
if (trimmed.startsWith("--") || trimmed.startsWith("var(")) {
|
|
1011
840
|
if (resolveCss) {
|
|
@@ -1031,12 +860,12 @@ var normalizeColorToHex = (color, element, resolveCss, _depth = 0) => {
|
|
|
1031
860
|
};
|
|
1032
861
|
var lightenHexColor = (hex, blend) => {
|
|
1033
862
|
validateHexColor(hex);
|
|
1034
|
-
const
|
|
1035
|
-
const
|
|
1036
|
-
const
|
|
1037
|
-
const newR = Math.round(
|
|
1038
|
-
const newG = Math.round(
|
|
1039
|
-
const newB = Math.round(
|
|
863
|
+
const r = parseInt(hex.slice(1, 3), 16);
|
|
864
|
+
const g = parseInt(hex.slice(3, 5), 16);
|
|
865
|
+
const b = parseInt(hex.slice(5, 7), 16);
|
|
866
|
+
const newR = Math.round(r + (255 - r) * blend);
|
|
867
|
+
const newG = Math.round(g + (255 - g) * blend);
|
|
868
|
+
const newB = Math.round(b + (255 - b) * blend);
|
|
1040
869
|
return `#${newR.toString(16).padStart(2, "0")}${newG.toString(16).padStart(2, "0")}${newB.toString(16).padStart(2, "0")}`;
|
|
1041
870
|
};
|
|
1042
871
|
|
|
@@ -1086,11 +915,27 @@ function resolveVariableName(varName, element) {
|
|
|
1086
915
|
const targetElement = element || document.documentElement;
|
|
1087
916
|
const computedValue = getComputedStyle(targetElement).getPropertyValue(varName).trim();
|
|
1088
917
|
return computedValue || null;
|
|
1089
|
-
} catch (
|
|
918
|
+
} catch (e2) {
|
|
1090
919
|
return null;
|
|
1091
920
|
}
|
|
1092
921
|
}
|
|
1093
922
|
|
|
923
|
+
// src/utils/resolve-font-size.ts
|
|
924
|
+
var resolveFontSize = (val) => {
|
|
925
|
+
if (typeof val === "number") {
|
|
926
|
+
return isNaN(val) ? void 0 : val;
|
|
927
|
+
}
|
|
928
|
+
if (typeof val === "string") {
|
|
929
|
+
const match2 = val.trim().match(/^(-?\d+\.?\d*|-?\.\d+)(px)?$/);
|
|
930
|
+
if (!match2) {
|
|
931
|
+
return void 0;
|
|
932
|
+
}
|
|
933
|
+
const parsed = parseFloat(match2[1]);
|
|
934
|
+
return isNaN(parsed) ? void 0 : parsed;
|
|
935
|
+
}
|
|
936
|
+
return void 0;
|
|
937
|
+
};
|
|
938
|
+
|
|
1094
939
|
// src/providers/chart-context/private/get-chart-color.ts
|
|
1095
940
|
|
|
1096
941
|
var GOLDEN_RATIO = 0.618033988749;
|
|
@@ -1128,8 +973,8 @@ var getChartColor = (index, colorCache) => {
|
|
|
1128
973
|
if (hues.length === 1) {
|
|
1129
974
|
hueRange = FULL_HUE_ROTATION_DEGREES * SINGLE_COLOR_HUE_RANGE_FACTOR;
|
|
1130
975
|
} else if (hueRange > HUE_WRAP_THRESHOLD_DEGREES) {
|
|
1131
|
-
const altMinHue = Math.min(...hues.filter((
|
|
1132
|
-
const altMaxHue = Math.max(...hues.filter((
|
|
976
|
+
const altMinHue = Math.min(...hues.filter((h) => h > HUE_WRAP_THRESHOLD_DEGREES));
|
|
977
|
+
const altMaxHue = Math.max(...hues.filter((h) => h < HUE_WRAP_THRESHOLD_DEGREES)) + FULL_HUE_ROTATION_DEGREES;
|
|
1133
978
|
const altRange = altMaxHue - altMinHue;
|
|
1134
979
|
if (altRange < hueRange) {
|
|
1135
980
|
minHue = altMinHue;
|
|
@@ -1197,7 +1042,13 @@ var defaultTheme = {
|
|
|
1197
1042
|
},
|
|
1198
1043
|
seriesLineStyles: [],
|
|
1199
1044
|
glyphs: [],
|
|
1200
|
-
|
|
1045
|
+
// `fontFamily: 'inherit'` overrides visx's hardcoded default font stack
|
|
1046
|
+
// (`-apple-system,BlinkMacSystemFont,Roboto,Helvetica Neue,sans-serif`)
|
|
1047
|
+
// that `buildChartTheme` injects as an inline style on SVG `<text>`
|
|
1048
|
+
// elements for axis labels and ticks. Setting `inherit` lets SVG text
|
|
1049
|
+
// pick up the host application's font-family via normal CSS inheritance.
|
|
1050
|
+
svgLabelSmall: { fill: "var(--jp-gray-80, #2c3338)", fontFamily: "inherit" },
|
|
1051
|
+
svgLabelBig: { fontFamily: "inherit" },
|
|
1201
1052
|
annotationStyles: {
|
|
1202
1053
|
label: {
|
|
1203
1054
|
anchorLineStroke: "var(--jp-gray-80, #2c3338)",
|
|
@@ -1263,7 +1114,9 @@ var GlobalChartsProvider = ({
|
|
|
1263
1114
|
minHue: 360,
|
|
1264
1115
|
maxHue: 0
|
|
1265
1116
|
}));
|
|
1117
|
+
const [isColorPaletteResolved, setIsColorPaletteResolved] = _react.useState.call(void 0, false);
|
|
1266
1118
|
_react.useLayoutEffect.call(void 0, () => {
|
|
1119
|
+
setIsColorPaletteResolved(false);
|
|
1267
1120
|
const {
|
|
1268
1121
|
colors
|
|
1269
1122
|
} = providerTheme;
|
|
@@ -1298,6 +1151,11 @@ var GlobalChartsProvider = ({
|
|
|
1298
1151
|
maxHue
|
|
1299
1152
|
});
|
|
1300
1153
|
}, [providerTheme]);
|
|
1154
|
+
_react.useEffect.call(void 0, () => {
|
|
1155
|
+
if (colorCache.colors.length > 0) {
|
|
1156
|
+
setIsColorPaletteResolved(true);
|
|
1157
|
+
}
|
|
1158
|
+
}, [colorCache]);
|
|
1301
1159
|
const [groupToColorMap, setGroupToColorMap] = _react.useState.call(void 0, () => /* @__PURE__ */ new Map());
|
|
1302
1160
|
_react.useEffect.call(void 0, () => {
|
|
1303
1161
|
setGroupToColorMap(/* @__PURE__ */ new Map());
|
|
@@ -1377,8 +1235,8 @@ var GlobalChartsProvider = ({
|
|
|
1377
1235
|
return !chartHidden || !chartHidden.has(seriesLabel);
|
|
1378
1236
|
}, [hiddenSeries]);
|
|
1379
1237
|
const getHiddenSeries = _react.useCallback.call(void 0, (chartId) => {
|
|
1380
|
-
const
|
|
1381
|
-
return
|
|
1238
|
+
const set2 = hiddenSeries.get(chartId);
|
|
1239
|
+
return set2 ? new Set(set2) : /* @__PURE__ */ new Set();
|
|
1382
1240
|
}, [hiddenSeries]);
|
|
1383
1241
|
const value = _react.useMemo.call(void 0, () => ({
|
|
1384
1242
|
charts,
|
|
@@ -1389,8 +1247,9 @@ var GlobalChartsProvider = ({
|
|
|
1389
1247
|
getElementStyles,
|
|
1390
1248
|
toggleSeriesVisibility,
|
|
1391
1249
|
isSeriesVisible,
|
|
1392
|
-
getHiddenSeries
|
|
1393
|
-
|
|
1250
|
+
getHiddenSeries,
|
|
1251
|
+
isColorPaletteResolved
|
|
1252
|
+
}), [charts, registerChart, unregisterChart, getChartData, providerTheme, getElementStyles, toggleSeriesVisibility, isSeriesVisible, getHiddenSeries, isColorPaletteResolved]);
|
|
1394
1253
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, GlobalChartsContext.Provider, {
|
|
1395
1254
|
value,
|
|
1396
1255
|
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", {
|
|
@@ -1424,7 +1283,7 @@ var useChartId = (providedId) => {
|
|
|
1424
1283
|
|
|
1425
1284
|
|
|
1426
1285
|
// src/hooks/use-deep-memo.ts
|
|
1427
|
-
var import_fast_deep_equal =
|
|
1286
|
+
var import_fast_deep_equal = _chunkDZUJEN5Ncjs.__toESM.call(void 0, require_fast_deep_equal(), 1);
|
|
1428
1287
|
|
|
1429
1288
|
var useDeepMemo = (value) => {
|
|
1430
1289
|
const ref = _react.useRef.call(void 0, value);
|
|
@@ -1470,9 +1329,9 @@ var useChartDataTransform = (data) => {
|
|
|
1470
1329
|
...point,
|
|
1471
1330
|
date
|
|
1472
1331
|
};
|
|
1473
|
-
}).sort((
|
|
1474
|
-
if (!
|
|
1475
|
-
return
|
|
1332
|
+
}).sort((a, b) => {
|
|
1333
|
+
if (!a.date || !b.date) return 0;
|
|
1334
|
+
return a.date.getTime() - b.date.getTime();
|
|
1476
1335
|
})
|
|
1477
1336
|
}));
|
|
1478
1337
|
}, [data]);
|
|
@@ -1489,16 +1348,6 @@ var DEFAULT_BOTTOM_FOR_TOP_AXIS = 10;
|
|
|
1489
1348
|
var DEFAULT_FONT_SIZE = 12;
|
|
1490
1349
|
var DEFAULT_TICK_LENGTH = 8;
|
|
1491
1350
|
var DEFAULT_Y_TICK_WIDTH = 40;
|
|
1492
|
-
var resolveFontSize = (val) => {
|
|
1493
|
-
if (typeof val === "number" && !isNaN(val)) {
|
|
1494
|
-
return val;
|
|
1495
|
-
}
|
|
1496
|
-
if (typeof val === "string") {
|
|
1497
|
-
const parsed = parseFloat(val);
|
|
1498
|
-
return isNaN(parsed) ? void 0 : parsed;
|
|
1499
|
-
}
|
|
1500
|
-
return void 0;
|
|
1501
|
-
};
|
|
1502
1351
|
var getXAxisLabelMetrics = (theme, orientation) => {
|
|
1503
1352
|
const xAxisStyles = orientation === "top" ? _optionalChain([theme, 'access', _31 => _31.axisStyles, 'optionalAccess', _32 => _32.x, 'optionalAccess', _33 => _33.top]) : _optionalChain([theme, 'access', _34 => _34.axisStyles, 'optionalAccess', _35 => _35.x, 'optionalAccess', _36 => _36.bottom]);
|
|
1504
1353
|
const fontSize = resolveFontSize(_optionalChain([xAxisStyles, 'optionalAccess', _37 => _37.axisLabel, 'optionalAccess', _38 => _38.fontSize])) || resolveFontSize(_optionalChain([theme, 'access', _39 => _39.svgLabelSmall, 'optionalAccess', _40 => _40.fontSize])) || DEFAULT_FONT_SIZE;
|
|
@@ -1512,10 +1361,10 @@ var useChartMargin = (height, options, data, theme, horizontal = false) => {
|
|
|
1512
1361
|
const yTicks = _react.useMemo.call(void 0, () => {
|
|
1513
1362
|
const allDataPoints = data.flatMap((series) => series.data);
|
|
1514
1363
|
if (horizontal) {
|
|
1515
|
-
return allDataPoints.map((
|
|
1364
|
+
return allDataPoints.map((d) => d.label || _optionalChain([options, 'access', _42 => _42.axis, 'optionalAccess', _43 => _43.y, 'optionalAccess', _44 => _44.tickFormat, 'call', _45 => _45(d.date.getTime(), 0, [])]));
|
|
1516
1365
|
}
|
|
1517
|
-
const minY = Math.min(...allDataPoints.map((
|
|
1518
|
-
const maxY = Math.max(...allDataPoints.map((
|
|
1366
|
+
const minY = Math.min(...allDataPoints.map((d) => d.value));
|
|
1367
|
+
const maxY = Math.max(...allDataPoints.map((d) => d.value));
|
|
1519
1368
|
const yScale = _scale.createScale.call(void 0, {
|
|
1520
1369
|
...options.yScale,
|
|
1521
1370
|
domain: [minY, maxY],
|
|
@@ -1704,7 +1553,7 @@ var useInteractiveLegendData = ({
|
|
|
1704
1553
|
if (!legendInteractive || !chartId) {
|
|
1705
1554
|
return data;
|
|
1706
1555
|
}
|
|
1707
|
-
const visibleDataMap = new Map(visibleData.map((
|
|
1556
|
+
const visibleDataMap = new Map(visibleData.map((d) => [d.label, d]));
|
|
1708
1557
|
return data.map((segment) => {
|
|
1709
1558
|
const isVisible = isSeriesVisible(chartId, segment.label);
|
|
1710
1559
|
if (!isVisible) {
|
|
@@ -1798,11 +1647,11 @@ function labelTransformFactory({
|
|
|
1798
1647
|
scale,
|
|
1799
1648
|
labelFormat
|
|
1800
1649
|
}) {
|
|
1801
|
-
return (
|
|
1802
|
-
datum:
|
|
1803
|
-
index:
|
|
1804
|
-
text: `${labelFormat(
|
|
1805
|
-
value: scale(
|
|
1650
|
+
return (d, i) => ({
|
|
1651
|
+
datum: d,
|
|
1652
|
+
index: i,
|
|
1653
|
+
text: `${labelFormat(d, i)}`,
|
|
1654
|
+
value: scale(d)
|
|
1806
1655
|
});
|
|
1807
1656
|
}
|
|
1808
1657
|
|
|
@@ -1934,11 +1783,11 @@ var BaseLegend = /* @__PURE__ */ _react.forwardRef.call(void 0, ({
|
|
|
1934
1783
|
flexDirection: orientationToFlexDirection[orientation],
|
|
1935
1784
|
..._optionalChain([theme, 'access', _62 => _62.legend, 'optionalAccess', _63 => _63.containerStyles])
|
|
1936
1785
|
},
|
|
1937
|
-
children: labels.map((label,
|
|
1786
|
+
children: labels.map((label, i) => {
|
|
1938
1787
|
const visible = isSeriesVisible(label.text);
|
|
1939
1788
|
const handleClick = createClickHandler(label.text);
|
|
1940
1789
|
const handleKeyDown = createKeyDownHandler(label.text);
|
|
1941
|
-
const matchedItem = items[
|
|
1790
|
+
const matchedItem = items[i];
|
|
1942
1791
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _legend.LegendItem, {
|
|
1943
1792
|
className: _clsx2.default.call(void 0, "visx-legend-item", base_legend_module_default["legend-item"], interactive && base_legend_module_default["legend-item--interactive"], !visible && base_legend_module_default["legend-item--inactive"], itemClassName),
|
|
1944
1793
|
margin: itemMargin,
|
|
@@ -1949,18 +1798,18 @@ var BaseLegend = /* @__PURE__ */ _react.forwardRef.call(void 0, ({
|
|
|
1949
1798
|
tabIndex: interactive ? 0 : void 0,
|
|
1950
1799
|
"aria-pressed": interactive ? visible : void 0,
|
|
1951
1800
|
"aria-label": interactive ? `${label.text}: ${visible ? "visible" : "hidden"}. Toggle visibility.` : void 0,
|
|
1952
|
-
children: [_optionalChain([items, 'access', _64 => _64[
|
|
1953
|
-
width: _optionalChain([items, 'access', _66 => _66[
|
|
1954
|
-
height: _optionalChain([items, 'access', _68 => _68[
|
|
1801
|
+
children: [_optionalChain([items, 'access', _64 => _64[i], 'optionalAccess', _65 => _65.renderGlyph]) ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "svg", {
|
|
1802
|
+
width: _optionalChain([items, 'access', _66 => _66[i], 'optionalAccess', _67 => _67.glyphSize]) * 2,
|
|
1803
|
+
height: _optionalChain([items, 'access', _68 => _68[i], 'optionalAccess', _69 => _69.glyphSize]) * 2,
|
|
1955
1804
|
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _group.Group, {
|
|
1956
|
-
children: _optionalChain([items, 'access', _70 => _70[
|
|
1805
|
+
children: _optionalChain([items, 'access', _70 => _70[i], 'optionalAccess', _71 => _71.renderGlyph, 'call', _72 => _72({
|
|
1957
1806
|
key: `legend-glyph-${label.text}`,
|
|
1958
1807
|
datum: {},
|
|
1959
|
-
index:
|
|
1808
|
+
index: i,
|
|
1960
1809
|
color: fill(label),
|
|
1961
|
-
size: _optionalChain([items, 'access', _73 => _73[
|
|
1962
|
-
x: _optionalChain([items, 'access', _75 => _75[
|
|
1963
|
-
y: _optionalChain([items, 'access', _77 => _77[
|
|
1810
|
+
size: _optionalChain([items, 'access', _73 => _73[i], 'optionalAccess', _74 => _74.glyphSize]),
|
|
1811
|
+
x: _optionalChain([items, 'access', _75 => _75[i], 'optionalAccess', _76 => _76.glyphSize]),
|
|
1812
|
+
y: _optionalChain([items, 'access', _77 => _77[i], 'optionalAccess', _78 => _78.glyphSize])
|
|
1964
1813
|
})])
|
|
1965
1814
|
})
|
|
1966
1815
|
}) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _legend.LegendShape, {
|
|
@@ -1968,8 +1817,8 @@ var BaseLegend = /* @__PURE__ */ _react.forwardRef.call(void 0, ({
|
|
|
1968
1817
|
height: shapeHeight,
|
|
1969
1818
|
width: shapeWidth,
|
|
1970
1819
|
margin: shapeMargin,
|
|
1971
|
-
item: domain[
|
|
1972
|
-
itemIndex:
|
|
1820
|
+
item: domain[i],
|
|
1821
|
+
itemIndex: i,
|
|
1973
1822
|
label,
|
|
1974
1823
|
fill,
|
|
1975
1824
|
size,
|
|
@@ -1991,7 +1840,7 @@ var BaseLegend = /* @__PURE__ */ _react.forwardRef.call(void 0, ({
|
|
|
1991
1840
|
children: ["\xA0", matchedItem.value]
|
|
1992
1841
|
})]
|
|
1993
1842
|
})]
|
|
1994
|
-
}, `legend-${label.text}-${
|
|
1843
|
+
}, `legend-${label.text}-${i}`);
|
|
1995
1844
|
})
|
|
1996
1845
|
})
|
|
1997
1846
|
});
|
|
@@ -2209,7 +2058,7 @@ var AccessibleTooltip = ({
|
|
|
2209
2058
|
const tooltipData = _react.useMemo.call(void 0, () => {
|
|
2210
2059
|
if (mode !== "individual") return [];
|
|
2211
2060
|
if (series.length === 0) return [];
|
|
2212
|
-
const maxDataPoints = Math.max(...series.map((
|
|
2061
|
+
const maxDataPoints = Math.max(...series.map((s) => s.data.length));
|
|
2213
2062
|
const flattened = [];
|
|
2214
2063
|
for (let dataPointIndex = 0; dataPointIndex < maxDataPoints; dataPointIndex++) {
|
|
2215
2064
|
for (let seriesIndex = 0; seriesIndex < series.length; seriesIndex++) {
|
|
@@ -2232,12 +2081,12 @@ var AccessibleTooltip = ({
|
|
|
2232
2081
|
return;
|
|
2233
2082
|
}
|
|
2234
2083
|
if (mode === "group") {
|
|
2235
|
-
series.forEach((
|
|
2236
|
-
if (selectedIndex <
|
|
2237
|
-
const datum =
|
|
2084
|
+
series.forEach((s, index) => {
|
|
2085
|
+
if (selectedIndex < s.data.length) {
|
|
2086
|
+
const datum = s.data[selectedIndex];
|
|
2238
2087
|
_optionalChain([tooltipContext, 'optionalAccess', _94 => _94.showTooltip, 'call', _95 => _95({
|
|
2239
2088
|
datum,
|
|
2240
|
-
key:
|
|
2089
|
+
key: s.label,
|
|
2241
2090
|
index
|
|
2242
2091
|
})]);
|
|
2243
2092
|
}
|
|
@@ -2361,8 +2210,8 @@ ChartHTML.displayName = "Chart.HTML";
|
|
|
2361
2210
|
// src/charts/private/chart-composition/render-legend-slot.ts
|
|
2362
2211
|
|
|
2363
2212
|
function renderLegendSlot(legendChildren, position2) {
|
|
2364
|
-
return legendChildren.filter((
|
|
2365
|
-
(
|
|
2213
|
+
return legendChildren.filter((l) => l.position === position2).map(
|
|
2214
|
+
(l, i) => _react.createElement.call(void 0, _react.Fragment, { key: `legend-${position2}-${i}` }, l.element)
|
|
2366
2215
|
);
|
|
2367
2216
|
}
|
|
2368
2217
|
|
|
@@ -2416,7 +2265,7 @@ function useChartChildren(children, chartType) {
|
|
|
2416
2265
|
}, [children, chartType]);
|
|
2417
2266
|
}
|
|
2418
2267
|
|
|
2419
|
-
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.
|
|
2268
|
+
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.6_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/esm/useRefWithInit.js
|
|
2420
2269
|
|
|
2421
2270
|
var UNINITIALIZED = {};
|
|
2422
2271
|
function useRefWithInit(init, initArg) {
|
|
@@ -2427,22 +2276,41 @@ function useRefWithInit(init, initArg) {
|
|
|
2427
2276
|
return ref;
|
|
2428
2277
|
}
|
|
2429
2278
|
|
|
2430
|
-
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.
|
|
2431
|
-
|
|
2432
|
-
|
|
2433
|
-
|
|
2434
|
-
args.forEach((arg) => url.searchParams.append("args[]", arg));
|
|
2435
|
-
return `Base UI error #${code}; visit ${url} for the full message.`;
|
|
2279
|
+
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.6_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/esm/warn.js
|
|
2280
|
+
var set;
|
|
2281
|
+
if (process.env.NODE_ENV !== "production") {
|
|
2282
|
+
set = /* @__PURE__ */ new Set();
|
|
2436
2283
|
}
|
|
2284
|
+
function warn(...messages) {
|
|
2285
|
+
if (process.env.NODE_ENV !== "production") {
|
|
2286
|
+
const messageKey = messages.join(" ");
|
|
2287
|
+
if (!set.has(messageKey)) {
|
|
2288
|
+
set.add(messageKey);
|
|
2289
|
+
console.warn(`Base UI: ${messageKey}`);
|
|
2290
|
+
}
|
|
2291
|
+
}
|
|
2292
|
+
}
|
|
2293
|
+
|
|
2294
|
+
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.6_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/esm/formatErrorMessage.js
|
|
2295
|
+
function createFormatErrorMessage(baseUrl, prefix2) {
|
|
2296
|
+
return function formatErrorMessage2(code, ...args) {
|
|
2297
|
+
const url = new URL(baseUrl);
|
|
2298
|
+
url.searchParams.set("code", code.toString());
|
|
2299
|
+
args.forEach((arg) => url.searchParams.append("args[]", arg));
|
|
2300
|
+
return `${prefix2} error #${code}; visit ${url} for the full message.`;
|
|
2301
|
+
};
|
|
2302
|
+
}
|
|
2303
|
+
var formatErrorMessage = createFormatErrorMessage("https://base-ui.com/production-error", "Base UI");
|
|
2304
|
+
var formatErrorMessage_default = formatErrorMessage;
|
|
2437
2305
|
|
|
2438
|
-
// ../../../node_modules/.pnpm/@base-ui+react@1.
|
|
2306
|
+
// ../../../node_modules/.pnpm/@base-ui+react@1.3.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/esm/utils/useRenderElement.js
|
|
2439
2307
|
|
|
2440
2308
|
|
|
2441
|
-
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.
|
|
2442
|
-
function useMergedRefs(
|
|
2309
|
+
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.6_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/esm/useMergedRefs.js
|
|
2310
|
+
function useMergedRefs(a, b, c, d) {
|
|
2443
2311
|
const forkRef = useRefWithInit(createForkRef).current;
|
|
2444
|
-
if (didChange(forkRef,
|
|
2445
|
-
update(forkRef, [
|
|
2312
|
+
if (didChange(forkRef, a, b, c, d)) {
|
|
2313
|
+
update(forkRef, [a, b, c, d]);
|
|
2446
2314
|
}
|
|
2447
2315
|
return forkRef.callback;
|
|
2448
2316
|
}
|
|
@@ -2460,8 +2328,8 @@ function createForkRef() {
|
|
|
2460
2328
|
refs: []
|
|
2461
2329
|
};
|
|
2462
2330
|
}
|
|
2463
|
-
function didChange(forkRef,
|
|
2464
|
-
return forkRef.refs[0] !==
|
|
2331
|
+
function didChange(forkRef, a, b, c, d) {
|
|
2332
|
+
return forkRef.refs[0] !== a || forkRef.refs[1] !== b || forkRef.refs[2] !== c || forkRef.refs[3] !== d;
|
|
2465
2333
|
}
|
|
2466
2334
|
function didChangeN(forkRef, newRefs) {
|
|
2467
2335
|
return forkRef.refs.length !== newRefs.length || forkRef.refs.some((ref, index) => ref !== newRefs[index]);
|
|
@@ -2479,8 +2347,8 @@ function update(forkRef, refs) {
|
|
|
2479
2347
|
}
|
|
2480
2348
|
if (instance != null) {
|
|
2481
2349
|
const cleanupCallbacks = Array(refs.length).fill(null);
|
|
2482
|
-
for (let
|
|
2483
|
-
const ref = refs[
|
|
2350
|
+
for (let i = 0; i < refs.length; i += 1) {
|
|
2351
|
+
const ref = refs[i];
|
|
2484
2352
|
if (ref == null) {
|
|
2485
2353
|
continue;
|
|
2486
2354
|
}
|
|
@@ -2488,7 +2356,7 @@ function update(forkRef, refs) {
|
|
|
2488
2356
|
case "function": {
|
|
2489
2357
|
const refCleanup = ref(instance);
|
|
2490
2358
|
if (typeof refCleanup === "function") {
|
|
2491
|
-
cleanupCallbacks[
|
|
2359
|
+
cleanupCallbacks[i] = refCleanup;
|
|
2492
2360
|
}
|
|
2493
2361
|
break;
|
|
2494
2362
|
}
|
|
@@ -2500,14 +2368,14 @@ function update(forkRef, refs) {
|
|
|
2500
2368
|
}
|
|
2501
2369
|
}
|
|
2502
2370
|
forkRef.cleanup = () => {
|
|
2503
|
-
for (let
|
|
2504
|
-
const ref = refs[
|
|
2371
|
+
for (let i = 0; i < refs.length; i += 1) {
|
|
2372
|
+
const ref = refs[i];
|
|
2505
2373
|
if (ref == null) {
|
|
2506
2374
|
continue;
|
|
2507
2375
|
}
|
|
2508
2376
|
switch (typeof ref) {
|
|
2509
2377
|
case "function": {
|
|
2510
|
-
const cleanupCallback = cleanupCallbacks[
|
|
2378
|
+
const cleanupCallback = cleanupCallbacks[i];
|
|
2511
2379
|
if (typeof cleanupCallback === "function") {
|
|
2512
2380
|
cleanupCallback();
|
|
2513
2381
|
} else {
|
|
@@ -2527,17 +2395,17 @@ function update(forkRef, refs) {
|
|
|
2527
2395
|
};
|
|
2528
2396
|
}
|
|
2529
2397
|
|
|
2530
|
-
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.
|
|
2398
|
+
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.6_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/esm/getReactElementRef.js
|
|
2531
2399
|
|
|
2532
2400
|
|
|
2533
|
-
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.
|
|
2401
|
+
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.6_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/esm/reactVersion.js
|
|
2534
2402
|
|
|
2535
2403
|
var majorVersion = parseInt(React2.version, 10);
|
|
2536
2404
|
function isReactVersionAtLeast(reactVersionToCheck) {
|
|
2537
2405
|
return majorVersion >= reactVersionToCheck;
|
|
2538
2406
|
}
|
|
2539
2407
|
|
|
2540
|
-
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.
|
|
2408
|
+
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.6_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/esm/getReactElementRef.js
|
|
2541
2409
|
function getReactElementRef(element) {
|
|
2542
2410
|
if (!/* @__PURE__ */ React3.isValidElement(element)) {
|
|
2543
2411
|
return null;
|
|
@@ -2547,24 +2415,24 @@ function getReactElementRef(element) {
|
|
|
2547
2415
|
return _nullishCoalesce((isReactVersionAtLeast(19) ? _optionalChain([propsWithRef, 'optionalAccess', _114 => _114.ref]) : reactElement.ref), () => ( null));
|
|
2548
2416
|
}
|
|
2549
2417
|
|
|
2550
|
-
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.
|
|
2551
|
-
function mergeObjects(
|
|
2552
|
-
if (
|
|
2553
|
-
return
|
|
2418
|
+
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.6_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/esm/mergeObjects.js
|
|
2419
|
+
function mergeObjects(a, b) {
|
|
2420
|
+
if (a && !b) {
|
|
2421
|
+
return a;
|
|
2554
2422
|
}
|
|
2555
|
-
if (!
|
|
2556
|
-
return
|
|
2423
|
+
if (!a && b) {
|
|
2424
|
+
return b;
|
|
2557
2425
|
}
|
|
2558
|
-
if (
|
|
2426
|
+
if (a || b) {
|
|
2559
2427
|
return {
|
|
2560
|
-
...
|
|
2561
|
-
...
|
|
2428
|
+
...a,
|
|
2429
|
+
...b
|
|
2562
2430
|
};
|
|
2563
2431
|
}
|
|
2564
2432
|
return void 0;
|
|
2565
2433
|
}
|
|
2566
2434
|
|
|
2567
|
-
// ../../../node_modules/.pnpm/@base-ui+react@1.
|
|
2435
|
+
// ../../../node_modules/.pnpm/@base-ui+react@1.3.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/esm/utils/getStateAttributesProps.js
|
|
2568
2436
|
function getStateAttributesProps(state, customMapping) {
|
|
2569
2437
|
const props = {};
|
|
2570
2438
|
for (const key in state) {
|
|
@@ -2585,33 +2453,33 @@ function getStateAttributesProps(state, customMapping) {
|
|
|
2585
2453
|
return props;
|
|
2586
2454
|
}
|
|
2587
2455
|
|
|
2588
|
-
// ../../../node_modules/.pnpm/@base-ui+react@1.
|
|
2456
|
+
// ../../../node_modules/.pnpm/@base-ui+react@1.3.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/esm/utils/resolveClassName.js
|
|
2589
2457
|
function resolveClassName(className, state) {
|
|
2590
2458
|
return typeof className === "function" ? className(state) : className;
|
|
2591
2459
|
}
|
|
2592
2460
|
|
|
2593
|
-
// ../../../node_modules/.pnpm/@base-ui+react@1.
|
|
2461
|
+
// ../../../node_modules/.pnpm/@base-ui+react@1.3.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/esm/utils/resolveStyle.js
|
|
2594
2462
|
function resolveStyle(style, state) {
|
|
2595
2463
|
return typeof style === "function" ? style(state) : style;
|
|
2596
2464
|
}
|
|
2597
2465
|
|
|
2598
|
-
// ../../../node_modules/.pnpm/@base-ui+react@1.
|
|
2466
|
+
// ../../../node_modules/.pnpm/@base-ui+react@1.3.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/esm/merge-props/mergeProps.js
|
|
2599
2467
|
var EMPTY_PROPS = {};
|
|
2600
|
-
function mergeProps(
|
|
2468
|
+
function mergeProps(a, b, c, d, e) {
|
|
2601
2469
|
let merged = {
|
|
2602
|
-
...resolvePropsGetter(
|
|
2470
|
+
...resolvePropsGetter(a, EMPTY_PROPS)
|
|
2603
2471
|
};
|
|
2604
|
-
if (
|
|
2605
|
-
merged = mergeOne(merged,
|
|
2472
|
+
if (b) {
|
|
2473
|
+
merged = mergeOne(merged, b);
|
|
2606
2474
|
}
|
|
2607
|
-
if (
|
|
2608
|
-
merged = mergeOne(merged,
|
|
2475
|
+
if (c) {
|
|
2476
|
+
merged = mergeOne(merged, c);
|
|
2609
2477
|
}
|
|
2610
|
-
if (
|
|
2611
|
-
merged = mergeOne(merged,
|
|
2478
|
+
if (d) {
|
|
2479
|
+
merged = mergeOne(merged, d);
|
|
2612
2480
|
}
|
|
2613
|
-
if (
|
|
2614
|
-
merged = mergeOne(merged,
|
|
2481
|
+
if (e) {
|
|
2482
|
+
merged = mergeOne(merged, e);
|
|
2615
2483
|
}
|
|
2616
2484
|
return merged;
|
|
2617
2485
|
}
|
|
@@ -2625,8 +2493,8 @@ function mergePropsN(props) {
|
|
|
2625
2493
|
let merged = {
|
|
2626
2494
|
...resolvePropsGetter(props[0], EMPTY_PROPS)
|
|
2627
2495
|
};
|
|
2628
|
-
for (let
|
|
2629
|
-
merged = mergeOne(merged, props[
|
|
2496
|
+
for (let i = 1; i < props.length; i += 1) {
|
|
2497
|
+
merged = mergeOne(merged, props[i]);
|
|
2630
2498
|
}
|
|
2631
2499
|
return merged;
|
|
2632
2500
|
}
|
|
@@ -2718,11 +2586,17 @@ function isSyntheticEvent(event) {
|
|
|
2718
2586
|
return event != null && typeof event === "object" && "nativeEvent" in event;
|
|
2719
2587
|
}
|
|
2720
2588
|
|
|
2721
|
-
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.
|
|
2589
|
+
// ../../../node_modules/.pnpm/@base-ui+utils@0.2.6_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/esm/empty.js
|
|
2722
2590
|
var EMPTY_ARRAY = Object.freeze([]);
|
|
2723
2591
|
var EMPTY_OBJECT = Object.freeze({});
|
|
2724
2592
|
|
|
2725
|
-
// ../../../node_modules/.pnpm/@base-ui+react@1.
|
|
2593
|
+
// ../../../node_modules/.pnpm/@base-ui+react@1.3.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/esm/utils/constants.js
|
|
2594
|
+
var BASE_UI_SWIPE_IGNORE_ATTRIBUTE = "data-base-ui-swipe-ignore";
|
|
2595
|
+
var LEGACY_SWIPE_IGNORE_ATTRIBUTE = "data-swipe-ignore";
|
|
2596
|
+
var BASE_UI_SWIPE_IGNORE_SELECTOR = `[${BASE_UI_SWIPE_IGNORE_ATTRIBUTE}]`;
|
|
2597
|
+
var LEGACY_SWIPE_IGNORE_SELECTOR = `[${LEGACY_SWIPE_IGNORE_ATTRIBUTE}]`;
|
|
2598
|
+
|
|
2599
|
+
// ../../../node_modules/.pnpm/@base-ui+react@1.3.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/esm/utils/useRenderElement.js
|
|
2726
2600
|
|
|
2727
2601
|
function useRenderElement(element, componentProps, params = {}) {
|
|
2728
2602
|
const renderProp = componentProps.render;
|
|
@@ -2774,6 +2648,9 @@ var REACT_LAZY_TYPE = /* @__PURE__ */ Symbol.for("react.lazy");
|
|
|
2774
2648
|
function evaluateRenderProp(element, render, props, state) {
|
|
2775
2649
|
if (render) {
|
|
2776
2650
|
if (typeof render === "function") {
|
|
2651
|
+
if (process.env.NODE_ENV !== "production") {
|
|
2652
|
+
warnIfRenderPropLooksLikeComponent(render);
|
|
2653
|
+
}
|
|
2777
2654
|
return render(props, state);
|
|
2778
2655
|
}
|
|
2779
2656
|
const mergedProps = mergeProps(props, render.props);
|
|
@@ -2795,7 +2672,18 @@ function evaluateRenderProp(element, render, props, state) {
|
|
|
2795
2672
|
return renderTag(element, props);
|
|
2796
2673
|
}
|
|
2797
2674
|
}
|
|
2798
|
-
throw new Error(process.env.NODE_ENV !== "production" ? "Base UI: Render element or function are not defined." :
|
|
2675
|
+
throw new Error(process.env.NODE_ENV !== "production" ? "Base UI: Render element or function are not defined." : formatErrorMessage_default(8));
|
|
2676
|
+
}
|
|
2677
|
+
function warnIfRenderPropLooksLikeComponent(renderFn) {
|
|
2678
|
+
const functionName = renderFn.name;
|
|
2679
|
+
if (functionName.length === 0) {
|
|
2680
|
+
return;
|
|
2681
|
+
}
|
|
2682
|
+
const firstCharacterCode = functionName.charCodeAt(0);
|
|
2683
|
+
if (firstCharacterCode < 65 || firstCharacterCode > 90) {
|
|
2684
|
+
return;
|
|
2685
|
+
}
|
|
2686
|
+
warn(`The \`render\` prop received a function named \`${functionName}\` that starts with an uppercase letter.`, "This usually means a React component was passed directly as `render={Component}`.", "Base UI calls `render` as a plain function, which can break the Rules of Hooks during reconciliation.", "If this is an intentional render callback, rename it to start with a lowercase letter.", "Use `render={<Component />}` or `render={(props) => <Component {...props} />}` instead.", "https://base-ui.com/r/invalid-render-prop");
|
|
2799
2687
|
}
|
|
2800
2688
|
function renderTag(Tag, props) {
|
|
2801
2689
|
if (Tag === "button") {
|
|
@@ -2815,12 +2703,12 @@ function renderTag(Tag, props) {
|
|
|
2815
2703
|
return /* @__PURE__ */ React4.createElement(Tag, props);
|
|
2816
2704
|
}
|
|
2817
2705
|
|
|
2818
|
-
// ../../../node_modules/.pnpm/@base-ui+react@1.
|
|
2706
|
+
// ../../../node_modules/.pnpm/@base-ui+react@1.3.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/esm/use-render/useRender.js
|
|
2819
2707
|
function useRender(params) {
|
|
2820
2708
|
return useRenderElement(_nullishCoalesce(params.defaultTagName, () => ( "div")), params, params);
|
|
2821
2709
|
}
|
|
2822
2710
|
|
|
2823
|
-
// ../../../node_modules/.pnpm/@wordpress+element@6.
|
|
2711
|
+
// ../../../node_modules/.pnpm/@wordpress+element@6.43.0/node_modules/@wordpress/element/build-module/react.mjs
|
|
2824
2712
|
|
|
2825
2713
|
|
|
2826
2714
|
|
|
@@ -2855,13 +2743,13 @@ function useRender(params) {
|
|
|
2855
2743
|
|
|
2856
2744
|
|
|
2857
2745
|
// ../../../node_modules/.pnpm/is-plain-object@5.0.0/node_modules/is-plain-object/dist/is-plain-object.mjs
|
|
2858
|
-
function isObject(
|
|
2859
|
-
return Object.prototype.toString.call(
|
|
2746
|
+
function isObject(o) {
|
|
2747
|
+
return Object.prototype.toString.call(o) === "[object Object]";
|
|
2860
2748
|
}
|
|
2861
|
-
function isPlainObject(
|
|
2749
|
+
function isPlainObject(o) {
|
|
2862
2750
|
var ctor, prot;
|
|
2863
|
-
if (isObject(
|
|
2864
|
-
ctor =
|
|
2751
|
+
if (isObject(o) === false) return false;
|
|
2752
|
+
ctor = o.constructor;
|
|
2865
2753
|
if (ctor === void 0) return true;
|
|
2866
2754
|
prot = ctor.prototype;
|
|
2867
2755
|
if (isObject(prot) === false) return false;
|
|
@@ -2952,6 +2840,27 @@ var Stack = _react.forwardRef.call(void 0, function Stack2({ direction, gap, ali
|
|
|
2952
2840
|
return element;
|
|
2953
2841
|
});
|
|
2954
2842
|
|
|
2843
|
+
// ../../../node_modules/.pnpm/@wordpress+ui@0.9.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1_stylelint@17.5.0/node_modules/@wordpress/ui/build-module/text/text.mjs
|
|
2844
|
+
|
|
2845
|
+
if (typeof document !== "undefined" && process.env.NODE_ENV !== "test" && !document.head.querySelector("style[data-wp-hash='893fb81f3c']")) {
|
|
2846
|
+
const style = document.createElement("style");
|
|
2847
|
+
style.setAttribute("data-wp-hash", "893fb81f3c");
|
|
2848
|
+
style.appendChild(document.createTextNode('@layer wp-ui-utilities, wp-ui-components, wp-ui-compositions, wp-ui-overrides;@layer wp-ui-components{._14437cfb77831647__heading-2xl{font-size:var(--wpds-font-size-2xl,32px);line-height:var(--wpds-font-line-height-2xl,40px)}._14437cfb77831647__heading-2xl,._3c78b7fa9b4072dd__heading-xl{font-family:var(--wpds-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-font-weight-medium,499)}._3c78b7fa9b4072dd__heading-xl{font-size:var(--wpds-font-size-xl,20px);line-height:var(--wpds-font-line-height-md,24px)}.aa58f227716bcde2__heading-lg{font-size:var(--wpds-font-size-lg,15px)}.aa58f227716bcde2__heading-lg,.fc4da56d8dfe52c4__heading-md{font-family:var(--wpds-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-font-weight-medium,499);line-height:var(--wpds-font-line-height-sm,20px)}.fc4da56d8dfe52c4__heading-md{font-size:var(--wpds-font-size-md,13px)}.a9b78c7c82e8dff7__heading-sm{font-family:var(--wpds-font-family-heading,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-font-size-xs,11px);font-weight:var(--wpds-font-weight-medium,499);line-height:var(--wpds-font-line-height-xs,16px);text-transform:uppercase}._305ff559e52180d5__body-xl{font-size:var(--wpds-font-size-xl,20px);line-height:var(--wpds-font-line-height-xl,32px)}._305ff559e52180d5__body-xl,.ca1aa3fc2029e958__body-lg{font-family:var(--wpds-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-font-weight-regular,400)}.ca1aa3fc2029e958__body-lg{font-size:var(--wpds-font-size-lg,15px);line-height:var(--wpds-font-line-height-md,24px)}._131101940be12424__body-md{font-size:var(--wpds-font-size-md,13px);line-height:var(--wpds-font-line-height-sm,20px)}._0e8d87a42c1f75fa__body-sm,._131101940be12424__body-md{font-family:var(--wpds-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-weight:var(--wpds-font-weight-regular,400)}._0e8d87a42c1f75fa__body-sm{font-size:var(--wpds-font-size-sm,12px);line-height:var(--wpds-font-line-height-xs,16px)}}'));
|
|
2849
|
+
document.head.appendChild(style);
|
|
2850
|
+
}
|
|
2851
|
+
var style_default2 = { "heading-2xl": "_14437cfb77831647__heading-2xl", "heading-xl": "_3c78b7fa9b4072dd__heading-xl", "heading-lg": "aa58f227716bcde2__heading-lg", "heading-md": "fc4da56d8dfe52c4__heading-md", "heading-sm": "a9b78c7c82e8dff7__heading-sm", "body-xl": "_305ff559e52180d5__body-xl", "body-lg": "ca1aa3fc2029e958__body-lg", "body-md": "_131101940be12424__body-md", "body-sm": "_0e8d87a42c1f75fa__body-sm" };
|
|
2852
|
+
var Text = _react.forwardRef.call(void 0, function Text2({ variant = "body-md", render, className, ...props }, ref) {
|
|
2853
|
+
const element = useRender({
|
|
2854
|
+
render,
|
|
2855
|
+
defaultTagName: "span",
|
|
2856
|
+
ref,
|
|
2857
|
+
props: mergeProps(props, {
|
|
2858
|
+
className: _clsx2.default.call(void 0, style_default2[variant], className)
|
|
2859
|
+
})
|
|
2860
|
+
});
|
|
2861
|
+
return element;
|
|
2862
|
+
});
|
|
2863
|
+
|
|
2955
2864
|
// src/charts/private/chart-layout/chart-layout.tsx
|
|
2956
2865
|
|
|
2957
2866
|
|
|
@@ -3016,15 +2925,15 @@ var svg_empty_state_module_default = {
|
|
|
3016
2925
|
// src/charts/private/svg-empty-state/svg-empty-state.tsx
|
|
3017
2926
|
|
|
3018
2927
|
var SvgEmptyState = ({
|
|
3019
|
-
x
|
|
3020
|
-
y
|
|
2928
|
+
x,
|
|
2929
|
+
y,
|
|
3021
2930
|
width,
|
|
3022
2931
|
height,
|
|
3023
2932
|
children
|
|
3024
2933
|
}) => {
|
|
3025
2934
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "foreignObject", {
|
|
3026
|
-
x:
|
|
3027
|
-
y:
|
|
2935
|
+
x: x - width / 2,
|
|
2936
|
+
y: y - height / 2,
|
|
3028
2937
|
width,
|
|
3029
2938
|
height,
|
|
3030
2939
|
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Stack, {
|
|
@@ -3135,8 +3044,8 @@ var getScaleBandwidth = (scale) => {
|
|
|
3135
3044
|
};
|
|
3136
3045
|
var MIN_TICK_LABEL_WIDTH = 20;
|
|
3137
3046
|
var TruncatedTickComponent = ({
|
|
3138
|
-
x
|
|
3139
|
-
y
|
|
3047
|
+
x,
|
|
3048
|
+
y,
|
|
3140
3049
|
formattedValue,
|
|
3141
3050
|
axis,
|
|
3142
3051
|
textAnchor,
|
|
@@ -3204,8 +3113,8 @@ var TruncatedTickComponent = ({
|
|
|
3204
3113
|
pointerEvents: "auto"
|
|
3205
3114
|
};
|
|
3206
3115
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "foreignObject", {
|
|
3207
|
-
x:
|
|
3208
|
-
y
|
|
3116
|
+
x: x + xOffset,
|
|
3117
|
+
y,
|
|
3209
3118
|
width: maxWidth,
|
|
3210
3119
|
height: 0,
|
|
3211
3120
|
overflow: "visible",
|
|
@@ -3250,10 +3159,10 @@ function useBarChartOptions(data, horizontal, options = {}) {
|
|
|
3250
3159
|
};
|
|
3251
3160
|
const labelFormatter = _optionalChain([data, 'optionalAccess', _120 => _120[0], 'optionalAccess', _121 => _121.data, 'optionalAccess', _122 => _122[0], 'optionalAccess', _123 => _123.label]) ? (label) => label : formatDateTick;
|
|
3252
3161
|
const valueFormatter = _numberformatters.formatNumberCompact;
|
|
3253
|
-
const labelAccessor = (
|
|
3254
|
-
const valueAccessor = (
|
|
3255
|
-
const enhancedPoint =
|
|
3256
|
-
return _optionalChain([enhancedPoint, 'optionalAccess', _126 => _126.visualValue]) !== void 0 ? enhancedPoint.visualValue : _optionalChain([
|
|
3162
|
+
const labelAccessor = (d) => _optionalChain([d, 'optionalAccess', _124 => _124.label]) || _optionalChain([d, 'optionalAccess', _125 => _125.date]);
|
|
3163
|
+
const valueAccessor = (d) => {
|
|
3164
|
+
const enhancedPoint = d;
|
|
3165
|
+
return _optionalChain([enhancedPoint, 'optionalAccess', _126 => _126.visualValue]) !== void 0 ? enhancedPoint.visualValue : _optionalChain([d, 'optionalAccess', _127 => _127.value]);
|
|
3257
3166
|
};
|
|
3258
3167
|
return {
|
|
3259
3168
|
vertical: {
|
|
@@ -3495,7 +3404,7 @@ var BarChartInternal = ({
|
|
|
3495
3404
|
}, [chartId]);
|
|
3496
3405
|
const createKeyboardHighlightStyle = _react.useCallback.call(void 0, () => {
|
|
3497
3406
|
if (selectedIndex === void 0) return "";
|
|
3498
|
-
const maxDataPoints = Math.max(...data.map((
|
|
3407
|
+
const maxDataPoints = Math.max(...data.map((s) => s.data.length));
|
|
3499
3408
|
const dataPointIndex = Math.floor(selectedIndex / data.length);
|
|
3500
3409
|
const seriesIndex = selectedIndex % data.length;
|
|
3501
3410
|
if (dataPointIndex >= maxDataPoints || seriesIndex >= data.length) {
|
|
@@ -3689,36 +3598,36 @@ var BarChartResponsive = attachSubComponents(withResponsive(BarChartWithProvider
|
|
|
3689
3598
|
|
|
3690
3599
|
|
|
3691
3600
|
var getScaleBandwidth2 = (scale) => {
|
|
3692
|
-
const
|
|
3693
|
-
return
|
|
3601
|
+
const s = scale;
|
|
3602
|
+
return s && "bandwidth" in s ? _nullishCoalesce(_optionalChain([s, 'optionalAccess', _147 => _147.bandwidth, 'call', _148 => _148()]), () => ( 0)) : 0;
|
|
3694
3603
|
};
|
|
3695
3604
|
var DefaultLabelComponent = ({
|
|
3696
3605
|
textProps,
|
|
3697
|
-
x
|
|
3698
|
-
y
|
|
3606
|
+
x,
|
|
3607
|
+
y,
|
|
3699
3608
|
label,
|
|
3700
3609
|
formatter
|
|
3701
3610
|
}) => {
|
|
3702
3611
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _text.Text, {
|
|
3703
3612
|
...textProps,
|
|
3704
3613
|
textAnchor: "start",
|
|
3705
|
-
x
|
|
3706
|
-
y
|
|
3614
|
+
x,
|
|
3615
|
+
y,
|
|
3707
3616
|
children: formatter(label)
|
|
3708
3617
|
});
|
|
3709
3618
|
};
|
|
3710
3619
|
var DefaultValueComponent = ({
|
|
3711
3620
|
textProps,
|
|
3712
|
-
x
|
|
3713
|
-
y
|
|
3621
|
+
x,
|
|
3622
|
+
y,
|
|
3714
3623
|
value,
|
|
3715
3624
|
formatter
|
|
3716
3625
|
}) => {
|
|
3717
3626
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _text.Text, {
|
|
3718
3627
|
...textProps,
|
|
3719
3628
|
textAnchor: "end",
|
|
3720
|
-
x
|
|
3721
|
-
y
|
|
3629
|
+
x,
|
|
3630
|
+
y,
|
|
3722
3631
|
fontWeight: 500,
|
|
3723
3632
|
children: formatter(value)
|
|
3724
3633
|
});
|
|
@@ -3752,18 +3661,18 @@ var AxisRenderer = ({
|
|
|
3752
3661
|
const sum = data.reduce((acc, {
|
|
3753
3662
|
data: seriesData
|
|
3754
3663
|
}) => acc + (_nullishCoalesce(_optionalChain([seriesData, 'access', _149 => _149[index], 'optionalAccess', _150 => _150.value]), () => ( 0))), 0);
|
|
3755
|
-
const
|
|
3664
|
+
const y = from2.y + yOffset;
|
|
3756
3665
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _group.Group, {
|
|
3757
3666
|
children: [/* @__PURE__ */ _jsxruntime.jsx.call(void 0, LabelComponent, {
|
|
3758
3667
|
textProps,
|
|
3759
3668
|
x: labelPosition,
|
|
3760
|
-
y
|
|
3669
|
+
y,
|
|
3761
3670
|
label: formattedValue,
|
|
3762
3671
|
formatter: labelFormatter
|
|
3763
3672
|
}), /* @__PURE__ */ _jsxruntime.jsx.call(void 0, ValueComponent, {
|
|
3764
3673
|
textProps,
|
|
3765
3674
|
x: valuePosition,
|
|
3766
|
-
y
|
|
3675
|
+
y,
|
|
3767
3676
|
value: sum,
|
|
3768
3677
|
formatter: valueFormatter,
|
|
3769
3678
|
data,
|
|
@@ -3891,21 +3800,19 @@ var _tooltip = require('@visx/tooltip');
|
|
|
3891
3800
|
|
|
3892
3801
|
// src/charts/conversion-funnel-chart/conversion-funnel-chart.module.scss
|
|
3893
3802
|
var conversion_funnel_chart_module_default = {
|
|
3894
|
-
"
|
|
3895
|
-
"loading": "a8ccharts-DbHKK5",
|
|
3803
|
+
"conversion-funnel-chart--loading": "a8ccharts-Qicx1p",
|
|
3896
3804
|
"main-metric": "a8ccharts-61WPYr",
|
|
3897
3805
|
"main-rate": "a8ccharts-RRRI6x",
|
|
3898
3806
|
"change-indicator": "a8ccharts-661iwx",
|
|
3899
3807
|
"funnel-container": "a8ccharts-Z7EGnW",
|
|
3900
3808
|
"funnel-step": "a8ccharts-VqFY0l",
|
|
3901
|
-
"
|
|
3809
|
+
"funnel-step--animated": "a8ccharts-fk-hCl",
|
|
3810
|
+
"funnel-step--blurred": "a8ccharts-1zOc9c",
|
|
3902
3811
|
"step-header": "a8ccharts-2JsQiV",
|
|
3903
3812
|
"step-label": "a8ccharts-6OabC4",
|
|
3904
3813
|
"step-rate": "a8ccharts-9wSZ6n",
|
|
3905
3814
|
"bar-container": "a8ccharts-sSmCTi",
|
|
3906
|
-
"disabled": "a8ccharts-PLWVAW",
|
|
3907
3815
|
"funnel-bar": "a8ccharts-EzczI-",
|
|
3908
|
-
"selected": "a8ccharts-wNpZEu",
|
|
3909
3816
|
"funnel-bar--animated": "a8ccharts-68HQJl",
|
|
3910
3817
|
"stretch": "a8ccharts-CmtieZ",
|
|
3911
3818
|
"tooltip-wrapper": "a8ccharts-2TeoCn",
|
|
@@ -3989,7 +3896,8 @@ var ConversionFunnelChartInternal = ({
|
|
|
3989
3896
|
conversionFunnelChart: conversionFunnelChartSettings
|
|
3990
3897
|
} = useGlobalChartsTheme();
|
|
3991
3898
|
const {
|
|
3992
|
-
getElementStyles
|
|
3899
|
+
getElementStyles,
|
|
3900
|
+
isColorPaletteResolved
|
|
3993
3901
|
} = useGlobalChartsContext();
|
|
3994
3902
|
const chartRef = _react.useRef.call(void 0, null);
|
|
3995
3903
|
const selectedBarRef = _react.useRef.call(void 0, null);
|
|
@@ -4022,11 +3930,11 @@ var ConversionFunnelChartInternal = ({
|
|
|
4022
3930
|
selectedBarRef.current = null;
|
|
4023
3931
|
hideTooltip();
|
|
4024
3932
|
}, [clearSelection, hideTooltip]);
|
|
4025
|
-
const showTooltipAt = _react.useCallback.call(void 0, (step,
|
|
3933
|
+
const showTooltipAt = _react.useCallback.call(void 0, (step, x, y) => {
|
|
4026
3934
|
showTooltip({
|
|
4027
3935
|
tooltipData: step,
|
|
4028
|
-
tooltipLeft:
|
|
4029
|
-
tooltipTop:
|
|
3936
|
+
tooltipLeft: x,
|
|
3937
|
+
tooltipTop: y - 10
|
|
4030
3938
|
});
|
|
4031
3939
|
}, [showTooltip]);
|
|
4032
3940
|
const getMouseTooltipCoords = _react.useCallback.call(void 0, (event) => {
|
|
@@ -4043,11 +3951,11 @@ var ConversionFunnelChartInternal = ({
|
|
|
4043
3951
|
return null;
|
|
4044
3952
|
}
|
|
4045
3953
|
const rect = event.currentTarget.getBoundingClientRect();
|
|
4046
|
-
const
|
|
4047
|
-
const
|
|
3954
|
+
const x = rect.left + rect.width / 2 - containerBounds.left;
|
|
3955
|
+
const y = rect.top - containerBounds.top;
|
|
4048
3956
|
return {
|
|
4049
|
-
x
|
|
4050
|
-
y
|
|
3957
|
+
x,
|
|
3958
|
+
y
|
|
4051
3959
|
};
|
|
4052
3960
|
}, [containerBounds.width, containerBounds.height, containerBounds.left, containerBounds.top]);
|
|
4053
3961
|
const handleStepInteraction = _react.useCallback.call(void 0, (step, event, interactionType) => {
|
|
@@ -4166,7 +4074,7 @@ var ConversionFunnelChartInternal = ({
|
|
|
4166
4074
|
if (!isDataValid) {
|
|
4167
4075
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Stack, {
|
|
4168
4076
|
direction: "column",
|
|
4169
|
-
className: _clsx2.default.call(void 0, conversion_funnel_chart_module_default
|
|
4077
|
+
className: _clsx2.default.call(void 0, conversion_funnel_chart_module_default["conversion-funnel-chart"], loading && conversion_funnel_chart_module_default["conversion-funnel-chart--loading"], className),
|
|
4170
4078
|
style: {
|
|
4171
4079
|
...style,
|
|
4172
4080
|
height: resolvedHeight
|
|
@@ -4185,7 +4093,7 @@ var ConversionFunnelChartInternal = ({
|
|
|
4185
4093
|
portalContainerRef(node2);
|
|
4186
4094
|
chartRef.current = node2;
|
|
4187
4095
|
},
|
|
4188
|
-
className: _clsx2.default.call(void 0, conversion_funnel_chart_module_default
|
|
4096
|
+
className: _clsx2.default.call(void 0, conversion_funnel_chart_module_default["conversion-funnel-chart"], loading && conversion_funnel_chart_module_default["conversion-funnel-chart--loading"], className),
|
|
4189
4097
|
style: {
|
|
4190
4098
|
...style,
|
|
4191
4099
|
height: resolvedHeight
|
|
@@ -4206,7 +4114,7 @@ var ConversionFunnelChartInternal = ({
|
|
|
4206
4114
|
isBlurred
|
|
4207
4115
|
} = getStepState(step.id);
|
|
4208
4116
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", {
|
|
4209
|
-
className: _clsx2.default.call(void 0, conversion_funnel_chart_module_default["funnel-step"], isBlurred && conversion_funnel_chart_module_default
|
|
4117
|
+
className: _clsx2.default.call(void 0, conversion_funnel_chart_module_default["funnel-step"], isColorPaletteResolved && conversion_funnel_chart_module_default["funnel-step--animated"], isBlurred && conversion_funnel_chart_module_default["funnel-step--blurred"]),
|
|
4210
4118
|
children: [/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", {
|
|
4211
4119
|
className: conversion_funnel_chart_module_default["step-header"],
|
|
4212
4120
|
children: [renderStepLabel ? renderStepLabel({
|
|
@@ -4225,7 +4133,7 @@ var ConversionFunnelChartInternal = ({
|
|
|
4225
4133
|
children: formatPercentage(step.rate)
|
|
4226
4134
|
})]
|
|
4227
4135
|
}), /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", {
|
|
4228
|
-
className:
|
|
4136
|
+
className: conversion_funnel_chart_module_default["bar-container"],
|
|
4229
4137
|
onClick: _optionalChain([stepHandlers, 'access', _160 => _160.get, 'call', _161 => _161(step.id), 'optionalAccess', _162 => _162.onClick]),
|
|
4230
4138
|
onKeyDown: _optionalChain([stepHandlers, 'access', _163 => _163.get, 'call', _164 => _164(step.id), 'optionalAccess', _165 => _165.onKeyDown]),
|
|
4231
4139
|
role: "button",
|
|
@@ -4250,7 +4158,7 @@ var ConversionFunnelChartInternal = ({
|
|
|
4250
4158
|
}), tooltipOpen && tooltipData && (() => {
|
|
4251
4159
|
const tooltipContent = renderTooltip ? renderTooltip({
|
|
4252
4160
|
step: tooltipData,
|
|
4253
|
-
index: steps.findIndex((
|
|
4161
|
+
index: steps.findIndex((s) => s.id === tooltipData.id),
|
|
4254
4162
|
top: tooltipTop,
|
|
4255
4163
|
left: tooltipLeft,
|
|
4256
4164
|
className: conversion_funnel_chart_module_default["tooltip-wrapper"]
|
|
@@ -4376,10 +4284,10 @@ var GeoChartInternal = ({
|
|
|
4376
4284
|
};
|
|
4377
4285
|
}
|
|
4378
4286
|
const htmlTooltipIndices = [];
|
|
4379
|
-
for (let
|
|
4380
|
-
const col = data[0][
|
|
4287
|
+
for (let i = 0; i < data[0].length; i++) {
|
|
4288
|
+
const col = data[0][i];
|
|
4381
4289
|
if (typeof col === "object" && col !== null && "role" in col && col.role === "tooltip" && "p" in col && typeof col.p === "object" && col.p !== null && "html" in col.p && col.p.html === true) {
|
|
4382
|
-
htmlTooltipIndices.push(
|
|
4290
|
+
htmlTooltipIndices.push(i);
|
|
4383
4291
|
}
|
|
4384
4292
|
}
|
|
4385
4293
|
if (htmlTooltipIndices.length === 0) {
|
|
@@ -4455,12 +4363,7 @@ var GeoChartWithProvider = (props) => {
|
|
|
4455
4363
|
GeoChartWithProvider.displayName = "GeoChart";
|
|
4456
4364
|
var GeoChartResponsive = withResponsive(GeoChartWithProvider);
|
|
4457
4365
|
|
|
4458
|
-
// ../../../node_modules/.pnpm/@wordpress+components@32.
|
|
4459
|
-
function isValueDefined(value) {
|
|
4460
|
-
return value !== void 0 && value !== null;
|
|
4461
|
-
}
|
|
4462
|
-
|
|
4463
|
-
// ../../../node_modules/.pnpm/@wordpress+components@32.4.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/utils/hooks/use-update-effect.mjs
|
|
4366
|
+
// ../../../node_modules/.pnpm/@wordpress+components@32.5.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/utils/hooks/use-update-effect.mjs
|
|
4464
4367
|
function useUpdateEffect(effect, deps) {
|
|
4465
4368
|
const mountedRef = _react.useRef.call(void 0, false);
|
|
4466
4369
|
_react.useEffect.call(void 0, () => {
|
|
@@ -4486,9 +4389,9 @@ function sheetForTag(tag) {
|
|
|
4486
4389
|
if (tag.sheet) {
|
|
4487
4390
|
return tag.sheet;
|
|
4488
4391
|
}
|
|
4489
|
-
for (var
|
|
4490
|
-
if (document.styleSheets[
|
|
4491
|
-
return document.styleSheets[
|
|
4392
|
+
for (var i = 0; i < document.styleSheets.length; i++) {
|
|
4393
|
+
if (document.styleSheets[i].ownerNode === tag) {
|
|
4394
|
+
return document.styleSheets[i];
|
|
4492
4395
|
}
|
|
4493
4396
|
}
|
|
4494
4397
|
return void 0;
|
|
@@ -4545,7 +4448,7 @@ var StyleSheet = /* @__PURE__ */ (function() {
|
|
|
4545
4448
|
var sheet2 = sheetForTag(tag);
|
|
4546
4449
|
try {
|
|
4547
4450
|
sheet2.insertRule(rule, sheet2.cssRules.length);
|
|
4548
|
-
} catch (
|
|
4451
|
+
} catch (e) {
|
|
4549
4452
|
}
|
|
4550
4453
|
} else {
|
|
4551
4454
|
tag.appendChild(document.createTextNode(rule));
|
|
@@ -4884,10 +4787,10 @@ function ruleset(value, root, parent, index, offset, rules, points, type, props,
|
|
|
4884
4787
|
var post = offset - 1;
|
|
4885
4788
|
var rule = offset === 0 ? rules : [""];
|
|
4886
4789
|
var size = sizeof(rule);
|
|
4887
|
-
for (var
|
|
4888
|
-
for (var
|
|
4889
|
-
if (z = trim(
|
|
4890
|
-
props[
|
|
4790
|
+
for (var i = 0, j = 0, k = 0; i < index; ++i)
|
|
4791
|
+
for (var x = 0, y = substr(value, post + 1, post = abs(j = points[i])), z = value; x < size; ++x)
|
|
4792
|
+
if (z = trim(j > 0 ? rule[x] + " " + y : replace2(y, /&\f/g, rule[x])))
|
|
4793
|
+
props[k++] = z;
|
|
4891
4794
|
return node(value, root, parent, offset === 0 ? RULESET : type, props, children, length2);
|
|
4892
4795
|
}
|
|
4893
4796
|
function comment(value, root, parent) {
|
|
@@ -4901,8 +4804,8 @@ function declaration(value, root, parent, length2) {
|
|
|
4901
4804
|
function serialize(children, callback) {
|
|
4902
4805
|
var output = "";
|
|
4903
4806
|
var length2 = sizeof(children);
|
|
4904
|
-
for (var
|
|
4905
|
-
output += callback(children[
|
|
4807
|
+
for (var i = 0; i < length2; i++)
|
|
4808
|
+
output += callback(children[i], i, children, callback) || "";
|
|
4906
4809
|
return output;
|
|
4907
4810
|
}
|
|
4908
4811
|
function stringify(element, index, children, callback) {
|
|
@@ -4927,8 +4830,8 @@ function middleware(collection) {
|
|
|
4927
4830
|
var length2 = sizeof(collection);
|
|
4928
4831
|
return function(element, index, children, callback) {
|
|
4929
4832
|
var output = "";
|
|
4930
|
-
for (var
|
|
4931
|
-
output += collection[
|
|
4833
|
+
for (var i = 0; i < length2; i++)
|
|
4834
|
+
output += collection[i](element, index, children, callback) || "";
|
|
4932
4835
|
return output;
|
|
4933
4836
|
};
|
|
4934
4837
|
}
|
|
@@ -5035,9 +4938,9 @@ var compat = function compat2(element) {
|
|
|
5035
4938
|
var points = [];
|
|
5036
4939
|
var rules = getRules(value, points);
|
|
5037
4940
|
var parentRules = parent.props;
|
|
5038
|
-
for (var
|
|
5039
|
-
for (var
|
|
5040
|
-
element.props[
|
|
4941
|
+
for (var i = 0, k = 0; i < rules.length; i++) {
|
|
4942
|
+
for (var j = 0; j < parentRules.length; j++, k++) {
|
|
4943
|
+
element.props[k] = points[i] ? rules[i].replace(/&\f/g, parentRules[j]) : parentRules[j] + " " + rules[i];
|
|
5041
4944
|
}
|
|
5042
4945
|
}
|
|
5043
4946
|
};
|
|
@@ -5261,8 +5164,8 @@ var createCache = function createCache2(options) {
|
|
|
5261
5164
|
document.querySelectorAll('style[data-emotion^="' + key + ' "]'),
|
|
5262
5165
|
function(node2) {
|
|
5263
5166
|
var attrib = node2.getAttribute("data-emotion").split(" ");
|
|
5264
|
-
for (var
|
|
5265
|
-
inserted[attrib[
|
|
5167
|
+
for (var i = 1; i < attrib.length; i++) {
|
|
5168
|
+
inserted[attrib[i]] = true;
|
|
5266
5169
|
}
|
|
5267
5170
|
nodesToHydrate.push(node2);
|
|
5268
5171
|
}
|
|
@@ -5390,32 +5293,32 @@ var insertStyles = function insertStyles2(cache2, serialized, isStringTag) {
|
|
|
5390
5293
|
|
|
5391
5294
|
// ../../../node_modules/.pnpm/@emotion+hash@0.9.2/node_modules/@emotion/hash/dist/emotion-hash.esm.js
|
|
5392
5295
|
function murmur2(str) {
|
|
5393
|
-
var
|
|
5394
|
-
var
|
|
5395
|
-
for (; len >= 4; ++
|
|
5396
|
-
|
|
5397
|
-
|
|
5398
|
-
(
|
|
5399
|
-
|
|
5400
|
-
|
|
5401
|
-
|
|
5402
|
-
(
|
|
5403
|
-
(
|
|
5296
|
+
var h = 0;
|
|
5297
|
+
var k, i = 0, len = str.length;
|
|
5298
|
+
for (; len >= 4; ++i, len -= 4) {
|
|
5299
|
+
k = str.charCodeAt(i) & 255 | (str.charCodeAt(++i) & 255) << 8 | (str.charCodeAt(++i) & 255) << 16 | (str.charCodeAt(++i) & 255) << 24;
|
|
5300
|
+
k = /* Math.imul(k, m): */
|
|
5301
|
+
(k & 65535) * 1540483477 + ((k >>> 16) * 59797 << 16);
|
|
5302
|
+
k ^= /* k >>> r: */
|
|
5303
|
+
k >>> 24;
|
|
5304
|
+
h = /* Math.imul(k, m): */
|
|
5305
|
+
(k & 65535) * 1540483477 + ((k >>> 16) * 59797 << 16) ^ /* Math.imul(h, m): */
|
|
5306
|
+
(h & 65535) * 1540483477 + ((h >>> 16) * 59797 << 16);
|
|
5404
5307
|
}
|
|
5405
5308
|
switch (len) {
|
|
5406
5309
|
case 3:
|
|
5407
|
-
|
|
5310
|
+
h ^= (str.charCodeAt(i + 2) & 255) << 16;
|
|
5408
5311
|
case 2:
|
|
5409
|
-
|
|
5312
|
+
h ^= (str.charCodeAt(i + 1) & 255) << 8;
|
|
5410
5313
|
case 1:
|
|
5411
|
-
|
|
5412
|
-
|
|
5413
|
-
(
|
|
5314
|
+
h ^= str.charCodeAt(i) & 255;
|
|
5315
|
+
h = /* Math.imul(h, m): */
|
|
5316
|
+
(h & 65535) * 1540483477 + ((h >>> 16) * 59797 << 16);
|
|
5414
5317
|
}
|
|
5415
|
-
|
|
5416
|
-
|
|
5417
|
-
(
|
|
5418
|
-
return ((
|
|
5318
|
+
h ^= h >>> 13;
|
|
5319
|
+
h = /* Math.imul(h, m): */
|
|
5320
|
+
(h & 65535) * 1540483477 + ((h >>> 16) * 59797 << 16);
|
|
5321
|
+
return ((h ^ h >>> 15) >>> 0).toString(36);
|
|
5419
5322
|
}
|
|
5420
5323
|
|
|
5421
5324
|
// ../../../node_modules/.pnpm/@emotion+unitless@0.10.0/node_modules/@emotion/unitless/dist/emotion-unitless.esm.js
|
|
@@ -5565,8 +5468,8 @@ function handleInterpolation(mergedProps, registered, interpolation) {
|
|
|
5565
5468
|
function createStringFromObject(mergedProps, registered, obj) {
|
|
5566
5469
|
var string = "";
|
|
5567
5470
|
if (Array.isArray(obj)) {
|
|
5568
|
-
for (var
|
|
5569
|
-
string += handleInterpolation(mergedProps, registered, obj[
|
|
5471
|
+
for (var i = 0; i < obj.length; i++) {
|
|
5472
|
+
string += handleInterpolation(mergedProps, registered, obj[i]) + ";";
|
|
5570
5473
|
}
|
|
5571
5474
|
} else {
|
|
5572
5475
|
for (var key in obj) {
|
|
@@ -5623,11 +5526,11 @@ function serializeStyles(args, registered, mergedProps) {
|
|
|
5623
5526
|
var asTemplateStringsArr = strings;
|
|
5624
5527
|
styles += asTemplateStringsArr[0];
|
|
5625
5528
|
}
|
|
5626
|
-
for (var
|
|
5627
|
-
styles += handleInterpolation(mergedProps, registered, args[
|
|
5529
|
+
for (var i = 1; i < args.length; i++) {
|
|
5530
|
+
styles += handleInterpolation(mergedProps, registered, args[i]);
|
|
5628
5531
|
if (stringMode) {
|
|
5629
5532
|
var templateStringsArr = strings;
|
|
5630
|
-
styles += templateStringsArr[
|
|
5533
|
+
styles += templateStringsArr[i];
|
|
5631
5534
|
}
|
|
5632
5535
|
}
|
|
5633
5536
|
labelPattern.lastIndex = 0;
|
|
@@ -5707,23 +5610,23 @@ var createEmotionProps = function createEmotionProps2(type, props) {
|
|
|
5707
5610
|
newProps[typePropName] = type;
|
|
5708
5611
|
return newProps;
|
|
5709
5612
|
};
|
|
5710
|
-
var Insertion = function Insertion2(
|
|
5711
|
-
var cache2 =
|
|
5613
|
+
var Insertion = function Insertion2(_ref) {
|
|
5614
|
+
var cache2 = _ref.cache, serialized = _ref.serialized, isStringTag = _ref.isStringTag;
|
|
5712
5615
|
registerStyles(cache2, serialized, isStringTag);
|
|
5713
5616
|
var rules = useInsertionEffectAlwaysWithSyncFallback(function() {
|
|
5714
5617
|
return insertStyles(cache2, serialized, isStringTag);
|
|
5715
5618
|
});
|
|
5716
5619
|
if (!isBrowser4 && rules !== void 0) {
|
|
5717
|
-
var
|
|
5620
|
+
var _ref2;
|
|
5718
5621
|
var serializedNames = serialized.name;
|
|
5719
5622
|
var next2 = serialized.next;
|
|
5720
5623
|
while (next2 !== void 0) {
|
|
5721
5624
|
serializedNames += " " + next2.name;
|
|
5722
5625
|
next2 = next2.next;
|
|
5723
5626
|
}
|
|
5724
|
-
return /* @__PURE__ */ React6.createElement("style", (
|
|
5627
|
+
return /* @__PURE__ */ React6.createElement("style", (_ref2 = {}, _ref2["data-emotion"] = cache2.key + " " + serializedNames, _ref2.dangerouslySetInnerHTML = {
|
|
5725
5628
|
__html: rules
|
|
5726
|
-
},
|
|
5629
|
+
}, _ref2.nonce = cache2.sheet.nonce, _ref2));
|
|
5727
5630
|
}
|
|
5728
5631
|
return null;
|
|
5729
5632
|
};
|
|
@@ -5763,7 +5666,7 @@ var Emotion$1 = Emotion;
|
|
|
5763
5666
|
// ../../../node_modules/.pnpm/@emotion+react@11.14.0_@types+react@18.3.28_react@18.3.1/node_modules/@emotion/react/dist/emotion-react.esm.js
|
|
5764
5667
|
|
|
5765
5668
|
require('@babel/runtime/helpers/extends');
|
|
5766
|
-
var import_hoist_non_react_statics =
|
|
5669
|
+
var import_hoist_non_react_statics = _chunkDZUJEN5Ncjs.__toESM.call(void 0, require_hoist_non_react_statics_cjs());
|
|
5767
5670
|
var jsx = function jsx2(type, props) {
|
|
5768
5671
|
var args = arguments;
|
|
5769
5672
|
if (props == null || !hasOwn.call(props, "css")) {
|
|
@@ -5773,15 +5676,15 @@ var jsx = function jsx2(type, props) {
|
|
|
5773
5676
|
var createElementArgArray = new Array(argsLength);
|
|
5774
5677
|
createElementArgArray[0] = Emotion$1;
|
|
5775
5678
|
createElementArgArray[1] = createEmotionProps(type, props);
|
|
5776
|
-
for (var
|
|
5777
|
-
createElementArgArray[
|
|
5679
|
+
for (var i = 2; i < argsLength; i++) {
|
|
5680
|
+
createElementArgArray[i] = args[i];
|
|
5778
5681
|
}
|
|
5779
5682
|
return React7.createElement.apply(null, createElementArgArray);
|
|
5780
5683
|
};
|
|
5781
|
-
(function(
|
|
5684
|
+
(function(_jsx30) {
|
|
5782
5685
|
var JSX;
|
|
5783
5686
|
/* @__PURE__ */ (function(_JSX) {
|
|
5784
|
-
})(JSX || (JSX =
|
|
5687
|
+
})(JSX || (JSX = _jsx30.JSX || (_jsx30.JSX = {})));
|
|
5785
5688
|
})(jsx || (jsx = {}));
|
|
5786
5689
|
function css() {
|
|
5787
5690
|
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
@@ -5866,8 +5769,8 @@ var createEmotion = function createEmotion2(options) {
|
|
|
5866
5769
|
};
|
|
5867
5770
|
var classnames = function classnames2(args) {
|
|
5868
5771
|
var cls = "";
|
|
5869
|
-
for (var
|
|
5870
|
-
var arg = args[
|
|
5772
|
+
for (var i = 0; i < args.length; i++) {
|
|
5773
|
+
var arg = args[i];
|
|
5871
5774
|
if (arg == null) continue;
|
|
5872
5775
|
var toAdd = void 0;
|
|
5873
5776
|
switch (typeof arg) {
|
|
@@ -5878,10 +5781,10 @@ var classnames = function classnames2(args) {
|
|
|
5878
5781
|
toAdd = classnames2(arg);
|
|
5879
5782
|
} else {
|
|
5880
5783
|
toAdd = "";
|
|
5881
|
-
for (var
|
|
5882
|
-
if (arg[
|
|
5784
|
+
for (var k in arg) {
|
|
5785
|
+
if (arg[k] && k) {
|
|
5883
5786
|
toAdd && (toAdd += " ");
|
|
5884
|
-
toAdd +=
|
|
5787
|
+
toAdd += k;
|
|
5885
5788
|
}
|
|
5886
5789
|
}
|
|
5887
5790
|
}
|
|
@@ -5914,8 +5817,8 @@ var css2 = _createEmotion.css;
|
|
|
5914
5817
|
var sheet = _createEmotion.sheet;
|
|
5915
5818
|
var cache = _createEmotion.cache;
|
|
5916
5819
|
|
|
5917
|
-
// ../../../node_modules/.pnpm/@wordpress+components@32.
|
|
5918
|
-
var isSerializedStyles = (
|
|
5820
|
+
// ../../../node_modules/.pnpm/@wordpress+components@32.5.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/utils/hooks/use-cx.mjs
|
|
5821
|
+
var isSerializedStyles = (o) => typeof o !== "undefined" && o !== null && ["name", "styles"].every((p) => typeof o[p] !== "undefined");
|
|
5919
5822
|
var useCx = () => {
|
|
5920
5823
|
const cache2 = __unsafe_useEmotionCache();
|
|
5921
5824
|
const cx2 = _react.useCallback.call(void 0, (...classNames) => {
|
|
@@ -5940,14 +5843,14 @@ function memize(fn, options) {
|
|
|
5940
5843
|
var tail;
|
|
5941
5844
|
options = options || {};
|
|
5942
5845
|
function memoized() {
|
|
5943
|
-
var node2 = head, len = arguments.length, args,
|
|
5846
|
+
var node2 = head, len = arguments.length, args, i;
|
|
5944
5847
|
searchCache: while (node2) {
|
|
5945
5848
|
if (node2.args.length !== arguments.length) {
|
|
5946
5849
|
node2 = node2.next;
|
|
5947
5850
|
continue;
|
|
5948
5851
|
}
|
|
5949
|
-
for (
|
|
5950
|
-
if (node2.args[
|
|
5852
|
+
for (i = 0; i < len; i++) {
|
|
5853
|
+
if (node2.args[i] !== arguments[i]) {
|
|
5951
5854
|
node2 = node2.next;
|
|
5952
5855
|
continue searchCache;
|
|
5953
5856
|
}
|
|
@@ -5968,8 +5871,8 @@ function memize(fn, options) {
|
|
|
5968
5871
|
return node2.val;
|
|
5969
5872
|
}
|
|
5970
5873
|
args = new Array(len);
|
|
5971
|
-
for (
|
|
5972
|
-
args[
|
|
5874
|
+
for (i = 0; i < len; i++) {
|
|
5875
|
+
args[i] = arguments[i];
|
|
5973
5876
|
}
|
|
5974
5877
|
node2 = {
|
|
5975
5878
|
args,
|
|
@@ -6001,250 +5904,7 @@ function memize(fn, options) {
|
|
|
6001
5904
|
return memoized;
|
|
6002
5905
|
}
|
|
6003
5906
|
|
|
6004
|
-
// ../../../node_modules/.pnpm
|
|
6005
|
-
var r = { grad: 0.9, turn: 360, rad: 360 / (2 * Math.PI) };
|
|
6006
|
-
var t = function(r2) {
|
|
6007
|
-
return "string" == typeof r2 ? r2.length > 0 : "number" == typeof r2;
|
|
6008
|
-
};
|
|
6009
|
-
var n = function(r2, t2, n2) {
|
|
6010
|
-
return void 0 === t2 && (t2 = 0), void 0 === n2 && (n2 = Math.pow(10, t2)), Math.round(n2 * r2) / n2 + 0;
|
|
6011
|
-
};
|
|
6012
|
-
var e = function(r2, t2, n2) {
|
|
6013
|
-
return void 0 === t2 && (t2 = 0), void 0 === n2 && (n2 = 1), r2 > n2 ? n2 : r2 > t2 ? r2 : t2;
|
|
6014
|
-
};
|
|
6015
|
-
var u = function(r2) {
|
|
6016
|
-
return (r2 = isFinite(r2) ? r2 % 360 : 0) > 0 ? r2 : r2 + 360;
|
|
6017
|
-
};
|
|
6018
|
-
var a = function(r2) {
|
|
6019
|
-
return { r: e(r2.r, 0, 255), g: e(r2.g, 0, 255), b: e(r2.b, 0, 255), a: e(r2.a) };
|
|
6020
|
-
};
|
|
6021
|
-
var o = function(r2) {
|
|
6022
|
-
return { r: n(r2.r), g: n(r2.g), b: n(r2.b), a: n(r2.a, 3) };
|
|
6023
|
-
};
|
|
6024
|
-
var i = /^#([0-9a-f]{3,8})$/i;
|
|
6025
|
-
var s = function(r2) {
|
|
6026
|
-
var t2 = r2.toString(16);
|
|
6027
|
-
return t2.length < 2 ? "0" + t2 : t2;
|
|
6028
|
-
};
|
|
6029
|
-
var h = function(r2) {
|
|
6030
|
-
var t2 = r2.r, n2 = r2.g, e2 = r2.b, u2 = r2.a, a2 = Math.max(t2, n2, e2), o2 = a2 - Math.min(t2, n2, e2), i2 = o2 ? a2 === t2 ? (n2 - e2) / o2 : a2 === n2 ? 2 + (e2 - t2) / o2 : 4 + (t2 - n2) / o2 : 0;
|
|
6031
|
-
return { h: 60 * (i2 < 0 ? i2 + 6 : i2), s: a2 ? o2 / a2 * 100 : 0, v: a2 / 255 * 100, a: u2 };
|
|
6032
|
-
};
|
|
6033
|
-
var b = function(r2) {
|
|
6034
|
-
var t2 = r2.h, n2 = r2.s, e2 = r2.v, u2 = r2.a;
|
|
6035
|
-
t2 = t2 / 360 * 6, n2 /= 100, e2 /= 100;
|
|
6036
|
-
var a2 = Math.floor(t2), o2 = e2 * (1 - n2), i2 = e2 * (1 - (t2 - a2) * n2), s2 = e2 * (1 - (1 - t2 + a2) * n2), h2 = a2 % 6;
|
|
6037
|
-
return { r: 255 * [e2, i2, o2, o2, s2, e2][h2], g: 255 * [s2, e2, e2, i2, o2, o2][h2], b: 255 * [o2, o2, s2, e2, e2, i2][h2], a: u2 };
|
|
6038
|
-
};
|
|
6039
|
-
var g = function(r2) {
|
|
6040
|
-
return { h: u(r2.h), s: e(r2.s, 0, 100), l: e(r2.l, 0, 100), a: e(r2.a) };
|
|
6041
|
-
};
|
|
6042
|
-
var d = function(r2) {
|
|
6043
|
-
return { h: n(r2.h), s: n(r2.s), l: n(r2.l), a: n(r2.a, 3) };
|
|
6044
|
-
};
|
|
6045
|
-
var f = function(r2) {
|
|
6046
|
-
return b((n2 = (t2 = r2).s, { h: t2.h, s: (n2 *= ((e2 = t2.l) < 50 ? e2 : 100 - e2) / 100) > 0 ? 2 * n2 / (e2 + n2) * 100 : 0, v: e2 + n2, a: t2.a }));
|
|
6047
|
-
var t2, n2, e2;
|
|
6048
|
-
};
|
|
6049
|
-
var c = function(r2) {
|
|
6050
|
-
return { h: (t2 = h(r2)).h, s: (u2 = (200 - (n2 = t2.s)) * (e2 = t2.v) / 100) > 0 && u2 < 200 ? n2 * e2 / 100 / (u2 <= 100 ? u2 : 200 - u2) * 100 : 0, l: u2 / 2, a: t2.a };
|
|
6051
|
-
var t2, n2, e2, u2;
|
|
6052
|
-
};
|
|
6053
|
-
var l = /^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s*,\s*([+-]?\d*\.?\d+)%\s*,\s*([+-]?\d*\.?\d+)%\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i;
|
|
6054
|
-
var p = /^hsla?\(\s*([+-]?\d*\.?\d+)(deg|rad|grad|turn)?\s+([+-]?\d*\.?\d+)%\s+([+-]?\d*\.?\d+)%\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i;
|
|
6055
|
-
var v = /^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*,\s*([+-]?\d*\.?\d+)(%)?\s*(?:,\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i;
|
|
6056
|
-
var m = /^rgba?\(\s*([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s+([+-]?\d*\.?\d+)(%)?\s*(?:\/\s*([+-]?\d*\.?\d+)(%)?\s*)?\)$/i;
|
|
6057
|
-
var y = { string: [[function(r2) {
|
|
6058
|
-
var t2 = i.exec(r2);
|
|
6059
|
-
return t2 ? (r2 = t2[1]).length <= 4 ? { r: parseInt(r2[0] + r2[0], 16), g: parseInt(r2[1] + r2[1], 16), b: parseInt(r2[2] + r2[2], 16), a: 4 === r2.length ? n(parseInt(r2[3] + r2[3], 16) / 255, 2) : 1 } : 6 === r2.length || 8 === r2.length ? { r: parseInt(r2.substr(0, 2), 16), g: parseInt(r2.substr(2, 2), 16), b: parseInt(r2.substr(4, 2), 16), a: 8 === r2.length ? n(parseInt(r2.substr(6, 2), 16) / 255, 2) : 1 } : null : null;
|
|
6060
|
-
}, "hex"], [function(r2) {
|
|
6061
|
-
var t2 = v.exec(r2) || m.exec(r2);
|
|
6062
|
-
return t2 ? t2[2] !== t2[4] || t2[4] !== t2[6] ? null : a({ r: Number(t2[1]) / (t2[2] ? 100 / 255 : 1), g: Number(t2[3]) / (t2[4] ? 100 / 255 : 1), b: Number(t2[5]) / (t2[6] ? 100 / 255 : 1), a: void 0 === t2[7] ? 1 : Number(t2[7]) / (t2[8] ? 100 : 1) }) : null;
|
|
6063
|
-
}, "rgb"], [function(t2) {
|
|
6064
|
-
var n2 = l.exec(t2) || p.exec(t2);
|
|
6065
|
-
if (!n2) return null;
|
|
6066
|
-
var e2, u2, a2 = g({ h: (e2 = n2[1], u2 = n2[2], void 0 === u2 && (u2 = "deg"), Number(e2) * (r[u2] || 1)), s: Number(n2[3]), l: Number(n2[4]), a: void 0 === n2[5] ? 1 : Number(n2[5]) / (n2[6] ? 100 : 1) });
|
|
6067
|
-
return f(a2);
|
|
6068
|
-
}, "hsl"]], object: [[function(r2) {
|
|
6069
|
-
var n2 = r2.r, e2 = r2.g, u2 = r2.b, o2 = r2.a, i2 = void 0 === o2 ? 1 : o2;
|
|
6070
|
-
return t(n2) && t(e2) && t(u2) ? a({ r: Number(n2), g: Number(e2), b: Number(u2), a: Number(i2) }) : null;
|
|
6071
|
-
}, "rgb"], [function(r2) {
|
|
6072
|
-
var n2 = r2.h, e2 = r2.s, u2 = r2.l, a2 = r2.a, o2 = void 0 === a2 ? 1 : a2;
|
|
6073
|
-
if (!t(n2) || !t(e2) || !t(u2)) return null;
|
|
6074
|
-
var i2 = g({ h: Number(n2), s: Number(e2), l: Number(u2), a: Number(o2) });
|
|
6075
|
-
return f(i2);
|
|
6076
|
-
}, "hsl"], [function(r2) {
|
|
6077
|
-
var n2 = r2.h, a2 = r2.s, o2 = r2.v, i2 = r2.a, s2 = void 0 === i2 ? 1 : i2;
|
|
6078
|
-
if (!t(n2) || !t(a2) || !t(o2)) return null;
|
|
6079
|
-
var h2 = (function(r3) {
|
|
6080
|
-
return { h: u(r3.h), s: e(r3.s, 0, 100), v: e(r3.v, 0, 100), a: e(r3.a) };
|
|
6081
|
-
})({ h: Number(n2), s: Number(a2), v: Number(o2), a: Number(s2) });
|
|
6082
|
-
return b(h2);
|
|
6083
|
-
}, "hsv"]] };
|
|
6084
|
-
var N = function(r2, t2) {
|
|
6085
|
-
for (var n2 = 0; n2 < t2.length; n2++) {
|
|
6086
|
-
var e2 = t2[n2][0](r2);
|
|
6087
|
-
if (e2) return [e2, t2[n2][1]];
|
|
6088
|
-
}
|
|
6089
|
-
return [null, void 0];
|
|
6090
|
-
};
|
|
6091
|
-
var x = function(r2) {
|
|
6092
|
-
return "string" == typeof r2 ? N(r2.trim(), y.string) : "object" == typeof r2 && null !== r2 ? N(r2, y.object) : [null, void 0];
|
|
6093
|
-
};
|
|
6094
|
-
var M = function(r2, t2) {
|
|
6095
|
-
var n2 = c(r2);
|
|
6096
|
-
return { h: n2.h, s: e(n2.s + 100 * t2, 0, 100), l: n2.l, a: n2.a };
|
|
6097
|
-
};
|
|
6098
|
-
var H = function(r2) {
|
|
6099
|
-
return (299 * r2.r + 587 * r2.g + 114 * r2.b) / 1e3 / 255;
|
|
6100
|
-
};
|
|
6101
|
-
var $ = function(r2, t2) {
|
|
6102
|
-
var n2 = c(r2);
|
|
6103
|
-
return { h: n2.h, s: n2.s, l: e(n2.l + 100 * t2, 0, 100), a: n2.a };
|
|
6104
|
-
};
|
|
6105
|
-
var j = (function() {
|
|
6106
|
-
function r2(r3) {
|
|
6107
|
-
this.parsed = x(r3)[0], this.rgba = this.parsed || { r: 0, g: 0, b: 0, a: 1 };
|
|
6108
|
-
}
|
|
6109
|
-
return r2.prototype.isValid = function() {
|
|
6110
|
-
return null !== this.parsed;
|
|
6111
|
-
}, r2.prototype.brightness = function() {
|
|
6112
|
-
return n(H(this.rgba), 2);
|
|
6113
|
-
}, r2.prototype.isDark = function() {
|
|
6114
|
-
return H(this.rgba) < 0.5;
|
|
6115
|
-
}, r2.prototype.isLight = function() {
|
|
6116
|
-
return H(this.rgba) >= 0.5;
|
|
6117
|
-
}, r2.prototype.toHex = function() {
|
|
6118
|
-
return r3 = o(this.rgba), t2 = r3.r, e2 = r3.g, u2 = r3.b, i2 = (a2 = r3.a) < 1 ? s(n(255 * a2)) : "", "#" + s(t2) + s(e2) + s(u2) + i2;
|
|
6119
|
-
var r3, t2, e2, u2, a2, i2;
|
|
6120
|
-
}, r2.prototype.toRgb = function() {
|
|
6121
|
-
return o(this.rgba);
|
|
6122
|
-
}, r2.prototype.toRgbString = function() {
|
|
6123
|
-
return r3 = o(this.rgba), t2 = r3.r, n2 = r3.g, e2 = r3.b, (u2 = r3.a) < 1 ? "rgba(" + t2 + ", " + n2 + ", " + e2 + ", " + u2 + ")" : "rgb(" + t2 + ", " + n2 + ", " + e2 + ")";
|
|
6124
|
-
var r3, t2, n2, e2, u2;
|
|
6125
|
-
}, r2.prototype.toHsl = function() {
|
|
6126
|
-
return d(c(this.rgba));
|
|
6127
|
-
}, r2.prototype.toHslString = function() {
|
|
6128
|
-
return r3 = d(c(this.rgba)), t2 = r3.h, n2 = r3.s, e2 = r3.l, (u2 = r3.a) < 1 ? "hsla(" + t2 + ", " + n2 + "%, " + e2 + "%, " + u2 + ")" : "hsl(" + t2 + ", " + n2 + "%, " + e2 + "%)";
|
|
6129
|
-
var r3, t2, n2, e2, u2;
|
|
6130
|
-
}, r2.prototype.toHsv = function() {
|
|
6131
|
-
return r3 = h(this.rgba), { h: n(r3.h), s: n(r3.s), v: n(r3.v), a: n(r3.a, 3) };
|
|
6132
|
-
var r3;
|
|
6133
|
-
}, r2.prototype.invert = function() {
|
|
6134
|
-
return w({ r: 255 - (r3 = this.rgba).r, g: 255 - r3.g, b: 255 - r3.b, a: r3.a });
|
|
6135
|
-
var r3;
|
|
6136
|
-
}, r2.prototype.saturate = function(r3) {
|
|
6137
|
-
return void 0 === r3 && (r3 = 0.1), w(M(this.rgba, r3));
|
|
6138
|
-
}, r2.prototype.desaturate = function(r3) {
|
|
6139
|
-
return void 0 === r3 && (r3 = 0.1), w(M(this.rgba, -r3));
|
|
6140
|
-
}, r2.prototype.grayscale = function() {
|
|
6141
|
-
return w(M(this.rgba, -1));
|
|
6142
|
-
}, r2.prototype.lighten = function(r3) {
|
|
6143
|
-
return void 0 === r3 && (r3 = 0.1), w($(this.rgba, r3));
|
|
6144
|
-
}, r2.prototype.darken = function(r3) {
|
|
6145
|
-
return void 0 === r3 && (r3 = 0.1), w($(this.rgba, -r3));
|
|
6146
|
-
}, r2.prototype.rotate = function(r3) {
|
|
6147
|
-
return void 0 === r3 && (r3 = 15), this.hue(this.hue() + r3);
|
|
6148
|
-
}, r2.prototype.alpha = function(r3) {
|
|
6149
|
-
return "number" == typeof r3 ? w({ r: (t2 = this.rgba).r, g: t2.g, b: t2.b, a: r3 }) : n(this.rgba.a, 3);
|
|
6150
|
-
var t2;
|
|
6151
|
-
}, r2.prototype.hue = function(r3) {
|
|
6152
|
-
var t2 = c(this.rgba);
|
|
6153
|
-
return "number" == typeof r3 ? w({ h: r3, s: t2.s, l: t2.l, a: t2.a }) : n(t2.h);
|
|
6154
|
-
}, r2.prototype.isEqual = function(r3) {
|
|
6155
|
-
return this.toHex() === w(r3).toHex();
|
|
6156
|
-
}, r2;
|
|
6157
|
-
})();
|
|
6158
|
-
var w = function(r2) {
|
|
6159
|
-
return r2 instanceof j ? r2 : new j(r2);
|
|
6160
|
-
};
|
|
6161
|
-
var S = [];
|
|
6162
|
-
var k = function(r2) {
|
|
6163
|
-
r2.forEach(function(r3) {
|
|
6164
|
-
S.indexOf(r3) < 0 && (r3(j, y), S.push(r3));
|
|
6165
|
-
});
|
|
6166
|
-
};
|
|
6167
|
-
|
|
6168
|
-
// ../../../node_modules/.pnpm/colord@2.9.3/node_modules/colord/plugins/names.mjs
|
|
6169
|
-
function names_default(e2, f2) {
|
|
6170
|
-
var a2 = { white: "#ffffff", bisque: "#ffe4c4", blue: "#0000ff", cadetblue: "#5f9ea0", chartreuse: "#7fff00", chocolate: "#d2691e", coral: "#ff7f50", antiquewhite: "#faebd7", aqua: "#00ffff", azure: "#f0ffff", whitesmoke: "#f5f5f5", papayawhip: "#ffefd5", plum: "#dda0dd", blanchedalmond: "#ffebcd", black: "#000000", gold: "#ffd700", goldenrod: "#daa520", gainsboro: "#dcdcdc", cornsilk: "#fff8dc", cornflowerblue: "#6495ed", burlywood: "#deb887", aquamarine: "#7fffd4", beige: "#f5f5dc", crimson: "#dc143c", cyan: "#00ffff", darkblue: "#00008b", darkcyan: "#008b8b", darkgoldenrod: "#b8860b", darkkhaki: "#bdb76b", darkgray: "#a9a9a9", darkgreen: "#006400", darkgrey: "#a9a9a9", peachpuff: "#ffdab9", darkmagenta: "#8b008b", darkred: "#8b0000", darkorchid: "#9932cc", darkorange: "#ff8c00", darkslateblue: "#483d8b", gray: "#808080", darkslategray: "#2f4f4f", darkslategrey: "#2f4f4f", deeppink: "#ff1493", deepskyblue: "#00bfff", wheat: "#f5deb3", firebrick: "#b22222", floralwhite: "#fffaf0", ghostwhite: "#f8f8ff", darkviolet: "#9400d3", magenta: "#ff00ff", green: "#008000", dodgerblue: "#1e90ff", grey: "#808080", honeydew: "#f0fff0", hotpink: "#ff69b4", blueviolet: "#8a2be2", forestgreen: "#228b22", lawngreen: "#7cfc00", indianred: "#cd5c5c", indigo: "#4b0082", fuchsia: "#ff00ff", brown: "#a52a2a", maroon: "#800000", mediumblue: "#0000cd", lightcoral: "#f08080", darkturquoise: "#00ced1", lightcyan: "#e0ffff", ivory: "#fffff0", lightyellow: "#ffffe0", lightsalmon: "#ffa07a", lightseagreen: "#20b2aa", linen: "#faf0e6", mediumaquamarine: "#66cdaa", lemonchiffon: "#fffacd", lime: "#00ff00", khaki: "#f0e68c", mediumseagreen: "#3cb371", limegreen: "#32cd32", mediumspringgreen: "#00fa9a", lightskyblue: "#87cefa", lightblue: "#add8e6", midnightblue: "#191970", lightpink: "#ffb6c1", mistyrose: "#ffe4e1", moccasin: "#ffe4b5", mintcream: "#f5fffa", lightslategray: "#778899", lightslategrey: "#778899", navajowhite: "#ffdead", navy: "#000080", mediumvioletred: "#c71585", powderblue: "#b0e0e6", palegoldenrod: "#eee8aa", oldlace: "#fdf5e6", paleturquoise: "#afeeee", mediumturquoise: "#48d1cc", mediumorchid: "#ba55d3", rebeccapurple: "#663399", lightsteelblue: "#b0c4de", mediumslateblue: "#7b68ee", thistle: "#d8bfd8", tan: "#d2b48c", orchid: "#da70d6", mediumpurple: "#9370db", purple: "#800080", pink: "#ffc0cb", skyblue: "#87ceeb", springgreen: "#00ff7f", palegreen: "#98fb98", red: "#ff0000", yellow: "#ffff00", slateblue: "#6a5acd", lavenderblush: "#fff0f5", peru: "#cd853f", palevioletred: "#db7093", violet: "#ee82ee", teal: "#008080", slategray: "#708090", slategrey: "#708090", aliceblue: "#f0f8ff", darkseagreen: "#8fbc8f", darkolivegreen: "#556b2f", greenyellow: "#adff2f", seagreen: "#2e8b57", seashell: "#fff5ee", tomato: "#ff6347", silver: "#c0c0c0", sienna: "#a0522d", lavender: "#e6e6fa", lightgreen: "#90ee90", orange: "#ffa500", orangered: "#ff4500", steelblue: "#4682b4", royalblue: "#4169e1", turquoise: "#40e0d0", yellowgreen: "#9acd32", salmon: "#fa8072", saddlebrown: "#8b4513", sandybrown: "#f4a460", rosybrown: "#bc8f8f", darksalmon: "#e9967a", lightgoldenrodyellow: "#fafad2", snow: "#fffafa", lightgrey: "#d3d3d3", lightgray: "#d3d3d3", dimgray: "#696969", dimgrey: "#696969", olivedrab: "#6b8e23", olive: "#808000" }, r2 = {};
|
|
6171
|
-
for (var d2 in a2) r2[a2[d2]] = d2;
|
|
6172
|
-
var l2 = {};
|
|
6173
|
-
e2.prototype.toName = function(f3) {
|
|
6174
|
-
if (!(this.rgba.a || this.rgba.r || this.rgba.g || this.rgba.b)) return "transparent";
|
|
6175
|
-
var d3, i2, n2 = r2[this.toHex()];
|
|
6176
|
-
if (n2) return n2;
|
|
6177
|
-
if (null == f3 ? void 0 : f3.closest) {
|
|
6178
|
-
var o2 = this.toRgb(), t2 = 1 / 0, b2 = "black";
|
|
6179
|
-
if (!l2.length) for (var c2 in a2) l2[c2] = new e2(a2[c2]).toRgb();
|
|
6180
|
-
for (var g2 in a2) {
|
|
6181
|
-
var u2 = (d3 = o2, i2 = l2[g2], Math.pow(d3.r - i2.r, 2) + Math.pow(d3.g - i2.g, 2) + Math.pow(d3.b - i2.b, 2));
|
|
6182
|
-
u2 < t2 && (t2 = u2, b2 = g2);
|
|
6183
|
-
}
|
|
6184
|
-
return b2;
|
|
6185
|
-
}
|
|
6186
|
-
};
|
|
6187
|
-
f2.string.push([function(f3) {
|
|
6188
|
-
var r3 = f3.toLowerCase(), d3 = "transparent" === r3 ? "#0000" : a2[r3];
|
|
6189
|
-
return d3 ? new e2(d3).toRgb() : null;
|
|
6190
|
-
}, "name"]);
|
|
6191
|
-
}
|
|
6192
|
-
|
|
6193
|
-
// ../../../node_modules/.pnpm/@wordpress+components@32.4.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/utils/colors.mjs
|
|
6194
|
-
var colorComputationNode;
|
|
6195
|
-
k([names_default]);
|
|
6196
|
-
function getColorComputationNode() {
|
|
6197
|
-
if (typeof document === "undefined") {
|
|
6198
|
-
return;
|
|
6199
|
-
}
|
|
6200
|
-
if (!colorComputationNode) {
|
|
6201
|
-
const el = document.createElement("div");
|
|
6202
|
-
el.setAttribute("data-g2-color-computation-node", "");
|
|
6203
|
-
document.body.appendChild(el);
|
|
6204
|
-
colorComputationNode = el;
|
|
6205
|
-
}
|
|
6206
|
-
return colorComputationNode;
|
|
6207
|
-
}
|
|
6208
|
-
function isColor(value) {
|
|
6209
|
-
if (typeof value !== "string") {
|
|
6210
|
-
return false;
|
|
6211
|
-
}
|
|
6212
|
-
const test = w(value);
|
|
6213
|
-
return test.isValid();
|
|
6214
|
-
}
|
|
6215
|
-
function _getComputedBackgroundColor(backgroundColor) {
|
|
6216
|
-
if (typeof backgroundColor !== "string") {
|
|
6217
|
-
return "";
|
|
6218
|
-
}
|
|
6219
|
-
if (isColor(backgroundColor)) {
|
|
6220
|
-
return backgroundColor;
|
|
6221
|
-
}
|
|
6222
|
-
if (!backgroundColor.includes("var(")) {
|
|
6223
|
-
return "";
|
|
6224
|
-
}
|
|
6225
|
-
if (typeof document === "undefined") {
|
|
6226
|
-
return "";
|
|
6227
|
-
}
|
|
6228
|
-
const el = getColorComputationNode();
|
|
6229
|
-
if (!el) {
|
|
6230
|
-
return "";
|
|
6231
|
-
}
|
|
6232
|
-
el.style.background = backgroundColor;
|
|
6233
|
-
const computedColor = _optionalChain([window, 'optionalAccess', _166 => _166.getComputedStyle, 'call', _167 => _167(el), 'access', _168 => _168.background]);
|
|
6234
|
-
el.style.background = "";
|
|
6235
|
-
return computedColor || "";
|
|
6236
|
-
}
|
|
6237
|
-
var getComputedBackgroundColor = memize(_getComputedBackgroundColor);
|
|
6238
|
-
function getOptimalTextColor(backgroundColor) {
|
|
6239
|
-
const background = getComputedBackgroundColor(backgroundColor);
|
|
6240
|
-
return w(background).isLight() ? "#000000" : "#ffffff";
|
|
6241
|
-
}
|
|
6242
|
-
function getOptimalTextShade(backgroundColor) {
|
|
6243
|
-
const result = getOptimalTextColor(backgroundColor);
|
|
6244
|
-
return result === "#000000" ? "dark" : "light";
|
|
6245
|
-
}
|
|
6246
|
-
|
|
6247
|
-
// ../../../node_modules/.pnpm/@wordpress+components@32.4.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/utils/colors-values.mjs
|
|
5907
|
+
// ../../../node_modules/.pnpm/@wordpress+components@32.5.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/utils/colors-values.mjs
|
|
6248
5908
|
var white = "#fff";
|
|
6249
5909
|
var GRAY = {
|
|
6250
5910
|
900: "#1e1e1e",
|
|
@@ -6325,7 +5985,7 @@ var COLORS = Object.freeze({
|
|
|
6325
5985
|
ui: UI
|
|
6326
5986
|
});
|
|
6327
5987
|
|
|
6328
|
-
// ../../../node_modules/.pnpm/@wordpress+components@32.
|
|
5988
|
+
// ../../../node_modules/.pnpm/@wordpress+components@32.5.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/utils/config-values.mjs
|
|
6329
5989
|
var CONTROL_HEIGHT = "36px";
|
|
6330
5990
|
var CONTROL_PROPS = {
|
|
6331
5991
|
// These values should be shared with TextControl.
|
|
@@ -6393,14 +6053,14 @@ var config_values_default = Object.assign({}, CONTROL_PROPS, {
|
|
|
6393
6053
|
transitionTimingFunctionControl: "cubic-bezier(0.12, 0.8, 0.32, 1)"
|
|
6394
6054
|
});
|
|
6395
6055
|
|
|
6396
|
-
// ../../../node_modules/.pnpm/@wordpress+components@32.
|
|
6397
|
-
var import_es6 =
|
|
6056
|
+
// ../../../node_modules/.pnpm/@wordpress+components@32.5.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/context/context-system-provider.mjs
|
|
6057
|
+
var import_es6 = _chunkDZUJEN5Ncjs.__toESM.call(void 0, require_es6(), 1);
|
|
6398
6058
|
|
|
6399
6059
|
|
|
6400
|
-
// ../../../node_modules/.pnpm/@wordpress+warning@3.
|
|
6060
|
+
// ../../../node_modules/.pnpm/@wordpress+warning@3.43.0/node_modules/@wordpress/warning/build-module/utils.mjs
|
|
6401
6061
|
var logged = /* @__PURE__ */ new Set();
|
|
6402
6062
|
|
|
6403
|
-
// ../../../node_modules/.pnpm/@wordpress+warning@3.
|
|
6063
|
+
// ../../../node_modules/.pnpm/@wordpress+warning@3.43.0/node_modules/@wordpress/warning/build-module/index.mjs
|
|
6404
6064
|
function isDev() {
|
|
6405
6065
|
return globalThis.SCRIPT_DEBUG === true;
|
|
6406
6066
|
}
|
|
@@ -6414,12 +6074,12 @@ function warning(message) {
|
|
|
6414
6074
|
console.warn(message);
|
|
6415
6075
|
try {
|
|
6416
6076
|
throw Error(message);
|
|
6417
|
-
} catch (
|
|
6077
|
+
} catch (x) {
|
|
6418
6078
|
}
|
|
6419
6079
|
logged.add(message);
|
|
6420
6080
|
}
|
|
6421
6081
|
|
|
6422
|
-
// ../../../node_modules/.pnpm/@wordpress+components@32.
|
|
6082
|
+
// ../../../node_modules/.pnpm/@wordpress+components@32.5.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/context/context-system-provider.mjs
|
|
6423
6083
|
|
|
6424
6084
|
var ComponentsContext = _react.createContext.call(void 0,
|
|
6425
6085
|
/** @type {Record<string, any>} */
|
|
@@ -6462,26 +6122,26 @@ var BaseContextSystemProvider = ({
|
|
|
6462
6122
|
};
|
|
6463
6123
|
var ContextSystemProvider = _react.memo.call(void 0, BaseContextSystemProvider);
|
|
6464
6124
|
|
|
6465
|
-
// ../../../node_modules/.pnpm/@wordpress+components@32.
|
|
6125
|
+
// ../../../node_modules/.pnpm/@wordpress+components@32.5.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/context/constants.mjs
|
|
6466
6126
|
var COMPONENT_NAMESPACE = "data-wp-component";
|
|
6467
6127
|
var CONNECTED_NAMESPACE = "data-wp-c16t";
|
|
6468
6128
|
var CONNECT_STATIC_NAMESPACE = "__contextSystemKey__";
|
|
6469
6129
|
|
|
6470
|
-
// ../../../node_modules/.pnpm/@wordpress+components@32.
|
|
6130
|
+
// ../../../node_modules/.pnpm/@wordpress+components@32.5.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/context/get-styled-class-name-from-key.mjs
|
|
6471
6131
|
function getStyledClassName(namespace) {
|
|
6472
6132
|
const kebab = paramCase(namespace);
|
|
6473
6133
|
return `components-${kebab}`;
|
|
6474
6134
|
}
|
|
6475
6135
|
var getStyledClassNameFromKey = memize(getStyledClassName);
|
|
6476
6136
|
|
|
6477
|
-
// ../../../node_modules/.pnpm/@wordpress+components@32.
|
|
6137
|
+
// ../../../node_modules/.pnpm/@wordpress+components@32.5.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/context/context-connect.mjs
|
|
6478
6138
|
function contextConnect(Component2, namespace) {
|
|
6479
6139
|
return _contextConnect(Component2, namespace, {
|
|
6480
6140
|
forwardsRef: true
|
|
6481
6141
|
});
|
|
6482
6142
|
}
|
|
6483
6143
|
function _contextConnect(Component2, namespace, options) {
|
|
6484
|
-
const WrappedComponent = _optionalChain([options, 'optionalAccess',
|
|
6144
|
+
const WrappedComponent = _optionalChain([options, 'optionalAccess', _166 => _166.forwardsRef]) ? _react.forwardRef.call(void 0, Component2) : Component2;
|
|
6485
6145
|
if (typeof namespace === "undefined") {
|
|
6486
6146
|
globalThis.SCRIPT_DEBUG === true ? warning("contextConnect: Please provide a namespace") : void 0;
|
|
6487
6147
|
}
|
|
@@ -6498,33 +6158,8 @@ function _contextConnect(Component2, namespace, options) {
|
|
|
6498
6158
|
selector: `.${getStyledClassNameFromKey(namespace)}`
|
|
6499
6159
|
});
|
|
6500
6160
|
}
|
|
6501
|
-
function getConnectNamespace(Component2) {
|
|
6502
|
-
if (!Component2) {
|
|
6503
|
-
return [];
|
|
6504
|
-
}
|
|
6505
|
-
let namespaces = [];
|
|
6506
|
-
if (Component2[CONNECT_STATIC_NAMESPACE]) {
|
|
6507
|
-
namespaces = Component2[CONNECT_STATIC_NAMESPACE];
|
|
6508
|
-
}
|
|
6509
|
-
if (Component2.type && Component2.type[CONNECT_STATIC_NAMESPACE]) {
|
|
6510
|
-
namespaces = Component2.type[CONNECT_STATIC_NAMESPACE];
|
|
6511
|
-
}
|
|
6512
|
-
return namespaces;
|
|
6513
|
-
}
|
|
6514
|
-
function hasConnectNamespace(Component2, match2) {
|
|
6515
|
-
if (!Component2) {
|
|
6516
|
-
return false;
|
|
6517
|
-
}
|
|
6518
|
-
if (typeof match2 === "string") {
|
|
6519
|
-
return getConnectNamespace(Component2).includes(match2);
|
|
6520
|
-
}
|
|
6521
|
-
if (Array.isArray(match2)) {
|
|
6522
|
-
return match2.some((result) => getConnectNamespace(Component2).includes(result));
|
|
6523
|
-
}
|
|
6524
|
-
return false;
|
|
6525
|
-
}
|
|
6526
6161
|
|
|
6527
|
-
// ../../../node_modules/.pnpm/@wordpress+components@32.
|
|
6162
|
+
// ../../../node_modules/.pnpm/@wordpress+components@32.5.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/context/utils.mjs
|
|
6528
6163
|
function getNamespace(componentName) {
|
|
6529
6164
|
return {
|
|
6530
6165
|
[COMPONENT_NAMESPACE]: componentName
|
|
@@ -6536,13 +6171,13 @@ function getConnectedNamespace() {
|
|
|
6536
6171
|
};
|
|
6537
6172
|
}
|
|
6538
6173
|
|
|
6539
|
-
// ../../../node_modules/.pnpm/@wordpress+components@32.
|
|
6174
|
+
// ../../../node_modules/.pnpm/@wordpress+components@32.5.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/context/use-context-system.mjs
|
|
6540
6175
|
function useContextSystem(props, namespace) {
|
|
6541
6176
|
const contextSystemProps = useComponentsContext();
|
|
6542
6177
|
if (typeof namespace === "undefined") {
|
|
6543
6178
|
globalThis.SCRIPT_DEBUG === true ? warning("useContextSystem: Please provide a namespace") : void 0;
|
|
6544
6179
|
}
|
|
6545
|
-
const contextProps = _optionalChain([contextSystemProps, 'optionalAccess',
|
|
6180
|
+
const contextProps = _optionalChain([contextSystemProps, 'optionalAccess', _167 => _167[namespace]]) || {};
|
|
6546
6181
|
const finalComponentProps = {
|
|
6547
6182
|
...getConnectedNamespace(),
|
|
6548
6183
|
...getNamespace(namespace)
|
|
@@ -6607,23 +6242,23 @@ var composeShouldForwardProps = function composeShouldForwardProps2(tag, options
|
|
|
6607
6242
|
}
|
|
6608
6243
|
return shouldForwardProp;
|
|
6609
6244
|
};
|
|
6610
|
-
var Insertion3 = function Insertion4(
|
|
6611
|
-
var cache2 =
|
|
6245
|
+
var Insertion3 = function Insertion4(_ref) {
|
|
6246
|
+
var cache2 = _ref.cache, serialized = _ref.serialized, isStringTag = _ref.isStringTag;
|
|
6612
6247
|
registerStyles(cache2, serialized, isStringTag);
|
|
6613
6248
|
var rules = useInsertionEffectAlwaysWithSyncFallback(function() {
|
|
6614
6249
|
return insertStyles(cache2, serialized, isStringTag);
|
|
6615
6250
|
});
|
|
6616
6251
|
if (!isBrowser5 && rules !== void 0) {
|
|
6617
|
-
var
|
|
6252
|
+
var _ref2;
|
|
6618
6253
|
var serializedNames = serialized.name;
|
|
6619
6254
|
var next2 = serialized.next;
|
|
6620
6255
|
while (next2 !== void 0) {
|
|
6621
6256
|
serializedNames += " " + next2.name;
|
|
6622
6257
|
next2 = next2.next;
|
|
6623
6258
|
}
|
|
6624
|
-
return /* @__PURE__ */ React8.createElement("style", (
|
|
6259
|
+
return /* @__PURE__ */ React8.createElement("style", (_ref2 = {}, _ref2["data-emotion"] = cache2.key + " " + serializedNames, _ref2.dangerouslySetInnerHTML = {
|
|
6625
6260
|
__html: rules
|
|
6626
|
-
},
|
|
6261
|
+
}, _ref2.nonce = cache2.sheet.nonce, _ref2));
|
|
6627
6262
|
}
|
|
6628
6263
|
return null;
|
|
6629
6264
|
};
|
|
@@ -6651,9 +6286,9 @@ var createStyled = function createStyled2(tag, options) {
|
|
|
6651
6286
|
var templateStringsArr = args[0];
|
|
6652
6287
|
styles.push(templateStringsArr[0]);
|
|
6653
6288
|
var len = args.length;
|
|
6654
|
-
var
|
|
6655
|
-
for (;
|
|
6656
|
-
styles.push(args[
|
|
6289
|
+
var i = 1;
|
|
6290
|
+
for (; i < len; i++) {
|
|
6291
|
+
styles.push(args[i], templateStringsArr[i]);
|
|
6657
6292
|
}
|
|
6658
6293
|
}
|
|
6659
6294
|
var Styled = withEmotionCache(function(props, cache2, ref) {
|
|
@@ -6720,7 +6355,7 @@ var createStyled = function createStyled2(tag, options) {
|
|
|
6720
6355
|
};
|
|
6721
6356
|
};
|
|
6722
6357
|
|
|
6723
|
-
// ../../../node_modules/.pnpm/@wordpress+components@32.
|
|
6358
|
+
// ../../../node_modules/.pnpm/@wordpress+components@32.5.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/view/component.mjs
|
|
6724
6359
|
|
|
6725
6360
|
var PolymorphicDiv = /* @__PURE__ */ createStyled("div", process.env.NODE_ENV === "production" ? {
|
|
6726
6361
|
target: "e19lxcc00"
|
|
@@ -6743,7 +6378,7 @@ var View = Object.assign(_react.forwardRef.call(void 0, UnforwardedView), {
|
|
|
6743
6378
|
});
|
|
6744
6379
|
var component_default = View;
|
|
6745
6380
|
|
|
6746
|
-
// ../../../node_modules/.pnpm/@wordpress+components@32.
|
|
6381
|
+
// ../../../node_modules/.pnpm/@wordpress+components@32.5.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/utils/use-responsive-value.mjs
|
|
6747
6382
|
var breakpoints = ["40em", "52em", "64em"];
|
|
6748
6383
|
var useBreakpointIndex = (options = {}) => {
|
|
6749
6384
|
const {
|
|
@@ -6786,429 +6421,7 @@ function useResponsiveValue(values, options = {}) {
|
|
|
6786
6421
|
return array[index >= array.length ? array.length - 1 : index];
|
|
6787
6422
|
}
|
|
6788
6423
|
|
|
6789
|
-
// ../../../node_modules/.pnpm/@wordpress+components@32.
|
|
6790
|
-
var GRID_BASE = "4px";
|
|
6791
|
-
function space(value) {
|
|
6792
|
-
if (typeof value === "undefined") {
|
|
6793
|
-
return void 0;
|
|
6794
|
-
}
|
|
6795
|
-
if (!value) {
|
|
6796
|
-
return "0";
|
|
6797
|
-
}
|
|
6798
|
-
const asInt = typeof value === "number" ? value : Number(value);
|
|
6799
|
-
if (typeof window !== "undefined" && _optionalChain([window, 'access', _171 => _171.CSS, 'optionalAccess', _172 => _172.supports, 'optionalCall', _173 => _173("margin", value.toString())]) || Number.isNaN(asInt)) {
|
|
6800
|
-
return value.toString();
|
|
6801
|
-
}
|
|
6802
|
-
return `calc(${GRID_BASE} * ${value})`;
|
|
6803
|
-
}
|
|
6804
|
-
|
|
6805
|
-
// ../../../node_modules/.pnpm/@wordpress+components@32.4.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/truncate/styles.mjs
|
|
6806
|
-
function _EMOTION_STRINGIFIED_CSS_ERROR__() {
|
|
6807
|
-
return "You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop).";
|
|
6808
|
-
}
|
|
6809
|
-
var Truncate = process.env.NODE_ENV === "production" ? {
|
|
6810
|
-
name: "hdknak",
|
|
6811
|
-
styles: "display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap"
|
|
6812
|
-
} : {
|
|
6813
|
-
name: "abxxyf-Truncate",
|
|
6814
|
-
styles: "display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;label:Truncate;/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInN0eWxlcy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFLMkIiLCJmaWxlIjoic3R5bGVzLnRzIiwic291cmNlc0NvbnRlbnQiOlsiLyoqXG4gKiBFeHRlcm5hbCBkZXBlbmRlbmNpZXNcbiAqL1xuaW1wb3J0IHsgY3NzIH0gZnJvbSAnQGVtb3Rpb24vcmVhY3QnO1xuXG5leHBvcnQgY29uc3QgVHJ1bmNhdGUgPSBjc3NgXG5cdGRpc3BsYXk6IGJsb2NrO1xuXHRvdmVyZmxvdzogaGlkZGVuO1xuXHR0ZXh0LW92ZXJmbG93OiBlbGxpcHNpcztcblx0d2hpdGUtc3BhY2U6IG5vd3JhcDtcbmA7XG4iXX0= */",
|
|
6815
|
-
toString: _EMOTION_STRINGIFIED_CSS_ERROR__
|
|
6816
|
-
};
|
|
6817
|
-
|
|
6818
|
-
// ../../../node_modules/.pnpm/@wordpress+components@32.4.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/truncate/utils.mjs
|
|
6819
|
-
var TRUNCATE_ELLIPSIS = "\u2026";
|
|
6820
|
-
var TRUNCATE_TYPE = {
|
|
6821
|
-
auto: "auto",
|
|
6822
|
-
head: "head",
|
|
6823
|
-
middle: "middle",
|
|
6824
|
-
tail: "tail",
|
|
6825
|
-
none: "none"
|
|
6826
|
-
};
|
|
6827
|
-
var TRUNCATE_DEFAULT_PROPS = {
|
|
6828
|
-
ellipsis: TRUNCATE_ELLIPSIS,
|
|
6829
|
-
ellipsizeMode: TRUNCATE_TYPE.auto,
|
|
6830
|
-
limit: 0,
|
|
6831
|
-
numberOfLines: 0
|
|
6832
|
-
};
|
|
6833
|
-
function truncateMiddle(word, headLength, tailLength, ellipsis) {
|
|
6834
|
-
if (typeof word !== "string") {
|
|
6835
|
-
return "";
|
|
6836
|
-
}
|
|
6837
|
-
const wordLength = word.length;
|
|
6838
|
-
const frontLength = ~~headLength;
|
|
6839
|
-
const backLength = ~~tailLength;
|
|
6840
|
-
const truncateStr = isValueDefined(ellipsis) ? ellipsis : TRUNCATE_ELLIPSIS;
|
|
6841
|
-
if (frontLength === 0 && backLength === 0 || frontLength >= wordLength || backLength >= wordLength || frontLength + backLength >= wordLength) {
|
|
6842
|
-
return word;
|
|
6843
|
-
} else if (backLength === 0) {
|
|
6844
|
-
return word.slice(0, frontLength) + truncateStr;
|
|
6845
|
-
}
|
|
6846
|
-
return word.slice(0, frontLength) + truncateStr + word.slice(wordLength - backLength);
|
|
6847
|
-
}
|
|
6848
|
-
function truncateContent(words = "", props) {
|
|
6849
|
-
const mergedProps = {
|
|
6850
|
-
...TRUNCATE_DEFAULT_PROPS,
|
|
6851
|
-
...props
|
|
6852
|
-
};
|
|
6853
|
-
const {
|
|
6854
|
-
ellipsis,
|
|
6855
|
-
ellipsizeMode,
|
|
6856
|
-
limit
|
|
6857
|
-
} = mergedProps;
|
|
6858
|
-
if (ellipsizeMode === TRUNCATE_TYPE.none) {
|
|
6859
|
-
return words;
|
|
6860
|
-
}
|
|
6861
|
-
let truncateHead;
|
|
6862
|
-
let truncateTail;
|
|
6863
|
-
switch (ellipsizeMode) {
|
|
6864
|
-
case TRUNCATE_TYPE.head:
|
|
6865
|
-
truncateHead = 0;
|
|
6866
|
-
truncateTail = limit;
|
|
6867
|
-
break;
|
|
6868
|
-
case TRUNCATE_TYPE.middle:
|
|
6869
|
-
truncateHead = Math.floor(limit / 2);
|
|
6870
|
-
truncateTail = Math.floor(limit / 2);
|
|
6871
|
-
break;
|
|
6872
|
-
default:
|
|
6873
|
-
truncateHead = limit;
|
|
6874
|
-
truncateTail = 0;
|
|
6875
|
-
}
|
|
6876
|
-
const truncatedContent = ellipsizeMode !== TRUNCATE_TYPE.auto ? truncateMiddle(words, truncateHead, truncateTail, ellipsis) : words;
|
|
6877
|
-
return truncatedContent;
|
|
6878
|
-
}
|
|
6879
|
-
|
|
6880
|
-
// ../../../node_modules/.pnpm/@wordpress+components@32.4.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/truncate/hook.mjs
|
|
6881
|
-
function useTruncate(props) {
|
|
6882
|
-
const {
|
|
6883
|
-
className,
|
|
6884
|
-
children,
|
|
6885
|
-
ellipsis = TRUNCATE_ELLIPSIS,
|
|
6886
|
-
ellipsizeMode = TRUNCATE_TYPE.auto,
|
|
6887
|
-
limit = 0,
|
|
6888
|
-
numberOfLines = 0,
|
|
6889
|
-
...otherProps
|
|
6890
|
-
} = useContextSystem(props, "Truncate");
|
|
6891
|
-
const cx2 = useCx();
|
|
6892
|
-
let childrenAsText;
|
|
6893
|
-
if (typeof children === "string") {
|
|
6894
|
-
childrenAsText = children;
|
|
6895
|
-
} else if (typeof children === "number") {
|
|
6896
|
-
childrenAsText = children.toString();
|
|
6897
|
-
}
|
|
6898
|
-
const truncatedContent = childrenAsText ? truncateContent(childrenAsText, {
|
|
6899
|
-
ellipsis,
|
|
6900
|
-
ellipsizeMode,
|
|
6901
|
-
limit,
|
|
6902
|
-
numberOfLines
|
|
6903
|
-
}) : children;
|
|
6904
|
-
const shouldTruncate = !!childrenAsText && ellipsizeMode === TRUNCATE_TYPE.auto;
|
|
6905
|
-
const classes = _react.useMemo.call(void 0, () => {
|
|
6906
|
-
const truncateLines = /* @__PURE__ */ css(numberOfLines === 1 ? "word-break: break-all;" : "", " -webkit-box-orient:vertical;-webkit-line-clamp:", numberOfLines, ";display:-webkit-box;overflow:hidden;" + (process.env.NODE_ENV === "production" ? "" : ";label:truncateLines;"), process.env.NODE_ENV === "production" ? "" : "/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbImhvb2sudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBMEQyQiIsImZpbGUiOiJob29rLnRzIiwic291cmNlc0NvbnRlbnQiOlsiLyoqXG4gKiBFeHRlcm5hbCBkZXBlbmRlbmNpZXNcbiAqL1xuaW1wb3J0IHsgY3NzIH0gZnJvbSAnQGVtb3Rpb24vcmVhY3QnO1xuXG4vKipcbiAqIFdvcmRQcmVzcyBkZXBlbmRlbmNpZXNcbiAqL1xuaW1wb3J0IHsgdXNlTWVtbyB9IGZyb20gJ0B3b3JkcHJlc3MvZWxlbWVudCc7XG5cbi8qKlxuICogSW50ZXJuYWwgZGVwZW5kZW5jaWVzXG4gKi9cbmltcG9ydCB0eXBlIHsgV29yZFByZXNzQ29tcG9uZW50UHJvcHMgfSBmcm9tICcuLi9jb250ZXh0JztcbmltcG9ydCB7IHVzZUNvbnRleHRTeXN0ZW0gfSBmcm9tICcuL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2F0ZSAmJiAhIG51bWJlck9mTGluZXMgJiYgc3R5bGVzLlRydW5jYXRlLFxuXHRcdFx0c2hvdWxkVHJ1bmNhdGUgJiYgISEgbnVtYmVyT2ZMaW5lcyAmJiB0cnVuY2F0ZUxpbmVzLFxuXHRcdFx0Y2xhc3NOYW1lXG5cdFx0KTtcblx0fSwgWyBjbGFzc05hbWUsIGN4LCBudW1iZXJPZkxpbmVzLCBzaG91bGRUcnVuY2F0ZSBdICk7XG5cblx0cmV0dXJuIHsgLi4ub3RoZXJQcm9wcywgY2xhc3NOYW1lOiBjbGFzc2VzLCBjaGlsZHJlbjogdHJ1bmNhdGVkQ29udGVudCB9O1xufVxuIl19 */");
|
|
6907
|
-
return cx2(shouldTruncate && !numberOfLines && Truncate, shouldTruncate && !!numberOfLines && truncateLines, className);
|
|
6908
|
-
}, [className, cx2, numberOfLines, shouldTruncate]);
|
|
6909
|
-
return {
|
|
6910
|
-
...otherProps,
|
|
6911
|
-
className: classes,
|
|
6912
|
-
children: truncatedContent
|
|
6913
|
-
};
|
|
6914
|
-
}
|
|
6915
|
-
|
|
6916
|
-
// ../../../node_modules/.pnpm/@wordpress+components@32.4.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/text/styles.mjs
|
|
6917
|
-
var styles_exports2 = {};
|
|
6918
|
-
_chunkEMMSS5I5cjs.__export.call(void 0, styles_exports2, {
|
|
6919
|
-
Text: () => Text2,
|
|
6920
|
-
block: () => block,
|
|
6921
|
-
destructive: () => destructive,
|
|
6922
|
-
highlighterText: () => highlighterText,
|
|
6923
|
-
muted: () => muted,
|
|
6924
|
-
positive: () => positive,
|
|
6925
|
-
upperCase: () => upperCase
|
|
6926
|
-
});
|
|
6927
|
-
function _EMOTION_STRINGIFIED_CSS_ERROR__2() {
|
|
6928
|
-
return "You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop).";
|
|
6929
|
-
}
|
|
6930
|
-
var Text2 = /* @__PURE__ */ css("color:", COLORS.theme.foreground, ";line-height:", config_values_default.fontLineHeightBase, ";margin:0;text-wrap:pretty;" + (process.env.NODE_ENV === "production" ? "" : ";label:Text;"), process.env.NODE_ENV === "production" ? "" : "/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInN0eWxlcy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFVdUIiLCJmaWxlIjoic3R5bGVzLnRzIiwic291cmNlc0NvbnRlbnQiOlsiLyoqXG4gKiBFeHRlcm5hbCBkZXBlbmRlbmNpZXNcbiAqL1xuaW1wb3J0IHsgY3NzIH0gZnJvbSAnQGVtb3Rpb24vcmVhY3QnO1xuXG4vKipcbiAqIEludGVybmFsIGRlcGVuZGVuY2llc1xuICovXG5pbXBvcnQgeyBDT0xPUlMsIENPTkZJRyB9IGZyb20gJy4uL3V0aWxzJztcblxuZXhwb3J0IGNvbnN0IFRleHQgPSBjc3NgXG5cdGNvbG9yOiAkeyBDT0xPUlMudGhlbWUuZm9yZWdyb3VuZCB9O1xuXHRsaW5lLWhlaWdodDogJHsgQ09ORklHLmZvbnRMaW5lSGVpZ2h0QmFzZSB9O1xuXHRtYXJnaW46IDA7XG5cdHRleHQtd3JhcDogcHJldHR5O1xuYDtcblxuZXhwb3J0IGNvbnN0IGJsb2NrID0gY3NzYFxuXHRkaXNwbGF5OiBibG9jaztcbmA7XG5cbmV4cG9ydCBjb25zdCBwb3NpdGl2ZSA9IGNzc2Bcblx0Y29sb3I6ICR7IENPTE9SUy5hbGVydC5ncmVlbiB9O1xuYDtcblxuZXhwb3J0IGNvbnN0IGRlc3RydWN0aXZlID0gY3NzYFxuXHRjb2xvcjogJHsgQ09MT1JTLmFsZXJ0LnJlZCB9O1xuYDtcblxuZXhwb3J0IGNvbnN0IG11dGVkID0gY3NzYFxuXHRjb2xvcjogJHsgQ09MT1JTLmdyYXlbIDcwMCBdIH07XG5gO1xuXG5leHBvcnQgY29uc3QgaGlnaGxpZ2h0ZXJUZXh0ID0gY3NzYFxuXHRtYXJrIHtcblx0XHRiYWNrZ3JvdW5kOiAkeyBDT0xPUlMuYWxlcnQueWVsbG93IH07XG5cdFx0Ym9yZGVyLXJhZGl1czogJHsgQ09ORklHLnJhZGl1c1NtYWxsIH07XG5cdFx0Ym94LXNoYWRvdzpcblx0XHRcdDAgMCAwIDFweCByZ2JhKCAwLCAwLCAwLCAwLjA1ICkgaW5zZXQsXG5cdFx0XHQwIC0xcHggMCByZ2JhKCAwLCAwLCAwLCAwLjEgKSBpbnNldDtcblx0fVxuYDtcblxuZXhwb3J0IGNvbnN0IHVwcGVyQ2FzZSA9IGNzc2Bcblx0dGV4dC10cmFuc2Zvcm06IHVwcGVyY2FzZTtcbmA7XG4iXX0= */");
|
|
6931
|
-
var block = process.env.NODE_ENV === "production" ? {
|
|
6932
|
-
name: "4zleql",
|
|
6933
|
-
styles: "display:block"
|
|
6934
|
-
} : {
|
|
6935
|
-
name: "14aceuy-block",
|
|
6936
|
-
styles: "display:block;label:block;/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInN0eWxlcy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFpQndCIiwiZmlsZSI6InN0eWxlcy50cyIsInNvdXJjZXNDb250ZW50IjpbIi8qKlxuICogRXh0ZXJuYWwgZGVwZW5kZW5jaWVzXG4gKi9cbmltcG9ydCB7IGNzcyB9IGZyb20gJ0BlbW90aW9uL3JlYWN0JztcblxuLyoqXG4gKiBJbnRlcm5hbCBkZXBlbmRlbmNpZXNcbiAqL1xuaW1wb3J0IHsgQ09MT1JTLCBDT05GSUcgfSBmcm9tICcuLi91dGlscyc7XG5cbmV4cG9ydCBjb25zdCBUZXh0ID0gY3NzYFxuXHRjb2xvcjogJHsgQ09MT1JTLnRoZW1lLmZvcmVncm91bmQgfTtcblx0bGluZS1oZWlnaHQ6ICR7IENPTkZJRy5mb250TGluZUhlaWdodEJhc2UgfTtcblx0bWFyZ2luOiAwO1xuXHR0ZXh0LXdyYXA6IHByZXR0eTtcbmA7XG5cbmV4cG9ydCBjb25zdCBibG9jayA9IGNzc2Bcblx0ZGlzcGxheTogYmxvY2s7XG5gO1xuXG5leHBvcnQgY29uc3QgcG9zaXRpdmUgPSBjc3NgXG5cdGNvbG9yOiAkeyBDT0xPUlMuYWxlcnQuZ3JlZW4gfTtcbmA7XG5cbmV4cG9ydCBjb25zdCBkZXN0cnVjdGl2ZSA9IGNzc2Bcblx0Y29sb3I6ICR7IENPTE9SUy5hbGVydC5yZWQgfTtcbmA7XG5cbmV4cG9ydCBjb25zdCBtdXRlZCA9IGNzc2Bcblx0Y29sb3I6ICR7IENPTE9SUy5ncmF5WyA3MDAgXSB9O1xuYDtcblxuZXhwb3J0IGNvbnN0IGhpZ2hsaWdodGVyVGV4dCA9IGNzc2Bcblx0bWFyayB7XG5cdFx0YmFja2dyb3VuZDogJHsgQ09MT1JTLmFsZXJ0LnllbGxvdyB9O1xuXHRcdGJvcmRlci1yYWRpdXM6ICR7IENPTkZJRy5yYWRpdXNTbWFsbCB9O1xuXHRcdGJveC1zaGFkb3c6XG5cdFx0XHQwIDAgMCAxcHggcmdiYSggMCwgMCwgMCwgMC4wNSApIGluc2V0LFxuXHRcdFx0MCAtMXB4IDAgcmdiYSggMCwgMCwgMCwgMC4xICkgaW5zZXQ7XG5cdH1cbmA7XG5cbmV4cG9ydCBjb25zdCB1cHBlckNhc2UgPSBjc3NgXG5cdHRleHQtdHJhbnNmb3JtOiB1cHBlcmNhc2U7XG5gO1xuIl19 */",
|
|
6937
|
-
toString: _EMOTION_STRINGIFIED_CSS_ERROR__2
|
|
6938
|
-
};
|
|
6939
|
-
var positive = /* @__PURE__ */ css("color:", COLORS.alert.green, ";" + (process.env.NODE_ENV === "production" ? "" : ";label:positive;"), process.env.NODE_ENV === "production" ? "" : "/*#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JvcmRlci1yYWRpdXM6ICR7IENPTkZJRy5yYWRpdXNTbWFsbCB9O1xuXHRcdGJveC1zaGFkb3c6XG5cdFx0XHQwIDAgMCAxcHggcmdiYSggMCwgMCwgMCwgMC4wNSApIGluc2V0LFxuXHRcdFx0MCAtMXB4IDAgcmdiYSggMCwgMCwgMCwgMC4xICkgaW5zZXQ7XG5cdH1cbmA7XG5cbmV4cG9ydCBjb25zdCB1cHBlckNhc2UgPSBjc3NgXG5cdHRleHQtdHJhbnNmb3JtOiB1cHBlcmNhc2U7XG5gO1xuIl19 */");
|
|
6940
|
-
var destructive = /* @__PURE__ */ css("color:", COLORS.alert.red, ";" + (process.env.NODE_ENV === "production" ? "" : ";label:destructive;"), process.env.NODE_ENV === "production" ? "" : "/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInN0eWxlcy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUF5QjhCIiwiZmlsZSI6InN0eWxlcy50cyIsInNvdXJjZXNDb250ZW50IjpbIi8qKlxuICogRXh0ZXJuYWwgZGVwZW5kZW5jaWVzXG4gKi9cbmltcG9ydCB7IGNzcyB9IGZyb20gJ0BlbW90aW9uL3JlYWN0JztcblxuLyoqXG4gKiBJbnRlcm5hbCBkZXBlbmRlbmNpZXNcbiAqL1xuaW1wb3J0IHsgQ09MT1JTLCBDT05GSUcgfSBmcm9tICcuLi91dGlscyc7XG5cbmV4cG9ydCBjb25zdCBUZXh0ID0gY3NzYFxuXHRjb2xvcjogJHsgQ09MT1JTLnRoZW1lLmZvcmVncm91bmQgfTtcblx0bGluZS1oZWlnaHQ6ICR7IENPTkZJRy5mb250TGluZUhlaWdodEJhc2UgfTtcblx0bWFyZ2luOiAwO1xuXHR0ZXh0LXdyYXA6IHByZXR0eTtcbmA7XG5cbmV4cG9ydCBjb25zdCBibG9jayA9IGNzc2Bcblx0ZGlzcGxheTogYmxvY2s7XG5gO1xuXG5leHBvcnQgY29uc3QgcG9zaXRpdmUgPSBjc3NgXG5cdGNvbG9yOiAkeyBDT0xPUlMuYWxlcnQuZ3JlZW4gfTtcbmA7XG5cbmV4cG9ydCBjb25zdCBkZXN0cnVjdGl2ZSA9IGNzc2Bcblx0Y29sb3I6ICR7IENPTE9SUy5hbGVydC5yZWQgfTtcbmA7XG5cbmV4cG9ydCBjb25zdCBtdXRlZCA9IGNzc2Bcblx0Y29sb3I6ICR7IENPTE9SUy5ncmF5WyA3MDAgXSB9O1xuYDtcblxuZXhwb3J0IGNvbnN0IGhpZ2hsaWdodGVyVGV4dCA9IGNzc2Bcblx0bWFyayB7XG5cdFx0YmFja2dyb3VuZDogJHsgQ09MT1JTLmFsZXJ0LnllbGxvdyB9O1xuXHRcdGJvcmRlci1yYWRpdXM6ICR7IENPTkZJRy5yYWRpdXNTbWFsbCB9O1xuXHRcdGJveC1zaGFkb3c6XG5cdFx0XHQwIDAgMCAxcHggcmdiYSggMCwgMCwgMCwgMC4wNSApIGluc2V0LFxuXHRcdFx0MCAtMXB4IDAgcmdiYSggMCwgMCwgMCwgMC4xICkgaW5zZXQ7XG5cdH1cbmA7XG5cbmV4cG9ydCBjb25zdCB1cHBlckNhc2UgPSBjc3NgXG5cdHRleHQtdHJhbnNmb3JtOiB1cHBlcmNhc2U7XG5gO1xuIl19 */");
|
|
6941
|
-
var muted = /* @__PURE__ */ css("color:", COLORS.gray[700], ";" + (process.env.NODE_ENV === "production" ? "" : ";label:muted;"), process.env.NODE_ENV === "production" ? "" : "/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInN0eWxlcy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUE2QndCIiwiZmlsZSI6InN0eWxlcy50cyIsInNvdXJjZXNDb250ZW50IjpbIi8qKlxuICogRXh0ZXJuYWwgZGVwZW5kZW5jaWVzXG4gKi9cbmltcG9ydCB7IGNzcyB9IGZyb20gJ0Bl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3NgXG5cdHRleHQtdHJhbnNmb3JtOiB1cHBlcmNhc2U7XG5gO1xuIl19 */");
|
|
6942
|
-
var highlighterText = /* @__PURE__ */ css("mark{background:", COLORS.alert.yellow, ";border-radius:", config_values_default.radiusSmall, ";box-shadow:0 0 0 1px rgba( 0, 0, 0, 0.05 ) inset,0 -1px 0 rgba( 0, 0, 0, 0.1 ) inset;}" + (process.env.NODE_ENV === "production" ? "" : ";label:highlighterText;"), process.env.NODE_ENV === "production" ? "" : "/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInN0eWxlcy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFpQ2tDIiwiZmlsZSI6InN0eWxlcy50cyIsInNvdXJjZXNDb250ZW50IjpbIi8qKlxuICogRXh0ZXJuYWwgZGVwZW5kZW5jaWVzXG4gKi9cbmltcG9ydCB7IGNzcyB9IGZyb20gJ0BlbW90aW9uL3JlYWN0JztcblxuLyoqXG4gKiBJbnRlcm5hbCBkZXBlbmRlbmNpZXNcbiAqL1xuaW1wb3J0IHsgQ09MT1JTLCBDT05GSUcgfSBmcm9tICcuLi91dGlscyc7XG5cbmV4cG9ydCBjb25zdCBUZXh0ID0gY3NzYFxuXHRjb2xvcjogJHsgQ09MT1JTLnRoZW1lLmZvcmVncm91bmQgfTtcblx0bGluZS1oZWlnaHQ6ICR7IENPTkZJRy5mb250TGluZUhlaWdodEJhc2UgfTtcblx0bWFyZ2luOiAwO1xuXHR0ZXh0LXdyYXA6IHByZXR0eTtcbmA7XG5cbmV4cG9ydCBjb25zdCBibG9jayA9IGNzc2Bcblx0ZGlzcGxheTogYmxvY2s7XG5gO1xuXG5leHBvcnQgY29uc3QgcG9zaXRpdmUgPSBjc3NgXG5cdGNvbG9yOiAkeyBDT0xPUlMuYWxlcnQuZ3JlZW4gfTtcbmA7XG5cbmV4cG9ydCBjb25zdCBkZXN0cnVjdGl2ZSA9IGNzc2Bcblx0Y29sb3I6ICR7IENPTE9SUy5hbGVydC5yZWQgfTtcbmA7XG5cbmV4cG9ydCBjb25zdCBtdXRlZCA9IGNzc2Bcblx0Y29sb3I6ICR7IENPTE9SUy5ncmF5WyA3MDAgXSB9O1xuYDtcblxuZXhwb3J0IGNvbnN0IGhpZ2hsaWdodGVyVGV4dCA9IGNzc2Bcblx0bWFyayB7XG5cdFx0YmFja2dyb3VuZDogJHsgQ09MT1JTLmFsZXJ0LnllbGxvdyB9O1xuXHRcdGJvcmRlci1yYWRpdXM6ICR7IENPTkZJRy5yYWRpdXNTbWFsbCB9O1xuXHRcdGJveC1zaGFkb3c6XG5cdFx0XHQwIDAgMCAxcHggcmdiYSggMCwgMCwgMCwgMC4wNSApIGluc2V0LFxuXHRcdFx0MCAtMXB4IDAgcmdiYSggMCwgMCwgMCwgMC4xICkgaW5zZXQ7XG5cdH1cbmA7XG5cbmV4cG9ydCBjb25zdCB1cHBlckNhc2UgPSBjc3NgXG5cdHRleHQtdHJhbnNmb3JtOiB1cHBlcmNhc2U7XG5gO1xuIl19 */");
|
|
6943
|
-
var upperCase = process.env.NODE_ENV === "production" ? {
|
|
6944
|
-
name: "50zrmy",
|
|
6945
|
-
styles: "text-transform:uppercase"
|
|
6946
|
-
} : {
|
|
6947
|
-
name: "1mrt3zt-upperCase",
|
|
6948
|
-
styles: "text-transform:uppercase;label:upperCase;/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbInN0eWxlcy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUEyQzRCIiwiZmlsZSI6InN0eWxlcy50cyIsInNvdXJjZXNDb250ZW50IjpbIi8qKlxuICogRXh0ZXJuYWwgZGVwZW5kZW5jaWVzXG4gKi9cbmltcG9ydCB7IGNzcyB9IGZyb20gJ0BlbW90aW9uL3JlYWN0JztcblxuLyoqXG4gKiBJbnRlcm5hbCBkZXBlbmRlbmNpZXNcbiAqL1xuaW1wb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OTION_STRINGIFIED_CSS_ERROR__2
|
|
6950
|
-
};
|
|
6951
|
-
|
|
6952
|
-
// ../../../node_modules/.pnpm/@wordpress+components@32.4.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/text/utils.mjs
|
|
6953
|
-
var import_highlight_words_core = _chunkEMMSS5I5cjs.__toESM.call(void 0, require_dist(), 1);
|
|
6954
|
-
var lowercaseProps = (object) => {
|
|
6955
|
-
const mapped = {};
|
|
6956
|
-
for (const key in object) {
|
|
6957
|
-
mapped[key.toLowerCase()] = object[key];
|
|
6958
|
-
}
|
|
6959
|
-
return mapped;
|
|
6960
|
-
};
|
|
6961
|
-
var memoizedLowercaseProps = memize(lowercaseProps);
|
|
6962
|
-
function createHighlighterText({
|
|
6963
|
-
activeClassName = "",
|
|
6964
|
-
activeIndex = -1,
|
|
6965
|
-
activeStyle,
|
|
6966
|
-
autoEscape,
|
|
6967
|
-
caseSensitive = false,
|
|
6968
|
-
children,
|
|
6969
|
-
findChunks,
|
|
6970
|
-
highlightClassName = "",
|
|
6971
|
-
highlightStyle = {},
|
|
6972
|
-
highlightTag = "mark",
|
|
6973
|
-
sanitize,
|
|
6974
|
-
searchWords = [],
|
|
6975
|
-
unhighlightClassName = "",
|
|
6976
|
-
unhighlightStyle
|
|
6977
|
-
}) {
|
|
6978
|
-
if (!children) {
|
|
6979
|
-
return null;
|
|
6980
|
-
}
|
|
6981
|
-
if (typeof children !== "string") {
|
|
6982
|
-
return children;
|
|
6983
|
-
}
|
|
6984
|
-
const textToHighlight = children;
|
|
6985
|
-
const chunks = (0, import_highlight_words_core.findAll)({
|
|
6986
|
-
autoEscape,
|
|
6987
|
-
caseSensitive,
|
|
6988
|
-
findChunks,
|
|
6989
|
-
sanitize,
|
|
6990
|
-
searchWords,
|
|
6991
|
-
textToHighlight
|
|
6992
|
-
});
|
|
6993
|
-
const HighlightTag = highlightTag;
|
|
6994
|
-
let highlightIndex = -1;
|
|
6995
|
-
let highlightClassNames = "";
|
|
6996
|
-
let highlightStyles;
|
|
6997
|
-
const textContent = chunks.map((chunk, index) => {
|
|
6998
|
-
const text = textToHighlight.substr(chunk.start, chunk.end - chunk.start);
|
|
6999
|
-
if (chunk.highlight) {
|
|
7000
|
-
highlightIndex++;
|
|
7001
|
-
let highlightClass;
|
|
7002
|
-
if (typeof highlightClassName === "object") {
|
|
7003
|
-
if (!caseSensitive) {
|
|
7004
|
-
highlightClassName = memoizedLowercaseProps(highlightClassName);
|
|
7005
|
-
highlightClass = highlightClassName[text.toLowerCase()];
|
|
7006
|
-
} else {
|
|
7007
|
-
highlightClass = highlightClassName[text];
|
|
7008
|
-
}
|
|
7009
|
-
} else {
|
|
7010
|
-
highlightClass = highlightClassName;
|
|
7011
|
-
}
|
|
7012
|
-
const isActive = highlightIndex === +activeIndex;
|
|
7013
|
-
highlightClassNames = `${highlightClass} ${isActive ? activeClassName : ""}`;
|
|
7014
|
-
highlightStyles = isActive === true && activeStyle !== null ? Object.assign({}, highlightStyle, activeStyle) : highlightStyle;
|
|
7015
|
-
const props = {
|
|
7016
|
-
children: text,
|
|
7017
|
-
className: highlightClassNames,
|
|
7018
|
-
key: index,
|
|
7019
|
-
style: highlightStyles
|
|
7020
|
-
};
|
|
7021
|
-
if (typeof HighlightTag !== "string") {
|
|
7022
|
-
props.highlightIndex = highlightIndex;
|
|
7023
|
-
}
|
|
7024
|
-
return _react.createElement.call(void 0, HighlightTag, props);
|
|
7025
|
-
}
|
|
7026
|
-
return _react.createElement.call(void 0, "span", {
|
|
7027
|
-
children: text,
|
|
7028
|
-
className: unhighlightClassName,
|
|
7029
|
-
key: index,
|
|
7030
|
-
style: unhighlightStyle
|
|
7031
|
-
});
|
|
7032
|
-
});
|
|
7033
|
-
return textContent;
|
|
7034
|
-
}
|
|
7035
|
-
|
|
7036
|
-
// ../../../node_modules/.pnpm/@wordpress+components@32.4.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/utils/font-size.mjs
|
|
7037
|
-
var BASE_FONT_SIZE = 13;
|
|
7038
|
-
var PRESET_FONT_SIZES = {
|
|
7039
|
-
body: BASE_FONT_SIZE,
|
|
7040
|
-
caption: 10,
|
|
7041
|
-
footnote: 11,
|
|
7042
|
-
largeTitle: 28,
|
|
7043
|
-
subheadline: 12,
|
|
7044
|
-
title: 20
|
|
7045
|
-
};
|
|
7046
|
-
var HEADING_FONT_SIZES = [1, 2, 3, 4, 5, 6].flatMap((n2) => [n2, n2.toString()]);
|
|
7047
|
-
function getFontSize(size = BASE_FONT_SIZE) {
|
|
7048
|
-
if (size in PRESET_FONT_SIZES) {
|
|
7049
|
-
return getFontSize(PRESET_FONT_SIZES[size]);
|
|
7050
|
-
}
|
|
7051
|
-
if (typeof size !== "number") {
|
|
7052
|
-
const parsed = parseFloat(size);
|
|
7053
|
-
if (Number.isNaN(parsed)) {
|
|
7054
|
-
return size;
|
|
7055
|
-
}
|
|
7056
|
-
size = parsed;
|
|
7057
|
-
}
|
|
7058
|
-
const ratio = `(${size} / ${BASE_FONT_SIZE})`;
|
|
7059
|
-
return `calc(${ratio} * ${config_values_default.fontSize})`;
|
|
7060
|
-
}
|
|
7061
|
-
|
|
7062
|
-
// ../../../node_modules/.pnpm/@wordpress+components@32.4.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/text/get-line-height.mjs
|
|
7063
|
-
function getLineHeight(adjustLineHeightForInnerControls, lineHeight) {
|
|
7064
|
-
if (lineHeight) {
|
|
7065
|
-
return lineHeight;
|
|
7066
|
-
}
|
|
7067
|
-
if (!adjustLineHeightForInnerControls) {
|
|
7068
|
-
return;
|
|
7069
|
-
}
|
|
7070
|
-
let value = `calc(${config_values_default.controlHeight} + ${space(2)})`;
|
|
7071
|
-
switch (adjustLineHeightForInnerControls) {
|
|
7072
|
-
case "large":
|
|
7073
|
-
value = `calc(${config_values_default.controlHeightLarge} + ${space(2)})`;
|
|
7074
|
-
break;
|
|
7075
|
-
case "small":
|
|
7076
|
-
value = `calc(${config_values_default.controlHeightSmall} + ${space(2)})`;
|
|
7077
|
-
break;
|
|
7078
|
-
case "xSmall":
|
|
7079
|
-
value = `calc(${config_values_default.controlHeightXSmall} + ${space(2)})`;
|
|
7080
|
-
break;
|
|
7081
|
-
default:
|
|
7082
|
-
break;
|
|
7083
|
-
}
|
|
7084
|
-
return value;
|
|
7085
|
-
}
|
|
7086
|
-
|
|
7087
|
-
// ../../../node_modules/.pnpm/@wordpress+components@32.4.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/text/hook.mjs
|
|
7088
|
-
function _EMOTION_STRINGIFIED_CSS_ERROR__3() {
|
|
7089
|
-
return "You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop).";
|
|
7090
|
-
}
|
|
7091
|
-
var _ref = process.env.NODE_ENV === "production" ? {
|
|
7092
|
-
name: "50zrmy",
|
|
7093
|
-
styles: "text-transform:uppercase"
|
|
7094
|
-
} : {
|
|
7095
|
-
name: "18bqwxz-sx-upperCase",
|
|
7096
|
-
styles: "text-transform:uppercase;label:sx-upperCase;/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbImhvb2sudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBa0dpQiIsImZpbGUiOiJob29rLnRzIiwic291cmNlc0NvbnRlbnQiOlsiLyoqXG4gKiBFeHRlcm5hbCBkZXBlbmRlbmNpZXNcbiAqL1xuaW1wb3J0IHR5cGUgeyBTZXJpYWxpemVkU3R5bGVzIH0gZnJvbSAnQGVtb3Rpb24vcmVhY3QnO1xuaW1wb3J0IHsgY3NzIH0gZnJvbSAnQGVtb3Rpb24vcmVhY3QnO1xuXG4vKipcbiAqIFdvcmRQcmVzcyBkZXBlbmRlbmNpZXNcbiAqL1xuaW1wb3J0IHsgdXNlTWVtbywgQ2h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kIGA8TGluayAvPmAgY29tcG9uZW50cyB0byBpbmhlcml0IGZvbnQgc2l6ZS5cblx0ICovXG5cdGlmICggISB0cnVuY2F0ZSAmJiBBcnJheS5pc0FycmF5KCBjaGlsZHJlbiApICkge1xuXHRcdGNvbnRlbnQgPSBDaGlsZHJlbi5tYXAoIGNoaWxkcmVuLCAoIGNoaWxkICkgPT4ge1xuXHRcdFx0aWYgKFxuXHRcdFx0XHR0eXBlb2YgY2hpbGQgIT09ICdvYmplY3QnIHx8XG5cdFx0XHRcdGNoaWxkID09PSBudWxsIHx8XG5cdFx0XHRcdCEgKCAncHJvcHMnIGluIGNoaWxkIClcblx0XHRcdCkge1xuXHRcdFx0XHRyZXR1cm4gY2hpbGQ7XG5cdFx0XHR9XG5cblx0XHRcdGNvbnN0IGlzTGluayA9IGhhc0Nvbm5lY3ROYW1lc3BhY2UoIGNoaWxkLCBbICdMaW5rJyBdICk7XG5cdFx0XHRpZiAoIGlzTGluayApIHtcblx0XHRcdFx0cmV0dXJuIGNsb25lRWxlbWVudCggY2hpbGQsIHtcblx0XHRcdFx0XHRzaXplOiBjaGlsZC5wcm9wcy5zaXplIHx8ICdpbmhlcml0Jyxcblx0XHRcdFx0fSApO1xuXHRcdFx0fVxuXG5cdFx0XHRyZXR1cm4gY2hpbGQ7XG5cdFx0fSApO1xuXHR9XG5cblx0cmV0dXJuIHtcblx0XHQuLi50cnVuY2F0ZVByb3BzLFxuXHRcdGNoaWxkcmVuOiB0cnVuY2F0ZSA/IHRydW5jYXRlUHJvcHMuY2hpbGRyZW4gOiBjb250ZW50LFxuXHR9O1xufVxuIl19 */",
|
|
7097
|
-
toString: _EMOTION_STRINGIFIED_CSS_ERROR__3
|
|
7098
|
-
};
|
|
7099
|
-
function useText(props) {
|
|
7100
|
-
const {
|
|
7101
|
-
adjustLineHeightForInnerControls,
|
|
7102
|
-
align,
|
|
7103
|
-
children,
|
|
7104
|
-
className,
|
|
7105
|
-
color,
|
|
7106
|
-
ellipsizeMode,
|
|
7107
|
-
isDestructive = false,
|
|
7108
|
-
display,
|
|
7109
|
-
highlightEscape = false,
|
|
7110
|
-
highlightCaseSensitive = false,
|
|
7111
|
-
highlightWords,
|
|
7112
|
-
highlightSanitize,
|
|
7113
|
-
isBlock = false,
|
|
7114
|
-
letterSpacing,
|
|
7115
|
-
lineHeight: lineHeightProp,
|
|
7116
|
-
optimizeReadabilityFor,
|
|
7117
|
-
size,
|
|
7118
|
-
truncate = false,
|
|
7119
|
-
upperCase: upperCase2 = false,
|
|
7120
|
-
variant,
|
|
7121
|
-
weight = config_values_default.fontWeight,
|
|
7122
|
-
...otherProps
|
|
7123
|
-
} = useContextSystem(props, "Text");
|
|
7124
|
-
let content = children;
|
|
7125
|
-
const isHighlighter = Array.isArray(highlightWords);
|
|
7126
|
-
const isCaption = size === "caption";
|
|
7127
|
-
if (isHighlighter) {
|
|
7128
|
-
if (typeof children !== "string") {
|
|
7129
|
-
throw new TypeError("`children` of `Text` must only be `string` types when `highlightWords` is defined");
|
|
7130
|
-
}
|
|
7131
|
-
content = createHighlighterText({
|
|
7132
|
-
autoEscape: highlightEscape,
|
|
7133
|
-
children,
|
|
7134
|
-
caseSensitive: highlightCaseSensitive,
|
|
7135
|
-
searchWords: highlightWords,
|
|
7136
|
-
sanitize: highlightSanitize
|
|
7137
|
-
});
|
|
7138
|
-
}
|
|
7139
|
-
const cx2 = useCx();
|
|
7140
|
-
const classes = _react.useMemo.call(void 0, () => {
|
|
7141
|
-
const sx = {};
|
|
7142
|
-
const lineHeight = getLineHeight(adjustLineHeightForInnerControls, lineHeightProp);
|
|
7143
|
-
sx.Base = /* @__PURE__ */ css({
|
|
7144
|
-
color,
|
|
7145
|
-
display,
|
|
7146
|
-
fontSize: getFontSize(size),
|
|
7147
|
-
fontWeight: weight,
|
|
7148
|
-
lineHeight,
|
|
7149
|
-
letterSpacing,
|
|
7150
|
-
textAlign: align
|
|
7151
|
-
}, process.env.NODE_ENV === "production" ? "" : ";label:sx-Base;", process.env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jaGlsZDtcblx0XHR9ICk7XG5cdH1cblxuXHRyZXR1cm4ge1xuXHRcdC4uLnRydW5jYXRlUHJvcHMsXG5cdFx0Y2hpbGRyZW46IHRydW5jYXRlID8gdHJ1bmNhdGVQcm9wcy5jaGlsZHJlbiA6IGNvbnRlbnQsXG5cdH07XG59XG4iXX0= */");
|
|
7152
|
-
sx.upperCase = _ref;
|
|
7153
|
-
sx.optimalTextColor = null;
|
|
7154
|
-
if (optimizeReadabilityFor) {
|
|
7155
|
-
const isOptimalTextColorDark = getOptimalTextShade(optimizeReadabilityFor) === "dark";
|
|
7156
|
-
sx.optimalTextColor = isOptimalTextColorDark ? /* @__PURE__ */ css({
|
|
7157
|
-
color: COLORS.gray[900]
|
|
7158
|
-
}, process.env.NODE_ENV === "production" ? "" : ";label:sx-optimalTextColor;", process.env.NODE_ENV === "production" ? "" : "/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbImhvb2sudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBNEdNIiwiZmlsZSI6Imhvb2sudHMiLCJzb3VyY2VzQ29udGVudCI6WyIvKipcbiAqIEV4dGVybmFsIGRlcGVuZGVuY2llc1xuICovXG5pbXBvcnQgdHlwZSB7IFNlcmlhbGl6ZWRTdHlsZXMgfSBmcm9tICdAZW1vdGlvbi9yZWFjdCc7XG5pbXBvcnQgeyBjc3MgfSBmcm9tICdAZW1vdGlvbi9yZWFjdCc7XG5cbi8qKlxuICogV29yZFByZXNzIGRlcGVuZGVuY2llc1xuICovXG5pbXBvcnQgeyB1c2VNZW1vLCBDaGlsZHJlbiwgY2xvbmVFbGVtZW50IH0gZnJvbSAnQHdvcmRwcmVzcy9lbGVtZW50JztcblxuLyoqXG4gKiBJbnRlcm5hbCBkZXBlbmRlbmNpZXNcbiAqL1xuaW1wb3J0IHR5cGUgeyBXb3JkUHJlc3NDb21wb25lbnRQcm9wcyB9IGZyb20gJy4uL2Nv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GlsZCAhPT0gJ29iamVjdCcgfHxcblx0XHRcdFx0Y2hpbGQgPT09IG51bGwgfHxcblx0XHRcdFx0ISAoICdwcm9wcycgaW4gY2hpbGQgKVxuXHRcdFx0KSB7XG5cdFx0XHRcdHJldHVybiBjaGlsZDtcblx0XHRcdH1cblxuXHRcdFx0Y29uc3QgaXNMaW5rID0gaGFzQ29ubmVjdE5hbWVzcGFjZSggY2hpbGQsIFsgJ0xpbmsnIF0gKTtcblx0XHRcdGlmICggaXNMaW5rICkge1xuXHRcdFx0XHRyZXR1cm4gY2xvbmVFbGVtZW50KCBjaGlsZCwge1xuXHRcdFx0XHRcdHNpemU6IGNoaWxkLnByb3BzLnNpemUgfHwgJ2luaGVyaXQnLFxuXHRcdFx0XHR9ICk7XG5cdFx0XHR9XG5cblx0XHRcdHJldHVybiBjaGlsZDtcblx0XHR9ICk7XG5cdH1cblxuXHRyZXR1cm4ge1xuXHRcdC4uLnRydW5jYXRlUHJvcHMsXG5cdFx0Y2hpbGRyZW46IHRydW5jYXRlID8gdHJ1bmNhdGVQcm9wcy5jaGlsZHJlbiA6IGNvbnRlbnQsXG5cdH07XG59XG4iXX0= */") : /* @__PURE__ */ css({
|
|
7159
|
-
color: COLORS.white
|
|
7160
|
-
}, process.env.NODE_ENV === "production" ? "" : ";label:sx-optimalTextColor;", process.env.NODE_ENV === "production" ? "" : "/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbImhvb2sudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBNkdNIiwiZmlsZSI6Imhvb2sudHMiLCJzb3VyY2VzQ29udGVudCI6WyIvKipcbiAqIEV4dGVybmFsIGRlcGVuZGVuY2llc1xuICovXG5pbXBvcnQgdHlwZSB7IFNlcmlhbGl6ZWRTdHlsZXMgfSBmcm9tICdAZW1vdGlvbi9yZWFjdCc7XG5pbXBvcnQgeyBjc3MgfSBmcm9tICdAZW1vdGlvbi9yZWF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5cdCAqIEVuaGFuY2UgY2hpbGQgYDxMaW5rIC8+YCBjb21wb25lbnRzIHRvIGluaGVyaXQgZm9udCBzaXplLlxuXHQgKi9cblx0aWYgKCAhIHRydW5jYXRlICYmIEFycmF5LmlzQXJyYXkoIGNoaWxkcmVuICkgKSB7XG5cdFx0Y29udGVudCA9IENoaWxkcmVuLm1hcCggY2hpbGRyZW4sICggY2hpbGQgKSA9PiB7XG5cdFx0XHRpZiAoXG5cdFx0XHRcdHR5cGVvZiBjaGlsZCAhPT0gJ29iamVjdCcgfHxcblx0XHRcdFx0Y2hpbGQgPT09IG51bGwgfHxcblx0XHRcdFx0ISAoICdwcm9wcycgaW4gY2hpbGQgKVxuXHRcdFx0KSB7XG5cdFx0XHRcdHJldHVybiBjaGlsZDtcblx0XHRcdH1cblxuXHRcdFx0Y29uc3QgaXNMaW5rID0gaGFzQ29ubmVjdE5hbWVzcGFjZSggY2hpbGQsIFsgJ0xpbmsnIF0gKTtcblx0XHRcdGlmICggaXNMaW5rICkge1xuXHRcdFx0XHRyZXR1cm4gY2xvbmVFbGVtZW50KCBjaGlsZCwge1xuXHRcdFx0XHRcdHNpemU6IGNoaWxkLnByb3BzLnNpemUgfHwgJ2luaGVyaXQnLFxuXHRcdFx0XHR9ICk7XG5cdFx0XHR9XG5cblx0XHRcdHJldHVybiBjaGlsZDtcblx0XHR9ICk7XG5cdH1cblxuXHRyZXR1cm4ge1xuXHRcdC4uLnRydW5jYXRlUHJvcHMsXG5cdFx0Y2hpbGRyZW46IHRydW5jYXRlID8gdHJ1bmNhdGVQcm9wcy5jaGlsZHJlbiA6IGNvbnRlbnQsXG5cdH07XG59XG4iXX0= */");
|
|
7161
|
-
}
|
|
7162
|
-
return cx2(Text2, sx.Base, sx.optimalTextColor, isDestructive && destructive, !!isHighlighter && highlighterText, isBlock && block, isCaption && muted, variant && styles_exports2[variant], upperCase2 && sx.upperCase, className);
|
|
7163
|
-
}, [adjustLineHeightForInnerControls, align, className, color, cx2, display, isBlock, isCaption, isDestructive, isHighlighter, letterSpacing, lineHeightProp, optimizeReadabilityFor, size, upperCase2, variant, weight]);
|
|
7164
|
-
let finalEllipsizeMode;
|
|
7165
|
-
if (truncate === true) {
|
|
7166
|
-
finalEllipsizeMode = "auto";
|
|
7167
|
-
}
|
|
7168
|
-
if (truncate === false) {
|
|
7169
|
-
finalEllipsizeMode = "none";
|
|
7170
|
-
}
|
|
7171
|
-
const finalComponentProps = {
|
|
7172
|
-
...otherProps,
|
|
7173
|
-
className: classes,
|
|
7174
|
-
children,
|
|
7175
|
-
ellipsizeMode: ellipsizeMode || finalEllipsizeMode
|
|
7176
|
-
};
|
|
7177
|
-
const truncateProps = useTruncate(finalComponentProps);
|
|
7178
|
-
if (!truncate && Array.isArray(children)) {
|
|
7179
|
-
content = _react.Children.map(children, (child) => {
|
|
7180
|
-
if (typeof child !== "object" || child === null || !("props" in child)) {
|
|
7181
|
-
return child;
|
|
7182
|
-
}
|
|
7183
|
-
const isLink = hasConnectNamespace(child, ["Link"]);
|
|
7184
|
-
if (isLink) {
|
|
7185
|
-
return _react.cloneElement.call(void 0, child, {
|
|
7186
|
-
size: child.props.size || "inherit"
|
|
7187
|
-
});
|
|
7188
|
-
}
|
|
7189
|
-
return child;
|
|
7190
|
-
});
|
|
7191
|
-
}
|
|
7192
|
-
return {
|
|
7193
|
-
...truncateProps,
|
|
7194
|
-
children: truncate ? truncateProps.children : content
|
|
7195
|
-
};
|
|
7196
|
-
}
|
|
7197
|
-
|
|
7198
|
-
// ../../../node_modules/.pnpm/@wordpress+components@32.4.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/text/component.mjs
|
|
7199
|
-
|
|
7200
|
-
function UnconnectedText(props, forwardedRef) {
|
|
7201
|
-
const textProps = useText(props);
|
|
7202
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, component_default, {
|
|
7203
|
-
as: "span",
|
|
7204
|
-
...textProps,
|
|
7205
|
-
ref: forwardedRef
|
|
7206
|
-
});
|
|
7207
|
-
}
|
|
7208
|
-
var Text3 = contextConnect(UnconnectedText, "Text");
|
|
7209
|
-
var component_default2 = Text3;
|
|
7210
|
-
|
|
7211
|
-
// ../../../node_modules/.pnpm/@wordpress+components@32.4.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/grid/utils.mjs
|
|
6424
|
+
// ../../../node_modules/.pnpm/@wordpress+components@32.5.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/grid/utils.mjs
|
|
7212
6425
|
var ALIGNMENTS = {
|
|
7213
6426
|
bottom: {
|
|
7214
6427
|
alignItems: "flex-end",
|
|
@@ -7259,7 +6472,7 @@ function getAlignmentProps(alignment) {
|
|
|
7259
6472
|
return alignmentProps;
|
|
7260
6473
|
}
|
|
7261
6474
|
|
|
7262
|
-
// ../../../node_modules/.pnpm/@wordpress+components@32.
|
|
6475
|
+
// ../../../node_modules/.pnpm/@wordpress+components@32.5.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/grid/hook.mjs
|
|
7263
6476
|
function useGrid(props) {
|
|
7264
6477
|
const {
|
|
7265
6478
|
align,
|
|
@@ -7305,7 +6518,7 @@ function useGrid(props) {
|
|
|
7305
6518
|
};
|
|
7306
6519
|
}
|
|
7307
6520
|
|
|
7308
|
-
// ../../../node_modules/.pnpm/@wordpress+components@32.
|
|
6521
|
+
// ../../../node_modules/.pnpm/@wordpress+components@32.5.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/grid/component.mjs
|
|
7309
6522
|
|
|
7310
6523
|
function UnconnectedGrid(props, forwardedRef) {
|
|
7311
6524
|
const gridProps = useGrid(props);
|
|
@@ -7315,7 +6528,7 @@ function UnconnectedGrid(props, forwardedRef) {
|
|
|
7315
6528
|
});
|
|
7316
6529
|
}
|
|
7317
6530
|
var Grid2 = contextConnect(UnconnectedGrid, "Grid");
|
|
7318
|
-
var
|
|
6531
|
+
var component_default2 = Grid2;
|
|
7319
6532
|
|
|
7320
6533
|
// src/charts/leaderboard-chart/leaderboard-chart.tsx
|
|
7321
6534
|
|
|
@@ -7345,7 +6558,7 @@ function useLeaderboardLegendItems({
|
|
|
7345
6558
|
overrideColor: primaryColor || leaderboardChartSettings.primaryColor
|
|
7346
6559
|
});
|
|
7347
6560
|
items.push({
|
|
7348
|
-
label: _optionalChain([legendLabels, 'optionalAccess',
|
|
6561
|
+
label: _optionalChain([legendLabels, 'optionalAccess', _168 => _168.primary]) || _i18n.__.call(void 0, "Current period", "jetpack-charts"),
|
|
7349
6562
|
color: resolvedPrimaryColor
|
|
7350
6563
|
});
|
|
7351
6564
|
if (withComparison && !withOverlayLabel) {
|
|
@@ -7354,7 +6567,7 @@ function useLeaderboardLegendItems({
|
|
|
7354
6567
|
overrideColor: secondaryColor || leaderboardChartSettings.secondaryColor
|
|
7355
6568
|
});
|
|
7356
6569
|
items.push({
|
|
7357
|
-
label: _optionalChain([legendLabels, 'optionalAccess',
|
|
6570
|
+
label: _optionalChain([legendLabels, 'optionalAccess', _169 => _169.comparison]) || _i18n.__.call(void 0, "Previous period", "jetpack-charts"),
|
|
7358
6571
|
color: resolvedSecondaryColor
|
|
7359
6572
|
});
|
|
7360
6573
|
}
|
|
@@ -7405,7 +6618,7 @@ var defaultDeltaFormatter = (value) => {
|
|
|
7405
6618
|
var BarLabel = ({
|
|
7406
6619
|
label
|
|
7407
6620
|
}) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _jsxruntime.Fragment, {
|
|
7408
|
-
children: typeof label === "string" ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
6621
|
+
children: typeof label === "string" ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Text, {
|
|
7409
6622
|
className: leaderboard_chart_module_default.label,
|
|
7410
6623
|
children: label
|
|
7411
6624
|
}) : label
|
|
@@ -7606,7 +6819,7 @@ var LeaderboardChartInternal = ({
|
|
|
7606
6819
|
children: allSeriesHidden ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", {
|
|
7607
6820
|
className: leaderboard_chart_module_default.emptyState,
|
|
7608
6821
|
children: _i18n.__.call(void 0, "All series are hidden. Click legend items to show data.", "jetpack-charts")
|
|
7609
|
-
}) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
6822
|
+
}) : /* @__PURE__ */ _jsxruntime.jsx.call(void 0, component_default2, {
|
|
7610
6823
|
templateColumns: "minmax(0, 1fr) auto",
|
|
7611
6824
|
rowGap,
|
|
7612
6825
|
columnGap,
|
|
@@ -7633,9 +6846,9 @@ var LeaderboardChartInternal = ({
|
|
|
7633
6846
|
className: _clsx2.default.call(void 0, leaderboard_chart_module_default.valueContainer, {
|
|
7634
6847
|
[leaderboard_chart_module_default.overlayLabel]: withOverlayLabel
|
|
7635
6848
|
}),
|
|
7636
|
-
children: [isPrimaryVisible && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
6849
|
+
children: [isPrimaryVisible && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Text, {
|
|
7637
6850
|
children: valueFormatter(entry.currentValue)
|
|
7638
|
-
}), withComparison && isComparisonVisible && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
6851
|
+
}), withComparison && isComparisonVisible && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Text, {
|
|
7639
6852
|
style: {
|
|
7640
6853
|
color: deltaColor
|
|
7641
6854
|
},
|
|
@@ -7695,7 +6908,7 @@ var DefaultGlyph = (props) => {
|
|
|
7695
6908
|
cy: props.y,
|
|
7696
6909
|
r: props.size,
|
|
7697
6910
|
fill: props.color,
|
|
7698
|
-
stroke: _optionalChain([theme, 'optionalAccess',
|
|
6911
|
+
stroke: _optionalChain([theme, 'optionalAccess', _170 => _170.backgroundColor]),
|
|
7699
6912
|
strokeWidth: 1.5,
|
|
7700
6913
|
paintOrder: "fill",
|
|
7701
6914
|
...props.glyphStyle
|
|
@@ -7724,8 +6937,8 @@ var line_chart_module_default = {
|
|
|
7724
6937
|
|
|
7725
6938
|
// src/charts/line-chart/private/line-chart-annotation-label-popover.tsx
|
|
7726
6939
|
|
|
6940
|
+
var _icons = require('@wordpress/icons');
|
|
7727
6941
|
|
|
7728
|
-
var _gridicons = require('gridicons'); var _gridicons2 = _interopRequireDefault(_gridicons);
|
|
7729
6942
|
|
|
7730
6943
|
|
|
7731
6944
|
var POPOVER_BUTTON_SIZE = 44;
|
|
@@ -7752,8 +6965,8 @@ var LineChartAnnotationLabelWithPopover = ({
|
|
|
7752
6965
|
}
|
|
7753
6966
|
setIsPositioned(true);
|
|
7754
6967
|
};
|
|
7755
|
-
popover.addEventListener("toggle", (
|
|
7756
|
-
if (
|
|
6968
|
+
popover.addEventListener("toggle", (e) => {
|
|
6969
|
+
if (e.newState === "open") {
|
|
7757
6970
|
positionPopover();
|
|
7758
6971
|
}
|
|
7759
6972
|
});
|
|
@@ -7761,7 +6974,7 @@ var LineChartAnnotationLabelWithPopover = ({
|
|
|
7761
6974
|
if (popover.matches(":popover-open")) {
|
|
7762
6975
|
positionPopover();
|
|
7763
6976
|
}
|
|
7764
|
-
} catch (
|
|
6977
|
+
} catch (e3) {
|
|
7765
6978
|
}
|
|
7766
6979
|
}, [isBrowserSafari]);
|
|
7767
6980
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", {
|
|
@@ -7798,8 +7011,8 @@ var LineChartAnnotationLabelWithPopover = ({
|
|
|
7798
7011
|
popovertargetaction: "hide",
|
|
7799
7012
|
className: line_chart_module_default["line-chart__annotation-label-popover-close-button"],
|
|
7800
7013
|
"aria-label": _i18n.__.call(void 0, "Close", "jetpack-charts"),
|
|
7801
|
-
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
7802
|
-
icon:
|
|
7014
|
+
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _icons.Icon, {
|
|
7015
|
+
icon: _icons.close,
|
|
7803
7016
|
size: 16
|
|
7804
7017
|
})
|
|
7805
7018
|
})]
|
|
@@ -7831,7 +7044,7 @@ var LineChartAnnotationsOverlay = ({
|
|
|
7831
7044
|
return `${xDomain.join(",")}-${yDomain.join(",")}-${xRange.join(",")}-${yRange.join(",")}`;
|
|
7832
7045
|
}, []);
|
|
7833
7046
|
const getScalesData = _react.useCallback.call(void 0, () => {
|
|
7834
|
-
if (_optionalChain([chartRef, 'optionalAccess',
|
|
7047
|
+
if (_optionalChain([chartRef, 'optionalAccess', _171 => _171.current])) {
|
|
7835
7048
|
const scaleData = chartRef.current.getScales();
|
|
7836
7049
|
if (scaleData) {
|
|
7837
7050
|
const scaleInfo = {
|
|
@@ -7916,9 +7129,9 @@ var ANNOTATION_MAX_WIDTH = 125;
|
|
|
7916
7129
|
var ANNOTATION_INIT_HEIGHT = 100;
|
|
7917
7130
|
var getLabelPosition = ({
|
|
7918
7131
|
subjectType,
|
|
7919
|
-
x
|
|
7132
|
+
x,
|
|
7920
7133
|
xMax,
|
|
7921
|
-
y
|
|
7134
|
+
y,
|
|
7922
7135
|
yMin,
|
|
7923
7136
|
yMax,
|
|
7924
7137
|
maxWidth,
|
|
@@ -7938,7 +7151,7 @@ var getLabelPosition = ({
|
|
|
7938
7151
|
dx = 20;
|
|
7939
7152
|
dy = 0;
|
|
7940
7153
|
}
|
|
7941
|
-
const effectiveX =
|
|
7154
|
+
const effectiveX = x + dx;
|
|
7942
7155
|
if (effectiveX + annotationMaxWidth > xMax) {
|
|
7943
7156
|
isFlippedHorizontally = true;
|
|
7944
7157
|
if (subjectType === "circle") {
|
|
@@ -7948,18 +7161,18 @@ var getLabelPosition = ({
|
|
|
7948
7161
|
}
|
|
7949
7162
|
}
|
|
7950
7163
|
if (subjectType === "circle") {
|
|
7951
|
-
if (
|
|
7164
|
+
if (y + dy + annotationHeight > yMin) {
|
|
7952
7165
|
isFlippedVertically = true;
|
|
7953
7166
|
dy = -Math.abs(dy);
|
|
7954
7167
|
}
|
|
7955
|
-
} else if (
|
|
7168
|
+
} else if (y - annotationHeight < yMax) {
|
|
7956
7169
|
if (subjectType === "line-horizontal") {
|
|
7957
7170
|
isFlippedVertically = true;
|
|
7958
7171
|
dy = Math.abs(dy);
|
|
7959
7172
|
} else if (subjectType === "line-vertical") {
|
|
7960
7173
|
isFlippedVertically = true;
|
|
7961
7174
|
}
|
|
7962
|
-
} else if (
|
|
7175
|
+
} else if (y + annotationHeight > yMin) {
|
|
7963
7176
|
if (subjectType === "line-horizontal") {
|
|
7964
7177
|
isFlippedVertically = true;
|
|
7965
7178
|
dy = -Math.abs(dy);
|
|
@@ -7980,10 +7193,10 @@ var getHorizontalAnchor = (subjectType, isFlippedHorizontally) => {
|
|
|
7980
7193
|
}
|
|
7981
7194
|
return void 0;
|
|
7982
7195
|
};
|
|
7983
|
-
var getVerticalAnchor = (subjectType, isFlippedVertically,
|
|
7196
|
+
var getVerticalAnchor = (subjectType, isFlippedVertically, y, yMax, height) => {
|
|
7984
7197
|
if (subjectType === "line-vertical") {
|
|
7985
7198
|
if (isFlippedVertically) {
|
|
7986
|
-
return
|
|
7199
|
+
return y - height < yMax ? "start" : "end";
|
|
7987
7200
|
}
|
|
7988
7201
|
return "start";
|
|
7989
7202
|
}
|
|
@@ -8008,23 +7221,23 @@ var LineChartAnnotation = ({
|
|
|
8008
7221
|
const [height, setHeight] = _react.useState.call(void 0, null);
|
|
8009
7222
|
const styles = _deepmerge2.default.call(void 0, _nullishCoalesce(providerTheme.annotationStyles, () => ( {})), _nullishCoalesce(datumStyles, () => ( {})));
|
|
8010
7223
|
_react.useEffect.call(void 0, () => {
|
|
8011
|
-
if (_optionalChain([labelRef, 'access',
|
|
7224
|
+
if (_optionalChain([labelRef, 'access', _172 => _172.current, 'optionalAccess', _173 => _173.getBBox])) {
|
|
8012
7225
|
const bbox = labelRef.current.getBBox();
|
|
8013
7226
|
setHeight(bbox.height);
|
|
8014
7227
|
}
|
|
8015
7228
|
}, []);
|
|
8016
7229
|
const positionData = _react.useMemo.call(void 0, () => {
|
|
8017
7230
|
if (!datum || !datum.date || datum.value == null || !xScale || !yScale) return null;
|
|
8018
|
-
const
|
|
8019
|
-
const
|
|
8020
|
-
if (typeof
|
|
7231
|
+
const x2 = xScale(datum.date);
|
|
7232
|
+
const y2 = yScale(datum.value);
|
|
7233
|
+
if (typeof x2 !== "number" || typeof y2 !== "number") return null;
|
|
8021
7234
|
const [yMin2, yMax2] = yScale.range().map(Number);
|
|
8022
7235
|
const [xMin2, xMax2] = xScale.range().map(Number);
|
|
8023
7236
|
if (renderLabel) {
|
|
8024
7237
|
return {
|
|
8025
|
-
x:
|
|
7238
|
+
x: x2,
|
|
8026
7239
|
dx: 0,
|
|
8027
|
-
y:
|
|
7240
|
+
y: y2,
|
|
8028
7241
|
dy: 0,
|
|
8029
7242
|
yMin: yMin2,
|
|
8030
7243
|
yMax: yMax2,
|
|
@@ -8036,28 +7249,28 @@ var LineChartAnnotation = ({
|
|
|
8036
7249
|
}
|
|
8037
7250
|
const position2 = getLabelPosition({
|
|
8038
7251
|
subjectType,
|
|
8039
|
-
x:
|
|
7252
|
+
x: x2,
|
|
8040
7253
|
xMax: xMax2,
|
|
8041
|
-
y:
|
|
7254
|
+
y: y2,
|
|
8042
7255
|
yMin: yMin2,
|
|
8043
7256
|
yMax: yMax2,
|
|
8044
|
-
maxWidth: _optionalChain([styles, 'optionalAccess',
|
|
7257
|
+
maxWidth: _optionalChain([styles, 'optionalAccess', _174 => _174.label, 'optionalAccess', _175 => _175.maxWidth]),
|
|
8045
7258
|
height
|
|
8046
7259
|
});
|
|
8047
7260
|
return {
|
|
8048
|
-
x:
|
|
8049
|
-
y:
|
|
7261
|
+
x: x2,
|
|
7262
|
+
y: y2,
|
|
8050
7263
|
yMin: yMin2,
|
|
8051
7264
|
yMax: yMax2,
|
|
8052
7265
|
xMin: xMin2,
|
|
8053
7266
|
xMax: xMax2,
|
|
8054
7267
|
...position2
|
|
8055
7268
|
};
|
|
8056
|
-
}, [datum, xScale, yScale, subjectType, _optionalChain([styles, 'optionalAccess',
|
|
7269
|
+
}, [datum, xScale, yScale, subjectType, _optionalChain([styles, 'optionalAccess', _176 => _176.label, 'optionalAccess', _177 => _177.maxWidth]), height, renderLabel]);
|
|
8057
7270
|
if (!positionData) return null;
|
|
8058
7271
|
const {
|
|
8059
|
-
x
|
|
8060
|
-
y
|
|
7272
|
+
x,
|
|
7273
|
+
y,
|
|
8061
7274
|
yMin,
|
|
8062
7275
|
yMax,
|
|
8063
7276
|
xMin,
|
|
@@ -8068,13 +7281,13 @@ var LineChartAnnotation = ({
|
|
|
8068
7281
|
isFlippedVertically
|
|
8069
7282
|
} = positionData;
|
|
8070
7283
|
const getLabelY = () => {
|
|
8071
|
-
const labelY = _optionalChain([styles, 'optionalAccess',
|
|
7284
|
+
const labelY = _optionalChain([styles, 'optionalAccess', _178 => _178.label, 'optionalAccess', _179 => _179.y]);
|
|
8072
7285
|
if (labelY === "start") return yMax;
|
|
8073
7286
|
if (labelY === "end") return yMin;
|
|
8074
7287
|
return labelY;
|
|
8075
7288
|
};
|
|
8076
7289
|
const getLabelX = () => {
|
|
8077
|
-
const labelX = _optionalChain([styles, 'optionalAccess',
|
|
7290
|
+
const labelX = _optionalChain([styles, 'optionalAccess', _180 => _180.label, 'optionalAccess', _181 => _181.x]);
|
|
8078
7291
|
if (labelX === "start") return xMin;
|
|
8079
7292
|
if (labelX === "end") return xMax;
|
|
8080
7293
|
return labelX;
|
|
@@ -8087,33 +7300,33 @@ var LineChartAnnotation = ({
|
|
|
8087
7300
|
const labelWidth = POPOVER_BUTTON_SIZE;
|
|
8088
7301
|
const labelHeight = POPOVER_BUTTON_SIZE;
|
|
8089
7302
|
return isSafari() ? {
|
|
8090
|
-
transform: `translate(${
|
|
7303
|
+
transform: `translate(${x + (dx || 0) + (typeof labelPosition.x === "number" ? labelPosition.x - x : 0) - labelWidth}px, ${y + (dy || 0) + (typeof labelPosition.y === "number" ? labelPosition.y - y : 0) - labelHeight}px)`,
|
|
8091
7304
|
width: labelWidth,
|
|
8092
7305
|
height: labelHeight
|
|
8093
7306
|
} : void 0;
|
|
8094
7307
|
};
|
|
8095
7308
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "g", {
|
|
8096
7309
|
children: /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _annotation.Annotation, {
|
|
8097
|
-
x
|
|
8098
|
-
y
|
|
7310
|
+
x,
|
|
7311
|
+
y,
|
|
8099
7312
|
dx,
|
|
8100
7313
|
dy,
|
|
8101
7314
|
children: [/* @__PURE__ */ _jsxruntime.jsx.call(void 0, _annotation.Connector, {
|
|
8102
|
-
..._optionalChain([styles, 'optionalAccess',
|
|
7315
|
+
..._optionalChain([styles, 'optionalAccess', _182 => _182.connector])
|
|
8103
7316
|
}), subjectType === "circle" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _annotation.CircleSubject, {
|
|
8104
|
-
..._optionalChain([styles, 'optionalAccess',
|
|
7317
|
+
..._optionalChain([styles, 'optionalAccess', _183 => _183.circleSubject])
|
|
8105
7318
|
}), subjectType === "line-vertical" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _annotation.LineSubject, {
|
|
8106
7319
|
min: yMax,
|
|
8107
7320
|
max: yMin,
|
|
8108
|
-
..._optionalChain([styles, 'optionalAccess',
|
|
7321
|
+
..._optionalChain([styles, 'optionalAccess', _184 => _184.lineSubject]),
|
|
8109
7322
|
orientation: "vertical"
|
|
8110
7323
|
}), subjectType === "line-horizontal" && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _annotation.LineSubject, {
|
|
8111
7324
|
min: xMin,
|
|
8112
7325
|
max: xMax,
|
|
8113
|
-
..._optionalChain([styles, 'optionalAccess',
|
|
7326
|
+
..._optionalChain([styles, 'optionalAccess', _185 => _185.lineSubject]),
|
|
8114
7327
|
orientation: "horizontal"
|
|
8115
7328
|
}), renderLabel ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _annotation.HtmlLabel, {
|
|
8116
|
-
..._optionalChain([styles, 'optionalAccess',
|
|
7329
|
+
..._optionalChain([styles, 'optionalAccess', _186 => _186.label]),
|
|
8117
7330
|
...labelPosition,
|
|
8118
7331
|
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", {
|
|
8119
7332
|
style: getSafariHTMLLabelPosition(),
|
|
@@ -8132,10 +7345,10 @@ var LineChartAnnotation = ({
|
|
|
8132
7345
|
children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _annotation.Label, {
|
|
8133
7346
|
title,
|
|
8134
7347
|
subtitle,
|
|
8135
|
-
..._optionalChain([styles, 'optionalAccess',
|
|
7348
|
+
..._optionalChain([styles, 'optionalAccess', _187 => _187.label]),
|
|
8136
7349
|
...labelPosition,
|
|
8137
7350
|
horizontalAnchor: getHorizontalAnchor(subjectType, isFlippedHorizontally),
|
|
8138
|
-
verticalAnchor: getVerticalAnchor(subjectType, isFlippedVertically,
|
|
7351
|
+
verticalAnchor: getVerticalAnchor(subjectType, isFlippedVertically, y, yMax, _nullishCoalesce(height, () => ( ANNOTATION_INIT_HEIGHT)))
|
|
8139
7352
|
})
|
|
8140
7353
|
})]
|
|
8141
7354
|
})
|
|
@@ -8166,18 +7379,18 @@ var LineChartGlyph = ({
|
|
|
8166
7379
|
if (!xScale || !yScale) return null;
|
|
8167
7380
|
if (data.data.length === 0) return null;
|
|
8168
7381
|
const point = position2 === "start" ? data.data[0] : data.data[data.data.length - 1];
|
|
8169
|
-
const
|
|
8170
|
-
const
|
|
8171
|
-
if (typeof
|
|
8172
|
-
const size = Math.max(0, _nullishCoalesce(toNumber(_optionalChain([glyphStyle, 'optionalAccess',
|
|
7382
|
+
const x = xScale(accessors.xAccessor(point));
|
|
7383
|
+
const y = yScale(accessors.yAccessor(point));
|
|
7384
|
+
if (typeof x !== "number" || typeof y !== "number") return null;
|
|
7385
|
+
const size = Math.max(0, _nullishCoalesce(toNumber(_optionalChain([glyphStyle, 'optionalAccess', _188 => _188.radius])), () => ( 4)));
|
|
8173
7386
|
return renderGlyph({
|
|
8174
7387
|
key: `${position2}-glyph-${data.label}`,
|
|
8175
7388
|
index,
|
|
8176
7389
|
datum: point,
|
|
8177
7390
|
color,
|
|
8178
7391
|
size,
|
|
8179
|
-
x
|
|
8180
|
-
y
|
|
7392
|
+
x,
|
|
7393
|
+
y,
|
|
8181
7394
|
glyphStyle,
|
|
8182
7395
|
position: position2
|
|
8183
7396
|
});
|
|
@@ -8216,19 +7429,19 @@ var renderDefaultTooltip = (params) => {
|
|
|
8216
7429
|
const {
|
|
8217
7430
|
tooltipData
|
|
8218
7431
|
} = params;
|
|
8219
|
-
const nearestDatum = _optionalChain([tooltipData, 'optionalAccess',
|
|
7432
|
+
const nearestDatum = _optionalChain([tooltipData, 'optionalAccess', _189 => _189.nearestDatum, 'optionalAccess', _190 => _190.datum]);
|
|
8220
7433
|
if (!nearestDatum) return null;
|
|
8221
|
-
const tooltipPoints = Object.entries(_optionalChain([tooltipData, 'optionalAccess',
|
|
7434
|
+
const tooltipPoints = Object.entries(_optionalChain([tooltipData, 'optionalAccess', _191 => _191.datumByKey]) || {}).map(([key, {
|
|
8222
7435
|
datum
|
|
8223
7436
|
}]) => ({
|
|
8224
7437
|
key,
|
|
8225
7438
|
value: datum.value
|
|
8226
|
-
})).sort((
|
|
7439
|
+
})).sort((a, b) => b.value - a.value);
|
|
8227
7440
|
return /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", {
|
|
8228
7441
|
className: line_chart_module_default["line-chart__tooltip"],
|
|
8229
7442
|
children: [/* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", {
|
|
8230
7443
|
className: line_chart_module_default["line-chart__tooltip-date"],
|
|
8231
|
-
children: _optionalChain([nearestDatum, 'access',
|
|
7444
|
+
children: _optionalChain([nearestDatum, 'access', _192 => _192.date, 'optionalAccess', _193 => _193.toLocaleDateString, 'call', _194 => _194()])
|
|
8232
7445
|
}), tooltipPoints.map((point) => /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "div", {
|
|
8233
7446
|
className: line_chart_module_default["line-chart__tooltip-row"],
|
|
8234
7447
|
children: [/* @__PURE__ */ _jsxruntime.jsxs.call(void 0, "span", {
|
|
@@ -8262,8 +7475,8 @@ var formatHourTick = (timestamp) => {
|
|
|
8262
7475
|
});
|
|
8263
7476
|
};
|
|
8264
7477
|
var getFormatter = (sortedData) => {
|
|
8265
|
-
const minX = Math.min(...sortedData.map((datom) => _optionalChain([datom, 'access',
|
|
8266
|
-
const maxX = Math.max(...sortedData.map((datom) => _optionalChain([datom, 'access',
|
|
7478
|
+
const minX = Math.min(...sortedData.map((datom) => _optionalChain([datom, 'access', _195 => _195.data, 'access', _196 => _196.at, 'call', _197 => _197(0), 'optionalAccess', _198 => _198.date])));
|
|
7479
|
+
const maxX = Math.max(...sortedData.map((datom) => _optionalChain([datom, 'access', _199 => _199.data, 'access', _200 => _200.at, 'call', _201 => _201(-1), 'optionalAccess', _202 => _202.date])));
|
|
8267
7480
|
const diffInHours = Math.abs(_datefns.differenceInHours.call(void 0, maxX, minX));
|
|
8268
7481
|
if (diffInHours <= 24) {
|
|
8269
7482
|
return formatHourTick;
|
|
@@ -8275,19 +7488,19 @@ var getFormatter = (sortedData) => {
|
|
|
8275
7488
|
return formatYearTick;
|
|
8276
7489
|
};
|
|
8277
7490
|
var guessOptimalNumTicks = (data, chartWidth, tickFormatter) => {
|
|
8278
|
-
const minX = Math.min(...data.map((datom) => _optionalChain([datom, 'access',
|
|
8279
|
-
const maxX = Math.max(...data.map((datom) => _optionalChain([datom, 'access',
|
|
7491
|
+
const minX = Math.min(...data.map((datom) => _optionalChain([datom, 'access', _203 => _203.data, 'access', _204 => _204.at, 'call', _205 => _205(0), 'optionalAccess', _206 => _206.date])));
|
|
7492
|
+
const maxX = Math.max(...data.map((datom) => _optionalChain([datom, 'access', _207 => _207.data, 'access', _208 => _208.at, 'call', _209 => _209(-1), 'optionalAccess', _210 => _210.date])));
|
|
8280
7493
|
const xScale = _scale.scaleTime.call(void 0, {
|
|
8281
7494
|
domain: [minX, maxX]
|
|
8282
7495
|
});
|
|
8283
7496
|
const upperBound = Math.min(
|
|
8284
|
-
_optionalChain([data, 'access',
|
|
7497
|
+
_optionalChain([data, 'access', _211 => _211[0], 'optionalAccess', _212 => _212.data, 'access', _213 => _213.length]) || 3,
|
|
8285
7498
|
// A sane fallback to avoid NaN when no data is present
|
|
8286
7499
|
Math.ceil(chartWidth / X_TICK_WIDTH)
|
|
8287
7500
|
);
|
|
8288
7501
|
let secondBestGuess = 1;
|
|
8289
7502
|
for (let numTicks = upperBound; numTicks > 1; --numTicks) {
|
|
8290
|
-
const ticks = xScale.ticks(numTicks).map((
|
|
7503
|
+
const ticks = xScale.ticks(numTicks).map((d) => tickFormatter(d.getTime()));
|
|
8291
7504
|
if (ticks.length > upperBound) {
|
|
8292
7505
|
continue;
|
|
8293
7506
|
}
|
|
@@ -8305,7 +7518,7 @@ var guessOptimalNumTicks = (data, chartWidth, tickFormatter) => {
|
|
|
8305
7518
|
return secondBestGuess;
|
|
8306
7519
|
};
|
|
8307
7520
|
var validateData2 = (data) => {
|
|
8308
|
-
if (!_optionalChain([data, 'optionalAccess',
|
|
7521
|
+
if (!_optionalChain([data, 'optionalAccess', _214 => _214.length])) return "No data available";
|
|
8309
7522
|
const hasInvalidData = data.some((series) => series.data.some((point) => isNaN(point.value) || point.value === null || point.value === void 0 || "date" in point && point.date && isNaN(point.date.getTime())));
|
|
8310
7523
|
if (hasInvalidData) return "Invalid data";
|
|
8311
7524
|
return null;
|
|
@@ -8319,7 +7532,7 @@ var LineChartScalesRef = ({
|
|
|
8319
7532
|
const context = _react.useContext.call(void 0, _xychart.DataContext);
|
|
8320
7533
|
_react.useImperativeHandle.call(void 0, chartRef, () => ({
|
|
8321
7534
|
getScales: () => {
|
|
8322
|
-
if (!_optionalChain([context, 'optionalAccess',
|
|
7535
|
+
if (!_optionalChain([context, 'optionalAccess', _215 => _215.xScale]) || !_optionalChain([context, 'optionalAccess', _216 => _216.yScale])) {
|
|
8323
7536
|
return null;
|
|
8324
7537
|
}
|
|
8325
7538
|
return {
|
|
@@ -8385,8 +7598,8 @@ var LineChartInternal = /* @__PURE__ */ _react.forwardRef.call(void 0, ({
|
|
|
8385
7598
|
setMeasuredChartHeight(chartHeight);
|
|
8386
7599
|
}, [height]);
|
|
8387
7600
|
_react.useImperativeHandle.call(void 0, ref, () => ({
|
|
8388
|
-
getScales: () => _optionalChain([internalChartRef, 'access',
|
|
8389
|
-
getChartDimensions: () => _optionalChain([internalChartRef, 'access',
|
|
7601
|
+
getScales: () => _optionalChain([internalChartRef, 'access', _217 => _217.current, 'optionalAccess', _218 => _218.getScales, 'call', _219 => _219()]) || null,
|
|
7602
|
+
getChartDimensions: () => _optionalChain([internalChartRef, 'access', _220 => _220.current, 'optionalAccess', _221 => _221.getChartDimensions, 'call', _222 => _222()]) || {
|
|
8390
7603
|
width: 0,
|
|
8391
7604
|
height: 0,
|
|
8392
7605
|
margin: {}
|
|
@@ -8427,10 +7640,10 @@ var LineChartInternal = /* @__PURE__ */ _react.forwardRef.call(void 0, ({
|
|
|
8427
7640
|
isNavigating,
|
|
8428
7641
|
setIsNavigating,
|
|
8429
7642
|
chartRef,
|
|
8430
|
-
totalPoints: _optionalChain([dataSorted, 'access',
|
|
7643
|
+
totalPoints: _optionalChain([dataSorted, 'access', _223 => _223[0], 'optionalAccess', _224 => _224.data, 'access', _225 => _225.length]) || 0
|
|
8431
7644
|
});
|
|
8432
7645
|
const chartOptions = _react.useMemo.call(void 0, () => {
|
|
8433
|
-
const formatter = _optionalChain([options, 'optionalAccess',
|
|
7646
|
+
const formatter = _optionalChain([options, 'optionalAccess', _226 => _226.axis, 'optionalAccess', _227 => _227.x, 'optionalAccess', _228 => _228.tickFormat]) || getFormatter(dataSorted);
|
|
8434
7647
|
return {
|
|
8435
7648
|
axis: {
|
|
8436
7649
|
x: {
|
|
@@ -8438,25 +7651,25 @@ var LineChartInternal = /* @__PURE__ */ _react.forwardRef.call(void 0, ({
|
|
|
8438
7651
|
numTicks: guessOptimalNumTicks(dataSorted, width, formatter),
|
|
8439
7652
|
tickFormat: formatter,
|
|
8440
7653
|
display: true,
|
|
8441
|
-
..._optionalChain([options, 'optionalAccess',
|
|
7654
|
+
..._optionalChain([options, 'optionalAccess', _229 => _229.axis, 'optionalAccess', _230 => _230.x])
|
|
8442
7655
|
},
|
|
8443
7656
|
y: {
|
|
8444
7657
|
orientation: "left",
|
|
8445
7658
|
numTicks: 4,
|
|
8446
7659
|
tickFormat: _numberformatters.formatNumberCompact,
|
|
8447
7660
|
display: true,
|
|
8448
|
-
..._optionalChain([options, 'optionalAccess',
|
|
7661
|
+
..._optionalChain([options, 'optionalAccess', _231 => _231.axis, 'optionalAccess', _232 => _232.y])
|
|
8449
7662
|
}
|
|
8450
7663
|
},
|
|
8451
7664
|
xScale: {
|
|
8452
7665
|
type: "time",
|
|
8453
|
-
..._optionalChain([options, 'optionalAccess',
|
|
7666
|
+
..._optionalChain([options, 'optionalAccess', _233 => _233.xScale])
|
|
8454
7667
|
},
|
|
8455
7668
|
yScale: {
|
|
8456
7669
|
type: "linear",
|
|
8457
7670
|
nice: true,
|
|
8458
7671
|
zero: false,
|
|
8459
|
-
..._optionalChain([options, 'optionalAccess',
|
|
7672
|
+
..._optionalChain([options, 'optionalAccess', _234 => _234.yScale])
|
|
8460
7673
|
}
|
|
8461
7674
|
};
|
|
8462
7675
|
}, [options, dataSorted, width]);
|
|
@@ -8483,9 +7696,9 @@ var LineChartInternal = /* @__PURE__ */ _react.forwardRef.call(void 0, ({
|
|
|
8483
7696
|
const isDataValid = !error;
|
|
8484
7697
|
const legendOptions = _react.useMemo.call(void 0, () => ({
|
|
8485
7698
|
withGlyph: withLegendGlyph,
|
|
8486
|
-
glyphSize: Math.max(0, _nullishCoalesce(toNumber2(_optionalChain([glyphStyle, 'optionalAccess',
|
|
7699
|
+
glyphSize: Math.max(0, _nullishCoalesce(toNumber2(_optionalChain([glyphStyle, 'optionalAccess', _235 => _235.radius])), () => ( 4))),
|
|
8487
7700
|
renderGlyph
|
|
8488
|
-
}), [withLegendGlyph, _optionalChain([glyphStyle, 'optionalAccess',
|
|
7701
|
+
}), [withLegendGlyph, _optionalChain([glyphStyle, 'optionalAccess', _236 => _236.radius]), renderGlyph]);
|
|
8489
7702
|
const legendItems = useChartLegendItems(dataSorted, legendOptions, legendShape);
|
|
8490
7703
|
const chartMetadata = _react.useMemo.call(void 0, () => ({
|
|
8491
7704
|
withGradientFill,
|
|
@@ -8504,8 +7717,8 @@ var LineChartInternal = /* @__PURE__ */ _react.forwardRef.call(void 0, ({
|
|
|
8504
7717
|
});
|
|
8505
7718
|
const prefersReducedMotion = usePrefersReducedMotion();
|
|
8506
7719
|
const accessors = {
|
|
8507
|
-
xAccessor: (
|
|
8508
|
-
yAccessor: (
|
|
7720
|
+
xAccessor: (d) => _optionalChain([d, 'optionalAccess', _237 => _237.date]),
|
|
7721
|
+
yAccessor: (d) => _optionalChain([d, 'optionalAccess', _238 => _238.value])
|
|
8509
7722
|
};
|
|
8510
7723
|
if (error) {
|
|
8511
7724
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "div", {
|
|
@@ -8615,21 +7828,21 @@ var LineChartInternal = /* @__PURE__ */ _react.forwardRef.call(void 0, ({
|
|
|
8615
7828
|
fromOpacity: 0.4,
|
|
8616
7829
|
toOpacity: 0.1,
|
|
8617
7830
|
to: providerTheme.backgroundColor,
|
|
8618
|
-
..._optionalChain([seriesData, 'access',
|
|
8619
|
-
children: _optionalChain([seriesData, 'access',
|
|
7831
|
+
..._optionalChain([seriesData, 'access', _239 => _239.options, 'optionalAccess', _240 => _240.gradient]),
|
|
7832
|
+
children: _optionalChain([seriesData, 'access', _241 => _241.options, 'optionalAccess', _242 => _242.gradient, 'optionalAccess', _243 => _243.stops, 'optionalAccess', _244 => _244.map, 'call', _245 => _245((stop, stopIndex) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "stop", {
|
|
8620
7833
|
offset: stop.offset,
|
|
8621
7834
|
stopColor: stop.color || color,
|
|
8622
7835
|
stopOpacity: _nullishCoalesce(stop.opacity, () => ( 1))
|
|
8623
7836
|
}, `${stop.offset}-${stop.color || color}`))])
|
|
8624
7837
|
}), /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _xychart.AreaSeries, {
|
|
8625
|
-
dataKey: _optionalChain([seriesData, 'optionalAccess',
|
|
7838
|
+
dataKey: _optionalChain([seriesData, 'optionalAccess', _246 => _246.label]),
|
|
8626
7839
|
data: seriesData.data,
|
|
8627
7840
|
...accessors,
|
|
8628
7841
|
fill: withGradientFill ? `url(#area-gradient-${chartId}-${index + 1})` : "transparent",
|
|
8629
7842
|
renderLine: true,
|
|
8630
7843
|
curve: getCurveType(curveType, smoothing),
|
|
8631
7844
|
lineProps
|
|
8632
|
-
}, _optionalChain([seriesData, 'optionalAccess',
|
|
7845
|
+
}, _optionalChain([seriesData, 'optionalAccess', _247 => _247.label])), withStartGlyphs && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, line_chart_glyph_default, {
|
|
8633
7846
|
index,
|
|
8634
7847
|
data: seriesData,
|
|
8635
7848
|
color,
|
|
@@ -8646,7 +7859,7 @@ var LineChartInternal = /* @__PURE__ */ _react.forwardRef.call(void 0, ({
|
|
|
8646
7859
|
glyphStyle,
|
|
8647
7860
|
position: "end"
|
|
8648
7861
|
})]
|
|
8649
|
-
}, _optionalChain([seriesData, 'optionalAccess',
|
|
7862
|
+
}, _optionalChain([seriesData, 'optionalAccess', _248 => _248.label]) || index);
|
|
8650
7863
|
}), withTooltips && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, AccessibleTooltip, {
|
|
8651
7864
|
detectBounds: true,
|
|
8652
7865
|
snapTooltipToDatumX: true,
|
|
@@ -8655,8 +7868,8 @@ var LineChartInternal = /* @__PURE__ */ _react.forwardRef.call(void 0, ({
|
|
|
8655
7868
|
renderTooltip,
|
|
8656
7869
|
renderGlyph: tooltipRenderGlyph,
|
|
8657
7870
|
glyphStyle,
|
|
8658
|
-
showVerticalCrosshair: _optionalChain([withTooltipCrosshairs, 'optionalAccess',
|
|
8659
|
-
showHorizontalCrosshair: _optionalChain([withTooltipCrosshairs, 'optionalAccess',
|
|
7871
|
+
showVerticalCrosshair: _optionalChain([withTooltipCrosshairs, 'optionalAccess', _249 => _249.showVertical]),
|
|
7872
|
+
showHorizontalCrosshair: _optionalChain([withTooltipCrosshairs, 'optionalAccess', _250 => _250.showHorizontal]),
|
|
8660
7873
|
selectedIndex,
|
|
8661
7874
|
tooltipRef,
|
|
8662
7875
|
keyboardFocusedClassName: line_chart_module_default["line-chart__tooltip--keyboard-focused"],
|
|
@@ -8904,19 +8117,19 @@ var PieChartInternal = ({
|
|
|
8904
8117
|
});
|
|
8905
8118
|
}
|
|
8906
8119
|
const padAngle = gapScale * (2 * Math.PI / data.length);
|
|
8907
|
-
const dataWithIndex = visibleData.map((
|
|
8908
|
-
const originalIndex = data.findIndex((item) => item.label ===
|
|
8120
|
+
const dataWithIndex = visibleData.map((d) => {
|
|
8121
|
+
const originalIndex = data.findIndex((item) => item.label === d.label);
|
|
8909
8122
|
return {
|
|
8910
|
-
...
|
|
8123
|
+
...d,
|
|
8911
8124
|
index: originalIndex >= 0 ? originalIndex : 0
|
|
8912
8125
|
};
|
|
8913
8126
|
});
|
|
8914
8127
|
const accessors = {
|
|
8915
|
-
value: (
|
|
8916
|
-
fill: (
|
|
8128
|
+
value: (d) => d.value,
|
|
8129
|
+
fill: (d) => {
|
|
8917
8130
|
return getElementStyles({
|
|
8918
|
-
data:
|
|
8919
|
-
index:
|
|
8131
|
+
data: d,
|
|
8132
|
+
index: d.index
|
|
8920
8133
|
}).color;
|
|
8921
8134
|
}
|
|
8922
8135
|
};
|
|
@@ -9043,9 +8256,12 @@ var PieChartInternal = ({
|
|
|
9043
8256
|
groupProps.onMouseMove = handleMouseMove;
|
|
9044
8257
|
groupProps.onMouseLeave = onMouseLeave;
|
|
9045
8258
|
}
|
|
9046
|
-
const
|
|
8259
|
+
const svgLabelSmall = providerTheme.svgLabelSmall;
|
|
8260
|
+
const fontSize = _nullishCoalesce(resolveFontSize(_optionalChain([svgLabelSmall, 'optionalAccess', _251 => _251.fontSize])), () => ( 12));
|
|
9047
8261
|
const estimatedTextWidth = _chunk7OZEQ5HEcjs.getStringWidth.call(void 0, arc.data.label, {
|
|
9048
|
-
fontSize
|
|
8262
|
+
fontSize,
|
|
8263
|
+
fontFamily: _optionalChain([svgLabelSmall, 'optionalAccess', _252 => _252.fontFamily]),
|
|
8264
|
+
fontWeight: _optionalChain([svgLabelSmall, 'optionalAccess', _253 => _253.fontWeight])
|
|
9049
8265
|
});
|
|
9050
8266
|
const labelPadding = 6;
|
|
9051
8267
|
const backgroundWidth = estimatedTextWidth + labelPadding * 2;
|
|
@@ -9246,11 +8462,11 @@ var PieSemiCircleChartInternal = ({
|
|
|
9246
8462
|
isSeriesVisible
|
|
9247
8463
|
});
|
|
9248
8464
|
const accessors = _react.useMemo.call(void 0, () => ({
|
|
9249
|
-
value: (
|
|
9250
|
-
sort: (
|
|
9251
|
-
fill: (
|
|
9252
|
-
data:
|
|
9253
|
-
index:
|
|
8465
|
+
value: (d) => d.value,
|
|
8466
|
+
sort: (a, b) => b.value - a.value,
|
|
8467
|
+
fill: (d) => getElementStyles({
|
|
8468
|
+
data: d,
|
|
8469
|
+
index: d.index
|
|
9254
8470
|
}).color
|
|
9255
8471
|
}), [getElementStyles]);
|
|
9256
8472
|
const legendOptions = _react.useMemo.call(void 0, () => ({
|
|
@@ -9295,10 +8511,10 @@ var PieSemiCircleChartInternal = ({
|
|
|
9295
8511
|
})
|
|
9296
8512
|
});
|
|
9297
8513
|
}
|
|
9298
|
-
const dataWithIndex = visibleData.map((
|
|
9299
|
-
const originalIndex = data.findIndex((item) => item.label ===
|
|
8514
|
+
const dataWithIndex = visibleData.map((d) => {
|
|
8515
|
+
const originalIndex = data.findIndex((item) => item.label === d.label);
|
|
9300
8516
|
return {
|
|
9301
|
-
...
|
|
8517
|
+
...d,
|
|
9302
8518
|
index: originalIndex >= 0 ? originalIndex : 0
|
|
9303
8519
|
};
|
|
9304
8520
|
});
|
|
@@ -9495,7 +8711,7 @@ var SparklineComponent = /* @__PURE__ */ _react.forwardRef.call(void 0, ({
|
|
|
9495
8711
|
animation
|
|
9496
8712
|
}, ref) => {
|
|
9497
8713
|
const theme = useGlobalChartsTheme();
|
|
9498
|
-
const themeStrokeWidth = _nullishCoalesce(_optionalChain([theme, 'access',
|
|
8714
|
+
const themeStrokeWidth = _nullishCoalesce(_optionalChain([theme, 'access', _254 => _254.sparkline, 'optionalAccess', _255 => _255.strokeWidth]), () => ( 1.5));
|
|
9499
8715
|
const strokeWidth = _nullishCoalesce(strokeWidthProp, () => ( themeStrokeWidth));
|
|
9500
8716
|
const seriesData = _react.useMemo.call(void 0, () => {
|
|
9501
8717
|
if (!data || data.length === 0) {
|
|
@@ -9504,7 +8720,7 @@ var SparklineComponent = /* @__PURE__ */ _react.forwardRef.call(void 0, ({
|
|
|
9504
8720
|
return transformToSeriesData(data, color, strokeWidth);
|
|
9505
8721
|
}, [data, color, strokeWidth]);
|
|
9506
8722
|
const finalMargin = _react.useMemo.call(void 0, () => {
|
|
9507
|
-
const themeMargin = _nullishCoalesce(_optionalChain([theme, 'access',
|
|
8723
|
+
const themeMargin = _nullishCoalesce(_optionalChain([theme, 'access', _256 => _256.sparkline, 'optionalAccess', _257 => _257.margin]), () => ( {
|
|
9508
8724
|
top: 2,
|
|
9509
8725
|
right: 2,
|
|
9510
8726
|
bottom: 2,
|
|
@@ -9515,7 +8731,7 @@ var SparklineComponent = /* @__PURE__ */ _react.forwardRef.call(void 0, ({
|
|
|
9515
8731
|
...themeMargin,
|
|
9516
8732
|
...margin
|
|
9517
8733
|
};
|
|
9518
|
-
}, [marginProp, _optionalChain([theme, 'access',
|
|
8734
|
+
}, [marginProp, _optionalChain([theme, 'access', _258 => _258.sparkline, 'optionalAccess', _259 => _259.margin])]);
|
|
9519
8735
|
const seriesWithGradient = _react.useMemo.call(void 0, () => {
|
|
9520
8736
|
if (!gradient || seriesData.length === 0) {
|
|
9521
8737
|
return seriesData;
|
|
@@ -9620,7 +8836,7 @@ var DIRECTION_LABELS = {
|
|
|
9620
8836
|
down: "Decrease",
|
|
9621
8837
|
neutral: "No change"
|
|
9622
8838
|
};
|
|
9623
|
-
var
|
|
8839
|
+
var Icon2 = ({
|
|
9624
8840
|
direction
|
|
9625
8841
|
}) => {
|
|
9626
8842
|
if (direction === "neutral") {
|
|
@@ -9653,7 +8869,7 @@ function TrendIndicator({
|
|
|
9653
8869
|
className: _clsx2.default.call(void 0, trend_indicator_module_default["trend-indicator"], trend_indicator_module_default[`trend-indicator--${direction}`], className),
|
|
9654
8870
|
style,
|
|
9655
8871
|
"aria-label": ariaLabel,
|
|
9656
|
-
children: [showIcon && /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
8872
|
+
children: [showIcon && /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Icon2, {
|
|
9657
8873
|
direction
|
|
9658
8874
|
}), /* @__PURE__ */ _jsxruntime.jsx.call(void 0, "span", {
|
|
9659
8875
|
className: trend_indicator_module_default["trend-indicator__value"],
|