diff --git a/assets/dummy-data/auction_products.xml b/assets/dummy-data/auction_products.xml new file mode 100644 index 00000000..459b9abc --- /dev/null +++ b/assets/dummy-data/auction_products.xml @@ -0,0 +1,359 @@ + + + + Test Auction Product A + This is the product description for a test auction product + This a test auction product. + testvendor1 + test-auction-product-a + publish + product + auction + + + + + + + + + + + _edit_lock + 1727262609:1 + + + _edit_last + 1 + + + _auction_started + 0 + + + _auction_bid_count + 0 + + + total_sales + 0 + + + _tax_status + taxable + + + _tax_class + + + + _manage_stock + yes + + + _backorders + no + + + _sold_individually + yes + + + _virtual + no + + + _downloadable + no + + + _download_limit + -1 + + + _download_expiry + -1 + + + _stock + 1 + + + _stock_status + instock + + + _wc_average_rating + 0 + + + _wc_review_count + 0 + + + _product_version + 9.2.3 + + + _price + 2000 + + + _auction_item_condition + new + + + _auction_type + normal + + + _auction_proxy + 0 + + + _auction_sealed + no + + + _auction_start_price + 1000 + + + _auction_bid_increment + 250 + + + _auction_reserved_price + 1750 + + + _regular_price + 2000 + + + _auction_dates_from + 2024-09-27 00:00 + + + _auction_dates_to + 2024-09-30 23:59 + + + _auction_automatic_relist + no + + + _auction_relist_fail_time + + + + _auction_relist_not_paid_time + + + + _auction_relist_duration + + + + _auction_extend_enable + no + + + _auction_extend_in_time + 0 + + + _auction_extend_for_time + 0 + + + _commission_percentage_per_product + 0 + + + _commission_fixed_with_percentage_qty + 0 + + + + + Test Auction Product B + Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. Vestibulum tortor quam, feugiat vitae, ultricies eget, tempor sit amet, ante. Donec eu libero sit amet quam egestas semper. Aenean ultricies mi vitae est. Mauris placerat eleifend leo. + This is a test auction product. + testvendor1 + test-auction-product-b + publish + product + auction + + + + + + + + + + + total_sales + 0 + + + _tax_status + taxable + + + _tax_class + + + + _manage_stock + yes + + + _backorders + no + + + _sold_individually + yes + + + _virtual + no + + + _downloadable + no + + + _download_limit + -1 + + + _download_expiry + -1 + + + _stock + 1 + + + _wc_average_rating + 0 + + + _wc_review_count + 0 + + + _product_version + 9.2.3 + + + _price + 5000 + + + _auction_item_condition + new + + + _auction_type + normal + + + _auction_proxy + 0 + + + _auction_sealed + no + + + _auction_start_price + 2000 + + + _auction_bid_increment + 250 + + + _auction_reserved_price + 4000 + + + _auction_automatic_relist + no + + + _auction_relist_fail_time + + + + _auction_relist_not_paid_time + + + + _auction_relist_duration + + + + _auction_extend_enable + no + + + _auction_extend_in_time + 0 + + + _auction_extend_for_time + 0 + + + _commission_percentage_per_product + 0 + + + _commission_fixed_with_percentage_qty + 0 + + + _stock_status + instock + + + _auction_bid_count + 0 + + + _edit_lock + 1727263228:1 + + + _edit_last + 1 + + + _regular_price + 5000 + + + _auction_dates_from + 2024-09-25 00:00 + + + _auction_dates_to + 2024-09-30 23:59 + + + _auction_has_started + 1 + + + _auction_last_activity + 1727263104 + + + + \ No newline at end of file diff --git a/assets/dummy-data/booking_products.xml b/assets/dummy-data/booking_products.xml new file mode 100644 index 00000000..723db917 --- /dev/null +++ b/assets/dummy-data/booking_products.xml @@ -0,0 +1,495 @@ + + + + Test booking A + Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. Vestibulum tortor quam, feugiat vitae, ultricies eget, tempor sit amet, ante. Donec eu libero sit amet quam egestas semper. Aenean ultricies mi vitae est. Mauris placerat eleifend leo. + This is a test booking product. + testvendor1 + test-booking-a + publish + product + booking + + + + + + + + + + + _edit_lock + 1726825169:1 + + + _edit_last + 1 + + + total_sales + 0 + + + _tax_status + taxable + + + _tax_class + + + + _manage_stock + no + + + _backorders + no + + + _sold_individually + no + + + _virtual + no + + + _downloadable + no + + + _download_limit + -1 + + + _download_expiry + -1 + + + _stock + NULL + + + _stock_status + instock + + + _wc_average_rating + 0 + + + _wc_review_count + 0 + + + _has_additional_costs + NULL + + + _wc_booking_apply_adjacent_buffer + + + + _wc_booking_availability + a:4:{i:0;a:5:{s:4:"type";s:6:"time:1";s:8:"bookable";s:3:"yes";s:8:"priority";i:10;s:4:"from";s:5:"08:00";s:2:"to";s:5:"22:00";}i:1;a:5:{s:4:"type";s:6:"time:2";s:8:"bookable";s:3:"yes";s:8:"priority";i:10;s:4:"from";s:5:"08:00";s:2:"to";s:5:"22:00";}i:2;a:5:{s:4:"type";s:6:"time:3";s:8:"bookable";s:3:"yes";s:8:"priority";i:10;s:4:"from";s:5:"08:00";s:2:"to";s:5:"22:00";}i:3;a:5:{s:4:"type";s:6:"time:4";s:8:"bookable";s:3:"yes";s:8:"priority";i:10;s:4:"from";s:5:"08:00";s:2:"to";s:5:"22:00";}} + + + _wc_booking_block_cost + 100 + + + _wc_booking_buffer_period + 0 + + + _wc_booking_calendar_display_mode + always_visible + + + _wc_booking_cancel_limit_unit + month + + + _wc_booking_cancel_limit + 1 + + + _wc_booking_check_availability_against + + + + _wc_booking_cost + 50 + + + _wc_booking_default_date_availability + available + + + _wc_booking_duration_type + fixed + + + _wc_booking_duration_unit + day + + + _wc_booking_duration + 1 + + + _wc_booking_enable_range_picker + + + + _wc_booking_first_block_time + + + + _wc_booking_has_person_types + + + + _wc_booking_has_persons + + + + _wc_booking_has_resources + + + + _wc_booking_has_restricted_days + + + + _wc_booking_max_date_unit + month + + + _wc_booking_max_date + 12 + + + _wc_booking_max_duration + 1 + + + _wc_booking_max_persons_group + 1 + + + _wc_booking_min_date_unit + day + + + _wc_booking_min_date + 0 + + + _wc_booking_min_duration + 1 + + + _wc_booking_min_persons_group + 1 + + + _wc_booking_person_cost_multiplier + + + + _wc_booking_person_qty_multiplier + + + + _wc_booking_pricing + a:1:{i:0;a:7:{s:4:"type";s:5:"weeks";s:4:"cost";s:2:"10";s:8:"modifier";s:0:"";s:9:"base_cost";s:2:"10";s:13:"base_modifier";s:0:"";s:4:"from";s:1:"1";s:2:"to";s:1:"2";}} + + + _wc_booking_pricing_mode + fixed + + + _wc_booking_required_persons + 0 + + + _wc_booking_use_calendar + 1 + + + _wc_booking_weekly_pricing + + + + _wc_booking_block_weekdays + a:0:{} + + + _wc_booking_premium_day_cost + 200 + + + _wc_booking_premium_day_qty + 0 + + + _wc_booking_display_block_costs + no + + + _wc_booking_prices_display_mode + show_cost_only + + + _wc_booking_max_cost + + + + _wc_booking_calendar_limit + 5 + + + + + Test booking B + Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. Vestibulum tortor quam, feugiat vitae, ultricies eget, tempor sit amet, ante. Donec eu libero sit amet quam egestas semper. Aenean ultricies mi vitae est. Mauris placerat eleifend leo. + This is a test booking product. + testvendor1 + test-booking-b + publish + product + booking + + + + + + + + + + + _edit_lock + 1726825169:1 + + + _edit_last + 1 + + + total_sales + 0 + + + _tax_status + taxable + + + _tax_class + + + + _manage_stock + no + + + _backorders + no + + + _sold_individually + no + + + _virtual + no + + + _downloadable + no + + + _download_limit + -1 + + + _download_expiry + -1 + + + _stock + NULL + + + _stock_status + instock + + + _wc_average_rating + 0 + + + _wc_review_count + 0 + + + _has_additional_costs + NULL + + + _wc_booking_apply_adjacent_buffer + + + + _wc_booking_availability + a:4:{i:0;a:5:{s:4:"type";s:6:"time:1";s:8:"bookable";s:3:"yes";s:8:"priority";i:10;s:4:"from";s:5:"08:00";s:2:"to";s:5:"22:00";}i:1;a:5:{s:4:"type";s:6:"time:2";s:8:"bookable";s:3:"yes";s:8:"priority";i:10;s:4:"from";s:5:"08:00";s:2:"to";s:5:"22:00";}i:2;a:5:{s:4:"type";s:6:"time:3";s:8:"bookable";s:3:"yes";s:8:"priority";i:10;s:4:"from";s:5:"08:00";s:2:"to";s:5:"22:00";}i:3;a:5:{s:4:"type";s:6:"time:4";s:8:"bookable";s:3:"yes";s:8:"priority";i:10;s:4:"from";s:5:"08:00";s:2:"to";s:5:"22:00";}} + + + _wc_booking_block_cost + 100 + + + _wc_booking_buffer_period + 0 + + + _wc_booking_calendar_display_mode + always_visible + + + _wc_booking_cancel_limit_unit + month + + + _wc_booking_cancel_limit + 1 + + + _wc_booking_check_availability_against + + + + _wc_booking_cost + 50 + + + _wc_booking_default_date_availability + available + + + _wc_booking_duration_type + fixed + + + _wc_booking_duration_unit + day + + + _wc_booking_duration + 1 + + + _wc_booking_enable_range_picker + + + + _wc_booking_first_block_time + + + + _wc_booking_has_person_types + + + + _wc_booking_has_persons + + + + _wc_booking_has_resources + + + + _wc_booking_has_restricted_days + + + + _wc_booking_max_date_unit + month + + + _wc_booking_max_date + 12 + + + _wc_booking_max_duration + 1 + + + _wc_booking_max_persons_group + 1 + + + _wc_booking_min_date_unit + day + + + _wc_booking_min_date + 0 + + + _wc_booking_min_duration + 1 + + + _wc_booking_min_persons_group + 1 + + + _wc_booking_person_cost_multiplier + + + + _wc_booking_person_qty_multiplier + + + + _wc_booking_pricing + a:1:{i:0;a:7:{s:4:"type";s:5:"weeks";s:4:"cost";s:2:"10";s:8:"modifier";s:0:"";s:9:"base_cost";s:2:"10";s:13:"base_modifier";s:0:"";s:4:"from";s:1:"1";s:2:"to";s:1:"2";}} + + + _wc_booking_require_confirmation + yes + + + _wc_booking_reservation_method + individual + + + _wc_booking_reservation_type + individual + + + _wc_booking_resource_ids + + + + _wc_booking_time_units + hour + + + _wc_booking_time_per_block + 1 + + + _wc_booking_block_duration_type + fixed + + + _wc_booking_block_duration + 1 + + + + \ No newline at end of file diff --git a/assets/dummy-data/commissions.xml b/assets/dummy-data/commissions.xml new file mode 100644 index 00000000..a9cb25dc --- /dev/null +++ b/assets/dummy-data/commissions.xml @@ -0,0 +1,14 @@ + + + Art + 5 + + + Electronics + 10 + + + Fashion + 15 + + \ No newline at end of file diff --git a/assets/dummy-data/images/product_images/hoodie.jpg b/assets/dummy-data/images/product_images/hoodie.jpg new file mode 100644 index 00000000..969f558c Binary files /dev/null and b/assets/dummy-data/images/product_images/hoodie.jpg differ diff --git a/assets/dummy-data/images/product_images/hoodie_with_logo.jpg b/assets/dummy-data/images/product_images/hoodie_with_logo.jpg new file mode 100644 index 00000000..d345bda0 Binary files /dev/null and b/assets/dummy-data/images/product_images/hoodie_with_logo.jpg differ diff --git a/assets/dummy-data/images/product_images/v_neck_tshirt.jpeg b/assets/dummy-data/images/product_images/v_neck_tshirt.jpeg new file mode 100644 index 00000000..f15c3f2b Binary files /dev/null and b/assets/dummy-data/images/product_images/v_neck_tshirt.jpeg differ diff --git a/assets/dummy-data/images/vendor_images/vendor1_banner.png b/assets/dummy-data/images/vendor_images/vendor1_banner.png new file mode 100644 index 00000000..680a56a8 Binary files /dev/null and b/assets/dummy-data/images/vendor_images/vendor1_banner.png differ diff --git a/assets/dummy-data/images/vendor_images/vendor1_logo.png b/assets/dummy-data/images/vendor_images/vendor1_logo.png new file mode 100644 index 00000000..332347dd Binary files /dev/null and b/assets/dummy-data/images/vendor_images/vendor1_logo.png differ diff --git a/assets/dummy-data/images/vendor_images/vendor2_banner.jpg b/assets/dummy-data/images/vendor_images/vendor2_banner.jpg new file mode 100644 index 00000000..74f3d4fe Binary files /dev/null and b/assets/dummy-data/images/vendor_images/vendor2_banner.jpg differ diff --git a/assets/dummy-data/images/vendor_images/venodr2_logo.png b/assets/dummy-data/images/vendor_images/venodr2_logo.png new file mode 100644 index 00000000..7c84ed4a Binary files /dev/null and b/assets/dummy-data/images/vendor_images/venodr2_logo.png differ diff --git a/assets/dummy-data/niche_products.xml b/assets/dummy-data/niche_products.xml new file mode 100644 index 00000000..5c2daaf7 --- /dev/null +++ b/assets/dummy-data/niche_products.xml @@ -0,0 +1,480 @@ + + + + V-Neck T-Shirt + Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. Vestibulum tortor quam, feugiat vitae, ultricies eget, tempor sit amet, ante. Donec eu libero sit amet quam egestas semper. Aenean ultricies mi vitae est. Mauris placerat eleifend leo. + This is a variable product. + testvendor2 + v-neck-t-shirt + publish + product + simple + + + dc-woocommerce-multi-vendor\assets\dummy-data\images\product_images\v_neck_tshirt.jpeg + + + + Blue + featured + Green + Large + Medium + Red + Small + variable + Tshirts + + + + _sku + woo-vneck-tee + + + _sale_price_dates_from + + + + _sale_price_dates_to + + + + total_sales + 0 + + + _tax_status + taxable + + + _tax_class + + + + _manage_stock + no + + + _backorders + no + + + _low_stock_amount + + + + _sold_individually + no + + + _weight + 0.5 + + + _length + 24 + + + _width + 1 + + + _height + 2 + + + _upsell_ids + a:0:{} + + + _crosssell_ids + a:0:{} + + + _purchase_note + + + + _default_attributes + a:0:{} + + + _virtual + no + + + _downloadable + no + + + _download_limit + 0 + + + _download_expiry + 0 + + + _stock + + + + _stock_status + instock + + + _wc_average_rating + 0 + + + _wc_rating_count + a:0:{} + + + _wc_review_count + 0 + + + _downloadable_files + a:0:{} + + + _product_attributes + a:2:{s:8:"pa_color";a:6:{s:4:"name";s:8:"pa_color";s:5:"value";s:0:"";s:8:"position";i:0;s:10:"is_visible";i:1;s:12:"is_variation";i:1;s:11:"is_taxonomy";i:1;}s:7:"pa_size";a:6:{s:4:"name";s:7:"pa_size";s:5:"value";s:0:"";s:8:"position";i:1;s:10:"is_visible";i:1;s:12:"is_variation";i:1;s:11:"is_taxonomy";i:1;}} + + + _product_version + 3.5.3 + + + _price + 15 + + + _price + 20 + + + _regular_price + + + + _sale_price + + + + + + Hoodie + Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. Vestibulum tortor quam, feugiat vitae, ultricies eget, tempor sit amet, ante. Donec eu libero sit amet quam egestas semper. Aenean ultricies mi vitae est. Mauris placerat eleifend leo. + This is a variable product. + testvendor2 + hoodie + publish + product + simple + + + dc-woocommerce-multi-vendor\assets\dummy-data\images\product_images\hoodie.jpg + + + + Blue + Green + Red + variable + Hoodies + + + + _sku + woo-hoodie + + + _sale_price_dates_from + + + + _sale_price_dates_to + + + + total_sales + 0 + + + _tax_status + taxable + + + _tax_class + + + + _manage_stock + no + + + _backorders + no + + + _low_stock_amount + + + + _sold_individually + no + + + _weight + 1.5 + + + _length + 10 + + + _width + 8 + + + _height + 3 + + + _upsell_ids + a:0:{} + + + _crosssell_ids + a:0:{} + + + _purchase_note + + + + _default_attributes + a:0:{} + + + _virtual + no + + + _downloadable + no + + + _download_limit + 0 + + + _download_expiry + 0 + + + _stock + + + + _stock_status + instock + + + _wc_average_rating + 0 + + + _wc_rating_count + a:0:{} + + + _wc_review_count + 0 + + + _downloadable_files + a:0:{} + + + _product_attributes + a:2:{s:8:"pa_color";a:6:{s:4:"name";s:8:"pa_color";s:5:"value";s:0:"";s:8:"position";i:0;s:10:"is_visible";i:1;s:12:"is_variation";i:1;s:11:"is_taxonomy";i:1;}s:4:"logo";a:6:{s:4:"name";s:4:"Logo";s:5:"value";s:8:"Yes | No";s:8:"position";i:1;s:10:"is_visible";i:1;s:12:"is_variation";i:1;s:11:"is_taxonomy";i:0;}} + + + _product_version + 3.5.3 + + + _price + 42 + + + _price + 45 + + + _regular_price + + + + _sale_price + + + + + + Hoodie with Logo + Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. Vestibulum tortor quam, feugiat vitae, ultricies eget, tempor sit amet, ante. Donec eu libero sit amet quam egestas semper. Aenean ultricies mi vitae est. Mauris placerat eleifend leo. + This is a simple product. + testvendor2 + hoodie-with-logo + publish + product + + + dc-woocommerce-multi-vendor\assets\dummy-data\images\product_images\hoodie_with_logo.jpg + + + + Blue + simple + Hoodies + + + + _sku + woo-hoodie-with-logo + + + _regular_price + 45 + + + _sale_price + + + + _sale_price_dates_from + + + + _sale_price_dates_to + + + + total_sales + 0 + + + _tax_status + taxable + + + _tax_class + + + + _manage_stock + no + + + _backorders + no + + + _low_stock_amount + + + + _sold_individually + no + + + _weight + 2 + + + _length + 10 + + + _width + 6 + + + _height + 3 + + + _upsell_ids + a:0:{} + + + _crosssell_ids + a:0:{} + + + _purchase_note + + + + _default_attributes + a:0:{} + + + _virtual + no + + + _downloadable + no + + + _download_limit + 0 + + + _download_expiry + 0 + + + _stock + + + + _stock_status + instock + + + _wc_average_rating + 0 + + + _wc_rating_count + a:0:{} + + + _wc_review_count + 0 + + + _downloadable_files + a:0:{} + + + _product_attributes + a:1:{s:8:"pa_color";a:6:{s:4:"name";s:8:"pa_color";s:5:"value";s:0:"";s:8:"position";i:0;s:10:"is_visible";i:1;s:12:"is_variation";i:0;s:11:"is_taxonomy";i:1;}} + + + _product_version + 3.5.3 + + + _price + 45 + + + + \ No newline at end of file diff --git a/assets/dummy-data/orders.xml b/assets/dummy-data/orders.xml new file mode 100644 index 00000000..2703e4dc --- /dev/null +++ b/assets/dummy-data/orders.xml @@ -0,0 +1,30 @@ + + + John + Doe + john.doe@example.com + 123 Main Street + + Anytown + CA + 12345 + United States (US) + 1 + cod + Cash on delivery + + + Jane + Smith + jane.smith@example.com + 123 Main Street + + Anytown + CA + 12345 + United States (US) + 1 + cod + Cash on delivery + + \ No newline at end of file diff --git a/assets/dummy-data/reviews.xml b/assets/dummy-data/reviews.xml new file mode 100644 index 00000000..d3a9bebf --- /dev/null +++ b/assets/dummy-data/reviews.xml @@ -0,0 +1,14 @@ + + + John Doe + john.doe@example.com + 5 + Very good product, fits perfectly. + + + Jane Smith + jane.smith@example.com + 4 + Good Product but package was slightly damaged. + + \ No newline at end of file diff --git a/assets/dummy-data/subscription_products.xml b/assets/dummy-data/subscription_products.xml new file mode 100644 index 00000000..6d9ffa2d --- /dev/null +++ b/assets/dummy-data/subscription_products.xml @@ -0,0 +1,299 @@ + + + + Test Subscription Product A + This is the product description for a test subscription product + This a test subscription product. + testvendor1 + test-subscription-product-a + publish + product + subscription + + + + + + + + + + + _edit_lock + 1727259788:1 + + + _edit_last + 1 + + + _regular_price + 199 + + + _sale_price + 169 + + + total_sales + 0 + + + _tax_status + taxable + + + _tax_class + + + + _manage_stock + no + + + _backorders + no + + + _sold_individually + no + + + _virtual + no + + + _downloadable + no + + + _download_limit + -1 + + + _download_expiry + -1 + + + _stock + NULL + + + _stock_status + instock + + + _wc_average_rating + 0 + + + _wc_review_count + 0 + + + _product_version + 9.2.3 + + + _price + 169 + + + _subscription_payment_sync_date + 0 + + + _commission_percentage_per_product + 0 + + + _commission_fixed_with_percentage_qty + 0 + + + _subscription_price + 199 + + + _subscription_trial_length + 0 + + + _subscription_sign_up_fee + 49 + + + _subscription_period + month + + + _subscription_period_interval + 1 + + + _subscription_length + 0 + + + _subscription_trial_period + day + + + _subscription_limit + no + + + _subscription_one_time_shipping + no + + + + + Test Subscription Product B + Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. Vestibulum tortor quam, feugiat vitae, ultricies eget, tempor sit amet, ante. Donec eu libero sit amet quam egestas semper. Aenean ultricies mi vitae est. Mauris placerat eleifend leo. + This is a test booking product. + testvendor1 + test-subscription-product-b + publish + product + subscription + + + + + + + + + + + _edit_lock + 1727260417:1 + + + _edit_last + 1 + + + _regular_price + 999 + + + _sale_price + 799 + + + total_sales + 0 + + + _tax_status + taxable + + + _tax_class + + + + _manage_stock + no + + + _backorders + no + + + _sold_individually + no + + + _virtual + no + + + _downloadable + no + + + _download_limit + -1 + + + _download_expiry + -1 + + + _stock + NULL + + + _stock_status + instock + + + _wc_average_rating + 0 + + + _wc_review_count + 0 + + + _product_version + 9.2.3 + + + _price + 799 + + + _subscription_payment_sync_date + 0 + + + _commission_percentage_per_product + 0 + + + _commission_fixed_with_percentage_qty + 0 + + + _subscription_price + 999 + + + _subscription_trial_length + 30 + + + _subscription_sign_up_fee + + + + _subscription_period + month + + + _subscription_period_interval + 1 + + + _subscription_length + 0 + + + _subscription_trial_period + day + + + _subscription_limit + no + + + _subscription_one_time_shipping + no + + + + \ No newline at end of file diff --git a/assets/dummy-data/vendors.xml b/assets/dummy-data/vendors.xml new file mode 100644 index 00000000..17f82841 --- /dev/null +++ b/assets/dummy-data/vendors.xml @@ -0,0 +1,38 @@ + + + testvendor1 + dummyPass + Test + Vendor 1 + testvendor1@gmail.com + TestVendor1 + + + dc-woocommerce-multi-vendor/assets/dummy-data/images/vendor_images/vendor1_logo.png + store + + + dc-woocommerce-multi-vendor/assets/dummy-data/images/vendor_images/vendor1_banner.png + cover + + + + + testvendor2 + dummyPass + Test + Vendor 2 + testvendor2@gmail.com + TestVendor2 + + + dc-woocommerce-multi-vendor/assets/dummy-data/images/vendor_images/venodr2_logo.png + store + + + dc-woocommerce-multi-vendor/assets/dummy-data/images/vendor_images/vendor2_banner.jpg + cover + + + + \ No newline at end of file diff --git a/classes/Admin/SetupWizard.php b/classes/Admin/SetupWizard.php index 39d84b43..4d045e52 100644 --- a/classes/Admin/SetupWizard.php +++ b/classes/Admin/SetupWizard.php @@ -14,22 +14,16 @@ class SetupWizard { - /** @var string Currenct Step */ - private $step = ''; - - /** @var array Steps for the setup wizard */ - private $steps = []; - public function __construct() { add_action('admin_menu', [$this, 'admin_menus']); - add_action('admin_init', [$this, 'setup_wizard']); + add_action('admin_enqueue_scripts', [ $this, 'setup_scripts']); } /** * Add admin menus/screens. */ public function admin_menus() { - add_dashboard_page('', '', 'manage_options', 'mvx-setup', ''); + add_dashboard_page('', '', 'manage_options', 'mvx-setup', [$this, 'setup_wizard']); } /** @@ -41,254 +35,40 @@ public function setup_wizard() { return; } - if (! MVX()->is_woocommerce_installed()) { - if (filter_input(INPUT_POST, 'submit')) { - $this->install_woocommerce(); - } - $this->install_woocommerce_view(); - exit(); - } - - $default_steps = array( - 'introduction' => array( - 'name' => __('Introduction', 'multivendorx'), - 'view' => array($this, 'mvx_setup_introduction'), - 'handler' => '', - ), - 'store' => array( - 'name' => __('Store Setup', 'multivendorx'), - 'view' => array($this, 'mvx_setup_store'), - 'handler' => array($this, 'mvx_setup_store_save') - ), - 'commission' => array( - 'name' => __('Commission Setup', 'multivendorx'), - 'view' => array($this, 'mvx_setup_commission'), - 'handler' => array($this, 'mvx_setup_commission_save') - ), - 'payments' => array( - 'name' => __('Payments', 'multivendorx'), - 'view' => array($this, 'mvx_setup_payments'), - 'handler' => array($this, 'mvx_setup_payments_save') - ), - 'capability' => array( - 'name' => __('Capability', 'multivendorx'), - 'view' => array($this, 'mvx_setup_capability'), - 'handler' => array($this, 'mvx_setup_capability_save') - ), - 'introduction-migration' => array( - 'name' => __('Migration', 'multivendorx' ), - 'view' => array($this, 'mvx_migration_introduction'), - 'handler' => '', - ), - 'store-process' => array( - 'name' => __('Processing', 'multivendorx'), - 'view' => array($this, 'mvx_migration_store_process'), - 'handler' => '' - ), - 'next_steps' => array( - 'name' => __('Ready!', 'multivendorx'), - 'view' => array($this, 'mvx_setup_ready'), - 'handler' => '', - ), - ); - if (!$MVX->multivendor_migration->mvx_is_marketplace()) { - unset( $default_steps['introduction-migration'], $default_steps['store-process'] ); - } - $this->steps = apply_filters('mvx_setup_wizard_steps', $default_steps); - $current_step = filter_input(INPUT_GET, 'step'); - $this->step = $current_step ? sanitize_key($current_step) : current(array_keys($this->steps)); + // if (!$MVX->multivendor_migration->mvx_is_marketplace()) { + // unset( $default_steps['introduction-migration'], $default_steps['store-process'] ); + // } $suffix = defined('MVX_SCRIPT_DEBUG') && MVX_SCRIPT_DEBUG ? '' : '.min'; wp_register_script('jquery-blockui', WC()->plugin_url() . '/assets/js/jquery-blockui/jquery.blockUI' . $suffix . '.js', array('jquery'), '2.70', true); wp_register_script( 'jquery-tiptip', WC()->plugin_url() . '/assets/js/jquery-tiptip/jquery.tipTip' . $suffix . '.js', array( 'jquery' ), WC_VERSION, true ); wp_register_script( 'selectWoo', WC()->plugin_url() . '/assets/js/selectWoo/selectWoo.full' . $suffix . '.js', array( 'jquery' ), '1.0.0' ); wp_register_script('wc-enhanced-select', WC()->plugin_url() . '/assets/js/admin/wc-enhanced-select' . $suffix . '.js', array('jquery', 'selectWoo'), WC_VERSION); - wp_localize_script('wc-enhanced-select', 'wc_enhanced_select_params', array( - 'i18n_no_matches' => _x('No matches found', 'enhanced select', 'multivendorx'), - 'i18n_ajax_error' => _x('Loading failed', 'enhanced select', 'multivendorx'), - 'i18n_input_too_short_1' => _x('Please enter 1 or more characters', 'enhanced select', 'multivendorx'), - 'i18n_input_too_short_n' => _x('Please enter %qty% or more characters', 'enhanced select', 'multivendorx'), - 'i18n_input_too_long_1' => _x('Please delete 1 character', 'enhanced select', 'multivendorx'), - 'i18n_input_too_long_n' => _x('Please delete %qty% characters', 'enhanced select', 'multivendorx'), - 'i18n_selection_too_long_1' => _x('You can only select 1 item', 'enhanced select', 'multivendorx'), - 'i18n_selection_too_long_n' => _x('You can only select %qty% items', 'enhanced select', 'multivendorx'), - 'i18n_load_more' => _x('Loading more results…', 'enhanced select', 'multivendorx'), - 'i18n_searching' => _x('Searching…', 'enhanced select', 'multivendorx'), - 'ajax_url' => admin_url('admin-ajax.php'), - 'search_products_nonce' => wp_create_nonce('search-products'), - 'search_customers_nonce' => wp_create_nonce('search-customers'), - )); wp_enqueue_style('woocommerce_admin_styles', WC()->plugin_url() . '/assets/css/admin.css', array(), WC_VERSION); wp_enqueue_style('wc-setup', WC()->plugin_url() . '/assets/css/wc-setup.css', array('dashicons', 'install'), WC_VERSION); wp_enqueue_style('mvx_admin_css', $MVX->plugin_url . 'assets/admin/css/admin' . $suffix . '.css', array(), $MVX->version); wp_register_script('wc-setup', WC()->plugin_url() . '/assets/js/admin/wc-setup' . $suffix . '.js', array('jquery', 'wc-enhanced-select', 'jquery-blockui', 'jquery-tiptip'), WC_VERSION); - wp_register_script('mvx-setup', $MVX->plugin_url . '/assets/admin/js/setup-wizard.js', array('wc-setup'), WC_VERSION); wp_localize_script('wc-setup', 'wc_setup_params', array( 'locale_info' => json_encode(include( WC()->plugin_path() . '/i18n/locale-info.php' )), )); - - if (!empty($_POST['save_step']) && isset($this->steps[$this->step]['handler'])) { - call_user_func($this->steps[$this->step]['handler'], $this); - } - - ob_start(); - $this->setup_wizard_header(); - $this->setup_wizard_steps(); - $this->setup_wizard_content(); - $this->setup_wizard_footer(); - exit(); - } - - /** - * Content for install woocommerce view - */ - public function install_woocommerce_view() { ?> - - > - - - - <?php esc_html_e('MultivendorX › Setup Wizard', 'multivendorx'); ?> - - - - -

MultivendorX

-
-

-
- - -
-
- - +
id === 'dashboard_page_mvx-setup' ) { + wp_enqueue_script('setup_wizard_js', MVX()->plugin_url . 'mvx-modules/build/blocks/setupWizard/index.js', [ 'jquery', 'jquery-blockui', 'wp-element', 'wp-i18n' ], MVX()->version, true); + wp_localize_script( + 'setup_wizard_js', 'appLocalizer', [ + 'apiUrl' => untrailingslashit(get_rest_url()), + 'nonce' => wp_create_nonce( 'wp_rest' ), + 'redirect_url' => admin_url(), + 'woocommerce_installed' => MVX()->is_woocommerce_installed(), + ]); } - // Install this thing! - if (!$installed) { - // Suppress feedback - ob_start(); - - try { - $plugin_information = plugins_api('plugin_information', array( - 'slug' => $plugin_slug, - 'fields' => array( - 'short_description' => false, - 'sections' => false, - 'requires' => false, - 'rating' => false, - 'ratings' => false, - 'downloaded' => false, - 'last_updated' => false, - 'added' => false, - 'tags' => false, - 'homepage' => false, - 'donate_link' => false, - 'author_profile' => false, - 'author' => false, - ), - )); - - if (is_wp_error($plugin_information)) { - throw new \Exception($plugin_information->get_error_message()); - } - - $package = $plugin_information->download_link; - $download = $upgrader->download_package($package); - - if (is_wp_error($download)) { - throw new \Exception($download->get_error_message()); - } - - $working_dir = $upgrader->unpack_package($download, true); - - if (is_wp_error($working_dir)) { - throw new \Exception($working_dir->get_error_message()); - } - - $result = $upgrader->install_package(array( - 'source' => $working_dir, - 'destination' => WP_PLUGIN_DIR, - 'clear_destination' => false, - 'abort_if_destination_exists' => false, - 'clear_working' => true, - 'hook_extra' => array( - 'type' => 'plugin', - 'action' => 'install', - ), - )); - - if (is_wp_error($result)) { - throw new \Exception($result->get_error_message()); - } - - $activate = true; - } catch (\Exception $e) { - printf( - __('%1$s could not be installed (%2$s). Please install it manually by clicking here.', 'multivendorx'), 'WooCommerce', $e->getMessage(), esc_url(admin_url('plugin-install.php?tab=search&s=woocommerce')) - ); - exit(); - } - - // Discard feedback - ob_end_clean(); - } - - wp_clean_plugins_cache(); - // Activate this thing - if ($activate) { - try { - $result = activate_plugin($plugin); - - if (is_wp_error($result)) { - throw new \Exception($result->get_error_message()); - } - } catch (\Exception $e) { - printf( - __('%1$s was installed but could not be activated. Please activate it manually by clicking here.', 'multivendorx'), 'WooCommerce', admin_url('plugins.php') - ); - exit(); - } - } - wp_safe_redirect(admin_url('index.php?page=mvx-setup')); - } - - /** - * Get slug from path - * @param string $key - * @return string - */ - private static function format_plugin_slug($key) { - $slug = explode('/', $key); - $slug = explode('.', end($slug)); - return $slug[0]; } /** @@ -299,659 +79,35 @@ private static function format_plugin_slug($key) { * Empty string on failure. * @since 2.7.7 */ - public function get_next_step_link($step = '') { - if (!$step) { - $step = $this->step; - } - - $keys = array_keys($this->steps); - if (end($keys) === $step) { - return admin_url(); - } - - $step_index = array_search($step, $keys); - if (false === $step_index) { - return ''; - } - - return add_query_arg('step', $keys[$step_index + 1]); - } - - /** - * Setup Wizard Header. - */ - public function setup_wizard_header() { - global $MVX; - ?> - - > - - - - <?php esc_html_e('MultivendorX › Setup Wizard', 'multivendorx'); ?> - - - - - - -

MultivendorX

- steps; - array_shift($ouput_steps); - ?> -
    - $step) : ?> -
  1. - -
- '; - call_user_func($this->steps[$this->step]['view'], $this); - echo ''; - } - - /** - * Introduction step. - */ - public function mvx_setup_introduction() { - ?> -

-

It’s completely optional and shouldn’t take longer than five minutes.'); ?>

-

-

- - -

- -

-
 
-
- - - - - - - - - -
- - -

-
- - id="is_single_product_multiple_vendor" name="is_single_product_multiple_vendor" class="input-checkbox" value="Enable" /> -
-

- - - -

-
- -

-
 
-
- - - - - - - - - - - - - - - - - - - + // public function get_next_step_link($step = '') { + // if (!$step) { + // $step = $this->step; + // } - - - - + // $keys = array_keys($this->steps); + // if (end($keys) === $step) { + // return admin_url(); + // } - - - - + // $step_index = array_search($step, $keys); + // if (false === $step_index) { + // return ''; + // } -
- -
- -
- - -
- - -
- - -
- - -
- - -
-

- - - -

-
- get_payment_methods(); - ?> -

-
 
-
-

- - - - - - - - - - - - - - - -
- - id="mvx_disbursal_mode_admin" name="mvx_disbursal_mode_admin" class="input-checkbox" value="Enable" /> -

-
-
-
-
-
- -
- - id="mvx_disbursal_mode_vendor" name="mvx_disbursal_mode_vendor" class="input-checkbox" value="Enable" /> -

-
-

- - - -

-
- -

-
 
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
- id="is_submit_product" name="is_submit_product" class="input-checkbox" value="Enable"> -

-
- id="is_published_product" name="is_published_product" class="input-checkbox" value="Enable"> -

-
- id="is_edit_delete_published_product" name="is_edit_delete_published_product" class="input-checkbox" value="Enable"> -

-
- id="is_submit_coupon" name="is_submit_coupon" class="input-checkbox" value="Enable"> -

-
- id="is_published_coupon" name="is_published_coupon" class="input-checkbox" value="Enable"> -

-
- id="is_edit_delete_published_coupon" name="is_edit_delete_published_coupon" class="input-checkbox" value="Enable"> -

-
- id="is_upload_files" name="is_upload_files" class="input-checkbox" value="Enable"> -

-
-

- - - -

-
- - -
- -

- Tweet - -
- -
-

-
-
-
-

- -
-
-

- -
-
- get_next_step_link())); - exit; - } - - /** - * save commission settings - */ - public function mvx_setup_commission_save() { - check_admin_referer('mvx-setup'); - $payment_settings = mvx_get_option('mvx_commissions_tab_settings'); - $revenue_sharing_mode = filter_input(INPUT_POST, 'revenue_sharing_mode'); - $commission_type = filter_input(INPUT_POST, 'commission_type'); - $default_commission = filter_input(INPUT_POST, 'default_commission'); - $default_percentage = filter_input(INPUT_POST, 'default_percentage'); - $fixed_with_percentage = filter_input(INPUT_POST, 'fixed_with_percentage'); - $fixed_with_percentage_qty = filter_input(INPUT_POST, 'fixed_with_percentage_qty'); - if ($revenue_sharing_mode) { - $payment_settings['revenue_sharing_mode'] = $revenue_sharing_mode; - } - if ($commission_type) { - $payment_settings['commission_type'] = $commission_type; - } - if ($default_commission) { - $payment_settings['default_commission'] = $default_commission; - $payment_settings['default_commission'] = array( - 'key' => 'fixed_ammount', - 'value' => $default_commission - ); - } - if ($default_percentage) { - $payment_settings['default_percentage'] = $default_percentage; - $payment_settings['default_commission'] = array( - 'key' => 'percent_amount', - 'value' => $default_percentage - ); - } - if ($fixed_with_percentage) { - $payment_settings['fixed_with_percentage'] = $fixed_with_percentage; - $payment_settings['default_commission'] = array( - 'key' => 'percent_amount', - 'value' => $fixed_with_percentage - ); - } - if ($fixed_with_percentage_qty) { - $payment_settings['fixed_with_percentage_qty'] = $fixed_with_percentage_qty; - $payment_settings['default_commission'] = array( - 'key' => 'fixed_ammount', - 'value' => $fixed_with_percentage_qty - ); - } - mvx_update_option('mvx_commissions_tab_settings', $payment_settings); - wp_redirect(esc_url_raw($this->get_next_step_link())); - exit; - } - - /** - * save payment settings - */ - public function mvx_setup_payments_save() { - check_admin_referer('mvx-setup'); - $gateways = $this->get_payment_methods(); - //$payment_settings = mvx_get_option('mvx_commissions_tab_settings'); - $active_module_list = mvx_get_option('mvx_all_active_module_list') ? get_option('mvx_all_active_module_list') : array(); - $disbursement_settings = mvx_get_option('mvx_disbursement_tab_settings'); - $mvx_disbursal_mode_admin = filter_input(INPUT_POST, 'mvx_disbursal_mode_admin'); - $mvx_disbursal_mode_vendor = filter_input(INPUT_POST, 'mvx_disbursal_mode_vendor'); - - if ($mvx_disbursal_mode_admin) { - $disbursement_settings['choose_payment_mode_automatic_disbursal'] = array('choose_payment_mode_automatic_disbursal'); - $payment_schedule = filter_input(INPUT_POST, 'payment_schedule'); - if ($payment_schedule) { - $disbursement_settings['payment_schedule'] = $payment_schedule; - $schedule = wp_get_schedule('masspay_cron_start'); - if ($schedule != $payment_schedule) { - if (wp_next_scheduled('masspay_cron_start')) { - $timestamp = wp_next_scheduled('masspay_cron_start'); - wp_unschedule_event($timestamp, 'masspay_cron_start'); - } - wp_schedule_event(time(), $payment_schedule, 'masspay_cron_start'); - } - } - } else if (isset($disbursement_settings['choose_payment_mode_automatic_disbursal'])) { - unset($disbursement_settings['choose_payment_mode_automatic_disbursal']); - if (wp_next_scheduled('masspay_cron_start')) { - $timestamp = wp_next_scheduled('masspay_cron_start'); - wp_unschedule_event($timestamp, 'masspay_cron_start'); - } - } - - if ($mvx_disbursal_mode_vendor) { - $disbursement_settings['withdrawal_request'] = array('withdrawal_request'); - } else if (isset($disbursement_settings['withdrawal_request'])) { - unset($disbursement_settings['withdrawal_request']); - } - - foreach ($gateways as $gateway_id => $gateway) { - $is_enable_gateway = filter_input(INPUT_POST, 'payment_method_' . $gateway_id); - if ($is_enable_gateway) { - //$payment_settings['payment_method_disbursement'][$gateway_id] = str_replace('payment_method_', '', $is_enable_gateway); - array_push($active_module_list, $gateway_id); - if (!empty($gateway['repo-slug'])) { - wp_schedule_single_event(time() + 10, 'woocommerce_plugin_background_installer', array($gateway_id, $gateway)); - } - } else if (mvx_is_module_active($gateway_id)) { - unset($active_module_list[$gateway_id]); - } - } - //mvx_update_option('mvx_commissions_tab_settings', $payment_settings); - mvx_update_option( 'mvx_all_active_module_list', $active_module_list ); - mvx_update_option('mvx_disbursement_tab_settings', $disbursement_settings); - wp_redirect(esc_url_raw($this->get_next_step_link())); - exit; - } - - /** - * save capability settings - * @global object $mvx - */ - public function mvx_setup_capability_save() { - global $MVX; - check_admin_referer('mvx-setup'); - $capability_settings = mvx_get_option('mvx_products_capability_tab_settings') ? mvx_get_option('mvx_products_capability_tab_settings') : array(); - - $is_submit_product = filter_input(INPUT_POST, 'is_submit_product'); - $is_published_product = filter_input(INPUT_POST, 'is_published_product'); - $is_edit_delete_published_product = filter_input(INPUT_POST, 'is_edit_delete_published_product'); - $is_submit_coupon = filter_input(INPUT_POST, 'is_submit_coupon'); - $is_published_coupon = filter_input(INPUT_POST, 'is_published_coupon'); - $is_edit_delete_published_coupon = filter_input(INPUT_POST, 'is_edit_delete_published_coupon'); - $is_upload_files = filter_input(INPUT_POST, 'is_upload_files'); - - if ($is_submit_product) { - $capability_settings['is_submit_product'] = array('is_submit_product'); - } else if (isset($capability_settings['is_submit_product'])) { - unset($capability_settings['is_submit_product']); - } - if ($is_published_product) { - $capability_settings['is_published_product'] = array('is_published_product'); - } else if (isset($capability_settings['is_published_product'])) { - unset($capability_settings['is_published_product']); - } - if ($is_edit_delete_published_product) { - $capability_settings['is_edit_delete_published_product'] = array('is_edit_delete_published_product'); - } else if (isset($capability_settings['is_edit_delete_published_product'])) { - unset($capability_settings['is_edit_delete_published_product']); - } - if ($is_submit_coupon) { - $capability_settings['is_submit_coupon'] = array('is_submit_coupon'); - } else if (isset($capability_settings['is_submit_coupon'])) { - unset($capability_settings['is_submit_coupon']); - } - if ($is_published_coupon) { - $capability_settings['is_published_coupon'] = array('is_published_coupon'); - } else if (isset($capability_settings['is_published_coupon'])) { - unset($capability_settings['is_published_coupon']); - } - if ($is_edit_delete_published_coupon) { - $capability_settings['is_edit_delete_published_coupon'] = array('is_edit_delete_published_coupon'); - } else if (isset($capability_settings['is_edit_delete_published_coupon'])) { - unset($capability_settings['is_edit_delete_published_coupon']); - } - if ($is_upload_files) { - $capability_settings['is_upload_files'] = array('is_upload_files'); - } else if (isset($capability_settings['is_upload_files'])) { - unset($capability_settings['is_upload_files']); - } - mvx_update_option('mvx_products_capability_tab_settings', $capability_settings); - $MVX->vendor_caps->update_mvx_vendor_role_capability(); - wp_redirect(esc_url_raw($this->get_next_step_link())); - exit; - } + // return add_query_arg('step', $keys[$step_index + 1]); + // } /** * Migration Introduction step. */ - public function mvx_migration_introduction() { - global $MVX; - $MVX->multivendor_migration->mvx_migration_first_step( $this->get_next_step_link() ); - } + // public function mvx_migration_introduction() { + // global $MVX; + // $MVX->multivendor_migration->mvx_migration_first_step( $this->get_next_step_link() ); + // } - public function mvx_migration_store_process() { - global $MVX; - $MVX->multivendor_migration->mvx_migration_third_step( $this->get_next_step_link() ); - } + // public function mvx_migration_store_process() { + // global $MVX; + // $MVX->multivendor_migration->mvx_migration_third_step( $this->get_next_step_link() ); + // } - /** - * Setup Wizard Footer. - */ - public function setup_wizard_footer() { - if ('next_steps' === $this->step) : - ?> - - - - - array( - 'label' => __('Paypal Masspay', 'multivendorx'), - 'description' => __('Pay via paypal masspay', 'multivendorx'), - 'class' => 'featured featured-row-last' - ), - 'paypal_payout' => array( - 'label' => __('Paypal Payout', 'multivendorx'), - 'description' => __('Pay via paypal payout', 'multivendorx'), - 'class' => 'featured featured-row-first' - ), - 'direct_bank' => array( - 'label' => __('Direct Bank Transfer', 'multivendorx'), - 'description' => __('', 'multivendorx'), - 'class' => '' - ), - 'stripe_masspay' => array( - 'label' => __('Stripe Connect', 'multivendorx'), - 'description' => __('', 'multivendorx'), - 'class' => '' - ) - ); - return $methods; - } } \ No newline at end of file diff --git a/classes/MultiVendorX.php b/classes/MultiVendorX.php index 95a091e9..4a95e56f 100644 --- a/classes/MultiVendorX.php +++ b/classes/MultiVendorX.php @@ -17,8 +17,6 @@ final class MultiVendorX { private static $instance = null; private $file = ''; - private $plugin_url = ''; - private $plugin_path = ''; private $container = []; /** @@ -27,8 +25,10 @@ final class MultiVendorX { */ public function __construct($file) { $this->file = $file; - $this->plugin_url = trailingslashit(plugins_url('', $file)); - $this->plugin_path = trailingslashit(dirname($file)); + $this->container[ 'plugin_url' ] = trailingslashit( plugins_url( '', $file ) ); + $this->container[ 'plugin_path' ] = trailingslashit( dirname( $file ) ); + $this->container[ 'version' ] = MVX_PLUGIN_VERSION; + $this->container[ 'rest_namespace' ] = MVX_REST_NAMESPACE; register_activation_hook( $file, [ $this, 'activate' ] ); register_deactivation_hook( $file, [ $this, 'deactivate' ] ); @@ -113,7 +113,8 @@ public function init_classes() { $this->container['utility'] = new Utility\Utility(); $this->container['order'] = new Order\OrderManager(); $this->container['commission'] = new Commission\CommissionManager(); - $this->container['gateways'] = new Gateways\GatewaysManager(); + $this->container['gateways'] = new Gateways\GatewaysManager(); + $this->container['restapi'] = new Rest(); } diff --git a/classes/Rest.php b/classes/Rest.php new file mode 100644 index 00000000..20fb2857 --- /dev/null +++ b/classes/Rest.php @@ -0,0 +1,1040 @@ +rest_namespace, '/get_store', [ + 'methods' => \WP_REST_Server::READABLE, + 'callback' => [ $this, 'store_settings' ], + 'permission_callback' => [ $this, 'permissions_check' ], + ] ); + + register_rest_route( MVX()->rest_namespace, '/set_store', [ + 'methods' => \WP_REST_Server::EDITABLE, + 'callback' => [ $this, 'save_store_settings' ], + 'permission_callback' => [ $this, 'permissions_check' ], + ] ); + + register_rest_route( MVX()->rest_namespace, '/get_commission_setting', [ + 'methods' => \WP_REST_Server::READABLE, + 'callback' => [ $this, 'get_commission_setting' ], + 'permission_callback' => [ $this, 'permissions_check' ], + ] ); + + register_rest_route( MVX()->rest_namespace, '/set_commission_setting', [ + 'methods' => \WP_REST_Server::EDITABLE, + 'callback' => [ $this, 'set_commission_setting' ], + 'permission_callback' => [ $this, 'permissions_check' ], + ] ); + + register_rest_route( MVX()->rest_namespace, '/get_payment_setting', [ + 'methods' => \WP_REST_Server::READABLE, + 'callback' => [ $this, 'get_payment_setting' ], + 'permission_callback' => [ $this, 'permissions_check' ], + ] ); + + register_rest_route( MVX()->rest_namespace, '/set_payment_setting', [ + 'methods' => \WP_REST_Server::EDITABLE, + 'callback' => [ $this, 'set_payment_setting' ], + 'permission_callback' => [ $this, 'permissions_check' ], + ] ); + + register_rest_route( MVX()->rest_namespace, '/get_capability_setting', [ + 'methods' => \WP_REST_Server::READABLE, + 'callback' => [ $this, 'get_capability_setting' ], + 'permission_callback' => [ $this, 'permissions_check' ], + ] ); + + register_rest_route( MVX()->rest_namespace, '/set_capability_setting', [ + 'methods' => \WP_REST_Server::EDITABLE, + 'callback' => [ $this, 'set_capability_setting' ], + 'permission_callback' => [ $this, 'permissions_check' ], + ] ); + + register_rest_route( MVX()->rest_namespace, '/get_active_plugins', [ + 'methods' => \WP_REST_Server::READABLE, + 'callback' => [ $this, 'get_active_plugins' ], + 'permission_callback' => [ $this, 'permissions_check' ], + ] ); + + register_rest_route( MVX()->rest_namespace, '/import_dummy_data', [ + 'methods' => \WP_REST_Server::EDITABLE, + 'callback' => [ $this, 'import_dummy_data' ], + 'permission_callback' => [ $this, 'permissions_check' ], + ] ); + + register_rest_route( MVX()->rest_namespace, '/install_woocommerce', [ + 'methods' => \WP_REST_Server::READABLE, + 'callback' => [ $this, 'install_woocommerce' ], + 'permission_callback' => [ $this, 'permissions_check' ], + ] ); + } + + function store_settings( $request ){ + $nonce = $request->get_header('X-WP-Nonce'); + if (!wp_verify_nonce($nonce, 'wp_rest')) { + return new \WP_Error('rest_invalid_nonce', __('Invalid nonce', 'multivendorx'), array('status' => 403)); + } + + $permalinks = mvx_get_option('dc_vendors_permalinks'); + $vendor_slug = empty($permalinks['vendor_shop_base']) ? _x('', 'slug', 'multivendorx') : $permalinks['vendor_shop_base']; + $is_single_product_multiple_vendor = get_mvx_global_settings('is_singleproductmultiseller') ? 'Enable' : ''; + $data = array( + 'vendor_slug' => $vendor_slug, + 'is_single_product_multiple_vendor' => $is_single_product_multiple_vendor, + 'site_url' => site_url() + ); + + return rest_ensure_response( $data ); + } + + function save_store_settings( $request ){ + $nonce = $request->get_header('X-WP-Nonce'); + if (!wp_verify_nonce($nonce, 'wp_rest')) { + return new \WP_Error('rest_invalid_nonce', __('Invalid nonce', 'multivendorx'), array('status' => 403)); + } + + $general_settings = mvx_get_option('mvx_spmv_pages_tab_settings') ? mvx_get_option('mvx_spmv_pages_tab_settings') : array(); + $vendor_permalink = $request->get_param('vendor_store_url'); + $is_single_product_multiple_vendor = $request->get_param('is_single_product_multiple_vendor'); + + if ($is_single_product_multiple_vendor) { + $general_settings['is_singleproductmultiseller'] = array('is_singleproductmultiseller'); + } else if (isset($general_settings['is_singleproductmultiseller'])) { + unset($general_settings['is_singleproductmultiseller']); + } + + mvx_update_option('mvx_spmv_pages_tab_settings', $general_settings); + if ($vendor_permalink) { + $permalinks = mvx_get_option('dc_vendors_permalinks', array()); + $permalinks['vendor_shop_base'] = untrailingslashit($vendor_permalink); + mvx_update_option('dc_vendors_permalinks', $permalinks); + flush_rewrite_rules(); + } + + return rest_ensure_response(array( + 'success' => true, + 'message' => __('Store settings updated successfully.', 'multivendorx'), + )); + } + + public function get_commission_setting( $request ){ + $nonce = $request->get_header('X-WP-Nonce'); + if (!wp_verify_nonce($nonce, 'wp_rest')) { + return new \WP_Error('rest_invalid_nonce', __('Invalid nonce', 'multivendorx'), array('status' => 403)); + } + $payment_settings = mvx_get_option('mvx_commissions_tab_settings'); + + if(isset($payment_settings['revenue_sharing_mode'])){ + $revenue_sharing_mode = $payment_settings['revenue_sharing_mode']; + }else{ + $revenue_sharing_mode = 'revenue_sharing_mode_vendor'; + } + + if( isset($payment_settings['commission_type']['value']) ){ + $commission_type = $payment_settings['commission_type']['value']; + }else{ + $commission_type = 'percent'; + } + + if( isset($payment_settings['default_commission'][0]['value']) ){ + if( $commission_type === 'fixed' ){ + $fixed = $payment_settings['default_commission'][0]['value']; + $percentage = ''; + }elseif( $commission_type === 'percent' ){ + $fixed = ''; + $percentage = $payment_settings['default_commission'][0]['value']; + }else{ + $fixed = $payment_settings['default_commission'][1]['value']; + $percentage = $payment_settings['default_commission'][0]['value']; + } + } + + $data = array( + 'revenue_sharing_mode'=> $revenue_sharing_mode, + 'commission_type' => $commission_type, + 'fixed' => $fixed, + 'percentage' => $percentage + ); + + return rest_ensure_response( $data ); + } + + public function set_commission_setting( $request ){ + $nonce = $request->get_header('X-WP-Nonce'); + if (!wp_verify_nonce($nonce, 'wp_rest')) { + return new \WP_Error('rest_invalid_nonce', __('Invalid nonce', 'multivendorx'), array('status' => 403)); + } + + $payment_settings = mvx_get_option('mvx_commissions_tab_settings'); + $revenue_sharing_mode = $request->get_param('revenue_sharing_mode'); + $commission_type = $request->get_param('commission_type'); + $default_commission = $request->get_param('fixed'); + $default_percentage = $request->get_param('percentage'); + + if ($revenue_sharing_mode) { + $payment_settings['revenue_sharing_mode'] = $revenue_sharing_mode; + } + if ($commission_type) { + switch($commission_type){ + case 'fixed': + $payment_settings['commission_type'] = array( + 'value'=> __('fixed', 'multivendorx'), + 'label'=> __('Fixed Amount', 'multivendorx'), + 'index'=> 1, + ); + $payment_settings['default_commission'] = $default_commission; + $payment_settings['default_commission'] = array( + 0 => array ( + 'key' => 'fixed_ammount', + 'value' => $default_commission, + ) + ); + break; + + case 'percent': + $payment_settings['commission_type'] = array( + 'value'=> __('percent', 'multivendorx'), + 'label'=> __('Percentage', 'multivendorx'), + 'index'=> 2, + ); + $payment_settings['default_percentage'] = $default_percentage; + $payment_settings['default_commission'] = array( + 0 => array ( + 'key' => 'percent_amount', + 'value' => $default_percentage + ) + ); + break; + + case 'fixed_with_percentage': + $payment_settings['commission_type'] = array( + 'value'=> __('fixed_with_percentage', 'multivendorx'), + 'label'=> __('%age + Fixed (per transaction)', 'multivendorx'), + 'index'=> 3, + ); + $payment_settings['fixed_with_percentage'] = $default_commission; + $payment_settings['default_commission'] = array( + 0 => array ( + 'key' => 'percent_amount', + 'value' => $default_percentage + ), + 1 => array ( + 'key' => 'percent_amount', + 'value' => $default_commission + ) + ); + break; + + case 'fixed_with_percentage_qty': + $payment_settings['commission_type'] = array( + 'value'=> __('fixed_with_percentage_qty', 'multivendorx'), + 'label'=> __('%age + Fixed (per unit)', 'multivendorx'), + 'index'=> 4, + ); + $payment_settings['fixed_with_percentage_qty'] = $default_commission; + $payment_settings['default_commission'] = array( + 0 => array ( + 'key' => 'fixed_ammount', + 'value' => $default_percentage + ), + 1 => array ( + 'key' => 'percent_amount', + 'value' => $default_commission + ) + ); + break; + } + } + mvx_update_option('mvx_commissions_tab_settings', $payment_settings); + + return rest_ensure_response(array( + 'success' => true, + 'message' => __('Commission settings updated successfully.', 'multivendorx'), + )); + } + + public function get_payment_setting( $request ){ + $nonce = $request->get_header('X-WP-Nonce'); + if (!wp_verify_nonce($nonce, 'wp_rest')) { + return new \WP_Error('rest_invalid_nonce', __('Invalid nonce', 'multivendorx'), array('status' => 403)); + } + + $disbursement_settings = mvx_get_option('mvx_disbursement_tab_settings'); + $mvx_disbursal_mode_admin = isset($disbursement_settings['choose_payment_mode_automatic_disbursal']); + if ( isset($disbursement_settings['payment_schedule']) ){ + $payment_schedule = $disbursement_settings['payment_schedule']; + }else{ + $payment_schedule = 'monthly'; + } + $mvx_disbursal_mode_vendor = isset($disbursement_settings['withdrawal_request']); + $is_enable_gateway = array( + 'paypal_masspay'=> mvx_is_module_active('paypal_masspay'), + 'paypal_payout' => mvx_is_module_active('paypal_payout'), + 'direct_bank' => mvx_is_module_active('direct_bank'), + 'stripe_masspay'=> mvx_is_module_active('stripe_masspay'), + + ); + $data = array( + 'mvx_disbursal_mode_admin' => $mvx_disbursal_mode_admin, + 'payment_schedule' => $payment_schedule, + 'mvx_disbursal_mode_vendor' => $mvx_disbursal_mode_vendor, + 'is_enable_gateway' => $is_enable_gateway, + ); + + return rest_ensure_response( $data ); + } + + public function set_payment_setting( $request ) { + $nonce = $request->get_header('X-WP-Nonce'); + if (!wp_verify_nonce($nonce, 'wp_rest')) { + return new \WP_Error('rest_invalid_nonce', __('Invalid nonce', 'multivendorx'), array('status' => 403)); + } + + $gateways = $this->get_payment_methods(); + $active_module_list = mvx_get_option('mvx_all_active_module_list') ? get_option('mvx_all_active_module_list') : array(); + + $disbursement_settings = mvx_get_option('mvx_disbursement_tab_settings'); + $mvx_disbursal_mode_admin = $request->get_param('mvx_disbursal_mode_admin'); + $mvx_disbursal_mode_vendor = $request->get_param('mvx_disbursal_mode_vendor'); + $is_module_active = $request->get_param('is_module_active'); + + if ($mvx_disbursal_mode_admin) { + $disbursement_settings['choose_payment_mode_automatic_disbursal'] = array('choose_payment_mode_automatic_disbursal'); + $payment_schedule = $request->get_param('payment_schedule'); + if ($payment_schedule) { + $disbursement_settings['payment_schedule'] = $payment_schedule; + $schedule = wp_get_schedule('masspay_cron_start'); + if ($schedule != $payment_schedule) { + if (wp_next_scheduled('masspay_cron_start')) { + $timestamp = wp_next_scheduled('masspay_cron_start'); + wp_unschedule_event($timestamp, 'masspay_cron_start'); + } + wp_schedule_event(time(), $payment_schedule, 'masspay_cron_start'); + } + } + } else if (isset($disbursement_settings['choose_payment_mode_automatic_disbursal'])) { + unset($disbursement_settings['choose_payment_mode_automatic_disbursal']); + if (wp_next_scheduled('masspay_cron_start')) { + $timestamp = wp_next_scheduled('masspay_cron_start'); + wp_unschedule_event($timestamp, 'masspay_cron_start'); + } + } + + if ($mvx_disbursal_mode_vendor) { + $disbursement_settings['withdrawal_request'] = array('withdrawal_request'); + } else if (isset($disbursement_settings['withdrawal_request'])) { + unset($disbursement_settings['withdrawal_request']); + } + + foreach ($gateways as $gateway_id => $gateway) { + $is_enable_gateway = $is_module_active[$gateway_id]; + if ($is_enable_gateway) { + array_push($active_module_list, $gateway_id); + if (!empty($gateway['repo-slug'])) { + wp_schedule_single_event(time() + 10, 'woocommerce_plugin_background_installer', array($gateway_id, $gateway)); + } + } else if (mvx_is_module_active($gateway_id)) { + if (($key = array_search($gateway_id, $active_module_list)) !== false) { + unset($active_module_list[$key]); + } + } + } + + mvx_update_option( 'mvx_all_active_module_list', $active_module_list ); + mvx_update_option('mvx_disbursement_tab_settings', $disbursement_settings); + + return rest_ensure_response(array( + 'success' => true, + 'message' => __('Payment settings updated successfully.', 'multivendorx'), + )); + } + + function get_capability_setting( $request ){ + $nonce = $request->get_header('X-WP-Nonce'); + if (!wp_verify_nonce($nonce, 'wp_rest')) { + return new \WP_Error('rest_invalid_nonce', __('Invalid nonce', 'multivendorx'), array('status' => 403)); + } + + $capabilities_settings = mvx_get_option('mvx_products_capability_tab_settings'); + $data = array( + 'is_submit_product' => isset($capabilities_settings['is_submit_product']), + 'is_published_product' => isset($capabilities_settings['is_published_product']), + 'is_edit_delete_published_product'=> isset($capabilities_settings['is_edit_delete_published_product']), + 'is_submit_coupon' => isset($capabilities_settings['is_submit_coupon']), + 'is_published_coupon' => isset($capabilities_settings['is_published_coupon']), + 'is_edit_delete_published_coupon' => isset($capabilities_settings['is_edit_delete_published_coupon']), + 'is_upload_files' => isset($capabilities_settings['is_upload_files']), + ); + + return rest_ensure_response( $data ); + } + + public function set_capability_setting( $request ){ + $nonce = $request->get_header('X-WP-Nonce'); + if (!wp_verify_nonce($nonce, 'wp_rest')) { + return new \WP_Error('rest_invalid_nonce', __('Invalid nonce', 'multivendorx'), array('status' => 403)); + } + + global $MVX; + $capability_settings = mvx_get_option('mvx_products_capability_tab_settings') ? mvx_get_option('mvx_products_capability_tab_settings') : array(); + + $is_submit_product = $request->get_param('is_submit_product'); + $is_published_product = $request->get_param('is_published_product'); + $is_edit_delete_published_product = $request->get_param('is_edit_delete_published_product'); + $is_submit_coupon = $request->get_param('is_submit_coupon'); + $is_published_coupon = $request->get_param('is_published_coupon'); + $is_edit_delete_published_coupon = $request->get_param('is_edit_delete_published_coupon'); + $is_upload_files = $request->get_param('is_upload_files'); + + if ($is_submit_product) { + $capability_settings['is_submit_product'] = array('is_submit_product'); + } else if (isset($capability_settings['is_submit_product'])) { + unset($capability_settings['is_submit_product']); + } + if ($is_published_product) { + $capability_settings['is_published_product'] = array('is_published_product'); + } else if (isset($capability_settings['is_published_product'])) { + unset($capability_settings['is_published_product']); + } + if ($is_edit_delete_published_product) { + $capability_settings['is_edit_delete_published_product'] = array('is_edit_delete_published_product'); + } else if (isset($capability_settings['is_edit_delete_published_product'])) { + unset($capability_settings['is_edit_delete_published_product']); + } + if ($is_submit_coupon) { + $capability_settings['is_submit_coupon'] = array('is_submit_coupon'); + } else if (isset($capability_settings['is_submit_coupon'])) { + unset($capability_settings['is_submit_coupon']); + } + if ($is_published_coupon) { + $capability_settings['is_published_coupon'] = array('is_published_coupon'); + } else if (isset($capability_settings['is_published_coupon'])) { + unset($capability_settings['is_published_coupon']); + } + if ($is_edit_delete_published_coupon) { + $capability_settings['is_edit_delete_published_coupon'] = array('is_edit_delete_published_coupon'); + } else if (isset($capability_settings['is_edit_delete_published_coupon'])) { + unset($capability_settings['is_edit_delete_published_coupon']); + } + if ($is_upload_files) { + $capability_settings['is_upload_files'] = array('is_upload_files'); + } else if (isset($capability_settings['is_upload_files'])) { + unset($capability_settings['is_upload_files']); + } + mvx_update_option('mvx_products_capability_tab_settings', $capability_settings); + $MVX->vendor_caps->update_mvx_vendor_role_capability(); + + return rest_ensure_response(array( + 'success' => true, + 'message' => __('Capability settings updated successfully.', 'multivendorx'), + )); + } + + public function get_active_plugins( $request ){ + $nonce = $request->get_header('X-WP-Nonce'); + if (!wp_verify_nonce($nonce, 'wp_rest')) { + return new \WP_Error('rest_invalid_nonce', __('Invalid nonce', 'multivendorx'), array('status' => 403)); + } + + $data = array( + 'booking' => is_plugin_active('woocommerce-bookings/woocommerce-bookings.php'), + 'subscription' => is_plugin_active('woocommerce-subscriptions/woocommerce-subscriptions.php'), + 'rental' => is_plugin_active('woocommerce-rental-and-booking/redq-rental-and-bookings.php'), + 'auction' => is_plugin_active('woocommerce-simple-auctions/woocommerce-simple-auctions.php') + ); + + return rest_ensure_response( $data ); + } + + public function import_dummy_data( $request ){ + $nonce = $request->get_header('X-WP-Nonce'); + if (!wp_verify_nonce($nonce, 'wp_rest')) { + return new \WP_Error('rest_invalid_nonce', __('Invalid nonce', 'multivendorx'), array('status' => 403)); + } + + $marketplace_type = $request->get_param('marketplace_type'); + + $this->import_vendors(); + $product_ids = $this->import_products( $marketplace_type ); + $this->import_commissions(); + if( $product_ids ){ + $this->import_orders( $product_ids, $marketplace_type ); + $this->import_reviews($product_ids); + } + + return rest_ensure_response(array( + 'success' => true, + 'message' => __('Dummy data imported successfully.', 'multivendorx'), + )); + } + + /** + * Import the Dummy vendors + */ + public function import_vendors(){ + // load the vendor data xml file + $xml = simplexml_load_file( MVX_PLUGIN_DUMMY_DATA . '/vendors.xml' ); + if( ! $xml ){ + return; + } + + // importing vendors + foreach( $xml->vendor as $vendor){ + $userdata = array( + 'user_login' => (string) $vendor->username, + 'user_pass' => (string) $vendor->password, + 'user_email' => (string) $vendor->email, + 'user_nicename' => (string) $vendor->nickname, + 'first_name' => (string) $vendor->firstname, + 'last_name' => (string) $vendor->lastname, + 'role' => 'dc_vendor', + ); + + $user_id = wp_insert_user( $userdata ) ; + + if ( is_wp_error( $user_id ) ) { + return; + } + + foreach( $vendor->images->image as $image ){ + $src = plugins_url( $image->src ); + $upload = wc_rest_upload_image_from_url( esc_url_raw($src) ); + + if( is_wp_error( $upload )){ + continue; + } + $attachment_id = wc_rest_set_uploaded_image_as_attachment( $upload, $user_id ); + + if ( wp_attachment_is_image( $attachment_id ) ) { + $parent = get_post($attachment_id); + $url = $parent->guid; + + $size = @getimagesize($url); + $image_type = ( $size ) ? $size['mime'] : 'image/jpeg'; + $object = array( + 'ID' => $attachment_id, + 'post_title' => basename($url), + 'post_mime_type' => $image_type, + 'guid' => $url, + 'post_status' => 'inherit', + ); + + $attachment_id = wp_insert_attachment($object, $url); + + $metadata = wp_generate_attachment_metadata($attachment_id, $url); + wp_update_attachment_metadata($attachment_id, $metadata); + + if ( 'store' == $image->position ) { + update_user_meta( $user_id, '_vendor_image', $attachment_id ); + } elseif ( 'cover' == $image->position ) { + update_user_meta( $user_id, '_vendor_banner', $attachment_id ); + } + } + } + } + } + + /** + * Import Dummy products + * @global object $mvx + */ + public function import_products($marketplace_type){ + global $MVX; + + $xml = simplexml_load_file( MVX_PLUGIN_DUMMY_DATA . '//'. $marketplace_type .'_products.xml' ); + if( ! $xml ){ + return; + } + + $product_ids = array(); + + // importing products + foreach( $xml->item as $product){ + + // Get vendor Id + $vendor = get_user_by( 'slug', (string) $product->author ); + if ($vendor) { + $vendor_id = $vendor->ID; + }else { + $vendor = get_user_by( 'slug', 'admin'); + $vendor_id = $vendor->ID; + } + + $product_data = array( + 'post_title' => (string) $product->title, // Product Title + 'post_content' => (string) $product->content, // Product Description + 'post_excerpt' => (string) $product->excerpt, // Short Description + 'post_author' => $vendor_id, // Vendor Id + 'post_name' => (string) $product->post_name, // post name + 'post_status' => (string) $product->status, // Publish the product + 'post_type' => (string) $product->post_type, // WooCommerce product type + ); + + $product_id = wp_insert_post( $product_data ); + + if ( is_wp_error( $product_id ) ) { + return null; + } + // set the product type + wp_set_object_terms( $product_id, (string) $product->product_type, 'product_type' ); + + // Set product vendor + $vendor = get_mvx_vendor( $vendor_id ); + if($vendor){ + wp_set_object_terms( $product_id, absint($vendor->term_id), $MVX->taxonomy->taxonomy_name ); + } + // Set product category + foreach( $product->categories->category as $category){ + $category_name = (string) $category; + $term = term_exists( $category_name, 'product_cat' ); + + // If the category doesn't exist, create it + if ( ! $term ) { + $term = wp_insert_term( $category_name, 'product_cat' ); + } + + if ( ! is_wp_error( $term ) ) { + // Get the term ID + $term_id = is_array( $term ) ? $term['term_id'] : $term; + + // Assign the category to the product + wp_set_object_terms( $product_id, (int)$term_id, 'product_cat', true ); + } + } + + // Set product meta data + foreach( $product->meta->postmeta as $meta){ + update_post_meta( $product_id, (string) $meta->meta_key, (string) $meta->meta_value ); + } + + array_push( $product_ids, $product_id); + + foreach( $product->images->image as $image ){ + $src = plugins_url( $image->src ); + $upload = wc_rest_upload_image_from_url( esc_url_raw($src) ); + + if( is_wp_error( $upload )){ + continue; + } + $attachment_id = wc_rest_set_uploaded_image_as_attachment( $upload ); + + if ( wp_attachment_is_image( $attachment_id ) ) { + $parent = get_post($attachment_id); + $url = $parent->guid; + + $size = @getimagesize($url); + $image_type = ( $size ) ? $size['mime'] : 'image/jpeg'; + $object = array( + 'ID' => $attachment_id, + 'post_title' => basename($url), + 'post_mime_type' => $image_type, + 'guid' => $url, + 'post_status' => 'inherit', + ); + + $attachment_id = wp_insert_attachment($object, $url); + + $metadata = wp_generate_attachment_metadata($attachment_id, $url); + wp_update_attachment_metadata($attachment_id, $metadata); + + update_post_meta( $product_id, '_thumbnail_id', $attachment_id ); + } + } + } + return $product_ids; + } + + /** + * Import commissions data + */ + public function import_commissions(){ + // importing commission structure + $xml = simplexml_load_file( MVX_PLUGIN_DUMMY_DATA . '/commissions.xml' ); + if( ! $xml){ + return; + } + + foreach( $xml->commission as $commission ) { + $category_name = (string) $commission->category; + $term = term_exists( $category_name, 'product_cat' ); + + // If the category doesn't exist, create it + if ( ! $term ) { + $term = wp_insert_term( $category_name, 'product_cat' ); + } + + if ( is_wp_error( $term ) ) { + return; + } + // Get the term ID + $term_id = is_array( $term ) ? $term['term_id'] : $term; + + // Get commission type + $commission_type_value = get_mvx_vendor_settings('commission_type', 'commissions') && !empty(get_mvx_vendor_settings('commission_type', 'commissions')) ? mvx_get_settings_value(get_mvx_vendor_settings('commission_type', 'commissions')) : ''; + if ($commission_type_value) { + switch($commission_type_value){ + case 'fixed': + case 'percent': + add_term_meta( $term_id, 'commision', floatval((string) $commission->value)); + break; + + case 'fixed_with_percentage': + case 'fixed_with_percentage_qty': + add_term_meta( $term_id, 'commission_percentage', floatval((string) $commission->value)); + break; + } + } + } + } + + /** + * Import dummy orders + * @global object $mvx + */ + public function import_orders( $product_ids, $marketplace_type ){ + global $MVX; + $product_ids = array_reverse( $product_ids ); + + // importing orders + $xml = simplexml_load_file( MVX_PLUGIN_DUMMY_DATA . '/orders.xml' ); + if( ! $xml){ + return; + } + + foreach( $xml->order as $order){ + $new_order = wc_create_order(); + $order_id = $new_order->get_id(); + + $product_id = array_pop( $product_ids ); + $quantity = $order->quantity; + $new_order->add_product( wc_get_product( $product_id ), $quantity ); + + $address = array( + 'first_name' => (string) $order->first_name, + 'last_name' => (string) $order->last_name, + 'email' => (string) $order->email, + 'address_1' => (string) $order->address_1, + 'address_2' => (string) $order->address_2, + 'city' => (string) $order->city, + 'state' => (string) $order->state, + 'postcode' => (string) $order->postcode, + 'country' => (string) $order->country, + ); + + $new_order->set_billing_address( $address ); + $new_order->set_shipping_address( $address ); + $order_items = $new_order->get_items(); + $cost = intval(get_post_meta( $product_id, '_wc_booking_block_cost', true )) + intval(get_post_meta( $product_id, '_wc_booking_cost', true )); + + if( $marketplace_type == 'booking' ){ + $props = array( + 'customer_id' => '1', + 'product_id' => $product_id, + 'resource_id' => '', + 'person_counts' => 'a:0:{}', + 'cost' => $cost, + 'start' => strtotime( current_time( 'Y-m-d' ). '00:00:00' ), + 'end' => strtotime( current_time( 'Y-m-d' ). '23:59:59' ), + 'all_day' => 1, + ); + + $booking = new \WC_Booking( $props ); + $booking->set_order_id( $order_id ); + $item = reset( $order_items ); + $item['subtotal'] = $cost; + $item['total'] = $cost; + $item_id = key( $order_items ); + $booking->set_order_item_id( $item_id ); + $booking->set_cost(intval(get_post_meta( $product_id, '_wc_booking_block_cost', true )) + intval(get_post_meta( $product_id, '_wc_booking_cost', true ))); + $booking->set_status( 'unpaid' ); + $booking->save(); + } + + $shipping_item = new \WC_Order_Item_Shipping(); + $shipping_item->set_method_title( 'Free shipping' ); + $shipping_item->set_method_id( 'free shipping' ); + + // Set the shipping cost to 0 + $shipping_item->set_total( 0 ); + + foreach( $order_items as $item_id => $item ){ + $vendor = get_mvx_product_vendors( $item['product_id'] ); + if ($vendor) { + if ( !wc_get_order_item_meta( $item_id, 'Sold by') ) + wc_add_order_item_meta( $item_id, 'Sold by', $vendor->page_title); + if ( !wc_get_order_item_meta( $item_id, '_vendor_id' ) ) + wc_add_order_item_meta( $item_id, '_vendor_id', $vendor->id); + } + } + + // Add the shipping item to the order + $shipping_item->save(); + $new_order->add_item( $shipping_item ); + + $new_order->set_payment_method( (string) $order->payment_method ); + $new_order->set_payment_method_title( (string) $order->payment_method_title ); + + $new_order->update_meta_data('has_mvx_sub_order', true); + $vendor_items = array(); + foreach ($order_items as $item_id => $item) { + $has_vendor = get_mvx_product_vendors($item['product_id']); + if ($has_vendor) { + $variation_id = isset($item['variation_id']) && !empty($item['variation_id']) ? $item['variation_id'] : 0; + $item_commission = $MVX->commission->get_item_commission($item['product_id'], $variation_id, $item, $order_id, $item_id); + $commission_values = $MVX->commission->get_commission_amount($item['product_id'], $has_vendor->term_id, $variation_id, $item_id, $order); + $commission_rate = array('mode' => $MVX->vendor_caps->payment_cap['revenue_sharing_mode'], 'type' => $MVX->vendor_caps->payment_cap['commission_type']); + $commission_rate['commission_val'] = isset($commission_values['commission_val']) ? $commission_values['commission_val'] : 0; + $commission_rate['commission_fixed'] = isset($commission_values['commission_fixed']) ? $commission_values['commission_fixed'] : 0; + $item['commission'] = $item_commission; + $item['commission_rate'] = $commission_rate; + $vendor_items[$has_vendor->id][$item_id] = $item; + } + } + + if (count($vendor_items) != 0){ + // update parent order meta + $new_order->update_meta_data('has_mvx_sub_order', true); + + $order_manager = new OrderManager; + $order_manager->create_vendor_orders( $order_id, $new_order ); + $sub_orders = $order_manager->get_suborders($new_order); + + foreach ($sub_orders as $sub_order) { + $commission_id = \MVX_Commission::create_commission($sub_order); + if ($commission_id) { + // Calculate commission + \MVX_Commission::calculate_commission($commission_id, $sub_order); + // add commission id with associated vendor order + $sub_order->update_meta_data('_commission_id', $commission_id ); + // Mark commissions as processed + $sub_order->update_meta_data('_commissions_processed', 'yes' ); + $sub_order->save(); + } + } + } + + $new_order->calculate_totals(); + $new_order->update_status( 'processing', 'Order imported' ); + $new_order->save(); + } + } + + /** + * Import dummy reviews + */ + public function import_reviews( $product_ids ){ + $product_ids = array_reverse( $product_ids ); + + // importing reviews + $xml = simplexml_load_file( MVX_PLUGIN_DUMMY_DATA . '/reviews.xml' ); + if( ! $xml){ + return; + } + + foreach ( $xml->review as $review ) { + $product_id = array_pop( $product_ids ); + + $comment_data = array( + 'comment_post_ID' => $product_id, + 'comment_author' => (string) $review->reviewer, + 'comment_author_email' => (string) $review->email, + 'comment_content' => (string) $review->comment, + 'comment_type' => 'review', + 'comment_approved' => 1, + ); + + $comment_id = wp_insert_comment( $comment_data ); + + if ( is_wp_error( $comment_id ) ) { + return; + } + update_comment_meta( $comment_id, 'rating', intval( $review->rating ) ); + + $average_rating = intval( get_post_meta( $product_id, '_wc_average_rating', true ) ); + $review_count = intval( get_post_meta( $product_id, '_wc_review_count', true ) ); + + if($review_count == 1){ + $average_rating = intval( $review->rating ); + } else{ + $average_rating = ( ( $average_rating * ( $review_count - 1 ) ) + intval( $review->rating ) ) / $review_count; + } + + update_post_meta( $product_id, '_wc_average_rating', $average_rating ); + } + } + + public function install_woocommerce( $request ){ + $nonce = $request->get_header('X-WP-Nonce'); + if (!wp_verify_nonce($nonce, 'wp_rest')) { + return new \WP_Error('rest_invalid_nonce', __('Invalid nonce', 'multivendorx'), array('status' => 403)); + } + + require_once( ABSPATH . 'wp-admin/includes/file.php' ); + require_once( ABSPATH . 'wp-admin/includes/plugin-install.php' ); + require_once( ABSPATH . 'wp-admin/includes/class-wp-upgrader.php' ); + require_once( ABSPATH . 'wp-admin/includes/plugin.php' ); + + WP_Filesystem(); + $skin = new \Automatic_Upgrader_Skin; + $upgrader = new \WP_Upgrader($skin); + $installed_plugins = array_map([__CLASS__, 'format_plugin_slug'], array_keys(get_plugins())); + $plugin_slug = 'woocommerce'; + $plugin = $plugin_slug . '/' . $plugin_slug . '.php'; + $installed = false; + $activate = false; + // See if the plugin is installed already + if (in_array($plugin_slug, $installed_plugins)) { + $installed = true; + $activate = !is_plugin_active($plugin); + } + // Install this thing! + if (!$installed) { + // Suppress feedback + ob_start(); + + try { + $plugin_information = plugins_api('plugin_information', array( + 'slug' => $plugin_slug, + 'fields' => array( + 'short_description' => false, + 'sections' => false, + 'requires' => false, + 'rating' => false, + 'ratings' => false, + 'downloaded' => false, + 'last_updated' => false, + 'added' => false, + 'tags' => false, + 'homepage' => false, + 'donate_link' => false, + 'author_profile' => false, + 'author' => false, + ), + )); + + if (is_wp_error($plugin_information)) { + throw new \Exception($plugin_information->get_error_message()); + } + + $package = $plugin_information->download_link; + $download = $upgrader->download_package($package); + + if (is_wp_error($download)) { + throw new \Exception($download->get_error_message()); + } + + $working_dir = $upgrader->unpack_package($download, true); + + if (is_wp_error($working_dir)) { + throw new \Exception($working_dir->get_error_message()); + } + + $result = $upgrader->install_package(array( + 'source' => $working_dir, + 'destination' => WP_PLUGIN_DIR, + 'clear_destination' => false, + 'abort_if_destination_exists' => false, + 'clear_working' => true, + 'hook_extra' => array( + 'type' => 'plugin', + 'action' => 'install', + ), + )); + + if (is_wp_error($result)) { + throw new \Exception($result->get_error_message()); + } + + $activate = true; + } catch (\Exception $e) { + printf( + __('%1$s could not be installed (%2$s). Please install it manually by clicking here.', 'multivendorx'), 'WooCommerce', $e->getMessage(), esc_url(admin_url('plugin-install.php?tab=search&s=woocommerce')) + ); + exit(); + } + + // Discard feedback + ob_end_clean(); + } + + wp_clean_plugins_cache(); + // Activate this thing + if ($activate) { + try { + $result = activate_plugin($plugin); + + if (is_wp_error($result)) { + throw new \Exception($result->get_error_message()); + } + } catch (\Exception $e) { + printf( + __('%1$s was installed but could not be activated. Please activate it manually by clicking here.', 'multivendorx'), 'WooCommerce', admin_url('plugins.php') + ); + exit(); + } + } + + return rest_ensure_response(array( + 'success' => true, + 'message' => __('Woocommerce installed successfully.', 'multivendorx'), + 'redirect' => admin_url('index.php?page=mvx-setup'), + )); + } + + /** + * Get slug from path + * @param string $key + * @return string + */ + private static function format_plugin_slug($key) { + $slug = explode('/', $key); + $slug = explode('.', end($slug)); + return $slug[0]; + } + + public function get_payment_methods() { + $methods = array( + 'paypal_masspay' => array( + 'label' => __('Paypal Masspay', 'multivendorx'), + 'description' => __('Pay via paypal masspay', 'multivendorx'), + 'class' => 'featured featured-row-last' + ), + 'paypal_payout' => array( + 'label' => __('Paypal Payout', 'multivendorx'), + 'description' => __('Pay via paypal payout', 'multivendorx'), + 'class' => 'featured featured-row-first' + ), + 'direct_bank' => array( + 'label' => __('Direct Bank Transfer', 'multivendorx'), + 'description' => __('', 'multivendorx'), + 'class' => '' + ), + 'stripe_masspay' => array( + 'label' => __('Stripe Connect', 'multivendorx'), + 'description' => __('', 'multivendorx'), + //'repo-slug' => 'marketplace-stripe-gateway', + 'class' => '' + ) + ); + return $methods; + } + + public function permissions_check() { + return true; + } +} \ No newline at end of file diff --git a/mvx-config.php b/mvx-config.php index 75238fc2..d7620bb9 100644 --- a/mvx-config.php +++ b/mvx-config.php @@ -7,3 +7,7 @@ define('MVX_SCRIPT_DEBUG', false); define('MVX_PLUGIN_ASSEST', plugins_url( 'assets', __FILE__ )); + +define('MVX_REST_NAMESPACE', 'mvx_module/v1'); + +define('MVX_PLUGIN_DUMMY_DATA', __DIR__.'/assets/dummy-data'); \ No newline at end of file diff --git a/mvx-modules/build/block.json b/mvx-modules/build/block.json new file mode 100644 index 00000000..71b7ddc3 --- /dev/null +++ b/mvx-modules/build/block.json @@ -0,0 +1,8 @@ +{ + "$schema": "https://schemas.wp.org/trunk/block.json", + "apiVersion": 2, + "name": "simple-example/simple-block", + "version": "1.0.0", + "title": "SIMPLE BLOCK", + "editorScript": "file:./index.js" +} \ No newline at end of file diff --git a/mvx-modules/build/blocks/setupWizard/block.json b/mvx-modules/build/blocks/setupWizard/block.json new file mode 100644 index 00000000..71b7ddc3 --- /dev/null +++ b/mvx-modules/build/blocks/setupWizard/block.json @@ -0,0 +1,8 @@ +{ + "$schema": "https://schemas.wp.org/trunk/block.json", + "apiVersion": 2, + "name": "simple-example/simple-block", + "version": "1.0.0", + "title": "SIMPLE BLOCK", + "editorScript": "file:./index.js" +} \ No newline at end of file diff --git a/mvx-modules/build/blocks/setupWizard/index.asset.php b/mvx-modules/build/blocks/setupWizard/index.asset.php new file mode 100644 index 00000000..cd317637 --- /dev/null +++ b/mvx-modules/build/blocks/setupWizard/index.asset.php @@ -0,0 +1 @@ + array('react', 'react-dom', 'wp-element'), 'version' => '4f24dc72515f9d69ecbf'); diff --git a/mvx-modules/build/blocks/setupWizard/index.js b/mvx-modules/build/blocks/setupWizard/index.js new file mode 100644 index 00000000..2cfc6bd0 --- /dev/null +++ b/mvx-modules/build/blocks/setupWizard/index.js @@ -0,0 +1 @@ +(()=>{"use strict";var e={679:(e,t,n)=>{var r=n(296),o={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},i={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},a={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},s={};function l(e){return r.isMemo(e)?a:s[e.$$typeof]||o}s[r.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},s[r.Memo]=a;var c=Object.defineProperty,u=Object.getOwnPropertyNames,d=Object.getOwnPropertySymbols,p=Object.getOwnPropertyDescriptor,f=Object.getPrototypeOf,m=Object.prototype;e.exports=function e(t,n,r){if("string"!=typeof n){if(m){var o=f(n);o&&o!==m&&e(t,o,r)}var a=u(n);d&&(a=a.concat(d(n)));for(var s=l(t),h=l(n),g=0;g{var n="function"==typeof Symbol&&Symbol.for,r=n?Symbol.for("react.element"):60103,o=n?Symbol.for("react.portal"):60106,i=n?Symbol.for("react.fragment"):60107,a=n?Symbol.for("react.strict_mode"):60108,s=n?Symbol.for("react.profiler"):60114,l=n?Symbol.for("react.provider"):60109,c=n?Symbol.for("react.context"):60110,u=n?Symbol.for("react.async_mode"):60111,d=n?Symbol.for("react.concurrent_mode"):60111,p=n?Symbol.for("react.forward_ref"):60112,f=n?Symbol.for("react.suspense"):60113,m=n?Symbol.for("react.suspense_list"):60120,h=n?Symbol.for("react.memo"):60115,g=n?Symbol.for("react.lazy"):60116,b=n?Symbol.for("react.block"):60121,v=n?Symbol.for("react.fundamental"):60117,y=n?Symbol.for("react.responder"):60118,E=n?Symbol.for("react.scope"):60119;function w(e){if("object"==typeof e&&null!==e){var t=e.$$typeof;switch(t){case r:switch(e=e.type){case u:case d:case i:case s:case a:case f:return e;default:switch(e=e&&e.$$typeof){case c:case p:case g:case h:case l:return e;default:return t}}case o:return t}}}function C(e){return w(e)===d}t.AsyncMode=u,t.ConcurrentMode=d,t.ContextConsumer=c,t.ContextProvider=l,t.Element=r,t.ForwardRef=p,t.Fragment=i,t.Lazy=g,t.Memo=h,t.Portal=o,t.Profiler=s,t.StrictMode=a,t.Suspense=f,t.isAsyncMode=function(e){return C(e)||w(e)===u},t.isConcurrentMode=C,t.isContextConsumer=function(e){return w(e)===c},t.isContextProvider=function(e){return w(e)===l},t.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===r},t.isForwardRef=function(e){return w(e)===p},t.isFragment=function(e){return w(e)===i},t.isLazy=function(e){return w(e)===g},t.isMemo=function(e){return w(e)===h},t.isPortal=function(e){return w(e)===o},t.isProfiler=function(e){return w(e)===s},t.isStrictMode=function(e){return w(e)===a},t.isSuspense=function(e){return w(e)===f},t.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===i||e===d||e===s||e===a||e===f||e===m||"object"==typeof e&&null!==e&&(e.$$typeof===g||e.$$typeof===h||e.$$typeof===l||e.$$typeof===c||e.$$typeof===p||e.$$typeof===v||e.$$typeof===y||e.$$typeof===E||e.$$typeof===b)},t.typeOf=w},296:(e,t,n)=>{e.exports=n(103)}},t={};function n(r){var o=t[r];if(void 0!==o)return o.exports;var i=t[r]={exports:{}};return e[r](i,i.exports,n),i.exports}(()=>{const e=window.wp.element,t=window.React;function r(){return r=Object.assign?Object.assign.bind():function(e){for(var t=1;t=0&&(t.hash=e.substr(n),e=e.substr(0,n));let r=e.indexOf("?");r>=0&&(t.search=e.substr(r),e=e.substr(0,r)),e&&(t.pathname=e)}return t}var p;!function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"}(p||(p={})),new Set(["lazy","caseSensitive","path","id","index","children"]),Error;const f=["post","put","patch","delete"],m=(new Set(f),["get",...f]);new Set(m),new Set([301,302,303,307,308]),new Set([307,308]),Symbol("deferred");const h=t.createContext(null),g=t.createContext(null);function b(e){let{basename:n="/",children:r=null,location:i,navigationType:a=o.Pop,navigator:l,static:c=!1}=e;null!=t.useContext(g)&&s(!1);let u=n.replace(/^\/*/,"/"),p=t.useMemo((()=>({basename:u,navigator:l,static:c})),[u,l,c]);"string"==typeof i&&(i=d(i));let{pathname:f="/",search:m="",hash:b="",state:v=null,key:y="default"}=i,E=t.useMemo((()=>{let e=function(e,t){if("/"===t)return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith("/")?t.length-1:t.length,r=e.charAt(n);return r&&"/"!==r?null:e.slice(n)||"/"}(f,u);return null==e?null:{location:{pathname:e,search:m,hash:b,state:v,key:y},navigationType:a}}),[u,f,m,b,v,y,a]);return null==E?null:t.createElement(h.Provider,{value:p},t.createElement(g.Provider,{children:r,value:E}))}t.Component,t.startTransition,new Promise((()=>{})),t.Component,new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);const v=t.startTransition;var y,E,w,C;function M(t){return(0,e.createElement)("div",{className:t.wrapperClass},(0,e.createElement)("input",{className:t.inputClass,type:t.type,value:t.value,onClick:e=>{t.onClick(e)}}),t.proSetting&&(0,e.createElement)("span",{className:"admin-pro-tag"},"pro"),t.description&&(0,e.createElement)("p",{className:t.descClass,dangerouslySetInnerHTML:{__html:t.description}}))}"undefined"!=typeof window&&void 0!==window.document&&window.document.createElement,(C=y||(y={})).UseScrollRestoration="useScrollRestoration",C.UseSubmit="useSubmit",C.UseSubmitFetcher="useSubmitFetcher",C.UseFetcher="useFetcher",(w=E||(E={})).UseFetchers="useFetchers",w.UseScrollRestoration="useScrollRestoration";const S=t=>(0,e.createElement)(e.Fragment,null,(0,e.createElement)("h1",null,"Welcome to the MultivendorX family!"),(0,e.createElement)("p",null,"Thank you for choosing MultivendorX! This quick setup wizard will help you configure the basic settings and you will have your marketplace ready in no time. ",(0,e.createElement)("strong",null,"It’s completely optional and shouldn’t take longer than five minutes.")),(0,e.createElement)("p",null,"If you don't want to go through the wizard right now, you can skip and return to the WordPress dashboard. Come back anytime if you change your mind!"),(0,e.createElement)("p",{className:"wc-setup-actions step"},(0,e.createElement)(M,{inputClass:"button button-large",type:"button",value:"Not right now",onClick:t.exitWizard}),(0,e.createElement)(M,{inputClass:"btn red-btn button button-large button-next",type:"button",value:"Let's go!",onClick:t.onNext})));function x(e,t){return function(){return e.apply(t,arguments)}}const{toString:L}=Object.prototype,{getPrototypeOf:I}=Object,N=(O=Object.create(null),e=>{const t=L.call(e);return O[t]||(O[t]=t.slice(8,-1).toLowerCase())});var O;const k=e=>(e=e.toLowerCase(),t=>N(t)===e),j=e=>t=>typeof t===e,{isArray:T}=Array,D=j("undefined"),_=k("ArrayBuffer"),P=j("string"),R=j("function"),A=j("number"),F=e=>null!==e&&"object"==typeof e,z=e=>{if("object"!==N(e))return!1;const t=I(e);return!(null!==t&&t!==Object.prototype&&null!==Object.getPrototypeOf(t)||Symbol.toStringTag in e||Symbol.iterator in e)},V=k("Date"),U=k("File"),B=k("Blob"),H=k("FileList"),Q=k("URLSearchParams");function W(e,t,{allOwnKeys:n=!1}={}){if(null==e)return;let r,o;if("object"!=typeof e&&(e=[e]),T(e))for(r=0,o=e.length;r0;)if(r=n[o],t===r.toLowerCase())return r;return null}const Y="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:global,G=e=>!D(e)&&e!==Y,$=(Z="undefined"!=typeof Uint8Array&&I(Uint8Array),e=>Z&&e instanceof Z);var Z;const X=k("HTMLFormElement"),q=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),K=k("RegExp"),ee=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};W(n,((n,o)=>{!1!==t(n,o,e)&&(r[o]=n)})),Object.defineProperties(e,r)},te="abcdefghijklmnopqrstuvwxyz",ne="0123456789",re={DIGIT:ne,ALPHA:te,ALPHA_DIGIT:te+te.toUpperCase()+ne},oe=k("AsyncFunction"),ie={isArray:T,isArrayBuffer:_,isBuffer:function(e){return null!==e&&!D(e)&&null!==e.constructor&&!D(e.constructor)&&R(e.constructor.isBuffer)&&e.constructor.isBuffer(e)},isFormData:e=>{let t;return e&&("function"==typeof FormData&&e instanceof FormData||R(e.append)&&("formdata"===(t=N(e))||"object"===t&&R(e.toString)&&"[object FormData]"===e.toString()))},isArrayBufferView:function(e){let t;return t="undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&_(e.buffer),t},isString:P,isNumber:A,isBoolean:e=>!0===e||!1===e,isObject:F,isPlainObject:z,isUndefined:D,isDate:V,isFile:U,isBlob:B,isRegExp:K,isFunction:R,isStream:e=>F(e)&&R(e.pipe),isURLSearchParams:Q,isTypedArray:$,isFileList:H,forEach:W,merge:function e(){const{caseless:t}=G(this)&&this||{},n={},r=(r,o)=>{const i=t&&J(n,o)||o;z(n[i])&&z(r)?n[i]=e(n[i],r):z(r)?n[i]=e({},r):T(r)?n[i]=r.slice():n[i]=r};for(let e=0,t=arguments.length;e(W(t,((t,r)=>{n&&R(t)?e[r]=x(t,n):e[r]=t}),{allOwnKeys:r}),e),trim:e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,""),stripBOM:e=>(65279===e.charCodeAt(0)&&(e=e.slice(1)),e),inherits:(e,t,n,r)=>{e.prototype=Object.create(t.prototype,r),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),n&&Object.assign(e.prototype,n)},toFlatObject:(e,t,n,r)=>{let o,i,a;const s={};if(t=t||{},null==e)return t;do{for(o=Object.getOwnPropertyNames(e),i=o.length;i-- >0;)a=o[i],r&&!r(a,e,t)||s[a]||(t[a]=e[a],s[a]=!0);e=!1!==n&&I(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},kindOf:N,kindOfTest:k,endsWith:(e,t,n)=>{e=String(e),(void 0===n||n>e.length)&&(n=e.length),n-=t.length;const r=e.indexOf(t,n);return-1!==r&&r===n},toArray:e=>{if(!e)return null;if(T(e))return e;let t=e.length;if(!A(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},forEachEntry:(e,t)=>{const n=(e&&e[Symbol.iterator]).call(e);let r;for(;(r=n.next())&&!r.done;){const n=r.value;t.call(e,n[0],n[1])}},matchAll:(e,t)=>{let n;const r=[];for(;null!==(n=e.exec(t));)r.push(n);return r},isHTMLForm:X,hasOwnProperty:q,hasOwnProp:q,reduceDescriptors:ee,freezeMethods:e=>{ee(e,((t,n)=>{if(R(e)&&-1!==["arguments","caller","callee"].indexOf(n))return!1;const r=e[n];R(r)&&(t.enumerable=!1,"writable"in t?t.writable=!1:t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")}))}))},toObjectSet:(e,t)=>{const n={},r=e=>{e.forEach((e=>{n[e]=!0}))};return T(e)?r(e):r(String(e).split(t)),n},toCamelCase:e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,(function(e,t,n){return t.toUpperCase()+n})),noop:()=>{},toFiniteNumber:(e,t)=>(e=+e,Number.isFinite(e)?e:t),findKey:J,global:Y,isContextDefined:G,ALPHABET:re,generateString:(e=16,t=re.ALPHA_DIGIT)=>{let n="";const{length:r}=t;for(;e--;)n+=t[Math.random()*r|0];return n},isSpecCompliantForm:function(e){return!!(e&&R(e.append)&&"FormData"===e[Symbol.toStringTag]&&e[Symbol.iterator])},toJSONObject:e=>{const t=new Array(10),n=(e,r)=>{if(F(e)){if(t.indexOf(e)>=0)return;if(!("toJSON"in e)){t[r]=e;const o=T(e)?[]:{};return W(e,((e,t)=>{const i=n(e,r+1);!D(i)&&(o[t]=i)})),t[r]=void 0,o}}return e};return n(e,0)},isAsyncFn:oe,isThenable:e=>e&&(F(e)||R(e))&&R(e.then)&&R(e.catch)};function ae(e,t,n,r,o){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=(new Error).stack,this.message=e,this.name="AxiosError",t&&(this.code=t),n&&(this.config=n),r&&(this.request=r),o&&(this.response=o)}ie.inherits(ae,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:ie.toJSONObject(this.config),code:this.code,status:this.response&&this.response.status?this.response.status:null}}});const se=ae.prototype,le={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach((e=>{le[e]={value:e}})),Object.defineProperties(ae,le),Object.defineProperty(se,"isAxiosError",{value:!0}),ae.from=(e,t,n,r,o,i)=>{const a=Object.create(se);return ie.toFlatObject(e,a,(function(e){return e!==Error.prototype}),(e=>"isAxiosError"!==e)),ae.call(a,e.message,t,n,r,o),a.cause=e,a.name=e.name,i&&Object.assign(a,i),a};const ce=ae;function ue(e){return ie.isPlainObject(e)||ie.isArray(e)}function de(e){return ie.endsWith(e,"[]")?e.slice(0,-2):e}function pe(e,t,n){return e?e.concat(t).map((function(e,t){return e=de(e),!n&&t?"["+e+"]":e})).join(n?".":""):t}const fe=ie.toFlatObject(ie,{},null,(function(e){return/^is[A-Z]/.test(e)})),me=function(e,t,n){if(!ie.isObject(e))throw new TypeError("target must be an object");t=t||new FormData;const r=(n=ie.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,(function(e,t){return!ie.isUndefined(t[e])}))).metaTokens,o=n.visitor||c,i=n.dots,a=n.indexes,s=(n.Blob||"undefined"!=typeof Blob&&Blob)&&ie.isSpecCompliantForm(t);if(!ie.isFunction(o))throw new TypeError("visitor must be a function");function l(e){if(null===e)return"";if(ie.isDate(e))return e.toISOString();if(!s&&ie.isBlob(e))throw new ce("Blob is not supported. Use a Buffer instead.");return ie.isArrayBuffer(e)||ie.isTypedArray(e)?s&&"function"==typeof Blob?new Blob([e]):Buffer.from(e):e}function c(e,n,o){let s=e;if(e&&!o&&"object"==typeof e)if(ie.endsWith(n,"{}"))n=r?n:n.slice(0,-2),e=JSON.stringify(e);else if(ie.isArray(e)&&function(e){return ie.isArray(e)&&!e.some(ue)}(e)||(ie.isFileList(e)||ie.endsWith(n,"[]"))&&(s=ie.toArray(e)))return n=de(n),s.forEach((function(e,r){!ie.isUndefined(e)&&null!==e&&t.append(!0===a?pe([n],r,i):null===a?n:n+"[]",l(e))})),!1;return!!ue(e)||(t.append(pe(o,n,i),l(e)),!1)}const u=[],d=Object.assign(fe,{defaultVisitor:c,convertValue:l,isVisitable:ue});if(!ie.isObject(e))throw new TypeError("data must be an object");return function e(n,r){if(!ie.isUndefined(n)){if(-1!==u.indexOf(n))throw Error("Circular reference detected in "+r.join("."));u.push(n),ie.forEach(n,(function(n,i){!0===(!(ie.isUndefined(n)||null===n)&&o.call(t,n,ie.isString(i)?i.trim():i,r,d))&&e(n,r?r.concat(i):[i])})),u.pop()}}(e),t};function he(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,(function(e){return t[e]}))}function ge(e,t){this._pairs=[],e&&me(e,this,t)}const be=ge.prototype;be.append=function(e,t){this._pairs.push([e,t])},be.toString=function(e){const t=e?function(t){return e.call(this,t,he)}:he;return this._pairs.map((function(e){return t(e[0])+"="+t(e[1])}),"").join("&")};const ve=ge;function ye(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function Ee(e,t,n){if(!t)return e;const r=n&&n.encode||ye,o=n&&n.serialize;let i;if(i=o?o(t,n):ie.isURLSearchParams(t)?t.toString():new ve(t,n).toString(r),i){const t=e.indexOf("#");-1!==t&&(e=e.slice(0,t)),e+=(-1===e.indexOf("?")?"?":"&")+i}return e}const we=class{constructor(){this.handlers=[]}use(e,t,n){return this.handlers.push({fulfilled:e,rejected:t,synchronous:!!n&&n.synchronous,runWhen:n?n.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){ie.forEach(this.handlers,(function(t){null!==t&&e(t)}))}},Ce={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},Me={isBrowser:!0,classes:{URLSearchParams:"undefined"!=typeof URLSearchParams?URLSearchParams:ve,FormData:"undefined"!=typeof FormData?FormData:null,Blob:"undefined"!=typeof Blob?Blob:null},isStandardBrowserEnv:(()=>{let e;return("undefined"==typeof navigator||"ReactNative"!==(e=navigator.product)&&"NativeScript"!==e&&"NS"!==e)&&"undefined"!=typeof window&&"undefined"!=typeof document})(),isStandardBrowserWebWorkerEnv:"undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope&&"function"==typeof self.importScripts,protocols:["http","https","file","blob","url","data"]},Se=function(e){function t(e,n,r,o){let i=e[o++];const a=Number.isFinite(+i),s=o>=e.length;return i=!i&&ie.isArray(r)?r.length:i,s?(ie.hasOwnProp(r,i)?r[i]=[r[i],n]:r[i]=n,!a):(r[i]&&ie.isObject(r[i])||(r[i]=[]),t(e,n,r[i],o)&&ie.isArray(r[i])&&(r[i]=function(e){const t={},n=Object.keys(e);let r;const o=n.length;let i;for(r=0;r{t(function(e){return ie.matchAll(/\w+|\[(\w*)]/g,e).map((e=>"[]"===e[0]?"":e[1]||e[0]))}(e),r,n,0)})),n}return null},xe={"Content-Type":void 0},Le={transitional:Ce,adapter:["xhr","http"],transformRequest:[function(e,t){const n=t.getContentType()||"",r=n.indexOf("application/json")>-1,o=ie.isObject(e);if(o&&ie.isHTMLForm(e)&&(e=new FormData(e)),ie.isFormData(e))return r&&r?JSON.stringify(Se(e)):e;if(ie.isArrayBuffer(e)||ie.isBuffer(e)||ie.isStream(e)||ie.isFile(e)||ie.isBlob(e))return e;if(ie.isArrayBufferView(e))return e.buffer;if(ie.isURLSearchParams(e))return t.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let i;if(o){if(n.indexOf("application/x-www-form-urlencoded")>-1)return function(e,t){return me(e,new Me.classes.URLSearchParams,Object.assign({visitor:function(e,t,n,r){return Me.isNode&&ie.isBuffer(e)?(this.append(t,e.toString("base64")),!1):r.defaultVisitor.apply(this,arguments)}},t))}(e,this.formSerializer).toString();if((i=ie.isFileList(e))||n.indexOf("multipart/form-data")>-1){const t=this.env&&this.env.FormData;return me(i?{"files[]":e}:e,t&&new t,this.formSerializer)}}return o||r?(t.setContentType("application/json",!1),function(e,t,n){if(ie.isString(e))try{return(0,JSON.parse)(e),ie.trim(e)}catch(e){if("SyntaxError"!==e.name)throw e}return(0,JSON.stringify)(e)}(e)):e}],transformResponse:[function(e){const t=this.transitional||Le.transitional,n=t&&t.forcedJSONParsing,r="json"===this.responseType;if(e&&ie.isString(e)&&(n&&!this.responseType||r)){const n=!(t&&t.silentJSONParsing)&&r;try{return JSON.parse(e)}catch(e){if(n){if("SyntaxError"===e.name)throw ce.from(e,ce.ERR_BAD_RESPONSE,this,null,this.response);throw e}}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Me.classes.FormData,Blob:Me.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};ie.forEach(["delete","get","head"],(function(e){Le.headers[e]={}})),ie.forEach(["post","put","patch"],(function(e){Le.headers[e]=ie.merge(xe)}));const Ie=Le,Ne=ie.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),Oe=Symbol("internals");function ke(e){return e&&String(e).trim().toLowerCase()}function je(e){return!1===e||null==e?e:ie.isArray(e)?e.map(je):String(e)}function Te(e,t,n,r,o){return ie.isFunction(r)?r.call(this,t,n):(o&&(t=n),ie.isString(t)?ie.isString(r)?-1!==t.indexOf(r):ie.isRegExp(r)?r.test(t):void 0:void 0)}class De{constructor(e){e&&this.set(e)}set(e,t,n){const r=this;function o(e,t,n){const o=ke(t);if(!o)throw new Error("header name must be a non-empty string");const i=ie.findKey(r,o);(!i||void 0===r[i]||!0===n||void 0===n&&!1!==r[i])&&(r[i||t]=je(e))}const i=(e,t)=>ie.forEach(e,((e,n)=>o(e,n,t)));return ie.isPlainObject(e)||e instanceof this.constructor?i(e,t):ie.isString(e)&&(e=e.trim())&&!/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim())?i((e=>{const t={};let n,r,o;return e&&e.split("\n").forEach((function(e){o=e.indexOf(":"),n=e.substring(0,o).trim().toLowerCase(),r=e.substring(o+1).trim(),!n||t[n]&&Ne[n]||("set-cookie"===n?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+", "+r:r)})),t})(e),t):null!=e&&o(t,e,n),this}get(e,t){if(e=ke(e)){const n=ie.findKey(this,e);if(n){const e=this[n];if(!t)return e;if(!0===t)return function(e){const t=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=n.exec(e);)t[r[1]]=r[2];return t}(e);if(ie.isFunction(t))return t.call(this,e,n);if(ie.isRegExp(t))return t.exec(e);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,t){if(e=ke(e)){const n=ie.findKey(this,e);return!(!n||void 0===this[n]||t&&!Te(0,this[n],n,t))}return!1}delete(e,t){const n=this;let r=!1;function o(e){if(e=ke(e)){const o=ie.findKey(n,e);!o||t&&!Te(0,n[o],o,t)||(delete n[o],r=!0)}}return ie.isArray(e)?e.forEach(o):o(e),r}clear(e){const t=Object.keys(this);let n=t.length,r=!1;for(;n--;){const o=t[n];e&&!Te(0,this[o],o,e,!0)||(delete this[o],r=!0)}return r}normalize(e){const t=this,n={};return ie.forEach(this,((r,o)=>{const i=ie.findKey(n,o);if(i)return t[i]=je(r),void delete t[o];const a=e?function(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,((e,t,n)=>t.toUpperCase()+n))}(o):String(o).trim();a!==o&&delete t[o],t[a]=je(r),n[a]=!0})),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const t=Object.create(null);return ie.forEach(this,((n,r)=>{null!=n&&!1!==n&&(t[r]=e&&ie.isArray(n)?n.join(", "):n)})),t}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map((([e,t])=>e+": "+t)).join("\n")}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...t){const n=new this(e);return t.forEach((e=>n.set(e))),n}static accessor(e){const t=(this[Oe]=this[Oe]={accessors:{}}).accessors,n=this.prototype;function r(e){const r=ke(e);t[r]||(function(e,t){const n=ie.toCamelCase(" "+t);["get","set","has"].forEach((r=>{Object.defineProperty(e,r+n,{value:function(e,n,o){return this[r].call(this,t,e,n,o)},configurable:!0})}))}(n,e),t[r]=!0)}return ie.isArray(e)?e.forEach(r):r(e),this}}De.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),ie.freezeMethods(De.prototype),ie.freezeMethods(De);const _e=De;function Pe(e,t){const n=this||Ie,r=t||n,o=_e.from(r.headers);let i=r.data;return ie.forEach(e,(function(e){i=e.call(n,i,o.normalize(),t?t.status:void 0)})),o.normalize(),i}function Re(e){return!(!e||!e.__CANCEL__)}function Ae(e,t,n){ce.call(this,null==e?"canceled":e,ce.ERR_CANCELED,t,n),this.name="CanceledError"}ie.inherits(Ae,ce,{__CANCEL__:!0});const Fe=Ae,ze=Me.isStandardBrowserEnv?{write:function(e,t,n,r,o,i){const a=[];a.push(e+"="+encodeURIComponent(t)),ie.isNumber(n)&&a.push("expires="+new Date(n).toGMTString()),ie.isString(r)&&a.push("path="+r),ie.isString(o)&&a.push("domain="+o),!0===i&&a.push("secure"),document.cookie=a.join("; ")},read:function(e){const t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove:function(e){this.write(e,"",Date.now()-864e5)}}:{write:function(){},read:function(){return null},remove:function(){}};function Ve(e,t){return e&&!/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)?function(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}(e,t):t}const Ue=Me.isStandardBrowserEnv?function(){const e=/(msie|trident)/i.test(navigator.userAgent),t=document.createElement("a");let n;function r(n){let r=n;return e&&(t.setAttribute("href",r),r=t.href),t.setAttribute("href",r),{href:t.href,protocol:t.protocol?t.protocol.replace(/:$/,""):"",host:t.host,search:t.search?t.search.replace(/^\?/,""):"",hash:t.hash?t.hash.replace(/^#/,""):"",hostname:t.hostname,port:t.port,pathname:"/"===t.pathname.charAt(0)?t.pathname:"/"+t.pathname}}return n=r(window.location.href),function(e){const t=ie.isString(e)?r(e):e;return t.protocol===n.protocol&&t.host===n.host}}():function(){return!0};function Be(e,t){let n=0;const r=function(e,t){e=e||10;const n=new Array(e),r=new Array(e);let o,i=0,a=0;return t=void 0!==t?t:1e3,function(s){const l=Date.now(),c=r[a];o||(o=l),n[i]=s,r[i]=l;let u=a,d=0;for(;u!==i;)d+=n[u++],u%=e;if(i=(i+1)%e,i===a&&(a=(a+1)%e),l-o{const i=o.loaded,a=o.lengthComputable?o.total:void 0,s=i-n,l=r(s);n=i;const c={loaded:i,total:a,progress:a?i/a:void 0,bytes:s,rate:l||void 0,estimated:l&&a&&i<=a?(a-i)/l:void 0,event:o};c[t?"download":"upload"]=!0,e(c)}}const He="undefined"!=typeof XMLHttpRequest&&function(e){return new Promise((function(t,n){let r=e.data;const o=_e.from(e.headers).normalize(),i=e.responseType;let a;function s(){e.cancelToken&&e.cancelToken.unsubscribe(a),e.signal&&e.signal.removeEventListener("abort",a)}ie.isFormData(r)&&(Me.isStandardBrowserEnv||Me.isStandardBrowserWebWorkerEnv?o.setContentType(!1):o.setContentType("multipart/form-data;",!1));let l=new XMLHttpRequest;if(e.auth){const t=e.auth.username||"",n=e.auth.password?unescape(encodeURIComponent(e.auth.password)):"";o.set("Authorization","Basic "+btoa(t+":"+n))}const c=Ve(e.baseURL,e.url);function u(){if(!l)return;const r=_e.from("getAllResponseHeaders"in l&&l.getAllResponseHeaders());!function(e,t,n){const r=n.config.validateStatus;n.status&&r&&!r(n.status)?t(new ce("Request failed with status code "+n.status,[ce.ERR_BAD_REQUEST,ce.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n)):e(n)}((function(e){t(e),s()}),(function(e){n(e),s()}),{data:i&&"text"!==i&&"json"!==i?l.response:l.responseText,status:l.status,statusText:l.statusText,headers:r,config:e,request:l}),l=null}if(l.open(e.method.toUpperCase(),Ee(c,e.params,e.paramsSerializer),!0),l.timeout=e.timeout,"onloadend"in l?l.onloadend=u:l.onreadystatechange=function(){l&&4===l.readyState&&(0!==l.status||l.responseURL&&0===l.responseURL.indexOf("file:"))&&setTimeout(u)},l.onabort=function(){l&&(n(new ce("Request aborted",ce.ECONNABORTED,e,l)),l=null)},l.onerror=function(){n(new ce("Network Error",ce.ERR_NETWORK,e,l)),l=null},l.ontimeout=function(){let t=e.timeout?"timeout of "+e.timeout+"ms exceeded":"timeout exceeded";const r=e.transitional||Ce;e.timeoutErrorMessage&&(t=e.timeoutErrorMessage),n(new ce(t,r.clarifyTimeoutError?ce.ETIMEDOUT:ce.ECONNABORTED,e,l)),l=null},Me.isStandardBrowserEnv){const t=(e.withCredentials||Ue(c))&&e.xsrfCookieName&&ze.read(e.xsrfCookieName);t&&o.set(e.xsrfHeaderName,t)}void 0===r&&o.setContentType(null),"setRequestHeader"in l&&ie.forEach(o.toJSON(),(function(e,t){l.setRequestHeader(t,e)})),ie.isUndefined(e.withCredentials)||(l.withCredentials=!!e.withCredentials),i&&"json"!==i&&(l.responseType=e.responseType),"function"==typeof e.onDownloadProgress&&l.addEventListener("progress",Be(e.onDownloadProgress,!0)),"function"==typeof e.onUploadProgress&&l.upload&&l.upload.addEventListener("progress",Be(e.onUploadProgress)),(e.cancelToken||e.signal)&&(a=t=>{l&&(n(!t||t.type?new Fe(null,e,l):t),l.abort(),l=null)},e.cancelToken&&e.cancelToken.subscribe(a),e.signal&&(e.signal.aborted?a():e.signal.addEventListener("abort",a)));const d=function(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}(c);d&&-1===Me.protocols.indexOf(d)?n(new ce("Unsupported protocol "+d+":",ce.ERR_BAD_REQUEST,e)):l.send(r||null)}))},Qe={http:null,xhr:He};ie.forEach(Qe,((e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch(e){}Object.defineProperty(e,"adapterName",{value:t})}}));function We(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Fe(null,e)}function Je(e){return We(e),e.headers=_e.from(e.headers),e.data=Pe.call(e,e.transformRequest),-1!==["post","put","patch"].indexOf(e.method)&&e.headers.setContentType("application/x-www-form-urlencoded",!1),(e=>{e=ie.isArray(e)?e:[e];const{length:t}=e;let n,r;for(let o=0;oe instanceof _e?e.toJSON():e;function Ge(e,t){t=t||{};const n={};function r(e,t,n){return ie.isPlainObject(e)&&ie.isPlainObject(t)?ie.merge.call({caseless:n},e,t):ie.isPlainObject(t)?ie.merge({},t):ie.isArray(t)?t.slice():t}function o(e,t,n){return ie.isUndefined(t)?ie.isUndefined(e)?void 0:r(void 0,e,n):r(e,t,n)}function i(e,t){if(!ie.isUndefined(t))return r(void 0,t)}function a(e,t){return ie.isUndefined(t)?ie.isUndefined(e)?void 0:r(void 0,e):r(void 0,t)}function s(n,o,i){return i in t?r(n,o):i in e?r(void 0,n):void 0}const l={url:i,method:i,data:i,baseURL:a,transformRequest:a,transformResponse:a,paramsSerializer:a,timeout:a,timeoutMessage:a,withCredentials:a,adapter:a,responseType:a,xsrfCookieName:a,xsrfHeaderName:a,onUploadProgress:a,onDownloadProgress:a,decompress:a,maxContentLength:a,maxBodyLength:a,beforeRedirect:a,transport:a,httpAgent:a,httpsAgent:a,cancelToken:a,socketPath:a,responseEncoding:a,validateStatus:s,headers:(e,t)=>o(Ye(e),Ye(t),!0)};return ie.forEach(Object.keys(Object.assign({},e,t)),(function(r){const i=l[r]||o,a=i(e[r],t[r],r);ie.isUndefined(a)&&i!==s||(n[r]=a)})),n}const $e={};["object","boolean","number","function","string","symbol"].forEach(((e,t)=>{$e[e]=function(n){return typeof n===e||"a"+(t<1?"n ":" ")+e}}));const Ze={};$e.transitional=function(e,t,n){function r(e,t){return"[Axios v1.4.0] Transitional option '"+e+"'"+t+(n?". "+n:"")}return(n,o,i)=>{if(!1===e)throw new ce(r(o," has been removed"+(t?" in "+t:"")),ce.ERR_DEPRECATED);return t&&!Ze[o]&&(Ze[o]=!0,console.warn(r(o," has been deprecated since v"+t+" and will be removed in the near future"))),!e||e(n,o,i)}};const Xe={assertOptions:function(e,t,n){if("object"!=typeof e)throw new ce("options must be an object",ce.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let o=r.length;for(;o-- >0;){const i=r[o],a=t[i];if(a){const t=e[i],n=void 0===t||a(t,i,e);if(!0!==n)throw new ce("option "+i+" must be "+n,ce.ERR_BAD_OPTION_VALUE)}else if(!0!==n)throw new ce("Unknown option "+i,ce.ERR_BAD_OPTION)}},validators:$e},qe=Xe.validators;class Ke{constructor(e){this.defaults=e,this.interceptors={request:new we,response:new we}}request(e,t){"string"==typeof e?(t=t||{}).url=e:t=e||{},t=Ge(this.defaults,t);const{transitional:n,paramsSerializer:r,headers:o}=t;let i;void 0!==n&&Xe.assertOptions(n,{silentJSONParsing:qe.transitional(qe.boolean),forcedJSONParsing:qe.transitional(qe.boolean),clarifyTimeoutError:qe.transitional(qe.boolean)},!1),null!=r&&(ie.isFunction(r)?t.paramsSerializer={serialize:r}:Xe.assertOptions(r,{encode:qe.function,serialize:qe.function},!0)),t.method=(t.method||this.defaults.method||"get").toLowerCase(),i=o&&ie.merge(o.common,o[t.method]),i&&ie.forEach(["delete","get","head","post","put","patch","common"],(e=>{delete o[e]})),t.headers=_e.concat(i,o);const a=[];let s=!0;this.interceptors.request.forEach((function(e){"function"==typeof e.runWhen&&!1===e.runWhen(t)||(s=s&&e.synchronous,a.unshift(e.fulfilled,e.rejected))}));const l=[];let c;this.interceptors.response.forEach((function(e){l.push(e.fulfilled,e.rejected)}));let u,d=0;if(!s){const e=[Je.bind(this),void 0];for(e.unshift.apply(e,a),e.push.apply(e,l),u=e.length,c=Promise.resolve(t);d{if(!n._listeners)return;let t=n._listeners.length;for(;t-- >0;)n._listeners[t](e);n._listeners=null})),this.promise.then=e=>{let t;const r=new Promise((e=>{n.subscribe(e),t=e})).then(e);return r.cancel=function(){n.unsubscribe(t)},r},e((function(e,r,o){n.reason||(n.reason=new Fe(e,r,o),t(n.reason))}))}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){this.reason?e(this.reason):this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;const t=this._listeners.indexOf(e);-1!==t&&this._listeners.splice(t,1)}static source(){let e;return{token:new tt((function(t){e=t})),cancel:e}}}const nt=tt,rt={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(rt).forEach((([e,t])=>{rt[t]=e}));const ot=rt,it=function e(t){const n=new et(t),r=x(et.prototype.request,n);return ie.extend(r,et.prototype,n,{allOwnKeys:!0}),ie.extend(r,n,null,{allOwnKeys:!0}),r.create=function(n){return e(Ge(t,n))},r}(Ie);it.Axios=et,it.CanceledError=Fe,it.CancelToken=nt,it.isCancel=Re,it.VERSION="1.4.0",it.toFormData=me,it.AxiosError=ce,it.Cancel=it.CanceledError,it.all=function(e){return Promise.all(e)},it.spread=function(e){return function(t){return e.apply(null,t)}},it.isAxiosError=function(e){return ie.isObject(e)&&!0===e.isAxiosError},it.mergeConfig=Ge,it.AxiosHeaders=_e,it.formToJSON=e=>Se(ie.isHTMLForm(e)?new FormData(e):e),it.HttpStatusCode=ot,it.default=it;const at=it,st=(e,t=null,n=null)=>`${n=n||appLocalizer.apiUrl}/${t=t||"mvx_module/v1"}/${e}`,lt=t=>(0,e.createElement)(e.Fragment,null,(0,e.createElement)("div",{className:t.wrapperClass},(0,e.createElement)("input",{className:t.inputClass,id:t.id,key:t.key,type:t.type||"text",name:t.name||"basic-input",value:t.value,placeholder:t.placeholder,onChange:e=>{t.onChange?.(e)},onClick:e=>{t.onClick?.(e)},onMouseOver:e=>{t.onMouseOver?.(e)},onMouseOut:e=>{t.onMouseOut?.(e)},onFocus:e=>{t.onFocus?.(e)}}),t.proSetting&&(0,e.createElement)("span",{className:"admin-pro-tag"},"pro"),t.description&&(0,e.createElement)("p",{className:t.descClass,dangerouslySetInnerHTML:{__html:t.description}}))),ct=t=>(0,e.createElement)(e.Fragment,null,(0,e.createElement)("div",{className:t.wrapperClass},(0,e.createElement)("input",{className:t.inputClass,id:t.id,key:t.key,type:t.type||"checkbox",name:t.name||"basic-input",value:t.value,checked:t.checked,onChange:e=>{t.onChange?.(e)},onClick:e=>{t.onClick?.(e)},onMouseOver:e=>{t.onMouseOver?.(e)},onMouseOut:e=>{t.onMouseOut?.(e)}}),t.label&&(0,e.createElement)("label",{htmlFor:`admin-toggle-switch-${t.label}`}),t.proSetting&&(0,e.createElement)("span",{className:"admin-pro-tag"},"pro")),t.description&&(0,e.createElement)("p",{className:t.descClass,dangerouslySetInnerHTML:{__html:t.description}})),ut=n=>{const[r,o]=(0,t.useState)(""),[i,a]=(0,t.useState)(!1),[s,l]=(0,t.useState)("");return(0,t.useEffect)((()=>{at({method:"get",url:st("get_store"),headers:{"X-WP-Nonce":appLocalizer.nonce}}).then((e=>{const{vendor_slug:t,is_single_product_multiple_vendor:n,site_url:r}=e.data;o(t),a("Enable"===n),l(r)})).catch((e=>{console.error("Error fetching store settings:",e)}))}),[]),(0,e.createElement)(e.Fragment,null,(0,e.createElement)("h1",null,"Store setup"),(0,e.createElement)("div",{className:"mvx-setting-section-divider"}," "),(0,e.createElement)("form",{method:"post"},(0,e.createElement)("table",{className:"form-table"},(0,e.createElement)("tr",null,(0,e.createElement)("th",{scope:"row"},(0,e.createElement)("label",{for:"vendor_store_url"},"Store URL")),(0,e.createElement)("td",{className:"mvx-store-setup"},(0,e.createElement)(lt,{onChange:function(e){o(e.target.value)},id:"vendor_store_url",name:"vendor_store_url",placeholder:"vendor",value:r,description:`Define vendor store URL (${s}/[this-text]/[seller-name])`}))),(0,e.createElement)("tr",null,(0,e.createElement)("th",{scope:"row"},(0,e.createElement)("label",{for:"is_single_product_multiple_vendor"},"Single Product Multiple Vendors")),(0,e.createElement)("td",null,(0,e.createElement)(ct,{onChange:function(e){a(!i)},checked:i,name:"is_single_product_multiple_vendor",className:"input-checkbox"})))),(0,e.createElement)("p",{className:"wc-setup-actions step"},(0,e.createElement)(M,{onClick:n.onNext,type:"button",inputClass:"button button-large button-next",value:"Skip this step"}),(0,e.createElement)(M,{onClick:function(e){e.preventDefault();const t={vendor_store_url:r,is_single_product_multiple_vendor:i};at({method:"post",url:st("set_store"),headers:{"X-WP-Nonce":appLocalizer.nonce},data:t}).then((e=>{console.log("Settings saved successfully:",e.data),n.onNext()})).catch((e=>{console.error("Error saving settings:",e.response?e.response.data:e.message)}))},type:"submit",inputClass:"button-primary button button-large button-next",value:"Continue"}))))},dt=t=>(0,e.createElement)("tr",{id:t.id,className:"mvx_commission_type_fields"},(0,e.createElement)("th",{scope:"row"},(0,e.createElement)("label",{htmlFor:t.type},"default_commission"===t.type?"Commission Fixed":"Commission Percentage")),(0,e.createElement)("td",null,(0,e.createElement)(lt,{onChange:e=>t.handler(e.target.value,t.type),id:t.type,name:t.type,value:t.value}))),pt=t=>(0,e.createElement)(e.Fragment,null,(0,e.createElement)("div",{className:t.wrapperClass},(0,e.createElement)("div",{className:t.inputWrapperClass},(0,e.createElement)("ul",null,t.options.map((n=>(0,e.createElement)("li",{className:t.inputWrapperClass},(0,e.createElement)("input",{className:t.inputClass,id:`${t.idPrefix}-${n.key}`,key:n.key,type:"radio",name:n.name,checked:t.value==n.value,value:n.value,onChange:e=>{t.onChange(e)}}),(0,e.createElement)("label",{key:n.key,htmlFor:`${t.idPrefix}-${n.key}`},n.label),t.proSetting&&(0,e.createElement)("span",{className:"admin-pro-tag"},"pro")))))),t.description&&(0,e.createElement)("p",{className:t.descClass,dangerouslySetInnerHTML:{__html:t.description}})));function ft(e){return ft="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},ft(e)}function mt(e){var t=function(e,t){if("object"!==ft(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!==ft(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===ft(t)?t:String(t)}function ht(e,t,n){return(t=mt(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function gt(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 bt(e){for(var t=1;te.length)&&(t=e.length);for(var n=0,r=new Array(t);n=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var Ct=["defaultInputValue","defaultMenuIsOpen","defaultValue","inputValue","menuIsOpen","onChange","onInputChange","onMenuClose","onMenuOpen","value"];function Mt(){return Mt=Object.assign?Object.assign.bind():function(e){for(var t=1;t0?Rt(Jt,--Qt):0,Bt--,10===Wt&&(Bt=1,Ut--),Wt}function Zt(){return Wt=Qt2||en(Wt)>3?"":" "}function an(e,t){for(;--t&&Zt()&&!(Wt<48||Wt>102||Wt>57&&Wt<65||Wt>70&&Wt<97););return Kt(e,qt()+(t<6&&32==Xt()&&32==Zt()))}function sn(e){for(;Zt();)switch(Wt){case e:return Qt;case 34:case 39:34!==e&&39!==e&&sn(Wt);break;case 40:41===e&&sn(e);break;case 92:Zt()}return Qt}function ln(e,t){for(;Zt()&&e+Wt!==57&&(e+Wt!==84||47!==Xt()););return"/*"+Kt(t,Qt-1)+"*"+jt(47===e?e:Zt())}function cn(e){for(;!en(Xt());)Zt();return Kt(e,Qt)}var un="-ms-",dn="-moz-",pn="-webkit-",fn="comm",mn="rule",hn="decl",gn="@keyframes";function bn(e,t){for(var n="",r=zt(e),o=0;o0&&Ft(M)-d&&Vt(f>32?Mn(M+";",r,n,d-1):Mn(_t(M," ","")+";",r,n,d-2),l);break;case 59:M+=";";default:if(Vt(C=wn(M,t,n,c,u,o,s,y,E=[],w=[],d),i),123===v)if(0===u)En(M,t,C,C,E,i,d,s,w);else switch(99===p&&110===Rt(M,3)?100:p){case 100:case 108:case 109:case 115:En(e,C,C,r&&Vt(wn(e,C,C,0,0,o,s,y,o,E=[],d),w),o,w,d,s,r?E:w);break;default:En(M,C,C,C,[""],w,0,s,w)}}c=u=f=0,h=b=1,y=M="",d=a;break;case 58:d=1+Ft(M),f=m;default:if(h<1)if(123==v)--h;else if(125==v&&0==h++&&125==$t())continue;switch(M+=jt(v),v*h){case 38:b=u>0?1:(M+="\f",-1);break;case 44:s[c++]=(Ft(M)-1)*b,b=1;break;case 64:45===Xt()&&(M+=rn(Zt())),p=Xt(),u=d=Ft(y=M+=cn(qt())),v++;break;case 45:45===m&&2==Ft(M)&&(h=0)}}return i}function wn(e,t,n,r,o,i,a,s,l,c,u){for(var d=o-1,p=0===o?i:[""],f=zt(p),m=0,h=0,g=0;m0?p[b]+" "+v:_t(v,/&\f/g,p[b])))&&(l[g++]=y);return Yt(e,t,n,0===o?mn:s,l,c,u)}function Cn(e,t,n){return Yt(e,t,n,fn,jt(Wt),At(e,2,-2),0)}function Mn(e,t,n,r){return Yt(e,t,n,hn,At(e,0,r),At(e,r+1,-1),r)}var Sn=function(e,t,n){for(var r=0,o=0;r=o,o=Xt(),38===r&&12===o&&(t[n]=1),!en(o);)Zt();return Kt(e,Qt)},xn=new WeakMap,Ln=function(e){if("rule"===e.type&&e.parent&&!(e.length<1)){for(var t=e.value,n=e.parent,r=e.column===n.column&&e.line===n.line;"rule"!==n.type;)if(!(n=n.parent))return;if((1!==e.props.length||58===t.charCodeAt(0)||xn.get(n))&&!r){xn.set(e,!0);for(var o=[],i=function(e,t){return nn(function(e,t){var n=-1,r=44;do{switch(en(r)){case 0:38===r&&12===Xt()&&(t[n]=1),e[n]+=Sn(Qt-1,t,n);break;case 2:e[n]+=rn(r);break;case 4:if(44===r){e[++n]=58===Xt()?"&\f":"",t[n]=e[n].length;break}default:e[n]+=jt(r)}}while(r=Zt());return e}(tn(e),t))}(t,o),a=n.props,s=0,l=0;s6)switch(Rt(e,t+1)){case 109:if(45!==Rt(e,t+4))break;case 102:return _t(e,/(.+:)(.+)-([^]+)/,"$1"+pn+"$2-$3$1"+dn+(108==Rt(e,t+3)?"$3":"$2-$3"))+e;case 115:return~Pt(e,"stretch")?Nn(_t(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(115!==Rt(e,t+1))break;case 6444:switch(Rt(e,Ft(e)-3-(~Pt(e,"!important")&&10))){case 107:return _t(e,":",":"+pn)+e;case 101:return _t(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+pn+(45===Rt(e,14)?"inline-":"")+"box$3$1"+pn+"$2$3$1"+un+"$2box$3")+e}break;case 5936:switch(Rt(e,t+11)){case 114:return pn+e+un+_t(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return pn+e+un+_t(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return pn+e+un+_t(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return pn+e+un+e+e}return e}var On=[function(e,t,n,r){if(e.length>-1&&!e.return)switch(e.type){case hn:e.return=Nn(e.value,e.length);break;case gn:return bn([Gt(e,{value:_t(e.value,"@","@"+pn)})],r);case mn: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 bn([Gt(e,{props:[_t(t,/:(read-\w+)/,":-moz-$1")]})],r);case"::placeholder":return bn([Gt(e,{props:[_t(t,/:(plac\w+)/,":"+pn+"input-$1")]}),Gt(e,{props:[_t(t,/:(plac\w+)/,":-moz-$1")]}),Gt(e,{props:[_t(t,/:(plac\w+)/,un+"input-$1")]})],r)}return""}))}}],kn=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,o,i=e.stylisPlugins||On,a={},s=[];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;n=4;++r,o-=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(o){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)}(o)+l;return{name:c,styles:o,next:Bn}},Wn=!!t.useInsertionEffect&&t.useInsertionEffect,Jn=Wn||function(e){return e()},Yn=(Wn||t.useLayoutEffect,{}.hasOwnProperty),Gn=t.createContext("undefined"!=typeof HTMLElement?kn({key:"css"}):null);Gn.Provider;var $n=function(e){return(0,t.forwardRef)((function(n,r){var o=(0,t.useContext)(Gn);return e(n,o,r)}))},Zn=t.createContext({}),Xn="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",qn=function(e){var t=e.cache,n=e.serialized,r=e.isStringTag;return jn(t,n,r),Jn((function(){return function(e,t,n){jn(e,t,n);var r=e.key+"-"+t.name;if(void 0===e.inserted[t.name]){var o=t;do{e.insert(t===o?"."+r:"",o,e.sheet,!0),o=o.next}while(void 0!==o)}}(t,n,r)})),null},Kn=$n((function(e,n,r){var o=e.css;"string"==typeof o&&void 0!==n.registered[o]&&(o=n.registered[o]);var i=e[Xn],a=[o],s="";"string"==typeof e.className?s=function(e,t,n){var r="";return n.split(" ").forEach((function(n){void 0!==e[n]?t.push(e[n]+";"):r+=n+" "})),r}(n.registered,a,e.className):null!=e.className&&(s=e.className+" ");var l=Qn(a,void 0,t.useContext(Zn));s+=n.key+"-"+l.name;var c={};for(var u in e)Yn.call(e,u)&&"css"!==u&&u!==Xn&&(c[u]=e[u]);return c.ref=r,c.className=s,t.createElement(t.Fragment,null,t.createElement(qn,{cache:n,serialized:l,isStringTag:"string"==typeof i}),t.createElement(i,c))})),er=Kn,tr=(n(679),function(e,n){var r=arguments;if(null==n||!Yn.call(n,"css"))return t.createElement.apply(void 0,r);var o=r.length,i=new Array(o);i[0]=er,i[1]=function(e,t){var n={};for(var r in t)Yn.call(t,r)&&(n[r]=t[r]);return n[Xn]=e,n}(e,n);for(var a=2;ae.concat(t,t+"-start",t+"-end")),[]);const pr=Math.min,fr=Math.max,mr=Math.round,hr=Math.floor,gr=e=>({x:e,y:e});function br(e){return cr(e)?e:e.contextElement}function vr(e){const t=br(e);if(!lr(t))return gr(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:i}=function(e){const t=ir(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=lr(e),i=o?e.offsetWidth:n,a=o?e.offsetHeight:r,s=mr(n)!==i||mr(r)!==a;return s&&(n=i,r=a),{width:n,height:r,$:s}}(t);let a=(i?mr(n.width):n.width)/r,s=(i?mr(n.height):n.height)/o;return a&&Number.isFinite(a)||(a=1),s&&Number.isFinite(s)||(s=1),{x:a,y:s}}const yr=gr(0);function Er(e,t,n){var r,o;if(void 0===t&&(t=!0),"undefined"==typeof CSS||!CSS.supports||!CSS.supports("-webkit-backdrop-filter","none"))return yr;const i=e?or(e):window;return!n||t&&n!==i?yr:{x:(null==(r=i.visualViewport)?void 0:r.offsetLeft)||0,y:(null==(o=i.visualViewport)?void 0:o.offsetTop)||0}}function wr(e,t,n,r){void 0===t&&(t=!1),void 0===n&&(n=!1);const o=e.getBoundingClientRect(),i=br(e);let a=gr(1);t&&(r?cr(r)&&(a=vr(r)):a=vr(e));const s=Er(i,n,r);let l=(o.left+s.x)/a.x,c=(o.top+s.y)/a.y,u=o.width/a.x,d=o.height/a.y;if(i){const e=or(i),t=r&&cr(r)?or(r):r;let n=e.frameElement;for(;n&&r&&t!==e;){const e=vr(n),t=n.getBoundingClientRect(),r=getComputedStyle(n),o=t.left+(n.clientLeft+parseFloat(r.paddingLeft))*e.x,i=t.top+(n.clientTop+parseFloat(r.paddingTop))*e.y;l*=e.x,c*=e.y,u*=e.x,d*=e.y,l+=o,c+=i,n=or(n).frameElement}}return p={width:u,height:d,x:l,y:c},{...p,top:p.y,left:p.x,right:p.x+p.width,bottom:p.y+p.height};var p}function Cr(e){return((ar(e)?e.ownerDocument:e.document)||window.document).documentElement}function Mr(e){const t=function(e){if("html"===sr(e))return e;const t=e.assignedSlot||e.parentNode||ur(e)&&e.host||Cr(e);return ur(t)?t.host:t}(e);return function(e){return["html","body","#document"].includes(sr(e))}(t)?e.ownerDocument?e.ownerDocument.body:e.body:lr(t)&&dr(t)?t:Mr(t)}function Sr(e,t){var n;void 0===t&&(t=[]);const r=Mr(e),o=r===(null==(n=e.ownerDocument)?void 0:n.body),i=or(r);return o?t.concat(i,i.visualViewport||[],dr(r)?r:[]):t.concat(r,Sr(r))}const xr=t.useLayoutEffect;var Lr=["className","clearValue","cx","getStyles","getClassNames","getValue","hasValue","isMulti","isRtl","options","selectOption","selectProps","setValue","theme"],Ir=function(){};function Nr(e,t){return t?"-"===t[0]?e+t:e+"__"+t:e}function Or(e,t){for(var n=arguments.length,r=new Array(n>2?n-2:0),o=2;o-1}function _r(e){return Dr(e)?window.pageYOffset:e.scrollTop}function Pr(e,t){Dr(e)?window.scrollTo(0,t):e.scrollTop=t}function Rr(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:200,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:Ir,o=_r(e),i=t-o,a=0;!function t(){var s=function(e,t,n,r){return n*((e=e/r-1)*e*e+1)+t}(a+=10,o,i,n);Pr(e,s),an.bottom?Pr(e,Math.min(t.offsetTop+t.clientHeight-e.offsetHeight+o,e.scrollHeight)):r.top-o=m)return{placement:"bottom",maxHeight:t};if(S>=m&&!a)return i&&Rr(l,x,I),{placement:"bottom",maxHeight:t};if(!a&&S>=r||a&&C>=r)return i&&Rr(l,x,I),{placement:"bottom",maxHeight:a?C-y:S-y};if("auto"===o||a){var N=t,O=a?w:M;return O>=r&&(N=Math.min(O-y-s,t)),{placement:"top",maxHeight:N}}if("bottom"===o)return i&&Pr(l,x),{placement:"bottom",maxHeight:t};break;case"top":if(w>=m)return{placement:"top",maxHeight:t};if(M>=m&&!a)return i&&Rr(l,L,I),{placement:"top",maxHeight:t};if(!a&&M>=r||a&&w>=r){var k=t;return(!a&&M>=r||a&&w>=r)&&(k=a?w-E:M-E),i&&Rr(l,L,I),{placement:"top",maxHeight:k}}return{placement:"bottom",maxHeight:t};default:throw new Error('Invalid placement provided "'.concat(o,'".'))}return c}({maxHeight:o,menuEl:e,minHeight:r,placement:i,shouldScroll:s&&!t,isFixedPosition:t,controlHeight:b});f(n.maxHeight),g(n.placement),null==c||c(n.placement)}}),[o,i,a,s,r,c,b]),n({ref:u,placerProps:bt(bt({},e),{},{placement:h||Zr(i),maxHeight:p})})},Kr=function(e,t){var n=e.theme,r=n.spacing.baseUnit,o=n.colors;return bt({textAlign:"center"},t?{}:{color:o.neutral40,padding:"".concat(2*r,"px ").concat(3*r,"px")})},eo=Kr,to=Kr,no=["size"],ro=["innerProps","isRtl","size"],oo={name:"8mmkcg",styles:"display:inline-block;fill:currentColor;line-height:1;stroke:currentColor;stroke-width:0"},io=function(e){var t=e.size,n=wt(e,no);return tr("svg",Mt({height:t,width:t,viewBox:"0 0 20 20","aria-hidden":"true",focusable:"false",css:oo},n))},ao=function(e){return tr(io,Mt({size:20},e),tr("path",{d:"M14.348 14.849c-0.469 0.469-1.229 0.469-1.697 0l-2.651-3.030-2.651 3.029c-0.469 0.469-1.229 0.469-1.697 0-0.469-0.469-0.469-1.229 0-1.697l2.758-3.15-2.759-3.152c-0.469-0.469-0.469-1.228 0-1.697s1.228-0.469 1.697 0l2.652 3.031 2.651-3.031c0.469-0.469 1.228-0.469 1.697 0s0.469 1.229 0 1.697l-2.758 3.152 2.758 3.15c0.469 0.469 0.469 1.229 0 1.698z"}))},so=function(e){return tr(io,Mt({size:20},e),tr("path",{d:"M4.516 7.548c0.436-0.446 1.043-0.481 1.576 0l3.908 3.747 3.908-3.747c0.533-0.481 1.141-0.446 1.574 0 0.436 0.445 0.408 1.197 0 1.615-0.406 0.418-4.695 4.502-4.695 4.502-0.217 0.223-0.502 0.335-0.787 0.335s-0.57-0.112-0.789-0.335c0 0-4.287-4.084-4.695-4.502s-0.436-1.17 0-1.615z"}))},lo=function(e,t){var n=e.isFocused,r=e.theme,o=r.spacing.baseUnit,i=r.colors;return bt({label:"indicatorContainer",display:"flex",transition:"color 150ms"},t?{}:{color:n?i.neutral60:i.neutral20,padding:2*o,":hover":{color:n?i.neutral80:i.neutral40}})},co=lo,uo=lo,po=function(){var e=nr.apply(void 0,arguments),t="animation-"+e.name;return{name:t,styles:"@keyframes "+t+"{"+e.styles+"}",anim:1,toString:function(){return"_EMO_"+this.name+"_"+this.styles+"_EMO_"}}}(Yr||(Gr=["\n 0%, 80%, 100% { opacity: 0; }\n 40% { opacity: 1; }\n"],$r||($r=Gr.slice(0)),Yr=Object.freeze(Object.defineProperties(Gr,{raw:{value:Object.freeze($r)}})))),fo=function(e){var t=e.delay,n=e.offset;return tr("span",{css:nr({animation:"".concat(po," 1s ease-in-out ").concat(t,"ms infinite;"),backgroundColor:"currentColor",borderRadius:"1em",display:"inline-block",marginLeft:n?"1em":void 0,height:"1em",verticalAlign:"top",width:"1em"},"","")})},mo=["data"],ho=["innerRef","isDisabled","isHidden","inputClassName"],go={gridArea:"1 / 2",font:"inherit",minWidth:"2px",border:0,margin:0,outline:0,padding:0},bo={flex:"1 1 auto",display:"inline-grid",gridArea:"1 / 1 / 2 / 3",gridTemplateColumns:"0 min-content","&:after":bt({content:'attr(data-value) " "',visibility:"hidden",whiteSpace:"pre"},go)},vo=function(e){return bt({label:"input",color:"inherit",background:0,opacity:e?0:1,width:"100%"},go)},yo=function(e){var t=e.children,n=e.innerProps;return tr("div",n,t)},Eo={ClearIndicator:function(e){var t=e.children,n=e.innerProps;return tr("div",Mt({},Tr(e,"clearIndicator",{indicator:!0,"clear-indicator":!0}),n),t||tr(ao,null))},Control:function(e){var t=e.children,n=e.isDisabled,r=e.isFocused,o=e.innerRef,i=e.innerProps,a=e.menuIsOpen;return tr("div",Mt({ref:o},Tr(e,"control",{control:!0,"control--is-disabled":n,"control--is-focused":r,"control--menu-is-open":a}),i),t)},DropdownIndicator:function(e){var t=e.children,n=e.innerProps;return tr("div",Mt({},Tr(e,"dropdownIndicator",{indicator:!0,"dropdown-indicator":!0}),n),t||tr(so,null))},DownChevron:so,CrossIcon:ao,Group:function(e){var t=e.children,n=e.cx,r=e.getStyles,o=e.getClassNames,i=e.Heading,a=e.headingProps,s=e.innerProps,l=e.label,c=e.theme,u=e.selectProps;return tr("div",Mt({},Tr(e,"group",{group:!0}),s),tr(i,Mt({},a,{selectProps:u,theme:c,getStyles:r,getClassNames:o,cx:n}),l),tr("div",null,t))},GroupHeading:function(e){var t=jr(e);t.data;var n=wt(t,mo);return tr("div",Mt({},Tr(e,"groupHeading",{"group-heading":!0}),n))},IndicatorsContainer:function(e){var t=e.children,n=e.innerProps;return tr("div",Mt({},Tr(e,"indicatorsContainer",{indicators:!0}),n),t)},IndicatorSeparator:function(e){var t=e.innerProps;return tr("span",Mt({},t,Tr(e,"indicatorSeparator",{"indicator-separator":!0})))},Input:function(e){var t=e.cx,n=e.value,r=jr(e),o=r.innerRef,i=r.isDisabled,a=r.isHidden,s=r.inputClassName,l=wt(r,ho);return tr("div",Mt({},Tr(e,"input",{"input-container":!0}),{"data-value":n||""}),tr("input",Mt({className:t({input:!0},s),ref:o,style:vo(a),disabled:i},l)))},LoadingIndicator:function(e){var t=e.innerProps,n=e.isRtl,r=e.size,o=void 0===r?4:r,i=wt(e,ro);return tr("div",Mt({},Tr(bt(bt({},i),{},{innerProps:t,isRtl:n,size:o}),"loadingIndicator",{indicator:!0,"loading-indicator":!0}),t),tr(fo,{delay:0,offset:n}),tr(fo,{delay:160,offset:!0}),tr(fo,{delay:320,offset:!n}))},Menu:function(e){var t=e.children,n=e.innerRef,r=e.innerProps;return tr("div",Mt({},Tr(e,"menu",{menu:!0}),{ref:n},r),t)},MenuList:function(e){var t=e.children,n=e.innerProps,r=e.innerRef,o=e.isMulti;return tr("div",Mt({},Tr(e,"menuList",{"menu-list":!0,"menu-list--is-multi":o}),{ref:r},n),t)},MenuPortal:function(e){var n=e.appendTo,r=e.children,o=e.controlElement,i=e.innerProps,a=e.menuPlacement,s=e.menuPosition,l=(0,t.useRef)(null),c=(0,t.useRef)(null),u=Et((0,t.useState)(Zr(a)),2),d=u[0],p=u[1],f=(0,t.useMemo)((function(){return{setPortalPlacement:p}}),[]),m=Et((0,t.useState)(null),2),h=m[0],g=m[1],b=(0,t.useCallback)((function(){if(o){var e=function(e){var t=e.getBoundingClientRect();return{bottom:t.bottom,height:t.height,left:t.left,right:t.right,top:t.top,width:t.width}}(o),t="fixed"===s?0:window.pageYOffset,n=e[d]+t;n===(null==h?void 0:h.offset)&&e.left===(null==h?void 0:h.rect.left)&&e.width===(null==h?void 0:h.rect.width)||g({offset:n,rect:e})}}),[o,s,d,null==h?void 0:h.offset,null==h?void 0:h.rect.left,null==h?void 0:h.rect.width]);xr((function(){b()}),[b]);var v=(0,t.useCallback)((function(){"function"==typeof c.current&&(c.current(),c.current=null),o&&l.current&&(c.current=function(e,t,n,r){void 0===r&&(r={});const{ancestorScroll:o=!0,ancestorResize:i=!0,elementResize:a=!0,layoutShift:s="function"==typeof IntersectionObserver,animationFrame:l=!1}=r,c=br(e),u=o||i?[...c?Sr(c):[],...Sr(t)]:[];u.forEach((e=>{o&&e.addEventListener("scroll",n,{passive:!0}),i&&e.addEventListener("resize",n)}));const d=c&&s?function(e,t){let n,r=null;const o=Cr(e);function i(){clearTimeout(n),r&&r.disconnect(),r=null}return function a(s,l){void 0===s&&(s=!1),void 0===l&&(l=1),i();const{left:c,top:u,width:d,height:p}=e.getBoundingClientRect();if(s||t(),!d||!p)return;const f=hr(u),m=hr(o.clientWidth-(c+d)),h=hr(o.clientHeight-(u+p)),g=hr(c);let b=!0;r=new IntersectionObserver((e=>{const t=e[0].intersectionRatio;if(t!==l){if(!b)return a();t?a(!1,t):n=setTimeout((()=>{a(!1,1e-7)}),100)}b=!1}),{rootMargin:-f+"px "+-m+"px "+-h+"px "+-g+"px",threshold:fr(0,pr(1,l))||1}),r.observe(e)}(!0),i}(c,n):null;let p,f=null;a&&(f=new ResizeObserver(n),c&&!l&&f.observe(c),f.observe(t));let m=l?wr(e):null;return l&&function t(){const r=wr(e);!m||r.x===m.x&&r.y===m.y&&r.width===m.width&&r.height===m.height||n(),m=r,p=requestAnimationFrame(t)}(),n(),()=>{u.forEach((e=>{o&&e.removeEventListener("scroll",n),i&&e.removeEventListener("resize",n)})),d&&d(),f&&f.disconnect(),f=null,l&&cancelAnimationFrame(p)}}(o,l.current,b,{elementResize:"ResizeObserver"in window}))}),[o,b]);xr((function(){v()}),[v]);var y=(0,t.useCallback)((function(e){l.current=e,v()}),[v]);if(!n&&"fixed"!==s||!h)return null;var E=tr("div",Mt({ref:y},Tr(bt(bt({},e),{},{offset:h.offset,position:s,rect:h.rect}),"menuPortal",{"menu-portal":!0}),i),r);return tr(Xr.Provider,{value:f},n?(0,rr.createPortal)(E,n):E)},LoadingMessage:function(e){var t=e.children,n=void 0===t?"Loading...":t,r=e.innerProps,o=wt(e,Jr);return tr("div",Mt({},Tr(bt(bt({},o),{},{children:n,innerProps:r}),"loadingMessage",{"menu-notice":!0,"menu-notice--loading":!0}),r),n)},NoOptionsMessage:function(e){var t=e.children,n=void 0===t?"No options":t,r=e.innerProps,o=wt(e,Wr);return tr("div",Mt({},Tr(bt(bt({},o),{},{children:n,innerProps:r}),"noOptionsMessage",{"menu-notice":!0,"menu-notice--no-options":!0}),r),n)},MultiValue:function(e){var t=e.children,n=e.components,r=e.data,o=e.innerProps,i=e.isDisabled,a=e.removeProps,s=e.selectProps,l=n.Container,c=n.Label,u=n.Remove;return tr(l,{data:r,innerProps:bt(bt({},Tr(e,"multiValue",{"multi-value":!0,"multi-value--is-disabled":i})),o),selectProps:s},tr(c,{data:r,innerProps:bt({},Tr(e,"multiValueLabel",{"multi-value__label":!0})),selectProps:s},t),tr(u,{data:r,innerProps:bt(bt({},Tr(e,"multiValueRemove",{"multi-value__remove":!0})),{},{"aria-label":"Remove ".concat(t||"option")},a),selectProps:s}))},MultiValueContainer:yo,MultiValueLabel:yo,MultiValueRemove:function(e){var t=e.children,n=e.innerProps;return tr("div",Mt({role:"button"},n),t||tr(ao,{size:14}))},Option:function(e){var t=e.children,n=e.isDisabled,r=e.isFocused,o=e.isSelected,i=e.innerRef,a=e.innerProps;return tr("div",Mt({},Tr(e,"option",{option:!0,"option--is-disabled":n,"option--is-focused":r,"option--is-selected":o}),{ref:i,"aria-disabled":n},a),t)},Placeholder:function(e){var t=e.children,n=e.innerProps;return tr("div",Mt({},Tr(e,"placeholder",{placeholder:!0}),n),t)},SelectContainer:function(e){var t=e.children,n=e.innerProps,r=e.isDisabled,o=e.isRtl;return tr("div",Mt({},Tr(e,"container",{"--is-disabled":r,"--is-rtl":o}),n),t)},SingleValue:function(e){var t=e.children,n=e.isDisabled,r=e.innerProps;return tr("div",Mt({},Tr(e,"singleValue",{"single-value":!0,"single-value--is-disabled":n}),r),t)},ValueContainer:function(e){var t=e.children,n=e.innerProps,r=e.isMulti,o=e.hasValue;return tr("div",Mt({},Tr(e,"valueContainer",{"value-container":!0,"value-container--is-multi":r,"value-container--has-value":o}),n),t)}},wo=Number.isNaN||function(e){return"number"==typeof e&&e!=e};function Co(e,t){if(e.length!==t.length)return!1;for(var n=0;n1?"s":""," ").concat(o.join(","),", selected.");case"select-option":return"option ".concat(r,i?" is disabled. Select another option.":", selected.");default:return""}},onFocus:function(e){var t=e.context,n=e.focused,r=e.options,o=e.label,i=void 0===o?"":o,a=e.selectValue,s=e.isDisabled,l=e.isSelected,c=function(e,t){return e&&e.length?"".concat(e.indexOf(t)+1," of ").concat(e.length):""};if("value"===t&&a)return"value ".concat(i," focused, ").concat(c(a,n),".");if("menu"===t){var u=s?" disabled":"",d="".concat(l?"selected":"focused").concat(u);return"option ".concat(i," ").concat(d,", ").concat(c(r,n),".")}return""},onFilter:function(e){var t=e.inputValue,n=e.resultsMessage;return"".concat(n).concat(t?" for search term "+t:"",".")}},Lo=function(e){var n=e.ariaSelection,r=e.focusedOption,o=e.focusedValue,i=e.focusableOptions,a=e.isFocused,s=e.selectValue,l=e.selectProps,c=e.id,u=l.ariaLiveMessages,d=l.getOptionLabel,p=l.inputValue,f=l.isMulti,m=l.isOptionDisabled,h=l.isSearchable,g=l.menuIsOpen,b=l.options,v=l.screenReaderStatus,y=l.tabSelectsValue,E=l["aria-label"],w=l["aria-live"],C=(0,t.useMemo)((function(){return bt(bt({},xo),u||{})}),[u]),M=(0,t.useMemo)((function(){var e,t="";if(n&&C.onChange){var r=n.option,o=n.options,i=n.removedValue,a=n.removedValues,l=n.value,c=i||r||(e=l,Array.isArray(e)?null:e),u=c?d(c):"",p=o||a||void 0,f=p?p.map(d):[],h=bt({isDisabled:c&&m(c,s),label:u,labels:f},n);t=C.onChange(h)}return t}),[n,C,m,s,d]),S=(0,t.useMemo)((function(){var e="",t=r||o,n=!!(r&&s&&s.includes(r));if(t&&C.onFocus){var a={focused:t,label:d(t),isDisabled:m(t,s),isSelected:n,options:i,context:t===r?"menu":"value",selectValue:s};e=C.onFocus(a)}return e}),[r,o,d,m,C,i,s]),x=(0,t.useMemo)((function(){var e="";if(g&&b.length&&C.onFilter){var t=v({count:i.length});e=C.onFilter({inputValue:p,resultsMessage:t})}return e}),[i,p,g,C,b,v]),L=(0,t.useMemo)((function(){var e="";if(C.guidance){var t=o?"value":g?"menu":"input";e=C.guidance({"aria-label":E,context:t,isDisabled:r&&m(r,s),isMulti:f,isSearchable:h,tabSelectsValue:y})}return e}),[E,r,o,f,m,h,g,C,s,y]),I="".concat(S," ").concat(x," ").concat(L),N=tr(t.Fragment,null,tr("span",{id:"aria-selection"},M),tr("span",{id:"aria-context"},I)),O="initial-input-focus"===(null==n?void 0:n.action);return tr(t.Fragment,null,tr(So,{id:c},O&&N),tr(So,{"aria-live":w,"aria-atomic":"false","aria-relevant":"additions text"},a&&!O&&N))},Io=[{base:"A",letters:"AⒶAÀÁÂẦẤẪẨÃĀĂẰẮẴẲȦǠÄǞẢÅǺǍȀȂẠẬẶḀĄȺⱯ"},{base:"AA",letters:"Ꜳ"},{base:"AE",letters:"ÆǼǢ"},{base:"AO",letters:"Ꜵ"},{base:"AU",letters:"Ꜷ"},{base:"AV",letters:"ꜸꜺ"},{base:"AY",letters:"Ꜽ"},{base:"B",letters:"BⒷBḂḄḆɃƂƁ"},{base:"C",letters:"CⒸCĆĈĊČÇḈƇȻꜾ"},{base:"D",letters:"DⒹDḊĎḌḐḒḎĐƋƊƉꝹ"},{base:"DZ",letters:"DZDŽ"},{base:"Dz",letters:"DzDž"},{base:"E",letters:"EⒺEÈÉÊỀẾỄỂẼĒḔḖĔĖËẺĚȄȆẸỆȨḜĘḘḚƐƎ"},{base:"F",letters:"FⒻFḞƑꝻ"},{base:"G",letters:"GⒼGǴĜḠĞĠǦĢǤƓꞠꝽꝾ"},{base:"H",letters:"HⒽHĤḢḦȞḤḨḪĦⱧⱵꞍ"},{base:"I",letters:"IⒾIÌÍÎĨĪĬİÏḮỈǏȈȊỊĮḬƗ"},{base:"J",letters:"JⒿJĴɈ"},{base:"K",letters:"KⓀKḰǨḲĶḴƘⱩꝀꝂꝄꞢ"},{base:"L",letters:"LⓁLĿĹĽḶḸĻḼḺŁȽⱢⱠꝈꝆꞀ"},{base:"LJ",letters:"LJ"},{base:"Lj",letters:"Lj"},{base:"M",letters:"MⓂMḾṀṂⱮƜ"},{base:"N",letters:"NⓃNǸŃÑṄŇṆŅṊṈȠƝꞐꞤ"},{base:"NJ",letters:"NJ"},{base:"Nj",letters:"Nj"},{base:"O",letters:"OⓄOÒÓÔỒỐỖỔÕṌȬṎŌṐṒŎȮȰÖȪỎŐǑȌȎƠỜỚỠỞỢỌỘǪǬØǾƆƟꝊꝌ"},{base:"OI",letters:"Ƣ"},{base:"OO",letters:"Ꝏ"},{base:"OU",letters:"Ȣ"},{base:"P",letters:"PⓅPṔṖƤⱣꝐꝒꝔ"},{base:"Q",letters:"QⓆQꝖꝘɊ"},{base:"R",letters:"RⓇRŔṘŘȐȒṚṜŖṞɌⱤꝚꞦꞂ"},{base:"S",letters:"SⓈSẞŚṤŜṠŠṦṢṨȘŞⱾꞨꞄ"},{base:"T",letters:"TⓉTṪŤṬȚŢṰṮŦƬƮȾꞆ"},{base:"TZ",letters:"Ꜩ"},{base:"U",letters:"UⓊUÙÚÛŨṸŪṺŬÜǛǗǕǙỦŮŰǓȔȖƯỪỨỮỬỰỤṲŲṶṴɄ"},{base:"V",letters:"VⓋVṼṾƲꝞɅ"},{base:"VY",letters:"Ꝡ"},{base:"W",letters:"WⓌWẀẂŴẆẄẈⱲ"},{base:"X",letters:"XⓍXẊẌ"},{base:"Y",letters:"YⓎYỲÝŶỸȲẎŸỶỴƳɎỾ"},{base:"Z",letters:"ZⓏZŹẐŻŽẒẔƵȤⱿⱫꝢ"},{base:"a",letters:"aⓐaẚàáâầấẫẩãāăằắẵẳȧǡäǟảåǻǎȁȃạậặḁąⱥɐ"},{base:"aa",letters:"ꜳ"},{base:"ae",letters:"æǽǣ"},{base:"ao",letters:"ꜵ"},{base:"au",letters:"ꜷ"},{base:"av",letters:"ꜹꜻ"},{base:"ay",letters:"ꜽ"},{base:"b",letters:"bⓑbḃḅḇƀƃɓ"},{base:"c",letters:"cⓒcćĉċčçḉƈȼꜿↄ"},{base:"d",letters:"dⓓdḋďḍḑḓḏđƌɖɗꝺ"},{base:"dz",letters:"dzdž"},{base:"e",letters:"eⓔeèéêềếễểẽēḕḗĕėëẻěȅȇẹệȩḝęḙḛɇɛǝ"},{base:"f",letters:"fⓕfḟƒꝼ"},{base:"g",letters:"gⓖgǵĝḡğġǧģǥɠꞡᵹꝿ"},{base:"h",letters:"hⓗhĥḣḧȟḥḩḫẖħⱨⱶɥ"},{base:"hv",letters:"ƕ"},{base:"i",letters:"iⓘiìíîĩīĭïḯỉǐȉȋịįḭɨı"},{base:"j",letters:"jⓙjĵǰɉ"},{base:"k",letters:"kⓚkḱǩḳķḵƙⱪꝁꝃꝅꞣ"},{base:"l",letters:"lⓛlŀĺľḷḹļḽḻſłƚɫⱡꝉꞁꝇ"},{base:"lj",letters:"lj"},{base:"m",letters:"mⓜmḿṁṃɱɯ"},{base:"n",letters:"nⓝnǹńñṅňṇņṋṉƞɲʼnꞑꞥ"},{base:"nj",letters:"nj"},{base:"o",letters:"oⓞoòóôồốỗổõṍȭṏōṑṓŏȯȱöȫỏőǒȍȏơờớỡởợọộǫǭøǿɔꝋꝍɵ"},{base:"oi",letters:"ƣ"},{base:"ou",letters:"ȣ"},{base:"oo",letters:"ꝏ"},{base:"p",letters:"pⓟpṕṗƥᵽꝑꝓꝕ"},{base:"q",letters:"qⓠqɋꝗꝙ"},{base:"r",letters:"rⓡrŕṙřȑȓṛṝŗṟɍɽꝛꞧꞃ"},{base:"s",letters:"sⓢsßśṥŝṡšṧṣṩșşȿꞩꞅẛ"},{base:"t",letters:"tⓣtṫẗťṭțţṱṯŧƭʈⱦꞇ"},{base:"tz",letters:"ꜩ"},{base:"u",letters:"uⓤuùúûũṹūṻŭüǜǘǖǚủůűǔȕȗưừứữửựụṳųṷṵʉ"},{base:"v",letters:"vⓥvṽṿʋꝟʌ"},{base:"vy",letters:"ꝡ"},{base:"w",letters:"wⓦwẁẃŵẇẅẘẉⱳ"},{base:"x",letters:"xⓧxẋẍ"},{base:"y",letters:"yⓨyỳýŷỹȳẏÿỷẙỵƴɏỿ"},{base:"z",letters:"zⓩzźẑżžẓẕƶȥɀⱬꝣ"}],No=new RegExp("["+Io.map((function(e){return e.letters})).join("")+"]","g"),Oo={},ko=0;ko1?t-1:0),r=1;r0,h=d-p-c,g=!1;h>t&&s.current&&(o&&o(e),s.current=!1),m&&l.current&&(a&&a(e),l.current=!1),m&&t>h?(r&&!s.current&&r(e),f.scrollTop=d,g=!0,s.current=!0):!m&&-t>c&&(i&&!l.current&&i(e),f.scrollTop=0,g=!0,l.current=!0),g&&function(e){e.preventDefault(),e.stopPropagation()}(e)}}),[r,o,i,a]),p=(0,t.useCallback)((function(e){d(e,e.deltaY)}),[d]),f=(0,t.useCallback)((function(e){c.current=e.changedTouches[0].clientY}),[]),m=(0,t.useCallback)((function(e){var t=c.current-e.changedTouches[0].clientY;d(e,t)}),[d]),h=(0,t.useCallback)((function(e){if(e){var t=!!Br&&{passive:!1};e.addEventListener("wheel",p,t),e.addEventListener("touchstart",f,t),e.addEventListener("touchmove",m,t)}}),[m,f,p]),g=(0,t.useCallback)((function(e){e&&(e.removeEventListener("wheel",p,!1),e.removeEventListener("touchstart",f,!1),e.removeEventListener("touchmove",m,!1))}),[m,f,p]);return(0,t.useEffect)((function(){if(n){var e=u.current;return h(e),function(){g(e)}}}),[n,h,g]),function(e){u.current=e}}({isEnabled:void 0===o||o,onBottomArrive:e.onBottomArrive,onBottomLeave:e.onBottomLeave,onTopArrive:e.onTopArrive,onTopLeave:e.onTopLeave}),a=function(e){var n=e.isEnabled,r=e.accountForScrollbars,o=void 0===r||r,i=(0,t.useRef)({}),a=(0,t.useRef)(null),s=(0,t.useCallback)((function(e){if(Wo){var t=document.body,n=t&&t.style;if(o&&zo.forEach((function(e){var t=n&&n[e];i.current[e]=t})),o&&Jo<1){var r=parseInt(i.current.paddingRight,10)||0,a=document.body?document.body.clientWidth:0,s=window.innerWidth-a+r||0;Object.keys(Vo).forEach((function(e){var t=Vo[e];n&&(n[e]=t)})),n&&(n.paddingRight="".concat(s,"px"))}t&&Qo()&&(t.addEventListener("touchmove",Uo,Yo),e&&(e.addEventListener("touchstart",Ho,Yo),e.addEventListener("touchmove",Bo,Yo))),Jo+=1}}),[o]),l=(0,t.useCallback)((function(e){if(Wo){var t=document.body,n=t&&t.style;Jo=Math.max(Jo-1,0),o&&Jo<1&&zo.forEach((function(e){var t=i.current[e];n&&(n[e]=t)})),t&&Qo()&&(t.removeEventListener("touchmove",Uo,Yo),e&&(e.removeEventListener("touchstart",Ho,Yo),e.removeEventListener("touchmove",Bo,Yo)))}}),[o]);return(0,t.useEffect)((function(){if(n){var e=a.current;return s(e),function(){l(e)}}}),[n,s,l]),function(e){a.current=e}}({isEnabled:r});return tr(t.Fragment,null,r&&tr("div",{onClick:Go,css:$o}),n((function(e){i(e),a(e)})))}var Xo={name:"1a0ro4n-requiredInput",styles:"label:requiredInput;opacity:0;pointer-events:none;position:absolute;bottom:0;left:0;right:0;width:100%"},qo=function(e){var t=e.name,n=e.onFocus;return tr("input",{required:!0,name:t,tabIndex:-1,"aria-hidden":"true",onFocus:n,css:Xo,value:"",onChange:function(){}})},Ko={clearIndicator:uo,container:function(e){var t=e.isDisabled;return{label:"container",direction:e.isRtl?"rtl":void 0,pointerEvents:t?"none":void 0,position:"relative"}},control:function(e,t){var n=e.isDisabled,r=e.isFocused,o=e.theme,i=o.colors,a=o.borderRadius;return bt({label:"control",alignItems:"center",cursor:"default",display:"flex",flexWrap:"wrap",justifyContent:"space-between",minHeight:o.spacing.controlHeight,outline:"0 !important",position:"relative",transition:"all 100ms"},t?{}:{backgroundColor:n?i.neutral5:i.neutral0,borderColor:n?i.neutral10:r?i.primary:i.neutral20,borderRadius:a,borderStyle:"solid",borderWidth:1,boxShadow:r?"0 0 0 1px ".concat(i.primary):void 0,"&:hover":{borderColor:r?i.primary:i.neutral30}})},dropdownIndicator:co,group:function(e,t){var n=e.theme.spacing;return t?{}:{paddingBottom:2*n.baseUnit,paddingTop:2*n.baseUnit}},groupHeading:function(e,t){var n=e.theme,r=n.colors,o=n.spacing;return bt({label:"group",cursor:"default",display:"block"},t?{}:{color:r.neutral40,fontSize:"75%",fontWeight:500,marginBottom:"0.25em",paddingLeft:3*o.baseUnit,paddingRight:3*o.baseUnit,textTransform:"uppercase"})},indicatorsContainer:function(){return{alignItems:"center",alignSelf:"stretch",display:"flex",flexShrink:0}},indicatorSeparator:function(e,t){var n=e.isDisabled,r=e.theme,o=r.spacing.baseUnit,i=r.colors;return bt({label:"indicatorSeparator",alignSelf:"stretch",width:1},t?{}:{backgroundColor:n?i.neutral10:i.neutral20,marginBottom:2*o,marginTop:2*o})},input:function(e,t){var n=e.isDisabled,r=e.value,o=e.theme,i=o.spacing,a=o.colors;return bt(bt({visibility:n?"hidden":"visible",transform:r?"translateZ(0)":""},bo),t?{}:{margin:i.baseUnit/2,paddingBottom:i.baseUnit/2,paddingTop:i.baseUnit/2,color:a.neutral80})},loadingIndicator:function(e,t){var n=e.isFocused,r=e.size,o=e.theme,i=o.colors,a=o.spacing.baseUnit;return bt({label:"loadingIndicator",display:"flex",transition:"color 150ms",alignSelf:"center",fontSize:r,lineHeight:1,marginRight:r,textAlign:"center",verticalAlign:"middle"},t?{}:{color:n?i.neutral60:i.neutral20,padding:2*a})},loadingMessage:to,menu:function(e,t){var n,r=e.placement,o=e.theme,i=o.borderRadius,a=o.spacing,s=o.colors;return bt((ht(n={label:"menu"},function(e){return e?{bottom:"top",top:"bottom"}[e]:"bottom"}(r),"100%"),ht(n,"position","absolute"),ht(n,"width","100%"),ht(n,"zIndex",1),n),t?{}:{backgroundColor:s.neutral0,borderRadius:i,boxShadow:"0 0 0 1px hsla(0, 0%, 0%, 0.1), 0 4px 11px hsla(0, 0%, 0%, 0.1)",marginBottom:a.menuGutter,marginTop:a.menuGutter})},menuList:function(e,t){var n=e.maxHeight,r=e.theme.spacing.baseUnit;return bt({maxHeight:n,overflowY:"auto",position:"relative",WebkitOverflowScrolling:"touch"},t?{}:{paddingBottom:r,paddingTop:r})},menuPortal:function(e){var t=e.rect,n=e.offset,r=e.position;return{left:t.left,position:r,top:n,width:t.width,zIndex:1}},multiValue:function(e,t){var n=e.theme,r=n.spacing,o=n.borderRadius,i=n.colors;return bt({label:"multiValue",display:"flex",minWidth:0},t?{}:{backgroundColor:i.neutral10,borderRadius:o/2,margin:r.baseUnit/2})},multiValueLabel:function(e,t){var n=e.theme,r=n.borderRadius,o=n.colors,i=e.cropWithEllipsis;return bt({overflow:"hidden",textOverflow:i||void 0===i?"ellipsis":void 0,whiteSpace:"nowrap"},t?{}:{borderRadius:r/2,color:o.neutral80,fontSize:"85%",padding:3,paddingLeft:6})},multiValueRemove:function(e,t){var n=e.theme,r=n.spacing,o=n.borderRadius,i=n.colors,a=e.isFocused;return bt({alignItems:"center",display:"flex"},t?{}:{borderRadius:o/2,backgroundColor:a?i.dangerLight:void 0,paddingLeft:r.baseUnit,paddingRight:r.baseUnit,":hover":{backgroundColor:i.dangerLight,color:i.danger}})},noOptionsMessage:eo,option:function(e,t){var n=e.isDisabled,r=e.isFocused,o=e.isSelected,i=e.theme,a=i.spacing,s=i.colors;return bt({label:"option",cursor:"default",display:"block",fontSize:"inherit",width:"100%",userSelect:"none",WebkitTapHighlightColor:"rgba(0, 0, 0, 0)"},t?{}:{backgroundColor:o?s.primary:r?s.primary25:"transparent",color:n?s.neutral20:o?s.neutral0:"inherit",padding:"".concat(2*a.baseUnit,"px ").concat(3*a.baseUnit,"px"),":active":{backgroundColor:n?void 0:o?s.primary:s.primary50}})},placeholder:function(e,t){var n=e.theme,r=n.spacing,o=n.colors;return bt({label:"placeholder",gridArea:"1 / 1 / 2 / 3"},t?{}:{color:o.neutral50,marginLeft:r.baseUnit/2,marginRight:r.baseUnit/2})},singleValue:function(e,t){var n=e.isDisabled,r=e.theme,o=r.spacing,i=r.colors;return bt({label:"singleValue",gridArea:"1 / 1 / 2 / 3",maxWidth:"100%",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},t?{}:{color:n?i.neutral40:i.neutral80,marginLeft:o.baseUnit/2,marginRight:o.baseUnit/2})},valueContainer:function(e,t){var n=e.theme.spacing,r=e.isMulti,o=e.hasValue,i=e.selectProps.controlShouldRenderValue;return bt({alignItems:"center",display:r&&o&&i?"flex":"grid",flex:1,flexWrap:"wrap",WebkitOverflowScrolling:"touch",position:"relative",overflow:"hidden"},t?{}:{padding:"".concat(n.baseUnit/2,"px ").concat(2*n.baseUnit,"px")})}},ei={borderRadius:4,colors:{primary:"#2684FF",primary75:"#4C9AFF",primary50:"#B2D4FF",primary25:"#DEEBFF",danger:"#DE350B",dangerLight:"#FFBDAD",neutral0:"hsl(0, 0%, 100%)",neutral5:"hsl(0, 0%, 95%)",neutral10:"hsl(0, 0%, 90%)",neutral20:"hsl(0, 0%, 80%)",neutral30:"hsl(0, 0%, 70%)",neutral40:"hsl(0, 0%, 60%)",neutral50:"hsl(0, 0%, 50%)",neutral60:"hsl(0, 0%, 40%)",neutral70:"hsl(0, 0%, 30%)",neutral80:"hsl(0, 0%, 20%)",neutral90:"hsl(0, 0%, 10%)"},spacing:{baseUnit:4,controlHeight:38,menuGutter:8}},ti={"aria-live":"polite",backspaceRemovesValue:!0,blurInputOnSelect:Fr(),captureMenuScroll:!Fr(),classNames:{},closeMenuOnSelect:!0,closeMenuOnScroll:!1,components:{},controlShouldRenderValue:!0,escapeClearsValue:!1,filterOption:function(e,t){if(e.data.__isNew__)return!0;var n=bt({ignoreCase:!0,ignoreAccents:!0,stringify:Ro,trim:!0,matchFrom:"any"},undefined),r=n.ignoreCase,o=n.ignoreAccents,i=n.stringify,a=n.trim,s=n.matchFrom,l=a?Po(t):t,c=a?Po(i(e)):i(e);return r&&(l=l.toLowerCase(),c=c.toLowerCase()),o&&(l=_o(l),c=Do(c)),"start"===s?c.substr(0,l.length)===l:c.indexOf(l)>-1},formatGroupLabel:function(e){return e.label},getOptionLabel:function(e){return e.label},getOptionValue:function(e){return e.value},isDisabled:!1,isLoading:!1,isMulti:!1,isRtl:!1,isSearchable:!0,isOptionDisabled:function(e){return!!e.isDisabled},loadingMessage:function(){return"Loading..."},maxMenuHeight:300,minMenuHeight:140,menuIsOpen:!1,menuPlacement:"bottom",menuPosition:"absolute",menuShouldBlockScroll:!1,menuShouldScrollIntoView:!function(){try{return/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)}catch(e){return!1}}(),noOptionsMessage:function(){return"No options"},openMenuOnFocus:!1,openMenuOnClick:!0,options:[],pageSize:5,placeholder:"Select...",screenReaderStatus:function(e){var t=e.count;return"".concat(t," result").concat(1!==t?"s":""," available")},styles:{},tabIndex:0,tabSelectsValue:!0,unstyled:!1};function ni(e,t,n,r){return{type:"option",data:t,isDisabled:li(e,t,n),isSelected:ci(e,t,n),label:ai(e,t),value:si(e,t),index:r}}function ri(e,t){return e.options.map((function(n,r){if("options"in n){var o=n.options.map((function(n,r){return ni(e,n,t,r)})).filter((function(t){return ii(e,t)}));return o.length>0?{type:"group",data:n,options:o,index:r}:void 0}var i=ni(e,n,t,r);return ii(e,i)?i:void 0})).filter(Hr)}function oi(e){return e.reduce((function(e,t){return"group"===t.type?e.push.apply(e,Nt(t.options.map((function(e){return e.data})))):e.push(t.data),e}),[])}function ii(e,t){var n=e.inputValue,r=void 0===n?"":n,o=t.data,i=t.isSelected,a=t.label,s=t.value;return(!di(e)||!i)&&ui(e,{label:a,value:s,data:o},r)}var ai=function(e,t){return e.getOptionLabel(t)},si=function(e,t){return e.getOptionValue(t)};function li(e,t,n){return"function"==typeof e.isOptionDisabled&&e.isOptionDisabled(t,n)}function ci(e,t,n){if(n.indexOf(t)>-1)return!0;if("function"==typeof e.isOptionSelected)return e.isOptionSelected(t,n);var r=si(e,t);return n.some((function(t){return si(e,t)===r}))}function ui(e,t,n){return!e.filterOption||e.filterOption(t,n)}var di=function(e){var t=e.hideSelectedOptions,n=e.isMulti;return void 0===t?n:t},pi=1,fi=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&xt(e,t)}(a,e);var n,r,o,i=It(a);function a(e){var t;if(function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,a),(t=i.call(this,e)).state={ariaSelection:null,focusedOption:null,focusedValue:null,inputIsHidden:!1,isFocused:!1,selectValue:[],clearFocusValueOnUpdate:!1,prevWasFocused:!1,inputIsHiddenAfterUpdate:void 0,prevProps:void 0},t.blockOptionHover=!1,t.isComposing=!1,t.commonProps=void 0,t.initialTouchX=0,t.initialTouchY=0,t.instancePrefix="",t.openAfterFocus=!1,t.scrollToFocusedOptionOnUpdate=!1,t.userIsDragging=void 0,t.controlRef=null,t.getControlRef=function(e){t.controlRef=e},t.focusedOptionRef=null,t.getFocusedOptionRef=function(e){t.focusedOptionRef=e},t.menuListRef=null,t.getMenuListRef=function(e){t.menuListRef=e},t.inputRef=null,t.getInputRef=function(e){t.inputRef=e},t.focus=t.focusInput,t.blur=t.blurInput,t.onChange=function(e,n){var r=t.props,o=r.onChange,i=r.name;n.name=i,t.ariaOnChange(e,n),o(e,n)},t.setValue=function(e,n,r){var o=t.props,i=o.closeMenuOnSelect,a=o.isMulti,s=o.inputValue;t.onInputChange("",{action:"set-value",prevInputValue:s}),i&&(t.setState({inputIsHiddenAfterUpdate:!a}),t.onMenuClose()),t.setState({clearFocusValueOnUpdate:!0}),t.onChange(e,{action:n,option:r})},t.selectOption=function(e){var n=t.props,r=n.blurInputOnSelect,o=n.isMulti,i=n.name,a=t.state.selectValue,s=o&&t.isOptionSelected(e,a),l=t.isOptionDisabled(e,a);if(s){var c=t.getOptionValue(e);t.setValue(a.filter((function(e){return t.getOptionValue(e)!==c})),"deselect-option",e)}else{if(l)return void t.ariaOnChange(e,{action:"select-option",option:e,name:i});o?t.setValue([].concat(Nt(a),[e]),"select-option",e):t.setValue(e,"select-option")}r&&t.blurInput()},t.removeValue=function(e){var n=t.props.isMulti,r=t.state.selectValue,o=t.getOptionValue(e),i=r.filter((function(e){return t.getOptionValue(e)!==o})),a=Qr(n,i,i[0]||null);t.onChange(a,{action:"remove-value",removedValue:e}),t.focusInput()},t.clearValue=function(){var e=t.state.selectValue;t.onChange(Qr(t.props.isMulti,[],null),{action:"clear",removedValues:e})},t.popValue=function(){var e=t.props.isMulti,n=t.state.selectValue,r=n[n.length-1],o=n.slice(0,n.length-1),i=Qr(e,o,o[0]||null);t.onChange(i,{action:"pop-value",removedValue:r})},t.getValue=function(){return t.state.selectValue},t.cx=function(){for(var e=arguments.length,n=new Array(e),r=0;r5||i>5}},t.onTouchEnd=function(e){t.userIsDragging||(t.controlRef&&!t.controlRef.contains(e.target)&&t.menuListRef&&!t.menuListRef.contains(e.target)&&t.blurInput(),t.initialTouchX=0,t.initialTouchY=0)},t.onControlTouchEnd=function(e){t.userIsDragging||t.onControlMouseDown(e)},t.onClearIndicatorTouchEnd=function(e){t.userIsDragging||t.onClearIndicatorMouseDown(e)},t.onDropdownIndicatorTouchEnd=function(e){t.userIsDragging||t.onDropdownIndicatorMouseDown(e)},t.handleInputChange=function(e){var n=t.props.inputValue,r=e.currentTarget.value;t.setState({inputIsHiddenAfterUpdate:!1}),t.onInputChange(r,{action:"input-change",prevInputValue:n}),t.props.menuIsOpen||t.onMenuOpen()},t.onInputFocus=function(e){t.props.onFocus&&t.props.onFocus(e),t.setState({inputIsHiddenAfterUpdate:!1,isFocused:!0}),(t.openAfterFocus||t.props.openMenuOnFocus)&&t.openMenu("first"),t.openAfterFocus=!1},t.onInputBlur=function(e){var n=t.props.inputValue;t.menuListRef&&t.menuListRef.contains(document.activeElement)?t.inputRef.focus():(t.props.onBlur&&t.props.onBlur(e),t.onInputChange("",{action:"input-blur",prevInputValue:n}),t.onMenuClose(),t.setState({focusedValue:null,isFocused:!1}))},t.onOptionHover=function(e){t.blockOptionHover||t.state.focusedOption===e||t.setState({focusedOption:e})},t.shouldHideSelectedOptions=function(){return di(t.props)},t.onValueInputFocus=function(e){e.preventDefault(),e.stopPropagation(),t.focus()},t.onKeyDown=function(e){var n=t.props,r=n.isMulti,o=n.backspaceRemovesValue,i=n.escapeClearsValue,a=n.inputValue,s=n.isClearable,l=n.isDisabled,c=n.menuIsOpen,u=n.onKeyDown,d=n.tabSelectsValue,p=n.openMenuOnFocus,f=t.state,m=f.focusedOption,h=f.focusedValue,g=f.selectValue;if(!(l||"function"==typeof u&&(u(e),e.defaultPrevented))){switch(t.blockOptionHover=!0,e.key){case"ArrowLeft":if(!r||a)return;t.focusValue("previous");break;case"ArrowRight":if(!r||a)return;t.focusValue("next");break;case"Delete":case"Backspace":if(a)return;if(h)t.removeValue(h);else{if(!o)return;r?t.popValue():s&&t.clearValue()}break;case"Tab":if(t.isComposing)return;if(e.shiftKey||!c||!d||!m||p&&t.isOptionSelected(m,g))return;t.selectOption(m);break;case"Enter":if(229===e.keyCode)break;if(c){if(!m)return;if(t.isComposing)return;t.selectOption(m);break}return;case"Escape":c?(t.setState({inputIsHiddenAfterUpdate:!1}),t.onInputChange("",{action:"menu-close",prevInputValue:a}),t.onMenuClose()):s&&i&&t.clearValue();break;case" ":if(a)return;if(!c){t.openMenu("first");break}if(!m)return;t.selectOption(m);break;case"ArrowUp":c?t.focusOption("up"):t.openMenu("last");break;case"ArrowDown":c?t.focusOption("down"):t.openMenu("first");break;case"PageUp":if(!c)return;t.focusOption("pageup");break;case"PageDown":if(!c)return;t.focusOption("pagedown");break;case"Home":if(!c)return;t.focusOption("first");break;case"End":if(!c)return;t.focusOption("last");break;default:return}e.preventDefault()}},t.instancePrefix="react-select-"+(t.props.instanceId||++pi),t.state.selectValue=kr(e.value),e.menuIsOpen&&t.state.selectValue.length){var n=t.buildFocusableOptions(),r=n.indexOf(t.state.selectValue[0]);t.state.focusedOption=n[r]}return t}return n=a,r=[{key:"componentDidMount",value:function(){this.startListeningComposition(),this.startListeningToTouch(),this.props.closeMenuOnScroll&&document&&document.addEventListener&&document.addEventListener("scroll",this.onScroll,!0),this.props.autoFocus&&this.focusInput(),this.props.menuIsOpen&&this.state.focusedOption&&this.menuListRef&&this.focusedOptionRef&&Ar(this.menuListRef,this.focusedOptionRef)}},{key:"componentDidUpdate",value:function(e){var t=this.props,n=t.isDisabled,r=t.menuIsOpen,o=this.state.isFocused;(o&&!n&&e.isDisabled||o&&r&&!e.menuIsOpen)&&this.focusInput(),o&&n&&!e.isDisabled?this.setState({isFocused:!1},this.onMenuClose):o||n||!e.isDisabled||this.inputRef!==document.activeElement||this.setState({isFocused:!0}),this.menuListRef&&this.focusedOptionRef&&this.scrollToFocusedOptionOnUpdate&&(Ar(this.menuListRef,this.focusedOptionRef),this.scrollToFocusedOptionOnUpdate=!1)}},{key:"componentWillUnmount",value:function(){this.stopListeningComposition(),this.stopListeningToTouch(),document.removeEventListener("scroll",this.onScroll,!0)}},{key:"onMenuOpen",value:function(){this.props.onMenuOpen()}},{key:"onMenuClose",value:function(){this.onInputChange("",{action:"menu-close",prevInputValue:this.props.inputValue}),this.props.onMenuClose()}},{key:"onInputChange",value:function(e,t){this.props.onInputChange(e,t)}},{key:"focusInput",value:function(){this.inputRef&&this.inputRef.focus()}},{key:"blurInput",value:function(){this.inputRef&&this.inputRef.blur()}},{key:"openMenu",value:function(e){var t=this,n=this.state,r=n.selectValue,o=n.isFocused,i=this.buildFocusableOptions(),a="first"===e?0:i.length-1;if(!this.props.isMulti){var s=i.indexOf(r[0]);s>-1&&(a=s)}this.scrollToFocusedOptionOnUpdate=!(o&&this.menuListRef),this.setState({inputIsHiddenAfterUpdate:!1,focusedValue:null,focusedOption:i[a]},(function(){return t.onMenuOpen()}))}},{key:"focusValue",value:function(e){var t=this.state,n=t.selectValue,r=t.focusedValue;if(this.props.isMulti){this.setState({focusedOption:null});var o=n.indexOf(r);r||(o=-1);var i=n.length-1,a=-1;if(n.length){switch(e){case"previous":a=0===o?0:-1===o?i:o-1;break;case"next":o>-1&&o0&&void 0!==arguments[0]?arguments[0]:"first",t=this.props.pageSize,n=this.state.focusedOption,r=this.getFocusableOptions();if(r.length){var o=0,i=r.indexOf(n);n||(i=-1),"up"===e?o=i>0?i-1:r.length-1:"down"===e?o=(i+1)%r.length:"pageup"===e?(o=i-t)<0&&(o=0):"pagedown"===e?(o=i+t)>r.length-1&&(o=r.length-1):"last"===e&&(o=r.length-1),this.scrollToFocusedOptionOnUpdate=!0,this.setState({focusedOption:r[o],focusedValue:null})}}},{key:"getTheme",value:function(){return this.props.theme?"function"==typeof this.props.theme?this.props.theme(ei):bt(bt({},ei),this.props.theme):ei}},{key:"getCommonProps",value:function(){var e=this.clearValue,t=this.cx,n=this.getStyles,r=this.getClassNames,o=this.getValue,i=this.selectOption,a=this.setValue,s=this.props,l=s.isMulti,c=s.isRtl,u=s.options;return{clearValue:e,cx:t,getStyles:n,getClassNames:r,getValue:o,hasValue:this.hasValue(),isMulti:l,isRtl:c,options:u,selectOption:i,selectProps:s,setValue:a,theme:this.getTheme()}}},{key:"hasValue",value:function(){return this.state.selectValue.length>0}},{key:"hasOptions",value:function(){return!!this.getFocusableOptions().length}},{key:"isClearable",value:function(){var e=this.props,t=e.isClearable,n=e.isMulti;return void 0===t?n:t}},{key:"isOptionDisabled",value:function(e,t){return li(this.props,e,t)}},{key:"isOptionSelected",value:function(e,t){return ci(this.props,e,t)}},{key:"filterOption",value:function(e,t){return ui(this.props,e,t)}},{key:"formatOptionLabel",value:function(e,t){if("function"==typeof this.props.formatOptionLabel){var n=this.props.inputValue,r=this.state.selectValue;return this.props.formatOptionLabel(e,{context:t,inputValue:n,selectValue:r})}return this.getOptionLabel(e)}},{key:"formatGroupLabel",value:function(e){return this.props.formatGroupLabel(e)}},{key:"startListeningComposition",value:function(){document&&document.addEventListener&&(document.addEventListener("compositionstart",this.onCompositionStart,!1),document.addEventListener("compositionend",this.onCompositionEnd,!1))}},{key:"stopListeningComposition",value:function(){document&&document.removeEventListener&&(document.removeEventListener("compositionstart",this.onCompositionStart),document.removeEventListener("compositionend",this.onCompositionEnd))}},{key:"startListeningToTouch",value:function(){document&&document.addEventListener&&(document.addEventListener("touchstart",this.onTouchStart,!1),document.addEventListener("touchmove",this.onTouchMove,!1),document.addEventListener("touchend",this.onTouchEnd,!1))}},{key:"stopListeningToTouch",value:function(){document&&document.removeEventListener&&(document.removeEventListener("touchstart",this.onTouchStart),document.removeEventListener("touchmove",this.onTouchMove),document.removeEventListener("touchend",this.onTouchEnd))}},{key:"renderInput",value:function(){var e=this.props,n=e.isDisabled,r=e.isSearchable,o=e.inputId,i=e.inputValue,a=e.tabIndex,s=e.form,l=e.menuIsOpen,c=e.required,u=this.getComponents().Input,d=this.state,p=d.inputIsHidden,f=d.ariaSelection,m=this.commonProps,h=o||this.getElementId("input"),g=bt(bt(bt({"aria-autocomplete":"list","aria-expanded":l,"aria-haspopup":!0,"aria-errormessage":this.props["aria-errormessage"],"aria-invalid":this.props["aria-invalid"],"aria-label":this.props["aria-label"],"aria-labelledby":this.props["aria-labelledby"],"aria-required":c,role:"combobox"},l&&{"aria-controls":this.getElementId("listbox"),"aria-owns":this.getElementId("listbox")}),!r&&{"aria-readonly":!0}),this.hasValue()?"initial-input-focus"===(null==f?void 0:f.action)&&{"aria-describedby":this.getElementId("live-region")}:{"aria-describedby":this.getElementId("placeholder")});return r?t.createElement(u,Mt({},m,{autoCapitalize:"none",autoComplete:"off",autoCorrect:"off",id:h,innerRef:this.getInputRef,isDisabled:n,isHidden:p,onBlur:this.onInputBlur,onChange:this.handleInputChange,onFocus:this.onInputFocus,spellCheck:"false",tabIndex:a,form:s,type:"text",value:i},g)):t.createElement(Fo,Mt({id:h,innerRef:this.getInputRef,onBlur:this.onInputBlur,onChange:Ir,onFocus:this.onInputFocus,disabled:n,tabIndex:a,inputMode:"none",form:s,value:""},g))}},{key:"renderPlaceholderOrValue",value:function(){var e=this,n=this.getComponents(),r=n.MultiValue,o=n.MultiValueContainer,i=n.MultiValueLabel,a=n.MultiValueRemove,s=n.SingleValue,l=n.Placeholder,c=this.commonProps,u=this.props,d=u.controlShouldRenderValue,p=u.isDisabled,f=u.isMulti,m=u.inputValue,h=u.placeholder,g=this.state,b=g.selectValue,v=g.focusedValue,y=g.isFocused;if(!this.hasValue()||!d)return m?null:t.createElement(l,Mt({},c,{key:"placeholder",isDisabled:p,isFocused:y,innerProps:{id:this.getElementId("placeholder")}}),h);if(f)return b.map((function(n,s){var l=n===v,u="".concat(e.getOptionLabel(n),"-").concat(e.getOptionValue(n));return t.createElement(r,Mt({},c,{components:{Container:o,Label:i,Remove:a},isFocused:l,isDisabled:p,key:u,index:s,removeProps:{onClick:function(){return e.removeValue(n)},onTouchEnd:function(){return e.removeValue(n)},onMouseDown:function(e){e.preventDefault()}},data:n}),e.formatOptionLabel(n,"value"))}));if(m)return null;var E=b[0];return t.createElement(s,Mt({},c,{data:E,isDisabled:p}),this.formatOptionLabel(E,"value"))}},{key:"renderClearIndicator",value:function(){var e=this.getComponents().ClearIndicator,n=this.commonProps,r=this.props,o=r.isDisabled,i=r.isLoading,a=this.state.isFocused;if(!this.isClearable()||!e||o||!this.hasValue()||i)return null;var s={onMouseDown:this.onClearIndicatorMouseDown,onTouchEnd:this.onClearIndicatorTouchEnd,"aria-hidden":"true"};return t.createElement(e,Mt({},n,{innerProps:s,isFocused:a}))}},{key:"renderLoadingIndicator",value:function(){var e=this.getComponents().LoadingIndicator,n=this.commonProps,r=this.props,o=r.isDisabled,i=r.isLoading,a=this.state.isFocused;return e&&i?t.createElement(e,Mt({},n,{innerProps:{"aria-hidden":"true"},isDisabled:o,isFocused:a})):null}},{key:"renderIndicatorSeparator",value:function(){var e=this.getComponents(),n=e.DropdownIndicator,r=e.IndicatorSeparator;if(!n||!r)return null;var o=this.commonProps,i=this.props.isDisabled,a=this.state.isFocused;return t.createElement(r,Mt({},o,{isDisabled:i,isFocused:a}))}},{key:"renderDropdownIndicator",value:function(){var e=this.getComponents().DropdownIndicator;if(!e)return null;var n=this.commonProps,r=this.props.isDisabled,o=this.state.isFocused,i={onMouseDown:this.onDropdownIndicatorMouseDown,onTouchEnd:this.onDropdownIndicatorTouchEnd,"aria-hidden":"true"};return t.createElement(e,Mt({},n,{innerProps:i,isDisabled:r,isFocused:o}))}},{key:"renderMenu",value:function(){var e=this,n=this.getComponents(),r=n.Group,o=n.GroupHeading,i=n.Menu,a=n.MenuList,s=n.MenuPortal,l=n.LoadingMessage,c=n.NoOptionsMessage,u=n.Option,d=this.commonProps,p=this.state.focusedOption,f=this.props,m=f.captureMenuScroll,h=f.inputValue,g=f.isLoading,b=f.loadingMessage,v=f.minMenuHeight,y=f.maxMenuHeight,E=f.menuIsOpen,w=f.menuPlacement,C=f.menuPosition,M=f.menuPortalTarget,S=f.menuShouldBlockScroll,x=f.menuShouldScrollIntoView,L=f.noOptionsMessage,I=f.onMenuScrollToTop,N=f.onMenuScrollToBottom;if(!E)return null;var O,k=function(n,r){var o=n.type,i=n.data,a=n.isDisabled,s=n.isSelected,l=n.label,c=n.value,f=p===i,m=a?void 0:function(){return e.onOptionHover(i)},h=a?void 0:function(){return e.selectOption(i)},g="".concat(e.getElementId("option"),"-").concat(r),b={id:g,onClick:h,onMouseMove:m,onMouseOver:m,tabIndex:-1};return t.createElement(u,Mt({},d,{innerProps:b,data:i,isDisabled:a,isSelected:s,key:g,label:l,type:o,value:c,isFocused:f,innerRef:f?e.getFocusedOptionRef:void 0}),e.formatOptionLabel(n.data,"menu"))};if(this.hasOptions())O=this.getCategorizedOptions().map((function(n){if("group"===n.type){var i=n.data,a=n.options,s=n.index,l="".concat(e.getElementId("group"),"-").concat(s),c="".concat(l,"-heading");return t.createElement(r,Mt({},d,{key:l,data:i,options:a,Heading:o,headingProps:{id:c,data:n.data},label:e.formatGroupLabel(n.data)}),n.options.map((function(e){return k(e,"".concat(s,"-").concat(e.index))})))}if("option"===n.type)return k(n,"".concat(n.index))}));else if(g){var j=b({inputValue:h});if(null===j)return null;O=t.createElement(l,d,j)}else{var T=L({inputValue:h});if(null===T)return null;O=t.createElement(c,d,T)}var D={minMenuHeight:v,maxMenuHeight:y,menuPlacement:w,menuPosition:C,menuShouldScrollIntoView:x},_=t.createElement(qr,Mt({},d,D),(function(n){var r=n.ref,o=n.placerProps,s=o.placement,l=o.maxHeight;return t.createElement(i,Mt({},d,D,{innerRef:r,innerProps:{onMouseDown:e.onMenuMouseDown,onMouseMove:e.onMenuMouseMove,id:e.getElementId("listbox")},isLoading:g,placement:s}),t.createElement(Zo,{captureEnabled:m,onTopArrive:I,onBottomArrive:N,lockEnabled:S},(function(n){return t.createElement(a,Mt({},d,{innerRef:function(t){e.getMenuListRef(t),n(t)},isLoading:g,maxHeight:l,focusedOption:p}),O)})))}));return M||"fixed"===C?t.createElement(s,Mt({},d,{appendTo:M,controlElement:this.controlRef,menuPlacement:w,menuPosition:C}),_):_}},{key:"renderFormField",value:function(){var e=this,n=this.props,r=n.delimiter,o=n.isDisabled,i=n.isMulti,a=n.name,s=n.required,l=this.state.selectValue;if(s&&!this.hasValue()&&!o)return t.createElement(qo,{name:a,onFocus:this.onValueInputFocus});if(a&&!o){if(i){if(r){var c=l.map((function(t){return e.getOptionValue(t)})).join(r);return t.createElement("input",{name:a,type:"hidden",value:c})}var u=l.length>0?l.map((function(n,r){return t.createElement("input",{key:"i-".concat(r),name:a,type:"hidden",value:e.getOptionValue(n)})})):t.createElement("input",{name:a,type:"hidden",value:""});return t.createElement("div",null,u)}var d=l[0]?this.getOptionValue(l[0]):"";return t.createElement("input",{name:a,type:"hidden",value:d})}}},{key:"renderLiveRegion",value:function(){var e=this.commonProps,n=this.state,r=n.ariaSelection,o=n.focusedOption,i=n.focusedValue,a=n.isFocused,s=n.selectValue,l=this.getFocusableOptions();return t.createElement(Lo,Mt({},e,{id:this.getElementId("live-region"),ariaSelection:r,focusedOption:o,focusedValue:i,isFocused:a,selectValue:s,focusableOptions:l}))}},{key:"render",value:function(){var e=this.getComponents(),n=e.Control,r=e.IndicatorsContainer,o=e.SelectContainer,i=e.ValueContainer,a=this.props,s=a.className,l=a.id,c=a.isDisabled,u=a.menuIsOpen,d=this.state.isFocused,p=this.commonProps=this.getCommonProps();return t.createElement(o,Mt({},p,{className:s,innerProps:{id:l,onKeyDown:this.onKeyDown},isDisabled:c,isFocused:d}),this.renderLiveRegion(),t.createElement(n,Mt({},p,{innerRef:this.getControlRef,innerProps:{onMouseDown:this.onControlMouseDown,onTouchEnd:this.onControlTouchEnd},isDisabled:c,isFocused:d,menuIsOpen:u}),t.createElement(i,Mt({},p,{isDisabled:c}),this.renderPlaceholderOrValue(),this.renderInput()),t.createElement(r,Mt({},p,{isDisabled:c}),this.renderClearIndicator(),this.renderLoadingIndicator(),this.renderIndicatorSeparator(),this.renderDropdownIndicator())),this.renderMenu(),this.renderFormField())}}],o=[{key:"getDerivedStateFromProps",value:function(e,t){var n=t.prevProps,r=t.clearFocusValueOnUpdate,o=t.inputIsHiddenAfterUpdate,i=t.ariaSelection,a=t.isFocused,s=t.prevWasFocused,l=e.options,c=e.value,u=e.menuIsOpen,d=e.inputValue,p=e.isMulti,f=kr(c),m={};if(n&&(c!==n.value||l!==n.options||u!==n.menuIsOpen||d!==n.inputValue)){var h=u?function(e,t){return oi(ri(e,t))}(e,f):[],g=r?function(e,t){var n=e.focusedValue,r=e.selectValue.indexOf(n);if(r>-1){if(t.indexOf(n)>-1)return n;if(r-1?n:t[0]}(t,h);m={selectValue:f,focusedOption:b,focusedValue:g,clearFocusValueOnUpdate:!1}}var v=null!=o&&e!==n?{inputIsHidden:o,inputIsHiddenAfterUpdate:void 0}:{},y=i,E=a&&s;return a&&!E&&(y={value:Qr(p,f,f[0]||null),options:f,action:"initial-input-focus"},E=!s),"initial-input-focus"===(null==i?void 0:i.action)&&(y=null),bt(bt(bt({},m),v),{},{prevProps:e,ariaSelection:y,prevWasFocused:E})}}],r&&St(n.prototype,r),o&&St(n,o),Object.defineProperty(n,"prototype",{writable:!1}),a}(t.Component);fi.defaultProps=ti;var mi=(0,t.forwardRef)((function(e,n){var r=function(e){var n=e.defaultInputValue,r=void 0===n?"":n,o=e.defaultMenuIsOpen,i=void 0!==o&&o,a=e.defaultValue,s=void 0===a?null:a,l=e.inputValue,c=e.menuIsOpen,u=e.onChange,d=e.onInputChange,p=e.onMenuClose,f=e.onMenuOpen,m=e.value,h=wt(e,Ct),g=Et((0,t.useState)(void 0!==l?l:r),2),b=g[0],v=g[1],y=Et((0,t.useState)(void 0!==c?c:i),2),E=y[0],w=y[1],C=Et((0,t.useState)(void 0!==m?m:s),2),M=C[0],S=C[1],x=(0,t.useCallback)((function(e,t){"function"==typeof u&&u(e,t),S(e)}),[u]),L=(0,t.useCallback)((function(e,t){var n;"function"==typeof d&&(n=d(e,t)),v(void 0!==n?n:e)}),[d]),I=(0,t.useCallback)((function(){"function"==typeof f&&f(),w(!0)}),[f]),N=(0,t.useCallback)((function(){"function"==typeof p&&p(),w(!1)}),[p]),O=void 0!==l?l:b,k=void 0!==c?c:E,j=void 0!==m?m:M;return bt(bt({},h),{},{inputValue:O,menuIsOpen:k,onChange:x,onInputChange:L,onMenuClose:N,onMenuOpen:I,value:j})}(e);return t.createElement(fi,Mt({ref:n},r))})),hi=mi;const gi=t=>{const n=[];let r;return t.options.forEach(((e,o)=>{n[o]={value:e.value,label:e.label,index:o},e.value===t.value&&(r=n[o])})),(0,e.createElement)(e.Fragment,null,(0,e.createElement)("div",{className:t.wrapperClass},t.selectDeselect&&(0,e.createElement)(e.Fragment,null,(0,e.createElement)("div",{className:t.selectDeselectClass,onClick:e=>{t.onMultiSelectDeselectChange?.(e)}},t.selectDeselectValue)),(0,e.createElement)(hi,{className:t.inputClass,value:r,options:n,onChange:e=>{t.onChange?.(e)},onClick:e=>{t.onClick?.(e)},isMulti:"multi-select"===t.type}),t.proSetting&&(0,e.createElement)("span",{className:"admin-pro-tag"},"pro"),t.description&&(0,e.createElement)("p",{className:t.descClass,dangerouslySetInnerHTML:{__html:t.description}})))},bi=n=>{const[r,o]=(0,t.useState)(""),[i,a]=(0,t.useState)(""),[s,l]=(0,t.useState)(),[c,u]=(0,t.useState)();(0,t.useEffect)((()=>{at({method:"get",url:st("get_commission_setting"),headers:{"X-WP-Nonce":appLocalizer.nonce}}).then((e=>{const{revenue_sharing_mode:t,commission_type:n,fixed:r,percentage:i}=e.data;o(t),a(n),l(r),u(i)})).catch((e=>{console.error("Error fetching commission settings:",e)}))}),[]);const d=(e,t)=>{"default_commission"===t?l(e):"default_percentage"===t&&u(e)};return(0,e.createElement)(e.Fragment,null,(0,e.createElement)("h1",null,"Commission Setup"),(0,e.createElement)("div",{className:"mvx-setting-section-divider"}," "),(0,e.createElement)("form",{method:"post"},(0,e.createElement)("table",{className:"form-table"},(0,e.createElement)("tr",null,(0,e.createElement)("th",{scope:"row"},(0,e.createElement)("label",{htmlFor:"revenue_sharing_mode"},"Revenue Sharing Mode")),(0,e.createElement)("td",null,(0,e.createElement)(pt,{inputClass:"input-radio",idPrefix:"toggle",options:[{key:"admin",value:"revenue_sharing_mode_admin",label:"Admin fees",name:"revenue_sharing_mode"},{key:"vendor",value:"revenue_sharing_mode_vendor",label:"Vendor Commissions",name:"revenue_sharing_mode"}],value:r,onChange:e=>{o(e.target.value)}}))),(0,e.createElement)("tr",null,(0,e.createElement)("th",{scope:"row"},(0,e.createElement)("label",{htmlFor:"commission_type"},"Commission Type")),(0,e.createElement)("td",null,(0,e.createElement)(gi,{options:[{value:"fixed",label:"Fixed Amount"},{value:"percent",label:"Percentage"},{value:"fixed_with_percentage",label:"%age + Fixed (per transaction)"},{value:"fixed_with_percentage_qty",label:"%age + Fixed (per unit)"}],value:i,onChange:e=>{a(e.value)},inputClass:"wc-enhanced-select"}))),(t=>{switch(t){case"fixed":return(0,e.createElement)(dt,{id:"tr_default_commission",type:"default_commission",value:s,handler:d});case"percent":return(0,e.createElement)(dt,{id:"tr_default_percentage",type:"default_percentage",value:c,handler:d});case"fixed_with_percentage":return(0,e.createElement)(e.Fragment,null,(0,e.createElement)(dt,{id:"tr_fixed_with_percentage",type:"default_commission",value:s,handler:d}),(0,e.createElement)(dt,{id:"tr_default_percentage",type:"default_percentage",value:c,handler:d}));case"fixed_with_percentage_qty":return(0,e.createElement)(e.Fragment,null,(0,e.createElement)(dt,{id:"tr_fixed_with_percentage_qty",type:"default_commission",value:s,handler:d}),(0,e.createElement)(dt,{id:"tr_default_percentage",type:"default_percentage",value:c,handler:d}));default:return null}})(i)),(0,e.createElement)("p",{className:"wc-setup-actions step"},(0,e.createElement)(M,{onClick:n.onNext,type:"button",inputClass:"button button-large button-next",value:"Skip this step"}),(0,e.createElement)(M,{onClick:e=>{e.preventDefault();const t={revenue_sharing_mode:r,commission_type:i,fixed:s,percentage:c};at({method:"post",url:st("set_commission_setting"),headers:{"X-WP-Nonce":appLocalizer.nonce},data:t}).then((e=>{console.log("Settings saved successfully:",e.data),n.onNext()})).catch((e=>{console.error("Error saving settings:",e.response?e.response.data:e.message)}))},type:"submit",inputClass:"button-primary button button-large button-next",value:"Continue"}))))},vi=t=>(0,e.createElement)("div",{className:t.wrapperClass},t.selectDeselect&&(0,e.createElement)(e.Fragment,null,(0,e.createElement)("div",{className:t.selectDeselectClass,onClick:e=>{t.onMultiSelectDeselectChange?.(e)}},t.selectDeselectValue)),t.options.map((n=>{let r=!1;return t.value&&t.value.length>0&&(r=t.value.indexOf(n.value)>=0),(0,e.createElement)("div",{className:t.inputWrapperClass},t.rightContent&&(0,e.createElement)("p",{className:t.rightContentClass,dangerouslySetInnerHTML:{__html:n.label}}),(0,e.createElement)("div",{className:t.inputInnerWrapperClass},(0,e.createElement)("input",{className:t.inputClass,id:`${t.idPrefix}-${n.key}`,key:n.key,type:t.type||"checkbox",name:n.name||"basic-input",value:n.value,checked:r,onChange:e=>{t.onChange?.(e)}}),(0,e.createElement)("label",{htmlFor:`${t.idPrefix}-${n.key}`}),t.proSetting&&(0,e.createElement)("span",{className:"admin-pro-tag"},"pro")),!t.rightContent&&(0,e.createElement)("p",{className:t.rightContentClass,dangerouslySetInnerHTML:{__html:n.label}}),n.hints&&(0,e.createElement)("span",{className:t.hintOuterClass},(0,e.createElement)("div",{className:t.hintInnerClass},n.hints)))})),t.description&&(0,e.createElement)("p",{className:t.descClass,dangerouslySetInnerHTML:{__html:t.description}})),yi=t=>(0,e.createElement)(e.Fragment,null,(0,e.createElement)("div",{className:t.wrapperClass},t.options.map((n=>{const r=t.value==n.value;return(0,e.createElement)("div",{className:`${t.inputWrapperClass} ${r?t.activeClass:""}`},(0,e.createElement)("input",{className:t.inputClass,id:`${t.idPrefix}-${n.key}`,key:n.keyName,type:"radio",name:n.name,checked:r,value:n.value,onChange:e=>{t.onChange(e)}}),(0,e.createElement)("label",{key:n.key,htmlFor:`${t.idPrefix}-${n.key}`,className:"radio-select"===t.type?t.radiSelectLabelClass:""},n.label,"radio-color"===t.type&&(0,e.createElement)("p",{className:"color-palette"},n.color.map((t=>(0,e.createElement)("div",{style:{backgroundColor:t}},"   ")))),"radio-select"===t.type&&(0,e.createElement)(e.Fragment,null,(0,e.createElement)("img",{src:n.color,alt:n.label,className:t.labelImgClass}),(0,e.createElement)("div",{className:t.labelOverlayClass},t.labelOverlayText))),t.proSetting&&(0,e.createElement)("span",{className:"admin-pro-tag"},"pro"))})),t.description&&(0,e.createElement)("p",{className:t.descClass,dangerouslySetInnerHTML:{__html:t.description}}))),Ei=n=>{const[r,o]=(0,t.useState)(!1),[i,a]=(0,t.useState)(!1),[s,l]=(0,t.useState)(""),[c,u]=(0,t.useState)({paypal_masspay:!1,paypal_payout:!1,direct_bank:!1,stripe_masspay:!1});return(0,t.useEffect)((()=>{at({method:"get",url:st("get_payment_setting"),headers:{"X-WP-Nonce":appLocalizer.nonce}}).then((e=>{const{mvx_disbursal_mode_admin:t,payment_schedule:n,mvx_disbursal_mode_vendor:r,is_enable_gateway:i}=e.data;o(t),a(r),l(n),u(i)})).catch((e=>{console.error("Error fetching payment settings:",e)}))}),[]),(0,e.createElement)(e.Fragment,null,(0,e.createElement)("h1",null,"Payments"),(0,e.createElement)("div",{className:"mvx-setting-section-divider"}," "),(0,e.createElement)("form",{method:"post",className:"wc-wizard-payment-gateway-form"},(0,e.createElement)("h3",{className:"mvx-pay-heading"},"Allowed Payment Methods"),(0,e.createElement)(vi,{options:[{key:"paypal_masspay",value:"paypal_masspay",label:"Paypal Masspay",hints:"Pay via paypal masspay"},{key:"paypal_payout",value:"paypal_payout",label:"Paypal Payout",hints:"Pay via paypal payout"},{key:"direct_bank",value:"direct_bank",label:"Direct Bank Transfer",hints:""},{key:"stripe_masspay",value:"stripe_masspay",label:"Stripe Connect",hints:""}],value:Object.keys(c).filter((e=>!0===c[e])),onChange:e=>{const t=e.target.value;u((e=>({...e,[t]:!e[t]})))},inputClass:"input-checkbox",rightContent:!0,rightContentClass:"wc-wizard-service-name",idPrefix:"multi-checkbox",hintInnerClass:"wc-wizard-gateway-description",inputInnerWrapperClass:"wc-wizard-service-toggle disabled",inputWrapperClass:"wc-wizard-service-enable"}),(0,e.createElement)("table",{className:"form-table"},(0,e.createElement)("tr",null,(0,e.createElement)("th",{scope:"row"},(0,e.createElement)("label",{htmlFor:"mvx_disbursal_mode_admin"},"Disbursal Schedule")),(0,e.createElement)("td",null,(0,e.createElement)(ct,{checked:r,onClick:()=>{o((e=>!e))},name:"mvx_disbursal_mode_admin",inputClass:"input-checkbox",value:"Enable",description:"If checked, automatically vendors commission will disburse."}))),r&&(0,e.createElement)("tr",null,(0,e.createElement)("th",{scope:"row"},(0,e.createElement)("label",{htmlFor:"payment_schedule"},"Set Schedule")),(0,e.createElement)("td",null,(0,e.createElement)(yi,{inputClass:"input-radio",value:s,options:[{keyName:"weekly",name:"payment_schedule",value:"weekly",label:"Weekly"},{keyName:"daily",name:"payment_schedule",value:"daily",label:"Daily"},{keyName:"monthly",name:"payment_schedule",value:"monthly",label:"Monthly"},{keyName:"fortnightly",name:"payment_schedule",value:"fortnightly",label:"Fortnightly"},{keyName:"hourly",name:"payment_schedule",value:"hourly",label:"Hourly"}],onChange:e=>{l(e.target.value)},idPrefix:"payment_schedule",activeClass:"active"}))),(0,e.createElement)("tr",null,(0,e.createElement)("th",{scope:"row"},(0,e.createElement)("label",{htmlFor:"mvx_disbursal_mode_vendor"},"Withdrawal Request")),(0,e.createElement)("td",null,(0,e.createElement)(ct,{onClick:()=>{a((e=>!e))},checked:i,name:"mvx_disbursal_mode_vendor",inputClass:"input-checkbox",value:"Enable",description:"Vendors can request for commission withdrawal."})))),(0,e.createElement)("p",{className:"wc-setup-actions step"},(0,e.createElement)(M,{type:"button",onClick:n.onNext,inputClass:"button button-large button-next",value:"Skip this step"}),(0,e.createElement)(M,{type:"submit",onClick:e=>{e.preventDefault();const t={mvx_disbursal_mode_admin:r,mvx_disbursal_mode_vendor:i,is_module_active:c,payment_schedule:s};at({method:"post",url:st("set_payment_setting"),headers:{"X-WP-Nonce":appLocalizer.nonce},data:t}).then((e=>{console.log("Settings saved successfully:",e.data),n.onNext()})).catch((e=>{console.error("Error saving settings:",e.response?e.response.data:e.message)}))},inputClass:"button-primary button button-large button-next",value:"Continue"}))))},wi=n=>{const[r,o]=(0,t.useState)({is_submit_product:!1,is_published_product:!1,is_edit_delete_published_product:!1,is_submit_coupon:!1,is_published_coupon:!1,is_edit_delete_published_coupon:!1,is_upload_files:!1});(0,t.useEffect)((()=>{at({method:"get",url:st("get_capability_setting"),headers:{"X-WP-Nonce":appLocalizer.nonce}}).then((e=>{const t=e.data;o((e=>({...e,...t})))})).catch((e=>{console.error("Error fetching capability settings:",e)}))}),[]);const i=e=>{o((t=>({...t,[e]:!t[e]})))};return(0,e.createElement)(e.Fragment,null,(0,e.createElement)("h1",null,"Capability"),(0,e.createElement)("div",{className:"mvx-setting-section-divider"}," "),(0,e.createElement)("form",{method:"post"},(0,e.createElement)("table",{className:"form-table"},(0,e.createElement)("tr",null,(0,e.createElement)("th",{scope:"row"},(0,e.createElement)("label",{htmlFor:"is_submit_product"},"Submit Products")),(0,e.createElement)("td",null,(0,e.createElement)(ct,{onClick:()=>i("is_submit_product"),checked:r.is_submit_product,name:"is_submit_product",className:"input-checkbox",value:"Enable",description:"Allow vendors to submit products for approval/publishing.",descClass:"description"}))),(0,e.createElement)("tr",null,(0,e.createElement)("th",{scope:"row"},(0,e.createElement)("label",{htmlFor:"is_published_product"},"Publish Products")),(0,e.createElement)("td",null,(0,e.createElement)(ct,{onClick:()=>i("is_published_product"),checked:r.is_published_product,name:"is_published_product",className:"input-checkbox",value:"Enable",description:"If checked, products uploaded by vendors will be directly published without admin approval.",descClass:"description"}))),(0,e.createElement)("tr",null,(0,e.createElement)("th",{scope:"row"},(0,e.createElement)("label",{htmlFor:"is_edit_delete_published_product"},"Edit Publish Products")),(0,e.createElement)("td",null,(0,e.createElement)(ct,{onClick:()=>i("is_edit_delete_published_product"),checked:r.is_edit_delete_published_product,name:"is_edit_delete_published_product",className:"input-checkbox",value:"Enable",description:"Allow vendors to Edit published products.",descClass:"description"}))),(0,e.createElement)("tr",null,(0,e.createElement)("th",{scope:"row"},(0,e.createElement)("label",{htmlFor:"is_submit_coupon"},"Submit Coupons")),(0,e.createElement)("td",null,(0,e.createElement)(ct,{onClick:()=>i("is_submit_coupon"),checked:r.is_submit_coupon,name:"is_submit_coupon",className:"input-checkbox",value:"Enable",description:"Allow vendors to create coupons.",descClass:"description"}))),(0,e.createElement)("tr",null,(0,e.createElement)("th",{scope:"row"},(0,e.createElement)("label",{htmlFor:"is_published_coupon"},"Publish Coupons")),(0,e.createElement)("td",null,(0,e.createElement)(ct,{onClick:()=>i("is_published_coupon"),checked:r.is_published_coupon,name:"is_published_coupon",className:"input-checkbox",value:"Enable",description:"If checked, coupons added by vendors will be directly published without admin approval.",descClass:"description"}))),(0,e.createElement)("tr",null,(0,e.createElement)("th",{scope:"row"},(0,e.createElement)("label",{htmlFor:"is_edit_delete_published_coupon"},"Edit Publish Coupons")),(0,e.createElement)("td",null,(0,e.createElement)(ct,{onClick:()=>i("is_edit_delete_published_coupon"),checked:r.is_edit_delete_published_coupon,name:"is_edit_delete_published_coupon",className:"input-checkbox",value:"Enable",description:"Allow Vendor To edit delete published shop coupons.",descClass:"description"}))),(0,e.createElement)("tr",null,(0,e.createElement)("th",{scope:"row"},(0,e.createElement)("label",{htmlFor:"is_upload_files"},"Upload Media Files")),(0,e.createElement)("td",null,(0,e.createElement)(ct,{onClick:()=>i("is_upload_files"),checked:r.is_upload_files,name:"is_upload_files",className:"input-checkbox",value:"Enable",description:"Allow vendors to upload media files.",descClass:"description"})))),(0,e.createElement)("p",{className:"wc-setup-actions step"},(0,e.createElement)(M,{type:"button",onClick:n.onNext,inputClass:"button button-large button-next",value:"Skip this step"}),(0,e.createElement)(M,{type:"submit",onClick:e=>{e.preventDefault(),at({method:"post",url:st("set_capability_setting"),headers:{"X-WP-Nonce":appLocalizer.nonce},data:r}).then((e=>{console.log("Settings saved successfully:",e.data),n.onNext()})).catch((e=>{console.error("Error saving settings:",e.response?e.response.data:e.message)}))},inputClass:"button-primary button button-large button-next",value:"Continue"}))))},Ci=n=>{const[r,o]=(0,t.useState)("niche"),[i,a]=(0,t.useState)(!1),[s,l]=(0,t.useState)({niche:!0,booking:!1,subscription:!1,rental:!1,auction:!1});return(0,t.useEffect)((()=>{at({method:"get",url:st("get_active_plugins"),headers:{"X-WP-Nonce":appLocalizer.nonce}}).then((e=>{const t=e.data;l((e=>({...e,...t})))})).catch((e=>{console.error("Error fetching active plugins:",e)}))}),[]),(0,e.createElement)(e.Fragment,null,(0,e.createElement)("h1",null,"Import Dummy Data"),(0,e.createElement)("div",{className:"mvx-setting-section-divider"}," "),(0,e.createElement)("form",{method:"post"},(0,e.createElement)("table",{className:"form-table"},(0,e.createElement)("tr",null,(0,e.createElement)("th",{scope:"row"},(0,e.createElement)("label",{htmlFor:"marketplace_type"},"Marketplace Type")),(0,e.createElement)("td",null,(0,e.createElement)(gi,{options:[{value:"niche",label:"Niche Marketplace"},{value:"booking",label:"Booking Marketplace"},{value:"subscription",label:"Subscription Marketplace"},{value:"rental",label:"Rental Marketplace"},{value:"auction",label:"Auction Marketplace"}],value:r,onChange:e=>{const t=e.value;o(t),s[t]?a(!1):a(!0)},inputClass:"wc-enhanced-select",description:"Dummy data will be imported based on the marketplace type.",descClass:"description"}),"booking"===r&&!s.booking&&(0,e.createElement)("p",{id:"booking-error",className:"woocommerce-error"},"WooCommerce Bookings pulgin is required to continue."),"subscription"===r&&!s.subscription&&(0,e.createElement)("p",{id:"subscription-error",className:"woocommerce-error"},"WooCommerce Subscriptions pulgin is required to continue."),"rental"===r&&!s.rental&&(0,e.createElement)("p",{id:"rental-error",className:"woocommerce-error"},"WooCommerce Booking & Rental pulgin is required to continue."),"auction"===r&&!s.auction&&(0,e.createElement)("p",{className:"woocommerce-error"},"WooCommerce Simple Auction pulgin is required to continue.")))),(0,e.createElement)("p",{className:"wc-setup-actions step"},(0,e.createElement)(M,{type:"button",onClick:n.onNext,inputClass:"button button-large button-next",value:"Skip this step"}),(0,e.createElement)("input",{onClick:e=>{e.preventDefault();const t={marketplace_type:r};at({method:"post",url:st("import_dummy_data"),headers:{"X-WP-Nonce":appLocalizer.nonce},data:t}).then((e=>{console.log("Data imported successfully:",e.data)})).catch((e=>{console.error("Error importing data:",e.response?e.response.data:e.message)}))},disabled:i,type:"submit",className:"button-primary button button-large button-next",value:"Continue"}))))},Mi=()=>{const n=window.location.protocol+"//"+window.location.host+"/"+window.location.pathname.split("/")[1];return(0,t.useEffect)((()=>{if(!document.getElementById("twitter-wjs")){const e=document.createElement("script");e.id="twitter-wjs",e.src="https://platform.twitter.com/widgets.js",document.body.appendChild(e)}}),[]),(0,e.createElement)(e.Fragment,null,(0,e.createElement)("div",{className:"mvx-all-done-page-header-sec"},(0,e.createElement)("i",{className:"mvx-font icon-yes"}),(0,e.createElement)("h1",{className:"mvx-title"},"Yay! All done!"),(0,e.createElement)("a",{href:"https://twitter.com/share",className:"twitter-button","data-url":n,"data-text":"Hey Guys! Our new marketplace is now live and ready to be ransacked! Check it out at","data-via":"wc_marketplace","data-size":"large"},(0,e.createElement)("i",{className:"mvx-font icon-twitter-setup-widget"})," Tweet")),(0,e.createElement)("div",{className:"woocommerce-message woocommerce-tracker"},(0,e.createElement)("p",null,"Your marketplace is ready. It's time to bring some sellers on your platform and start your journey. We wish you all the success for your business, you will be great!")),(0,e.createElement)("div",{className:"wc-setup-next-steps"},(0,e.createElement)("div",{className:"wc-setup-next-steps-first"},(0,e.createElement)("h2",null,"Next steps"),(0,e.createElement)("ul",null,(0,e.createElement)("li",{className:"setup-product"},(0,e.createElement)("a",{className:"button button-primary btn-red",href:appLocalizer.redirect_url+"admin.php?page=mvx#&submenu=settings&name=registration"},"Create your vendor registration form")))),(0,e.createElement)("div",{className:"wc-setup-next-steps-last"},(0,e.createElement)("h2",null,"Learn more"),(0,e.createElement)("ul",null,(0,e.createElement)("li",null," ",(0,e.createElement)("i",{className:"mvx-font icon-watch-setup-widget"}),(0,e.createElement)("a",{href:"https://www.youtube.com/c/MultivendorX"},"Watch the tutorial videos")),(0,e.createElement)("li",null," ",(0,e.createElement)("i",{className:"mvx-font icon-help-setup-widget"}),(0,e.createElement)("a",{href:"https://multivendorx.com/knowledgebase/mvx-setup-guide/?utm_source=mvx_plugin&utm_medium=setup_wizard&utm_campaign=new_installation&utm_content=documentation"},"Looking for help to get started")),(0,e.createElement)("li",null," ",(0,e.createElement)("i",{className:"mvx-font icon-Learn-more-setup-widget"}),(0,e.createElement)("a",{href:"https://multivendorx.com/best-revenue-model-marketplace-part-one/?utm_source=mvx_plugin&utm_medium=setup_wizard&utm_campaign=new_installation&utm_content=blog"},"Learn more about revenue models"))))))};(0,e.render)((0,e.createElement)((function(e){let{basename:n,children:i,future:d,window:p}=e,f=t.useRef();null==f.current&&(f.current=function(e){return void 0===e&&(e={}),function(e,t,n,i){void 0===i&&(i={});let{window:d=document.defaultView,v5Compat:p=!1}=i,f=d.history,m=o.Pop,h=null,g=b();function b(){return(f.state||{idx:null}).idx}function v(){m=o.Pop;let e=b(),t=null==e?null:e-g;g=e,h&&h({action:m,location:E.location,delta:t})}function y(e){let t="null"!==d.location.origin?d.location.origin:d.location.href,n="string"==typeof e?e:u(e);return s(t,"No window.location.(origin|href) available to create URL for href: "+n),new URL(n,t)}null==g&&(g=0,f.replaceState(r({},f.state,{idx:g}),""));let E={get action(){return m},get location(){return e(d,f)},listen(e){if(h)throw new Error("A history only accepts one active listener");return d.addEventListener(a,v),h=e,()=>{d.removeEventListener(a,v),h=null}},createHref:e=>t(d,e),createURL:y,encodeLocation(e){let t=y(e);return{pathname:t.pathname,search:t.search,hash:t.hash}},push:function(e,t){m=o.Push;let r=c(E.location,e,t);n&&n(r,e),g=b()+1;let i=l(r,g),a=E.createHref(r);try{f.pushState(i,"",a)}catch(e){if(e instanceof DOMException&&"DataCloneError"===e.name)throw e;d.location.assign(a)}p&&h&&h({action:m,location:E.location,delta:1})},replace:function(e,t){m=o.Replace;let r=c(E.location,e,t);n&&n(r,e),g=b();let i=l(r,g),a=E.createHref(r);f.replaceState(i,"",a),p&&h&&h({action:m,location:E.location,delta:0})},go:e=>f.go(e)};return E}((function(e,t){let{pathname:n,search:r,hash:o}=e.location;return c("",{pathname:n,search:r,hash:o},t.state&&t.state.usr||null,t.state&&t.state.key||"default")}),(function(e,t){return"string"==typeof t?t:u(t)}),null,e)}({window:p,v5Compat:!0}));let m=f.current,[h,g]=t.useState({action:m.action,location:m.location}),{v7_startTransition:y}=d||{},E=t.useCallback((e=>{y&&v?v((()=>g(e))):g(e)}),[g,y]);return t.useLayoutEffect((()=>m.listen(E)),[m,E]),t.createElement(b,{basename:n,children:i,location:h.location,navigationType:h.action,navigator:m})}),null,appLocalizer.woocommerce_installed?(0,e.createElement)((()=>{const[n,r]=(0,t.useState)(0),o=()=>{r(n+1)},i=()=>{window.location.href=appLocalizer.redirect_url},a=[{component:(0,e.createElement)(S,{onNext:o,exitWizard:i}),title:"Introduction"},{component:(0,e.createElement)(ut,{onNext:o}),title:"Store Setup"},{component:(0,e.createElement)(bi,{onNext:o}),title:"Commission Setup"},{component:(0,e.createElement)(Ei,{onNext:o}),title:"Payments"},{component:(0,e.createElement)(wi,{onNext:o}),title:"Capability"},{component:(0,e.createElement)(Ci,{onNext:o}),title:"Import Dummy Data"},{component:(0,e.createElement)(Mi,null),title:"Ready!"}];return(0,e.createElement)(e.Fragment,null,(0,e.createElement)("h1",{id:"wc-logo"},(0,e.createElement)("a",{href:"https://multivendorx.com/"},(0,e.createElement)("img",{src:"data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4NCjwhLS0gR2VuZXJhdG9yOiBBZG9iZSBJbGx1c3RyYXRvciAxOS4wLjAsIFNWRyBFeHBvcnQgUGx1Zy1JbiAuIFNWRyBWZXJzaW9uOiA2LjAwIEJ1aWxkIDApICAtLT4NCjxzdmcgdmVyc2lvbj0iMS4xIiBpZD0iTGF5ZXJfMSIgeG1sbnM9Imh0dHA6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Hg9IjE2NC40IiB5PSIzMy41IiBjbGFzcz0ic3QzIiB3aWR0aD0iMS40IiBoZWlnaHQ9IjEuNCIvPg0KCQkJPHJlY3QgaWQ9IlhNTElEXzVfIiB4PSIxNjUuMSIgeT0iMzIuMSIgY2xhc3M9InN0MyIgd2lkdGg9IjAuNyIgaGVpZ2h0PSIwLjciLz4NCgkJPC9nPg0KCTwvZz4NCjwvZz4NCjwvc3ZnPg0K",alt:"MultivendorX"}))),(0,e.createElement)("ol",{className:"wc-setup-steps"},a.map(((t,r)=>(0,e.createElement)("li",{key:r,className:n>=r?"active":""},t.title)))),(0,e.createElement)("div",{className:"wc-setup-content"},a[n].component),n===a.length-1&&(0,e.createElement)("a",{className:"wc-return-to-dashboard",onClick:i},"Return to the WordPress Dashboard"))}),null):(0,e.createElement)((()=>(0,e.createElement)("div",{className:"mvx-install-woocommerce"},(0,e.createElement)("p",null,"MultivendorX requires WooCommerce plugin to be active!"),(0,e.createElement)("form",{onSubmit:e=>{e.preventDefault(),axios({method:"get",url:getApiLink("install_woocommerce"),headers:{"X-WP-Nonce":appLocalizer.nonce}}).then((e=>{console.log("WooCommerce installed successfully:",e.data),window.location.href=e.redirect})).catch((e=>{console.error("Error installing WooCommerce:",e.response?e.response.data:e.message)}))},name:"mvx_install_woocommerce"},(0,e.createElement)("button",{type:"submit",className:"button button-primary"},"Install WooCommerce")))),null)),document.getElementById("mvx_setup_wizard"))})()})(); \ No newline at end of file diff --git a/mvx-modules/build/blocks/setupWizard/index.js.map b/mvx-modules/build/blocks/setupWizard/index.js.map new file mode 100644 index 00000000..85fb968d --- /dev/null +++ b/mvx-modules/build/blocks/setupWizard/index.js.map @@ -0,0 +1 @@ +{"version":3,"file":"blocks/setupWizard/index.js","mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,oBAAoB,sBAAsB;AAC1C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC,wBAAwB;AACzB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ,eAAe;AACf;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA,KAAK;AACL;AACA;AACA,KAAK;AACL;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,0CAA0C;AAC1C;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC,gCAAgC;AACjC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,kCAAkC;AAClC;AACA,OAAO;AACP;AACA;AACA,MAAM;AACN,yCAAyC;AACzC;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,kBAAkB,wCAAwC;AAC1D;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA,kBAAkB,uBAAuB;AACzC;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG,IAAI;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,uBAAuB;AACvB;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA,2BAA2B;AAC3B,IAAI;AACJ;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,uCAAuC,cAAc;AACrD;AACA;AACA;AACA;AACA,yBAAyB,mBAAmB;AAC5C,iCAAiC,eAAe;AAChD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ,oBAAoB;AACpB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA,mDAAmD;AACnD;AACA,uDAAuD;AACvD;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP,KAAK,IAAI;AACT;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,0BAA0B;AAC1B;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP,KAAK,IAAI;AACT;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA,uCAAuC;AACvC;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC;AACD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA,KAAK;AACL,IAAI;AACJ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,yEAAyE;AACzE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,QAAQ;AACR;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,aAAa;AACb;AACA;AACA,WAAW;AACX;AACA;AACA;AACA;AACA;AACA,aAAa;AACb;AACA,SAAS;AACT;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,uBAAuB;AACvB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,QAAQ;AACR;AACA;AACA;AACA,MAAM;AACN;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,uCAAuC,yCAAyC;AAChF;AACA,MAAM;AACN;AACA;AACA,2BAA2B;AAC3B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA,8BAA8B;AAC9B;AACA;AACA;AACA;AACA,MAAM,kCAAkC;AACxC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,WAAW;AACX;AACA;AACA,SAAS;AACT;AACA;AACA;AACA;AACA;AACA,WAAW;AACX;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA,QAAQ;AACR;AACA;AACA;AACA;AACA,sBAAsB;AACtB;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA,MAAM,IAAI;AACV;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,QAAQ;AACR;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,6BAA6B;AAC7B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,sBAAsB;AACtB;AACA;AACA,OAAO;AACP;AACA,QAAQ,IAAI;AACZ;AACA,QAAQ,IAAI;AACZ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA,OAAO;AACP;AACA,QAAQ;AACR;AACA,QAAQ,IAAI;AACZ;AACA,QAAQ,IAAI;AACZ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA,MAAM,IAAI;AACV;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT;AACA,QAAQ;AACR;AACA;AACA;AACA;AACA;AACA,SAAS;AACT;AACA;AACA;AACA,SAAS;AACT;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA,QAAQ,IAAI;AACZ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT;AACA,QAAQ;AACR;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM,wBAAwB;AAC9B;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA,MAAM,IAAI;AACV;AACA;AACA;AACA;AACA;AACA;AACA,QAAQ;AACR;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,UAAU;AACV;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,+BAA+B;AAC/B;AACA,SAAS;AACT;AACA;AACA,OAAO;AACP,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,QAAQ;AACR;AACA;AACA;AACA;AACA,WAAW;AACX;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA,KAAK;AACL;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA,KAAK;AACL,IAAI;AACJ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM,yBAAyB;AAC/B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA,QAAQ;AACR;AACA;AACA;AACA;AACA,sBAAsB;AACtB;AACA;AACA;AACA,SAAS;AACT;AACA,yBAAyB;AACzB,yBAAyB;AACzB;AACA;AACA,MAAM;AACN;AACA;AACA,OAAO;AACP;AACA;AACA;AACA,QAAQ;AACR;AACA;AACA;AACA;AACA,sBAAsB;AACtB;AACA;AACA;AACA,SAAS;AACT;AACA,yBAAyB;AACzB,yBAAyB;AACzB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM,yBAAyB;AAC/B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP,MAAM;AACN;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP,MAAM;AACN;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,sDAAsD;AACtD;AACA;AACA,OAAO;AACP,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,sBAAsB;AACtB;AACA;AACA,SAAS;AACT;AACA;AACA;AACA;AACA,yBAAyB;AACzB,yBAAyB;AACzB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA,wBAAwB;AACxB;AACA;AACA,kCAAkC;AAClC;AACA,UAAU,IAAI;AACd,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA,sBAAsB;AACtB;AACA,MAAM,IAAI;AACV;AACA;AACA,OAAO;AACP,gCAAgC;AAChC;AACA,QAAQ,IAAI;AACZ,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA,gIAAgI;AAChI;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS,KAAK;AACd;AACA;AACA,yBAAyB;AACzB;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL,sBAAsB;AACtB;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,8BAA8B;AAC9B;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,QAAQ;AACR;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA,IAAI;AACJ;AACA;AACA,IAAI;AACJ;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,0CAA0C;AAC1C;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,QAAQ;AACR;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,UAAU;AACV;AACA;AACA;AACA;AACA;AACA;AACA,WAAW;AACX,UAAU;AACV;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA,OAAO;AACP,MAAM;AACN;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,QAAQ;AACR;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA,MAAM;AACN;AACA;AACA,MAAM;AACN;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA,QAAQ;AACR;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA,sBAAsB,qCAAqC;AAC3D;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA,4BAA4B;AAC5B;AACA,SAAS;AACT;AACA;AACA,MAAM;AACN;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,oCAAoC;AACpC;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,gBAAgB;AAChB;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI,yBAAyB;AAC7B;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA,MAAM;AACN;AACA;AACA,IAAI;AACJ;AACA;AACA,IAAI;AACJ;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA,mCAAmC,QAAQ;AAC3C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,+BAA+B;AAC/B;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,sBAAsB,wBAAwB;AAC9C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEurB;AACvrB;;;;;;;;;;;;;;;;;;ACr8HA;AACA,sBAAsB,sEAAsE,gBAAgB,sBAAsB,OAAO,2BAA2B,0BAA0B,yDAAyD,iCAAiC,kBAAkB;AAC3Q;AAC/B;AACA,sBAAsB,gDAAmB;AACzC;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA,GAAG,2CAA2C,gDAAmB,+CAA+C,aAAa,8BAA8B,aAAa,kBAAkB,gDAAmB;AAC7M;AACA,GAAG,2BAA2B,gDAAmB;AACjD;AACA,GAAG,eAAe,gDAAmB;AACrC;AACA;AACA;AACA,GAAG,gBAAgB,gDAAmB;AACtC;AACA;AACA;AACA,GAAG,gBAAgB,gDAAmB;AACtC;AACA;AACA;AACA,GAAG,gBAAgB,gDAAmB;AACtC;AACA;AACA;AACA,GAAG,gBAAgB,gDAAmB;AACtC;AACA;AACA;AACA,GAAG,gBAAgB,gDAAmB;AACtC;AACA;AACA;AACA,GAAG,gBAAgB,gDAAmB;AACtC;AACA;AACA;AACA,GAAG,gBAAgB,gDAAmB;AACtC;AACA;AACA;AACA,GAAG,gBAAgB,gDAAmB;AACtC;AACA;AACA;AACA,GAAG,gBAAgB,gDAAmB;AACtC;AACA;AACA;AACA,GAAG,gBAAgB,gDAAmB;AACtC;AACA;AACA;AACA,GAAG,kBAAkB,gDAAmB;AACxC;AACA,GAAG,eAAe,gDAAmB;AACrC;AACA,GAAG,eAAe,gDAAmB;AACrC;AACA;AACA;AACA;AACA;AACA;AACA,GAAG,eAAe,gDAAmB;AACrC;AACA;AACA;AACA;AACA,GAAG,gBAAgB,gDAAmB;AACtC;AACA;AACA;AACA;AACA,GAAG,gBAAgB,gDAAmB;AACtC;AACA;AACA;AACA;AACA,GAAG,iBAAiB,gDAAmB;AACvC;AACA;AACA;AACA;AACA;AACA,GAAG,gBAAgB,gDAAmB;AACtC;AACA;AACA;AACA;AACA;AACA;AACA,GAAG,eAAe,gDAAmB;AACrC;AACA;AACA;AACA;AACA,GAAG,gBAAgB,gDAAmB;AACtC;AACA;AACA;AACA;AACA,GAAG,gBAAgB,gDAAmB;AACtC;AACA;AACA;AACA;AACA,GAAG,iBAAiB,gDAAmB;AACvC;AACA;AACA;AACA;AACA;AACA,GAAG,+BAA+B,gDAAmB;AACrD;AACA,GAAG,eAAe,gDAAmB;AACrC;AACA;AACA;AACA,GAAG,gBAA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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AChDD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAC+B;AAC6Q;AACghB;AACvpB;;AAErK;AACA;AACA,oBAAoB,sBAAsB;AAC1C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,cAAc,uBAAuB;AACrC;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI,KAAqC,GAAG,4DAAc,8IAA8I,CAAM;AAC9M;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,oBAAoB,2DAAa;AACjC;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,oBAAoB,2DAAa;AACjC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,QAAQ;AACR;AACA;AACA;AACA;AACA,QAAQ;AACR;AACA;AACA;AACA,IAAI;AACJ;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA,SAAS,0DAAY;AACrB;AACA,uBAAuB;AACvB;AACA,KAAK;AACL,aAAa,kEAAoB;AACjC;AACA,KAAK;AACL;AACA;AACA,wBAAwB,mEAAyB;AACjD,GAAG;AACH;AACA;AACA,SAAS,0DAAY;AACrB;AACA,uBAAuB;AACvB;AACA,KAAK;AACL,aAAa,+DAAiB;AAC9B;AACA,KAAK;AACL;AACA;AACA,wBAAwB,mEAAyB;AACjD,GAAG;AACH;AACA;AACA;AACA;AACA;AACA,uBAAuB;AACvB;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,4BAA4B,uDAAa;AACzC,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,YAAY;AACZ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,aAAa,kBAAkB;AAC/B;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,4BAA4B,kCAAK;AACjC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ,mBAAmB,yCAAY;AAC/B;AACA,yBAAyB,kEAAoB;AAC7C;AACA;AACA,KAAK;AACL;AACA;AACA,8BAA8B,2CAAc;AAC5C;AACA;AACA,GAAG;AACH;AACA;AACA,IAAI;AACJ,iBAAiB,8CAAiB;AAClC;AACA,GAAG;AACH,EAAE,kDAAqB;AACvB,sBAAsB,gDAAmB,CAAC,gDAAM;AAChD;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ,mBAAmB,yCAAY;AAC/B;AACA,yBAAyB,+DAAiB;AAC1C;AACA;AACA,KAAK;AACL;AACA;AACA,8BAA8B,2CAAc;AAC5C;AACA;AACA,GAAG;AACH;AACA;AACA,IAAI;AACJ,iBAAiB,8CAAiB;AAClC;AACA,GAAG;AACH,EAAE,kDAAqB;AACvB,sBAAsB,gDAAmB,CAAC,gDAAM;AAChD;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ,8BAA8B,2CAAc;AAC5C;AACA;AACA,GAAG;AACH;AACA;AACA,IAAI;AACJ,iBAAiB,8CAAiB;AAClC;AACA,GAAG;AACH,EAAE,kDAAqB;AACvB,sBAAsB,gDAAmB,CAAC,gDAAM;AAChD;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA,IAAI,IAAqC;AACzC;AACA;AACA;AACA;AACA;AACA;AACA;AACA,0BAA0B,6CAAgB;AAC1C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA,IAAI,EAAE,6CAAgB,CAAC,kEAAwB;AAC/C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,mBAAmB,2DAAa;AAChC;AACA;AACA;AACA,UAAU;AACV;AACA;AACA,QAAQ;AACR;AACA,QAAQ,KAAqC,GAAG,4DAAc,+IAA+I,CAAM;AACnN;AACA;AACA;AACA;AACA,aAAa,qDAAO;AACpB;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI,gDAAmB,iBAAiB;AACxC;AACA;AACA;AACA;AACA,KAAK;AACL;AACA,CAAC;AACD,IAAI,IAAqC;AACzC;AACA;AACA;AACA;AACA;AACA,6BAA6B,6CAAgB;AAC7C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA,aAAa,6DAAe;AAC5B;AACA,GAAG;AACH,iBAAiB,yDAAW;AAC5B,oBAAoB,6CAAgB,CAAC,uEAA6B;AAClE;AACA;AACA,IAAI,EAAE,6CAAgB,CAAC,kEAAwB;AAC/C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL,IAAI;AACJ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH,sBAAsB,gDAAmB,kBAAkB;AAC3D;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA,GAAG;AACH,CAAC;AACD,IAAI,IAAqC;AACzC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,0BAA0B,6CAAgB;AAC1C;AACA,sBAAsB,gDAAmB,sBAAsB;AAC/D;AACA;AACA,GAAG;AACH,CAAC;AACD,IAAI,IAAqC;AACzC;AACA;AACA,8BAA8B,6CAAgB;AAC9C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA,sBAAsB,gDAAmB;AACzC;AACA;AACA;AACA;AACA,GAAG;AACH,CAAC;AACD,IAAI,IAAqC;AACzC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA,GAAG;AACH;AACA;AACA,IAAI,IAAqC;AACzC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC,wCAAwC;AACzC;AACA;AACA;AACA;AACA,CAAC,kDAAkD;AACnD;AACA;AACA;AACA;AACA,YAAY,6CAAgB,CAAC,kEAAwB;AACrD,SAAS,KAAqC,GAAG,8DAAgB,+CAA+C,CAAuB;AACvI;AACA;AACA;AACA,cAAc,6CAAgB,CAAC,uEAA6B;AAC5D,WAAW,KAAqC,GAAG,8DAAgB,+CAA+C,CAAuB;AACzI;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI,wBAAwB;AAC5B,iBAAiB,yDAAW;AAC5B,iBAAiB,yDAAW;AAC5B,aAAa,6DAAe;AAC5B;AACA,GAAG;AACH,SAAS,8CAAiB;AAC1B;AACA;AACA;AACA;AACA,8DAA8D,wDAAU,eAAe,wDAAU;AACjG;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA,EAAE,KAAqC,GAAG,4DAAc,ghBAAghB,CAAM;AAC9kB,+BAA+B,yCAAY;AAC3C,8BAA8B,yCAAY;AAC1C,iBAAiB,yDAAW;AAC5B,qBAAqB,0CAAa;AAClC;AACA;AACA,2CAA2C;AAC3C;AACA,iBAAiB,yDAAW;AAC5B,wBAAwB,8CAAiB;AACzC;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA,IAAI,EAAE,6CAAgB,CAAC,kEAAwB;AAC/C,uBAAuB,+DAAiB;AACxC,SAAS,8CAAiB;AAC1B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA,IAAI,EAAE,6CAAgB,CAAC,kEAAwB;AAC/C,SAAS,8CAAiB;AAC1B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN,gCAAgC,KAAqC,GAAG,8DAAgB,mDAAmD,CAAuB;AAClK;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA,IAAI,yBAAyB;AAC7B;AACA;AACA,IAAI,EAAE,6CAAgB,CAAC,kEAAwB;AAC/C,qBAAqB,6CAAgB,CAAC,6DAAmB;AACzD,kBAAkB,KAAqC,GAAG,8DAAgB,8DAA8D,CAAuB;AAC/J;AACA;AACA;AACA,wBAAwB,EAAE,6DAAe;AACzC;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA,iBAAiB,yDAAW;AAC5B;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,uDAAuD,uDAAS;AAChE;AACA,SAAS,wDAAU;AACnB;AACA;AACA,iCAAiC,6CAAgB;AACjD;AACA,wBAAwB,gDAAmB,sBAAsB;AACjE;AACA;AACA,KAAK;AACL,GAAG;AACH,MAAM,IAAqC;AAC3C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ,cAAc,6CAAgB,CAAC,6DAAmB;AAClD,WAAW,KAAqC,GAAG,8DAAgB,2DAA2D,CAAuB;AACrJ;AACA,uBAAuB,KAAqC,GAAG,8DAAgB,gFAAgF,CAAuB;AACtL,qBAAqB,2CAAc;AACnC,eAAe,2CAAc;AAC7B,eAAe,KAAqC,GAAG,8DAAgB,qDAAqD,CAAuB;AACnJ;AACA,GAAG;AACH,eAAe,2CAAc;AAC7B,cAAc,KAAqC,GAAG,8DAAgB,oDAAoD,CAAuB;AACjJ,eAAe,KAAqC,GAAG,8DAAgB,qDAAqD,CAAuB;AACnJ;AACA,GAAG;AACH;AACA;AACA,8BAA8B,0CAAa;AAC3C;AACA;AACA;AACA,GAAG;AACH,EAAE,4CAAe;AACjB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI,yBAAyB;AAC7B;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA,IAAI,EAAE,6CAAgB,CAAC,kEAAwB;AAC/C,iBAAiB,yDAAW;AAC5B,gBAAgB,wDAAU;AAC1B,mBAAmB,2DAAa;AAChC;AACA,EAAE,4CAAe;AACjB;AACA;AACA;AACA;AACA,GAAG;AACH;AACA,cAAc,8CAAiB;AAC/B;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA,IAAI,kDAAqB;AACzB;AACA;AACA;AACA;AACA;AACA,QAAQ;AACR;AACA;AACA,KAAK;AACL;AACA;AACA,IAAI,kDAAqB;AACzB;AACA,iBAAiB;AACjB,kBAAkB,2DAAa;AAC/B,OAAO;AACP;AACA;AACA,KAAK;AACL;AACA;AACA,IAAI,kDAAqB;AACzB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ,EAAE,4CAAe;AACjB;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ,EAAE,4CAAe;AACjB;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ,gBAAgB,iEAAmB;AACnC,EAAE,4CAAe;AACjB;AACA;AACA;AACA;AACA;AACA;AACA;AACA,QAAQ;AACR;AACA;AACA;AACA,GAAG;AACH,EAAE,4CAAe;AACjB;AACA;AACA;AACA,GAAG;AACH;AACA;;AAEiX;AACjX;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AC1jCA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAC+B;AACsP;AACzD;;AAE5N;AACA;AACA,oBAAoB,sBAAsB;AAC1C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA,uCAAuC,gDAAmB;AAC1D,IAAI,IAAqC;AACzC;AACA;AACA,4CAA4C,gDAAmB;AAC/D,IAAI,IAAqC;AACzC;AACA;AACA,kCAAkC,gDAAmB;AACrD,IAAI,IAAqC;AACzC;AACA;;AAEA;AACA,wCAAwC;AACxC;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,uCAAuC,gDAAmB;AAC1D,IAAI,IAAqC;AACzC;AACA;AACA,qCAAqC,gDAAmB;AACxD,IAAI,IAAqC;AACzC;AACA;AACA,kCAAkC,gDAAmB;AACrD;AACA;AACA;AACA,CAAC;AACD,IAAI,IAAqC;AACzC;AACA;AACA,uCAAuC,gDAAmB;AAC1D,IAAI,IAAqC;AACzC;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI,wBAAwB;AAC5B,0BAA0B,KAAqC,GAAG,mEAAgB;AAClF;AACA,0EAA0E,CAAuB;AACjG;AACA;AACA;AACA,IAAI,EAAE,6CAAgB;AACtB;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA,GAAG;AACH;;AAEA;AACA;AACA;AACA;AACA;AACA,mDAAmD,4DAAS;AAC5D;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS,6CAAgB;AACzB;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,0BAA0B,KAAqC,GAAG,mEAAgB;AAClF;AACA,8EAA8E,CAAuB;AACrG,SAAS,6CAAgB;AACzB;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS,6CAAgB;AACzB;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,0BAA0B,KAAqC,GAAG,mEAAgB;AAClF;AACA,2EAA2E,CAAuB;AAClG;AACA;AACA,IAAI;AACJ,SAAS,0CAAa,OAAO,4DAAS;AACtC;;AAEA;AACA;AACA;;AAEA;;AAEA;AACA;AACA,iBAAiB,6CAAgB;AACjC;AACA;AACA;AACA;AACA,IAAI,kDAAqB;AACzB;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI,EAAE,6CAAgB;AACtB;AACA;AACA;AACA;AACA;AACA,0BAA0B,KAAqC,GAAG,mEAAgB;AAClF;AACA,8EAA8E,CAAuB;AACrG,0BAA0B,6CAAgB;AAC1C;AACA;AACA;AACA,IAAI,EAAE,6CAAgB;AACtB;AACA;AACA,IAAI,EAAE,6CAAgB;AACtB;AACA;AACA,IAAI;AACJ,0CAA0C,oFAAiC;AAC3E,kBAAkB,yCAAY;AAC9B;AACA;AACA,GAAG;AACH,iBAAiB,8CAAiB;AAClC;AACA;AACA;AACA,IAAI,KAAqC,GAAG,iEAAc,6CAA6C,CAAM;;AAE7G;AACA;AACA;AACA;AACA;AACA;AACA;AACA,eAAe,4DAAS;;AAExB;AACA;AACA;AACA;AACA;AACA;AACA;AACA,yDAAyD,4DAAS;AAClE;AACA;AACA,GAAG;AACH;AACA;AACA,mCAAmC,gDAAmB;;AAEtD;AACA;AACA;AACA;AACA;AACA;AACA,SAAS,6CAAgB;AACzB;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,eAAe,6CAAgB;AAC/B;AACA,wBAAwB,gDAAmB;AAC3C;AACA,KAAK;AACL;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI,EAAE,6CAAgB;AACtB;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI,yBAAyB;AAC7B;AACA;AACA,IAAI,EAAE,6CAAgB;AACtB;AACA;AACA,IAAI;AACJ,0CAA0C,oFAAiC;AAC3E,SAAS,0CAAa,OAAO,4DAAS;AACtC;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA,0BAA0B,KAAqC,GAAG,mEAAgB;AAClF;AACA,4EAA4E,CAAuB;AACnG;AACA;AACA,IAAI,EAAE,6CAAgB;AACtB;AACA;AACA,IAAI,EAAE,6CAAgB;AACtB;AACA;AACA;AACA;AACA;AACA,MAAM,IAAqC;AAC3C;AACA;AACA;AACA;AACA;AACA;AACA;AACA,UAAU;AACV;AACA,qCAAqC,UAAU;AAC/C,0CAA0C,cAAc;AACxD;AACA;AACA;AACA;AACA;AACA,6CAA6C,UAAU;AACvD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,8DAA8D,4DAAS;AACvE,sKAAsK,KAAqC,GAAG,mEAAgB,wXAAwX,CAAuB;AAC7mB;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA,gBAAgB,8DAAW;AAC3B;AACA,GAAG;AACH,MAAM,IAAqC;AAC3C,IAAI,KAAqC,GAAG,iEAAc,kIAAkI,CAAM;AAClM,IAAI,KAAqC,GAAG,iEAAc,oYAAoY,CAAM;AACpc;AACA,uFAAuF;AACvF,4BAA4B;AAC5B,cAAc,4DAAS;AACvB;AACA;AACA,oEAAoE,4DAAS;AAC7E;AACA;AACA,GAAG;;AAEH;AACA;AACA;AACA;AACA,wBAAwB,gDAAmB;AAC3C;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS;AACT,wBAAwB,qDAAM;AAC9B;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA,gBAAgB,uEAAoB;AACpC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM,IAAqC;AAC3C;AACA,2BAA2B,gDAAmB,CAAC,2CAAc,qBAAqB,gDAAmB,qEAAqE,gDAAmB,yHAAyH,gDAAmB;AACzU;AACA,KAAK,6CAA6C,gDAAmB;AACrE;AACA,KAAK;AACL;AACA,sBAAsB,gDAAmB,CAAC,2CAAc,qBAAqB,gDAAmB,4DAA4D,gDAAmB;AAC/K;AACA;AACA;AACA,GAAG,iCAAiC,gDAAmB;AACvD;AACA,GAAG;AACH;AACA,yCAAyC,gDAAmB;AAC5D,kCAAkC,4CAAe;AACjD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,2CAA2C,gDAAmB;AAC9D;AACA,KAAK,eAAe,gDAAmB;AACvC;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ,0BAA0B,6CAAgB;;AAE1C;AACA;AACA;AACA;AACA;AACA,sBAAsB,gDAAmB;AACzC;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA,yBAAyB,KAAqC,GAAG,mEAAgB,uGAAuG,CAAuB;AAC/M;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,QAAQ;AACR;AACA;AACA;AACA,8BAA8B,IAAI;AAClC;AACA;AACA,gCAAgC,gDAAmB;AACnD,QAAQ;AACR;AACA,QAAQ;AACR;AACA;AACA,0BAA0B,gDAAmB;AAC7C;AACA;AACA;AACA;AACA;AACA,SAAS;AACT;AACA,OAAO;AACP;AACA;AACA;AACA;AACA,oHAAoH,gDAAmB;AACvI;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA,CAAC,qBAAqB;AACtB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC,0BAA0B;AAC3B;AACA;AACA;AACA;AACA,YAAY,6CAAgB;AAC5B,SAAS,KAAqC,GAAG,mEAAgB,+CAA+C,CAAuB;AACvI;AACA;AACA;AACA,cAAc,6CAAgB;AAC9B,WAAW,KAAqC,GAAG,mEAAgB,+CAA+C,CAAuB;AACzI;AACA;AACA;AACA,cAAc,6CAAgB;AAC9B,WAAW,KAAqC,GAAG,mEAAgB,+CAA+C,CAAuB;AACzI;AACA;;AAEA;AACA;AACA;AACA;AACA,wBAAwB,KAAqC,GAAG,mEAAgB,iFAAiF,CAAuB;AACxL;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAAS,0CAAa;AACtB;AACA;AACA,GAAG;AACH;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ,SAAS,0CAAa;AACtB;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA,cAAc,6CAAgB;AAC9B,WAAW,KAAqC,GAAG,mEAAgB,8DAA8D,CAAuB;AACxJ,wEAAwE;AACxE;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,cAAc,6CAAgB;AAC9B;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA,cAAc,6CAAgB;AAC9B;AACA;;AAEA;AACA;AACA;AACA;AACA,cAAc,6CAAgB;AAC9B;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA,oCAAoC,2CAAc;AAClD,wBAAwB,8CAAiB;AACzC;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA,kCAAkC;AAClC,kBAAkB,gEAAa;AAC/B,OAAO;AACP,+BAA+B;AAC/B,kBAAkB,gEAAa;AAC/B,OAAO;AACP;AACA,KAAK;AACL,GAAG;;AAEH;AACA;AACA,EAAE,4CAAe;AACjB;AACA;AACA;AACA,GAAG;;AAEH;AACA;AACA;AACA;AACA,EAAE,4CAAe;AACjB;AACA;AACA;AACA,GAAG;;AAEH;AACA;AACA,yFAAyF,2DAAY;AACrG;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA,kBAAkB,yCAAY;AAC9B;AACA;AACA,GAAG;AACH,iBAAiB,8CAAiB;AAClC;AACA;AACA;AACA,IAAI,KAAqC,GAAG,iEAAc,6CAA6C,CAAM;;AAE7G;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA,OAAO;AACP;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA,IAAI,KAAqC,GAAG,iEAAc,mBAAmB,CAAM;AACnF;AACA;;AAEA;AACA;AACA;AACA,aAAa,kBAAkB;AAC/B;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,4BAA4B,kCAAK;;AAEjC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA,8BAA8B,2CAAc;AAC5C;AACA;AACA,IAAI;AACJ,iBAAiB,8CAAiB;AAClC;AACA,GAAG;AACH,EAAE,kDAAqB;AACvB,kBAAkB,0CAAa;AAC/B;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA;AACA;AACA,OAAO;AACP;AACA,GAAG;AACH;AACA,0BAA0B,0CAAa;AACvC;AACA;AACA;AACA;AACA,GAAG;;AAEH,uBAAuB,MAAM;AAC7B;AACA;AACA;AACA;AACA;AACA,sBAAsB,gDAAmB,CAAC,2CAAc,qBAAqB,gDAAmB;AAChG;AACA,GAAG,eAAe,gDAAmB;AACrC;AACA,GAAG,eAAe,gDAAmB;AACrC;AACA;AACA;AACA;AACA,GAAG,mCAAmC,gDAAmB;AACzD;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ,mBAAmB,yCAAY;AAC/B;AACA,yBAAyB,sEAAmB;AAC5C;AACA;AACA;AACA,KAAK;AACL;AACA;AACA,8BAA8B,2CAAc;AAC5C;AACA;AACA,GAAG;AACH;AACA;AACA,IAAI;AACJ,iBAAiB,8CAAiB;AAClC;AACA,GAAG;AACH,EAAE,kDAAqB;AACvB,sBAAsB,gDAAmB;AACzC;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ,0BAA0B,KAAqC,GAAG,mEAAgB;AAClF;AACA,2EAA2E,CAAuB;AAClG,EAAE,KAAqC,GAAG,iEAAc,EAAE,6CAAgB,iQAAiQ,CAAM;AACjV;AACA;AACA,IAAI,EAAE,6CAAgB;AACtB;AACA;AACA,IAAI;AACJ;;AAEA;AACA;AACA,aAAa,4DAAS,KAAK,oFAAiC;AAC5D;AACA,EAAE,4CAAe;AACjB;AACA;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,EAAE,KAAqC,GAAG,mEAAgB,uJAAuJ,CAAuB;AACxO;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,qBAAqB,qDAAM;AAC3B;AACA;AACA,IAAI;AACJ,2BAA2B,KAAqC,GAAG,mEAAgB,yHAAyH,CAAuB;;AAEnO;AACA;AACA;AACA,0BAA0B,0CAAa;AACvC;AACA;AACA;AACA,GAAG;AACH;AACA,mBAAmB,4DAAS;AAC5B;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ,wBAAwB,0CAAa;AACrC,2BAA2B,gEAAa;AACxC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA,GAAG;AACH,EAAE,KAAqC,GAAG,iEAAc,wOAAwO,CAAM;AACtS;AACA;AACA;AACA,sBAAsB,gDAAmB;AACzC;AACA,GAAG,eAAe,gDAAmB;AACrC;AACA;AACA,GAAG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ,sBAAsB,gDAAmB;AACzC;AACA;AACA,GAAG,eAAe,gDAAmB;AACrC;AACA;AACA;AACA;AACA;AACA;AACA,CAAC,wBAAwB;AACzB,gDAAgD;AAChD,iCAAiC,4CAAe;AAChD;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA,OAAO;AACP,MAAM;AACN;AACA;AACA;AACA,+CAA+C,GAAG;AAClD;AACA;AACA,OAAO;AACP;AACA;AACA,OAAO;AACP,MAAM;AACN;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA,OAAO;AACP;AACA;AACA,OAAO;AACP;AACA,OAAO;AACP;AACA,wEAAwE,mEAAoB;AAC5F;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,0BAA0B,gDAAmB;AAC7C;AACA;AACA,OAAO;AACP;AACA;AACA;AACA,0BAA0B,gDAAmB;AAC7C;AACA;AACA,OAAO;AACP;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA,sBAAsB,gDAAmB,CAAC,2CAAc;AACxD;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,EAAE,2CAAc;AAChB,uBAAuB,iDAAoB;AAC3C;AACA;AACA;AACA;AACA;AACA,yBAAyB,2CAAc;AACvC;AACA;AACA;AACA;AACA,gCAAgC,KAAqC,GAAG,mEAAgB,kMAAkM,CAAuB;AACjT,yDAAyD,KAAqC,GAAG,mEAAgB,sDAAsD,CAAuB;AAC9L;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,QAAQ,IAAqC;AAC7C;AACA,QAAQ,KAAqC,GAAG,iEAAc,kHAAkH,CAAM;AACtL;AACA;AACA;AACA,4BAA4B,gDAAmB;AAC/C;AACA,KAAK;AACL;AACA;AACA,QAAQ,IAAqC;AAC7C;AACA,QAAQ,KAAqC,GAAG,iEAAc,+HAA+H,CAAM;AACnM;AACA;AACA;AACA,iCAAiC,gDAAmB;AACpD;AACA,KAAK;AACL;AACA;AACA;AACA;AACA,SAAS,+DAAY;AACrB;AACA,uBAAuB;AACvB;AACA,KAAK;AACL,aAAa,sEAAmB;AAChC;AACA;AACA,KAAK;AACL;AACA;AACA;AACA,GAAG;AACH;;AAEg3B;AACh3B;;;;;;;;;;;ACh1CA;;;;;;;;;;ACAA;;;;;;;;;;;;;;;;;;ACAgC;AACI;AACF;AACa;;AAE/C;AACA,QAAQ,gDAAW;AACnB,OAAO,+CAAU;AACjB;;AAEA,iDAAK;AACL;AACA;AACA,yCAAyC,MAAM;AAC/C,MAAM;AACN;AACA;AACA,8CAA8C,MAAM;AACpD;AACA,CAAC;;AAED,iEAAe;AACf;AACA,eAAe,iDAAK;;AAEpB,WAAW,QAAQ;AACnB;AACA;;AAEA,oBAAoB,YAAY;AAChC;AACA,oBAAoB,iDAAK;AACzB;AACA;AACA;;AAEA;AACA;AACA,kBAAkB,2DAAU;AAC5B,qBAAqB,eAAe;AACpC;AACA;AACA;;AAEA;AACA,QAAQ,iDAAK;AACb,sBAAsB,cAAc;AACpC,8BAA8B,cAAc;AAC5C;AACA;;AAEA,SAAS,iDAAK;AACd;AACA;;AAEA;AACA,GAAG;AACH;AACA,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;AC1DY;;AAEqB;AACO;AACK;AACE;AACK;AACS;AACC;AAChB;AACQ;AACC;AACZ;AACO;AACC;;AAEpD;AACA;AACA,uBAAuB,mEAAW;;AAElC;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;;AAEA;;AAEA,iEAAe;AACf;AACA;AACA,2BAA2B,6DAAY;AACvC;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA,QAAQ,iDAAK;AACb,UAAU,0DAAQ,yBAAyB,0DAAQ;AACnD,8CAA8C;AAC9C,QAAQ;AACR,2DAA2D,WAAW;AACtE;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA,qBAAqB,kEAAa;;AAElC,8CAA8C,gEAAQ;;AAEtD;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA,8BAA8B,6DAAY;AAC1C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,MAAM,2DAAM;AACZ;AACA;AACA,OAAO;AACP;AACA;AACA,OAAO;;AAEP;AACA;AACA;;AAEA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA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AAErC;AACA,cAAc,sDAAK;;AAEnB;AACA,sBAAsB,gEAAa;AACnC,oBAAoB,8DAAW;AAC/B,iBAAiB,2DAAQ;AACzB,gBAAgB,iDAAO;AACvB,mBAAmB,8DAAU;;AAE7B;AACA,mBAAmB,4DAAU;;AAE7B;AACA;;AAEA;AACA;AACA;AACA;;AAEA,eAAe,2DAAM;;AAErB;AACA,qBAAqB,iEAAY;;AAEjC;AACA,oBAAoB,4DAAW;;AAE/B,qBAAqB,8DAAY;;AAEjC,4BAA4B,uEAAc,CAAC,iDAAK;;AAEhD,uBAAuB,mEAAc;;AAErC;;AAEA;AACA,iEAAe,KAAK;;;;;;;;;;;;;;;;ACrFP;;AAEkC;;AAE/C;AACA;AACA;AACA,WAAW,UAAU;AACrB;AACA,aAAa;AACb;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA,KAAK;;AAEL;;AAEA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA,KAAK;;AAEL;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO;;AAEP;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA,yBAAyB,yDAAa;AACtC;AACA,KAAK;AACL;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA,MAAM;AACN;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;AACA;AACA;AACA;AACA;;AAEA,iEAAe,WAAW,EAAC;;;;;;;;;;;;;;;;;ACxHd;;AAEkC;AACf;;AAEhC;AACA;AACA;AACA,WAAW,SAAS;AACpB,WAAW,SAAS;AACpB,WAAW,SAAS;AACpB;AACA,aAAa,eAAe;AAC5B;AACA;AACA;AACA,EAAE,2DAAU,oDAAoD,2DAAU;A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a;AAClC,WAAW,gEAAQ;AACnB;AACA;;AAEA;AACA,iDAAK;AACL;AACA;AACA,wBAAwB,2DAAW,aAAa;AAChD;AACA;AACA,yBAAyB;AACzB,KAAK;AACL;AACA,CAAC;;AAED,iDAAK;AACL;;AAEA;AACA;AACA,0BAA0B,2DAAW,aAAa;AAClD;AACA;AACA;AACA,UAAU,IAAI;AACd;AACA;AACA,OAAO;AACP;AACA;;AAEA;;AAEA;AACA,CAAC;;AAED,iEAAe,KAAK,EAAC;;;;;;;;;;;;;;;;AC1MR;;AAEmB;;AAEhC;AACA;AACA;AACA,WAAW,QAAQ;AACnB,WAAW,QAAQ;AACnB,WAAW,QAAQ;AACnB,WAAW,QAAQ;AACnB,WAAW,QAAQ;AACnB;AACA,aAAa,OAAO;AACpB;AACA;AACA;;AAEA;AACA;AACA,IAAI;AACJ;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,iDAAK;AACL;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,cAAc,iDAAK;AACnB;AACA;AACA;AACA;AACA,CAAC;;AAED;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,uBAAuB;AACvB,CAAC;;AAED;AACA,kDAAkD,YAAY;;AAE9D;AACA;AACA;;AAEA,EAAE,iDAAK;AACP;AACA,GAAG;AACH;AACA,GAAG;;AAEH;;AAEA;;AAEA;;AAEA;;AAEA;AACA;;AAEA,iEAAe,UAAU,EAAC;;;;;;;;;;;;;;;;;ACnGb;;AAEmB;AACsB;;AAEtD;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA,SAAS,iDAAK;AACd;;AAEA;AACA;AACA,2BAA2B,mBAAmB;AAC9C;;AAEA;AACA;AACA;;AAEA;AACA;;AAEA;;AAEA;AACA,MAAM,iDAAK;AACX;AACA;;AAEA;AACA;AACA;;AAEA,OAAO,iDAAK;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A;;AAEA;AACA;AACA;AACA,KAAK;;AAEL;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA,IAAI,iDAAK;;AAET;AACA;AACA;;AAEA;;AAEA,iDAAK;AACL,iDAAK;;AAEL,iEAAe,YAAY,EAAC;;;;;;;;;;;;;;;;AC/Rf;;AAEqB;;AAElC;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,aAAa,UAAU;AACvB,aAAa,UAAU;AACvB;AACA,cAAc,QAAQ;AACtB;AACA;AACA;AACA;AACA;AACA;AACA;AACA,KAAK;AACL;AACA;;AAEA;AACA;AACA;AACA,aAAa,QAAQ;AACrB;AACA,eAAe,SAAS;AACxB;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,eAAe;AACf;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA,aAAa,UAAU;AACvB;AACA,eAAe;AACf;AACA;AACA,IAAI,iDAAK;AACT;AACA;AACA;AACA,KAAK;AACL;AACA;;AAEA,iEAAe,kBAAkB,EAAC;;;;;;;;;;;;;;;;;ACtErB;;AAE2C;AACJ;;AAEpD;AACA;AACA;AACA;AACA;AACA,WAAW,QAAQ;AACnB,WAAW,QAAQ;AACnB;AACA,aAAa,QAAQ;AACrB;AACe;AACf,kBAAkB,qEAAa;AAC/B,WAAW,mEAAW;AACtB;AACA;AACA;;;;;;;;;;;;;;;;;;;;;ACpBa;;AAEkC;AACF;AACD;AACW;AACJ;AACJ;;AAE/C;AACA;AACA;AACA,WAAW,QAAQ;AACnB;AACA,aAAa;AACb;AACA;AACA;AACA;AACA;;AAEA;AACA,cAAc,gEAAa;AAC3B;AACA;;AAEA;AACA;AACA;AACA,WAAW,QAAQ;AACnB;AACA,aAAa,SAAS;AACtB;AACe;AACf;;AAEA,mBAAmB,6DAAY;;AAE/B;AACA,gBAAgB,yDAAa;AAC7B;AACA;AACA;;AAEA;AACA;AACA;;AAEA,kBAAkB,6DAAQ,8BAA8B,0DAAQ;;AAEhE;AACA;;AAEA;AACA,oBAAoB,yDAAa;AACjC;AACA;AACA;AACA;;AAEA,uBAAuB,6DAAY;;AAEnC;AACA,GAAG;AACH,SAAS,+DAAQ;AACjB;;AAEA;AACA;AACA,+BAA+B,yDAAa;AAC5C;AACA;AACA;AACA;AACA,kCAAkC,6DAAY;AAC9C;AACA;;AAEA;AACA,GAAG;AACH;;;;;;;;;;;;;;;;;AChFa;;AAEmB;AACa;;AAE7C,oDAAoD,wDAAY;;AAEhE;AACA;AACA;AACA;AACA,WAAW,QAAQ;AACnB,WAAW,QAAQ;AACnB;AACA,aAAa,QAAQ;AACrB;AACe;AACf;AACA;AACA;;AAEA;AACA,QAAQ,iDAAK,0BAA0B,iDAAK;AAC5C,aAAa,iDAAK,aAAa,SAAS;AACxC,MAAM,SAAS,iDAAK;AACpB,aAAa,iDAAK,SAAS;AAC3B,MAAM,SAAS,iDAAK;AACpB;AACA;AACA;AACA;;AAEA;AACA;AACA,SAAS,iDAAK;AACd;AACA,MAAM,UAAU,iDAAK;AACrB;AACA;AACA;;AAEA;AACA;AACA,SAAS,iDAAK;AACd;AACA;AACA;;AAEA;AACA;AACA,SAAS,iDAAK;AACd;AACA,MAAM,UAAU,iDAAK;AACrB;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA,MAAM;AACN;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,EAAE,iDAAK,qCAAqC;AAC5C;AACA;AACA,KAAK,iDAAK;AACV,GAAG;;AAEH;AACA;;;;;;;;;;;;;;;;ACxGa;;AAE4B;;AAEzC;AACA;AACA;AACA,WAAW,UAAU;AACrB,WAAW,UAAU;AACrB,WAAW,QAAQ;AACnB;AACA,aAAa,QAAQ;AACrB;AACe;AACf;AACA;AACA;AACA,IAAI;AACJ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;;AAEA;AACA;AACA,QAAQ;AACR;AACA;AACA,kBAAkB,2DAAU,SAAS,2DAAU;AAC/C;AACA;AACA;AACA;AACA;;AAEA;AACA,GAAG;;AAEH;AACA;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA,cAAc,0DAAQ;AACtB,UAAU,0DAAQ;AAClB,GAAG;;AAEH;AACA;AACA,GAAG;;AAEH;AACA;AACA;AACA;AACA;AACA;;AAEA,iDAAK;AACL;AACA,CAAC;;AAED,iDAAK;AACL,6BAA6B,iDAAK;AAClC,CAAC;;AAED,iEAAe,QAAQ,EAAC;;;;;;;;;;;;;;;ACrKX;;AAEb,iEAAe;AACf;AACA;AACA;AACA,CAAC,EAAC;;;;;;;;;;;;;;;ACNK;;;;;;;;;;;;;;;ACAM;;AAE4B;;AAEzC;AACA;AACA;AACA;AACA,WAAW,QAAQ;AACnB;AACA,aAAa,QAAQ;AACrB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;;AAEA;AACA;AACA;AACA,WAAW,qBAAqB;AAChC,WAAW,qBAAqB;AAChC;AACA,aAAa;AACb;AACA;AACA;;AAEA,YAAY,0DAAU;AACtB;;AAEA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA,IAAI;;AAEJ;AACA;AACA,GAAG;AACH;;AAEA,iEAAe,oBAAoB,EAAC;;;;;;;;;;;;;;;ACzDpC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA,CAAC;;AAED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ACA;AACA;AACA;AACA;AACA;AACA;AACA,cAAc,SAAS;AACvB;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,WAAW,QAAQ;AACnB;AACA,aAAa,4BAA4B;AACzC;AACA;AACA;AACA;AACA;AACA;AACA,oBAAoB,iDAAK;;AAEzB;AACA,UAAU,iDAAK;AACf;AACA,QAAQ;AACR;AACA;;AAEA;AACA;;AAEA,0BAA0B,iDAAK;AAC/B;AACA;;AAEA;;AAEA,kBAAkB,iDAAK;AACvB;AACA;;AAEA;AACA;;AAEA,MAAM,iDAAK,yBAAyB,iDAAK;AACzC;;AAEA,IAAI,iDAAK;AACT;AACA,KAAK;;AAEL;AACA;;AAEA;AACA;;AAEA,iEAAe,cAAc,EAAC;;;;;;;;;;;;;;;AC3FjB;;AAEb;AACA;AACA;AACA,WAAW,QAAQ;AACnB;AACA,aAAa,SAAS;AACtB;AACe;AACf;AACA;AACA;AACA;AACA;;;;;;;;;;;;;;;;ACda;;AAEqB;;AAElC;AACA;AACA;AACA,WAAW,GAAG;AACd;AACA,aAAa,SAAS;AACtB;AACe;AACf,SAAS,iDAAK;AACd;;;;;;;;;;;;;;;;;ACba;;AAEqB;AACU;;AAE5C,iEAAe,0DAAQ;;AAEvB;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,cAAc,QAAQ;AACtB,gBAAgB;AAChB;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA,cAAc,QAAQ;AACtB,gBAAgB,SAAS;AACzB;AACA;AACA,sBAAsB,iDAAK;AAC3B;AACA;AACA;AACA,GAAG;;AAEH;AACA;AACA;AACA;AACA;AACA,GAAG,GAAG,EAAC;;;;;;;;;;;;;;;AClEP;AACA,iEAAe,IAAI,EAAC;;;;;;;;;;;;;;;;ACDP;;AAEqB;;AAElC;AACA;AACA,0BAA0B,iDAAK;AAC/B;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,WAAW,QAAQ;AACnB;AACA,aAAa,QAAQ;AACrB;AACA,iEAAe;AACf;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA,QAAQ;AACR;AACA;AACA,MAAM;AACN;AACA;AACA,GAAG;;AAEH;AACA,CAAC,EAAC;;;;;;;;;;;;;;;ACtDW;;AAEE;AACf,0BAA0B,KAAK;AAC/B;AACA;;;;;;;;;;;;;;;ACLa;;AAEb;AACA;AACA,WAAW,QAAQ;AACnB,WAAW,QAAQ;AACnB,aAAa;AACb;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;;AAEA;;AAEA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;;AAEA,iEAAe,WAAW,EAAC;;;;;;;;;;;;;;;ACtDd;;AAEb;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,+BAA+B;AAC/B;AACA;AACA,WAAW,UAAU;AACrB;AACA,aAAa;AACb;AACe;AACf;AACA;AACA;AACA;;;;;;;;;;;;;;;;;;AC3Ba;;AAEmB;AACe;AAC/C;AACoE;;AAEpE;AACA;AACA;AACA,WAAW,QAAQ;AACnB;AACA,aAAa;AACb;AACA;AACA,SAAS,iDAAK,yBAAyB,iDAAK;AAC5C;;AAEA;AACA;AACA;AACA,WAAW,QAAQ;AACnB;AACA,aAAa,QAAQ;AACrB;AACA;AACA,SAAS,iDAAK;AACd;;AAEA;AACA;AACA;AACA,WAAW,QAAQ;AACnB,WAAW,QAAQ;AACnB,WAAW,QAAQ;AACnB;AACA,aAAa,QAAQ;AACrB;AACA;AACA;AACA;AACA;AACA;AACA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ACFpD;;AAE+D;AAC5E,iEAAe,2DAA2D,wEAAoB,EAAC;;;;;;;;;;;;;;;;;;ACHrC;AACd;AACR;;AAEpC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,aAAa;AACb;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA,CAAC;;AAED;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC;;;AAGD,iEAAe;AACf;AACA;AACA,mBAAmB;AACnB,YAAY;AACZ,QAAQ;AACR,GAAG;AACH;AACA;AACA;AACA,CAAC,EAAC;;;;;;;;;;;;;;;;AC/DW;;AAEwB;;AAErC;;AAEA,OAAO,UAAU;AACjB,OAAO,gBAAgB;;AAEvB;AACA;AACA;AACA,CAAC;;AAED;AACA;AACA;AACA;;AAEA;;AAEA;AACA;AACA;AACA,WAAW,QAAQ;AACnB;AACA,aAAa,SAAS;AACtB;AACA,OAAO,SAAS;;AAEhB;AACA;AACA;AACA,WAAW,GAAG;AACd;AACA,aAAa,SAAS;AACtB;AACA;;AAEA;AACA;AACA;AACA,WAAW,GAAG;AACd;AACA,aAAa,SAAS;AACtB;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,WAAW,GAAG;AACd;AACA,aAAa,SAAS;AACtB;AACA;;;AAGA;AACA;AACA;AACA,WAAW,GAAG;AACd;AACA,aAAa,SAAS;AACtB;AACA;AACA;AACA;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,WAAW,GAAG;AACd;AACA,aAAa,SAAS;AACtB;AACA;;AAEA;AACA;AACA;AACA,WAAW,GAAG;AACd,aAAa,SAAS;AACtB;AACA;;AAEA;AACA;AACA;AACA,WAAW,GAAG;AACd;AACA,aAAa,SAAS;AACtB;AACA;;AAEA;AACA;AACA;AACA,WAAW,GAAG;AACd;AACA,aAAa,SAAS;AACtB;AACA;;AAEA;AACA;AACA;AACA,WAAW,GAAG;AACd,aAAa,SAAS;AACtB;AACA;;AAEA;AACA;AACA;AACA,WAAW,GAAG;AACd;AACA,aAAa,SAAS;AACtB;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA,WAAW,GAAG;AACd;AACA,aAAa,SAAS;AACtB;AACA;;AAEA;AACA;AACA;AACA,WAAW,GAAG;AACd;AACA,aAAa,SAAS;AACtB;AACA;;AAEA;AACA;AACA;AACA,WAAW,GAAG;AACd;AACA,aAAa,SAAS;AACtB;AACA;;AAEA;AACA;AACA;AACA,WAAW,GAAG;AACd;AACA,aAAa,SAAS;AACtB;AACA;;AAEA;AACA;AACA;AACA,WAAW,GAAG;AACd;AACA,aAAa,SAAS;AACtB;AACA;;AAEA;AACA;AACA;AACA,WAAW,GAAG;AACd;AACA,aAAa,SAAS;AACtB;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,WAAW,GAAG;AACd;AACA,aAAa,SAAS;AACtB;AACA;;AAEA;AACA;AACA;AACA,WAAW,QAAQ;AACnB;AACA,aAAa,QAAQ;AACrB;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,WAAW,cAAc;AACzB,WAAW,UAAU;AACrB;AACA,WAAW,SAAS;AACpB,aAAa;AACb;AACA,2BAA2B,oBAAoB,IAAI;AACnD;AACA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA,gCAAgC,OAAO;AACvC;AACA;AACA,IAAI;AACJ;AACA;AACA;AACA;;AAEA,gBAAgB,SAAS;AACzB;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA,CAAC;;AAED;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,uBAAuB,SAAS,GAAG,SAAS;AAC5C,4BAA4B;AAC5B;AACA;AACA,WAAW,QAAQ;AACnB;AACA,aAAa,QAAQ;AACrB;AACA;AACA,SAAS,UAAU;AACnB;AACA;AACA;AACA;AACA;AACA,MAAM;AACN,kCAAkC;AAClC,MAAM;AACN;AACA,MAAM;AACN;AACA;AACA;;AAEA,wCAAwC,OAAO;AAC/C;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,WAAW,QAAQ;AACnB,WAAW,QAAQ;AACnB,WAAW,QAAQ;AACnB;AACA,WAAW,SAAS;AACpB,aAAa,QAAQ;AACrB;AACA,gCAAgC,WAAW,IAAI;AAC/C;AACA;AACA,eAAe,4DAAI;AACnB,MAAM;AACN;AACA;AACA,GAAG,GAAG,WAAW;AACjB;AACA;;AAEA;AACA;AACA;AACA,WAAW,QAAQ;AACnB;AACA,aAAa,QAAQ;AACrB;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA,WAAW,UAAU;AACrB,WAAW,UAAU;AACrB,WAAW,QAAQ;AACnB,WAAW,QAAQ;AACnB;AACA,aAAa;AACb;AACA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;AACA;;AAEA;AACA;AACA,WAAW,QAAQ;AACnB,WAAW,QAAQ;AACnB,WAAW,kBAAkB;AAC7B,WAAW,UAAU;AACrB;AACA,aAAa;AACb;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI;;AAEJ;AACA;;AAEA;AACA;AACA;AACA,WAAW,QAAQ;AACnB,WAAW,QAAQ;AACnB,WAAW,QAAQ;AACnB;AACA,aAAa;AACb;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;AAGA;AACA;AACA;AACA,WAAW,GAAG;AACd;AACA,aAAa;AACb;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA,WAAW;AACX;AACA,aAAa;AACb;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC;;AAED;AACA;AACA;AACA,WAAW,kBAAkB;AAC7B,WAAW,UAAU;AACrB;AACA,aAAa;AACb;AACA;AACA;;AAEA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA,WAAW,QAAQ;AACnB,WAAW,QAAQ;AACnB;AACA,aAAa;AACb;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA,0BAA0B,eAAe;;AAEzC;AACA;AACA;AACA,WAAW,GAAG;AACd;AACA,aAAa,SAAS;AACtB;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA,GAAG;;AAEH;AACA;;AAEA;AACA;AACA,WAAW,QAAQ;AACnB;;AAEA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAEA;;AAEA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA,GAAG;AACH;;AAEA;AACA;;AAEA;AACA;AACA;AACA,KAAK;AACL;;AAEA;;AAEA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;;AAEA;;AAEA;;AAEA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA,SAAS,QAAQ;AACjB;AACA;AACA;;AAEA;AACA;;AAEA;AACA;AACA;AACA,WAAW,SAAS;AACpB;AACA,aAAa;AACb;AACA;AACA;AACA;;AAEA;AACA;;AAEA;;AAEA;AACA;AACA;AACA;;AAEA;AACA;AACA;;AAEA;AACA;AACA;AACA,SAAS;;AAET;;AAEA;AACA;AACA;;AAEA;AACA;;AAEA;AACA;;AAEA;;AAEA;AACA;;AAEA,iEAAe;AACf;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,CAAC,EAAC;;;;;;;UCjtBF;UACA;;UAEA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;;UAEA;UACA;;UAEA;UACA;UACA;;;;;WCtBA;WACA;WACA;WACA;WACA;WACA,iCAAiC,WAAW;WAC5C;WACA;;;;;WCPA;WACA;WACA;WACA;WACA,yCAAyC,wCAAwC;WACjF;WACA;WACA;;;;;WCPA;;;;;WCAA;WACA;WACA;WACA,uDAAuD,iBAAiB;WACxE;WACA,gDAAgD,aAAa;WAC7D;;;;;;;;;;;;;;;;;ACN4C;AACK;AACT;AACkB;;AAE1D;AACAI,0DAAM,CAACnJ,iEAAA,CAACoJ,2DAAa,QACpBxJ,YAAY,CAACyJ,qBAAqB,GAAGrJ,iEAAA,CAACZ,oDAAW,MAAC,CAAC,GAAGY,iEAAA,CAACa,6DAAoB,MAAC,CAC9D,CAAC,EAAE0G,QAAQ,CAACC,cAAc,CAAC,kBAAkB,CAAC,CAAC,C","sources":["webpack://mvx-modules/./node_modules/@remix-run/router/dist/router.js","webpack://mvx-modules/../assets/images/widget-multivendorX.svg","webpack://mvx-modules/./src/blocks/setupWizard/SetupWizard.jsx","webpack://mvx-modules/./src/blocks/setupWizard/WooCommerceInstaller.jsx","webpack://mvx-modules/./src/blocks/setupWizard/components/CommissionField.jsx","webpack://mvx-modules/./src/blocks/setupWizard/steps/CapabilitySetup.jsx","webpack://mvx-modules/./src/blocks/setupWizard/steps/CommissionSetup.jsx","webpack://mvx-modules/./src/blocks/setupWizard/steps/DummydataSetup.jsx","webpack://mvx-modules/./src/blocks/setupWizard/steps/PaymentSetup.jsx","webpack://mvx-modules/./src/blocks/setupWizard/steps/SetupReady.jsx","webpack://mvx-modules/./src/blocks/setupWizard/steps/StoreSetup.jsx","webpack://mvx-modules/./src/blocks/setupWizard/steps/intro.jsx","webpack://mvx-modules/./src/services/apiService.js","webpack://mvx-modules/./node_modules/react-router-dom/dist/index.js","webpack://mvx-modules/./node_modules/react-router/dist/index.js","webpack://mvx-modules/external window \"React\"","webpack://mvx-modules/external window [\"wp\",\"element\"]","webpack://mvx-modules/./node_modules/axios/lib/adapters/adapters.js","webpack://mvx-modules/./node_modules/axios/lib/adapters/xhr.js","webpack://mvx-modules/./node_modules/axios/lib/axios.js","webpack://mvx-modules/./node_modules/axios/lib/cancel/CancelToken.js","webpack://mvx-modules/./node_modules/axios/lib/cancel/CanceledError.js","webpack://mvx-modules/./node_modules/axios/lib/cancel/isCancel.js","webpack://mvx-modules/./node_modules/axios/lib/core/Axios.js","webpack://mvx-modules/./node_modules/axios/lib/core/AxiosError.js","webpack://mvx-modules/./node_modules/axios/lib/core/AxiosHeaders.js","webpack://mvx-modules/./node_modules/axios/lib/core/InterceptorManager.js","webpack://mvx-modules/./node_modules/axios/lib/core/buildFullPath.js","webpack://mvx-modules/./node_modules/axios/lib/core/dispatchRequest.js","webpack://mvx-modules/./node_modules/axios/lib/core/mergeConfig.js","webpack://mvx-modules/./node_modules/axios/lib/core/settle.js","webpack://mvx-modules/./node_modules/axios/lib/core/transformData.js","webpack://mvx-modules/./node_modules/axios/lib/defaults/index.js","webpack://mvx-modules/./node_modules/axios/lib/defaults/transitional.js","webpack://mvx-modules/./node_modules/axios/lib/env/data.js","webpack://mvx-modules/./node_modules/axios/lib/helpers/AxiosURLSearchParams.js","webpack://mvx-modules/./node_modules/axios/lib/helpers/HttpStatusCode.js","webpack://mvx-modules/./node_modules/axios/lib/helpers/bind.js","webpack://mvx-modules/./node_modules/axios/lib/helpers/buildURL.js","webpack://mvx-modules/./node_modules/axios/lib/helpers/combineURLs.js","webpack://mvx-modules/./node_modules/axios/lib/helpers/cookies.js","webpack://mvx-modules/./node_modules/axios/lib/helpers/formDataToJSON.js","webpack://mvx-modules/./node_modules/axios/lib/helpers/isAbsoluteURL.js","webpack://mvx-modules/./node_modules/axios/lib/helpers/isAxiosError.js","webpack://mvx-modules/./node_modules/axios/lib/helpers/isURLSameOrigin.js","webpack://mvx-modules/./node_modules/axios/lib/helpers/null.js","webpack://mvx-modules/./node_modules/axios/lib/helpers/parseHeaders.js","webpack://mvx-modules/./node_modules/axios/lib/helpers/parseProtocol.js","webpack://mvx-modules/./node_modules/axios/lib/helpers/speedometer.js","webpack://mvx-modules/./node_modules/axios/lib/helpers/spread.js","webpack://mvx-modules/./node_modules/axios/lib/helpers/toFormData.js","webpack://mvx-modules/./node_modules/axios/lib/helpers/toURLEncodedForm.js","webpack://mvx-modules/./node_modules/axios/lib/helpers/validator.js","webpack://mvx-modules/./node_modules/axios/lib/platform/browser/classes/Blob.js","webpack://mvx-modules/./node_modules/axios/lib/platform/browser/classes/FormData.js","webpack://mvx-modules/./node_modules/axios/lib/platform/browser/classes/URLSearchParams.js","webpack://mvx-modules/./node_modules/axios/lib/platform/browser/index.js","webpack://mvx-modules/./node_modules/axios/lib/utils.js","webpack://mvx-modules/webpack/bootstrap","webpack://mvx-modules/webpack/runtime/compat get default export","webpack://mvx-modules/webpack/runtime/define property getters","webpack://mvx-modules/webpack/runtime/hasOwnProperty shorthand","webpack://mvx-modules/webpack/runtime/make namespace object","webpack://mvx-modules/./src/blocks/setupWizard/index.js"],"sourcesContent":["/**\n * @remix-run/router v1.8.0\n *\n * Copyright (c) Remix Software Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE.md file in the root directory of this source tree.\n *\n * @license MIT\n */\nfunction _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}\n\n////////////////////////////////////////////////////////////////////////////////\n//#region Types and Constants\n////////////////////////////////////////////////////////////////////////////////\n/**\n * Actions represent the type of change to a location value.\n */\nvar Action;\n(function (Action) {\n /**\n * A POP indicates a change to an arbitrary index in the history stack, such\n * as a back or forward navigation. It does not describe the direction of the\n * navigation, only that the current index changed.\n *\n * Note: This is the default action for newly created history objects.\n */\n Action[\"Pop\"] = \"POP\";\n /**\n * A PUSH indicates a new entry being added to the history stack, such as when\n * a link is clicked and a new page loads. When this happens, all subsequent\n * entries in the stack are lost.\n */\n Action[\"Push\"] = \"PUSH\";\n /**\n * A REPLACE indicates the entry at the current index in the history stack\n * being replaced by a new one.\n */\n Action[\"Replace\"] = \"REPLACE\";\n})(Action || (Action = {}));\nconst PopStateEventType = \"popstate\";\n/**\n * Memory history stores the current location in memory. It is designed for use\n * in stateful non-browser environments like tests and React Native.\n */\nfunction createMemoryHistory(options) {\n if (options === void 0) {\n options = {};\n }\n let {\n initialEntries = [\"/\"],\n initialIndex,\n v5Compat = false\n } = options;\n let entries; // Declare so we can access from createMemoryLocation\n entries = initialEntries.map((entry, index) => createMemoryLocation(entry, typeof entry === \"string\" ? null : entry.state, index === 0 ? \"default\" : undefined));\n let index = clampIndex(initialIndex == null ? entries.length - 1 : initialIndex);\n let action = Action.Pop;\n let listener = null;\n function clampIndex(n) {\n return Math.min(Math.max(n, 0), entries.length - 1);\n }\n function getCurrentLocation() {\n return entries[index];\n }\n function createMemoryLocation(to, state, key) {\n if (state === void 0) {\n state = null;\n }\n let location = createLocation(entries ? getCurrentLocation().pathname : \"/\", to, state, key);\n warning(location.pathname.charAt(0) === \"/\", \"relative pathnames are not supported in memory history: \" + JSON.stringify(to));\n return location;\n }\n function createHref(to) {\n return typeof to === \"string\" ? to : createPath(to);\n }\n let history = {\n get index() {\n return index;\n },\n get action() {\n return action;\n },\n get location() {\n return getCurrentLocation();\n },\n createHref,\n createURL(to) {\n return new URL(createHref(to), \"http://localhost\");\n },\n encodeLocation(to) {\n let path = typeof to === \"string\" ? parsePath(to) : to;\n return {\n pathname: path.pathname || \"\",\n search: path.search || \"\",\n hash: path.hash || \"\"\n };\n },\n push(to, state) {\n action = Action.Push;\n let nextLocation = createMemoryLocation(to, state);\n index += 1;\n entries.splice(index, entries.length, nextLocation);\n if (v5Compat && listener) {\n listener({\n action,\n location: nextLocation,\n delta: 1\n });\n }\n },\n replace(to, state) {\n action = Action.Replace;\n let nextLocation = createMemoryLocation(to, state);\n entries[index] = nextLocation;\n if (v5Compat && listener) {\n listener({\n action,\n location: nextLocation,\n delta: 0\n });\n }\n },\n go(delta) {\n action = Action.Pop;\n let nextIndex = clampIndex(index + delta);\n let nextLocation = entries[nextIndex];\n index = nextIndex;\n if (listener) {\n listener({\n action,\n location: nextLocation,\n delta\n });\n }\n },\n listen(fn) {\n listener = fn;\n return () => {\n listener = null;\n };\n }\n };\n return history;\n}\n/**\n * Browser history stores the location in regular URLs. This is the standard for\n * most web apps, but it requires some configuration on the server to ensure you\n * serve the same app at multiple URLs.\n *\n * @see https://github.com/remix-run/history/tree/main/docs/api-reference.md#createbrowserhistory\n */\nfunction createBrowserHistory(options) {\n if (options === void 0) {\n options = {};\n }\n function createBrowserLocation(window, globalHistory) {\n let {\n pathname,\n search,\n hash\n } = window.location;\n return createLocation(\"\", {\n pathname,\n search,\n hash\n },\n // state defaults to `null` because `window.history.state` does\n globalHistory.state && globalHistory.state.usr || null, globalHistory.state && globalHistory.state.key || \"default\");\n }\n function createBrowserHref(window, to) {\n return typeof to === \"string\" ? to : createPath(to);\n }\n return getUrlBasedHistory(createBrowserLocation, createBrowserHref, null, options);\n}\n/**\n * Hash history stores the location in window.location.hash. This makes it ideal\n * for situations where you don't want to send the location to the server for\n * some reason, either because you do cannot configure it or the URL space is\n * reserved for something else.\n *\n * @see https://github.com/remix-run/history/tree/main/docs/api-reference.md#createhashhistory\n */\nfunction createHashHistory(options) {\n if (options === void 0) {\n options = {};\n }\n function createHashLocation(window, globalHistory) {\n let {\n pathname = \"/\",\n search = \"\",\n hash = \"\"\n } = parsePath(window.location.hash.substr(1));\n // Hash URL should always have a leading / just like window.location.pathname\n // does, so if an app ends up at a route like /#something then we add a\n // leading slash so all of our path-matching behaves the same as if it would\n // in a browser router. This is particularly important when there exists a\n // root splat route () since that matches internally against\n // \"/*\" and we'd expect /#something to 404 in a hash router app.\n if (!pathname.startsWith(\"/\") && !pathname.startsWith(\".\")) {\n pathname = \"/\" + pathname;\n }\n return createLocation(\"\", {\n pathname,\n search,\n hash\n },\n // state defaults to `null` because `window.history.state` does\n globalHistory.state && globalHistory.state.usr || null, globalHistory.state && globalHistory.state.key || \"default\");\n }\n function createHashHref(window, to) {\n let base = window.document.querySelector(\"base\");\n let href = \"\";\n if (base && base.getAttribute(\"href\")) {\n let url = window.location.href;\n let hashIndex = url.indexOf(\"#\");\n href = hashIndex === -1 ? url : url.slice(0, hashIndex);\n }\n return href + \"#\" + (typeof to === \"string\" ? to : createPath(to));\n }\n function validateHashLocation(location, to) {\n warning(location.pathname.charAt(0) === \"/\", \"relative pathnames are not supported in hash history.push(\" + JSON.stringify(to) + \")\");\n }\n return getUrlBasedHistory(createHashLocation, createHashHref, validateHashLocation, options);\n}\nfunction invariant(value, message) {\n if (value === false || value === null || typeof value === \"undefined\") {\n throw new Error(message);\n }\n}\nfunction warning(cond, message) {\n if (!cond) {\n // eslint-disable-next-line no-console\n if (typeof console !== \"undefined\") console.warn(message);\n try {\n // Welcome to debugging history!\n //\n // This error is thrown as a convenience so you can more easily\n // find the source for a warning that appears in the console by\n // enabling \"pause on exceptions\" in your JavaScript debugger.\n throw new Error(message);\n // eslint-disable-next-line no-empty\n } catch (e) {}\n }\n}\nfunction createKey() {\n return Math.random().toString(36).substr(2, 8);\n}\n/**\n * For browser-based histories, we combine the state and key into an object\n */\nfunction getHistoryState(location, index) {\n return {\n usr: location.state,\n key: location.key,\n idx: index\n };\n}\n/**\n * Creates a Location object with a unique key from the given Path\n */\nfunction createLocation(current, to, state, key) {\n if (state === void 0) {\n state = null;\n }\n let location = _extends({\n pathname: typeof current === \"string\" ? current : current.pathname,\n search: \"\",\n hash: \"\"\n }, typeof to === \"string\" ? parsePath(to) : to, {\n state,\n // TODO: This could be cleaned up. push/replace should probably just take\n // full Locations now and avoid the need to run through this flow at all\n // But that's a pretty big refactor to the current test suite so going to\n // keep as is for the time being and just let any incoming keys take precedence\n key: to && to.key || key || createKey()\n });\n return location;\n}\n/**\n * Creates a string URL path from the given pathname, search, and hash components.\n */\nfunction createPath(_ref) {\n let {\n pathname = \"/\",\n search = \"\",\n hash = \"\"\n } = _ref;\n if (search && search !== \"?\") pathname += search.charAt(0) === \"?\" ? search : \"?\" + search;\n if (hash && hash !== \"#\") pathname += hash.charAt(0) === \"#\" ? hash : \"#\" + hash;\n return pathname;\n}\n/**\n * Parses a string URL path into its separate pathname, search, and hash components.\n */\nfunction parsePath(path) {\n let parsedPath = {};\n if (path) {\n let hashIndex = path.indexOf(\"#\");\n if (hashIndex >= 0) {\n parsedPath.hash = path.substr(hashIndex);\n path = path.substr(0, hashIndex);\n }\n let searchIndex = path.indexOf(\"?\");\n if (searchIndex >= 0) {\n parsedPath.search = path.substr(searchIndex);\n path = path.substr(0, searchIndex);\n }\n if (path) {\n parsedPath.pathname = path;\n }\n }\n return parsedPath;\n}\nfunction getUrlBasedHistory(getLocation, createHref, validateLocation, options) {\n if (options === void 0) {\n options = {};\n }\n let {\n window = document.defaultView,\n v5Compat = false\n } = options;\n let globalHistory = window.history;\n let action = Action.Pop;\n let listener = null;\n let index = getIndex();\n // Index should only be null when we initialize. If not, it's because the\n // user called history.pushState or history.replaceState directly, in which\n // case we should log a warning as it will result in bugs.\n if (index == null) {\n index = 0;\n globalHistory.replaceState(_extends({}, globalHistory.state, {\n idx: index\n }), \"\");\n }\n function getIndex() {\n let state = globalHistory.state || {\n idx: null\n };\n return state.idx;\n }\n function handlePop() {\n action = Action.Pop;\n let nextIndex = getIndex();\n let delta = nextIndex == null ? null : nextIndex - index;\n index = nextIndex;\n if (listener) {\n listener({\n action,\n location: history.location,\n delta\n });\n }\n }\n function push(to, state) {\n action = Action.Push;\n let location = createLocation(history.location, to, state);\n if (validateLocation) validateLocation(location, to);\n index = getIndex() + 1;\n let historyState = getHistoryState(location, index);\n let url = history.createHref(location);\n // try...catch because iOS limits us to 100 pushState calls :/\n try {\n globalHistory.pushState(historyState, \"\", url);\n } catch (error) {\n // If the exception is because `state` can't be serialized, let that throw\n // outwards just like a replace call would so the dev knows the cause\n // https://html.spec.whatwg.org/multipage/nav-history-apis.html#shared-history-push/replace-state-steps\n // https://html.spec.whatwg.org/multipage/structured-data.html#structuredserializeinternal\n if (error instanceof DOMException && error.name === \"DataCloneError\") {\n throw error;\n }\n // They are going to lose state here, but there is no real\n // way to warn them about it since the page will refresh...\n window.location.assign(url);\n }\n if (v5Compat && listener) {\n listener({\n action,\n location: history.location,\n delta: 1\n });\n }\n }\n function replace(to, state) {\n action = Action.Replace;\n let location = createLocation(history.location, to, state);\n if (validateLocation) validateLocation(location, to);\n index = getIndex();\n let historyState = getHistoryState(location, index);\n let url = history.createHref(location);\n globalHistory.replaceState(historyState, \"\", url);\n if (v5Compat && listener) {\n listener({\n action,\n location: history.location,\n delta: 0\n });\n }\n }\n function createURL(to) {\n // window.location.origin is \"null\" (the literal string value) in Firefox\n // under certain conditions, notably when serving from a local HTML file\n // See https://bugzilla.mozilla.org/show_bug.cgi?id=878297\n let base = window.location.origin !== \"null\" ? window.location.origin : window.location.href;\n let href = typeof to === \"string\" ? to : createPath(to);\n invariant(base, \"No window.location.(origin|href) available to create URL for href: \" + href);\n return new URL(href, base);\n }\n let history = {\n get action() {\n return action;\n },\n get location() {\n return getLocation(window, globalHistory);\n },\n listen(fn) {\n if (listener) {\n throw new Error(\"A history only accepts one active listener\");\n }\n window.addEventListener(PopStateEventType, handlePop);\n listener = fn;\n return () => {\n window.removeEventListener(PopStateEventType, handlePop);\n listener = null;\n };\n },\n createHref(to) {\n return createHref(window, to);\n },\n createURL,\n encodeLocation(to) {\n // Encode a Location the same way window.location would\n let url = createURL(to);\n return {\n pathname: url.pathname,\n search: url.search,\n hash: url.hash\n };\n },\n push,\n replace,\n go(n) {\n return globalHistory.go(n);\n }\n };\n return history;\n}\n//#endregion\n\nvar ResultType;\n(function (ResultType) {\n ResultType[\"data\"] = \"data\";\n ResultType[\"deferred\"] = \"deferred\";\n ResultType[\"redirect\"] = \"redirect\";\n ResultType[\"error\"] = \"error\";\n})(ResultType || (ResultType = {}));\nconst immutableRouteKeys = new Set([\"lazy\", \"caseSensitive\", \"path\", \"id\", \"index\", \"children\"]);\nfunction isIndexRoute(route) {\n return route.index === true;\n}\n// Walk the route tree generating unique IDs where necessary so we are working\n// solely with AgnosticDataRouteObject's within the Router\nfunction convertRoutesToDataRoutes(routes, mapRouteProperties, parentPath, manifest) {\n if (parentPath === void 0) {\n parentPath = [];\n }\n if (manifest === void 0) {\n manifest = {};\n }\n return routes.map((route, index) => {\n let treePath = [...parentPath, index];\n let id = typeof route.id === \"string\" ? route.id : treePath.join(\"-\");\n invariant(route.index !== true || !route.children, \"Cannot specify children on an index route\");\n invariant(!manifest[id], \"Found a route id collision on id \\\"\" + id + \"\\\". Route \" + \"id's must be globally unique within Data Router usages\");\n if (isIndexRoute(route)) {\n let indexRoute = _extends({}, route, mapRouteProperties(route), {\n id\n });\n manifest[id] = indexRoute;\n return indexRoute;\n } else {\n let pathOrLayoutRoute = _extends({}, route, mapRouteProperties(route), {\n id,\n children: undefined\n });\n manifest[id] = pathOrLayoutRoute;\n if (route.children) {\n pathOrLayoutRoute.children = convertRoutesToDataRoutes(route.children, mapRouteProperties, treePath, manifest);\n }\n return pathOrLayoutRoute;\n }\n });\n}\n/**\n * Matches the given routes to a location and returns the match data.\n *\n * @see https://reactrouter.com/utils/match-routes\n */\nfunction matchRoutes(routes, locationArg, basename) {\n if (basename === void 0) {\n basename = \"/\";\n }\n let location = typeof locationArg === \"string\" ? parsePath(locationArg) : locationArg;\n let pathname = stripBasename(location.pathname || \"/\", basename);\n if (pathname == null) {\n return null;\n }\n let branches = flattenRoutes(routes);\n rankRouteBranches(branches);\n let matches = null;\n for (let i = 0; matches == null && i < branches.length; ++i) {\n matches = matchRouteBranch(branches[i],\n // Incoming pathnames are generally encoded from either window.location\n // or from router.navigate, but we want to match against the unencoded\n // paths in the route definitions. Memory router locations won't be\n // encoded here but there also shouldn't be anything to decode so this\n // should be a safe operation. This avoids needing matchRoutes to be\n // history-aware.\n safelyDecodeURI(pathname));\n }\n return matches;\n}\nfunction flattenRoutes(routes, branches, parentsMeta, parentPath) {\n if (branches === void 0) {\n branches = [];\n }\n if (parentsMeta === void 0) {\n parentsMeta = [];\n }\n if (parentPath === void 0) {\n parentPath = \"\";\n }\n let flattenRoute = (route, index, relativePath) => {\n let meta = {\n relativePath: relativePath === undefined ? route.path || \"\" : relativePath,\n caseSensitive: route.caseSensitive === true,\n childrenIndex: index,\n route\n };\n if (meta.relativePath.startsWith(\"/\")) {\n invariant(meta.relativePath.startsWith(parentPath), \"Absolute route path \\\"\" + meta.relativePath + \"\\\" nested under path \" + (\"\\\"\" + parentPath + \"\\\" is not valid. An absolute child route path \") + \"must start with the combined path of all its parent routes.\");\n meta.relativePath = meta.relativePath.slice(parentPath.length);\n }\n let path = joinPaths([parentPath, meta.relativePath]);\n let routesMeta = parentsMeta.concat(meta);\n // Add the children before adding this route to the array so we traverse the\n // route tree depth-first and child routes appear before their parents in\n // the \"flattened\" version.\n if (route.children && route.children.length > 0) {\n invariant(\n // Our types know better, but runtime JS may not!\n // @ts-expect-error\n route.index !== true, \"Index routes must not have child routes. Please remove \" + (\"all child routes from route path \\\"\" + path + \"\\\".\"));\n flattenRoutes(route.children, branches, routesMeta, path);\n }\n // Routes without a path shouldn't ever match by themselves unless they are\n // index routes, so don't add them to the list of possible branches.\n if (route.path == null && !route.index) {\n return;\n }\n branches.push({\n path,\n score: computeScore(path, route.index),\n routesMeta\n });\n };\n routes.forEach((route, index) => {\n var _route$path;\n // coarse-grain check for optional params\n if (route.path === \"\" || !((_route$path = route.path) != null && _route$path.includes(\"?\"))) {\n flattenRoute(route, index);\n } else {\n for (let exploded of explodeOptionalSegments(route.path)) {\n flattenRoute(route, index, exploded);\n }\n }\n });\n return branches;\n}\n/**\n * Computes all combinations of optional path segments for a given path,\n * excluding combinations that are ambiguous and of lower priority.\n *\n * For example, `/one/:two?/three/:four?/:five?` explodes to:\n * - `/one/three`\n * - `/one/:two/three`\n * - `/one/three/:four`\n * - `/one/three/:five`\n * - `/one/:two/three/:four`\n * - `/one/:two/three/:five`\n * - `/one/three/:four/:five`\n * - `/one/:two/three/:four/:five`\n */\nfunction explodeOptionalSegments(path) {\n let segments = path.split(\"/\");\n if (segments.length === 0) return [];\n let [first, ...rest] = segments;\n // Optional path segments are denoted by a trailing `?`\n let isOptional = first.endsWith(\"?\");\n // Compute the corresponding required segment: `foo?` -> `foo`\n let required = first.replace(/\\?$/, \"\");\n if (rest.length === 0) {\n // Intepret empty string as omitting an optional segment\n // `[\"one\", \"\", \"three\"]` corresponds to omitting `:two` from `/one/:two?/three` -> `/one/three`\n return isOptional ? [required, \"\"] : [required];\n }\n let restExploded = explodeOptionalSegments(rest.join(\"/\"));\n let result = [];\n // All child paths with the prefix. Do this for all children before the\n // optional version for all children so we get consistent ordering where the\n // parent optional aspect is preferred as required. Otherwise, we can get\n // child sections interspersed where deeper optional segments are higher than\n // parent optional segments, where for example, /:two would explodes _earlier_\n // then /:one. By always including the parent as required _for all children_\n // first, we avoid this issue\n result.push(...restExploded.map(subpath => subpath === \"\" ? required : [required, subpath].join(\"/\")));\n // Then if this is an optional value, add all child versions without\n if (isOptional) {\n result.push(...restExploded);\n }\n // for absolute paths, ensure `/` instead of empty segment\n return result.map(exploded => path.startsWith(\"/\") && exploded === \"\" ? \"/\" : exploded);\n}\nfunction rankRouteBranches(branches) {\n branches.sort((a, b) => a.score !== b.score ? b.score - a.score // Higher score first\n : compareIndexes(a.routesMeta.map(meta => meta.childrenIndex), b.routesMeta.map(meta => meta.childrenIndex)));\n}\nconst paramRe = /^:\\w+$/;\nconst dynamicSegmentValue = 3;\nconst indexRouteValue = 2;\nconst emptySegmentValue = 1;\nconst staticSegmentValue = 10;\nconst splatPenalty = -2;\nconst isSplat = s => s === \"*\";\nfunction computeScore(path, index) {\n let segments = path.split(\"/\");\n let initialScore = segments.length;\n if (segments.some(isSplat)) {\n initialScore += splatPenalty;\n }\n if (index) {\n initialScore += indexRouteValue;\n }\n return segments.filter(s => !isSplat(s)).reduce((score, segment) => score + (paramRe.test(segment) ? dynamicSegmentValue : segment === \"\" ? emptySegmentValue : staticSegmentValue), initialScore);\n}\nfunction compareIndexes(a, b) {\n let siblings = a.length === b.length && a.slice(0, -1).every((n, i) => n === b[i]);\n return siblings ?\n // If two routes are siblings, we should try to match the earlier sibling\n // first. This allows people to have fine-grained control over the matching\n // behavior by simply putting routes with identical paths in the order they\n // want them tried.\n a[a.length - 1] - b[b.length - 1] :\n // Otherwise, it doesn't really make sense to rank non-siblings by index,\n // so they sort equally.\n 0;\n}\nfunction matchRouteBranch(branch, pathname) {\n let {\n routesMeta\n } = branch;\n let matchedParams = {};\n let matchedPathname = \"/\";\n let matches = [];\n for (let i = 0; i < routesMeta.length; ++i) {\n let meta = routesMeta[i];\n let end = i === routesMeta.length - 1;\n let remainingPathname = matchedPathname === \"/\" ? pathname : pathname.slice(matchedPathname.length) || \"/\";\n let match = matchPath({\n path: meta.relativePath,\n caseSensitive: meta.caseSensitive,\n end\n }, remainingPathname);\n if (!match) return null;\n Object.assign(matchedParams, match.params);\n let route = meta.route;\n matches.push({\n // TODO: Can this as be avoided?\n params: matchedParams,\n pathname: joinPaths([matchedPathname, match.pathname]),\n pathnameBase: normalizePathname(joinPaths([matchedPathname, match.pathnameBase])),\n route\n });\n if (match.pathnameBase !== \"/\") {\n matchedPathname = joinPaths([matchedPathname, match.pathnameBase]);\n }\n }\n return matches;\n}\n/**\n * Returns a path with params interpolated.\n *\n * @see https://reactrouter.com/utils/generate-path\n */\nfunction generatePath(originalPath, params) {\n if (params === void 0) {\n params = {};\n }\n let path = originalPath;\n if (path.endsWith(\"*\") && path !== \"*\" && !path.endsWith(\"/*\")) {\n warning(false, \"Route path \\\"\" + path + \"\\\" will be treated as if it were \" + (\"\\\"\" + path.replace(/\\*$/, \"/*\") + \"\\\" because the `*` character must \") + \"always follow a `/` in the pattern. To get rid of this warning, \" + (\"please change the route path to \\\"\" + path.replace(/\\*$/, \"/*\") + \"\\\".\"));\n path = path.replace(/\\*$/, \"/*\");\n }\n // ensure `/` is added at the beginning if the path is absolute\n const prefix = path.startsWith(\"/\") ? \"/\" : \"\";\n const stringify = p => p == null ? \"\" : typeof p === \"string\" ? p : String(p);\n const segments = path.split(/\\/+/).map((segment, index, array) => {\n const isLastSegment = index === array.length - 1;\n // only apply the splat if it's the last segment\n if (isLastSegment && segment === \"*\") {\n const star = \"*\";\n // Apply the splat\n return stringify(params[star]);\n }\n const keyMatch = segment.match(/^:(\\w+)(\\??)$/);\n if (keyMatch) {\n const [, key, optional] = keyMatch;\n let param = params[key];\n invariant(optional === \"?\" || param != null, \"Missing \\\":\" + key + \"\\\" param\");\n return stringify(param);\n }\n // Remove any optional markers from optional static segments\n return segment.replace(/\\?$/g, \"\");\n })\n // Remove empty segments\n .filter(segment => !!segment);\n return prefix + segments.join(\"/\");\n}\n/**\n * Performs pattern matching on a URL pathname and returns information about\n * the match.\n *\n * @see https://reactrouter.com/utils/match-path\n */\nfunction matchPath(pattern, pathname) {\n if (typeof pattern === \"string\") {\n pattern = {\n path: pattern,\n caseSensitive: false,\n end: true\n };\n }\n let [matcher, paramNames] = compilePath(pattern.path, pattern.caseSensitive, pattern.end);\n let match = pathname.match(matcher);\n if (!match) return null;\n let matchedPathname = match[0];\n let pathnameBase = matchedPathname.replace(/(.)\\/+$/, \"$1\");\n let captureGroups = match.slice(1);\n let params = paramNames.reduce((memo, paramName, index) => {\n // We need to compute the pathnameBase here using the raw splat value\n // instead of using params[\"*\"] later because it will be decoded then\n if (paramName === \"*\") {\n let splatValue = captureGroups[index] || \"\";\n pathnameBase = matchedPathname.slice(0, matchedPathname.length - splatValue.length).replace(/(.)\\/+$/, \"$1\");\n }\n memo[paramName] = safelyDecodeURIComponent(captureGroups[index] || \"\", paramName);\n return memo;\n }, {});\n return {\n params,\n pathname: matchedPathname,\n pathnameBase,\n pattern\n };\n}\nfunction compilePath(path, caseSensitive, end) {\n if (caseSensitive === void 0) {\n caseSensitive = false;\n }\n if (end === void 0) {\n end = true;\n }\n warning(path === \"*\" || !path.endsWith(\"*\") || path.endsWith(\"/*\"), \"Route path \\\"\" + path + \"\\\" will be treated as if it were \" + (\"\\\"\" + path.replace(/\\*$/, \"/*\") + \"\\\" because the `*` character must \") + \"always follow a `/` in the pattern. To get rid of this warning, \" + (\"please change the route path to \\\"\" + path.replace(/\\*$/, \"/*\") + \"\\\".\"));\n let paramNames = [];\n let regexpSource = \"^\" + path.replace(/\\/*\\*?$/, \"\") // Ignore trailing / and /*, we'll handle it below\n .replace(/^\\/*/, \"/\") // Make sure it has a leading /\n .replace(/[\\\\.*+^$?{}|()[\\]]/g, \"\\\\$&\") // Escape special regex chars\n .replace(/\\/:(\\w+)/g, (_, paramName) => {\n paramNames.push(paramName);\n return \"/([^\\\\/]+)\";\n });\n if (path.endsWith(\"*\")) {\n paramNames.push(\"*\");\n regexpSource += path === \"*\" || path === \"/*\" ? \"(.*)$\" // Already matched the initial /, just match the rest\n : \"(?:\\\\/(.+)|\\\\/*)$\"; // Don't include the / in params[\"*\"]\n } else if (end) {\n // When matching to the end, ignore trailing slashes\n regexpSource += \"\\\\/*$\";\n } else if (path !== \"\" && path !== \"/\") {\n // If our path is non-empty and contains anything beyond an initial slash,\n // then we have _some_ form of path in our regex so we should expect to\n // match only if we find the end of this path segment. Look for an optional\n // non-captured trailing slash (to match a portion of the URL) or the end\n // of the path (if we've matched to the end). We used to do this with a\n // word boundary but that gives false positives on routes like\n // /user-preferences since `-` counts as a word boundary.\n regexpSource += \"(?:(?=\\\\/|$))\";\n } else ;\n let matcher = new RegExp(regexpSource, caseSensitive ? undefined : \"i\");\n return [matcher, paramNames];\n}\nfunction safelyDecodeURI(value) {\n try {\n return decodeURI(value);\n } catch (error) {\n warning(false, \"The URL path \\\"\" + value + \"\\\" could not be decoded because it is is a \" + \"malformed URL segment. This is probably due to a bad percent \" + (\"encoding (\" + error + \").\"));\n return value;\n }\n}\nfunction safelyDecodeURIComponent(value, paramName) {\n try {\n return decodeURIComponent(value);\n } catch (error) {\n warning(false, \"The value for the URL param \\\"\" + paramName + \"\\\" will not be decoded because\" + (\" the string \\\"\" + value + \"\\\" is a malformed URL segment. This is probably\") + (\" due to a bad percent encoding (\" + error + \").\"));\n return value;\n }\n}\n/**\n * @private\n */\nfunction stripBasename(pathname, basename) {\n if (basename === \"/\") return pathname;\n if (!pathname.toLowerCase().startsWith(basename.toLowerCase())) {\n return null;\n }\n // We want to leave trailing slash behavior in the user's control, so if they\n // specify a basename with a trailing slash, we should support it\n let startIndex = basename.endsWith(\"/\") ? basename.length - 1 : basename.length;\n let nextChar = pathname.charAt(startIndex);\n if (nextChar && nextChar !== \"/\") {\n // pathname does not start with basename/\n return null;\n }\n return pathname.slice(startIndex) || \"/\";\n}\n/**\n * Returns a resolved path object relative to the given pathname.\n *\n * @see https://reactrouter.com/utils/resolve-path\n */\nfunction resolvePath(to, fromPathname) {\n if (fromPathname === void 0) {\n fromPathname = \"/\";\n }\n let {\n pathname: toPathname,\n search = \"\",\n hash = \"\"\n } = typeof to === \"string\" ? parsePath(to) : to;\n let pathname = toPathname ? toPathname.startsWith(\"/\") ? toPathname : resolvePathname(toPathname, fromPathname) : fromPathname;\n return {\n pathname,\n search: normalizeSearch(search),\n hash: normalizeHash(hash)\n };\n}\nfunction resolvePathname(relativePath, fromPathname) {\n let segments = fromPathname.replace(/\\/+$/, \"\").split(\"/\");\n let relativeSegments = relativePath.split(\"/\");\n relativeSegments.forEach(segment => {\n if (segment === \"..\") {\n // Keep the root \"\" segment so the pathname starts at /\n if (segments.length > 1) segments.pop();\n } else if (segment !== \".\") {\n segments.push(segment);\n }\n });\n return segments.length > 1 ? segments.join(\"/\") : \"/\";\n}\nfunction getInvalidPathError(char, field, dest, path) {\n return \"Cannot include a '\" + char + \"' character in a manually specified \" + (\"`to.\" + field + \"` field [\" + JSON.stringify(path) + \"]. Please separate it out to the \") + (\"`to.\" + dest + \"` field. Alternatively you may provide the full path as \") + \"a string in and the router will parse it for you.\";\n}\n/**\n * @private\n *\n * When processing relative navigation we want to ignore ancestor routes that\n * do not contribute to the path, such that index/pathless layout routes don't\n * interfere.\n *\n * For example, when moving a route element into an index route and/or a\n * pathless layout route, relative link behavior contained within should stay\n * the same. Both of the following examples should link back to the root:\n *\n * \n * \n * \n *\n * \n * \n * }> // <-- Does not contribute\n * // <-- Does not contribute\n * \n * \n */\nfunction getPathContributingMatches(matches) {\n return matches.filter((match, index) => index === 0 || match.route.path && match.route.path.length > 0);\n}\n/**\n * @private\n */\nfunction resolveTo(toArg, routePathnames, locationPathname, isPathRelative) {\n if (isPathRelative === void 0) {\n isPathRelative = false;\n }\n let to;\n if (typeof toArg === \"string\") {\n to = parsePath(toArg);\n } else {\n to = _extends({}, toArg);\n invariant(!to.pathname || !to.pathname.includes(\"?\"), getInvalidPathError(\"?\", \"pathname\", \"search\", to));\n invariant(!to.pathname || !to.pathname.includes(\"#\"), getInvalidPathError(\"#\", \"pathname\", \"hash\", to));\n invariant(!to.search || !to.search.includes(\"#\"), getInvalidPathError(\"#\", \"search\", \"hash\", to));\n }\n let isEmptyPath = toArg === \"\" || to.pathname === \"\";\n let toPathname = isEmptyPath ? \"/\" : to.pathname;\n let from;\n // Routing is relative to the current pathname if explicitly requested.\n //\n // If a pathname is explicitly provided in `to`, it should be relative to the\n // route context. This is explained in `Note on `` values` in our\n // migration guide from v5 as a means of disambiguation between `to` values\n // that begin with `/` and those that do not. However, this is problematic for\n // `to` values that do not provide a pathname. `to` can simply be a search or\n // hash string, in which case we should assume that the navigation is relative\n // to the current location's pathname and *not* the route pathname.\n if (isPathRelative || toPathname == null) {\n from = locationPathname;\n } else {\n let routePathnameIndex = routePathnames.length - 1;\n if (toPathname.startsWith(\"..\")) {\n let toSegments = toPathname.split(\"/\");\n // Each leading .. segment means \"go up one route\" instead of \"go up one\n // URL segment\". This is a key difference from how works and a\n // major reason we call this a \"to\" value instead of a \"href\".\n while (toSegments[0] === \"..\") {\n toSegments.shift();\n routePathnameIndex -= 1;\n }\n to.pathname = toSegments.join(\"/\");\n }\n // If there are more \"..\" segments than parent routes, resolve relative to\n // the root / URL.\n from = routePathnameIndex >= 0 ? routePathnames[routePathnameIndex] : \"/\";\n }\n let path = resolvePath(to, from);\n // Ensure the pathname has a trailing slash if the original \"to\" had one\n let hasExplicitTrailingSlash = toPathname && toPathname !== \"/\" && toPathname.endsWith(\"/\");\n // Or if this was a link to the current path which has a trailing slash\n let hasCurrentTrailingSlash = (isEmptyPath || toPathname === \".\") && locationPathname.endsWith(\"/\");\n if (!path.pathname.endsWith(\"/\") && (hasExplicitTrailingSlash || hasCurrentTrailingSlash)) {\n path.pathname += \"/\";\n }\n return path;\n}\n/**\n * @private\n */\nfunction getToPathname(to) {\n // Empty strings should be treated the same as / paths\n return to === \"\" || to.pathname === \"\" ? \"/\" : typeof to === \"string\" ? parsePath(to).pathname : to.pathname;\n}\n/**\n * @private\n */\nconst joinPaths = paths => paths.join(\"/\").replace(/\\/\\/+/g, \"/\");\n/**\n * @private\n */\nconst normalizePathname = pathname => pathname.replace(/\\/+$/, \"\").replace(/^\\/*/, \"/\");\n/**\n * @private\n */\nconst normalizeSearch = search => !search || search === \"?\" ? \"\" : search.startsWith(\"?\") ? search : \"?\" + search;\n/**\n * @private\n */\nconst normalizeHash = hash => !hash || hash === \"#\" ? \"\" : hash.startsWith(\"#\") ? hash : \"#\" + hash;\n/**\n * This is a shortcut for creating `application/json` responses. Converts `data`\n * to JSON and sets the `Content-Type` header.\n */\nconst json = function json(data, init) {\n if (init === void 0) {\n init = {};\n }\n let responseInit = typeof init === \"number\" ? {\n status: init\n } : init;\n let headers = new Headers(responseInit.headers);\n if (!headers.has(\"Content-Type\")) {\n headers.set(\"Content-Type\", \"application/json; charset=utf-8\");\n }\n return new Response(JSON.stringify(data), _extends({}, responseInit, {\n headers\n }));\n};\nclass AbortedDeferredError extends Error {}\nclass DeferredData {\n constructor(data, responseInit) {\n this.pendingKeysSet = new Set();\n this.subscribers = new Set();\n this.deferredKeys = [];\n invariant(data && typeof data === \"object\" && !Array.isArray(data), \"defer() only accepts plain objects\");\n // Set up an AbortController + Promise we can race against to exit early\n // cancellation\n let reject;\n this.abortPromise = new Promise((_, r) => reject = r);\n this.controller = new AbortController();\n let onAbort = () => reject(new AbortedDeferredError(\"Deferred data aborted\"));\n this.unlistenAbortSignal = () => this.controller.signal.removeEventListener(\"abort\", onAbort);\n this.controller.signal.addEventListener(\"abort\", onAbort);\n this.data = Object.entries(data).reduce((acc, _ref) => {\n let [key, value] = _ref;\n return Object.assign(acc, {\n [key]: this.trackPromise(key, value)\n });\n }, {});\n if (this.done) {\n // All incoming values were resolved\n this.unlistenAbortSignal();\n }\n this.init = responseInit;\n }\n trackPromise(key, value) {\n if (!(value instanceof Promise)) {\n return value;\n }\n this.deferredKeys.push(key);\n this.pendingKeysSet.add(key);\n // We store a little wrapper promise that will be extended with\n // _data/_error props upon resolve/reject\n let promise = Promise.race([value, this.abortPromise]).then(data => this.onSettle(promise, key, undefined, data), error => this.onSettle(promise, key, error));\n // Register rejection listeners to avoid uncaught promise rejections on\n // errors or aborted deferred values\n promise.catch(() => {});\n Object.defineProperty(promise, \"_tracked\", {\n get: () => true\n });\n return promise;\n }\n onSettle(promise, key, error, data) {\n if (this.controller.signal.aborted && error instanceof AbortedDeferredError) {\n this.unlistenAbortSignal();\n Object.defineProperty(promise, \"_error\", {\n get: () => error\n });\n return Promise.reject(error);\n }\n this.pendingKeysSet.delete(key);\n if (this.done) {\n // Nothing left to abort!\n this.unlistenAbortSignal();\n }\n // If the promise was resolved/rejected with undefined, we'll throw an error as you\n // should always resolve with a value or null\n if (error === undefined && data === undefined) {\n let undefinedError = new Error(\"Deferred data for key \\\"\" + key + \"\\\" resolved/rejected with `undefined`, \" + \"you must resolve/reject with a value or `null`.\");\n Object.defineProperty(promise, \"_error\", {\n get: () => undefinedError\n });\n this.emit(false, key);\n return Promise.reject(undefinedError);\n }\n if (data === undefined) {\n Object.defineProperty(promise, \"_error\", {\n get: () => error\n });\n this.emit(false, key);\n return Promise.reject(error);\n }\n Object.defineProperty(promise, \"_data\", {\n get: () => data\n });\n this.emit(false, key);\n return data;\n }\n emit(aborted, settledKey) {\n this.subscribers.forEach(subscriber => subscriber(aborted, settledKey));\n }\n subscribe(fn) {\n this.subscribers.add(fn);\n return () => this.subscribers.delete(fn);\n }\n cancel() {\n this.controller.abort();\n this.pendingKeysSet.forEach((v, k) => this.pendingKeysSet.delete(k));\n this.emit(true);\n }\n async resolveData(signal) {\n let aborted = false;\n if (!this.done) {\n let onAbort = () => this.cancel();\n signal.addEventListener(\"abort\", onAbort);\n aborted = await new Promise(resolve => {\n this.subscribe(aborted => {\n signal.removeEventListener(\"abort\", onAbort);\n if (aborted || this.done) {\n resolve(aborted);\n }\n });\n });\n }\n return aborted;\n }\n get done() {\n return this.pendingKeysSet.size === 0;\n }\n get unwrappedData() {\n invariant(this.data !== null && this.done, \"Can only unwrap data on initialized and settled deferreds\");\n return Object.entries(this.data).reduce((acc, _ref2) => {\n let [key, value] = _ref2;\n return Object.assign(acc, {\n [key]: unwrapTrackedPromise(value)\n });\n }, {});\n }\n get pendingKeys() {\n return Array.from(this.pendingKeysSet);\n }\n}\nfunction isTrackedPromise(value) {\n return value instanceof Promise && value._tracked === true;\n}\nfunction unwrapTrackedPromise(value) {\n if (!isTrackedPromise(value)) {\n return value;\n }\n if (value._error) {\n throw value._error;\n }\n return value._data;\n}\nconst defer = function defer(data, init) {\n if (init === void 0) {\n init = {};\n }\n let responseInit = typeof init === \"number\" ? {\n status: init\n } : init;\n return new DeferredData(data, responseInit);\n};\n/**\n * A redirect response. Sets the status code and the `Location` header.\n * Defaults to \"302 Found\".\n */\nconst redirect = function redirect(url, init) {\n if (init === void 0) {\n init = 302;\n }\n let responseInit = init;\n if (typeof responseInit === \"number\") {\n responseInit = {\n status: responseInit\n };\n } else if (typeof responseInit.status === \"undefined\") {\n responseInit.status = 302;\n }\n let headers = new Headers(responseInit.headers);\n headers.set(\"Location\", url);\n return new Response(null, _extends({}, responseInit, {\n headers\n }));\n};\n/**\n * A redirect response that will force a document reload to the new location.\n * Sets the status code and the `Location` header.\n * Defaults to \"302 Found\".\n */\nconst redirectDocument = (url, init) => {\n let response = redirect(url, init);\n response.headers.set(\"X-Remix-Reload-Document\", \"true\");\n return response;\n};\n/**\n * @private\n * Utility class we use to hold auto-unwrapped 4xx/5xx Response bodies\n */\nclass ErrorResponse {\n constructor(status, statusText, data, internal) {\n if (internal === void 0) {\n internal = false;\n }\n this.status = status;\n this.statusText = statusText || \"\";\n this.internal = internal;\n if (data instanceof Error) {\n this.data = data.toString();\n this.error = data;\n } else {\n this.data = data;\n }\n }\n}\n/**\n * Check if the given error is an ErrorResponse generated from a 4xx/5xx\n * Response thrown from an action/loader\n */\nfunction isRouteErrorResponse(error) {\n return error != null && typeof error.status === \"number\" && typeof error.statusText === \"string\" && typeof error.internal === \"boolean\" && \"data\" in error;\n}\n\nconst validMutationMethodsArr = [\"post\", \"put\", \"patch\", \"delete\"];\nconst validMutationMethods = new Set(validMutationMethodsArr);\nconst validRequestMethodsArr = [\"get\", ...validMutationMethodsArr];\nconst validRequestMethods = new Set(validRequestMethodsArr);\nconst redirectStatusCodes = new Set([301, 302, 303, 307, 308]);\nconst redirectPreserveMethodStatusCodes = new Set([307, 308]);\nconst IDLE_NAVIGATION = {\n state: \"idle\",\n location: undefined,\n formMethod: undefined,\n formAction: undefined,\n formEncType: undefined,\n formData: undefined,\n json: undefined,\n text: undefined\n};\nconst IDLE_FETCHER = {\n state: \"idle\",\n data: undefined,\n formMethod: undefined,\n formAction: undefined,\n formEncType: undefined,\n formData: undefined,\n json: undefined,\n text: undefined\n};\nconst IDLE_BLOCKER = {\n state: \"unblocked\",\n proceed: undefined,\n reset: undefined,\n location: undefined\n};\nconst ABSOLUTE_URL_REGEX = /^(?:[a-z][a-z0-9+.-]*:|\\/\\/)/i;\nconst defaultMapRouteProperties = route => ({\n hasErrorBoundary: Boolean(route.hasErrorBoundary)\n});\n//#endregion\n////////////////////////////////////////////////////////////////////////////////\n//#region createRouter\n////////////////////////////////////////////////////////////////////////////////\n/**\n * Create a router and listen to history POP navigations\n */\nfunction createRouter(init) {\n const routerWindow = init.window ? init.window : typeof window !== \"undefined\" ? window : undefined;\n const isBrowser = typeof routerWindow !== \"undefined\" && typeof routerWindow.document !== \"undefined\" && typeof routerWindow.document.createElement !== \"undefined\";\n const isServer = !isBrowser;\n invariant(init.routes.length > 0, \"You must provide a non-empty routes array to createRouter\");\n let mapRouteProperties;\n if (init.mapRouteProperties) {\n mapRouteProperties = init.mapRouteProperties;\n } else if (init.detectErrorBoundary) {\n // If they are still using the deprecated version, wrap it with the new API\n let detectErrorBoundary = init.detectErrorBoundary;\n mapRouteProperties = route => ({\n hasErrorBoundary: detectErrorBoundary(route)\n });\n } else {\n mapRouteProperties = defaultMapRouteProperties;\n }\n // Routes keyed by ID\n let manifest = {};\n // Routes in tree format for matching\n let dataRoutes = convertRoutesToDataRoutes(init.routes, mapRouteProperties, undefined, manifest);\n let inFlightDataRoutes;\n let basename = init.basename || \"/\";\n // Config driven behavior flags\n let future = _extends({\n v7_normalizeFormMethod: false,\n v7_prependBasename: false\n }, init.future);\n // Cleanup function for history\n let unlistenHistory = null;\n // Externally-provided functions to call on all state changes\n let subscribers = new Set();\n // Externally-provided object to hold scroll restoration locations during routing\n let savedScrollPositions = null;\n // Externally-provided function to get scroll restoration keys\n let getScrollRestorationKey = null;\n // Externally-provided function to get current scroll position\n let getScrollPosition = null;\n // One-time flag to control the initial hydration scroll restoration. Because\n // we don't get the saved positions from until _after_\n // the initial render, we need to manually trigger a separate updateState to\n // send along the restoreScrollPosition\n // Set to true if we have `hydrationData` since we assume we were SSR'd and that\n // SSR did the initial scroll restoration.\n let initialScrollRestored = init.hydrationData != null;\n let initialMatches = matchRoutes(dataRoutes, init.history.location, basename);\n let initialErrors = null;\n if (initialMatches == null) {\n // If we do not match a user-provided-route, fall back to the root\n // to allow the error boundary to take over\n let error = getInternalRouterError(404, {\n pathname: init.history.location.pathname\n });\n let {\n matches,\n route\n } = getShortCircuitMatches(dataRoutes);\n initialMatches = matches;\n initialErrors = {\n [route.id]: error\n };\n }\n let initialized =\n // All initialMatches need to be loaded before we're ready. If we have lazy\n // functions around still then we'll need to run them in initialize()\n !initialMatches.some(m => m.route.lazy) && (\n // And we have to either have no loaders or have been provided hydrationData\n !initialMatches.some(m => m.route.loader) || init.hydrationData != null);\n let router;\n let state = {\n historyAction: init.history.action,\n location: init.history.location,\n matches: initialMatches,\n initialized,\n navigation: IDLE_NAVIGATION,\n // Don't restore on initial updateState() if we were SSR'd\n restoreScrollPosition: init.hydrationData != null ? false : null,\n preventScrollReset: false,\n revalidation: \"idle\",\n loaderData: init.hydrationData && init.hydrationData.loaderData || {},\n actionData: init.hydrationData && init.hydrationData.actionData || null,\n errors: init.hydrationData && init.hydrationData.errors || initialErrors,\n fetchers: new Map(),\n blockers: new Map()\n };\n // -- Stateful internal variables to manage navigations --\n // Current navigation in progress (to be committed in completeNavigation)\n let pendingAction = Action.Pop;\n // Should the current navigation prevent the scroll reset if scroll cannot\n // be restored?\n let pendingPreventScrollReset = false;\n // AbortController for the active navigation\n let pendingNavigationController;\n // We use this to avoid touching history in completeNavigation if a\n // revalidation is entirely uninterrupted\n let isUninterruptedRevalidation = false;\n // Use this internal flag to force revalidation of all loaders:\n // - submissions (completed or interrupted)\n // - useRevalidator()\n // - X-Remix-Revalidate (from redirect)\n let isRevalidationRequired = false;\n // Use this internal array to capture routes that require revalidation due\n // to a cancelled deferred on action submission\n let cancelledDeferredRoutes = [];\n // Use this internal array to capture fetcher loads that were cancelled by an\n // action navigation and require revalidation\n let cancelledFetcherLoads = [];\n // AbortControllers for any in-flight fetchers\n let fetchControllers = new Map();\n // Track loads based on the order in which they started\n let incrementingLoadId = 0;\n // Track the outstanding pending navigation data load to be compared against\n // the globally incrementing load when a fetcher load lands after a completed\n // navigation\n let pendingNavigationLoadId = -1;\n // Fetchers that triggered data reloads as a result of their actions\n let fetchReloadIds = new Map();\n // Fetchers that triggered redirect navigations\n let fetchRedirectIds = new Set();\n // Most recent href/match for fetcher.load calls for fetchers\n let fetchLoadMatches = new Map();\n // Store DeferredData instances for active route matches. When a\n // route loader returns defer() we stick one in here. Then, when a nested\n // promise resolves we update loaderData. If a new navigation starts we\n // cancel active deferreds for eliminated routes.\n let activeDeferreds = new Map();\n // Store blocker functions in a separate Map outside of router state since\n // we don't need to update UI state if they change\n let blockerFunctions = new Map();\n // Flag to ignore the next history update, so we can revert the URL change on\n // a POP navigation that was blocked by the user without touching router state\n let ignoreNextHistoryUpdate = false;\n // Initialize the router, all side effects should be kicked off from here.\n // Implemented as a Fluent API for ease of:\n // let router = createRouter(init).initialize();\n function initialize() {\n // If history informs us of a POP navigation, start the navigation but do not update\n // state. We'll update our own state once the navigation completes\n unlistenHistory = init.history.listen(_ref => {\n let {\n action: historyAction,\n location,\n delta\n } = _ref;\n // Ignore this event if it was just us resetting the URL from a\n // blocked POP navigation\n if (ignoreNextHistoryUpdate) {\n ignoreNextHistoryUpdate = false;\n return;\n }\n warning(blockerFunctions.size === 0 || delta != null, \"You are trying to use a blocker on a POP navigation to a location \" + \"that was not created by @remix-run/router. This will fail silently in \" + \"production. This can happen if you are navigating outside the router \" + \"via `window.history.pushState`/`window.location.hash` instead of using \" + \"router navigation APIs. This can also happen if you are using \" + \"createHashRouter and the user manually changes the URL.\");\n let blockerKey = shouldBlockNavigation({\n currentLocation: state.location,\n nextLocation: location,\n historyAction\n });\n if (blockerKey && delta != null) {\n // Restore the URL to match the current UI, but don't update router state\n ignoreNextHistoryUpdate = true;\n init.history.go(delta * -1);\n // Put the blocker into a blocked state\n updateBlocker(blockerKey, {\n state: \"blocked\",\n location,\n proceed() {\n updateBlocker(blockerKey, {\n state: \"proceeding\",\n proceed: undefined,\n reset: undefined,\n location\n });\n // Re-do the same POP navigation we just blocked\n init.history.go(delta);\n },\n reset() {\n let blockers = new Map(state.blockers);\n blockers.set(blockerKey, IDLE_BLOCKER);\n updateState({\n blockers\n });\n }\n });\n return;\n }\n return startNavigation(historyAction, location);\n });\n // Kick off initial data load if needed. Use Pop to avoid modifying history\n // Note we don't do any handling of lazy here. For SPA's it'll get handled\n // in the normal navigation flow. For SSR it's expected that lazy modules are\n // resolved prior to router creation since we can't go into a fallbackElement\n // UI for SSR'd apps\n if (!state.initialized) {\n startNavigation(Action.Pop, state.location);\n }\n return router;\n }\n // Clean up a router and it's side effects\n function dispose() {\n if (unlistenHistory) {\n unlistenHistory();\n }\n subscribers.clear();\n pendingNavigationController && pendingNavigationController.abort();\n state.fetchers.forEach((_, key) => deleteFetcher(key));\n state.blockers.forEach((_, key) => deleteBlocker(key));\n }\n // Subscribe to state updates for the router\n function subscribe(fn) {\n subscribers.add(fn);\n return () => subscribers.delete(fn);\n }\n // Update our state and notify the calling context of the change\n function updateState(newState) {\n state = _extends({}, state, newState);\n subscribers.forEach(subscriber => subscriber(state));\n }\n // Complete a navigation returning the state.navigation back to the IDLE_NAVIGATION\n // and setting state.[historyAction/location/matches] to the new route.\n // - Location is a required param\n // - Navigation will always be set to IDLE_NAVIGATION\n // - Can pass any other state in newState\n function completeNavigation(location, newState) {\n var _location$state, _location$state2;\n // Deduce if we're in a loading/actionReload state:\n // - We have committed actionData in the store\n // - The current navigation was a mutation submission\n // - We're past the submitting state and into the loading state\n // - The location being loaded is not the result of a redirect\n let isActionReload = state.actionData != null && state.navigation.formMethod != null && isMutationMethod(state.navigation.formMethod) && state.navigation.state === \"loading\" && ((_location$state = location.state) == null ? void 0 : _location$state._isRedirect) !== true;\n let actionData;\n if (newState.actionData) {\n if (Object.keys(newState.actionData).length > 0) {\n actionData = newState.actionData;\n } else {\n // Empty actionData -> clear prior actionData due to an action error\n actionData = null;\n }\n } else if (isActionReload) {\n // Keep the current data if we're wrapping up the action reload\n actionData = state.actionData;\n } else {\n // Clear actionData on any other completed navigations\n actionData = null;\n }\n // Always preserve any existing loaderData from re-used routes\n let loaderData = newState.loaderData ? mergeLoaderData(state.loaderData, newState.loaderData, newState.matches || [], newState.errors) : state.loaderData;\n // On a successful navigation we can assume we got through all blockers\n // so we can start fresh\n let blockers = state.blockers;\n if (blockers.size > 0) {\n blockers = new Map(blockers);\n blockers.forEach((_, k) => blockers.set(k, IDLE_BLOCKER));\n }\n // Always respect the user flag. Otherwise don't reset on mutation\n // submission navigations unless they redirect\n let preventScrollReset = pendingPreventScrollReset === true || state.navigation.formMethod != null && isMutationMethod(state.navigation.formMethod) && ((_location$state2 = location.state) == null ? void 0 : _location$state2._isRedirect) !== true;\n if (inFlightDataRoutes) {\n dataRoutes = inFlightDataRoutes;\n inFlightDataRoutes = undefined;\n }\n if (isUninterruptedRevalidation) ; else if (pendingAction === Action.Pop) ; else if (pendingAction === Action.Push) {\n init.history.push(location, location.state);\n } else if (pendingAction === Action.Replace) {\n init.history.replace(location, location.state);\n }\n updateState(_extends({}, newState, {\n actionData,\n loaderData,\n historyAction: pendingAction,\n location,\n initialized: true,\n navigation: IDLE_NAVIGATION,\n revalidation: \"idle\",\n restoreScrollPosition: getSavedScrollPosition(location, newState.matches || state.matches),\n preventScrollReset,\n blockers\n }));\n // Reset stateful navigation vars\n pendingAction = Action.Pop;\n pendingPreventScrollReset = false;\n isUninterruptedRevalidation = false;\n isRevalidationRequired = false;\n cancelledDeferredRoutes = [];\n cancelledFetcherLoads = [];\n }\n // Trigger a navigation event, which can either be a numerical POP or a PUSH\n // replace with an optional submission\n async function navigate(to, opts) {\n if (typeof to === \"number\") {\n init.history.go(to);\n return;\n }\n let normalizedPath = normalizeTo(state.location, state.matches, basename, future.v7_prependBasename, to, opts == null ? void 0 : opts.fromRouteId, opts == null ? void 0 : opts.relative);\n let {\n path,\n submission,\n error\n } = normalizeNavigateOptions(future.v7_normalizeFormMethod, false, normalizedPath, opts);\n let currentLocation = state.location;\n let nextLocation = createLocation(state.location, path, opts && opts.state);\n // When using navigate as a PUSH/REPLACE we aren't reading an already-encoded\n // URL from window.location, so we need to encode it here so the behavior\n // remains the same as POP and non-data-router usages. new URL() does all\n // the same encoding we'd get from a history.pushState/window.location read\n // without having to touch history\n nextLocation = _extends({}, nextLocation, init.history.encodeLocation(nextLocation));\n let userReplace = opts && opts.replace != null ? opts.replace : undefined;\n let historyAction = Action.Push;\n if (userReplace === true) {\n historyAction = Action.Replace;\n } else if (userReplace === false) ; else if (submission != null && isMutationMethod(submission.formMethod) && submission.formAction === state.location.pathname + state.location.search) {\n // By default on submissions to the current location we REPLACE so that\n // users don't have to double-click the back button to get to the prior\n // location. If the user redirects to a different location from the\n // action/loader this will be ignored and the redirect will be a PUSH\n historyAction = Action.Replace;\n }\n let preventScrollReset = opts && \"preventScrollReset\" in opts ? opts.preventScrollReset === true : undefined;\n let blockerKey = shouldBlockNavigation({\n currentLocation,\n nextLocation,\n historyAction\n });\n if (blockerKey) {\n // Put the blocker into a blocked state\n updateBlocker(blockerKey, {\n state: \"blocked\",\n location: nextLocation,\n proceed() {\n updateBlocker(blockerKey, {\n state: \"proceeding\",\n proceed: undefined,\n reset: undefined,\n location: nextLocation\n });\n // Send the same navigation through\n navigate(to, opts);\n },\n reset() {\n let blockers = new Map(state.blockers);\n blockers.set(blockerKey, IDLE_BLOCKER);\n updateState({\n blockers\n });\n }\n });\n return;\n }\n return await startNavigation(historyAction, nextLocation, {\n submission,\n // Send through the formData serialization error if we have one so we can\n // render at the right error boundary after we match routes\n pendingError: error,\n preventScrollReset,\n replace: opts && opts.replace\n });\n }\n // Revalidate all current loaders. If a navigation is in progress or if this\n // is interrupted by a navigation, allow this to \"succeed\" by calling all\n // loaders during the next loader round\n function revalidate() {\n interruptActiveLoads();\n updateState({\n revalidation: \"loading\"\n });\n // If we're currently submitting an action, we don't need to start a new\n // navigation, we'll just let the follow up loader execution call all loaders\n if (state.navigation.state === \"submitting\") {\n return;\n }\n // If we're currently in an idle state, start a new navigation for the current\n // action/location and mark it as uninterrupted, which will skip the history\n // update in completeNavigation\n if (state.navigation.state === \"idle\") {\n startNavigation(state.historyAction, state.location, {\n startUninterruptedRevalidation: true\n });\n return;\n }\n // Otherwise, if we're currently in a loading state, just start a new\n // navigation to the navigation.location but do not trigger an uninterrupted\n // revalidation so that history correctly updates once the navigation completes\n startNavigation(pendingAction || state.historyAction, state.navigation.location, {\n overrideNavigation: state.navigation\n });\n }\n // Start a navigation to the given action/location. Can optionally provide a\n // overrideNavigation which will override the normalLoad in the case of a redirect\n // navigation\n async function startNavigation(historyAction, location, opts) {\n // Abort any in-progress navigations and start a new one. Unset any ongoing\n // uninterrupted revalidations unless told otherwise, since we want this\n // new navigation to update history normally\n pendingNavigationController && pendingNavigationController.abort();\n pendingNavigationController = null;\n pendingAction = historyAction;\n isUninterruptedRevalidation = (opts && opts.startUninterruptedRevalidation) === true;\n // Save the current scroll position every time we start a new navigation,\n // and track whether we should reset scroll on completion\n saveScrollPosition(state.location, state.matches);\n pendingPreventScrollReset = (opts && opts.preventScrollReset) === true;\n let routesToUse = inFlightDataRoutes || dataRoutes;\n let loadingNavigation = opts && opts.overrideNavigation;\n let matches = matchRoutes(routesToUse, location, basename);\n // Short circuit with a 404 on the root error boundary if we match nothing\n if (!matches) {\n let error = getInternalRouterError(404, {\n pathname: location.pathname\n });\n let {\n matches: notFoundMatches,\n route\n } = getShortCircuitMatches(routesToUse);\n // Cancel all pending deferred on 404s since we don't keep any routes\n cancelActiveDeferreds();\n completeNavigation(location, {\n matches: notFoundMatches,\n loaderData: {},\n errors: {\n [route.id]: error\n }\n });\n return;\n }\n // Short circuit if it's only a hash change and not a revalidation or\n // mutation submission.\n //\n // Ignore on initial page loads because since the initial load will always\n // be \"same hash\". For example, on /page#hash and submit a
\n // which will default to a navigation to /page\n if (state.initialized && !isRevalidationRequired && isHashChangeOnly(state.location, location) && !(opts && opts.submission && isMutationMethod(opts.submission.formMethod))) {\n completeNavigation(location, {\n matches\n });\n return;\n }\n // Create a controller/Request for this navigation\n pendingNavigationController = new AbortController();\n let request = createClientSideRequest(init.history, location, pendingNavigationController.signal, opts && opts.submission);\n let pendingActionData;\n let pendingError;\n if (opts && opts.pendingError) {\n // If we have a pendingError, it means the user attempted a GET submission\n // with binary FormData so assign here and skip to handleLoaders. That\n // way we handle calling loaders above the boundary etc. It's not really\n // different from an actionError in that sense.\n pendingError = {\n [findNearestBoundary(matches).route.id]: opts.pendingError\n };\n } else if (opts && opts.submission && isMutationMethod(opts.submission.formMethod)) {\n // Call action if we received an action submission\n let actionOutput = await handleAction(request, location, opts.submission, matches, {\n replace: opts.replace\n });\n if (actionOutput.shortCircuited) {\n return;\n }\n pendingActionData = actionOutput.pendingActionData;\n pendingError = actionOutput.pendingActionError;\n loadingNavigation = getLoadingNavigation(location, opts.submission);\n // Create a GET request for the loaders\n request = new Request(request.url, {\n signal: request.signal\n });\n }\n // Call loaders\n let {\n shortCircuited,\n loaderData,\n errors\n } = await handleLoaders(request, location, matches, loadingNavigation, opts && opts.submission, opts && opts.fetcherSubmission, opts && opts.replace, pendingActionData, pendingError);\n if (shortCircuited) {\n return;\n }\n // Clean up now that the action/loaders have completed. Don't clean up if\n // we short circuited because pendingNavigationController will have already\n // been assigned to a new controller for the next navigation\n pendingNavigationController = null;\n completeNavigation(location, _extends({\n matches\n }, pendingActionData ? {\n actionData: pendingActionData\n } : {}, {\n loaderData,\n errors\n }));\n }\n // Call the action matched by the leaf route for this navigation and handle\n // redirects/errors\n async function handleAction(request, location, submission, matches, opts) {\n if (opts === void 0) {\n opts = {};\n }\n interruptActiveLoads();\n // Put us in a submitting state\n let navigation = getSubmittingNavigation(location, submission);\n updateState({\n navigation\n });\n // Call our action and get the result\n let result;\n let actionMatch = getTargetMatch(matches, location);\n if (!actionMatch.route.action && !actionMatch.route.lazy) {\n result = {\n type: ResultType.error,\n error: getInternalRouterError(405, {\n method: request.method,\n pathname: location.pathname,\n routeId: actionMatch.route.id\n })\n };\n } else {\n result = await callLoaderOrAction(\"action\", request, actionMatch, matches, manifest, mapRouteProperties, basename);\n if (request.signal.aborted) {\n return {\n shortCircuited: true\n };\n }\n }\n if (isRedirectResult(result)) {\n let replace;\n if (opts && opts.replace != null) {\n replace = opts.replace;\n } else {\n // If the user didn't explicity indicate replace behavior, replace if\n // we redirected to the exact same location we're currently at to avoid\n // double back-buttons\n replace = result.location === state.location.pathname + state.location.search;\n }\n await startRedirectNavigation(state, result, {\n submission,\n replace\n });\n return {\n shortCircuited: true\n };\n }\n if (isErrorResult(result)) {\n // Store off the pending error - we use it to determine which loaders\n // to call and will commit it when we complete the navigation\n let boundaryMatch = findNearestBoundary(matches, actionMatch.route.id);\n // By default, all submissions are REPLACE navigations, but if the\n // action threw an error that'll be rendered in an errorElement, we fall\n // back to PUSH so that the user can use the back button to get back to\n // the pre-submission form location to try again\n if ((opts && opts.replace) !== true) {\n pendingAction = Action.Push;\n }\n return {\n // Send back an empty object we can use to clear out any prior actionData\n pendingActionData: {},\n pendingActionError: {\n [boundaryMatch.route.id]: result.error\n }\n };\n }\n if (isDeferredResult(result)) {\n throw getInternalRouterError(400, {\n type: \"defer-action\"\n });\n }\n return {\n pendingActionData: {\n [actionMatch.route.id]: result.data\n }\n };\n }\n // Call all applicable loaders for the given matches, handling redirects,\n // errors, etc.\n async function handleLoaders(request, location, matches, overrideNavigation, submission, fetcherSubmission, replace, pendingActionData, pendingError) {\n // Figure out the right navigation we want to use for data loading\n let loadingNavigation = overrideNavigation || getLoadingNavigation(location, submission);\n // If this was a redirect from an action we don't have a \"submission\" but\n // we have it on the loading navigation so use that if available\n let activeSubmission = submission || fetcherSubmission || getSubmissionFromNavigation(loadingNavigation);\n let routesToUse = inFlightDataRoutes || dataRoutes;\n let [matchesToLoad, revalidatingFetchers] = getMatchesToLoad(init.history, state, matches, activeSubmission, location, isRevalidationRequired, cancelledDeferredRoutes, cancelledFetcherLoads, fetchLoadMatches, fetchRedirectIds, routesToUse, basename, pendingActionData, pendingError);\n // Cancel pending deferreds for no-longer-matched routes or routes we're\n // about to reload. Note that if this is an action reload we would have\n // already cancelled all pending deferreds so this would be a no-op\n cancelActiveDeferreds(routeId => !(matches && matches.some(m => m.route.id === routeId)) || matchesToLoad && matchesToLoad.some(m => m.route.id === routeId));\n pendingNavigationLoadId = ++incrementingLoadId;\n // Short circuit if we have no loaders to run\n if (matchesToLoad.length === 0 && revalidatingFetchers.length === 0) {\n let updatedFetchers = markFetchRedirectsDone();\n completeNavigation(location, _extends({\n matches,\n loaderData: {},\n // Commit pending error if we're short circuiting\n errors: pendingError || null\n }, pendingActionData ? {\n actionData: pendingActionData\n } : {}, updatedFetchers ? {\n fetchers: new Map(state.fetchers)\n } : {}));\n return {\n shortCircuited: true\n };\n }\n // If this is an uninterrupted revalidation, we remain in our current idle\n // state. If not, we need to switch to our loading state and load data,\n // preserving any new action data or existing action data (in the case of\n // a revalidation interrupting an actionReload)\n if (!isUninterruptedRevalidation) {\n revalidatingFetchers.forEach(rf => {\n let fetcher = state.fetchers.get(rf.key);\n let revalidatingFetcher = getLoadingFetcher(undefined, fetcher ? fetcher.data : undefined);\n state.fetchers.set(rf.key, revalidatingFetcher);\n });\n let actionData = pendingActionData || state.actionData;\n updateState(_extends({\n navigation: loadingNavigation\n }, actionData ? Object.keys(actionData).length === 0 ? {\n actionData: null\n } : {\n actionData\n } : {}, revalidatingFetchers.length > 0 ? {\n fetchers: new Map(state.fetchers)\n } : {}));\n }\n revalidatingFetchers.forEach(rf => {\n if (fetchControllers.has(rf.key)) {\n abortFetcher(rf.key);\n }\n if (rf.controller) {\n // Fetchers use an independent AbortController so that aborting a fetcher\n // (via deleteFetcher) does not abort the triggering navigation that\n // triggered the revalidation\n fetchControllers.set(rf.key, rf.controller);\n }\n });\n // Proxy navigation abort through to revalidation fetchers\n let abortPendingFetchRevalidations = () => revalidatingFetchers.forEach(f => abortFetcher(f.key));\n if (pendingNavigationController) {\n pendingNavigationController.signal.addEventListener(\"abort\", abortPendingFetchRevalidations);\n }\n let {\n results,\n loaderResults,\n fetcherResults\n } = await callLoadersAndMaybeResolveData(state.matches, matches, matchesToLoad, revalidatingFetchers, request);\n if (request.signal.aborted) {\n return {\n shortCircuited: true\n };\n }\n // Clean up _after_ loaders have completed. Don't clean up if we short\n // circuited because fetchControllers would have been aborted and\n // reassigned to new controllers for the next navigation\n if (pendingNavigationController) {\n pendingNavigationController.signal.removeEventListener(\"abort\", abortPendingFetchRevalidations);\n }\n revalidatingFetchers.forEach(rf => fetchControllers.delete(rf.key));\n // If any loaders returned a redirect Response, start a new REPLACE navigation\n let redirect = findRedirect(results);\n if (redirect) {\n if (redirect.idx >= matchesToLoad.length) {\n // If this redirect came from a fetcher make sure we mark it in\n // fetchRedirectIds so it doesn't get revalidated on the next set of\n // loader executions\n let fetcherKey = revalidatingFetchers[redirect.idx - matchesToLoad.length].key;\n fetchRedirectIds.add(fetcherKey);\n }\n await startRedirectNavigation(state, redirect.result, {\n replace\n });\n return {\n shortCircuited: true\n };\n }\n // Process and commit output from loaders\n let {\n loaderData,\n errors\n } = processLoaderData(state, matches, matchesToLoad, loaderResults, pendingError, revalidatingFetchers, fetcherResults, activeDeferreds);\n // Wire up subscribers to update loaderData as promises settle\n activeDeferreds.forEach((deferredData, routeId) => {\n deferredData.subscribe(aborted => {\n // Note: No need to updateState here since the TrackedPromise on\n // loaderData is stable across resolve/reject\n // Remove this instance if we were aborted or if promises have settled\n if (aborted || deferredData.done) {\n activeDeferreds.delete(routeId);\n }\n });\n });\n let updatedFetchers = markFetchRedirectsDone();\n let didAbortFetchLoads = abortStaleFetchLoads(pendingNavigationLoadId);\n let shouldUpdateFetchers = updatedFetchers || didAbortFetchLoads || revalidatingFetchers.length > 0;\n return _extends({\n loaderData,\n errors\n }, shouldUpdateFetchers ? {\n fetchers: new Map(state.fetchers)\n } : {});\n }\n function getFetcher(key) {\n return state.fetchers.get(key) || IDLE_FETCHER;\n }\n // Trigger a fetcher load/submit for the given fetcher key\n function fetch(key, routeId, href, opts) {\n if (isServer) {\n throw new Error(\"router.fetch() was called during the server render, but it shouldn't be. \" + \"You are likely calling a useFetcher() method in the body of your component. \" + \"Try moving it to a useEffect or a callback.\");\n }\n if (fetchControllers.has(key)) abortFetcher(key);\n let routesToUse = inFlightDataRoutes || dataRoutes;\n let normalizedPath = normalizeTo(state.location, state.matches, basename, future.v7_prependBasename, href, routeId, opts == null ? void 0 : opts.relative);\n let matches = matchRoutes(routesToUse, normalizedPath, basename);\n if (!matches) {\n setFetcherError(key, routeId, getInternalRouterError(404, {\n pathname: normalizedPath\n }));\n return;\n }\n let {\n path,\n submission,\n error\n } = normalizeNavigateOptions(future.v7_normalizeFormMethod, true, normalizedPath, opts);\n if (error) {\n setFetcherError(key, routeId, error);\n return;\n }\n let match = getTargetMatch(matches, path);\n pendingPreventScrollReset = (opts && opts.preventScrollReset) === true;\n if (submission && isMutationMethod(submission.formMethod)) {\n handleFetcherAction(key, routeId, path, match, matches, submission);\n return;\n }\n // Store off the match so we can call it's shouldRevalidate on subsequent\n // revalidations\n fetchLoadMatches.set(key, {\n routeId,\n path\n });\n handleFetcherLoader(key, routeId, path, match, matches, submission);\n }\n // Call the action for the matched fetcher.submit(), and then handle redirects,\n // errors, and revalidation\n async function handleFetcherAction(key, routeId, path, match, requestMatches, submission) {\n interruptActiveLoads();\n fetchLoadMatches.delete(key);\n if (!match.route.action && !match.route.lazy) {\n let error = getInternalRouterError(405, {\n method: submission.formMethod,\n pathname: path,\n routeId: routeId\n });\n setFetcherError(key, routeId, error);\n return;\n }\n // Put this fetcher into it's submitting state\n let existingFetcher = state.fetchers.get(key);\n let fetcher = getSubmittingFetcher(submission, existingFetcher);\n state.fetchers.set(key, fetcher);\n updateState({\n fetchers: new Map(state.fetchers)\n });\n // Call the action for the fetcher\n let abortController = new AbortController();\n let fetchRequest = createClientSideRequest(init.history, path, abortController.signal, submission);\n fetchControllers.set(key, abortController);\n let originatingLoadId = incrementingLoadId;\n let actionResult = await callLoaderOrAction(\"action\", fetchRequest, match, requestMatches, manifest, mapRouteProperties, basename);\n if (fetchRequest.signal.aborted) {\n // We can delete this so long as we weren't aborted by ou our own fetcher\n // re-submit which would have put _new_ controller is in fetchControllers\n if (fetchControllers.get(key) === abortController) {\n fetchControllers.delete(key);\n }\n return;\n }\n if (isRedirectResult(actionResult)) {\n fetchControllers.delete(key);\n if (pendingNavigationLoadId > originatingLoadId) {\n // A new navigation was kicked off after our action started, so that\n // should take precedence over this redirect navigation. We already\n // set isRevalidationRequired so all loaders for the new route should\n // fire unless opted out via shouldRevalidate\n let doneFetcher = getDoneFetcher(undefined);\n state.fetchers.set(key, doneFetcher);\n updateState({\n fetchers: new Map(state.fetchers)\n });\n return;\n } else {\n fetchRedirectIds.add(key);\n let loadingFetcher = getLoadingFetcher(submission);\n state.fetchers.set(key, loadingFetcher);\n updateState({\n fetchers: new Map(state.fetchers)\n });\n return startRedirectNavigation(state, actionResult, {\n submission,\n isFetchActionRedirect: true\n });\n }\n }\n // Process any non-redirect errors thrown\n if (isErrorResult(actionResult)) {\n setFetcherError(key, routeId, actionResult.error);\n return;\n }\n if (isDeferredResult(actionResult)) {\n throw getInternalRouterError(400, {\n type: \"defer-action\"\n });\n }\n // Start the data load for current matches, or the next location if we're\n // in the middle of a navigation\n let nextLocation = state.navigation.location || state.location;\n let revalidationRequest = createClientSideRequest(init.history, nextLocation, abortController.signal);\n let routesToUse = inFlightDataRoutes || dataRoutes;\n let matches = state.navigation.state !== \"idle\" ? matchRoutes(routesToUse, state.navigation.location, basename) : state.matches;\n invariant(matches, \"Didn't find any matches after fetcher action\");\n let loadId = ++incrementingLoadId;\n fetchReloadIds.set(key, loadId);\n let loadFetcher = getLoadingFetcher(submission, actionResult.data);\n state.fetchers.set(key, loadFetcher);\n let [matchesToLoad, revalidatingFetchers] = getMatchesToLoad(init.history, state, matches, submission, nextLocation, isRevalidationRequired, cancelledDeferredRoutes, cancelledFetcherLoads, fetchLoadMatches, fetchRedirectIds, routesToUse, basename, {\n [match.route.id]: actionResult.data\n }, undefined // No need to send through errors since we short circuit above\n );\n // Put all revalidating fetchers into the loading state, except for the\n // current fetcher which we want to keep in it's current loading state which\n // contains it's action submission info + action data\n revalidatingFetchers.filter(rf => rf.key !== key).forEach(rf => {\n let staleKey = rf.key;\n let existingFetcher = state.fetchers.get(staleKey);\n let revalidatingFetcher = getLoadingFetcher(undefined, existingFetcher ? existingFetcher.data : undefined);\n state.fetchers.set(staleKey, revalidatingFetcher);\n if (fetchControllers.has(staleKey)) {\n abortFetcher(staleKey);\n }\n if (rf.controller) {\n fetchControllers.set(staleKey, rf.controller);\n }\n });\n updateState({\n fetchers: new Map(state.fetchers)\n });\n let abortPendingFetchRevalidations = () => revalidatingFetchers.forEach(rf => abortFetcher(rf.key));\n abortController.signal.addEventListener(\"abort\", abortPendingFetchRevalidations);\n let {\n results,\n loaderResults,\n fetcherResults\n } = await callLoadersAndMaybeResolveData(state.matches, matches, matchesToLoad, revalidatingFetchers, revalidationRequest);\n if (abortController.signal.aborted) {\n return;\n }\n abortController.signal.removeEventListener(\"abort\", abortPendingFetchRevalidations);\n fetchReloadIds.delete(key);\n fetchControllers.delete(key);\n revalidatingFetchers.forEach(r => fetchControllers.delete(r.key));\n let redirect = findRedirect(results);\n if (redirect) {\n if (redirect.idx >= matchesToLoad.length) {\n // If this redirect came from a fetcher make sure we mark it in\n // fetchRedirectIds so it doesn't get revalidated on the next set of\n // loader executions\n let fetcherKey = revalidatingFetchers[redirect.idx - matchesToLoad.length].key;\n fetchRedirectIds.add(fetcherKey);\n }\n return startRedirectNavigation(state, redirect.result);\n }\n // Process and commit output from loaders\n let {\n loaderData,\n errors\n } = processLoaderData(state, state.matches, matchesToLoad, loaderResults, undefined, revalidatingFetchers, fetcherResults, activeDeferreds);\n // Since we let revalidations complete even if the submitting fetcher was\n // deleted, only put it back to idle if it hasn't been deleted\n if (state.fetchers.has(key)) {\n let doneFetcher = getDoneFetcher(actionResult.data);\n state.fetchers.set(key, doneFetcher);\n }\n let didAbortFetchLoads = abortStaleFetchLoads(loadId);\n // If we are currently in a navigation loading state and this fetcher is\n // more recent than the navigation, we want the newer data so abort the\n // navigation and complete it with the fetcher data\n if (state.navigation.state === \"loading\" && loadId > pendingNavigationLoadId) {\n invariant(pendingAction, \"Expected pending action\");\n pendingNavigationController && pendingNavigationController.abort();\n completeNavigation(state.navigation.location, {\n matches,\n loaderData,\n errors,\n fetchers: new Map(state.fetchers)\n });\n } else {\n // otherwise just update with the fetcher data, preserving any existing\n // loaderData for loaders that did not need to reload. We have to\n // manually merge here since we aren't going through completeNavigation\n updateState(_extends({\n errors,\n loaderData: mergeLoaderData(state.loaderData, loaderData, matches, errors)\n }, didAbortFetchLoads || revalidatingFetchers.length > 0 ? {\n fetchers: new Map(state.fetchers)\n } : {}));\n isRevalidationRequired = false;\n }\n }\n // Call the matched loader for fetcher.load(), handling redirects, errors, etc.\n async function handleFetcherLoader(key, routeId, path, match, matches, submission) {\n let existingFetcher = state.fetchers.get(key);\n // Put this fetcher into it's loading state\n let loadingFetcher = getLoadingFetcher(submission, existingFetcher ? existingFetcher.data : undefined);\n state.fetchers.set(key, loadingFetcher);\n updateState({\n fetchers: new Map(state.fetchers)\n });\n // Call the loader for this fetcher route match\n let abortController = new AbortController();\n let fetchRequest = createClientSideRequest(init.history, path, abortController.signal);\n fetchControllers.set(key, abortController);\n let originatingLoadId = incrementingLoadId;\n let result = await callLoaderOrAction(\"loader\", fetchRequest, match, matches, manifest, mapRouteProperties, basename);\n // Deferred isn't supported for fetcher loads, await everything and treat it\n // as a normal load. resolveDeferredData will return undefined if this\n // fetcher gets aborted, so we just leave result untouched and short circuit\n // below if that happens\n if (isDeferredResult(result)) {\n result = (await resolveDeferredData(result, fetchRequest.signal, true)) || result;\n }\n // We can delete this so long as we weren't aborted by our our own fetcher\n // re-load which would have put _new_ controller is in fetchControllers\n if (fetchControllers.get(key) === abortController) {\n fetchControllers.delete(key);\n }\n if (fetchRequest.signal.aborted) {\n return;\n }\n // If the loader threw a redirect Response, start a new REPLACE navigation\n if (isRedirectResult(result)) {\n if (pendingNavigationLoadId > originatingLoadId) {\n // A new navigation was kicked off after our loader started, so that\n // should take precedence over this redirect navigation\n let doneFetcher = getDoneFetcher(undefined);\n state.fetchers.set(key, doneFetcher);\n updateState({\n fetchers: new Map(state.fetchers)\n });\n return;\n } else {\n fetchRedirectIds.add(key);\n await startRedirectNavigation(state, result);\n return;\n }\n }\n // Process any non-redirect errors thrown\n if (isErrorResult(result)) {\n let boundaryMatch = findNearestBoundary(state.matches, routeId);\n state.fetchers.delete(key);\n // TODO: In remix, this would reset to IDLE_NAVIGATION if it was a catch -\n // do we need to behave any differently with our non-redirect errors?\n // What if it was a non-redirect Response?\n updateState({\n fetchers: new Map(state.fetchers),\n errors: {\n [boundaryMatch.route.id]: result.error\n }\n });\n return;\n }\n invariant(!isDeferredResult(result), \"Unhandled fetcher deferred data\");\n // Put the fetcher back into an idle state\n let doneFetcher = getDoneFetcher(result.data);\n state.fetchers.set(key, doneFetcher);\n updateState({\n fetchers: new Map(state.fetchers)\n });\n }\n /**\n * Utility function to handle redirects returned from an action or loader.\n * Normally, a redirect \"replaces\" the navigation that triggered it. So, for\n * example:\n *\n * - user is on /a\n * - user clicks a link to /b\n * - loader for /b redirects to /c\n *\n * In a non-JS app the browser would track the in-flight navigation to /b and\n * then replace it with /c when it encountered the redirect response. In\n * the end it would only ever update the URL bar with /c.\n *\n * In client-side routing using pushState/replaceState, we aim to emulate\n * this behavior and we also do not update history until the end of the\n * navigation (including processed redirects). This means that we never\n * actually touch history until we've processed redirects, so we just use\n * the history action from the original navigation (PUSH or REPLACE).\n */\n async function startRedirectNavigation(state, redirect, _temp) {\n let {\n submission,\n replace,\n isFetchActionRedirect\n } = _temp === void 0 ? {} : _temp;\n if (redirect.revalidate) {\n isRevalidationRequired = true;\n }\n let redirectLocation = createLocation(state.location, redirect.location, // TODO: This can be removed once we get rid of useTransition in Remix v2\n _extends({\n _isRedirect: true\n }, isFetchActionRedirect ? {\n _isFetchActionRedirect: true\n } : {}));\n invariant(redirectLocation, \"Expected a location on the redirect navigation\");\n if (isBrowser) {\n let isDocumentReload = false;\n if (redirect.reloadDocument) {\n // Hard reload if the response contained X-Remix-Reload-Document\n isDocumentReload = true;\n } else if (ABSOLUTE_URL_REGEX.test(redirect.location)) {\n const url = init.history.createURL(redirect.location);\n isDocumentReload =\n // Hard reload if it's an absolute URL to a new origin\n url.origin !== routerWindow.location.origin ||\n // Hard reload if it's an absolute URL that does not match our basename\n stripBasename(url.pathname, basename) == null;\n }\n if (isDocumentReload) {\n if (replace) {\n routerWindow.location.replace(redirect.location);\n } else {\n routerWindow.location.assign(redirect.location);\n }\n return;\n }\n }\n // There's no need to abort on redirects, since we don't detect the\n // redirect until the action/loaders have settled\n pendingNavigationController = null;\n let redirectHistoryAction = replace === true ? Action.Replace : Action.Push;\n // Use the incoming submission if provided, fallback on the active one in\n // state.navigation\n let activeSubmission = submission || getSubmissionFromNavigation(state.navigation);\n // If this was a 307/308 submission we want to preserve the HTTP method and\n // re-submit the GET/POST/PUT/PATCH/DELETE as a submission navigation to the\n // redirected location\n if (redirectPreserveMethodStatusCodes.has(redirect.status) && activeSubmission && isMutationMethod(activeSubmission.formMethod)) {\n await startNavigation(redirectHistoryAction, redirectLocation, {\n submission: _extends({}, activeSubmission, {\n formAction: redirect.location\n }),\n // Preserve this flag across redirects\n preventScrollReset: pendingPreventScrollReset\n });\n } else if (isFetchActionRedirect) {\n // For a fetch action redirect, we kick off a new loading navigation\n // without the fetcher submission, but we send it along for shouldRevalidate\n await startNavigation(redirectHistoryAction, redirectLocation, {\n overrideNavigation: getLoadingNavigation(redirectLocation),\n fetcherSubmission: activeSubmission,\n // Preserve this flag across redirects\n preventScrollReset: pendingPreventScrollReset\n });\n } else {\n // If we have a submission, we will preserve it through the redirect navigation\n let overrideNavigation = getLoadingNavigation(redirectLocation, activeSubmission);\n await startNavigation(redirectHistoryAction, redirectLocation, {\n overrideNavigation,\n // Preserve this flag across redirects\n preventScrollReset: pendingPreventScrollReset\n });\n }\n }\n async function callLoadersAndMaybeResolveData(currentMatches, matches, matchesToLoad, fetchersToLoad, request) {\n // Call all navigation loaders and revalidating fetcher loaders in parallel,\n // then slice off the results into separate arrays so we can handle them\n // accordingly\n let results = await Promise.all([...matchesToLoad.map(match => callLoaderOrAction(\"loader\", request, match, matches, manifest, mapRouteProperties, basename)), ...fetchersToLoad.map(f => {\n if (f.matches && f.match && f.controller) {\n return callLoaderOrAction(\"loader\", createClientSideRequest(init.history, f.path, f.controller.signal), f.match, f.matches, manifest, mapRouteProperties, basename);\n } else {\n let error = {\n type: ResultType.error,\n error: getInternalRouterError(404, {\n pathname: f.path\n })\n };\n return error;\n }\n })]);\n let loaderResults = results.slice(0, matchesToLoad.length);\n let fetcherResults = results.slice(matchesToLoad.length);\n await Promise.all([resolveDeferredResults(currentMatches, matchesToLoad, loaderResults, loaderResults.map(() => request.signal), false, state.loaderData), resolveDeferredResults(currentMatches, fetchersToLoad.map(f => f.match), fetcherResults, fetchersToLoad.map(f => f.controller ? f.controller.signal : null), true)]);\n return {\n results,\n loaderResults,\n fetcherResults\n };\n }\n function interruptActiveLoads() {\n // Every interruption triggers a revalidation\n isRevalidationRequired = true;\n // Cancel pending route-level deferreds and mark cancelled routes for\n // revalidation\n cancelledDeferredRoutes.push(...cancelActiveDeferreds());\n // Abort in-flight fetcher loads\n fetchLoadMatches.forEach((_, key) => {\n if (fetchControllers.has(key)) {\n cancelledFetcherLoads.push(key);\n abortFetcher(key);\n }\n });\n }\n function setFetcherError(key, routeId, error) {\n let boundaryMatch = findNearestBoundary(state.matches, routeId);\n deleteFetcher(key);\n updateState({\n errors: {\n [boundaryMatch.route.id]: error\n },\n fetchers: new Map(state.fetchers)\n });\n }\n function deleteFetcher(key) {\n let fetcher = state.fetchers.get(key);\n // Don't abort the controller if this is a deletion of a fetcher.submit()\n // in it's loading phase since - we don't want to abort the corresponding\n // revalidation and want them to complete and land\n if (fetchControllers.has(key) && !(fetcher && fetcher.state === \"loading\" && fetchReloadIds.has(key))) {\n abortFetcher(key);\n }\n fetchLoadMatches.delete(key);\n fetchReloadIds.delete(key);\n fetchRedirectIds.delete(key);\n state.fetchers.delete(key);\n }\n function abortFetcher(key) {\n let controller = fetchControllers.get(key);\n invariant(controller, \"Expected fetch controller: \" + key);\n controller.abort();\n fetchControllers.delete(key);\n }\n function markFetchersDone(keys) {\n for (let key of keys) {\n let fetcher = getFetcher(key);\n let doneFetcher = getDoneFetcher(fetcher.data);\n state.fetchers.set(key, doneFetcher);\n }\n }\n function markFetchRedirectsDone() {\n let doneKeys = [];\n let updatedFetchers = false;\n for (let key of fetchRedirectIds) {\n let fetcher = state.fetchers.get(key);\n invariant(fetcher, \"Expected fetcher: \" + key);\n if (fetcher.state === \"loading\") {\n fetchRedirectIds.delete(key);\n doneKeys.push(key);\n updatedFetchers = true;\n }\n }\n markFetchersDone(doneKeys);\n return updatedFetchers;\n }\n function abortStaleFetchLoads(landedId) {\n let yeetedKeys = [];\n for (let [key, id] of fetchReloadIds) {\n if (id < landedId) {\n let fetcher = state.fetchers.get(key);\n invariant(fetcher, \"Expected fetcher: \" + key);\n if (fetcher.state === \"loading\") {\n abortFetcher(key);\n fetchReloadIds.delete(key);\n yeetedKeys.push(key);\n }\n }\n }\n markFetchersDone(yeetedKeys);\n return yeetedKeys.length > 0;\n }\n function getBlocker(key, fn) {\n let blocker = state.blockers.get(key) || IDLE_BLOCKER;\n if (blockerFunctions.get(key) !== fn) {\n blockerFunctions.set(key, fn);\n }\n return blocker;\n }\n function deleteBlocker(key) {\n state.blockers.delete(key);\n blockerFunctions.delete(key);\n }\n // Utility function to update blockers, ensuring valid state transitions\n function updateBlocker(key, newBlocker) {\n let blocker = state.blockers.get(key) || IDLE_BLOCKER;\n // Poor mans state machine :)\n // https://mermaid.live/edit#pako:eNqVkc9OwzAMxl8l8nnjAYrEtDIOHEBIgwvKJTReGy3_lDpIqO27k6awMG0XcrLlnz87nwdonESogKXXBuE79rq75XZO3-yHds0RJVuv70YrPlUrCEe2HfrORS3rubqZfuhtpg5C9wk5tZ4VKcRUq88q9Z8RS0-48cE1iHJkL0ugbHuFLus9L6spZy8nX9MP2CNdomVaposqu3fGayT8T8-jJQwhepo_UtpgBQaDEUom04dZhAN1aJBDlUKJBxE1ceB2Smj0Mln-IBW5AFU2dwUiktt_2Qaq2dBfaKdEup85UV7Yd-dKjlnkabl2Pvr0DTkTreM\n invariant(blocker.state === \"unblocked\" && newBlocker.state === \"blocked\" || blocker.state === \"blocked\" && newBlocker.state === \"blocked\" || blocker.state === \"blocked\" && newBlocker.state === \"proceeding\" || blocker.state === \"blocked\" && newBlocker.state === \"unblocked\" || blocker.state === \"proceeding\" && newBlocker.state === \"unblocked\", \"Invalid blocker state transition: \" + blocker.state + \" -> \" + newBlocker.state);\n let blockers = new Map(state.blockers);\n blockers.set(key, newBlocker);\n updateState({\n blockers\n });\n }\n function shouldBlockNavigation(_ref2) {\n let {\n currentLocation,\n nextLocation,\n historyAction\n } = _ref2;\n if (blockerFunctions.size === 0) {\n return;\n }\n // We ony support a single active blocker at the moment since we don't have\n // any compelling use cases for multi-blocker yet\n if (blockerFunctions.size > 1) {\n warning(false, \"A router only supports one blocker at a time\");\n }\n let entries = Array.from(blockerFunctions.entries());\n let [blockerKey, blockerFunction] = entries[entries.length - 1];\n let blocker = state.blockers.get(blockerKey);\n if (blocker && blocker.state === \"proceeding\") {\n // If the blocker is currently proceeding, we don't need to re-check\n // it and can let this navigation continue\n return;\n }\n // At this point, we know we're unblocked/blocked so we need to check the\n // user-provided blocker function\n if (blockerFunction({\n currentLocation,\n nextLocation,\n historyAction\n })) {\n return blockerKey;\n }\n }\n function cancelActiveDeferreds(predicate) {\n let cancelledRouteIds = [];\n activeDeferreds.forEach((dfd, routeId) => {\n if (!predicate || predicate(routeId)) {\n // Cancel the deferred - but do not remove from activeDeferreds here -\n // we rely on the subscribers to do that so our tests can assert proper\n // cleanup via _internalActiveDeferreds\n dfd.cancel();\n cancelledRouteIds.push(routeId);\n activeDeferreds.delete(routeId);\n }\n });\n return cancelledRouteIds;\n }\n // Opt in to capturing and reporting scroll positions during navigations,\n // used by the component\n function enableScrollRestoration(positions, getPosition, getKey) {\n savedScrollPositions = positions;\n getScrollPosition = getPosition;\n getScrollRestorationKey = getKey || null;\n // Perform initial hydration scroll restoration, since we miss the boat on\n // the initial updateState() because we've not yet rendered \n // and therefore have no savedScrollPositions available\n if (!initialScrollRestored && state.navigation === IDLE_NAVIGATION) {\n initialScrollRestored = true;\n let y = getSavedScrollPosition(state.location, state.matches);\n if (y != null) {\n updateState({\n restoreScrollPosition: y\n });\n }\n }\n return () => {\n savedScrollPositions = null;\n getScrollPosition = null;\n getScrollRestorationKey = null;\n };\n }\n function getScrollKey(location, matches) {\n if (getScrollRestorationKey) {\n let key = getScrollRestorationKey(location, matches.map(m => createUseMatchesMatch(m, state.loaderData)));\n return key || location.key;\n }\n return location.key;\n }\n function saveScrollPosition(location, matches) {\n if (savedScrollPositions && getScrollPosition) {\n let key = getScrollKey(location, matches);\n savedScrollPositions[key] = getScrollPosition();\n }\n }\n function getSavedScrollPosition(location, matches) {\n if (savedScrollPositions) {\n let key = getScrollKey(location, matches);\n let y = savedScrollPositions[key];\n if (typeof y === \"number\") {\n return y;\n }\n }\n return null;\n }\n function _internalSetRoutes(newRoutes) {\n manifest = {};\n inFlightDataRoutes = convertRoutesToDataRoutes(newRoutes, mapRouteProperties, undefined, manifest);\n }\n router = {\n get basename() {\n return basename;\n },\n get state() {\n return state;\n },\n get routes() {\n return dataRoutes;\n },\n initialize,\n subscribe,\n enableScrollRestoration,\n navigate,\n fetch,\n revalidate,\n // Passthrough to history-aware createHref used by useHref so we get proper\n // hash-aware URLs in DOM paths\n createHref: to => init.history.createHref(to),\n encodeLocation: to => init.history.encodeLocation(to),\n getFetcher,\n deleteFetcher,\n dispose,\n getBlocker,\n deleteBlocker,\n _internalFetchControllers: fetchControllers,\n _internalActiveDeferreds: activeDeferreds,\n // TODO: Remove setRoutes, it's temporary to avoid dealing with\n // updating the tree while validating the update algorithm.\n _internalSetRoutes\n };\n return router;\n}\n//#endregion\n////////////////////////////////////////////////////////////////////////////////\n//#region createStaticHandler\n////////////////////////////////////////////////////////////////////////////////\nconst UNSAFE_DEFERRED_SYMBOL = Symbol(\"deferred\");\nfunction createStaticHandler(routes, opts) {\n invariant(routes.length > 0, \"You must provide a non-empty routes array to createStaticHandler\");\n let manifest = {};\n let basename = (opts ? opts.basename : null) || \"/\";\n let mapRouteProperties;\n if (opts != null && opts.mapRouteProperties) {\n mapRouteProperties = opts.mapRouteProperties;\n } else if (opts != null && opts.detectErrorBoundary) {\n // If they are still using the deprecated version, wrap it with the new API\n let detectErrorBoundary = opts.detectErrorBoundary;\n mapRouteProperties = route => ({\n hasErrorBoundary: detectErrorBoundary(route)\n });\n } else {\n mapRouteProperties = defaultMapRouteProperties;\n }\n let dataRoutes = convertRoutesToDataRoutes(routes, mapRouteProperties, undefined, manifest);\n /**\n * The query() method is intended for document requests, in which we want to\n * call an optional action and potentially multiple loaders for all nested\n * routes. It returns a StaticHandlerContext object, which is very similar\n * to the router state (location, loaderData, actionData, errors, etc.) and\n * also adds SSR-specific information such as the statusCode and headers\n * from action/loaders Responses.\n *\n * It _should_ never throw and should report all errors through the\n * returned context.errors object, properly associating errors to their error\n * boundary. Additionally, it tracks _deepestRenderedBoundaryId which can be\n * used to emulate React error boundaries during SSr by performing a second\n * pass only down to the boundaryId.\n *\n * The one exception where we do not return a StaticHandlerContext is when a\n * redirect response is returned or thrown from any action/loader. We\n * propagate that out and return the raw Response so the HTTP server can\n * return it directly.\n */\n async function query(request, _temp2) {\n let {\n requestContext\n } = _temp2 === void 0 ? {} : _temp2;\n let url = new URL(request.url);\n let method = request.method;\n let location = createLocation(\"\", createPath(url), null, \"default\");\n let matches = matchRoutes(dataRoutes, location, basename);\n // SSR supports HEAD requests while SPA doesn't\n if (!isValidMethod(method) && method !== \"HEAD\") {\n let error = getInternalRouterError(405, {\n method\n });\n let {\n matches: methodNotAllowedMatches,\n route\n } = getShortCircuitMatches(dataRoutes);\n return {\n basename,\n location,\n matches: methodNotAllowedMatches,\n loaderData: {},\n actionData: null,\n errors: {\n [route.id]: error\n },\n statusCode: error.status,\n loaderHeaders: {},\n actionHeaders: {},\n activeDeferreds: null\n };\n } else if (!matches) {\n let error = getInternalRouterError(404, {\n pathname: location.pathname\n });\n let {\n matches: notFoundMatches,\n route\n } = getShortCircuitMatches(dataRoutes);\n return {\n basename,\n location,\n matches: notFoundMatches,\n loaderData: {},\n actionData: null,\n errors: {\n [route.id]: error\n },\n statusCode: error.status,\n loaderHeaders: {},\n actionHeaders: {},\n activeDeferreds: null\n };\n }\n let result = await queryImpl(request, location, matches, requestContext);\n if (isResponse(result)) {\n return result;\n }\n // When returning StaticHandlerContext, we patch back in the location here\n // since we need it for React Context. But this helps keep our submit and\n // loadRouteData operating on a Request instead of a Location\n return _extends({\n location,\n basename\n }, result);\n }\n /**\n * The queryRoute() method is intended for targeted route requests, either\n * for fetch ?_data requests or resource route requests. In this case, we\n * are only ever calling a single action or loader, and we are returning the\n * returned value directly. In most cases, this will be a Response returned\n * from the action/loader, but it may be a primitive or other value as well -\n * and in such cases the calling context should handle that accordingly.\n *\n * We do respect the throw/return differentiation, so if an action/loader\n * throws, then this method will throw the value. This is important so we\n * can do proper boundary identification in Remix where a thrown Response\n * must go to the Catch Boundary but a returned Response is happy-path.\n *\n * One thing to note is that any Router-initiated Errors that make sense\n * to associate with a status code will be thrown as an ErrorResponse\n * instance which include the raw Error, such that the calling context can\n * serialize the error as they see fit while including the proper response\n * code. Examples here are 404 and 405 errors that occur prior to reaching\n * any user-defined loaders.\n */\n async function queryRoute(request, _temp3) {\n let {\n routeId,\n requestContext\n } = _temp3 === void 0 ? {} : _temp3;\n let url = new URL(request.url);\n let method = request.method;\n let location = createLocation(\"\", createPath(url), null, \"default\");\n let matches = matchRoutes(dataRoutes, location, basename);\n // SSR supports HEAD requests while SPA doesn't\n if (!isValidMethod(method) && method !== \"HEAD\" && method !== \"OPTIONS\") {\n throw getInternalRouterError(405, {\n method\n });\n } else if (!matches) {\n throw getInternalRouterError(404, {\n pathname: location.pathname\n });\n }\n let match = routeId ? matches.find(m => m.route.id === routeId) : getTargetMatch(matches, location);\n if (routeId && !match) {\n throw getInternalRouterError(403, {\n pathname: location.pathname,\n routeId\n });\n } else if (!match) {\n // This should never hit I don't think?\n throw getInternalRouterError(404, {\n pathname: location.pathname\n });\n }\n let result = await queryImpl(request, location, matches, requestContext, match);\n if (isResponse(result)) {\n return result;\n }\n let error = result.errors ? Object.values(result.errors)[0] : undefined;\n if (error !== undefined) {\n // If we got back result.errors, that means the loader/action threw\n // _something_ that wasn't a Response, but it's not guaranteed/required\n // to be an `instanceof Error` either, so we have to use throw here to\n // preserve the \"error\" state outside of queryImpl.\n throw error;\n }\n // Pick off the right state value to return\n if (result.actionData) {\n return Object.values(result.actionData)[0];\n }\n if (result.loaderData) {\n var _result$activeDeferre;\n let data = Object.values(result.loaderData)[0];\n if ((_result$activeDeferre = result.activeDeferreds) != null && _result$activeDeferre[match.route.id]) {\n data[UNSAFE_DEFERRED_SYMBOL] = result.activeDeferreds[match.route.id];\n }\n return data;\n }\n return undefined;\n }\n async function queryImpl(request, location, matches, requestContext, routeMatch) {\n invariant(request.signal, \"query()/queryRoute() requests must contain an AbortController signal\");\n try {\n if (isMutationMethod(request.method.toLowerCase())) {\n let result = await submit(request, matches, routeMatch || getTargetMatch(matches, location), requestContext, routeMatch != null);\n return result;\n }\n let result = await loadRouteData(request, matches, requestContext, routeMatch);\n return isResponse(result) ? result : _extends({}, result, {\n actionData: null,\n actionHeaders: {}\n });\n } catch (e) {\n // If the user threw/returned a Response in callLoaderOrAction, we throw\n // it to bail out and then return or throw here based on whether the user\n // returned or threw\n if (isQueryRouteResponse(e)) {\n if (e.type === ResultType.error) {\n throw e.response;\n }\n return e.response;\n }\n // Redirects are always returned since they don't propagate to catch\n // boundaries\n if (isRedirectResponse(e)) {\n return e;\n }\n throw e;\n }\n }\n async function submit(request, matches, actionMatch, requestContext, isRouteRequest) {\n let result;\n if (!actionMatch.route.action && !actionMatch.route.lazy) {\n let error = getInternalRouterError(405, {\n method: request.method,\n pathname: new URL(request.url).pathname,\n routeId: actionMatch.route.id\n });\n if (isRouteRequest) {\n throw error;\n }\n result = {\n type: ResultType.error,\n error\n };\n } else {\n result = await callLoaderOrAction(\"action\", request, actionMatch, matches, manifest, mapRouteProperties, basename, {\n isStaticRequest: true,\n isRouteRequest,\n requestContext\n });\n if (request.signal.aborted) {\n let method = isRouteRequest ? \"queryRoute\" : \"query\";\n throw new Error(method + \"() call aborted\");\n }\n }\n if (isRedirectResult(result)) {\n // Uhhhh - this should never happen, we should always throw these from\n // callLoaderOrAction, but the type narrowing here keeps TS happy and we\n // can get back on the \"throw all redirect responses\" train here should\n // this ever happen :/\n throw new Response(null, {\n status: result.status,\n headers: {\n Location: result.location\n }\n });\n }\n if (isDeferredResult(result)) {\n let error = getInternalRouterError(400, {\n type: \"defer-action\"\n });\n if (isRouteRequest) {\n throw error;\n }\n result = {\n type: ResultType.error,\n error\n };\n }\n if (isRouteRequest) {\n // Note: This should only be non-Response values if we get here, since\n // isRouteRequest should throw any Response received in callLoaderOrAction\n if (isErrorResult(result)) {\n throw result.error;\n }\n return {\n matches: [actionMatch],\n loaderData: {},\n actionData: {\n [actionMatch.route.id]: result.data\n },\n errors: null,\n // Note: statusCode + headers are unused here since queryRoute will\n // return the raw Response or value\n statusCode: 200,\n loaderHeaders: {},\n actionHeaders: {},\n activeDeferreds: null\n };\n }\n if (isErrorResult(result)) {\n // Store off the pending error - we use it to determine which loaders\n // to call and will commit it when we complete the navigation\n let boundaryMatch = findNearestBoundary(matches, actionMatch.route.id);\n let context = await loadRouteData(request, matches, requestContext, undefined, {\n [boundaryMatch.route.id]: result.error\n });\n // action status codes take precedence over loader status codes\n return _extends({}, context, {\n statusCode: isRouteErrorResponse(result.error) ? result.error.status : 500,\n actionData: null,\n actionHeaders: _extends({}, result.headers ? {\n [actionMatch.route.id]: result.headers\n } : {})\n });\n }\n // Create a GET request for the loaders\n let loaderRequest = new Request(request.url, {\n headers: request.headers,\n redirect: request.redirect,\n signal: request.signal\n });\n let context = await loadRouteData(loaderRequest, matches, requestContext);\n return _extends({}, context, result.statusCode ? {\n statusCode: result.statusCode\n } : {}, {\n actionData: {\n [actionMatch.route.id]: result.data\n },\n actionHeaders: _extends({}, result.headers ? {\n [actionMatch.route.id]: result.headers\n } : {})\n });\n }\n async function loadRouteData(request, matches, requestContext, routeMatch, pendingActionError) {\n let isRouteRequest = routeMatch != null;\n // Short circuit if we have no loaders to run (queryRoute())\n if (isRouteRequest && !(routeMatch != null && routeMatch.route.loader) && !(routeMatch != null && routeMatch.route.lazy)) {\n throw getInternalRouterError(400, {\n method: request.method,\n pathname: new URL(request.url).pathname,\n routeId: routeMatch == null ? void 0 : routeMatch.route.id\n });\n }\n let requestMatches = routeMatch ? [routeMatch] : getLoaderMatchesUntilBoundary(matches, Object.keys(pendingActionError || {})[0]);\n let matchesToLoad = requestMatches.filter(m => m.route.loader || m.route.lazy);\n // Short circuit if we have no loaders to run (query())\n if (matchesToLoad.length === 0) {\n return {\n matches,\n // Add a null for all matched routes for proper revalidation on the client\n loaderData: matches.reduce((acc, m) => Object.assign(acc, {\n [m.route.id]: null\n }), {}),\n errors: pendingActionError || null,\n statusCode: 200,\n loaderHeaders: {},\n activeDeferreds: null\n };\n }\n let results = await Promise.all([...matchesToLoad.map(match => callLoaderOrAction(\"loader\", request, match, matches, manifest, mapRouteProperties, basename, {\n isStaticRequest: true,\n isRouteRequest,\n requestContext\n }))]);\n if (request.signal.aborted) {\n let method = isRouteRequest ? \"queryRoute\" : \"query\";\n throw new Error(method + \"() call aborted\");\n }\n // Process and commit output from loaders\n let activeDeferreds = new Map();\n let context = processRouteLoaderData(matches, matchesToLoad, results, pendingActionError, activeDeferreds);\n // Add a null for any non-loader matches for proper revalidation on the client\n let executedLoaders = new Set(matchesToLoad.map(match => match.route.id));\n matches.forEach(match => {\n if (!executedLoaders.has(match.route.id)) {\n context.loaderData[match.route.id] = null;\n }\n });\n return _extends({}, context, {\n matches,\n activeDeferreds: activeDeferreds.size > 0 ? Object.fromEntries(activeDeferreds.entries()) : null\n });\n }\n return {\n dataRoutes,\n query,\n queryRoute\n };\n}\n//#endregion\n////////////////////////////////////////////////////////////////////////////////\n//#region Helpers\n////////////////////////////////////////////////////////////////////////////////\n/**\n * Given an existing StaticHandlerContext and an error thrown at render time,\n * provide an updated StaticHandlerContext suitable for a second SSR render\n */\nfunction getStaticContextFromError(routes, context, error) {\n let newContext = _extends({}, context, {\n statusCode: 500,\n errors: {\n [context._deepestRenderedBoundaryId || routes[0].id]: error\n }\n });\n return newContext;\n}\nfunction isSubmissionNavigation(opts) {\n return opts != null && (\"formData\" in opts && opts.formData != null || \"body\" in opts && opts.body !== undefined);\n}\nfunction normalizeTo(location, matches, basename, prependBasename, to, fromRouteId, relative) {\n let contextualMatches;\n let activeRouteMatch;\n if (fromRouteId != null && relative !== \"path\") {\n // Grab matches up to the calling route so our route-relative logic is\n // relative to the correct source route. When using relative:path,\n // fromRouteId is ignored since that is always relative to the current\n // location path\n contextualMatches = [];\n for (let match of matches) {\n contextualMatches.push(match);\n if (match.route.id === fromRouteId) {\n activeRouteMatch = match;\n break;\n }\n }\n } else {\n contextualMatches = matches;\n activeRouteMatch = matches[matches.length - 1];\n }\n // Resolve the relative path\n let path = resolveTo(to ? to : \".\", getPathContributingMatches(contextualMatches).map(m => m.pathnameBase), stripBasename(location.pathname, basename) || location.pathname, relative === \"path\");\n // When `to` is not specified we inherit search/hash from the current\n // location, unlike when to=\".\" and we just inherit the path.\n // See https://github.com/remix-run/remix/issues/927\n if (to == null) {\n path.search = location.search;\n path.hash = location.hash;\n }\n // Add an ?index param for matched index routes if we don't already have one\n if ((to == null || to === \"\" || to === \".\") && activeRouteMatch && activeRouteMatch.route.index && !hasNakedIndexQuery(path.search)) {\n path.search = path.search ? path.search.replace(/^\\?/, \"?index&\") : \"?index\";\n }\n // If we're operating within a basename, prepend it to the pathname. If\n // this is a root navigation, then just use the raw basename which allows\n // the basename to have full control over the presence of a trailing slash\n // on root actions\n if (prependBasename && basename !== \"/\") {\n path.pathname = path.pathname === \"/\" ? basename : joinPaths([basename, path.pathname]);\n }\n return createPath(path);\n}\n// Normalize navigation options by converting formMethod=GET formData objects to\n// URLSearchParams so they behave identically to links with query params\nfunction normalizeNavigateOptions(normalizeFormMethod, isFetcher, path, opts) {\n // Return location verbatim on non-submission navigations\n if (!opts || !isSubmissionNavigation(opts)) {\n return {\n path\n };\n }\n if (opts.formMethod && !isValidMethod(opts.formMethod)) {\n return {\n path,\n error: getInternalRouterError(405, {\n method: opts.formMethod\n })\n };\n }\n let getInvalidBodyError = () => ({\n path,\n error: getInternalRouterError(400, {\n type: \"invalid-body\"\n })\n });\n // Create a Submission on non-GET navigations\n let rawFormMethod = opts.formMethod || \"get\";\n let formMethod = normalizeFormMethod ? rawFormMethod.toUpperCase() : rawFormMethod.toLowerCase();\n let formAction = stripHashFromPath(path);\n if (opts.body !== undefined) {\n if (opts.formEncType === \"text/plain\") {\n // text only support POST/PUT/PATCH/DELETE submissions\n if (!isMutationMethod(formMethod)) {\n return getInvalidBodyError();\n }\n let text = typeof opts.body === \"string\" ? opts.body : opts.body instanceof FormData || opts.body instanceof URLSearchParams ?\n // https://html.spec.whatwg.org/multipage/form-control-infrastructure.html#plain-text-form-data\n Array.from(opts.body.entries()).reduce((acc, _ref3) => {\n let [name, value] = _ref3;\n return \"\" + acc + name + \"=\" + value + \"\\n\";\n }, \"\") : String(opts.body);\n return {\n path,\n submission: {\n formMethod,\n formAction,\n formEncType: opts.formEncType,\n formData: undefined,\n json: undefined,\n text\n }\n };\n } else if (opts.formEncType === \"application/json\") {\n // json only supports POST/PUT/PATCH/DELETE submissions\n if (!isMutationMethod(formMethod)) {\n return getInvalidBodyError();\n }\n try {\n let json = typeof opts.body === \"string\" ? JSON.parse(opts.body) : opts.body;\n return {\n path,\n submission: {\n formMethod,\n formAction,\n formEncType: opts.formEncType,\n formData: undefined,\n json,\n text: undefined\n }\n };\n } catch (e) {\n return getInvalidBodyError();\n }\n }\n }\n invariant(typeof FormData === \"function\", \"FormData is not available in this environment\");\n let searchParams;\n let formData;\n if (opts.formData) {\n searchParams = convertFormDataToSearchParams(opts.formData);\n formData = opts.formData;\n } else if (opts.body instanceof FormData) {\n searchParams = convertFormDataToSearchParams(opts.body);\n formData = opts.body;\n } else if (opts.body instanceof URLSearchParams) {\n searchParams = opts.body;\n formData = convertSearchParamsToFormData(searchParams);\n } else if (opts.body == null) {\n searchParams = new URLSearchParams();\n formData = new FormData();\n } else {\n try {\n searchParams = new URLSearchParams(opts.body);\n formData = convertSearchParamsToFormData(searchParams);\n } catch (e) {\n return getInvalidBodyError();\n }\n }\n let submission = {\n formMethod,\n formAction,\n formEncType: opts && opts.formEncType || \"application/x-www-form-urlencoded\",\n formData,\n json: undefined,\n text: undefined\n };\n if (isMutationMethod(submission.formMethod)) {\n return {\n path,\n submission\n };\n }\n // Flatten submission onto URLSearchParams for GET submissions\n let parsedPath = parsePath(path);\n // On GET navigation submissions we can drop the ?index param from the\n // resulting location since all loaders will run. But fetcher GET submissions\n // only run a single loader so we need to preserve any incoming ?index params\n if (isFetcher && parsedPath.search && hasNakedIndexQuery(parsedPath.search)) {\n searchParams.append(\"index\", \"\");\n }\n parsedPath.search = \"?\" + searchParams;\n return {\n path: createPath(parsedPath),\n submission\n };\n}\n// Filter out all routes below any caught error as they aren't going to\n// render so we don't need to load them\nfunction getLoaderMatchesUntilBoundary(matches, boundaryId) {\n let boundaryMatches = matches;\n if (boundaryId) {\n let index = matches.findIndex(m => m.route.id === boundaryId);\n if (index >= 0) {\n boundaryMatches = matches.slice(0, index);\n }\n }\n return boundaryMatches;\n}\nfunction getMatchesToLoad(history, state, matches, submission, location, isRevalidationRequired, cancelledDeferredRoutes, cancelledFetcherLoads, fetchLoadMatches, fetchRedirectIds, routesToUse, basename, pendingActionData, pendingError) {\n let actionResult = pendingError ? Object.values(pendingError)[0] : pendingActionData ? Object.values(pendingActionData)[0] : undefined;\n let currentUrl = history.createURL(state.location);\n let nextUrl = history.createURL(location);\n // Pick navigation matches that are net-new or qualify for revalidation\n let boundaryId = pendingError ? Object.keys(pendingError)[0] : undefined;\n let boundaryMatches = getLoaderMatchesUntilBoundary(matches, boundaryId);\n let navigationMatches = boundaryMatches.filter((match, index) => {\n if (match.route.lazy) {\n // We haven't loaded this route yet so we don't know if it's got a loader!\n return true;\n }\n if (match.route.loader == null) {\n return false;\n }\n // Always call the loader on new route instances and pending defer cancellations\n if (isNewLoader(state.loaderData, state.matches[index], match) || cancelledDeferredRoutes.some(id => id === match.route.id)) {\n return true;\n }\n // This is the default implementation for when we revalidate. If the route\n // provides it's own implementation, then we give them full control but\n // provide this value so they can leverage it if needed after they check\n // their own specific use cases\n let currentRouteMatch = state.matches[index];\n let nextRouteMatch = match;\n return shouldRevalidateLoader(match, _extends({\n currentUrl,\n currentParams: currentRouteMatch.params,\n nextUrl,\n nextParams: nextRouteMatch.params\n }, submission, {\n actionResult,\n defaultShouldRevalidate:\n // Forced revalidation due to submission, useRevalidator, or X-Remix-Revalidate\n isRevalidationRequired ||\n // Clicked the same link, resubmitted a GET form\n currentUrl.pathname + currentUrl.search === nextUrl.pathname + nextUrl.search ||\n // Search params affect all loaders\n currentUrl.search !== nextUrl.search || isNewRouteInstance(currentRouteMatch, nextRouteMatch)\n }));\n });\n // Pick fetcher.loads that need to be revalidated\n let revalidatingFetchers = [];\n fetchLoadMatches.forEach((f, key) => {\n // Don't revalidate if fetcher won't be present in the subsequent render\n if (!matches.some(m => m.route.id === f.routeId)) {\n return;\n }\n let fetcherMatches = matchRoutes(routesToUse, f.path, basename);\n // If the fetcher path no longer matches, push it in with null matches so\n // we can trigger a 404 in callLoadersAndMaybeResolveData. Note this is\n // currently only a use-case for Remix HMR where the route tree can change\n // at runtime and remove a route previously loaded via a fetcher\n if (!fetcherMatches) {\n revalidatingFetchers.push({\n key,\n routeId: f.routeId,\n path: f.path,\n matches: null,\n match: null,\n controller: null\n });\n return;\n }\n // Revalidating fetchers are decoupled from the route matches since they\n // load from a static href. They revalidate based on explicit revalidation\n // (submission, useRevalidator, or X-Remix-Revalidate)\n let fetcher = state.fetchers.get(key);\n let fetcherMatch = getTargetMatch(fetcherMatches, f.path);\n let shouldRevalidate = false;\n if (fetchRedirectIds.has(key)) {\n // Never trigger a revalidation of an actively redirecting fetcher\n shouldRevalidate = false;\n } else if (cancelledFetcherLoads.includes(key)) {\n // Always revalidate if the fetcher was cancelled\n shouldRevalidate = true;\n } else if (fetcher && fetcher.state !== \"idle\" && fetcher.data === undefined) {\n // If the fetcher hasn't ever completed loading yet, then this isn't a\n // revalidation, it would just be a brand new load if an explicit\n // revalidation is required\n shouldRevalidate = isRevalidationRequired;\n } else {\n // Otherwise fall back on any user-defined shouldRevalidate, defaulting\n // to explicit revalidations only\n shouldRevalidate = shouldRevalidateLoader(fetcherMatch, _extends({\n currentUrl,\n currentParams: state.matches[state.matches.length - 1].params,\n nextUrl,\n nextParams: matches[matches.length - 1].params\n }, submission, {\n actionResult,\n defaultShouldRevalidate: isRevalidationRequired\n }));\n }\n if (shouldRevalidate) {\n revalidatingFetchers.push({\n key,\n routeId: f.routeId,\n path: f.path,\n matches: fetcherMatches,\n match: fetcherMatch,\n controller: new AbortController()\n });\n }\n });\n return [navigationMatches, revalidatingFetchers];\n}\nfunction isNewLoader(currentLoaderData, currentMatch, match) {\n let isNew =\n // [a] -> [a, b]\n !currentMatch ||\n // [a, b] -> [a, c]\n match.route.id !== currentMatch.route.id;\n // Handle the case that we don't have data for a re-used route, potentially\n // from a prior error or from a cancelled pending deferred\n let isMissingData = currentLoaderData[match.route.id] === undefined;\n // Always load if this is a net-new route or we don't yet have data\n return isNew || isMissingData;\n}\nfunction isNewRouteInstance(currentMatch, match) {\n let currentPath = currentMatch.route.path;\n return (\n // param change for this match, /users/123 -> /users/456\n currentMatch.pathname !== match.pathname ||\n // splat param changed, which is not present in match.path\n // e.g. /files/images/avatar.jpg -> files/finances.xls\n currentPath != null && currentPath.endsWith(\"*\") && currentMatch.params[\"*\"] !== match.params[\"*\"]\n );\n}\nfunction shouldRevalidateLoader(loaderMatch, arg) {\n if (loaderMatch.route.shouldRevalidate) {\n let routeChoice = loaderMatch.route.shouldRevalidate(arg);\n if (typeof routeChoice === \"boolean\") {\n return routeChoice;\n }\n }\n return arg.defaultShouldRevalidate;\n}\n/**\n * Execute route.lazy() methods to lazily load route modules (loader, action,\n * shouldRevalidate) and update the routeManifest in place which shares objects\n * with dataRoutes so those get updated as well.\n */\nasync function loadLazyRouteModule(route, mapRouteProperties, manifest) {\n if (!route.lazy) {\n return;\n }\n let lazyRoute = await route.lazy();\n // If the lazy route function was executed and removed by another parallel\n // call then we can return - first lazy() to finish wins because the return\n // value of lazy is expected to be static\n if (!route.lazy) {\n return;\n }\n let routeToUpdate = manifest[route.id];\n invariant(routeToUpdate, \"No route found in manifest\");\n // Update the route in place. This should be safe because there's no way\n // we could yet be sitting on this route as we can't get there without\n // resolving lazy() first.\n //\n // This is different than the HMR \"update\" use-case where we may actively be\n // on the route being updated. The main concern boils down to \"does this\n // mutation affect any ongoing navigations or any current state.matches\n // values?\". If not, it should be safe to update in place.\n let routeUpdates = {};\n for (let lazyRouteProperty in lazyRoute) {\n let staticRouteValue = routeToUpdate[lazyRouteProperty];\n let isPropertyStaticallyDefined = staticRouteValue !== undefined &&\n // This property isn't static since it should always be updated based\n // on the route updates\n lazyRouteProperty !== \"hasErrorBoundary\";\n warning(!isPropertyStaticallyDefined, \"Route \\\"\" + routeToUpdate.id + \"\\\" has a static property \\\"\" + lazyRouteProperty + \"\\\" \" + \"defined but its lazy function is also returning a value for this property. \" + (\"The lazy route property \\\"\" + lazyRouteProperty + \"\\\" will be ignored.\"));\n if (!isPropertyStaticallyDefined && !immutableRouteKeys.has(lazyRouteProperty)) {\n routeUpdates[lazyRouteProperty] = lazyRoute[lazyRouteProperty];\n }\n }\n // Mutate the route with the provided updates. Do this first so we pass\n // the updated version to mapRouteProperties\n Object.assign(routeToUpdate, routeUpdates);\n // Mutate the `hasErrorBoundary` property on the route based on the route\n // updates and remove the `lazy` function so we don't resolve the lazy\n // route again.\n Object.assign(routeToUpdate, _extends({}, mapRouteProperties(routeToUpdate), {\n lazy: undefined\n }));\n}\nasync function callLoaderOrAction(type, request, match, matches, manifest, mapRouteProperties, basename, opts) {\n if (opts === void 0) {\n opts = {};\n }\n let resultType;\n let result;\n let onReject;\n let runHandler = handler => {\n // Setup a promise we can race against so that abort signals short circuit\n let reject;\n let abortPromise = new Promise((_, r) => reject = r);\n onReject = () => reject();\n request.signal.addEventListener(\"abort\", onReject);\n return Promise.race([handler({\n request,\n params: match.params,\n context: opts.requestContext\n }), abortPromise]);\n };\n try {\n let handler = match.route[type];\n if (match.route.lazy) {\n if (handler) {\n // Run statically defined handler in parallel with lazy()\n let values = await Promise.all([runHandler(handler), loadLazyRouteModule(match.route, mapRouteProperties, manifest)]);\n result = values[0];\n } else {\n // Load lazy route module, then run any returned handler\n await loadLazyRouteModule(match.route, mapRouteProperties, manifest);\n handler = match.route[type];\n if (handler) {\n // Handler still run even if we got interrupted to maintain consistency\n // with un-abortable behavior of handler execution on non-lazy or\n // previously-lazy-loaded routes\n result = await runHandler(handler);\n } else if (type === \"action\") {\n let url = new URL(request.url);\n let pathname = url.pathname + url.search;\n throw getInternalRouterError(405, {\n method: request.method,\n pathname,\n routeId: match.route.id\n });\n } else {\n // lazy() route has no loader to run. Short circuit here so we don't\n // hit the invariant below that errors on returning undefined.\n return {\n type: ResultType.data,\n data: undefined\n };\n }\n }\n } else if (!handler) {\n let url = new URL(request.url);\n let pathname = url.pathname + url.search;\n throw getInternalRouterError(404, {\n pathname\n });\n } else {\n result = await runHandler(handler);\n }\n invariant(result !== undefined, \"You defined \" + (type === \"action\" ? \"an action\" : \"a loader\") + \" for route \" + (\"\\\"\" + match.route.id + \"\\\" but didn't return anything from your `\" + type + \"` \") + \"function. Please return a value or `null`.\");\n } catch (e) {\n resultType = ResultType.error;\n result = e;\n } finally {\n if (onReject) {\n request.signal.removeEventListener(\"abort\", onReject);\n }\n }\n if (isResponse(result)) {\n let status = result.status;\n // Process redirects\n if (redirectStatusCodes.has(status)) {\n let location = result.headers.get(\"Location\");\n invariant(location, \"Redirects returned/thrown from loaders/actions must have a Location header\");\n // Support relative routing in internal redirects\n if (!ABSOLUTE_URL_REGEX.test(location)) {\n location = normalizeTo(new URL(request.url), matches.slice(0, matches.indexOf(match) + 1), basename, true, location);\n } else if (!opts.isStaticRequest) {\n // Strip off the protocol+origin for same-origin + same-basename absolute\n // redirects. If this is a static request, we can let it go back to the\n // browser as-is\n let currentUrl = new URL(request.url);\n let url = location.startsWith(\"//\") ? new URL(currentUrl.protocol + location) : new URL(location);\n let isSameBasename = stripBasename(url.pathname, basename) != null;\n if (url.origin === currentUrl.origin && isSameBasename) {\n location = url.pathname + url.search + url.hash;\n }\n }\n // Don't process redirects in the router during static requests requests.\n // Instead, throw the Response and let the server handle it with an HTTP\n // redirect. We also update the Location header in place in this flow so\n // basename and relative routing is taken into account\n if (opts.isStaticRequest) {\n result.headers.set(\"Location\", location);\n throw result;\n }\n return {\n type: ResultType.redirect,\n status,\n location,\n revalidate: result.headers.get(\"X-Remix-Revalidate\") !== null,\n reloadDocument: result.headers.get(\"X-Remix-Reload-Document\") !== null\n };\n }\n // For SSR single-route requests, we want to hand Responses back directly\n // without unwrapping. We do this with the QueryRouteResponse wrapper\n // interface so we can know whether it was returned or thrown\n if (opts.isRouteRequest) {\n let queryRouteResponse = {\n type: resultType === ResultType.error ? ResultType.error : ResultType.data,\n response: result\n };\n throw queryRouteResponse;\n }\n let data;\n let contentType = result.headers.get(\"Content-Type\");\n // Check between word boundaries instead of startsWith() due to the last\n // paragraph of https://httpwg.org/specs/rfc9110.html#field.content-type\n if (contentType && /\\bapplication\\/json\\b/.test(contentType)) {\n data = await result.json();\n } else {\n data = await result.text();\n }\n if (resultType === ResultType.error) {\n return {\n type: resultType,\n error: new ErrorResponse(status, result.statusText, data),\n headers: result.headers\n };\n }\n return {\n type: ResultType.data,\n data,\n statusCode: result.status,\n headers: result.headers\n };\n }\n if (resultType === ResultType.error) {\n return {\n type: resultType,\n error: result\n };\n }\n if (isDeferredData(result)) {\n var _result$init, _result$init2;\n return {\n type: ResultType.deferred,\n deferredData: result,\n statusCode: (_result$init = result.init) == null ? void 0 : _result$init.status,\n headers: ((_result$init2 = result.init) == null ? void 0 : _result$init2.headers) && new Headers(result.init.headers)\n };\n }\n return {\n type: ResultType.data,\n data: result\n };\n}\n// Utility method for creating the Request instances for loaders/actions during\n// client-side navigations and fetches. During SSR we will always have a\n// Request instance from the static handler (query/queryRoute)\nfunction createClientSideRequest(history, location, signal, submission) {\n let url = history.createURL(stripHashFromPath(location)).toString();\n let init = {\n signal\n };\n if (submission && isMutationMethod(submission.formMethod)) {\n let {\n formMethod,\n formEncType\n } = submission;\n // Didn't think we needed this but it turns out unlike other methods, patch\n // won't be properly normalized to uppercase and results in a 405 error.\n // See: https://fetch.spec.whatwg.org/#concept-method\n init.method = formMethod.toUpperCase();\n if (formEncType === \"application/json\") {\n init.headers = new Headers({\n \"Content-Type\": formEncType\n });\n init.body = JSON.stringify(submission.json);\n } else if (formEncType === \"text/plain\") {\n // Content-Type is inferred (https://fetch.spec.whatwg.org/#dom-request)\n init.body = submission.text;\n } else if (formEncType === \"application/x-www-form-urlencoded\" && submission.formData) {\n // Content-Type is inferred (https://fetch.spec.whatwg.org/#dom-request)\n init.body = convertFormDataToSearchParams(submission.formData);\n } else {\n // Content-Type is inferred (https://fetch.spec.whatwg.org/#dom-request)\n init.body = submission.formData;\n }\n }\n return new Request(url, init);\n}\nfunction convertFormDataToSearchParams(formData) {\n let searchParams = new URLSearchParams();\n for (let [key, value] of formData.entries()) {\n // https://html.spec.whatwg.org/multipage/form-control-infrastructure.html#converting-an-entry-list-to-a-list-of-name-value-pairs\n searchParams.append(key, typeof value === \"string\" ? value : value.name);\n }\n return searchParams;\n}\nfunction convertSearchParamsToFormData(searchParams) {\n let formData = new FormData();\n for (let [key, value] of searchParams.entries()) {\n formData.append(key, value);\n }\n return formData;\n}\nfunction processRouteLoaderData(matches, matchesToLoad, results, pendingError, activeDeferreds) {\n // Fill in loaderData/errors from our loaders\n let loaderData = {};\n let errors = null;\n let statusCode;\n let foundError = false;\n let loaderHeaders = {};\n // Process loader results into state.loaderData/state.errors\n results.forEach((result, index) => {\n let id = matchesToLoad[index].route.id;\n invariant(!isRedirectResult(result), \"Cannot handle redirect results in processLoaderData\");\n if (isErrorResult(result)) {\n // Look upwards from the matched route for the closest ancestor\n // error boundary, defaulting to the root match\n let boundaryMatch = findNearestBoundary(matches, id);\n let error = result.error;\n // If we have a pending action error, we report it at the highest-route\n // that throws a loader error, and then clear it out to indicate that\n // it was consumed\n if (pendingError) {\n error = Object.values(pendingError)[0];\n pendingError = undefined;\n }\n errors = errors || {};\n // Prefer higher error values if lower errors bubble to the same boundary\n if (errors[boundaryMatch.route.id] == null) {\n errors[boundaryMatch.route.id] = error;\n }\n // Clear our any prior loaderData for the throwing route\n loaderData[id] = undefined;\n // Once we find our first (highest) error, we set the status code and\n // prevent deeper status codes from overriding\n if (!foundError) {\n foundError = true;\n statusCode = isRouteErrorResponse(result.error) ? result.error.status : 500;\n }\n if (result.headers) {\n loaderHeaders[id] = result.headers;\n }\n } else {\n if (isDeferredResult(result)) {\n activeDeferreds.set(id, result.deferredData);\n loaderData[id] = result.deferredData.data;\n } else {\n loaderData[id] = result.data;\n }\n // Error status codes always override success status codes, but if all\n // loaders are successful we take the deepest status code.\n if (result.statusCode != null && result.statusCode !== 200 && !foundError) {\n statusCode = result.statusCode;\n }\n if (result.headers) {\n loaderHeaders[id] = result.headers;\n }\n }\n });\n // If we didn't consume the pending action error (i.e., all loaders\n // resolved), then consume it here. Also clear out any loaderData for the\n // throwing route\n if (pendingError) {\n errors = pendingError;\n loaderData[Object.keys(pendingError)[0]] = undefined;\n }\n return {\n loaderData,\n errors,\n statusCode: statusCode || 200,\n loaderHeaders\n };\n}\nfunction processLoaderData(state, matches, matchesToLoad, results, pendingError, revalidatingFetchers, fetcherResults, activeDeferreds) {\n let {\n loaderData,\n errors\n } = processRouteLoaderData(matches, matchesToLoad, results, pendingError, activeDeferreds);\n // Process results from our revalidating fetchers\n for (let index = 0; index < revalidatingFetchers.length; index++) {\n let {\n key,\n match,\n controller\n } = revalidatingFetchers[index];\n invariant(fetcherResults !== undefined && fetcherResults[index] !== undefined, \"Did not find corresponding fetcher result\");\n let result = fetcherResults[index];\n // Process fetcher non-redirect errors\n if (controller && controller.signal.aborted) {\n // Nothing to do for aborted fetchers\n continue;\n } else if (isErrorResult(result)) {\n let boundaryMatch = findNearestBoundary(state.matches, match == null ? void 0 : match.route.id);\n if (!(errors && errors[boundaryMatch.route.id])) {\n errors = _extends({}, errors, {\n [boundaryMatch.route.id]: result.error\n });\n }\n state.fetchers.delete(key);\n } else if (isRedirectResult(result)) {\n // Should never get here, redirects should get processed above, but we\n // keep this to type narrow to a success result in the else\n invariant(false, \"Unhandled fetcher revalidation redirect\");\n } else if (isDeferredResult(result)) {\n // Should never get here, deferred data should be awaited for fetchers\n // in resolveDeferredResults\n invariant(false, \"Unhandled fetcher deferred data\");\n } else {\n let doneFetcher = getDoneFetcher(result.data);\n state.fetchers.set(key, doneFetcher);\n }\n }\n return {\n loaderData,\n errors\n };\n}\nfunction mergeLoaderData(loaderData, newLoaderData, matches, errors) {\n let mergedLoaderData = _extends({}, newLoaderData);\n for (let match of matches) {\n let id = match.route.id;\n if (newLoaderData.hasOwnProperty(id)) {\n if (newLoaderData[id] !== undefined) {\n mergedLoaderData[id] = newLoaderData[id];\n }\n } else if (loaderData[id] !== undefined && match.route.loader) {\n // Preserve existing keys not included in newLoaderData and where a loader\n // wasn't removed by HMR\n mergedLoaderData[id] = loaderData[id];\n }\n if (errors && errors.hasOwnProperty(id)) {\n // Don't keep any loader data below the boundary\n break;\n }\n }\n return mergedLoaderData;\n}\n// Find the nearest error boundary, looking upwards from the leaf route (or the\n// route specified by routeId) for the closest ancestor error boundary,\n// defaulting to the root match\nfunction findNearestBoundary(matches, routeId) {\n let eligibleMatches = routeId ? matches.slice(0, matches.findIndex(m => m.route.id === routeId) + 1) : [...matches];\n return eligibleMatches.reverse().find(m => m.route.hasErrorBoundary === true) || matches[0];\n}\nfunction getShortCircuitMatches(routes) {\n // Prefer a root layout route if present, otherwise shim in a route object\n let route = routes.find(r => r.index || !r.path || r.path === \"/\") || {\n id: \"__shim-error-route__\"\n };\n return {\n matches: [{\n params: {},\n pathname: \"\",\n pathnameBase: \"\",\n route\n }],\n route\n };\n}\nfunction getInternalRouterError(status, _temp4) {\n let {\n pathname,\n routeId,\n method,\n type\n } = _temp4 === void 0 ? {} : _temp4;\n let statusText = \"Unknown Server Error\";\n let errorMessage = \"Unknown @remix-run/router error\";\n if (status === 400) {\n statusText = \"Bad Request\";\n if (method && pathname && routeId) {\n errorMessage = \"You made a \" + method + \" request to \\\"\" + pathname + \"\\\" but \" + (\"did not provide a `loader` for route \\\"\" + routeId + \"\\\", \") + \"so there is no way to handle the request.\";\n } else if (type === \"defer-action\") {\n errorMessage = \"defer() is not supported in actions\";\n } else if (type === \"invalid-body\") {\n errorMessage = \"Unable to encode submission body\";\n }\n } else if (status === 403) {\n statusText = \"Forbidden\";\n errorMessage = \"Route \\\"\" + routeId + \"\\\" does not match URL \\\"\" + pathname + \"\\\"\";\n } else if (status === 404) {\n statusText = \"Not Found\";\n errorMessage = \"No route matches URL \\\"\" + pathname + \"\\\"\";\n } else if (status === 405) {\n statusText = \"Method Not Allowed\";\n if (method && pathname && routeId) {\n errorMessage = \"You made a \" + method.toUpperCase() + \" request to \\\"\" + pathname + \"\\\" but \" + (\"did not provide an `action` for route \\\"\" + routeId + \"\\\", \") + \"so there is no way to handle the request.\";\n } else if (method) {\n errorMessage = \"Invalid request method \\\"\" + method.toUpperCase() + \"\\\"\";\n }\n }\n return new ErrorResponse(status || 500, statusText, new Error(errorMessage), true);\n}\n// Find any returned redirect errors, starting from the lowest match\nfunction findRedirect(results) {\n for (let i = results.length - 1; i >= 0; i--) {\n let result = results[i];\n if (isRedirectResult(result)) {\n return {\n result,\n idx: i\n };\n }\n }\n}\nfunction stripHashFromPath(path) {\n let parsedPath = typeof path === \"string\" ? parsePath(path) : path;\n return createPath(_extends({}, parsedPath, {\n hash: \"\"\n }));\n}\nfunction isHashChangeOnly(a, b) {\n if (a.pathname !== b.pathname || a.search !== b.search) {\n return false;\n }\n if (a.hash === \"\") {\n // /page -> /page#hash\n return b.hash !== \"\";\n } else if (a.hash === b.hash) {\n // /page#hash -> /page#hash\n return true;\n } else if (b.hash !== \"\") {\n // /page#hash -> /page#other\n return true;\n }\n // If the hash is removed the browser will re-perform a request to the server\n // /page#hash -> /page\n return false;\n}\nfunction isDeferredResult(result) {\n return result.type === ResultType.deferred;\n}\nfunction isErrorResult(result) {\n return result.type === ResultType.error;\n}\nfunction isRedirectResult(result) {\n return (result && result.type) === ResultType.redirect;\n}\nfunction isDeferredData(value) {\n let deferred = value;\n return deferred && typeof deferred === \"object\" && typeof deferred.data === \"object\" && typeof deferred.subscribe === \"function\" && typeof deferred.cancel === \"function\" && typeof deferred.resolveData === \"function\";\n}\nfunction isResponse(value) {\n return value != null && typeof value.status === \"number\" && typeof value.statusText === \"string\" && typeof value.headers === \"object\" && typeof value.body !== \"undefined\";\n}\nfunction isRedirectResponse(result) {\n if (!isResponse(result)) {\n return false;\n }\n let status = result.status;\n let location = result.headers.get(\"Location\");\n return status >= 300 && status <= 399 && location != null;\n}\nfunction isQueryRouteResponse(obj) {\n return obj && isResponse(obj.response) && (obj.type === ResultType.data || obj.type === ResultType.error);\n}\nfunction isValidMethod(method) {\n return validRequestMethods.has(method.toLowerCase());\n}\nfunction isMutationMethod(method) {\n return validMutationMethods.has(method.toLowerCase());\n}\nasync function resolveDeferredResults(currentMatches, matchesToLoad, results, signals, isFetcher, currentLoaderData) {\n for (let index = 0; index < results.length; index++) {\n let result = results[index];\n let match = matchesToLoad[index];\n // If we don't have a match, then we can have a deferred result to do\n // anything with. This is for revalidating fetchers where the route was\n // removed during HMR\n if (!match) {\n continue;\n }\n let currentMatch = currentMatches.find(m => m.route.id === match.route.id);\n let isRevalidatingLoader = currentMatch != null && !isNewRouteInstance(currentMatch, match) && (currentLoaderData && currentLoaderData[match.route.id]) !== undefined;\n if (isDeferredResult(result) && (isFetcher || isRevalidatingLoader)) {\n // Note: we do not have to touch activeDeferreds here since we race them\n // against the signal in resolveDeferredData and they'll get aborted\n // there if needed\n let signal = signals[index];\n invariant(signal, \"Expected an AbortSignal for revalidating fetcher deferred result\");\n await resolveDeferredData(result, signal, isFetcher).then(result => {\n if (result) {\n results[index] = result || results[index];\n }\n });\n }\n }\n}\nasync function resolveDeferredData(result, signal, unwrap) {\n if (unwrap === void 0) {\n unwrap = false;\n }\n let aborted = await result.deferredData.resolveData(signal);\n if (aborted) {\n return;\n }\n if (unwrap) {\n try {\n return {\n type: ResultType.data,\n data: result.deferredData.unwrappedData\n };\n } catch (e) {\n // Handle any TrackedPromise._error values encountered while unwrapping\n return {\n type: ResultType.error,\n error: e\n };\n }\n }\n return {\n type: ResultType.data,\n data: result.deferredData.data\n };\n}\nfunction hasNakedIndexQuery(search) {\n return new URLSearchParams(search).getAll(\"index\").some(v => v === \"\");\n}\n// Note: This should match the format exported by useMatches, so if you change\n// this please also change that :) Eventually we'll DRY this up\nfunction createUseMatchesMatch(match, loaderData) {\n let {\n route,\n pathname,\n params\n } = match;\n return {\n id: route.id,\n pathname,\n params,\n data: loaderData[route.id],\n handle: route.handle\n };\n}\nfunction getTargetMatch(matches, location) {\n let search = typeof location === \"string\" ? parsePath(location).search : location.search;\n if (matches[matches.length - 1].route.index && hasNakedIndexQuery(search || \"\")) {\n // Return the leaf index route when index is present\n return matches[matches.length - 1];\n }\n // Otherwise grab the deepest \"path contributing\" match (ignoring index and\n // pathless layout routes)\n let pathMatches = getPathContributingMatches(matches);\n return pathMatches[pathMatches.length - 1];\n}\nfunction getSubmissionFromNavigation(navigation) {\n let {\n formMethod,\n formAction,\n formEncType,\n text,\n formData,\n json\n } = navigation;\n if (!formMethod || !formAction || !formEncType) {\n return;\n }\n if (text != null) {\n return {\n formMethod,\n formAction,\n formEncType,\n formData: undefined,\n json: undefined,\n text\n };\n } else if (formData != null) {\n return {\n formMethod,\n formAction,\n formEncType,\n formData,\n json: undefined,\n text: undefined\n };\n } else if (json !== undefined) {\n return {\n formMethod,\n formAction,\n formEncType,\n formData: undefined,\n json,\n text: undefined\n };\n }\n}\nfunction getLoadingNavigation(location, submission) {\n if (submission) {\n let navigation = {\n state: \"loading\",\n location,\n formMethod: submission.formMethod,\n formAction: submission.formAction,\n formEncType: submission.formEncType,\n formData: submission.formData,\n json: submission.json,\n text: submission.text\n };\n return navigation;\n } else {\n let navigation = {\n state: \"loading\",\n location,\n formMethod: undefined,\n formAction: undefined,\n formEncType: undefined,\n formData: undefined,\n json: undefined,\n text: undefined\n };\n return navigation;\n }\n}\nfunction getSubmittingNavigation(location, submission) {\n let navigation = {\n state: \"submitting\",\n location,\n formMethod: submission.formMethod,\n formAction: submission.formAction,\n formEncType: submission.formEncType,\n formData: submission.formData,\n json: submission.json,\n text: submission.text\n };\n return navigation;\n}\nfunction getLoadingFetcher(submission, data) {\n if (submission) {\n let fetcher = {\n state: \"loading\",\n formMethod: submission.formMethod,\n formAction: submission.formAction,\n formEncType: submission.formEncType,\n formData: submission.formData,\n json: submission.json,\n text: submission.text,\n data,\n \" _hasFetcherDoneAnything \": true\n };\n return fetcher;\n } else {\n let fetcher = {\n state: \"loading\",\n formMethod: undefined,\n formAction: undefined,\n formEncType: undefined,\n formData: undefined,\n json: undefined,\n text: undefined,\n data,\n \" _hasFetcherDoneAnything \": true\n };\n return fetcher;\n }\n}\nfunction getSubmittingFetcher(submission, existingFetcher) {\n let fetcher = {\n state: \"submitting\",\n formMethod: submission.formMethod,\n formAction: submission.formAction,\n formEncType: submission.formEncType,\n formData: submission.formData,\n json: submission.json,\n text: submission.text,\n data: existingFetcher ? existingFetcher.data : undefined,\n \" _hasFetcherDoneAnything \": true\n };\n return fetcher;\n}\nfunction getDoneFetcher(data) {\n let fetcher = {\n state: \"idle\",\n formMethod: undefined,\n formAction: undefined,\n formEncType: undefined,\n formData: undefined,\n json: undefined,\n text: undefined,\n data,\n \" _hasFetcherDoneAnything \": true\n };\n return fetcher;\n}\n//#endregion\n\nexport { AbortedDeferredError, Action, ErrorResponse, IDLE_BLOCKER, IDLE_FETCHER, IDLE_NAVIGATION, UNSAFE_DEFERRED_SYMBOL, DeferredData as UNSAFE_DeferredData, convertRoutesToDataRoutes as UNSAFE_convertRoutesToDataRoutes, getPathContributingMatches as UNSAFE_getPathContributingMatches, invariant as UNSAFE_invariant, warning as UNSAFE_warning, createBrowserHistory, createHashHistory, createMemoryHistory, createPath, createRouter, createStaticHandler, defer, generatePath, getStaticContextFromError, getToPathname, isDeferredData, isRouteErrorResponse, joinPaths, json, matchPath, matchRoutes, normalizePathname, parsePath, redirect, redirectDocument, resolvePath, resolveTo, stripBasename };\n//# sourceMappingURL=router.js.map\n","var _style, _g, _g2;\nfunction _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }\nimport * as React from \"react\";\nvar SvgWidgetMultivendorX = function SvgWidgetMultivendorX(props) {\n return /*#__PURE__*/React.createElement(\"svg\", _extends({\n id: \"widget-multivendorX_svg__Layer_1\",\n xmlns: \"http://www.w3.org/2000/svg\",\n x: 0,\n y: 0,\n viewBox: \"0 0 175 42.5\",\n style: {\n enableBackground: \"new 0 0 175 42.5\"\n },\n xmlSpace: \"preserve\"\n }, props), _style || (_style = /*#__PURE__*/React.createElement(\"style\", null, \".widget-multivendorX_svg__st0{fill:#181718}.widget-multivendorX_svg__st3{fill:#f8f8fb}\")), /*#__PURE__*/React.createElement(\"g\", {\n id: \"widget-multivendorX_svg__XMLID_1_\"\n }, _g || (_g = /*#__PURE__*/React.createElement(\"g\", {\n id: \"widget-multivendorX_svg__XMLID_122_\"\n }, /*#__PURE__*/React.createElement(\"path\", {\n id: \"widget-multivendorX_svg__XMLID_147_\",\n className: \"widget-multivendorX_svg__st0\",\n d: \"m17.9 29.9-2.1-11.6L10 30.1l-.1-.1-.1.2L4 18.3 1.9 29.9H0l3-17.2h.3l6.5 13.5.1.3.1-.3 6.5-13.5h.3l3 17.2h-1.9z\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n id: \"widget-multivendorX_svg__XMLID_145_\",\n className: \"widget-multivendorX_svg__st0\",\n d: \"M32.8 17.3V30h-1.6l-.2-1.8v-.1c-1.1 1.3-2.8 2.2-4.4 2.2-2.9 0-4.5-1.7-4.5-5.7v-7.4h1.8v7.4c0 2.6.9 4.1 3.2 4.1 1.4 0 2.9-.9 3.9-2.4v-9.2h1.8z\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n id: \"widget-multivendorX_svg__XMLID_143_\",\n className: \"widget-multivendorX_svg__st0\",\n d: \"M36.3 11.9h1.8v18h-1.8v-18z\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n id: \"widget-multivendorX_svg__XMLID_141_\",\n className: \"widget-multivendorX_svg__st0\",\n d: \"M42.2 25.9v-7h-2.5v-1.6h2.4v-2.6l1.9-1.4v4h3.9v1.6H44v6.9c0 2 .9 2.9 2.3 2.9 1.1 0 2-.4 2.4-.5l-.1 1.6c-.5.2-1.3.6-2.5.6-2.6 0-3.9-1.8-3.9-4.5z\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n id: \"widget-multivendorX_svg__XMLID_138_\",\n className: \"widget-multivendorX_svg__st0\",\n d: \"M50.1 13.7c0-.7.6-1.3 1.3-1.3s1.3.5 1.3 1.3c0 .7-.6 1.2-1.3 1.2s-1.3-.5-1.3-1.2zm.5 3.6h1.8V30h-1.8V17.3z\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n id: \"widget-multivendorX_svg__XMLID_136_\",\n className: \"widget-multivendorX_svg__st0\",\n d: \"m69.5 13-7.4 17.6h-.3L54.3 13h2.1L62 26.4 67.4 13h2.1z\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n id: \"widget-multivendorX_svg__XMLID_133_\",\n className: \"widget-multivendorX_svg__st0\",\n d: \"M80.1 24.3h-9.9c.1 2.7 2.2 4.5 4.9 4.5 1.9 0 3.2-.7 4.5-1.5V29c-1 .5-2.5 1.3-4.6 1.3-3.8 0-6.4-2.9-6.4-6.9 0-3.9 2.7-6.6 6-6.6 3.5 0 5.6 2.6 5.6 5.9 0 .3 0 1.4-.1 1.6zm-1.5-1.5c.1-2.9-1.6-4.5-3.9-4.5-2.6 0-4.3 1.8-4.4 4.5h8.3z\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n id: \"widget-multivendorX_svg__XMLID_131_\",\n className: \"widget-multivendorX_svg__st0\",\n d: \"M93.2 22.5v7.4h-1.8v-7.4c0-2.6-.9-4.1-3.2-4.1-1.4 0-2.9.9-3.9 2.4V30h-1.8V17.3h1.6l.2 1.7v.1c1.1-1.3 2.8-2.2 4.4-2.2 2.9 0 4.5 1.6 4.5 5.6z\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n id: \"widget-multivendorX_svg__XMLID_128_\",\n className: \"widget-multivendorX_svg__st0\",\n d: \"M107.6 11.9v18H106l-.2-1.7v-.1c-1.1 1.3-2.4 2.2-4.2 2.2-3.3 0-6-2.7-6-6.7s2.4-6.8 5.8-6.8c1.6 0 3.2.9 4.4 2v-6.9h1.8zm-1.8 14.6v-6c-1.3-1.4-2.6-2-4-2-2.7 0-4.5 2.1-4.5 5.2s2 5.2 4.6 5.2c1.6-.1 2.8-1 3.9-2.4z\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n id: \"widget-multivendorX_svg__XMLID_125_\",\n className: \"widget-multivendorX_svg__st0\",\n d: \"M110 23.6c0-3.9 2.8-6.8 6.6-6.8s6.6 2.9 6.6 6.8-2.8 6.7-6.6 6.7c-3.7.1-6.6-2.8-6.6-6.7zm11.6 0c0-3-2.1-5.2-4.9-5.2-2.8 0-4.9 2.3-4.9 5.2 0 3 2.1 5.2 4.9 5.2 2.7 0 4.9-2.2 4.9-5.2z\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n id: \"widget-multivendorX_svg__XMLID_123_\",\n className: \"widget-multivendorX_svg__st0\",\n d: \"M132.8 18.8c-.6-.3-1.3-.4-1.9-.4-1.3 0-2.5.9-3.4 2.4v9.1h-1.8V17.3h1.5l.2 1.8c1-1.4 2.3-2.2 3.6-2.2.5 0 1.1.1 1.6.3l.2 1.6z\"\n }))), /*#__PURE__*/React.createElement(\"g\", {\n id: \"widget-multivendorX_svg__XMLID_11_\"\n }, /*#__PURE__*/React.createElement(\"g\", {\n id: \"widget-multivendorX_svg__XMLID_4_\"\n }, /*#__PURE__*/React.createElement(\"linearGradient\", {\n id: \"widget-multivendorX_svg__XMLID_6_\",\n gradientUnits: \"userSpaceOnUse\",\n x1: 144.005,\n y1: 10.33,\n x2: 186.913,\n y2: 54.03\n }, /*#__PURE__*/React.createElement(\"stop\", {\n offset: 0,\n style: {\n stopColor: \"#3a2768\"\n }\n }), /*#__PURE__*/React.createElement(\"stop\", {\n offset: 0.5,\n style: {\n stopColor: \"#9d3668\"\n }\n }), /*#__PURE__*/React.createElement(\"stop\", {\n offset: 1,\n style: {\n stopColor: \"#c6454d\"\n }\n })), /*#__PURE__*/React.createElement(\"path\", {\n id: \"widget-multivendorX_svg__XMLID_87_\",\n d: \"M171.2 9.3c-19.8 5.1-28.1-5.3-32.2 1.1-2.3 3.6.5 16.4 2.6 27.9 4.3 2.8 9.5 4.5 15 4.5 5.8 0 11.2-1.8 15.6-4.9 2.9-11.6 4.9-30.2-1-28.6z\",\n style: {\n fill: \"url(#widget-multivendorX_svg__XMLID_6_)\"\n }\n }), /*#__PURE__*/React.createElement(\"linearGradient\", {\n id: \"widget-multivendorX_svg__XMLID_7_\",\n gradientUnits: \"userSpaceOnUse\",\n x1: 152.852,\n y1: 1.644,\n x2: 195.76,\n y2: 45.344\n }, /*#__PURE__*/React.createElement(\"stop\", {\n offset: 0,\n style: {\n stopColor: \"#3a2768\"\n }\n }), /*#__PURE__*/React.createElement(\"stop\", {\n offset: 0.5,\n style: {\n stopColor: \"#9d3668\"\n }\n }), /*#__PURE__*/React.createElement(\"stop\", {\n offset: 1,\n style: {\n stopColor: \"#c6454d\"\n }\n })), /*#__PURE__*/React.createElement(\"path\", {\n id: \"widget-multivendorX_svg__XMLID_121_\",\n d: \"M158.3-.2h-2.8c-3.3 0-6 2.7-6 6v2.5c.3.1.7.2 1 .2V5.8c0-2.8 2.2-5 5-5h2.8c2.8 0 5 2.2 5 5v3.7c.3 0 .7-.1 1-.1V5.8c0-3.3-2.7-6-6-6z\",\n style: {\n fill: \"url(#widget-multivendorX_svg__XMLID_7_)\"\n }\n })), _g2 || (_g2 = /*#__PURE__*/React.createElement(\"g\", {\n id: \"widget-multivendorX_svg__XMLID_3_\"\n }, /*#__PURE__*/React.createElement(\"path\", {\n id: \"widget-multivendorX_svg__XMLID_75_\",\n className: \"widget-multivendorX_svg__st3\",\n d: \"M147.2 18.8h.6v.6h-.6z\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n id: \"widget-multivendorX_svg__XMLID_46_\",\n className: \"widget-multivendorX_svg__st3\",\n d: \"M144.4 21.5h1.4v1.4h-1.4z\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n id: \"widget-multivendorX_svg__XMLID_43_\",\n className: \"widget-multivendorX_svg__st3\",\n d: \"M145.3 20.2h.7v.7h-.7z\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n id: \"widget-multivendorX_svg__XMLID_40_\",\n className: \"widget-multivendorX_svg__st3\",\n d: \"M148.2 24h-.5v1.1h1.1V24z\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n id: \"widget-multivendorX_svg__XMLID_37_\",\n className: \"widget-multivendorX_svg__st3\",\n d: \"M149.5 21v1.4h1.5V21z\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n id: \"widget-multivendorX_svg__XMLID_33_\",\n className: \"widget-multivendorX_svg__st3\",\n d: \"M143.4 19.6h1.3v1.3h-1.3z\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n id: \"widget-multivendorX_svg__XMLID_30_\",\n className: \"widget-multivendorX_svg__st3\",\n d: \"M146.8 20h1.5v1.5h-1.5z\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n id: \"widget-multivendorX_svg__XMLID_26_\",\n className: \"widget-multivendorX_svg__st3\",\n d: \"M145.5 18.4h1v1h-1z\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n id: \"widget-multivendorX_svg__XMLID_23_\",\n className: \"widget-multivendorX_svg__st3\",\n d: \"M163.9 35.9h-2.1v-2.1h1.3l-3-3.5 9.6-11.1h-3.1c-1.4 0-2.7.6-3.6 1.6l-6 6.8-5-5.6h-.6v.8H149V22h-1.9l1.1 1.3h1.2v1.4l4.7 5.5-5.4 6.4h5.2l3.3-3.7 3.3 3.7h5.2l-1.7-2v1.3z\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n id: \"widget-multivendorX_svg__XMLID_20_\",\n className: \"widget-multivendorX_svg__st3\",\n d: \"M162.3 34.3h1.1v1.1h-1.1z\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n id: \"widget-multivendorX_svg__XMLID_17_\",\n className: \"widget-multivendorX_svg__st3\",\n d: \"M163.3 31.9h1.1V33h-1.1z\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n id: \"widget-multivendorX_svg__XMLID_12_\",\n className: \"widget-multivendorX_svg__st3\",\n d: \"M164.4 33.5h1.4v1.4h-1.4z\"\n }), /*#__PURE__*/React.createElement(\"path\", {\n id: \"widget-multivendorX_svg__XMLID_5_\",\n className: \"widget-multivendorX_svg__st3\",\n d: \"M165.1 32.1h.7v.7h-.7z\"\n }))))));\n};\nexport { SvgWidgetMultivendorX as ReactComponent };\nexport default \"data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4NCjwhLS0gR2VuZXJhdG9yOiBBZG9iZSBJbGx1c3RyYXRvciAxOS4wLjAsIFNWRyBFeHBvcnQgUGx1Zy1JbiAuIFNWRyBWZXJzaW9uOiA2LjAwIEJ1aWxkIDApICAtLT4NCjxzdmcgdmVyc2lvbj0iMS4xIiBpZD0iTGF5ZXJfMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeD0iMHB4IiB5PSIwcHgiDQoJIHZpZXdCb3g9IjAgMCAxNzUgNDIuNSIgc3R5bGU9ImVuYWJsZS1iYWNrZ3JvdW5kOm5ldyAwIDAgMTc1IDQyLjU7IiB4bWw6c3BhY2U9InByZXNlcnZlIj4NCjxzdHlsZSB0eXBlPSJ0ZXh0L2NzcyI+DQoJLnN0MHtmaWxsOiMxODE3MTg7fQ0KCS5zdDF7ZmlsbDp1cmwoI1hNTElEXzZfKTt9DQoJLnN0MntmaWxsOnVybCgjWE1MSURfN18pO30NCgkuc3Qze2ZpbGw6I0Y4RjhGQjt9DQo8L3N0eWxlPg0KPGcgaWQ9IlhNTElEXzFfIj4NCgk8ZyBpZD0iWE1MSURfMTIyXyI+DQoJCTxwYXRoIGlkPSJYTUxJRF8xNDdfIiBjbGFzcz0ic3QwIiBkPSJNMTcuOSwyOS45bC0yLjEtMTEuNkwxMCwzMC4xTDkuOSwzMGwtMC4xLDAuMkw0LDE4LjNMMS45LDI5L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EuMWgtMy4xYy0xLjQsMC0yLjcsMC42LTMuNiwxLjZsLTYsNi44bC01LTUuNmgtMC42DQoJCQkJdjAuOEgxNDl2LTAuOGgtMS45bDEuMSwxLjNoMS4ydjEuNGw0LjcsNS41bC01LjQsNi40aDUuMmwzLjMtMy43bDMuMywzLjdoNS4ybC0xLjctMlYzNS45eiIvPg0KCQkJPHJlY3QgaWQ9IlhNTElEXzIwXyIgeD0iMTYyLjMiIHk9IjM0LjMiIGNsYXNzPSJzdDMiIHdpZHRoPSIxLjEiIGhlaWdodD0iMS4xIi8+DQoJCQk8cmVjdCBpZD0iWE1MSURfMTdfIiB4PSIxNjMuMyIgeT0iMzEuOSIgY2xhc3M9InN0MyIgd2lkdGg9IjEuMSIgaGVpZ2h0PSIxLjEiLz4NCgkJCTxyZWN0IGlkPSJYTUxJRF8xMl8iIHg9IjE2NC40IiB5PSIzMy41IiBjbGFzcz0ic3QzIiB3aWR0aD0iMS40IiBoZWlnaHQ9IjEuNCIvPg0KCQkJPHJlY3QgaWQ9IlhNTElEXzVfIiB4PSIxNjUuMSIgeT0iMzIuMSIgY2xhc3M9InN0MyIgd2lkdGg9IjAuNyIgaGVpZ2h0PSIwLjciLz4NCgkJPC9nPg0KCTwvZz4NCjwvZz4NCjwvc3ZnPg0K\";","import React, { useState } from 'react';\r\nimport Intro from './steps/intro';\r\nimport StoreSetup from './steps/StoreSetup';\r\nimport CommissionSetup from './steps/CommissionSetup';\r\nimport PaymentSetup from './steps/PaymentSetup';\r\nimport CapabilitySetup from './steps/CapabilitySetup';\r\nimport DummydataSetup from './steps/DummydataSetup';\r\nimport SetupReady from './steps/SetupReady';\r\nimport Logo from '../../../../assets/images/widget-multivendorX.svg'\r\n\r\nconst SetupWizard = () => {\r\n const [currentStep, setCurrentStep] = useState(0);\r\n\r\n\tconst onNext = () => {\r\n\t\tsetCurrentStep(currentStep + 1);\r\n\t}\r\n\r\n const exitWizard = () => {\r\n\t\twindow.location.href = appLocalizer.redirect_url;\r\n\t}\r\n\r\n const steps = [\r\n { component: , title: 'Introduction' },\r\n { component: , title: 'Store Setup' },\r\n { component: , title: 'Commission Setup' },\r\n { component: , title: 'Payments' },\r\n { component: , title: 'Capability' },\r\n { component: , title: 'Import Dummy Data' },\r\n { component: , title: 'Ready!' },\r\n ];\r\n\r\n return (\r\n <>\r\n

\"MultivendorX\"

\r\n
    \r\n {steps.map((step, index) =>\r\n
  1. = index ? 'active' : ''}>{step.title}
  2. \r\n )\r\n }\r\n
\r\n
{steps[currentStep].component}
\r\n {currentStep === steps.length - 1 && Return to the WordPress Dashboard}\r\n \r\n );\r\n}\r\n\r\nexport default SetupWizard;","import React from \"react\";\r\n\r\nconst WooCommerceInstaller = () => {\r\n const handleSubmit = (event) => {\r\n event.preventDefault();\r\n\r\n axios({\r\n method: \"get\",\r\n url: getApiLink('install_woocommerce'),\r\n headers: { \"X-WP-Nonce\": appLocalizer.nonce },\r\n }).then((response) =>{\r\n console.log(\"WooCommerce installed successfully:\", response.data);\r\n window.location.href = response.redirect;\r\n }).catch((error) => {\r\n console.error(\"Error installing WooCommerce:\", error.response ? error.response.data : error.message);\r\n });\r\n };\r\n\r\n return (\r\n
\r\n

MultivendorX requires WooCommerce plugin to be active!

\r\n \r\n \r\n \r\n
\r\n );\r\n}\r\n\r\nexport default WooCommerceInstaller;","import React from \"react\";\r\n\r\nconst CommissionField = (props) => {\r\n return (\r\n \r\n \r\n \r\n props.handler(event.target.value, props.type)} id={props.type} name={props.type} value={props.value} />\r\n \r\n \r\n );\r\n}\r\n\r\nexport default CommissionField;","import React, { useState, useEffect } from \"react\";\r\nimport axios from \"axios\";\r\nimport { getApiLink } from \"../../../services/apiService\";\r\n\r\nconst CapabilitySetup = (props) => {\r\n const [ capabilitySettings, setCapabilitySettings ] = useState({\r\n is_submit_product : false,\r\n is_published_product : false,\r\n is_edit_delete_published_product: false,\r\n is_submit_coupon : false,\r\n is_published_coupon : false,\r\n is_edit_delete_published_coupon : false,\r\n is_upload_files : false,\r\n });\r\n\r\n useEffect(() => {\r\n axios({\r\n method : \"get\",\r\n url : getApiLink('get_capability_setting'),\r\n headers: { \"X-WP-Nonce\": appLocalizer.nonce },\r\n }).then((response) => {\r\n const capability_settings = response.data;\r\n setCapabilitySettings(prevState => ({\r\n ...prevState,\r\n ...capability_settings,\r\n }));\r\n })\r\n .catch((error) => {\r\n console.error('Error fetching capability settings:', error);\r\n });\r\n }, []);\r\n\r\n const handleCheckboxClick = (id) => {\r\n setCapabilitySettings(prevState => ({\r\n ...prevState,\r\n [id]: !prevState[id],\r\n }));\r\n };\r\n\r\n const submitForm = (e) => {\r\n e.preventDefault();\r\n axios({\r\n method: \"post\",\r\n url: getApiLink('set_capability_setting'),\r\n headers: { \"X-WP-Nonce\": appLocalizer.nonce },\r\n data: capabilitySettings\r\n }).then((response) =>{\r\n console.log(\"Settings saved successfully:\", response.data);\r\n props.onNext();\r\n }).catch((error) => {\r\n console.error(\"Error saving settings:\", error.response ? error.response.data : error.message);\r\n });\r\n }\r\n\r\n return (\r\n <>\r\n

Capability

\r\n
 
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n
\r\n handleCheckboxClick('is_submit_product')} checked={capabilitySettings.is_submit_product} id=\"is_submit_product\" name=\"is_submit_product\" className=\"input-checkbox\" value=\"Enable\" />\r\n

Allow vendors to submit products for approval/publishing.

\r\n
\r\n handleCheckboxClick('is_published_product')} checked={capabilitySettings.is_published_product} id=\"is_published_product\" name=\"is_published_product\" className=\"input-checkbox\" value=\"Enable\" />\r\n

If checked, products uploaded by vendors will be directly published without admin approval.

\r\n
\r\n handleCheckboxClick('is_edit_delete_published_product')} checked={capabilitySettings.is_edit_delete_published_product} id=\"is_edit_delete_published_product\" name=\"is_edit_delete_published_product\" className=\"input-checkbox\" value=\"Enable\" />\r\n

Allow vendors to Edit published products.

\r\n
\r\n handleCheckboxClick('is_submit_coupon')} checked={capabilitySettings.is_submit_coupon} id=\"is_submit_coupon\" name=\"is_submit_coupon\" className=\"input-checkbox\" value=\"Enable\" />\r\n

Allow vendors to create coupons.

\r\n
\r\n handleCheckboxClick('is_published_coupon')} checked={capabilitySettings.is_published_coupon} id=\"is_published_coupon\" name=\"is_published_coupon\" className=\"input-checkbox\" value=\"Enable\" />\r\n

If checked, coupons added by vendors will be directly published without admin approval.

\r\n
\r\n handleCheckboxClick('is_edit_delete_published_coupon')} checked={capabilitySettings.is_edit_delete_published_coupon} id=\"is_edit_delete_published_coupon\" name=\"is_edit_delete_published_coupon\" className=\"input-checkbox\" value=\"Enable\" />\r\n

Allow Vendor To edit delete published shop coupons.

\r\n
\r\n handleCheckboxClick('is_upload_files')} checked={capabilitySettings.is_upload_files} id=\"is_upload_files\" name=\"is_upload_files\" className=\"input-checkbox\" value=\"Enable\" />\r\n

Allow vendors to upload media files.

\r\n
\r\n

\r\n Skip this step\r\n \r\n

\r\n
\r\n \r\n );\r\n}\r\n\r\nexport default CapabilitySetup;","import React, { useEffect, useState } from \"react\";\r\nimport CommissionField from \"../components/CommissionField\";\r\nimport { getApiLink } from \"../../../services/apiService\";\r\nimport axios from \"axios\";\r\n\r\nconst CommissionSetup = (props) => {\r\n const [ revenueSharingMode, setRevenueSharingMode ] = useState('');\r\n const [ commissionType, setCommissionType ] = useState('');\r\n const [ commission, setFixedCommission ] = useState();\r\n const [ percentCommission, setPercentCommission ] = useState();\r\n\r\n useEffect(() => {\r\n axios({\r\n method : \"get\",\r\n url : getApiLink('get_commission_setting'),\r\n headers: { \"X-WP-Nonce\": appLocalizer.nonce },\r\n }).then((response) => {\r\n const { revenue_sharing_mode, commission_type, fixed, percentage } = response.data;\r\n\r\n setRevenueSharingMode(revenue_sharing_mode);\r\n setCommissionType(commission_type)\r\n setFixedCommission(fixed)\r\n setPercentCommission(percentage);\r\n })\r\n .catch((error) => {\r\n console.error('Error fetching commission settings:', error);\r\n });\r\n }, []);\r\n\r\n const handleRevenueSharingModeChange = (e) => {\r\n setRevenueSharingMode(e.target.value);\r\n }\r\n\r\n const handleCommissionTypeChange = (e) => {\r\n setCommissionType(e.target.value);\r\n }\r\n\r\n const handleCommissionValueChange = (value, type) => {\r\n if(type === 'default_commission'){\r\n setFixedCommission(value);\r\n }else if(type === 'default_percentage'){\r\n setPercentCommission(value);\r\n }\r\n }\r\n\r\n const submitForm = (e) => {\r\n e.preventDefault();\r\n const data = {\r\n revenue_sharing_mode: revenueSharingMode,\r\n commission_type: commissionType,\r\n fixed: commission,\r\n percentage: percentCommission,\r\n };\r\n axios({\r\n method: \"post\",\r\n url: getApiLink('set_commission_setting'),\r\n headers: { \"X-WP-Nonce\": appLocalizer.nonce },\r\n data: data\r\n }).then((response) =>{\r\n console.log(\"Settings saved successfully:\", response.data);\r\n props.onNext();\r\n }).catch((error) => {\r\n console.error(\"Error saving settings:\", error.response ? error.response.data : error.message);\r\n });\r\n }\r\n\r\n const commissionFields = (type) => {\r\n switch(type){\r\n case 'fixed':\r\n return ;\r\n case 'percent':\r\n return \r\n case 'fixed_with_percentage':\r\n return (\r\n <>\r\n \r\n \r\n \r\n );\r\n case 'fixed_with_percentage_qty':\r\n return (\r\n <>\r\n \r\n \r\n \r\n );\r\n default: \r\n return null;\r\n }\r\n }\r\n\r\n return (\r\n <>\r\n

Commission Setup

\r\n
 
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n {\r\n commissionFields(commissionType)}\r\n
\r\n
\r\n \r\n
\r\n \r\n
\r\n

\r\n Skip this step\r\n \r\n

\r\n
\r\n \r\n );\r\n}\r\n\r\nexport default CommissionSetup;","import React, { useState, useEffect } from \"react\";\r\nimport { getApiLink } from \"../../../services/apiService\";\r\nimport axios from \"axios\";\r\n\r\nconst DummydataSetup = (props) => {\r\n const [ marketplaceType, setMarketplaceType ] = useState('niche');\r\n const [ isPluginActive, setIsPluginActive ] = useState({\r\n booking : false,\r\n subscription : false,\r\n rental : false,\r\n auction : false,\r\n });\r\n\r\n useEffect(() => {\r\n axios({\r\n method : \"get\",\r\n url : getApiLink('get_active_plugins'),\r\n headers: { \"X-WP-Nonce\": appLocalizer.nonce },\r\n }).then((response) => {\r\n const activePlugins = response.data;\r\n\r\n setIsPluginActive(prevState => ({\r\n ...prevState,\r\n ...activePlugins,\r\n }));\r\n })\r\n .catch((error) => {\r\n console.error('Error fetching active plugins:', error);\r\n });\r\n }, [] );\r\n\r\n const handleMarketplaceTypeChange = (e) => {\r\n setMarketplaceType(e.target.value);\r\n }\r\n\r\n const submitForm = (e) => {\r\n e.preventDefault();\r\n const data = {\r\n marketplace_type: marketplaceType,\r\n };\r\n axios({\r\n method: \"post\",\r\n url: getApiLink('import_dummy_data'),\r\n headers: { \"X-WP-Nonce\": appLocalizer.nonce },\r\n data: data\r\n }).then((response) =>{\r\n console.log(\"Data imported successfully:\", response.data);\r\n // props.onNext();\r\n }).catch((error) => {\r\n console.error(\"Error importing data:\", error.response ? error.response.data : error.message);\r\n });\r\n }\r\n\r\n return (\r\n <>\r\n

Import Dummy Data

\r\n
 
\r\n
\r\n \r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n

Dummy data will be imported based on the marketplace type.

\r\n {marketplaceType === 'booking' && !isPluginActive.booking &&

WooCommerce Bookings pulgin is required to continue.

}\r\n {marketplaceType === 'subscription' && !isPluginActive.subscription &&

WooCommerce Subscriptions pulgin is required to continue.

}\r\n {marketplaceType === 'rental' && !isPluginActive.rental &&

WooCommerce Booking & Rental pulgin is required to continue.

}\r\n {marketplaceType === 'auction' && !isPluginActive.auction &&

WooCommerce Simple Auction pulgin is required to continue.

}\r\n \r\n
\r\n

\r\n Skip this step\r\n \r\n

\r\n
\r\n \r\n );\r\n}\r\n\r\nexport default DummydataSetup;","import React, { useEffect, useState } from \"react\";\r\nimport axios from \"axios\";\r\nimport { getApiLink } from \"../../../services/apiService\";\r\n\r\nconst PaymentSetup = (props) => {\r\n const [ disbursalModeAdmin, setDisbursalModeAdmin ] = useState(false);\r\n const [ disbursalModeVendor, setDisbursalModeVendor ] = useState(false);\r\n const [ paymentSchedule, setPaymentSchedule ] = useState('');\r\n const [ mvxIsModuleActive, setMvxIsModuleActive ] = useState({\r\n paypal_masspay: false,\r\n paypal_payout: false,\r\n direct_bank: false,\r\n stripe_masspay: false,\r\n });\r\n\r\n const gateways = [\r\n {\r\n id: 'paypal_masspay',\r\n label: 'Paypal Masspay',\r\n description: 'Pay via paypal masspay',\r\n class: 'featured featured-row-last',\r\n },\r\n {\r\n id: 'paypal_payout',\r\n label: 'Paypal Payout',\r\n description: 'Pay via paypal payout',\r\n class: 'featured featured-row-first',\r\n },\r\n {\r\n id: 'direct_bank',\r\n label: 'Direct Bank Transfer',\r\n description: '',\r\n class: '',\r\n },\r\n {\r\n id: 'stripe_masspay',\r\n label: 'Stripe Connect',\r\n description: '',\r\n class: '',\r\n },\r\n ];\r\n\r\n useEffect(() => {\r\n axios({\r\n method : \"get\",\r\n url : getApiLink('get_payment_setting'),\r\n headers: { \"X-WP-Nonce\": appLocalizer.nonce },\r\n }).then((response) => {\r\n const { mvx_disbursal_mode_admin, \r\n payment_schedule, \r\n mvx_disbursal_mode_vendor, \r\n is_enable_gateway } = response.data;\r\n\r\n setDisbursalModeAdmin(mvx_disbursal_mode_admin);\r\n setDisbursalModeVendor(mvx_disbursal_mode_vendor);\r\n setPaymentSchedule(payment_schedule);\r\n setMvxIsModuleActive(is_enable_gateway);\r\n })\r\n .catch((error) => {\r\n console.error('Error fetching payment settings:', error);\r\n });\r\n }, [] );\r\n\r\n const moduleActiveChangeHandler = (id) => {\r\n setMvxIsModuleActive(prevState => ({\r\n ...prevState,\r\n [id]: !prevState[id]\r\n }));\r\n }\r\n\r\n const disbursalModeAdminChangeHandler = () => {\r\n setDisbursalModeAdmin(prevState => !prevState);\r\n }\r\n\r\n const paymentScheduleChangeHandler = (value) => {\r\n setPaymentSchedule(value);\r\n }\r\n\r\n const disbursalModeVendorChangeHandler = () => {\r\n setDisbursalModeVendor(prevState => !prevState);\r\n }\r\n\r\n const submitForm = (e) => {\r\n e.preventDefault();\r\n const data = {\r\n mvx_disbursal_mode_admin: disbursalModeAdmin,\r\n mvx_disbursal_mode_vendor: disbursalModeVendor,\r\n is_module_active: mvxIsModuleActive,\r\n payment_schedule: paymentSchedule,\r\n };\r\n axios({\r\n method: \"post\",\r\n url: getApiLink('set_payment_setting'),\r\n headers: { \"X-WP-Nonce\": appLocalizer.nonce },\r\n data: data\r\n }).then((response) =>{\r\n console.log(\"Settings saved successfully:\", response.data);\r\n props.onNext();\r\n }).catch((error) => {\r\n console.error(\"Error saving settings:\", error.response ? error.response.data : error.message);\r\n });\r\n }\r\n\r\n const gatewayFields = () => {\r\n return ( gateways.map((gateway) => {\r\n return (\r\n
  • \r\n
    \r\n \r\n
    \r\n
    \r\n {gateway.description}\r\n
    \r\n
    \r\n \r\n moduleActiveChangeHandler(gateway.id)}\r\n name={\"payment_method_\" + gateway.id} \r\n className=\"input-checkbox\" \r\n value=\"Enable\" />\r\n \r\n
    \r\n
  • \r\n );\r\n }));\r\n }\r\n\r\n return (\r\n <>\r\n

    Payments

    \r\n
     
    \r\n
    \r\n

    Allowed Payment Methods

    \r\n
      \r\n {gatewayFields()}\r\n
    \r\n \r\n \r\n \r\n \r\n \r\n {disbursalModeAdmin && \r\n \r\n \r\n }\r\n \r\n \r\n \r\n \r\n
    \r\n \r\n

    If checked, automatically vendors commission will disburse.

    \r\n
    \r\n
    \r\n
    \r\n
    \r\n
    \r\n \r\n
    \r\n \r\n

    Vendors can request for commission withdrawal.

    \r\n
    \r\n

    \r\n Skip this step\r\n \r\n

    \r\n
    \r\n \r\n );\r\n}\r\n\r\nexport default PaymentSetup;","import React, { useEffect } from \"react\";\r\n\r\nconst SetupReady = () => {\r\n const siteUrl = window.location.protocol + \"//\" + window.location.host + \"/\" + window.location.pathname.split('/')[1];\r\n\r\n useEffect(() => {\r\n if (!document.getElementById('twitter-wjs')) {\r\n const script = document.createElement('script');\r\n script.id = 'twitter-wjs';\r\n script.src = \"https://platform.twitter.com/widgets.js\";\r\n document.body.appendChild(script);\r\n }\r\n }, []);\r\n\r\n return (\r\n <>\r\n
    \r\n \r\n

    Yay! All done!

    \r\n \r\n Tweet\r\n \r\n
    \r\n \r\n
    \r\n

    Your marketplace is ready. It's time to bring some sellers on your platform and start your journey. We wish you all the success for your business, you will be great!

    \r\n
    \r\n
    \r\n
    \r\n

    Next steps

    \r\n \r\n
    \r\n \r\n
    \r\n \r\n );\r\n}\r\n\r\nexport default SetupReady;","import React, { useEffect, useState } from \"react\";\r\nimport axios, { Axios } from 'axios';\r\nimport { getApiLink } from \"../../../services/apiService\";\r\n\r\nconst StoreSetup = (props) => {\r\n const [ vendorSlug, setVendorSlug ] = useState('');\r\n const [ isSingleProductMultipleVendor, setIsSingleProductMultipleVendor ] = useState(false);\r\n const [ siteUrl, setSiteUrl ] = useState('');\r\n \r\n useEffect( () => {\r\n axios({\r\n method : \"get\",\r\n url : getApiLink('get_store'),\r\n headers: { \"X-WP-Nonce\": appLocalizer.nonce },\r\n }).then((response) => {\r\n const { vendor_slug, is_single_product_multiple_vendor, site_url } = response.data;\r\n\r\n setVendorSlug(vendor_slug);\r\n setIsSingleProductMultipleVendor(is_single_product_multiple_vendor === 'Enable');\r\n setSiteUrl(site_url);\r\n })\r\n .catch((error) => {\r\n console.error('Error fetching store settings:', error);\r\n });\r\n }, [])\r\n\r\n function handleStoreUrlChange(event){\r\n setVendorSlug(event.target.value);\r\n }\r\n\r\n function handleIsSingleProductMultipleVendorChange(event){\r\n setIsSingleProductMultipleVendor(!isSingleProductMultipleVendor);\r\n }\r\n\r\n function submitForm(e){\r\n e.preventDefault();\r\n const data = {\r\n vendor_store_url: vendorSlug,\r\n is_single_product_multiple_vendor: isSingleProductMultipleVendor,\r\n };\r\n axios({\r\n method: \"post\",\r\n url: getApiLink('set_store'),\r\n headers: { \"X-WP-Nonce\": appLocalizer.nonce },\r\n data: data\r\n }).then((response) =>{\r\n console.log(\"Settings saved successfully:\", response.data);\r\n props.onNext();\r\n }).catch((error) => {\r\n console.error(\"Error saving settings:\", error.response ? error.response.data : error.message);\r\n });\r\n }\r\n\r\n return (\r\n <>\r\n

    Store setup

    \r\n
     
    \r\n
    \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n
    \r\n \r\n

    Define vendor store URL ({siteUrl}/[this-text]/[seller-name])

    \r\n
    \r\n \r\n
    \r\n

    \r\n Skip this step\r\n \r\n

    \r\n
    \r\n \r\n );\r\n}\r\n\r\nexport default StoreSetup;","import React from \"react\";\r\n\r\nconst Intro = (props) => {\r\n return (\r\n <>\r\n

    Welcome to the MultivendorX family!

    \r\n

    Thank you for choosing MultivendorX! This quick setup wizard will help you configure the basic settings and you will have your marketplace ready in no time. It’s completely optional and shouldn’t take longer than five minutes.

    \r\n

    If you don't want to go through the wizard right now, you can skip and return to the WordPress dashboard. Come back anytime if you change your mind!

    \r\n

    \r\n Not right now\r\n Let's go!\r\n

    \r\n \r\n );\r\n}\r\n\r\nexport default Intro;","/**\n * Core API service module\n */\n\nimport axios from \"axios\";\n\n/**\n * Get response from rest api.\n * @param {String} url \n * @param {Object} headers \n */\nconst getApiResponse = async ( url, headers ) => {\n try {\n const result = await axios.get( url, headers );\n return result.data;\n } catch ( error ) {\n console.error(`Error: fetching data on url ${ url } `);\n console.error(`ErrorObject: ${ error }`);\n }\n};\n\n/**\n * Send response to rest api.\n * @param {String} url \n * @param {Object} data \n * @param {Object} headers \n */\nconst sendApiResponse = async ( url, data, headers ) => {\n try {\n const result = await axios.post(url, data, { headers });\n return result.data;\n } catch ( error ) {\n console.error(`Error: sending data on url ${ url } `);\n console.error(`ErrorObject: ${ error }`);\n }\n}\n\n/**\n * Get the rest api url from endpoint.\n * @param {String} endpoint \n * @param {String} namespace\n * @param {String} rootUrl \n * @returns \n */\nconst getApiLink = ( endpoint, namespace = null, rootUrl = null ) => {\n rootUrl = rootUrl || appLocalizer.apiUrl;\n namespace = namespace || 'mvx_module/v1';\n return `${rootUrl}/${namespace}/${endpoint}`;\n}\n\nexport { getApiResponse, sendApiResponse, getApiLink };","/**\n * React Router DOM v6.15.0\n *\n * Copyright (c) Remix Software Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE.md file in the root directory of this source tree.\n *\n * @license MIT\n */\nimport * as React from 'react';\nimport { UNSAFE_mapRouteProperties, Router, UNSAFE_NavigationContext, useHref, useResolvedPath, useLocation, UNSAFE_DataRouterStateContext, useNavigate, createPath, UNSAFE_useRouteId, UNSAFE_RouteContext, useMatches, useNavigation, unstable_useBlocker, UNSAFE_DataRouterContext } from 'react-router';\nexport { AbortedDeferredError, Await, MemoryRouter, Navigate, NavigationType, Outlet, Route, Router, RouterProvider, Routes, UNSAFE_DataRouterContext, UNSAFE_DataRouterStateContext, UNSAFE_LocationContext, UNSAFE_NavigationContext, UNSAFE_RouteContext, UNSAFE_useRouteId, createMemoryRouter, createPath, createRoutesFromChildren, createRoutesFromElements, defer, generatePath, isRouteErrorResponse, json, matchPath, matchRoutes, parsePath, redirect, redirectDocument, renderMatches, resolvePath, unstable_useBlocker, useActionData, useAsyncError, useAsyncValue, useHref, useInRouterContext, useLoaderData, useLocation, useMatch, useMatches, useNavigate, useNavigation, useNavigationType, useOutlet, useOutletContext, useParams, useResolvedPath, useRevalidator, useRouteError, useRouteLoaderData, useRoutes } from 'react-router';\nimport { stripBasename, UNSAFE_warning, createRouter, createBrowserHistory, createHashHistory, ErrorResponse, UNSAFE_invariant, joinPaths } from '@remix-run/router';\n\nfunction _extends() {\n _extends = Object.assign ? Object.assign.bind() : function (target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i];\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n target[key] = source[key];\n }\n }\n }\n return target;\n };\n return _extends.apply(this, arguments);\n}\nfunction _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n for (i = 0; i < sourceKeys.length; i++) {\n key = sourceKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n target[key] = source[key];\n }\n return target;\n}\n\nconst defaultMethod = \"get\";\nconst defaultEncType = \"application/x-www-form-urlencoded\";\nfunction isHtmlElement(object) {\n return object != null && typeof object.tagName === \"string\";\n}\nfunction isButtonElement(object) {\n return isHtmlElement(object) && object.tagName.toLowerCase() === \"button\";\n}\nfunction isFormElement(object) {\n return isHtmlElement(object) && object.tagName.toLowerCase() === \"form\";\n}\nfunction isInputElement(object) {\n return isHtmlElement(object) && object.tagName.toLowerCase() === \"input\";\n}\nfunction isModifiedEvent(event) {\n return !!(event.metaKey || event.altKey || event.ctrlKey || event.shiftKey);\n}\nfunction shouldProcessLinkClick(event, target) {\n return event.button === 0 && (\n // Ignore everything but left clicks\n !target || target === \"_self\") &&\n // Let browser handle \"target=_blank\" etc.\n !isModifiedEvent(event) // Ignore clicks with modifier keys\n ;\n}\n/**\n * Creates a URLSearchParams object using the given initializer.\n *\n * This is identical to `new URLSearchParams(init)` except it also\n * supports arrays as values in the object form of the initializer\n * instead of just strings. This is convenient when you need multiple\n * values for a given key, but don't want to use an array initializer.\n *\n * For example, instead of:\n *\n * let searchParams = new URLSearchParams([\n * ['sort', 'name'],\n * ['sort', 'price']\n * ]);\n *\n * you can do:\n *\n * let searchParams = createSearchParams({\n * sort: ['name', 'price']\n * });\n */\nfunction createSearchParams(init) {\n if (init === void 0) {\n init = \"\";\n }\n return new URLSearchParams(typeof init === \"string\" || Array.isArray(init) || init instanceof URLSearchParams ? init : Object.keys(init).reduce((memo, key) => {\n let value = init[key];\n return memo.concat(Array.isArray(value) ? value.map(v => [key, v]) : [[key, value]]);\n }, []));\n}\nfunction getSearchParamsForLocation(locationSearch, defaultSearchParams) {\n let searchParams = createSearchParams(locationSearch);\n if (defaultSearchParams) {\n // Use `defaultSearchParams.forEach(...)` here instead of iterating of\n // `defaultSearchParams.keys()` to work-around a bug in Firefox related to\n // web extensions. Relevant Bugzilla tickets:\n // https://bugzilla.mozilla.org/show_bug.cgi?id=1414602\n // https://bugzilla.mozilla.org/show_bug.cgi?id=1023984\n defaultSearchParams.forEach((_, key) => {\n if (!searchParams.has(key)) {\n defaultSearchParams.getAll(key).forEach(value => {\n searchParams.append(key, value);\n });\n }\n });\n }\n return searchParams;\n}\n// One-time check for submitter support\nlet _formDataSupportsSubmitter = null;\nfunction isFormDataSubmitterSupported() {\n if (_formDataSupportsSubmitter === null) {\n try {\n new FormData(document.createElement(\"form\"),\n // @ts-expect-error if FormData supports the submitter parameter, this will throw\n 0);\n _formDataSupportsSubmitter = false;\n } catch (e) {\n _formDataSupportsSubmitter = true;\n }\n }\n return _formDataSupportsSubmitter;\n}\nconst supportedFormEncTypes = new Set([\"application/x-www-form-urlencoded\", \"multipart/form-data\", \"text/plain\"]);\nfunction getFormEncType(encType) {\n if (encType != null && !supportedFormEncTypes.has(encType)) {\n process.env.NODE_ENV !== \"production\" ? UNSAFE_warning(false, \"\\\"\" + encType + \"\\\" is not a valid `encType` for `
    `/`` \" + (\"and will default to \\\"\" + defaultEncType + \"\\\"\")) : void 0;\n return null;\n }\n return encType;\n}\nfunction getFormSubmissionInfo(target, basename) {\n let method;\n let action;\n let encType;\n let formData;\n let body;\n if (isFormElement(target)) {\n // When grabbing the action from the element, it will have had the basename\n // prefixed to ensure non-JS scenarios work, so strip it since we'll\n // re-prefix in the router\n let attr = target.getAttribute(\"action\");\n action = attr ? stripBasename(attr, basename) : null;\n method = target.getAttribute(\"method\") || defaultMethod;\n encType = getFormEncType(target.getAttribute(\"enctype\")) || defaultEncType;\n formData = new FormData(target);\n } else if (isButtonElement(target) || isInputElement(target) && (target.type === \"submit\" || target.type === \"image\")) {\n let form = target.form;\n if (form == null) {\n throw new Error(\"Cannot submit a