chunk-AEFA3FTZ.js 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381
  1. import {
  2. n as n4
  3. } from "./chunk-XBH7TGC2.js";
  4. import {
  5. c,
  6. e,
  7. i as i2,
  8. n as n3,
  9. o
  10. } from "./chunk-K3NA3LQS.js";
  11. import {
  12. q
  13. } from "./chunk-7SW2GQFP.js";
  14. import {
  15. p,
  16. y
  17. } from "./chunk-EGVIPYN2.js";
  18. import {
  19. i,
  20. n2 as n
  21. } from "./chunk-7256PFPA.js";
  22. import {
  23. l
  24. } from "./chunk-7XXXCK2A.js";
  25. import {
  26. U
  27. } from "./chunk-VNFRAYHO.js";
  28. import {
  29. n as n2
  30. } from "./chunk-R5IG2D6H.js";
  31. import {
  32. s3 as s
  33. } from "./chunk-EMJ4ZSM2.js";
  34. import {
  35. a
  36. } from "./chunk-GZT4BVFP.js";
  37. // node_modules/@arcgis/core/symbols/support/svgUtils.js
  38. var h = "http://www.w3.org/2000/svg";
  39. var f = 0;
  40. var c2 = 0;
  41. var d = a("android");
  42. var u = a("chrome") || d && d >= 4 ? "auto" : "optimizeLegibility";
  43. var y2 = { m: 2, l: 2, h: 1, v: 1, c: 6, s: 4, q: 4, t: 2, a: 7, z: 0 };
  44. var p2 = /([A-DF-Za-df-z])|([-+]?\d*[.]?\d+(?:[eE][-+]?\d+)?)/g;
  45. var g = {};
  46. var x = {};
  47. var m = { solid: "none", shortdash: [4, 1], shortdot: [1, 1], shortdashdot: [4, 1, 1, 1], shortdashdotdot: [4, 1, 1, 1, 1, 1], dot: [1, 3], dash: [4, 3], longdash: [8, 3], dashdot: [4, 3, 1, 3], longdashdot: [8, 3, 1, 3], longdashdotdot: [8, 3, 1, 3, 1, 3] };
  48. var w = Math.PI;
  49. var k = 1;
  50. function b(t, e2) {
  51. const i3 = t * (w / 180);
  52. return Math.abs(e2 * Math.sin(i3)) + Math.abs(e2 * Math.cos(i3));
  53. }
  54. function j(t) {
  55. return t.map((t2) => `${t2.command} ${t2.values.join(" ")}`).join(" ").trim();
  56. }
  57. function v(t, e2, i3, r) {
  58. if (t) {
  59. if (t.type === "circle")
  60. return n("circle", { fill: e2, "fill-rule": "evenodd", stroke: i3.color, "stroke-width": i3.width, "stroke-linecap": i3.cap, "stroke-linejoin": i3.join, "stroke-dasharray": i3.dashArray, "stroke-dashoffset": i3.dashOffset, "stroke-miterlimit": "4", cx: t.cx, cy: t.cy, r: t.r });
  61. if (t.type === "ellipse")
  62. return n("ellipse", { fill: e2, "fill-rule": "evenodd", stroke: i3.color, "stroke-width": i3.width, "stroke-linecap": i3.cap, "stroke-linejoin": i3.join, "stroke-dasharray": i3.dashArray, "stroke-miterlimit": "4", cx: t.cx, cy: t.cy, rx: t.rx, ry: t.ry });
  63. if (t.type === "rect")
  64. return n("rect", { fill: e2, "fill-rule": "evenodd", stroke: i3.color, "stroke-width": i3.width, "stroke-linecap": i3.cap, "stroke-linejoin": i3.join, "stroke-dasharray": i3.dashArray, "stroke-miterlimit": "4", x: t.x, y: t.y, width: t.width, height: t.height });
  65. if (t.type === "image")
  66. return n("image", { href: t.src, x: t.x, y: t.y, width: t.width, height: t.height, preserveAspectRatio: "none" });
  67. if (t.type === "path") {
  68. const r2 = typeof t.path != "string" ? j(t.path) : t.path;
  69. return n("path", { fill: e2, "fill-rule": "evenodd", stroke: i3.color, "stroke-width": i3.width, "stroke-linecap": i3.cap, "stroke-linejoin": i3.join, "stroke-dasharray": i3.dashArray, "stroke-miterlimit": "4", d: r2 });
  70. }
  71. if (t.type === "text")
  72. return n("text", { "alignment-baseline": r.alignBaseline, fill: e2, "fill-rule": "evenodd", stroke: i3.color, "stroke-width": i3.width, "stroke-linecap": i3.cap, "stroke-linejoin": i3.join, "stroke-dasharray": i3.dashArray, "stroke-miterlimit": "4", "text-anchor": r.align, "text-decoration": r.decoration, kerning: r.kerning, rotate: r.rotate, "text-rendering": u, "font-style": r.font.style, "font-variant": r.font.variant, "font-weight": r.font.weight, "font-size": r.font.size, "font-family": r.font.family, x: t.x, y: t.y }, t.text);
  73. }
  74. return null;
  75. }
  76. function M(e2) {
  77. const i3 = { fill: "none", pattern: null, linearGradient: null };
  78. if (e2) {
  79. if ("type" in e2 && e2.type === "pattern") {
  80. const t = "patternId-" + ++f;
  81. i3.fill = `url(#${t})`, i3.pattern = { id: t, x: e2.x, y: e2.y, width: e2.width, height: e2.height, image: { x: 0, y: 0, width: e2.width, height: e2.height, href: e2.src } };
  82. } else if ("type" in e2 && e2.type === "linear") {
  83. const r = "linearGradientId-" + ++c2;
  84. i3.fill = `url(#${r})`, i3.linearGradient = { id: r, x1: e2.x1, y1: e2.y1, x2: e2.x2, y2: e2.y2, stops: e2.colors.map((e3) => ({ offset: e3.offset, color: e3.color && new l(e3.color).toString() })) };
  85. } else if (e2) {
  86. const r = new l(e2);
  87. i3.fill = r.toString();
  88. }
  89. }
  90. return i3;
  91. }
  92. function A(e2) {
  93. const i3 = { color: "none", width: 1, cap: "butt", join: "4", dashArray: "none", dashOffset: "0" };
  94. if (e2 && (e2.width != null && (i3.width = e2.width), e2.cap && (i3.cap = e2.cap), e2.join && (i3.join = e2.join.toString()), e2.color && (i3.color = new l(e2.color).toString()), e2.dashArray && (i3.dashArray = e2.dashArray), e2.dashArray && (i3.dashOffset = e2.dashoffset), e2.style)) {
  95. let t = null;
  96. if (e2.style in m && (t = m[e2.style]), Array.isArray(t)) {
  97. t = t.slice(0);
  98. for (let i4 = 0; i4 < t.length; ++i4)
  99. t[i4] *= e2.width;
  100. if (e2.cap !== "butt") {
  101. for (let i4 = 0; i4 < t.length; i4 += 2)
  102. t[i4] -= e2.width, t[i4] < 1 && (t[i4] = 1);
  103. for (let i4 = 1; i4 < t.length; i4 += 2)
  104. t[i4] += e2.width;
  105. }
  106. t = t.join(",");
  107. }
  108. i3.dashArray = t;
  109. }
  110. return i3;
  111. }
  112. function S(t, e2) {
  113. const i3 = { align: null, decoration: null, kerning: null, rotate: null, font: { style: null, variant: null, weight: null, size: null, family: null } };
  114. return t && (i3.align = t.align, i3.alignBaseline = t.alignBaseline, i3.decoration = t.decoration, i3.kerning = t.kerning ? "auto" : "0", i3.rotate = t.rotated ? "90" : "0", i3.font.style = e2.style || "normal", i3.font.variant = e2.variant || "normal", i3.font.weight = e2.weight || "normal", i3.font.size = e2.size && e2.size.toString() || "10pt", i3.font.family = e2.family || "serif"), i3;
  115. }
  116. function $(t) {
  117. const { pattern: e2, linearGradient: i3 } = t;
  118. if (e2)
  119. return n("pattern", { id: e2.id, patternUnits: "userSpaceOnUse", x: e2.x, y: e2.y, width: e2.width, height: e2.height }, n("image", { x: e2.image.x, y: e2.image.y, width: e2.image.width, height: e2.image.height, href: e2.image.href }));
  120. if (i3) {
  121. const t2 = i3.stops.map((t3, e3) => n("stop", { key: `${e3}-stop`, offset: t3.offset, "stop-color": t3.color }));
  122. return n("linearGradient", { id: i3.id, gradientUnits: "userSpaceOnUse", x1: i3.x1, y1: i3.y1, x2: i3.x2, y2: i3.y2 }, t2);
  123. }
  124. return null;
  125. }
  126. function N(t, e2) {
  127. if (!t)
  128. return null;
  129. const i3 = [];
  130. for (const r of t) {
  131. const { shape: t2, fill: e3, stroke: n5, font: o2 } = r, s2 = M(e3), a2 = A(n5), l3 = t2.type === "text" ? S(t2, o2) : null;
  132. i3.push(v(t2, s2.fill, a2, l3));
  133. }
  134. return n("mask", { id: e2, maskUnits: "userSpaceOnUse" }, n("g", null, i3));
  135. }
  136. function G(t, e2, i3) {
  137. return i2(t, n3(t), [e2, i3]);
  138. }
  139. function I(t, e2, i3, r, n5) {
  140. return c(t, n3(t), [e2, i3]), t[4] = t[4] * e2 - r * e2 + r, t[5] = t[5] * i3 - n5 * i3 + n5, t;
  141. }
  142. function z(t, e2, i3, r) {
  143. const n5 = e2 % 360 * Math.PI / 180;
  144. e(t, n3(t), n5);
  145. const s2 = Math.cos(n5), l3 = Math.sin(n5), h3 = t[4], f3 = t[5];
  146. return t[4] = h3 * s2 - f3 * l3 + r * l3 - i3 * s2 + i3, t[5] = f3 * s2 + h3 * l3 - i3 * l3 - r * s2 + r, t;
  147. }
  148. function B(t, e2) {
  149. g && "left" in g ? (g.left > t && (g.left = t), g.right < t && (g.right = t), g.top > e2 && (g.top = e2), g.bottom < e2 && (g.bottom = e2)) : g = { left: t, bottom: e2, right: t, top: e2 };
  150. }
  151. function U2(t) {
  152. const e2 = t.args, i3 = e2.length;
  153. let r;
  154. switch (t.action) {
  155. case "M":
  156. case "L":
  157. case "C":
  158. case "S":
  159. case "Q":
  160. case "T":
  161. for (r = 0; r < i3; r += 2)
  162. B(e2[r], e2[r + 1]);
  163. x.x = e2[i3 - 2], x.y = e2[i3 - 1];
  164. break;
  165. case "H":
  166. for (r = 0; r < i3; ++r)
  167. B(e2[r], x.y);
  168. x.x = e2[i3 - 1];
  169. break;
  170. case "V":
  171. for (r = 0; r < i3; ++r)
  172. B(x.x, e2[r]);
  173. x.y = e2[i3 - 1];
  174. break;
  175. case "m": {
  176. let t2 = 0;
  177. "x" in x || (B(x.x = e2[0], x.y = e2[1]), t2 = 2);
  178. for (r = t2; r < i3; r += 2)
  179. B(x.x += e2[r], x.y += e2[r + 1]);
  180. break;
  181. }
  182. case "l":
  183. case "t":
  184. for (r = 0; r < i3; r += 2)
  185. B(x.x += e2[r], x.y += e2[r + 1]);
  186. break;
  187. case "h":
  188. for (r = 0; r < i3; ++r)
  189. B(x.x += e2[r], x.y);
  190. break;
  191. case "v":
  192. for (r = 0; r < i3; ++r)
  193. B(x.x, x.y += e2[r]);
  194. break;
  195. case "c":
  196. for (r = 0; r < i3; r += 6)
  197. B(x.x + e2[r], x.y + e2[r + 1]), B(x.x + e2[r + 2], x.y + e2[r + 3]), B(x.x += e2[r + 4], x.y += e2[r + 5]);
  198. break;
  199. case "s":
  200. case "q":
  201. for (r = 0; r < i3; r += 4)
  202. B(x.x + e2[r], x.y + e2[r + 1]), B(x.x += e2[r + 2], x.y += e2[r + 3]);
  203. break;
  204. case "A":
  205. for (r = 0; r < i3; r += 7)
  206. B(e2[r + 5], e2[r + 6]);
  207. x.x = e2[i3 - 2], x.y = e2[i3 - 1];
  208. break;
  209. case "a":
  210. for (r = 0; r < i3; r += 7)
  211. B(x.x += e2[r + 5], x.y += e2[r + 6]);
  212. }
  213. }
  214. function F(t, e2, i3) {
  215. const r = y2[t.toLowerCase()];
  216. let n5;
  217. typeof r == "number" && (r ? e2.length >= r && (n5 = { action: t, args: e2.slice(0, e2.length - e2.length % r) }, i3.push(n5), U2(n5)) : (n5 = { action: t, args: [] }, i3.push(n5), U2(n5)));
  218. }
  219. function O(t) {
  220. const e2 = (typeof t.path != "string" ? j(t.path) : t.path).match(p2), i3 = [];
  221. if (g = {}, x = {}, !e2)
  222. return null;
  223. let r = "", n5 = [];
  224. const o2 = e2.length;
  225. for (let a2 = 0; a2 < o2; ++a2) {
  226. const t2 = e2[a2], o3 = parseFloat(t2);
  227. isNaN(o3) ? (r && F(r, n5, i3), n5 = [], r = t2) : n5.push(o3);
  228. }
  229. F(r, n5, i3);
  230. const s2 = { x: 0, y: 0, width: 0, height: 0 };
  231. return g && "left" in g && (s2.x = g.left, s2.y = g.top, s2.width = g.right - g.left, s2.height = g.bottom - g.top), s2;
  232. }
  233. function T(t) {
  234. const e2 = { x: 0, y: 0, width: 0, height: 0 };
  235. if (t.type === "circle")
  236. e2.x = t.cx - t.r, e2.y = t.cy - t.r, e2.width = 2 * t.r, e2.height = 2 * t.r;
  237. else if (t.type === "ellipse")
  238. e2.x = t.cx - t.rx, e2.y = t.cy - t.ry, e2.width = 2 * t.rx, e2.height = 2 * t.ry;
  239. else if (t.type === "image" || t.type === "rect")
  240. e2.x = t.x, e2.y = t.y, e2.width = t.width, e2.height = t.height;
  241. else if (t.type === "path") {
  242. const i3 = O(t);
  243. e2.x = i3.x, e2.y = i3.y, e2.width = i3.width, e2.height = i3.height;
  244. }
  245. return e2;
  246. }
  247. function E(t) {
  248. const e2 = { x: 0, y: 0, width: 0, height: 0 };
  249. let i3 = null, r = Number.NEGATIVE_INFINITY, n5 = Number.NEGATIVE_INFINITY;
  250. for (const o2 of t)
  251. i3 ? (i3.x = Math.min(i3.x, o2.x), i3.y = Math.min(i3.y, o2.y), r = Math.max(r, o2.x + o2.width), n5 = Math.max(n5, o2.y + o2.height)) : (i3 = e2, i3.x = o2.x, i3.y = o2.y, r = o2.x + o2.width, n5 = o2.y + o2.height);
  252. return i3 && (i3.width = r - i3.x, i3.height = n5 - i3.y), i3;
  253. }
  254. function V(t, e2, n5, o2, s2, a2, l3, h3, f3) {
  255. let c3 = (l3 && a2 ? b(a2, e2) : e2) / 2, d3 = (l3 && a2 ? b(a2, n5) : n5) / 2;
  256. if (f3) {
  257. const t2 = f3[0], e3 = f3[1];
  258. c3 = (l3 && a2 ? b(a2, t2) : t2) / 2, d3 = (l3 && a2 ? b(a2, e3) : e3) / 2;
  259. }
  260. const u3 = t.width + o2, y3 = t.height + o2, p3 = n4(), g3 = n4();
  261. let x2 = false;
  262. if (s2 && u3 !== 0 && y3 !== 0) {
  263. const t2 = e2 !== n5 ? e2 / n5 : u3 / y3, i3 = e2 > n5 ? e2 : n5;
  264. let o3 = 1, s3 = 1;
  265. isNaN(i3) || (t2 > 1 ? (o3 = i3 / u3, s3 = i3 / t2 / y3) : (s3 = i3 / y3, o3 = i3 * t2 / u3)), o(g3, g3, I(p3, o3, s3, c3, d3)), x2 = true;
  266. }
  267. const m3 = t.x + (u3 - o2) / 2, w2 = t.y + (y3 - o2) / 2;
  268. if (o(g3, g3, G(p3, c3 - m3, d3 - w2)), !x2 && (u3 > e2 || y3 > n5)) {
  269. const t2 = u3 / e2 > y3 / n5, i3 = (t2 ? e2 : n5) / (t2 ? u3 : y3);
  270. o(g3, g3, I(p3, i3, i3, m3, w2));
  271. }
  272. return a2 && o(g3, g3, z(p3, a2, m3, w2)), h3 && o(g3, g3, G(p3, h3[0], h3[1])), `matrix(${g3[0]},${g3[1]},${g3[2]},${g3[3]},${g3[4]},${g3[5]})`;
  273. }
  274. function C(t, e2, i3) {
  275. const r = t?.effects.find((t2) => t2.type === "bloom");
  276. if (!r)
  277. return null;
  278. const { strength: n5, radius: o2 } = r, s2 = n5 > 0 ? o2 : 0, a2 = (n5 + s2) * e2, h3 = 4 * n5 + 1;
  279. return n("filter", { id: `bloom${i3}`, x: "-100%", y: "-100%", width: "300%", height: "300%", filterUnits: "userSpaceOnUse" }, n("feMorphology", { operator: "dilate", radius: (n5 + 0.5 * s2) * (5 ** (e2 / 100) * (0.4 + e2 / 100)), in: "SourceGraphic", result: "dilate" }), n("feGaussianBlur", { in: "dilate", stdDeviation: a2 / 25, result: "blur" }), n("feGaussianBlur", { in: "blur", stdDeviation: a2 / 50, result: "intensityBlur" }), n("feComponentTransfer", { in: "SourceGraphic", result: "intensityBrightness" }, n("feFuncR", { type: "linear", slope: h3 }), n("feFuncG", { type: "linear", slope: h3 }), n("feFuncB", { type: "linear", slope: h3 })), n("feMerge", null, n("feMergeNode", { in: "intensityBlur" }), n("feMergeNode", { in: "intensityBrightness" }), n("feGaussianBlur", { stdDeviation: n5 / 10 })));
  280. }
  281. function D(t, e2, i3, r = {}) {
  282. const n5 = [], o2 = [], s2 = ++k, a2 = C(r.effectView, e2, s2);
  283. let f3 = null;
  284. if (a2) {
  285. const t2 = r.effectView?.effects.find((t3) => t3.type === "bloom"), n6 = (t2.strength ? t2.strength + t2.radius / 2 : 0) / 3, o3 = e2 + e2 * n6, s3 = i3 + i3 * n6;
  286. f3 = [Math.max(o3, 10), Math.max(s3, 10)];
  287. }
  288. for (let h3 = 0; h3 < t.length; h3++) {
  289. const s3 = t[h3], a3 = [], c3 = [];
  290. let d3 = 0, u3 = 0, y3 = 0;
  291. for (const t2 of s3) {
  292. const { shape: e3, fill: i4, stroke: o3, font: s4, offset: l3 } = t2;
  293. r.ignoreStrokeWidth || (d3 += o3 && o3.width || 0);
  294. const h4 = M(i4), f4 = A(o3), p4 = e3.type === "text" ? S(e3, s4) : null;
  295. n5.push($(h4)), a3.push(v(e3, h4.fill, f4, p4)), c3.push(T(e3)), l3 && (u3 += l3[0], y3 += l3[1]);
  296. }
  297. const p3 = V(E(c3), e2, i3, d3, r.scale, r.rotation, r.useRotationSize, [u3, y3], f3);
  298. let g3 = null;
  299. if (r.masking) {
  300. const t2 = `mask-${h3}`, e3 = r.masking[h3];
  301. n5.push(N(e3, t2)), g3 = `url(#${t2})`;
  302. }
  303. o2.push(g3 ? n("g", { mask: g3 }, n("g", { transform: p3 }, a3)) : n("g", { transform: p3 }, a3));
  304. }
  305. r.useRotationSize && r.rotation && (e2 = b(r.rotation, e2), i3 = b(r.rotation, i3)), a2 && (e2 = f3[0], i3 = f3[1]);
  306. return n("svg", { xmlns: h, width: e2, height: i3, style: "display: block;" }, a2, n("defs", null, n5), a2 ? n("g", { filter: `url(#bloom${s2})` }, o2) : o2);
  307. }
  308. // node_modules/@arcgis/core/symbols/support/renderUtils.js
  309. var h2 = i();
  310. function l2(t, e2, i3) {
  311. const r = Math.ceil(e2[0]), n5 = Math.ceil(e2[1]);
  312. if (!t.some((t2) => !!t2.length))
  313. return null;
  314. const o2 = i3 && i3.node || document.createElement("div");
  315. return i3.opacity != null && (o2.style.opacity = i3.opacity.toString()), i3.effectView != null && (o2.style.filter = q(i3.effectView)), h2.append(o2, D.bind(null, t, r, n5, i3)), o2;
  316. }
  317. function m2(t, e2) {
  318. t = Math.ceil(t), e2 = Math.ceil(e2);
  319. const i3 = document.createElement("canvas");
  320. i3.width = t, i3.height = e2, i3.style.width = t + "px", i3.style.height = e2 + "px";
  321. const r = i3.getContext("2d");
  322. return r.clearRect(0, 0, t, e2), r;
  323. }
  324. function g2(t, i3, r) {
  325. return t ? U(t, { responseType: "image" }).then((t2) => {
  326. const e2 = t2.data, n5 = e2.width, o2 = e2.height, a2 = n5 / o2;
  327. let c3 = i3;
  328. if (r) {
  329. const t3 = Math.max(n5, o2);
  330. c3 = Math.min(c3, t3);
  331. }
  332. return { image: e2, width: a2 <= 1 ? Math.ceil(c3 * a2) : c3, height: a2 <= 1 ? c3 : Math.ceil(c3 / a2) };
  333. }) : Promise.reject(new s("renderUtils: imageDataSize", "href not provided."));
  334. }
  335. function u2(t, e2) {
  336. return !(!t || e2 === "ignore") && (e2 !== "multiply" || t.r !== 255 || t.g !== 255 || t.b !== 255 || t.a !== 1);
  337. }
  338. function d2(t, e2, n5, o2, a2) {
  339. switch (a2) {
  340. case "multiply":
  341. t[e2 + 0] *= n5[0], t[e2 + 1] *= n5[1], t[e2 + 2] *= n5[2], t[e2 + 3] *= n5[3];
  342. break;
  343. default: {
  344. const a3 = y({ r: t[e2 + 0], g: t[e2 + 1], b: t[e2 + 2] });
  345. a3.h = o2.h, a3.s = o2.s, a3.v = a3.v / 100 * o2.v;
  346. const c3 = p(a3);
  347. t[e2 + 0] = c3.r, t[e2 + 1] = c3.g, t[e2 + 2] = c3.b, t[e2 + 3] *= n5[3];
  348. break;
  349. }
  350. }
  351. }
  352. function f2(e2, r, n5, a2, c3) {
  353. return g2(e2, r, c3).then((c4) => {
  354. const s2 = c4.width ? c4.width : r, h3 = c4.height ? c4.height : r;
  355. if (c4.image && u2(n5, a2)) {
  356. let t = c4.image.width, r2 = c4.image.height;
  357. a("edge") && /\.svg$/i.test(e2) && (t -= 1, r2 -= 1);
  358. const l3 = m2(s2, h3);
  359. l3.drawImage(c4.image, 0, 0, t, r2, 0, 0, s2, h3);
  360. const g3 = l3.getImageData(0, 0, s2, h3), u3 = [n5.r / 255, n5.g / 255, n5.b / 255, n5.a], f3 = y(n5);
  361. for (let e3 = 0; e3 < g3.data.length; e3 += 4)
  362. d2(g3.data, e3, u3, f3, a2);
  363. l3.putImageData(g3, 0, 0), e2 = l3.canvas.toDataURL("image/png");
  364. } else {
  365. const i3 = n2 && n2.findCredential(e2);
  366. if (i3 && i3.token) {
  367. const t = e2.includes("?") ? "&" : "?";
  368. e2 = `${e2}${t}token=${i3.token}`;
  369. }
  370. }
  371. return { url: e2, width: s2, height: h3 };
  372. }).catch(() => ({ url: e2, width: r, height: r }));
  373. }
  374. export {
  375. l2 as l,
  376. f2 as f
  377. };
  378. //# sourceMappingURL=chunk-AEFA3FTZ.js.map