@getmicdrop/venue-calendar 4.3.38 → 4.3.39

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 (102) hide show
  1. package/dist/{ArrowLeftIcon-bH5d6LQO.js → ArrowLeftIcon-BMuyNOqe.js} +1 -1
  2. package/dist/{BlockPlaceholder-yXhu9HrQ.js → BlockPlaceholder-CUusOhOf.js} +1 -1
  3. package/dist/{Calendar-BjE02HrG.js → Calendar-Dy-jZDff.js} +3 -3
  4. package/dist/{CalendarFoundryView-BWaOYwqK.js → CalendarFoundryView-BWyEe7Xe.js} +23 -23
  5. package/dist/{CalendarIcon-Cg9UUTeu.js → CalendarIcon-B1JasL-W.js} +1 -1
  6. package/dist/{CartView-YRimdA6F.js → CartView-CyU9g9ss.js} +14 -14
  7. package/dist/{Checkbox-24CWEsty.js → Checkbox-BtJwg_CF.js} +1 -0
  8. package/dist/{Checkout-rsX9zvb7.js → Checkout-BGXlW2j2.js} +14 -20
  9. package/dist/{Checkout-djS62Y9-.js → Checkout-DrP1KLR_.js} +15 -15
  10. package/dist/{CheckoutTimer-D3XNCZ36.js → CheckoutTimer-CAKT63di.js} +3 -3
  11. package/dist/{ChevronDownIcon-BA40Kl0C.js → ChevronDownIcon--mG1fNDx.js} +1 -1
  12. package/dist/{ClockIcon-DjC-doTv.js → ClockIcon-B8ahXV8G.js} +1 -1
  13. package/dist/{CloseIcon-BdwmaxDK.js → CloseIcon-C9guTa4C.js} +1 -1
  14. package/dist/{CollectionView-DJMd-lQ5.js → CollectionView-BhBCM-01.js} +6 -6
  15. package/dist/{CropImage-Ct6MRg_a.js → CropImage-BFtvLjTE.js} +1 -1
  16. package/dist/{Event-ETzQP0s-.js → Event-DyX1UrZe.js} +18 -18
  17. package/dist/{EventPage-BDmpGhgp.js → EventPage-DxyEqU7R.js} +14 -14
  18. package/dist/{Input-o-1w57H2.js → Input-DNzDcf6I.js} +1 -1
  19. package/dist/{MailIcon-DCMMhuHr.js → MailIcon-Cf77TYiB.js} +1 -1
  20. package/dist/{PasswordInput-zX7J--jb.js → PasswordInput-C-BH1Do3.js} +1 -1
  21. package/dist/{RecommendationsRail-CKoChbYt.js → RecommendationsRail-CG0vCtgJ.js} +7 -7
  22. package/dist/{ScarcityBadge-CwYWJOsJ.js → ScarcityBadge-D0D6Hqp0.js} +3 -3
  23. package/dist/{SeriesPage-DccLByjM.js → SeriesPage-D9_Nn8gF.js} +3 -3
  24. package/dist/{Success-BVYGRvb8.js → Success-Db843hJe.js} +17 -17
  25. package/dist/{TagIcon-CkfQvNGi.js → TagIcon-DUY8KSZ0.js} +1 -1
  26. package/dist/{ViewTicketsEmbed-D6ZLDsJe.js → ViewTicketsEmbed-rdcE9aPB.js} +5 -5
  27. package/dist/{WarningCircleIcon-Iq24pJJf.js → WarningCircleIcon-C1-Aj9ut.js} +1 -1
  28. package/dist/{WarningTriIcon-Dw5GnHpq.js → WarningTriIcon-BrwQ58VB.js} +1 -1
  29. package/dist/api/api.cjs +1 -1
  30. package/dist/api/api.mjs +1 -1
  31. package/dist/api/authHeaders.d.ts +25 -0
  32. package/dist/api/checkout-availability.d.ts +71 -0
  33. package/dist/api/gate-password-cache.d.ts +60 -0
  34. package/dist/api/recommendations.d.ts +35 -0
  35. package/dist/api/surge-queue.d.ts +133 -0
  36. package/dist/api/types.d.ts +435 -556
  37. package/dist/{api-LOBSDFGW.js → api-DDVVRbC-.js} +3 -3
  38. package/dist/{constants-COyf9Cef.js → constants-7hsFMWgp.js} +1 -1
  39. package/dist/{copyToClipboard-C3IBl2Z1.js → copyToClipboard-4LAkJ_1y.js} +1 -1
  40. package/dist/{de-BY5vJUGN.js → de-DD9e2eok.js} +21 -3
  41. package/dist/{defaultLabels-Zp9QbN37.js → defaultLabels-BkjXKQDd.js} +20 -2
  42. package/dist/{defaults-BS-A8oEj.js → defaults-DthmKRyG.js} +2 -2
  43. package/dist/{es-jUq9nrJk.js → es-CHuPO3ex.js} +21 -3
  44. package/dist/{event-c9mHeEJz.js → event-Dew6DCL7.js} +1 -1
  45. package/dist/{event-transform-BR82y7EY.js → event-transform-CbFR1hRl.js} +4 -4
  46. package/dist/{eventStatusStream-1YtkEBw8.js → eventStatusStream-DTshTZoI.js} +1 -1
  47. package/dist/{fr-BhVwmvlV.js → fr-Ctu5i20f.js} +21 -3
  48. package/dist/{href-1o0O9xTA.js → href-B4azVXj-.js} +2 -2
  49. package/dist/i18n--YZExMpe.js +28 -0
  50. package/dist/{i18n-02Y9QRm0.js → i18n-srcm-H61.js} +6 -6
  51. package/dist/{id-CWU5ZvLv.js → id-DKYW7qEJ.js} +21 -3
  52. package/dist/imageOptimizer-Cf0BbZJ7.js +220 -0
  53. package/dist/{it-wlDmN3hH.js → it-DPWCuCsJ.js} +21 -3
  54. package/dist/{ja-DpA7hJaC.js → ja-CNSRW1XM.js} +21 -3
  55. package/dist/{ko-DdWLaFvo.js → ko--itQbcHD.js} +21 -3
  56. package/dist/locales/{4.3.38 → 4.3.39}/main/de.js +1 -1
  57. package/dist/locales/{4.3.38 → 4.3.39}/main/es.js +1 -1
  58. package/dist/locales/{4.3.38 → 4.3.39}/main/fr.js +1 -1
  59. package/dist/locales/{4.3.38 → 4.3.39}/main/id.js +1 -1
  60. package/dist/locales/{4.3.38 → 4.3.39}/main/it.js +1 -1
  61. package/dist/locales/{4.3.38 → 4.3.39}/main/ja.js +1 -1
  62. package/dist/locales/{4.3.38 → 4.3.39}/main/ko.js +1 -1
  63. package/dist/locales/{4.3.38 → 4.3.39}/main/nl.js +1 -1
  64. package/dist/locales/{4.3.38 → 4.3.39}/main/pl.js +1 -1
  65. package/dist/locales/{4.3.38 → 4.3.39}/main/pt-br.js +1 -1
  66. package/dist/locales/{4.3.38 → 4.3.39}/main/tr.js +1 -1
  67. package/dist/locales/{4.3.38 → 4.3.39}/main/zh.js +1 -1
  68. package/dist/{nl-BwxAfMRa.js → nl-BoZA1-rw.js} +21 -3
  69. package/dist/{order-totals-BEUOdkCb.js → order-totals-DFE6UVG4.js} +3 -3
  70. package/dist/{orders-_DuPjm-g.js → orders-DABdaHOy.js} +1 -1
  71. package/dist/{phoneUtils-CbiDWdEC.js → phoneUtils-CxLRaM5n.js} +1 -1
  72. package/dist/{pixels-BXobnFyk.js → pixels-BVOE_JFH.js} +2 -2
  73. package/dist/{pl-CuRdwJXc.js → pl-tC8ayoR2.js} +21 -3
  74. package/dist/{promo-BrstveEs.js → promo-B3Tj0iQF.js} +1 -1
  75. package/dist/{pt-br-BUWJLxKf.js → pt-br-CTMA1wMi.js} +21 -3
  76. package/dist/{scarcity-CwnIxi1J.js → scarcity-DqbDh1cS.js} +1 -1
  77. package/dist/seo/types.d.ts +137 -156
  78. package/dist/{serverTotals-D2-FzkdS.js → serverTotals-ClEUVCOz.js} +1 -1
  79. package/dist/{showcase-state-options-CDOHpho6.js → showcase-state-options-Dwn2NLOM.js} +1 -1
  80. package/dist/{to-event-card-props-ChcFQ_rl.js → to-event-card-props-CRaeqRxY.js} +2 -2
  81. package/dist/{tr-DTe5Urub.js → tr-CuaYXuAQ.js} +21 -3
  82. package/dist/{utils-DlMAhsnl.js → utils-kRsfuFcG.js} +2 -2
  83. package/dist/venue-calendar.css +1 -1
  84. package/dist/venue-calendar.es.js +471 -462
  85. package/dist/venue-calendar.iife.js +56 -56
  86. package/dist/venue-calendar.umd.js +56 -56
  87. package/dist/{zh-BnBN3ggx.js → zh-Bcr7RKpt.js} +21 -3
  88. package/package.json +2 -2
  89. package/dist/i18n-Dwg2jCJS.js +0 -28
  90. package/dist/imageOptimizer-DkJp4tei.js +0 -140
  91. /package/dist/locales/{4.3.38 → 4.3.39}/flow/de.js +0 -0
  92. /package/dist/locales/{4.3.38 → 4.3.39}/flow/es.js +0 -0
  93. /package/dist/locales/{4.3.38 → 4.3.39}/flow/fr.js +0 -0
  94. /package/dist/locales/{4.3.38 → 4.3.39}/flow/id.js +0 -0
  95. /package/dist/locales/{4.3.38 → 4.3.39}/flow/it.js +0 -0
  96. /package/dist/locales/{4.3.38 → 4.3.39}/flow/ja.js +0 -0
  97. /package/dist/locales/{4.3.38 → 4.3.39}/flow/ko.js +0 -0
  98. /package/dist/locales/{4.3.38 → 4.3.39}/flow/nl.js +0 -0
  99. /package/dist/locales/{4.3.38 → 4.3.39}/flow/pl.js +0 -0
  100. /package/dist/locales/{4.3.38 → 4.3.39}/flow/pt-br.js +0 -0
  101. /package/dist/locales/{4.3.38 → 4.3.39}/flow/tr.js +0 -0
  102. /package/dist/locales/{4.3.38 → 4.3.39}/flow/zh.js +0 -0
