@devgateway/dvz-ui-react 1.6.20 → 1.7.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (156) hide show
  1. package/dist/cjs/_virtual/_commonjsHelpers.js +1 -0
  2. package/dist/cjs/_virtual/debounce.js +1 -0
  3. package/dist/cjs/embeddable/big-filter/BigNumberGroup.js +1 -0
  4. package/dist/cjs/embeddable/big-filter/BigNumberItem.js +1 -0
  5. package/dist/cjs/embeddable/big-filter/DataProvider.js +1 -0
  6. package/dist/cjs/embeddable/big-filter/index.js +1 -0
  7. package/dist/cjs/embeddable/big-number/index.js +1 -1
  8. package/dist/cjs/embeddable/big-number-trend/Alternative.js +1 -0
  9. package/dist/cjs/embeddable/big-number-trend/Classic.js +1 -0
  10. package/dist/cjs/embeddable/big-number-trend/index.js +1 -1
  11. package/dist/cjs/embeddable/chart/Bar.js +1 -1
  12. package/dist/cjs/embeddable/chart/Line.js +1 -1
  13. package/dist/cjs/embeddable/chart/data/Bar.js +1 -1
  14. package/dist/cjs/embeddable/chart/data/Line.js +1 -1
  15. package/dist/cjs/embeddable/chart/data/Utils.js +1 -1
  16. package/dist/cjs/embeddable/chart/index.js +1 -1
  17. package/dist/cjs/embeddable/d3Map/BaseLayer.js +1 -1
  18. package/dist/cjs/embeddable/d3Map/BreaksStyles.js +1 -1
  19. package/dist/cjs/embeddable/d3Map/DataLayer.js +1 -1
  20. package/dist/cjs/embeddable/d3Map/FlowLayer.js +1 -1
  21. package/dist/cjs/embeddable/d3Map/GradientColors.js +1 -1
  22. package/dist/cjs/embeddable/d3Map/LatLongLayer.js +1 -1
  23. package/dist/cjs/embeddable/d3Map/Layer.js +1 -1
  24. package/dist/cjs/embeddable/d3Map/Legends.js +1 -1
  25. package/dist/cjs/embeddable/d3Map/ProjectedContainer.js +1 -1
  26. package/dist/cjs/embeddable/d3Map/Utils.js +1 -1
  27. package/dist/cjs/embeddable/d3Map/ZoomControl.js +1 -1
  28. package/dist/cjs/embeddable/d3Map/index.js +1 -1
  29. package/dist/cjs/embeddable/data/CategoriesProvider.js +1 -1
  30. package/dist/cjs/embeddable/data/D3MapDataConsumer.js +1 -0
  31. package/dist/cjs/embeddable/data/D3MapDataProvider.js +1 -0
  32. package/dist/cjs/embeddable/data/DataContext.js +1 -1
  33. package/dist/cjs/embeddable/data/DataProvider.js +1 -1
  34. package/dist/cjs/embeddable/data-paragraph/index.js +1 -0
  35. package/dist/cjs/embeddable/download/dom-to-image.js +2 -2
  36. package/dist/cjs/embeddable/download/index.js +5 -5
  37. package/dist/cjs/embeddable/filter/index.js +1 -1
  38. package/dist/cjs/embeddable/grouped-bars/GroupedBars.js +1 -0
  39. package/dist/cjs/embeddable/grouped-bars/index.js +1 -0
  40. package/dist/cjs/embeddable/index.js +1 -1
  41. package/dist/cjs/embeddable/posts-filter/CategoricalFilter.js +1 -1
  42. package/dist/cjs/embeddable/reducers/data-api.js +1 -1
  43. package/dist/cjs/embeddable/reducers/data.js +1 -1
  44. package/dist/cjs/embeddable/utils/common.js +1 -1
  45. package/dist/cjs/index.js +1 -1
  46. package/dist/cjs/layout/Customizer.js +1 -1
  47. package/dist/cjs/layout/SearchControl.js +1 -1
  48. package/dist/cjs/layout/containers/SlugPostContainer.js +1 -1
  49. package/dist/cjs/node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_Symbol.js +1 -0
  50. package/dist/cjs/node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_baseGetTag.js +1 -0
  51. package/dist/cjs/node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_baseTrim.js +1 -0
  52. package/dist/cjs/node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_freeGlobal.js +1 -0
  53. package/dist/cjs/node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_getRawTag.js +1 -0
  54. package/dist/cjs/node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_objectToString.js +1 -0
  55. package/dist/cjs/node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_root.js +1 -0
  56. package/dist/cjs/node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_trimmedEndIndex.js +1 -0
  57. package/dist/cjs/node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/debounce.js +1 -0
  58. package/dist/cjs/node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/isObject.js +1 -0
  59. package/dist/cjs/node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/isObjectLike.js +1 -0
  60. package/dist/cjs/node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/isSymbol.js +1 -0
  61. package/dist/cjs/node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/now.js +1 -0
  62. package/dist/cjs/node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/toNumber.js +1 -0
  63. package/dist/cjs/styles.css +1 -1
  64. package/dist/esm/_virtual/_commonjsHelpers.js +8 -0
  65. package/dist/esm/_virtual/debounce.js +7 -0
  66. package/dist/esm/embeddable/big-filter/BigNumberGroup.js +129 -0
  67. package/dist/esm/embeddable/big-filter/BigNumberItem.js +107 -0
  68. package/dist/esm/embeddable/big-filter/DataProvider.js +53 -0
  69. package/dist/esm/embeddable/big-filter/index.js +130 -0
  70. package/dist/esm/embeddable/big-number/index.js +154 -102
  71. package/dist/esm/embeddable/big-number-trend/Alternative.js +227 -0
  72. package/dist/esm/embeddable/big-number-trend/Classic.js +190 -0
  73. package/dist/esm/embeddable/big-number-trend/index.js +12 -147
  74. package/dist/esm/embeddable/chart/Bar.js +450 -395
  75. package/dist/esm/embeddable/chart/Line.js +216 -184
  76. package/dist/esm/embeddable/chart/data/Bar.js +16 -18
  77. package/dist/esm/embeddable/chart/data/Line.js +27 -24
  78. package/dist/esm/embeddable/chart/data/Utils.js +3 -1
  79. package/dist/esm/embeddable/chart/index.js +168 -162
  80. package/dist/esm/embeddable/d3Map/BaseLayer.js +25 -28
  81. package/dist/esm/embeddable/d3Map/BreaksStyles.js +17 -10
  82. package/dist/esm/embeddable/d3Map/DataLayer.js +290 -289
  83. package/dist/esm/embeddable/d3Map/FlowLayer.js +122 -136
  84. package/dist/esm/embeddable/d3Map/GradientColors.js +27 -20
  85. package/dist/esm/embeddable/d3Map/LatLongLayer.js +62 -62
  86. package/dist/esm/embeddable/d3Map/Layer.js +31 -27
  87. package/dist/esm/embeddable/d3Map/Legends.js +204 -190
  88. package/dist/esm/embeddable/d3Map/ProjectedContainer.js +1 -3
  89. package/dist/esm/embeddable/d3Map/Utils.js +12 -8
  90. package/dist/esm/embeddable/d3Map/ZoomControl.js +41 -41
  91. package/dist/esm/embeddable/d3Map/index.js +135 -117
  92. package/dist/esm/embeddable/data/CategoriesProvider.js +39 -26
  93. package/dist/esm/embeddable/data/D3MapDataConsumer.js +7 -0
  94. package/dist/esm/embeddable/data/D3MapDataProvider.js +83 -0
  95. package/dist/esm/embeddable/data/DataContext.js +2 -2
  96. package/dist/esm/embeddable/data/DataProvider.js +124 -55
  97. package/dist/esm/embeddable/data-paragraph/index.js +168 -0
  98. package/dist/esm/embeddable/download/dom-to-image.js +163 -148
  99. package/dist/esm/embeddable/download/index.js +102 -76
  100. package/dist/esm/embeddable/filter/index.js +335 -298
  101. package/dist/esm/embeddable/grouped-bars/GroupedBars.js +549 -0
  102. package/dist/esm/embeddable/grouped-bars/index.js +16 -0
  103. package/dist/esm/embeddable/index.js +33 -30
  104. package/dist/esm/embeddable/posts-filter/CategoricalFilter.js +18 -18
  105. package/dist/esm/embeddable/reducers/data-api.js +39 -35
  106. package/dist/esm/embeddable/reducers/data.js +141 -182
  107. package/dist/esm/embeddable/utils/common.js +3 -3
  108. package/dist/esm/index.js +111 -94
  109. package/dist/esm/layout/Customizer.js +10 -9
  110. package/dist/esm/layout/SearchControl.js +103 -113
  111. package/dist/esm/layout/containers/SlugPostContainer.js +1 -1
  112. package/dist/esm/node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_Symbol.js +11 -0
  113. package/dist/esm/node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_baseGetTag.js +16 -0
  114. package/dist/esm/node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_baseTrim.js +14 -0
  115. package/dist/esm/node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_freeGlobal.js +11 -0
  116. package/dist/esm/node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_getRawTag.js +21 -0
  117. package/dist/esm/node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_objectToString.js +13 -0
  118. package/dist/esm/node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_root.js +11 -0
  119. package/dist/esm/node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/_trimmedEndIndex.js +15 -0
  120. package/dist/esm/node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/debounce.js +60 -0
  121. package/dist/esm/node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/isObject.js +13 -0
  122. package/dist/esm/node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/isObjectLike.js +12 -0
  123. package/dist/esm/node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/isSymbol.js +15 -0
  124. package/dist/esm/node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/now.js +13 -0
  125. package/dist/esm/node_modules/.pnpm/lodash@4.17.21/node_modules/lodash/toNumber.js +28 -0
  126. package/dist/esm/styles.css +1 -1
  127. package/dist/types/embeddable/big-filter/BigNumberGroup.d.ts +3 -0
  128. package/dist/types/embeddable/big-filter/BigNumberItem.d.ts +2 -0
  129. package/dist/types/embeddable/big-filter/DataProvider.d.ts +7 -0
  130. package/dist/types/embeddable/big-filter/index.d.ts +5 -0
  131. package/dist/types/embeddable/big-number-trend/Alternative.d.ts +5 -0
  132. package/dist/types/embeddable/big-number-trend/Classic.d.ts +5 -0
  133. package/dist/types/embeddable/big-number-trend/index.d.ts +2 -4
  134. package/dist/types/embeddable/chart/Bar.d.ts +3 -0
  135. package/dist/types/embeddable/chart/Line.d.ts +6 -0
  136. package/dist/types/embeddable/d3Map/GradientColors.d.ts +6 -2
  137. package/dist/types/embeddable/d3Map/Layer.d.ts +1 -1
  138. package/dist/types/embeddable/d3Map/Utils.d.ts +1 -1
  139. package/dist/types/embeddable/data/D3MapDataProvider.d.ts +7 -0
  140. package/dist/types/embeddable/data/index.d.ts +6 -0
  141. package/dist/types/embeddable/data-paragraph/index.d.ts +5 -0
  142. package/dist/types/embeddable/filter/index.d.ts +13 -1
  143. package/dist/types/embeddable/grouped-bars/GroupedBars.d.ts +5 -0
  144. package/dist/types/embeddable/grouped-bars/index.d.ts +3 -0
  145. package/dist/types/embeddable/reducers/data-api.d.ts +5 -0
  146. package/dist/types/embeddable/reducers/data.d.ts +16 -9
  147. package/dist/types/embeddable/utils/index.d.ts +1 -0
  148. package/dist/types/embeddable/utils/parseUtils.d.ts +0 -6
  149. package/dist/types/index.d.ts +6 -0
  150. package/dist/types/layout/Customizer.d.ts +1 -0
  151. package/dist/types/layout/containers/PageContainer.d.ts +8 -0
  152. package/dist/types/layout/containers/PostContainer.d.ts +0 -0
  153. package/dist/types/layout/index.d.ts +1 -0
  154. package/dist/types/utils/Logger.d.ts +1 -0
  155. package/package.json +3 -2
  156. /package/dist/types/embeddable/data/{DataConsumerMap.d.ts → D3MapDataConsumer.d.ts} +0 -0
