@sonordev/site-kit 2.7.1 → 2.7.2
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/dist/{chunk-2OGUBINV.js → chunk-5OX347TD.js} +24 -4
- package/dist/chunk-5OX347TD.js.map +1 -0
- package/dist/{chunk-MCIELZWP.mjs → chunk-XCQ7BEZG.mjs} +24 -4
- package/dist/chunk-XCQ7BEZG.mjs.map +1 -0
- package/dist/commerce/index.js +46 -46
- package/dist/commerce/index.mjs +1 -1
- package/dist/index.js +26 -26
- package/dist/index.mjs +1 -1
- package/package.json +1 -1
- package/dist/chunk-2OGUBINV.js.map +0 -1
- package/dist/chunk-MCIELZWP.mjs.map +0 -1
|
@@ -5021,8 +5021,28 @@ function loadSquareSDK2(environment) {
|
|
|
5021
5021
|
}
|
|
5022
5022
|
function resolveCssVar(name, fallback) {
|
|
5023
5023
|
if (typeof window === "undefined") return fallback;
|
|
5024
|
-
const
|
|
5025
|
-
|
|
5024
|
+
const raw = getComputedStyle(document.documentElement).getPropertyValue(name).trim();
|
|
5025
|
+
if (!raw) return fallback;
|
|
5026
|
+
return normalizeColorForSquare(raw) ?? fallback;
|
|
5027
|
+
}
|
|
5028
|
+
function normalizeColorForSquare(value) {
|
|
5029
|
+
const v = value.trim();
|
|
5030
|
+
if (!v) return null;
|
|
5031
|
+
if (/^#[0-9a-f]{6}$/i.test(v)) return v;
|
|
5032
|
+
const eightDigit = /^(#[0-9a-f]{6})[0-9a-f]{2}$/i.exec(v);
|
|
5033
|
+
if (eightDigit) return eightDigit[1];
|
|
5034
|
+
const threeDigit = /^#([0-9a-f])([0-9a-f])([0-9a-f])$/i.exec(v);
|
|
5035
|
+
if (threeDigit) {
|
|
5036
|
+
const [, r, g, b] = threeDigit;
|
|
5037
|
+
return `#${r}${r}${g}${g}${b}${b}`;
|
|
5038
|
+
}
|
|
5039
|
+
const rgb = /^rgba?\(\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)/i.exec(v);
|
|
5040
|
+
if (rgb) {
|
|
5041
|
+
const [, r, g, b] = rgb;
|
|
5042
|
+
const toHex = (n) => Number(n).toString(16).padStart(2, "0");
|
|
5043
|
+
return `#${toHex(r)}${toHex(g)}${toHex(b)}`;
|
|
5044
|
+
}
|
|
5045
|
+
return null;
|
|
5026
5046
|
}
|
|
5027
5047
|
var SINGLE_TICKET_KEY = "__single__";
|
|
5028
5048
|
function EventCheckout({
|
|
@@ -7739,5 +7759,5 @@ function groupEventsByOffering(events) {
|
|
|
7739
7759
|
}
|
|
7740
7760
|
|
|
7741
7761
|
export { CalendarView, CheckoutForm, EventCalendar, EventCheckout, EventEmbed, EventModal, EventTile, EventsWidget, OfferingCard, OfferingList, ProductDetail, ProductEmbed, ProductGrid, ProductPage, RegistrationForm, SizeChart, UpcomingEvents, createCheckoutSession, createPaymentIntent, fetchActiveProcessor, fetchCategories, fetchLatestOffering, fetchNextEvent, fetchOffering, fetchOfferings, fetchProcessorConfig, fetchProductBySlug, fetchProducts, fetchProductsPublic, fetchServices, fetchShippingRates, fetchUpcomingEvents, formatDate, formatDateRange, formatDateTime, formatPrice, formatTime, getOfferingUrl, getRelativeTimeUntil, getSpotsRemaining, isEventSoldOut, registerForEvent, useEventModal, validateAddress, validateDiscountCode };
|
|
7742
|
-
//# sourceMappingURL=chunk-
|
|
7743
|
-
//# sourceMappingURL=chunk-
|
|
7762
|
+
//# sourceMappingURL=chunk-XCQ7BEZG.mjs.map
|
|
7763
|
+
//# sourceMappingURL=chunk-XCQ7BEZG.mjs.map
|