@gomusdev/web-components 1.49.0 → 1.50.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.
|
@@ -11125,7 +11125,7 @@ function createQuotaManager(quotas) {
|
|
|
11125
11125
|
{}
|
|
11126
11126
|
)
|
|
11127
11127
|
);
|
|
11128
|
-
return filtered;
|
|
11128
|
+
return filtered.sort((a2, b) => a2.timeSlot.localeCompare(b.timeSlot));
|
|
11129
11129
|
}
|
|
11130
11130
|
};
|
|
11131
11131
|
return ret;
|
|
@@ -16163,7 +16163,7 @@ function createField(data, required) {
|
|
|
16163
16163
|
options: data.options,
|
|
16164
16164
|
autocomplete: data.autocomplete ?? "",
|
|
16165
16165
|
placeholder: data.placeholder ?? "",
|
|
16166
|
-
description: data.description
|
|
16166
|
+
description: data.description,
|
|
16167
16167
|
apiErrors: data.apiErrors ?? [],
|
|
16168
16168
|
mounted: data.mounted ?? false,
|
|
16169
16169
|
required,
|
|
@@ -16545,7 +16545,7 @@ function wrapInElement(host, tag, props) {
|
|
|
16545
16545
|
host.replaceChildren(element);
|
|
16546
16546
|
return element;
|
|
16547
16547
|
}
|
|
16548
|
-
var root_1$
|
|
16548
|
+
var root_1$l = /* @__PURE__ */ from_html(`<go-all-fields></go-all-fields> <go-form-feedback><go-errors-feedback></go-errors-feedback> <go-success-feedback></go-success-feedback></go-form-feedback> <go-submit> </go-submit>`, 3);
|
|
16549
16549
|
function Form($$anchor, $$props) {
|
|
16550
16550
|
push($$props, true);
|
|
16551
16551
|
let formId = prop($$props, "formId", 7), custom2 = prop($$props, "custom", 7);
|
|
@@ -16588,7 +16588,7 @@ function Form($$anchor, $$props) {
|
|
|
16588
16588
|
var node = first_child(fragment);
|
|
16589
16589
|
{
|
|
16590
16590
|
var consequent = ($$anchor2) => {
|
|
16591
|
-
var fragment_1 = root_1$
|
|
16591
|
+
var fragment_1 = root_1$l();
|
|
16592
16592
|
var go_all_fields = first_child(fragment_1);
|
|
16593
16593
|
var go_form_feedback = sibling(go_all_fields, 2);
|
|
16594
16594
|
var go_submit = sibling(go_form_feedback, 2);
|
|
@@ -16615,7 +16615,7 @@ customElements.define("go-form", create_custom_element(
|
|
|
16615
16615
|
[],
|
|
16616
16616
|
["details"]
|
|
16617
16617
|
));
|
|
16618
|
-
var root$
|
|
16618
|
+
var root$d = /* @__PURE__ */ from_html(`<go-form></go-form>`, 2);
|
|
16619
16619
|
function PasswordReset($$anchor, $$props) {
|
|
16620
16620
|
push($$props, true);
|
|
16621
16621
|
let custom2 = prop($$props, "custom", 7, false);
|
|
@@ -16645,7 +16645,7 @@ function PasswordReset($$anchor, $$props) {
|
|
|
16645
16645
|
flushSync();
|
|
16646
16646
|
}
|
|
16647
16647
|
};
|
|
16648
|
-
var go_form = root$
|
|
16648
|
+
var go_form = root$d();
|
|
16649
16649
|
set_custom_element_data(go_form, "formId", "passwordReset");
|
|
16650
16650
|
template_effect(() => set_custom_element_data(go_form, "custom", custom2()));
|
|
16651
16651
|
event("submit", go_form, passwordReset);
|
|
@@ -16749,8 +16749,8 @@ customElements.define("go-sign-up", create_custom_element(
|
|
|
16749
16749
|
[],
|
|
16750
16750
|
[]
|
|
16751
16751
|
));
|
|
16752
|
-
var root_1$
|
|
16753
|
-
var root$
|
|
16752
|
+
var root_1$k = /* @__PURE__ */ from_html(`<span class="go-cart-item-date" data-testid="cart-item-date"> </span><span class="go-cart-item-time" data-testid="cart-item-time"> </span>`, 1);
|
|
16753
|
+
var root$c = /* @__PURE__ */ from_html(`<span class="go-cart-item-title" data-testid="cart-item-title"><span class="go-cart-item-title-event-title"> </span><span class="go-cart-item-title-ticket-title"> </span></span><!>`, 1);
|
|
16754
16754
|
function Event$2($$anchor, $$props) {
|
|
16755
16755
|
push($$props, true);
|
|
16756
16756
|
let cartItem = prop($$props, "cartItem", 7);
|
|
@@ -16765,7 +16765,7 @@ function Event$2($$anchor, $$props) {
|
|
|
16765
16765
|
flushSync();
|
|
16766
16766
|
}
|
|
16767
16767
|
};
|
|
16768
|
-
var fragment = root$
|
|
16768
|
+
var fragment = root$c();
|
|
16769
16769
|
var span = first_child(fragment);
|
|
16770
16770
|
var span_1 = child(span);
|
|
16771
16771
|
var text2 = child(span_1, true);
|
|
@@ -16777,7 +16777,7 @@ function Event$2($$anchor, $$props) {
|
|
|
16777
16777
|
var node = sibling(span);
|
|
16778
16778
|
{
|
|
16779
16779
|
var consequent = ($$anchor2) => {
|
|
16780
|
-
var fragment_1 = root_1$
|
|
16780
|
+
var fragment_1 = root_1$k();
|
|
16781
16781
|
var span_3 = first_child(fragment_1);
|
|
16782
16782
|
var text_2 = child(span_3, true);
|
|
16783
16783
|
reset(span_3);
|
|
@@ -16809,8 +16809,8 @@ function Event$2($$anchor, $$props) {
|
|
|
16809
16809
|
}
|
|
16810
16810
|
create_custom_element(Event$2, { cartItem: {} }, [], [], { mode: "open" });
|
|
16811
16811
|
var root_2$q = /* @__PURE__ */ from_html(`<span class="go-cart-item-time" data-testid="cart-item-time"> </span>`);
|
|
16812
|
-
var root_1$
|
|
16813
|
-
var root$
|
|
16812
|
+
var root_1$j = /* @__PURE__ */ from_html(`<span class="go-cart-item-date" data-testid="cart-item-date"> </span> <!>`, 1);
|
|
16813
|
+
var root$b = /* @__PURE__ */ from_html(`<span class="go-cart-item-title" data-testid="cart-item-title"> </span> <!>`, 1);
|
|
16814
16814
|
function Ticket($$anchor, $$props) {
|
|
16815
16815
|
push($$props, true);
|
|
16816
16816
|
let cartItem = prop($$props, "cartItem", 7);
|
|
@@ -16823,14 +16823,14 @@ function Ticket($$anchor, $$props) {
|
|
|
16823
16823
|
flushSync();
|
|
16824
16824
|
}
|
|
16825
16825
|
};
|
|
16826
|
-
var fragment = root$
|
|
16826
|
+
var fragment = root$b();
|
|
16827
16827
|
var span = first_child(fragment);
|
|
16828
16828
|
var text2 = child(span, true);
|
|
16829
16829
|
reset(span);
|
|
16830
16830
|
var node = sibling(span, 2);
|
|
16831
16831
|
{
|
|
16832
16832
|
var consequent_1 = ($$anchor2) => {
|
|
16833
|
-
var fragment_1 = root_1$
|
|
16833
|
+
var fragment_1 = root_1$j();
|
|
16834
16834
|
var span_1 = first_child(fragment_1);
|
|
16835
16835
|
var text_1 = child(span_1, true);
|
|
16836
16836
|
reset(span_1);
|
|
@@ -16880,11 +16880,11 @@ function generateQuantityOptions(from, to, options = { floor: 0 }) {
|
|
|
16880
16880
|
function option(value) {
|
|
16881
16881
|
return { value, label: value.toString() };
|
|
16882
16882
|
}
|
|
16883
|
-
var root_5$
|
|
16883
|
+
var root_5$1 = /* @__PURE__ */ from_html(`<span> </span>`);
|
|
16884
16884
|
var root_7$3 = /* @__PURE__ */ from_html(`<option> </option>`);
|
|
16885
16885
|
var root_6$2 = /* @__PURE__ */ from_html(`<select></select>`);
|
|
16886
16886
|
var root_8$2 = /* @__PURE__ */ from_html(`<li class="go-cart-item-remove" data-go-cart-item-remove=""><button>⨉</button></li>`);
|
|
16887
|
-
var root_1$
|
|
16887
|
+
var root_1$i = /* @__PURE__ */ from_html(`<article><ul><li data-go-cart-item-title=""><!></li> <li class="go-cart-item-price" data-go-cart-item-price=""> </li> <li class="go-cart-item-count" data-go-cart-item-count=""><!></li> <!> <li class="go-cart-item-sum" data-go-cart-item-sum=""> </li></ul></article>`);
|
|
16888
16888
|
function Item$1($$anchor, $$props) {
|
|
16889
16889
|
push($$props, true);
|
|
16890
16890
|
let cartItem = prop($$props, "cartItem", 7), cart = prop($$props, "cart", 7), preview = prop($$props, "preview", 7);
|
|
@@ -16927,7 +16927,7 @@ function Item$1($$anchor, $$props) {
|
|
|
16927
16927
|
var node = first_child(fragment);
|
|
16928
16928
|
{
|
|
16929
16929
|
var consequent_4 = ($$anchor2) => {
|
|
16930
|
-
var article = root_1$
|
|
16930
|
+
var article = root_1$i();
|
|
16931
16931
|
var ul = child(article);
|
|
16932
16932
|
var li = child(ul);
|
|
16933
16933
|
var node_1 = child(li);
|
|
@@ -16973,7 +16973,7 @@ function Item$1($$anchor, $$props) {
|
|
|
16973
16973
|
var node_3 = child(li_2);
|
|
16974
16974
|
{
|
|
16975
16975
|
var consequent_2 = ($$anchor3) => {
|
|
16976
|
-
var span = root_5$
|
|
16976
|
+
var span = root_5$1();
|
|
16977
16977
|
var text_1 = child(span, true);
|
|
16978
16978
|
reset(span);
|
|
16979
16979
|
template_effect(() => set_text(text_1, cartItem().quantity));
|
|
@@ -17042,7 +17042,7 @@ create_custom_element(Item$1, { cartItem: {}, cart: {}, preview: {} }, [], [], {
|
|
|
17042
17042
|
var root_2$p = /* @__PURE__ */ from_html(`<li class="go-cart-header-remove" data-go-cart-header-remove=""></li>`);
|
|
17043
17043
|
var root_3$8 = /* @__PURE__ */ from_html(`<li class="go-cart-item" data-go-cart-item=""><!></li>`);
|
|
17044
17044
|
var root_4$6 = /* @__PURE__ */ from_html(`<li class="go-cart-footer-remove" data-go-cart-footer-remove=""></li>`);
|
|
17045
|
-
var root_1$
|
|
17045
|
+
var root_1$h = /* @__PURE__ */ from_html(`<ol data-testid="cart"><li class="go-cart-header" data-go-cart-header="" data-testid="cart-header"><ul><li class="go-cart-header-title" data-go-cart-header-title=""> </li> <li class="go-cart-header-price" data-go-cart-header-price=""> </li> <li class="go-cart-header-count" data-go-cart-header-count=""> </li> <!> <li class="go-cart-header-sum" data-go-cart-header-sum=""> </li></ul></li> <!> <li class="go-cart-footer" data-go-cart-footer="" data-testid="cart-footer"><ul><li class="go-cart-footer-title" data-go-cart-footer-title=""></li> <li class="go-cart-footer-price" data-go-cart-footer-price=""></li> <li class="go-cart-footer-count" data-go-cart-footer-count=""></li> <!> <li class="go-cart-footer-sum" data-go-cart-footer-sum="" data-go-cart-sum=""> </li></ul></li></ol>`);
|
|
17046
17046
|
function Cart($$anchor, $$props) {
|
|
17047
17047
|
push($$props, true);
|
|
17048
17048
|
const preview = prop($$props, "preview", 7, false);
|
|
@@ -17060,7 +17060,7 @@ function Cart($$anchor, $$props) {
|
|
|
17060
17060
|
var node = first_child(fragment);
|
|
17061
17061
|
{
|
|
17062
17062
|
var consequent_2 = ($$anchor2) => {
|
|
17063
|
-
var ol = root_1$
|
|
17063
|
+
var ol = root_1$h();
|
|
17064
17064
|
var li = child(ol);
|
|
17065
17065
|
var ul = child(li);
|
|
17066
17066
|
var li_1 = child(ul);
|
|
@@ -17247,7 +17247,7 @@ async function redeem(form) {
|
|
|
17247
17247
|
form.details.apiErrors = [shop.t("cart.coupon.form.errors.notValid")];
|
|
17248
17248
|
}
|
|
17249
17249
|
}
|
|
17250
|
-
var root$
|
|
17250
|
+
var root$a = /* @__PURE__ */ from_html(`<go-form></go-form>`, 2);
|
|
17251
17251
|
function CouponRedemption($$anchor, $$props) {
|
|
17252
17252
|
push($$props, false);
|
|
17253
17253
|
Forms.defineForm({
|
|
@@ -17259,7 +17259,7 @@ function CouponRedemption($$anchor, $$props) {
|
|
|
17259
17259
|
await redeem(e.target);
|
|
17260
17260
|
}
|
|
17261
17261
|
init();
|
|
17262
|
-
var go_form = root$
|
|
17262
|
+
var go_form = root$a();
|
|
17263
17263
|
set_custom_element_data(go_form, "formId", "couponRedemption");
|
|
17264
17264
|
event("submit", go_form, redeem$1);
|
|
17265
17265
|
append($$anchor, go_form);
|
|
@@ -17309,8 +17309,8 @@ class GoDonation {
|
|
|
17309
17309
|
};
|
|
17310
17310
|
}
|
|
17311
17311
|
const goDonation = new GoDonation();
|
|
17312
|
-
var root_1$
|
|
17313
|
-
var root$
|
|
17312
|
+
var root_1$g = /* @__PURE__ */ from_html(`<img alt="logo"/>`);
|
|
17313
|
+
var root$9 = /* @__PURE__ */ from_html(`<div role="button" tabindex="0"><div class="donation-image"><!></div> <div class="donation-info"><p class="donation-info-title"> </p> <p class="donation-info-description"> </p></div></div>`);
|
|
17314
17314
|
function DonationCampaign($$anchor, $$props) {
|
|
17315
17315
|
push($$props, true);
|
|
17316
17316
|
let campaign = prop($$props, "campaign", 7);
|
|
@@ -17324,7 +17324,7 @@ function DonationCampaign($$anchor, $$props) {
|
|
|
17324
17324
|
flushSync();
|
|
17325
17325
|
}
|
|
17326
17326
|
};
|
|
17327
|
-
var div = root$
|
|
17327
|
+
var div = root$9();
|
|
17328
17328
|
let classes;
|
|
17329
17329
|
div.__click = () => goDonation.selectCampaign(campaign());
|
|
17330
17330
|
div.__keydown = (e) => {
|
|
@@ -17336,7 +17336,7 @@ function DonationCampaign($$anchor, $$props) {
|
|
|
17336
17336
|
var node = child(div_1);
|
|
17337
17337
|
{
|
|
17338
17338
|
var consequent = ($$anchor2) => {
|
|
17339
|
-
var img = root_1$
|
|
17339
|
+
var img = root_1$g();
|
|
17340
17340
|
template_effect(($0) => set_attribute(img, "src", $0), [
|
|
17341
17341
|
() => campaign().picture.thumbnail.replace("thumbnail", "article_3x2")
|
|
17342
17342
|
]);
|
|
@@ -17392,9 +17392,9 @@ function parseTokens(tokens, possibleTokens) {
|
|
|
17392
17392
|
});
|
|
17393
17393
|
return parsed.length > 0 ? parsed : void 0;
|
|
17394
17394
|
}
|
|
17395
|
-
var root_1$
|
|
17395
|
+
var root_1$f = /* @__PURE__ */ from_html(`<button> </button>`);
|
|
17396
17396
|
var root_2$o = /* @__PURE__ */ from_html(`<form id="donationForm" action="" novalidate=""><div class="donation-custom form-group"><label for="donation-custom-amount"> </label> <input class="form-control" id="donation-custom-amount" type="number" min="1"/></div></form>`);
|
|
17397
|
-
var root$
|
|
17397
|
+
var root$8 = /* @__PURE__ */ from_html(`<div class="donation-selection"><h3> </h3> <div class="donation-options"></div> <!></div>`);
|
|
17398
17398
|
function DonationSelector($$anchor, $$props) {
|
|
17399
17399
|
push($$props, true);
|
|
17400
17400
|
const guestMaxLimit = goDonation.campaign?.guest_limit / 100;
|
|
@@ -17412,13 +17412,13 @@ function DonationSelector($$anchor, $$props) {
|
|
|
17412
17412
|
form.reportValidity();
|
|
17413
17413
|
}
|
|
17414
17414
|
}
|
|
17415
|
-
var div = root$
|
|
17415
|
+
var div = root$8();
|
|
17416
17416
|
var h3 = child(div);
|
|
17417
17417
|
var text2 = child(h3, true);
|
|
17418
17418
|
reset(h3);
|
|
17419
17419
|
var div_1 = sibling(h3, 2);
|
|
17420
17420
|
each(div_1, 20, () => goDonation.campaign?.options, (option2) => option2, ($$anchor2, option2) => {
|
|
17421
|
-
var button = root_1$
|
|
17421
|
+
var button = root_1$f();
|
|
17422
17422
|
let classes;
|
|
17423
17423
|
button.__click = () => selectAmount(option2);
|
|
17424
17424
|
var text_1 = child(button, true);
|
|
@@ -17471,7 +17471,7 @@ function DonationSelector($$anchor, $$props) {
|
|
|
17471
17471
|
}
|
|
17472
17472
|
delegate(["click", "input"]);
|
|
17473
17473
|
create_custom_element(DonationSelector, {}, [], [], { mode: "open" });
|
|
17474
|
-
var root_1$
|
|
17474
|
+
var root_1$e = /* @__PURE__ */ from_html(`<div class="go-donations-list"><!> <!> <div class="donation-actions"><button class="btn btn-default"> </button> <button class="btn btn-primary"> </button></div></div>`);
|
|
17475
17475
|
function Donations($$anchor, $$props) {
|
|
17476
17476
|
push($$props, false);
|
|
17477
17477
|
onMount(() => {
|
|
@@ -17484,7 +17484,7 @@ function Donations($$anchor, $$props) {
|
|
|
17484
17484
|
var node = first_child(fragment);
|
|
17485
17485
|
{
|
|
17486
17486
|
var consequent_1 = ($$anchor2) => {
|
|
17487
|
-
var div = root_1$
|
|
17487
|
+
var div = root_1$e();
|
|
17488
17488
|
var node_1 = child(div);
|
|
17489
17489
|
each(node_1, 1, () => shop?.donations?.campaigns, (campaign) => campaign.id, ($$anchor3, campaign) => {
|
|
17490
17490
|
DonationCampaign($$anchor3, {
|
|
@@ -23684,7 +23684,7 @@ function Calendar_prev_button($$anchor, $$props) {
|
|
|
23684
23684
|
return pop($$exports);
|
|
23685
23685
|
}
|
|
23686
23686
|
create_custom_element(Calendar_prev_button, { children: {}, child: {}, id: {}, ref: {}, tabindex: {} }, [], [], { mode: "open" });
|
|
23687
|
-
var root_1$
|
|
23687
|
+
var root_1$d = /* @__PURE__ */ from_html(`<input/>`);
|
|
23688
23688
|
var root_2$b = /* @__PURE__ */ from_html(`<input/>`);
|
|
23689
23689
|
function Hidden_input($$anchor, $$props) {
|
|
23690
23690
|
push($$props, true);
|
|
@@ -23707,7 +23707,7 @@ function Hidden_input($$anchor, $$props) {
|
|
|
23707
23707
|
var node = first_child(fragment);
|
|
23708
23708
|
{
|
|
23709
23709
|
var consequent = ($$anchor2) => {
|
|
23710
|
-
var input = root_1$
|
|
23710
|
+
var input = root_1$d();
|
|
23711
23711
|
attribute_effect(input, () => ({ ...get$2(mergedProps), value: value() }), void 0, void 0, void 0, void 0, true);
|
|
23712
23712
|
append($$anchor2, input);
|
|
23713
23713
|
};
|
|
@@ -26161,7 +26161,7 @@ function Popper_content($$anchor, $$props) {
|
|
|
26161
26161
|
return pop($$exports);
|
|
26162
26162
|
}
|
|
26163
26163
|
create_custom_element(Popper_content, { content: {}, isStatic: {}, onPlaced: {} }, [], [], { mode: "open" });
|
|
26164
|
-
var root_1$
|
|
26164
|
+
var root_1$c = /* @__PURE__ */ from_html(`<!> <!>`, 1);
|
|
26165
26165
|
function Popper_layer_inner($$anchor, $$props) {
|
|
26166
26166
|
push($$props, true);
|
|
26167
26167
|
let popper = prop($$props, "popper", 7), onEscapeKeydown = prop($$props, "onEscapeKeydown", 7), escapeKeydownBehavior = prop($$props, "escapeKeydownBehavior", 7), preventOverflowTextSelection = prop($$props, "preventOverflowTextSelection", 7), id = prop($$props, "id", 7), onPointerDown = prop($$props, "onPointerDown", 7), onPointerUp = prop($$props, "onPointerUp", 7), side = prop($$props, "side", 7), sideOffset = prop($$props, "sideOffset", 7), align = prop($$props, "align", 7), alignOffset = prop($$props, "alignOffset", 7), arrowPadding = prop($$props, "arrowPadding", 7), avoidCollisions = prop($$props, "avoidCollisions", 7), collisionBoundary = prop($$props, "collisionBoundary", 7), collisionPadding = prop($$props, "collisionPadding", 7), sticky = prop($$props, "sticky", 7), hideWhenDetached = prop($$props, "hideWhenDetached", 7), updatePositionStrategy = prop($$props, "updatePositionStrategy", 7), strategy = prop($$props, "strategy", 7), dir = prop($$props, "dir", 7), preventScroll = prop($$props, "preventScroll", 7), wrapperId = prop($$props, "wrapperId", 7), style = prop($$props, "style", 7), onPlaced = prop($$props, "onPlaced", 7), onInteractOutside = prop($$props, "onInteractOutside", 7), onCloseAutoFocus = prop($$props, "onCloseAutoFocus", 7), onOpenAutoFocus = prop($$props, "onOpenAutoFocus", 7), onFocusOutside = prop($$props, "onFocusOutside", 7), interactOutsideBehavior = prop($$props, "interactOutsideBehavior", 7, "close"), loop = prop($$props, "loop", 7), trapFocus = prop($$props, "trapFocus", 7, true), isValidEvent2 = prop($$props, "isValidEvent", 7, () => false), customAnchor = prop($$props, "customAnchor", 7, null), isStatic = prop($$props, "isStatic", 7, false), enabled = prop($$props, "enabled", 7), ref = prop($$props, "ref", 7), tooltip = prop($$props, "tooltip", 7, false), contentPointerEvents = prop($$props, "contentPointerEvents", 7, "auto"), restProps = /* @__PURE__ */ rest_props($$props, [
|
|
@@ -26480,7 +26480,7 @@ function Popper_layer_inner($$anchor, $$props) {
|
|
|
26480
26480
|
const content = ($$anchor2, $$arg0) => {
|
|
26481
26481
|
let floatingProps = () => $$arg0?.().props;
|
|
26482
26482
|
let wrapperProps = () => $$arg0?.().wrapperProps;
|
|
26483
|
-
var fragment_1 = root_1$
|
|
26483
|
+
var fragment_1 = root_1$c();
|
|
26484
26484
|
var node = first_child(fragment_1);
|
|
26485
26485
|
{
|
|
26486
26486
|
var consequent = ($$anchor3) => {
|
|
@@ -28936,7 +28936,7 @@ function Date_field_hidden_input($$anchor, $$props) {
|
|
|
28936
28936
|
}
|
|
28937
28937
|
create_custom_element(Date_field_hidden_input, {}, [], [], { mode: "open" });
|
|
28938
28938
|
var root_2$a = /* @__PURE__ */ from_html(`<div><!></div>`);
|
|
28939
|
-
var root$
|
|
28939
|
+
var root$7 = /* @__PURE__ */ from_html(`<!> <!>`, 1);
|
|
28940
28940
|
function Date_field_input($$anchor, $$props) {
|
|
28941
28941
|
const uid = props_id();
|
|
28942
28942
|
push($$props, true);
|
|
@@ -28994,7 +28994,7 @@ function Date_field_input($$anchor, $$props) {
|
|
|
28994
28994
|
flushSync();
|
|
28995
28995
|
}
|
|
28996
28996
|
};
|
|
28997
|
-
var fragment = root$
|
|
28997
|
+
var fragment = root$7();
|
|
28998
28998
|
var node = first_child(fragment);
|
|
28999
28999
|
{
|
|
29000
29000
|
var consequent = ($$anchor2) => {
|
|
@@ -30852,7 +30852,7 @@ var root_4$4 = /* @__PURE__ */ from_html(`<!> <!>`, 1);
|
|
|
30852
30852
|
var root_9$2 = /* @__PURE__ */ from_html(`<!> <!> <!>`, 1);
|
|
30853
30853
|
var root_11$3 = /* @__PURE__ */ from_html(`<!> <!>`, 1);
|
|
30854
30854
|
var root_8$1 = /* @__PURE__ */ from_html(`<!> <!>`, 1);
|
|
30855
|
-
var root_1$
|
|
30855
|
+
var root_1$b = /* @__PURE__ */ from_html(`<!> <!> <!>`, 1);
|
|
30856
30856
|
function DatePicker_1($$anchor, $$props) {
|
|
30857
30857
|
push($$props, true);
|
|
30858
30858
|
let dateString = prop($$props, "dateString", 15), labelClass = prop($$props, "labelClass", 7), inputClass = prop($$props, "inputClass", 7), labelText = prop($$props, "labelText", 7);
|
|
@@ -30909,7 +30909,7 @@ function DatePicker_1($$anchor, $$props) {
|
|
|
30909
30909
|
set(date2, $$value, true);
|
|
30910
30910
|
},
|
|
30911
30911
|
children: ($$anchor3, $$slotProps) => {
|
|
30912
|
-
var fragment_1 = root_1$
|
|
30912
|
+
var fragment_1 = root_1$b();
|
|
30913
30913
|
var node_1 = first_child(fragment_1);
|
|
30914
30914
|
component(node_1, () => Date_field_label, ($$anchor4, DatePicker_Label) => {
|
|
30915
30915
|
DatePicker_Label($$anchor4, {
|
|
@@ -31154,19 +31154,19 @@ create_custom_element(
|
|
|
31154
31154
|
{ mode: "open" }
|
|
31155
31155
|
);
|
|
31156
31156
|
var root_2$6 = /* @__PURE__ */ from_html(`<span class="go-field-star" aria-hidden="true">*</span>`);
|
|
31157
|
-
var root_1$
|
|
31157
|
+
var root_1$a = /* @__PURE__ */ from_html(` <!>`, 1);
|
|
31158
31158
|
var root_3$6 = /* @__PURE__ */ from_html(`<label><!></label> <input/>`, 1);
|
|
31159
31159
|
var root_4$3 = /* @__PURE__ */ from_html(`<label><input/> <span class="go-checkbox-label"><!></span></label>`);
|
|
31160
31160
|
var root_7$2 = /* @__PURE__ */ from_html(`<option> </option>`);
|
|
31161
31161
|
var root_6$1 = /* @__PURE__ */ from_html(`<option disabled hidden="" selected> </option> <!>`, 1);
|
|
31162
|
-
var root_5
|
|
31162
|
+
var root_5 = /* @__PURE__ */ from_html(`<label><!></label> <select><!></select>`, 1);
|
|
31163
31163
|
var root_11$2 = /* @__PURE__ */ from_html(`<label> <input/></label>`);
|
|
31164
31164
|
var root_9$1 = /* @__PURE__ */ from_html(`<fieldset><legend><!></legend> <!></fieldset>`);
|
|
31165
31165
|
function InputAndLabel($$anchor, $$props) {
|
|
31166
31166
|
push($$props, true);
|
|
31167
31167
|
const labelText = ($$anchor2) => {
|
|
31168
31168
|
next();
|
|
31169
|
-
var fragment = root_1$
|
|
31169
|
+
var fragment = root_1$a();
|
|
31170
31170
|
var text2 = first_child(fragment);
|
|
31171
31171
|
var node = sibling(text2);
|
|
31172
31172
|
{
|
|
@@ -31250,7 +31250,7 @@ function InputAndLabel($$anchor, $$props) {
|
|
|
31250
31250
|
append($$anchor2, label_2);
|
|
31251
31251
|
};
|
|
31252
31252
|
const select = ($$anchor2) => {
|
|
31253
|
-
var fragment_2 = root_5
|
|
31253
|
+
var fragment_2 = root_5();
|
|
31254
31254
|
var label_3 = first_child(fragment_2);
|
|
31255
31255
|
var node_3 = child(label_3);
|
|
31256
31256
|
labelText(node_3);
|
|
@@ -31365,13 +31365,13 @@ function InputAndLabel($$anchor, $$props) {
|
|
|
31365
31365
|
reset(fieldset);
|
|
31366
31366
|
append($$anchor2, fieldset);
|
|
31367
31367
|
};
|
|
31368
|
-
let field = prop($$props, "field", 15),
|
|
31368
|
+
let field = prop($$props, "field", 15), describedByIds = prop($$props, "describedByIds", 7), labelClass = prop($$props, "labelClass", 7), inputClass = prop($$props, "inputClass", 7), host = prop($$props, "host", 7), restProps = /* @__PURE__ */ rest_props($$props, [
|
|
31369
31369
|
"$$slots",
|
|
31370
31370
|
"$$events",
|
|
31371
31371
|
"$$legacy",
|
|
31372
31372
|
"$$host",
|
|
31373
31373
|
"field",
|
|
31374
|
-
"
|
|
31374
|
+
"describedByIds",
|
|
31375
31375
|
"labelClass",
|
|
31376
31376
|
"inputClass",
|
|
31377
31377
|
"host"
|
|
@@ -31403,7 +31403,7 @@ function InputAndLabel($$anchor, $$props) {
|
|
|
31403
31403
|
}
|
|
31404
31404
|
const fieldAttributes = /* @__PURE__ */ user_derived(() => ({
|
|
31405
31405
|
id: get$2(inputId),
|
|
31406
|
-
"aria-describedby":
|
|
31406
|
+
"aria-describedby": describedByIds(),
|
|
31407
31407
|
"aria-required": field().required,
|
|
31408
31408
|
"aria-invalid": field().errors.length > 0,
|
|
31409
31409
|
autocomplete: field().autocomplete,
|
|
@@ -31418,11 +31418,11 @@ function InputAndLabel($$anchor, $$props) {
|
|
|
31418
31418
|
field($$value);
|
|
31419
31419
|
flushSync();
|
|
31420
31420
|
},
|
|
31421
|
-
get
|
|
31422
|
-
return
|
|
31421
|
+
get describedByIds() {
|
|
31422
|
+
return describedByIds();
|
|
31423
31423
|
},
|
|
31424
|
-
set
|
|
31425
|
-
|
|
31424
|
+
set describedByIds($$value) {
|
|
31425
|
+
describedByIds($$value);
|
|
31426
31426
|
flushSync();
|
|
31427
31427
|
},
|
|
31428
31428
|
get labelClass() {
|
|
@@ -31467,7 +31467,7 @@ create_custom_element(
|
|
|
31467
31467
|
InputAndLabel,
|
|
31468
31468
|
{
|
|
31469
31469
|
field: {},
|
|
31470
|
-
|
|
31470
|
+
describedByIds: {},
|
|
31471
31471
|
labelClass: {},
|
|
31472
31472
|
inputClass: {},
|
|
31473
31473
|
host: {}
|
|
@@ -31476,10 +31476,10 @@ create_custom_element(
|
|
|
31476
31476
|
[],
|
|
31477
31477
|
{ mode: "open" }
|
|
31478
31478
|
);
|
|
31479
|
-
var root_1$
|
|
31479
|
+
var root_1$9 = /* @__PURE__ */ from_html(`<span> </span>`);
|
|
31480
31480
|
var root_3$5 = /* @__PURE__ */ from_html(`<li> </li>`);
|
|
31481
|
-
var root_2$5 = /* @__PURE__ */ from_html(`<ul class="go-field-errors"
|
|
31482
|
-
var root$
|
|
31481
|
+
var root_2$5 = /* @__PURE__ */ from_html(`<ul class="go-field-errors"></ul>`);
|
|
31482
|
+
var root$6 = /* @__PURE__ */ from_html(`<!> <!> <!>`, 1);
|
|
31483
31483
|
function Field($$anchor, $$props) {
|
|
31484
31484
|
push($$props, true);
|
|
31485
31485
|
let key = prop($$props, "key", 7), required = prop($$props, "required", 7, false), labelClass = prop($$props, "labelClass", 7), inputClass = prop($$props, "inputClass", 7);
|
|
@@ -31488,9 +31488,14 @@ function Field($$anchor, $$props) {
|
|
|
31488
31488
|
const details = /* @__PURE__ */ user_derived(() => _details.value);
|
|
31489
31489
|
const getField = () => get$2(field);
|
|
31490
31490
|
let allErrors = /* @__PURE__ */ user_derived(() => get$2(field) ? [...get$2(field).errors, ...get$2(field).apiErrors].map((e) => shop.t(e)) : []);
|
|
31491
|
-
let
|
|
31492
|
-
let
|
|
31493
|
-
let
|
|
31491
|
+
let hasDescription = /* @__PURE__ */ user_derived(() => get$2(field)?.description);
|
|
31492
|
+
let hasErrors = /* @__PURE__ */ user_derived(() => get$2(allErrors).length > 0);
|
|
31493
|
+
let descriptionId = /* @__PURE__ */ user_derived(() => `go-description-${key()}-${Math.floor(Math.random() * 100)}`);
|
|
31494
|
+
let errorsId = /* @__PURE__ */ user_derived(() => `go-errors-${key()}-${Math.floor(Math.random() * 100)}`);
|
|
31495
|
+
let describedByIds = /* @__PURE__ */ user_derived(() => [
|
|
31496
|
+
get$2(hasDescription) && get$2(descriptionId),
|
|
31497
|
+
get$2(hasErrors) && get$2(errorsId)
|
|
31498
|
+
].filter(Boolean).join(" ") || void 0);
|
|
31494
31499
|
user_effect(() => {
|
|
31495
31500
|
$$props.$$host.classList.toggle("go-field", true);
|
|
31496
31501
|
$$props.$$host.classList.toggle("is-invalid", get$2(allErrors).length > 0);
|
|
@@ -31538,11 +31543,11 @@ function Field($$anchor, $$props) {
|
|
|
31538
31543
|
flushSync();
|
|
31539
31544
|
}
|
|
31540
31545
|
};
|
|
31541
|
-
var fragment = root$
|
|
31546
|
+
var fragment = root$6();
|
|
31542
31547
|
var node = first_child(fragment);
|
|
31543
31548
|
InputAndLabel(node, {
|
|
31544
|
-
get
|
|
31545
|
-
return get$2(
|
|
31549
|
+
get describedByIds() {
|
|
31550
|
+
return get$2(describedByIds);
|
|
31546
31551
|
},
|
|
31547
31552
|
get labelClass() {
|
|
31548
31553
|
return labelClass();
|
|
@@ -31561,7 +31566,7 @@ function Field($$anchor, $$props) {
|
|
|
31561
31566
|
var node_1 = sibling(node, 2);
|
|
31562
31567
|
{
|
|
31563
31568
|
var consequent = ($$anchor2) => {
|
|
31564
|
-
var span = root_1$
|
|
31569
|
+
var span = root_1$9();
|
|
31565
31570
|
var text2 = child(span, true);
|
|
31566
31571
|
reset(span);
|
|
31567
31572
|
template_effect(() => {
|
|
@@ -31571,7 +31576,7 @@ function Field($$anchor, $$props) {
|
|
|
31571
31576
|
append($$anchor2, span);
|
|
31572
31577
|
};
|
|
31573
31578
|
if_block(node_1, ($$render) => {
|
|
31574
|
-
if (get$2(
|
|
31579
|
+
if (get$2(hasDescription)) $$render(consequent);
|
|
31575
31580
|
});
|
|
31576
31581
|
}
|
|
31577
31582
|
var node_2 = sibling(node_1, 2);
|
|
@@ -31590,7 +31595,7 @@ function Field($$anchor, $$props) {
|
|
|
31590
31595
|
append($$anchor2, ul);
|
|
31591
31596
|
};
|
|
31592
31597
|
if_block(node_2, ($$render) => {
|
|
31593
|
-
if (get$2(
|
|
31598
|
+
if (get$2(hasErrors)) $$render(consequent_1);
|
|
31594
31599
|
});
|
|
31595
31600
|
}
|
|
31596
31601
|
append($$anchor, fragment);
|
|
@@ -31607,7 +31612,7 @@ customElements.define("go-field", create_custom_element(
|
|
|
31607
31612
|
[],
|
|
31608
31613
|
["getField"]
|
|
31609
31614
|
));
|
|
31610
|
-
var root_1$
|
|
31615
|
+
var root_1$8 = /* @__PURE__ */ from_html(`<go-field></go-field>`, 2);
|
|
31611
31616
|
function AllFields($$anchor, $$props) {
|
|
31612
31617
|
push($$props, true);
|
|
31613
31618
|
let _details = getDetails$1($$props.$$host);
|
|
@@ -31616,7 +31621,7 @@ function AllFields($$anchor, $$props) {
|
|
|
31616
31621
|
var fragment = comment();
|
|
31617
31622
|
var node = first_child(fragment);
|
|
31618
31623
|
each(node, 17, () => get$2(allFields2), index$1, ($$anchor2, field) => {
|
|
31619
|
-
var go_field = root_1$
|
|
31624
|
+
var go_field = root_1$8();
|
|
31620
31625
|
template_effect(() => set_custom_element_data(go_field, "key", get$2(field).key));
|
|
31621
31626
|
template_effect(() => set_custom_element_data(go_field, "required", get$2(field).required));
|
|
31622
31627
|
append($$anchor2, go_field);
|
|
@@ -31625,11 +31630,10 @@ function AllFields($$anchor, $$props) {
|
|
|
31625
31630
|
pop();
|
|
31626
31631
|
}
|
|
31627
31632
|
customElements.define("go-all-fields", create_custom_element(AllFields, {}, [], []));
|
|
31628
|
-
var root_2$4 = /* @__PURE__ */ from_html(`<p aria-
|
|
31633
|
+
var root_2$4 = /* @__PURE__ */ from_html(`<p aria-hidden="true"> </p>`);
|
|
31629
31634
|
var root_4$2 = /* @__PURE__ */ from_html(`<li> </li>`);
|
|
31630
31635
|
var root_3$4 = /* @__PURE__ */ from_html(`<ul class="go-error-feedback-api-errors"></ul>`);
|
|
31631
|
-
var
|
|
31632
|
-
var root_1$8 = /* @__PURE__ */ from_html(`<div><!> <!> <!></div>`);
|
|
31636
|
+
var root$5 = /* @__PURE__ */ from_html(`<div><p aria-live="assertive" class="sr-only"><!></p> <!> <!></div>`);
|
|
31633
31637
|
function ErrorsFeedback($$anchor, $$props) {
|
|
31634
31638
|
push($$props, true);
|
|
31635
31639
|
const _details = getDetails$1($$props.$$host);
|
|
@@ -31639,80 +31643,71 @@ function ErrorsFeedback($$anchor, $$props) {
|
|
|
31639
31643
|
set(errorsOnSubmit, errors(get$2(details)?.fields), true);
|
|
31640
31644
|
});
|
|
31641
31645
|
});
|
|
31642
|
-
let errorsRealtime = /* @__PURE__ */ state(
|
|
31646
|
+
let errorsRealtime = /* @__PURE__ */ state(0);
|
|
31643
31647
|
setInterval(
|
|
31644
31648
|
() => {
|
|
31645
|
-
set(errorsRealtime, errors(get$2(details)?.fields), true);
|
|
31649
|
+
set(errorsRealtime, errors(get$2(details)?.fields) || 0, true);
|
|
31646
31650
|
},
|
|
31647
31651
|
100
|
|
31648
31652
|
);
|
|
31653
|
+
let numErrors = /* @__PURE__ */ user_derived(() => get$2(errorsRealtime) + (get$2(details)?.apiErrors?.length || 0));
|
|
31649
31654
|
let errorsOnSubmit = /* @__PURE__ */ state(-1);
|
|
31650
|
-
|
|
31651
|
-
|
|
31652
|
-
|
|
31655
|
+
user_effect(() => {
|
|
31656
|
+
$$props.$$host.classList.toggle("is-invalid", get$2(numErrors) > 0);
|
|
31657
|
+
$$props.$$host.classList.toggle("go-feedback", true);
|
|
31658
|
+
$$props.$$host.setAttribute("data-num-errors", get$2(numErrors).toString());
|
|
31659
|
+
});
|
|
31660
|
+
var div = root$5();
|
|
31661
|
+
var p2 = child(div);
|
|
31662
|
+
var node = child(p2);
|
|
31653
31663
|
{
|
|
31654
|
-
var
|
|
31655
|
-
var
|
|
31656
|
-
|
|
31657
|
-
|
|
31658
|
-
|
|
31659
|
-
|
|
31660
|
-
var p2 = root_2$4();
|
|
31661
|
-
var text2 = child(p2, true);
|
|
31662
|
-
reset(p2);
|
|
31663
|
-
template_effect(($0) => set_text(text2, $0), [
|
|
31664
|
-
() => shop.t("forms.errorSummary", { count: get$2(errorsOnSubmit) })
|
|
31665
|
-
]);
|
|
31666
|
-
append($$anchor3, p2);
|
|
31667
|
-
};
|
|
31668
|
-
if_block(node_1, ($$render) => {
|
|
31669
|
-
if (get$2(errorsOnSubmit) > 0) $$render(consequent);
|
|
31670
|
-
});
|
|
31671
|
-
}
|
|
31672
|
-
var node_2 = sibling(node_1, 2);
|
|
31673
|
-
{
|
|
31674
|
-
var consequent_1 = ($$anchor3) => {
|
|
31675
|
-
var ul = root_3$4();
|
|
31676
|
-
each(ul, 21, () => get$2(details)?.apiErrors, index$1, ($$anchor4, error) => {
|
|
31677
|
-
var li = root_4$2();
|
|
31678
|
-
var text_1 = child(li, true);
|
|
31679
|
-
reset(li);
|
|
31680
|
-
template_effect(() => set_text(text_1, get$2(error)));
|
|
31681
|
-
append($$anchor4, li);
|
|
31682
|
-
});
|
|
31683
|
-
reset(ul);
|
|
31684
|
-
append($$anchor3, ul);
|
|
31685
|
-
};
|
|
31686
|
-
if_block(node_2, ($$render) => {
|
|
31687
|
-
if (get$2(details) && isArray(get$2(details).apiErrors) && get$2(details).apiErrors.length > 0) $$render(consequent_1);
|
|
31688
|
-
});
|
|
31689
|
-
}
|
|
31690
|
-
var node_3 = sibling(node_2, 2);
|
|
31691
|
-
{
|
|
31692
|
-
var consequent_2 = ($$anchor3) => {
|
|
31693
|
-
var p_1 = root_5();
|
|
31694
|
-
var text_2 = child(p_1, true);
|
|
31695
|
-
reset(p_1);
|
|
31696
|
-
template_effect(($0) => set_text(text_2, $0), [
|
|
31697
|
-
() => shop.t("forms.errorSummary", { count: get$2(errorsRealtime) })
|
|
31698
|
-
]);
|
|
31699
|
-
append($$anchor3, p_1);
|
|
31700
|
-
};
|
|
31701
|
-
if_block(node_3, ($$render) => {
|
|
31702
|
-
if (get$2(errorsRealtime) > 0) $$render(consequent_2);
|
|
31703
|
-
});
|
|
31704
|
-
}
|
|
31705
|
-
reset(div);
|
|
31706
|
-
template_effect(() => classes = set_class(div, 1, "go-error-feedback go-feedback", null, classes, {
|
|
31707
|
-
"is-invalid": get$2(errorsRealtime) || get$2(generalApiErrors).length > 0
|
|
31708
|
-
}));
|
|
31709
|
-
append($$anchor2, div);
|
|
31664
|
+
var consequent = ($$anchor2) => {
|
|
31665
|
+
var text$1 = text();
|
|
31666
|
+
template_effect(($0) => set_text(text$1, $0), [
|
|
31667
|
+
() => shop.t("forms.errorSummary", { count: get$2(errorsOnSubmit) })
|
|
31668
|
+
]);
|
|
31669
|
+
append($$anchor2, text$1);
|
|
31710
31670
|
};
|
|
31711
31671
|
if_block(node, ($$render) => {
|
|
31712
|
-
if (get$2(
|
|
31672
|
+
if (get$2(errorsOnSubmit) > 0) $$render(consequent);
|
|
31713
31673
|
});
|
|
31714
31674
|
}
|
|
31715
|
-
|
|
31675
|
+
reset(p2);
|
|
31676
|
+
var node_1 = sibling(p2, 2);
|
|
31677
|
+
{
|
|
31678
|
+
var consequent_1 = ($$anchor2) => {
|
|
31679
|
+
var p_1 = root_2$4();
|
|
31680
|
+
var text_1 = child(p_1, true);
|
|
31681
|
+
reset(p_1);
|
|
31682
|
+
template_effect(($0) => set_text(text_1, $0), [
|
|
31683
|
+
() => shop.t("forms.errorSummary", { count: get$2(errorsRealtime) })
|
|
31684
|
+
]);
|
|
31685
|
+
append($$anchor2, p_1);
|
|
31686
|
+
};
|
|
31687
|
+
if_block(node_1, ($$render) => {
|
|
31688
|
+
if (get$2(errorsRealtime) > 0) $$render(consequent_1);
|
|
31689
|
+
});
|
|
31690
|
+
}
|
|
31691
|
+
var node_2 = sibling(node_1, 2);
|
|
31692
|
+
{
|
|
31693
|
+
var consequent_2 = ($$anchor2) => {
|
|
31694
|
+
var ul = root_3$4();
|
|
31695
|
+
each(ul, 21, () => get$2(details)?.apiErrors, index$1, ($$anchor3, error) => {
|
|
31696
|
+
var li = root_4$2();
|
|
31697
|
+
var text_2 = child(li, true);
|
|
31698
|
+
reset(li);
|
|
31699
|
+
template_effect(() => set_text(text_2, get$2(error)));
|
|
31700
|
+
append($$anchor3, li);
|
|
31701
|
+
});
|
|
31702
|
+
reset(ul);
|
|
31703
|
+
append($$anchor2, ul);
|
|
31704
|
+
};
|
|
31705
|
+
if_block(node_2, ($$render) => {
|
|
31706
|
+
if (get$2(details) && isArray(get$2(details).apiErrors) && get$2(details).apiErrors.length > 0) $$render(consequent_2);
|
|
31707
|
+
});
|
|
31708
|
+
}
|
|
31709
|
+
reset(div);
|
|
31710
|
+
append($$anchor, div);
|
|
31716
31711
|
pop();
|
|
31717
31712
|
}
|
|
31718
31713
|
customElements.define("go-errors-feedback", create_custom_element(ErrorsFeedback, {}, [], []));
|