diff --git a/data/templates/1-payment-button.json b/data/templates/1-payment-button.json index 4695bab1..91eb3c7b 100644 --- a/data/templates/1-payment-button.json +++ b/data/templates/1-payment-button.json @@ -1,5 +1,7 @@ { "id": "53e12229-1cef-4313-9f97-e5f75b98af841", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "lite", "personal", diff --git a/data/templates/2-donate-button.json b/data/templates/2-donate-button.json index acb0f21e..e50a7977 100644 --- a/data/templates/2-donate-button.json +++ b/data/templates/2-donate-button.json @@ -1,5 +1,7 @@ { "id": "20746d04-3d3d-45cd-9681-445c8bfac479", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "lite", "personal", diff --git a/data/templates/3-payment-form.json b/data/templates/3-payment-form.json index 0f07efd6..85b741b5 100644 --- a/data/templates/3-payment-form.json +++ b/data/templates/3-payment-form.json @@ -1,5 +1,7 @@ { "id": "ec0e97c2-6dda-4a7a-9f85-83969ff452eb", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ "on-site" ], diff --git a/data/templates/accepted-quote-payment-form.json b/data/templates/accepted-quote-payment-form.json index 2973a84a..fd84780e 100644 --- a/data/templates/accepted-quote-payment-form.json +++ b/data/templates/accepted-quote-payment-form.json @@ -1,5 +1,7 @@ { "id": "fb95aee0-3d3a-4893-85a3-5ca3e57467cd", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "business-operations" ], "keywords": [ "on-site", "business", "fee", "quote", "payment" ], diff --git a/data/templates/ach-direct-debit-payment-form.json b/data/templates/ach-direct-debit-payment-form.json index 3d4ec529..aa9e5ebb 100644 --- a/data/templates/ach-direct-debit-payment-form.json +++ b/data/templates/ach-direct-debit-payment-form.json @@ -1,5 +1,7 @@ { "id": "125cf8e1-84ab-42a9-82f4-077de46388f6", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ "on-site", "bank", "account", "u.s" ], diff --git a/data/templates/afterpay-clearpay-payment-form.json b/data/templates/afterpay-clearpay-payment-form.json index a54ce29d..00d29d1e 100644 --- a/data/templates/afterpay-clearpay-payment-form.json +++ b/data/templates/afterpay-clearpay-payment-form.json @@ -1,5 +1,7 @@ { "id": "e1336366-a8d6-4e6b-8ece-7ab476d96e28", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ "buy now", "pay later", "on-site" ], diff --git a/data/templates/alipay-payment-form.json b/data/templates/alipay-payment-form.json index 661cdaba..00ce648d 100644 --- a/data/templates/alipay-payment-form.json +++ b/data/templates/alipay-payment-form.json @@ -1,5 +1,7 @@ { "id": "26b5e795-cddc-485d-97ff-adf92c559fcc", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ "on-site", "alipay" ], diff --git a/data/templates/alumni-services-donation-form.json b/data/templates/alumni-services-donation-form.json index c12f9edd..ca208909 100644 --- a/data/templates/alumni-services-donation-form.json +++ b/data/templates/alumni-services-donation-form.json @@ -1,5 +1,7 @@ { "id": "45056b78-55f6-434d-aa14-2ca06025b4a3", + "created_at": "2022-12-15 00:00:00", + "updated_at": "2022-12-15 00:00:00", "license": [ "plus", "professional", "ultimate", "elite" ], "categories": [ "donations" ], "keywords": [ "alumni", "donate", "donation", "school" ], diff --git a/data/templates/animal-recovery-donation-form.json b/data/templates/animal-recovery-donation-form.json index 4591078a..f16fb375 100644 --- a/data/templates/animal-recovery-donation-form.json +++ b/data/templates/animal-recovery-donation-form.json @@ -1,5 +1,7 @@ { "id": "b7d703a7-2ac3-45d0-983c-6dc78129a862", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "donations" ], "keywords": [ "pet", "donate", "donation", "recovery" ], diff --git a/data/templates/apple-pay-google-pay-payment-form.json b/data/templates/apple-pay-google-pay-payment-form.json index c4c9f150..c5f30a19 100644 --- a/data/templates/apple-pay-google-pay-payment-form.json +++ b/data/templates/apple-pay-google-pay-payment-form.json @@ -1,5 +1,7 @@ { "id": "6d08e14b-fb0f-492d-bb2e-fad14b905f6d", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ "on-site" ], diff --git a/data/templates/attorney-fee-payment-form.json b/data/templates/attorney-fee-payment-form.json index f6f1d48b..00d88bf5 100644 --- a/data/templates/attorney-fee-payment-form.json +++ b/data/templates/attorney-fee-payment-form.json @@ -1,5 +1,7 @@ { "id": "2a6e7c6f-92f3-49fd-8d3b-8ecc9faaf853", + "created_at": "2022-12-15 00:00:00", + "updated_at": "2022-12-15 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "business-operations" ], "keywords": [ "attorney", "legal", "business", "fee", "payment" ], diff --git a/data/templates/bancontact-payment-form.json b/data/templates/bancontact-payment-form.json index cd074503..e510ee43 100644 --- a/data/templates/bancontact-payment-form.json +++ b/data/templates/bancontact-payment-form.json @@ -1,5 +1,7 @@ { "id": "258107b2-215c-4f31-9c94-4c2aa3fd4bd3", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ "on-site", "bancontact", "belgium" ], diff --git a/data/templates/business-consultation-fee-payment-form.json b/data/templates/business-consultation-fee-payment-form.json index 3a60ed71..d36ed2bd 100644 --- a/data/templates/business-consultation-fee-payment-form.json +++ b/data/templates/business-consultation-fee-payment-form.json @@ -1,5 +1,7 @@ { "id": "73b384ca-0131-42c0-a5f9-80b9b3e0c87b", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "business-operations" ], "keywords": [ "consultation", "consultant", "business", "fee", "payment" ], diff --git a/data/templates/business-development-coaching-services-form.json b/data/templates/business-development-coaching-services-form.json index eb965993..8062cf1d 100644 --- a/data/templates/business-development-coaching-services-form.json +++ b/data/templates/business-development-coaching-services-form.json @@ -1,5 +1,7 @@ { "id": "d69466c3-d3b6-4933-b1f8-fb3f92c003c9", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "products-services" ], "keywords": [ "on-site", "payment", "business", "service" ], diff --git a/data/templates/candle-making-class-registration-form.json b/data/templates/candle-making-class-registration-form.json index 3cb3b322..331a6e49 100644 --- a/data/templates/candle-making-class-registration-form.json +++ b/data/templates/candle-making-class-registration-form.json @@ -1,5 +1,7 @@ { "id": "8124a819-ff7f-43b3-bf8d-4939956403bd", + "created_at": "2022-12-15 00:00:00", + "updated_at": "2022-12-15 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "registrations" ], "keywords": [ "candle", "educational", "payment", "register" ], diff --git a/data/templates/car-driver-service-payment-form.json b/data/templates/car-driver-service-payment-form.json index 6a96ce28..bc527d1b 100644 --- a/data/templates/car-driver-service-payment-form.json +++ b/data/templates/car-driver-service-payment-form.json @@ -1,5 +1,7 @@ { "id": "7c350bda-0914-482c-93a6-c403ca8a965a", + "created_at": "2022-12-15 00:00:00", + "updated_at": "2022-12-15 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "products-services" ], "keywords": [ "on-site", "payment", "driver", "service" ], diff --git a/data/templates/cheese-making-class-registration-form.json b/data/templates/cheese-making-class-registration-form.json index bc52db17..ea285b6c 100644 --- a/data/templates/cheese-making-class-registration-form.json +++ b/data/templates/cheese-making-class-registration-form.json @@ -1,5 +1,7 @@ { "id": "0bd31b12-df17-473a-b056-85333908762f", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "registrations" ], "keywords": [ "payment", "class", "register", "educational" ], diff --git a/data/templates/church-tithing-form.json b/data/templates/church-tithing-form.json index e1bf0fa5..49152f8b 100644 --- a/data/templates/church-tithing-form.json +++ b/data/templates/church-tithing-form.json @@ -1,5 +1,7 @@ { "id": "87d4bfd1-f354-4e21-a7cf-3abb5a60bd19", + "created_at": "2022-12-15 00:00:00", + "updated_at": "2022-12-15 00:00:00", "license": [ "plus", "professional", "ultimate", "elite" ], "categories": [ "donations" ], "keywords": [ "church", "donate", "donation", "tithing" ], diff --git a/data/templates/city-government-fees-payment-form.json b/data/templates/city-government-fees-payment-form.json index 086a3834..30553dee 100644 --- a/data/templates/city-government-fees-payment-form.json +++ b/data/templates/city-government-fees-payment-form.json @@ -1,5 +1,7 @@ { "id": "0040c6eb-ee27-4706-8b44-46c2f37b9595", + "created_at": "2022-12-15 00:00:00", + "updated_at": "2022-12-15 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "business-operations" ], "keywords": [ "on-site", "city government", "utilities", "fee", "payment" ], diff --git a/data/templates/cleaning-service-payment-form.json b/data/templates/cleaning-service-payment-form.json index 998a3be6..552db5a2 100644 --- a/data/templates/cleaning-service-payment-form.json +++ b/data/templates/cleaning-service-payment-form.json @@ -1,5 +1,7 @@ { "id": "eb2e5b6a-3a08-4757-b9e8-49076518b9f3", + "created_at": "2022-12-15 00:00:00", + "updated_at": "2022-12-15 00:00:00", "license": [ "plus", "professional", "ultimate", "elite" ], "categories": [ "products-services" ], "keywords": [ "on-site", "cleaning", "recurring", "service" ], diff --git a/data/templates/cleaning-service-subscription-form.json b/data/templates/cleaning-service-subscription-form.json index f4c9cc94..d91a6843 100644 --- a/data/templates/cleaning-service-subscription-form.json +++ b/data/templates/cleaning-service-subscription-form.json @@ -1,8 +1,10 @@ { "id": "9fad2944-b52a-48aa-a1d4-d318892d2996", + "created_at": "2022-12-15 00:00:00", + "updated_at": "2022-12-15 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "products-services" ], - "keywords": [ "on-site", "cleaning","service", "subscription" ], + "keywords": [ "on-site", "cleaning", "service", "subscription" ], "slug": "cleaning-service-subscription-form", "name": "Cleaning Service Subscription Form", "description": "Collect recurring payment for a cleaning service subscription.", diff --git a/data/templates/college-tuition-fundraising-form.json b/data/templates/college-tuition-fundraising-form.json index 7a242d21..729fd837 100644 --- a/data/templates/college-tuition-fundraising-form.json +++ b/data/templates/college-tuition-fundraising-form.json @@ -1,5 +1,7 @@ { "id": "cc00eda0-d2eb-4109-a578-668cbf3f6b04", + "created_at": "2022-12-15 00:00:00", + "updated_at": "2022-12-15 00:00:00", "license": [ "plus", "professional", "ultimate", "elite" ], "categories": [ "fundraising" ], "keywords": [ "college", "donate", "donation", "tuition", "fundraising" ], diff --git a/data/templates/coupon-code-payment-form.json b/data/templates/coupon-code-payment-form.json index 6e0d16dc..ef40d675 100644 --- a/data/templates/coupon-code-payment-form.json +++ b/data/templates/coupon-code-payment-form.json @@ -1,5 +1,7 @@ { "id": "5201e546-8de6-42dc-9e5f-d3cc51813fa2", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ "on-site", "coupon", "discount" ], diff --git a/data/templates/credit-card-payment-form.json b/data/templates/credit-card-payment-form.json index 4c21d44e..6a78a301 100644 --- a/data/templates/credit-card-payment-form.json +++ b/data/templates/credit-card-payment-form.json @@ -1,5 +1,7 @@ { "id": "38fed248-3210-4c5a-baf4-189e2bd30145", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ "on-site" ], diff --git a/data/templates/custom-fields-payment-form.json b/data/templates/custom-fields-payment-form.json index 2cc0e72a..4f0357a1 100644 --- a/data/templates/custom-fields-payment-form.json +++ b/data/templates/custom-fields-payment-form.json @@ -1,5 +1,7 @@ { "id": "e4a9378e-a7cf-463f-a6f0-f63aed94437c", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ "on-site" ], diff --git a/data/templates/dance-lesson-payment-form.json b/data/templates/dance-lesson-payment-form.json index 22713980..e24dc7d8 100644 --- a/data/templates/dance-lesson-payment-form.json +++ b/data/templates/dance-lesson-payment-form.json @@ -1,5 +1,7 @@ { "id": "4a970e44-c839-4ae4-89f3-8f23189cae13", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "products-services" ], "keywords": [ "dance", "payment", "coach", "lesson" ], diff --git a/data/templates/disaster-recovery-donation-form.json b/data/templates/disaster-recovery-donation-form.json index b9e7d91e..8f04e22a 100644 --- a/data/templates/disaster-recovery-donation-form.json +++ b/data/templates/disaster-recovery-donation-form.json @@ -1,5 +1,7 @@ { "id": "d39ee544-c070-4c38-b3c5-3c7e346b1caf", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "donations" ], "keywords": [ "disaster", "donate", "donation", "environment", "recovery" ], diff --git a/data/templates/disaster-relief-fundraising-form.json b/data/templates/disaster-relief-fundraising-form.json index 514c2353..5a873838 100644 --- a/data/templates/disaster-relief-fundraising-form.json +++ b/data/templates/disaster-relief-fundraising-form.json @@ -1,5 +1,7 @@ { "id": "a2894c7e-24a6-4cb3-ba88-9a1b0330d838", + "created_at": "2022-12-15 00:00:00", + "updated_at": "2022-12-15 00:00:00", "license": [ "plus", "professional", "ultimate", "elite" ], "categories": [ "fundraising" ], "keywords": [ "disaster", "donate", "donation", "fundraising" ], diff --git a/data/templates/fun-run-registration-form.json b/data/templates/fun-run-registration-form.json index 64771aad..c570b1dc 100644 --- a/data/templates/fun-run-registration-form.json +++ b/data/templates/fun-run-registration-form.json @@ -1,5 +1,7 @@ { "id": "c64d2d63-9ebb-47ce-8889-4751f62ed3cb", + "created_at": "2022-12-15 00:00:00", + "updated_at": "2022-12-15 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "registrations" ], "keywords": [ "payment", "register", "fun run", "event" ], diff --git a/data/templates/gaming-tournament-registration-form.json b/data/templates/gaming-tournament-registration-form.json index 8b934085..402605da 100644 --- a/data/templates/gaming-tournament-registration-form.json +++ b/data/templates/gaming-tournament-registration-form.json @@ -1,5 +1,7 @@ { "id": "f380fb47-4243-4828-9870-e25b625f4b42", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "registrations" ], "keywords": [ "payment", "gaming", "register", "tournament" ], diff --git a/data/templates/giropay-payment-form.json b/data/templates/giropay-payment-form.json index 0ef5f420..a3647d95 100644 --- a/data/templates/giropay-payment-form.json +++ b/data/templates/giropay-payment-form.json @@ -1,5 +1,7 @@ { "id": "c2a3a4ec-d9ef-4108-b474-d5c6854e50a4", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ "on-site", "giropay", "germany" ], diff --git a/data/templates/golf-lesson-payment-form.json b/data/templates/golf-lesson-payment-form.json index 9dc14f64..d64eed5a 100644 --- a/data/templates/golf-lesson-payment-form.json +++ b/data/templates/golf-lesson-payment-form.json @@ -1,5 +1,7 @@ { "id": "29218b18-b74b-4146-9aa8-54c8596b697a", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "products-services" ], "keywords": [ "golf", "payment", "coach", "lesson" ], diff --git a/data/templates/golf-tournament-registration-form.json b/data/templates/golf-tournament-registration-form.json index 87b1d6d7..7dd276de 100644 --- a/data/templates/golf-tournament-registration-form.json +++ b/data/templates/golf-tournament-registration-form.json @@ -1,5 +1,7 @@ { "id": "19947fc7-b677-48ad-9368-e75fe0f5b11b", + "created_at": "2022-12-15 00:00:00", + "updated_at": "2022-12-15 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "registrations" ], "keywords": [ "payment", "register", "golf", "tournament" ], diff --git a/data/templates/ideal-payment-form.json b/data/templates/ideal-payment-form.json index 65a14cdf..26903910 100644 --- a/data/templates/ideal-payment-form.json +++ b/data/templates/ideal-payment-form.json @@ -1,5 +1,7 @@ { "id": "0d3c6e32-2862-45a0-8998-d6a567c5ec41", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ "on-site", "ideal", "eur" ], diff --git a/data/templates/invoice-reconciliation-payment-form.json b/data/templates/invoice-reconciliation-payment-form.json index 2a3e9562..22b67da3 100644 --- a/data/templates/invoice-reconciliation-payment-form.json +++ b/data/templates/invoice-reconciliation-payment-form.json @@ -1,5 +1,7 @@ { "id": "1b9c32fb-2e7f-4663-a3d1-e0ee01b18ec8", + "created_at": "2022-12-15 00:00:00", + "updated_at": "2022-12-15 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "business-operations" ], "keywords": [ "on-site", "invoice", "business", "fee", "payment" ], diff --git a/data/templates/klarna-payment-form.json b/data/templates/klarna-payment-form.json index 59062f84..f23995e7 100644 --- a/data/templates/klarna-payment-form.json +++ b/data/templates/klarna-payment-form.json @@ -1,5 +1,7 @@ { "id": "a0668a50-8b04-4231-8bf5-54264cf7030a", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ "buy now", "pay later", "on-site" ], diff --git a/data/templates/landscaping-service-payment-form.json b/data/templates/landscaping-service-payment-form.json index 8692fefe..db70e236 100644 --- a/data/templates/landscaping-service-payment-form.json +++ b/data/templates/landscaping-service-payment-form.json @@ -1,5 +1,7 @@ { "id": "5b63d2ee-b7bc-4242-991c-b9d54a514134", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "products-services" ], "keywords": [ "on-site", "payment", "landscaping", "service" ], diff --git a/data/templates/landscaping-service-subscription-form.json b/data/templates/landscaping-service-subscription-form.json index aaf79e69..b5383741 100644 --- a/data/templates/landscaping-service-subscription-form.json +++ b/data/templates/landscaping-service-subscription-form.json @@ -1,5 +1,7 @@ { "id": "8fe5adce-6960-4a36-9cd9-a600426fee50", + "created_at": "2022-12-15 00:00:00", + "updated_at": "2022-12-15 00:00:00", "license": [ "plus", "professional", "ultimate", "elite" ], "categories": [ "products-services" ], "keywords": [ "on-site", "susbcription", "landscaping", "service" ], diff --git a/data/templates/laundry-service-payment-form.json b/data/templates/laundry-service-payment-form.json index d75cb992..eb37c34e 100644 --- a/data/templates/laundry-service-payment-form.json +++ b/data/templates/laundry-service-payment-form.json @@ -1,5 +1,7 @@ { "id": "dde096b5-dc2e-41a4-a2c0-abda22b08d19", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "products-services" ], "keywords": [ "on-site", "susbcription", "laundry", "service" ], diff --git a/data/templates/life-coaching-webinar-registration-form.json b/data/templates/life-coaching-webinar-registration-form.json index 0cf29e85..9802ef0c 100644 --- a/data/templates/life-coaching-webinar-registration-form.json +++ b/data/templates/life-coaching-webinar-registration-form.json @@ -1,5 +1,7 @@ { "id": "5e9aa4d0-c13e-49aa-93e1-33ea7e4bde90", + "created_at": "2022-12-15 00:00:00", + "updated_at": "2022-12-15 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "registrations" ], "keywords": [ "payment", "register", "webinar", "life coach" ], diff --git a/data/templates/marathon-run-registration-form.json b/data/templates/marathon-run-registration-form.json index 74392047..f6aec04b 100644 --- a/data/templates/marathon-run-registration-form.json +++ b/data/templates/marathon-run-registration-form.json @@ -1,5 +1,7 @@ { "id": "21373c41-4e3f-46f7-b36e-90d0b6988985", + "created_at": "2022-12-15 00:00:00", + "updated_at": "2022-12-15 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "registrations" ], "keywords": [ "payment", "register", "marathon", "event" ], diff --git a/data/templates/martial-arts-lesson-payment-form.json b/data/templates/martial-arts-lesson-payment-form.json index ca3a9b37..923d15aa 100644 --- a/data/templates/martial-arts-lesson-payment-form.json +++ b/data/templates/martial-arts-lesson-payment-form.json @@ -1,5 +1,7 @@ { "id": "78c35bf8-a741-4f93-84ac-ee09e2cc6c30", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "products-services" ], "keywords": [ "martial-arts", "payment", "coach", "lesson" ], diff --git a/data/templates/medical-expense-fundraising-form.json b/data/templates/medical-expense-fundraising-form.json index 96dd992c..5925e1e5 100644 --- a/data/templates/medical-expense-fundraising-form.json +++ b/data/templates/medical-expense-fundraising-form.json @@ -1,5 +1,7 @@ { "id": "b2a99251-bb26-4da3-846d-70fe9e896da1", + "created_at": "2022-12-15 00:00:00", + "updated_at": "2022-12-15 00:00:00", "license": [ "plus", "professional", "ultimate", "elite" ], "categories": [ "fundraising" ], "keywords": [ "fundraising", "donate", "donation", "medical" ], diff --git a/data/templates/mission-trip-fundraising-form.json b/data/templates/mission-trip-fundraising-form.json index 37a6d109..c9f24eee 100644 --- a/data/templates/mission-trip-fundraising-form.json +++ b/data/templates/mission-trip-fundraising-form.json @@ -1,5 +1,7 @@ { "id": "62cc07dc-9de4-407b-bf19-a7d789899744", + "created_at": "2022-12-15 00:00:00", + "updated_at": "2022-12-15 00:00:00", "license": [ "plus", "professional", "ultimate", "elite" ], "categories": [ "fundraising" ], "keywords": [ "church", "donate", "fundraising", "mission trip" ], diff --git a/data/templates/monthly-rent-payment-form.json b/data/templates/monthly-rent-payment-form.json index f71c740c..cd82ee72 100644 --- a/data/templates/monthly-rent-payment-form.json +++ b/data/templates/monthly-rent-payment-form.json @@ -1,5 +1,7 @@ { "id": "681c0663-39e8-4bfb-8d23-bd5a1a52253c", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "business-operations" ], "keywords": [ "on-site", "rent", "business", "tenant", "payment" ], diff --git a/data/templates/multiple-payment-methods-form.json b/data/templates/multiple-payment-methods-form.json index cea5af35..25cc8a0f 100644 --- a/data/templates/multiple-payment-methods-form.json +++ b/data/templates/multiple-payment-methods-form.json @@ -1,5 +1,7 @@ { "id": "4fc0a259-3fe4-4849-9f19-1e90e384e65c", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ diff --git a/data/templates/neighborhood-watch-donation-form.json b/data/templates/neighborhood-watch-donation-form.json index 9f77f4f6..096ac315 100644 --- a/data/templates/neighborhood-watch-donation-form.json +++ b/data/templates/neighborhood-watch-donation-form.json @@ -1,5 +1,7 @@ { "id": "80aab0a0-58fc-4c1d-80b3-cbfb1b08f3a5", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "plus", "professional", "ultimate", "elite" ], "categories": [ "donations" ], "keywords": [ "neighborhood", "donate", "donation", "watch" ], diff --git a/data/templates/one-time-custom-amount-form.json b/data/templates/one-time-custom-amount-form.json index fccc7f92..1297abfa 100644 --- a/data/templates/one-time-custom-amount-form.json +++ b/data/templates/one-time-custom-amount-form.json @@ -1,5 +1,7 @@ { "id": "62a2605b-e62b-4372-b142-3b23be117f3c", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ "on-site" ], diff --git a/data/templates/opt-in-subscription-form.json b/data/templates/opt-in-subscription-form.json index e5ab74a9..009c4831 100644 --- a/data/templates/opt-in-subscription-form.json +++ b/data/templates/opt-in-subscription-form.json @@ -1,5 +1,7 @@ { "id": "0ed465fa-85a7-4b9f-b7f1-c38d647e5248", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "plus", "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ "subscription", "opt-in", "checkbox" ], diff --git a/data/templates/overlay-payment-form.json b/data/templates/overlay-payment-form.json index a852c0cb..eaccf025 100644 --- a/data/templates/overlay-payment-form.json +++ b/data/templates/overlay-payment-form.json @@ -1,5 +1,7 @@ { "id": "877d75be-f2d8-4fac-b124-6d59e40c5457", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ "on-site" ], diff --git a/data/templates/pesticide-service-subscription-form.json b/data/templates/pesticide-service-subscription-form.json index 392d9b8b..b2609161 100644 --- a/data/templates/pesticide-service-subscription-form.json +++ b/data/templates/pesticide-service-subscription-form.json @@ -1,5 +1,7 @@ { "id": "7672379e-d2a8-4590-9432-603d243c89c1", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "plus", "professional", "ultimate", "elite" ], "categories": [ "products-services" ], "keywords": [ "on-site", "recurring", "pest control", "service" ], diff --git a/data/templates/political-campaign-donation-form.json b/data/templates/political-campaign-donation-form.json index 8ab50f77..f68fab3d 100644 --- a/data/templates/political-campaign-donation-form.json +++ b/data/templates/political-campaign-donation-form.json @@ -1,5 +1,7 @@ { "id": "830c0468-1510-4043-8222-eed1c534c8ce", + "created_at": "2022-12-15 00:00:00", + "updated_at": "2022-12-15 00:00:00", "license": [ "plus", "professional", "ultimate", "elite" ], "categories": [ "donations" ], "keywords": [ "politics", "donate", "donation", "campaign" ], diff --git a/data/templates/pool-cleaning-service-payment-form.json b/data/templates/pool-cleaning-service-payment-form.json index 74bfbbfc..5bba01f9 100644 --- a/data/templates/pool-cleaning-service-payment-form.json +++ b/data/templates/pool-cleaning-service-payment-form.json @@ -1,5 +1,7 @@ { "id": "b796f627-e2eb-41dd-8b14-1e2c5e80ae95", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "products-services" ], "keywords": [ "on-site", "payment", "pool cleaning", "service" ], diff --git a/data/templates/pool-cleaning-service-subscription-form.json b/data/templates/pool-cleaning-service-subscription-form.json index 2712c57f..5b1566da 100644 --- a/data/templates/pool-cleaning-service-subscription-form.json +++ b/data/templates/pool-cleaning-service-subscription-form.json @@ -1,5 +1,7 @@ { "id": "0175921c-eb6a-474b-8190-a719ff08979e", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "plus", "professional", "ultimate", "elite" ], "categories": [ "products-services" ], "keywords": [ "on-site", "susbcription", "pool cleaning", "service" ], diff --git a/data/templates/product-installment-plan-form.json b/data/templates/product-installment-plan-form.json index 8a8a75c5..7ce5803a 100644 --- a/data/templates/product-installment-plan-form.json +++ b/data/templates/product-installment-plan-form.json @@ -1,5 +1,7 @@ { "id": "05387fec-8a7d-423e-8a5d-04e94af41111", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "plus", "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ "installment", "service", "subscription" ], diff --git a/data/templates/product-purchase-form.json b/data/templates/product-purchase-form.json index e9708f93..304f8870 100644 --- a/data/templates/product-purchase-form.json +++ b/data/templates/product-purchase-form.json @@ -1,5 +1,7 @@ { "id": "c37fc67b-5f6c-4c49-9900-ff066fccf50b", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ "variable", "options" ], diff --git a/data/templates/product-subscription-form-coupon.json b/data/templates/product-subscription-form-coupon.json index d7f13000..fa4c3578 100644 --- a/data/templates/product-subscription-form-coupon.json +++ b/data/templates/product-subscription-form-coupon.json @@ -1,5 +1,7 @@ { "id": "9c99931b-599b-471f-b39d-2607c8283c19", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "plus", "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ "subscription", "coupon", "discount" ], diff --git a/data/templates/product-subscription-form.json b/data/templates/product-subscription-form.json index 77d7e205..b1c327ab 100644 --- a/data/templates/product-subscription-form.json +++ b/data/templates/product-subscription-form.json @@ -1,5 +1,7 @@ { "id": "546ec148-fcec-4156-99cb-bb3547db7c4d", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "plus", "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ "subscription" ], diff --git a/data/templates/przelewy24-payment-form.json b/data/templates/przelewy24-payment-form.json index c3e60ab7..3286f7cf 100644 --- a/data/templates/przelewy24-payment-form.json +++ b/data/templates/przelewy24-payment-form.json @@ -1,5 +1,7 @@ { "id": "5854a5f2-8dcb-4270-9dc5-09f8c2b77170", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ "on-site", "przelewy24", "poland" ], diff --git a/data/templates/pub-crawl-registration-form.json b/data/templates/pub-crawl-registration-form.json index 314a6a8b..11511a2e 100644 --- a/data/templates/pub-crawl-registration-form.json +++ b/data/templates/pub-crawl-registration-form.json @@ -1,5 +1,7 @@ { "id": "272e5b2c-6f86-42c0-ab06-6261d0b92c98", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "registrations" ], "keywords": [ "payment", "register", "pub crawl", "event" ], diff --git a/data/templates/quantities-payment-form.json b/data/templates/quantities-payment-form.json index 92c5ff2d..ea60e979 100644 --- a/data/templates/quantities-payment-form.json +++ b/data/templates/quantities-payment-form.json @@ -1,5 +1,7 @@ { "id": "df9ba8be-8823-46b2-b022-65a7d33ac503", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ "on-site", "quantity" ], diff --git a/data/templates/recurring-service-setup-fee-form.json b/data/templates/recurring-service-setup-fee-form.json index b9892817..c64390cb 100644 --- a/data/templates/recurring-service-setup-fee-form.json +++ b/data/templates/recurring-service-setup-fee-form.json @@ -1,5 +1,7 @@ { "id": "03a82a3c-f9bd-42c2-92e9-e48b7f827c46", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "plus", "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ "fee", "setup", "service", "subscription" ], diff --git a/data/templates/recurring-service-trial-period-form.json b/data/templates/recurring-service-trial-period-form.json index fa02480d..89685003 100644 --- a/data/templates/recurring-service-trial-period-form.json +++ b/data/templates/recurring-service-trial-period-form.json @@ -1,5 +1,7 @@ { "id": "df64055c-3fdc-43d4-bc4c-f58e232160e6", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "plus", "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ "trial", "free", "service", "subscription" ], diff --git a/data/templates/recurring-services-form.json b/data/templates/recurring-services-form.json index b9088501..f1d9c98e 100644 --- a/data/templates/recurring-services-form.json +++ b/data/templates/recurring-services-form.json @@ -1,5 +1,7 @@ { "id": "02ff50b2-f55d-4dbe-b274-e265338f9bcc", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "plus", "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ "service", "subscription" ], diff --git a/data/templates/school-book-club-fundraising-form.json b/data/templates/school-book-club-fundraising-form.json index 18b70cc9..317a6957 100644 --- a/data/templates/school-book-club-fundraising-form.json +++ b/data/templates/school-book-club-fundraising-form.json @@ -1,5 +1,7 @@ { "id": "df2362af-781e-4aa8-a9ae-81637a10054e", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "plus", "professional", "ultimate", "elite" ], "categories": [ "fundraising" ], "keywords": [ "club", "donate", "donation", "fundraising", "book club" ], diff --git a/data/templates/school-excursion-fundraising-form.json b/data/templates/school-excursion-fundraising-form.json index b325c9fa..5cf99edf 100644 --- a/data/templates/school-excursion-fundraising-form.json +++ b/data/templates/school-excursion-fundraising-form.json @@ -1,8 +1,16 @@ { "id": "903660a3-5b0e-4082-9872-1fdea1387032", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "plus", "professional", "ultimate", "elite" ], "categories": [ "fundraising" ], - "keywords": [ "school", "donate", "donation", "fundraising", "school trip" ], + "keywords": [ + "school", + "donate", + "donation", + "fundraising", + "school trip" + ], "slug": "school-excursion-fundraising-form", "name": "School Excursion Fundraising Form", "description": "Crowdsource donations to enusre that all students may participate in school trips.", diff --git a/data/templates/school-supplies-donation-form.json b/data/templates/school-supplies-donation-form.json index baa483c6..ee558ad7 100644 --- a/data/templates/school-supplies-donation-form.json +++ b/data/templates/school-supplies-donation-form.json @@ -1,5 +1,7 @@ { "id": "3adfe219-01bc-463f-b481-2d0dab578fd7", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "plus", "professional", "ultimate", "elite" ], "categories": [ "donations" ], "keywords": [ "school", "donate", "donation", "supplies", "teacher" ], diff --git a/data/templates/sepa-direct-debit-form.json b/data/templates/sepa-direct-debit-form.json index 474da608..53602936 100644 --- a/data/templates/sepa-direct-debit-form.json +++ b/data/templates/sepa-direct-debit-form.json @@ -1,5 +1,7 @@ { "id": "378765dc-9691-4155-91ca-1de02b6ed0b1", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ "sepa", "debit", "on-site" ], diff --git a/data/templates/soccer-club-registration-form.json b/data/templates/soccer-club-registration-form.json index 12767c5a..73c99117 100644 --- a/data/templates/soccer-club-registration-form.json +++ b/data/templates/soccer-club-registration-form.json @@ -1,8 +1,10 @@ { "id": "ed029780-bbea-4599-bdb3-d4b929831483", + "created_at": "2022-12-15 00:00:00", + "updated_at": "2022-12-15 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "registrations" ], - "keywords": [ "soccer","payment", "sports", "register" ], + "keywords": [ "soccer", "payment", "sports", "register" ], "slug": "soccer-club-registration-form", "name": "Soccer Club Registration Form", "description": "Gather team information and collect a payment for a soccer club registration.", diff --git a/data/templates/soccer-lesson-payment-form.json b/data/templates/soccer-lesson-payment-form.json index 3e24eb33..fe8b6319 100644 --- a/data/templates/soccer-lesson-payment-form.json +++ b/data/templates/soccer-lesson-payment-form.json @@ -1,5 +1,7 @@ { "id": "e5960e3f-4072-4828-a219-d8bd073a285c", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "products-services" ], "keywords": [ "soccer", "payment", "coach", "lesson" ], diff --git a/data/templates/subscription-custom-amount-form.json b/data/templates/subscription-custom-amount-form.json index 7181f8d0..b94f5d72 100644 --- a/data/templates/subscription-custom-amount-form.json +++ b/data/templates/subscription-custom-amount-form.json @@ -1,5 +1,7 @@ { "id": "ae95db8c-d69f-4e3f-9a5f-59795e7800fe", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "plus", "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ "on-site" ], diff --git a/data/templates/subscription-payment-form.json b/data/templates/subscription-payment-form.json index 0a0eadb0..69a51dd9 100644 --- a/data/templates/subscription-payment-form.json +++ b/data/templates/subscription-payment-form.json @@ -1,5 +1,7 @@ { "id": "dde0de95-33c5-4320-b312-807d66b85f0f", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "plus", "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ "on-site" ], diff --git a/data/templates/subscription-setup-fee-form.json b/data/templates/subscription-setup-fee-form.json index e4420bef..b3ebf11e 100644 --- a/data/templates/subscription-setup-fee-form.json +++ b/data/templates/subscription-setup-fee-form.json @@ -1,5 +1,7 @@ { "id": "23afba6d-d85a-479b-96db-cb794b99684b", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "plus", "professional", "ultimate", "elite" ], "categories": [ "features-functionality" ], "keywords": [ "on-site" ], diff --git a/data/templates/tuition-fees-payment-form.json b/data/templates/tuition-fees-payment-form.json index a942671e..06715338 100644 --- a/data/templates/tuition-fees-payment-form.json +++ b/data/templates/tuition-fees-payment-form.json @@ -1,5 +1,7 @@ { "id": "575db34e-34da-4ee9-9b84-c62df1510bef", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "business-operations" ], "keywords": [ "on-site", "tuition", "education", "fee", "payment" ], diff --git a/data/templates/twitch-streamer-donation-form.json b/data/templates/twitch-streamer-donation-form.json index 29a71bc5..eca05f05 100644 --- a/data/templates/twitch-streamer-donation-form.json +++ b/data/templates/twitch-streamer-donation-form.json @@ -1,5 +1,7 @@ { "id": "7fb25f8e-2825-43b7-95cd-5c66aba91ad3", + "created_at": "2022-12-15 00:00:00", + "updated_at": "2022-12-15 00:00:00", "license": [ "plus", "professional", "ultimate", "elite" ], "categories": [ "donations" ], "keywords": [ "twitch", "donate", "donation", "streamer" ], diff --git a/data/templates/web-development-services-form.json b/data/templates/web-development-services-form.json index 2f045632..ebd0ca7b 100644 --- a/data/templates/web-development-services-form.json +++ b/data/templates/web-development-services-form.json @@ -1,5 +1,7 @@ { "id": "323bc6d4-abfc-4123-b951-e6bf1719a370", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "personal", "plus", "professional", "ultimate", "elite" ], "categories": [ "products-services" ], "keywords": [ "on-site", "susbcription", "development", "service" ], diff --git a/data/templates/web-hosting-service-subscription-form.json b/data/templates/web-hosting-service-subscription-form.json index 5dcfeceb..62e87389 100644 --- a/data/templates/web-hosting-service-subscription-form.json +++ b/data/templates/web-hosting-service-subscription-form.json @@ -1,5 +1,7 @@ { "id": "d7d2aa4b-35bc-4d8b-92b1-cb92a6f2d4f4", + "created_at": "2022-11-01 00:00:00", + "updated_at": "2022-11-01 00:00:00", "license": [ "plus", "professional", "ultimate", "elite" ], "categories": [ "products-services" ], "keywords": [ "on-site", "susbcription", "hosting", "service" ], diff --git a/data/templates/youtube-streamer-donation-form.json b/data/templates/youtube-streamer-donation-form.json index 7c5e01a8..8a7c1fc7 100644 --- a/data/templates/youtube-streamer-donation-form.json +++ b/data/templates/youtube-streamer-donation-form.json @@ -1,5 +1,7 @@ { "id": "7df18342-e7bc-42f7-9652-ce250bc83c15", + "created_at": "2022-12-15 00:00:00", + "updated_at": "2022-12-15 00:00:00", "license": [ "plus", "professional", "ultimate", "elite" ], "categories": [ "donations" ], "keywords": [ "youtube", "donate", "donation", "streamer" ], diff --git a/includes/core/assets/css/admin/all-pages.scss b/includes/core/assets/css/admin/all-pages.scss index b4b0825e..f707ada3 100644 --- a/includes/core/assets/css/admin/all-pages.scss +++ b/includes/core/assets/css/admin/all-pages.scss @@ -259,3 +259,14 @@ #adminmenu a[href*="page=simpay-setup-wizard"] { display: none; } + +/** + * Style "New!" menu text. + */ +#adminmenu .simpay-menu-new { + color: #f18500; + vertical-align: super; + font-size: 9px; + font-weight: 600; + padding-left: 2px; +} diff --git a/includes/core/assets/css/admin/form-template-explorer.scss b/includes/core/assets/css/admin/form-template-explorer.scss index 201f2620..66a3f240 100644 --- a/includes/core/assets/css/admin/form-template-explorer.scss +++ b/includes/core/assets/css/admin/form-template-explorer.scss @@ -135,26 +135,27 @@ body.simpay-template-explorer-open { .simpay-form-template-explorer-header { @include break-huge() { + margin-right: $grid-unit-30; + padding: 30px 30px 25px; + width: 100%; + background: #fff; + border-bottom: 1px solid #c3c4c7; + box-shadow: 0 1px 1px rgba(0, 0, 0, 0.04); position: absolute; left: 0; right: 0; - padding: $grid-unit-30 0 $grid-unit-30 $grid-unit-30; - margin-right: $grid-unit-30; - height: 100px; - background: #fff; - z-index: 2; + z-index: 3; } &__title { - font-size: 22px; - font-weight: 400; + font-size: 26px; margin: 0; } &__subtitle { color: #555; font-size: 15px; - margin: $grid-unit-10 0 0; + margin: $grid-unit-20 0 0; } } @@ -185,6 +186,10 @@ body.simpay-template-explorer-open { background-color: var(--wp-admin-theme-color); } } + + &-categories_category.category-new { + font-weight: bold; + } } &__content { @@ -329,13 +334,41 @@ body.simpay-template-explorer-open { font-size: 14px; } } + + &-upgrade { + color: #1d2327; + padding: $grid-unit-40; + grid-column: 1 / -1; + display: flex; + align-items: center; + justify-content: space-between; + background: #fafcfe; + border: 1px solid #dce9f6; + border-radius: 4px; + box-shadow: 0 1px 3px rgba(66, 139, 202, 0.08); + + > div { + margin-right: 50px; + } + + h4 { + font-size: 18px; + margin: 0; + } + + p { + color: #555; + font-size: 14px; + margin: $grid-unit-10 0 0; + } + } } @include break-huge() { - margin-top: 100px; + margin-top: 130px; &__sidebar { - top: 100px; + top: 130px; bottom: 0; left: $grid-unit-30; overflow-x: hidden; diff --git a/includes/core/assets/css/simpay-admin-all-pages.min.css b/includes/core/assets/css/simpay-admin-all-pages.min.css index c254beb9..9552acd1 100644 --- a/includes/core/assets/css/simpay-admin-all-pages.min.css +++ b/includes/core/assets/css/simpay-admin-all-pages.min.css @@ -1,3 +1,3 @@ -.simpay-test-mode-badge-container .simpay-test-mode-badge{color:#a04903;text-align:center;text-transform:uppercase;font-size:10px;line-height:10px;font-weight:700;padding:5px 7px;border-radius:3px;background:#ffde92;display:inline-flex;align-items:center}.simpay-external-link .dashicons{opacity:.8;font-size:16px;margin:3px 0 0 2px;width:16px;height:16px;text-decoration:none}.simpay-external-link:hover .dashicons{opacity:1}.simpay-settings-bubble{display:inline-block;vertical-align:top;box-sizing:border-box;margin:1px 0 -1px 5px;padding:0 5px;min-width:18px;height:18px;border-radius:9px;background-color:#d63638;color:#fff;font-size:11px;line-height:1.6;text-align:center;z-index:26;position:relative}.simpay-settings-bubble:empty{width:10px;height:10px;min-width:10px}.nav-tab .simpay-settings-bubble:empty{margin-top:7px}@-webkit-keyframes simpay-pulse{0%{transform:scale(0.95);box-shadow:0 0 0 0 rgba(214,54,56,.65)}100%{transform:scale(1);box-shadow:0 0 0 8px rgba(214,54,56,0)}}@keyframes simpay-pulse{0%{transform:scale(0.95);box-shadow:0 0 0 0 rgba(214,54,56,.65)}100%{transform:scale(1);box-shadow:0 0 0 8px rgba(214,54,56,0)}}#adminmenu .simpay-admin-menu-notification-indicator{display:inline-block;margin-top:6px;width:8px;height:8px;background-color:#d63638;border-radius:50%;float:right;-webkit-animation:simpay-pulse 2s infinite;animation:simpay-pulse 2s infinite}#adminmenu a[href^="https://wpsimplepay.com/lite-vs-pro"]:not(.simpay-upgrade-btn){color:#fff;background-color:#347d39 !important}#adminmenu a[href^="https://wpsimplepay.com/lite-vs-pro"]:not(.simpay-upgrade-btn):hover{color:#fff !important}#adminmenu .opensub a[href^="https://wpsimplepay.com/lite-vs-pro"]:not(.simpay-upgrade-btn){margin-right:6px}.simpay-upgrade-link{color:#3db634 !important;font-weight:bold}.simpay-plugin-upgrade-notice{font-weight:400;color:#fff;background:#d54d21;padding:1em;margin:9px 0}.simpay-plugin-upgrade-notice::before{content:"";display:inline-block;font:400 18px/1 dashicons;speak:none;margin:0 8px 0 -2px;vertical-align:top}#stripe-update .updating-message .simpay-plugin-upgrade-notice{display:none}.simpay-admin-notice-top-of-page{font-size:13px;line-height:1.4;color:#fff;margin-left:-20px;padding:9px 32px 9px 20px;background:#2d6ca2;display:none}@media screen and (min-width: 783px){.simpay-admin-notice-top-of-page{padding:10px 46px 10px 22px}}@media screen and (min-width: 961px){.simpay-admin-notice-top-of-page{text-align:center}}.simpay-admin-notice-top-of-page a{color:#fff}.simpay-admin-notice-top-of-page a:hover{text-decoration:none}.simpay-admin-notice-top-of-page .button-link{position:absolute;top:48px;right:-1px;font-size:20px;color:#fff;font-weight:bold;text-decoration:none;margin-left:5px;padding:6px 10px}@media screen and (min-width: 601px){.simpay-admin-notice-top-of-page .button-link{top:0}}@media screen and (min-width: 783px){.simpay-admin-notice-top-of-page .button-link{right:9px}}.simpay-admin-notice-top-of-page .button-link:hover,.simpay-admin-notice-top-of-page .button-link:active,.simpay-admin-notice-top-of-page .button-link:focus{color:#fff;text-decoration:none}#simpay-product-education .simpay-dashboard-widget-product-education{text-align:center;padding:10px 30px}#simpay-product-education .simpay-dashboard-widget-product-education img{width:200px;margin:0 auto}#simpay-product-education .simpay-dashboard-widget-product-education h2{font-size:16px;font-weight:600;margin:0 0 -10px;padding:0;line-height:1.3}#simpay-product-education .simpay-dashboard-widget-product-education .button+.button{margin-left:5px}.simpay-admin-notice-update-plugin{display:flex;justify-content:space-between;align-items:center;padding:10px}.simpay-admin-notice-update-plugin__copy{display:flex;align-items:center;flex-grow:1}.simpay-admin-notice-update-plugin__copy img{width:150px;margin:0 15px 3px 0}.simpay-admin-notice-update-plugin~.notice-dismiss{top:11px}@media screen and (max-width: 782px){.simpay-admin-notice-update-plugin{flex-wrap:wrap}.simpay-admin-notice-update-plugin img{display:none}.simpay-admin-notice-update-plugin .button.button-primary{margin-top:10px}.simpay-admin-notice-update-plugin~.notice-dismiss{top:0}}#adminmenu a[href*="page=simpay-setup-wizard"]{display:none} +.simpay-test-mode-badge-container .simpay-test-mode-badge{color:#a04903;text-align:center;text-transform:uppercase;font-size:10px;line-height:10px;font-weight:700;padding:5px 7px;border-radius:3px;background:#ffde92;display:inline-flex;align-items:center}.simpay-external-link .dashicons{opacity:.8;font-size:16px;margin:3px 0 0 2px;width:16px;height:16px;text-decoration:none}.simpay-external-link:hover .dashicons{opacity:1}.simpay-settings-bubble{display:inline-block;vertical-align:top;box-sizing:border-box;margin:1px 0 -1px 5px;padding:0 5px;min-width:18px;height:18px;border-radius:9px;background-color:#d63638;color:#fff;font-size:11px;line-height:1.6;text-align:center;z-index:26;position:relative}.simpay-settings-bubble:empty{width:10px;height:10px;min-width:10px}.nav-tab .simpay-settings-bubble:empty{margin-top:7px}@-webkit-keyframes simpay-pulse{0%{transform:scale(0.95);box-shadow:0 0 0 0 rgba(214,54,56,.65)}100%{transform:scale(1);box-shadow:0 0 0 8px rgba(214,54,56,0)}}@keyframes simpay-pulse{0%{transform:scale(0.95);box-shadow:0 0 0 0 rgba(214,54,56,.65)}100%{transform:scale(1);box-shadow:0 0 0 8px rgba(214,54,56,0)}}#adminmenu .simpay-admin-menu-notification-indicator{display:inline-block;margin-top:6px;width:8px;height:8px;background-color:#d63638;border-radius:50%;float:right;-webkit-animation:simpay-pulse 2s infinite;animation:simpay-pulse 2s infinite}#adminmenu a[href^="https://wpsimplepay.com/lite-vs-pro"]:not(.simpay-upgrade-btn){color:#fff;background-color:#347d39 !important}#adminmenu a[href^="https://wpsimplepay.com/lite-vs-pro"]:not(.simpay-upgrade-btn):hover{color:#fff !important}#adminmenu .opensub a[href^="https://wpsimplepay.com/lite-vs-pro"]:not(.simpay-upgrade-btn){margin-right:6px}.simpay-upgrade-link{color:#3db634 !important;font-weight:bold}.simpay-plugin-upgrade-notice{font-weight:400;color:#fff;background:#d54d21;padding:1em;margin:9px 0}.simpay-plugin-upgrade-notice::before{content:"";display:inline-block;font:400 18px/1 dashicons;speak:none;margin:0 8px 0 -2px;vertical-align:top}#stripe-update .updating-message .simpay-plugin-upgrade-notice{display:none}.simpay-admin-notice-top-of-page{font-size:13px;line-height:1.4;color:#fff;margin-left:-20px;padding:9px 32px 9px 20px;background:#2d6ca2;display:none}@media screen and (min-width: 783px){.simpay-admin-notice-top-of-page{padding:10px 46px 10px 22px}}@media screen and (min-width: 961px){.simpay-admin-notice-top-of-page{text-align:center}}.simpay-admin-notice-top-of-page a{color:#fff}.simpay-admin-notice-top-of-page a:hover{text-decoration:none}.simpay-admin-notice-top-of-page .button-link{position:absolute;top:48px;right:-1px;font-size:20px;color:#fff;font-weight:bold;text-decoration:none;margin-left:5px;padding:6px 10px}@media screen and (min-width: 601px){.simpay-admin-notice-top-of-page .button-link{top:0}}@media screen and (min-width: 783px){.simpay-admin-notice-top-of-page .button-link{right:9px}}.simpay-admin-notice-top-of-page .button-link:hover,.simpay-admin-notice-top-of-page .button-link:active,.simpay-admin-notice-top-of-page .button-link:focus{color:#fff;text-decoration:none}#simpay-product-education .simpay-dashboard-widget-product-education{text-align:center;padding:10px 30px}#simpay-product-education .simpay-dashboard-widget-product-education img{width:200px;margin:0 auto}#simpay-product-education .simpay-dashboard-widget-product-education h2{font-size:16px;font-weight:600;margin:0 0 -10px;padding:0;line-height:1.3}#simpay-product-education .simpay-dashboard-widget-product-education .button+.button{margin-left:5px}.simpay-admin-notice-update-plugin{display:flex;justify-content:space-between;align-items:center;padding:10px}.simpay-admin-notice-update-plugin__copy{display:flex;align-items:center;flex-grow:1}.simpay-admin-notice-update-plugin__copy img{width:150px;margin:0 15px 3px 0}.simpay-admin-notice-update-plugin~.notice-dismiss{top:11px}@media screen and (max-width: 782px){.simpay-admin-notice-update-plugin{flex-wrap:wrap}.simpay-admin-notice-update-plugin img{display:none}.simpay-admin-notice-update-plugin .button.button-primary{margin-top:10px}.simpay-admin-notice-update-plugin~.notice-dismiss{top:0}}#adminmenu a[href*="page=simpay-setup-wizard"]{display:none}#adminmenu .simpay-menu-new{color:#f18500;vertical-align:super;font-size:9px;font-weight:600;padding-left:2px} /*# sourceMappingURL=simpay-admin-all-pages.min.css.map*/ \ No newline at end of file diff --git a/includes/core/assets/css/simpay-admin-all-pages.min.css.map b/includes/core/assets/css/simpay-admin-all-pages.min.css.map index db33e61f..bf59103c 100644 --- a/includes/core/assets/css/simpay-admin-all-pages.min.css.map +++ b/includes/core/assets/css/simpay-admin-all-pages.min.css.map @@ -1 +1 @@ -{"version":3,"sources":["webpack:///./css/admin/all-pages.scss"],"names":[],"mappings":"AAAA,0DAA0D,cAAc,kBAAkB,yBAAyB,eAAe,iBAAiB,gBAAgB,gBAAgB,kBAAkB,mBAAmB,oBAAoB,mBAAmB,iCAAiC,WAAW,eAAe,mBAAmB,WAAW,YAAY,qBAAqB,uCAAuC,UAAU,wBAAwB,qBAAqB,mBAAmB,sBAAsB,sBAAsB,cAAc,eAAe,YAAY,kBAAkB,yBAAyB,WAAW,eAAe,gBAAgB,kBAAkB,WAAW,kBAAkB,8BAA8B,WAAW,YAAY,eAAe,uCAAuC,eAAe,gCAAgC,GAAG,sBAAsB,uCAAuC,KAAK,mBAAmB,wCAAwC,wBAAwB,GAAG,sBAAsB,uCAAuC,KAAK,mBAAmB,wCAAwC,qDAAqD,qBAAqB,eAAe,UAAU,WAAW,yBAAyB,kBAAkB,YAAY,2CAA2C,mCAAmC,mFAAmF,WAAW,oCAAoC,yFAAyF,sBAAsB,4FAA4F,iBAAiB,qBAAqB,yBAAyB,iBAAiB,8BAA8B,gBAAgB,WAAW,mBAAmB,YAAY,aAAa,sCAAsC,YAAY,qBAAqB,0BAA0B,WAAW,oBAAoB,mBAAmB,+DAA+D,aAAa,iCAAiC,eAAe,gBAAgB,WAAW,kBAAkB,0BAA0B,mBAAmB,aAAa,qCAAqC,iCAAiC,6BAA6B,qCAAqC,iCAAiC,mBAAmB,mCAAmC,WAAW,yCAAyC,qBAAqB,8CAA8C,kBAAkB,SAAS,WAAW,eAAe,WAAW,iBAAiB,qBAAqB,gBAAgB,iBAAiB,qCAAqC,8CAA8C,OAAO,qCAAqC,8CAA8C,WAAW,6JAA6J,WAAW,qBAAqB,qEAAqE,kBAAkB,kBAAkB,yEAAyE,YAAY,cAAc,wEAAwE,eAAe,gBAAgB,iBAAiB,UAAU,gBAAgB,qFAAqF,gBAAgB,mCAAmC,aAAa,8BAA8B,mBAAmB,aAAa,yCAAyC,aAAa,mBAAmB,YAAY,6CAA6C,YAAY,oBAAoB,mDAAmD,SAAS,qCAAqC,mCAAmC,eAAe,uCAAuC,aAAa,0DAA0D,gBAAgB,mDAAmD,OAAO,+CAA+C,a","file":"./../css/simpay-admin-all-pages.min.css","sourcesContent":[".simpay-test-mode-badge-container .simpay-test-mode-badge{color:#a04903;text-align:center;text-transform:uppercase;font-size:10px;line-height:10px;font-weight:700;padding:5px 7px;border-radius:3px;background:#ffde92;display:inline-flex;align-items:center}.simpay-external-link .dashicons{opacity:.8;font-size:16px;margin:3px 0 0 2px;width:16px;height:16px;text-decoration:none}.simpay-external-link:hover .dashicons{opacity:1}.simpay-settings-bubble{display:inline-block;vertical-align:top;box-sizing:border-box;margin:1px 0 -1px 5px;padding:0 5px;min-width:18px;height:18px;border-radius:9px;background-color:#d63638;color:#fff;font-size:11px;line-height:1.6;text-align:center;z-index:26;position:relative}.simpay-settings-bubble:empty{width:10px;height:10px;min-width:10px}.nav-tab .simpay-settings-bubble:empty{margin-top:7px}@-webkit-keyframes simpay-pulse{0%{transform:scale(0.95);box-shadow:0 0 0 0 rgba(214,54,56,.65)}100%{transform:scale(1);box-shadow:0 0 0 8px rgba(214,54,56,0)}}@keyframes simpay-pulse{0%{transform:scale(0.95);box-shadow:0 0 0 0 rgba(214,54,56,.65)}100%{transform:scale(1);box-shadow:0 0 0 8px rgba(214,54,56,0)}}#adminmenu .simpay-admin-menu-notification-indicator{display:inline-block;margin-top:6px;width:8px;height:8px;background-color:#d63638;border-radius:50%;float:right;-webkit-animation:simpay-pulse 2s infinite;animation:simpay-pulse 2s infinite}#adminmenu a[href^=\"https://wpsimplepay.com/lite-vs-pro\"]:not(.simpay-upgrade-btn){color:#fff;background-color:#347d39 !important}#adminmenu a[href^=\"https://wpsimplepay.com/lite-vs-pro\"]:not(.simpay-upgrade-btn):hover{color:#fff !important}#adminmenu .opensub a[href^=\"https://wpsimplepay.com/lite-vs-pro\"]:not(.simpay-upgrade-btn){margin-right:6px}.simpay-upgrade-link{color:#3db634 !important;font-weight:bold}.simpay-plugin-upgrade-notice{font-weight:400;color:#fff;background:#d54d21;padding:1em;margin:9px 0}.simpay-plugin-upgrade-notice::before{content:\"\";display:inline-block;font:400 18px/1 dashicons;speak:none;margin:0 8px 0 -2px;vertical-align:top}#stripe-update .updating-message .simpay-plugin-upgrade-notice{display:none}.simpay-admin-notice-top-of-page{font-size:13px;line-height:1.4;color:#fff;margin-left:-20px;padding:9px 32px 9px 20px;background:#2d6ca2;display:none}@media screen and (min-width: 783px){.simpay-admin-notice-top-of-page{padding:10px 46px 10px 22px}}@media screen and (min-width: 961px){.simpay-admin-notice-top-of-page{text-align:center}}.simpay-admin-notice-top-of-page a{color:#fff}.simpay-admin-notice-top-of-page a:hover{text-decoration:none}.simpay-admin-notice-top-of-page .button-link{position:absolute;top:48px;right:-1px;font-size:20px;color:#fff;font-weight:bold;text-decoration:none;margin-left:5px;padding:6px 10px}@media screen and (min-width: 601px){.simpay-admin-notice-top-of-page .button-link{top:0}}@media screen and (min-width: 783px){.simpay-admin-notice-top-of-page .button-link{right:9px}}.simpay-admin-notice-top-of-page .button-link:hover,.simpay-admin-notice-top-of-page .button-link:active,.simpay-admin-notice-top-of-page .button-link:focus{color:#fff;text-decoration:none}#simpay-product-education .simpay-dashboard-widget-product-education{text-align:center;padding:10px 30px}#simpay-product-education .simpay-dashboard-widget-product-education img{width:200px;margin:0 auto}#simpay-product-education .simpay-dashboard-widget-product-education h2{font-size:16px;font-weight:600;margin:0 0 -10px;padding:0;line-height:1.3}#simpay-product-education .simpay-dashboard-widget-product-education .button+.button{margin-left:5px}.simpay-admin-notice-update-plugin{display:flex;justify-content:space-between;align-items:center;padding:10px}.simpay-admin-notice-update-plugin__copy{display:flex;align-items:center;flex-grow:1}.simpay-admin-notice-update-plugin__copy img{width:150px;margin:0 15px 3px 0}.simpay-admin-notice-update-plugin~.notice-dismiss{top:11px}@media screen and (max-width: 782px){.simpay-admin-notice-update-plugin{flex-wrap:wrap}.simpay-admin-notice-update-plugin img{display:none}.simpay-admin-notice-update-plugin .button.button-primary{margin-top:10px}.simpay-admin-notice-update-plugin~.notice-dismiss{top:0}}#adminmenu a[href*=\"page=simpay-setup-wizard\"]{display:none}"],"sourceRoot":""} \ No newline at end of file +{"version":3,"sources":["webpack:///./css/admin/all-pages.scss"],"names":[],"mappings":"AAAA,0DAA0D,cAAc,kBAAkB,yBAAyB,eAAe,iBAAiB,gBAAgB,gBAAgB,kBAAkB,mBAAmB,oBAAoB,mBAAmB,iCAAiC,WAAW,eAAe,mBAAmB,WAAW,YAAY,qBAAqB,uCAAuC,UAAU,wBAAwB,qBAAqB,mBAAmB,sBAAsB,sBAAsB,cAAc,eAAe,YAAY,kBAAkB,yBAAyB,WAAW,eAAe,gBAAgB,kBAAkB,WAAW,kBAAkB,8BAA8B,WAAW,YAAY,eAAe,uCAAuC,eAAe,gCAAgC,GAAG,sBAAsB,uCAAuC,KAAK,mBAAmB,wCAAwC,wBAAwB,GAAG,sBAAsB,uCAAuC,KAAK,mBAAmB,wCAAwC,qDAAqD,qBAAqB,eAAe,UAAU,WAAW,yBAAyB,kBAAkB,YAAY,2CAA2C,mCAAmC,mFAAmF,WAAW,oCAAoC,yFAAyF,sBAAsB,4FAA4F,iBAAiB,qBAAqB,yBAAyB,iBAAiB,8BAA8B,gBAAgB,WAAW,mBAAmB,YAAY,aAAa,sCAAsC,YAAY,qBAAqB,0BAA0B,WAAW,oBAAoB,mBAAmB,+DAA+D,aAAa,iCAAiC,eAAe,gBAAgB,WAAW,kBAAkB,0BAA0B,mBAAmB,aAAa,qCAAqC,iCAAiC,6BAA6B,qCAAqC,iCAAiC,mBAAmB,mCAAmC,WAAW,yCAAyC,qBAAqB,8CAA8C,kBAAkB,SAAS,WAAW,eAAe,WAAW,iBAAiB,qBAAqB,gBAAgB,iBAAiB,qCAAqC,8CAA8C,OAAO,qCAAqC,8CAA8C,WAAW,6JAA6J,WAAW,qBAAqB,qEAAqE,kBAAkB,kBAAkB,yEAAyE,YAAY,cAAc,wEAAwE,eAAe,gBAAgB,iBAAiB,UAAU,gBAAgB,qFAAqF,gBAAgB,mCAAmC,aAAa,8BAA8B,mBAAmB,aAAa,yCAAyC,aAAa,mBAAmB,YAAY,6CAA6C,YAAY,oBAAoB,mDAAmD,SAAS,qCAAqC,mCAAmC,eAAe,uCAAuC,aAAa,0DAA0D,gBAAgB,mDAAmD,OAAO,+CAA+C,aAAa,4BAA4B,cAAc,qBAAqB,cAAc,gBAAgB,iB","file":"./../css/simpay-admin-all-pages.min.css","sourcesContent":[".simpay-test-mode-badge-container .simpay-test-mode-badge{color:#a04903;text-align:center;text-transform:uppercase;font-size:10px;line-height:10px;font-weight:700;padding:5px 7px;border-radius:3px;background:#ffde92;display:inline-flex;align-items:center}.simpay-external-link .dashicons{opacity:.8;font-size:16px;margin:3px 0 0 2px;width:16px;height:16px;text-decoration:none}.simpay-external-link:hover .dashicons{opacity:1}.simpay-settings-bubble{display:inline-block;vertical-align:top;box-sizing:border-box;margin:1px 0 -1px 5px;padding:0 5px;min-width:18px;height:18px;border-radius:9px;background-color:#d63638;color:#fff;font-size:11px;line-height:1.6;text-align:center;z-index:26;position:relative}.simpay-settings-bubble:empty{width:10px;height:10px;min-width:10px}.nav-tab .simpay-settings-bubble:empty{margin-top:7px}@-webkit-keyframes simpay-pulse{0%{transform:scale(0.95);box-shadow:0 0 0 0 rgba(214,54,56,.65)}100%{transform:scale(1);box-shadow:0 0 0 8px rgba(214,54,56,0)}}@keyframes simpay-pulse{0%{transform:scale(0.95);box-shadow:0 0 0 0 rgba(214,54,56,.65)}100%{transform:scale(1);box-shadow:0 0 0 8px rgba(214,54,56,0)}}#adminmenu .simpay-admin-menu-notification-indicator{display:inline-block;margin-top:6px;width:8px;height:8px;background-color:#d63638;border-radius:50%;float:right;-webkit-animation:simpay-pulse 2s infinite;animation:simpay-pulse 2s infinite}#adminmenu a[href^=\"https://wpsimplepay.com/lite-vs-pro\"]:not(.simpay-upgrade-btn){color:#fff;background-color:#347d39 !important}#adminmenu a[href^=\"https://wpsimplepay.com/lite-vs-pro\"]:not(.simpay-upgrade-btn):hover{color:#fff !important}#adminmenu .opensub a[href^=\"https://wpsimplepay.com/lite-vs-pro\"]:not(.simpay-upgrade-btn){margin-right:6px}.simpay-upgrade-link{color:#3db634 !important;font-weight:bold}.simpay-plugin-upgrade-notice{font-weight:400;color:#fff;background:#d54d21;padding:1em;margin:9px 0}.simpay-plugin-upgrade-notice::before{content:\"\";display:inline-block;font:400 18px/1 dashicons;speak:none;margin:0 8px 0 -2px;vertical-align:top}#stripe-update .updating-message .simpay-plugin-upgrade-notice{display:none}.simpay-admin-notice-top-of-page{font-size:13px;line-height:1.4;color:#fff;margin-left:-20px;padding:9px 32px 9px 20px;background:#2d6ca2;display:none}@media screen and (min-width: 783px){.simpay-admin-notice-top-of-page{padding:10px 46px 10px 22px}}@media screen and (min-width: 961px){.simpay-admin-notice-top-of-page{text-align:center}}.simpay-admin-notice-top-of-page a{color:#fff}.simpay-admin-notice-top-of-page a:hover{text-decoration:none}.simpay-admin-notice-top-of-page .button-link{position:absolute;top:48px;right:-1px;font-size:20px;color:#fff;font-weight:bold;text-decoration:none;margin-left:5px;padding:6px 10px}@media screen and (min-width: 601px){.simpay-admin-notice-top-of-page .button-link{top:0}}@media screen and (min-width: 783px){.simpay-admin-notice-top-of-page .button-link{right:9px}}.simpay-admin-notice-top-of-page .button-link:hover,.simpay-admin-notice-top-of-page .button-link:active,.simpay-admin-notice-top-of-page .button-link:focus{color:#fff;text-decoration:none}#simpay-product-education .simpay-dashboard-widget-product-education{text-align:center;padding:10px 30px}#simpay-product-education .simpay-dashboard-widget-product-education img{width:200px;margin:0 auto}#simpay-product-education .simpay-dashboard-widget-product-education h2{font-size:16px;font-weight:600;margin:0 0 -10px;padding:0;line-height:1.3}#simpay-product-education .simpay-dashboard-widget-product-education .button+.button{margin-left:5px}.simpay-admin-notice-update-plugin{display:flex;justify-content:space-between;align-items:center;padding:10px}.simpay-admin-notice-update-plugin__copy{display:flex;align-items:center;flex-grow:1}.simpay-admin-notice-update-plugin__copy img{width:150px;margin:0 15px 3px 0}.simpay-admin-notice-update-plugin~.notice-dismiss{top:11px}@media screen and (max-width: 782px){.simpay-admin-notice-update-plugin{flex-wrap:wrap}.simpay-admin-notice-update-plugin img{display:none}.simpay-admin-notice-update-plugin .button.button-primary{margin-top:10px}.simpay-admin-notice-update-plugin~.notice-dismiss{top:0}}#adminmenu a[href*=\"page=simpay-setup-wizard\"]{display:none}#adminmenu .simpay-menu-new{color:#f18500;vertical-align:super;font-size:9px;font-weight:600;padding-left:2px}"],"sourceRoot":""} \ No newline at end of file diff --git a/includes/core/assets/css/simpay-admin-form-template-explorer.min.css b/includes/core/assets/css/simpay-admin-form-template-explorer.min.css index 94cfb898..2fc46190 100644 --- a/includes/core/assets/css/simpay-admin-form-template-explorer.min.css +++ b/includes/core/assets/css/simpay-admin-form-template-explorer.min.css @@ -1,3 +1,3 @@ -body.admin-color-light{--wp-admin-theme-color: #0085ba;--wp-admin-theme-color--rgb: 0, 133, 186;--wp-admin-theme-color-darker-10: #0073a1;--wp-admin-theme-color-darker-10--rgb: 0, 115, 161;--wp-admin-theme-color-darker-20: #006187;--wp-admin-theme-color-darker-20--rgb: 0, 97, 135;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-light{--wp-admin-border-width-focus: 1.5px}}body.admin-color-modern{--wp-admin-theme-color: #3858e9;--wp-admin-theme-color--rgb: 56, 88, 233;--wp-admin-theme-color-darker-10: #2145e6;--wp-admin-theme-color-darker-10--rgb: 33, 69, 230;--wp-admin-theme-color-darker-20: #183ad6;--wp-admin-theme-color-darker-20--rgb: 24, 58, 214;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-modern{--wp-admin-border-width-focus: 1.5px}}body.admin-color-blue{--wp-admin-theme-color: #096484;--wp-admin-theme-color--rgb: 9, 100, 132;--wp-admin-theme-color-darker-10: #07526c;--wp-admin-theme-color-darker-10--rgb: 7, 82, 108;--wp-admin-theme-color-darker-20: #064054;--wp-admin-theme-color-darker-20--rgb: 6, 64, 84;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-blue{--wp-admin-border-width-focus: 1.5px}}body.admin-color-coffee{--wp-admin-theme-color: #46403c;--wp-admin-theme-color--rgb: 70, 64, 60;--wp-admin-theme-color-darker-10: #383330;--wp-admin-theme-color-darker-10--rgb: 56, 51, 48;--wp-admin-theme-color-darker-20: #2b2724;--wp-admin-theme-color-darker-20--rgb: 43, 39, 36;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-coffee{--wp-admin-border-width-focus: 1.5px}}body.admin-color-ectoplasm{--wp-admin-theme-color: #523f6d;--wp-admin-theme-color--rgb: 82, 63, 109;--wp-admin-theme-color-darker-10: #46365d;--wp-admin-theme-color-darker-10--rgb: 70, 54, 93;--wp-admin-theme-color-darker-20: #3a2c4d;--wp-admin-theme-color-darker-20--rgb: 58, 44, 77;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-ectoplasm{--wp-admin-border-width-focus: 1.5px}}body.admin-color-midnight{--wp-admin-theme-color: #e14d43;--wp-admin-theme-color--rgb: 225, 77, 67;--wp-admin-theme-color-darker-10: #dd382d;--wp-admin-theme-color-darker-10--rgb: 221, 56, 45;--wp-admin-theme-color-darker-20: #d02c21;--wp-admin-theme-color-darker-20--rgb: 208, 44, 33;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-midnight{--wp-admin-border-width-focus: 1.5px}}body.admin-color-ocean{--wp-admin-theme-color: #627c83;--wp-admin-theme-color--rgb: 98, 124, 131;--wp-admin-theme-color-darker-10: #576e74;--wp-admin-theme-color-darker-10--rgb: 87, 110, 116;--wp-admin-theme-color-darker-20: #4c6066;--wp-admin-theme-color-darker-20--rgb: 76, 96, 102;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-ocean{--wp-admin-border-width-focus: 1.5px}}body.admin-color-sunrise{--wp-admin-theme-color: #dd823b;--wp-admin-theme-color--rgb: 221, 130, 59;--wp-admin-theme-color-darker-10: #d97426;--wp-admin-theme-color-darker-10--rgb: 217, 116, 38;--wp-admin-theme-color-darker-20: #c36922;--wp-admin-theme-color-darker-20--rgb: 195, 105, 34;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-sunrise{--wp-admin-border-width-focus: 1.5px}}@media(min-width: 1440px){body.simpay-template-explorer-open{overflow:hidden}}body.simpay-template-explorer-open .simpay-admin-notice-top-of-page.simpay-notice,body.simpay-template-explorer-open .notice,body.simpay-template-explorer-open #screen-meta,body.simpay-template-explorer-open #screen-meta-links,body.simpay-template-explorer-open #poststuff,body.simpay-template-explorer-open #wpfooter{display:none !important}body.simpay-template-explorer-open.branch-5-6 .components-search-control,body.simpay-template-explorer-open.branch-5-7 .components-search-control,body.simpay-template-explorer-open.branch-5-8 .components-search-control{position:relative}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input{font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Oxygen-Sans,Ubuntu,Cantarell,"Helvetica Neue",sans-serif;padding:6px 8px;box-shadow:0 0 0 transparent;transition:box-shadow .1s linear;border-radius:2px;border:1px solid #757575;font-size:16px;line-height:normal;display:block;padding:16px 48px 16px 16px;background:#f0f0f0;border:none;width:100%;height:48px;font-size:16px}@media(prefers-reduced-motion: reduce){body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input{transition-duration:0s;transition-delay:0s}}@media(min-width: 600px){body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input{font-size:13px;line-height:normal}}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input:focus,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input:focus,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input:focus{border-color:var(--wp-admin-theme-color);box-shadow:0 0 0 1px var(--wp-admin-theme-color);outline:2px solid transparent}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::-webkit-input-placeholder,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::-webkit-input-placeholder,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::-webkit-input-placeholder{color:rgba(30,30,30,.62)}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::-moz-placeholder,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::-moz-placeholder,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::-moz-placeholder{opacity:1;color:rgba(30,30,30,.62)}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input:-ms-input-placeholder,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input:-ms-input-placeholder,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input:-ms-input-placeholder{color:rgba(30,30,30,.62)}@media(min-width: 600px){body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input{font-size:13px}}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input:focus,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input:focus,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input:focus{background:#fff;box-shadow:0 0 0 2px var(--wp-admin-theme-color)}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::-moz-placeholder, body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::-moz-placeholder, body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::-moz-placeholder{color:#757575}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input:-ms-input-placeholder, body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input:-ms-input-placeholder, body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input:-ms-input-placeholder{color:#757575}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::placeholder,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::placeholder,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::placeholder{color:#757575}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::-webkit-search-decoration,body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::-webkit-search-cancel-button,body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::-webkit-search-results-button,body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::-webkit-search-results-decoration,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::-webkit-search-decoration,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::-webkit-search-cancel-button,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::-webkit-search-results-button,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::-webkit-search-results-decoration,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::-webkit-search-decoration,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::-webkit-search-cancel-button,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::-webkit-search-results-button,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::-webkit-search-results-decoration{-webkit-appearance:none}body.simpay-template-explorer-open.branch-5-6 .components-search-control__icon,body.simpay-template-explorer-open.branch-5-7 .components-search-control__icon,body.simpay-template-explorer-open.branch-5-8 .components-search-control__icon{position:absolute;top:0;right:12px;bottom:0;display:flex;align-items:center}body.simpay-template-explorer-open.branch-5-6 .components-search-control__icon>svg,body.simpay-template-explorer-open.branch-5-7 .components-search-control__icon>svg,body.simpay-template-explorer-open.branch-5-8 .components-search-control__icon>svg{margin:8px 0}body.simpay-template-explorer-open.branch-5-6 .components-search-control__input-wrapper,body.simpay-template-explorer-open.branch-5-7 .components-search-control__input-wrapper,body.simpay-template-explorer-open.branch-5-8 .components-search-control__input-wrapper{position:relative}#simpay-form-template-explorer{background:#fff;border:1px solid #c3c4c7;box-shadow:0 1px 1px rgba(0,0,0,.04);margin-top:10px}#simpay-form-template-explorer,#simpay-form-template-explorer *{box-sizing:border-box}@media(min-width: 1440px){#simpay-form-template-explorer{position:fixed;top:111px;right:0;bottom:0;left:160px;margin:20px 22px;overflow-x:hidden;overflow-y:scroll}.folded #simpay-form-template-explorer{left:36px}}#simpay-form-template-explorer #wpcontent{padding-left:0}#simpay-form-template-explorer #wpbody-content{padding-bottom:0}.simpay-form-template-explorer{padding:24px}@media(min-width: 1440px){.simpay-form-template-explorer{height:100%;overflow:auto;padding-top:0}}@media(min-width: 1440px){.simpay-form-template-explorer-header{position:absolute;left:0;right:0;padding:24px 0 24px 24px;margin-right:24px;height:100px;background:#fff;z-index:2}}.simpay-form-template-explorer-header__title{font-size:22px;font-weight:400;margin:0}.simpay-form-template-explorer-header__subtitle{color:#555;font-size:15px;margin:8px 0 0}.simpay-form-template-explorer-main{margin-top:24px}.simpay-form-template-explorer-main__sidebar{margin-bottom:24px;padding:2px}.simpay-form-template-explorer-main__sidebar-search{margin-bottom:12px}@media(min-width: 1440px){.simpay-form-template-explorer-main__sidebar-search{margin-bottom:24px}}@media(min-width: 1440px){.simpay-form-template-explorer-main__sidebar-categories{display:flex;flex-direction:column}}.simpay-form-template-explorer-main__sidebar-categories .components-button.is-pressed{background-color:var(--wp-admin-theme-color)}.simpay-form-template-explorer-main__content{display:-ms-grid;display:grid;grid-gap:24px;-ms-grid-columns:(1fr)[1];grid-template-columns:repeat(1, 1fr);padding:2px}@media(min-width: 782px){.simpay-form-template-explorer-main__content:not(.is-empty){-ms-grid-columns:(minmax(0, 1fr))[2];grid-template-columns:repeat(2, minmax(0, 1fr))}}@media(min-width: 960px){.simpay-form-template-explorer-main__content:not(.is-empty){-ms-grid-columns:(minmax(0, 1fr))[3];grid-template-columns:repeat(3, minmax(0, 1fr))}}.simpay-form-template-explorer-main__content-list-item{text-align:left;padding:16px;border-radius:4px;border:1px solid #ddd;position:relative;transition:all .15s ease-out;width:100%;height:auto;min-height:100px;flex-direction:column;align-items:flex-start}.simpay-form-template-explorer-main__content-list-item:focus-within,.simpay-form-template-explorer-main__content-list-item:focus,.simpay-form-template-explorer-main__content-list-item:hover{border-color:#1e1e1e;box-shadow:0 0 0 1px #1e1e1e;outline:none}.simpay-form-template-explorer-main__content-list-item:focus-within .simpay-form-template-explorer-main__content-list-item__description,.simpay-form-template-explorer-main__content-list-item:focus .simpay-form-template-explorer-main__content-list-item__description,.simpay-form-template-explorer-main__content-list-item:hover .simpay-form-template-explorer-main__content-list-item__description{opacity:0}.simpay-form-template-explorer-main__content-list-item:focus-within .simpay-form-template-explorer-main__content-list-item__actions,.simpay-form-template-explorer-main__content-list-item:focus .simpay-form-template-explorer-main__content-list-item__actions,.simpay-form-template-explorer-main__content-list-item:hover .simpay-form-template-explorer-main__content-list-item__actions{opacity:1}.simpay-form-template-explorer-main__content-list-item__name{font-size:16px;font-weight:600;line-height:21px;overflow:hidden;position:relative;text-overflow:ellipsis;white-space:nowrap}.simpay-form-template-explorer-main__content-list-item__name--is-locked{padding-right:30px}.simpay-form-template-explorer-main__content-list-item__description{color:#777;font-size:14px;line-height:18px;margin:10px 0 0;max-height:53px;overflow:hidden;opacity:1}.simpay-form-template-explorer-main__content-list-item__actions{background-color:#fff;border-radius:4px;display:flex;justify-content:space-between;align-items:center;padding:16px;position:absolute;top:0;right:0;bottom:0;left:0;width:100%;height:100%;opacity:0;transition:all .15s ease-out}@media(min-width: 782px){.simpay-form-template-explorer-main__content-list-item__actions{padding:0 16px 16px;top:auto;height:auto}}.simpay-form-template-explorer-main__content-list-item__actions .components-button{justify-content:center;flex:1 1 48%}.simpay-form-template-explorer-main__content-list-item__badge{background:#fff;padding:4px;position:absolute;right:10px;top:14px;z-index:2}.simpay-form-template-explorer-main__content-list-item__badge svg{fill:#777}.simpay-form-template-explorer-main__content-suggest{color:#1d2327;padding:24px;grid-column:1/-1;display:flex;align-items:flex-start;border:1px solid #ddd;border-radius:4px;box-shadow:0 1px 2px rgba(0,0,0,.06)}.simpay-form-template-explorer-main__content-suggest>div{margin-left:16px}.simpay-form-template-explorer-main__content-suggest svg{fill:currentColor;flex:1 0 auto;margin-top:-6px}.simpay-form-template-explorer-main__content-suggest h4{margin:0;font-size:20px}.simpay-form-template-explorer-main__content-suggest p{color:#555;font-size:14px}@media(min-width: 1440px){.simpay-form-template-explorer-main{margin-top:100px}.simpay-form-template-explorer-main__sidebar{top:100px;bottom:0;left:24px;overflow-x:hidden;overflow-y:auto;position:absolute;width:280px}.simpay-form-template-explorer-main__content{overflow-x:hidden;overflow-y:auto;margin-left:300px}}.simpay-form-template-explorer-upgrade{max-width:600px}.simpay-form-template-explorer-upgrade *{box-sizing:border-box}.simpay-form-template-explorer-upgrade__content{text-align:center;display:flex;flex-direction:column;align-items:center}.simpay-form-template-explorer-upgrade__title{font-size:22px;line-height:1.5;display:block;margin:12px 0 0}.simpay-form-template-explorer-upgrade__description{color:#777;font-size:16px;margin:16px 0 24px}.simpay-form-template-explorer-upgrade__description strong{color:#1d2327}.simpay-form-template-explorer-upgrade .components-button.is-primary{font-size:16px;font-weight:bold;margin:0 0 15px;padding:15px 30px !important;height:auto}.simpay-form-template-explorer-upgrade__purchased{color:#555;display:inline-block;margin:8px 0}.simpay-form-template-explorer-upgrade__discount{font-size:15px;text-align:center;margin:24px -32px -24px;padding:32px 40px 24px;border-bottom-left-radius:2px;border-bottom-right-radius:2px;background-color:#fcf9e8;position:relative}.simpay-form-template-explorer-upgrade__discount svg{background:#00a32a;fill:#fff;border-radius:50%;border:4px solid #fff;width:32px;height:32px;position:absolute;top:-16px;left:50%;margin-left:-16px}.simpay-form-template-explorer-upgrade__discount u{text-decoration:none;font-weight:bold;color:#00a32a}.simpay-form-template-explorer-upgrade__discount a{text-decoration:none} +body.admin-color-light{--wp-admin-theme-color: #0085ba;--wp-admin-theme-color--rgb: 0, 133, 186;--wp-admin-theme-color-darker-10: #0073a1;--wp-admin-theme-color-darker-10--rgb: 0, 115, 161;--wp-admin-theme-color-darker-20: #006187;--wp-admin-theme-color-darker-20--rgb: 0, 97, 135;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-light{--wp-admin-border-width-focus: 1.5px}}body.admin-color-modern{--wp-admin-theme-color: #3858e9;--wp-admin-theme-color--rgb: 56, 88, 233;--wp-admin-theme-color-darker-10: #2145e6;--wp-admin-theme-color-darker-10--rgb: 33, 69, 230;--wp-admin-theme-color-darker-20: #183ad6;--wp-admin-theme-color-darker-20--rgb: 24, 58, 214;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-modern{--wp-admin-border-width-focus: 1.5px}}body.admin-color-blue{--wp-admin-theme-color: #096484;--wp-admin-theme-color--rgb: 9, 100, 132;--wp-admin-theme-color-darker-10: #07526c;--wp-admin-theme-color-darker-10--rgb: 7, 82, 108;--wp-admin-theme-color-darker-20: #064054;--wp-admin-theme-color-darker-20--rgb: 6, 64, 84;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-blue{--wp-admin-border-width-focus: 1.5px}}body.admin-color-coffee{--wp-admin-theme-color: #46403c;--wp-admin-theme-color--rgb: 70, 64, 60;--wp-admin-theme-color-darker-10: #383330;--wp-admin-theme-color-darker-10--rgb: 56, 51, 48;--wp-admin-theme-color-darker-20: #2b2724;--wp-admin-theme-color-darker-20--rgb: 43, 39, 36;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-coffee{--wp-admin-border-width-focus: 1.5px}}body.admin-color-ectoplasm{--wp-admin-theme-color: #523f6d;--wp-admin-theme-color--rgb: 82, 63, 109;--wp-admin-theme-color-darker-10: #46365d;--wp-admin-theme-color-darker-10--rgb: 70, 54, 93;--wp-admin-theme-color-darker-20: #3a2c4d;--wp-admin-theme-color-darker-20--rgb: 58, 44, 77;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-ectoplasm{--wp-admin-border-width-focus: 1.5px}}body.admin-color-midnight{--wp-admin-theme-color: #e14d43;--wp-admin-theme-color--rgb: 225, 77, 67;--wp-admin-theme-color-darker-10: #dd382d;--wp-admin-theme-color-darker-10--rgb: 221, 56, 45;--wp-admin-theme-color-darker-20: #d02c21;--wp-admin-theme-color-darker-20--rgb: 208, 44, 33;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-midnight{--wp-admin-border-width-focus: 1.5px}}body.admin-color-ocean{--wp-admin-theme-color: #627c83;--wp-admin-theme-color--rgb: 98, 124, 131;--wp-admin-theme-color-darker-10: #576e74;--wp-admin-theme-color-darker-10--rgb: 87, 110, 116;--wp-admin-theme-color-darker-20: #4c6066;--wp-admin-theme-color-darker-20--rgb: 76, 96, 102;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-ocean{--wp-admin-border-width-focus: 1.5px}}body.admin-color-sunrise{--wp-admin-theme-color: #dd823b;--wp-admin-theme-color--rgb: 221, 130, 59;--wp-admin-theme-color-darker-10: #d97426;--wp-admin-theme-color-darker-10--rgb: 217, 116, 38;--wp-admin-theme-color-darker-20: #c36922;--wp-admin-theme-color-darker-20--rgb: 195, 105, 34;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-sunrise{--wp-admin-border-width-focus: 1.5px}}@media(min-width: 1440px){body.simpay-template-explorer-open{overflow:hidden}}body.simpay-template-explorer-open .simpay-admin-notice-top-of-page.simpay-notice,body.simpay-template-explorer-open .notice,body.simpay-template-explorer-open #screen-meta,body.simpay-template-explorer-open #screen-meta-links,body.simpay-template-explorer-open #poststuff,body.simpay-template-explorer-open #wpfooter{display:none !important}body.simpay-template-explorer-open.branch-5-6 .components-search-control,body.simpay-template-explorer-open.branch-5-7 .components-search-control,body.simpay-template-explorer-open.branch-5-8 .components-search-control{position:relative}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input{font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Oxygen-Sans,Ubuntu,Cantarell,"Helvetica Neue",sans-serif;padding:6px 8px;box-shadow:0 0 0 transparent;transition:box-shadow .1s linear;border-radius:2px;border:1px solid #757575;font-size:16px;line-height:normal;display:block;padding:16px 48px 16px 16px;background:#f0f0f0;border:none;width:100%;height:48px;font-size:16px}@media(prefers-reduced-motion: reduce){body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input{transition-duration:0s;transition-delay:0s}}@media(min-width: 600px){body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input{font-size:13px;line-height:normal}}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input:focus,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input:focus,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input:focus{border-color:var(--wp-admin-theme-color);box-shadow:0 0 0 1px var(--wp-admin-theme-color);outline:2px solid transparent}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::-webkit-input-placeholder,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::-webkit-input-placeholder,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::-webkit-input-placeholder{color:rgba(30,30,30,.62)}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::-moz-placeholder,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::-moz-placeholder,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::-moz-placeholder{opacity:1;color:rgba(30,30,30,.62)}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input:-ms-input-placeholder,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input:-ms-input-placeholder,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input:-ms-input-placeholder{color:rgba(30,30,30,.62)}@media(min-width: 600px){body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input{font-size:13px}}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input:focus,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input:focus,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input:focus{background:#fff;box-shadow:0 0 0 2px var(--wp-admin-theme-color)}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::-moz-placeholder, body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::-moz-placeholder, body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::-moz-placeholder{color:#757575}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input:-ms-input-placeholder, body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input:-ms-input-placeholder, body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input:-ms-input-placeholder{color:#757575}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::placeholder,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::placeholder,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::placeholder{color:#757575}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::-webkit-search-decoration,body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::-webkit-search-cancel-button,body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::-webkit-search-results-button,body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::-webkit-search-results-decoration,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::-webkit-search-decoration,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::-webkit-search-cancel-button,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::-webkit-search-results-button,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::-webkit-search-results-decoration,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::-webkit-search-decoration,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::-webkit-search-cancel-button,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::-webkit-search-results-button,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::-webkit-search-results-decoration{-webkit-appearance:none}body.simpay-template-explorer-open.branch-5-6 .components-search-control__icon,body.simpay-template-explorer-open.branch-5-7 .components-search-control__icon,body.simpay-template-explorer-open.branch-5-8 .components-search-control__icon{position:absolute;top:0;right:12px;bottom:0;display:flex;align-items:center}body.simpay-template-explorer-open.branch-5-6 .components-search-control__icon>svg,body.simpay-template-explorer-open.branch-5-7 .components-search-control__icon>svg,body.simpay-template-explorer-open.branch-5-8 .components-search-control__icon>svg{margin:8px 0}body.simpay-template-explorer-open.branch-5-6 .components-search-control__input-wrapper,body.simpay-template-explorer-open.branch-5-7 .components-search-control__input-wrapper,body.simpay-template-explorer-open.branch-5-8 .components-search-control__input-wrapper{position:relative}#simpay-form-template-explorer{background:#fff;border:1px solid #c3c4c7;box-shadow:0 1px 1px rgba(0,0,0,.04);margin-top:10px}#simpay-form-template-explorer,#simpay-form-template-explorer *{box-sizing:border-box}@media(min-width: 1440px){#simpay-form-template-explorer{position:fixed;top:111px;right:0;bottom:0;left:160px;margin:20px 22px;overflow-x:hidden;overflow-y:scroll}.folded #simpay-form-template-explorer{left:36px}}#simpay-form-template-explorer #wpcontent{padding-left:0}#simpay-form-template-explorer #wpbody-content{padding-bottom:0}.simpay-form-template-explorer{padding:24px}@media(min-width: 1440px){.simpay-form-template-explorer{height:100%;overflow:auto;padding-top:0}}@media(min-width: 1440px){.simpay-form-template-explorer-header{margin-right:24px;padding:30px 30px 25px;width:100%;background:#fff;border-bottom:1px solid #c3c4c7;box-shadow:0 1px 1px rgba(0,0,0,.04);position:absolute;left:0;right:0;z-index:3}}.simpay-form-template-explorer-header__title{font-size:26px;margin:0}.simpay-form-template-explorer-header__subtitle{color:#555;font-size:15px;margin:16px 0 0}.simpay-form-template-explorer-main{margin-top:24px}.simpay-form-template-explorer-main__sidebar{margin-bottom:24px;padding:2px}.simpay-form-template-explorer-main__sidebar-search{margin-bottom:12px}@media(min-width: 1440px){.simpay-form-template-explorer-main__sidebar-search{margin-bottom:24px}}@media(min-width: 1440px){.simpay-form-template-explorer-main__sidebar-categories{display:flex;flex-direction:column}}.simpay-form-template-explorer-main__sidebar-categories .components-button.is-pressed{background-color:var(--wp-admin-theme-color)}.simpay-form-template-explorer-main__sidebar-categories_category.category-new{font-weight:bold}.simpay-form-template-explorer-main__content{display:-ms-grid;display:grid;grid-gap:24px;-ms-grid-columns:(1fr)[1];grid-template-columns:repeat(1, 1fr);padding:2px}@media(min-width: 782px){.simpay-form-template-explorer-main__content:not(.is-empty){-ms-grid-columns:(minmax(0, 1fr))[2];grid-template-columns:repeat(2, minmax(0, 1fr))}}@media(min-width: 960px){.simpay-form-template-explorer-main__content:not(.is-empty){-ms-grid-columns:(minmax(0, 1fr))[3];grid-template-columns:repeat(3, minmax(0, 1fr))}}.simpay-form-template-explorer-main__content-list-item{text-align:left;padding:16px;border-radius:4px;border:1px solid #ddd;position:relative;transition:all .15s ease-out;width:100%;height:auto;min-height:100px;flex-direction:column;align-items:flex-start}.simpay-form-template-explorer-main__content-list-item:focus-within,.simpay-form-template-explorer-main__content-list-item:focus,.simpay-form-template-explorer-main__content-list-item:hover{border-color:#1e1e1e;box-shadow:0 0 0 1px #1e1e1e;outline:none}.simpay-form-template-explorer-main__content-list-item:focus-within .simpay-form-template-explorer-main__content-list-item__description,.simpay-form-template-explorer-main__content-list-item:focus .simpay-form-template-explorer-main__content-list-item__description,.simpay-form-template-explorer-main__content-list-item:hover .simpay-form-template-explorer-main__content-list-item__description{opacity:0}.simpay-form-template-explorer-main__content-list-item:focus-within .simpay-form-template-explorer-main__content-list-item__actions,.simpay-form-template-explorer-main__content-list-item:focus .simpay-form-template-explorer-main__content-list-item__actions,.simpay-form-template-explorer-main__content-list-item:hover .simpay-form-template-explorer-main__content-list-item__actions{opacity:1}.simpay-form-template-explorer-main__content-list-item__name{font-size:16px;font-weight:600;line-height:21px;overflow:hidden;position:relative;text-overflow:ellipsis;white-space:nowrap}.simpay-form-template-explorer-main__content-list-item__name--is-locked{padding-right:30px}.simpay-form-template-explorer-main__content-list-item__description{color:#777;font-size:14px;line-height:18px;margin:10px 0 0;max-height:53px;overflow:hidden;opacity:1}.simpay-form-template-explorer-main__content-list-item__actions{background-color:#fff;border-radius:4px;display:flex;justify-content:space-between;align-items:center;padding:16px;position:absolute;top:0;right:0;bottom:0;left:0;width:100%;height:100%;opacity:0;transition:all .15s ease-out}@media(min-width: 782px){.simpay-form-template-explorer-main__content-list-item__actions{padding:0 16px 16px;top:auto;height:auto}}.simpay-form-template-explorer-main__content-list-item__actions .components-button{justify-content:center;flex:1 1 48%}.simpay-form-template-explorer-main__content-list-item__badge{background:#fff;padding:4px;position:absolute;right:10px;top:14px;z-index:2}.simpay-form-template-explorer-main__content-list-item__badge svg{fill:#777}.simpay-form-template-explorer-main__content-suggest{color:#1d2327;padding:24px;grid-column:1/-1;display:flex;align-items:flex-start;border:1px solid #ddd;border-radius:4px;box-shadow:0 1px 2px rgba(0,0,0,.06)}.simpay-form-template-explorer-main__content-suggest>div{margin-left:16px}.simpay-form-template-explorer-main__content-suggest svg{fill:currentColor;flex:1 0 auto;margin-top:-6px}.simpay-form-template-explorer-main__content-suggest h4{margin:0;font-size:20px}.simpay-form-template-explorer-main__content-suggest p{color:#555;font-size:14px}.simpay-form-template-explorer-main__content-upgrade{color:#1d2327;padding:32px;grid-column:1/-1;display:flex;align-items:center;justify-content:space-between;background:#fafcfe;border:1px solid #dce9f6;border-radius:4px;box-shadow:0 1px 3px rgba(66,139,202,.08)}.simpay-form-template-explorer-main__content-upgrade>div{margin-right:50px}.simpay-form-template-explorer-main__content-upgrade h4{font-size:18px;margin:0}.simpay-form-template-explorer-main__content-upgrade p{color:#555;font-size:14px;margin:8px 0 0}@media(min-width: 1440px){.simpay-form-template-explorer-main{margin-top:130px}.simpay-form-template-explorer-main__sidebar{top:130px;bottom:0;left:24px;overflow-x:hidden;overflow-y:auto;position:absolute;width:280px}.simpay-form-template-explorer-main__content{overflow-x:hidden;overflow-y:auto;margin-left:300px}}.simpay-form-template-explorer-upgrade{max-width:600px}.simpay-form-template-explorer-upgrade *{box-sizing:border-box}.simpay-form-template-explorer-upgrade__content{text-align:center;display:flex;flex-direction:column;align-items:center}.simpay-form-template-explorer-upgrade__title{font-size:22px;line-height:1.5;display:block;margin:12px 0 0}.simpay-form-template-explorer-upgrade__description{color:#777;font-size:16px;margin:16px 0 24px}.simpay-form-template-explorer-upgrade__description strong{color:#1d2327}.simpay-form-template-explorer-upgrade .components-button.is-primary{font-size:16px;font-weight:bold;margin:0 0 15px;padding:15px 30px !important;height:auto}.simpay-form-template-explorer-upgrade__purchased{color:#555;display:inline-block;margin:8px 0}.simpay-form-template-explorer-upgrade__discount{font-size:15px;text-align:center;margin:24px -32px -24px;padding:32px 40px 24px;border-bottom-left-radius:2px;border-bottom-right-radius:2px;background-color:#fcf9e8;position:relative}.simpay-form-template-explorer-upgrade__discount svg{background:#00a32a;fill:#fff;border-radius:50%;border:4px solid #fff;width:32px;height:32px;position:absolute;top:-16px;left:50%;margin-left:-16px}.simpay-form-template-explorer-upgrade__discount u{text-decoration:none;font-weight:bold;color:#00a32a}.simpay-form-template-explorer-upgrade__discount a{text-decoration:none} /*# sourceMappingURL=simpay-admin-form-template-explorer.min.css.map*/ \ No newline at end of file diff --git a/includes/core/assets/css/simpay-admin-form-template-explorer.min.css.map b/includes/core/assets/css/simpay-admin-form-template-explorer.min.css.map index 9491cd0f..cfe45bc5 100644 --- a/includes/core/assets/css/simpay-admin-form-template-explorer.min.css.map +++ b/includes/core/assets/css/simpay-admin-form-template-explorer.min.css.map @@ -1 +1 @@ -{"version":3,"sources":["webpack:///./css/admin/form-template-explorer.scss"],"names":[],"mappings":"AAAA,uBAAuB,gCAAgC,yCAAyC,0CAA0C,mDAAmD,0CAA0C,kDAAkD,mCAAmC,mEAAmE,uBAAuB,sCAAsC,wBAAwB,gCAAgC,yCAAyC,0CAA0C,mDAAmD,0CAA0C,mDAAmD,mCAAmC,mEAAmE,wBAAwB,sCAAsC,sBAAsB,gCAAgC,yCAAyC,0CAA0C,kDAAkD,0CAA0C,iDAAiD,mCAAmC,mEAAmE,sBAAsB,sCAAsC,wBAAwB,gCAAgC,wCAAwC,0CAA0C,kDAAkD,0CAA0C,kDAAkD,mCAAmC,mEAAmE,wBAAwB,sCAAsC,2BAA2B,gCAAgC,yCAAyC,0CAA0C,kDAAkD,0CAA0C,kDAAkD,mCAAmC,mEAAmE,2BAA2B,sCAAsC,0BAA0B,gCAAgC,yCAAyC,0CAA0C,mDAAmD,0CAA0C,mDAAmD,mCAAmC,mEAAmE,0BAA0B,sCAAsC,uBAAuB,gCAAgC,0CAA0C,0CAA0C,oDAAoD,0CAA0C,mDAAmD,mCAAmC,mEAAmE,uBAAuB,sCAAsC,yBAAyB,gCAAgC,0CAA0C,0CAA0C,oDAAoD,0CAA0C,oDAAoD,mCAAmC,mEAAmE,yBAAyB,sCAAsC,0BAA0B,mCAAmC,iBAAiB,8TAA8T,wBAAwB,2NAA2N,kBAAkB,uXAAuX,wHAAwH,gBAAgB,6BAA6B,iCAAiC,kBAAkB,yBAAyB,eAAe,mBAAmB,cAAc,4BAA4B,mBAAmB,YAAY,WAAW,YAAY,eAAe,uCAAuC,uXAAuX,uBAAuB,qBAAqB,yBAAyB,uXAAuX,eAAe,oBAAoB,yYAAyY,yCAAyC,iDAAiD,8BAA8B,wcAAwc,yBAAyB,6aAA6a,UAAU,yBAAyB,ybAAyb,yBAAyB,yBAAyB,uXAAuX,gBAAgB,yYAAyY,gBAAgB,iDAAiD,+aAA+a,cAAc,2bAA2b,cAAc,8ZAA8Z,cAAc,60DAA60D,wBAAwB,6OAA6O,kBAAkB,MAAM,WAAW,SAAS,aAAa,mBAAmB,yPAAyP,aAAa,wQAAwQ,kBAAkB,+BAA+B,gBAAgB,yBAAyB,qCAAqC,gBAAgB,gEAAgE,sBAAsB,0BAA0B,+BAA+B,eAAe,UAAU,QAAQ,SAAS,WAAW,iBAAiB,kBAAkB,kBAAkB,uCAAuC,WAAW,0CAA0C,eAAe,+CAA+C,iBAAiB,+BAA+B,aAAa,0BAA0B,+BAA+B,YAAY,cAAc,eAAe,0BAA0B,sCAAsC,kBAAkB,OAAO,QAAQ,yBAAyB,kBAAkB,aAAa,gBAAgB,WAAW,6CAA6C,eAAe,gBAAgB,SAAS,gDAAgD,WAAW,eAAe,eAAe,oCAAoC,gBAAgB,6CAA6C,mBAAmB,YAAY,oDAAoD,mBAAmB,0BAA0B,oDAAoD,oBAAoB,0BAA0B,wDAAwD,aAAa,uBAAuB,sFAAsF,6CAA6C,6CAA6C,iBAAiB,aAAa,cAAc,0BAA0B,qCAAqC,YAAY,yBAAyB,4DAA4D,qCAAqC,iDAAiD,yBAAyB,4DAA4D,qCAAqC,iDAAiD,uDAAuD,gBAAgB,aAAa,kBAAkB,sBAAsB,kBAAkB,6BAA6B,WAAW,YAAY,iBAAiB,sBAAsB,uBAAuB,8LAA8L,qBAAqB,6BAA6B,aAAa,0YAA0Y,UAAU,8XAA8X,UAAU,6DAA6D,eAAe,gBAAgB,iBAAiB,gBAAgB,kBAAkB,uBAAuB,mBAAmB,wEAAwE,mBAAmB,oEAAoE,WAAW,eAAe,iBAAiB,gBAAgB,gBAAgB,gBAAgB,UAAU,gEAAgE,sBAAsB,kBAAkB,aAAa,8BAA8B,mBAAmB,aAAa,kBAAkB,MAAM,QAAQ,SAAS,OAAO,WAAW,YAAY,UAAU,6BAA6B,yBAAyB,gEAAgE,oBAAoB,SAAS,aAAa,mFAAmF,uBAAuB,aAAa,8DAA8D,gBAAgB,YAAY,kBAAkB,WAAW,SAAS,UAAU,kEAAkE,UAAU,qDAAqD,cAAc,aAAa,iBAAiB,aAAa,uBAAuB,sBAAsB,kBAAkB,qCAAqC,yDAAyD,iBAAiB,yDAAyD,kBAAkB,cAAc,gBAAgB,wDAAwD,SAAS,eAAe,uDAAuD,WAAW,eAAe,0BAA0B,oCAAoC,iBAAiB,6CAA6C,UAAU,SAAS,UAAU,kBAAkB,gBAAgB,kBAAkB,YAAY,6CAA6C,kBAAkB,gBAAgB,mBAAmB,uCAAuC,gBAAgB,yCAAyC,sBAAsB,gDAAgD,kBAAkB,aAAa,sBAAsB,mBAAmB,8CAA8C,eAAe,gBAAgB,cAAc,gBAAgB,oDAAoD,WAAW,eAAe,mBAAmB,2DAA2D,cAAc,qEAAqE,eAAe,iBAAiB,gBAAgB,6BAA6B,YAAY,kDAAkD,WAAW,qBAAqB,aAAa,iDAAiD,eAAe,kBAAkB,wBAAwB,uBAAuB,8BAA8B,+BAA+B,yBAAyB,kBAAkB,qDAAqD,mBAAmB,UAAU,kBAAkB,sBAAsB,WAAW,YAAY,kBAAkB,UAAU,SAAS,kBAAkB,mDAAmD,qBAAqB,iBAAiB,cAAc,mDAAmD,qB","file":"./../css/simpay-admin-form-template-explorer.min.css","sourcesContent":["body.admin-color-light{--wp-admin-theme-color: #0085ba;--wp-admin-theme-color--rgb: 0, 133, 186;--wp-admin-theme-color-darker-10: #0073a1;--wp-admin-theme-color-darker-10--rgb: 0, 115, 161;--wp-admin-theme-color-darker-20: #006187;--wp-admin-theme-color-darker-20--rgb: 0, 97, 135;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-light{--wp-admin-border-width-focus: 1.5px}}body.admin-color-modern{--wp-admin-theme-color: #3858e9;--wp-admin-theme-color--rgb: 56, 88, 233;--wp-admin-theme-color-darker-10: #2145e6;--wp-admin-theme-color-darker-10--rgb: 33, 69, 230;--wp-admin-theme-color-darker-20: #183ad6;--wp-admin-theme-color-darker-20--rgb: 24, 58, 214;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-modern{--wp-admin-border-width-focus: 1.5px}}body.admin-color-blue{--wp-admin-theme-color: #096484;--wp-admin-theme-color--rgb: 9, 100, 132;--wp-admin-theme-color-darker-10: #07526c;--wp-admin-theme-color-darker-10--rgb: 7, 82, 108;--wp-admin-theme-color-darker-20: #064054;--wp-admin-theme-color-darker-20--rgb: 6, 64, 84;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-blue{--wp-admin-border-width-focus: 1.5px}}body.admin-color-coffee{--wp-admin-theme-color: #46403c;--wp-admin-theme-color--rgb: 70, 64, 60;--wp-admin-theme-color-darker-10: #383330;--wp-admin-theme-color-darker-10--rgb: 56, 51, 48;--wp-admin-theme-color-darker-20: #2b2724;--wp-admin-theme-color-darker-20--rgb: 43, 39, 36;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-coffee{--wp-admin-border-width-focus: 1.5px}}body.admin-color-ectoplasm{--wp-admin-theme-color: #523f6d;--wp-admin-theme-color--rgb: 82, 63, 109;--wp-admin-theme-color-darker-10: #46365d;--wp-admin-theme-color-darker-10--rgb: 70, 54, 93;--wp-admin-theme-color-darker-20: #3a2c4d;--wp-admin-theme-color-darker-20--rgb: 58, 44, 77;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-ectoplasm{--wp-admin-border-width-focus: 1.5px}}body.admin-color-midnight{--wp-admin-theme-color: #e14d43;--wp-admin-theme-color--rgb: 225, 77, 67;--wp-admin-theme-color-darker-10: #dd382d;--wp-admin-theme-color-darker-10--rgb: 221, 56, 45;--wp-admin-theme-color-darker-20: #d02c21;--wp-admin-theme-color-darker-20--rgb: 208, 44, 33;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-midnight{--wp-admin-border-width-focus: 1.5px}}body.admin-color-ocean{--wp-admin-theme-color: #627c83;--wp-admin-theme-color--rgb: 98, 124, 131;--wp-admin-theme-color-darker-10: #576e74;--wp-admin-theme-color-darker-10--rgb: 87, 110, 116;--wp-admin-theme-color-darker-20: #4c6066;--wp-admin-theme-color-darker-20--rgb: 76, 96, 102;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-ocean{--wp-admin-border-width-focus: 1.5px}}body.admin-color-sunrise{--wp-admin-theme-color: #dd823b;--wp-admin-theme-color--rgb: 221, 130, 59;--wp-admin-theme-color-darker-10: #d97426;--wp-admin-theme-color-darker-10--rgb: 217, 116, 38;--wp-admin-theme-color-darker-20: #c36922;--wp-admin-theme-color-darker-20--rgb: 195, 105, 34;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-sunrise{--wp-admin-border-width-focus: 1.5px}}@media(min-width: 1440px){body.simpay-template-explorer-open{overflow:hidden}}body.simpay-template-explorer-open .simpay-admin-notice-top-of-page.simpay-notice,body.simpay-template-explorer-open .notice,body.simpay-template-explorer-open #screen-meta,body.simpay-template-explorer-open #screen-meta-links,body.simpay-template-explorer-open #poststuff,body.simpay-template-explorer-open #wpfooter{display:none !important}body.simpay-template-explorer-open.branch-5-6 .components-search-control,body.simpay-template-explorer-open.branch-5-7 .components-search-control,body.simpay-template-explorer-open.branch-5-8 .components-search-control{position:relative}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input{font-family:-apple-system,BlinkMacSystemFont,\"Segoe UI\",Roboto,Oxygen-Sans,Ubuntu,Cantarell,\"Helvetica Neue\",sans-serif;padding:6px 8px;box-shadow:0 0 0 transparent;transition:box-shadow .1s linear;border-radius:2px;border:1px solid #757575;font-size:16px;line-height:normal;display:block;padding:16px 48px 16px 16px;background:#f0f0f0;border:none;width:100%;height:48px;font-size:16px}@media(prefers-reduced-motion: reduce){body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input{transition-duration:0s;transition-delay:0s}}@media(min-width: 600px){body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input{font-size:13px;line-height:normal}}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input:focus,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input:focus,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input:focus{border-color:var(--wp-admin-theme-color);box-shadow:0 0 0 1px var(--wp-admin-theme-color);outline:2px solid transparent}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::-webkit-input-placeholder,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::-webkit-input-placeholder,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::-webkit-input-placeholder{color:rgba(30,30,30,.62)}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::-moz-placeholder,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::-moz-placeholder,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::-moz-placeholder{opacity:1;color:rgba(30,30,30,.62)}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input:-ms-input-placeholder,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input:-ms-input-placeholder,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input:-ms-input-placeholder{color:rgba(30,30,30,.62)}@media(min-width: 600px){body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input{font-size:13px}}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input:focus,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input:focus,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input:focus{background:#fff;box-shadow:0 0 0 2px var(--wp-admin-theme-color)}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::-moz-placeholder, body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::-moz-placeholder, body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::-moz-placeholder{color:#757575}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input:-ms-input-placeholder, body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input:-ms-input-placeholder, body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input:-ms-input-placeholder{color:#757575}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::placeholder,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::placeholder,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::placeholder{color:#757575}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::-webkit-search-decoration,body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::-webkit-search-cancel-button,body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::-webkit-search-results-button,body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::-webkit-search-results-decoration,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::-webkit-search-decoration,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::-webkit-search-cancel-button,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::-webkit-search-results-button,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::-webkit-search-results-decoration,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::-webkit-search-decoration,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::-webkit-search-cancel-button,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::-webkit-search-results-button,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::-webkit-search-results-decoration{-webkit-appearance:none}body.simpay-template-explorer-open.branch-5-6 .components-search-control__icon,body.simpay-template-explorer-open.branch-5-7 .components-search-control__icon,body.simpay-template-explorer-open.branch-5-8 .components-search-control__icon{position:absolute;top:0;right:12px;bottom:0;display:flex;align-items:center}body.simpay-template-explorer-open.branch-5-6 .components-search-control__icon>svg,body.simpay-template-explorer-open.branch-5-7 .components-search-control__icon>svg,body.simpay-template-explorer-open.branch-5-8 .components-search-control__icon>svg{margin:8px 0}body.simpay-template-explorer-open.branch-5-6 .components-search-control__input-wrapper,body.simpay-template-explorer-open.branch-5-7 .components-search-control__input-wrapper,body.simpay-template-explorer-open.branch-5-8 .components-search-control__input-wrapper{position:relative}#simpay-form-template-explorer{background:#fff;border:1px solid #c3c4c7;box-shadow:0 1px 1px rgba(0,0,0,.04);margin-top:10px}#simpay-form-template-explorer,#simpay-form-template-explorer *{box-sizing:border-box}@media(min-width: 1440px){#simpay-form-template-explorer{position:fixed;top:111px;right:0;bottom:0;left:160px;margin:20px 22px;overflow-x:hidden;overflow-y:scroll}.folded #simpay-form-template-explorer{left:36px}}#simpay-form-template-explorer #wpcontent{padding-left:0}#simpay-form-template-explorer #wpbody-content{padding-bottom:0}.simpay-form-template-explorer{padding:24px}@media(min-width: 1440px){.simpay-form-template-explorer{height:100%;overflow:auto;padding-top:0}}@media(min-width: 1440px){.simpay-form-template-explorer-header{position:absolute;left:0;right:0;padding:24px 0 24px 24px;margin-right:24px;height:100px;background:#fff;z-index:2}}.simpay-form-template-explorer-header__title{font-size:22px;font-weight:400;margin:0}.simpay-form-template-explorer-header__subtitle{color:#555;font-size:15px;margin:8px 0 0}.simpay-form-template-explorer-main{margin-top:24px}.simpay-form-template-explorer-main__sidebar{margin-bottom:24px;padding:2px}.simpay-form-template-explorer-main__sidebar-search{margin-bottom:12px}@media(min-width: 1440px){.simpay-form-template-explorer-main__sidebar-search{margin-bottom:24px}}@media(min-width: 1440px){.simpay-form-template-explorer-main__sidebar-categories{display:flex;flex-direction:column}}.simpay-form-template-explorer-main__sidebar-categories .components-button.is-pressed{background-color:var(--wp-admin-theme-color)}.simpay-form-template-explorer-main__content{display:-ms-grid;display:grid;grid-gap:24px;-ms-grid-columns:(1fr)[1];grid-template-columns:repeat(1, 1fr);padding:2px}@media(min-width: 782px){.simpay-form-template-explorer-main__content:not(.is-empty){-ms-grid-columns:(minmax(0, 1fr))[2];grid-template-columns:repeat(2, minmax(0, 1fr))}}@media(min-width: 960px){.simpay-form-template-explorer-main__content:not(.is-empty){-ms-grid-columns:(minmax(0, 1fr))[3];grid-template-columns:repeat(3, minmax(0, 1fr))}}.simpay-form-template-explorer-main__content-list-item{text-align:left;padding:16px;border-radius:4px;border:1px solid #ddd;position:relative;transition:all .15s ease-out;width:100%;height:auto;min-height:100px;flex-direction:column;align-items:flex-start}.simpay-form-template-explorer-main__content-list-item:focus-within,.simpay-form-template-explorer-main__content-list-item:focus,.simpay-form-template-explorer-main__content-list-item:hover{border-color:#1e1e1e;box-shadow:0 0 0 1px #1e1e1e;outline:none}.simpay-form-template-explorer-main__content-list-item:focus-within .simpay-form-template-explorer-main__content-list-item__description,.simpay-form-template-explorer-main__content-list-item:focus .simpay-form-template-explorer-main__content-list-item__description,.simpay-form-template-explorer-main__content-list-item:hover .simpay-form-template-explorer-main__content-list-item__description{opacity:0}.simpay-form-template-explorer-main__content-list-item:focus-within .simpay-form-template-explorer-main__content-list-item__actions,.simpay-form-template-explorer-main__content-list-item:focus .simpay-form-template-explorer-main__content-list-item__actions,.simpay-form-template-explorer-main__content-list-item:hover .simpay-form-template-explorer-main__content-list-item__actions{opacity:1}.simpay-form-template-explorer-main__content-list-item__name{font-size:16px;font-weight:600;line-height:21px;overflow:hidden;position:relative;text-overflow:ellipsis;white-space:nowrap}.simpay-form-template-explorer-main__content-list-item__name--is-locked{padding-right:30px}.simpay-form-template-explorer-main__content-list-item__description{color:#777;font-size:14px;line-height:18px;margin:10px 0 0;max-height:53px;overflow:hidden;opacity:1}.simpay-form-template-explorer-main__content-list-item__actions{background-color:#fff;border-radius:4px;display:flex;justify-content:space-between;align-items:center;padding:16px;position:absolute;top:0;right:0;bottom:0;left:0;width:100%;height:100%;opacity:0;transition:all .15s ease-out}@media(min-width: 782px){.simpay-form-template-explorer-main__content-list-item__actions{padding:0 16px 16px;top:auto;height:auto}}.simpay-form-template-explorer-main__content-list-item__actions .components-button{justify-content:center;flex:1 1 48%}.simpay-form-template-explorer-main__content-list-item__badge{background:#fff;padding:4px;position:absolute;right:10px;top:14px;z-index:2}.simpay-form-template-explorer-main__content-list-item__badge svg{fill:#777}.simpay-form-template-explorer-main__content-suggest{color:#1d2327;padding:24px;grid-column:1/-1;display:flex;align-items:flex-start;border:1px solid #ddd;border-radius:4px;box-shadow:0 1px 2px rgba(0,0,0,.06)}.simpay-form-template-explorer-main__content-suggest>div{margin-left:16px}.simpay-form-template-explorer-main__content-suggest svg{fill:currentColor;flex:1 0 auto;margin-top:-6px}.simpay-form-template-explorer-main__content-suggest h4{margin:0;font-size:20px}.simpay-form-template-explorer-main__content-suggest p{color:#555;font-size:14px}@media(min-width: 1440px){.simpay-form-template-explorer-main{margin-top:100px}.simpay-form-template-explorer-main__sidebar{top:100px;bottom:0;left:24px;overflow-x:hidden;overflow-y:auto;position:absolute;width:280px}.simpay-form-template-explorer-main__content{overflow-x:hidden;overflow-y:auto;margin-left:300px}}.simpay-form-template-explorer-upgrade{max-width:600px}.simpay-form-template-explorer-upgrade *{box-sizing:border-box}.simpay-form-template-explorer-upgrade__content{text-align:center;display:flex;flex-direction:column;align-items:center}.simpay-form-template-explorer-upgrade__title{font-size:22px;line-height:1.5;display:block;margin:12px 0 0}.simpay-form-template-explorer-upgrade__description{color:#777;font-size:16px;margin:16px 0 24px}.simpay-form-template-explorer-upgrade__description strong{color:#1d2327}.simpay-form-template-explorer-upgrade .components-button.is-primary{font-size:16px;font-weight:bold;margin:0 0 15px;padding:15px 30px !important;height:auto}.simpay-form-template-explorer-upgrade__purchased{color:#555;display:inline-block;margin:8px 0}.simpay-form-template-explorer-upgrade__discount{font-size:15px;text-align:center;margin:24px -32px -24px;padding:32px 40px 24px;border-bottom-left-radius:2px;border-bottom-right-radius:2px;background-color:#fcf9e8;position:relative}.simpay-form-template-explorer-upgrade__discount svg{background:#00a32a;fill:#fff;border-radius:50%;border:4px solid #fff;width:32px;height:32px;position:absolute;top:-16px;left:50%;margin-left:-16px}.simpay-form-template-explorer-upgrade__discount u{text-decoration:none;font-weight:bold;color:#00a32a}.simpay-form-template-explorer-upgrade__discount a{text-decoration:none}"],"sourceRoot":""} \ No newline at end of file +{"version":3,"sources":["webpack:///./css/admin/form-template-explorer.scss"],"names":[],"mappings":"AAAA,uBAAuB,gCAAgC,yCAAyC,0CAA0C,mDAAmD,0CAA0C,kDAAkD,mCAAmC,mEAAmE,uBAAuB,sCAAsC,wBAAwB,gCAAgC,yCAAyC,0CAA0C,mDAAmD,0CAA0C,mDAAmD,mCAAmC,mEAAmE,wBAAwB,sCAAsC,sBAAsB,gCAAgC,yCAAyC,0CAA0C,kDAAkD,0CAA0C,iDAAiD,mCAAmC,mEAAmE,sBAAsB,sCAAsC,wBAAwB,gCAAgC,wCAAwC,0CAA0C,kDAAkD,0CAA0C,kDAAkD,mCAAmC,mEAAmE,wBAAwB,sCAAsC,2BAA2B,gCAAgC,yCAAyC,0CAA0C,kDAAkD,0CAA0C,kDAAkD,mCAAmC,mEAAmE,2BAA2B,sCAAsC,0BAA0B,gCAAgC,yCAAyC,0CAA0C,mDAAmD,0CAA0C,mDAAmD,mCAAmC,mEAAmE,0BAA0B,sCAAsC,uBAAuB,gCAAgC,0CAA0C,0CAA0C,oDAAoD,0CAA0C,mDAAmD,mCAAmC,mEAAmE,uBAAuB,sCAAsC,yBAAyB,gCAAgC,0CAA0C,0CAA0C,oDAAoD,0CAA0C,oDAAoD,mCAAmC,mEAAmE,yBAAyB,sCAAsC,0BAA0B,mCAAmC,iBAAiB,8TAA8T,wBAAwB,2NAA2N,kBAAkB,uXAAuX,wHAAwH,gBAAgB,6BAA6B,iCAAiC,kBAAkB,yBAAyB,eAAe,mBAAmB,cAAc,4BAA4B,mBAAmB,YAAY,WAAW,YAAY,eAAe,uCAAuC,uXAAuX,uBAAuB,qBAAqB,yBAAyB,uXAAuX,eAAe,oBAAoB,yYAAyY,yCAAyC,iDAAiD,8BAA8B,wcAAwc,yBAAyB,6aAA6a,UAAU,yBAAyB,ybAAyb,yBAAyB,yBAAyB,uXAAuX,gBAAgB,yYAAyY,gBAAgB,iDAAiD,+aAA+a,cAAc,2bAA2b,cAAc,8ZAA8Z,cAAc,60DAA60D,wBAAwB,6OAA6O,kBAAkB,MAAM,WAAW,SAAS,aAAa,mBAAmB,yPAAyP,aAAa,wQAAwQ,kBAAkB,+BAA+B,gBAAgB,yBAAyB,qCAAqC,gBAAgB,gEAAgE,sBAAsB,0BAA0B,+BAA+B,eAAe,UAAU,QAAQ,SAAS,WAAW,iBAAiB,kBAAkB,kBAAkB,uCAAuC,WAAW,0CAA0C,eAAe,+CAA+C,iBAAiB,+BAA+B,aAAa,0BAA0B,+BAA+B,YAAY,cAAc,eAAe,0BAA0B,sCAAsC,kBAAkB,uBAAuB,WAAW,gBAAgB,gCAAgC,qCAAqC,kBAAkB,OAAO,QAAQ,WAAW,6CAA6C,eAAe,SAAS,gDAAgD,WAAW,eAAe,gBAAgB,oCAAoC,gBAAgB,6CAA6C,mBAAmB,YAAY,oDAAoD,mBAAmB,0BAA0B,oDAAoD,oBAAoB,0BAA0B,wDAAwD,aAAa,uBAAuB,sFAAsF,6CAA6C,8EAA8E,iBAAiB,6CAA6C,iBAAiB,aAAa,cAAc,0BAA0B,qCAAqC,YAAY,yBAAyB,4DAA4D,qCAAqC,iDAAiD,yBAAyB,4DAA4D,qCAAqC,iDAAiD,uDAAuD,gBAAgB,aAAa,kBAAkB,sBAAsB,kBAAkB,6BAA6B,WAAW,YAAY,iBAAiB,sBAAsB,uBAAuB,8LAA8L,qBAAqB,6BAA6B,aAAa,0YAA0Y,UAAU,8XAA8X,UAAU,6DAA6D,eAAe,gBAAgB,iBAAiB,gBAAgB,kBAAkB,uBAAuB,mBAAmB,wEAAwE,mBAAmB,oEAAoE,WAAW,eAAe,iBAAiB,gBAAgB,gBAAgB,gBAAgB,UAAU,gEAAgE,sBAAsB,kBAAkB,aAAa,8BAA8B,mBAAmB,aAAa,kBAAkB,MAAM,QAAQ,SAAS,OAAO,WAAW,YAAY,UAAU,6BAA6B,yBAAyB,gEAAgE,oBAAoB,SAAS,aAAa,mFAAmF,uBAAuB,aAAa,8DAA8D,gBAAgB,YAAY,kBAAkB,WAAW,SAAS,UAAU,kEAAkE,UAAU,qDAAqD,cAAc,aAAa,iBAAiB,aAAa,uBAAuB,sBAAsB,kBAAkB,qCAAqC,yDAAyD,iBAAiB,yDAAyD,kBAAkB,cAAc,gBAAgB,wDAAwD,SAAS,eAAe,uDAAuD,WAAW,eAAe,qDAAqD,cAAc,aAAa,iBAAiB,aAAa,mBAAmB,8BAA8B,mBAAmB,yBAAyB,kBAAkB,0CAA0C,yDAAyD,kBAAkB,wDAAwD,eAAe,SAAS,uDAAuD,WAAW,eAAe,eAAe,0BAA0B,oCAAoC,iBAAiB,6CAA6C,UAAU,SAAS,UAAU,kBAAkB,gBAAgB,kBAAkB,YAAY,6CAA6C,kBAAkB,gBAAgB,mBAAmB,uCAAuC,gBAAgB,yCAAyC,sBAAsB,gDAAgD,kBAAkB,aAAa,sBAAsB,mBAAmB,8CAA8C,eAAe,gBAAgB,cAAc,gBAAgB,oDAAoD,WAAW,eAAe,mBAAmB,2DAA2D,cAAc,qEAAqE,eAAe,iBAAiB,gBAAgB,6BAA6B,YAAY,kDAAkD,WAAW,qBAAqB,aAAa,iDAAiD,eAAe,kBAAkB,wBAAwB,uBAAuB,8BAA8B,+BAA+B,yBAAyB,kBAAkB,qDAAqD,mBAAmB,UAAU,kBAAkB,sBAAsB,WAAW,YAAY,kBAAkB,UAAU,SAAS,kBAAkB,mDAAmD,qBAAqB,iBAAiB,cAAc,mDAAmD,qB","file":"./../css/simpay-admin-form-template-explorer.min.css","sourcesContent":["body.admin-color-light{--wp-admin-theme-color: #0085ba;--wp-admin-theme-color--rgb: 0, 133, 186;--wp-admin-theme-color-darker-10: #0073a1;--wp-admin-theme-color-darker-10--rgb: 0, 115, 161;--wp-admin-theme-color-darker-20: #006187;--wp-admin-theme-color-darker-20--rgb: 0, 97, 135;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-light{--wp-admin-border-width-focus: 1.5px}}body.admin-color-modern{--wp-admin-theme-color: #3858e9;--wp-admin-theme-color--rgb: 56, 88, 233;--wp-admin-theme-color-darker-10: #2145e6;--wp-admin-theme-color-darker-10--rgb: 33, 69, 230;--wp-admin-theme-color-darker-20: #183ad6;--wp-admin-theme-color-darker-20--rgb: 24, 58, 214;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-modern{--wp-admin-border-width-focus: 1.5px}}body.admin-color-blue{--wp-admin-theme-color: #096484;--wp-admin-theme-color--rgb: 9, 100, 132;--wp-admin-theme-color-darker-10: #07526c;--wp-admin-theme-color-darker-10--rgb: 7, 82, 108;--wp-admin-theme-color-darker-20: #064054;--wp-admin-theme-color-darker-20--rgb: 6, 64, 84;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-blue{--wp-admin-border-width-focus: 1.5px}}body.admin-color-coffee{--wp-admin-theme-color: #46403c;--wp-admin-theme-color--rgb: 70, 64, 60;--wp-admin-theme-color-darker-10: #383330;--wp-admin-theme-color-darker-10--rgb: 56, 51, 48;--wp-admin-theme-color-darker-20: #2b2724;--wp-admin-theme-color-darker-20--rgb: 43, 39, 36;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-coffee{--wp-admin-border-width-focus: 1.5px}}body.admin-color-ectoplasm{--wp-admin-theme-color: #523f6d;--wp-admin-theme-color--rgb: 82, 63, 109;--wp-admin-theme-color-darker-10: #46365d;--wp-admin-theme-color-darker-10--rgb: 70, 54, 93;--wp-admin-theme-color-darker-20: #3a2c4d;--wp-admin-theme-color-darker-20--rgb: 58, 44, 77;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-ectoplasm{--wp-admin-border-width-focus: 1.5px}}body.admin-color-midnight{--wp-admin-theme-color: #e14d43;--wp-admin-theme-color--rgb: 225, 77, 67;--wp-admin-theme-color-darker-10: #dd382d;--wp-admin-theme-color-darker-10--rgb: 221, 56, 45;--wp-admin-theme-color-darker-20: #d02c21;--wp-admin-theme-color-darker-20--rgb: 208, 44, 33;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-midnight{--wp-admin-border-width-focus: 1.5px}}body.admin-color-ocean{--wp-admin-theme-color: #627c83;--wp-admin-theme-color--rgb: 98, 124, 131;--wp-admin-theme-color-darker-10: #576e74;--wp-admin-theme-color-darker-10--rgb: 87, 110, 116;--wp-admin-theme-color-darker-20: #4c6066;--wp-admin-theme-color-darker-20--rgb: 76, 96, 102;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-ocean{--wp-admin-border-width-focus: 1.5px}}body.admin-color-sunrise{--wp-admin-theme-color: #dd823b;--wp-admin-theme-color--rgb: 221, 130, 59;--wp-admin-theme-color-darker-10: #d97426;--wp-admin-theme-color-darker-10--rgb: 217, 116, 38;--wp-admin-theme-color-darker-20: #c36922;--wp-admin-theme-color-darker-20--rgb: 195, 105, 34;--wp-admin-border-width-focus: 2px}@media(-webkit-min-device-pixel-ratio: 2),(min-resolution: 192dpi){body.admin-color-sunrise{--wp-admin-border-width-focus: 1.5px}}@media(min-width: 1440px){body.simpay-template-explorer-open{overflow:hidden}}body.simpay-template-explorer-open .simpay-admin-notice-top-of-page.simpay-notice,body.simpay-template-explorer-open .notice,body.simpay-template-explorer-open #screen-meta,body.simpay-template-explorer-open #screen-meta-links,body.simpay-template-explorer-open #poststuff,body.simpay-template-explorer-open #wpfooter{display:none !important}body.simpay-template-explorer-open.branch-5-6 .components-search-control,body.simpay-template-explorer-open.branch-5-7 .components-search-control,body.simpay-template-explorer-open.branch-5-8 .components-search-control{position:relative}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input{font-family:-apple-system,BlinkMacSystemFont,\"Segoe UI\",Roboto,Oxygen-Sans,Ubuntu,Cantarell,\"Helvetica Neue\",sans-serif;padding:6px 8px;box-shadow:0 0 0 transparent;transition:box-shadow .1s linear;border-radius:2px;border:1px solid #757575;font-size:16px;line-height:normal;display:block;padding:16px 48px 16px 16px;background:#f0f0f0;border:none;width:100%;height:48px;font-size:16px}@media(prefers-reduced-motion: reduce){body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input{transition-duration:0s;transition-delay:0s}}@media(min-width: 600px){body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input{font-size:13px;line-height:normal}}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input:focus,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input:focus,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input:focus{border-color:var(--wp-admin-theme-color);box-shadow:0 0 0 1px var(--wp-admin-theme-color);outline:2px solid transparent}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::-webkit-input-placeholder,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::-webkit-input-placeholder,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::-webkit-input-placeholder{color:rgba(30,30,30,.62)}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::-moz-placeholder,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::-moz-placeholder,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::-moz-placeholder{opacity:1;color:rgba(30,30,30,.62)}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input:-ms-input-placeholder,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input:-ms-input-placeholder,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input:-ms-input-placeholder{color:rgba(30,30,30,.62)}@media(min-width: 600px){body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input{font-size:13px}}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input:focus,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input:focus,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input:focus{background:#fff;box-shadow:0 0 0 2px var(--wp-admin-theme-color)}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::-moz-placeholder, body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::-moz-placeholder, body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::-moz-placeholder{color:#757575}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input:-ms-input-placeholder, body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input:-ms-input-placeholder, body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input:-ms-input-placeholder{color:#757575}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::placeholder,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::placeholder,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::placeholder{color:#757575}body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::-webkit-search-decoration,body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::-webkit-search-cancel-button,body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::-webkit-search-results-button,body.simpay-template-explorer-open.branch-5-6 .components-search-control input[type=search].components-search-control__input::-webkit-search-results-decoration,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::-webkit-search-decoration,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::-webkit-search-cancel-button,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::-webkit-search-results-button,body.simpay-template-explorer-open.branch-5-7 .components-search-control input[type=search].components-search-control__input::-webkit-search-results-decoration,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::-webkit-search-decoration,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::-webkit-search-cancel-button,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::-webkit-search-results-button,body.simpay-template-explorer-open.branch-5-8 .components-search-control input[type=search].components-search-control__input::-webkit-search-results-decoration{-webkit-appearance:none}body.simpay-template-explorer-open.branch-5-6 .components-search-control__icon,body.simpay-template-explorer-open.branch-5-7 .components-search-control__icon,body.simpay-template-explorer-open.branch-5-8 .components-search-control__icon{position:absolute;top:0;right:12px;bottom:0;display:flex;align-items:center}body.simpay-template-explorer-open.branch-5-6 .components-search-control__icon>svg,body.simpay-template-explorer-open.branch-5-7 .components-search-control__icon>svg,body.simpay-template-explorer-open.branch-5-8 .components-search-control__icon>svg{margin:8px 0}body.simpay-template-explorer-open.branch-5-6 .components-search-control__input-wrapper,body.simpay-template-explorer-open.branch-5-7 .components-search-control__input-wrapper,body.simpay-template-explorer-open.branch-5-8 .components-search-control__input-wrapper{position:relative}#simpay-form-template-explorer{background:#fff;border:1px solid #c3c4c7;box-shadow:0 1px 1px rgba(0,0,0,.04);margin-top:10px}#simpay-form-template-explorer,#simpay-form-template-explorer *{box-sizing:border-box}@media(min-width: 1440px){#simpay-form-template-explorer{position:fixed;top:111px;right:0;bottom:0;left:160px;margin:20px 22px;overflow-x:hidden;overflow-y:scroll}.folded #simpay-form-template-explorer{left:36px}}#simpay-form-template-explorer #wpcontent{padding-left:0}#simpay-form-template-explorer #wpbody-content{padding-bottom:0}.simpay-form-template-explorer{padding:24px}@media(min-width: 1440px){.simpay-form-template-explorer{height:100%;overflow:auto;padding-top:0}}@media(min-width: 1440px){.simpay-form-template-explorer-header{margin-right:24px;padding:30px 30px 25px;width:100%;background:#fff;border-bottom:1px solid #c3c4c7;box-shadow:0 1px 1px rgba(0,0,0,.04);position:absolute;left:0;right:0;z-index:3}}.simpay-form-template-explorer-header__title{font-size:26px;margin:0}.simpay-form-template-explorer-header__subtitle{color:#555;font-size:15px;margin:16px 0 0}.simpay-form-template-explorer-main{margin-top:24px}.simpay-form-template-explorer-main__sidebar{margin-bottom:24px;padding:2px}.simpay-form-template-explorer-main__sidebar-search{margin-bottom:12px}@media(min-width: 1440px){.simpay-form-template-explorer-main__sidebar-search{margin-bottom:24px}}@media(min-width: 1440px){.simpay-form-template-explorer-main__sidebar-categories{display:flex;flex-direction:column}}.simpay-form-template-explorer-main__sidebar-categories .components-button.is-pressed{background-color:var(--wp-admin-theme-color)}.simpay-form-template-explorer-main__sidebar-categories_category.category-new{font-weight:bold}.simpay-form-template-explorer-main__content{display:-ms-grid;display:grid;grid-gap:24px;-ms-grid-columns:(1fr)[1];grid-template-columns:repeat(1, 1fr);padding:2px}@media(min-width: 782px){.simpay-form-template-explorer-main__content:not(.is-empty){-ms-grid-columns:(minmax(0, 1fr))[2];grid-template-columns:repeat(2, minmax(0, 1fr))}}@media(min-width: 960px){.simpay-form-template-explorer-main__content:not(.is-empty){-ms-grid-columns:(minmax(0, 1fr))[3];grid-template-columns:repeat(3, minmax(0, 1fr))}}.simpay-form-template-explorer-main__content-list-item{text-align:left;padding:16px;border-radius:4px;border:1px solid #ddd;position:relative;transition:all .15s ease-out;width:100%;height:auto;min-height:100px;flex-direction:column;align-items:flex-start}.simpay-form-template-explorer-main__content-list-item:focus-within,.simpay-form-template-explorer-main__content-list-item:focus,.simpay-form-template-explorer-main__content-list-item:hover{border-color:#1e1e1e;box-shadow:0 0 0 1px #1e1e1e;outline:none}.simpay-form-template-explorer-main__content-list-item:focus-within .simpay-form-template-explorer-main__content-list-item__description,.simpay-form-template-explorer-main__content-list-item:focus .simpay-form-template-explorer-main__content-list-item__description,.simpay-form-template-explorer-main__content-list-item:hover .simpay-form-template-explorer-main__content-list-item__description{opacity:0}.simpay-form-template-explorer-main__content-list-item:focus-within .simpay-form-template-explorer-main__content-list-item__actions,.simpay-form-template-explorer-main__content-list-item:focus .simpay-form-template-explorer-main__content-list-item__actions,.simpay-form-template-explorer-main__content-list-item:hover .simpay-form-template-explorer-main__content-list-item__actions{opacity:1}.simpay-form-template-explorer-main__content-list-item__name{font-size:16px;font-weight:600;line-height:21px;overflow:hidden;position:relative;text-overflow:ellipsis;white-space:nowrap}.simpay-form-template-explorer-main__content-list-item__name--is-locked{padding-right:30px}.simpay-form-template-explorer-main__content-list-item__description{color:#777;font-size:14px;line-height:18px;margin:10px 0 0;max-height:53px;overflow:hidden;opacity:1}.simpay-form-template-explorer-main__content-list-item__actions{background-color:#fff;border-radius:4px;display:flex;justify-content:space-between;align-items:center;padding:16px;position:absolute;top:0;right:0;bottom:0;left:0;width:100%;height:100%;opacity:0;transition:all .15s ease-out}@media(min-width: 782px){.simpay-form-template-explorer-main__content-list-item__actions{padding:0 16px 16px;top:auto;height:auto}}.simpay-form-template-explorer-main__content-list-item__actions .components-button{justify-content:center;flex:1 1 48%}.simpay-form-template-explorer-main__content-list-item__badge{background:#fff;padding:4px;position:absolute;right:10px;top:14px;z-index:2}.simpay-form-template-explorer-main__content-list-item__badge svg{fill:#777}.simpay-form-template-explorer-main__content-suggest{color:#1d2327;padding:24px;grid-column:1/-1;display:flex;align-items:flex-start;border:1px solid #ddd;border-radius:4px;box-shadow:0 1px 2px rgba(0,0,0,.06)}.simpay-form-template-explorer-main__content-suggest>div{margin-left:16px}.simpay-form-template-explorer-main__content-suggest svg{fill:currentColor;flex:1 0 auto;margin-top:-6px}.simpay-form-template-explorer-main__content-suggest h4{margin:0;font-size:20px}.simpay-form-template-explorer-main__content-suggest p{color:#555;font-size:14px}.simpay-form-template-explorer-main__content-upgrade{color:#1d2327;padding:32px;grid-column:1/-1;display:flex;align-items:center;justify-content:space-between;background:#fafcfe;border:1px solid #dce9f6;border-radius:4px;box-shadow:0 1px 3px rgba(66,139,202,.08)}.simpay-form-template-explorer-main__content-upgrade>div{margin-right:50px}.simpay-form-template-explorer-main__content-upgrade h4{font-size:18px;margin:0}.simpay-form-template-explorer-main__content-upgrade p{color:#555;font-size:14px;margin:8px 0 0}@media(min-width: 1440px){.simpay-form-template-explorer-main{margin-top:130px}.simpay-form-template-explorer-main__sidebar{top:130px;bottom:0;left:24px;overflow-x:hidden;overflow-y:auto;position:absolute;width:280px}.simpay-form-template-explorer-main__content{overflow-x:hidden;overflow-y:auto;margin-left:300px}}.simpay-form-template-explorer-upgrade{max-width:600px}.simpay-form-template-explorer-upgrade *{box-sizing:border-box}.simpay-form-template-explorer-upgrade__content{text-align:center;display:flex;flex-direction:column;align-items:center}.simpay-form-template-explorer-upgrade__title{font-size:22px;line-height:1.5;display:block;margin:12px 0 0}.simpay-form-template-explorer-upgrade__description{color:#777;font-size:16px;margin:16px 0 24px}.simpay-form-template-explorer-upgrade__description strong{color:#1d2327}.simpay-form-template-explorer-upgrade .components-button.is-primary{font-size:16px;font-weight:bold;margin:0 0 15px;padding:15px 30px !important;height:auto}.simpay-form-template-explorer-upgrade__purchased{color:#555;display:inline-block;margin:8px 0}.simpay-form-template-explorer-upgrade__discount{font-size:15px;text-align:center;margin:24px -32px -24px;padding:32px 40px 24px;border-bottom-left-radius:2px;border-bottom-right-radius:2px;background-color:#fcf9e8;position:relative}.simpay-form-template-explorer-upgrade__discount svg{background:#00a32a;fill:#fff;border-radius:50%;border:4px solid #fff;width:32px;height:32px;position:absolute;top:-16px;left:50%;margin-left:-16px}.simpay-form-template-explorer-upgrade__discount u{text-decoration:none;font-weight:bold;color:#00a32a}.simpay-form-template-explorer-upgrade__discount a{text-decoration:none}"],"sourceRoot":""} \ No newline at end of file diff --git a/includes/core/assets/js/admin/index.js b/includes/core/assets/js/admin/index.js index 0289b749..18dede82 100644 --- a/includes/core/assets/js/admin/index.js +++ b/includes/core/assets/js/admin/index.js @@ -50,7 +50,81 @@ let spAdmin = {}; ); } - // Radios settings. + // Stripe Connect toggle notice. + hooks.addAction( + 'settings.toggleTestMode', + 'wpsp/settings/stripe-connect', + toggleStripeConnectNotice + ); + + // Setting toggles. + this.handleFormBuilderSettingToggles(); + + hooks.addAction( + 'customFieldAdded', + 'wpsp/payment-form', + this.handleFormBuilderSettingToggles + ); + + // Init internal link to tab clicks. + spFormSettings.on( + 'click.simpayTabLink', + '.simpay-tab-link', + function ( e ) { + e.preventDefault(); + spAdmin.handleInternalLinkToTabClicks( $( this ) ); + } + ); + + // Remove image preview click. + spFormSettings.on( + 'click.simpayImagePreview', + '.simpay-remove-image-preview', + function ( e ) { + spAdmin.handleRemoveImagePreviewClick( e ); + } + ); + + // Use chosen for select fields + this.setupChosen(); + + // Media Uploader + this.addMediaFields(); + + this.stripeConnect(); + + // Payment Mode. + // + // Disable modes that are not globally available. + const paymentModeSelector = $( '.simpay-payment-modes' ); + + if ( paymentModeSelector.length ) { + const paymentModes = paymentModeSelector.find( 'input' ); + + paymentModes.each( function () { + const mode = $( this ); + + if ( + ! paymentModeSelector.hasClass( + 'simpay-payment-mode--' + mode.val() + ) + ) { + mode.attr( 'disabled', true ); + } + } ); + } + + body.trigger( 'simpayAdminInit' ); + }, + + /** + * Handles the setup of form builder setting toggles. + * + * @since 4.6.5 + * + * @return {void} + */ + handleFormBuilderSettingToggles() { [ '_amount_type', '_success_redirect_type', @@ -133,63 +207,6 @@ let spAdmin = {}; $( inputEl ).trigger( 'change' ); } } ); - - // Stripe Connect toggle notice. - hooks.addAction( - 'settings.toggleTestMode', - 'wpsp/settings/stripe-connect', - toggleStripeConnectNotice - ); - - // Init internal link to tab clicks. - spFormSettings.on( - 'click.simpayTabLink', - '.simpay-tab-link', - function ( e ) { - e.preventDefault(); - spAdmin.handleInternalLinkToTabClicks( $( this ) ); - } - ); - - // Remove image preview click. - spFormSettings.on( - 'click.simpayImagePreview', - '.simpay-remove-image-preview', - function ( e ) { - spAdmin.handleRemoveImagePreviewClick( e ); - } - ); - - // Use chosen for select fields - this.setupChosen(); - - // Media Uploader - this.addMediaFields(); - - this.stripeConnect(); - - // Payment Mode. - // - // Disable modes that are not globally available. - const paymentModeSelector = $( '.simpay-payment-modes' ); - - if ( paymentModeSelector.length ) { - const paymentModes = paymentModeSelector.find( 'input' ); - - paymentModes.each( function () { - const mode = $( this ); - - if ( - ! paymentModeSelector.hasClass( - 'simpay-payment-mode--' + mode.val() - ) - ) { - mode.attr( 'disabled', true ); - } - } ); - } - - body.trigger( 'simpayAdminInit' ); }, handleRemoveImagePreviewClick( e ) { diff --git a/includes/core/assets/js/admin/pages/setup-wizard/components/logo/index.js b/includes/core/assets/js/admin/pages/setup-wizard/components/logo/index.js index c4e68eb1..bcd3b0c8 100644 --- a/includes/core/assets/js/admin/pages/setup-wizard/components/logo/index.js +++ b/includes/core/assets/js/admin/pages/setup-wizard/components/logo/index.js @@ -1,25 +1,19 @@ export function Logo( { width } ) { return ( ); diff --git a/includes/core/assets/js/admin/payment-form/template-explorer/content.js b/includes/core/assets/js/admin/payment-form/template-explorer/content.js index 3339f204..9e266a91 100644 --- a/includes/core/assets/js/admin/payment-form/template-explorer/content.js +++ b/includes/core/assets/js/admin/payment-form/template-explorer/content.js @@ -11,6 +11,7 @@ import { sortBy } from 'lodash'; */ import { createInterpolateElement, + Fragment, useMemo, useEffect, } from '@wordpress/element'; @@ -23,6 +24,7 @@ import { speak } from '@wordpress/a11y'; */ import TemplateListItem from './list-item.js'; import SuggestCta from './suggest-cta.js'; +import UpgradeCta from './upgrade-cta.js'; import { searchItems } from './search-utils.js'; const { suggestUrl, licenseLevel } = simpayFormBuilderTemplateExplorer; @@ -40,7 +42,7 @@ function TemplateExplorerContent( { if ( ! filterValue ) { if ( '' !== selectedCategory ) { results = templates.filter( ( { categories } ) => - Object.keys( categories ).includes( selectedCategory ) + categories.includes( selectedCategory ) ); } } else { @@ -103,12 +105,31 @@ function TemplateExplorerContent( { { hasItems && ( <> - { filteredTemplates.map( ( template ) => ( - - ) ) } + { filteredTemplates.map( ( template, i ) => { + const item = ( + + ); + + if ( + '' === filterValue && + [ 'lite', 'personal', 'plus' ].includes( + licenseLevel + ) && + i === 5 + ) { + return ( + + { item } + + + ); + } + + return item; + } ) } diff --git a/includes/core/assets/js/admin/payment-form/template-explorer/header.js b/includes/core/assets/js/admin/payment-form/template-explorer/header.js index 2f162e35..ee01919d 100644 --- a/includes/core/assets/js/admin/payment-form/template-explorer/header.js +++ b/includes/core/assets/js/admin/payment-form/template-explorer/header.js @@ -10,7 +10,7 @@ import { find } from 'lodash'; */ import { createInterpolateElement } from '@wordpress/element'; import { __ } from '@wordpress/i18n'; -import { addQueryArgs } from '@wordpress/url'; +import { addQueryArgs, getQueryArg } from '@wordpress/url'; const { suggestUrl, @@ -26,12 +26,19 @@ const blankUrl = addQueryArgs( addNewUrl, { } ); const baseClassName = 'simpay-form-template-explorer-header'; +const isAdding = + 'simpay_form_templates' === getQueryArg( window.location.href, 'page' ); function Header() { return (

- { __( 'Select a template', 'simple-pay' ) } + { isAdding + ? __( + 'Get a Head Start With Our Pre-Made Form Templates', + 'simple-pay' + ) + : __( 'Select a template', 'simple-pay' ) }

diff --git a/includes/core/assets/js/admin/payment-form/template-explorer/index.js b/includes/core/assets/js/admin/payment-form/template-explorer/index.js index 5d16497e..53977ee5 100644 --- a/includes/core/assets/js/admin/payment-form/template-explorer/index.js +++ b/includes/core/assets/js/admin/payment-form/template-explorer/index.js @@ -5,7 +5,6 @@ */ import { render, useEffect, useState } from '@wordpress/element'; import { Popover, SlotFillProvider } from '@wordpress/components'; -import { __ } from '@wordpress/i18n'; /** * Internal dependencies @@ -14,23 +13,18 @@ import TemplateExplorerHeader from './header.js'; import TemplateExplorerSidebar from './sidebar.js'; import TemplateExplorerContent from './content.js'; -const { templates } = simpayFormBuilderTemplateExplorer; -const templateCategories = templates.reduce( - ( categories, template ) => { - return { - ...categories, - ...template.categories, - }; - }, - { - '': __( 'All Templates', 'simple-pay' ), - } -); +const { + hasNew, + templates, + categories: templateCategories, +} = simpayFormBuilderTemplateExplorer; const baseClassName = 'simpay-form-template-explorer'; function TemplateExplorer() { const [ filterValue, setFilterValueString ] = useState( '' ); - const [ selectedCategory, setSelectedCategory ] = useState( '' ); + const [ selectedCategory, setSelectedCategory ] = useState( + hasNew ? 'new' : '' + ); const setFilterValue = ( value ) => { setFilterValueString( value ); diff --git a/includes/core/assets/js/admin/payment-form/template-explorer/list-item.js b/includes/core/assets/js/admin/payment-form/template-explorer/list-item.js index 664ee132..58aadd14 100644 --- a/includes/core/assets/js/admin/payment-form/template-explorer/list-item.js +++ b/includes/core/assets/js/admin/payment-form/template-explorer/list-item.js @@ -107,6 +107,7 @@ function TemplateListItem( { template } ) { variant="secondary" href={ demoUrl } style={ { marginLeft: '10px' } } + target="_blank" > { __( 'View Demo', 'simple-pay' ) } diff --git a/includes/core/assets/js/admin/payment-form/template-explorer/sidebar.js b/includes/core/assets/js/admin/payment-form/template-explorer/sidebar.js index 5f5dac12..f70f43de 100644 --- a/includes/core/assets/js/admin/payment-form/template-explorer/sidebar.js +++ b/includes/core/assets/js/admin/payment-form/template-explorer/sidebar.js @@ -1,3 +1,8 @@ +/** + * External dependencies + */ +import classnames from 'classnames'; + /** * WordPress dependencies */ @@ -21,23 +26,26 @@ function TemplateCategoriesList( { orientation="vertical" className={ `${ baseClassName }-categories` } > - { Object.keys( templateCategories ) - .sort() - .map( ( name ) => { - return ( - - ); - } ) } + { Object.keys( templateCategories ).map( ( name ) => { + const className = classnames( + `category-${ name }`, + `${ baseClassName }-categories_category` + ); + + return ( + + ); + } ) } ); } diff --git a/includes/core/assets/js/admin/payment-form/template-explorer/upgrade-cta.js b/includes/core/assets/js/admin/payment-form/template-explorer/upgrade-cta.js new file mode 100644 index 00000000..33508e18 --- /dev/null +++ b/includes/core/assets/js/admin/payment-form/template-explorer/upgrade-cta.js @@ -0,0 +1,46 @@ +/* global simpayFormBuilderTemplateExplorer */ + +/** + * WordPress dependencies + */ +import { Button } from '@wordpress/components'; +import { __ } from '@wordpress/i18n'; + +const { isLite, upgradeUrl } = simpayFormBuilderTemplateExplorer; +const baseClassName = 'simpay-form-template-explorer-main__content'; + +function UpgradeCta() { + return ( +

+
+

+ { __( + 'Get Access to All of Our Pre-Made Payment Form Templates', + 'simple-pay' + ) } +

+

+ { __( + 'Never start from scratch again! Upgrade to gain access to every payment form template we make and unlock powerful new features.', + 'simple-pay' + ) } +

+
+ + +
+ ); +} + +export default UpgradeCta; diff --git a/includes/core/assets/js/simpay-admin-dashboard-widget-report.min.asset.php b/includes/core/assets/js/simpay-admin-dashboard-widget-report.min.asset.php index a6b93f9b..55d74b45 100644 --- a/includes/core/assets/js/simpay-admin-dashboard-widget-report.min.asset.php +++ b/includes/core/assets/js/simpay-admin-dashboard-widget-report.min.asset.php @@ -1 +1 @@ - array('lodash', 'react', 'wp-api-fetch', 'wp-components', 'wp-core-data', 'wp-data', 'wp-element', 'wp-html-entities', 'wp-i18n', 'wp-primitives', 'wp-url'), 'version' => '01c31e9e8b6bf2eb66e271df8fba30ab'); \ No newline at end of file + array('lodash', 'react', 'wp-api-fetch', 'wp-components', 'wp-core-data', 'wp-data', 'wp-element', 'wp-html-entities', 'wp-i18n', 'wp-primitives', 'wp-url'), 'version' => '3dd5f32841a621d1d6743bc6e63b8d79'); \ No newline at end of file diff --git a/includes/core/assets/js/simpay-admin-dashboard-widget-report.min.js b/includes/core/assets/js/simpay-admin-dashboard-widget-report.min.js index 213951c3..3f4a4f27 100644 --- a/includes/core/assets/js/simpay-admin-dashboard-widget-report.min.js +++ b/includes/core/assets/js/simpay-admin-dashboard-widget-report.min.js @@ -1,6 +1,6 @@ -!function(t){var e={};function i(s){if(e[s])return e[s].exports;var n=e[s]={i:s,l:!1,exports:{}};return t[s].call(n.exports,n,n.exports,i),n.l=!0,n.exports}i.m=t,i.c=e,i.d=function(t,e,s){i.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:s})},i.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},i.t=function(t,e){if(1&e&&(t=i(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var s=Object.create(null);if(i.r(s),Object.defineProperty(s,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var n in t)i.d(s,n,function(e){return t[e]}.bind(null,n));return s},i.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return i.d(e,"a",e),e},i.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},i.p="",i(i.s=67)}([function(t,e){t.exports=window.wp.element},,function(t,e){t.exports=window.wp.i18n},function(t,e){t.exports=window.wp.components},function(t,e){t.exports=window.React},function(t,e,i){var s=i(20),n=i(21),o=i(16),a=i(22);t.exports=function(t,e){return s(t)||n(t,e)||o(t,e)||a()},t.exports.__esModule=!0,t.exports.default=t.exports},function(t,e){t.exports=window.wp.primitives},function(t,e){t.exports=window.wp.url},function(t,e){t.exports=window.lodash},,,,function(t,e){t.exports=window.wp.data},function(t,e){t.exports=function(t,e,i){return e in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t},t.exports.__esModule=!0,t.exports.default=t.exports},function(t,e,i){var s;!function(){"use strict";var i={}.hasOwnProperty;function n(){for(var t=[],e=0;et.length)&&(e=t.length);for(var i=0,s=new Array(e);iArray.prototype.slice.call(t));let n=!1,o=[];return function(...i){o=s(i),n||(n=!0,m.call(window,()=>{n=!1,t.apply(e,o)}))}}const x=(t,e,i)=>"start"===t?e:"end"===t?i:(e+i)/2;function _(){}const y=function(){let t=0;return function(){return t++}}();function v(t){return null==t}function w(t){if(Array.isArray&&Array.isArray(t))return!0;const e=Object.prototype.toString.call(t);return"[object"===e.substr(0,7)&&"Array]"===e.substr(-6)}function M(t){return null!==t&&"[object Object]"===Object.prototype.toString.call(t)}const k=t=>("number"==typeof t||t instanceof Number)&&isFinite(+t);function O(t,e){return k(t)?t:e}function S(t,e){return void 0===t?e:t}const P=(t,e)=>"string"==typeof t&&t.endsWith("%")?parseFloat(t)/100*e:+t;function D(t,e,i){if(t&&"function"==typeof t.call)return t.apply(i,e)}function E(t,e,i,s){let n,o,a;if(w(t))if(o=t.length,s)for(n=o-1;n>=0;n--)e.call(i,t[n],n);else for(n=0;ni;)t=t[e.substr(i,s-i)],i=s+1,s=F(e,i);return t}function V(t){return t.charAt(0).toUpperCase()+t.slice(1)}const B=t=>void 0!==t,N=t=>"function"==typeof t,W=(t,e)=>{if(t.size!==e.size)return!1;for(const i of t)if(!e.has(i))return!1;return!0},H=Math.PI,$=2*H,Y=$+H,U=Number.POSITIVE_INFINITY,X=H/180,q=H/2,K=H/4,G=2*H/3,Z=Math.log10,Q=Math.sign;function J(t){const e=Math.round(t);t=et(t,e,t/1e3)?e:t;const i=Math.pow(10,Math.floor(Z(t))),s=t/i;return(s<=1?1:s<=2?2:s<=5?5:10)*i}function tt(t){return!isNaN(parseFloat(t))&&isFinite(t)}function et(t,e,i){return Math.abs(t-e)l&&h=Math.min(e,i)-s&&t<=Math.max(e,i)+s}const ft=t=>0===t||1===t,pt=(t,e,i)=>-Math.pow(2,10*(t-=1))*Math.sin((t-e)*$/i),gt=(t,e,i)=>Math.pow(2,-10*t)*Math.sin((t-e)*$/i)+1,mt={linear:t=>t,easeInQuad:t=>t*t,easeOutQuad:t=>-t*(t-2),easeInOutQuad:t=>(t/=.5)<1?.5*t*t:-.5*(--t*(t-2)-1),easeInCubic:t=>t*t*t,easeOutCubic:t=>(t-=1)*t*t+1,easeInOutCubic:t=>(t/=.5)<1?.5*t*t*t:.5*((t-=2)*t*t+2),easeInQuart:t=>t*t*t*t,easeOutQuart:t=>-((t-=1)*t*t*t-1),easeInOutQuart:t=>(t/=.5)<1?.5*t*t*t*t:-.5*((t-=2)*t*t*t-2),easeInQuint:t=>t*t*t*t*t,easeOutQuint:t=>(t-=1)*t*t*t*t+1,easeInOutQuint:t=>(t/=.5)<1?.5*t*t*t*t*t:.5*((t-=2)*t*t*t*t+2),easeInSine:t=>1-Math.cos(t*q),easeOutSine:t=>Math.sin(t*q),easeInOutSine:t=>-.5*(Math.cos(H*t)-1),easeInExpo:t=>0===t?0:Math.pow(2,10*(t-1)),easeOutExpo:t=>1===t?1:1-Math.pow(2,-10*t),easeInOutExpo:t=>ft(t)?t:t<.5?.5*Math.pow(2,10*(2*t-1)):.5*(2-Math.pow(2,-10*(2*t-1))),easeInCirc:t=>t>=1?t:-(Math.sqrt(1-t*t)-1),easeOutCirc:t=>Math.sqrt(1-(t-=1)*t),easeInOutCirc:t=>(t/=.5)<1?-.5*(Math.sqrt(1-t*t)-1):.5*(Math.sqrt(1-(t-=2)*t)+1),easeInElastic:t=>ft(t)?t:pt(t,.075,.3),easeOutElastic:t=>ft(t)?t:gt(t,.075,.3),easeInOutElastic(t){const e=.1125;return ft(t)?t:t<.5?.5*pt(2*t,e,.45):.5+.5*gt(2*t-1,e,.45)},easeInBack(t){const e=1.70158;return t*t*((e+1)*t-e)},easeOutBack(t){const e=1.70158;return(t-=1)*t*((e+1)*t+e)+1},easeInOutBack(t){let e=1.70158;return(t/=.5)<1?t*t*((1+(e*=1.525))*t-e)*.5:.5*((t-=2)*t*((1+(e*=1.525))*t+e)+2)},easeInBounce:t=>1-mt.easeOutBounce(1-t),easeOutBounce(t){const e=7.5625,i=2.75;return t<1/i?e*t*t:t<2/i?e*(t-=1.5/i)*t+.75:t<2.5/i?e*(t-=2.25/i)*t+.9375:e*(t-=2.625/i)*t+.984375},easeInOutBounce:t=>t<.5?.5*mt.easeInBounce(2*t):.5*mt.easeOutBounce(2*t-1)+.5},bt={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,A:10,B:11,C:12,D:13,E:14,F:15,a:10,b:11,c:12,d:13,e:14,f:15},xt="0123456789ABCDEF",_t=t=>xt[15&t],yt=t=>xt[(240&t)>>4]+xt[15&t],vt=t=>(240&t)>>4==(15&t);function wt(t){return t+.5|0}const Mt=(t,e,i)=>Math.max(Math.min(t,i),e);function kt(t){return Mt(wt(2.55*t),0,255)}function Ot(t){return Mt(wt(255*t),0,255)}function St(t){return Mt(wt(t/2.55)/100,0,1)}function Pt(t){return Mt(wt(100*t),0,100)}const Dt=/^rgba?\(\s*([-+.\d]+)(%)?[\s,]+([-+.e\d]+)(%)?[\s,]+([-+.e\d]+)(%)?(?:[\s,/]+([-+.e\d]+)(%)?)?\s*\)$/,Et=/^(hsla?|hwb|hsv)\(\s*([-+.e\d]+)(?:deg)?[\s,]+([-+.e\d]+)%[\s,]+([-+.e\d]+)%(?:[\s,]+([-+.e\d]+)(%)?)?\s*\)$/;function Ct(t,e,i){const s=e*Math.min(i,1-i),n=(e,n=(e+t/30)%12)=>i-s*Math.max(Math.min(n-3,9-n,1),-1);return[n(0),n(8),n(4)]}function At(t,e,i){const s=(s,n=(s+t/60)%6)=>i-i*e*Math.max(Math.min(n,4-n,1),0);return[s(5),s(3),s(1)]}function Tt(t,e,i){const s=Ct(t,1,.5);let n;for(e+i>1&&(n=1/(e+i),e*=n,i*=n),n=0;n<3;n++)s[n]*=1-e-i,s[n]+=e;return s}function Rt(t){const e=t.r/255,i=t.g/255,s=t.b/255,n=Math.max(e,i,s),o=Math.min(e,i,s),a=(n+o)/2;let r,l,h;return n!==o&&(h=n-o,l=a>.5?h/(2-n-o):h/(n+o),r=n===e?(i-s)/h+(i=3&&(e={r:t[0],g:t[1],b:t[2],a:255},t.length>3&&(e.a=Ot(t[3]))):(e=Nt(t,{r:0,g:0,b:0,a:1})).a=Ot(e.a),e}function Ht(t){return"r"===t.charAt(0)?function(t){const e=Dt.exec(t);let i,s,n,o=255;if(e){if(e[7]!==i){const t=+e[7];o=255&(e[8]?kt(t):255*t)}return i=+e[1],s=+e[3],n=+e[5],i=255&(e[2]?kt(i):i),s=255&(e[4]?kt(s):s),n=255&(e[6]?kt(n):n),{r:i,g:s,b:n,a:o}}}(t):function(t){const e=Et.exec(t);let i,s=255;if(!e)return;e[5]!==i&&(s=e[6]?kt(+e[5]):Ot(+e[5]));const n=It(+e[2]),o=+e[3]/100,a=+e[4]/100;return i="hwb"===e[1]?function(t,e,i){return Lt(Tt,t,e,i)}(n,o,a):"hsv"===e[1]?function(t,e,i){return Lt(At,t,e,i)}(n,o,a):jt(n,o,a),{r:i[0],g:i[1],b:i[2],a:s}}(t)}class $t{constructor(t){if(t instanceof $t)return t;const e=typeof t;let i;var s,n,o;"object"===e?i=Wt(t):"string"===e&&(o=(s=t).length,"#"===s[0]&&(4===o||5===o?n={r:255&17*bt[s[1]],g:255&17*bt[s[2]],b:255&17*bt[s[3]],a:5===o?17*bt[s[4]]:255}:7!==o&&9!==o||(n={r:bt[s[1]]<<4|bt[s[2]],g:bt[s[3]]<<4|bt[s[4]],b:bt[s[5]]<<4|bt[s[6]],a:9===o?bt[s[7]]<<4|bt[s[8]]:255})),i=n||function(t){Vt||(Vt=function(){const t={},e=Object.keys(zt),i=Object.keys(Ft);let s,n,o,a,r;for(s=0;s>16&255,o>>8&255,255&o]}return t}(),Vt.transparent=[0,0,0,0]);const e=Vt[t.toLowerCase()];return e&&{r:e[0],g:e[1],b:e[2],a:4===e.length?e[3]:255}}(t)||Ht(t)),this._rgb=i,this._valid=!!i}get valid(){return this._valid}get rgb(){var t=Nt(this._rgb);return t&&(t.a=St(t.a)),t}set rgb(t){this._rgb=Wt(t)}rgbString(){return this._valid?(t=this._rgb)&&(t.a<255?`rgba(${t.r}, ${t.g}, ${t.b}, ${St(t.a)})`:`rgb(${t.r}, ${t.g}, ${t.b})`):this._rgb;var t}hexString(){return this._valid?(t=this._rgb,e=function(t){return vt(t.r)&&vt(t.g)&&vt(t.b)&&vt(t.a)}(t)?_t:yt,t?"#"+e(t.r)+e(t.g)+e(t.b)+(t.a<255?e(t.a):""):t):this._rgb;var t,e}hslString(){return this._valid?function(t){if(!t)return;const e=Rt(t),i=e[0],s=Pt(e[1]),n=Pt(e[2]);return t.a<255?`hsla(${i}, ${s}%, ${n}%, ${St(t.a)})`:`hsl(${i}, ${s}%, ${n}%)`}(this._rgb):this._rgb}mix(t,e){const i=this;if(t){const s=i.rgb,n=t.rgb;let o;const a=e===o?.5:e,r=2*a-1,l=s.a-n.a,h=((r*l==-1?r:(r+l)/(1+r*l))+1)/2;o=1-h,s.r=255&h*s.r+o*n.r+.5,s.g=255&h*s.g+o*n.g+.5,s.b=255&h*s.b+o*n.b+.5,s.a=a*s.a+(1-a)*n.a,i.rgb=s}return i}clone(){return new $t(this.rgb)}alpha(t){return this._rgb.a=Ot(t),this}clearer(t){return this._rgb.a*=1-t,this}greyscale(){const t=this._rgb,e=wt(.3*t.r+.59*t.g+.11*t.b);return t.r=t.g=t.b=e,this}opaquer(t){return this._rgb.a*=1+t,this}negate(){const t=this._rgb;return t.r=255-t.r,t.g=255-t.g,t.b=255-t.b,this}lighten(t){return Bt(this._rgb,2,t),this}darken(t){return Bt(this._rgb,2,-t),this}saturate(t){return Bt(this._rgb,1,t),this}desaturate(t){return Bt(this._rgb,1,-t),this}rotate(t){return function(t,e){var i=Rt(t);i[0]=It(i[0]+e),i=jt(i),t.r=i[0],t.g=i[1],t.b=i[2]}(this._rgb,t),this}}function Yt(t){return new $t(t)}const Ut=t=>t instanceof CanvasGradient||t instanceof CanvasPattern;function Xt(t){return Ut(t)?t:Yt(t)}function qt(t){return Ut(t)?t:Yt(t).saturate(.5).darken(.1).hexString()}const Kt=Object.create(null),Gt=Object.create(null);function Zt(t,e){if(!e)return t;const i=e.split(".");for(let e=0,s=i.length;et.chart.platform.getDevicePixelRatio(),this.elements={},this.events=["mousemove","mouseout","click","touchstart","touchmove"],this.font={family:"'Helvetica Neue', 'Helvetica', 'Arial', sans-serif",size:12,style:"normal",lineHeight:1.2,weight:null},this.hover={},this.hoverBackgroundColor=(t,e)=>qt(e.backgroundColor),this.hoverBorderColor=(t,e)=>qt(e.borderColor),this.hoverColor=(t,e)=>qt(e.color),this.indexAxis="x",this.interaction={mode:"nearest",intersect:!0},this.maintainAspectRatio=!0,this.onHover=null,this.onClick=null,this.parsing=!0,this.plugins={},this.responsive=!0,this.scale=void 0,this.scales={},this.showLine=!0,this.drawActiveElementsOnTop=!0,this.describe(t)}set(t,e){return Qt(this,t,e)}get(t){return Zt(this,t)}describe(t,e){return Qt(Gt,t,e)}override(t,e){return Qt(Kt,t,e)}route(t,e,i,s){const n=Zt(this,t),o=Zt(this,i),a="_"+e;Object.defineProperties(n,{[a]:{value:n[e],writable:!0},[e]:{enumerable:!0,get(){const t=this[a],e=o[s];return M(t)?Object.assign({},e,t):S(t,e)},set(t){this[a]=t}}})}}({_scriptable:t=>!t.startsWith("on"),_indexable:t=>"events"!==t,hover:{_fallback:"interaction"},interaction:{_scriptable:!1,_indexable:!1}});function te(t,e,i,s,n){let o=e[n];return o||(o=e[n]=t.measureText(n).width,i.push(n)),o>s&&(s=o),s}function ee(t,e,i,s){let n=(s=s||{}).data=s.data||{},o=s.garbageCollect=s.garbageCollect||[];s.font!==e&&(n=s.data={},o=s.garbageCollect=[],s.font=e),t.save(),t.font=e;let a=0;const r=i.length;let l,h,c,d,u;for(l=0;li.length){for(l=0;l0&&t.stroke()}}function oe(t,e,i){return i=i||.5,!e||t&&t.x>e.left-i&&t.xe.top-i&&t.y0&&""!==o.strokeColor;let l,h;for(t.save(),t.font=n.string,function(t,e){e.translation&&t.translate(e.translation[0],e.translation[1]),v(e.rotation)||t.rotate(e.rotation),e.color&&(t.fillStyle=e.color),e.textAlign&&(t.textAlign=e.textAlign),e.textBaseline&&(t.textBaseline=e.textBaseline)}(t,o),l=0;lS(t[i],t[e[i]]):e=>t[e]:()=>t;for(const t of n)i[t]=+o(t)||0;return i}function be(t){return me(t,{top:"y",right:"x",bottom:"y",left:"x"})}function xe(t){return me(t,["topLeft","topRight","bottomLeft","bottomRight"])}function _e(t){const e=be(t);return e.width=e.left+e.right,e.height=e.top+e.bottom,e}function ye(t,e){t=t||{},e=e||Jt.font;let i=S(t.size,e.size);"string"==typeof i&&(i=parseInt(i,10));let s=S(t.style,e.style);s&&!(""+s).match(pe)&&(console.warn('Invalid font style specified: "'+s+'"'),s="");const n={family:S(t.family,e.family),lineHeight:ge(S(t.lineHeight,e.lineHeight),i),size:i,style:s,weight:S(t.weight,e.weight),string:""};return n.string=function(t){return!t||v(t.size)||v(t.family)?null:(t.style?t.style+" ":"")+(t.weight?t.weight+" ":"")+t.size+"px "+t.family}(n),n}function ve(t,e,i,s){let n,o,a,r=!0;for(n=0,o=t.length;nt[i]1;)s=o+n>>1,i(s)?o=s:n=s;return{lo:o,hi:n}}const ke=(t,e,i)=>Me(t,i,s=>t[s][e]Me(t,i,s=>t[s][e]>=i),Se=["push","pop","shift","splice","unshift"];function Pe(t,e){const i=t._chartjs;if(!i)return;const s=i.listeners,n=s.indexOf(e);-1!==n&&s.splice(n,1),s.length>0||(Se.forEach(e=>{delete t[e]}),delete t._chartjs)}function De(t){const e=new Set;let i,s;for(i=0,s=t.length;it[0])){B(s)||(s=Be("_fallback",t));const o={[Symbol.toStringTag]:"Object",_cacheable:!0,_scopes:t,_rootScopes:i,_fallback:s,_getTarget:n,override:n=>Ee([n,...t],e,i,s)};return new Proxy(o,{deleteProperty:(e,i)=>(delete e[i],delete e._keys,delete t[0][i],!0),get:(i,s)=>Le(i,s,()=>function(t,e,i,s){let n;for(const o of e)if(n=Be(Te(o,t),i),B(n))return Re(t,n)?ze(i,s,t,n):n}(s,e,t,i)),getOwnPropertyDescriptor:(t,e)=>Reflect.getOwnPropertyDescriptor(t._scopes[0],e),getPrototypeOf:()=>Reflect.getPrototypeOf(t[0]),has:(t,e)=>Ne(t).includes(e),ownKeys:t=>Ne(t),set(t,e,i){const s=t._storage||(t._storage=n());return t[e]=s[e]=i,delete t._keys,!0}})}function Ce(t,e,i,s){const n={_cacheable:!1,_proxy:t,_context:e,_subProxy:i,_stack:new Set,_descriptors:Ae(t,s),setContext:e=>Ce(t,e,i,s),override:n=>Ce(t.override(n),e,i,s)};return new Proxy(n,{deleteProperty:(e,i)=>(delete e[i],delete t[i],!0),get:(t,e,i)=>Le(t,e,()=>function(t,e,i){const{_proxy:s,_context:n,_subProxy:o,_descriptors:a}=t;let r=s[e];return N(r)&&a.isScriptable(e)&&(r=function(t,e,i,s){const{_proxy:n,_context:o,_subProxy:a,_stack:r}=i;if(r.has(t))throw new Error("Recursion detected: "+Array.from(r).join("->")+"->"+t);return r.add(t),e=e(o,a||s),r.delete(t),Re(t,e)&&(e=ze(n._scopes,n,t,e)),e}(e,r,t,i)),w(r)&&r.length&&(r=function(t,e,i,s){const{_proxy:n,_context:o,_subProxy:a,_descriptors:r}=i;if(B(o.index)&&s(t))e=e[o.index%e.length];else if(M(e[0])){const i=e,s=n._scopes.filter(t=>t!==i);e=[];for(const l of i){const i=ze(s,n,t,l);e.push(Ce(i,o,a&&a[t],r))}}return e}(e,r,t,a.isIndexable)),Re(e,r)&&(r=Ce(r,n,o&&o[e],a)),r}(t,e,i)),getOwnPropertyDescriptor:(e,i)=>e._descriptors.allKeys?Reflect.has(t,i)?{enumerable:!0,configurable:!0}:void 0:Reflect.getOwnPropertyDescriptor(t,i),getPrototypeOf:()=>Reflect.getPrototypeOf(t),has:(e,i)=>Reflect.has(t,i),ownKeys:()=>Reflect.ownKeys(t),set:(e,i,s)=>(t[i]=s,delete e[i],!0)})}function Ae(t,e={scriptable:!0,indexable:!0}){const{_scriptable:i=e.scriptable,_indexable:s=e.indexable,_allKeys:n=e.allKeys}=t;return{allKeys:n,scriptable:i,indexable:s,isScriptable:N(i)?i:()=>i,isIndexable:N(s)?s:()=>s}}const Te=(t,e)=>t?t+V(e):e,Re=(t,e)=>M(e)&&"adapters"!==t&&(null===Object.getPrototypeOf(e)||e.constructor===Object);function Le(t,e,i){if(Object.prototype.hasOwnProperty.call(t,e))return t[e];const s=i();return t[e]=s,s}function je(t,e,i){return N(t)?t(e,i):t}const Ie=(t,e)=>!0===t?e:"string"==typeof t?z(e,t):void 0;function Fe(t,e,i,s,n){for(const o of e){const e=Ie(i,o);if(e){t.add(e);const o=je(e._fallback,i,n);if(B(o)&&o!==i&&o!==s)return o}else if(!1===e&&B(s)&&i!==s)return null}return!1}function ze(t,e,i,s){const n=e._rootScopes,o=je(e._fallback,i,s),a=[...t,...n],r=new Set;r.add(s);let l=Ve(r,a,i,o||i,s);return null!==l&&(!B(o)||o===i||(l=Ve(r,a,o,l,s),null!==l))&&Ee(Array.from(r),[""],n,o,()=>function(t,e,i){const s=t._getTarget();e in s||(s[e]={});const n=s[e];return w(n)&&M(i)?i:n}(e,i,s))}function Ve(t,e,i,s,n){for(;i;)i=Fe(t,e,i,s,n);return i}function Be(t,e){for(const i of e){if(!i)continue;const e=i[t];if(B(e))return e}}function Ne(t){let e=t._keys;return e||(e=t._keys=function(t){const e=new Set;for(const i of t)for(const t of Object.keys(i).filter(t=>!t.startsWith("_")))e.add(t);return Array.from(e)}(t._scopes)),e}const We=Number.EPSILON||1e-14,He=(t,e)=>e"x"===t?"y":"x";function Ye(t,e,i,s){const n=t.skip?e:t,o=e,a=i.skip?e:i,r=rt(o,n),l=rt(a,o);let h=r/(r+l),c=l/(r+l);h=isNaN(h)?0:h,c=isNaN(c)?0:c;const d=s*h,u=s*c;return{previous:{x:o.x-d*(a.x-n.x),y:o.y-d*(a.y-n.y)},next:{x:o.x+u*(a.x-n.x),y:o.y+u*(a.y-n.y)}}}function Ue(t,e,i){return Math.max(Math.min(t,i),e)}function Xe(t,e,i,s,n){let o,a,r,l;if(e.spanGaps&&(t=t.filter(t=>!t.skip)),"monotone"===e.cubicInterpolationMode)!function(t,e="x"){const i=$e(e),s=t.length,n=Array(s).fill(0),o=Array(s);let a,r,l,h=He(t,0);for(a=0;awindow.getComputedStyle(t,null),Qe=["top","right","bottom","left"];function Je(t,e,i){const s={};i=i?"-"+i:"";for(let n=0;n<4;n++){const o=Qe[n];s[o]=parseFloat(t[e+"-"+o+i])||0}return s.width=s.left+s.right,s.height=s.top+s.bottom,s}function ti(t,e){const{canvas:i,currentDevicePixelRatio:s}=e,n=Ze(i),o="border-box"===n.boxSizing,a=Je(n,"padding"),r=Je(n,"border","width"),{x:l,y:h,box:c}=function(t,e){const i=t.native||t,s=i.touches,n=s&&s.length?s[0]:i,{offsetX:o,offsetY:a}=n;let r,l,h=!1;if(((t,e,i)=>(t>0||e>0)&&(!i||!i.shadowRoot))(o,a,i.target))r=o,l=a;else{const t=e.getBoundingClientRect();r=n.clientX-t.left,l=n.clientY-t.top,h=!0}return{x:r,y:l,box:h}}(t,i),d=a.left+(c&&r.left),u=a.top+(c&&r.top);let{width:f,height:p}=e;return o&&(f-=a.width+r.width,p-=a.height+r.height),{x:Math.round((l-d)/f*i.width/s),y:Math.round((h-u)/p*i.height/s)}}const ei=t=>Math.round(10*t)/10;function ii(t,e,i){const s=e||1,n=Math.floor(t.height*s),o=Math.floor(t.width*s);t.height=n/s,t.width=o/s;const a=t.canvas;return a.style&&(i||!a.style.height&&!a.style.width)&&(a.style.height=t.height+"px",a.style.width=t.width+"px"),(t.currentDevicePixelRatio!==s||a.height!==n||a.width!==o)&&(t.currentDevicePixelRatio=s,a.height=n,a.width=o,t.ctx.setTransform(s,0,0,s,0,0),!0)}const si=function(){let t=!1;try{const e={get passive(){return t=!0,!1}};window.addEventListener("test",null,e),window.removeEventListener("test",null,e)}catch(t){}return t}();function ni(t,e){const i=function(t,e){return Ze(t).getPropertyValue(e)}(t,e),s=i&&i.match(/^(\d+)(\.\d+)?px$/);return s?+s[1]:void 0}function oi(t,e,i,s){return{x:t.x+i*(e.x-t.x),y:t.y+i*(e.y-t.y)}}function ai(t,e,i,s){return{x:t.x+i*(e.x-t.x),y:"middle"===s?i<.5?t.y:e.y:"after"===s?i<1?t.y:e.y:i>0?e.y:t.y}}function ri(t,e,i,s){const n={x:t.cp2x,y:t.cp2y},o={x:e.cp1x,y:e.cp1y},a=oi(t,n,i),r=oi(n,o,i),l=oi(o,e,i),h=oi(a,r,i),c=oi(r,l,i);return oi(h,c,i)}const li=new Map;function hi(t,e,i){return function(t,e){e=e||{};const i=t+JSON.stringify(e);let s=li.get(i);return s||(s=new Intl.NumberFormat(t,e),li.set(i,s)),s}(e,i).format(t)}function ci(t,e,i){return t?function(t,e){return{x:i=>t+t+e-i,setWidth(t){e=t},textAlign:t=>"center"===t?t:"right"===t?"left":"right",xPlus:(t,e)=>t-e,leftForLtr:(t,e)=>t-e}}(e,i):{x:t=>t,setWidth(t){},textAlign:t=>t,xPlus:(t,e)=>t+e,leftForLtr:(t,e)=>t}}function di(t){return"angle"===t?{between:ct,compare:lt,normalize:ht}:{between:ut,compare:(t,e)=>t-e,normalize:t=>t}}function ui({start:t,end:e,count:i,loop:s,style:n}){return{start:t%i,end:e%i,loop:s&&(e-t+1)%i==0,style:n}}function fi(t,e,i){if(!i)return[t];const{property:s,start:n,end:o}=i,a=e.length,{compare:r,between:l,normalize:h}=di(s),{start:c,end:d,loop:u,style:f}=function(t,e,i){const{property:s,start:n,end:o}=i,{between:a,normalize:r}=di(s),l=e.length;let h,c,{start:d,end:u,loop:f}=t;if(f){for(d+=l,u+=l,h=0,c=l;hs({chart:t,initial:e.initial,numSteps:o,currentStep:Math.min(i-e.start,o)}))}_refresh(){this._request||(this._running=!0,this._request=m.call(window,()=>{this._update(),this._request=null,this._running&&this._refresh()}))}_update(t=Date.now()){let e=0;this._charts.forEach((i,s)=>{if(!i.running||!i.items.length)return;const n=i.items;let o,a=n.length-1,r=!1;for(;a>=0;--a)o=n[a],o._active?(o._total>i.duration&&(i.duration=o._total),o.tick(t),r=!0):(n[a]=n[n.length-1],n.pop());r&&(s.draw(),this._notify(s,i,t,"progress")),n.length||(i.running=!1,this._notify(s,i,t,"complete"),i.initial=!1),e+=n.length}),this._lastDate=t,0===e&&(this._running=!1)}_getAnims(t){const e=this._charts;let i=e.get(t);return i||(i={running:!1,initial:!0,items:[],listeners:{complete:[],progress:[]}},e.set(t,i)),i}listen(t,e,i){this._getAnims(t).listeners[e].push(i)}add(t,e){e&&e.length&&this._getAnims(t).items.push(...e)}has(t){return this._getAnims(t).items.length>0}start(t){const e=this._charts.get(t);e&&(e.running=!0,e.start=Date.now(),e.duration=e.items.reduce((t,e)=>Math.max(t,e._duration),0),this._refresh())}running(t){if(!this._running)return!1;const e=this._charts.get(t);return!!(e&&e.running&&e.items.length)}stop(t){const e=this._charts.get(t);if(!e||!e.items.length)return;const i=e.items;let s=i.length-1;for(;s>=0;--s)i[s].cancel();e.items=[],this._notify(t,e,Date.now(),"complete")}remove(t){return this._charts.delete(t)}};const xi={boolean:(t,e,i)=>i>.5?e:t,color(t,e,i){const s=Xt(t||"transparent"),n=s.valid&&Xt(e||"transparent");return n&&n.valid?n.mix(s,i).hexString():e},number:(t,e,i)=>t+(e-t)*i};class _i{constructor(t,e,i,s){const n=e[i];s=ve([t.to,s,n,t.from]);const o=ve([t.from,n,s]);this._active=!0,this._fn=t.fn||xi[t.type||typeof o],this._easing=mt[t.easing]||mt.linear,this._start=Math.floor(Date.now()+(t.delay||0)),this._duration=this._total=Math.floor(t.duration),this._loop=!!t.loop,this._target=e,this._prop=i,this._from=o,this._to=s,this._promises=void 0}active(){return this._active}update(t,e,i){if(this._active){this._notify(!1);const s=this._target[this._prop],n=i-this._start,o=this._duration-n;this._start=i,this._duration=Math.floor(Math.max(o,t.duration)),this._total+=n,this._loop=!!t.loop,this._to=ve([t.to,e,s,t.from]),this._from=ve([t.from,s,e])}}cancel(){this._active&&(this.tick(Date.now()),this._active=!1,this._notify(!1))}tick(t){const e=t-this._start,i=this._duration,s=this._prop,n=this._from,o=this._loop,a=this._to;let r;if(this._active=n!==a&&(o||e1?2-r:r,r=this._easing(Math.min(1,Math.max(0,r))),this._target[s]=this._fn(n,a,r))}wait(){const t=this._promises||(this._promises=[]);return new Promise((e,i)=>{t.push({res:e,rej:i})})}_notify(t){const e=t?"res":"rej",i=this._promises||[];for(let t=0;t"onProgress"!==t&&"onComplete"!==t&&"fn"!==t}),Jt.set("animations",{colors:{type:"color",properties:["color","borderColor","backgroundColor"]},numbers:{type:"number",properties:["x","y","borderWidth","radius","tension"]}}),Jt.describe("animations",{_fallback:"animation"}),Jt.set("transitions",{active:{animation:{duration:400}},resize:{animation:{duration:0}},show:{animations:{colors:{from:"transparent"},visible:{type:"boolean",duration:0}}},hide:{animations:{colors:{to:"transparent"},visible:{type:"boolean",easing:"linear",fn:t=>0|t}}}});class vi{constructor(t,e){this._chart=t,this._properties=new Map,this.configure(e)}configure(t){if(!M(t))return;const e=this._properties;Object.getOwnPropertyNames(t).forEach(i=>{const s=t[i];if(!M(s))return;const n={};for(const t of yi)n[t]=s[t];(w(s.properties)&&s.properties||[i]).forEach(t=>{t!==i&&e.has(t)||e.set(t,n)})})}_animateOptions(t,e){const i=e.options,s=function(t,e){if(!e)return;let i=t.options;if(i)return i.$shared&&(t.options=i=Object.assign({},i,{$shared:!1,$animations:{}})),i;t.options=e}(t,i);if(!s)return[];const n=this._createAnimations(s,i);return i.$shared&&function(t,e){const i=[],s=Object.keys(e);for(let e=0;e{t.options=i},()=>{}),n}_createAnimations(t,e){const i=this._properties,s=[],n=t.$animations||(t.$animations={}),o=Object.keys(e),a=Date.now();let r;for(r=o.length-1;r>=0;--r){const l=o[r];if("$"===l.charAt(0))continue;if("options"===l){s.push(...this._animateOptions(t,e));continue}const h=e[l];let c=n[l];const d=i.get(l);if(c){if(d&&c.active()){c.update(d,h,a);continue}c.cancel()}d&&d.duration?(n[l]=c=new _i(d,t,l,h),s.push(c)):t[l]=h}return s}update(t,e){if(0===this._properties.size)return void Object.assign(t,e);const i=this._createAnimations(t,e);return i.length?(bi.add(this._chart,i),!0):void 0}}function wi(t,e){const i=t&&t.options||{},s=i.reverse,n=void 0===i.min?e:0,o=void 0===i.max?e:0;return{start:s?o:n,end:s?n:o}}function Mi(t,e){const i=[],s=t._getSortedDatasetMetas(e);let n,o;for(n=0,o=s.length;n0||!i&&e<0)return n.index}return null}function Di(t,e){const{chart:i,_cachedMeta:s}=t,n=i._stacks||(i._stacks={}),{iScale:o,vScale:a,index:r}=s,l=o.axis,h=a.axis,c=function(t,e,i){return`${t.id}.${e.id}.${i.stack||i.type}`}(o,a,s),d=e.length;let u;for(let t=0;ti[t].axis===e).shift()}function Ci(t,e){const i=t.controller.index,s=t.vScale&&t.vScale.axis;if(s){e=e||t._parsed;for(const t of e){const e=t._stacks;if(!e||void 0===e[s]||void 0===e[s][i])return;delete e[s][i]}}}const Ai=t=>"reset"===t||"none"===t,Ti=(t,e)=>e?t:Object.assign({},t);class Ri{constructor(t,e){this.chart=t,this._ctx=t.ctx,this.index=e,this._cachedDataOpts={},this._cachedMeta=this.getMeta(),this._type=this._cachedMeta.type,this.options=void 0,this._parsing=!1,this._data=void 0,this._objectData=void 0,this._sharedOptions=void 0,this._drawStart=void 0,this._drawCount=void 0,this.enableOptionSharing=!1,this.$context=void 0,this._syncList=[],this.initialize()}initialize(){const t=this._cachedMeta;this.configure(),this.linkScales(),t._stacked=Oi(t.vScale,t),this.addElements()}updateIndex(t){this.index!==t&&Ci(this._cachedMeta),this.index=t}linkScales(){const t=this.chart,e=this._cachedMeta,i=this.getDataset(),s=(t,e,i,s)=>"x"===t?e:"r"===t?s:i,n=e.xAxisID=S(i.xAxisID,Ei(t,"x")),o=e.yAxisID=S(i.yAxisID,Ei(t,"y")),a=e.rAxisID=S(i.rAxisID,Ei(t,"r")),r=e.indexAxis,l=e.iAxisID=s(r,n,o,a),h=e.vAxisID=s(r,o,n,a);e.xScale=this.getScaleForId(n),e.yScale=this.getScaleForId(o),e.rScale=this.getScaleForId(a),e.iScale=this.getScaleForId(l),e.vScale=this.getScaleForId(h)}getDataset(){return this.chart.data.datasets[this.index]}getMeta(){return this.chart.getDatasetMeta(this.index)}getScaleForId(t){return this.chart.scales[t]}_getOtherScale(t){const e=this._cachedMeta;return t===e.iScale?e.vScale:e.iScale}reset(){this._update("reset")}_destroy(){const t=this._cachedMeta;this._data&&Pe(this._data,this),t._stacked&&Ci(t)}_dataCheck(){const t=this.getDataset(),e=t.data||(t.data=[]),i=this._data;if(M(e))this._data=function(t){const e=Object.keys(t),i=new Array(e.length);let s,n,o;for(s=0,n=e.length;s{const e="_onData"+V(t),i=s[t];Object.defineProperty(s,t,{configurable:!0,enumerable:!1,value(...t){const n=i.apply(this,t);return s._chartjs.listeners.forEach(i=>{"function"==typeof i[e]&&i[e](...t)}),n}})}))),this._syncList=[],this._data=e}var s}addElements(){const t=this._cachedMeta;this._dataCheck(),this.datasetElementType&&(t.dataset=new this.datasetElementType)}buildOrUpdateElements(t){const e=this._cachedMeta,i=this.getDataset();let s=!1;this._dataCheck();const n=e._stacked;e._stacked=Oi(e.vScale,e),e.stack!==i.stack&&(s=!0,Ci(e),e.stack=i.stack),this._resyncElements(t),(s||n!==e._stacked)&&Di(this,e._parsed)}configure(){const t=this.chart.config,e=t.datasetScopeKeys(this._type),i=t.getOptionScopes(this.getDataset(),e,!0);this.options=t.createResolver(i,this.getContext()),this._parsing=this.options.parsing,this._cachedDataOpts={}}parse(t,e){const{_cachedMeta:i,_data:s}=this,{iScale:n,_stacked:o}=i,a=n.axis;let r,l,h,c=0===t&&e===s.length||i._sorted,d=t>0&&i._parsed[t-1];if(!1===this._parsing)i._parsed=s,i._sorted=!0,h=s;else{h=w(s[t])?this.parseArrayData(i,s,t,e):M(s[t])?this.parseObjectData(i,s,t,e):this.parsePrimitiveData(i,s,t,e);const n=()=>null===l[a]||d&&l[a]t&&!e.hidden&&e._stacked&&{keys:Mi(i,!0),values:null})(e,i,this.chart),l={min:Number.POSITIVE_INFINITY,max:Number.NEGATIVE_INFINITY},{min:h,max:c}=function(t){const{min:e,max:i,minDefined:s,maxDefined:n}=t.getUserBounds();return{min:s?e:Number.NEGATIVE_INFINITY,max:n?i:Number.POSITIVE_INFINITY}}(a);let d,u;function f(){u=s[d];const e=u[a.axis];return!k(u[t.axis])||h>e||c=0;--d)if(!f()){this.updateRangeFromParsed(l,t,u,r);break}return l}getAllParsedValues(t){const e=this._cachedMeta._parsed,i=[];let s,n,o;for(s=0,n=e.length;s=0&&tthis.getContext(i,s),c);return f.$shared&&(f.$shared=r,n[o]=Object.freeze(Ti(f,r))),f}_resolveAnimations(t,e,i){const s=this.chart,n=this._cachedDataOpts,o="animation-"+e,a=n[o];if(a)return a;let r;if(!1!==s.options.animation){const s=this.chart.config,n=s.datasetAnimationScopeKeys(this._type,e),o=s.getOptionScopes(this.getDataset(),n);r=s.createResolver(o,this.getContext(t,i,e))}const l=new vi(s,r&&r.animations);return r&&r._cacheable&&(n[o]=Object.freeze(l)),l}getSharedOptions(t){if(t.$shared)return this._sharedOptions||(this._sharedOptions=Object.assign({},t))}includeOptions(t,e){return!e||Ai(t)||this.chart._animationsDisabled}updateElement(t,e,i,s){Ai(s)?Object.assign(t,i):this._resolveAnimations(e,s).update(t,i)}updateSharedOptions(t,e,i){t&&!Ai(e)&&this._resolveAnimations(void 0,e).update(t,i)}_setStyle(t,e,i,s){t.active=s;const n=this.getStyle(e,s);this._resolveAnimations(e,i,s).update(t,{options:!s&&this.getSharedOptions(n)||n})}removeHoverStyle(t,e,i){this._setStyle(t,i,"active",!1)}setHoverStyle(t,e,i){this._setStyle(t,i,"active",!0)}_removeDatasetHoverStyle(){const t=this._cachedMeta.dataset;t&&this._setStyle(t,void 0,"active",!1)}_setDatasetHoverStyle(){const t=this._cachedMeta.dataset;t&&this._setStyle(t,void 0,"active",!0)}_resyncElements(t){const e=this._data,i=this._cachedMeta.data;for(const[t,e,i]of this._syncList)this[t](e,i);this._syncList=[];const s=i.length,n=e.length,o=Math.min(n,s);o&&this.parse(0,o),n>s?this._insertElements(s,n-s,t):n{for(t.length+=e,a=t.length-1;a>=o;a--)t[a]=t[a-e]};for(r(n),a=t;at-e))}return t._cache.$bar}(e,t.type);let s,n,o,a,r=e._length;const l=()=>{32767!==o&&-32768!==o&&(B(a)&&(r=Math.min(r,Math.abs(o-a)||r)),a=o)};for(s=0,n=i.length;sMath.abs(r)&&(l=r,h=a),e[i.axis]=h,e._custom={barStart:l,barEnd:h,start:n,end:o,min:a,max:r}}(t,e,i,s):e[i.axis]=i.parse(t,s),e}function Ii(t,e,i,s){const n=t.iScale,o=t.vScale,a=n.getLabels(),r=n===o,l=[];let h,c,d,u;for(h=i,c=i+s;ht.x,i="left",s="right"):(e=t.base=i?1:-1)}(c,e,o)*n,d===o&&(g-=c/2),h=g+c),g===e.getPixelForValue(o)){const t=Q(c)*e.getLineWidthForValue(o)/2;g+=t,c-=t}return{size:c,base:g,head:h,center:h+c/2}}_calculateBarIndexPixels(t,e){const i=e.scale,s=this.options,n=s.skipNull,o=S(s.maxBarThickness,1/0);let a,r;if(e.grouped){const i=n?this._getStackCount(t):e.stackCount,l="flex"===s.barThickness?function(t,e,i,s){const n=e.pixels,o=n[t];let a=t>0?n[t-1]:null,r=t=0;--i)e=Math.max(e,t[i].size(this.resolveDataElementOptions(i))/2);return e>0&&e}getLabelAndValue(t){const e=this._cachedMeta,{xScale:i,yScale:s}=e,n=this.getParsed(t),o=i.getLabelForValue(n.x),a=s.getLabelForValue(n.y),r=n._custom;return{label:e.label,value:"("+o+", "+a+(r?", "+r:"")+")"}}update(t){const e=this._cachedMeta.data;this.updateElements(e,0,e.length,t)}updateElements(t,e,i,s){const n="reset"===s,{iScale:o,vScale:a}=this._cachedMeta,r=this.resolveDataElementOptions(e,s),l=this.getSharedOptions(r),h=this.includeOptions(s,l),c=o.axis,d=a.axis;for(let r=e;r""}}}};class $i extends Ri{constructor(t,e){super(t,e),this.enableOptionSharing=!0,this.innerRadius=void 0,this.outerRadius=void 0,this.offsetX=void 0,this.offsetY=void 0}linkScales(){}parse(t,e){const i=this.getDataset().data,s=this._cachedMeta;if(!1===this._parsing)s._parsed=i;else{let n,o,a=t=>+i[t];if(M(i[t])){const{key:t="value"}=this._parsing;a=e=>+z(i[e],t)}for(n=t,o=t+e;nct(t,r,l,!0)?1:Math.max(e,e*i,s,s*i),p=(t,e,s)=>ct(t,r,l,!0)?-1:Math.min(e,e*i,s,s*i),g=f(0,h,d),m=f(q,c,u),b=p(H,h,d),x=p(H+q,c,u);s=(g-b)/2,n=(m-x)/2,o=-(g+b)/2,a=-(m+x)/2}return{ratioX:s,ratioY:n,offsetX:o,offsetY:a}}(u,d,r),b=(i.width-o)/f,x=(i.height-o)/p,_=Math.max(Math.min(b,x)/2,0),y=P(this.options.radius,_),v=(y-Math.max(y*r,0))/this._getVisibleDatasetWeightTotal();this.offsetX=g*y,this.offsetY=m*y,s.total=this.calculateTotal(),this.outerRadius=y-v*this._getRingWeightOffset(this.index),this.innerRadius=Math.max(this.outerRadius-v*c,0),this.updateElements(n,0,n.length,t)}_circumference(t,e){const i=this.options,s=this._cachedMeta,n=this._getCircumference();return e&&i.animation.animateRotate||!this.chart.getDataVisibility(t)||null===s._parsed[t]||s.data[t].hidden?0:this.calculateCircumference(s._parsed[t]*n/$)}updateElements(t,e,i,s){const n="reset"===s,o=this.chart,a=o.chartArea,r=o.options.animation,l=(a.left+a.right)/2,h=(a.top+a.bottom)/2,c=n&&r.animateScale,d=c?0:this.innerRadius,u=c?0:this.outerRadius,f=this.resolveDataElementOptions(e,s),p=this.getSharedOptions(f),g=this.includeOptions(s,p);let m,b=this._getRotation();for(m=0;m0&&!isNaN(t)?$*(Math.abs(t)/e):0}getLabelAndValue(t){const e=this._cachedMeta,i=this.chart,s=i.data.labels||[],n=hi(e._parsed[t],i.options.locale);return{label:s[t]||"",value:n}}getMaxBorderWidth(t){let e=0;const i=this.chart;let s,n,o,a,r;if(!t)for(s=0,n=i.data.datasets.length;s"spacing"!==t,_indexable:t=>"spacing"!==t},$i.overrides={aspectRatio:1,plugins:{legend:{labels:{generateLabels(t){const e=t.data;if(e.labels.length&&e.datasets.length){const{labels:{pointStyle:i}}=t.legend.options;return e.labels.map((e,s)=>{const n=t.getDatasetMeta(0).controller.getStyle(s);return{text:e,fillStyle:n.backgroundColor,strokeStyle:n.borderColor,lineWidth:n.borderWidth,pointStyle:i,hidden:!t.getDataVisibility(s),index:s}})}return[]}},onClick(t,e,i){i.chart.toggleDataVisibility(e.index),i.chart.update()}},tooltip:{callbacks:{title:()=>"",label(t){let e=t.label;const i=": "+t.formattedValue;return w(e)?(e=e.slice(),e[0]+=i):e+=i,e}}}}};class Yi extends Ri{initialize(){this.enableOptionSharing=!0,super.initialize()}update(t){const e=this._cachedMeta,{dataset:i,data:s=[],_dataset:n}=e,o=this.chart._animationsDisabled;let{start:a,count:r}=function(t,e,i){const s=e.length;let n=0,o=s;if(t._sorted){const{iScale:a,_parsed:r}=t,l=a.axis,{min:h,max:c,minDefined:d,maxDefined:u}=a.getUserBounds();d&&(n=dt(Math.min(ke(r,a.axis,h).lo,i?s:ke(e,l,a.getPixelForValue(h)).lo),0,s-1)),o=u?dt(Math.max(ke(r,a.axis,c).hi+1,i?0:ke(e,l,a.getPixelForValue(c)).hi+1),n,s)-n:s-n}return{start:n,count:o}}(e,s,o);this._drawStart=a,this._drawCount=r,function(t){const{xScale:e,yScale:i,_scaleRanges:s}=t,n={xmin:e.min,xmax:e.max,ymin:i.min,ymax:i.max};if(!s)return t._scaleRanges=n,!0;const o=s.xmin!==e.min||s.xmax!==e.max||s.ymin!==i.min||s.ymax!==i.max;return Object.assign(s,n),o}(e)&&(a=0,r=s.length),i._chart=this.chart,i._datasetIndex=this.index,i._decimated=!!n._decimated,i.points=s;const l=this.resolveDatasetElementOptions(t);this.options.showLine||(l.borderWidth=0),l.segment=this.options.segment,this.updateElement(i,void 0,{animated:!o,options:l},t),this.updateElements(s,a,r,t)}updateElements(t,e,i,s){const n="reset"===s,{iScale:o,vScale:a,_stacked:r,_dataset:l}=this._cachedMeta,h=this.resolveDataElementOptions(e,s),c=this.getSharedOptions(h),d=this.includeOptions(s,c),u=o.axis,f=a.axis,{spanGaps:p,segment:g}=this.options,m=tt(p)?p:Number.POSITIVE_INFINITY,b=this.chart._animationsDisabled||n||"none"===s;let x=e>0&&this.getParsed(e-1);for(let h=e;h0&&i[u]-x[u]>m,g&&(p.parsed=i,p.raw=l.data[h]),d&&(p.options=c||this.resolveDataElementOptions(h,e.active?"active":s)),b||this.updateElement(e,h,p,s),x=i}this.updateSharedOptions(c,s,h)}getMaxOverflow(){const t=this._cachedMeta,e=t.dataset,i=e.options&&e.options.borderWidth||0,s=t.data||[];if(!s.length)return i;const n=s[0].size(this.resolveDataElementOptions(0)),o=s[s.length-1].size(this.resolveDataElementOptions(s.length-1));return Math.max(i,n,o)/2}draw(){const t=this._cachedMeta;t.dataset.updateControlPoints(this.chart.chartArea,t.iScale.axis),super.draw()}}Yi.id="line",Yi.defaults={datasetElementType:"line",dataElementType:"point",showLine:!0,spanGaps:!1},Yi.overrides={scales:{_index_:{type:"category"},_value_:{type:"linear"}}};class Ui extends Ri{constructor(t,e){super(t,e),this.innerRadius=void 0,this.outerRadius=void 0}getLabelAndValue(t){const e=this._cachedMeta,i=this.chart,s=i.data.labels||[],n=hi(e._parsed[t].r,i.options.locale);return{label:s[t]||"",value:n}}update(t){const e=this._cachedMeta.data;this._updateRadius(),this.updateElements(e,0,e.length,t)}_updateRadius(){const t=this.chart,e=t.chartArea,i=t.options,s=Math.min(e.right-e.left,e.bottom-e.top),n=Math.max(s/2,0),o=(n-Math.max(i.cutoutPercentage?n/100*i.cutoutPercentage:1,0))/t.getVisibleDatasetCount();this.outerRadius=n-o*this.index,this.innerRadius=this.outerRadius-o}updateElements(t,e,i,s){const n="reset"===s,o=this.chart,a=this.getDataset(),r=o.options.animation,l=this._cachedMeta.rScale,h=l.xCenter,c=l.yCenter,d=l.getIndexAngle(0)-.5*H;let u,f=d;const p=360/this.countVisibleElements();for(u=0;u{!isNaN(t.data[s])&&this.chart.getDataVisibility(s)&&i++}),i}_computeAngle(t,e,i){return this.chart.getDataVisibility(t)?st(this.resolveDataElementOptions(t,e).angle||i):0}}Ui.id="polarArea",Ui.defaults={dataElementType:"arc",animation:{animateRotate:!0,animateScale:!0},animations:{numbers:{type:"number",properties:["x","y","startAngle","endAngle","innerRadius","outerRadius"]}},indexAxis:"r",startAngle:0},Ui.overrides={aspectRatio:1,plugins:{legend:{labels:{generateLabels(t){const e=t.data;if(e.labels.length&&e.datasets.length){const{labels:{pointStyle:i}}=t.legend.options;return e.labels.map((e,s)=>{const n=t.getDatasetMeta(0).controller.getStyle(s);return{text:e,fillStyle:n.backgroundColor,strokeStyle:n.borderColor,lineWidth:n.borderWidth,pointStyle:i,hidden:!t.getDataVisibility(s),index:s}})}return[]}},onClick(t,e,i){i.chart.toggleDataVisibility(e.index),i.chart.update()}},tooltip:{callbacks:{title:()=>"",label:t=>t.chart.data.labels[t.dataIndex]+": "+t.formattedValue}}},scales:{r:{type:"radialLinear",angleLines:{display:!1},beginAtZero:!0,grid:{circular:!0},pointLabels:{display:!1},startAngle:0}}};class Xi extends $i{}Xi.id="pie",Xi.defaults={cutout:0,rotation:0,circumference:360,radius:"100%"};class qi extends Ri{getLabelAndValue(t){const e=this._cachedMeta.vScale,i=this.getParsed(t);return{label:e.getLabels()[t],value:""+e.getLabelForValue(i[e.axis])}}update(t){const e=this._cachedMeta,i=e.dataset,s=e.data||[],n=e.iScale.getLabels();if(i.points=s,"resize"!==t){const e=this.resolveDatasetElementOptions(t);this.options.showLine||(e.borderWidth=0);const o={_loop:!0,_fullLoop:n.length===s.length,options:e};this.updateElement(i,void 0,o,t)}this.updateElements(s,0,s.length,t)}updateElements(t,e,i,s){const n=this.getDataset(),o=this._cachedMeta.rScale,a="reset"===s;for(let r=e;r"",label:t=>"("+t.label+", "+t.formattedValue+")"}}},scales:{x:{type:"linear"},y:{type:"linear"}}};class Zi{constructor(t){this.options=t||{}}formats(){return Gi()}parse(t,e){return Gi()}format(t,e){return Gi()}add(t,e,i){return Gi()}diff(t,e,i){return Gi()}startOf(t,e,i){return Gi()}endOf(t,e){return Gi()}}Zi.override=function(t){Object.assign(Zi.prototype,t)};var Qi={_date:Zi};function Ji(t,e){return"native"in t?{x:t.x,y:t.y}:ti(t,e)}function ts(t,e,i,s){const{controller:n,data:o,_sorted:a}=t,r=n._cachedMeta.iScale;if(r&&e===r.axis&&"r"!==e&&a&&o.length){const t=r._reversePixels?Oe:ke;if(!s)return t(o,e,i);if(n._sharedOptions){const s=o[0],n="function"==typeof s.getRange&&s.getRange(e);if(n){const s=t(o,e,i-n),a=t(o,e,i+n);return{lo:s.lo,hi:a.hi}}}}return{lo:0,hi:o.length-1}}function es(t,e,i,s,n){const o=t.getSortedVisibleDatasetMetas(),a=i[e];for(let t=0,i=o.length;t{t[r](n[a],s)&&o.push({element:t,datasetIndex:e,index:i}),t.inRange(n.x,n.y,s)&&(l=!0)}),i.intersect&&!l?[]:o}var os={modes:{index(t,e,i,s){const n=Ji(e,t),o=i.axis||"x",a=i.intersect?is(t,n,o,s):ss(t,n,o,!1,s),r=[];return a.length?(t.getSortedVisibleDatasetMetas().forEach(t=>{const e=a[0].index,i=t.data[e];i&&!i.skip&&r.push({element:i,datasetIndex:t.index,index:e})}),r):[]},dataset(t,e,i,s){const n=Ji(e,t),o=i.axis||"xy";let a=i.intersect?is(t,n,o,s):ss(t,n,o,!1,s);if(a.length>0){const e=a[0].datasetIndex,i=t.getDatasetMeta(e).data;a=[];for(let t=0;tis(t,Ji(e,t),i.axis||"xy",s),nearest:(t,e,i,s)=>ss(t,Ji(e,t),i.axis||"xy",i.intersect,s),x:(t,e,i,s)=>ns(t,e,{axis:"x",intersect:i.intersect},s),y:(t,e,i,s)=>ns(t,e,{axis:"y",intersect:i.intersect},s)}};const as=["left","top","right","bottom"];function rs(t,e){return t.filter(t=>t.pos===e)}function ls(t,e){return t.filter(t=>-1===as.indexOf(t.pos)&&t.box.axis===e)}function hs(t,e){return t.sort((t,i)=>{const s=e?i:t,n=e?t:i;return s.weight===n.weight?s.index-n.index:s.weight-n.weight})}function cs(t,e,i,s){return Math.max(t[i],e[i])+Math.max(t[s],e[s])}function ds(t,e){t.top=Math.max(t.top,e.top),t.left=Math.max(t.left,e.left),t.bottom=Math.max(t.bottom,e.bottom),t.right=Math.max(t.right,e.right)}function us(t,e,i,s){const{pos:n,box:o}=i,a=t.maxPadding;if(!M(n)){i.size&&(t[n]-=i.size);const e=s[i.stack]||{size:0,count:1};e.size=Math.max(e.size,i.horizontal?o.height:o.width),i.size=e.size/e.count,t[n]+=i.size}o.getPadding&&ds(a,o.getPadding());const r=Math.max(0,e.outerWidth-cs(a,t,"left","right")),l=Math.max(0,e.outerHeight-cs(a,t,"top","bottom")),h=r!==t.w,c=l!==t.h;return t.w=r,t.h=l,i.horizontal?{same:h,other:c}:{same:c,other:h}}function fs(t,e){const i=e.maxPadding;return function(t){const s={left:0,top:0,right:0,bottom:0};return t.forEach(t=>{s[t]=Math.max(e[t],i[t])}),s}(t?["left","right"]:["top","bottom"])}function ps(t,e,i,s){const n=[];let o,a,r,l,h,c;for(o=0,a=t.length,h=0;ot.box.fullSize),!0),s=hs(rs(e,"left"),!0),n=hs(rs(e,"right")),o=hs(rs(e,"top"),!0),a=hs(rs(e,"bottom")),r=ls(e,"x"),l=ls(e,"y");return{fullSize:i,leftAndTop:s.concat(o),rightAndBottom:n.concat(l).concat(a).concat(r),chartArea:rs(e,"chartArea"),vertical:s.concat(n).concat(l),horizontal:o.concat(a).concat(r)}}(t.boxes),l=r.vertical,h=r.horizontal;E(t.boxes,t=>{"function"==typeof t.beforeLayout&&t.beforeLayout()});const c=l.reduce((t,e)=>e.box.options&&!1===e.box.options.display?t:t+1,0)||1,d=Object.freeze({outerWidth:e,outerHeight:i,padding:n,availableWidth:o,availableHeight:a,vBoxMaxWidth:o/2/c,hBoxMaxHeight:a/2}),u=Object.assign({},n);ds(u,_e(s));const f=Object.assign({maxPadding:u,w:o,h:a,x:n.left,y:n.top},n),p=function(t,e){const i=function(t){const e={};for(const i of t){const{stack:t,pos:s,stackWeight:n}=i;if(!t||!as.includes(s))continue;const o=e[t]||(e[t]={count:0,placed:0,weight:0,size:0});o.count++,o.weight+=n}return e}(t),{vBoxMaxWidth:s,hBoxMaxHeight:n}=e;let o,a,r;for(o=0,a=t.length;o{const i=e.box;Object.assign(i,t.chartArea),i.update(f.w,f.h,{left:0,top:0,right:0,bottom:0})})}};class xs{acquireContext(t,e){}releaseContext(t){return!1}addEventListener(t,e,i){}removeEventListener(t,e,i){}getDevicePixelRatio(){return 1}getMaximumSize(t,e,i,s){return e=Math.max(0,e||t.width),i=i||t.height,{width:e,height:Math.max(0,s?Math.floor(e/s):i)}}isAttached(t){return!0}updateConfig(t){}}class _s extends xs{acquireContext(t){return t&&t.getContext&&t.getContext("2d")||null}updateConfig(t){t.options.animation=!1}}const ys={touchstart:"mousedown",touchmove:"mousemove",touchend:"mouseup",pointerenter:"mouseenter",pointerdown:"mousedown",pointermove:"mousemove",pointerup:"mouseup",pointerleave:"mouseout",pointerout:"mouseout"},vs=t=>null===t||""===t,ws=!!si&&{passive:!0};function Ms(t,e,i){t.canvas.removeEventListener(e,i,ws)}function ks(t,e){for(const i of t)if(i===e||i.contains(e))return!0}function Os(t,e,i){const s=t.canvas,n=new MutationObserver(t=>{let e=!1;for(const i of t)e=e||ks(i.addedNodes,s),e=e&&!ks(i.removedNodes,s);e&&i()});return n.observe(document,{childList:!0,subtree:!0}),n}function Ss(t,e,i){const s=t.canvas,n=new MutationObserver(t=>{let e=!1;for(const i of t)e=e||ks(i.removedNodes,s),e=e&&!ks(i.addedNodes,s);e&&i()});return n.observe(document,{childList:!0,subtree:!0}),n}const Ps=new Map;let Ds=0;function Es(){const t=window.devicePixelRatio;t!==Ds&&(Ds=t,Ps.forEach((e,i)=>{i.currentDevicePixelRatio!==t&&e()}))}function Cs(t,e,i){const s=t.canvas,n=s&&Ke(s);if(!n)return;const o=b((t,e)=>{const s=n.clientWidth;i(t,e),s{const e=t[0],i=e.contentRect.width,s=e.contentRect.height;0===i&&0===s||o(i,s)});return a.observe(n),function(t,e){Ps.size||window.addEventListener("resize",Es),Ps.set(t,e)}(t,o),a}function As(t,e,i){i&&i.disconnect(),"resize"===e&&function(t){Ps.delete(t),Ps.size||window.removeEventListener("resize",Es)}(t)}function Ts(t,e,i){const s=t.canvas,n=b(e=>{null!==t.ctx&&i(function(t,e){const i=ys[t.type]||t.type,{x:s,y:n}=ti(t,e);return{type:i,chart:e,native:t,x:void 0!==s?s:null,y:void 0!==n?n:null}}(e,t))},t,t=>{const e=t[0];return[e,e.offsetX,e.offsetY]});return function(t,e,i){t.addEventListener(e,i,ws)}(s,e,n),n}class Rs extends xs{acquireContext(t,e){const i=t&&t.getContext&&t.getContext("2d");return i&&i.canvas===t?(function(t,e){const i=t.style,s=t.getAttribute("height"),n=t.getAttribute("width");if(t.$chartjs={initial:{height:s,width:n,style:{display:i.display,height:i.height,width:i.width}}},i.display=i.display||"block",i.boxSizing=i.boxSizing||"border-box",vs(n)){const e=ni(t,"width");void 0!==e&&(t.width=e)}if(vs(s))if(""===t.style.height)t.height=t.width/(e||2);else{const e=ni(t,"height");void 0!==e&&(t.height=e)}}(t,e),i):null}releaseContext(t){const e=t.canvas;if(!e.$chartjs)return!1;const i=e.$chartjs.initial;["height","width"].forEach(t=>{const s=i[t];v(s)?e.removeAttribute(t):e.setAttribute(t,s)});const s=i.style||{};return Object.keys(s).forEach(t=>{e.style[t]=s[t]}),e.width=e.width,delete e.$chartjs,!0}addEventListener(t,e,i){this.removeEventListener(t,e);const s=t.$proxies||(t.$proxies={}),n={attach:Os,detach:Ss,resize:Cs}[e]||Ts;s[e]=n(t,e,i)}removeEventListener(t,e){const i=t.$proxies||(t.$proxies={}),s=i[e];s&&(({attach:As,detach:As,resize:As}[e]||Ms)(t,e,s),i[e]=void 0)}getDevicePixelRatio(){return window.devicePixelRatio}getMaximumSize(t,e,i,s){return function(t,e,i,s){const n=Ze(t),o=Je(n,"margin"),a=Ge(n.maxWidth,t,"clientWidth")||U,r=Ge(n.maxHeight,t,"clientHeight")||U,l=function(t,e,i){let s,n;if(void 0===e||void 0===i){const o=Ke(t);if(o){const t=o.getBoundingClientRect(),a=Ze(o),r=Je(a,"border","width"),l=Je(a,"padding");e=t.width-l.width-r.width,i=t.height-l.height-r.height,s=Ge(a.maxWidth,o,"clientWidth"),n=Ge(a.maxHeight,o,"clientHeight")}else e=t.clientWidth,i=t.clientHeight}return{width:e,height:i,maxWidth:s||U,maxHeight:n||U}}(t,e,i);let{width:h,height:c}=l;if("content-box"===n.boxSizing){const t=Je(n,"border","width"),e=Je(n,"padding");h-=e.width+t.width,c-=e.height+t.height}return h=Math.max(0,h-o.width),c=Math.max(0,s?Math.floor(h/s):c-o.height),h=ei(Math.min(h,a,l.maxWidth)),c=ei(Math.min(c,r,l.maxHeight)),h&&!c&&(c=ei(h/2)),{width:h,height:c}}(t,e,i,s)}isAttached(t){const e=Ke(t);return!(!e||!e.isConnected)}}class Ls{constructor(){this.x=void 0,this.y=void 0,this.active=!1,this.options=void 0,this.$animations=void 0}tooltipPosition(t){const{x:e,y:i}=this.getProps(["x","y"],t);return{x:e,y:i}}hasValue(){return tt(this.x)&&tt(this.y)}getProps(t,e){const i=this.$animations;if(!e||!i)return this;const s={};return t.forEach(t=>{s[t]=i[t]&&i[t].active()?i[t]._to:this[t]}),s}}Ls.defaults={},Ls.defaultRoutes=void 0;const js={values:t=>w(t)?t:""+t,numeric(t,e,i){if(0===t)return"0";const s=this.chart.options.locale;let n,o=t;if(i.length>1){const e=Math.max(Math.abs(i[0].value),Math.abs(i[i.length-1].value));(e<1e-4||e>1e15)&&(n="scientific"),o=function(t,e){let i=e.length>3?e[2].value-e[1].value:e[1].value-e[0].value;return Math.abs(i)>=1&&t!==Math.floor(t)&&(i=t-Math.floor(t)),i}(t,i)}const a=Z(Math.abs(o)),r=Math.max(Math.min(-1*Math.floor(a),20),0),l={notation:n,minimumFractionDigits:r,maximumFractionDigits:r};return Object.assign(l,this.options.ticks.format),hi(t,s,l)},logarithmic(t,e,i){if(0===t)return"0";const s=t/Math.pow(10,Math.floor(Z(t)));return 1===s||2===s||5===s?js.numeric.call(this,t,e,i):""}};var Is={formatters:js};function Fs(t,e,i,s,n){const o=S(s,0),a=Math.min(S(n,t.length),t.length);let r,l,h,c=0;for(i=Math.ceil(i),n&&(r=n-s,i=r/Math.floor(r/i)),h=o;h<0;)c++,h=Math.round(o+c*i);for(l=Math.max(o,0);le.lineWidth,tickColor:(t,e)=>e.color,offset:!1,borderDash:[],borderDashOffset:0,borderWidth:1},title:{display:!1,text:"",padding:{top:4,bottom:4}},ticks:{minRotation:0,maxRotation:50,mirror:!1,textStrokeWidth:0,textStrokeColor:"",padding:3,display:!0,autoSkip:!0,autoSkipPadding:3,labelOffset:0,callback:Is.formatters.values,minor:{},major:{},align:"center",crossAlign:"near",showLabelBackdrop:!1,backdropColor:"rgba(255, 255, 255, 0.75)",backdropPadding:2}}),Jt.route("scale.ticks","color","","color"),Jt.route("scale.grid","color","","borderColor"),Jt.route("scale.grid","borderColor","","borderColor"),Jt.route("scale.title","color","","color"),Jt.describe("scale",{_fallback:!1,_scriptable:t=>!t.startsWith("before")&&!t.startsWith("after")&&"callback"!==t&&"parser"!==t,_indexable:t=>"borderDash"!==t&&"tickBorderDash"!==t}),Jt.describe("scales",{_fallback:"scale"}),Jt.describe("scale.ticks",{_scriptable:t=>"backdropPadding"!==t&&"callback"!==t,_indexable:t=>"backdropPadding"!==t});const zs=(t,e,i)=>"top"===e||"left"===e?t[e]+i:t[e]-i;function Vs(t,e){const i=[],s=t.length/e,n=t.length;let o=0;for(;oa+1e-6)))return l}function Ns(t){return t.drawTicks?t.tickLength:0}function Ws(t,e){if(!t.display)return 0;const i=ye(t.font,e),s=_e(t.padding);return(w(t.text)?t.text.length:1)*i.lineHeight+s.height}function Hs(t,e,i){let s=(t=>"start"===t?"left":"end"===t?"right":"center")(t);return(i&&"right"!==e||!i&&"right"===e)&&(s=(t=>"left"===t?"right":"right"===t?"left":t)(s)),s}class $s extends Ls{constructor(t){super(),this.id=t.id,this.type=t.type,this.options=void 0,this.ctx=t.ctx,this.chart=t.chart,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.width=void 0,this.height=void 0,this._margins={left:0,right:0,top:0,bottom:0},this.maxWidth=void 0,this.maxHeight=void 0,this.paddingTop=void 0,this.paddingBottom=void 0,this.paddingLeft=void 0,this.paddingRight=void 0,this.axis=void 0,this.labelRotation=void 0,this.min=void 0,this.max=void 0,this._range=void 0,this.ticks=[],this._gridLineItems=null,this._labelItems=null,this._labelSizes=null,this._length=0,this._maxLength=0,this._longestTextCache={},this._startPixel=void 0,this._endPixel=void 0,this._reversePixels=!1,this._userMax=void 0,this._userMin=void 0,this._suggestedMax=void 0,this._suggestedMin=void 0,this._ticksLength=0,this._borderValue=0,this._cache={},this._dataLimitsCached=!1,this.$context=void 0}init(t){this.options=t.setContext(this.getContext()),this.axis=t.axis,this._userMin=this.parse(t.min),this._userMax=this.parse(t.max),this._suggestedMin=this.parse(t.suggestedMin),this._suggestedMax=this.parse(t.suggestedMax)}parse(t,e){return t}getUserBounds(){let{_userMin:t,_userMax:e,_suggestedMin:i,_suggestedMax:s}=this;return t=O(t,Number.POSITIVE_INFINITY),e=O(e,Number.NEGATIVE_INFINITY),i=O(i,Number.POSITIVE_INFINITY),s=O(s,Number.NEGATIVE_INFINITY),{min:O(t,i),max:O(e,s),minDefined:k(t),maxDefined:k(e)}}getMinMax(t){let e,{min:i,max:s,minDefined:n,maxDefined:o}=this.getUserBounds();if(n&&o)return{min:i,max:s};const a=this.getMatchingVisibleMetas();for(let r=0,l=a.length;rs?s:i,s=n&&i>s?i:s,{min:O(i,O(s,i)),max:O(s,O(i,s))}}getPadding(){return{left:this.paddingLeft||0,top:this.paddingTop||0,right:this.paddingRight||0,bottom:this.paddingBottom||0}}getTicks(){return this.ticks}getLabels(){const t=this.chart.data;return this.options.labels||(this.isHorizontal()?t.xLabels:t.yLabels)||t.labels||[]}beforeLayout(){this._cache={},this._dataLimitsCached=!1}beforeUpdate(){D(this.options.beforeUpdate,[this])}update(t,e,i){const{beginAtZero:s,grace:n,ticks:o}=this.options,a=o.sampleSize;this.beforeUpdate(),this.maxWidth=t,this.maxHeight=e,this._margins=i=Object.assign({left:0,right:0,top:0,bottom:0},i),this.ticks=null,this._labelSizes=null,this._gridLineItems=null,this._labelItems=null,this.beforeSetDimensions(),this.setDimensions(),this.afterSetDimensions(),this._maxLength=this.isHorizontal()?this.width+i.left+i.right:this.height+i.top+i.bottom,this._dataLimitsCached||(this.beforeDataLimits(),this.determineDataLimits(),this.afterDataLimits(),this._range=function(t,e,i){const{min:s,max:n}=t,o=P(e,(n-s)/2),a=(t,e)=>i&&0===t?0:t+e;return{min:a(s,-Math.abs(o)),max:a(n,o)}}(this,n,s),this._dataLimitsCached=!0),this.beforeBuildTicks(),this.ticks=this.buildTicks()||[],this.afterBuildTicks();const r=as)return function(t,e,i,s){let n,o=0,a=i[0];for(s=Math.ceil(s),n=0;nt-e).pop(),e}(s);for(let t=0,e=o.length-1;tn)return e}return Math.max(n,1)}(n,e,s);if(o>0){let t,i;const s=o>1?Math.round((r-a)/(o-1)):null;for(Fs(e,l,h,v(s)?0:a-s,a),t=0,i=o-1;t=n||i<=1||!this.isHorizontal())return void(this.labelRotation=s);const h=this._getLabelSizes(),c=h.widest.width,d=h.highest.height,u=dt(this.chart.width-c,0,this.maxWidth);o=t.offset?this.maxWidth/i:u/(i-1),c+6>o&&(o=u/(i-(t.offset?.5:1)),a=this.maxHeight-Ns(t.grid)-e.padding-Ws(t.title,this.chart.options.font),r=Math.sqrt(c*c+d*d),l=nt(Math.min(Math.asin(dt((h.highest.height+6)/o,-1,1)),Math.asin(dt(a/r,-1,1))-Math.asin(dt(d/r,-1,1)))),l=Math.max(s,Math.min(n,l))),this.labelRotation=l}afterCalculateLabelRotation(){D(this.options.afterCalculateLabelRotation,[this])}beforeFit(){D(this.options.beforeFit,[this])}fit(){const t={width:0,height:0},{chart:e,options:{ticks:i,title:s,grid:n}}=this,o=this._isVisible(),a=this.isHorizontal();if(o){const o=Ws(s,e.options.font);if(a?(t.width=this.maxWidth,t.height=Ns(n)+o):(t.height=this.maxHeight,t.width=Ns(n)+o),i.display&&this.ticks.length){const{first:e,last:s,widest:n,highest:o}=this._getLabelSizes(),r=2*i.padding,l=st(this.labelRotation),h=Math.cos(l),c=Math.sin(l);if(a){const e=i.mirror?0:c*n.width+h*o.height;t.height=Math.min(this.maxHeight,t.height+e+r)}else{const e=i.mirror?0:h*n.width+c*o.height;t.width=Math.min(this.maxWidth,t.width+e+r)}this._calculatePadding(e,s,c,h)}}this._handleMargins(),a?(this.width=this._length=e.width-this._margins.left-this._margins.right,this.height=t.height):(this.width=t.width,this.height=this._length=e.height-this._margins.top-this._margins.bottom)}_calculatePadding(t,e,i,s){const{ticks:{align:n,padding:o},position:a}=this.options,r=0!==this.labelRotation,l="top"!==a&&"x"===this.axis;if(this.isHorizontal()){const a=this.getPixelForTick(0)-this.left,h=this.right-this.getPixelForTick(this.ticks.length-1);let c=0,d=0;r?l?(c=s*t.width,d=i*e.height):(c=i*t.height,d=s*e.width):"start"===n?d=e.width:"end"===n?c=t.width:(c=t.width/2,d=e.width/2),this.paddingLeft=Math.max((c-a+o)*this.width/(this.width-a),0),this.paddingRight=Math.max((d-h+o)*this.width/(this.width-h),0)}else{let i=e.height/2,s=t.height/2;"start"===n?(i=0,s=t.height):"end"===n&&(i=e.height,s=0),this.paddingTop=i+o,this.paddingBottom=s+o}}_handleMargins(){this._margins&&(this._margins.left=Math.max(this.paddingLeft,this._margins.left),this._margins.top=Math.max(this.paddingTop,this._margins.top),this._margins.right=Math.max(this.paddingRight,this._margins.right),this._margins.bottom=Math.max(this.paddingBottom,this._margins.bottom))}afterFit(){D(this.options.afterFit,[this])}isHorizontal(){const{axis:t,position:e}=this.options;return"top"===e||"bottom"===e||"x"===t}isFullSize(){return this.options.fullSize}_convertTicksToLabels(t){let e,i;for(this.beforeTickToLabelConversion(),this.generateTickLabels(t),e=0,i=t.length;e{const i=t.gc,s=i.length/2;let n;if(s>e){for(n=0;n({width:n[t]||0,height:o[t]||0});return{first:M(0),last:M(e-1),widest:M(_),highest:M(y),widths:n,heights:o}}getLabelForValue(t){return t}getPixelForValue(t,e){return NaN}getValueForPixel(t){}getPixelForTick(t){const e=this.ticks;return t<0||t>e.length-1?null:this.getPixelForValue(e[t].value)}getPixelForDecimal(t){this._reversePixels&&(t=1-t);const e=this._startPixel+t*this._length;return dt(this._alignToPixels?ie(this.chart,e,0):e,-32768,32767)}getDecimalForPixel(t){const e=(t-this._startPixel)/this._length;return this._reversePixels?1-e:e}getBasePixel(){return this.getPixelForValue(this.getBaseValue())}getBaseValue(){const{min:t,max:e}=this;return t<0&&e<0?e:t>0&&e>0?t:0}getContext(t){const e=this.ticks||[];if(t>=0&&ta*s?a/i:r/s:r*s0}_computeGridLineItems(t){const e=this.axis,i=this.chart,s=this.options,{grid:n,position:o}=s,a=n.offset,r=this.isHorizontal(),l=this.ticks.length+(a?1:0),h=Ns(n),c=[],d=n.setContext(this.getContext()),u=d.drawBorder?d.borderWidth:0,f=u/2,p=function(t){return ie(i,t,u)};let g,m,b,x,_,y,v,w,k,O,P,D;if("top"===o)g=p(this.bottom),y=this.bottom-h,w=g-f,O=p(t.top)+f,D=t.bottom;else if("bottom"===o)g=p(this.top),O=t.top,D=p(t.bottom)-f,y=g+f,w=this.top+h;else if("left"===o)g=p(this.right),_=this.right-h,v=g-f,k=p(t.left)+f,P=t.right;else if("right"===o)g=p(this.left),k=t.left,P=p(t.right)-f,_=g+f,v=this.left+h;else if("x"===e){if("center"===o)g=p((t.top+t.bottom)/2+.5);else if(M(o)){const t=Object.keys(o)[0],e=o[t];g=p(this.chart.scales[t].getPixelForValue(e))}O=t.top,D=t.bottom,y=g+f,w=y+h}else if("y"===e){if("center"===o)g=p((t.left+t.right)/2);else if(M(o)){const t=Object.keys(o)[0],e=o[t];g=p(this.chart.scales[t].getPixelForValue(e))}_=g-f,v=_-h,k=t.left,P=t.right}const E=S(s.ticks.maxTicksLimit,l),C=Math.max(1,Math.ceil(l/E));for(m=0;me.value===t);return i>=0?e.setContext(this.getContext(i)).lineWidth:0}drawGrid(t){const e=this.options.grid,i=this.ctx,s=this._gridLineItems||(this._gridLineItems=this._computeGridLineItems(t));let n,o;const a=(t,e,s)=>{s.width&&s.color&&(i.save(),i.lineWidth=s.width,i.strokeStyle=s.color,i.setLineDash(s.borderDash||[]),i.lineDashOffset=s.borderDashOffset,i.beginPath(),i.moveTo(t.x,t.y),i.lineTo(e.x,e.y),i.stroke(),i.restore())};if(e.display)for(n=0,o=s.length;n{this.drawBackground(),this.drawGrid(t),this.drawTitle()}},{z:i+1,draw:()=>{this.drawBorder()}},{z:e,draw:t=>{this.drawLabels(t)}}]:[{z:e,draw:t=>{this.draw(t)}}]}getMatchingVisibleMetas(t){const e=this.chart.getSortedVisibleDatasetMetas(),i=this.axis+"AxisID",s=[];let n,o;for(n=0,o=e.length;n{const s=i.split("."),n=s.pop(),o=[t].concat(s).join("."),a=e[i].split("."),r=a.pop(),l=a.join(".");Jt.route(o,n,l,r)})}(e,t.defaultRoutes),t.descriptors&&Jt.describe(e,t.descriptors)}(t,o,i),this.override&&Jt.override(t.id,t.overrides)),o}get(t){return this.items[t]}unregister(t){const e=this.items,i=t.id,s=this.scope;i in e&&delete e[i],s&&i in Jt[s]&&(delete Jt[s][i],this.override&&delete Kt[i])}}var Us=new class{constructor(){this.controllers=new Ys(Ri,"datasets",!0),this.elements=new Ys(Ls,"elements"),this.plugins=new Ys(Object,"plugins"),this.scales=new Ys($s,"scales"),this._typedRegistries=[this.controllers,this.scales,this.elements]}add(...t){this._each("register",t)}remove(...t){this._each("unregister",t)}addControllers(...t){this._each("register",t,this.controllers)}addElements(...t){this._each("register",t,this.elements)}addPlugins(...t){this._each("register",t,this.plugins)}addScales(...t){this._each("register",t,this.scales)}getController(t){return this._get(t,this.controllers,"controller")}getElement(t){return this._get(t,this.elements,"element")}getPlugin(t){return this._get(t,this.plugins,"plugin")}getScale(t){return this._get(t,this.scales,"scale")}removeControllers(...t){this._each("unregister",t,this.controllers)}removeElements(...t){this._each("unregister",t,this.elements)}removePlugins(...t){this._each("unregister",t,this.plugins)}removeScales(...t){this._each("unregister",t,this.scales)}_each(t,e,i){[...e].forEach(e=>{const s=i||this._getRegistryForType(e);i||s.isForType(e)||s===this.plugins&&e.id?this._exec(t,s,e):E(e,e=>{const s=i||this._getRegistryForType(e);this._exec(t,s,e)})})}_exec(t,e,i){const s=V(t);D(i["before"+s],[],i),e[t](i),D(i["after"+s],[],i)}_getRegistryForType(t){for(let e=0;et.filter(t=>!e.some(e=>t.plugin.id===e.plugin.id));this._notify(s(e,i),t,"stop"),this._notify(s(i,e),t,"start")}}function qs(t,e){return e||!1!==t?!0===t?{}:t:null}function Ks(t,e,i,s){const n=t.pluginScopeKeys(e),o=t.getOptionScopes(i,n);return t.createResolver(o,s,[""],{scriptable:!1,indexable:!1,allKeys:!0})}function Gs(t,e){const i=Jt.datasets[t]||{};return((e.datasets||{})[t]||{}).indexAxis||e.indexAxis||i.indexAxis||"x"}function Zs(t,e){return"x"===t||"y"===t?t:e.axis||("top"===(i=e.position)||"bottom"===i?"x":"left"===i||"right"===i?"y":void 0)||t.charAt(0).toLowerCase();var i}function Qs(t){const e=t.options||(t.options={});e.plugins=S(e.plugins,{}),e.scales=function(t,e){const i=Kt[t.type]||{scales:{}},s=e.scales||{},n=Gs(t.type,e),o=Object.create(null),a=Object.create(null);return Object.keys(s).forEach(t=>{const e=s[t];if(!M(e))return console.error("Invalid scale configuration for scale: "+t);if(e._proxy)return console.warn("Ignoring resolver passed as options for scale: "+t);const r=Zs(t,e),l=function(t,e){return t===e?"_index_":"_value_"}(r,n),h=i.scales||{};o[r]=o[r]||t,a[t]=j(Object.create(null),[{axis:r},e,h[r],h[l]])}),t.data.datasets.forEach(i=>{const n=i.type||t.type,r=i.indexAxis||Gs(n,e),l=(Kt[n]||{}).scales||{};Object.keys(l).forEach(t=>{const e=function(t,e){let i=t;return"_index_"===t?i=e:"_value_"===t&&(i="x"===e?"y":"x"),i}(t,r),n=i[e+"AxisID"]||o[e]||e;a[n]=a[n]||Object.create(null),j(a[n],[{axis:e},s[n],l[t]])})}),Object.keys(a).forEach(t=>{const e=a[t];j(e,[Jt.scales[e.type],Jt.scale])}),a}(t,e)}function Js(t){return(t=t||{}).datasets=t.datasets||[],t.labels=t.labels||[],t}const tn=new Map,en=new Set;function sn(t,e){let i=tn.get(t);return i||(i=e(),tn.set(t,i),en.add(i)),i}const nn=(t,e,i)=>{const s=z(e,i);void 0!==s&&t.add(s)};class on{constructor(t){this._config=function(t){return(t=t||{}).data=Js(t.data),Qs(t),t}(t),this._scopeCache=new Map,this._resolverCache=new Map}get platform(){return this._config.platform}get type(){return this._config.type}set type(t){this._config.type=t}get data(){return this._config.data}set data(t){this._config.data=Js(t)}get options(){return this._config.options}set options(t){this._config.options=t}get plugins(){return this._config.plugins}update(){const t=this._config;this.clearCache(),Qs(t)}clearCache(){this._scopeCache.clear(),this._resolverCache.clear()}datasetScopeKeys(t){return sn(t,()=>[["datasets."+t,""]])}datasetAnimationScopeKeys(t,e){return sn(`${t}.transition.${e}`,()=>[[`datasets.${t}.transitions.${e}`,"transitions."+e],["datasets."+t,""]])}datasetElementScopeKeys(t,e){return sn(`${t}-${e}`,()=>[[`datasets.${t}.elements.${e}`,"datasets."+t,"elements."+e,""]])}pluginScopeKeys(t){const e=t.id;return sn(`${this.type}-plugin-${e}`,()=>[["plugins."+e,...t.additionalOptionScopes||[]]])}_cachedScopes(t,e){const i=this._scopeCache;let s=i.get(t);return s&&!e||(s=new Map,i.set(t,s)),s}getOptionScopes(t,e,i){const{options:s,type:n}=this,o=this._cachedScopes(t,i),a=o.get(e);if(a)return a;const r=new Set;e.forEach(e=>{t&&(r.add(t),e.forEach(e=>nn(r,t,e))),e.forEach(t=>nn(r,s,t)),e.forEach(t=>nn(r,Kt[n]||{},t)),e.forEach(t=>nn(r,Jt,t)),e.forEach(t=>nn(r,Gt,t))});const l=Array.from(r);return 0===l.length&&l.push(Object.create(null)),en.has(e)&&o.set(e,l),l}chartOptionScopes(){const{options:t,type:e}=this;return[t,Kt[e]||{},Jt.datasets[e]||{},{type:e},Jt,Gt]}resolveNamedOptions(t,e,i,s=[""]){const n={$shared:!0},{resolver:o,subPrefixes:a}=an(this._resolverCache,t,s);let r=o;(function(t,e){const{isScriptable:i,isIndexable:s}=Ae(t);for(const n of e){const e=i(n),o=s(n),a=(o||e)&&t[n];if(e&&(N(a)||rn(a))||o&&w(a))return!0}return!1})(o,e)&&(n.$shared=!1,r=Ce(o,i=N(i)?i():i,this.createResolver(t,i,a)));for(const t of e)n[t]=r[t];return n}createResolver(t,e,i=[""],s){const{resolver:n}=an(this._resolverCache,t,i);return M(e)?Ce(n,e,void 0,s):n}}function an(t,e,i){let s=t.get(e);s||(s=new Map,t.set(e,s));const n=i.join();let o=s.get(n);return o||(o={resolver:Ee(e,i),subPrefixes:i.filter(t=>!t.toLowerCase().includes("hover"))},s.set(n,o)),o}const rn=t=>M(t)&&Object.getOwnPropertyNames(t).reduce((e,i)=>e||N(t[i]),!1),ln=["top","bottom","left","right","chartArea"];function hn(t,e){return"top"===t||"bottom"===t||-1===ln.indexOf(t)&&"x"===e}function cn(t,e){return function(i,s){return i[t]===s[t]?i[e]-s[e]:i[t]-s[t]}}function dn(t){const e=t.chart,i=e.options.animation;e.notifyPlugins("afterRender"),D(i&&i.onComplete,[t],e)}function un(t){const e=t.chart,i=e.options.animation;D(i&&i.onProgress,[t],e)}function fn(t){return qe()&&"string"==typeof t?t=document.getElementById(t):t&&t.length&&(t=t[0]),t&&t.canvas&&(t=t.canvas),t}const pn={},gn=t=>{const e=fn(t);return Object.values(pn).filter(t=>t.canvas===e).pop()};function mn(t,e,i){const s=Object.keys(t);for(const n of s){const s=+n;if(s>=e){const o=t[n];delete t[n],(i>0||s>e)&&(t[s+i]=o)}}}class bn{constructor(t,e){const i=this.config=new on(e),s=fn(t),n=gn(s);if(n)throw new Error("Canvas is already in use. Chart with ID '"+n.id+"' must be destroyed before the canvas can be reused.");const o=i.createResolver(i.chartOptionScopes(),this.getContext());this.platform=new(i.platform||function(t){return!qe()||"undefined"!=typeof OffscreenCanvas&&t instanceof OffscreenCanvas?_s:Rs}(s)),this.platform.updateConfig(i);const a=this.platform.acquireContext(s,o.aspectRatio),r=a&&a.canvas,l=r&&r.height,h=r&&r.width;this.id=y(),this.ctx=a,this.canvas=r,this.width=h,this.height=l,this._options=o,this._aspectRatio=this.aspectRatio,this._layers=[],this._metasets=[],this._stacks=void 0,this.boxes=[],this.currentDevicePixelRatio=void 0,this.chartArea=void 0,this._active=[],this._lastEvent=void 0,this._listeners={},this._responsiveListeners=void 0,this._sortedMetasets=[],this.scales={},this._plugins=new Xs,this.$proxies={},this._hiddenIndices={},this.attached=!1,this._animationsDisabled=void 0,this.$context=void 0,this._doResize=function(t,e){let i;return function(...s){return e?(clearTimeout(i),i=setTimeout(t,e,s)):t.apply(this,s),e}}(t=>this.update(t),o.resizeDelay||0),this._dataChanges=[],pn[this.id]=this,a&&r?(bi.listen(this,"complete",dn),bi.listen(this,"progress",un),this._initialize(),this.attached&&this.update()):console.error("Failed to create chart: can't acquire context from the given item")}get aspectRatio(){const{options:{aspectRatio:t,maintainAspectRatio:e},width:i,height:s,_aspectRatio:n}=this;return v(t)?e&&n?n:s?i/s:null:t}get data(){return this.config.data}set data(t){this.config.data=t}get options(){return this._options}set options(t){this.config.options=t}_initialize(){return this.notifyPlugins("beforeInit"),this.options.responsive?this.resize():ii(this,this.options.devicePixelRatio),this.bindEvents(),this.notifyPlugins("afterInit"),this}clear(){return se(this.canvas,this.ctx),this}stop(){return bi.stop(this),this}resize(t,e){bi.running(this)?this._resizeBeforeDraw={width:t,height:e}:this._resize(t,e)}_resize(t,e){const i=this.options,s=this.canvas,n=i.maintainAspectRatio&&this.aspectRatio,o=this.platform.getMaximumSize(s,t,e,n),a=i.devicePixelRatio||this.platform.getDevicePixelRatio(),r=this.width?"resize":"attach";this.width=o.width,this.height=o.height,this._aspectRatio=this.aspectRatio,ii(this,a,!0)&&(this.notifyPlugins("resize",{size:o}),D(i.onResize,[this,o],this),this.attached&&this._doResize(r)&&this.render())}ensureScalesHaveIDs(){E(this.options.scales||{},(t,e)=>{t.id=e})}buildOrUpdateScales(){const t=this.options,e=t.scales,i=this.scales,s=Object.keys(i).reduce((t,e)=>(t[e]=!1,t),{});let n=[];e&&(n=n.concat(Object.keys(e).map(t=>{const i=e[t],s=Zs(t,i),n="r"===s,o="x"===s;return{options:i,dposition:n?"chartArea":o?"bottom":"left",dtype:n?"radialLinear":o?"category":"linear"}}))),E(n,e=>{const n=e.options,o=n.id,a=Zs(o,n),r=S(n.type,e.dtype);void 0!==n.position&&hn(n.position,a)===hn(e.dposition)||(n.position=e.dposition),s[o]=!0;let l=null;o in i&&i[o].type===r?l=i[o]:(l=new(Us.getScale(r))({id:o,type:r,ctx:this.ctx,chart:this}),i[l.id]=l),l.init(n,t)}),E(s,(t,e)=>{t||delete i[e]}),E(i,t=>{bs.configure(this,t,t.options),bs.addBox(this,t)})}_updateMetasets(){const t=this._metasets,e=this.data.datasets.length,i=t.length;if(t.sort((t,e)=>t.index-e.index),i>e){for(let t=e;te.length&&delete this._stacks,t.forEach((t,i)=>{0===e.filter(e=>e===t._dataset).length&&this._destroyDatasetMeta(i)})}buildOrUpdateControllers(){const t=[],e=this.data.datasets;let i,s;for(this._removeUnreferencedMetasets(),i=0,s=e.length;i{this.getDatasetMeta(e).controller.reset()},this)}reset(){this._resetElements(),this.notifyPlugins("reset")}update(t){const e=this.config;e.update();const i=this._options=e.createResolver(e.chartOptionScopes(),this.getContext()),s=this._animationsDisabled=!i.animation;if(this._updateScales(),this._checkEventBindings(),this._updateHiddenIndices(),this._plugins.invalidate(),!1===this.notifyPlugins("beforeUpdate",{mode:t,cancelable:!0}))return;const n=this.buildOrUpdateControllers();this.notifyPlugins("beforeElementsUpdate");let o=0;for(let t=0,e=this.data.datasets.length;t{t.reset()}),this._updateDatasets(t),this.notifyPlugins("afterUpdate",{mode:t}),this._layers.sort(cn("z","_idx"));const{_active:a,_lastEvent:r}=this;r?this._eventHandler(r,!0):a.length&&this._updateHoverStyles(a,a,!0),this.render()}_updateScales(){E(this.scales,t=>{bs.removeBox(this,t)}),this.ensureScalesHaveIDs(),this.buildOrUpdateScales()}_checkEventBindings(){const t=this.options,e=new Set(Object.keys(this._listeners)),i=new Set(t.events);W(e,i)&&!!this._responsiveListeners===t.responsive||(this.unbindEvents(),this.bindEvents())}_updateHiddenIndices(){const{_hiddenIndices:t}=this,e=this._getUniformDataChanges()||[];for(const{method:i,start:s,count:n}of e)mn(t,s,"_removeElements"===i?-n:n)}_getUniformDataChanges(){const t=this._dataChanges;if(!t||!t.length)return;this._dataChanges=[];const e=this.data.datasets.length,i=e=>new Set(t.filter(t=>t[0]===e).map((t,e)=>e+","+t.splice(1).join(","))),s=i(0);for(let t=1;tt.split(",")).map(t=>({method:t[1],start:+t[2],count:+t[3]}))}_updateLayout(t){if(!1===this.notifyPlugins("beforeLayout",{cancelable:!0}))return;bs.update(this,this.width,this.height,t);const e=this.chartArea,i=e.width<=0||e.height<=0;this._layers=[],E(this.boxes,t=>{i&&"chartArea"===t.position||(t.configure&&t.configure(),this._layers.push(...t._layers()))},this),this._layers.forEach((t,e)=>{t._idx=e}),this.notifyPlugins("afterLayout")}_updateDatasets(t){if(!1!==this.notifyPlugins("beforeDatasetsUpdate",{mode:t,cancelable:!0})){for(let t=0,e=this.data.datasets.length;t=0;--e)this._drawDataset(t[e]);this.notifyPlugins("afterDatasetsDraw")}_drawDataset(t){const e=this.ctx,i=t._clip,s=!i.disabled,n=this.chartArea,o={meta:t,index:t.index,cancelable:!0};!1!==this.notifyPlugins("beforeDatasetDraw",o)&&(s&&ae(e,{left:!1===i.left?0:n.left-i.left,right:!1===i.right?this.width:n.right+i.right,top:!1===i.top?0:n.top-i.top,bottom:!1===i.bottom?this.height:n.bottom+i.bottom}),t.controller.draw(),s&&re(e),o.cancelable=!1,this.notifyPlugins("afterDatasetDraw",o))}getElementsAtEventForMode(t,e,i,s){const n=os.modes[e];return"function"==typeof n?n(this,t,i,s):[]}getDatasetMeta(t){const e=this.data.datasets[t],i=this._metasets;let s=i.filter(t=>t&&t._dataset===e).pop();return s||(s={type:null,data:[],dataset:null,controller:null,hidden:null,xAxisID:null,yAxisID:null,order:e&&e.order||0,index:t,_dataset:e,_parsed:[],_sorted:!1},i.push(s)),s}getContext(){return this.$context||(this.$context=we(null,{chart:this,type:"chart"}))}getVisibleDatasetCount(){return this.getSortedVisibleDatasetMetas().length}isDatasetVisible(t){const e=this.data.datasets[t];if(!e)return!1;const i=this.getDatasetMeta(t);return"boolean"==typeof i.hidden?!i.hidden:!e.hidden}setDatasetVisibility(t,e){this.getDatasetMeta(t).hidden=!e}toggleDataVisibility(t){this._hiddenIndices[t]=!this._hiddenIndices[t]}getDataVisibility(t){return!this._hiddenIndices[t]}_updateVisibility(t,e,i){const s=i?"show":"hide",n=this.getDatasetMeta(t),o=n.controller._resolveAnimations(void 0,s);B(e)?(n.data[e].hidden=!i,this.update()):(this.setDatasetVisibility(t,i),o.update(n,{visible:i}),this.update(e=>e.datasetIndex===t?s:void 0))}hide(t,e){this._updateVisibility(t,e,!1)}show(t,e){this._updateVisibility(t,e,!0)}_destroyDatasetMeta(t){const e=this._metasets[t];e&&e.controller&&e.controller._destroy(),delete this._metasets[t]}_stop(){let t,e;for(this.stop(),bi.remove(this),t=0,e=this.data.datasets.length;t{e.addEventListener(this,i,s),t[i]=s},s=(t,e,i)=>{t.offsetX=e,t.offsetY=i,this._eventHandler(t)};E(this.options.events,t=>i(t,s))}bindResponsiveEvents(){this._responsiveListeners||(this._responsiveListeners={});const t=this._responsiveListeners,e=this.platform,i=(i,s)=>{e.addEventListener(this,i,s),t[i]=s},s=(i,s)=>{t[i]&&(e.removeEventListener(this,i,s),delete t[i])},n=(t,e)=>{this.canvas&&this.resize(t,e)};let o;const a=()=>{s("attach",a),this.attached=!0,this.resize(),i("resize",n),i("detach",o)};o=()=>{this.attached=!1,s("resize",n),this._stop(),this._resize(0,0),i("attach",a)},e.isAttached(this.canvas)?a():o()}unbindEvents(){E(this._listeners,(t,e)=>{this.platform.removeEventListener(this,e,t)}),this._listeners={},E(this._responsiveListeners,(t,e)=>{this.platform.removeEventListener(this,e,t)}),this._responsiveListeners=void 0}updateHoverStyle(t,e,i){const s=i?"set":"remove";let n,o,a,r;for("dataset"===e&&(n=this.getDatasetMeta(t[0].datasetIndex),n.controller["_"+s+"DatasetHoverStyle"]()),a=0,r=t.length;a{const i=this.getDatasetMeta(t);if(!i)throw new Error("No dataset found at index "+t);return{datasetIndex:t,element:i.data[e],index:e}});!C(i,e)&&(this._active=i,this._lastEvent=null,this._updateHoverStyles(i,e))}notifyPlugins(t,e,i){return this._plugins.notify(this,t,e,i)}_updateHoverStyles(t,e,i){const s=this.options.hover,n=(t,e)=>t.filter(t=>!e.some(e=>t.datasetIndex===e.datasetIndex&&t.index===e.index)),o=n(e,t),a=i?t:n(t,e);o.length&&this.updateHoverStyle(o,s.mode,!1),a.length&&s.mode&&this.updateHoverStyle(a,s.mode,!0)}_eventHandler(t,e){const i={event:t,replay:e,cancelable:!0,inChartArea:oe(t,this.chartArea,this._minPadding)},s=e=>(e.options.events||this.options.events).includes(t.native.type);if(!1===this.notifyPlugins("beforeEvent",i,s))return;const n=this._handleEvent(t,e,i.inChartArea);return i.cancelable=!1,this.notifyPlugins("afterEvent",i,s),(n||i.changed)&&this.render(),this}_handleEvent(t,e,i){const{_active:s=[],options:n}=this,o=e,a=this._getActiveElements(t,s,i,o),r=function(t){return"mouseup"===t.type||"click"===t.type||"contextmenu"===t.type}(t),l=function(t,e,i,s){return i&&"mouseout"!==t.type?s?e:t:null}(t,this._lastEvent,i,r);i&&(this._lastEvent=null,D(n.onHover,[t,a,this],this),r&&D(n.onClick,[t,a,this],this));const h=!C(a,s);return(h||e)&&(this._active=a,this._updateHoverStyles(a,s,e)),this._lastEvent=l,h}_getActiveElements(t,e,i,s){if("mouseout"===t.type)return[];if(!i)return e;const n=this.options.hover;return this.getElementsAtEventForMode(t,n.mode,n,s)}}const xn=()=>E(bn.instances,t=>t._plugins.invalidate());function yn(t,e,i){const{startAngle:s,pixelMargin:n,x:o,y:a,outerRadius:r,innerRadius:l}=e;let h=n/r;t.beginPath(),t.arc(o,a,r,s-h,i+h),l>n?(h=n/l,t.arc(o,a,l,i+h,s-h,!0)):t.arc(o,a,n,i+q,s-q),t.closePath(),t.clip()}function vn(t,e,i,s){return{x:i+t*Math.cos(e),y:s+t*Math.sin(e)}}function wn(t,e,i,s,n){const{x:o,y:a,startAngle:r,pixelMargin:l,innerRadius:h}=e,c=Math.max(e.outerRadius+s+i-l,0),d=h>0?h+s+i+l:0;let u=0;const f=n-r;if(s){const t=((h>0?h-s:0)+(c>0?c-s:0))/2;u=(f-(0!==t?f*t/(t+s):f))/2}const p=(f-Math.max(.001,f*c-i/H)/c)/2,g=r+p+u,m=n-p-u,{outerStart:b,outerEnd:x,innerStart:_,innerEnd:y}=function(t,e,i,s){const n=me(t.options.borderRadius,["outerStart","outerEnd","innerStart","innerEnd"]),o=(i-e)/2,a=Math.min(o,s*e/2),r=t=>{const e=(i-Math.min(o,t))*s/2;return dt(t,0,Math.min(o,e))};return{outerStart:r(n.outerStart),outerEnd:r(n.outerEnd),innerStart:dt(n.innerStart,0,a),innerEnd:dt(n.innerEnd,0,a)}}(e,d,c,m-g),v=c-b,w=c-x,M=g+b/v,k=m-x/w,O=d+_,S=d+y,P=g+_/O,D=m-y/S;if(t.beginPath(),t.arc(o,a,c,M,k),x>0){const e=vn(w,k,o,a);t.arc(e.x,e.y,x,k,m+q)}const E=vn(S,m,o,a);if(t.lineTo(E.x,E.y),y>0){const e=vn(S,D,o,a);t.arc(e.x,e.y,y,m+q,D+Math.PI)}if(t.arc(o,a,d,m-y/d,g+_/d,!0),_>0){const e=vn(O,P,o,a);t.arc(e.x,e.y,_,P+Math.PI,g-q)}const C=vn(v,g,o,a);if(t.lineTo(C.x,C.y),b>0){const e=vn(v,M,o,a);t.arc(e.x,e.y,b,g-q,M)}t.closePath()}Object.defineProperties(bn,{defaults:{enumerable:!0,value:Jt},instances:{enumerable:!0,value:pn},overrides:{enumerable:!0,value:Kt},registry:{enumerable:!0,value:Us},version:{enumerable:!0,value:"3.7.1"},getChart:{enumerable:!0,value:gn},register:{enumerable:!0,value:(...t)=>{Us.add(...t),xn()}},unregister:{enumerable:!0,value:(...t)=>{Us.remove(...t),xn()}}});class Mn extends Ls{constructor(t){super(),this.options=void 0,this.circumference=void 0,this.startAngle=void 0,this.endAngle=void 0,this.innerRadius=void 0,this.outerRadius=void 0,this.pixelMargin=0,this.fullCircles=0,t&&Object.assign(this,t)}inRange(t,e,i){const s=this.getProps(["x","y"],i),{angle:n,distance:o}=at(s,{x:t,y:e}),{startAngle:a,endAngle:r,innerRadius:l,outerRadius:h,circumference:c}=this.getProps(["startAngle","endAngle","innerRadius","outerRadius","circumference"],i),d=this.options.spacing/2,u=S(c,r-a)>=$||ct(n,a,r),f=ut(o,l+d,h+d);return u&&f}getCenterPoint(t){const{x:e,y:i,startAngle:s,endAngle:n,innerRadius:o,outerRadius:a}=this.getProps(["x","y","startAngle","endAngle","innerRadius","outerRadius","circumference"],t),{offset:r,spacing:l}=this.options,h=(s+n)/2,c=(o+a+l+r)/2;return{x:e+Math.cos(h)*c,y:i+Math.sin(h)*c}}tooltipPosition(t){return this.getCenterPoint(t)}draw(t){const{options:e,circumference:i}=this,s=(e.offset||0)/2,n=(e.spacing||0)/2;if(this.pixelMargin="inner"===e.borderAlign?.33:0,this.fullCircles=i>$?Math.floor(i/$):0,0===i||this.innerRadius<0||this.outerRadius<0)return;t.save();let o=0;if(s){o=s/2;const e=(this.startAngle+this.endAngle)/2;t.translate(Math.cos(e)*o,Math.sin(e)*o),this.circumference>=H&&(o=s)}t.fillStyle=e.backgroundColor,t.strokeStyle=e.borderColor;const a=function(t,e,i,s){const{fullCircles:n,startAngle:o,circumference:a}=e;let r=e.endAngle;if(n){wn(t,e,i,s,o+$);for(let e=0;er&&o>r;return{count:s,start:l,loop:e.loop,ilen:h(a+(h?r-t:t))%o,_=()=>{f!==p&&(t.lineTo(m,p),t.lineTo(m,f),t.lineTo(m,g))};for(l&&(d=n[x(0)],t.moveTo(d.x,d.y)),c=0;c<=r;++c){if(d=n[x(c)],d.skip)continue;const e=d.x,i=d.y,s=0|e;s===u?(ip&&(p=i),m=(b*m+e)/++b):(_(),t.lineTo(e,i),u=s,b=0,f=p=i),g=i}_()}function En(t){const e=t.options,i=e.borderDash&&e.borderDash.length;return t._decimated||t._loop||e.tension||"monotone"===e.cubicInterpolationMode||e.stepped||i?Pn:Dn}Mn.id="arc",Mn.defaults={borderAlign:"center",borderColor:"#fff",borderJoinStyle:void 0,borderRadius:0,borderWidth:2,offset:0,spacing:0,angle:void 0},Mn.defaultRoutes={backgroundColor:"backgroundColor"};const Cn="function"==typeof Path2D;class An extends Ls{constructor(t){super(),this.animated=!0,this.options=void 0,this._chart=void 0,this._loop=void 0,this._fullLoop=void 0,this._path=void 0,this._points=void 0,this._segments=void 0,this._decimated=!1,this._pointsUpdated=!1,this._datasetIndex=void 0,t&&Object.assign(this,t)}updateControlPoints(t,e){const i=this.options;if((i.tension||"monotone"===i.cubicInterpolationMode)&&!i.stepped&&!this._pointsUpdated){const s=i.spanGaps?this._loop:this._fullLoop;Xe(this._points,i,t,s,e),this._pointsUpdated=!0}}set points(t){this._points=t,delete this._segments,delete this._path,this._pointsUpdated=!1}get points(){return this._points}get segments(){return this._segments||(this._segments=function(t,e){const i=t.points,s=t.options.spanGaps,n=i.length;if(!n)return[];const o=!!t._loop,{start:a,end:r}=function(t,e,i,s){let n=0,o=e-1;if(i&&!s)for(;nn&&t[o%e].skip;)o--;return o%=e,{start:n,end:o}}(i,n,o,s);return function(t,e,i,s){return s&&s.setContext&&i?function(t,e,i,s){const n=t._chart.getContext(),o=gi(t.options),{_datasetIndex:a,options:{spanGaps:r}}=t,l=i.length,h=[];let c=o,d=e[0].start,u=d;function f(t,e,s,n){const o=r?-1:1;if(t!==e){for(t+=l;i[t%l].skip;)t-=o;for(;i[e%l].skip;)e+=o;t%l!=e%l&&(h.push({start:t%l,end:e%l,loop:s,style:n}),c=n,d=e%l)}}for(const t of e){d=r?d:t.start;let e,o=i[d%l];for(u=d+1;u<=t.end;u++){const r=i[u%l];e=gi(s.setContext(we(n,{type:"segment",p0:o,p1:r,p0DataIndex:(u-1)%l,p1DataIndex:u%l,datasetIndex:a}))),mi(e,c)&&f(d,u-1,t.loop,c),o=r,c=e}d"borderDash"!==t&&"fill"!==t};class Rn extends Ls{constructor(t){super(),this.options=void 0,this.parsed=void 0,this.skip=void 0,this.stop=void 0,t&&Object.assign(this,t)}inRange(t,e,i){const s=this.options,{x:n,y:o}=this.getProps(["x","y"],i);return Math.pow(t-n,2)+Math.pow(e-o,2)=i)&&n):["origin","start","end","stack","shape"].indexOf(s)>=0&&s}Vn.id="bar",Vn.defaults={borderSkipped:"start",borderWidth:0,borderRadius:0,inflateAmount:"auto",pointStyle:void 0},Vn.defaultRoutes={backgroundColor:"backgroundColor",borderColor:"borderColor"};class Nn{constructor(t){this.x=t.x,this.y=t.y,this.radius=t.radius}pathSegment(t,e,i){const{x:s,y:n,radius:o}=this;return e=e||{start:0,end:$},t.arc(s,n,o,e.end,e.start,!0),!i.bounds}interpolate(t){const{x:e,y:i,radius:s}=this,n=t.angle;return{x:e+Math.cos(n)*s,y:i+Math.sin(n)*s,angle:n}}}function Wn(t,e,i){for(;e>t;e--){const t=i[e];if(!isNaN(t.x)&&!isNaN(t.y))break}return e}function Hn(t,e,i){const s=[];for(let n=0;n{e=Wn(t,e,n);const a=n[t],r=n[e];null!==s?(o.push({x:a.x,y:s}),o.push({x:r.x,y:s})):null!==i&&(o.push({x:i,y:a.y}),o.push({x:i,y:r.y}))}),o}(t,e),i.length?new An({points:i,options:{tension:0},_loop:s,_fullLoop:s}):null}function Xn(t,e,i){let s=t[e].fill;const n=[e];let o;if(!i)return s;for(;!1!==s&&-1===n.indexOf(s);){if(!k(s))return s;if(o=t[s],!o)return!1;if(o.visible)return s;n.push(s),s=o.fill}return!1}function qn(t,e,i){const{segments:s,points:n}=e;let o=!0,a=!1;t.beginPath();for(const r of s){const{start:s,end:l}=r,h=n[s],c=n[Wn(s,l,n)];o?(t.moveTo(h.x,h.y),o=!1):(t.lineTo(h.x,i),t.lineTo(h.x,h.y)),a=!!e.pathSegment(t,r,{move:a}),a?t.closePath():t.lineTo(c.x,i)}t.lineTo(e.first().x,i),t.closePath(),t.clip()}function Kn(t,e,i,s){if(s)return;let n=e[t],o=i[t];return"angle"===t&&(n=ht(n),o=ht(o)),{property:t,start:n,end:o}}function Gn(t,e,i,s){return t&&e?s(t[i],e[i]):t?t[i]:e?e[i]:0}function Zn(t,e,i){const{top:s,bottom:n}=e.chart.chartArea,{property:o,start:a,end:r}=i||{};"x"===o&&(t.beginPath(),t.rect(a,s,r-a,n-s),t.clip())}function Qn(t,e,i,s){const n=e.interpolate(i,s);n&&t.lineTo(n.x,n.y)}function Jn(t,e){const{line:i,target:s,property:n,color:o,scale:a}=e,r=function(t,e,i){const s=t.segments,n=t.points,o=e.points,a=[];for(const t of s){let{start:s,end:r}=t;r=Wn(s,r,n);const l=Kn(i,n[s],n[r],t.loop);if(!e.segments){a.push({source:t,target:l,start:n[s],end:n[r]});continue}const h=pi(e,l);for(const e of h){const s=Kn(i,o[e.start],o[e.end],e.loop),r=fi(t,n,s);for(const t of r)a.push({source:t,target:e,start:{[i]:Gn(l,s,"start",Math.max)},end:{[i]:Gn(l,s,"end",Math.min)}})}}return a}(i,s,n);for(const{source:e,target:l,start:h,end:c}of r){const{style:{backgroundColor:r=o}={}}=e,d=!0!==s;t.save(),t.fillStyle=r,Zn(t,a,d&&Kn(n,h,c)),t.beginPath();const u=!!i.pathSegment(t,e);let f;if(d){u?t.closePath():Qn(t,s,c,n);const e=!!s.pathSegment(t,l,{move:u,reverse:!0});f=u&&e,f||Qn(t,s,h,n)}t.closePath(),t.fill(f?"evenodd":"nonzero"),t.restore()}}function to(t,e,i){const s=Yn(e),{line:n,scale:o,axis:a}=e,r=n.options,l=r.fill,h=r.backgroundColor,{above:c=h,below:d=h}=l||{};s&&n.points.length&&(ae(t,i),function(t,e){const{line:i,target:s,above:n,below:o,area:a,scale:r}=e,l=i._loop?"angle":e.axis;t.save(),"x"===l&&o!==n&&(qn(t,s,a.top),Jn(t,{line:i,target:s,color:n,scale:r,property:l}),t.restore(),t.save(),qn(t,s,a.bottom)),Jn(t,{line:i,target:s,color:o,scale:r,property:l}),t.restore()}(t,{line:n,target:s,above:c,below:d,area:i,scale:o,axis:a}),re(t))}var eo={id:"filler",afterDatasetsUpdate(t,e,i){const s=(t.data.datasets||[]).length,n=[];let o,a,r,l;for(a=0;a=0;--e){const i=n[e].$filler;i&&(i.line.updateControlPoints(o,i.axis),s&&to(t.ctx,i,o))}},beforeDatasetsDraw(t,e,i){if("beforeDatasetsDraw"!==i.drawTime)return;const s=t.getSortedVisibleDatasetMetas();for(let e=s.length-1;e>=0;--e){const i=s[e].$filler;i&&to(t.ctx,i,t.chartArea)}},beforeDatasetDraw(t,e,i){const s=e.meta.$filler;s&&!1!==s.fill&&"beforeDatasetDraw"===i.drawTime&&to(t.ctx,s,t.chartArea)},defaults:{propagate:!0,drawTime:"beforeDatasetDraw"}};new WeakMap;const io={average(t){if(!t.length)return!1;let e,i,s=0,n=0,o=0;for(e=0,i=t.length;e-1?t.split("\n"):t}function oo(t,e){const{element:i,datasetIndex:s,index:n}=e,o=t.getDatasetMeta(s).controller,{label:a,value:r}=o.getLabelAndValue(n);return{chart:t,label:a,parsed:o.getParsed(n),raw:t.data.datasets[s].data[n],formattedValue:r,dataset:o.getDataset(),dataIndex:n,datasetIndex:s,element:i}}function ao(t,e){const i=t.chart.ctx,{body:s,footer:n,title:o}=t,{boxWidth:a,boxHeight:r}=e,l=ye(e.bodyFont),h=ye(e.titleFont),c=ye(e.footerFont),d=o.length,u=n.length,f=s.length,p=_e(e.padding);let g=p.height,m=0,b=s.reduce((t,e)=>t+e.before.length+e.lines.length+e.after.length,0);b+=t.beforeBody.length+t.afterBody.length,d&&(g+=d*h.lineHeight+(d-1)*e.titleSpacing+e.titleMarginBottom),b&&(g+=f*(e.displayColors?Math.max(r,l.lineHeight):l.lineHeight)+(b-f)*l.lineHeight+(b-1)*e.bodySpacing),u&&(g+=e.footerMarginTop+u*c.lineHeight+(u-1)*e.footerSpacing);let x=0;const _=function(t){m=Math.max(m,i.measureText(t).width+x)};return i.save(),i.font=h.string,E(t.title,_),i.font=l.string,E(t.beforeBody.concat(t.afterBody),_),x=e.displayColors?a+2+e.boxPadding:0,E(s,t=>{E(t.before,_),E(t.lines,_),E(t.after,_)}),x=0,i.font=c.string,E(t.footer,_),i.restore(),m+=p.width,{width:m,height:g}}function ro(t,e,i,s){const{x:n,width:o}=i,{width:a,chartArea:{left:r,right:l}}=t;let h="center";return"center"===s?h=n<=(r+l)/2?"left":"right":n<=o/2?h="left":n>=a-o/2&&(h="right"),function(t,e,i,s){const{x:n,width:o}=s,a=i.caretSize+i.caretPadding;return"left"===t&&n+o+a>e.width||"right"===t&&n-o-a<0||void 0}(h,t,e,i)&&(h="center"),h}function lo(t,e,i){const s=i.yAlign||e.yAlign||function(t,e){const{y:i,height:s}=e;return it.height-s/2?"bottom":"center"}(t,i);return{xAlign:i.xAlign||e.xAlign||ro(t,e,i,s),yAlign:s}}function ho(t,e,i,s){const{caretSize:n,caretPadding:o,cornerRadius:a}=t,{xAlign:r,yAlign:l}=i,h=n+o,{topLeft:c,topRight:d,bottomLeft:u,bottomRight:f}=xe(a);let p=function(t,e){let{x:i,width:s}=t;return"right"===e?i-=s:"center"===e&&(i-=s/2),i}(e,r);const g=function(t,e,i){let{y:s,height:n}=t;return"top"===e?s+=i:s-="bottom"===e?n+i:n/2,s}(e,l,h);return"center"===l?"left"===r?p+=h:"right"===r&&(p-=h):"left"===r?p-=Math.max(c,u)+n:"right"===r&&(p+=Math.max(d,f)+n),{x:dt(p,0,s.width-e.width),y:dt(g,0,s.height-e.height)}}function co(t,e,i){const s=_e(i.padding);return"center"===e?t.x+t.width/2:"right"===e?t.x+t.width-s.right:t.x+s.left}function uo(t){return so([],no(t))}function fo(t,e){const i=e&&e.dataset&&e.dataset.tooltip&&e.dataset.tooltip.callbacks;return i?t.override(i):t}class po extends Ls{constructor(t){super(),this.opacity=0,this._active=[],this._eventPosition=void 0,this._size=void 0,this._cachedAnimations=void 0,this._tooltipItems=[],this.$animations=void 0,this.$context=void 0,this.chart=t.chart||t._chart,this._chart=this.chart,this.options=t.options,this.dataPoints=void 0,this.title=void 0,this.beforeBody=void 0,this.body=void 0,this.afterBody=void 0,this.footer=void 0,this.xAlign=void 0,this.yAlign=void 0,this.x=void 0,this.y=void 0,this.height=void 0,this.width=void 0,this.caretX=void 0,this.caretY=void 0,this.labelColors=void 0,this.labelPointStyles=void 0,this.labelTextColors=void 0}initialize(t){this.options=t,this._cachedAnimations=void 0,this.$context=void 0}_resolveAnimations(){const t=this._cachedAnimations;if(t)return t;const e=this.chart,i=this.options.setContext(this.getContext()),s=i.enabled&&e.options.animation&&i.animations,n=new vi(this.chart,s);return s._cacheable&&(this._cachedAnimations=Object.freeze(n)),n}getContext(){return this.$context||(this.$context=(this,we(this.chart.getContext(),{tooltip:this,tooltipItems:this._tooltipItems,type:"tooltip"})))}getTitle(t,e){const{callbacks:i}=e,s=i.beforeTitle.apply(this,[t]),n=i.title.apply(this,[t]),o=i.afterTitle.apply(this,[t]);let a=[];return a=so(a,no(s)),a=so(a,no(n)),a=so(a,no(o)),a}getBeforeBody(t,e){return uo(e.callbacks.beforeBody.apply(this,[t]))}getBody(t,e){const{callbacks:i}=e,s=[];return E(t,t=>{const e={before:[],lines:[],after:[]},n=fo(i,t);so(e.before,no(n.beforeLabel.call(this,t))),so(e.lines,n.label.call(this,t)),so(e.after,no(n.afterLabel.call(this,t))),s.push(e)}),s}getAfterBody(t,e){return uo(e.callbacks.afterBody.apply(this,[t]))}getFooter(t,e){const{callbacks:i}=e,s=i.beforeFooter.apply(this,[t]),n=i.footer.apply(this,[t]),o=i.afterFooter.apply(this,[t]);let a=[];return a=so(a,no(s)),a=so(a,no(n)),a=so(a,no(o)),a}_createItems(t){const e=this._active,i=this.chart.data,s=[],n=[],o=[];let a,r,l=[];for(a=0,r=e.length;at.filter(e,s,n,i))),t.itemSort&&(l=l.sort((e,s)=>t.itemSort(e,s,i))),E(l,e=>{const i=fo(t.callbacks,e);s.push(i.labelColor.call(this,e)),n.push(i.labelPointStyle.call(this,e)),o.push(i.labelTextColor.call(this,e))}),this.labelColors=s,this.labelPointStyles=n,this.labelTextColors=o,this.dataPoints=l,l}update(t,e){const i=this.options.setContext(this.getContext()),s=this._active;let n,o=[];if(s.length){const t=io[i.position].call(this,s,this._eventPosition);o=this._createItems(i),this.title=this.getTitle(o,i),this.beforeBody=this.getBeforeBody(o,i),this.body=this.getBody(o,i),this.afterBody=this.getAfterBody(o,i),this.footer=this.getFooter(o,i);const e=this._size=ao(this,i),a=Object.assign({},t,e),r=lo(this.chart,i,a),l=ho(i,a,r,this.chart);this.xAlign=r.xAlign,this.yAlign=r.yAlign,n={opacity:1,x:l.x,y:l.y,width:e.width,height:e.height,caretX:t.x,caretY:t.y}}else 0!==this.opacity&&(n={opacity:0});this._tooltipItems=o,this.$context=void 0,n&&this._resolveAnimations().update(this,n),t&&i.external&&i.external.call(this,{chart:this.chart,tooltip:this,replay:e})}drawCaret(t,e,i,s){const n=this.getCaretPosition(t,i,s);e.lineTo(n.x1,n.y1),e.lineTo(n.x2,n.y2),e.lineTo(n.x3,n.y3)}getCaretPosition(t,e,i){const{xAlign:s,yAlign:n}=this,{caretSize:o,cornerRadius:a}=i,{topLeft:r,topRight:l,bottomLeft:h,bottomRight:c}=xe(a),{x:d,y:u}=t,{width:f,height:p}=e;let g,m,b,x,_,y;return"center"===n?(_=u+p/2,"left"===s?(g=d,m=g-o,x=_+o,y=_-o):(g=d+f,m=g+o,x=_-o,y=_+o),b=g):(m="left"===s?d+Math.max(r,h)+o:"right"===s?d+f-Math.max(l,c)-o:this.caretX,"top"===n?(x=u,_=x-o,g=m-o,b=m+o):(x=u+p,_=x+o,g=m+o,b=m-o),y=x),{x1:g,x2:m,x3:b,y1:x,y2:_,y3:y}}drawTitle(t,e,i){const s=this.title,n=s.length;let o,a,r;if(n){const l=ci(i.rtl,this.x,this.width);for(t.x=co(this,i.titleAlign,i),e.textAlign=l.textAlign(i.titleAlign),e.textBaseline="middle",o=ye(i.titleFont),a=i.titleSpacing,e.fillStyle=i.titleColor,e.font=o.string,r=0;r0!==t)?(t.beginPath(),t.fillStyle=n.multiKeyBackground,ue(t,{x:e,y:p,w:l,h:r,radius:a}),t.fill(),t.stroke(),t.fillStyle=o.backgroundColor,t.beginPath(),ue(t,{x:i,y:p+1,w:l-2,h:r-2,radius:a}),t.fill()):(t.fillStyle=n.multiKeyBackground,t.fillRect(e,p,l,r),t.strokeRect(e,p,l,r),t.fillStyle=o.backgroundColor,t.fillRect(i,p+1,l-2,r-2))}t.fillStyle=this.labelTextColors[i]}drawBody(t,e,i){const{body:s}=this,{bodySpacing:n,bodyAlign:o,displayColors:a,boxHeight:r,boxWidth:l,boxPadding:h}=i,c=ye(i.bodyFont);let d=c.lineHeight,u=0;const f=ci(i.rtl,this.x,this.width),p=function(i){e.fillText(i,f.x(t.x+u),t.y+d/2),t.y+=d+n},g=f.textAlign(o);let m,b,x,_,y,v,w;for(e.textAlign=o,e.textBaseline="middle",e.font=c.string,t.x=co(this,g,i),e.fillStyle=i.bodyColor,E(this.beforeBody,p),u=a&&"right"!==g?"center"===o?l/2+h:l+2+h:0,_=0,v=s.length;_0&&e.stroke()}_updateAnimationTarget(t){const e=this.chart,i=this.$animations,s=i&&i.x,n=i&&i.y;if(s||n){const i=io[t.position].call(this,this._active,this._eventPosition);if(!i)return;const o=this._size=ao(this,t),a=Object.assign({},i,this._size),r=lo(e,t,a),l=ho(t,a,r,e);s._to===l.x&&n._to===l.y||(this.xAlign=r.xAlign,this.yAlign=r.yAlign,this.width=o.width,this.height=o.height,this.caretX=i.x,this.caretY=i.y,this._resolveAnimations().update(this,l))}}draw(t){const e=this.options.setContext(this.getContext());let i=this.opacity;if(!i)return;this._updateAnimationTarget(e);const s={width:this.width,height:this.height},n={x:this.x,y:this.y};i=Math.abs(i)<.001?0:i;const o=_e(e.padding),a=this.title.length||this.beforeBody.length||this.body.length||this.afterBody.length||this.footer.length;e.enabled&&a&&(t.save(),t.globalAlpha=i,this.drawBackground(n,t,s,e),function(t,e){let i,s;"ltr"!==e&&"rtl"!==e||(i=t.canvas.style,s=[i.getPropertyValue("direction"),i.getPropertyPriority("direction")],i.setProperty("direction",e,"important"),t.prevTextDirection=s)}(t,e.textDirection),n.y+=o.top,this.drawTitle(n,t,e),this.drawBody(n,t,e),this.drawFooter(n,t,e),function(t,e){void 0!==e&&(delete t.prevTextDirection,t.canvas.style.setProperty("direction",e[0],e[1]))}(t,e.textDirection),t.restore())}getActiveElements(){return this._active||[]}setActiveElements(t,e){const i=this._active,s=t.map(({datasetIndex:t,index:e})=>{const i=this.chart.getDatasetMeta(t);if(!i)throw new Error("Cannot find a dataset at index "+t);return{datasetIndex:t,element:i.data[e],index:e}}),n=!C(i,s),o=this._positionChanged(s,e);(n||o)&&(this._active=s,this._eventPosition=e,this._ignoreReplayEvents=!0,this.update(!0))}handleEvent(t,e,i=!0){if(e&&this._ignoreReplayEvents)return!1;this._ignoreReplayEvents=!1;const s=this.options,n=this._active||[],o=this._getActiveElements(t,n,e,i),a=this._positionChanged(o,t),r=e||!C(o,n)||a;return r&&(this._active=o,(s.enabled||s.external)&&(this._eventPosition={x:t.x,y:t.y},this.update(!0,e))),r}_getActiveElements(t,e,i,s){const n=this.options;if("mouseout"===t.type)return[];if(!s)return e;const o=this.chart.getElementsAtEventForMode(t,n.mode,n,i);return n.reverse&&o.reverse(),o}_positionChanged(t,e){const{caretX:i,caretY:s,options:n}=this,o=io[n.position].call(this,t,e);return!1!==o&&(i!==o.x||s!==o.y)}}po.positioners=io;var go={id:"tooltip",_element:po,positioners:io,afterInit(t,e,i){i&&(t.tooltip=new po({chart:t,options:i}))},beforeUpdate(t,e,i){t.tooltip&&t.tooltip.initialize(i)},reset(t,e,i){t.tooltip&&t.tooltip.initialize(i)},afterDraw(t){const e=t.tooltip,i={tooltip:e};!1!==t.notifyPlugins("beforeTooltipDraw",i)&&(e&&e.draw(t.ctx),t.notifyPlugins("afterTooltipDraw",i))},afterEvent(t,e){if(t.tooltip){const i=e.replay;t.tooltip.handleEvent(e.event,i,e.inChartArea)&&(e.changed=!0)}},defaults:{enabled:!0,external:null,position:"average",backgroundColor:"rgba(0,0,0,0.8)",titleColor:"#fff",titleFont:{weight:"bold"},titleSpacing:2,titleMarginBottom:6,titleAlign:"left",bodyColor:"#fff",bodySpacing:2,bodyFont:{},bodyAlign:"left",footerColor:"#fff",footerSpacing:2,footerMarginTop:6,footerFont:{weight:"bold"},footerAlign:"left",padding:6,caretPadding:2,caretSize:5,cornerRadius:6,boxHeight:(t,e)=>e.bodyFont.size,boxWidth:(t,e)=>e.bodyFont.size,multiKeyBackground:"#fff",displayColors:!0,boxPadding:0,borderColor:"rgba(0,0,0,0)",borderWidth:0,animation:{duration:400,easing:"easeOutQuart"},animations:{numbers:{type:"number",properties:["x","y","width","height","caretX","caretY"]},opacity:{easing:"linear",duration:200}},callbacks:{beforeTitle:_,title(t){if(t.length>0){const e=t[0],i=e.chart.data.labels,s=i?i.length:0;if(this&&this.options&&"dataset"===this.options.mode)return e.dataset.label||"";if(e.label)return e.label;if(s>0&&e.dataIndex"filter"!==t&&"itemSort"!==t&&"external"!==t,_indexable:!1,callbacks:{_scriptable:!1,_indexable:!1},animation:{_fallback:!1},animations:{_fallback:"animation"}},additionalOptionScopes:["interaction"]};class mo extends $s{constructor(t){super(t),this._startValue=void 0,this._valueRange=0,this._addedLabels=[]}init(t){const e=this._addedLabels;if(e.length){const t=this.getLabels();for(const{index:i,label:s}of e)t[i]===s&&t.splice(i,1);this._addedLabels=[]}super.init(t)}parse(t,e){if(v(t))return null;const i=this.getLabels();return((t,e)=>null===t?null:dt(Math.round(t),0,e))(e=isFinite(e)&&i[e]===t?e:function(t,e,i,s){const n=t.indexOf(e);return-1===n?((t,e,i,s)=>("string"==typeof e?(i=t.push(e)-1,s.unshift({index:i,label:e})):isNaN(e)&&(i=null),i))(t,e,i,s):n!==t.lastIndexOf(e)?i:n}(i,t,S(e,t),this._addedLabels),i.length-1)}determineDataLimits(){const{minDefined:t,maxDefined:e}=this.getUserBounds();let{min:i,max:s}=this.getMinMax(!0);"ticks"===this.options.bounds&&(t||(i=0),e||(s=this.getLabels().length-1)),this.min=i,this.max=s}buildTicks(){const t=this.min,e=this.max,i=this.options.offset,s=[];let n=this.getLabels();n=0===t&&e===n.length-1?n:n.slice(t,e+1),this._valueRange=Math.max(n.length-(i?0:1),1),this._startValue=this.min-(i?.5:0);for(let i=t;i<=e;i++)s.push({value:i});return s}getLabelForValue(t){const e=this.getLabels();return t>=0&&te.length-1?null:this.getPixelForValue(e[t].value)}getValueForPixel(t){return Math.round(this._startValue+this.getDecimalForPixel(t)*this._valueRange)}getBasePixel(){return this.bottom}}function bo(t,e,{horizontal:i,minRotation:s}){const n=st(s),o=(i?Math.sin(n):Math.cos(n))||.001,a=.75*e*(""+t).length;return Math.min(e/o,a)}mo.id="category",mo.defaults={ticks:{callback:mo.prototype.getLabelForValue}};class xo extends $s{constructor(t){super(t),this.start=void 0,this.end=void 0,this._startValue=void 0,this._endValue=void 0,this._valueRange=0}parse(t,e){return v(t)||("number"==typeof t||t instanceof Number)&&!isFinite(+t)?null:+t}handleTickRangeOptions(){const{beginAtZero:t}=this.options,{minDefined:e,maxDefined:i}=this.getUserBounds();let{min:s,max:n}=this;const o=t=>s=e?s:t,a=t=>n=i?n:t;if(t){const t=Q(s),e=Q(n);t<0&&e<0?a(0):t>0&&e>0&&o(0)}if(s===n){let e=1;(n>=Number.MAX_SAFE_INTEGER||s<=Number.MIN_SAFE_INTEGER)&&(e=Math.abs(.05*n)),a(n+e),t||o(s-e)}this.min=s,this.max=n}getTickLimit(){const t=this.options.ticks;let e,{maxTicksLimit:i,stepSize:s}=t;return s?(e=Math.ceil(this.max/s)-Math.floor(this.min/s)+1,e>1e3&&(console.warn(`scales.${this.id}.ticks.stepSize: ${s} would result generating up to ${e} ticks. Limiting to 1000.`),e=1e3)):(e=this.computeTickLimit(),i=i||11),i&&(e=Math.min(i,e)),e}computeTickLimit(){return Number.POSITIVE_INFINITY}buildTicks(){const t=this.options,e=t.ticks;let i=this.getTickLimit();i=Math.max(2,i);const s=function(t,e){const i=[],{bounds:s,step:n,min:o,max:a,precision:r,count:l,maxTicks:h,maxDigits:c,includeBounds:d}=t,u=n||1,f=h-1,{min:p,max:g}=e,m=!v(o),b=!v(a),x=!v(l),_=(g-p)/(c+1);let y,w,M,k,O=J((g-p)/f/u)*u;if(O<1e-14&&!m&&!b)return[{value:p},{value:g}];k=Math.ceil(g/O)-Math.floor(p/O),k>f&&(O=J(k*O/f/u)*u),v(r)||(y=Math.pow(10,r),O=Math.ceil(O*y)/y),"ticks"===s?(w=Math.floor(p/O)*O,M=Math.ceil(g/O)*O):(w=p,M=g),m&&b&&n&&function(t,e){const i=Math.round(t);return i-e<=t&&i+e>=t}((a-o)/n,O/1e3)?(k=Math.round(Math.min((a-o)/O,h)),O=(a-o)/k,w=o,M=a):x?(w=m?o:w,M=b?a:M,k=l-1,O=(M-w)/k):(k=(M-w)/O,k=et(k,Math.round(k),O/1e3)?Math.round(k):Math.ceil(k));const S=Math.max(ot(O),ot(w));y=Math.pow(10,v(r)?S:r),w=Math.round(w*y)/y,M=Math.round(M*y)/y;let P=0;for(m&&(d&&w!==o?(i.push({value:o}),w0?i:null;this._zero=!0}determineDataLimits(){const{min:t,max:e}=this.getMinMax(!0);this.min=k(t)?Math.max(0,t):null,this.max=k(e)?Math.max(0,e):null,this.options.beginAtZero&&(this._zero=!0),this.handleTickRangeOptions()}handleTickRangeOptions(){const{minDefined:t,maxDefined:e}=this.getUserBounds();let i=this.min,s=this.max;const n=e=>i=t?i:e,o=t=>s=e?s:t,a=(t,e)=>Math.pow(10,Math.floor(Z(t))+e);i===s&&(i<=0?(n(1),o(10)):(n(a(i,-1)),o(a(s,1)))),i<=0&&n(a(s,-1)),s<=0&&o(a(i,1)),this._zero&&this.min!==this._suggestedMin&&i===a(this.min,0)&&n(a(i,-1)),this.min=i,this.max=s}buildTicks(){const t=this.options,e=function(t,e){const i=Math.floor(Z(e.max)),s=Math.ceil(e.max/Math.pow(10,i)),n=[];let o=O(t.min,Math.pow(10,Math.floor(Z(e.min)))),a=Math.floor(Z(o)),r=Math.floor(o/Math.pow(10,a)),l=a<0?Math.pow(10,Math.abs(a)):1;do{n.push({value:o,major:yo(o)}),++r,10===r&&(r=1,++a,l=a>=0?1:l),o=Math.round(r*Math.pow(10,a)*l)/l}while(an?{start:e-i,end:e}:{start:e,end:e+i}}function ko(t,e,i,s,n){const o=Math.abs(Math.sin(i)),a=Math.abs(Math.cos(i));let r=0,l=0;s.starte.r&&(r=(s.end-e.r)/o,t.r=Math.max(t.r,e.r+r)),n.starte.b&&(l=(n.end-e.b)/a,t.b=Math.max(t.b,e.b+l))}function Oo(t){return 0===t||180===t?"center":t<180?"left":"right"}function So(t,e,i){return 90===i||270===i?t-=e/2:(i>270||i<90)&&(t-=e),t}function Po(t,e,i,s){const{ctx:n}=t;if(i)n.arc(t.xCenter,t.yCenter,e,0,$);else{let i=t.getPointPosition(0,e);n.moveTo(i.x,i.y);for(let o=1;o{const i=D(this.options.pointLabels.callback,[t,e],this);return i||0===i?i:""}).filter((t,e)=>this.chart.getDataVisibility(e))}fit(){const t=this.options;t.display&&t.pointLabels.display?function(t){const e={l:t.left+t._padding.left,r:t.right-t._padding.right,t:t.top+t._padding.top,b:t.bottom-t._padding.bottom},i=Object.assign({},e),s=[],n=[],o=t._pointLabels.length,a=t.options.pointLabels,r=a.centerPointLabels?H/o:0;for(let d=0;d=0&&t=0;n--){const e=s.setContext(t.getPointLabelContext(n)),o=ye(e.font),{x:a,y:r,textAlign:l,left:h,top:c,right:d,bottom:u}=t._pointLabelItems[n],{backdropColor:f}=e;if(!v(f)){const t=_e(e.backdropPadding);i.fillStyle=f,i.fillRect(h-t.left,c-t.top,d-h+t.width,u-c+t.height)}ce(i,t._pointLabels[n],a,r+o.lineHeight/2,o,{color:e.color,textAlign:l,textBaseline:"middle"})}}(this,n),s.display&&this.ticks.forEach((t,e)=>{0!==e&&(a=this.getDistanceFromCenterForValue(t.value),function(t,e,i,s){const n=t.ctx,o=e.circular,{color:a,lineWidth:r}=e;!o&&!s||!a||!r||i<0||(n.save(),n.strokeStyle=a,n.lineWidth=r,n.setLineDash(e.borderDash),n.lineDashOffset=e.borderDashOffset,n.beginPath(),Po(t,i,o,s),n.closePath(),n.stroke(),n.restore())}(this,s.setContext(this.getContext(e-1)),a,n))}),i.display){for(t.save(),o=n-1;o>=0;o--){const s=i.setContext(this.getPointLabelContext(o)),{color:n,lineWidth:l}=s;l&&n&&(t.lineWidth=l,t.strokeStyle=n,t.setLineDash(s.borderDash),t.lineDashOffset=s.borderDashOffset,a=this.getDistanceFromCenterForValue(e.ticks.reverse?this.min:this.max),r=this.getPointPosition(o,a),t.beginPath(),t.moveTo(this.xCenter,this.yCenter),t.lineTo(r.x,r.y),t.stroke())}t.restore()}}drawBorder(){}drawLabels(){const t=this.ctx,e=this.options,i=e.ticks;if(!i.display)return;const s=this.getIndexAngle(0);let n,o;t.save(),t.translate(this.xCenter,this.yCenter),t.rotate(s),t.textAlign="center",t.textBaseline="middle",this.ticks.forEach((s,a)=>{if(0===a&&!e.reverse)return;const r=i.setContext(this.getContext(a)),l=ye(r.font);if(n=this.getDistanceFromCenterForValue(this.ticks[a].value),r.showLabelBackdrop){t.font=l.string,o=t.measureText(s.label).width,t.fillStyle=r.backdropColor;const e=_e(r.backdropPadding);t.fillRect(-o/2-e.left,-n-l.size/2-e.top,o+e.width,l.size+e.height)}ce(t,s.label,0,-n,l,{color:r.color})}),t.restore()}drawTitle(){}}Do.id="radialLinear",Do.defaults={display:!0,animate:!0,position:"chartArea",angleLines:{display:!0,lineWidth:1,borderDash:[],borderDashOffset:0},grid:{circular:!1},startAngle:0,ticks:{showLabelBackdrop:!0,callback:Is.formatters.numeric},pointLabels:{backdropColor:void 0,backdropPadding:2,display:!0,font:{size:10},callback:t=>t,padding:5,centerPointLabels:!1}},Do.defaultRoutes={"angleLines.color":"borderColor","pointLabels.color":"color","ticks.color":"color"},Do.descriptors={angleLines:{_fallback:"grid"}};const Eo={millisecond:{common:!0,size:1,steps:1e3},second:{common:!0,size:1e3,steps:60},minute:{common:!0,size:6e4,steps:60},hour:{common:!0,size:36e5,steps:24},day:{common:!0,size:864e5,steps:30},week:{common:!1,size:6048e5,steps:4},month:{common:!0,size:2628e6,steps:12},quarter:{common:!1,size:7884e6,steps:4},year:{common:!0,size:3154e7}},Co=Object.keys(Eo);function Ao(t,e){return t-e}function To(t,e){if(v(e))return null;const i=t._adapter,{parser:s,round:n,isoWeekday:o}=t._parseOpts;let a=e;return"function"==typeof s&&(a=s(a)),k(a)||(a="string"==typeof s?i.parse(a,s):i.parse(a)),null===a?null:(n&&(a="week"!==n||!tt(o)&&!0!==o?i.startOf(a,n):i.startOf(a,"isoWeek",o)),+a)}function Ro(t,e,i,s){const n=Co.length;for(let o=Co.indexOf(t);o=e?i[s]:i[n]]=!0}}else t[e]=!0}function jo(t,e,i){const s=[],n={},o=e.length;let a,r;for(a=0;a=0&&(e[l].major=!0);return e}(t,s,n,i):s}class Io extends $s{constructor(t){super(t),this._cache={data:[],labels:[],all:[]},this._unit="day",this._majorUnit=void 0,this._offsets={},this._normalized=!1,this._parseOpts=void 0}init(t,e){const i=t.time||(t.time={}),s=this._adapter=new Qi._date(t.adapters.date);j(i.displayFormats,s.formats()),this._parseOpts={parser:i.parser,round:i.round,isoWeekday:i.isoWeekday},super.init(t),this._normalized=e.normalized}parse(t,e){return void 0===t?null:To(this,t)}beforeLayout(){super.beforeLayout(),this._cache={data:[],labels:[],all:[]}}determineDataLimits(){const t=this.options,e=this._adapter,i=t.time.unit||"day";let{min:s,max:n,minDefined:o,maxDefined:a}=this.getUserBounds();function r(t){o||isNaN(t.min)||(s=Math.min(s,t.min)),a||isNaN(t.max)||(n=Math.max(n,t.max))}o&&a||(r(this._getLabelBounds()),"ticks"===t.bounds&&"labels"===t.ticks.source||r(this.getMinMax(!1))),s=k(s)&&!isNaN(s)?s:+e.startOf(Date.now(),i),n=k(n)&&!isNaN(n)?n:+e.endOf(Date.now(),i)+1,this.min=Math.min(s,n-1),this.max=Math.max(s+1,n)}_getLabelBounds(){const t=this.getLabelTimestamps();let e=Number.POSITIVE_INFINITY,i=Number.NEGATIVE_INFINITY;return t.length&&(e=t[0],i=t[t.length-1]),{min:e,max:i}}buildTicks(){const t=this.options,e=t.time,i=t.ticks,s="labels"===i.source?this.getLabelTimestamps():this._generate();"ticks"===t.bounds&&s.length&&(this.min=this._userMin||s[0],this.max=this._userMax||s[s.length-1]);const n=this.min,o=function(t,e,i){let s=0,n=t.length;for(;ss&&t[n-1]>i;)n--;return s>0||n=Co.indexOf(i);o--){const i=Co[o];if(Eo[i].common&&t._adapter.diff(n,s,i)>=e-1)return i}return Co[i?Co.indexOf(i):0]}(this,o.length,e.minUnit,this.min,this.max)),this._majorUnit=i.major.enabled&&"year"!==this._unit?function(t){for(let e=Co.indexOf(t)+1,i=Co.length;e1e5*a)throw new Error(e+" and "+i+" are too far apart with stepSize of "+a+" "+o);const f="data"===s.ticks.source&&this.getDataTimestamps();for(c=u,d=0;ct-e).map(t=>+t)}getLabelForValue(t){const e=this._adapter,i=this.options.time;return i.tooltipFormat?e.format(t,i.tooltipFormat):e.format(t,i.displayFormats.datetime)}_tickFormatFunction(t,e,i,s){const n=this.options,o=n.time.displayFormats,a=this._unit,r=this._majorUnit,l=a&&o[a],h=r&&o[r],c=i[e],d=r&&h&&c&&c.major,u=this._adapter.format(t,s||(d?h:l)),f=n.ticks.callback;return f?D(f,[u,e,i],this):u}generateTickLabels(t){let e,i,s;for(e=0,i=t.length;e0?a:1}getDataTimestamps(){let t,e,i=this._cache.data||[];if(i.length)return i;const s=this.getMatchingVisibleMetas();if(this._normalized&&s.length)return this._cache.data=s[0].controller.getAllParsedValues(this);for(t=0,e=s.length;t=t[r].pos&&e<=t[l].pos&&({lo:r,hi:l}=ke(t,"pos",e)),({pos:s,time:o}=t[r]),({pos:n,time:a}=t[l])):(e>=t[r].time&&e<=t[l].time&&({lo:r,hi:l}=ke(t,"time",e)),({time:s,pos:o}=t[r]),({time:n,pos:a}=t[l]));const h=n-s;return h?o+(a-o)*(e-s)/h:o}Io.id="time",Io.defaults={bounds:"data",adapters:{},time:{parser:!1,unit:!1,round:!1,isoWeekday:!1,minUnit:"millisecond",displayFormats:{}},ticks:{source:"auto",major:{enabled:!1}}};class zo extends Io{constructor(t){super(t),this._table=[],this._minPos=void 0,this._tableRange=void 0}initOffsets(){const t=this._getTimestampsForTable(),e=this._table=this.buildLookupTable(t);this._minPos=Fo(e,this.min),this._tableRange=Fo(e,this.max)-this._minPos,super.initOffsets(t)}buildLookupTable(t){const{min:e,max:i}=this,s=[],n=[];let o,a,r,l,h;for(o=0,a=t.length;o=e&&l<=i&&s.push(l);if(s.length<2)return[{time:e,pos:0},{time:i,pos:1}];for(o=0,a=s.length;o2&&void 0!==arguments[2]?arguments[2]:"label";const s=[];t.datasets=e.map(e=>{const n=t.datasets.find(t=>t[i]===e[i]);return n&&e.data&&!s.includes(n)?(s.push(n),Object.assign(n,e),n):{...e}})}function $o(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"label";const i={labels:[],datasets:[]};return Wo(i,t.labels),Ho(i,t.datasets,e),i}function Yo(t,e){let{height:i=150,width:s=300,redraw:n=!1,datasetIdKey:o,type:a,data:r,options:l,plugins:h=[],fallbackContent:c,...d}=t;const u=Object(Vo.useRef)(null),f=Object(Vo.useRef)(),p=()=>{u.current&&(f.current=new bn(u.current,{type:a,data:$o(r,o),options:l,plugins:h}),No(e,f.current))},g=()=>{No(e,null),f.current&&(f.current.destroy(),f.current=null)};return Object(Vo.useEffect)(()=>{var t,e;!n&&f.current&&l&&(t=f.current,e=l,t.options={...e})},[n,l]),Object(Vo.useEffect)(()=>{!n&&f.current&&Wo(f.current.config.data,r.labels)},[n,r.labels]),Object(Vo.useEffect)(()=>{!n&&f.current&&r.datasets&&Ho(f.current.config.data,r.datasets,o)},[n,r.datasets]),Object(Vo.useEffect)(()=>{f.current&&(n?(g(),setTimeout(p)):f.current.update())},[n,l,r.labels,r.datasets]),Object(Vo.useEffect)(()=>(p(),()=>g()),[]),Bo.a.createElement("canvas",Object.assign({ref:u,role:"img",height:i,width:s},d),c)}const Uo=Object(Vo.forwardRef)(Yo);function Xo(t,e){return bn.register(e),Object(Vo.forwardRef)((e,i)=>Bo.a.createElement(Uo,Object.assign({},e,{ref:i,type:t})))}const qo=Xo("line",Yi);var Ko=i(2),Go=i(24),Zo={id:"chartBorder",beforeDraw:function(t,e,i){var s=t.ctx,n=t.chartArea,o=n.left,a=n.top,r=n.width,l=n.height;s.save(),s.strokeStyle=i.borderColor||"#ccc",s.lineWidth=i.borderWidth||1,s.strokeRect(o,a,r,l),s.restore()}},Qo=i(8);function Jo(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);e&&(s=s.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),i.push.apply(i,s)}return i}function ta(t){for(var e=1;et.length)&&(e=t.length);for(var i=0,s=new Array(e);iArray.prototype.slice.call(t));let n=!1,o=[];return function(...i){o=s(i),n||(n=!0,m.call(window,()=>{n=!1,t.apply(e,o)}))}}const x=(t,e,i)=>"start"===t?e:"end"===t?i:(e+i)/2;function _(){}const y=function(){let t=0;return function(){return t++}}();function v(t){return null==t}function w(t){if(Array.isArray&&Array.isArray(t))return!0;const e=Object.prototype.toString.call(t);return"[object"===e.substr(0,7)&&"Array]"===e.substr(-6)}function M(t){return null!==t&&"[object Object]"===Object.prototype.toString.call(t)}const k=t=>("number"==typeof t||t instanceof Number)&&isFinite(+t);function O(t,e){return k(t)?t:e}function S(t,e){return void 0===t?e:t}const P=(t,e)=>"string"==typeof t&&t.endsWith("%")?parseFloat(t)/100*e:+t;function D(t,e,i){if(t&&"function"==typeof t.call)return t.apply(i,e)}function E(t,e,i,s){let n,o,a;if(w(t))if(o=t.length,s)for(n=o-1;n>=0;n--)e.call(i,t[n],n);else for(n=0;ni;)t=t[e.substr(i,s-i)],i=s+1,s=F(e,i);return t}function V(t){return t.charAt(0).toUpperCase()+t.slice(1)}const B=t=>void 0!==t,N=t=>"function"==typeof t,W=(t,e)=>{if(t.size!==e.size)return!1;for(const i of t)if(!e.has(i))return!1;return!0},H=Math.PI,$=2*H,Y=$+H,U=Number.POSITIVE_INFINITY,X=H/180,q=H/2,K=H/4,G=2*H/3,Z=Math.log10,Q=Math.sign;function J(t){const e=Math.round(t);t=et(t,e,t/1e3)?e:t;const i=Math.pow(10,Math.floor(Z(t))),s=t/i;return(s<=1?1:s<=2?2:s<=5?5:10)*i}function tt(t){return!isNaN(parseFloat(t))&&isFinite(t)}function et(t,e,i){return Math.abs(t-e)l&&h=Math.min(e,i)-s&&t<=Math.max(e,i)+s}const ft=t=>0===t||1===t,pt=(t,e,i)=>-Math.pow(2,10*(t-=1))*Math.sin((t-e)*$/i),gt=(t,e,i)=>Math.pow(2,-10*t)*Math.sin((t-e)*$/i)+1,mt={linear:t=>t,easeInQuad:t=>t*t,easeOutQuad:t=>-t*(t-2),easeInOutQuad:t=>(t/=.5)<1?.5*t*t:-.5*(--t*(t-2)-1),easeInCubic:t=>t*t*t,easeOutCubic:t=>(t-=1)*t*t+1,easeInOutCubic:t=>(t/=.5)<1?.5*t*t*t:.5*((t-=2)*t*t+2),easeInQuart:t=>t*t*t*t,easeOutQuart:t=>-((t-=1)*t*t*t-1),easeInOutQuart:t=>(t/=.5)<1?.5*t*t*t*t:-.5*((t-=2)*t*t*t-2),easeInQuint:t=>t*t*t*t*t,easeOutQuint:t=>(t-=1)*t*t*t*t+1,easeInOutQuint:t=>(t/=.5)<1?.5*t*t*t*t*t:.5*((t-=2)*t*t*t*t+2),easeInSine:t=>1-Math.cos(t*q),easeOutSine:t=>Math.sin(t*q),easeInOutSine:t=>-.5*(Math.cos(H*t)-1),easeInExpo:t=>0===t?0:Math.pow(2,10*(t-1)),easeOutExpo:t=>1===t?1:1-Math.pow(2,-10*t),easeInOutExpo:t=>ft(t)?t:t<.5?.5*Math.pow(2,10*(2*t-1)):.5*(2-Math.pow(2,-10*(2*t-1))),easeInCirc:t=>t>=1?t:-(Math.sqrt(1-t*t)-1),easeOutCirc:t=>Math.sqrt(1-(t-=1)*t),easeInOutCirc:t=>(t/=.5)<1?-.5*(Math.sqrt(1-t*t)-1):.5*(Math.sqrt(1-(t-=2)*t)+1),easeInElastic:t=>ft(t)?t:pt(t,.075,.3),easeOutElastic:t=>ft(t)?t:gt(t,.075,.3),easeInOutElastic(t){const e=.1125;return ft(t)?t:t<.5?.5*pt(2*t,e,.45):.5+.5*gt(2*t-1,e,.45)},easeInBack(t){const e=1.70158;return t*t*((e+1)*t-e)},easeOutBack(t){const e=1.70158;return(t-=1)*t*((e+1)*t+e)+1},easeInOutBack(t){let e=1.70158;return(t/=.5)<1?t*t*((1+(e*=1.525))*t-e)*.5:.5*((t-=2)*t*((1+(e*=1.525))*t+e)+2)},easeInBounce:t=>1-mt.easeOutBounce(1-t),easeOutBounce(t){const e=7.5625,i=2.75;return t<1/i?e*t*t:t<2/i?e*(t-=1.5/i)*t+.75:t<2.5/i?e*(t-=2.25/i)*t+.9375:e*(t-=2.625/i)*t+.984375},easeInOutBounce:t=>t<.5?.5*mt.easeInBounce(2*t):.5*mt.easeOutBounce(2*t-1)+.5},bt={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,A:10,B:11,C:12,D:13,E:14,F:15,a:10,b:11,c:12,d:13,e:14,f:15},xt="0123456789ABCDEF",_t=t=>xt[15&t],yt=t=>xt[(240&t)>>4]+xt[15&t],vt=t=>(240&t)>>4==(15&t);function wt(t){return t+.5|0}const Mt=(t,e,i)=>Math.max(Math.min(t,i),e);function kt(t){return Mt(wt(2.55*t),0,255)}function Ot(t){return Mt(wt(255*t),0,255)}function St(t){return Mt(wt(t/2.55)/100,0,1)}function Pt(t){return Mt(wt(100*t),0,100)}const Dt=/^rgba?\(\s*([-+.\d]+)(%)?[\s,]+([-+.e\d]+)(%)?[\s,]+([-+.e\d]+)(%)?(?:[\s,/]+([-+.e\d]+)(%)?)?\s*\)$/,Et=/^(hsla?|hwb|hsv)\(\s*([-+.e\d]+)(?:deg)?[\s,]+([-+.e\d]+)%[\s,]+([-+.e\d]+)%(?:[\s,]+([-+.e\d]+)(%)?)?\s*\)$/;function Ct(t,e,i){const s=e*Math.min(i,1-i),n=(e,n=(e+t/30)%12)=>i-s*Math.max(Math.min(n-3,9-n,1),-1);return[n(0),n(8),n(4)]}function At(t,e,i){const s=(s,n=(s+t/60)%6)=>i-i*e*Math.max(Math.min(n,4-n,1),0);return[s(5),s(3),s(1)]}function Tt(t,e,i){const s=Ct(t,1,.5);let n;for(e+i>1&&(n=1/(e+i),e*=n,i*=n),n=0;n<3;n++)s[n]*=1-e-i,s[n]+=e;return s}function Rt(t){const e=t.r/255,i=t.g/255,s=t.b/255,n=Math.max(e,i,s),o=Math.min(e,i,s),a=(n+o)/2;let r,l,h;return n!==o&&(h=n-o,l=a>.5?h/(2-n-o):h/(n+o),r=n===e?(i-s)/h+(i=3&&(e={r:t[0],g:t[1],b:t[2],a:255},t.length>3&&(e.a=Ot(t[3]))):(e=Nt(t,{r:0,g:0,b:0,a:1})).a=Ot(e.a),e}function Ht(t){return"r"===t.charAt(0)?function(t){const e=Dt.exec(t);let i,s,n,o=255;if(e){if(e[7]!==i){const t=+e[7];o=255&(e[8]?kt(t):255*t)}return i=+e[1],s=+e[3],n=+e[5],i=255&(e[2]?kt(i):i),s=255&(e[4]?kt(s):s),n=255&(e[6]?kt(n):n),{r:i,g:s,b:n,a:o}}}(t):function(t){const e=Et.exec(t);let i,s=255;if(!e)return;e[5]!==i&&(s=e[6]?kt(+e[5]):Ot(+e[5]));const n=It(+e[2]),o=+e[3]/100,a=+e[4]/100;return i="hwb"===e[1]?function(t,e,i){return Lt(Tt,t,e,i)}(n,o,a):"hsv"===e[1]?function(t,e,i){return Lt(At,t,e,i)}(n,o,a):jt(n,o,a),{r:i[0],g:i[1],b:i[2],a:s}}(t)}class $t{constructor(t){if(t instanceof $t)return t;const e=typeof t;let i;var s,n,o;"object"===e?i=Wt(t):"string"===e&&(o=(s=t).length,"#"===s[0]&&(4===o||5===o?n={r:255&17*bt[s[1]],g:255&17*bt[s[2]],b:255&17*bt[s[3]],a:5===o?17*bt[s[4]]:255}:7!==o&&9!==o||(n={r:bt[s[1]]<<4|bt[s[2]],g:bt[s[3]]<<4|bt[s[4]],b:bt[s[5]]<<4|bt[s[6]],a:9===o?bt[s[7]]<<4|bt[s[8]]:255})),i=n||function(t){Vt||(Vt=function(){const t={},e=Object.keys(zt),i=Object.keys(Ft);let s,n,o,a,r;for(s=0;s>16&255,o>>8&255,255&o]}return t}(),Vt.transparent=[0,0,0,0]);const e=Vt[t.toLowerCase()];return e&&{r:e[0],g:e[1],b:e[2],a:4===e.length?e[3]:255}}(t)||Ht(t)),this._rgb=i,this._valid=!!i}get valid(){return this._valid}get rgb(){var t=Nt(this._rgb);return t&&(t.a=St(t.a)),t}set rgb(t){this._rgb=Wt(t)}rgbString(){return this._valid?(t=this._rgb)&&(t.a<255?`rgba(${t.r}, ${t.g}, ${t.b}, ${St(t.a)})`:`rgb(${t.r}, ${t.g}, ${t.b})`):this._rgb;var t}hexString(){return this._valid?(t=this._rgb,e=function(t){return vt(t.r)&&vt(t.g)&&vt(t.b)&&vt(t.a)}(t)?_t:yt,t?"#"+e(t.r)+e(t.g)+e(t.b)+(t.a<255?e(t.a):""):t):this._rgb;var t,e}hslString(){return this._valid?function(t){if(!t)return;const e=Rt(t),i=e[0],s=Pt(e[1]),n=Pt(e[2]);return t.a<255?`hsla(${i}, ${s}%, ${n}%, ${St(t.a)})`:`hsl(${i}, ${s}%, ${n}%)`}(this._rgb):this._rgb}mix(t,e){const i=this;if(t){const s=i.rgb,n=t.rgb;let o;const a=e===o?.5:e,r=2*a-1,l=s.a-n.a,h=((r*l==-1?r:(r+l)/(1+r*l))+1)/2;o=1-h,s.r=255&h*s.r+o*n.r+.5,s.g=255&h*s.g+o*n.g+.5,s.b=255&h*s.b+o*n.b+.5,s.a=a*s.a+(1-a)*n.a,i.rgb=s}return i}clone(){return new $t(this.rgb)}alpha(t){return this._rgb.a=Ot(t),this}clearer(t){return this._rgb.a*=1-t,this}greyscale(){const t=this._rgb,e=wt(.3*t.r+.59*t.g+.11*t.b);return t.r=t.g=t.b=e,this}opaquer(t){return this._rgb.a*=1+t,this}negate(){const t=this._rgb;return t.r=255-t.r,t.g=255-t.g,t.b=255-t.b,this}lighten(t){return Bt(this._rgb,2,t),this}darken(t){return Bt(this._rgb,2,-t),this}saturate(t){return Bt(this._rgb,1,t),this}desaturate(t){return Bt(this._rgb,1,-t),this}rotate(t){return function(t,e){var i=Rt(t);i[0]=It(i[0]+e),i=jt(i),t.r=i[0],t.g=i[1],t.b=i[2]}(this._rgb,t),this}}function Yt(t){return new $t(t)}const Ut=t=>t instanceof CanvasGradient||t instanceof CanvasPattern;function Xt(t){return Ut(t)?t:Yt(t)}function qt(t){return Ut(t)?t:Yt(t).saturate(.5).darken(.1).hexString()}const Kt=Object.create(null),Gt=Object.create(null);function Zt(t,e){if(!e)return t;const i=e.split(".");for(let e=0,s=i.length;et.chart.platform.getDevicePixelRatio(),this.elements={},this.events=["mousemove","mouseout","click","touchstart","touchmove"],this.font={family:"'Helvetica Neue', 'Helvetica', 'Arial', sans-serif",size:12,style:"normal",lineHeight:1.2,weight:null},this.hover={},this.hoverBackgroundColor=(t,e)=>qt(e.backgroundColor),this.hoverBorderColor=(t,e)=>qt(e.borderColor),this.hoverColor=(t,e)=>qt(e.color),this.indexAxis="x",this.interaction={mode:"nearest",intersect:!0},this.maintainAspectRatio=!0,this.onHover=null,this.onClick=null,this.parsing=!0,this.plugins={},this.responsive=!0,this.scale=void 0,this.scales={},this.showLine=!0,this.drawActiveElementsOnTop=!0,this.describe(t)}set(t,e){return Qt(this,t,e)}get(t){return Zt(this,t)}describe(t,e){return Qt(Gt,t,e)}override(t,e){return Qt(Kt,t,e)}route(t,e,i,s){const n=Zt(this,t),o=Zt(this,i),a="_"+e;Object.defineProperties(n,{[a]:{value:n[e],writable:!0},[e]:{enumerable:!0,get(){const t=this[a],e=o[s];return M(t)?Object.assign({},e,t):S(t,e)},set(t){this[a]=t}}})}}({_scriptable:t=>!t.startsWith("on"),_indexable:t=>"events"!==t,hover:{_fallback:"interaction"},interaction:{_scriptable:!1,_indexable:!1}});function te(t,e,i,s,n){let o=e[n];return o||(o=e[n]=t.measureText(n).width,i.push(n)),o>s&&(s=o),s}function ee(t,e,i,s){let n=(s=s||{}).data=s.data||{},o=s.garbageCollect=s.garbageCollect||[];s.font!==e&&(n=s.data={},o=s.garbageCollect=[],s.font=e),t.save(),t.font=e;let a=0;const r=i.length;let l,h,c,d,u;for(l=0;li.length){for(l=0;l0&&t.stroke()}}function oe(t,e,i){return i=i||.5,!e||t&&t.x>e.left-i&&t.xe.top-i&&t.y0&&""!==o.strokeColor;let l,h;for(t.save(),t.font=n.string,function(t,e){e.translation&&t.translate(e.translation[0],e.translation[1]),v(e.rotation)||t.rotate(e.rotation),e.color&&(t.fillStyle=e.color),e.textAlign&&(t.textAlign=e.textAlign),e.textBaseline&&(t.textBaseline=e.textBaseline)}(t,o),l=0;lS(t[i],t[e[i]]):e=>t[e]:()=>t;for(const t of n)i[t]=+o(t)||0;return i}function be(t){return me(t,{top:"y",right:"x",bottom:"y",left:"x"})}function xe(t){return me(t,["topLeft","topRight","bottomLeft","bottomRight"])}function _e(t){const e=be(t);return e.width=e.left+e.right,e.height=e.top+e.bottom,e}function ye(t,e){t=t||{},e=e||Jt.font;let i=S(t.size,e.size);"string"==typeof i&&(i=parseInt(i,10));let s=S(t.style,e.style);s&&!(""+s).match(pe)&&(console.warn('Invalid font style specified: "'+s+'"'),s="");const n={family:S(t.family,e.family),lineHeight:ge(S(t.lineHeight,e.lineHeight),i),size:i,style:s,weight:S(t.weight,e.weight),string:""};return n.string=function(t){return!t||v(t.size)||v(t.family)?null:(t.style?t.style+" ":"")+(t.weight?t.weight+" ":"")+t.size+"px "+t.family}(n),n}function ve(t,e,i,s){let n,o,a,r=!0;for(n=0,o=t.length;nt[i]1;)s=o+n>>1,i(s)?o=s:n=s;return{lo:o,hi:n}}const ke=(t,e,i)=>Me(t,i,s=>t[s][e]Me(t,i,s=>t[s][e]>=i),Se=["push","pop","shift","splice","unshift"];function Pe(t,e){const i=t._chartjs;if(!i)return;const s=i.listeners,n=s.indexOf(e);-1!==n&&s.splice(n,1),s.length>0||(Se.forEach(e=>{delete t[e]}),delete t._chartjs)}function De(t){const e=new Set;let i,s;for(i=0,s=t.length;it[0])){B(s)||(s=Be("_fallback",t));const o={[Symbol.toStringTag]:"Object",_cacheable:!0,_scopes:t,_rootScopes:i,_fallback:s,_getTarget:n,override:n=>Ee([n,...t],e,i,s)};return new Proxy(o,{deleteProperty:(e,i)=>(delete e[i],delete e._keys,delete t[0][i],!0),get:(i,s)=>Le(i,s,()=>function(t,e,i,s){let n;for(const o of e)if(n=Be(Te(o,t),i),B(n))return Re(t,n)?ze(i,s,t,n):n}(s,e,t,i)),getOwnPropertyDescriptor:(t,e)=>Reflect.getOwnPropertyDescriptor(t._scopes[0],e),getPrototypeOf:()=>Reflect.getPrototypeOf(t[0]),has:(t,e)=>Ne(t).includes(e),ownKeys:t=>Ne(t),set(t,e,i){const s=t._storage||(t._storage=n());return t[e]=s[e]=i,delete t._keys,!0}})}function Ce(t,e,i,s){const n={_cacheable:!1,_proxy:t,_context:e,_subProxy:i,_stack:new Set,_descriptors:Ae(t,s),setContext:e=>Ce(t,e,i,s),override:n=>Ce(t.override(n),e,i,s)};return new Proxy(n,{deleteProperty:(e,i)=>(delete e[i],delete t[i],!0),get:(t,e,i)=>Le(t,e,()=>function(t,e,i){const{_proxy:s,_context:n,_subProxy:o,_descriptors:a}=t;let r=s[e];return N(r)&&a.isScriptable(e)&&(r=function(t,e,i,s){const{_proxy:n,_context:o,_subProxy:a,_stack:r}=i;if(r.has(t))throw new Error("Recursion detected: "+Array.from(r).join("->")+"->"+t);return r.add(t),e=e(o,a||s),r.delete(t),Re(t,e)&&(e=ze(n._scopes,n,t,e)),e}(e,r,t,i)),w(r)&&r.length&&(r=function(t,e,i,s){const{_proxy:n,_context:o,_subProxy:a,_descriptors:r}=i;if(B(o.index)&&s(t))e=e[o.index%e.length];else if(M(e[0])){const i=e,s=n._scopes.filter(t=>t!==i);e=[];for(const l of i){const i=ze(s,n,t,l);e.push(Ce(i,o,a&&a[t],r))}}return e}(e,r,t,a.isIndexable)),Re(e,r)&&(r=Ce(r,n,o&&o[e],a)),r}(t,e,i)),getOwnPropertyDescriptor:(e,i)=>e._descriptors.allKeys?Reflect.has(t,i)?{enumerable:!0,configurable:!0}:void 0:Reflect.getOwnPropertyDescriptor(t,i),getPrototypeOf:()=>Reflect.getPrototypeOf(t),has:(e,i)=>Reflect.has(t,i),ownKeys:()=>Reflect.ownKeys(t),set:(e,i,s)=>(t[i]=s,delete e[i],!0)})}function Ae(t,e={scriptable:!0,indexable:!0}){const{_scriptable:i=e.scriptable,_indexable:s=e.indexable,_allKeys:n=e.allKeys}=t;return{allKeys:n,scriptable:i,indexable:s,isScriptable:N(i)?i:()=>i,isIndexable:N(s)?s:()=>s}}const Te=(t,e)=>t?t+V(e):e,Re=(t,e)=>M(e)&&"adapters"!==t&&(null===Object.getPrototypeOf(e)||e.constructor===Object);function Le(t,e,i){if(Object.prototype.hasOwnProperty.call(t,e))return t[e];const s=i();return t[e]=s,s}function je(t,e,i){return N(t)?t(e,i):t}const Ie=(t,e)=>!0===t?e:"string"==typeof t?z(e,t):void 0;function Fe(t,e,i,s,n){for(const o of e){const e=Ie(i,o);if(e){t.add(e);const o=je(e._fallback,i,n);if(B(o)&&o!==i&&o!==s)return o}else if(!1===e&&B(s)&&i!==s)return null}return!1}function ze(t,e,i,s){const n=e._rootScopes,o=je(e._fallback,i,s),a=[...t,...n],r=new Set;r.add(s);let l=Ve(r,a,i,o||i,s);return null!==l&&(!B(o)||o===i||(l=Ve(r,a,o,l,s),null!==l))&&Ee(Array.from(r),[""],n,o,()=>function(t,e,i){const s=t._getTarget();e in s||(s[e]={});const n=s[e];return w(n)&&M(i)?i:n}(e,i,s))}function Ve(t,e,i,s,n){for(;i;)i=Fe(t,e,i,s,n);return i}function Be(t,e){for(const i of e){if(!i)continue;const e=i[t];if(B(e))return e}}function Ne(t){let e=t._keys;return e||(e=t._keys=function(t){const e=new Set;for(const i of t)for(const t of Object.keys(i).filter(t=>!t.startsWith("_")))e.add(t);return Array.from(e)}(t._scopes)),e}const We=Number.EPSILON||1e-14,He=(t,e)=>e"x"===t?"y":"x";function Ye(t,e,i,s){const n=t.skip?e:t,o=e,a=i.skip?e:i,r=rt(o,n),l=rt(a,o);let h=r/(r+l),c=l/(r+l);h=isNaN(h)?0:h,c=isNaN(c)?0:c;const d=s*h,u=s*c;return{previous:{x:o.x-d*(a.x-n.x),y:o.y-d*(a.y-n.y)},next:{x:o.x+u*(a.x-n.x),y:o.y+u*(a.y-n.y)}}}function Ue(t,e,i){return Math.max(Math.min(t,i),e)}function Xe(t,e,i,s,n){let o,a,r,l;if(e.spanGaps&&(t=t.filter(t=>!t.skip)),"monotone"===e.cubicInterpolationMode)!function(t,e="x"){const i=$e(e),s=t.length,n=Array(s).fill(0),o=Array(s);let a,r,l,h=He(t,0);for(a=0;awindow.getComputedStyle(t,null),Qe=["top","right","bottom","left"];function Je(t,e,i){const s={};i=i?"-"+i:"";for(let n=0;n<4;n++){const o=Qe[n];s[o]=parseFloat(t[e+"-"+o+i])||0}return s.width=s.left+s.right,s.height=s.top+s.bottom,s}function ti(t,e){const{canvas:i,currentDevicePixelRatio:s}=e,n=Ze(i),o="border-box"===n.boxSizing,a=Je(n,"padding"),r=Je(n,"border","width"),{x:l,y:h,box:c}=function(t,e){const i=t.native||t,s=i.touches,n=s&&s.length?s[0]:i,{offsetX:o,offsetY:a}=n;let r,l,h=!1;if(((t,e,i)=>(t>0||e>0)&&(!i||!i.shadowRoot))(o,a,i.target))r=o,l=a;else{const t=e.getBoundingClientRect();r=n.clientX-t.left,l=n.clientY-t.top,h=!0}return{x:r,y:l,box:h}}(t,i),d=a.left+(c&&r.left),u=a.top+(c&&r.top);let{width:f,height:p}=e;return o&&(f-=a.width+r.width,p-=a.height+r.height),{x:Math.round((l-d)/f*i.width/s),y:Math.round((h-u)/p*i.height/s)}}const ei=t=>Math.round(10*t)/10;function ii(t,e,i){const s=e||1,n=Math.floor(t.height*s),o=Math.floor(t.width*s);t.height=n/s,t.width=o/s;const a=t.canvas;return a.style&&(i||!a.style.height&&!a.style.width)&&(a.style.height=t.height+"px",a.style.width=t.width+"px"),(t.currentDevicePixelRatio!==s||a.height!==n||a.width!==o)&&(t.currentDevicePixelRatio=s,a.height=n,a.width=o,t.ctx.setTransform(s,0,0,s,0,0),!0)}const si=function(){let t=!1;try{const e={get passive(){return t=!0,!1}};window.addEventListener("test",null,e),window.removeEventListener("test",null,e)}catch(t){}return t}();function ni(t,e){const i=function(t,e){return Ze(t).getPropertyValue(e)}(t,e),s=i&&i.match(/^(\d+)(\.\d+)?px$/);return s?+s[1]:void 0}function oi(t,e,i,s){return{x:t.x+i*(e.x-t.x),y:t.y+i*(e.y-t.y)}}function ai(t,e,i,s){return{x:t.x+i*(e.x-t.x),y:"middle"===s?i<.5?t.y:e.y:"after"===s?i<1?t.y:e.y:i>0?e.y:t.y}}function ri(t,e,i,s){const n={x:t.cp2x,y:t.cp2y},o={x:e.cp1x,y:e.cp1y},a=oi(t,n,i),r=oi(n,o,i),l=oi(o,e,i),h=oi(a,r,i),c=oi(r,l,i);return oi(h,c,i)}const li=new Map;function hi(t,e,i){return function(t,e){e=e||{};const i=t+JSON.stringify(e);let s=li.get(i);return s||(s=new Intl.NumberFormat(t,e),li.set(i,s)),s}(e,i).format(t)}function ci(t,e,i){return t?function(t,e){return{x:i=>t+t+e-i,setWidth(t){e=t},textAlign:t=>"center"===t?t:"right"===t?"left":"right",xPlus:(t,e)=>t-e,leftForLtr:(t,e)=>t-e}}(e,i):{x:t=>t,setWidth(t){},textAlign:t=>t,xPlus:(t,e)=>t+e,leftForLtr:(t,e)=>t}}function di(t){return"angle"===t?{between:ct,compare:lt,normalize:ht}:{between:ut,compare:(t,e)=>t-e,normalize:t=>t}}function ui({start:t,end:e,count:i,loop:s,style:n}){return{start:t%i,end:e%i,loop:s&&(e-t+1)%i==0,style:n}}function fi(t,e,i){if(!i)return[t];const{property:s,start:n,end:o}=i,a=e.length,{compare:r,between:l,normalize:h}=di(s),{start:c,end:d,loop:u,style:f}=function(t,e,i){const{property:s,start:n,end:o}=i,{between:a,normalize:r}=di(s),l=e.length;let h,c,{start:d,end:u,loop:f}=t;if(f){for(d+=l,u+=l,h=0,c=l;hs({chart:t,initial:e.initial,numSteps:o,currentStep:Math.min(i-e.start,o)}))}_refresh(){this._request||(this._running=!0,this._request=m.call(window,()=>{this._update(),this._request=null,this._running&&this._refresh()}))}_update(t=Date.now()){let e=0;this._charts.forEach((i,s)=>{if(!i.running||!i.items.length)return;const n=i.items;let o,a=n.length-1,r=!1;for(;a>=0;--a)o=n[a],o._active?(o._total>i.duration&&(i.duration=o._total),o.tick(t),r=!0):(n[a]=n[n.length-1],n.pop());r&&(s.draw(),this._notify(s,i,t,"progress")),n.length||(i.running=!1,this._notify(s,i,t,"complete"),i.initial=!1),e+=n.length}),this._lastDate=t,0===e&&(this._running=!1)}_getAnims(t){const e=this._charts;let i=e.get(t);return i||(i={running:!1,initial:!0,items:[],listeners:{complete:[],progress:[]}},e.set(t,i)),i}listen(t,e,i){this._getAnims(t).listeners[e].push(i)}add(t,e){e&&e.length&&this._getAnims(t).items.push(...e)}has(t){return this._getAnims(t).items.length>0}start(t){const e=this._charts.get(t);e&&(e.running=!0,e.start=Date.now(),e.duration=e.items.reduce((t,e)=>Math.max(t,e._duration),0),this._refresh())}running(t){if(!this._running)return!1;const e=this._charts.get(t);return!!(e&&e.running&&e.items.length)}stop(t){const e=this._charts.get(t);if(!e||!e.items.length)return;const i=e.items;let s=i.length-1;for(;s>=0;--s)i[s].cancel();e.items=[],this._notify(t,e,Date.now(),"complete")}remove(t){return this._charts.delete(t)}};const xi={boolean:(t,e,i)=>i>.5?e:t,color(t,e,i){const s=Xt(t||"transparent"),n=s.valid&&Xt(e||"transparent");return n&&n.valid?n.mix(s,i).hexString():e},number:(t,e,i)=>t+(e-t)*i};class _i{constructor(t,e,i,s){const n=e[i];s=ve([t.to,s,n,t.from]);const o=ve([t.from,n,s]);this._active=!0,this._fn=t.fn||xi[t.type||typeof o],this._easing=mt[t.easing]||mt.linear,this._start=Math.floor(Date.now()+(t.delay||0)),this._duration=this._total=Math.floor(t.duration),this._loop=!!t.loop,this._target=e,this._prop=i,this._from=o,this._to=s,this._promises=void 0}active(){return this._active}update(t,e,i){if(this._active){this._notify(!1);const s=this._target[this._prop],n=i-this._start,o=this._duration-n;this._start=i,this._duration=Math.floor(Math.max(o,t.duration)),this._total+=n,this._loop=!!t.loop,this._to=ve([t.to,e,s,t.from]),this._from=ve([t.from,s,e])}}cancel(){this._active&&(this.tick(Date.now()),this._active=!1,this._notify(!1))}tick(t){const e=t-this._start,i=this._duration,s=this._prop,n=this._from,o=this._loop,a=this._to;let r;if(this._active=n!==a&&(o||e1?2-r:r,r=this._easing(Math.min(1,Math.max(0,r))),this._target[s]=this._fn(n,a,r))}wait(){const t=this._promises||(this._promises=[]);return new Promise((e,i)=>{t.push({res:e,rej:i})})}_notify(t){const e=t?"res":"rej",i=this._promises||[];for(let t=0;t"onProgress"!==t&&"onComplete"!==t&&"fn"!==t}),Jt.set("animations",{colors:{type:"color",properties:["color","borderColor","backgroundColor"]},numbers:{type:"number",properties:["x","y","borderWidth","radius","tension"]}}),Jt.describe("animations",{_fallback:"animation"}),Jt.set("transitions",{active:{animation:{duration:400}},resize:{animation:{duration:0}},show:{animations:{colors:{from:"transparent"},visible:{type:"boolean",duration:0}}},hide:{animations:{colors:{to:"transparent"},visible:{type:"boolean",easing:"linear",fn:t=>0|t}}}});class vi{constructor(t,e){this._chart=t,this._properties=new Map,this.configure(e)}configure(t){if(!M(t))return;const e=this._properties;Object.getOwnPropertyNames(t).forEach(i=>{const s=t[i];if(!M(s))return;const n={};for(const t of yi)n[t]=s[t];(w(s.properties)&&s.properties||[i]).forEach(t=>{t!==i&&e.has(t)||e.set(t,n)})})}_animateOptions(t,e){const i=e.options,s=function(t,e){if(!e)return;let i=t.options;if(i)return i.$shared&&(t.options=i=Object.assign({},i,{$shared:!1,$animations:{}})),i;t.options=e}(t,i);if(!s)return[];const n=this._createAnimations(s,i);return i.$shared&&function(t,e){const i=[],s=Object.keys(e);for(let e=0;e{t.options=i},()=>{}),n}_createAnimations(t,e){const i=this._properties,s=[],n=t.$animations||(t.$animations={}),o=Object.keys(e),a=Date.now();let r;for(r=o.length-1;r>=0;--r){const l=o[r];if("$"===l.charAt(0))continue;if("options"===l){s.push(...this._animateOptions(t,e));continue}const h=e[l];let c=n[l];const d=i.get(l);if(c){if(d&&c.active()){c.update(d,h,a);continue}c.cancel()}d&&d.duration?(n[l]=c=new _i(d,t,l,h),s.push(c)):t[l]=h}return s}update(t,e){if(0===this._properties.size)return void Object.assign(t,e);const i=this._createAnimations(t,e);return i.length?(bi.add(this._chart,i),!0):void 0}}function wi(t,e){const i=t&&t.options||{},s=i.reverse,n=void 0===i.min?e:0,o=void 0===i.max?e:0;return{start:s?o:n,end:s?n:o}}function Mi(t,e){const i=[],s=t._getSortedDatasetMetas(e);let n,o;for(n=0,o=s.length;n0||!i&&e<0)return n.index}return null}function Di(t,e){const{chart:i,_cachedMeta:s}=t,n=i._stacks||(i._stacks={}),{iScale:o,vScale:a,index:r}=s,l=o.axis,h=a.axis,c=function(t,e,i){return`${t.id}.${e.id}.${i.stack||i.type}`}(o,a,s),d=e.length;let u;for(let t=0;ti[t].axis===e).shift()}function Ci(t,e){const i=t.controller.index,s=t.vScale&&t.vScale.axis;if(s){e=e||t._parsed;for(const t of e){const e=t._stacks;if(!e||void 0===e[s]||void 0===e[s][i])return;delete e[s][i]}}}const Ai=t=>"reset"===t||"none"===t,Ti=(t,e)=>e?t:Object.assign({},t);class Ri{constructor(t,e){this.chart=t,this._ctx=t.ctx,this.index=e,this._cachedDataOpts={},this._cachedMeta=this.getMeta(),this._type=this._cachedMeta.type,this.options=void 0,this._parsing=!1,this._data=void 0,this._objectData=void 0,this._sharedOptions=void 0,this._drawStart=void 0,this._drawCount=void 0,this.enableOptionSharing=!1,this.$context=void 0,this._syncList=[],this.initialize()}initialize(){const t=this._cachedMeta;this.configure(),this.linkScales(),t._stacked=Oi(t.vScale,t),this.addElements()}updateIndex(t){this.index!==t&&Ci(this._cachedMeta),this.index=t}linkScales(){const t=this.chart,e=this._cachedMeta,i=this.getDataset(),s=(t,e,i,s)=>"x"===t?e:"r"===t?s:i,n=e.xAxisID=S(i.xAxisID,Ei(t,"x")),o=e.yAxisID=S(i.yAxisID,Ei(t,"y")),a=e.rAxisID=S(i.rAxisID,Ei(t,"r")),r=e.indexAxis,l=e.iAxisID=s(r,n,o,a),h=e.vAxisID=s(r,o,n,a);e.xScale=this.getScaleForId(n),e.yScale=this.getScaleForId(o),e.rScale=this.getScaleForId(a),e.iScale=this.getScaleForId(l),e.vScale=this.getScaleForId(h)}getDataset(){return this.chart.data.datasets[this.index]}getMeta(){return this.chart.getDatasetMeta(this.index)}getScaleForId(t){return this.chart.scales[t]}_getOtherScale(t){const e=this._cachedMeta;return t===e.iScale?e.vScale:e.iScale}reset(){this._update("reset")}_destroy(){const t=this._cachedMeta;this._data&&Pe(this._data,this),t._stacked&&Ci(t)}_dataCheck(){const t=this.getDataset(),e=t.data||(t.data=[]),i=this._data;if(M(e))this._data=function(t){const e=Object.keys(t),i=new Array(e.length);let s,n,o;for(s=0,n=e.length;s{const e="_onData"+V(t),i=s[t];Object.defineProperty(s,t,{configurable:!0,enumerable:!1,value(...t){const n=i.apply(this,t);return s._chartjs.listeners.forEach(i=>{"function"==typeof i[e]&&i[e](...t)}),n}})}))),this._syncList=[],this._data=e}var s}addElements(){const t=this._cachedMeta;this._dataCheck(),this.datasetElementType&&(t.dataset=new this.datasetElementType)}buildOrUpdateElements(t){const e=this._cachedMeta,i=this.getDataset();let s=!1;this._dataCheck();const n=e._stacked;e._stacked=Oi(e.vScale,e),e.stack!==i.stack&&(s=!0,Ci(e),e.stack=i.stack),this._resyncElements(t),(s||n!==e._stacked)&&Di(this,e._parsed)}configure(){const t=this.chart.config,e=t.datasetScopeKeys(this._type),i=t.getOptionScopes(this.getDataset(),e,!0);this.options=t.createResolver(i,this.getContext()),this._parsing=this.options.parsing,this._cachedDataOpts={}}parse(t,e){const{_cachedMeta:i,_data:s}=this,{iScale:n,_stacked:o}=i,a=n.axis;let r,l,h,c=0===t&&e===s.length||i._sorted,d=t>0&&i._parsed[t-1];if(!1===this._parsing)i._parsed=s,i._sorted=!0,h=s;else{h=w(s[t])?this.parseArrayData(i,s,t,e):M(s[t])?this.parseObjectData(i,s,t,e):this.parsePrimitiveData(i,s,t,e);const n=()=>null===l[a]||d&&l[a]t&&!e.hidden&&e._stacked&&{keys:Mi(i,!0),values:null})(e,i,this.chart),l={min:Number.POSITIVE_INFINITY,max:Number.NEGATIVE_INFINITY},{min:h,max:c}=function(t){const{min:e,max:i,minDefined:s,maxDefined:n}=t.getUserBounds();return{min:s?e:Number.NEGATIVE_INFINITY,max:n?i:Number.POSITIVE_INFINITY}}(a);let d,u;function f(){u=s[d];const e=u[a.axis];return!k(u[t.axis])||h>e||c=0;--d)if(!f()){this.updateRangeFromParsed(l,t,u,r);break}return l}getAllParsedValues(t){const e=this._cachedMeta._parsed,i=[];let s,n,o;for(s=0,n=e.length;s=0&&tthis.getContext(i,s),c);return f.$shared&&(f.$shared=r,n[o]=Object.freeze(Ti(f,r))),f}_resolveAnimations(t,e,i){const s=this.chart,n=this._cachedDataOpts,o="animation-"+e,a=n[o];if(a)return a;let r;if(!1!==s.options.animation){const s=this.chart.config,n=s.datasetAnimationScopeKeys(this._type,e),o=s.getOptionScopes(this.getDataset(),n);r=s.createResolver(o,this.getContext(t,i,e))}const l=new vi(s,r&&r.animations);return r&&r._cacheable&&(n[o]=Object.freeze(l)),l}getSharedOptions(t){if(t.$shared)return this._sharedOptions||(this._sharedOptions=Object.assign({},t))}includeOptions(t,e){return!e||Ai(t)||this.chart._animationsDisabled}updateElement(t,e,i,s){Ai(s)?Object.assign(t,i):this._resolveAnimations(e,s).update(t,i)}updateSharedOptions(t,e,i){t&&!Ai(e)&&this._resolveAnimations(void 0,e).update(t,i)}_setStyle(t,e,i,s){t.active=s;const n=this.getStyle(e,s);this._resolveAnimations(e,i,s).update(t,{options:!s&&this.getSharedOptions(n)||n})}removeHoverStyle(t,e,i){this._setStyle(t,i,"active",!1)}setHoverStyle(t,e,i){this._setStyle(t,i,"active",!0)}_removeDatasetHoverStyle(){const t=this._cachedMeta.dataset;t&&this._setStyle(t,void 0,"active",!1)}_setDatasetHoverStyle(){const t=this._cachedMeta.dataset;t&&this._setStyle(t,void 0,"active",!0)}_resyncElements(t){const e=this._data,i=this._cachedMeta.data;for(const[t,e,i]of this._syncList)this[t](e,i);this._syncList=[];const s=i.length,n=e.length,o=Math.min(n,s);o&&this.parse(0,o),n>s?this._insertElements(s,n-s,t):n{for(t.length+=e,a=t.length-1;a>=o;a--)t[a]=t[a-e]};for(r(n),a=t;at-e))}return t._cache.$bar}(e,t.type);let s,n,o,a,r=e._length;const l=()=>{32767!==o&&-32768!==o&&(B(a)&&(r=Math.min(r,Math.abs(o-a)||r)),a=o)};for(s=0,n=i.length;sMath.abs(r)&&(l=r,h=a),e[i.axis]=h,e._custom={barStart:l,barEnd:h,start:n,end:o,min:a,max:r}}(t,e,i,s):e[i.axis]=i.parse(t,s),e}function Ii(t,e,i,s){const n=t.iScale,o=t.vScale,a=n.getLabels(),r=n===o,l=[];let h,c,d,u;for(h=i,c=i+s;ht.x,i="left",s="right"):(e=t.base=i?1:-1)}(c,e,o)*n,d===o&&(g-=c/2),h=g+c),g===e.getPixelForValue(o)){const t=Q(c)*e.getLineWidthForValue(o)/2;g+=t,c-=t}return{size:c,base:g,head:h,center:h+c/2}}_calculateBarIndexPixels(t,e){const i=e.scale,s=this.options,n=s.skipNull,o=S(s.maxBarThickness,1/0);let a,r;if(e.grouped){const i=n?this._getStackCount(t):e.stackCount,l="flex"===s.barThickness?function(t,e,i,s){const n=e.pixels,o=n[t];let a=t>0?n[t-1]:null,r=t=0;--i)e=Math.max(e,t[i].size(this.resolveDataElementOptions(i))/2);return e>0&&e}getLabelAndValue(t){const e=this._cachedMeta,{xScale:i,yScale:s}=e,n=this.getParsed(t),o=i.getLabelForValue(n.x),a=s.getLabelForValue(n.y),r=n._custom;return{label:e.label,value:"("+o+", "+a+(r?", "+r:"")+")"}}update(t){const e=this._cachedMeta.data;this.updateElements(e,0,e.length,t)}updateElements(t,e,i,s){const n="reset"===s,{iScale:o,vScale:a}=this._cachedMeta,r=this.resolveDataElementOptions(e,s),l=this.getSharedOptions(r),h=this.includeOptions(s,l),c=o.axis,d=a.axis;for(let r=e;r""}}}};class $i extends Ri{constructor(t,e){super(t,e),this.enableOptionSharing=!0,this.innerRadius=void 0,this.outerRadius=void 0,this.offsetX=void 0,this.offsetY=void 0}linkScales(){}parse(t,e){const i=this.getDataset().data,s=this._cachedMeta;if(!1===this._parsing)s._parsed=i;else{let n,o,a=t=>+i[t];if(M(i[t])){const{key:t="value"}=this._parsing;a=e=>+z(i[e],t)}for(n=t,o=t+e;nct(t,r,l,!0)?1:Math.max(e,e*i,s,s*i),p=(t,e,s)=>ct(t,r,l,!0)?-1:Math.min(e,e*i,s,s*i),g=f(0,h,d),m=f(q,c,u),b=p(H,h,d),x=p(H+q,c,u);s=(g-b)/2,n=(m-x)/2,o=-(g+b)/2,a=-(m+x)/2}return{ratioX:s,ratioY:n,offsetX:o,offsetY:a}}(u,d,r),b=(i.width-o)/f,x=(i.height-o)/p,_=Math.max(Math.min(b,x)/2,0),y=P(this.options.radius,_),v=(y-Math.max(y*r,0))/this._getVisibleDatasetWeightTotal();this.offsetX=g*y,this.offsetY=m*y,s.total=this.calculateTotal(),this.outerRadius=y-v*this._getRingWeightOffset(this.index),this.innerRadius=Math.max(this.outerRadius-v*c,0),this.updateElements(n,0,n.length,t)}_circumference(t,e){const i=this.options,s=this._cachedMeta,n=this._getCircumference();return e&&i.animation.animateRotate||!this.chart.getDataVisibility(t)||null===s._parsed[t]||s.data[t].hidden?0:this.calculateCircumference(s._parsed[t]*n/$)}updateElements(t,e,i,s){const n="reset"===s,o=this.chart,a=o.chartArea,r=o.options.animation,l=(a.left+a.right)/2,h=(a.top+a.bottom)/2,c=n&&r.animateScale,d=c?0:this.innerRadius,u=c?0:this.outerRadius,f=this.resolveDataElementOptions(e,s),p=this.getSharedOptions(f),g=this.includeOptions(s,p);let m,b=this._getRotation();for(m=0;m0&&!isNaN(t)?$*(Math.abs(t)/e):0}getLabelAndValue(t){const e=this._cachedMeta,i=this.chart,s=i.data.labels||[],n=hi(e._parsed[t],i.options.locale);return{label:s[t]||"",value:n}}getMaxBorderWidth(t){let e=0;const i=this.chart;let s,n,o,a,r;if(!t)for(s=0,n=i.data.datasets.length;s"spacing"!==t,_indexable:t=>"spacing"!==t},$i.overrides={aspectRatio:1,plugins:{legend:{labels:{generateLabels(t){const e=t.data;if(e.labels.length&&e.datasets.length){const{labels:{pointStyle:i}}=t.legend.options;return e.labels.map((e,s)=>{const n=t.getDatasetMeta(0).controller.getStyle(s);return{text:e,fillStyle:n.backgroundColor,strokeStyle:n.borderColor,lineWidth:n.borderWidth,pointStyle:i,hidden:!t.getDataVisibility(s),index:s}})}return[]}},onClick(t,e,i){i.chart.toggleDataVisibility(e.index),i.chart.update()}},tooltip:{callbacks:{title:()=>"",label(t){let e=t.label;const i=": "+t.formattedValue;return w(e)?(e=e.slice(),e[0]+=i):e+=i,e}}}}};class Yi extends Ri{initialize(){this.enableOptionSharing=!0,super.initialize()}update(t){const e=this._cachedMeta,{dataset:i,data:s=[],_dataset:n}=e,o=this.chart._animationsDisabled;let{start:a,count:r}=function(t,e,i){const s=e.length;let n=0,o=s;if(t._sorted){const{iScale:a,_parsed:r}=t,l=a.axis,{min:h,max:c,minDefined:d,maxDefined:u}=a.getUserBounds();d&&(n=dt(Math.min(ke(r,a.axis,h).lo,i?s:ke(e,l,a.getPixelForValue(h)).lo),0,s-1)),o=u?dt(Math.max(ke(r,a.axis,c).hi+1,i?0:ke(e,l,a.getPixelForValue(c)).hi+1),n,s)-n:s-n}return{start:n,count:o}}(e,s,o);this._drawStart=a,this._drawCount=r,function(t){const{xScale:e,yScale:i,_scaleRanges:s}=t,n={xmin:e.min,xmax:e.max,ymin:i.min,ymax:i.max};if(!s)return t._scaleRanges=n,!0;const o=s.xmin!==e.min||s.xmax!==e.max||s.ymin!==i.min||s.ymax!==i.max;return Object.assign(s,n),o}(e)&&(a=0,r=s.length),i._chart=this.chart,i._datasetIndex=this.index,i._decimated=!!n._decimated,i.points=s;const l=this.resolveDatasetElementOptions(t);this.options.showLine||(l.borderWidth=0),l.segment=this.options.segment,this.updateElement(i,void 0,{animated:!o,options:l},t),this.updateElements(s,a,r,t)}updateElements(t,e,i,s){const n="reset"===s,{iScale:o,vScale:a,_stacked:r,_dataset:l}=this._cachedMeta,h=this.resolveDataElementOptions(e,s),c=this.getSharedOptions(h),d=this.includeOptions(s,c),u=o.axis,f=a.axis,{spanGaps:p,segment:g}=this.options,m=tt(p)?p:Number.POSITIVE_INFINITY,b=this.chart._animationsDisabled||n||"none"===s;let x=e>0&&this.getParsed(e-1);for(let h=e;h0&&i[u]-x[u]>m,g&&(p.parsed=i,p.raw=l.data[h]),d&&(p.options=c||this.resolveDataElementOptions(h,e.active?"active":s)),b||this.updateElement(e,h,p,s),x=i}this.updateSharedOptions(c,s,h)}getMaxOverflow(){const t=this._cachedMeta,e=t.dataset,i=e.options&&e.options.borderWidth||0,s=t.data||[];if(!s.length)return i;const n=s[0].size(this.resolveDataElementOptions(0)),o=s[s.length-1].size(this.resolveDataElementOptions(s.length-1));return Math.max(i,n,o)/2}draw(){const t=this._cachedMeta;t.dataset.updateControlPoints(this.chart.chartArea,t.iScale.axis),super.draw()}}Yi.id="line",Yi.defaults={datasetElementType:"line",dataElementType:"point",showLine:!0,spanGaps:!1},Yi.overrides={scales:{_index_:{type:"category"},_value_:{type:"linear"}}};class Ui extends Ri{constructor(t,e){super(t,e),this.innerRadius=void 0,this.outerRadius=void 0}getLabelAndValue(t){const e=this._cachedMeta,i=this.chart,s=i.data.labels||[],n=hi(e._parsed[t].r,i.options.locale);return{label:s[t]||"",value:n}}update(t){const e=this._cachedMeta.data;this._updateRadius(),this.updateElements(e,0,e.length,t)}_updateRadius(){const t=this.chart,e=t.chartArea,i=t.options,s=Math.min(e.right-e.left,e.bottom-e.top),n=Math.max(s/2,0),o=(n-Math.max(i.cutoutPercentage?n/100*i.cutoutPercentage:1,0))/t.getVisibleDatasetCount();this.outerRadius=n-o*this.index,this.innerRadius=this.outerRadius-o}updateElements(t,e,i,s){const n="reset"===s,o=this.chart,a=this.getDataset(),r=o.options.animation,l=this._cachedMeta.rScale,h=l.xCenter,c=l.yCenter,d=l.getIndexAngle(0)-.5*H;let u,f=d;const p=360/this.countVisibleElements();for(u=0;u{!isNaN(t.data[s])&&this.chart.getDataVisibility(s)&&i++}),i}_computeAngle(t,e,i){return this.chart.getDataVisibility(t)?st(this.resolveDataElementOptions(t,e).angle||i):0}}Ui.id="polarArea",Ui.defaults={dataElementType:"arc",animation:{animateRotate:!0,animateScale:!0},animations:{numbers:{type:"number",properties:["x","y","startAngle","endAngle","innerRadius","outerRadius"]}},indexAxis:"r",startAngle:0},Ui.overrides={aspectRatio:1,plugins:{legend:{labels:{generateLabels(t){const e=t.data;if(e.labels.length&&e.datasets.length){const{labels:{pointStyle:i}}=t.legend.options;return e.labels.map((e,s)=>{const n=t.getDatasetMeta(0).controller.getStyle(s);return{text:e,fillStyle:n.backgroundColor,strokeStyle:n.borderColor,lineWidth:n.borderWidth,pointStyle:i,hidden:!t.getDataVisibility(s),index:s}})}return[]}},onClick(t,e,i){i.chart.toggleDataVisibility(e.index),i.chart.update()}},tooltip:{callbacks:{title:()=>"",label:t=>t.chart.data.labels[t.dataIndex]+": "+t.formattedValue}}},scales:{r:{type:"radialLinear",angleLines:{display:!1},beginAtZero:!0,grid:{circular:!0},pointLabels:{display:!1},startAngle:0}}};class Xi extends $i{}Xi.id="pie",Xi.defaults={cutout:0,rotation:0,circumference:360,radius:"100%"};class qi extends Ri{getLabelAndValue(t){const e=this._cachedMeta.vScale,i=this.getParsed(t);return{label:e.getLabels()[t],value:""+e.getLabelForValue(i[e.axis])}}update(t){const e=this._cachedMeta,i=e.dataset,s=e.data||[],n=e.iScale.getLabels();if(i.points=s,"resize"!==t){const e=this.resolveDatasetElementOptions(t);this.options.showLine||(e.borderWidth=0);const o={_loop:!0,_fullLoop:n.length===s.length,options:e};this.updateElement(i,void 0,o,t)}this.updateElements(s,0,s.length,t)}updateElements(t,e,i,s){const n=this.getDataset(),o=this._cachedMeta.rScale,a="reset"===s;for(let r=e;r"",label:t=>"("+t.label+", "+t.formattedValue+")"}}},scales:{x:{type:"linear"},y:{type:"linear"}}};class Zi{constructor(t){this.options=t||{}}formats(){return Gi()}parse(t,e){return Gi()}format(t,e){return Gi()}add(t,e,i){return Gi()}diff(t,e,i){return Gi()}startOf(t,e,i){return Gi()}endOf(t,e){return Gi()}}Zi.override=function(t){Object.assign(Zi.prototype,t)};var Qi={_date:Zi};function Ji(t,e){return"native"in t?{x:t.x,y:t.y}:ti(t,e)}function ts(t,e,i,s){const{controller:n,data:o,_sorted:a}=t,r=n._cachedMeta.iScale;if(r&&e===r.axis&&"r"!==e&&a&&o.length){const t=r._reversePixels?Oe:ke;if(!s)return t(o,e,i);if(n._sharedOptions){const s=o[0],n="function"==typeof s.getRange&&s.getRange(e);if(n){const s=t(o,e,i-n),a=t(o,e,i+n);return{lo:s.lo,hi:a.hi}}}}return{lo:0,hi:o.length-1}}function es(t,e,i,s,n){const o=t.getSortedVisibleDatasetMetas(),a=i[e];for(let t=0,i=o.length;t{t[r](n[a],s)&&o.push({element:t,datasetIndex:e,index:i}),t.inRange(n.x,n.y,s)&&(l=!0)}),i.intersect&&!l?[]:o}var os={modes:{index(t,e,i,s){const n=Ji(e,t),o=i.axis||"x",a=i.intersect?is(t,n,o,s):ss(t,n,o,!1,s),r=[];return a.length?(t.getSortedVisibleDatasetMetas().forEach(t=>{const e=a[0].index,i=t.data[e];i&&!i.skip&&r.push({element:i,datasetIndex:t.index,index:e})}),r):[]},dataset(t,e,i,s){const n=Ji(e,t),o=i.axis||"xy";let a=i.intersect?is(t,n,o,s):ss(t,n,o,!1,s);if(a.length>0){const e=a[0].datasetIndex,i=t.getDatasetMeta(e).data;a=[];for(let t=0;tis(t,Ji(e,t),i.axis||"xy",s),nearest:(t,e,i,s)=>ss(t,Ji(e,t),i.axis||"xy",i.intersect,s),x:(t,e,i,s)=>ns(t,e,{axis:"x",intersect:i.intersect},s),y:(t,e,i,s)=>ns(t,e,{axis:"y",intersect:i.intersect},s)}};const as=["left","top","right","bottom"];function rs(t,e){return t.filter(t=>t.pos===e)}function ls(t,e){return t.filter(t=>-1===as.indexOf(t.pos)&&t.box.axis===e)}function hs(t,e){return t.sort((t,i)=>{const s=e?i:t,n=e?t:i;return s.weight===n.weight?s.index-n.index:s.weight-n.weight})}function cs(t,e,i,s){return Math.max(t[i],e[i])+Math.max(t[s],e[s])}function ds(t,e){t.top=Math.max(t.top,e.top),t.left=Math.max(t.left,e.left),t.bottom=Math.max(t.bottom,e.bottom),t.right=Math.max(t.right,e.right)}function us(t,e,i,s){const{pos:n,box:o}=i,a=t.maxPadding;if(!M(n)){i.size&&(t[n]-=i.size);const e=s[i.stack]||{size:0,count:1};e.size=Math.max(e.size,i.horizontal?o.height:o.width),i.size=e.size/e.count,t[n]+=i.size}o.getPadding&&ds(a,o.getPadding());const r=Math.max(0,e.outerWidth-cs(a,t,"left","right")),l=Math.max(0,e.outerHeight-cs(a,t,"top","bottom")),h=r!==t.w,c=l!==t.h;return t.w=r,t.h=l,i.horizontal?{same:h,other:c}:{same:c,other:h}}function fs(t,e){const i=e.maxPadding;return function(t){const s={left:0,top:0,right:0,bottom:0};return t.forEach(t=>{s[t]=Math.max(e[t],i[t])}),s}(t?["left","right"]:["top","bottom"])}function ps(t,e,i,s){const n=[];let o,a,r,l,h,c;for(o=0,a=t.length,h=0;ot.box.fullSize),!0),s=hs(rs(e,"left"),!0),n=hs(rs(e,"right")),o=hs(rs(e,"top"),!0),a=hs(rs(e,"bottom")),r=ls(e,"x"),l=ls(e,"y");return{fullSize:i,leftAndTop:s.concat(o),rightAndBottom:n.concat(l).concat(a).concat(r),chartArea:rs(e,"chartArea"),vertical:s.concat(n).concat(l),horizontal:o.concat(a).concat(r)}}(t.boxes),l=r.vertical,h=r.horizontal;E(t.boxes,t=>{"function"==typeof t.beforeLayout&&t.beforeLayout()});const c=l.reduce((t,e)=>e.box.options&&!1===e.box.options.display?t:t+1,0)||1,d=Object.freeze({outerWidth:e,outerHeight:i,padding:n,availableWidth:o,availableHeight:a,vBoxMaxWidth:o/2/c,hBoxMaxHeight:a/2}),u=Object.assign({},n);ds(u,_e(s));const f=Object.assign({maxPadding:u,w:o,h:a,x:n.left,y:n.top},n),p=function(t,e){const i=function(t){const e={};for(const i of t){const{stack:t,pos:s,stackWeight:n}=i;if(!t||!as.includes(s))continue;const o=e[t]||(e[t]={count:0,placed:0,weight:0,size:0});o.count++,o.weight+=n}return e}(t),{vBoxMaxWidth:s,hBoxMaxHeight:n}=e;let o,a,r;for(o=0,a=t.length;o{const i=e.box;Object.assign(i,t.chartArea),i.update(f.w,f.h,{left:0,top:0,right:0,bottom:0})})}};class xs{acquireContext(t,e){}releaseContext(t){return!1}addEventListener(t,e,i){}removeEventListener(t,e,i){}getDevicePixelRatio(){return 1}getMaximumSize(t,e,i,s){return e=Math.max(0,e||t.width),i=i||t.height,{width:e,height:Math.max(0,s?Math.floor(e/s):i)}}isAttached(t){return!0}updateConfig(t){}}class _s extends xs{acquireContext(t){return t&&t.getContext&&t.getContext("2d")||null}updateConfig(t){t.options.animation=!1}}const ys={touchstart:"mousedown",touchmove:"mousemove",touchend:"mouseup",pointerenter:"mouseenter",pointerdown:"mousedown",pointermove:"mousemove",pointerup:"mouseup",pointerleave:"mouseout",pointerout:"mouseout"},vs=t=>null===t||""===t,ws=!!si&&{passive:!0};function Ms(t,e,i){t.canvas.removeEventListener(e,i,ws)}function ks(t,e){for(const i of t)if(i===e||i.contains(e))return!0}function Os(t,e,i){const s=t.canvas,n=new MutationObserver(t=>{let e=!1;for(const i of t)e=e||ks(i.addedNodes,s),e=e&&!ks(i.removedNodes,s);e&&i()});return n.observe(document,{childList:!0,subtree:!0}),n}function Ss(t,e,i){const s=t.canvas,n=new MutationObserver(t=>{let e=!1;for(const i of t)e=e||ks(i.removedNodes,s),e=e&&!ks(i.addedNodes,s);e&&i()});return n.observe(document,{childList:!0,subtree:!0}),n}const Ps=new Map;let Ds=0;function Es(){const t=window.devicePixelRatio;t!==Ds&&(Ds=t,Ps.forEach((e,i)=>{i.currentDevicePixelRatio!==t&&e()}))}function Cs(t,e,i){const s=t.canvas,n=s&&Ke(s);if(!n)return;const o=b((t,e)=>{const s=n.clientWidth;i(t,e),s{const e=t[0],i=e.contentRect.width,s=e.contentRect.height;0===i&&0===s||o(i,s)});return a.observe(n),function(t,e){Ps.size||window.addEventListener("resize",Es),Ps.set(t,e)}(t,o),a}function As(t,e,i){i&&i.disconnect(),"resize"===e&&function(t){Ps.delete(t),Ps.size||window.removeEventListener("resize",Es)}(t)}function Ts(t,e,i){const s=t.canvas,n=b(e=>{null!==t.ctx&&i(function(t,e){const i=ys[t.type]||t.type,{x:s,y:n}=ti(t,e);return{type:i,chart:e,native:t,x:void 0!==s?s:null,y:void 0!==n?n:null}}(e,t))},t,t=>{const e=t[0];return[e,e.offsetX,e.offsetY]});return function(t,e,i){t.addEventListener(e,i,ws)}(s,e,n),n}class Rs extends xs{acquireContext(t,e){const i=t&&t.getContext&&t.getContext("2d");return i&&i.canvas===t?(function(t,e){const i=t.style,s=t.getAttribute("height"),n=t.getAttribute("width");if(t.$chartjs={initial:{height:s,width:n,style:{display:i.display,height:i.height,width:i.width}}},i.display=i.display||"block",i.boxSizing=i.boxSizing||"border-box",vs(n)){const e=ni(t,"width");void 0!==e&&(t.width=e)}if(vs(s))if(""===t.style.height)t.height=t.width/(e||2);else{const e=ni(t,"height");void 0!==e&&(t.height=e)}}(t,e),i):null}releaseContext(t){const e=t.canvas;if(!e.$chartjs)return!1;const i=e.$chartjs.initial;["height","width"].forEach(t=>{const s=i[t];v(s)?e.removeAttribute(t):e.setAttribute(t,s)});const s=i.style||{};return Object.keys(s).forEach(t=>{e.style[t]=s[t]}),e.width=e.width,delete e.$chartjs,!0}addEventListener(t,e,i){this.removeEventListener(t,e);const s=t.$proxies||(t.$proxies={}),n={attach:Os,detach:Ss,resize:Cs}[e]||Ts;s[e]=n(t,e,i)}removeEventListener(t,e){const i=t.$proxies||(t.$proxies={}),s=i[e];s&&(({attach:As,detach:As,resize:As}[e]||Ms)(t,e,s),i[e]=void 0)}getDevicePixelRatio(){return window.devicePixelRatio}getMaximumSize(t,e,i,s){return function(t,e,i,s){const n=Ze(t),o=Je(n,"margin"),a=Ge(n.maxWidth,t,"clientWidth")||U,r=Ge(n.maxHeight,t,"clientHeight")||U,l=function(t,e,i){let s,n;if(void 0===e||void 0===i){const o=Ke(t);if(o){const t=o.getBoundingClientRect(),a=Ze(o),r=Je(a,"border","width"),l=Je(a,"padding");e=t.width-l.width-r.width,i=t.height-l.height-r.height,s=Ge(a.maxWidth,o,"clientWidth"),n=Ge(a.maxHeight,o,"clientHeight")}else e=t.clientWidth,i=t.clientHeight}return{width:e,height:i,maxWidth:s||U,maxHeight:n||U}}(t,e,i);let{width:h,height:c}=l;if("content-box"===n.boxSizing){const t=Je(n,"border","width"),e=Je(n,"padding");h-=e.width+t.width,c-=e.height+t.height}return h=Math.max(0,h-o.width),c=Math.max(0,s?Math.floor(h/s):c-o.height),h=ei(Math.min(h,a,l.maxWidth)),c=ei(Math.min(c,r,l.maxHeight)),h&&!c&&(c=ei(h/2)),{width:h,height:c}}(t,e,i,s)}isAttached(t){const e=Ke(t);return!(!e||!e.isConnected)}}class Ls{constructor(){this.x=void 0,this.y=void 0,this.active=!1,this.options=void 0,this.$animations=void 0}tooltipPosition(t){const{x:e,y:i}=this.getProps(["x","y"],t);return{x:e,y:i}}hasValue(){return tt(this.x)&&tt(this.y)}getProps(t,e){const i=this.$animations;if(!e||!i)return this;const s={};return t.forEach(t=>{s[t]=i[t]&&i[t].active()?i[t]._to:this[t]}),s}}Ls.defaults={},Ls.defaultRoutes=void 0;const js={values:t=>w(t)?t:""+t,numeric(t,e,i){if(0===t)return"0";const s=this.chart.options.locale;let n,o=t;if(i.length>1){const e=Math.max(Math.abs(i[0].value),Math.abs(i[i.length-1].value));(e<1e-4||e>1e15)&&(n="scientific"),o=function(t,e){let i=e.length>3?e[2].value-e[1].value:e[1].value-e[0].value;return Math.abs(i)>=1&&t!==Math.floor(t)&&(i=t-Math.floor(t)),i}(t,i)}const a=Z(Math.abs(o)),r=Math.max(Math.min(-1*Math.floor(a),20),0),l={notation:n,minimumFractionDigits:r,maximumFractionDigits:r};return Object.assign(l,this.options.ticks.format),hi(t,s,l)},logarithmic(t,e,i){if(0===t)return"0";const s=t/Math.pow(10,Math.floor(Z(t)));return 1===s||2===s||5===s?js.numeric.call(this,t,e,i):""}};var Is={formatters:js};function Fs(t,e,i,s,n){const o=S(s,0),a=Math.min(S(n,t.length),t.length);let r,l,h,c=0;for(i=Math.ceil(i),n&&(r=n-s,i=r/Math.floor(r/i)),h=o;h<0;)c++,h=Math.round(o+c*i);for(l=Math.max(o,0);le.lineWidth,tickColor:(t,e)=>e.color,offset:!1,borderDash:[],borderDashOffset:0,borderWidth:1},title:{display:!1,text:"",padding:{top:4,bottom:4}},ticks:{minRotation:0,maxRotation:50,mirror:!1,textStrokeWidth:0,textStrokeColor:"",padding:3,display:!0,autoSkip:!0,autoSkipPadding:3,labelOffset:0,callback:Is.formatters.values,minor:{},major:{},align:"center",crossAlign:"near",showLabelBackdrop:!1,backdropColor:"rgba(255, 255, 255, 0.75)",backdropPadding:2}}),Jt.route("scale.ticks","color","","color"),Jt.route("scale.grid","color","","borderColor"),Jt.route("scale.grid","borderColor","","borderColor"),Jt.route("scale.title","color","","color"),Jt.describe("scale",{_fallback:!1,_scriptable:t=>!t.startsWith("before")&&!t.startsWith("after")&&"callback"!==t&&"parser"!==t,_indexable:t=>"borderDash"!==t&&"tickBorderDash"!==t}),Jt.describe("scales",{_fallback:"scale"}),Jt.describe("scale.ticks",{_scriptable:t=>"backdropPadding"!==t&&"callback"!==t,_indexable:t=>"backdropPadding"!==t});const zs=(t,e,i)=>"top"===e||"left"===e?t[e]+i:t[e]-i;function Vs(t,e){const i=[],s=t.length/e,n=t.length;let o=0;for(;oa+1e-6)))return l}function Ns(t){return t.drawTicks?t.tickLength:0}function Ws(t,e){if(!t.display)return 0;const i=ye(t.font,e),s=_e(t.padding);return(w(t.text)?t.text.length:1)*i.lineHeight+s.height}function Hs(t,e,i){let s=(t=>"start"===t?"left":"end"===t?"right":"center")(t);return(i&&"right"!==e||!i&&"right"===e)&&(s=(t=>"left"===t?"right":"right"===t?"left":t)(s)),s}class $s extends Ls{constructor(t){super(),this.id=t.id,this.type=t.type,this.options=void 0,this.ctx=t.ctx,this.chart=t.chart,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.width=void 0,this.height=void 0,this._margins={left:0,right:0,top:0,bottom:0},this.maxWidth=void 0,this.maxHeight=void 0,this.paddingTop=void 0,this.paddingBottom=void 0,this.paddingLeft=void 0,this.paddingRight=void 0,this.axis=void 0,this.labelRotation=void 0,this.min=void 0,this.max=void 0,this._range=void 0,this.ticks=[],this._gridLineItems=null,this._labelItems=null,this._labelSizes=null,this._length=0,this._maxLength=0,this._longestTextCache={},this._startPixel=void 0,this._endPixel=void 0,this._reversePixels=!1,this._userMax=void 0,this._userMin=void 0,this._suggestedMax=void 0,this._suggestedMin=void 0,this._ticksLength=0,this._borderValue=0,this._cache={},this._dataLimitsCached=!1,this.$context=void 0}init(t){this.options=t.setContext(this.getContext()),this.axis=t.axis,this._userMin=this.parse(t.min),this._userMax=this.parse(t.max),this._suggestedMin=this.parse(t.suggestedMin),this._suggestedMax=this.parse(t.suggestedMax)}parse(t,e){return t}getUserBounds(){let{_userMin:t,_userMax:e,_suggestedMin:i,_suggestedMax:s}=this;return t=O(t,Number.POSITIVE_INFINITY),e=O(e,Number.NEGATIVE_INFINITY),i=O(i,Number.POSITIVE_INFINITY),s=O(s,Number.NEGATIVE_INFINITY),{min:O(t,i),max:O(e,s),minDefined:k(t),maxDefined:k(e)}}getMinMax(t){let e,{min:i,max:s,minDefined:n,maxDefined:o}=this.getUserBounds();if(n&&o)return{min:i,max:s};const a=this.getMatchingVisibleMetas();for(let r=0,l=a.length;rs?s:i,s=n&&i>s?i:s,{min:O(i,O(s,i)),max:O(s,O(i,s))}}getPadding(){return{left:this.paddingLeft||0,top:this.paddingTop||0,right:this.paddingRight||0,bottom:this.paddingBottom||0}}getTicks(){return this.ticks}getLabels(){const t=this.chart.data;return this.options.labels||(this.isHorizontal()?t.xLabels:t.yLabels)||t.labels||[]}beforeLayout(){this._cache={},this._dataLimitsCached=!1}beforeUpdate(){D(this.options.beforeUpdate,[this])}update(t,e,i){const{beginAtZero:s,grace:n,ticks:o}=this.options,a=o.sampleSize;this.beforeUpdate(),this.maxWidth=t,this.maxHeight=e,this._margins=i=Object.assign({left:0,right:0,top:0,bottom:0},i),this.ticks=null,this._labelSizes=null,this._gridLineItems=null,this._labelItems=null,this.beforeSetDimensions(),this.setDimensions(),this.afterSetDimensions(),this._maxLength=this.isHorizontal()?this.width+i.left+i.right:this.height+i.top+i.bottom,this._dataLimitsCached||(this.beforeDataLimits(),this.determineDataLimits(),this.afterDataLimits(),this._range=function(t,e,i){const{min:s,max:n}=t,o=P(e,(n-s)/2),a=(t,e)=>i&&0===t?0:t+e;return{min:a(s,-Math.abs(o)),max:a(n,o)}}(this,n,s),this._dataLimitsCached=!0),this.beforeBuildTicks(),this.ticks=this.buildTicks()||[],this.afterBuildTicks();const r=as)return function(t,e,i,s){let n,o=0,a=i[0];for(s=Math.ceil(s),n=0;nt-e).pop(),e}(s);for(let t=0,e=o.length-1;tn)return e}return Math.max(n,1)}(n,e,s);if(o>0){let t,i;const s=o>1?Math.round((r-a)/(o-1)):null;for(Fs(e,l,h,v(s)?0:a-s,a),t=0,i=o-1;t=n||i<=1||!this.isHorizontal())return void(this.labelRotation=s);const h=this._getLabelSizes(),c=h.widest.width,d=h.highest.height,u=dt(this.chart.width-c,0,this.maxWidth);o=t.offset?this.maxWidth/i:u/(i-1),c+6>o&&(o=u/(i-(t.offset?.5:1)),a=this.maxHeight-Ns(t.grid)-e.padding-Ws(t.title,this.chart.options.font),r=Math.sqrt(c*c+d*d),l=nt(Math.min(Math.asin(dt((h.highest.height+6)/o,-1,1)),Math.asin(dt(a/r,-1,1))-Math.asin(dt(d/r,-1,1)))),l=Math.max(s,Math.min(n,l))),this.labelRotation=l}afterCalculateLabelRotation(){D(this.options.afterCalculateLabelRotation,[this])}beforeFit(){D(this.options.beforeFit,[this])}fit(){const t={width:0,height:0},{chart:e,options:{ticks:i,title:s,grid:n}}=this,o=this._isVisible(),a=this.isHorizontal();if(o){const o=Ws(s,e.options.font);if(a?(t.width=this.maxWidth,t.height=Ns(n)+o):(t.height=this.maxHeight,t.width=Ns(n)+o),i.display&&this.ticks.length){const{first:e,last:s,widest:n,highest:o}=this._getLabelSizes(),r=2*i.padding,l=st(this.labelRotation),h=Math.cos(l),c=Math.sin(l);if(a){const e=i.mirror?0:c*n.width+h*o.height;t.height=Math.min(this.maxHeight,t.height+e+r)}else{const e=i.mirror?0:h*n.width+c*o.height;t.width=Math.min(this.maxWidth,t.width+e+r)}this._calculatePadding(e,s,c,h)}}this._handleMargins(),a?(this.width=this._length=e.width-this._margins.left-this._margins.right,this.height=t.height):(this.width=t.width,this.height=this._length=e.height-this._margins.top-this._margins.bottom)}_calculatePadding(t,e,i,s){const{ticks:{align:n,padding:o},position:a}=this.options,r=0!==this.labelRotation,l="top"!==a&&"x"===this.axis;if(this.isHorizontal()){const a=this.getPixelForTick(0)-this.left,h=this.right-this.getPixelForTick(this.ticks.length-1);let c=0,d=0;r?l?(c=s*t.width,d=i*e.height):(c=i*t.height,d=s*e.width):"start"===n?d=e.width:"end"===n?c=t.width:(c=t.width/2,d=e.width/2),this.paddingLeft=Math.max((c-a+o)*this.width/(this.width-a),0),this.paddingRight=Math.max((d-h+o)*this.width/(this.width-h),0)}else{let i=e.height/2,s=t.height/2;"start"===n?(i=0,s=t.height):"end"===n&&(i=e.height,s=0),this.paddingTop=i+o,this.paddingBottom=s+o}}_handleMargins(){this._margins&&(this._margins.left=Math.max(this.paddingLeft,this._margins.left),this._margins.top=Math.max(this.paddingTop,this._margins.top),this._margins.right=Math.max(this.paddingRight,this._margins.right),this._margins.bottom=Math.max(this.paddingBottom,this._margins.bottom))}afterFit(){D(this.options.afterFit,[this])}isHorizontal(){const{axis:t,position:e}=this.options;return"top"===e||"bottom"===e||"x"===t}isFullSize(){return this.options.fullSize}_convertTicksToLabels(t){let e,i;for(this.beforeTickToLabelConversion(),this.generateTickLabels(t),e=0,i=t.length;e{const i=t.gc,s=i.length/2;let n;if(s>e){for(n=0;n({width:n[t]||0,height:o[t]||0});return{first:M(0),last:M(e-1),widest:M(_),highest:M(y),widths:n,heights:o}}getLabelForValue(t){return t}getPixelForValue(t,e){return NaN}getValueForPixel(t){}getPixelForTick(t){const e=this.ticks;return t<0||t>e.length-1?null:this.getPixelForValue(e[t].value)}getPixelForDecimal(t){this._reversePixels&&(t=1-t);const e=this._startPixel+t*this._length;return dt(this._alignToPixels?ie(this.chart,e,0):e,-32768,32767)}getDecimalForPixel(t){const e=(t-this._startPixel)/this._length;return this._reversePixels?1-e:e}getBasePixel(){return this.getPixelForValue(this.getBaseValue())}getBaseValue(){const{min:t,max:e}=this;return t<0&&e<0?e:t>0&&e>0?t:0}getContext(t){const e=this.ticks||[];if(t>=0&&ta*s?a/i:r/s:r*s0}_computeGridLineItems(t){const e=this.axis,i=this.chart,s=this.options,{grid:n,position:o}=s,a=n.offset,r=this.isHorizontal(),l=this.ticks.length+(a?1:0),h=Ns(n),c=[],d=n.setContext(this.getContext()),u=d.drawBorder?d.borderWidth:0,f=u/2,p=function(t){return ie(i,t,u)};let g,m,b,x,_,y,v,w,k,O,P,D;if("top"===o)g=p(this.bottom),y=this.bottom-h,w=g-f,O=p(t.top)+f,D=t.bottom;else if("bottom"===o)g=p(this.top),O=t.top,D=p(t.bottom)-f,y=g+f,w=this.top+h;else if("left"===o)g=p(this.right),_=this.right-h,v=g-f,k=p(t.left)+f,P=t.right;else if("right"===o)g=p(this.left),k=t.left,P=p(t.right)-f,_=g+f,v=this.left+h;else if("x"===e){if("center"===o)g=p((t.top+t.bottom)/2+.5);else if(M(o)){const t=Object.keys(o)[0],e=o[t];g=p(this.chart.scales[t].getPixelForValue(e))}O=t.top,D=t.bottom,y=g+f,w=y+h}else if("y"===e){if("center"===o)g=p((t.left+t.right)/2);else if(M(o)){const t=Object.keys(o)[0],e=o[t];g=p(this.chart.scales[t].getPixelForValue(e))}_=g-f,v=_-h,k=t.left,P=t.right}const E=S(s.ticks.maxTicksLimit,l),C=Math.max(1,Math.ceil(l/E));for(m=0;me.value===t);return i>=0?e.setContext(this.getContext(i)).lineWidth:0}drawGrid(t){const e=this.options.grid,i=this.ctx,s=this._gridLineItems||(this._gridLineItems=this._computeGridLineItems(t));let n,o;const a=(t,e,s)=>{s.width&&s.color&&(i.save(),i.lineWidth=s.width,i.strokeStyle=s.color,i.setLineDash(s.borderDash||[]),i.lineDashOffset=s.borderDashOffset,i.beginPath(),i.moveTo(t.x,t.y),i.lineTo(e.x,e.y),i.stroke(),i.restore())};if(e.display)for(n=0,o=s.length;n{this.drawBackground(),this.drawGrid(t),this.drawTitle()}},{z:i+1,draw:()=>{this.drawBorder()}},{z:e,draw:t=>{this.drawLabels(t)}}]:[{z:e,draw:t=>{this.draw(t)}}]}getMatchingVisibleMetas(t){const e=this.chart.getSortedVisibleDatasetMetas(),i=this.axis+"AxisID",s=[];let n,o;for(n=0,o=e.length;n{const s=i.split("."),n=s.pop(),o=[t].concat(s).join("."),a=e[i].split("."),r=a.pop(),l=a.join(".");Jt.route(o,n,l,r)})}(e,t.defaultRoutes),t.descriptors&&Jt.describe(e,t.descriptors)}(t,o,i),this.override&&Jt.override(t.id,t.overrides)),o}get(t){return this.items[t]}unregister(t){const e=this.items,i=t.id,s=this.scope;i in e&&delete e[i],s&&i in Jt[s]&&(delete Jt[s][i],this.override&&delete Kt[i])}}var Us=new class{constructor(){this.controllers=new Ys(Ri,"datasets",!0),this.elements=new Ys(Ls,"elements"),this.plugins=new Ys(Object,"plugins"),this.scales=new Ys($s,"scales"),this._typedRegistries=[this.controllers,this.scales,this.elements]}add(...t){this._each("register",t)}remove(...t){this._each("unregister",t)}addControllers(...t){this._each("register",t,this.controllers)}addElements(...t){this._each("register",t,this.elements)}addPlugins(...t){this._each("register",t,this.plugins)}addScales(...t){this._each("register",t,this.scales)}getController(t){return this._get(t,this.controllers,"controller")}getElement(t){return this._get(t,this.elements,"element")}getPlugin(t){return this._get(t,this.plugins,"plugin")}getScale(t){return this._get(t,this.scales,"scale")}removeControllers(...t){this._each("unregister",t,this.controllers)}removeElements(...t){this._each("unregister",t,this.elements)}removePlugins(...t){this._each("unregister",t,this.plugins)}removeScales(...t){this._each("unregister",t,this.scales)}_each(t,e,i){[...e].forEach(e=>{const s=i||this._getRegistryForType(e);i||s.isForType(e)||s===this.plugins&&e.id?this._exec(t,s,e):E(e,e=>{const s=i||this._getRegistryForType(e);this._exec(t,s,e)})})}_exec(t,e,i){const s=V(t);D(i["before"+s],[],i),e[t](i),D(i["after"+s],[],i)}_getRegistryForType(t){for(let e=0;et.filter(t=>!e.some(e=>t.plugin.id===e.plugin.id));this._notify(s(e,i),t,"stop"),this._notify(s(i,e),t,"start")}}function qs(t,e){return e||!1!==t?!0===t?{}:t:null}function Ks(t,e,i,s){const n=t.pluginScopeKeys(e),o=t.getOptionScopes(i,n);return t.createResolver(o,s,[""],{scriptable:!1,indexable:!1,allKeys:!0})}function Gs(t,e){const i=Jt.datasets[t]||{};return((e.datasets||{})[t]||{}).indexAxis||e.indexAxis||i.indexAxis||"x"}function Zs(t,e){return"x"===t||"y"===t?t:e.axis||("top"===(i=e.position)||"bottom"===i?"x":"left"===i||"right"===i?"y":void 0)||t.charAt(0).toLowerCase();var i}function Qs(t){const e=t.options||(t.options={});e.plugins=S(e.plugins,{}),e.scales=function(t,e){const i=Kt[t.type]||{scales:{}},s=e.scales||{},n=Gs(t.type,e),o=Object.create(null),a=Object.create(null);return Object.keys(s).forEach(t=>{const e=s[t];if(!M(e))return console.error("Invalid scale configuration for scale: "+t);if(e._proxy)return console.warn("Ignoring resolver passed as options for scale: "+t);const r=Zs(t,e),l=function(t,e){return t===e?"_index_":"_value_"}(r,n),h=i.scales||{};o[r]=o[r]||t,a[t]=j(Object.create(null),[{axis:r},e,h[r],h[l]])}),t.data.datasets.forEach(i=>{const n=i.type||t.type,r=i.indexAxis||Gs(n,e),l=(Kt[n]||{}).scales||{};Object.keys(l).forEach(t=>{const e=function(t,e){let i=t;return"_index_"===t?i=e:"_value_"===t&&(i="x"===e?"y":"x"),i}(t,r),n=i[e+"AxisID"]||o[e]||e;a[n]=a[n]||Object.create(null),j(a[n],[{axis:e},s[n],l[t]])})}),Object.keys(a).forEach(t=>{const e=a[t];j(e,[Jt.scales[e.type],Jt.scale])}),a}(t,e)}function Js(t){return(t=t||{}).datasets=t.datasets||[],t.labels=t.labels||[],t}const tn=new Map,en=new Set;function sn(t,e){let i=tn.get(t);return i||(i=e(),tn.set(t,i),en.add(i)),i}const nn=(t,e,i)=>{const s=z(e,i);void 0!==s&&t.add(s)};class on{constructor(t){this._config=function(t){return(t=t||{}).data=Js(t.data),Qs(t),t}(t),this._scopeCache=new Map,this._resolverCache=new Map}get platform(){return this._config.platform}get type(){return this._config.type}set type(t){this._config.type=t}get data(){return this._config.data}set data(t){this._config.data=Js(t)}get options(){return this._config.options}set options(t){this._config.options=t}get plugins(){return this._config.plugins}update(){const t=this._config;this.clearCache(),Qs(t)}clearCache(){this._scopeCache.clear(),this._resolverCache.clear()}datasetScopeKeys(t){return sn(t,()=>[["datasets."+t,""]])}datasetAnimationScopeKeys(t,e){return sn(`${t}.transition.${e}`,()=>[[`datasets.${t}.transitions.${e}`,"transitions."+e],["datasets."+t,""]])}datasetElementScopeKeys(t,e){return sn(`${t}-${e}`,()=>[[`datasets.${t}.elements.${e}`,"datasets."+t,"elements."+e,""]])}pluginScopeKeys(t){const e=t.id;return sn(`${this.type}-plugin-${e}`,()=>[["plugins."+e,...t.additionalOptionScopes||[]]])}_cachedScopes(t,e){const i=this._scopeCache;let s=i.get(t);return s&&!e||(s=new Map,i.set(t,s)),s}getOptionScopes(t,e,i){const{options:s,type:n}=this,o=this._cachedScopes(t,i),a=o.get(e);if(a)return a;const r=new Set;e.forEach(e=>{t&&(r.add(t),e.forEach(e=>nn(r,t,e))),e.forEach(t=>nn(r,s,t)),e.forEach(t=>nn(r,Kt[n]||{},t)),e.forEach(t=>nn(r,Jt,t)),e.forEach(t=>nn(r,Gt,t))});const l=Array.from(r);return 0===l.length&&l.push(Object.create(null)),en.has(e)&&o.set(e,l),l}chartOptionScopes(){const{options:t,type:e}=this;return[t,Kt[e]||{},Jt.datasets[e]||{},{type:e},Jt,Gt]}resolveNamedOptions(t,e,i,s=[""]){const n={$shared:!0},{resolver:o,subPrefixes:a}=an(this._resolverCache,t,s);let r=o;(function(t,e){const{isScriptable:i,isIndexable:s}=Ae(t);for(const n of e){const e=i(n),o=s(n),a=(o||e)&&t[n];if(e&&(N(a)||rn(a))||o&&w(a))return!0}return!1})(o,e)&&(n.$shared=!1,r=Ce(o,i=N(i)?i():i,this.createResolver(t,i,a)));for(const t of e)n[t]=r[t];return n}createResolver(t,e,i=[""],s){const{resolver:n}=an(this._resolverCache,t,i);return M(e)?Ce(n,e,void 0,s):n}}function an(t,e,i){let s=t.get(e);s||(s=new Map,t.set(e,s));const n=i.join();let o=s.get(n);return o||(o={resolver:Ee(e,i),subPrefixes:i.filter(t=>!t.toLowerCase().includes("hover"))},s.set(n,o)),o}const rn=t=>M(t)&&Object.getOwnPropertyNames(t).reduce((e,i)=>e||N(t[i]),!1),ln=["top","bottom","left","right","chartArea"];function hn(t,e){return"top"===t||"bottom"===t||-1===ln.indexOf(t)&&"x"===e}function cn(t,e){return function(i,s){return i[t]===s[t]?i[e]-s[e]:i[t]-s[t]}}function dn(t){const e=t.chart,i=e.options.animation;e.notifyPlugins("afterRender"),D(i&&i.onComplete,[t],e)}function un(t){const e=t.chart,i=e.options.animation;D(i&&i.onProgress,[t],e)}function fn(t){return qe()&&"string"==typeof t?t=document.getElementById(t):t&&t.length&&(t=t[0]),t&&t.canvas&&(t=t.canvas),t}const pn={},gn=t=>{const e=fn(t);return Object.values(pn).filter(t=>t.canvas===e).pop()};function mn(t,e,i){const s=Object.keys(t);for(const n of s){const s=+n;if(s>=e){const o=t[n];delete t[n],(i>0||s>e)&&(t[s+i]=o)}}}class bn{constructor(t,e){const i=this.config=new on(e),s=fn(t),n=gn(s);if(n)throw new Error("Canvas is already in use. Chart with ID '"+n.id+"' must be destroyed before the canvas can be reused.");const o=i.createResolver(i.chartOptionScopes(),this.getContext());this.platform=new(i.platform||function(t){return!qe()||"undefined"!=typeof OffscreenCanvas&&t instanceof OffscreenCanvas?_s:Rs}(s)),this.platform.updateConfig(i);const a=this.platform.acquireContext(s,o.aspectRatio),r=a&&a.canvas,l=r&&r.height,h=r&&r.width;this.id=y(),this.ctx=a,this.canvas=r,this.width=h,this.height=l,this._options=o,this._aspectRatio=this.aspectRatio,this._layers=[],this._metasets=[],this._stacks=void 0,this.boxes=[],this.currentDevicePixelRatio=void 0,this.chartArea=void 0,this._active=[],this._lastEvent=void 0,this._listeners={},this._responsiveListeners=void 0,this._sortedMetasets=[],this.scales={},this._plugins=new Xs,this.$proxies={},this._hiddenIndices={},this.attached=!1,this._animationsDisabled=void 0,this.$context=void 0,this._doResize=function(t,e){let i;return function(...s){return e?(clearTimeout(i),i=setTimeout(t,e,s)):t.apply(this,s),e}}(t=>this.update(t),o.resizeDelay||0),this._dataChanges=[],pn[this.id]=this,a&&r?(bi.listen(this,"complete",dn),bi.listen(this,"progress",un),this._initialize(),this.attached&&this.update()):console.error("Failed to create chart: can't acquire context from the given item")}get aspectRatio(){const{options:{aspectRatio:t,maintainAspectRatio:e},width:i,height:s,_aspectRatio:n}=this;return v(t)?e&&n?n:s?i/s:null:t}get data(){return this.config.data}set data(t){this.config.data=t}get options(){return this._options}set options(t){this.config.options=t}_initialize(){return this.notifyPlugins("beforeInit"),this.options.responsive?this.resize():ii(this,this.options.devicePixelRatio),this.bindEvents(),this.notifyPlugins("afterInit"),this}clear(){return se(this.canvas,this.ctx),this}stop(){return bi.stop(this),this}resize(t,e){bi.running(this)?this._resizeBeforeDraw={width:t,height:e}:this._resize(t,e)}_resize(t,e){const i=this.options,s=this.canvas,n=i.maintainAspectRatio&&this.aspectRatio,o=this.platform.getMaximumSize(s,t,e,n),a=i.devicePixelRatio||this.platform.getDevicePixelRatio(),r=this.width?"resize":"attach";this.width=o.width,this.height=o.height,this._aspectRatio=this.aspectRatio,ii(this,a,!0)&&(this.notifyPlugins("resize",{size:o}),D(i.onResize,[this,o],this),this.attached&&this._doResize(r)&&this.render())}ensureScalesHaveIDs(){E(this.options.scales||{},(t,e)=>{t.id=e})}buildOrUpdateScales(){const t=this.options,e=t.scales,i=this.scales,s=Object.keys(i).reduce((t,e)=>(t[e]=!1,t),{});let n=[];e&&(n=n.concat(Object.keys(e).map(t=>{const i=e[t],s=Zs(t,i),n="r"===s,o="x"===s;return{options:i,dposition:n?"chartArea":o?"bottom":"left",dtype:n?"radialLinear":o?"category":"linear"}}))),E(n,e=>{const n=e.options,o=n.id,a=Zs(o,n),r=S(n.type,e.dtype);void 0!==n.position&&hn(n.position,a)===hn(e.dposition)||(n.position=e.dposition),s[o]=!0;let l=null;o in i&&i[o].type===r?l=i[o]:(l=new(Us.getScale(r))({id:o,type:r,ctx:this.ctx,chart:this}),i[l.id]=l),l.init(n,t)}),E(s,(t,e)=>{t||delete i[e]}),E(i,t=>{bs.configure(this,t,t.options),bs.addBox(this,t)})}_updateMetasets(){const t=this._metasets,e=this.data.datasets.length,i=t.length;if(t.sort((t,e)=>t.index-e.index),i>e){for(let t=e;te.length&&delete this._stacks,t.forEach((t,i)=>{0===e.filter(e=>e===t._dataset).length&&this._destroyDatasetMeta(i)})}buildOrUpdateControllers(){const t=[],e=this.data.datasets;let i,s;for(this._removeUnreferencedMetasets(),i=0,s=e.length;i{this.getDatasetMeta(e).controller.reset()},this)}reset(){this._resetElements(),this.notifyPlugins("reset")}update(t){const e=this.config;e.update();const i=this._options=e.createResolver(e.chartOptionScopes(),this.getContext()),s=this._animationsDisabled=!i.animation;if(this._updateScales(),this._checkEventBindings(),this._updateHiddenIndices(),this._plugins.invalidate(),!1===this.notifyPlugins("beforeUpdate",{mode:t,cancelable:!0}))return;const n=this.buildOrUpdateControllers();this.notifyPlugins("beforeElementsUpdate");let o=0;for(let t=0,e=this.data.datasets.length;t{t.reset()}),this._updateDatasets(t),this.notifyPlugins("afterUpdate",{mode:t}),this._layers.sort(cn("z","_idx"));const{_active:a,_lastEvent:r}=this;r?this._eventHandler(r,!0):a.length&&this._updateHoverStyles(a,a,!0),this.render()}_updateScales(){E(this.scales,t=>{bs.removeBox(this,t)}),this.ensureScalesHaveIDs(),this.buildOrUpdateScales()}_checkEventBindings(){const t=this.options,e=new Set(Object.keys(this._listeners)),i=new Set(t.events);W(e,i)&&!!this._responsiveListeners===t.responsive||(this.unbindEvents(),this.bindEvents())}_updateHiddenIndices(){const{_hiddenIndices:t}=this,e=this._getUniformDataChanges()||[];for(const{method:i,start:s,count:n}of e)mn(t,s,"_removeElements"===i?-n:n)}_getUniformDataChanges(){const t=this._dataChanges;if(!t||!t.length)return;this._dataChanges=[];const e=this.data.datasets.length,i=e=>new Set(t.filter(t=>t[0]===e).map((t,e)=>e+","+t.splice(1).join(","))),s=i(0);for(let t=1;tt.split(",")).map(t=>({method:t[1],start:+t[2],count:+t[3]}))}_updateLayout(t){if(!1===this.notifyPlugins("beforeLayout",{cancelable:!0}))return;bs.update(this,this.width,this.height,t);const e=this.chartArea,i=e.width<=0||e.height<=0;this._layers=[],E(this.boxes,t=>{i&&"chartArea"===t.position||(t.configure&&t.configure(),this._layers.push(...t._layers()))},this),this._layers.forEach((t,e)=>{t._idx=e}),this.notifyPlugins("afterLayout")}_updateDatasets(t){if(!1!==this.notifyPlugins("beforeDatasetsUpdate",{mode:t,cancelable:!0})){for(let t=0,e=this.data.datasets.length;t=0;--e)this._drawDataset(t[e]);this.notifyPlugins("afterDatasetsDraw")}_drawDataset(t){const e=this.ctx,i=t._clip,s=!i.disabled,n=this.chartArea,o={meta:t,index:t.index,cancelable:!0};!1!==this.notifyPlugins("beforeDatasetDraw",o)&&(s&&ae(e,{left:!1===i.left?0:n.left-i.left,right:!1===i.right?this.width:n.right+i.right,top:!1===i.top?0:n.top-i.top,bottom:!1===i.bottom?this.height:n.bottom+i.bottom}),t.controller.draw(),s&&re(e),o.cancelable=!1,this.notifyPlugins("afterDatasetDraw",o))}getElementsAtEventForMode(t,e,i,s){const n=os.modes[e];return"function"==typeof n?n(this,t,i,s):[]}getDatasetMeta(t){const e=this.data.datasets[t],i=this._metasets;let s=i.filter(t=>t&&t._dataset===e).pop();return s||(s={type:null,data:[],dataset:null,controller:null,hidden:null,xAxisID:null,yAxisID:null,order:e&&e.order||0,index:t,_dataset:e,_parsed:[],_sorted:!1},i.push(s)),s}getContext(){return this.$context||(this.$context=we(null,{chart:this,type:"chart"}))}getVisibleDatasetCount(){return this.getSortedVisibleDatasetMetas().length}isDatasetVisible(t){const e=this.data.datasets[t];if(!e)return!1;const i=this.getDatasetMeta(t);return"boolean"==typeof i.hidden?!i.hidden:!e.hidden}setDatasetVisibility(t,e){this.getDatasetMeta(t).hidden=!e}toggleDataVisibility(t){this._hiddenIndices[t]=!this._hiddenIndices[t]}getDataVisibility(t){return!this._hiddenIndices[t]}_updateVisibility(t,e,i){const s=i?"show":"hide",n=this.getDatasetMeta(t),o=n.controller._resolveAnimations(void 0,s);B(e)?(n.data[e].hidden=!i,this.update()):(this.setDatasetVisibility(t,i),o.update(n,{visible:i}),this.update(e=>e.datasetIndex===t?s:void 0))}hide(t,e){this._updateVisibility(t,e,!1)}show(t,e){this._updateVisibility(t,e,!0)}_destroyDatasetMeta(t){const e=this._metasets[t];e&&e.controller&&e.controller._destroy(),delete this._metasets[t]}_stop(){let t,e;for(this.stop(),bi.remove(this),t=0,e=this.data.datasets.length;t{e.addEventListener(this,i,s),t[i]=s},s=(t,e,i)=>{t.offsetX=e,t.offsetY=i,this._eventHandler(t)};E(this.options.events,t=>i(t,s))}bindResponsiveEvents(){this._responsiveListeners||(this._responsiveListeners={});const t=this._responsiveListeners,e=this.platform,i=(i,s)=>{e.addEventListener(this,i,s),t[i]=s},s=(i,s)=>{t[i]&&(e.removeEventListener(this,i,s),delete t[i])},n=(t,e)=>{this.canvas&&this.resize(t,e)};let o;const a=()=>{s("attach",a),this.attached=!0,this.resize(),i("resize",n),i("detach",o)};o=()=>{this.attached=!1,s("resize",n),this._stop(),this._resize(0,0),i("attach",a)},e.isAttached(this.canvas)?a():o()}unbindEvents(){E(this._listeners,(t,e)=>{this.platform.removeEventListener(this,e,t)}),this._listeners={},E(this._responsiveListeners,(t,e)=>{this.platform.removeEventListener(this,e,t)}),this._responsiveListeners=void 0}updateHoverStyle(t,e,i){const s=i?"set":"remove";let n,o,a,r;for("dataset"===e&&(n=this.getDatasetMeta(t[0].datasetIndex),n.controller["_"+s+"DatasetHoverStyle"]()),a=0,r=t.length;a{const i=this.getDatasetMeta(t);if(!i)throw new Error("No dataset found at index "+t);return{datasetIndex:t,element:i.data[e],index:e}});!C(i,e)&&(this._active=i,this._lastEvent=null,this._updateHoverStyles(i,e))}notifyPlugins(t,e,i){return this._plugins.notify(this,t,e,i)}_updateHoverStyles(t,e,i){const s=this.options.hover,n=(t,e)=>t.filter(t=>!e.some(e=>t.datasetIndex===e.datasetIndex&&t.index===e.index)),o=n(e,t),a=i?t:n(t,e);o.length&&this.updateHoverStyle(o,s.mode,!1),a.length&&s.mode&&this.updateHoverStyle(a,s.mode,!0)}_eventHandler(t,e){const i={event:t,replay:e,cancelable:!0,inChartArea:oe(t,this.chartArea,this._minPadding)},s=e=>(e.options.events||this.options.events).includes(t.native.type);if(!1===this.notifyPlugins("beforeEvent",i,s))return;const n=this._handleEvent(t,e,i.inChartArea);return i.cancelable=!1,this.notifyPlugins("afterEvent",i,s),(n||i.changed)&&this.render(),this}_handleEvent(t,e,i){const{_active:s=[],options:n}=this,o=e,a=this._getActiveElements(t,s,i,o),r=function(t){return"mouseup"===t.type||"click"===t.type||"contextmenu"===t.type}(t),l=function(t,e,i,s){return i&&"mouseout"!==t.type?s?e:t:null}(t,this._lastEvent,i,r);i&&(this._lastEvent=null,D(n.onHover,[t,a,this],this),r&&D(n.onClick,[t,a,this],this));const h=!C(a,s);return(h||e)&&(this._active=a,this._updateHoverStyles(a,s,e)),this._lastEvent=l,h}_getActiveElements(t,e,i,s){if("mouseout"===t.type)return[];if(!i)return e;const n=this.options.hover;return this.getElementsAtEventForMode(t,n.mode,n,s)}}const xn=()=>E(bn.instances,t=>t._plugins.invalidate());function yn(t,e,i){const{startAngle:s,pixelMargin:n,x:o,y:a,outerRadius:r,innerRadius:l}=e;let h=n/r;t.beginPath(),t.arc(o,a,r,s-h,i+h),l>n?(h=n/l,t.arc(o,a,l,i+h,s-h,!0)):t.arc(o,a,n,i+q,s-q),t.closePath(),t.clip()}function vn(t,e,i,s){return{x:i+t*Math.cos(e),y:s+t*Math.sin(e)}}function wn(t,e,i,s,n){const{x:o,y:a,startAngle:r,pixelMargin:l,innerRadius:h}=e,c=Math.max(e.outerRadius+s+i-l,0),d=h>0?h+s+i+l:0;let u=0;const f=n-r;if(s){const t=((h>0?h-s:0)+(c>0?c-s:0))/2;u=(f-(0!==t?f*t/(t+s):f))/2}const p=(f-Math.max(.001,f*c-i/H)/c)/2,g=r+p+u,m=n-p-u,{outerStart:b,outerEnd:x,innerStart:_,innerEnd:y}=function(t,e,i,s){const n=me(t.options.borderRadius,["outerStart","outerEnd","innerStart","innerEnd"]),o=(i-e)/2,a=Math.min(o,s*e/2),r=t=>{const e=(i-Math.min(o,t))*s/2;return dt(t,0,Math.min(o,e))};return{outerStart:r(n.outerStart),outerEnd:r(n.outerEnd),innerStart:dt(n.innerStart,0,a),innerEnd:dt(n.innerEnd,0,a)}}(e,d,c,m-g),v=c-b,w=c-x,M=g+b/v,k=m-x/w,O=d+_,S=d+y,P=g+_/O,D=m-y/S;if(t.beginPath(),t.arc(o,a,c,M,k),x>0){const e=vn(w,k,o,a);t.arc(e.x,e.y,x,k,m+q)}const E=vn(S,m,o,a);if(t.lineTo(E.x,E.y),y>0){const e=vn(S,D,o,a);t.arc(e.x,e.y,y,m+q,D+Math.PI)}if(t.arc(o,a,d,m-y/d,g+_/d,!0),_>0){const e=vn(O,P,o,a);t.arc(e.x,e.y,_,P+Math.PI,g-q)}const C=vn(v,g,o,a);if(t.lineTo(C.x,C.y),b>0){const e=vn(v,M,o,a);t.arc(e.x,e.y,b,g-q,M)}t.closePath()}Object.defineProperties(bn,{defaults:{enumerable:!0,value:Jt},instances:{enumerable:!0,value:pn},overrides:{enumerable:!0,value:Kt},registry:{enumerable:!0,value:Us},version:{enumerable:!0,value:"3.7.1"},getChart:{enumerable:!0,value:gn},register:{enumerable:!0,value:(...t)=>{Us.add(...t),xn()}},unregister:{enumerable:!0,value:(...t)=>{Us.remove(...t),xn()}}});class Mn extends Ls{constructor(t){super(),this.options=void 0,this.circumference=void 0,this.startAngle=void 0,this.endAngle=void 0,this.innerRadius=void 0,this.outerRadius=void 0,this.pixelMargin=0,this.fullCircles=0,t&&Object.assign(this,t)}inRange(t,e,i){const s=this.getProps(["x","y"],i),{angle:n,distance:o}=at(s,{x:t,y:e}),{startAngle:a,endAngle:r,innerRadius:l,outerRadius:h,circumference:c}=this.getProps(["startAngle","endAngle","innerRadius","outerRadius","circumference"],i),d=this.options.spacing/2,u=S(c,r-a)>=$||ct(n,a,r),f=ut(o,l+d,h+d);return u&&f}getCenterPoint(t){const{x:e,y:i,startAngle:s,endAngle:n,innerRadius:o,outerRadius:a}=this.getProps(["x","y","startAngle","endAngle","innerRadius","outerRadius","circumference"],t),{offset:r,spacing:l}=this.options,h=(s+n)/2,c=(o+a+l+r)/2;return{x:e+Math.cos(h)*c,y:i+Math.sin(h)*c}}tooltipPosition(t){return this.getCenterPoint(t)}draw(t){const{options:e,circumference:i}=this,s=(e.offset||0)/2,n=(e.spacing||0)/2;if(this.pixelMargin="inner"===e.borderAlign?.33:0,this.fullCircles=i>$?Math.floor(i/$):0,0===i||this.innerRadius<0||this.outerRadius<0)return;t.save();let o=0;if(s){o=s/2;const e=(this.startAngle+this.endAngle)/2;t.translate(Math.cos(e)*o,Math.sin(e)*o),this.circumference>=H&&(o=s)}t.fillStyle=e.backgroundColor,t.strokeStyle=e.borderColor;const a=function(t,e,i,s){const{fullCircles:n,startAngle:o,circumference:a}=e;let r=e.endAngle;if(n){wn(t,e,i,s,o+$);for(let e=0;er&&o>r;return{count:s,start:l,loop:e.loop,ilen:h(a+(h?r-t:t))%o,_=()=>{f!==p&&(t.lineTo(m,p),t.lineTo(m,f),t.lineTo(m,g))};for(l&&(d=n[x(0)],t.moveTo(d.x,d.y)),c=0;c<=r;++c){if(d=n[x(c)],d.skip)continue;const e=d.x,i=d.y,s=0|e;s===u?(ip&&(p=i),m=(b*m+e)/++b):(_(),t.lineTo(e,i),u=s,b=0,f=p=i),g=i}_()}function En(t){const e=t.options,i=e.borderDash&&e.borderDash.length;return t._decimated||t._loop||e.tension||"monotone"===e.cubicInterpolationMode||e.stepped||i?Pn:Dn}Mn.id="arc",Mn.defaults={borderAlign:"center",borderColor:"#fff",borderJoinStyle:void 0,borderRadius:0,borderWidth:2,offset:0,spacing:0,angle:void 0},Mn.defaultRoutes={backgroundColor:"backgroundColor"};const Cn="function"==typeof Path2D;class An extends Ls{constructor(t){super(),this.animated=!0,this.options=void 0,this._chart=void 0,this._loop=void 0,this._fullLoop=void 0,this._path=void 0,this._points=void 0,this._segments=void 0,this._decimated=!1,this._pointsUpdated=!1,this._datasetIndex=void 0,t&&Object.assign(this,t)}updateControlPoints(t,e){const i=this.options;if((i.tension||"monotone"===i.cubicInterpolationMode)&&!i.stepped&&!this._pointsUpdated){const s=i.spanGaps?this._loop:this._fullLoop;Xe(this._points,i,t,s,e),this._pointsUpdated=!0}}set points(t){this._points=t,delete this._segments,delete this._path,this._pointsUpdated=!1}get points(){return this._points}get segments(){return this._segments||(this._segments=function(t,e){const i=t.points,s=t.options.spanGaps,n=i.length;if(!n)return[];const o=!!t._loop,{start:a,end:r}=function(t,e,i,s){let n=0,o=e-1;if(i&&!s)for(;nn&&t[o%e].skip;)o--;return o%=e,{start:n,end:o}}(i,n,o,s);return function(t,e,i,s){return s&&s.setContext&&i?function(t,e,i,s){const n=t._chart.getContext(),o=gi(t.options),{_datasetIndex:a,options:{spanGaps:r}}=t,l=i.length,h=[];let c=o,d=e[0].start,u=d;function f(t,e,s,n){const o=r?-1:1;if(t!==e){for(t+=l;i[t%l].skip;)t-=o;for(;i[e%l].skip;)e+=o;t%l!=e%l&&(h.push({start:t%l,end:e%l,loop:s,style:n}),c=n,d=e%l)}}for(const t of e){d=r?d:t.start;let e,o=i[d%l];for(u=d+1;u<=t.end;u++){const r=i[u%l];e=gi(s.setContext(we(n,{type:"segment",p0:o,p1:r,p0DataIndex:(u-1)%l,p1DataIndex:u%l,datasetIndex:a}))),mi(e,c)&&f(d,u-1,t.loop,c),o=r,c=e}d"borderDash"!==t&&"fill"!==t};class Rn extends Ls{constructor(t){super(),this.options=void 0,this.parsed=void 0,this.skip=void 0,this.stop=void 0,t&&Object.assign(this,t)}inRange(t,e,i){const s=this.options,{x:n,y:o}=this.getProps(["x","y"],i);return Math.pow(t-n,2)+Math.pow(e-o,2)=i)&&n):["origin","start","end","stack","shape"].indexOf(s)>=0&&s}Vn.id="bar",Vn.defaults={borderSkipped:"start",borderWidth:0,borderRadius:0,inflateAmount:"auto",pointStyle:void 0},Vn.defaultRoutes={backgroundColor:"backgroundColor",borderColor:"borderColor"};class Nn{constructor(t){this.x=t.x,this.y=t.y,this.radius=t.radius}pathSegment(t,e,i){const{x:s,y:n,radius:o}=this;return e=e||{start:0,end:$},t.arc(s,n,o,e.end,e.start,!0),!i.bounds}interpolate(t){const{x:e,y:i,radius:s}=this,n=t.angle;return{x:e+Math.cos(n)*s,y:i+Math.sin(n)*s,angle:n}}}function Wn(t,e,i){for(;e>t;e--){const t=i[e];if(!isNaN(t.x)&&!isNaN(t.y))break}return e}function Hn(t,e,i){const s=[];for(let n=0;n{e=Wn(t,e,n);const a=n[t],r=n[e];null!==s?(o.push({x:a.x,y:s}),o.push({x:r.x,y:s})):null!==i&&(o.push({x:i,y:a.y}),o.push({x:i,y:r.y}))}),o}(t,e),i.length?new An({points:i,options:{tension:0},_loop:s,_fullLoop:s}):null}function Xn(t,e,i){let s=t[e].fill;const n=[e];let o;if(!i)return s;for(;!1!==s&&-1===n.indexOf(s);){if(!k(s))return s;if(o=t[s],!o)return!1;if(o.visible)return s;n.push(s),s=o.fill}return!1}function qn(t,e,i){const{segments:s,points:n}=e;let o=!0,a=!1;t.beginPath();for(const r of s){const{start:s,end:l}=r,h=n[s],c=n[Wn(s,l,n)];o?(t.moveTo(h.x,h.y),o=!1):(t.lineTo(h.x,i),t.lineTo(h.x,h.y)),a=!!e.pathSegment(t,r,{move:a}),a?t.closePath():t.lineTo(c.x,i)}t.lineTo(e.first().x,i),t.closePath(),t.clip()}function Kn(t,e,i,s){if(s)return;let n=e[t],o=i[t];return"angle"===t&&(n=ht(n),o=ht(o)),{property:t,start:n,end:o}}function Gn(t,e,i,s){return t&&e?s(t[i],e[i]):t?t[i]:e?e[i]:0}function Zn(t,e,i){const{top:s,bottom:n}=e.chart.chartArea,{property:o,start:a,end:r}=i||{};"x"===o&&(t.beginPath(),t.rect(a,s,r-a,n-s),t.clip())}function Qn(t,e,i,s){const n=e.interpolate(i,s);n&&t.lineTo(n.x,n.y)}function Jn(t,e){const{line:i,target:s,property:n,color:o,scale:a}=e,r=function(t,e,i){const s=t.segments,n=t.points,o=e.points,a=[];for(const t of s){let{start:s,end:r}=t;r=Wn(s,r,n);const l=Kn(i,n[s],n[r],t.loop);if(!e.segments){a.push({source:t,target:l,start:n[s],end:n[r]});continue}const h=pi(e,l);for(const e of h){const s=Kn(i,o[e.start],o[e.end],e.loop),r=fi(t,n,s);for(const t of r)a.push({source:t,target:e,start:{[i]:Gn(l,s,"start",Math.max)},end:{[i]:Gn(l,s,"end",Math.min)}})}}return a}(i,s,n);for(const{source:e,target:l,start:h,end:c}of r){const{style:{backgroundColor:r=o}={}}=e,d=!0!==s;t.save(),t.fillStyle=r,Zn(t,a,d&&Kn(n,h,c)),t.beginPath();const u=!!i.pathSegment(t,e);let f;if(d){u?t.closePath():Qn(t,s,c,n);const e=!!s.pathSegment(t,l,{move:u,reverse:!0});f=u&&e,f||Qn(t,s,h,n)}t.closePath(),t.fill(f?"evenodd":"nonzero"),t.restore()}}function to(t,e,i){const s=Yn(e),{line:n,scale:o,axis:a}=e,r=n.options,l=r.fill,h=r.backgroundColor,{above:c=h,below:d=h}=l||{};s&&n.points.length&&(ae(t,i),function(t,e){const{line:i,target:s,above:n,below:o,area:a,scale:r}=e,l=i._loop?"angle":e.axis;t.save(),"x"===l&&o!==n&&(qn(t,s,a.top),Jn(t,{line:i,target:s,color:n,scale:r,property:l}),t.restore(),t.save(),qn(t,s,a.bottom)),Jn(t,{line:i,target:s,color:o,scale:r,property:l}),t.restore()}(t,{line:n,target:s,above:c,below:d,area:i,scale:o,axis:a}),re(t))}var eo={id:"filler",afterDatasetsUpdate(t,e,i){const s=(t.data.datasets||[]).length,n=[];let o,a,r,l;for(a=0;a=0;--e){const i=n[e].$filler;i&&(i.line.updateControlPoints(o,i.axis),s&&to(t.ctx,i,o))}},beforeDatasetsDraw(t,e,i){if("beforeDatasetsDraw"!==i.drawTime)return;const s=t.getSortedVisibleDatasetMetas();for(let e=s.length-1;e>=0;--e){const i=s[e].$filler;i&&to(t.ctx,i,t.chartArea)}},beforeDatasetDraw(t,e,i){const s=e.meta.$filler;s&&!1!==s.fill&&"beforeDatasetDraw"===i.drawTime&&to(t.ctx,s,t.chartArea)},defaults:{propagate:!0,drawTime:"beforeDatasetDraw"}};new WeakMap;const io={average(t){if(!t.length)return!1;let e,i,s=0,n=0,o=0;for(e=0,i=t.length;e-1?t.split("\n"):t}function oo(t,e){const{element:i,datasetIndex:s,index:n}=e,o=t.getDatasetMeta(s).controller,{label:a,value:r}=o.getLabelAndValue(n);return{chart:t,label:a,parsed:o.getParsed(n),raw:t.data.datasets[s].data[n],formattedValue:r,dataset:o.getDataset(),dataIndex:n,datasetIndex:s,element:i}}function ao(t,e){const i=t.chart.ctx,{body:s,footer:n,title:o}=t,{boxWidth:a,boxHeight:r}=e,l=ye(e.bodyFont),h=ye(e.titleFont),c=ye(e.footerFont),d=o.length,u=n.length,f=s.length,p=_e(e.padding);let g=p.height,m=0,b=s.reduce((t,e)=>t+e.before.length+e.lines.length+e.after.length,0);b+=t.beforeBody.length+t.afterBody.length,d&&(g+=d*h.lineHeight+(d-1)*e.titleSpacing+e.titleMarginBottom),b&&(g+=f*(e.displayColors?Math.max(r,l.lineHeight):l.lineHeight)+(b-f)*l.lineHeight+(b-1)*e.bodySpacing),u&&(g+=e.footerMarginTop+u*c.lineHeight+(u-1)*e.footerSpacing);let x=0;const _=function(t){m=Math.max(m,i.measureText(t).width+x)};return i.save(),i.font=h.string,E(t.title,_),i.font=l.string,E(t.beforeBody.concat(t.afterBody),_),x=e.displayColors?a+2+e.boxPadding:0,E(s,t=>{E(t.before,_),E(t.lines,_),E(t.after,_)}),x=0,i.font=c.string,E(t.footer,_),i.restore(),m+=p.width,{width:m,height:g}}function ro(t,e,i,s){const{x:n,width:o}=i,{width:a,chartArea:{left:r,right:l}}=t;let h="center";return"center"===s?h=n<=(r+l)/2?"left":"right":n<=o/2?h="left":n>=a-o/2&&(h="right"),function(t,e,i,s){const{x:n,width:o}=s,a=i.caretSize+i.caretPadding;return"left"===t&&n+o+a>e.width||"right"===t&&n-o-a<0||void 0}(h,t,e,i)&&(h="center"),h}function lo(t,e,i){const s=i.yAlign||e.yAlign||function(t,e){const{y:i,height:s}=e;return it.height-s/2?"bottom":"center"}(t,i);return{xAlign:i.xAlign||e.xAlign||ro(t,e,i,s),yAlign:s}}function ho(t,e,i,s){const{caretSize:n,caretPadding:o,cornerRadius:a}=t,{xAlign:r,yAlign:l}=i,h=n+o,{topLeft:c,topRight:d,bottomLeft:u,bottomRight:f}=xe(a);let p=function(t,e){let{x:i,width:s}=t;return"right"===e?i-=s:"center"===e&&(i-=s/2),i}(e,r);const g=function(t,e,i){let{y:s,height:n}=t;return"top"===e?s+=i:s-="bottom"===e?n+i:n/2,s}(e,l,h);return"center"===l?"left"===r?p+=h:"right"===r&&(p-=h):"left"===r?p-=Math.max(c,u)+n:"right"===r&&(p+=Math.max(d,f)+n),{x:dt(p,0,s.width-e.width),y:dt(g,0,s.height-e.height)}}function co(t,e,i){const s=_e(i.padding);return"center"===e?t.x+t.width/2:"right"===e?t.x+t.width-s.right:t.x+s.left}function uo(t){return so([],no(t))}function fo(t,e){const i=e&&e.dataset&&e.dataset.tooltip&&e.dataset.tooltip.callbacks;return i?t.override(i):t}class po extends Ls{constructor(t){super(),this.opacity=0,this._active=[],this._eventPosition=void 0,this._size=void 0,this._cachedAnimations=void 0,this._tooltipItems=[],this.$animations=void 0,this.$context=void 0,this.chart=t.chart||t._chart,this._chart=this.chart,this.options=t.options,this.dataPoints=void 0,this.title=void 0,this.beforeBody=void 0,this.body=void 0,this.afterBody=void 0,this.footer=void 0,this.xAlign=void 0,this.yAlign=void 0,this.x=void 0,this.y=void 0,this.height=void 0,this.width=void 0,this.caretX=void 0,this.caretY=void 0,this.labelColors=void 0,this.labelPointStyles=void 0,this.labelTextColors=void 0}initialize(t){this.options=t,this._cachedAnimations=void 0,this.$context=void 0}_resolveAnimations(){const t=this._cachedAnimations;if(t)return t;const e=this.chart,i=this.options.setContext(this.getContext()),s=i.enabled&&e.options.animation&&i.animations,n=new vi(this.chart,s);return s._cacheable&&(this._cachedAnimations=Object.freeze(n)),n}getContext(){return this.$context||(this.$context=(this,we(this.chart.getContext(),{tooltip:this,tooltipItems:this._tooltipItems,type:"tooltip"})))}getTitle(t,e){const{callbacks:i}=e,s=i.beforeTitle.apply(this,[t]),n=i.title.apply(this,[t]),o=i.afterTitle.apply(this,[t]);let a=[];return a=so(a,no(s)),a=so(a,no(n)),a=so(a,no(o)),a}getBeforeBody(t,e){return uo(e.callbacks.beforeBody.apply(this,[t]))}getBody(t,e){const{callbacks:i}=e,s=[];return E(t,t=>{const e={before:[],lines:[],after:[]},n=fo(i,t);so(e.before,no(n.beforeLabel.call(this,t))),so(e.lines,n.label.call(this,t)),so(e.after,no(n.afterLabel.call(this,t))),s.push(e)}),s}getAfterBody(t,e){return uo(e.callbacks.afterBody.apply(this,[t]))}getFooter(t,e){const{callbacks:i}=e,s=i.beforeFooter.apply(this,[t]),n=i.footer.apply(this,[t]),o=i.afterFooter.apply(this,[t]);let a=[];return a=so(a,no(s)),a=so(a,no(n)),a=so(a,no(o)),a}_createItems(t){const e=this._active,i=this.chart.data,s=[],n=[],o=[];let a,r,l=[];for(a=0,r=e.length;at.filter(e,s,n,i))),t.itemSort&&(l=l.sort((e,s)=>t.itemSort(e,s,i))),E(l,e=>{const i=fo(t.callbacks,e);s.push(i.labelColor.call(this,e)),n.push(i.labelPointStyle.call(this,e)),o.push(i.labelTextColor.call(this,e))}),this.labelColors=s,this.labelPointStyles=n,this.labelTextColors=o,this.dataPoints=l,l}update(t,e){const i=this.options.setContext(this.getContext()),s=this._active;let n,o=[];if(s.length){const t=io[i.position].call(this,s,this._eventPosition);o=this._createItems(i),this.title=this.getTitle(o,i),this.beforeBody=this.getBeforeBody(o,i),this.body=this.getBody(o,i),this.afterBody=this.getAfterBody(o,i),this.footer=this.getFooter(o,i);const e=this._size=ao(this,i),a=Object.assign({},t,e),r=lo(this.chart,i,a),l=ho(i,a,r,this.chart);this.xAlign=r.xAlign,this.yAlign=r.yAlign,n={opacity:1,x:l.x,y:l.y,width:e.width,height:e.height,caretX:t.x,caretY:t.y}}else 0!==this.opacity&&(n={opacity:0});this._tooltipItems=o,this.$context=void 0,n&&this._resolveAnimations().update(this,n),t&&i.external&&i.external.call(this,{chart:this.chart,tooltip:this,replay:e})}drawCaret(t,e,i,s){const n=this.getCaretPosition(t,i,s);e.lineTo(n.x1,n.y1),e.lineTo(n.x2,n.y2),e.lineTo(n.x3,n.y3)}getCaretPosition(t,e,i){const{xAlign:s,yAlign:n}=this,{caretSize:o,cornerRadius:a}=i,{topLeft:r,topRight:l,bottomLeft:h,bottomRight:c}=xe(a),{x:d,y:u}=t,{width:f,height:p}=e;let g,m,b,x,_,y;return"center"===n?(_=u+p/2,"left"===s?(g=d,m=g-o,x=_+o,y=_-o):(g=d+f,m=g+o,x=_-o,y=_+o),b=g):(m="left"===s?d+Math.max(r,h)+o:"right"===s?d+f-Math.max(l,c)-o:this.caretX,"top"===n?(x=u,_=x-o,g=m-o,b=m+o):(x=u+p,_=x+o,g=m+o,b=m-o),y=x),{x1:g,x2:m,x3:b,y1:x,y2:_,y3:y}}drawTitle(t,e,i){const s=this.title,n=s.length;let o,a,r;if(n){const l=ci(i.rtl,this.x,this.width);for(t.x=co(this,i.titleAlign,i),e.textAlign=l.textAlign(i.titleAlign),e.textBaseline="middle",o=ye(i.titleFont),a=i.titleSpacing,e.fillStyle=i.titleColor,e.font=o.string,r=0;r0!==t)?(t.beginPath(),t.fillStyle=n.multiKeyBackground,ue(t,{x:e,y:p,w:l,h:r,radius:a}),t.fill(),t.stroke(),t.fillStyle=o.backgroundColor,t.beginPath(),ue(t,{x:i,y:p+1,w:l-2,h:r-2,radius:a}),t.fill()):(t.fillStyle=n.multiKeyBackground,t.fillRect(e,p,l,r),t.strokeRect(e,p,l,r),t.fillStyle=o.backgroundColor,t.fillRect(i,p+1,l-2,r-2))}t.fillStyle=this.labelTextColors[i]}drawBody(t,e,i){const{body:s}=this,{bodySpacing:n,bodyAlign:o,displayColors:a,boxHeight:r,boxWidth:l,boxPadding:h}=i,c=ye(i.bodyFont);let d=c.lineHeight,u=0;const f=ci(i.rtl,this.x,this.width),p=function(i){e.fillText(i,f.x(t.x+u),t.y+d/2),t.y+=d+n},g=f.textAlign(o);let m,b,x,_,y,v,w;for(e.textAlign=o,e.textBaseline="middle",e.font=c.string,t.x=co(this,g,i),e.fillStyle=i.bodyColor,E(this.beforeBody,p),u=a&&"right"!==g?"center"===o?l/2+h:l+2+h:0,_=0,v=s.length;_0&&e.stroke()}_updateAnimationTarget(t){const e=this.chart,i=this.$animations,s=i&&i.x,n=i&&i.y;if(s||n){const i=io[t.position].call(this,this._active,this._eventPosition);if(!i)return;const o=this._size=ao(this,t),a=Object.assign({},i,this._size),r=lo(e,t,a),l=ho(t,a,r,e);s._to===l.x&&n._to===l.y||(this.xAlign=r.xAlign,this.yAlign=r.yAlign,this.width=o.width,this.height=o.height,this.caretX=i.x,this.caretY=i.y,this._resolveAnimations().update(this,l))}}draw(t){const e=this.options.setContext(this.getContext());let i=this.opacity;if(!i)return;this._updateAnimationTarget(e);const s={width:this.width,height:this.height},n={x:this.x,y:this.y};i=Math.abs(i)<.001?0:i;const o=_e(e.padding),a=this.title.length||this.beforeBody.length||this.body.length||this.afterBody.length||this.footer.length;e.enabled&&a&&(t.save(),t.globalAlpha=i,this.drawBackground(n,t,s,e),function(t,e){let i,s;"ltr"!==e&&"rtl"!==e||(i=t.canvas.style,s=[i.getPropertyValue("direction"),i.getPropertyPriority("direction")],i.setProperty("direction",e,"important"),t.prevTextDirection=s)}(t,e.textDirection),n.y+=o.top,this.drawTitle(n,t,e),this.drawBody(n,t,e),this.drawFooter(n,t,e),function(t,e){void 0!==e&&(delete t.prevTextDirection,t.canvas.style.setProperty("direction",e[0],e[1]))}(t,e.textDirection),t.restore())}getActiveElements(){return this._active||[]}setActiveElements(t,e){const i=this._active,s=t.map(({datasetIndex:t,index:e})=>{const i=this.chart.getDatasetMeta(t);if(!i)throw new Error("Cannot find a dataset at index "+t);return{datasetIndex:t,element:i.data[e],index:e}}),n=!C(i,s),o=this._positionChanged(s,e);(n||o)&&(this._active=s,this._eventPosition=e,this._ignoreReplayEvents=!0,this.update(!0))}handleEvent(t,e,i=!0){if(e&&this._ignoreReplayEvents)return!1;this._ignoreReplayEvents=!1;const s=this.options,n=this._active||[],o=this._getActiveElements(t,n,e,i),a=this._positionChanged(o,t),r=e||!C(o,n)||a;return r&&(this._active=o,(s.enabled||s.external)&&(this._eventPosition={x:t.x,y:t.y},this.update(!0,e))),r}_getActiveElements(t,e,i,s){const n=this.options;if("mouseout"===t.type)return[];if(!s)return e;const o=this.chart.getElementsAtEventForMode(t,n.mode,n,i);return n.reverse&&o.reverse(),o}_positionChanged(t,e){const{caretX:i,caretY:s,options:n}=this,o=io[n.position].call(this,t,e);return!1!==o&&(i!==o.x||s!==o.y)}}po.positioners=io;var go={id:"tooltip",_element:po,positioners:io,afterInit(t,e,i){i&&(t.tooltip=new po({chart:t,options:i}))},beforeUpdate(t,e,i){t.tooltip&&t.tooltip.initialize(i)},reset(t,e,i){t.tooltip&&t.tooltip.initialize(i)},afterDraw(t){const e=t.tooltip,i={tooltip:e};!1!==t.notifyPlugins("beforeTooltipDraw",i)&&(e&&e.draw(t.ctx),t.notifyPlugins("afterTooltipDraw",i))},afterEvent(t,e){if(t.tooltip){const i=e.replay;t.tooltip.handleEvent(e.event,i,e.inChartArea)&&(e.changed=!0)}},defaults:{enabled:!0,external:null,position:"average",backgroundColor:"rgba(0,0,0,0.8)",titleColor:"#fff",titleFont:{weight:"bold"},titleSpacing:2,titleMarginBottom:6,titleAlign:"left",bodyColor:"#fff",bodySpacing:2,bodyFont:{},bodyAlign:"left",footerColor:"#fff",footerSpacing:2,footerMarginTop:6,footerFont:{weight:"bold"},footerAlign:"left",padding:6,caretPadding:2,caretSize:5,cornerRadius:6,boxHeight:(t,e)=>e.bodyFont.size,boxWidth:(t,e)=>e.bodyFont.size,multiKeyBackground:"#fff",displayColors:!0,boxPadding:0,borderColor:"rgba(0,0,0,0)",borderWidth:0,animation:{duration:400,easing:"easeOutQuart"},animations:{numbers:{type:"number",properties:["x","y","width","height","caretX","caretY"]},opacity:{easing:"linear",duration:200}},callbacks:{beforeTitle:_,title(t){if(t.length>0){const e=t[0],i=e.chart.data.labels,s=i?i.length:0;if(this&&this.options&&"dataset"===this.options.mode)return e.dataset.label||"";if(e.label)return e.label;if(s>0&&e.dataIndex"filter"!==t&&"itemSort"!==t&&"external"!==t,_indexable:!1,callbacks:{_scriptable:!1,_indexable:!1},animation:{_fallback:!1},animations:{_fallback:"animation"}},additionalOptionScopes:["interaction"]};class mo extends $s{constructor(t){super(t),this._startValue=void 0,this._valueRange=0,this._addedLabels=[]}init(t){const e=this._addedLabels;if(e.length){const t=this.getLabels();for(const{index:i,label:s}of e)t[i]===s&&t.splice(i,1);this._addedLabels=[]}super.init(t)}parse(t,e){if(v(t))return null;const i=this.getLabels();return((t,e)=>null===t?null:dt(Math.round(t),0,e))(e=isFinite(e)&&i[e]===t?e:function(t,e,i,s){const n=t.indexOf(e);return-1===n?((t,e,i,s)=>("string"==typeof e?(i=t.push(e)-1,s.unshift({index:i,label:e})):isNaN(e)&&(i=null),i))(t,e,i,s):n!==t.lastIndexOf(e)?i:n}(i,t,S(e,t),this._addedLabels),i.length-1)}determineDataLimits(){const{minDefined:t,maxDefined:e}=this.getUserBounds();let{min:i,max:s}=this.getMinMax(!0);"ticks"===this.options.bounds&&(t||(i=0),e||(s=this.getLabels().length-1)),this.min=i,this.max=s}buildTicks(){const t=this.min,e=this.max,i=this.options.offset,s=[];let n=this.getLabels();n=0===t&&e===n.length-1?n:n.slice(t,e+1),this._valueRange=Math.max(n.length-(i?0:1),1),this._startValue=this.min-(i?.5:0);for(let i=t;i<=e;i++)s.push({value:i});return s}getLabelForValue(t){const e=this.getLabels();return t>=0&&te.length-1?null:this.getPixelForValue(e[t].value)}getValueForPixel(t){return Math.round(this._startValue+this.getDecimalForPixel(t)*this._valueRange)}getBasePixel(){return this.bottom}}function bo(t,e,{horizontal:i,minRotation:s}){const n=st(s),o=(i?Math.sin(n):Math.cos(n))||.001,a=.75*e*(""+t).length;return Math.min(e/o,a)}mo.id="category",mo.defaults={ticks:{callback:mo.prototype.getLabelForValue}};class xo extends $s{constructor(t){super(t),this.start=void 0,this.end=void 0,this._startValue=void 0,this._endValue=void 0,this._valueRange=0}parse(t,e){return v(t)||("number"==typeof t||t instanceof Number)&&!isFinite(+t)?null:+t}handleTickRangeOptions(){const{beginAtZero:t}=this.options,{minDefined:e,maxDefined:i}=this.getUserBounds();let{min:s,max:n}=this;const o=t=>s=e?s:t,a=t=>n=i?n:t;if(t){const t=Q(s),e=Q(n);t<0&&e<0?a(0):t>0&&e>0&&o(0)}if(s===n){let e=1;(n>=Number.MAX_SAFE_INTEGER||s<=Number.MIN_SAFE_INTEGER)&&(e=Math.abs(.05*n)),a(n+e),t||o(s-e)}this.min=s,this.max=n}getTickLimit(){const t=this.options.ticks;let e,{maxTicksLimit:i,stepSize:s}=t;return s?(e=Math.ceil(this.max/s)-Math.floor(this.min/s)+1,e>1e3&&(console.warn(`scales.${this.id}.ticks.stepSize: ${s} would result generating up to ${e} ticks. Limiting to 1000.`),e=1e3)):(e=this.computeTickLimit(),i=i||11),i&&(e=Math.min(i,e)),e}computeTickLimit(){return Number.POSITIVE_INFINITY}buildTicks(){const t=this.options,e=t.ticks;let i=this.getTickLimit();i=Math.max(2,i);const s=function(t,e){const i=[],{bounds:s,step:n,min:o,max:a,precision:r,count:l,maxTicks:h,maxDigits:c,includeBounds:d}=t,u=n||1,f=h-1,{min:p,max:g}=e,m=!v(o),b=!v(a),x=!v(l),_=(g-p)/(c+1);let y,w,M,k,O=J((g-p)/f/u)*u;if(O<1e-14&&!m&&!b)return[{value:p},{value:g}];k=Math.ceil(g/O)-Math.floor(p/O),k>f&&(O=J(k*O/f/u)*u),v(r)||(y=Math.pow(10,r),O=Math.ceil(O*y)/y),"ticks"===s?(w=Math.floor(p/O)*O,M=Math.ceil(g/O)*O):(w=p,M=g),m&&b&&n&&function(t,e){const i=Math.round(t);return i-e<=t&&i+e>=t}((a-o)/n,O/1e3)?(k=Math.round(Math.min((a-o)/O,h)),O=(a-o)/k,w=o,M=a):x?(w=m?o:w,M=b?a:M,k=l-1,O=(M-w)/k):(k=(M-w)/O,k=et(k,Math.round(k),O/1e3)?Math.round(k):Math.ceil(k));const S=Math.max(ot(O),ot(w));y=Math.pow(10,v(r)?S:r),w=Math.round(w*y)/y,M=Math.round(M*y)/y;let P=0;for(m&&(d&&w!==o?(i.push({value:o}),w0?i:null;this._zero=!0}determineDataLimits(){const{min:t,max:e}=this.getMinMax(!0);this.min=k(t)?Math.max(0,t):null,this.max=k(e)?Math.max(0,e):null,this.options.beginAtZero&&(this._zero=!0),this.handleTickRangeOptions()}handleTickRangeOptions(){const{minDefined:t,maxDefined:e}=this.getUserBounds();let i=this.min,s=this.max;const n=e=>i=t?i:e,o=t=>s=e?s:t,a=(t,e)=>Math.pow(10,Math.floor(Z(t))+e);i===s&&(i<=0?(n(1),o(10)):(n(a(i,-1)),o(a(s,1)))),i<=0&&n(a(s,-1)),s<=0&&o(a(i,1)),this._zero&&this.min!==this._suggestedMin&&i===a(this.min,0)&&n(a(i,-1)),this.min=i,this.max=s}buildTicks(){const t=this.options,e=function(t,e){const i=Math.floor(Z(e.max)),s=Math.ceil(e.max/Math.pow(10,i)),n=[];let o=O(t.min,Math.pow(10,Math.floor(Z(e.min)))),a=Math.floor(Z(o)),r=Math.floor(o/Math.pow(10,a)),l=a<0?Math.pow(10,Math.abs(a)):1;do{n.push({value:o,major:yo(o)}),++r,10===r&&(r=1,++a,l=a>=0?1:l),o=Math.round(r*Math.pow(10,a)*l)/l}while(an?{start:e-i,end:e}:{start:e,end:e+i}}function ko(t,e,i,s,n){const o=Math.abs(Math.sin(i)),a=Math.abs(Math.cos(i));let r=0,l=0;s.starte.r&&(r=(s.end-e.r)/o,t.r=Math.max(t.r,e.r+r)),n.starte.b&&(l=(n.end-e.b)/a,t.b=Math.max(t.b,e.b+l))}function Oo(t){return 0===t||180===t?"center":t<180?"left":"right"}function So(t,e,i){return 90===i||270===i?t-=e/2:(i>270||i<90)&&(t-=e),t}function Po(t,e,i,s){const{ctx:n}=t;if(i)n.arc(t.xCenter,t.yCenter,e,0,$);else{let i=t.getPointPosition(0,e);n.moveTo(i.x,i.y);for(let o=1;o{const i=D(this.options.pointLabels.callback,[t,e],this);return i||0===i?i:""}).filter((t,e)=>this.chart.getDataVisibility(e))}fit(){const t=this.options;t.display&&t.pointLabels.display?function(t){const e={l:t.left+t._padding.left,r:t.right-t._padding.right,t:t.top+t._padding.top,b:t.bottom-t._padding.bottom},i=Object.assign({},e),s=[],n=[],o=t._pointLabels.length,a=t.options.pointLabels,r=a.centerPointLabels?H/o:0;for(let d=0;d=0&&t=0;n--){const e=s.setContext(t.getPointLabelContext(n)),o=ye(e.font),{x:a,y:r,textAlign:l,left:h,top:c,right:d,bottom:u}=t._pointLabelItems[n],{backdropColor:f}=e;if(!v(f)){const t=_e(e.backdropPadding);i.fillStyle=f,i.fillRect(h-t.left,c-t.top,d-h+t.width,u-c+t.height)}ce(i,t._pointLabels[n],a,r+o.lineHeight/2,o,{color:e.color,textAlign:l,textBaseline:"middle"})}}(this,n),s.display&&this.ticks.forEach((t,e)=>{0!==e&&(a=this.getDistanceFromCenterForValue(t.value),function(t,e,i,s){const n=t.ctx,o=e.circular,{color:a,lineWidth:r}=e;!o&&!s||!a||!r||i<0||(n.save(),n.strokeStyle=a,n.lineWidth=r,n.setLineDash(e.borderDash),n.lineDashOffset=e.borderDashOffset,n.beginPath(),Po(t,i,o,s),n.closePath(),n.stroke(),n.restore())}(this,s.setContext(this.getContext(e-1)),a,n))}),i.display){for(t.save(),o=n-1;o>=0;o--){const s=i.setContext(this.getPointLabelContext(o)),{color:n,lineWidth:l}=s;l&&n&&(t.lineWidth=l,t.strokeStyle=n,t.setLineDash(s.borderDash),t.lineDashOffset=s.borderDashOffset,a=this.getDistanceFromCenterForValue(e.ticks.reverse?this.min:this.max),r=this.getPointPosition(o,a),t.beginPath(),t.moveTo(this.xCenter,this.yCenter),t.lineTo(r.x,r.y),t.stroke())}t.restore()}}drawBorder(){}drawLabels(){const t=this.ctx,e=this.options,i=e.ticks;if(!i.display)return;const s=this.getIndexAngle(0);let n,o;t.save(),t.translate(this.xCenter,this.yCenter),t.rotate(s),t.textAlign="center",t.textBaseline="middle",this.ticks.forEach((s,a)=>{if(0===a&&!e.reverse)return;const r=i.setContext(this.getContext(a)),l=ye(r.font);if(n=this.getDistanceFromCenterForValue(this.ticks[a].value),r.showLabelBackdrop){t.font=l.string,o=t.measureText(s.label).width,t.fillStyle=r.backdropColor;const e=_e(r.backdropPadding);t.fillRect(-o/2-e.left,-n-l.size/2-e.top,o+e.width,l.size+e.height)}ce(t,s.label,0,-n,l,{color:r.color})}),t.restore()}drawTitle(){}}Do.id="radialLinear",Do.defaults={display:!0,animate:!0,position:"chartArea",angleLines:{display:!0,lineWidth:1,borderDash:[],borderDashOffset:0},grid:{circular:!1},startAngle:0,ticks:{showLabelBackdrop:!0,callback:Is.formatters.numeric},pointLabels:{backdropColor:void 0,backdropPadding:2,display:!0,font:{size:10},callback:t=>t,padding:5,centerPointLabels:!1}},Do.defaultRoutes={"angleLines.color":"borderColor","pointLabels.color":"color","ticks.color":"color"},Do.descriptors={angleLines:{_fallback:"grid"}};const Eo={millisecond:{common:!0,size:1,steps:1e3},second:{common:!0,size:1e3,steps:60},minute:{common:!0,size:6e4,steps:60},hour:{common:!0,size:36e5,steps:24},day:{common:!0,size:864e5,steps:30},week:{common:!1,size:6048e5,steps:4},month:{common:!0,size:2628e6,steps:12},quarter:{common:!1,size:7884e6,steps:4},year:{common:!0,size:3154e7}},Co=Object.keys(Eo);function Ao(t,e){return t-e}function To(t,e){if(v(e))return null;const i=t._adapter,{parser:s,round:n,isoWeekday:o}=t._parseOpts;let a=e;return"function"==typeof s&&(a=s(a)),k(a)||(a="string"==typeof s?i.parse(a,s):i.parse(a)),null===a?null:(n&&(a="week"!==n||!tt(o)&&!0!==o?i.startOf(a,n):i.startOf(a,"isoWeek",o)),+a)}function Ro(t,e,i,s){const n=Co.length;for(let o=Co.indexOf(t);o=e?i[s]:i[n]]=!0}}else t[e]=!0}function jo(t,e,i){const s=[],n={},o=e.length;let a,r;for(a=0;a=0&&(e[l].major=!0);return e}(t,s,n,i):s}class Io extends $s{constructor(t){super(t),this._cache={data:[],labels:[],all:[]},this._unit="day",this._majorUnit=void 0,this._offsets={},this._normalized=!1,this._parseOpts=void 0}init(t,e){const i=t.time||(t.time={}),s=this._adapter=new Qi._date(t.adapters.date);j(i.displayFormats,s.formats()),this._parseOpts={parser:i.parser,round:i.round,isoWeekday:i.isoWeekday},super.init(t),this._normalized=e.normalized}parse(t,e){return void 0===t?null:To(this,t)}beforeLayout(){super.beforeLayout(),this._cache={data:[],labels:[],all:[]}}determineDataLimits(){const t=this.options,e=this._adapter,i=t.time.unit||"day";let{min:s,max:n,minDefined:o,maxDefined:a}=this.getUserBounds();function r(t){o||isNaN(t.min)||(s=Math.min(s,t.min)),a||isNaN(t.max)||(n=Math.max(n,t.max))}o&&a||(r(this._getLabelBounds()),"ticks"===t.bounds&&"labels"===t.ticks.source||r(this.getMinMax(!1))),s=k(s)&&!isNaN(s)?s:+e.startOf(Date.now(),i),n=k(n)&&!isNaN(n)?n:+e.endOf(Date.now(),i)+1,this.min=Math.min(s,n-1),this.max=Math.max(s+1,n)}_getLabelBounds(){const t=this.getLabelTimestamps();let e=Number.POSITIVE_INFINITY,i=Number.NEGATIVE_INFINITY;return t.length&&(e=t[0],i=t[t.length-1]),{min:e,max:i}}buildTicks(){const t=this.options,e=t.time,i=t.ticks,s="labels"===i.source?this.getLabelTimestamps():this._generate();"ticks"===t.bounds&&s.length&&(this.min=this._userMin||s[0],this.max=this._userMax||s[s.length-1]);const n=this.min,o=function(t,e,i){let s=0,n=t.length;for(;ss&&t[n-1]>i;)n--;return s>0||n=Co.indexOf(i);o--){const i=Co[o];if(Eo[i].common&&t._adapter.diff(n,s,i)>=e-1)return i}return Co[i?Co.indexOf(i):0]}(this,o.length,e.minUnit,this.min,this.max)),this._majorUnit=i.major.enabled&&"year"!==this._unit?function(t){for(let e=Co.indexOf(t)+1,i=Co.length;e1e5*a)throw new Error(e+" and "+i+" are too far apart with stepSize of "+a+" "+o);const f="data"===s.ticks.source&&this.getDataTimestamps();for(c=u,d=0;ct-e).map(t=>+t)}getLabelForValue(t){const e=this._adapter,i=this.options.time;return i.tooltipFormat?e.format(t,i.tooltipFormat):e.format(t,i.displayFormats.datetime)}_tickFormatFunction(t,e,i,s){const n=this.options,o=n.time.displayFormats,a=this._unit,r=this._majorUnit,l=a&&o[a],h=r&&o[r],c=i[e],d=r&&h&&c&&c.major,u=this._adapter.format(t,s||(d?h:l)),f=n.ticks.callback;return f?D(f,[u,e,i],this):u}generateTickLabels(t){let e,i,s;for(e=0,i=t.length;e0?a:1}getDataTimestamps(){let t,e,i=this._cache.data||[];if(i.length)return i;const s=this.getMatchingVisibleMetas();if(this._normalized&&s.length)return this._cache.data=s[0].controller.getAllParsedValues(this);for(t=0,e=s.length;t=t[r].pos&&e<=t[l].pos&&({lo:r,hi:l}=ke(t,"pos",e)),({pos:s,time:o}=t[r]),({pos:n,time:a}=t[l])):(e>=t[r].time&&e<=t[l].time&&({lo:r,hi:l}=ke(t,"time",e)),({time:s,pos:o}=t[r]),({time:n,pos:a}=t[l]));const h=n-s;return h?o+(a-o)*(e-s)/h:o}Io.id="time",Io.defaults={bounds:"data",adapters:{},time:{parser:!1,unit:!1,round:!1,isoWeekday:!1,minUnit:"millisecond",displayFormats:{}},ticks:{source:"auto",major:{enabled:!1}}};class zo extends Io{constructor(t){super(t),this._table=[],this._minPos=void 0,this._tableRange=void 0}initOffsets(){const t=this._getTimestampsForTable(),e=this._table=this.buildLookupTable(t);this._minPos=Fo(e,this.min),this._tableRange=Fo(e,this.max)-this._minPos,super.initOffsets(t)}buildLookupTable(t){const{min:e,max:i}=this,s=[],n=[];let o,a,r,l,h;for(o=0,a=t.length;o=e&&l<=i&&s.push(l);if(s.length<2)return[{time:e,pos:0},{time:i,pos:1}];for(o=0,a=s.length;o2&&void 0!==arguments[2]?arguments[2]:"label";const s=[];t.datasets=e.map(e=>{const n=t.datasets.find(t=>t[i]===e[i]);return n&&e.data&&!s.includes(n)?(s.push(n),Object.assign(n,e),n):{...e}})}function $o(t){let e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"label";const i={labels:[],datasets:[]};return Wo(i,t.labels),Ho(i,t.datasets,e),i}function Yo(t,e){let{height:i=150,width:s=300,redraw:n=!1,datasetIdKey:o,type:a,data:r,options:l,plugins:h=[],fallbackContent:c,...d}=t;const u=Object(Vo.useRef)(null),f=Object(Vo.useRef)(),p=()=>{u.current&&(f.current=new bn(u.current,{type:a,data:$o(r,o),options:l,plugins:h}),No(e,f.current))},g=()=>{No(e,null),f.current&&(f.current.destroy(),f.current=null)};return Object(Vo.useEffect)(()=>{var t,e;!n&&f.current&&l&&(t=f.current,e=l,t.options={...e})},[n,l]),Object(Vo.useEffect)(()=>{!n&&f.current&&Wo(f.current.config.data,r.labels)},[n,r.labels]),Object(Vo.useEffect)(()=>{!n&&f.current&&r.datasets&&Ho(f.current.config.data,r.datasets,o)},[n,r.datasets]),Object(Vo.useEffect)(()=>{f.current&&(n?(g(),setTimeout(p)):f.current.update())},[n,l,r.labels,r.datasets]),Object(Vo.useEffect)(()=>(p(),()=>g()),[]),Bo.a.createElement("canvas",Object.assign({ref:u,role:"img",height:i,width:s},d),c)}const Uo=Object(Vo.forwardRef)(Yo);function Xo(t,e){return bn.register(e),Object(Vo.forwardRef)((e,i)=>Bo.a.createElement(Uo,Object.assign({},e,{ref:i,type:t})))}const qo=Xo("line",Yi);var Ko=i(2),Go=i(24),Zo={id:"chartBorder",beforeDraw:function(t,e,i){var s=t.ctx,n=t.chartArea,o=n.left,a=n.top,r=n.width,l=n.height;s.save(),s.strokeStyle=i.borderColor||"#ccc",s.lineWidth=i.borderWidth||1,s.strokeRect(o,a,r,l),s.restore()}},Qo=i(8);function Jo(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);e&&(s=s.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),i.push.apply(i,s)}return i}function ta(t){for(var e=1;ewebhooks to be properly configured to populate correctly.","simple-pay"),{url:Object(o.createElement)("a",{href:fa})})),Object(o.createElement)(a.Flex,null,Object(o.createElement)(a.Button,{variant:"link",onClick:function(){return e(!1)}},Object(Ko.__)("Close","simple-pay")),Object(o.createElement)(a.Button,{variant:"primary",isPrimary:!0,href:"https://dashboard.stripe.com/reports/hub",target:"_blank"},Object(Ko.__)("View advanced reports in Stripe →","simple-pay"))))},ma=simpayAdminDashboardWidgetReport.currencies,ba=function(t){var e=t.report,i=t.currency,s=t.setCurrency,r=t.range,l=t.setRange,h=e||{},c=h.total,d=h.delta,u=Object(o.useState)(!1),f=n()(u,2),p=f[0],g=f[1],m=ha()("simpay-admin-dashboard-widget-report__badge",{"is-positive":d>0,"is-negative":d<0});return Object(o.createElement)("div",{className:"simpay-admin-dashboard-widget-report__data-filter"},Object(o.createElement)("div",{className:"simpay-admin-dashboard-widget-report__data-filter-title"},Object(o.createElement)("span",null,Object(Ko.__)("Payments by form","simple-pay")),p&&Object(o.createElement)(ga,{setIsOpen:g}),c>0&&d>0&&Object(o.createElement)(a.Tooltip,{text:Object(Ko.__)("Change since previous period","simple-pay"),position:"top center"},Object(o.createElement)("div",{className:m},Object(o.createElement)(o.Fragment,null,d<0?"–":"",d||"0","%"))),Object(o.createElement)(a.Button,{isLink:!0,variant:"link",onClick:function(){return g(!0)}},Object(o.createElement)(ca.a,{size:20,icon:da.a}))),Object(o.createElement)("div",{className:"simpay-admin-dashboard-widget-report__data-filter-controls"},Object(o.createElement)(a.SelectControl,{label:Object(Ko.__)("Currency","simple-pay"),hideLabelFromVision:!0,value:i,onChange:s,options:ma.map((function(t){return{label:t,value:t.toLowerCase()}}))}),Object(o.createElement)(a.SelectControl,{label:Object(Ko.__)("Range","simple-pay"),hideLabelFromVision:!0,value:r,onChange:l,options:[{label:"Last 7 days",value:"last7"},{label:"Last 30 days",value:"last30"}]})))},xa=i(17),_a=i.n(xa),ya=function(t){var e=t.id,i=t.title,s=t.total_formatted,n=Object(r.addQueryArgs)("post.php",{post:e,action:"edit"});return Object(o.createElement)(a.Flex,{justify:"space-between",key:i},Object(o.createElement)(a.Flex,{justify:"flex-start"},Object(o.createElement)("span",null,i?Object(o.createElement)("a",{href:n,target:"_blank",rel:"noreferrer"},i):Object(Ko.sprintf)( +Object(Ko.__)("No %s transactions for selected period.","simple-pay"),x.code.toUpperCase())),Object(o.createElement)("div",null,Object(Ko.__)("Please select a different currency, period, or check back later.","simple-pay")))),Object(o.createElement)(qo,{ref:l,options:m,plugins:[Zo,ia],data:{datasets:f}}),Object(o.createElement)(na,{chartRef:l,chart:r.chart}),Object(o.createElement)(sa,d))},la=i(13),ha=i.n(la),ca=i(35),da=i(55),ua=simpayAdminDashboardWidgetReport,fa=ua.webhooks_url,pa=ua.license,ga=function(t){var e=t.setIsOpen;return Object(o.createElement)(a.Modal,{title:Object(Ko.__)("Gross Volume","simple-pay"),onRequestClose:function(){return e(!1)},style:{maxWidth:"420px"}},Object(o.createElement)("p",{style:{marginBottom:"2rem"}},Object(Ko.__)("Estimated gross amounts for transactions in the selected currency and time period. Amounts do not represent verified financial data.","simple-pay")),!1===pa.is_lite&&Object(o.createElement)("p",{style:{marginBottom:"2rem"}},Object(o.createInterpolateElement)(Object(Ko.__)("Transaction data requires webhooks to be properly configured to populate correctly.","simple-pay"),{url:Object(o.createElement)("a",{href:fa})})),Object(o.createElement)(a.Flex,null,Object(o.createElement)(a.Button,{variant:"link",onClick:function(){return e(!1)}},Object(Ko.__)("Close","simple-pay")),Object(o.createElement)(a.Button,{variant:"primary",isPrimary:!0,href:"https://dashboard.stripe.com/reports/hub",target:"_blank"},Object(Ko.__)("View advanced reports in Stripe →","simple-pay"))))},ma=simpayAdminDashboardWidgetReport.currencies,ba=function(t){var e=t.report,i=t.currency,s=t.setCurrency,r=t.range,l=t.setRange,h=e||{},c=h.total,d=h.delta,u=Object(o.useState)(!1),f=n()(u,2),p=f[0],g=f[1],m=ha()("simpay-admin-dashboard-widget-report__badge",{"is-positive":d>0,"is-negative":d<0});return Object(o.createElement)("div",{className:"simpay-admin-dashboard-widget-report__data-filter"},Object(o.createElement)("div",{className:"simpay-admin-dashboard-widget-report__data-filter-title"},Object(o.createElement)("span",null,Object(Ko.__)("Payments by form","simple-pay")),p&&Object(o.createElement)(ga,{setIsOpen:g}),c>0&&d>0&&Object(o.createElement)(a.Tooltip,{text:Object(Ko.__)("Change since previous period","simple-pay"),position:"top center"},Object(o.createElement)("div",{className:m},Object(o.createElement)(o.Fragment,null,d<0?"–":"",d||"0","%"))),Object(o.createElement)(a.Button,{isLink:!0,variant:"link",onClick:function(){return g(!0)}},Object(o.createElement)(ca.a,{size:20,icon:da.a}))),Object(o.createElement)("div",{className:"simpay-admin-dashboard-widget-report__data-filter-controls"},Object(o.createElement)(a.SelectControl,{label:Object(Ko.__)("Currency","simple-pay"),hideLabelFromVision:!0,value:i,onChange:s,options:ma.map((function(t){return{label:t,value:t.toLowerCase()}}))}),Object(o.createElement)(a.SelectControl,{label:Object(Ko.__)("Range","simple-pay"),hideLabelFromVision:!0,value:r,onChange:l,options:[{label:"Last 7 days",value:"last7"},{label:"Last 30 days",value:"last30"}]})))},xa=i(17),_a=i.n(xa),ya=function(t){var e=t.id,i=t.title,s=t.total_formatted,n=Object(r.addQueryArgs)("post.php",{post:e,action:"edit"});return Object(o.createElement)(a.Flex,{justify:"space-between",key:i},Object(o.createElement)(a.Flex,{justify:"flex-start"},Object(o.createElement)("span",null,i?Object(o.createElement)("a",{href:n,target:"_blank",rel:"noreferrer"},i):Object(Ko.sprintf)( /* translators: %d Form ID. */ Object(Ko.__)("Payment form %d (deleted)","simple-pay"),e))),Object(o.createElement)(a.Flex,{gap:2,justify:"flex-end"},Object(o.createElement)("strong",null,Object(Go.decodeEntities)(s))))},va=function(t){var e=t.report;if(!e)return null;var i=e.forms,s=i.top,n=i.remaining;return Object(o.createElement)("div",{className:"simpay-admin-dashboard-widget-report__data-list"},s.map((function(t){return Object(o.createElement)(ya,_a()({key:t.id},t))})),n.count>0&&Object(o.createElement)(a.Flex,{justify:"space-between"},Object(o.createElement)(a.Flex,{justify:"flex-start"},Object(Ko.sprintf)( /* translators: %d The number of forms included in results that are not shown. */ diff --git a/includes/core/assets/js/simpay-admin-form-template-explorer-css.min.asset.php b/includes/core/assets/js/simpay-admin-form-template-explorer-css.min.asset.php index ef302512..9f9a9384 100644 --- a/includes/core/assets/js/simpay-admin-form-template-explorer-css.min.asset.php +++ b/includes/core/assets/js/simpay-admin-form-template-explorer-css.min.asset.php @@ -1 +1 @@ - array(), 'version' => '4390af3ca7ae6f65a169b77e26a0bc56'); \ No newline at end of file + array(), 'version' => '174cdaef21be2285c90ed9c984cdd203'); \ No newline at end of file diff --git a/includes/core/assets/js/simpay-admin-form-template-explorer.min.asset.php b/includes/core/assets/js/simpay-admin-form-template-explorer.min.asset.php index 8658d552..ea5521d0 100644 --- a/includes/core/assets/js/simpay-admin-form-template-explorer.min.asset.php +++ b/includes/core/assets/js/simpay-admin-form-template-explorer.min.asset.php @@ -1 +1 @@ - array('lodash', 'wp-a11y', 'wp-components', 'wp-compose', 'wp-element', 'wp-i18n', 'wp-primitives', 'wp-url'), 'version' => 'af06376d3e61765e12302a38f4e0e63d'); \ No newline at end of file + array('lodash', 'wp-a11y', 'wp-components', 'wp-compose', 'wp-element', 'wp-i18n', 'wp-primitives', 'wp-url'), 'version' => 'dcc6a17448ebc9297aa7baee34aa056a'); \ No newline at end of file diff --git a/includes/core/assets/js/simpay-admin-form-template-explorer.min.js b/includes/core/assets/js/simpay-admin-form-template-explorer.min.js index df4ac231..8fbdffb6 100644 --- a/includes/core/assets/js/simpay-admin-form-template-explorer.min.js +++ b/includes/core/assets/js/simpay-admin-form-template-explorer.min.js @@ -1,7 +1,7 @@ -!function(e){var t={};function r(n){if(t[n])return t[n].exports;var a=t[n]={i:n,l:!1,exports:{}};return e[n].call(a.exports,a,a.exports,r),a.l=!0,a.exports}r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var a in e)r.d(n,a,function(t){return e[t]}.bind(null,a));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=69)}([function(e,t){e.exports=window.wp.element},,function(e,t){e.exports=window.wp.i18n},function(e,t){e.exports=window.wp.components},,function(e,t,r){var n=r(20),a=r(21),o=r(16),c=r(22);e.exports=function(e,t){return n(e)||a(e,t)||o(e,t)||c()},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){e.exports=window.wp.primitives},function(e,t){e.exports=window.wp.url},function(e,t){e.exports=window.lodash},,,function(e,t){e.exports=window.wp.compose},,function(e,t){e.exports=function(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,r){var n;!function(){"use strict";var r={}.hasOwnProperty;function a(){for(var e=[],t=0;te.length)&&(t=e.length);for(var r=0,n=new Array(t);rbasic form. Have a suggestion for a new template? We'd love to hear it!","simple-pay"),{blank:Object(l.createElement)("a",{href:O}),suggest:Object(l.createElement)("a",{href:f,target:"_blank",rel:"noopener noreferrer"})})))},v=r(14),_=r.n(v),h=r(11),E=r(56),x=r(35),w=r(57),C=function e(t){var r=t.className,n=t.onChange,a=t.value,o=t.label,c=t.placeholder,u=void 0===c?Object(s.__)("Search"):c,p=t.hideLabelFromVision,m=void 0===p||p,f=t.help,d=Object(h.useInstanceId)(e),b=Object(l.useRef)(),g="components-search-control-".concat(d);return Object(l.createElement)(i.BaseControl,{label:o,id:g,hideLabelFromVision:m,help:f,className:_()(r,"components-search-control")},Object(l.createElement)("div",{className:"components-search-control__input-wrapper"},Object(l.createElement)("input",{ref:b,className:"components-search-control__input",id:g,type:"search",placeholder:u,onChange:function(e){return n(e.target.value)},autoComplete:"off",value:a||""}),Object(l.createElement)("div",{className:"components-search-control__icon"},!!a&&Object(l.createElement)(i.Button,{icon:E.a,label:Object(s.__)("Reset search","simple-pay"),onClick:function(){n(""),b.current.focus()}}),!a&&Object(l.createElement)(x.a,{icon:w.a}))))},S="simpay-form-template-explorer-main__sidebar";function P(e){var t=e.selectedCategory,r=e.templateCategories,n=e.onClickCategory;return Object(l.createElement)(i.NavigableMenu,{orientation:"vertical",className:"".concat(S,"-categories")},Object.keys(r).sort().map((function(e){return Object(l.createElement)(i.Button,{key:e,label:r[e],className:"".concat(S,"-categories_category"),isPressed:t===e,onClick:function(){n(e)}},r[e])})))}function k(e){var t=e.filterValue,r=e.setFilterValue;return Object(l.createElement)("div",{className:"".concat(S,"-search")},Object(l.createElement)(C,{onChange:r,value:t,label:Object(s.__)("Search for templates","simple-pay"),placeholder:Object(s.__)("Search","simple-pay")}))}var N=function(e){var t=e.selectedCategory,r=e.templateCategories,n=e.onClickCategory,a=e.filterValue,o=e.setFilterValue;return Object(l.createElement)("div",{className:S},Object(l.createElement)(k,{filterValue:a,setFilterValue:o}),!a&&Object(l.createElement)(P,{selectedCategory:t,templateCategories:r,onClickCategory:n}))},M=r(30),V=r(6),L=Object(l.createElement)(V.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(l.createElement)(V.Path,{d:"M8 5C8 3.34315 9.34315 2 11 2H13C14.6569 2 16 3.34315 16 5V9H18C19.2624 9 20 9.9804 20 11V19C20 20.0196 19.2624 21 18 21H6C4.73763 21 4 20.0196 4 19V11C4 9.9804 4.73763 9 6 9H8V5ZM9.5 9H14.5V5C14.5 4.17157 13.8284 3.5 13 3.5H11C10.1716 3.5 9.5 4.17157 9.5 5V9Z"})),B=r(54),A=simpayFormBuilderTemplateExplorer,I=A.alreadyPurchasedUrl,U=A.licenseLevel,F=A.upgradeUrl,T="simpay-form-template-explorer-upgrade",H=function(e){var t=e.template,r=e.setIsShowingUpgradeModal;return Object(l.createElement)(i.Modal,{title:Object(s.__)("Upgrade Required","simple-pay"),onRequestClose:function(){return r(!1)},className:T},Object(l.createElement)("div",{className:"".concat(T,"__content")},Object(l.createElement)(x.a,{icon:L,size:"48px"}),Object(l.createElement)("h3",{className:"".concat(T,"__title")},Object(s.sprintf)( +!function(e){var t={};function r(n){if(t[n])return t[n].exports;var a=t[n]={i:n,l:!1,exports:{}};return e[n].call(a.exports,a,a.exports,r),a.l=!0,a.exports}r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var a in e)r.d(n,a,function(t){return e[t]}.bind(null,a));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=69)}([function(e,t){e.exports=window.wp.element},,function(e,t){e.exports=window.wp.i18n},function(e,t){e.exports=window.wp.components},,function(e,t,r){var n=r(20),a=r(21),o=r(16),l=r(22);e.exports=function(e,t){return n(e)||a(e,t)||o(e,t)||l()},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){e.exports=window.wp.primitives},function(e,t){e.exports=window.wp.url},function(e,t){e.exports=window.lodash},,,function(e,t){e.exports=window.wp.compose},,function(e,t,r){var n;!function(){"use strict";var r={}.hasOwnProperty;function a(){for(var e=[],t=0;te.length)&&(t=e.length);for(var r=0,n=new Array(t);rbasic form. Have a suggestion for a new template? We'd love to hear it!","simple-pay"),{blank:Object(o.createElement)("a",{href:b}),suggest:Object(o.createElement)("a",{href:p,target:"_blank",rel:"noopener noreferrer"})})))},O=r(13),_=r.n(O),v=r(11),h=r(56),E=r(35),x=r(57),w=function e(t){var r=t.className,n=t.onChange,a=t.value,c=t.label,s=t.placeholder,u=void 0===s?Object(i.__)("Search"):s,p=t.hideLabelFromVision,m=void 0===p||p,d=t.help,f=Object(v.useInstanceId)(e),b=Object(o.useRef)(),g="components-search-control-".concat(f);return Object(o.createElement)(l.BaseControl,{label:c,id:g,hideLabelFromVision:m,help:d,className:_()(r,"components-search-control")},Object(o.createElement)("div",{className:"components-search-control__input-wrapper"},Object(o.createElement)("input",{ref:b,className:"components-search-control__input",id:g,type:"search",placeholder:u,onChange:function(e){return n(e.target.value)},autoComplete:"off",value:a||""}),Object(o.createElement)("div",{className:"components-search-control__icon"},!!a&&Object(o.createElement)(l.Button,{icon:h.a,label:Object(i.__)("Reset search","simple-pay"),onClick:function(){n(""),b.current.focus()}}),!a&&Object(o.createElement)(E.a,{icon:x.a}))))},C="simpay-form-template-explorer-main__sidebar";function S(e){var t=e.selectedCategory,r=e.templateCategories,n=e.onClickCategory;return Object(o.createElement)(l.NavigableMenu,{orientation:"vertical",className:"".concat(C,"-categories")},Object.keys(r).map((function(e){var a=_()("category-".concat(e),"".concat(C,"-categories_category"));return Object(o.createElement)(l.Button,{key:e,label:r[e],className:a,isPressed:t===e,onClick:function(){n(e)}},r[e])})))}function k(e){var t=e.filterValue,r=e.setFilterValue;return Object(o.createElement)("div",{className:"".concat(C,"-search")},Object(o.createElement)(w,{onChange:r,value:t,label:Object(i.__)("Search for templates","simple-pay"),placeholder:Object(i.__)("Search","simple-pay")}))}var N=function(e){var t=e.selectedCategory,r=e.templateCategories,n=e.onClickCategory,a=e.filterValue,l=e.setFilterValue;return Object(o.createElement)("div",{className:C},Object(o.createElement)(k,{filterValue:a,setFilterValue:l}),!a&&Object(o.createElement)(S,{selectedCategory:t,templateCategories:r,onClickCategory:n}))},M=r(30),P=r(6),V=Object(o.createElement)(P.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(o.createElement)(P.Path,{d:"M8 5C8 3.34315 9.34315 2 11 2H13C14.6569 2 16 3.34315 16 5V9H18C19.2624 9 20 9.9804 20 11V19C20 20.0196 19.2624 21 18 21H6C4.73763 21 4 20.0196 4 19V11C4 9.9804 4.73763 9 6 9H8V5ZM9.5 9H14.5V5C14.5 4.17157 13.8284 3.5 13 3.5H11C10.1716 3.5 9.5 4.17157 9.5 5V9Z"})),L=r(54),B=simpayFormBuilderTemplateExplorer,A=B.alreadyPurchasedUrl,U=B.licenseLevel,F=B.upgradeUrl,I="simpay-form-template-explorer-upgrade",T=function(e){var t=e.template,r=e.setIsShowingUpgradeModal;return Object(o.createElement)(l.Modal,{title:Object(i.__)("Upgrade Required","simple-pay"),onRequestClose:function(){return r(!1)},className:I},Object(o.createElement)("div",{className:"".concat(I,"__content")},Object(o.createElement)(E.a,{icon:V,size:"48px"}),Object(o.createElement)("h3",{className:"".concat(I,"__title")},Object(i.sprintf)( /* translators: %s Template name */ -Object(s.__)('Unlock the "%s" Template',"simple-pay"),t.name)),Object(l.createElement)("p",{className:"".concat(T,"__description")},Object(l.createInterpolateElement)(Object(s.sprintf)( +Object(i.__)('Unlock the "%s" Template',"simple-pay"),t.name)),Object(o.createElement)("p",{className:"".concat(I,"__description")},Object(o.createInterpolateElement)(Object(i.sprintf)( /* translators: %$ss Template name. %2$s Minimum license level. */ -Object(s.__)('We\'re sorry, the "%1$s" template is not available on your plan. Please upgrade to the %2$s plan or higher to unlock this and other awesome features.',"simple-pay"),t.name,Object(u.upperFirst)(t.license[0])),{strong:Object(l.createElement)("strong",null)})),Object(l.createElement)(i.Button,{isPrimary:!0,variant:"primary",href:Object(p.addQueryArgs)(F,{utm_content:t.name}),target:"_blank",rel:"noopener noreferrer"},"lite"===U?Object(s.__)("Upgrade to Pro","simple-pay"):Object(s.__)("See Upgrade Options","simple-pay")),Object(l.createElement)("a",{href:I,target:"_blank",rel:"noopener noreferrer",className:"".concat(T,"__purchased")},Object(s.__)("Already purchased?","simple-pay")),Object(l.createElement)("p",{className:"".concat(T,"__discount")},Object(l.createElement)(x.a,{icon:B.a}),"lite"===U?Object(l.createInterpolateElement)(Object(s.__)("Bonus: WP Simple Pay Lite users get 50% off regular price, automatically applied at checkout. Upgrade to Pro →","simple-pay"),{strong:Object(l.createElement)("strong",null),highlight:Object(l.createElement)("u",null),upgrade:Object(l.createElement)("a",{href:Object(p.addQueryArgs)(F,{utm_content:t.name}),target:"_blank",rel:"noopener noreferrer"})}):Object(l.createInterpolateElement)(Object(s.__)("Bonus: WP Simple Pay Pro users get 50% off upgrade pricing, automatically applied at checkout. See Upgrade Options →","simple-pay"),{strong:Object(l.createElement)("strong",null),highlight:Object(l.createElement)("u",null),upgrade:Object(l.createElement)("a",{href:Object(p.addQueryArgs)(F,{utm_content:t.name}),target:"_blank",rel:"noopener noreferrer"})}))))},W=simpayFormBuilderTemplateExplorer,z=W.licenseLevel,D=W.addNewUrl,G=W.isLite,Q="simpay-form-template-explorer-main__content",R=["payment-button","donate-button","payment-form","product-installment-plan-form","product-purchse-form","product-subscription-form","product-subscription-form-coupon","recurring-service-setup-fee-form","recurring-service-trial-period-form","recurring-services-form"],Z=function(e){var t=e.template,r=Object(l.useState)(!1),n=a()(r,2),o=n[0],c=n[1],u=!t.license.includes(z),m=Object(p.addQueryArgs)(D,{"simpay-template":t.id}),f=Object(p.addQueryArgs)("https://wpsimplepay.com/templates/".concat(t.slug,"/"),{utm_source:"WordPress",utm_campaign:"1"===G?"lite-plugin":"pro-plugin",utm_medium:"template-explorer",utm_content:t.name});return Object(l.createElement)(l.Fragment,null,o&&Object(l.createElement)(H,{template:t,setIsShowingUpgradeModal:c}),Object(l.createElement)("div",{key:t.id,className:"".concat(Q,"-list-item")},u&&Object(l.createElement)("div",{className:"".concat(Q,"-list-item__badge")},Object(l.createElement)(x.a,{icon:L,size:"16px"})),Object(l.createElement)("div",{id:t.id,className:"".concat(Q,"-list-item__name ").concat(u?"".concat(Q,"-list-item__name--is-locked"):"")},t.name),Object(l.createElement)("div",{className:"".concat(Q,"-list-item__description")},t.description),Object(l.createElement)("div",{className:"".concat(Q,"-list-item__actions")},Object(l.createElement)(i.Button,{isPrimary:!0,variant:"primary",href:u?void 0:m,onClick:function(){return u?c(!0):null}},"lite"===z&&"payment-button"===t.slug?Object(s.__)("Create Payment Button","simple-pay"):Object(s.__)("Use Template","simple-pay")),!R.includes(t.slug)&&Object(l.createElement)(i.Button,{isSecondary:!0,variant:"secondary",href:f,style:{marginLeft:"10px"}},Object(s.__)("View Demo","simple-pay")))))},q=Object(l.createElement)(V.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(l.createElement)(V.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M6.68822 16.625L5.5 17.8145L5.5 5.5L18.5 5.5L18.5 16.625L6.68822 16.625ZM7.31 18.125L19 18.125C19.5523 18.125 20 17.6773 20 17.125L20 5C20 4.44772 19.5523 4 19 4H5C4.44772 4 4 4.44772 4 5V19.5247C4 19.8173 4.16123 20.086 4.41935 20.2237C4.72711 20.3878 5.10601 20.3313 5.35252 20.0845L7.31 18.125ZM16 9.99997H8V8.49997H16V9.99997ZM8 14H13V12.5H8V14Z"})),$=simpayFormBuilderTemplateExplorer.suggestUrl,K=function(){return Object(l.createElement)("div",{className:"".concat("simpay-form-template-explorer-main__content","-suggest")},Object(l.createElement)("div",{style:{flexGrow:0}},Object(l.createElement)(x.a,{icon:q,size:"42px"})),Object(l.createElement)("div",null,Object(l.createElement)("h4",null,Object(s.__)("We need your help!","simple-pay")),Object(l.createElement)("p",null,Object(l.createInterpolateElement)(Object(s.__)("We're constantly building more pre-made payment form templates to get you up and running even faster. If you have ideas for future templates, please let us know!","simple-pay"),{suggest:Object(l.createElement)("a",{href:$,target:"_blank",rel:"noopener noreferrer"})})),Object(l.createElement)(i.Button,{isSecondary:!0,variant:"secondary",isLink:!0,href:$,target:"_blank"},Object(s.__)("Suggest a Template","simple-pay"))))},J=r(19),X=r.n(J),Y=function(e){return e.name||""},ee=function(e){return e.description||""},te=function(e){return e.keywords||[]},re=function(e){return e.category};function ne(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return(e=(e=Object(u.deburr)(e)).replace(/^\//,"")).toLowerCase()}var ae=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return Object(u.words)(ne(e))},oe=function(e,t){return Object(u.differenceWith)(e,ae(t),(function(e,t){return t.includes(e)}))};function ce(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},n=r.getName,a=void 0===n?Y:n,o=r.getDescription,c=void 0===o?ee:o,l=r.getKeywords,i=void 0===l?te:l,s=r.getCategory,p=void 0===s?re:s,m=a(e),f=c(e),d=i(e),b=p(e),g=ne(t),O=ne(m),j=0;if(g===O)j+=30;else if(O.startsWith(g))j+=20;else{var y=[m,f].concat(X()(d),[b]).join(" "),v=Object(u.words)(g),_=oe(v,y);0===_.length&&(j+=10)}return j}var le=simpayFormBuilderTemplateExplorer,ie=le.suggestUrl,se=le.licenseLevel,ue=function(e){var t=e.filterValue,r=e.selectedCategory,n=e.templates,o=Object(h.useDebounce)(M.speak,500),c=Object(l.useMemo)((function(){var e=n;return t?e=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},n=ae(t);if(0===n.length)return e;var o=e.map((function(e){return[e,ce(e,t,r)]})).filter((function(e){return a()(e,2)[1]>0}));return o.sort((function(e,t){var r=a()(e,2)[1];return a()(t,2)[1]-r})),o.map((function(e){return a()(e,1)[0]}))}(n,t):""!==r&&(e=n.filter((function(e){var t=e.categories;return Object.keys(t).includes(r)}))),Object(u.sortBy)(e,(function(e){return!e.license.includes(se)}))}),[t,r,n]);Object(l.useEffect)((function(){if(t){var e=c.length,r=Object(s.sprintf)( +Object(i.__)('We\'re sorry, the "%1$s" template is not available on your plan. Please upgrade to the %2$s plan or higher to unlock this and other awesome features.',"simple-pay"),t.name,Object(c.upperFirst)(t.license[0])),{strong:Object(o.createElement)("strong",null)})),Object(o.createElement)(l.Button,{isPrimary:!0,variant:"primary",href:Object(s.addQueryArgs)(F,{utm_content:t.name}),target:"_blank",rel:"noopener noreferrer"},"lite"===U?Object(i.__)("Upgrade to Pro","simple-pay"):Object(i.__)("See Upgrade Options","simple-pay")),Object(o.createElement)("a",{href:A,target:"_blank",rel:"noopener noreferrer",className:"".concat(I,"__purchased")},Object(i.__)("Already purchased?","simple-pay")),Object(o.createElement)("p",{className:"".concat(I,"__discount")},Object(o.createElement)(E.a,{icon:L.a}),"lite"===U?Object(o.createInterpolateElement)(Object(i.__)("Bonus: WP Simple Pay Lite users get 50% off regular price, automatically applied at checkout. Upgrade to Pro →","simple-pay"),{strong:Object(o.createElement)("strong",null),highlight:Object(o.createElement)("u",null),upgrade:Object(o.createElement)("a",{href:Object(s.addQueryArgs)(F,{utm_content:t.name}),target:"_blank",rel:"noopener noreferrer"})}):Object(o.createInterpolateElement)(Object(i.__)("Bonus: WP Simple Pay Pro users get 50% off upgrade pricing, automatically applied at checkout. See Upgrade Options →","simple-pay"),{strong:Object(o.createElement)("strong",null),highlight:Object(o.createElement)("u",null),upgrade:Object(o.createElement)("a",{href:Object(s.addQueryArgs)(F,{utm_content:t.name}),target:"_blank",rel:"noopener noreferrer"})}))))},H=simpayFormBuilderTemplateExplorer,W=H.licenseLevel,z=H.addNewUrl,G=H.isLite,Q="simpay-form-template-explorer-main__content",R=["payment-button","donate-button","payment-form","product-installment-plan-form","product-purchse-form","product-subscription-form","product-subscription-form-coupon","recurring-service-setup-fee-form","recurring-service-trial-period-form","recurring-services-form"],Z=function(e){var t=e.template,r=Object(o.useState)(!1),n=a()(r,2),c=n[0],u=n[1],p=!t.license.includes(W),m=Object(s.addQueryArgs)(z,{"simpay-template":t.id}),d=Object(s.addQueryArgs)("https://wpsimplepay.com/templates/".concat(t.slug,"/"),{utm_source:"WordPress",utm_campaign:"1"===G?"lite-plugin":"pro-plugin",utm_medium:"template-explorer",utm_content:t.name});return Object(o.createElement)(o.Fragment,null,c&&Object(o.createElement)(T,{template:t,setIsShowingUpgradeModal:u}),Object(o.createElement)("div",{key:t.id,className:"".concat(Q,"-list-item")},p&&Object(o.createElement)("div",{className:"".concat(Q,"-list-item__badge")},Object(o.createElement)(E.a,{icon:V,size:"16px"})),Object(o.createElement)("div",{id:t.id,className:"".concat(Q,"-list-item__name ").concat(p?"".concat(Q,"-list-item__name--is-locked"):"")},t.name),Object(o.createElement)("div",{className:"".concat(Q,"-list-item__description")},t.description),Object(o.createElement)("div",{className:"".concat(Q,"-list-item__actions")},Object(o.createElement)(l.Button,{isPrimary:!0,variant:"primary",href:p?void 0:m,onClick:function(){return p?u(!0):null}},"lite"===W&&"payment-button"===t.slug?Object(i.__)("Create Payment Button","simple-pay"):Object(i.__)("Use Template","simple-pay")),!R.includes(t.slug)&&Object(o.createElement)(l.Button,{isSecondary:!0,variant:"secondary",href:d,style:{marginLeft:"10px"},target:"_blank"},Object(i.__)("View Demo","simple-pay")))))},q=Object(o.createElement)(P.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(o.createElement)(P.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M6.68822 16.625L5.5 17.8145L5.5 5.5L18.5 5.5L18.5 16.625L6.68822 16.625ZM7.31 18.125L19 18.125C19.5523 18.125 20 17.6773 20 17.125L20 5C20 4.44772 19.5523 4 19 4H5C4.44772 4 4 4.44772 4 5V19.5247C4 19.8173 4.16123 20.086 4.41935 20.2237C4.72711 20.3878 5.10601 20.3313 5.35252 20.0845L7.31 18.125ZM16 9.99997H8V8.49997H16V9.99997ZM8 14H13V12.5H8V14Z"})),D=simpayFormBuilderTemplateExplorer.suggestUrl,$=function(){return Object(o.createElement)("div",{className:"".concat("simpay-form-template-explorer-main__content","-suggest")},Object(o.createElement)("div",{style:{flexGrow:0}},Object(o.createElement)(E.a,{icon:q,size:"42px"})),Object(o.createElement)("div",null,Object(o.createElement)("h4",null,Object(i.__)("We need your help!","simple-pay")),Object(o.createElement)("p",null,Object(o.createInterpolateElement)(Object(i.__)("We're constantly building more pre-made payment form templates to get you up and running even faster. If you have ideas for future templates, please let us know!","simple-pay"),{suggest:Object(o.createElement)("a",{href:D,target:"_blank",rel:"noopener noreferrer"})})),Object(o.createElement)(l.Button,{isSecondary:!0,variant:"secondary",isLink:!0,href:D,target:"_blank"},Object(i.__)("Suggest a Template","simple-pay"))))},K=simpayFormBuilderTemplateExplorer,J=K.isLite,X=K.upgradeUrl,Y=function(){return Object(o.createElement)("div",{className:"".concat("simpay-form-template-explorer-main__content","-upgrade")},Object(o.createElement)("div",null,Object(o.createElement)("h4",null,Object(i.__)("Get Access to All of Our Pre-Made Payment Form Templates","simple-pay")),Object(o.createElement)("p",null,Object(i.__)("Never start from scratch again! Upgrade to gain access to every payment form template we make and unlock powerful new features.","simple-pay"))),Object(o.createElement)(l.Button,{isSecondary:!0,variant:"primary",isLink:!0,size:"large",href:X,target:"_blank"},J?Object(i.__)("Upgrade to Pro","simple-pay"):Object(i.__)("Upgrade Now","simple-pay")))},ee=r(19),te=r.n(ee),re=function(e){return e.name||""},ne=function(e){return e.description||""},ae=function(e){return e.keywords||[]},oe=function(e){return e.category};function le(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return(e=(e=Object(c.deburr)(e)).replace(/^\//,"")).toLowerCase()}var ce=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return Object(c.words)(le(e))},ie=function(e,t){return Object(c.differenceWith)(e,ce(t),(function(e,t){return t.includes(e)}))};function se(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},n=r.getName,a=void 0===n?re:n,o=r.getDescription,l=void 0===o?ne:o,i=r.getKeywords,s=void 0===i?ae:i,u=r.getCategory,p=void 0===u?oe:u,m=a(e),d=l(e),f=s(e),b=p(e),g=le(t),y=le(m),j=0;if(g===y)j+=30;else if(y.startsWith(g))j+=20;else{var O=[m,d].concat(te()(f),[b]).join(" "),_=Object(c.words)(g),v=ie(_,O);0===v.length&&(j+=10)}return j}var ue=simpayFormBuilderTemplateExplorer,pe=ue.suggestUrl,me=ue.licenseLevel,de=function(e){var t=e.filterValue,r=e.selectedCategory,n=e.templates,l=Object(v.useDebounce)(M.speak,500),s=Object(o.useMemo)((function(){var e=n;return t?e=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},n=ce(t);if(0===n.length)return e;var o=e.map((function(e){return[e,se(e,t,r)]})).filter((function(e){return a()(e,2)[1]>0}));return o.sort((function(e,t){var r=a()(e,2)[1];return a()(t,2)[1]-r})),o.map((function(e){return a()(e,1)[0]}))}(n,t):""!==r&&(e=n.filter((function(e){return e.categories.includes(r)}))),Object(c.sortBy)(e,(function(e){return!e.license.includes(me)}))}),[t,r,n]);Object(o.useEffect)((function(){if(t){var e=s.length,r=Object(i.sprintf)( /* translators: %d: number of results. */ -Object(s._n)("%d result found.","%d results found.",e,"simple-pay"),e);o(r)}}),[t,o]);var i=!(null==c||!c.length),p=_()("simpay-form-template-explorer-main__content",{"is-empty":!i});return Object(l.createElement)("div",{className:p},!i&&Object(l.createElement)("p",null,Object(l.createInterpolateElement)(Object(s.__)("No results found. Have a suggestion for a new template? We'd love to hear it!","simple-pay"),{suggest:Object(l.createElement)("a",{href:ie,target:"_blank",rel:"noopener noreferrer"})})),i&&Object(l.createElement)(l.Fragment,null,c.map((function(e){return Object(l.createElement)(Z,{key:e.slug,template:e})})),Object(l.createElement)(K,null)))};function pe(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function me(e){for(var t=1;tWe'd love to hear it!","simple-pay"),{suggest:Object(o.createElement)("a",{href:pe,target:"_blank",rel:"noopener noreferrer"})})),u&&Object(o.createElement)(o.Fragment,null,s.map((function(e,r){var n=Object(o.createElement)(Z,{key:e.slug,template:e});return""===t&&["lite","personal","plus"].includes(me)&&5===r?Object(o.createElement)(o.Fragment,{key:"upgrade-frag"},n,Object(o.createElement)(Y,null)):n})),Object(o.createElement)($,null)))},fe=simpayFormBuilderTemplateExplorer,be=fe.hasNew,ge=fe.templates,ye=fe.categories;Object(o.render)(Object(o.createElement)((function(){var e=Object(o.useState)(""),t=a()(e,2),r=t[0],n=t[1],c=Object(o.useState)(be?"new":""),i=a()(c,2),s=i[0],u=i[1];return Object(o.useEffect)((function(){document.querySelector("body").classList.add("simpay-template-explorer-open")}),[]),Object(o.createElement)(l.SlotFillProvider,null,Object(o.createElement)("div",{className:"simpay-form-template-explorer"},Object(o.createElement)(j,null),Object(o.createElement)("div",{className:"".concat("simpay-form-template-explorer","-main")},Object(o.createElement)(N,{selectedCategory:s,templateCategories:ye,onClickCategory:u,filterValue:r,setFilterValue:function(e){n(e),u("")}}),Object(o.createElement)(de,{templates:ge,templateCategories:ye,selectedCategory:s,filterValue:r}))),Object(o.createElement)(l.Popover.Slot,null))}),null),document.getElementById("simpay-form-template-explorer"))}]); \ No newline at end of file diff --git a/includes/core/assets/js/simpay-admin-help.min.asset.php b/includes/core/assets/js/simpay-admin-help.min.asset.php index 1c9a39cc..38b4b22e 100644 --- a/includes/core/assets/js/simpay-admin-help.min.asset.php +++ b/includes/core/assets/js/simpay-admin-help.min.asset.php @@ -1 +1 @@ - array('lodash', 'wp-a11y', 'wp-components', 'wp-compose', 'wp-element', 'wp-i18n', 'wp-keycodes', 'wp-primitives', 'wp-url'), 'version' => '653c3df75d9c8b5cab79317eff139d23'); \ No newline at end of file + array('lodash', 'wp-a11y', 'wp-components', 'wp-compose', 'wp-element', 'wp-i18n', 'wp-keycodes', 'wp-primitives', 'wp-url'), 'version' => '74db5ba791842122a0a2853e7f699cae'); \ No newline at end of file diff --git a/includes/core/assets/js/simpay-admin-help.min.js b/includes/core/assets/js/simpay-admin-help.min.js index f2b06163..4c867840 100644 --- a/includes/core/assets/js/simpay-admin-help.min.js +++ b/includes/core/assets/js/simpay-admin-help.min.js @@ -1,3 +1,3 @@ -!function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)n.d(r,o,function(t){return e[t]}.bind(null,o));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=68)}([function(e,t){e.exports=window.wp.element},,function(e,t){e.exports=window.wp.i18n},function(e,t){e.exports=window.wp.components},,function(e,t,n){var r=n(20),o=n(21),c=n(16),a=n(22);e.exports=function(e,t){return r(e)||o(e,t)||c(e,t)||a()},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){e.exports=window.wp.primitives},function(e,t){e.exports=window.wp.url},function(e,t){e.exports=window.lodash},,,function(e,t){e.exports=window.wp.compose},,,function(e,t,n){var r;!function(){"use strict";var n={}.hasOwnProperty;function o(){for(var e=[],t=0;te.length)&&(t=e.length);for(var n=0,r=new Array(t);ne.length)&&(t=e.length);for(var n=0,r=new Array(t);n5&&Object(c.createElement)(a.Button,{variant:"secondary",isSecondary:!0,isSmall:!0,onClick:function(){return f(!0)}},Object(s.__)("View all","simple-pay"))))},R=simpayHelp,I=R.docs,G=R.docsCategories,D=function(){var e,t=Object(c.useState)("getting-started"),n=o()(t,2),r=n[0],a=n[1];return Object(c.createElement)("div",{className:"simpay-help-panel__categories"},(e=Object(V.groupBy)(I,"categories"),Object(V.map)(e,(function(e,t){return{slug:t,title:G[t]||"",docs:e}}))).map((function(e){return Object(c.createElement)(H,P()({key:e.slug,openCategory:r,setOpenCategory:a},e))})))},F=n(19),W=n.n(F);function U(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return(e=(e=Object(V.deburr)(e)).replace(/^\//,"")).toLowerCase()}var Z=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return Object(V.words)(U(e))};function $(e,t){var n,r,o=e.title||"",c=e.excerpt||"",a=e.categories||[],l=e.tags||[],i=U(t),s=U(o),u=0;if(i===s)u+=30;else if(s.startsWith(i))u+=20;else{var p=[o,c].concat(W()(a),W()(l)).join(" ");0===(n=Object(V.words)(i),r=p,Object(V.differenceWith)(n,Z(r),(function(e,t){return t.includes(e)}))).length&&(u+=10)}return u}var Q=simpayHelp.docs,K=function(e){var t=e.searchTerm,n=Object(c.useMemo)((function(){var e=[];return""!==t&&(e=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=Z(t);if(0===n.length)return e;var r=e.map((function(e){return[e,$(e,t)]})).filter((function(e){return o()(e,2)[1]>0}));return r.sort((function(e,t){var n=o()(e,2)[1];return o()(t,2)[1]-n})),r.map((function(e){return o()(e,1)[0]}))}(Q,t)),e}),[t]),r=Object(d.useDebounce)(k.speak,500);Object(c.useEffect)((function(){if(t){var e=n.length,o=Object(s.sprintf)( +!function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)n.d(r,o,function(t){return e[t]}.bind(null,o));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=68)}([function(e,t){e.exports=window.wp.element},,function(e,t){e.exports=window.wp.i18n},function(e,t){e.exports=window.wp.components},,function(e,t,n){var r=n(20),o=n(21),c=n(16),a=n(22);e.exports=function(e,t){return r(e)||o(e,t)||c(e,t)||a()},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){e.exports=window.wp.primitives},function(e,t){e.exports=window.wp.url},function(e,t){e.exports=window.lodash},,,function(e,t){e.exports=window.wp.compose},,function(e,t,n){var r;!function(){"use strict";var n={}.hasOwnProperty;function o(){for(var e=[],t=0;te.length)&&(t=e.length);for(var n=0,r=new Array(t);ne.length)&&(t=e.length);for(var n=0,r=new Array(t);n5&&Object(c.createElement)(a.Button,{variant:"secondary",isSecondary:!0,isSmall:!0,onClick:function(){return f(!0)}},Object(s.__)("View all","simple-pay"))))},R=simpayHelp,I=R.docs,G=R.docsCategories,D=function(){var e,t=Object(c.useState)("getting-started"),n=o()(t,2),r=n[0],a=n[1];return Object(c.createElement)("div",{className:"simpay-help-panel__categories"},(e=Object(V.groupBy)(I,"categories"),Object(V.map)(e,(function(e,t){return{slug:t,title:G[t]||"",docs:e}}))).map((function(e){return Object(c.createElement)(H,P()({key:e.slug,openCategory:r,setOpenCategory:a},e))})))},F=n(19),W=n.n(F);function U(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return(e=(e=Object(V.deburr)(e)).replace(/^\//,"")).toLowerCase()}var Z=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return Object(V.words)(U(e))};function $(e,t){var n,r,o=e.title||"",c=e.excerpt||"",a=e.categories||[],l=e.tags||[],i=U(t),s=U(o),u=0;if(i===s)u+=30;else if(s.startsWith(i))u+=20;else{var p=[o,c].concat(W()(a),W()(l)).join(" ");0===(n=Object(V.words)(i),r=p,Object(V.differenceWith)(n,Z(r),(function(e,t){return t.includes(e)}))).length&&(u+=10)}return u}var Q=simpayHelp.docs,K=function(e){var t=e.searchTerm,n=Object(c.useMemo)((function(){var e=[];return""!==t&&(e=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=Z(t);if(0===n.length)return e;var r=e.map((function(e){return[e,$(e,t)]})).filter((function(e){return o()(e,2)[1]>0}));return r.sort((function(e,t){var n=o()(e,2)[1];return o()(t,2)[1]-n})),r.map((function(e){return o()(e,1)[0]}))}(Q,t)),e}),[t]),r=Object(d.useDebounce)(k.speak,500);Object(c.useEffect)((function(){if(t){var e=n.length,o=Object(s.sprintf)( /* translators: %d: number of results. */ Object(s._n)("%d result found.","%d results found.",e,"simple-pay"),e);r(o)}}),[t,r]);var a=!(null==n||!n.length);return Object(c.createElement)("div",{className:"simpay-help-panel__results"},!a&&Object(c.createElement)(D,null),a&&n.map((function(e){return Object(c.createElement)(z,P()({key:e.id,searchTerm:t},e))})))},q=function(e){var t=e.onClose,n=e.onSearch,r=e.searchTerm,o=Object(d.useFocusOnMount)("firstElement"),l=function(e){var t=Object(c.useRef)(),n=Object(c.useRef)(!1),r=Object(c.useRef)([]),o=Object(c.useRef)(e);return o.current=e,Object(c.useLayoutEffect)((function(){!1===n.current&&e.forEach((function(e,n){var o=r.current[n];e!==o&&(h(o,null),h(e,t.current))})),r.current=e}),e),Object(c.useLayoutEffect)((function(){n.current=!1})),Object(c.useCallback)((function(e){h(t,e),n.current=!0;var c,a=function(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return b(e,void 0);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?b(e,void 0):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var c,a=!0,l=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){l=!0,c=e},f:function(){try{a||null==n.return||n.return()}finally{if(l)throw c}}}}(e?o.current:r.current);try{for(a.s();!(c=a.n()).done;)h(c.value,e)}catch(e){a.e(e)}finally{a.f()}}),[])}([Object(d.useConstrainedTabbing)(),Object(d.useFocusReturn)(),o]);return Object(c.createElement)(a.Animate,{type:"slide-in",options:{origin:"left"}},(function(e){var o=e.className,a=f()("simpay-help-panel",o);return Object(c.createElement)("div",{ref:l,className:a},Object(c.createElement)(v,{onClose:t}),Object(c.createElement)("div",{className:"simpay-help-panel__search"},Object(c.createElement)(M,{label:Object(s.__)("Search the documentation","simple-pay"),placeholder:Object(s.__)("Search","simple-pay"),onChange:n,value:r}),Object(c.createElement)(K,{searchTerm:r})),Object(c.createElement)(x,{searchTerm:r}))}))},J=function(e){var t=e.isOpen,n=e.onClose;return Object(c.useEffect)((function(){return document.body.classList.toggle("simpay-help-body-locked"),function(){document.body.classList.remove("simpay-help-body-locked")}}),[t]),Object(c.createElement)("button",{className:"simpay-help-backdrop",onClick:n})},X=simpayHelp,Y=X.docsSearchTerm,ee=X.docs;function te(e){var t=Object(i.getFragment)(e),n=Y;if(t&&t.includes("/")){var r=t.split("/");t=r[0],n=Object(i.safeDecodeURI)(r[1])}return{hash:t,searchTerm:n}}Object(c.render)(Object(c.createElement)((function(){var e=te(window.location.href),t=e.hash,n=e.searchTerm,r=Object(c.useState)(n),i=o()(r,2),s=i[0],u=i[1],m=Object(c.useState)("#help"===t),f=o()(m,2),d=f[0],b=f[1];function h(){b(!1),window.history.pushState("",document.title,window.location.pathname+window.location.search)}return Object(c.useEffect)((function(){function e(e){var t=te(e.newURL),r=t.hash,o=t.searchTerm;"#help"===r&&b(!0),o!==n&&u(o)}return window.addEventListener("hashchange",e),function(){window.removeEventListener("hashchange",e)}}),[]),Object(c.createElement)("div",{onKeyDown:function(e){e.keyCode!==l.ESCAPE||e.defaultPrevented||(e.preventDefault(),b(!1))},role:"region"},Object(c.createElement)(p,{isOpen:d,onOpen:function(){u(Y),b(!0),window.history.pushState("",document.title,window.location.pathname+window.location.search+"#help")}}),d&&Object(c.createElement)(c.Fragment,null,Object(c.createElement)(q,{onClose:h,onSearch:u,searchTerm:s,docs:ee}),Object(c.createElement)(J,{onClose:h})),Object(c.createElement)(a.Popover.Slot,null))}),null),document.getElementById("simpay-branding-bar-help"))}]); \ No newline at end of file diff --git a/includes/core/assets/js/simpay-admin-notifications.min.asset.php b/includes/core/assets/js/simpay-admin-notifications.min.asset.php index 69e7ba7b..11069c8b 100644 --- a/includes/core/assets/js/simpay-admin-notifications.min.asset.php +++ b/includes/core/assets/js/simpay-admin-notifications.min.asset.php @@ -1 +1 @@ - array('lodash', 'moment', 'react', 'react-dom', 'wp-api-fetch', 'wp-autop', 'wp-components', 'wp-compose', 'wp-element', 'wp-i18n', 'wp-keycodes', 'wp-polyfill', 'wp-primitives', 'wp-url'), 'version' => '8fff0381fd303c9d2faaf33230fb0ec0'); \ No newline at end of file + array('lodash', 'moment', 'react', 'react-dom', 'wp-api-fetch', 'wp-autop', 'wp-components', 'wp-compose', 'wp-element', 'wp-i18n', 'wp-keycodes', 'wp-polyfill', 'wp-primitives', 'wp-url'), 'version' => '13d6fed6a204d069dde23428a9d8c77e'); \ No newline at end of file diff --git a/includes/core/assets/js/simpay-admin-notifications.min.js b/includes/core/assets/js/simpay-admin-notifications.min.js index 041b5e52..c14a0e6a 100644 --- a/includes/core/assets/js/simpay-admin-notifications.min.js +++ b/includes/core/assets/js/simpay-admin-notifications.min.js @@ -1,5 +1,5 @@ -!function(t){var e={};function n(r){if(e[r])return e[r].exports;var s=e[r]={i:r,l:!1,exports:{}};return t[r].call(s.exports,s,s.exports,n),s.l=!0,s.exports}n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var s in t)n.d(r,s,function(e){return t[e]}.bind(null,s));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=70)}([function(t,e){t.exports=window.wp.element},function(t,e,n){"use strict";n.d(e,"w",(function(){return s})),n.d(e,"a",(function(){return Ot})),n.d(e,"b",(function(){return q})),n.d(e,"c",(function(){return jt})),n.d(e,"d",(function(){return yt})),n.d(e,"e",(function(){return H})),n.d(e,"f",(function(){return dt})),n.d(e,"g",(function(){return Rt})),n.d(e,"h",(function(){return _})),n.d(e,"i",(function(){return zt})),n.d(e,"j",(function(){return qt})),n.d(e,"k",(function(){return E})),n.d(e,"l",(function(){return S})),n.d(e,"m",(function(){return M})),n.d(e,"n",(function(){return A})),n.d(e,"o",(function(){return U})),n.d(e,"p",(function(){return gt})),n.d(e,"q",(function(){return bt})),n.d(e,"r",(function(){return mt})),n.d(e,"s",(function(){return k})),n.d(e,"t",(function(){return Lt})),n.d(e,"u",(function(){return x})),n.d(e,"v",(function(){return w})),n.d(e,"x",(function(){return wt})),n.d(e,"y",(function(){return P})),n.d(e,"z",(function(){return $t})),n.d(e,"A",(function(){return Ht})),n.d(e,"B",(function(){return Bt})),n.d(e,"C",(function(){return Ft})),n.d(e,"D",(function(){return Gt}));let r=O();const s=t=>m(t,r);let i=O();s.write=t=>m(t,i);let o=O();s.onStart=t=>m(t,o);let a=O();s.onFrame=t=>m(t,a);let c=O();s.onFinish=t=>m(t,c);let u=[];s.setTimeout=(t,e)=>{let n=s.now()+e,r=()=>{let t=u.findIndex(t=>t.cancel==r);~t&&u.splice(t,1),h-=~t?1:0},i={time:n,handler:t,cancel:r};return u.splice(l(n),0,i),h+=1,b(),i};let l=t=>~(~u.findIndex(e=>e.time>t)||~u.length);s.cancel=t=>{o.delete(t),a.delete(t),r.delete(t),i.delete(t),c.delete(t)},s.sync=t=>{p=!0,s.batchedUpdates(t),p=!1},s.throttle=t=>{let e;function n(){try{t(...e)}finally{e=null}}function r(...t){e=t,s.onStart(n)}return r.handler=t,r.cancel=()=>{o.delete(n),e=null},r};let d="undefined"!=typeof window?window.requestAnimationFrame:()=>{};s.use=t=>d=t,s.now="undefined"!=typeof performance?()=>performance.now():Date.now,s.batchedUpdates=t=>t(),s.catch=console.error,s.frameLoop="always",s.advance=()=>{"demand"!==s.frameLoop?console.warn("Cannot call the manual advancement of rafz whilst frameLoop is not set as demand"):y()};let f=-1,h=0,p=!1;function m(t,e){p?(e.delete(t),t(0)):(e.add(t),b())}function b(){f<0&&(f=0,"demand"!==s.frameLoop&&d(g))}function g(){~f&&(d(g),s.batchedUpdates(y))}function y(){let t=f;f=s.now();let e=l(f);e&&(v(u.splice(0,e),t=>t.handler()),h-=e),o.flush(),r.flush(t?Math.min(64,f-t):16.667),a.flush(),i.flush(),c.flush(),h||(f=-1)}function O(){let t=new Set,e=t;return{add(n){h+=e!=t||t.has(n)?0:1,t.add(n)},delete:n=>(h-=e==t&&t.has(n)?1:0,t.delete(n)),flush(n){e.size&&(t=new Set,h-=e.size,v(e,e=>e(n)&&t.add(e)),h+=t.size,e=t)}}}function v(t,e){t.forEach(t=>{try{e(t)}catch(t){s.catch(t)}})}var j=n(4);function w(){}const _=(t,e,n)=>Object.defineProperty(t,e,{value:n,writable:!0,configurable:!0}),k={arr:Array.isArray,obj:t=>!!t&&"Object"===t.constructor.name,fun:t=>"function"==typeof t,str:t=>"string"==typeof t,num:t=>"number"==typeof t,und:t=>void 0===t};function x(t,e){if(k.arr(t)){if(!k.arr(e)||t.length!==e.length)return!1;for(let n=0;nt.forEach(e);function S(t,e,n){if(k.arr(t))for(let r=0;rk.und(t)?[]:k.arr(t)?t:[t];function M(t,e){if(t.size){const n=Array.from(t);t.clear(),E(n,e)}}const A=(t,...e)=>M(t,t=>t(...e)),I=()=>"undefined"==typeof window||!window.navigator||/ServerSideRendering|^Deno\//.test(window.navigator.userAgent);let C,R,T=null,V=!1,N=w;var q=Object.freeze({__proto__:null,get createStringInterpolator(){return C},get to(){return R},get colors(){return T},get skipAnimation(){return V},get willAdvance(){return N},assign:t=>{t.to&&(R=t.to),t.now&&(s.now=t.now),void 0!==t.colors&&(T=t.colors),null!=t.skipAnimation&&(V=t.skipAnimation),t.createStringInterpolator&&(C=t.createStringInterpolator),t.requestAnimationFrame&&s.use(t.requestAnimationFrame),t.batchedUpdates&&(s.batchedUpdates=t.batchedUpdates),t.willAdvance&&(N=t.willAdvance),t.frameLoop&&(s.frameLoop=t.frameLoop)}});const D=new Set;let z=[],L=[],F=0;const U={get idle(){return!D.size&&!z.length},start(t){F>t.priority?(D.add(t),s.onStart($)):(Q(t),s(G))},advance:G,sort(t){if(F)s.onFrame(()=>U.sort(t));else{const e=z.indexOf(t);~e&&(z.splice(e,1),B(t))}},clear(){z=[],D.clear()}};function $(){D.forEach(Q),D.clear(),s(G)}function Q(t){z.includes(t)||B(t)}function B(t){z.splice(function(e,n){const r=e.findIndex(e=>e.priority>t.priority);return r<0?e.length:r}(z),0,t)}function G(t){const e=L;for(let n=0;n0}const H={transparent:0,aliceblue:4042850303,antiquewhite:4209760255,aqua:16777215,aquamarine:2147472639,azure:4043309055,beige:4126530815,bisque:4293182719,black:255,blanchedalmond:4293643775,blue:65535,blueviolet:2318131967,brown:2771004159,burlywood:3736635391,burntsienna:3934150143,cadetblue:1604231423,chartreuse:2147418367,chocolate:3530104575,coral:4286533887,cornflowerblue:1687547391,cornsilk:4294499583,crimson:3692313855,cyan:16777215,darkblue:35839,darkcyan:9145343,darkgoldenrod:3095792639,darkgray:2846468607,darkgreen:6553855,darkgrey:2846468607,darkkhaki:3182914559,darkmagenta:2332068863,darkolivegreen:1433087999,darkorange:4287365375,darkorchid:2570243327,darkred:2332033279,darksalmon:3918953215,darkseagreen:2411499519,darkslateblue:1211993087,darkslategray:793726975,darkslategrey:793726975,darkturquoise:13554175,darkviolet:2483082239,deeppink:4279538687,deepskyblue:12582911,dimgray:1768516095,dimgrey:1768516095,dodgerblue:512819199,firebrick:2988581631,floralwhite:4294635775,forestgreen:579543807,fuchsia:4278255615,gainsboro:3705462015,ghostwhite:4177068031,gold:4292280575,goldenrod:3668254975,gray:2155905279,green:8388863,greenyellow:2919182335,grey:2155905279,honeydew:4043305215,hotpink:4285117695,indianred:3445382399,indigo:1258324735,ivory:4294963455,khaki:4041641215,lavender:3873897215,lavenderblush:4293981695,lawngreen:2096890111,lemonchiffon:4294626815,lightblue:2916673279,lightcoral:4034953471,lightcyan:3774873599,lightgoldenrodyellow:4210742015,lightgray:3553874943,lightgreen:2431553791,lightgrey:3553874943,lightpink:4290167295,lightsalmon:4288707327,lightseagreen:548580095,lightskyblue:2278488831,lightslategray:2005441023,lightslategrey:2005441023,lightsteelblue:2965692159,lightyellow:4294959359,lime:16711935,limegreen:852308735,linen:4210091775,magenta:4278255615,maroon:2147483903,mediumaquamarine:1724754687,mediumblue:52735,mediumorchid:3126187007,mediumpurple:2473647103,mediumseagreen:1018393087,mediumslateblue:2070474495,mediumspringgreen:16423679,mediumturquoise:1221709055,mediumvioletred:3340076543,midnightblue:421097727,mintcream:4127193855,mistyrose:4293190143,moccasin:4293178879,navajowhite:4292783615,navy:33023,oldlace:4260751103,olive:2155872511,olivedrab:1804477439,orange:4289003775,orangered:4282712319,orchid:3664828159,palegoldenrod:4008225535,palegreen:2566625535,paleturquoise:2951671551,palevioletred:3681588223,papayawhip:4293907967,peachpuff:4292524543,peru:3448061951,pink:4290825215,plum:3718307327,powderblue:2967529215,purple:2147516671,rebeccapurple:1714657791,red:4278190335,rosybrown:3163525119,royalblue:1097458175,saddlebrown:2336560127,salmon:4202722047,sandybrown:4104413439,seagreen:780883967,seashell:4294307583,sienna:2689740287,silver:3233857791,skyblue:2278484991,slateblue:1784335871,slategray:1887473919,slategrey:1887473919,snow:4294638335,springgreen:16744447,steelblue:1182971135,tan:3535047935,teal:8421631,thistle:3636451583,tomato:4284696575,turquoise:1088475391,violet:4001558271,wheat:4125012991,white:4294967295,whitesmoke:4126537215,yellow:4294902015,yellowgreen:2597139199},W="[-+]?\\d*\\.?\\d+";function Z(...t){return"\\(\\s*("+t.join(")\\s*,\\s*(")+")\\s*\\)"}const Y=new RegExp("rgb"+Z(W,W,W)),J=new RegExp("rgba"+Z(W,W,W,W)),K=new RegExp("hsl"+Z(W,"[-+]?\\d*\\.?\\d+%","[-+]?\\d*\\.?\\d+%")),X=new RegExp("hsla"+Z(W,"[-+]?\\d*\\.?\\d+%","[-+]?\\d*\\.?\\d+%",W)),tt=/^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,et=/^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,nt=/^#([0-9a-fA-F]{6})$/,rt=/^#([0-9a-fA-F]{8})$/;function st(t,e,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?t+6*(e-t)*n:n<.5?e:n<2/3?t+(e-t)*(2/3-n)*6:t}function it(t,e,n){const r=n<.5?n*(1+e):n+e-n*e,s=2*n-r,i=st(s,r,t+1/3),o=st(s,r,t),a=st(s,r,t-1/3);return Math.round(255*i)<<24|Math.round(255*o)<<16|Math.round(255*a)<<8}function ot(t){const e=parseInt(t,10);return e<0?0:e>255?255:e}function at(t){return(parseFloat(t)%360+360)%360/360}function ct(t){const e=parseFloat(t);return e<0?0:e>1?255:Math.round(255*e)}function ut(t){const e=parseFloat(t);return e<0?0:e>100?1:e/100}function lt(t){let e=function(t){let e;return"number"==typeof t?t>>>0===t&&t>=0&&t<=4294967295?t:null:(e=nt.exec(t))?parseInt(e[1]+"ff",16)>>>0:T&&void 0!==T[t]?T[t]:(e=Y.exec(t))?(ot(e[1])<<24|ot(e[2])<<16|ot(e[3])<<8|255)>>>0:(e=J.exec(t))?(ot(e[1])<<24|ot(e[2])<<16|ot(e[3])<<8|ct(e[4]))>>>0:(e=tt.exec(t))?parseInt(e[1]+e[1]+e[2]+e[2]+e[3]+e[3]+"ff",16)>>>0:(e=rt.exec(t))?parseInt(e[1],16)>>>0:(e=et.exec(t))?parseInt(e[1]+e[1]+e[2]+e[2]+e[3]+e[3]+e[4]+e[4],16)>>>0:(e=K.exec(t))?(255|it(at(e[1]),ut(e[2]),ut(e[3])))>>>0:(e=X.exec(t))?(it(at(e[1]),ut(e[2]),ut(e[3]))|ct(e[4]))>>>0:null}(t);return null===e?t:(e=e||0,`rgba(${(4278190080&e)>>>24}, ${(16711680&e)>>>16}, ${(65280&e)>>>8}, ${(255&e)/255})`)}const dt=(t,e,n)=>{if(k.fun(t))return t;if(k.arr(t))return dt({range:t,output:e,extrapolate:n});if(k.str(t.output[0]))return C(t);const r=t,s=r.output,i=r.range||[0,1],o=r.extrapolateLeft||r.extrapolate||"extend",a=r.extrapolateRight||r.extrapolate||"extend",c=r.easing||(t=>t);return t=>{const e=function(t,e){for(var n=1;n=t);++n);return n-1}(t,i);return function(t,e,n,r,s,i,o,a,c){let u=c?c(t):t;if(un){if("identity"===a)return u;"clamp"===a&&(u=n)}return r===s?r:e===n?t<=e?r:s:(e===-1/0?u=-u:n===1/0?u-=e:u=(u-e)/(n-e),u=i(u),r===-1/0?u=-u:s===1/0?u+=r:u=u*(s-r)+r,u)}(t,i[e],i[e+1],s[e],s[e+1],c,o,a,r.map)}};function ft(){return(ft=Object.assign||function(t){for(var e=1;eBoolean(t&&t[ht]),bt=t=>t&&t[ht]?t[ht]():t,gt=t=>t[pt]||null;function yt(t,e){let n=t[pt];n&&n.forEach(t=>{!function(t,e){t.eventObserved?t.eventObserved(e):t(e)}(t,e)})}class Ot{constructor(t){if(this[ht]=void 0,this[pt]=void 0,!t&&!(t=this.get))throw Error("Unknown getter");vt(this,t)}}const vt=(t,e)=>_t(t,ht,e);function jt(t,e){if(t[ht]){let n=t[pt];n||_t(t,pt,n=new Set),n.has(e)||(n.add(e),t.observerAdded&&t.observerAdded(n.size,e))}return e}function wt(t,e){let n=t[pt];if(n&&n.has(e)){const r=n.size-1;r?n.delete(e):t[pt]=null,t.observerRemoved&&t.observerRemoved(r,e)}}const _t=(t,e,n)=>Object.defineProperty(t,e,{value:n,writable:!0,configurable:!0}),kt=/[+\-]?(?:0|[1-9]\d*)(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,xt=/(#(?:[0-9a-f]{2}){2,4}|(#[0-9a-f]{3})|(rgb|hsl)a?\((-?\d+%?[,\s]+){2,3}\s*[\d\.]+%?\))/gi,Et=new RegExp(`(${kt.source})(%|[a-z]+)`,"i"),St=/rgba\(([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+)\)/gi,Pt=/var\((--[a-zA-Z0-9-_]+),? ?([a-zA-Z0-9 ()%#.,-]+)?\)/,Mt=t=>{const[e,n]=At(t);if(!e||I())return t;const r=window.getComputedStyle(document.documentElement).getPropertyValue(e);if(r)return r.trim();if(n&&n.startsWith("--")){return window.getComputedStyle(document.documentElement).getPropertyValue(n)||t}return n&&Pt.test(n)?Mt(n):n||t},At=t=>{const e=Pt.exec(t);if(!e)return[,];const[,n,r]=e;return[n,r]};let It;const Ct=(t,e,n,r,s)=>`rgba(${Math.round(e)}, ${Math.round(n)}, ${Math.round(r)}, ${s})`,Rt=t=>{It||(It=T?new RegExp(`(${Object.keys(T).join("|")})(?!\\w)`,"g"):/^\b$/);const e=t.output.map(t=>bt(t).replace(Pt,Mt).replace(xt,lt).replace(It,lt)),n=e.map(t=>t.match(kt).map(Number)),r=n[0].map((t,e)=>n.map(t=>{if(!(e in t))throw Error('The arity of each "output" value must be equal');return t[e]})).map(e=>dt(ft({},t,{output:e})));return t=>{var n;const s=!Et.test(e[0])&&(null==(n=e.find(t=>Et.test(t)))?void 0:n.replace(kt,""));let i=0;return e[0].replace(kt,()=>`${r[i++](t)}${s||""}`).replace(St,Ct)}},Tt="react-spring: ",Vt=t=>{const e=t;let n=!1;if("function"!=typeof e)throw new TypeError(Tt+"once requires a function parameter");return(...t)=>{n||(e(...t),n=!0)}},Nt=Vt(console.warn);function qt(){Nt(Tt+'The "interpolate" function is deprecated in v9 (use "to" instead)')}const Dt=Vt(console.warn);function zt(){Dt(Tt+'Directly calling start instead of using the api object is deprecated in v9 (use ".start" instead), this will be removed in later 0.X.0 versions')}function Lt(t){return k.str(t)&&("#"==t[0]||/\d/.test(t)||!I()&&Pt.test(t)||t in(T||{}))}const Ft=t=>Object(j.useEffect)(t,Ut),Ut=[];function $t(){const t=Object(j.useState)()[1],e=Object(j.useState)(Qt)[0];return Ft(e.unmount),()=>{e.current&&t({})}}function Qt(){const t={current:!0,unmount:()=>()=>{t.current=!1}};return t}function Bt(t,e){const[n]=Object(j.useState)(()=>({inputs:e,result:t()})),r=Object(j.useRef)(),s=r.current;let i=s;return i?Boolean(e&&i.inputs&&function(t,e){if(t.length!==e.length)return!1;for(let n=0;n{r.current=i,s==n&&(n.inputs=n.result=void 0)},[i]),i.result}function Gt(t){const e=Object(j.useRef)();return Object(j.useEffect)(()=>{e.current=t}),e.current}const Ht="undefined"!=typeof window&&window.document&&window.document.createElement?j.useLayoutEffect:j.useEffect},function(t,e){t.exports=window.wp.i18n},function(t,e){t.exports=window.wp.components},function(t,e){t.exports=window.React},function(t,e,n){var r=n(20),s=n(21),i=n(16),o=n(22);t.exports=function(t,e){return r(t)||s(t,e)||i(t,e)||o()},t.exports.__esModule=!0,t.exports.default=t.exports},function(t,e){t.exports=window.wp.primitives},function(t,e){t.exports=window.wp.url},function(t,e){t.exports=window.lodash},,function(t,e,n){"use strict";n.d(e,"a",(function(){return h})),n.d(e,"b",(function(){return d})),n.d(e,"c",(function(){return l})),n.d(e,"d",(function(){return j})),n.d(e,"e",(function(){return o})),n.d(e,"f",(function(){return b})),n.d(e,"g",(function(){return c})),n.d(e,"h",(function(){return a}));var r=n(1),s=n(4);const i=Symbol.for("Animated:node"),o=t=>t&&t[i],a=(t,e)=>Object(r.h)(t,i,e),c=t=>t&&t[i]&&t[i].getPayload();class u{constructor(){this.payload=void 0,a(this,this)}getPayload(){return this.payload||[]}}class l extends u{constructor(t){super(),this.done=!0,this.elapsedTime=void 0,this.lastPosition=void 0,this.lastVelocity=void 0,this.v0=void 0,this.durationProgress=0,this._value=t,r.s.num(this._value)&&(this.lastPosition=this._value)}static create(t){return new l(t)}getPayload(){return[this]}getValue(){return this._value}setValue(t,e){return r.s.num(t)&&(this.lastPosition=t,e&&(t=Math.round(t/e)*e,this.done&&(this.lastPosition=t))),this._value!==t&&(this._value=t,!0)}reset(){const{done:t}=this;this.done=!1,r.s.num(this._value)&&(this.elapsedTime=0,this.durationProgress=0,this.lastPosition=this._value,t&&(this.lastVelocity=null),this.v0=null)}}class d extends l{constructor(t){super(0),this._string=null,this._toString=void 0,this._toString=Object(r.f)({output:[t,t]})}static create(t){return new d(t)}getValue(){let t=this._string;return null==t?this._string=this._toString(this._value):t}setValue(t){if(r.s.str(t)){if(t==this._string)return!1;this._string=t,this._value=1}else{if(!super.setValue(t))return!1;this._string=null}return!0}reset(t){t&&(this._toString=Object(r.f)({output:[this.getValue(),t]})),this._value=0,super.reset()}}const f={dependencies:null};class h extends u{constructor(t){super(),this.source=t,this.setValue(t)}getValue(t){const e={};return Object(r.l)(this.source,(n,s)=>{var o;(o=n)&&o[i]===o?e[s]=n.getValue(t):Object(r.r)(n)?e[s]=Object(r.q)(n):t||(e[s]=n)}),e}setValue(t){this.source=t,this.payload=this._makePayload(t)}reset(){this.payload&&Object(r.k)(this.payload,t=>t.reset())}_makePayload(t){if(t){const e=new Set;return Object(r.l)(t,this._addToPayload,e),Array.from(e)}}_addToPayload(t){f.dependencies&&Object(r.r)(t)&&f.dependencies.add(t);const e=c(t);e&&Object(r.k)(e,t=>this.add(t))}}class p extends h{constructor(t){super(t)}static create(t){return new p(t)}getValue(){return this.source.map(t=>t.getValue())}setValue(t){const e=this.getPayload();return t.length==e.length?e.map((e,n)=>e.setValue(t[n])).some(Boolean):(super.setValue(t.map(m)),!0)}}function m(t){return(Object(r.t)(t)?d:l).create(t)}function b(t){const e=o(t);return e?e.constructor:r.s.arr(t)?p:Object(r.t)(t)?d:l}function g(){return(g=Object.assign||function(t){for(var e=1;e{const n=!r.s.fun(t)||t.prototype&&t.prototype.isReactComponent;return Object(s.forwardRef)((i,o)=>{const a=Object(s.useRef)(null),c=n&&Object(s.useCallback)(t=>{a.current=function(t,e){return t&&(r.s.fun(t)?t(e):t.current=e),e}(o,t)},[o]),[u,l]=function(t,e){const n=new Set;return f.dependencies=n,t.style&&(t=g({},t,{style:e.createAnimatedStyle(t.style)})),t=new h(t),f.dependencies=null,[t,n]}(i,e),d=Object(r.z)(),p=()=>{const t=a.current;n&&!t||!1===(!!t&&e.applyAnimatedValues(t,u.getValue(!0)))&&d()},m=new O(p,l),b=Object(s.useRef)();Object(r.A)(()=>{const t=b.current;b.current=m,Object(r.k)(l,t=>Object(r.c)(t,m)),t&&(Object(r.k)(t.deps,e=>Object(r.x)(e,t)),r.w.cancel(t.update))}),Object(s.useEffect)(p,[]),Object(r.C)(()=>()=>{const t=b.current;Object(r.k)(t.deps,e=>Object(r.x)(e,t))});const y=e.getComponentProps(u.getValue());return s.createElement(t,g({},y,{ref:c}))})};class O{constructor(t,e){this.update=t,this.deps=e}eventObserved(t){"change"==t.type&&r.w.write(this.update)}}const v=Symbol.for("AnimatedComponent"),j=(t,{applyAnimatedValues:e=(()=>!1),createAnimatedStyle:n=(t=>new h(t)),getComponentProps:s=(t=>t)}={})=>{const i={applyAnimatedValues:e,createAnimatedStyle:n,getComponentProps:s},o=t=>{const e=w(t)||"Anonymous";return(t=r.s.str(t)?o[t]||(o[t]=y(t,i)):t[v]||(t[v]=y(t,i))).displayName=`Animated(${e})`,t};return Object(r.l)(t,(e,n)=>{r.s.arr(t)&&(n=w(e)),o[n]=o(e)}),{animated:o}},w=t=>r.s.str(t)?t:t&&r.s.str(t.displayName)?t.displayName:r.s.fun(t)&&t.name||null},function(t,e){t.exports=window.wp.compose},,function(t,e){t.exports=function(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t},t.exports.__esModule=!0,t.exports.default=t.exports},function(t,e,n){var r;!function(){"use strict";var n={}.hasOwnProperty;function s(){for(var t=[],e=0;et.length)&&(e=t.length);for(var n=0,r=new Array(e);n!0===t||!!(e&&t&&(r.s.fun(t)?t(e):Object(r.y)(t).includes(e))),u=(t,e)=>r.s.obj(t)?e&&t[e]:t,l=(t,e)=>!0===t.default?t[e]:t.default?t.default[e]:void 0,d=t=>t,f=(t,e=d)=>{let n=h;t.default&&!0!==t.default&&(t=t.default,n=Object.keys(t));const s={};for(const i of n){const n=e(t[i],i);r.s.und(n)||(s[i]=n)}return s},h=["config","onProps","onStart","onChange","onPause","onResume","onRest"],p={config:1,from:1,to:1,ref:1,loop:1,reset:1,pause:1,cancel:1,reverse:1,immediate:1,default:1,delay:1,onProps:1,onStart:1,onChange:1,onPause:1,onResume:1,onRest:1,onResolve:1,items:1,trail:1,sort:1,expires:1,initial:1,enter:1,update:1,leave:1,children:1,onDestroyed:1,keys:1,callId:1,parentId:1};function m(t){const e=function(t){const e={};let n=0;if(Object(r.l)(t,(t,r)=>{p[r]||(e[r]=t,n++)}),n)return e}(t);if(e){const n={to:e};return Object(r.l)(t,(t,r)=>r in e||(n[r]=t)),n}return o({},t)}function b(t){return t=Object(r.q)(t),r.s.arr(t)?t.map(b):Object(r.t)(t)?r.b.createStringInterpolator({range:[0,1],output:[t,t]})(1):t}function g(t){for(const e in t)return!0;return!1}function y(t){return r.s.fun(t)||r.s.arr(t)&&r.s.obj(t[0])}function O(t,e){var n;null==(n=t.ref)||n.delete(t),null==e||e.delete(t)}function v(t,e){var n;e&&t.ref!==e&&(null==(n=t.ref)||n.delete(t),e.add(t),t.ref=e)}const j={default:{tension:170,friction:26},gentle:{tension:120,friction:14},wobbly:{tension:180,friction:12},stiff:{tension:210,friction:20},slow:{tension:280,friction:60},molasses:{tension:280,friction:120}},w=1.70158,_=1.525*w,k=2*Math.PI/3,x=2*Math.PI/4.5,E=t=>{const e=7.5625,n=2.75;return t<1/n?e*t*t:t<2/n?e*(t-=1.5/n)*t+.75:t<2.5/n?e*(t-=2.25/n)*t+.9375:e*(t-=2.625/n)*t+.984375},S={linear:t=>t,easeInQuad:t=>t*t,easeOutQuad:t=>1-(1-t)*(1-t),easeInOutQuad:t=>t<.5?2*t*t:1-Math.pow(-2*t+2,2)/2,easeInCubic:t=>t*t*t,easeOutCubic:t=>1-Math.pow(1-t,3),easeInOutCubic:t=>t<.5?4*t*t*t:1-Math.pow(-2*t+2,3)/2,easeInQuart:t=>t*t*t*t,easeOutQuart:t=>1-Math.pow(1-t,4),easeInOutQuart:t=>t<.5?8*t*t*t*t:1-Math.pow(-2*t+2,4)/2,easeInQuint:t=>t*t*t*t*t,easeOutQuint:t=>1-Math.pow(1-t,5),easeInOutQuint:t=>t<.5?16*t*t*t*t*t:1-Math.pow(-2*t+2,5)/2,easeInSine:t=>1-Math.cos(t*Math.PI/2),easeOutSine:t=>Math.sin(t*Math.PI/2),easeInOutSine:t=>-(Math.cos(Math.PI*t)-1)/2,easeInExpo:t=>0===t?0:Math.pow(2,10*t-10),easeOutExpo:t=>1===t?1:1-Math.pow(2,-10*t),easeInOutExpo:t=>0===t?0:1===t?1:t<.5?Math.pow(2,20*t-10)/2:(2-Math.pow(2,-20*t+10))/2,easeInCirc:t=>1-Math.sqrt(1-Math.pow(t,2)),easeOutCirc:t=>Math.sqrt(1-Math.pow(t-1,2)),easeInOutCirc:t=>t<.5?(1-Math.sqrt(1-Math.pow(2*t,2)))/2:(Math.sqrt(1-Math.pow(-2*t+2,2))+1)/2,easeInBack:t=>2.70158*t*t*t-w*t*t,easeOutBack:t=>1+2.70158*Math.pow(t-1,3)+w*Math.pow(t-1,2),easeInOutBack:t=>t<.5?Math.pow(2*t,2)*(7.189819*t-_)/2:(Math.pow(2*t-2,2)*((_+1)*(2*t-2)+_)+2)/2,easeInElastic:t=>0===t?0:1===t?1:-Math.pow(2,10*t-10)*Math.sin((10*t-10.75)*k),easeOutElastic:t=>0===t?0:1===t?1:Math.pow(2,-10*t)*Math.sin((10*t-.75)*k)+1,easeInOutElastic:t=>0===t?0:1===t?1:t<.5?-Math.pow(2,20*t-10)*Math.sin((20*t-11.125)*x)/2:Math.pow(2,-20*t+10)*Math.sin((20*t-11.125)*x)/2+1,easeInBounce:t=>1-E(1-t),easeOutBounce:E,easeInOutBounce:t=>t<.5?(1-E(1-2*t))/2:(1+E(2*t-1))/2},P=o({},j.default,{mass:1,damping:1,easing:S.linear,clamp:!1});class M{constructor(){this.tension=void 0,this.friction=void 0,this.frequency=void 0,this.damping=void 0,this.mass=void 0,this.velocity=0,this.restVelocity=void 0,this.precision=void 0,this.progress=void 0,this.duration=void 0,this.easing=void 0,this.clamp=void 0,this.bounce=void 0,this.decay=void 0,this.round=void 0,Object.assign(this,P)}}function A(t,e){if(r.s.und(e.decay)){const n=!r.s.und(e.tension)||!r.s.und(e.friction);!n&&r.s.und(e.frequency)&&r.s.und(e.damping)&&r.s.und(e.mass)||(t.duration=void 0,t.decay=void 0),n&&(t.frequency=void 0)}else t.duration=void 0}const I=[];class C{constructor(){this.changed=!1,this.values=I,this.toValues=null,this.fromValues=I,this.to=void 0,this.from=void 0,this.config=new M,this.immediate=!1}}function R(t,{key:e,props:n,defaultProps:s,state:i,actions:u}){return new Promise((l,d)=>{var f;let h,p,m=c(null!=(f=n.cancel)?f:null==s?void 0:s.cancel,e);if(m)y();else{r.s.und(n.pause)||(i.paused=c(n.pause,e));let t=null==s?void 0:s.pause;!0!==t&&(t=i.paused||c(t,e)),h=a(n.delay||0,e),t?(i.resumeQueue.add(g),u.pause()):(u.resume(),g())}function b(){i.resumeQueue.add(g),i.timeouts.delete(p),p.cancel(),h=p.time-r.w.now()}function g(){h>0&&!r.b.skipAnimation?(i.delayed=!0,p=r.w.setTimeout(y,h),i.pauseQueue.add(b),i.timeouts.add(p)):y()}function y(){i.delayed&&(i.delayed=!1),i.pauseQueue.delete(b),i.timeouts.delete(p),t<=(i.cancelId||0)&&(m=!0);try{u.start(o({},n,{callId:t,cancel:m}),l)}catch(t){d(t)}}})}const T=(t,e)=>1==e.length?e[0]:e.some(t=>t.cancelled)?q(t.get()):e.every(t=>t.noop)?V(t.get()):N(t.get(),e.every(t=>t.finished)),V=t=>({value:t,noop:!0,finished:!0,cancelled:!1}),N=(t,e,n=!1)=>({value:t,finished:e,cancelled:n}),q=t=>({value:t,cancelled:!0,finished:!1});function D(t,e,n,s){const{callId:i,parentId:a,onRest:c}=e,{asyncTo:u,promise:l}=n;return a||t!==u||e.reset?n.promise=(async()=>{n.asyncId=i,n.asyncTo=t;const d=f(e,(t,e)=>"onRest"===e?void 0:t);let h,p;const m=new Promise((t,e)=>(h=t,p=e)),b=t=>{const e=i<=(n.cancelId||0)&&q(s)||i!==n.asyncId&&N(s,!1);if(e)throw t.result=e,p(t),t},g=(t,e)=>{const a=new L,c=new F;return(async()=>{if(r.b.skipAnimation)throw z(n),c.result=N(s,!1),p(c),c;b(a);const u=r.s.obj(t)?o({},t):o({},e,{to:t});u.parentId=i,Object(r.l)(d,(t,e)=>{r.s.und(u[e])&&(u[e]=t)});const l=await s.start(u);return b(a),n.paused&&await new Promise(t=>{n.resumeQueue.add(t)}),l})()};let y;if(r.b.skipAnimation)return z(n),N(s,!1);try{let e;e=r.s.arr(t)?(async t=>{for(const e of t)await g(e)})(t):Promise.resolve(t(g,s.stop.bind(s))),await Promise.all([e.then(h),m]),y=N(s.get(),!0,!1)}catch(t){if(t instanceof L)y=t.result;else{if(!(t instanceof F))throw t;y=t.result}}finally{i==n.asyncId&&(n.asyncId=a,n.asyncTo=a?u:void 0,n.promise=a?l:void 0)}return r.s.fun(c)&&r.w.batchedUpdates(()=>{c(y,s,s.item)}),y})():l}function z(t,e){Object(r.m)(t.timeouts,t=>t.cancel()),t.pauseQueue.clear(),t.resumeQueue.clear(),t.asyncId=t.asyncTo=t.promise=void 0,e&&(t.cancelId=e)}class L extends Error{constructor(){super("An async animation has been interrupted. You see this error because you forgot to use `await` or `.catch(...)` on its returned promise."),this.result=void 0}}class F extends Error{constructor(){super("SkipAnimationSignal"),this.result=void 0}}const U=t=>t instanceof Q;let $=1;class Q extends r.a{constructor(...t){super(...t),this.id=$++,this.key=void 0,this._priority=0}get priority(){return this._priority}set priority(t){this._priority!=t&&(this._priority=t,this._onPriorityChange(t))}get(){const t=Object(i.e)(this);return t&&t.getValue()}to(...t){return r.b.to(this,t)}interpolate(...t){return Object(r.j)(),r.b.to(this,t)}toJSON(){return this.get()}observerAdded(t){1==t&&this._attach()}observerRemoved(t){0==t&&this._detach()}_attach(){}_detach(){}_onChange(t,e=!1){Object(r.d)(this,{type:"change",parent:this,value:t,idle:e})}_onPriorityChange(t){this.idle||r.o.sort(this),Object(r.d)(this,{type:"priority",parent:this,priority:t})}}const B=Symbol.for("SpringPhase"),G=t=>(1&t[B])>0,H=t=>(2&t[B])>0,W=t=>(4&t[B])>0,Z=(t,e)=>e?t[B]|=3:t[B]&=-3,Y=(t,e)=>e?t[B]|=4:t[B]&=-5;class J extends Q{constructor(t,e){if(super(),this.key=void 0,this.animation=new C,this.queue=void 0,this.defaultProps={},this._state={paused:!1,delayed:!1,pauseQueue:new Set,resumeQueue:new Set,timeouts:new Set},this._pendingCalls=new Set,this._lastCallId=0,this._lastToId=0,this._memoizedDuration=0,!r.s.und(t)||!r.s.und(e)){const n=r.s.obj(t)?o({},t):o({},e,{from:t});r.s.und(n.default)&&(n.default=!0),this.start(n)}}get idle(){return!(H(this)||this._state.asyncTo)||W(this)}get goal(){return Object(r.q)(this.animation.to)}get velocity(){const t=Object(i.e)(this);return t instanceof i.c?t.lastVelocity||0:t.getPayload().map(t=>t.lastVelocity||0)}get hasAnimated(){return G(this)}get isAnimating(){return H(this)}get isPaused(){return W(this)}get isDelayed(){return this._state.delayed}advance(t){let e=!0,n=!1;const s=this.animation;let{config:o,toValues:a}=s;const c=Object(i.g)(s.to);!c&&Object(r.r)(s.to)&&(a=Object(r.y)(Object(r.q)(s.to))),s.values.forEach((u,l)=>{if(u.done)return;const d=u.constructor==i.b?1:c?c[l].lastPosition:a[l];let f=s.immediate,h=d;if(!f){if(h=u.lastPosition,o.tension<=0)return void(u.done=!0);let e=u.elapsedTime+=t;const n=s.fromValues[l],i=null!=u.v0?u.v0:u.v0=r.s.arr(o.velocity)?o.velocity[l]:o.velocity;let a;if(r.s.und(o.duration))if(o.decay){const t=!0===o.decay?.998:o.decay,r=Math.exp(-(1-t)*e);h=n+i/(1-t)*(1-r),f=Math.abs(u.lastPosition-h)<.1,a=i*r}else{a=null==u.lastVelocity?i:u.lastVelocity;const e=o.precision||(n==d?.005:Math.min(1,.001*Math.abs(d-n))),s=o.restVelocity||e/10,c=o.clamp?0:o.bounce,l=!r.s.und(c),p=n==d?u.v0>0:ns,m||(f=Math.abs(d-h)<=e,!f));++t)l&&(b=h==d||h>d==p,b&&(a=-a*c,h=d)),a+=(1e-6*-o.tension*(h-d)+.001*-o.friction*a)/o.mass*g,h+=a*g}else{let r=1;o.duration>0&&(this._memoizedDuration!==o.duration&&(this._memoizedDuration=o.duration,u.durationProgress>0&&(u.elapsedTime=o.duration*u.durationProgress,e=u.elapsedTime+=t)),r=(o.progress||0)+e/this._memoizedDuration,r=r>1?1:r<0?0:r,u.durationProgress=r),h=n+o.easing(r)*(d-n),a=(h-u.lastPosition)/t,f=1==r}u.lastVelocity=a,Number.isNaN(h)&&(console.warn("Got NaN while animating:",this),f=!0)}c&&!c[l].done&&(f=!1),f?u.done=!0:e=!1,u.setValue(h,o.round)&&(n=!0)});const u=Object(i.e)(this),l=u.getValue();if(e){const t=Object(r.q)(s.to);l===t&&!n||o.decay?n&&o.decay&&this._onChange(l):(u.setValue(t),this._onChange(t)),this._stop()}else n&&this._onChange(l)}set(t){return r.w.batchedUpdates(()=>{this._stop(),this._focus(t),this._set(t)}),this}pause(){this._update({pause:!0})}resume(){this._update({pause:!1})}finish(){if(H(this)){const{to:t,config:e}=this.animation;r.w.batchedUpdates(()=>{this._onStart(),e.decay||this._set(t,!1),this._stop()})}return this}update(t){return(this.queue||(this.queue=[])).push(t),this}start(t,e){let n;return r.s.und(t)?(n=this.queue||[],this.queue=[]):n=[r.s.obj(t)?t:o({},e,{to:t})],Promise.all(n.map(t=>this._update(t))).then(t=>T(this,t))}stop(t){const{to:e}=this.animation;return this._focus(this.get()),z(this._state,t&&this._lastCallId),r.w.batchedUpdates(()=>this._stop(e,t)),this}reset(){this._update({reset:!0})}eventObserved(t){"change"==t.type?this._start():"priority"==t.type&&(this.priority=t.priority+1)}_prepareNode(t){const e=this.key||"";let{to:n,from:s}=t;n=r.s.obj(n)?n[e]:n,(null==n||y(n))&&(n=void 0),s=r.s.obj(s)?s[e]:s,null==s&&(s=void 0);const o={to:n,from:s};return G(this)||(t.reverse&&([n,s]=[s,n]),s=Object(r.q)(s),r.s.und(s)?Object(i.e)(this)||this._set(n):this._set(s)),o}_update(t,e){let n=o({},t);const{key:s,defaultProps:i}=this;n.default&&Object.assign(i,f(n,(t,e)=>/^on/.test(e)?u(t,s):t)),st(this,n,"onProps"),it(this,"onProps",n,this);const a=this._prepareNode(n);if(Object.isFrozen(this))throw Error("Cannot animate a `SpringValue` object that is frozen. Did you forget to pass your component to `animated(...)` before animating its props?");const c=this._state;return R(++this._lastCallId,{key:s,props:n,defaultProps:i,state:c,actions:{pause:()=>{W(this)||(Y(this,!0),Object(r.n)(c.pauseQueue),it(this,"onPause",N(this,K(this,this.animation.to)),this))},resume:()=>{W(this)&&(Y(this,!1),H(this)&&this._resume(),Object(r.n)(c.resumeQueue),it(this,"onResume",N(this,K(this,this.animation.to)),this))},start:this._merge.bind(this,a)}}).then(t=>{if(n.loop&&t.finished&&(!e||!t.noop)){const t=X(n);if(t)return this._update(t,!0)}return t})}_merge(t,e,n){if(e.cancel)return this.stop(!0),n(q(this));const s=!r.s.und(t.to),u=!r.s.und(t.from);if(s||u){if(!(e.callId>this._lastToId))return n(q(this));this._lastToId=e.callId}const{key:l,defaultProps:d,animation:f}=this,{to:h,from:p}=f;let{to:m=h,from:g=p}=t;!u||s||e.default&&!r.s.und(m)||(m=g),e.reverse&&([m,g]=[g,m]);const O=!Object(r.u)(g,p);O&&(f.from=g),g=Object(r.q)(g);const v=!Object(r.u)(m,h);v&&this._focus(m);const j=y(e.to),{config:w}=f,{decay:_,velocity:k}=w;(s||u)&&(w.velocity=0),e.config&&!j&&function(t,e,n){n&&(A(n=o({},n),e),e=o({},n,e)),A(t,e),Object.assign(t,e);for(const e in P)null==t[e]&&(t[e]=P[e]);let{mass:s,frequency:i,damping:a}=t;r.s.und(i)||(i<.01&&(i=.01),a<0&&(a=0),t.tension=Math.pow(2*Math.PI/i,2)*s,t.friction=4*Math.PI*a*s/i)}(w,a(e.config,l),e.config!==d.config?a(d.config,l):void 0);let x=Object(i.e)(this);if(!x||r.s.und(m))return n(N(this,!0));const E=r.s.und(e.reset)?u&&!e.default:!r.s.und(g)&&c(e.reset,l),S=E?g:this.get(),M=b(m),I=r.s.num(M)||r.s.arr(M)||Object(r.t)(M),C=!j&&(!I||c(d.immediate||e.immediate,l));if(v){const t=Object(i.f)(m);if(t!==x.constructor){if(!C)throw Error(`Cannot animate between ${x.constructor.name} and ${t.name}, as the "to" prop suggests`);x=this._set(M)}}const R=x.constructor;let T=Object(r.r)(m),z=!1;if(!T){const t=E||!G(this)&&O;(v||t)&&(z=Object(r.u)(b(S),M),T=!z),(Object(r.u)(f.immediate,C)||C)&&Object(r.u)(w.decay,_)&&Object(r.u)(w.velocity,k)||(T=!0)}if(z&&H(this)&&(f.changed&&!E?T=!0:T||this._stop(h)),!j&&((T||Object(r.r)(h))&&(f.values=x.getPayload(),f.toValues=Object(r.r)(m)?null:R==i.b?[1]:Object(r.y)(M)),f.immediate!=C&&(f.immediate=C,C||E||this._set(h)),T)){const{onRest:t}=f;Object(r.k)(rt,t=>st(this,e,t));const s=N(this,K(this,h));Object(r.n)(this._pendingCalls,s),this._pendingCalls.add(n),f.changed&&r.w.batchedUpdates(()=>{f.changed=!E,null==t||t(s,this),E?a(d.onRest,s):null==f.onStart||f.onStart(s,this)})}E&&this._set(S),j?n(D(e.to,e,this._state,this)):T?this._start():H(this)&&!v?this._pendingCalls.add(n):n(V(S))}_focus(t){const e=this.animation;t!==e.to&&(Object(r.p)(this)&&this._detach(),e.to=t,Object(r.p)(this)&&this._attach())}_attach(){let t=0;const{to:e}=this.animation;Object(r.r)(e)&&(Object(r.c)(e,this),U(e)&&(t=e.priority+1)),this.priority=t}_detach(){const{to:t}=this.animation;Object(r.r)(t)&&Object(r.x)(t,this)}_set(t,e=!0){const n=Object(r.q)(t);if(!r.s.und(n)){const t=Object(i.e)(this);if(!t||!Object(r.u)(n,t.getValue())){const s=Object(i.f)(n);t&&t.constructor==s?t.setValue(n):Object(i.h)(this,s.create(n)),t&&r.w.batchedUpdates(()=>{this._onChange(n,e)})}}return Object(i.e)(this)}_onStart(){const t=this.animation;t.changed||(t.changed=!0,it(this,"onStart",N(this,K(this,t.to)),this))}_onChange(t,e){e||(this._onStart(),a(this.animation.onChange,t,this)),a(this.defaultProps.onChange,t,this),super._onChange(t,e)}_start(){const t=this.animation;Object(i.e)(this).reset(Object(r.q)(t.to)),t.immediate||(t.fromValues=t.values.map(t=>t.lastPosition)),H(this)||(Z(this,!0),W(this)||this._resume())}_resume(){r.b.skipAnimation?this.finish():r.o.start(this)}_stop(t,e){if(H(this)){Z(this,!1);const n=this.animation;Object(r.k)(n.values,t=>{t.done=!0}),n.toValues&&(n.onChange=n.onPause=n.onResume=void 0),Object(r.d)(this,{type:"idle",parent:this});const s=e?q(this.get()):N(this.get(),K(this,null!=t?t:n.to));Object(r.n)(this._pendingCalls,s),n.changed&&(n.changed=!1,it(this,"onRest",s,this))}}}function K(t,e){const n=b(e),s=b(t.get());return Object(r.u)(s,n)}function X(t,e=t.loop,n=t.to){let r=a(e);if(r){const s=!0!==r&&m(r),i=(s||t).reverse,a=!s||s.reset;return tt(o({},t,{loop:e,default:!1,pause:void 0,to:!i||y(n)?n:void 0,from:a?t.from:void 0,reset:a},s))}}function tt(t){const{to:e,from:n}=t=m(t),s=new Set;return r.s.obj(e)&&nt(e,s),r.s.obj(n)&&nt(n,s),t.keys=s.size?Array.from(s):null,t}function et(t){const e=tt(t);return r.s.und(e.default)&&(e.default=f(e)),e}function nt(t,e){Object(r.l)(t,(t,n)=>null!=t&&e.add(n))}const rt=["onStart","onRest","onChange","onPause","onResume"];function st(t,e,n){t.animation[n]=e[n]!==l(e,n)?u(e[n],t.key):void 0}function it(t,e,...n){var r,s,i,o;null==(r=(s=t.animation)[e])||r.call(s,...n),null==(i=(o=t.defaultProps)[e])||i.call(o,...n)}const ot=["onStart","onChange","onRest"];let at=1;class ct{constructor(t,e){this.id=at++,this.springs={},this.queue=[],this.ref=void 0,this._flush=void 0,this._initialProps=void 0,this._lastAsyncId=0,this._active=new Set,this._changed=new Set,this._started=!1,this._item=void 0,this._state={paused:!1,pauseQueue:new Set,resumeQueue:new Set,timeouts:new Set},this._events={onStart:new Map,onChange:new Map,onRest:new Map},this._onFrame=this._onFrame.bind(this),e&&(this._flush=e),t&&this.start(o({default:!0},t))}get idle(){return!this._state.asyncTo&&Object.values(this.springs).every(t=>t.idle&&!t.isDelayed&&!t.isPaused)}get item(){return this._item}set item(t){this._item=t}get(){const t={};return this.each((e,n)=>t[n]=e.get()),t}set(t){for(const e in t){const n=t[e];r.s.und(n)||this.springs[e].set(n)}}update(t){return t&&this.queue.push(tt(t)),this}start(t){let{queue:e}=this;return t?e=Object(r.y)(t).map(tt):this.queue=[],this._flush?this._flush(this,e):(pt(this,e),ut(this,e))}stop(t,e){if(t!==!!t&&(e=t),e){const n=this.springs;Object(r.k)(Object(r.y)(e),e=>n[e].stop(!!t))}else z(this._state,this._lastAsyncId),this.each(e=>e.stop(!!t));return this}pause(t){if(r.s.und(t))this.start({pause:!0});else{const e=this.springs;Object(r.k)(Object(r.y)(t),t=>e[t].pause())}return this}resume(t){if(r.s.und(t))this.start({pause:!1});else{const e=this.springs;Object(r.k)(Object(r.y)(t),t=>e[t].resume())}return this}each(t){Object(r.l)(this.springs,t)}_onFrame(){const{onStart:t,onChange:e,onRest:n}=this._events,s=this._active.size>0,i=this._changed.size>0;(s&&!this._started||i&&!this._started)&&(this._started=!0,Object(r.m)(t,([t,e])=>{e.value=this.get(),t(e,this,this._item)}));const o=!s&&this._started,a=i||o&&n.size?this.get():null;i&&e.size&&Object(r.m)(e,([t,e])=>{e.value=a,t(e,this,this._item)}),o&&(this._started=!1,Object(r.m)(n,([t,e])=>{e.value=a,t(e,this,this._item)}))}eventObserved(t){if("change"==t.type)this._changed.add(t.parent),t.idle||this._active.add(t.parent);else{if("idle"!=t.type)return;this._active.delete(t.parent)}r.w.onFrame(this._onFrame)}}function ut(t,e){return Promise.all(e.map(e=>async function t(e,n,s){const{keys:i,to:o,from:a,loop:c,onRest:u,onResolve:d}=n,f=r.s.obj(n.default)&&n.default;c&&(n.loop=!1),!1===o&&(n.to=null),!1===a&&(n.from=null);const h=r.s.arr(o)||r.s.fun(o)?o:void 0;h?(n.to=void 0,n.onRest=void 0,f&&(f.onRest=void 0)):Object(r.k)(ot,t=>{const s=n[t];if(r.s.fun(s)){const r=e._events[t];n[t]=({finished:t,cancelled:e})=>{const n=r.get(s);n?(t||(n.finished=!1),e&&(n.cancelled=!0)):r.set(s,{value:null,finished:t||!1,cancelled:e||!1})},f&&(f[t]=n[t])}});const p=e._state;n.pause===!p.paused?(p.paused=n.pause,Object(r.n)(n.pause?p.pauseQueue:p.resumeQueue)):p.paused&&(n.pause=!0);const m=(i||Object.keys(e.springs)).map(t=>e.springs[t].start(n)),b=!0===n.cancel||!0===l(n,"cancel");(h||b&&p.asyncId)&&m.push(R(++e._lastAsyncId,{props:n,state:p,actions:{pause:r.v,resume:r.v,start(t,n){b?(z(p,e._lastAsyncId),n(q(e))):(t.onRest=u,n(D(h,t,p,e)))}}})),p.paused&&await new Promise(t=>{p.resumeQueue.add(t)});const g=T(e,await Promise.all(m));if(c&&g.finished&&(!s||!g.noop)){const r=X(n,c,o);if(r)return pt(e,[r]),t(e,r,!0)}return d&&r.w.batchedUpdates(()=>d(g,e,e.item)),g}(t,e))).then(e=>T(t,e))}function lt(t,e){const n=o({},t.springs);return e&&Object(r.k)(Object(r.y)(e),t=>{r.s.und(t.keys)&&(t=tt(t)),r.s.obj(t.to)||(t=o({},t,{to:void 0})),ht(n,t,t=>ft(t))}),dt(t,n),n}function dt(t,e){Object(r.l)(e,(e,n)=>{t.springs[n]||(t.springs[n]=e,Object(r.c)(e,t))})}function ft(t,e){const n=new J;return n.key=t,e&&Object(r.c)(n,e),n}function ht(t,e,n){e.keys&&Object(r.k)(e.keys,r=>{(t[r]||(t[r]=n(r)))._prepareNode(e)})}function pt(t,e){Object(r.k)(e,e=>{ht(t.springs,e,e=>ft(e,t))})}const mt=["children"],bt=t=>{let{children:e}=t,n=function(t,e){if(null==t)return{};var n,r,s={},i=Object.keys(t);for(r=0;r=0||(s[n]=t[n]);return s}(t,mt);const i=Object(s.useContext)(gt),o=n.pause||!!i.pause,a=n.immediate||!!i.immediate;n=Object(r.B)(()=>({pause:o,immediate:a}),[o,a]);const{Provider:c}=gt;return s.createElement(c,{value:n},e)},gt=(yt=bt,Ot={},Object.assign(yt,s.createContext(Ot)),yt.Provider._context=yt,yt.Consumer._context=yt,yt);var yt,Ot;bt.Provider=gt.Provider,bt.Consumer=gt.Consumer;const vt=()=>{const t=[],e=function(e){Object(r.i)();const s=[];return Object(r.k)(t,(t,i)=>{if(r.s.und(e))s.push(t.start());else{const r=n(e,t,i);r&&s.push(t.start(r))}}),s};e.current=t,e.add=function(e){t.includes(e)||t.push(e)},e.delete=function(e){const n=t.indexOf(e);~n&&t.splice(n,1)},e.pause=function(){return Object(r.k)(t,t=>t.pause(...arguments)),this},e.resume=function(){return Object(r.k)(t,t=>t.resume(...arguments)),this},e.set=function(e){Object(r.k)(t,t=>t.set(e))},e.start=function(e){const n=[];return Object(r.k)(t,(t,s)=>{if(r.s.und(e))n.push(t.start());else{const r=this._getProps(e,t,s);r&&n.push(t.start(r))}}),n},e.stop=function(){return Object(r.k)(t,t=>t.stop(...arguments)),this},e.update=function(e){return Object(r.k)(t,(t,n)=>t.update(this._getProps(e,t,n))),this};const n=function(t,e,n){return r.s.fun(t)?t(n,e):t};return e._getProps=n,e};function jt(t,e,n){const i=r.s.fun(e)&&e;i&&!n&&(n=[]);const a=Object(s.useMemo)(()=>i||3==arguments.length?vt():void 0,[]),c=Object(s.useRef)(0),u=Object(r.z)(),l=Object(s.useMemo)(()=>({ctrls:[],queue:[],flush(t,e){const n=lt(t,e);return c.current>0&&!l.queue.length&&!Object.keys(n).some(e=>!t.springs[e])?ut(t,e):new Promise(r=>{dt(t,n),l.queue.push(()=>{r(ut(t,e))}),u()})}}),[]),d=Object(s.useRef)([...l.ctrls]),f=[],h=Object(r.D)(t)||0;function p(t,n){for(let r=t;r{Object(r.k)(d.current.slice(t,h),t=>{O(t,a),t.stop(!0)}),d.current.length=t,p(h,t)},[t]),Object(s.useMemo)(()=>{p(0,Math.min(h,t))},n);const m=d.current.map((t,e)=>lt(t,f[e])),b=Object(s.useContext)(bt),y=Object(r.D)(b),j=b!==y&&g(b);Object(r.A)(()=>{c.current++,l.ctrls=d.current;const{queue:t}=l;t.length&&(l.queue=[],Object(r.k)(t,t=>t())),Object(r.k)(d.current,(t,e)=>{null==a||a.add(t),j&&t.start({default:b});const n=f[e];n&&(v(t,n.ref),t.ref?t.queue.push(n):t.start(n))})}),Object(r.C)(()=>()=>{Object(r.k)(l.ctrls,t=>t.stop(!0))});const w=m.map(t=>o({},t));return a?[w,a]:w}function wt(t,e){const n=r.s.fun(t),[[s],i]=jt(1,n?t:[t],n?e||[]:e);return n||2==arguments.length?[s,i]:s}let _t;function kt(t,e,n){const i=r.s.fun(e)&&e,{reset:c,sort:u,trail:l=0,expires:d=!0,exitBeforeEnter:h=!1,onDestroyed:p,ref:b,config:y}=i?i():e,j=Object(s.useMemo)(()=>i||3==arguments.length?vt():void 0,[]),w=Object(r.y)(t),_=[],k=Object(s.useRef)(null),x=c?null:k.current;Object(r.A)(()=>{k.current=_}),Object(r.C)(()=>()=>{Object(r.k)(k.current,t=>{t.expired&&clearTimeout(t.expirationId),O(t.ctrl,j),t.ctrl.stop(!0)})});const E=Et(w,i?i():e,x),S=c&&k.current||[];Object(r.A)(()=>Object(r.k)(S,({ctrl:t,item:e,key:n})=>{O(t,j),a(p,e,n)}));const P=[];if(x&&Object(r.k)(x,(t,e)=>{t.expired?(clearTimeout(t.expirationId),S.push(t)):~(e=P[e]=E.indexOf(t.key))&&(_[e]=t)}),Object(r.k)(w,(t,e)=>{_[e]||(_[e]={key:E[e],item:t,phase:_t.MOUNT,ctrl:new ct},_[e].ctrl.item=t)}),P.length){let t=-1;const{leave:n}=i?i():e;Object(r.k)(P,(e,r)=>{const s=x[r];~e?(t=_.indexOf(s),_[t]=o({},s,{item:w[e]})):n&&_.splice(++t,0,s)})}r.s.fun(u)&&_.sort((t,e)=>u(t.item,e.item));let M=-l;const A=Object(r.z)(),I=f(e),C=new Map,R=Object(s.useRef)(new Map),T=Object(s.useRef)(!1);Object(r.k)(_,(t,n)=>{const s=t.key,c=t.phase,u=i?i():e;let f,p,g=a(u.delay||0,s);if(c==_t.MOUNT)f=u.enter,p=_t.ENTER;else{const t=E.indexOf(s)<0;if(c!=_t.LEAVE)if(t)f=u.leave,p=_t.LEAVE;else{if(!(f=u.update))return;p=_t.UPDATE}else{if(t)return;f=u.enter,p=_t.ENTER}}if(f=a(f,t.item,n),f=r.s.obj(f)?m(f):{to:f},!f.config){const e=y||I.config;f.config=a(e,t.item,n,p)}M+=l;const O=o({},I,{delay:g+M,ref:b,immediate:u.immediate,reset:!1},f);if(p==_t.ENTER&&r.s.und(O.from)){const s=i?i():e,o=r.s.und(s.initial)||x?s.from:s.initial;O.from=a(o,t.item,n)}const{onResolve:v}=O;O.onResolve=t=>{a(v,t);const e=k.current,n=e.find(t=>t.key===s);if(n&&(!t.cancelled||n.phase==_t.UPDATE)&&n.ctrl.idle){const t=e.every(t=>t.ctrl.idle);if(n.phase==_t.LEAVE){const e=a(d,n.item);if(!1!==e){const r=!0===e?0:e;if(n.expired=!0,!t&&r>0)return void(r<=2147483647&&(n.expirationId=setTimeout(A,r)))}}t&&e.some(t=>t.expired)&&(R.current.delete(n),h&&(T.current=!0),A())}};const j=lt(t.ctrl,O);p===_t.LEAVE&&h?R.current.set(t,{phase:p,springs:j,payload:O}):C.set(t,{phase:p,springs:j,payload:O})});const V=Object(s.useContext)(bt),N=Object(r.D)(V),q=V!==N&&g(V);Object(r.A)(()=>{q&&Object(r.k)(_,t=>{t.ctrl.start({default:V})})},[V]),Object(r.k)(C,(t,e)=>{if(R.current.size){const t=_.findIndex(t=>t.key===e.key);_.splice(t,1)}}),Object(r.A)(()=>{Object(r.k)(R.current.size?R.current:C,({phase:t,payload:e},n)=>{const{ctrl:r}=n;n.phase=t,null==j||j.add(r),q&&t==_t.ENTER&&r.start({default:V}),e&&(v(r,e.ref),r.ref&&!T.current?r.update(e):(r.start(e),T.current&&(T.current=!1)))})},c?void 0:n);const D=t=>s.createElement(s.Fragment,null,_.map((e,n)=>{const{springs:i}=C.get(e)||e.ctrl,a=t(o({},i),e.item,e,n);return a&&a.type?s.createElement(a.type,o({},a.props,{key:r.s.str(e.key)||r.s.num(e.key)?e.key:e.ctrl.id,ref:a.ref})):a}));return j?[D,j]:D}!function(t){t.MOUNT="mount",t.ENTER="enter",t.UPDATE="update",t.LEAVE="leave"}(_t||(_t={}));let xt=1;function Et(t,{key:e,keys:n=e},s){if(null===n){const e=new Set;return t.map(t=>{const n=s&&s.find(n=>n.item===t&&n.phase!==_t.LEAVE&&!e.has(n));return n?(e.add(n),n.key):xt++})}return r.s.und(n)?t:r.s.fun(n)?t.map(n):Object(r.y)(n)}class St extends Q{constructor(t,e){super(),this.key=void 0,this.idle=!0,this.calc=void 0,this._active=new Set,this.source=t,this.calc=Object(r.f)(...e);const n=this._get(),s=Object(i.f)(n);Object(i.h)(this,s.create(n))}advance(t){const e=this._get(),n=this.get();Object(r.u)(e,n)||(Object(i.e)(this).setValue(e),this._onChange(e,this.idle)),!this.idle&&Mt(this._active)&&At(this)}_get(){const t=r.s.arr(this.source)?this.source.map(r.q):Object(r.y)(Object(r.q)(this.source));return this.calc(...t)}_start(){this.idle&&!Mt(this._active)&&(this.idle=!1,Object(r.k)(Object(i.g)(this),t=>{t.done=!1}),r.b.skipAnimation?(r.w.batchedUpdates(()=>this.advance()),At(this)):r.o.start(this))}_attach(){let t=1;Object(r.k)(Object(r.y)(this.source),e=>{Object(r.r)(e)&&Object(r.c)(e,this),U(e)&&(e.idle||this._active.add(e),t=Math.max(t,e.priority+1))}),this.priority=t,this._start()}_detach(){Object(r.k)(Object(r.y)(this.source),t=>{Object(r.r)(t)&&Object(r.x)(t,this)}),this._active.clear(),At(this)}eventObserved(t){"change"==t.type?t.idle?this.advance():(this._active.add(t.parent),this._start()):"idle"==t.type?this._active.delete(t.parent):"priority"==t.type&&(this.priority=Object(r.y)(this.source).reduce((t,e)=>Math.max(t,(U(e)?e.priority:0)+1),0))}}function Pt(t){return!1!==t.idle}function Mt(t){return!t.size||Array.from(t).every(Pt)}function At(t){t.idle||(t.idle=!0,Object(r.k)(Object(i.g)(t),t=>{t.done=!0}),Object(r.d)(t,{type:"idle",parent:t}))}r.b.assign({createStringInterpolator:r.g,to:(t,e)=>new St(t,e)}),r.o.advance},,function(t,e){t.exports=window.regeneratorRuntime},,function(t,e,n){"use strict";n.d(e,"animated",(function(){return _}));var r=n(34);n.o(r,"config")&&n.d(e,"config",(function(){return r.config})),n.o(r,"useSpring")&&n.d(e,"useSpring",(function(){return r.useSpring})),n.o(r,"useTransition")&&n.d(e,"useTransition",(function(){return r.useTransition}));var s=n(45),i=n(1),o=n(10);function a(t,e){if(null==t)return{};var n,r,s={},i=Object.keys(t);for(r=0;r=0||(s[n]=t[n]);return s}const c=["style","children","scrollTop","scrollLeft"],u=/^--/;function l(t,e){return null==e||"boolean"==typeof e||""===e?"":"number"!=typeof e||0===e||u.test(t)||f.hasOwnProperty(t)&&f[t]?(""+e).trim():e+"px"}const d={};let f={animationIterationCount:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0};const h=["Webkit","Ms","Moz","O"];f=Object.keys(f).reduce((t,e)=>(h.forEach(n=>t[((t,e)=>t+e.charAt(0).toUpperCase()+e.substring(1))(n,e)]=t[e]),t),f);const p=["x","y","z"],m=/^(matrix|translate|scale|rotate|skew)/,b=/^(translate)/,g=/^(rotate|skew)/,y=(t,e)=>i.s.num(t)&&0!==t?t+e:t,O=(t,e)=>i.s.arr(t)?t.every(t=>O(t,e)):i.s.num(t)?t===e:parseFloat(t)===e;class v extends o.a{constructor(t){let{x:e,y:n,z:r}=t,s=a(t,p);const o=[],c=[];(e||n||r)&&(o.push([e||0,n||0,r||0]),c.push(t=>[`translate3d(${t.map(t=>y(t,"px")).join(",")})`,O(t,0)])),Object(i.l)(s,(t,e)=>{if("transform"===e)o.push([t||""]),c.push(t=>[t,""===t]);else if(m.test(e)){if(delete s[e],i.s.und(t))return;const n=b.test(e)?"px":g.test(e)?"deg":"";o.push(Object(i.y)(t)),c.push("rotate3d"===e?([t,e,r,s])=>[`rotate3d(${t},${e},${r},${y(s,n)})`,O(s,0)]:t=>[`${e}(${t.map(t=>y(t,n)).join(",")})`,O(t,e.startsWith("scale")?1:0)])}}),o.length&&(s.transform=new j(o,c)),super(s)}}class j extends i.a{constructor(t,e){super(),this._value=null,this.inputs=t,this.transforms=e}get(){return this._value||(this._value=this._get())}_get(){let t="",e=!0;return Object(i.k)(this.inputs,(n,r)=>{const s=Object(i.q)(n[0]),[o,a]=this.transforms[r](i.s.arr(s)?s:n.map(i.q));t+=" "+o,e=e&&a}),e?"none":t}observerAdded(t){1==t&&Object(i.k)(this.inputs,t=>Object(i.k)(t,t=>Object(i.r)(t)&&Object(i.c)(t,this)))}observerRemoved(t){0==t&&Object(i.k)(this.inputs,t=>Object(i.k)(t,t=>Object(i.r)(t)&&Object(i.x)(t,this)))}eventObserved(t){"change"==t.type&&(this._value=null),Object(i.d)(this,t)}}const w=["scrollTop","scrollLeft"];r.Globals.assign({batchedUpdates:s.unstable_batchedUpdates,createStringInterpolator:i.g,colors:i.e});const _=Object(o.d)(["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"],{applyAnimatedValues:function(t,e){if(!t.nodeType||!t.setAttribute)return!1;const n="filter"===t.nodeName||t.parentNode&&"filter"===t.parentNode.nodeName,r=e,{style:s,children:i,scrollTop:o,scrollLeft:f}=r,h=a(r,c),p=Object.values(h),m=Object.keys(h).map(e=>n||t.hasAttribute(e)?e:d[e]||(d[e]=e.replace(/([A-Z])/g,t=>"-"+t.toLowerCase())));void 0!==i&&(t.textContent=i);for(let e in s)if(s.hasOwnProperty(e)){const n=l(e,s[e]);u.test(e)?t.style.setProperty(e,n):t.style[e]=n}m.forEach((e,n)=>{t.setAttribute(e,p[n])}),void 0!==o&&(t.scrollTop=o),void 0!==f&&(t.scrollLeft=f)},createAnimatedStyle:t=>new v(t),getComponentProps:t=>a(t,w)}).animated},function(t,e){},function(t,e){},,,,,function(t,e){t.exports=window.ReactDOM},function(t,e){t.exports=window.moment},function(t,e){t.exports=window.wp.autop},function(t,e){function n(t,e,n,r,s,i,o){try{var a=t[i](o),c=a.value}catch(t){return void n(t)}a.done?e(c):Promise.resolve(c).then(r,s)}t.exports=function(t){return function(){var e=this,r=arguments;return new Promise((function(s,i){var o=t.apply(e,r);function a(t){n(o,s,i,a,c,"next",t)}function c(t){n(o,s,i,a,c,"throw",t)}a(void 0)}))}},t.exports.__esModule=!0,t.exports.default=t.exports},,,,,,,,,,,function(t,e,n){"use strict";var r=n(0),s=n(6);const i=Object(r.createElement)(s.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(s.Path,{d:"M13 11.8l6.1-6.3-1-1-6.1 6.2-6.1-6.2-1 1 6.1 6.3-6.5 6.7 1 1 6.5-6.6 6.5 6.6 1-1z"}));e.a=i},,,,,,,,,,,function(t,e,n){"use strict";n.r(e);var r=n(5),s=n.n(r),i=n(0),o=n(23),a=n.n(o),c=n(32),u=n(7),l=n(13),d=n.n(l);function f(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function h(t){for(var e=1;e0&&Object(i.createElement)(m.animated.span,{style:r,className:"simpay-branding-bar__actions-button-count","aria-label":Object(b.sprintf)( +!function(t){var e={};function n(r){if(e[r])return e[r].exports;var s=e[r]={i:r,l:!1,exports:{}};return t[r].call(s.exports,s,s.exports,n),s.l=!0,s.exports}n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var s in t)n.d(r,s,function(e){return t[e]}.bind(null,s));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=70)}([function(t,e){t.exports=window.wp.element},function(t,e,n){"use strict";n.d(e,"w",(function(){return s})),n.d(e,"a",(function(){return Ot})),n.d(e,"b",(function(){return q})),n.d(e,"c",(function(){return jt})),n.d(e,"d",(function(){return yt})),n.d(e,"e",(function(){return H})),n.d(e,"f",(function(){return dt})),n.d(e,"g",(function(){return Rt})),n.d(e,"h",(function(){return _})),n.d(e,"i",(function(){return zt})),n.d(e,"j",(function(){return qt})),n.d(e,"k",(function(){return E})),n.d(e,"l",(function(){return S})),n.d(e,"m",(function(){return M})),n.d(e,"n",(function(){return A})),n.d(e,"o",(function(){return U})),n.d(e,"p",(function(){return gt})),n.d(e,"q",(function(){return bt})),n.d(e,"r",(function(){return mt})),n.d(e,"s",(function(){return k})),n.d(e,"t",(function(){return Lt})),n.d(e,"u",(function(){return x})),n.d(e,"v",(function(){return w})),n.d(e,"x",(function(){return wt})),n.d(e,"y",(function(){return P})),n.d(e,"z",(function(){return $t})),n.d(e,"A",(function(){return Ht})),n.d(e,"B",(function(){return Bt})),n.d(e,"C",(function(){return Ft})),n.d(e,"D",(function(){return Gt}));let r=O();const s=t=>m(t,r);let i=O();s.write=t=>m(t,i);let o=O();s.onStart=t=>m(t,o);let a=O();s.onFrame=t=>m(t,a);let c=O();s.onFinish=t=>m(t,c);let u=[];s.setTimeout=(t,e)=>{let n=s.now()+e,r=()=>{let t=u.findIndex(t=>t.cancel==r);~t&&u.splice(t,1),h-=~t?1:0},i={time:n,handler:t,cancel:r};return u.splice(l(n),0,i),h+=1,b(),i};let l=t=>~(~u.findIndex(e=>e.time>t)||~u.length);s.cancel=t=>{o.delete(t),a.delete(t),r.delete(t),i.delete(t),c.delete(t)},s.sync=t=>{p=!0,s.batchedUpdates(t),p=!1},s.throttle=t=>{let e;function n(){try{t(...e)}finally{e=null}}function r(...t){e=t,s.onStart(n)}return r.handler=t,r.cancel=()=>{o.delete(n),e=null},r};let d="undefined"!=typeof window?window.requestAnimationFrame:()=>{};s.use=t=>d=t,s.now="undefined"!=typeof performance?()=>performance.now():Date.now,s.batchedUpdates=t=>t(),s.catch=console.error,s.frameLoop="always",s.advance=()=>{"demand"!==s.frameLoop?console.warn("Cannot call the manual advancement of rafz whilst frameLoop is not set as demand"):y()};let f=-1,h=0,p=!1;function m(t,e){p?(e.delete(t),t(0)):(e.add(t),b())}function b(){f<0&&(f=0,"demand"!==s.frameLoop&&d(g))}function g(){~f&&(d(g),s.batchedUpdates(y))}function y(){let t=f;f=s.now();let e=l(f);e&&(v(u.splice(0,e),t=>t.handler()),h-=e),o.flush(),r.flush(t?Math.min(64,f-t):16.667),a.flush(),i.flush(),c.flush(),h||(f=-1)}function O(){let t=new Set,e=t;return{add(n){h+=e!=t||t.has(n)?0:1,t.add(n)},delete:n=>(h-=e==t&&t.has(n)?1:0,t.delete(n)),flush(n){e.size&&(t=new Set,h-=e.size,v(e,e=>e(n)&&t.add(e)),h+=t.size,e=t)}}}function v(t,e){t.forEach(t=>{try{e(t)}catch(t){s.catch(t)}})}var j=n(4);function w(){}const _=(t,e,n)=>Object.defineProperty(t,e,{value:n,writable:!0,configurable:!0}),k={arr:Array.isArray,obj:t=>!!t&&"Object"===t.constructor.name,fun:t=>"function"==typeof t,str:t=>"string"==typeof t,num:t=>"number"==typeof t,und:t=>void 0===t};function x(t,e){if(k.arr(t)){if(!k.arr(e)||t.length!==e.length)return!1;for(let n=0;nt.forEach(e);function S(t,e,n){if(k.arr(t))for(let r=0;rk.und(t)?[]:k.arr(t)?t:[t];function M(t,e){if(t.size){const n=Array.from(t);t.clear(),E(n,e)}}const A=(t,...e)=>M(t,t=>t(...e)),I=()=>"undefined"==typeof window||!window.navigator||/ServerSideRendering|^Deno\//.test(window.navigator.userAgent);let C,R,T=null,V=!1,N=w;var q=Object.freeze({__proto__:null,get createStringInterpolator(){return C},get to(){return R},get colors(){return T},get skipAnimation(){return V},get willAdvance(){return N},assign:t=>{t.to&&(R=t.to),t.now&&(s.now=t.now),void 0!==t.colors&&(T=t.colors),null!=t.skipAnimation&&(V=t.skipAnimation),t.createStringInterpolator&&(C=t.createStringInterpolator),t.requestAnimationFrame&&s.use(t.requestAnimationFrame),t.batchedUpdates&&(s.batchedUpdates=t.batchedUpdates),t.willAdvance&&(N=t.willAdvance),t.frameLoop&&(s.frameLoop=t.frameLoop)}});const D=new Set;let z=[],L=[],F=0;const U={get idle(){return!D.size&&!z.length},start(t){F>t.priority?(D.add(t),s.onStart($)):(Q(t),s(G))},advance:G,sort(t){if(F)s.onFrame(()=>U.sort(t));else{const e=z.indexOf(t);~e&&(z.splice(e,1),B(t))}},clear(){z=[],D.clear()}};function $(){D.forEach(Q),D.clear(),s(G)}function Q(t){z.includes(t)||B(t)}function B(t){z.splice(function(e,n){const r=e.findIndex(e=>e.priority>t.priority);return r<0?e.length:r}(z),0,t)}function G(t){const e=L;for(let n=0;n0}const H={transparent:0,aliceblue:4042850303,antiquewhite:4209760255,aqua:16777215,aquamarine:2147472639,azure:4043309055,beige:4126530815,bisque:4293182719,black:255,blanchedalmond:4293643775,blue:65535,blueviolet:2318131967,brown:2771004159,burlywood:3736635391,burntsienna:3934150143,cadetblue:1604231423,chartreuse:2147418367,chocolate:3530104575,coral:4286533887,cornflowerblue:1687547391,cornsilk:4294499583,crimson:3692313855,cyan:16777215,darkblue:35839,darkcyan:9145343,darkgoldenrod:3095792639,darkgray:2846468607,darkgreen:6553855,darkgrey:2846468607,darkkhaki:3182914559,darkmagenta:2332068863,darkolivegreen:1433087999,darkorange:4287365375,darkorchid:2570243327,darkred:2332033279,darksalmon:3918953215,darkseagreen:2411499519,darkslateblue:1211993087,darkslategray:793726975,darkslategrey:793726975,darkturquoise:13554175,darkviolet:2483082239,deeppink:4279538687,deepskyblue:12582911,dimgray:1768516095,dimgrey:1768516095,dodgerblue:512819199,firebrick:2988581631,floralwhite:4294635775,forestgreen:579543807,fuchsia:4278255615,gainsboro:3705462015,ghostwhite:4177068031,gold:4292280575,goldenrod:3668254975,gray:2155905279,green:8388863,greenyellow:2919182335,grey:2155905279,honeydew:4043305215,hotpink:4285117695,indianred:3445382399,indigo:1258324735,ivory:4294963455,khaki:4041641215,lavender:3873897215,lavenderblush:4293981695,lawngreen:2096890111,lemonchiffon:4294626815,lightblue:2916673279,lightcoral:4034953471,lightcyan:3774873599,lightgoldenrodyellow:4210742015,lightgray:3553874943,lightgreen:2431553791,lightgrey:3553874943,lightpink:4290167295,lightsalmon:4288707327,lightseagreen:548580095,lightskyblue:2278488831,lightslategray:2005441023,lightslategrey:2005441023,lightsteelblue:2965692159,lightyellow:4294959359,lime:16711935,limegreen:852308735,linen:4210091775,magenta:4278255615,maroon:2147483903,mediumaquamarine:1724754687,mediumblue:52735,mediumorchid:3126187007,mediumpurple:2473647103,mediumseagreen:1018393087,mediumslateblue:2070474495,mediumspringgreen:16423679,mediumturquoise:1221709055,mediumvioletred:3340076543,midnightblue:421097727,mintcream:4127193855,mistyrose:4293190143,moccasin:4293178879,navajowhite:4292783615,navy:33023,oldlace:4260751103,olive:2155872511,olivedrab:1804477439,orange:4289003775,orangered:4282712319,orchid:3664828159,palegoldenrod:4008225535,palegreen:2566625535,paleturquoise:2951671551,palevioletred:3681588223,papayawhip:4293907967,peachpuff:4292524543,peru:3448061951,pink:4290825215,plum:3718307327,powderblue:2967529215,purple:2147516671,rebeccapurple:1714657791,red:4278190335,rosybrown:3163525119,royalblue:1097458175,saddlebrown:2336560127,salmon:4202722047,sandybrown:4104413439,seagreen:780883967,seashell:4294307583,sienna:2689740287,silver:3233857791,skyblue:2278484991,slateblue:1784335871,slategray:1887473919,slategrey:1887473919,snow:4294638335,springgreen:16744447,steelblue:1182971135,tan:3535047935,teal:8421631,thistle:3636451583,tomato:4284696575,turquoise:1088475391,violet:4001558271,wheat:4125012991,white:4294967295,whitesmoke:4126537215,yellow:4294902015,yellowgreen:2597139199},W="[-+]?\\d*\\.?\\d+";function Z(...t){return"\\(\\s*("+t.join(")\\s*,\\s*(")+")\\s*\\)"}const Y=new RegExp("rgb"+Z(W,W,W)),J=new RegExp("rgba"+Z(W,W,W,W)),K=new RegExp("hsl"+Z(W,"[-+]?\\d*\\.?\\d+%","[-+]?\\d*\\.?\\d+%")),X=new RegExp("hsla"+Z(W,"[-+]?\\d*\\.?\\d+%","[-+]?\\d*\\.?\\d+%",W)),tt=/^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,et=/^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,nt=/^#([0-9a-fA-F]{6})$/,rt=/^#([0-9a-fA-F]{8})$/;function st(t,e,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?t+6*(e-t)*n:n<.5?e:n<2/3?t+(e-t)*(2/3-n)*6:t}function it(t,e,n){const r=n<.5?n*(1+e):n+e-n*e,s=2*n-r,i=st(s,r,t+1/3),o=st(s,r,t),a=st(s,r,t-1/3);return Math.round(255*i)<<24|Math.round(255*o)<<16|Math.round(255*a)<<8}function ot(t){const e=parseInt(t,10);return e<0?0:e>255?255:e}function at(t){return(parseFloat(t)%360+360)%360/360}function ct(t){const e=parseFloat(t);return e<0?0:e>1?255:Math.round(255*e)}function ut(t){const e=parseFloat(t);return e<0?0:e>100?1:e/100}function lt(t){let e=function(t){let e;return"number"==typeof t?t>>>0===t&&t>=0&&t<=4294967295?t:null:(e=nt.exec(t))?parseInt(e[1]+"ff",16)>>>0:T&&void 0!==T[t]?T[t]:(e=Y.exec(t))?(ot(e[1])<<24|ot(e[2])<<16|ot(e[3])<<8|255)>>>0:(e=J.exec(t))?(ot(e[1])<<24|ot(e[2])<<16|ot(e[3])<<8|ct(e[4]))>>>0:(e=tt.exec(t))?parseInt(e[1]+e[1]+e[2]+e[2]+e[3]+e[3]+"ff",16)>>>0:(e=rt.exec(t))?parseInt(e[1],16)>>>0:(e=et.exec(t))?parseInt(e[1]+e[1]+e[2]+e[2]+e[3]+e[3]+e[4]+e[4],16)>>>0:(e=K.exec(t))?(255|it(at(e[1]),ut(e[2]),ut(e[3])))>>>0:(e=X.exec(t))?(it(at(e[1]),ut(e[2]),ut(e[3]))|ct(e[4]))>>>0:null}(t);return null===e?t:(e=e||0,`rgba(${(4278190080&e)>>>24}, ${(16711680&e)>>>16}, ${(65280&e)>>>8}, ${(255&e)/255})`)}const dt=(t,e,n)=>{if(k.fun(t))return t;if(k.arr(t))return dt({range:t,output:e,extrapolate:n});if(k.str(t.output[0]))return C(t);const r=t,s=r.output,i=r.range||[0,1],o=r.extrapolateLeft||r.extrapolate||"extend",a=r.extrapolateRight||r.extrapolate||"extend",c=r.easing||(t=>t);return t=>{const e=function(t,e){for(var n=1;n=t);++n);return n-1}(t,i);return function(t,e,n,r,s,i,o,a,c){let u=c?c(t):t;if(un){if("identity"===a)return u;"clamp"===a&&(u=n)}return r===s?r:e===n?t<=e?r:s:(e===-1/0?u=-u:n===1/0?u-=e:u=(u-e)/(n-e),u=i(u),r===-1/0?u=-u:s===1/0?u+=r:u=u*(s-r)+r,u)}(t,i[e],i[e+1],s[e],s[e+1],c,o,a,r.map)}};function ft(){return(ft=Object.assign||function(t){for(var e=1;eBoolean(t&&t[ht]),bt=t=>t&&t[ht]?t[ht]():t,gt=t=>t[pt]||null;function yt(t,e){let n=t[pt];n&&n.forEach(t=>{!function(t,e){t.eventObserved?t.eventObserved(e):t(e)}(t,e)})}class Ot{constructor(t){if(this[ht]=void 0,this[pt]=void 0,!t&&!(t=this.get))throw Error("Unknown getter");vt(this,t)}}const vt=(t,e)=>_t(t,ht,e);function jt(t,e){if(t[ht]){let n=t[pt];n||_t(t,pt,n=new Set),n.has(e)||(n.add(e),t.observerAdded&&t.observerAdded(n.size,e))}return e}function wt(t,e){let n=t[pt];if(n&&n.has(e)){const r=n.size-1;r?n.delete(e):t[pt]=null,t.observerRemoved&&t.observerRemoved(r,e)}}const _t=(t,e,n)=>Object.defineProperty(t,e,{value:n,writable:!0,configurable:!0}),kt=/[+\-]?(?:0|[1-9]\d*)(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,xt=/(#(?:[0-9a-f]{2}){2,4}|(#[0-9a-f]{3})|(rgb|hsl)a?\((-?\d+%?[,\s]+){2,3}\s*[\d\.]+%?\))/gi,Et=new RegExp(`(${kt.source})(%|[a-z]+)`,"i"),St=/rgba\(([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+), ([0-9\.-]+)\)/gi,Pt=/var\((--[a-zA-Z0-9-_]+),? ?([a-zA-Z0-9 ()%#.,-]+)?\)/,Mt=t=>{const[e,n]=At(t);if(!e||I())return t;const r=window.getComputedStyle(document.documentElement).getPropertyValue(e);if(r)return r.trim();if(n&&n.startsWith("--")){return window.getComputedStyle(document.documentElement).getPropertyValue(n)||t}return n&&Pt.test(n)?Mt(n):n||t},At=t=>{const e=Pt.exec(t);if(!e)return[,];const[,n,r]=e;return[n,r]};let It;const Ct=(t,e,n,r,s)=>`rgba(${Math.round(e)}, ${Math.round(n)}, ${Math.round(r)}, ${s})`,Rt=t=>{It||(It=T?new RegExp(`(${Object.keys(T).join("|")})(?!\\w)`,"g"):/^\b$/);const e=t.output.map(t=>bt(t).replace(Pt,Mt).replace(xt,lt).replace(It,lt)),n=e.map(t=>t.match(kt).map(Number)),r=n[0].map((t,e)=>n.map(t=>{if(!(e in t))throw Error('The arity of each "output" value must be equal');return t[e]})).map(e=>dt(ft({},t,{output:e})));return t=>{var n;const s=!Et.test(e[0])&&(null==(n=e.find(t=>Et.test(t)))?void 0:n.replace(kt,""));let i=0;return e[0].replace(kt,()=>`${r[i++](t)}${s||""}`).replace(St,Ct)}},Tt="react-spring: ",Vt=t=>{const e=t;let n=!1;if("function"!=typeof e)throw new TypeError(Tt+"once requires a function parameter");return(...t)=>{n||(e(...t),n=!0)}},Nt=Vt(console.warn);function qt(){Nt(Tt+'The "interpolate" function is deprecated in v9 (use "to" instead)')}const Dt=Vt(console.warn);function zt(){Dt(Tt+'Directly calling start instead of using the api object is deprecated in v9 (use ".start" instead), this will be removed in later 0.X.0 versions')}function Lt(t){return k.str(t)&&("#"==t[0]||/\d/.test(t)||!I()&&Pt.test(t)||t in(T||{}))}const Ft=t=>Object(j.useEffect)(t,Ut),Ut=[];function $t(){const t=Object(j.useState)()[1],e=Object(j.useState)(Qt)[0];return Ft(e.unmount),()=>{e.current&&t({})}}function Qt(){const t={current:!0,unmount:()=>()=>{t.current=!1}};return t}function Bt(t,e){const[n]=Object(j.useState)(()=>({inputs:e,result:t()})),r=Object(j.useRef)(),s=r.current;let i=s;return i?Boolean(e&&i.inputs&&function(t,e){if(t.length!==e.length)return!1;for(let n=0;n{r.current=i,s==n&&(n.inputs=n.result=void 0)},[i]),i.result}function Gt(t){const e=Object(j.useRef)();return Object(j.useEffect)(()=>{e.current=t}),e.current}const Ht="undefined"!=typeof window&&window.document&&window.document.createElement?j.useLayoutEffect:j.useEffect},function(t,e){t.exports=window.wp.i18n},function(t,e){t.exports=window.wp.components},function(t,e){t.exports=window.React},function(t,e,n){var r=n(20),s=n(21),i=n(16),o=n(22);t.exports=function(t,e){return r(t)||s(t,e)||i(t,e)||o()},t.exports.__esModule=!0,t.exports.default=t.exports},function(t,e){t.exports=window.wp.primitives},function(t,e){t.exports=window.wp.url},function(t,e){t.exports=window.lodash},,function(t,e,n){"use strict";n.d(e,"a",(function(){return h})),n.d(e,"b",(function(){return d})),n.d(e,"c",(function(){return l})),n.d(e,"d",(function(){return j})),n.d(e,"e",(function(){return o})),n.d(e,"f",(function(){return b})),n.d(e,"g",(function(){return c})),n.d(e,"h",(function(){return a}));var r=n(1),s=n(4);const i=Symbol.for("Animated:node"),o=t=>t&&t[i],a=(t,e)=>Object(r.h)(t,i,e),c=t=>t&&t[i]&&t[i].getPayload();class u{constructor(){this.payload=void 0,a(this,this)}getPayload(){return this.payload||[]}}class l extends u{constructor(t){super(),this.done=!0,this.elapsedTime=void 0,this.lastPosition=void 0,this.lastVelocity=void 0,this.v0=void 0,this.durationProgress=0,this._value=t,r.s.num(this._value)&&(this.lastPosition=this._value)}static create(t){return new l(t)}getPayload(){return[this]}getValue(){return this._value}setValue(t,e){return r.s.num(t)&&(this.lastPosition=t,e&&(t=Math.round(t/e)*e,this.done&&(this.lastPosition=t))),this._value!==t&&(this._value=t,!0)}reset(){const{done:t}=this;this.done=!1,r.s.num(this._value)&&(this.elapsedTime=0,this.durationProgress=0,this.lastPosition=this._value,t&&(this.lastVelocity=null),this.v0=null)}}class d extends l{constructor(t){super(0),this._string=null,this._toString=void 0,this._toString=Object(r.f)({output:[t,t]})}static create(t){return new d(t)}getValue(){let t=this._string;return null==t?this._string=this._toString(this._value):t}setValue(t){if(r.s.str(t)){if(t==this._string)return!1;this._string=t,this._value=1}else{if(!super.setValue(t))return!1;this._string=null}return!0}reset(t){t&&(this._toString=Object(r.f)({output:[this.getValue(),t]})),this._value=0,super.reset()}}const f={dependencies:null};class h extends u{constructor(t){super(),this.source=t,this.setValue(t)}getValue(t){const e={};return Object(r.l)(this.source,(n,s)=>{var o;(o=n)&&o[i]===o?e[s]=n.getValue(t):Object(r.r)(n)?e[s]=Object(r.q)(n):t||(e[s]=n)}),e}setValue(t){this.source=t,this.payload=this._makePayload(t)}reset(){this.payload&&Object(r.k)(this.payload,t=>t.reset())}_makePayload(t){if(t){const e=new Set;return Object(r.l)(t,this._addToPayload,e),Array.from(e)}}_addToPayload(t){f.dependencies&&Object(r.r)(t)&&f.dependencies.add(t);const e=c(t);e&&Object(r.k)(e,t=>this.add(t))}}class p extends h{constructor(t){super(t)}static create(t){return new p(t)}getValue(){return this.source.map(t=>t.getValue())}setValue(t){const e=this.getPayload();return t.length==e.length?e.map((e,n)=>e.setValue(t[n])).some(Boolean):(super.setValue(t.map(m)),!0)}}function m(t){return(Object(r.t)(t)?d:l).create(t)}function b(t){const e=o(t);return e?e.constructor:r.s.arr(t)?p:Object(r.t)(t)?d:l}function g(){return(g=Object.assign||function(t){for(var e=1;e{const n=!r.s.fun(t)||t.prototype&&t.prototype.isReactComponent;return Object(s.forwardRef)((i,o)=>{const a=Object(s.useRef)(null),c=n&&Object(s.useCallback)(t=>{a.current=function(t,e){return t&&(r.s.fun(t)?t(e):t.current=e),e}(o,t)},[o]),[u,l]=function(t,e){const n=new Set;return f.dependencies=n,t.style&&(t=g({},t,{style:e.createAnimatedStyle(t.style)})),t=new h(t),f.dependencies=null,[t,n]}(i,e),d=Object(r.z)(),p=()=>{const t=a.current;n&&!t||!1===(!!t&&e.applyAnimatedValues(t,u.getValue(!0)))&&d()},m=new O(p,l),b=Object(s.useRef)();Object(r.A)(()=>{const t=b.current;b.current=m,Object(r.k)(l,t=>Object(r.c)(t,m)),t&&(Object(r.k)(t.deps,e=>Object(r.x)(e,t)),r.w.cancel(t.update))}),Object(s.useEffect)(p,[]),Object(r.C)(()=>()=>{const t=b.current;Object(r.k)(t.deps,e=>Object(r.x)(e,t))});const y=e.getComponentProps(u.getValue());return s.createElement(t,g({},y,{ref:c}))})};class O{constructor(t,e){this.update=t,this.deps=e}eventObserved(t){"change"==t.type&&r.w.write(this.update)}}const v=Symbol.for("AnimatedComponent"),j=(t,{applyAnimatedValues:e=(()=>!1),createAnimatedStyle:n=(t=>new h(t)),getComponentProps:s=(t=>t)}={})=>{const i={applyAnimatedValues:e,createAnimatedStyle:n,getComponentProps:s},o=t=>{const e=w(t)||"Anonymous";return(t=r.s.str(t)?o[t]||(o[t]=y(t,i)):t[v]||(t[v]=y(t,i))).displayName=`Animated(${e})`,t};return Object(r.l)(t,(e,n)=>{r.s.arr(t)&&(n=w(e)),o[n]=o(e)}),{animated:o}},w=t=>r.s.str(t)?t:t&&r.s.str(t.displayName)?t.displayName:r.s.fun(t)&&t.name||null},function(t,e){t.exports=window.wp.compose},,function(t,e,n){var r;!function(){"use strict";var n={}.hasOwnProperty;function s(){for(var t=[],e=0;et.length)&&(e=t.length);for(var n=0,r=new Array(e);n!0===t||!!(e&&t&&(r.s.fun(t)?t(e):Object(r.y)(t).includes(e))),u=(t,e)=>r.s.obj(t)?e&&t[e]:t,l=(t,e)=>!0===t.default?t[e]:t.default?t.default[e]:void 0,d=t=>t,f=(t,e=d)=>{let n=h;t.default&&!0!==t.default&&(t=t.default,n=Object.keys(t));const s={};for(const i of n){const n=e(t[i],i);r.s.und(n)||(s[i]=n)}return s},h=["config","onProps","onStart","onChange","onPause","onResume","onRest"],p={config:1,from:1,to:1,ref:1,loop:1,reset:1,pause:1,cancel:1,reverse:1,immediate:1,default:1,delay:1,onProps:1,onStart:1,onChange:1,onPause:1,onResume:1,onRest:1,onResolve:1,items:1,trail:1,sort:1,expires:1,initial:1,enter:1,update:1,leave:1,children:1,onDestroyed:1,keys:1,callId:1,parentId:1};function m(t){const e=function(t){const e={};let n=0;if(Object(r.l)(t,(t,r)=>{p[r]||(e[r]=t,n++)}),n)return e}(t);if(e){const n={to:e};return Object(r.l)(t,(t,r)=>r in e||(n[r]=t)),n}return o({},t)}function b(t){return t=Object(r.q)(t),r.s.arr(t)?t.map(b):Object(r.t)(t)?r.b.createStringInterpolator({range:[0,1],output:[t,t]})(1):t}function g(t){for(const e in t)return!0;return!1}function y(t){return r.s.fun(t)||r.s.arr(t)&&r.s.obj(t[0])}function O(t,e){var n;null==(n=t.ref)||n.delete(t),null==e||e.delete(t)}function v(t,e){var n;e&&t.ref!==e&&(null==(n=t.ref)||n.delete(t),e.add(t),t.ref=e)}const j={default:{tension:170,friction:26},gentle:{tension:120,friction:14},wobbly:{tension:180,friction:12},stiff:{tension:210,friction:20},slow:{tension:280,friction:60},molasses:{tension:280,friction:120}},w=1.70158,_=1.525*w,k=2*Math.PI/3,x=2*Math.PI/4.5,E=t=>{const e=7.5625,n=2.75;return t<1/n?e*t*t:t<2/n?e*(t-=1.5/n)*t+.75:t<2.5/n?e*(t-=2.25/n)*t+.9375:e*(t-=2.625/n)*t+.984375},S={linear:t=>t,easeInQuad:t=>t*t,easeOutQuad:t=>1-(1-t)*(1-t),easeInOutQuad:t=>t<.5?2*t*t:1-Math.pow(-2*t+2,2)/2,easeInCubic:t=>t*t*t,easeOutCubic:t=>1-Math.pow(1-t,3),easeInOutCubic:t=>t<.5?4*t*t*t:1-Math.pow(-2*t+2,3)/2,easeInQuart:t=>t*t*t*t,easeOutQuart:t=>1-Math.pow(1-t,4),easeInOutQuart:t=>t<.5?8*t*t*t*t:1-Math.pow(-2*t+2,4)/2,easeInQuint:t=>t*t*t*t*t,easeOutQuint:t=>1-Math.pow(1-t,5),easeInOutQuint:t=>t<.5?16*t*t*t*t*t:1-Math.pow(-2*t+2,5)/2,easeInSine:t=>1-Math.cos(t*Math.PI/2),easeOutSine:t=>Math.sin(t*Math.PI/2),easeInOutSine:t=>-(Math.cos(Math.PI*t)-1)/2,easeInExpo:t=>0===t?0:Math.pow(2,10*t-10),easeOutExpo:t=>1===t?1:1-Math.pow(2,-10*t),easeInOutExpo:t=>0===t?0:1===t?1:t<.5?Math.pow(2,20*t-10)/2:(2-Math.pow(2,-20*t+10))/2,easeInCirc:t=>1-Math.sqrt(1-Math.pow(t,2)),easeOutCirc:t=>Math.sqrt(1-Math.pow(t-1,2)),easeInOutCirc:t=>t<.5?(1-Math.sqrt(1-Math.pow(2*t,2)))/2:(Math.sqrt(1-Math.pow(-2*t+2,2))+1)/2,easeInBack:t=>2.70158*t*t*t-w*t*t,easeOutBack:t=>1+2.70158*Math.pow(t-1,3)+w*Math.pow(t-1,2),easeInOutBack:t=>t<.5?Math.pow(2*t,2)*(7.189819*t-_)/2:(Math.pow(2*t-2,2)*((_+1)*(2*t-2)+_)+2)/2,easeInElastic:t=>0===t?0:1===t?1:-Math.pow(2,10*t-10)*Math.sin((10*t-10.75)*k),easeOutElastic:t=>0===t?0:1===t?1:Math.pow(2,-10*t)*Math.sin((10*t-.75)*k)+1,easeInOutElastic:t=>0===t?0:1===t?1:t<.5?-Math.pow(2,20*t-10)*Math.sin((20*t-11.125)*x)/2:Math.pow(2,-20*t+10)*Math.sin((20*t-11.125)*x)/2+1,easeInBounce:t=>1-E(1-t),easeOutBounce:E,easeInOutBounce:t=>t<.5?(1-E(1-2*t))/2:(1+E(2*t-1))/2},P=o({},j.default,{mass:1,damping:1,easing:S.linear,clamp:!1});class M{constructor(){this.tension=void 0,this.friction=void 0,this.frequency=void 0,this.damping=void 0,this.mass=void 0,this.velocity=0,this.restVelocity=void 0,this.precision=void 0,this.progress=void 0,this.duration=void 0,this.easing=void 0,this.clamp=void 0,this.bounce=void 0,this.decay=void 0,this.round=void 0,Object.assign(this,P)}}function A(t,e){if(r.s.und(e.decay)){const n=!r.s.und(e.tension)||!r.s.und(e.friction);!n&&r.s.und(e.frequency)&&r.s.und(e.damping)&&r.s.und(e.mass)||(t.duration=void 0,t.decay=void 0),n&&(t.frequency=void 0)}else t.duration=void 0}const I=[];class C{constructor(){this.changed=!1,this.values=I,this.toValues=null,this.fromValues=I,this.to=void 0,this.from=void 0,this.config=new M,this.immediate=!1}}function R(t,{key:e,props:n,defaultProps:s,state:i,actions:u}){return new Promise((l,d)=>{var f;let h,p,m=c(null!=(f=n.cancel)?f:null==s?void 0:s.cancel,e);if(m)y();else{r.s.und(n.pause)||(i.paused=c(n.pause,e));let t=null==s?void 0:s.pause;!0!==t&&(t=i.paused||c(t,e)),h=a(n.delay||0,e),t?(i.resumeQueue.add(g),u.pause()):(u.resume(),g())}function b(){i.resumeQueue.add(g),i.timeouts.delete(p),p.cancel(),h=p.time-r.w.now()}function g(){h>0&&!r.b.skipAnimation?(i.delayed=!0,p=r.w.setTimeout(y,h),i.pauseQueue.add(b),i.timeouts.add(p)):y()}function y(){i.delayed&&(i.delayed=!1),i.pauseQueue.delete(b),i.timeouts.delete(p),t<=(i.cancelId||0)&&(m=!0);try{u.start(o({},n,{callId:t,cancel:m}),l)}catch(t){d(t)}}})}const T=(t,e)=>1==e.length?e[0]:e.some(t=>t.cancelled)?q(t.get()):e.every(t=>t.noop)?V(t.get()):N(t.get(),e.every(t=>t.finished)),V=t=>({value:t,noop:!0,finished:!0,cancelled:!1}),N=(t,e,n=!1)=>({value:t,finished:e,cancelled:n}),q=t=>({value:t,cancelled:!0,finished:!1});function D(t,e,n,s){const{callId:i,parentId:a,onRest:c}=e,{asyncTo:u,promise:l}=n;return a||t!==u||e.reset?n.promise=(async()=>{n.asyncId=i,n.asyncTo=t;const d=f(e,(t,e)=>"onRest"===e?void 0:t);let h,p;const m=new Promise((t,e)=>(h=t,p=e)),b=t=>{const e=i<=(n.cancelId||0)&&q(s)||i!==n.asyncId&&N(s,!1);if(e)throw t.result=e,p(t),t},g=(t,e)=>{const a=new L,c=new F;return(async()=>{if(r.b.skipAnimation)throw z(n),c.result=N(s,!1),p(c),c;b(a);const u=r.s.obj(t)?o({},t):o({},e,{to:t});u.parentId=i,Object(r.l)(d,(t,e)=>{r.s.und(u[e])&&(u[e]=t)});const l=await s.start(u);return b(a),n.paused&&await new Promise(t=>{n.resumeQueue.add(t)}),l})()};let y;if(r.b.skipAnimation)return z(n),N(s,!1);try{let e;e=r.s.arr(t)?(async t=>{for(const e of t)await g(e)})(t):Promise.resolve(t(g,s.stop.bind(s))),await Promise.all([e.then(h),m]),y=N(s.get(),!0,!1)}catch(t){if(t instanceof L)y=t.result;else{if(!(t instanceof F))throw t;y=t.result}}finally{i==n.asyncId&&(n.asyncId=a,n.asyncTo=a?u:void 0,n.promise=a?l:void 0)}return r.s.fun(c)&&r.w.batchedUpdates(()=>{c(y,s,s.item)}),y})():l}function z(t,e){Object(r.m)(t.timeouts,t=>t.cancel()),t.pauseQueue.clear(),t.resumeQueue.clear(),t.asyncId=t.asyncTo=t.promise=void 0,e&&(t.cancelId=e)}class L extends Error{constructor(){super("An async animation has been interrupted. You see this error because you forgot to use `await` or `.catch(...)` on its returned promise."),this.result=void 0}}class F extends Error{constructor(){super("SkipAnimationSignal"),this.result=void 0}}const U=t=>t instanceof Q;let $=1;class Q extends r.a{constructor(...t){super(...t),this.id=$++,this.key=void 0,this._priority=0}get priority(){return this._priority}set priority(t){this._priority!=t&&(this._priority=t,this._onPriorityChange(t))}get(){const t=Object(i.e)(this);return t&&t.getValue()}to(...t){return r.b.to(this,t)}interpolate(...t){return Object(r.j)(),r.b.to(this,t)}toJSON(){return this.get()}observerAdded(t){1==t&&this._attach()}observerRemoved(t){0==t&&this._detach()}_attach(){}_detach(){}_onChange(t,e=!1){Object(r.d)(this,{type:"change",parent:this,value:t,idle:e})}_onPriorityChange(t){this.idle||r.o.sort(this),Object(r.d)(this,{type:"priority",parent:this,priority:t})}}const B=Symbol.for("SpringPhase"),G=t=>(1&t[B])>0,H=t=>(2&t[B])>0,W=t=>(4&t[B])>0,Z=(t,e)=>e?t[B]|=3:t[B]&=-3,Y=(t,e)=>e?t[B]|=4:t[B]&=-5;class J extends Q{constructor(t,e){if(super(),this.key=void 0,this.animation=new C,this.queue=void 0,this.defaultProps={},this._state={paused:!1,delayed:!1,pauseQueue:new Set,resumeQueue:new Set,timeouts:new Set},this._pendingCalls=new Set,this._lastCallId=0,this._lastToId=0,this._memoizedDuration=0,!r.s.und(t)||!r.s.und(e)){const n=r.s.obj(t)?o({},t):o({},e,{from:t});r.s.und(n.default)&&(n.default=!0),this.start(n)}}get idle(){return!(H(this)||this._state.asyncTo)||W(this)}get goal(){return Object(r.q)(this.animation.to)}get velocity(){const t=Object(i.e)(this);return t instanceof i.c?t.lastVelocity||0:t.getPayload().map(t=>t.lastVelocity||0)}get hasAnimated(){return G(this)}get isAnimating(){return H(this)}get isPaused(){return W(this)}get isDelayed(){return this._state.delayed}advance(t){let e=!0,n=!1;const s=this.animation;let{config:o,toValues:a}=s;const c=Object(i.g)(s.to);!c&&Object(r.r)(s.to)&&(a=Object(r.y)(Object(r.q)(s.to))),s.values.forEach((u,l)=>{if(u.done)return;const d=u.constructor==i.b?1:c?c[l].lastPosition:a[l];let f=s.immediate,h=d;if(!f){if(h=u.lastPosition,o.tension<=0)return void(u.done=!0);let e=u.elapsedTime+=t;const n=s.fromValues[l],i=null!=u.v0?u.v0:u.v0=r.s.arr(o.velocity)?o.velocity[l]:o.velocity;let a;if(r.s.und(o.duration))if(o.decay){const t=!0===o.decay?.998:o.decay,r=Math.exp(-(1-t)*e);h=n+i/(1-t)*(1-r),f=Math.abs(u.lastPosition-h)<.1,a=i*r}else{a=null==u.lastVelocity?i:u.lastVelocity;const e=o.precision||(n==d?.005:Math.min(1,.001*Math.abs(d-n))),s=o.restVelocity||e/10,c=o.clamp?0:o.bounce,l=!r.s.und(c),p=n==d?u.v0>0:ns,m||(f=Math.abs(d-h)<=e,!f));++t)l&&(b=h==d||h>d==p,b&&(a=-a*c,h=d)),a+=(1e-6*-o.tension*(h-d)+.001*-o.friction*a)/o.mass*g,h+=a*g}else{let r=1;o.duration>0&&(this._memoizedDuration!==o.duration&&(this._memoizedDuration=o.duration,u.durationProgress>0&&(u.elapsedTime=o.duration*u.durationProgress,e=u.elapsedTime+=t)),r=(o.progress||0)+e/this._memoizedDuration,r=r>1?1:r<0?0:r,u.durationProgress=r),h=n+o.easing(r)*(d-n),a=(h-u.lastPosition)/t,f=1==r}u.lastVelocity=a,Number.isNaN(h)&&(console.warn("Got NaN while animating:",this),f=!0)}c&&!c[l].done&&(f=!1),f?u.done=!0:e=!1,u.setValue(h,o.round)&&(n=!0)});const u=Object(i.e)(this),l=u.getValue();if(e){const t=Object(r.q)(s.to);l===t&&!n||o.decay?n&&o.decay&&this._onChange(l):(u.setValue(t),this._onChange(t)),this._stop()}else n&&this._onChange(l)}set(t){return r.w.batchedUpdates(()=>{this._stop(),this._focus(t),this._set(t)}),this}pause(){this._update({pause:!0})}resume(){this._update({pause:!1})}finish(){if(H(this)){const{to:t,config:e}=this.animation;r.w.batchedUpdates(()=>{this._onStart(),e.decay||this._set(t,!1),this._stop()})}return this}update(t){return(this.queue||(this.queue=[])).push(t),this}start(t,e){let n;return r.s.und(t)?(n=this.queue||[],this.queue=[]):n=[r.s.obj(t)?t:o({},e,{to:t})],Promise.all(n.map(t=>this._update(t))).then(t=>T(this,t))}stop(t){const{to:e}=this.animation;return this._focus(this.get()),z(this._state,t&&this._lastCallId),r.w.batchedUpdates(()=>this._stop(e,t)),this}reset(){this._update({reset:!0})}eventObserved(t){"change"==t.type?this._start():"priority"==t.type&&(this.priority=t.priority+1)}_prepareNode(t){const e=this.key||"";let{to:n,from:s}=t;n=r.s.obj(n)?n[e]:n,(null==n||y(n))&&(n=void 0),s=r.s.obj(s)?s[e]:s,null==s&&(s=void 0);const o={to:n,from:s};return G(this)||(t.reverse&&([n,s]=[s,n]),s=Object(r.q)(s),r.s.und(s)?Object(i.e)(this)||this._set(n):this._set(s)),o}_update(t,e){let n=o({},t);const{key:s,defaultProps:i}=this;n.default&&Object.assign(i,f(n,(t,e)=>/^on/.test(e)?u(t,s):t)),st(this,n,"onProps"),it(this,"onProps",n,this);const a=this._prepareNode(n);if(Object.isFrozen(this))throw Error("Cannot animate a `SpringValue` object that is frozen. Did you forget to pass your component to `animated(...)` before animating its props?");const c=this._state;return R(++this._lastCallId,{key:s,props:n,defaultProps:i,state:c,actions:{pause:()=>{W(this)||(Y(this,!0),Object(r.n)(c.pauseQueue),it(this,"onPause",N(this,K(this,this.animation.to)),this))},resume:()=>{W(this)&&(Y(this,!1),H(this)&&this._resume(),Object(r.n)(c.resumeQueue),it(this,"onResume",N(this,K(this,this.animation.to)),this))},start:this._merge.bind(this,a)}}).then(t=>{if(n.loop&&t.finished&&(!e||!t.noop)){const t=X(n);if(t)return this._update(t,!0)}return t})}_merge(t,e,n){if(e.cancel)return this.stop(!0),n(q(this));const s=!r.s.und(t.to),u=!r.s.und(t.from);if(s||u){if(!(e.callId>this._lastToId))return n(q(this));this._lastToId=e.callId}const{key:l,defaultProps:d,animation:f}=this,{to:h,from:p}=f;let{to:m=h,from:g=p}=t;!u||s||e.default&&!r.s.und(m)||(m=g),e.reverse&&([m,g]=[g,m]);const O=!Object(r.u)(g,p);O&&(f.from=g),g=Object(r.q)(g);const v=!Object(r.u)(m,h);v&&this._focus(m);const j=y(e.to),{config:w}=f,{decay:_,velocity:k}=w;(s||u)&&(w.velocity=0),e.config&&!j&&function(t,e,n){n&&(A(n=o({},n),e),e=o({},n,e)),A(t,e),Object.assign(t,e);for(const e in P)null==t[e]&&(t[e]=P[e]);let{mass:s,frequency:i,damping:a}=t;r.s.und(i)||(i<.01&&(i=.01),a<0&&(a=0),t.tension=Math.pow(2*Math.PI/i,2)*s,t.friction=4*Math.PI*a*s/i)}(w,a(e.config,l),e.config!==d.config?a(d.config,l):void 0);let x=Object(i.e)(this);if(!x||r.s.und(m))return n(N(this,!0));const E=r.s.und(e.reset)?u&&!e.default:!r.s.und(g)&&c(e.reset,l),S=E?g:this.get(),M=b(m),I=r.s.num(M)||r.s.arr(M)||Object(r.t)(M),C=!j&&(!I||c(d.immediate||e.immediate,l));if(v){const t=Object(i.f)(m);if(t!==x.constructor){if(!C)throw Error(`Cannot animate between ${x.constructor.name} and ${t.name}, as the "to" prop suggests`);x=this._set(M)}}const R=x.constructor;let T=Object(r.r)(m),z=!1;if(!T){const t=E||!G(this)&&O;(v||t)&&(z=Object(r.u)(b(S),M),T=!z),(Object(r.u)(f.immediate,C)||C)&&Object(r.u)(w.decay,_)&&Object(r.u)(w.velocity,k)||(T=!0)}if(z&&H(this)&&(f.changed&&!E?T=!0:T||this._stop(h)),!j&&((T||Object(r.r)(h))&&(f.values=x.getPayload(),f.toValues=Object(r.r)(m)?null:R==i.b?[1]:Object(r.y)(M)),f.immediate!=C&&(f.immediate=C,C||E||this._set(h)),T)){const{onRest:t}=f;Object(r.k)(rt,t=>st(this,e,t));const s=N(this,K(this,h));Object(r.n)(this._pendingCalls,s),this._pendingCalls.add(n),f.changed&&r.w.batchedUpdates(()=>{f.changed=!E,null==t||t(s,this),E?a(d.onRest,s):null==f.onStart||f.onStart(s,this)})}E&&this._set(S),j?n(D(e.to,e,this._state,this)):T?this._start():H(this)&&!v?this._pendingCalls.add(n):n(V(S))}_focus(t){const e=this.animation;t!==e.to&&(Object(r.p)(this)&&this._detach(),e.to=t,Object(r.p)(this)&&this._attach())}_attach(){let t=0;const{to:e}=this.animation;Object(r.r)(e)&&(Object(r.c)(e,this),U(e)&&(t=e.priority+1)),this.priority=t}_detach(){const{to:t}=this.animation;Object(r.r)(t)&&Object(r.x)(t,this)}_set(t,e=!0){const n=Object(r.q)(t);if(!r.s.und(n)){const t=Object(i.e)(this);if(!t||!Object(r.u)(n,t.getValue())){const s=Object(i.f)(n);t&&t.constructor==s?t.setValue(n):Object(i.h)(this,s.create(n)),t&&r.w.batchedUpdates(()=>{this._onChange(n,e)})}}return Object(i.e)(this)}_onStart(){const t=this.animation;t.changed||(t.changed=!0,it(this,"onStart",N(this,K(this,t.to)),this))}_onChange(t,e){e||(this._onStart(),a(this.animation.onChange,t,this)),a(this.defaultProps.onChange,t,this),super._onChange(t,e)}_start(){const t=this.animation;Object(i.e)(this).reset(Object(r.q)(t.to)),t.immediate||(t.fromValues=t.values.map(t=>t.lastPosition)),H(this)||(Z(this,!0),W(this)||this._resume())}_resume(){r.b.skipAnimation?this.finish():r.o.start(this)}_stop(t,e){if(H(this)){Z(this,!1);const n=this.animation;Object(r.k)(n.values,t=>{t.done=!0}),n.toValues&&(n.onChange=n.onPause=n.onResume=void 0),Object(r.d)(this,{type:"idle",parent:this});const s=e?q(this.get()):N(this.get(),K(this,null!=t?t:n.to));Object(r.n)(this._pendingCalls,s),n.changed&&(n.changed=!1,it(this,"onRest",s,this))}}}function K(t,e){const n=b(e),s=b(t.get());return Object(r.u)(s,n)}function X(t,e=t.loop,n=t.to){let r=a(e);if(r){const s=!0!==r&&m(r),i=(s||t).reverse,a=!s||s.reset;return tt(o({},t,{loop:e,default:!1,pause:void 0,to:!i||y(n)?n:void 0,from:a?t.from:void 0,reset:a},s))}}function tt(t){const{to:e,from:n}=t=m(t),s=new Set;return r.s.obj(e)&&nt(e,s),r.s.obj(n)&&nt(n,s),t.keys=s.size?Array.from(s):null,t}function et(t){const e=tt(t);return r.s.und(e.default)&&(e.default=f(e)),e}function nt(t,e){Object(r.l)(t,(t,n)=>null!=t&&e.add(n))}const rt=["onStart","onRest","onChange","onPause","onResume"];function st(t,e,n){t.animation[n]=e[n]!==l(e,n)?u(e[n],t.key):void 0}function it(t,e,...n){var r,s,i,o;null==(r=(s=t.animation)[e])||r.call(s,...n),null==(i=(o=t.defaultProps)[e])||i.call(o,...n)}const ot=["onStart","onChange","onRest"];let at=1;class ct{constructor(t,e){this.id=at++,this.springs={},this.queue=[],this.ref=void 0,this._flush=void 0,this._initialProps=void 0,this._lastAsyncId=0,this._active=new Set,this._changed=new Set,this._started=!1,this._item=void 0,this._state={paused:!1,pauseQueue:new Set,resumeQueue:new Set,timeouts:new Set},this._events={onStart:new Map,onChange:new Map,onRest:new Map},this._onFrame=this._onFrame.bind(this),e&&(this._flush=e),t&&this.start(o({default:!0},t))}get idle(){return!this._state.asyncTo&&Object.values(this.springs).every(t=>t.idle&&!t.isDelayed&&!t.isPaused)}get item(){return this._item}set item(t){this._item=t}get(){const t={};return this.each((e,n)=>t[n]=e.get()),t}set(t){for(const e in t){const n=t[e];r.s.und(n)||this.springs[e].set(n)}}update(t){return t&&this.queue.push(tt(t)),this}start(t){let{queue:e}=this;return t?e=Object(r.y)(t).map(tt):this.queue=[],this._flush?this._flush(this,e):(pt(this,e),ut(this,e))}stop(t,e){if(t!==!!t&&(e=t),e){const n=this.springs;Object(r.k)(Object(r.y)(e),e=>n[e].stop(!!t))}else z(this._state,this._lastAsyncId),this.each(e=>e.stop(!!t));return this}pause(t){if(r.s.und(t))this.start({pause:!0});else{const e=this.springs;Object(r.k)(Object(r.y)(t),t=>e[t].pause())}return this}resume(t){if(r.s.und(t))this.start({pause:!1});else{const e=this.springs;Object(r.k)(Object(r.y)(t),t=>e[t].resume())}return this}each(t){Object(r.l)(this.springs,t)}_onFrame(){const{onStart:t,onChange:e,onRest:n}=this._events,s=this._active.size>0,i=this._changed.size>0;(s&&!this._started||i&&!this._started)&&(this._started=!0,Object(r.m)(t,([t,e])=>{e.value=this.get(),t(e,this,this._item)}));const o=!s&&this._started,a=i||o&&n.size?this.get():null;i&&e.size&&Object(r.m)(e,([t,e])=>{e.value=a,t(e,this,this._item)}),o&&(this._started=!1,Object(r.m)(n,([t,e])=>{e.value=a,t(e,this,this._item)}))}eventObserved(t){if("change"==t.type)this._changed.add(t.parent),t.idle||this._active.add(t.parent);else{if("idle"!=t.type)return;this._active.delete(t.parent)}r.w.onFrame(this._onFrame)}}function ut(t,e){return Promise.all(e.map(e=>async function t(e,n,s){const{keys:i,to:o,from:a,loop:c,onRest:u,onResolve:d}=n,f=r.s.obj(n.default)&&n.default;c&&(n.loop=!1),!1===o&&(n.to=null),!1===a&&(n.from=null);const h=r.s.arr(o)||r.s.fun(o)?o:void 0;h?(n.to=void 0,n.onRest=void 0,f&&(f.onRest=void 0)):Object(r.k)(ot,t=>{const s=n[t];if(r.s.fun(s)){const r=e._events[t];n[t]=({finished:t,cancelled:e})=>{const n=r.get(s);n?(t||(n.finished=!1),e&&(n.cancelled=!0)):r.set(s,{value:null,finished:t||!1,cancelled:e||!1})},f&&(f[t]=n[t])}});const p=e._state;n.pause===!p.paused?(p.paused=n.pause,Object(r.n)(n.pause?p.pauseQueue:p.resumeQueue)):p.paused&&(n.pause=!0);const m=(i||Object.keys(e.springs)).map(t=>e.springs[t].start(n)),b=!0===n.cancel||!0===l(n,"cancel");(h||b&&p.asyncId)&&m.push(R(++e._lastAsyncId,{props:n,state:p,actions:{pause:r.v,resume:r.v,start(t,n){b?(z(p,e._lastAsyncId),n(q(e))):(t.onRest=u,n(D(h,t,p,e)))}}})),p.paused&&await new Promise(t=>{p.resumeQueue.add(t)});const g=T(e,await Promise.all(m));if(c&&g.finished&&(!s||!g.noop)){const r=X(n,c,o);if(r)return pt(e,[r]),t(e,r,!0)}return d&&r.w.batchedUpdates(()=>d(g,e,e.item)),g}(t,e))).then(e=>T(t,e))}function lt(t,e){const n=o({},t.springs);return e&&Object(r.k)(Object(r.y)(e),t=>{r.s.und(t.keys)&&(t=tt(t)),r.s.obj(t.to)||(t=o({},t,{to:void 0})),ht(n,t,t=>ft(t))}),dt(t,n),n}function dt(t,e){Object(r.l)(e,(e,n)=>{t.springs[n]||(t.springs[n]=e,Object(r.c)(e,t))})}function ft(t,e){const n=new J;return n.key=t,e&&Object(r.c)(n,e),n}function ht(t,e,n){e.keys&&Object(r.k)(e.keys,r=>{(t[r]||(t[r]=n(r)))._prepareNode(e)})}function pt(t,e){Object(r.k)(e,e=>{ht(t.springs,e,e=>ft(e,t))})}const mt=["children"],bt=t=>{let{children:e}=t,n=function(t,e){if(null==t)return{};var n,r,s={},i=Object.keys(t);for(r=0;r=0||(s[n]=t[n]);return s}(t,mt);const i=Object(s.useContext)(gt),o=n.pause||!!i.pause,a=n.immediate||!!i.immediate;n=Object(r.B)(()=>({pause:o,immediate:a}),[o,a]);const{Provider:c}=gt;return s.createElement(c,{value:n},e)},gt=(yt=bt,Ot={},Object.assign(yt,s.createContext(Ot)),yt.Provider._context=yt,yt.Consumer._context=yt,yt);var yt,Ot;bt.Provider=gt.Provider,bt.Consumer=gt.Consumer;const vt=()=>{const t=[],e=function(e){Object(r.i)();const s=[];return Object(r.k)(t,(t,i)=>{if(r.s.und(e))s.push(t.start());else{const r=n(e,t,i);r&&s.push(t.start(r))}}),s};e.current=t,e.add=function(e){t.includes(e)||t.push(e)},e.delete=function(e){const n=t.indexOf(e);~n&&t.splice(n,1)},e.pause=function(){return Object(r.k)(t,t=>t.pause(...arguments)),this},e.resume=function(){return Object(r.k)(t,t=>t.resume(...arguments)),this},e.set=function(e){Object(r.k)(t,t=>t.set(e))},e.start=function(e){const n=[];return Object(r.k)(t,(t,s)=>{if(r.s.und(e))n.push(t.start());else{const r=this._getProps(e,t,s);r&&n.push(t.start(r))}}),n},e.stop=function(){return Object(r.k)(t,t=>t.stop(...arguments)),this},e.update=function(e){return Object(r.k)(t,(t,n)=>t.update(this._getProps(e,t,n))),this};const n=function(t,e,n){return r.s.fun(t)?t(n,e):t};return e._getProps=n,e};function jt(t,e,n){const i=r.s.fun(e)&&e;i&&!n&&(n=[]);const a=Object(s.useMemo)(()=>i||3==arguments.length?vt():void 0,[]),c=Object(s.useRef)(0),u=Object(r.z)(),l=Object(s.useMemo)(()=>({ctrls:[],queue:[],flush(t,e){const n=lt(t,e);return c.current>0&&!l.queue.length&&!Object.keys(n).some(e=>!t.springs[e])?ut(t,e):new Promise(r=>{dt(t,n),l.queue.push(()=>{r(ut(t,e))}),u()})}}),[]),d=Object(s.useRef)([...l.ctrls]),f=[],h=Object(r.D)(t)||0;function p(t,n){for(let r=t;r{Object(r.k)(d.current.slice(t,h),t=>{O(t,a),t.stop(!0)}),d.current.length=t,p(h,t)},[t]),Object(s.useMemo)(()=>{p(0,Math.min(h,t))},n);const m=d.current.map((t,e)=>lt(t,f[e])),b=Object(s.useContext)(bt),y=Object(r.D)(b),j=b!==y&&g(b);Object(r.A)(()=>{c.current++,l.ctrls=d.current;const{queue:t}=l;t.length&&(l.queue=[],Object(r.k)(t,t=>t())),Object(r.k)(d.current,(t,e)=>{null==a||a.add(t),j&&t.start({default:b});const n=f[e];n&&(v(t,n.ref),t.ref?t.queue.push(n):t.start(n))})}),Object(r.C)(()=>()=>{Object(r.k)(l.ctrls,t=>t.stop(!0))});const w=m.map(t=>o({},t));return a?[w,a]:w}function wt(t,e){const n=r.s.fun(t),[[s],i]=jt(1,n?t:[t],n?e||[]:e);return n||2==arguments.length?[s,i]:s}let _t;function kt(t,e,n){const i=r.s.fun(e)&&e,{reset:c,sort:u,trail:l=0,expires:d=!0,exitBeforeEnter:h=!1,onDestroyed:p,ref:b,config:y}=i?i():e,j=Object(s.useMemo)(()=>i||3==arguments.length?vt():void 0,[]),w=Object(r.y)(t),_=[],k=Object(s.useRef)(null),x=c?null:k.current;Object(r.A)(()=>{k.current=_}),Object(r.C)(()=>()=>{Object(r.k)(k.current,t=>{t.expired&&clearTimeout(t.expirationId),O(t.ctrl,j),t.ctrl.stop(!0)})});const E=Et(w,i?i():e,x),S=c&&k.current||[];Object(r.A)(()=>Object(r.k)(S,({ctrl:t,item:e,key:n})=>{O(t,j),a(p,e,n)}));const P=[];if(x&&Object(r.k)(x,(t,e)=>{t.expired?(clearTimeout(t.expirationId),S.push(t)):~(e=P[e]=E.indexOf(t.key))&&(_[e]=t)}),Object(r.k)(w,(t,e)=>{_[e]||(_[e]={key:E[e],item:t,phase:_t.MOUNT,ctrl:new ct},_[e].ctrl.item=t)}),P.length){let t=-1;const{leave:n}=i?i():e;Object(r.k)(P,(e,r)=>{const s=x[r];~e?(t=_.indexOf(s),_[t]=o({},s,{item:w[e]})):n&&_.splice(++t,0,s)})}r.s.fun(u)&&_.sort((t,e)=>u(t.item,e.item));let M=-l;const A=Object(r.z)(),I=f(e),C=new Map,R=Object(s.useRef)(new Map),T=Object(s.useRef)(!1);Object(r.k)(_,(t,n)=>{const s=t.key,c=t.phase,u=i?i():e;let f,p,g=a(u.delay||0,s);if(c==_t.MOUNT)f=u.enter,p=_t.ENTER;else{const t=E.indexOf(s)<0;if(c!=_t.LEAVE)if(t)f=u.leave,p=_t.LEAVE;else{if(!(f=u.update))return;p=_t.UPDATE}else{if(t)return;f=u.enter,p=_t.ENTER}}if(f=a(f,t.item,n),f=r.s.obj(f)?m(f):{to:f},!f.config){const e=y||I.config;f.config=a(e,t.item,n,p)}M+=l;const O=o({},I,{delay:g+M,ref:b,immediate:u.immediate,reset:!1},f);if(p==_t.ENTER&&r.s.und(O.from)){const s=i?i():e,o=r.s.und(s.initial)||x?s.from:s.initial;O.from=a(o,t.item,n)}const{onResolve:v}=O;O.onResolve=t=>{a(v,t);const e=k.current,n=e.find(t=>t.key===s);if(n&&(!t.cancelled||n.phase==_t.UPDATE)&&n.ctrl.idle){const t=e.every(t=>t.ctrl.idle);if(n.phase==_t.LEAVE){const e=a(d,n.item);if(!1!==e){const r=!0===e?0:e;if(n.expired=!0,!t&&r>0)return void(r<=2147483647&&(n.expirationId=setTimeout(A,r)))}}t&&e.some(t=>t.expired)&&(R.current.delete(n),h&&(T.current=!0),A())}};const j=lt(t.ctrl,O);p===_t.LEAVE&&h?R.current.set(t,{phase:p,springs:j,payload:O}):C.set(t,{phase:p,springs:j,payload:O})});const V=Object(s.useContext)(bt),N=Object(r.D)(V),q=V!==N&&g(V);Object(r.A)(()=>{q&&Object(r.k)(_,t=>{t.ctrl.start({default:V})})},[V]),Object(r.k)(C,(t,e)=>{if(R.current.size){const t=_.findIndex(t=>t.key===e.key);_.splice(t,1)}}),Object(r.A)(()=>{Object(r.k)(R.current.size?R.current:C,({phase:t,payload:e},n)=>{const{ctrl:r}=n;n.phase=t,null==j||j.add(r),q&&t==_t.ENTER&&r.start({default:V}),e&&(v(r,e.ref),r.ref&&!T.current?r.update(e):(r.start(e),T.current&&(T.current=!1)))})},c?void 0:n);const D=t=>s.createElement(s.Fragment,null,_.map((e,n)=>{const{springs:i}=C.get(e)||e.ctrl,a=t(o({},i),e.item,e,n);return a&&a.type?s.createElement(a.type,o({},a.props,{key:r.s.str(e.key)||r.s.num(e.key)?e.key:e.ctrl.id,ref:a.ref})):a}));return j?[D,j]:D}!function(t){t.MOUNT="mount",t.ENTER="enter",t.UPDATE="update",t.LEAVE="leave"}(_t||(_t={}));let xt=1;function Et(t,{key:e,keys:n=e},s){if(null===n){const e=new Set;return t.map(t=>{const n=s&&s.find(n=>n.item===t&&n.phase!==_t.LEAVE&&!e.has(n));return n?(e.add(n),n.key):xt++})}return r.s.und(n)?t:r.s.fun(n)?t.map(n):Object(r.y)(n)}class St extends Q{constructor(t,e){super(),this.key=void 0,this.idle=!0,this.calc=void 0,this._active=new Set,this.source=t,this.calc=Object(r.f)(...e);const n=this._get(),s=Object(i.f)(n);Object(i.h)(this,s.create(n))}advance(t){const e=this._get(),n=this.get();Object(r.u)(e,n)||(Object(i.e)(this).setValue(e),this._onChange(e,this.idle)),!this.idle&&Mt(this._active)&&At(this)}_get(){const t=r.s.arr(this.source)?this.source.map(r.q):Object(r.y)(Object(r.q)(this.source));return this.calc(...t)}_start(){this.idle&&!Mt(this._active)&&(this.idle=!1,Object(r.k)(Object(i.g)(this),t=>{t.done=!1}),r.b.skipAnimation?(r.w.batchedUpdates(()=>this.advance()),At(this)):r.o.start(this))}_attach(){let t=1;Object(r.k)(Object(r.y)(this.source),e=>{Object(r.r)(e)&&Object(r.c)(e,this),U(e)&&(e.idle||this._active.add(e),t=Math.max(t,e.priority+1))}),this.priority=t,this._start()}_detach(){Object(r.k)(Object(r.y)(this.source),t=>{Object(r.r)(t)&&Object(r.x)(t,this)}),this._active.clear(),At(this)}eventObserved(t){"change"==t.type?t.idle?this.advance():(this._active.add(t.parent),this._start()):"idle"==t.type?this._active.delete(t.parent):"priority"==t.type&&(this.priority=Object(r.y)(this.source).reduce((t,e)=>Math.max(t,(U(e)?e.priority:0)+1),0))}}function Pt(t){return!1!==t.idle}function Mt(t){return!t.size||Array.from(t).every(Pt)}function At(t){t.idle||(t.idle=!0,Object(r.k)(Object(i.g)(t),t=>{t.done=!0}),Object(r.d)(t,{type:"idle",parent:t}))}r.b.assign({createStringInterpolator:r.g,to:(t,e)=>new St(t,e)}),r.o.advance},,function(t,e){t.exports=window.regeneratorRuntime},,function(t,e,n){"use strict";n.d(e,"animated",(function(){return _}));var r=n(34);n.o(r,"config")&&n.d(e,"config",(function(){return r.config})),n.o(r,"useSpring")&&n.d(e,"useSpring",(function(){return r.useSpring})),n.o(r,"useTransition")&&n.d(e,"useTransition",(function(){return r.useTransition}));var s=n(45),i=n(1),o=n(10);function a(t,e){if(null==t)return{};var n,r,s={},i=Object.keys(t);for(r=0;r=0||(s[n]=t[n]);return s}const c=["style","children","scrollTop","scrollLeft"],u=/^--/;function l(t,e){return null==e||"boolean"==typeof e||""===e?"":"number"!=typeof e||0===e||u.test(t)||f.hasOwnProperty(t)&&f[t]?(""+e).trim():e+"px"}const d={};let f={animationIterationCount:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0};const h=["Webkit","Ms","Moz","O"];f=Object.keys(f).reduce((t,e)=>(h.forEach(n=>t[((t,e)=>t+e.charAt(0).toUpperCase()+e.substring(1))(n,e)]=t[e]),t),f);const p=["x","y","z"],m=/^(matrix|translate|scale|rotate|skew)/,b=/^(translate)/,g=/^(rotate|skew)/,y=(t,e)=>i.s.num(t)&&0!==t?t+e:t,O=(t,e)=>i.s.arr(t)?t.every(t=>O(t,e)):i.s.num(t)?t===e:parseFloat(t)===e;class v extends o.a{constructor(t){let{x:e,y:n,z:r}=t,s=a(t,p);const o=[],c=[];(e||n||r)&&(o.push([e||0,n||0,r||0]),c.push(t=>[`translate3d(${t.map(t=>y(t,"px")).join(",")})`,O(t,0)])),Object(i.l)(s,(t,e)=>{if("transform"===e)o.push([t||""]),c.push(t=>[t,""===t]);else if(m.test(e)){if(delete s[e],i.s.und(t))return;const n=b.test(e)?"px":g.test(e)?"deg":"";o.push(Object(i.y)(t)),c.push("rotate3d"===e?([t,e,r,s])=>[`rotate3d(${t},${e},${r},${y(s,n)})`,O(s,0)]:t=>[`${e}(${t.map(t=>y(t,n)).join(",")})`,O(t,e.startsWith("scale")?1:0)])}}),o.length&&(s.transform=new j(o,c)),super(s)}}class j extends i.a{constructor(t,e){super(),this._value=null,this.inputs=t,this.transforms=e}get(){return this._value||(this._value=this._get())}_get(){let t="",e=!0;return Object(i.k)(this.inputs,(n,r)=>{const s=Object(i.q)(n[0]),[o,a]=this.transforms[r](i.s.arr(s)?s:n.map(i.q));t+=" "+o,e=e&&a}),e?"none":t}observerAdded(t){1==t&&Object(i.k)(this.inputs,t=>Object(i.k)(t,t=>Object(i.r)(t)&&Object(i.c)(t,this)))}observerRemoved(t){0==t&&Object(i.k)(this.inputs,t=>Object(i.k)(t,t=>Object(i.r)(t)&&Object(i.x)(t,this)))}eventObserved(t){"change"==t.type&&(this._value=null),Object(i.d)(this,t)}}const w=["scrollTop","scrollLeft"];r.Globals.assign({batchedUpdates:s.unstable_batchedUpdates,createStringInterpolator:i.g,colors:i.e});const _=Object(o.d)(["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"],{applyAnimatedValues:function(t,e){if(!t.nodeType||!t.setAttribute)return!1;const n="filter"===t.nodeName||t.parentNode&&"filter"===t.parentNode.nodeName,r=e,{style:s,children:i,scrollTop:o,scrollLeft:f}=r,h=a(r,c),p=Object.values(h),m=Object.keys(h).map(e=>n||t.hasAttribute(e)?e:d[e]||(d[e]=e.replace(/([A-Z])/g,t=>"-"+t.toLowerCase())));void 0!==i&&(t.textContent=i);for(let e in s)if(s.hasOwnProperty(e)){const n=l(e,s[e]);u.test(e)?t.style.setProperty(e,n):t.style[e]=n}m.forEach((e,n)=>{t.setAttribute(e,p[n])}),void 0!==o&&(t.scrollTop=o),void 0!==f&&(t.scrollLeft=f)},createAnimatedStyle:t=>new v(t),getComponentProps:t=>a(t,w)}).animated},function(t,e){},function(t,e){},,,,,function(t,e){t.exports=window.ReactDOM},function(t,e){t.exports=window.moment},function(t,e){t.exports=window.wp.autop},function(t,e){function n(t,e,n,r,s,i,o){try{var a=t[i](o),c=a.value}catch(t){return void n(t)}a.done?e(c):Promise.resolve(c).then(r,s)}t.exports=function(t){return function(){var e=this,r=arguments;return new Promise((function(s,i){var o=t.apply(e,r);function a(t){n(o,s,i,a,c,"next",t)}function c(t){n(o,s,i,a,c,"throw",t)}a(void 0)}))}},t.exports.__esModule=!0,t.exports.default=t.exports},,,,,,,,,,,function(t,e,n){"use strict";var r=n(0),s=n(6);const i=Object(r.createElement)(s.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(s.Path,{d:"M13 11.8l6.1-6.3-1-1-6.1 6.2-6.1-6.2-1 1 6.1 6.3-6.5 6.7 1 1 6.5-6.6 6.5 6.6 1-1z"}));e.a=i},,,,,,,,,,,function(t,e,n){"use strict";n.r(e);var r=n(5),s=n.n(r),i=n(0),o=n(23),a=n.n(o),c=n(32),u=n(7),l=n(15),d=n.n(l);function f(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function h(t){for(var e=1;e0&&Object(i.createElement)(m.animated.span,{style:r,className:"simpay-branding-bar__actions-button-count","aria-label":Object(b.sprintf)( /* translators: %d Unread notification count. */ -Object(b.__)("%d unread notifications","simple-pay"),e)},Object(i.createElement)("span",null,e)),Object(i.createElement)("svg",{viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg"},Object(i.createElement)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M15.8333 2.5H4.16667C3.25 2.5 2.5 3.25 2.5 4.16667V15.8333c0 .9167.74167 1.6667 1.66667 1.6667H15.8333c.9167 0 1.6667-.75 1.6667-1.6667V4.16667C17.5 3.25 16.75 2.5 15.8333 2.5Zm0 13.3333H4.16667v-2.5h2.96666C7.70833 14.325 8.775 15 10.0083 15c1.2334 0 2.2917-.675 2.875-1.6667h2.95v2.5Zm-4.1583-4.1666h4.1583V4.16667H4.16667v7.50003h4.175c0 .9166.75 1.6666 1.66663 1.6666.9167 0 1.6667-.75 1.6667-1.6666Z",fill:"currentColor"})))},y=n(46),O=n.n(y),v=n(3),j=n(47),w="simpay-notifications-notification",_=simpayNotifications.isLite;function k(t){switch(t){case"warning":return"warning";case"error":return"dismiss";case"info":return"admin-generic";case"success":default:return"yes-alt"}}function x(t){return Object(u.getAuthority)(window.location.href)!==Object(u.getAuthority)(t)}function E(t,e,n){return!1===x(t)?t:Object(u.addQueryArgs)(t.replace(/\/?$/,"/"),{utm_source:"WordPress",utm_campaign:"1"===_?"lite-plugin":"pro-plugin",utm_medium:e,utm_content:n})}var S=function(t){var e=t.notification,n=t.onDismissNotification,r=e.id,s=e.title,o=e.content,a=e.type,c=e.start,u=e.actions,l=e.is_dismissible;return Object(i.createElement)("div",{className:w,style:{backgroundColor:l?"transparent":"#fafafa"}},Object(i.createElement)("div",{className:"".concat(w,"__icon ").concat(w,"__icon-").concat(a||"success")},Object(i.createElement)("span",{className:"dashicons dashicons-".concat(k(a))})),Object(i.createElement)("div",{className:"".concat(w,"__body")},Object(i.createElement)("div",{className:"".concat(w,"__header")},Object(i.createElement)("div",{className:"".concat(w,"__title")},s),l&&Object(i.createElement)("div",{className:"".concat(w,"__date")},O.a.unix(c).fromNow())),Object(i.createElement)("div",{className:"".concat(w,"__content"),dangerouslySetInnerHTML:{__html:Object(j.autop)(o)}}),Object(i.createElement)("div",{className:"".concat(w,"__actions")},u.map((function(t){var e=t.type,n=t.text,r=t.url;return Object(i.createElement)(v.Button,{key:n,href:E(r,"notification-inbox",s),isPrimary:"primary"===e,isSecondary:"secondary"===e,variant:e,target:x(r)?"_blank":"_self"},n)})),l&&Object(i.createElement)(v.Button,{isLink:!0,variant:"link",onClick:function(){return n(r)}},Object(b.__)("Dismiss","simple-pay")))))},P=n(48),M=n.n(P),A=n(36),I=n.n(A),C=n(14),R=n.n(C),T=n(8),V=n(11);function N(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);nt.length)&&(e=t.length);for(var n=0,r=new Array(e);n=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(t){throw t},f:s}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,o=!0,a=!1;return{s:function(){n=n.call(t)},n:function(){var t=n.next();return o=t.done,t},e:function(t){a=!0,i=t},f:function(){try{o||null==n.return||n.return()}finally{if(a)throw i}}}}(t?s.current:r.current);try{for(o.s();!(i=o.n()).done;)q(i.value,t)}catch(t){o.e(t)}finally{o.f()}}),[])}([Object(V.useConstrainedTabbing)(),Object(V.useFocusReturn)(),c]),l=Object(i.useState)((function(){return new WeakMap})),d=s()(l,1)[0],f=Object(T.sortBy)(o,"is_dismissible"),h=Object(m.useTransition)(f,{config:m.config.default,enter:function(t){return function(){var e=M()(I.a.mark((function e(n){return I.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,n({height:d.get(t).offsetHeight,transform:"translate3d(0%, 0px, 0px)"});case 2:case"end":return e.stop()}}),e)})));return function(_x){return e.apply(this,arguments)}}()},leave:[{transform:"translate3d(150%, 0px, 0px)"},{height:0}],keys:function(t){return t.id},trail:100});return Object(i.createElement)(v.Animate,{type:"slide-in",options:{origin:"left"}},(function(t){var s=t.className,c=R()("simpay-notifications-panel",s);return Object(i.createElement)("div",{ref:u,className:c},Object(i.createElement)(z,{count:e.data.length,onClose:n}),Object(i.createElement)("div",{className:"simpay-notifications-panel__notifications"},a&&Object(i.createElement)("div",{className:"simpay-notifications-panel__none"},Object(i.createElement)(v.Spinner,null)),0===o.length&&!a&&Object(i.createElement)("div",{className:"simpay-notifications-panel__none"},Object(i.createElement)("span",null,Object(b.__)("You have no new notifications.","simple-pay"))),h((function(t,e){return Object(i.createElement)(m.animated.div,{style:F(F({},t),{},{overflow:"hidden"}),ref:function(t){return t&&d.set(e,t)}},Object(i.createElement)(S,{onDismissNotification:r,notification:e}))}))))}))},$=function(t){var e=t.isOpen,n=t.onClose;return Object(i.useEffect)((function(){return document.body.classList.toggle("simpay-notifications-body-locked"),function(){document.body.classList.remove("simpay-notifications-body-locked")}}),[e]),Object(i.createElement)("button",{className:"simpay-notifications-backdrop",onClick:n})};Object(i.render)(Object(i.createElement)((function(){var t=Object(i.useReducer)(p,{data:[],isLoading:!0}),e=s()(t,2),n=e[0],r=e[1],o=Object(i.useState)("#notifications"===Object(u.getFragment)(window.location.href)),l=s()(o,2),d=l[0],f=l[1];function h(){f(!1),window.history.pushState("",document.title,window.location.pathname+window.location.search)}return Object(i.useEffect)((function(){function t(){"#notifications"===Object(u.getFragment)(window.location.href)&&f(!0)}return window.addEventListener("hashchange",t),function(){window.removeEventListener("hashchange",t)}}),[]),Object(i.useEffect)((function(){if(!n.isLoading){var t=document.querySelector("#wp-admin-bar-simpay-admin-bar-test-mode .wp-ui-notification");if(0===n.data.length){t&&t.remove();var e=document.getElementById("wp-admin-bar-simpay-notifications");e&&e.remove();var r=document.querySelector('#menu-posts-simple-pay .wp-submenu a[href$="#notifications"]');r&&r.remove()}else t&&(t.textContent=n.data.length)}}),[n.data]),Object(i.useEffect)((function(){r({type:"START_RESOLUTION"}),a()({path:"/wpsp/v2/notifications"}).then((function(t){var e=t.data;r({type:"SET",notifications:e}),r({type:"FINISH_RESOLUTION"})}))}),[]),Object(i.createElement)("div",{onKeyDown:function(t){t.keyCode!==c.ESCAPE||t.defaultPrevented||(t.preventDefault(),f(!1))},role:"region"},Object(i.createElement)(g,{count:n.data.length,isOpen:d,onOpen:function(){f(!0),window.history.pushState("",document.title,window.location.pathname+window.location.search+"#notifications")}}),d&&Object(i.createElement)(i.Fragment,null,Object(i.createElement)(U,{notifications:n,onDismissNotification:function(t){r({type:"DISMISS",id:t}),a()({path:"/wpsp/v2/notifications/"+t,method:"DELETE"})},onClose:h}),Object(i.createElement)($,{onClose:h})))}),null),document.getElementById("simpay-branding-bar-notifications"))}]); \ No newline at end of file diff --git a/includes/core/assets/js/simpay-admin-page-setup-wizard.min.asset.php b/includes/core/assets/js/simpay-admin-page-setup-wizard.min.asset.php index 1ea77ad2..4dde9c69 100644 --- a/includes/core/assets/js/simpay-admin-page-setup-wizard.min.asset.php +++ b/includes/core/assets/js/simpay-admin-page-setup-wizard.min.asset.php @@ -1 +1 @@ - array('lodash', 'react', 'wp-api-fetch', 'wp-components', 'wp-core-data', 'wp-data', 'wp-element', 'wp-i18n', 'wp-notices', 'wp-primitives', 'wp-url'), 'version' => 'f2c7d2f2ff80314f2a4a7ccc36e08ba5'); \ No newline at end of file + array('lodash', 'react', 'wp-api-fetch', 'wp-components', 'wp-core-data', 'wp-data', 'wp-element', 'wp-i18n', 'wp-notices', 'wp-primitives', 'wp-url'), 'version' => '870904912a23d5b727cd651f92621a97'); \ No newline at end of file diff --git a/includes/core/assets/js/simpay-admin-page-setup-wizard.min.js b/includes/core/assets/js/simpay-admin-page-setup-wizard.min.js index 52896378..ec3ccfa0 100644 --- a/includes/core/assets/js/simpay-admin-page-setup-wizard.min.js +++ b/includes/core/assets/js/simpay-admin-page-setup-wizard.min.js @@ -1,3 +1,3 @@ -!function(e){var t={};function n(r){if(t[r])return t[r].exports;var a=t[r]={i:r,l:!1,exports:{}};return e[r].call(a.exports,a,a.exports,n),a.l=!0,a.exports}n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var a in e)n.d(r,a,function(t){return e[t]}.bind(null,a));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=66)}([function(e,t){e.exports=window.wp.element},,function(e,t){e.exports=window.wp.i18n},function(e,t){e.exports=window.wp.components},function(e,t){e.exports=window.React},function(e,t,n){var r=n(20),a=n(21),i=n(16),c=n(22);e.exports=function(e,t){return r(e)||a(e,t)||i(e,t)||c()},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){e.exports=window.wp.primitives},function(e,t){e.exports=window.wp.url},function(e,t){e.exports=window.lodash},function(e,t){e.exports=function(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))},e.exports.__esModule=!0,e.exports.default=e.exports},,,function(e,t){e.exports=window.wp.data},function(e,t){e.exports=function(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,n){var r;!function(){"use strict";var n={}.hasOwnProperty;function a(){for(var e=[],t=0;te.length)&&(t=e.length);for(var n=0,r=new Array(t);n=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i},e.exports.__esModule=!0,e.exports.default=e.exports},,,,,,,,function(e,t){e.exports=window.wp.notices},function(e,t,n){"use strict";e.exports=n(52)},function(e,t,n){"use strict";var r="function"==typeof Symbol&&Symbol.for,a=r?Symbol.for("react.element"):60103,i=r?Symbol.for("react.portal"):60106,c=r?Symbol.for("react.fragment"):60107,o=r?Symbol.for("react.strict_mode"):60108,s=r?Symbol.for("react.profiler"):60114,l=r?Symbol.for("react.provider"):60109,u=r?Symbol.for("react.context"):60110,p=r?Symbol.for("react.async_mode"):60111,m=r?Symbol.for("react.concurrent_mode"):60111,f=r?Symbol.for("react.forward_ref"):60112,d=r?Symbol.for("react.suspense"):60113,b=r?Symbol.for("react.suspense_list"):60120,y=r?Symbol.for("react.memo"):60115,h=r?Symbol.for("react.lazy"):60116,g=r?Symbol.for("react.block"):60121,v=r?Symbol.for("react.fundamental"):60117,O=r?Symbol.for("react.responder"):60118,j=r?Symbol.for("react.scope"):60119;function _(e){if("object"==typeof e&&null!==e){var t=e.$$typeof;switch(t){case a:switch(e=e.type){case p:case m:case c:case s:case o:case d:return e;default:switch(e=e&&e.$$typeof){case u:case f:case h:case y:case l:return e;default:return t}}case i:return t}}}function w(e){return _(e)===m}t.AsyncMode=p,t.ConcurrentMode=m,t.ContextConsumer=u,t.ContextProvider=l,t.Element=a,t.ForwardRef=f,t.Fragment=c,t.Lazy=h,t.Memo=y,t.Portal=i,t.Profiler=s,t.StrictMode=o,t.Suspense=d,t.isAsyncMode=function(e){return w(e)||_(e)===p},t.isConcurrentMode=w,t.isContextConsumer=function(e){return _(e)===u},t.isContextProvider=function(e){return _(e)===l},t.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===a},t.isForwardRef=function(e){return _(e)===f},t.isFragment=function(e){return _(e)===c},t.isLazy=function(e){return _(e)===h},t.isMemo=function(e){return _(e)===y},t.isPortal=function(e){return _(e)===i},t.isProfiler=function(e){return _(e)===s},t.isStrictMode=function(e){return _(e)===o},t.isSuspense=function(e){return _(e)===d},t.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===c||e===m||e===s||e===o||e===d||e===b||"object"==typeof e&&null!==e&&(e.$$typeof===h||e.$$typeof===y||e.$$typeof===l||e.$$typeof===u||e.$$typeof===f||e.$$typeof===v||e.$$typeof===O||e.$$typeof===j||e.$$typeof===g)},t.typeOf=_},function(e,t){e.exports=function(e,t){if(null==e)return{};var n,r,a={},i=Object.keys(e);for(r=0;r=0||(a[n]=e[n]);return a},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,n){"use strict";var r=n(0),a=n(6);const i=Object(r.createElement)(a.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(a.Path,{d:"M16.7 7.1l-6.3 8.5-3.3-2.5-.9 1.2 4.5 3.4L17.9 8z"}));t.a=i},function(e,t,n){"use strict";var r=n(0),a=n(6);const i=Object(r.createElement)(a.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(a.Path,{d:"M12 3.2c-4.8 0-8.8 3.9-8.8 8.8 0 4.8 3.9 8.8 8.8 8.8 4.8 0 8.8-3.9 8.8-8.8 0-4.8-4-8.8-8.8-8.8zm0 16c-4 0-7.2-3.3-7.2-7.2C4.8 8 8 4.8 12 4.8s7.2 3.3 7.2 7.2c0 4-3.2 7.2-7.2 7.2zM11 17h2v-6h-2v6zm0-8h2V7h-2v2z"}));t.a=i},,,,,,,,,,,function(e,t,n){"use strict";n.r(t);var r=n(5),a=n.n(r),i=n(0),c=(n(50),n(3)),o=n(2),s=n(7),l=n(33),u=n(8),p=n(23),m=n.n(p),f=n(35),d=n(55),b=n(9),y=n.n(b),h=n(17),g=n.n(h),v=n(4),O=function(e){var t=Object.create(null);return function(n){return void 0===t[n]&&(t[n]=e(n)),t[n]}},j=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|download|draggable|encType|enterKeyHint|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,_=O((function(e){return j.test(e)||111===e.charCodeAt(0)&&110===e.charCodeAt(1)&&e.charCodeAt(2)<91}));function w(){return(w=Object.assign||function(e){for(var t=1;t0?L(q,--H):0,I--,10===G&&(I=1,Z--),G}function K(){return G=H2||ne(G)>3?"":" "}function oe(e,t){for(;--t&&K()&&!(G<48||G>102||G>57&&G<65||G>70&&G<97););return te(e,ee()+(t<6&&32==J()&&32==K()))}function se(e,t){for(;K()&&e+G!==57&&(e+G!==84||47!==J()););return"/*"+te(t,H-1)+"*"+N(47===e?e:K())}function le(e){for(;!ne(J());)K();return te(e,H)}function ue(e,t,n,r,a,i,c,o,s,l,u){for(var p=a-1,m=0===a?i:[""],f=W(m),d=0,b=0,y=0;d0?m[h]+" "+g:T(g,/&\f/g,m[h])))&&(s[y++]=v);return Y(e,t,n,0===a?P:o,s,l,u)}function pe(e,t,n){return Y(e,t,n,C,N(G),D(e,2,-2),0)}function me(e,t,n,r){return Y(e,t,n,z,D(e,0,r),D(e,r+1,-1),r)}function fe(e,t){for(var n="",r=W(e),a=0;a-1&&!e.return)switch(e.type){case z:e.return=function e(t,n){switch(function(e,t){return(((t<<2^L(e,0))<<2^L(e,1))<<2^L(e,2))<<2^L(e,3)}(t,n)){case 5103:return k+"print-"+t+t;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return k+t+t;case 5349:case 4246:case 4810:case 6968:case 2756:return k+t+S+t+E+t+t;case 6828:case 4268:return k+t+E+t+t;case 6165:return k+t+E+"flex-"+t+t;case 5187:return k+t+T(t,/(\w+).+(:[^]+)/,k+"box-$1$2"+E+"flex-$1$2")+t;case 5443:return k+t+E+"flex-item-"+T(t,/flex-|-self/,"")+t;case 4675:return k+t+E+"flex-line-pack"+T(t,/align-content|flex-|-self/,"")+t;case 5548:return k+t+E+T(t,"shrink","negative")+t;case 5292:return k+t+E+T(t,"basis","preferred-size")+t;case 6060:return k+"box-"+T(t,"-grow","")+k+t+E+T(t,"grow","positive")+t;case 4554:return k+T(t,/([^-])(transform)/g,"$1"+k+"$2")+t;case 6187:return T(T(T(t,/(zoom-|grab)/,k+"$1"),/(image-set)/,k+"$1"),t,"")+t;case 5495:case 3959:return T(t,/(image-set\([^]*)/,k+"$1$`$1");case 4968:return T(T(t,/(.+:)(flex-)?(.*)/,k+"box-pack:$3"+E+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+k+t+t;case 4095:case 3583:case 4068:case 2532:return T(t,/(.+)-inline(.+)/,k+"$1$2")+t;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(U(t)-1-n>6)switch(L(t,n+1)){case 109:if(45!==L(t,n+4))break;case 102:return T(t,/(.+:)(.+)-([^]+)/,"$1"+k+"$2-$3$1"+S+(108==L(t,n+3)?"$3":"$2-$3"))+t;case 115:return~F(t,"stretch")?e(T(t,"stretch","fill-available"),n)+t:t}break;case 4949:if(115!==L(t,n+1))break;case 6444:switch(L(t,U(t)-3-(~F(t,"!important")&&10))){case 107:return T(t,":",":"+k)+t;case 101:return T(t,/(.+:)([^;!]+)(;|!.+)?/,"$1"+k+(45===L(t,14)?"inline-":"")+"box$3$1"+k+"$2$3$1"+E+"$2box$3")+t}break;case 5936:switch(L(t,n+11)){case 114:return k+t+E+T(t,/[svh]\w+-[tblr]{2}/,"tb")+t;case 108:return k+t+E+T(t,/[svh]\w+-[tblr]{2}/,"tb-rl")+t;case 45:return k+t+E+T(t,/[svh]\w+-[tblr]{2}/,"lr")+t}return k+t+E+t+t}return t}(e.value,e.length);break;case A:return fe([X(e,{value:T(e.value,"@","@"+k)})],r);case P:if(e.length)return function(e,t){return e.map(t).join("")}(e.props,(function(t){switch(function(e,t){return(e=/(::plac\w+|:read-\w+)/.exec(e))?e[0]:e}(t)){case":read-only":case":read-write":return fe([X(e,{props:[T(t,/:(read-\w+)/,":-moz-$1")]})],r);case"::placeholder":return fe([X(e,{props:[T(t,/:(plac\w+)/,":"+k+"input-$1")]}),X(e,{props:[T(t,/:(plac\w+)/,":-moz-$1")]}),X(e,{props:[T(t,/:(plac\w+)/,E+"input-$1")]})],r)}return""}))}}],je=function(e){var t=e.key;if("css"===t){var n=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(n,(function(e){-1!==e.getAttribute("data-emotion").indexOf(" ")&&(document.head.appendChild(e),e.setAttribute("data-s",""))}))}var r,a,i=e.stylisPlugins||Oe,c={},o=[];r=e.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+t+' "]'),(function(e){for(var t=e.getAttribute("data-emotion").split(" "),n=1;n0&&U(x)-m&&B(d>32?me(x+";",a,r,m-1):me(T(x," ","")+";",a,r,m-2),l);break;case 59:x+=";";default:if(B(w=ue(x,n,r,u,p,i,s,O,j=[],_=[],m),c),123===v)if(0===p)e(x,n,w,w,j,c,m,s,_);else switch(f){case 100:case 109:case 115:e(t,w,w,a&&B(ue(t,w,w,0,0,i,s,O,i,j=[],m),_),i,_,m,s,a?j:_);break;default:e(x,w,w,w,[""],_,0,s,_)}}u=p=d=0,y=g=1,O=x="",m=o;break;case 58:m=1+U(x),d=b;default:if(y<1)if(123==v)--y;else if(125==v&&0==y++&&125==Q())continue;switch(x+=N(v),v*y){case 38:g=p>0?1:(x+="\f",-1);break;case 44:s[u++]=(U(x)-1)*g,g=1;break;case 64:45===J()&&(x+=ie(K())),f=J(),p=m=U(O=x+=le(ee())),v++;break;case 45:45===b&&2==U(x)&&(y=0)}}return c}("",null,null,null,[""],e=re(e),0,[0],e))}(e?e+"{"+t.styles+"}":t.styles),p),r&&(m.inserted[t.name]=!0)};var m={key:t,sheet:new x({key:t,container:r,nonce:e.nonce,speedy:e.speedy,prepend:e.prepend,insertionPoint:e.insertionPoint}),nonce:e.nonce,inserted:c,registered:{},insert:a};return m.sheet.hydrate(o),m};function _e(e,t,n){var r="";return n.split(" ").forEach((function(n){void 0!==e[n]?t.push(e[n]+";"):r+=n+" "})),r}n(41);var we=function(e,t,n){var r=e.key+"-"+t.name;if(!1===n&&void 0===e.registered[r]&&(e.registered[r]=t.styles),void 0===e.inserted[t.name]){var a=t;do{e.insert(t===a?"."+r:"",a,e.sheet,!0),a=a.next}while(void 0!==a)}},xe=function(e){for(var t,n=0,r=0,a=e.length;a>=4;++r,a-=4)t=1540483477*(65535&(t=255&e.charCodeAt(r)|(255&e.charCodeAt(++r))<<8|(255&e.charCodeAt(++r))<<16|(255&e.charCodeAt(++r))<<24))+(59797*(t>>>16)<<16),n=1540483477*(65535&(t^=t>>>24))+(59797*(t>>>16)<<16)^1540483477*(65535&n)+(59797*(n>>>16)<<16);switch(a){case 3:n^=(255&e.charCodeAt(r+2))<<16;case 2:n^=(255&e.charCodeAt(r+1))<<8;case 1:n=1540483477*(65535&(n^=255&e.charCodeAt(r)))+(59797*(n>>>16)<<16)}return(((n=1540483477*(65535&(n^=n>>>13))+(59797*(n>>>16)<<16))^n>>>15)>>>0).toString(36)},Ee={animationIterationCount:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},Se=/[A-Z]|^ms/g,ke=/_EMO_([^_]+?)_([^]*?)_EMO_/g,Ce=function(e){return 45===e.charCodeAt(1)},Pe=function(e){return null!=e&&"boolean"!=typeof e},ze=O((function(e){return Ce(e)?e:e.replace(Se,"-$&").toLowerCase()})),Ae=function(e,t){switch(e){case"animation":case"animationName":if("string"==typeof t)return t.replace(ke,(function(e,t,n){return Ne={name:t,styles:n,next:Ne},t}))}return 1===Ee[e]||Ce(e)||"number"!=typeof t||0===t?t:t+"px"};function $e(e,t,n){if(null==n)return"";if(void 0!==n.__emotion_styles)return n;switch(typeof n){case"boolean":return"";case"object":if(1===n.anim)return Ne={name:n.name,styles:n.styles,next:Ne},n.name;if(void 0!==n.styles){var r=n.next;if(void 0!==r)for(;void 0!==r;)Ne={name:r.name,styles:r.styles,next:Ne},r=r.next;return n.styles+";"}return function(e,t,n){var r="";if(Array.isArray(n))for(var a=0;a96?De:Ue},Be=function(e,t,n){var r;if(t){var a=t.shouldForwardProp;r=e.__emotion_forwardProp&&a?function(t){return e.__emotion_forwardProp(t)&&a(t)}:a}return"function"!=typeof r&&n&&(r=e.__emotion_forwardProp),r},Ze=function(){return null},Ie=function e(t,n){var r,a,i=t.__emotion_real===t,c=i&&t.__emotion_base||t;void 0!==n&&(r=n.label,a=n.target);var o=Be(t,n,i),s=o||We(c),l=!s("as");return function(){var u=arguments,p=i&&void 0!==t.__emotion_styles?t.__emotion_styles.slice(0):[];if(void 0!==r&&p.push("label:"+r+";"),null==u[0]||void 0===u[0].raw)p.push.apply(p,u);else{p.push(u[0][0]);for(var m=u.length,f=1;f div {\n\t\tmargin-left: 8px;\n\t}\n\n\tsvg {\n\t\tdisplay: block;\n\n\t\t&:hover {\n\t\t\tcursor: pointer;\n\t\t}\n\t}\n"]))),nt=Je(c.Popover)(Ge||(Ge=y()(["\n\t.components-popover__content {\n\t\tpadding: 20px;\n\t\twidth: 200px;\n\t}\n"]))),rt=Je(c.ToggleControl)(qe||(qe=y()(["\n\t&& {\n\t\t.components-base-control__field {\n\t\t\tmargin-bottom: 0;\n\t\t}\n\t}\n"]))),at=n(42),it=n.n(at),ct=Je(c.Card)(Ye||(Ye=y()(["\n\tpadding: 30px;\n\n\t&& {\n\t\tbox-shadow: 0 2px 6px 0 rgba( 0, 0, 0, 0.05 );\n\t\tborder: 1px solid #ccc;\n\t\twidth: 100%;\n\t}\n"]))),ot=Je(c.CardHeader)(Xe||(Xe=y()(["\n\t&&& {\n\t\tpadding: 0 0 30px;\n\t}\n\n\th1 {\n\t\tfont-size: 26px;\n\t\tline-height: 1;\n\t\tmargin: 0;\n\t\tpadding: 0;\n\t}\n\n\tsmall {\n\t\tcolor: #c0c0c0;\n\t\tfont-size: 13px;\n\t\tfont-weight: normal;\n\t\tdisplay: block;\n\t\tmargin: 0 0 3px;\n\t}\n"]))),st=Je(c.CardFooter)(Qe||(Qe=y()(["\n\t&&& {\n\t\tpadding: 30px 0 0;\n\t}\n"]))),lt=Je(c.CardBody)(Ke||(Ke=y()(["\n\t&&& {\n\t\tpadding: 30px 0;\n\t}\n\n\t> * {\n\t\tmargin: 0 0 2rem;\n\n\t\t&:last-child {\n\t\t\tmargin-bottom: 0;\n\t\t}\n\t}\n\n\t> p {\n\t\tcolor: #555555;\n\t\tfont-size: 15px;\n\t}\n"]))),ut=["title","supTitle","children"];function pt(e){return Object(i.createElement)(ct,e)}function mt(e){var t=e.title,n=e.supTitle,r=e.children,a=it()(e,ut);return Object(i.createElement)(ot,a,Object(i.createElement)("div",null,n&&Object(i.createElement)("small",null,n),t&&Object(i.createElement)("h1",null,t)),r)}function ft(e){return Object(i.createElement)(st,e)}function dt(e){return Object(i.createElement)(lt,e)}var bt,yt=simpaySetupWizard.adminUrl;function ht(e){var t=e.isFirst,n=Object(i.useState)(!1),r=a()(n,2),s=r[0],l=r[1];return Object(i.createElement)(c.Flex,{justify:"center"},s&&Object(i.createElement)(c.Modal,{title:Object(o.__)("Are you sure you want to exit the wizard?","simple-pay"),onRequestClose:function(){return l(!1)}},Object(i.createElement)("p",{style:{marginBottom:"2rem"}},Object(o.__)("Manual setup is only recommended for experienced users.","simple-pay")),Object(i.createElement)(c.Flex,null,Object(i.createElement)(c.Button,{href:yt,isDestructive:!0,variant:"destructive"},Object(o.__)("Exit Setup Wizard","simple-pay")),Object(i.createElement)(c.Button,{variant:"primary",isPrimary:!0,onClick:function(){return l(!1)}},Object(o.__)("Continue Setup","simple-pay")))),Object(i.createElement)(c.Button,{isLink:!0,variant:"link",className:"simpay-setup-wizard-subtle-link",onClick:function(){return l(!0)}},t?Object(o.__)("Go back to the Dashboard","simple-pay"):Object(o.__)("Close and exit the Setup Wizard","simple-pay")))}var gt=Je(c.Button)(bt||(bt=y()(["\n\t&& {\n\t\tfont-size: 16px;\n\t\tfont-weight: bold;\n\t\tpadding: 15px 30px !important;\n\t\theight: auto;\n\t}\n"]))),vt=Object(i.forwardRef)((function(e,t){return Object(i.createElement)(gt,g()({isPrimary:!0,variant:"primary"},e,{ref:t}))}));function Ot(e){var t=e.width;return Object(i.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1200 251",xmlSpace:"preserve",fillRule:"evenodd",clipRule:"evenodd",strokeLinejoin:"round",strokeMiterlimit:2,style:{width:t}},Object(i.createElement)("path",{d:"M1141.285 88.98V78.438c0-13.067 10.682-23.724 23.789-23.724 13.106 0 23.788 10.657 23.788 23.724v10.544h6.649c2.494 0 4.536 1.995 4.496 4.518v39.162c0 2.485-2.042 4.519-4.537 4.519h-60.833c-2.495 0-4.537-2.034-4.537-4.52V93.5c0-2.483 2.032-4.514 4.537-4.518h6.648Zm49.66 39.124V97.98h-51.782v30.124h51.781ZM1175.342 0c6.991.004 12.694 5.688 12.694 12.653v32.571c0 2.486-2.042 4.52-4.536 4.52s-4.527-2.034-4.527-4.52v-9.036h-154.277v68.758c0 1.996 1.63 3.615 3.631 3.615h87.459c2.535 0 4.577 2.033 4.577 4.519s-2.042 4.52-4.537 4.52h-87.499c-6.99 0-12.693-5.687-12.693-12.654V12.653c0-6.965 5.662-12.649 12.693-12.653h147.015Zm-106.197 81.412c2.494.004 4.536 2.035 4.536 4.519s-2.042 4.518-4.536 4.518h-21.787c-2.494 0-4.536-2.034-4.536-4.518s2.042-4.515 4.536-4.52h21.787Zm110.653 7.53V78.4c0-8.096-6.608-14.685-14.725-14.685-8.118 0-14.726 6.589-14.726 14.685v10.543h29.451Zm-77.983-23.723c2.494.005 4.526 2.037 4.526 4.52a4.513 4.513 0 0 1-4.526 4.518h-54.457c-2.494 0-4.536-2.033-4.536-4.518 0-2.483 2.042-4.515 4.536-4.52h54.457Zm-.533-16.38c2.504.005 4.536 2.037 4.536 4.52 0 2.485-2.042 4.518-4.536 4.518h-54.457a4.513 4.513 0 0 1-4.526-4.519c0-2.482 2.031-4.514 4.526-4.519h54.457Zm77.691-21.689V12.653a3.625 3.625 0 0 0-3.63-3.615h-147.016c-2.001 0-3.671 1.62-3.671 3.615V27.15h154.317Z",fill:"#428bca"}),Object(i.createElement)("path",{d:"m1082.047 217.635-11.642 29.874c-.394.922-1.381 1.66-2.96 2.212-1.578.37-3.946.738-7.103.738-1.578 0-2.96-.184-3.946-.184-1.184-.185-1.973-.554-2.368-.922-.592-.37-.987-.738-.987-1.291 0-.738 0-1.475.395-2.213l12.036-28.214c-.592-.185-1.184-.553-1.578-1.107-.592-.553-.987-1.106-1.184-1.844l-30.781-77.45c-.592-1.106-.79-2.213-.79-2.95 0-.738.198-1.291.79-1.66.394-.369 1.184-.738 2.368-.922 1.183 0 2.762-.185 4.735-.185 1.776 0 3.354 0 4.538.185.987 0 1.973.184 2.565.553.592.185.987.553 1.382.922.197.553.592 1.107.789 1.844l24.862 65.095h.197l24.072-65.464c.198-1.106.79-1.844 1.381-2.212a11.34 11.34 0 0 1 2.368-.738c1.184 0 2.763-.185 4.736-.185 1.776 0 3.354.185 4.34.185 1.185.184 2.171.553 2.566.922.592.369.986.922.986 1.66 0 .737-.197 1.66-.592 2.766l-31.175 80.585Zm-59.528-2.213c0 .738-.394 1.29-.789 1.66-.592.368-1.184.553-2.17.737-.79.185-2.17.37-3.947.37-1.578 0-2.96-.185-3.946-.37-.987-.184-1.776-.369-2.17-.737-.395-.37-.79-.922-.79-1.66v-8.114c-3.749 3.873-7.892 6.823-12.628 8.852-4.538 2.212-9.47 3.135-14.798 3.135-4.539 0-8.682-.554-12.234-1.66-3.749-1.107-6.906-2.582-9.471-4.795-2.762-2.028-4.736-4.61-6.117-7.745-1.38-2.95-2.17-6.454-2.17-10.51 0-4.427.986-8.483 2.96-11.803s4.932-6.085 8.681-8.298c3.552-2.213 8.288-3.873 13.615-4.979a89.464 89.464 0 0 1 18.153-1.844h12.036v-6.27c0-3.135-.394-5.9-1.184-8.298-.592-2.397-1.776-4.241-3.354-5.901-1.579-1.66-3.552-2.766-6.117-3.688-2.565-.738-5.525-1.107-9.274-1.107-3.946 0-7.498.37-10.457 1.291-3.157.922-5.92 1.844-8.287 2.95-2.368.923-4.341 1.845-5.92 2.767-1.578.922-2.762 1.29-3.354 1.29-.592 0-.987 0-1.381-.368a1.93 1.93 0 0 1-.987-1.107c-.395-.368-.592-1.106-.79-1.844 0-.737-.197-1.475-.197-2.397 0-1.475.198-2.766.395-3.504.197-.922.79-1.844 1.579-2.581.986-.738 2.367-1.66 4.538-2.766 2.17-.922 4.538-2.029 7.3-2.766 2.763-.922 5.92-1.66 9.077-2.213 3.354-.554 6.511-.922 9.866-.922 6.314 0 11.641.737 15.982 2.028 4.341 1.291 7.893 3.32 10.655 5.901 2.565 2.397 4.538 5.717 5.722 9.405 1.381 3.872 1.973 8.298 1.973 13.277v54.584Zm-15.785-36.881H993.12c-4.34 0-8.287.184-11.444.922s-5.92 1.66-7.892 3.135c-2.17 1.29-3.75 2.95-4.736 4.794-.986 1.844-1.578 4.057-1.578 6.639 0 4.057 1.578 7.56 4.34 9.958 2.96 2.582 6.907 3.688 12.037 3.688 4.143 0 8.09-.922 11.641-2.95 3.552-2.029 7.3-4.98 11.247-9.036v-17.15Zm-63.44-43.335c0 5.9-.987 11.064-2.96 15.858-2.17 4.61-5.13 8.668-8.88 11.987-3.946 3.32-8.484 5.716-14.009 7.56-5.722 1.845-12.233 2.767-19.928 2.767H883.31v41.86c0 .553-.197.922-.395 1.29-.394.37-.789.738-1.38.922-.593.185-1.382.37-2.566.554-.987.184-2.368.184-3.946.184-1.579 0-2.96 0-3.947-.184-1.183-.185-1.973-.37-2.565-.554-.592-.184-1.184-.553-1.38-.922-.198-.368-.395-.737-.395-1.29V107.729c0-2.397.591-4.057 1.973-5.163 1.38-.922 2.96-1.475 4.538-1.475h26.637c2.763 0 5.328.184 7.893.368a63.42 63.42 0 0 1 8.682 1.291 38.896 38.896 0 0 1 10.26 3.873c3.552 1.844 6.512 4.241 9.077 7.007 2.367 2.766 4.143 5.901 5.524 9.59 1.382 3.687 1.974 7.56 1.974 11.986Zm-17.364 1.29c0-4.794-.987-8.667-2.96-11.802-1.776-3.319-4.143-5.716-6.906-7.191-2.762-1.476-5.722-2.582-8.682-2.95-2.96-.37-5.92-.738-8.681-.738H883.31v46.839h14.996c4.933 0 9.076-.554 12.43-1.844 3.355-1.107 6.117-2.767 8.288-4.98 2.368-2.212 3.946-4.61 5.13-7.56 1.184-3.135 1.776-6.27 1.776-9.774ZM805.708 171.35c0 2.397-.592 4.057-1.973 4.979-1.184.922-2.763 1.475-4.341 1.475H742.37c0 4.61.394 8.667 1.381 12.171.987 3.688 2.565 6.639 4.933 9.22 2.17 2.582 5.13 4.61 8.682 6.086 3.749 1.29 8.09 2.028 13.417 2.028 4.144 0 7.695-.369 11.05-.922 3.157-.737 5.92-1.475 8.287-2.213a77.69 77.69 0 0 0 5.722-2.028c1.579-.738 2.762-.922 3.552-.922.394 0 .789 0 1.184.184.394.185.592.553.789.922.197.553.394 1.107.394 1.844.198.738.198 1.66.198 2.766v2.029c-.198.553-.198 1.106-.395 1.475 0 .553-.197.922-.394 1.29-.198.37-.592.739-.79.923-.394.369-1.381.922-3.157 1.66-1.776.737-3.946 1.475-6.708 2.212a94.74 94.74 0 0 1-9.669 2.029c-3.552.553-7.498.738-11.641.738-7.104 0-13.418-.923-18.745-2.767-5.328-1.844-9.866-4.61-13.418-8.298-3.749-3.688-6.511-8.298-8.287-13.646-1.973-5.532-2.96-11.986-2.96-19.362 0-7.008.987-13.278 2.96-18.81 1.973-5.532 4.736-10.142 8.287-14.015 3.75-3.872 8.09-7.007 13.22-9.035 5.13-2.029 10.853-3.135 17.167-3.135 6.906 0 12.628 1.106 17.363 3.135 4.933 2.028 8.88 4.794 11.84 8.298 3.156 3.32 5.327 7.376 6.905 12.17a51.475 51.475 0 0 1 2.17 14.753v2.766Zm-15.983-4.426c.198-7.745-1.776-13.83-5.722-18.44-3.749-4.426-9.668-6.639-17.364-6.639-3.946 0-7.3.738-10.26 2.213-2.96 1.29-5.525 3.135-7.498 5.348-1.973 2.397-3.552 4.979-4.735 8.114-.987 2.95-1.579 6.085-1.776 9.404h47.355Zm-82.18 48.499c0 .369 0 .922-.394 1.106-.197.37-.592.738-1.184.922s-1.381.37-2.368.554c-.986.184-2.368.184-3.946.184-1.579 0-2.96 0-3.946-.184-.987-.185-1.776-.37-2.368-.554-.592-.184-.987-.553-1.381-.922-.198-.184-.198-.737-.198-1.106V95.005c0-.369 0-.737.198-1.106.394-.369.789-.738 1.38-.922.593-.37 1.382-.553 2.369-.553.986-.185 2.367-.185 3.946-.185 1.578 0 2.96 0 3.946.185.987 0 1.776.184 2.368.553.592.184.987.553 1.184.922.395.369.395.737.395 1.106v120.417Zm-34.41-41.86c0 7.192-.789 13.462-2.367 19.178-1.776 5.532-4.144 10.327-7.3 14.384-3.158 3.872-7.104 6.823-11.84 9.036-4.735 2.028-10.063 3.135-15.982 3.135-2.565 0-4.933-.185-7.3-.738-2.171-.369-4.144-1.107-6.315-2.213-2.17-.922-4.144-2.213-6.314-3.872-1.973-1.476-4.144-3.32-6.511-5.533v40.57c0 .553 0 .922-.395 1.29-.197.37-.592.738-1.184.922-.592.185-1.381.37-2.368.554-.986 0-2.367.184-3.946.184-1.578 0-2.96-.184-3.946-.184-.987-.185-1.776-.37-2.368-.554-.592-.184-.987-.553-1.381-.922-.198-.368-.198-.737-.198-1.29V134.284c0-.554 0-.922.198-1.291.197-.37.592-.553 1.184-.738.592-.369 1.38-.553 2.17-.553.987-.185 1.973-.185 3.354-.185 1.382 0 2.368 0 3.355.185.79 0 1.578.184 2.17.553.592.185.987.369 1.184.738.197.369.395.737.395 1.29v10.88c2.565-2.397 5.13-4.61 7.498-6.454 2.368-1.844 4.933-3.503 7.3-4.61 2.565-1.29 5.13-2.213 7.696-2.95 2.565-.554 5.327-.922 8.287-.922 6.314 0 11.641 1.29 15.982 3.503 4.539 2.213 8.09 5.348 10.853 9.405 2.762 3.873 4.933 8.483 6.116 13.83 1.382 5.164 1.974 10.696 1.974 16.597Zm-16.377 1.844c0-4.241-.394-8.298-1.183-12.17-.592-3.873-1.776-7.193-3.355-10.327-1.776-2.951-3.946-5.348-6.708-7.192-2.763-1.66-6.315-2.582-10.458-2.582-1.973 0-3.946.184-6.117.738-1.973.553-3.946 1.475-5.92 2.766-2.17 1.29-4.34 2.766-6.51 4.794-2.369 2.029-4.736 4.61-7.301 7.56v32.087c4.538 4.98 8.681 8.852 12.628 11.434 3.946 2.766 8.09 4.057 12.43 4.057 3.947 0 7.301-.922 10.26-2.767 2.763-1.66 5.131-4.056 6.907-7.191a32.374 32.374 0 0 0 3.946-9.958c.79-3.873 1.381-7.56 1.381-11.249Zm-86.981 40.016c0 .369-.197.922-.395 1.106-.394.37-.79.738-1.381.922-.592.185-1.381.37-2.368.554-.986.184-2.368.184-3.749.184-1.776 0-2.96 0-3.946-.184-1.184-.185-1.973-.37-2.565-.554-.592-.184-.987-.553-1.381-.922-.198-.184-.198-.737-.198-1.106v-49.236c0-3.504-.394-6.639-.986-9.405-.79-2.766-1.776-5.348-3.157-7.376-1.381-2.029-3.157-3.504-5.328-4.61-2.17-1.107-4.735-1.66-7.695-1.66-3.749 0-7.498 1.29-11.05 4.057-3.749 2.582-7.892 6.454-12.233 11.618v56.612c0 .369-.197.922-.395 1.106-.197.37-.789.738-1.381.922-.592.185-1.381.37-2.368.554-.986.184-2.368.184-3.946.184-1.381 0-2.762 0-3.749-.184a55.016 55.016 0 0 1-2.565-.554c-.592-.184-.987-.553-1.184-.922-.197-.184-.395-.737-.395-1.106v-49.236c0-3.504-.197-6.639-.986-9.405-.79-2.766-1.776-5.348-3.157-7.376-1.381-2.029-3.157-3.504-5.328-4.61-2.17-1.107-4.735-1.66-7.695-1.66-3.749 0-7.3 1.29-11.05 4.057-3.749 2.582-7.892 6.454-12.233 11.618v56.612c0 .369 0 .922-.395 1.106-.197.37-.592.738-1.184.922s-1.38.37-2.367.554c-.987.184-2.368.184-3.947.184-1.578 0-2.96 0-3.946-.184-.987-.185-1.776-.37-2.368-.554-.592-.184-.986-.553-1.381-.922-.197-.184-.197-.737-.197-1.106v-81.138c0-.37 0-.738.197-1.107s.592-.737 1.184-.922c.592-.369 1.381-.553 2.17-.553.987-.185 2.17-.185 3.552-.185 1.381 0 2.565 0 3.552.185.986 0 1.776.184 2.17.553.592.185.987.553 1.184.922.197.369.197.738.197 1.107v10.695c4.933-4.979 9.669-8.667 14.207-11.064 4.736-2.398 9.274-3.688 14.01-3.688 3.551 0 6.905.368 9.668 1.29 2.96.738 5.327 1.845 7.498 3.32 2.367 1.29 4.143 2.95 5.722 4.979 1.578 1.844 2.762 4.057 3.749 6.454a95.95 95.95 0 0 1 8.287-7.376 53.41 53.41 0 0 1 7.498-4.98c2.368-1.29 4.736-2.212 7.103-2.765 2.17-.554 4.539-.922 6.906-.922 5.525 0 10.26.922 14.01 2.766 3.749 1.844 6.906 4.241 9.273 7.376 2.17 3.135 3.947 6.639 4.933 10.695.987 4.242 1.579 8.483 1.579 13.093v51.265Zm-152.818 0c0 .369 0 .922-.395 1.106-.197.37-.592.738-1.184.922s-1.381.37-2.368.554c-.986.184-2.368.184-3.946.184-1.579 0-2.96 0-3.946-.184-.987-.185-1.776-.37-2.368-.554-.592-.184-.987-.553-1.381-.922-.198-.184-.198-.737-.198-1.106v-81.138c0-.37 0-.738.198-1.107.394-.369.789-.737 1.38-.922.593-.184 1.382-.369 2.369-.553.986 0 2.367-.185 3.946-.185 1.578 0 2.96.185 3.946.185.987.184 1.776.369 2.368.553.592.185.987.553 1.184.922.395.369.395.738.395 1.107v81.138Zm1.973-108.43c0 3.503-.79 5.9-2.17 7.007-1.382 1.29-4.144 2.028-7.893 2.028-3.75 0-6.314-.737-7.696-1.844-1.38-1.29-1.973-3.688-1.973-7.007 0-3.504.79-5.901 2.17-7.192 1.382-1.29 3.947-1.844 7.696-1.844 3.749 0 6.314.553 7.695 1.844 1.381 1.291 2.17 3.504 2.17 7.008Zm-34.426 78.003c0 5.348-.987 10.327-3.158 14.568-2.17 4.241-5.13 7.93-8.879 10.88-3.946 2.95-8.484 5.163-13.614 6.639-5.13 1.475-10.655 2.213-16.772 2.213-4.144 0-7.893-.37-11.444-.923-3.552-.737-6.906-1.475-9.669-2.397-2.762-.922-5.13-2.028-6.906-2.95-1.973-1.107-3.354-2.029-3.946-2.766-.79-.554-1.381-1.476-1.776-2.582a27.177 27.177 0 0 1-.395-4.61c0-1.291 0-2.397.198-3.135 0-.922.197-1.66.592-2.213.197-.553.592-.922.789-1.106.395-.185.987-.37 1.381-.37.987 0 2.17.554 3.946 1.66 1.579.922 3.75 2.029 6.315 3.32 2.565 1.106 5.524 2.213 9.273 3.32 3.552 1.106 7.696 1.474 12.431 1.474 3.75 0 6.906-.368 9.866-1.29 3.157-.923 5.722-2.213 7.892-3.873 1.974-1.66 3.75-3.688 4.933-6.085 1.184-2.398 1.579-4.98 1.579-8.114 0-3.32-.79-6.086-2.368-8.483-1.578-2.397-3.749-4.426-6.314-6.085-2.565-1.844-5.722-3.504-9.076-4.98-3.355-1.474-6.71-2.95-10.26-4.425-3.552-1.475-6.907-3.32-10.261-5.163-3.355-1.844-6.314-4.057-9.077-6.455-2.565-2.581-4.735-5.532-6.314-8.851-1.776-3.504-2.565-7.56-2.565-12.355 0-4.795.987-9.036 2.96-12.909 1.776-3.872 4.538-7.007 7.892-9.589 3.355-2.581 7.301-4.61 12.037-5.9 4.538-1.291 9.668-2.03 14.996-2.03 2.762 0 5.524.185 8.287.739 2.96.368 5.525.922 7.892 1.66 2.565.737 4.736 1.659 6.71 2.58 1.972.923 3.156 1.66 3.748 2.214.592.553.987 1.106 1.184 1.475.197.184.395.738.592 1.106 0 .554.197 1.107.197 1.844.198.738.198 1.66.198 2.767 0 1.106-.198 2.212-.198 2.95-.197.922-.197 1.66-.394 2.213-.198.553-.592.922-.79 1.106-.394.37-.789.554-1.184.554-.789 0-1.973-.554-3.354-1.291-1.578-.922-3.354-1.844-5.525-2.95-2.17-.923-4.933-1.845-7.892-2.767-2.96-.922-6.314-1.29-10.063-1.29-3.355 0-6.512.368-9.077 1.29-2.565.922-4.538 2.029-6.314 3.504-1.578 1.29-2.96 3.135-3.749 4.979-.79 2.028-1.184 4.241-1.184 6.454 0 3.135.79 5.901 2.368 8.298 1.579 2.398 3.749 4.426 6.314 6.27 2.762 1.66 5.722 3.32 9.274 4.979 3.354 1.475 6.709 2.95 10.26 4.426 3.552 1.66 7.104 3.319 10.458 5.163 3.354 1.66 6.511 3.873 9.076 6.454 2.763 2.398 4.933 5.348 6.512 8.852 1.578 3.319 2.368 7.376 2.368 11.986Zm-127.083-49.79c0 5.902-.987 11.065-2.96 15.86-2.17 4.61-5.13 8.667-8.88 11.986-3.946 3.32-8.484 5.716-14.009 7.56-5.722 1.845-12.233 2.767-19.928 2.767h-14.207v41.86c0 .553-.197.922-.395 1.29-.394.37-.789.738-1.38.922-.593.185-1.382.37-2.566.554-.987.184-2.368.184-3.946.184-1.579 0-2.96 0-3.947-.184-1.183-.185-1.973-.37-2.565-.554-.592-.184-1.184-.553-1.38-.922-.198-.368-.395-.737-.395-1.29v-107.51c0-2.397.591-4.057 1.973-5.163 1.38-.922 2.96-1.475 4.538-1.475h26.637c2.763 0 5.328.184 7.893.368a63.42 63.42 0 0 1 8.682 1.291 38.896 38.896 0 0 1 10.26 3.873c3.552 1.844 6.512 4.241 9.077 7.007 2.367 2.766 4.143 5.901 5.524 9.59 1.382 3.687 1.974 7.56 1.974 11.986Zm-17.364 1.291c0-4.794-.987-8.667-2.96-11.802-1.776-3.319-4.143-5.716-6.906-7.191-2.762-1.476-5.722-2.582-8.682-2.95-2.96-.37-5.92-.738-8.681-.738h-15.391v46.839h14.996c4.933 0 9.076-.554 12.43-1.844 3.355-1.107 6.117-2.767 8.288-4.98 2.368-2.212 3.946-4.61 5.13-7.56 1.184-3.135 1.776-6.27 1.776-9.774Zm-110.032 77.635c-.197.922-.592 1.66-1.184 2.029-.394.553-1.184.922-2.17 1.29-.79.185-1.973.37-3.157.554-1.381.184-2.96.184-4.933.184-1.973 0-3.749 0-5.13-.184-1.381-.185-2.565-.37-3.355-.554-.986-.368-1.578-.737-1.973-1.29-.592-.37-.789-1.107-1.184-2.029L80.896 126.17h-.197l-24.073 87.96c-.197.922-.592 1.66-.986 2.029-.395.553-1.184.922-1.974 1.29-.789.185-1.775.37-3.157.554-1.38.184-2.96.184-5.13.184-1.973 0-3.749 0-5.327-.184-1.381-.185-2.565-.37-3.355-.554-.986-.368-1.578-.737-2.17-1.29-.395-.37-.79-1.107-.987-2.029L.59 106.623c-.395-1.475-.592-2.398-.592-3.32 0-.737.197-1.29.79-1.66.591-.552 1.38-.737 2.564-.921 1.381 0 2.96-.185 4.933-.185 1.973 0 3.552 0 4.736.185 1.184 0 2.17.184 2.762.553.592.184.987.553 1.184.922.197.369.395.922.592 1.66l28.019 97.55 26.637-97.366c.197-.738.395-1.29.79-1.66.197-.553.591-.922 1.38-1.106.592-.184 1.579-.369 2.763-.553 1.184 0 2.762-.185 4.538-.185 1.776 0 3.355.185 4.341.185.987.184 1.973.369 2.565.553.592.184 1.184.553 1.381 1.106.395.37.592.922.79 1.66l28.61 97.366h.198l27.426-97.55c.198-.554.395-1.107.592-1.476.198-.553.592-.922 1.184-1.106.592-.184 1.381-.369 2.565-.553 1.184 0 2.565-.185 4.538-.185 1.974 0 3.355.185 4.539.185 1.184.184 1.973.553 2.367.922.592.369.79 1.106.79 1.844 0 .737-.198 1.844-.592 3.135L130.027 214.13Z",fill:"#428bca",fillRule:"nonzero"}))}var jt=n(12);function _t(e){var t=Object(jt.useSelect)((function(e){return Object(u.filter)(e("core/notices").getNotices(),{type:"snackbar"})}),[]),n=Object(jt.useDispatch)("core/notices").removeNotice;return 0===t.length?null:Object(i.createElement)(c.SnackbarList,g()({onRemove:n,notices:t},e))}var wt,xt,Et,St,kt,Ct=n(54),Pt=Je.div(wt||(wt=y()(["\n\tmax-width: 80%;\n\tdisplay: flex;\n\talign-items: center;\n\n\t> * {\n\t\tmargin-right: 8px;\n\n\t\t&:last-child {\n\t\t\tmargin-right: 0;\n\t\t}\n\t}\n"]))),zt={current:"var(--wp-admin-theme-color)",complete:"var(--wp-admin-theme-color)",incomplete:"#c0c0c0"},At=Je.div(xt||(xt=y()(["\n\twidth: 16px;\n\theight: 16px;\n\tborder-radius: 50%;\n\tbackground-color: ",";\n\tflex-shrink: 0;\n\tposition: relative;\n\ttransition: backgroundColor 0.2s ease-in-out;\n\n\tsvg {\n\t\tfill: #fff;\n\t\tposition: absolute;\n\t\tleft: -1px;\n\t\ttop: -1px;\n\t\ttransition: opacity 0.2s ease-in-out;\n\t\topacity: ",";\n\t}\n\n\tdiv {\n\t\topacity: ",";\n\t}\n\n\tpath {\n\t\tstroke: #fff;\n\t}\n"])),(function(e){return zt[e.status]}),(function(e){return e.isComplete?"1":"0"}),(function(e){var t=e.isCurrent,n=e.isComplete;return t&&!n?"1":"0"})),$t=Je.div(Et||(Et=y()(["\n\twidth: 6px;\n\theight: 6px;\n\tbackground-color: #f0f0f1;\n\tborder-radius: 50%;\n\tposition: absolute;\n\ttop: 5px;\n\tleft: 5px;\n\ttransition: opacity 0.2s ease-in-out;\n"]))),Nt=Je.div(St||(St=y()(["\n\twidth: 100%;\n\theight: 2px;\n\tbackground-color: rgba( 192, 192, 192, 0.5 );\n\twidth: 100px;\n"])));function Mt(e){for(var t=e.current,n=e.total,r=[],a=1;a<=n;a++){var c="incomplete";a * {\n\t\tmargin: 25px 0;\n\t}\n"])));function Ft(e){return Object(i.createElement)(Tt,e)}var Lt=Je(c.Button)(Rt||(Rt=y()(["\n\t&&&& {\n\t\tfont-size: 16px;\n\t\tfont-weight: bold;\n\t\tpadding: 13px 30px 12px !important;\n\t\theight: auto;\n\t\tbackground-color: #635bff;\n\n\t\t&:focus {\n\t\t\tbackground-color: #635bff;\n\t\t\tbox-shadow: inset 0 0 0 1px #fff,\n\t\t\t\t0 0 0 var( --wp-admin-border-width-focus ) #635bff;\n\t\t}\n\n\t\t&:hover {\n\t\t\tbackground-color: #0a2540 !important;\n\t\t}\n\n\t\t&:focus:hover {\n\t\t\tbox-shadow: inset 0 0 0 1px #fff,\n\t\t\t\t0 0 0 var( --wp-admin-border-width-focus ) #0a2540;\n\t\t}\n\n\t\tsvg {\n\t\t\tmargin-left: 5px;\n\t\t}\n\t}\n"]))),Dt=Object(i.forwardRef)((function(e,t){return Object(i.createElement)(Lt,g()({isPrimary:!0,variant:"primary"},e,{ref:t}))}));function Ut(){return Object(i.createElement)("svg",{width:56,height:23,fill:"none",xmlns:"http://www.w3.org/2000/svg"},Object(i.createElement)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M55.742 11.884c0-3.93-1.92-7.032-5.59-7.032-3.684 0-5.914 3.101-5.914 7.001 0 4.622 2.632 6.955 6.41 6.955 1.843 0 3.236-.414 4.29-.998v-3.07c-1.053.522-2.261.844-3.794.844-1.502 0-2.834-.522-3.004-2.334h7.572c0-.2.03-.998.03-1.366Zm-7.649-1.459c0-1.735 1.069-2.456 2.044-2.456.945 0 1.951.721 1.951 2.456h-3.995Zm-9.832-5.573c-1.517 0-2.493.706-3.035 1.197l-.201-.952h-3.407V23l3.871-.814.016-4.345c.557.4 1.378.967 2.74.967 2.772 0 5.296-2.21 5.296-7.078-.015-4.452-2.57-6.878-5.28-6.878Zm-.929 10.579c-.913 0-1.456-.323-1.827-.722l-.016-5.696c.403-.446.96-.753 1.843-.753 1.41 0 2.385 1.566 2.385 3.578 0 2.057-.96 3.593-2.385 3.593ZM26.292 3.946l3.886-.83V0l-3.886.814v3.132Zm0 1.167h3.886v13.434h-3.886V5.113Zm-4.165 1.136-.248-1.136h-3.345v13.434h3.871V9.443c.914-1.183 2.462-.968 2.942-.799V5.113c-.495-.184-2.307-.522-3.22 1.136Zm-7.742-4.468-3.778.798-.016 12.299c0 2.272 1.719 3.946 4.01 3.946 1.27 0 2.2-.23 2.71-.507V15.2c-.495.2-2.942.906-2.942-1.366v-5.45h2.942V5.112H14.37l.016-3.332ZM3.917 9.013c0-.6.496-.83 1.317-.83 1.176 0 2.663.354 3.84.983V5.558c-1.286-.507-2.555-.706-3.84-.706C2.09 4.852 0 6.479 0 9.197c0 4.238 5.884 3.562 5.884 5.39 0 .705-.62.936-1.487.936-1.285 0-2.926-.522-4.227-1.229v3.655c1.44.614 2.896.875 4.227.875 3.221 0 5.435-1.582 5.435-4.33-.015-4.575-5.915-3.762-5.915-5.481Z",fill:"#fff"}))}var Wt=n(13),Bt=n.n(Wt);function Zt(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function It(e){for(var t=1;tWP Simple Pay account or purchase receipt email.","simple-pay"),{strong:Object(i.createElement)("strong",null),a:Object(i.createElement)("a",{href:rn,target:"_blank",rel:"noopener noreferrer"})})),Object(i.createElement)(c.TextControl,{label:Object(o.__)("License Key","simple-pay"),value:l,className:_,onChange:function(e){return u(e)},disabled:d,help:g||Object(o.__)("An active license ensures automatic updates and the latest features.","simple-pay"),ref:j})),Object(i.createElement)(ft,{justify:"flex-end",align:"center"},Object(i.createElement)(vt,{onClick:function(){b(!0);var e=new FormData;e.append("action","simpay_activate_license"),e.append("nonce",an),e.append("license",l),m()({url:nn,method:"POST",body:e}).then((function(e){var r=e.success,a=e.data,i=a.message,c=a.license;if(!r)throw{message:i};n(c),O(Object(o.__)("License activated","simple-pay"),{type:"snackbar"}),b(!1),t()})).catch((function(e){var t=e.message;v(t),b(!1)}))},disabled:""===l||d,isBusy:d},Object(o.__)("Activate and Continue →","simple-pay"))))}},{id:"stripe",title:Object(o.__)("Connect to Stripe","simple-pay"),content:Cn},{id:"emails",title:Object(o.__)("Configure Emails","simple-pay"),content:function(e){var t=e.goPrev,n=e.goNext,r=e.licenseData,a=Ht(),s=a.settings,l=a.rawSettings,p=a.discardChanges,m=a.editSettings,f=a.saveSettings,d=Object(i.useRef)();if(Object(i.useLayoutEffect)((function(){d.current&&d.current.focus()}),[l]),Object(u.isEmpty)(s))return Object(i.createElement)(dt,null,Object(i.createElement)(c.Spinner,null));var b=s["email_payment-confirmation"],y=s["email_payment-notification"],h=s["email_payment-notification_to"],g=s["email_upcoming-invoice"],v=s["email_invoice-confirmation"],O=r.features,j=O.subscriptions,_=O.enhanced_subscriptions;return Object(i.createElement)(i.Fragment,null,Object(i.createElement)(dt,null,Object(i.createElement)("ul",{className:"simpay-setup-wizard-toggle-list"},Object(i.createElement)("li",null,Object(i.createElement)("label",{htmlFor:"email_payment-confirmation"},Object(i.createElement)("h3",null,Object(o.__)("Payment Receipt","simple-pay")),Object(i.createElement)("p",null,Object(o.__)("Send a payment receipt email to the customer upon successful payment.","simple-pay"))),Object(i.createElement)(c.FormToggle,{id:"email_payment-confirmation",checked:"no"!==b,onChange:function(e){var t=e.target;return m({"email_payment-confirmation":t.checked?"yes":"no"})}})),Object(i.createElement)("li",null,Object(i.createElement)("label",{htmlFor:"email_payment-notification"},Object(i.createElement)("h3",null,Object(o.__)("Payment Notification","simple-pay")),Object(i.createElement)("p",null,Object(o.__)("Receive an email notification when a new payment is made.","simple-pay"))),Object(i.createElement)(c.FormToggle,{id:"email_payment-notification",checked:"no"!==y,onChange:function(e){var t=e.target;return m({"email_payment-notification":t.checked?"yes":"no"})}})),"no"!==y&&Object(i.createElement)("li",{className:"simpay-setup-wizard-toggle-list__child"},Object(i.createElement)(c.TextControl,{label:Object(o.__)("Send to:","simple-pay"),value:h,onChange:function(e){return m({"email_payment-notification_to":e})}})),_&&Object(i.createElement)("li",null,Object(i.createElement)("label",{htmlFor:"email_invoice-confirmation"},Object(i.createElement)("h3",null,Object(o.__)("Invoice Receipt","simple-pay")),Object(i.createElement)("p",null,Object(o.__)("Send a payment receipt email to the customer upon successful invoice.","simple-pay"))),Object(i.createElement)(c.FormToggle,{id:"email_payment-confirmation",checked:"no"!==v,onChange:function(e){var t=e.target;return m({"email_invoice-confirmation":t.checked?"yes":"no"})}})),j&&Object(i.createElement)("li",null,Object(i.createElement)("label",{htmlFor:"email_upcoming-invoice"},Object(i.createElement)("h3",null,Object(o.__)("Upcoming Invoice","simple-pay")),Object(i.createElement)("p",null,Object(o.__)("Remind customers of upcoming invoices and allow payment method changes.","simple-pay"))),Object(i.createElement)(c.FormToggle,{id:"email_upcoming-invoice",checked:"no"!==g,onChange:function(e){var t=e.target;return m({"email_upcoming-invoice":t.checked?"yes":"no"})}})))),Object(i.createElement)(ft,{justify:"space-between",align:"center"},Object(i.createElement)("div",null,Object(i.createElement)(c.Button,{isLink:!0,variant:"link",onClick:t,className:"simpay-setup-wizard-subtle-link"},Object(o.__)("← Previous Step","simple-pay"))),Object(i.createElement)("div",{style:{display:"flex",justifyContent:"center"}},Object(i.createElement)(c.Button,{isLink:!0,variant:"link",onClick:function(){p(),n()},style:{marginRight:"16px"},className:"simpay-setup-wizard-subtle-link"},Object(o.__)("Skip Step","simple-pay")),Object(i.createElement)(vt,{onClick:function(){f(),n()},ref:d},Object(o.__)("Save and Continue →","simple-pay")))))}},{id:"next-steps",title:Object(o.__)("🎉 Setup Complete","simple-pay"),content:function(){return Object(i.createElement)(i.Fragment,null,Object(i.createElement)(dt,null,Object(i.createElement)("div",{className:"simpay-setup-wizard-content-list"},Object(i.createElement)("div",{className:"simpay-setup-wizard-content-list__content"},Object(i.createElement)("p",null,Object(o.__)("Congratulations, you’re ready to start accepting payments!","simple-pay")),Object(i.createElement)("p",null,Object(o.__)("WP Simple Pay is just that: simple. Create your first payment form below to start collecting payments, or fine-tune your setup through some of these suggestions:","simple-pay"))),Object(i.createElement)("div",{className:"simpay-setup-wizard-content-list__list"},Object(i.createElement)("ul",{className:"simpay-setup-wizard-bullet-list"},Object(i.createElement)("li",null,Object(i.createElement)("a",{href:vn,target:"_blank",rel:"noopener noreferrer"},Object(o.__)("Collect tax or GST","simple-pay"))),Object(i.createElement)("li",null,Object(i.createElement)("a",{href:On,target:"_blank",rel:"noopener noreferrer"},Object(o.__)("Add anti-spam protection","simple-pay"))),Object(i.createElement)("li",null,Object(i.createElement)("a",{href:jn,target:"_blank",rel:"noopener noreferrer"},Object(o.__)("Change the default currency","simple-pay"))),Object(i.createElement)("li",null,Object(i.createElement)("a",{href:wn,target:"_blank",rel:"noopener noreferrer"},Object(o.__)("Customize receipts","simple-pay")))))),Object(i.createElement)("hr",null),Object(i.createElement)("div",{className:"simpay-setup-wizard-doc-suggestions"},Object(i.createElement)("div",null,Object(i.createElement)("h3",null,Object(o.__)("Accept Donations","simple-pay")),Object(i.createElement)("p",null,Object(o.__)("Easily fundraise or accept donations online via 135+ supported currencies. Offer one-time or recurring donations of fixed or user-defined amounts.","simple-pay")),Object(i.createElement)(c.Button,{href:xn,variant:"secondary",isSecondary:!0,target:"_blank",rel:"noopener noreferrer"},Object(o.__)("View Walkthrough","simple-pay"))),Object(i.createElement)("div",null,Object(i.createElement)("h3",null,Object(o.__)("Reconcile Invoices","simple-pay")),Object(i.createElement)("p",null,Object(o.__)("Collect additional custom data on your payment forms such as an Invoice ID to reconcile invoices against your own invoicing system.","simple-pay")),Object(i.createElement)(c.Button,{href:En,variant:"secondary",isSecondary:!0,target:"_blank",rel:"noopener noreferrer"},Object(o.__)("View Walkthrough","simple-pay"))))),Object(i.createElement)(ft,{justify:"space-between",align:"center"},Object(i.createElement)("div",{style:{flexBasis:"100%"}},Object(i.createElement)(c.Button,{isLink:!0,variant:"link",href:hn,className:"simpay-setup-wizard-subtle-link",icon:Object(i.createElement)(f.a,{icon:sn})},Object(o.__)("Return to Dashboard","simple-pay"))),Object(i.createElement)(c.Flex,{justify:"flex-end",gap:4},Object(i.createElement)(vt,{href:gn},Object(o.__)("Create a Payment Form →","simple-pay")))))}}],lite:[{id:"stripe",title:Object(o.__)("Connect to Stripe","simple-pay"),content:Cn},{id:"analytics",title:Object(o.__)("Help Improve WP Simple Pay + Smart Recommendations","simple-pay"),content:function(e){var t=e.goPrev,n=e.goNext,r=Ht(),s=r.settings,l=r.rawSettings,p=r.discardChanges,b=r.editSettings,y=r.saveSettings,h=Object(i.useState)(!0),g=a()(h,2),v=g[0],O=g[1],j=Object(i.useState)(Xt),_=a()(j,2),w=_[0],x=_[1],E=Object(i.useState)(!1),S=a()(E,2),k=S[0],C=S[1],P=Object(i.useState)(!1),z=a()(P,2),A=z[0],$=z[1],N=Object(i.useRef)();return Object(i.useLayoutEffect)((function(){N.current&&N.current.focus()}),[l]),Object(u.isEmpty)(s)?Object(i.createElement)(dt,null,Object(i.createElement)(c.Spinner,null)):Object(i.createElement)(i.Fragment,null,Object(i.createElement)(dt,null,Object(i.createElement)("p",null,Object(o.__)("Get helpful suggestions from WP Simple Pay on how to optimize your payment forms and grow your business or increase donations.","simple-pay")),Object(i.createElement)(c.TextControl,{label:Object(o.__)("Your Email Address:","simple-pay"),value:w,className:"simpay-setup-wizard-large-input",onChange:function(e){return x(e)},help:Object(o.__)("Your email is needed so you receive recommendations.","simple-pay"),ref:N,disabled:k}),Object(i.createElement)("hr",null),Object(i.createElement)(et,null,Object(i.createElement)(tt,null,Object(o.__)("Help make WP Simple Pay better for everyone","simple-pay"),Object(i.createElement)("div",null,A&&Object(i.createElement)(nt,{position:"top center"},Object(o.__)("By allowing us to track usage data we can better help you because we know which WordPress configurations, themes, and plugins we should test.","simple-pay")),Object(i.createElement)(f.a,{size:20,icon:d.a,onMouseEnter:function(){return $(!0)},onMouseLeave:function(){return $(!1)}}))),Object(i.createElement)(rt,{label:Object(o.__)("Yes, count me in","simple-pay"),id:"email_payment-confirmation",checked:v,disabled:k,onChange:function(e){O(e)}}))),Object(i.createElement)(ft,{justify:"space-between",align:"center"},Object(i.createElement)("div",null,Object(i.createElement)(c.Button,{isLink:!0,variant:"link",onClick:t,className:"simpay-setup-wizard-subtle-link",disabled:k},Object(o.__)("← Previous Step","simple-pay"))),Object(i.createElement)("div",{style:{display:"flex",justifyContent:"center"}},Object(i.createElement)(c.Button,{isLink:!0,variant:"link",onClick:function(){p(),n()},style:{marginRight:"16px"},className:"simpay-setup-wizard-subtle-link",disabled:k},Object(o.__)("Skip Step","simple-pay")),Object(i.createElement)(vt,{onClick:function(){C(!0),b({usage_tracking_opt_in:v?"yes":"no"}),y();var e=new FormData;e.append("action","simpay_setup_wizard_subscribe_email"),e.append("nonce",Qt),e.append("email",w),m()({url:Kt,method:"POST",body:e}).finally((function(){C(!1),n()}))},isBusy:k,disabled:k},Object(o.__)("Save and Continue →","simple-pay")))))}},{id:"next-steps",title:Object(o.__)("🎉 Setup Complete","simple-pay"),content:function(){return Object(i.createElement)(i.Fragment,null,Object(i.createElement)(dt,null,Object(i.createElement)(c.Flex,{justify:"space-between",align:"center",className:"simpay-setup-wizard-content-list"},Object(i.createElement)("div",{className:"simpay-setup-wizard-content-list__content"},Object(i.createElement)("p",null,Object(o.__)("Congratulations, you’re ready to start easily and securely accepting payments with WP Simple Pay!","simple-pay"))),Object(i.createElement)("div",null,Object(i.createElement)(vt,{href:fn},Object(o.__)("Create a Payment Form →","simple-pay")))),Object(i.createElement)("hr",null),Object(i.createElement)(ln,null,Object(i.createElement)("h4",null,Object(o.__)("Special Upgrade Offer - Save 50%","simple-pay")),Object(i.createElement)("h3",null,Object(o.__)("Upgrade to WP Simple Pay Pro Today and Save","simple-pay")),Object(i.createElement)(un,{className:"simpay-setup-wizard-check-list"},bn.map((function(e){return Object(i.createElement)("li",{key:e},Object(i.createElement)(f.a,{icon:Ct.a}),e)}))),Object(i.createElement)(c.Button,{isLarge:!0,isSecondary:!0,variant:"secondary",href:dn,target:"_blank",rel:"noopener noreferrer"},Object(o.__)("Upgrade to WP Simple Pay Pro","simple-pay")))),Object(i.createElement)(ft,{justify:"center"},Object(i.createElement)(c.Button,{isLink:!0,variant:"link",href:mn,className:"simpay-setup-wizard-subtle-link",icon:Object(i.createElement)(f.a,{icon:sn})},Object(o.__)("Return to Dashboard","simple-pay"))))}}]},$n=simpaySetupWizard,Nn=$n.license,Mn=$n.adminUrl,Rn=Nn.is_lite;Object(i.render)(Object(i.createElement)((function(){var e=An[!0===Rn?"lite":"pro"],t=Object(s.getQueryArg)(window.location.href,"step"),n=Object(i.useState)(Nn),r=a()(n,2),u=r[0],p=r[1],m=function(e){var t=e.steps,n=e.currentStepId,r=t.findIndex((function(e){return e.id===n}))||0,c=Object(i.useState)(r),o=a()(c,2),l=o[0],u=o[1];function p(e){u(e),window.history.pushState({},"",Object(s.addQueryArgs)(window.location.href,{step:t[e].id}))}return Object(i.useEffect)((function(){var e=function(){var e=Object(s.getQueryArg)(window.location.search,"step"),n=t.findIndex((function(t){return t.id===e}))||0;u(n)};return window.addEventListener("popstate",e),window.addEventListener("pushstate",e),function(){window.removeEventListener("popstate",e),window.removeEventListener("pushstate",e)}}),[]),{currentStep:l,setCurrentStep:u,hasNext:l0}}({steps:e,currentStepId:t}),f=m.currentStep,d=m.goNext,b=m.goPrev,y=m.hasNext,h=m.hasPrev;if(-1===f)return Object(i.createElement)(zn,{steps:e,goNext:d});var g=e[f],v=g.content;return Object(i.createElement)(c.SlotFillProvider,null,Object(i.createElement)(l.EntityProvider,{kind:"root",type:"site"},Object(i.createElement)(Ft,null,Object(i.createElement)("a",{href:Mn},Object(i.createElement)(Ot,{width:"250px"})),Object(i.createElement)(Mt,{current:f+1,total:e.length}),Object(i.createElement)(pt,{isRounded:!0},Object(i.createElement)(mt,{supTitle:Object(o.sprintf)( +!function(e){var t={};function n(r){if(t[r])return t[r].exports;var a=t[r]={i:r,l:!1,exports:{}};return e[r].call(a.exports,a,a.exports,n),a.l=!0,a.exports}n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var a in e)n.d(r,a,function(t){return e[t]}.bind(null,a));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=66)}([function(e,t){e.exports=window.wp.element},,function(e,t){e.exports=window.wp.i18n},function(e,t){e.exports=window.wp.components},function(e,t){e.exports=window.React},function(e,t,n){var r=n(20),a=n(21),i=n(16),c=n(22);e.exports=function(e,t){return r(e)||a(e,t)||i(e,t)||c()},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){e.exports=window.wp.primitives},function(e,t){e.exports=window.wp.url},function(e,t){e.exports=window.lodash},function(e,t){e.exports=function(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))},e.exports.__esModule=!0,e.exports.default=e.exports},,,function(e,t){e.exports=window.wp.data},function(e,t,n){var r;!function(){"use strict";var n={}.hasOwnProperty;function a(){for(var e=[],t=0;te.length)&&(t=e.length);for(var n=0,r=new Array(t);n=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i},e.exports.__esModule=!0,e.exports.default=e.exports},,,,,,,,function(e,t){e.exports=window.wp.notices},function(e,t,n){"use strict";e.exports=n(52)},function(e,t,n){"use strict";var r="function"==typeof Symbol&&Symbol.for,a=r?Symbol.for("react.element"):60103,i=r?Symbol.for("react.portal"):60106,c=r?Symbol.for("react.fragment"):60107,o=r?Symbol.for("react.strict_mode"):60108,s=r?Symbol.for("react.profiler"):60114,l=r?Symbol.for("react.provider"):60109,u=r?Symbol.for("react.context"):60110,p=r?Symbol.for("react.async_mode"):60111,m=r?Symbol.for("react.concurrent_mode"):60111,f=r?Symbol.for("react.forward_ref"):60112,d=r?Symbol.for("react.suspense"):60113,b=r?Symbol.for("react.suspense_list"):60120,y=r?Symbol.for("react.memo"):60115,h=r?Symbol.for("react.lazy"):60116,g=r?Symbol.for("react.block"):60121,v=r?Symbol.for("react.fundamental"):60117,O=r?Symbol.for("react.responder"):60118,j=r?Symbol.for("react.scope"):60119;function _(e){if("object"==typeof e&&null!==e){var t=e.$$typeof;switch(t){case a:switch(e=e.type){case p:case m:case c:case s:case o:case d:return e;default:switch(e=e&&e.$$typeof){case u:case f:case h:case y:case l:return e;default:return t}}case i:return t}}}function w(e){return _(e)===m}t.AsyncMode=p,t.ConcurrentMode=m,t.ContextConsumer=u,t.ContextProvider=l,t.Element=a,t.ForwardRef=f,t.Fragment=c,t.Lazy=h,t.Memo=y,t.Portal=i,t.Profiler=s,t.StrictMode=o,t.Suspense=d,t.isAsyncMode=function(e){return w(e)||_(e)===p},t.isConcurrentMode=w,t.isContextConsumer=function(e){return _(e)===u},t.isContextProvider=function(e){return _(e)===l},t.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===a},t.isForwardRef=function(e){return _(e)===f},t.isFragment=function(e){return _(e)===c},t.isLazy=function(e){return _(e)===h},t.isMemo=function(e){return _(e)===y},t.isPortal=function(e){return _(e)===i},t.isProfiler=function(e){return _(e)===s},t.isStrictMode=function(e){return _(e)===o},t.isSuspense=function(e){return _(e)===d},t.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===c||e===m||e===s||e===o||e===d||e===b||"object"==typeof e&&null!==e&&(e.$$typeof===h||e.$$typeof===y||e.$$typeof===l||e.$$typeof===u||e.$$typeof===f||e.$$typeof===v||e.$$typeof===O||e.$$typeof===j||e.$$typeof===g)},t.typeOf=_},function(e,t){e.exports=function(e,t){if(null==e)return{};var n,r,a={},i=Object.keys(e);for(r=0;r=0||(a[n]=e[n]);return a},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t,n){"use strict";var r=n(0),a=n(6);const i=Object(r.createElement)(a.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(a.Path,{d:"M16.7 7.1l-6.3 8.5-3.3-2.5-.9 1.2 4.5 3.4L17.9 8z"}));t.a=i},function(e,t,n){"use strict";var r=n(0),a=n(6);const i=Object(r.createElement)(a.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(a.Path,{d:"M12 3.2c-4.8 0-8.8 3.9-8.8 8.8 0 4.8 3.9 8.8 8.8 8.8 4.8 0 8.8-3.9 8.8-8.8 0-4.8-4-8.8-8.8-8.8zm0 16c-4 0-7.2-3.3-7.2-7.2C4.8 8 8 4.8 12 4.8s7.2 3.3 7.2 7.2c0 4-3.2 7.2-7.2 7.2zM11 17h2v-6h-2v6zm0-8h2V7h-2v2z"}));t.a=i},,,,,,,,,,,function(e,t,n){"use strict";n.r(t);var r=n(5),a=n.n(r),i=n(0),c=(n(50),n(3)),o=n(2),s=n(7),l=n(33),u=n(8),p=n(23),m=n.n(p),f=n(35),d=n(55),b=n(9),y=n.n(b),h=n(17),g=n.n(h),v=n(4),O=function(e){var t=Object.create(null);return function(n){return void 0===t[n]&&(t[n]=e(n)),t[n]}},j=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|download|draggable|encType|enterKeyHint|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,_=O((function(e){return j.test(e)||111===e.charCodeAt(0)&&110===e.charCodeAt(1)&&e.charCodeAt(2)<91}));function w(){return(w=Object.assign||function(e){for(var t=1;t0?L(q,--H):0,Z--,10===G&&(Z=1,I--),G}function K(){return G=H2||ne(G)>3?"":" "}function oe(e,t){for(;--t&&K()&&!(G<48||G>102||G>57&&G<65||G>70&&G<97););return te(e,ee()+(t<6&&32==J()&&32==K()))}function se(e,t){for(;K()&&e+G!==57&&(e+G!==84||47!==J()););return"/*"+te(t,H-1)+"*"+N(47===e?e:K())}function le(e){for(;!ne(J());)K();return te(e,H)}function ue(e,t,n,r,a,i,c,o,s,l,u){for(var p=a-1,m=0===a?i:[""],f=U(m),d=0,b=0,y=0;d0?m[h]+" "+g:T(g,/&\f/g,m[h])))&&(s[y++]=v);return Y(e,t,n,0===a?P:o,s,l,u)}function pe(e,t,n){return Y(e,t,n,C,N(G),D(e,2,-2),0)}function me(e,t,n,r){return Y(e,t,n,z,D(e,0,r),D(e,r+1,-1),r)}function fe(e,t){for(var n="",r=U(e),a=0;a-1&&!e.return)switch(e.type){case z:e.return=function e(t,n){switch(function(e,t){return(((t<<2^L(e,0))<<2^L(e,1))<<2^L(e,2))<<2^L(e,3)}(t,n)){case 5103:return k+"print-"+t+t;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return k+t+t;case 5349:case 4246:case 4810:case 6968:case 2756:return k+t+S+t+E+t+t;case 6828:case 4268:return k+t+E+t+t;case 6165:return k+t+E+"flex-"+t+t;case 5187:return k+t+T(t,/(\w+).+(:[^]+)/,k+"box-$1$2"+E+"flex-$1$2")+t;case 5443:return k+t+E+"flex-item-"+T(t,/flex-|-self/,"")+t;case 4675:return k+t+E+"flex-line-pack"+T(t,/align-content|flex-|-self/,"")+t;case 5548:return k+t+E+T(t,"shrink","negative")+t;case 5292:return k+t+E+T(t,"basis","preferred-size")+t;case 6060:return k+"box-"+T(t,"-grow","")+k+t+E+T(t,"grow","positive")+t;case 4554:return k+T(t,/([^-])(transform)/g,"$1"+k+"$2")+t;case 6187:return T(T(T(t,/(zoom-|grab)/,k+"$1"),/(image-set)/,k+"$1"),t,"")+t;case 5495:case 3959:return T(t,/(image-set\([^]*)/,k+"$1$`$1");case 4968:return T(T(t,/(.+:)(flex-)?(.*)/,k+"box-pack:$3"+E+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+k+t+t;case 4095:case 3583:case 4068:case 2532:return T(t,/(.+)-inline(.+)/,k+"$1$2")+t;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(B(t)-1-n>6)switch(L(t,n+1)){case 109:if(45!==L(t,n+4))break;case 102:return T(t,/(.+:)(.+)-([^]+)/,"$1"+k+"$2-$3$1"+S+(108==L(t,n+3)?"$3":"$2-$3"))+t;case 115:return~F(t,"stretch")?e(T(t,"stretch","fill-available"),n)+t:t}break;case 4949:if(115!==L(t,n+1))break;case 6444:switch(L(t,B(t)-3-(~F(t,"!important")&&10))){case 107:return T(t,":",":"+k)+t;case 101:return T(t,/(.+:)([^;!]+)(;|!.+)?/,"$1"+k+(45===L(t,14)?"inline-":"")+"box$3$1"+k+"$2$3$1"+E+"$2box$3")+t}break;case 5936:switch(L(t,n+11)){case 114:return k+t+E+T(t,/[svh]\w+-[tblr]{2}/,"tb")+t;case 108:return k+t+E+T(t,/[svh]\w+-[tblr]{2}/,"tb-rl")+t;case 45:return k+t+E+T(t,/[svh]\w+-[tblr]{2}/,"lr")+t}return k+t+E+t+t}return t}(e.value,e.length);break;case A:return fe([X(e,{value:T(e.value,"@","@"+k)})],r);case P:if(e.length)return function(e,t){return e.map(t).join("")}(e.props,(function(t){switch(function(e,t){return(e=/(::plac\w+|:read-\w+)/.exec(e))?e[0]:e}(t)){case":read-only":case":read-write":return fe([X(e,{props:[T(t,/:(read-\w+)/,":-moz-$1")]})],r);case"::placeholder":return fe([X(e,{props:[T(t,/:(plac\w+)/,":"+k+"input-$1")]}),X(e,{props:[T(t,/:(plac\w+)/,":-moz-$1")]}),X(e,{props:[T(t,/:(plac\w+)/,E+"input-$1")]})],r)}return""}))}}],je=function(e){var t=e.key;if("css"===t){var n=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(n,(function(e){-1!==e.getAttribute("data-emotion").indexOf(" ")&&(document.head.appendChild(e),e.setAttribute("data-s",""))}))}var r,a,i=e.stylisPlugins||Oe,c={},o=[];r=e.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+t+' "]'),(function(e){for(var t=e.getAttribute("data-emotion").split(" "),n=1;n0&&B(x)-m&&W(d>32?me(x+";",a,r,m-1):me(T(x," ","")+";",a,r,m-2),l);break;case 59:x+=";";default:if(W(w=ue(x,n,r,u,p,i,s,O,j=[],_=[],m),c),123===v)if(0===p)e(x,n,w,w,j,c,m,s,_);else switch(f){case 100:case 109:case 115:e(t,w,w,a&&W(ue(t,w,w,0,0,i,s,O,i,j=[],m),_),i,_,m,s,a?j:_);break;default:e(x,w,w,w,[""],_,0,s,_)}}u=p=d=0,y=g=1,O=x="",m=o;break;case 58:m=1+B(x),d=b;default:if(y<1)if(123==v)--y;else if(125==v&&0==y++&&125==Q())continue;switch(x+=N(v),v*y){case 38:g=p>0?1:(x+="\f",-1);break;case 44:s[u++]=(B(x)-1)*g,g=1;break;case 64:45===J()&&(x+=ie(K())),f=J(),p=m=B(O=x+=le(ee())),v++;break;case 45:45===b&&2==B(x)&&(y=0)}}return c}("",null,null,null,[""],e=re(e),0,[0],e))}(e?e+"{"+t.styles+"}":t.styles),p),r&&(m.inserted[t.name]=!0)};var m={key:t,sheet:new x({key:t,container:r,nonce:e.nonce,speedy:e.speedy,prepend:e.prepend,insertionPoint:e.insertionPoint}),nonce:e.nonce,inserted:c,registered:{},insert:a};return m.sheet.hydrate(o),m};function _e(e,t,n){var r="";return n.split(" ").forEach((function(n){void 0!==e[n]?t.push(e[n]+";"):r+=n+" "})),r}n(41);var we=function(e,t,n){var r=e.key+"-"+t.name;if(!1===n&&void 0===e.registered[r]&&(e.registered[r]=t.styles),void 0===e.inserted[t.name]){var a=t;do{e.insert(t===a?"."+r:"",a,e.sheet,!0),a=a.next}while(void 0!==a)}},xe=function(e){for(var t,n=0,r=0,a=e.length;a>=4;++r,a-=4)t=1540483477*(65535&(t=255&e.charCodeAt(r)|(255&e.charCodeAt(++r))<<8|(255&e.charCodeAt(++r))<<16|(255&e.charCodeAt(++r))<<24))+(59797*(t>>>16)<<16),n=1540483477*(65535&(t^=t>>>24))+(59797*(t>>>16)<<16)^1540483477*(65535&n)+(59797*(n>>>16)<<16);switch(a){case 3:n^=(255&e.charCodeAt(r+2))<<16;case 2:n^=(255&e.charCodeAt(r+1))<<8;case 1:n=1540483477*(65535&(n^=255&e.charCodeAt(r)))+(59797*(n>>>16)<<16)}return(((n=1540483477*(65535&(n^=n>>>13))+(59797*(n>>>16)<<16))^n>>>15)>>>0).toString(36)},Ee={animationIterationCount:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},Se=/[A-Z]|^ms/g,ke=/_EMO_([^_]+?)_([^]*?)_EMO_/g,Ce=function(e){return 45===e.charCodeAt(1)},Pe=function(e){return null!=e&&"boolean"!=typeof e},ze=O((function(e){return Ce(e)?e:e.replace(Se,"-$&").toLowerCase()})),Ae=function(e,t){switch(e){case"animation":case"animationName":if("string"==typeof t)return t.replace(ke,(function(e,t,n){return Ne={name:t,styles:n,next:Ne},t}))}return 1===Ee[e]||Ce(e)||"number"!=typeof t||0===t?t:t+"px"};function $e(e,t,n){if(null==n)return"";if(void 0!==n.__emotion_styles)return n;switch(typeof n){case"boolean":return"";case"object":if(1===n.anim)return Ne={name:n.name,styles:n.styles,next:Ne},n.name;if(void 0!==n.styles){var r=n.next;if(void 0!==r)for(;void 0!==r;)Ne={name:r.name,styles:r.styles,next:Ne},r=r.next;return n.styles+";"}return function(e,t,n){var r="";if(Array.isArray(n))for(var a=0;a96?De:Be},We=function(e,t,n){var r;if(t){var a=t.shouldForwardProp;r=e.__emotion_forwardProp&&a?function(t){return e.__emotion_forwardProp(t)&&a(t)}:a}return"function"!=typeof r&&n&&(r=e.__emotion_forwardProp),r},Ie=function(){return null},Ze=function e(t,n){var r,a,i=t.__emotion_real===t,c=i&&t.__emotion_base||t;void 0!==n&&(r=n.label,a=n.target);var o=We(t,n,i),s=o||Ue(c),l=!s("as");return function(){var u=arguments,p=i&&void 0!==t.__emotion_styles?t.__emotion_styles.slice(0):[];if(void 0!==r&&p.push("label:"+r+";"),null==u[0]||void 0===u[0].raw)p.push.apply(p,u);else{p.push(u[0][0]);for(var m=u.length,f=1;f div {\n\t\tmargin-left: 8px;\n\t}\n\n\tsvg {\n\t\tdisplay: block;\n\n\t\t&:hover {\n\t\t\tcursor: pointer;\n\t\t}\n\t}\n"]))),nt=Je(c.Popover)(Ge||(Ge=y()(["\n\t.components-popover__content {\n\t\tpadding: 20px;\n\t\twidth: 200px;\n\t}\n"]))),rt=Je(c.ToggleControl)(qe||(qe=y()(["\n\t&& {\n\t\t.components-base-control__field {\n\t\t\tmargin-bottom: 0;\n\t\t}\n\t}\n"]))),at=n(42),it=n.n(at),ct=Je(c.Card)(Ye||(Ye=y()(["\n\tpadding: 30px;\n\n\t&& {\n\t\tbox-shadow: 0 2px 6px 0 rgba( 0, 0, 0, 0.05 );\n\t\tborder: 1px solid #ccc;\n\t\twidth: 100%;\n\t}\n"]))),ot=Je(c.CardHeader)(Xe||(Xe=y()(["\n\t&&& {\n\t\tpadding: 0 0 30px;\n\t}\n\n\th1 {\n\t\tfont-size: 26px;\n\t\tline-height: 1;\n\t\tmargin: 0;\n\t\tpadding: 0;\n\t}\n\n\tsmall {\n\t\tcolor: #c0c0c0;\n\t\tfont-size: 13px;\n\t\tfont-weight: normal;\n\t\tdisplay: block;\n\t\tmargin: 0 0 3px;\n\t}\n"]))),st=Je(c.CardFooter)(Qe||(Qe=y()(["\n\t&&& {\n\t\tpadding: 30px 0 0;\n\t}\n"]))),lt=Je(c.CardBody)(Ke||(Ke=y()(["\n\t&&& {\n\t\tpadding: 30px 0;\n\t}\n\n\t> * {\n\t\tmargin: 0 0 2rem;\n\n\t\t&:last-child {\n\t\t\tmargin-bottom: 0;\n\t\t}\n\t}\n\n\t> p {\n\t\tcolor: #555555;\n\t\tfont-size: 15px;\n\t}\n"]))),ut=["title","supTitle","children"];function pt(e){return Object(i.createElement)(ct,e)}function mt(e){var t=e.title,n=e.supTitle,r=e.children,a=it()(e,ut);return Object(i.createElement)(ot,a,Object(i.createElement)("div",null,n&&Object(i.createElement)("small",null,n),t&&Object(i.createElement)("h1",null,t)),r)}function ft(e){return Object(i.createElement)(st,e)}function dt(e){return Object(i.createElement)(lt,e)}var bt,yt=simpaySetupWizard.adminUrl;function ht(e){var t=e.isFirst,n=Object(i.useState)(!1),r=a()(n,2),s=r[0],l=r[1];return Object(i.createElement)(c.Flex,{justify:"center"},s&&Object(i.createElement)(c.Modal,{title:Object(o.__)("Are you sure you want to exit the wizard?","simple-pay"),onRequestClose:function(){return l(!1)}},Object(i.createElement)("p",{style:{marginBottom:"2rem"}},Object(o.__)("Manual setup is only recommended for experienced users.","simple-pay")),Object(i.createElement)(c.Flex,null,Object(i.createElement)(c.Button,{href:yt,isDestructive:!0,variant:"destructive"},Object(o.__)("Exit Setup Wizard","simple-pay")),Object(i.createElement)(c.Button,{variant:"primary",isPrimary:!0,onClick:function(){return l(!1)}},Object(o.__)("Continue Setup","simple-pay")))),Object(i.createElement)(c.Button,{isLink:!0,variant:"link",className:"simpay-setup-wizard-subtle-link",onClick:function(){return l(!0)}},t?Object(o.__)("Go back to the Dashboard","simple-pay"):Object(o.__)("Close and exit the Setup Wizard","simple-pay")))}var gt=Je(c.Button)(bt||(bt=y()(["\n\t&& {\n\t\tfont-size: 16px;\n\t\tfont-weight: bold;\n\t\tpadding: 15px 30px !important;\n\t\theight: auto;\n\t}\n"]))),vt=Object(i.forwardRef)((function(e,t){return Object(i.createElement)(gt,g()({isPrimary:!0,variant:"primary"},e,{ref:t}))}));function Ot(e){return e.width,Object(i.createElement)("svg",{width:"311",height:"41",fill:"none",xmlns:"http://www.w3.org/2000/svg"},Object(i.createElement)("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M2.352 0C1.052 0 0 1.02 0 2.277v30.746C0 34.281 1.053 35.3 2.352 35.3h28.806c.975 0 1.764-.764 1.764-1.708 0-.943-.79-1.708-1.763-1.708H5.29c-.974 0-1.764-.765-1.764-1.708v-17.08c0-.944.79-1.709 1.764-1.709h44.092c1.299 0 2.352-1.02 2.352-2.277V2.277C51.735 1.02 50.682 0 49.383 0H2.352Zm55.262 24.198h-1.47v-1.993c0-4.088-3.422-7.402-7.643-7.402-4.22 0-7.642 3.314-7.642 7.402v1.993H38.8c-1.299 0-2.352 1.02-2.352 2.277v11.387c0 1.258 1.053 2.278 2.352 2.278h18.813c1.299 0 2.351-1.02 2.351-2.278V26.475c0-1.258-1.053-2.277-2.351-2.277Zm-4.997-1.993v1.993h-8.23v-1.993c0-2.201 1.842-3.985 4.114-3.985 2.273 0 4.116 1.784 4.116 3.985ZM8.23 20.497c0-.629.526-1.139 1.175-1.139H28.22c.65 0 1.176.51 1.176 1.139s-.527 1.139-1.176 1.139H9.406c-.649 0-1.175-.51-1.175-1.139Zm0 5.124c0-.629.526-1.138 1.175-1.138h7.055c.65 0 1.176.51 1.176 1.138 0 .63-.527 1.139-1.176 1.139H9.406c-.649 0-1.175-.51-1.175-1.139Zm31.158 11.672V27.045h17.637v10.248H39.389Z",fill:"#428BCA"}),Object(i.createElement)("path",{d:"M81.08 30.745h5.288l5.41-17.186 5.596 17.187h5.289l7.84-24.29h-5.288l-5.289 17.956L94.7 6.457h-5.842L83.785 24.38 78.528 6.457h-5.289l7.84 24.288Zm31.511 0h4.796v-8.793h6.456c5.319 0 8.302-3.228 8.302-7.963 0-4.735-2.983-7.532-8.302-7.532h-11.252v24.288Zm4.796-13.405V11.1h5.288c2.952 0 4.52 1.168 4.52 3.104 0 1.968-1.507 3.136-4.366 3.136h-5.442Zm35.473 13.897c6.303 0 10.023-3.197 10.023-7.747 0-10.3-14.789-4.581-14.789-10.085 0-1.906 1.599-3.013 4.52-3.013 2.859 0 4.519 1.322 4.704 3.567h5.288c0-4.92-4.089-7.994-9.9-7.994-5.872 0-9.562 2.89-9.562 7.502 0 10.268 14.758 4.642 14.758 10.084 0 1.998-1.752 3.26-4.919 3.26-3.228 0-5.073-1.6-5.165-4.305h-5.381c0 5.503 4.274 8.731 10.423 8.731Zm15.137-18.447c1.66 0 2.89-1.23 2.89-2.89 0-1.66-1.23-2.829-2.89-2.829-1.691 0-2.921 1.169-2.921 2.83 0 1.66 1.23 2.89 2.921 2.89Zm-2.306 17.956h4.581V14.758h-4.581v15.988Zm7.696-.001h4.55v-8.178c0-2.644 1.384-4.366 3.597-4.366 1.968 0 3.136 1.415 3.136 3.751v8.793h4.612v-8.178c0-2.644 1.384-4.366 3.597-4.366 1.968 0 3.136 1.415 3.136 3.751v8.793h4.643v-9.039c0-4.888-1.968-7.44-5.965-7.44-2.459 0-4.642.86-6.21 3.044-.892-2.03-2.583-3.044-5.135-3.044-2.552 0-4.335 1.076-5.411 2.798v-2.306h-4.55v15.988Zm30.183 6.15h4.551v-8.24c1.106 1.63 2.859 2.582 5.38 2.582 4.028 0 6.887-3.504 6.887-8.424 0-5.011-2.859-8.547-6.887-8.547-2.521 0-4.274.953-5.38 2.583v-2.091h-4.551v22.137Zm8.363-9.593c-2.244 0-3.843-1.875-3.843-4.52 0-2.674 1.599-4.58 3.843-4.58 2.275 0 3.874 1.906 3.874 4.58 0 2.645-1.599 4.52-3.874 4.52Zm10.651 3.443h4.551V6.457h-4.551v24.288Zm15.443.492c3.905 0 6.918-2.213 7.41-5.688h-4.551c-.184 1.107-1.229 1.968-2.828 1.968-2.368 0-3.536-1.353-3.751-3.412h11.222v-1.476c0-5.104-3.259-8.363-7.502-8.363-4.919 0-8.363 3.505-8.363 8.455 0 4.98 3.444 8.516 8.363 8.516Zm-3.689-9.93c.276-1.845 1.352-3.106 3.505-3.106 1.937 0 3.013 1.322 3.105 3.106h-6.61Zm22.358 9.438h4.796v-8.793h6.457c5.319 0 8.301-3.228 8.301-7.963 0-4.735-2.982-7.532-8.301-7.532h-11.253v24.288Zm4.796-13.405V11.1h5.288c2.952 0 4.52 1.168 4.52 3.104 0 1.968-1.507 3.136-4.366 3.136h-5.442Zm20.704 13.897c2.736 0 4.458-1.23 5.257-3.228.4 2.183 2.152 3.413 5.688 2.613v-3.259c-1.261.123-1.507-.338-1.507-1.66v-5.411c0-3.782-2.644-6.026-7.317-6.026-4.612 0-7.317 2.275-7.317 6.118h4.488c0-1.383 1.015-2.183 2.768-2.183 1.906 0 2.859.769 2.828 2.091v.492l-3.659.43c-4.519.523-7.071 2.368-7.071 5.258 0 2.429 1.722 4.765 5.842 4.765Zm.922-3.382c-1.414 0-2.183-.645-2.183-1.63 0-1.167 1.507-1.629 4.397-1.998l1.568-.153c-.277 2.152-1.599 3.781-3.782 3.781Zm11.126 9.04h1.967c3.936 0 6.641-1.077 8.271-4.981L311 14.758h-4.766l-3.996 10.669-4.797-10.67h-4.796l7.225 16.234c-1.014 1.446-2.06 1.907-4.058 1.876h-1.568v4.028Z",fill:"#428BCA"}))}var jt=n(12);function _t(e){var t=Object(jt.useSelect)((function(e){return Object(u.filter)(e("core/notices").getNotices(),{type:"snackbar"})}),[]),n=Object(jt.useDispatch)("core/notices").removeNotice;return 0===t.length?null:Object(i.createElement)(c.SnackbarList,g()({onRemove:n,notices:t},e))}var wt,xt,Et,St,kt,Ct=n(54),Pt=Je.div(wt||(wt=y()(["\n\tmax-width: 80%;\n\tdisplay: flex;\n\talign-items: center;\n\n\t> * {\n\t\tmargin-right: 8px;\n\n\t\t&:last-child {\n\t\t\tmargin-right: 0;\n\t\t}\n\t}\n"]))),zt={current:"var(--wp-admin-theme-color)",complete:"var(--wp-admin-theme-color)",incomplete:"#c0c0c0"},At=Je.div(xt||(xt=y()(["\n\twidth: 16px;\n\theight: 16px;\n\tborder-radius: 50%;\n\tbackground-color: ",";\n\tflex-shrink: 0;\n\tposition: relative;\n\ttransition: backgroundColor 0.2s ease-in-out;\n\n\tsvg {\n\t\tfill: #fff;\n\t\tposition: absolute;\n\t\tleft: -1px;\n\t\ttop: -1px;\n\t\ttransition: opacity 0.2s ease-in-out;\n\t\topacity: ",";\n\t}\n\n\tdiv {\n\t\topacity: ",";\n\t}\n\n\tpath {\n\t\tstroke: #fff;\n\t}\n"])),(function(e){return zt[e.status]}),(function(e){return e.isComplete?"1":"0"}),(function(e){var t=e.isCurrent,n=e.isComplete;return t&&!n?"1":"0"})),$t=Je.div(Et||(Et=y()(["\n\twidth: 6px;\n\theight: 6px;\n\tbackground-color: #f0f0f1;\n\tborder-radius: 50%;\n\tposition: absolute;\n\ttop: 5px;\n\tleft: 5px;\n\ttransition: opacity 0.2s ease-in-out;\n"]))),Nt=Je.div(St||(St=y()(["\n\twidth: 100%;\n\theight: 2px;\n\tbackground-color: rgba( 192, 192, 192, 0.5 );\n\twidth: 100px;\n"])));function Mt(e){for(var t=e.current,n=e.total,r=[],a=1;a<=n;a++){var c="incomplete";a * {\n\t\tmargin: 25px 0;\n\t}\n"])));function Ft(e){return Object(i.createElement)(Tt,e)}var Lt=Je(c.Button)(Rt||(Rt=y()(["\n\t&&&& {\n\t\tfont-size: 16px;\n\t\tfont-weight: bold;\n\t\tpadding: 13px 30px 12px !important;\n\t\theight: auto;\n\t\tbackground-color: #635bff;\n\n\t\t&:focus {\n\t\t\tbackground-color: #635bff;\n\t\t\tbox-shadow: inset 0 0 0 1px #fff,\n\t\t\t\t0 0 0 var( --wp-admin-border-width-focus ) #635bff;\n\t\t}\n\n\t\t&:hover {\n\t\t\tbackground-color: #0a2540 !important;\n\t\t}\n\n\t\t&:focus:hover {\n\t\t\tbox-shadow: inset 0 0 0 1px #fff,\n\t\t\t\t0 0 0 var( --wp-admin-border-width-focus ) #0a2540;\n\t\t}\n\n\t\tsvg {\n\t\t\tmargin-left: 5px;\n\t\t}\n\t}\n"]))),Dt=Object(i.forwardRef)((function(e,t){return Object(i.createElement)(Lt,g()({isPrimary:!0,variant:"primary"},e,{ref:t}))}));function Bt(){return Object(i.createElement)("svg",{width:56,height:23,fill:"none",xmlns:"http://www.w3.org/2000/svg"},Object(i.createElement)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M55.742 11.884c0-3.93-1.92-7.032-5.59-7.032-3.684 0-5.914 3.101-5.914 7.001 0 4.622 2.632 6.955 6.41 6.955 1.843 0 3.236-.414 4.29-.998v-3.07c-1.053.522-2.261.844-3.794.844-1.502 0-2.834-.522-3.004-2.334h7.572c0-.2.03-.998.03-1.366Zm-7.649-1.459c0-1.735 1.069-2.456 2.044-2.456.945 0 1.951.721 1.951 2.456h-3.995Zm-9.832-5.573c-1.517 0-2.493.706-3.035 1.197l-.201-.952h-3.407V23l3.871-.814.016-4.345c.557.4 1.378.967 2.74.967 2.772 0 5.296-2.21 5.296-7.078-.015-4.452-2.57-6.878-5.28-6.878Zm-.929 10.579c-.913 0-1.456-.323-1.827-.722l-.016-5.696c.403-.446.96-.753 1.843-.753 1.41 0 2.385 1.566 2.385 3.578 0 2.057-.96 3.593-2.385 3.593ZM26.292 3.946l3.886-.83V0l-3.886.814v3.132Zm0 1.167h3.886v13.434h-3.886V5.113Zm-4.165 1.136-.248-1.136h-3.345v13.434h3.871V9.443c.914-1.183 2.462-.968 2.942-.799V5.113c-.495-.184-2.307-.522-3.22 1.136Zm-7.742-4.468-3.778.798-.016 12.299c0 2.272 1.719 3.946 4.01 3.946 1.27 0 2.2-.23 2.71-.507V15.2c-.495.2-2.942.906-2.942-1.366v-5.45h2.942V5.112H14.37l.016-3.332ZM3.917 9.013c0-.6.496-.83 1.317-.83 1.176 0 2.663.354 3.84.983V5.558c-1.286-.507-2.555-.706-3.84-.706C2.09 4.852 0 6.479 0 9.197c0 4.238 5.884 3.562 5.884 5.39 0 .705-.62.936-1.487.936-1.285 0-2.926-.522-4.227-1.229v3.655c1.44.614 2.896.875 4.227.875 3.221 0 5.435-1.582 5.435-4.33-.015-4.575-5.915-3.762-5.915-5.481Z",fill:"#fff"}))}var Ut=n(15),Wt=n.n(Ut);function It(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Zt(e){for(var t=1;tWP Simple Pay account or purchase receipt email.","simple-pay"),{strong:Object(i.createElement)("strong",null),a:Object(i.createElement)("a",{href:rn,target:"_blank",rel:"noopener noreferrer"})})),Object(i.createElement)(c.TextControl,{label:Object(o.__)("License Key","simple-pay"),value:l,className:_,onChange:function(e){return u(e)},disabled:d,help:g||Object(o.__)("An active license ensures automatic updates and the latest features.","simple-pay"),ref:j})),Object(i.createElement)(ft,{justify:"flex-end",align:"center"},Object(i.createElement)(vt,{onClick:function(){b(!0);var e=new FormData;e.append("action","simpay_activate_license"),e.append("nonce",an),e.append("license",l),m()({url:nn,method:"POST",body:e}).then((function(e){var r=e.success,a=e.data,i=a.message,c=a.license;if(!r)throw{message:i};n(c),O(Object(o.__)("License activated","simple-pay"),{type:"snackbar"}),b(!1),t()})).catch((function(e){var t=e.message;v(t),b(!1)}))},disabled:""===l||d,isBusy:d},Object(o.__)("Activate and Continue →","simple-pay"))))}},{id:"stripe",title:Object(o.__)("Connect to Stripe","simple-pay"),content:Cn},{id:"emails",title:Object(o.__)("Configure Emails","simple-pay"),content:function(e){var t=e.goPrev,n=e.goNext,r=e.licenseData,a=Ht(),s=a.settings,l=a.rawSettings,p=a.discardChanges,m=a.editSettings,f=a.saveSettings,d=Object(i.useRef)();if(Object(i.useLayoutEffect)((function(){d.current&&d.current.focus()}),[l]),Object(u.isEmpty)(s))return Object(i.createElement)(dt,null,Object(i.createElement)(c.Spinner,null));var b=s["email_payment-confirmation"],y=s["email_payment-notification"],h=s["email_payment-notification_to"],g=s["email_upcoming-invoice"],v=s["email_invoice-confirmation"],O=r.features,j=O.subscriptions,_=O.enhanced_subscriptions;return Object(i.createElement)(i.Fragment,null,Object(i.createElement)(dt,null,Object(i.createElement)("ul",{className:"simpay-setup-wizard-toggle-list"},Object(i.createElement)("li",null,Object(i.createElement)("label",{htmlFor:"email_payment-confirmation"},Object(i.createElement)("h3",null,Object(o.__)("Payment Receipt","simple-pay")),Object(i.createElement)("p",null,Object(o.__)("Send a payment receipt email to the customer upon successful payment.","simple-pay"))),Object(i.createElement)(c.FormToggle,{id:"email_payment-confirmation",checked:"no"!==b,onChange:function(e){var t=e.target;return m({"email_payment-confirmation":t.checked?"yes":"no"})}})),Object(i.createElement)("li",null,Object(i.createElement)("label",{htmlFor:"email_payment-notification"},Object(i.createElement)("h3",null,Object(o.__)("Payment Notification","simple-pay")),Object(i.createElement)("p",null,Object(o.__)("Receive an email notification when a new payment is made.","simple-pay"))),Object(i.createElement)(c.FormToggle,{id:"email_payment-notification",checked:"no"!==y,onChange:function(e){var t=e.target;return m({"email_payment-notification":t.checked?"yes":"no"})}})),"no"!==y&&Object(i.createElement)("li",{className:"simpay-setup-wizard-toggle-list__child"},Object(i.createElement)(c.TextControl,{label:Object(o.__)("Send to:","simple-pay"),value:h,onChange:function(e){return m({"email_payment-notification_to":e})}})),_&&Object(i.createElement)("li",null,Object(i.createElement)("label",{htmlFor:"email_invoice-confirmation"},Object(i.createElement)("h3",null,Object(o.__)("Invoice Receipt","simple-pay")),Object(i.createElement)("p",null,Object(o.__)("Send a payment receipt email to the customer upon successful invoice.","simple-pay"))),Object(i.createElement)(c.FormToggle,{id:"email_payment-confirmation",checked:"no"!==v,onChange:function(e){var t=e.target;return m({"email_invoice-confirmation":t.checked?"yes":"no"})}})),j&&Object(i.createElement)("li",null,Object(i.createElement)("label",{htmlFor:"email_upcoming-invoice"},Object(i.createElement)("h3",null,Object(o.__)("Upcoming Invoice","simple-pay")),Object(i.createElement)("p",null,Object(o.__)("Remind customers of upcoming invoices and allow payment method changes.","simple-pay"))),Object(i.createElement)(c.FormToggle,{id:"email_upcoming-invoice",checked:"no"!==g,onChange:function(e){var t=e.target;return m({"email_upcoming-invoice":t.checked?"yes":"no"})}})))),Object(i.createElement)(ft,{justify:"space-between",align:"center"},Object(i.createElement)("div",null,Object(i.createElement)(c.Button,{isLink:!0,variant:"link",onClick:t,className:"simpay-setup-wizard-subtle-link"},Object(o.__)("← Previous Step","simple-pay"))),Object(i.createElement)("div",{style:{display:"flex",justifyContent:"center"}},Object(i.createElement)(c.Button,{isLink:!0,variant:"link",onClick:function(){p(),n()},style:{marginRight:"16px"},className:"simpay-setup-wizard-subtle-link"},Object(o.__)("Skip Step","simple-pay")),Object(i.createElement)(vt,{onClick:function(){f(),n()},ref:d},Object(o.__)("Save and Continue →","simple-pay")))))}},{id:"next-steps",title:Object(o.__)("🎉 Setup Complete","simple-pay"),content:function(){return Object(i.createElement)(i.Fragment,null,Object(i.createElement)(dt,null,Object(i.createElement)("div",{className:"simpay-setup-wizard-content-list"},Object(i.createElement)("div",{className:"simpay-setup-wizard-content-list__content"},Object(i.createElement)("p",null,Object(o.__)("Congratulations, you’re ready to start accepting payments!","simple-pay")),Object(i.createElement)("p",null,Object(o.__)("WP Simple Pay is just that: simple. Create your first payment form below to start collecting payments, or fine-tune your setup through some of these suggestions:","simple-pay"))),Object(i.createElement)("div",{className:"simpay-setup-wizard-content-list__list"},Object(i.createElement)("ul",{className:"simpay-setup-wizard-bullet-list"},Object(i.createElement)("li",null,Object(i.createElement)("a",{href:vn,target:"_blank",rel:"noopener noreferrer"},Object(o.__)("Collect tax or GST","simple-pay"))),Object(i.createElement)("li",null,Object(i.createElement)("a",{href:On,target:"_blank",rel:"noopener noreferrer"},Object(o.__)("Add anti-spam protection","simple-pay"))),Object(i.createElement)("li",null,Object(i.createElement)("a",{href:jn,target:"_blank",rel:"noopener noreferrer"},Object(o.__)("Change the default currency","simple-pay"))),Object(i.createElement)("li",null,Object(i.createElement)("a",{href:wn,target:"_blank",rel:"noopener noreferrer"},Object(o.__)("Customize receipts","simple-pay")))))),Object(i.createElement)("hr",null),Object(i.createElement)("div",{className:"simpay-setup-wizard-doc-suggestions"},Object(i.createElement)("div",null,Object(i.createElement)("h3",null,Object(o.__)("Accept Donations","simple-pay")),Object(i.createElement)("p",null,Object(o.__)("Easily fundraise or accept donations online via 135+ supported currencies. Offer one-time or recurring donations of fixed or user-defined amounts.","simple-pay")),Object(i.createElement)(c.Button,{href:xn,variant:"secondary",isSecondary:!0,target:"_blank",rel:"noopener noreferrer"},Object(o.__)("View Walkthrough","simple-pay"))),Object(i.createElement)("div",null,Object(i.createElement)("h3",null,Object(o.__)("Reconcile Invoices","simple-pay")),Object(i.createElement)("p",null,Object(o.__)("Collect additional custom data on your payment forms such as an Invoice ID to reconcile invoices against your own invoicing system.","simple-pay")),Object(i.createElement)(c.Button,{href:En,variant:"secondary",isSecondary:!0,target:"_blank",rel:"noopener noreferrer"},Object(o.__)("View Walkthrough","simple-pay"))))),Object(i.createElement)(ft,{justify:"space-between",align:"center"},Object(i.createElement)("div",{style:{flexBasis:"100%"}},Object(i.createElement)(c.Button,{isLink:!0,variant:"link",href:hn,className:"simpay-setup-wizard-subtle-link",icon:Object(i.createElement)(f.a,{icon:sn})},Object(o.__)("Return to Dashboard","simple-pay"))),Object(i.createElement)(c.Flex,{justify:"flex-end",gap:4},Object(i.createElement)(vt,{href:gn},Object(o.__)("Create a Payment Form →","simple-pay")))))}}],lite:[{id:"stripe",title:Object(o.__)("Connect to Stripe","simple-pay"),content:Cn},{id:"analytics",title:Object(o.__)("Help Improve WP Simple Pay + Smart Recommendations","simple-pay"),content:function(e){var t=e.goPrev,n=e.goNext,r=Ht(),s=r.settings,l=r.rawSettings,p=r.discardChanges,b=r.editSettings,y=r.saveSettings,h=Object(i.useState)(!0),g=a()(h,2),v=g[0],O=g[1],j=Object(i.useState)(Xt),_=a()(j,2),w=_[0],x=_[1],E=Object(i.useState)(!1),S=a()(E,2),k=S[0],C=S[1],P=Object(i.useState)(!1),z=a()(P,2),A=z[0],$=z[1],N=Object(i.useRef)();return Object(i.useLayoutEffect)((function(){N.current&&N.current.focus()}),[l]),Object(u.isEmpty)(s)?Object(i.createElement)(dt,null,Object(i.createElement)(c.Spinner,null)):Object(i.createElement)(i.Fragment,null,Object(i.createElement)(dt,null,Object(i.createElement)("p",null,Object(o.__)("Get helpful suggestions from WP Simple Pay on how to optimize your payment forms and grow your business or increase donations.","simple-pay")),Object(i.createElement)(c.TextControl,{label:Object(o.__)("Your Email Address:","simple-pay"),value:w,className:"simpay-setup-wizard-large-input",onChange:function(e){return x(e)},help:Object(o.__)("Your email is needed so you receive recommendations.","simple-pay"),ref:N,disabled:k}),Object(i.createElement)("hr",null),Object(i.createElement)(et,null,Object(i.createElement)(tt,null,Object(o.__)("Help make WP Simple Pay better for everyone","simple-pay"),Object(i.createElement)("div",null,A&&Object(i.createElement)(nt,{position:"top center"},Object(o.__)("By allowing us to track usage data we can better help you because we know which WordPress configurations, themes, and plugins we should test.","simple-pay")),Object(i.createElement)(f.a,{size:20,icon:d.a,onMouseEnter:function(){return $(!0)},onMouseLeave:function(){return $(!1)}}))),Object(i.createElement)(rt,{label:Object(o.__)("Yes, count me in","simple-pay"),id:"email_payment-confirmation",checked:v,disabled:k,onChange:function(e){O(e)}}))),Object(i.createElement)(ft,{justify:"space-between",align:"center"},Object(i.createElement)("div",null,Object(i.createElement)(c.Button,{isLink:!0,variant:"link",onClick:t,className:"simpay-setup-wizard-subtle-link",disabled:k},Object(o.__)("← Previous Step","simple-pay"))),Object(i.createElement)("div",{style:{display:"flex",justifyContent:"center"}},Object(i.createElement)(c.Button,{isLink:!0,variant:"link",onClick:function(){p(),n()},style:{marginRight:"16px"},className:"simpay-setup-wizard-subtle-link",disabled:k},Object(o.__)("Skip Step","simple-pay")),Object(i.createElement)(vt,{onClick:function(){C(!0),b({usage_tracking_opt_in:v?"yes":"no"}),y();var e=new FormData;e.append("action","simpay_setup_wizard_subscribe_email"),e.append("nonce",Qt),e.append("email",w),m()({url:Kt,method:"POST",body:e}).finally((function(){C(!1),n()}))},isBusy:k,disabled:k},Object(o.__)("Save and Continue →","simple-pay")))))}},{id:"next-steps",title:Object(o.__)("🎉 Setup Complete","simple-pay"),content:function(){return Object(i.createElement)(i.Fragment,null,Object(i.createElement)(dt,null,Object(i.createElement)(c.Flex,{justify:"space-between",align:"center",className:"simpay-setup-wizard-content-list"},Object(i.createElement)("div",{className:"simpay-setup-wizard-content-list__content"},Object(i.createElement)("p",null,Object(o.__)("Congratulations, you’re ready to start easily and securely accepting payments with WP Simple Pay!","simple-pay"))),Object(i.createElement)("div",null,Object(i.createElement)(vt,{href:fn},Object(o.__)("Create a Payment Form →","simple-pay")))),Object(i.createElement)("hr",null),Object(i.createElement)(ln,null,Object(i.createElement)("h4",null,Object(o.__)("Special Upgrade Offer - Save 50%","simple-pay")),Object(i.createElement)("h3",null,Object(o.__)("Upgrade to WP Simple Pay Pro Today and Save","simple-pay")),Object(i.createElement)(un,{className:"simpay-setup-wizard-check-list"},bn.map((function(e){return Object(i.createElement)("li",{key:e},Object(i.createElement)(f.a,{icon:Ct.a}),e)}))),Object(i.createElement)(c.Button,{isLarge:!0,isSecondary:!0,variant:"secondary",href:dn,target:"_blank",rel:"noopener noreferrer"},Object(o.__)("Upgrade to WP Simple Pay Pro","simple-pay")))),Object(i.createElement)(ft,{justify:"center"},Object(i.createElement)(c.Button,{isLink:!0,variant:"link",href:mn,className:"simpay-setup-wizard-subtle-link",icon:Object(i.createElement)(f.a,{icon:sn})},Object(o.__)("Return to Dashboard","simple-pay"))))}}]},$n=simpaySetupWizard,Nn=$n.license,Mn=$n.adminUrl,Rn=Nn.is_lite;Object(i.render)(Object(i.createElement)((function(){var e=An[!0===Rn?"lite":"pro"],t=Object(s.getQueryArg)(window.location.href,"step"),n=Object(i.useState)(Nn),r=a()(n,2),u=r[0],p=r[1],m=function(e){var t=e.steps,n=e.currentStepId,r=t.findIndex((function(e){return e.id===n}))||0,c=Object(i.useState)(r),o=a()(c,2),l=o[0],u=o[1];function p(e){u(e),window.history.pushState({},"",Object(s.addQueryArgs)(window.location.href,{step:t[e].id}))}return Object(i.useEffect)((function(){var e=function(){var e=Object(s.getQueryArg)(window.location.search,"step"),n=t.findIndex((function(t){return t.id===e}))||0;u(n)};return window.addEventListener("popstate",e),window.addEventListener("pushstate",e),function(){window.removeEventListener("popstate",e),window.removeEventListener("pushstate",e)}}),[]),{currentStep:l,setCurrentStep:u,hasNext:l0}}({steps:e,currentStepId:t}),f=m.currentStep,d=m.goNext,b=m.goPrev,y=m.hasNext,h=m.hasPrev;if(-1===f)return Object(i.createElement)(zn,{steps:e,goNext:d});var g=e[f],v=g.content;return Object(i.createElement)(c.SlotFillProvider,null,Object(i.createElement)(l.EntityProvider,{kind:"root",type:"site"},Object(i.createElement)(Ft,null,Object(i.createElement)("a",{href:Mn},Object(i.createElement)(Ot,{width:"250px"})),Object(i.createElement)(Mt,{current:f+1,total:e.length}),Object(i.createElement)(pt,{isRounded:!0},Object(i.createElement)(mt,{supTitle:Object(o.sprintf)( /* translators: %1$d current step count. %2$d total step count*/ Object(o.__)("Step %1$d of %2$d","simple-pay"),f+1,e.length),title:g.title}),Object(i.createElement)(v,{steps:e,currentStep:f,goPrev:b,goNext:d,hasNext:y,hasPrev:h,licenseData:u,setLicenseData:p})),y&&Object(i.createElement)(ht,null)),Object(i.createElement)(_t,{className:"simpay-setup-wizard-toasts"}),Object(i.createElement)(c.Popover.Slot,null)))}),null),document.getElementById("simpay-setup-wizard"))}]); \ No newline at end of file diff --git a/includes/core/assets/js/simpay-admin.min.js b/includes/core/assets/js/simpay-admin.min.js index 6c6579a1..91aef4ef 100644 --- a/includes/core/assets/js/simpay-admin.min.js +++ b/includes/core/assets/js/simpay-admin.min.js @@ -1 +1 @@ -!function(e){var t={};function n(r){if(t[r])return t[r].exports;var a=t[r]={i:r,l:!1,exports:{}};return e[r].call(a.exports,a,a.exports,n),a.l=!0,a.exports}n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var a in e)n.d(r,a,function(t){return e[t]}.bind(null,a));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=336)}({1:function(e,t,n){"use strict";function r(e){"complete"!==document.readyState&&"interactive"!==document.readyState?document.addEventListener("DOMContentLoaded",e):e()}n.d(t,"a",(function(){return r}))},10:function(e,t){var n=/^(?:submit|button|image|reset|file)$/i,r=/^(?:input|select|textarea|keygen)/i,a=/(\[[^\[\]]*\])/g;function i(e,t,n){if(t.match(a))!function e(t,n,r){if(0===n.length)return r;var a=n.shift(),i=a.match(/^\[(.+?)\]$/);if("[]"===a)return t=t||[],Array.isArray(t)?t.push(e(null,n,r)):(t._values=t._values||[],t._values.push(e(null,n,r))),t;if(i){var o=i[1],c=+o;isNaN(c)?(t=t||{})[o]=e(t[o],n,r):(t=t||[])[c]=e(t[c],n,r)}else t[a]=e(t[a],n,r);return t}(e,function(e){var t=[],n=new RegExp(a),r=/^([^\[\]]*)/.exec(e);for(r[1]&&t.push(r[1]);null!==(r=n.exec(e));)t.push(r[1]);return t}(t),n);else{var r=e[t];r?(Array.isArray(r)||(e[t]=[r]),e[t].push(n)):e[t]=n}return e}function o(e,t,n){return n=n.replace(/(\r)?\n/g,"\r\n"),n=(n=encodeURIComponent(n)).replace(/%20/g,"+"),e+(e?"&":"")+encodeURIComponent(t)+"="+n}e.exports=function(e,t){"object"!=typeof t?t={hash:!!t}:void 0===t.hash&&(t.hash=!0);for(var a=t.hash?{}:"",c=t.serializer||(t.hash?i:o),s=e&&e.elements?e.elements:[],l=Object.create(null),u=0;u1&&void 0!==arguments[1]?arguments[1]:{};e(".simpay-upgrade-modal").dialog(o({position:{my:"center",at:"center",of:window},modal:!0,width:600,resizable:!1,draggable:!1,open:function(){var t=e(this);t.parent().find(".ui-dialog-titlebar").css({borderBottom:0}),t.find(".simpay-upgrade-modal__title").html(n),t.find(".simpay-upgrade-modal__description").html(r),t.find(".simpay-upgrade-modal__upgrade-url").attr("href",a),t.find(".simpay-upgrade-modal__upgrade-purchased-url").attr("href",i)}},c))}}).call(this,n(16))},148:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return a}));var r=n(1);function a(e,t){var n=document.getElementById("simpay-test-mode-toggle-notice");if(n)if(e!==t){var r=document.getElementById("simpay-toggle-notice-status"),a=document.getElementById("simpay-toggle-notice-status-link");n.style.display="block",r&&a&&(r.innerHTML=""+r.dataset[e]+"",a.href=a.dataset[e])}else n.style.display="none"}function i(){var t=document.querySelectorAll(".simpay-disconnect-link");if(t){var n=simpayAdmin.i18n,r=n.disconnectConfirm,a=n.disconnectCancel;t.forEach((function(t){t.addEventListener("click",(function(n){n.preventDefault(),e(".simpay-disconnect-confirm").dialog({resizable:!1,height:"auto",width:400,modal:!0,draggable:!1,open:function(){e(".ui-dialog-buttonset .ui-button").removeClass("ui-button").last().css({marginLeft:"10px"}).focus()},buttons:[{text:a,click:function(){e(this).dialog("close")},class:"button button-secondary"},{text:r,click:function(){window.location.href=t.href},class:"button button-primary"}]})}))}))}}Object(r.a)((function(){var e;(e=document.getElementById("simpay-stripe-account-info"))&&wp.ajax.send("simpay_stripe_connect_account_information",{data:{nonce:e.dataset.nonce},success:function(t){e.querySelector("p").innerHTML=t.message,e.style.display="block","simpay-stripe-activated-account-actions"===t.actions?e.classList.add("notice-info"):e.classList.add("notice-warning");var n=document.getElementById(t.actions);n&&(n.style.display="block"),i()},error:function(t){e.querySelector("p").innerHTML=t.message,e.style.display="block",e.classList.add("notice-error");var n=document.getElementById(t.actions);n&&(n.style.display="block",i())}})}))}).call(this,n(16))},16:function(e,t){e.exports=jQuery},17:function(e,t,n){"use strict";n.d(t,"a",(function(){return h})),n.d(t,"c",(function(){return v}));var r=function(e){return"string"!=typeof e||""===e?(console.error("The namespace must be a non-empty string."),!1):!!/^[a-zA-Z][a-zA-Z0-9_.\-\/]*$/.test(e)||(console.error("The namespace can only contain numbers, letters, dashes, periods, underscores and slashes."),!1)},a=function(e){return"string"!=typeof e||""===e?(console.error("The hook name must be a non-empty string."),!1):/^__/.test(e)?(console.error("The hook name cannot begin with `__`."),!1):!!/^[a-zA-Z][a-zA-Z0-9_.-]*$/.test(e)||(console.error("The hook name can only contain numbers, letters, dashes, periods and underscores."),!1)},i=function(e){return function(t,n,i){var o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:10;if(a(t)&&r(n))if("function"==typeof i)if("number"==typeof o){var c={callback:i,priority:o,namespace:n};if(e[t]){var s,l=e[t].handlers;for(s=l.length;s>0&&!(o>=l[s-1].priority);s--);s===l.length?l[s]=c:l.splice(s,0,c),(e.__current||[]).forEach((function(e){e.name===t&&e.currentIndex>=s&&e.currentIndex++}))}else e[t]={handlers:[c],runs:0};"hookAdded"!==t&&f("hookAdded",t,n,i,o)}else console.error("If specified, the hook priority must be a number.");else console.error("The hook callback must be a function.")}},o=function(e,t){return function(n,i){if(a(n)&&(t||r(i))){if(!e[n])return 0;var o=0;if(t)o=e[n].handlers.length,e[n]={runs:e[n].runs,handlers:[]};else for(var c=e[n].handlers,s=function(t){c[t].namespace===i&&(c.splice(t,1),o++,(e.__current||[]).forEach((function(e){e.name===n&&e.currentIndex>=t&&e.currentIndex--})))},l=c.length-1;l>=0;l--)s(l);return"hookRemoved"!==n&&f("hookRemoved",n,i),o}}},c=function(e){return function(t,n){return void 0!==n?t in e&&e[t].handlers.some((function(e){return e.namespace===n})):t in e}},s=function(e,t){return function(n){e[n]||(e[n]={handlers:[],runs:0}),e[n].runs++;for(var r=e[n].handlers,a=arguments.length,i=new Array(a>1?a-1:0),o=1;o .spinner").hide(),n.removeClass("active"),r.addClass("active"),t.addClass("simpay-panel-hidden"),i.removeClass("simpay-panel-hidden")}));var r="#form-display-options-settings-panel";location.hash.length&&(r=location.hash);var i=a('ul.simpay-tabs a[href="'+r+'"]');a('[name="simpay_form_settings_tab"]').val(r),i.length&&i.click()},stripeConnect:function(){var e="tr:nth-child(2), tr:nth-child(3), tr:nth-child(4), tr:nth-child(5)";a(".simpay-settings.stripe-account .form-table").find(e).hide(),a("#wpsp-api-keys-row-reveal button").on("click",(function(t){t.preventDefault(),a(".simpay-settings.stripe-account .form-table").find(e).show(),a("#wpsp-api-keys-row-hide").show(),a(this).parent().hide(),a(".wpsp-manual-key-warning").show()})),a("#wpsp-api-keys-row-hide button").on("click",(function(t){t.preventDefault(),a(".simpay-settings.stripe-account .form-table").find(e).hide(),a("#wpsp-api-keys-row-reveal").show(),a(this).parent().hide(),a(".wpsp-manual-key-warning").hide()}))},handleInternalLinkToTabClicks:function(e){var t=e.data("show-tab");i.find("."+t+"-tab a").click()}},(a=e)(document).ready((function(e){c.init()}))}.call(this,n(16))},337:function(e,t,n){"use strict";var r=n(1),a=simpayAdminSettingToggles||[];function i(e){var t=e.id,n=(e.value,e.toggles,document.querySelector(".simpay-settings-".concat(t)));if(!n)return{};var r=n.querySelector("input");r||(r=n.querySelector("select"));var a=r.value;return"checkbox"===r.type&&(a=!0===r.checked?"yes":"no"),{setting:r,currentValue:a}}function o(e){var t=e.id,n=e.value,r=e.toggles,c=i(e),s=(c.setting,c.currentValue);"none"!==document.querySelector(".simpay-settings-".concat(t)).style.display&&(r.map((function(e){return document.querySelector(".simpay-settings-".concat(e))})).forEach((function(e){e&&(e.style.display=s===n?"table-row":"none")})),r.forEach((function(e){var t=_.find(a,{id:e});t&&o(t)})))}Object(r.a)((function(){a.forEach((function(e){o(e),i(e).setting.addEventListener("change",(function(){return o(e)}))}))}))},338:function(e,t,n){"use strict";var r=n(1);Object(r.a)((function(){var e=window.wpsp.hooks,t=document.querySelectorAll('[name="simpay_settings[test_mode]"]');if(0!==t.length){var n="enabled"===document.querySelector('[name="simpay_settings[test_mode]"]:checked').value?"test":"live";e.doAction("settings.toggleTestMode",n,n),_.each(t,(function(t){return t.addEventListener("change",(function(t){var r="enabled"===t.target.value?"test":"live";e.doAction("settings.toggleTestMode",r,n)}))}))}}))},339:function(e,t,n){"use strict";var r=n(1);function a(e){var t=document.getElementById("simpay-connect-license-feedback"),n=document.getElementById("simpay-connect-license-submit");e.message?(t.innerText=e.message,t.classList.remove("simpay-license-message--valid"),t.classList.add("simpay-license-message--invalid"),t.style.display="block"):t.style.display="none",e.reload?setTimeout((function(){window.location.reload()}),2e3):(n.disabled=!1,n.innerText=n.dataset.connect)}function i(e){var t=document.getElementById("simpay-connect-license-feedback");e.message?(t.innerText=e.message,t.classList.remove("simpay-license-message--invalid"),t.classList.add("simpay-license-message--valid"),t.style.display="block"):t.style.display="none",e.reload?setTimeout((function(){window.location.reload()}),2e3):window.location=e.url}function o(){var e=document.getElementById("simpay-connect-license-key"),t=document.getElementById("simpay-connect-license-nonce"),n=document.getElementById("simpay-connect-license-submit");n.disabled=!0,n.innerText=n.dataset.connecting,wp.ajax.send("simpay_get_connect_url",{data:{nonce:t.value,key:e.value},success:i,error:a})}Object(r.a)((function(){var e=document.getElementById("simpay-connect-license-key");if(e){var t=document.getElementById("simpay-connect-license-submit");e.addEventListener("keypress",(function(e){"Enter"===e.key&&(e.preventDefault(),o())})),t.addEventListener("click",(function(e){e.preventDefault(),t.disabled=!0,o()}))}}))},340:function(e,t,n){"use strict";var r=n(1);Object(r.a)((function(){var e=document.querySelector(".simpay-recaptcha-feedback");if(e){var t=simpayGoogleRecaptcha,n=t.siteKey,r=t.i18n;""!==n&&grecaptcha.ready((function(){var e=document.querySelector(".grecaptcha-badge");e&&(e.style.display="none");try{grecaptcha.execute(n,{action:"simple_pay_admin_test"}).then((function(e){wp.ajax.send("simpay_validate_recaptcha_source",{data:{token:e,recaptcha_action:"simple_pay_admin_test"},error:a})})).catch(a)}catch(e){a()}}))}function a(){e.style.display="block",e.classList.add("notice-error"),e.querySelector("p").innerText=r.invalid}}))},341:function(e,t,n){"use strict";(function(e){var t=n(10),r=n.n(t),a=n(1),i=n(8);Object(a.a)((function(){var t,n,a,o,c=document.querySelector(".post-type-simple-pay #post");if(c){var s=r()(c,{hash:!0});delete s.simpay_form_settings_tab,function(t){function n(e){var n=r()(document.querySelector(".post-type-simple-pay form#post"),{hash:!0});if(delete n.simpay_form_settings_tab,delete n.simpay_save_preview,JSON.stringify(n)!==t)return e.preventDefault(),simpayAdmin.i18n.leavePageConfirm}window.addEventListener("beforeunload",n),window.onbeforeunload=n,e(".post-type-simple-pay form#post").off("submit").on("submit",(function(){window.removeEventListener("beforeunload",n),window.onbeforeunload=null}))}(JSON.stringify(s)),a=document.getElementById("form-type-select"),o=document.getElementById("is-overlay"),a.addEventListener("change",(function(e){var t=e.target,n=t.options[t.selectedIndex],r=n.value;"on-site"===r&&Object(i.maybeBlockSelectWithUpgradeModal)(e),"off-site"===r&&(o.querySelector("input").checked=!1),o.style.display="yes"===n.dataset.available&&"on-site"===r?"block":"none"})),function(){var e=document.querySelector(".simpay-recaptcha-payment-form-feedback");if(e){var t=simpayGoogleRecaptcha,n=t.siteKey,r=t.i18n,a=t.settingsUrl,i=document.getElementById("_recaptcha");if(i.addEventListener("change",(function(e){e.preventDefault(),e.target.checked=!e.target.checked,window.open(a,"_blank")})),i.checked){if(""===n)return o();grecaptcha.ready((function(){var e=document.querySelector(".grecaptcha-badge");e&&(e.style.display="none");try{grecaptcha.execute(n,{action:"simple_pay_admin_test"}).then((function(e){wp.ajax.send("simpay_validate_recaptcha_source",{data:{token:e,recaptcha_action:"simple_pay_admin_test"},success:c,error:o})})).catch(o)}catch(e){o()}}))}}function o(){e.style.color="#b91c1c",e.style.display="inline",e.innerHTML=r.invalid,i.checked=!1,i.readOnly=!1}function c(){e.style.color="#15803d",e.style.display="inline",e.innerHTML=r.valid,i.checked=!0,i.readOnly=!0}}(),(n=document.getElementById("_email_verification"))&&n.addEventListener("change",(function(e){e.preventDefault(),e.target.checked=!e.target.checked,window.open(e.target.dataset.settingsUrl,"_blank")})),(t=document.querySelector("#_company_name"))&&(t.addEventListener("blur",(function(){0===t.value.length?(t.nextElementSibling.classList.remove("hidden"),t.value=simpayAdmin.siteTitle):t.nextElementSibling.classList.add("hidden")})),t.addEventListener("focus",(function(){0!==t.value.length&&t.nextElementSibling.classList.add("hidden")})))}}))}).call(this,n(16))},342:function(e,t,n){"use strict";(function(e,t){var r=n(37),a=n.n(r),i=n(1),o=n(17),c=n(8);function s(){var e=document.getElementById("simpay-prices");if(e){var t=e.querySelectorAll(".simpay-price").length;document.querySelectorAll(".simpay-price-label-default").forEach((function(e){return e.style.display=t>1?"none":"block"})),document.querySelectorAll(".simpay-price-label-display").forEach((function(e){return e.style.display=t>1?"block":"none"})),document.querySelectorAll(".simpay-price-option-label").forEach((function(e){return e.style.display=t>1?"block":"none"})),document.querySelectorAll(".simpay-price-default-check").forEach((function(e){return e.style.display=t>1?"block":"none"}));var n=document.querySelectorAll(".simpay-panel-field-price-select");if(n.length>0){n.forEach((function(e){return e.style.display=t>1?"table-row":"none"}));var r=document.querySelector(".simpay-panel-field-price-select-notice");r&&(r.style.display=1===t?"table-row":"none")}}}function l(e){var t,n=e.querySelector(".simpay-price-label-display"),r=e.querySelector(".simpay-price-label"),a=spGeneral.strings,i=a.recurringIntervalDisplay,c=a.customAmountLabel;if(""!==r.value)t=r.value;else{var s=e.querySelector(".simpay-price-currency"),l=e.querySelector(".simpay-price-amount"),u=e.querySelector(".simpay-price-amount-type"),d=e.querySelector(".simpay-price-custom-amount input"),p=e.querySelector(".simpay-price-enable-custom-amount"),m=spGeneral.strings,f=m.currencyPosition,y=m.recurringIntervals,h=s.options[s.selectedIndex].dataset.symbol;switch(t=!0===p.checked?d.value:l.value,f){case"left":t="".concat(h).concat(t);break;case"left_space":t="".concat(h," ").concat(t);break;case"right":t="".concat(t).concat(h);break;case"right_space":t="".concat(t," ").concat(h)}if(!0===p.checked&&(t=c.replace("%s",t)),"recurring"===u.value){var v=e.querySelector(".simpay-price-recurring-interval"),g=e.querySelector(".simpay-price-recurring-interval-count"),b=y[v.options[v.selectedIndex].value];t=i.replace("%1$s",t).replace("%2$s",g.value).replace("%3$s","1"===g.value?b[0]:b[1])}}n.innerHTML=t,Object(o.c)("simpayFormBuilderPriceOptionLabelUpdated",t,e)}function u(e,t){e.querySelector(".simpay-price-recurring-settings").style.display=t.checked?"table":"none"}function d(e){var t=e.querySelector(".simpay-price-recurring-interval"),n=e.querySelector(".simpay-price-recurring-interval-count"),r=parseInt(n.value);switch(t.options[t.selectedIndex].value){case"day":r>365&&(n.value=365);break;case"week":r>52&&(n.value=52);break;case"month":r>12&&(n.value=12);break;case"year":r>1&&(n.value=1)}var i=JSON.parse(t.dataset.intervals);a()(t.options).forEach((function(e,r){var a=e.value;t.options[r].text=1===parseInt(n.value)?i[a][0]:i[a][1]}))}function p(){var e=document.querySelectorAll(".simpay-price");_.each(e,(function(e){var t=e.querySelector(".simpay-price-amount-type").value;e.querySelector(".simpay-price-label").addEventListener("keyup",(function(){return l(e)})),l(e),e.querySelector(".simpay-price-currency").addEventListener("change",(function(){!function(e){var t=e.querySelector(".simpay-price-currency"),n=t.options[t.selectedIndex].dataset.symbol,r=e.querySelectorAll(".simpay-price-currency-symbol");_.each(r,(function(e){return e.innerText=n}))}(e),l(e)}));var n=e.querySelectorAll(".simpay-price-amount-type .button");n.length>0&&_.each(n,(function(t){return t.addEventListener("click",(function(t){t.preventDefault();var n=t.target.dataset,r=n.available,a=n.upgradeTitle,i=n.upgradeDescription,o=n.upgradeUrl,s=n.upgradePurchasedUrl;"no"===r?Object(c.upgradeModal)({title:a,description:i,url:o,purchasedUrl:s}):(function(e,t){var n=e.querySelectorAll(".simpay-price-amount-type .button");_.each(n,(function(e){return e.classList.remove("button-primary")}));var r=t.dataset.amountType,a=e.querySelector(".simpay-price-recurring-settings");t.classList.add("button-primary"),a.style.display="recurring"===r?"table":"none";var i=e.querySelector(".simpay-price-recurring-amount-toggle"),o=e.querySelector(".simpay-price-enable-optional-subscription");i.style.display="recurring"===r?"none":"block",o.checked=!1,e.querySelector(".simpay-price-amount-type").value=r}(e,t.target),l(e))}))})),e.querySelector(".simpay-price-amount").addEventListener("keyup",(function(){return l(e)}));var r=e.querySelector(".simpay-price-enable-optional-subscription");r&&(r.addEventListener("click",(function(t){var n=t.target,r=n.dataset,a=r.available,i=r.upgradeTitle,o=r.upgradeDescription,s=r.upgradeUrl,d=r.upgradePurchasedUrl;"no"===a?(n.checked=!1,t.preventDefault(),Object(c.upgradeModal)({title:i,description:o,url:s,purchasedUrl:d})):(u(e,n),l(e))})),"recurring"!==t&&u(e,r)),e.querySelector(".simpay-price-enable-custom-amount").addEventListener("click",(function(){!function(e){var t=e.querySelector(".simpay-price-custom-amount");t.style.display="none"===t.style.display?"block":"none"}(e),l(e)})),e.querySelector(".simpay-price-recurring-interval").addEventListener("change",(function(){l(e),d(e)}));var a=e.querySelector(".simpay-price-recurring-interval-count");d(e),a.addEventListener("keyup",(function(){d(e),l(e)})),a.addEventListener("change",(function(){d(e),l(e)}));var i=e.querySelector(".simpay-price-legacy-setting-toggle");i&&i.addEventListener("click",(function(t){t.preventDefault(),function(e){var t=e.querySelectorAll(".simpay-price-legacy-setting");_.each(t,(function(e){return e.style.display="block"===e.style.display?"none":"block"}))}(e)})),e.querySelector(".simpay-price-default").addEventListener("change",(function(){return function(e){var t=document.querySelectorAll(".simpay-price-default");_.each(t,(function(e){return e.checked=!1})),e.querySelector(".simpay-price-default").checked=!0}(e)})),e.querySelector(".simpay-price-remove").addEventListener("click",(function(t){t.preventDefault(),function(e){e.remove(),m(),s(),Object(o.c)("simpayFormBuilderPriceRemoved",e.id)}(e)}))})),s()}function m(){var e=document.querySelectorAll(".simpay-price");document.querySelector(".simpay-price-default:checked")||(e[0].querySelector(".simpay-price-default").checked=!0)}Object(i.a)((function(){var n,r,a,i,l,u,d;t(".simpay-prices").sortable({items:".simpay-field-metabox",containment:"#simpay-prices",handle:".simpay-hndle",placeholder:"sortable-placeholder",cursor:"move",delay:t(document.body).hasClass("mobile")?200:0,distance:2,tolerance:"pointer",forcePlaceholderSize:!0,opacity:.65,helper:function(e,t){return t.clone().find(":input").attr("name",(function(e,t){return"sort_"+parseInt(1e5*Math.random(),10).toString()+"_"+t})).end()}}),p(),n=document.getElementById("simpay-prices-advanced-toggle"),r=document.getElementById("simpay-prices-advanced"),n&&r&&n.addEventListener("click",(function(e){e.preventDefault(),r.style.display="block"==r.style.display?"none":"block"})),(d=document.getElementById("simpay-prices-advanced-add"))&&d.addEventListener("click",(function(t){var n,r,a,i,o,c;t.preventDefault(),a=(r=(n=d).dataset).nonce,i=r.formId,o=document.getElementById("simpay-prices"),c=document.getElementById("simpay-prices-advanced-plan-id"),n.classList.add("disabled"),wp.ajax.send("simpay_add_plan",{data:{_wpnonce:a,form_id:i,plan_id:c.value},success:function(t){e(o).append(t),p(),document.getElementById("simpay-prices-advanced").style.display="none",c.value="",n.classList.remove("disabled"),s()},error:function(e){var t=e.message;alert(t),n.classList.remove("disabled")}})})),function(){var t=document.getElementById("simpay-add-price");t&&t.addEventListener("click",(function(n){var r,a,i,c,l;n.preventDefault(),i=(a=(r=t).dataset).nonce,c=a.formId,l=document.getElementById("simpay-prices"),r.classList.add("disabled"),wp.ajax.send("simpay_add_price",{data:{_wpnonce:i,form_id:c},success:function(t){e(l).append(t),p(),m(),r.classList.remove("disabled"),s(),Object(o.c)("simpayFormBuilderPriceAdded",t)},error:function(e){var t=e.message;alert(t),r.classList.remove("disabled")}})}))}(),(a=document.getElementById("simpay-add-price-lite"))&&a.addEventListener("click",c.maybeBlockButtonWithUpgradeModal),(i=document.getElementById("simpay-amount-type-lite"))&&i.addEventListener("click",c.maybeBlockButtonWithUpgradeModal),(l=document.getElementById("simpay-can-recur-lite"))&&l.addEventListener("click",c.maybeBlockButtonWithUpgradeModal),(u=document.getElementById("simpay-custom-lite"))&&u.addEventListener("click",c.maybeBlockButtonWithUpgradeModal)}))}).call(this,n(16),n(16))},343:function(e,t,n){"use strict";(function(e){var t=n(1),r=n(8);Object(t.a)((function(){var t,n,a;(t=document.querySelector('[name="_enable_payment_page"]'))&&t.addEventListener("change",r.maybeBlockCheckboxWithUpgradeModal),(n=document.querySelector('[name="_payment_page_powered_by"]'))&&n.addEventListener("change",r.maybeBlockCheckboxWithUpgradeModal),function(){if(document.getElementById("payment-page-background-color-custom")){e("#payment-page-background-color-custom").wpColorPicker();var t=document.querySelector(".simpay-payment-page-background-color .wp-color-result"),n=document.querySelectorAll(".simpay-payment-page-background-color");t.addEventListener("click",(function(t){n.forEach((function(e){e.querySelector("input").checked=!1})),t.target.classList.add("is-selected"),e(t.target).parent().find("input").prop("checked",!0)})),n.forEach((function(e){e.querySelector("input").addEventListener("change",(function(){t.classList.remove("is-selected")}))}))}}(),(a=document.querySelector('[name="_payment_page_slug"]'))&&a.addEventListener("keyup",(function(e){var t=document.querySelector(".simpay-payment-page-url");t&&(t.dataset.clipboardText="".concat(window.location.origin,"/").concat(e.target.value))}))}))}).call(this,n(16))},344:function(e,t,n){"use strict";(function(e){var t=n(20),r=n.n(t),a=n(1),i='',o='',c=simpayAdmin,s=c.nonce,l=c.ajaxUrl,u=c.i18n,d=u.addonActivated,p=u.addonActivate,m=u.addonActive,f=u.addonDeactivate,y=u.addonInactive,h=u.addonInstall,v=u.addonError,g=u.pluginError;function b(t){t.preventDefault();var n,a,c,u,b,_,k=e(t.target);if(k.hasClass("status-go-to-url"))window.open(k.attr("data-plugin"),"_blank");else{var w=k.attr("data-type");if(k.prop("disabled",!0).addClass("loading"),k.html(''),k.hasClass("status-active"))n="deactivate",a="status-installed","plugin"===w&&(a+=" button button-secondary"),c=y,u=p,b=f,"addon"===w&&(u=i+u,b=o+b);else if(k.hasClass("status-installed"))n="activate",a="status-active","plugin"===w&&(a+=" button button-secondary disabled"),c=m,u=f,"addon"===w?(u=o+u,b=i+p):"plugin"===w&&(u=d,b=p);else{if(!k.hasClass("status-missing"))return;n="install",a="status-active","plugin"===w&&(a+=" button disabled"),c=m,u=d,b='',"addon"===w&&(u=i+f,b+=h)}var E=k.closest(".simpay-addon");!function(t,n,r,a){var i={activate:"simpay_activate_addon",install:"simpay_install_addon",deactivate:"simpay_deactivate_addon"}[n];if(i){var o={action:i,nonce:s,plugin:t,type:r};e.post(l,o,a).fail((function(e){console.log(e.responseText)}))}}(k.attr("data-plugin"),n,w,(function(e){e.success?("install"===n?(k.attr("data-plugin",e.data.basename),_=e.data.msg,e.data.is_activated||(c=y,u="plugin"===w?p:i+p,a="plugin"===w?"status-installed button button-secondary":"status-installed")):_=e.data,E.find(".simpay-addon__actions").append('
'+_+"
"),E.find("span.status-label").removeClass("status-active status-installed status-missing").addClass(a).removeClass("button button-primary button-secondary disabled").text(c),k.removeClass("status-active status-installed status-missing").removeClass("button button-primary button-secondary disabled").addClass(a).html(u)):("object"===r()(e.data)?"addon"===w?E.find(".simpay-addon__actions").append('
'+v+"
"):E.find(".simpay-addon__actions").append('
'+g+"
"):E.find(".simpay-addon__actions").append('
'+e.data+"
"),"install"===n&&"plugin"===w&&k.addClass("status-go-to-url").removeClass("status-missing"),k.html(b)),k.prop("disabled",!1).removeClass("loading"),setTimeout((function(){E.find(".msg").remove()}),3e3)}))}}Object(a.a)((function(){document.querySelector(".simpay-addons")&&document.querySelectorAll(".simpay-addon").forEach((function(e){e.querySelector("button").addEventListener("click",b)}))}))}).call(this,n(16))},345:function(e,t,n){"use strict";var r=n(1);Object(r.a)((function(){var e=new ClipboardJS(".simpay-copy-button");e.on("success",(function(t){var n=t.trigger,r=n.dataset.copied,a=n.innerHTML;clearTimeout(i),n.innerHTML=r,n.classList.contains("button-secondary")&&(n.style.color="green",n.style.borderColor="green"),t.clearSelection();var i=setTimeout((function(){n.innerHTML=a,n.classList.contains("button-secondary")&&(n.style.color="",n.style.borderColor=""),e.clipboardAction.fakeElem&&e.clipboardAction.removeFake&&e.clipboardAction.removeFake()}),3e3);wp.a11y.speak(r)}))}))},359:function(e,t,n){"use strict";n(341),n(342);var r=n(37),a=n.n(r),i=n(1),o=n(8);function c(e){var t=e.target,n=t.options[t.selectedIndex].value,r=document.querySelectorAll(".simpay-panel-field-payment-method[data-payment-method]");a()(r).forEach((function(e){var t="popular"===JSON.parse(e.dataset.paymentMethod).scope?"block":"none";e.style.display="all"===n?"block":t}))}Object(i.a)((function(){var e=document.querySelectorAll(".simpay-panel-field-payment-method-filter");0!==e.length&&a()(e).forEach((function(e){e.addEventListener("change",c)}));var t=document.querySelectorAll(".simpay-payment-method-lite");t&&t.forEach((function(e){return e.addEventListener("change",o.maybeBlockCheckboxWithUpgradeModal)}))})),Object(i.a)((function(){var e=document.getElementById("_tax_status_lite");e&&e.addEventListener("change",o.maybeBlockSelectWithUpgradeModal)})),Object(i.a)((function(){var e;document.querySelector(".post-type-simple-pay #post")&&(e=document.getElementById("simpay-add-field-lite"))&&e.addEventListener("click",o.maybeBlockButtonWithUpgradeModal)})),Object(i.a)((function(){var e,t;(e=document.getElementById("_enable_tax_id"))&&e.addEventListener("change",o.maybeBlockCheckboxWithUpgradeModal),(t=document.getElementById("_enable_promotion_codes"))&&t.addEventListener("change",o.maybeBlockCheckboxWithUpgradeModal)})),n(343),Object(i.a)((function(){var e=document.getElementById("_inventory");e&&e.addEventListener("change",o.maybeBlockCheckboxWithUpgradeModal);var t=document.getElementById("_inventory_behavior_individual");t&&t.addEventListener("change",o.maybeBlockCheckboxWithUpgradeModal);var n=document.getElementById("_schedule_start");n&&n.addEventListener("change",o.maybeBlockCheckboxWithUpgradeModal);var r=document.getElementById("_schedule_end");r&&r.addEventListener("change",o.maybeBlockCheckboxWithUpgradeModal)}))},37:function(e,t,n){var r=n(109),a=n(110),i=n(111),o=n(112);e.exports=function(e){return r(e)||a(e)||i(e)||o()},e.exports.__esModule=!0,e.exports.default=e.exports},59:function(e,t,n){"use strict";n.d(t,"a",(function(){return r})),n.d(t,"b",(function(){return a}));var r={};n.r(r),n.d(r,"create",(function(){return p}));var a={};n.r(a),n.d(a,"create",(function(){return y}));var i=n(2),o=n(3),c=n.n(o),s=n(10),l=n.n(s);function u(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function d(e){for(var t=1;t0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0,n=t.id,r=t.getFormData;return Object(i.a)("v2/customer",d({form_values:l()(t[0],{hash:!0}),form_data:r(),form_id:n},e))}function m(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function f(e){for(var t=1;t0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0,n=t.id,r=t.getFormData;return Object(i.a)("v2/checkout-session",f({form_values:l()(t[0],{hash:!0}),form_data:r(),form_id:n},e))}n(19),n(11),n(33)},65:function(e,t,n){var r=function(e){"use strict";var t=Object.prototype,n=t.hasOwnProperty,r="function"==typeof Symbol?Symbol:{},a=r.iterator||"@@iterator",i=r.asyncIterator||"@@asyncIterator",o=r.toStringTag||"@@toStringTag";function c(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{c({},"")}catch(e){c=function(e,t,n){return e[t]=n}}function s(e,t,n,r){var a=t&&t.prototype instanceof d?t:d,i=Object.create(a.prototype),o=new E(r||[]);return i._invoke=function(e,t,n){var r="suspendedStart";return function(a,i){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===a)throw i;return{value:void 0,done:!0}}for(n.method=a,n.arg=i;;){var o=n.delegate;if(o){var c=_(o,n);if(c){if(c===u)continue;return c}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if("suspendedStart"===r)throw r="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";var s=l(e,t,n);if("normal"===s.type){if(r=n.done?"completed":"suspendedYield",s.arg===u)continue;return{value:s.arg,done:n.done}}"throw"===s.type&&(r="completed",n.method="throw",n.arg=s.arg)}}}(e,n,o),i}function l(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}e.wrap=s;var u={};function d(){}function p(){}function m(){}var f={};c(f,a,(function(){return this}));var y=Object.getPrototypeOf,h=y&&y(y(x([])));h&&h!==t&&n.call(h,a)&&(f=h);var v=m.prototype=d.prototype=Object.create(f);function g(e){["next","throw","return"].forEach((function(t){c(e,t,(function(e){return this._invoke(t,e)}))}))}function b(e,t){var r;this._invoke=function(a,i){function o(){return new t((function(r,o){!function r(a,i,o,c){var s=l(e[a],e,i);if("throw"!==s.type){var u=s.arg,d=u.value;return d&&"object"==typeof d&&n.call(d,"__await")?t.resolve(d.__await).then((function(e){r("next",e,o,c)}),(function(e){r("throw",e,o,c)})):t.resolve(d).then((function(e){u.value=e,o(u)}),(function(e){return r("throw",e,o,c)}))}c(s.arg)}(a,i,r,o)}))}return r=r?r.then(o,o):o()}}function _(e,t){var n=e.iterator[t.method];if(void 0===n){if(t.delegate=null,"throw"===t.method){if(e.iterator.return&&(t.method="return",t.arg=void 0,_(e,t),"throw"===t.method))return u;t.method="throw",t.arg=new TypeError("The iterator does not provide a 'throw' method")}return u}var r=l(n,e.iterator,t.arg);if("throw"===r.type)return t.method="throw",t.arg=r.arg,t.delegate=null,u;var a=r.arg;return a?a.done?(t[e.resultName]=a.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=void 0),t.delegate=null,u):a:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,u)}function k(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function w(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function E(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(k,this),this.reset(!0)}function x(e){if(e){var t=e[a];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,i=function t(){for(;++r=0;--a){var i=this.tryEntries[a],o=i.completion;if("root"===i.tryLoc)return r("end");if(i.tryLoc<=this.prev){var c=n.call(i,"catchLoc"),s=n.call(i,"finallyLoc");if(c&&s){if(this.prev=0;--r){var a=this.tryEntries[r];if(a.tryLoc<=this.prev&&n.call(a,"finallyLoc")&&this.prev=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),w(n),u}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var a=r.arg;w(n)}return a}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:x(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=void 0),u}},e}(e.exports);try{regeneratorRuntime=r}catch(e){"object"==typeof globalThis?globalThis.regeneratorRuntime=r:Function("r","regeneratorRuntime = r")(r)}},66:function(e,t){e.exports=function(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n1&&void 0!==arguments[1]?arguments[1]:{};e(".simpay-upgrade-modal").dialog(o({position:{my:"center",at:"center",of:window},modal:!0,width:600,resizable:!1,draggable:!1,open:function(){var t=e(this);t.parent().find(".ui-dialog-titlebar").css({borderBottom:0}),t.find(".simpay-upgrade-modal__title").html(n),t.find(".simpay-upgrade-modal__description").html(r),t.find(".simpay-upgrade-modal__upgrade-url").attr("href",a),t.find(".simpay-upgrade-modal__upgrade-purchased-url").attr("href",i)}},c))}}).call(this,n(16))},148:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return a}));var r=n(1);function a(e,t){var n=document.getElementById("simpay-test-mode-toggle-notice");if(n)if(e!==t){var r=document.getElementById("simpay-toggle-notice-status"),a=document.getElementById("simpay-toggle-notice-status-link");n.style.display="block",r&&a&&(r.innerHTML=""+r.dataset[e]+"",a.href=a.dataset[e])}else n.style.display="none"}function i(){var t=document.querySelectorAll(".simpay-disconnect-link");if(t){var n=simpayAdmin.i18n,r=n.disconnectConfirm,a=n.disconnectCancel;t.forEach((function(t){t.addEventListener("click",(function(n){n.preventDefault(),e(".simpay-disconnect-confirm").dialog({resizable:!1,height:"auto",width:400,modal:!0,draggable:!1,open:function(){e(".ui-dialog-buttonset .ui-button").removeClass("ui-button").last().css({marginLeft:"10px"}).focus()},buttons:[{text:a,click:function(){e(this).dialog("close")},class:"button button-secondary"},{text:r,click:function(){window.location.href=t.href},class:"button button-primary"}]})}))}))}}Object(r.a)((function(){var e;(e=document.getElementById("simpay-stripe-account-info"))&&wp.ajax.send("simpay_stripe_connect_account_information",{data:{nonce:e.dataset.nonce},success:function(t){e.querySelector("p").innerHTML=t.message,e.style.display="block","simpay-stripe-activated-account-actions"===t.actions?e.classList.add("notice-info"):e.classList.add("notice-warning");var n=document.getElementById(t.actions);n&&(n.style.display="block"),i()},error:function(t){e.querySelector("p").innerHTML=t.message,e.style.display="block",e.classList.add("notice-error");var n=document.getElementById(t.actions);n&&(n.style.display="block",i())}})}))}).call(this,n(16))},16:function(e,t){e.exports=jQuery},17:function(e,t,n){"use strict";n.d(t,"a",(function(){return h})),n.d(t,"c",(function(){return v}));var r=function(e){return"string"!=typeof e||""===e?(console.error("The namespace must be a non-empty string."),!1):!!/^[a-zA-Z][a-zA-Z0-9_.\-\/]*$/.test(e)||(console.error("The namespace can only contain numbers, letters, dashes, periods, underscores and slashes."),!1)},a=function(e){return"string"!=typeof e||""===e?(console.error("The hook name must be a non-empty string."),!1):/^__/.test(e)?(console.error("The hook name cannot begin with `__`."),!1):!!/^[a-zA-Z][a-zA-Z0-9_.-]*$/.test(e)||(console.error("The hook name can only contain numbers, letters, dashes, periods and underscores."),!1)},i=function(e){return function(t,n,i){var o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:10;if(a(t)&&r(n))if("function"==typeof i)if("number"==typeof o){var c={callback:i,priority:o,namespace:n};if(e[t]){var s,l=e[t].handlers;for(s=l.length;s>0&&!(o>=l[s-1].priority);s--);s===l.length?l[s]=c:l.splice(s,0,c),(e.__current||[]).forEach((function(e){e.name===t&&e.currentIndex>=s&&e.currentIndex++}))}else e[t]={handlers:[c],runs:0};"hookAdded"!==t&&f("hookAdded",t,n,i,o)}else console.error("If specified, the hook priority must be a number.");else console.error("The hook callback must be a function.")}},o=function(e,t){return function(n,i){if(a(n)&&(t||r(i))){if(!e[n])return 0;var o=0;if(t)o=e[n].handlers.length,e[n]={runs:e[n].runs,handlers:[]};else for(var c=e[n].handlers,s=function(t){c[t].namespace===i&&(c.splice(t,1),o++,(e.__current||[]).forEach((function(e){e.name===n&&e.currentIndex>=t&&e.currentIndex--})))},l=c.length-1;l>=0;l--)s(l);return"hookRemoved"!==n&&f("hookRemoved",n,i),o}}},c=function(e){return function(t,n){return void 0!==n?t in e&&e[t].handlers.some((function(e){return e.namespace===n})):t in e}},s=function(e,t){return function(n){e[n]||(e[n]={handlers:[],runs:0}),e[n].runs++;for(var r=e[n].handlers,a=arguments.length,i=new Array(a>1?a-1:0),o=1;o .spinner").hide(),n.removeClass("active"),r.addClass("active"),t.addClass("simpay-panel-hidden"),i.removeClass("simpay-panel-hidden")}));var r="#form-display-options-settings-panel";location.hash.length&&(r=location.hash);var i=a('ul.simpay-tabs a[href="'+r+'"]');a('[name="simpay_form_settings_tab"]').val(r),i.length&&i.click()},stripeConnect:function(){var e="tr:nth-child(2), tr:nth-child(3), tr:nth-child(4), tr:nth-child(5)";a(".simpay-settings.stripe-account .form-table").find(e).hide(),a("#wpsp-api-keys-row-reveal button").on("click",(function(t){t.preventDefault(),a(".simpay-settings.stripe-account .form-table").find(e).show(),a("#wpsp-api-keys-row-hide").show(),a(this).parent().hide(),a(".wpsp-manual-key-warning").show()})),a("#wpsp-api-keys-row-hide button").on("click",(function(t){t.preventDefault(),a(".simpay-settings.stripe-account .form-table").find(e).hide(),a("#wpsp-api-keys-row-reveal").show(),a(this).parent().hide(),a(".wpsp-manual-key-warning").hide()}))},handleInternalLinkToTabClicks:function(e){var t=e.data("show-tab");i.find("."+t+"-tab a").click()}},(a=e)(document).ready((function(e){c.init()}))}.call(this,n(16))},337:function(e,t,n){"use strict";var r=n(1),a=simpayAdminSettingToggles||[];function i(e){var t=e.id,n=(e.value,e.toggles,document.querySelector(".simpay-settings-".concat(t)));if(!n)return{};var r=n.querySelector("input");r||(r=n.querySelector("select"));var a=r.value;return"checkbox"===r.type&&(a=!0===r.checked?"yes":"no"),{setting:r,currentValue:a}}function o(e){var t=e.id,n=e.value,r=e.toggles,c=i(e),s=(c.setting,c.currentValue);"none"!==document.querySelector(".simpay-settings-".concat(t)).style.display&&(r.map((function(e){return document.querySelector(".simpay-settings-".concat(e))})).forEach((function(e){e&&(e.style.display=s===n?"table-row":"none")})),r.forEach((function(e){var t=_.find(a,{id:e});t&&o(t)})))}Object(r.a)((function(){a.forEach((function(e){o(e),i(e).setting.addEventListener("change",(function(){return o(e)}))}))}))},338:function(e,t,n){"use strict";var r=n(1);Object(r.a)((function(){var e=window.wpsp.hooks,t=document.querySelectorAll('[name="simpay_settings[test_mode]"]');if(0!==t.length){var n="enabled"===document.querySelector('[name="simpay_settings[test_mode]"]:checked').value?"test":"live";e.doAction("settings.toggleTestMode",n,n),_.each(t,(function(t){return t.addEventListener("change",(function(t){var r="enabled"===t.target.value?"test":"live";e.doAction("settings.toggleTestMode",r,n)}))}))}}))},339:function(e,t,n){"use strict";var r=n(1);function a(e){var t=document.getElementById("simpay-connect-license-feedback"),n=document.getElementById("simpay-connect-license-submit");e.message?(t.innerText=e.message,t.classList.remove("simpay-license-message--valid"),t.classList.add("simpay-license-message--invalid"),t.style.display="block"):t.style.display="none",e.reload?setTimeout((function(){window.location.reload()}),2e3):(n.disabled=!1,n.innerText=n.dataset.connect)}function i(e){var t=document.getElementById("simpay-connect-license-feedback");e.message?(t.innerText=e.message,t.classList.remove("simpay-license-message--invalid"),t.classList.add("simpay-license-message--valid"),t.style.display="block"):t.style.display="none",e.reload?setTimeout((function(){window.location.reload()}),2e3):window.location=e.url}function o(){var e=document.getElementById("simpay-connect-license-key"),t=document.getElementById("simpay-connect-license-nonce"),n=document.getElementById("simpay-connect-license-submit");n.disabled=!0,n.innerText=n.dataset.connecting,wp.ajax.send("simpay_get_connect_url",{data:{nonce:t.value,key:e.value},success:i,error:a})}Object(r.a)((function(){var e=document.getElementById("simpay-connect-license-key");if(e){var t=document.getElementById("simpay-connect-license-submit");e.addEventListener("keypress",(function(e){"Enter"===e.key&&(e.preventDefault(),o())})),t.addEventListener("click",(function(e){e.preventDefault(),t.disabled=!0,o()}))}}))},340:function(e,t,n){"use strict";var r=n(1);Object(r.a)((function(){var e=document.querySelector(".simpay-recaptcha-feedback");if(e){var t=simpayGoogleRecaptcha,n=t.siteKey,r=t.i18n;""!==n&&grecaptcha.ready((function(){var e=document.querySelector(".grecaptcha-badge");e&&(e.style.display="none");try{grecaptcha.execute(n,{action:"simple_pay_admin_test"}).then((function(e){wp.ajax.send("simpay_validate_recaptcha_source",{data:{token:e,recaptcha_action:"simple_pay_admin_test"},error:a})})).catch(a)}catch(e){a()}}))}function a(){e.style.display="block",e.classList.add("notice-error"),e.querySelector("p").innerText=r.invalid}}))},341:function(e,t,n){"use strict";(function(e){var t=n(10),r=n.n(t),a=n(1),i=n(8);Object(a.a)((function(){var t,n,a,o,c=document.querySelector(".post-type-simple-pay #post");if(c){var s=r()(c,{hash:!0});delete s.simpay_form_settings_tab,function(t){function n(e){var n=r()(document.querySelector(".post-type-simple-pay form#post"),{hash:!0});if(delete n.simpay_form_settings_tab,delete n.simpay_save_preview,JSON.stringify(n)!==t)return e.preventDefault(),simpayAdmin.i18n.leavePageConfirm}window.addEventListener("beforeunload",n),window.onbeforeunload=n,e(".post-type-simple-pay form#post").off("submit").on("submit",(function(){window.removeEventListener("beforeunload",n),window.onbeforeunload=null}))}(JSON.stringify(s)),a=document.getElementById("form-type-select"),o=document.getElementById("is-overlay"),a.addEventListener("change",(function(e){var t=e.target,n=t.options[t.selectedIndex],r=n.value;"on-site"===r&&Object(i.maybeBlockSelectWithUpgradeModal)(e),"off-site"===r&&(o.querySelector("input").checked=!1),o.style.display="yes"===n.dataset.available&&"on-site"===r?"block":"none"})),function(){var e=document.querySelector(".simpay-recaptcha-payment-form-feedback");if(e){var t=simpayGoogleRecaptcha,n=t.siteKey,r=t.i18n,a=t.settingsUrl,i=document.getElementById("_recaptcha");if(i.addEventListener("change",(function(e){e.preventDefault(),e.target.checked=!e.target.checked,window.open(a,"_blank")})),i.checked){if(""===n)return o();grecaptcha.ready((function(){var e=document.querySelector(".grecaptcha-badge");e&&(e.style.display="none");try{grecaptcha.execute(n,{action:"simple_pay_admin_test"}).then((function(e){wp.ajax.send("simpay_validate_recaptcha_source",{data:{token:e,recaptcha_action:"simple_pay_admin_test"},success:c,error:o})})).catch(o)}catch(e){o()}}))}}function o(){e.style.color="#b91c1c",e.style.display="inline",e.innerHTML=r.invalid,i.checked=!1,i.readOnly=!1}function c(){e.style.color="#15803d",e.style.display="inline",e.innerHTML=r.valid,i.checked=!0,i.readOnly=!0}}(),(n=document.getElementById("_email_verification"))&&n.addEventListener("change",(function(e){e.preventDefault(),e.target.checked=!e.target.checked,window.open(e.target.dataset.settingsUrl,"_blank")})),(t=document.querySelector("#_company_name"))&&(t.addEventListener("blur",(function(){0===t.value.length?(t.nextElementSibling.classList.remove("hidden"),t.value=simpayAdmin.siteTitle):t.nextElementSibling.classList.add("hidden")})),t.addEventListener("focus",(function(){0!==t.value.length&&t.nextElementSibling.classList.add("hidden")})))}}))}).call(this,n(16))},342:function(e,t,n){"use strict";(function(e,t){var r=n(37),a=n.n(r),i=n(1),o=n(17),c=n(8);function s(){var e=document.getElementById("simpay-prices");if(e){var t=e.querySelectorAll(".simpay-price").length;document.querySelectorAll(".simpay-price-label-default").forEach((function(e){return e.style.display=t>1?"none":"block"})),document.querySelectorAll(".simpay-price-label-display").forEach((function(e){return e.style.display=t>1?"block":"none"})),document.querySelectorAll(".simpay-price-option-label").forEach((function(e){return e.style.display=t>1?"block":"none"})),document.querySelectorAll(".simpay-price-default-check").forEach((function(e){return e.style.display=t>1?"block":"none"}));var n=document.querySelectorAll(".simpay-panel-field-price-select");if(n.length>0){n.forEach((function(e){return e.style.display=t>1?"table-row":"none"}));var r=document.querySelector(".simpay-panel-field-price-select-notice");r&&(r.style.display=1===t?"table-row":"none")}}}function l(e){var t,n=e.querySelector(".simpay-price-label-display"),r=e.querySelector(".simpay-price-label"),a=spGeneral.strings,i=a.recurringIntervalDisplay,c=a.customAmountLabel;if(""!==r.value)t=r.value;else{var s=e.querySelector(".simpay-price-currency"),l=e.querySelector(".simpay-price-amount"),u=e.querySelector(".simpay-price-amount-type"),d=e.querySelector(".simpay-price-custom-amount input"),p=e.querySelector(".simpay-price-enable-custom-amount"),m=spGeneral.strings,f=m.currencyPosition,y=m.recurringIntervals,h=s.options[s.selectedIndex].dataset.symbol;switch(t=!0===p.checked?d.value:l.value,f){case"left":t="".concat(h).concat(t);break;case"left_space":t="".concat(h," ").concat(t);break;case"right":t="".concat(t).concat(h);break;case"right_space":t="".concat(t," ").concat(h)}if(!0===p.checked&&(t=c.replace("%s",t)),"recurring"===u.value){var v=e.querySelector(".simpay-price-recurring-interval"),g=e.querySelector(".simpay-price-recurring-interval-count"),b=y[v.options[v.selectedIndex].value];t=i.replace("%1$s",t).replace("%2$s",g.value).replace("%3$s","1"===g.value?b[0]:b[1])}}n.innerHTML=t,Object(o.c)("simpayFormBuilderPriceOptionLabelUpdated",t,e)}function u(e,t){e.querySelector(".simpay-price-recurring-settings").style.display=t.checked?"table":"none"}function d(e){var t=e.querySelector(".simpay-price-recurring-interval"),n=e.querySelector(".simpay-price-recurring-interval-count"),r=parseInt(n.value);switch(t.options[t.selectedIndex].value){case"day":r>365&&(n.value=365);break;case"week":r>52&&(n.value=52);break;case"month":r>12&&(n.value=12);break;case"year":r>1&&(n.value=1)}var i=JSON.parse(t.dataset.intervals);a()(t.options).forEach((function(e,r){var a=e.value;t.options[r].text=1===parseInt(n.value)?i[a][0]:i[a][1]}))}function p(){var e=document.querySelectorAll(".simpay-price");_.each(e,(function(e){var t=e.querySelector(".simpay-price-amount-type").value;e.querySelector(".simpay-price-label").addEventListener("keyup",(function(){return l(e)})),l(e),e.querySelector(".simpay-price-currency").addEventListener("change",(function(){!function(e){var t=e.querySelector(".simpay-price-currency"),n=t.options[t.selectedIndex].dataset.symbol,r=e.querySelectorAll(".simpay-price-currency-symbol");_.each(r,(function(e){return e.innerText=n}))}(e),l(e)}));var n=e.querySelectorAll(".simpay-price-amount-type .button");n.length>0&&_.each(n,(function(t){return t.addEventListener("click",(function(t){t.preventDefault();var n=t.target.dataset,r=n.available,a=n.upgradeTitle,i=n.upgradeDescription,o=n.upgradeUrl,s=n.upgradePurchasedUrl;"no"===r?Object(c.upgradeModal)({title:a,description:i,url:o,purchasedUrl:s}):(function(e,t){var n=e.querySelectorAll(".simpay-price-amount-type .button");_.each(n,(function(e){return e.classList.remove("button-primary")}));var r=t.dataset.amountType,a=e.querySelector(".simpay-price-recurring-settings");t.classList.add("button-primary"),a.style.display="recurring"===r?"table":"none";var i=e.querySelector(".simpay-price-recurring-amount-toggle"),o=e.querySelector(".simpay-price-enable-optional-subscription");i.style.display="recurring"===r?"none":"block",o.checked=!1,e.querySelector(".simpay-price-amount-type").value=r}(e,t.target),l(e))}))})),e.querySelector(".simpay-price-amount").addEventListener("keyup",(function(){return l(e)}));var r=e.querySelector(".simpay-price-enable-optional-subscription");r&&(r.addEventListener("click",(function(t){var n=t.target,r=n.dataset,a=r.available,i=r.upgradeTitle,o=r.upgradeDescription,s=r.upgradeUrl,d=r.upgradePurchasedUrl;"no"===a?(n.checked=!1,t.preventDefault(),Object(c.upgradeModal)({title:i,description:o,url:s,purchasedUrl:d})):(u(e,n),l(e))})),"recurring"!==t&&u(e,r)),e.querySelector(".simpay-price-enable-custom-amount").addEventListener("click",(function(){!function(e){var t=e.querySelector(".simpay-price-custom-amount");t.style.display="none"===t.style.display?"block":"none"}(e),l(e)})),e.querySelector(".simpay-price-recurring-interval").addEventListener("change",(function(){l(e),d(e)}));var a=e.querySelector(".simpay-price-recurring-interval-count");d(e),a.addEventListener("keyup",(function(){d(e),l(e)})),a.addEventListener("change",(function(){d(e),l(e)}));var i=e.querySelector(".simpay-price-legacy-setting-toggle");i&&i.addEventListener("click",(function(t){t.preventDefault(),function(e){var t=e.querySelectorAll(".simpay-price-legacy-setting");_.each(t,(function(e){return e.style.display="block"===e.style.display?"none":"block"}))}(e)})),e.querySelector(".simpay-price-default").addEventListener("change",(function(){return function(e){var t=document.querySelectorAll(".simpay-price-default");_.each(t,(function(e){return e.checked=!1})),e.querySelector(".simpay-price-default").checked=!0}(e)})),e.querySelector(".simpay-price-remove").addEventListener("click",(function(t){t.preventDefault(),function(e){e.remove(),m(),s(),Object(o.c)("simpayFormBuilderPriceRemoved",e.id)}(e)}))})),s()}function m(){var e=document.querySelectorAll(".simpay-price");document.querySelector(".simpay-price-default:checked")||(e[0].querySelector(".simpay-price-default").checked=!0)}Object(i.a)((function(){var n,r,a,i,l,u,d;t(".simpay-prices").sortable({items:".simpay-field-metabox",containment:"#simpay-prices",handle:".simpay-hndle",placeholder:"sortable-placeholder",cursor:"move",delay:t(document.body).hasClass("mobile")?200:0,distance:2,tolerance:"pointer",forcePlaceholderSize:!0,opacity:.65,helper:function(e,t){return t.clone().find(":input").attr("name",(function(e,t){return"sort_"+parseInt(1e5*Math.random(),10).toString()+"_"+t})).end()}}),p(),n=document.getElementById("simpay-prices-advanced-toggle"),r=document.getElementById("simpay-prices-advanced"),n&&r&&n.addEventListener("click",(function(e){e.preventDefault(),r.style.display="block"==r.style.display?"none":"block"})),(d=document.getElementById("simpay-prices-advanced-add"))&&d.addEventListener("click",(function(t){var n,r,a,i,o,c;t.preventDefault(),a=(r=(n=d).dataset).nonce,i=r.formId,o=document.getElementById("simpay-prices"),c=document.getElementById("simpay-prices-advanced-plan-id"),n.classList.add("disabled"),wp.ajax.send("simpay_add_plan",{data:{_wpnonce:a,form_id:i,plan_id:c.value},success:function(t){e(o).append(t),p(),document.getElementById("simpay-prices-advanced").style.display="none",c.value="",n.classList.remove("disabled"),s()},error:function(e){var t=e.message;alert(t),n.classList.remove("disabled")}})})),function(){var t=document.getElementById("simpay-add-price");t&&t.addEventListener("click",(function(n){var r,a,i,c,l;n.preventDefault(),i=(a=(r=t).dataset).nonce,c=a.formId,l=document.getElementById("simpay-prices"),r.classList.add("disabled"),wp.ajax.send("simpay_add_price",{data:{_wpnonce:i,form_id:c},success:function(t){e(l).append(t),p(),m(),r.classList.remove("disabled"),s(),Object(o.c)("simpayFormBuilderPriceAdded",t)},error:function(e){var t=e.message;alert(t),r.classList.remove("disabled")}})}))}(),(a=document.getElementById("simpay-add-price-lite"))&&a.addEventListener("click",c.maybeBlockButtonWithUpgradeModal),(i=document.getElementById("simpay-amount-type-lite"))&&i.addEventListener("click",c.maybeBlockButtonWithUpgradeModal),(l=document.getElementById("simpay-can-recur-lite"))&&l.addEventListener("click",c.maybeBlockButtonWithUpgradeModal),(u=document.getElementById("simpay-custom-lite"))&&u.addEventListener("click",c.maybeBlockButtonWithUpgradeModal)}))}).call(this,n(16),n(16))},343:function(e,t,n){"use strict";(function(e){var t=n(1),r=n(8);Object(t.a)((function(){var t,n,a;(t=document.querySelector('[name="_enable_payment_page"]'))&&t.addEventListener("change",r.maybeBlockCheckboxWithUpgradeModal),(n=document.querySelector('[name="_payment_page_powered_by"]'))&&n.addEventListener("change",r.maybeBlockCheckboxWithUpgradeModal),function(){if(document.getElementById("payment-page-background-color-custom")){e("#payment-page-background-color-custom").wpColorPicker();var t=document.querySelector(".simpay-payment-page-background-color .wp-color-result"),n=document.querySelectorAll(".simpay-payment-page-background-color");t.addEventListener("click",(function(t){n.forEach((function(e){e.querySelector("input").checked=!1})),t.target.classList.add("is-selected"),e(t.target).parent().find("input").prop("checked",!0)})),n.forEach((function(e){e.querySelector("input").addEventListener("change",(function(){t.classList.remove("is-selected")}))}))}}(),(a=document.querySelector('[name="_payment_page_slug"]'))&&a.addEventListener("keyup",(function(e){var t=document.querySelector(".simpay-payment-page-url");t&&(t.dataset.clipboardText="".concat(window.location.origin,"/").concat(e.target.value))}))}))}).call(this,n(16))},344:function(e,t,n){"use strict";(function(e){var t=n(20),r=n.n(t),a=n(1),i='',o='',c=simpayAdmin,s=c.nonce,l=c.ajaxUrl,u=c.i18n,d=u.addonActivated,p=u.addonActivate,m=u.addonActive,f=u.addonDeactivate,y=u.addonInactive,h=u.addonInstall,v=u.addonError,g=u.pluginError;function b(t){t.preventDefault();var n,a,c,u,b,_,k=e(t.target);if(k.hasClass("status-go-to-url"))window.open(k.attr("data-plugin"),"_blank");else{var w=k.attr("data-type");if(k.prop("disabled",!0).addClass("loading"),k.html(''),k.hasClass("status-active"))n="deactivate",a="status-installed","plugin"===w&&(a+=" button button-secondary"),c=y,u=p,b=f,"addon"===w&&(u=i+u,b=o+b);else if(k.hasClass("status-installed"))n="activate",a="status-active","plugin"===w&&(a+=" button button-secondary disabled"),c=m,u=f,"addon"===w?(u=o+u,b=i+p):"plugin"===w&&(u=d,b=p);else{if(!k.hasClass("status-missing"))return;n="install",a="status-active","plugin"===w&&(a+=" button disabled"),c=m,u=d,b='',"addon"===w&&(u=i+f,b+=h)}var E=k.closest(".simpay-addon");!function(t,n,r,a){var i={activate:"simpay_activate_addon",install:"simpay_install_addon",deactivate:"simpay_deactivate_addon"}[n];if(i){var o={action:i,nonce:s,plugin:t,type:r};e.post(l,o,a).fail((function(e){console.log(e.responseText)}))}}(k.attr("data-plugin"),n,w,(function(e){e.success?("install"===n?(k.attr("data-plugin",e.data.basename),_=e.data.msg,e.data.is_activated||(c=y,u="plugin"===w?p:i+p,a="plugin"===w?"status-installed button button-secondary":"status-installed")):_=e.data,E.find(".simpay-addon__actions").append('
'+_+"
"),E.find("span.status-label").removeClass("status-active status-installed status-missing").addClass(a).removeClass("button button-primary button-secondary disabled").text(c),k.removeClass("status-active status-installed status-missing").removeClass("button button-primary button-secondary disabled").addClass(a).html(u)):("object"===r()(e.data)?"addon"===w?E.find(".simpay-addon__actions").append('
'+v+"
"):E.find(".simpay-addon__actions").append('
'+g+"
"):E.find(".simpay-addon__actions").append('
'+e.data+"
"),"install"===n&&"plugin"===w&&k.addClass("status-go-to-url").removeClass("status-missing"),k.html(b)),k.prop("disabled",!1).removeClass("loading"),setTimeout((function(){E.find(".msg").remove()}),3e3)}))}}Object(a.a)((function(){document.querySelector(".simpay-addons")&&document.querySelectorAll(".simpay-addon").forEach((function(e){e.querySelector("button").addEventListener("click",b)}))}))}).call(this,n(16))},345:function(e,t,n){"use strict";var r=n(1);Object(r.a)((function(){var e=new ClipboardJS(".simpay-copy-button");e.on("success",(function(t){var n=t.trigger,r=n.dataset.copied,a=n.innerHTML;clearTimeout(i),n.innerHTML=r,n.classList.contains("button-secondary")&&(n.style.color="green",n.style.borderColor="green"),t.clearSelection();var i=setTimeout((function(){n.innerHTML=a,n.classList.contains("button-secondary")&&(n.style.color="",n.style.borderColor=""),e.clipboardAction.fakeElem&&e.clipboardAction.removeFake&&e.clipboardAction.removeFake()}),3e3);wp.a11y.speak(r)}))}))},359:function(e,t,n){"use strict";n(341),n(342);var r=n(37),a=n.n(r),i=n(1),o=n(8);function c(e){var t=e.target,n=t.options[t.selectedIndex].value,r=document.querySelectorAll(".simpay-panel-field-payment-method[data-payment-method]");a()(r).forEach((function(e){var t="popular"===JSON.parse(e.dataset.paymentMethod).scope?"block":"none";e.style.display="all"===n?"block":t}))}Object(i.a)((function(){var e=document.querySelectorAll(".simpay-panel-field-payment-method-filter");0!==e.length&&a()(e).forEach((function(e){e.addEventListener("change",c)}));var t=document.querySelectorAll(".simpay-payment-method-lite");t&&t.forEach((function(e){return e.addEventListener("change",o.maybeBlockCheckboxWithUpgradeModal)}))})),Object(i.a)((function(){var e=document.getElementById("_tax_status_lite");e&&e.addEventListener("change",o.maybeBlockSelectWithUpgradeModal)})),Object(i.a)((function(){var e;document.querySelector(".post-type-simple-pay #post")&&(e=document.getElementById("simpay-add-field-lite"))&&e.addEventListener("click",o.maybeBlockButtonWithUpgradeModal)})),Object(i.a)((function(){var e,t;(e=document.getElementById("_enable_tax_id"))&&e.addEventListener("change",o.maybeBlockCheckboxWithUpgradeModal),(t=document.getElementById("_enable_promotion_codes"))&&t.addEventListener("change",o.maybeBlockCheckboxWithUpgradeModal)})),n(343),Object(i.a)((function(){var e=document.getElementById("_inventory");e&&e.addEventListener("change",o.maybeBlockCheckboxWithUpgradeModal);var t=document.getElementById("_inventory_behavior_individual");t&&t.addEventListener("change",o.maybeBlockCheckboxWithUpgradeModal);var n=document.getElementById("_schedule_start");n&&n.addEventListener("change",o.maybeBlockCheckboxWithUpgradeModal);var r=document.getElementById("_schedule_end");r&&r.addEventListener("change",o.maybeBlockCheckboxWithUpgradeModal)}))},37:function(e,t,n){var r=n(109),a=n(110),i=n(111),o=n(112);e.exports=function(e){return r(e)||a(e)||i(e)||o()},e.exports.__esModule=!0,e.exports.default=e.exports},59:function(e,t,n){"use strict";n.d(t,"a",(function(){return r})),n.d(t,"b",(function(){return a}));var r={};n.r(r),n.d(r,"create",(function(){return p}));var a={};n.r(a),n.d(a,"create",(function(){return y}));var i=n(2),o=n(3),c=n.n(o),s=n(10),l=n.n(s);function u(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function d(e){for(var t=1;t0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0,n=t.id,r=t.getFormData;return Object(i.a)("v2/customer",d({form_values:l()(t[0],{hash:!0}),form_data:r(),form_id:n},e))}function m(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function f(e){for(var t=1;t0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0,n=t.id,r=t.getFormData;return Object(i.a)("v2/checkout-session",f({form_values:l()(t[0],{hash:!0}),form_data:r(),form_id:n},e))}n(19),n(11),n(33)},65:function(e,t,n){var r=function(e){"use strict";var t=Object.prototype,n=t.hasOwnProperty,r="function"==typeof Symbol?Symbol:{},a=r.iterator||"@@iterator",i=r.asyncIterator||"@@asyncIterator",o=r.toStringTag||"@@toStringTag";function c(e,t,n){return Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{c({},"")}catch(e){c=function(e,t,n){return e[t]=n}}function s(e,t,n,r){var a=t&&t.prototype instanceof d?t:d,i=Object.create(a.prototype),o=new E(r||[]);return i._invoke=function(e,t,n){var r="suspendedStart";return function(a,i){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===a)throw i;return{value:void 0,done:!0}}for(n.method=a,n.arg=i;;){var o=n.delegate;if(o){var c=_(o,n);if(c){if(c===u)continue;return c}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if("suspendedStart"===r)throw r="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";var s=l(e,t,n);if("normal"===s.type){if(r=n.done?"completed":"suspendedYield",s.arg===u)continue;return{value:s.arg,done:n.done}}"throw"===s.type&&(r="completed",n.method="throw",n.arg=s.arg)}}}(e,n,o),i}function l(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(e){return{type:"throw",arg:e}}}e.wrap=s;var u={};function d(){}function p(){}function m(){}var f={};c(f,a,(function(){return this}));var y=Object.getPrototypeOf,h=y&&y(y(x([])));h&&h!==t&&n.call(h,a)&&(f=h);var v=m.prototype=d.prototype=Object.create(f);function g(e){["next","throw","return"].forEach((function(t){c(e,t,(function(e){return this._invoke(t,e)}))}))}function b(e,t){var r;this._invoke=function(a,i){function o(){return new t((function(r,o){!function r(a,i,o,c){var s=l(e[a],e,i);if("throw"!==s.type){var u=s.arg,d=u.value;return d&&"object"==typeof d&&n.call(d,"__await")?t.resolve(d.__await).then((function(e){r("next",e,o,c)}),(function(e){r("throw",e,o,c)})):t.resolve(d).then((function(e){u.value=e,o(u)}),(function(e){return r("throw",e,o,c)}))}c(s.arg)}(a,i,r,o)}))}return r=r?r.then(o,o):o()}}function _(e,t){var n=e.iterator[t.method];if(void 0===n){if(t.delegate=null,"throw"===t.method){if(e.iterator.return&&(t.method="return",t.arg=void 0,_(e,t),"throw"===t.method))return u;t.method="throw",t.arg=new TypeError("The iterator does not provide a 'throw' method")}return u}var r=l(n,e.iterator,t.arg);if("throw"===r.type)return t.method="throw",t.arg=r.arg,t.delegate=null,u;var a=r.arg;return a?a.done?(t[e.resultName]=a.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=void 0),t.delegate=null,u):a:(t.method="throw",t.arg=new TypeError("iterator result is not an object"),t.delegate=null,u)}function k(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function w(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function E(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(k,this),this.reset(!0)}function x(e){if(e){var t=e[a];if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,i=function t(){for(;++r=0;--a){var i=this.tryEntries[a],o=i.completion;if("root"===i.tryLoc)return r("end");if(i.tryLoc<=this.prev){var c=n.call(i,"catchLoc"),s=n.call(i,"finallyLoc");if(c&&s){if(this.prev=0;--r){var a=this.tryEntries[r];if(a.tryLoc<=this.prev&&n.call(a,"finallyLoc")&&this.prev=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),w(n),u}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var a=r.arg;w(n)}return a}}throw new Error("illegal catch attempt")},delegateYield:function(e,t,n){return this.delegate={iterator:x(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=void 0),u}},e}(e.exports);try{regeneratorRuntime=r}catch(e){"object"==typeof globalThis?globalThis.regeneratorRuntime=r:Function("r","regeneratorRuntime = r")(r)}},66:function(e,t){e.exports=function(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n array('wp-block-editor', 'wp-components', 'wp-compose', 'wp-element', 'wp-hooks', 'wp-i18n', 'wp-primitives'), 'version' => 'de9006acd89102bba9d52f321a0d6d9c'); \ No newline at end of file + array('wp-block-editor', 'wp-components', 'wp-compose', 'wp-element', 'wp-hooks', 'wp-i18n', 'wp-primitives'), 'version' => '34d9f2cd400c0c6dd154f0b1e8221352'); \ No newline at end of file diff --git a/includes/core/assets/js/simpay-block-button.min.js b/includes/core/assets/js/simpay-block-button.min.js index b0339fab..aeec0d29 100644 --- a/includes/core/assets/js/simpay-block-button.min.js +++ b/includes/core/assets/js/simpay-block-button.min.js @@ -1 +1 @@ -!function(e){var t={};function r(n){if(t[n])return t[n].exports;var o=t[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,r),o.l=!0,o.exports}r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)r.d(n,o,function(t){return e[t]}.bind(null,o));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=72)}({0:function(e,t){e.exports=window.wp.element},11:function(e,t){e.exports=window.wp.compose},13:function(e,t){e.exports=function(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e},e.exports.__esModule=!0,e.exports.default=e.exports},15:function(e,t){e.exports=function(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);re.length)&&(t=e.length);for(var r=0,n=new Array(t);r array('wp-block-editor', 'wp-blocks', 'wp-components', 'wp-data', 'wp-element', 'wp-i18n', 'wp-primitives', 'wp-server-side-render'), 'version' => 'eaa221cf4a013fd95bfa223f2de2ee6e'); \ No newline at end of file + array('wp-block-editor', 'wp-blocks', 'wp-components', 'wp-data', 'wp-element', 'wp-i18n', 'wp-primitives', 'wp-server-side-render'), 'version' => 'c71f62fbfd5c319d08ad00da7d3c350a'); \ No newline at end of file diff --git a/includes/core/assets/js/simpay-block-payment-form.min.js b/includes/core/assets/js/simpay-block-payment-form.min.js index be7400fd..50260dbb 100644 --- a/includes/core/assets/js/simpay-block-payment-form.min.js +++ b/includes/core/assets/js/simpay-block-payment-form.min.js @@ -1 +1 @@ -!function(e){var t={};function r(n){if(t[n])return t[n].exports;var o=t[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,r),o.l=!0,o.exports}r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)r.d(n,o,function(t){return e[t]}.bind(null,o));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=71)}([function(e,t){e.exports=window.wp.element},,function(e,t){e.exports=window.wp.i18n},function(e,t){e.exports=window.wp.components},,function(e,t,r){var n=r(20),o=r(21),i=r(16),c=r(22);e.exports=function(e,t){return n(e)||o(e,t)||i(e,t)||c()},e.exports.__esModule=!0,e.exports.default=e.exports},function(e,t){e.exports=window.wp.primitives},,,,,,function(e,t){e.exports=window.wp.data},,,function(e,t){e.exports=function(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);re.length)&&(t=e.length);for(var r=0,n=new Array(t);r defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG, ); + // phpcs:disable WordPress.Arrays.MultipleStatementAlignment.DoubleArrowNotAligned $strings['strings'] = array( - 'currency' => simpay_get_setting( 'currency', 'USD' ), - 'currencySymbol' => html_entity_decode( + 'currency' => simpay_get_setting( 'currency', 'USD' ), + 'currencySymbol' => html_entity_decode( simpay_get_saved_currency_symbol() ), - 'currencyPosition' => simpay_get_currency_position(), - 'decimalSeparator' => simpay_get_decimal_separator(), - 'thousandSeparator' => simpay_get_thousand_separator(), - 'ajaxurl' => admin_url( 'admin-ajax.php' ), + 'currencyPosition' => simpay_get_currency_position(), + 'decimalSeparator' => simpay_get_decimal_separator(), + 'thousandSeparator' => simpay_get_thousand_separator(), + 'ajaxurl' => admin_url( 'admin-ajax.php' ), /* translators: Minimum payment amount. */ - 'customAmountLabel' => esc_html__( - 'starting at %s', - 'stripe' - ), - 'recurringIntervals' => simpay_get_recurring_intervals(), + 'customAmountLabel' => esc_html__( 'starting at %s', 'stripe' ), + 'recurringIntervals' => simpay_get_recurring_intervals(), /* translators: %1$s Recurring amount. %2$s Recurring interval count. %3$s Recurring interval. */ - 'recurringIntervalDisplay' => esc_html_x( + 'recurringIntervalDisplay' => esc_html_x( '%1$s every %2$s %3$s', 'recurring interval', 'stripe' ), /* translators: %1$s Recurring amount. %2$s Recurring interval count -- not output when 1. %3$s Recurring interval. %4$s Limited discount interval count. %5$s Recurring amount without discount. */ - 'recurringIntervalDisplayLimitedDiscount' => esc_html_x( + 'recurringIntervalDisplayLimitedDiscount' => esc_html_x( '%1$s every %2$s %3$s for %4$s months then %5$s', 'recurring interval', 'stripe' @@ -565,15 +563,28 @@ function simpay_shared_script_variables() { 'recurring interval with automatic tax', 'stripe' ), - 'addressRequired' => esc_html__( + /* translators: %1$s Invoice limit. %2$s Recurring interval count -- not output when 1. %3$s Recurring interval. %4$s Recurring amount limit */ + 'recurringIntervalDisplayInvoiceLimit' => esc_html_x( + '%1$d payments of %2$s every %3$s %4$s', + 'recurring interval', + 'stripe' + ), + /* translators: %1$s Invoice limit. %2$s Recurring interval count -- not output when 1. %3$s Recurring interval. %4$s Recurring amount */ + 'recurringIntervalDisplayInvoiceLimitWithCoupon' => esc_html_x( + '%1$d payments of %2$s (for the duration of the coupon) every %3$s %4$s', + 'recurring interval', + 'stripe' + ), + 'addressRequired' => esc_html__( 'Enter address to calculate', 'stripe' ), - 'addressInvalid' => esc_html__( + 'addressInvalid' => esc_html__( 'Please enter a valid address', 'stripe' ), ); + // phpcs:enable WordPress.Arrays.MultipleStatementAlignment.DoubleArrowNotAligned $i18n['i18n'] = array( 'mediaTitle' => esc_html__( 'Insert Media', 'stripe' ), @@ -1375,14 +1386,13 @@ function simpay_get_payment_form_setting( } /** - * Returns the nicename of a payment form template category. + * Returns a list of category slugs and nicenames. * - * @since 4.4.4 + * @since 4.6.5 * - * @param string $category_slug Category slug. - * @return string + * @return array */ -function __unstable_simpay_get_form_template_category_name( $category_slug ) { +function __unstable_simpay_get_form_template_categories() { $categories = array( 'business-operations' => __( 'Business Operations', 'stripe' ), 'donations' => __( 'Donations', 'stripe' ), @@ -1392,6 +1402,29 @@ function __unstable_simpay_get_form_template_category_name( $category_slug ) { 'features-functionality' => __( 'Features / Functionality', 'stripe' ), ); + if ( __unstable_simpay_has_new_form_templates() ) { + $categories = array_merge( + array( + 'new' => __( 'Recently Added', 'stripe' ), + ), + $categories + ); + } + + return $categories; +} + +/** + * Returns the nicename of a payment form template category. + * + * @since 4.4.4 + * + * @param string $category_slug Category slug. + * @return string + */ +function __unstable_simpay_get_form_template_category_name( $category_slug ) { + $categories = __unstable_simpay_get_form_template_categories(); + return isset( $categories[ $category_slug ] ) ? $categories[ $category_slug ] : $category_slug; @@ -1405,16 +1438,19 @@ function __unstable_simpay_get_form_template_category_name( $category_slug ) { * @return array */ function __unstable_simpay_get_payment_form_templates() { + static $templates = array(); + + if ( ! empty( $templates ) ) { + return $templates; + } + $template_files = glob( SIMPLE_PAY_DIR . '/data/templates/*.json' ); if ( false === $template_files ) { return array(); } - $templates = array(); - $currency = strtolower( - simpay_get_setting( 'currency', 'USD' ) - ); + $currency = strtolower( simpay_get_setting( 'currency', 'USD' ) ); foreach ( $template_files as $template_file ) { $data = json_decode( file_get_contents( $template_file ), true ); @@ -1424,6 +1460,11 @@ function __unstable_simpay_get_payment_form_templates() { continue; } + $is_new = ( + isset( $data['created_at'] ) && + strtotime( $data['created_at'] ) > strtotime( '-2 weeks' ) + ); + // Adjust licenses if needed. // Templates that utilize "enhanced" subscription functionality should only continue to be available // for "Plus" license holders if they have been grandfathered in. @@ -1447,16 +1488,8 @@ function __unstable_simpay_get_payment_form_templates() { } // Pull category names. - if ( isset( $data['categories'] ) ) { - $categories = $data['categories']; - $data['categories'] = array(); - - foreach ( $categories as $category_slug ) { - $data['categories'][ $category_slug ] = - __unstable_simpay_get_form_template_category_name( - $category_slug - ); - } + if ( isset( $data['categories'] ) && $is_new ) { + $data['categories'][] = 'new'; } // Use the store currency if one is not set. @@ -1517,6 +1550,29 @@ function __unstable_simpay_get_payment_form_template( $id ) { return empty( $template ) ? null : current( $template ); } +/** + * Determines if we have newly added templates available. + * + * @since 4.6.5 + * + * @return bool True if a template was added within the last two weeks. + */ +function __unstable_simpay_has_new_form_templates() { + $templates = __unstable_simpay_get_payment_form_templates(); + + $new = array_filter( + $templates, + function( $template_data ) { + return ( + isset( $template_data['created_at'] ) && + strtotime( $template_data['created_at'] ) > strtotime( '-2 weeks' ) + ); + } + ); + + return ! empty( $new ); +} + /** * Returns an list of payment form titles keyed by ID. * diff --git a/includes/core/payments/payment-confirmation.php b/includes/core/payments/payment-confirmation.php index 64e07d42..7f626b0f 100644 --- a/includes/core/payments/payment-confirmation.php +++ b/includes/core/payments/payment-confirmation.php @@ -67,11 +67,11 @@ function do_confirmation_actions( $payment_confirmation_data ) { $_GET ); - if ( ! empty( $payment_confirmation_data[ 'paymentintents' ] ) ) { - $objects = $payment_confirmation_data[ 'paymentintents' ]; + if ( ! empty( $payment_confirmation_data['paymentintents'] ) ) { + $objects = $payment_confirmation_data['paymentintents']; $object_type = 'payment_intent'; } else { - $objects = $payment_confirmation_data[ 'subscriptions' ]; + $objects = $payment_confirmation_data['subscriptions']; $object_type = 'subscription'; } @@ -102,11 +102,19 @@ function do_confirmation_actions( $payment_confirmation_data ) { switch ( $object_type ) { case 'payment_intent': - API\PaymentIntents\update( $object->id, $update ); + API\PaymentIntents\update( + $object->id, + $update, + $payment_confirmation_data['form']->get_api_request_args() + ); break; case 'subscription': - API\Subscriptions\update( $object->id, $update ); + API\Subscriptions\update( + $object->id, + $update, + $payment_confirmation_data['form']->get_api_request_args() + ); break; } @@ -276,8 +284,8 @@ function get_confirmation_data( $customer_id = false, $session_id = false, $form * @return string */ function get_one_time_amount_message_default() { - $license = simpay_get_license(); - $is_lite = $license->is_lite(); + $license = simpay_get_license(); + $is_lite = $license->is_lite(); $has_email = false; if ( false === $is_lite ) { diff --git a/includes/core/post-types/simple-pay/actions.php b/includes/core/post-types/simple-pay/actions.php index 5d17434b..59af3cfd 100644 --- a/includes/core/post-types/simple-pay/actions.php +++ b/includes/core/post-types/simple-pay/actions.php @@ -220,9 +220,10 @@ function save_product( $post_id, $post, $form ) { $title = get_post_meta( $form->id, '_company_name', true ); $name = ! empty( $title ) ? $title : get_bloginfo( 'name' ); - // https://github.com/wpsimplepay/wp-simple-pay-pro/issues/1598 + // https://github.com/wpsimplepay/wp-simple-pay-pro/issues/1598. if ( empty( $name ) ) { $name = sprintf( + /* translators: %d: Payment Form ID. */ __( 'WP Simple Pay - Form %d', 'stripe' ), $form->id ); @@ -244,7 +245,7 @@ function save_product( $post_id, $post, $form ) { $tax_status = get_post_meta( $form->id, '_tax_status', true ); if ( 'automatic' === $tax_status ) { - $tax_code = get_post_meta( $form->id, '_tax_code', true ); + $tax_code = get_post_meta( $form->id, '_tax_code', true ); $product_args['tax_code'] = $tax_code; } @@ -511,21 +512,44 @@ function save_prices( $post_id, $post, $form ) { if ( 'automatic' === $tax_status ) { try { + $tax_behavior = get_post_meta( + $form->id, + '_tax_behavior', + true + ); + $existing_price = API\Prices\retrieve( $price_args['id'], $form->get_api_request_args() ); - if ( 'unspecified' === $existing_price->tax_behavior ) { - $tax_behavior = get_post_meta( - $form->id, - '_tax_behavior', - true + if ( + 'unspecified' === $existing_price->tax_behavior && + ! empty( $tax_behavior ) + ) { + API\Prices\update( + $price_args['id'], + array( + 'tax_behavior' => $tax_behavior, + ), + $form->get_api_request_args() + ); + } + + // Also update recurring, if needed. + if ( + ! empty( $recurring_args ) && + ! empty( $recurring_args['id'] ) && + ! empty( $tax_behavior ) + ) { + $recurring_price = API\Prices\retrieve( + $recurring_args['id'], + $form->get_api_request_args() ); - if ( ! empty( $tax_behavior ) ) { + if ( 'unspecified' === $recurring_price->tax_behavior ) { API\Prices\update( - $price_args['id'], + $recurring_args['id'], array( 'tax_behavior' => $tax_behavior, ), @@ -580,7 +604,7 @@ function save_prices( $post_id, $post, $form ) { array_merge( $stripe_price_args, array( - 'recurring' => array( + 'recurring' => array( 'interval' => $recurring_args['interval'], 'interval_count' => @@ -752,7 +776,7 @@ function duplicate() { delete_post_meta( $duplicate, '_simpay_product_live' ); delete_post_meta( $duplicate, '_simpay_product_test' ); - // Update form title to append - Duplicate + // Update form title to append - Duplicate. $form_name = get_post_meta( $duplicate, '_company_name', true ); update_post_meta( $duplicate, diff --git a/includes/core/post-types/simple-pay/edit-form-custom-fields.php b/includes/core/post-types/simple-pay/edit-form-custom-fields.php index 8162d6f3..81ba5b09 100644 --- a/includes/core/post-types/simple-pay/edit-form-custom-fields.php +++ b/includes/core/post-types/simple-pay/edit-form-custom-fields.php @@ -120,7 +120,7 @@ function get_custom_field_types() { 'repeatable' => true, ), 'payment_request_button' => array( - 'label' => esc_html__( 'Apple Pay/Google Pay Button', 'stripe' ), + 'label' => esc_html__( '1-Click Payment Button (Apple Pay / Google Pay)', 'stripe' ), 'type' => 'payment_request_button', 'category' => 'payment', 'active' => simpay_can_use_payment_request_button(), diff --git a/includes/core/post-types/simple-pay/list-table.php b/includes/core/post-types/simple-pay/list-table.php index bd44d194..976f2b46 100644 --- a/includes/core/post-types/simple-pay/list-table.php +++ b/includes/core/post-types/simple-pay/list-table.php @@ -37,7 +37,7 @@ function remove_edit_from_bulk_actions( $actions ) { * * @since 4.1.0 * - * @param string $title post_title Post title + * @param string $title post_title Post title. * @param int $post_id ID Post ID. * @return string */ @@ -310,8 +310,8 @@ function search_metadata( $where ) { // Find the existing search WHERE and add an additional OR for meta_value. $where = preg_replace( - "/\(\s*" . $wpdb->posts . ".post_title\s+LIKE\s*(\'[^\']+\')\s*\)/", - "(" . $wpdb->posts . ".post_title LIKE $1) OR (" . $wpdb->postmeta . ".meta_value LIKE $1)", + '/\(\s*' . $wpdb->posts . ".post_title\s+LIKE\s*(\'[^\']+\')\s*\)/", + '(' . $wpdb->posts . '.post_title LIKE $1) OR (' . $wpdb->postmeta . '.meta_value LIKE $1)', $where ); @@ -320,3 +320,37 @@ function search_metadata( $where ) { return $where; } add_filter( 'posts_where', __NAMESPACE__ . '\\search_metadata' ); + +/** + * Ensures proper sort order when sorting payment forms by "Title". + * + * Payment forms do not use the `post_title` column for their title, so we need + * to adjust the query to sort by the `_company_name` meta instead. + * + * @since 4.6.5 + * + * @param \WP_Query $query The current \WP_Query object. + * @return void + */ +function sort_by_title( $query ) { + if ( ! is_admin() ) { + return; + } + + if ( + ! $query->get( 'post_type' ) || + 'simple-pay' !== $query->get( 'post_type' ) + ) { + return; + } + + $orderby = $query->get( 'orderby' ); + + if ( 'title' !== $orderby ) { + return; + } + + $query->set( 'meta_key', '_company_name' ); + $query->set( 'orderby', 'meta_value' ); +} +add_filter( 'pre_get_posts', __NAMESPACE__ . '\\sort_by_title' ); diff --git a/includes/core/post-types/simple-pay/menu.php b/includes/core/post-types/simple-pay/menu.php index 9a225eac..3c2064c1 100644 --- a/includes/core/post-types/simple-pay/menu.php +++ b/includes/core/post-types/simple-pay/menu.php @@ -40,7 +40,8 @@ function add_items() { $settings_menu_name, 'manage_options', 'simpay_settings', - 'SimplePay\\Core\\Settings\\page' + 'SimplePay\\Core\\Settings\\page', + 9 ); /** diff --git a/includes/core/settings/register-payment-confirmations.php b/includes/core/settings/register-payment-confirmations.php index 2d743f08..2a410995 100644 --- a/includes/core/settings/register-payment-confirmations.php +++ b/includes/core/settings/register-payment-confirmations.php @@ -22,6 +22,22 @@ exit; } +/** + * Removes TinyMCE Media Buttons. + * + * This is required because some TinyMCE buttons are not functional on our edit payment confirmation pages. + * + * @since 4.6.5 + * + * @return void + */ +function remove_extra_media_buttons() { + remove_all_actions( 'media_buttons' ); + add_filter( 'wpforms_display_media_button', '__return_false' ); + add_action( 'media_buttons', 'media_buttons' ); +} +add_action( 'simpay_admin_page_settings_display_start', __NAMESPACE__ . '\\remove_extra_media_buttons' ); + /** * Registers the settings section. * diff --git a/includes/core/settings/register-stripe.php b/includes/core/settings/register-stripe.php index 9849ead3..1250602c 100644 --- a/includes/core/settings/register-stripe.php +++ b/includes/core/settings/register-stripe.php @@ -236,13 +236,13 @@ function register_account_settings( $settings ) { 'section' => 'stripe', 'subsection' => 'account', 'label' => esc_html_x( - 'Test Mode', + 'Payment Mode', 'setting label', 'stripe' ), 'options' => array( - 'enabled' => esc_html_x( 'Enabled', 'setting label', 'stripe' ), - 'disabled' => esc_html_x( 'Disabled', 'setting label', 'stripe' ), + 'enabled' => esc_html_x( 'Test Mode', 'setting label', 'stripe' ), + 'disabled' => esc_html_x( 'Live Mode', 'setting label', 'stripe' ), ), 'value' => simpay_get_setting( 'test_mode', 'enabled' ), 'description' => wpautop( diff --git a/includes/core/utils/class-rate-limiting.php b/includes/core/utils/class-rate-limiting.php index b320f1ba..f79eb979 100644 --- a/includes/core/utils/class-rate-limiting.php +++ b/includes/core/utils/class-rate-limiting.php @@ -307,9 +307,7 @@ public function rate_limiting_enabled() { * @return string */ public function get_rate_limit_id() { - $id = isset( $_COOKIE['__stripe_mid'] ) - ? sanitize_text_field( $_COOKIE['__stripe_mid'] ) - : get_current_ip_address(); + $id = get_current_ip_address(); /** * Filters the rate limiting tracking ID. diff --git a/src/Admin/AdminPageSubscriber.php b/src/Admin/AdminPageSubscriber.php index bcac328b..acce6a1e 100644 --- a/src/Admin/AdminPageSubscriber.php +++ b/src/Admin/AdminPageSubscriber.php @@ -52,7 +52,7 @@ public function __construct( $pages ) { */ public function get_subscribed_events() { return array( - 'admin_menu' => 'add_menu_pages', + 'admin_menu' => array( 'add_menu_pages', 20 ), 'admin_head' => 'set_block_editor_body_class', ); } diff --git a/src/Admin/AdminServiceProvider.php b/src/Admin/AdminServiceProvider.php index 3aef7b72..02e18aae 100644 --- a/src/Admin/AdminServiceProvider.php +++ b/src/Admin/AdminServiceProvider.php @@ -33,6 +33,7 @@ public function get_services() { 'admin-page-system-report', 'admin-page-about-us', 'admin-page-setup-wizard', + 'admin-page-form-templates', 'admin-notice-update-available', 'admin-notice-five-star-rating', 'admin-notice-license-upgrade-top-of-page', @@ -105,10 +106,20 @@ private function get_pages() { AdminPage\AboutUsPage::class ); + // Form templates. + $container->share( + 'admin-page-form-templates', + AdminPage\FormTemplatesPage::class + ) + ->withArgument( + $container->get( 'form-builder-template-explorer' ) + ); + $pages = array( $container->get( 'admin-page-setup-wizard' ), $container->get( 'admin-page-system-report' ), $container->get( 'admin-page-about-us' ), + $container->get( 'admin-page-form-templates' ), ); // Add notification inbox page if notifications are being used. diff --git a/src/Admin/Education/PluginCouponMenuItem.php b/src/Admin/Education/PluginCouponMenuItem.php index 7eb7e97e..0fcde3ec 100644 --- a/src/Admin/Education/PluginCouponMenuItem.php +++ b/src/Admin/Education/PluginCouponMenuItem.php @@ -29,7 +29,7 @@ public function get_subscribed_events() { } return array( - 'admin_menu' => array( 'menu_item', 0 ), + 'admin_menu' => 'menu_item', ); } @@ -47,7 +47,8 @@ public function menu_item() { __( 'Coupons', 'stripe' ), 'manage_options', 'simpay_coupons', - array( $this, 'upsell' ) + array( $this, 'upsell' ), + 5 ); } diff --git a/src/Admin/FormBuilder/TemplateExplorer.php b/src/Admin/FormBuilder/TemplateExplorer.php index a0313464..b8f6c373 100644 --- a/src/Admin/FormBuilder/TemplateExplorer.php +++ b/src/Admin/FormBuilder/TemplateExplorer.php @@ -146,6 +146,17 @@ public function maybe_show_template_explorer( $post ) { return; } + $this->render(); + } + + /** + * Renders the template explorer. + * + * @since 4.6.5 + * + * @return void + */ + public function render() { $asset_file = SIMPLE_PAY_INC . '/core/assets/js/simpay-admin-form-template-explorer.min.asset.php'; // @phpstan-ignore-line if ( ! file_exists( $asset_file ) ) { @@ -200,6 +211,16 @@ public function maybe_show_template_explorer( $post ) { 'template-explorer', true ), + 'hasNew' => ( + isset( $_GET['page'] ) && + __unstable_simpay_has_new_form_templates() + ), + 'categories' => array_merge( + array( + '' => esc_html__( 'All Templates', 'stripe' ), + ), + __unstable_simpay_get_form_template_categories() + ), 'templates' => array_values( __unstable_simpay_get_payment_form_templates() ), diff --git a/src/AdminPage/AboutUsPage.php b/src/AdminPage/AboutUsPage.php index 1fb1fc23..c120b3eb 100644 --- a/src/AdminPage/AboutUsPage.php +++ b/src/AdminPage/AboutUsPage.php @@ -27,7 +27,7 @@ class AboutUsPage extends AbstractAdminPage implements AdminSecondaryPageInterfa * {@inheritdoc} */ public function get_position() { - return 99; + return 7; } /** diff --git a/src/AdminPage/FormTemplatesPage.php b/src/AdminPage/FormTemplatesPage.php new file mode 100644 index 00000000..5102c62d --- /dev/null +++ b/src/AdminPage/FormTemplatesPage.php @@ -0,0 +1,123 @@ +template_explorer = $template_explorer; + } + + /** + * {@inheritdoc} + */ + public function get_position() { + return 3; + } + + /** + * {@inheritdoc} + */ + public function get_capability_requirement() { + return 'manage_options'; + } + + /** + * {@inheritdoc} + */ + public function get_menu_title() { + $has_new = __unstable_simpay_has_new_form_templates(); + + return sprintf( + '%s %s', + __( 'Form Templates', 'stripe' ), + $has_new + ? sprintf( + '%s', + esc_html__( 'New!', 'stripe' ) + ) + : '' + ); + } + + /** + * {@inheritdoc} + */ + public function get_page_title() { + return __( 'Form Templates', 'stripe' ); + } + + /** + * {@inheritdoc} + */ + public function get_page_slug() { + return 'simpay_form_templates'; + } + + /** + * {@inheritdoc} + */ + public function get_parent_slug() { + return 'edit.php?post_type=simple-pay'; + } + + /** + * {@inheritdoc} + */ + public function is_block_editor() { + return false; + } + + /** + * {@inheritdoc} + */ + public function render() { + ?> + +
+

+ +

+
+ + template_explorer->render(); ?> +
+ + get_fraud_event_count() >= $this->get_fraud_event_threshold() && $this->is_latest_fraud_event_in_timeframe() ) { @@ -159,7 +159,7 @@ public function add_settings( $settings ) { ), 'value' => simpay_get_setting( 'fraud_email_verification', - 'no' + 'yes' ), 'toggles' => array( 'value' => 'yes', @@ -272,7 +272,7 @@ public function add_payment_form_settings() { $enabled = simpay_get_setting( 'fraud_email_verification', - 'no' + 'yes' ); ?> @@ -345,14 +345,6 @@ class="simpay-field simpay-field-checkbox simpay-field simpay-field-checkboxes" * @return void */ public function log_fraud_event( $event, $charge ) { - // Do nothing if the failure is for another reason. - if ( - ! isset( $charge->fraud_details->stripe_report ) || - 'fraudulent' !== $charge->fraud_details->stripe_report - ) { - return; - } - /** @var array $fraud_events */ $fraud_events = get_option( 'simpay_fraud_events', array() ); $timeframe = $this->get_fraud_event_timeframe(); diff --git a/src/Plugin.php b/src/Plugin.php index 2e149385..f5c19469 100644 --- a/src/Plugin.php +++ b/src/Plugin.php @@ -67,7 +67,7 @@ public function load() { } // Run slightly early to gain access to legacy registries. - add_action( 'plugins_loaded', array( $this, 'register' ), 5 ); + add_action( 'plugins_loaded', array( $this, 'register' ), 5 ); // @phpstan-ignore-line } /** diff --git a/src/StripeConnect/ApplicationFee.php b/src/StripeConnect/ApplicationFee.php index 1eda248e..6bc2e5f9 100644 --- a/src/StripeConnect/ApplicationFee.php +++ b/src/StripeConnect/ApplicationFee.php @@ -488,6 +488,7 @@ private function is_account_country_supported() { private function get_unavailable_country_codes() { return array( 'br', + 'in', ); } diff --git a/vendor/autoload.php b/vendor/autoload.php index 5ec295f8..2c4eab0c 100644 --- a/vendor/autoload.php +++ b/vendor/autoload.php @@ -4,4 +4,4 @@ require_once __DIR__ . '/composer/autoload_real.php'; -return ComposerAutoloaderInitb15b4328f642a8c511800bdf6172862c::getLoader(); +return ComposerAutoloaderInita277997cd9e74c50762174de5036ad2a::getLoader(); diff --git a/vendor/composer/autoload_real.php b/vendor/composer/autoload_real.php index 74cc6fa8..9948f6a1 100644 --- a/vendor/composer/autoload_real.php +++ b/vendor/composer/autoload_real.php @@ -2,7 +2,7 @@ // autoload_real.php @generated by Composer -class ComposerAutoloaderInitb15b4328f642a8c511800bdf6172862c +class ComposerAutoloaderInita277997cd9e74c50762174de5036ad2a { private static $loader; @@ -22,15 +22,15 @@ public static function getLoader() return self::$loader; } - spl_autoload_register(array('ComposerAutoloaderInitb15b4328f642a8c511800bdf6172862c', 'loadClassLoader'), true, true); + spl_autoload_register(array('ComposerAutoloaderInita277997cd9e74c50762174de5036ad2a', 'loadClassLoader'), true, true); self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(\dirname(__FILE__))); - spl_autoload_unregister(array('ComposerAutoloaderInitb15b4328f642a8c511800bdf6172862c', 'loadClassLoader')); + spl_autoload_unregister(array('ComposerAutoloaderInita277997cd9e74c50762174de5036ad2a', 'loadClassLoader')); $useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded()); if ($useStaticLoader) { require __DIR__ . '/autoload_static.php'; - call_user_func(\Composer\Autoload\ComposerStaticInitb15b4328f642a8c511800bdf6172862c::getInitializer($loader)); + call_user_func(\Composer\Autoload\ComposerStaticInita277997cd9e74c50762174de5036ad2a::getInitializer($loader)); } else { $map = require __DIR__ . '/autoload_namespaces.php'; foreach ($map as $namespace => $path) { diff --git a/vendor/composer/autoload_static.php b/vendor/composer/autoload_static.php index d8646530..bee99dfd 100644 --- a/vendor/composer/autoload_static.php +++ b/vendor/composer/autoload_static.php @@ -4,7 +4,7 @@ namespace Composer\Autoload; -class ComposerStaticInitb15b4328f642a8c511800bdf6172862c +class ComposerStaticInita277997cd9e74c50762174de5036ad2a { public static $prefixLengthsPsr4 = array ( 'S' => @@ -37,9 +37,9 @@ class ComposerStaticInitb15b4328f642a8c511800bdf6172862c public static function getInitializer(ClassLoader $loader) { return \Closure::bind(function () use ($loader) { - $loader->prefixLengthsPsr4 = ComposerStaticInitb15b4328f642a8c511800bdf6172862c::$prefixLengthsPsr4; - $loader->prefixDirsPsr4 = ComposerStaticInitb15b4328f642a8c511800bdf6172862c::$prefixDirsPsr4; - $loader->classMap = ComposerStaticInitb15b4328f642a8c511800bdf6172862c::$classMap; + $loader->prefixLengthsPsr4 = ComposerStaticInita277997cd9e74c50762174de5036ad2a::$prefixLengthsPsr4; + $loader->prefixDirsPsr4 = ComposerStaticInita277997cd9e74c50762174de5036ad2a::$prefixDirsPsr4; + $loader->classMap = ComposerStaticInita277997cd9e74c50762174de5036ad2a::$classMap; }, null, ClassLoader::class); } diff --git a/vendor/composer/installed.php b/vendor/composer/installed.php index 9144df89..06241fef 100644 --- a/vendor/composer/installed.php +++ b/vendor/composer/installed.php @@ -5,7 +5,7 @@ 'type' => 'wordpress-plugin', 'install_path' => __DIR__ . '/../../', 'aliases' => array(), - 'reference' => 'dcef12edfdfa3a445bb4eebca41fdf89c532d483', + 'reference' => 'fbd65ae6efb7172dbe61678c4620370fb23746d4', 'name' => 'wpsimplepay/wp-simple-pay-pro-3', 'dev' => false, ), @@ -88,7 +88,7 @@ 'type' => 'wordpress-plugin', 'install_path' => __DIR__ . '/../../', 'aliases' => array(), - 'reference' => 'dcef12edfdfa3a445bb4eebca41fdf89c532d483', + 'reference' => 'fbd65ae6efb7172dbe61678c4620370fb23746d4', 'dev_requirement' => false, ), ), diff --git a/views/payment-page-output.php b/views/payment-page-output.php index f069a6f7..6ab20769 100644 --- a/views/payment-page-output.php +++ b/views/payment-page-output.php @@ -25,6 +25,7 @@ +