@@ -1,4 +1,4 @@
1
- const h = z(), R = K(), F = Q(), N = Y(), k = {
1
+ const d = z(), I = K(), F = Q(), N = Y(), k = {
2
2
  // Default is to fail on error, no placeholder
3
3
  imagePlaceholder: void 0,
4
4
  // Default cache bust is false, it will use the cache
@@ -13,75 +13,75 @@ const h = z(), R = K(), F = Q(), N = Y(), k = {
13
13
  impl: {
14
14
  fontFaces: F,
15
15
  images: N,
16
- util: h,
17
- inliner: R,
16
+ util: d,
17
+ inliner: I,
18
18
  options: {}
19
19
  }
20
20
  };
21
21
  typeof module < "u" ? module.exports = b : globalThis.domtoimage = b;
22
- async function j(o, t) {
23
- t = t || {}, $(t);
24
- const n = await Promise.resolve(o), a = await O(n, t.filter, !0), l = await W(a), r = await q(l), s = await d(r);
22
+ async function j(o, n) {
23
+ n = n || {}, $(n);
24
+ const t = await Promise.resolve(o), s = await O(t, n.filter, !0), l = await W(s), r = await q(l), c = await h(r);
25
25
  return await J(
26
- s,
27
- t.width || h.width(o),
28
- t.height || h.height(o)
26
+ c,
27
+ n.width || d.width(o),
28
+ n.height || d.height(o)
29
29
  );
30
- function d(m) {
31
- return t.bgcolor && (m.style.backgroundColor = t.bgcolor), t.width && (m.style.width = t.width + "px"), t.height && (m.style.height = t.height + "px"), t.style && Object.keys(t.style).forEach(function(g) {
32
- m.style[g] = t.style[g];
30
+ function h(m) {
31
+ return n.bgcolor && (m.style.backgroundColor = n.bgcolor), n.width && (m.style.width = n.width + "px"), n.height && (m.style.height = n.height + "px"), n.style && Object.keys(n.style).forEach(function(g) {
32
+ m.style[g] = n.style[g];
33
33
  }), m;
34
34
  }
35
35
  }
36
- async function V(o, t) {
37
- const n = await I(o, t || {});
38
- return n ? n.getContext("2d").getImageData(
36
+ async function V(o, n) {
37
+ const t = await R(o, n || {});
38
+ return t ? t.getContext("2d").getImageData(
39
39
  0,
40
40
  0,
41
- h.width(o),
42
- h.height(o)
41
+ d.width(o),
42
+ d.height(o)
43
43
  ).data : null;
44
44
  }
45
- async function _(o, t) {
46
- const n = await I(o, t || {});
47
- return n ? n.toDataURL() : null;
45
+ async function _(o, n) {
46
+ const t = await R(o, n || {});
47
+ return t ? t.toDataURL() : null;
48
48
  }
49
- async function X(o, t) {
50
- t = t || {};
51
- const n = await I(o, t);
52
- return n ? n.toDataURL("image/jpeg", t.quality || 1) : null;
49
+ async function X(o, n) {
50
+ n = n || {};
51
+ const t = await R(o, n);
52
+ return t ? t.toDataURL("image/jpeg", n.quality || 1) : null;
53
53
  }
54
- function G(o, t) {
55
- return I(o, t || {}).then(h.canvasToBlob);
54
+ function G(o, n) {
55
+ return R(o, n || {}).then(d.canvasToBlob);
56
56
  }
57
57
  function $(o) {
58
58
  typeof o.imagePlaceholder > "u" ? b.impl.options.imagePlaceholder = k.imagePlaceholder : b.impl.options.imagePlaceholder = o.imagePlaceholder, typeof o.cacheBust > "u" ? b.impl.options.cacheBust = k.cacheBust : b.impl.options.cacheBust = o.cacheBust;
59
59
  }
60
- function I(o, t) {
61
- return j(o, t).then(h.makeImage).then(h.delay(100)).then(function(a) {
62
- const l = n(o, t), r = l.getContext("2d");
63
- return r ? (r.drawImage(a, 0, 0), l) : new HTMLCanvasElement();
64
- }).catch(function(a) {
65
- console.error("Failed to draw canvas:", a);
60
+ function R(o, n) {
61
+ return j(o, n).then(d.makeImage).then(d.delay(100)).then(function(s) {
62
+ const l = t(o, n), r = l.getContext("2d");
63
+ return r ? (r.drawImage(s, 0, 0), l) : new HTMLCanvasElement();
64
+ }).catch(function(s) {
65
+ console.error("Failed to draw canvas:", s);
66
66
  });
67
- function n(a, l) {
68
- const r = document.createElement("canvas"), s = a.getBoundingClientRect(), d = window.devicePixelRatio || 1;
69
- r.width = (l.width || s.width) * d, r.height = (l.height || s.height) * d, r.style.width = (l.width || s.width) + "px", r.style.height = (l.height || s.height) + "px";
67
+ function t(s, l) {
68
+ const r = document.createElement("canvas"), c = s.getBoundingClientRect(), h = window.devicePixelRatio || 1;
69
+ r.width = (l.width || c.width) * h, r.height = (l.height || c.height) * h, r.style.width = (l.width || c.width) + "px", r.style.height = (l.height || c.height) + "px";
70
70
  const m = r.getContext("2d");
71
- return m ? (m.scale(d, d), l.bgcolor && (m.fillStyle = l.bgcolor, m.fillRect(0, 0, r.width, r.height)), r) : new HTMLCanvasElement();
71
+ return m ? (m.scale(h, h), l.bgcolor && (m.fillStyle = l.bgcolor, m.fillRect(0, 0, r.width, r.height)), r) : new HTMLCanvasElement();
72
72
  }
73
73
  }
74
- async function O(o, t, n) {
75
- if (!n && t && !t(o)) return Promise.resolve();
76
- const a = await Promise.resolve(o), l = await s(a), r = await d(o, l, t);
74
+ async function O(o, n, t) {
75
+ if (!t && n && !n(o)) return Promise.resolve();
76
+ const s = await Promise.resolve(o), l = await c(s), r = await h(o, l, n);
77
77
  return m(o, r);
78
- function s(g) {
79
- return g instanceof HTMLCanvasElement ? h.makeImage(g.toDataURL()) : g.cloneNode(!1);
78
+ function c(g) {
79
+ return g instanceof HTMLCanvasElement ? d.makeImage(g.toDataURL()) : g.cloneNode(!1);
80
80
  }
81
- async function d(g, c, T) {
81
+ async function h(g, a, T) {
82
82
  const x = g.childNodes;
83
- if (x.length === 0) return Promise.resolve(c);
84
- return await C(c, h.asArray(x), T), c;
83
+ if (x.length === 0) return Promise.resolve(a);
84
+ return await C(a, d.asArray(x), T), a;
85
85
  function C(U, v, p) {
86
86
  let w = Promise.resolve();
87
87
  return v.forEach(function(e) {
@@ -93,17 +93,17 @@ async function O(o, t, n) {
93
93
  }), w;
94
94
  }
95
95
  }
96
- function m(g, c) {
97
- if (!(c instanceof Element)) return c;
96
+ function m(g, a) {
97
+ if (!(a instanceof Element)) return a;
98
98
  return Promise.resolve().then(T).then(x).then(C).then(U).then(function() {
99
- return c;
99
+ return a;
100
100
  });
101
101
  function T() {
102
- v(window.getComputedStyle(g), c.style);
102
+ v(window.getComputedStyle(g), a.style);
103
103
  function v(p, w) {
104
104
  p.cssText ? w.cssText = p.cssText : e(p, w);
105
105
  function e(i, f) {
106
- h.asArray(i).forEach(function(u) {
106
+ d.asArray(i).forEach(function(u) {
107
107
  f.setProperty(
108
108
  u,
109
109
  i.getPropertyValue(u),
@@ -120,10 +120,10 @@ async function O(o, t, n) {
120
120
  function v(p) {
121
121
  const w = window.getComputedStyle(g, p), e = w.getPropertyValue("content");
122
122
  if (e === "" || e === "none") return;
123
- const i = h.uid();
124
- c.className = c.className + " " + i;
123
+ const i = d.uid();
124
+ a.className = a.className + " " + i;
125
125
  const f = document.createElement("style");
126
- f.appendChild(u(i, p, w)), c.appendChild(f);
126
+ f.appendChild(u(i, p, w)), a.appendChild(f);
127
127
  function u(y, E, S) {
128
128
  const B = "." + y + ":" + E, P = S.cssText ? L(S) : H(S);
129
129
  return document.createTextNode(B + "{" + P + "}");
@@ -132,7 +132,7 @@ async function O(o, t, n) {
132
132
  return A.cssText + " content: " + D + ";";
133
133
  }
134
134
  function H(A) {
135
- return h.asArray(A).map(D).join("; ") + ";";
135
+ return d.asArray(A).map(D).join("; ") + ";";
136
136
  function D(M) {
137
137
  return M + ": " + A.getPropertyValue(M) + (A.getPropertyPriority(M) ? " !important" : "");
138
138
  }
@@ -141,47 +141,47 @@ async function O(o, t, n) {
141
141
  }
142
142
  }
143
143
  function C() {
144
- g instanceof HTMLTextAreaElement && (c.innerHTML = g.value), g instanceof HTMLInputElement && c.setAttribute("value", g.value);
144
+ g instanceof HTMLTextAreaElement && (a.innerHTML = g.value), g instanceof HTMLInputElement && a.setAttribute("value", g.value);
145
145
  }
146
146
  function U() {
147
- c instanceof SVGElement && (c.setAttribute("xmlns", "http://www.w3.org/2000/svg"), c instanceof SVGRectElement && ["width", "height"].forEach(function(v) {
148
- const p = c.getAttribute(v);
149
- p && c.style.setProperty(v, p);
147
+ a instanceof SVGElement && (a.setAttribute("xmlns", "http://www.w3.org/2000/svg"), a instanceof SVGRectElement && ["width", "height"].forEach(function(v) {
148
+ const p = a.getAttribute(v);
149
+ p && a.style.setProperty(v, p);
150
150
  }));
151
151
  }
152
152
  }
153
153
  }
154
154
  async function W(o) {
155
- const t = await F.resolveAll(), n = document.createElement("style");
156
- return o.appendChild(n), n.appendChild(document.createTextNode(t)), o;
155
+ const n = await F.resolveAll(), t = document.createElement("style");
156
+ return o.appendChild(t), t.appendChild(document.createTextNode(n)), o;
157
157
  }
158
158
  function q(o) {
159
159
  return N.inlineAll(o).then(function() {
160
160
  return o;
161
161
  });
162
162
  }
163
- function J(o, t, n) {
164
- return Promise.resolve(o).then(function(a) {
165
- return a.setAttribute("xmlns", "http://www.w3.org/1999/xhtml"), new XMLSerializer().serializeToString(a);
166
- }).then(h.escapeXhtml).then(function(a) {
167
- return '<foreignObject x="0" y="0" width="100%" height="100%">' + a + "</foreignObject>";
168
- }).then(function(a) {
169
- return '<svg xmlns="http://www.w3.org/2000/svg" width="' + t + '" height="' + n + '">' + a + "</svg>";
170
- }).then(function(a) {
171
- return "data:image/svg+xml;charset=utf-8," + a;
163
+ function J(o, n, t) {
164
+ return Promise.resolve(o).then(function(s) {
165
+ return s.setAttribute("xmlns", "http://www.w3.org/1999/xhtml"), new XMLSerializer().serializeToString(s);
166
+ }).then(d.escapeXhtml).then(function(s) {
167
+ return '<foreignObject x="0" y="0" width="100%" height="100%">' + s + "</foreignObject>";
168
+ }).then(function(s) {
169
+ return '<svg xmlns="http://www.w3.org/2000/svg" width="' + n + '" height="' + t + '">' + s + "</svg>";
170
+ }).then(function(s) {
171
+ return "data:image/svg+xml;charset=utf-8," + s;
172
172
  });
173
173
  }
174
174
  function z() {
175
175
  return {
176
176
  escape: T,
177
- parseExtension: t,
178
- mimeType: n,
179
- dataAsUrl: c,
180
- isDataUrl: a,
177
+ parseExtension: n,
178
+ mimeType: t,
179
+ dataAsUrl: a,
180
+ isDataUrl: s,
181
181
  canvasToBlob: r,
182
- resolveUrl: s,
182
+ resolveUrl: c,
183
183
  getAndEncode: g,
184
- uid: d(),
184
+ uid: h(),
185
185
  delay: x,
186
186
  asArray: C,
187
187
  escapeXhtml: U,
@@ -201,18 +201,20 @@ function z() {
201
201
  jpeg: i,
202
202
  gif: "image/gif",
203
203
  tiff: "image/tiff",
204
- svg: "image/svg+xml"
204
+ svg: "image/svg+xml",
205
+ webp: "image/webp",
206
+ avif: "image/avif"
205
207
  };
206
208
  }
207
- function t(e) {
209
+ function n(e) {
208
210
  const i = /\.([^\.\/]*?)$/g.exec(e);
209
211
  return i ? i[1] : "";
210
212
  }
211
- function n(e) {
212
- const i = t(e).toLowerCase();
213
+ function t(e) {
214
+ const i = n(e).toLowerCase();
213
215
  return o()[i] || "";
214
216
  }
215
- function a(e) {
217
+ function s(e) {
216
218
  return e.search(/^(data:)/) !== -1;
217
219
  }
218
220
  function l(e) {
@@ -230,13 +232,13 @@ function z() {
230
232
  e.toBlob(i);
231
233
  }) : l(e);
232
234
  }
233
- function s(e, i) {
235
+ function c(e, i) {
234
236
  const f = document.implementation.createHTMLDocument(), u = f.createElement("base");
235
237
  f.head.appendChild(u);
236
238
  const y = f.createElement("a");
237
239
  return f.body.appendChild(y), u.href = i, y.href = e, y.href;
238
240
  }
239
- function d() {
241
+ function h() {
240
242
  let e = 0;
241
243
  return function() {
242
244
  return "u" + i() + e++;
@@ -282,7 +284,7 @@ function z() {
282
284
  }
283
285
  });
284
286
  }
285
- function c(e, i) {
287
+ function a(e, i) {
286
288
  return "data:" + i + ";base64," + e;
287
289
  }
288
290
  function T(e) {
@@ -322,48 +324,48 @@ function K() {
322
324
  const o = /url\(['"]?([^'"]+?)['"]?\)/g;
323
325
  return {
324
326
  inlineAll: l,
325
- shouldProcess: t,
327
+ shouldProcess: n,
326
328
  impl: {
327
- readUrls: n,
328
- inline: a
329
+ readUrls: t,
330
+ inline: s
329
331
  }
330
332
  };
331
- function t(r) {
333
+ function n(r) {
332
334
  return r.search(o) !== -1;
333
335
  }
334
- function n(r) {
335
- const s = [];
336
- let d;
337
- for (; (d = o.exec(r)) !== null; )
338
- s.push(d[1]);
339
- return s.filter(function(m) {
340
- return !h.isDataUrl(m);
336
+ function t(r) {
337
+ const c = [];
338
+ let h;
339
+ for (; (h = o.exec(r)) !== null; )
340
+ c.push(h[1]);
341
+ return c.filter(function(m) {
342
+ return !d.isDataUrl(m);
341
343
  });
342
344
  }
343
- function a(r, s, d, m) {
344
- return Promise.resolve(s).then(function(c) {
345
- return d ? h.resolveUrl(c, d) : c;
346
- }).then(m || h.getAndEncode).then(function(c) {
347
- return h.dataAsUrl(c, h.mimeType(s));
348
- }).then(function(c) {
349
- return r.replace(g(s), "$1" + c + "$3");
345
+ function s(r, c, h, m) {
346
+ return Promise.resolve(c).then(function(a) {
347
+ return h ? d.resolveUrl(a, h) : a;
348
+ }).then(m || d.getAndEncode).then(function(a) {
349
+ return d.dataAsUrl(a, d.mimeType(c));
350
+ }).then(function(a) {
351
+ return r.replace(g(c), "$1" + a + "$3");
350
352
  });
351
- function g(c) {
352
- return new RegExp(`(url\\(['"]?)(` + h.escape(c) + `)(['"]?\\))`, "g");
353
+ function g(a) {
354
+ return new RegExp(`(url\\(['"]?)(` + d.escape(a) + `)(['"]?\\))`, "g");
353
355
  }
354
356
  }
355
- function l(r, s, d) {
357
+ function l(r, c, h) {
356
358
  if (m()) return Promise.resolve(r);
357
- return Promise.resolve(r).then(n).then(function(g) {
358
- let c = Promise.resolve(r);
359
+ return Promise.resolve(r).then(t).then(function(g) {
360
+ let a = Promise.resolve(r);
359
361
  return g.forEach(function(T) {
360
- c = c.then(function(x) {
361
- return a(x, T, s, d);
362
+ a = a.then(function(x) {
363
+ return s(x, T, c, h);
362
364
  });
363
- }), c;
365
+ }), a;
364
366
  });
365
367
  function m() {
366
- return !t(r);
368
+ return !n(r);
367
369
  }
368
370
  }
369
371
  }
@@ -371,48 +373,48 @@ function Q() {
371
373
  return {
372
374
  resolveAll: o,
373
375
  impl: {
374
- readAll: t
376
+ readAll: n
375
377
  }
376
378
  };
377
379
  function o() {
378
- return t().then(function(n) {
380
+ return n().then(function(t) {
379
381
  return Promise.all(
380
- n.map(function(a) {
381
- return a.resolve();
382
+ t.map(function(s) {
383
+ return s.resolve();
382
384
  })
383
385
  );
384
- }).then(function(n) {
385
- return n.join(`
386
+ }).then(function(t) {
387
+ return t.join(`
386
388
  `);
387
389
  });
388
390
  }
389
- function t() {
390
- return Promise.resolve(h.asArray(document.styleSheets)).then(a).then(n).then(function(r) {
391
+ function n() {
392
+ return Promise.resolve(d.asArray(document.styleSheets)).then(s).then(t).then(function(r) {
391
393
  return r.map(l);
392
394
  });
393
- function n(r) {
394
- return r.filter(function(s) {
395
- return s.type === CSSRule.FONT_FACE_RULE;
396
- }).filter(function(s) {
397
- return R.shouldProcess(s.style.getPropertyValue("src"));
395
+ function t(r) {
396
+ return r.filter(function(c) {
397
+ return c.type === CSSRule.FONT_FACE_RULE;
398
+ }).filter(function(c) {
399
+ return I.shouldProcess(c.style.getPropertyValue("src"));
398
400
  });
399
401
  }
400
- function a(r) {
401
- const s = [];
402
- return r.forEach(function(d) {
403
- if (Object.prototype.hasOwnProperty.call(d, "cssRules"))
402
+ function s(r) {
403
+ const c = [];
404
+ return r.forEach(function(h) {
405
+ if (Object.prototype.hasOwnProperty.call(h, "cssRules"))
404
406
  try {
405
- h.asArray(d.cssRules || []).forEach(s.push.bind(s));
407
+ d.asArray(h.cssRules || []).forEach(c.push.bind(c));
406
408
  } catch (m) {
407
- console.log("Error while reading CSS rules from " + d.href, m.toString());
409
+ console.log("Error while reading CSS rules from " + h.href, m.toString());
408
410
  }
409
- }), s;
411
+ }), c;
410
412
  }
411
413
  function l(r) {
412
414
  return {
413
415
  resolve: function() {
414
- const d = (r.parentStyleSheet || {}).href;
415
- return R.inlineAll(r.cssText, d);
416
+ const h = (r.parentStyleSheet || {}).href;
417
+ return I.inlineAll(r.cssText, h);
416
418
  },
417
419
  src: function() {
418
420
  return r.style.getPropertyValue("src");
@@ -423,40 +425,53 @@ function Q() {
423
425
  }
424
426
  function Y() {
425
427
  return {
426
- inlineAll: t,
428
+ inlineAll: n,
427
429
  impl: {
428
430
  newImage: o
429
431
  }
430
432
  };
431
- function o(n) {
433
+ function o(t) {
432
434
  return {
433
- inline: a
435
+ inline: s
434
436
  };
435
- function a(l) {
436
- return h.isDataUrl(n.src) ? Promise.resolve() : Promise.resolve(n.src).then(l || h.getAndEncode).then(function(r) {
437
- return h.dataAsUrl(r, h.mimeType(n.src));
437
+ function s(l) {
438
+ return d.isDataUrl(t.src) ? Promise.resolve() : Promise.resolve(t.src).then(l || d.getAndEncode).then(function(r) {
439
+ return d.dataAsUrl(r, d.mimeType(t.src));
438
440
  }).then(function(r) {
439
- return new Promise(function(s, d) {
440
- n.onload = s, n.onerror = d, n.src = r, n.srcset = "";
441
+ return new Promise(function(c) {
442
+ t.onload = function() {
443
+ c();
444
+ }, t.onerror = function() {
445
+ const h = b.impl.options.imagePlaceholder;
446
+ if (h)
447
+ try {
448
+ t.onload = null, t.onerror = null, t.src = h, t.srcset = "";
449
+ } catch (m) {
450
+ console.error("Image placeholder assignment failed:", m);
451
+ }
452
+ else
453
+ console.warn("Image inline failed, continuing without placeholder:", t.src);
454
+ c();
455
+ }, t.src = r, t.srcset = "";
441
456
  });
442
457
  });
443
458
  }
444
459
  }
445
- function t(n) {
446
- if (!(n instanceof Element)) return Promise.resolve(n);
447
- return a(n).then(function() {
448
- return n instanceof HTMLImageElement ? o(n).inline() : Promise.all(
449
- h.asArray(n.childNodes).map(function(l) {
450
- return t(l);
460
+ function n(t) {
461
+ if (!(t instanceof Element)) return Promise.resolve(t);
462
+ return s(t).then(function() {
463
+ return t instanceof HTMLImageElement ? o(t).inline() : Promise.all(
464
+ d.asArray(t.childNodes).map(function(l) {
465
+ return n(l);
451
466
  })
452
467
  );
453
468
  });
454
- function a(l) {
469
+ function s(l) {
455
470
  const r = l.style.getPropertyValue("background");
456
- return r ? R.inlineAll(r).then(function(s) {
471
+ return r ? I.inlineAll(r).then(function(c) {
457
472
  l.style.setProperty(
458
473
  "background",
459
- s,
474
+ c,
460
475
  l.style.getPropertyPriority("background")
461
476
  );
462
477
  }).then(function() {