@@ -337,8 +337,6 @@ var e = {
337
337
  cardDeclinedSuggestion: "请尝试其他银行卡,或联系发卡行了解详情",
338
338
  cardDoNotHonorMessage: "您的发卡行拒绝了这张卡",
339
339
  cardDoNotHonorSuggestion: "请尝试其他银行卡,或致电您的发卡行",
340
- cardFraudMessage: "您的发卡行标记了这笔付款",
341
- cardFraudSuggestion: "请尝试其他银行卡",
342
340
  paymentConnectionErrorMessage: "无法连接到支付服务器",
343
341
  paymentConnectionErrorSuggestion: "请检查网络连接后重试",
344
342
  tooManyAttemptsTitle: "尝试次数过多",
@@ -520,7 +518,27 @@ var e = {
520
518
  opensInGoogleMaps: "(在 Google 地图中打开)",
521
519
  purchaseGiftCard: "购买礼品卡",
522
520
  giftDetails: "赠礼详情",
523
- continueToPayment: "前往支付"
521
+ continueToPayment: "前往支付",
522
+ giftCardForVenue: "适用于 {venue}",
523
+ giftCardYourInformation: "您的信息",
524
+ giftCardYourName: "您的姓名",
525
+ giftCardYourNamePlaceholder: "请输入您的姓名",
526
+ giftCardYourNameRequired: "请输入您的姓名",
527
+ giftCardYourEmail: "您的邮箱",
528
+ giftCardYourEmailPlaceholder: "请输入您的邮箱",
529
+ giftCardYourEmailRequired: "请输入您的邮箱",
530
+ giftCardConfirmationEmailHelp: "确认信息将发送至此邮箱",
531
+ giftCardCreatePurchaseFailed: "创建订单失败,请重试",
532
+ giftCardOrderSummary: "订单摘要",
533
+ giftCardAmount: "礼品卡金额",
534
+ giftCardRecipient: "收件人",
535
+ giftCardDelivery: "发送方式",
536
+ giftCardDeliveryScheduled: "定时发送",
537
+ giftCardDeliveryImmediate: "立即发送",
538
+ giftCardPaymentDetails: "支付详情",
539
+ giftCardBack: "返回",
540
+ giftCardPayAmount: "支付 {amount}",
541
+ giftCardPaymentFailed: "支付失败,请重试"
524
542
  };
525
543
  //#endregion
526
544
  export { e as zh };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@getmicdrop/venue-calendar",
3
3
  "_version_comment": "4.1.55 was the last PUBLISHED version, and the tree carried 36 commits npm's 4.1.55 does not have — including the gate-password security fix and four money fixes. A filename must never reuse a version npm has taken (jsDelivr/unpkg cache the FIRST bytes they see under `@4.1.55` forever, so republishing that number ships the old widget to every venue that pinned it). Bumped to 4.2.0 here, BEFORE anything is built for publish. `npm run release:preflight` refuses to proceed when this number already exists in the registry.",
4
- "version": "4.3.38",
4
+ "version": "4.3.39",
5
5
  "description": "A customizable Svelte calendar component for displaying comedy events",
6
6
  "type": "module",
7
7
  "types": "./dist/types/index.d.ts",
@@ -154,7 +154,7 @@
154
154
  "_devDependencies_pin_comment": "Three EXACT pins in here are load-bearing and must not be re-caretted by a dependency bot. (1) `@getmicdrop/svelte-components` — the ES/UMD/IIFE builds do NOT externalize SC, so it is COMPILED INTO every shipped artifact. RESTORED TO AN EXACT PIN 2026-08-23, having drifted back to a caret at some point between 6.24.311 and 6.24.316 — exactly the re-caretting this note warns about, which is worth knowing recurs. Under a caretted range like `^6.24.311` the SC version a venue's browser executes is whatever the range floats to on the publish machine at publish time, which is not recorded anywhere and is not reproducible after the fact; the `overrides` block below cannot help (it only ever covered esbuild, and consumers ignore a dependency's overrides entirely). Pinned exact so the artifact and the manifest agree, and vite.config.lib.js stamps the resolved version into the bundle as __VC_SC_VERSION__ so a venue's devtools can answer 'which SC is this?'. (2) `svelte` — the compiler whose private internal/client calls the pre-compiled dist binds to. `^5.56.9` let the compiler move under a peer range that stayed still; see _peerDependencies_comment. (3) `@stripe/stripe-js` in dependencies — see its own note there.",
155
155
  "devDependencies": {
156
156
  "@eslint/js": "^10.0.1",
157
- "@getmicdrop/svelte-components": "6.24.364",
157
+ "@getmicdrop/svelte-components": "6.24.365",
158
158
  "@playwright/test": "^1.60.0",
159
159
  "@size-limit/file": "^13.0.3",
160
160
  "@sveltejs/adapter-auto": "^7.0.1",
@@ -1,28 +0,0 @@
1
- import { t as e } from "./defaultLabels-Zp9QbN37.js";
2
- import { l as t } from "./orders-_DuPjm-g.js";
3
- //#endregion
4
- //#region src/lib/i18n/index.js
5
- var n = t({
6
- defaults: e,
7
- locales: { en: e },
8
- loaders: {
9
- es: () => import("./es-jUq9nrJk.js").then((e) => e.es),
10
- fr: () => import("./fr-BhVwmvlV.js").then((e) => e.fr),
11
- "pt-br": () => import("./pt-br-BUWJLxKf.js").then((e) => e.pt_br),
12
- pt: () => import("./pt-br-BUWJLxKf.js").then((e) => e.pt_br),
13
- de: () => import("./de-BY5vJUGN.js").then((e) => e.de),
14
- ja: () => import("./ja-DpA7hJaC.js").then((e) => e.ja),
15
- zh: () => import("./zh-BnBN3ggx.js").then((e) => e.zh),
16
- ko: () => import("./ko-DdWLaFvo.js").then((e) => e.ko),
17
- it: () => import("./it-wlDmN3hH.js").then((e) => e.it),
18
- nl: () => import("./nl-BwxAfMRa.js").then((e) => e.nl),
19
- tr: () => import("./tr-DTe5Urub.js").then((e) => e.tr),
20
- id: () => import("./id-CWU5ZvLv.js").then((e) => e.id),
21
- pl: () => import("./pl-CuRdwJXc.js").then((e) => e.pl)
22
- }
23
- });
24
- n.resolveLocale;
25
- var r = n.getLabelsForLocale, i = n.loadLocale;
26
- n.listLocales;
27
- //#endregion
28
- export { i as n, r as t };
@@ -1,140 +0,0 @@
1
- import { A as e, C as t, o as n } from "./Button-klwKgfhG.js";
2
- import { c as r, n as i, r as a, t as o, u as s } from "./z-index-Bo0dqmiq.js";
3
- import { c, h as l, l as u, m as d, o as f, s as p } from "./ModalFooter-T1gpnywp.js";
4
- import "svelte/internal/disclose-version";
5
- import * as m from "svelte/internal/client";
6
- //#region node_modules/@getmicdrop/svelte-components/dist/primitives/Icons/PlusOutline.svelte
7
- var h = m.from_svg("<svg aria-hidden=\"true\" fill=\"none\" stroke-width=\"2\" viewBox=\"0 0 24 24\" xmlns=\"http://www.w3.org/2000/svg\"><path stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M12 4.5v15m7.5-7.5h-15\"></path></svg>");
8
- function g(e, t) {
9
- let n = m.prop(t, "size", 3, "24"), r = m.prop(t, "color", 3, "currentColor"), i = m.prop(t, "class", 3, "");
10
- var a = h();
11
- m.template_effect(() => {
12
- m.set_class(a, 0, m.clsx(i())), m.set_attribute(a, "width", n()), m.set_attribute(a, "height", n()), m.set_attribute(a, "stroke", r());
13
- }), m.append(e, a);
14
- }
15
- //#endregion
16
- //#region node_modules/@getmicdrop/svelte-components/dist/primitives/BottomSheet/BottomSheet.svelte
17
- var _ = m.from_html("<div class=\"px-6 pb-4 border-b border-border shrink-0\"><h3> </h3></div>"), v = m.from_html("<div class=\"px-6 py-4 border-t border-border shrink-0 flex flex-col gap-3\"><!></div>"), y = m.from_html("<div role=\"presentation\"><div role=\"dialog\" aria-modal=\"true\" data-escape-layer=\"\" tabindex=\"-1\"><!> <!> <div class=\"flex-1 overflow-y-auto overscroll-contain p-4 px-6\"><!></div> <!></div></div>");
18
- function b(e, f) {
19
- m.push(f, !0);
20
- let p = m.prop(f, "open", 11, !1), h = m.prop(f, "title", 3, ""), g = m.prop(f, "alwaysSheet", 3, !1), b = `bottom-sheet-title-${Math.random().toString(36).slice(2, 9)}`, x = m.state(!1), S = m.state(null);
21
- m.user_effect(() => {
22
- p() && !m.get(x) && typeof document < "u" && m.set(S, document.activeElement, !0), m.set(x, p());
23
- });
24
- let C = m.state(void 0);
25
- function w() {
26
- f.onclose?.();
27
- }
28
- function T(e) {
29
- e.target === e.currentTarget && w();
30
- }
31
- function E(e) {
32
- p() && n(e, m.get(C)) && (e.preventDefault(), w());
33
- }
34
- m.user_effect(() => {
35
- if (p()) return d();
36
- });
37
- let D = m.derived(() => g() ? "fixed inset-0 flex items-end bg-bg-primary/50" : "fixed inset-0 flex items-end md:items-center md:justify-center bg-bg-primary/50"), O = m.derived(() => g() ? "w-full max-h-[90dvh] bg-card rounded-t-xl shadow-xl flex flex-col overflow-hidden" : "w-full max-h-[90dvh] md:max-w-lg md:max-h-[80vh] md:m-4 bg-card rounded-t-xl md:rounded-lg shadow-xl flex flex-col overflow-hidden");
38
- var k = m.comment();
39
- m.event("keydown", m.window, E);
40
- var A = m.first_child(k), j = (e) => {
41
- var n = y();
42
- let d;
43
- var x = m.child(n), w = m.child(x);
44
- {
45
- let e = m.derived(() => g() ? "" : "md:hidden");
46
- c(w, { get class() {
47
- return m.get(e);
48
- } });
49
- }
50
- var E = m.sibling(w, 2), k = (e) => {
51
- var n = _(), r = m.child(n), i = m.child(r, !0);
52
- m.reset(r), m.reset(n), m.template_effect(() => {
53
- m.set_attribute(r, "id", b), m.set_class(r, 1, m.clsx(t.h3)), m.set_text(i, h());
54
- }), m.append(e, n);
55
- };
56
- m.if(E, (e) => {
57
- h() && e(k);
58
- });
59
- var A = m.sibling(E, 2), j = m.child(A);
60
- m.snippet(j, () => f.children ?? m.noop), m.reset(A);
61
- var M = m.sibling(A, 2), N = (e) => {
62
- var t = v(), n = m.child(t);
63
- m.snippet(n, () => f.actions ?? m.noop), m.reset(t), m.append(e, t);
64
- };
65
- m.if(M, (e) => {
66
- f.actions && e(N);
67
- }), m.reset(x), m.bind_this(x, (e) => m.set(C, e), () => m.get(C)), m.action(x, (e, t) => l?.(e, t), () => ({
68
- enabled: p(),
69
- returnFocusTo: m.get(S)
70
- })), m.reset(n), m.action(n, (e) => u?.(e)), m.template_effect(() => {
71
- m.set_class(n, 1, m.clsx(m.get(D))), d = m.set_style(n, "", d, { "z-index": o.modal }), m.set_class(x, 1, m.clsx(m.get(O))), m.set_attribute(x, "aria-labelledby", f["aria-labelledby"] ?? (h() ? b : void 0)), m.set_attribute(x, "data-testid", f["data-testid"]);
72
- }), m.delegated("click", n, T), m.delegated("click", x, (e) => e.stopPropagation()), m.transition(3, x, () => s, () => ({
73
- y: 300,
74
- duration: i.normal,
75
- easing: a.out
76
- })), m.transition(3, n, () => r, () => ({ duration: i.fast })), m.append(e, n);
77
- };
78
- m.if(A, (e) => {
79
- p() && e(j);
80
- }), m.append(e, k), m.pop();
81
- }
82
- m.delegate(["click"]);
83
- //#endregion
84
- //#region node_modules/@getmicdrop/svelte-components/dist/primitives/Modal/ModalTitle.svelte
85
- var x = m.from_html("<h2><!></h2>");
86
- function S(t, n) {
87
- m.push(n, !0);
88
- let r = f(), i = r.nextTitleId(), a = p() ?? "always";
89
- m.user_effect(() => (r.registerTitle({
90
- id: i,
91
- visibility: a
92
- }), () => {
93
- r.unregisterTitle(i);
94
- }));
95
- var o = x(), s = m.child(o), c = (e) => {
96
- var t = m.comment(), r = m.first_child(t);
97
- m.snippet(r, () => n.children), m.append(e, t);
98
- };
99
- m.if(s, (e) => {
100
- n.children && e(c);
101
- }), m.reset(o), m.template_effect((e) => {
102
- m.set_attribute(o, "id", i), m.set_class(o, 1, e);
103
- }, [() => m.clsx(e(n.class))]), m.append(t, o), m.pop();
104
- }
105
- //#endregion
106
- //#region node_modules/@getmicdrop/svelte-components/dist/utils/imageOptimizer.js
107
- function C(e) {
108
- return new Promise((t, n) => {
109
- let r = new Image();
110
- r.addEventListener("load", () => t(r)), r.addEventListener("error", (e) => n(e)), e.startsWith("blob:") || r.setAttribute("crossOrigin", "anonymous"), r.src = e;
111
- });
112
- }
113
- function w() {
114
- let e = document.createElement("canvas");
115
- return e.width = 1, e.height = 1, e.toDataURL("image/webp").indexOf("data:image/webp") === 0;
116
- }
117
- async function T(e, t = {}) {
118
- let { maxSize: n = 1e3, quality: r, forceSquare: i = !1 } = t, a = URL.createObjectURL(e);
119
- try {
120
- let t = await C(a), o = document.createElement("canvas"), s = o.getContext("2d"), c, l, u = 0, d = 0, f = t.width, p = t.height;
121
- if (i) {
122
- let e = Math.min(t.width, t.height);
123
- u = (t.width - e) / 2, d = (t.height - e) / 2, f = e, p = e, c = n, l = n;
124
- } else {
125
- let e = t.width / t.height;
126
- t.width > t.height ? (c = Math.min(t.width, n), l = Math.round(c / e)) : (l = Math.min(t.height, n), c = Math.round(l * e)), t.width <= n && t.height <= n && (c = t.width, l = t.height);
127
- }
128
- o.width = c, o.height = l, s.imageSmoothingEnabled = !0, s.imageSmoothingQuality = "high", s.drawImage(t, u, d, f, p, 0, 0, c, l);
129
- let m = w(), h = m ? "image/webp" : "image/jpeg", g = r ?? (m ? .8 : .85), _ = m ? "webp" : "jpg", v = `${e.name.replace(/\.[^.]+$/, "")}.${_}`;
130
- return new Promise((e) => {
131
- o.toBlob((t) => {
132
- e(new File([t], v, { type: h }));
133
- }, h, g);
134
- });
135
- } finally {
136
- URL.revokeObjectURL(a);
137
- }
138
- }
139
- //#endregion
140
- export { b as a, S as i, T as n, g as o, w as r, C as t };
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes