html2canvas-pro 2.2.2 → 2.2.3

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.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * html2canvas-pro 2.2.2 <https://yorickshan.github.io/html2canvas-pro/>
2
+ * html2canvas-pro 2.2.3 <https://yorickshan.github.io/html2canvas-pro/>
3
3
  * Copyright (c) 2024-present yorickshan and html2canvas-pro contributors
4
4
  * Released under MIT License
5
5
  */
@@ -3903,6 +3903,7 @@
3903
3903
  initialValue: "none",
3904
3904
  type: 1,
3905
3905
  prefix: false,
3906
+ skipCache: true,
3906
3907
  parse: (context, tokens) => {
3907
3908
  if (tokens.length === 0) return [];
3908
3909
  const first = tokens[0];
@@ -4345,6 +4346,7 @@
4345
4346
  initialValue: "none",
4346
4347
  type: 0,
4347
4348
  prefix: false,
4349
+ skipCache: true,
4348
4350
  parse: (context, token) => {
4349
4351
  if (token.type === 20 && token.value === "none") return null;
4350
4352
  return image.parse(context, token);
@@ -5365,6 +5367,7 @@
5365
5367
  initialValue: "none",
5366
5368
  prefix: false,
5367
5369
  type: 1,
5370
+ skipCache: true,
5368
5371
  parse: (context, tokens) => {
5369
5372
  if (tokens.length === 0) return null;
5370
5373
  const filtered = tokens.filter((t) => nonFunctionArgSeparator(t) && isSupportedImage(t));
@@ -6301,7 +6304,7 @@
6301
6304
  valueCache = /* @__PURE__ */ new Map();
6302
6305
  parseCache.set(descriptor, valueCache);
6303
6306
  }
6304
- if (!(descriptor.type === 3 && descriptor.format === "image")) {
6307
+ if (!(descriptor.skipCache || descriptor.type === 3 && descriptor.format === "image")) {
6305
6308
  if (valueCache.size >= 200) {
6306
6309
  const oldestKey = valueCache.keys().next().value;
6307
6310
  valueCache.delete(oldestKey);