diff --git a/CHANGELOG.md b/CHANGELOG.md index 32549065df0..dea5261e148 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,38 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## Releases +### [5.0.13] + +#### Fixed + - [Set Defaults and Types for EE_Gateway Properties (#989)](https://github.com/eventespresso/cafe/pull/989) + - [Fix Escaping for [ESPRESSO_MY_EVENTS] Shortcode (#975)](https://github.com/eventespresso/cafe/pull/975) + - [Fix Messages Settings Admin Toggle Switch Display (#996)](https://github.com/eventespresso/cafe/pull/996) + - [Fix Event Registrations Report CSV (#988)](https://github.com/eventespresso/cafe/pull/988) + - [Relax Property Types in EE_Template_Config (#1007)](https://github.com/eventespresso/cafe/pull/1007) + - [Fix EE_Line_Item::desc() Return Type (#1009)](https://github.com/eventespresso/cafe/pull/1009) + - [Fix Country Settings Is EU Option Not Saving (#1017)](https://github.com/eventespresso/cafe/pull/1017) + - [Fix Registration List Table View Links When Filtered by Event (#1016)](https://github.com/eventespresso/cafe/pull/1016) + - [Fix Event List Registration Links (#1014)](https://github.com/eventespresso/cafe/pull/1014) + - [Fix Session Reset Keys Data Type (#1023)](https://github.com/eventespresso/cafe/pull/1023) + - [Fix Ticket Total with Taxes (#1018)](https://github.com/eventespresso/cafe/pull/1018) + - [Fix Undefined Constant and Uninitialized Properties (#1030)](https://github.com/eventespresso/cafe/pull/1030) + - [ES. Fix missing thank you page session (#1032)](https://github.com/eventespresso/cafe/pull/1032) + - [Fix Model Path for DTT_ID in addWhereParamsForFilters() (#1039)](https://github.com/eventespresso/cafe/pull/1039) + - [Fix RSS Feeds and UI Tweaks (#1045)](https://github.com/eventespresso/cafe/pull/1045) + - [Fix fatals/deprecated notices thrown during migrations (#1063)](https://github.com/eventespresso/cafe/pull/1063) + +#### Changed + - [BM 5.0.12.p changes (#977)](https://github.com/eventespresso/cafe/pull/977) + - [Refactor How Database Table Indexes are Added (#983)](https://github.com/eventespresso/cafe/pull/983) + - [Check for Multiple @ Sign in Email Addresses (#973)](https://github.com/eventespresso/cafe/pull/973) + - [Move Venue Sorting into useVenues() Hook (Barista#1276) (#1000)](https://github.com/eventespresso/cafe/pull/1000) + - [PPC. Third party integration (#807)](https://github.com/eventespresso/cafe/pull/807) + - [Make M-Mode Changes Backwards Compatible (#979)](https://github.com/eventespresso/cafe/pull/979) + - [Dont Use Links to Close Notices (#1036)](https://github.com/eventespresso/cafe/pull/1036) + - [PPC. Fix not ACDC eligible behaviour (#1040)](https://github.com/eventespresso/cafe/pull/1040) + - [Protect Ticket Assignments Manager Layout from Other Plugin CSS (#1065)](https://github.com/eventespresso/cafe/pull/1065) + + ### [5.0.12] #### Added @@ -83,7 +115,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 #### Changed - [Build Machine 5.0.9 changes (#828)](https://github.com/eventespresso/cafe/pull/828) - - [PayPal Commerce. Fix double opening clicks on SPCO](https://github.com/eventespresso/cafe/pull/827) + - [PayPal Commerce. Fix double](https://github.com/eventespresso/cafe/pull/827) - [Don't apply payments to cancelled payments by default (#844)](https://github.com/eventespresso/cafe/pull/844) - [Verify Core Config Loaded Before Showing Maintenance Mode Notice (#843)](https://github.com/eventespresso/cafe/pull/843) diff --git a/PaymentMethods/PayPalCommerce/PayPalCheckout/EEG_PayPalCheckout.gateway.php b/PaymentMethods/PayPalCommerce/PayPalCheckout/EEG_PayPalCheckout.gateway.php index 829e54ea7c9..0b93ba7f7b0 100644 --- a/PaymentMethods/PayPalCommerce/PayPalCheckout/EEG_PayPalCheckout.gateway.php +++ b/PaymentMethods/PayPalCommerce/PayPalCheckout/EEG_PayPalCheckout.gateway.php @@ -51,7 +51,7 @@ class EEG_PayPalCheckout extends EE_Onsite_Gateway /** * @param EE_Payment|null $payment - * @param array|null $billing_info + * @param array|null $billing_info * @return EE_Payment * @throws EE_Error * @throws ReflectionException @@ -59,13 +59,14 @@ class EEG_PayPalCheckout extends EE_Onsite_Gateway public function do_direct_payment($payment, $billing_info = null) { $failed_status = $this->_pay_model->failed_status(); - $request = LoaderFactory::getLoader()->getShared(RequestInterface::class); + $request = LoaderFactory::getLoader()->getShared(RequestInterface::class); // Check the payment. $payment_valid = $this->validateThisPayment($payment, $request); if ($payment_valid->details() === 'error' && $payment_valid->status() === $failed_status) { return $payment_valid; } - $payment_method = $payment->transaction()->payment_method(); + $transaction = $payment->transaction(); + $payment_method = $transaction->payment_method(); // Get saved order details. try { @@ -87,7 +88,7 @@ public function do_direct_payment($payment, $billing_info = null) // Remove the saved order data. PayPalExtraMetaManager::deletePmOption($payment_method, Domain::META_KEY_LAST_ORDER); // Looks like all is good. Do a payment success. - return $this->setPaymentSuccess($payment, $order); + return $this->setPaymentSuccess($payment, $transaction, $order); } @@ -98,6 +99,7 @@ public function do_direct_payment($payment, $billing_info = null) * @param RequestInterface $request * @return EE_Payment * @throws EE_Error + * @throws ReflectionException */ public function validateThisPayment(?EE_Payment $payment, RequestInterface $request): EE_Payment { @@ -131,7 +133,7 @@ public function validateThisPayment(?EE_Payment $payment, RequestInterface $requ * Validate the Order. * * @param string $provided_order_id - * @param $order + * @param $order * @return string string if error and empty if valid. */ public function orderInvalid(string $provided_order_id, $order): string @@ -161,13 +163,13 @@ public function orderInvalid(string $provided_order_id, $order): string * @param array|string $response_data * @param string $err_message * @return EE_Payment - * @throws EE_Error + * @throws EE_Error|ReflectionException */ public function setPaymentFailure( EE_Payment $payment, - string $status, - $response_data, - string $err_message = '' + string $status, + $response_data, + string $err_message = '' ): EE_Payment { $this->log(['Error request data:' => $response_data], $payment); $payment->set_status($status); @@ -180,19 +182,76 @@ public function setPaymentFailure( /** * Set the payment success. * - * @param EE_Payment $payment - * @param array $order + * @param EE_Payment $payment + * @param EE_Transaction $transaction + * @param array $order * @return EE_Payment - * @throws EE_Error + * @throws EE_Error|ReflectionException */ - public function setPaymentSuccess(EE_Payment $payment, array $order): EE_Payment + public function setPaymentSuccess(EE_Payment $payment, EE_Transaction $transaction, array $order): EE_Payment { - $amount = $order['purchase_units'][0]['payments']['captures'][0]['amount']['value']; + $amount = $order['purchase_units'][0]['payments']['captures'][0]['amount']['value'] ?? 0; + if (! $amount) { + $this->log(['Success order but amount is 0 !' => $order], $payment); + } $payment->set_status(EEM_Payment::status_id_approved); $payment->set_amount((float) $amount); - $payment->set_txn_id_chq_nmbr($order['purchase_units'][0]['payments']['captures'][0]['id']); - $payment->set_details($order['payer']); - $payment->set_gateway_response($order['status']); + $payment->set_txn_id_chq_nmbr($order['purchase_units'][0]['payments']['captures'][0]['id'] ?? $order['id']); + $payment->set_gateway_response($order['status'] ?? 'success'); + $this->saveBillingDetails($payment, $transaction, $order); return $payment; } + + + /** + * Save some transaction details, like billing information. + * + * @param EE_Payment $payment + * @param EE_Transaction $transaction + * @param array $order + * @return void + * @throws EE_Error|ReflectionException + */ + public function saveBillingDetails(EE_Payment $payment, EE_Transaction $transaction, array $order): void + { + $input_values = []; + $primary_reg = $transaction->primary_registration(); + $attendee = $primary_reg instanceof EE_Registration ? $primary_reg->attendee() : null; + $transaction = $payment->transaction(); + $payment_method = $transaction->payment_method(); + $postmeta_name = $payment_method->type_obj() instanceof EE_PMT_Base + ? 'billing_info_' . $payment_method->type_obj()->system_name() + : ''; + if (empty($order['payment_source']) || ! $attendee instanceof EE_Attendee) { + // I guess we are done here then. Just save what we have. + $payment->set_details($order); + return; + } + // Do we have order information from the express checkout (PayPal button) ? + if (! empty($order['payment_source']['paypal'])) { + $payer = $order['payment_source']['paypal']; + $payer_name = $payer['name'] ?? ''; + $input_values['first_name'] = $payer_name['given_name'] ?? $attendee->fname(); + $input_values['last_name'] = $payer_name['surname'] ?? $attendee->lname(); + $input_values['email'] = $payer_name['email_address'] ?? $attendee->email(); + $input_values['address'] = $payer_name['address_line_1'] ?? $attendee->address(); + $input_values['address2'] = $payer_name['address_line_2'] ?? $attendee->address2(); + $input_values['city'] = $payer_name['admin_area_2'] ?? $attendee->city(); + $input_values['country'] = $payer_name['country_code'] ?? $attendee->country(); + $input_values['zip'] = $payer_name['postal_code'] ?? $attendee->zip(); + } + // Or card information from ACDC ? + if (! empty($order['payment_source']['card'])) { + $payer_card = $order['payment_source']['card']; + if (! empty($payer_card['name'])) { + $full_name = explode(' ', $payer_card['name']); + // Don't need to save each field because others should be populated from the billing form. + $input_values['credit_card'] = $payer_card['last_digits'] ?? ''; + $input_values['first_name'] = $full_name[0] ?? $attendee->fname(); + $input_values['last_name'] = $full_name[1] ?? $attendee->lname(); + } + } + update_post_meta($attendee->ID(), $postmeta_name, $input_values); + $attendee->save(); + } } diff --git a/PaymentMethods/PayPalCommerce/PayPalCheckout/EE_PMT_PayPalCheckout.pm.php b/PaymentMethods/PayPalCommerce/PayPalCheckout/EE_PMT_PayPalCheckout.pm.php index 3bfc141982f..b3de0dec7ba 100644 --- a/PaymentMethods/PayPalCommerce/PayPalCheckout/EE_PMT_PayPalCheckout.pm.php +++ b/PaymentMethods/PayPalCommerce/PayPalCheckout/EE_PMT_PayPalCheckout.pm.php @@ -2,6 +2,7 @@ use EventEspresso\core\services\loaders\LoaderFactory; use EventEspresso\core\services\request\DataType; +use EventEspresso\core\services\request\Request; use EventEspresso\core\services\request\RequestInterface; use EventEspresso\PaymentMethods\PayPalCommerce\PayPalCheckout\forms\BillingForm; use EventEspresso\PaymentMethods\PayPalCommerce\PayPalCheckout\forms\SettingsForm; @@ -58,7 +59,6 @@ public function generate_new_settings_form() { // Settings form. $settings_form = new SettingsForm($this, $this->_pm_instance); - // Filter the form contents. return apply_filters( 'FHEE__EE_PMT_PayPalCheckout__generate_new_settings_form__form_filtering', @@ -78,10 +78,26 @@ public function generate_new_settings_form() * @throws EE_Error * @throws ReflectionException */ - public function generate_new_billing_form(EE_Transaction $transaction = null, $extra_args = []) + public function generate_new_billing_form(EE_Transaction $transaction = null, ?array $extra_args = []) { + $request = LoaderFactory::getShared(Request::class); + $request_params = $request->requestParams(); + // Return the default billing form for the postbox if this is a WP admin transaction info page. + if (! empty($request_params['page']) && $request_params['page'] === 'espresso_transactions') { + $default_form = new EE_Billing_Attendee_Info_Form($this->_pm_instance, $extra_args); + $default_form->add_subsections(['credit_card' => new EE_Credit_Card_Input()]); + return $default_form; + } + // Just in case this is used on other admin pages. + if (empty($transaction) && ! empty($request_params['TXN_ID'])) { + $txn_instance = EEM_Transaction::instance()->get_one_by_ID($request_params['TXN_ID']); + $transaction = $txn_instance instanceof EE_Transaction ? $txn_instance : null; + } $options = array_merge( - ['transaction' => $transaction, 'template_path' => $this->_template_path], + [ + 'transaction' => $transaction, + 'template_path' => $this->_template_path, + ], $extra_args ); return new BillingForm($this->_pm_instance, $options); @@ -94,7 +110,7 @@ public function generate_new_billing_form(EE_Transaction $transaction = null, $e * @return array * @see EE_PMT_Base::help_tabs_config() */ - public function help_tabs_config() + public function help_tabs_config(): array { return [ $this->get_help_tab_name() => [ @@ -130,7 +146,7 @@ public static function refundNotice(bool $can_edit_payments) } // Try loading the template. EE_Registry::instance()->load_helper('Template'); - } catch (EE_Error | ReflectionException $e) { + } catch (EE_Error|ReflectionException $e) { // Just return, adding nothing. return; } diff --git a/PaymentMethods/PayPalCommerce/PayPalCheckout/forms/BillingForm.php b/PaymentMethods/PayPalCommerce/PayPalCheckout/forms/BillingForm.php index f41614d6f55..972828ba3f6 100644 --- a/PaymentMethods/PayPalCommerce/PayPalCheckout/forms/BillingForm.php +++ b/PaymentMethods/PayPalCommerce/PayPalCheckout/forms/BillingForm.php @@ -3,6 +3,7 @@ namespace EventEspresso\PaymentMethods\PayPalCommerce\PayPalCheckout\forms; use EE_Billing_Attendee_Info_Form; +use EE_Billing_Info_Form; use EE_Error; use EE_Form_Section_Base; use EE_Form_Section_HTML; @@ -12,16 +13,19 @@ use EE_Payment_Method; use EE_PMT_PayPalCheckout; use EE_Registry; +use EE_Submit_Input; use EE_Template_Layout; +use EE_Text_Input; use EE_Transaction; +use EED_PayPalCommerce; +use EEH_HTML; use EEM_Payment_Method; -use EventEspresso\core\exceptions\InvalidDataTypeException; -use EventEspresso\core\exceptions\InvalidInterfaceException; +use EventEspresso\core\services\loaders\LoaderFactory; +use EventEspresso\core\services\request\Request; use EventEspresso\PaymentMethods\PayPalCommerce\domain\Domain; use EventEspresso\PaymentMethods\PayPalCommerce\tools\currency\CurrencyManager; use EventEspresso\PaymentMethods\PayPalCommerce\tools\extra_meta\PayPalExtraMetaManager; use Exception; -use InvalidArgumentException; use ReflectionException; /** @@ -51,38 +55,35 @@ class BillingForm extends EE_Billing_Attendee_Info_Form */ protected $paypal_pmt; + /** + * @var string + */ + protected $checkout_type; + /** * Class constructor. * * @param EE_Payment_Method $payment_method * @param array $options - * @throws InvalidDataTypeException - * @throws InvalidInterfaceException - * @throws InvalidArgumentException * @throws EE_Error + * @throws ReflectionException */ public function __construct(EE_Payment_Method $payment_method, array $options = []) { - // Don't initiate if there's no transaction. - if (isset($options['transaction']) && $options['transaction'] instanceof EE_Transaction) { - if (! isset($options['template_path'])) { - $this->throwError('template_path'); - } - $this->paypal_pmt = $payment_method; - $this->transaction = $options['transaction']; - $this->template_path = $options['template_path']; - } - $pm_slug = $payment_method->slug(); - $parameters = array_replace_recursive( + $this->paypal_pmt = $payment_method; + // Can't be too careful. + $this->transaction = $options['transaction'] ?? null; + $this->template_path = $options['template_path'] ?? ''; + $this->checkout_type = $payment_method->get_extra_meta(Domain::META_KEY_CHECKOUT_TYPE, true, ''); + $pm_slug = $payment_method->slug(); + $parameters = array_replace_recursive( $options, [ 'name' => 'PayPalCommerceBillingForm', - 'html_id' => 'pp-' . $payment_method->slug() . '-billing-form', + 'html_id' => 'pp-' . $pm_slug . '-billing-form', 'html_class' => 'pp_commerce_billing_form', 'subsections' => [ - 'debug_content' => $this->addDebugContent($payment_method), - 'paypal_commerce_pm_form' => $this->addPaymentButtons(), 'eea_paypal_commerce_token' => new EE_Hidden_Input( [ 'html_id' => 'eea-paypal-commerce-token', @@ -90,28 +91,28 @@ public function __construct(EE_Payment_Method $payment_method, array $options = 'default' => '', ] ), - 'pp_order_nonce' => new EE_Hidden_Input( + 'pp_order_nonce' => new EE_Hidden_Input( [ 'html_id' => 'eea-' . $pm_slug . '-order-nonce', 'html_name' => 'pp_order_nonce', 'default' => '', ] ), - 'pp_order_id' => new EE_Hidden_Input( + 'pp_order_id' => new EE_Hidden_Input( [ 'html_id' => 'eea-' . $pm_slug . '-order-id', 'html_name' => 'pp_order_id', 'default' => '', ] ), - 'pp_order_status' => new EE_Hidden_Input( + 'pp_order_status' => new EE_Hidden_Input( [ 'html_id' => 'eea-' . $pm_slug . '-order-status', 'html_name' => 'pp_order_status', 'default' => '', ] ), - 'pp_order_amount' => new EE_Hidden_Input( + 'pp_order_amount' => new EE_Hidden_Input( [ 'html_id' => 'eea-' . $pm_slug . '-order-amount', 'html_name' => 'pp_order_amount', @@ -121,8 +122,255 @@ public function __construct(EE_Payment_Method $payment_method, array $options = ], ] ); - + // Add data tags to the PP script. + add_filter('script_loader_tag', [$this, 'addDataTagsToScript'], 10, 2); parent::__construct($payment_method, $parameters); + // Add and exclude other sections. + $this->addPaymentSections(); + // Additional actions and/or filters. + $this->loadActionsAndFilters(); + } + + + /** + * Add PayPal payment sections. + * + * @return void + * @throws EE_Error + * @throws ReflectionException + */ + public function addPaymentSections(): void + { + // Exclude the default billing form fields. + $this->exclude([ + 'first_name', + 'last_name', + 'email', + ]); + // Add PayPal Hosted Fields. + if ($this->checkout_type !== 'express_checkout') { + $this->addAdvancedCardFields(); + } + // Add payment types separator, if both are enabled. + if ($this->checkout_type === 'all') { + $this->addTypesSeparator(); + } + // Add PayPal Buttons section. + if ($this->checkout_type !== 'ppcp') { + $this->add_subsections( + [ + 'paypal_commerce_pm_form' => $this->addPayPalCheckout(), + ] + ); + } + // Exclude the rest billing form fields if the payment type is express checkout. + if ($this->checkout_type === 'express_checkout') { + $this->exclude([ + 'address', + 'address2', + 'state', + 'phone', + 'city', + 'country', + 'zip', + ]); + // Remove the Info subsection. + add_filter('FHEE__EE_Form_Section_Proper___construct__options_array', [$this, 'excludeInfoSubsection']); + } + $this->add_subsections( + [ + 'debug_content' => $this->addDebugContent($this->paypal_pmt), + ] + ); + } + + + /** + * Additional actions and/or filters. + * + * @return void + */ + public function loadActionsAndFilters(): void + { + add_filter( + 'FHEE__EE_SPCO_Reg_Step_Payment_Options___get_billing_form_for_payment_method__billing_form', + [__CLASS__, 'excludeBillingFormFields'], + 10, + 2 + ); + } + + + /** + * Filter out billing form fields if pay button was used. + * + * @param EE_Billing_Info_Form $billing_form + * @param EE_Payment_Method $payment_method + * @return EE_Billing_Info_Form + */ + public static function excludeBillingFormFields( + EE_Billing_Info_Form $billing_form, + EE_Payment_Method $payment_method + ): EE_Billing_Info_Form { + $request = LoaderFactory::getShared(Request::class); + $request_params = $request->requestParams(); + if ( + // Only the PPC billing form. + $billing_form instanceof BillingForm + && ! empty($request_params['process_form_submission']) + && $request_params['process_form_submission'] === '1' + && ! empty($request_params['eep_ppc_skip_form_validation']) + ) { + // Hide card info fields. + $billing_form->exclude([ + 'pp_name_on_card', + 'address', + 'address2', + 'state', + 'phone', + 'city', + 'country', + 'zip', + ]); + } + return $billing_form; + } + + + /** + * Add advanced card & debit card fields. + * + * @return void + * @throws EE_Error|ReflectionException + */ + public function addAdvancedCardFields(): void + { + $pm_slug = $this->paypal_pmt->slug(); + $this->add_subsections( + [ + 'pp_card_number' => new EE_Form_Section_HTML( + EEH_HTML::label( + esc_html__('Card Number', 'event_espresso'), + "$pm_slug-card-number-lbl", + "$pm_slug-card-fields", + "", + 'for="' . $pm_slug . '-card-number"' + ) . + EEH_HTML::p( + "", + "$pm_slug-card-number", + "card_field $pm_slug-card-fields" + ) + ), + 'pp_expiration_date' => new EE_Form_Section_HTML( + EEH_HTML::label( + esc_html__('Expiration Date', 'event_espresso'), + "$pm_slug-expiration-date-lbl", + "$pm_slug-card-fields", + "", + 'for="' . $pm_slug . '-expiration-date"' + ) . + EEH_HTML::p( + "", + "$pm_slug-expiration-date", + "card_field $pm_slug-card-fields" + ) + ), + 'pp_card_cvv' => new EE_Form_Section_HTML( + EEH_HTML::label( + esc_html__('CVV', 'event_espresso'), + "$pm_slug-cvv-lbl", + "$pm_slug-card-fields", + "", + 'for="' . $pm_slug . '-cvv"' + ) . + EEH_HTML::p( + "", + "$pm_slug-cvv", + "card_field $pm_slug-card-fields" + ) + ), + 'pp_name_on_card' => new EE_Text_Input( + [ + 'html_label_text' => esc_html__('Name On Card', 'event_espresso'), + 'html_id' => $pm_slug . '-card-holder-name', + 'html_name' => 'card-holder-name', + 'html_class' => '', + 'required' => true, + ] + ), + ] + ); + // Add the submit button at the end. + $this->add_subsections( + [ + 'pp_cc_submit' => new EE_Submit_Input( + [ + 'html_label_text' => esc_html__('Submit', 'event_espresso'), + 'html_id' => $pm_slug, + 'html_class' => 'eep-ppc-btn', + ] + ), + ], + 'phone', + false + ); + } + + + /** + * Add advanced card & debit card fields. + * + * @return void + * @throws EE_Error|ReflectionException + */ + public function addTypesSeparator(): void + { + $this->add_subsections( + [ + 'pp_payment_types_separator' => new EE_Form_Section_HTML( + EEH_HTML::div( + EEH_HTML::div( + ' ', + 'eep-' . $this->paypal_pmt->slug() . '-payments-separator', + 'eep-ppc-separator-line eep-left-floating' + ) . + EEH_HTML::div( + esc_html__(' or ', 'event_espresso'), + 'eep-' . $this->paypal_pmt->slug() . '-separator-text', + 'eep-ppc-separator-text1 eep-mid-floating' + ) . EEH_HTML::div( + ' ', + 'eep-' . $this->paypal_pmt->slug() . '-payments-separator', + 'eep-ppc-separator-line eep-right-floating' + ), + 'eep-ppc-separator-holder', + 'eep-ppc-separator-holder' + ) + ), + ] + ); + } + + + /** + * Exclude the info subsection from the PPC checkout form. + * + * @param array $options_array + * @return array + * @throws EE_Error + * @throws ReflectionException + */ + public function excludeInfoSubsection(array $options_array): array + { + if (! empty($options_array['html_id']) + && $options_array['html_id'] === 'spco-payment-method-info-' . $this->paypal_pmt->slug() + ) { + if (! empty($options_array['subsections']) && isset($options_array['subsections']['info'])) { + unset($options_array['subsections']['info']); + } + } + return $options_array; } @@ -131,7 +379,7 @@ public function __construct(EE_Payment_Method $payment_method, array $options = * * @param EE_Payment_Method $paypal_pm * @return EE_Form_Section_Base - * @throws EE_Error + * @throws EE_Error|ReflectionException */ public function addDebugContent(EE_Payment_Method $paypal_pm): EE_Form_Section_Base { @@ -157,11 +405,9 @@ public function addDebugContent(EE_Payment_Method $paypal_pm): EE_Form_Section_B * @return EE_Form_Section_Proper * @throws EE_Error */ - public function addPaymentButtons(): EE_Form_Section_Proper + public function addPayPalCheckout(): EE_Form_Section_Proper { - $template_args = [ - // 'pm_slug' => $this->_pm_instance->slug(), - ]; + $template_args['pm_slug'] = $this->paypal_pmt->slug(); return new EE_Form_Section_Proper( [ 'layout_strategy' => new EE_Template_Layout( @@ -175,6 +421,29 @@ public function addPaymentButtons(): EE_Form_Section_Proper } + /** + * Load scripts and localize data needed for this form. + * + * @param $tag + * @param $handle + * @return string + */ + public function addDataTagsToScript($tag, $handle): string + { + if ($handle === 'eea_paypal_commerce_js_lib') { + $bn_code = PayPalExtraMetaManager::getPmOption($this->_pm_instance, Domain::META_KEY_BN_CODE); + $response = EED_PayPalCommerce::requestClientToken($this->paypal_pmt); + if (empty($response['client_token'])) { + return $tag; + } + $client_token = $response['client_token']; + $attributes = " data-partner-attribution-id=\"$bn_code\" data-client-token=\"$client_token\""; + $tag = str_replace('>', $attributes . '>', $tag); + } + return $tag; + } + + /** * Load scripts and localize data needed for this form. * @@ -183,22 +452,40 @@ public function addPaymentButtons(): EE_Form_Section_Proper * @throws ReflectionException * @throws Exception */ - public function enqueue_js() + public function enqueue_js(): void { - $client_id = PayPalExtraMetaManager::getPmOption($this->_pm_instance, Domain::META_KEY_CLIENT_ID); - $currency = CurrencyManager::currencyCode(); + $third_party = EED_PayPalCommerce::isThirdParty($this->_pm_instance); + $currency = CurrencyManager::currencyCode(); + $client_id_key = Domain::META_KEY_CLIENT_ID; // Scripts. - $scripts_src = 'https://www.paypal.com/sdk/js?&client-id=' . $client_id . '¤cy=' . $currency; + $scripts_src = 'https://www.paypal.com/sdk/js?components=buttons,hosted-fields&intent=capture'; + if ($third_party) { + $client_id_key = Domain::META_KEY_PARTNER_CLIENT_ID; + $merchant_id = PayPalExtraMetaManager::getPmOption( + $this->_pm_instance, + Domain::META_KEY_SELLER_MERCHANT_ID + ); + $scripts_src .= "&merchant-id=$merchant_id"; + } + $client_id = PayPalExtraMetaManager::getPmOption($this->_pm_instance, $client_id_key); + $scripts_src .= "&client-id=$client_id¤cy=$currency"; wp_enqueue_script('eea_paypal_commerce_js_lib', $scripts_src, [], null); wp_enqueue_script( 'eea_paypal_commerce_js', EEP_PAYPAL_COMMERCE_URL . 'assets/js/paypal-commerce-payments.js', - [], - filemtime(EEP_PAYPAL_COMMERCE_DIR . 'assets/js/paypal-commerce-payments.js'), + ['eea_paypal_commerce_js_lib'], + EVENT_ESPRESSO_VERSION, true ); + // Styles. + wp_enqueue_style( + 'eea_paypal_checkout_form_styles', + EEP_PAYPAL_COMMERCE_URL . 'assets' . DS . 'css' . DS . 'eea-paypal-checkout.css', + [], + EVENT_ESPRESSO_VERSION + ); // Localize the script with our transaction data. - $parameters = $this->localizeParameters($client_id); + $parameters = $this->localizeParameters(); wp_localize_script('eea_paypal_commerce_js', 'eeaPPCommerceParameters', $parameters); parent::enqueue_js(); } @@ -230,13 +517,12 @@ public function getPpOrderId(string $transaction_id): string /** * Form and return PayPal commerce parameters for script localization. * - * @param string $client_id * @return array * @throws EE_Error * @throws ReflectionException * @throws Exception */ - public function localizeParameters(string $client_id): array + public function localizeParameters(): array { // Also tell the script about each instance of this PM. $pm_versions = []; @@ -253,16 +539,15 @@ public function localizeParameters(string $client_id): array // Convert money for a display format. $decimal_places = CurrencyManager::getDecimalPlaces(); $org_country = isset(EE_Registry::instance()->CFG->organization) - && EE_Registry::instance()->CFG->organization instanceof EE_Organization_Config + && EE_Registry::instance()->CFG->organization instanceof EE_Organization_Config ? EE_Registry::instance()->CFG->organization->CNT_ISO : 'US'; $transaction_id = $this->transaction instanceof EE_Transaction ? $this->transaction->ID() : 0; $currency_code = CurrencyManager::currencyCode(); - return [ 'pm_versions' => $pm_versions, - 'client_id' => $client_id, 'payment_currency' => $currency_code, + 'checkout_type' => $this->checkout_type, 'currency_sign' => EE_Registry::instance()->CFG->currency->sign, 'pp_order_id' => $this->getPpOrderId($transaction_id), 'pp_order_nonce' => wp_create_nonce(Domain::CAPTURE_ORDER_NONCE_NAME), @@ -271,6 +556,7 @@ public function localizeParameters(string $client_id): array 'org_country' => $org_country, 'decimal_places' => $decimal_places, 'site_name' => get_bloginfo('name'), + 'active_states' => EED_PayPalCommerce::getActiveStates(), 'no_spco_error' => esc_html__( 'It appears the SDK script was not loaded properly! Please refresh the page and try again or contact support.', 'event_espresso' @@ -296,29 +582,9 @@ public function localizeParameters(string $client_id): array ), 'no_order_id' => esc_html__('No Order ID found.', 'event_espresso'), 'general_pp_error' => esc_html__('PayPal form threw an error.', 'event_espresso'), + 'hf_render_error' => esc_html__('Hosted fields could not be rendered!', 'event_espresso'), + 'pm_capture_error' => esc_html__('Payment could not be captured!', 'event_espresso'), + 'not_acdc_eligible' => esc_html__('This merchant is not eligible for Advanced Card Fields checkout type.', 'event_espresso'), ]; } - - - /** - * Throw an EE error. - * - * @param string $error_name - * @throws EE_Error - */ - private function throwError(string $error_name) - { - if ($error_name === 'template_path') { - throw new EE_Error( - sprintf( - esc_html__( - '%1$s instantiated without the required template_path. Please provide it in $2$s', - 'event_espresso' - ), - __CLASS__, - '$options[\'template_path\']' - ) - ); - } - } } diff --git a/PaymentMethods/PayPalCommerce/PayPalCheckout/forms/OnboardingForm.php b/PaymentMethods/PayPalCommerce/PayPalCheckout/forms/OnboardingForm.php index 8517c29ecbb..4c7a8dd2004 100644 --- a/PaymentMethods/PayPalCommerce/PayPalCheckout/forms/OnboardingForm.php +++ b/PaymentMethods/PayPalCommerce/PayPalCheckout/forms/OnboardingForm.php @@ -2,20 +2,15 @@ namespace EventEspresso\PaymentMethods\PayPalCommerce\PayPalCheckout\forms; -use EE_Form_Section_Base; use EED_PayPalOnboard; use EEM_Payment_Method; use EE_Admin_Two_Column_Layout; use EE_Error; -use EE_Form_Section_HTML; use EE_Form_Section_Proper; use EE_Payment_Method; use EE_PMT_Base; use EE_Simple_HTML_Validation_Strategy; -use EEH_HTML; -use EventEspresso\PaymentMethods\PayPalCommerce\domain\Domain; -use EventEspresso\PaymentMethods\PayPalCommerce\tools\extra_meta\PayPalExtraMetaManager; -use Exception; +use ReflectionException; /** * Class OnboardingForm @@ -29,45 +24,24 @@ class OnboardingForm extends EE_Form_Section_Proper /** * Payment method. * - * @var EE_PMT_Base + * @var EE_PMT_Base|null */ protected $payment_method = null; /** * Payment method instance. * - * @var EE_PMT_Base + * @var EE_PMT_Base|null */ protected $pm_instance = null; /** * Payment method slug. * - * @var EE_PMT_Base + * @var EE_PMT_Base|null */ protected $pm_slug = null; - /** - * PayPal Onboarding button text. - * - * @var string - */ - protected $onboard_btn_text = ''; - - /** - * PayPal Onboarding button in sandbox mode text. - * - * @var string - */ - protected $sandbox_btn_text = ''; - - /** - * PayPal Onboarding section sandbox mode text. - * - * @var string - */ - protected $authed_sandbox_text = ''; - /** * Options field header. * @@ -82,6 +56,13 @@ class OnboardingForm extends EE_Form_Section_Proper */ protected $onboarding_url = ''; + /** + * Onboarding form html entities object. + * + * @var OnboardingFormHtml|null + */ + protected $form_html = null; + /** * Class constructor. @@ -95,18 +76,9 @@ public function __construct(EE_PMT_Base $pmt, EE_Payment_Method $payment_method) $this->payment_method = $pmt; $this->pm_instance = $payment_method; $this->pm_slug = $this->pm_instance->slug(); - $this->onboard_btn_text = esc_html__('Connect with PayPal', 'event_espresso'); - $this->sandbox_btn_text = esc_html__('Connect with PayPal (sandbox)', 'event_espresso'); - $this->authed_sandbox_text = esc_html__('(using sandbox credentials)', 'event_espresso'); + $this->form_html = new OnboardingFormHtml($pmt, $payment_method); // Help tab link as icon. - $this->option_heading = EEH_HTML::th( - sprintf( - esc_html__('PayPal Onboarding: %1$s', 'event_espresso'), - $this->payment_method->get_help_tab_link() - ), - 'eea_paypal_onboard_heading_' . $this->pm_slug, - 'eea-paypal-onboard-heading' - ); + $this->option_heading = $this->form_html->getHeader(); $options = [ 'html_id' => $this->pm_slug . '_pp_commerce_form', 'layout_strategy' => new EE_Admin_Two_Column_Layout(), @@ -121,206 +93,15 @@ public function __construct(EE_PMT_Base $pmt, EE_Payment_Method $payment_method) * Add the onboarding options section. * * @return array - * @throws EE_Error */ public function onboardSectionContents(): array { $subsections = []; // Get the Onboarding status. $is_onboard = EED_PayPalOnboard::isOnboard($this->pm_instance); - $subsections = $this->addOnboardButton($subsections, $is_onboard); - $subsections = $this->addOffboardButton($subsections, $is_onboard); - $subsections = $this->addPmSlugHolder($subsections); - return $subsections; - } - - - /** - * Add the onboarding button. - * - * @param array $subsections - * @param bool $is_onboard - * @return array - * @throws EE_Error - */ - public function addOnboardButton(array $subsections, bool $is_onboard): array - { - // Prep the redirect link for the merchant if he is not onboard yet. - $onboard_url = ''; - if (! $is_onboard) { - $onboard_url = EED_PayPalOnboard::getSignUpLink($this->pm_instance); - } - $this->onboarding_url = $onboard_url ? $onboard_url . '?&displayMode=minibrowser' : '#'; - // Section to be displayed if not onboard. - $subsections['paypal_onboard_btn'] = new EE_Form_Section_HTML( - EEH_HTML::tr( - $this->option_heading . - EEH_HTML::td( - EEH_HTML::link( - $this->onboarding_url, - EEH_HTML::span($this->onboard_btn_text), - '', - 'eea_paypal_onboard_btn_' . $this->pm_slug, - 'eea-paypal-onboard-btn button button--primary', - '', - 'target="_blank" data-paypal-onboard-complete="onboardedCallback" data-paypal-button="true"' - . ' data-ee-pm-slug=' . $this->pm_slug - ) - ), - 'eea_paypal_onboard_section_' . $this->pm_slug, - 'eea-onboard-section-' . $this->pm_slug, - // Are we onboard ? - $is_onboard ? 'display:none;' : '' - ), - ['required' => true] - ); - return $subsections; - } - - - /** - * Get the sandbox onboarding section contents. - * - * @return string - */ - public function getOnboardSandboxSection(): string - { - // Is this a test onboarding ? - $sandbox_mode_text = $this->pm_instance->debug_mode() ? $this->authed_sandbox_text : ''; - return ' ' . EEH_HTML::strong( - $sandbox_mode_text, - 'eea_paypal_onboard_test_txt_' . $this->pm_slug, - 'eea-paypal-onboard-test-txt' - ); - } - - - /** - * Get the seller merchant ID section contents. - * - * @return string - */ - public function getSellerIdSection(): string - { - try { - $payer_id = PayPalExtraMetaManager::getPmOption($this->pm_instance, Domain::META_KEY_PAYER_ID) ?? '--'; - } catch (Exception $e) { - $payer_id = '--'; - } - return ' ' . EEH_HTML::strong( - sprintf(esc_html__('Linked account ID: %1$s', 'event_espresso'), $payer_id), - 'eea_paypal_seller_id_' . $this->pm_slug, - 'eea-paypal-seller-id' - ); - } - - - /** - * Add the offboarding (deauthorize) button. - * - * @param array $subsections - * @param bool $is_onboard - * @return array - */ - public function addOffboardButton(array $subsections, bool $is_onboard): array - { - $onboard_sandbox_section = $this->getOnboardSandboxSection(); - // If we are connected, display the seller merchant ID. - $seller_id_section = $this->getSellerIdSection(); - // Section to be displayed when onboard. - $subsections['paypal_offboard_btn'] = new EE_Form_Section_HTML( - EEH_HTML::tr( - $this->option_heading - . EEH_HTML::td( - EEH_HTML::img( - EEP_PAYPAL_COMMERCE_URL . 'assets' . DS . 'lib' . DS . 'paypal-onboard.png', - '', - 'eea_paypal_offboard_ico', - 'eea-paypal-offboard-ico' - ) - . EEH_HTML::strong( - esc_html__('Connected.', 'event_espresso'), - 'eea_paypal_offboard_txt_' . $this->pm_slug, - 'eea-paypal-offboard-txt' - ) - . $onboard_sandbox_section - . $seller_id_section - . EEH_HTML::link( - '#', - EEH_HTML::span(esc_html__('Disconnect', 'event_espresso')), - '', - 'eea_paypal_offboard_btn_' . $this->pm_slug, - 'eea-paypal-onboard-btn button button--primary' - ) - ), - 'eea_paypal_offboard_section_' . $this->pm_slug, - 'eea-offboard-section-' . $this->pm_slug, - // Are we onboard ? - ! $is_onboard ? 'display:none;' : '' - ), - ['required' => true] - ); - return $subsections; - } - - - /** - * Add the PM slug holder. - * - * @param array $subsections - * @return array - */ - public function addPmSlugHolder(array $subsections): array - { - $subsections['paypal_pm_slug_holder'] = new EE_Form_Section_HTML( - EEH_HTML::span( - '', - 'eea_paypal_pm_slug', - 'eea-paypal-pm-slug', - 'display:none;' - ) - ); - return $subsections; - } - - - /** - * HTML for the disconnect warning dialog. - * - * @return EE_Form_Section_Base - */ - public function disconnectDialogHtml(): EE_Form_Section_Base - { - $message = esc_html__( - 'Disconnecting your PayPal account will prevent you from offering PayPal services and products on your website.', - 'event_espresso' - ); - return new EE_Form_Section_HTML( - EEH_HTML::tr( - EEH_HTML::td( - EEH_HTML::strong( - $message, - 'eea_paypal_dialog_txt_' . $this->pm_slug, - 'eea-paypal-dialog-txt' - ) . - EEH_HTML::link( - '', - 'Cancel', - 'cancel, go back', - 'eea_paypal_dialog_cancel_' . $this->pm_slug, - 'eea-paypal-dialog-cancel button button--secondary' - ) . - EEH_HTML::link( - '', - 'Disconnect', - 'ok, continue', - 'eea_paypal_dialog_ok_' . $this->pm_slug, - 'eea-paypal-dialog-ok button button--primary-alt' - ) - ), - 'eea_paypal_disconnect_dialog_' . $this->pm_slug - ) - ); + $subsections = $this->form_html->addOnboardButton($subsections, $is_onboard); + $subsections = $this->form_html->addOffboardButton($subsections, $is_onboard); + return $this->form_html->addPmSlugHolder($subsections); } @@ -330,6 +111,7 @@ public function disconnectDialogHtml(): EE_Form_Section_Base * * @return void * @throws EE_Error + * @throws ReflectionException */ public function enqueue_js() { @@ -344,14 +126,18 @@ public function enqueue_js() 'pm_slug' => $payment_method->slug(), ]; } - + $countries_iso = ["US", "AU", "AT", "BE", "BG", "HR", "CY", "CZ", "DK", "EE", "FI", "FR", "DE", "GR", "HU", + "IE", "IT", "LV", "LT", "LU", "MT", "NL", "PL", "PT", "RO", "SK", "SI", "ES", "SE"]; $parameters = [ - 'onboard_btn_text' => $this->onboard_btn_text, - 'sandbox_btn_text' => $this->sandbox_btn_text, - 'sandbox_text' => $this->authed_sandbox_text, + 'onboard_btn_text' => $this->form_html->onboard_btn_text, + 'sandbox_btn_text' => $this->form_html->sandbox_btn_text, + 'sandbox_text' => $this->form_html->authed_sandbox_text, 'pm_versions' => $pm_versions, 'onboarding_url' => $this->onboarding_url, - 'disconnect_dialog' => $this->disconnectDialogHtml()->get_html(), + 'supported_countries' => $countries_iso, + 'connect_dialog' => $this->form_html->connectDialog()->get_html(), + 'disconnect_dialog' => $this->form_html->disconnectDialog()->get_html(), + 'processing_mask' => $this->form_html->processingMask()->get_html(), 'ee_default_styles' => EE_ADMIN_URL . 'assets/ee-admin-page.css', 'wp_stylesheet' => includes_url('css/dashicons.min.css'), 'can_disable_input' => method_exists('EE_Form_Input_Base', 'isDisabled'), @@ -362,7 +148,7 @@ public function enqueue_js() 'event_espresso' ), 'unknown_container' => esc_html__('Could not specify the parent form.', 'event_espresso'), - 'pm_nice_name' => esc_html__('PayPal Payments', 'event_espresso'), + 'pm_nice_name' => esc_html__('PayPal Commerce', 'event_espresso'), 'blocked_popup_notice' => esc_html__( 'The authentication process could not be executed. Please allow window pop-ups in your browser for this website in order to process a successful authentication.', 'event_espresso' @@ -380,21 +166,19 @@ public function enqueue_js() 'event_espresso' ), ]; - // Styles. wp_enqueue_style( 'eea_paypal_onboard_form_styles', EEP_PAYPAL_COMMERCE_URL . 'assets' . DS . 'css' . DS . 'eea-paypal-onboard.css', [], - filemtime(EEP_PAYPAL_COMMERCE_DIR . 'assets' . DS . 'css' . DS . 'eea-paypal-onboard.css') + EVENT_ESPRESSO_VERSION ); - // Scripts. wp_enqueue_script( 'eea_paypal_onboard_form_scripts', EEP_PAYPAL_COMMERCE_URL . 'assets' . DS . 'js' . DS . 'eea-paypal-onboarding.js', [], - filemtime(EEP_PAYPAL_COMMERCE_DIR . 'assets' . DS . 'js' . DS . 'eea-paypal-onboarding.js') + EVENT_ESPRESSO_VERSION ); wp_enqueue_script( 'eea_paypal_partner_script', @@ -402,10 +186,8 @@ public function enqueue_js() [], EVENT_ESPRESSO_VERSION ); - // Localize the script with some extra data. wp_localize_script('eea_paypal_onboard_form_scripts', 'eeaPPOnboardParameters', $parameters); - parent::enqueue_js(); } } diff --git a/PaymentMethods/PayPalCommerce/PayPalCheckout/forms/OnboardingFormHtml.php b/PaymentMethods/PayPalCommerce/PayPalCheckout/forms/OnboardingFormHtml.php new file mode 100644 index 00000000000..b59dd002793 --- /dev/null +++ b/PaymentMethods/PayPalCommerce/PayPalCheckout/forms/OnboardingFormHtml.php @@ -0,0 +1,476 @@ +payment_method = $pmt; + $this->pm_instance = $payment_method; + $this->pm_slug = $this->pm_instance->slug(); + $this->onboard_btn_text = esc_html__('Connect with PayPal', 'event_espresso'); + $this->sandbox_btn_text = esc_html__('Connect with PayPal (sandbox)', 'event_espresso'); + $this->authed_sandbox_text = esc_html__('(using sandbox credentials)', 'event_espresso'); + } + + + /** + * Form a heading. + * + * @param string $text + * @return string + */ + public function getHeader(string $text = ''): string + { + $text = $text ?: esc_html__('PayPal Onboarding: %1$s', 'event_espresso'); + return EEH_HTML::th( + sprintf( + $text, + $this->payment_method->get_help_tab_link() + ), + 'eea_paypal_onboard_heading_' . $this->pm_slug, + 'eea-paypal-onboard-heading' + ); + } + + + /** + * Add the onboarding button. + * + * @param array $subsections + * @param bool $is_onboard + * @return array + */ + public function addOnboardButton(array $subsections, bool $is_onboard): array + { + // Section to be displayed if not onboard. + $subsections['paypal_onboard_btn'] = new EE_Form_Section_HTML( + EEH_HTML::tr( + $this->getHeader() . + EEH_HTML::td( + EEH_HTML::button( + $this->onboard_btn_text, + 'eea-paypal-onboard-btn button button--primary', + '', + 'eea_paypal_onboard_btn_' . $this->pm_slug, + ) + . EEH_HTML::link( + '#', + '', + '', + 'eea_paypal_onboard_trigger_btn_' . $this->pm_slug, + 'eea-paypal-onboard-trigger-btn', + '', + 'data-ee-pm-slug="' . $this->pm_slug . '" data-paypal-button="true"' + ) + ), + 'eea_paypal_onboard_section_' . $this->pm_slug, + 'eea-onboard-section eea-onboard-section-' . $this->pm_slug, + // Are we onboard ? + $is_onboard ? 'display:none;' : '' + ), + ['required' => true] + ); + return $subsections; + } + + + /** + * Add the offboarding (deauthorize) button. + * + * @param array $subsections + * @param bool $is_onboard + * @return array + */ + public function addOffboardButton(array $subsections, bool $is_onboard): array + { + $onboard_sandbox_section = $this->getOnboardSandboxSection(); + // If we are connected, display the seller merchant ID. + $seller_id_section = $this->getSellerIdSection(); + // Section to be displayed when onboard. + $subsections['paypal_offboard_btn'] = new EE_Form_Section_HTML( + EEH_HTML::tr( + $this->getHeader() + . EEH_HTML::td( + EEH_HTML::img( + EEP_PAYPAL_COMMERCE_URL . 'assets' . DS . 'lib' . DS . 'paypal-onboard.png', + '', + 'eea_paypal_offboard_ico', + 'eea-paypal-offboard-ico' + ) + . EEH_HTML::strong( + esc_html__('Connected.', 'event_espresso'), + 'eea_paypal_offboard_txt_' . $this->pm_slug, + 'eea-paypal-offboard-txt' + ) + . $onboard_sandbox_section + . $seller_id_section + . EEH_HTML::link( + '#', + EEH_HTML::span(esc_html__('Disconnect', 'event_espresso')), + '', + 'eea_paypal_offboard_btn_' . $this->pm_slug, + 'eea-paypal-onboard-btn button button--primary' + ) + ), + 'eea_paypal_offboard_section_' . $this->pm_slug, + 'eea-offboard-section-' . $this->pm_slug, + // Are we onboard ? + ! $is_onboard ? 'display:none;' : '' + ), + ['required' => true] + ); + return $subsections; + } + + + /** + * Get the sandbox onboarding section contents. + * + * @return string + */ + public function getOnboardSandboxSection(): string + { + // Is this a test onboarding ? + $sandbox_mode_text = $this->pm_instance->debug_mode() ? $this->authed_sandbox_text : ''; + return ' ' . EEH_HTML::strong( + $sandbox_mode_text, + 'eea_paypal_onboard_test_txt_' . $this->pm_slug, + 'eea-paypal-onboard-test-txt' + ); + } + + + /** + * Get the seller merchant ID section contents. + * + * @return string + */ + public function getSellerIdSection(): string + { + try { + $is_third_party = EED_PayPalCommerce::isThirdParty($this->pm_instance); + $meta_key = $is_third_party ? Domain::META_KEY_SELLER_MERCHANT_ID : Domain::META_KEY_PAYER_ID; + $payer_id = PayPalExtraMetaManager::getPmOption($this->pm_instance, $meta_key) ?: '--'; + } catch (Exception $e) { + $payer_id = '--'; + } + return ' ' . EEH_HTML::strong( + sprintf(esc_html__('Linked account ID: %1$s', 'event_espresso'), $payer_id), + 'eea_paypal_seller_id_' . $this->pm_slug, + 'eea-paypal-seller-id' + ); + } + + + /** + * Add the PM slug holder. + * + * @param array $subsections + * @return array + */ + public function addPmSlugHolder(array $subsections): array + { + $subsections['paypal_pm_slug_holder'] = new EE_Form_Section_HTML( + EEH_HTML::span( + '', + 'eea_paypal_pm_slug', + 'eea-paypal-pm-slug', + 'display:none;' + ) + ); + return $subsections; + } + + + /** + * HTML for onboarding settings dialog. + * + * @return EE_Form_Section_Base + */ + public function connectDialog(): EE_Form_Section_Base + { + return new EE_Form_Section_HTML( + EEH_HTML::div( + $this->countriesSelectHtml() . + $this->paymentOptionsHtml() . + EEH_HTML::div( + EEH_HTML::link( + '', + 'Cancel', + 'cancel, go back', + 'eea_ppc_connect_cancel_' . $this->pm_slug, + 'eea-ppc-connect-cancel button button--secondary' + ) . + EEH_HTML::link( + '', + 'Continue', + 'ok, continue', + 'eea_ppc_connect_ok_' . $this->pm_slug, + 'eea-ppc-connect-ok button button--primary-alt' + ), + '', + 'eep-ppc-dialog-yes-no' + ), + 'eea_paypal_connect_dialog_' . $this->pm_slug + ) + ); + } + + + /** + * Form a countries select and return as html. + * + * @return string + */ + public function countriesSelectHtml(): string + { + $countries = []; + $countries_select = EEH_HTML::strong( + esc_html__('Please select a country where your PayPal account is registered:', 'event_espresso'), + 'eep_ppc_country_txt_' . $this->pm_slug, + 'eep-ppc-country-txt' + ); + try { + // Get all countries list. + $countries_iso = EEM_Country::instance()->get_all_countries(); + foreach ($countries_iso as $iso => $country) { + if ($country instanceof EE_Country) { + $countries [ $iso ] = $country->get('CNT_name'); + } + } + // Now build the select input. + $select_input = new EE_Select_Input( + $countries, + [ + 'html_name' => 'eep_ppc_country_' . $this->pm_slug, + 'html_id' => 'eep_ppc_country_' . $this->pm_slug, + 'html_class' => 'eep-ppc-country-' . $this->pm_slug, + 'html_label_text' => esc_html__('Select country', 'event_espresso'), + 'required' => true, + 'default' => EE_Config::instance()->organization->CNT_ISO ?? 'US' + ] + ); + $countries_select .= $select_input->get_html_for_input(); + } catch (Exception $e) { + // Countries list set at this point, so just continue. + } + return $countries_select; + } + + + /** + * Form the payment options checkboxes and return as html. + * + * @return string + */ + public function paymentOptionsHtml(): string + { + $options_lbl = EEH_HTML::strong( + esc_html__('Select a product you\'d like to allow at checkout:', 'event_espresso'), + 'eea_ppc_product_txt_' . $this->pm_slug, + 'eea-ppc-product-txt' + ); + $express_checkout_lbl = EEH_HTML::label( + esc_html__('Accept PayPal ', 'event_espresso') + . EEH_HTML::img( + 'https://www.paypalobjects.com/webstatic/mktg/Logo/pp-logo-100px.png', + '', + 'eea_ppc_express_checkout_img_' . $this->pm_slug, + 'eea-ppc-express-checkout-img' + ), + '', + '', + '', + 'for="' . 'eep_ppc_checkout_type_' . $this->pm_slug .'-express_checkout"' + ); + $ppcp_lbl = EEH_HTML::label( + esc_html__('Accept credit and debit card payments with PayPal ', 'event_espresso') + . EEH_HTML::img( + 'https://www.paypalobjects.com/digitalassets/c/website/marketing/apac/C2/logos-buttons/optimize/Full_Online_Tray_RGB.png', + '', + 'eea_ppc_ppcp_img_' . $this->pm_slug, + 'eea-ppc-ppcp-img' + ), + '', + '', + '', + 'for="' . 'eep_ppc_checkout_type_' . $this->pm_slug .'-ppcp"' + ); + $checkbox = new EE_Checkbox_Multi_Input( + [ + 'express_checkout' => $express_checkout_lbl, + 'ppcp' => $ppcp_lbl, + ], + [ + 'html_id' => 'eep_ppc_checkout_type_' . $this->pm_slug, + 'html_label_text' => esc_html__( + 'Select a product you\'d like to allow at checkout.', + 'event_espresso' + ), + 'html_help_text' => esc_html__( + 'Select a product you\'d like to allow at checkout.', + 'event_espresso' + ), + 'default' => ['express_checkout', 'ppcp'] + ] + ); + try { + return EEH_HTML::div( + $options_lbl + . $checkbox->get_html_for_input(), + 'eep_ppc_checkout_types_' . $this->pm_slug, + 'eep-ppc-checkout-types' + ); + } catch (Exception $e) { + return ''; + } + } + + + /** + * HTML for onboarding settings dialog. + * + * @return EE_Form_Section_Base + */ + public function processingMask(): EE_Form_Section_Base + { + return new EE_Form_Section_HTML( + EEH_HTML::div( + EEH_HTML::div(' ', 'eep_ppc_processing_mask', 'eep-ppc-processing-mask') . + EEH_HTML::div(' ', 'eep_ppc_processing_spinner', 'ee-spinner ee-spin') . + EEH_HTML::div( + esc_html__('The login window should be open. If you don\'t see a new PayPal login window you might need to enable pop-ups in your browser in order to continue.') . + EEH_HTML::div( + EEH_HTML::link( + '#', + esc_html__('Focus window'), + esc_html__('Focus window'), + 'eep_ppc_window_focus_' . $this->pm_slug, + 'eep-ppc-window-focus' + ) + ), + 'eep_ppc_processing_message', + 'eep-ppc-processing-message' + ), + 'eep_ppc_processing_' . $this->pm_slug, + 'eep-ppc-processing' + ) + ); + } + + + /** + * HTML for the disconnect warning dialog. + * + * @return EE_Form_Section_Base + */ + public function disconnectDialog(): EE_Form_Section_Base + { + $message = esc_html__( + 'Disconnecting your PayPal account will prevent you from offering PayPal services and products on your website.', + 'event_espresso' + ); + return new EE_Form_Section_HTML( + EEH_HTML::div( + EEH_HTML::strong( + $message, + 'eep_ppc_disconnect_dialog_txt_' . $this->pm_slug, + 'eep-ppc-disconnect-dialog-txt' + ) . + EEH_HTML::div( + EEH_HTML::link( + '', + 'Cancel', + 'cancel, go back', + 'eep_ppc_disconnect_cancel_' . $this->pm_slug, + 'eep-ppc-disconnect-cancel button button--secondary' + ) . + EEH_HTML::link( + '', + 'Disconnect', + 'ok, continue', + 'eep_ppc_disconnect_ok_' . $this->pm_slug, + 'eep-ppc-disconnect-ok button button--primary-alt' + ), + '', + 'eep-ppc-dialog-yes-no' + ), + 'eep_paypal_disconnect_dialog_' . $this->pm_slug + ) + ); + } +} diff --git a/PaymentMethods/PayPalCommerce/PayPalCheckout/forms/SettingsForm.php b/PaymentMethods/PayPalCommerce/PayPalCheckout/forms/SettingsForm.php index 572c02013cb..7c4b7fb19cf 100644 --- a/PaymentMethods/PayPalCommerce/PayPalCheckout/forms/SettingsForm.php +++ b/PaymentMethods/PayPalCommerce/PayPalCheckout/forms/SettingsForm.php @@ -3,12 +3,17 @@ namespace EventEspresso\PaymentMethods\PayPalCommerce\PayPalCheckout\forms; use EE_Payment_Method_Form; +use EE_PMT_Base; use EE_PMT_PayPalCheckout; use EE_Payment_Method; use EE_Error; use EE_Form_Section_HTML; +use EE_Select_Input; use EED_PayPalOnboard; use EEH_HTML; +use EventEspresso\PaymentMethods\PayPalCommerce\domain\Domain; +use EventEspresso\PaymentMethods\PayPalCommerce\tools\extra_meta\PayPalExtraMetaManager; +use ReflectionException; /** * Class SettingsForm @@ -19,22 +24,47 @@ */ class SettingsForm extends EE_Payment_Method_Form { + /** + * Payment method. + * + * @var EE_PMT_Base|null + */ + protected $payment_method = null; + + /** + * Payment method instance. + * + * @var EE_PMT_Base|null + */ + protected $pm_instance = null; + + /** * Class constructor. * * @param EE_PMT_PayPalCheckout $payment_method * @param EE_Payment_Method $pm_instance + * @throws EE_Error + * @throws ReflectionException */ public function __construct(EE_PMT_PayPalCheckout $payment_method, EE_Payment_Method $pm_instance) { - $form_parameters = []; + $form_parameters = []; + $this->payment_method = $payment_method; + $this->pm_instance = $pm_instance; + // Allow Advanced Card Checkout if PPCP checkout type was possible and selected. + $allowed_type = PayPalExtraMetaManager::getPmOption($pm_instance, Domain::META_KEY_ALLOWED_CHECKOUT_TYPE); + $is_onboard = EED_PayPalOnboard::isOnboard($pm_instance); + if ($is_onboard && ($allowed_type === 'ppcp' || $allowed_type === 'all')) { + $form_parameters = $this->addCheckoutTypeSelect($form_parameters); + } // Build the PM form. parent::__construct($form_parameters); // Add a form for PayPal Onboard. $this->addOnboardingForm($payment_method, $pm_instance); // Add the clear data button. $this->clearMetadataButton($pm_instance); - // Disable inputs if needed + // Disable inputs if needed. $this->toggleSubsections($pm_instance); } @@ -46,14 +76,12 @@ public function __construct(EE_PMT_PayPalCheckout $payment_method, EE_Payment_Me * @param EE_Payment_Method $pm_instance * @return void */ - public function addOnboardingForm(EE_PMT_PayPalCheckout $payment_method, EE_Payment_Method $pm_instance) + public function addOnboardingForm(EE_PMT_PayPalCheckout $payment_method, EE_Payment_Method $pm_instance): void { // Add the connect button before the app id field. try { - // $template = new OnboardingForm($payment_method, $pm_instance); $this->add_subsections( [ - // 'paypal_onboard' => new EE_Form_Section_HTML($template->get_html_and_js()), 'paypal_onboard' => new OnboardingForm($payment_method, $pm_instance), ], 'PMD_debug_mode', @@ -65,20 +93,53 @@ public function addOnboardingForm(EE_PMT_PayPalCheckout $payment_method, EE_Paym } + /** + * Add a checkout type select. + * + * @param array $form_parameters + * @return array + */ + public function addCheckoutTypeSelect(array $form_parameters): array + { + $pm_slug = $this->pm_instance->slug(); + $allowed_checkout_type = PayPalExtraMetaManager::getPmOption( + $this->pm_instance, + Domain::META_KEY_ALLOWED_CHECKOUT_TYPE + ); + // Section to be displayed if onboard. + $form_parameters['extra_meta_inputs'] = [ + Domain::META_KEY_CHECKOUT_TYPE => new EE_Select_Input( + [ + 'express_checkout' => esc_html__('Express Checkout', 'event_espresso'), + 'ppcp' => esc_html__('Advanced Credit and Debit Card payments', 'event_espresso'), + 'all' => esc_html__('Both, ACDC and Express Checkout', 'event_espresso'), + ], + [ + 'html_name' => 'eep_checkout_type_option_' . $pm_slug, + 'html_id' => 'eep_checkout_type_option_' . $pm_slug, + 'html_class' => 'eep-checkout-type-option-' . $pm_slug, + 'required' => true, + 'default' => $allowed_checkout_type, + ] + ), + ]; + return $form_parameters; + } + + /** * Adds a button for clearing the PM metadata. * - * @param EE_Payment_Method $pm_instance + * @param EE_Payment_Method $pm_instance * @return void */ - public function clearMetadataButton(EE_Payment_Method $pm_instance) + public function clearMetadataButton(EE_Payment_Method $pm_instance): void { try { $is_onboard = EED_PayPalOnboard::isOnboard($pm_instance); if ($is_onboard) { return; } - $button_text = sprintf( esc_html__('Clear %1$s metadata', 'event_espresso'), $pm_instance->admin_name() @@ -86,20 +147,18 @@ public function clearMetadataButton(EE_Payment_Method $pm_instance) $this->add_subsections( [ 'clear_pm_metadata' => new EE_Form_Section_HTML( - // EEH_HTML::table( EEH_HTML::tr( EEH_HTML::th(esc_html__('Clear PM metadata ?', 'event_espresso')) . - EEH_HTML::td( - EEH_HTML::link( - '', - $button_text, - $button_text, - 'eea_clear_metadata_' . $pm_instance->slug(), - 'espresso-button button button--secondary' - ) + EEH_HTML::td( + EEH_HTML::link( + '', + $button_text, + $button_text, + 'eea_clear_metadata_' . $pm_instance->slug(), + 'espresso-button button button--secondary' ) + ) ) - // ) ), ], 'PMD_order', @@ -118,7 +177,7 @@ public function clearMetadataButton(EE_Payment_Method $pm_instance) * @return void * @throws EE_Error */ - private function toggleSubsections(EE_Payment_Method $pm_instance) + private function toggleSubsections(EE_Payment_Method $pm_instance): void { $onboard = EED_PayPalOnboard::isOnboard($pm_instance); // Don't allow changing the debug mode setting while connected. diff --git a/PaymentMethods/PayPalCommerce/PayPalCheckout/templates/paymentButtons.template.php b/PaymentMethods/PayPalCommerce/PayPalCheckout/templates/paymentButtons.template.php index c6403c2a304..60bf845ed8f 100644 --- a/PaymentMethods/PayPalCommerce/PayPalCheckout/templates/paymentButtons.template.php +++ b/PaymentMethods/PayPalCommerce/PayPalCheckout/templates/paymentButtons.template.php @@ -5,7 +5,10 @@ * * @package Event Espresso * @subpackage eea-paypal-commerce + * + * Template arguments: + * @type bool $pm_slug The payment method slug. */ ?> -
+
diff --git a/PaymentMethods/PayPalCommerce/api/FirstPartyPayPalApi.php b/PaymentMethods/PayPalCommerce/api/FirstPartyPayPalApi.php new file mode 100644 index 00000000000..f6ae15764b3 --- /dev/null +++ b/PaymentMethods/PayPalCommerce/api/FirstPartyPayPalApi.php @@ -0,0 +1,127 @@ +client_id = $client_id; + $this->client_secret = $client_secret; + $this->bn_code = $bn_code; + } + + + /** + * Send an API request. + * + * @param array $body_parameters + * @param string $endpoint + * @param string $method + * @param array $headers + * @return Object|array + */ + public function sendRequest(array $body_parameters, string $endpoint, string $method = 'POST', array $headers = []) + { + $request_parameters = $this->getRequestParameters($body_parameters, $method, $headers); + return $this->response($endpoint, $request_parameters); + } + + + /** + * Build the request parameters. + * + * @param array $body_parameters + * @param string $method + * @param array $headers + * @return array + */ + private function getRequestParameters(array $body_parameters, string $method, array $headers): array + { + $request_parameters = [ + 'method' => $method, + 'timeout' => 60, + 'redirection' => 5, + 'blocking' => true, + ]; + $default_headers = [ + 'User-Agent' => sanitize_text_field($_SERVER['HTTP_USER_AGENT']), + 'PayPal-Partner-Attribution-Id' => $this->bn_code, + 'Content-Type' => 'application/json', + 'Authorization' => 'Basic ' . base64_encode( + $this->client_id . ':' . $this->client_secret + ), + ]; + $request_parameters['headers'] = array_merge($default_headers, $headers); + // Add body if this is a POST request. + if ($body_parameters && ($method === 'POST' || $method === 'PUT')) { + $request_parameters['body'] = json_encode($body_parameters); + } + return $request_parameters; + } + + + /** + * @return string + */ + public function clientId(): string + { + return $this->client_id; + } + + + /** + * @return string + */ + public function clientSecret(): string + { + return $this->client_secret; + } + + + /** + * @return string + */ + public function bnCode(): string + { + return $this->bn_code; + } +} diff --git a/PaymentMethods/PayPalCommerce/api/PayPalApi.php b/PaymentMethods/PayPalCommerce/api/PayPalApi.php index 7676b3490a5..eb34d3572d7 100644 --- a/PaymentMethods/PayPalCommerce/api/PayPalApi.php +++ b/PaymentMethods/PayPalCommerce/api/PayPalApi.php @@ -2,92 +2,59 @@ namespace EventEspresso\PaymentMethods\PayPalCommerce\api; -use EE_Error; use EventEspresso\PaymentMethods\PayPalCommerce\tools\logging\PayPalLogger; /** * Class PayPalApi * - * A base class for all PayPal API components used in this add-on. + * Abstract parent class for all PayPal API implementations. * * @package Event Espresso * @subpackage eea-paypal-commerce * @author Nazar Kolivoshka */ -class PayPalApi +abstract class PayPalApi { /** - * Client ID. Used to process payments. - * - * @var string - */ - protected $client_id = ''; - - /** - * Client secret. Used to process payments. - * - * @var string + * @var bool Debug mode enabled ? */ - protected $client_secret = ''; + protected bool $sandbox_mode; /** - * BN Code. Partner-Attribution-Id. + * API request/response validation helper. * - * @var string + * @var ResponseInspector */ - protected $bn_code = ''; + protected ResponseInspector $inspector; /** * @var string PayPal API endpoint. */ - protected $api_endpoint = ''; - - /** - * @var bool Debug mode enabled ? - */ - protected $sandbox_mode; - - /** - * API request/response validation helper. - * - * @var ResponseInspector - */ - protected $inspector; + protected string $api_endpoint = ''; /** - * @param string $client_id - * @param string $client_secret - * @param string $bn_code - * @param bool $sandbox_mode + * @param bool $sandbox_mode */ - public function __construct(string $client_id, string $client_secret, string $bn_code, bool $sandbox_mode = true) - { - $this->client_id = $client_id; - $this->client_secret = $client_secret; - $this->sandbox_mode = $sandbox_mode; - $this->bn_code = $bn_code; + public function __construct(bool $sandbox_mode = true) { + $this->sandbox_mode = $sandbox_mode; // Is this a sandbox request. $this->api_endpoint = $this->sandbox_mode ? 'https://api-m.sandbox.paypal.com/v2/' : 'https://api-m.paypal.com/v2/'; - $this->inspector = new ResponseInspector(); + $this->inspector = new ResponseInspector(); } /** * Send an API request. * - * @param array $body_parameters * @param string $endpoint - * @param string $method - * @param array $headers + * @param array $request_parameters * @return Object|array - * @throws EE_Error */ - public function sendRequest(array $body_parameters, string $endpoint, string $method = 'POST', array $headers = []) + public function response(string $endpoint, array $request_parameters) { - $request_parameters = $this->getRequestParameters($body_parameters, $method, $headers); // Sent the API request. $response = wp_remote_request($endpoint, $request_parameters); // Validate the response. @@ -109,39 +76,6 @@ public function sendRequest(array $body_parameters, string $endpoint, string $me } - /** - * Build the request parameters. - * - * @param array $body_parameters - * @param string $method - * @param array $headers - * @return array - */ - private function getRequestParameters(array $body_parameters, string $method, array $headers): array - { - $request_parameters = [ - 'method' => $method, - 'timeout' => 60, - 'redirection' => 5, - 'blocking' => true, - ]; - $default_headers = [ - 'User-Agent' => sanitize_text_field($_SERVER['HTTP_USER_AGENT']), - 'PayPal-Partner-Attribution-Id' => $this->bn_code, - 'Content-Type' => 'application/json', - 'Authorization' => 'Basic ' . base64_encode( - $this->client_id . ':' . $this->client_secret - ), - ]; - $request_parameters['headers'] = array_merge($default_headers, $headers); - // Add body if this is a POST request. - if ($body_parameters && ($method === 'POST' || $method === 'PUT')) { - $request_parameters['body'] = json_encode($body_parameters); - } - return $request_parameters; - } - - /** * @return string */ @@ -149,31 +83,4 @@ public function apiEndpoint(): string { return $this->api_endpoint; } - - - /** - * @return string - */ - public function clientId(): string - { - return $this->client_id; - } - - - /** - * @return string - */ - public function clientSecret(): string - { - return $this->client_secret; - } - - - /** - * @return string - */ - public function bnCode(): string - { - return $this->bn_code; - } } diff --git a/PaymentMethods/PayPalCommerce/api/ResponseInspector.php b/PaymentMethods/PayPalCommerce/api/ResponseInspector.php index 8089cc0703f..6f1d6f18fe4 100644 --- a/PaymentMethods/PayPalCommerce/api/ResponseInspector.php +++ b/PaymentMethods/PayPalCommerce/api/ResponseInspector.php @@ -95,7 +95,7 @@ public function validateResponse($response): bool 'error' => $response->get_error_code(), 'message' => sprintf( esc_html__('Response error. Message: %1$s.', 'event_espresso'), - $response->get_error_messages() + $response->get_error_message() ), ] ); diff --git a/PaymentMethods/PayPalCommerce/api/ThirdPartyPayPalApi.php b/PaymentMethods/PayPalCommerce/api/ThirdPartyPayPalApi.php new file mode 100644 index 00000000000..936d63c3984 --- /dev/null +++ b/PaymentMethods/PayPalCommerce/api/ThirdPartyPayPalApi.php @@ -0,0 +1,139 @@ +access_token = $access_token; + $this->partner_client_id = $partner_client_id; + $this->payer_id = $payer_id; + $this->bn_code = $bn_code; + } + + + /** + * Send an API request. + * + * @param array $body_parameters + * @param string $endpoint + * @param string $method + * @param array $headers + * @return Object|array + */ + public function sendRequest(array $body_parameters, string $endpoint, string $method = 'POST', array $headers = []) + { + $request_parameters = $this->getRequestParameters($body_parameters, $method, $headers); + return $this->response($endpoint, $request_parameters); + } + + + /** + * Build the request parameters. + * + * @param array $body_parameters + * @param string $method + * @param array $headers + * @return array + */ + private function getRequestParameters(array $body_parameters, string $method, array $headers): array + { + $request_parameters = [ + 'method' => $method, + ]; + $default_headers = [ + 'User-Agent' => sanitize_text_field($_SERVER['HTTP_USER_AGENT']), + 'PayPal-Partner-Attribution-Id' => $this->bnCode(), + 'Content-Type' => 'application/json', + 'Authorization' => 'Bearer ' . $this->accessToken(), + ]; + // If we have merchant credentials then we are onboard and can do requests on behalf of the seller. + if ($this->partner_client_id && $this->payer_id) { + $assertion1 = [ + 'alg' => 'none', + ]; + $assertion2 = [ + 'iss' => $this->partner_client_id, + 'payer_id' => $this->payer_id, + ]; + $default_headers['PayPal-Auth-Assertion'] = base64_encode(json_encode($assertion1, JSON_HEX_APOS)) . '.' . + base64_encode(json_encode($assertion2, JSON_HEX_APOS)) . '.'; + } + $request_parameters['headers'] = array_merge($default_headers, $headers); + // Add body if this is a POST request. + if ($body_parameters && ($method === 'POST' || $method === 'PUT')) { + $request_parameters['body'] = json_encode($body_parameters); + } + return $request_parameters; + } + + + /** + * @return string + */ + public function accessToken(): string + { + return $this->access_token; + } + + + /** + * @return string + */ + public function bnCode(): string + { + return $this->bn_code; + } +} diff --git a/PaymentMethods/PayPalCommerce/api/clients/ClientToken.php b/PaymentMethods/PayPalCommerce/api/clients/ClientToken.php new file mode 100644 index 00000000000..b046407ff4d --- /dev/null +++ b/PaymentMethods/PayPalCommerce/api/clients/ClientToken.php @@ -0,0 +1,76 @@ +request_url = $this->request_url . "/generate-token"; + } + + + /** + * Get the onboarding status and validate it. + * + * @return array + */ + public function getToken(): array + { + // Send GET request. + $response = $this->api->sendRequest([], $this->request_url); + return $this->validateResponse($response); + } + + + /** + * Makes sure that we have received the client token. Returns an error as array if not. + * + * @param array $response + * @return array + */ + public function validateResponse(array $response): array + { + // Could this be an error ? + if (! empty($response['error'])) { + return $response; + } + if (! empty($response['name']) && ! empty($response['message'])) { + return ['error' => $response['name'], 'message' => $response['message']]; + } + // Check the data we received. + if (empty($response[ Domain::API_KEY_CLIENT_TOKEN ])) { + $err_msg = esc_html__('No client token was found in the Client Token request response.', 'event_espresso'); + PayPalLogger::errorLog($err_msg, $response); + return ['error' => 'ONBOARDING_MISSING_CLIENT_TOKEN', 'message' => $err_msg]; + } + return [ + 'valid' => true, + 'client_token' => $response[ Domain::API_KEY_CLIENT_TOKEN ], + 'expires_in' => $response[ Domain::API_KEY_EXPIRES_IN ] + ]; + } +} diff --git a/PaymentMethods/PayPalCommerce/api/clients/ClientsApi.php b/PaymentMethods/PayPalCommerce/api/clients/ClientsApi.php new file mode 100644 index 00000000000..93adefe5c5e --- /dev/null +++ b/PaymentMethods/PayPalCommerce/api/clients/ClientsApi.php @@ -0,0 +1,45 @@ +api = $api; + // Is this a sandbox request. + $api_endpoint = $sandbox_mode + ? 'https://api-m.sandbox.paypal.com/' + : 'https://api-m.paypal.com/'; + $this->request_url = $api_endpoint . 'v1/identity'; + } +} diff --git a/PaymentMethods/PayPalCommerce/api/orders/CaptureOrder.php b/PaymentMethods/PayPalCommerce/api/orders/CaptureOrder.php index 7a7d6893ca8..481ab14bab2 100644 --- a/PaymentMethods/PayPalCommerce/api/orders/CaptureOrder.php +++ b/PaymentMethods/PayPalCommerce/api/orders/CaptureOrder.php @@ -25,14 +25,14 @@ class CaptureOrder extends OrdersApi * * @var string */ - protected $currency_code; + protected string $currency_code; /** * Transaction this order is for. * * @var EE_Transaction */ - protected $transaction; + protected EE_Transaction $transaction; /** @@ -55,7 +55,6 @@ public function __construct(PayPalApi $api, EE_Transaction $transaction, string * Capture payment for PayPal Order. * * @return array - * @throws EE_Error */ public function capture(): array { diff --git a/PaymentMethods/PayPalCommerce/api/orders/CreateOrder.php b/PaymentMethods/PayPalCommerce/api/orders/CreateOrder.php index b1eabac6b5d..6ccc4ce86ca 100644 --- a/PaymentMethods/PayPalCommerce/api/orders/CreateOrder.php +++ b/PaymentMethods/PayPalCommerce/api/orders/CreateOrder.php @@ -5,7 +5,6 @@ use EE_Error; use EE_Line_Item; use EE_Transaction; -use EEM_State; use EventEspresso\core\domain\services\validation\email\strategies\Basic; use EventEspresso\core\services\request\sanitizers\RequestSanitizer; use EventEspresso\PaymentMethods\PayPalCommerce\api\PayPalApi; @@ -15,6 +14,7 @@ /** * Class CreateOrder + * * Generates and sends a Create Order request using PayPal API. * * @package Event Espresso @@ -49,21 +49,21 @@ class CreateOrder extends OrdersApi * * @var string */ - protected $currency_code; + protected string $currency_code; /** * Billing info. * * @var array */ - protected $billing_info; + protected array $billing_info; /** * Transaction this order is for. * * @var EE_Transaction */ - protected $transaction; + protected EE_Transaction $transaction; /** @@ -88,10 +88,12 @@ public function __construct(PayPalApi $api, EE_Transaction $transaction, array $ * @param array $billing_info * @return void */ - public function sanitizeRequestParameters(array $billing_info) + public function sanitizeRequestParameters(array $billing_info): void { - $sanitizer = new RequestSanitizer(new Basic()); - foreach ($billing_info as $item => $value) { + $email_validator = new Basic(); + $sanitizer = new RequestSanitizer($email_validator); + foreach ($billing_info as $item => $value) + { $this->billing_info[ $item ] = $sanitizer->clean($value); } } @@ -123,16 +125,13 @@ public function create(): array protected function getParameters(): array { $registrant = $this->transaction->primary_registration(); + $attendee = $registrant->attendee(); $event = $registrant->event(); - $description = $event->name() ?? esc_html__('Tickets for an event', 'event_espresso'); - $state = EEM_State::instance()->get_col( - [ - ['STA_ID' => $this->billing_info['bill_state']], - 'limit' => 1, - ], - 'STA_abbrev' - )[0]; - $params = [ + $description = $event->name() ?: sprintf( + esc_html__('Tickets for an event at %1$s', 'event_espresso'), + get_bloginfo('name') + ); + return [ 'intent' => 'CAPTURE', 'purchase_units' => [ [ @@ -151,28 +150,14 @@ protected function getParameters(): array 'user_action' => 'PAY_NOW', ], 'payer' => [ - 'email_address' => $this->billing_info['bill_email'], + 'email_address' => $attendee->email(), 'name' => [ - 'given_name' => substr($this->billing_info['bill_first_name'], 0, 139), - 'surname' => substr($this->billing_info['bill_last_name'], 0, 139), + 'given_name' => $attendee->fname(), + 'surname' => $attendee->lname(), ], - 'address' => [ - 'country_code' => $this->billing_info['bill_country'], - 'address_line_1' => substr($this->billing_info['bill_address'], 0, 299), - 'admin_area_1' => $state ?? '', - 'admin_area_2' => substr($this->billing_info['bill_city'], 0, 119), - 'postal_code' => substr($this->billing_info['bill_zip'], 0, 59), - ], ], ]; - if (isset($this->billing_info['bill_address_2']) && $this->billing_info['bill_address_2']) { - $params['payer']['address']['address_line_2'] = substr($this->billing_info['bill_address_2'], 0, 299); - } - if (isset($this->billing_info['bill_phone']) && $this->billing_info['bill_phone']) { - $params['payer']['phone_number'] = $this->billing_info['bill_phone']; - } - return $params; } @@ -192,7 +177,7 @@ protected function getLineItems(): array if ($line_item instanceof EE_Line_Item && $line_item->OBJ_type() !== 'Promotion') { $item_money = $line_item->unit_price(); $li_description = $line_item->desc() ?? esc_html__('Event Ticket', 'event_espresso'); - $line_items [] = [ + $line_items [] = [ 'name' => substr(wp_strip_all_tags($line_item->name()), 0, 126), 'quantity' => $line_item->quantity(), 'description' => substr(wp_strip_all_tags($li_description), 0, 125), @@ -223,7 +208,7 @@ protected function getLineItems(): array * @return void * @throws EE_Error|ReflectionException */ - protected function countTaxTotal() + protected function countTaxTotal(): void { // List taxes. $this->tax_total = 0; @@ -278,7 +263,7 @@ public function validateOrder($response, $parameters): array [$this->request_url, $parameters, $response], $this->transaction->payment_method() ); - } catch (EE_Error|ReflectionException $e) { + } catch (EE_Error | ReflectionException $e) { // Just continue. } return [ diff --git a/PaymentMethods/PayPalCommerce/api/orders/OrdersApi.php b/PaymentMethods/PayPalCommerce/api/orders/OrdersApi.php index 06712f1548c..284cbc2d812 100644 --- a/PaymentMethods/PayPalCommerce/api/orders/OrdersApi.php +++ b/PaymentMethods/PayPalCommerce/api/orders/OrdersApi.php @@ -18,12 +18,12 @@ abstract class OrdersApi /** * @var PayPalApi */ - protected $api; + protected PayPalApi $api; /** * @var string */ - protected $request_url; + protected string $request_url; /** diff --git a/PaymentMethods/PayPalCommerce/api/partners/TrackSellerOnboarding.php b/PaymentMethods/PayPalCommerce/api/partners/TrackSellerOnboarding.php index 250b3fd09c3..60a633ae949 100644 --- a/PaymentMethods/PayPalCommerce/api/partners/TrackSellerOnboarding.php +++ b/PaymentMethods/PayPalCommerce/api/partners/TrackSellerOnboarding.php @@ -2,8 +2,8 @@ namespace EventEspresso\PaymentMethods\PayPalCommerce\api\partners; -use EE_Error; use EventEspresso\PaymentMethods\PayPalCommerce\api\PayPalApi; +use EventEspresso\PaymentMethods\PayPalCommerce\domain\Domain; use EventEspresso\PaymentMethods\PayPalCommerce\tools\logging\PayPalLogger; /** @@ -17,26 +17,19 @@ */ class TrackSellerOnboarding extends PartnersApi { - /** - * Partner access token. - * - * @var int - */ - protected $access_token; - /** * Partner ID. * - * @var int + * @var string */ - protected $partner_id; + protected string $partner_id; /** * Seller ID. * - * @var int + * @var string */ - protected $seller_id; + protected string $seller_id; /** @@ -64,7 +57,6 @@ public function __construct( * Get the onboarding status and validate it. * * @return array - * @throws EE_Error */ public function isValid(): array { @@ -79,25 +71,27 @@ public function isValid(): array * * @param array $response * @return array - * @throws EE_Error */ public function validateStatus(array $response): array { if (! empty($response['error'])) { return $response; } + if (! empty($response['name']) && ! empty($response['message'])) { + return ['error' => $response['name'], 'message' => $response['message']]; + } // Check the data we received. if ( - empty($response['merchant_id']) - || ! isset($response['payments_receivable']) - || ! isset($response['primary_email_confirmed']) + empty($response[ Domain::API_PARAM_TRACK_MERCHANT_ID ]) + || ! isset($response[ Domain::API_PARAM_PAYMENTS_RECEIVABLE ]) + || ! isset($response[ Domain::API_PARAM_PRIM_EMAIL_CONFIRMED ]) ) { $err_msg = esc_html__('Missing required data for validating the onboarding status.', 'event_espresso'); PayPalLogger::errorLog($err_msg, $response); return ['error' => 'ONBOARDING_MISSING_REQUIRED_DATA', 'message' => $err_msg]; } // Now validate the onboarding status. - if (! $response['payments_receivable']) { + if (! $response[ Domain::API_PARAM_PAYMENTS_RECEIVABLE ]) { $err_msg = esc_html__( 'Your Account has been limited by PayPal. Please check your PayPal account inbox for an email from PayPal to determine the next steps for this.', 'event_espresso' @@ -105,11 +99,14 @@ public function validateStatus(array $response): array PayPalLogger::errorLog($err_msg, $response); return ['error' => 'ONBOARDING_LIMITED_BY_PAYPAL', 'message' => $err_msg]; } - if (! $response['primary_email_confirmed']) { + if (! $response[ Domain::API_PARAM_PRIM_EMAIL_CONFIRMED ]) { $err_msg = esc_html__('Email address not confirmed. Please confirm your email address.', 'event_espresso'); PayPalLogger::errorLog($err_msg, $response); return ['error' => 'ONBOARDING_CONFIRM_EMAIL', 'message' => $err_msg]; } - return ['valid' => true]; + return [ + 'valid' => true, + 'response' => $response, + ]; } } diff --git a/PaymentMethods/PayPalCommerce/assets/css/eea-paypal-checkout.css b/PaymentMethods/PayPalCommerce/assets/css/eea-paypal-checkout.css new file mode 100644 index 00000000000..acca4cd13cb --- /dev/null +++ b/PaymentMethods/PayPalCommerce/assets/css/eea-paypal-checkout.css @@ -0,0 +1,174 @@ +.paypal-button-container { + border-radius: 5px; + background-color: #FFFFFF; + padding: 20px; + max-width: 760px; + width: 100%; + margin: 0 auto; +} +.card_container { + border-radius: 5px; + background-color: #FFFFFF; + padding: 20px; + max-width: 760px; + width: 100%; + margin: 0 auto; +} +.card_field{ + width: 100%; + padding: 12px; + border: 1px solid #ccc; + border-radius: 4px; + box-sizing: border-box; + margin-top: 6px; + margin-bottom: 16px; + resize: vertical; + height:40px; + background:white; + font-size:17px; + color:#3a3a3a; + font-family:helvetica, tahoma, calibri, sans-serif; +} +.card_field_50{ + width: 50%; + padding: 12px; + border: 1px solid #ccc; + border-radius: 4px; + box-sizing: border-box; + margin-top: 6px; + margin-bottom: 16px; + resize: vertical; + height:40px; + background:white; + font-size:17px; + color:#3a3a3a; + font-family:helvetica, tahoma, calibri, sans-serif; +} +.card_field_75{ + width: 75%; + padding: 12px; + border: 1px solid #ccc; + border-radius: 4px; + box-sizing: border-box; + margin-top: 6px; + margin-bottom: 16px; + resize: vertical; + height:40px; + background:white; + font-size:17px; + color:#3a3a3a; + font-family:helvetica, tahoma, calibri, sans-serif; +} +.row { + display: -ms-flexbox; /* IE10 */ + display: flex; + -ms-flex-wrap: wrap; /* IE10 */ + flex-wrap: wrap; + margin: 0 -16px; +} +.col-25 { + -ms-flex: 25%; /* IE10 */ + flex: 25%; +} +.col-50 { + -ms-flex: 50%; /* IE10 */ + flex: 50%; +} +input[type=text], select, textarea { + width: 100%; + padding: 12px; + border: 1px solid #ccc; + border-radius: 4px; + box-sizing: border-box; + margin-top: 6px; + margin-bottom: 16px; + resize: vertical; + height:40px; + background:white; + font-size:17px; + color:#3a3a3a; + font-family:helvetica, tahoma, calibri, sans-serif; +} +input[type=submit] { + background-color: #4CAF50; + color: white; + padding: 12px 20px; + border: none; + border-radius: 4px; + cursor: pointer; +} +.message_container { + border-radius: 5px; + background: #FFFFFF; + font-size: 13px; + font-family: monospace; + padding: 20px; +} +#loading { + width: 100%; + height: 100%; + top: 0; + left: 0; + position: fixed; + display: block; + opacity: 0.7; + background-color: #fff; + z-index: 99; + text-align: center; +} +#loading-image { + position: absolute; + z-index: 15; + top: 50%; + left: 50%; + margin: -100px 0 0 -150px; +} +.spinner { + position: fixed; + top: 50%; + left: 50%; + margin-left: -50px; /* half width of the spinner gif */ + margin-top: -50px; /* half height of the spinner gif */ + text-align:center; + z-index: 1234; + overflow: auto; + width: 100px; /* width of the spinner gif */ + height: 102px; /* height of the spinner gif +2px to fix IE8 issue */ +} +.eep-ppc-btn-submit-dv { + text-align: right; + margin: 30px 20px; +} +.test-credit-cards-info-pg { + padding-bottom: 30px; +} +.eep-ppc-payment-buttons { + padding-top: 30px; +} +.eep-ppc-separator-holder { + width: 100%; + display: flex; + align-items: center; + justify-content: center; + padding: 30px; +} +.eep-ppc-separator-line { + background: #c7c7c7; + height: 1px; +} +.eep-ppc-separator-text { + text-align: center; + text-align: -webkit-center; +} +.eep-left-floating { + float: left; + width: 45%; +} +.eep-mid-floating { + float: left; + margin: 0 auto; +} +.eep-right-floating { + float: right; + width: 45%; +} diff --git a/PaymentMethods/PayPalCommerce/assets/css/eea-paypal-onboard.css b/PaymentMethods/PayPalCommerce/assets/css/eea-paypal-onboard.css index 7421a7a717d..377ce71755a 100644 --- a/PaymentMethods/PayPalCommerce/assets/css/eea-paypal-onboard.css +++ b/PaymentMethods/PayPalCommerce/assets/css/eea-paypal-onboard.css @@ -29,15 +29,15 @@ background-size: 22px 22px; } - +.eea-onboard-section .eea-paypal-onboard-trigger-btn { + display: none !important; +} /** PayPal Commerce images **/ .eea-paypal-onboard-btn span:before { background-image: url('https://www.paypalobjects.com/paypal-ui/logos/svg/paypal-mark-color.svg'); } - - /** Connection information text **/ .eea-paypal-offboard-ico { height: 25px; @@ -56,9 +56,61 @@ font-weight: bold; } - /** Disconnect dialog **/ .ee-admin-dialog-container .eea-paypal-dialog-cancel, .ee-admin-dialog-container .eea-paypal-dialog-ok { margin: 20px 10px 0 10px; float: right; } + +/** Processing Mask **/ +.eep-ppc-processing-mask { + z-index: 9999990; + position: fixed; + margin: auto; + top: 0; + left: 0; + bottom: 0; + right: 0; + width: 100%; + height: 100%; + background-color: black; + opacity: 0.82; +} + +.eep-ppc-processing-message { + z-index: 9999991; + position: fixed; + align-self: center; + width: 20em; + height: 6em; + margin: auto; + top: 0; + left: 0; + bottom: 0; + right: 0; + color: #ADB3B6FF; + text-align: center; + background: rgb(17 17 17 / 36%); + padding: 20px; + border-radius: 10px; +} + +.eep-ppc-pm-types { + margin: 10px 0 10px; +} + +.eep-ppc-pm-types .ee-checkbox-label-after, +.eea-ppc-express-checkout-img .ee-checkbox-label-after { + margin-block-start: 0 !important; +} + +.eea-ppc-ppcp-img { + width: 140px; +} +.eea-ppc-ppcp-img, .eea-ppc-express-checkout-img { + padding: 10px; +} + +.eep-ppc-dialog-yes-no { + text-align: right; +} diff --git a/PaymentMethods/PayPalCommerce/assets/js/eea-paypal-onboarding.js b/PaymentMethods/PayPalCommerce/assets/js/eea-paypal-onboarding.js index 8005d90abb5..0c27d13e795 100644 --- a/PaymentMethods/PayPalCommerce/assets/js/eea-paypal-onboarding.js +++ b/PaymentMethods/PayPalCommerce/assets/js/eea-paypal-onboarding.js @@ -8,15 +8,23 @@ jQuery(document).ready(function ($) { * signup_link: string, * localized: array, * onboard_btn: object, + * onboard_trigger_btn: object, * offboard_btn: object, * form: object, + * onboard_window: object, * onboard_section: object, * offboard_section: object, * sandbox_select: object, + * onboard_sandbox_section: object, * processing_icon_name: string, * processing_icon: object, * clear_metadata_btn: object, + * pp_pm_slug_holder: object, * pp_seller_section: object, + * connect_ok_id: string, + * connect_cancel_id: string, + * disconnect_ok_id: string, + * disconnect_cancel_id: string, * }} * * @namespace eeaPPOnboardParameters @@ -38,14 +46,19 @@ jQuery(document).ready(function ($) { * debug_is_on_notice: string, * debug_is_off_notice: boolean, * refresh_alert: string, + * connect_dialog: string, * disconnect_dialog: string, + * processing_mask: string, + * supported_countries: array, * }} */ function EeaPayPalOnboarding(pm_slug) { this.slug = pm_slug; this.signup_link = ''; + this.onboard_window = null; this.processing_icon_name = 'espresso-ajax-loading'; this.onboard_btn = $('#eea_paypal_onboard_btn_' + pm_slug); + this.onboard_trigger_btn = $('#eea_paypal_onboard_trigger_btn_' + pm_slug); this.offboard_btn = $('#eea_paypal_offboard_btn_' + pm_slug); this.onboard_section = $('#eea_paypal_onboard_section_' + pm_slug); this.offboard_section = $('#eea_paypal_offboard_section_' + pm_slug); @@ -55,6 +68,15 @@ jQuery(document).ready(function ($) { this.pp_pm_slug_holder = $('#eea_paypal_pm_slug'); this.clear_metadata_btn = $('#eea_clear_metadata_' + pm_slug); this.pp_seller_section = $('#eea_paypal_seller_id_' + pm_slug); + this.connect_ok_id = '#eea_ppc_connect_ok_' + pm_slug; + this.connect_cancel_id = '#eea_ppc_connect_cancel_' + pm_slug; + this.disconnect_ok_id = '#eep_ppc_disconnect_ok_' + pm_slug; + this.disconnect_cancel_id = '#eep_ppc_disconnect_cancel_' + pm_slug; + this.pp_country_select_id = '#eep_ppc_country_' + pm_slug; + this.checkout_type_select_id = '#eep_ppc_checkout_type_' + pm_slug; + this.express_checkout_type_id = this.checkout_type_select_id + '-express_checkout'; + this.ppcp_checkout_type_id = this.checkout_type_select_id + '-ppcp'; + this.ppcp_checkout_type_lbl = this.ppcp_checkout_type_id + '-lbl'; /** @@ -103,15 +125,10 @@ jQuery(document).ready(function ($) { const this_pm = this; // Update button text on page load, depending on the PM sandbox mode. this_pm.toggleBtnText(this_pm, this_pm.sandbox_select.val()); - // Listen for the sandbox mode change. - this.sandbox_select.on('change', function () { + this_pm.sandbox_select.on('change', function () { const sandbox_mode = this_pm.sandbox_select.val(); - // Disable the Connect button for the time the URL is being updated. Save current URL. - this_pm.signup_link = this_pm.onboard_btn.attr('href'); - this_pm.onboard_btn.removeAttr('href'); // Update the onboarding URL if the debug mode was changed. - this_pm.sendRequest('eeaPpGetOnboardingUrl', {}, this_pm.updateOnboardingUrl, false); this_pm.toggleBtnText(this_pm, sandbox_mode); }); }; @@ -127,48 +144,102 @@ jQuery(document).ready(function ($) { this.onboard_btn.on('click', function (event) { this_pm.pp_pm_slug_holder.text(this_pm.slug); this_pm.sandbox_mode = this_pm.sandbox_select.val(); + this_pm.preOnboardingForm(); }); }; /** - * Hide the EE dialog. - * @return {void} + * Shows the pre onboarding/options form. + * @function */ - this.hideDialog = function () { - overlay.fadeOut('fast'); - eedialog.fadeOut('fast'); - }; + this.preOnboardingForm = function () { + position_overlay(true); + position_dialog(2, false); + dialogHelper.addContent(eeaPPOnboardParameters.connect_dialog); + // Pre onboarding form setup. + this.preOnboardingFormSetup(); + // Onboarding form listeners. + this.onboardFormListeners(); + } /** - * Show a dialog with the disconnect warning. - * @return {boolean} + * Set up the pre-onboarding form. + * @function */ - this.confirmDisconnect = function () { - const this_pm = this; - position_overlay(false); - position_dialog(4, false); - dialogHelper.addContent(eeaPPOnboardParameters.disconnect_dialog); - $('#eea_paypal_dialog_ok_' + this_pm.slug).on('click', function() { - this_pm.hideDialog(); - const btn_container = $(this).closest('tr'); - if (btn_container) { - this_pm.sandbox_mode = this_pm.sandbox_select.val(); - this_pm.sendRequest('eeaPpOffboard', {}, this_pm.reloadPage, false); - } else { - console.error(eeaPPOnboardParameters.unknown_container); - } - return true; - }); - $('#eea_paypal_dialog_cancel_' + this_pm.slug).on('click', function() { + this.preOnboardingFormSetup = function () { + $(this.express_checkout_type_id).attr('disabled', true); + } + + + /** + * Onboard/options form listeners. + * @function + */ + this.onboardFormListeners = function () { + let this_pm = this; + // Cancel. + $(this.connect_cancel_id).on('click', function() { this_pm.hideDialog(); return false; }); - overlay.on('click', function() { - this_pm.hideDialog(); - return false; + // Continue the onboarding. + $(this.connect_ok_id).on('click', function() { + this_pm.startOnboarding(); }); + // Change country select. + $(this.pp_country_select_id).on('change', function() { + this_pm.validateCountry(); + }); + } + + + /** + * Start the onboarding process. + * @return {void} + */ + this.startOnboarding = function () { + let selected_country = $(this.pp_country_select_id).val(); + let checkout_type = 'EXPRESS_CHECKOUT'; + if ($(this.ppcp_checkout_type_id).is(':checked')) { + checkout_type = 'PPCP'; + } + // Request the onboarding URL and then initiate PayPal onboarding flow. + const url_parameters = new URLSearchParams(window.location.search); + const request_params = { + wp_nonce: url_parameters.get('_wpnonce'), + country: selected_country, + checkout_type: checkout_type + }; + this.sendRequest('eeaPpGetOnboardingUrl', request_params, this.initiatePayPalOnboarding, false); + }; + + + /** + * Validate the selected country. + * @return {void} + */ + this.validateCountry = function () { + let selected_country = $(this.pp_country_select_id).val(); + if ($.inArray(selected_country, eeaPPOnboardParameters.supported_countries) === -1) { + // Do not allow PPCP pm to be selected if there is no support for selected country. + $(this.ppcp_checkout_type_id).prop('checked', false); + $(this.ppcp_checkout_type_id).attr('disabled', true); + $(this.ppcp_checkout_type_lbl).fadeOut('fast'); + } else { + $(this.ppcp_checkout_type_lbl).show(); + $(this.ppcp_checkout_type_id).removeAttr('disabled'); + } + } + + + /** + * Hide the EE dialog. + * @return {void} + */ + this.hideDialog = function () { + dialogHelper.closeModal(); }; @@ -199,33 +270,32 @@ jQuery(document).ready(function ($) { /** - * Simply reloads the page. + * Trigger a click to initiate PayPal. * @param this_pm * @param response * @function */ - this.reloadPage = function (this_pm, response) { - window.do_before_admin_page_ajax(); - // Reload the page when disconnected. - // Seems to be required for PP scripts. If not refreshed the signup link is opened in a new window or tab. - location.reload(); - }; + this.initiatePayPalOnboarding = function (this_pm, response) { + if (typeof response.signup_link !== 'undefined') { + this_pm.onboard_trigger_btn.attr('href', response.signup_link); + this_pm.hideDialog(); + this_pm.processing_icon.fadeOut('fast'); + this_pm.onboard_trigger_btn[0].click(); + } + } /** - * Change the onboarding URL, sandbox vs live. + * Simply reloads the page. * @param this_pm * @param response * @function */ - this.updateOnboardingUrl = function (this_pm, response) { + this.reloadPage = function (this_pm, response) { window.do_before_admin_page_ajax(); - let signup_link = this_pm.signup_link; - if (typeof response.signup_link !== 'undefined') { - signup_link = response.signup_link; - } - this_pm.onboard_btn.attr('href', signup_link); - this_pm.processing_icon.fadeOut('fast'); + // Reload the page when disconnected. + // Seems to be required for PP scripts. If not refreshed the signup link is opened in a new window or tab. + location.reload(); }; @@ -282,7 +352,7 @@ jQuery(document).ready(function ($) { }, success: function (response) { ppc_onboarding_processing = false; - const is_valid = this_pm.checkForErrors(response); + const is_valid = this_pm.checkForErrors(response, request_action === 'eeaPpGetOnboardingUrl'); if (is_valid && typeof callback !== 'undefined' && callback) { // Run the callback if there are no errors. callback(this_pm, response); @@ -293,7 +363,7 @@ jQuery(document).ready(function ($) { }, error: function (jqXHR, details, error) { ppc_onboarding_processing = false; - this_pm.requestError(jqXHR, error, details, this_pm); + this_pm.requestError(jqXHR, error, details, this_pm, request_action === 'eeaPpGetOnboardingUrl'); }, }); }; @@ -304,21 +374,48 @@ jQuery(document).ready(function ($) { * @function */ this.toggleBtnText = function (this_pm, sandbox_mode) { - const btn_text_span = this_pm.onboard_btn.find('span')[0]; - // Change button text. - if (btn_text_span) { - if (sandbox_mode === '1') { - $(btn_text_span).text(eeaPPOnboardParameters.sandbox_btn_text); - } else { - $(btn_text_span).text(eeaPPOnboardParameters.onboard_btn_text); - } + if (sandbox_mode === '1') { + this_pm.onboard_btn.text(eeaPPOnboardParameters.sandbox_btn_text); + } else { + this_pm.onboard_btn.text(eeaPPOnboardParameters.onboard_btn_text); } // Also update sandbox text. this.updateConnectionInfo(this_pm); }; + /** + * Show a dialog with the disconnect warning. + * @return {boolean} + */ + this.confirmDisconnect = function () { + const this_pm = this; + position_overlay(false); + position_dialog(3, false); + dialogHelper.addContent(eeaPPOnboardParameters.disconnect_dialog); + $(this_pm.disconnect_ok_id).on('click', function() { + this_pm.hideDialog(); + const btn_container = $(this).closest('tr'); + if (btn_container) { + this_pm.sandbox_mode = this_pm.sandbox_select.val(); + this_pm.sendRequest('eeaPpOffboard', {}, this_pm.reloadPage, false); + } else { + console.error(eeaPPOnboardParameters.unknown_container); + } + return true; + }); + $(this.disconnect_cancel_id).on('click', function() { + this_pm.hideDialog(); + return false; + }); + overlay.on('click', function() { + this_pm.hideDialog(); + return false; + }); + }; + + /** * Show a dialog with message. * @param error @@ -327,7 +424,7 @@ jQuery(document).ready(function ($) { this.showAlert = function (error) { const this_pm = this; position_overlay(false); - position_dialog(4, false); + position_dialog(3, false); dialogHelper.addContent('Error: ' + error); overlay.on('click', function() { this_pm.hideDialog(); @@ -338,16 +435,21 @@ jQuery(document).ready(function ($) { /** * Check for errors in the response. * @param response + * @param close_window * @return {boolean} */ - this.checkForErrors = function (response) { + this.checkForErrors = function (response, close_window) { if (response === null || response.error) { + if (close_window) { + this.onboard_window.close(); + } let error = eeaPPOnboardParameters.request_error; if (response !== null && response.message) { error = response.message; } console.error(error); this.showAlert(error); + this.processing_icon.fadeOut('fast'); return false; } return true; @@ -431,7 +533,7 @@ jQuery(document).ready(function ($) { * Display or log the error. * @function */ - this.requestError = function (response, err, details, this_pm) { + this.requestError = function (response, err, details, this_pm, close_window) { this_pm.processing_icon.fadeOut('fast'); let error = eeaPPOnboardParameters.error_response; if (details) { @@ -439,6 +541,9 @@ jQuery(document).ready(function ($) { } console.error(error); this_pm.showAlert(error); + if (close_window) { + this_pm.onboard_window.close(); + } }; } @@ -448,22 +553,3 @@ jQuery(document).ready(function ($) { paypal_pms[slug].initialize(); } }); - -// Default callback for PayPal to trigger when onboarding was a success. -function onboardedCallback(authCode, sharedId) { - // Prevent double callback triggers (which did happen frequently). - if (ppc_onboarding_processing) { - return; - } - ppc_onboarding_processing = true; - const pm_slug = document.getElementById('eea_paypal_pm_slug').textContent; - const request_data = { - authCode: authCode, - sharedId: sharedId - }; - paypal_pms[pm_slug].sendRequest('eeaPpGetSellerAccessToken', request_data, false, true); - // Close the window. - if (typeof PAYPAL !== 'undefined') { - PAYPAL.apps.Signup.MiniBrowser.closeFlow(); - } -} diff --git a/PaymentMethods/PayPalCommerce/assets/js/paypal-commerce-payments.js b/PaymentMethods/PayPalCommerce/assets/js/paypal-commerce-payments.js index 1587208aa8c..a91a0606cd8 100644 --- a/PaymentMethods/PayPalCommerce/assets/js/paypal-commerce-payments.js +++ b/PaymentMethods/PayPalCommerce/assets/js/paypal-commerce-payments.js @@ -18,12 +18,14 @@ jQuery(document).ready(function ($) { * @namespace paypal * @type {{ * paypal: object, + * hostedFields: Object, * }} + * * @namespace eeaPPCommerceParameters * @type {{ * pm_versions: array, - * client_id: string, * payment_currency: string, + * checkout_type: string, * currency_sign: string, * pp_order_id: string, * pp_order_nonce: string, @@ -31,6 +33,7 @@ jQuery(document).ready(function ($) { * org_country: string, * decimal_places: int, * site_name: string, + * active_states: array, * no_spco_error: string, * no_pm_error: string, * browser_not_supported: string, @@ -41,6 +44,9 @@ jQuery(document).ready(function ($) { * payment_error: string, * no_order_id: string, * general_pp_error: string, + * hf_render_error: string, + * pm_capture_error: string, + * not_acdc_eligible: string, * }} */ function EeaPayPalCheckout(pm_slug) { @@ -49,7 +55,6 @@ jQuery(document).ready(function ($) { this.transaction = {}; this.spco = window.SPCO || null; - /** * Initial setup. * @function @@ -59,13 +64,13 @@ jQuery(document).ready(function ($) { // Ensure that the SPCO has loaded. if (typeof this.spco == null) { this.hidePm(); - this.throwError(eeaPPCommerceParameters.no_spco_error, '', false); + this.throwError(eeaPPCommerceParameters.no_spco_error, '', this.slug, false); return false; } // Ensure that PayPal scripts loaded. if (typeof paypal === 'undefined') { this.hidePm(); - this.throwError(eeaPPCommerceParameters.no_pm_error, ''); + this.throwError(eeaPPCommerceParameters.no_pm_error, '', this.slug); return false; } // Prevent loading on registration page. @@ -74,7 +79,13 @@ jQuery(document).ready(function ($) { } // PayPal components will require re-setup even if PM already initialized. if (this.initialized) { - this.setupPayPal(); + // PayPal buttons or Hosted Fields ? + if (eeaPPCommerceParameters.checkout_type !== 'express_checkout') { + this.setupHostedFields(); + } + if (eeaPPCommerceParameters.checkout_type !== 'ppcp') { + this.setupPayPalButtons(); + } this.disableSubmitButtons(); return true; } @@ -96,42 +107,35 @@ jQuery(document).ready(function ($) { if (! this.pp_order_id || this.pp_order_id.length < 1) { this.pp_order_id = eeaPPCommerceParameters.pp_order_id; } - // this.button_container_id = 'eea-' + pm_slug + '-payment-buttons'; - this.button_container_id = 'eea-paypal-commerce-payment-buttons'; - this.payment_button_container = $('#' + this.button_container_id); + this.button_container_id = '#eep-' + pm_slug + '-payment-buttons'; this.payment_method_selector = $('#ee-available-payment-method-inputs'); this.payment_method_select_lbl = $('#ee-available-payment-method-inputs-' + pm_slug + '-lbl'); this.payment_method_info_div = $('#spco-payment-method-info-' + pm_slug); this.billing_form = $('#pp-' + pm_slug + '-billing-form'); - this.payment_form = this.payment_button_container.parents('form:first'); // PP order details this.order_nonce_input = $('#eea-' + pm_slug + '-order-nonce'); this.order_id_input = $('#eea-' + pm_slug + '-order-id'); this.order_status_input = $('#eea-' + pm_slug + '-order-status'); this.order_amount_input = $('#eea-' + pm_slug + '-order-amount'); - // Billing data. - if (typeof this.billing_form !== 'undefined') { - this.bill_first_name = this.billing_form.find( - 'input[id*="billing-form-first-name"]:visible'); - this.bill_last_name = this.billing_form.find( - 'input[id*="billing-form-last-name"]:visible'); - this.bill_email = this.billing_form.find( - 'input[id*="billing-form-email"]:visible'); - this.bill_address = this.billing_form.find( - 'input[id*="billing-form-address"]:visible'); - this.bill_address_2 = this.billing_form.find( - 'input[id*="billing-form-address2"]:visible'); - this.bill_city = this.billing_form.find( - 'input[id*="billing-form-city"]:visible'); - this.bill_state = this.billing_form.find( - 'select[id*="billing-form-state"]:visible'); - this.bill_country = this.billing_form.find( - 'select[id*="billing-form-country"]:visible'); - this.bill_zip = this.billing_form.find( - 'input[id*="billing-form-zip"]:visible'); - this.bill_phone = this.billing_form.find( - 'input[id*="billing-form-phone"]:visible'); - } + // PP credit card fields + this.card_input_id = '#' + this.slug + '-card-number'; + this.cvv_input_id = '#' + this.slug + '-cvv'; + this.expiration_date_input_id = '#' + this.slug + '-expiration-date'; + this.card_holder_name_input_id = '#' + this.slug + '-card-holder-name'; + this.type_separator_id = '#eep-ppc-separator-holder'; + this.card_fields_class = '.' + this.slug + '-card-fields'; + this.payment_form = this.order_nonce_input.parents('form:first'); + this.new_state_form_id = '#new_state_micro_form'; + this.acdc_submit_btn_dv = '#' + this.slug + '-submit-dv'; + // Billing inputs. + this.bill_address = $('#pp-' + this.slug + '-billing-form-address'); + this.bill_address_2 = $('#pp-' + this.slug + '-billing-form-address2'); + this.bill_city = $('#pp-' + this.slug + '-billing-form-city'); + this.bill_state = $('#pp-' + this.slug + '-billing-form-state'); + this.bill_country = $('#pp-' + this.slug + '-billing-form-country'); + this.bill_zip = $('#pp-' + this.slug + '-billing-form-zip'); + this.bill_phone = $('#pp-' + this.slug + '-billing-form-phone'); + this.add_new_state = $('#pp-' + this.slug + '-billing-form-nsmf_add_new_state'); } @@ -170,8 +174,13 @@ jQuery(document).ready(function ($) { } // Save transaction data. this_pm.transaction = response; - // Now we can set up PayPal buttons. - this_pm.setupPayPal(); + // Now we can set up PayPal. PayPal buttons or Hosted Fields ? Or both ? + if (eeaPPCommerceParameters.checkout_type !== 'express_checkout') { + this_pm.setupHostedFields(); + } + if (eeaPPCommerceParameters.checkout_type !== 'ppcp') { + this_pm.setupPayPalButtons(); + } this_pm.spco.end_ajax(); return true; }, @@ -188,7 +197,7 @@ jQuery(document).ready(function ($) { * Sets up PayPal payment button. * @function */ - this.setupPayPal = function () { + this.setupPayPalButtons = function () { const this_pm = this; this_pm.spco.do_before_sending_ajax(); paypal.Buttons({ @@ -196,95 +205,189 @@ jQuery(document).ready(function ($) { layout: 'vertical', color: 'blue', shape: 'rect', - label: 'paypal' - }, - onInit: function (data, actions) { - // actions.disable(); - }, - onClick: function () { - console.log('-- PP onClick:'); - const form_valid = this_pm.payment_form.valid(); - if (!form_valid) { - this_pm.throwError(eeaPPCommerceParameters.form_validation_notice, ''); - return false; - } + label: 'pay' }, // Sets up the transaction when a payment button is clicked. createOrder: function (data, actions) { - this_pm.spco.do_before_sending_ajax(); - console.log('-- PP createOrder:', data, actions); return this_pm.createOrder(); }, // Finalize the transaction after payer approval onApprove: function (data, actions) { - this_pm.spco.do_before_sending_ajax(); - console.log('-- PP onApprove:', data, actions); - return this_pm.captureOrder(data, actions); + this_pm.hideACDCForm(); + return this_pm.captureOrder(data); }, onError: function (error) { - console.log('-- PP onError:', error); - console.error(eeaPPCommerceParameters.general_pp_error); + console.error(eeaPPCommerceParameters.general_pp_error, error); if (String(error).includes('PAYMENT_ALREADY_DONE')) { // Hide any return to cart buttons, etc. $('.hide-me-after-successful-payment-js').hide(); // Save order ID. - const order_data = { - pp_order_id: this_pm.getOrderId(), - pp_order_nonce: this_pm.getOrderNonce(), - }; - this_pm.saveOrderData(order_data); + this_pm.saveOrderInDom(); + this_pm.hideACDCForm(); // Trigger click event on SPCO "Proceed to Next Step" button. this_pm.spco.enable_submit_buttons(); - this_pm.payment_button_container.parents('form:first').find('.spco-next-step-btn').trigger('click'); + this_pm.order_nonce_input.parents('form:first').find('.spco-next-step-btn').trigger('click'); } else { - let message = eeaPPCommerceParameters.payment_error + '; ' + error; - this_pm.throwError(message, this_pm.slug); + let message = eeaPPCommerceParameters.payment_error; + this_pm.throwError(message, error, this_pm.slug); } } - }).render('#' + this.button_container_id); + }).render(this.button_container_id); this_pm.spco.end_ajax(); }; + /** + * Sets up PayPal Hosted Fields. + * @function + */ + this.setupHostedFields = function () { + const this_pm = this; + this_pm.spco.do_before_sending_ajax(); + if (paypal.HostedFields.isEligible()) { + // Renders card fields + paypal.HostedFields.render({ + // Call your server to set up the transaction + createOrder: function () { + return this_pm.createOrder(); + }, + styles: { + '.valid': { + 'color': 'green' + }, + '.invalid': { + 'color': 'red' + } + }, + fields: { + number: { + selector: this_pm.card_input_id, + placeholder: "4111 1111 1111 1111" + }, + cvv: { + selector: this_pm.cvv_input_id, + placeholder: "123" + }, + expirationDate: { + selector: this_pm.expiration_date_input_id, + placeholder: "MM/YY" + } + } + }).then(function (cardFields) { + this_pm.submitCardFieldsListener(cardFields); + }).catch(function (orderData) { + this_pm.throwError( + eeaPPCommerceParameters.hf_render_error + ' ' + JSON.stringify(orderData), + JSON.stringify(orderData), + this_pm.slug + ); + }); + } else { + // Hides card fields if the merchant isn't eligible + this_pm.hideACDCForm(); + this_pm.displayError( + eeaPPCommerceParameters.not_acdc_eligible, + $(this.button_container_id) + ); + // And allow Express checkout. + if (eeaPPCommerceParameters.checkout_type === 'ppcp') { + this_pm.setupPayPalButtons(); + } + } + this_pm.spco.end_ajax(); + } + + + /** + * Listener for the card fields submit action. + * @function + */ + this.submitCardFieldsListener = function (cardFields) { + const this_pm = this; + $("#" + this_pm.slug + "-submit").on('click', (event) => { + event.preventDefault(); + // Validate the form. + let state = cardFields.getState(); + let form_valid = this_pm.payment_form.valid(); + Object.keys(state.fields).forEach(function callback(value) { + let field_valid = state.fields[value].isValid; + // Highlight the problem field. + if (!field_valid) { + form_valid = false; + $(state.fields[value].container).addClass('ee-needs-value'); + } else { + $(state.fields[value].container).removeClass('ee-needs-value'); + } + }); + if (form_valid) { + let bill_state = ''; + let bill_state_id = this.bill_state.val(); + for (const key in eeaPPCommerceParameters.active_states) { + if (bill_state_id === key) { + bill_state = eeaPPCommerceParameters.active_states[key]; + } + } + + let bill_address_2 = this.bill_address_2.val(); + if (!bill_address_2) { + bill_address_2 = ''; + } + cardFields.submit({ + // Cardholder's first and last name + cardholderName: $(this_pm.card_holder_name_input_id).val(), + // Billing Address + billingAddress: { + // Street address, line 1 + streetAddress: this.bill_address.val(), + // Street address, line 2 (Ex: Unit, Apartment, etc.) + extendedAddress: bill_address_2, + // State + region: bill_state, + // City + locality: this.bill_city.val(), + // Postal Code + postalCode: this.bill_zip.val(), + // Country Code + countryCodeAlpha2: this.bill_country.val() + } + }).then(function () { + return this_pm.captureOrder([]); + }).catch(function (err) { + this_pm.throwError( + eeaPPCommerceParameters.pm_capture_error + ' ' + JSON.stringify(err), + JSON.stringify(err), + this_pm.slug + ); + }); + } else { + this_pm.displayError( + eeaPPCommerceParameters.form_validation_notice, + $(this_pm.card_input_id) + ); + } + }); + } + + /** * Send a request to the server side to create an Order through the PayPal API. * @function */ - this.createOrder = function () { - console.log('-- createOrder:'); + this.createOrder = function (billing_info) { + console.log('function createOrder()'); + this.spco.do_before_sending_ajax(); // Do we already have an order created ? if (this.pp_order_id.length > 0) { - console.log('-- createOrder return:', this.pp_order_id); this.spco.end_ajax(); return this.pp_order_id; } // Create a new order. const this_pm = this; const request_data = new FormData(); - const billing_info = { - bill_first_name: this.bill_first_name.val(), - bill_last_name: this.bill_last_name.val(), - bill_address: this.bill_address.val(), - bill_city: this.bill_city.val(), - bill_state: this.bill_state.val(), - bill_country: this.bill_country.val(), - bill_zip: this.bill_zip.val(), - bill_email: this.bill_email.val() - }; - let bill_address_2 = this.bill_address_2.val(); - if (bill_address_2) { - billing_info.bill_address_2 = bill_address_2; - } - let phone = this.bill_phone.val(); - if (phone) { - billing_info.bill_phone = phone; - } - console.log('-- billing_info:', billing_info); - request_data.append('action', 'eeaPpCreateOrder'); + request_data.append('action', 'eeaPPCCreateOrder'); request_data.append('txn_id', eeaPPCommerceParameters.txn_id); request_data.append('payment_method', this.slug); request_data.append('billing_info', JSON.stringify(billing_info)); - // Do a request to create an Order. return fetch(eei18n.ajax_url, { method: 'POST', @@ -302,14 +405,14 @@ jQuery(document).ready(function ($) { if (typeof response_data.error !== 'undefined') { message = response_data.error; } - this_pm.throwError(message, this_pm.slug, false); - console.log('-- createOrder return false:'); + this_pm.throwError(message, response_data, this_pm.slug, false); + console.log('-- createOrder return false!'); this_pm.spco.end_ajax(); return false; } }) .catch((error) => { - this_pm.throwError(error, this_pm.slug); + this_pm.throwError(error, '', this_pm.slug); }); }; @@ -318,14 +421,19 @@ jQuery(document).ready(function ($) { * Send a request to the server side to capture the Order through the PayPal API. * @function */ - this.captureOrder = function (order_data, order_actions) { - console.log('-- captureOrder:', order_data); + this.captureOrder = function (order_data) { + console.log('function captureOrder()'); const this_pm = this; + this_pm.spco.do_before_sending_ajax(); const request_data = new FormData(); - request_data.append('action', 'eeaPpCaptureOrder'); + let order_id = this.getOrderId(); + if (typeof order_data.orderID !== 'undefined' && order_data.orderID) { + order_id = order_data.orderID; + } + request_data.append('action', 'eeaPPCCaptureOrder'); request_data.append('payment_method', this.slug); request_data.append('txn_id', eeaPPCommerceParameters.txn_id); - request_data.append('order_id', order_data.orderID); + request_data.append('order_id', order_id); // Do a request to capture the Order. return fetch(eei18n.ajax_url, { @@ -336,14 +444,13 @@ jQuery(document).ready(function ($) { .then((response_data) => { console.log('-- captureOrder response:', response_data); if (typeof response_data.error !== 'undefined') { - // if (response_data.name === 'INSTRUMENT_DECLINED') { - // this_pm.clearOrder(); - // } + if (response_data.name === 'INSTRUMENT_DECLINED') { + this_pm.clearOrder(); + } let message = eeaPPCommerceParameters.payment_error; if (response_data.message) message += '\n\n' + response_data.message; - this_pm.throwError(message, this_pm.slug); + this_pm.throwError(message, response_data, this_pm.slug); // order_actions.restart(); - console.log('-- captureOrder return []:'); this_pm.spco.end_ajax(); return []; } @@ -353,7 +460,7 @@ jQuery(document).ready(function ($) { $('.hide-me-after-successful-payment-js').hide(); // Trigger click event on SPCO "Proceed to Next Step" button. this_pm.spco.enable_submit_buttons(); - this_pm.payment_button_container.parents('form:first').find('.spco-next-step-btn').trigger('click'); + this_pm.order_nonce_input.parents('form:first').find('.spco-next-step-btn').trigger('click'); console.log('-- captureOrder return response_data:', response_data); this_pm.spco.end_ajax(); return response_data; @@ -361,19 +468,75 @@ jQuery(document).ready(function ($) { }; + /** + * Hide the advanced credit debit card fields. + * @function + */ + this.hideACDCForm = function () { + const card_fields = [ + $(this.card_fields_class), + $(this.type_separator_id), + $(this.new_state_form_id), + $(this.acdc_submit_btn_dv), + ]; + const bill_fields = [ + $(this.card_holder_name_input_id), + this.bill_address, + this.bill_address_2, + this.bill_city, + this.bill_state, + this.bill_country, + this.bill_zip, + this.bill_phone, + this.add_new_state, + ]; + // No need to validate this form, disable inputs. + SPCO.remove_previous_validation_rules(); + // Send additional POST data with the form submit + SPCO.additional_post_data += '&eep_ppc_skip_form_validation=true'; + $.each(bill_fields, function(index, field) { + field.parent().hide(); + field.removeAttr('required'); + } + ); + // Hide card fields as well. + $.each(card_fields, function(index, field) { + field.hide(); + } + ); + } + + /** * Add order data to the payment form to pass it to the gateway. * @function */ this.saveOrderData = function (order_data) { - console.log('-- saveOrderData:', order_data); - // Save order data in case there's an error. - this.pp_order_id = order_data.pp_order_id; - this.pp_order_nonce = order_data.pp_order_nonce; + console.log('function saveOrderData()', order_data); + // Check each parameter before setting its value. + if (typeof order_data.pp_order_id !== 'undefined' && order_data.pp_order_id) { + this.pp_order_id = order_data.pp_order_id; + } + if (typeof order_data.pp_order_nonce !== 'undefined' && order_data.pp_order_nonce) { + this.pp_order_nonce = order_data.pp_order_nonce; + } + if (typeof order_data.pp_order_status !== 'undefined' && order_data.pp_order_status) { + this.order_status_input.val(order_data.pp_order_status); + } + if (typeof order_data.pp_order_amount !== 'undefined' && order_data.pp_order_amount) { + this.order_amount_input.val(order_data.pp_order_amount); + } + this.saveOrderInDom(); + }; + + + /** + * Get paypal_order_id. + * @function + */ + this.saveOrderInDom = function () { this.order_id_input.val(this.pp_order_id); this.order_nonce_input.val(this.pp_order_nonce); - this.order_status_input.val(order_data.pp_order_status); - this.order_amount_input.val(order_data.pp_order_amount); }; @@ -400,7 +563,7 @@ jQuery(document).ready(function ($) { * @function */ this.clearOrder = function () { - console.log('-- clearOrder:'); + console.log('function clearOrder()'); this.pp_order_id = ''; this.pp_order_nonce = ''; return true; @@ -410,24 +573,28 @@ jQuery(document).ready(function ($) { /** * Display and/or log the error. * @function + * @param message * @param details * @param pm_slug * @param log_error * @param display_error */ - this.throwError = function (details, pm_slug, log_error, display_error) { - let error = eeaPPCommerceParameters.error_response; - if (details) { - error = error + ': ' + details; + this.throwError = function (message, details, pm_slug, log_error, display_error) { + let error_message = eeaPPCommerceParameters.error_response; + if (message) { + error_message = error_message + ': ' + message; } - console.error(error); + console.error(error_message, details); // front-end message if (display_error !== false) { - this.displayError(details); + this.displayError(error_message); } // add to PM logs if (log_error !== false) { - this.logError(error, pm_slug); + if (!details) { + details = error_message; + } + this.logError(details, pm_slug); } }; @@ -446,13 +613,12 @@ jQuery(document).ready(function ($) { * Scroll to top and display the error message. * @function displayError */ - this.displayError = function (message) { + this.displayError = function (message, item) { let notification = this.spco.generate_message_object('', '', message); - this.spco.scroll_to_top_and_display_messages( - this.payment_method_info_div, - notification, - this - ); + if (typeof item === 'undefined' || typeof item.offset() === 'undefined') { + item = this.spco.main_container; + } + this.spco.scroll_to_top_and_display_messages(item, notification, true); }; @@ -483,7 +649,7 @@ jQuery(document).ready(function ($) { * @function disableSubmitButtons */ this.disableSubmitButtons = function () { - if (this.selected && this.payment_button_container.length > 0) { + if (this.selected && this.order_nonce_input.length > 0) { this.spco.allow_enable_submit_buttons = false; this.spco.disable_submit_buttons(); } diff --git a/PaymentMethods/PayPalCommerce/domain/Domain.php b/PaymentMethods/PayPalCommerce/domain/Domain.php index 83130b95b0b..f2755ef6e8d 100644 --- a/PaymentMethods/PayPalCommerce/domain/Domain.php +++ b/PaymentMethods/PayPalCommerce/domain/Domain.php @@ -2,6 +2,8 @@ namespace EventEspresso\PaymentMethods\PayPalCommerce\domain; +use EE_Payment_Method; + /** * Class Domain * @@ -33,20 +35,15 @@ class Domain public const META_KEY_ACCESS_TOKEN = 'access_token'; /** - * Name of the extra meta that stores the seller nonce. + * Name of the extra meta that stores the last request tracking ID. */ - public const META_KEY_SELLER_NONCE = 'seller_nonce'; + public const META_KEY_TRACKING_ID = 'tracking_id'; /** * Name of the extra meta that stores the Event Espresso PayPal Account's merchant id. */ public const META_KEY_APP_ID = 'app_id'; - /** - * Name of the extra meta that holds the partner client ID. - */ - public const META_KEY_PARTNER_CLIENT_ID = 'partner_client_id'; - /** * Name of the extra meta that holds the seller client ID. */ @@ -63,15 +60,20 @@ class Domain public const META_KEY_EXPIRES_IN = 'expires_in'; /** - * Name of the extra meta that holds the seller payer ID. + * Name of the extra meta that holds the partner client ID. */ - public const META_KEY_PAYER_ID = 'payer_id'; + public const META_KEY_PARTNER_CLIENT_ID = 'partner_client_id'; /** * Name of the extra meta that holds the partner merchant ID. */ public const META_KEY_PARTNER_MERCHANT_ID = 'partner_merchant_id'; + /** + * Name of the extra meta that holds the seller merchant ID. + */ + public const META_KEY_SELLER_MERCHANT_ID = 'merchantIdInPayPal'; + /** * Name of the extra meta that holds the onboarding URL. */ @@ -87,23 +89,90 @@ class Domain */ public const META_KEY_LAST_ORDER = 'last_order_details'; + /** + * Name of the extra meta that stores the allowed PP checkout type selected by merchant while onboarding. + */ + public const META_KEY_ALLOWED_CHECKOUT_TYPE = 'allowed_checkout_type'; + + /** + * Name of the extra meta that stores the PP checkout type selected by merchant after onboarding. + */ + public const META_KEY_CHECKOUT_TYPE = 'checkout_type'; + /** * Name of the PayPal API parameter that holds the auth code. */ public const API_KEY_AUTH_CODE = 'authCode'; /** - * Name of the PayPal API parameter that holds the shared ID. + * Name of the PayPal API parameter that holds the client token. + */ + public const API_KEY_CLIENT_TOKEN = 'client_token'; + + /** + * Name of the extra meta that holds the seller payer ID. + */ + public const META_KEY_PAYER_ID = 'payer_id'; + + /** + * Name of the PayPal API parameter that holds the client token expiration time. */ - public const API_KEY_SHARED_ID = 'sharedId'; + public const API_KEY_EXPIRES_IN = 'expires_in'; + + /** + * Name of the PayPal API parameter that holds the bool of if permissions were granted. + */ + public const API_PARAM_PERMISSIONS_GRANTED = 'permissionsGranted'; + + /** + * Name of the PayPal API parameter that holds the bool of if the primary email was confirmed. + */ + public const API_PARAM_PRIM_EMAIL_CONFIRMED = 'primary_email_confirmed'; + + /** + * Name of the PayPal API parameter that holds the bool of if email was confirmed. + */ + public const API_PARAM_EMAIL_CONFIRMED = 'isEmailConfirmed'; + + /** + * Name of the PayPal API parameter that holds the partner ID. + */ + public const API_PARAM_PARTNER_ID = 'merchantId'; + + /** + * Name of the PayPal API parameter that holds the merchant ID in the Track seller onboarding status request. + */ + public const API_PARAM_TRACK_MERCHANT_ID = 'merchant_id'; + + /** + * Name of the PayPal API parameter that holds the payments_receivable status. + */ + public const API_PARAM_PAYMENTS_RECEIVABLE = 'payments_receivable'; /** * Name of the nonce used in the capture order request. */ public const CAPTURE_ORDER_NONCE_NAME = 'eea_pp_commerce_capture_order_payment'; + /** + * Name of the nonce used in the onboarding process. + */ + public const NONCE_NAME_ONBOARDING_RETURN = 'eea_pp_commerce_onboarding_return'; + /** * Holds this payment method slug. */ public const PM_SLUG = 'paypalcheckout'; + + + /** + * Returns the base PayPal API URL. + * + * @param EE_Payment_Method $payment_method + * @return string + */ + public static function getPayPalApiUrl(EE_Payment_Method $payment_method): string + { + return $payment_method->debug_mode() ? 'https://api-m.sandbox.paypal.com' : 'https://api-m.paypal.com'; + } } diff --git a/PaymentMethods/PayPalCommerce/modules/EED_PayPalCommerce.module.php b/PaymentMethods/PayPalCommerce/modules/EED_PayPalCommerce.module.php index 94743a6f185..c8e2b66b769 100644 --- a/PaymentMethods/PayPalCommerce/modules/EED_PayPalCommerce.module.php +++ b/PaymentMethods/PayPalCommerce/modules/EED_PayPalCommerce.module.php @@ -2,9 +2,12 @@ use EventEspresso\core\domain\services\database\DbStatus; use EventEspresso\core\services\request\DataType; +use EventEspresso\PaymentMethods\PayPalCommerce\api\clients\ClientToken; use EventEspresso\PaymentMethods\PayPalCommerce\api\orders\CaptureOrder; use EventEspresso\PaymentMethods\PayPalCommerce\api\orders\CreateOrder; use EventEspresso\PaymentMethods\PayPalCommerce\api\PayPalApi; +use EventEspresso\PaymentMethods\PayPalCommerce\api\FirstPartyPayPalApi; +use EventEspresso\PaymentMethods\PayPalCommerce\api\ThirdPartyPayPalApi; use EventEspresso\PaymentMethods\PayPalCommerce\domain\Domain; use EventEspresso\PaymentMethods\PayPalCommerce\tools\extra_meta\PayPalExtraMetaManager; use EventEspresso\PaymentMethods\PayPalCommerce\tools\logging\PayPalLogger; @@ -36,17 +39,6 @@ public static function instance(): EED_Module * @return void */ public function run($WP) - { - // TODO: Implement run() method. - } - - - /** - * For hooking into EE Core and other modules. - * - * @return void - */ - public static function set_hooks() { } @@ -56,15 +48,15 @@ public static function set_hooks() * * @return void */ - public static function set_hooks_admin() + public static function set_hooks_admin(): void { if (DbStatus::isOnline()) { // Create an Order. - add_action('wp_ajax_eeaPpCreateOrder', [__CLASS__, 'createOrderRequest']); - add_action('wp_ajax_nopriv_eeaPpCreateOrder', [__CLASS__, 'createOrderRequest']); + add_action('wp_ajax_eeaPPCCreateOrder', [__CLASS__, 'createOrderRequest']); + add_action('wp_ajax_nopriv_eeaPPCCreateOrder', [__CLASS__, 'createOrderRequest']); // Capture the Order. - add_action('wp_ajax_eeaPpCaptureOrder', [__CLASS__, 'captureOrderRequest']); - add_action('wp_ajax_nopriv_eeaPpCaptureOrder', [__CLASS__, 'captureOrderRequest']); + add_action('wp_ajax_eeaPPCCaptureOrder', [__CLASS__, 'captureOrderRequest']); + add_action('wp_ajax_nopriv_eeaPPCCaptureOrder', [__CLASS__, 'captureOrderRequest']); // Log errors from the JS side. add_action('wp_ajax_eeaPPCommerceLogError', [__CLASS__, 'logJsError']); add_action('wp_ajax_nopriv_eeaPPCommerceLogError', [__CLASS__, 'logJsError']); @@ -87,9 +79,9 @@ public static function set_hooks_admin() * @throws EE_Error * @throws ReflectionException */ - public static function createOrderRequest() + public static function createOrderRequest(): void { - $paypal_pm = self::getPaymentMethod(); + $paypal_pm = EED_PayPalCommerce::getPaymentMethod(); $request = EED_Module::getRequest(); $post_params = $request->postParams(); if (! $paypal_pm instanceof EE_Payment_Method) { @@ -98,24 +90,21 @@ public static function createOrderRequest() $post_params ); } - $transaction = self::getTransaction(); + $transaction = EED_PayPalCommerce::getTransaction(); $billing_info = $post_params['billing_info'] ?? []; if ($billing_info) { $billing_info_decoded = json_decode(stripslashes($billing_info), true); - if (is_array($billing_info_decoded)) { - $billing_info = $billing_info_decoded; - } + $billing_info = is_array($billing_info_decoded) ? $billing_info_decoded : []; } - if (! $transaction || ! $billing_info || ! is_array($billing_info)) { + if (! $transaction) { PayPalLogger::errorLogAndExit( - esc_html__('Transaction or billing info not found.', 'event_espresso'), + esc_html__('Transaction info not found.', 'event_espresso'), $post_params, $paypal_pm ); } - $order_data = self::createOrder($transaction, $billing_info, $paypal_pm); - echo json_encode($order_data); - exit(); + $order_data = EED_PayPalCommerce::createOrder($transaction, $billing_info, $paypal_pm); + wp_send_json($order_data); } @@ -124,17 +113,15 @@ public static function createOrderRequest() * (AJAX) * * @return void - * @throws EE_Error - * @throws ReflectionException */ - public static function captureOrderRequest() + public static function captureOrderRequest(): void { $error_message = false; - $paypal_pm = self::getPaymentMethod(); + $paypal_pm = EED_PayPalCommerce::getPaymentMethod(); if (! $paypal_pm instanceof EE_Payment_Method) { $error_message = esc_html__('Payment method not found (capture Order).', 'event_espresso'); } - $transaction = self::getTransaction(); + $transaction = EED_PayPalCommerce::getTransaction(); if (! $transaction) { $error_message = esc_html__('Transaction not found.', 'event_espresso'); } @@ -146,9 +133,8 @@ public static function captureOrderRequest() if ($error_message) { PayPalLogger::errorLogAndExit($error_message, EED_Module::getRequest()->postParams(), $paypal_pm); } - $capture_response = self::captureOrder($transaction, $paypal_pm, $order_id); - echo json_encode($capture_response); - exit(); + $capture_response = EED_PayPalCommerce::captureOrder($transaction, $paypal_pm, $order_id); + wp_send_json($capture_response); } @@ -161,14 +147,13 @@ public static function captureOrderRequest() * @return array * @throws EE_Error * @throws ReflectionException - * @throws Exception */ public static function createOrder( EE_Transaction $transaction, array $billing_info, EE_Payment_Method $paypal_pm ): array { - $create_order_api = self::getCreateOrderApi($transaction, $billing_info, $paypal_pm); + $create_order_api = EED_PayPalCommerce::getCreateOrderApi($transaction, $billing_info, $paypal_pm); if (! $create_order_api instanceof CreateOrder) { return [ 'error' => 'CREATE_ORDER_API_FAULT', @@ -195,16 +180,13 @@ public static function createOrder( * @param EE_Payment_Method $paypal_pm * @param string $order_id * @return array - * @throws EE_Error - * @throws ReflectionException - * @throws Exception */ public static function captureOrder( EE_Transaction $transaction, EE_Payment_Method $paypal_pm, string $order_id ): array { - $capture_order_api = self::getCaptureOrderApi($transaction, $paypal_pm, $order_id); + $capture_order_api = EED_PayPalCommerce::getCaptureOrderApi($transaction, $paypal_pm, $order_id); if (! $capture_order_api instanceof CaptureOrder) { return [ 'error' => 'CAPTURE_ORDER_API_FAULT', @@ -216,7 +198,11 @@ public static function captureOrder( return $order; } // Attach the transaction ID to this order. - $order['ee_txn_id'] = $transaction->ID(); + try { + $order['ee_txn_id'] = $transaction->ID(); + } catch (Exception $e) { + // Just don't set the txn id. + } // Save this order details. PayPalExtraMetaManager::savePmOption($paypal_pm, Domain::META_KEY_LAST_ORDER, $order); $nonce = wp_create_nonce(Domain::CAPTURE_ORDER_NONCE_NAME); @@ -236,15 +222,14 @@ public static function captureOrder( * @param array $billing_info * @param EE_Payment_Method $paypal_pm * @return CreateOrder|null - * @throws Exception */ public static function getCreateOrderApi( EE_Transaction $transaction, array $billing_info, EE_Payment_Method $paypal_pm ): ?CreateOrder { - $paypal_api = self::getPayPalApi($paypal_pm); - if (! $paypal_api) { + $paypal_api = EED_PayPalCommerce::getPayPalApi($paypal_pm); + if (! $paypal_api instanceof PayPalApi) { return null; } return new CreateOrder($paypal_api, $transaction, $billing_info); @@ -258,15 +243,14 @@ public static function getCreateOrderApi( * @param EE_Payment_Method $paypal_pm * @param string $order_id * @return CaptureOrder|null - * @throws Exception */ public static function getCaptureOrderApi( EE_Transaction $transaction, EE_Payment_Method $paypal_pm, string $order_id ): ?CaptureOrder { - $paypal_api = self::getPayPalApi($paypal_pm); - if (! $paypal_api) { + $paypal_api = EED_PayPalCommerce::getPayPalApi($paypal_pm); + if (! $paypal_api instanceof PayPalApi) { return null; } return new CaptureOrder($paypal_api, $transaction, $order_id); @@ -278,17 +262,55 @@ public static function getCaptureOrderApi( * * @param EE_Payment_Method $paypal_pm * @return PayPalApi|null - * @throws Exception + * @throws EE_Error + * @throws ReflectionException */ public static function getPayPalApi(EE_Payment_Method $paypal_pm): ?PayPalApi { + // Try getting the first party credentials to determine if this is a first party integration that's active. $client_id = PayPalExtraMetaManager::getPmOption($paypal_pm, Domain::META_KEY_CLIENT_ID); $client_secret = PayPalExtraMetaManager::getPmOption($paypal_pm, Domain::META_KEY_CLIENT_SECRET); $bn_code = PayPalExtraMetaManager::getPmOption($paypal_pm, Domain::META_KEY_BN_CODE); - if (! $client_id || ! $client_secret || ! $bn_code) { + if ($client_id && $client_secret) { + return new FirstPartyPayPalApi($client_id, $client_secret, $bn_code, $paypal_pm->debug_mode()); + } + // Third party integration credentials: + $access_token = EED_PayPalOnboard::getPartnerAccessToken($paypal_pm); + if (! $access_token || ! $bn_code) { return null; } - return new PayPalApi($client_id, $client_secret, $bn_code, $paypal_pm->debug_mode()); + $partner_client_id = PayPalExtraMetaManager::getPmOption($paypal_pm, Domain::META_KEY_PARTNER_CLIENT_ID) ?: ''; + $payer_id = PayPalExtraMetaManager::getPmOption($paypal_pm, Domain::META_KEY_SELLER_MERCHANT_ID) ?: ''; + return new ThirdPartyPayPalApi($access_token, $bn_code, $partner_client_id, $payer_id, $paypal_pm->debug_mode()); + } + + + /** + * Requests a client token. + * + * @param EE_Payment_Method $paypal_pm + * @return array + */ + public static function requestClientToken(EE_Payment_Method $paypal_pm): array + { + $error = [ + 'error' => 'GET_CLIENT_TOKEN_FAULT' + ]; + $paypal_api = EED_PayPalCommerce::getPayPalApi($paypal_pm); + if (! $paypal_api instanceof PayPalApi) { + $error['message'] = esc_html__('Got an error while trying to get the client token.', 'event_espresso'); + return $error; + } + $client_token_api = new ClientToken($paypal_api, $paypal_pm->debug_mode()); + $client_token = $client_token_api->getToken(); + if (isset($client_token['error'])) { + return $client_token; + } + if (empty($client_token)) { + $error['message'] = esc_html__('Client token not valid.', 'event_espresso'); + return $error; + } + return $client_token; } @@ -296,23 +318,40 @@ public static function getPayPalApi(EE_Payment_Method $paypal_pm): ?PayPalApi * Retrieve the payment method from the provided data. * * @return EE_Transaction|null - * @throws EE_Error */ public static function getTransaction(): ?EE_Transaction { - $txn_id = EED_Module::getRequest()->getRequestParam('txn_id', 0, DataType::INT); - $transaction = EEM_Transaction::instance()->get_one_by_ID($txn_id); - if (! $transaction instanceof EE_Transaction) { - PayPalLogger::errorLog( - esc_html__('No transaction found by ID:', 'event_espresso'), - EED_Module::getRequest()->postParams() - ); + try { + $txn_id = EED_Module::getRequest()->getRequestParam('txn_id', 0, DataType::INT); + $transaction = EEM_Transaction::instance()->get_one_by_ID($txn_id); + if (! $transaction instanceof EE_Transaction) { + PayPalLogger::errorLog( + esc_html__('No transaction found by ID:', 'event_espresso'), + EED_Module::getRequest()->postParams() + ); + return null; + } + } catch (Exception $e) { return null; } return $transaction; } + /** + * Return a PayPal API object, or false on failure. + * + * @param EE_Payment_Method $paypal_pm + * @return bool + */ + public static function isThirdParty(EE_Payment_Method $paypal_pm): bool + { + $pp_meta_data = PayPalExtraMetaManager::getAllData($paypal_pm); + return ! empty($pp_meta_data[ Domain::META_KEY_SELLER_MERCHANT_ID ]) + && ! empty($pp_meta_data[ Domain::META_KEY_ACCESS_TOKEN ]); + } + + /** * Retrieve the payment method from the provided data. * @@ -327,7 +366,7 @@ public static function getPaymentMethod(): ?EE_Payment_Method if ($payment_method instanceof EE_Payment_Method) { return $payment_method; } - } catch (EE_Error $e) { + } catch (Exception $e) { return null; } return null; @@ -338,10 +377,8 @@ public static function getPaymentMethod(): ?EE_Payment_Method * Log JS error. * * @return void - * @throws EE_Error - * @throws ReflectionException */ - public static function logJsError() + public static function logJsError(): void { // Default to the "first" PayPal checkout PM. $request = EED_Module::getRequest(); @@ -365,7 +402,6 @@ public static function logJsError() * @param EE_Transaction $transaction * @param string $scope @see EEM_Payment_Method::get_all_for_events * @return array - * @throws EE_Error */ public static function filterPaymentMethods(array $payment_methods, $transaction, $scope): array { @@ -378,4 +414,26 @@ public static function filterPaymentMethods(array $payment_methods, $transaction } return $payment_methods; } + + + /** + * Get all active states. + * + * @return array + * @throws EE_Error + * @throws ReflectionException + */ + public static function getActiveStates(): array + { + $state_options = []; + $states = EEM_State::instance()->get_all_active_states(); + if (! empty($states)) { + foreach ($states as $numeral => $state) { + if ($state instanceof EE_State) { + $state_options[ $numeral ] = $state->abbrev(); + } + } + } + return $state_options; + } } diff --git a/PaymentMethods/PayPalCommerce/modules/EED_PayPalOnboard.module.php b/PaymentMethods/PayPalCommerce/modules/EED_PayPalOnboard.module.php index 3f0f6e3cfdb..a294428d709 100644 --- a/PaymentMethods/PayPalCommerce/modules/EED_PayPalOnboard.module.php +++ b/PaymentMethods/PayPalCommerce/modules/EED_PayPalOnboard.module.php @@ -1,6 +1,9 @@ postParams()); - $signup_link = self::getSignUpLink($paypal_pm); + // $signup_link = PayPalExtraMetaManager::getPmOption($paypal_pm, Domain::META_KEY_ONBOARDING_URL); + // $token_expired = EED_PayPalOnboard::partnerAccessTokenExpired($paypal_pm); + // if (! $signup_link || $token_expired) { + $signup_link = EED_PayPalOnboard::requestOnboardingUrl($paypal_pm); + // } + if (! $signup_link) { + $err_msg = esc_html__('Error! Could not generate a sign-up link.', 'event_espresso'); + PayPalLogger::errorLogAndExit($err_msg, ['signup_link' => $signup_link], $paypal_pm); + } + PayPalExtraMetaManager::savePmOption($paypal_pm, Domain::META_KEY_ONBOARDING_URL, $signup_link); } catch (Exception $exception) { - self::exitWithError($exception->getMessage()); + PayPalLogger::errorLogAndExit($exception->getMessage()); } // Is it empty (can happen if we didn't get the URL through the API). $signup_link = $signup_link ? $signup_link . '?&displayMode=minibrowser' : '#'; - echo json_encode( + wp_send_json( [ 'signup_link' => $signup_link, ] ); - exit(); - } - - - /** - * Get the URL to redirect the seller to and start the onboarding. - * - * @param EE_Payment_Method $paypal_pm - * @return string - * @throws EE_Error - * @throws Exception - */ - public static function getSignUpLink(EE_Payment_Method $paypal_pm): string - { - $signup_link = PayPalExtraMetaManager::getPmOption($paypal_pm, Domain::META_KEY_ONBOARDING_URL); - $token_expired = self::partnerAccessTokenExpired($paypal_pm); - if (! $signup_link || $token_expired) { - // Generate sign-up link and save. - $signup_link = self::requestOnboardingUrl($paypal_pm); - if (! $signup_link) { - $err_msg = esc_html__('Error! Could not generate a sign-up link.', 'event_espresso'); - PayPalLogger::errorLog($err_msg, ['signup_link' => $signup_link], $paypal_pm); - return ''; - } - PayPalExtraMetaManager::savePmOption($paypal_pm, Domain::META_KEY_ONBOARDING_URL, $signup_link); - } - return $signup_link; } @@ -134,53 +110,25 @@ public static function getSignUpLink(EE_Payment_Method $paypal_pm): string * Request the sign-up link from PayPal. * * @param EE_Payment_Method $paypal_pm + * @param bool $one_time_request * @return string * @throws EE_Error * @throws Exception */ - public static function requestOnboardingUrl(EE_Payment_Method $paypal_pm): string + public static function requestOnboardingUrl(EE_Payment_Method $paypal_pm, bool $one_time_request = false): string { $signup_link = ''; // Get the access token. - $access_token = self::getPartnerAccessToken($paypal_pm); + $access_token = EED_PayPalOnboard::getPartnerAccessToken($paypal_pm); if (! $access_token) { $err_msg = esc_html__('Error! No access token.', 'event_espresso'); PayPalLogger::errorLog($err_msg, ['access_token' => $access_token], $paypal_pm); - return $signup_link; + return ''; } - $identifier_string = new OneTimeString($paypal_pm->debug_mode()); - $seller_nonce = $identifier_string->value(); - // Save the identifier for future use. - PayPalExtraMetaManager::savePmOption($paypal_pm, Domain::META_KEY_SELLER_NONCE, $seller_nonce); // Request the access token. - $body_params = json_encode( - [ - 'products' => ['EXPRESS_CHECKOUT'], - 'legal_consents' => [ - [ - 'type' => 'SHARE_DATA_CONSENT', - 'granted' => true, - ], - ], - 'operations' => [ - [ - 'operation' => 'API_INTEGRATION', - 'api_integration_preference' => [ - 'rest_api_integration' => [ - 'integration_method' => 'PAYPAL', - 'integration_type' => 'FIRST_PARTY', - 'first_party_details' => [ - 'features' => ['PAYMENT', 'REFUND', 'PARTNER_FEE'], - 'seller_nonce' => $seller_nonce, - ], - ], - ], - ], - ], - ] - ); + $body_params = EED_PayPalOnboard::signupLinkRequestBody($paypal_pm); $bn_code = PayPalExtraMetaManager::getPmOption($paypal_pm, Domain::META_KEY_BN_CODE); - $post_args = [ + $post_params = [ 'method' => 'POST', 'headers' => [ 'User-Agent' => sanitize_text_field($_SERVER['HTTP_USER_AGENT']), @@ -190,13 +138,19 @@ public static function requestOnboardingUrl(EE_Payment_Method $paypal_pm): strin ], 'body' => $body_params, ]; - $request_url = self::getPayPalApiUrl($paypal_pm) . '/v2/customer/partner-referrals'; - $response = self::sendRequest($paypal_pm, $request_url, $post_args); - if (isset($response['error'])) { - return ''; - } + $request_url = Domain::getPayPalApiUrl($paypal_pm) . '/v2/customer/partner-referrals'; + $response = EED_PayPalOnboard::sendRequest($paypal_pm, $request_url, $post_params); // Check the data we received. - if (empty($response['links'])) { + if (isset($response['error']) || empty($response['links'])) { + // Did the original access token get replaced by any chance ? + if (! $one_time_request + && ! empty($response['message']) + && $response['message'] === 'Access Token not found in cache' + ) { + // Clear all PM metadata and try getting the access token One more time. + PayPalExtraMetaManager::deleteAllData($paypal_pm); + return EED_PayPalOnboard::requestOnboardingUrl($paypal_pm, true); + } $err_msg = esc_html__('Incoming sign-up link parameter validation failed.', 'event_espresso'); PayPalLogger::errorLog($err_msg, $response, $paypal_pm); return ''; @@ -204,29 +158,215 @@ public static function requestOnboardingUrl(EE_Payment_Method $paypal_pm): strin // Now retrieve that sign-up link. foreach ($response['links'] as $link) { if ($link['rel'] === 'action_url') { - return $link['href'] ?? ''; + $signup_link = $link['href'] ?? ''; } } return $signup_link; } + /** + * Get the return URL. + * + * @param EE_Payment_Method $paypal_pm + * @return string + * @throws Exception + */ + public static function signupLinkRequestBody(EE_Payment_Method $paypal_pm): string + { + $identifier_string = new OneTimeString($paypal_pm->debug_mode()); + $tracking_id = $identifier_string->value(); + $request = LoaderFactory::getLoader()->getShared(RequestInterface::class); + $checkout_type = $request->getRequestParam('checkout_type', 'EXPRESS_CHECKOUT', DataType::STRING); + // Save the identifier for future use. + PayPalExtraMetaManager::savePmOption($paypal_pm, Domain::META_KEY_TRACKING_ID, $tracking_id); + // Assemble the return URL. + $return_url = EED_PayPalOnboard::getReturnUrl($paypal_pm); + return json_encode([ + 'tracking_id' => $tracking_id, + 'operations' => [ + [ + 'operation' => 'API_INTEGRATION', + 'api_integration_preference' => [ + 'rest_api_integration' => [ + 'integration_method' => 'PAYPAL', + 'integration_type' => 'THIRD_PARTY', + 'third_party_details' => [ + 'features' => ['PAYMENT', 'REFUND'], + ], + ], + ], + ], + ], + 'products' => [$checkout_type], + 'legal_consents' => [ + [ + 'type' => 'SHARE_DATA_CONSENT', + 'granted' => true, + ], + ], + 'partner_config_override' => [ + 'return_url' => $return_url, + ], + ]); + } + + + /** + * Get the return URL. + * + * @param EE_Payment_Method $paypal_pm + * @return string + * @throws EE_Error + * @throws ReflectionException + */ + public static function getReturnUrl(EE_Payment_Method $paypal_pm): string + { + $wp_nonce = EED_Module::getRequest()->getRequestParam('wp_nonce'); + $nonce = wp_create_nonce(Domain::NONCE_NAME_ONBOARDING_RETURN); + return add_query_arg( + [ + 'page' => 'espresso_payment_settings', + 'webhook_action' => 'eea_pp_commerce_merchant_onboard', + 'payment_method' => $paypal_pm->slug(), + '_wpnonce' => $wp_nonce, + 'nonce' => $nonce, + Domain::META_KEY_SANDBOX_MODE => $paypal_pm->debug_mode() ? '1' : '0', + ], + admin_url('admin.php') + ); + } + + + /** + * Redirect to the payment method (PP) settings home page. + * + * @return void + */ + public static function redirectToPmSettingsHome(): void + { + $get_params = EED_Module::getRequest()->getParams(); + if (empty($get_params['payment_method'])) { + // Simply do not redirect. + return; + } + $args_to_add = [ + 'page' => 'espresso_payment_settings', + 'payment_method' => $get_params['payment_method'], + ]; + if (isset($get_params['sandbox_mode'])) { + $args_to_add[ Domain::META_KEY_SANDBOX_MODE ] = $get_params['sandbox_mode']; + } + $home_url = add_query_arg($args_to_add, admin_url('admin.php')); + wp_redirect($home_url); + exit; + } + + + /** + * Check user’s onboarding status. + * This will handle the user return from the auth page and also check the status via the API. + * + * @return void + * @throws EE_Error + * @throws ReflectionException + */ + public static function updateOnboardingStatus(): void + { + // Check if this is the webhook from PayPal. + if (! isset($_GET['webhook_action'], $_GET['nonce']) + || $_GET['webhook_action'] !== 'eea_pp_commerce_merchant_onboard' + ) { + return; // Ignore. + } + $get_params = EED_Module::getRequest()->getParams(); + // Get the payment method. + $paypal_pm = EED_PayPalCommerce::getPaymentMethod(); + // Check the response (GET) parameters. + if (! EED_PayPalOnboard::onboardingStatusResponseValid($get_params, $paypal_pm)) { + // Missing parameters. Can't proceed. + PayPalLogger::errorLog( + esc_html__('Missing required onboarding parameters.', 'event_espresso'), + $get_params, + $paypal_pm + ); + EED_PayPalOnboard::redirectToPmSettingsHome(); + return; + } + // Were the requested permissions granted ? + if (empty($get_params[ Domain::API_PARAM_PERMISSIONS_GRANTED ])) { + $error_message = esc_html__( + 'Permissions not granted by merchant or email not confirmed.', + 'event_espresso' + ); + PayPalLogger::errorLog($error_message, $get_params, $paypal_pm); + EED_PayPalOnboard::redirectToPmSettingsHome(); + return; + } + // Check on the onboarding status (recommended by PP). + $onboarding_status = EED_PayPalOnboard::trackSellerOnboarding( + $paypal_pm, + $get_params[ Domain::META_KEY_SELLER_MERCHANT_ID ] + ); + if (! isset($onboarding_status['valid']) || ! $onboarding_status['valid']) { + PayPalLogger::errorLog( + $onboarding_status['message'], + array_merge($get_params, $onboarding_status), + $paypal_pm + ); + EED_PayPalOnboard::redirectToPmSettingsHome(); + return; + } + // Start saving the setup and info. + PayPalExtraMetaManager::parseAndSaveOptions($paypal_pm, $onboarding_status); + // Save the credentials. + PayPalExtraMetaManager::saveSellerApiCredentials($paypal_pm, $get_params); + // If onboarded successfully, remove the onboarding URL. + PayPalExtraMetaManager::deletePmOption($paypal_pm, Domain::META_KEY_ONBOARDING_URL); + // Also clen GET params by redirecting, because PP auto redirects to the return_url on closing the onboarding window. + EED_PayPalOnboard::redirectToPmSettingsHome(); + } + + + /** + * Check if all required parameters for the onboarding status check are present. + * + * @param array $data + * @param mixed $paypal_pm + * @return bool + */ + public static function onboardingStatusResponseValid(array $data, mixed $paypal_pm): bool + { + // Check that we have all the required parameters and the nonce is ok. + if ($paypal_pm instanceof EE_Payment_Method + && wp_verify_nonce($data['nonce'], Domain::NONCE_NAME_ONBOARDING_RETURN) + && ! empty($data[ Domain::API_PARAM_PARTNER_ID ]) + && ! empty($data[ Domain::META_KEY_SELLER_MERCHANT_ID ]) + && isset($data[ Domain::API_PARAM_PERMISSIONS_GRANTED ]) + && isset($data[ Domain::API_PARAM_EMAIL_CONFIRMED ]) + ) { + return true; + } + return false; + } + + /** * Get partner access token. * * @param EE_Payment_Method $paypal_pm * @return string * @throws EE_Error - * @throws Exception + * @throws ReflectionException */ public static function getPartnerAccessToken(EE_Payment_Method $paypal_pm): string { // Do we have it saved ? $access_token = PayPalExtraMetaManager::getPmOption($paypal_pm, Domain::META_KEY_ACCESS_TOKEN); - $expired = self::partnerAccessTokenExpired($paypal_pm); + $expired = EED_PayPalOnboard::partnerAccessTokenExpired($paypal_pm); // If we don't have it, request/update it. if (! $access_token || $expired) { - return self::requestPartnerAccessToken($paypal_pm); + return EED_PayPalOnboard::requestPartnerAccessToken($paypal_pm); } // Access token is saved as encrypted, so return decrypted. return $access_token; @@ -238,7 +378,6 @@ public static function getPartnerAccessToken(EE_Payment_Method $paypal_pm): stri * * @param EE_Payment_Method $paypal_pm * @return bool - * @throws Exception */ public static function partnerAccessTokenExpired(EE_Payment_Method $paypal_pm): bool { @@ -246,7 +385,7 @@ public static function partnerAccessTokenExpired(EE_Payment_Method $paypal_pm): if (! $expires_at) { return true; } - // Validate the token. Do a health check. + // Validate the token expiration date. $now = time(); $minutes_left = round(($expires_at - $now) / 60); // Count as expired if less than 60 minutes till expiration left. @@ -263,6 +402,7 @@ public static function partnerAccessTokenExpired(EE_Payment_Method $paypal_pm): * @param EE_Payment_Method $paypal_pm * @return string * @throws EE_Error + * @throws ReflectionException */ public static function requestPartnerAccessToken(EE_Payment_Method $paypal_pm): string { @@ -279,13 +419,13 @@ public static function requestPartnerAccessToken(EE_Payment_Method $paypal_pm): if (defined('LOCAL_MIDDLEMAN_SERVER')) { $post_args['sslverify'] = false; } - $post_url = self::getMiddlemanBaseUrl($paypal_pm) . 'get_token'; - $response = self::sendRequest($paypal_pm, $post_url, $post_args); + $post_url = EED_PayPalOnboard::getMiddlemanBaseUrl($paypal_pm) . 'get_token'; + $response = EED_PayPalOnboard::sendRequest($paypal_pm, $post_url, $post_args); if (isset($response['error'])) { return ''; } // Check the data we received. - if (! self::partnerTokenResponseValid($response, $paypal_pm)) { + if (! EED_PayPalOnboard::partnerTokenResponseValid($response, $paypal_pm)) { return ''; } // If we are here all seems to be ok. Save the token and it's data. @@ -298,178 +438,19 @@ public static function requestPartnerAccessToken(EE_Payment_Method $paypal_pm): /** - * Get the seller access token. - * (AJAX) - * - * @return void - * @throws Exception - */ - public static function getSellerAccessToken() - { - $paypal_pm = EED_PayPalCommerce::getPaymentMethod(); - $post_params = EED_Module::getRequest()->postParams(); - $bn_code = PayPalExtraMetaManager::getPmOption($paypal_pm, Domain::META_KEY_BN_CODE); - if (! $paypal_pm instanceof EE_Payment_Method) { - PayPalLogger::errorLogAndExit( - esc_html__('No payment method.', 'event_espresso'), - $post_params, - $paypal_pm - ); - } - $seller_nonce = PayPalExtraMetaManager::getPmOption($paypal_pm, Domain::META_KEY_SELLER_NONCE); - // Look for mandatory parameters. - if ( - empty($post_params[ Domain::API_KEY_AUTH_CODE ]) - || empty($post_params[ Domain::API_KEY_SHARED_ID ]) - || ! $seller_nonce - || ! $bn_code - ) { - $error_message = esc_html__('Missing authCode and sharedId.', 'event_espresso'); - PayPalLogger::errorLogAndExit($error_message, $post_params, $paypal_pm); - } - $nonce = wp_create_nonce('eea_pp_commerce_get_seller_access_token'); - // Request the access token. - $post_args = [ - 'method' => 'POST', - 'headers' => [ - 'User-Agent' => sanitize_text_field($_SERVER['HTTP_USER_AGENT']), - 'Content-Type' => 'application/json', - 'Authorization' => 'Basic ' . base64_encode($post_params[ Domain::API_KEY_SHARED_ID ]), - 'PayPal-Partner-Attribution-Id' => $bn_code, - ], - 'body' => [ - 'nonce' => $nonce, - 'grant_type' => 'authorization_code', - 'code' => $post_params[ Domain::API_KEY_AUTH_CODE ], - 'code_verifier' => $seller_nonce, - ], - ]; - $post_url = self::getPayPalApiUrl($paypal_pm) . '/v1/oauth2/token'; - $response = self::sendRequest($paypal_pm, $post_url, $post_args); - if (isset($response['error'])) { - self::exitWithError($response['message']); - } - // Check the data we received. - if ( - empty($response['access_token']) - || empty($response['expires_in']) - || empty($response['refresh_token']) - ) { - // This is an error. - $err_msg = esc_html__('Incoming parameter validation failed.', 'event_espresso'); - PayPalLogger::errorLogAndExit($err_msg, $response, $paypal_pm); - } - // Now we can request the seller API credentials. - $credentials_saved = self::requestApiCredentials($paypal_pm, $response['access_token']); - if (isset($credentials_saved['error'])) { - echo json_encode( - [ - 'error' => $credentials_saved['error'], - 'message' => $credentials_saved['message'], - ] - ); - } else { - echo json_encode( - [ - 'success' => true, - 'on_board' => true, - ] - ); - } - exit(); - } - - - /** - * Get the seller API credentials. + * Request seller onboarding status from PayPal. * * @param EE_Payment_Method $paypal_pm - * @param string $seller_token + * @param string $merchant_id * @return array - * @throws EE_Error - * @throws Exception */ - public static function requestApiCredentials(EE_Payment_Method $paypal_pm, string $seller_token): array + public static function trackSellerOnboarding(EE_Payment_Method $paypal_pm, string $merchant_id): array { - $partner_merchant_id = PayPalExtraMetaManager::getPmOption($paypal_pm, Domain::META_KEY_PARTNER_MERCHANT_ID); - $bn_code = PayPalExtraMetaManager::getPmOption($paypal_pm, Domain::META_KEY_BN_CODE); - $get_params = [ - 'method' => 'GET', - 'headers' => [ - 'User-Agent' => sanitize_text_field($_SERVER['HTTP_USER_AGENT']), - 'Content-Type' => 'application/json', - 'Authorization' => 'Bearer ' . $seller_token, - 'PayPal-Partner-Attribution-Id' => $bn_code, - ], - ]; - $request_url = self::getPayPalApiUrl($paypal_pm) - . '/v1/customer/partners/' - . $partner_merchant_id - . '/merchant-integrations/credentials/'; - $response = self::sendRequest($paypal_pm, $request_url, $get_params); - // Check the data we received. - if (empty($response['client_id']) || empty($response['client_secret'])) { - // This is an error. - if (isset($response['message'])) { - $err_msg = $response['message']; - $err_name = $response['name'] ?? 'UNRECOGNIZED_ERROR'; - } else { - $err_msg = esc_html__('Incoming parameter validation failed.', 'event_espresso'); - $err_name = 'INCOMING_PARAMETER_INVALID'; - } - PayPalLogger::errorLog($err_msg, $response, $paypal_pm); - return ['error' => $err_name, 'message' => $err_msg]; - } - // Finally, track seller onboarding status. - $onboarding_status = self::trackSellerOnboarding( - $paypal_pm, - $partner_merchant_id, - $response[ Domain::META_KEY_PAYER_ID ], - $response[ Domain::META_KEY_CLIENT_ID ], - $response[ Domain::META_KEY_CLIENT_SECRET ] - ); - if (isset($onboarding_status['error'])) { - return $onboarding_status; - } - // If onboarded successfully, remove the onetime onboarding URL. - if (PayPalExtraMetaManager::saveSellerApiCredentials($paypal_pm, $response)) { - PayPalExtraMetaManager::deletePmOption($paypal_pm, Domain::META_KEY_ONBOARDING_URL); - return ['success' => true]; - } else { - return [ - 'error' => 'SELLER_CREDENTIALS_NOT_SAVED', - 'message' => esc_html__('Seller credentials were not saved.', 'event_espresso'), - ]; + $track_onboarding = EED_PayPalOnboard::getTrackOnboardingApi($paypal_pm, $merchant_id); + if (! $track_onboarding instanceof TrackSellerOnboarding) { + $err_msg = esc_html__('Failed to track seller onboarding.', 'event_espresso'); + return ['error' => 'TRACK_ONBOARDING_FAILED', 'message' => $err_msg]; } - } - - - /** - * Request seller onboarding status from PayPal. - * - * @param EE_Payment_Method $paypal_pm - * @param string $partner_id - * @param $seller_id - * @param string $client_id - * @param string $client_secret - * @return array - * @throws EE_Error - * @throws Exception - */ - public static function trackSellerOnboarding( - EE_Payment_Method $paypal_pm, - string $partner_id, - $seller_id, - string $client_id, - string $client_secret - ): array { - $track_onboarding = self::getTrackOnboardingApi( - $paypal_pm, - $partner_id, - $seller_id, - $client_id, - $client_secret - ); return $track_onboarding->isValid(); } @@ -478,47 +459,21 @@ public static function trackSellerOnboarding( * Returns the Track Seller Onboarding API. * * @param EE_Payment_Method $paypal_pm - * @param string $partner_id - * @param string $seller_id - * @param string $client_id - * @param string $client_secret + * @param string $merchant_id * @return TrackSellerOnboarding|null - * @throws Exception + * @throws EE_Error + * @throws ReflectionException */ public static function getTrackOnboardingApi( EE_Payment_Method $paypal_pm, - string $partner_id, - string $seller_id, - string $client_id, - string $client_secret + string $merchant_id ): ?TrackSellerOnboarding { - $paypal_api = self::getPayPalApi($paypal_pm, $client_id, $client_secret); - if (! $paypal_api) { + $partner_id = PayPalExtraMetaManager::getPmOption($paypal_pm, Domain::META_KEY_PARTNER_MERCHANT_ID); + $paypal_api = EED_PayPalCommerce::getPayPalApi($paypal_pm); + if (! $paypal_api instanceof PayPalApi || ! $partner_id) { return null; } - return new TrackSellerOnboarding($paypal_api, $partner_id, $seller_id, $paypal_pm->debug_mode()); - } - - - /** - * Return a PayPal API object, or false on failure. - * - * @param EE_Payment_Method $paypal_pm - * @param string $client_id - * @param string $client_secret - * @return PayPalApi|null - * @throws Exception - */ - public static function getPayPalApi( - EE_Payment_Method $paypal_pm, - string $client_id, - string $client_secret - ): ?PayPalApi { - $bn_code = PayPalExtraMetaManager::getPmOption($paypal_pm, Domain::META_KEY_BN_CODE); - if (! $client_id || ! $client_secret || ! $bn_code) { - return null; - } - return new PayPalApi($client_id, $client_secret, $bn_code, $paypal_pm->debug_mode()); + return new TrackSellerOnboarding($paypal_api, $partner_id, $merchant_id, $paypal_pm->debug_mode()); } @@ -527,48 +482,71 @@ public static function getPayPalApi( * (AJAX) * * @return void - * @throws EE_Error */ - public static function getOnboardStatus() + public static function getOnboardStatus(): void { $paypal_pm = EED_PayPalCommerce::getPaymentMethod(); if (! $paypal_pm instanceof EE_Payment_Method) { $err_msg = esc_html__('Could not specify the payment method.', 'event_espresso'); PayPalLogger::errorLog($err_msg, EED_Module::getRequest()->postParams(), $paypal_pm); - echo json_encode(['on_board' => false]); - exit(); + wp_send_json(['on_board' => false]); } try { - $seller_id = PayPalExtraMetaManager::getPmOption($paypal_pm, Domain::META_KEY_PAYER_ID) ?? '--'; + $seller_id = PayPalExtraMetaManager::getPmOption($paypal_pm, Domain::META_KEY_SELLER_MERCHANT_ID) ?? '--'; } catch (Exception $e) { $seller_id = '--'; } - echo json_encode( + wp_send_json( [ - 'on_board' => self::isOnboard($paypal_pm), + 'on_board' => EED_PayPalOnboard::isOnboard($paypal_pm), 'seller_id' => $seller_id, ] ); - exit(); } /** - * Deauthorize the seller. Remove all API credentials. + * De-authorize the seller. Remove all API credentials. * (AJAX) * * @return void */ - public static function offboard() + public static function offboard(): void { $paypal_pm = EED_PayPalCommerce::getPaymentMethod(); + if (! $paypal_pm instanceof EE_Payment_Method) { + wp_send_json([ + 'error' => 'INVALID_PM', + 'message' => esc_html__( + 'Invalid payment method. Please refresh the page and try again.', + 'event_espresso' + ), + ]); + } PayPalExtraMetaManager::deleteAllData($paypal_pm); - echo json_encode( - [ - 'success' => true, - ] - ); - exit(); + wp_send_json(['success' => true]); + } + + + /** + * Checks if already onboard. + * + * @param EE_Payment_Method $payment_method + * @return boolean + */ + public static function isOnboard(EE_Payment_Method $payment_method): bool + { + $pp_meta_data = PayPalExtraMetaManager::getAllData($payment_method); + return + // onborded with a third party integration ? + (! empty($pp_meta_data[ Domain::META_KEY_SELLER_MERCHANT_ID ]) + && ! empty($pp_meta_data[ Domain::META_KEY_ACCESS_TOKEN ]) + ) + // or with the first party integration ? + || (! empty($pp_meta_data[ Domain::META_KEY_CLIENT_ID ]) + && ! empty($pp_meta_data[ Domain::META_KEY_CLIENT_SECRET ]) + && ! empty($pp_meta_data[ Domain::META_KEY_PAYER_ID ]) + ); } @@ -579,7 +557,6 @@ public static function offboard() * @param string $request_url * @param array $request_args * @return array - * @throws EE_Error */ public static function sendRequest(EE_Payment_Method $paypal_pm, string $request_url, array $request_args): array { @@ -594,10 +571,10 @@ public static function sendRequest(EE_Payment_Method $paypal_pm, string $request $response_body = (isset($response['body']) && $response['body']) ? json_decode($response['body'], true) : []; if (empty($response_body) || isset($response_body['error'])) { $message = $response_body['error_description'] - ?? sprintf( - esc_html__('Unknown response received while sending a request to: %1$s', 'event_espresso'), - $request_url - ); + ?? sprintf( + esc_html__('Unknown response received while sending a request to: %1$s', 'event_espresso'), + $request_url + ); PayPalLogger::errorLog($message, [$request_url, $request_args, $response], $paypal_pm); $error_return['message'] = $message; return $error_return; @@ -612,7 +589,6 @@ public static function sendRequest(EE_Payment_Method $paypal_pm, string $request * @param $response * @param EE_Payment_Method $paypal_pm * @return bool - * @throws EE_Error */ public static function partnerTokenResponseValid($response, EE_Payment_Method $paypal_pm): bool { @@ -641,6 +617,8 @@ public static function partnerTokenResponseValid($response, EE_Payment_Method $p * * @param EE_Payment_Method $payment_method * @return string + * @throws EE_Error + * @throws ReflectionException */ public static function getMiddlemanBaseUrl(EE_Payment_Method $payment_method): string { @@ -654,56 +632,61 @@ public static function getMiddlemanBaseUrl(EE_Payment_Method $payment_method): s /** - * Returns the base PayPal API URL. + * This Payment Method admin notices. * - * @param EE_Payment_Method $payment_method - * @return string - */ - public static function getPayPalApiUrl(EE_Payment_Method $payment_method): string - { - return $payment_method->debug_mode() ? 'https://api-m.sandbox.paypal.com' : 'https://api-m.paypal.com'; - } - - - /** - * Checks if already onboard. - * - * @param EE_Payment_Method $payment_method - * @return boolean + * @return void * @throws EE_Error + * @throws ReflectionException */ - public static function isOnboard(EE_Payment_Method $payment_method): bool + public static function adminNotice() { - $pp_meta_data = PayPalExtraMetaManager::getAllData($payment_method); - if ( - $pp_meta_data - && isset($pp_meta_data[ Domain::META_KEY_CLIENT_ID ]) - && $pp_meta_data[ Domain::META_KEY_CLIENT_ID ] - && isset($pp_meta_data[ Domain::META_KEY_CLIENT_SECRET ]) - && $pp_meta_data[ Domain::META_KEY_CLIENT_SECRET ] + // A notice to re-connect if still connected through the first party integration. + $pp_commerce = EEM_Payment_Method::instance()->get_one_by_slug('paypalcheckout'); + // Show the notice only if PayPal Commerce is active. + if (! $pp_commerce instanceof EE_Payment_Method + || ! EED_PayPalOnboard::isOnboard($pp_commerce) + || EED_PayPalCommerce::isThirdParty($pp_commerce) ) { - return true; + return; } - return false; + add_action('admin_notices', [__CLASS__, 'reConnectNotice']); } /** - * Return error message as json allowing to show an alert on the front-end. + * Re-connect notice contents. * - * @param string $error_message - * @param bool $show_alert * @return void + * @throws EE_Error + * @throws ReflectionException */ - public static function exitWithError(string $error_message = '', bool $show_alert = false) + public static function reConnectNotice() { - echo json_encode( - [ - 'error' => $error_message, - 'message' => $error_message, - 'alert' => $show_alert, - ] - ); - exit(); + $open_anchor = $close_anchor = ''; + $pp_commerce = EEM_Payment_Method::instance()->get_one_by_slug('paypalcheckout'); + if ($pp_commerce instanceof EE_Payment_Method) { + $pm_page = add_query_arg( + [ + 'page' => 'espresso_payment_settings', + 'webhook_action' => 'eea_pp_commerce_merchant_onboard', + 'payment_method' => $pp_commerce->slug(), + ], + admin_url('admin.php') + ); + $open_anchor = ""; + $close_anchor = ""; + } + echo '

' + . sprintf( + esc_html__( + '%1$sPayPal Commerce%2$s has updated the API integration type to allow more flexibility with payments. Please disconnect and re-Connect on the %3$sPayment Methods admin%4$s page to update the credentials and allow advanced payment type options.', + 'event_espresso' + ), + '', + '', + $open_anchor, + $close_anchor + ) + . '

'; } } diff --git a/PaymentMethods/PayPalCommerce/tools/extra_meta/PayPalExtraMeta.php b/PaymentMethods/PayPalCommerce/tools/extra_meta/PayPalExtraMeta.php index 3b7d69d736a..5dfb364c18e 100644 --- a/PaymentMethods/PayPalCommerce/tools/extra_meta/PayPalExtraMeta.php +++ b/PaymentMethods/PayPalCommerce/tools/extra_meta/PayPalExtraMeta.php @@ -52,7 +52,6 @@ public function __construct(EE_Payment_Method $pm_instance) * * @param array $data * @return bool - * @throws EE_Error */ public function saveBatch(array $data): bool { @@ -78,7 +77,6 @@ public function saveBatch(array $data): bool * * @param string $option_name * @return mixed - * @throws EE_Error */ public function getOption(string $option_name) { @@ -92,7 +90,6 @@ public function getOption(string $option_name) * Return the metadata array if all good. False otherwise. * * @return array|bool - * @throws EE_Error */ public function getMetaData() { @@ -115,7 +112,6 @@ public function getMetaData() * @param string $name * @param $value * @return bool - * @throws EE_Error */ public function saveOption(string $name, $value): bool { @@ -151,7 +147,6 @@ public function saveMetaData(array $data): bool * * @param string $name * @return bool - * @throws EE_Error */ public function deleteOption(string $name): bool { diff --git a/PaymentMethods/PayPalCommerce/tools/extra_meta/PayPalExtraMetaManager.php b/PaymentMethods/PayPalCommerce/tools/extra_meta/PayPalExtraMetaManager.php index 08a9281a3e3..e5ce3906342 100644 --- a/PaymentMethods/PayPalCommerce/tools/extra_meta/PayPalExtraMetaManager.php +++ b/PaymentMethods/PayPalCommerce/tools/extra_meta/PayPalExtraMetaManager.php @@ -11,6 +11,7 @@ use EventEspresso\PaymentMethods\PayPalCommerce\tools\encryption\PPCommerceEncryptionKeyManager; use EventEspresso\PaymentMethods\PayPalCommerce\tools\logging\PayPalLogger; use Exception; +use ReflectionException; /** * Class PayPalExtraMetaManager @@ -27,9 +28,8 @@ class PayPalExtraMetaManager * @param EE_Payment_Method $paypal_pm * @param string $option_name * @return mixed - * @throws Exception */ - public static function getPmOption(EE_Payment_Method $paypal_pm, string $option_name) + public static function getPmOption(EE_Payment_Method $paypal_pm, string $option_name): mixed { $pp_meta_data = self::extraMeta($paypal_pm); $option_value = $pp_meta_data->getOption($option_name); @@ -52,7 +52,6 @@ public static function getPmOption(EE_Payment_Method $paypal_pm, string $option_ * @param string $option_name * @param $option_value * @return bool - * @throws EE_Error */ public static function savePmOption(EE_Payment_Method $paypal_pm, string $option_name, $option_value): bool { @@ -67,7 +66,6 @@ public static function savePmOption(EE_Payment_Method $paypal_pm, string $option * @param EE_Payment_Method $paypal_pm * @param array $options_list * @return bool - * @throws EE_Error */ public static function savePmOptions(EE_Payment_Method $paypal_pm, array $options_list): bool { @@ -82,7 +80,6 @@ public static function savePmOptions(EE_Payment_Method $paypal_pm, array $option * @param EE_Payment_Method $paypal_pm * @param string $option_name * @return bool - * @throws EE_Error */ public static function deletePmOption(EE_Payment_Method $paypal_pm, string $option_name): bool { @@ -96,7 +93,6 @@ public static function deletePmOption(EE_Payment_Method $paypal_pm, string $opti * * @param EE_Payment_Method $paypal_pm * @return array|bool - * @throws EE_Error */ public static function getAllData(EE_Payment_Method $paypal_pm) { @@ -124,7 +120,6 @@ public static function deleteAllData(EE_Payment_Method $paypal_pm): bool * @param EE_Payment_Method $paypal_pm * @param array $request_data * @return bool Updated or not. - * @throws EE_Error */ public static function updateDebugMode(EE_Payment_Method $paypal_pm, array $request_data): bool { @@ -155,7 +150,6 @@ public static function updateDebugMode(EE_Payment_Method $paypal_pm, array $requ * @param EE_Payment_Method $paypal_pm * @param array $response * @return bool - * @throws EE_Error */ public static function savePartnerAccessToken(EE_Payment_Method $paypal_pm, array $response): bool { @@ -200,15 +194,12 @@ public static function savePartnerAccessToken(EE_Payment_Method $paypal_pm, arra * @param EE_Payment_Method $paypal_pm * @param array $response * @return bool - * @throws EE_Error */ public static function saveSellerApiCredentials(EE_Payment_Method $paypal_pm, array $response): bool { $api_credentials = []; $expected_parameters = [ - Domain::META_KEY_CLIENT_ID, - Domain::META_KEY_CLIENT_SECRET, - Domain::META_KEY_PAYER_ID, + Domain::META_KEY_SELLER_MERCHANT_ID, ]; foreach ($expected_parameters as $api_key) { if (! isset($response[ $api_key ])) { @@ -216,11 +207,7 @@ public static function saveSellerApiCredentials(EE_Payment_Method $paypal_pm, ar continue; } try { - if ($api_key === Domain::META_KEY_CLIENT_SECRET) { - $api_credentials[ $api_key ] = self::encryptString($response[ $api_key ], $paypal_pm); - } else { - $api_credentials[ $api_key ] = $response[ $api_key ]; - } + $api_credentials[ $api_key ] = $response[ $api_key ]; } catch (Exception $exception) { PayPalLogger::errorLog($exception->getMessage(), $response, $paypal_pm); return false; @@ -230,6 +217,42 @@ public static function saveSellerApiCredentials(EE_Payment_Method $paypal_pm, ar } + /** + * Save other payment method related settings from a data array. + * + * @param EE_Payment_Method $paypal_pm + * @param array $data + * @return bool + * @throws EE_Error + * @throws ReflectionException + */ + public static function parseAndSaveOptions(EE_Payment_Method $paypal_pm, array $data): bool + { + $allowed_checkout_type = 'express_checkout'; + // Note, although PayPal shows that this should include PPCP_CUSTOM or EXPRESS_CHECKOUT only, + // in reality, it will also include other products like MOBILE_PAYMENT_ACCEPTANCE etc. + if (! empty($data['response']['products'][0]['name']) && is_array($data['response']['products'])) { + foreach ($data['response']['products'] as $product) { + if (str_contains($product['name'], 'PPCP')) { + // This merchant has PPCP in the products list, so we can enable both (all) checkout types. + $allowed_checkout_type = 'all'; + break; + } + } + } + // Set the Checkout type (a PM option), just in case merchant doesn't save PM options manually. + $checkout_type = $paypal_pm->get_extra_meta(Domain::META_KEY_CHECKOUT_TYPE, true, false); + if (! $checkout_type) { + $paypal_pm->update_extra_meta(Domain::META_KEY_CHECKOUT_TYPE, $allowed_checkout_type); + } + return PayPalExtraMetaManager::savePmOption( + $paypal_pm, + Domain::META_KEY_ALLOWED_CHECKOUT_TYPE, + $allowed_checkout_type + ); + } + + /** * Get PayPal extra meta helper. * @@ -271,7 +294,6 @@ public static function encryptString(string $text, EE_Payment_Method $paypal_pm) * @param string $text * @param EE_Payment_Method $paypal_pm * @return string - * @throws Exception */ public static function decryptString(string $text, EE_Payment_Method $paypal_pm): string { @@ -280,11 +302,15 @@ public static function decryptString(string $text, EE_Payment_Method $paypal_pm) return $text; } // Try decrypting. - $encryptor = LoaderFactory::getLoader()->getShared(OpenSSLEncryption::class, [new Base64Encoder()]); - $key_identifier = $paypal_pm->debug_mode() - ? PPCommerceEncryptionKeyManager::SANDBOX_ENCRYPTION_KEY_ID - : PPCommerceEncryptionKeyManager::PRODUCTION_ENCRYPTION_KEY_ID; - $decrypted = $encryptor->decrypt($text, $key_identifier); + try { + $encryptor = LoaderFactory::getLoader()->getShared(OpenSSLEncryption::class, [new Base64Encoder()]); + $key_identifier = $paypal_pm->debug_mode() + ? PPCommerceEncryptionKeyManager::SANDBOX_ENCRYPTION_KEY_ID + : PPCommerceEncryptionKeyManager::PRODUCTION_ENCRYPTION_KEY_ID; + $decrypted = $encryptor->decrypt($text, $key_identifier); + } catch (Exception) { + return $text; + } return $decrypted ?? $text; } } diff --git a/PaymentMethods/PayPalCommerce/tools/logging/PayPalLogger.php b/PaymentMethods/PayPalCommerce/tools/logging/PayPalLogger.php index aee468528e0..d0850b738ef 100644 --- a/PaymentMethods/PayPalCommerce/tools/logging/PayPalLogger.php +++ b/PaymentMethods/PayPalCommerce/tools/logging/PayPalLogger.php @@ -5,7 +5,6 @@ use EE_Error; use EE_Gateway; use EE_Payment_Method; -use EED_PayPalOnboard; use EEM_Payment_Method; use EventEspresso\PaymentMethods\PayPalCommerce\domain\Domain; use ReflectionException; @@ -25,11 +24,11 @@ class PayPalLogger * @param string $error_message * @param array $data * @param EE_Payment_Method|null $paypal_pm + * @param mixed $object_logged * @param bool $return_json Should we echo json and exit * @param bool $popup_log * @param bool $show_alert Show an alert on the front end or not * @return void - * @throws EE_Error */ public static function errorLogAndExit( string $error_message = '', @@ -37,17 +36,18 @@ public static function errorLogAndExit( ?EE_Payment_Method $paypal_pm = null, bool $return_json = true, bool $popup_log = false, - bool $show_alert = false - ) { - self::errorLog($error_message, $data, $paypal_pm, $popup_log); - // Do we echo json and exit ? + bool $show_alert = false, + $object_logged = null + ): void { + PayPalLogger::errorLog($error_message, $data, $paypal_pm, $popup_log, $object_logged); + // Do we echo json and exit or just close the window ? if ($return_json) { - EED_PayPalOnboard::exitWithError($error_message, $show_alert); + PayPalLogger::exitWithJson($error_message, $show_alert); } if ($popup_log) { - self::logInWindow($error_message); + PayPalLogger::logInWindow($error_message); } - self::closeWindowAndExit(); + PayPalLogger::closeWindowAndExit(); } @@ -57,31 +57,36 @@ public static function errorLogAndExit( * @param string $error_message * @param array $data * @param EE_Payment_Method|null $paypal_pm + * @param mixed $object_logged * @param bool $popup_log * @return bool - * @throws EE_Error|ReflectionException */ public static function errorLog( string $error_message = '', array $data = [], ?EE_Payment_Method $paypal_pm = null, - bool $popup_log = false + bool $popup_log = false, + $object_logged = null ): bool { $default_msg = 'PayPal Commerce error'; if ($data) { - $data = self::cleanDataArray($data); + $data = PayPalLogger::cleanDataArray($data); $default_msg = $error_message; } - if (! $paypal_pm instanceof EE_Payment_Method) { - // Default to the standard PP Commerce PM. - $paypal_pm = EEM_Payment_Method::instance()->get_one_by_slug(Domain::PM_SLUG); - } - $paypal_gateway = $paypal_pm->type_obj()->get_gateway(); - if ($paypal_gateway instanceof EE_Gateway) { - $paypal_gateway->log([$default_msg => $data], $paypal_pm); - } - if ($popup_log) { - self::logInWindow(json_encode($data)); + try { + if (! $paypal_pm instanceof EE_Payment_Method) { + // Default to the standard PP Commerce PM. + $paypal_pm = EEM_Payment_Method::instance()->get_one_by_slug(Domain::PM_SLUG); + } + $paypal_gateway = $paypal_pm->type_obj()->get_gateway(); + if ($paypal_gateway instanceof EE_Gateway) { + $paypal_gateway->log([$default_msg => $data], $object_logged); + } + if ($popup_log) { + PayPalLogger::logInWindow(json_encode($data)); + } + } catch (ReflectionException|EE_Error $error) { + return false; } // Yes, always return true. return true; @@ -104,13 +109,19 @@ private static function cleanDataArray(array $data): array 'client_secret', Domain::API_KEY_AUTH_CODE, 'Authorization', + 'merchantIdInPayPal', ]; foreach ($data as $key => $value) { if (is_string($value)) { // Json encoded ? $value = json_decode($value) ?? $value; } - $value = is_array($value) ? self::cleanDataArray($value) : $value; + $value = is_array($value) ? PayPalLogger::cleanDataArray($value) : $value; + // Validate the data type. Some objects won't encode easily, so try getting from them some basic info. + if (is_object($value)) { + $obj_vars = get_object_vars($value); + $value = ! empty($obj_vars) ? PayPalLogger::cleanDataArray($obj_vars) : get_class($value); + } if (is_string($key) && in_array($key, $sensitive_data)) { $data[ $key ] = empty($value) ? '**empty**' : '**hidden**'; } else { @@ -121,13 +132,32 @@ private static function cleanDataArray(array $data): array } + /** + * Return error message as json allowing to show an alert on the front-end. + * + * @param string $error_message + * @param bool $show_alert + * @return void + */ + public static function exitWithJson(string $error_message = '', bool $show_alert = false) + { + wp_send_json( + [ + 'error' => $error_message, + 'message' => $error_message, + 'alert' => $show_alert, + ] + ); + } + + /** * Close the OAuth window with JS. * * @param string $message * @return void */ - public static function logInWindow(string $message) + public static function logInWindow(string $message): void { $js_out = ''; echo $js_out; - exit(); + wp_die(); } @@ -149,7 +179,7 @@ public static function logInWindow(string $message) * @param string $message * @return void */ - public static function closeWindowAndExit(string $message = '') + public static function closeWindowAndExit(string $message = ''): void { $js_out = ''; echo $js_out; - exit(); + wp_die(); } } diff --git a/admin_pages/events/Events_Admin_List_Table.class.php b/admin_pages/events/Events_Admin_List_Table.class.php index 934dfe72f31..735755f2f81 100644 --- a/admin_pages/events/Events_Admin_List_Table.class.php +++ b/admin_pages/events/Events_Admin_List_Table.class.php @@ -471,6 +471,7 @@ public function column_attendees(EE_Event $event): string $attendees_query_args = [ 'action' => 'default', 'event_id' => $event->ID(), + '_reg_status' => EEM_Registration::status_id_approved, ]; $attendees_link = EE_Admin_Page::add_query_args_and_nonce($attendees_query_args, REG_ADMIN_URL); $registered_attendees = EEM_Registration::instance()->get_event_registration_count($event->ID()); diff --git a/admin_pages/general_settings/General_Settings_Admin_Page.core.php b/admin_pages/general_settings/General_Settings_Admin_Page.core.php index a19e83462d0..6ffb1bdf3cc 100644 --- a/admin_pages/general_settings/General_Settings_Admin_Page.core.php +++ b/admin_pages/general_settings/General_Settings_Admin_Page.core.php @@ -1193,6 +1193,11 @@ protected function _update_country_settings() $country->isActive(), DataType::BOOL ); + $cols_n_values['CNT_is_EU'] = $this->request->getRequestParam( + "cntry[$CNT_ISO][CNT_is_EU]", + $country->isEU(), + DataType::BOOL + ); // allow filtering of country data $cols_n_values = apply_filters( diff --git a/admin_pages/messages/help_tabs/messages_settings_messengers.help_tab.php b/admin_pages/messages/help_tabs/messages_settings_messengers.help_tab.php index d3b0d7893d7..0f7e9078047 100644 --- a/admin_pages/messages/help_tabs/messages_settings_messengers.help_tab.php +++ b/admin_pages/messages/help_tabs/messages_settings_messengers.help_tab.php @@ -45,11 +45,11 @@ ), '
' . '' - . '' + . '' . '
', '
' . '' - . '' + . '' . '
' ); ?>

diff --git a/admin_pages/registrations/EE_Registrations_List_Table.class.php b/admin_pages/registrations/EE_Registrations_List_Table.class.php index 92c45b9e474..b0e0e54bcc2 100644 --- a/admin_pages/registrations/EE_Registrations_List_Table.class.php +++ b/admin_pages/registrations/EE_Registrations_List_Table.class.php @@ -5,7 +5,9 @@ use EventEspresso\core\exceptions\EntityNotFoundException; use EventEspresso\core\exceptions\InvalidDataTypeException; use EventEspresso\core\exceptions\InvalidInterfaceException; +use EventEspresso\core\services\loaders\LoaderFactory; use EventEspresso\core\services\request\DataType; +use EventEspresso\core\services\request\RequestInterface; /** * Registrations Table class @@ -41,8 +43,14 @@ class EE_Registrations_List_Table extends EE_Admin_List_Table */ protected array $_event_details = []; + private array $filters = []; + private int $EVT_ID = 0; + private int $DTT_ID = 0; + + private int $TKT_ID = 0; + /** * @param Registrations_Admin_Page $admin_page @@ -50,17 +58,61 @@ class EE_Registrations_List_Table extends EE_Admin_List_Table public function __construct(Registrations_Admin_Page $admin_page) { $this->caps_handler = new RegistrationsListTableUserCapabilities(EE_Registry::instance()->CAP); + $this->request = $this->request ?? LoaderFactory::getShared(RequestInterface::class); + $this->setupFilters(); parent::__construct($admin_page); - $this->EVT_ID = $this->request->getRequestParam('event_id', 0, DataType::INTEGER); - $req_data = $admin_page->get_request_data(); - if ($this->EVT_ID) { - $extra_query_args = []; + $this->_status = $this->_admin_page->get_registration_status_array(); + } + + + private function setupFilters() + { + // for event filtering + $this->EVT_ID = $this->request->getRequestParam('EVT_ID', 0, DataType::INTEGER); + $this->EVT_ID = $this->request->getRequestParam('event_id', $this->EVT_ID, DataType::INTEGER); + // for datetime filtering + $this->DTT_ID = $this->request->getRequestParam('DTT_ID', 0, DataType::INTEGER); + $this->DTT_ID = $this->request->getRequestParam('datetime_id', $this->DTT_ID, DataType::INTEGER); + // for ticket filtering + $this->TKT_ID = $this->request->getRequestParam('TKT_ID', 0, DataType::INTEGER); + $this->TKT_ID = $this->request->getRequestParam('ticket_id', $this->TKT_ID, DataType::INTEGER); + + $filters = [ + 'event_id' => $this->EVT_ID, + 'datetime_id' => $this->DTT_ID, + 'ticket_id' => $this->TKT_ID, + ]; + foreach ($filters as $filter_key => $filter_value) { + if ($filter_value) { + $this->filters[ $filter_key ] = $filter_value; + } + } + + add_filter( + 'FHEE__EE_Admin_Page__get_list_table_view_RLs__extra_query_args', + [$this, 'filterExtraQueryArgs'], + 10, + 2 + ); + } + + + /** + * @param array $extra_query_args + * @param EE_Admin_Page $admin_page + * @return void + * @since $VID:$ + */ + public function filterExtraQueryArgs(array $extra_query_args, EE_Admin_Page $admin_page): array + { + if ($admin_page instanceof Registrations_Admin_Page) { foreach ($admin_page->get_views() as $view_details) { - $extra_query_args[ $view_details['slug'] ] = ['event_id' => $this->EVT_ID]; + foreach ($this->filters as $filter_key => $filter_value) { + $extra_query_args[ $view_details['slug'] ][ $filter_key ] = $filter_value; + } } - $this->_views = $admin_page->get_list_table_view_RLs($extra_query_args); } - $this->_status = $this->_admin_page->get_registration_status_array(); + return $extra_query_args; } @@ -81,9 +133,6 @@ protected function _setup_data() */ protected function _set_properties() { - $return_url = $this->getReturnUrl(); - $req_data = $this->_admin_page->get_request_data(); - $this->_wp_list_args = [ 'singular' => esc_html__('registration', 'event_espresso'), 'plural' => esc_html__('registrations', 'event_espresso'), @@ -91,10 +140,6 @@ protected function _set_properties() 'screen' => $this->_admin_page->get_current_screen()->id, ]; - $DTT_ID = $req_data['DTT_ID'] ?? 0; - $DTT_ID = $req_data['datetime_id'] ?? $DTT_ID; - $DTT_ID = (int) $DTT_ID; - if ($this->EVT_ID) { $this->_columns = [ 'cb' => '', // Render a checkbox instead of text @@ -122,11 +167,6 @@ protected function _set_properties() ]; } - $csv_report = RegistrationsCsvReportParams::getRequestParams($return_url, $req_data, $this->EVT_ID, $DTT_ID); - if (! empty($csv_report)) { - $this->_bottom_buttons['csv_reg_report'] = $csv_report; - } - $this->_primary_column = 'id'; $this->_sortable_columns = [ '_REG_date' => ['_REG_date' => true], // true means its already sorted @@ -147,6 +187,16 @@ protected function _set_properties() 'id' => ['REG_ID' => false], ]; $this->_hidden_columns = []; + + $csv_report = RegistrationsCsvReportParams::getRequestParams( + $this->getReturnUrl(), + $this->_admin_page->get_request_data(), + $this->EVT_ID, + $this->DTT_ID + ); + if (! empty($csv_report)) { + $this->_bottom_buttons['csv_reg_report'] = $csv_report; + } } @@ -239,14 +289,8 @@ protected function _get_table_filters() $reg_status ? strtoupper($reg_status) : '' ); } - foreach (['event_id', 'datetime_id', 'ticket_id'] as $filter_key) { - if ($this->request->requestParamIsSet($filter_key)) { - $filters[] = EEH_Form_Fields::hidden_input( - $filter_key, - $this->request->getRequestParam($filter_key), - 'reg_' . $filter_key - ); - } + foreach ($this->filters as $filter_key => $filter_value) { + $filters[] = EEH_Form_Fields::hidden_input($filter_key, $filter_value, 'reg_' . $filter_key); } return $filters; } @@ -273,6 +317,21 @@ protected function _add_view_counts() } + private function addWhereParamsForFilters(array $where = []): array + { + if ($this->EVT_ID) { + $where['EVT_ID'] = $this->EVT_ID; + } + if ($this->DTT_ID) { + $where['Ticket.Datetime.DTT_ID'] = $this->DTT_ID; + } + if ($this->TKT_ID) { + $where['TKT_ID'] = $this->TKT_ID; + } + return $where; + } + + /** * @param string $view * @return int @@ -281,20 +340,17 @@ protected function _add_view_counts() */ protected function _total_registrations(string $view = ''): int { - $_where = []; - if ($this->EVT_ID) { - $_where['EVT_ID'] = $this->EVT_ID; - } + $where = $this->addWhereParamsForFilters(); switch ($view) { case 'trash': - return EEM_Registration::instance()->count_deleted([$_where]); + return EEM_Registration::instance()->count_deleted([$where]); case 'incomplete': - $_where['STS_ID'] = EEM_Registration::status_id_incomplete; + $where['STS_ID'] = EEM_Registration::status_id_incomplete; break; default: - $_where['STS_ID'] = ['!=', EEM_Registration::status_id_incomplete]; + $where['STS_ID'] = ['!=', EEM_Registration::status_id_incomplete]; } - return EEM_Registration::instance()->count([$_where]); + return EEM_Registration::instance()->count([$where]); } @@ -335,7 +391,7 @@ protected function _total_registrations_today(): int */ protected function totalRegistrationsYesterday(): int { - $yesterday = date('Y-m-d', current_time('timestamp') - DAY_IN_SECONDS); + $yesterday = date('Y-m-d', current_time('timestamp') - DAY_IN_SECONDS); return $this->totalRegistrationsForDateRange($yesterday, $yesterday); } @@ -349,27 +405,26 @@ protected function totalRegistrationsYesterday(): int */ private function totalRegistrationsForDateRange(string $start_date, string $end_date): int { - $where = [ - 'REG_date' => [ - 'BETWEEN', - [ - EEM_Registration::instance()->convert_datetime_for_query( - 'REG_date', - "$start_date 00:00:00", - 'Y-m-d H:i:s' - ), - EEM_Registration::instance()->convert_datetime_for_query( - 'REG_date', - "$end_date 23:59:59", - 'Y-m-d H:i:s' - ), + $where = $this->addWhereParamsForFilters( + [ + 'REG_date' => [ + 'BETWEEN', + [ + EEM_Registration::instance()->convert_datetime_for_query( + 'REG_date', + "$start_date 00:00:00", + 'Y-m-d H:i:s' + ), + EEM_Registration::instance()->convert_datetime_for_query( + 'REG_date', + "$end_date 23:59:59", + 'Y-m-d H:i:s' + ), + ], ], - ], - 'STS_ID' => ['!=', EEM_Registration::status_id_incomplete], - ]; - if ($this->EVT_ID) { - $where['EVT_ID'] = $this->EVT_ID; - } + 'STS_ID' => ['!=', EEM_Registration::status_id_incomplete], + ] + ); return EEM_Registration::instance()->count([$where]); } diff --git a/admin_pages/registrations/assets/espresso_registrations_admin.css b/admin_pages/registrations/assets/espresso_registrations_admin.css index f2fa04ab395..da4280db993 100644 --- a/admin_pages/registrations/assets/espresso_registrations_admin.css +++ b/admin_pages/registrations/assets/espresso_registrations_admin.css @@ -83,8 +83,8 @@ width: clamp(6rem, 7.5%, 15rem); } -.wp-list-table td.column-_REG_final_price .TKT_name + .reg-overview-paid-event-spn{ - margin-inline-start: var(--ee-margin-nano); +.wp-list-table td.column-PRC_amount .TKT_name { + margin-inline-end: var(--ee-margin-nano); } .espresso-admin .wp-list-table .TXN_paid .dashicons-yes:before { diff --git a/assets/asset-manifest.json b/assets/asset-manifest.json index 27bd14d7d39..15c0e0e0ed9 100644 --- a/assets/asset-manifest.json +++ b/assets/asset-manifest.json @@ -23,17 +23,17 @@ "dates-table-view.css": "/static/css/dates-table-view.fc6705f5.chunk.css", "dates-table-view.js": "/static/js/dates-table-view.6e63357c.chunk.js", "dates-table-view.js.map": "/static/js/dates-table-view.6e63357c.chunk.js.map", - "edtrServices.js": "/static/js/edtrServices.7f51b510.js", - "edtrServices.js.map": "/static/js/edtrServices.7f51b510.js.map", - "edtrServices.php": "/static/js/edtrServices.3dfe4571.asset.php", + "edtrServices.js": "/static/js/edtrServices.67147781.js", + "edtrServices.js.map": "/static/js/edtrServices.67147781.js.map", + "edtrServices.php": "/static/js/edtrServices.bf217bbb.asset.php", "eeComponents.css": "/static/css/eeComponents.ac62fdb0.css", "eeComponents.js": "/static/js/eeComponents.c4d9e11d.js", "eeComponents.js.map": "/static/js/eeComponents.c4d9e11d.js.map", "eeComponents.php": "/static/js/eeComponents.9fbf5b6b.asset.php", "eventEditor.css": "/static/css/eventEditor.83eacf6a.css", - "eventEditor.js": "/static/js/eventEditor.5414d673.js", - "eventEditor.js.map": "/static/js/eventEditor.5414d673.js.map", - "eventEditor.php": "/static/js/eventEditor.102d65dc.asset.php", + "eventEditor.js": "/static/js/eventEditor.a576dbed.js", + "eventEditor.js.map": "/static/js/eventEditor.a576dbed.js.map", + "eventEditor.php": "/static/js/eventEditor.1aefe9f3.asset.php", "events.js": "/static/js/events.28ce1ab2.js", "events.js.map": "/static/js/events.28ce1ab2.js.map", "events.php": "/static/js/events.7bba8cb0.asset.php", @@ -126,9 +126,9 @@ "static/js/blocks.4ab89eab.js.LICENSE.txt": "/static/js/blocks.4ab89eab.js.LICENSE.txt", "static/js/data.43f67b25.js.LICENSE.txt": "/static/js/data.43f67b25.js.LICENSE.txt", "static/js/dates.bbffe846.js.LICENSE.txt": "/static/js/dates.bbffe846.js.LICENSE.txt", - "static/js/edtrServices.7f51b510.js.LICENSE.txt": "/static/js/edtrServices.7f51b510.js.LICENSE.txt", + "static/js/edtrServices.67147781.js.LICENSE.txt": "/static/js/edtrServices.67147781.js.LICENSE.txt", "static/js/eeComponents.c4d9e11d.js.LICENSE.txt": "/static/js/eeComponents.c4d9e11d.js.LICENSE.txt", - "static/js/eventEditor.5414d673.js.LICENSE.txt": "/static/js/eventEditor.5414d673.js.LICENSE.txt", + "static/js/eventEditor.a576dbed.js.LICENSE.txt": "/static/js/eventEditor.a576dbed.js.LICENSE.txt", "static/js/form.2f5f7eed.js.LICENSE.txt": "/static/js/form.2f5f7eed.js.LICENSE.txt", "static/js/formBuilder.b57b46ff.js.LICENSE.txt": "/static/js/formBuilder.b57b46ff.js.LICENSE.txt", "static/js/plugins.9bc32fca.js.LICENSE.txt": "/static/js/plugins.9bc32fca.js.LICENSE.txt", @@ -161,8 +161,8 @@ "static/js/dates.cb8000a0.asset.php" ], "edtrServices": [ - "static/js/edtrServices.7f51b510.js", - "static/js/edtrServices.3dfe4571.asset.php" + "static/js/edtrServices.67147781.js", + "static/js/edtrServices.bf217bbb.asset.php" ], "eeComponents": [ "static/css/eeComponents.ac62fdb0.css", @@ -258,8 +258,8 @@ ], "eventEditor": [ "static/css/eventEditor.83eacf6a.css", - "static/js/eventEditor.5414d673.js", - "static/js/eventEditor.102d65dc.asset.php" + "static/js/eventEditor.a576dbed.js", + "static/js/eventEditor.1aefe9f3.asset.php" ], "wpPluginsPage": [ "static/css/wpPluginsPage.b279b3dc.css", diff --git a/assets/static/js/edtrServices.7f51b510.js b/assets/static/js/edtrServices.67147781.js similarity index 73% rename from assets/static/js/edtrServices.7f51b510.js rename to assets/static/js/edtrServices.67147781.js index e34c0a6a07e..1c8c29efa91 100644 --- a/assets/static/js/edtrServices.7f51b510.js +++ b/assets/static/js/edtrServices.67147781.js @@ -1,3 +1,3 @@ -/*! For license information please see edtrServices.7f51b510.js.LICENSE.txt */ -this.eventespresso=this.eventespresso||{},this.eventespresso.edtrServices=function(t){var e={};function n(r){if(e[r])return e[r].exports;var i=e[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"===typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(r,i,function(e){return t[e]}.bind(null,i));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="/",n(n.s=1530)}([function(t,e){t.exports=window.React},function(t,e,n){"use strict";t.exports=n(77)},function(t,e,n){"use strict";n.d(e,"a",(function(){return a}));var r=n(14);function i(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function a(t){for(var e=1;e=0||(i[n]=t[n]);return i}(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}n.d(e,"a",(function(){return r}))},function(t,e,n){"use strict";n.d(e,"a",(function(){return u}));var r=n(54);var i=n(42),a=n(55);function u(t,e){return Object(r.a)(t)||function(t,e){if("undefined"!==typeof Symbol&&Symbol.iterator in Object(t)){var n=[],r=!0,i=!1,a=void 0;try{for(var u,o=t[Symbol.iterator]();!(r=(u=o.next()).done)&&(n.push(u.value),!e||n.length!==e);r=!0);}catch(c){i=!0,a=c}finally{try{r||null==o.return||o.return()}finally{if(i)throw a}}return n}}(t,e)||Object(i.a)(t,e)||Object(a.a)()}},,,function(t,e){t.exports=window.eventespresso.predicates},,function(t,e,n){"use strict";function r(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}n.d(e,"a",(function(){return r}))},,,function(t,e){t.exports=window.eventespresso.utils},function(t,e){t.exports=window.eventespresso.data},,,,,,function(t,e){t.exports=window.eventespresso.services},,function(t,e){t.exports=window.eventespresso.hooks},function(t,e){t.exports=window.eventespresso.adapters},,,,function(t,e,n){"use strict";n.d(e,"a",(function(){return u}));var r=n(39);var i=n(68),a=n(42);function u(t){return function(t){if(Array.isArray(t))return Object(r.a)(t)}(t)||Object(i.a)(t)||Object(a.a)(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}},,,function(t,e,n){t.exports=n(171)},,function(t,e){t.exports=window.eventespresso.constants},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}n.d(e,"a",(function(){return r}))},,function(t,e,n){"use strict";function r(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n=t.length?{done:!0}:{done:!1,value:t[i++]}},e:function(t){throw t},f:a}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var u,o=!0,c=!1;return{s:function(){n=t[Symbol.iterator]()},n:function(){var t=n.next();return o=t.done,t},e:function(t){c=!0,u=t},f:function(){try{o||null==n.return||n.return()}finally{if(c)throw u}}}}},,,,,function(t,e,n){"use strict";function r(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}n.d(e,"a",(function(){return r}))},,,,,,,,,,,,,function(t,e,n){"use strict";function r(t,e){return(r=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}n.d(e,"a",(function(){return r}))},,,,,,,,,,,,,,,,,function(t,e,n){"use strict";function r(t){return(r="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}n.d(e,"a",(function(){return r}))},function(t,e,n){"use strict";function r(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}n.d(e,"a",(function(){return r}))},,,,,,function(t,e,n){var r=n(388),i="object"==typeof self&&self&&self.Object===Object&&self,a=r||i||Function("return this")();t.exports=a},,,,,,,,,,function(t,e){var n=Array.isArray;t.exports=n},,,,function(t,e,n){"use strict";function r(t){this._maxSize=t,this.clear()}r.prototype.clear=function(){this._size=0,this._values=Object.create(null)},r.prototype.get=function(t){return this._values[t]},r.prototype.set=function(t,e){return this._size>=this._maxSize&&this.clear(),t in this._values||this._size++,this._values[t]=e};var i=/[^.^\]^[]+|(?=\[\]|\.\.)/g,a=/^\d+$/,u=/^\d/,o=/[~`!#$%\^&*+=\-\[\]\\';,/{}|\\":<>\?]/g,c=/^\s*(['"]?)(.*?)(\1)\s*$/,s=new r(512),f=new r(512),l=new r(512);function d(t){return s.get(t)||s.set(t,p(t).map((function(t){return t.replace(c,"$2")})))}function p(t){return t.match(i)}function v(t){return"string"===typeof t&&t&&-1!==["'",'"'].indexOf(t.charAt(0))}function b(t){return!v(t)&&(function(t){return t.match(u)&&!t.match(a)}(t)||function(t){return o.test(t)}(t))}t.exports={Cache:r,split:p,normalizePath:d,setter:function(t){var e=d(t);return f.get(t)||f.set(t,(function(t,n){for(var r=0,i=e.length,a=t;r=0;--a){var u=this.tryEntries[a],o=u.completion;if("root"===u.tryLoc)return i("end");if(u.tryLoc<=this.prev){var c=r.call(u,"catchLoc"),s=r.call(u,"finallyLoc");if(c&&s){if(this.prev=0;--n){var i=this.tryEntries[n];if(i.tryLoc<=this.prev&&r.call(i,"finallyLoc")&&this.prev=0;--e){var n=this.tryEntries[e];if(n.finallyLoc===t)return this.complete(n.completion,n.afterLoc),I(n),b}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.tryLoc===t){var r=n.completion;if("throw"===r.type){var i=r.arg;I(n)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(t,n,r){return this.delegate={iterator:w(t),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=e),b}},t}(t.exports);try{regeneratorRuntime=r}catch(i){Function("r","regeneratorRuntime = r")(r)}},,,,function(t,e){t.exports=window.eventespresso.toaster},,function(t,e,n){"use strict";n.r(e),n.d(e,"TICKET_PRICES_ATTRIBUTE",(function(){return j})),n.d(e,"CREATE_TICKET",(function(){return m})),n.d(e,"UPDATE_TICKET",(function(){return E})),n.d(e,"DELETE_TICKET",(function(){return T})),n.d(e,"BULK_UPDATE_TICKETS",(function(){return g}));var r=n(49),i=n(18),a=n(194),u=n(291),o=n(1289);n.d(e,"useTicketMutator",(function(){return o.a}));var c=n(991);n.d(e,"useReorderTickets",(function(){return c.a}));var s=n(494);n.d(e,"useBulkEditTickets",(function(){return s.a}));var f=n(776);n.d(e,"useBulkDeleteTickets",(function(){return f.a}));var l=n(992);n.d(e,"useUpdateTicketQtyByCapacity",(function(){return l.a}));var d,p,v,b,h,y=n(993);for(var O in y)["default","TICKET_PRICES_ATTRIBUTE","CREATE_TICKET","UPDATE_TICKET","DELETE_TICKET","BULK_UPDATE_TICKETS","useTicketMutator","useReorderTickets","useBulkEditTickets","useBulkDeleteTickets","useUpdateTicketQtyByCapacity"].indexOf(O)<0&&function(t){n.d(e,t,(function(){return y[t]}))}(O);var j=Object(i.gql)(d||(d=Object(r.a)(["\n\tfragment ticketPricesAttribute on EspressoTicket {\n\t\tprices {\n\t\t\tnodes {\n\t\t\t\t...priceAttributes\n\t\t\t}\n\t\t}\n\t}\n\t","\n"])),u.c),m=Object(i.gql)(p||(p=Object(r.a)(["\n\tmutation CREATE_TICKET($input: CreateEspressoTicketInput!) {\n\t\tcreateEspressoTicket(input: $input) {\n\t\t\tespressoTicket {\n\t\t\t\t...ticketAttributes\n\t\t\t\t...ticketPricesAttribute # fetch default prices when a ticket is created.\n\t\t\t}\n\t\t}\n\t}\n\t","\n\t","\n"])),a.c,j),E=Object(i.gql)(v||(v=Object(r.a)(["\n\tmutation UPDATE_TICKET($input: UpdateEspressoTicketInput!) {\n\t\tupdateEspressoTicket(input: $input) {\n\t\t\tespressoTicket {\n\t\t\t\t...ticketAttributes\n\t\t\t\t...ticketPricesAttribute # fetch updated prices when a ticket is updated.\n\t\t\t}\n\t\t}\n\t}\n\t","\n\t","\n"])),a.c,j),T=Object(i.gql)(b||(b=Object(r.a)(["\n\tmutation DELETE_TICKET($input: DeleteEspressoTicketInput!) {\n\t\tdeleteEspressoTicket(input: $input) {\n\t\t\tespressoTicket {\n\t\t\t\t...ticketAttributes\n\t\t\t}\n\t\t}\n\t}\n\t","\n"])),a.c),g=Object(i.gql)(h||(h=Object(r.a)(["\n\tmutation BULK_UPDATE_TICKETS($input: BulkUpdateEspressoTicketInput!) {\n\t\tbulkUpdateEspressoTicket(input: $input) {\n\t\t\tupdated\n\t\t\tfailed\n\t\t}\n\t}\n"])))},,function(t,e,n){"use strict";var r=n(0),i=n(4),a=n(18),u=n(12),o=n(265);e.a=function(){var t,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:u.isNotDefault,n=Object(o.a)(),c=Object(a.useTicketsQuery)(n),s=c.data,f=(null===s||void 0===s||null===(t=s.espressoTickets)||void 0===t?void 0:t.nodes)||[],l=Object(u.getCacheIds)(f);return Object(r.useMemo)((function(){return Object(i.filter)(e,f)}),[l])}},,,,,,,,function(t,e,n){"use strict";var r=n(18);e.a=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:void 0;return Object(r.useUpdateCache)(t)}},,,,,function(t,e,n){"use strict";n.r(e),n.d(e,"CREATE_DATETIME",(function(){return y})),n.d(e,"UPDATE_DATETIME",(function(){return O})),n.d(e,"DELETE_DATETIME",(function(){return j})),n.d(e,"BULK_UPDATE_DATETIMES",(function(){return m}));var r=n(49),i=n(18),a=n(215),u=n(1288);n.d(e,"useDatetimeMutator",(function(){return u.a}));var o=n(492);n.d(e,"useDeleteRelatedTickets",(function(){return o.a}));var c=n(986);n.d(e,"useBulkEditDatetimes",(function(){return c.a}));var s=n(987);n.d(e,"useBulkDeleteDatetimes",(function(){return s.a}));var f=n(988);n.d(e,"useReorderDatetimes",(function(){return f.a}));var l,d,p,v,b=n(989);for(var h in b)["default","CREATE_DATETIME","UPDATE_DATETIME","DELETE_DATETIME","BULK_UPDATE_DATETIMES","useDatetimeMutator","useDeleteRelatedTickets","useBulkEditDatetimes","useBulkDeleteDatetimes","useReorderDatetimes"].indexOf(h)<0&&function(t){n.d(e,t,(function(){return b[t]}))}(h);var y=Object(i.gql)(l||(l=Object(r.a)(["\n\tmutation CREATE_DATETIME($input: CreateEspressoDatetimeInput!) {\n\t\tcreateEspressoDatetime(input: $input) {\n\t\t\tespressoDatetime {\n\t\t\t\t...datetimeAttributes\n\t\t\t}\n\t\t}\n\t}\n\t","\n"])),a.a),O=Object(i.gql)(d||(d=Object(r.a)(["\n\tmutation UPDATE_DATETIME($input: UpdateEspressoDatetimeInput!) {\n\t\tupdateEspressoDatetime(input: $input) {\n\t\t\tespressoDatetime {\n\t\t\t\t...datetimeAttributes\n\t\t\t}\n\t\t}\n\t}\n\t","\n"])),a.a),j=Object(i.gql)(p||(p=Object(r.a)(["\n\tmutation DELETE_DATETIME($input: DeleteEspressoDatetimeInput!) {\n\t\tdeleteEspressoDatetime(input: $input) {\n\t\t\tespressoDatetime {\n\t\t\t\t...datetimeAttributes\n\t\t\t}\n\t\t}\n\t}\n\t","\n"])),a.a),m=Object(i.gql)(v||(v=Object(r.a)(["\n\tmutation BULK_UPDATE_DATETIMES($input: BulkUpdateEspressoDatetimeInput!) {\n\t\tbulkUpdateEspressoDatetime(input: $input) {\n\t\t\tupdated\n\t\t\tfailed\n\t\t}\n\t}\n"])))},,function(t,e,n){"use strict";n.d(e,"c",(function(){return c})),n.d(e,"a",(function(){return s})),n.d(e,"b",(function(){return f}));var r,i,a,u=n(49),o=n(18),c=Object(o.gql)(r||(r=Object(u.a)(["\n\tfragment ticketAttributes on EspressoTicket {\n\t\tid\n\t\tdbId\n\t\tcacheId\n\t\tdescription\n\t\tendDate\n\t\tisDefault\n\t\tisExpired\n\t\tisFree\n\t\tisOnSale\n\t\tisPending\n\t\tisRequired\n\t\tisSoldOut\n\t\tisTrashed\n\t\tmax\n\t\tmin\n\t\tname\n\t\torder\n\t\tprice\n\t\tquantity\n\t\tregistrationCount\n\t\treserved\n\t\treverseCalculate\n\t\tsold\n\t\tstartDate\n\t\tuserId\n\t\tuses\n\t\tvisibility\n\t}\n"]))),s=Object(o.gql)(i||(i=Object(u.a)(["\n\tquery GET_TICKET($id: ID!) {\n\t\tespressoTicket(id: $id) {\n\t\t\t...ticketAttributes\n\t\t}\n\t}\n\t","\n"])),c),f=Object(o.gql)(a||(a=Object(u.a)(["\n\tquery GET_TICKETS($where: EspressoRootQueryTicketsConnectionWhereArgs) {\n\t\tespressoTickets(where: $where) {\n\t\t\tnodes {\n\t\t\t\t...ticketAttributes\n\t\t\t}\n\t\t}\n\t}\n\t","\n"])),c)},,,,,,,,function(t,e,n){var r=n(239),i=n(634),a=n(635),u=r?r.toStringTag:void 0;t.exports=function(t){return null==t?void 0===t?"[object Undefined]":"[object Null]":u&&u in Object(t)?i(t):a(t)}},function(t,e){t.exports=function(t){return null!=t&&"object"==typeof t}},function(t,e,n){var r=n(660);t.exports=function(t){return null==t?"":r(t)}},,,,,,,,,,,function(t,e,n){"use strict";n.d(e,"a",(function(){return c})),n.d(e,"b",(function(){return s})),n.d(e,"c",(function(){return f}));var r,i,a,u=n(49),o=n(18),c=Object(o.gql)(r||(r=Object(u.a)(["\n\tfragment datetimeAttributes on EspressoDatetime {\n\t\tid\n\t\tdbId\n\t\tcacheId\n\t\tcapacity\n\t\tdescription\n\t\tendDate\n\t\tisActive\n\t\tisExpired\n\t\tisPrimary\n\t\tisSoldOut\n\t\tisTrashed\n\t\tisUpcoming\n\t\tlength\n\t\tname\n\t\torder\n\t\treserved\n\t\tsold\n\t\tstatus\n\t\tstartDate\n\t\tvenue\n\t}\n"]))),s=Object(o.gql)(i||(i=Object(u.a)(["\n\tquery GET_DATETIME($id: ID!) {\n\t\tespressoDatetime(id: $id) {\n\t\t\t...datetimeAttributes\n\t\t}\n\t}\n\t","\n"])),c),f=Object(o.gql)(a||(a=Object(u.a)(["\n\tquery GET_DATETIMES($where: EspressoRootQueryDatetimesConnectionWhereArgs) {\n\t\tespressoDatetimes(where: $where) {\n\t\t\tnodes {\n\t\t\t\t...datetimeAttributes\n\t\t\t}\n\t\t}\n\t}\n\t","\n"])),c)},function(t,e,n){"use strict";n.d(e,"c",(function(){return s})),n.d(e,"b",(function(){return f})),n.d(e,"a",(function(){return l})),n.d(e,"d",(function(){return d})),n.d(e,"e",(function(){return p}));var r=n(14),i=n(2),a=n(8),u=n(12),o=n(50),c=n(17),s=function(t,e,n){var r=t.shiftDates,c=Object(a.a)(t,["shiftDates"]),s=[];if((null===r||void 0===r?void 0:r.unit)&&(null===r||void 0===r?void 0:r.value)&&(null===r||void 0===r?void 0:r.type)){var f=Object(u.entitiesWithGuIdInArray)(e,n),l=Object(o.shiftDate)(r);s=f.map((function(t){var e=l(t.startDate).toISOString(),n=l(t.endDate).toISOString();return{id:t.id,startDate:e,endDate:n}}))}else s=n.map((function(t){return{id:t}}));return{sharedInput:Object(i.a)(Object(i.a)({},c),{},{id:""}),uniqueInputs:s}},f=function(t,e){var n=t.uniqueInputs.reduce((function(t,e){return Object(i.a)(Object(i.a)({},t),{},Object(r.a)({},e.id,e))}),{});return e.map((function(e){return(null===n||void 0===n?void 0:n[e.id])?Object(i.a)(Object(i.a)(Object(i.a)(Object(i.a)({},e),t.sharedInput),n[e.id]),{},{cacheId:Object(c.uuid)()}):e}))},l=function(t,e,n){return n?Object(u.entitiesWithGuIdNotInArray)(e,t):e.map((function(e){return t.includes(e.id)?Object(i.a)(Object(i.a)({},e),{},{isTrashed:!0,cacheId:Object(c.uuid)()}):e}))},d=function(t){return Object(i.a)(Object(i.a)({},t),{},{isActive:Object(u.isActive)(t,!0),isExpired:Object(u.isExpired)(t,!0),isUpcoming:Object(u.isUpcoming)(t,!0)})},p=function(t){return Object(i.a)(Object(i.a)({},t),{},{isExpired:Object(u.isExpired)(t,!0),isFree:!t.price,isOnSale:Object(u.isOnSale)(t,!0),isPending:Object(u.isPending)(t,!0)})}},,,,,,function(t,e,n){"use strict";n.d(e,"c",(function(){return Ot})),n.d(e,"a",(function(){return gt})),n.d(e,"b",(function(){return qt}));var r,i,a=n(31),u=n(37),o=n(47);try{r=Map}catch(Bt){}try{i=Set}catch(Bt){}function c(t,e,n){if(!t||"object"!==typeof t||"function"===typeof t)return t;if(t.nodeType&&"cloneNode"in t)return t.cloneNode(!0);if(t instanceof Date)return new Date(t.getTime());if(t instanceof RegExp)return new RegExp(t);if(Array.isArray(t))return t.map(s);if(r&&t instanceof r)return new Map(Array.from(t.entries()));if(i&&t instanceof i)return new Set(Array.from(t.values()));if(t instanceof Object){e.push(t);var a=Object.create(t);for(var u in n.push(a),t){var o=e.findIndex((function(e){return e===t[u]}));a[u]=o>-1?n[o]:c(t[u],e,n)}return a}return t}function s(t){return c(t,[],[])}var f=Object.prototype.toString,l=Error.prototype.toString,d=RegExp.prototype.toString,p="undefined"!==typeof Symbol?Symbol.prototype.toString:function(){return""},v=/^Symbol\((.*)\)(.*)$/;function b(t){return t!=+t?"NaN":0===t&&1/t<0?"-0":""+t}function h(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(null==t||!0===t||!1===t)return""+t;var n=typeof t;if("number"===n)return b(t);if("string"===n)return e?'"'.concat(t,'"'):t;if("function"===n)return"[Function "+(t.name||"anonymous")+"]";if("symbol"===n)return p.call(t).replace(v,"Symbol($1)");var r=f.call(t).slice(8,-1);return"Date"===r?isNaN(t.getTime())?""+t:t.toISOString(t):"Error"===r||t instanceof Error?"["+l.call(t)+"]":"RegExp"===r?d.call(t):null}function y(t,e){var n=h(t,e);return null!==n?n:JSON.stringify(t,(function(t,n){var r=h(this[t],e);return null!==r?r:n}),2)}var O={default:"${path} is invalid",required:"${path} is a required field",oneOf:"${path} must be one of the following values: ${values}",notOneOf:"${path} must not be one of the following values: ${values}",notType:function(t){var e=t.path,n=t.type,r=t.value,i=t.originalValue,a=null!=i&&i!==r,u="".concat(e," must be a `").concat(n,"` type, ")+"but the final value was: `".concat(y(r,!0),"`")+(a?" (cast from the value `".concat(y(i,!0),"`)."):".");return null===r&&(u+='\n If "null" is intended as an empty value be sure to mark the schema as `.nullable()`'),u},defined:"${path} must be defined"},j={length:"${path} must be exactly ${length} characters",min:"${path} must be at least ${min} characters",max:"${path} must be at most ${max} characters",matches:'${path} must match the following: "${regex}"',email:"${path} must be a valid email",url:"${path} must be a valid URL",uuid:"${path} must be a valid UUID",trim:"${path} must be a trimmed string",lowercase:"${path} must be a lowercase string",uppercase:"${path} must be a upper case string"},m={min:"${path} must be greater than or equal to ${min}",max:"${path} must be less than or equal to ${max}",lessThan:"${path} must be less than ${less}",moreThan:"${path} must be greater than ${more}",positive:"${path} must be a positive number",negative:"${path} must be a negative number",integer:"${path} must be an integer"},E={min:"${path} field must be later than ${min}",max:"${path} field must be at earlier than ${max}"},T={isValue:"${path} field must be ${value}"},g={noUnknown:"${path} field has unspecified keys: ${unknown}"},_={min:"${path} field must have at least ${min} items",max:"${path} field must have less than or equal to ${max} items",length:"${path} must have ${length} items"},k=(Object.assign(Object.create(null),{mixed:O,string:j,number:m,date:E,object:g,array:_,boolean:T}),n(151)),D=n.n(k),I=function(t){return t&&t.__isYupSchema__},x=function(){function t(e,n){if(Object(u.a)(this,t),this.fn=void 0,this.refs=e,this.refs=e,"function"!==typeof n){if(!D()(n,"is"))throw new TypeError("`is:` is required for `when()` conditions");if(!n.then&&!n.otherwise)throw new TypeError("either `then:` or `otherwise:` is required for `when()` conditions");var r=n.is,i=n.then,a=n.otherwise,o="function"===typeof r?r:function(){for(var t=arguments.length,e=new Array(t),n=0;n1?"".concat(c.errors.length," errors occurred"):c.errors[0],Error.captureStackTrace&&Error.captureStackTrace(Object(w.a)(c),n),c}return Object(o.a)(n,null,[{key:"formatError",value:function(t,e){var n=e.label||e.path||"this";return n!==e.path&&(e=P({},e,{path:n})),"string"===typeof t?t.replace(R,(function(t,n){return y(e[n])})):"function"===typeof t?t(e):t}},{key:"isError",value:function(t){return t&&"ValidationError"===t.name}}]),n}(Object(S.a)(Error));function M(t,e){var n=t.endEarly,r=t.tests,i=t.args,u=t.value,o=t.errors,c=t.sort,s=t.path,f=function(t){var e=!1;return function(){e||(e=!0,t.apply(void 0,arguments))}}(e),l=r.length,d=[];if(o=o||[],!l)return o.length?f(new U(o,u,s)):f(null,u);for(var p=0;p1&&void 0!==arguments[1]?arguments[1]:{};if(Object(u.a)(this,t),this.key=void 0,this.isContext=void 0,this.isValue=void 0,this.isSibling=void 0,this.path=void 0,this.getter=void 0,this.map=void 0,"string"!==typeof e)throw new TypeError("ref must be a string, got: "+e);if(this.key=e.trim(),""===e)throw new TypeError("ref must be a non-empty string");this.isContext=this.key[0]===q,this.isValue=this.key[0]===G,this.isSibling=!this.isContext&&!this.isValue;var r=this.isContext?q:this.isValue?G:"";this.path=this.key.slice(r.length),this.getter=this.path&&Object($.getter)(this.path,!0),this.map=n.map}return Object(o.a)(t,[{key:"getValue",value:function(t,e,n){var r=this.isContext?n:this.isValue?t:e;return this.getter&&(r=this.getter(r||{})),this.map&&(r=this.map(r)),r}},{key:"cast",value:function(t,e){return this.getValue(t,null==e?void 0:e.parent,null==e?void 0:e.context)}},{key:"resolve",value:function(){return this}},{key:"describe",value:function(){return{type:"ref",key:this.key}}},{key:"toString",value:function(){return"Ref(".concat(this.key,")")}}],[{key:"isRef",value:function(t){return t&&t.__isYupRef}}]),t}();function B(){return(B=Object.assign||function(t){for(var e=1;e=0||(i[n]=t[n]);return i}(e,["value","path","label","options","originalValue","sync"]),l=t.name,d=t.test,p=t.params,v=t.message,b=o.parent,h=o.context;function y(t){return z.isRef(t)?t.getValue(r,b,h):t}function O(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=N()(B({value:r,originalValue:c,label:u,path:t.path||a},p,t.params),y),n=new U(U.formatError(t.message||v,e),r,e.path,t.type||l);return n.params=e,n}var j=B({path:a,parent:b,type:l,createError:O,resolve:y,options:o,originalValue:c},f);if(s){var m;try{var E;if("function"===typeof(null==(E=m=d.call(j,r,j))?void 0:E.then))throw new Error('Validation test of type: "'.concat(j.type,'" returned a Promise during a synchronous validate. ')+"This test will finish after the validate call has returned")}catch(T){return void n(T)}U.isError(m)?n(m):m?n(null,m):n(O())}else try{Promise.resolve(d.call(j,r,j)).then((function(t){U.isError(t)?n(t):t?n(null,t):n(O())})).catch(n)}catch(T){n(T)}}return e.OPTIONS=t,e}z.prototype.__isYupRef=!0;var K=function(t){return t.substr(0,t.length-1).substr(1)};function Q(t,e,n){var r,i,a,u=arguments.length>3&&void 0!==arguments[3]?arguments[3]:n;return e?(Object($.forEach)(e,(function(o,c,s){var f=c?K(o):o;if((t=t.resolve({context:u,parent:r,value:n})).innerType){var l=s?parseInt(f,10):0;if(n&&l>=n.length)throw new Error("Yup.reach cannot resolve an array item at index: ".concat(o,", in the path: ").concat(e,". ")+"because there is no value at that index. ");r=n,n=n&&n[l],t=t.innerType}if(!s){if(!t.fields||!t.fields[f])throw new Error("The schema does not contain the path: ".concat(e,". ")+"(failed at: ".concat(a,' which is a type: "').concat(t._type,'")'));r=n,n=n&&n[f],t=t.fields[f]}i=f,a=c?"["+o+"]":"."+o})),{schema:t,parent:r,parentPath:i}):{parent:r,parentPath:e,schema:t}}var W=n(9),Y=n(80),H=function(){function t(){Object(u.a)(this,t),this.list=void 0,this.refs=void 0,this.list=new Set,this.refs=new Map}return Object(o.a)(t,[{key:"size",get:function(){return this.list.size+this.refs.size}},{key:"describe",value:function(){var t,e=[],n=Object(Y.a)(this.list);try{for(n.s();!(t=n.n()).done;){var r=t.value;e.push(r)}}catch(o){n.e(o)}finally{n.f()}var i,a=Object(Y.a)(this.refs);try{for(a.s();!(i=a.n()).done;){var u=Object(W.a)(i.value,2)[1];e.push(u.describe())}}catch(o){a.e(o)}finally{a.f()}return e}},{key:"toArray",value:function(){return Array.from(this.list).concat(Array.from(this.refs.values()))}},{key:"resolveAll",value:function(t){return this.toArray().reduce((function(e,n){return e.concat(z.isRef(n)?t(n):n)}),[])}},{key:"add",value:function(t){z.isRef(t)?this.refs.set(t.key,t):this.list.add(t)}},{key:"delete",value:function(t){z.isRef(t)?this.refs.delete(t.key):this.list.delete(t)}},{key:"clone",value:function(){var e=new t;return e.list=new Set(this.list),e.refs=new Map(this.refs),e}},{key:"merge",value:function(t,e){var n=this.clone();return t.list.forEach((function(t){return n.add(t)})),t.refs.forEach((function(t){return n.add(t)})),e.list.forEach((function(t){return n.delete(t)})),e.refs.forEach((function(t){return n.delete(t)})),n}}]),t}();function Z(){return(Z=Object.assign||function(t){for(var e=1;e1&&void 0!==arguments[1]?arguments[1]:{},n=this.resolve(Z({value:t},e)),r=n._cast(t,e);if(void 0!==t&&!1!==e.assert&&!0!==n.isType(r)){var i=y(t),a=y(r);throw new TypeError("The value of ".concat(e.path||"field"," could not be cast to a value ")+'that satisfies the schema type: "'.concat(n._type,'". \n\n')+"attempted value: ".concat(i," \n")+(a!==i?"result of cast: ".concat(a):""))}return r}},{key:"_cast",value:function(t,e){var n=this,r=void 0===t?t:this.transforms.reduce((function(e,r){return r.call(n,e,t,n)}),t);return void 0===r&&(r=this.getDefault()),r}},{key:"_validate",value:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2?arguments[2]:void 0,i=n.sync,a=n.path,u=n.from,o=void 0===u?[]:u,c=n.originalValue,s=void 0===c?t:c,f=n.strict,l=void 0===f?this.spec.strict:f,d=n.abortEarly,p=void 0===d?this.spec.abortEarly:d,v=t;l||(v=this._cast(v,Z({assert:!1},n)));var b={value:v,path:a,options:n,originalValue:s,schema:this,label:this.spec.label,sync:i,from:o},h=[];this._typeError&&h.push(this._typeError);var y=[];this._whitelistError&&y.push(this._whitelistError),this._blacklistError&&y.push(this._blacklistError),M({args:b,value:v,path:a,sync:i,tests:h,endEarly:p},(function(t){t?r(t,v):M({tests:e.tests.concat(y),args:b,path:a,sync:i,value:v,endEarly:p},r)}))}},{key:"validate",value:function(t,e,n){var r=this.resolve(Z({},e,{value:t}));return"function"===typeof n?r._validate(t,e,n):new Promise((function(n,i){return r._validate(t,e,(function(t,e){t?i(t):n(e)}))}))}},{key:"validateSync",value:function(t,e){var n;return this.resolve(Z({},e,{value:t}))._validate(t,Z({},e,{sync:!0}),(function(t,e){if(t)throw t;n=e})),n}},{key:"isValid",value:function(t,e){return this.validate(t,e).then((function(){return!0}),(function(t){if(U.isError(t))return!1;throw t}))}},{key:"isValidSync",value:function(t,e){try{return this.validateSync(t,e),!0}catch(n){if(U.isError(n))return!1;throw n}}},{key:"_getDefault",value:function(){var t=this.spec.default;return null==t?t:"function"===typeof t?t.call(this):s(t)}},{key:"getDefault",value:function(t){return this.resolve(t||{})._getDefault()}},{key:"default",value:function(t){if(0===arguments.length)return this._getDefault();var e=this.clone({default:t});return e}},{key:"strict",value:function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],e=this.clone();return e.spec.strict=t,e}},{key:"_isPresent",value:function(t){return null!=t}},{key:"defined",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:O.defined;return this.test({message:t,name:"defined",exclusive:!0,test:function(t){return void 0!==t}})}},{key:"required",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:O.required;return this.clone({presence:"required"}).withMutation((function(e){return e.test({message:t,name:"required",exclusive:!0,test:function(t){return this.schema._isPresent(t)}})}))}},{key:"notRequired",value:function(){var t=this.clone({presence:"optional"});return t.tests=t.tests.filter((function(t){return"required"!==t.OPTIONS.name})),t}},{key:"nullable",value:function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],e=this.clone({nullable:!1!==t});return e}},{key:"transform",value:function(t){var e=this.clone();return e.transforms.push(t),e}},{key:"test",value:function(){var t;if(void 0===(t=1===arguments.length?"function"===typeof(arguments.length<=0?void 0:arguments[0])?{test:arguments.length<=0?void 0:arguments[0]}:arguments.length<=0?void 0:arguments[0]:2===arguments.length?{name:arguments.length<=0?void 0:arguments[0],test:arguments.length<=1?void 0:arguments[1]}:{name:arguments.length<=0?void 0:arguments[0],message:arguments.length<=1?void 0:arguments[1],test:arguments.length<=2?void 0:arguments[2]}).message&&(t.message=O.default),"function"!==typeof t.test)throw new TypeError("`test` is a required parameters");var e=this.clone(),n=V(t),r=t.exclusive||t.name&&!0===e.exclusiveTests[t.name];if(t.exclusive&&!t.name)throw new TypeError("Exclusive tests must provide a unique `name` identifying the test");return t.name&&(e.exclusiveTests[t.name]=!!t.exclusive),e.tests=e.tests.filter((function(e){if(e.OPTIONS.name===t.name){if(r)return!1;if(e.OPTIONS.test===n.OPTIONS.test)return!1}return!0})),e.tests.push(n),e}},{key:"when",value:function(t,e){Array.isArray(t)||"string"===typeof t||(e=t,t=".");var n=this.clone(),r=F(t).map((function(t){return new z(t)}));return r.forEach((function(t){t.isSibling&&n.deps.push(t.key)})),n.conditions.push(new x(r,e)),n}},{key:"typeError",value:function(t){var e=this.clone();return e._typeError=V({message:t,name:"typeError",test:function(t){return!(void 0!==t&&!this.schema.isType(t))||this.createError({params:{type:this.schema._type}})}}),e}},{key:"oneOf",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:O.oneOf,n=this.clone();return t.forEach((function(t){n._whitelist.add(t),n._blacklist.delete(t)})),n._whitelistError=V({message:e,name:"oneOf",test:function(t){if(void 0===t)return!0;var e=this.schema._whitelist,n=e.resolveAll(this.resolve);return!!n.includes(t)||this.createError({params:{values:e.toArray().join(", "),resolved:n}})}}),n}},{key:"notOneOf",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:O.notOneOf,n=this.clone();return t.forEach((function(t){n._blacklist.add(t),n._whitelist.delete(t)})),n._blacklistError=V({message:e,name:"notOneOf",test:function(t){var e=this.schema._blacklist,n=e.resolveAll(this.resolve);return!n.includes(t)||this.createError({params:{values:e.toArray().join(", "),resolved:n}})}}),n}},{key:"strip",value:function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],e=this.clone();return e.spec.strip=t,e}},{key:"describe",value:function(){var t=this.clone(),e=t.spec,n=e.label;return{meta:e.meta,label:n,type:t.type,oneOf:t._whitelist.describe(),notOneOf:t._blacklist.describe(),tests:t.tests.map((function(t){return{name:t.OPTIONS.name,params:t.OPTIONS.params}})).filter((function(t,e,n){return n.findIndex((function(e){return e.name===t.name}))===e}))}}}]),t}();J.prototype.__isYupSchema__=!0;for(var X=function(){var t=et[tt];J.prototype["".concat(t,"At")]=function(e,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=Q(this,e,n,r.context),a=i.parent,u=i.parentPath,o=i.schema;return o[t](a&&a[u],Z({},r,{parent:a,path:e}))}},tt=0,et=["validate","validateSync"];tt0&&void 0!==arguments[0]?arguments[0]:T.isValue;return this.test({message:t,name:"is-value",exclusive:!0,params:{value:"true"},test:function(t){return st(t)||!0===t}})}},{key:"isFalse",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:T.isValue;return this.test({message:t,name:"is-value",exclusive:!0,params:{value:"false"},test:function(t){return st(t)||!1===t}})}}]),n}(J);ft.prototype;var lt=n(59),dt=n(46),pt=/^((([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+(\.([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+)*)|((\x22)((((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(([\x01-\x08\x0b\x0c\x0e-\x1f\x7f]|\x21|[\x23-\x5b]|[\x5d-\x7e]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(\\([\x01-\x09\x0b\x0c\x0d-\x7f]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]))))*(((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(\x22)))@((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))$/i,vt=/^((https?|ftp):)?\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,bt=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,ht=function(t){return st(t)||t===t.trim()},yt={}.toString();function Ot(){return new jt}var jt=function(t){Object(C.a)(n,t);var e=Object(A.a)(n);function n(){var t;return Object(u.a)(this,n),(t=e.call(this,{type:"string"})).withMutation((function(){t.transform((function(t){if(this.isType(t))return t;if(Array.isArray(t))return t;var e=null!=t&&t.toString?t.toString():t;return e===yt?t:e}))})),t}return Object(o.a)(n,[{key:"_typeCheck",value:function(t){return t instanceof String&&(t=t.valueOf()),"string"===typeof t}},{key:"_isPresent",value:function(t){return Object(lt.a)(Object(dt.a)(n.prototype),"_isPresent",this).call(this,t)&&!!t.length}},{key:"length",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:j.length;return this.test({message:e,name:"length",exclusive:!0,params:{length:t},test:function(e){return st(e)||e.length===this.resolve(t)}})}},{key:"min",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:j.min;return this.test({message:e,name:"min",exclusive:!0,params:{min:t},test:function(e){return st(e)||e.length>=this.resolve(t)}})}},{key:"max",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:j.max;return this.test({name:"max",exclusive:!0,message:e,params:{max:t},test:function(e){return st(e)||e.length<=this.resolve(t)}})}},{key:"matches",value:function(t,e){var n,r,i=!1;if(e)if("object"===typeof e){var a=e.excludeEmptyString;i=void 0!==a&&a,n=e.message,r=e.name}else n=e;return this.test({name:r||"matches",message:n||j.matches,params:{regex:t},test:function(e){return st(e)||""===e&&i||-1!==e.search(t)}})}},{key:"email",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:j.email;return this.matches(pt,{name:"email",message:t,excludeEmptyString:!0})}},{key:"url",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:j.url;return this.matches(vt,{name:"url",message:t,excludeEmptyString:!0})}},{key:"uuid",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:j.uuid;return this.matches(bt,{name:"uuid",message:t,excludeEmptyString:!1})}},{key:"ensure",value:function(){return this.default("").transform((function(t){return null===t?"":t}))}},{key:"trim",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:j.trim;return this.transform((function(t){return null!=t?t.trim():t})).test({message:t,name:"trim",test:ht})}},{key:"lowercase",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:j.lowercase;return this.transform((function(t){return st(t)?t:t.toLowerCase()})).test({message:t,name:"string_case",exclusive:!0,test:function(t){return st(t)||t===t.toLowerCase()}})}},{key:"uppercase",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:j.uppercase;return this.transform((function(t){return st(t)?t:t.toUpperCase()})).test({message:t,name:"string_case",exclusive:!0,test:function(t){return st(t)||t===t.toUpperCase()}})}}]),n}(J);Ot.prototype=jt.prototype;var mt=function(t){Object(C.a)(n,t);var e=Object(A.a)(n);function n(){var t;return Object(u.a)(this,n),(t=e.call(this,{type:"number"})).withMutation((function(){t.transform((function(t){var e=t;if("string"===typeof e){if(""===(e=e.replace(/\s/g,"")))return NaN;e=+e}return this.isType(e)?e:parseFloat(e)}))})),t}return Object(o.a)(n,[{key:"_typeCheck",value:function(t){return t instanceof Number&&(t=t.valueOf()),"number"===typeof t&&!function(t){return t!=+t}(t)}},{key:"min",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:m.min;return this.test({message:e,name:"min",exclusive:!0,params:{min:t},test:function(e){return st(e)||e>=this.resolve(t)}})}},{key:"max",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:m.max;return this.test({message:e,name:"max",exclusive:!0,params:{max:t},test:function(e){return st(e)||e<=this.resolve(t)}})}},{key:"lessThan",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:m.lessThan;return this.test({message:e,name:"max",exclusive:!0,params:{less:t},test:function(e){return st(e)||e1&&void 0!==arguments[1]?arguments[1]:m.moreThan;return this.test({message:e,name:"min",exclusive:!0,params:{more:t},test:function(e){return st(e)||e>this.resolve(t)}})}},{key:"positive",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:m.positive;return this.moreThan(0,t)}},{key:"negative",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:m.negative;return this.lessThan(0,t)}},{key:"integer",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:m.integer;return this.test({name:"integer",message:t,test:function(t){return st(t)||Number.isInteger(t)}})}},{key:"truncate",value:function(){return this.transform((function(t){return st(t)?t:0|t}))}},{key:"round",value:function(t){var e,n=["ceil","floor","round","trunc"];if("trunc"===(t=(null==(e=t)?void 0:e.toLowerCase())||"round"))return this.truncate();if(-1===n.indexOf(t.toLowerCase()))throw new TypeError("Only valid options for round() are: "+n.join(", "));return this.transform((function(e){return st(e)?e:Math[t](e)}))}}]),n}(J);mt.prototype;var Et=/^(\d{4}|[+\-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,\.](\d{1,}))?)?(?:(Z)|([+\-])(\d{2})(?::?(\d{2}))?)?)?$/;var Tt=new Date("");function gt(){return new _t}var _t=function(t){Object(C.a)(n,t);var e=Object(A.a)(n);function n(){var t;return Object(u.a)(this,n),(t=e.call(this,{type:"date"})).withMutation((function(){t.transform((function(t){return this.isType(t)?t:(t=function(t){var e,n,r=[1,4,5,6,7,10,11],i=0;if(n=Et.exec(t)){for(var a,u=0;a=r[u];++u)n[a]=+n[a]||0;n[2]=(+n[2]||1)-1,n[3]=+n[3]||1,n[7]=n[7]?String(n[7]).substr(0,3):0,void 0!==n[8]&&""!==n[8]||void 0!==n[9]&&""!==n[9]?("Z"!==n[8]&&void 0!==n[9]&&(i=60*n[10]+n[11],"+"===n[9]&&(i=0-i)),e=Date.UTC(n[1],n[2],n[3],n[4],n[5]+i,n[6],n[7])):e=+new Date(n[1],n[2],n[3],n[4],n[5],n[6],n[7])}else e=Date.parse?Date.parse(t):NaN;return e}(t),isNaN(t)?Tt:new Date(t))}))})),t}return Object(o.a)(n,[{key:"_typeCheck",value:function(t){return e=t,"[object Date]"===Object.prototype.toString.call(e)&&!isNaN(t.getTime());var e}},{key:"prepareParam",value:function(t,e){var n;if(z.isRef(t))n=t;else{var r=this.cast(t);if(!this._typeCheck(r))throw new TypeError("`".concat(e,"` must be a Date or a value that can be `cast()` to a Date"));n=r}return n}},{key:"min",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:E.min,n=this.prepareParam(t,"min");return this.test({message:e,name:"min",exclusive:!0,params:{min:t},test:function(t){return st(t)||t>=this.resolve(n)}})}},{key:"max",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:E.max,n=this.prepareParam(t,"max");return this.test({message:e,name:"max",exclusive:!0,params:{max:t},test:function(t){return st(t)||t<=this.resolve(n)}})}}]),n}(J);_t.INVALID_DATE=Tt,gt.prototype=_t.prototype,gt.INVALID_DATE=Tt;var kt=n(327),Dt=n.n(kt),It=n(433),xt=n.n(It),wt=n(434),Ct=n.n(wt),At=n(435),St=n.n(At);function Ft(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=[],r=new Set,i=new Set(e.map((function(t){var e=Object(W.a)(t,2),n=e[0],r=e[1];return"".concat(n,"-").concat(r)})));function a(t,e){var a=Object($.split)(t)[0];r.add(a),i.has("".concat(e,"-").concat(a))||n.push([e,a])}var u=function(e){if(D()(t,e)){var n=t[e];r.add(e),z.isRef(n)&&n.isSibling?a(n.path,e):I(n)&&"deps"in n&&n.deps.forEach((function(t){return a(t,e)}))}};for(var o in t)u(o);return St.a.array(Array.from(r),n).reverse()}function Pt(t,e){var n=1/0;return t.some((function(t,r){var i;if(-1!==(null==(i=e.path)?void 0:i.indexOf(t)))return n=r,!0})),n}function Rt(t){return function(e,n){return Pt(t,e)-Pt(t,n)}}function Ut(){return(Ut=Object.assign||function(t){for(var e=1;e1&&void 0!==arguments[1]?arguments[1]:{},a=Object(lt.a)(Object(dt.a)(n.prototype),"_cast",this).call(this,t,i);if(void 0===a)return this.getDefault();if(!this._typeCheck(a))return a;var u,o=this.fields,c=null!=(e=i.stripUnknown)?e:this.spec.noUnknown,s=this._nodes.concat(Object.keys(a).filter((function(t){return-1===r._nodes.indexOf(t)}))),f={},l=Ut({},i,{parent:f,__validating:i.__validating||!1}),d=!1,p=Object(Y.a)(s);try{for(p.s();!(u=p.n()).done;){var v=u.value,b=o[v],h=D()(a,v);if(b){var y=void 0,O=a[v];l.path=(i.path?"".concat(i.path,"."):"")+v;var j="spec"in(b=b.resolve({value:O,context:i.context,parent:f}))?b.spec:void 0,m=null==j?void 0:j.strict;if(null==j?void 0:j.strip){d=d||v in a;continue}void 0!==(y=i.__validating&&m?a[v]:b.cast(a[v],l))&&(f[v]=y)}else h&&!c&&(f[v]=a[v]);f[v]!==a[v]&&(d=!0)}}catch(E){p.e(E)}finally{p.f()}return d?f:a}},{key:"_validate",value:function(t){var e=this,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=arguments.length>2?arguments[2]:void 0,u=[],o=r.sync,c=r.from,s=void 0===c?[]:c,f=r.originalValue,l=void 0===f?t:f,d=r.abortEarly,p=void 0===d?this.spec.abortEarly:d,v=r.recursive,b=void 0===v?this.spec.recursive:v;s=[{schema:this,value:l}].concat(Object(a.a)(s)),r.__validating=!0,r.originalValue=l,r.from=s,Object(lt.a)(Object(dt.a)(n.prototype),"_validate",this).call(this,t,r,(function(t,n){if(t){if(!U.isError(t)||p)return void i(t,n);u.push(t)}if(b&&Mt(n)){l=l||n;var a=e._nodes.map((function(t){return function(i,a){var u=-1===t.indexOf(".")?(r.path?"".concat(r.path,"."):"")+t:"".concat(r.path||"",'["').concat(t,'"]'),o=e.fields[t];o&&"validate"in o?o.validate(n[t],Ut({},r,{path:u,from:s,strict:!0,parent:n,originalValue:l[t]}),a):a(null)}}));M({sync:o,tests:a,value:n,errors:u,endEarly:p,sort:e._sortErrors,path:r.path},i)}else i(u[0]||null,n)}))}},{key:"clone",value:function(t){var e=Object(lt.a)(Object(dt.a)(n.prototype),"clone",this).call(this,t);return e.fields=Ut({},this.fields),e._nodes=this._nodes,e._excludedEdges=this._excludedEdges,e._sortErrors=this._sortErrors,e}},{key:"concat",value:function(t){for(var e=this,r=Object(lt.a)(Object(dt.a)(n.prototype),"concat",this).call(this,t),i=r.fields,a=0,u=Object.entries(this.fields);a1&&void 0!==arguments[1]?arguments[1]:[],n=this.clone(),r=Object.assign(n.fields,t);return n.fields=r,n._sortErrors=Rt(Object.keys(r)),e.length&&(Array.isArray(e[0])||(e=[e]),n._excludedEdges=[].concat(Object(a.a)(n._excludedEdges),Object(a.a)(e))),n._nodes=Ft(r,n._excludedEdges),n}},{key:"pick",value:function(t){var e,n={},r=Object(Y.a)(t);try{for(r.s();!(e=r.n()).done;){var i=e.value;this.fields[i]&&(n[i]=this.fields[i])}}catch(a){r.e(a)}finally{r.f()}return this.clone().withMutation((function(t){return t.fields={},t.shape(n)}))}},{key:"omit",value:function(t){var e=this.clone(),n=e.fields;e.fields={};var r,i=Object(Y.a)(t);try{for(i.s();!(r=i.n()).done;){var a=r.value;delete n[a]}}catch(u){i.e(u)}finally{i.f()}return e.withMutation((function(){return e.shape(n)}))}},{key:"from",value:function(t,e,n){var r=Object($.getter)(t,!0);return this.transform((function(i){if(null==i)return i;var a=i;return D()(i,t)&&(a=Ut({},i),n||delete a[t],a[e]=r(i)),a}))}},{key:"noUnknown",value:function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:g.noUnknown;"string"===typeof t&&(e=t,t=!0);var n=this.test({name:"noUnknown",exclusive:!0,message:e,test:function(e){if(null==e)return!0;var n=Lt(this.schema,e);return!t||0===n.length||this.createError({params:{unknown:n.join(", ")}})}});return n.spec.noUnknown=t,n}},{key:"unknown",value:function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:g.noUnknown;return this.noUnknown(!t,e)}},{key:"transformKeys",value:function(t){return this.transform((function(e){return e&&Ct()(e,(function(e,n){return t(n)}))}))}},{key:"camelCase",value:function(){return this.transformKeys(xt.a)}},{key:"snakeCase",value:function(){return this.transformKeys(Dt.a)}},{key:"constantCase",value:function(){return this.transformKeys((function(t){return Dt()(t).toUpperCase()}))}},{key:"describe",value:function(){var t=Object(lt.a)(Object(dt.a)(n.prototype),"describe",this).call(this);return t.fields=N()(this.fields,(function(t){return t.describe()})),t}}]),n}(J);function qt(t){return new $t(t)}function Gt(){return(Gt=Object.assign||function(t){for(var e=1;e1&&void 0!==arguments[1]?arguments[1]:{},u=arguments.length>2?arguments[2]:void 0,o=[],c=a.sync,s=a.path,f=this.innerType,l=null!=(e=a.abortEarly)?e:this.spec.abortEarly,d=null!=(r=a.recursive)?r:this.spec.recursive,p=null!=a.originalValue?a.originalValue:t;Object(lt.a)(Object(dt.a)(n.prototype),"_validate",this).call(this,t,a,(function(t,e){if(t){if(!U.isError(t)||l)return void u(t,e);o.push(t)}if(d&&f&&i._typeCheck(e)){p=p||e;for(var n=new Array(e.length),r=function(t){var r=e[t],i="".concat(a.path||"","[").concat(t,"]"),u=Gt({},a,{path:i,strict:!0,parent:e,index:t,originalValue:p[t]});n[t]=function(t,e){return f.validate(r,u,e)}},v=0;v1&&void 0!==arguments[1]?arguments[1]:_.length;return this.test({message:e,name:"length",exclusive:!0,params:{length:t},test:function(e){return st(e)||e.length===this.resolve(t)}})}},{key:"min",value:function(t,e){return e=e||_.min,this.test({message:e,name:"min",exclusive:!0,params:{min:t},test:function(e){return st(e)||e.length>=this.resolve(t)}})}},{key:"max",value:function(t,e){return e=e||_.max,this.test({message:e,name:"max",exclusive:!0,params:{max:t},test:function(e){return st(e)||e.length<=this.resolve(t)}})}},{key:"ensure",value:function(){var t=this;return this.default((function(){return[]})).transform((function(e,n){return t._typeCheck(e)?e:null==n?[]:[].concat(n)}))}},{key:"compact",value:function(t){var e=t?function(e,n,r){return!t(e,n,r)}:function(t){return!!t};return this.transform((function(t){return null!=t?t.filter(e):t}))}},{key:"describe",value:function(){var t=Object(lt.a)(Object(dt.a)(n.prototype),"describe",this).call(this);return this.innerType&&(t.innerType=this.innerType.describe()),t}},{key:"nullable",value:function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return Object(lt.a)(Object(dt.a)(n.prototype),"nullable",this).call(this,t)}},{key:"defined",value:function(){return Object(lt.a)(Object(dt.a)(n.prototype),"defined",this).call(this)}},{key:"required",value:function(t){return Object(lt.a)(Object(dt.a)(n.prototype),"required",this).call(this,t)}}]),n}(J);zt.prototype},,,,,function(t,e){t.exports=window.eventespresso.slotFill},,,function(t,e,n){"use strict";var r=n(264),i=n(26),a=n(12),u=n(18);e.a=function(){var t,e=Object(r.a)(),n=Object(u.useDatetimesQuery)(e).data,o=(null===n||void 0===n||null===(t=n.espressoDatetimes)||void 0===t?void 0:t.nodes)||[],c=Object(a.getCacheIds)(o);return Object(i.useMemoStringify)(o,c)}},function(t,e,n){"use strict";n.r(e),n.d(e,"CREATE_PRICE",(function(){return p})),n.d(e,"UPDATE_PRICE",(function(){return v})),n.d(e,"DELETE_PRICE",(function(){return b}));var r=n(49),i=n(18),a=n(291),u=n(1281);n.d(e,"usePriceMutator",(function(){return u.a}));var o=n(994);n.d(e,"useBulkDeletePrices",(function(){return o.a}));var c,s,f,l=n(995);for(var d in l)["default","CREATE_PRICE","UPDATE_PRICE","DELETE_PRICE","usePriceMutator","useBulkDeletePrices"].indexOf(d)<0&&function(t){n.d(e,t,(function(){return l[t]}))}(d);var p=Object(i.gql)(c||(c=Object(r.a)(["\n\tmutation CREATE_PRICE($input: CreateEspressoPriceInput!) {\n\t\tcreateEspressoPrice(input: $input) {\n\t\t\tespressoPrice {\n\t\t\t\t...priceAttributes\n\t\t\t}\n\t\t}\n\t}\n\t","\n"])),a.c),v=Object(i.gql)(s||(s=Object(r.a)(["\n\tmutation UPDATE_PRICE($input: UpdateEspressoPriceInput!) {\n\t\tupdateEspressoPrice(input: $input) {\n\t\t\tespressoPrice {\n\t\t\t\t...priceAttributes\n\t\t\t}\n\t\t}\n\t}\n\t","\n"])),a.c),b=Object(i.gql)(f||(f=Object(r.a)(["\n\tmutation DELETE_PRICE($input: DeleteEspressoPriceInput!) {\n\t\tdeleteEspressoPrice(input: $input) {\n\t\t\tespressoPrice {\n\t\t\t\tid\n\t\t\t}\n\t\t}\n\t}\n"])))},,,,,,function(t,e,n){"use strict";n(159)},function(t,e,n){"use strict";n.r(e);var r=n(1329);n.d(e,"useCacheRehydration",(function(){return r.a}));var i=n(1364);n.d(e,"useTicketsMeta",(function(){return i.a}));var a=n(385);for(var u in a)["default","useCacheRehydration","useTicketsMeta"].indexOf(u)<0&&function(t){n.d(e,t,(function(){return a[t]}))}(u);var o=n(79);for(var u in o)["default","useCacheRehydration","useTicketsMeta"].indexOf(u)<0&&function(t){n.d(e,t,(function(){return o[t]}))}(u);var c=n(996);n.d(e,"DateStatus",(function(){return c.a})),n.d(e,"isDatetime",(function(){return c.c})),n.d(e,"PriceBasetype",(function(){return c.b}))},function(t,e,n){var r=n(122).Symbol;t.exports=r},function(t,e,n){var r=n(148)(Object,"create");t.exports=r},function(t,e,n){var r=n(650),i=n(651),a=n(652),u=n(653),o=n(654);function c(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e-1&&t%1==0&&t<=9007199254740991}},function(t,e,n){var r=n(666),i=n(672),a=n(676);t.exports=function(t){return a(t)?r(t):i(t)}},,,,,,,,,,,,,,,,,,,,,,,,,function(t,e,n){var r=n(405)((function(t,e,n){return t+(n?"_":"")+e.toLowerCase()}));t.exports=r},,,,,,,,function(t,e,n){"use strict";n.d(e,"q",(function(){return d})),n.d(e,"e",(function(){return b})),n.d(e,"c",(function(){return p.b})),n.d(e,"d",(function(){return p.c})),n.d(e,"b",(function(){return p.a})),n.d(e,"g",(function(){return v.b})),n.d(e,"h",(function(){return v.c})),n.d(e,"f",(function(){return v.a})),n.d(e,"p",(function(){return O})),n.d(e,"n",(function(){return h.b})),n.d(e,"o",(function(){return h.c})),n.d(e,"m",(function(){return h.a})),n.d(e,"j",(function(){return y.b})),n.d(e,"k",(function(){return y.c})),n.d(e,"i",(function(){return y.a})),n.d(e,"r",(function(){return m})),n.d(e,"l",(function(){return f})),n.d(e,"a",(function(){return l}));var r=n(2),i=n(18),a=n(27),u=n(227),o=n(24),c=n(45),s=n(1),f=function(t){var e=t.children;return Object(s.jsx)(a.ThemeProvider,{children:Object(s.jsx)(o.StatusProvider,{children:Object(s.jsx)(o.ConfigProvider,{children:Object(s.jsx)(o.FeaturesProvider,{children:Object(s.jsx)(o.RelationsProvider,{children:Object(s.jsx)(u.SlotFillProvider,{children:Object(s.jsx)(c.GlobalModalProvider,{children:e})})})})})})})},l=function(t){var e=t.children;return Object(s.jsx)(i.DataProvider,{children:Object(s.jsx)(f,{children:e})})},d=function(t){return function(e){return Object(s.jsx)(l,{children:Object(s.jsx)(t,Object(r.a)({},e))})}},p=n(428),v=n(429),b=function(t){var e=t.children;return Object(s.jsx)(p.c,{children:Object(s.jsx)(v.c,{children:e})})},h=n(430),y=n(431),O=function(t){var e=t.children;return Object(s.jsx)(h.c,{children:Object(s.jsx)(y.c,{children:e})})},j=n(8),m=function(t){var e=t.Provider,n=t.Component,i=Object(j.a)(t,["Provider","Component"]);return function(){return Object(s.jsx)(e,{children:Object(s.jsx)(n,Object(r.a)({},i))})}}},function(t,e,n){"use strict";n.d(e,"a",(function(){return r.a})),n.d(e,"b",(function(){return r.b})),n.d(e,"c",(function(){return r.c})),n.d(e,"d",(function(){return o})),n.d(e,"e",(function(){return f})),n.d(e,"h",(function(){return l.a})),n.d(e,"f",(function(){return d.a})),n.d(e,"g",(function(){return u.a})),n.d(e,"i",(function(){return b}));var r=n(215),i=n(26),a=n(12),u=n(230),o=function(){var t=Object(u.a)();return Object(i.useMemoStringify)(Object(a.getGuids)(t))},c=n(0),s=n(18),f=function(t){var e=t.id,n=Object(c.useMemo)((function(){return{query:r.b,variables:{id:e},returnPartialData:!0}}),[e]),a=Object(s.useCacheQuery)(n).data;return Object(i.useMemoStringify)(null===a||void 0===a?void 0:a.espressoDatetime)},l=n(771),d=n(264),p=n(17),v=n(24),b=function(t){var e=t.entity,n=t.entityId,r=Object(u.a)(),i=(0,Object(v.useRelations)().getRelations)({entity:e,entityId:n,relation:"datetimes"}),o=Object(p.entityListCacheIdString)(r),s=JSON.stringify(i);return Object(c.useMemo)((function(){return Object(a.entitiesWithGuIdInArray)(r,i)}),[s,o])}},function(t,e,n){"use strict";n.d(e,"c",(function(){return r.c})),n.d(e,"d",(function(){return r.d})),n.d(e,"a",(function(){return r.a})),n.d(e,"b",(function(){return r.b})),n.d(e,"e",(function(){return i.a})),n.d(e,"f",(function(){return a.a})),n.d(e,"g",(function(){return f}));var r=n(291),i=n(366),a=n(425),u=n(0),o=n(12),c=n(17),s=n(24),f=function(t){var e=t.entity,n=t.entityId,r=Object(a.a)(),i=(0,Object(s.useRelations)().getRelations)({entity:e,entityId:n,relation:"prices"}),f=Object(c.entityListCacheIdString)(r),l=JSON.stringify(i);return Object(u.useMemo)((function(){return Object(o.entitiesWithGuIdInArray)(r,i)}),[l,f])}},,,function(t,e,n){"use strict";n.r(e),n.d(e,"UPDATE_EVENT",(function(){return f}));var r=n(49),i=n(18),a=n(424),u=n(1337);n.d(e,"useEventMutator",(function(){return u.a}));var o,c=n(990);for(var s in c)["default","UPDATE_EVENT","useEventMutator"].indexOf(s)<0&&function(t){n.d(e,t,(function(){return c[t]}))}(s);var f=Object(i.gql)(o||(o=Object(r.a)(["\n\tmutation UPDATE_EVENT($input: UpdateEspressoEventInput!) {\n\t\tupdateEspressoEvent(input: $input) {\n\t\t\tespressoEvent {\n\t\t\t\t...eventAttributes\n\t\t\t}\n\t\t}\n\t}\n\t","\n"])),a.a)},function(t,e,n){"use strict";var r;n.d(e,"a",(function(){return r})),function(t){t.start="start",t.end="end",t.both="both"}(r||(r={}))},,,,,,,,,,,,,,,,,,,,,,,,,function(t,e,n){"use strict";var r=n(2),i=n(0),a=n(291),u=n(275);e.a=function(t){var e=Object(u.a)();return Object(i.useMemo)((function(){return{query:a.b,variables:{where:Object(r.a)({eventId:e,includeDefaultTicketsPrices:!0,includeDefaultPrices:!0},t)}}}),[e,t])}},function(t,e,n){"use strict";var r=n(2),i=n(31),a=n(0),u=n(4),o=n(12),c=n(265);e.a=function(){var t=Object(c.a)();return Object(a.useCallback)((function(e){var n,a=e.cache,c=e.tickets,s=e.ticket,f=e.action,l=c.nodes,d=void 0===l?[]:l,p=[];switch(f){case"add":p=[].concat(Object(i.a)(d),[s]);break;case"update":(n=Object(u.findIndex)(Object(o.entityHasGuid)(s.id),d))>=0&&(p=Object(u.update)(n,s,d));break;case"remove":p=d.filter((function(t){return t.id!==s.id}));break;default:p=d}var v=Object(r.a)(Object(r.a)({},t),{},{data:{espressoTickets:Object(r.a)(Object(r.a)({},c),{},{nodes:p})}});a.writeQuery(v)}),[t])}},function(t,e,n){"use strict";var r,i=n(43),a=n(49),u=n(34),o=n.n(u),c=n(0),s=n(18),f=Object(s.gql)(r||(r=Object(a.a)(["\n\tmutation BULK_DELETE_ENTITIES($input: BulkDeleteEspressoEntitiesInput!) {\n\t\tbulkDeleteEspressoEntities(input: $input) {\n\t\t\tdeleted\n\t\t\tfailed\n\t\t}\n\t}\n"])));e.a=function(t){var e=t.entityType,n=t.typeName,r=Object(s.useMutationWithFeedback)({typeName:n,mutationType:s.MutationType.Delete,mutation:f});return Object(c.useCallback)(function(){var t=Object(i.a)(o.a.mark((function t(n){var i,a,u;return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return i=n.entityIds,a=n.deletePermanently,u=n.updateEntityList,t.next=3,r({variables:{input:{clientMutationId:"BULK_DELETE_ENTITIES",entityIds:i,entityType:e,deletePermanently:a}},update:u});case 3:return t.abrupt("return",t.sent);case 4:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),[r,e])}},,,,,,,,,,,,,,,,function(t,e,n){var r=n(981);t.exports=function(t){return function e(n){return 0===arguments.length||r(n)?e:t.apply(this,arguments)}}},function(t,e,n){"use strict";n.r(e),n.d(e,"mutations",(function(){return l}));var r=n(192),i=n(340),a=n(177),u=n(231);for(var o in r)["default","mutations","useUpdateCallback"].indexOf(o)<0&&function(t){n.d(e,t,(function(){return r[t]}))}(o);for(var o in i)["default","mutations","useUpdateCallback"].indexOf(o)<0&&function(t){n.d(e,t,(function(){return i[t]}))}(o);for(var o in a)["default","mutations","useUpdateCallback"].indexOf(o)<0&&function(t){n.d(e,t,(function(){return a[t]}))}(o);for(var o in u)["default","mutations","useUpdateCallback"].indexOf(o)<0&&function(t){n.d(e,t,(function(){return u[t]}))}(o);var c=n(216);n.d(e,"formToBulkUpdateInput",(function(){return c.c})),n.d(e,"cacheNodesFromBulkInput",(function(){return c.b})),n.d(e,"cacheNodesFromBulkDelete",(function(){return c.a})),n.d(e,"updateDatetimeFlags",(function(){return c.d})),n.d(e,"updateTicketFlags",(function(){return c.e}));var s=n(254);n.d(e,"TypeName",(function(){return s.a}));var f=n(276);n.d(e,"useUpdateCallback",(function(){return f.a}));var l={CREATE_DATETIME:r.CREATE_DATETIME,UPDATE_DATETIME:r.UPDATE_DATETIME,DELETE_DATETIME:r.DELETE_DATETIME,UPDATE_EVENT:i.UPDATE_EVENT,CREATE_TICKET:a.CREATE_TICKET,UPDATE_TICKET:a.UPDATE_TICKET,DELETE_TICKET:a.DELETE_TICKET,CREATE_PRICE:u.CREATE_PRICE,UPDATE_PRICE:u.UPDATE_PRICE,DELETE_PRICE:u.DELETE_PRICE}},function(t,e,n){var r=n(387),i=n(392),a=n(132),u=n(393),o=n(301),c=n(244);t.exports=function(t,e,n){for(var s=-1,f=(e=r(e,t)).length,l=!1;++s-1&&t%1==0&&tf))return!1;var d=c.get(t),p=c.get(e);if(d&&p)return d==e&&p==t;var v=-1,b=!0,h=2&n?new r:void 0;for(c.set(t,e),c.set(e,t);++v0&&void 0!==arguments[0]?arguments[0]:void 0,e=Object(u.a)(),n=Object(i.useMemo)((function(){return Object(r.a)(Object(r.a)({},e),t)}),[e,t]);return Object(a.a)(n)}},function(t,e,n){"use strict";var r=n(2),i=n(0),a=n(187),u=n(265);e.a=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:void 0,e=Object(u.a)(),n=Object(i.useMemo)((function(){return Object(r.a)(Object(r.a)({},e),t)}),[e,t]);return Object(a.a)(n)}},,,,,,,,,,,,,,,,function(t,e,n){"use strict";var r=n(424);n.d(e,"a",(function(){return r.a})),n.d(e,"b",(function(){return r.b}));var i=n(980);n.d(e,"c",(function(){return i.a}));var a=n(554);n.d(e,"e",(function(){return a.a}));var u=n(275);n.d(e,"d",(function(){return u.a}))},,,,,,,,,,,,,,,,,function(t,e,n){"use strict";n.d(e,"c",(function(){return r.c})),n.d(e,"a",(function(){return r.a})),n.d(e,"b",(function(){return r.b})),n.d(e,"f",(function(){return u})),n.d(e,"e",(function(){return c})),n.d(e,"g",(function(){return s.a})),n.d(e,"h",(function(){return f.a})),n.d(e,"i",(function(){return l})),n.d(e,"j",(function(){return v})),n.d(e,"k",(function(){return y})),n.d(e,"l",(function(){return O.a})),n.d(e,"m",(function(){return a.a})),n.d(e,"d",(function(){return E}));var r=n(194),i=n(12),a=n(179),u=function(){return Object(a.a)(i.isDefault)},o=n(26),c=function(){var t=u();return Object(o.useMemoStringify)(Object(i.getGuids)(t))},s=n(772),f=n(773),l=function(){var t=Object(a.a)();return Object(o.useMemoStringify)(Object(i.getGuids)(t))},d=n(0),p=n(18),v=function(t){var e=t.id,n=Object(d.useMemo)((function(){return{query:r.a,variables:{id:e},returnPartialData:!0}}),[e]),i=Object(p.useCacheQuery)(n).data;return Object(o.useMemoStringify)(null===i||void 0===i?void 0:i.espressoTicket)},b=n(24),h=n(425),y=function(){var t=Object(h.a)(),e=Object(b.useRelations)().getRelations;return Object(d.useCallback)((function(n){var r=e({entity:"tickets",entityId:n,relation:"prices"});return Object(i.entitiesWithGuIdInArray)(t,r)}),[e,t])},O=n(265),j=n(4),m=n(230),E=function(){var t=Object(m.a)(),e=Object(b.useRelations)().getRelations;return Object(d.useCallback)((function(n){var r=n.capacity,a=n.quantity,u=n.ticketId,o=n.relatedDateIds,c=void 0===o?[]:o,s=(null===c||void 0===c?void 0:c.length)?c:e({entity:"tickets",entityId:u,relation:"datetimes"}),f=j.isNil(r)?Object(i.minDateCapacity)(t)(s):r;return Object(i.ticketQuantityFromCapacity)(f)(a)}),[t,e])}},function(t,e,n){"use strict";n.d(e,"c",(function(){return r.c})),n.d(e,"a",(function(){return r.a})),n.d(e,"b",(function(){return r.b})),n.d(e,"g",(function(){return c})),n.d(e,"d",(function(){return s})),n.d(e,"e",(function(){return p})),n.d(e,"f",(function(){return u.a}));var r=n(575),i=n(18),a=n(26),u=n(426),o=n(12),c=function(){var t,e=Object(u.a)(),n=Object(i.useCacheQuery)(e).data,r=(null===n||void 0===n||null===(t=n.espressoPriceTypes)||void 0===t?void 0:t.nodes)||[],c=Object(o.getCacheIds)(r);return Object(a.useMemoStringify)(r,c)},s=function(){var t=c(),e=Object(o.getDefaultPriceModifierType)(t);return Object(a.useMemoStringify)(e)},f=n(1429),l=n.n(f),d=n(24),p=function(t){var e=(0,Object(d.useRelations)().getRelations)({entity:"prices",entityId:t,relation:"priceTypes"}),n=s(),r=c(),i=Object(o.entitiesWithGuIdInArray)(r,e),u=l()(i)?n:i[0];return Object(a.useMemoStringify)(u)}},,,,,,,,function(t,e,n){"use strict";var r=n(43),i=n(34),a=n.n(i),u=n(0),o=n(24),c=n(776);e.a=function(){var t=Object(o.useRelations)().getRelations,e=Object(c.a)();return Object(u.useCallback)(function(){var n=Object(r.a)(a.a.mark((function n(r,i){var u,o;return a.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:if(u=t({entity:"datetimes",entityId:r,relation:"tickets"}),!(o=u.filter((function(e){return 1===t({entity:"tickets",entityId:e,relation:"datetimes"}).length}))).length){n.next=5;break}return n.next=5,e({entityIds:o,deletePermanently:i,deleteRemotely:!1,relatedDatetimeIds:[r]});case 5:case"end":return n.stop()}}),n)})));return function(t,e){return n.apply(this,arguments)}}(),[e,t])}},function(t,e,n){"use strict";n.d(e,"a",(function(){return i}));var r=n(138),i=Object(r.getHooks)()},function(t,e,n){"use strict";var r=n(8),i=n(2),a=n(0),u=n(4),o=n(18),c=n(179),s=n(265),f=n(450),l=n(177),d=n(75),p=n(216),v=n(583),b=n(584);e.a=function(){var t=Object(c.a)(u.identity),e=Object(s.a)(),n=Object(f.a)(),h=Object(v.a)(),y=Object(b.a)(),O=Object(o.useMutationWithFeedback)({typeName:d.a.TICKET,mutationType:o.MutationType.Update,mutation:l.BULK_UPDATE_TICKETS}),j=Object(a.useCallback)((function(a){return function(){var u={nodes:Object(p.b)(a,t).map(p.e),__typename:"EspressoRootQueryTicketsConnection"};n(Object(i.a)(Object(i.a)({},e),{},{data:{espressoTickets:u}})),a.uniqueInputs.forEach((function(t){var e=t.datetimes,n=t.prices,i=Object(r.a)(t,["datetimes","prices"]);h({ticket:i,datetimeIds:e,priceIds:n})}))}}),[t,h,e,n]),m=Object(a.useCallback)((function(t){var e={input:Object(i.a)({clientMutationId:"BULK_UPDATE_TICKETS"},t)},n=Object(u.unnest)(t.uniqueInputs.map((function(t){return y({input:t})}))).filter(Boolean);return O({variables:e,update:j(t),refetchQueries:n})}),[O,j,y]);return Object(a.useMemo)((function(){return{updateEntities:m}}),[m])}},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(t,e,n){"use strict";var r=n(0),i=function(){var t,e,n,r;return(null===(t=window)||void 0===t||null===(e=t.eventEspressoData)||void 0===e||null===(n=e.eventEditor)||void 0===n||null===(r=n.event)||void 0===r?void 0:r.id)||""},a=n(424);e.a=function(){var t=i();return Object(r.useMemo)((function(){return{query:a.b,variables:{id:t}}}),[t])}},,,,,,,,,,,,,,,,,,,,,function(t,e,n){"use strict";n.d(e,"c",(function(){return c})),n.d(e,"a",(function(){return s})),n.d(e,"b",(function(){return f}));var r,i,a,u=n(49),o=n(18),c=Object(o.gql)(r||(r=Object(u.a)(["\n\tfragment priceTypeAttributes on EspressoPriceType {\n\t\tid\n\t\tdbId\n\t\tbaseType\n\t\tcacheId\n\t\tisBasePrice\n\t\tisDiscount\n\t\tisPercent\n\t\tisTax\n\t\tisTrashed\n\t\tname\n\t\torder\n\t}\n"]))),s=Object(o.gql)(i||(i=Object(u.a)(["\n\tquery GET_PRICE_TYPE($id: ID!) {\n\t\tpriceType(id: $id) {\n\t\t\t...priceTypeAttributes\n\t\t}\n\t}\n\t","\n"])),c),f=Object(o.gql)(a||(a=Object(u.a)(["\n\tquery GET_PRICE_TYPES {\n\t\tespressoPriceTypes {\n\t\t\tnodes {\n\t\t\t\t...priceTypeAttributes\n\t\t\t}\n\t\t}\n\t}\n\t","\n"])),c)},function(t,e,n){"use strict";var r=n(2),i=n(31),a=n(0),u=n(4),o=n(12),c=n(264);e.a=function(){var t=Object(c.a)();return Object(a.useCallback)((function(e){var n,a=e.cache,c=e.datetimes,s=e.datetime,f=e.action,l=c.nodes,d=void 0===l?[]:l,p=[];switch(f){case"add":p=[].concat(Object(i.a)(d),[s]);break;case"update":(n=Object(u.findIndex)(Object(o.entityHasGuid)(s.id),d))>=0&&(p=Object(u.update)(n,s,d));break;case"remove":p=d.filter((function(t){return t.id!==s.id}));break;default:p=d}var v=Object(r.a)(Object(r.a)({},t),{},{data:{espressoDatetimes:Object(r.a)(Object(r.a)({},c),{},{nodes:p})}});a.writeQuery(v)}),[t])}},function(t,e,n){"use strict";var r=n(31),i=n(194),a=n(4);e.a=function(t){var e,n,u=t.cache,o=t.datetimeIn,c=t.datetimeId,s=t.action,f={query:i.b,variables:{where:{datetimeIn:Object(a.sortBy)(a.identity,o)}}};try{n=u.readQuery(f)}catch(p){n=null}if(null===(e=n)||void 0===e?void 0:e.espressoTickets){var l;switch(s){case"add":l=[].concat(Object(r.a)(o),[c]);break;case"remove":l=o.filter((function(t){return t!==c}));break;default:l=o}var d={query:i.b,data:n,variables:{where:{datetimeIn:Object(a.sortBy)(a.identity,l)}}};u.writeQuery(d)}}},function(t,e,n){"use strict";var r=n(0),i=n(24),a=n(12);e.a=function(){var t=Object(i.useRelations)(),e=t.addRelation,n=t.removeRelation,u=t.updateRelations;return Object(r.useCallback)((function(t){var r=t.datetime,i=t.tickets;if(!Object(a.hasTempId)(r)){var o=null===r||void 0===r?void 0:r.id;i&&(n({entity:"datetimes",entityId:o,relation:"tickets"}),i.length&&(u({entity:"datetimes",entityId:o,relation:"tickets",relationIds:i}),i.forEach((function(t){e({entity:"tickets",entityId:t,relation:"datetimes",relationId:o})}))))}}),[e,n,u])}},function(t,e,n){"use strict";var r=n(2),i=n(0),a=n(577),u=n(576),o=n(24),c=n(12);e.a=function(){var t=Object(o.useRelations)(),e=t.dropRelations,n=t.removeRelation,s=Object(u.a)();return Object(i.useCallback)((function(t){var i=t.cache,u=t.datetimes,o=t.datetime,f=t.deletePermanently,l=f?"remove":"update";if(!Object(c.hasTempId)(o)&&f){var d=u.nodes,p=void 0===d?[]:d,v=Object(c.getGuids)(p),b=o.id;Object(a.a)({cache:i,datetimeIn:v,datetimeId:b,action:l}),n({entity:"datetimes",entityId:b,relation:"tickets"}),e({entity:"datetimes",entityId:b})}s({cache:i,datetimes:u,datetime:Object(r.a)(Object(r.a)({},o),{},{isTrashed:!0}),action:l})}),[e,n,s])}},function(t,e,n){"use strict";var r=n(2),i=n(0),a=n(24),u=n(12),o=n(581),c=n(367);e.a=function(){var t=Object(a.useRelations)(),e=t.dropRelations,n=t.removeRelation,s=Object(c.a)();return Object(i.useCallback)((function(t){var i=t.cache,a=t.tickets,c=t.ticket,f=t.deletePermanently,l=f?"remove":"update";if(!Object(u.hasTempId)(c)&&f){var d=a.nodes,p=void 0===d?[]:d,v=Object(u.getGuids)(p),b=c.id;Object(o.a)({cache:i,ticketIn:v,ticketId:b,action:l}),n({entity:"tickets",entityId:b,relation:"datetimes"}),n({entity:"tickets",entityId:b,relation:"prices"}),e({entity:"tickets",entityId:b})}s({cache:i,tickets:a,ticket:Object(r.a)(Object(r.a)({},c),{},{isTrashed:!0}),action:l})}),[e,n,s])}},function(t,e,n){"use strict";var r=n(31),i=n(4),a=n(291),u=n(79),o=n(12);e.a=function(t){var e,n,c,s=t.cache,f=t.prices,l=void 0===f?null:f,d=t.ticketIn,p=t.ticketId,v=t.action,b={query:a.b,variables:{where:{ticketIn:Object(i.sortBy)(i.identity,d),includeDefaultPrices:!0}}};try{n=s.readQuery(b)}catch(E){}switch((null===(e=n)||void 0===e?void 0:e.espressoPrices)||(n={espressoPrices:u.DEFAULT_PRICE_LIST_DATA}),v){case"add":c=[].concat(Object(r.a)(d),[p]);break;case"remove":c=d.filter((function(t){return t!==p}));break;default:c=d}var h=(null===l||void 0===l?void 0:l.nodes)||[],y=["espressoPrices","nodes"];if("add"===v&&h.length){var O=Object(i.pathOr)([],y,n),j=Object(i.uniqBy)(o.entityDbId,[].concat(Object(r.a)(O),Object(r.a)(h)));n=Object(i.assocPath)(y,j,n)}if(Object(i.pathOr)([],y,n).length){var m={query:a.b,data:n,variables:{where:{ticketIn:Object(i.sortBy)(i.identity,c),includeDefaultPrices:!0}}};s.writeQuery(m)}}},function(t,e,n){"use strict";n.d(e,"a",(function(){return O}));var r,i=n(31),a=n(2),u=n(43),o=n(9),c=n(49),s=n(34),f=n.n(s),l=n(0),d=n(4),p=n(3),v=n(18),b=n(175),h=n(12),y=Object(v.gql)(r||(r=Object(c.a)(["\n\tmutation REORDER_ENTITIES($input: ReorderEspressoEntitiesInput!) {\n\t\treorderEspressoEntities(input: $input) {\n\t\t\tok\n\t\t}\n\t}\n"]))),O=function(t){var e=t.entityType,n=t.filteredEntities,r=Object(b.useSystemNotifications)(),c=Object(l.useState)([]),s=Object(o.a)(c,2),O=s[0],j=s[1],m=Object(l.useState)(n),E=Object(o.a)(m,2),T=E[0],g=E[1],_=Object(v.useMutation)(y),k=Object(o.a)(_,2),D=k[0],I=k[1],x=Object(l.useCallback)(Object(u.a)(f.a.mark((function t(){return f.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,D({variables:{input:{clientMutationId:"REORDER_ENTITIES",entityIds:O,entityType:e}}});case 2:return r.success({message:Object(p.__)("order updated")}),t.abrupt("return",!0);case 4:case"end":return t.stop()}}),t)}))),[O,e,D,r]);Object(l.useEffect)((function(){g(n)}),[n]);var w=Object(l.useCallback)((function(t){var e=t.allEntities,n=t.newIndex,r=t.oldIndex;if(!(n===r||n<0||r<0)){var u=Object(d.clone)(T.map((function(t){return t.id}))),c=Object(d.clone)(e),s=u.splice(r,1),f=Object(o.a)(s,1)[0];u.splice(n,0,f);var l=u.map((function(t,e){var n=c.findIndex((function(e){return e.id===t})),r=c.splice(n,1),i=Object(o.a)(r,1)[0];return Object(a.a)(Object(a.a)({},i),{},{order:e+1})}));return(c=[].concat(Object(i.a)(l),Object(i.a)(c))).map((function(t,e){return Object(a.a)(Object(a.a)({},t),{},{order:e+1})})),g(l),j(Object(h.getGuids)(c)),c}}),[T]);return Object(l.useMemo)((function(){return{allReorderedEntities:T,updateSortOrder:x,result:I,sortEntities:w}}),[T,x,I,w])}},function(t,e,n){"use strict";var r=n(0),i=n(24),a=n(12),u=n(367);e.a=function(){var t=Object(i.useRelations)(),e=t.addRelation,n=t.removeRelation,o=t.updateRelations,c=Object(u.a)();return Object(r.useCallback)((function(t){var r=t.cache,i=t.tickets,u=t.ticket,s=t.datetimeIds,f=t.priceIds;if(!Object(a.hasTempId)(u)){var l=u.id;s&&(n({entity:"tickets",entityId:l,relation:"datetimes"}),s.length&&(o({entity:"tickets",entityId:l,relation:"datetimes",relationIds:s}),s.forEach((function(t){e({entity:"datetimes",entityId:t,relation:"tickets",relationId:l})})))),f&&(n({entity:"tickets",entityId:l,relation:"prices"}),f.length&&(o({entity:"tickets",entityId:l,relation:"prices",relationIds:f}),f.forEach((function(t){e({entity:"prices",entityId:t,relation:"tickets",relationId:l})})))),r&&i&&c({cache:r,tickets:i,ticket:u,action:"update"})}}),[e,n,o,c])}},function(t,e,n){"use strict";var r=n(0),i=n(4),a=n(24),u=n(18),o=n(215);e.a=function(){var t=Object(a.useRelations)().getRelations;return Object(r.useCallback)((function(e){var n=e.input,r=e.mutationType,a=void 0===r?u.MutationType.Update:r;if(n.id&&n.datetimes||a===u.MutationType.Delete){var c=t({entity:"tickets",entityId:n.id,relation:"datetimes"});return i.difference(i.union(c,n.datetimes||[]),i.intersection(c,n.datetimes||[])).map((function(t){return{query:o.b,variables:{id:t}}}))}}),[t])}},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(t,e){t.exports=function(t,e){return Object.prototype.hasOwnProperty.call(e,t)}},function(t,e){var n=Object.prototype.hasOwnProperty;t.exports=function(t,e){return null!=t&&n.call(t,e)}},function(t,e,n){var r=n(239),i=Object.prototype,a=i.hasOwnProperty,u=i.toString,o=r?r.toStringTag:void 0;t.exports=function(t){var e=a.call(t,o),n=t[o];try{t[o]=void 0;var r=!0}catch(c){}var i=u.call(t);return r&&(e?t[o]=n:delete t[o]),i}},function(t,e){var n=Object.prototype.toString;t.exports=function(t){return n.call(t)}},function(t,e,n){var r=n(637),i=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,a=/\\(\\)?/g,u=r((function(t){var e=[];return 46===t.charCodeAt(0)&&e.push(""),t.replace(i,(function(t,n,r,i){e.push(r?i.replace(a,"$1"):n||t)})),e}));t.exports=u},function(t,e,n){var r=n(638);t.exports=function(t){var e=r(t,(function(t){return 500===n.size&&n.clear(),t})),n=e.cache;return e}},function(t,e,n){var r=n(298);function i(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new TypeError("Expected a function");var n=function n(){var r=arguments,i=e?e.apply(this,r):r[0],a=n.cache;if(a.has(i))return a.get(i);var u=t.apply(this,r);return n.cache=a.set(i,u)||a,u};return n.cache=new(i.Cache||r),n}i.Cache=r,t.exports=i},function(t,e,n){var r=n(640),i=n(241),a=n(300);t.exports=function(){this.size=0,this.__data__={hash:new r,map:new(a||i),string:new r}}},function(t,e,n){var r=n(641),i=n(646),a=n(647),u=n(648),o=n(649);function c(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e-1}},function(t,e,n){var r=n(242);t.exports=function(t,e){var n=this.__data__,i=r(n,t);return i<0?(++this.size,n.push([t,e])):n[i][1]=e,this}},function(t,e,n){var r=n(243);t.exports=function(t){var e=r(this,t).delete(t);return this.size-=e?1:0,e}},function(t,e){t.exports=function(t){var e=typeof t;return"string"==e||"number"==e||"symbol"==e||"boolean"==e?"__proto__"!==t:null===t}},function(t,e,n){var r=n(243);t.exports=function(t){return r(this,t).get(t)}},function(t,e,n){var r=n(243);t.exports=function(t){return r(this,t).has(t)}},function(t,e,n){var r=n(243);t.exports=function(t,e){var n=r(this,t),i=n.size;return n.set(t,e),this.size+=n.size==i?0:1,this}},function(t,e,n){var r=n(239),i=n(661),a=n(132),u=n(297),o=r?r.prototype:void 0,c=o?o.toString:void 0;t.exports=function t(e){if("string"==typeof e)return e;if(a(e))return i(e,t)+"";if(u(e))return c?c.call(e):"";var n=e+"";return"0"==n&&1/e==-Infinity?"-0":n}},function(t,e){t.exports=function(t,e){for(var n=-1,r=null==t?0:t.length,i=Array(r);++n=i?t:r(t,e,n)}},function(t,e){t.exports=function(t,e,n){var r=-1,i=t.length;e<0&&(e=-e>i?0:i+e),(n=n>i?i:n)<0&&(n+=i),i=e>n?0:n-e>>>0,e>>>=0;for(var a=Array(i);++r0&&void 0!==arguments[0]?arguments[0]:void 0,e=Object(a.a)(),n=Object(u.useMemo)((function(){return Object(r.a)(Object(r.a)({},e),t)}),[e,t]);return Object(i.a)(n)}},function(t,e,n){"use strict";var r=n(43),i=n(80),a=n(2),u=n(34),o=n.n(u),c=n(0),s=n(4),f=n(18),l=n(12),d=n(179),p=n(265),v=n(79),b=n(450),h=n(368),y=n(216),O=n(75),j=n(580);e.a=function(){var t=Object(d.a)(),e=Object(p.a)(),n=Object(b.a)(),u=Object(j.a)(),m=Object(f.useApolloClient)().cache,E=Object(h.a)({entityType:"TICKET",typeName:O.a.TICKET}),T=Object(c.useCallback)((function(r){var o=r.entityIds,c=r.deletePermanently,f=r.relatedDatetimeIds;return function(){var r,d;try{d=m.readQuery(e)}catch(I){d=null}var p,b,h=(null===(r=d)||void 0===r?void 0:r.espressoTickets)||v.DEFAULT_TICKET_LIST_DATA,O=Object(l.findEntityByGuid)(h.nodes),j=Object(a.a)({},h),E=Object(i.a)(o);try{for(E.s();!(b=E.n()).done;){var T=b.value;p=O(T),u({cache:m,tickets:j,ticket:p,deletePermanently:c}),j.nodes=Object(l.entitiesWithGuIdNotInArray)(j.nodes,[T])}}catch(x){E.e(x)}finally{E.f()}var g,_=Object(y.a)(o,t,c);if(f.length){var k=["variables","where","datetimeIn"],D=Object(s.pathOr)([],k,e).filter((function(t){return!f.includes(t)}));g=Object(s.assocPath)(k,D,e)}n(Object(a.a)(Object(a.a)(Object(a.a)({},e),g),{},{data:{espressoTickets:Object(a.a)(Object(a.a)({},h),{},{nodes:_})}}))}}),[t,m,u,e,n]);return Object(c.useCallback)(function(){var t=Object(r.a)(o.a.mark((function t(e){var n,r,i,a,u,c;return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(n=e.entityIds,r=e.deletePermanently,i=e.deleteRemotely,a=void 0===i||i,u=e.relatedDatetimeIds,c=T({entityIds:n,deletePermanently:r,relatedDatetimeIds:void 0===u?[]:u}),!a){t.next=6;break}return t.next=5,E({entityIds:n,deletePermanently:r,updateEntityList:c});case 5:return t.abrupt("return",t.sent);case 6:c();case 7:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),[E,T])}},function(t,e,n){"use strict";var r=n(0),i=n(63),a=n.n(i),u=n(428);e.a=function(){var t=Object(r.useContext)(u.b);return a()(t,"useDatesListFilterState must be used inside component"),t}},function(t,e,n){"use strict";n.d(e,"a",(function(){return a}));var r=n(18),i=Object(r.makeVar)([]),a=function(){return Object(r.useReactiveVariable)(i)}},function(t,e,n){"use strict";var r=n(0),i=n(63),a=n.n(i),u=n(430);e.a=function(){var t=Object(r.useContext)(u.b);return a()(t,"useTicketsListFilterState must be used inside component"),t}},function(t,e,n){"use strict";n.d(e,"a",(function(){return a}));var r=n(18),i=Object(r.makeVar)([]),a=function(){return Object(r.useReactiveVariable)(i)}},,,,,,,,,,,,,,,,,,,,,,function(t,e,n){"use strict";var r=n(2),i=n(9),a=n(0),u=n(24),o=n(12),c=n(259),s=n(341),f=n(75),l=function(t,e){var n=e.displayStartOrEndDate,i=e.sales,a=e.status,u=e.recurrence;switch(e.type){case"SET_DISPLAY_START_OR_END_DATE":return Object(r.a)(Object(r.a)({},t),{},{displayStartOrEndDate:n});case"SET_SALES":return Object(r.a)(Object(r.a)({},t),{},{sales:i});case"SET_STATUS":return Object(r.a)(Object(r.a)({},t),{},{status:a});case"SET_RECURRENCE":return Object(r.a)(Object(r.a)({},t),{},{recurrence:u});default:throw new Error("Unknown action")}},d={displayStartOrEndDate:s.a.start,sales:o.DatetimeSales.all,status:o.DatetimeStatus.activeUpcoming,recurrence:""};e.a=function(){var t=Object(c.useSessionStorageReducer)("dates-list-filter-state",l,d),e=Object(i.a)(t,2),n=e[0],o=e[1],s=Object(u.useEntityListFilterStateManager)("order",f.c),p=s.setPageNumber,v=Object(a.useCallback)((function(t,e){e!==n[t]&&p(1)}),[p,n]),b=Object(a.useCallback)((function(t){o({type:"SET_DISPLAY_START_OR_END_DATE",displayStartOrEndDate:t})}),[o]),h=Object(a.useCallback)((function(t){v("sales",t),o({type:"SET_SALES",sales:t})}),[o,v]),y=Object(a.useCallback)((function(t){v("status",t),o({type:"SET_STATUS",status:t})}),[o,v]),O=Object(a.useCallback)((function(t){v("recurrence",t),o({type:"SET_RECURRENCE",recurrence:t})}),[o,v]);return Object(a.useMemo)((function(){return Object(r.a)(Object(r.a)(Object(r.a)({},n),s),{},{setDisplayStartOrEndDate:b,setSales:h,setStatus:y,setRecurrence:O})}),[n,s,b,h,y,O])}},function(t,e,n){"use strict";var r=n(2),i=n(9),a=n(0),u=n(341),o=n(75),c=n(24),s=n(778),f=n(259),l=n(12),d=function(t,e){var n=e.displayStartOrEndDate,i=e.sales,a=e.status;switch(e.type){case"SET_DISPLAY_START_OR_END_DATE":return Object(r.a)(Object(r.a)({},t),{},{displayStartOrEndDate:n});case"SET_SALES":return Object(r.a)(Object(r.a)({},t),{},{sales:i});case"SET_STATUS":return Object(r.a)(Object(r.a)({},t),{},{status:a});case"TOGGLE_IS_CHAINED":return Object(r.a)(Object(r.a)({},t),{},{isChained:!t.isChained});default:throw new Error("Unknown action")}},p={displayStartOrEndDate:u.a.start,isChained:!0,sales:l.TicketsSales.all,status:l.TicketsStatus.onSaleAndPending};e.a=function(){var t=Object(f.useSessionStorageReducer)("ticket-list-filter-state",d,p),e=Object(i.a)(t,2),n=e[0],u=e[1],l=Object(a.useState)(""),v=Object(i.a)(l,2),b=v[0],h=v[1],y=Object(s.a)(),O=Object(i.a)(y,1)[0],j=Object(c.useEntityListFilterStateManager)("order",o.e),m=j.setPageNumber;Object(a.useEffect)((function(){n.isChained&&h(O.join(":"))}),[n.isChained,O]);var E=Object(a.useCallback)((function(t,e){e!==n[t]&&m(1)}),[m,n]),T=Object(a.useCallback)((function(t){u({type:"SET_DISPLAY_START_OR_END_DATE",displayStartOrEndDate:t})}),[u]),g=Object(a.useCallback)((function(t){E("sales",t),u({type:"SET_SALES",sales:t})}),[u,E]),_=Object(a.useCallback)((function(t){E("status",t),u({type:"SET_STATUS",status:t})}),[u,E]),k=Object(a.useCallback)((function(){u({type:"TOGGLE_IS_CHAINED"})}),[u]);return Object(a.useMemo)((function(){return Object(r.a)(Object(r.a)(Object(r.a)({},n),j),{},{setDisplayStartOrEndDate:T,setSales:g,setStatus:_,toggleIsChained:k,visibleDatesStr:b})}),[j,b,T,g,k,n,_])}},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(t,e,n){"use strict";var r=n(18),i=n(554),a=n(26);e.a=function(){var t=Object(i.a)(),e=Object(r.useCacheQuery)(t).data;return Object(a.useMemoStringify)(null===e||void 0===e?void 0:e.espressoEvent)}},function(t,e){t.exports=function(t){return null!=t&&"object"===typeof t&&!0===t["@@functional/placeholder"]}},function(t,e,n){var r=n(632),i=Object.prototype.toString,a=function(){return"[object Arguments]"===i.call(arguments)?function(t){return"[object Arguments]"===i.call(t)}:function(t){return r("callee",t)}}();t.exports=a},function(t,e){},function(t,e,n){"use strict";var r=n(2),i=n(0),a=n(187),u=n(426);e.a=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:void 0,e=Object(u.a)(),n=Object(i.useMemo)((function(){return Object(r.a)(Object(r.a)({},e),t)}),[e,t]);return Object(a.a)(n)}},function(t,e,n){"use strict";var r=n(2),i=n(0),a=n(187),u=n(427);e.a=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:void 0,e=Object(u.a)(),n=Object(i.useMemo)((function(){return Object(r.a)(Object(r.a)({},e),t)}),[e,t]);return Object(a.a)(n)}},function(t,e,n){"use strict";var r=n(8),i=n(2),a=n(0),u=n(18),o=n(230),c=n(264),s=n(192),f=n(578),l=n(449),d=n(216),p=n(75);e.a=function(){var t=Object(o.a)(),e=Object(c.a)(),n=Object(l.a)(),v=Object(f.a)(),b=Object(u.useMutationWithFeedback)({typeName:p.a.DATETIME,mutationType:u.MutationType.Update,mutation:s.BULK_UPDATE_DATETIMES}),h=Object(a.useCallback)((function(a){return function(){var u={nodes:Object(d.b)(a,t).map(d.d),__typename:"EspressoRootQueryDatetimesConnection"};n(Object(i.a)(Object(i.a)({},e),{},{data:{espressoDatetimes:u}})),a.uniqueInputs.forEach((function(t){var e=t.tickets,n=Object(r.a)(t,["tickets"]);v({datetime:n,tickets:e})}))}}),[t,v,e,n]),y=Object(a.useCallback)((function(t){var e={input:Object(i.a)({clientMutationId:"BULK_UPDATE_DATETIMES"},t)};return b({variables:e,update:h(t)})}),[b,h]);return Object(a.useMemo)((function(){return{updateEntities:y}}),[y])}},function(t,e,n){"use strict";var r=n(2),i=n(80),a=n(43),u=n(34),o=n.n(u),c=n(0),s=n(18),f=n(12),l=n(230),d=n(264),p=n(79),v=n(449),b=n(368),h=n(216),y=n(579),O=n(492),j=n(75);e.a=function(){var t=Object(l.a)(),e=Object(d.a)(),n=Object(v.a)(),u=Object(y.a)(),m=Object(s.useApolloClient)().cache,E=Object(b.a)({entityType:"DATETIME",typeName:j.a.DATETIME}),T=Object(O.a)(),g=Object(c.useCallback)((function(c,s){return Object(a.a)(o.a.mark((function a(){var l,d,v,b,y,O,j,E,g,_,k,D,I,x;return o.a.wrap((function(a){for(;;)switch(a.prev=a.next){case 0:d=Object(i.a)(c),a.prev=1,d.s();case 3:if((v=d.n()).done){a.next=9;break}return b=v.value,a.next=7,T(b,s);case 7:a.next=3;break;case 9:a.next=14;break;case 11:a.prev=11,a.t0=a.catch(1),d.e(a.t0);case 14:return a.prev=14,d.f(),a.finish(14);case 17:try{y=m.readQuery(e)}catch(o){y=null}O=(null===(l=y)||void 0===l?void 0:l.espressoDatetimes)||p.DEFAULT_DATETIME_LIST_DATA,j=Object(f.findEntityByGuid)(O.nodes),E=Object(r.a)({},O),_=Object(i.a)(c);try{for(_.s();!(k=_.n()).done;)D=k.value,g=j(D),u({cache:m,datetimes:E,datetime:g,deletePermanently:s}),E.nodes=Object(f.entitiesWithGuIdNotInArray)(E.nodes,[D])}catch(w){_.e(w)}finally{_.f()}I=Object(h.a)(c,t,s),x={nodes:I,__typename:"EspressoRootQueryDatetimesConnection"},n(Object(r.a)(Object(r.a)({},e),{},{data:{espressoDatetimes:x}}));case 26:case"end":return a.stop()}}),a,null,[[1,11,14,17]])})))}),[t,m,T,u,e,n]);return Object(c.useCallback)(function(){var t=Object(a.a)(o.a.mark((function t(e,n){return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,E({entityIds:e,deletePermanently:n,updateEntityList:g(e,n)});case 2:return t.abrupt("return",t.sent);case 3:case"end":return t.stop()}}),t)})));return function(e,n){return t.apply(this,arguments)}}(),[E,g])}},function(t,e,n){"use strict";var r=n(2),i=n(43),a=n(9),u=n(34),o=n.n(u),c=n(0),s=n(36),f=n(582),l=n(771),d=n(230),p=n(264),v=n(449);e.a=function(t){var e=Object(c.useState)([]),n=Object(a.a)(e,2),u=n[0],b=n[1],h=Object(l.a)(),y=Object(c.useMemo)((function(){return t.map(h)}),[t,h]),O=Object(f.a)({entityType:"DATETIME",filteredEntities:y}),j=O.allReorderedEntities,m=O.updateSortOrder,E=O.sortEntities,T=Object(d.a)(),g=Object(p.a)(),_=Object(v.a)(),k=Object(c.useCallback)(Object(i.a)(o.a.mark((function t(){var e;return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return e={nodes:u,__typename:"EspressoRootQueryDatetimesConnection"},t.next=3,m();case 3:_(Object(r.a)(Object(r.a)({},g),{},{data:{espressoDatetimes:e}}));case 4:case"end":return t.stop()}}),t)}))),[u,m,g,_]),D=Object(c.useCallback)((function(t){var e=t.destination,n=t.source,r=!e,i=(null===n||void 0===n?void 0:n.index)===(null===e||void 0===e?void 0:e.index)&&(null===e||void 0===e?void 0:e.droppableId)===(null===n||void 0===n?void 0:n.droppableId),a=(null===e||void 0===e?void 0:e.droppableId)!==s.datetimesDroppableId;if(!(r||i||a)){var u=E({allEntities:T,newIndex:e.index,oldIndex:n.index});b(u)}}),[T,E]);return Object(c.useMemo)((function(){return{allReorderedEntities:j,sortResponder:D,updateEntityList:k}}),[j,D,k])}},function(t,e){},function(t,e){},function(t,e,n){"use strict";var r=n(2),i=n(43),a=n(9),u=n(34),o=n.n(u),c=n(0),s=n(36),f=n(582),l=n(772),d=n(179),p=n(265),v=n(450);e.a=function(t){var e=Object(c.useState)([]),n=Object(a.a)(e,2),u=n[0],b=n[1],h=Object(l.a)(),y=Object(c.useMemo)((function(){return t.map(h)}),[t,h]),O=Object(f.a)({entityType:"TICKET",filteredEntities:y}),j=O.allReorderedEntities,m=O.updateSortOrder,E=O.sortEntities,T=Object(d.a)(),g=Object(p.a)(),_=Object(v.a)(),k=Object(c.useCallback)(Object(i.a)(o.a.mark((function t(){var e;return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return e={nodes:u,__typename:"EspressoRootQueryTicketsConnection"},t.next=3,m();case 3:_(Object(r.a)(Object(r.a)({},g),{},{data:{espressoTickets:e}}));case 4:case"end":return t.stop()}}),t)}))),[u,m,g,_]),D=Object(c.useCallback)((function(t){var e=t.destination,n=t.source,r=!e,i=(null===n||void 0===n?void 0:n.index)===(null===e||void 0===e?void 0:e.index)&&(null===e||void 0===e?void 0:e.droppableId)===(null===n||void 0===n?void 0:n.droppableId),a=(null===e||void 0===e?void 0:e.droppableId)!==s.ticketDroppableId;if(!(r||i||a)){var u=E({allEntities:T,newIndex:e.index,oldIndex:n.index});b(u)}}),[T,E]);return Object(c.useMemo)((function(){return{allReorderedEntities:j,sortResponder:D,updateEntityList:k}}),[j,D,k])}},function(t,e,n){"use strict";n.d(e,"a",(function(){return v}));var r=n(43),i=n(34),a=n.n(i),u=n(0),o=n(17),c=n(12),s=n(175),f=n(3),l=n(179),d=n(773),p=n(494),v=function(){var t=Object(l.a)(),e=Object(d.a)(),n=Object(p.a)().updateEntities,i=Object(s.useSystemNotifications)(),v=Object(u.useCallback)((function(n){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],i=(null===r||void 0===r?void 0:r.length)?Object(c.entitiesWithGuIdInArray)(t,r):e({entity:"datetimes",entityId:n.id}),a=Object(o.parseInfinity)(n.capacity,1/0),u=Object(c.ticketQuantityFromCapacity)(a),s=i.map((function(t){var e=t.id,n=t.quantity,r=Object(o.parseInfinity)(n,1/0);return Object(o.isInfinite)(a)||a>=r?null:{id:e,quantity:u(n)}})).filter(Boolean);return s}),[e,t]),b=Object(u.useCallback)(function(){var t=Object(r.a)(a.a.mark((function t(e){var r,u,o=arguments;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(r=!(o.length>1&&void 0!==o[1])||o[1],!e.length){t.next=6;break}return u=Object(c.uniqTicketsByMinQty)(e),t.next=5,n({uniqueInputs:u});case 5:r&&i.info({message:Object(f.__)("Ticket quantity has been adjusted because it cannot be more than the related event date capacity.")});case 6:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),[n,i]);return Object(u.useMemo)((function(){return{createBulkQtyUpdateInput:v,doQtyBulkUpdate:b}}),[v,b])}},function(t,e){},function(t,e,n){"use strict";var r=n(43),i=n(2),a=n(34),u=n.n(a),o=n(0),c=n(425),s=n(366),f=n(775),l=n(368),d=n(254),p=n(216);e.a=function(){var t=Object(c.a)(),e=Object(s.a)(),n=Object(f.a)(),a=Object(l.a)({entityType:"PRICE",typeName:d.a.Price}),v=Object(o.useCallback)((function(r){return function(){var a={nodes:Object(p.a)(r,t,!0),__typename:"EspressoRootQueryPricesConnection"};n(Object(i.a)(Object(i.a)({},e),{},{data:{espressoPrices:a}}))}}),[t,e,n]);return Object(o.useCallback)(function(){var t=Object(r.a)(u.a.mark((function t(e){return u.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,a({entityIds:e,updateEntityList:v(e)});case 2:return t.abrupt("return",t.sent);case 3:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),[a,v])}},function(t,e){},function(t,e,n){"use strict";var r;n.d(e,"a",(function(){return r})),n.d(e,"c",(function(){return a})),n.d(e,"b",(function(){return i})),function(t){t.soldOut="DTS",t.active="DTA",t.upcoming="DTU",t.postponed="DTP",t.cancelled="DTC",t.expired="DTE",t.inactive="DTI"}(r||(r={}));var i,a=function(t){return"EspressoDatetime"===t.__typename};!function(t){t.BASE_PRICE="BASE_PRICE",t.DISCOUNT="DISCOUNT",t.SURCHARGE="SURCHARGE",t.TAX="TAX"}(i||(i={}))},function(t,e,n){"use strict";n.r(e);var r=n(777);n.d(e,"useDatesListFilterState",(function(){return r.a}));var i=n(998);n.d(e,"useFilteredDateIds",(function(){return i.a}));var a=n(802);n.d(e,"useDatesListFilterStateManager",(function(){return a.a}));var u=n(999);for(var o in u)["default","useDatesListFilterState","useFilteredDateIds","useDatesListFilterStateManager"].indexOf(o)<0&&function(t){n.d(e,t,(function(){return u[t]}))}(o)},function(t,e,n){"use strict";var r=n(0),i=n(63),a=n.n(i),u=n(429);e.a=function(){var t=Object(r.useContext)(u.b);return a()(t,"useFilteredDateIds must be used inside component"),t}},function(t,e){},function(t,e,n){"use strict";n.r(e);var r=n(779);n.d(e,"useTicketsListFilterState",(function(){return r.a}));var i=n(1001);n.d(e,"useFilteredTicketIds",(function(){return i.a}));var a=n(1401);n.d(e,"useRegisterIsChainedFilter",(function(){return a.a}));var u=n(803);n.d(e,"useTicketsListFilterStateManager",(function(){return u.a}));var o=n(1002);for(var c in o)["default","useTicketsListFilterState","useFilteredTicketIds","useRegisterIsChainedFilter","useTicketsListFilterStateManager"].indexOf(c)<0&&function(t){n.d(e,t,(function(){return o[t]}))}(c)},function(t,e,n){"use strict";var r=n(0),i=n(63),a=n.n(i),u=n(431);e.a=function(){var t=Object(r.useContext)(u.b);return a()(t,"useFilteredTicketIds must be used inside component"),t}},function(t,e){},function(t,e,n){"use strict";n.r(e);var r=n(1004);for(var i in r)["default"].indexOf(i)<0&&function(t){n.d(e,t,(function(){return r[t]}))}(i)},function(t,e){},function(t,e,n){"use strict";var r,i;n.d(e,"a",(function(){return r})),n.d(e,"b",(function(){return i})),function(t){t.DEFAULT_TICKETS="defaultTickets",t.EDIT_DATE="editDate",t.EDIT_TICKET="editTicket",t.NEW_DATE="newDate",t.TAM="tam",t.TPC="tpc"}(r||(r={})),function(t){t.APPROVED="RAP",t.PENDING="RPP",t.WAITLIST="RWL",t.INCOMPLETE="RIC",t.NOT_APPROVED="RNA",t.DECLINED="RDC",t.CANCELLED="RCN"}(i||(i={}))},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(t,e,n){"use strict";var r=n(2),i=n(8),a=n(0),u=n(18),o=n(254),c=n(231),s=n(17),f=function(){return Object(a.useCallback)((function(t,e){return{input:Object(r.a)({clientMutationId:"".concat(t,"_PRICE")},e)}}),[])},l=n(31),d=n(4),p=n(12),v=n(366),b=function(){var t=Object(v.a)();return Object(a.useCallback)((function(e){var n,i=e.cache,a=e.prices,u=e.price,o=e.action,c=a.nodes,s=void 0===c?[]:c,f=[];switch(o){case"add":f=[].concat(Object(l.a)(s),[u]);break;case"update":(n=Object(d.findIndex)(Object(p.entityHasGuid)(u.id),s))>=0&&(f=Object(d.update)(n,u,s));break;case"remove":f=s.filter((function(t){return t.id!==u.id}));break;default:f=s}var v=Object(r.a)(Object(r.a)({},t),{},{data:{espressoPrices:Object(r.a)(Object(r.a)({},a),{},{nodes:f})}});i.writeQuery(v)}),[t])},h=n(24),y=function(){var t=Object(h.useRelations)().updateRelations,e=b();return Object(a.useCallback)((function(n){var r=n.cache,i=n.price,a=n.prices,u=n.priceTypeId,o=i.id;o&&u&&t({entity:"prices",entityId:o,relation:"priceTypes",relationIds:[u]}),e({cache:r,prices:a,price:i,action:"add"})}),[e,t])},O=function(){var t=Object(h.useRelations)(),e=t.dropRelations,n=t.removeRelation,i=b();return Object(a.useCallback)((function(t){var a=t.cache,u=t.prices,o=t.price,c=t.deletePermanently,s=o.id,f=c?"remove":"update";s&&c&&(n({entity:"prices",entityId:s,relation:"tickets"}),e({entity:"prices",entityId:s})),i({cache:a,prices:u,price:Object(r.a)(Object(r.a)({},o),{},{isTrashed:!0}),action:f})}),[e,n,i])},j=function(){var t=Object(h.useRelations)().updateRelations;return Object(a.useCallback)((function(e){var n=e.price,r=e.priceTypeId,i=n.id;i&&r&&t({entity:"prices",entityId:i,relation:"priceTypes",relationIds:[r]})}),[t])},m=n(79),E=["amount","order","overrides","wpUser"],T=["isDefault","isTrashed"],g=function(){var t=Object(v.a)(),e=y(),n=j(),r=O(),i=f(),o=Object(a.useCallback)((function(i){var a,o,c=i.cache,s=i.entity,f=i.input,l=i.mutationType,d=null===f||void 0===f?void 0:f.priceType;try{o=c.readQuery(t)}catch(v){o=null}var p=(null===(a=o)||void 0===a?void 0:a.espressoPrices)||m.DEFAULT_PRICE_LIST_DATA;switch(l){case u.MutationType.Create:e({cache:c,prices:p,price:s,priceTypeId:d});break;case u.MutationType.Update:n({price:s,priceTypeId:d});break;case u.MutationType.Delete:r({cache:c,prices:p,price:s,deletePermanently:null===f||void 0===f?void 0:f.deletePermanently})}}),[e,r,n,t]);return Object(a.useCallback)((function(t,e){var n=Object(s.removeNullAndUndefined)(e),r=Object(s.normalizeNumericFields)(E,n);return r=Object(s.normalizeBooleanFields)(T,r),{variables:i(t,r),onUpdate:o}}),[i,o])},_=n(276),k=n(75);e.a=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",e=Object(u.useMutationWithFeedback)({typeName:k.a.PRICE,mutationType:u.MutationType.Create,mutation:c.CREATE_PRICE}),n=Object(u.useMutationWithFeedback)({typeName:k.a.PRICE,mutationType:u.MutationType.Update,mutation:c.UPDATE_PRICE}),s=Object(u.useMutationWithFeedback)({typeName:k.a.PRICE,mutationType:u.MutationType.Delete,mutation:c.DELETE_PRICE}),f=g(),l=Object(_.a)(o.a.Price),d=Object(a.useCallback)((function(t){var n=f(u.MutationType.Create,t),a=n.onUpdate,o=Object(i.a)(n,["onUpdate"]),c=l({onUpdate:a,mutationType:u.MutationType.Create,input:t});return e(Object(r.a)(Object(r.a)({},o),{},{update:c}))}),[e,l,f]),p=Object(a.useCallback)((function(e){var a=f(u.MutationType.Update,Object(r.a)({id:t},e)),o=a.onUpdate,c=Object(i.a)(a,["onUpdate"]),s=l({onUpdate:o,mutationType:u.MutationType.Update,input:e});return n(Object(r.a)(Object(r.a)({},c),{},{update:s}))}),[l,t,f,n]),v=Object(a.useCallback)((function(e){var n=f(u.MutationType.Delete,Object(r.a)({id:t},e)),a=n.onUpdate,o=Object(i.a)(n,["onUpdate"]),c=l({onUpdate:a,mutationType:u.MutationType.Delete,input:e});return s(Object(r.a)(Object(r.a)({},o),{},{update:c}))}),[s,l,t,f]);return Object(a.useMemo)((function(){return{createEntity:d,updateEntity:p,deleteEntity:v}}),[d,v,p])}},,,,,,,function(t,e,n){"use strict";var r=n(2),i=n(8),a=n(0),u=n(18),o=n(192),c=n(17),s=n(275),f=function(){var t=Object(s.a)();return Object(a.useCallback)((function(e,n){var i=Object(r.a)({clientMutationId:"".concat(e,"_DATETIME")},n);return"CREATE"===e&&(i.eventId=t),{input:i}}),[t])},l=n(577),d=n(576),p=n(24),v=n(12),b=function(){var t=Object(p.useRelations)(),e=t.updateRelations,n=t.addRelation,r=Object(d.a)();return Object(a.useCallback)((function(t){var i=t.cache,a=t.datetimes,u=t.datetime,o=t.tickets;if(!Object(v.hasTempId)(u)){var c=a.nodes,s=void 0===c?[]:c,f=Object(v.getGuids)(s).sort(),d=u.id;Object(l.a)({cache:i,datetimeIn:f,datetimeId:d,action:"add"}),(null===o||void 0===o?void 0:o.length)&&(e({entity:"datetimes",entityId:d,relation:"tickets",relationIds:o}),o.forEach((function(t){n({entity:"tickets",entityId:t,relation:"datetimes",relationId:d})})))}r({cache:i,datetimes:a,datetime:u,action:"add"})}),[n,r,e])},h=n(579),y=n(578),O=n(14),j=n(36),m=n(771),E={__typename:"EspressoDatetime",id:"",dbId:0,cacheId:"",capacity:-1,description:"",endDate:j.PLUS_TWO_MONTHS.toISOString(),isActive:!1,isExpired:!1,isPrimary:!1,isSoldOut:!1,isTrashed:!1,isUpcoming:!1,length:0,name:"",order:0,reserved:0,sold:0,startDate:j.PLUS_ONE_MONTH.toISOString(),status:null,venue:""},T=function(){var t=Object(m.a)();return Object(a.useCallback)((function(e,n){var i={__typename:"EspressoDatetime"},a=t(n.id),o="temp:".concat(Object(c.uuid)());switch(e){case u.MutationType.Create:i=Object(r.a)(Object(r.a)(Object(r.a)({},i),E),{},{cacheId:o,id:o},n);break;case u.MutationType.Delete:i=Object(r.a)(Object(r.a)(Object(r.a)(Object(r.a)(Object(r.a)({},i),E),a),n),{},{isTrashed:!0,cacheId:o});break;case u.MutationType.Update:i=Object(r.a)(Object(r.a)(Object(r.a)(Object(r.a)({},i),a),n),{},{cacheId:o})}var s=e.toLowerCase(),f=Object(c.ucFirst)(s),l="".concat(s,"EspressoDatetime");return Object(O.a)({__typename:"RootMutation"},l,{__typename:"".concat(f,"EspressoDatetimePayload"),espressoDatetime:i})}),[t])},g=n(79),_=n(264),k=["capacity","eventId","order","reserved","sold"],D=function(){var t=Object(_.a)(),e=b(),n=Object(y.a)(),r=Object(h.a)(),i=f(),o=T(),s=Object(a.useCallback)((function(i){var a,o,c=i.cache,s=i.entity,f=i.input,l=i.mutationType;try{o=c.readQuery(t)}catch(v){o=null}var d=(null===(a=o)||void 0===a?void 0:a.espressoDatetimes)||g.DEFAULT_DATETIME_LIST_DATA,p=null===f||void 0===f?void 0:f.tickets;switch(l){case u.MutationType.Create:e({cache:c,datetimes:d,datetime:s,tickets:p});break;case u.MutationType.Update:n({datetime:s,tickets:p});break;case u.MutationType.Delete:r({cache:c,datetimes:d,datetime:s,deletePermanently:null===f||void 0===f?void 0:f.deletePermanently})}}),[e,r,n,t]);return Object(a.useCallback)((function(t,e){var n=Object(c.removeNullAndUndefined)(e),r=Object(c.normalizeNumericFields)(k,n);return{variables:i(t,r),optimisticResponse:o(t,r),onUpdate:s}}),[i,o,s])},I=n(276),x=n(254),w=n(75);e.a=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",e=Object(u.useMutationWithFeedback)({typeName:w.a.DATETIME,mutationType:u.MutationType.Create,mutation:o.CREATE_DATETIME}),n=Object(u.useMutationWithFeedback)({typeName:w.a.DATETIME,mutationType:u.MutationType.Update,mutation:o.UPDATE_DATETIME}),c=Object(u.useMutationWithFeedback)({typeName:w.a.DATETIME,mutationType:u.MutationType.Delete,mutation:o.DELETE_DATETIME}),s=D(),f=Object(I.a)(x.a.Datetime),l=Object(a.useCallback)((function(t){var n=s(u.MutationType.Create,t),a=n.onUpdate,o=Object(i.a)(n,["onUpdate"]),c=f({onUpdate:a,mutationType:u.MutationType.Create,input:t});return e(Object(r.a)(Object(r.a)({},o),{},{update:c}))}),[e,f,s]),d=Object(a.useCallback)((function(e){var a=s(u.MutationType.Update,Object(r.a)({id:t},e)),o=a.onUpdate,c=Object(i.a)(a,["onUpdate"]),l=f({onUpdate:o,mutationType:u.MutationType.Update,input:e});return n(Object(r.a)(Object(r.a)({},c),{},{update:l}))}),[f,t,s,n]),p=Object(a.useCallback)((function(e){var n=s(u.MutationType.Delete,Object(r.a)({id:t},e)),a=n.onUpdate,o=Object(i.a)(n,["onUpdate"]),l=f({onUpdate:a,mutationType:u.MutationType.Delete,input:e});return c(Object(r.a)(Object(r.a)({},o),{},{update:l}))}),[c,f,t,s]);return Object(a.useMemo)((function(){return{createEntity:l,updateEntity:d,deleteEntity:p}}),[l,p,d])}},function(t,e,n){"use strict";var r=n(2),i=n(8),a=n(0),u=n(18),o=n(177),c=n(12),s=n(17),f=function(){return Object(a.useCallback)((function(t,e){return{input:Object(r.a)({clientMutationId:"".concat(t,"_TICKET")},e)}}),[])},l=n(24),d=n(581),p=n(367),v=function(){var t=Object(l.useRelations)(),e=t.addRelation,n=t.updateRelations,r=Object(p.a)();return Object(a.useCallback)((function(t){var i=t.cache,a=t.datetimeIds,u=t.ticket,o=t.tickets,s=t.prices;if(!Object(c.hasTempId)(u)){var f=o.nodes,l=void 0===f?[]:f,p=Object(c.getGuids)(l),v=u.id;Object(d.a)({cache:i,prices:s,ticketIn:p,ticketId:v,action:"add"}),(null===a||void 0===a?void 0:a.length)&&(n({entity:"tickets",entityId:v,relation:"datetimes",relationIds:a}),a.forEach((function(t){e({entity:"datetimes",entityId:t,relation:"tickets",relationId:v})})));var b=Object(c.getGuids)((null===s||void 0===s?void 0:s.nodes)||[]);b.length&&(n({entity:"tickets",entityId:v,relation:"prices",relationIds:b}),b.forEach((function(t){e({entity:"prices",entityId:t,relation:"tickets",relationId:v})})))}r({cache:i,tickets:o,ticket:u,action:"add"})}),[e,n,r])},b=n(580),h=n(583),y=n(14),O=n(36),j=n(772),m={id:"",dbId:0,cacheId:"",description:"",endDate:O.PLUS_TWO_MONTHS.toISOString(),isSoldOut:!1,isTrashed:!1,isDefault:!1,isExpired:!1,isFree:!1,isOnSale:!1,isPending:!0,isRequired:!1,max:-1,min:0,name:"",order:0,price:null,prices:null,quantity:-1,registrationCount:0,reserved:0,reverseCalculate:!0,sold:0,startDate:O.PLUS_ONE_MONTH.toISOString(),userId:"",uses:-1,visibility:"PUBLIC"},E=function(){var t=Object(j.a)();return Object(a.useCallback)((function(e,n){var i={__typename:"EspressoTicket"},a=t(n.id),o="temp:".concat(Object(s.uuid)());switch(e){case u.MutationType.Create:i=Object(r.a)(Object(r.a)(Object(r.a)(Object(r.a)({},i),m),{},{cacheId:o,id:o},n),{},{prices:null});break;case u.MutationType.Delete:i=Object(r.a)(Object(r.a)(Object(r.a)(Object(r.a)(Object(r.a)({},i),m),a),n),{},{isTrashed:!0,cacheId:o});break;case u.MutationType.Update:i=Object(r.a)(Object(r.a)(Object(r.a)(Object(r.a)({},i),a),n),{},{cacheId:o,prices:null})}var c=e.toLowerCase(),f=Object(s.ucFirst)(c),l="".concat(c,"EspressoTicket");return Object(y.a)({__typename:"RootMutation"},l,{__typename:"".concat(f,"EspressoTicketPayload"),espressoTicket:i})}),[t])},T=n(493),g=n(265),_=n(79),k=["max","min","order","price","quantity","reserved","row","sold","uses","wpUser"],D=["isDefault","isRequired","isTrashed","reverseCalculate"],I=n(584),x=function(){var t=Object(g.a)(),e=v(),n=Object(h.a)(),r=Object(b.a)(),o=Object(I.a)(),l=f(),d=E(),p=Object(a.useCallback)((function(a){var o,s,f=a.cache,l=a.entity,d=a.input,p=a.mutationType,v=l.prices,b=Object(i.a)(l,["prices"]);try{s=f.readQuery(t)}catch(j){s=null}var h=(null===(o=s)||void 0===o?void 0:o.espressoTickets)||_.DEFAULT_TICKET_LIST_DATA,y=null===d||void 0===d?void 0:d.datetimes,O=(null===v||void 0===v?void 0:v.nodes)?Object(c.getGuids)(v.nodes):null;switch(p){case u.MutationType.Create:e({cache:f,tickets:h,ticket:b,datetimeIds:y,prices:v});break;case u.MutationType.Update:n({cache:f,tickets:h,ticket:b,datetimeIds:y,priceIds:O});break;case u.MutationType.Delete:r({cache:f,tickets:h,ticket:b,deletePermanently:null===d||void 0===d?void 0:d.deletePermanently})}T.a.doAction("eventEditor.ticket.mutation",p,d,l,f)}),[e,r,n,t]);return Object(a.useCallback)((function(t,e){var n=Object(s.removeNullAndUndefined)(e),r=Object(s.normalizeNumericFields)(k,n);r=Object(s.normalizeBooleanFields)(D,r);var i=l(t,r);if(e.isDefault)return{variables:i,onUpdate:p};var a=o({input:e,mutationType:t});return{variables:i,optimisticResponse:d(t,r),onUpdate:p,refetchQueries:a}}),[o,l,d,p])},w=n(276),C=n(254),A=n(75);e.a=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",e=Object(u.useMutationWithFeedback)({typeName:A.a.TICKET,mutationType:u.MutationType.Create,mutation:o.CREATE_TICKET}),n=Object(u.useMutationWithFeedback)({typeName:A.a.TICKET,mutationType:u.MutationType.Update,mutation:o.UPDATE_TICKET}),c=Object(u.useMutationWithFeedback)({typeName:A.a.TICKET,mutationType:u.MutationType.Delete,mutation:o.DELETE_TICKET}),s=x(),f=Object(w.a)(C.a.Ticket),l=Object(a.useCallback)((function(t){var n=s(u.MutationType.Create,t),a=n.onUpdate,o=Object(i.a)(n,["onUpdate"]),c=f({onUpdate:a,mutationType:u.MutationType.Create,input:t});return e(Object(r.a)(Object(r.a)({},o),{},{update:c}))}),[e,f,s]),d=Object(a.useCallback)((function(e){var a=s(u.MutationType.Update,Object(r.a)({id:t},e)),o=a.onUpdate,c=Object(i.a)(a,["onUpdate"]),l=f({onUpdate:o,mutationType:u.MutationType.Update,input:e});return n(Object(r.a)(Object(r.a)({},c),{},{update:l}))}),[f,t,s,n]),p=Object(a.useCallback)((function(e){var n=s(u.MutationType.Delete,Object(r.a)({id:t},e)),a=n.onUpdate,o=Object(i.a)(n,["onUpdate"]),l=f({onUpdate:a,mutationType:u.MutationType.Delete,input:e});return c(Object(r.a)(Object(r.a)({},o),{},{update:l}))}),[c,f,t,s]);return Object(a.useMemo)((function(){return{createEntity:l,updateEntity:d,deleteEntity:p}}),[l,p,d])}},,,,,,,,,,,,,function(t,e,n){"use strict";n.d(e,"e",(function(){return u})),n.d(e,"d",(function(){return o})),n.d(e,"a",(function(){return c})),n.d(e,"b",(function(){return f})),n.d(e,"c",(function(){return l}));var r=n(222),i=n(50),a=n(3),u=function(t){var e={};return t.subscribe((function(n){var r=n.values;t.batch((function(){var n,u,o,c=r.endDate,s=r.startDate,f=e.startDate,l=e.endDate,d=s!==f,p=c!==l,v=!(null===(n=t.getFieldState("endDate"))||void 0===n?void 0:n.pristine),b=null===(u=t.getFieldState("endDate"))||void 0===u||null===(o=u.data)||void 0===o?void 0:o.changedFromStartDate;if(d){var h,y=Object(i.mayBeAdjustEndDate)({newEndDate:c,newStartDate:s,prevEndDate:l,prevStartDate:f});y!==c&&(t.change("endDate",y),t.mutators.setFieldData("endDate",{changedFromStartDate:!0}),h=Object(a.__)("End date has been adjusted")),t.mutators.setFieldData("endDate",{fieldNotice:h})}p&&(v&&!b&&t.mutators.setFieldData("endDate",{fieldNotice:null}),t.mutators.setFieldData("endDate",{changedFromStartDate:!1}))})),e=r}),{values:!0})},o=function(){return Object(a.__)("Required")},c={startDate:r.a().required((function(){return Object(a.__)("Start Date is required")})).typeError(o),endDate:r.a().required((function(){return Object(a.__)("End Date is required")})).typeError(o).when(["startDate"],(function(t,e){return e.min(t,(function(){return i.endDateAfterStartDateErrorMessage}))}))},s=n(341),f=function(t){return function(e){return(t!==s.a.start||"end"!==e.key)&&(t!==s.a.end||"start"!==e.key)}},l=function(t){var e;return null===(e=window.eventEspressoData.eventEditor)||void 0===e?void 0:e[t]}},,,,,,,,,,,,,,,,,,,,,,,,,,,function(t,e,n){"use strict";n.d(e,"a",(function(){return E}));var r=n(2),i=n(9),a=n(0),u=n(24),o=n(18),c=function(){return Object(a.useMemo)((function(){var t,e,n,r,i=(null===(t=window)||void 0===t||null===(e=t.eventEspressoData)||void 0===e?void 0:e.config)||{},a=i.currentUser,u=i.generalSettings;return{currentUser:a,eventEditor:(null===(n=window)||void 0===n||null===(r=n.eventEspressoData)||void 0===r?void 0:r.eventEditor)||{},generalSettings:u}}),[])},s=n(984),f=n(449),l=n(450),d=n(775),p=n(985),v=n(79),b=n(426),h=n(264),y=n(265),O=n(366),j=n(427),m=n(554),E=function(){var t=Object(u.useStatus)().setIsLoaded,e=Object(u.useRelations)(),n=e.initialize,E=e.isInitialized,T=c(),g=T.currentUser,_=T.eventEditor,k=T.generalSettings,D=Object(o.useIsRehydrated)(),I=Object(i.a)(D,2),x=I[0],w=I[1],C=_.event,A=_.datetimes,S=void 0===A?v.DEFAULT_DATETIME_LIST_DATA:A,F=_.tickets,P=void 0===F?v.DEFAULT_TICKET_LIST_DATA:F,R=_.prices,U=void 0===R?v.DEFAULT_PRICE_LIST_DATA:R,M=_.priceTypes,L=void 0===M?v.DEFAULT_PRICE_TYPE_LIST_DATA:M,N=_.venues,$=void 0===N?v.DEFAULT_VENUE_LIST_DATA:N,q=_.relations,G=Object(b.a)(),z=Object(s.a)(),B=Object(h.a)(),V=Object(f.a)(),K=Object(y.a)(),Q=Object(l.a)(),W=Object(O.a)(),Y=Object(d.a)(),H=Object(j.a)(),Z=Object(p.a)(),J=Object(o.useCurrentUserQueryOptions)(),X=Object(o.useUpdateCurrentUserCache)(),tt=Object(o.useGeneralSettingsQueryOptions)(),et=Object(o.useUpdateGeneralSettingsCache)(),nt=Object(m.a)(),rt=Object(o.useUpdateCache)();return Object(a.useEffect)((function(){E()||n(q)}),[q]),Object(a.useEffect)((function(){x||(rt(Object(r.a)(Object(r.a)({},nt),{},{data:{espressoEvent:C}})),z(Object(r.a)(Object(r.a)({},G),{},{data:{espressoPriceTypes:L}})),t(u.TypeName.priceTypes,!0),V(Object(r.a)(Object(r.a)({},B),{},{data:{espressoDatetimes:S}})),t(u.TypeName.datetimes,!0),Q(Object(r.a)(Object(r.a)({},K),{},{data:{espressoTickets:P}})),t(u.TypeName.tickets,!0),Y(Object(r.a)(Object(r.a)({},W),{},{data:{espressoPrices:U}})),t(u.TypeName.prices,!0),Z(Object(r.a)(Object(r.a)({},H),{},{data:{espressoVenues:$}})),X(Object(r.a)(Object(r.a)({},J),{},{data:{viewer:g}})),et(Object(r.a)(Object(r.a)({},tt),{},{data:{generalSettings:k}})),w(!0))}),[]),x}},,,,,,,,function(t,e,n){"use strict";var r=n(2),i=n(0),a=n(18),u=n(340),o=n(14),c=n(17),s=n(980),f=(Object(c.uuid)(),function(){var t=Object(s.a)();return Object(i.useCallback)((function(e,n){var i={__typename:"EspressoEvent"},u=Object(c.removeNullAndUndefined)(n);switch(e){case a.MutationType.Update:i=Object(r.a)(Object(r.a)(Object(r.a)(Object(r.a)({},i),t),u),{},{cacheId:Object(c.uuid)()}),(null===n||void 0===n?void 0:n.manager)&&(i.manager=Object(r.a)(Object(r.a)({},null===t||void 0===t?void 0:t.manager),{},{id:null===n||void 0===n?void 0:n.manager}))}var s=e.toLowerCase(),f=Object(c.ucFirst)(s),l="".concat(s,"EspressoEvent");return Object(o.a)({__typename:"RootMutation"},l,{__typename:"".concat(f,"EspressoEventPayload"),espressoEvent:i})}),[t])}),l=function(){var t=f(),e=Object(i.useCallback)((function(t,e){return{input:Object(r.a)({clientMutationId:"".concat(t,"_EVENT")},e)}}),[]);return Object(i.useCallback)((function(n,r){return{variables:e(n,r),optimisticResponse:t(n,r)}}),[e,t])},d=n(75);e.a=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",e=Object(a.useMutationWithFeedback)({typeName:d.a.EVENT,mutationType:a.MutationType.Update,mutation:u.UPDATE_EVENT}),n=l(),o=Object(i.useCallback)((function(i){var u=n(a.MutationType.Update,Object(r.a)({id:t},i));return e(u)}),[t,n,e]);return Object(i.useMemo)((function(){return{updateEntity:o}}),[o])}},,function(t,e,n){"use strict";n.d(e,"a",(function(){return u})),n.d(e,"b",(function(){return a}));var r=n(227),i=Object(r.createSlotFill)("NewDateOptions"),a=i.Slot,u=i.Fill},,,,,,,,,,,,,,,,,,,,,,,,,function(t,e,n){"use strict";n.d(e,"a",(function(){return u}));var r=n(18),i=n(24),a=Object(r.makeVar)({}),u=function(){return Object(i.useEntityMeta)(a)}},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(t,e,n){"use strict";n.d(e,"a",(function(){return i}));var r=n(26),i=function(){var t,e;return Object(r.useMemoStringify)((null===(t=window.eventEspressoData)||void 0===t||null===(e=t.eventEditor)||void 0===e?void 0:e.eventManagers)||[])}},function(t,e,n){"use strict";var r=n(9),i=n(0),a=n(45),u=n(75),o=n(4),c=n(24),s=n(12),f=n(778),l=function(){var t=Object(c.useRelations)().getData,e=Object(f.a)(),n=Object(r.a)(e,1)[0],a=Object(i.useMemo)((function(){return Object(o.keys)(Object(o.pickBy)((function(t){return Object(o.hasPath)(["datetimes"],t)&&Object(o.pathOr)([],["datetimes"],t).some((function(t){return n.includes(t)}))}),t().tickets))}),[t,n]),u=Object(i.useCallback)((function(t){var e=t.isChained,n=t.tickets;return e?Object(s.entitiesWithGuIdInArray)(n,a):n}),[a]);return Object(i.useMemo)((function(){return[u,a]}),[u,a])},d=new a.FilterBarService(u.d,u.e).registerFilter;e.a=function(){var t=l(),e=Object(r.a)(t,2),n=e[0],a=e[1],u=Object(i.useRef)();Object(i.useEffect)((function(){var t;null===(t=u.current)||void 0===t||t.call(u);var e=d((function(t){var e=t.entityList,r=t.filterState;return n({isChained:r.isChained,tickets:e})}),9);return u.current=e,function(){var t;null===(t=u.current)||void 0===t||t.call(u)}}),[a,n])}},,,,,,,,,,,,,,,,,,,,,,,,,,,,function(t,e,n){var r=n(384),i=n(1532),a=n(1536),u=r((function(t){return null!=t&&a(t,i(t))}));t.exports=u},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(t,e,n){t.exports=n(1531)},function(t,e,n){"use strict";n.r(e);n(237);var r=n(238);for(var i in r)["default"].indexOf(i)<0&&function(t){n.d(e,t,(function(){return r[t]}))}(i);var a=n(75);n.d(e,"domain",(function(){return a.d})),n.d(e,"datesList",(function(){return a.c})),n.d(e,"ticketsList",(function(){return a.e})),n.d(e,"TICKET_FIELDS_FOR_TPC",(function(){return a.b})),n.d(e,"SINGULAR_ENTITY_NAME",(function(){return a.a}));var u=n(335);n.d(e,"withEdtrContext",(function(){return u.q})),n.d(e,"DatetimesListProvider",(function(){return u.e})),n.d(e,"DatesFilterStateContext",(function(){return u.c})),n.d(e,"DatesFilterStateProvider",(function(){return u.d})),n.d(e,"DatesFilterStateConsumer",(function(){return u.b})),n.d(e,"FilteredDatesContext",(function(){return u.g})),n.d(e,"FilteredDatesProvider",(function(){return u.h})),n.d(e,"FilteredDatesConsumer",(function(){return u.f})),n.d(e,"TicketsListProvider",(function(){return u.p})),n.d(e,"TicketsFilterStateContext",(function(){return u.n})),n.d(e,"TicketsFilterStateProvider",(function(){return u.o})),n.d(e,"TicketsFilterStateConsumer",(function(){return u.m})),n.d(e,"FilteredTicketsContext",(function(){return u.j})),n.d(e,"FilteredTicketsProvider",(function(){return u.k})),n.d(e,"FilteredTicketsConsumer",(function(){return u.i})),n.d(e,"withEntityListContext",(function(){return u.r})),n.d(e,"ServiceProvider",(function(){return u.l})),n.d(e,"ContextProvider",(function(){return u.a}));var o=n(295);for(var i in o)["default","domain","datesList","ticketsList","TICKET_FIELDS_FOR_TPC","SINGULAR_ENTITY_NAME","withEdtrContext","DatetimesListProvider","DatesFilterStateContext","DatesFilterStateProvider","DatesFilterStateConsumer","FilteredDatesContext","FilteredDatesProvider","FilteredDatesConsumer","TicketsListProvider","TicketsFilterStateContext","TicketsFilterStateProvider","TicketsFilterStateConsumer","FilteredTicketsContext","FilteredTicketsProvider","FilteredTicketsConsumer","withEntityListContext","ServiceProvider","ContextProvider"].indexOf(i)<0&&function(t){n.d(e,t,(function(){return o[t]}))}(i);var c=n(1003);for(var i in c)["default","domain","datesList","ticketsList","TICKET_FIELDS_FOR_TPC","SINGULAR_ENTITY_NAME","withEdtrContext","DatetimesListProvider","DatesFilterStateContext","DatesFilterStateProvider","DatesFilterStateConsumer","FilteredDatesContext","FilteredDatesProvider","FilteredDatesConsumer","TicketsListProvider","TicketsFilterStateContext","TicketsFilterStateProvider","TicketsFilterStateConsumer","FilteredTicketsContext","FilteredTicketsProvider","FilteredTicketsConsumer","withEntityListContext","ServiceProvider","ContextProvider"].indexOf(i)<0&&function(t){n.d(e,t,(function(){return c[t]}))}(i);var s=n(164);n.d(e,"useVisibleDatetimeIds",(function(){return s.i})),n.d(e,"useVisibleTicketIds",(function(){return s.j})),n.d(e,"useUpdateDatetimeList",(function(){return s.c})),n.d(e,"useUpdateTicketList",(function(){return s.g})),n.d(e,"useUpdatePriceList",(function(){return s.e})),n.d(e,"useUpdatePriceTypeList",(function(){return s.f})),n.d(e,"useUpdateVenueList",(function(){return s.h})),n.d(e,"useUpdateEntityList",(function(){return s.d})),n.d(e,"useEventsHandler",(function(){return s.a})),n.d(e,"useRegistrationsLink",(function(){return s.b}));var f=n(493);n.d(e,"hooks",(function(){return f.a}));var l=n(1339);n.d(e,"NewDateOption",(function(){return l.a})),n.d(e,"NewDateOptions",(function(){return l.b}));var d=n(1302);n.d(e,"startAndEndDateFixer",(function(){return d.e})),n.d(e,"requiredMessage",(function(){return d.d})),n.d(e,"datesSchema",(function(){return d.a})),n.d(e,"filterCellByStartOrEndDate",(function(){return d.b})),n.d(e,"getEdtrDomData",(function(){return d.c}));var p=n(1005);n.d(e,"EdtrGlobalModals",(function(){return p.a})),n.d(e,"QueryURLRegStatus",(function(){return p.b}))},function(t,e,n){var r=n(384),i=n(982),a=n(1533),u=n(1534),o=n(1535),c=r((function(t){return null!=t&&"function"===typeof t["fantasy-land/empty"]?t["fantasy-land/empty"]():null!=t&&null!=t.constructor&&"function"===typeof t.constructor["fantasy-land/empty"]?t.constructor["fantasy-land/empty"]():null!=t&&"function"===typeof t.empty?t.empty():null!=t&&null!=t.constructor&&"function"===typeof t.constructor.empty?t.constructor.empty():a(t)?[]:o(t)?"":u(t)?{}:i(t)?function(){return arguments}():void 0}));t.exports=c},function(t,e){t.exports=Array.isArray||function(t){return null!=t&&t.length>=0&&"[object Array]"===Object.prototype.toString.call(t)}},function(t,e){t.exports=function(t){return"[object Object]"===Object.prototype.toString.call(t)}},function(t,e){t.exports=function(t){return"[object String]"===Object.prototype.toString.call(t)}},function(t,e,n){var r=n(1537),i=n(1538),a=r((function(t,e){return i(t,e,[],[])}));t.exports=a},function(t,e,n){var r=n(384),i=n(981);t.exports=function(t){return function e(n,a){switch(arguments.length){case 0:return e;case 1:return i(n)?e:r((function(e){return t(n,e)}));default:return i(n)&&i(a)?e:i(n)?r((function(e){return t(e,a)})):i(a)?r((function(e){return t(n,e)})):t(n,a)}}}},function(t,e,n){var r=n(1539),i=n(1540),a=n(1541),u=n(632),o=n(1542),c=n(1543),s=n(1544);function f(t,e,n,a){var u=r(t),o=r(e);function c(t,e){return l(t,e,n.slice(),a.slice())}return!i((function(t,e){return!i(c,e,t)}),o,u)}function l(t,e,n,r){if(o(t,e))return!0;var i=s(t);if(i!==s(e))return!1;if(null==t||null==e)return!1;if("function"===typeof t["fantasy-land/equals"]||"function"===typeof e["fantasy-land/equals"])return"function"===typeof t["fantasy-land/equals"]&&t["fantasy-land/equals"](e)&&"function"===typeof e["fantasy-land/equals"]&&e["fantasy-land/equals"](t);if("function"===typeof t.equals||"function"===typeof e.equals)return"function"===typeof t.equals&&t.equals(e)&&"function"===typeof e.equals&&e.equals(t);switch(i){case"Arguments":case"Array":case"Object":if("function"===typeof t.constructor&&"Promise"===a(t.constructor))return t===e;break;case"Boolean":case"Number":case"String":if(typeof t!==typeof e||!o(t.valueOf(),e.valueOf()))return!1;break;case"Date":if(!o(t.valueOf(),e.valueOf()))return!1;break;case"Error":return t.name===e.name&&t.message===e.message;case"RegExp":if(t.source!==e.source||t.global!==e.global||t.ignoreCase!==e.ignoreCase||t.multiline!==e.multiline||t.sticky!==e.sticky||t.unicode!==e.unicode)return!1}for(var d=n.length-1;d>=0;){if(n[d]===t)return r[d]===e;d-=1}switch(i){case"Map":return t.size===e.size&&f(t.entries(),e.entries(),n.concat([t]),r.concat([e]));case"Set":return t.size===e.size&&f(t.values(),e.values(),n.concat([t]),r.concat([e]));case"Arguments":case"Array":case"Object":case"Boolean":case"Number":case"String":case"Date":case"Error":case"RegExp":case"Int8Array":case"Uint8Array":case"Uint8ClampedArray":case"Int16Array":case"Uint16Array":case"Int32Array":case"Uint32Array":case"Float32Array":case"Float64Array":case"ArrayBuffer":break;default:return!1}var p=c(t);if(p.length!==c(e).length)return!1;var v=n.concat([t]),b=r.concat([e]);for(d=p.length-1;d>=0;){var h=p[d];if(!u(h,e)||!l(e[h],t[h],v,b))return!1;d-=1}return!0}t.exports=l},function(t,e){t.exports=function(t){for(var e,n=[];!(e=t.next()).done;)n.push(e.value);return n}},function(t,e){t.exports=function(t,e,n){for(var r=0,i=n.length;r=0;)i(e=o[n],t)&&!s(r,e)&&(r[r.length]=e),n-=1;return r})):r((function(t){return Object(t)!==t?[]:Object.keys(t)}));t.exports=f},function(t,e,n){var r=n(384)((function(t){return null===t?"Null":void 0===t?"Undefined":Object.prototype.toString.call(t).slice(8,-1)}));t.exports=r}]); -//# sourceMappingURL=edtrServices.7f51b510.js.map \ No newline at end of file +/*! For license information please see edtrServices.67147781.js.LICENSE.txt */ +this.eventespresso=this.eventespresso||{},this.eventespresso.edtrServices=function(t){var e={};function n(r){if(e[r])return e[r].exports;var i=e[r]={i:r,l:!1,exports:{}};return t[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"===typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var i in t)n.d(r,i,function(e){return t[e]}.bind(null,i));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="/",n(n.s=1530)}([function(t,e){t.exports=window.React},function(t,e,n){"use strict";t.exports=n(77)},function(t,e,n){"use strict";n.d(e,"a",(function(){return a}));var r=n(14);function i(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function a(t){for(var e=1;e=0||(i[n]=t[n]);return i}(t,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}n.d(e,"a",(function(){return r}))},function(t,e,n){"use strict";n.d(e,"a",(function(){return u}));var r=n(54);var i=n(42),a=n(55);function u(t,e){return Object(r.a)(t)||function(t,e){if("undefined"!==typeof Symbol&&Symbol.iterator in Object(t)){var n=[],r=!0,i=!1,a=void 0;try{for(var u,o=t[Symbol.iterator]();!(r=(u=o.next()).done)&&(n.push(u.value),!e||n.length!==e);r=!0);}catch(c){i=!0,a=c}finally{try{r||null==o.return||o.return()}finally{if(i)throw a}}return n}}(t,e)||Object(i.a)(t,e)||Object(a.a)()}},,,function(t,e){t.exports=window.eventespresso.predicates},,function(t,e,n){"use strict";function r(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}n.d(e,"a",(function(){return r}))},,,function(t,e){t.exports=window.eventespresso.utils},function(t,e){t.exports=window.eventespresso.data},,,,,,function(t,e){t.exports=window.eventespresso.services},,function(t,e){t.exports=window.eventespresso.hooks},function(t,e){t.exports=window.eventespresso.adapters},,,,function(t,e,n){"use strict";n.d(e,"a",(function(){return u}));var r=n(39);var i=n(68),a=n(42);function u(t){return function(t){if(Array.isArray(t))return Object(r.a)(t)}(t)||Object(i.a)(t)||Object(a.a)(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}},,,function(t,e,n){t.exports=n(171)},,function(t,e){t.exports=window.eventespresso.constants},function(t,e,n){"use strict";function r(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}n.d(e,"a",(function(){return r}))},,function(t,e,n){"use strict";function r(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n=t.length?{done:!0}:{done:!1,value:t[i++]}},e:function(t){throw t},f:a}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var u,o=!0,c=!1;return{s:function(){n=t[Symbol.iterator]()},n:function(){var t=n.next();return o=t.done,t},e:function(t){c=!0,u=t},f:function(){try{o||null==n.return||n.return()}finally{if(c)throw u}}}}},,,,,function(t,e,n){"use strict";function r(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}n.d(e,"a",(function(){return r}))},,,,,,,,,,,,,function(t,e,n){"use strict";function r(t,e){return(r=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t})(t,e)}n.d(e,"a",(function(){return r}))},,,,,,,,,,,,,,,,,function(t,e,n){"use strict";function r(t){return(r="function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}n.d(e,"a",(function(){return r}))},function(t,e,n){"use strict";function r(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(t){return!1}}n.d(e,"a",(function(){return r}))},,,,,,function(t,e,n){var r=n(388),i="object"==typeof self&&self&&self.Object===Object&&self,a=r||i||Function("return this")();t.exports=a},,,,,,,,,,function(t,e){var n=Array.isArray;t.exports=n},,,,function(t,e,n){"use strict";function r(t){this._maxSize=t,this.clear()}r.prototype.clear=function(){this._size=0,this._values=Object.create(null)},r.prototype.get=function(t){return this._values[t]},r.prototype.set=function(t,e){return this._size>=this._maxSize&&this.clear(),t in this._values||this._size++,this._values[t]=e};var i=/[^.^\]^[]+|(?=\[\]|\.\.)/g,a=/^\d+$/,u=/^\d/,o=/[~`!#$%\^&*+=\-\[\]\\';,/{}|\\":<>\?]/g,c=/^\s*(['"]?)(.*?)(\1)\s*$/,s=new r(512),f=new r(512),l=new r(512);function d(t){return s.get(t)||s.set(t,p(t).map((function(t){return t.replace(c,"$2")})))}function p(t){return t.match(i)}function v(t){return"string"===typeof t&&t&&-1!==["'",'"'].indexOf(t.charAt(0))}function b(t){return!v(t)&&(function(t){return t.match(u)&&!t.match(a)}(t)||function(t){return o.test(t)}(t))}t.exports={Cache:r,split:p,normalizePath:d,setter:function(t){var e=d(t);return f.get(t)||f.set(t,(function(t,n){for(var r=0,i=e.length,a=t;r=0;--a){var u=this.tryEntries[a],o=u.completion;if("root"===u.tryLoc)return i("end");if(u.tryLoc<=this.prev){var c=r.call(u,"catchLoc"),s=r.call(u,"finallyLoc");if(c&&s){if(this.prev=0;--n){var i=this.tryEntries[n];if(i.tryLoc<=this.prev&&r.call(i,"finallyLoc")&&this.prev=0;--e){var n=this.tryEntries[e];if(n.finallyLoc===t)return this.complete(n.completion,n.afterLoc),I(n),b}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.tryLoc===t){var r=n.completion;if("throw"===r.type){var i=r.arg;I(n)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(t,n,r){return this.delegate={iterator:w(t),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=e),b}},t}(t.exports);try{regeneratorRuntime=r}catch(i){Function("r","regeneratorRuntime = r")(r)}},,,,function(t,e){t.exports=window.eventespresso.toaster},,function(t,e,n){"use strict";n.r(e),n.d(e,"TICKET_PRICES_ATTRIBUTE",(function(){return j})),n.d(e,"CREATE_TICKET",(function(){return m})),n.d(e,"UPDATE_TICKET",(function(){return E})),n.d(e,"DELETE_TICKET",(function(){return T})),n.d(e,"BULK_UPDATE_TICKETS",(function(){return g}));var r=n(49),i=n(18),a=n(194),u=n(291),o=n(1289);n.d(e,"useTicketMutator",(function(){return o.a}));var c=n(991);n.d(e,"useReorderTickets",(function(){return c.a}));var s=n(494);n.d(e,"useBulkEditTickets",(function(){return s.a}));var f=n(776);n.d(e,"useBulkDeleteTickets",(function(){return f.a}));var l=n(992);n.d(e,"useUpdateTicketQtyByCapacity",(function(){return l.a}));var d,p,v,b,h,y=n(993);for(var O in y)["default","TICKET_PRICES_ATTRIBUTE","CREATE_TICKET","UPDATE_TICKET","DELETE_TICKET","BULK_UPDATE_TICKETS","useTicketMutator","useReorderTickets","useBulkEditTickets","useBulkDeleteTickets","useUpdateTicketQtyByCapacity"].indexOf(O)<0&&function(t){n.d(e,t,(function(){return y[t]}))}(O);var j=Object(i.gql)(d||(d=Object(r.a)(["\n\tfragment ticketPricesAttribute on EspressoTicket {\n\t\tprices {\n\t\t\tnodes {\n\t\t\t\t...priceAttributes\n\t\t\t}\n\t\t}\n\t}\n\t","\n"])),u.c),m=Object(i.gql)(p||(p=Object(r.a)(["\n\tmutation CREATE_TICKET($input: CreateEspressoTicketInput!) {\n\t\tcreateEspressoTicket(input: $input) {\n\t\t\tespressoTicket {\n\t\t\t\t...ticketAttributes\n\t\t\t\t...ticketPricesAttribute # fetch default prices when a ticket is created.\n\t\t\t}\n\t\t}\n\t}\n\t","\n\t","\n"])),a.c,j),E=Object(i.gql)(v||(v=Object(r.a)(["\n\tmutation UPDATE_TICKET($input: UpdateEspressoTicketInput!) {\n\t\tupdateEspressoTicket(input: $input) {\n\t\t\tespressoTicket {\n\t\t\t\t...ticketAttributes\n\t\t\t\t...ticketPricesAttribute # fetch updated prices when a ticket is updated.\n\t\t\t}\n\t\t}\n\t}\n\t","\n\t","\n"])),a.c,j),T=Object(i.gql)(b||(b=Object(r.a)(["\n\tmutation DELETE_TICKET($input: DeleteEspressoTicketInput!) {\n\t\tdeleteEspressoTicket(input: $input) {\n\t\t\tespressoTicket {\n\t\t\t\t...ticketAttributes\n\t\t\t}\n\t\t}\n\t}\n\t","\n"])),a.c),g=Object(i.gql)(h||(h=Object(r.a)(["\n\tmutation BULK_UPDATE_TICKETS($input: BulkUpdateEspressoTicketInput!) {\n\t\tbulkUpdateEspressoTicket(input: $input) {\n\t\t\tupdated\n\t\t\tfailed\n\t\t}\n\t}\n"])))},,function(t,e,n){"use strict";var r=n(0),i=n(4),a=n(18),u=n(12),o=n(265);e.a=function(){var t,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:u.isNotDefault,n=Object(o.a)(),c=Object(a.useTicketsQuery)(n),s=c.data,f=(null===s||void 0===s||null===(t=s.espressoTickets)||void 0===t?void 0:t.nodes)||[],l=Object(u.getCacheIds)(f);return Object(r.useMemo)((function(){return Object(i.filter)(e,f)}),[l])}},,,,,,,,function(t,e,n){"use strict";var r=n(18);e.a=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:void 0;return Object(r.useUpdateCache)(t)}},,,,,function(t,e,n){"use strict";n.r(e),n.d(e,"CREATE_DATETIME",(function(){return y})),n.d(e,"UPDATE_DATETIME",(function(){return O})),n.d(e,"DELETE_DATETIME",(function(){return j})),n.d(e,"BULK_UPDATE_DATETIMES",(function(){return m}));var r=n(49),i=n(18),a=n(215),u=n(1288);n.d(e,"useDatetimeMutator",(function(){return u.a}));var o=n(492);n.d(e,"useDeleteRelatedTickets",(function(){return o.a}));var c=n(986);n.d(e,"useBulkEditDatetimes",(function(){return c.a}));var s=n(987);n.d(e,"useBulkDeleteDatetimes",(function(){return s.a}));var f=n(988);n.d(e,"useReorderDatetimes",(function(){return f.a}));var l,d,p,v,b=n(989);for(var h in b)["default","CREATE_DATETIME","UPDATE_DATETIME","DELETE_DATETIME","BULK_UPDATE_DATETIMES","useDatetimeMutator","useDeleteRelatedTickets","useBulkEditDatetimes","useBulkDeleteDatetimes","useReorderDatetimes"].indexOf(h)<0&&function(t){n.d(e,t,(function(){return b[t]}))}(h);var y=Object(i.gql)(l||(l=Object(r.a)(["\n\tmutation CREATE_DATETIME($input: CreateEspressoDatetimeInput!) {\n\t\tcreateEspressoDatetime(input: $input) {\n\t\t\tespressoDatetime {\n\t\t\t\t...datetimeAttributes\n\t\t\t}\n\t\t}\n\t}\n\t","\n"])),a.a),O=Object(i.gql)(d||(d=Object(r.a)(["\n\tmutation UPDATE_DATETIME($input: UpdateEspressoDatetimeInput!) {\n\t\tupdateEspressoDatetime(input: $input) {\n\t\t\tespressoDatetime {\n\t\t\t\t...datetimeAttributes\n\t\t\t}\n\t\t}\n\t}\n\t","\n"])),a.a),j=Object(i.gql)(p||(p=Object(r.a)(["\n\tmutation DELETE_DATETIME($input: DeleteEspressoDatetimeInput!) {\n\t\tdeleteEspressoDatetime(input: $input) {\n\t\t\tespressoDatetime {\n\t\t\t\t...datetimeAttributes\n\t\t\t}\n\t\t}\n\t}\n\t","\n"])),a.a),m=Object(i.gql)(v||(v=Object(r.a)(["\n\tmutation BULK_UPDATE_DATETIMES($input: BulkUpdateEspressoDatetimeInput!) {\n\t\tbulkUpdateEspressoDatetime(input: $input) {\n\t\t\tupdated\n\t\t\tfailed\n\t\t}\n\t}\n"])))},,function(t,e,n){"use strict";n.d(e,"c",(function(){return c})),n.d(e,"a",(function(){return s})),n.d(e,"b",(function(){return f}));var r,i,a,u=n(49),o=n(18),c=Object(o.gql)(r||(r=Object(u.a)(["\n\tfragment ticketAttributes on EspressoTicket {\n\t\tid\n\t\tdbId\n\t\tcacheId\n\t\tdescription\n\t\tendDate\n\t\tisDefault\n\t\tisExpired\n\t\tisFree\n\t\tisOnSale\n\t\tisPending\n\t\tisRequired\n\t\tisSoldOut\n\t\tisTrashed\n\t\tmax\n\t\tmin\n\t\tname\n\t\torder\n\t\tprice\n\t\tquantity\n\t\tregistrationCount\n\t\treserved\n\t\treverseCalculate\n\t\tsold\n\t\tstartDate\n\t\tuserId\n\t\tuses\n\t\tvisibility\n\t}\n"]))),s=Object(o.gql)(i||(i=Object(u.a)(["\n\tquery GET_TICKET($id: ID!) {\n\t\tespressoTicket(id: $id) {\n\t\t\t...ticketAttributes\n\t\t}\n\t}\n\t","\n"])),c),f=Object(o.gql)(a||(a=Object(u.a)(["\n\tquery GET_TICKETS($where: EspressoRootQueryTicketsConnectionWhereArgs) {\n\t\tespressoTickets(where: $where) {\n\t\t\tnodes {\n\t\t\t\t...ticketAttributes\n\t\t\t}\n\t\t}\n\t}\n\t","\n"])),c)},,,,,,,,function(t,e,n){var r=n(239),i=n(634),a=n(635),u=r?r.toStringTag:void 0;t.exports=function(t){return null==t?void 0===t?"[object Undefined]":"[object Null]":u&&u in Object(t)?i(t):a(t)}},function(t,e){t.exports=function(t){return null!=t&&"object"==typeof t}},function(t,e,n){var r=n(660);t.exports=function(t){return null==t?"":r(t)}},,,,,,,,,,,function(t,e,n){"use strict";n.d(e,"a",(function(){return c})),n.d(e,"b",(function(){return s})),n.d(e,"c",(function(){return f}));var r,i,a,u=n(49),o=n(18),c=Object(o.gql)(r||(r=Object(u.a)(["\n\tfragment datetimeAttributes on EspressoDatetime {\n\t\tid\n\t\tdbId\n\t\tcacheId\n\t\tcapacity\n\t\tdescription\n\t\tendDate\n\t\tisActive\n\t\tisExpired\n\t\tisPrimary\n\t\tisSoldOut\n\t\tisTrashed\n\t\tisUpcoming\n\t\tlength\n\t\tname\n\t\torder\n\t\treserved\n\t\tsold\n\t\tstatus\n\t\tstartDate\n\t\tvenue\n\t}\n"]))),s=Object(o.gql)(i||(i=Object(u.a)(["\n\tquery GET_DATETIME($id: ID!) {\n\t\tespressoDatetime(id: $id) {\n\t\t\t...datetimeAttributes\n\t\t}\n\t}\n\t","\n"])),c),f=Object(o.gql)(a||(a=Object(u.a)(["\n\tquery GET_DATETIMES($where: EspressoRootQueryDatetimesConnectionWhereArgs) {\n\t\tespressoDatetimes(where: $where) {\n\t\t\tnodes {\n\t\t\t\t...datetimeAttributes\n\t\t\t}\n\t\t}\n\t}\n\t","\n"])),c)},function(t,e,n){"use strict";n.d(e,"c",(function(){return s})),n.d(e,"b",(function(){return f})),n.d(e,"a",(function(){return l})),n.d(e,"d",(function(){return d})),n.d(e,"e",(function(){return p}));var r=n(14),i=n(2),a=n(8),u=n(12),o=n(50),c=n(17),s=function(t,e,n){var r=t.shiftDates,c=Object(a.a)(t,["shiftDates"]),s=[];if((null===r||void 0===r?void 0:r.unit)&&(null===r||void 0===r?void 0:r.value)&&(null===r||void 0===r?void 0:r.type)){var f=Object(u.entitiesWithGuIdInArray)(e,n),l=Object(o.shiftDate)(r);s=f.map((function(t){var e=l(t.startDate).toISOString(),n=l(t.endDate).toISOString();return{id:t.id,startDate:e,endDate:n}}))}else s=n.map((function(t){return{id:t}}));return{sharedInput:Object(i.a)(Object(i.a)({},c),{},{id:""}),uniqueInputs:s}},f=function(t,e){var n=t.uniqueInputs.reduce((function(t,e){return Object(i.a)(Object(i.a)({},t),{},Object(r.a)({},e.id,e))}),{});return e.map((function(e){return(null===n||void 0===n?void 0:n[e.id])?Object(i.a)(Object(i.a)(Object(i.a)(Object(i.a)({},e),t.sharedInput),n[e.id]),{},{cacheId:Object(c.uuid)()}):e}))},l=function(t,e,n){return n?Object(u.entitiesWithGuIdNotInArray)(e,t):e.map((function(e){return t.includes(e.id)?Object(i.a)(Object(i.a)({},e),{},{isTrashed:!0,cacheId:Object(c.uuid)()}):e}))},d=function(t){return Object(i.a)(Object(i.a)({},t),{},{isActive:Object(u.isActive)(t,!0),isExpired:Object(u.isExpired)(t,!0),isUpcoming:Object(u.isUpcoming)(t,!0)})},p=function(t){return Object(i.a)(Object(i.a)({},t),{},{isExpired:Object(u.isExpired)(t,!0),isFree:!t.price,isOnSale:Object(u.isOnSale)(t,!0),isPending:Object(u.isPending)(t,!0)})}},,,,,,function(t,e,n){"use strict";n.d(e,"c",(function(){return Ot})),n.d(e,"a",(function(){return gt})),n.d(e,"b",(function(){return qt}));var r,i,a=n(31),u=n(37),o=n(47);try{r=Map}catch(Bt){}try{i=Set}catch(Bt){}function c(t,e,n){if(!t||"object"!==typeof t||"function"===typeof t)return t;if(t.nodeType&&"cloneNode"in t)return t.cloneNode(!0);if(t instanceof Date)return new Date(t.getTime());if(t instanceof RegExp)return new RegExp(t);if(Array.isArray(t))return t.map(s);if(r&&t instanceof r)return new Map(Array.from(t.entries()));if(i&&t instanceof i)return new Set(Array.from(t.values()));if(t instanceof Object){e.push(t);var a=Object.create(t);for(var u in n.push(a),t){var o=e.findIndex((function(e){return e===t[u]}));a[u]=o>-1?n[o]:c(t[u],e,n)}return a}return t}function s(t){return c(t,[],[])}var f=Object.prototype.toString,l=Error.prototype.toString,d=RegExp.prototype.toString,p="undefined"!==typeof Symbol?Symbol.prototype.toString:function(){return""},v=/^Symbol\((.*)\)(.*)$/;function b(t){return t!=+t?"NaN":0===t&&1/t<0?"-0":""+t}function h(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(null==t||!0===t||!1===t)return""+t;var n=typeof t;if("number"===n)return b(t);if("string"===n)return e?'"'.concat(t,'"'):t;if("function"===n)return"[Function "+(t.name||"anonymous")+"]";if("symbol"===n)return p.call(t).replace(v,"Symbol($1)");var r=f.call(t).slice(8,-1);return"Date"===r?isNaN(t.getTime())?""+t:t.toISOString(t):"Error"===r||t instanceof Error?"["+l.call(t)+"]":"RegExp"===r?d.call(t):null}function y(t,e){var n=h(t,e);return null!==n?n:JSON.stringify(t,(function(t,n){var r=h(this[t],e);return null!==r?r:n}),2)}var O={default:"${path} is invalid",required:"${path} is a required field",oneOf:"${path} must be one of the following values: ${values}",notOneOf:"${path} must not be one of the following values: ${values}",notType:function(t){var e=t.path,n=t.type,r=t.value,i=t.originalValue,a=null!=i&&i!==r,u="".concat(e," must be a `").concat(n,"` type, ")+"but the final value was: `".concat(y(r,!0),"`")+(a?" (cast from the value `".concat(y(i,!0),"`)."):".");return null===r&&(u+='\n If "null" is intended as an empty value be sure to mark the schema as `.nullable()`'),u},defined:"${path} must be defined"},j={length:"${path} must be exactly ${length} characters",min:"${path} must be at least ${min} characters",max:"${path} must be at most ${max} characters",matches:'${path} must match the following: "${regex}"',email:"${path} must be a valid email",url:"${path} must be a valid URL",uuid:"${path} must be a valid UUID",trim:"${path} must be a trimmed string",lowercase:"${path} must be a lowercase string",uppercase:"${path} must be a upper case string"},m={min:"${path} must be greater than or equal to ${min}",max:"${path} must be less than or equal to ${max}",lessThan:"${path} must be less than ${less}",moreThan:"${path} must be greater than ${more}",positive:"${path} must be a positive number",negative:"${path} must be a negative number",integer:"${path} must be an integer"},E={min:"${path} field must be later than ${min}",max:"${path} field must be at earlier than ${max}"},T={isValue:"${path} field must be ${value}"},g={noUnknown:"${path} field has unspecified keys: ${unknown}"},_={min:"${path} field must have at least ${min} items",max:"${path} field must have less than or equal to ${max} items",length:"${path} must have ${length} items"},k=(Object.assign(Object.create(null),{mixed:O,string:j,number:m,date:E,object:g,array:_,boolean:T}),n(151)),D=n.n(k),I=function(t){return t&&t.__isYupSchema__},x=function(){function t(e,n){if(Object(u.a)(this,t),this.fn=void 0,this.refs=e,this.refs=e,"function"!==typeof n){if(!D()(n,"is"))throw new TypeError("`is:` is required for `when()` conditions");if(!n.then&&!n.otherwise)throw new TypeError("either `then:` or `otherwise:` is required for `when()` conditions");var r=n.is,i=n.then,a=n.otherwise,o="function"===typeof r?r:function(){for(var t=arguments.length,e=new Array(t),n=0;n1?"".concat(c.errors.length," errors occurred"):c.errors[0],Error.captureStackTrace&&Error.captureStackTrace(Object(w.a)(c),n),c}return Object(o.a)(n,null,[{key:"formatError",value:function(t,e){var n=e.label||e.path||"this";return n!==e.path&&(e=P({},e,{path:n})),"string"===typeof t?t.replace(R,(function(t,n){return y(e[n])})):"function"===typeof t?t(e):t}},{key:"isError",value:function(t){return t&&"ValidationError"===t.name}}]),n}(Object(S.a)(Error));function M(t,e){var n=t.endEarly,r=t.tests,i=t.args,u=t.value,o=t.errors,c=t.sort,s=t.path,f=function(t){var e=!1;return function(){e||(e=!0,t.apply(void 0,arguments))}}(e),l=r.length,d=[];if(o=o||[],!l)return o.length?f(new U(o,u,s)):f(null,u);for(var p=0;p1&&void 0!==arguments[1]?arguments[1]:{};if(Object(u.a)(this,t),this.key=void 0,this.isContext=void 0,this.isValue=void 0,this.isSibling=void 0,this.path=void 0,this.getter=void 0,this.map=void 0,"string"!==typeof e)throw new TypeError("ref must be a string, got: "+e);if(this.key=e.trim(),""===e)throw new TypeError("ref must be a non-empty string");this.isContext=this.key[0]===q,this.isValue=this.key[0]===G,this.isSibling=!this.isContext&&!this.isValue;var r=this.isContext?q:this.isValue?G:"";this.path=this.key.slice(r.length),this.getter=this.path&&Object($.getter)(this.path,!0),this.map=n.map}return Object(o.a)(t,[{key:"getValue",value:function(t,e,n){var r=this.isContext?n:this.isValue?t:e;return this.getter&&(r=this.getter(r||{})),this.map&&(r=this.map(r)),r}},{key:"cast",value:function(t,e){return this.getValue(t,null==e?void 0:e.parent,null==e?void 0:e.context)}},{key:"resolve",value:function(){return this}},{key:"describe",value:function(){return{type:"ref",key:this.key}}},{key:"toString",value:function(){return"Ref(".concat(this.key,")")}}],[{key:"isRef",value:function(t){return t&&t.__isYupRef}}]),t}();function B(){return(B=Object.assign||function(t){for(var e=1;e=0||(i[n]=t[n]);return i}(e,["value","path","label","options","originalValue","sync"]),l=t.name,d=t.test,p=t.params,v=t.message,b=o.parent,h=o.context;function y(t){return z.isRef(t)?t.getValue(r,b,h):t}function O(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=N()(B({value:r,originalValue:c,label:u,path:t.path||a},p,t.params),y),n=new U(U.formatError(t.message||v,e),r,e.path,t.type||l);return n.params=e,n}var j=B({path:a,parent:b,type:l,createError:O,resolve:y,options:o,originalValue:c},f);if(s){var m;try{var E;if("function"===typeof(null==(E=m=d.call(j,r,j))?void 0:E.then))throw new Error('Validation test of type: "'.concat(j.type,'" returned a Promise during a synchronous validate. ')+"This test will finish after the validate call has returned")}catch(T){return void n(T)}U.isError(m)?n(m):m?n(null,m):n(O())}else try{Promise.resolve(d.call(j,r,j)).then((function(t){U.isError(t)?n(t):t?n(null,t):n(O())})).catch(n)}catch(T){n(T)}}return e.OPTIONS=t,e}z.prototype.__isYupRef=!0;var K=function(t){return t.substr(0,t.length-1).substr(1)};function Q(t,e,n){var r,i,a,u=arguments.length>3&&void 0!==arguments[3]?arguments[3]:n;return e?(Object($.forEach)(e,(function(o,c,s){var f=c?K(o):o;if((t=t.resolve({context:u,parent:r,value:n})).innerType){var l=s?parseInt(f,10):0;if(n&&l>=n.length)throw new Error("Yup.reach cannot resolve an array item at index: ".concat(o,", in the path: ").concat(e,". ")+"because there is no value at that index. ");r=n,n=n&&n[l],t=t.innerType}if(!s){if(!t.fields||!t.fields[f])throw new Error("The schema does not contain the path: ".concat(e,". ")+"(failed at: ".concat(a,' which is a type: "').concat(t._type,'")'));r=n,n=n&&n[f],t=t.fields[f]}i=f,a=c?"["+o+"]":"."+o})),{schema:t,parent:r,parentPath:i}):{parent:r,parentPath:e,schema:t}}var W=n(9),Y=n(80),H=function(){function t(){Object(u.a)(this,t),this.list=void 0,this.refs=void 0,this.list=new Set,this.refs=new Map}return Object(o.a)(t,[{key:"size",get:function(){return this.list.size+this.refs.size}},{key:"describe",value:function(){var t,e=[],n=Object(Y.a)(this.list);try{for(n.s();!(t=n.n()).done;){var r=t.value;e.push(r)}}catch(o){n.e(o)}finally{n.f()}var i,a=Object(Y.a)(this.refs);try{for(a.s();!(i=a.n()).done;){var u=Object(W.a)(i.value,2)[1];e.push(u.describe())}}catch(o){a.e(o)}finally{a.f()}return e}},{key:"toArray",value:function(){return Array.from(this.list).concat(Array.from(this.refs.values()))}},{key:"resolveAll",value:function(t){return this.toArray().reduce((function(e,n){return e.concat(z.isRef(n)?t(n):n)}),[])}},{key:"add",value:function(t){z.isRef(t)?this.refs.set(t.key,t):this.list.add(t)}},{key:"delete",value:function(t){z.isRef(t)?this.refs.delete(t.key):this.list.delete(t)}},{key:"clone",value:function(){var e=new t;return e.list=new Set(this.list),e.refs=new Map(this.refs),e}},{key:"merge",value:function(t,e){var n=this.clone();return t.list.forEach((function(t){return n.add(t)})),t.refs.forEach((function(t){return n.add(t)})),e.list.forEach((function(t){return n.delete(t)})),e.refs.forEach((function(t){return n.delete(t)})),n}}]),t}();function Z(){return(Z=Object.assign||function(t){for(var e=1;e1&&void 0!==arguments[1]?arguments[1]:{},n=this.resolve(Z({value:t},e)),r=n._cast(t,e);if(void 0!==t&&!1!==e.assert&&!0!==n.isType(r)){var i=y(t),a=y(r);throw new TypeError("The value of ".concat(e.path||"field"," could not be cast to a value ")+'that satisfies the schema type: "'.concat(n._type,'". \n\n')+"attempted value: ".concat(i," \n")+(a!==i?"result of cast: ".concat(a):""))}return r}},{key:"_cast",value:function(t,e){var n=this,r=void 0===t?t:this.transforms.reduce((function(e,r){return r.call(n,e,t,n)}),t);return void 0===r&&(r=this.getDefault()),r}},{key:"_validate",value:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2?arguments[2]:void 0,i=n.sync,a=n.path,u=n.from,o=void 0===u?[]:u,c=n.originalValue,s=void 0===c?t:c,f=n.strict,l=void 0===f?this.spec.strict:f,d=n.abortEarly,p=void 0===d?this.spec.abortEarly:d,v=t;l||(v=this._cast(v,Z({assert:!1},n)));var b={value:v,path:a,options:n,originalValue:s,schema:this,label:this.spec.label,sync:i,from:o},h=[];this._typeError&&h.push(this._typeError);var y=[];this._whitelistError&&y.push(this._whitelistError),this._blacklistError&&y.push(this._blacklistError),M({args:b,value:v,path:a,sync:i,tests:h,endEarly:p},(function(t){t?r(t,v):M({tests:e.tests.concat(y),args:b,path:a,sync:i,value:v,endEarly:p},r)}))}},{key:"validate",value:function(t,e,n){var r=this.resolve(Z({},e,{value:t}));return"function"===typeof n?r._validate(t,e,n):new Promise((function(n,i){return r._validate(t,e,(function(t,e){t?i(t):n(e)}))}))}},{key:"validateSync",value:function(t,e){var n;return this.resolve(Z({},e,{value:t}))._validate(t,Z({},e,{sync:!0}),(function(t,e){if(t)throw t;n=e})),n}},{key:"isValid",value:function(t,e){return this.validate(t,e).then((function(){return!0}),(function(t){if(U.isError(t))return!1;throw t}))}},{key:"isValidSync",value:function(t,e){try{return this.validateSync(t,e),!0}catch(n){if(U.isError(n))return!1;throw n}}},{key:"_getDefault",value:function(){var t=this.spec.default;return null==t?t:"function"===typeof t?t.call(this):s(t)}},{key:"getDefault",value:function(t){return this.resolve(t||{})._getDefault()}},{key:"default",value:function(t){if(0===arguments.length)return this._getDefault();var e=this.clone({default:t});return e}},{key:"strict",value:function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],e=this.clone();return e.spec.strict=t,e}},{key:"_isPresent",value:function(t){return null!=t}},{key:"defined",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:O.defined;return this.test({message:t,name:"defined",exclusive:!0,test:function(t){return void 0!==t}})}},{key:"required",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:O.required;return this.clone({presence:"required"}).withMutation((function(e){return e.test({message:t,name:"required",exclusive:!0,test:function(t){return this.schema._isPresent(t)}})}))}},{key:"notRequired",value:function(){var t=this.clone({presence:"optional"});return t.tests=t.tests.filter((function(t){return"required"!==t.OPTIONS.name})),t}},{key:"nullable",value:function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],e=this.clone({nullable:!1!==t});return e}},{key:"transform",value:function(t){var e=this.clone();return e.transforms.push(t),e}},{key:"test",value:function(){var t;if(void 0===(t=1===arguments.length?"function"===typeof(arguments.length<=0?void 0:arguments[0])?{test:arguments.length<=0?void 0:arguments[0]}:arguments.length<=0?void 0:arguments[0]:2===arguments.length?{name:arguments.length<=0?void 0:arguments[0],test:arguments.length<=1?void 0:arguments[1]}:{name:arguments.length<=0?void 0:arguments[0],message:arguments.length<=1?void 0:arguments[1],test:arguments.length<=2?void 0:arguments[2]}).message&&(t.message=O.default),"function"!==typeof t.test)throw new TypeError("`test` is a required parameters");var e=this.clone(),n=V(t),r=t.exclusive||t.name&&!0===e.exclusiveTests[t.name];if(t.exclusive&&!t.name)throw new TypeError("Exclusive tests must provide a unique `name` identifying the test");return t.name&&(e.exclusiveTests[t.name]=!!t.exclusive),e.tests=e.tests.filter((function(e){if(e.OPTIONS.name===t.name){if(r)return!1;if(e.OPTIONS.test===n.OPTIONS.test)return!1}return!0})),e.tests.push(n),e}},{key:"when",value:function(t,e){Array.isArray(t)||"string"===typeof t||(e=t,t=".");var n=this.clone(),r=F(t).map((function(t){return new z(t)}));return r.forEach((function(t){t.isSibling&&n.deps.push(t.key)})),n.conditions.push(new x(r,e)),n}},{key:"typeError",value:function(t){var e=this.clone();return e._typeError=V({message:t,name:"typeError",test:function(t){return!(void 0!==t&&!this.schema.isType(t))||this.createError({params:{type:this.schema._type}})}}),e}},{key:"oneOf",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:O.oneOf,n=this.clone();return t.forEach((function(t){n._whitelist.add(t),n._blacklist.delete(t)})),n._whitelistError=V({message:e,name:"oneOf",test:function(t){if(void 0===t)return!0;var e=this.schema._whitelist,n=e.resolveAll(this.resolve);return!!n.includes(t)||this.createError({params:{values:e.toArray().join(", "),resolved:n}})}}),n}},{key:"notOneOf",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:O.notOneOf,n=this.clone();return t.forEach((function(t){n._blacklist.add(t),n._whitelist.delete(t)})),n._blacklistError=V({message:e,name:"notOneOf",test:function(t){var e=this.schema._blacklist,n=e.resolveAll(this.resolve);return!n.includes(t)||this.createError({params:{values:e.toArray().join(", "),resolved:n}})}}),n}},{key:"strip",value:function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],e=this.clone();return e.spec.strip=t,e}},{key:"describe",value:function(){var t=this.clone(),e=t.spec,n=e.label;return{meta:e.meta,label:n,type:t.type,oneOf:t._whitelist.describe(),notOneOf:t._blacklist.describe(),tests:t.tests.map((function(t){return{name:t.OPTIONS.name,params:t.OPTIONS.params}})).filter((function(t,e,n){return n.findIndex((function(e){return e.name===t.name}))===e}))}}}]),t}();J.prototype.__isYupSchema__=!0;for(var X=function(){var t=et[tt];J.prototype["".concat(t,"At")]=function(e,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=Q(this,e,n,r.context),a=i.parent,u=i.parentPath,o=i.schema;return o[t](a&&a[u],Z({},r,{parent:a,path:e}))}},tt=0,et=["validate","validateSync"];tt0&&void 0!==arguments[0]?arguments[0]:T.isValue;return this.test({message:t,name:"is-value",exclusive:!0,params:{value:"true"},test:function(t){return st(t)||!0===t}})}},{key:"isFalse",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:T.isValue;return this.test({message:t,name:"is-value",exclusive:!0,params:{value:"false"},test:function(t){return st(t)||!1===t}})}}]),n}(J);ft.prototype;var lt=n(59),dt=n(46),pt=/^((([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+(\.([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+)*)|((\x22)((((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(([\x01-\x08\x0b\x0c\x0e-\x1f\x7f]|\x21|[\x23-\x5b]|[\x5d-\x7e]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(\\([\x01-\x09\x0b\x0c\x0d-\x7f]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]))))*(((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(\x22)))@((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))$/i,vt=/^((https?|ftp):)?\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,bt=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,ht=function(t){return st(t)||t===t.trim()},yt={}.toString();function Ot(){return new jt}var jt=function(t){Object(C.a)(n,t);var e=Object(A.a)(n);function n(){var t;return Object(u.a)(this,n),(t=e.call(this,{type:"string"})).withMutation((function(){t.transform((function(t){if(this.isType(t))return t;if(Array.isArray(t))return t;var e=null!=t&&t.toString?t.toString():t;return e===yt?t:e}))})),t}return Object(o.a)(n,[{key:"_typeCheck",value:function(t){return t instanceof String&&(t=t.valueOf()),"string"===typeof t}},{key:"_isPresent",value:function(t){return Object(lt.a)(Object(dt.a)(n.prototype),"_isPresent",this).call(this,t)&&!!t.length}},{key:"length",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:j.length;return this.test({message:e,name:"length",exclusive:!0,params:{length:t},test:function(e){return st(e)||e.length===this.resolve(t)}})}},{key:"min",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:j.min;return this.test({message:e,name:"min",exclusive:!0,params:{min:t},test:function(e){return st(e)||e.length>=this.resolve(t)}})}},{key:"max",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:j.max;return this.test({name:"max",exclusive:!0,message:e,params:{max:t},test:function(e){return st(e)||e.length<=this.resolve(t)}})}},{key:"matches",value:function(t,e){var n,r,i=!1;if(e)if("object"===typeof e){var a=e.excludeEmptyString;i=void 0!==a&&a,n=e.message,r=e.name}else n=e;return this.test({name:r||"matches",message:n||j.matches,params:{regex:t},test:function(e){return st(e)||""===e&&i||-1!==e.search(t)}})}},{key:"email",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:j.email;return this.matches(pt,{name:"email",message:t,excludeEmptyString:!0})}},{key:"url",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:j.url;return this.matches(vt,{name:"url",message:t,excludeEmptyString:!0})}},{key:"uuid",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:j.uuid;return this.matches(bt,{name:"uuid",message:t,excludeEmptyString:!1})}},{key:"ensure",value:function(){return this.default("").transform((function(t){return null===t?"":t}))}},{key:"trim",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:j.trim;return this.transform((function(t){return null!=t?t.trim():t})).test({message:t,name:"trim",test:ht})}},{key:"lowercase",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:j.lowercase;return this.transform((function(t){return st(t)?t:t.toLowerCase()})).test({message:t,name:"string_case",exclusive:!0,test:function(t){return st(t)||t===t.toLowerCase()}})}},{key:"uppercase",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:j.uppercase;return this.transform((function(t){return st(t)?t:t.toUpperCase()})).test({message:t,name:"string_case",exclusive:!0,test:function(t){return st(t)||t===t.toUpperCase()}})}}]),n}(J);Ot.prototype=jt.prototype;var mt=function(t){Object(C.a)(n,t);var e=Object(A.a)(n);function n(){var t;return Object(u.a)(this,n),(t=e.call(this,{type:"number"})).withMutation((function(){t.transform((function(t){var e=t;if("string"===typeof e){if(""===(e=e.replace(/\s/g,"")))return NaN;e=+e}return this.isType(e)?e:parseFloat(e)}))})),t}return Object(o.a)(n,[{key:"_typeCheck",value:function(t){return t instanceof Number&&(t=t.valueOf()),"number"===typeof t&&!function(t){return t!=+t}(t)}},{key:"min",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:m.min;return this.test({message:e,name:"min",exclusive:!0,params:{min:t},test:function(e){return st(e)||e>=this.resolve(t)}})}},{key:"max",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:m.max;return this.test({message:e,name:"max",exclusive:!0,params:{max:t},test:function(e){return st(e)||e<=this.resolve(t)}})}},{key:"lessThan",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:m.lessThan;return this.test({message:e,name:"max",exclusive:!0,params:{less:t},test:function(e){return st(e)||e1&&void 0!==arguments[1]?arguments[1]:m.moreThan;return this.test({message:e,name:"min",exclusive:!0,params:{more:t},test:function(e){return st(e)||e>this.resolve(t)}})}},{key:"positive",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:m.positive;return this.moreThan(0,t)}},{key:"negative",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:m.negative;return this.lessThan(0,t)}},{key:"integer",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:m.integer;return this.test({name:"integer",message:t,test:function(t){return st(t)||Number.isInteger(t)}})}},{key:"truncate",value:function(){return this.transform((function(t){return st(t)?t:0|t}))}},{key:"round",value:function(t){var e,n=["ceil","floor","round","trunc"];if("trunc"===(t=(null==(e=t)?void 0:e.toLowerCase())||"round"))return this.truncate();if(-1===n.indexOf(t.toLowerCase()))throw new TypeError("Only valid options for round() are: "+n.join(", "));return this.transform((function(e){return st(e)?e:Math[t](e)}))}}]),n}(J);mt.prototype;var Et=/^(\d{4}|[+\-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,\.](\d{1,}))?)?(?:(Z)|([+\-])(\d{2})(?::?(\d{2}))?)?)?$/;var Tt=new Date("");function gt(){return new _t}var _t=function(t){Object(C.a)(n,t);var e=Object(A.a)(n);function n(){var t;return Object(u.a)(this,n),(t=e.call(this,{type:"date"})).withMutation((function(){t.transform((function(t){return this.isType(t)?t:(t=function(t){var e,n,r=[1,4,5,6,7,10,11],i=0;if(n=Et.exec(t)){for(var a,u=0;a=r[u];++u)n[a]=+n[a]||0;n[2]=(+n[2]||1)-1,n[3]=+n[3]||1,n[7]=n[7]?String(n[7]).substr(0,3):0,void 0!==n[8]&&""!==n[8]||void 0!==n[9]&&""!==n[9]?("Z"!==n[8]&&void 0!==n[9]&&(i=60*n[10]+n[11],"+"===n[9]&&(i=0-i)),e=Date.UTC(n[1],n[2],n[3],n[4],n[5]+i,n[6],n[7])):e=+new Date(n[1],n[2],n[3],n[4],n[5],n[6],n[7])}else e=Date.parse?Date.parse(t):NaN;return e}(t),isNaN(t)?Tt:new Date(t))}))})),t}return Object(o.a)(n,[{key:"_typeCheck",value:function(t){return e=t,"[object Date]"===Object.prototype.toString.call(e)&&!isNaN(t.getTime());var e}},{key:"prepareParam",value:function(t,e){var n;if(z.isRef(t))n=t;else{var r=this.cast(t);if(!this._typeCheck(r))throw new TypeError("`".concat(e,"` must be a Date or a value that can be `cast()` to a Date"));n=r}return n}},{key:"min",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:E.min,n=this.prepareParam(t,"min");return this.test({message:e,name:"min",exclusive:!0,params:{min:t},test:function(t){return st(t)||t>=this.resolve(n)}})}},{key:"max",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:E.max,n=this.prepareParam(t,"max");return this.test({message:e,name:"max",exclusive:!0,params:{max:t},test:function(t){return st(t)||t<=this.resolve(n)}})}}]),n}(J);_t.INVALID_DATE=Tt,gt.prototype=_t.prototype,gt.INVALID_DATE=Tt;var kt=n(327),Dt=n.n(kt),It=n(433),xt=n.n(It),wt=n(434),Ct=n.n(wt),At=n(435),St=n.n(At);function Ft(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=[],r=new Set,i=new Set(e.map((function(t){var e=Object(W.a)(t,2),n=e[0],r=e[1];return"".concat(n,"-").concat(r)})));function a(t,e){var a=Object($.split)(t)[0];r.add(a),i.has("".concat(e,"-").concat(a))||n.push([e,a])}var u=function(e){if(D()(t,e)){var n=t[e];r.add(e),z.isRef(n)&&n.isSibling?a(n.path,e):I(n)&&"deps"in n&&n.deps.forEach((function(t){return a(t,e)}))}};for(var o in t)u(o);return St.a.array(Array.from(r),n).reverse()}function Pt(t,e){var n=1/0;return t.some((function(t,r){var i;if(-1!==(null==(i=e.path)?void 0:i.indexOf(t)))return n=r,!0})),n}function Rt(t){return function(e,n){return Pt(t,e)-Pt(t,n)}}function Ut(){return(Ut=Object.assign||function(t){for(var e=1;e1&&void 0!==arguments[1]?arguments[1]:{},a=Object(lt.a)(Object(dt.a)(n.prototype),"_cast",this).call(this,t,i);if(void 0===a)return this.getDefault();if(!this._typeCheck(a))return a;var u,o=this.fields,c=null!=(e=i.stripUnknown)?e:this.spec.noUnknown,s=this._nodes.concat(Object.keys(a).filter((function(t){return-1===r._nodes.indexOf(t)}))),f={},l=Ut({},i,{parent:f,__validating:i.__validating||!1}),d=!1,p=Object(Y.a)(s);try{for(p.s();!(u=p.n()).done;){var v=u.value,b=o[v],h=D()(a,v);if(b){var y=void 0,O=a[v];l.path=(i.path?"".concat(i.path,"."):"")+v;var j="spec"in(b=b.resolve({value:O,context:i.context,parent:f}))?b.spec:void 0,m=null==j?void 0:j.strict;if(null==j?void 0:j.strip){d=d||v in a;continue}void 0!==(y=i.__validating&&m?a[v]:b.cast(a[v],l))&&(f[v]=y)}else h&&!c&&(f[v]=a[v]);f[v]!==a[v]&&(d=!0)}}catch(E){p.e(E)}finally{p.f()}return d?f:a}},{key:"_validate",value:function(t){var e=this,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=arguments.length>2?arguments[2]:void 0,u=[],o=r.sync,c=r.from,s=void 0===c?[]:c,f=r.originalValue,l=void 0===f?t:f,d=r.abortEarly,p=void 0===d?this.spec.abortEarly:d,v=r.recursive,b=void 0===v?this.spec.recursive:v;s=[{schema:this,value:l}].concat(Object(a.a)(s)),r.__validating=!0,r.originalValue=l,r.from=s,Object(lt.a)(Object(dt.a)(n.prototype),"_validate",this).call(this,t,r,(function(t,n){if(t){if(!U.isError(t)||p)return void i(t,n);u.push(t)}if(b&&Mt(n)){l=l||n;var a=e._nodes.map((function(t){return function(i,a){var u=-1===t.indexOf(".")?(r.path?"".concat(r.path,"."):"")+t:"".concat(r.path||"",'["').concat(t,'"]'),o=e.fields[t];o&&"validate"in o?o.validate(n[t],Ut({},r,{path:u,from:s,strict:!0,parent:n,originalValue:l[t]}),a):a(null)}}));M({sync:o,tests:a,value:n,errors:u,endEarly:p,sort:e._sortErrors,path:r.path},i)}else i(u[0]||null,n)}))}},{key:"clone",value:function(t){var e=Object(lt.a)(Object(dt.a)(n.prototype),"clone",this).call(this,t);return e.fields=Ut({},this.fields),e._nodes=this._nodes,e._excludedEdges=this._excludedEdges,e._sortErrors=this._sortErrors,e}},{key:"concat",value:function(t){for(var e=this,r=Object(lt.a)(Object(dt.a)(n.prototype),"concat",this).call(this,t),i=r.fields,a=0,u=Object.entries(this.fields);a1&&void 0!==arguments[1]?arguments[1]:[],n=this.clone(),r=Object.assign(n.fields,t);return n.fields=r,n._sortErrors=Rt(Object.keys(r)),e.length&&(Array.isArray(e[0])||(e=[e]),n._excludedEdges=[].concat(Object(a.a)(n._excludedEdges),Object(a.a)(e))),n._nodes=Ft(r,n._excludedEdges),n}},{key:"pick",value:function(t){var e,n={},r=Object(Y.a)(t);try{for(r.s();!(e=r.n()).done;){var i=e.value;this.fields[i]&&(n[i]=this.fields[i])}}catch(a){r.e(a)}finally{r.f()}return this.clone().withMutation((function(t){return t.fields={},t.shape(n)}))}},{key:"omit",value:function(t){var e=this.clone(),n=e.fields;e.fields={};var r,i=Object(Y.a)(t);try{for(i.s();!(r=i.n()).done;){var a=r.value;delete n[a]}}catch(u){i.e(u)}finally{i.f()}return e.withMutation((function(){return e.shape(n)}))}},{key:"from",value:function(t,e,n){var r=Object($.getter)(t,!0);return this.transform((function(i){if(null==i)return i;var a=i;return D()(i,t)&&(a=Ut({},i),n||delete a[t],a[e]=r(i)),a}))}},{key:"noUnknown",value:function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:g.noUnknown;"string"===typeof t&&(e=t,t=!0);var n=this.test({name:"noUnknown",exclusive:!0,message:e,test:function(e){if(null==e)return!0;var n=Lt(this.schema,e);return!t||0===n.length||this.createError({params:{unknown:n.join(", ")}})}});return n.spec.noUnknown=t,n}},{key:"unknown",value:function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:g.noUnknown;return this.noUnknown(!t,e)}},{key:"transformKeys",value:function(t){return this.transform((function(e){return e&&Ct()(e,(function(e,n){return t(n)}))}))}},{key:"camelCase",value:function(){return this.transformKeys(xt.a)}},{key:"snakeCase",value:function(){return this.transformKeys(Dt.a)}},{key:"constantCase",value:function(){return this.transformKeys((function(t){return Dt()(t).toUpperCase()}))}},{key:"describe",value:function(){var t=Object(lt.a)(Object(dt.a)(n.prototype),"describe",this).call(this);return t.fields=N()(this.fields,(function(t){return t.describe()})),t}}]),n}(J);function qt(t){return new $t(t)}function Gt(){return(Gt=Object.assign||function(t){for(var e=1;e1&&void 0!==arguments[1]?arguments[1]:{},u=arguments.length>2?arguments[2]:void 0,o=[],c=a.sync,s=a.path,f=this.innerType,l=null!=(e=a.abortEarly)?e:this.spec.abortEarly,d=null!=(r=a.recursive)?r:this.spec.recursive,p=null!=a.originalValue?a.originalValue:t;Object(lt.a)(Object(dt.a)(n.prototype),"_validate",this).call(this,t,a,(function(t,e){if(t){if(!U.isError(t)||l)return void u(t,e);o.push(t)}if(d&&f&&i._typeCheck(e)){p=p||e;for(var n=new Array(e.length),r=function(t){var r=e[t],i="".concat(a.path||"","[").concat(t,"]"),u=Gt({},a,{path:i,strict:!0,parent:e,index:t,originalValue:p[t]});n[t]=function(t,e){return f.validate(r,u,e)}},v=0;v1&&void 0!==arguments[1]?arguments[1]:_.length;return this.test({message:e,name:"length",exclusive:!0,params:{length:t},test:function(e){return st(e)||e.length===this.resolve(t)}})}},{key:"min",value:function(t,e){return e=e||_.min,this.test({message:e,name:"min",exclusive:!0,params:{min:t},test:function(e){return st(e)||e.length>=this.resolve(t)}})}},{key:"max",value:function(t,e){return e=e||_.max,this.test({message:e,name:"max",exclusive:!0,params:{max:t},test:function(e){return st(e)||e.length<=this.resolve(t)}})}},{key:"ensure",value:function(){var t=this;return this.default((function(){return[]})).transform((function(e,n){return t._typeCheck(e)?e:null==n?[]:[].concat(n)}))}},{key:"compact",value:function(t){var e=t?function(e,n,r){return!t(e,n,r)}:function(t){return!!t};return this.transform((function(t){return null!=t?t.filter(e):t}))}},{key:"describe",value:function(){var t=Object(lt.a)(Object(dt.a)(n.prototype),"describe",this).call(this);return this.innerType&&(t.innerType=this.innerType.describe()),t}},{key:"nullable",value:function(){var t=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return Object(lt.a)(Object(dt.a)(n.prototype),"nullable",this).call(this,t)}},{key:"defined",value:function(){return Object(lt.a)(Object(dt.a)(n.prototype),"defined",this).call(this)}},{key:"required",value:function(t){return Object(lt.a)(Object(dt.a)(n.prototype),"required",this).call(this,t)}}]),n}(J);zt.prototype},,,,,function(t,e){t.exports=window.eventespresso.slotFill},,,function(t,e,n){"use strict";var r=n(264),i=n(26),a=n(12),u=n(18);e.a=function(){var t,e=Object(r.a)(),n=Object(u.useDatetimesQuery)(e).data,o=(null===n||void 0===n||null===(t=n.espressoDatetimes)||void 0===t?void 0:t.nodes)||[],c=Object(a.getCacheIds)(o);return Object(i.useMemoStringify)(o,c)}},function(t,e,n){"use strict";n.r(e),n.d(e,"CREATE_PRICE",(function(){return p})),n.d(e,"UPDATE_PRICE",(function(){return v})),n.d(e,"DELETE_PRICE",(function(){return b}));var r=n(49),i=n(18),a=n(291),u=n(1281);n.d(e,"usePriceMutator",(function(){return u.a}));var o=n(994);n.d(e,"useBulkDeletePrices",(function(){return o.a}));var c,s,f,l=n(995);for(var d in l)["default","CREATE_PRICE","UPDATE_PRICE","DELETE_PRICE","usePriceMutator","useBulkDeletePrices"].indexOf(d)<0&&function(t){n.d(e,t,(function(){return l[t]}))}(d);var p=Object(i.gql)(c||(c=Object(r.a)(["\n\tmutation CREATE_PRICE($input: CreateEspressoPriceInput!) {\n\t\tcreateEspressoPrice(input: $input) {\n\t\t\tespressoPrice {\n\t\t\t\t...priceAttributes\n\t\t\t}\n\t\t}\n\t}\n\t","\n"])),a.c),v=Object(i.gql)(s||(s=Object(r.a)(["\n\tmutation UPDATE_PRICE($input: UpdateEspressoPriceInput!) {\n\t\tupdateEspressoPrice(input: $input) {\n\t\t\tespressoPrice {\n\t\t\t\t...priceAttributes\n\t\t\t}\n\t\t}\n\t}\n\t","\n"])),a.c),b=Object(i.gql)(f||(f=Object(r.a)(["\n\tmutation DELETE_PRICE($input: DeleteEspressoPriceInput!) {\n\t\tdeleteEspressoPrice(input: $input) {\n\t\t\tespressoPrice {\n\t\t\t\tid\n\t\t\t}\n\t\t}\n\t}\n"])))},,,,,,function(t,e,n){"use strict";n(159)},function(t,e,n){"use strict";n.r(e);var r=n(1329);n.d(e,"useCacheRehydration",(function(){return r.a}));var i=n(1364);n.d(e,"useTicketsMeta",(function(){return i.a}));var a=n(385);for(var u in a)["default","useCacheRehydration","useTicketsMeta"].indexOf(u)<0&&function(t){n.d(e,t,(function(){return a[t]}))}(u);var o=n(79);for(var u in o)["default","useCacheRehydration","useTicketsMeta"].indexOf(u)<0&&function(t){n.d(e,t,(function(){return o[t]}))}(u);var c=n(996);n.d(e,"DateStatus",(function(){return c.a})),n.d(e,"isDatetime",(function(){return c.c})),n.d(e,"PriceBasetype",(function(){return c.b}))},function(t,e,n){var r=n(122).Symbol;t.exports=r},function(t,e,n){var r=n(148)(Object,"create");t.exports=r},function(t,e,n){var r=n(650),i=n(651),a=n(652),u=n(653),o=n(654);function c(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e-1&&t%1==0&&t<=9007199254740991}},function(t,e,n){var r=n(666),i=n(672),a=n(676);t.exports=function(t){return a(t)?r(t):i(t)}},,,,,,,,,,,,,,,,,,,,,,,,,function(t,e,n){var r=n(405)((function(t,e,n){return t+(n?"_":"")+e.toLowerCase()}));t.exports=r},,,,,,,,function(t,e,n){"use strict";n.d(e,"q",(function(){return d})),n.d(e,"e",(function(){return b})),n.d(e,"c",(function(){return p.b})),n.d(e,"d",(function(){return p.c})),n.d(e,"b",(function(){return p.a})),n.d(e,"g",(function(){return v.b})),n.d(e,"h",(function(){return v.c})),n.d(e,"f",(function(){return v.a})),n.d(e,"p",(function(){return O})),n.d(e,"n",(function(){return h.b})),n.d(e,"o",(function(){return h.c})),n.d(e,"m",(function(){return h.a})),n.d(e,"j",(function(){return y.b})),n.d(e,"k",(function(){return y.c})),n.d(e,"i",(function(){return y.a})),n.d(e,"r",(function(){return m})),n.d(e,"l",(function(){return f})),n.d(e,"a",(function(){return l}));var r=n(2),i=n(18),a=n(27),u=n(227),o=n(24),c=n(45),s=n(1),f=function(t){var e=t.children;return Object(s.jsx)(a.ThemeProvider,{children:Object(s.jsx)(o.StatusProvider,{children:Object(s.jsx)(o.ConfigProvider,{children:Object(s.jsx)(o.FeaturesProvider,{children:Object(s.jsx)(o.RelationsProvider,{children:Object(s.jsx)(u.SlotFillProvider,{children:Object(s.jsx)(c.GlobalModalProvider,{children:e})})})})})})})},l=function(t){var e=t.children;return Object(s.jsx)(i.DataProvider,{children:Object(s.jsx)(f,{children:e})})},d=function(t){return function(e){return Object(s.jsx)(l,{children:Object(s.jsx)(t,Object(r.a)({},e))})}},p=n(428),v=n(429),b=function(t){var e=t.children;return Object(s.jsx)(p.c,{children:Object(s.jsx)(v.c,{children:e})})},h=n(430),y=n(431),O=function(t){var e=t.children;return Object(s.jsx)(h.c,{children:Object(s.jsx)(y.c,{children:e})})},j=n(8),m=function(t){var e=t.Provider,n=t.Component,i=Object(j.a)(t,["Provider","Component"]);return function(){return Object(s.jsx)(e,{children:Object(s.jsx)(n,Object(r.a)({},i))})}}},function(t,e,n){"use strict";n.d(e,"a",(function(){return r.a})),n.d(e,"b",(function(){return r.b})),n.d(e,"c",(function(){return r.c})),n.d(e,"d",(function(){return o})),n.d(e,"e",(function(){return f})),n.d(e,"h",(function(){return l.a})),n.d(e,"f",(function(){return d.a})),n.d(e,"g",(function(){return u.a})),n.d(e,"i",(function(){return b}));var r=n(215),i=n(26),a=n(12),u=n(230),o=function(){var t=Object(u.a)();return Object(i.useMemoStringify)(Object(a.getGuids)(t))},c=n(0),s=n(18),f=function(t){var e=t.id,n=Object(c.useMemo)((function(){return{query:r.b,variables:{id:e},returnPartialData:!0}}),[e]),a=Object(s.useCacheQuery)(n).data;return Object(i.useMemoStringify)(null===a||void 0===a?void 0:a.espressoDatetime)},l=n(771),d=n(264),p=n(17),v=n(24),b=function(t){var e=t.entity,n=t.entityId,r=Object(u.a)(),i=(0,Object(v.useRelations)().getRelations)({entity:e,entityId:n,relation:"datetimes"}),o=Object(p.entityListCacheIdString)(r),s=JSON.stringify(i);return Object(c.useMemo)((function(){return Object(a.entitiesWithGuIdInArray)(r,i)}),[s,o])}},function(t,e,n){"use strict";n.d(e,"c",(function(){return r.c})),n.d(e,"d",(function(){return r.d})),n.d(e,"a",(function(){return r.a})),n.d(e,"b",(function(){return r.b})),n.d(e,"e",(function(){return i.a})),n.d(e,"f",(function(){return a.a})),n.d(e,"g",(function(){return f}));var r=n(291),i=n(366),a=n(425),u=n(0),o=n(12),c=n(17),s=n(24),f=function(t){var e=t.entity,n=t.entityId,r=Object(a.a)(),i=(0,Object(s.useRelations)().getRelations)({entity:e,entityId:n,relation:"prices"}),f=Object(c.entityListCacheIdString)(r),l=JSON.stringify(i);return Object(u.useMemo)((function(){return Object(o.entitiesWithGuIdInArray)(r,i)}),[l,f])}},,,function(t,e,n){"use strict";n.r(e),n.d(e,"UPDATE_EVENT",(function(){return f}));var r=n(49),i=n(18),a=n(424),u=n(1337);n.d(e,"useEventMutator",(function(){return u.a}));var o,c=n(990);for(var s in c)["default","UPDATE_EVENT","useEventMutator"].indexOf(s)<0&&function(t){n.d(e,t,(function(){return c[t]}))}(s);var f=Object(i.gql)(o||(o=Object(r.a)(["\n\tmutation UPDATE_EVENT($input: UpdateEspressoEventInput!) {\n\t\tupdateEspressoEvent(input: $input) {\n\t\t\tespressoEvent {\n\t\t\t\t...eventAttributes\n\t\t\t}\n\t\t}\n\t}\n\t","\n"])),a.a)},function(t,e,n){"use strict";var r;n.d(e,"a",(function(){return r})),function(t){t.start="start",t.end="end",t.both="both"}(r||(r={}))},,,,,,,,,,,,,,,,,,,,,,,,,function(t,e,n){"use strict";var r=n(2),i=n(0),a=n(291),u=n(275);e.a=function(t){var e=Object(u.a)();return Object(i.useMemo)((function(){return{query:a.b,variables:{where:Object(r.a)({eventId:e,includeDefaultTicketsPrices:!0,includeDefaultPrices:!0},t)}}}),[e,t])}},function(t,e,n){"use strict";var r=n(2),i=n(31),a=n(0),u=n(4),o=n(12),c=n(265);e.a=function(){var t=Object(c.a)();return Object(a.useCallback)((function(e){var n,a=e.cache,c=e.tickets,s=e.ticket,f=e.action,l=c.nodes,d=void 0===l?[]:l,p=[];switch(f){case"add":p=[].concat(Object(i.a)(d),[s]);break;case"update":(n=Object(u.findIndex)(Object(o.entityHasGuid)(s.id),d))>=0&&(p=Object(u.update)(n,s,d));break;case"remove":p=d.filter((function(t){return t.id!==s.id}));break;default:p=d}var v=Object(r.a)(Object(r.a)({},t),{},{data:{espressoTickets:Object(r.a)(Object(r.a)({},c),{},{nodes:p})}});a.writeQuery(v)}),[t])}},function(t,e,n){"use strict";var r,i=n(43),a=n(49),u=n(34),o=n.n(u),c=n(0),s=n(18),f=Object(s.gql)(r||(r=Object(a.a)(["\n\tmutation BULK_DELETE_ENTITIES($input: BulkDeleteEspressoEntitiesInput!) {\n\t\tbulkDeleteEspressoEntities(input: $input) {\n\t\t\tdeleted\n\t\t\tfailed\n\t\t}\n\t}\n"])));e.a=function(t){var e=t.entityType,n=t.typeName,r=Object(s.useMutationWithFeedback)({typeName:n,mutationType:s.MutationType.Delete,mutation:f});return Object(c.useCallback)(function(){var t=Object(i.a)(o.a.mark((function t(n){var i,a,u;return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return i=n.entityIds,a=n.deletePermanently,u=n.updateEntityList,t.next=3,r({variables:{input:{clientMutationId:"BULK_DELETE_ENTITIES",entityIds:i,entityType:e,deletePermanently:a}},update:u});case 3:return t.abrupt("return",t.sent);case 4:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),[r,e])}},,,,,,,,,,,,,,,,function(t,e,n){var r=n(981);t.exports=function(t){return function e(n){return 0===arguments.length||r(n)?e:t.apply(this,arguments)}}},function(t,e,n){"use strict";n.r(e),n.d(e,"mutations",(function(){return l}));var r=n(192),i=n(340),a=n(177),u=n(231);for(var o in r)["default","mutations","useUpdateCallback"].indexOf(o)<0&&function(t){n.d(e,t,(function(){return r[t]}))}(o);for(var o in i)["default","mutations","useUpdateCallback"].indexOf(o)<0&&function(t){n.d(e,t,(function(){return i[t]}))}(o);for(var o in a)["default","mutations","useUpdateCallback"].indexOf(o)<0&&function(t){n.d(e,t,(function(){return a[t]}))}(o);for(var o in u)["default","mutations","useUpdateCallback"].indexOf(o)<0&&function(t){n.d(e,t,(function(){return u[t]}))}(o);var c=n(216);n.d(e,"formToBulkUpdateInput",(function(){return c.c})),n.d(e,"cacheNodesFromBulkInput",(function(){return c.b})),n.d(e,"cacheNodesFromBulkDelete",(function(){return c.a})),n.d(e,"updateDatetimeFlags",(function(){return c.d})),n.d(e,"updateTicketFlags",(function(){return c.e}));var s=n(254);n.d(e,"TypeName",(function(){return s.a}));var f=n(276);n.d(e,"useUpdateCallback",(function(){return f.a}));var l={CREATE_DATETIME:r.CREATE_DATETIME,UPDATE_DATETIME:r.UPDATE_DATETIME,DELETE_DATETIME:r.DELETE_DATETIME,UPDATE_EVENT:i.UPDATE_EVENT,CREATE_TICKET:a.CREATE_TICKET,UPDATE_TICKET:a.UPDATE_TICKET,DELETE_TICKET:a.DELETE_TICKET,CREATE_PRICE:u.CREATE_PRICE,UPDATE_PRICE:u.UPDATE_PRICE,DELETE_PRICE:u.DELETE_PRICE}},function(t,e,n){var r=n(387),i=n(392),a=n(132),u=n(393),o=n(301),c=n(244);t.exports=function(t,e,n){for(var s=-1,f=(e=r(e,t)).length,l=!1;++s-1&&t%1==0&&tf))return!1;var d=c.get(t),p=c.get(e);if(d&&p)return d==e&&p==t;var v=-1,b=!0,h=2&n?new r:void 0;for(c.set(t,e),c.set(e,t);++v0&&void 0!==arguments[0]?arguments[0]:void 0,e=Object(u.a)(),n=Object(i.useMemo)((function(){return Object(r.a)(Object(r.a)({},e),t)}),[e,t]);return Object(a.a)(n)}},function(t,e,n){"use strict";var r=n(2),i=n(0),a=n(187),u=n(265);e.a=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:void 0,e=Object(u.a)(),n=Object(i.useMemo)((function(){return Object(r.a)(Object(r.a)({},e),t)}),[e,t]);return Object(a.a)(n)}},,,,,,,,,,,,,,,,function(t,e,n){"use strict";var r=n(424);n.d(e,"a",(function(){return r.a})),n.d(e,"b",(function(){return r.b}));var i=n(980);n.d(e,"c",(function(){return i.a}));var a=n(554);n.d(e,"e",(function(){return a.a}));var u=n(275);n.d(e,"d",(function(){return u.a}))},,,,,,,,,,,,,,,,,function(t,e,n){"use strict";n.d(e,"c",(function(){return r.c})),n.d(e,"a",(function(){return r.a})),n.d(e,"b",(function(){return r.b})),n.d(e,"f",(function(){return u})),n.d(e,"e",(function(){return c})),n.d(e,"g",(function(){return s.a})),n.d(e,"h",(function(){return f.a})),n.d(e,"i",(function(){return l})),n.d(e,"j",(function(){return v})),n.d(e,"k",(function(){return y})),n.d(e,"l",(function(){return O.a})),n.d(e,"m",(function(){return a.a})),n.d(e,"d",(function(){return E}));var r=n(194),i=n(12),a=n(179),u=function(){return Object(a.a)(i.isDefault)},o=n(26),c=function(){var t=u();return Object(o.useMemoStringify)(Object(i.getGuids)(t))},s=n(772),f=n(773),l=function(){var t=Object(a.a)();return Object(o.useMemoStringify)(Object(i.getGuids)(t))},d=n(0),p=n(18),v=function(t){var e=t.id,n=Object(d.useMemo)((function(){return{query:r.a,variables:{id:e},returnPartialData:!0}}),[e]),i=Object(p.useCacheQuery)(n).data;return Object(o.useMemoStringify)(null===i||void 0===i?void 0:i.espressoTicket)},b=n(24),h=n(425),y=function(){var t=Object(h.a)(),e=Object(b.useRelations)().getRelations;return Object(d.useCallback)((function(n){var r=e({entity:"tickets",entityId:n,relation:"prices"});return Object(i.entitiesWithGuIdInArray)(t,r)}),[e,t])},O=n(265),j=n(4),m=n(230),E=function(){var t=Object(m.a)(),e=Object(b.useRelations)().getRelations;return Object(d.useCallback)((function(n){var r=n.capacity,a=n.quantity,u=n.ticketId,o=n.relatedDateIds,c=void 0===o?[]:o,s=(null===c||void 0===c?void 0:c.length)?c:e({entity:"tickets",entityId:u,relation:"datetimes"}),f=j.isNil(r)?Object(i.minDateCapacity)(t)(s):r;return Object(i.ticketQuantityFromCapacity)(f)(a)}),[t,e])}},function(t,e,n){"use strict";n.d(e,"c",(function(){return r.c})),n.d(e,"a",(function(){return r.a})),n.d(e,"b",(function(){return r.b})),n.d(e,"g",(function(){return c})),n.d(e,"d",(function(){return s})),n.d(e,"e",(function(){return p})),n.d(e,"f",(function(){return u.a}));var r=n(575),i=n(18),a=n(26),u=n(426),o=n(12),c=function(){var t,e=Object(u.a)(),n=Object(i.useCacheQuery)(e).data,r=(null===n||void 0===n||null===(t=n.espressoPriceTypes)||void 0===t?void 0:t.nodes)||[],c=Object(o.getCacheIds)(r);return Object(a.useMemoStringify)(r,c)},s=function(){var t=c(),e=Object(o.getDefaultPriceModifierType)(t);return Object(a.useMemoStringify)(e)},f=n(1429),l=n.n(f),d=n(24),p=function(t){var e=(0,Object(d.useRelations)().getRelations)({entity:"prices",entityId:t,relation:"priceTypes"}),n=s(),r=c(),i=Object(o.entitiesWithGuIdInArray)(r,e),u=l()(i)?n:i[0];return Object(a.useMemoStringify)(u)}},,,,,,,,function(t,e,n){"use strict";var r=n(43),i=n(34),a=n.n(i),u=n(0),o=n(24),c=n(776);e.a=function(){var t=Object(o.useRelations)().getRelations,e=Object(c.a)();return Object(u.useCallback)(function(){var n=Object(r.a)(a.a.mark((function n(r,i){var u,o;return a.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:if(u=t({entity:"datetimes",entityId:r,relation:"tickets"}),!(o=u.filter((function(e){return 1===t({entity:"tickets",entityId:e,relation:"datetimes"}).length}))).length){n.next=5;break}return n.next=5,e({entityIds:o,deletePermanently:i,deleteRemotely:!1,relatedDatetimeIds:[r]});case 5:case"end":return n.stop()}}),n)})));return function(t,e){return n.apply(this,arguments)}}(),[e,t])}},function(t,e,n){"use strict";n.d(e,"a",(function(){return i}));var r=n(138),i=Object(r.getHooks)()},function(t,e,n){"use strict";var r=n(8),i=n(2),a=n(0),u=n(4),o=n(18),c=n(179),s=n(265),f=n(450),l=n(177),d=n(75),p=n(216),v=n(583),b=n(584);e.a=function(){var t=Object(c.a)(u.identity),e=Object(s.a)(),n=Object(f.a)(),h=Object(v.a)(),y=Object(b.a)(),O=Object(o.useMutationWithFeedback)({typeName:d.a.TICKET,mutationType:o.MutationType.Update,mutation:l.BULK_UPDATE_TICKETS}),j=Object(a.useCallback)((function(a){return function(){var u={nodes:Object(p.b)(a,t).map(p.e),__typename:"EspressoRootQueryTicketsConnection"};n(Object(i.a)(Object(i.a)({},e),{},{data:{espressoTickets:u}})),a.uniqueInputs.forEach((function(t){var e=t.datetimes,n=t.prices,i=Object(r.a)(t,["datetimes","prices"]);h({ticket:i,datetimeIds:e,priceIds:n})}))}}),[t,h,e,n]),m=Object(a.useCallback)((function(t){var e={input:Object(i.a)({clientMutationId:"BULK_UPDATE_TICKETS"},t)},n=Object(u.unnest)(t.uniqueInputs.map((function(t){return y({input:t})}))).filter(Boolean);return O({variables:e,update:j(t),refetchQueries:n})}),[O,j,y]);return Object(a.useMemo)((function(){return{updateEntities:m}}),[m])}},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(t,e,n){"use strict";var r=n(0),i=function(){var t,e,n,r;return(null===(t=window)||void 0===t||null===(e=t.eventEspressoData)||void 0===e||null===(n=e.eventEditor)||void 0===n||null===(r=n.event)||void 0===r?void 0:r.id)||""},a=n(424);e.a=function(){var t=i();return Object(r.useMemo)((function(){return{query:a.b,variables:{id:t}}}),[t])}},,,,,,,,,,,,,,,,,,,,,function(t,e,n){"use strict";n.d(e,"c",(function(){return c})),n.d(e,"a",(function(){return s})),n.d(e,"b",(function(){return f}));var r,i,a,u=n(49),o=n(18),c=Object(o.gql)(r||(r=Object(u.a)(["\n\tfragment priceTypeAttributes on EspressoPriceType {\n\t\tid\n\t\tdbId\n\t\tbaseType\n\t\tcacheId\n\t\tisBasePrice\n\t\tisDiscount\n\t\tisPercent\n\t\tisTax\n\t\tisTrashed\n\t\tname\n\t\torder\n\t}\n"]))),s=Object(o.gql)(i||(i=Object(u.a)(["\n\tquery GET_PRICE_TYPE($id: ID!) {\n\t\tpriceType(id: $id) {\n\t\t\t...priceTypeAttributes\n\t\t}\n\t}\n\t","\n"])),c),f=Object(o.gql)(a||(a=Object(u.a)(["\n\tquery GET_PRICE_TYPES {\n\t\tespressoPriceTypes {\n\t\t\tnodes {\n\t\t\t\t...priceTypeAttributes\n\t\t\t}\n\t\t}\n\t}\n\t","\n"])),c)},function(t,e,n){"use strict";var r=n(2),i=n(31),a=n(0),u=n(4),o=n(12),c=n(264);e.a=function(){var t=Object(c.a)();return Object(a.useCallback)((function(e){var n,a=e.cache,c=e.datetimes,s=e.datetime,f=e.action,l=c.nodes,d=void 0===l?[]:l,p=[];switch(f){case"add":p=[].concat(Object(i.a)(d),[s]);break;case"update":(n=Object(u.findIndex)(Object(o.entityHasGuid)(s.id),d))>=0&&(p=Object(u.update)(n,s,d));break;case"remove":p=d.filter((function(t){return t.id!==s.id}));break;default:p=d}var v=Object(r.a)(Object(r.a)({},t),{},{data:{espressoDatetimes:Object(r.a)(Object(r.a)({},c),{},{nodes:p})}});a.writeQuery(v)}),[t])}},function(t,e,n){"use strict";var r=n(31),i=n(194),a=n(4);e.a=function(t){var e,n,u=t.cache,o=t.datetimeIn,c=t.datetimeId,s=t.action,f={query:i.b,variables:{where:{datetimeIn:Object(a.sortBy)(a.identity,o)}}};try{n=u.readQuery(f)}catch(p){n=null}if(null===(e=n)||void 0===e?void 0:e.espressoTickets){var l;switch(s){case"add":l=[].concat(Object(r.a)(o),[c]);break;case"remove":l=o.filter((function(t){return t!==c}));break;default:l=o}var d={query:i.b,data:n,variables:{where:{datetimeIn:Object(a.sortBy)(a.identity,l)}}};u.writeQuery(d)}}},function(t,e,n){"use strict";var r=n(0),i=n(24),a=n(12);e.a=function(){var t=Object(i.useRelations)(),e=t.addRelation,n=t.removeRelation,u=t.updateRelations;return Object(r.useCallback)((function(t){var r=t.datetime,i=t.tickets;if(!Object(a.hasTempId)(r)){var o=null===r||void 0===r?void 0:r.id;i&&(n({entity:"datetimes",entityId:o,relation:"tickets"}),i.length&&(u({entity:"datetimes",entityId:o,relation:"tickets",relationIds:i}),i.forEach((function(t){e({entity:"tickets",entityId:t,relation:"datetimes",relationId:o})}))))}}),[e,n,u])}},function(t,e,n){"use strict";var r=n(2),i=n(0),a=n(577),u=n(576),o=n(24),c=n(12);e.a=function(){var t=Object(o.useRelations)(),e=t.dropRelations,n=t.removeRelation,s=Object(u.a)();return Object(i.useCallback)((function(t){var i=t.cache,u=t.datetimes,o=t.datetime,f=t.deletePermanently,l=f?"remove":"update";if(!Object(c.hasTempId)(o)&&f){var d=u.nodes,p=void 0===d?[]:d,v=Object(c.getGuids)(p),b=o.id;Object(a.a)({cache:i,datetimeIn:v,datetimeId:b,action:l}),n({entity:"datetimes",entityId:b,relation:"tickets"}),e({entity:"datetimes",entityId:b})}s({cache:i,datetimes:u,datetime:Object(r.a)(Object(r.a)({},o),{},{isTrashed:!0}),action:l})}),[e,n,s])}},function(t,e,n){"use strict";var r=n(2),i=n(0),a=n(24),u=n(12),o=n(581),c=n(367);e.a=function(){var t=Object(a.useRelations)(),e=t.dropRelations,n=t.removeRelation,s=Object(c.a)();return Object(i.useCallback)((function(t){var i=t.cache,a=t.tickets,c=t.ticket,f=t.deletePermanently,l=f?"remove":"update";if(!Object(u.hasTempId)(c)&&f){var d=a.nodes,p=void 0===d?[]:d,v=Object(u.getGuids)(p),b=c.id;Object(o.a)({cache:i,ticketIn:v,ticketId:b,action:l}),n({entity:"tickets",entityId:b,relation:"datetimes"}),n({entity:"tickets",entityId:b,relation:"prices"}),e({entity:"tickets",entityId:b})}s({cache:i,tickets:a,ticket:Object(r.a)(Object(r.a)({},c),{},{isTrashed:!0}),action:l})}),[e,n,s])}},function(t,e,n){"use strict";var r=n(31),i=n(4),a=n(291),u=n(79),o=n(12);e.a=function(t){var e,n,c,s=t.cache,f=t.prices,l=void 0===f?null:f,d=t.ticketIn,p=t.ticketId,v=t.action,b={query:a.b,variables:{where:{ticketIn:Object(i.sortBy)(i.identity,d),includeDefaultPrices:!0}}};try{n=s.readQuery(b)}catch(E){}switch((null===(e=n)||void 0===e?void 0:e.espressoPrices)||(n={espressoPrices:u.DEFAULT_PRICE_LIST_DATA}),v){case"add":c=[].concat(Object(r.a)(d),[p]);break;case"remove":c=d.filter((function(t){return t!==p}));break;default:c=d}var h=(null===l||void 0===l?void 0:l.nodes)||[],y=["espressoPrices","nodes"];if("add"===v&&h.length){var O=Object(i.pathOr)([],y,n),j=Object(i.uniqBy)(o.entityDbId,[].concat(Object(r.a)(O),Object(r.a)(h)));n=Object(i.assocPath)(y,j,n)}if(Object(i.pathOr)([],y,n).length){var m={query:a.b,data:n,variables:{where:{ticketIn:Object(i.sortBy)(i.identity,c),includeDefaultPrices:!0}}};s.writeQuery(m)}}},function(t,e,n){"use strict";n.d(e,"a",(function(){return O}));var r,i=n(31),a=n(2),u=n(43),o=n(9),c=n(49),s=n(34),f=n.n(s),l=n(0),d=n(4),p=n(3),v=n(18),b=n(175),h=n(12),y=Object(v.gql)(r||(r=Object(c.a)(["\n\tmutation REORDER_ENTITIES($input: ReorderEspressoEntitiesInput!) {\n\t\treorderEspressoEntities(input: $input) {\n\t\t\tok\n\t\t}\n\t}\n"]))),O=function(t){var e=t.entityType,n=t.filteredEntities,r=Object(b.useSystemNotifications)(),c=Object(l.useState)([]),s=Object(o.a)(c,2),O=s[0],j=s[1],m=Object(l.useState)(n),E=Object(o.a)(m,2),T=E[0],g=E[1],_=Object(v.useMutation)(y),k=Object(o.a)(_,2),D=k[0],I=k[1],x=Object(l.useCallback)(Object(u.a)(f.a.mark((function t(){return f.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,D({variables:{input:{clientMutationId:"REORDER_ENTITIES",entityIds:O,entityType:e}}});case 2:return r.success({message:Object(p.__)("order updated")}),t.abrupt("return",!0);case 4:case"end":return t.stop()}}),t)}))),[O,e,D,r]);Object(l.useEffect)((function(){g(n)}),[n]);var w=Object(l.useCallback)((function(t){var e=t.allEntities,n=t.newIndex,r=t.oldIndex;if(!(n===r||n<0||r<0)){var u=Object(d.clone)(T.map((function(t){return t.id}))),c=Object(d.clone)(e),s=u.splice(r,1),f=Object(o.a)(s,1)[0];u.splice(n,0,f);var l=u.map((function(t,e){var n=c.findIndex((function(e){return e.id===t})),r=c.splice(n,1),i=Object(o.a)(r,1)[0];return Object(a.a)(Object(a.a)({},i),{},{order:e+1})}));return(c=[].concat(Object(i.a)(l),Object(i.a)(c))).map((function(t,e){return Object(a.a)(Object(a.a)({},t),{},{order:e+1})})),g(l),j(Object(h.getGuids)(c)),c}}),[T]);return Object(l.useMemo)((function(){return{allReorderedEntities:T,updateSortOrder:x,result:I,sortEntities:w}}),[T,x,I,w])}},function(t,e,n){"use strict";var r=n(0),i=n(24),a=n(12),u=n(367);e.a=function(){var t=Object(i.useRelations)(),e=t.addRelation,n=t.removeRelation,o=t.updateRelations,c=Object(u.a)();return Object(r.useCallback)((function(t){var r=t.cache,i=t.tickets,u=t.ticket,s=t.datetimeIds,f=t.priceIds;if(!Object(a.hasTempId)(u)){var l=u.id;s&&(n({entity:"tickets",entityId:l,relation:"datetimes"}),s.length&&(o({entity:"tickets",entityId:l,relation:"datetimes",relationIds:s}),s.forEach((function(t){e({entity:"datetimes",entityId:t,relation:"tickets",relationId:l})})))),f&&(n({entity:"tickets",entityId:l,relation:"prices"}),f.length&&(o({entity:"tickets",entityId:l,relation:"prices",relationIds:f}),f.forEach((function(t){e({entity:"prices",entityId:t,relation:"tickets",relationId:l})})))),r&&i&&c({cache:r,tickets:i,ticket:u,action:"update"})}}),[e,n,o,c])}},function(t,e,n){"use strict";var r=n(0),i=n(4),a=n(24),u=n(18),o=n(215);e.a=function(){var t=Object(a.useRelations)().getRelations;return Object(r.useCallback)((function(e){var n=e.input,r=e.mutationType,a=void 0===r?u.MutationType.Update:r;if(n.id&&n.datetimes||a===u.MutationType.Delete){var c=t({entity:"tickets",entityId:n.id,relation:"datetimes"});return i.difference(i.union(c,n.datetimes||[]),i.intersection(c,n.datetimes||[])).map((function(t){return{query:o.b,variables:{id:t}}}))}}),[t])}},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(t,e){t.exports=function(t,e){return Object.prototype.hasOwnProperty.call(e,t)}},function(t,e){var n=Object.prototype.hasOwnProperty;t.exports=function(t,e){return null!=t&&n.call(t,e)}},function(t,e,n){var r=n(239),i=Object.prototype,a=i.hasOwnProperty,u=i.toString,o=r?r.toStringTag:void 0;t.exports=function(t){var e=a.call(t,o),n=t[o];try{t[o]=void 0;var r=!0}catch(c){}var i=u.call(t);return r&&(e?t[o]=n:delete t[o]),i}},function(t,e){var n=Object.prototype.toString;t.exports=function(t){return n.call(t)}},function(t,e,n){var r=n(637),i=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,a=/\\(\\)?/g,u=r((function(t){var e=[];return 46===t.charCodeAt(0)&&e.push(""),t.replace(i,(function(t,n,r,i){e.push(r?i.replace(a,"$1"):n||t)})),e}));t.exports=u},function(t,e,n){var r=n(638);t.exports=function(t){var e=r(t,(function(t){return 500===n.size&&n.clear(),t})),n=e.cache;return e}},function(t,e,n){var r=n(298);function i(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new TypeError("Expected a function");var n=function n(){var r=arguments,i=e?e.apply(this,r):r[0],a=n.cache;if(a.has(i))return a.get(i);var u=t.apply(this,r);return n.cache=a.set(i,u)||a,u};return n.cache=new(i.Cache||r),n}i.Cache=r,t.exports=i},function(t,e,n){var r=n(640),i=n(241),a=n(300);t.exports=function(){this.size=0,this.__data__={hash:new r,map:new(a||i),string:new r}}},function(t,e,n){var r=n(641),i=n(646),a=n(647),u=n(648),o=n(649);function c(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e-1}},function(t,e,n){var r=n(242);t.exports=function(t,e){var n=this.__data__,i=r(n,t);return i<0?(++this.size,n.push([t,e])):n[i][1]=e,this}},function(t,e,n){var r=n(243);t.exports=function(t){var e=r(this,t).delete(t);return this.size-=e?1:0,e}},function(t,e){t.exports=function(t){var e=typeof t;return"string"==e||"number"==e||"symbol"==e||"boolean"==e?"__proto__"!==t:null===t}},function(t,e,n){var r=n(243);t.exports=function(t){return r(this,t).get(t)}},function(t,e,n){var r=n(243);t.exports=function(t){return r(this,t).has(t)}},function(t,e,n){var r=n(243);t.exports=function(t,e){var n=r(this,t),i=n.size;return n.set(t,e),this.size+=n.size==i?0:1,this}},function(t,e,n){var r=n(239),i=n(661),a=n(132),u=n(297),o=r?r.prototype:void 0,c=o?o.toString:void 0;t.exports=function t(e){if("string"==typeof e)return e;if(a(e))return i(e,t)+"";if(u(e))return c?c.call(e):"";var n=e+"";return"0"==n&&1/e==-Infinity?"-0":n}},function(t,e){t.exports=function(t,e){for(var n=-1,r=null==t?0:t.length,i=Array(r);++n=i?t:r(t,e,n)}},function(t,e){t.exports=function(t,e,n){var r=-1,i=t.length;e<0&&(e=-e>i?0:i+e),(n=n>i?i:n)<0&&(n+=i),i=e>n?0:n-e>>>0,e>>>=0;for(var a=Array(i);++r0&&void 0!==arguments[0]?arguments[0]:void 0,e=Object(a.a)(),n=Object(u.useMemo)((function(){return Object(r.a)(Object(r.a)({},e),t)}),[e,t]);return Object(i.a)(n)}},function(t,e,n){"use strict";var r=n(43),i=n(80),a=n(2),u=n(34),o=n.n(u),c=n(0),s=n(4),f=n(18),l=n(12),d=n(179),p=n(265),v=n(79),b=n(450),h=n(368),y=n(216),O=n(75),j=n(580);e.a=function(){var t=Object(d.a)(),e=Object(p.a)(),n=Object(b.a)(),u=Object(j.a)(),m=Object(f.useApolloClient)().cache,E=Object(h.a)({entityType:"TICKET",typeName:O.a.TICKET}),T=Object(c.useCallback)((function(r){var o=r.entityIds,c=r.deletePermanently,f=r.relatedDatetimeIds;return function(){var r,d;try{d=m.readQuery(e)}catch(I){d=null}var p,b,h=(null===(r=d)||void 0===r?void 0:r.espressoTickets)||v.DEFAULT_TICKET_LIST_DATA,O=Object(l.findEntityByGuid)(h.nodes),j=Object(a.a)({},h),E=Object(i.a)(o);try{for(E.s();!(b=E.n()).done;){var T=b.value;p=O(T),u({cache:m,tickets:j,ticket:p,deletePermanently:c}),j.nodes=Object(l.entitiesWithGuIdNotInArray)(j.nodes,[T])}}catch(x){E.e(x)}finally{E.f()}var g,_=Object(y.a)(o,t,c);if(f.length){var k=["variables","where","datetimeIn"],D=Object(s.pathOr)([],k,e).filter((function(t){return!f.includes(t)}));g=Object(s.assocPath)(k,D,e)}n(Object(a.a)(Object(a.a)(Object(a.a)({},e),g),{},{data:{espressoTickets:Object(a.a)(Object(a.a)({},h),{},{nodes:_})}}))}}),[t,m,u,e,n]);return Object(c.useCallback)(function(){var t=Object(r.a)(o.a.mark((function t(e){var n,r,i,a,u,c;return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(n=e.entityIds,r=e.deletePermanently,i=e.deleteRemotely,a=void 0===i||i,u=e.relatedDatetimeIds,c=T({entityIds:n,deletePermanently:r,relatedDatetimeIds:void 0===u?[]:u}),!a){t.next=6;break}return t.next=5,E({entityIds:n,deletePermanently:r,updateEntityList:c});case 5:return t.abrupt("return",t.sent);case 6:c();case 7:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),[E,T])}},function(t,e,n){"use strict";var r=n(0),i=n(63),a=n.n(i),u=n(428);e.a=function(){var t=Object(r.useContext)(u.b);return a()(t,"useDatesListFilterState must be used inside component"),t}},function(t,e,n){"use strict";n.d(e,"a",(function(){return a}));var r=n(18),i=Object(r.makeVar)([]),a=function(){return Object(r.useReactiveVariable)(i)}},function(t,e,n){"use strict";var r=n(0),i=n(63),a=n.n(i),u=n(430);e.a=function(){var t=Object(r.useContext)(u.b);return a()(t,"useTicketsListFilterState must be used inside component"),t}},function(t,e,n){"use strict";n.d(e,"a",(function(){return a}));var r=n(18),i=Object(r.makeVar)([]),a=function(){return Object(r.useReactiveVariable)(i)}},,,,,,,,,,,,,,,,,,,,,,function(t,e,n){"use strict";var r=n(2),i=n(9),a=n(0),u=n(24),o=n(12),c=n(259),s=n(341),f=n(75),l=function(t,e){var n=e.displayStartOrEndDate,i=e.sales,a=e.status,u=e.recurrence;switch(e.type){case"SET_DISPLAY_START_OR_END_DATE":return Object(r.a)(Object(r.a)({},t),{},{displayStartOrEndDate:n});case"SET_SALES":return Object(r.a)(Object(r.a)({},t),{},{sales:i});case"SET_STATUS":return Object(r.a)(Object(r.a)({},t),{},{status:a});case"SET_RECURRENCE":return Object(r.a)(Object(r.a)({},t),{},{recurrence:u});default:throw new Error("Unknown action")}},d={displayStartOrEndDate:s.a.start,sales:o.DatetimeSales.all,status:o.DatetimeStatus.activeUpcoming,recurrence:""};e.a=function(){var t=Object(c.useSessionStorageReducer)("dates-list-filter-state",l,d),e=Object(i.a)(t,2),n=e[0],o=e[1],s=Object(u.useEntityListFilterStateManager)("order",f.c),p=s.setPageNumber,v=Object(a.useCallback)((function(t,e){e!==n[t]&&p(1)}),[p,n]),b=Object(a.useCallback)((function(t){o({type:"SET_DISPLAY_START_OR_END_DATE",displayStartOrEndDate:t})}),[o]),h=Object(a.useCallback)((function(t){v("sales",t),o({type:"SET_SALES",sales:t})}),[o,v]),y=Object(a.useCallback)((function(t){v("status",t),o({type:"SET_STATUS",status:t})}),[o,v]),O=Object(a.useCallback)((function(t){v("recurrence",t),o({type:"SET_RECURRENCE",recurrence:t})}),[o,v]);return Object(a.useMemo)((function(){return Object(r.a)(Object(r.a)(Object(r.a)({},n),s),{},{setDisplayStartOrEndDate:b,setSales:h,setStatus:y,setRecurrence:O})}),[n,s,b,h,y,O])}},function(t,e,n){"use strict";var r=n(2),i=n(9),a=n(0),u=n(341),o=n(75),c=n(24),s=n(778),f=n(259),l=n(12),d=function(t,e){var n=e.displayStartOrEndDate,i=e.sales,a=e.status;switch(e.type){case"SET_DISPLAY_START_OR_END_DATE":return Object(r.a)(Object(r.a)({},t),{},{displayStartOrEndDate:n});case"SET_SALES":return Object(r.a)(Object(r.a)({},t),{},{sales:i});case"SET_STATUS":return Object(r.a)(Object(r.a)({},t),{},{status:a});case"TOGGLE_IS_CHAINED":return Object(r.a)(Object(r.a)({},t),{},{isChained:!t.isChained});default:throw new Error("Unknown action")}},p={displayStartOrEndDate:u.a.start,isChained:!0,sales:l.TicketsSales.all,status:l.TicketsStatus.onSaleAndPending};e.a=function(){var t=Object(f.useSessionStorageReducer)("ticket-list-filter-state",d,p),e=Object(i.a)(t,2),n=e[0],u=e[1],l=Object(a.useState)(""),v=Object(i.a)(l,2),b=v[0],h=v[1],y=Object(s.a)(),O=Object(i.a)(y,1)[0],j=Object(c.useEntityListFilterStateManager)("order",o.e),m=j.setPageNumber;Object(a.useEffect)((function(){n.isChained&&h(O.join(":"))}),[n.isChained,O]);var E=Object(a.useCallback)((function(t,e){e!==n[t]&&m(1)}),[m,n]),T=Object(a.useCallback)((function(t){u({type:"SET_DISPLAY_START_OR_END_DATE",displayStartOrEndDate:t})}),[u]),g=Object(a.useCallback)((function(t){E("sales",t),u({type:"SET_SALES",sales:t})}),[u,E]),_=Object(a.useCallback)((function(t){E("status",t),u({type:"SET_STATUS",status:t})}),[u,E]),k=Object(a.useCallback)((function(){u({type:"TOGGLE_IS_CHAINED"})}),[u]);return Object(a.useMemo)((function(){return Object(r.a)(Object(r.a)(Object(r.a)({},n),j),{},{setDisplayStartOrEndDate:T,setSales:g,setStatus:_,toggleIsChained:k,visibleDatesStr:b})}),[j,b,T,g,k,n,_])}},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(t,e,n){"use strict";var r=n(18),i=n(554),a=n(26);e.a=function(){var t=Object(i.a)(),e=Object(r.useCacheQuery)(t).data;return Object(a.useMemoStringify)(null===e||void 0===e?void 0:e.espressoEvent)}},function(t,e){t.exports=function(t){return null!=t&&"object"===typeof t&&!0===t["@@functional/placeholder"]}},function(t,e,n){var r=n(632),i=Object.prototype.toString,a=function(){return"[object Arguments]"===i.call(arguments)?function(t){return"[object Arguments]"===i.call(t)}:function(t){return r("callee",t)}}();t.exports=a},function(t,e){},function(t,e,n){"use strict";var r=n(2),i=n(0),a=n(187),u=n(426);e.a=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:void 0,e=Object(u.a)(),n=Object(i.useMemo)((function(){return Object(r.a)(Object(r.a)({},e),t)}),[e,t]);return Object(a.a)(n)}},function(t,e,n){"use strict";var r=n(2),i=n(0),a=n(187),u=n(427);e.a=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:void 0,e=Object(u.a)(),n=Object(i.useMemo)((function(){return Object(r.a)(Object(r.a)({},e),t)}),[e,t]);return Object(a.a)(n)}},function(t,e,n){"use strict";var r=n(8),i=n(2),a=n(0),u=n(18),o=n(230),c=n(264),s=n(192),f=n(578),l=n(449),d=n(216),p=n(75);e.a=function(){var t=Object(o.a)(),e=Object(c.a)(),n=Object(l.a)(),v=Object(f.a)(),b=Object(u.useMutationWithFeedback)({typeName:p.a.DATETIME,mutationType:u.MutationType.Update,mutation:s.BULK_UPDATE_DATETIMES}),h=Object(a.useCallback)((function(a){return function(){var u={nodes:Object(d.b)(a,t).map(d.d),__typename:"EspressoRootQueryDatetimesConnection"};n(Object(i.a)(Object(i.a)({},e),{},{data:{espressoDatetimes:u}})),a.uniqueInputs.forEach((function(t){var e=t.tickets,n=Object(r.a)(t,["tickets"]);v({datetime:n,tickets:e})}))}}),[t,v,e,n]),y=Object(a.useCallback)((function(t){var e={input:Object(i.a)({clientMutationId:"BULK_UPDATE_DATETIMES"},t)};return b({variables:e,update:h(t)})}),[b,h]);return Object(a.useMemo)((function(){return{updateEntities:y}}),[y])}},function(t,e,n){"use strict";var r=n(2),i=n(80),a=n(43),u=n(34),o=n.n(u),c=n(0),s=n(18),f=n(12),l=n(230),d=n(264),p=n(79),v=n(449),b=n(368),h=n(216),y=n(579),O=n(492),j=n(75);e.a=function(){var t=Object(l.a)(),e=Object(d.a)(),n=Object(v.a)(),u=Object(y.a)(),m=Object(s.useApolloClient)().cache,E=Object(b.a)({entityType:"DATETIME",typeName:j.a.DATETIME}),T=Object(O.a)(),g=Object(c.useCallback)((function(c,s){return Object(a.a)(o.a.mark((function a(){var l,d,v,b,y,O,j,E,g,_,k,D,I,x;return o.a.wrap((function(a){for(;;)switch(a.prev=a.next){case 0:d=Object(i.a)(c),a.prev=1,d.s();case 3:if((v=d.n()).done){a.next=9;break}return b=v.value,a.next=7,T(b,s);case 7:a.next=3;break;case 9:a.next=14;break;case 11:a.prev=11,a.t0=a.catch(1),d.e(a.t0);case 14:return a.prev=14,d.f(),a.finish(14);case 17:try{y=m.readQuery(e)}catch(o){y=null}O=(null===(l=y)||void 0===l?void 0:l.espressoDatetimes)||p.DEFAULT_DATETIME_LIST_DATA,j=Object(f.findEntityByGuid)(O.nodes),E=Object(r.a)({},O),_=Object(i.a)(c);try{for(_.s();!(k=_.n()).done;)D=k.value,g=j(D),u({cache:m,datetimes:E,datetime:g,deletePermanently:s}),E.nodes=Object(f.entitiesWithGuIdNotInArray)(E.nodes,[D])}catch(w){_.e(w)}finally{_.f()}I=Object(h.a)(c,t,s),x={nodes:I,__typename:"EspressoRootQueryDatetimesConnection"},n(Object(r.a)(Object(r.a)({},e),{},{data:{espressoDatetimes:x}}));case 26:case"end":return a.stop()}}),a,null,[[1,11,14,17]])})))}),[t,m,T,u,e,n]);return Object(c.useCallback)(function(){var t=Object(a.a)(o.a.mark((function t(e,n){return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,E({entityIds:e,deletePermanently:n,updateEntityList:g(e,n)});case 2:return t.abrupt("return",t.sent);case 3:case"end":return t.stop()}}),t)})));return function(e,n){return t.apply(this,arguments)}}(),[E,g])}},function(t,e,n){"use strict";var r=n(2),i=n(43),a=n(9),u=n(34),o=n.n(u),c=n(0),s=n(36),f=n(582),l=n(771),d=n(230),p=n(264),v=n(449);e.a=function(t){var e=Object(c.useState)([]),n=Object(a.a)(e,2),u=n[0],b=n[1],h=Object(l.a)(),y=Object(c.useMemo)((function(){return t.map(h)}),[t,h]),O=Object(f.a)({entityType:"DATETIME",filteredEntities:y}),j=O.allReorderedEntities,m=O.updateSortOrder,E=O.sortEntities,T=Object(d.a)(),g=Object(p.a)(),_=Object(v.a)(),k=Object(c.useCallback)(Object(i.a)(o.a.mark((function t(){var e;return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return e={nodes:u,__typename:"EspressoRootQueryDatetimesConnection"},t.next=3,m();case 3:_(Object(r.a)(Object(r.a)({},g),{},{data:{espressoDatetimes:e}}));case 4:case"end":return t.stop()}}),t)}))),[u,m,g,_]),D=Object(c.useCallback)((function(t){var e=t.destination,n=t.source,r=!e,i=(null===n||void 0===n?void 0:n.index)===(null===e||void 0===e?void 0:e.index)&&(null===e||void 0===e?void 0:e.droppableId)===(null===n||void 0===n?void 0:n.droppableId),a=(null===e||void 0===e?void 0:e.droppableId)!==s.datetimesDroppableId;if(!(r||i||a)){var u=E({allEntities:T,newIndex:e.index,oldIndex:n.index});b(u)}}),[T,E]);return Object(c.useMemo)((function(){return{allReorderedEntities:j,sortResponder:D,updateEntityList:k}}),[j,D,k])}},function(t,e){},function(t,e){},function(t,e,n){"use strict";var r=n(2),i=n(43),a=n(9),u=n(34),o=n.n(u),c=n(0),s=n(36),f=n(582),l=n(772),d=n(179),p=n(265),v=n(450);e.a=function(t){var e=Object(c.useState)([]),n=Object(a.a)(e,2),u=n[0],b=n[1],h=Object(l.a)(),y=Object(c.useMemo)((function(){return t.map(h)}),[t,h]),O=Object(f.a)({entityType:"TICKET",filteredEntities:y}),j=O.allReorderedEntities,m=O.updateSortOrder,E=O.sortEntities,T=Object(d.a)(),g=Object(p.a)(),_=Object(v.a)(),k=Object(c.useCallback)(Object(i.a)(o.a.mark((function t(){var e;return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return e={nodes:u,__typename:"EspressoRootQueryTicketsConnection"},t.next=3,m();case 3:_(Object(r.a)(Object(r.a)({},g),{},{data:{espressoTickets:e}}));case 4:case"end":return t.stop()}}),t)}))),[u,m,g,_]),D=Object(c.useCallback)((function(t){var e=t.destination,n=t.source,r=!e,i=(null===n||void 0===n?void 0:n.index)===(null===e||void 0===e?void 0:e.index)&&(null===e||void 0===e?void 0:e.droppableId)===(null===n||void 0===n?void 0:n.droppableId),a=(null===e||void 0===e?void 0:e.droppableId)!==s.ticketDroppableId;if(!(r||i||a)){var u=E({allEntities:T,newIndex:e.index,oldIndex:n.index});b(u)}}),[T,E]);return Object(c.useMemo)((function(){return{allReorderedEntities:j,sortResponder:D,updateEntityList:k}}),[j,D,k])}},function(t,e,n){"use strict";n.d(e,"a",(function(){return v}));var r=n(43),i=n(34),a=n.n(i),u=n(0),o=n(17),c=n(12),s=n(175),f=n(3),l=n(179),d=n(773),p=n(494),v=function(){var t=Object(l.a)(),e=Object(d.a)(),n=Object(p.a)().updateEntities,i=Object(s.useSystemNotifications)(),v=Object(u.useCallback)((function(n){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],i=(null===r||void 0===r?void 0:r.length)?Object(c.entitiesWithGuIdInArray)(t,r):e({entity:"datetimes",entityId:n.id}),a=Object(o.parseInfinity)(n.capacity,1/0),u=Object(c.ticketQuantityFromCapacity)(a),s=i.map((function(t){var e=t.id,n=t.quantity,r=Object(o.parseInfinity)(n,1/0);return Object(o.isInfinite)(a)||a>=r?null:{id:e,quantity:u(n)}})).filter(Boolean);return s}),[e,t]),b=Object(u.useCallback)(function(){var t=Object(r.a)(a.a.mark((function t(e){var r,u,o=arguments;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(r=!(o.length>1&&void 0!==o[1])||o[1],!e.length){t.next=6;break}return u=Object(c.uniqTicketsByMinQty)(e),t.next=5,n({uniqueInputs:u});case 5:r&&i.info({message:Object(f.__)("Ticket quantity has been adjusted because it cannot be more than the related event date capacity.")});case 6:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),[n,i]);return Object(u.useMemo)((function(){return{createBulkQtyUpdateInput:v,doQtyBulkUpdate:b}}),[v,b])}},function(t,e){},function(t,e,n){"use strict";var r=n(43),i=n(2),a=n(34),u=n.n(a),o=n(0),c=n(425),s=n(366),f=n(775),l=n(368),d=n(254),p=n(216);e.a=function(){var t=Object(c.a)(),e=Object(s.a)(),n=Object(f.a)(),a=Object(l.a)({entityType:"PRICE",typeName:d.a.Price}),v=Object(o.useCallback)((function(r){return function(){var a={nodes:Object(p.a)(r,t,!0),__typename:"EspressoRootQueryPricesConnection"};n(Object(i.a)(Object(i.a)({},e),{},{data:{espressoPrices:a}}))}}),[t,e,n]);return Object(o.useCallback)(function(){var t=Object(r.a)(u.a.mark((function t(e){return u.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,a({entityIds:e,updateEntityList:v(e)});case 2:return t.abrupt("return",t.sent);case 3:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),[a,v])}},function(t,e){},function(t,e,n){"use strict";var r;n.d(e,"a",(function(){return r})),n.d(e,"c",(function(){return a})),n.d(e,"b",(function(){return i})),function(t){t.soldOut="DTS",t.active="DTA",t.upcoming="DTU",t.postponed="DTP",t.cancelled="DTC",t.expired="DTE",t.inactive="DTI"}(r||(r={}));var i,a=function(t){return"EspressoDatetime"===t.__typename};!function(t){t.BASE_PRICE="BASE_PRICE",t.DISCOUNT="DISCOUNT",t.SURCHARGE="SURCHARGE",t.TAX="TAX"}(i||(i={}))},function(t,e,n){"use strict";n.r(e);var r=n(777);n.d(e,"useDatesListFilterState",(function(){return r.a}));var i=n(998);n.d(e,"useFilteredDateIds",(function(){return i.a}));var a=n(802);n.d(e,"useDatesListFilterStateManager",(function(){return a.a}));var u=n(999);for(var o in u)["default","useDatesListFilterState","useFilteredDateIds","useDatesListFilterStateManager"].indexOf(o)<0&&function(t){n.d(e,t,(function(){return u[t]}))}(o)},function(t,e,n){"use strict";var r=n(0),i=n(63),a=n.n(i),u=n(429);e.a=function(){var t=Object(r.useContext)(u.b);return a()(t,"useFilteredDateIds must be used inside component"),t}},function(t,e){},function(t,e,n){"use strict";n.r(e);var r=n(779);n.d(e,"useTicketsListFilterState",(function(){return r.a}));var i=n(1001);n.d(e,"useFilteredTicketIds",(function(){return i.a}));var a=n(1401);n.d(e,"useRegisterIsChainedFilter",(function(){return a.a}));var u=n(803);n.d(e,"useTicketsListFilterStateManager",(function(){return u.a}));var o=n(1002);for(var c in o)["default","useTicketsListFilterState","useFilteredTicketIds","useRegisterIsChainedFilter","useTicketsListFilterStateManager"].indexOf(c)<0&&function(t){n.d(e,t,(function(){return o[t]}))}(c)},function(t,e,n){"use strict";var r=n(0),i=n(63),a=n.n(i),u=n(431);e.a=function(){var t=Object(r.useContext)(u.b);return a()(t,"useFilteredTicketIds must be used inside component"),t}},function(t,e){},function(t,e,n){"use strict";n.r(e);var r=n(1004);for(var i in r)["default"].indexOf(i)<0&&function(t){n.d(e,t,(function(){return r[t]}))}(i)},function(t,e){},function(t,e,n){"use strict";var r,i;n.d(e,"a",(function(){return r})),n.d(e,"b",(function(){return i})),function(t){t.DEFAULT_TICKETS="defaultTickets",t.EDIT_DATE="editDate",t.EDIT_TICKET="editTicket",t.NEW_DATE="newDate",t.TAM="tam",t.TPC="tpc"}(r||(r={})),function(t){t.APPROVED="RAP",t.PENDING="RPP",t.WAITLIST="RWL",t.INCOMPLETE="RIC",t.NOT_APPROVED="RNA",t.DECLINED="RDC",t.CANCELLED="RCN"}(i||(i={}))},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(t,e,n){"use strict";var r=n(2),i=n(8),a=n(0),u=n(18),o=n(254),c=n(231),s=n(17),f=function(){return Object(a.useCallback)((function(t,e){return{input:Object(r.a)({clientMutationId:"".concat(t,"_PRICE")},e)}}),[])},l=n(31),d=n(4),p=n(12),v=n(366),b=function(){var t=Object(v.a)();return Object(a.useCallback)((function(e){var n,i=e.cache,a=e.prices,u=e.price,o=e.action,c=a.nodes,s=void 0===c?[]:c,f=[];switch(o){case"add":f=[].concat(Object(l.a)(s),[u]);break;case"update":(n=Object(d.findIndex)(Object(p.entityHasGuid)(u.id),s))>=0&&(f=Object(d.update)(n,u,s));break;case"remove":f=s.filter((function(t){return t.id!==u.id}));break;default:f=s}var v=Object(r.a)(Object(r.a)({},t),{},{data:{espressoPrices:Object(r.a)(Object(r.a)({},a),{},{nodes:f})}});i.writeQuery(v)}),[t])},h=n(24),y=function(){var t=Object(h.useRelations)().updateRelations,e=b();return Object(a.useCallback)((function(n){var r=n.cache,i=n.price,a=n.prices,u=n.priceTypeId,o=i.id;o&&u&&t({entity:"prices",entityId:o,relation:"priceTypes",relationIds:[u]}),e({cache:r,prices:a,price:i,action:"add"})}),[e,t])},O=function(){var t=Object(h.useRelations)(),e=t.dropRelations,n=t.removeRelation,i=b();return Object(a.useCallback)((function(t){var a=t.cache,u=t.prices,o=t.price,c=t.deletePermanently,s=o.id,f=c?"remove":"update";s&&c&&(n({entity:"prices",entityId:s,relation:"tickets"}),e({entity:"prices",entityId:s})),i({cache:a,prices:u,price:Object(r.a)(Object(r.a)({},o),{},{isTrashed:!0}),action:f})}),[e,n,i])},j=function(){var t=Object(h.useRelations)().updateRelations;return Object(a.useCallback)((function(e){var n=e.price,r=e.priceTypeId,i=n.id;i&&r&&t({entity:"prices",entityId:i,relation:"priceTypes",relationIds:[r]})}),[t])},m=n(79),E=["amount","order","overrides","wpUser"],T=["isDefault","isTrashed"],g=function(){var t=Object(v.a)(),e=y(),n=j(),r=O(),i=f(),o=Object(a.useCallback)((function(i){var a,o,c=i.cache,s=i.entity,f=i.input,l=i.mutationType,d=null===f||void 0===f?void 0:f.priceType;try{o=c.readQuery(t)}catch(v){o=null}var p=(null===(a=o)||void 0===a?void 0:a.espressoPrices)||m.DEFAULT_PRICE_LIST_DATA;switch(l){case u.MutationType.Create:e({cache:c,prices:p,price:s,priceTypeId:d});break;case u.MutationType.Update:n({price:s,priceTypeId:d});break;case u.MutationType.Delete:r({cache:c,prices:p,price:s,deletePermanently:null===f||void 0===f?void 0:f.deletePermanently})}}),[e,r,n,t]);return Object(a.useCallback)((function(t,e){var n=Object(s.removeNullAndUndefined)(e),r=Object(s.normalizeNumericFields)(E,n);return r=Object(s.normalizeBooleanFields)(T,r),{variables:i(t,r),onUpdate:o}}),[i,o])},_=n(276),k=n(75);e.a=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",e=Object(u.useMutationWithFeedback)({typeName:k.a.PRICE,mutationType:u.MutationType.Create,mutation:c.CREATE_PRICE}),n=Object(u.useMutationWithFeedback)({typeName:k.a.PRICE,mutationType:u.MutationType.Update,mutation:c.UPDATE_PRICE}),s=Object(u.useMutationWithFeedback)({typeName:k.a.PRICE,mutationType:u.MutationType.Delete,mutation:c.DELETE_PRICE}),f=g(),l=Object(_.a)(o.a.Price),d=Object(a.useCallback)((function(t){var n=f(u.MutationType.Create,t),a=n.onUpdate,o=Object(i.a)(n,["onUpdate"]),c=l({onUpdate:a,mutationType:u.MutationType.Create,input:t});return e(Object(r.a)(Object(r.a)({},o),{},{update:c}))}),[e,l,f]),p=Object(a.useCallback)((function(e){var a=f(u.MutationType.Update,Object(r.a)({id:t},e)),o=a.onUpdate,c=Object(i.a)(a,["onUpdate"]),s=l({onUpdate:o,mutationType:u.MutationType.Update,input:e});return n(Object(r.a)(Object(r.a)({},c),{},{update:s}))}),[l,t,f,n]),v=Object(a.useCallback)((function(e){var n=f(u.MutationType.Delete,Object(r.a)({id:t},e)),a=n.onUpdate,o=Object(i.a)(n,["onUpdate"]),c=l({onUpdate:a,mutationType:u.MutationType.Delete,input:e});return s(Object(r.a)(Object(r.a)({},o),{},{update:c}))}),[s,l,t,f]);return Object(a.useMemo)((function(){return{createEntity:d,updateEntity:p,deleteEntity:v}}),[d,v,p])}},,,,,,,function(t,e,n){"use strict";var r=n(2),i=n(8),a=n(0),u=n(18),o=n(192),c=n(17),s=n(275),f=function(){var t=Object(s.a)();return Object(a.useCallback)((function(e,n){var i=Object(r.a)({clientMutationId:"".concat(e,"_DATETIME")},n);return"CREATE"===e&&(i.eventId=t),{input:i}}),[t])},l=n(577),d=n(576),p=n(24),v=n(12),b=function(){var t=Object(p.useRelations)(),e=t.updateRelations,n=t.addRelation,r=Object(d.a)();return Object(a.useCallback)((function(t){var i=t.cache,a=t.datetimes,u=t.datetime,o=t.tickets;if(!Object(v.hasTempId)(u)){var c=a.nodes,s=void 0===c?[]:c,f=Object(v.getGuids)(s).sort(),d=u.id;Object(l.a)({cache:i,datetimeIn:f,datetimeId:d,action:"add"}),(null===o||void 0===o?void 0:o.length)&&(e({entity:"datetimes",entityId:d,relation:"tickets",relationIds:o}),o.forEach((function(t){n({entity:"tickets",entityId:t,relation:"datetimes",relationId:d})})))}r({cache:i,datetimes:a,datetime:u,action:"add"})}),[n,r,e])},h=n(579),y=n(578),O=n(14),j=n(36),m=n(771),E={__typename:"EspressoDatetime",id:"",dbId:0,cacheId:"",capacity:-1,description:"",endDate:j.PLUS_TWO_MONTHS.toISOString(),isActive:!1,isExpired:!1,isPrimary:!1,isSoldOut:!1,isTrashed:!1,isUpcoming:!1,length:0,name:"",order:0,reserved:0,sold:0,startDate:j.PLUS_ONE_MONTH.toISOString(),status:null,venue:""},T=function(){var t=Object(m.a)();return Object(a.useCallback)((function(e,n){var i={__typename:"EspressoDatetime"},a=t(n.id),o="temp:".concat(Object(c.uuid)());switch(e){case u.MutationType.Create:i=Object(r.a)(Object(r.a)(Object(r.a)({},i),E),{},{cacheId:o,id:o},n);break;case u.MutationType.Delete:i=Object(r.a)(Object(r.a)(Object(r.a)(Object(r.a)(Object(r.a)({},i),E),a),n),{},{isTrashed:!0,cacheId:o});break;case u.MutationType.Update:i=Object(r.a)(Object(r.a)(Object(r.a)(Object(r.a)({},i),a),n),{},{cacheId:o})}var s=e.toLowerCase(),f=Object(c.ucFirst)(s),l="".concat(s,"EspressoDatetime");return Object(O.a)({__typename:"RootMutation"},l,{__typename:"".concat(f,"EspressoDatetimePayload"),espressoDatetime:i})}),[t])},g=n(79),_=n(264),k=["capacity","eventId","order","reserved","sold"],D=function(){var t=Object(_.a)(),e=b(),n=Object(y.a)(),r=Object(h.a)(),i=f(),o=T(),s=Object(a.useCallback)((function(i){var a,o,c=i.cache,s=i.entity,f=i.input,l=i.mutationType;try{o=c.readQuery(t)}catch(v){o=null}var d=(null===(a=o)||void 0===a?void 0:a.espressoDatetimes)||g.DEFAULT_DATETIME_LIST_DATA,p=null===f||void 0===f?void 0:f.tickets;switch(l){case u.MutationType.Create:e({cache:c,datetimes:d,datetime:s,tickets:p});break;case u.MutationType.Update:n({datetime:s,tickets:p});break;case u.MutationType.Delete:r({cache:c,datetimes:d,datetime:s,deletePermanently:null===f||void 0===f?void 0:f.deletePermanently})}}),[e,r,n,t]);return Object(a.useCallback)((function(t,e){var n=Object(c.removeNullAndUndefined)(e),r=Object(c.normalizeNumericFields)(k,n);return{variables:i(t,r),optimisticResponse:o(t,r),onUpdate:s}}),[i,o,s])},I=n(276),x=n(254),w=n(75);e.a=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",e=Object(u.useMutationWithFeedback)({typeName:w.a.DATETIME,mutationType:u.MutationType.Create,mutation:o.CREATE_DATETIME}),n=Object(u.useMutationWithFeedback)({typeName:w.a.DATETIME,mutationType:u.MutationType.Update,mutation:o.UPDATE_DATETIME}),c=Object(u.useMutationWithFeedback)({typeName:w.a.DATETIME,mutationType:u.MutationType.Delete,mutation:o.DELETE_DATETIME}),s=D(),f=Object(I.a)(x.a.Datetime),l=Object(a.useCallback)((function(t){var n=s(u.MutationType.Create,t),a=n.onUpdate,o=Object(i.a)(n,["onUpdate"]),c=f({onUpdate:a,mutationType:u.MutationType.Create,input:t});return e(Object(r.a)(Object(r.a)({},o),{},{update:c}))}),[e,f,s]),d=Object(a.useCallback)((function(e){var a=s(u.MutationType.Update,Object(r.a)({id:t},e)),o=a.onUpdate,c=Object(i.a)(a,["onUpdate"]),l=f({onUpdate:o,mutationType:u.MutationType.Update,input:e});return n(Object(r.a)(Object(r.a)({},c),{},{update:l}))}),[f,t,s,n]),p=Object(a.useCallback)((function(e){var n=s(u.MutationType.Delete,Object(r.a)({id:t},e)),a=n.onUpdate,o=Object(i.a)(n,["onUpdate"]),l=f({onUpdate:a,mutationType:u.MutationType.Delete,input:e});return c(Object(r.a)(Object(r.a)({},o),{},{update:l}))}),[c,f,t,s]);return Object(a.useMemo)((function(){return{createEntity:l,updateEntity:d,deleteEntity:p}}),[l,p,d])}},function(t,e,n){"use strict";var r=n(2),i=n(8),a=n(0),u=n(18),o=n(177),c=n(12),s=n(17),f=function(){return Object(a.useCallback)((function(t,e){return{input:Object(r.a)({clientMutationId:"".concat(t,"_TICKET")},e)}}),[])},l=n(24),d=n(581),p=n(367),v=function(){var t=Object(l.useRelations)(),e=t.addRelation,n=t.updateRelations,r=Object(p.a)();return Object(a.useCallback)((function(t){var i=t.cache,a=t.datetimeIds,u=t.ticket,o=t.tickets,s=t.prices;if(!Object(c.hasTempId)(u)){var f=o.nodes,l=void 0===f?[]:f,p=Object(c.getGuids)(l),v=u.id;Object(d.a)({cache:i,prices:s,ticketIn:p,ticketId:v,action:"add"}),(null===a||void 0===a?void 0:a.length)&&(n({entity:"tickets",entityId:v,relation:"datetimes",relationIds:a}),a.forEach((function(t){e({entity:"datetimes",entityId:t,relation:"tickets",relationId:v})})));var b=Object(c.getGuids)((null===s||void 0===s?void 0:s.nodes)||[]);b.length&&(n({entity:"tickets",entityId:v,relation:"prices",relationIds:b}),b.forEach((function(t){e({entity:"prices",entityId:t,relation:"tickets",relationId:v})})))}r({cache:i,tickets:o,ticket:u,action:"add"})}),[e,n,r])},b=n(580),h=n(583),y=n(14),O=n(36),j=n(772),m={id:"",dbId:0,cacheId:"",description:"",endDate:O.PLUS_TWO_MONTHS.toISOString(),isSoldOut:!1,isTrashed:!1,isDefault:!1,isExpired:!1,isFree:!1,isOnSale:!1,isPending:!0,isRequired:!1,max:-1,min:0,name:"",order:0,price:null,prices:null,quantity:-1,registrationCount:0,reserved:0,reverseCalculate:!0,sold:0,startDate:O.PLUS_ONE_MONTH.toISOString(),userId:"",uses:-1,visibility:"PUBLIC"},E=function(){var t=Object(j.a)();return Object(a.useCallback)((function(e,n){var i={__typename:"EspressoTicket"},a=t(n.id),o="temp:".concat(Object(s.uuid)());switch(e){case u.MutationType.Create:i=Object(r.a)(Object(r.a)(Object(r.a)(Object(r.a)({},i),m),{},{cacheId:o,id:o},n),{},{prices:null});break;case u.MutationType.Delete:i=Object(r.a)(Object(r.a)(Object(r.a)(Object(r.a)(Object(r.a)({},i),m),a),n),{},{isTrashed:!0,cacheId:o});break;case u.MutationType.Update:i=Object(r.a)(Object(r.a)(Object(r.a)(Object(r.a)({},i),a),n),{},{cacheId:o,prices:null})}var c=e.toLowerCase(),f=Object(s.ucFirst)(c),l="".concat(c,"EspressoTicket");return Object(y.a)({__typename:"RootMutation"},l,{__typename:"".concat(f,"EspressoTicketPayload"),espressoTicket:i})}),[t])},T=n(493),g=n(265),_=n(79),k=["max","min","order","price","quantity","reserved","row","sold","uses","wpUser"],D=["isDefault","isRequired","isTrashed","reverseCalculate"],I=n(584),x=function(){var t=Object(g.a)(),e=v(),n=Object(h.a)(),r=Object(b.a)(),o=Object(I.a)(),l=f(),d=E(),p=Object(a.useCallback)((function(a){var o,s,f=a.cache,l=a.entity,d=a.input,p=a.mutationType,v=l.prices,b=Object(i.a)(l,["prices"]);try{s=f.readQuery(t)}catch(j){s=null}var h=(null===(o=s)||void 0===o?void 0:o.espressoTickets)||_.DEFAULT_TICKET_LIST_DATA,y=null===d||void 0===d?void 0:d.datetimes,O=(null===v||void 0===v?void 0:v.nodes)?Object(c.getGuids)(v.nodes):null;switch(p){case u.MutationType.Create:e({cache:f,tickets:h,ticket:b,datetimeIds:y,prices:v});break;case u.MutationType.Update:n({cache:f,tickets:h,ticket:b,datetimeIds:y,priceIds:O});break;case u.MutationType.Delete:r({cache:f,tickets:h,ticket:b,deletePermanently:null===d||void 0===d?void 0:d.deletePermanently})}T.a.doAction("eventEditor.ticket.mutation",p,d,l,f)}),[e,r,n,t]);return Object(a.useCallback)((function(t,e){var n=Object(s.removeNullAndUndefined)(e),r=Object(s.normalizeNumericFields)(k,n);r=Object(s.normalizeBooleanFields)(D,r);var i=l(t,r);if(e.isDefault)return{variables:i,onUpdate:p};var a=o({input:e,mutationType:t});return{variables:i,optimisticResponse:d(t,r),onUpdate:p,refetchQueries:a}}),[o,l,d,p])},w=n(276),C=n(254),A=n(75);e.a=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",e=Object(u.useMutationWithFeedback)({typeName:A.a.TICKET,mutationType:u.MutationType.Create,mutation:o.CREATE_TICKET}),n=Object(u.useMutationWithFeedback)({typeName:A.a.TICKET,mutationType:u.MutationType.Update,mutation:o.UPDATE_TICKET}),c=Object(u.useMutationWithFeedback)({typeName:A.a.TICKET,mutationType:u.MutationType.Delete,mutation:o.DELETE_TICKET}),s=x(),f=Object(w.a)(C.a.Ticket),l=Object(a.useCallback)((function(t){var n=s(u.MutationType.Create,t),a=n.onUpdate,o=Object(i.a)(n,["onUpdate"]),c=f({onUpdate:a,mutationType:u.MutationType.Create,input:t});return e(Object(r.a)(Object(r.a)({},o),{},{update:c}))}),[e,f,s]),d=Object(a.useCallback)((function(e){var a=s(u.MutationType.Update,Object(r.a)({id:t},e)),o=a.onUpdate,c=Object(i.a)(a,["onUpdate"]),l=f({onUpdate:o,mutationType:u.MutationType.Update,input:e});return n(Object(r.a)(Object(r.a)({},c),{},{update:l}))}),[f,t,s,n]),p=Object(a.useCallback)((function(e){var n=s(u.MutationType.Delete,Object(r.a)({id:t},e)),a=n.onUpdate,o=Object(i.a)(n,["onUpdate"]),l=f({onUpdate:a,mutationType:u.MutationType.Delete,input:e});return c(Object(r.a)(Object(r.a)({},o),{},{update:l}))}),[c,f,t,s]);return Object(a.useMemo)((function(){return{createEntity:l,updateEntity:d,deleteEntity:p}}),[l,p,d])}},,,,,,,,,,,,,function(t,e,n){"use strict";n.d(e,"e",(function(){return u})),n.d(e,"d",(function(){return o})),n.d(e,"a",(function(){return c})),n.d(e,"b",(function(){return f})),n.d(e,"c",(function(){return l}));var r=n(222),i=n(50),a=n(3),u=function(t){var e={};return t.subscribe((function(n){var r=n.values;t.batch((function(){var n,u,o,c=r.endDate,s=r.startDate,f=e.startDate,l=e.endDate,d=s!==f,p=c!==l,v=!(null===(n=t.getFieldState("endDate"))||void 0===n?void 0:n.pristine),b=null===(u=t.getFieldState("endDate"))||void 0===u||null===(o=u.data)||void 0===o?void 0:o.changedFromStartDate;if(d){var h,y=Object(i.mayBeAdjustEndDate)({newEndDate:c,newStartDate:s,prevEndDate:l,prevStartDate:f});y!==c&&(t.change("endDate",y),t.mutators.setFieldData("endDate",{changedFromStartDate:!0}),h=Object(a.__)("End date has been adjusted")),t.mutators.setFieldData("endDate",{fieldNotice:h})}p&&(v&&!b&&t.mutators.setFieldData("endDate",{fieldNotice:null}),t.mutators.setFieldData("endDate",{changedFromStartDate:!1}))})),e=r}),{values:!0})},o=function(){return Object(a.__)("Required")},c={startDate:r.a().required((function(){return Object(a.__)("Start Date is required")})).typeError(o),endDate:r.a().required((function(){return Object(a.__)("End Date is required")})).typeError(o).when(["startDate"],(function(t,e){return e.min(t,(function(){return i.endDateAfterStartDateErrorMessage}))}))},s=n(341),f=function(t){return function(e){return(t!==s.a.start||"end"!==e.key)&&(t!==s.a.end||"start"!==e.key)}},l=function(t){var e;return null===(e=window.eventEspressoData.eventEditor)||void 0===e?void 0:e[t]}},,,,,,,,,,,,,,,,,,,,,,,,,,,function(t,e,n){"use strict";n.d(e,"a",(function(){return E}));var r=n(2),i=n(9),a=n(0),u=n(24),o=n(18),c=function(){return Object(a.useMemo)((function(){var t,e,n,r,i=(null===(t=window)||void 0===t||null===(e=t.eventEspressoData)||void 0===e?void 0:e.config)||{},a=i.currentUser,u=i.generalSettings;return{currentUser:a,eventEditor:(null===(n=window)||void 0===n||null===(r=n.eventEspressoData)||void 0===r?void 0:r.eventEditor)||{},generalSettings:u}}),[])},s=n(984),f=n(449),l=n(450),d=n(775),p=n(985),v=n(79),b=n(426),h=n(264),y=n(265),O=n(366),j=n(427),m=n(554),E=function(){var t=Object(u.useStatus)().setIsLoaded,e=Object(u.useRelations)(),n=e.initialize,E=e.isInitialized,T=c(),g=T.currentUser,_=T.eventEditor,k=T.generalSettings,D=Object(o.useIsRehydrated)(),I=Object(i.a)(D,2),x=I[0],w=I[1],C=_.event,A=_.datetimes,S=void 0===A?v.DEFAULT_DATETIME_LIST_DATA:A,F=_.tickets,P=void 0===F?v.DEFAULT_TICKET_LIST_DATA:F,R=_.prices,U=void 0===R?v.DEFAULT_PRICE_LIST_DATA:R,M=_.priceTypes,L=void 0===M?v.DEFAULT_PRICE_TYPE_LIST_DATA:M,N=_.venues,$=void 0===N?v.DEFAULT_VENUE_LIST_DATA:N,q=_.relations,G=Object(b.a)(),z=Object(s.a)(),B=Object(h.a)(),V=Object(f.a)(),K=Object(y.a)(),Q=Object(l.a)(),W=Object(O.a)(),Y=Object(d.a)(),H=Object(j.a)(),Z=Object(p.a)(),J=Object(o.useCurrentUserQueryOptions)(),X=Object(o.useUpdateCurrentUserCache)(),tt=Object(o.useGeneralSettingsQueryOptions)(),et=Object(o.useUpdateGeneralSettingsCache)(),nt=Object(m.a)(),rt=Object(o.useUpdateCache)();return Object(a.useEffect)((function(){E()||n(q)}),[q]),Object(a.useEffect)((function(){x||(rt(Object(r.a)(Object(r.a)({},nt),{},{data:{espressoEvent:C}})),z(Object(r.a)(Object(r.a)({},G),{},{data:{espressoPriceTypes:L}})),t(u.TypeName.priceTypes,!0),V(Object(r.a)(Object(r.a)({},B),{},{data:{espressoDatetimes:S}})),t(u.TypeName.datetimes,!0),Q(Object(r.a)(Object(r.a)({},K),{},{data:{espressoTickets:P}})),t(u.TypeName.tickets,!0),Y(Object(r.a)(Object(r.a)({},W),{},{data:{espressoPrices:U}})),t(u.TypeName.prices,!0),Z(Object(r.a)(Object(r.a)({},H),{},{data:{espressoVenues:$}})),X(Object(r.a)(Object(r.a)({},J),{},{data:{viewer:g}})),et(Object(r.a)(Object(r.a)({},tt),{},{data:{generalSettings:k}})),w(!0))}),[]),x}},,,,,,,,function(t,e,n){"use strict";var r=n(2),i=n(0),a=n(18),u=n(340),o=n(14),c=n(17),s=n(980),f=(Object(c.uuid)(),function(){var t=Object(s.a)();return Object(i.useCallback)((function(e,n){var i={__typename:"EspressoEvent"},u=Object(c.removeNullAndUndefined)(n);switch(e){case a.MutationType.Update:i=Object(r.a)(Object(r.a)(Object(r.a)(Object(r.a)({},i),t),u),{},{cacheId:Object(c.uuid)()}),(null===n||void 0===n?void 0:n.manager)&&(i.manager=Object(r.a)(Object(r.a)({},null===t||void 0===t?void 0:t.manager),{},{id:null===n||void 0===n?void 0:n.manager}))}var s=e.toLowerCase(),f=Object(c.ucFirst)(s),l="".concat(s,"EspressoEvent");return Object(o.a)({__typename:"RootMutation"},l,{__typename:"".concat(f,"EspressoEventPayload"),espressoEvent:i})}),[t])}),l=function(){var t=f(),e=Object(i.useCallback)((function(t,e){return{input:Object(r.a)({clientMutationId:"".concat(t,"_EVENT")},e)}}),[]);return Object(i.useCallback)((function(n,r){return{variables:e(n,r),optimisticResponse:t(n,r)}}),[e,t])},d=n(75);e.a=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",e=Object(a.useMutationWithFeedback)({typeName:d.a.EVENT,mutationType:a.MutationType.Update,mutation:u.UPDATE_EVENT}),n=l(),o=Object(i.useCallback)((function(i){var u=n(a.MutationType.Update,Object(r.a)({id:t},i));return e(u)}),[t,n,e]);return Object(i.useMemo)((function(){return{updateEntity:o}}),[o])}},,function(t,e,n){"use strict";n.d(e,"a",(function(){return u})),n.d(e,"b",(function(){return a}));var r=n(227),i=Object(r.createSlotFill)("NewDateOptions"),a=i.Slot,u=i.Fill},,,,,,,,,,,,,,,,,,,,,,,,,function(t,e,n){"use strict";n.d(e,"a",(function(){return u}));var r=n(18),i=n(24),a=Object(r.makeVar)({}),u=function(){return Object(i.useEntityMeta)(a)}},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(t,e,n){"use strict";n.d(e,"a",(function(){return i}));var r=n(26),i=function(){var t,e;return Object(r.useMemoStringify)((null===(t=window.eventEspressoData)||void 0===t||null===(e=t.eventEditor)||void 0===e?void 0:e.eventManagers)||[])}},function(t,e,n){"use strict";var r=n(9),i=n(0),a=n(45),u=n(75),o=n(4),c=n(24),s=n(12),f=n(778),l=function(){var t=Object(c.useRelations)().getData,e=Object(f.a)(),n=Object(r.a)(e,1)[0],a=Object(i.useMemo)((function(){return Object(o.keys)(Object(o.pickBy)((function(t){return Object(o.hasPath)(["datetimes"],t)&&Object(o.pathOr)([],["datetimes"],t).some((function(t){return n.includes(t)}))}),t().tickets))}),[t,n]),u=Object(i.useCallback)((function(t){var e=t.isChained,n=t.tickets;return e?Object(s.entitiesWithGuIdInArray)(n,a):n}),[a]);return Object(i.useMemo)((function(){return[u,a]}),[u,a])},d=new a.FilterBarService(u.d,u.e).registerFilter;e.a=function(){var t=l(),e=Object(r.a)(t,2),n=e[0],a=e[1],u=Object(i.useRef)();Object(i.useEffect)((function(){var t;null===(t=u.current)||void 0===t||t.call(u);var e=d((function(t){var e=t.entityList,r=t.filterState;return n({isChained:r.isChained,tickets:e})}),9);return u.current=e,function(){var t;null===(t=u.current)||void 0===t||t.call(u)}}),[a,n])}},,,,,,,,,,,,,,,,,,,,,,,,,,,,function(t,e,n){var r=n(384),i=n(1532),a=n(1536),u=r((function(t){return null!=t&&a(t,i(t))}));t.exports=u},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(t,e,n){t.exports=n(1531)},function(t,e,n){"use strict";n.r(e);n(237);var r=n(238);for(var i in r)["default"].indexOf(i)<0&&function(t){n.d(e,t,(function(){return r[t]}))}(i);var a=n(75);n.d(e,"domain",(function(){return a.d})),n.d(e,"datesList",(function(){return a.c})),n.d(e,"ticketsList",(function(){return a.e})),n.d(e,"TICKET_FIELDS_FOR_TPC",(function(){return a.b})),n.d(e,"SINGULAR_ENTITY_NAME",(function(){return a.a}));var u=n(335);n.d(e,"withEdtrContext",(function(){return u.q})),n.d(e,"DatetimesListProvider",(function(){return u.e})),n.d(e,"DatesFilterStateContext",(function(){return u.c})),n.d(e,"DatesFilterStateProvider",(function(){return u.d})),n.d(e,"DatesFilterStateConsumer",(function(){return u.b})),n.d(e,"FilteredDatesContext",(function(){return u.g})),n.d(e,"FilteredDatesProvider",(function(){return u.h})),n.d(e,"FilteredDatesConsumer",(function(){return u.f})),n.d(e,"TicketsListProvider",(function(){return u.p})),n.d(e,"TicketsFilterStateContext",(function(){return u.n})),n.d(e,"TicketsFilterStateProvider",(function(){return u.o})),n.d(e,"TicketsFilterStateConsumer",(function(){return u.m})),n.d(e,"FilteredTicketsContext",(function(){return u.j})),n.d(e,"FilteredTicketsProvider",(function(){return u.k})),n.d(e,"FilteredTicketsConsumer",(function(){return u.i})),n.d(e,"withEntityListContext",(function(){return u.r})),n.d(e,"ServiceProvider",(function(){return u.l})),n.d(e,"ContextProvider",(function(){return u.a}));var o=n(295);for(var i in o)["default","domain","datesList","ticketsList","TICKET_FIELDS_FOR_TPC","SINGULAR_ENTITY_NAME","withEdtrContext","DatetimesListProvider","DatesFilterStateContext","DatesFilterStateProvider","DatesFilterStateConsumer","FilteredDatesContext","FilteredDatesProvider","FilteredDatesConsumer","TicketsListProvider","TicketsFilterStateContext","TicketsFilterStateProvider","TicketsFilterStateConsumer","FilteredTicketsContext","FilteredTicketsProvider","FilteredTicketsConsumer","withEntityListContext","ServiceProvider","ContextProvider"].indexOf(i)<0&&function(t){n.d(e,t,(function(){return o[t]}))}(i);var c=n(1003);for(var i in c)["default","domain","datesList","ticketsList","TICKET_FIELDS_FOR_TPC","SINGULAR_ENTITY_NAME","withEdtrContext","DatetimesListProvider","DatesFilterStateContext","DatesFilterStateProvider","DatesFilterStateConsumer","FilteredDatesContext","FilteredDatesProvider","FilteredDatesConsumer","TicketsListProvider","TicketsFilterStateContext","TicketsFilterStateProvider","TicketsFilterStateConsumer","FilteredTicketsContext","FilteredTicketsProvider","FilteredTicketsConsumer","withEntityListContext","ServiceProvider","ContextProvider"].indexOf(i)<0&&function(t){n.d(e,t,(function(){return c[t]}))}(i);var s=n(164);n.d(e,"useVisibleDatetimeIds",(function(){return s.i})),n.d(e,"useVisibleTicketIds",(function(){return s.j})),n.d(e,"useUpdateDatetimeList",(function(){return s.c})),n.d(e,"useUpdateTicketList",(function(){return s.g})),n.d(e,"useUpdatePriceList",(function(){return s.e})),n.d(e,"useUpdatePriceTypeList",(function(){return s.f})),n.d(e,"useUpdateVenueList",(function(){return s.h})),n.d(e,"useUpdateEntityList",(function(){return s.d})),n.d(e,"useEventsHandler",(function(){return s.a})),n.d(e,"useRegistrationsLink",(function(){return s.b}));var f=n(493);n.d(e,"hooks",(function(){return f.a}));var l=n(1339);n.d(e,"NewDateOption",(function(){return l.a})),n.d(e,"NewDateOptions",(function(){return l.b}));var d=n(1302);n.d(e,"startAndEndDateFixer",(function(){return d.e})),n.d(e,"requiredMessage",(function(){return d.d})),n.d(e,"datesSchema",(function(){return d.a})),n.d(e,"filterCellByStartOrEndDate",(function(){return d.b})),n.d(e,"getEdtrDomData",(function(){return d.c}));var p=n(1005);n.d(e,"EdtrGlobalModals",(function(){return p.a})),n.d(e,"QueryURLRegStatus",(function(){return p.b}))},function(t,e,n){var r=n(384),i=n(982),a=n(1533),u=n(1534),o=n(1535),c=r((function(t){return null!=t&&"function"===typeof t["fantasy-land/empty"]?t["fantasy-land/empty"]():null!=t&&null!=t.constructor&&"function"===typeof t.constructor["fantasy-land/empty"]?t.constructor["fantasy-land/empty"]():null!=t&&"function"===typeof t.empty?t.empty():null!=t&&null!=t.constructor&&"function"===typeof t.constructor.empty?t.constructor.empty():a(t)?[]:o(t)?"":u(t)?{}:i(t)?function(){return arguments}():void 0}));t.exports=c},function(t,e){t.exports=Array.isArray||function(t){return null!=t&&t.length>=0&&"[object Array]"===Object.prototype.toString.call(t)}},function(t,e){t.exports=function(t){return"[object Object]"===Object.prototype.toString.call(t)}},function(t,e){t.exports=function(t){return"[object String]"===Object.prototype.toString.call(t)}},function(t,e,n){var r=n(1537),i=n(1538),a=r((function(t,e){return i(t,e,[],[])}));t.exports=a},function(t,e,n){var r=n(384),i=n(981);t.exports=function(t){return function e(n,a){switch(arguments.length){case 0:return e;case 1:return i(n)?e:r((function(e){return t(n,e)}));default:return i(n)&&i(a)?e:i(n)?r((function(e){return t(e,a)})):i(a)?r((function(e){return t(n,e)})):t(n,a)}}}},function(t,e,n){var r=n(1539),i=n(1540),a=n(1541),u=n(632),o=n(1542),c=n(1543),s=n(1544);function f(t,e,n,a){var u=r(t),o=r(e);function c(t,e){return l(t,e,n.slice(),a.slice())}return!i((function(t,e){return!i(c,e,t)}),o,u)}function l(t,e,n,r){if(o(t,e))return!0;var i=s(t);if(i!==s(e))return!1;if(null==t||null==e)return!1;if("function"===typeof t["fantasy-land/equals"]||"function"===typeof e["fantasy-land/equals"])return"function"===typeof t["fantasy-land/equals"]&&t["fantasy-land/equals"](e)&&"function"===typeof e["fantasy-land/equals"]&&e["fantasy-land/equals"](t);if("function"===typeof t.equals||"function"===typeof e.equals)return"function"===typeof t.equals&&t.equals(e)&&"function"===typeof e.equals&&e.equals(t);switch(i){case"Arguments":case"Array":case"Object":if("function"===typeof t.constructor&&"Promise"===a(t.constructor))return t===e;break;case"Boolean":case"Number":case"String":if(typeof t!==typeof e||!o(t.valueOf(),e.valueOf()))return!1;break;case"Date":if(!o(t.valueOf(),e.valueOf()))return!1;break;case"Error":return t.name===e.name&&t.message===e.message;case"RegExp":if(t.source!==e.source||t.global!==e.global||t.ignoreCase!==e.ignoreCase||t.multiline!==e.multiline||t.sticky!==e.sticky||t.unicode!==e.unicode)return!1}for(var d=n.length-1;d>=0;){if(n[d]===t)return r[d]===e;d-=1}switch(i){case"Map":return t.size===e.size&&f(t.entries(),e.entries(),n.concat([t]),r.concat([e]));case"Set":return t.size===e.size&&f(t.values(),e.values(),n.concat([t]),r.concat([e]));case"Arguments":case"Array":case"Object":case"Boolean":case"Number":case"String":case"Date":case"Error":case"RegExp":case"Int8Array":case"Uint8Array":case"Uint8ClampedArray":case"Int16Array":case"Uint16Array":case"Int32Array":case"Uint32Array":case"Float32Array":case"Float64Array":case"ArrayBuffer":break;default:return!1}var p=c(t);if(p.length!==c(e).length)return!1;var v=n.concat([t]),b=r.concat([e]);for(d=p.length-1;d>=0;){var h=p[d];if(!u(h,e)||!l(e[h],t[h],v,b))return!1;d-=1}return!0}t.exports=l},function(t,e){t.exports=function(t){for(var e,n=[];!(e=t.next()).done;)n.push(e.value);return n}},function(t,e){t.exports=function(t,e,n){for(var r=0,i=n.length;r=0;)i(e=o[n],t)&&!s(r,e)&&(r[r.length]=e),n-=1;return r})):r((function(t){return Object(t)!==t?[]:Object.keys(t)}));t.exports=f},function(t,e,n){var r=n(384)((function(t){return null===t?"Null":void 0===t?"Undefined":Object.prototype.toString.call(t).slice(8,-1)}));t.exports=r}]); +//# sourceMappingURL=edtrServices.67147781.js.map \ No newline at end of file diff --git a/assets/static/js/edtrServices.7f51b510.js.LICENSE.txt b/assets/static/js/edtrServices.67147781.js.LICENSE.txt similarity index 100% rename from assets/static/js/edtrServices.7f51b510.js.LICENSE.txt rename to assets/static/js/edtrServices.67147781.js.LICENSE.txt diff --git a/assets/static/js/edtrServices.67147781.js.map b/assets/static/js/edtrServices.67147781.js.map new file mode 100644 index 00000000000..d298ea9a359 --- /dev/null +++ b/assets/static/js/edtrServices.67147781.js.map @@ -0,0 +1 @@ +{"version":3,"sources":["../webpack/bootstrap","../external \"React\"","../node_modules/react/jsx-runtime.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/objectSpread2.js","../external [\"eventespresso\",\"i18n\"]","../external \"R\"","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/slicedToArray.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/iterableToArrayLimit.js","../external [\"eventespresso\",\"predicates\"]","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/defineProperty.js","../external [\"eventespresso\",\"utils\"]","../external [\"eventespresso\",\"data\"]","../external [\"eventespresso\",\"services\"]","../external [\"eventespresso\",\"hooks\"]","../external [\"eventespresso\",\"adapters\"]","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/toConsumableArray.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/arrayWithoutHoles.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/nonIterableSpread.js","../node_modules/@babel/runtime/regenerator/index.js","../external [\"eventespresso\",\"constants\"]","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/classCallCheck.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/arrayLikeToArray.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/asyncToGenerator.js","../external [\"eventespresso\",\"registry\"]","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/getPrototypeOf.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/createClass.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/taggedTemplateLiteral.js","../external [\"eventespresso\",\"dates\"]","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/inherits.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/possibleConstructorReturn.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/createSuper.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/arrayWithHoles.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/nonIterableRest.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/get.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/superPropBase.js","../node_modules/invariant/browser.js","../node_modules/object-assign/index.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/iterableToArray.js","../packages/edtr-services/src/constants.ts","../node_modules/react/cjs/react-jsx-runtime.production.min.js","../packages/edtr-services/src/apollo/queries/index.ts","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/createForOfIteratorHelper.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/assertThisInitialized.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/typeof.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/isNativeReflectConstruct.js","../node_modules/lodash/_root.js","../node_modules/lodash/isArray.js","../node_modules/property-expr/index.js","../external [\"eventespresso\",\"ioc\"]","../node_modules/lodash/_getNative.js","../node_modules/lodash/has.js","../node_modules/webpack/buildin/global.js","../packages/edtr-services/src/hooks/useEventsHandler.ts","../packages/edtr-services/src/hooks/useRegistrationsLink.ts","../node_modules/regenerator-runtime/runtime.js","../external [\"eventespresso\",\"toaster\"]","../packages/edtr-services/src/apollo/mutations/tickets/index.ts","../packages/edtr-services/src/apollo/queries/tickets/useTickets.ts","../packages/edtr-services/src/hooks/entityListCacheUpdates/useUpdateEntityList.ts","../packages/edtr-services/src/apollo/mutations/datetimes/index.ts","../packages/edtr-services/src/apollo/queries/tickets/queries.ts","../node_modules/lodash/_baseGetTag.js","../node_modules/lodash/isObjectLike.js","../node_modules/lodash/toString.js","../packages/edtr-services/src/apollo/queries/datetimes/queries.ts","../packages/edtr-services/src/apollo/mutations/utils.ts","../node_modules/nanoclone/src/index.js","../node_modules/yup/es/util/printValue.js","../node_modules/yup/es/locale.js","../node_modules/yup/es/util/isSchema.js","../node_modules/yup/es/Condition.js","../node_modules/yup/es/util/toArray.js","../node_modules/yup/es/ValidationError.js","../node_modules/yup/es/util/runTests.js","../node_modules/yup/es/Reference.js","../node_modules/yup/es/util/createValidation.js","../node_modules/yup/es/util/reach.js","../node_modules/yup/es/util/ReferenceSet.js","../node_modules/yup/es/schema.js","../node_modules/yup/es/mixed.js","../node_modules/yup/es/util/isAbsent.js","../node_modules/yup/es/boolean.js","../node_modules/yup/es/string.js","../node_modules/yup/es/number.js","../node_modules/yup/es/util/isodate.js","../node_modules/yup/es/date.js","../node_modules/yup/es/util/sortFields.js","../node_modules/yup/es/util/sortByKeyOrder.js","../node_modules/yup/es/object.js","../node_modules/yup/es/array.js","../external [\"eventespresso\",\"slotFill\"]","../packages/edtr-services/src/apollo/queries/datetimes/useDatetimes.ts","../packages/edtr-services/src/apollo/mutations/prices/index.ts","../types/index.ts","../packages/edtr-services/src/apollo/index.ts","../node_modules/lodash/_Symbol.js","../node_modules/lodash/_nativeCreate.js","../node_modules/lodash/_ListCache.js","../node_modules/lodash/_assocIndexOf.js","../node_modules/lodash/_getMapData.js","../node_modules/lodash/_toKey.js","../packages/edtr-services/src/apollo/mutations/types.ts","../node_modules/lodash/mapValues.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/construct.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/wrapNativeSuper.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/isNativeFunction.js","../external [\"eventespresso\",\"storage\"]","../packages/edtr-services/src/apollo/queries/datetimes/useDatetimeQueryOptions.ts","../packages/edtr-services/src/apollo/queries/tickets/useTicketQueryOptions.ts","../packages/edtr-services/src/apollo/queries/events/useEventId.ts","../packages/edtr-services/src/apollo/mutations/useUpdateCallback.ts","../packages/edtr-services/src/apollo/queries/prices/queries.ts","../node_modules/webpack/buildin/module.js","../packages/edtr-services/src/filterState/index.ts","../node_modules/lodash/_isKey.js","../node_modules/lodash/isSymbol.js","../node_modules/lodash/_MapCache.js","../node_modules/lodash/isObject.js","../node_modules/lodash/_Map.js","../node_modules/lodash/isLength.js","../node_modules/lodash/keys.js","../node_modules/lodash/snakeCase.js","../packages/edtr-services/src/context/ContextProvider.tsx","../packages/edtr-services/src/context/withEdtrContext.tsx","../packages/edtr-services/src/context/EntityListContext/datetimes/DatetimesListProvider.tsx","../packages/edtr-services/src/context/EntityListContext/tickets/TicketsListProvider.tsx","../packages/edtr-services/src/context/EntityListContext/withEntityListContext.tsx","../packages/edtr-services/src/apollo/queries/datetimes/useDatetimeIds.ts","../packages/edtr-services/src/apollo/queries/datetimes/useDatetimeItem.ts","../packages/edtr-services/src/apollo/queries/datetimes/useRelatedDatetimes.ts","../packages/edtr-services/src/apollo/queries/prices/useRelatedPrices.ts","../packages/edtr-services/src/apollo/mutations/events/index.ts","../packages/edtr-services/src/filterState/types.ts","../packages/edtr-services/src/apollo/queries/prices/usePriceQueryOptions.ts","../packages/edtr-services/src/apollo/mutations/tickets/useUpdateTicketCache.ts","../packages/edtr-services/src/apollo/mutations/useBulkDeleteEntities.ts","../node_modules/ramda/src/internal/_curry1.js","../packages/edtr-services/src/apollo/mutations/index.ts","../node_modules/lodash/_hasPath.js","../node_modules/lodash/_castPath.js","../node_modules/lodash/_freeGlobal.js","../node_modules/lodash/isFunction.js","../node_modules/lodash/_toSource.js","../node_modules/lodash/eq.js","../node_modules/lodash/isArguments.js","../node_modules/lodash/_isIndex.js","../node_modules/lodash/_baseAssignValue.js","../node_modules/lodash/_baseForOwn.js","../node_modules/lodash/isBuffer.js","../node_modules/lodash/isTypedArray.js","../node_modules/lodash/_baseIteratee.js","../node_modules/lodash/_Stack.js","../node_modules/lodash/_baseIsEqual.js","../node_modules/lodash/_equalArrays.js","../node_modules/lodash/_isStrictComparable.js","../node_modules/lodash/_matchesStrictComparable.js","../node_modules/lodash/_baseGet.js","../node_modules/lodash/_createCompounder.js","../node_modules/lodash/_hasUnicode.js","../packages/edtr-services/src/apollo/queries/events/queries.ts","../packages/edtr-services/src/apollo/queries/prices/usePrices.ts","../packages/edtr-services/src/apollo/queries/priceTypes/usePriceTypeQueryOptions.ts","../packages/edtr-services/src/apollo/queries/venues/useVenueQueryOptions.ts","../packages/edtr-services/src/context/EntityListContext/datetimes/DatesFilterStateProvider.tsx","../packages/edtr-services/src/context/EntityListContext/datetimes/FilteredDatesProvider.tsx","../packages/edtr-services/src/context/EntityListContext/tickets/TicketsFilterStateProvider.tsx","../packages/edtr-services/src/context/EntityListContext/tickets/FilteredTicketsProvider.tsx","../external [\"wp\",\"url\"]","../node_modules/lodash/camelCase.js","../node_modules/lodash/mapKeys.js","../node_modules/toposort/index.js","../packages/edtr-services/src/hooks/entityListCacheUpdates/useUpdateDatetimeList.ts","../packages/edtr-services/src/hooks/entityListCacheUpdates/useUpdateTicketList.ts","../packages/edtr-services/src/apollo/queries/events/index.ts","../packages/edtr-services/src/apollo/queries/tickets/useDefaultTickets.ts","../packages/edtr-services/src/apollo/queries/tickets/useDefaultTicketIds.ts","../packages/edtr-services/src/apollo/queries/tickets/useTicketIds.ts","../packages/edtr-services/src/apollo/queries/tickets/useTicketItem.ts","../packages/edtr-services/src/apollo/queries/tickets/useTicketPrices.ts","../packages/edtr-services/src/apollo/queries/tickets/useCappedQuantity.ts","../packages/edtr-services/src/apollo/queries/priceTypes/usePriceTypes.ts","../packages/edtr-services/src/apollo/queries/priceTypes/useDefaultPriceType.ts","../packages/edtr-services/src/apollo/queries/priceTypes/usePriceTypeForPrice.ts","../packages/edtr-services/src/apollo/mutations/datetimes/useDeleteRelatedTickets.ts","../packages/edtr-services/src/ioc/index.ts","../packages/edtr-services/src/apollo/mutations/tickets/useBulkEditTickets.ts","../packages/edtr-services/src/apollo/queries/events/useEventGuid.ts","../packages/edtr-services/src/apollo/queries/events/useEventQueryOptions.ts","../packages/edtr-services/src/apollo/queries/priceTypes/queries.ts","../packages/edtr-services/src/apollo/mutations/datetimes/useUpdateDatetimeCache.ts","../packages/edtr-services/src/apollo/mutations/datetimes/updateTicketCache.ts","../packages/edtr-services/src/apollo/mutations/datetimes/useOnUpdateDatetime.ts","../packages/edtr-services/src/apollo/mutations/datetimes/useOnDeleteDatetime.ts","../packages/edtr-services/src/apollo/mutations/tickets/useOnDeleteTicket.ts","../packages/edtr-services/src/apollo/mutations/tickets/updatePriceCache.ts","../packages/edtr-services/src/apollo/mutations/useReorderEntities.ts","../packages/edtr-services/src/apollo/mutations/tickets/useOnUpdateTicket.ts","../packages/edtr-services/src/apollo/mutations/tickets/useAffectedDatesQueries.ts","../node_modules/ramda/src/internal/_has.js","../node_modules/lodash/_baseHas.js","../node_modules/lodash/_getRawTag.js","../node_modules/lodash/_objectToString.js","../node_modules/lodash/_stringToPath.js","../node_modules/lodash/_memoizeCapped.js","../node_modules/lodash/memoize.js","../node_modules/lodash/_mapCacheClear.js","../node_modules/lodash/_Hash.js","../node_modules/lodash/_hashClear.js","../node_modules/lodash/_baseIsNative.js","../node_modules/lodash/_isMasked.js","../node_modules/lodash/_coreJsData.js","../node_modules/lodash/_getValue.js","../node_modules/lodash/_hashDelete.js","../node_modules/lodash/_hashGet.js","../node_modules/lodash/_hashHas.js","../node_modules/lodash/_hashSet.js","../node_modules/lodash/_listCacheClear.js","../node_modules/lodash/_listCacheDelete.js","../node_modules/lodash/_listCacheGet.js","../node_modules/lodash/_listCacheHas.js","../node_modules/lodash/_listCacheSet.js","../node_modules/lodash/_mapCacheDelete.js","../node_modules/lodash/_isKeyable.js","../node_modules/lodash/_mapCacheGet.js","../node_modules/lodash/_mapCacheHas.js","../node_modules/lodash/_mapCacheSet.js","../node_modules/lodash/_baseToString.js","../node_modules/lodash/_arrayMap.js","../node_modules/lodash/_baseIsArguments.js","../node_modules/lodash/_defineProperty.js","../node_modules/lodash/_baseFor.js","../node_modules/lodash/_createBaseFor.js","../node_modules/lodash/_arrayLikeKeys.js","../node_modules/lodash/_baseTimes.js","../node_modules/lodash/stubFalse.js","../node_modules/lodash/_baseIsTypedArray.js","../node_modules/lodash/_baseUnary.js","../node_modules/lodash/_nodeUtil.js","../node_modules/lodash/_baseKeys.js","../node_modules/lodash/_isPrototype.js","../node_modules/lodash/_nativeKeys.js","../node_modules/lodash/_overArg.js","../node_modules/lodash/isArrayLike.js","../node_modules/lodash/_baseMatches.js","../node_modules/lodash/_baseIsMatch.js","../node_modules/lodash/_stackClear.js","../node_modules/lodash/_stackDelete.js","../node_modules/lodash/_stackGet.js","../node_modules/lodash/_stackHas.js","../node_modules/lodash/_stackSet.js","../node_modules/lodash/_baseIsEqualDeep.js","../node_modules/lodash/_SetCache.js","../node_modules/lodash/_setCacheAdd.js","../node_modules/lodash/_setCacheHas.js","../node_modules/lodash/_arraySome.js","../node_modules/lodash/_cacheHas.js","../node_modules/lodash/_equalByTag.js","../node_modules/lodash/_Uint8Array.js","../node_modules/lodash/_mapToArray.js","../node_modules/lodash/_setToArray.js","../node_modules/lodash/_equalObjects.js","../node_modules/lodash/_getAllKeys.js","../node_modules/lodash/_baseGetAllKeys.js","../node_modules/lodash/_arrayPush.js","../node_modules/lodash/_getSymbols.js","../node_modules/lodash/_arrayFilter.js","../node_modules/lodash/stubArray.js","../node_modules/lodash/_getTag.js","../node_modules/lodash/_DataView.js","../node_modules/lodash/_Promise.js","../node_modules/lodash/_Set.js","../node_modules/lodash/_WeakMap.js","../node_modules/lodash/_getMatchData.js","../node_modules/lodash/_baseMatchesProperty.js","../node_modules/lodash/get.js","../node_modules/lodash/hasIn.js","../node_modules/lodash/_baseHasIn.js","../node_modules/lodash/identity.js","../node_modules/lodash/property.js","../node_modules/lodash/_baseProperty.js","../node_modules/lodash/_basePropertyDeep.js","../node_modules/lodash/_arrayReduce.js","../node_modules/lodash/deburr.js","../node_modules/lodash/_deburrLetter.js","../node_modules/lodash/_basePropertyOf.js","../node_modules/lodash/words.js","../node_modules/lodash/_asciiWords.js","../node_modules/lodash/_hasUnicodeWord.js","../node_modules/lodash/_unicodeWords.js","../node_modules/lodash/capitalize.js","../node_modules/lodash/upperFirst.js","../node_modules/lodash/_createCaseFirst.js","../node_modules/lodash/_castSlice.js","../node_modules/lodash/_baseSlice.js","../node_modules/lodash/_stringToArray.js","../node_modules/lodash/_asciiToArray.js","../node_modules/lodash/_unicodeToArray.js","../packages/edtr-services/src/apollo/queries/venues/useVenues.ts","../packages/edtr-services/src/apollo/queries/datetimes/useLazyDatetime.ts","../packages/edtr-services/src/apollo/queries/tickets/useLazyTicket.ts","../packages/edtr-services/src/apollo/queries/tickets/useRelatedTickets.ts","../packages/edtr-services/src/apollo/queries/venues/queries.ts","../packages/edtr-services/src/hooks/entityListCacheUpdates/useUpdatePriceList.ts","../packages/edtr-services/src/apollo/mutations/tickets/useBulkDeleteTickets.ts","../packages/edtr-services/src/filterState/datetimes/useDatesListFilterState.ts","../packages/edtr-services/src/hooks/edtrState/useVisibleDatetimeIds.ts","../packages/edtr-services/src/filterState/tickets/useTicketsListFilterState.ts","../packages/edtr-services/src/hooks/edtrState/useVisibleTicketIds.ts","../packages/edtr-services/src/filterState/datetimes/reducer.ts","../packages/edtr-services/src/filterState/datetimes/useDatesListFilterStateManager.ts","../packages/edtr-services/src/filterState/tickets/reducer.ts","../packages/edtr-services/src/filterState/tickets/useTicketsListFilterStateManager.ts","../packages/edtr-services/src/apollo/queries/events/useEvent.ts","../node_modules/ramda/src/internal/_isPlaceholder.js","../node_modules/ramda/src/internal/_isArguments.js","../packages/edtr-services/src/hooks/entityListCacheUpdates/useUpdatePriceTypeList.ts","../packages/edtr-services/src/hooks/entityListCacheUpdates/useUpdateVenueList.ts","../packages/edtr-services/src/apollo/mutations/datetimes/useBulkEditDatetimes.ts","../packages/edtr-services/src/apollo/mutations/datetimes/useBulkDeleteDatetimes.ts","../packages/edtr-services/src/apollo/mutations/datetimes/useReorderDatetimes.ts","../packages/edtr-services/src/apollo/mutations/tickets/useReorderTickets.ts","../packages/edtr-services/src/apollo/mutations/tickets/useUpdateTicketQtyByCapacity.ts","../packages/edtr-services/src/apollo/mutations/prices/useBulkDeletePrices.ts","../packages/edtr-services/src/apollo/types.ts","../packages/edtr-services/src/filterState/datetimes/index.ts","../packages/edtr-services/src/filterState/datetimes/useFilteredDateIds.ts","../packages/edtr-services/src/filterState/tickets/index.ts","../packages/edtr-services/src/filterState/tickets/useFilteredTicketIds.ts","../packages/edtr-services/src/forms/index.ts","../packages/edtr-services/src/types.ts","../packages/edtr-services/src/apollo/mutations/prices/useMutationVariables.ts","../packages/edtr-services/src/apollo/mutations/prices/useUpdatePriceCache.ts","../packages/edtr-services/src/apollo/mutations/prices/useOnCreatePrice.ts","../packages/edtr-services/src/apollo/mutations/prices/useOnDeletePrice.ts","../packages/edtr-services/src/apollo/mutations/prices/useOnUpdatePrice.ts","../packages/edtr-services/src/apollo/mutations/prices/constants.ts","../packages/edtr-services/src/apollo/mutations/prices/useMutationHandler.ts","../packages/edtr-services/src/apollo/mutations/prices/usePriceMutator.ts","../packages/edtr-services/src/apollo/mutations/datetimes/useMutationVariables.ts","../packages/edtr-services/src/apollo/mutations/datetimes/useOnCreateDatetime.ts","../packages/edtr-services/src/apollo/mutations/datetimes/useOptimisticResponse.ts","../packages/edtr-services/src/apollo/mutations/datetimes/constants.ts","../packages/edtr-services/src/apollo/mutations/datetimes/useMutationHandler.ts","../packages/edtr-services/src/apollo/mutations/datetimes/useDatetimeMutator.ts","../packages/edtr-services/src/apollo/mutations/tickets/useMutationVariables.ts","../packages/edtr-services/src/apollo/mutations/tickets/useOnCreateTicket.ts","../packages/edtr-services/src/apollo/mutations/tickets/useOptimisticResponse.ts","../packages/edtr-services/src/apollo/mutations/tickets/constants.ts","../packages/edtr-services/src/apollo/mutations/tickets/useMutationHandler.ts","../packages/edtr-services/src/apollo/mutations/tickets/useTicketMutator.ts","../packages/edtr-services/src/utils/dateAndTime.ts","../packages/edtr-services/src/utils/filterCells.ts","../packages/edtr-services/src/utils/misc.ts","../packages/edtr-services/src/apollo/initialization/useCacheRehydrationData.ts","../packages/edtr-services/src/apollo/initialization/useCacheRehydration.ts","../packages/edtr-services/src/apollo/mutations/events/useOptimisticResponse.ts","../packages/edtr-services/src/apollo/mutations/events/useMutationHandler.ts","../packages/edtr-services/src/apollo/mutations/events/useEventMutator.ts","../packages/edtr-services/src/slots/NewDateOptions.ts","../packages/edtr-services/src/apollo/meta/useTicketsMeta.ts","../packages/edtr-services/src/apollo/queries/users/useEventManagers.ts","../packages/edtr-services/src/filterState/tickets/useIsChainedFilter.ts","../packages/edtr-services/src/filterState/tickets/useRegisterIsChainedFilter.ts","../node_modules/ramda/src/isEmpty.js","../packages/edtr-services/src/index.ts","../node_modules/ramda/src/empty.js","../node_modules/ramda/src/internal/_isArray.js","../node_modules/ramda/src/internal/_isObject.js","../node_modules/ramda/src/internal/_isString.js","../node_modules/ramda/src/equals.js","../node_modules/ramda/src/internal/_curry2.js","../node_modules/ramda/src/internal/_equals.js","../node_modules/ramda/src/internal/_arrayFromIterator.js","../node_modules/ramda/src/internal/_includesWith.js","../node_modules/ramda/src/internal/_functionName.js","../node_modules/ramda/src/internal/_objectIs.js","../node_modules/ramda/src/keys.js","../node_modules/ramda/src/type.js"],"names":["installedModules","__webpack_require__","moduleId","exports","module","i","l","modules","call","m","c","d","name","getter","o","Object","defineProperty","enumerable","get","r","Symbol","toStringTag","value","t","mode","__esModule","ns","create","key","bind","n","object","property","prototype","hasOwnProperty","p","s","window","require","ownKeys","enumerableOnly","keys","getOwnPropertySymbols","symbols","filter","sym","getOwnPropertyDescriptor","push","apply","_objectSpread2","target","arguments","length","source","forEach","getOwnPropertyDescriptors","defineProperties","_objectWithoutProperties","excluded","sourceKeys","indexOf","sourceSymbolKeys","propertyIsEnumerable","_slicedToArray","arr","arrayWithHoles","iterator","_arr","_n","_d","_e","undefined","_s","_i","next","done","err","unsupportedIterableToArray","nonIterableRest","_defineProperty","obj","configurable","writable","_toConsumableArray","Array","isArray","arrayLikeToArray","iterableToArray","TypeError","_classCallCheck","instance","Constructor","_arrayLikeToArray","len","arr2","_unsupportedIterableToArray","minLen","toString","slice","constructor","from","test","asyncGeneratorStep","gen","resolve","reject","_next","_throw","arg","info","error","Promise","then","_asyncToGenerator","fn","self","this","args","_getPrototypeOf","setPrototypeOf","getPrototypeOf","__proto__","_defineProperties","props","descriptor","_createClass","protoProps","staticProps","_taggedTemplateLiteral","strings","raw","freeze","_inherits","subClass","superClass","_possibleConstructorReturn","assertThisInitialized","_createSuper","Derived","hasNativeReflectConstruct","isNativeReflectConstruct","result","Super","NewTarget","Reflect","construct","_arrayWithHoles","_nonIterableRest","receiver","base","desc","condition","format","a","b","e","f","Error","argIndex","replace","framesToPop","propIsEnumerable","toObject","val","assign","test1","String","getOwnPropertyNames","test2","fromCharCode","map","join","test3","split","letter","shouldUseNative","to","_iterableToArray","iter","domain","datesList","ticketsList","TICKET_FIELDS_FOR_TPC","SINGULAR_ENTITY_NAME","DATETIME","__","EVENT","TICKET","PRICE","PRICE_TYPE","g","Fragment","for","h","__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED","ReactCurrentOwner","ref","__self","__source","q","k","defaultProps","$$typeof","type","_owner","current","jsx","jsxs","DEFAULT_ENTITY_LIST_DATA","nodes","__typename","DEFAULT_DATETIME_LIST_DATA","DEFAULT_TICKET_LIST_DATA","DEFAULT_PRICE_LIST_DATA","DEFAULT_PRICE_TYPE_LIST_DATA","DEFAULT_VENUE_LIST_DATA","_createForOfIteratorHelper","allowArrayLike","it","F","normalCompletion","didErr","step","_e2","_assertThisInitialized","ReferenceError","_setPrototypeOf","_typeof","_isNativeReflectConstruct","sham","Proxy","Date","freeGlobal","freeSelf","root","Function","Cache","maxSize","_maxSize","clear","_size","_values","set","SPLIT_REGEX","DIGIT_REGEX","LEAD_DIGIT_REGEX","SPEC_CHAR_REGEX","CLEAN_QUOTES_REGEX","pathCache","setCache","getCache","normalizePath","path","part","match","isQuoted","str","charAt","shouldBeQuoted","hasLeadingNumber","hasSpecialChars","setter","parts","index","data","safe","segments","reduce","cb","thisArg","idx","isBracket","baseIsNative","getValue","baseHas","hasPath","useEventsHandler","toaster","useSystemNotifications","onError","useCallback","message","useEffect","events","on","off","useRegistrationsLink","siteUrl","useConfig","eventId","useEventId","useMemo","adminUrl","getAdminUrl","adminSiteUrl","admin","page","ADMIN_ROUTES","REGISTRATIONS","addQueryArgs","_objectSpread","event_id","return","runtime","Op","hasOwn","$Symbol","iteratorSymbol","asyncIteratorSymbol","asyncIterator","toStringTagSymbol","define","wrap","innerFn","outerFn","tryLocsList","protoGenerator","Generator","generator","context","Context","_invoke","state","GenStateSuspendedStart","method","GenStateExecuting","GenStateCompleted","doneResult","delegate","delegateResult","maybeInvokeDelegate","ContinueSentinel","sent","_sent","dispatchException","abrupt","record","tryCatch","GenStateSuspendedYield","makeInvokeMethod","GeneratorFunction","GeneratorFunctionPrototype","IteratorPrototype","getProto","NativeIteratorPrototype","values","Gp","defineIteratorMethods","AsyncIterator","PromiseImpl","invoke","__await","unwrapped","previousPromise","callInvokeWithMethodAndArg","resultName","nextLoc","pushTryEntry","locs","entry","tryLoc","catchLoc","finallyLoc","afterLoc","tryEntries","resetTryEntry","completion","reset","iterable","iteratorMethod","isNaN","displayName","isGeneratorFunction","genFun","ctor","mark","awrap","async","reverse","pop","skipTempReset","prev","stop","rootRecord","rval","exception","handle","loc","caught","hasCatch","hasFinally","finallyEntry","complete","finish","thrown","delegateYield","regeneratorRuntime","accidentalStrictMode","TICKET_PRICES_ATTRIBUTE","gql","_templateObject","PRICE_ATTRIBUTES","CREATE_TICKET","_templateObject2","TICKET_ATTRIBUTES","UPDATE_TICKET","_templateObject3","DELETE_TICKET","_templateObject4","BULK_UPDATE_TICKETS","_templateObject5","useTickets","_data$espressoTickets","filterBy","isNotDefault","options","useTicketQueryOptions","_useTicketsQuery","useTicketsQuery","espressoTickets","cacheIds","getCacheIds","useUpdateEntityList","writeQueryOptions","useUpdateCache","CREATE_DATETIME","DATETIME_ATTRIBUTES","UPDATE_DATETIME","DELETE_DATETIME","BULK_UPDATE_DATETIMES","GET_TICKET","GET_TICKETS","getRawTag","objectToString","symToStringTag","baseToString","GET_DATETIME","GET_DATETIMES","formToBulkUpdateInput","formData","allEntities","selectedIds","shiftDates","uniqueInputs","unit","selectedEntities","entitiesWithGuIdInArray","shiftTheDate","shiftDate","entity","startDate","toISOString","endDate","id","sharedInput","cacheNodesFromBulkInput","input","inputs","currentInput","node","cacheId","uuid","cacheNodesFromBulkDelete","entityIds","deletePermanently","entitiesWithGuIdNotInArray","includes","isTrashed","updateDatetimeFlags","date","isActive","isExpired","isUpcoming","updateTicketFlags","ticket","isFree","price","isOnSale","isPending","Map","_","Set","baseClone","src","circulars","clones","nodeType","cloneNode","getTime","RegExp","clone","entries","findIndex","errorToString","regExpToString","symbolToString","SYMBOL_REGEXP","printNumber","printSimpleValue","quoteStrings","typeOf","concat","tag","printValue","JSON","stringify","mixed","default","required","oneOf","notOneOf","notType","_ref","originalValue","isCast","msg","defined","string","min","max","matches","email","url","trim","lowercase","uppercase","number","lessThan","moreThan","positive","negative","integer","boolean","isValue","noUnknown","array","isSchema","__isYupSchema__","Condition","refs","has","otherwise","is","check","_len","_key","every","_len2","_key2","schema","branch","parent","toArray","_extends","strReg","ValidationError","_Error","_super","errorOrErrors","field","_this","errors","params","inner","_this$errors","isError","captureStackTrace","label","_wrapNativeSuper","runTests","endEarly","tests","sort","callback","fired","once","count","nestedErrors","prefixes","Reference","isContext","isSibling","prefix","__isYupRef","createValidation","config","validate","_ref$path","sync","rest","_objectWithoutPropertiesLoose","item","Ref","isRef","createError","overrides","nextParams","mapValues","formatError","ctx","_ref2","validOrError","catch","OPTIONS","substr","getIn","lastPart","lastPartDebug","_part","innerType","parseInt","fields","_type","parentPath","ReferenceSet","list","size","_step","description","_iterator","_step2","_iterator2","describe","acc","add","delete","newItems","removeItems","BaseSchema","deps","transforms","conditions","_mutate","_typeError","_whitelist","_blacklist","exclusiveTests","spec","withMutation","typeError","locale","strip","strict","abortEarly","recursive","nullable","presence","_value","_whitelistError","_blacklistError","cloneDeep","meta","before","combined","mergedSpec","merge","v","_typeCheck","resolvedSchema","_cast","assert","isType","formattedValue","formattedResult","rawValue","_options","_this2","getDefault","_this3","_options$from","_options$originalValu","_options$strict","_options$abortEarly","initialTests","finalTests","maybeCb","_validate","validateSync","defaultValue","_getDefault","def","isStrict","exclusive","_isPresent","isNullable","opts","isExclusive","dep","enums","valids","resolved","resolveAll","invalids","_next$spec","_loop","_getIn","_i2","_arr2","alias","_i3","_arr3","optional","notRequired","Mixed","isAbsent","BooleanSchema","_BaseSchema","transform","Boolean","valueOf","rEmail","rUrl","rUUID","isTrimmed","objStringTag","StringSchema","strValue","_get","regex","excludeEmptyString","_options$excludeEmpty","search","toLowerCase","toUpperCase","NumberSchema","parsed","NaN","parseFloat","Number","less","more","isInteger","_method","avail","truncate","Math","isoReg","invalidDate","DateSchema","timestamp","struct","numericKeys","minutesOffset","exec","UTC","parse","isoParse","param","cast","limit","prepareParam","INVALID_DATE","sortFields","excludedEdges","edges","excludes","addNode","depPath","toposort","Infinity","some","ii","_err$path","sortByKeyOrder","isObject","unknown","known","defaultSort","ObjectSchema","_sortErrors","_nodes","_excludedEdges","shape","_options$stripUnknown","stripUnknown","intermediateValue","innerOptions","__validating","isChanged","prop","exists","fieldValue","inputValue","fieldSpec","_opts$from","_opts$originalValue","_opts$abortEarly","_opts$recursive","_this4","nextFields","_Object$entries","_Object$entries$_i","schemaOrRef","_this5","dft","getDefaultFromShape","additions","picked","_step3","_iterator3","fromGetter","newObj","noAllow","unknownKeys","allow","mapKeys","transformKeys","camelCase","snakeCase","ArraySchema","_opts","castArray","castElement","_options$recursive","original","rejector","useDatetimes","_data$espressoDatetim","useDatetimeQueryOptions","useDatetimesQuery","espressoDatetimes","useMemoStringify","CREATE_PRICE","UPDATE_PRICE","DELETE_PRICE","nativeCreate","getNative","listCacheClear","listCacheDelete","listCacheGet","listCacheHas","listCacheSet","ListCache","eq","isKeyable","__data__","isSymbol","TypeName","baseAssignValue","baseForOwn","baseIteratee","iteratee","Parent","Class","_cache","Wrapper","query","variables","where","queryArgs","includeDefaultTickets","_window","_window$eventEspresso","_window$eventEspresso2","_window$eventEspresso3","eventEspressoData","eventEditor","event","dbId","useUpdateCallback","typeName","onUpdate","mutationType","cache","pathOr","PRICE_BASE_TYPE_ATTRIBUTE","PRICE_TYPE_ATTRIBUTES","GET_PRICE","GET_PRICES","webpackPolyfill","deprecate","paths","children","reIsDeepProp","reIsPlainProp","baseGetTag","isObjectLike","mapCacheClear","mapCacheDelete","mapCacheGet","mapCacheHas","mapCacheSet","MapCache","arrayLikeKeys","baseKeys","isArrayLike","createCompounder","word","ServiceProvider","_jsx","ThemeProvider","StatusProvider","ConfigProvider","FeaturesProvider","RelationsProvider","SlotFillProvider","GlobalModalProvider","ContextProvider","DataProvider","withEdtrContext","Component","DatetimesListProvider","DatesFilterStateProvider","FilteredDatesProvider","TicketsListProvider","TicketsFilterStateProvider","FilteredTicketsProvider","withEntityListContext","Provider","useDatetimeIds","datetimes","getGuids","useDatetimeItem","returnPartialData","useCacheQuery","espressoDatetime","useRelatedDatetimes","entityId","relatedDatetimeIds","getRelations","useRelations","relation","entityListCacheIdString","relatedDatetimeIdsStr","useRelatedPrices","prices","usePrices","relatedPriceIds","relatedPriceIdsStr","UPDATE_EVENT","EVENT_ATTRIBUTES","DisplayStartOrEndDate","usePriceQueryOptions","includeDefaultTicketsPrices","includeDefaultPrices","useUpdateTicketCache","queryOptions","ticketIndex","tickets","action","_tickets$nodes","newNodes","entityHasGuid","update","writeOptions","writeQuery","BULK_DELETE_ENTITIES","useBulkDeleteEntities","entityType","bulkDelete","useMutationWithFeedback","MutationType","Delete","mutation","_ref3","_regeneratorRuntime","_callee","updateEntityList","_context","clientMutationId","_x","_isPlaceholder","f1","mutations","castPath","isArguments","isIndex","isLength","toKey","hasFunc","isKey","stringToPath","global","funcToString","func","other","baseIsArguments","objectProto","reIsUint","baseFor","stubFalse","freeExports","freeModule","Buffer","isBuffer","baseIsTypedArray","baseUnary","nodeUtil","nodeIsTypedArray","isTypedArray","baseMatches","baseMatchesProperty","identity","stackClear","stackDelete","stackGet","stackHas","stackSet","Stack","baseIsEqualDeep","baseIsEqual","bitmask","customizer","stack","SetCache","arraySome","cacheHas","equalFunc","isPartial","arrLength","othLength","arrStacked","othStacked","seen","arrValue","othValue","compared","othIndex","srcValue","arrayReduce","deburr","words","reApos","reHasUnicode","GET_EVENT","_data$espressoPrices","usePricesQuery","espressoPrices","usePriceTypeQueryOptions","GET_PRICE_TYPES","useVenueQueryOptions","GET_VENUES","DatesFilterStateContext","createContext","DatesFilterStateConsumer","Consumer","filterState","useDatesListFilterStateManager","FilteredDatesContext","FilteredDatesConsumer","useDatesListFilterState","filteredEntities","useFilteredEntities","filteredEntityIds","_useVisibleDatetimeId","useVisibleDatetimeIds","setVisibleDatetimeIds","TicketsFilterStateContext","TicketsFilterStateConsumer","useTicketsListFilterStateManager","FilteredTicketsContext","FilteredTicketsConsumer","useTicketsListFilterState","_useVisibleTicketIds","useVisibleTicketIds","setVisibleTicketIds","capitalize","cursor","sorted","visited","outgoingEdges","edge","makeOutgoingEdges","nodesHash","res","makeNodesHash","visit","predecessors","nodeRep","outgoing","child","uniqueNodes","useUpdateDatetimeList","useUpdateTicketList","useDefaultTickets","isDefault","useDefaultTicketIds","useTicketIds","useTicketItem","espressoTicket","useTicketPrices","ticketId","relatedPricesIds","useCappedQuantity","allDates","capacity","quantity","_ref$relatedDateIds","relatedDateIds","dateIdsToUse","minimumCapacity","R","minDateCapacity","ticketQuantityFromCapacity","usePriceTypes","_data$espressoPriceTy","espressoPriceTypes","useDefaultPriceType","allPriceTypes","defaultPriceType","getDefaultPriceModifierType","usePriceTypeForPrice","priceId","relatedPriceTypeIds","relatedPriceTypes","priceType","isEmpty","useDeleteRelatedTickets","deleteTickets","useBulkDeleteTickets","datetimeId","relatedTicketIds","ticketIdsRelatedOnlyToTheDate","deleteRemotely","_x2","hooks","getHooks","useBulkEditTickets","allTickets","updateTicketList","onUpdateTicket","useOnUpdateTicket","affectedDatesQueries","useAffectedDatesQueries","updateTickets","Update","updateInput","datetimeIds","priceIds","updateEntities","refetchQueries","unnest","useEventGuid","useEventQueryOptions","GET_PRICE_TYPE","useUpdateDatetimeCache","datetimeIndex","datetime","_datetimes$nodes","updateTicketCache","_data","datetimeIn","sortBy","readQuery","newDatetimeIn","useOnUpdateDatetime","_useRelations","addRelation","removeRelation","updateRelations","hasTempId","relationIds","relationId","useOnDeleteDatetime","dropRelations","updateDatetimeCache","useOnDeleteTicket","ticketIn","updatePriceCache","newTicketIn","_ref$prices","priceNodes","pathToNodes","existingPrices","newPrices","uniqBy","entityDbId","assocPath","REORDER_ENTITIES","useReorderEntities","_useState","useState","_useState2","allEntityGuids","setAllEntityGuids","_useState3","_useState4","allReorderedEntities","setAllOrderedEntities","_useMutation","useMutation","_useMutation2","mutate","updateSortOrder","success","sortEntities","allEntitiesList","newIndex","oldIndex","_ref4","_entityIds$splice","splice","removed","entities","indexInAll","_allEntities$splice","order","_ref$mutationType","oldDatetimeIds","nativeObjectToString","isOwn","unmasked","memoizeCapped","rePropName","reEscapeChar","charCodeAt","quote","subString","memoize","resolver","memoized","Hash","hashClear","hashDelete","hashGet","hashHas","hashSet","isFunction","isMasked","toSource","reIsHostCtor","funcProto","reIsNative","coreJsData","maskSrcKey","uid","IE_PROTO","assocIndexOf","getMapData","arrayMap","symbolProto","createBaseFor","fromRight","keysFunc","baseTimes","inherited","isArr","isArg","isBuff","skipIndexes","typedArrayTags","freeProcess","process","types","binding","isPrototype","nativeKeys","Ctor","overArg","baseIsMatch","getMatchData","matchesStrictComparable","matchData","noCustomizer","objValue","COMPARE_PARTIAL_FLAG","pairs","LARGE_ARRAY_SIZE","equalArrays","equalByTag","equalObjects","getTag","argsTag","arrayTag","objectTag","objIsArr","othIsArr","objTag","othTag","objIsObj","othIsObj","isSameTag","objIsWrapped","othIsWrapped","objUnwrapped","othUnwrapped","setCacheAdd","setCacheHas","predicate","Uint8Array","mapToArray","setToArray","symbolValueOf","byteLength","byteOffset","buffer","convert","stacked","getAllKeys","objProps","objLength","objStacked","skipCtor","objCtor","othCtor","baseGetAllKeys","getSymbols","arrayPush","symbolsFunc","offset","arrayFilter","stubArray","nativeGetSymbols","symbol","resIndex","DataView","WeakMap","mapTag","promiseTag","setTag","weakMapTag","dataViewTag","dataViewCtorString","mapCtorString","promiseCtorString","setCtorString","weakMapCtorString","ArrayBuffer","ctorString","isStrictComparable","hasIn","baseGet","baseHasIn","baseProperty","basePropertyDeep","accumulator","initAccum","deburrLetter","reLatin","reComboMark","basePropertyOf","asciiWords","hasUnicodeWord","unicodeWords","pattern","guard","reAsciiWord","reHasUnicodeWord","rsDingbatRange","rsLowerRange","rsUpperRange","rsBreakRange","rsMathOpRange","rsBreak","rsDigits","rsDingbat","rsLower","rsMisc","rsRegional","rsSurrPair","rsUpper","rsMiscLower","rsMiscUpper","rsOptContrLower","rsOptContrUpper","reOptMod","rsModifier","rsOptVar","rsSeq","rsEmoji","reUnicodeWord","upperFirst","createCaseFirst","castSlice","hasUnicode","stringToArray","methodName","strSymbols","chr","trailing","baseSlice","start","end","asciiToArray","unicodeToArray","rsAstral","rsCombo","rsFitz","rsNonAstral","rsSymbol","reUnicode","useVenues","_data$espressoVenues","useVenuesQuery","venues","espressoVenues","sortedVenues","collator","Intl","Collator","numeric","sensitivity","compare","useLazyDatetime","getData","useLazyCacheQuery","useLazyTicket","useRelatedTickets","VENUE_ATTRIBUTES","GET_VENUE","useUpdatePriceList","onDeleteTicket","useApolloClient","DEFAULT_LIST_DATA","findTicket","findEntityByGuid","filteredTickets","finalDatetimeIn","_ref2$deleteRemotely","_ref2$relatedDatetime","updateTheEntityList","useContext","invariant","visibleDatetimeIds","makeVar","useReactiveVariable","visibleTicketIds","reducer","displayStartOrEndDate","sales","status","recurrence","initialState","DatetimeSales","all","DatetimeStatus","activeUpcoming","_useSessionStorageRed","useSessionStorageReducer","_useSessionStorageRed2","dispatch","entityFilterState","useEntityListFilterStateManager","setPageNumber","resetPageNumber","setDisplayStartOrEndDate","setSales","setStatus","setRecurrence","isChained","TicketsSales","TicketsStatus","onSaleAndPending","visibleDatesStr","setVisibleDatesStr","toggleIsChained","useEvent","espressoEvent","_has","_isArguments","x","useUpdatePriceTypeList","useUpdateVenueList","useBulkEditDatetimes","allDatetimes","updateDatetimeList","onUpdateDatetime","updateDatetimes","useBulkDeleteDatetimes","onDeleteDatetime","deleteRelatedTickets","findDatetime","filteredDatetimes","_entityId","t0","_callee2","_context2","useReorderDatetimes","allUpdatedEntities","setAllUpdatedEntities","getDatetime","_useReorderEntities","sortResponder","destination","noDestination","noChange","droppableId","notOurListOfInterest","datetimesDroppableId","allSortedEntities","useReorderTickets","getTicket","ticketDroppableId","useUpdateTicketQtyByCapacity","getRelatedTickets","bulkEditTickets","createBulkQtyUpdateInput","ticketIdsToUpdate","ticketsToUpdate","parseInfinity","getTicketQuantityFromCapacity","nonNegativeTicketQuantity","isInfinite","doQtyBulkUpdate","uniqInputs","showNotice","_args","uniqTicketsByMinQty","useBulkDeletePrices","allPrices","updatePriceList","Price","DateStatus","PriceBasetype","isDatetime","useFilteredDateIds","useFilteredTicketIds","EdtrGlobalModals","QueryURLRegStatus","useMutationVariables","useUpdatePriceCache","priceIndex","_prices$nodes","useOnCreatePrice","priceTypeId","useOnDeletePrice","useOnUpdatePrice","NUMERIC_FIELDS","BOOLEAN_FIELDS","useMutationHandler","onCreatePrice","onUpdatePrice","onDeletePrice","getMutationVariables","Create","filteredInput","removeNullAndUndefined","normalizedInput","normalizeNumericFields","normalizeBooleanFields","usePriceMutator","createPrice","updatePrice","deletePrice","mutationHandler","getUpdateCallback","createEntity","_mutationHandler","updateEntity","_mutationHandler2","deleteEntity","_mutationHandler3","mutationInput","useOnCreateDatetime","DATETIME_DEFAULTS","PLUS_TWO_MONTHS","isPrimary","isSoldOut","reserved","sold","PLUS_ONE_MONTH","venue","useOptimisticResponse","lcMutationtype","ucFirstMutationtype","ucFirst","onCreateDatetime","getOptimisticResponse","optimisticResponse","useDatetimeMutator","createDatetime","updateDatetime","deleteDatetime","Datetime","useOnCreateTicket","TICKET_DEFAULTS","isRequired","registrationCount","reverseCalculate","userId","uses","visibility","onCreateTicket","doAction","useTicketMutator","createTicket","updateTicket","deleteTicket","Ticket","startAndEndDateFixer","form","previousValues","subscribe","batch","_form$getFieldState","_form$getFieldState2","_form$getFieldState2$","prevStartDate","prevEndDate","startDateChanged","endDateChanged","isEndDateNotPristine","getFieldState","pristine","changedFromStartDate","endDateFieldNotice","newEndDate","mayBeAdjustEndDate","newStartDate","change","mutators","setFieldData","fieldNotice","requiredMessage","datesSchema","yup","when","endDateAfterStartDateErrorMessage","filterCellByStartOrEndDate","cell","getEdtrDomData","useCacheRehydrationData","_window2","_window2$eventEspress","currentUser","generalSettings","useCacheRehydration","setIsLoaded","useStatus","initializeRelations","initialize","relationsInitialized","isInitialized","_useCacheRehydrationD","_useIsRehydrated","useIsRehydrated","_useIsRehydrated2","isRehydrated","setIsRehydrated","_eventEditor$datetime","_eventEditor$tickets","_eventEditor$prices","_eventEditor$priceTyp","priceTypes","_eventEditor$venues","relations","priceTypeQueryOptions","updatePriceTypeList","datetimeQueryOptions","ticketQueryOptions","priceQueryOptions","venueQueryOptions","updateVenueList","currentUserQueryOptions","useCurrentUserQueryOptions","updateCurrentUser","useUpdateCurrentUserCache","generalSettingsQueryOptions","useGeneralSettingsQueryOptions","updateGeneralSettings","useUpdateGeneralSettingsCache","eventQueryOptions","updateCache","viewer","manager","createVariables","useEventMutator","updateEvent","_createSlotFill","createSlotFill","NewDateOptions","Slot","NewDateOption","Fill","ticketsMeta","useTicketsMeta","useEntityMeta","useEventManagers","eventManagers","useIsChainedFilter","pickBy","registerTicketsFilter","FilterBarService","registerFilter","useRegisterIsChainedFilter","_useIsChainedFilter","_useIsChainedFilter2","isChainedFilter","isChainedDeps","unSubIsChainedFilterRef","useRef","_unSubIsChainedFilter","unSubscribeIsChainedFilter","entityList","_unSubIsChainedFilter2","_curry1","empty","equals","_isArray","_isObject","_isString","_curry2","_equals","f2","_b","_a","_arrayFromIterator","_includesWith","_functionName","_objectIs","_uniqContentEquals","aIterator","bIterator","stackA","stackB","aItem","typeA","ignoreCase","multiline","sticky","unicode","keysA","extendedStackA","extendedStackB","pred","hasEnumBug","nonEnumerableProps","hasArgsEnumBug","contains","nIdx","ks","checkArgsLength"],"mappings":";sFACE,IAAIA,EAAmB,GAGvB,SAASC,EAAoBC,GAG5B,GAAGF,EAAiBE,GACnB,OAAOF,EAAiBE,GAAUC,QAGnC,IAAIC,EAASJ,EAAiBE,GAAY,CACzCG,EAAGH,EACHI,GAAG,EACHH,QAAS,IAUV,OANAI,EAAQL,GAAUM,KAAKJ,EAAOD,QAASC,EAAQA,EAAOD,QAASF,GAG/DG,EAAOE,GAAI,EAGJF,EAAOD,QA0Df,OArDAF,EAAoBQ,EAAIF,EAGxBN,EAAoBS,EAAIV,EAGxBC,EAAoBU,EAAI,SAASR,EAASS,EAAMC,GAC3CZ,EAAoBa,EAAEX,EAASS,IAClCG,OAAOC,eAAeb,EAASS,EAAM,CAAEK,YAAY,EAAMC,IAAKL,KAKhEZ,EAAoBkB,EAAI,SAAShB,GACX,qBAAXiB,QAA0BA,OAAOC,aAC1CN,OAAOC,eAAeb,EAASiB,OAAOC,YAAa,CAAEC,MAAO,WAE7DP,OAAOC,eAAeb,EAAS,aAAc,CAAEmB,OAAO,KAQvDr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ACE,aAEA,OAAOloD,UAAUW,qBAAqB,UAHxC,GAMIwnD,EAAW,SAAkB/kC,EAAMxB,GAGrC,IAFA,IAAIjU,EAAM,EAEHA,EAAMyV,EAAKnjB,QAAQ,CACxB,GAAImjB,EAAKzV,KAASiU,EAChB,OAAO,EAGTjU,GAAO,EAGT,OAAO,GAsBLrO,EAA8B,oBAAhB1B,OAAO0B,MAAwB4oD,EAMjDhC,GAAQ,SAAcrkD,GACpB,GAAIjE,OAAOiE,KAASA,EAClB,MAAO,GAGT,IAAI2rB,EAAM46B,EACNC,EAAK,GAELC,EAAkBJ,GAAkB5Q,EAAaz1C,GAErD,IAAK2rB,KAAQ3rB,GACPw1C,EAAK7pB,EAAM3rB,IAAUymD,GAA4B,WAAT96B,IAC1C66B,EAAGA,EAAGpoD,QAAUutB,GAIpB,GAAIw6B,EAGF,IAFAI,EAAOH,EAAmBhoD,OAAS,EAE5BmoD,GAAQ,GAGT/Q,EAFJ7pB,EAAOy6B,EAAmBG,GAEXvmD,KAASsmD,EAASE,EAAI76B,KACnC66B,EAAGA,EAAGpoD,QAAUutB,GAGlB46B,GAAQ,EAIZ,OAAOC,KAlCTnC,GAAQ,SAAcrkD,GACpB,OAAOjE,OAAOiE,KAASA,EAAM,GAAKjE,OAAO0B,KAAKuC,MAmChD5E,EAAOD,QAAUsC,G,gBCnGjB,IA8BIkK,EA5BJrK,EAAQ,IA8BR+mD,EAAQ,SAAcl/C,GACpB,OAAe,OAARA,EAAe,YAAiB5F,IAAR4F,EAAoB,YAAcpJ,OAAOkB,UAAUgE,SAASzF,KAAK2J,GAAKjE,MAAM,GAAI,MAGjH9F,EAAOD,QAAUwM","file":"static/js/edtrServices.67147781.js","sourcesContent":[" \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"/\";\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 1530);\n","(function() { module.exports = window[\"React\"]; }());","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-jsx-runtime.production.min.js');\n} else {\n module.exports = require('./cjs/react-jsx-runtime.development.js');\n}\n","import defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\n\nfunction ownKeys(object, enumerableOnly) {\n var keys = Object.keys(object);\n\n if (Object.getOwnPropertySymbols) {\n var symbols = Object.getOwnPropertySymbols(object);\n if (enumerableOnly) symbols = symbols.filter(function (sym) {\n return Object.getOwnPropertyDescriptor(object, sym).enumerable;\n });\n keys.push.apply(keys, symbols);\n }\n\n return keys;\n}\n\nexport default function _objectSpread2(target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i] != null ? arguments[i] : {};\n\n if (i % 2) {\n ownKeys(Object(source), true).forEach(function (key) {\n defineProperty(target, key, source[key]);\n });\n } else if (Object.getOwnPropertyDescriptors) {\n Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));\n } else {\n ownKeys(Object(source)).forEach(function (key) {\n Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));\n });\n }\n }\n\n return target;\n}","(function() { module.exports = window[\"eventespresso\"][\"i18n\"]; }());","(function() { module.exports = window[\"R\"]; }());","import objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nexport default function _objectWithoutProperties(source, excluded) {\n if (source == null) return {};\n var target = objectWithoutPropertiesLoose(source, excluded);\n var key, i;\n\n if (Object.getOwnPropertySymbols) {\n var sourceSymbolKeys = Object.getOwnPropertySymbols(source);\n\n for (i = 0; i < sourceSymbolKeys.length; i++) {\n key = sourceSymbolKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;\n target[key] = source[key];\n }\n }\n\n return target;\n}","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n\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\n return target;\n}","import arrayWithHoles from \"@babel/runtime/helpers/esm/arrayWithHoles\";\nimport iterableToArrayLimit from \"@babel/runtime/helpers/esm/iterableToArrayLimit\";\nimport unsupportedIterableToArray from \"@babel/runtime/helpers/esm/unsupportedIterableToArray\";\nimport nonIterableRest from \"@babel/runtime/helpers/esm/nonIterableRest\";\nexport default function _slicedToArray(arr, i) {\n return arrayWithHoles(arr) || iterableToArrayLimit(arr, i) || unsupportedIterableToArray(arr, i) || nonIterableRest();\n}","export default function _iterableToArrayLimit(arr, i) {\n if (typeof Symbol === \"undefined\" || !(Symbol.iterator in Object(arr))) return;\n var _arr = [];\n var _n = true;\n var _d = false;\n var _e = undefined;\n\n try {\n for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) {\n _arr.push(_s.value);\n\n if (i && _arr.length === i) break;\n }\n } catch (err) {\n _d = true;\n _e = err;\n } finally {\n try {\n if (!_n && _i[\"return\"] != null) _i[\"return\"]();\n } finally {\n if (_d) throw _e;\n }\n }\n\n return _arr;\n}","(function() { module.exports = window[\"eventespresso\"][\"predicates\"]; }());","export default function _defineProperty(obj, key, value) {\n if (key in obj) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n } else {\n obj[key] = value;\n }\n\n return obj;\n}","(function() { module.exports = window[\"eventespresso\"][\"utils\"]; }());","(function() { module.exports = window[\"eventespresso\"][\"data\"]; }());","(function() { module.exports = window[\"eventespresso\"][\"services\"]; }());","(function() { module.exports = window[\"eventespresso\"][\"hooks\"]; }());","(function() { module.exports = window[\"eventespresso\"][\"adapters\"]; }());","import arrayWithoutHoles from \"@babel/runtime/helpers/esm/arrayWithoutHoles\";\nimport iterableToArray from \"@babel/runtime/helpers/esm/iterableToArray\";\nimport unsupportedIterableToArray from \"@babel/runtime/helpers/esm/unsupportedIterableToArray\";\nimport nonIterableSpread from \"@babel/runtime/helpers/esm/nonIterableSpread\";\nexport default function _toConsumableArray(arr) {\n return arrayWithoutHoles(arr) || iterableToArray(arr) || unsupportedIterableToArray(arr) || nonIterableSpread();\n}","import arrayLikeToArray from \"@babel/runtime/helpers/esm/arrayLikeToArray\";\nexport default function _arrayWithoutHoles(arr) {\n if (Array.isArray(arr)) return arrayLikeToArray(arr);\n}","export default function _nonIterableSpread() {\n throw new TypeError(\"Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}","module.exports = require(\"regenerator-runtime\");\n","(function() { module.exports = window[\"eventespresso\"][\"constants\"]; }());","export default function _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n}","export default function _arrayLikeToArray(arr, len) {\n if (len == null || len > arr.length) len = arr.length;\n\n for (var i = 0, arr2 = new Array(len); i < len; i++) {\n arr2[i] = arr[i];\n }\n\n return arr2;\n}","import arrayLikeToArray from \"@babel/runtime/helpers/esm/arrayLikeToArray\";\nexport default function _unsupportedIterableToArray(o, minLen) {\n if (!o) return;\n if (typeof o === \"string\") return arrayLikeToArray(o, minLen);\n var n = Object.prototype.toString.call(o).slice(8, -1);\n if (n === \"Object\" && o.constructor) n = o.constructor.name;\n if (n === \"Map\" || n === \"Set\") return Array.from(o);\n if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return arrayLikeToArray(o, minLen);\n}","function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {\n try {\n var info = gen[key](arg);\n var value = info.value;\n } catch (error) {\n reject(error);\n return;\n }\n\n if (info.done) {\n resolve(value);\n } else {\n Promise.resolve(value).then(_next, _throw);\n }\n}\n\nexport default function _asyncToGenerator(fn) {\n return function () {\n var self = this,\n args = arguments;\n return new Promise(function (resolve, reject) {\n var gen = fn.apply(self, args);\n\n function _next(value) {\n asyncGeneratorStep(gen, resolve, reject, _next, _throw, \"next\", value);\n }\n\n function _throw(err) {\n asyncGeneratorStep(gen, resolve, reject, _next, _throw, \"throw\", err);\n }\n\n _next(undefined);\n });\n };\n}","(function() { module.exports = window[\"eventespresso\"][\"registry\"]; }());","export default function _getPrototypeOf(o) {\n _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) {\n return o.__proto__ || Object.getPrototypeOf(o);\n };\n return _getPrototypeOf(o);\n}","function _defineProperties(target, props) {\n for (var i = 0; i < props.length; i++) {\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n Object.defineProperty(target, descriptor.key, descriptor);\n }\n}\n\nexport default function _createClass(Constructor, protoProps, staticProps) {\n if (protoProps) _defineProperties(Constructor.prototype, protoProps);\n if (staticProps) _defineProperties(Constructor, staticProps);\n return Constructor;\n}","export default function _taggedTemplateLiteral(strings, raw) {\n if (!raw) {\n raw = strings.slice(0);\n }\n\n return Object.freeze(Object.defineProperties(strings, {\n raw: {\n value: Object.freeze(raw)\n }\n }));\n}","(function() { module.exports = window[\"eventespresso\"][\"dates\"]; }());","import setPrototypeOf from \"@babel/runtime/helpers/esm/setPrototypeOf\";\nexport default function _inherits(subClass, superClass) {\n if (typeof superClass !== \"function\" && superClass !== null) {\n throw new TypeError(\"Super expression must either be null or a function\");\n }\n\n subClass.prototype = Object.create(superClass && superClass.prototype, {\n constructor: {\n value: subClass,\n writable: true,\n configurable: true\n }\n });\n if (superClass) setPrototypeOf(subClass, superClass);\n}","import _typeof from \"@babel/runtime/helpers/esm/typeof\";\nimport assertThisInitialized from \"@babel/runtime/helpers/esm/assertThisInitialized\";\nexport default function _possibleConstructorReturn(self, call) {\n if (call && (_typeof(call) === \"object\" || typeof call === \"function\")) {\n return call;\n }\n\n return assertThisInitialized(self);\n}","import getPrototypeOf from \"@babel/runtime/helpers/esm/getPrototypeOf\";\nimport isNativeReflectConstruct from \"@babel/runtime/helpers/esm/isNativeReflectConstruct\";\nimport possibleConstructorReturn from \"@babel/runtime/helpers/esm/possibleConstructorReturn\";\nexport default function _createSuper(Derived) {\n var hasNativeReflectConstruct = isNativeReflectConstruct();\n return function _createSuperInternal() {\n var Super = getPrototypeOf(Derived),\n result;\n\n if (hasNativeReflectConstruct) {\n var NewTarget = getPrototypeOf(this).constructor;\n result = Reflect.construct(Super, arguments, NewTarget);\n } else {\n result = Super.apply(this, arguments);\n }\n\n return possibleConstructorReturn(this, result);\n };\n}","export default function _arrayWithHoles(arr) {\n if (Array.isArray(arr)) return arr;\n}","export default function _nonIterableRest() {\n throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}","import superPropBase from \"@babel/runtime/helpers/esm/superPropBase\";\nexport default function _get(target, property, receiver) {\n if (typeof Reflect !== \"undefined\" && Reflect.get) {\n _get = Reflect.get;\n } else {\n _get = function _get(target, property, receiver) {\n var base = superPropBase(target, property);\n if (!base) return;\n var desc = Object.getOwnPropertyDescriptor(base, property);\n\n if (desc.get) {\n return desc.get.call(receiver);\n }\n\n return desc.value;\n };\n }\n\n return _get(target, property, receiver || target);\n}","import getPrototypeOf from \"@babel/runtime/helpers/esm/getPrototypeOf\";\nexport default function _superPropBase(object, property) {\n while (!Object.prototype.hasOwnProperty.call(object, property)) {\n object = getPrototypeOf(object);\n if (object === null) break;\n }\n\n return object;\n}","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n/**\n * Use invariant() to assert state which your program assumes to be true.\n *\n * Provide sprintf-style format (only %s is supported) and arguments\n * to provide information about what broke and what you were\n * expecting.\n *\n * The invariant message will be stripped in production, but the invariant\n * will remain to ensure logic does not differ in production.\n */\n\nvar invariant = function(condition, format, a, b, c, d, e, f) {\n if (process.env.NODE_ENV !== 'production') {\n if (format === undefined) {\n throw new Error('invariant requires an error message argument');\n }\n }\n\n if (!condition) {\n var error;\n if (format === undefined) {\n error = new Error(\n 'Minified exception occurred; use the non-minified dev environment ' +\n 'for the full error message and additional helpful warnings.'\n );\n } else {\n var args = [a, b, c, d, e, f];\n var argIndex = 0;\n error = new Error(\n format.replace(/%s/g, function() { return args[argIndex++]; })\n );\n error.name = 'Invariant Violation';\n }\n\n error.framesToPop = 1; // we don't care about invariant's own frame\n throw error;\n }\n};\n\nmodule.exports = invariant;\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","export default function _iterableToArray(iter) {\n if (typeof Symbol !== \"undefined\" && Symbol.iterator in Object(iter)) return Array.from(iter);\n}","import type { Ticket } from '@eventespresso/edtr-services';\nimport { __ } from '@eventespresso/i18n';\n\nexport const domain = 'eventEditor';\n\nexport const datesList = 'dates-list';\n\nexport const ticketsList = 'tickets-list';\n\nexport const TICKET_FIELDS_FOR_TPC: Array = [\n\t'id',\n\t'name',\n\t'description',\n\t'price',\n\t'quantity',\n\t'reverseCalculate',\n\t'visibility',\n];\n\n/**\n * Translated singular entity names\n */\nexport const SINGULAR_ENTITY_NAME = {\n\tDATETIME: __('datetime'),\n\tEVENT: __('event'),\n\tTICKET: __('ticket'),\n\tPRICE: __('price'),\n\tPRICE_TYPE: __('price type'),\n};\n","/** @license React v17.0.2\n * react-jsx-runtime.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';require(\"object-assign\");var f=require(\"react\"),g=60103;exports.Fragment=60107;if(\"function\"===typeof Symbol&&Symbol.for){var h=Symbol.for;g=h(\"react.element\");exports.Fragment=h(\"react.fragment\")}var m=f.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,n=Object.prototype.hasOwnProperty,p={key:!0,ref:!0,__self:!0,__source:!0};\nfunction q(c,a,k){var b,d={},e=null,l=null;void 0!==k&&(e=\"\"+k);void 0!==a.key&&(e=\"\"+a.key);void 0!==a.ref&&(l=a.ref);for(b in a)n.call(a,b)&&!p.hasOwnProperty(b)&&(d[b]=a[b]);if(c&&c.defaultProps)for(b in a=c.defaultProps,a)void 0===d[b]&&(d[b]=a[b]);return{$$typeof:g,type:c,key:e,ref:l,props:d,_owner:m.current}}exports.jsx=q;exports.jsxs=q;\n","import type { DatetimeEdge, TicketEdge, PriceEdge, PriceTypeEdge, VenueEdge } from '../types';\nimport { EntityEdge } from '@eventespresso/data';\n\nexport const DEFAULT_ENTITY_LIST_DATA: EntityEdge = {\n\tnodes: [],\n\t__typename: '',\n};\n\nexport const DEFAULT_DATETIME_LIST_DATA: DatetimeEdge = {\n\tnodes: [],\n\t__typename: 'EspressoRootQueryDatetimesConnection',\n};\n\nexport const DEFAULT_TICKET_LIST_DATA: TicketEdge = {\n\tnodes: [],\n\t__typename: 'EspressoRootQueryTicketsConnection',\n};\n\nexport const DEFAULT_PRICE_LIST_DATA: PriceEdge = {\n\tnodes: [],\n\t__typename: 'EspressoRootQueryPricesConnection',\n};\n\nexport const DEFAULT_PRICE_TYPE_LIST_DATA: PriceTypeEdge = {\n\tnodes: [],\n\t__typename: 'EspressoRootQueryPriceTypesConnection',\n};\n\nexport const DEFAULT_VENUE_LIST_DATA: VenueEdge = {\n\tnodes: [],\n\t__typename: 'RootQueryToEspressoVenueConnection',\n};\n\nexport * from './datetimes';\n\nexport * from './events';\n\nexport * from './tickets';\n\nexport * from './prices';\n\nexport * from './priceTypes';\n\nexport * from './users';\n\nexport * from './venues';\n\nexport * from './types';\n","import unsupportedIterableToArray from \"@babel/runtime/helpers/esm/unsupportedIterableToArray\";\nexport default function _createForOfIteratorHelper(o, allowArrayLike) {\n var it;\n\n if (typeof Symbol === \"undefined\" || o[Symbol.iterator] == null) {\n if (Array.isArray(o) || (it = unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === \"number\") {\n if (it) o = it;\n var i = 0;\n\n var F = function F() {};\n\n return {\n s: F,\n n: function n() {\n if (i >= o.length) return {\n done: true\n };\n return {\n done: false,\n value: o[i++]\n };\n },\n e: function e(_e) {\n throw _e;\n },\n f: F\n };\n }\n\n throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n }\n\n var normalCompletion = true,\n didErr = false,\n err;\n return {\n s: function s() {\n it = o[Symbol.iterator]();\n },\n n: function n() {\n var step = it.next();\n normalCompletion = step.done;\n return step;\n },\n e: function e(_e2) {\n didErr = true;\n err = _e2;\n },\n f: function f() {\n try {\n if (!normalCompletion && it[\"return\"] != null) it[\"return\"]();\n } finally {\n if (didErr) throw err;\n }\n }\n };\n}","export default function _assertThisInitialized(self) {\n if (self === void 0) {\n throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\");\n }\n\n return self;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n\n return _setPrototypeOf(o, p);\n}","export default function _typeof(obj) {\n \"@babel/helpers - typeof\";\n\n if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") {\n _typeof = function _typeof(obj) {\n return typeof obj;\n };\n } else {\n _typeof = function _typeof(obj) {\n return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj;\n };\n }\n\n return _typeof(obj);\n}","export default function _isNativeReflectConstruct() {\n if (typeof Reflect === \"undefined\" || !Reflect.construct) return false;\n if (Reflect.construct.sham) return false;\n if (typeof Proxy === \"function\") return true;\n\n try {\n Date.prototype.toString.call(Reflect.construct(Date, [], function () {}));\n return true;\n } catch (e) {\n return false;\n }\n}","var freeGlobal = require('./_freeGlobal');\n\n/** Detect free variable `self`. */\nvar freeSelf = typeof self == 'object' && self && self.Object === Object && self;\n\n/** Used as a reference to the global object. */\nvar root = freeGlobal || freeSelf || Function('return this')();\n\nmodule.exports = root;\n","/**\n * Checks if `value` is classified as an `Array` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an array, else `false`.\n * @example\n *\n * _.isArray([1, 2, 3]);\n * // => true\n *\n * _.isArray(document.body.children);\n * // => false\n *\n * _.isArray('abc');\n * // => false\n *\n * _.isArray(_.noop);\n * // => false\n */\nvar isArray = Array.isArray;\n\nmodule.exports = isArray;\n","/**\n * Based on Kendo UI Core expression code \n */\n'use strict'\n\nfunction Cache(maxSize) {\n this._maxSize = maxSize\n this.clear()\n}\nCache.prototype.clear = function () {\n this._size = 0\n this._values = Object.create(null)\n}\nCache.prototype.get = function (key) {\n return this._values[key]\n}\nCache.prototype.set = function (key, value) {\n this._size >= this._maxSize && this.clear()\n if (!(key in this._values)) this._size++\n\n return (this._values[key] = value)\n}\n\nvar SPLIT_REGEX = /[^.^\\]^[]+|(?=\\[\\]|\\.\\.)/g,\n DIGIT_REGEX = /^\\d+$/,\n LEAD_DIGIT_REGEX = /^\\d/,\n SPEC_CHAR_REGEX = /[~`!#$%\\^&*+=\\-\\[\\]\\\\';,/{}|\\\\\":<>\\?]/g,\n CLEAN_QUOTES_REGEX = /^\\s*(['\"]?)(.*?)(\\1)\\s*$/,\n MAX_CACHE_SIZE = 512\n\nvar pathCache = new Cache(MAX_CACHE_SIZE),\n setCache = new Cache(MAX_CACHE_SIZE),\n getCache = new Cache(MAX_CACHE_SIZE)\n\nvar config\n\nmodule.exports = {\n Cache: Cache,\n\n split: split,\n\n normalizePath: normalizePath,\n\n setter: function (path) {\n var parts = normalizePath(path)\n\n return (\n setCache.get(path) ||\n setCache.set(path, function setter(obj, value) {\n var index = 0\n var len = parts.length\n var data = obj\n\n while (index < len - 1) {\n var part = parts[index]\n if (\n part === '__proto__' ||\n part === 'constructor' ||\n part === 'prototype'\n ) {\n return obj\n }\n\n data = data[parts[index++]]\n }\n data[parts[index]] = value\n })\n )\n },\n\n getter: function (path, safe) {\n var parts = normalizePath(path)\n return (\n getCache.get(path) ||\n getCache.set(path, function getter(data) {\n var index = 0,\n len = parts.length\n while (index < len) {\n if (data != null || !safe) data = data[parts[index++]]\n else return\n }\n return data\n })\n )\n },\n\n join: function (segments) {\n return segments.reduce(function (path, part) {\n return (\n path +\n (isQuoted(part) || DIGIT_REGEX.test(part)\n ? '[' + part + ']'\n : (path ? '.' : '') + part)\n )\n }, '')\n },\n\n forEach: function (path, cb, thisArg) {\n forEach(Array.isArray(path) ? path : split(path), cb, thisArg)\n },\n}\n\nfunction normalizePath(path) {\n return (\n pathCache.get(path) ||\n pathCache.set(\n path,\n split(path).map(function (part) {\n return part.replace(CLEAN_QUOTES_REGEX, '$2')\n })\n )\n )\n}\n\nfunction split(path) {\n return path.match(SPLIT_REGEX)\n}\n\nfunction forEach(parts, iter, thisArg) {\n var len = parts.length,\n part,\n idx,\n isArray,\n isBracket\n\n for (idx = 0; idx < len; idx++) {\n part = parts[idx]\n\n if (part) {\n if (shouldBeQuoted(part)) {\n part = '\"' + part + '\"'\n }\n\n isBracket = isQuoted(part)\n isArray = !isBracket && /^\\d+$/.test(part)\n\n iter.call(thisArg, part, isBracket, isArray, idx, parts)\n }\n }\n}\n\nfunction isQuoted(str) {\n return (\n typeof str === 'string' && str && [\"'\", '\"'].indexOf(str.charAt(0)) !== -1\n )\n}\n\nfunction hasLeadingNumber(part) {\n return part.match(LEAD_DIGIT_REGEX) && !part.match(DIGIT_REGEX)\n}\n\nfunction hasSpecialChars(part) {\n return SPEC_CHAR_REGEX.test(part)\n}\n\nfunction shouldBeQuoted(part) {\n return !isQuoted(part) && (hasLeadingNumber(part) || hasSpecialChars(part))\n}\n","(function() { module.exports = window[\"eventespresso\"][\"ioc\"]; }());","var baseIsNative = require('./_baseIsNative'),\n getValue = require('./_getValue');\n\n/**\n * Gets the native function at `key` of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {string} key The key of the method to get.\n * @returns {*} Returns the function if it's native, else `undefined`.\n */\nfunction getNative(object, key) {\n var value = getValue(object, key);\n return baseIsNative(value) ? value : undefined;\n}\n\nmodule.exports = getNative;\n","var baseHas = require('./_baseHas'),\n hasPath = require('./_hasPath');\n\n/**\n * Checks if `path` is a direct property of `object`.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Object\n * @param {Object} object The object to query.\n * @param {Array|string} path The path to check.\n * @returns {boolean} Returns `true` if `path` exists, else `false`.\n * @example\n *\n * var object = { 'a': { 'b': 2 } };\n * var other = _.create({ 'a': _.create({ 'b': 2 }) });\n *\n * _.has(object, 'a');\n * // => true\n *\n * _.has(object, 'a.b');\n * // => true\n *\n * _.has(object, ['a', 'b']);\n * // => true\n *\n * _.has(other, 'a');\n * // => false\n */\nfunction has(object, path) {\n return object != null && hasPath(object, path, baseHas);\n}\n\nmodule.exports = has;\n","var g;\n\n// This works in non-strict mode\ng = (function() {\n\treturn this;\n})();\n\ntry {\n\t// This works if eval is allowed (see CSP)\n\tg = g || new Function(\"return this\")();\n} catch (e) {\n\t// This works if the window reference is available\n\tif (typeof window === \"object\") g = window;\n}\n\n// g can still be undefined, but nothing to do about it...\n// We return undefined, instead of nothing here, so it's\n// easier to handle this case. if(!global) { ...}\n\nmodule.exports = g;\n","import { useCallback, useEffect } from 'react';\n\nimport { events } from '@eventespresso/data';\nimport { useSystemNotifications } from '@eventespresso/toaster';\nimport type { EventSet } from '@eventespresso/data';\n\nexport const useEventsHandler: VoidFunction = () => {\n\tconst toaster = useSystemNotifications();\n\n\tconst onError = useCallback(\n\t\t(error) => {\n\t\t\ttoaster.error({ message: error.message });\n\t\t},\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\t\t[]\n\t);\n\n\tuseEffect(() => {\n\t\tevents.on('fetchUser.error', onError);\n\t\tevents.on('fetchSettings.error', onError);\n\n\t\t// housekeeping\n\t\treturn () => {\n\t\t\tevents.off('fetchUser.error', onError);\n\t\t\tevents.off('fetchSettings.error', onError);\n\t\t};\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\t}, []);\n};\n","import { useMemo } from 'react';\nimport { addQueryArgs } from '@wordpress/url';\n\nimport { ADMIN_ROUTES } from '@eventespresso/constants';\nimport { useConfig, getAdminUrl } from '@eventespresso/services';\n\nimport { useEventId } from '../apollo/queries';\nimport { QueryURLRegStatus } from '../types';\n\nexport type RegistrationsLinkArgs = {\n\tdatetime_id?: number;\n\tticket_id?: number;\n\t_reg_status?: QueryURLRegStatus;\n};\n\nexport const useRegistrationsLink = (args: RegistrationsLinkArgs): string => {\n\tconst { siteUrl } = useConfig();\n\tconst eventId = useEventId();\n\n\treturn useMemo(() => {\n\t\tconst adminUrl = getAdminUrl({\n\t\t\tadminSiteUrl: siteUrl.admin,\n\t\t\tpage: ADMIN_ROUTES.REGISTRATIONS,\n\t\t});\n\t\treturn addQueryArgs(adminUrl, {\n\t\t\tevent_id: eventId,\n\t\t\treturn: 'edit',\n\t\t\t...args,\n\t\t});\n\t}, [args, eventId, siteUrl.admin]);\n};\n","/**\n * Copyright (c) 2014-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nvar runtime = (function (exports) {\n \"use strict\";\n\n var Op = Object.prototype;\n var hasOwn = Op.hasOwnProperty;\n var undefined; // More compressible than void 0.\n var $Symbol = typeof Symbol === \"function\" ? Symbol : {};\n var iteratorSymbol = $Symbol.iterator || \"@@iterator\";\n var asyncIteratorSymbol = $Symbol.asyncIterator || \"@@asyncIterator\";\n var toStringTagSymbol = $Symbol.toStringTag || \"@@toStringTag\";\n\n function define(obj, key, value) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n return obj[key];\n }\n try {\n // IE 8 has a broken Object.defineProperty that only works on DOM objects.\n define({}, \"\");\n } catch (err) {\n define = function(obj, key, value) {\n return obj[key] = value;\n };\n }\n\n function wrap(innerFn, outerFn, self, tryLocsList) {\n // If outerFn provided and outerFn.prototype is a Generator, then outerFn.prototype instanceof Generator.\n var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator;\n var generator = Object.create(protoGenerator.prototype);\n var context = new Context(tryLocsList || []);\n\n // The ._invoke method unifies the implementations of the .next,\n // .throw, and .return methods.\n generator._invoke = makeInvokeMethod(innerFn, self, context);\n\n return generator;\n }\n exports.wrap = wrap;\n\n // Try/catch helper to minimize deoptimizations. Returns a completion\n // record like context.tryEntries[i].completion. This interface could\n // have been (and was previously) designed to take a closure to be\n // invoked without arguments, but in all the cases we care about we\n // already have an existing method we want to call, so there's no need\n // to create a new function object. We can even get away with assuming\n // the method takes exactly one argument, since that happens to be true\n // in every case, so we don't have to touch the arguments object. The\n // only additional allocation required is the completion record, which\n // has a stable shape and so hopefully should be cheap to allocate.\n function tryCatch(fn, obj, arg) {\n try {\n return { type: \"normal\", arg: fn.call(obj, arg) };\n } catch (err) {\n return { type: \"throw\", arg: err };\n }\n }\n\n var GenStateSuspendedStart = \"suspendedStart\";\n var GenStateSuspendedYield = \"suspendedYield\";\n var GenStateExecuting = \"executing\";\n var GenStateCompleted = \"completed\";\n\n // Returning this object from the innerFn has the same effect as\n // breaking out of the dispatch switch statement.\n var ContinueSentinel = {};\n\n // Dummy constructor functions that we use as the .constructor and\n // .constructor.prototype properties for functions that return Generator\n // objects. For full spec compliance, you may wish to configure your\n // minifier not to mangle the names of these two functions.\n function Generator() {}\n function GeneratorFunction() {}\n function GeneratorFunctionPrototype() {}\n\n // This is a polyfill for %IteratorPrototype% for environments that\n // don't natively support it.\n var IteratorPrototype = {};\n IteratorPrototype[iteratorSymbol] = function () {\n return this;\n };\n\n var getProto = Object.getPrototypeOf;\n var NativeIteratorPrototype = getProto && getProto(getProto(values([])));\n if (NativeIteratorPrototype &&\n NativeIteratorPrototype !== Op &&\n hasOwn.call(NativeIteratorPrototype, iteratorSymbol)) {\n // This environment has a native %IteratorPrototype%; use it instead\n // of the polyfill.\n IteratorPrototype = NativeIteratorPrototype;\n }\n\n var Gp = GeneratorFunctionPrototype.prototype =\n Generator.prototype = Object.create(IteratorPrototype);\n GeneratorFunction.prototype = Gp.constructor = GeneratorFunctionPrototype;\n GeneratorFunctionPrototype.constructor = GeneratorFunction;\n GeneratorFunction.displayName = define(\n GeneratorFunctionPrototype,\n toStringTagSymbol,\n \"GeneratorFunction\"\n );\n\n // Helper for defining the .next, .throw, and .return methods of the\n // Iterator interface in terms of a single ._invoke method.\n function defineIteratorMethods(prototype) {\n [\"next\", \"throw\", \"return\"].forEach(function(method) {\n define(prototype, method, function(arg) {\n return this._invoke(method, arg);\n });\n });\n }\n\n exports.isGeneratorFunction = function(genFun) {\n var ctor = typeof genFun === \"function\" && genFun.constructor;\n return ctor\n ? ctor === GeneratorFunction ||\n // For the native GeneratorFunction constructor, the best we can\n // do is to check its .name property.\n (ctor.displayName || ctor.name) === \"GeneratorFunction\"\n : false;\n };\n\n exports.mark = function(genFun) {\n if (Object.setPrototypeOf) {\n Object.setPrototypeOf(genFun, GeneratorFunctionPrototype);\n } else {\n genFun.__proto__ = GeneratorFunctionPrototype;\n define(genFun, toStringTagSymbol, \"GeneratorFunction\");\n }\n genFun.prototype = Object.create(Gp);\n return genFun;\n };\n\n // Within the body of any async function, `await x` is transformed to\n // `yield regeneratorRuntime.awrap(x)`, so that the runtime can test\n // `hasOwn.call(value, \"__await\")` to determine if the yielded value is\n // meant to be awaited.\n exports.awrap = function(arg) {\n return { __await: arg };\n };\n\n function AsyncIterator(generator, PromiseImpl) {\n function invoke(method, arg, resolve, reject) {\n var record = tryCatch(generator[method], generator, arg);\n if (record.type === \"throw\") {\n reject(record.arg);\n } else {\n var result = record.arg;\n var value = result.value;\n if (value &&\n typeof value === \"object\" &&\n hasOwn.call(value, \"__await\")) {\n return PromiseImpl.resolve(value.__await).then(function(value) {\n invoke(\"next\", value, resolve, reject);\n }, function(err) {\n invoke(\"throw\", err, resolve, reject);\n });\n }\n\n return PromiseImpl.resolve(value).then(function(unwrapped) {\n // When a yielded Promise is resolved, its final value becomes\n // the .value of the Promise<{value,done}> result for the\n // current iteration.\n result.value = unwrapped;\n resolve(result);\n }, function(error) {\n // If a rejected Promise was yielded, throw the rejection back\n // into the async generator function so it can be handled there.\n return invoke(\"throw\", error, resolve, reject);\n });\n }\n }\n\n var previousPromise;\n\n function enqueue(method, arg) {\n function callInvokeWithMethodAndArg() {\n return new PromiseImpl(function(resolve, reject) {\n invoke(method, arg, resolve, reject);\n });\n }\n\n return previousPromise =\n // If enqueue has been called before, then we want to wait until\n // all previous Promises have been resolved before calling invoke,\n // so that results are always delivered in the correct order. If\n // enqueue has not been called before, then it is important to\n // call invoke immediately, without waiting on a callback to fire,\n // so that the async generator function has the opportunity to do\n // any necessary setup in a predictable way. This predictability\n // is why the Promise constructor synchronously invokes its\n // executor callback, and why async functions synchronously\n // execute code before the first await. Since we implement simple\n // async functions in terms of async generators, it is especially\n // important to get this right, even though it requires care.\n previousPromise ? previousPromise.then(\n callInvokeWithMethodAndArg,\n // Avoid propagating failures to Promises returned by later\n // invocations of the iterator.\n callInvokeWithMethodAndArg\n ) : callInvokeWithMethodAndArg();\n }\n\n // Define the unified helper method that is used to implement .next,\n // .throw, and .return (see defineIteratorMethods).\n this._invoke = enqueue;\n }\n\n defineIteratorMethods(AsyncIterator.prototype);\n AsyncIterator.prototype[asyncIteratorSymbol] = function () {\n return this;\n };\n exports.AsyncIterator = AsyncIterator;\n\n // Note that simple async functions are implemented on top of\n // AsyncIterator objects; they just return a Promise for the value of\n // the final result produced by the iterator.\n exports.async = function(innerFn, outerFn, self, tryLocsList, PromiseImpl) {\n if (PromiseImpl === void 0) PromiseImpl = Promise;\n\n var iter = new AsyncIterator(\n wrap(innerFn, outerFn, self, tryLocsList),\n PromiseImpl\n );\n\n return exports.isGeneratorFunction(outerFn)\n ? iter // If outerFn is a generator, return the full iterator.\n : iter.next().then(function(result) {\n return result.done ? result.value : iter.next();\n });\n };\n\n function makeInvokeMethod(innerFn, self, context) {\n var state = GenStateSuspendedStart;\n\n return function invoke(method, arg) {\n if (state === GenStateExecuting) {\n throw new Error(\"Generator is already running\");\n }\n\n if (state === GenStateCompleted) {\n if (method === \"throw\") {\n throw arg;\n }\n\n // Be forgiving, per 25.3.3.3.3 of the spec:\n // https://people.mozilla.org/~jorendorff/es6-draft.html#sec-generatorresume\n return doneResult();\n }\n\n context.method = method;\n context.arg = arg;\n\n while (true) {\n var delegate = context.delegate;\n if (delegate) {\n var delegateResult = maybeInvokeDelegate(delegate, context);\n if (delegateResult) {\n if (delegateResult === ContinueSentinel) continue;\n return delegateResult;\n }\n }\n\n if (context.method === \"next\") {\n // Setting context._sent for legacy support of Babel's\n // function.sent implementation.\n context.sent = context._sent = context.arg;\n\n } else if (context.method === \"throw\") {\n if (state === GenStateSuspendedStart) {\n state = GenStateCompleted;\n throw context.arg;\n }\n\n context.dispatchException(context.arg);\n\n } else if (context.method === \"return\") {\n context.abrupt(\"return\", context.arg);\n }\n\n state = GenStateExecuting;\n\n var record = tryCatch(innerFn, self, context);\n if (record.type === \"normal\") {\n // If an exception is thrown from innerFn, we leave state ===\n // GenStateExecuting and loop back for another invocation.\n state = context.done\n ? GenStateCompleted\n : GenStateSuspendedYield;\n\n if (record.arg === ContinueSentinel) {\n continue;\n }\n\n return {\n value: record.arg,\n done: context.done\n };\n\n } else if (record.type === \"throw\") {\n state = GenStateCompleted;\n // Dispatch the exception by looping back around to the\n // context.dispatchException(context.arg) call above.\n context.method = \"throw\";\n context.arg = record.arg;\n }\n }\n };\n }\n\n // Call delegate.iterator[context.method](context.arg) and handle the\n // result, either by returning a { value, done } result from the\n // delegate iterator, or by modifying context.method and context.arg,\n // setting context.delegate to null, and returning the ContinueSentinel.\n function maybeInvokeDelegate(delegate, context) {\n var method = delegate.iterator[context.method];\n if (method === undefined) {\n // A .throw or .return when the delegate iterator has no .throw\n // method always terminates the yield* loop.\n context.delegate = null;\n\n if (context.method === \"throw\") {\n // Note: [\"return\"] must be used for ES3 parsing compatibility.\n if (delegate.iterator[\"return\"]) {\n // If the delegate iterator has a return method, give it a\n // chance to clean up.\n context.method = \"return\";\n context.arg = undefined;\n maybeInvokeDelegate(delegate, context);\n\n if (context.method === \"throw\") {\n // If maybeInvokeDelegate(context) changed context.method from\n // \"return\" to \"throw\", let that override the TypeError below.\n return ContinueSentinel;\n }\n }\n\n context.method = \"throw\";\n context.arg = new TypeError(\n \"The iterator does not provide a 'throw' method\");\n }\n\n return ContinueSentinel;\n }\n\n var record = tryCatch(method, delegate.iterator, context.arg);\n\n if (record.type === \"throw\") {\n context.method = \"throw\";\n context.arg = record.arg;\n context.delegate = null;\n return ContinueSentinel;\n }\n\n var info = record.arg;\n\n if (! info) {\n context.method = \"throw\";\n context.arg = new TypeError(\"iterator result is not an object\");\n context.delegate = null;\n return ContinueSentinel;\n }\n\n if (info.done) {\n // Assign the result of the finished delegate to the temporary\n // variable specified by delegate.resultName (see delegateYield).\n context[delegate.resultName] = info.value;\n\n // Resume execution at the desired location (see delegateYield).\n context.next = delegate.nextLoc;\n\n // If context.method was \"throw\" but the delegate handled the\n // exception, let the outer generator proceed normally. If\n // context.method was \"next\", forget context.arg since it has been\n // \"consumed\" by the delegate iterator. If context.method was\n // \"return\", allow the original .return call to continue in the\n // outer generator.\n if (context.method !== \"return\") {\n context.method = \"next\";\n context.arg = undefined;\n }\n\n } else {\n // Re-yield the result returned by the delegate method.\n return info;\n }\n\n // The delegate iterator is finished, so forget it and continue with\n // the outer generator.\n context.delegate = null;\n return ContinueSentinel;\n }\n\n // Define Generator.prototype.{next,throw,return} in terms of the\n // unified ._invoke helper method.\n defineIteratorMethods(Gp);\n\n define(Gp, toStringTagSymbol, \"Generator\");\n\n // A Generator should always return itself as the iterator object when the\n // @@iterator function is called on it. Some browsers' implementations of the\n // iterator prototype chain incorrectly implement this, causing the Generator\n // object to not be returned from this call. This ensures that doesn't happen.\n // See https://github.com/facebook/regenerator/issues/274 for more details.\n Gp[iteratorSymbol] = function() {\n return this;\n };\n\n Gp.toString = function() {\n return \"[object Generator]\";\n };\n\n function pushTryEntry(locs) {\n var entry = { tryLoc: locs[0] };\n\n if (1 in locs) {\n entry.catchLoc = locs[1];\n }\n\n if (2 in locs) {\n entry.finallyLoc = locs[2];\n entry.afterLoc = locs[3];\n }\n\n this.tryEntries.push(entry);\n }\n\n function resetTryEntry(entry) {\n var record = entry.completion || {};\n record.type = \"normal\";\n delete record.arg;\n entry.completion = record;\n }\n\n function Context(tryLocsList) {\n // The root entry object (effectively a try statement without a catch\n // or a finally block) gives us a place to store values thrown from\n // locations where there is no enclosing try statement.\n this.tryEntries = [{ tryLoc: \"root\" }];\n tryLocsList.forEach(pushTryEntry, this);\n this.reset(true);\n }\n\n exports.keys = function(object) {\n var keys = [];\n for (var key in object) {\n keys.push(key);\n }\n keys.reverse();\n\n // Rather than returning an object with a next method, we keep\n // things simple and return the next function itself.\n return function next() {\n while (keys.length) {\n var key = keys.pop();\n if (key in object) {\n next.value = key;\n next.done = false;\n return next;\n }\n }\n\n // To avoid creating an additional object, we just hang the .value\n // and .done properties off the next function object itself. This\n // also ensures that the minifier will not anonymize the function.\n next.done = true;\n return next;\n };\n };\n\n function values(iterable) {\n if (iterable) {\n var iteratorMethod = iterable[iteratorSymbol];\n if (iteratorMethod) {\n return iteratorMethod.call(iterable);\n }\n\n if (typeof iterable.next === \"function\") {\n return iterable;\n }\n\n if (!isNaN(iterable.length)) {\n var i = -1, next = function next() {\n while (++i < iterable.length) {\n if (hasOwn.call(iterable, i)) {\n next.value = iterable[i];\n next.done = false;\n return next;\n }\n }\n\n next.value = undefined;\n next.done = true;\n\n return next;\n };\n\n return next.next = next;\n }\n }\n\n // Return an iterator with no values.\n return { next: doneResult };\n }\n exports.values = values;\n\n function doneResult() {\n return { value: undefined, done: true };\n }\n\n Context.prototype = {\n constructor: Context,\n\n reset: function(skipTempReset) {\n this.prev = 0;\n this.next = 0;\n // Resetting context._sent for legacy support of Babel's\n // function.sent implementation.\n this.sent = this._sent = undefined;\n this.done = false;\n this.delegate = null;\n\n this.method = \"next\";\n this.arg = undefined;\n\n this.tryEntries.forEach(resetTryEntry);\n\n if (!skipTempReset) {\n for (var name in this) {\n // Not sure about the optimal order of these conditions:\n if (name.charAt(0) === \"t\" &&\n hasOwn.call(this, name) &&\n !isNaN(+name.slice(1))) {\n this[name] = undefined;\n }\n }\n }\n },\n\n stop: function() {\n this.done = true;\n\n var rootEntry = this.tryEntries[0];\n var rootRecord = rootEntry.completion;\n if (rootRecord.type === \"throw\") {\n throw rootRecord.arg;\n }\n\n return this.rval;\n },\n\n dispatchException: function(exception) {\n if (this.done) {\n throw exception;\n }\n\n var context = this;\n function handle(loc, caught) {\n record.type = \"throw\";\n record.arg = exception;\n context.next = loc;\n\n if (caught) {\n // If the dispatched exception was caught by a catch block,\n // then let that catch block handle the exception normally.\n context.method = \"next\";\n context.arg = undefined;\n }\n\n return !! caught;\n }\n\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n var record = entry.completion;\n\n if (entry.tryLoc === \"root\") {\n // Exception thrown outside of any try block that could handle\n // it, so set the completion value of the entire function to\n // throw the exception.\n return handle(\"end\");\n }\n\n if (entry.tryLoc <= this.prev) {\n var hasCatch = hasOwn.call(entry, \"catchLoc\");\n var hasFinally = hasOwn.call(entry, \"finallyLoc\");\n\n if (hasCatch && hasFinally) {\n if (this.prev < entry.catchLoc) {\n return handle(entry.catchLoc, true);\n } else if (this.prev < entry.finallyLoc) {\n return handle(entry.finallyLoc);\n }\n\n } else if (hasCatch) {\n if (this.prev < entry.catchLoc) {\n return handle(entry.catchLoc, true);\n }\n\n } else if (hasFinally) {\n if (this.prev < entry.finallyLoc) {\n return handle(entry.finallyLoc);\n }\n\n } else {\n throw new Error(\"try statement without catch or finally\");\n }\n }\n }\n },\n\n abrupt: function(type, arg) {\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n if (entry.tryLoc <= this.prev &&\n hasOwn.call(entry, \"finallyLoc\") &&\n this.prev < entry.finallyLoc) {\n var finallyEntry = entry;\n break;\n }\n }\n\n if (finallyEntry &&\n (type === \"break\" ||\n type === \"continue\") &&\n finallyEntry.tryLoc <= arg &&\n arg <= finallyEntry.finallyLoc) {\n // Ignore the finally entry if control is not jumping to a\n // location outside the try/catch block.\n finallyEntry = null;\n }\n\n var record = finallyEntry ? finallyEntry.completion : {};\n record.type = type;\n record.arg = arg;\n\n if (finallyEntry) {\n this.method = \"next\";\n this.next = finallyEntry.finallyLoc;\n return ContinueSentinel;\n }\n\n return this.complete(record);\n },\n\n complete: function(record, afterLoc) {\n if (record.type === \"throw\") {\n throw record.arg;\n }\n\n if (record.type === \"break\" ||\n record.type === \"continue\") {\n this.next = record.arg;\n } else if (record.type === \"return\") {\n this.rval = this.arg = record.arg;\n this.method = \"return\";\n this.next = \"end\";\n } else if (record.type === \"normal\" && afterLoc) {\n this.next = afterLoc;\n }\n\n return ContinueSentinel;\n },\n\n finish: function(finallyLoc) {\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n if (entry.finallyLoc === finallyLoc) {\n this.complete(entry.completion, entry.afterLoc);\n resetTryEntry(entry);\n return ContinueSentinel;\n }\n }\n },\n\n \"catch\": function(tryLoc) {\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n if (entry.tryLoc === tryLoc) {\n var record = entry.completion;\n if (record.type === \"throw\") {\n var thrown = record.arg;\n resetTryEntry(entry);\n }\n return thrown;\n }\n }\n\n // The context.catch method must only be called with a location\n // argument that corresponds to a known catch block.\n throw new Error(\"illegal catch attempt\");\n },\n\n delegateYield: function(iterable, resultName, nextLoc) {\n this.delegate = {\n iterator: values(iterable),\n resultName: resultName,\n nextLoc: nextLoc\n };\n\n if (this.method === \"next\") {\n // Deliberately forget the last sent value so that we don't\n // accidentally pass it on to the delegate.\n this.arg = undefined;\n }\n\n return ContinueSentinel;\n }\n };\n\n // Regardless of whether this script is executing as a CommonJS module\n // or not, return the runtime object so that we can declare the variable\n // regeneratorRuntime in the outer scope, which allows this module to be\n // injected easily by `bin/regenerator --include-runtime script.js`.\n return exports;\n\n}(\n // If this script is executing as a CommonJS module, use module.exports\n // as the regeneratorRuntime namespace. Otherwise create a new empty\n // object. Either way, the resulting object will be used to initialize\n // the regeneratorRuntime variable at the top of this file.\n typeof module === \"object\" ? module.exports : {}\n));\n\ntry {\n regeneratorRuntime = runtime;\n} catch (accidentalStrictMode) {\n // This module should not be running in strict mode, so the above\n // assignment should always work unless something is misconfigured. Just\n // in case runtime.js accidentally runs in strict mode, we can escape\n // strict mode using a global Function call. This could conceivably fail\n // if a Content Security Policy forbids using Function, but in that case\n // the proper solution is to fix the accidental strict mode problem. If\n // you've misconfigured your bundler to force strict mode and applied a\n // CSP to forbid Function, and you're not willing to fix either of those\n // problems, please detail your unique predicament in a GitHub issue.\n Function(\"r\", \"regeneratorRuntime = r\")(runtime);\n}\n","(function() { module.exports = window[\"eventespresso\"][\"toaster\"]; }());","import { gql } from '@eventespresso/data';\nimport { TICKET_ATTRIBUTES } from '../../queries/tickets';\nimport { PRICE_ATTRIBUTES } from '../../queries/prices';\n\n/**\n * The related prices for a ticket.\n * Can be used to fetch the default prices\n * created for a ticket on the server.\n */\nexport const TICKET_PRICES_ATTRIBUTE: any = gql`\n\tfragment ticketPricesAttribute on EspressoTicket {\n\t\tprices {\n\t\t\tnodes {\n\t\t\t\t...priceAttributes\n\t\t\t}\n\t\t}\n\t}\n\t${PRICE_ATTRIBUTES}\n`;\n\nexport const CREATE_TICKET = gql`\n\tmutation CREATE_TICKET($input: CreateEspressoTicketInput!) {\n\t\tcreateEspressoTicket(input: $input) {\n\t\t\tespressoTicket {\n\t\t\t\t...ticketAttributes\n\t\t\t\t...ticketPricesAttribute # fetch default prices when a ticket is created.\n\t\t\t}\n\t\t}\n\t}\n\t${TICKET_ATTRIBUTES}\n\t${TICKET_PRICES_ATTRIBUTE}\n`;\n\nexport const UPDATE_TICKET = gql`\n\tmutation UPDATE_TICKET($input: UpdateEspressoTicketInput!) {\n\t\tupdateEspressoTicket(input: $input) {\n\t\t\tespressoTicket {\n\t\t\t\t...ticketAttributes\n\t\t\t\t...ticketPricesAttribute # fetch updated prices when a ticket is updated.\n\t\t\t}\n\t\t}\n\t}\n\t${TICKET_ATTRIBUTES}\n\t${TICKET_PRICES_ATTRIBUTE}\n`;\n\nexport const DELETE_TICKET = gql`\n\tmutation DELETE_TICKET($input: DeleteEspressoTicketInput!) {\n\t\tdeleteEspressoTicket(input: $input) {\n\t\t\tespressoTicket {\n\t\t\t\t...ticketAttributes\n\t\t\t}\n\t\t}\n\t}\n\t${TICKET_ATTRIBUTES}\n`;\n\nexport const BULK_UPDATE_TICKETS = gql`\n\tmutation BULK_UPDATE_TICKETS($input: BulkUpdateEspressoTicketInput!) {\n\t\tbulkUpdateEspressoTicket(input: $input) {\n\t\t\tupdated\n\t\t\tfailed\n\t\t}\n\t}\n`;\n\nexport { default as useTicketMutator } from './useTicketMutator';\n\nexport { default as useReorderTickets } from './useReorderTickets';\n\nexport { default as useBulkEditTickets } from './useBulkEditTickets';\n\nexport { default as useBulkDeleteTickets } from './useBulkDeleteTickets';\n\nexport * from './useUpdateTicketQtyByCapacity';\n\nexport * from './types';\n","import { useMemo } from 'react';\nimport { filter } from 'ramda';\n\nimport { useTicketsQuery } from '@eventespresso/data';\nimport { getCacheIds, TicketPred, isNotDefault } from '@eventespresso/predicates';\n\nimport useTicketQueryOptions from './useTicketQueryOptions';\nimport type { Ticket, TicketEdge } from '../../types';\n\nconst useTickets = (filterBy: TicketPred = isNotDefault): Array => {\n\tconst options = useTicketQueryOptions();\n\n\tconst { data } = useTicketsQuery(options);\n\n\tconst nodes = data?.espressoTickets?.nodes || [];\n\n\tconst cacheIds = getCacheIds(nodes);\n\n\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\treturn useMemo(() => filter(filterBy, nodes), [cacheIds]);\n};\n\nexport default useTickets;\n","import { CacheUpdaterFn, useUpdateCache, WriteQueryOptions } from '@eventespresso/data';\n\n/**\n * Updates entity list Apollo cache\n */\nconst useUpdateEntityList = (\n\twriteQueryOptions: WriteQueryOptions = undefined\n): CacheUpdaterFn => {\n\treturn useUpdateCache(writeQueryOptions);\n};\n\nexport default useUpdateEntityList;\n","import { gql } from '@eventespresso/data';\nimport { DATETIME_ATTRIBUTES } from '../../queries/datetimes';\n\nexport const CREATE_DATETIME = gql`\n\tmutation CREATE_DATETIME($input: CreateEspressoDatetimeInput!) {\n\t\tcreateEspressoDatetime(input: $input) {\n\t\t\tespressoDatetime {\n\t\t\t\t...datetimeAttributes\n\t\t\t}\n\t\t}\n\t}\n\t${DATETIME_ATTRIBUTES}\n`;\n\nexport const UPDATE_DATETIME = gql`\n\tmutation UPDATE_DATETIME($input: UpdateEspressoDatetimeInput!) {\n\t\tupdateEspressoDatetime(input: $input) {\n\t\t\tespressoDatetime {\n\t\t\t\t...datetimeAttributes\n\t\t\t}\n\t\t}\n\t}\n\t${DATETIME_ATTRIBUTES}\n`;\n\nexport const DELETE_DATETIME = gql`\n\tmutation DELETE_DATETIME($input: DeleteEspressoDatetimeInput!) {\n\t\tdeleteEspressoDatetime(input: $input) {\n\t\t\tespressoDatetime {\n\t\t\t\t...datetimeAttributes\n\t\t\t}\n\t\t}\n\t}\n\t${DATETIME_ATTRIBUTES}\n`;\n\nexport const BULK_UPDATE_DATETIMES = gql`\n\tmutation BULK_UPDATE_DATETIMES($input: BulkUpdateEspressoDatetimeInput!) {\n\t\tbulkUpdateEspressoDatetime(input: $input) {\n\t\t\tupdated\n\t\t\tfailed\n\t\t}\n\t}\n`;\n\nexport { default as useDatetimeMutator } from './useDatetimeMutator';\n\nexport { default as useDeleteRelatedTickets } from './useDeleteRelatedTickets';\n\nexport { default as useBulkEditDatetimes } from './useBulkEditDatetimes';\n\nexport { default as useBulkDeleteDatetimes } from './useBulkDeleteDatetimes';\n\nexport { default as useReorderDatetimes } from './useReorderDatetimes';\n\nexport * from './types';\n","import { gql } from '@eventespresso/data';\n\nexport const TICKET_ATTRIBUTES: any = gql`\n\tfragment ticketAttributes on EspressoTicket {\n\t\tid\n\t\tdbId\n\t\tcacheId\n\t\tdescription\n\t\tendDate\n\t\tisDefault\n\t\tisExpired\n\t\tisFree\n\t\tisOnSale\n\t\tisPending\n\t\tisRequired\n\t\tisSoldOut\n\t\tisTrashed\n\t\tmax\n\t\tmin\n\t\tname\n\t\torder\n\t\tprice\n\t\tquantity\n\t\tregistrationCount\n\t\treserved\n\t\treverseCalculate\n\t\tsold\n\t\tstartDate\n\t\tuserId\n\t\tuses\n\t\tvisibility\n\t}\n`;\n\nexport const GET_TICKET: any = gql`\n\tquery GET_TICKET($id: ID!) {\n\t\tespressoTicket(id: $id) {\n\t\t\t...ticketAttributes\n\t\t}\n\t}\n\t${TICKET_ATTRIBUTES}\n`;\n\nexport const GET_TICKETS: any = gql`\n\tquery GET_TICKETS($where: EspressoRootQueryTicketsConnectionWhereArgs) {\n\t\tespressoTickets(where: $where) {\n\t\t\tnodes {\n\t\t\t\t...ticketAttributes\n\t\t\t}\n\t\t}\n\t}\n\t${TICKET_ATTRIBUTES}\n`;\n","var Symbol = require('./_Symbol'),\n getRawTag = require('./_getRawTag'),\n objectToString = require('./_objectToString');\n\n/** `Object#toString` result references. */\nvar nullTag = '[object Null]',\n undefinedTag = '[object Undefined]';\n\n/** Built-in value references. */\nvar symToStringTag = Symbol ? Symbol.toStringTag : undefined;\n\n/**\n * The base implementation of `getTag` without fallbacks for buggy environments.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\nfunction baseGetTag(value) {\n if (value == null) {\n return value === undefined ? undefinedTag : nullTag;\n }\n return (symToStringTag && symToStringTag in Object(value))\n ? getRawTag(value)\n : objectToString(value);\n}\n\nmodule.exports = baseGetTag;\n","/**\n * Checks if `value` is object-like. A value is object-like if it's not `null`\n * and has a `typeof` result of \"object\".\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is object-like, else `false`.\n * @example\n *\n * _.isObjectLike({});\n * // => true\n *\n * _.isObjectLike([1, 2, 3]);\n * // => true\n *\n * _.isObjectLike(_.noop);\n * // => false\n *\n * _.isObjectLike(null);\n * // => false\n */\nfunction isObjectLike(value) {\n return value != null && typeof value == 'object';\n}\n\nmodule.exports = isObjectLike;\n","var baseToString = require('./_baseToString');\n\n/**\n * Converts `value` to a string. An empty string is returned for `null`\n * and `undefined` values. The sign of `-0` is preserved.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to convert.\n * @returns {string} Returns the converted string.\n * @example\n *\n * _.toString(null);\n * // => ''\n *\n * _.toString(-0);\n * // => '-0'\n *\n * _.toString([1, 2, 3]);\n * // => '1,2,3'\n */\nfunction toString(value) {\n return value == null ? '' : baseToString(value);\n}\n\nmodule.exports = toString;\n","import { gql } from '@eventespresso/data';\n\nexport const DATETIME_ATTRIBUTES: any = gql`\n\tfragment datetimeAttributes on EspressoDatetime {\n\t\tid\n\t\tdbId\n\t\tcacheId\n\t\tcapacity\n\t\tdescription\n\t\tendDate\n\t\tisActive\n\t\tisExpired\n\t\tisPrimary\n\t\tisSoldOut\n\t\tisTrashed\n\t\tisUpcoming\n\t\tlength\n\t\tname\n\t\torder\n\t\treserved\n\t\tsold\n\t\tstatus\n\t\tstartDate\n\t\tvenue\n\t}\n`;\n\nexport const GET_DATETIME: any = gql`\n\tquery GET_DATETIME($id: ID!) {\n\t\tespressoDatetime(id: $id) {\n\t\t\t...datetimeAttributes\n\t\t}\n\t}\n\t${DATETIME_ATTRIBUTES}\n`;\n\nexport const GET_DATETIMES: any = gql`\n\tquery GET_DATETIMES($where: EspressoRootQueryDatetimesConnectionWhereArgs) {\n\t\tespressoDatetimes(where: $where) {\n\t\t\tnodes {\n\t\t\t\t...datetimeAttributes\n\t\t\t}\n\t\t}\n\t}\n\t${DATETIME_ATTRIBUTES}\n`;\n","import {\n\tentitiesWithGuIdInArray,\n\tentitiesWithGuIdNotInArray,\n\tisActive,\n\tisExpired,\n\tisOnSale,\n\tisPending,\n\tisUpcoming,\n} from '@eventespresso/predicates';\nimport type { AnyObject } from '@eventespresso/utils';\nimport { shiftDate } from '@eventespresso/dates';\nimport type { EntityId } from '@eventespresso/data';\nimport { uuid } from '@eventespresso/utils';\n\nimport { BulkUpdateInput, BulkEditFormBaseShape } from './types';\nimport { Datetime, Ticket, Price } from '../types';\nimport { UpdateDatetimeInput } from '../..';\nimport { UpdateTicketInput } from './tickets';\n\nexport const formToBulkUpdateInput = <\n\tT extends BulkEditFormBaseShape,\n\tE extends Datetime | Ticket,\n\tI extends AnyObject\n>(\n\tformData: T,\n\tallEntities: E[],\n\tselectedIds: EntityId[]\n): BulkUpdateInput => {\n\tconst { shiftDates, ...values } = formData;\n\t// This contains the unique input for each entity.\n\tlet uniqueInputs: BulkUpdateInput['uniqueInputs'] = [];\n\t// we need to shift the dates.\n\tif (shiftDates?.unit && shiftDates?.value && shiftDates?.type) {\n\t\t// get full entity objects from the selected IDs\n\t\tconst selectedEntities = entitiesWithGuIdInArray(allEntities, selectedIds);\n\t\t// keep the date shifter ready\n\t\tconst shiftTheDate = shiftDate(shiftDates);\n\t\t// shift start and end dates for the selected entities\n\t\tuniqueInputs = selectedEntities.map((entity) => {\n\t\t\tconst startDate = shiftTheDate(entity.startDate).toISOString();\n\t\t\tconst endDate = shiftTheDate(entity.endDate).toISOString();\n\t\t\treturn { id: entity.id, startDate, endDate };\n\t\t});\n\t} else {\n\t\t// otherwise we just need the ids for uniqueInputs\n\t\tuniqueInputs = selectedIds.map((id) => ({ id }));\n\t}\n\n\t// we need to add id to shared input to avoid GQL schema yelling at us.\n\tconst sharedInput = { ...values, id: '' };\n\n\treturn {\n\t\tsharedInput,\n\t\tuniqueInputs,\n\t} as BulkUpdateInput;\n};\n\nexport const cacheNodesFromBulkInput = (\n\tinput: BulkUpdateInput,\n\tallEntities: E[]\n): E[] => {\n\t// convert uniqueInputs array to object with ids as keys and the objects as values\n\tconst uniqueInputs = input.uniqueInputs.reduce((inputs, currentInput) => {\n\t\treturn { ...inputs, [currentInput.id]: currentInput };\n\t}, {});\n\n\t// override the data for the selected nodes from the given input\n\tconst nodes = allEntities.map((node) => {\n\t\t// if the node is not in selected nodes\n\t\tif (!uniqueInputs?.[node.id]) {\n\t\t\treturn node;\n\t\t}\n\t\treturn {\n\t\t\t...node,\n\t\t\t...input.sharedInput,\n\t\t\t...uniqueInputs[node.id],\n\t\t\tcacheId: uuid(),\n\t\t};\n\t});\n\n\treturn nodes;\n};\n\nexport const cacheNodesFromBulkDelete = (\n\tentityIds: Array,\n\tallEntities: E[],\n\tdeletePermanently?: boolean\n): E[] => {\n\tif (deletePermanently) {\n\t\treturn entitiesWithGuIdNotInArray(allEntities, entityIds);\n\t}\n\n\t// mark all entities as trashed\n\tconst nodes = allEntities.map((node) => {\n\t\t// if the node is not in selected nodes\n\t\tif (!entityIds.includes(node.id)) {\n\t\t\treturn node;\n\t\t}\n\t\treturn {\n\t\t\t...node,\n\t\t\tisTrashed: true,\n\t\t\tcacheId: uuid(),\n\t\t};\n\t});\n\n\treturn nodes;\n};\n\n/**\n * Updates the boolean date related flags for the given datetime\n * based upon the (possible updated) other fields\n */\nexport const updateDatetimeFlags = (date: Datetime): Datetime => {\n\treturn {\n\t\t...date,\n\t\tisActive: isActive(date, true),\n\t\tisExpired: isExpired(date, true),\n\t\tisUpcoming: isUpcoming(date, true),\n\t};\n};\n\n/**\n * Updates the boolean date related flags for the given ticket\n * based upon the (possible updated) other fields\n */\nexport const updateTicketFlags = (ticket: Ticket): Ticket => {\n\treturn {\n\t\t...ticket,\n\t\tisExpired: isExpired(ticket, true),\n\t\tisFree: !ticket.price,\n\t\tisOnSale: isOnSale(ticket, true),\n\t\tisPending: isPending(ticket, true),\n\t};\n};\n","// ES6 Map\nvar map\ntry {\n map = Map\n} catch (_) { }\nvar set\n\n// ES6 Set\ntry {\n set = Set\n} catch (_) { }\n\nfunction baseClone (src, circulars, clones) {\n // Null/undefined/functions/etc\n if (!src || typeof src !== 'object' || typeof src === 'function') {\n return src\n }\n\n // DOM Node\n if (src.nodeType && 'cloneNode' in src) {\n return src.cloneNode(true)\n }\n\n // Date\n if (src instanceof Date) {\n return new Date(src.getTime())\n }\n\n // RegExp\n if (src instanceof RegExp) {\n return new RegExp(src)\n }\n\n // Arrays\n if (Array.isArray(src)) {\n return src.map(clone)\n }\n\n // ES6 Maps\n if (map && src instanceof map) {\n return new Map(Array.from(src.entries()))\n }\n\n // ES6 Sets\n if (set && src instanceof set) {\n return new Set(Array.from(src.values()))\n }\n\n // Object\n if (src instanceof Object) {\n circulars.push(src)\n var obj = Object.create(src)\n clones.push(obj)\n for (var key in src) {\n var idx = circulars.findIndex(function (i) {\n return i === src[key]\n })\n obj[key] = idx > -1 ? clones[idx] : baseClone(src[key], circulars, clones)\n }\n return obj\n }\n\n // ???\n return src\n}\n\nexport default function clone (src) {\n return baseClone(src, [], [])\n}\n","const toString = Object.prototype.toString;\nconst errorToString = Error.prototype.toString;\nconst regExpToString = RegExp.prototype.toString;\nconst symbolToString = typeof Symbol !== 'undefined' ? Symbol.prototype.toString : () => '';\nconst SYMBOL_REGEXP = /^Symbol\\((.*)\\)(.*)$/;\n\nfunction printNumber(val) {\n if (val != +val) return 'NaN';\n const isNegativeZero = val === 0 && 1 / val < 0;\n return isNegativeZero ? '-0' : '' + val;\n}\n\nfunction printSimpleValue(val, quoteStrings = false) {\n if (val == null || val === true || val === false) return '' + val;\n const typeOf = typeof val;\n if (typeOf === 'number') return printNumber(val);\n if (typeOf === 'string') return quoteStrings ? `\"${val}\"` : val;\n if (typeOf === 'function') return '[Function ' + (val.name || 'anonymous') + ']';\n if (typeOf === 'symbol') return symbolToString.call(val).replace(SYMBOL_REGEXP, 'Symbol($1)');\n const tag = toString.call(val).slice(8, -1);\n if (tag === 'Date') return isNaN(val.getTime()) ? '' + val : val.toISOString(val);\n if (tag === 'Error' || val instanceof Error) return '[' + errorToString.call(val) + ']';\n if (tag === 'RegExp') return regExpToString.call(val);\n return null;\n}\n\nexport default function printValue(value, quoteStrings) {\n let result = printSimpleValue(value, quoteStrings);\n if (result !== null) return result;\n return JSON.stringify(value, function (key, value) {\n let result = printSimpleValue(this[key], quoteStrings);\n if (result !== null) return result;\n return value;\n }, 2);\n}","import printValue from './util/printValue';\nexport let mixed = {\n default: '${path} is invalid',\n required: '${path} is a required field',\n oneOf: '${path} must be one of the following values: ${values}',\n notOneOf: '${path} must not be one of the following values: ${values}',\n notType: ({\n path,\n type,\n value,\n originalValue\n }) => {\n let isCast = originalValue != null && originalValue !== value;\n let msg = `${path} must be a \\`${type}\\` type, ` + `but the final value was: \\`${printValue(value, true)}\\`` + (isCast ? ` (cast from the value \\`${printValue(originalValue, true)}\\`).` : '.');\n\n if (value === null) {\n msg += `\\n If \"null\" is intended as an empty value be sure to mark the schema as \\`.nullable()\\``;\n }\n\n return msg;\n },\n defined: '${path} must be defined'\n};\nexport let string = {\n length: '${path} must be exactly ${length} characters',\n min: '${path} must be at least ${min} characters',\n max: '${path} must be at most ${max} characters',\n matches: '${path} must match the following: \"${regex}\"',\n email: '${path} must be a valid email',\n url: '${path} must be a valid URL',\n uuid: '${path} must be a valid UUID',\n trim: '${path} must be a trimmed string',\n lowercase: '${path} must be a lowercase string',\n uppercase: '${path} must be a upper case string'\n};\nexport let number = {\n min: '${path} must be greater than or equal to ${min}',\n max: '${path} must be less than or equal to ${max}',\n lessThan: '${path} must be less than ${less}',\n moreThan: '${path} must be greater than ${more}',\n positive: '${path} must be a positive number',\n negative: '${path} must be a negative number',\n integer: '${path} must be an integer'\n};\nexport let date = {\n min: '${path} field must be later than ${min}',\n max: '${path} field must be at earlier than ${max}'\n};\nexport let boolean = {\n isValue: '${path} field must be ${value}'\n};\nexport let object = {\n noUnknown: '${path} field has unspecified keys: ${unknown}'\n};\nexport let array = {\n min: '${path} field must have at least ${min} items',\n max: '${path} field must have less than or equal to ${max} items',\n length: '${path} must have ${length} items'\n};\nexport default Object.assign(Object.create(null), {\n mixed,\n string,\n number,\n date,\n object,\n array,\n boolean\n});","const isSchema = obj => obj && obj.__isYupSchema__;\n\nexport default isSchema;","import has from 'lodash/has';\nimport isSchema from './util/isSchema';\n\nclass Condition {\n constructor(refs, options) {\n this.fn = void 0;\n this.refs = refs;\n this.refs = refs;\n\n if (typeof options === 'function') {\n this.fn = options;\n return;\n }\n\n if (!has(options, 'is')) throw new TypeError('`is:` is required for `when()` conditions');\n if (!options.then && !options.otherwise) throw new TypeError('either `then:` or `otherwise:` is required for `when()` conditions');\n let {\n is,\n then,\n otherwise\n } = options;\n let check = typeof is === 'function' ? is : (...values) => values.every(value => value === is);\n\n this.fn = function (...args) {\n let options = args.pop();\n let schema = args.pop();\n let branch = check(...args) ? then : otherwise;\n if (!branch) return undefined;\n if (typeof branch === 'function') return branch(schema);\n return schema.concat(branch.resolve(options));\n };\n }\n\n resolve(base, options) {\n let values = this.refs.map(ref => ref.getValue(options == null ? void 0 : options.value, options == null ? void 0 : options.parent, options == null ? void 0 : options.context));\n let schema = this.fn.apply(base, values.concat(base, options));\n if (schema === undefined || schema === base) return base;\n if (!isSchema(schema)) throw new TypeError('conditions must return a schema object');\n return schema.resolve(options);\n }\n\n}\n\nexport default Condition;","export default function toArray(value) {\n return value == null ? [] : [].concat(value);\n}","function _extends() { _extends = Object.assign || 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); }\n\nimport printValue from './util/printValue';\nimport toArray from './util/toArray';\nlet strReg = /\\$\\{\\s*(\\w+)\\s*\\}/g;\nexport default class ValidationError extends Error {\n static formatError(message, params) {\n const path = params.label || params.path || 'this';\n if (path !== params.path) params = _extends({}, params, {\n path\n });\n if (typeof message === 'string') return message.replace(strReg, (_, key) => printValue(params[key]));\n if (typeof message === 'function') return message(params);\n return message;\n }\n\n static isError(err) {\n return err && err.name === 'ValidationError';\n }\n\n constructor(errorOrErrors, value, field, type) {\n super();\n this.value = void 0;\n this.path = void 0;\n this.type = void 0;\n this.errors = void 0;\n this.params = void 0;\n this.inner = void 0;\n this.name = 'ValidationError';\n this.value = value;\n this.path = field;\n this.type = type;\n this.errors = [];\n this.inner = [];\n toArray(errorOrErrors).forEach(err => {\n if (ValidationError.isError(err)) {\n this.errors.push(...err.errors);\n this.inner = this.inner.concat(err.inner.length ? err.inner : err);\n } else {\n this.errors.push(err);\n }\n });\n this.message = this.errors.length > 1 ? `${this.errors.length} errors occurred` : this.errors[0];\n if (Error.captureStackTrace) Error.captureStackTrace(this, ValidationError);\n }\n\n}","import ValidationError from '../ValidationError';\n\nconst once = cb => {\n let fired = false;\n return (...args) => {\n if (fired) return;\n fired = true;\n cb(...args);\n };\n};\n\nexport default function runTests(options, cb) {\n let {\n endEarly,\n tests,\n args,\n value,\n errors,\n sort,\n path\n } = options;\n let callback = once(cb);\n let count = tests.length;\n const nestedErrors = [];\n errors = errors ? errors : [];\n if (!count) return errors.length ? callback(new ValidationError(errors, value, path)) : callback(null, value);\n\n for (let i = 0; i < tests.length; i++) {\n const test = tests[i];\n test(args, function finishTestRun(err) {\n if (err) {\n // always return early for non validation errors\n if (!ValidationError.isError(err)) {\n return callback(err, value);\n }\n\n if (endEarly) {\n err.value = value;\n return callback(err, value);\n }\n\n nestedErrors.push(err);\n }\n\n if (--count <= 0) {\n if (nestedErrors.length) {\n if (sort) nestedErrors.sort(sort); //show parent errors after the nested ones: name.first, name\n\n if (errors.length) nestedErrors.push(...errors);\n errors = nestedErrors;\n }\n\n if (errors.length) {\n callback(new ValidationError(errors, value, path), value);\n return;\n }\n\n callback(null, value);\n }\n });\n }\n}","import { getter } from 'property-expr';\nconst prefixes = {\n context: '$',\n value: '.'\n};\nexport function create(key, options) {\n return new Reference(key, options);\n}\nexport default class Reference {\n constructor(key, options = {}) {\n this.key = void 0;\n this.isContext = void 0;\n this.isValue = void 0;\n this.isSibling = void 0;\n this.path = void 0;\n this.getter = void 0;\n this.map = void 0;\n if (typeof key !== 'string') throw new TypeError('ref must be a string, got: ' + key);\n this.key = key.trim();\n if (key === '') throw new TypeError('ref must be a non-empty string');\n this.isContext = this.key[0] === prefixes.context;\n this.isValue = this.key[0] === prefixes.value;\n this.isSibling = !this.isContext && !this.isValue;\n let prefix = this.isContext ? prefixes.context : this.isValue ? prefixes.value : '';\n this.path = this.key.slice(prefix.length);\n this.getter = this.path && getter(this.path, true);\n this.map = options.map;\n }\n\n getValue(value, parent, context) {\n let result = this.isContext ? context : this.isValue ? value : parent;\n if (this.getter) result = this.getter(result || {});\n if (this.map) result = this.map(result);\n return result;\n }\n /**\n *\n * @param {*} value\n * @param {Object} options\n * @param {Object=} options.context\n * @param {Object=} options.parent\n */\n\n\n cast(value, options) {\n return this.getValue(value, options == null ? void 0 : options.parent, options == null ? void 0 : options.context);\n }\n\n resolve() {\n return this;\n }\n\n describe() {\n return {\n type: 'ref',\n key: this.key\n };\n }\n\n toString() {\n return `Ref(${this.key})`;\n }\n\n static isRef(value) {\n return value && value.__isYupRef;\n }\n\n} // @ts-ignore\n\nReference.prototype.__isYupRef = true;","function _extends() { _extends = Object.assign || 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); }\n\nfunction _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }\n\nimport mapValues from 'lodash/mapValues';\nimport ValidationError from '../ValidationError';\nimport Ref from '../Reference';\nexport default function createValidation(config) {\n function validate(_ref, cb) {\n let {\n value,\n path = '',\n label,\n options,\n originalValue,\n sync\n } = _ref,\n rest = _objectWithoutPropertiesLoose(_ref, [\"value\", \"path\", \"label\", \"options\", \"originalValue\", \"sync\"]);\n\n const {\n name,\n test,\n params,\n message\n } = config;\n let {\n parent,\n context\n } = options;\n\n function resolve(item) {\n return Ref.isRef(item) ? item.getValue(value, parent, context) : item;\n }\n\n function createError(overrides = {}) {\n const nextParams = mapValues(_extends({\n value,\n originalValue,\n label,\n path: overrides.path || path\n }, params, overrides.params), resolve);\n const error = new ValidationError(ValidationError.formatError(overrides.message || message, nextParams), value, nextParams.path, overrides.type || name);\n error.params = nextParams;\n return error;\n }\n\n let ctx = _extends({\n path,\n parent,\n type: name,\n createError,\n resolve,\n options,\n originalValue\n }, rest);\n\n if (!sync) {\n try {\n Promise.resolve(test.call(ctx, value, ctx)).then(validOrError => {\n if (ValidationError.isError(validOrError)) cb(validOrError);else if (!validOrError) cb(createError());else cb(null, validOrError);\n }).catch(cb);\n } catch (err) {\n cb(err);\n }\n\n return;\n }\n\n let result;\n\n try {\n var _ref2;\n\n result = test.call(ctx, value, ctx);\n\n if (typeof ((_ref2 = result) == null ? void 0 : _ref2.then) === 'function') {\n throw new Error(`Validation test of type: \"${ctx.type}\" returned a Promise during a synchronous validate. ` + `This test will finish after the validate call has returned`);\n }\n } catch (err) {\n cb(err);\n return;\n }\n\n if (ValidationError.isError(result)) cb(result);else if (!result) cb(createError());else cb(null, result);\n }\n\n validate.OPTIONS = config;\n return validate;\n}","import { forEach } from 'property-expr';\n\nlet trim = part => part.substr(0, part.length - 1).substr(1);\n\nexport function getIn(schema, path, value, context = value) {\n let parent, lastPart, lastPartDebug; // root path: ''\n\n if (!path) return {\n parent,\n parentPath: path,\n schema\n };\n forEach(path, (_part, isBracket, isArray) => {\n let part = isBracket ? trim(_part) : _part;\n schema = schema.resolve({\n context,\n parent,\n value\n });\n\n if (schema.innerType) {\n let idx = isArray ? parseInt(part, 10) : 0;\n\n if (value && idx >= value.length) {\n throw new Error(`Yup.reach cannot resolve an array item at index: ${_part}, in the path: ${path}. ` + `because there is no value at that index. `);\n }\n\n parent = value;\n value = value && value[idx];\n schema = schema.innerType;\n } // sometimes the array index part of a path doesn't exist: \"nested.arr.child\"\n // in these cases the current part is the next schema and should be processed\n // in this iteration. For cases where the index signature is included this\n // check will fail and we'll handle the `child` part on the next iteration like normal\n\n\n if (!isArray) {\n if (!schema.fields || !schema.fields[part]) throw new Error(`The schema does not contain the path: ${path}. ` + `(failed at: ${lastPartDebug} which is a type: \"${schema._type}\")`);\n parent = value;\n value = value && value[part];\n schema = schema.fields[part];\n }\n\n lastPart = part;\n lastPartDebug = isBracket ? '[' + _part + ']' : '.' + _part;\n });\n return {\n schema,\n parent,\n parentPath: lastPart\n };\n}\n\nconst reach = (obj, path, value, context) => getIn(obj, path, value, context).schema;\n\nexport default reach;","import Reference from '../Reference';\nexport default class ReferenceSet {\n constructor() {\n this.list = void 0;\n this.refs = void 0;\n this.list = new Set();\n this.refs = new Map();\n }\n\n get size() {\n return this.list.size + this.refs.size;\n }\n\n describe() {\n const description = [];\n\n for (const item of this.list) description.push(item);\n\n for (const [, ref] of this.refs) description.push(ref.describe());\n\n return description;\n }\n\n toArray() {\n return Array.from(this.list).concat(Array.from(this.refs.values()));\n }\n\n resolveAll(resolve) {\n return this.toArray().reduce((acc, e) => acc.concat(Reference.isRef(e) ? resolve(e) : e), []);\n }\n\n add(value) {\n Reference.isRef(value) ? this.refs.set(value.key, value) : this.list.add(value);\n }\n\n delete(value) {\n Reference.isRef(value) ? this.refs.delete(value.key) : this.list.delete(value);\n }\n\n clone() {\n const next = new ReferenceSet();\n next.list = new Set(this.list);\n next.refs = new Map(this.refs);\n return next;\n }\n\n merge(newItems, removeItems) {\n const next = this.clone();\n newItems.list.forEach(value => next.add(value));\n newItems.refs.forEach(value => next.add(value));\n removeItems.list.forEach(value => next.delete(value));\n removeItems.refs.forEach(value => next.delete(value));\n return next;\n }\n\n}","function _extends() { _extends = Object.assign || 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); }\n\n// @ts-ignore\nimport cloneDeep from 'nanoclone';\nimport { mixed as locale } from './locale';\nimport Condition from './Condition';\nimport runTests from './util/runTests';\nimport createValidation from './util/createValidation';\nimport printValue from './util/printValue';\nimport Ref from './Reference';\nimport { getIn } from './util/reach';\nimport ValidationError from './ValidationError';\nimport ReferenceSet from './util/ReferenceSet';\nimport toArray from './util/toArray'; // const UNSET = 'unset' as const;\n\nexport default class BaseSchema {\n constructor(options) {\n this.deps = [];\n this.tests = void 0;\n this.transforms = void 0;\n this.conditions = [];\n this._mutate = void 0;\n this._typeError = void 0;\n this._whitelist = new ReferenceSet();\n this._blacklist = new ReferenceSet();\n this.exclusiveTests = Object.create(null);\n this.spec = void 0;\n this.tests = [];\n this.transforms = [];\n this.withMutation(() => {\n this.typeError(locale.notType);\n });\n this.type = (options == null ? void 0 : options.type) || 'mixed';\n this.spec = _extends({\n strip: false,\n strict: false,\n abortEarly: true,\n recursive: true,\n nullable: false,\n presence: 'optional'\n }, options == null ? void 0 : options.spec);\n } // TODO: remove\n\n\n get _type() {\n return this.type;\n }\n\n _typeCheck(_value) {\n return true;\n }\n\n clone(spec) {\n if (this._mutate) {\n if (spec) Object.assign(this.spec, spec);\n return this;\n } // if the nested value is a schema we can skip cloning, since\n // they are already immutable\n\n\n const next = Object.create(Object.getPrototypeOf(this)); // @ts-expect-error this is readonly\n\n next.type = this.type;\n next._typeError = this._typeError;\n next._whitelistError = this._whitelistError;\n next._blacklistError = this._blacklistError;\n next._whitelist = this._whitelist.clone();\n next._blacklist = this._blacklist.clone();\n next.exclusiveTests = _extends({}, this.exclusiveTests); // @ts-expect-error this is readonly\n\n next.deps = [...this.deps];\n next.conditions = [...this.conditions];\n next.tests = [...this.tests];\n next.transforms = [...this.transforms];\n next.spec = cloneDeep(_extends({}, this.spec, spec));\n return next;\n }\n\n label(label) {\n let next = this.clone();\n next.spec.label = label;\n return next;\n }\n\n meta(...args) {\n if (args.length === 0) return this.spec.meta;\n let next = this.clone();\n next.spec.meta = Object.assign(next.spec.meta || {}, args[0]);\n return next;\n } // withContext(): BaseSchema<\n // TCast,\n // TContext,\n // TOutput\n // > {\n // return this as any;\n // }\n\n\n withMutation(fn) {\n let before = this._mutate;\n this._mutate = true;\n let result = fn(this);\n this._mutate = before;\n return result;\n }\n\n concat(schema) {\n if (!schema || schema === this) return this;\n if (schema.type !== this.type && this.type !== 'mixed') throw new TypeError(`You cannot \\`concat()\\` schema's of different types: ${this.type} and ${schema.type}`);\n let base = this;\n let combined = schema.clone();\n\n const mergedSpec = _extends({}, base.spec, combined.spec); // if (combined.spec.nullable === UNSET)\n // mergedSpec.nullable = base.spec.nullable;\n // if (combined.spec.presence === UNSET)\n // mergedSpec.presence = base.spec.presence;\n\n\n combined.spec = mergedSpec;\n combined._typeError || (combined._typeError = base._typeError);\n combined._whitelistError || (combined._whitelistError = base._whitelistError);\n combined._blacklistError || (combined._blacklistError = base._blacklistError); // manually merge the blacklist/whitelist (the other `schema` takes\n // precedence in case of conflicts)\n\n combined._whitelist = base._whitelist.merge(schema._whitelist, schema._blacklist);\n combined._blacklist = base._blacklist.merge(schema._blacklist, schema._whitelist); // start with the current tests\n\n combined.tests = base.tests;\n combined.exclusiveTests = base.exclusiveTests; // manually add the new tests to ensure\n // the deduping logic is consistent\n\n combined.withMutation(next => {\n schema.tests.forEach(fn => {\n next.test(fn.OPTIONS);\n });\n });\n combined.transforms = [...base.transforms, ...combined.transforms];\n return combined;\n }\n\n isType(v) {\n if (this.spec.nullable && v === null) return true;\n return this._typeCheck(v);\n }\n\n resolve(options) {\n let schema = this;\n\n if (schema.conditions.length) {\n let conditions = schema.conditions;\n schema = schema.clone();\n schema.conditions = [];\n schema = conditions.reduce((schema, condition) => condition.resolve(schema, options), schema);\n schema = schema.resolve(options);\n }\n\n return schema;\n }\n /**\n *\n * @param {*} value\n * @param {Object} options\n * @param {*=} options.parent\n * @param {*=} options.context\n */\n\n\n cast(value, options = {}) {\n let resolvedSchema = this.resolve(_extends({\n value\n }, options));\n\n let result = resolvedSchema._cast(value, options);\n\n if (value !== undefined && options.assert !== false && resolvedSchema.isType(result) !== true) {\n let formattedValue = printValue(value);\n let formattedResult = printValue(result);\n throw new TypeError(`The value of ${options.path || 'field'} could not be cast to a value ` + `that satisfies the schema type: \"${resolvedSchema._type}\". \\n\\n` + `attempted value: ${formattedValue} \\n` + (formattedResult !== formattedValue ? `result of cast: ${formattedResult}` : ''));\n }\n\n return result;\n }\n\n _cast(rawValue, _options) {\n let value = rawValue === undefined ? rawValue : this.transforms.reduce((value, fn) => fn.call(this, value, rawValue, this), rawValue);\n\n if (value === undefined) {\n value = this.getDefault();\n }\n\n return value;\n }\n\n _validate(_value, options = {}, cb) {\n let {\n sync,\n path,\n from = [],\n originalValue = _value,\n strict = this.spec.strict,\n abortEarly = this.spec.abortEarly\n } = options;\n let value = _value;\n\n if (!strict) {\n // this._validating = true;\n value = this._cast(value, _extends({\n assert: false\n }, options)); // this._validating = false;\n } // value is cast, we can check if it meets type requirements\n\n\n let args = {\n value,\n path,\n options,\n originalValue,\n schema: this,\n label: this.spec.label,\n sync,\n from\n };\n let initialTests = [];\n if (this._typeError) initialTests.push(this._typeError);\n let finalTests = [];\n if (this._whitelistError) finalTests.push(this._whitelistError);\n if (this._blacklistError) finalTests.push(this._blacklistError);\n runTests({\n args,\n value,\n path,\n sync,\n tests: initialTests,\n endEarly: abortEarly\n }, err => {\n if (err) return void cb(err, value);\n runTests({\n tests: this.tests.concat(finalTests),\n args,\n path,\n sync,\n value,\n endEarly: abortEarly\n }, cb);\n });\n }\n\n validate(value, options, maybeCb) {\n let schema = this.resolve(_extends({}, options, {\n value\n })); // callback case is for nested validations\n\n return typeof maybeCb === 'function' ? schema._validate(value, options, maybeCb) : new Promise((resolve, reject) => schema._validate(value, options, (err, value) => {\n if (err) reject(err);else resolve(value);\n }));\n }\n\n validateSync(value, options) {\n let schema = this.resolve(_extends({}, options, {\n value\n }));\n let result;\n\n schema._validate(value, _extends({}, options, {\n sync: true\n }), (err, value) => {\n if (err) throw err;\n result = value;\n });\n\n return result;\n }\n\n isValid(value, options) {\n return this.validate(value, options).then(() => true, err => {\n if (ValidationError.isError(err)) return false;\n throw err;\n });\n }\n\n isValidSync(value, options) {\n try {\n this.validateSync(value, options);\n return true;\n } catch (err) {\n if (ValidationError.isError(err)) return false;\n throw err;\n }\n }\n\n _getDefault() {\n let defaultValue = this.spec.default;\n\n if (defaultValue == null) {\n return defaultValue;\n }\n\n return typeof defaultValue === 'function' ? defaultValue.call(this) : cloneDeep(defaultValue);\n }\n\n getDefault(options) {\n let schema = this.resolve(options || {});\n return schema._getDefault();\n }\n\n default(def) {\n if (arguments.length === 0) {\n return this._getDefault();\n }\n\n let next = this.clone({\n default: def\n });\n return next;\n }\n\n strict(isStrict = true) {\n let next = this.clone();\n next.spec.strict = isStrict;\n return next;\n }\n\n _isPresent(value) {\n return value != null;\n }\n\n defined(message = locale.defined) {\n return this.test({\n message,\n name: 'defined',\n exclusive: true,\n\n test(value) {\n return value !== undefined;\n }\n\n });\n }\n\n required(message = locale.required) {\n return this.clone({\n presence: 'required'\n }).withMutation(s => s.test({\n message,\n name: 'required',\n exclusive: true,\n\n test(value) {\n return this.schema._isPresent(value);\n }\n\n }));\n }\n\n notRequired() {\n let next = this.clone({\n presence: 'optional'\n });\n next.tests = next.tests.filter(test => test.OPTIONS.name !== 'required');\n return next;\n }\n\n nullable(isNullable = true) {\n let next = this.clone({\n nullable: isNullable !== false\n });\n return next;\n }\n\n transform(fn) {\n let next = this.clone();\n next.transforms.push(fn);\n return next;\n }\n /**\n * Adds a test function to the schema's queue of tests.\n * tests can be exclusive or non-exclusive.\n *\n * - exclusive tests, will replace any existing tests of the same name.\n * - non-exclusive: can be stacked\n *\n * If a non-exclusive test is added to a schema with an exclusive test of the same name\n * the exclusive test is removed and further tests of the same name will be stacked.\n *\n * If an exclusive test is added to a schema with non-exclusive tests of the same name\n * the previous tests are removed and further tests of the same name will replace each other.\n */\n\n\n test(...args) {\n let opts;\n\n if (args.length === 1) {\n if (typeof args[0] === 'function') {\n opts = {\n test: args[0]\n };\n } else {\n opts = args[0];\n }\n } else if (args.length === 2) {\n opts = {\n name: args[0],\n test: args[1]\n };\n } else {\n opts = {\n name: args[0],\n message: args[1],\n test: args[2]\n };\n }\n\n if (opts.message === undefined) opts.message = locale.default;\n if (typeof opts.test !== 'function') throw new TypeError('`test` is a required parameters');\n let next = this.clone();\n let validate = createValidation(opts);\n let isExclusive = opts.exclusive || opts.name && next.exclusiveTests[opts.name] === true;\n\n if (opts.exclusive) {\n if (!opts.name) throw new TypeError('Exclusive tests must provide a unique `name` identifying the test');\n }\n\n if (opts.name) next.exclusiveTests[opts.name] = !!opts.exclusive;\n next.tests = next.tests.filter(fn => {\n if (fn.OPTIONS.name === opts.name) {\n if (isExclusive) return false;\n if (fn.OPTIONS.test === validate.OPTIONS.test) return false;\n }\n\n return true;\n });\n next.tests.push(validate);\n return next;\n }\n\n when(keys, options) {\n if (!Array.isArray(keys) && typeof keys !== 'string') {\n options = keys;\n keys = '.';\n }\n\n let next = this.clone();\n let deps = toArray(keys).map(key => new Ref(key));\n deps.forEach(dep => {\n // @ts-ignore\n if (dep.isSibling) next.deps.push(dep.key);\n });\n next.conditions.push(new Condition(deps, options));\n return next;\n }\n\n typeError(message) {\n let next = this.clone();\n next._typeError = createValidation({\n message,\n name: 'typeError',\n\n test(value) {\n if (value !== undefined && !this.schema.isType(value)) return this.createError({\n params: {\n type: this.schema._type\n }\n });\n return true;\n }\n\n });\n return next;\n }\n\n oneOf(enums, message = locale.oneOf) {\n let next = this.clone();\n enums.forEach(val => {\n next._whitelist.add(val);\n\n next._blacklist.delete(val);\n });\n next._whitelistError = createValidation({\n message,\n name: 'oneOf',\n\n test(value) {\n if (value === undefined) return true;\n let valids = this.schema._whitelist;\n let resolved = valids.resolveAll(this.resolve);\n return resolved.includes(value) ? true : this.createError({\n params: {\n values: valids.toArray().join(', '),\n resolved\n }\n });\n }\n\n });\n return next;\n }\n\n notOneOf(enums, message = locale.notOneOf) {\n let next = this.clone();\n enums.forEach(val => {\n next._blacklist.add(val);\n\n next._whitelist.delete(val);\n });\n next._blacklistError = createValidation({\n message,\n name: 'notOneOf',\n\n test(value) {\n let invalids = this.schema._blacklist;\n let resolved = invalids.resolveAll(this.resolve);\n if (resolved.includes(value)) return this.createError({\n params: {\n values: invalids.toArray().join(', '),\n resolved\n }\n });\n return true;\n }\n\n });\n return next;\n }\n\n strip(strip = true) {\n let next = this.clone();\n next.spec.strip = strip;\n return next;\n }\n\n describe() {\n const next = this.clone();\n const {\n label,\n meta\n } = next.spec;\n const description = {\n meta,\n label,\n type: next.type,\n oneOf: next._whitelist.describe(),\n notOneOf: next._blacklist.describe(),\n tests: next.tests.map(fn => ({\n name: fn.OPTIONS.name,\n params: fn.OPTIONS.params\n })).filter((n, idx, list) => list.findIndex(c => c.name === n.name) === idx)\n };\n return description;\n }\n\n} // eslint-disable-next-line @typescript-eslint/no-unused-vars\n\n// @ts-expect-error\nBaseSchema.prototype.__isYupSchema__ = true;\n\nfor (const method of ['validate', 'validateSync']) BaseSchema.prototype[`${method}At`] = function (path, value, options = {}) {\n const {\n parent,\n parentPath,\n schema\n } = getIn(this, path, value, options.context);\n return schema[method](parent && parent[parentPath], _extends({}, options, {\n parent,\n path\n }));\n};\n\nfor (const alias of ['equals', 'is']) BaseSchema.prototype[alias] = BaseSchema.prototype.oneOf;\n\nfor (const alias of ['not', 'nope']) BaseSchema.prototype[alias] = BaseSchema.prototype.notOneOf;\n\nBaseSchema.prototype.optional = BaseSchema.prototype.notRequired;","import BaseSchema from './schema';\nconst Mixed = BaseSchema;\nexport default Mixed;\nexport function create() {\n return new Mixed();\n} // XXX: this is using the Base schema so that `addMethod(mixed)` works as a base class\n\ncreate.prototype = Mixed.prototype;","const isAbsent = value => value == null;\n\nexport default isAbsent;","import BaseSchema from './schema';\nimport { boolean as locale } from './locale';\nimport isAbsent from './util/isAbsent';\nexport function create() {\n return new BooleanSchema();\n}\nexport default class BooleanSchema extends BaseSchema {\n constructor() {\n super({\n type: 'boolean'\n });\n this.withMutation(() => {\n this.transform(function (value) {\n if (!this.isType(value)) {\n if (/^(true|1)$/i.test(String(value))) return true;\n if (/^(false|0)$/i.test(String(value))) return false;\n }\n\n return value;\n });\n });\n }\n\n _typeCheck(v) {\n if (v instanceof Boolean) v = v.valueOf();\n return typeof v === 'boolean';\n }\n\n isTrue(message = locale.isValue) {\n return this.test({\n message,\n name: 'is-value',\n exclusive: true,\n params: {\n value: 'true'\n },\n\n test(value) {\n return isAbsent(value) || value === true;\n }\n\n });\n }\n\n isFalse(message = locale.isValue) {\n return this.test({\n message,\n name: 'is-value',\n exclusive: true,\n params: {\n value: 'false'\n },\n\n test(value) {\n return isAbsent(value) || value === false;\n }\n\n });\n }\n\n}\ncreate.prototype = BooleanSchema.prototype;","import { string as locale } from './locale';\nimport isAbsent from './util/isAbsent';\nimport BaseSchema from './schema'; // eslint-disable-next-line\n\nlet rEmail = /^((([a-z]|\\d|[!#\\$%&'\\*\\+\\-\\/=\\?\\^_`{\\|}~]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])+(\\.([a-z]|\\d|[!#\\$%&'\\*\\+\\-\\/=\\?\\^_`{\\|}~]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])+)*)|((\\x22)((((\\x20|\\x09)*(\\x0d\\x0a))?(\\x20|\\x09)+)?(([\\x01-\\x08\\x0b\\x0c\\x0e-\\x1f\\x7f]|\\x21|[\\x23-\\x5b]|[\\x5d-\\x7e]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(\\\\([\\x01-\\x09\\x0b\\x0c\\x0d-\\x7f]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]))))*(((\\x20|\\x09)*(\\x0d\\x0a))?(\\x20|\\x09)+)?(\\x22)))@((([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])*([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])))\\.)+(([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])*([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])))$/i; // eslint-disable-next-line\n\nlet rUrl = /^((https?|ftp):)?\\/\\/(((([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(%[\\da-f]{2})|[!\\$&'\\(\\)\\*\\+,;=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|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(%[\\da-f]{2})|[!\\$&'\\(\\)\\*\\+,;=]|:|@)|\\/|\\?)*)?$/i; // eslint-disable-next-line\n\nlet rUUID = /^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;\n\nlet isTrimmed = value => isAbsent(value) || value === value.trim();\n\nlet objStringTag = {}.toString();\nexport function create() {\n return new StringSchema();\n}\nexport default class StringSchema extends BaseSchema {\n constructor() {\n super({\n type: 'string'\n });\n this.withMutation(() => {\n this.transform(function (value) {\n if (this.isType(value)) return value;\n if (Array.isArray(value)) return value;\n const strValue = value != null && value.toString ? value.toString() : value;\n if (strValue === objStringTag) return value;\n return strValue;\n });\n });\n }\n\n _typeCheck(value) {\n if (value instanceof String) value = value.valueOf();\n return typeof value === 'string';\n }\n\n _isPresent(value) {\n return super._isPresent(value) && !!value.length;\n }\n\n length(length, message = locale.length) {\n return this.test({\n message,\n name: 'length',\n exclusive: true,\n params: {\n length\n },\n\n test(value) {\n return isAbsent(value) || value.length === this.resolve(length);\n }\n\n });\n }\n\n min(min, message = locale.min) {\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n min\n },\n\n test(value) {\n return isAbsent(value) || value.length >= this.resolve(min);\n }\n\n });\n }\n\n max(max, message = locale.max) {\n return this.test({\n name: 'max',\n exclusive: true,\n message,\n params: {\n max\n },\n\n test(value) {\n return isAbsent(value) || value.length <= this.resolve(max);\n }\n\n });\n }\n\n matches(regex, options) {\n let excludeEmptyString = false;\n let message;\n let name;\n\n if (options) {\n if (typeof options === 'object') {\n ({\n excludeEmptyString = false,\n message,\n name\n } = options);\n } else {\n message = options;\n }\n }\n\n return this.test({\n name: name || 'matches',\n message: message || locale.matches,\n params: {\n regex\n },\n test: value => isAbsent(value) || value === '' && excludeEmptyString || value.search(regex) !== -1\n });\n }\n\n email(message = locale.email) {\n return this.matches(rEmail, {\n name: 'email',\n message,\n excludeEmptyString: true\n });\n }\n\n url(message = locale.url) {\n return this.matches(rUrl, {\n name: 'url',\n message,\n excludeEmptyString: true\n });\n }\n\n uuid(message = locale.uuid) {\n return this.matches(rUUID, {\n name: 'uuid',\n message,\n excludeEmptyString: false\n });\n } //-- transforms --\n\n\n ensure() {\n return this.default('').transform(val => val === null ? '' : val);\n }\n\n trim(message = locale.trim) {\n return this.transform(val => val != null ? val.trim() : val).test({\n message,\n name: 'trim',\n test: isTrimmed\n });\n }\n\n lowercase(message = locale.lowercase) {\n return this.transform(value => !isAbsent(value) ? value.toLowerCase() : value).test({\n message,\n name: 'string_case',\n exclusive: true,\n test: value => isAbsent(value) || value === value.toLowerCase()\n });\n }\n\n uppercase(message = locale.uppercase) {\n return this.transform(value => !isAbsent(value) ? value.toUpperCase() : value).test({\n message,\n name: 'string_case',\n exclusive: true,\n test: value => isAbsent(value) || value === value.toUpperCase()\n });\n }\n\n}\ncreate.prototype = StringSchema.prototype; //\n// String Interfaces\n//","import { number as locale } from './locale';\nimport isAbsent from './util/isAbsent';\nimport BaseSchema from './schema';\n\nlet isNaN = value => value != +value;\n\nexport function create() {\n return new NumberSchema();\n}\nexport default class NumberSchema extends BaseSchema {\n constructor() {\n super({\n type: 'number'\n });\n this.withMutation(() => {\n this.transform(function (value) {\n let parsed = value;\n\n if (typeof parsed === 'string') {\n parsed = parsed.replace(/\\s/g, '');\n if (parsed === '') return NaN; // don't use parseFloat to avoid positives on alpha-numeric strings\n\n parsed = +parsed;\n }\n\n if (this.isType(parsed)) return parsed;\n return parseFloat(parsed);\n });\n });\n }\n\n _typeCheck(value) {\n if (value instanceof Number) value = value.valueOf();\n return typeof value === 'number' && !isNaN(value);\n }\n\n min(min, message = locale.min) {\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n min\n },\n\n test(value) {\n return isAbsent(value) || value >= this.resolve(min);\n }\n\n });\n }\n\n max(max, message = locale.max) {\n return this.test({\n message,\n name: 'max',\n exclusive: true,\n params: {\n max\n },\n\n test(value) {\n return isAbsent(value) || value <= this.resolve(max);\n }\n\n });\n }\n\n lessThan(less, message = locale.lessThan) {\n return this.test({\n message,\n name: 'max',\n exclusive: true,\n params: {\n less\n },\n\n test(value) {\n return isAbsent(value) || value < this.resolve(less);\n }\n\n });\n }\n\n moreThan(more, message = locale.moreThan) {\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n more\n },\n\n test(value) {\n return isAbsent(value) || value > this.resolve(more);\n }\n\n });\n }\n\n positive(msg = locale.positive) {\n return this.moreThan(0, msg);\n }\n\n negative(msg = locale.negative) {\n return this.lessThan(0, msg);\n }\n\n integer(message = locale.integer) {\n return this.test({\n name: 'integer',\n message,\n test: val => isAbsent(val) || Number.isInteger(val)\n });\n }\n\n truncate() {\n return this.transform(value => !isAbsent(value) ? value | 0 : value);\n }\n\n round(method) {\n var _method;\n\n let avail = ['ceil', 'floor', 'round', 'trunc'];\n method = ((_method = method) == null ? void 0 : _method.toLowerCase()) || 'round'; // this exists for symemtry with the new Math.trunc\n\n if (method === 'trunc') return this.truncate();\n if (avail.indexOf(method.toLowerCase()) === -1) throw new TypeError('Only valid options for round() are: ' + avail.join(', '));\n return this.transform(value => !isAbsent(value) ? Math[method](value) : value);\n }\n\n}\ncreate.prototype = NumberSchema.prototype; //\n// Number Interfaces\n//","/* eslint-disable */\n\n/**\n *\n * Date.parse with progressive enhancement for ISO 8601 \n * NON-CONFORMANT EDITION.\n * © 2011 Colin Snover \n * Released under MIT license.\n */\n// 1 YYYY 2 MM 3 DD 4 HH 5 mm 6 ss 7 msec 8 Z 9 ± 10 tzHH 11 tzmm\nvar isoReg = /^(\\d{4}|[+\\-]\\d{6})(?:-?(\\d{2})(?:-?(\\d{2}))?)?(?:[ T]?(\\d{2}):?(\\d{2})(?::?(\\d{2})(?:[,\\.](\\d{1,}))?)?(?:(Z)|([+\\-])(\\d{2})(?::?(\\d{2}))?)?)?$/;\nexport default function parseIsoDate(date) {\n var numericKeys = [1, 4, 5, 6, 7, 10, 11],\n minutesOffset = 0,\n timestamp,\n struct;\n\n if (struct = isoReg.exec(date)) {\n // avoid NaN timestamps caused by “undefined” values being passed to Date.UTC\n for (var i = 0, k; k = numericKeys[i]; ++i) struct[k] = +struct[k] || 0; // allow undefined days and months\n\n\n struct[2] = (+struct[2] || 1) - 1;\n struct[3] = +struct[3] || 1; // allow arbitrary sub-second precision beyond milliseconds\n\n struct[7] = struct[7] ? String(struct[7]).substr(0, 3) : 0; // timestamps without timezone identifiers should be considered local time\n\n if ((struct[8] === undefined || struct[8] === '') && (struct[9] === undefined || struct[9] === '')) timestamp = +new Date(struct[1], struct[2], struct[3], struct[4], struct[5], struct[6], struct[7]);else {\n if (struct[8] !== 'Z' && struct[9] !== undefined) {\n minutesOffset = struct[10] * 60 + struct[11];\n if (struct[9] === '+') minutesOffset = 0 - minutesOffset;\n }\n\n timestamp = Date.UTC(struct[1], struct[2], struct[3], struct[4], struct[5] + minutesOffset, struct[6], struct[7]);\n }\n } else timestamp = Date.parse ? Date.parse(date) : NaN;\n\n return timestamp;\n}","// @ts-ignore\nimport isoParse from './util/isodate';\nimport { date as locale } from './locale';\nimport isAbsent from './util/isAbsent';\nimport Ref from './Reference';\nimport BaseSchema from './schema';\nlet invalidDate = new Date('');\n\nlet isDate = obj => Object.prototype.toString.call(obj) === '[object Date]';\n\nexport function create() {\n return new DateSchema();\n}\nexport default class DateSchema extends BaseSchema {\n constructor() {\n super({\n type: 'date'\n });\n this.withMutation(() => {\n this.transform(function (value) {\n if (this.isType(value)) return value;\n value = isoParse(value); // 0 is a valid timestamp equivalent to 1970-01-01T00:00:00Z(unix epoch) or before.\n\n return !isNaN(value) ? new Date(value) : invalidDate;\n });\n });\n }\n\n _typeCheck(v) {\n return isDate(v) && !isNaN(v.getTime());\n }\n\n prepareParam(ref, name) {\n let param;\n\n if (!Ref.isRef(ref)) {\n let cast = this.cast(ref);\n if (!this._typeCheck(cast)) throw new TypeError(`\\`${name}\\` must be a Date or a value that can be \\`cast()\\` to a Date`);\n param = cast;\n } else {\n param = ref;\n }\n\n return param;\n }\n\n min(min, message = locale.min) {\n let limit = this.prepareParam(min, 'min');\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n min\n },\n\n test(value) {\n return isAbsent(value) || value >= this.resolve(limit);\n }\n\n });\n }\n\n max(max, message = locale.max) {\n let limit = this.prepareParam(max, 'max');\n return this.test({\n message,\n name: 'max',\n exclusive: true,\n params: {\n max\n },\n\n test(value) {\n return isAbsent(value) || value <= this.resolve(limit);\n }\n\n });\n }\n\n}\nDateSchema.INVALID_DATE = invalidDate;\ncreate.prototype = DateSchema.prototype;\ncreate.INVALID_DATE = invalidDate;","import has from 'lodash/has'; // @ts-expect-error\n\nimport toposort from 'toposort';\nimport { split } from 'property-expr';\nimport Ref from '../Reference';\nimport isSchema from './isSchema';\nexport default function sortFields(fields, excludedEdges = []) {\n let edges = [];\n let nodes = new Set();\n let excludes = new Set(excludedEdges.map(([a, b]) => `${a}-${b}`));\n\n function addNode(depPath, key) {\n let node = split(depPath)[0];\n nodes.add(node);\n if (!excludes.has(`${key}-${node}`)) edges.push([key, node]);\n }\n\n for (const key in fields) if (has(fields, key)) {\n let value = fields[key];\n nodes.add(key);\n if (Ref.isRef(value) && value.isSibling) addNode(value.path, key);else if (isSchema(value) && 'deps' in value) value.deps.forEach(path => addNode(path, key));\n }\n\n return toposort.array(Array.from(nodes), edges).reverse();\n}","function findIndex(arr, err) {\n let idx = Infinity;\n arr.some((key, ii) => {\n var _err$path;\n\n if (((_err$path = err.path) == null ? void 0 : _err$path.indexOf(key)) !== -1) {\n idx = ii;\n return true;\n }\n });\n return idx;\n}\n\nexport default function sortByKeyOrder(keys) {\n return (a, b) => {\n return findIndex(keys, a) - findIndex(keys, b);\n };\n}","function _extends() { _extends = Object.assign || 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); }\n\nimport has from 'lodash/has';\nimport snakeCase from 'lodash/snakeCase';\nimport camelCase from 'lodash/camelCase';\nimport mapKeys from 'lodash/mapKeys';\nimport mapValues from 'lodash/mapValues';\nimport { getter } from 'property-expr';\nimport { object as locale } from './locale';\nimport sortFields from './util/sortFields';\nimport sortByKeyOrder from './util/sortByKeyOrder';\nimport runTests from './util/runTests';\nimport ValidationError from './ValidationError';\nimport BaseSchema from './schema';\n\nlet isObject = obj => Object.prototype.toString.call(obj) === '[object Object]';\n\nfunction unknown(ctx, value) {\n let known = Object.keys(ctx.fields);\n return Object.keys(value).filter(key => known.indexOf(key) === -1);\n}\n\nconst defaultSort = sortByKeyOrder([]);\nexport default class ObjectSchema extends BaseSchema {\n constructor(spec) {\n super({\n type: 'object'\n });\n this.fields = Object.create(null);\n this._sortErrors = defaultSort;\n this._nodes = [];\n this._excludedEdges = [];\n this.withMutation(() => {\n this.transform(function coerce(value) {\n if (typeof value === 'string') {\n try {\n value = JSON.parse(value);\n } catch (err) {\n value = null;\n }\n }\n\n if (this.isType(value)) return value;\n return null;\n });\n\n if (spec) {\n this.shape(spec);\n }\n });\n }\n\n _typeCheck(value) {\n return isObject(value) || typeof value === 'function';\n }\n\n _cast(_value, options = {}) {\n var _options$stripUnknown;\n\n let value = super._cast(_value, options); //should ignore nulls here\n\n\n if (value === undefined) return this.getDefault();\n if (!this._typeCheck(value)) return value;\n let fields = this.fields;\n let strip = (_options$stripUnknown = options.stripUnknown) != null ? _options$stripUnknown : this.spec.noUnknown;\n\n let props = this._nodes.concat(Object.keys(value).filter(v => this._nodes.indexOf(v) === -1));\n\n let intermediateValue = {}; // is filled during the transform below\n\n let innerOptions = _extends({}, options, {\n parent: intermediateValue,\n __validating: options.__validating || false\n });\n\n let isChanged = false;\n\n for (const prop of props) {\n let field = fields[prop];\n let exists = has(value, prop);\n\n if (field) {\n let fieldValue;\n let inputValue = value[prop]; // safe to mutate since this is fired in sequence\n\n innerOptions.path = (options.path ? `${options.path}.` : '') + prop; // innerOptions.value = value[prop];\n\n field = field.resolve({\n value: inputValue,\n context: options.context,\n parent: intermediateValue\n });\n let fieldSpec = 'spec' in field ? field.spec : undefined;\n let strict = fieldSpec == null ? void 0 : fieldSpec.strict;\n\n if (fieldSpec == null ? void 0 : fieldSpec.strip) {\n isChanged = isChanged || prop in value;\n continue;\n }\n\n fieldValue = !options.__validating || !strict ? // TODO: use _cast, this is double resolving\n field.cast(value[prop], innerOptions) : value[prop];\n\n if (fieldValue !== undefined) {\n intermediateValue[prop] = fieldValue;\n }\n } else if (exists && !strip) {\n intermediateValue[prop] = value[prop];\n }\n\n if (intermediateValue[prop] !== value[prop]) {\n isChanged = true;\n }\n }\n\n return isChanged ? intermediateValue : value;\n }\n\n _validate(_value, opts = {}, callback) {\n let errors = [];\n let {\n sync,\n from = [],\n originalValue = _value,\n abortEarly = this.spec.abortEarly,\n recursive = this.spec.recursive\n } = opts;\n from = [{\n schema: this,\n value: originalValue\n }, ...from]; // this flag is needed for handling `strict` correctly in the context of\n // validation vs just casting. e.g strict() on a field is only used when validating\n\n opts.__validating = true;\n opts.originalValue = originalValue;\n opts.from = from;\n\n super._validate(_value, opts, (err, value) => {\n if (err) {\n if (!ValidationError.isError(err) || abortEarly) {\n return void callback(err, value);\n }\n\n errors.push(err);\n }\n\n if (!recursive || !isObject(value)) {\n callback(errors[0] || null, value);\n return;\n }\n\n originalValue = originalValue || value;\n\n let tests = this._nodes.map(key => (_, cb) => {\n let path = key.indexOf('.') === -1 ? (opts.path ? `${opts.path}.` : '') + key : `${opts.path || ''}[\"${key}\"]`;\n let field = this.fields[key];\n\n if (field && 'validate' in field) {\n field.validate(value[key], _extends({}, opts, {\n // @ts-ignore\n path,\n from,\n // inner fields are always strict:\n // 1. this isn't strict so the casting will also have cast inner values\n // 2. this is strict in which case the nested values weren't cast either\n strict: true,\n parent: value,\n originalValue: originalValue[key]\n }), cb);\n return;\n }\n\n cb(null);\n });\n\n runTests({\n sync,\n tests,\n value,\n errors,\n endEarly: abortEarly,\n sort: this._sortErrors,\n path: opts.path\n }, callback);\n });\n }\n\n clone(spec) {\n const next = super.clone(spec);\n next.fields = _extends({}, this.fields);\n next._nodes = this._nodes;\n next._excludedEdges = this._excludedEdges;\n next._sortErrors = this._sortErrors;\n return next;\n }\n\n concat(schema) {\n let next = super.concat(schema);\n let nextFields = next.fields;\n\n for (let [field, schemaOrRef] of Object.entries(this.fields)) {\n const target = nextFields[field];\n\n if (target === undefined) {\n nextFields[field] = schemaOrRef;\n } else if (target instanceof BaseSchema && schemaOrRef instanceof BaseSchema) {\n nextFields[field] = schemaOrRef.concat(target);\n }\n }\n\n return next.withMutation(() => next.shape(nextFields, this._excludedEdges));\n }\n\n getDefaultFromShape() {\n let dft = {};\n\n this._nodes.forEach(key => {\n const field = this.fields[key];\n dft[key] = 'default' in field ? field.getDefault() : undefined;\n });\n\n return dft;\n }\n\n _getDefault() {\n if ('default' in this.spec) {\n return super._getDefault();\n } // if there is no default set invent one\n\n\n if (!this._nodes.length) {\n return undefined;\n }\n\n return this.getDefaultFromShape();\n }\n\n shape(additions, excludes = []) {\n let next = this.clone();\n let fields = Object.assign(next.fields, additions);\n next.fields = fields;\n next._sortErrors = sortByKeyOrder(Object.keys(fields));\n\n if (excludes.length) {\n // this is a convenience for when users only supply a single pair\n if (!Array.isArray(excludes[0])) excludes = [excludes];\n next._excludedEdges = [...next._excludedEdges, ...excludes];\n }\n\n next._nodes = sortFields(fields, next._excludedEdges);\n return next;\n }\n\n pick(keys) {\n const picked = {};\n\n for (const key of keys) {\n if (this.fields[key]) picked[key] = this.fields[key];\n }\n\n return this.clone().withMutation(next => {\n next.fields = {};\n return next.shape(picked);\n });\n }\n\n omit(keys) {\n const next = this.clone();\n const fields = next.fields;\n next.fields = {};\n\n for (const key of keys) {\n delete fields[key];\n }\n\n return next.withMutation(() => next.shape(fields));\n }\n\n from(from, to, alias) {\n let fromGetter = getter(from, true);\n return this.transform(obj => {\n if (obj == null) return obj;\n let newObj = obj;\n\n if (has(obj, from)) {\n newObj = _extends({}, obj);\n if (!alias) delete newObj[from];\n newObj[to] = fromGetter(obj);\n }\n\n return newObj;\n });\n }\n\n noUnknown(noAllow = true, message = locale.noUnknown) {\n if (typeof noAllow === 'string') {\n message = noAllow;\n noAllow = true;\n }\n\n let next = this.test({\n name: 'noUnknown',\n exclusive: true,\n message: message,\n\n test(value) {\n if (value == null) return true;\n const unknownKeys = unknown(this.schema, value);\n return !noAllow || unknownKeys.length === 0 || this.createError({\n params: {\n unknown: unknownKeys.join(', ')\n }\n });\n }\n\n });\n next.spec.noUnknown = noAllow;\n return next;\n }\n\n unknown(allow = true, message = locale.noUnknown) {\n return this.noUnknown(!allow, message);\n }\n\n transformKeys(fn) {\n return this.transform(obj => obj && mapKeys(obj, (_, key) => fn(key)));\n }\n\n camelCase() {\n return this.transformKeys(camelCase);\n }\n\n snakeCase() {\n return this.transformKeys(snakeCase);\n }\n\n constantCase() {\n return this.transformKeys(key => snakeCase(key).toUpperCase());\n }\n\n describe() {\n let base = super.describe();\n base.fields = mapValues(this.fields, value => value.describe());\n return base;\n }\n\n}\nexport function create(spec) {\n return new ObjectSchema(spec);\n}\ncreate.prototype = ObjectSchema.prototype;","function _extends() { _extends = Object.assign || 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); }\n\nimport isAbsent from './util/isAbsent';\nimport isSchema from './util/isSchema';\nimport printValue from './util/printValue';\nimport { array as locale } from './locale';\nimport runTests from './util/runTests';\nimport ValidationError from './ValidationError';\nimport BaseSchema from './schema';\nexport function create(type) {\n return new ArraySchema(type);\n}\nexport default class ArraySchema extends BaseSchema {\n constructor(type) {\n super({\n type: 'array'\n }); // `undefined` specifically means uninitialized, as opposed to\n // \"no subtype\"\n\n this.innerType = void 0;\n this.innerType = type;\n this.withMutation(() => {\n this.transform(function (values) {\n if (typeof values === 'string') try {\n values = JSON.parse(values);\n } catch (err) {\n values = null;\n }\n return this.isType(values) ? values : null;\n });\n });\n }\n\n _typeCheck(v) {\n return Array.isArray(v);\n }\n\n get _subType() {\n return this.innerType;\n }\n\n _cast(_value, _opts) {\n const value = super._cast(_value, _opts); //should ignore nulls here\n\n\n if (!this._typeCheck(value) || !this.innerType) return value;\n let isChanged = false;\n const castArray = value.map((v, idx) => {\n const castElement = this.innerType.cast(v, _extends({}, _opts, {\n path: `${_opts.path || ''}[${idx}]`\n }));\n\n if (castElement !== v) {\n isChanged = true;\n }\n\n return castElement;\n });\n return isChanged ? castArray : value;\n }\n\n _validate(_value, options = {}, callback) {\n var _options$abortEarly, _options$recursive;\n\n let errors = [];\n let sync = options.sync;\n let path = options.path;\n let innerType = this.innerType;\n let endEarly = (_options$abortEarly = options.abortEarly) != null ? _options$abortEarly : this.spec.abortEarly;\n let recursive = (_options$recursive = options.recursive) != null ? _options$recursive : this.spec.recursive;\n let originalValue = options.originalValue != null ? options.originalValue : _value;\n\n super._validate(_value, options, (err, value) => {\n if (err) {\n if (!ValidationError.isError(err) || endEarly) {\n return void callback(err, value);\n }\n\n errors.push(err);\n }\n\n if (!recursive || !innerType || !this._typeCheck(value)) {\n callback(errors[0] || null, value);\n return;\n }\n\n originalValue = originalValue || value; // #950 Ensure that sparse array empty slots are validated\n\n let tests = new Array(value.length);\n\n for (let idx = 0; idx < value.length; idx++) {\n let item = value[idx];\n let path = `${options.path || ''}[${idx}]`; // object._validate note for isStrict explanation\n\n let innerOptions = _extends({}, options, {\n path,\n strict: true,\n parent: value,\n index: idx,\n originalValue: originalValue[idx]\n });\n\n tests[idx] = (_, cb) => innerType.validate(item, innerOptions, cb);\n }\n\n runTests({\n sync,\n path,\n value,\n errors,\n endEarly,\n tests\n }, callback);\n });\n }\n\n clone(spec) {\n const next = super.clone(spec);\n next.innerType = this.innerType;\n return next;\n }\n\n concat(schema) {\n let next = super.concat(schema);\n next.innerType = this.innerType;\n if (schema.innerType) next.innerType = next.innerType ? // @ts-expect-error Lazy doesn't have concat()\n next.innerType.concat(schema.innerType) : schema.innerType;\n return next;\n }\n\n of(schema) {\n // FIXME: this should return a new instance of array without the default to be\n let next = this.clone();\n if (!isSchema(schema)) throw new TypeError('`array.of()` sub-schema must be a valid yup schema not: ' + printValue(schema)); // FIXME(ts):\n\n next.innerType = schema;\n return next;\n }\n\n length(length, message = locale.length) {\n return this.test({\n message,\n name: 'length',\n exclusive: true,\n params: {\n length\n },\n\n test(value) {\n return isAbsent(value) || value.length === this.resolve(length);\n }\n\n });\n }\n\n min(min, message) {\n message = message || locale.min;\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n min\n },\n\n // FIXME(ts): Array\n test(value) {\n return isAbsent(value) || value.length >= this.resolve(min);\n }\n\n });\n }\n\n max(max, message) {\n message = message || locale.max;\n return this.test({\n message,\n name: 'max',\n exclusive: true,\n params: {\n max\n },\n\n test(value) {\n return isAbsent(value) || value.length <= this.resolve(max);\n }\n\n });\n }\n\n ensure() {\n return this.default(() => []).transform((val, original) => {\n // We don't want to return `null` for nullable schema\n if (this._typeCheck(val)) return val;\n return original == null ? [] : [].concat(original);\n });\n }\n\n compact(rejector) {\n let reject = !rejector ? v => !!v : (v, i, a) => !rejector(v, i, a);\n return this.transform(values => values != null ? values.filter(reject) : values);\n }\n\n describe() {\n let base = super.describe();\n if (this.innerType) base.innerType = this.innerType.describe();\n return base;\n }\n\n nullable(isNullable = true) {\n return super.nullable(isNullable);\n }\n\n defined() {\n return super.defined();\n }\n\n required(msg) {\n return super.required(msg);\n }\n\n}\ncreate.prototype = ArraySchema.prototype; //\n// Interfaces\n//","(function() { module.exports = window[\"eventespresso\"][\"slotFill\"]; }());","import useDatetimeQueryOptions from './useDatetimeQueryOptions';\nimport type { Datetime, DatetimeEdge } from '../../types';\nimport { useMemoStringify } from '@eventespresso/hooks';\nimport { getCacheIds } from '@eventespresso/predicates';\nimport { useDatetimesQuery } from '@eventespresso/data';\n\nconst useDatetimes = (): Array => {\n\tconst options = useDatetimeQueryOptions();\n\tconst { data } = useDatetimesQuery(options);\n\n\tconst nodes = data?.espressoDatetimes?.nodes || [];\n\n\tconst cacheIds = getCacheIds(nodes);\n\n\treturn useMemoStringify(nodes, cacheIds);\n};\n\nexport default useDatetimes;\n","import { gql } from '@eventespresso/data';\nimport { PRICE_ATTRIBUTES } from '../../queries/prices';\n\nexport const CREATE_PRICE = gql`\n\tmutation CREATE_PRICE($input: CreateEspressoPriceInput!) {\n\t\tcreateEspressoPrice(input: $input) {\n\t\t\tespressoPrice {\n\t\t\t\t...priceAttributes\n\t\t\t}\n\t\t}\n\t}\n\t${PRICE_ATTRIBUTES}\n`;\n\nexport const UPDATE_PRICE = gql`\n\tmutation UPDATE_PRICE($input: UpdateEspressoPriceInput!) {\n\t\tupdateEspressoPrice(input: $input) {\n\t\t\tespressoPrice {\n\t\t\t\t...priceAttributes\n\t\t\t}\n\t\t}\n\t}\n\t${PRICE_ATTRIBUTES}\n`;\n\nexport const DELETE_PRICE = gql`\n\tmutation DELETE_PRICE($input: DeleteEspressoPriceInput!) {\n\t\tdeleteEspressoPrice(input: $input) {\n\t\t\tespressoPrice {\n\t\t\t\tid\n\t\t\t}\n\t\t}\n\t}\n`;\n\nexport { default as usePriceMutator } from './usePriceMutator';\n\nexport { default as useBulkDeletePrices } from './useBulkDeletePrices';\n\nexport * from './types';\n","export * from './global';\n","export * from './initialization';\n\nexport * from './meta';\n\nexport * from './mutations';\n\nexport * from './queries';\n\nexport * from './types';\n","var root = require('./_root');\n\n/** Built-in value references. */\nvar Symbol = root.Symbol;\n\nmodule.exports = Symbol;\n","var getNative = require('./_getNative');\n\n/* Built-in method references that are verified to be native. */\nvar nativeCreate = getNative(Object, 'create');\n\nmodule.exports = nativeCreate;\n","var listCacheClear = require('./_listCacheClear'),\n listCacheDelete = require('./_listCacheDelete'),\n listCacheGet = require('./_listCacheGet'),\n listCacheHas = require('./_listCacheHas'),\n listCacheSet = require('./_listCacheSet');\n\n/**\n * Creates an list cache object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction ListCache(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `ListCache`.\nListCache.prototype.clear = listCacheClear;\nListCache.prototype['delete'] = listCacheDelete;\nListCache.prototype.get = listCacheGet;\nListCache.prototype.has = listCacheHas;\nListCache.prototype.set = listCacheSet;\n\nmodule.exports = ListCache;\n","var eq = require('./eq');\n\n/**\n * Gets the index at which the `key` is found in `array` of key-value pairs.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {*} key The key to search for.\n * @returns {number} Returns the index of the matched value, else `-1`.\n */\nfunction assocIndexOf(array, key) {\n var length = array.length;\n while (length--) {\n if (eq(array[length][0], key)) {\n return length;\n }\n }\n return -1;\n}\n\nmodule.exports = assocIndexOf;\n","var isKeyable = require('./_isKeyable');\n\n/**\n * Gets the data for `map`.\n *\n * @private\n * @param {Object} map The map to query.\n * @param {string} key The reference key.\n * @returns {*} Returns the map data.\n */\nfunction getMapData(map, key) {\n var data = map.__data__;\n return isKeyable(key)\n ? data[typeof key == 'string' ? 'string' : 'hash']\n : data.map;\n}\n\nmodule.exports = getMapData;\n","var isSymbol = require('./isSymbol');\n\n/** Used as references for various `Number` constants. */\nvar INFINITY = 1 / 0;\n\n/**\n * Converts `value` to a string key if it's not a string or symbol.\n *\n * @private\n * @param {*} value The value to inspect.\n * @returns {string|symbol} Returns the key.\n */\nfunction toKey(value) {\n if (typeof value == 'string' || isSymbol(value)) {\n return value;\n }\n var result = (value + '');\n return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;\n}\n\nmodule.exports = toKey;\n","import type {\n\tApolloCache,\n\tEntity as BaseEntity,\n\tEntity,\n\tMutationInput,\n\tMutationType,\n\tMutationUpdaterFn,\n\tOperationVariables,\n} from '@eventespresso/data';\nimport type { Merge, AnyObject } from '@eventespresso/utils';\nimport type { ShiftDateArgs } from '@eventespresso/dates';\nimport type { Datetime, DatetimeEdge, Ticket, TicketEdge, Price, PriceEdge } from '../types';\n\nexport interface MutationCallbackFnArgs {\n\tcache?: ApolloCache;\n}\n\ninterface CommonArgs {\n\tdeletePermanently?: boolean;\n}\n\n/* Datetime specific */\nexport interface DatetimeMutationCallbackFnArgs extends MutationCallbackFnArgs, CommonArgs {\n\tdatetime: Datetime;\n\tdatetimes?: DatetimeEdge;\n\ttickets?: string[];\n}\nexport type DatetimeMutationCallbackFn = (args: DatetimeMutationCallbackFnArgs) => void;\n\n/* Ticket specific */\nexport interface TicketMutationCallbackFnArgs extends MutationCallbackFnArgs, CommonArgs {\n\tticket: Ticket;\n\ttickets?: TicketEdge;\n\tdatetimeIds?: string[];\n\tprices?: PriceEdge;\n\tpriceIds?: string[];\n}\nexport type TicketMutationCallbackFn = (args: TicketMutationCallbackFnArgs) => void;\n\n/* Price specific */\nexport interface PriceMutationCallbackFnArgs extends MutationCallbackFnArgs, CommonArgs {\n\tprice: Price;\n\tprices?: PriceEdge;\n\tpriceTypeId?: string;\n\tticketId?: string;\n}\nexport type PriceMutationCallbackFn = (args: PriceMutationCallbackFnArgs) => void;\n\n/* Generic cache updater */\nexport interface CacheUpdaterFnArgs extends MutationCallbackFnArgs {\n\taction: 'add' | 'update' | 'remove';\n\tdatetime?: Datetime;\n\tdatetimeId?: string;\n\tdatetimeIn?: string[];\n\tdatetimes?: DatetimeEdge;\n\tprice?: Price;\n\tprices?: PriceEdge;\n\tticket?: Ticket;\n\tticketId?: string;\n\tticketIn?: string[];\n\ttickets?: TicketEdge;\n}\n\nexport type CacheUpdaterFn = (args: CacheUpdaterFnArgs) => void;\n\nexport enum TypeName {\n\tDatetime = 'Datetime',\n\tEvent = 'Event',\n\tTicket = 'Ticket',\n\tPrice = 'Price',\n\tPriceType = 'PriceType',\n}\n\nexport type OnUpdateFnOptions = {\n\tcache: ApolloCache;\n\tentity: Entity;\n};\n\nexport type OnUpdateFn = (options: OnUpdateFnOptions) => void;\n\nexport interface MutationInputWithId {\n\tclientMutationId: string;\n}\n\nexport interface MutationVariables {\n\tinput: Merge;\n}\n/*********************************/\nexport interface MutationBaseProps {\n\tinput: MI;\n\tmutationType: MutationType;\n}\n\nexport interface MutationUpdaterArgs\n\textends MutationBaseProps {\n\tcache: ApolloCache;\n\tentity: E;\n}\n\nexport type MutationUpdater = (\n\targs: MutationUpdaterArgs\n) => void;\n\nexport type MutationHandler = (\n\tmutationType: MutationType,\n\tinput: MI\n) => MutatorGeneratedObject;\n\nexport interface MutatorGeneratedObject {\n\tonUpdate?: MutationUpdater;\n\toptimisticResponse?: any;\n\tvariables: OperationVariables;\n}\n\nexport interface UpdaterCallbackArgs\n\textends MutationBaseProps {\n\tonUpdate?: MutationUpdater;\n}\n\nexport type UpdaterCallback = (\n\targs: UpdaterCallbackArgs\n) => MutationUpdaterFn;\n\nexport interface BulkUpdateInput {\n\tsharedInput?: T;\n\tuniqueInputs: Array;\n}\nexport interface BulkEditFormBaseShape extends Partial {\n\tshiftDates?: ShiftDateArgs;\n}\n","var baseAssignValue = require('./_baseAssignValue'),\n baseForOwn = require('./_baseForOwn'),\n baseIteratee = require('./_baseIteratee');\n\n/**\n * Creates an object with the same keys as `object` and values generated\n * by running each own enumerable string keyed property of `object` thru\n * `iteratee`. The iteratee is invoked with three arguments:\n * (value, key, object).\n *\n * @static\n * @memberOf _\n * @since 2.4.0\n * @category Object\n * @param {Object} object The object to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @returns {Object} Returns the new mapped object.\n * @see _.mapKeys\n * @example\n *\n * var users = {\n * 'fred': { 'user': 'fred', 'age': 40 },\n * 'pebbles': { 'user': 'pebbles', 'age': 1 }\n * };\n *\n * _.mapValues(users, function(o) { return o.age; });\n * // => { 'fred': 40, 'pebbles': 1 } (iteration order is not guaranteed)\n *\n * // The `_.property` iteratee shorthand.\n * _.mapValues(users, 'age');\n * // => { 'fred': 40, 'pebbles': 1 } (iteration order is not guaranteed)\n */\nfunction mapValues(object, iteratee) {\n var result = {};\n iteratee = baseIteratee(iteratee, 3);\n\n baseForOwn(object, function(value, key, object) {\n baseAssignValue(result, key, iteratee(value, key, object));\n });\n return result;\n}\n\nmodule.exports = mapValues;\n","import setPrototypeOf from \"@babel/runtime/helpers/esm/setPrototypeOf\";\nimport isNativeReflectConstruct from \"@babel/runtime/helpers/esm/isNativeReflectConstruct\";\nexport default function _construct(Parent, args, Class) {\n if (isNativeReflectConstruct()) {\n _construct = Reflect.construct;\n } else {\n _construct = function _construct(Parent, args, Class) {\n var a = [null];\n a.push.apply(a, args);\n var Constructor = Function.bind.apply(Parent, a);\n var instance = new Constructor();\n if (Class) setPrototypeOf(instance, Class.prototype);\n return instance;\n };\n }\n\n return _construct.apply(null, arguments);\n}","import getPrototypeOf from \"@babel/runtime/helpers/esm/getPrototypeOf\";\nimport setPrototypeOf from \"@babel/runtime/helpers/esm/setPrototypeOf\";\nimport isNativeFunction from \"@babel/runtime/helpers/esm/isNativeFunction\";\nimport construct from \"@babel/runtime/helpers/esm/construct\";\nexport default function _wrapNativeSuper(Class) {\n var _cache = typeof Map === \"function\" ? new Map() : undefined;\n\n _wrapNativeSuper = function _wrapNativeSuper(Class) {\n if (Class === null || !isNativeFunction(Class)) return Class;\n\n if (typeof Class !== \"function\") {\n throw new TypeError(\"Super expression must either be null or a function\");\n }\n\n if (typeof _cache !== \"undefined\") {\n if (_cache.has(Class)) return _cache.get(Class);\n\n _cache.set(Class, Wrapper);\n }\n\n function Wrapper() {\n return construct(Class, arguments, getPrototypeOf(this).constructor);\n }\n\n Wrapper.prototype = Object.create(Class.prototype, {\n constructor: {\n value: Wrapper,\n enumerable: false,\n writable: true,\n configurable: true\n }\n });\n return setPrototypeOf(Wrapper, Class);\n };\n\n return _wrapNativeSuper(Class);\n}","export default function _isNativeFunction(fn) {\n return Function.toString.call(fn).indexOf(\"[native code]\") !== -1;\n}","(function() { module.exports = window[\"eventespresso\"][\"storage\"]; }());","import { useMemo } from 'react';\n\nimport type { DatetimesList, DatetimesQueryArgs, CacheQueryOptions } from '@eventespresso/data';\n\nimport useEventId from '../events/useEventId';\nimport { GET_DATETIMES } from '../datetimes';\nimport type { DatetimeEdge } from '../../';\n\ntype DatetimesQueryOptions = CacheQueryOptions, DatetimesQueryArgs>;\n\nconst useDatetimeQueryOptions = (): DatetimesQueryOptions => {\n\tconst eventId = useEventId();\n\n\treturn useMemo(() => {\n\t\treturn {\n\t\t\tquery: GET_DATETIMES,\n\t\t\tvariables: {\n\t\t\t\twhere: {\n\t\t\t\t\teventId,\n\t\t\t\t},\n\t\t\t},\n\t\t};\n\t}, [eventId]);\n};\n\nexport default useDatetimeQueryOptions;\n","import { useMemo } from 'react';\n\nimport type { TicketsList, TicketsQueryArgs, CacheQueryOptions } from '@eventespresso/data';\n\nimport { GET_TICKETS } from '../tickets';\nimport type { TicketEdge } from '../../';\nimport useEventId from '../events/useEventId';\n\nexport type TicketsQueryOptions = CacheQueryOptions, TicketsQueryArgs>;\n\nconst useTicketQueryOptions = (queryArgs?: TicketsQueryArgs['where']): TicketsQueryOptions => {\n\tconst eventId = useEventId();\n\n\treturn useMemo(() => {\n\t\treturn {\n\t\t\tquery: GET_TICKETS,\n\t\t\tvariables: {\n\t\t\t\twhere: {\n\t\t\t\t\teventId,\n\t\t\t\t\tincludeDefaultTickets: true,\n\t\t\t\t\t...queryArgs,\n\t\t\t\t},\n\t\t\t},\n\t\t};\n\t}, [eventId, queryArgs]);\n};\n\nexport default useTicketQueryOptions;\n","const useEventId = (): number => {\n\treturn window?.eventEspressoData?.eventEditor?.event?.dbId || 0;\n};\n\nexport default useEventId;\n","import { useCallback } from 'react';\nimport type { MutationUpdaterFn } from '@apollo/client';\nimport { pathOr } from 'ramda';\n\nimport type { TypeName, UpdaterCallback } from './types';\n\nconst useUpdateCallback = (typeName: TypeName): UpdaterCallback => {\n\treturn useCallback(\n\t\t({ onUpdate, mutationType, input }) => {\n\t\t\t/**\n\t\t\t * Since every mutation update callback is interested\n\t\t\t * in the updated entity data in response, we will\n\t\t\t * pass just that entity to onUpdate.\n\t\t\t */\n\t\t\tconst update: MutationUpdaterFn = (cache, result) => {\n\t\t\t\t// e.g. \"createDatetime\", \"updateTicket\"\n\t\t\t\tconst mutationName = `${mutationType.toLowerCase()}Espresso${typeName}`;\n\t\t\t\t// Example result: { data: { deletePrice: { price : {...} } } }\n\t\t\t\tconst path = ['data', mutationName, `espresso${typeName}`];\n\t\t\t\tconst entity = pathOr({}, path, result);\n\n\t\t\t\tonUpdate?.({ cache, entity, mutationType, input });\n\t\t\t};\n\t\t\treturn update;\n\t\t},\n\t\t[typeName]\n\t);\n};\n\nexport default useUpdateCallback;\n","import { gql } from '@eventespresso/data';\nimport { PRICE_TYPE_ATTRIBUTES } from '../priceTypes';\n\nexport const PRICE_ATTRIBUTES: any = gql`\n\tfragment priceAttributes on EspressoPrice {\n\t\tid\n\t\tdbId\n\t\tamount\n\t\tcacheId\n\t\tdescription\n\t\tisBasePrice\n\t\tisDefault\n\t\tisDiscount\n\t\tisPercent\n\t\tisTax\n\t\tisTrashed\n\t\tname\n\t\torder\n\t\toverrides\n\t}\n`;\n\n/**\n * The related priceType for a price.\n * Can be used to fetch the related priceType\n * created for a price on the server.\n */\nexport const PRICE_BASE_TYPE_ATTRIBUTE: any = gql`\n\tfragment priceBaseTypeAttribute on EspressoPrice {\n\t\tpriceType {\n\t\t\t...priceTypeAttributes\n\t\t}\n\t}\n\t${PRICE_TYPE_ATTRIBUTES}\n`;\n\nexport const GET_PRICE: any = gql`\n\tquery GET_PRICE($id: ID!) {\n\t\tprice(id: $id) {\n\t\t\t...priceAttributes\n\t\t}\n\t}\n\t${PRICE_ATTRIBUTES}\n`;\n\nexport const GET_PRICES: any = gql`\n\tquery GET_PRICES($where: EspressoRootQueryPricesConnectionWhereArgs) {\n\t\tespressoPrices(where: $where) {\n\t\t\tnodes {\n\t\t\t\t...priceAttributes\n\t\t\t}\n\t\t}\n\t}\n\t${PRICE_ATTRIBUTES}\n`;\n","module.exports = function(module) {\n\tif (!module.webpackPolyfill) {\n\t\tmodule.deprecate = function() {};\n\t\tmodule.paths = [];\n\t\t// module.parent = undefined by default\n\t\tif (!module.children) module.children = [];\n\t\tObject.defineProperty(module, \"loaded\", {\n\t\t\tenumerable: true,\n\t\t\tget: function() {\n\t\t\t\treturn module.l;\n\t\t\t}\n\t\t});\n\t\tObject.defineProperty(module, \"id\", {\n\t\t\tenumerable: true,\n\t\t\tget: function() {\n\t\t\t\treturn module.i;\n\t\t\t}\n\t\t});\n\t\tmodule.webpackPolyfill = 1;\n\t}\n\treturn module;\n};\n","export * from './datetimes';\n\nexport * from './tickets';\n\nexport * from './types';\n","var isArray = require('./isArray'),\n isSymbol = require('./isSymbol');\n\n/** Used to match property names within property paths. */\nvar reIsDeepProp = /\\.|\\[(?:[^[\\]]*|([\"'])(?:(?!\\1)[^\\\\]|\\\\.)*?\\1)\\]/,\n reIsPlainProp = /^\\w*$/;\n\n/**\n * Checks if `value` is a property name and not a property path.\n *\n * @private\n * @param {*} value The value to check.\n * @param {Object} [object] The object to query keys on.\n * @returns {boolean} Returns `true` if `value` is a property name, else `false`.\n */\nfunction isKey(value, object) {\n if (isArray(value)) {\n return false;\n }\n var type = typeof value;\n if (type == 'number' || type == 'symbol' || type == 'boolean' ||\n value == null || isSymbol(value)) {\n return true;\n }\n return reIsPlainProp.test(value) || !reIsDeepProp.test(value) ||\n (object != null && value in Object(object));\n}\n\nmodule.exports = isKey;\n","var baseGetTag = require('./_baseGetTag'),\n isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar symbolTag = '[object Symbol]';\n\n/**\n * Checks if `value` is classified as a `Symbol` primitive or object.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a symbol, else `false`.\n * @example\n *\n * _.isSymbol(Symbol.iterator);\n * // => true\n *\n * _.isSymbol('abc');\n * // => false\n */\nfunction isSymbol(value) {\n return typeof value == 'symbol' ||\n (isObjectLike(value) && baseGetTag(value) == symbolTag);\n}\n\nmodule.exports = isSymbol;\n","var mapCacheClear = require('./_mapCacheClear'),\n mapCacheDelete = require('./_mapCacheDelete'),\n mapCacheGet = require('./_mapCacheGet'),\n mapCacheHas = require('./_mapCacheHas'),\n mapCacheSet = require('./_mapCacheSet');\n\n/**\n * Creates a map cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction MapCache(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `MapCache`.\nMapCache.prototype.clear = mapCacheClear;\nMapCache.prototype['delete'] = mapCacheDelete;\nMapCache.prototype.get = mapCacheGet;\nMapCache.prototype.has = mapCacheHas;\nMapCache.prototype.set = mapCacheSet;\n\nmodule.exports = MapCache;\n","/**\n * Checks if `value` is the\n * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)\n * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an object, else `false`.\n * @example\n *\n * _.isObject({});\n * // => true\n *\n * _.isObject([1, 2, 3]);\n * // => true\n *\n * _.isObject(_.noop);\n * // => true\n *\n * _.isObject(null);\n * // => false\n */\nfunction isObject(value) {\n var type = typeof value;\n return value != null && (type == 'object' || type == 'function');\n}\n\nmodule.exports = isObject;\n","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar Map = getNative(root, 'Map');\n\nmodule.exports = Map;\n","/** Used as references for various `Number` constants. */\nvar MAX_SAFE_INTEGER = 9007199254740991;\n\n/**\n * Checks if `value` is a valid array-like length.\n *\n * **Note:** This method is loosely based on\n * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a valid length, else `false`.\n * @example\n *\n * _.isLength(3);\n * // => true\n *\n * _.isLength(Number.MIN_VALUE);\n * // => false\n *\n * _.isLength(Infinity);\n * // => false\n *\n * _.isLength('3');\n * // => false\n */\nfunction isLength(value) {\n return typeof value == 'number' &&\n value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;\n}\n\nmodule.exports = isLength;\n","var arrayLikeKeys = require('./_arrayLikeKeys'),\n baseKeys = require('./_baseKeys'),\n isArrayLike = require('./isArrayLike');\n\n/**\n * Creates an array of the own enumerable property names of `object`.\n *\n * **Note:** Non-object values are coerced to objects. See the\n * [ES spec](http://ecma-international.org/ecma-262/7.0/#sec-object.keys)\n * for more details.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Object\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.keys(new Foo);\n * // => ['a', 'b'] (iteration order is not guaranteed)\n *\n * _.keys('hi');\n * // => ['0', '1']\n */\nfunction keys(object) {\n return isArrayLike(object) ? arrayLikeKeys(object) : baseKeys(object);\n}\n\nmodule.exports = keys;\n","var createCompounder = require('./_createCompounder');\n\n/**\n * Converts `string` to\n * [snake case](https://en.wikipedia.org/wiki/Snake_case).\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to convert.\n * @returns {string} Returns the snake cased string.\n * @example\n *\n * _.snakeCase('Foo Bar');\n * // => 'foo_bar'\n *\n * _.snakeCase('fooBar');\n * // => 'foo_bar'\n *\n * _.snakeCase('--FOO-BAR--');\n * // => 'foo_bar'\n */\nvar snakeCase = createCompounder(function(result, word, index) {\n return result + (index ? '_' : '') + word.toLowerCase();\n});\n\nmodule.exports = snakeCase;\n","import { DataProvider } from '@eventespresso/data';\nimport { ThemeProvider } from '@eventespresso/adapters';\nimport { SlotFillProvider } from '@eventespresso/slot-fill';\nimport { ConfigProvider, FeaturesProvider, RelationsProvider, StatusProvider } from '@eventespresso/services';\nimport { GlobalModalProvider } from '@eventespresso/registry';\n\nexport const ServiceProvider: React.FC = ({ children }) => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t{children}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport const ContextProvider: React.FC = ({ children }) => (\n\t\n\t\t{children}\n\t\n);\n","import { ContextProvider } from './ContextProvider';\nimport type { AnyObject } from '@eventespresso/utils';\n\nconst withEdtrContext =

(Component: React.ComponentType

): React.FC

=> {\n\tconst WrappedComponent: React.FC

= (props) => {\n\t\treturn (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t);\n\t};\n\n\treturn WrappedComponent;\n};\n\nexport default withEdtrContext;\n","import { DatesFilterStateProvider } from './DatesFilterStateProvider';\nimport { FilteredDatesProvider } from './FilteredDatesProvider';\n\nexport const DatetimesListProvider: React.FC = ({ children }) => {\n\treturn (\n\t\t\n\t\t\t{children}\n\t\t\n\t);\n};\n","import { TicketsFilterStateProvider } from './TicketsFilterStateProvider';\nimport { FilteredTicketsProvider } from './FilteredTicketsProvider';\n\nexport const TicketsListProvider: React.FC = ({ children }) => {\n\treturn (\n\t\t\n\t\t\t{children}\n\t\t\n\t);\n};\n","interface ContextHOCArgs {\n\tProvider: React.ComponentType;\n\tComponent: React.ComponentType;\n\t[key: string]: any;\n}\n\nconst withEntityListContext = ({ Provider, Component, ...props }: ContextHOCArgs): React.FC => {\n\tconst wrappedComponent: React.FC = () => {\n\t\treturn (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t);\n\t};\n\n\treturn wrappedComponent;\n};\n\nexport default withEntityListContext;\n","import { useMemoStringify } from '@eventespresso/hooks';\nimport { getGuids } from '@eventespresso/predicates';\nimport { EntityId } from '@eventespresso/data';\nimport useDatetimes from './useDatetimes';\n\nconst useDatetimeIds = (): EntityId[] => {\n\tconst datetimes = useDatetimes();\n\n\treturn useMemoStringify(getGuids(datetimes));\n};\n\nexport default useDatetimeIds;\n","import { useMemo } from 'react';\n\nimport { useCacheQuery, CacheQueryOptions } from '@eventespresso/data';\nimport { useMemoStringify } from '@eventespresso/hooks';\n\nimport { GET_DATETIME } from './queries';\nimport type { Datetime, DatetimeItem } from '../../types';\nimport type { EntityItemProps } from '../types';\n\nconst useDatetimeItem = ({ id }: EntityItemProps): Datetime => {\n\tconst options = useMemo(\n\t\t() => ({\n\t\t\tquery: GET_DATETIME,\n\t\t\tvariables: {\n\t\t\t\tid,\n\t\t\t},\n\t\t\treturnPartialData: true, // avoid console warnings if data not present\n\t\t}),\n\t\t[id]\n\t);\n\tconst { data } = useCacheQuery(options);\n\n\treturn useMemoStringify(data?.espressoDatetime);\n};\n\nexport default useDatetimeItem;\n","import { useMemo } from 'react';\n\nimport { entitiesWithGuIdInArray } from '@eventespresso/predicates';\nimport { entityListCacheIdString } from '@eventespresso/utils';\nimport { useRelations } from '@eventespresso/services';\nimport useDatetimes from './useDatetimes';\nimport type { Datetime } from '../../types';\nimport type { RelatedEntitiesHook } from '../types';\n\nconst useRelatedDatetimes: RelatedEntitiesHook = ({ entity, entityId }) => {\n\tconst datetimes = useDatetimes();\n\tconst { getRelations } = useRelations();\n\tconst relatedDatetimeIds = getRelations({\n\t\tentity,\n\t\tentityId,\n\t\trelation: 'datetimes',\n\t});\n\n\tconst cacheIds = entityListCacheIdString(datetimes);\n\tconst relatedDatetimeIdsStr = JSON.stringify(relatedDatetimeIds);\n\n\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\treturn useMemo(() => entitiesWithGuIdInArray(datetimes, relatedDatetimeIds), [relatedDatetimeIdsStr, cacheIds]);\n};\n\nexport default useRelatedDatetimes;\n","import { useMemo } from 'react';\n\nimport { entitiesWithGuIdInArray } from '@eventespresso/predicates';\nimport { entityListCacheIdString } from '@eventespresso/utils';\nimport { useRelations } from '@eventespresso/services';\nimport usePrices from './usePrices';\nimport type { Price } from '../../types';\nimport type { RelatedEntitiesHook } from '../types';\n\nconst useRelatedPrices: RelatedEntitiesHook = ({ entity, entityId }) => {\n\tconst prices = usePrices();\n\tconst { getRelations } = useRelations();\n\tconst relatedPriceIds = getRelations({\n\t\tentity,\n\t\tentityId,\n\t\trelation: 'prices',\n\t});\n\n\tconst cacheIds = entityListCacheIdString(prices);\n\tconst relatedPriceIdsStr = JSON.stringify(relatedPriceIds);\n\n\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\treturn useMemo(() => entitiesWithGuIdInArray(prices, relatedPriceIds), [relatedPriceIdsStr, cacheIds]);\n};\n\nexport default useRelatedPrices;\n","import { gql } from '@eventespresso/data';\n\nimport { EVENT_ATTRIBUTES } from '../../queries/events';\n\nexport const UPDATE_EVENT = gql`\n\tmutation UPDATE_EVENT($input: UpdateEspressoEventInput!) {\n\t\tupdateEspressoEvent(input: $input) {\n\t\t\tespressoEvent {\n\t\t\t\t...eventAttributes\n\t\t\t}\n\t\t}\n\t}\n\t${EVENT_ATTRIBUTES}\n`;\n\nexport { default as useEventMutator } from './useEventMutator';\n\nexport * from './types';\n","import type { BasicSortBy } from '@eventespresso/services';\n\nexport type SortBy = BasicSortBy | 'date' | 'order';\n\nexport enum DisplayStartOrEndDate {\n\tstart = 'start',\n\tend = 'end',\n\tboth = 'both',\n}\n\nexport interface EntityFilterState {\n\tdisplayStartOrEndDate?: DisplayStartOrEndDate;\n}\n\nexport type EntityFilterActionType = 'SET_DISPLAY_START_OR_END_DATE';\n\nexport interface EntityFilterAction extends Partial {\n\ttype: EntityFilterActionType | AcionType;\n}\n\nexport interface EntityFilterStateManager extends EntityFilterState {\n\tsetDisplayStartOrEndDate: (displayStartOrEndDate: DisplayStartOrEndDate) => void;\n}\n\nexport type EntityFilterStateReducer> = (\n\tstate: EFS,\n\taction: EFA\n) => EFS;\n","import { useMemo } from 'react';\n\nimport type { PricesList, PricesQueryArgs, CacheQueryOptions } from '@eventespresso/data';\n\nimport { GET_PRICES } from '../prices';\nimport useEventId from '../events/useEventId';\nimport type { PriceEdge } from '../../';\n\nexport type PricesQueryOptions = CacheQueryOptions, PricesQueryArgs>;\n\nconst usePriceQueryOptions = (queryArgs?: PricesQueryArgs['where']): PricesQueryOptions => {\n\tconst eventId = useEventId();\n\n\treturn useMemo(() => {\n\t\treturn {\n\t\t\tquery: GET_PRICES,\n\t\t\tvariables: {\n\t\t\t\twhere: {\n\t\t\t\t\teventId,\n\t\t\t\t\tincludeDefaultTicketsPrices: true,\n\t\t\t\t\tincludeDefaultPrices: true,\n\t\t\t\t\t...queryArgs,\n\t\t\t\t},\n\t\t\t},\n\t\t};\n\t}, [eventId, queryArgs]);\n};\n\nexport default usePriceQueryOptions;\n","import { useCallback } from 'react';\nimport { findIndex, update } from 'ramda';\n\nimport { WriteQueryOptions } from '@eventespresso/data';\nimport { entityHasGuid } from '@eventespresso/predicates';\n\nimport { useTicketQueryOptions } from '../../queries';\nimport type { CacheUpdaterFn, CacheUpdaterFnArgs } from '../types';\nimport { Ticket, TicketsList } from '../../';\n\nconst useUpdateTicketCache = (): CacheUpdaterFn => {\n\tconst queryOptions = useTicketQueryOptions();\n\n\tconst updateTicketCache = useCallback(\n\t\t({ cache, tickets, ticket, action }: CacheUpdaterFnArgs): void => {\n\t\t\tconst { nodes = [] } = tickets;\n\t\t\tlet newNodes: Array = [],\n\t\t\t\tticketIndex: number;\n\t\t\tswitch (action) {\n\t\t\t\tcase 'add':\n\t\t\t\t\tnewNodes = [...nodes, ticket];\n\t\t\t\t\tbreak;\n\t\t\t\tcase 'update':\n\t\t\t\t\t// find the index of the ticket to update\n\t\t\t\t\tticketIndex = findIndex(entityHasGuid(ticket.id), nodes);\n\t\t\t\t\t// if ticket exists\n\t\t\t\t\tif (ticketIndex >= 0) {\n\t\t\t\t\t\tnewNodes = update(ticketIndex, ticket, nodes);\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase 'remove':\n\t\t\t\t\tnewNodes = nodes.filter(({ id }) => id !== ticket.id);\n\t\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t\tnewNodes = nodes;\n\t\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\t// write the data to cache without\n\t\t\t// mutating the cache directly\n\t\t\tconst writeOptions: WriteQueryOptions = {\n\t\t\t\t...queryOptions,\n\t\t\t\tdata: {\n\t\t\t\t\tespressoTickets: {\n\t\t\t\t\t\t...tickets,\n\t\t\t\t\t\tnodes: newNodes,\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t};\n\t\t\tcache.writeQuery(writeOptions);\n\t\t},\n\t\t[queryOptions]\n\t);\n\n\treturn updateTicketCache;\n};\n\nexport default useUpdateTicketCache;\n","import { useCallback } from 'react';\nimport { useMutationWithFeedback, gql, MutationType } from '@eventespresso/data';\nimport type { ExecutionResult } from 'graphql';\n\nimport type { EntityId } from '@eventespresso/data';\n\ninterface BulkDeleteEntitiesProps {\n\tentityType: 'DATETIME' | 'TICKET' | 'PRICE';\n\ttypeName: string;\n}\n\ninterface CallbackArgs {\n\tentityIds: Array;\n\tdeletePermanently?: boolean;\n\tupdateEntityList: VoidFunction;\n}\n\ntype Callback = (args: CallbackArgs) => Promise;\n\nconst BULK_DELETE_ENTITIES = gql`\n\tmutation BULK_DELETE_ENTITIES($input: BulkDeleteEspressoEntitiesInput!) {\n\t\tbulkDeleteEspressoEntities(input: $input) {\n\t\t\tdeleted\n\t\t\tfailed\n\t\t}\n\t}\n`;\n\nconst useBulkDeleteEntities = ({ entityType, typeName }: BulkDeleteEntitiesProps): Callback => {\n\tconst bulkDelete = useMutationWithFeedback({\n\t\ttypeName,\n\t\tmutationType: MutationType.Delete,\n\t\tmutation: BULK_DELETE_ENTITIES,\n\t});\n\n\treturn useCallback(\n\t\tasync ({ entityIds, deletePermanently, updateEntityList }) => {\n\t\t\treturn await bulkDelete({\n\t\t\t\tvariables: {\n\t\t\t\t\tinput: {\n\t\t\t\t\t\tclientMutationId: 'BULK_DELETE_ENTITIES',\n\t\t\t\t\t\tentityIds,\n\t\t\t\t\t\tentityType,\n\t\t\t\t\t\tdeletePermanently,\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\tupdate: updateEntityList,\n\t\t\t});\n\t\t},\n\t\t[bulkDelete, entityType]\n\t);\n};\n\nexport default useBulkDeleteEntities;\n","var _isPlaceholder =\n/*#__PURE__*/\nrequire(\"./_isPlaceholder\");\n/**\n * Optimized internal one-arity curry function.\n *\n * @private\n * @category Function\n * @param {Function} fn The function to curry.\n * @return {Function} The curried function.\n */\n\n\nfunction _curry1(fn) {\n return function f1(a) {\n if (arguments.length === 0 || _isPlaceholder(a)) {\n return f1;\n } else {\n return fn.apply(this, arguments);\n }\n };\n}\n\nmodule.exports = _curry1;","import { CREATE_DATETIME, UPDATE_DATETIME, DELETE_DATETIME } from './datetimes';\nimport { UPDATE_EVENT } from './events';\nimport { CREATE_TICKET, UPDATE_TICKET, DELETE_TICKET } from './tickets';\nimport { CREATE_PRICE, UPDATE_PRICE, DELETE_PRICE } from './prices';\n\nexport const mutations: any = {\n\t/* datetimes */\n\tCREATE_DATETIME,\n\tUPDATE_DATETIME,\n\tDELETE_DATETIME,\n\t/* events */\n\tUPDATE_EVENT,\n\t/* tickets */\n\tCREATE_TICKET,\n\tUPDATE_TICKET,\n\tDELETE_TICKET,\n\t/* prices */\n\tCREATE_PRICE,\n\tUPDATE_PRICE,\n\tDELETE_PRICE,\n};\n\nexport * from './datetimes';\nexport * from './events';\nexport * from './tickets';\nexport * from './prices';\n\nexport * from './utils';\nexport * from './types';\n\nexport { default as useUpdateCallback } from './useUpdateCallback';\n","var castPath = require('./_castPath'),\n isArguments = require('./isArguments'),\n isArray = require('./isArray'),\n isIndex = require('./_isIndex'),\n isLength = require('./isLength'),\n toKey = require('./_toKey');\n\n/**\n * Checks if `path` exists on `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Array|string} path The path to check.\n * @param {Function} hasFunc The function to check properties.\n * @returns {boolean} Returns `true` if `path` exists, else `false`.\n */\nfunction hasPath(object, path, hasFunc) {\n path = castPath(path, object);\n\n var index = -1,\n length = path.length,\n result = false;\n\n while (++index < length) {\n var key = toKey(path[index]);\n if (!(result = object != null && hasFunc(object, key))) {\n break;\n }\n object = object[key];\n }\n if (result || ++index != length) {\n return result;\n }\n length = object == null ? 0 : object.length;\n return !!length && isLength(length) && isIndex(key, length) &&\n (isArray(object) || isArguments(object));\n}\n\nmodule.exports = hasPath;\n","var isArray = require('./isArray'),\n isKey = require('./_isKey'),\n stringToPath = require('./_stringToPath'),\n toString = require('./toString');\n\n/**\n * Casts `value` to a path array if it's not one.\n *\n * @private\n * @param {*} value The value to inspect.\n * @param {Object} [object] The object to query keys on.\n * @returns {Array} Returns the cast property path array.\n */\nfunction castPath(value, object) {\n if (isArray(value)) {\n return value;\n }\n return isKey(value, object) ? [value] : stringToPath(toString(value));\n}\n\nmodule.exports = castPath;\n","/** Detect free variable `global` from Node.js. */\nvar freeGlobal = typeof global == 'object' && global && global.Object === Object && global;\n\nmodule.exports = freeGlobal;\n","var baseGetTag = require('./_baseGetTag'),\n isObject = require('./isObject');\n\n/** `Object#toString` result references. */\nvar asyncTag = '[object AsyncFunction]',\n funcTag = '[object Function]',\n genTag = '[object GeneratorFunction]',\n proxyTag = '[object Proxy]';\n\n/**\n * Checks if `value` is classified as a `Function` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a function, else `false`.\n * @example\n *\n * _.isFunction(_);\n * // => true\n *\n * _.isFunction(/abc/);\n * // => false\n */\nfunction isFunction(value) {\n if (!isObject(value)) {\n return false;\n }\n // The use of `Object#toString` avoids issues with the `typeof` operator\n // in Safari 9 which returns 'object' for typed arrays and other constructors.\n var tag = baseGetTag(value);\n return tag == funcTag || tag == genTag || tag == asyncTag || tag == proxyTag;\n}\n\nmodule.exports = isFunction;\n","/** Used for built-in method references. */\nvar funcProto = Function.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/**\n * Converts `func` to its source code.\n *\n * @private\n * @param {Function} func The function to convert.\n * @returns {string} Returns the source code.\n */\nfunction toSource(func) {\n if (func != null) {\n try {\n return funcToString.call(func);\n } catch (e) {}\n try {\n return (func + '');\n } catch (e) {}\n }\n return '';\n}\n\nmodule.exports = toSource;\n","/**\n * Performs a\n * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * comparison between two values to determine if they are equivalent.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n * @example\n *\n * var object = { 'a': 1 };\n * var other = { 'a': 1 };\n *\n * _.eq(object, object);\n * // => true\n *\n * _.eq(object, other);\n * // => false\n *\n * _.eq('a', 'a');\n * // => true\n *\n * _.eq('a', Object('a'));\n * // => false\n *\n * _.eq(NaN, NaN);\n * // => true\n */\nfunction eq(value, other) {\n return value === other || (value !== value && other !== other);\n}\n\nmodule.exports = eq;\n","var baseIsArguments = require('./_baseIsArguments'),\n isObjectLike = require('./isObjectLike');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Built-in value references. */\nvar propertyIsEnumerable = objectProto.propertyIsEnumerable;\n\n/**\n * Checks if `value` is likely an `arguments` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\n * else `false`.\n * @example\n *\n * _.isArguments(function() { return arguments; }());\n * // => true\n *\n * _.isArguments([1, 2, 3]);\n * // => false\n */\nvar isArguments = baseIsArguments(function() { return arguments; }()) ? baseIsArguments : function(value) {\n return isObjectLike(value) && hasOwnProperty.call(value, 'callee') &&\n !propertyIsEnumerable.call(value, 'callee');\n};\n\nmodule.exports = isArguments;\n","/** Used as references for various `Number` constants. */\nvar MAX_SAFE_INTEGER = 9007199254740991;\n\n/** Used to detect unsigned integer values. */\nvar reIsUint = /^(?:0|[1-9]\\d*)$/;\n\n/**\n * Checks if `value` is a valid array-like index.\n *\n * @private\n * @param {*} value The value to check.\n * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index.\n * @returns {boolean} Returns `true` if `value` is a valid index, else `false`.\n */\nfunction isIndex(value, length) {\n var type = typeof value;\n length = length == null ? MAX_SAFE_INTEGER : length;\n\n return !!length &&\n (type == 'number' ||\n (type != 'symbol' && reIsUint.test(value))) &&\n (value > -1 && value % 1 == 0 && value < length);\n}\n\nmodule.exports = isIndex;\n","var defineProperty = require('./_defineProperty');\n\n/**\n * The base implementation of `assignValue` and `assignMergeValue` without\n * value checks.\n *\n * @private\n * @param {Object} object The object to modify.\n * @param {string} key The key of the property to assign.\n * @param {*} value The value to assign.\n */\nfunction baseAssignValue(object, key, value) {\n if (key == '__proto__' && defineProperty) {\n defineProperty(object, key, {\n 'configurable': true,\n 'enumerable': true,\n 'value': value,\n 'writable': true\n });\n } else {\n object[key] = value;\n }\n}\n\nmodule.exports = baseAssignValue;\n","var baseFor = require('./_baseFor'),\n keys = require('./keys');\n\n/**\n * The base implementation of `_.forOwn` without support for iteratee shorthands.\n *\n * @private\n * @param {Object} object The object to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Object} Returns `object`.\n */\nfunction baseForOwn(object, iteratee) {\n return object && baseFor(object, iteratee, keys);\n}\n\nmodule.exports = baseForOwn;\n","var root = require('./_root'),\n stubFalse = require('./stubFalse');\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Built-in value references. */\nvar Buffer = moduleExports ? root.Buffer : undefined;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined;\n\n/**\n * Checks if `value` is a buffer.\n *\n * @static\n * @memberOf _\n * @since 4.3.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a buffer, else `false`.\n * @example\n *\n * _.isBuffer(new Buffer(2));\n * // => true\n *\n * _.isBuffer(new Uint8Array(2));\n * // => false\n */\nvar isBuffer = nativeIsBuffer || stubFalse;\n\nmodule.exports = isBuffer;\n","var baseIsTypedArray = require('./_baseIsTypedArray'),\n baseUnary = require('./_baseUnary'),\n nodeUtil = require('./_nodeUtil');\n\n/* Node.js helper references. */\nvar nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray;\n\n/**\n * Checks if `value` is classified as a typed array.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n * @example\n *\n * _.isTypedArray(new Uint8Array);\n * // => true\n *\n * _.isTypedArray([]);\n * // => false\n */\nvar isTypedArray = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray;\n\nmodule.exports = isTypedArray;\n","var baseMatches = require('./_baseMatches'),\n baseMatchesProperty = require('./_baseMatchesProperty'),\n identity = require('./identity'),\n isArray = require('./isArray'),\n property = require('./property');\n\n/**\n * The base implementation of `_.iteratee`.\n *\n * @private\n * @param {*} [value=_.identity] The value to convert to an iteratee.\n * @returns {Function} Returns the iteratee.\n */\nfunction baseIteratee(value) {\n // Don't store the `typeof` result in a variable to avoid a JIT bug in Safari 9.\n // See https://bugs.webkit.org/show_bug.cgi?id=156034 for more details.\n if (typeof value == 'function') {\n return value;\n }\n if (value == null) {\n return identity;\n }\n if (typeof value == 'object') {\n return isArray(value)\n ? baseMatchesProperty(value[0], value[1])\n : baseMatches(value);\n }\n return property(value);\n}\n\nmodule.exports = baseIteratee;\n","var ListCache = require('./_ListCache'),\n stackClear = require('./_stackClear'),\n stackDelete = require('./_stackDelete'),\n stackGet = require('./_stackGet'),\n stackHas = require('./_stackHas'),\n stackSet = require('./_stackSet');\n\n/**\n * Creates a stack cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction Stack(entries) {\n var data = this.__data__ = new ListCache(entries);\n this.size = data.size;\n}\n\n// Add methods to `Stack`.\nStack.prototype.clear = stackClear;\nStack.prototype['delete'] = stackDelete;\nStack.prototype.get = stackGet;\nStack.prototype.has = stackHas;\nStack.prototype.set = stackSet;\n\nmodule.exports = Stack;\n","var baseIsEqualDeep = require('./_baseIsEqualDeep'),\n isObjectLike = require('./isObjectLike');\n\n/**\n * The base implementation of `_.isEqual` which supports partial comparisons\n * and tracks traversed objects.\n *\n * @private\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @param {boolean} bitmask The bitmask flags.\n * 1 - Unordered comparison\n * 2 - Partial comparison\n * @param {Function} [customizer] The function to customize comparisons.\n * @param {Object} [stack] Tracks traversed `value` and `other` objects.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n */\nfunction baseIsEqual(value, other, bitmask, customizer, stack) {\n if (value === other) {\n return true;\n }\n if (value == null || other == null || (!isObjectLike(value) && !isObjectLike(other))) {\n return value !== value && other !== other;\n }\n return baseIsEqualDeep(value, other, bitmask, customizer, baseIsEqual, stack);\n}\n\nmodule.exports = baseIsEqual;\n","var SetCache = require('./_SetCache'),\n arraySome = require('./_arraySome'),\n cacheHas = require('./_cacheHas');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/**\n * A specialized version of `baseIsEqualDeep` for arrays with support for\n * partial deep comparisons.\n *\n * @private\n * @param {Array} array The array to compare.\n * @param {Array} other The other array to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `array` and `other` objects.\n * @returns {boolean} Returns `true` if the arrays are equivalent, else `false`.\n */\nfunction equalArrays(array, other, bitmask, customizer, equalFunc, stack) {\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG,\n arrLength = array.length,\n othLength = other.length;\n\n if (arrLength != othLength && !(isPartial && othLength > arrLength)) {\n return false;\n }\n // Check that cyclic values are equal.\n var arrStacked = stack.get(array);\n var othStacked = stack.get(other);\n if (arrStacked && othStacked) {\n return arrStacked == other && othStacked == array;\n }\n var index = -1,\n result = true,\n seen = (bitmask & COMPARE_UNORDERED_FLAG) ? new SetCache : undefined;\n\n stack.set(array, other);\n stack.set(other, array);\n\n // Ignore non-index properties.\n while (++index < arrLength) {\n var arrValue = array[index],\n othValue = other[index];\n\n if (customizer) {\n var compared = isPartial\n ? customizer(othValue, arrValue, index, other, array, stack)\n : customizer(arrValue, othValue, index, array, other, stack);\n }\n if (compared !== undefined) {\n if (compared) {\n continue;\n }\n result = false;\n break;\n }\n // Recursively compare arrays (susceptible to call stack limits).\n if (seen) {\n if (!arraySome(other, function(othValue, othIndex) {\n if (!cacheHas(seen, othIndex) &&\n (arrValue === othValue || equalFunc(arrValue, othValue, bitmask, customizer, stack))) {\n return seen.push(othIndex);\n }\n })) {\n result = false;\n break;\n }\n } else if (!(\n arrValue === othValue ||\n equalFunc(arrValue, othValue, bitmask, customizer, stack)\n )) {\n result = false;\n break;\n }\n }\n stack['delete'](array);\n stack['delete'](other);\n return result;\n}\n\nmodule.exports = equalArrays;\n","var isObject = require('./isObject');\n\n/**\n * Checks if `value` is suitable for strict equality comparisons, i.e. `===`.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` if suitable for strict\n * equality comparisons, else `false`.\n */\nfunction isStrictComparable(value) {\n return value === value && !isObject(value);\n}\n\nmodule.exports = isStrictComparable;\n","/**\n * A specialized version of `matchesProperty` for source values suitable\n * for strict equality comparisons, i.e. `===`.\n *\n * @private\n * @param {string} key The key of the property to get.\n * @param {*} srcValue The value to match.\n * @returns {Function} Returns the new spec function.\n */\nfunction matchesStrictComparable(key, srcValue) {\n return function(object) {\n if (object == null) {\n return false;\n }\n return object[key] === srcValue &&\n (srcValue !== undefined || (key in Object(object)));\n };\n}\n\nmodule.exports = matchesStrictComparable;\n","var castPath = require('./_castPath'),\n toKey = require('./_toKey');\n\n/**\n * The base implementation of `_.get` without support for default values.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Array|string} path The path of the property to get.\n * @returns {*} Returns the resolved value.\n */\nfunction baseGet(object, path) {\n path = castPath(path, object);\n\n var index = 0,\n length = path.length;\n\n while (object != null && index < length) {\n object = object[toKey(path[index++])];\n }\n return (index && index == length) ? object : undefined;\n}\n\nmodule.exports = baseGet;\n","var arrayReduce = require('./_arrayReduce'),\n deburr = require('./deburr'),\n words = require('./words');\n\n/** Used to compose unicode capture groups. */\nvar rsApos = \"['\\u2019]\";\n\n/** Used to match apostrophes. */\nvar reApos = RegExp(rsApos, 'g');\n\n/**\n * Creates a function like `_.camelCase`.\n *\n * @private\n * @param {Function} callback The function to combine each word.\n * @returns {Function} Returns the new compounder function.\n */\nfunction createCompounder(callback) {\n return function(string) {\n return arrayReduce(words(deburr(string).replace(reApos, '')), callback, '');\n };\n}\n\nmodule.exports = createCompounder;\n","/** Used to compose unicode character classes. */\nvar rsAstralRange = '\\\\ud800-\\\\udfff',\n rsComboMarksRange = '\\\\u0300-\\\\u036f',\n reComboHalfMarksRange = '\\\\ufe20-\\\\ufe2f',\n rsComboSymbolsRange = '\\\\u20d0-\\\\u20ff',\n rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange,\n rsVarRange = '\\\\ufe0e\\\\ufe0f';\n\n/** Used to compose unicode capture groups. */\nvar rsZWJ = '\\\\u200d';\n\n/** Used to detect strings with [zero-width joiners or code points from the astral planes](http://eev.ee/blog/2015/09/12/dark-corners-of-unicode/). */\nvar reHasUnicode = RegExp('[' + rsZWJ + rsAstralRange + rsComboRange + rsVarRange + ']');\n\n/**\n * Checks if `string` contains Unicode symbols.\n *\n * @private\n * @param {string} string The string to inspect.\n * @returns {boolean} Returns `true` if a symbol is found, else `false`.\n */\nfunction hasUnicode(string) {\n return reHasUnicode.test(string);\n}\n\nmodule.exports = hasUnicode;\n","import { gql } from '@eventespresso/data';\n\nexport const EVENT_ATTRIBUTES: any = gql`\n\tfragment eventAttributes on EspressoEvent {\n\t\tid\n\t\tdbId\n\t\tcacheId\n\t\tallowDonations\n\t\tallowOverflow\n\t\taltRegPage\n\t\tcreated\n\t\tdefaultRegStatus\n\t\tdescription\n\t\tdisplayDescription\n\t\tdisplayTicketSelector\n\t\tisActive\n\t\tisCancelled\n\t\tisExpired\n\t\tisInactive\n\t\tisPostponed\n\t\tisSoldOut\n\t\tisUpcoming\n\t\tmanager {\n\t\t\tid\n\t\t\tname\n\t\t}\n\t\tmaxRegistrations\n\t\tmemberOnly\n\t\tname\n\t\torder\n\t\tphoneNumber\n\t\tshortDescription\n\t\tstatus\n\t\ttimezoneString\n\t\tvenue\n\t}\n`;\n\nexport const GET_EVENT: any = gql`\n\tquery GET_EVENT($id: ID!) {\n\t\tespressoEvent(id: $id) {\n\t\t\t...eventAttributes\n\t\t}\n\t}\n\t${EVENT_ATTRIBUTES}\n`;\n","import { usePricesQuery } from '@eventespresso/data';\nimport { useMemoStringify } from '@eventespresso/hooks';\nimport { getCacheIds } from '@eventespresso/predicates';\n\nimport type { Price, PriceEdge } from '../../types';\nimport usePriceQueryOptions from './usePriceQueryOptions';\n\n/**\n * A custom react hook to retrieve all the prices from cache\n */\nconst usePrices = (): Price[] => {\n\tconst options = usePriceQueryOptions();\n\n\tconst { data } = usePricesQuery(options);\n\n\tconst nodes = data?.espressoPrices?.nodes || [];\n\n\tconst cacheIds = getCacheIds(nodes);\n\n\treturn useMemoStringify(nodes, cacheIds);\n};\n\nexport default usePrices;\n","import { useMemo } from 'react';\nimport type { CacheQueryOptions } from '@eventespresso/data';\n\nimport { GET_PRICE_TYPES } from '../priceTypes';\n\nconst usePriceTypeQueryOptions = (): CacheQueryOptions => {\n\tconst options: CacheQueryOptions = useMemo(\n\t\t() => ({\n\t\t\tquery: GET_PRICE_TYPES,\n\t\t}),\n\t\t[]\n\t);\n\n\treturn options;\n};\n\nexport default usePriceTypeQueryOptions;\n","import { useMemo } from 'react';\n\nimport type { VenuesList, VenuesQueryArgs, CacheQueryOptions } from '@eventespresso/data';\n\nimport { GET_VENUES } from '../venues';\nimport type { VenueEdge } from '../../';\n\nexport type VenuesQueryOptions = CacheQueryOptions, VenuesQueryArgs>;\n\nexport const useVenueQueryOptions = (queryArgs?: VenuesQueryArgs['where']): VenuesQueryOptions => {\n\treturn useMemo(() => {\n\t\treturn {\n\t\t\tquery: GET_VENUES,\n\t\t\tvariables: {\n\t\t\t\twhere: queryArgs,\n\t\t\t},\n\t\t};\n\t}, [queryArgs]);\n};\n","import { createContext } from 'react';\n\nimport type { DatetimesFilterStateManager } from '../../../filterState';\n\nimport { useDatesListFilterStateManager } from '../../../filterState';\n\nconst DatesFilterStateContext = createContext(null);\n\nconst { Provider, Consumer: DatesFilterStateConsumer } = DatesFilterStateContext;\n\nconst DatesFilterStateProvider: React.FC = ({ children }) => {\n\tconst filterState = useDatesListFilterStateManager();\n\n\treturn {children};\n};\n\nexport { DatesFilterStateContext, DatesFilterStateProvider, DatesFilterStateConsumer };\n","import { createContext, useEffect } from 'react';\n\nimport { useFilteredEntities } from '@eventespresso/services';\nimport { getGuids } from '@eventespresso/predicates';\nimport { useMemoStringify } from '@eventespresso/hooks';\nimport type { EntityId } from '@eventespresso/data';\n\nimport { useDatesListFilterState } from '../../../filterState';\nimport { domain, datesList } from '../../../constants';\nimport { useDatetimes } from '../../../apollo';\nimport { useVisibleDatetimeIds } from '../../../hooks';\n\nconst FilteredDatesContext = createContext>(null);\n\nconst { Provider, Consumer: FilteredDatesConsumer } = FilteredDatesContext;\n\nconst FilteredDatesProvider: React.FC = ({ children }) => {\n\tconst datetimes = useDatetimes();\n\tconst filterState = useDatesListFilterState();\n\n\tconst filteredEntities = useFilteredEntities(domain, datesList, datetimes, filterState);\n\n\tconst filteredEntityIds = useMemoStringify(getGuids(filteredEntities));\n\n\t// Update Edtr state for isChained filter\n\tconst [, setVisibleDatetimeIds] = useVisibleDatetimeIds();\n\tuseEffect(() => {\n\t\tsetVisibleDatetimeIds(filteredEntityIds);\n\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\t}, [filteredEntityIds]);\n\n\treturn {children};\n};\n\nexport { FilteredDatesContext, FilteredDatesProvider, FilteredDatesConsumer };\n","import { createContext } from 'react';\n\nimport type { TicketsFilterStateManager } from '../../../filterState';\n\nimport { useTicketsListFilterStateManager } from '../../../filterState';\n\nconst TicketsFilterStateContext = createContext(null);\n\nconst { Provider, Consumer: TicketsFilterStateConsumer } = TicketsFilterStateContext;\n\nconst TicketsFilterStateProvider: React.FC = ({ children }) => {\n\tconst filterState = useTicketsListFilterStateManager();\n\n\treturn {children};\n};\n\nexport { TicketsFilterStateContext, TicketsFilterStateProvider, TicketsFilterStateConsumer };\n","import { createContext, useEffect } from 'react';\n\nimport { getGuids } from '@eventespresso/predicates';\nimport { useFilteredEntities } from '@eventespresso/services';\nimport type { EntityId } from '@eventespresso/data';\nimport { useMemoStringify } from '@eventespresso/hooks';\n\nimport { useTicketsListFilterState } from '../../../filterState';\nimport { domain, ticketsList } from '../../../constants';\nimport { useTickets } from '../../../apollo';\nimport { useVisibleTicketIds } from '../../../hooks';\n\nconst FilteredTicketsContext = createContext>(null);\n\nconst { Provider, Consumer: FilteredTicketsConsumer } = FilteredTicketsContext;\n\nconst FilteredTicketsProvider: React.FC = ({ children }) => {\n\tconst tickets = useTickets();\n\n\tconst filterState = useTicketsListFilterState();\n\n\tconst filteredEntities = useFilteredEntities(domain, ticketsList, tickets, filterState);\n\n\tconst filteredEntityIds = useMemoStringify(getGuids(filteredEntities));\n\n\t// Update Edtr state for bulk edit.\n\tconst [, setVisibleTicketIds] = useVisibleTicketIds();\n\tuseEffect(() => {\n\t\tsetVisibleTicketIds(getGuids(filteredEntities));\n\t}, [filteredEntities, filteredEntityIds, setVisibleTicketIds]);\n\n\treturn {children};\n};\n\nexport { FilteredTicketsContext, FilteredTicketsProvider, FilteredTicketsConsumer };\n","(function() { module.exports = window[\"wp\"][\"url\"]; }());","var capitalize = require('./capitalize'),\n createCompounder = require('./_createCompounder');\n\n/**\n * Converts `string` to [camel case](https://en.wikipedia.org/wiki/CamelCase).\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to convert.\n * @returns {string} Returns the camel cased string.\n * @example\n *\n * _.camelCase('Foo Bar');\n * // => 'fooBar'\n *\n * _.camelCase('--foo-bar--');\n * // => 'fooBar'\n *\n * _.camelCase('__FOO_BAR__');\n * // => 'fooBar'\n */\nvar camelCase = createCompounder(function(result, word, index) {\n word = word.toLowerCase();\n return result + (index ? capitalize(word) : word);\n});\n\nmodule.exports = camelCase;\n","var baseAssignValue = require('./_baseAssignValue'),\n baseForOwn = require('./_baseForOwn'),\n baseIteratee = require('./_baseIteratee');\n\n/**\n * The opposite of `_.mapValues`; this method creates an object with the\n * same values as `object` and keys generated by running each own enumerable\n * string keyed property of `object` thru `iteratee`. The iteratee is invoked\n * with three arguments: (value, key, object).\n *\n * @static\n * @memberOf _\n * @since 3.8.0\n * @category Object\n * @param {Object} object The object to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @returns {Object} Returns the new mapped object.\n * @see _.mapValues\n * @example\n *\n * _.mapKeys({ 'a': 1, 'b': 2 }, function(value, key) {\n * return key + value;\n * });\n * // => { 'a1': 1, 'b2': 2 }\n */\nfunction mapKeys(object, iteratee) {\n var result = {};\n iteratee = baseIteratee(iteratee, 3);\n\n baseForOwn(object, function(value, key, object) {\n baseAssignValue(result, iteratee(value, key, object), value);\n });\n return result;\n}\n\nmodule.exports = mapKeys;\n","\n/**\n * Topological sorting function\n *\n * @param {Array} edges\n * @returns {Array}\n */\n\nmodule.exports = function(edges) {\n return toposort(uniqueNodes(edges), edges)\n}\n\nmodule.exports.array = toposort\n\nfunction toposort(nodes, edges) {\n var cursor = nodes.length\n , sorted = new Array(cursor)\n , visited = {}\n , i = cursor\n // Better data structures make algorithm much faster.\n , outgoingEdges = makeOutgoingEdges(edges)\n , nodesHash = makeNodesHash(nodes)\n\n // check for unknown nodes\n edges.forEach(function(edge) {\n if (!nodesHash.has(edge[0]) || !nodesHash.has(edge[1])) {\n throw new Error('Unknown node. There is an unknown node in the supplied edges.')\n }\n })\n\n while (i--) {\n if (!visited[i]) visit(nodes[i], i, new Set())\n }\n\n return sorted\n\n function visit(node, i, predecessors) {\n if(predecessors.has(node)) {\n var nodeRep\n try {\n nodeRep = \", node was:\" + JSON.stringify(node)\n } catch(e) {\n nodeRep = \"\"\n }\n throw new Error('Cyclic dependency' + nodeRep)\n }\n\n if (!nodesHash.has(node)) {\n throw new Error('Found unknown node. Make sure to provided all involved nodes. Unknown node: '+JSON.stringify(node))\n }\n\n if (visited[i]) return;\n visited[i] = true\n\n var outgoing = outgoingEdges.get(node) || new Set()\n outgoing = Array.from(outgoing)\n\n if (i = outgoing.length) {\n predecessors.add(node)\n do {\n var child = outgoing[--i]\n visit(child, nodesHash.get(child), predecessors)\n } while (i)\n predecessors.delete(node)\n }\n\n sorted[--cursor] = node\n }\n}\n\nfunction uniqueNodes(arr){\n var res = new Set()\n for (var i = 0, len = arr.length; i < len; i++) {\n var edge = arr[i]\n res.add(edge[0])\n res.add(edge[1])\n }\n return Array.from(res)\n}\n\nfunction makeOutgoingEdges(arr){\n var edges = new Map()\n for (var i = 0, len = arr.length; i < len; i++) {\n var edge = arr[i]\n if (!edges.has(edge[0])) edges.set(edge[0], new Set())\n if (!edges.has(edge[1])) edges.set(edge[1], new Set())\n edges.get(edge[0]).add(edge[1])\n }\n return edges\n}\n\nfunction makeNodesHash(arr){\n var res = new Map()\n for (var i = 0, len = arr.length; i < len; i++) {\n res.set(arr[i], i)\n }\n return res\n}\n","import { useMemo } from 'react';\n\nimport useUpdateEntityList from './useUpdateEntityList';\nimport { useDatetimeQueryOptions, DatetimesList } from '../../apollo';\nimport { CacheUpdaterFn, WriteQueryOptions } from '@eventespresso/data';\n\nconst useUpdateDatetimeList = (\n\twriteQueryOptions: WriteQueryOptions = undefined\n): CacheUpdaterFn => {\n\tconst queryOptions = useDatetimeQueryOptions();\n\tconst options = useMemo(\n\t\t() => ({\n\t\t\t...queryOptions,\n\t\t\t...writeQueryOptions,\n\t\t}),\n\t\t[queryOptions, writeQueryOptions]\n\t);\n\treturn useUpdateEntityList(options);\n};\n\nexport default useUpdateDatetimeList;\n","import { useMemo } from 'react';\n\nimport useUpdateEntityList from './useUpdateEntityList';\nimport { TicketsList, useTicketQueryOptions } from '../../apollo';\nimport { CacheUpdaterFn, WriteQueryOptions } from '@eventespresso/data';\n\nconst useUpdateTicketList = (\n\twriteQueryOptions: WriteQueryOptions = undefined\n): CacheUpdaterFn => {\n\tconst queryOptions = useTicketQueryOptions();\n\tconst options = useMemo(\n\t\t() => ({\n\t\t\t...queryOptions,\n\t\t\t...writeQueryOptions,\n\t\t}),\n\t\t[queryOptions, writeQueryOptions]\n\t);\n\treturn useUpdateEntityList(options);\n};\n\nexport default useUpdateTicketList;\n","export * from './queries';\n\nexport { default as useEvent } from './useEvent';\n\nexport { default as useEventQueryOptions } from './useEventQueryOptions';\n\nexport { default as useEventId } from './useEventId';\n","import { isDefault } from '@eventespresso/predicates';\n\nimport useTickets from './useTickets';\nimport type { Ticket } from '../../types';\n\nconst useDefaultTickets = (): Array => {\n\treturn useTickets(isDefault);\n};\n\nexport default useDefaultTickets;\n","import { useMemoStringify } from '@eventespresso/hooks';\nimport { getGuids } from '@eventespresso/predicates';\nimport type { EntityId } from '@eventespresso/data';\n\nimport useDefaultTickets from './useDefaultTickets';\n\nconst useDefaultTicketIds = (): EntityId[] => {\n\tconst tickets = useDefaultTickets();\n\n\treturn useMemoStringify(getGuids(tickets));\n};\n\nexport default useDefaultTicketIds;\n","import { useMemoStringify } from '@eventespresso/hooks';\nimport { getGuids } from '@eventespresso/predicates';\nimport type { EntityId } from '@eventespresso/data';\nimport useTickets from './useTickets';\n\nconst useTicketIds = (): EntityId[] => {\n\tconst tickets = useTickets();\n\n\treturn useMemoStringify(getGuids(tickets));\n};\n\nexport default useTicketIds;\n","import { useMemo } from 'react';\n\nimport { useCacheQuery, CacheQueryOptions } from '@eventespresso/data';\nimport { useMemoStringify } from '@eventespresso/hooks';\n\nimport { GET_TICKET } from './queries';\nimport type { Ticket, TicketItem } from '../../types';\nimport type { EntityItemProps } from '../types';\n\nconst useTicketItem = ({ id }: EntityItemProps): Ticket => {\n\tconst options = useMemo(\n\t\t() => ({\n\t\t\tquery: GET_TICKET,\n\t\t\tvariables: {\n\t\t\t\tid,\n\t\t\t},\n\t\t\treturnPartialData: true, // avoid console warnings if data not present\n\t\t}),\n\t\t[id]\n\t);\n\tconst { data } = useCacheQuery(options);\n\n\treturn useMemoStringify(data?.espressoTicket);\n};\n\nexport default useTicketItem;\n","import { useCallback } from 'react';\n\nimport { entitiesWithGuIdInArray } from '@eventespresso/predicates';\nimport { useRelations } from '@eventespresso/services';\nimport { EntityId } from '@eventespresso/data';\n\nimport { usePrices } from '../prices';\nimport type { Price } from '../../types';\n\ntype GetTicketPrices = (ticketId: EntityId) => Array;\n/**\n * A custom react hook for retrieving the related prices\n * for the given `ticket` identified by `ticket.id`\n *\n * @param {string|string[]} ticketId ticket.id\n */\nconst useTicketPrices = (): GetTicketPrices => {\n\tconst prices = usePrices();\n\tconst { getRelations } = useRelations();\n\n\treturn useCallback(\n\t\t(ticketId) => {\n\t\t\tconst relatedPricesIds = getRelations({\n\t\t\t\tentity: 'tickets',\n\t\t\t\tentityId: ticketId,\n\t\t\t\trelation: 'prices',\n\t\t\t});\n\n\t\t\treturn entitiesWithGuIdInArray(prices, relatedPricesIds);\n\t\t},\n\t\t[getRelations, prices]\n\t);\n};\n\nexport default useTicketPrices;\n","import { useCallback } from 'react';\nimport * as R from 'ramda';\n\nimport { EntityId } from '@eventespresso/data';\nimport { useRelations } from '@eventespresso/services';\nimport { minDateCapacity, ticketQuantityFromCapacity } from '@eventespresso/predicates';\n\nimport { useDatetimes } from '../datetimes';\n\ntype GetCappedQuantity = (args: {\n\tcapacity?: number;\n\tquantity: number;\n\trelatedDateIds?: Array;\n\tticketId?: EntityId;\n}) => number;\n\n/**\n * Returns a callback to get the quantity cap for a ticket\n * based on the related dates capacity\n */\nexport const useCappedQuantity = () => {\n\tconst allDates = useDatetimes();\n\n\tconst { getRelations } = useRelations();\n\n\treturn useCallback(\n\t\t// at least one of `relatedDateIds` and `ticketId` must be passed\n\t\t({ capacity, quantity, ticketId, relatedDateIds = [] }) => {\n\t\t\tconst dateIdsToUse = relatedDateIds?.length\n\t\t\t\t? relatedDateIds\n\t\t\t\t: getRelations({\n\t\t\t\t\t\tentity: 'tickets',\n\t\t\t\t\t\tentityId: ticketId,\n\t\t\t\t\t\trelation: 'datetimes',\n\t\t\t\t });\n\t\t\tconst minimumCapacity = !R.isNil(capacity) ? capacity : minDateCapacity(allDates)(dateIdsToUse);\n\n\t\t\treturn ticketQuantityFromCapacity(minimumCapacity)(quantity);\n\t\t},\n\t\t[allDates, getRelations]\n\t);\n};\n","import type { PriceType, PriceTypesList } from '../../types';\nimport { useCacheQuery } from '@eventespresso/data';\nimport { useMemoStringify } from '@eventespresso/hooks';\nimport usePriceTypeQueryOptions from './usePriceTypeQueryOptions';\nimport { getCacheIds } from '@eventespresso/predicates';\n\n/**\n * A custom react hook for retrieving all the priceTypes from cache\n */\nconst usePriceTypes = (): PriceType[] => {\n\tconst options = usePriceTypeQueryOptions();\n\tconst { data } = useCacheQuery(options);\n\n\tconst nodes = data?.espressoPriceTypes?.nodes || [];\n\n\tconst cacheIds = getCacheIds(nodes);\n\n\treturn useMemoStringify(nodes, cacheIds);\n};\n\nexport default usePriceTypes;\n","import { getDefaultPriceModifierType } from '@eventespresso/predicates';\nimport { useMemoStringify } from '@eventespresso/hooks';\nimport usePriceTypes from './usePriceTypes';\nimport type { PriceType } from '../../types';\n\n/**\n * A custom react hook for retrieving the default price type object.\n */\nconst useDefaultPriceType = (): PriceType | null => {\n\tconst allPriceTypes = usePriceTypes();\n\tconst defaultPriceType: PriceType | null = getDefaultPriceModifierType(allPriceTypes);\n\treturn useMemoStringify(defaultPriceType);\n};\n\nexport default useDefaultPriceType;\n","import isEmpty from 'ramda/src/isEmpty';\n\nimport { useMemoStringify } from '@eventespresso/hooks';\nimport { entitiesWithGuIdInArray } from '@eventespresso/predicates';\nimport { useRelations } from '@eventespresso/services';\n\nimport useDefaultPriceType from './useDefaultPriceType';\nimport usePriceTypes from './usePriceTypes';\n\nimport type { EntityId } from '@eventespresso/data';\nimport type { PriceType } from '../../types';\n\n/**\n * A custom react hook for retrieving the related priceType from cache for the given Price entity\n *\n * @param {string} priceId price.id\n */\nconst usePriceTypeForPrice = (priceId: EntityId): PriceType | null => {\n\tconst { getRelations } = useRelations();\n\t// get related priceTypes for this price\n\tconst relatedPriceTypeIds = getRelations({\n\t\tentity: 'prices',\n\t\tentityId: priceId,\n\t\trelation: 'priceTypes',\n\t});\n\n\t// get the default price type object\n\tconst defaultPriceType: PriceType | null = useDefaultPriceType();\n\tconst allPriceTypes = usePriceTypes();\n\n\tconst relatedPriceTypes = entitiesWithGuIdInArray(allPriceTypes, relatedPriceTypeIds);\n\n\tconst priceType = !isEmpty(relatedPriceTypes) ? relatedPriceTypes[0] : defaultPriceType;\n\n\treturn useMemoStringify(priceType);\n};\n\nexport default usePriceTypeForPrice;\n","import { useCallback } from 'react';\n\nimport { useRelations } from '@eventespresso/services';\nimport type { EntityId } from '@eventespresso/data';\n\nimport { useBulkDeleteTickets } from '../tickets';\n\ntype Callback = (datetimeId: EntityId, deletePermanently?: boolean) => Promise;\n\n/**\n * Returns a callback to delete or trash the related tickets for a given date\n * if the ticket only related to the date\n */\nconst useDeleteRelatedTickets = (): Callback => {\n\tconst { getRelations } = useRelations();\n\n\tconst deleteTickets = useBulkDeleteTickets();\n\n\treturn useCallback(\n\t\tasync (datetimeId, deletePermanently) => {\n\t\t\tconst relatedTicketIds = getRelations({\n\t\t\t\tentity: 'datetimes',\n\t\t\t\tentityId: datetimeId,\n\t\t\t\trelation: 'tickets',\n\t\t\t});\n\n\t\t\tconst ticketIdsRelatedOnlyToTheDate = relatedTicketIds.filter((ticketId) => {\n\t\t\t\tconst relatedDatetimeIds = getRelations({\n\t\t\t\t\tentity: 'tickets',\n\t\t\t\t\tentityId: ticketId,\n\t\t\t\t\trelation: 'datetimes',\n\t\t\t\t});\n\n\t\t\t\treturn relatedDatetimeIds.length === 1;\n\t\t\t});\n\n\t\t\t// if we have something to work with\n\t\t\tif (ticketIdsRelatedOnlyToTheDate.length) {\n\t\t\t\tawait deleteTickets({\n\t\t\t\t\tentityIds: ticketIdsRelatedOnlyToTheDate,\n\t\t\t\t\tdeletePermanently,\n\t\t\t\t\tdeleteRemotely: false,\n\t\t\t\t\trelatedDatetimeIds: [datetimeId],\n\t\t\t\t});\n\t\t\t}\n\t\t},\n\t\t[deleteTickets, getRelations]\n\t);\n};\n\nexport default useDeleteRelatedTickets;\n","import { getHooks } from '@eventespresso/ioc';\nimport type { MutationType, ApolloCache, Entity } from '@eventespresso/data';\nimport type { OptionsType } from '@eventespresso/adapters';\nimport type { BulkEdit } from '@eventespresso/services';\nimport type { ButtonProps } from '@eventespresso/ui-components';\nimport type { SimpleTextEditorModalProps } from '@eventespresso/ee-components';\n\nimport { Datetime, Ticket } from '../apollo';\nimport { DateFormShape, DateFormConfig, TicketFormShape, TicketFormConfig } from '../forms';\n\ntype MutationActionArgs = [\n\tmutationType: MutationType,\n\tinput: Record,\n\tentity: E,\n\tcache?: ApolloCache\n];\n\nexport type Actions = {\n\t'eventEditor.ticket.mutation': MutationActionArgs;\n\t'eventEditor.datetimes.bulkEdit.apply': [action: string, bulkEdit: BulkEdit];\n};\nexport type Filters = {\n\t'eventEditor.ticketForm.initalValues': [initialValues: TicketFormShape, ticket: Ticket];\n\t'eventEditor.ticketForm.sections': [sections: TicketFormConfig['sections'], ticket: Ticket];\n\t'eventEditor.dateForm.initalValues': [initialValues: DateFormShape, datetime: Datetime];\n\t'eventEditor.dateForm.sections': [sections: DateFormConfig['sections'], datetime: Datetime];\n\t'eventEditor.ticket.mutationInput': [input: Record, rawInput?: Record];\n\t'eventEditor.datetimes.bulkEdit.actions': [actions: OptionsType];\n\t'eventEditor.addSingleDate.button': [button: JSX.Element, isOnlyButton: boolean];\n\t'eventEditor.addSingleDate.buttonProps': [props: Partial, isOnlyButton: boolean];\n\t'eventEditor.datetimes.inlineDescriptionProps': [props: Partial, entity: Datetime];\n\t'eventEditor.tickets.inlineDescriptionProps': [props: Partial, entity: Ticket];\n};\n\nexport const hooks = getHooks();\n","import { useCallback, useMemo } from 'react';\nimport { identity, unnest } from 'ramda';\n\nimport { useMutationWithFeedback, MutationType } from '@eventespresso/data';\nimport type { TicketPred } from '@eventespresso/predicates';\n\nimport type { TicketEdge, Ticket } from '../../types';\nimport { useTicketQueryOptions, useTickets } from '../../queries';\nimport { useUpdateTicketList } from '../../../hooks';\nimport { BulkUpdateTicketInput, BULK_UPDATE_TICKETS } from './';\nimport { SINGULAR_ENTITY_NAME } from '../../../constants';\nimport { cacheNodesFromBulkInput, updateTicketFlags } from '../utils';\nimport useOnUpdateTicket from './useOnUpdateTicket';\nimport useAffectedDatesQueries from './useAffectedDatesQueries';\n\ninterface BulkEditTickets {\n\tupdateEntities: (input: BulkUpdateTicketInput) => ReturnType>;\n}\n\nconst useBulkEditTickets = (): BulkEditTickets => {\n\t// ensure that bulk edit preserves default tickets\n\tconst allTickets = useTickets(identity as TicketPred);\n\tconst queryOptions = useTicketQueryOptions();\n\tconst updateTicketList = useUpdateTicketList();\n\tconst onUpdateTicket = useOnUpdateTicket();\n\tconst affectedDatesQueries = useAffectedDatesQueries();\n\n\tconst updateTickets = useMutationWithFeedback({\n\t\ttypeName: SINGULAR_ENTITY_NAME.TICKET,\n\t\tmutationType: MutationType.Update,\n\t\tmutation: BULK_UPDATE_TICKETS,\n\t});\n\n\tconst updateEntityList = useCallback(\n\t\t(input: BulkUpdateTicketInput) => () => {\n\t\t\tconst nodes = cacheNodesFromBulkInput(input, allTickets).map(updateTicketFlags);\n\n\t\t\tconst espressoTickets: TicketEdge = {\n\t\t\t\tnodes,\n\t\t\t\t__typename: 'EspressoRootQueryTicketsConnection',\n\t\t\t};\n\t\t\tupdateTicketList({\n\t\t\t\t...queryOptions,\n\t\t\t\tdata: {\n\t\t\t\t\tespressoTickets,\n\t\t\t\t},\n\t\t\t});\n\t\t\t// update entity relations\n\t\t\tinput.uniqueInputs.forEach(({ datetimes, prices, ...updateInput }) => {\n\t\t\t\tonUpdateTicket({ ticket: updateInput as Ticket, datetimeIds: datetimes, priceIds: prices });\n\t\t\t});\n\t\t},\n\t\t[allTickets, onUpdateTicket, queryOptions, updateTicketList]\n\t);\n\n\tconst updateEntities = useCallback(\n\t\t(input) => {\n\t\t\tconst variables = {\n\t\t\t\tinput: {\n\t\t\t\t\tclientMutationId: 'BULK_UPDATE_TICKETS',\n\t\t\t\t\t...input,\n\t\t\t\t},\n\t\t\t};\n\t\t\t// fetch the affected dates.\n\t\t\tconst refetchQueries = unnest(input.uniqueInputs.map((input) => affectedDatesQueries({ input }))).filter(\n\t\t\t\tBoolean\n\t\t\t);\n\n\t\t\treturn updateTickets({ variables, update: updateEntityList(input), refetchQueries });\n\t\t},\n\t\t[updateTickets, updateEntityList, affectedDatesQueries]\n\t);\n\n\treturn useMemo(() => ({ updateEntities }), [updateEntities]);\n};\n\nexport default useBulkEditTickets;\n","const useEventGuid = (): string => {\n\treturn window?.eventEspressoData?.eventEditor?.event?.id || '';\n};\n\nexport default useEventGuid;\n","import { useMemo } from 'react';\n\nimport type { CacheQueryOptions } from '@eventespresso/data';\nimport useEventGuid from '../events/useEventGuid';\nimport { GET_EVENT } from './queries';\n\nconst useEventQueryOptions = (): CacheQueryOptions => {\n\tconst id = useEventGuid();\n\n\treturn useMemo(\n\t\t() => ({\n\t\t\tquery: GET_EVENT,\n\t\t\tvariables: {\n\t\t\t\tid,\n\t\t\t},\n\t\t}),\n\t\t[id]\n\t);\n};\n\nexport default useEventQueryOptions;\n","import { gql } from '@eventespresso/data';\n\nexport const PRICE_TYPE_ATTRIBUTES: any = gql`\n\tfragment priceTypeAttributes on EspressoPriceType {\n\t\tid\n\t\tdbId\n\t\tbaseType\n\t\tcacheId\n\t\tisBasePrice\n\t\tisDiscount\n\t\tisPercent\n\t\tisTax\n\t\tisTrashed\n\t\tname\n\t\torder\n\t}\n`;\n\nexport const GET_PRICE_TYPE: any = gql`\n\tquery GET_PRICE_TYPE($id: ID!) {\n\t\tpriceType(id: $id) {\n\t\t\t...priceTypeAttributes\n\t\t}\n\t}\n\t${PRICE_TYPE_ATTRIBUTES}\n`;\n\nexport const GET_PRICE_TYPES: any = gql`\n\tquery GET_PRICE_TYPES {\n\t\tespressoPriceTypes {\n\t\t\tnodes {\n\t\t\t\t...priceTypeAttributes\n\t\t\t}\n\t\t}\n\t}\n\t${PRICE_TYPE_ATTRIBUTES}\n`;\n","import { useCallback } from 'react';\nimport { findIndex, update } from 'ramda';\n\nimport type { CacheUpdaterFn, CacheUpdaterFnArgs } from '../types';\nimport type { Datetime, DatetimesList } from '../../types';\nimport { WriteQueryOptions } from '@eventespresso/data';\nimport { entityHasGuid } from '@eventespresso/predicates';\nimport { useDatetimeQueryOptions } from '../../queries';\n\nconst useUpdateDatetimeCache = (): CacheUpdaterFn => {\n\tconst queryOptions = useDatetimeQueryOptions();\n\n\tconst updateDatetimeCache = useCallback(\n\t\t({ cache, datetimes, datetime, action }: CacheUpdaterFnArgs): void => {\n\t\t\tconst { nodes = [] } = datetimes;\n\t\t\tlet newNodes: Array = [],\n\t\t\t\tdatetimeIndex: number;\n\t\t\tswitch (action) {\n\t\t\t\tcase 'add':\n\t\t\t\t\tnewNodes = [...nodes, datetime];\n\t\t\t\t\tbreak;\n\t\t\t\tcase 'update':\n\t\t\t\t\t// find the index of the datetime to update\n\t\t\t\t\tdatetimeIndex = findIndex(entityHasGuid(datetime.id), nodes);\n\t\t\t\t\t// if datetime exists\n\t\t\t\t\tif (datetimeIndex >= 0) {\n\t\t\t\t\t\tnewNodes = update(datetimeIndex, datetime, nodes);\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase 'remove':\n\t\t\t\t\tnewNodes = nodes.filter(({ id }) => id !== datetime.id);\n\t\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t\tnewNodes = nodes;\n\t\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\t// write the data to cache without\n\t\t\t// mutating the cache directly\n\t\t\tconst writeOptions: WriteQueryOptions = {\n\t\t\t\t...queryOptions,\n\t\t\t\tdata: {\n\t\t\t\t\tespressoDatetimes: {\n\t\t\t\t\t\t...datetimes,\n\t\t\t\t\t\tnodes: newNodes,\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t};\n\t\t\tcache.writeQuery(writeOptions);\n\t\t},\n\t\t[queryOptions]\n\t);\n\n\treturn updateDatetimeCache;\n};\n\nexport default useUpdateDatetimeCache;\n","import type { CacheUpdaterFnArgs } from '../types';\nimport { GET_TICKETS } from '../../queries';\nimport type { TicketsList } from '../../types';\nimport { sortBy, identity } from 'ramda';\nimport type { CacheQueryOptions, WriteQueryOptions } from '@eventespresso/data';\n\nconst updateTicketCache = ({ cache, datetimeIn, datetimeId, action }: CacheUpdaterFnArgs): void => {\n\tconst queryOptions: CacheQueryOptions = {\n\t\tquery: GET_TICKETS,\n\t\tvariables: {\n\t\t\twhere: {\n\t\t\t\tdatetimeIn: sortBy(identity, datetimeIn),\n\t\t\t},\n\t\t},\n\t};\n\tlet data: TicketsList;\n\t// Read the existing data from cache.\n\ttry {\n\t\tdata = cache.readQuery(queryOptions);\n\t} catch (error) {\n\t\tdata = null;\n\t}\n\n\t// if there are no tickets\n\tif (!data?.espressoTickets) {\n\t\treturn;\n\t}\n\n\tlet newDatetimeIn: typeof datetimeIn;\n\n\tswitch (action) {\n\t\tcase 'add':\n\t\t\tnewDatetimeIn = [...datetimeIn, datetimeId];\n\t\t\tbreak;\n\t\tcase 'remove':\n\t\t\tnewDatetimeIn = datetimeIn.filter((id) => id !== datetimeId);\n\t\t\tbreak;\n\t\tdefault:\n\t\t\tnewDatetimeIn = datetimeIn;\n\t\t\tbreak;\n\t}\n\n\tconst writeOptions: WriteQueryOptions = {\n\t\tquery: GET_TICKETS,\n\t\tdata,\n\t\tvariables: {\n\t\t\twhere: {\n\t\t\t\tdatetimeIn: sortBy(identity, newDatetimeIn),\n\t\t\t},\n\t\t},\n\t};\n\n\t// write the data to cache without\n\t// mutating the cache directly\n\tcache.writeQuery(writeOptions);\n};\n\nexport default updateTicketCache;\n","import { useCallback } from 'react';\n\nimport { useRelations } from '@eventespresso/services';\nimport { hasTempId } from '@eventespresso/predicates';\nimport type { DatetimeMutationCallbackFn, DatetimeMutationCallbackFnArgs } from '../types';\n\nconst useOnUpdateDatetime = (): DatetimeMutationCallbackFn => {\n\tconst { addRelation, removeRelation, updateRelations } = useRelations();\n\n\tconst onUpdateDatetime = useCallback(\n\t\t({ datetime, tickets }: DatetimeMutationCallbackFnArgs): void => {\n\t\t\tif (hasTempId(datetime)) {\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tconst datetimeId = datetime?.id;\n\t\t\t// if related tickets are passed\n\t\t\t// may be empty array to remove relations\n\t\t\tif (tickets) {\n\t\t\t\t// make sure to remove datetime from\n\t\t\t\t// all existing relations\n\t\t\t\tremoveRelation({\n\t\t\t\t\tentity: 'datetimes',\n\t\t\t\t\tentityId: datetimeId,\n\t\t\t\t\trelation: 'tickets',\n\t\t\t\t});\n\n\t\t\t\t// if we have any tickets\n\t\t\t\tif (tickets.length) {\n\t\t\t\t\tupdateRelations({\n\t\t\t\t\t\tentity: 'datetimes',\n\t\t\t\t\t\tentityId: datetimeId,\n\t\t\t\t\t\trelation: 'tickets',\n\t\t\t\t\t\trelationIds: tickets,\n\t\t\t\t\t});\n\n\t\t\t\t\ttickets.forEach((entityId) => {\n\t\t\t\t\t\taddRelation({\n\t\t\t\t\t\t\tentity: 'tickets',\n\t\t\t\t\t\t\tentityId,\n\t\t\t\t\t\t\trelation: 'datetimes',\n\t\t\t\t\t\t\trelationId: datetimeId,\n\t\t\t\t\t\t});\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t}\n\t\t},\n\t\t[addRelation, removeRelation, updateRelations]\n\t);\n\n\treturn onUpdateDatetime;\n};\n\nexport default useOnUpdateDatetime;\n","import { useCallback } from 'react';\n\nimport updateTicketCache from './updateTicketCache';\nimport useUpdateDatetimeCache from './useUpdateDatetimeCache';\nimport type { DatetimeMutationCallbackFn, DatetimeMutationCallbackFnArgs } from '../types';\nimport { useRelations } from '@eventespresso/services';\nimport { getGuids, hasTempId } from '@eventespresso/predicates';\n\nconst useOnDeleteDatetime = (): DatetimeMutationCallbackFn => {\n\tconst { dropRelations, removeRelation } = useRelations();\n\n\tconst updateDatetimeCache = useUpdateDatetimeCache();\n\n\tconst onDeleteDatetime = useCallback(\n\t\t({ cache, datetimes, datetime, deletePermanently }: DatetimeMutationCallbackFnArgs): void => {\n\t\t\tconst action = deletePermanently ? 'remove' : 'update';\n\t\t\tif (!hasTempId(datetime) && deletePermanently) {\n\t\t\t\tconst { nodes = [] } = datetimes;\n\t\t\t\tconst datetimeIn = getGuids(nodes);\n\t\t\t\tconst { id: datetimeId } = datetime;\n\n\t\t\t\t// Update tickets cache for the changed datetimes,\n\t\t\t\t// to avoid refetching of tickets.\n\t\t\t\tupdateTicketCache({ cache, datetimeIn, datetimeId, action });\n\n\t\t\t\t// Remove the datetime from all ticket relations\n\t\t\t\tremoveRelation({\n\t\t\t\t\tentity: 'datetimes',\n\t\t\t\t\tentityId: datetimeId,\n\t\t\t\t\trelation: 'tickets',\n\t\t\t\t});\n\t\t\t\t// Drop all the relations for the datetime\n\t\t\t\tdropRelations({\n\t\t\t\t\tentity: 'datetimes',\n\t\t\t\t\tentityId: datetimeId,\n\t\t\t\t});\n\t\t\t}\n\t\t\t// Update datetime cache after tickets cache is updated.\n\t\t\tupdateDatetimeCache({ cache, datetimes, datetime: { ...datetime, isTrashed: true }, action });\n\t\t},\n\t\t[dropRelations, removeRelation, updateDatetimeCache]\n\t);\n\n\treturn onDeleteDatetime;\n};\n\nexport default useOnDeleteDatetime;\n","import { useCallback } from 'react';\n\nimport { useRelations } from '@eventespresso/services';\nimport { getGuids, hasTempId } from '@eventespresso/predicates';\nimport updatePriceCache from './updatePriceCache';\nimport useUpdateTicketCache from './useUpdateTicketCache';\nimport type { TicketMutationCallbackFn, TicketMutationCallbackFnArgs } from '../types';\n\nconst useOnDeleteTicket = (): TicketMutationCallbackFn => {\n\tconst { dropRelations, removeRelation } = useRelations();\n\n\tconst updateTicketCache = useUpdateTicketCache();\n\n\tconst onDeleteTicket = useCallback(\n\t\t({ cache, tickets, ticket, deletePermanently }: TicketMutationCallbackFnArgs): void => {\n\t\t\tconst action = deletePermanently ? 'remove' : 'update';\n\t\t\tif (!hasTempId(ticket) && deletePermanently) {\n\t\t\t\tconst { nodes = [] } = tickets;\n\t\t\t\tconst ticketIn = getGuids(nodes);\n\t\t\t\tconst { id: ticketId } = ticket;\n\n\t\t\t\t// Update prices cache for the changed tickets,\n\t\t\t\t// to avoid refetching of prices.\n\t\t\t\tupdatePriceCache({ cache, ticketIn, ticketId, action });\n\n\t\t\t\t// Remove the ticket from all datetime relations\n\t\t\t\tremoveRelation({\n\t\t\t\t\tentity: 'tickets',\n\t\t\t\t\tentityId: ticketId,\n\t\t\t\t\trelation: 'datetimes',\n\t\t\t\t});\n\t\t\t\t// Remove the ticket from all price relations\n\t\t\t\tremoveRelation({\n\t\t\t\t\tentity: 'tickets',\n\t\t\t\t\tentityId: ticketId,\n\t\t\t\t\trelation: 'prices',\n\t\t\t\t});\n\t\t\t\t// Drop all the relations for the ticket\n\t\t\t\tdropRelations({\n\t\t\t\t\tentity: 'tickets',\n\t\t\t\t\tentityId: ticketId,\n\t\t\t\t});\n\t\t\t}\n\t\t\t// Update ticket cache after price cache is updated.\n\t\t\tupdateTicketCache({ cache, tickets, ticket: { ...ticket, isTrashed: true }, action });\n\t\t},\n\t\t[dropRelations, removeRelation, updateTicketCache]\n\t);\n\n\treturn onDeleteTicket;\n};\n\nexport default useOnDeleteTicket;\n","import { assocPath, pathOr, uniqBy, sortBy, identity } from 'ramda';\n\nimport type { CacheUpdaterFnArgs } from '../types';\nimport { DEFAULT_PRICE_LIST_DATA, GET_PRICES } from '../../queries';\nimport type { Price, PricesList } from '../../types';\nimport type { CacheQueryOptions, WriteQueryOptions } from '@eventespresso/data';\nimport { entityDbId } from '@eventespresso/predicates';\n\nconst updatePriceCache = ({ cache, prices = null, ticketIn, ticketId, action }: CacheUpdaterFnArgs): void => {\n\tconst queryOptions: CacheQueryOptions = {\n\t\tquery: GET_PRICES,\n\t\tvariables: {\n\t\t\twhere: {\n\t\t\t\tticketIn: sortBy(identity, ticketIn),\n\t\t\t\tincludeDefaultPrices: true,\n\t\t\t},\n\t\t},\n\t};\n\tlet data: PricesList;\n\t// Read the existing data from cache.\n\ttry {\n\t\tdata = cache.readQuery(queryOptions);\n\t} catch (error) {\n\t\t// do nothing with the error\n\t}\n\n\t// if there is no data, make sure GQL type is properly set.\n\tif (!data?.espressoPrices) {\n\t\tdata = {\n\t\t\tespressoPrices: DEFAULT_PRICE_LIST_DATA,\n\t\t};\n\t}\n\n\tlet newTicketIn: typeof ticketIn;\n\n\tswitch (action) {\n\t\tcase 'add':\n\t\t\tnewTicketIn = [...ticketIn, ticketId];\n\t\t\tbreak;\n\t\tcase 'remove':\n\t\t\tnewTicketIn = ticketIn.filter((id) => id !== ticketId);\n\t\t\tbreak;\n\t\tdefault:\n\t\t\tnewTicketIn = ticketIn;\n\t\t\tbreak;\n\t}\n\n\tconst priceNodes = prices?.nodes || [];\n\tconst pathToNodes = ['espressoPrices', 'nodes'];\n\n\tif (action === 'add' && priceNodes.length) {\n\t\tconst existingPrices = pathOr([], pathToNodes, data);\n\t\t// make sure that default prices are not repeated\n\t\tconst newPrices = uniqBy(entityDbId, [...existingPrices, ...priceNodes]);\n\t\tdata = assocPath(pathToNodes, newPrices, data);\n\t}\n\tconst nodes = pathOr([], pathToNodes, data);\n\t// if there are no prices\n\tif (!nodes.length) {\n\t\treturn;\n\t}\n\n\t// write the data to cache without\n\t// mutating the cache directly\n\tconst writeOptions: WriteQueryOptions = {\n\t\tquery: GET_PRICES,\n\t\tdata,\n\t\tvariables: {\n\t\t\twhere: {\n\t\t\t\tticketIn: sortBy(identity, newTicketIn),\n\t\t\t\tincludeDefaultPrices: true,\n\t\t\t},\n\t\t},\n\t};\n\tcache.writeQuery(writeOptions);\n};\n\nexport default updatePriceCache;\n","import { useCallback, useState, useMemo, useEffect } from 'react';\nimport { clone } from 'ramda';\nimport type { MutationResult } from '@apollo/client';\n\nimport { __ } from '@eventespresso/i18n';\nimport { gql, useMutation } from '@eventespresso/data';\nimport { useSystemNotifications } from '@eventespresso/toaster';\nimport { getGuids } from '@eventespresso/predicates';\nimport type { EntityId } from '@eventespresso/data';\nimport type { Datetime, Ticket } from '../types';\n\ntype Entity = Datetime | Ticket;\n\ninterface ReorderEntitiesProps {\n\tentityType: 'DATETIME' | 'TICKET';\n\tfilteredEntities: Array;\n}\n\ninterface CallbackArgs {\n\tallEntities: Array;\n\tnewIndex: number;\n\toldIndex: number;\n}\n\ntype SortCallback = (args: CallbackArgs) => Array;\n\nconst REORDER_ENTITIES = gql`\n\tmutation REORDER_ENTITIES($input: ReorderEspressoEntitiesInput!) {\n\t\treorderEspressoEntities(input: $input) {\n\t\t\tok\n\t\t}\n\t}\n`;\n\nexport interface ReorderEntities {\n\tallReorderedEntities: Array;\n\tupdateSortOrder: () => Promise;\n\tresult: MutationResult;\n\tsortEntities: SortCallback;\n\tupdateEntityList?: VoidFunction;\n}\n\nexport const useReorderEntities = ({\n\tentityType,\n\tfilteredEntities,\n}: ReorderEntitiesProps): ReorderEntities => {\n\tconst toaster = useSystemNotifications();\n\tconst [allEntityGuids, setAllEntityGuids] = useState>([]);\n\tconst [allReorderedEntities, setAllOrderedEntities] = useState>(filteredEntities);\n\n\tconst [mutate, result] = useMutation(REORDER_ENTITIES);\n\n\tconst updateSortOrder = useCallback(async () => {\n\t\tawait mutate({\n\t\t\tvariables: {\n\t\t\t\tinput: {\n\t\t\t\t\tclientMutationId: 'REORDER_ENTITIES',\n\t\t\t\t\tentityIds: allEntityGuids,\n\t\t\t\t\tentityType,\n\t\t\t\t},\n\t\t\t},\n\t\t});\n\t\ttoaster.success({ message: __('order updated') });\n\t\treturn true;\n\t}, [allEntityGuids, entityType, mutate, toaster]);\n\n\tuseEffect(() => {\n\t\tsetAllOrderedEntities(filteredEntities);\n\t}, [filteredEntities]);\n\n\tconst sortEntities = useCallback>(\n\t\t({ allEntities: allEntitiesList, newIndex, oldIndex }) => {\n\t\t\tif (newIndex === oldIndex || newIndex < 0 || oldIndex < 0) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tconst entityIds = clone(allReorderedEntities.map(({ id }) => id));\n\t\t\tlet allEntities = clone(allEntitiesList);\n\n\t\t\t// remove entity from existing location in filtered list\n\t\t\tconst [removed] = entityIds.splice(oldIndex, 1);\n\n\t\t\t// insert removed entity into new location in same list\n\t\t\tentityIds.splice(newIndex, 0, removed);\n\n\t\t\t// now loop thru entities in filtered list\n\t\t\tconst entities = entityIds.map((entityId, index) => {\n\t\t\t\t// grab index of reordered entities in list of all entities\n\t\t\t\tconst indexInAll = allEntities.findIndex((item) => item.id === entityId);\n\t\t\t\t// remove reordered entities from list of all entities\n\t\t\t\tconst [entity] = allEntities.splice(indexInAll, 1);\n\n\t\t\t\t// reset the order property for all entities in filtered list\n\t\t\t\treturn { ...entity, order: index + 1 };\n\t\t\t});\n\n\t\t\t// insert ordered entities at the beginning of the array\n\t\t\t// which means trashed ones will land up at the end\n\t\t\tallEntities = [...entities, ...allEntities];\n\n\t\t\t// but now we need to reset the order properties for ALL entities\n\t\t\tallEntities.map((entity, index) => {\n\t\t\t\t// add 1 so we don't end up with order: 0\n\t\t\t\treturn { ...entity, order: index + 1 };\n\t\t\t});\n\n\t\t\tsetAllOrderedEntities(entities);\n\n\t\t\tsetAllEntityGuids(getGuids(allEntities));\n\n\t\t\treturn allEntities;\n\t\t},\n\t\t[allReorderedEntities]\n\t);\n\n\treturn useMemo(\n\t\t() => ({ allReorderedEntities, updateSortOrder, result, sortEntities }),\n\t\t[allReorderedEntities, updateSortOrder, result, sortEntities]\n\t);\n};\n","import { useCallback } from 'react';\n\nimport { useRelations } from '@eventespresso/services';\nimport { hasTempId } from '@eventespresso/predicates';\n\nimport useUpdateTicketCache from './useUpdateTicketCache';\nimport type { TicketMutationCallbackFn, TicketMutationCallbackFnArgs } from '../types';\n\nconst useOnUpdateTicket = (): TicketMutationCallbackFn => {\n\tconst { addRelation, removeRelation, updateRelations } = useRelations();\n\n\tconst updateTicketCache = useUpdateTicketCache();\n\n\tconst onUpdateTicket = useCallback(\n\t\t({ cache, tickets, ticket, datetimeIds, priceIds }: TicketMutationCallbackFnArgs): void => {\n\t\t\tif (hasTempId(ticket)) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tconst ticketId = ticket.id;\n\t\t\t// if related datetimes are passed\n\t\t\t// may be empty array to remove relations\n\t\t\tif (datetimeIds) {\n\t\t\t\t// make sure to remove ticket from\n\t\t\t\t// all existing relations\n\t\t\t\tremoveRelation({\n\t\t\t\t\tentity: 'tickets',\n\t\t\t\t\tentityId: ticketId,\n\t\t\t\t\trelation: 'datetimes',\n\t\t\t\t});\n\n\t\t\t\t// if we have any datetime ids\n\t\t\t\tif (datetimeIds.length) {\n\t\t\t\t\tupdateRelations({\n\t\t\t\t\t\tentity: 'tickets',\n\t\t\t\t\t\tentityId: ticketId,\n\t\t\t\t\t\trelation: 'datetimes',\n\t\t\t\t\t\trelationIds: datetimeIds,\n\t\t\t\t\t});\n\n\t\t\t\t\tdatetimeIds.forEach((entityId: string) => {\n\t\t\t\t\t\taddRelation({\n\t\t\t\t\t\t\tentity: 'datetimes',\n\t\t\t\t\t\t\tentityId,\n\t\t\t\t\t\t\trelation: 'tickets',\n\t\t\t\t\t\t\trelationId: ticketId,\n\t\t\t\t\t\t});\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// if related prices are passed\n\t\t\t// may be empty array to remove relations\n\t\t\tif (priceIds) {\n\t\t\t\t// make sure to remove ticket from\n\t\t\t\t// all existing relations\n\t\t\t\tremoveRelation({\n\t\t\t\t\tentity: 'tickets',\n\t\t\t\t\tentityId: ticketId,\n\t\t\t\t\trelation: 'prices',\n\t\t\t\t});\n\n\t\t\t\t// if we have any price ids\n\t\t\t\tif (priceIds.length) {\n\t\t\t\t\tupdateRelations({\n\t\t\t\t\t\tentity: 'tickets',\n\t\t\t\t\t\tentityId: ticketId,\n\t\t\t\t\t\trelation: 'prices',\n\t\t\t\t\t\trelationIds: priceIds,\n\t\t\t\t\t});\n\n\t\t\t\t\tpriceIds.forEach((entityId: string) => {\n\t\t\t\t\t\taddRelation({\n\t\t\t\t\t\t\tentity: 'prices',\n\t\t\t\t\t\t\tentityId,\n\t\t\t\t\t\t\trelation: 'tickets',\n\t\t\t\t\t\t\trelationId: ticketId,\n\t\t\t\t\t\t});\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (cache && tickets) {\n\t\t\t\t// Update ticket cache.\n\t\t\t\tupdateTicketCache({ cache, tickets, ticket, action: 'update' });\n\t\t\t}\n\t\t},\n\t\t[addRelation, removeRelation, updateRelations, updateTicketCache]\n\t);\n\n\treturn onUpdateTicket;\n};\n\nexport default useOnUpdateTicket;\n","import { useCallback } from 'react';\nimport * as R from 'ramda';\n\nimport { useRelations } from '@eventespresso/services';\nimport { MutationType, InternalRefetchQueriesInclude } from '@eventespresso/data';\n\nimport { GET_DATETIME } from '../../queries';\nimport { TicketCommonInput } from './types';\n\ntype AffectedDatesQueries = (args: {\n\tinput: TicketCommonInput;\n\tmutationType?: MutationType;\n}) => InternalRefetchQueriesInclude;\n\n/**\n * Returns the queries of the affected dates as a result of ticket mutations.\n */\nconst useAffectedDatesQueries = (): AffectedDatesQueries => {\n\tconst { getRelations } = useRelations();\n\n\treturn useCallback(\n\t\t({ input, mutationType = MutationType.Update }) => {\n\t\t\t// if we have an id and related datetimes or if it's a delete mutation\n\t\t\tif ((input.id && input.datetimes) || mutationType === MutationType.Delete) {\n\t\t\t\tconst oldDatetimeIds = getRelations({\n\t\t\t\t\tentity: 'tickets',\n\t\t\t\t\tentityId: input.id,\n\t\t\t\t\trelation: 'datetimes',\n\t\t\t\t});\n\n\t\t\t\t// These are the datetime ids which were removed or added for the ticket.\n\t\t\t\t// It removes the ids that were present before as well as afterwards.\n\t\t\t\tconst affectedDatetimeIds = R.difference(\n\t\t\t\t\tR.union(oldDatetimeIds, input.datetimes || []),\n\t\t\t\t\tR.intersection(oldDatetimeIds, input.datetimes || [])\n\t\t\t\t);\n\n\t\t\t\treturn affectedDatetimeIds.map((id) => ({\n\t\t\t\t\tquery: GET_DATETIME,\n\t\t\t\t\tvariables: { id },\n\t\t\t\t}));\n\t\t\t}\n\t\t},\n\t\t[getRelations]\n\t);\n};\n\nexport default useAffectedDatesQueries;\n","function _has(prop, obj) {\n return Object.prototype.hasOwnProperty.call(obj, prop);\n}\n\nmodule.exports = _has;","/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * The base implementation of `_.has` without support for deep paths.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {Array|string} key The key to check.\n * @returns {boolean} Returns `true` if `key` exists, else `false`.\n */\nfunction baseHas(object, key) {\n return object != null && hasOwnProperty.call(object, key);\n}\n\nmodule.exports = baseHas;\n","var Symbol = require('./_Symbol');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar nativeObjectToString = objectProto.toString;\n\n/** Built-in value references. */\nvar symToStringTag = Symbol ? Symbol.toStringTag : undefined;\n\n/**\n * A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the raw `toStringTag`.\n */\nfunction getRawTag(value) {\n var isOwn = hasOwnProperty.call(value, symToStringTag),\n tag = value[symToStringTag];\n\n try {\n value[symToStringTag] = undefined;\n var unmasked = true;\n } catch (e) {}\n\n var result = nativeObjectToString.call(value);\n if (unmasked) {\n if (isOwn) {\n value[symToStringTag] = tag;\n } else {\n delete value[symToStringTag];\n }\n }\n return result;\n}\n\nmodule.exports = getRawTag;\n","/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar nativeObjectToString = objectProto.toString;\n\n/**\n * Converts `value` to a string using `Object.prototype.toString`.\n *\n * @private\n * @param {*} value The value to convert.\n * @returns {string} Returns the converted string.\n */\nfunction objectToString(value) {\n return nativeObjectToString.call(value);\n}\n\nmodule.exports = objectToString;\n","var memoizeCapped = require('./_memoizeCapped');\n\n/** Used to match property names within property paths. */\nvar rePropName = /[^.[\\]]+|\\[(?:(-?\\d+(?:\\.\\d+)?)|([\"'])((?:(?!\\2)[^\\\\]|\\\\.)*?)\\2)\\]|(?=(?:\\.|\\[\\])(?:\\.|\\[\\]|$))/g;\n\n/** Used to match backslashes in property paths. */\nvar reEscapeChar = /\\\\(\\\\)?/g;\n\n/**\n * Converts `string` to a property path array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the property path array.\n */\nvar stringToPath = memoizeCapped(function(string) {\n var result = [];\n if (string.charCodeAt(0) === 46 /* . */) {\n result.push('');\n }\n string.replace(rePropName, function(match, number, quote, subString) {\n result.push(quote ? subString.replace(reEscapeChar, '$1') : (number || match));\n });\n return result;\n});\n\nmodule.exports = stringToPath;\n","var memoize = require('./memoize');\n\n/** Used as the maximum memoize cache size. */\nvar MAX_MEMOIZE_SIZE = 500;\n\n/**\n * A specialized version of `_.memoize` which clears the memoized function's\n * cache when it exceeds `MAX_MEMOIZE_SIZE`.\n *\n * @private\n * @param {Function} func The function to have its output memoized.\n * @returns {Function} Returns the new memoized function.\n */\nfunction memoizeCapped(func) {\n var result = memoize(func, function(key) {\n if (cache.size === MAX_MEMOIZE_SIZE) {\n cache.clear();\n }\n return key;\n });\n\n var cache = result.cache;\n return result;\n}\n\nmodule.exports = memoizeCapped;\n","var MapCache = require('./_MapCache');\n\n/** Error message constants. */\nvar FUNC_ERROR_TEXT = 'Expected a function';\n\n/**\n * Creates a function that memoizes the result of `func`. If `resolver` is\n * provided, it determines the cache key for storing the result based on the\n * arguments provided to the memoized function. By default, the first argument\n * provided to the memoized function is used as the map cache key. The `func`\n * is invoked with the `this` binding of the memoized function.\n *\n * **Note:** The cache is exposed as the `cache` property on the memoized\n * function. Its creation may be customized by replacing the `_.memoize.Cache`\n * constructor with one whose instances implement the\n * [`Map`](http://ecma-international.org/ecma-262/7.0/#sec-properties-of-the-map-prototype-object)\n * method interface of `clear`, `delete`, `get`, `has`, and `set`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Function\n * @param {Function} func The function to have its output memoized.\n * @param {Function} [resolver] The function to resolve the cache key.\n * @returns {Function} Returns the new memoized function.\n * @example\n *\n * var object = { 'a': 1, 'b': 2 };\n * var other = { 'c': 3, 'd': 4 };\n *\n * var values = _.memoize(_.values);\n * values(object);\n * // => [1, 2]\n *\n * values(other);\n * // => [3, 4]\n *\n * object.a = 2;\n * values(object);\n * // => [1, 2]\n *\n * // Modify the result cache.\n * values.cache.set(object, ['a', 'b']);\n * values(object);\n * // => ['a', 'b']\n *\n * // Replace `_.memoize.Cache`.\n * _.memoize.Cache = WeakMap;\n */\nfunction memoize(func, resolver) {\n if (typeof func != 'function' || (resolver != null && typeof resolver != 'function')) {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n var memoized = function() {\n var args = arguments,\n key = resolver ? resolver.apply(this, args) : args[0],\n cache = memoized.cache;\n\n if (cache.has(key)) {\n return cache.get(key);\n }\n var result = func.apply(this, args);\n memoized.cache = cache.set(key, result) || cache;\n return result;\n };\n memoized.cache = new (memoize.Cache || MapCache);\n return memoized;\n}\n\n// Expose `MapCache`.\nmemoize.Cache = MapCache;\n\nmodule.exports = memoize;\n","var Hash = require('./_Hash'),\n ListCache = require('./_ListCache'),\n Map = require('./_Map');\n\n/**\n * Removes all key-value entries from the map.\n *\n * @private\n * @name clear\n * @memberOf MapCache\n */\nfunction mapCacheClear() {\n this.size = 0;\n this.__data__ = {\n 'hash': new Hash,\n 'map': new (Map || ListCache),\n 'string': new Hash\n };\n}\n\nmodule.exports = mapCacheClear;\n","var hashClear = require('./_hashClear'),\n hashDelete = require('./_hashDelete'),\n hashGet = require('./_hashGet'),\n hashHas = require('./_hashHas'),\n hashSet = require('./_hashSet');\n\n/**\n * Creates a hash object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction Hash(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `Hash`.\nHash.prototype.clear = hashClear;\nHash.prototype['delete'] = hashDelete;\nHash.prototype.get = hashGet;\nHash.prototype.has = hashHas;\nHash.prototype.set = hashSet;\n\nmodule.exports = Hash;\n","var nativeCreate = require('./_nativeCreate');\n\n/**\n * Removes all key-value entries from the hash.\n *\n * @private\n * @name clear\n * @memberOf Hash\n */\nfunction hashClear() {\n this.__data__ = nativeCreate ? nativeCreate(null) : {};\n this.size = 0;\n}\n\nmodule.exports = hashClear;\n","var isFunction = require('./isFunction'),\n isMasked = require('./_isMasked'),\n isObject = require('./isObject'),\n toSource = require('./_toSource');\n\n/**\n * Used to match `RegExp`\n * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns).\n */\nvar reRegExpChar = /[\\\\^$.*+?()[\\]{}|]/g;\n\n/** Used to detect host constructors (Safari). */\nvar reIsHostCtor = /^\\[object .+?Constructor\\]$/;\n\n/** Used for built-in method references. */\nvar funcProto = Function.prototype,\n objectProto = Object.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Used to detect if a method is native. */\nvar reIsNative = RegExp('^' +\n funcToString.call(hasOwnProperty).replace(reRegExpChar, '\\\\$&')\n .replace(/hasOwnProperty|(function).*?(?=\\\\\\()| for .+?(?=\\\\\\])/g, '$1.*?') + '$'\n);\n\n/**\n * The base implementation of `_.isNative` without bad shim checks.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a native function,\n * else `false`.\n */\nfunction baseIsNative(value) {\n if (!isObject(value) || isMasked(value)) {\n return false;\n }\n var pattern = isFunction(value) ? reIsNative : reIsHostCtor;\n return pattern.test(toSource(value));\n}\n\nmodule.exports = baseIsNative;\n","var coreJsData = require('./_coreJsData');\n\n/** Used to detect methods masquerading as native. */\nvar maskSrcKey = (function() {\n var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || '');\n return uid ? ('Symbol(src)_1.' + uid) : '';\n}());\n\n/**\n * Checks if `func` has its source masked.\n *\n * @private\n * @param {Function} func The function to check.\n * @returns {boolean} Returns `true` if `func` is masked, else `false`.\n */\nfunction isMasked(func) {\n return !!maskSrcKey && (maskSrcKey in func);\n}\n\nmodule.exports = isMasked;\n","var root = require('./_root');\n\n/** Used to detect overreaching core-js shims. */\nvar coreJsData = root['__core-js_shared__'];\n\nmodule.exports = coreJsData;\n","/**\n * Gets the value at `key` of `object`.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {string} key The key of the property to get.\n * @returns {*} Returns the property value.\n */\nfunction getValue(object, key) {\n return object == null ? undefined : object[key];\n}\n\nmodule.exports = getValue;\n","/**\n * Removes `key` and its value from the hash.\n *\n * @private\n * @name delete\n * @memberOf Hash\n * @param {Object} hash The hash to modify.\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction hashDelete(key) {\n var result = this.has(key) && delete this.__data__[key];\n this.size -= result ? 1 : 0;\n return result;\n}\n\nmodule.exports = hashDelete;\n","var nativeCreate = require('./_nativeCreate');\n\n/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Gets the hash value for `key`.\n *\n * @private\n * @name get\n * @memberOf Hash\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction hashGet(key) {\n var data = this.__data__;\n if (nativeCreate) {\n var result = data[key];\n return result === HASH_UNDEFINED ? undefined : result;\n }\n return hasOwnProperty.call(data, key) ? data[key] : undefined;\n}\n\nmodule.exports = hashGet;\n","var nativeCreate = require('./_nativeCreate');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Checks if a hash value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Hash\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction hashHas(key) {\n var data = this.__data__;\n return nativeCreate ? (data[key] !== undefined) : hasOwnProperty.call(data, key);\n}\n\nmodule.exports = hashHas;\n","var nativeCreate = require('./_nativeCreate');\n\n/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/**\n * Sets the hash `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Hash\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the hash instance.\n */\nfunction hashSet(key, value) {\n var data = this.__data__;\n this.size += this.has(key) ? 0 : 1;\n data[key] = (nativeCreate && value === undefined) ? HASH_UNDEFINED : value;\n return this;\n}\n\nmodule.exports = hashSet;\n","/**\n * Removes all key-value entries from the list cache.\n *\n * @private\n * @name clear\n * @memberOf ListCache\n */\nfunction listCacheClear() {\n this.__data__ = [];\n this.size = 0;\n}\n\nmodule.exports = listCacheClear;\n","var assocIndexOf = require('./_assocIndexOf');\n\n/** Used for built-in method references. */\nvar arrayProto = Array.prototype;\n\n/** Built-in value references. */\nvar splice = arrayProto.splice;\n\n/**\n * Removes `key` and its value from the list cache.\n *\n * @private\n * @name delete\n * @memberOf ListCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction listCacheDelete(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n return false;\n }\n var lastIndex = data.length - 1;\n if (index == lastIndex) {\n data.pop();\n } else {\n splice.call(data, index, 1);\n }\n --this.size;\n return true;\n}\n\nmodule.exports = listCacheDelete;\n","var assocIndexOf = require('./_assocIndexOf');\n\n/**\n * Gets the list cache value for `key`.\n *\n * @private\n * @name get\n * @memberOf ListCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction listCacheGet(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n return index < 0 ? undefined : data[index][1];\n}\n\nmodule.exports = listCacheGet;\n","var assocIndexOf = require('./_assocIndexOf');\n\n/**\n * Checks if a list cache value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf ListCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction listCacheHas(key) {\n return assocIndexOf(this.__data__, key) > -1;\n}\n\nmodule.exports = listCacheHas;\n","var assocIndexOf = require('./_assocIndexOf');\n\n/**\n * Sets the list cache `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf ListCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the list cache instance.\n */\nfunction listCacheSet(key, value) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n ++this.size;\n data.push([key, value]);\n } else {\n data[index][1] = value;\n }\n return this;\n}\n\nmodule.exports = listCacheSet;\n","var getMapData = require('./_getMapData');\n\n/**\n * Removes `key` and its value from the map.\n *\n * @private\n * @name delete\n * @memberOf MapCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction mapCacheDelete(key) {\n var result = getMapData(this, key)['delete'](key);\n this.size -= result ? 1 : 0;\n return result;\n}\n\nmodule.exports = mapCacheDelete;\n","/**\n * Checks if `value` is suitable for use as unique object key.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is suitable, else `false`.\n */\nfunction isKeyable(value) {\n var type = typeof value;\n return (type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean')\n ? (value !== '__proto__')\n : (value === null);\n}\n\nmodule.exports = isKeyable;\n","var getMapData = require('./_getMapData');\n\n/**\n * Gets the map value for `key`.\n *\n * @private\n * @name get\n * @memberOf MapCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction mapCacheGet(key) {\n return getMapData(this, key).get(key);\n}\n\nmodule.exports = mapCacheGet;\n","var getMapData = require('./_getMapData');\n\n/**\n * Checks if a map value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf MapCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction mapCacheHas(key) {\n return getMapData(this, key).has(key);\n}\n\nmodule.exports = mapCacheHas;\n","var getMapData = require('./_getMapData');\n\n/**\n * Sets the map `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf MapCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the map cache instance.\n */\nfunction mapCacheSet(key, value) {\n var data = getMapData(this, key),\n size = data.size;\n\n data.set(key, value);\n this.size += data.size == size ? 0 : 1;\n return this;\n}\n\nmodule.exports = mapCacheSet;\n","var Symbol = require('./_Symbol'),\n arrayMap = require('./_arrayMap'),\n isArray = require('./isArray'),\n isSymbol = require('./isSymbol');\n\n/** Used as references for various `Number` constants. */\nvar INFINITY = 1 / 0;\n\n/** Used to convert symbols to primitives and strings. */\nvar symbolProto = Symbol ? Symbol.prototype : undefined,\n symbolToString = symbolProto ? symbolProto.toString : undefined;\n\n/**\n * The base implementation of `_.toString` which doesn't convert nullish\n * values to empty strings.\n *\n * @private\n * @param {*} value The value to process.\n * @returns {string} Returns the string.\n */\nfunction baseToString(value) {\n // Exit early for strings to avoid a performance hit in some environments.\n if (typeof value == 'string') {\n return value;\n }\n if (isArray(value)) {\n // Recursively convert values (susceptible to call stack limits).\n return arrayMap(value, baseToString) + '';\n }\n if (isSymbol(value)) {\n return symbolToString ? symbolToString.call(value) : '';\n }\n var result = (value + '');\n return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;\n}\n\nmodule.exports = baseToString;\n","/**\n * A specialized version of `_.map` for arrays without support for iteratee\n * shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns the new mapped array.\n */\nfunction arrayMap(array, iteratee) {\n var index = -1,\n length = array == null ? 0 : array.length,\n result = Array(length);\n\n while (++index < length) {\n result[index] = iteratee(array[index], index, array);\n }\n return result;\n}\n\nmodule.exports = arrayMap;\n","var baseGetTag = require('./_baseGetTag'),\n isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]';\n\n/**\n * The base implementation of `_.isArguments`.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\n */\nfunction baseIsArguments(value) {\n return isObjectLike(value) && baseGetTag(value) == argsTag;\n}\n\nmodule.exports = baseIsArguments;\n","var getNative = require('./_getNative');\n\nvar defineProperty = (function() {\n try {\n var func = getNative(Object, 'defineProperty');\n func({}, '', {});\n return func;\n } catch (e) {}\n}());\n\nmodule.exports = defineProperty;\n","var createBaseFor = require('./_createBaseFor');\n\n/**\n * The base implementation of `baseForOwn` which iterates over `object`\n * properties returned by `keysFunc` and invokes `iteratee` for each property.\n * Iteratee functions may exit iteration early by explicitly returning `false`.\n *\n * @private\n * @param {Object} object The object to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @param {Function} keysFunc The function to get the keys of `object`.\n * @returns {Object} Returns `object`.\n */\nvar baseFor = createBaseFor();\n\nmodule.exports = baseFor;\n","/**\n * Creates a base function for methods like `_.forIn` and `_.forOwn`.\n *\n * @private\n * @param {boolean} [fromRight] Specify iterating from right to left.\n * @returns {Function} Returns the new base function.\n */\nfunction createBaseFor(fromRight) {\n return function(object, iteratee, keysFunc) {\n var index = -1,\n iterable = Object(object),\n props = keysFunc(object),\n length = props.length;\n\n while (length--) {\n var key = props[fromRight ? length : ++index];\n if (iteratee(iterable[key], key, iterable) === false) {\n break;\n }\n }\n return object;\n };\n}\n\nmodule.exports = createBaseFor;\n","var baseTimes = require('./_baseTimes'),\n isArguments = require('./isArguments'),\n isArray = require('./isArray'),\n isBuffer = require('./isBuffer'),\n isIndex = require('./_isIndex'),\n isTypedArray = require('./isTypedArray');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Creates an array of the enumerable property names of the array-like `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @param {boolean} inherited Specify returning inherited property names.\n * @returns {Array} Returns the array of property names.\n */\nfunction arrayLikeKeys(value, inherited) {\n var isArr = isArray(value),\n isArg = !isArr && isArguments(value),\n isBuff = !isArr && !isArg && isBuffer(value),\n isType = !isArr && !isArg && !isBuff && isTypedArray(value),\n skipIndexes = isArr || isArg || isBuff || isType,\n result = skipIndexes ? baseTimes(value.length, String) : [],\n length = result.length;\n\n for (var key in value) {\n if ((inherited || hasOwnProperty.call(value, key)) &&\n !(skipIndexes && (\n // Safari 9 has enumerable `arguments.length` in strict mode.\n key == 'length' ||\n // Node.js 0.10 has enumerable non-index properties on buffers.\n (isBuff && (key == 'offset' || key == 'parent')) ||\n // PhantomJS 2 has enumerable non-index properties on typed arrays.\n (isType && (key == 'buffer' || key == 'byteLength' || key == 'byteOffset')) ||\n // Skip index properties.\n isIndex(key, length)\n ))) {\n result.push(key);\n }\n }\n return result;\n}\n\nmodule.exports = arrayLikeKeys;\n","/**\n * The base implementation of `_.times` without support for iteratee shorthands\n * or max array length checks.\n *\n * @private\n * @param {number} n The number of times to invoke `iteratee`.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns the array of results.\n */\nfunction baseTimes(n, iteratee) {\n var index = -1,\n result = Array(n);\n\n while (++index < n) {\n result[index] = iteratee(index);\n }\n return result;\n}\n\nmodule.exports = baseTimes;\n","/**\n * This method returns `false`.\n *\n * @static\n * @memberOf _\n * @since 4.13.0\n * @category Util\n * @returns {boolean} Returns `false`.\n * @example\n *\n * _.times(2, _.stubFalse);\n * // => [false, false]\n */\nfunction stubFalse() {\n return false;\n}\n\nmodule.exports = stubFalse;\n","var baseGetTag = require('./_baseGetTag'),\n isLength = require('./isLength'),\n isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]',\n arrayTag = '[object Array]',\n boolTag = '[object Boolean]',\n dateTag = '[object Date]',\n errorTag = '[object Error]',\n funcTag = '[object Function]',\n mapTag = '[object Map]',\n numberTag = '[object Number]',\n objectTag = '[object Object]',\n regexpTag = '[object RegExp]',\n setTag = '[object Set]',\n stringTag = '[object String]',\n weakMapTag = '[object WeakMap]';\n\nvar arrayBufferTag = '[object ArrayBuffer]',\n dataViewTag = '[object DataView]',\n float32Tag = '[object Float32Array]',\n float64Tag = '[object Float64Array]',\n int8Tag = '[object Int8Array]',\n int16Tag = '[object Int16Array]',\n int32Tag = '[object Int32Array]',\n uint8Tag = '[object Uint8Array]',\n uint8ClampedTag = '[object Uint8ClampedArray]',\n uint16Tag = '[object Uint16Array]',\n uint32Tag = '[object Uint32Array]';\n\n/** Used to identify `toStringTag` values of typed arrays. */\nvar typedArrayTags = {};\ntypedArrayTags[float32Tag] = typedArrayTags[float64Tag] =\ntypedArrayTags[int8Tag] = typedArrayTags[int16Tag] =\ntypedArrayTags[int32Tag] = typedArrayTags[uint8Tag] =\ntypedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] =\ntypedArrayTags[uint32Tag] = true;\ntypedArrayTags[argsTag] = typedArrayTags[arrayTag] =\ntypedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] =\ntypedArrayTags[dataViewTag] = typedArrayTags[dateTag] =\ntypedArrayTags[errorTag] = typedArrayTags[funcTag] =\ntypedArrayTags[mapTag] = typedArrayTags[numberTag] =\ntypedArrayTags[objectTag] = typedArrayTags[regexpTag] =\ntypedArrayTags[setTag] = typedArrayTags[stringTag] =\ntypedArrayTags[weakMapTag] = false;\n\n/**\n * The base implementation of `_.isTypedArray` without Node.js optimizations.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n */\nfunction baseIsTypedArray(value) {\n return isObjectLike(value) &&\n isLength(value.length) && !!typedArrayTags[baseGetTag(value)];\n}\n\nmodule.exports = baseIsTypedArray;\n","/**\n * The base implementation of `_.unary` without support for storing metadata.\n *\n * @private\n * @param {Function} func The function to cap arguments for.\n * @returns {Function} Returns the new capped function.\n */\nfunction baseUnary(func) {\n return function(value) {\n return func(value);\n };\n}\n\nmodule.exports = baseUnary;\n","var freeGlobal = require('./_freeGlobal');\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Detect free variable `process` from Node.js. */\nvar freeProcess = moduleExports && freeGlobal.process;\n\n/** Used to access faster Node.js helpers. */\nvar nodeUtil = (function() {\n try {\n // Use `util.types` for Node.js 10+.\n var types = freeModule && freeModule.require && freeModule.require('util').types;\n\n if (types) {\n return types;\n }\n\n // Legacy `process.binding('util')` for Node.js < 10.\n return freeProcess && freeProcess.binding && freeProcess.binding('util');\n } catch (e) {}\n}());\n\nmodule.exports = nodeUtil;\n","var isPrototype = require('./_isPrototype'),\n nativeKeys = require('./_nativeKeys');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * The base implementation of `_.keys` which doesn't treat sparse arrays as dense.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n */\nfunction baseKeys(object) {\n if (!isPrototype(object)) {\n return nativeKeys(object);\n }\n var result = [];\n for (var key in Object(object)) {\n if (hasOwnProperty.call(object, key) && key != 'constructor') {\n result.push(key);\n }\n }\n return result;\n}\n\nmodule.exports = baseKeys;\n","/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Checks if `value` is likely a prototype object.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a prototype, else `false`.\n */\nfunction isPrototype(value) {\n var Ctor = value && value.constructor,\n proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto;\n\n return value === proto;\n}\n\nmodule.exports = isPrototype;\n","var overArg = require('./_overArg');\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeKeys = overArg(Object.keys, Object);\n\nmodule.exports = nativeKeys;\n","/**\n * Creates a unary function that invokes `func` with its argument transformed.\n *\n * @private\n * @param {Function} func The function to wrap.\n * @param {Function} transform The argument transform.\n * @returns {Function} Returns the new function.\n */\nfunction overArg(func, transform) {\n return function(arg) {\n return func(transform(arg));\n };\n}\n\nmodule.exports = overArg;\n","var isFunction = require('./isFunction'),\n isLength = require('./isLength');\n\n/**\n * Checks if `value` is array-like. A value is considered array-like if it's\n * not a function and has a `value.length` that's an integer greater than or\n * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is array-like, else `false`.\n * @example\n *\n * _.isArrayLike([1, 2, 3]);\n * // => true\n *\n * _.isArrayLike(document.body.children);\n * // => true\n *\n * _.isArrayLike('abc');\n * // => true\n *\n * _.isArrayLike(_.noop);\n * // => false\n */\nfunction isArrayLike(value) {\n return value != null && isLength(value.length) && !isFunction(value);\n}\n\nmodule.exports = isArrayLike;\n","var baseIsMatch = require('./_baseIsMatch'),\n getMatchData = require('./_getMatchData'),\n matchesStrictComparable = require('./_matchesStrictComparable');\n\n/**\n * The base implementation of `_.matches` which doesn't clone `source`.\n *\n * @private\n * @param {Object} source The object of property values to match.\n * @returns {Function} Returns the new spec function.\n */\nfunction baseMatches(source) {\n var matchData = getMatchData(source);\n if (matchData.length == 1 && matchData[0][2]) {\n return matchesStrictComparable(matchData[0][0], matchData[0][1]);\n }\n return function(object) {\n return object === source || baseIsMatch(object, source, matchData);\n };\n}\n\nmodule.exports = baseMatches;\n","var Stack = require('./_Stack'),\n baseIsEqual = require('./_baseIsEqual');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/**\n * The base implementation of `_.isMatch` without support for iteratee shorthands.\n *\n * @private\n * @param {Object} object The object to inspect.\n * @param {Object} source The object of property values to match.\n * @param {Array} matchData The property names, values, and compare flags to match.\n * @param {Function} [customizer] The function to customize comparisons.\n * @returns {boolean} Returns `true` if `object` is a match, else `false`.\n */\nfunction baseIsMatch(object, source, matchData, customizer) {\n var index = matchData.length,\n length = index,\n noCustomizer = !customizer;\n\n if (object == null) {\n return !length;\n }\n object = Object(object);\n while (index--) {\n var data = matchData[index];\n if ((noCustomizer && data[2])\n ? data[1] !== object[data[0]]\n : !(data[0] in object)\n ) {\n return false;\n }\n }\n while (++index < length) {\n data = matchData[index];\n var key = data[0],\n objValue = object[key],\n srcValue = data[1];\n\n if (noCustomizer && data[2]) {\n if (objValue === undefined && !(key in object)) {\n return false;\n }\n } else {\n var stack = new Stack;\n if (customizer) {\n var result = customizer(objValue, srcValue, key, object, source, stack);\n }\n if (!(result === undefined\n ? baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG, customizer, stack)\n : result\n )) {\n return false;\n }\n }\n }\n return true;\n}\n\nmodule.exports = baseIsMatch;\n","var ListCache = require('./_ListCache');\n\n/**\n * Removes all key-value entries from the stack.\n *\n * @private\n * @name clear\n * @memberOf Stack\n */\nfunction stackClear() {\n this.__data__ = new ListCache;\n this.size = 0;\n}\n\nmodule.exports = stackClear;\n","/**\n * Removes `key` and its value from the stack.\n *\n * @private\n * @name delete\n * @memberOf Stack\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction stackDelete(key) {\n var data = this.__data__,\n result = data['delete'](key);\n\n this.size = data.size;\n return result;\n}\n\nmodule.exports = stackDelete;\n","/**\n * Gets the stack value for `key`.\n *\n * @private\n * @name get\n * @memberOf Stack\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction stackGet(key) {\n return this.__data__.get(key);\n}\n\nmodule.exports = stackGet;\n","/**\n * Checks if a stack value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Stack\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction stackHas(key) {\n return this.__data__.has(key);\n}\n\nmodule.exports = stackHas;\n","var ListCache = require('./_ListCache'),\n Map = require('./_Map'),\n MapCache = require('./_MapCache');\n\n/** Used as the size to enable large array optimizations. */\nvar LARGE_ARRAY_SIZE = 200;\n\n/**\n * Sets the stack `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Stack\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the stack cache instance.\n */\nfunction stackSet(key, value) {\n var data = this.__data__;\n if (data instanceof ListCache) {\n var pairs = data.__data__;\n if (!Map || (pairs.length < LARGE_ARRAY_SIZE - 1)) {\n pairs.push([key, value]);\n this.size = ++data.size;\n return this;\n }\n data = this.__data__ = new MapCache(pairs);\n }\n data.set(key, value);\n this.size = data.size;\n return this;\n}\n\nmodule.exports = stackSet;\n","var Stack = require('./_Stack'),\n equalArrays = require('./_equalArrays'),\n equalByTag = require('./_equalByTag'),\n equalObjects = require('./_equalObjects'),\n getTag = require('./_getTag'),\n isArray = require('./isArray'),\n isBuffer = require('./isBuffer'),\n isTypedArray = require('./isTypedArray');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1;\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]',\n arrayTag = '[object Array]',\n objectTag = '[object Object]';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * A specialized version of `baseIsEqual` for arrays and objects which performs\n * deep comparisons and tracks traversed objects enabling objects with circular\n * references to be compared.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} [stack] Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction baseIsEqualDeep(object, other, bitmask, customizer, equalFunc, stack) {\n var objIsArr = isArray(object),\n othIsArr = isArray(other),\n objTag = objIsArr ? arrayTag : getTag(object),\n othTag = othIsArr ? arrayTag : getTag(other);\n\n objTag = objTag == argsTag ? objectTag : objTag;\n othTag = othTag == argsTag ? objectTag : othTag;\n\n var objIsObj = objTag == objectTag,\n othIsObj = othTag == objectTag,\n isSameTag = objTag == othTag;\n\n if (isSameTag && isBuffer(object)) {\n if (!isBuffer(other)) {\n return false;\n }\n objIsArr = true;\n objIsObj = false;\n }\n if (isSameTag && !objIsObj) {\n stack || (stack = new Stack);\n return (objIsArr || isTypedArray(object))\n ? equalArrays(object, other, bitmask, customizer, equalFunc, stack)\n : equalByTag(object, other, objTag, bitmask, customizer, equalFunc, stack);\n }\n if (!(bitmask & COMPARE_PARTIAL_FLAG)) {\n var objIsWrapped = objIsObj && hasOwnProperty.call(object, '__wrapped__'),\n othIsWrapped = othIsObj && hasOwnProperty.call(other, '__wrapped__');\n\n if (objIsWrapped || othIsWrapped) {\n var objUnwrapped = objIsWrapped ? object.value() : object,\n othUnwrapped = othIsWrapped ? other.value() : other;\n\n stack || (stack = new Stack);\n return equalFunc(objUnwrapped, othUnwrapped, bitmask, customizer, stack);\n }\n }\n if (!isSameTag) {\n return false;\n }\n stack || (stack = new Stack);\n return equalObjects(object, other, bitmask, customizer, equalFunc, stack);\n}\n\nmodule.exports = baseIsEqualDeep;\n","var MapCache = require('./_MapCache'),\n setCacheAdd = require('./_setCacheAdd'),\n setCacheHas = require('./_setCacheHas');\n\n/**\n *\n * Creates an array cache object to store unique values.\n *\n * @private\n * @constructor\n * @param {Array} [values] The values to cache.\n */\nfunction SetCache(values) {\n var index = -1,\n length = values == null ? 0 : values.length;\n\n this.__data__ = new MapCache;\n while (++index < length) {\n this.add(values[index]);\n }\n}\n\n// Add methods to `SetCache`.\nSetCache.prototype.add = SetCache.prototype.push = setCacheAdd;\nSetCache.prototype.has = setCacheHas;\n\nmodule.exports = SetCache;\n","/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/**\n * Adds `value` to the array cache.\n *\n * @private\n * @name add\n * @memberOf SetCache\n * @alias push\n * @param {*} value The value to cache.\n * @returns {Object} Returns the cache instance.\n */\nfunction setCacheAdd(value) {\n this.__data__.set(value, HASH_UNDEFINED);\n return this;\n}\n\nmodule.exports = setCacheAdd;\n","/**\n * Checks if `value` is in the array cache.\n *\n * @private\n * @name has\n * @memberOf SetCache\n * @param {*} value The value to search for.\n * @returns {number} Returns `true` if `value` is found, else `false`.\n */\nfunction setCacheHas(value) {\n return this.__data__.has(value);\n}\n\nmodule.exports = setCacheHas;\n","/**\n * A specialized version of `_.some` for arrays without support for iteratee\n * shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {boolean} Returns `true` if any element passes the predicate check,\n * else `false`.\n */\nfunction arraySome(array, predicate) {\n var index = -1,\n length = array == null ? 0 : array.length;\n\n while (++index < length) {\n if (predicate(array[index], index, array)) {\n return true;\n }\n }\n return false;\n}\n\nmodule.exports = arraySome;\n","/**\n * Checks if a `cache` value for `key` exists.\n *\n * @private\n * @param {Object} cache The cache to query.\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction cacheHas(cache, key) {\n return cache.has(key);\n}\n\nmodule.exports = cacheHas;\n","var Symbol = require('./_Symbol'),\n Uint8Array = require('./_Uint8Array'),\n eq = require('./eq'),\n equalArrays = require('./_equalArrays'),\n mapToArray = require('./_mapToArray'),\n setToArray = require('./_setToArray');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/** `Object#toString` result references. */\nvar boolTag = '[object Boolean]',\n dateTag = '[object Date]',\n errorTag = '[object Error]',\n mapTag = '[object Map]',\n numberTag = '[object Number]',\n regexpTag = '[object RegExp]',\n setTag = '[object Set]',\n stringTag = '[object String]',\n symbolTag = '[object Symbol]';\n\nvar arrayBufferTag = '[object ArrayBuffer]',\n dataViewTag = '[object DataView]';\n\n/** Used to convert symbols to primitives and strings. */\nvar symbolProto = Symbol ? Symbol.prototype : undefined,\n symbolValueOf = symbolProto ? symbolProto.valueOf : undefined;\n\n/**\n * A specialized version of `baseIsEqualDeep` for comparing objects of\n * the same `toStringTag`.\n *\n * **Note:** This function only supports comparing values with tags of\n * `Boolean`, `Date`, `Error`, `Number`, `RegExp`, or `String`.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {string} tag The `toStringTag` of the objects to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction equalByTag(object, other, tag, bitmask, customizer, equalFunc, stack) {\n switch (tag) {\n case dataViewTag:\n if ((object.byteLength != other.byteLength) ||\n (object.byteOffset != other.byteOffset)) {\n return false;\n }\n object = object.buffer;\n other = other.buffer;\n\n case arrayBufferTag:\n if ((object.byteLength != other.byteLength) ||\n !equalFunc(new Uint8Array(object), new Uint8Array(other))) {\n return false;\n }\n return true;\n\n case boolTag:\n case dateTag:\n case numberTag:\n // Coerce booleans to `1` or `0` and dates to milliseconds.\n // Invalid dates are coerced to `NaN`.\n return eq(+object, +other);\n\n case errorTag:\n return object.name == other.name && object.message == other.message;\n\n case regexpTag:\n case stringTag:\n // Coerce regexes to strings and treat strings, primitives and objects,\n // as equal. See http://www.ecma-international.org/ecma-262/7.0/#sec-regexp.prototype.tostring\n // for more details.\n return object == (other + '');\n\n case mapTag:\n var convert = mapToArray;\n\n case setTag:\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG;\n convert || (convert = setToArray);\n\n if (object.size != other.size && !isPartial) {\n return false;\n }\n // Assume cyclic values are equal.\n var stacked = stack.get(object);\n if (stacked) {\n return stacked == other;\n }\n bitmask |= COMPARE_UNORDERED_FLAG;\n\n // Recursively compare objects (susceptible to call stack limits).\n stack.set(object, other);\n var result = equalArrays(convert(object), convert(other), bitmask, customizer, equalFunc, stack);\n stack['delete'](object);\n return result;\n\n case symbolTag:\n if (symbolValueOf) {\n return symbolValueOf.call(object) == symbolValueOf.call(other);\n }\n }\n return false;\n}\n\nmodule.exports = equalByTag;\n","var root = require('./_root');\n\n/** Built-in value references. */\nvar Uint8Array = root.Uint8Array;\n\nmodule.exports = Uint8Array;\n","/**\n * Converts `map` to its key-value pairs.\n *\n * @private\n * @param {Object} map The map to convert.\n * @returns {Array} Returns the key-value pairs.\n */\nfunction mapToArray(map) {\n var index = -1,\n result = Array(map.size);\n\n map.forEach(function(value, key) {\n result[++index] = [key, value];\n });\n return result;\n}\n\nmodule.exports = mapToArray;\n","/**\n * Converts `set` to an array of its values.\n *\n * @private\n * @param {Object} set The set to convert.\n * @returns {Array} Returns the values.\n */\nfunction setToArray(set) {\n var index = -1,\n result = Array(set.size);\n\n set.forEach(function(value) {\n result[++index] = value;\n });\n return result;\n}\n\nmodule.exports = setToArray;\n","var getAllKeys = require('./_getAllKeys');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1;\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * A specialized version of `baseIsEqualDeep` for objects with support for\n * partial deep comparisons.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction equalObjects(object, other, bitmask, customizer, equalFunc, stack) {\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG,\n objProps = getAllKeys(object),\n objLength = objProps.length,\n othProps = getAllKeys(other),\n othLength = othProps.length;\n\n if (objLength != othLength && !isPartial) {\n return false;\n }\n var index = objLength;\n while (index--) {\n var key = objProps[index];\n if (!(isPartial ? key in other : hasOwnProperty.call(other, key))) {\n return false;\n }\n }\n // Check that cyclic values are equal.\n var objStacked = stack.get(object);\n var othStacked = stack.get(other);\n if (objStacked && othStacked) {\n return objStacked == other && othStacked == object;\n }\n var result = true;\n stack.set(object, other);\n stack.set(other, object);\n\n var skipCtor = isPartial;\n while (++index < objLength) {\n key = objProps[index];\n var objValue = object[key],\n othValue = other[key];\n\n if (customizer) {\n var compared = isPartial\n ? customizer(othValue, objValue, key, other, object, stack)\n : customizer(objValue, othValue, key, object, other, stack);\n }\n // Recursively compare objects (susceptible to call stack limits).\n if (!(compared === undefined\n ? (objValue === othValue || equalFunc(objValue, othValue, bitmask, customizer, stack))\n : compared\n )) {\n result = false;\n break;\n }\n skipCtor || (skipCtor = key == 'constructor');\n }\n if (result && !skipCtor) {\n var objCtor = object.constructor,\n othCtor = other.constructor;\n\n // Non `Object` object instances with different constructors are not equal.\n if (objCtor != othCtor &&\n ('constructor' in object && 'constructor' in other) &&\n !(typeof objCtor == 'function' && objCtor instanceof objCtor &&\n typeof othCtor == 'function' && othCtor instanceof othCtor)) {\n result = false;\n }\n }\n stack['delete'](object);\n stack['delete'](other);\n return result;\n}\n\nmodule.exports = equalObjects;\n","var baseGetAllKeys = require('./_baseGetAllKeys'),\n getSymbols = require('./_getSymbols'),\n keys = require('./keys');\n\n/**\n * Creates an array of own enumerable property names and symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names and symbols.\n */\nfunction getAllKeys(object) {\n return baseGetAllKeys(object, keys, getSymbols);\n}\n\nmodule.exports = getAllKeys;\n","var arrayPush = require('./_arrayPush'),\n isArray = require('./isArray');\n\n/**\n * The base implementation of `getAllKeys` and `getAllKeysIn` which uses\n * `keysFunc` and `symbolsFunc` to get the enumerable property names and\n * symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Function} keysFunc The function to get the keys of `object`.\n * @param {Function} symbolsFunc The function to get the symbols of `object`.\n * @returns {Array} Returns the array of property names and symbols.\n */\nfunction baseGetAllKeys(object, keysFunc, symbolsFunc) {\n var result = keysFunc(object);\n return isArray(object) ? result : arrayPush(result, symbolsFunc(object));\n}\n\nmodule.exports = baseGetAllKeys;\n","/**\n * Appends the elements of `values` to `array`.\n *\n * @private\n * @param {Array} array The array to modify.\n * @param {Array} values The values to append.\n * @returns {Array} Returns `array`.\n */\nfunction arrayPush(array, values) {\n var index = -1,\n length = values.length,\n offset = array.length;\n\n while (++index < length) {\n array[offset + index] = values[index];\n }\n return array;\n}\n\nmodule.exports = arrayPush;\n","var arrayFilter = require('./_arrayFilter'),\n stubArray = require('./stubArray');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Built-in value references. */\nvar propertyIsEnumerable = objectProto.propertyIsEnumerable;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeGetSymbols = Object.getOwnPropertySymbols;\n\n/**\n * Creates an array of the own enumerable symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of symbols.\n */\nvar getSymbols = !nativeGetSymbols ? stubArray : function(object) {\n if (object == null) {\n return [];\n }\n object = Object(object);\n return arrayFilter(nativeGetSymbols(object), function(symbol) {\n return propertyIsEnumerable.call(object, symbol);\n });\n};\n\nmodule.exports = getSymbols;\n","/**\n * A specialized version of `_.filter` for arrays without support for\n * iteratee shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {Array} Returns the new filtered array.\n */\nfunction arrayFilter(array, predicate) {\n var index = -1,\n length = array == null ? 0 : array.length,\n resIndex = 0,\n result = [];\n\n while (++index < length) {\n var value = array[index];\n if (predicate(value, index, array)) {\n result[resIndex++] = value;\n }\n }\n return result;\n}\n\nmodule.exports = arrayFilter;\n","/**\n * This method returns a new empty array.\n *\n * @static\n * @memberOf _\n * @since 4.13.0\n * @category Util\n * @returns {Array} Returns the new empty array.\n * @example\n *\n * var arrays = _.times(2, _.stubArray);\n *\n * console.log(arrays);\n * // => [[], []]\n *\n * console.log(arrays[0] === arrays[1]);\n * // => false\n */\nfunction stubArray() {\n return [];\n}\n\nmodule.exports = stubArray;\n","var DataView = require('./_DataView'),\n Map = require('./_Map'),\n Promise = require('./_Promise'),\n Set = require('./_Set'),\n WeakMap = require('./_WeakMap'),\n baseGetTag = require('./_baseGetTag'),\n toSource = require('./_toSource');\n\n/** `Object#toString` result references. */\nvar mapTag = '[object Map]',\n objectTag = '[object Object]',\n promiseTag = '[object Promise]',\n setTag = '[object Set]',\n weakMapTag = '[object WeakMap]';\n\nvar dataViewTag = '[object DataView]';\n\n/** Used to detect maps, sets, and weakmaps. */\nvar dataViewCtorString = toSource(DataView),\n mapCtorString = toSource(Map),\n promiseCtorString = toSource(Promise),\n setCtorString = toSource(Set),\n weakMapCtorString = toSource(WeakMap);\n\n/**\n * Gets the `toStringTag` of `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\nvar getTag = baseGetTag;\n\n// Fallback for data views, maps, sets, and weak maps in IE 11 and promises in Node.js < 6.\nif ((DataView && getTag(new DataView(new ArrayBuffer(1))) != dataViewTag) ||\n (Map && getTag(new Map) != mapTag) ||\n (Promise && getTag(Promise.resolve()) != promiseTag) ||\n (Set && getTag(new Set) != setTag) ||\n (WeakMap && getTag(new WeakMap) != weakMapTag)) {\n getTag = function(value) {\n var result = baseGetTag(value),\n Ctor = result == objectTag ? value.constructor : undefined,\n ctorString = Ctor ? toSource(Ctor) : '';\n\n if (ctorString) {\n switch (ctorString) {\n case dataViewCtorString: return dataViewTag;\n case mapCtorString: return mapTag;\n case promiseCtorString: return promiseTag;\n case setCtorString: return setTag;\n case weakMapCtorString: return weakMapTag;\n }\n }\n return result;\n };\n}\n\nmodule.exports = getTag;\n","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar DataView = getNative(root, 'DataView');\n\nmodule.exports = DataView;\n","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar Promise = getNative(root, 'Promise');\n\nmodule.exports = Promise;\n","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar Set = getNative(root, 'Set');\n\nmodule.exports = Set;\n","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar WeakMap = getNative(root, 'WeakMap');\n\nmodule.exports = WeakMap;\n","var isStrictComparable = require('./_isStrictComparable'),\n keys = require('./keys');\n\n/**\n * Gets the property names, values, and compare flags of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the match data of `object`.\n */\nfunction getMatchData(object) {\n var result = keys(object),\n length = result.length;\n\n while (length--) {\n var key = result[length],\n value = object[key];\n\n result[length] = [key, value, isStrictComparable(value)];\n }\n return result;\n}\n\nmodule.exports = getMatchData;\n","var baseIsEqual = require('./_baseIsEqual'),\n get = require('./get'),\n hasIn = require('./hasIn'),\n isKey = require('./_isKey'),\n isStrictComparable = require('./_isStrictComparable'),\n matchesStrictComparable = require('./_matchesStrictComparable'),\n toKey = require('./_toKey');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/**\n * The base implementation of `_.matchesProperty` which doesn't clone `srcValue`.\n *\n * @private\n * @param {string} path The path of the property to get.\n * @param {*} srcValue The value to match.\n * @returns {Function} Returns the new spec function.\n */\nfunction baseMatchesProperty(path, srcValue) {\n if (isKey(path) && isStrictComparable(srcValue)) {\n return matchesStrictComparable(toKey(path), srcValue);\n }\n return function(object) {\n var objValue = get(object, path);\n return (objValue === undefined && objValue === srcValue)\n ? hasIn(object, path)\n : baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG);\n };\n}\n\nmodule.exports = baseMatchesProperty;\n","var baseGet = require('./_baseGet');\n\n/**\n * Gets the value at `path` of `object`. If the resolved value is\n * `undefined`, the `defaultValue` is returned in its place.\n *\n * @static\n * @memberOf _\n * @since 3.7.0\n * @category Object\n * @param {Object} object The object to query.\n * @param {Array|string} path The path of the property to get.\n * @param {*} [defaultValue] The value returned for `undefined` resolved values.\n * @returns {*} Returns the resolved value.\n * @example\n *\n * var object = { 'a': [{ 'b': { 'c': 3 } }] };\n *\n * _.get(object, 'a[0].b.c');\n * // => 3\n *\n * _.get(object, ['a', '0', 'b', 'c']);\n * // => 3\n *\n * _.get(object, 'a.b.c', 'default');\n * // => 'default'\n */\nfunction get(object, path, defaultValue) {\n var result = object == null ? undefined : baseGet(object, path);\n return result === undefined ? defaultValue : result;\n}\n\nmodule.exports = get;\n","var baseHasIn = require('./_baseHasIn'),\n hasPath = require('./_hasPath');\n\n/**\n * Checks if `path` is a direct or inherited property of `object`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Object\n * @param {Object} object The object to query.\n * @param {Array|string} path The path to check.\n * @returns {boolean} Returns `true` if `path` exists, else `false`.\n * @example\n *\n * var object = _.create({ 'a': _.create({ 'b': 2 }) });\n *\n * _.hasIn(object, 'a');\n * // => true\n *\n * _.hasIn(object, 'a.b');\n * // => true\n *\n * _.hasIn(object, ['a', 'b']);\n * // => true\n *\n * _.hasIn(object, 'b');\n * // => false\n */\nfunction hasIn(object, path) {\n return object != null && hasPath(object, path, baseHasIn);\n}\n\nmodule.exports = hasIn;\n","/**\n * The base implementation of `_.hasIn` without support for deep paths.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {Array|string} key The key to check.\n * @returns {boolean} Returns `true` if `key` exists, else `false`.\n */\nfunction baseHasIn(object, key) {\n return object != null && key in Object(object);\n}\n\nmodule.exports = baseHasIn;\n","/**\n * This method returns the first argument it receives.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Util\n * @param {*} value Any value.\n * @returns {*} Returns `value`.\n * @example\n *\n * var object = { 'a': 1 };\n *\n * console.log(_.identity(object) === object);\n * // => true\n */\nfunction identity(value) {\n return value;\n}\n\nmodule.exports = identity;\n","var baseProperty = require('./_baseProperty'),\n basePropertyDeep = require('./_basePropertyDeep'),\n isKey = require('./_isKey'),\n toKey = require('./_toKey');\n\n/**\n * Creates a function that returns the value at `path` of a given object.\n *\n * @static\n * @memberOf _\n * @since 2.4.0\n * @category Util\n * @param {Array|string} path The path of the property to get.\n * @returns {Function} Returns the new accessor function.\n * @example\n *\n * var objects = [\n * { 'a': { 'b': 2 } },\n * { 'a': { 'b': 1 } }\n * ];\n *\n * _.map(objects, _.property('a.b'));\n * // => [2, 1]\n *\n * _.map(_.sortBy(objects, _.property(['a', 'b'])), 'a.b');\n * // => [1, 2]\n */\nfunction property(path) {\n return isKey(path) ? baseProperty(toKey(path)) : basePropertyDeep(path);\n}\n\nmodule.exports = property;\n","/**\n * The base implementation of `_.property` without support for deep paths.\n *\n * @private\n * @param {string} key The key of the property to get.\n * @returns {Function} Returns the new accessor function.\n */\nfunction baseProperty(key) {\n return function(object) {\n return object == null ? undefined : object[key];\n };\n}\n\nmodule.exports = baseProperty;\n","var baseGet = require('./_baseGet');\n\n/**\n * A specialized version of `baseProperty` which supports deep paths.\n *\n * @private\n * @param {Array|string} path The path of the property to get.\n * @returns {Function} Returns the new accessor function.\n */\nfunction basePropertyDeep(path) {\n return function(object) {\n return baseGet(object, path);\n };\n}\n\nmodule.exports = basePropertyDeep;\n","/**\n * A specialized version of `_.reduce` for arrays without support for\n * iteratee shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @param {*} [accumulator] The initial value.\n * @param {boolean} [initAccum] Specify using the first element of `array` as\n * the initial value.\n * @returns {*} Returns the accumulated value.\n */\nfunction arrayReduce(array, iteratee, accumulator, initAccum) {\n var index = -1,\n length = array == null ? 0 : array.length;\n\n if (initAccum && length) {\n accumulator = array[++index];\n }\n while (++index < length) {\n accumulator = iteratee(accumulator, array[index], index, array);\n }\n return accumulator;\n}\n\nmodule.exports = arrayReduce;\n","var deburrLetter = require('./_deburrLetter'),\n toString = require('./toString');\n\n/** Used to match Latin Unicode letters (excluding mathematical operators). */\nvar reLatin = /[\\xc0-\\xd6\\xd8-\\xf6\\xf8-\\xff\\u0100-\\u017f]/g;\n\n/** Used to compose unicode character classes. */\nvar rsComboMarksRange = '\\\\u0300-\\\\u036f',\n reComboHalfMarksRange = '\\\\ufe20-\\\\ufe2f',\n rsComboSymbolsRange = '\\\\u20d0-\\\\u20ff',\n rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange;\n\n/** Used to compose unicode capture groups. */\nvar rsCombo = '[' + rsComboRange + ']';\n\n/**\n * Used to match [combining diacritical marks](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks) and\n * [combining diacritical marks for symbols](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks_for_Symbols).\n */\nvar reComboMark = RegExp(rsCombo, 'g');\n\n/**\n * Deburrs `string` by converting\n * [Latin-1 Supplement](https://en.wikipedia.org/wiki/Latin-1_Supplement_(Unicode_block)#Character_table)\n * and [Latin Extended-A](https://en.wikipedia.org/wiki/Latin_Extended-A)\n * letters to basic Latin letters and removing\n * [combining diacritical marks](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks).\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to deburr.\n * @returns {string} Returns the deburred string.\n * @example\n *\n * _.deburr('déjà vu');\n * // => 'deja vu'\n */\nfunction deburr(string) {\n string = toString(string);\n return string && string.replace(reLatin, deburrLetter).replace(reComboMark, '');\n}\n\nmodule.exports = deburr;\n","var basePropertyOf = require('./_basePropertyOf');\n\n/** Used to map Latin Unicode letters to basic Latin letters. */\nvar deburredLetters = {\n // Latin-1 Supplement block.\n '\\xc0': 'A', '\\xc1': 'A', '\\xc2': 'A', '\\xc3': 'A', '\\xc4': 'A', '\\xc5': 'A',\n '\\xe0': 'a', '\\xe1': 'a', '\\xe2': 'a', '\\xe3': 'a', '\\xe4': 'a', '\\xe5': 'a',\n '\\xc7': 'C', '\\xe7': 'c',\n '\\xd0': 'D', '\\xf0': 'd',\n '\\xc8': 'E', '\\xc9': 'E', '\\xca': 'E', '\\xcb': 'E',\n '\\xe8': 'e', '\\xe9': 'e', '\\xea': 'e', '\\xeb': 'e',\n '\\xcc': 'I', '\\xcd': 'I', '\\xce': 'I', '\\xcf': 'I',\n '\\xec': 'i', '\\xed': 'i', '\\xee': 'i', '\\xef': 'i',\n '\\xd1': 'N', '\\xf1': 'n',\n '\\xd2': 'O', '\\xd3': 'O', '\\xd4': 'O', '\\xd5': 'O', '\\xd6': 'O', '\\xd8': 'O',\n '\\xf2': 'o', '\\xf3': 'o', '\\xf4': 'o', '\\xf5': 'o', '\\xf6': 'o', '\\xf8': 'o',\n '\\xd9': 'U', '\\xda': 'U', '\\xdb': 'U', '\\xdc': 'U',\n '\\xf9': 'u', '\\xfa': 'u', '\\xfb': 'u', '\\xfc': 'u',\n '\\xdd': 'Y', '\\xfd': 'y', '\\xff': 'y',\n '\\xc6': 'Ae', '\\xe6': 'ae',\n '\\xde': 'Th', '\\xfe': 'th',\n '\\xdf': 'ss',\n // Latin Extended-A block.\n '\\u0100': 'A', '\\u0102': 'A', '\\u0104': 'A',\n '\\u0101': 'a', '\\u0103': 'a', '\\u0105': 'a',\n '\\u0106': 'C', '\\u0108': 'C', '\\u010a': 'C', '\\u010c': 'C',\n '\\u0107': 'c', '\\u0109': 'c', '\\u010b': 'c', '\\u010d': 'c',\n '\\u010e': 'D', '\\u0110': 'D', '\\u010f': 'd', '\\u0111': 'd',\n '\\u0112': 'E', '\\u0114': 'E', '\\u0116': 'E', '\\u0118': 'E', '\\u011a': 'E',\n '\\u0113': 'e', '\\u0115': 'e', '\\u0117': 'e', '\\u0119': 'e', '\\u011b': 'e',\n '\\u011c': 'G', '\\u011e': 'G', '\\u0120': 'G', '\\u0122': 'G',\n '\\u011d': 'g', '\\u011f': 'g', '\\u0121': 'g', '\\u0123': 'g',\n '\\u0124': 'H', '\\u0126': 'H', '\\u0125': 'h', '\\u0127': 'h',\n '\\u0128': 'I', '\\u012a': 'I', '\\u012c': 'I', '\\u012e': 'I', '\\u0130': 'I',\n '\\u0129': 'i', '\\u012b': 'i', '\\u012d': 'i', '\\u012f': 'i', '\\u0131': 'i',\n '\\u0134': 'J', '\\u0135': 'j',\n '\\u0136': 'K', '\\u0137': 'k', '\\u0138': 'k',\n '\\u0139': 'L', '\\u013b': 'L', '\\u013d': 'L', '\\u013f': 'L', '\\u0141': 'L',\n '\\u013a': 'l', '\\u013c': 'l', '\\u013e': 'l', '\\u0140': 'l', '\\u0142': 'l',\n '\\u0143': 'N', '\\u0145': 'N', '\\u0147': 'N', '\\u014a': 'N',\n '\\u0144': 'n', '\\u0146': 'n', '\\u0148': 'n', '\\u014b': 'n',\n '\\u014c': 'O', '\\u014e': 'O', '\\u0150': 'O',\n '\\u014d': 'o', '\\u014f': 'o', '\\u0151': 'o',\n '\\u0154': 'R', '\\u0156': 'R', '\\u0158': 'R',\n '\\u0155': 'r', '\\u0157': 'r', '\\u0159': 'r',\n '\\u015a': 'S', '\\u015c': 'S', '\\u015e': 'S', '\\u0160': 'S',\n '\\u015b': 's', '\\u015d': 's', '\\u015f': 's', '\\u0161': 's',\n '\\u0162': 'T', '\\u0164': 'T', '\\u0166': 'T',\n '\\u0163': 't', '\\u0165': 't', '\\u0167': 't',\n '\\u0168': 'U', '\\u016a': 'U', '\\u016c': 'U', '\\u016e': 'U', '\\u0170': 'U', '\\u0172': 'U',\n '\\u0169': 'u', '\\u016b': 'u', '\\u016d': 'u', '\\u016f': 'u', '\\u0171': 'u', '\\u0173': 'u',\n '\\u0174': 'W', '\\u0175': 'w',\n '\\u0176': 'Y', '\\u0177': 'y', '\\u0178': 'Y',\n '\\u0179': 'Z', '\\u017b': 'Z', '\\u017d': 'Z',\n '\\u017a': 'z', '\\u017c': 'z', '\\u017e': 'z',\n '\\u0132': 'IJ', '\\u0133': 'ij',\n '\\u0152': 'Oe', '\\u0153': 'oe',\n '\\u0149': \"'n\", '\\u017f': 's'\n};\n\n/**\n * Used by `_.deburr` to convert Latin-1 Supplement and Latin Extended-A\n * letters to basic Latin letters.\n *\n * @private\n * @param {string} letter The matched letter to deburr.\n * @returns {string} Returns the deburred letter.\n */\nvar deburrLetter = basePropertyOf(deburredLetters);\n\nmodule.exports = deburrLetter;\n","/**\n * The base implementation of `_.propertyOf` without support for deep paths.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Function} Returns the new accessor function.\n */\nfunction basePropertyOf(object) {\n return function(key) {\n return object == null ? undefined : object[key];\n };\n}\n\nmodule.exports = basePropertyOf;\n","var asciiWords = require('./_asciiWords'),\n hasUnicodeWord = require('./_hasUnicodeWord'),\n toString = require('./toString'),\n unicodeWords = require('./_unicodeWords');\n\n/**\n * Splits `string` into an array of its words.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to inspect.\n * @param {RegExp|string} [pattern] The pattern to match words.\n * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.\n * @returns {Array} Returns the words of `string`.\n * @example\n *\n * _.words('fred, barney, & pebbles');\n * // => ['fred', 'barney', 'pebbles']\n *\n * _.words('fred, barney, & pebbles', /[^, ]+/g);\n * // => ['fred', 'barney', '&', 'pebbles']\n */\nfunction words(string, pattern, guard) {\n string = toString(string);\n pattern = guard ? undefined : pattern;\n\n if (pattern === undefined) {\n return hasUnicodeWord(string) ? unicodeWords(string) : asciiWords(string);\n }\n return string.match(pattern) || [];\n}\n\nmodule.exports = words;\n","/** Used to match words composed of alphanumeric characters. */\nvar reAsciiWord = /[^\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\x7f]+/g;\n\n/**\n * Splits an ASCII `string` into an array of its words.\n *\n * @private\n * @param {string} The string to inspect.\n * @returns {Array} Returns the words of `string`.\n */\nfunction asciiWords(string) {\n return string.match(reAsciiWord) || [];\n}\n\nmodule.exports = asciiWords;\n","/** Used to detect strings that need a more robust regexp to match words. */\nvar reHasUnicodeWord = /[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;\n\n/**\n * Checks if `string` contains a word composed of Unicode symbols.\n *\n * @private\n * @param {string} string The string to inspect.\n * @returns {boolean} Returns `true` if a word is found, else `false`.\n */\nfunction hasUnicodeWord(string) {\n return reHasUnicodeWord.test(string);\n}\n\nmodule.exports = hasUnicodeWord;\n","/** Used to compose unicode character classes. */\nvar rsAstralRange = '\\\\ud800-\\\\udfff',\n rsComboMarksRange = '\\\\u0300-\\\\u036f',\n reComboHalfMarksRange = '\\\\ufe20-\\\\ufe2f',\n rsComboSymbolsRange = '\\\\u20d0-\\\\u20ff',\n rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange,\n rsDingbatRange = '\\\\u2700-\\\\u27bf',\n rsLowerRange = 'a-z\\\\xdf-\\\\xf6\\\\xf8-\\\\xff',\n rsMathOpRange = '\\\\xac\\\\xb1\\\\xd7\\\\xf7',\n rsNonCharRange = '\\\\x00-\\\\x2f\\\\x3a-\\\\x40\\\\x5b-\\\\x60\\\\x7b-\\\\xbf',\n rsPunctuationRange = '\\\\u2000-\\\\u206f',\n rsSpaceRange = ' \\\\t\\\\x0b\\\\f\\\\xa0\\\\ufeff\\\\n\\\\r\\\\u2028\\\\u2029\\\\u1680\\\\u180e\\\\u2000\\\\u2001\\\\u2002\\\\u2003\\\\u2004\\\\u2005\\\\u2006\\\\u2007\\\\u2008\\\\u2009\\\\u200a\\\\u202f\\\\u205f\\\\u3000',\n rsUpperRange = 'A-Z\\\\xc0-\\\\xd6\\\\xd8-\\\\xde',\n rsVarRange = '\\\\ufe0e\\\\ufe0f',\n rsBreakRange = rsMathOpRange + rsNonCharRange + rsPunctuationRange + rsSpaceRange;\n\n/** Used to compose unicode capture groups. */\nvar rsApos = \"['\\u2019]\",\n rsBreak = '[' + rsBreakRange + ']',\n rsCombo = '[' + rsComboRange + ']',\n rsDigits = '\\\\d+',\n rsDingbat = '[' + rsDingbatRange + ']',\n rsLower = '[' + rsLowerRange + ']',\n rsMisc = '[^' + rsAstralRange + rsBreakRange + rsDigits + rsDingbatRange + rsLowerRange + rsUpperRange + ']',\n rsFitz = '\\\\ud83c[\\\\udffb-\\\\udfff]',\n rsModifier = '(?:' + rsCombo + '|' + rsFitz + ')',\n rsNonAstral = '[^' + rsAstralRange + ']',\n rsRegional = '(?:\\\\ud83c[\\\\udde6-\\\\uddff]){2}',\n rsSurrPair = '[\\\\ud800-\\\\udbff][\\\\udc00-\\\\udfff]',\n rsUpper = '[' + rsUpperRange + ']',\n rsZWJ = '\\\\u200d';\n\n/** Used to compose unicode regexes. */\nvar rsMiscLower = '(?:' + rsLower + '|' + rsMisc + ')',\n rsMiscUpper = '(?:' + rsUpper + '|' + rsMisc + ')',\n rsOptContrLower = '(?:' + rsApos + '(?:d|ll|m|re|s|t|ve))?',\n rsOptContrUpper = '(?:' + rsApos + '(?:D|LL|M|RE|S|T|VE))?',\n reOptMod = rsModifier + '?',\n rsOptVar = '[' + rsVarRange + ']?',\n rsOptJoin = '(?:' + rsZWJ + '(?:' + [rsNonAstral, rsRegional, rsSurrPair].join('|') + ')' + rsOptVar + reOptMod + ')*',\n rsOrdLower = '\\\\d*(?:1st|2nd|3rd|(?![123])\\\\dth)(?=\\\\b|[A-Z_])',\n rsOrdUpper = '\\\\d*(?:1ST|2ND|3RD|(?![123])\\\\dTH)(?=\\\\b|[a-z_])',\n rsSeq = rsOptVar + reOptMod + rsOptJoin,\n rsEmoji = '(?:' + [rsDingbat, rsRegional, rsSurrPair].join('|') + ')' + rsSeq;\n\n/** Used to match complex or compound words. */\nvar reUnicodeWord = RegExp([\n rsUpper + '?' + rsLower + '+' + rsOptContrLower + '(?=' + [rsBreak, rsUpper, '$'].join('|') + ')',\n rsMiscUpper + '+' + rsOptContrUpper + '(?=' + [rsBreak, rsUpper + rsMiscLower, '$'].join('|') + ')',\n rsUpper + '?' + rsMiscLower + '+' + rsOptContrLower,\n rsUpper + '+' + rsOptContrUpper,\n rsOrdUpper,\n rsOrdLower,\n rsDigits,\n rsEmoji\n].join('|'), 'g');\n\n/**\n * Splits a Unicode `string` into an array of its words.\n *\n * @private\n * @param {string} The string to inspect.\n * @returns {Array} Returns the words of `string`.\n */\nfunction unicodeWords(string) {\n return string.match(reUnicodeWord) || [];\n}\n\nmodule.exports = unicodeWords;\n","var toString = require('./toString'),\n upperFirst = require('./upperFirst');\n\n/**\n * Converts the first character of `string` to upper case and the remaining\n * to lower case.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to capitalize.\n * @returns {string} Returns the capitalized string.\n * @example\n *\n * _.capitalize('FRED');\n * // => 'Fred'\n */\nfunction capitalize(string) {\n return upperFirst(toString(string).toLowerCase());\n}\n\nmodule.exports = capitalize;\n","var createCaseFirst = require('./_createCaseFirst');\n\n/**\n * Converts the first character of `string` to upper case.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category String\n * @param {string} [string=''] The string to convert.\n * @returns {string} Returns the converted string.\n * @example\n *\n * _.upperFirst('fred');\n * // => 'Fred'\n *\n * _.upperFirst('FRED');\n * // => 'FRED'\n */\nvar upperFirst = createCaseFirst('toUpperCase');\n\nmodule.exports = upperFirst;\n","var castSlice = require('./_castSlice'),\n hasUnicode = require('./_hasUnicode'),\n stringToArray = require('./_stringToArray'),\n toString = require('./toString');\n\n/**\n * Creates a function like `_.lowerFirst`.\n *\n * @private\n * @param {string} methodName The name of the `String` case method to use.\n * @returns {Function} Returns the new case function.\n */\nfunction createCaseFirst(methodName) {\n return function(string) {\n string = toString(string);\n\n var strSymbols = hasUnicode(string)\n ? stringToArray(string)\n : undefined;\n\n var chr = strSymbols\n ? strSymbols[0]\n : string.charAt(0);\n\n var trailing = strSymbols\n ? castSlice(strSymbols, 1).join('')\n : string.slice(1);\n\n return chr[methodName]() + trailing;\n };\n}\n\nmodule.exports = createCaseFirst;\n","var baseSlice = require('./_baseSlice');\n\n/**\n * Casts `array` to a slice if it's needed.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {number} start The start position.\n * @param {number} [end=array.length] The end position.\n * @returns {Array} Returns the cast slice.\n */\nfunction castSlice(array, start, end) {\n var length = array.length;\n end = end === undefined ? length : end;\n return (!start && end >= length) ? array : baseSlice(array, start, end);\n}\n\nmodule.exports = castSlice;\n","/**\n * The base implementation of `_.slice` without an iteratee call guard.\n *\n * @private\n * @param {Array} array The array to slice.\n * @param {number} [start=0] The start position.\n * @param {number} [end=array.length] The end position.\n * @returns {Array} Returns the slice of `array`.\n */\nfunction baseSlice(array, start, end) {\n var index = -1,\n length = array.length;\n\n if (start < 0) {\n start = -start > length ? 0 : (length + start);\n }\n end = end > length ? length : end;\n if (end < 0) {\n end += length;\n }\n length = start > end ? 0 : ((end - start) >>> 0);\n start >>>= 0;\n\n var result = Array(length);\n while (++index < length) {\n result[index] = array[index + start];\n }\n return result;\n}\n\nmodule.exports = baseSlice;\n","var asciiToArray = require('./_asciiToArray'),\n hasUnicode = require('./_hasUnicode'),\n unicodeToArray = require('./_unicodeToArray');\n\n/**\n * Converts `string` to an array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the converted array.\n */\nfunction stringToArray(string) {\n return hasUnicode(string)\n ? unicodeToArray(string)\n : asciiToArray(string);\n}\n\nmodule.exports = stringToArray;\n","/**\n * Converts an ASCII `string` to an array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the converted array.\n */\nfunction asciiToArray(string) {\n return string.split('');\n}\n\nmodule.exports = asciiToArray;\n","/** Used to compose unicode character classes. */\nvar rsAstralRange = '\\\\ud800-\\\\udfff',\n rsComboMarksRange = '\\\\u0300-\\\\u036f',\n reComboHalfMarksRange = '\\\\ufe20-\\\\ufe2f',\n rsComboSymbolsRange = '\\\\u20d0-\\\\u20ff',\n rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange,\n rsVarRange = '\\\\ufe0e\\\\ufe0f';\n\n/** Used to compose unicode capture groups. */\nvar rsAstral = '[' + rsAstralRange + ']',\n rsCombo = '[' + rsComboRange + ']',\n rsFitz = '\\\\ud83c[\\\\udffb-\\\\udfff]',\n rsModifier = '(?:' + rsCombo + '|' + rsFitz + ')',\n rsNonAstral = '[^' + rsAstralRange + ']',\n rsRegional = '(?:\\\\ud83c[\\\\udde6-\\\\uddff]){2}',\n rsSurrPair = '[\\\\ud800-\\\\udbff][\\\\udc00-\\\\udfff]',\n rsZWJ = '\\\\u200d';\n\n/** Used to compose unicode regexes. */\nvar reOptMod = rsModifier + '?',\n rsOptVar = '[' + rsVarRange + ']?',\n rsOptJoin = '(?:' + rsZWJ + '(?:' + [rsNonAstral, rsRegional, rsSurrPair].join('|') + ')' + rsOptVar + reOptMod + ')*',\n rsSeq = rsOptVar + reOptMod + rsOptJoin,\n rsSymbol = '(?:' + [rsNonAstral + rsCombo + '?', rsCombo, rsRegional, rsSurrPair, rsAstral].join('|') + ')';\n\n/** Used to match [string symbols](https://mathiasbynens.be/notes/javascript-unicode). */\nvar reUnicode = RegExp(rsFitz + '(?=' + rsFitz + ')|' + rsSymbol + rsSeq, 'g');\n\n/**\n * Converts a Unicode `string` to an array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the converted array.\n */\nfunction unicodeToArray(string) {\n return string.match(reUnicode) || [];\n}\n\nmodule.exports = unicodeToArray;\n","import { useVenuesQuery } from '@eventespresso/data';\nimport { useMemoStringify } from '@eventespresso/hooks';\nimport { getCacheIds } from '@eventespresso/predicates';\n\nimport type { Venue, VenueEdge } from '../../types';\nimport { useVenueQueryOptions } from './useVenueQueryOptions';\n\n/**\n * A custom react hook to retrieve all the venues from cache\n */\nexport const useVenues = (): Venue[] => {\n\tconst options = useVenueQueryOptions();\n\n\tconst { data } = useVenuesQuery(options);\n\n\tconst venues = data?.espressoVenues?.nodes || [];\n\n\t// need to make a copy else we can't sort it\n\tconst sortedVenues = [...venues];\n\n\t// create a collator to sort the venues by name using the current locale and natural sort order\n\tconst collator = new Intl.Collator(undefined, { numeric: true, sensitivity: 'base' });\n\tsortedVenues.sort((a, b) => collator.compare(a.name, b.name));\n\n\tconst cacheIds = getCacheIds(sortedVenues);\n\treturn useMemoStringify(sortedVenues, cacheIds);\n};\n","import { useCallback } from 'react';\n\nimport { EntityId, useLazyCacheQuery } from '@eventespresso/data';\n\nimport { GET_DATETIME } from './queries';\nimport type { Datetime, DatetimeItem } from '../../types';\n\ntype Callback = (id: EntityId) => Datetime;\n\nconst useLazyDatetime = (): Callback => {\n\tconst getData = useLazyCacheQuery();\n\n\treturn useCallback(\n\t\t(id) => {\n\t\t\tconst data = getData({\n\t\t\t\tquery: GET_DATETIME,\n\t\t\t\tvariables: {\n\t\t\t\t\tid,\n\t\t\t\t},\n\t\t\t});\n\t\t\treturn data?.espressoDatetime;\n\t\t},\n\t\t[getData]\n\t);\n};\n\nexport default useLazyDatetime;\n","import { useCallback } from 'react';\n\nimport { useLazyCacheQuery, EntityId } from '@eventespresso/data';\n\nimport { GET_TICKET } from './queries';\nimport type { Ticket, TicketItem } from '../../types';\n\ntype GetTicket = (id: EntityId) => Ticket;\n\nconst useLazyTicket = (): GetTicket => {\n\tconst getData = useLazyCacheQuery();\n\n\treturn useCallback(\n\t\t(id) => {\n\t\t\tconst data = getData({\n\t\t\t\tquery: GET_TICKET,\n\t\t\t\tvariables: {\n\t\t\t\t\tid,\n\t\t\t\t},\n\t\t\t});\n\t\t\treturn data?.espressoTicket;\n\t\t},\n\t\t[getData]\n\t);\n};\n\nexport default useLazyTicket;\n","import { useCallback } from 'react';\n\nimport { entitiesWithGuIdInArray } from '@eventespresso/predicates';\nimport { useRelations } from '@eventespresso/services';\nimport useTickets from './useTickets';\nimport type { Ticket } from '../../types';\nimport type { RelatedEntitiesHook } from '../types';\n\nconst useRelatedTickets = (): RelatedEntitiesHook => {\n\tconst tickets = useTickets();\n\tconst { getRelations } = useRelations();\n\n\treturn useCallback(\n\t\t({ entity, entityId }) => {\n\t\t\tconst relatedTicketIds = getRelations({\n\t\t\t\tentity,\n\t\t\t\tentityId,\n\t\t\t\trelation: 'tickets',\n\t\t\t});\n\n\t\t\treturn entitiesWithGuIdInArray(tickets, relatedTicketIds);\n\t\t},\n\t\t[getRelations, tickets]\n\t);\n};\n\nexport default useRelatedTickets;\n","import { gql } from '@eventespresso/data';\n\nexport const VENUE_ATTRIBUTES: any = gql`\n\tfragment venueAttributes on EspressoVenue {\n\t\tid\n\t\taddress\n\t\taddress2\n\t\tcacheId\n\t\tcapacity\n\t\tcity\n\t\tcountryISO\n\t\tcountryName\n\t\tdbId\n\t\tdescription\n\t\tgoogleMapLink\n\t\tname\n\t\tphone\n\t\tshortDescription\n\t\tstateAbbrev\n\t\tstateName\n\t\tthumbnail\n\t\turl\n\t\tzip\n\t}\n`;\n\nexport const GET_VENUE: any = gql`\n\tquery GET_VENUE($id: ID!) {\n\t\tvenue(id: $id) {\n\t\t\t...venueAttributes\n\t\t}\n\t}\n\t${VENUE_ATTRIBUTES}\n`;\n\nexport const GET_VENUES: any = gql`\n\tquery GET_VENUES($where: RootQueryToEspressoVenueConnectionWhereArgs) {\n\t\tespressoVenues(where: $where) {\n\t\t\tnodes {\n\t\t\t\t...venueAttributes\n\t\t\t}\n\t\t}\n\t}\n\t${VENUE_ATTRIBUTES}\n`;\n","import useUpdateEntityList from './useUpdateEntityList';\nimport { PricesList, usePriceQueryOptions } from '../../apollo';\nimport { CacheUpdaterFn, WriteQueryOptions } from '@eventespresso/data';\nimport { useMemo } from 'react';\n\nconst useUpdatePriceList = (\n\twriteQueryOptions: WriteQueryOptions = undefined\n): CacheUpdaterFn => {\n\tconst queryOptions = usePriceQueryOptions();\n\tconst options = useMemo(\n\t\t() => ({\n\t\t\t...queryOptions,\n\t\t\t...writeQueryOptions,\n\t\t}),\n\t\t[queryOptions, writeQueryOptions]\n\t);\n\treturn useUpdateEntityList(options);\n};\n\nexport default useUpdatePriceList;\n","import { useCallback } from 'react';\nimport { assocPath, pathOr } from 'ramda';\nimport type { ExecutionResult } from 'graphql';\n\nimport { EntityId, useApolloClient } from '@eventespresso/data';\nimport { entitiesWithGuIdNotInArray, findEntityByGuid } from '@eventespresso/predicates';\n\nimport type { Ticket, TicketsList } from '../../types';\nimport { useTickets, useTicketQueryOptions, DEFAULT_TICKET_LIST_DATA as DEFAULT_LIST_DATA } from '../../queries';\nimport { useUpdateTicketList } from '../../../hooks';\nimport useBulkDeleteEntities from '../useBulkDeleteEntities';\nimport { cacheNodesFromBulkDelete } from '../';\nimport { SINGULAR_ENTITY_NAME } from '../../../constants';\nimport useOnDeleteTicket from './useOnDeleteTicket';\n\ntype Callback = (args: {\n\tentityIds: Array;\n\tdeletePermanently?: boolean;\n\tdeleteRemotely?: boolean;\n\trelatedDatetimeIds?: Array;\n}) => R;\n\nconst useBulkDeleteTickets = (): Callback> => {\n\tconst allTickets = useTickets();\n\tconst queryOptions = useTicketQueryOptions();\n\tconst updateTicketList = useUpdateTicketList();\n\tconst onDeleteTicket = useOnDeleteTicket();\n\tconst { cache } = useApolloClient();\n\n\tconst bulkDelete = useBulkDeleteEntities({ entityType: 'TICKET', typeName: SINGULAR_ENTITY_NAME.TICKET });\n\n\tconst updateEntityList = useCallback>(\n\t\t({ entityIds, deletePermanently, relatedDatetimeIds }) =>\n\t\t\t() => {\n\t\t\t\t// Read the existing data from cache.\n\t\t\t\tlet data: TicketsList;\n\t\t\t\ttry {\n\t\t\t\t\tdata = cache.readQuery(queryOptions);\n\t\t\t\t} catch (error) {\n\t\t\t\t\tdata = null;\n\t\t\t\t}\n\t\t\t\tconst tickets = data?.espressoTickets || DEFAULT_LIST_DATA;\n\n\t\t\t\tconst findTicket = findEntityByGuid(tickets.nodes);\n\t\t\t\tconst filteredTickets = { ...tickets };\n\t\t\t\tlet ticket: Ticket;\n\t\t\t\t// run onDelete handler for every deleted ticket\n\t\t\t\tfor (const entityId of entityIds) {\n\t\t\t\t\tticket = findTicket(entityId);\n\t\t\t\t\tonDeleteTicket({\n\t\t\t\t\t\tcache,\n\t\t\t\t\t\ttickets: filteredTickets,\n\t\t\t\t\t\tticket,\n\t\t\t\t\t\tdeletePermanently,\n\t\t\t\t\t});\n\t\t\t\t\tfilteredTickets.nodes = entitiesWithGuIdNotInArray(filteredTickets.nodes, [entityId]);\n\t\t\t\t}\n\n\t\t\t\tconst nodes = cacheNodesFromBulkDelete(entityIds, allTickets, deletePermanently);\n\n\t\t\t\tlet options: typeof queryOptions;\n\t\t\t\t// if bulk delete is done as a result of deletion of related date(s)\n\t\t\t\tif (relatedDatetimeIds.length) {\n\t\t\t\t\tconst path = ['variables', 'where', 'datetimeIn'];\n\t\t\t\t\t// this is the current value for datetimeIn\n\t\t\t\t\tconst datetimeIn = pathOr([], path, queryOptions);\n\t\t\t\t\t// remove the related dates from query options\n\t\t\t\t\t// to make sure ticket list is updated\n\t\t\t\t\tconst finalDatetimeIn = datetimeIn.filter((id) => !relatedDatetimeIds.includes(id));\n\t\t\t\t\t// update query options\n\t\t\t\t\toptions = assocPath(path, finalDatetimeIn, queryOptions);\n\t\t\t\t}\n\n\t\t\t\tupdateTicketList({\n\t\t\t\t\t...queryOptions,\n\t\t\t\t\t...options,\n\t\t\t\t\tdata: {\n\t\t\t\t\t\tespressoTickets: {\n\t\t\t\t\t\t\t...tickets,\n\t\t\t\t\t\t\tnodes,\n\t\t\t\t\t\t},\n\t\t\t\t\t},\n\t\t\t\t});\n\t\t\t},\n\t\t[allTickets, cache, onDeleteTicket, queryOptions, updateTicketList]\n\t);\n\n\treturn useCallback(\n\t\tasync ({ entityIds, deletePermanently, deleteRemotely = true, relatedDatetimeIds = [] }) => {\n\t\t\tconst updateTheEntityList = updateEntityList({ entityIds, deletePermanently, relatedDatetimeIds });\n\t\t\t// if we need to send a remote request\n\t\t\tif (deleteRemotely) {\n\t\t\t\treturn await bulkDelete({\n\t\t\t\t\tentityIds,\n\t\t\t\t\tdeletePermanently,\n\t\t\t\t\tupdateEntityList: updateTheEntityList,\n\t\t\t\t});\n\t\t\t}\n\t\t\tupdateTheEntityList();\n\t\t},\n\t\t[bulkDelete, updateEntityList]\n\t);\n};\n\nexport default useBulkDeleteTickets;\n","import { useContext } from 'react';\nimport invariant from 'invariant';\n\nimport { DatesFilterStateContext } from '../../context';\nimport type { DatetimesFilterStateManager } from './types';\n\nconst useDatesListFilterState = (): DatetimesFilterStateManager => {\n\tconst value = useContext(DatesFilterStateContext);\n\n\tinvariant(value, 'useDatesListFilterState must be used inside component');\n\n\treturn value;\n};\n\nexport default useDatesListFilterState;\n","import { EntityId, makeVar, useReactiveVariable, ReactiveVariable } from '@eventespresso/data';\n\ntype DatetimeIds = Array;\n\nconst visibleDatetimeIds = makeVar([]);\n\nexport const useVisibleDatetimeIds = (): ReactiveVariable => {\n\treturn useReactiveVariable(visibleDatetimeIds);\n};\n","import { useContext } from 'react';\nimport invariant from 'invariant';\n\nimport { TicketsFilterStateContext } from '../../context';\nimport type { TicketsFilterStateManager } from './types';\n\nconst useTicketsListFilterState = (): TicketsFilterStateManager => {\n\tconst value = useContext(TicketsFilterStateContext);\n\n\tinvariant(value, 'useTicketsListFilterState must be used inside component');\n\n\treturn value;\n};\nexport default useTicketsListFilterState;\n","import { makeVar, ReactiveVariable, EntityId, useReactiveVariable } from '@eventespresso/data';\n\ntype TicketIds = Array;\n\nconst visibleTicketIds = makeVar([]);\n\nexport const useVisibleTicketIds = (): ReactiveVariable => {\n\treturn useReactiveVariable(visibleTicketIds);\n};\n","import { DatetimesFilterStateReducer } from './types';\n\nconst reducer: DatetimesFilterStateReducer = (state, action) => {\n\tconst { displayStartOrEndDate, sales, status, recurrence, type } = action;\n\tswitch (type) {\n\t\tcase 'SET_DISPLAY_START_OR_END_DATE':\n\t\t\treturn { ...state, displayStartOrEndDate };\n\t\tcase 'SET_SALES':\n\t\t\treturn { ...state, sales };\n\t\tcase 'SET_STATUS':\n\t\t\treturn { ...state, status };\n\t\tcase 'SET_RECURRENCE':\n\t\t\treturn { ...state, recurrence };\n\t\tdefault:\n\t\t\tthrow new Error('Unknown action');\n\t}\n};\n\nexport default reducer;\n","import { useCallback, useMemo } from 'react';\n\nimport { useEntityListFilterStateManager } from '@eventespresso/services';\nimport { DatetimeSales, DatetimeStatus } from '@eventespresso/predicates';\nimport { useSessionStorageReducer } from '@eventespresso/storage';\n\nimport type { DatetimesFilterState, DatetimesFilterStateManager } from './types';\nimport { DisplayStartOrEndDate, SortBy } from '../types';\nimport { datesList } from '../../constants';\nimport reducer from './reducer';\n\ntype FSM = DatetimesFilterStateManager;\ntype DFS = DatetimesFilterState;\n\nconst initialState: DFS = {\n\tdisplayStartOrEndDate: DisplayStartOrEndDate.start,\n\tsales: DatetimeSales.all,\n\tstatus: DatetimeStatus.activeUpcoming,\n\trecurrence: '',\n};\n\ntype ResetPageNumber = (filter: K, value: DFS[K]) => void;\n\nconst useDatesListFilterStateManager = (): FSM => {\n\tconst [state, dispatch] = useSessionStorageReducer('dates-list-filter-state', reducer, initialState);\n\n\tconst entityFilterState = useEntityListFilterStateManager('order', datesList);\n\n\tconst { setPageNumber } = entityFilterState;\n\n\tconst resetPageNumber = useCallback(\n\t\t(filter, value) => {\n\t\t\tif (value !== state[filter]) {\n\t\t\t\tsetPageNumber(1);\n\t\t\t}\n\t\t},\n\t\t[setPageNumber, state]\n\t);\n\n\tconst setDisplayStartOrEndDate: FSM['setDisplayStartOrEndDate'] = useCallback(\n\t\t(displayStartOrEndDate) => {\n\t\t\tdispatch({\n\t\t\t\ttype: 'SET_DISPLAY_START_OR_END_DATE',\n\t\t\t\tdisplayStartOrEndDate,\n\t\t\t});\n\t\t},\n\t\t[dispatch]\n\t);\n\n\tconst setSales: FSM['setSales'] = useCallback(\n\t\t(sales) => {\n\t\t\tresetPageNumber('sales', sales);\n\n\t\t\tdispatch({\n\t\t\t\ttype: 'SET_SALES',\n\t\t\t\tsales,\n\t\t\t});\n\t\t},\n\t\t[dispatch, resetPageNumber]\n\t);\n\n\tconst setStatus: FSM['setStatus'] = useCallback(\n\t\t(status) => {\n\t\t\tresetPageNumber('status', status);\n\n\t\t\tdispatch({\n\t\t\t\ttype: 'SET_STATUS',\n\t\t\t\tstatus,\n\t\t\t});\n\t\t},\n\t\t[dispatch, resetPageNumber]\n\t);\n\n\tconst setRecurrence: FSM['setRecurrence'] = useCallback(\n\t\t(recurrence) => {\n\t\t\tresetPageNumber('recurrence', recurrence);\n\n\t\t\tdispatch({\n\t\t\t\ttype: 'SET_RECURRENCE',\n\t\t\t\trecurrence,\n\t\t\t});\n\t\t},\n\t\t[dispatch, resetPageNumber]\n\t);\n\n\treturn useMemo(\n\t\t() => ({\n\t\t\t...state,\n\t\t\t...entityFilterState,\n\t\t\tsetDisplayStartOrEndDate,\n\t\t\tsetSales,\n\t\t\tsetStatus,\n\t\t\tsetRecurrence,\n\t\t}),\n\t\t[state, entityFilterState, setDisplayStartOrEndDate, setSales, setStatus, setRecurrence]\n\t);\n};\n\nexport default useDatesListFilterStateManager;\n","import { TicketsFilterStateReducer } from './types';\n\nconst reducer: TicketsFilterStateReducer = (state, action) => {\n\tconst { displayStartOrEndDate, sales, status, type } = action;\n\tswitch (type) {\n\t\tcase 'SET_DISPLAY_START_OR_END_DATE':\n\t\t\treturn { ...state, displayStartOrEndDate };\n\t\tcase 'SET_SALES':\n\t\t\treturn { ...state, sales };\n\t\tcase 'SET_STATUS':\n\t\t\treturn { ...state, status };\n\t\tcase 'TOGGLE_IS_CHAINED':\n\t\t\treturn { ...state, isChained: !state.isChained };\n\t\tdefault:\n\t\t\tthrow new Error('Unknown action');\n\t}\n};\n\nexport default reducer;\n","import { useCallback, useEffect, useMemo, useState } from 'react';\n\nimport { DisplayStartOrEndDate, SortBy } from '../types';\nimport { ticketsList } from '../../constants';\nimport { useEntityListFilterStateManager } from '@eventespresso/services';\nimport { useVisibleDatetimeIds } from '../../hooks';\nimport { useSessionStorageReducer } from '@eventespresso/storage';\nimport { TicketsSales, TicketsStatus } from '@eventespresso/predicates';\n\nimport reducer from './reducer';\nimport type { TicketsFilterState, TicketsFilterStateManager } from './types';\n\ntype FSM = TicketsFilterStateManager;\ntype TFS = TicketsFilterState;\n\nconst initialState: TicketsFilterState = {\n\tdisplayStartOrEndDate: DisplayStartOrEndDate.start,\n\tisChained: true,\n\tsales: TicketsSales.all,\n\tstatus: TicketsStatus.onSaleAndPending,\n};\ntype ResetPageNumber = (filter: K, value: TFS[K]) => void;\n\nconst useTicketsListFilterStateManager = (): FSM => {\n\tconst [state, dispatch] = useSessionStorageReducer('ticket-list-filter-state', reducer, initialState);\n\n\tconst [visibleDatesStr, setVisibleDatesStr] = useState('');\n\n\tconst [visibleDatetimeIds] = useVisibleDatetimeIds();\n\n\tconst entityFilterState = useEntityListFilterStateManager('order', ticketsList);\n\n\tconst { setPageNumber } = entityFilterState;\n\n\t// subscribe to visible dates for isChained\n\tuseEffect(() => {\n\t\tif (state.isChained) {\n\t\t\tsetVisibleDatesStr(visibleDatetimeIds.join(':'));\n\t\t}\n\t}, [state.isChained, visibleDatetimeIds]);\n\n\tconst resetPageNumber = useCallback(\n\t\t(filter, value) => {\n\t\t\tif (value !== state[filter]) {\n\t\t\t\tsetPageNumber(1);\n\t\t\t}\n\t\t},\n\t\t[setPageNumber, state]\n\t);\n\n\tconst setDisplayStartOrEndDate: FSM['setDisplayStartOrEndDate'] = useCallback(\n\t\t(displayStartOrEndDate) => {\n\t\t\tdispatch({\n\t\t\t\ttype: 'SET_DISPLAY_START_OR_END_DATE',\n\t\t\t\tdisplayStartOrEndDate,\n\t\t\t});\n\t\t},\n\t\t[dispatch]\n\t);\n\n\tconst setSales: FSM['setSales'] = useCallback(\n\t\t(sales) => {\n\t\t\tresetPageNumber('sales', sales);\n\n\t\t\tdispatch({\n\t\t\t\ttype: 'SET_SALES',\n\t\t\t\tsales,\n\t\t\t});\n\t\t},\n\t\t[dispatch, resetPageNumber]\n\t);\n\n\tconst setStatus: FSM['setStatus'] = useCallback(\n\t\t(status) => {\n\t\t\tresetPageNumber('status', status);\n\t\t\tdispatch({\n\t\t\t\ttype: 'SET_STATUS',\n\t\t\t\tstatus,\n\t\t\t});\n\t\t},\n\t\t[dispatch, resetPageNumber]\n\t);\n\n\tconst toggleIsChained: FSM['toggleIsChained'] = useCallback(() => {\n\t\tdispatch({\n\t\t\ttype: 'TOGGLE_IS_CHAINED',\n\t\t});\n\t}, [dispatch]);\n\n\treturn useMemo(\n\t\t() => ({\n\t\t\t...state,\n\t\t\t...entityFilterState,\n\t\t\tsetDisplayStartOrEndDate,\n\t\t\tsetSales,\n\t\t\tsetStatus,\n\t\t\ttoggleIsChained,\n\t\t\tvisibleDatesStr,\n\t\t}),\n\t\t[entityFilterState, visibleDatesStr, setDisplayStartOrEndDate, setSales, toggleIsChained, state, setStatus]\n\t);\n};\n\nexport default useTicketsListFilterStateManager;\n","import { useCacheQuery } from '@eventespresso/data';\nimport useEventQueryOptions from './useEventQueryOptions';\nimport { useMemoStringify } from '@eventespresso/hooks';\n\nimport type { Event, EventData } from '../../types';\n\nconst useEvent = (): Event => {\n\tconst options = useEventQueryOptions();\n\n\tconst { data } = useCacheQuery(options);\n\n\treturn useMemoStringify(data?.espressoEvent);\n};\n\nexport default useEvent;\n","function _isPlaceholder(a) {\n return a != null && typeof a === 'object' && a['@@functional/placeholder'] === true;\n}\n\nmodule.exports = _isPlaceholder;","var _has =\n/*#__PURE__*/\nrequire(\"./_has\");\n\nvar toString = Object.prototype.toString;\n\nvar _isArguments =\n/*#__PURE__*/\nfunction () {\n return toString.call(arguments) === '[object Arguments]' ? function _isArguments(x) {\n return toString.call(x) === '[object Arguments]';\n } : function _isArguments(x) {\n return _has('callee', x);\n };\n}();\n\nmodule.exports = _isArguments;","import { useMemo } from 'react';\n\nimport useUpdateEntityList from './useUpdateEntityList';\nimport { PriceTypesList, usePriceTypeQueryOptions } from '../../apollo';\nimport { CacheUpdaterFn, WriteQueryOptions } from '@eventespresso/data';\n\nconst useUpdatePriceTypeList = (\n\twriteQueryOptions: WriteQueryOptions = undefined\n): CacheUpdaterFn => {\n\tconst queryOptions = usePriceTypeQueryOptions();\n\tconst options = useMemo(\n\t\t() => ({\n\t\t\t...queryOptions,\n\t\t\t...writeQueryOptions,\n\t\t}),\n\t\t[queryOptions, writeQueryOptions]\n\t);\n\treturn useUpdateEntityList(options);\n};\n\nexport default useUpdatePriceTypeList;\n","import { useMemo } from 'react';\n\nimport useUpdateEntityList from './useUpdateEntityList';\nimport { VenuesList, useVenueQueryOptions } from '../../apollo';\nimport { CacheUpdaterFn, WriteQueryOptions } from '@eventespresso/data';\n\nconst useUpdateVenueList = (\n\twriteQueryOptions: WriteQueryOptions = undefined\n): CacheUpdaterFn => {\n\tconst queryOptions = useVenueQueryOptions();\n\tconst options = useMemo(\n\t\t() => ({\n\t\t\t...queryOptions,\n\t\t\t...writeQueryOptions,\n\t\t}),\n\t\t[queryOptions, writeQueryOptions]\n\t);\n\treturn useUpdateEntityList(options);\n};\n\nexport default useUpdateVenueList;\n","import { useCallback, useMemo } from 'react';\n\nimport { useMutationWithFeedback, MutationType } from '@eventespresso/data';\nimport { useDatetimeQueryOptions, useDatetimes } from '../../queries';\nimport { BulkUpdateDatetimeInput, BULK_UPDATE_DATETIMES } from './';\nimport useOnUpdateDatetime from './useOnUpdateDatetime';\nimport { useUpdateDatetimeList } from '../../../hooks';\nimport { cacheNodesFromBulkInput, updateDatetimeFlags } from '../utils';\nimport type { DatetimeEdge, Datetime } from '../../types';\nimport { SINGULAR_ENTITY_NAME } from '../../../constants';\n\ninterface BulkEditDatetimes {\n\tupdateEntities: (input: BulkUpdateDatetimeInput) => ReturnType>;\n}\n\nconst useBulkEditDatetimes = (): BulkEditDatetimes => {\n\tconst allDatetimes = useDatetimes();\n\tconst queryOptions = useDatetimeQueryOptions();\n\tconst updateDatetimeList = useUpdateDatetimeList();\n\tconst onUpdateDatetime = useOnUpdateDatetime();\n\n\tconst updateDatetimes = useMutationWithFeedback({\n\t\ttypeName: SINGULAR_ENTITY_NAME.DATETIME,\n\t\tmutationType: MutationType.Update,\n\t\tmutation: BULK_UPDATE_DATETIMES,\n\t});\n\n\tconst updateEntityList = useCallback(\n\t\t(input: BulkUpdateDatetimeInput) => () => {\n\t\t\tconst nodes = cacheNodesFromBulkInput(input, allDatetimes).map(updateDatetimeFlags);\n\n\t\t\tconst espressoDatetimes: DatetimeEdge = {\n\t\t\t\tnodes,\n\t\t\t\t__typename: 'EspressoRootQueryDatetimesConnection',\n\t\t\t};\n\t\t\tupdateDatetimeList({\n\t\t\t\t...queryOptions,\n\t\t\t\tdata: {\n\t\t\t\t\tespressoDatetimes,\n\t\t\t\t},\n\t\t\t});\n\t\t\t// update entity relations\n\t\t\tinput.uniqueInputs.forEach(({ tickets, ...updateInput }) => {\n\t\t\t\tonUpdateDatetime({ datetime: updateInput as Datetime, tickets });\n\t\t\t});\n\t\t},\n\t\t[allDatetimes, onUpdateDatetime, queryOptions, updateDatetimeList]\n\t);\n\n\tconst updateEntities = useCallback(\n\t\t(input) => {\n\t\t\tconst variables = {\n\t\t\t\tinput: {\n\t\t\t\t\tclientMutationId: 'BULK_UPDATE_DATETIMES',\n\t\t\t\t\t...input,\n\t\t\t\t},\n\t\t\t};\n\t\t\treturn updateDatetimes({ variables, update: updateEntityList(input) });\n\t\t},\n\t\t[updateDatetimes, updateEntityList]\n\t);\n\n\treturn useMemo(() => ({ updateEntities }), [updateEntities]);\n};\n\nexport default useBulkEditDatetimes;\n","import { useCallback } from 'react';\nimport type { ExecutionResult } from 'graphql';\n\nimport { EntityId, useApolloClient } from '@eventespresso/data';\nimport { entitiesWithGuIdNotInArray, findEntityByGuid } from '@eventespresso/predicates';\n\nimport type { Datetime, DatetimeEdge, DatetimesList } from '../../types';\nimport { useDatetimes, useDatetimeQueryOptions, DEFAULT_DATETIME_LIST_DATA as DEFAULT_LIST_DATA } from '../../queries';\nimport { useUpdateDatetimeList } from '../../../hooks';\nimport useBulkDeleteEntities from '../useBulkDeleteEntities';\nimport { cacheNodesFromBulkDelete } from '../';\nimport useOnDeleteDatetime from './useOnDeleteDatetime';\nimport useDeleteRelatedTickets from './useDeleteRelatedTickets';\nimport { SINGULAR_ENTITY_NAME } from '../../../constants';\n\ntype Callback = (entityIds: Array, deletePermanently?: boolean) => R;\n\nconst useBulkDeleteDatetimes = (): Callback> => {\n\tconst allDatetimes = useDatetimes();\n\tconst queryOptions = useDatetimeQueryOptions();\n\tconst updateDatetimeList = useUpdateDatetimeList();\n\tconst onDeleteDatetime = useOnDeleteDatetime();\n\n\tconst { cache } = useApolloClient();\n\n\tconst bulkDelete = useBulkDeleteEntities({ entityType: 'DATETIME', typeName: SINGULAR_ENTITY_NAME.DATETIME });\n\n\tconst deleteRelatedTickets = useDeleteRelatedTickets();\n\n\tconst updateEntityList = useCallback>(\n\t\t(entityIds, deletePermanently) => async () => {\n\t\t\t// delete related tickets for each date\n\t\t\tfor (const entityId of entityIds) {\n\t\t\t\tawait deleteRelatedTickets(entityId, deletePermanently);\n\t\t\t}\n\n\t\t\t// Read the existing data from cache.\n\t\t\tlet data: DatetimesList;\n\t\t\ttry {\n\t\t\t\tdata = cache.readQuery(queryOptions);\n\t\t\t} catch (error) {\n\t\t\t\tdata = null;\n\t\t\t}\n\t\t\tconst datetimes = data?.espressoDatetimes || DEFAULT_LIST_DATA;\n\n\t\t\tconst findDatetime = findEntityByGuid(datetimes.nodes);\n\t\t\tconst filteredDatetimes = { ...datetimes };\n\t\t\tlet datetime: Datetime;\n\t\t\t// run onDelete handler for every deleted datetime\n\t\t\tfor (const entityId of entityIds) {\n\t\t\t\tdatetime = findDatetime(entityId);\n\t\t\t\tonDeleteDatetime({\n\t\t\t\t\tcache,\n\t\t\t\t\tdatetimes: filteredDatetimes,\n\t\t\t\t\tdatetime,\n\t\t\t\t\tdeletePermanently,\n\t\t\t\t});\n\t\t\t\tfilteredDatetimes.nodes = entitiesWithGuIdNotInArray(filteredDatetimes.nodes, [entityId]);\n\t\t\t}\n\n\t\t\tconst nodes = cacheNodesFromBulkDelete(entityIds, allDatetimes, deletePermanently);\n\n\t\t\tconst espressoDatetimes: DatetimeEdge = {\n\t\t\t\tnodes,\n\t\t\t\t__typename: 'EspressoRootQueryDatetimesConnection',\n\t\t\t};\n\t\t\tupdateDatetimeList({\n\t\t\t\t...queryOptions,\n\t\t\t\tdata: {\n\t\t\t\t\tespressoDatetimes,\n\t\t\t\t},\n\t\t\t});\n\t\t},\n\t\t[allDatetimes, cache, deleteRelatedTickets, onDeleteDatetime, queryOptions, updateDatetimeList]\n\t);\n\n\treturn useCallback(\n\t\tasync (entityIds, deletePermanently) => {\n\t\t\treturn await bulkDelete({\n\t\t\t\tentityIds,\n\t\t\t\tdeletePermanently,\n\t\t\t\tupdateEntityList: updateEntityList(entityIds, deletePermanently),\n\t\t\t});\n\t\t},\n\t\t[bulkDelete, updateEntityList]\n\t);\n};\n\nexport default useBulkDeleteDatetimes;\n","import { useCallback, useMemo, useState } from 'react';\n\nimport { datetimesDroppableId } from '@eventespresso/constants';\n\nimport type { EntityId } from '@eventespresso/data';\nimport type { EntityTableProps } from '@eventespresso/ee-components';\n\nimport { ReorderEntities, useReorderEntities } from '../useReorderEntities';\nimport { useDatetimes, useDatetimeQueryOptions, useLazyDatetime } from '../../queries';\nimport { useUpdateDatetimeList } from '../../../hooks';\nimport { DatetimesFilterStateManager as DFSM } from '../../../filterState';\nimport type { Datetime, DatetimeEdge } from '../../types';\n\ntype SortResponder = EntityTableProps['onSort'];\n\ninterface ReorderDatetimes extends Pick, 'allReorderedEntities' | 'updateEntityList'> {\n\tsortResponder: SortResponder;\n\tupdateEntityList: VoidFunction;\n}\n\nconst useReorderDatetimes = (filteredEntityIds: Array): ReorderDatetimes => {\n\tconst [allUpdatedEntities, setAllUpdatedEntities] = useState>([]);\n\tconst getDatetime = useLazyDatetime();\n\n\tconst datetimes = useMemo(() => filteredEntityIds.map(getDatetime), [filteredEntityIds, getDatetime]);\n\n\tconst { allReorderedEntities, updateSortOrder, sortEntities } = useReorderEntities({\n\t\tentityType: 'DATETIME',\n\t\tfilteredEntities: datetimes,\n\t});\n\tconst allEntities = useDatetimes();\n\n\tconst queryOptions = useDatetimeQueryOptions();\n\tconst updateDatetimeList = useUpdateDatetimeList();\n\n\tconst updateEntityList = useCallback(async () => {\n\t\tconst espressoDatetimes: DatetimeEdge = {\n\t\t\tnodes: allUpdatedEntities,\n\t\t\t__typename: 'EspressoRootQueryDatetimesConnection',\n\t\t};\n\n\t\tawait updateSortOrder();\n\n\t\tupdateDatetimeList({\n\t\t\t...queryOptions,\n\t\t\tdata: {\n\t\t\t\tespressoDatetimes,\n\t\t\t},\n\t\t});\n\t}, [allUpdatedEntities, updateSortOrder, queryOptions, updateDatetimeList]);\n\n\tconst sortResponder = useCallback(\n\t\t({ destination, source }) => {\n\t\t\tconst noDestination = !destination;\n\t\t\tconst noChange = source?.index === destination?.index && destination?.droppableId === source?.droppableId;\n\t\t\tconst notOurListOfInterest = destination?.droppableId !== datetimesDroppableId;\n\n\t\t\tif (noDestination || noChange || notOurListOfInterest) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tconst allSortedEntities = sortEntities({\n\t\t\t\tallEntities,\n\t\t\t\tnewIndex: destination.index,\n\t\t\t\toldIndex: source.index,\n\t\t\t});\n\n\t\t\tsetAllUpdatedEntities(allSortedEntities);\n\t\t},\n\t\t[allEntities, sortEntities]\n\t);\n\n\treturn useMemo(\n\t\t() => ({ allReorderedEntities, sortResponder, updateEntityList }),\n\t\t[allReorderedEntities, sortResponder, updateEntityList]\n\t);\n};\n\nexport default useReorderDatetimes;\n","import { useCallback, useMemo, useState } from 'react';\n\nimport { ticketDroppableId } from '@eventespresso/constants';\nimport type { EntityId } from '@eventespresso/data';\nimport type { EntityTableProps } from '@eventespresso/ee-components';\n\nimport { ReorderEntities, useReorderEntities } from '../useReorderEntities';\nimport { TicketsFilterStateManager as TFSM } from '../../../filterState';\nimport { useTickets, useTicketQueryOptions, useLazyTicket } from '../../queries';\nimport { useUpdateTicketList } from '../../../hooks';\nimport type { Ticket, TicketEdge } from '../../types';\n\ntype SortResponder = EntityTableProps['onSort'];\n\ninterface ReorderTickets extends Pick, 'allReorderedEntities' | 'updateEntityList'> {\n\tsortResponder: SortResponder;\n}\n\nconst useReorderTickets = (filteredEntityIds: Array): ReorderTickets => {\n\tconst [allUpdatedEntities, setAllUpdatedEntities] = useState>([]);\n\tconst getTicket = useLazyTicket();\n\tconst filteredTickets = useMemo(() => filteredEntityIds.map(getTicket), [filteredEntityIds, getTicket]);\n\n\tconst { allReorderedEntities, updateSortOrder, sortEntities } = useReorderEntities({\n\t\tentityType: 'TICKET',\n\t\tfilteredEntities: filteredTickets,\n\t});\n\n\tconst allEntities = useTickets();\n\n\tconst queryOptions = useTicketQueryOptions();\n\tconst updateTicketList = useUpdateTicketList();\n\tconst updateEntityList = useCallback(async () => {\n\t\tconst espressoTickets: TicketEdge = {\n\t\t\tnodes: allUpdatedEntities,\n\t\t\t__typename: 'EspressoRootQueryTicketsConnection',\n\t\t};\n\n\t\tawait updateSortOrder();\n\n\t\tupdateTicketList({\n\t\t\t...queryOptions,\n\t\t\tdata: {\n\t\t\t\tespressoTickets,\n\t\t\t},\n\t\t});\n\t}, [allUpdatedEntities, updateSortOrder, queryOptions, updateTicketList]);\n\n\tconst sortResponder = useCallback(\n\t\t({ destination, source }) => {\n\t\t\tconst noDestination = !destination;\n\t\t\tconst noChange = source?.index === destination?.index && destination?.droppableId === source?.droppableId;\n\t\t\tconst notOurListOfInterest = destination?.droppableId !== ticketDroppableId;\n\n\t\t\tif (noDestination || noChange || notOurListOfInterest) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tconst allSortedEntities = sortEntities({\n\t\t\t\tallEntities,\n\t\t\t\tnewIndex: destination.index,\n\t\t\t\toldIndex: source.index,\n\t\t\t});\n\n\t\t\tsetAllUpdatedEntities(allSortedEntities);\n\t\t},\n\t\t[allEntities, sortEntities]\n\t);\n\n\treturn useMemo(\n\t\t() => ({ allReorderedEntities, sortResponder, updateEntityList }),\n\t\t[allReorderedEntities, sortResponder, updateEntityList]\n\t);\n};\n\nexport default useReorderTickets;\n","import { useCallback, useMemo } from 'react';\n\nimport { parseInfinity, isInfinite } from '@eventespresso/utils';\nimport { entitiesWithGuIdInArray, uniqTicketsByMinQty, ticketQuantityFromCapacity } from '@eventespresso/predicates';\nimport { EntityId } from '@eventespresso/data';\nimport { useSystemNotifications } from '@eventespresso/toaster';\nimport { __ } from '@eventespresso/i18n';\n\nimport { useTickets, useRelatedTickets } from '../../queries';\nimport useBulkEditTickets from './useBulkEditTickets';\n\nimport type { UpdateTicketInput } from './types';\nimport type { Datetime } from '../../types';\n\ntype UpdateTicketQtyByCapacity = {\n\t/**\n\t * Given a datetime and/or `ticketIdsToUpdate`, it generates bulk edit input with updated ticket quantities\n\t */\n\tcreateBulkQtyUpdateInput: (\n\t\tdatetime: Pick,\n\t\tticketIdsToUpdate?: Array\n\t) => Array;\n\t/**\n\t * Given unique inputs of a bulk edit mutation, it performes the actual mutation\n\t * removing the duplicate entries in the input by retaining the tickets with minimum quantity\n\t */\n\tdoQtyBulkUpdate: (uniqInputs: Array, showNotice?: boolean) => Promise;\n};\n\nexport const useUpdateTicketQtyByCapacity = (): UpdateTicketQtyByCapacity => {\n\tconst tickets = useTickets();\n\tconst getRelatedTickets = useRelatedTickets();\n\tconst { updateEntities: bulkEditTickets } = useBulkEditTickets();\n\tconst toaster = useSystemNotifications();\n\n\tconst createBulkQtyUpdateInput = useCallback(\n\t\t(datetime, ticketIdsToUpdate = []) => {\n\t\t\t// If `ticketIdsToUpdate` is passed, we will give preference to it.\n\t\t\t// Otherwise we will try to update the previous related tickets\n\t\t\tconst ticketsToUpdate = ticketIdsToUpdate?.length\n\t\t\t\t? entitiesWithGuIdInArray(tickets, ticketIdsToUpdate)\n\t\t\t\t: getRelatedTickets({ entity: 'datetimes', entityId: datetime.id });\n\n\t\t\tconst capacity = parseInfinity(datetime.capacity, Infinity);\n\n\t\t\tconst getTicketQuantityFromCapacity = ticketQuantityFromCapacity(capacity);\n\n\t\t\tconst uniqueInputs = ticketsToUpdate\n\t\t\t\t.map(({ id, quantity }) => {\n\t\t\t\t\tconst nonNegativeTicketQuantity = parseInfinity(quantity, Infinity);\n\n\t\t\t\t\t// if capacity is infinite or it's more than ticket quantity\n\t\t\t\t\tif (isInfinite(capacity) || capacity >= nonNegativeTicketQuantity) {\n\t\t\t\t\t\t// no need to update the ticket quantity\n\t\t\t\t\t\treturn null;\n\t\t\t\t\t}\n\t\t\t\t\tconst newQuantity = getTicketQuantityFromCapacity(quantity);\n\n\t\t\t\t\treturn { id, quantity: newQuantity };\n\t\t\t\t})\n\t\t\t\t.filter(Boolean);\n\n\t\t\treturn uniqueInputs;\n\t\t},\n\t\t[getRelatedTickets, tickets]\n\t);\n\n\tconst doQtyBulkUpdate = useCallback(\n\t\tasync (uniqInputs, showNotice = true) => {\n\t\t\tif (uniqInputs.length) {\n\t\t\t\t// remove duplicate entries, if any\n\t\t\t\tconst uniqueInputs = uniqTicketsByMinQty(uniqInputs);\n\t\t\t\t// perform the bulk update\n\t\t\t\tawait bulkEditTickets({ uniqueInputs });\n\n\t\t\t\tif (showNotice) {\n\t\t\t\t\ttoaster.info({\n\t\t\t\t\t\tmessage: __(\n\t\t\t\t\t\t\t'Ticket quantity has been adjusted because it cannot be more than the related event date capacity.'\n\t\t\t\t\t\t),\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t}\n\t\t},\n\t\t[bulkEditTickets, toaster]\n\t);\n\n\treturn useMemo(() => ({ createBulkQtyUpdateInput, doQtyBulkUpdate }), [createBulkQtyUpdateInput, doQtyBulkUpdate]);\n};\n","import { useCallback } from 'react';\nimport type { ExecutionResult } from 'graphql';\n\nimport type { EntityId } from '@eventespresso/data';\nimport type { PriceEdge } from '../../types';\nimport { usePrices, usePriceQueryOptions } from '../../queries';\nimport { useUpdatePriceList } from '../../../hooks';\nimport useBulkDeleteEntities from '../useBulkDeleteEntities';\nimport { TypeName, cacheNodesFromBulkDelete } from '../';\n\ntype Callback = (entityIds: Array) => R;\n\nconst useBulkDeletePrices = (): Callback> => {\n\tconst allPrices = usePrices();\n\tconst queryOptions = usePriceQueryOptions();\n\tconst updatePriceList = useUpdatePriceList();\n\n\tconst bulkDelete = useBulkDeleteEntities({ entityType: 'PRICE', typeName: TypeName.Price });\n\n\tconst updateEntityList = useCallback>(\n\t\t(entityIds) => () => {\n\t\t\t// pass true to deletePermanently, because prices are not trashable\n\t\t\tconst nodes = cacheNodesFromBulkDelete(entityIds, allPrices, true);\n\n\t\t\tconst espressoPrices: PriceEdge = {\n\t\t\t\tnodes,\n\t\t\t\t__typename: 'EspressoRootQueryPricesConnection',\n\t\t\t};\n\t\t\tupdatePriceList({\n\t\t\t\t...queryOptions,\n\t\t\t\tdata: {\n\t\t\t\t\tespressoPrices,\n\t\t\t\t},\n\t\t\t});\n\t\t},\n\t\t[allPrices, queryOptions, updatePriceList]\n\t);\n\n\treturn useCallback(\n\t\tasync (entityIds) => {\n\t\t\treturn await bulkDelete({\n\t\t\t\tentityIds,\n\t\t\t\tupdateEntityList: updateEntityList(entityIds),\n\t\t\t});\n\t\t},\n\t\t[bulkDelete, updateEntityList]\n\t);\n};\n\nexport default useBulkDeletePrices;\n","import type {\n\tAddress,\n\tEntity,\n\tEntityId,\n\tEntityEdge,\n\tTrashable,\n\tDatetimesList as DatetimeList,\n\tTicketsList as TicketList,\n\tUser,\n} from '@eventespresso/data';\n\nexport interface Event extends Entity {\n\tallowDonations: boolean;\n\tallowOverflow: boolean;\n\taltRegPage: string;\n\tcreated: string;\n\tdefaultRegStatus: string;\n\tdescription: string;\n\tdisplayDescription: boolean;\n\tdisplayTicketSelector: boolean;\n\tisActive: boolean;\n\tisCancelled: boolean;\n\tisExpired: boolean;\n\tisInactive: boolean;\n\tisPostponed: boolean;\n\tisSoldOut: boolean;\n\tisUpcoming: boolean;\n\tmanager?: EventManager;\n\tmaxRegistrations: number;\n\tmemberOnly: boolean;\n\tname: string;\n\torder: number;\n\tphoneNumber: string;\n\tshortDescription: string;\n\tstatus: string;\n\ttimezoneString: string;\n\tvenue: EntityId; // UUID\n}\n\nexport type EventManager = Pick;\n\nexport interface EventData {\n\tespressoEvent: Event;\n}\n\nexport enum DateStatus {\n\tsoldOut = 'DTS',\n\tactive = 'DTA',\n\tupcoming = 'DTU',\n\tpostponed = 'DTP',\n\tcancelled = 'DTC',\n\texpired = 'DTE',\n\tinactive = 'DTI',\n}\n\nexport interface Datetime extends Entity, Trashable {\n\t__typename: 'EspressoDatetime';\n\tcapacity: number;\n\tdescription: string;\n\tendDate: string;\n\tisActive: boolean;\n\tisExpired: boolean;\n\tisPrimary: boolean;\n\tisSoldOut: boolean;\n\tisUpcoming: boolean;\n\tlength: number;\n\tname: string;\n\torder: number;\n\treserved: number;\n\tsold: number;\n\tstartDate: string;\n\tstatus: DateStatus;\n\tvenue: EntityId; // UUID\n}\n\n// type guard\n// https://www.typescriptlang.org/docs/handbook/2/narrowing.html\nexport const isDatetime = (entity: Entity): entity is Datetime => {\n\treturn entity.__typename === 'EspressoDatetime';\n};\n\nexport interface DatetimeItem {\n\tespressoDatetime: Datetime;\n}\n\nexport type DatetimeEdge = EntityEdge;\n\nexport type DatetimesList = DatetimeList;\n\nexport interface Price extends Entity, Trashable {\n\tamount: number;\n\tdescription: string;\n\tisBasePrice: boolean;\n\tisDefault: boolean;\n\tisDiscount: boolean;\n\tisPercent: boolean;\n\tisTax: boolean;\n\tname: string;\n\torder: number;\n\toverrides: number;\n}\n\nexport type PriceEdge = EntityEdge;\n\nexport interface PricesList {\n\tespressoPrices: PriceEdge;\n}\n\nexport type TicketVisibility = 'ADMINS_ONLY' | 'ADMIN_UI_ONLY' | 'MEMBERS_ONLY' | 'NONE' | 'PUBLIC';\n\nexport interface Ticket extends Entity, Trashable {\n\tdescription: string;\n\tendDate: string; // ISO string\n\tisDefault: boolean;\n\tisExpired: boolean;\n\tisFree: boolean;\n\tisOnSale: boolean;\n\tisPending: boolean;\n\tisRequired: boolean;\n\tisSoldOut: boolean;\n\tmax: number;\n\tmin: number;\n\tname: string;\n\torder: number;\n\tprice: number;\n\tprices?: PriceEdge; // for create and update ticket mutation\n\tquantity: number;\n\tregistrationCount: number;\n\treserved: number;\n\treverseCalculate: boolean;\n\tsold: number;\n\tstartDate: string; // ISO string\n\tuserId: EntityId;\n\tuses: number;\n\tvisibility: TicketVisibility;\n}\n\nexport interface TicketItem {\n\tespressoTicket: Ticket;\n}\n\nexport type TicketEdge = EntityEdge;\n\nexport type TicketsList = TicketList;\n\nexport enum PriceBasetype {\n\tBASE_PRICE = 'BASE_PRICE',\n\tDISCOUNT = 'DISCOUNT',\n\tSURCHARGE = 'SURCHARGE',\n\tTAX = 'TAX',\n}\n\nexport interface PriceType extends Entity, Trashable {\n\tbaseType: PriceBasetype;\n\tisBasePrice: boolean;\n\tisDiscount: boolean;\n\tisPercent: boolean;\n\tisTax: boolean;\n\tname: string;\n\torder: number;\n}\n\nexport type PriceTypeEdge = EntityEdge;\n\nexport interface PriceTypesList {\n\tespressoPriceTypes: PriceTypeEdge;\n}\n\nexport interface Venue extends Entity, Address {\n\tcapacity: number;\n\tdescription: string;\n\tgoogleMapLink: string;\n\tname: string;\n\tphone: string;\n\tshortDescription: string;\n\tthumbnail: string;\n\turl: string;\n}\n\nexport type VenueEdge = EntityEdge;\n\nexport interface VenuesList {\n\tespressoVenues: VenueEdge;\n}\n","export { default as useDatesListFilterState } from './useDatesListFilterState';\n\nexport { default as useFilteredDateIds } from './useFilteredDateIds';\n\nexport { default as useDatesListFilterStateManager } from './useDatesListFilterStateManager';\n\nexport * from './types';\n","import { useContext } from 'react';\nimport invariant from 'invariant';\n\nimport type { EntityId } from '@eventespresso/data';\nimport { FilteredDatesContext } from '../../context';\n\nconst useFilteredDateIds = (): Array => {\n\tconst value = useContext(FilteredDatesContext);\n\n\tinvariant(value, 'useFilteredDateIds must be used inside component');\n\n\treturn value;\n};\nexport default useFilteredDateIds;\n","export { default as useTicketsListFilterState } from './useTicketsListFilterState';\n\nexport { default as useFilteredTicketIds } from './useFilteredTicketIds';\n\nexport { default as useRegisterIsChainedFilter } from './useRegisterIsChainedFilter';\n\nexport { default as useTicketsListFilterStateManager } from './useTicketsListFilterStateManager';\n\nexport * from './types';\n","import { useContext } from 'react';\nimport invariant from 'invariant';\n\nimport type { EntityId } from '@eventespresso/data';\n\nimport { FilteredTicketsContext } from '../../context';\n\nconst useFilteredTicketIds = (): Array => {\n\tconst value = useContext(FilteredTicketsContext);\n\n\tinvariant(value, 'useFilteredTicketIds must be used inside component');\n\n\treturn value;\n};\n\nexport default useFilteredTicketIds;\n","export * from './types';\n","import type { OptionsType } from '@eventespresso/adapters';\nimport type { User } from '@eventespresso/data';\nimport type { GeneralSettings, RelationalData } from '@eventespresso/services';\nimport type { FormSectionRaw, FormElementRaw } from '@eventespresso/form-builder';\nimport type { DatetimeEdge, TicketEdge, PriceEdge, PriceTypeEdge, Event, EventManager, VenueEdge } from './apollo';\n\nexport type TicketMeta = {\n\tvisibilityOptions: OptionsType;\n};\n\nexport type EdtrFormBuilderData = {\n\tsections: Array;\n\telements: Array;\n\ttopLevelSectionId?: string;\n};\n\nexport interface EventEditorData {\n\tdatetimes?: DatetimeEdge;\n\tevent?: Event;\n\teventManagers?: Array;\n\tformBuilder?: EdtrFormBuilderData;\n\tpriceTypes?: PriceTypeEdge;\n\tprices?: PriceEdge;\n\trelations?: RelationalData;\n\tticketMeta?: TicketMeta;\n\ttickets?: TicketEdge;\n\tvenues?: VenueEdge;\n}\n\nexport interface EditorData {\n\teventEditor: EventEditorData;\n\tcurrentUser?: User;\n\tgeneralSettings?: GeneralSettings;\n}\n\nexport interface EventEditorDomData {\n\teventEditor: EventEditorData;\n}\n\nexport enum EdtrGlobalModals {\n\tDEFAULT_TICKETS = 'defaultTickets',\n\tEDIT_DATE = 'editDate',\n\tEDIT_TICKET = 'editTicket',\n\tNEW_DATE = 'newDate',\n\tTAM = 'tam',\n\tTPC = 'tpc',\n}\n\nexport enum QueryURLRegStatus {\n\tAPPROVED = 'RAP',\n\tPENDING = 'RPP',\n\tWAITLIST = 'RWL',\n\tINCOMPLETE = 'RIC',\n\tNOT_APPROVED = 'RNA',\n\tDECLINED = 'RDC',\n\tCANCELLED = 'RCN',\n}\n","import { useCallback } from 'react';\n\nimport type { MutationType, MutationInput, OperationVariables } from '@eventespresso/data';\n\ntype MutationVariablesCb = (mutationType: MutationType, input: MutationInput) => OperationVariables;\n\nconst useMutationVariables = (): MutationVariablesCb => {\n\treturn useCallback((mutationType, input) => {\n\t\tconst mutationInput: MutationInput = {\n\t\t\tclientMutationId: `${mutationType}_PRICE`,\n\t\t\t...input,\n\t\t};\n\n\t\treturn {\n\t\t\tinput: mutationInput,\n\t\t};\n\t}, []);\n};\n\nexport default useMutationVariables;\n","import { useCallback } from 'react';\nimport { findIndex, update } from 'ramda';\n\nimport type { CacheUpdaterFn, CacheUpdaterFnArgs } from '../types';\nimport { Price, PricesList } from '../../';\nimport { WriteQueryOptions } from '@eventespresso/data';\nimport { entityHasGuid } from '@eventespresso/predicates';\nimport { usePriceQueryOptions } from '../../queries';\n\nconst useUpdatePriceCache = (): CacheUpdaterFn => {\n\tconst queryOptions = usePriceQueryOptions();\n\n\tconst updatePriceCache = useCallback(\n\t\t({ cache, prices, price, action }: CacheUpdaterFnArgs): void => {\n\t\t\tconst { nodes = [] } = prices;\n\t\t\tlet newNodes: Array = [],\n\t\t\t\tpriceIndex: number;\n\t\t\tswitch (action) {\n\t\t\t\tcase 'add':\n\t\t\t\t\tnewNodes = [...nodes, price];\n\t\t\t\t\tbreak;\n\t\t\t\tcase 'update':\n\t\t\t\t\t// find the index of the price to update\n\t\t\t\t\tpriceIndex = findIndex(entityHasGuid(price.id), nodes);\n\t\t\t\t\t// if price exists\n\t\t\t\t\tif (priceIndex >= 0) {\n\t\t\t\t\t\tnewNodes = update(priceIndex, price, nodes);\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase 'remove':\n\t\t\t\t\tnewNodes = nodes.filter(({ id }) => id !== price.id);\n\t\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t\tnewNodes = nodes;\n\t\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\t// write the data to cache without\n\t\t\t// mutating the cache directly\n\t\t\tconst writeOptions: WriteQueryOptions = {\n\t\t\t\t...queryOptions,\n\t\t\t\tdata: {\n\t\t\t\t\tespressoPrices: {\n\t\t\t\t\t\t...prices,\n\t\t\t\t\t\tnodes: newNodes,\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t};\n\t\t\tcache.writeQuery(writeOptions);\n\t\t},\n\t\t[queryOptions]\n\t);\n\n\treturn updatePriceCache;\n};\n\nexport default useUpdatePriceCache;\n","import { useCallback } from 'react';\n\nimport useUpdatePriceCache from './useUpdatePriceCache';\nimport type { PriceMutationCallbackFn, PriceMutationCallbackFnArgs } from '../types';\nimport { useRelations } from '@eventespresso/services';\n\nconst useOnCreatePrice = (): PriceMutationCallbackFn => {\n\tconst { updateRelations } = useRelations();\n\n\tconst updatePriceCache = useUpdatePriceCache();\n\n\tconst onCreatePrice = useCallback(\n\t\t({ cache, price, prices, priceTypeId }: PriceMutationCallbackFnArgs): void => {\n\t\t\tconst { id: priceId } = price;\n\t\t\tif (priceId && priceTypeId) {\n\t\t\t\tupdateRelations({\n\t\t\t\t\tentity: 'prices',\n\t\t\t\t\tentityId: priceId,\n\t\t\t\t\trelation: 'priceTypes',\n\t\t\t\t\trelationIds: [priceTypeId],\n\t\t\t\t});\n\t\t\t}\n\t\t\t// Update price cache.\n\t\t\tupdatePriceCache({ cache, prices, price, action: 'add' });\n\t\t},\n\t\t[updatePriceCache, updateRelations]\n\t);\n\n\treturn onCreatePrice;\n};\n\nexport default useOnCreatePrice;\n","import { useCallback } from 'react';\n\nimport useUpdatePriceCache from './useUpdatePriceCache';\nimport type { PriceMutationCallbackFn, PriceMutationCallbackFnArgs } from '../types';\nimport { useRelations } from '@eventespresso/services';\n\nconst useOnDeletePrice = (): PriceMutationCallbackFn => {\n\tconst { dropRelations, removeRelation } = useRelations();\n\n\tconst updatePriceCache = useUpdatePriceCache();\n\n\tconst onDeletePrice = useCallback(\n\t\t({ cache, prices, price, deletePermanently }: PriceMutationCallbackFnArgs): void => {\n\t\t\tconst { id: priceId } = price;\n\t\t\tconst action = deletePermanently ? 'remove' : 'update';\n\t\t\tif (priceId && deletePermanently) {\n\t\t\t\t// Remove the price from all tickets relations\n\t\t\t\tremoveRelation({\n\t\t\t\t\tentity: 'prices',\n\t\t\t\t\tentityId: priceId,\n\t\t\t\t\trelation: 'tickets',\n\t\t\t\t});\n\t\t\t\t// Drop all the relations for the price\n\t\t\t\tdropRelations({\n\t\t\t\t\tentity: 'prices',\n\t\t\t\t\tentityId: priceId,\n\t\t\t\t});\n\t\t\t}\n\t\t\t// Update price cache.\n\t\t\tupdatePriceCache({ cache, prices, price: { ...price, isTrashed: true }, action });\n\t\t},\n\t\t[dropRelations, removeRelation, updatePriceCache]\n\t);\n\n\treturn onDeletePrice;\n};\n\nexport default useOnDeletePrice;\n","import { useCallback } from 'react';\n\nimport type { PriceMutationCallbackFn, PriceMutationCallbackFnArgs } from '../types';\nimport { useRelations } from '@eventespresso/services';\n\nconst useOnUpdatePrice = (): PriceMutationCallbackFn => {\n\tconst { updateRelations } = useRelations();\n\n\tconst onUpdatePrice = useCallback(\n\t\t({ price, priceTypeId }: PriceMutationCallbackFnArgs): void => {\n\t\t\tconst { id: priceId } = price;\n\t\t\t// if it's not the optimistic response\n\t\t\t// and priceType has been updated.\n\t\t\tif (priceId && priceTypeId) {\n\t\t\t\t// Make sure to update the priceType relation\n\t\t\t\tupdateRelations({\n\t\t\t\t\tentity: 'prices',\n\t\t\t\t\tentityId: priceId,\n\t\t\t\t\trelation: 'priceTypes',\n\t\t\t\t\trelationIds: [priceTypeId],\n\t\t\t\t});\n\t\t\t}\n\t\t},\n\t\t[updateRelations]\n\t);\n\n\treturn onUpdatePrice;\n};\n\nexport default useOnUpdatePrice;\n","import type { KeysOfType } from '@eventespresso/utils';\nimport { PriceBaseInput } from './types';\n\nexport const NUMERIC_FIELDS: Array> = ['amount', 'order', 'overrides', 'wpUser'];\n\nexport const BOOLEAN_FIELDS: Array> = ['isDefault', 'isTrashed'];\n","import { useCallback } from 'react';\n\nimport { MutationType } from '@eventespresso/data';\nimport { normalizeNumericFields, normalizeBooleanFields, removeNullAndUndefined } from '@eventespresso/utils';\n\nimport useMutationVariables from './useMutationVariables';\nimport useOnCreatePrice from './useOnCreatePrice';\nimport useOnDeletePrice from './useOnDeletePrice';\nimport useOnUpdatePrice from './useOnUpdatePrice';\nimport type { MutationHandler, MutationUpdater } from '../types';\nimport { PricesList, Price } from '../../';\nimport { DEFAULT_PRICE_LIST_DATA as DEFAULT_LIST_DATA, usePriceQueryOptions } from '../../queries';\nimport type { PriceCommonInput } from './types';\nimport { BOOLEAN_FIELDS, NUMERIC_FIELDS } from './constants';\n\ntype MH = MutationHandler;\n\nconst useMutationHandler = (): MH => {\n\tconst options = usePriceQueryOptions();\n\n\tconst onCreatePrice = useOnCreatePrice();\n\tconst onUpdatePrice = useOnUpdatePrice();\n\tconst onDeletePrice = useOnDeletePrice();\n\tconst getMutationVariables = useMutationVariables();\n\n\tconst onUpdate = useCallback>(\n\t\t({ cache, entity: price, input, mutationType }) => {\n\t\t\tconst priceTypeId = input?.priceType;\n\t\t\t// Read the existing data from cache.\n\t\t\tlet data: PricesList;\n\t\t\ttry {\n\t\t\t\tdata = cache.readQuery(options);\n\t\t\t} catch (error) {\n\t\t\t\tdata = null;\n\t\t\t}\n\t\t\tconst prices = data?.espressoPrices || DEFAULT_LIST_DATA;\n\n\t\t\tswitch (mutationType) {\n\t\t\t\tcase MutationType.Create:\n\t\t\t\t\tonCreatePrice({ cache, prices, price, priceTypeId });\n\t\t\t\t\tbreak;\n\t\t\t\tcase MutationType.Update:\n\t\t\t\t\tonUpdatePrice({ price, priceTypeId });\n\t\t\t\t\tbreak;\n\t\t\t\tcase MutationType.Delete:\n\t\t\t\t\tonDeletePrice({ cache, prices, price, deletePermanently: input?.deletePermanently });\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t},\n\t\t[onCreatePrice, onDeletePrice, onUpdatePrice, options]\n\t);\n\n\tconst mutator = useCallback(\n\t\t(mutationType, input) => {\n\t\t\t// Get rid of null or undefined values\n\t\t\tconst filteredInput = removeNullAndUndefined(input);\n\t\t\tlet normalizedInput = normalizeNumericFields(NUMERIC_FIELDS, filteredInput);\n\t\t\t// normalize boolean fields\n\t\t\tnormalizedInput = normalizeBooleanFields(BOOLEAN_FIELDS, normalizedInput);\n\n\t\t\tconst variables = getMutationVariables(mutationType, normalizedInput);\n\n\t\t\treturn { variables, onUpdate };\n\t\t},\n\t\t[getMutationVariables, onUpdate]\n\t);\n\n\treturn mutator;\n};\n\nexport default useMutationHandler;\n","import { useCallback, useMemo } from 'react';\n\nimport { MutationType, MutationFunction, useMutationWithFeedback } from '@eventespresso/data';\n\nimport { TypeName } from '../types';\nimport { CREATE_PRICE, UPDATE_PRICE, DELETE_PRICE } from './';\nimport useMutationHandler from './useMutationHandler';\nimport useUpdateCallback from '../useUpdateCallback';\nimport type { CreatePriceInput, UpdatePriceInput, DeletePriceInput } from './types';\nimport type { CreatePriceResult, UpdatePriceResult, DeletePriceResult } from './types';\nimport { SINGULAR_ENTITY_NAME } from '../../../constants';\n\ninterface PriceMutator {\n\tcreateEntity: MutationFunction;\n\tupdateEntity: MutationFunction;\n\tdeleteEntity: MutationFunction;\n}\n\ntype PM = PriceMutator;\n\nconst usePriceMutator = (id = ''): PM => {\n\tconst createPrice = useMutationWithFeedback({\n\t\ttypeName: SINGULAR_ENTITY_NAME.PRICE,\n\t\tmutationType: MutationType.Create,\n\t\tmutation: CREATE_PRICE,\n\t});\n\n\tconst updatePrice = useMutationWithFeedback({\n\t\ttypeName: SINGULAR_ENTITY_NAME.PRICE,\n\t\tmutationType: MutationType.Update,\n\t\tmutation: UPDATE_PRICE,\n\t});\n\n\tconst deletePrice = useMutationWithFeedback({\n\t\ttypeName: SINGULAR_ENTITY_NAME.PRICE,\n\t\tmutationType: MutationType.Delete,\n\t\tmutation: DELETE_PRICE,\n\t});\n\n\tconst mutationHandler = useMutationHandler();\n\n\tconst getUpdateCallback = useUpdateCallback(TypeName.Price);\n\n\tconst createEntity = useCallback(\n\t\t(input) => {\n\t\t\tconst { onUpdate, ...options } = mutationHandler(MutationType.Create, input);\n\n\t\t\tconst update = getUpdateCallback({ onUpdate, mutationType: MutationType.Create, input });\n\n\t\t\treturn createPrice({ ...options, update });\n\t\t},\n\t\t[createPrice, getUpdateCallback, mutationHandler]\n\t);\n\n\tconst updateEntity = useCallback(\n\t\t(input) => {\n\t\t\tconst { onUpdate, ...options } = mutationHandler(MutationType.Update, { id, ...input });\n\n\t\t\tconst update = getUpdateCallback({ onUpdate, mutationType: MutationType.Update, input });\n\n\t\t\treturn updatePrice({ ...options, update });\n\t\t},\n\t\t[getUpdateCallback, id, mutationHandler, updatePrice]\n\t);\n\n\tconst deleteEntity = useCallback(\n\t\t(input) => {\n\t\t\tconst { onUpdate, ...options } = mutationHandler(MutationType.Delete, { id, ...input });\n\n\t\t\tconst update = getUpdateCallback({ onUpdate, mutationType: MutationType.Delete, input });\n\n\t\t\treturn deletePrice({ ...options, update });\n\t\t},\n\t\t[deletePrice, getUpdateCallback, id, mutationHandler]\n\t);\n\treturn useMemo(() => ({ createEntity, updateEntity, deleteEntity }), [createEntity, deleteEntity, updateEntity]);\n};\n\nexport default usePriceMutator;\n","import { useCallback } from 'react';\n\nimport type { MutationType, MutationInput, OperationVariables } from '@eventespresso/data';\n\nimport { useEventId } from '../../queries/events';\n\ntype MutationVariablesCb = (mutationType: MutationType, input: MutationInput) => OperationVariables;\n\nconst useMutationVariables = (): MutationVariablesCb => {\n\tconst eventId = useEventId();\n\n\treturn useCallback(\n\t\t(mutationType, input) => {\n\t\t\tconst mutationInput: MutationInput = {\n\t\t\t\tclientMutationId: `${mutationType}_DATETIME`,\n\t\t\t\t...input,\n\t\t\t};\n\n\t\t\tif (mutationType === 'CREATE') {\n\t\t\t\tmutationInput.eventId = eventId; // required for createDatetime\n\t\t\t}\n\n\t\t\treturn {\n\t\t\t\tinput: mutationInput,\n\t\t\t};\n\t\t},\n\t\t[eventId]\n\t);\n};\n\nexport default useMutationVariables;\n","import { useCallback } from 'react';\n\nimport updateTicketCache from './updateTicketCache';\nimport useUpdateDatetimeCache from './useUpdateDatetimeCache';\nimport type { DatetimeMutationCallbackFn, DatetimeMutationCallbackFnArgs } from '../types';\nimport { useRelations } from '@eventespresso/services';\nimport { getGuids, hasTempId } from '@eventespresso/predicates';\n\nconst useOnCreateDatetime = (): DatetimeMutationCallbackFn => {\n\tconst { updateRelations, addRelation } = useRelations();\n\n\tconst updateDatetimeCache = useUpdateDatetimeCache();\n\n\tconst onCreateDatetime = useCallback(\n\t\t({ cache, datetimes, datetime, tickets }: DatetimeMutationCallbackFnArgs): void => {\n\t\t\tif (!hasTempId(datetime)) {\n\t\t\t\tconst { nodes = [] } = datetimes;\n\t\t\t\tconst datetimeIn = getGuids(nodes).sort();\n\t\t\t\tconst { id: datetimeId } = datetime;\n\n\t\t\t\t// Update tickets cache for the changed datetimes,\n\t\t\t\t// to avoid refetching of tickets.\n\t\t\t\tupdateTicketCache({ cache, datetimeIn, datetimeId, action: 'add' });\n\n\t\t\t\t// if we have related tickets\n\t\t\t\tif (tickets?.length) {\n\t\t\t\t\tupdateRelations({\n\t\t\t\t\t\tentity: 'datetimes',\n\t\t\t\t\t\tentityId: datetimeId,\n\t\t\t\t\t\trelation: 'tickets',\n\t\t\t\t\t\trelationIds: tickets,\n\t\t\t\t\t});\n\t\t\t\t\ttickets.forEach((entityId: string) => {\n\t\t\t\t\t\taddRelation({\n\t\t\t\t\t\t\tentity: 'tickets',\n\t\t\t\t\t\t\tentityId,\n\t\t\t\t\t\t\trelation: 'datetimes',\n\t\t\t\t\t\t\trelationId: datetimeId,\n\t\t\t\t\t\t});\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t}\n\t\t\t// Update datetime cache after tickets cache is updated.\n\t\t\tupdateDatetimeCache({ cache, datetimes, datetime, action: 'add' });\n\t\t},\n\t\t[addRelation, updateDatetimeCache, updateRelations]\n\t);\n\n\treturn onCreateDatetime;\n};\n\nexport default useOnCreateDatetime;\n","import { useCallback } from 'react';\n\nimport { MutationType, MutationInput } from '@eventespresso/data';\nimport { PLUS_ONE_MONTH, PLUS_TWO_MONTHS } from '@eventespresso/constants';\nimport { ucFirst, uuid } from '@eventespresso/utils';\nimport type { Datetime } from '../../types';\nimport { useLazyDatetime } from '../../queries';\n\nexport const DATETIME_DEFAULTS: Datetime = {\n\t__typename: 'EspressoDatetime',\n\tid: '',\n\tdbId: 0,\n\tcacheId: '',\n\tcapacity: -1,\n\tdescription: '',\n\tendDate: PLUS_TWO_MONTHS.toISOString(),\n\tisActive: false,\n\tisExpired: false,\n\tisPrimary: false,\n\tisSoldOut: false,\n\tisTrashed: false,\n\tisUpcoming: false,\n\tlength: 0,\n\tname: '',\n\torder: 0,\n\treserved: 0,\n\tsold: 0,\n\tstartDate: PLUS_ONE_MONTH.toISOString(),\n\tstatus: null,\n\tvenue: '',\n};\n\ntype OptimisticResCb = (mutationType: MutationType, input: MutationInput) => any;\n\nconst useOptimisticResponse = (): OptimisticResCb => {\n\tconst getDatetime = useLazyDatetime();\n\n\treturn useCallback(\n\t\t(mutationType, input) => {\n\t\t\tlet espressoDatetime: Partial = {\n\t\t\t\t__typename: 'EspressoDatetime',\n\t\t\t};\n\n\t\t\tconst datetime = getDatetime(input.id);\n\t\t\tconst cacheId = `temp:${uuid()}`;\n\n\t\t\tswitch (mutationType) {\n\t\t\t\tcase MutationType.Create:\n\t\t\t\t\tespressoDatetime = {\n\t\t\t\t\t\t...espressoDatetime,\n\t\t\t\t\t\t...DATETIME_DEFAULTS,\n\t\t\t\t\t\tcacheId,\n\t\t\t\t\t\t// make sure the id is generated on each call to make sure\n\t\t\t\t\t\t// it is unique for each entity created in bulk\n\t\t\t\t\t\tid: cacheId,\n\t\t\t\t\t\t...input,\n\t\t\t\t\t};\n\t\t\t\t\tbreak;\n\t\t\t\tcase MutationType.Delete:\n\t\t\t\t\tespressoDatetime = {\n\t\t\t\t\t\t...espressoDatetime,\n\t\t\t\t\t\t...DATETIME_DEFAULTS, // to avoid pollution of test console\n\t\t\t\t\t\t...datetime,\n\t\t\t\t\t\t...input,\n\t\t\t\t\t\tisTrashed: true,\n\t\t\t\t\t\tcacheId,\n\t\t\t\t\t};\n\t\t\t\t\tbreak;\n\t\t\t\tcase MutationType.Update:\n\t\t\t\t\tespressoDatetime = {\n\t\t\t\t\t\t...espressoDatetime,\n\t\t\t\t\t\t...datetime,\n\t\t\t\t\t\t...input,\n\t\t\t\t\t\tcacheId,\n\t\t\t\t\t};\n\t\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tconst lcMutationtype = mutationType.toLowerCase();\n\t\t\tconst ucFirstMutationtype = ucFirst(lcMutationtype);\n\n\t\t\t// e.g. \"deleteEspressoDatetime\", \"createEspressoDatetime\"\n\t\t\tconst mutation = `${lcMutationtype}EspressoDatetime`;\n\n\t\t\treturn {\n\t\t\t\t__typename: 'RootMutation',\n\t\t\t\t[mutation]: {\n\t\t\t\t\t__typename: `${ucFirstMutationtype}EspressoDatetimePayload`,\n\t\t\t\t\tespressoDatetime,\n\t\t\t\t},\n\t\t\t};\n\t\t},\n\t\t[getDatetime]\n\t);\n};\n\nexport default useOptimisticResponse;\n","import type { KeysOfType } from '@eventespresso/utils';\nimport type { DatetimeBaseInput } from './types';\n\nexport const NUMERIC_FIELDS: Array> = [\n\t'capacity',\n\t'eventId',\n\t'order',\n\t'reserved',\n\t'sold',\n];\n","import { useCallback } from 'react';\n\nimport { normalizeNumericFields, removeNullAndUndefined } from '@eventespresso/utils';\nimport { MutationType } from '@eventespresso/data';\n\nimport useMutationVariables from './useMutationVariables';\nimport useOnCreateDatetime from './useOnCreateDatetime';\nimport useOnDeleteDatetime from './useOnDeleteDatetime';\nimport useOnUpdateDatetime from './useOnUpdateDatetime';\nimport useOptimisticResponse from './useOptimisticResponse';\nimport { DEFAULT_DATETIME_LIST_DATA as DEFAULT_LIST_DATA } from '../../queries';\nimport type { DatetimesList, Datetime } from '../../types';\nimport type { MutationHandler, MutationUpdater } from '../types';\nimport { useDatetimeQueryOptions } from '../../queries/datetimes';\nimport type { DatetimeCommonInput } from './types';\nimport { NUMERIC_FIELDS } from './constants';\n\ntype MH = MutationHandler;\n\nconst useMutationHandler = (): MH => {\n\tconst options = useDatetimeQueryOptions();\n\n\tconst onCreateDatetime = useOnCreateDatetime();\n\tconst onUpdateDatetime = useOnUpdateDatetime();\n\tconst onDeleteDatetime = useOnDeleteDatetime();\n\n\tconst getMutationVariables = useMutationVariables();\n\tconst getOptimisticResponse = useOptimisticResponse();\n\n\tconst onUpdate = useCallback>(\n\t\t({ cache, entity: datetime, input, mutationType }) => {\n\t\t\t// Read the existing data from cache.\n\t\t\tlet data: DatetimesList;\n\t\t\ttry {\n\t\t\t\tdata = cache.readQuery(options);\n\t\t\t} catch (error) {\n\t\t\t\tdata = null;\n\t\t\t}\n\t\t\tconst datetimes = data?.espressoDatetimes || DEFAULT_LIST_DATA;\n\t\t\tconst tickets = input?.tickets;\n\n\t\t\tswitch (mutationType) {\n\t\t\t\tcase MutationType.Create:\n\t\t\t\t\tonCreateDatetime({ cache, datetimes, datetime, tickets });\n\t\t\t\t\tbreak;\n\t\t\t\tcase MutationType.Update:\n\t\t\t\t\tonUpdateDatetime({ datetime, tickets });\n\t\t\t\t\tbreak;\n\t\t\t\tcase MutationType.Delete:\n\t\t\t\t\tonDeleteDatetime({ cache, datetimes, datetime, deletePermanently: input?.deletePermanently });\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t},\n\t\t[onCreateDatetime, onDeleteDatetime, onUpdateDatetime, options]\n\t);\n\n\tconst mutationHandler = useCallback(\n\t\t(mutationType, input) => {\n\t\t\t// Get rid of null or undefined values\n\t\t\tconst filteredInput = removeNullAndUndefined(input);\n\t\t\t// normalize numeric fields\n\t\t\tconst normalizedInput = normalizeNumericFields(NUMERIC_FIELDS, filteredInput);\n\n\t\t\tconst variables = getMutationVariables(mutationType, normalizedInput);\n\t\t\tconst optimisticResponse = getOptimisticResponse(mutationType, normalizedInput);\n\n\t\t\treturn { variables, optimisticResponse, onUpdate };\n\t\t},\n\t\t[getMutationVariables, getOptimisticResponse, onUpdate]\n\t);\n\n\treturn mutationHandler;\n};\n\nexport default useMutationHandler;\n","import { useCallback, useMemo } from 'react';\n\nimport { MutationType, useMutationWithFeedback } from '@eventespresso/data';\n\nimport type { DatetimeMutator } from './types';\nimport { CREATE_DATETIME, UPDATE_DATETIME, DELETE_DATETIME } from './';\nimport useMutationHandler from './useMutationHandler';\nimport useUpdateCallback from '../useUpdateCallback';\nimport { TypeName } from '../types';\nimport { SINGULAR_ENTITY_NAME } from '../../../constants';\n\ntype DM = DatetimeMutator;\n\nconst useDatetimeMutator = (id = ''): DM => {\n\tconst createDatetime = useMutationWithFeedback({\n\t\ttypeName: SINGULAR_ENTITY_NAME.DATETIME,\n\t\tmutationType: MutationType.Create,\n\t\tmutation: CREATE_DATETIME,\n\t});\n\n\tconst updateDatetime = useMutationWithFeedback({\n\t\ttypeName: SINGULAR_ENTITY_NAME.DATETIME,\n\t\tmutationType: MutationType.Update,\n\t\tmutation: UPDATE_DATETIME,\n\t});\n\n\tconst deleteDatetime = useMutationWithFeedback({\n\t\ttypeName: SINGULAR_ENTITY_NAME.DATETIME,\n\t\tmutationType: MutationType.Delete,\n\t\tmutation: DELETE_DATETIME,\n\t});\n\n\tconst mutationHandler = useMutationHandler();\n\n\tconst getUpdateCallback = useUpdateCallback(TypeName.Datetime);\n\n\tconst createEntity = useCallback(\n\t\t(input) => {\n\t\t\tconst { onUpdate, ...options } = mutationHandler(MutationType.Create, input);\n\n\t\t\tconst update = getUpdateCallback({ onUpdate, mutationType: MutationType.Create, input });\n\n\t\t\treturn createDatetime({ ...options, update });\n\t\t},\n\t\t[createDatetime, getUpdateCallback, mutationHandler]\n\t);\n\n\tconst updateEntity = useCallback(\n\t\t(input) => {\n\t\t\tconst { onUpdate, ...options } = mutationHandler(MutationType.Update, { id, ...input });\n\n\t\t\tconst update = getUpdateCallback({ onUpdate, mutationType: MutationType.Update, input });\n\n\t\t\treturn updateDatetime({ ...options, update });\n\t\t},\n\t\t[getUpdateCallback, id, mutationHandler, updateDatetime]\n\t);\n\n\tconst deleteEntity = useCallback(\n\t\t(input) => {\n\t\t\tconst { onUpdate, ...options } = mutationHandler(MutationType.Delete, { id, ...input });\n\n\t\t\tconst update = getUpdateCallback({ onUpdate, mutationType: MutationType.Delete, input });\n\n\t\t\treturn deleteDatetime({ ...options, update });\n\t\t},\n\t\t[deleteDatetime, getUpdateCallback, id, mutationHandler]\n\t);\n\treturn useMemo(() => ({ createEntity, updateEntity, deleteEntity }), [createEntity, deleteEntity, updateEntity]);\n};\n\nexport default useDatetimeMutator;\n","import { useCallback } from 'react';\n\nimport type { MutationType, MutationInput, OperationVariables } from '@eventespresso/data';\n\ntype MutationVariablesCb = (mutationType: MutationType, input: MutationInput) => OperationVariables;\n\nconst useMutationVariables = (): MutationVariablesCb => {\n\treturn useCallback((mutationType, input) => {\n\t\tconst mutationInput: MutationInput = {\n\t\t\tclientMutationId: `${mutationType}_TICKET`,\n\t\t\t...input,\n\t\t};\n\n\t\treturn {\n\t\t\tinput: mutationInput,\n\t\t};\n\t}, []);\n};\n\nexport default useMutationVariables;\n","import { useCallback } from 'react';\n\nimport { useRelations } from '@eventespresso/services';\nimport { getGuids, hasTempId } from '@eventespresso/predicates';\nimport updatePriceCache from './updatePriceCache';\nimport useUpdateTicketCache from './useUpdateTicketCache';\nimport type { TicketMutationCallbackFn, TicketMutationCallbackFnArgs } from '../types';\n\nconst useOnCreateTicket = (): TicketMutationCallbackFn => {\n\tconst { addRelation, updateRelations } = useRelations();\n\n\tconst updateTicketCache = useUpdateTicketCache();\n\n\tconst onCreateTicket = useCallback(\n\t\t({ cache, datetimeIds, ticket, tickets, prices }: TicketMutationCallbackFnArgs): void => {\n\t\t\tif (!hasTempId(ticket)) {\n\t\t\t\tconst { nodes = [] } = tickets;\n\t\t\t\tconst ticketIn = getGuids(nodes);\n\t\t\t\tconst { id: ticketId } = ticket;\n\n\t\t\t\t// Update prices cache for the changed tickets,\n\t\t\t\t// to avoid refetching of prices.\n\t\t\t\tupdatePriceCache({ cache, prices, ticketIn, ticketId, action: 'add' });\n\n\t\t\t\t// if related datetimes are passed\n\t\t\t\tif (datetimeIds?.length) {\n\t\t\t\t\t// Set relations with datetimes\n\t\t\t\t\tupdateRelations({\n\t\t\t\t\t\tentity: 'tickets',\n\t\t\t\t\t\tentityId: ticketId,\n\t\t\t\t\t\trelation: 'datetimes',\n\t\t\t\t\t\trelationIds: datetimeIds,\n\t\t\t\t\t});\n\t\t\t\t\tdatetimeIds.forEach((entityId: string) => {\n\t\t\t\t\t\taddRelation({\n\t\t\t\t\t\t\tentity: 'datetimes',\n\t\t\t\t\t\t\tentityId,\n\t\t\t\t\t\t\trelation: 'tickets',\n\t\t\t\t\t\t\trelationId: ticketId,\n\t\t\t\t\t\t});\n\t\t\t\t\t});\n\t\t\t\t}\n\n\t\t\t\t// Set relations with prices\n\t\t\t\tconst priceIds = getGuids(prices?.nodes || []);\n\t\t\t\tif (priceIds.length) {\n\t\t\t\t\tupdateRelations({\n\t\t\t\t\t\tentity: 'tickets',\n\t\t\t\t\t\tentityId: ticketId,\n\t\t\t\t\t\trelation: 'prices',\n\t\t\t\t\t\trelationIds: priceIds,\n\t\t\t\t\t});\n\t\t\t\t\tpriceIds.forEach((entityId: string) => {\n\t\t\t\t\t\taddRelation({\n\t\t\t\t\t\t\tentity: 'prices',\n\t\t\t\t\t\t\tentityId,\n\t\t\t\t\t\t\trelation: 'tickets',\n\t\t\t\t\t\t\trelationId: ticketId,\n\t\t\t\t\t\t});\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t}\n\t\t\t// Update ticket cache after price cache is updated.\n\t\t\tupdateTicketCache({ cache, tickets, ticket, action: 'add' });\n\t\t},\n\t\t[addRelation, updateRelations, updateTicketCache]\n\t);\n\n\treturn onCreateTicket;\n};\n\nexport default useOnCreateTicket;\n","import { useCallback } from 'react';\n\nimport { MutationType, MutationInput } from '@eventespresso/data';\nimport { PLUS_ONE_MONTH, PLUS_TWO_MONTHS } from '@eventespresso/constants';\nimport { ucFirst, uuid } from '@eventespresso/utils';\n\nimport type { Ticket } from '../../';\nimport { useLazyTicket } from '../../queries';\n\nexport const TICKET_DEFAULTS: Ticket = {\n\tid: '',\n\tdbId: 0,\n\tcacheId: '',\n\tdescription: '',\n\tendDate: PLUS_TWO_MONTHS.toISOString(),\n\tisSoldOut: false,\n\tisTrashed: false,\n\tisDefault: false,\n\tisExpired: false,\n\tisFree: false,\n\tisOnSale: false,\n\tisPending: true,\n\tisRequired: false,\n\tmax: -1,\n\tmin: 0,\n\tname: '',\n\torder: 0,\n\tprice: null,\n\tprices: null,\n\tquantity: -1,\n\tregistrationCount: 0,\n\treserved: 0,\n\treverseCalculate: true,\n\tsold: 0,\n\tstartDate: PLUS_ONE_MONTH.toISOString(),\n\tuserId: '',\n\tuses: -1,\n\tvisibility: 'PUBLIC',\n};\n\ntype OptimisticResCb = (mutationType: MutationType, input: MutationInput) => any;\n\nconst useOptimisticResponse = (): OptimisticResCb => {\n\tconst getTicket = useLazyTicket();\n\n\treturn useCallback(\n\t\t(mutationType, input) => {\n\t\t\tlet espressoTicket: Partial = {\n\t\t\t\t__typename: 'EspressoTicket',\n\t\t\t};\n\t\t\tconst ticket = getTicket(input.id);\n\t\t\tconst cacheId = `temp:${uuid()}`;\n\n\t\t\tswitch (mutationType) {\n\t\t\t\tcase MutationType.Create:\n\t\t\t\t\tespressoTicket = {\n\t\t\t\t\t\t...espressoTicket,\n\t\t\t\t\t\t...TICKET_DEFAULTS,\n\t\t\t\t\t\tcacheId,\n\t\t\t\t\t\t// make sure the id is generated on each call to make sure\n\t\t\t\t\t\t// it is unique for each entity created in bulk\n\t\t\t\t\t\tid: cacheId,\n\t\t\t\t\t\t...input,\n\t\t\t\t\t\tprices: null,\n\t\t\t\t\t};\n\t\t\t\t\tbreak;\n\t\t\t\tcase MutationType.Delete:\n\t\t\t\t\tespressoTicket = {\n\t\t\t\t\t\t...espressoTicket,\n\t\t\t\t\t\t...TICKET_DEFAULTS, // to avoid pollution of test console\n\t\t\t\t\t\t...ticket,\n\t\t\t\t\t\t...input,\n\t\t\t\t\t\tisTrashed: true,\n\t\t\t\t\t\tcacheId,\n\t\t\t\t\t};\n\t\t\t\t\tbreak;\n\t\t\t\tcase MutationType.Update:\n\t\t\t\t\tespressoTicket = {\n\t\t\t\t\t\t...espressoTicket,\n\t\t\t\t\t\t...ticket,\n\t\t\t\t\t\t...input,\n\t\t\t\t\t\tcacheId,\n\t\t\t\t\t\tprices: null,\n\t\t\t\t\t};\n\t\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tconst lcMutationtype = mutationType.toLowerCase();\n\t\t\tconst ucFirstMutationtype = ucFirst(lcMutationtype);\n\n\t\t\t// e.g. \"deleteEspressoTicket\", \"createEspressoTicket\"\n\t\t\tconst mutation = `${lcMutationtype}EspressoTicket`;\n\n\t\t\treturn {\n\t\t\t\t__typename: 'RootMutation',\n\t\t\t\t[mutation]: {\n\t\t\t\t\t__typename: `${ucFirstMutationtype}EspressoTicketPayload`,\n\t\t\t\t\tespressoTicket,\n\t\t\t\t},\n\t\t\t};\n\t\t},\n\t\t[getTicket]\n\t);\n};\n\nexport default useOptimisticResponse;\n","import type { KeysOfType } from '@eventespresso/utils';\nimport { TicketBaseInput } from './types';\n\nexport const NUMERIC_FIELDS: Array> = [\n\t'max',\n\t'min',\n\t'order',\n\t'price',\n\t'quantity',\n\t'reserved',\n\t'row',\n\t'sold',\n\t'uses',\n\t'wpUser',\n];\n\nexport const BOOLEAN_FIELDS: Array> = [\n\t'isDefault',\n\t'isRequired',\n\t'isTrashed',\n\t'reverseCalculate',\n];\n","import { useCallback } from 'react';\n\nimport { getGuids } from '@eventespresso/predicates';\nimport { MutationType } from '@eventespresso/data';\nimport { normalizeBooleanFields, normalizeNumericFields, removeNullAndUndefined } from '@eventespresso/utils';\n\nimport useMutationVariables from './useMutationVariables';\nimport useOnCreateTicket from './useOnCreateTicket';\nimport useOnDeleteTicket from './useOnDeleteTicket';\nimport useOnUpdateTicket from './useOnUpdateTicket';\nimport useOptimisticResponse from './useOptimisticResponse';\nimport { hooks } from '../../../ioc';\nimport { DEFAULT_TICKET_LIST_DATA as DEFAULT_LIST_DATA, useTicketQueryOptions } from '../../queries';\nimport type { MutationHandler, MutationUpdater } from '../types';\nimport { TicketsList, Ticket } from '../../';\nimport type { TicketCommonInput } from './types';\nimport { BOOLEAN_FIELDS, NUMERIC_FIELDS } from './constants';\nimport useAffectedDatesQueries from './useAffectedDatesQueries';\n\ntype MH = MutationHandler;\n\nconst useMutationHandler = (): MH => {\n\tconst queryOptions = useTicketQueryOptions();\n\n\tconst onCreateTicket = useOnCreateTicket();\n\tconst onUpdateTicket = useOnUpdateTicket();\n\tconst onDeleteTicket = useOnDeleteTicket();\n\tconst affectedDatesQueries = useAffectedDatesQueries();\n\n\tconst getMutationVariables = useMutationVariables();\n\tconst getOptimisticResponse = useOptimisticResponse();\n\n\tconst onUpdate = useCallback>(\n\t\t({ cache, entity, input, mutationType }) => {\n\t\t\t// extract prices data to avoid\n\t\t\t// it going to tickets cache\n\t\t\tconst { prices, ...ticket } = entity;\n\n\t\t\t// Read the existing data from cache.\n\t\t\tlet data: TicketsList;\n\t\t\ttry {\n\t\t\t\tdata = cache.readQuery(queryOptions);\n\t\t\t} catch (error) {\n\t\t\t\tdata = null;\n\t\t\t}\n\t\t\tconst tickets = data?.espressoTickets || DEFAULT_LIST_DATA;\n\t\t\tconst datetimeIds = input?.datetimes;\n\n\t\t\tconst priceIds: string[] = prices?.nodes ? getGuids(prices.nodes) : null;\n\n\t\t\tswitch (mutationType) {\n\t\t\t\tcase MutationType.Create:\n\t\t\t\t\tonCreateTicket({ cache, tickets, ticket, datetimeIds, prices });\n\t\t\t\t\tbreak;\n\t\t\t\tcase MutationType.Update:\n\t\t\t\t\tonUpdateTicket({ cache, tickets, ticket, datetimeIds, priceIds });\n\t\t\t\t\tbreak;\n\t\t\t\tcase MutationType.Delete:\n\t\t\t\t\tonDeleteTicket({ cache, tickets, ticket, deletePermanently: input?.deletePermanently });\n\t\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\thooks.doAction('eventEditor.ticket.mutation', mutationType, input, entity, cache);\n\t\t},\n\t\t[onCreateTicket, onDeleteTicket, onUpdateTicket, queryOptions]\n\t);\n\tconst mutator = useCallback(\n\t\t(mutationType, input) => {\n\t\t\t// Get rid of null or undefined values\n\t\t\tconst filteredInput = removeNullAndUndefined(input);\n\t\t\t// normalize numeric fields\n\t\t\tlet normalizedInput = normalizeNumericFields(NUMERIC_FIELDS, filteredInput);\n\t\t\t// normalize boolean fields\n\t\t\tnormalizedInput = normalizeBooleanFields(BOOLEAN_FIELDS, normalizedInput);\n\n\t\t\tconst variables = getMutationVariables(mutationType, normalizedInput);\n\n\t\t\tif (input.isDefault) {\n\t\t\t\t// no optimistic response for default tickets\n\t\t\t\treturn { variables, onUpdate };\n\t\t\t}\n\n\t\t\tconst refetchQueries = affectedDatesQueries({ input, mutationType });\n\n\t\t\tconst optimisticResponse = getOptimisticResponse(mutationType, normalizedInput);\n\n\t\t\treturn { variables, optimisticResponse, onUpdate, refetchQueries };\n\t\t},\n\t\t[affectedDatesQueries, getMutationVariables, getOptimisticResponse, onUpdate]\n\t);\n\n\treturn mutator;\n};\n\nexport default useMutationHandler;\n","import { useCallback, useMemo } from 'react';\n\nimport { MutationType, MutationFunction, useMutationWithFeedback } from '@eventespresso/data';\n\nimport type { CreateTicketInput, UpdateTicketInput, DeleteTicketInput } from './types';\nimport { CREATE_TICKET, UPDATE_TICKET, DELETE_TICKET } from './';\nimport useMutationHandler from './useMutationHandler';\nimport useUpdateCallback from '../useUpdateCallback';\nimport { TypeName } from '../types';\nimport type { CreateTicketResult, UpdateTicketResult, DeleteTicketResult } from './types';\nimport { SINGULAR_ENTITY_NAME } from '../../../constants';\n\ninterface TicketMutator {\n\tcreateEntity: MutationFunction;\n\tupdateEntity: MutationFunction;\n\tdeleteEntity: MutationFunction;\n}\n\ntype TM = TicketMutator;\n\nconst useTicketMutator = (id = ''): TM => {\n\tconst createTicket = useMutationWithFeedback({\n\t\ttypeName: SINGULAR_ENTITY_NAME.TICKET,\n\t\tmutationType: MutationType.Create,\n\t\tmutation: CREATE_TICKET,\n\t});\n\n\tconst updateTicket = useMutationWithFeedback({\n\t\ttypeName: SINGULAR_ENTITY_NAME.TICKET,\n\t\tmutationType: MutationType.Update,\n\t\tmutation: UPDATE_TICKET,\n\t});\n\n\tconst deleteTicket = useMutationWithFeedback({\n\t\ttypeName: SINGULAR_ENTITY_NAME.TICKET,\n\t\tmutationType: MutationType.Delete,\n\t\tmutation: DELETE_TICKET,\n\t});\n\n\tconst mutationHandler = useMutationHandler();\n\n\tconst getUpdateCallback = useUpdateCallback(TypeName.Ticket);\n\n\tconst createEntity = useCallback(\n\t\t(input) => {\n\t\t\tconst { onUpdate, ...options } = mutationHandler(MutationType.Create, input);\n\n\t\t\tconst update = getUpdateCallback({ onUpdate, mutationType: MutationType.Create, input });\n\n\t\t\treturn createTicket({ ...options, update });\n\t\t},\n\t\t[createTicket, getUpdateCallback, mutationHandler]\n\t);\n\n\tconst updateEntity = useCallback(\n\t\t(input) => {\n\t\t\tconst { onUpdate, ...options } = mutationHandler(MutationType.Update, { id, ...input });\n\n\t\t\tconst update = getUpdateCallback({ onUpdate, mutationType: MutationType.Update, input });\n\n\t\t\treturn updateTicket({ ...options, update });\n\t\t},\n\t\t[getUpdateCallback, id, mutationHandler, updateTicket]\n\t);\n\n\tconst deleteEntity = useCallback(\n\t\t(input) => {\n\t\t\tconst { onUpdate, ...options } = mutationHandler(MutationType.Delete, { id, ...input });\n\n\t\t\tconst update = getUpdateCallback({ onUpdate, mutationType: MutationType.Delete, input });\n\n\t\t\treturn deleteTicket({ ...options, update });\n\t\t},\n\t\t[deleteTicket, getUpdateCallback, id, mutationHandler]\n\t);\n\treturn useMemo(() => ({ createEntity, updateEntity, deleteEntity }), [createEntity, deleteEntity, updateEntity]);\n};\n\nexport default useTicketMutator;\n","import * as yup from 'yup';\n\nimport { endDateAfterStartDateErrorMessage, mayBeAdjustEndDate } from '@eventespresso/dates';\nimport { __ } from '@eventespresso/i18n';\nimport { Decorator } from '@eventespresso/form';\n\nexport const startAndEndDateFixer: Decorator = (form) => {\n\tlet previousValues: any = {};\n\n\tconst unsubscribe = form.subscribe(\n\t\t({ values }) => {\n\t\t\tform.batch(() => {\n\t\t\t\tconst { endDate, startDate } = values;\n\n\t\t\t\tconst prevStartDate = previousValues.startDate;\n\t\t\t\tconst prevEndDate = previousValues.endDate;\n\n\t\t\t\tconst startDateChanged = startDate !== prevStartDate;\n\t\t\t\tconst endDateChanged = endDate !== prevEndDate;\n\n\t\t\t\tconst isEndDateNotPristine = !form.getFieldState('endDate')?.pristine;\n\t\t\t\tconst changedFromStartDate = form.getFieldState('endDate')?.data?.changedFromStartDate;\n\n\t\t\t\tif (startDateChanged) {\n\t\t\t\t\t// there should be no notice unless things are not in order\n\t\t\t\t\tlet endDateFieldNotice: string;\n\n\t\t\t\t\tconst newEndDate = mayBeAdjustEndDate({\n\t\t\t\t\t\tnewEndDate: endDate,\n\t\t\t\t\t\tnewStartDate: startDate,\n\t\t\t\t\t\tprevEndDate,\n\t\t\t\t\t\tprevStartDate,\n\t\t\t\t\t});\n\t\t\t\t\t// if end date has been adjusted\n\t\t\t\t\tif (newEndDate !== endDate) {\n\t\t\t\t\t\tform.change('endDate', newEndDate);\n\t\t\t\t\t\tform.mutators.setFieldData('endDate', { changedFromStartDate: true });\n\t\t\t\t\t\tendDateFieldNotice = __('End date has been adjusted');\n\t\t\t\t\t}\n\n\t\t\t\t\tform.mutators.setFieldData('endDate', { fieldNotice: endDateFieldNotice });\n\t\t\t\t}\n\n\t\t\t\tif (endDateChanged) {\n\t\t\t\t\tif (isEndDateNotPristine && !changedFromStartDate) {\n\t\t\t\t\t\tform.mutators.setFieldData('endDate', { fieldNotice: null });\n\t\t\t\t\t}\n\n\t\t\t\t\tform.mutators.setFieldData('endDate', { changedFromStartDate: false });\n\t\t\t\t}\n\t\t\t});\n\t\t\tpreviousValues = values;\n\t\t},\n\t\t{ values: true }\n\t);\n\treturn unsubscribe;\n};\n\nexport const requiredMessage = (): string => __('Required');\n\nexport const datesSchema = {\n\tstartDate: yup\n\t\t.date()\n\t\t.required(() => __('Start Date is required'))\n\t\t.typeError(requiredMessage),\n\tendDate: yup\n\t\t.date()\n\t\t.required(() => __('End Date is required'))\n\t\t.typeError(requiredMessage)\n\t\t.when(['startDate'], (startDate: Date, schema: yup.DateSchema) => {\n\t\t\treturn schema.min(startDate, () => endDateAfterStartDateErrorMessage);\n\t\t}),\n};\n","import { DisplayStartOrEndDate } from '../filterState';\nimport type { Cell } from '@eventespresso/ui-components';\n\nexport const filterCellByStartOrEndDate =\n\t(displayStartOrEndDate: DisplayStartOrEndDate) =>\n\t(cell: Cell): boolean => {\n\t\tif (displayStartOrEndDate === DisplayStartOrEndDate.start && cell.key === 'end') {\n\t\t\treturn false;\n\t\t}\n\n\t\tif (displayStartOrEndDate === DisplayStartOrEndDate.end && cell.key === 'start') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t};\n","import { EventEditorData } from '../types';\n\nexport const getEdtrDomData = (key: K): EventEditorData[K] => {\n\treturn window.eventEspressoData.eventEditor?.[key];\n};\n","import { useMemo } from 'react';\nimport { EditorData } from '../../types';\n\nconst useCacheRehydrationData = (): EditorData => {\n\treturn useMemo(() => {\n\t\tconst { currentUser, generalSettings } = window?.eventEspressoData?.config || {};\n\t\tconst eventEditor = window?.eventEspressoData?.eventEditor || {};\n\n\t\treturn { currentUser, eventEditor, generalSettings };\n\t}, []);\n};\n\nexport default useCacheRehydrationData;\n","import { useEffect } from 'react';\n\nimport { useRelations, useStatus, TypeName } from '@eventespresso/services';\nimport {\n\tuseCurrentUserQueryOptions,\n\tuseGeneralSettingsQueryOptions,\n\tuseUpdateCache,\n\tuseUpdateCurrentUserCache,\n\tuseUpdateGeneralSettingsCache,\n\tuseIsRehydrated,\n} from '@eventespresso/data';\n\nimport useCacheRehydrationData from './useCacheRehydrationData';\nimport {\n\tuseUpdateDatetimeList,\n\tuseUpdatePriceList,\n\tuseUpdatePriceTypeList,\n\tuseUpdateTicketList,\n\tuseUpdateVenueList,\n} from '../../hooks';\nimport {\n\tDEFAULT_DATETIME_LIST_DATA,\n\tDEFAULT_TICKET_LIST_DATA,\n\tDEFAULT_PRICE_LIST_DATA,\n\tDEFAULT_PRICE_TYPE_LIST_DATA,\n\tDEFAULT_VENUE_LIST_DATA,\n\tuseDatetimeQueryOptions,\n\tuseEventQueryOptions,\n\tusePriceQueryOptions,\n\tusePriceTypeQueryOptions,\n\tuseTicketQueryOptions,\n\tuseVenueQueryOptions,\n} from '../queries';\n\nconst useCacheRehydration = (): boolean => {\n\tconst { setIsLoaded } = useStatus();\n\tconst { initialize: initializeRelations, isInitialized: relationsInitialized } = useRelations();\n\tconst { currentUser, eventEditor, generalSettings } = useCacheRehydrationData();\n\tconst [isRehydrated, setIsRehydrated] = useIsRehydrated();\n\tconst {\n\t\tevent,\n\t\tdatetimes: espressoDatetimes = DEFAULT_DATETIME_LIST_DATA,\n\t\ttickets: espressoTickets = DEFAULT_TICKET_LIST_DATA,\n\t\tprices: espressoPrices = DEFAULT_PRICE_LIST_DATA,\n\t\tpriceTypes: espressoPriceTypes = DEFAULT_PRICE_TYPE_LIST_DATA,\n\t\tvenues: espressoVenues = DEFAULT_VENUE_LIST_DATA,\n\t\trelations,\n\t} = eventEditor;\n\n\tconst priceTypeQueryOptions = usePriceTypeQueryOptions();\n\tconst updatePriceTypeList = useUpdatePriceTypeList();\n\n\tconst datetimeQueryOptions = useDatetimeQueryOptions();\n\tconst updateDatetimeList = useUpdateDatetimeList();\n\n\tconst ticketQueryOptions = useTicketQueryOptions();\n\tconst updateTicketList = useUpdateTicketList();\n\n\tconst priceQueryOptions = usePriceQueryOptions();\n\tconst updatePriceList = useUpdatePriceList();\n\n\tconst venueQueryOptions = useVenueQueryOptions();\n\tconst updateVenueList = useUpdateVenueList();\n\n\tconst currentUserQueryOptions = useCurrentUserQueryOptions();\n\tconst updateCurrentUser = useUpdateCurrentUserCache();\n\n\tconst generalSettingsQueryOptions = useGeneralSettingsQueryOptions();\n\tconst updateGeneralSettings = useUpdateGeneralSettingsCache();\n\n\tconst eventQueryOptions = useEventQueryOptions();\n\tconst updateCache = useUpdateCache();\n\n\tuseEffect(() => {\n\t\tif (!relationsInitialized()) {\n\t\t\t/* Rehydrate relations */\n\t\t\tinitializeRelations(relations);\n\t\t}\n\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\t}, [relations]);\n\n\tuseEffect(() => {\n\t\tif (isRehydrated) {\n\t\t\treturn;\n\t\t}\n\n\t\t/* Rehydrate event data */\n\t\tupdateCache({\n\t\t\t...eventQueryOptions,\n\t\t\tdata: {\n\t\t\t\tespressoEvent: event,\n\t\t\t},\n\t\t});\n\t\t/* Rehydrate price types */\n\t\tupdatePriceTypeList({\n\t\t\t...priceTypeQueryOptions,\n\t\t\tdata: {\n\t\t\t\tespressoPriceTypes,\n\t\t\t},\n\t\t});\n\t\tsetIsLoaded(TypeName.priceTypes, true);\n\n\t\t/* Rehydrate datetimes */\n\t\tupdateDatetimeList({\n\t\t\t...datetimeQueryOptions,\n\t\t\tdata: {\n\t\t\t\tespressoDatetimes,\n\t\t\t},\n\t\t});\n\t\tsetIsLoaded(TypeName.datetimes, true);\n\n\t\t/* Rehydrate tickets */\n\t\tupdateTicketList({\n\t\t\t...ticketQueryOptions,\n\t\t\tdata: {\n\t\t\t\tespressoTickets,\n\t\t\t},\n\t\t});\n\t\tsetIsLoaded(TypeName.tickets, true);\n\n\t\t/* Rehydrate prices */\n\t\tupdatePriceList({\n\t\t\t...priceQueryOptions,\n\t\t\tdata: {\n\t\t\t\tespressoPrices,\n\t\t\t},\n\t\t});\n\t\tsetIsLoaded(TypeName.prices, true);\n\n\t\t/* Rehydrate venues */\n\t\tupdateVenueList({\n\t\t\t...venueQueryOptions,\n\t\t\tdata: {\n\t\t\t\tespressoVenues,\n\t\t\t},\n\t\t});\n\n\t\t/* Rehydrate current user */\n\t\tupdateCurrentUser({\n\t\t\t...currentUserQueryOptions,\n\t\t\tdata: {\n\t\t\t\tviewer: currentUser,\n\t\t\t},\n\t\t});\n\n\t\t/* Rehydrate general settings */\n\t\tupdateGeneralSettings({\n\t\t\t...generalSettingsQueryOptions,\n\t\t\tdata: {\n\t\t\t\tgeneralSettings,\n\t\t\t},\n\t\t});\n\n\t\tsetIsRehydrated(true);\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\t}, []);\n\n\treturn isRehydrated;\n};\n\nexport default useCacheRehydration;\n","import { useCallback } from 'react';\n\nimport { MutationType, MutationInput } from '@eventespresso/data';\nimport { ucFirst, removeNullAndUndefined, uuid } from '@eventespresso/utils';\n\nimport type { Event } from '../../types';\nimport { useEvent } from '../../queries';\n\nexport const EVENT_DEFAULTS: Event = {\n\tid: '',\n\tdbId: 0,\n\tcacheId: uuid(),\n\tallowDonations: false,\n\tallowOverflow: false,\n\taltRegPage: '',\n\tcreated: '',\n\tdescription: '',\n\tdefaultRegStatus: '',\n\tdisplayDescription: false,\n\tdisplayTicketSelector: true,\n\tisActive: true,\n\tisCancelled: false,\n\tisExpired: false,\n\tisInactive: false,\n\tisPostponed: false,\n\tisSoldOut: false,\n\tisUpcoming: false,\n\tmaxRegistrations: 0,\n\tmemberOnly: false,\n\tname: '',\n\torder: 0,\n\tphoneNumber: '',\n\tshortDescription: '',\n\tstatus: '',\n\ttimezoneString: '',\n\tvenue: '',\n};\n\ntype OptimisticResCb = (mutationType: MutationType, input: MutationInput) => any;\n\nconst useOptimisticResponse = (): OptimisticResCb => {\n\tconst event = useEvent();\n\n\treturn useCallback(\n\t\t(mutationType, input) => {\n\t\t\tlet espressoEvent: Partial = {\n\t\t\t\t__typename: 'EspressoEvent',\n\t\t\t};\n\t\t\t// Get rid of null or undefined values\n\t\t\tconst filteredInput = removeNullAndUndefined(input);\n\n\t\t\tswitch (mutationType) {\n\t\t\t\tcase MutationType.Update:\n\t\t\t\t\tespressoEvent = {\n\t\t\t\t\t\t...espressoEvent,\n\t\t\t\t\t\t...event,\n\t\t\t\t\t\t...filteredInput,\n\t\t\t\t\t\tcacheId: uuid(),\n\t\t\t\t\t};\n\t\t\t\t\t// if manager is being updated\n\t\t\t\t\tif (input?.manager) {\n\t\t\t\t\t\t// make sure to properly update manager object\n\t\t\t\t\t\tespressoEvent.manager = {\n\t\t\t\t\t\t\t...event?.manager,\n\t\t\t\t\t\t\tid: input?.manager,\n\t\t\t\t\t\t};\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tconst lcMutationtype = mutationType.toLowerCase();\n\t\t\tconst ucFirstMutationtype = ucFirst(lcMutationtype);\n\n\t\t\t// e.g. \"updateEspressoEvent\"\n\t\t\tconst mutation = `${lcMutationtype}EspressoEvent`;\n\n\t\t\treturn {\n\t\t\t\t__typename: 'RootMutation',\n\t\t\t\t[mutation]: {\n\t\t\t\t\t__typename: `${ucFirstMutationtype}EspressoEventPayload`,\n\t\t\t\t\tespressoEvent,\n\t\t\t\t},\n\t\t\t};\n\t\t},\n\t\t[event]\n\t);\n};\n\nexport default useOptimisticResponse;\n","import { useCallback } from 'react';\n\nimport { MutationType, MutationInput, OperationVariables } from '@eventespresso/data';\n\nimport useOptimisticResponse from './useOptimisticResponse';\nimport type { MutationHandler } from '../types';\nimport type { Event } from '../../';\nimport type { EventBaseInput } from './types';\n\ntype MH = MutationHandler;\n\nconst useMutationHandler = (): MH => {\n\tconst getOptimisticResponse = useOptimisticResponse();\n\n\tconst createVariables = useCallback((mutationType: MutationType, input: MutationInput): OperationVariables => {\n\t\tconst mutationInput: MutationInput = {\n\t\t\tclientMutationId: `${mutationType}_EVENT`,\n\t\t\t...input,\n\t\t};\n\n\t\treturn {\n\t\t\tinput: mutationInput,\n\t\t};\n\t}, []);\n\n\tconst mutator = useCallback(\n\t\t(mutationType, input) => {\n\t\t\tconst variables = createVariables(mutationType, input);\n\t\t\tconst optimisticResponse = getOptimisticResponse(mutationType, input);\n\n\t\t\treturn { variables, optimisticResponse };\n\t\t},\n\t\t[createVariables, getOptimisticResponse]\n\t);\n\n\treturn mutator;\n};\n\nexport default useMutationHandler;\n","import { useCallback, useMemo } from 'react';\n\nimport { MutationType, MutationFunction, useMutationWithFeedback } from '@eventespresso/data';\n\nimport type { UpdateEventInput } from './types';\nimport { UPDATE_EVENT } from './';\nimport useMutationHandler from './useMutationHandler';\nimport type { UpdateEventResult } from './types';\nimport { SINGULAR_ENTITY_NAME } from '../../../constants';\n\ninterface EventMutator {\n\tupdateEntity: MutationFunction;\n}\n\ntype EM = EventMutator;\n\nconst useEventMutator = (id = ''): EM => {\n\tconst updateEvent = useMutationWithFeedback({\n\t\ttypeName: SINGULAR_ENTITY_NAME.EVENT,\n\t\tmutationType: MutationType.Update,\n\t\tmutation: UPDATE_EVENT,\n\t});\n\n\tconst mutationHandler = useMutationHandler();\n\n\tconst updateEntity = useCallback(\n\t\t(input) => {\n\t\t\tconst options = mutationHandler(MutationType.Update, { id, ...input });\n\n\t\t\treturn updateEvent(options);\n\t\t},\n\t\t[id, mutationHandler, updateEvent]\n\t);\n\n\treturn useMemo(() => ({ updateEntity }), [updateEntity]);\n};\n\nexport default useEventMutator;\n","import { createSlotFill } from '@eventespresso/slot-fill';\n\nconst { Slot: NewDateOptions, Fill: NewDateOption } = createSlotFill('NewDateOptions');\n\nexport { NewDateOption, NewDateOptions };\n","import { makeVar } from '@eventespresso/data';\nimport { useEntityMeta, ManageEntityMeta } from '@eventespresso/services';\n\nconst ticketsMeta = makeVar({});\n\nexport const useTicketsMeta = (): ManageEntityMeta => {\n\treturn useEntityMeta(ticketsMeta);\n};\n","import { useMemoStringify } from '@eventespresso/hooks';\n\nimport type { EventManager } from '../../types';\n\nconst useEventManagers = (): Array => {\n\treturn useMemoStringify(window.eventEspressoData?.eventEditor?.eventManagers || []);\n};\n\nexport default useEventManagers;\n","import { useCallback, useMemo } from 'react';\nimport { keys, pathOr, pickBy, hasPath } from 'ramda';\n\nimport { useRelations } from '@eventespresso/services';\nimport { entitiesWithGuIdInArray } from '@eventespresso/predicates';\n\nimport type { Ticket } from '../../apollo';\nimport { useVisibleDatetimeIds } from '../../hooks';\n\ntype IsChainedFilterCallback = (args: { isChained: boolean; tickets: Array }) => Array;\ntype IsChainedFilterDeps = any;\n\ntype IsChainedFilterTuple = [IsChainedFilterCallback, IsChainedFilterDeps];\n\nconst useIsChainedFilter = (): IsChainedFilterTuple => {\n\tconst { getData } = useRelations();\n\tconst [visibleDatetimeIds] = useVisibleDatetimeIds();\n\n\tconst relatedTicketIds = useMemo(() => {\n\t\treturn keys(\n\t\t\tpickBy((relations) => {\n\t\t\t\treturn (\n\t\t\t\t\thasPath(['datetimes'], relations) &&\n\t\t\t\t\tpathOr([], ['datetimes'], relations).some((id) => visibleDatetimeIds.includes(id))\n\t\t\t\t);\n\t\t\t}, getData().tickets)\n\t\t);\n\t}, [getData, visibleDatetimeIds]);\n\n\tconst callback = useCallback(\n\t\t({ isChained, tickets }) => {\n\t\t\t// bail early\n\t\t\tif (!isChained) {\n\t\t\t\treturn tickets;\n\t\t\t}\n\n\t\t\treturn entitiesWithGuIdInArray(tickets, relatedTicketIds);\n\t\t},\n\n\t\t[relatedTicketIds]\n\t);\n\n\treturn useMemo(() => [callback, relatedTicketIds], [callback, relatedTicketIds]);\n};\n\nexport default useIsChainedFilter;\n","import { useEffect, useRef } from 'react';\n\nimport { FilterBarService } from '@eventespresso/registry';\nimport type { TicketsFilterStateManager } from './types';\n\nimport { domain, ticketsList } from '../../constants';\nimport useIsChainedFilter from './useIsChainedFilter';\nimport type { Ticket } from '../../apollo';\n\ntype Domain = typeof domain;\ntype TFSM = TicketsFilterStateManager;\n\nconst { registerFilter: registerTicketsFilter } = new FilterBarService(\n\tdomain,\n\tticketsList\n);\n\nconst useRegisterIsChainedFilter: VoidFunction = () => {\n\t/**\n\t * isChained filter needs special treatment :)\n\t *\n\t * Unlike other sorters and filters, isChained filter is dependent upon\n\t * external state which can change. Thus we need to update our filter callback\n\t * to make sure the stale state is not bound to the filter callback.\n\t */\n\tconst [isChainedFilter, isChainedDeps] = useIsChainedFilter();\n\t// To avoid multiple filter registrations, we will store the already registered\n\t// filter unSubscribe callback in ref to use it to remove the existing filter.\n\tconst unSubIsChainedFilterRef = useRef();\n\n\tuseEffect(() => {\n\t\t// If already registered, de-register\n\t\tunSubIsChainedFilterRef.current?.();\n\n\t\t// Register isChained filter\n\t\tconst unSubscribeIsChainedFilter = registerTicketsFilter(({ entityList, filterState }) => {\n\t\t\treturn isChainedFilter({ isChained: filterState.isChained, tickets: entityList });\n\t\t}, 9); // we want isChained to run first\n\n\t\t// update ref, it won't cause rerendersٖ\n\t\tunSubIsChainedFilterRef.current = unSubscribeIsChainedFilter;\n\t\t// Housekeeping\n\t\treturn (): void => {\n\t\t\tunSubIsChainedFilterRef.current?.();\n\t\t};\n\t}, [isChainedDeps, isChainedFilter]);\n};\n\nexport default useRegisterIsChainedFilter;\n","var _curry1 =\n/*#__PURE__*/\nrequire(\"./internal/_curry1\");\n\nvar empty =\n/*#__PURE__*/\nrequire(\"./empty\");\n\nvar equals =\n/*#__PURE__*/\nrequire(\"./equals\");\n/**\n * Returns `true` if the given value is its type's empty value; `false`\n * otherwise.\n *\n * @func\n * @memberOf R\n * @since v0.1.0\n * @category Logic\n * @sig a -> Boolean\n * @param {*} x\n * @return {Boolean}\n * @see R.empty\n * @example\n *\n * R.isEmpty([1, 2, 3]); //=> false\n * R.isEmpty([]); //=> true\n * R.isEmpty(''); //=> true\n * R.isEmpty(null); //=> false\n * R.isEmpty({}); //=> true\n * R.isEmpty({length: 0}); //=> false\n */\n\n\nvar isEmpty =\n/*#__PURE__*/\n_curry1(function isEmpty(x) {\n return x != null && equals(x, empty(x));\n});\n\nmodule.exports = isEmpty;","// import global types.\nimport '../../../types';\n\nexport * from './apollo';\n\nexport * from './constants';\n\nexport * from './context';\n\nexport * from './filterState';\n\nexport * from './forms';\n\nexport * from './hooks';\n\nexport * from './ioc';\n\nexport * from './slots';\n\nexport * from './utils';\n\nexport * from './types';\n","var _curry1 =\n/*#__PURE__*/\nrequire(\"./internal/_curry1\");\n\nvar _isArguments =\n/*#__PURE__*/\nrequire(\"./internal/_isArguments\");\n\nvar _isArray =\n/*#__PURE__*/\nrequire(\"./internal/_isArray\");\n\nvar _isObject =\n/*#__PURE__*/\nrequire(\"./internal/_isObject\");\n\nvar _isString =\n/*#__PURE__*/\nrequire(\"./internal/_isString\");\n/**\n * Returns the empty value of its argument's type. Ramda defines the empty\n * value of Array (`[]`), Object (`{}`), String (`''`), and Arguments. Other\n * types are supported if they define `.empty`,\n * `.prototype.empty` or implement the\n * [FantasyLand Monoid spec](https://github.com/fantasyland/fantasy-land#monoid).\n *\n * Dispatches to the `empty` method of the first argument, if present.\n *\n * @func\n * @memberOf R\n * @since v0.3.0\n * @category Function\n * @sig a -> a\n * @param {*} x\n * @return {*}\n * @example\n *\n * R.empty(Just(42)); //=> Nothing()\n * R.empty([1, 2, 3]); //=> []\n * R.empty('unicorns'); //=> ''\n * R.empty({x: 1, y: 2}); //=> {}\n */\n\n\nvar empty =\n/*#__PURE__*/\n_curry1(function empty(x) {\n return x != null && typeof x['fantasy-land/empty'] === 'function' ? x['fantasy-land/empty']() : x != null && x.constructor != null && typeof x.constructor['fantasy-land/empty'] === 'function' ? x.constructor['fantasy-land/empty']() : x != null && typeof x.empty === 'function' ? x.empty() : x != null && x.constructor != null && typeof x.constructor.empty === 'function' ? x.constructor.empty() : _isArray(x) ? [] : _isString(x) ? '' : _isObject(x) ? {} : _isArguments(x) ? function () {\n return arguments;\n }() : void 0 // else\n ;\n});\n\nmodule.exports = empty;","/**\n * Tests whether or not an object is an array.\n *\n * @private\n * @param {*} val The object to test.\n * @return {Boolean} `true` if `val` is an array, `false` otherwise.\n * @example\n *\n * _isArray([]); //=> true\n * _isArray(null); //=> false\n * _isArray({}); //=> false\n */\nmodule.exports = Array.isArray || function _isArray(val) {\n return val != null && val.length >= 0 && Object.prototype.toString.call(val) === '[object Array]';\n};","function _isObject(x) {\n return Object.prototype.toString.call(x) === '[object Object]';\n}\n\nmodule.exports = _isObject;","function _isString(x) {\n return Object.prototype.toString.call(x) === '[object String]';\n}\n\nmodule.exports = _isString;","var _curry2 =\n/*#__PURE__*/\nrequire(\"./internal/_curry2\");\n\nvar _equals =\n/*#__PURE__*/\nrequire(\"./internal/_equals\");\n/**\n * Returns `true` if its arguments are equivalent, `false` otherwise. Handles\n * cyclical data structures.\n *\n * Dispatches symmetrically to the `equals` methods of both arguments, if\n * present.\n *\n * @func\n * @memberOf R\n * @since v0.15.0\n * @category Relation\n * @sig a -> b -> Boolean\n * @param {*} a\n * @param {*} b\n * @return {Boolean}\n * @example\n *\n * R.equals(1, 1); //=> true\n * R.equals(1, '1'); //=> false\n * R.equals([1, 2, 3], [1, 2, 3]); //=> true\n *\n * const a = {}; a.v = a;\n * const b = {}; b.v = b;\n * R.equals(a, b); //=> true\n */\n\n\nvar equals =\n/*#__PURE__*/\n_curry2(function equals(a, b) {\n return _equals(a, b, [], []);\n});\n\nmodule.exports = equals;","var _curry1 =\n/*#__PURE__*/\nrequire(\"./_curry1\");\n\nvar _isPlaceholder =\n/*#__PURE__*/\nrequire(\"./_isPlaceholder\");\n/**\n * Optimized internal two-arity curry function.\n *\n * @private\n * @category Function\n * @param {Function} fn The function to curry.\n * @return {Function} The curried function.\n */\n\n\nfunction _curry2(fn) {\n return function f2(a, b) {\n switch (arguments.length) {\n case 0:\n return f2;\n\n case 1:\n return _isPlaceholder(a) ? f2 : _curry1(function (_b) {\n return fn(a, _b);\n });\n\n default:\n return _isPlaceholder(a) && _isPlaceholder(b) ? f2 : _isPlaceholder(a) ? _curry1(function (_a) {\n return fn(_a, b);\n }) : _isPlaceholder(b) ? _curry1(function (_b) {\n return fn(a, _b);\n }) : fn(a, b);\n }\n };\n}\n\nmodule.exports = _curry2;","var _arrayFromIterator =\n/*#__PURE__*/\nrequire(\"./_arrayFromIterator\");\n\nvar _includesWith =\n/*#__PURE__*/\nrequire(\"./_includesWith\");\n\nvar _functionName =\n/*#__PURE__*/\nrequire(\"./_functionName\");\n\nvar _has =\n/*#__PURE__*/\nrequire(\"./_has\");\n\nvar _objectIs =\n/*#__PURE__*/\nrequire(\"./_objectIs\");\n\nvar keys =\n/*#__PURE__*/\nrequire(\"../keys\");\n\nvar type =\n/*#__PURE__*/\nrequire(\"../type\");\n/**\n * private _uniqContentEquals function.\n * That function is checking equality of 2 iterator contents with 2 assumptions\n * - iterators lengths are the same\n * - iterators values are unique\n *\n * false-positive result will be returned for comparision of, e.g.\n * - [1,2,3] and [1,2,3,4]\n * - [1,1,1] and [1,2,3]\n * */\n\n\nfunction _uniqContentEquals(aIterator, bIterator, stackA, stackB) {\n var a = _arrayFromIterator(aIterator);\n\n var b = _arrayFromIterator(bIterator);\n\n function eq(_a, _b) {\n return _equals(_a, _b, stackA.slice(), stackB.slice());\n } // if *a* array contains any element that is not included in *b*\n\n\n return !_includesWith(function (b, aItem) {\n return !_includesWith(eq, aItem, b);\n }, b, a);\n}\n\nfunction _equals(a, b, stackA, stackB) {\n if (_objectIs(a, b)) {\n return true;\n }\n\n var typeA = type(a);\n\n if (typeA !== type(b)) {\n return false;\n }\n\n if (a == null || b == null) {\n return false;\n }\n\n if (typeof a['fantasy-land/equals'] === 'function' || typeof b['fantasy-land/equals'] === 'function') {\n return typeof a['fantasy-land/equals'] === 'function' && a['fantasy-land/equals'](b) && typeof b['fantasy-land/equals'] === 'function' && b['fantasy-land/equals'](a);\n }\n\n if (typeof a.equals === 'function' || typeof b.equals === 'function') {\n return typeof a.equals === 'function' && a.equals(b) && typeof b.equals === 'function' && b.equals(a);\n }\n\n switch (typeA) {\n case 'Arguments':\n case 'Array':\n case 'Object':\n if (typeof a.constructor === 'function' && _functionName(a.constructor) === 'Promise') {\n return a === b;\n }\n\n break;\n\n case 'Boolean':\n case 'Number':\n case 'String':\n if (!(typeof a === typeof b && _objectIs(a.valueOf(), b.valueOf()))) {\n return false;\n }\n\n break;\n\n case 'Date':\n if (!_objectIs(a.valueOf(), b.valueOf())) {\n return false;\n }\n\n break;\n\n case 'Error':\n return a.name === b.name && a.message === b.message;\n\n case 'RegExp':\n if (!(a.source === b.source && a.global === b.global && a.ignoreCase === b.ignoreCase && a.multiline === b.multiline && a.sticky === b.sticky && a.unicode === b.unicode)) {\n return false;\n }\n\n break;\n }\n\n var idx = stackA.length - 1;\n\n while (idx >= 0) {\n if (stackA[idx] === a) {\n return stackB[idx] === b;\n }\n\n idx -= 1;\n }\n\n switch (typeA) {\n case 'Map':\n if (a.size !== b.size) {\n return false;\n }\n\n return _uniqContentEquals(a.entries(), b.entries(), stackA.concat([a]), stackB.concat([b]));\n\n case 'Set':\n if (a.size !== b.size) {\n return false;\n }\n\n return _uniqContentEquals(a.values(), b.values(), stackA.concat([a]), stackB.concat([b]));\n\n case 'Arguments':\n case 'Array':\n case 'Object':\n case 'Boolean':\n case 'Number':\n case 'String':\n case 'Date':\n case 'Error':\n case 'RegExp':\n case 'Int8Array':\n case 'Uint8Array':\n case 'Uint8ClampedArray':\n case 'Int16Array':\n case 'Uint16Array':\n case 'Int32Array':\n case 'Uint32Array':\n case 'Float32Array':\n case 'Float64Array':\n case 'ArrayBuffer':\n break;\n\n default:\n // Values of other types are only equal if identical.\n return false;\n }\n\n var keysA = keys(a);\n\n if (keysA.length !== keys(b).length) {\n return false;\n }\n\n var extendedStackA = stackA.concat([a]);\n var extendedStackB = stackB.concat([b]);\n idx = keysA.length - 1;\n\n while (idx >= 0) {\n var key = keysA[idx];\n\n if (!(_has(key, b) && _equals(b[key], a[key], extendedStackA, extendedStackB))) {\n return false;\n }\n\n idx -= 1;\n }\n\n return true;\n}\n\nmodule.exports = _equals;","function _arrayFromIterator(iter) {\n var list = [];\n var next;\n\n while (!(next = iter.next()).done) {\n list.push(next.value);\n }\n\n return list;\n}\n\nmodule.exports = _arrayFromIterator;","function _includesWith(pred, x, list) {\n var idx = 0;\n var len = list.length;\n\n while (idx < len) {\n if (pred(x, list[idx])) {\n return true;\n }\n\n idx += 1;\n }\n\n return false;\n}\n\nmodule.exports = _includesWith;","function _functionName(f) {\n // String(x => x) evaluates to \"x => x\", so the pattern may not match.\n var match = String(f).match(/^function (\\w*)/);\n return match == null ? '' : match[1];\n}\n\nmodule.exports = _functionName;","// Based on https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\nfunction _objectIs(a, b) {\n // SameValue algorithm\n if (a === b) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return a !== 0 || 1 / a === 1 / b;\n } else {\n // Step 6.a: NaN == NaN\n return a !== a && b !== b;\n }\n}\n\nmodule.exports = typeof Object.is === 'function' ? Object.is : _objectIs;","var _curry1 =\n/*#__PURE__*/\nrequire(\"./internal/_curry1\");\n\nvar _has =\n/*#__PURE__*/\nrequire(\"./internal/_has\");\n\nvar _isArguments =\n/*#__PURE__*/\nrequire(\"./internal/_isArguments\"); // cover IE < 9 keys issues\n\n\nvar hasEnumBug = !\n/*#__PURE__*/\n{\n toString: null\n}.propertyIsEnumerable('toString');\nvar nonEnumerableProps = ['constructor', 'valueOf', 'isPrototypeOf', 'toString', 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; // Safari bug\n\nvar hasArgsEnumBug =\n/*#__PURE__*/\nfunction () {\n 'use strict';\n\n return arguments.propertyIsEnumerable('length');\n}();\n\nvar contains = function contains(list, item) {\n var idx = 0;\n\n while (idx < list.length) {\n if (list[idx] === item) {\n return true;\n }\n\n idx += 1;\n }\n\n return false;\n};\n/**\n * Returns a list containing the names of all the enumerable own properties of\n * the supplied object.\n * Note that the order of the output array is not guaranteed to be consistent\n * across different JS platforms.\n *\n * @func\n * @memberOf R\n * @since v0.1.0\n * @category Object\n * @sig {k: v} -> [k]\n * @param {Object} obj The object to extract properties from\n * @return {Array} An array of the object's own properties.\n * @see R.keysIn, R.values\n * @example\n *\n * R.keys({a: 1, b: 2, c: 3}); //=> ['a', 'b', 'c']\n */\n\n\nvar keys = typeof Object.keys === 'function' && !hasArgsEnumBug ?\n/*#__PURE__*/\n_curry1(function keys(obj) {\n return Object(obj) !== obj ? [] : Object.keys(obj);\n}) :\n/*#__PURE__*/\n_curry1(function keys(obj) {\n if (Object(obj) !== obj) {\n return [];\n }\n\n var prop, nIdx;\n var ks = [];\n\n var checkArgsLength = hasArgsEnumBug && _isArguments(obj);\n\n for (prop in obj) {\n if (_has(prop, obj) && (!checkArgsLength || prop !== 'length')) {\n ks[ks.length] = prop;\n }\n }\n\n if (hasEnumBug) {\n nIdx = nonEnumerableProps.length - 1;\n\n while (nIdx >= 0) {\n prop = nonEnumerableProps[nIdx];\n\n if (_has(prop, obj) && !contains(ks, prop)) {\n ks[ks.length] = prop;\n }\n\n nIdx -= 1;\n }\n }\n\n return ks;\n});\nmodule.exports = keys;","var _curry1 =\n/*#__PURE__*/\nrequire(\"./internal/_curry1\");\n/**\n * Gives a single-word string description of the (native) type of a value,\n * returning such answers as 'Object', 'Number', 'Array', or 'Null'. Does not\n * attempt to distinguish user Object types any further, reporting them all as\n * 'Object'.\n *\n * @func\n * @memberOf R\n * @since v0.8.0\n * @category Type\n * @sig (* -> {*}) -> String\n * @param {*} val The value to test\n * @return {String}\n * @example\n *\n * R.type({}); //=> \"Object\"\n * R.type(1); //=> \"Number\"\n * R.type(false); //=> \"Boolean\"\n * R.type('s'); //=> \"String\"\n * R.type(null); //=> \"Null\"\n * R.type([]); //=> \"Array\"\n * R.type(/[A-z]/); //=> \"RegExp\"\n * R.type(() => {}); //=> \"Function\"\n * R.type(undefined); //=> \"Undefined\"\n */\n\n\nvar type =\n/*#__PURE__*/\n_curry1(function type(val) {\n return val === null ? 'Null' : val === undefined ? 'Undefined' : Object.prototype.toString.call(val).slice(8, -1);\n});\n\nmodule.exports = type;"],"sourceRoot":""} \ No newline at end of file diff --git a/assets/static/js/edtrServices.7f51b510.js.map b/assets/static/js/edtrServices.7f51b510.js.map deleted file mode 100644 index 78c4eb7b07b..00000000000 --- a/assets/static/js/edtrServices.7f51b510.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["../webpack/bootstrap","../external \"React\"","../node_modules/react/jsx-runtime.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/objectSpread2.js","../external [\"eventespresso\",\"i18n\"]","../external \"R\"","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/slicedToArray.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/iterableToArrayLimit.js","../external [\"eventespresso\",\"predicates\"]","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/defineProperty.js","../external [\"eventespresso\",\"utils\"]","../external [\"eventespresso\",\"data\"]","../external [\"eventespresso\",\"services\"]","../external [\"eventespresso\",\"hooks\"]","../external [\"eventespresso\",\"adapters\"]","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/toConsumableArray.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/arrayWithoutHoles.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/nonIterableSpread.js","../node_modules/@babel/runtime/regenerator/index.js","../external [\"eventespresso\",\"constants\"]","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/classCallCheck.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/arrayLikeToArray.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/asyncToGenerator.js","../external [\"eventespresso\",\"registry\"]","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/getPrototypeOf.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/createClass.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/taggedTemplateLiteral.js","../external [\"eventespresso\",\"dates\"]","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/inherits.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/possibleConstructorReturn.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/createSuper.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/arrayWithHoles.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/nonIterableRest.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/get.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/superPropBase.js","../node_modules/invariant/browser.js","../node_modules/object-assign/index.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/iterableToArray.js","../packages/edtr-services/src/constants.ts","../node_modules/react/cjs/react-jsx-runtime.production.min.js","../packages/edtr-services/src/apollo/queries/index.ts","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/createForOfIteratorHelper.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/assertThisInitialized.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/typeof.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/isNativeReflectConstruct.js","../node_modules/lodash/_root.js","../node_modules/lodash/isArray.js","../node_modules/property-expr/index.js","../external [\"eventespresso\",\"ioc\"]","../node_modules/lodash/_getNative.js","../node_modules/lodash/has.js","../node_modules/webpack/buildin/global.js","../packages/edtr-services/src/hooks/useEventsHandler.ts","../packages/edtr-services/src/hooks/useRegistrationsLink.ts","../node_modules/regenerator-runtime/runtime.js","../external [\"eventespresso\",\"toaster\"]","../packages/edtr-services/src/apollo/mutations/tickets/index.ts","../packages/edtr-services/src/apollo/queries/tickets/useTickets.ts","../packages/edtr-services/src/hooks/entityListCacheUpdates/useUpdateEntityList.ts","../packages/edtr-services/src/apollo/mutations/datetimes/index.ts","../packages/edtr-services/src/apollo/queries/tickets/queries.ts","../node_modules/lodash/_baseGetTag.js","../node_modules/lodash/isObjectLike.js","../node_modules/lodash/toString.js","../packages/edtr-services/src/apollo/queries/datetimes/queries.ts","../packages/edtr-services/src/apollo/mutations/utils.ts","../node_modules/nanoclone/src/index.js","../node_modules/yup/es/util/printValue.js","../node_modules/yup/es/locale.js","../node_modules/yup/es/util/isSchema.js","../node_modules/yup/es/Condition.js","../node_modules/yup/es/util/toArray.js","../node_modules/yup/es/ValidationError.js","../node_modules/yup/es/util/runTests.js","../node_modules/yup/es/Reference.js","../node_modules/yup/es/util/createValidation.js","../node_modules/yup/es/util/reach.js","../node_modules/yup/es/util/ReferenceSet.js","../node_modules/yup/es/schema.js","../node_modules/yup/es/mixed.js","../node_modules/yup/es/util/isAbsent.js","../node_modules/yup/es/boolean.js","../node_modules/yup/es/string.js","../node_modules/yup/es/number.js","../node_modules/yup/es/util/isodate.js","../node_modules/yup/es/date.js","../node_modules/yup/es/util/sortFields.js","../node_modules/yup/es/util/sortByKeyOrder.js","../node_modules/yup/es/object.js","../node_modules/yup/es/array.js","../external [\"eventespresso\",\"slotFill\"]","../packages/edtr-services/src/apollo/queries/datetimes/useDatetimes.ts","../packages/edtr-services/src/apollo/mutations/prices/index.ts","../types/index.ts","../packages/edtr-services/src/apollo/index.ts","../node_modules/lodash/_Symbol.js","../node_modules/lodash/_nativeCreate.js","../node_modules/lodash/_ListCache.js","../node_modules/lodash/_assocIndexOf.js","../node_modules/lodash/_getMapData.js","../node_modules/lodash/_toKey.js","../packages/edtr-services/src/apollo/mutations/types.ts","../node_modules/lodash/mapValues.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/construct.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/wrapNativeSuper.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/isNativeFunction.js","../external [\"eventespresso\",\"storage\"]","../packages/edtr-services/src/apollo/queries/datetimes/useDatetimeQueryOptions.ts","../packages/edtr-services/src/apollo/queries/tickets/useTicketQueryOptions.ts","../packages/edtr-services/src/apollo/queries/events/useEventId.ts","../packages/edtr-services/src/apollo/mutations/useUpdateCallback.ts","../packages/edtr-services/src/apollo/queries/prices/queries.ts","../node_modules/webpack/buildin/module.js","../packages/edtr-services/src/filterState/index.ts","../node_modules/lodash/_isKey.js","../node_modules/lodash/isSymbol.js","../node_modules/lodash/_MapCache.js","../node_modules/lodash/isObject.js","../node_modules/lodash/_Map.js","../node_modules/lodash/isLength.js","../node_modules/lodash/keys.js","../node_modules/lodash/snakeCase.js","../packages/edtr-services/src/context/ContextProvider.tsx","../packages/edtr-services/src/context/withEdtrContext.tsx","../packages/edtr-services/src/context/EntityListContext/datetimes/DatetimesListProvider.tsx","../packages/edtr-services/src/context/EntityListContext/tickets/TicketsListProvider.tsx","../packages/edtr-services/src/context/EntityListContext/withEntityListContext.tsx","../packages/edtr-services/src/apollo/queries/datetimes/useDatetimeIds.ts","../packages/edtr-services/src/apollo/queries/datetimes/useDatetimeItem.ts","../packages/edtr-services/src/apollo/queries/datetimes/useRelatedDatetimes.ts","../packages/edtr-services/src/apollo/queries/prices/useRelatedPrices.ts","../packages/edtr-services/src/apollo/mutations/events/index.ts","../packages/edtr-services/src/filterState/types.ts","../packages/edtr-services/src/apollo/queries/prices/usePriceQueryOptions.ts","../packages/edtr-services/src/apollo/mutations/tickets/useUpdateTicketCache.ts","../packages/edtr-services/src/apollo/mutations/useBulkDeleteEntities.ts","../node_modules/ramda/src/internal/_curry1.js","../packages/edtr-services/src/apollo/mutations/index.ts","../node_modules/lodash/_hasPath.js","../node_modules/lodash/_castPath.js","../node_modules/lodash/_freeGlobal.js","../node_modules/lodash/isFunction.js","../node_modules/lodash/_toSource.js","../node_modules/lodash/eq.js","../node_modules/lodash/isArguments.js","../node_modules/lodash/_isIndex.js","../node_modules/lodash/_baseAssignValue.js","../node_modules/lodash/_baseForOwn.js","../node_modules/lodash/isBuffer.js","../node_modules/lodash/isTypedArray.js","../node_modules/lodash/_baseIteratee.js","../node_modules/lodash/_Stack.js","../node_modules/lodash/_baseIsEqual.js","../node_modules/lodash/_equalArrays.js","../node_modules/lodash/_isStrictComparable.js","../node_modules/lodash/_matchesStrictComparable.js","../node_modules/lodash/_baseGet.js","../node_modules/lodash/_createCompounder.js","../node_modules/lodash/_hasUnicode.js","../packages/edtr-services/src/apollo/queries/events/queries.ts","../packages/edtr-services/src/apollo/queries/prices/usePrices.ts","../packages/edtr-services/src/apollo/queries/priceTypes/usePriceTypeQueryOptions.ts","../packages/edtr-services/src/apollo/queries/venues/useVenueQueryOptions.ts","../packages/edtr-services/src/context/EntityListContext/datetimes/DatesFilterStateProvider.tsx","../packages/edtr-services/src/context/EntityListContext/datetimes/FilteredDatesProvider.tsx","../packages/edtr-services/src/context/EntityListContext/tickets/TicketsFilterStateProvider.tsx","../packages/edtr-services/src/context/EntityListContext/tickets/FilteredTicketsProvider.tsx","../external [\"wp\",\"url\"]","../node_modules/lodash/camelCase.js","../node_modules/lodash/mapKeys.js","../node_modules/toposort/index.js","../packages/edtr-services/src/hooks/entityListCacheUpdates/useUpdateDatetimeList.ts","../packages/edtr-services/src/hooks/entityListCacheUpdates/useUpdateTicketList.ts","../packages/edtr-services/src/apollo/queries/events/index.ts","../packages/edtr-services/src/apollo/queries/tickets/useDefaultTickets.ts","../packages/edtr-services/src/apollo/queries/tickets/useDefaultTicketIds.ts","../packages/edtr-services/src/apollo/queries/tickets/useTicketIds.ts","../packages/edtr-services/src/apollo/queries/tickets/useTicketItem.ts","../packages/edtr-services/src/apollo/queries/tickets/useTicketPrices.ts","../packages/edtr-services/src/apollo/queries/tickets/useCappedQuantity.ts","../packages/edtr-services/src/apollo/queries/priceTypes/usePriceTypes.ts","../packages/edtr-services/src/apollo/queries/priceTypes/useDefaultPriceType.ts","../packages/edtr-services/src/apollo/queries/priceTypes/usePriceTypeForPrice.ts","../packages/edtr-services/src/apollo/mutations/datetimes/useDeleteRelatedTickets.ts","../packages/edtr-services/src/ioc/index.ts","../packages/edtr-services/src/apollo/mutations/tickets/useBulkEditTickets.ts","../packages/edtr-services/src/apollo/queries/events/useEventGuid.ts","../packages/edtr-services/src/apollo/queries/events/useEventQueryOptions.ts","../packages/edtr-services/src/apollo/queries/priceTypes/queries.ts","../packages/edtr-services/src/apollo/mutations/datetimes/useUpdateDatetimeCache.ts","../packages/edtr-services/src/apollo/mutations/datetimes/updateTicketCache.ts","../packages/edtr-services/src/apollo/mutations/datetimes/useOnUpdateDatetime.ts","../packages/edtr-services/src/apollo/mutations/datetimes/useOnDeleteDatetime.ts","../packages/edtr-services/src/apollo/mutations/tickets/useOnDeleteTicket.ts","../packages/edtr-services/src/apollo/mutations/tickets/updatePriceCache.ts","../packages/edtr-services/src/apollo/mutations/useReorderEntities.ts","../packages/edtr-services/src/apollo/mutations/tickets/useOnUpdateTicket.ts","../packages/edtr-services/src/apollo/mutations/tickets/useAffectedDatesQueries.ts","../node_modules/ramda/src/internal/_has.js","../node_modules/lodash/_baseHas.js","../node_modules/lodash/_getRawTag.js","../node_modules/lodash/_objectToString.js","../node_modules/lodash/_stringToPath.js","../node_modules/lodash/_memoizeCapped.js","../node_modules/lodash/memoize.js","../node_modules/lodash/_mapCacheClear.js","../node_modules/lodash/_Hash.js","../node_modules/lodash/_hashClear.js","../node_modules/lodash/_baseIsNative.js","../node_modules/lodash/_isMasked.js","../node_modules/lodash/_coreJsData.js","../node_modules/lodash/_getValue.js","../node_modules/lodash/_hashDelete.js","../node_modules/lodash/_hashGet.js","../node_modules/lodash/_hashHas.js","../node_modules/lodash/_hashSet.js","../node_modules/lodash/_listCacheClear.js","../node_modules/lodash/_listCacheDelete.js","../node_modules/lodash/_listCacheGet.js","../node_modules/lodash/_listCacheHas.js","../node_modules/lodash/_listCacheSet.js","../node_modules/lodash/_mapCacheDelete.js","../node_modules/lodash/_isKeyable.js","../node_modules/lodash/_mapCacheGet.js","../node_modules/lodash/_mapCacheHas.js","../node_modules/lodash/_mapCacheSet.js","../node_modules/lodash/_baseToString.js","../node_modules/lodash/_arrayMap.js","../node_modules/lodash/_baseIsArguments.js","../node_modules/lodash/_defineProperty.js","../node_modules/lodash/_baseFor.js","../node_modules/lodash/_createBaseFor.js","../node_modules/lodash/_arrayLikeKeys.js","../node_modules/lodash/_baseTimes.js","../node_modules/lodash/stubFalse.js","../node_modules/lodash/_baseIsTypedArray.js","../node_modules/lodash/_baseUnary.js","../node_modules/lodash/_nodeUtil.js","../node_modules/lodash/_baseKeys.js","../node_modules/lodash/_isPrototype.js","../node_modules/lodash/_nativeKeys.js","../node_modules/lodash/_overArg.js","../node_modules/lodash/isArrayLike.js","../node_modules/lodash/_baseMatches.js","../node_modules/lodash/_baseIsMatch.js","../node_modules/lodash/_stackClear.js","../node_modules/lodash/_stackDelete.js","../node_modules/lodash/_stackGet.js","../node_modules/lodash/_stackHas.js","../node_modules/lodash/_stackSet.js","../node_modules/lodash/_baseIsEqualDeep.js","../node_modules/lodash/_SetCache.js","../node_modules/lodash/_setCacheAdd.js","../node_modules/lodash/_setCacheHas.js","../node_modules/lodash/_arraySome.js","../node_modules/lodash/_cacheHas.js","../node_modules/lodash/_equalByTag.js","../node_modules/lodash/_Uint8Array.js","../node_modules/lodash/_mapToArray.js","../node_modules/lodash/_setToArray.js","../node_modules/lodash/_equalObjects.js","../node_modules/lodash/_getAllKeys.js","../node_modules/lodash/_baseGetAllKeys.js","../node_modules/lodash/_arrayPush.js","../node_modules/lodash/_getSymbols.js","../node_modules/lodash/_arrayFilter.js","../node_modules/lodash/stubArray.js","../node_modules/lodash/_getTag.js","../node_modules/lodash/_DataView.js","../node_modules/lodash/_Promise.js","../node_modules/lodash/_Set.js","../node_modules/lodash/_WeakMap.js","../node_modules/lodash/_getMatchData.js","../node_modules/lodash/_baseMatchesProperty.js","../node_modules/lodash/get.js","../node_modules/lodash/hasIn.js","../node_modules/lodash/_baseHasIn.js","../node_modules/lodash/identity.js","../node_modules/lodash/property.js","../node_modules/lodash/_baseProperty.js","../node_modules/lodash/_basePropertyDeep.js","../node_modules/lodash/_arrayReduce.js","../node_modules/lodash/deburr.js","../node_modules/lodash/_deburrLetter.js","../node_modules/lodash/_basePropertyOf.js","../node_modules/lodash/words.js","../node_modules/lodash/_asciiWords.js","../node_modules/lodash/_hasUnicodeWord.js","../node_modules/lodash/_unicodeWords.js","../node_modules/lodash/capitalize.js","../node_modules/lodash/upperFirst.js","../node_modules/lodash/_createCaseFirst.js","../node_modules/lodash/_castSlice.js","../node_modules/lodash/_baseSlice.js","../node_modules/lodash/_stringToArray.js","../node_modules/lodash/_asciiToArray.js","../node_modules/lodash/_unicodeToArray.js","../packages/edtr-services/src/apollo/queries/venues/useVenues.ts","../packages/edtr-services/src/apollo/queries/datetimes/useLazyDatetime.ts","../packages/edtr-services/src/apollo/queries/tickets/useLazyTicket.ts","../packages/edtr-services/src/apollo/queries/tickets/useRelatedTickets.ts","../packages/edtr-services/src/apollo/queries/venues/queries.ts","../packages/edtr-services/src/hooks/entityListCacheUpdates/useUpdatePriceList.ts","../packages/edtr-services/src/apollo/mutations/tickets/useBulkDeleteTickets.ts","../packages/edtr-services/src/filterState/datetimes/useDatesListFilterState.ts","../packages/edtr-services/src/hooks/edtrState/useVisibleDatetimeIds.ts","../packages/edtr-services/src/filterState/tickets/useTicketsListFilterState.ts","../packages/edtr-services/src/hooks/edtrState/useVisibleTicketIds.ts","../packages/edtr-services/src/filterState/datetimes/reducer.ts","../packages/edtr-services/src/filterState/datetimes/useDatesListFilterStateManager.ts","../packages/edtr-services/src/filterState/tickets/reducer.ts","../packages/edtr-services/src/filterState/tickets/useTicketsListFilterStateManager.ts","../packages/edtr-services/src/apollo/queries/events/useEvent.ts","../node_modules/ramda/src/internal/_isPlaceholder.js","../node_modules/ramda/src/internal/_isArguments.js","../packages/edtr-services/src/hooks/entityListCacheUpdates/useUpdatePriceTypeList.ts","../packages/edtr-services/src/hooks/entityListCacheUpdates/useUpdateVenueList.ts","../packages/edtr-services/src/apollo/mutations/datetimes/useBulkEditDatetimes.ts","../packages/edtr-services/src/apollo/mutations/datetimes/useBulkDeleteDatetimes.ts","../packages/edtr-services/src/apollo/mutations/datetimes/useReorderDatetimes.ts","../packages/edtr-services/src/apollo/mutations/tickets/useReorderTickets.ts","../packages/edtr-services/src/apollo/mutations/tickets/useUpdateTicketQtyByCapacity.ts","../packages/edtr-services/src/apollo/mutations/prices/useBulkDeletePrices.ts","../packages/edtr-services/src/apollo/types.ts","../packages/edtr-services/src/filterState/datetimes/index.ts","../packages/edtr-services/src/filterState/datetimes/useFilteredDateIds.ts","../packages/edtr-services/src/filterState/tickets/index.ts","../packages/edtr-services/src/filterState/tickets/useFilteredTicketIds.ts","../packages/edtr-services/src/forms/index.ts","../packages/edtr-services/src/types.ts","../packages/edtr-services/src/apollo/mutations/prices/useMutationVariables.ts","../packages/edtr-services/src/apollo/mutations/prices/useUpdatePriceCache.ts","../packages/edtr-services/src/apollo/mutations/prices/useOnCreatePrice.ts","../packages/edtr-services/src/apollo/mutations/prices/useOnDeletePrice.ts","../packages/edtr-services/src/apollo/mutations/prices/useOnUpdatePrice.ts","../packages/edtr-services/src/apollo/mutations/prices/constants.ts","../packages/edtr-services/src/apollo/mutations/prices/useMutationHandler.ts","../packages/edtr-services/src/apollo/mutations/prices/usePriceMutator.ts","../packages/edtr-services/src/apollo/mutations/datetimes/useMutationVariables.ts","../packages/edtr-services/src/apollo/mutations/datetimes/useOnCreateDatetime.ts","../packages/edtr-services/src/apollo/mutations/datetimes/useOptimisticResponse.ts","../packages/edtr-services/src/apollo/mutations/datetimes/constants.ts","../packages/edtr-services/src/apollo/mutations/datetimes/useMutationHandler.ts","../packages/edtr-services/src/apollo/mutations/datetimes/useDatetimeMutator.ts","../packages/edtr-services/src/apollo/mutations/tickets/useMutationVariables.ts","../packages/edtr-services/src/apollo/mutations/tickets/useOnCreateTicket.ts","../packages/edtr-services/src/apollo/mutations/tickets/useOptimisticResponse.ts","../packages/edtr-services/src/apollo/mutations/tickets/constants.ts","../packages/edtr-services/src/apollo/mutations/tickets/useMutationHandler.ts","../packages/edtr-services/src/apollo/mutations/tickets/useTicketMutator.ts","../packages/edtr-services/src/utils/dateAndTime.ts","../packages/edtr-services/src/utils/filterCells.ts","../packages/edtr-services/src/utils/misc.ts","../packages/edtr-services/src/apollo/initialization/useCacheRehydrationData.ts","../packages/edtr-services/src/apollo/initialization/useCacheRehydration.ts","../packages/edtr-services/src/apollo/mutations/events/useOptimisticResponse.ts","../packages/edtr-services/src/apollo/mutations/events/useMutationHandler.ts","../packages/edtr-services/src/apollo/mutations/events/useEventMutator.ts","../packages/edtr-services/src/slots/NewDateOptions.ts","../packages/edtr-services/src/apollo/meta/useTicketsMeta.ts","../packages/edtr-services/src/apollo/queries/users/useEventManagers.ts","../packages/edtr-services/src/filterState/tickets/useIsChainedFilter.ts","../packages/edtr-services/src/filterState/tickets/useRegisterIsChainedFilter.ts","../node_modules/ramda/src/isEmpty.js","../packages/edtr-services/src/index.ts","../node_modules/ramda/src/empty.js","../node_modules/ramda/src/internal/_isArray.js","../node_modules/ramda/src/internal/_isObject.js","../node_modules/ramda/src/internal/_isString.js","../node_modules/ramda/src/equals.js","../node_modules/ramda/src/internal/_curry2.js","../node_modules/ramda/src/internal/_equals.js","../node_modules/ramda/src/internal/_arrayFromIterator.js","../node_modules/ramda/src/internal/_includesWith.js","../node_modules/ramda/src/internal/_functionName.js","../node_modules/ramda/src/internal/_objectIs.js","../node_modules/ramda/src/keys.js","../node_modules/ramda/src/type.js"],"names":["installedModules","__webpack_require__","moduleId","exports","module","i","l","modules","call","m","c","d","name","getter","o","Object","defineProperty","enumerable","get","r","Symbol","toStringTag","value","t","mode","__esModule","ns","create","key","bind","n","object","property","prototype","hasOwnProperty","p","s","window","require","ownKeys","enumerableOnly","keys","getOwnPropertySymbols","symbols","filter","sym","getOwnPropertyDescriptor","push","apply","_objectSpread2","target","arguments","length","source","forEach","getOwnPropertyDescriptors","defineProperties","_objectWithoutProperties","excluded","sourceKeys","indexOf","sourceSymbolKeys","propertyIsEnumerable","_slicedToArray","arr","arrayWithHoles","iterator","_arr","_n","_d","_e","undefined","_s","_i","next","done","err","unsupportedIterableToArray","nonIterableRest","_defineProperty","obj","configurable","writable","_toConsumableArray","Array","isArray","arrayLikeToArray","iterableToArray","TypeError","_classCallCheck","instance","Constructor","_arrayLikeToArray","len","arr2","_unsupportedIterableToArray","minLen","toString","slice","constructor","from","test","asyncGeneratorStep","gen","resolve","reject","_next","_throw","arg","info","error","Promise","then","_asyncToGenerator","fn","self","this","args","_getPrototypeOf","setPrototypeOf","getPrototypeOf","__proto__","_defineProperties","props","descriptor","_createClass","protoProps","staticProps","_taggedTemplateLiteral","strings","raw","freeze","_inherits","subClass","superClass","_possibleConstructorReturn","assertThisInitialized","_createSuper","Derived","hasNativeReflectConstruct","isNativeReflectConstruct","result","Super","NewTarget","Reflect","construct","_arrayWithHoles","_nonIterableRest","receiver","base","desc","condition","format","a","b","e","f","Error","argIndex","replace","framesToPop","propIsEnumerable","toObject","val","assign","test1","String","getOwnPropertyNames","test2","fromCharCode","map","join","test3","split","letter","shouldUseNative","to","_iterableToArray","iter","domain","datesList","ticketsList","TICKET_FIELDS_FOR_TPC","SINGULAR_ENTITY_NAME","DATETIME","__","EVENT","TICKET","PRICE","PRICE_TYPE","g","Fragment","for","h","__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED","ReactCurrentOwner","ref","__self","__source","q","k","defaultProps","$$typeof","type","_owner","current","jsx","jsxs","DEFAULT_ENTITY_LIST_DATA","nodes","__typename","DEFAULT_DATETIME_LIST_DATA","DEFAULT_TICKET_LIST_DATA","DEFAULT_PRICE_LIST_DATA","DEFAULT_PRICE_TYPE_LIST_DATA","DEFAULT_VENUE_LIST_DATA","_createForOfIteratorHelper","allowArrayLike","it","F","normalCompletion","didErr","step","_e2","_assertThisInitialized","ReferenceError","_setPrototypeOf","_typeof","_isNativeReflectConstruct","sham","Proxy","Date","freeGlobal","freeSelf","root","Function","Cache","maxSize","_maxSize","clear","_size","_values","set","SPLIT_REGEX","DIGIT_REGEX","LEAD_DIGIT_REGEX","SPEC_CHAR_REGEX","CLEAN_QUOTES_REGEX","pathCache","setCache","getCache","normalizePath","path","part","match","isQuoted","str","charAt","shouldBeQuoted","hasLeadingNumber","hasSpecialChars","setter","parts","index","data","safe","segments","reduce","cb","thisArg","idx","isBracket","baseIsNative","getValue","baseHas","hasPath","useEventsHandler","toaster","useSystemNotifications","onError","useCallback","message","useEffect","events","on","off","useRegistrationsLink","siteUrl","useConfig","eventId","useEventId","useMemo","adminUrl","getAdminUrl","adminSiteUrl","admin","page","ADMIN_ROUTES","REGISTRATIONS","addQueryArgs","_objectSpread","event_id","return","runtime","Op","hasOwn","$Symbol","iteratorSymbol","asyncIteratorSymbol","asyncIterator","toStringTagSymbol","define","wrap","innerFn","outerFn","tryLocsList","protoGenerator","Generator","generator","context","Context","_invoke","state","GenStateSuspendedStart","method","GenStateExecuting","GenStateCompleted","doneResult","delegate","delegateResult","maybeInvokeDelegate","ContinueSentinel","sent","_sent","dispatchException","abrupt","record","tryCatch","GenStateSuspendedYield","makeInvokeMethod","GeneratorFunction","GeneratorFunctionPrototype","IteratorPrototype","getProto","NativeIteratorPrototype","values","Gp","defineIteratorMethods","AsyncIterator","PromiseImpl","invoke","__await","unwrapped","previousPromise","callInvokeWithMethodAndArg","resultName","nextLoc","pushTryEntry","locs","entry","tryLoc","catchLoc","finallyLoc","afterLoc","tryEntries","resetTryEntry","completion","reset","iterable","iteratorMethod","isNaN","displayName","isGeneratorFunction","genFun","ctor","mark","awrap","async","reverse","pop","skipTempReset","prev","stop","rootRecord","rval","exception","handle","loc","caught","hasCatch","hasFinally","finallyEntry","complete","finish","thrown","delegateYield","regeneratorRuntime","accidentalStrictMode","TICKET_PRICES_ATTRIBUTE","gql","_templateObject","PRICE_ATTRIBUTES","CREATE_TICKET","_templateObject2","TICKET_ATTRIBUTES","UPDATE_TICKET","_templateObject3","DELETE_TICKET","_templateObject4","BULK_UPDATE_TICKETS","_templateObject5","useTickets","_data$espressoTickets","filterBy","isNotDefault","options","useTicketQueryOptions","_useTicketsQuery","useTicketsQuery","espressoTickets","cacheIds","getCacheIds","useUpdateEntityList","writeQueryOptions","useUpdateCache","CREATE_DATETIME","DATETIME_ATTRIBUTES","UPDATE_DATETIME","DELETE_DATETIME","BULK_UPDATE_DATETIMES","GET_TICKET","GET_TICKETS","getRawTag","objectToString","symToStringTag","baseToString","GET_DATETIME","GET_DATETIMES","formToBulkUpdateInput","formData","allEntities","selectedIds","shiftDates","uniqueInputs","unit","selectedEntities","entitiesWithGuIdInArray","shiftTheDate","shiftDate","entity","startDate","toISOString","endDate","id","sharedInput","cacheNodesFromBulkInput","input","inputs","currentInput","node","cacheId","uuid","cacheNodesFromBulkDelete","entityIds","deletePermanently","entitiesWithGuIdNotInArray","includes","isTrashed","updateDatetimeFlags","date","isActive","isExpired","isUpcoming","updateTicketFlags","ticket","isFree","price","isOnSale","isPending","Map","_","Set","baseClone","src","circulars","clones","nodeType","cloneNode","getTime","RegExp","clone","entries","findIndex","errorToString","regExpToString","symbolToString","SYMBOL_REGEXP","printNumber","printSimpleValue","quoteStrings","typeOf","concat","tag","printValue","JSON","stringify","mixed","default","required","oneOf","notOneOf","notType","_ref","originalValue","isCast","msg","defined","string","min","max","matches","email","url","trim","lowercase","uppercase","number","lessThan","moreThan","positive","negative","integer","boolean","isValue","noUnknown","array","isSchema","__isYupSchema__","Condition","refs","has","otherwise","is","check","_len","_key","every","_len2","_key2","schema","branch","parent","toArray","_extends","strReg","ValidationError","_Error","_super","errorOrErrors","field","_this","errors","params","inner","_this$errors","isError","captureStackTrace","label","_wrapNativeSuper","runTests","endEarly","tests","sort","callback","fired","once","count","nestedErrors","prefixes","Reference","isContext","isSibling","prefix","__isYupRef","createValidation","config","validate","_ref$path","sync","rest","_objectWithoutPropertiesLoose","item","Ref","isRef","createError","overrides","nextParams","mapValues","formatError","ctx","_ref2","validOrError","catch","OPTIONS","substr","getIn","lastPart","lastPartDebug","_part","innerType","parseInt","fields","_type","parentPath","ReferenceSet","list","size","_step","description","_iterator","_step2","_iterator2","describe","acc","add","delete","newItems","removeItems","BaseSchema","deps","transforms","conditions","_mutate","_typeError","_whitelist","_blacklist","exclusiveTests","spec","withMutation","typeError","locale","strip","strict","abortEarly","recursive","nullable","presence","_value","_whitelistError","_blacklistError","cloneDeep","meta","before","combined","mergedSpec","merge","v","_typeCheck","resolvedSchema","_cast","assert","isType","formattedValue","formattedResult","rawValue","_options","_this2","getDefault","_this3","_options$from","_options$originalValu","_options$strict","_options$abortEarly","initialTests","finalTests","maybeCb","_validate","validateSync","defaultValue","_getDefault","def","isStrict","exclusive","_isPresent","isNullable","opts","isExclusive","dep","enums","valids","resolved","resolveAll","invalids","_next$spec","_loop","_getIn","_i2","_arr2","alias","_i3","_arr3","optional","notRequired","Mixed","isAbsent","BooleanSchema","_BaseSchema","transform","Boolean","valueOf","rEmail","rUrl","rUUID","isTrimmed","objStringTag","StringSchema","strValue","_get","regex","excludeEmptyString","_options$excludeEmpty","search","toLowerCase","toUpperCase","NumberSchema","parsed","NaN","parseFloat","Number","less","more","isInteger","_method","avail","truncate","Math","isoReg","invalidDate","DateSchema","timestamp","struct","numericKeys","minutesOffset","exec","UTC","parse","isoParse","param","cast","limit","prepareParam","INVALID_DATE","sortFields","excludedEdges","edges","excludes","addNode","depPath","toposort","Infinity","some","ii","_err$path","sortByKeyOrder","isObject","unknown","known","defaultSort","ObjectSchema","_sortErrors","_nodes","_excludedEdges","shape","_options$stripUnknown","stripUnknown","intermediateValue","innerOptions","__validating","isChanged","prop","exists","fieldValue","inputValue","fieldSpec","_opts$from","_opts$originalValue","_opts$abortEarly","_opts$recursive","_this4","nextFields","_Object$entries","_Object$entries$_i","schemaOrRef","_this5","dft","getDefaultFromShape","additions","picked","_step3","_iterator3","fromGetter","newObj","noAllow","unknownKeys","allow","mapKeys","transformKeys","camelCase","snakeCase","ArraySchema","_opts","castArray","castElement","_options$recursive","original","rejector","useDatetimes","_data$espressoDatetim","useDatetimeQueryOptions","useDatetimesQuery","espressoDatetimes","useMemoStringify","CREATE_PRICE","UPDATE_PRICE","DELETE_PRICE","nativeCreate","getNative","listCacheClear","listCacheDelete","listCacheGet","listCacheHas","listCacheSet","ListCache","eq","isKeyable","__data__","isSymbol","TypeName","baseAssignValue","baseForOwn","baseIteratee","iteratee","Parent","Class","_cache","Wrapper","query","variables","where","queryArgs","includeDefaultTickets","_window","_window$eventEspresso","_window$eventEspresso2","_window$eventEspresso3","eventEspressoData","eventEditor","event","dbId","useUpdateCallback","typeName","onUpdate","mutationType","cache","pathOr","PRICE_BASE_TYPE_ATTRIBUTE","PRICE_TYPE_ATTRIBUTES","GET_PRICE","GET_PRICES","webpackPolyfill","deprecate","paths","children","reIsDeepProp","reIsPlainProp","baseGetTag","isObjectLike","mapCacheClear","mapCacheDelete","mapCacheGet","mapCacheHas","mapCacheSet","MapCache","arrayLikeKeys","baseKeys","isArrayLike","createCompounder","word","ServiceProvider","_jsx","ThemeProvider","StatusProvider","ConfigProvider","FeaturesProvider","RelationsProvider","SlotFillProvider","GlobalModalProvider","ContextProvider","DataProvider","withEdtrContext","Component","DatetimesListProvider","DatesFilterStateProvider","FilteredDatesProvider","TicketsListProvider","TicketsFilterStateProvider","FilteredTicketsProvider","withEntityListContext","Provider","useDatetimeIds","datetimes","getGuids","useDatetimeItem","returnPartialData","useCacheQuery","espressoDatetime","useRelatedDatetimes","entityId","relatedDatetimeIds","getRelations","useRelations","relation","entityListCacheIdString","relatedDatetimeIdsStr","useRelatedPrices","prices","usePrices","relatedPriceIds","relatedPriceIdsStr","UPDATE_EVENT","EVENT_ATTRIBUTES","DisplayStartOrEndDate","usePriceQueryOptions","includeDefaultTicketsPrices","includeDefaultPrices","useUpdateTicketCache","queryOptions","ticketIndex","tickets","action","_tickets$nodes","newNodes","entityHasGuid","update","writeOptions","writeQuery","BULK_DELETE_ENTITIES","useBulkDeleteEntities","entityType","bulkDelete","useMutationWithFeedback","MutationType","Delete","mutation","_ref3","_regeneratorRuntime","_callee","updateEntityList","_context","clientMutationId","_x","_isPlaceholder","f1","mutations","castPath","isArguments","isIndex","isLength","toKey","hasFunc","isKey","stringToPath","global","funcToString","func","other","baseIsArguments","objectProto","reIsUint","baseFor","stubFalse","freeExports","freeModule","Buffer","isBuffer","baseIsTypedArray","baseUnary","nodeUtil","nodeIsTypedArray","isTypedArray","baseMatches","baseMatchesProperty","identity","stackClear","stackDelete","stackGet","stackHas","stackSet","Stack","baseIsEqualDeep","baseIsEqual","bitmask","customizer","stack","SetCache","arraySome","cacheHas","equalFunc","isPartial","arrLength","othLength","arrStacked","othStacked","seen","arrValue","othValue","compared","othIndex","srcValue","arrayReduce","deburr","words","reApos","reHasUnicode","GET_EVENT","_data$espressoPrices","usePricesQuery","espressoPrices","usePriceTypeQueryOptions","GET_PRICE_TYPES","useVenueQueryOptions","GET_VENUES","DatesFilterStateContext","createContext","DatesFilterStateConsumer","Consumer","filterState","useDatesListFilterStateManager","FilteredDatesContext","FilteredDatesConsumer","useDatesListFilterState","filteredEntities","useFilteredEntities","filteredEntityIds","_useVisibleDatetimeId","useVisibleDatetimeIds","setVisibleDatetimeIds","TicketsFilterStateContext","TicketsFilterStateConsumer","useTicketsListFilterStateManager","FilteredTicketsContext","FilteredTicketsConsumer","useTicketsListFilterState","_useVisibleTicketIds","useVisibleTicketIds","setVisibleTicketIds","capitalize","cursor","sorted","visited","outgoingEdges","edge","makeOutgoingEdges","nodesHash","res","makeNodesHash","visit","predecessors","nodeRep","outgoing","child","uniqueNodes","useUpdateDatetimeList","useUpdateTicketList","useDefaultTickets","isDefault","useDefaultTicketIds","useTicketIds","useTicketItem","espressoTicket","useTicketPrices","ticketId","relatedPricesIds","useCappedQuantity","allDates","capacity","quantity","_ref$relatedDateIds","relatedDateIds","dateIdsToUse","minimumCapacity","R","minDateCapacity","ticketQuantityFromCapacity","usePriceTypes","_data$espressoPriceTy","espressoPriceTypes","useDefaultPriceType","allPriceTypes","defaultPriceType","getDefaultPriceModifierType","usePriceTypeForPrice","priceId","relatedPriceTypeIds","relatedPriceTypes","priceType","isEmpty","useDeleteRelatedTickets","deleteTickets","useBulkDeleteTickets","datetimeId","relatedTicketIds","ticketIdsRelatedOnlyToTheDate","deleteRemotely","_x2","hooks","getHooks","useBulkEditTickets","allTickets","updateTicketList","onUpdateTicket","useOnUpdateTicket","affectedDatesQueries","useAffectedDatesQueries","updateTickets","Update","updateInput","datetimeIds","priceIds","updateEntities","refetchQueries","unnest","useEventGuid","useEventQueryOptions","GET_PRICE_TYPE","useUpdateDatetimeCache","datetimeIndex","datetime","_datetimes$nodes","updateTicketCache","_data","datetimeIn","sortBy","readQuery","newDatetimeIn","useOnUpdateDatetime","_useRelations","addRelation","removeRelation","updateRelations","hasTempId","relationIds","relationId","useOnDeleteDatetime","dropRelations","updateDatetimeCache","useOnDeleteTicket","ticketIn","updatePriceCache","newTicketIn","_ref$prices","priceNodes","pathToNodes","existingPrices","newPrices","uniqBy","entityDbId","assocPath","REORDER_ENTITIES","useReorderEntities","_useState","useState","_useState2","allEntityGuids","setAllEntityGuids","_useState3","_useState4","allReorderedEntities","setAllOrderedEntities","_useMutation","useMutation","_useMutation2","mutate","updateSortOrder","success","sortEntities","allEntitiesList","newIndex","oldIndex","_ref4","_entityIds$splice","splice","removed","entities","indexInAll","_allEntities$splice","order","_ref$mutationType","oldDatetimeIds","nativeObjectToString","isOwn","unmasked","memoizeCapped","rePropName","reEscapeChar","charCodeAt","quote","subString","memoize","resolver","memoized","Hash","hashClear","hashDelete","hashGet","hashHas","hashSet","isFunction","isMasked","toSource","reIsHostCtor","funcProto","reIsNative","coreJsData","maskSrcKey","uid","IE_PROTO","assocIndexOf","getMapData","arrayMap","symbolProto","createBaseFor","fromRight","keysFunc","baseTimes","inherited","isArr","isArg","isBuff","skipIndexes","typedArrayTags","freeProcess","process","types","binding","isPrototype","nativeKeys","Ctor","overArg","baseIsMatch","getMatchData","matchesStrictComparable","matchData","noCustomizer","objValue","COMPARE_PARTIAL_FLAG","pairs","LARGE_ARRAY_SIZE","equalArrays","equalByTag","equalObjects","getTag","argsTag","arrayTag","objectTag","objIsArr","othIsArr","objTag","othTag","objIsObj","othIsObj","isSameTag","objIsWrapped","othIsWrapped","objUnwrapped","othUnwrapped","setCacheAdd","setCacheHas","predicate","Uint8Array","mapToArray","setToArray","symbolValueOf","byteLength","byteOffset","buffer","convert","stacked","getAllKeys","objProps","objLength","objStacked","skipCtor","objCtor","othCtor","baseGetAllKeys","getSymbols","arrayPush","symbolsFunc","offset","arrayFilter","stubArray","nativeGetSymbols","symbol","resIndex","DataView","WeakMap","mapTag","promiseTag","setTag","weakMapTag","dataViewTag","dataViewCtorString","mapCtorString","promiseCtorString","setCtorString","weakMapCtorString","ArrayBuffer","ctorString","isStrictComparable","hasIn","baseGet","baseHasIn","baseProperty","basePropertyDeep","accumulator","initAccum","deburrLetter","reLatin","reComboMark","basePropertyOf","asciiWords","hasUnicodeWord","unicodeWords","pattern","guard","reAsciiWord","reHasUnicodeWord","rsDingbatRange","rsLowerRange","rsUpperRange","rsBreakRange","rsMathOpRange","rsBreak","rsDigits","rsDingbat","rsLower","rsMisc","rsRegional","rsSurrPair","rsUpper","rsMiscLower","rsMiscUpper","rsOptContrLower","rsOptContrUpper","reOptMod","rsModifier","rsOptVar","rsSeq","rsEmoji","reUnicodeWord","upperFirst","createCaseFirst","castSlice","hasUnicode","stringToArray","methodName","strSymbols","chr","trailing","baseSlice","start","end","asciiToArray","unicodeToArray","rsAstral","rsCombo","rsFitz","rsNonAstral","rsSymbol","reUnicode","useVenues","_data$espressoVenues","useVenuesQuery","espressoVenues","useLazyDatetime","getData","useLazyCacheQuery","useLazyTicket","useRelatedTickets","VENUE_ATTRIBUTES","GET_VENUE","useUpdatePriceList","onDeleteTicket","useApolloClient","DEFAULT_LIST_DATA","findTicket","findEntityByGuid","filteredTickets","finalDatetimeIn","_ref2$deleteRemotely","_ref2$relatedDatetime","updateTheEntityList","useContext","invariant","visibleDatetimeIds","makeVar","useReactiveVariable","visibleTicketIds","reducer","displayStartOrEndDate","sales","status","recurrence","initialState","DatetimeSales","all","DatetimeStatus","activeUpcoming","_useSessionStorageRed","useSessionStorageReducer","_useSessionStorageRed2","dispatch","entityFilterState","useEntityListFilterStateManager","setPageNumber","resetPageNumber","setDisplayStartOrEndDate","setSales","setStatus","setRecurrence","isChained","TicketsSales","TicketsStatus","onSaleAndPending","visibleDatesStr","setVisibleDatesStr","toggleIsChained","useEvent","espressoEvent","_has","_isArguments","x","useUpdatePriceTypeList","useUpdateVenueList","useBulkEditDatetimes","allDatetimes","updateDatetimeList","onUpdateDatetime","updateDatetimes","useBulkDeleteDatetimes","onDeleteDatetime","deleteRelatedTickets","findDatetime","filteredDatetimes","_entityId","t0","_callee2","_context2","useReorderDatetimes","allUpdatedEntities","setAllUpdatedEntities","getDatetime","_useReorderEntities","sortResponder","destination","noDestination","noChange","droppableId","notOurListOfInterest","datetimesDroppableId","allSortedEntities","useReorderTickets","getTicket","ticketDroppableId","useUpdateTicketQtyByCapacity","getRelatedTickets","bulkEditTickets","createBulkQtyUpdateInput","ticketIdsToUpdate","ticketsToUpdate","parseInfinity","getTicketQuantityFromCapacity","nonNegativeTicketQuantity","isInfinite","doQtyBulkUpdate","uniqInputs","showNotice","_args","uniqTicketsByMinQty","useBulkDeletePrices","allPrices","updatePriceList","Price","DateStatus","PriceBasetype","isDatetime","useFilteredDateIds","useFilteredTicketIds","EdtrGlobalModals","QueryURLRegStatus","useMutationVariables","useUpdatePriceCache","priceIndex","_prices$nodes","useOnCreatePrice","priceTypeId","useOnDeletePrice","useOnUpdatePrice","NUMERIC_FIELDS","BOOLEAN_FIELDS","useMutationHandler","onCreatePrice","onUpdatePrice","onDeletePrice","getMutationVariables","Create","filteredInput","removeNullAndUndefined","normalizedInput","normalizeNumericFields","normalizeBooleanFields","usePriceMutator","createPrice","updatePrice","deletePrice","mutationHandler","getUpdateCallback","createEntity","_mutationHandler","updateEntity","_mutationHandler2","deleteEntity","_mutationHandler3","mutationInput","useOnCreateDatetime","DATETIME_DEFAULTS","PLUS_TWO_MONTHS","isPrimary","isSoldOut","reserved","sold","PLUS_ONE_MONTH","venue","useOptimisticResponse","lcMutationtype","ucFirstMutationtype","ucFirst","onCreateDatetime","getOptimisticResponse","optimisticResponse","useDatetimeMutator","createDatetime","updateDatetime","deleteDatetime","Datetime","useOnCreateTicket","TICKET_DEFAULTS","isRequired","registrationCount","reverseCalculate","userId","uses","visibility","onCreateTicket","doAction","useTicketMutator","createTicket","updateTicket","deleteTicket","Ticket","startAndEndDateFixer","form","previousValues","subscribe","batch","_form$getFieldState","_form$getFieldState2","_form$getFieldState2$","prevStartDate","prevEndDate","startDateChanged","endDateChanged","isEndDateNotPristine","getFieldState","pristine","changedFromStartDate","endDateFieldNotice","newEndDate","mayBeAdjustEndDate","newStartDate","change","mutators","setFieldData","fieldNotice","requiredMessage","datesSchema","yup","when","endDateAfterStartDateErrorMessage","filterCellByStartOrEndDate","cell","getEdtrDomData","useCacheRehydrationData","_window2","_window2$eventEspress","currentUser","generalSettings","useCacheRehydration","setIsLoaded","useStatus","initializeRelations","initialize","relationsInitialized","isInitialized","_useCacheRehydrationD","_useIsRehydrated","useIsRehydrated","_useIsRehydrated2","isRehydrated","setIsRehydrated","_eventEditor$datetime","_eventEditor$tickets","_eventEditor$prices","_eventEditor$priceTyp","priceTypes","_eventEditor$venues","venues","relations","priceTypeQueryOptions","updatePriceTypeList","datetimeQueryOptions","ticketQueryOptions","priceQueryOptions","venueQueryOptions","updateVenueList","currentUserQueryOptions","useCurrentUserQueryOptions","updateCurrentUser","useUpdateCurrentUserCache","generalSettingsQueryOptions","useGeneralSettingsQueryOptions","updateGeneralSettings","useUpdateGeneralSettingsCache","eventQueryOptions","updateCache","viewer","manager","createVariables","useEventMutator","updateEvent","_createSlotFill","createSlotFill","NewDateOptions","Slot","NewDateOption","Fill","ticketsMeta","useTicketsMeta","useEntityMeta","useEventManagers","eventManagers","useIsChainedFilter","pickBy","registerTicketsFilter","FilterBarService","registerFilter","useRegisterIsChainedFilter","_useIsChainedFilter","_useIsChainedFilter2","isChainedFilter","isChainedDeps","unSubIsChainedFilterRef","useRef","_unSubIsChainedFilter","unSubscribeIsChainedFilter","entityList","_unSubIsChainedFilter2","_curry1","empty","equals","_isArray","_isObject","_isString","_curry2","_equals","f2","_b","_a","_arrayFromIterator","_includesWith","_functionName","_objectIs","_uniqContentEquals","aIterator","bIterator","stackA","stackB","aItem","typeA","ignoreCase","multiline","sticky","unicode","keysA","extendedStackA","extendedStackB","pred","hasEnumBug","nonEnumerableProps","hasArgsEnumBug","contains","nIdx","ks","checkArgsLength"],"mappings":";sFACE,IAAIA,EAAmB,GAGvB,SAASC,EAAoBC,GAG5B,GAAGF,EAAiBE,GACnB,OAAOF,EAAiBE,GAAUC,QAGnC,IAAIC,EAASJ,EAAiBE,GAAY,CACzCG,EAAGH,EACHI,GAAG,EACHH,QAAS,IAUV,OANAI,EAAQL,GAAUM,KAAKJ,EAAOD,QAASC,EAAQA,EAAOD,QAASF,GAG/DG,EAAOE,GAAI,EAGJF,EAAOD,QA0Df,OArDAF,EAAoBQ,EAAIF,EAGxBN,EAAoBS,EAAIV,EAGxBC,EAAoBU,EAAI,SAASR,EAASS,EAAMC,GAC3CZ,EAAoBa,EAAEX,EAASS,IAClCG,OAAOC,eAAeb,EAASS,EAAM,CAAEK,YAAY,EAAMC,IAAKL,KAKhEZ,EAAoBkB,EAAI,SAAShB,GACX,qBAAXiB,QAA0BA,OAAOC,aAC1CN,OAAOC,eAAeb,EAASiB,OAAOC,YAAa,CAAEC,MAAO,WAE7DP,OAAOC,eAAeb,EAAS,aAAc,CAAEmB,OAAO,KAQvDrB,EAAoBsB,EAAI,SAASD,EAAOE,GAEvC,GADU,EAAPA,IAAUF,EAAQrB,EAAoBqB,IAC/B,EAAPE,EAAU,OAAOF,EACpB,GAAW,EAAPE,GAA8B,kBAAVF,GAAsBA,GAASA,EAAMG,WAAY,OAAOH,EAChF,IAAII,EAAKX,OAAOY,OAAO,MAGvB,GAFA1B,EAAoBkB,EAAEO,GACtBX,OAAOC,eAAeU,EAAI,UAAW,CAAET,YAAY,EAAMK,MAAOA,IACtD,EAAPE,GAA4B,iBAATF,EAAmB,IAAI,IAAIM,KAAON,EAAOrB,EAAoBU,EAAEe,EAAI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AGF,IAFAI,EAAOH,EAAmBznD,OAAS,EAE5B4nD,GAAQ,GAGThR,EAFJrpB,EAAOk6B,EAAmBG,GAEXhmD,KAAS+lD,EAASE,EAAIt6B,KACnCs6B,EAAGA,EAAG7nD,QAAUutB,GAGlBq6B,GAAQ,EAIZ,OAAOC,KAlCTnC,GAAQ,SAAc9jD,GACpB,OAAOjE,OAAOiE,KAASA,EAAM,GAAKjE,OAAO0B,KAAKuC,MAmChD5E,EAAOD,QAAUsC,G,gBCnGjB,IA8BIkK,EA5BJrK,EAAQ,IA8BRwmD,EAAQ,SAAc3+C,GACpB,OAAe,OAARA,EAAe,YAAiB5F,IAAR4F,EAAoB,YAAcpJ,OAAOkB,UAAUgE,SAASzF,KAAK2J,GAAKjE,MAAM,GAAI,MAGjH9F,EAAOD,QAAUwM","file":"static/js/edtrServices.7f51b510.js","sourcesContent":[" \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"/\";\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 1530);\n","(function() { module.exports = window[\"React\"]; }());","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-jsx-runtime.production.min.js');\n} else {\n module.exports = require('./cjs/react-jsx-runtime.development.js');\n}\n","import defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\n\nfunction ownKeys(object, enumerableOnly) {\n var keys = Object.keys(object);\n\n if (Object.getOwnPropertySymbols) {\n var symbols = Object.getOwnPropertySymbols(object);\n if (enumerableOnly) symbols = symbols.filter(function (sym) {\n return Object.getOwnPropertyDescriptor(object, sym).enumerable;\n });\n keys.push.apply(keys, symbols);\n }\n\n return keys;\n}\n\nexport default function _objectSpread2(target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i] != null ? arguments[i] : {};\n\n if (i % 2) {\n ownKeys(Object(source), true).forEach(function (key) {\n defineProperty(target, key, source[key]);\n });\n } else if (Object.getOwnPropertyDescriptors) {\n Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));\n } else {\n ownKeys(Object(source)).forEach(function (key) {\n Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));\n });\n }\n }\n\n return target;\n}","(function() { module.exports = window[\"eventespresso\"][\"i18n\"]; }());","(function() { module.exports = window[\"R\"]; }());","import objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nexport default function _objectWithoutProperties(source, excluded) {\n if (source == null) return {};\n var target = objectWithoutPropertiesLoose(source, excluded);\n var key, i;\n\n if (Object.getOwnPropertySymbols) {\n var sourceSymbolKeys = Object.getOwnPropertySymbols(source);\n\n for (i = 0; i < sourceSymbolKeys.length; i++) {\n key = sourceSymbolKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;\n target[key] = source[key];\n }\n }\n\n return target;\n}","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n\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\n return target;\n}","import arrayWithHoles from \"@babel/runtime/helpers/esm/arrayWithHoles\";\nimport iterableToArrayLimit from \"@babel/runtime/helpers/esm/iterableToArrayLimit\";\nimport unsupportedIterableToArray from \"@babel/runtime/helpers/esm/unsupportedIterableToArray\";\nimport nonIterableRest from \"@babel/runtime/helpers/esm/nonIterableRest\";\nexport default function _slicedToArray(arr, i) {\n return arrayWithHoles(arr) || iterableToArrayLimit(arr, i) || unsupportedIterableToArray(arr, i) || nonIterableRest();\n}","export default function _iterableToArrayLimit(arr, i) {\n if (typeof Symbol === \"undefined\" || !(Symbol.iterator in Object(arr))) return;\n var _arr = [];\n var _n = true;\n var _d = false;\n var _e = undefined;\n\n try {\n for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) {\n _arr.push(_s.value);\n\n if (i && _arr.length === i) break;\n }\n } catch (err) {\n _d = true;\n _e = err;\n } finally {\n try {\n if (!_n && _i[\"return\"] != null) _i[\"return\"]();\n } finally {\n if (_d) throw _e;\n }\n }\n\n return _arr;\n}","(function() { module.exports = window[\"eventespresso\"][\"predicates\"]; }());","export default function _defineProperty(obj, key, value) {\n if (key in obj) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n } else {\n obj[key] = value;\n }\n\n return obj;\n}","(function() { module.exports = window[\"eventespresso\"][\"utils\"]; }());","(function() { module.exports = window[\"eventespresso\"][\"data\"]; }());","(function() { module.exports = window[\"eventespresso\"][\"services\"]; }());","(function() { module.exports = window[\"eventespresso\"][\"hooks\"]; }());","(function() { module.exports = window[\"eventespresso\"][\"adapters\"]; }());","import arrayWithoutHoles from \"@babel/runtime/helpers/esm/arrayWithoutHoles\";\nimport iterableToArray from \"@babel/runtime/helpers/esm/iterableToArray\";\nimport unsupportedIterableToArray from \"@babel/runtime/helpers/esm/unsupportedIterableToArray\";\nimport nonIterableSpread from \"@babel/runtime/helpers/esm/nonIterableSpread\";\nexport default function _toConsumableArray(arr) {\n return arrayWithoutHoles(arr) || iterableToArray(arr) || unsupportedIterableToArray(arr) || nonIterableSpread();\n}","import arrayLikeToArray from \"@babel/runtime/helpers/esm/arrayLikeToArray\";\nexport default function _arrayWithoutHoles(arr) {\n if (Array.isArray(arr)) return arrayLikeToArray(arr);\n}","export default function _nonIterableSpread() {\n throw new TypeError(\"Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}","module.exports = require(\"regenerator-runtime\");\n","(function() { module.exports = window[\"eventespresso\"][\"constants\"]; }());","export default function _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n}","export default function _arrayLikeToArray(arr, len) {\n if (len == null || len > arr.length) len = arr.length;\n\n for (var i = 0, arr2 = new Array(len); i < len; i++) {\n arr2[i] = arr[i];\n }\n\n return arr2;\n}","import arrayLikeToArray from \"@babel/runtime/helpers/esm/arrayLikeToArray\";\nexport default function _unsupportedIterableToArray(o, minLen) {\n if (!o) return;\n if (typeof o === \"string\") return arrayLikeToArray(o, minLen);\n var n = Object.prototype.toString.call(o).slice(8, -1);\n if (n === \"Object\" && o.constructor) n = o.constructor.name;\n if (n === \"Map\" || n === \"Set\") return Array.from(o);\n if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return arrayLikeToArray(o, minLen);\n}","function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {\n try {\n var info = gen[key](arg);\n var value = info.value;\n } catch (error) {\n reject(error);\n return;\n }\n\n if (info.done) {\n resolve(value);\n } else {\n Promise.resolve(value).then(_next, _throw);\n }\n}\n\nexport default function _asyncToGenerator(fn) {\n return function () {\n var self = this,\n args = arguments;\n return new Promise(function (resolve, reject) {\n var gen = fn.apply(self, args);\n\n function _next(value) {\n asyncGeneratorStep(gen, resolve, reject, _next, _throw, \"next\", value);\n }\n\n function _throw(err) {\n asyncGeneratorStep(gen, resolve, reject, _next, _throw, \"throw\", err);\n }\n\n _next(undefined);\n });\n };\n}","(function() { module.exports = window[\"eventespresso\"][\"registry\"]; }());","export default function _getPrototypeOf(o) {\n _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) {\n return o.__proto__ || Object.getPrototypeOf(o);\n };\n return _getPrototypeOf(o);\n}","function _defineProperties(target, props) {\n for (var i = 0; i < props.length; i++) {\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n Object.defineProperty(target, descriptor.key, descriptor);\n }\n}\n\nexport default function _createClass(Constructor, protoProps, staticProps) {\n if (protoProps) _defineProperties(Constructor.prototype, protoProps);\n if (staticProps) _defineProperties(Constructor, staticProps);\n return Constructor;\n}","export default function _taggedTemplateLiteral(strings, raw) {\n if (!raw) {\n raw = strings.slice(0);\n }\n\n return Object.freeze(Object.defineProperties(strings, {\n raw: {\n value: Object.freeze(raw)\n }\n }));\n}","(function() { module.exports = window[\"eventespresso\"][\"dates\"]; }());","import setPrototypeOf from \"@babel/runtime/helpers/esm/setPrototypeOf\";\nexport default function _inherits(subClass, superClass) {\n if (typeof superClass !== \"function\" && superClass !== null) {\n throw new TypeError(\"Super expression must either be null or a function\");\n }\n\n subClass.prototype = Object.create(superClass && superClass.prototype, {\n constructor: {\n value: subClass,\n writable: true,\n configurable: true\n }\n });\n if (superClass) setPrototypeOf(subClass, superClass);\n}","import _typeof from \"@babel/runtime/helpers/esm/typeof\";\nimport assertThisInitialized from \"@babel/runtime/helpers/esm/assertThisInitialized\";\nexport default function _possibleConstructorReturn(self, call) {\n if (call && (_typeof(call) === \"object\" || typeof call === \"function\")) {\n return call;\n }\n\n return assertThisInitialized(self);\n}","import getPrototypeOf from \"@babel/runtime/helpers/esm/getPrototypeOf\";\nimport isNativeReflectConstruct from \"@babel/runtime/helpers/esm/isNativeReflectConstruct\";\nimport possibleConstructorReturn from \"@babel/runtime/helpers/esm/possibleConstructorReturn\";\nexport default function _createSuper(Derived) {\n var hasNativeReflectConstruct = isNativeReflectConstruct();\n return function _createSuperInternal() {\n var Super = getPrototypeOf(Derived),\n result;\n\n if (hasNativeReflectConstruct) {\n var NewTarget = getPrototypeOf(this).constructor;\n result = Reflect.construct(Super, arguments, NewTarget);\n } else {\n result = Super.apply(this, arguments);\n }\n\n return possibleConstructorReturn(this, result);\n };\n}","export default function _arrayWithHoles(arr) {\n if (Array.isArray(arr)) return arr;\n}","export default function _nonIterableRest() {\n throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}","import superPropBase from \"@babel/runtime/helpers/esm/superPropBase\";\nexport default function _get(target, property, receiver) {\n if (typeof Reflect !== \"undefined\" && Reflect.get) {\n _get = Reflect.get;\n } else {\n _get = function _get(target, property, receiver) {\n var base = superPropBase(target, property);\n if (!base) return;\n var desc = Object.getOwnPropertyDescriptor(base, property);\n\n if (desc.get) {\n return desc.get.call(receiver);\n }\n\n return desc.value;\n };\n }\n\n return _get(target, property, receiver || target);\n}","import getPrototypeOf from \"@babel/runtime/helpers/esm/getPrototypeOf\";\nexport default function _superPropBase(object, property) {\n while (!Object.prototype.hasOwnProperty.call(object, property)) {\n object = getPrototypeOf(object);\n if (object === null) break;\n }\n\n return object;\n}","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n/**\n * Use invariant() to assert state which your program assumes to be true.\n *\n * Provide sprintf-style format (only %s is supported) and arguments\n * to provide information about what broke and what you were\n * expecting.\n *\n * The invariant message will be stripped in production, but the invariant\n * will remain to ensure logic does not differ in production.\n */\n\nvar invariant = function(condition, format, a, b, c, d, e, f) {\n if (process.env.NODE_ENV !== 'production') {\n if (format === undefined) {\n throw new Error('invariant requires an error message argument');\n }\n }\n\n if (!condition) {\n var error;\n if (format === undefined) {\n error = new Error(\n 'Minified exception occurred; use the non-minified dev environment ' +\n 'for the full error message and additional helpful warnings.'\n );\n } else {\n var args = [a, b, c, d, e, f];\n var argIndex = 0;\n error = new Error(\n format.replace(/%s/g, function() { return args[argIndex++]; })\n );\n error.name = 'Invariant Violation';\n }\n\n error.framesToPop = 1; // we don't care about invariant's own frame\n throw error;\n }\n};\n\nmodule.exports = invariant;\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","export default function _iterableToArray(iter) {\n if (typeof Symbol !== \"undefined\" && Symbol.iterator in Object(iter)) return Array.from(iter);\n}","import type { Ticket } from '@eventespresso/edtr-services';\nimport { __ } from '@eventespresso/i18n';\n\nexport const domain = 'eventEditor';\n\nexport const datesList = 'dates-list';\n\nexport const ticketsList = 'tickets-list';\n\nexport const TICKET_FIELDS_FOR_TPC: Array = [\n\t'id',\n\t'name',\n\t'description',\n\t'price',\n\t'quantity',\n\t'reverseCalculate',\n\t'visibility',\n];\n\n/**\n * Translated singular entity names\n */\nexport const SINGULAR_ENTITY_NAME = {\n\tDATETIME: __('datetime'),\n\tEVENT: __('event'),\n\tTICKET: __('ticket'),\n\tPRICE: __('price'),\n\tPRICE_TYPE: __('price type'),\n};\n","/** @license React v17.0.2\n * react-jsx-runtime.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';require(\"object-assign\");var f=require(\"react\"),g=60103;exports.Fragment=60107;if(\"function\"===typeof Symbol&&Symbol.for){var h=Symbol.for;g=h(\"react.element\");exports.Fragment=h(\"react.fragment\")}var m=f.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,n=Object.prototype.hasOwnProperty,p={key:!0,ref:!0,__self:!0,__source:!0};\nfunction q(c,a,k){var b,d={},e=null,l=null;void 0!==k&&(e=\"\"+k);void 0!==a.key&&(e=\"\"+a.key);void 0!==a.ref&&(l=a.ref);for(b in a)n.call(a,b)&&!p.hasOwnProperty(b)&&(d[b]=a[b]);if(c&&c.defaultProps)for(b in a=c.defaultProps,a)void 0===d[b]&&(d[b]=a[b]);return{$$typeof:g,type:c,key:e,ref:l,props:d,_owner:m.current}}exports.jsx=q;exports.jsxs=q;\n","import type { DatetimeEdge, TicketEdge, PriceEdge, PriceTypeEdge, VenueEdge } from '../types';\nimport { EntityEdge } from '@eventespresso/data';\n\nexport const DEFAULT_ENTITY_LIST_DATA: EntityEdge = {\n\tnodes: [],\n\t__typename: '',\n};\n\nexport const DEFAULT_DATETIME_LIST_DATA: DatetimeEdge = {\n\tnodes: [],\n\t__typename: 'EspressoRootQueryDatetimesConnection',\n};\n\nexport const DEFAULT_TICKET_LIST_DATA: TicketEdge = {\n\tnodes: [],\n\t__typename: 'EspressoRootQueryTicketsConnection',\n};\n\nexport const DEFAULT_PRICE_LIST_DATA: PriceEdge = {\n\tnodes: [],\n\t__typename: 'EspressoRootQueryPricesConnection',\n};\n\nexport const DEFAULT_PRICE_TYPE_LIST_DATA: PriceTypeEdge = {\n\tnodes: [],\n\t__typename: 'EspressoRootQueryPriceTypesConnection',\n};\n\nexport const DEFAULT_VENUE_LIST_DATA: VenueEdge = {\n\tnodes: [],\n\t__typename: 'RootQueryToEspressoVenueConnection',\n};\n\nexport * from './datetimes';\n\nexport * from './events';\n\nexport * from './tickets';\n\nexport * from './prices';\n\nexport * from './priceTypes';\n\nexport * from './users';\n\nexport * from './venues';\n\nexport * from './types';\n","import unsupportedIterableToArray from \"@babel/runtime/helpers/esm/unsupportedIterableToArray\";\nexport default function _createForOfIteratorHelper(o, allowArrayLike) {\n var it;\n\n if (typeof Symbol === \"undefined\" || o[Symbol.iterator] == null) {\n if (Array.isArray(o) || (it = unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === \"number\") {\n if (it) o = it;\n var i = 0;\n\n var F = function F() {};\n\n return {\n s: F,\n n: function n() {\n if (i >= o.length) return {\n done: true\n };\n return {\n done: false,\n value: o[i++]\n };\n },\n e: function e(_e) {\n throw _e;\n },\n f: F\n };\n }\n\n throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n }\n\n var normalCompletion = true,\n didErr = false,\n err;\n return {\n s: function s() {\n it = o[Symbol.iterator]();\n },\n n: function n() {\n var step = it.next();\n normalCompletion = step.done;\n return step;\n },\n e: function e(_e2) {\n didErr = true;\n err = _e2;\n },\n f: function f() {\n try {\n if (!normalCompletion && it[\"return\"] != null) it[\"return\"]();\n } finally {\n if (didErr) throw err;\n }\n }\n };\n}","export default function _assertThisInitialized(self) {\n if (self === void 0) {\n throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\");\n }\n\n return self;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n\n return _setPrototypeOf(o, p);\n}","export default function _typeof(obj) {\n \"@babel/helpers - typeof\";\n\n if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") {\n _typeof = function _typeof(obj) {\n return typeof obj;\n };\n } else {\n _typeof = function _typeof(obj) {\n return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj;\n };\n }\n\n return _typeof(obj);\n}","export default function _isNativeReflectConstruct() {\n if (typeof Reflect === \"undefined\" || !Reflect.construct) return false;\n if (Reflect.construct.sham) return false;\n if (typeof Proxy === \"function\") return true;\n\n try {\n Date.prototype.toString.call(Reflect.construct(Date, [], function () {}));\n return true;\n } catch (e) {\n return false;\n }\n}","var freeGlobal = require('./_freeGlobal');\n\n/** Detect free variable `self`. */\nvar freeSelf = typeof self == 'object' && self && self.Object === Object && self;\n\n/** Used as a reference to the global object. */\nvar root = freeGlobal || freeSelf || Function('return this')();\n\nmodule.exports = root;\n","/**\n * Checks if `value` is classified as an `Array` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an array, else `false`.\n * @example\n *\n * _.isArray([1, 2, 3]);\n * // => true\n *\n * _.isArray(document.body.children);\n * // => false\n *\n * _.isArray('abc');\n * // => false\n *\n * _.isArray(_.noop);\n * // => false\n */\nvar isArray = Array.isArray;\n\nmodule.exports = isArray;\n","/**\n * Based on Kendo UI Core expression code \n */\n'use strict'\n\nfunction Cache(maxSize) {\n this._maxSize = maxSize\n this.clear()\n}\nCache.prototype.clear = function () {\n this._size = 0\n this._values = Object.create(null)\n}\nCache.prototype.get = function (key) {\n return this._values[key]\n}\nCache.prototype.set = function (key, value) {\n this._size >= this._maxSize && this.clear()\n if (!(key in this._values)) this._size++\n\n return (this._values[key] = value)\n}\n\nvar SPLIT_REGEX = /[^.^\\]^[]+|(?=\\[\\]|\\.\\.)/g,\n DIGIT_REGEX = /^\\d+$/,\n LEAD_DIGIT_REGEX = /^\\d/,\n SPEC_CHAR_REGEX = /[~`!#$%\\^&*+=\\-\\[\\]\\\\';,/{}|\\\\\":<>\\?]/g,\n CLEAN_QUOTES_REGEX = /^\\s*(['\"]?)(.*?)(\\1)\\s*$/,\n MAX_CACHE_SIZE = 512\n\nvar pathCache = new Cache(MAX_CACHE_SIZE),\n setCache = new Cache(MAX_CACHE_SIZE),\n getCache = new Cache(MAX_CACHE_SIZE)\n\nvar config\n\nmodule.exports = {\n Cache: Cache,\n\n split: split,\n\n normalizePath: normalizePath,\n\n setter: function (path) {\n var parts = normalizePath(path)\n\n return (\n setCache.get(path) ||\n setCache.set(path, function setter(obj, value) {\n var index = 0\n var len = parts.length\n var data = obj\n\n while (index < len - 1) {\n var part = parts[index]\n if (\n part === '__proto__' ||\n part === 'constructor' ||\n part === 'prototype'\n ) {\n return obj\n }\n\n data = data[parts[index++]]\n }\n data[parts[index]] = value\n })\n )\n },\n\n getter: function (path, safe) {\n var parts = normalizePath(path)\n return (\n getCache.get(path) ||\n getCache.set(path, function getter(data) {\n var index = 0,\n len = parts.length\n while (index < len) {\n if (data != null || !safe) data = data[parts[index++]]\n else return\n }\n return data\n })\n )\n },\n\n join: function (segments) {\n return segments.reduce(function (path, part) {\n return (\n path +\n (isQuoted(part) || DIGIT_REGEX.test(part)\n ? '[' + part + ']'\n : (path ? '.' : '') + part)\n )\n }, '')\n },\n\n forEach: function (path, cb, thisArg) {\n forEach(Array.isArray(path) ? path : split(path), cb, thisArg)\n },\n}\n\nfunction normalizePath(path) {\n return (\n pathCache.get(path) ||\n pathCache.set(\n path,\n split(path).map(function (part) {\n return part.replace(CLEAN_QUOTES_REGEX, '$2')\n })\n )\n )\n}\n\nfunction split(path) {\n return path.match(SPLIT_REGEX)\n}\n\nfunction forEach(parts, iter, thisArg) {\n var len = parts.length,\n part,\n idx,\n isArray,\n isBracket\n\n for (idx = 0; idx < len; idx++) {\n part = parts[idx]\n\n if (part) {\n if (shouldBeQuoted(part)) {\n part = '\"' + part + '\"'\n }\n\n isBracket = isQuoted(part)\n isArray = !isBracket && /^\\d+$/.test(part)\n\n iter.call(thisArg, part, isBracket, isArray, idx, parts)\n }\n }\n}\n\nfunction isQuoted(str) {\n return (\n typeof str === 'string' && str && [\"'\", '\"'].indexOf(str.charAt(0)) !== -1\n )\n}\n\nfunction hasLeadingNumber(part) {\n return part.match(LEAD_DIGIT_REGEX) && !part.match(DIGIT_REGEX)\n}\n\nfunction hasSpecialChars(part) {\n return SPEC_CHAR_REGEX.test(part)\n}\n\nfunction shouldBeQuoted(part) {\n return !isQuoted(part) && (hasLeadingNumber(part) || hasSpecialChars(part))\n}\n","(function() { module.exports = window[\"eventespresso\"][\"ioc\"]; }());","var baseIsNative = require('./_baseIsNative'),\n getValue = require('./_getValue');\n\n/**\n * Gets the native function at `key` of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {string} key The key of the method to get.\n * @returns {*} Returns the function if it's native, else `undefined`.\n */\nfunction getNative(object, key) {\n var value = getValue(object, key);\n return baseIsNative(value) ? value : undefined;\n}\n\nmodule.exports = getNative;\n","var baseHas = require('./_baseHas'),\n hasPath = require('./_hasPath');\n\n/**\n * Checks if `path` is a direct property of `object`.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Object\n * @param {Object} object The object to query.\n * @param {Array|string} path The path to check.\n * @returns {boolean} Returns `true` if `path` exists, else `false`.\n * @example\n *\n * var object = { 'a': { 'b': 2 } };\n * var other = _.create({ 'a': _.create({ 'b': 2 }) });\n *\n * _.has(object, 'a');\n * // => true\n *\n * _.has(object, 'a.b');\n * // => true\n *\n * _.has(object, ['a', 'b']);\n * // => true\n *\n * _.has(other, 'a');\n * // => false\n */\nfunction has(object, path) {\n return object != null && hasPath(object, path, baseHas);\n}\n\nmodule.exports = has;\n","var g;\n\n// This works in non-strict mode\ng = (function() {\n\treturn this;\n})();\n\ntry {\n\t// This works if eval is allowed (see CSP)\n\tg = g || new Function(\"return this\")();\n} catch (e) {\n\t// This works if the window reference is available\n\tif (typeof window === \"object\") g = window;\n}\n\n// g can still be undefined, but nothing to do about it...\n// We return undefined, instead of nothing here, so it's\n// easier to handle this case. if(!global) { ...}\n\nmodule.exports = g;\n","import { useCallback, useEffect } from 'react';\n\nimport { events } from '@eventespresso/data';\nimport { useSystemNotifications } from '@eventespresso/toaster';\nimport type { EventSet } from '@eventespresso/data';\n\nexport const useEventsHandler: VoidFunction = () => {\n\tconst toaster = useSystemNotifications();\n\n\tconst onError = useCallback(\n\t\t(error) => {\n\t\t\ttoaster.error({ message: error.message });\n\t\t},\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\t\t[]\n\t);\n\n\tuseEffect(() => {\n\t\tevents.on('fetchUser.error', onError);\n\t\tevents.on('fetchSettings.error', onError);\n\n\t\t// housekeeping\n\t\treturn () => {\n\t\t\tevents.off('fetchUser.error', onError);\n\t\t\tevents.off('fetchSettings.error', onError);\n\t\t};\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\t}, []);\n};\n","import { useMemo } from 'react';\nimport { addQueryArgs } from '@wordpress/url';\n\nimport { ADMIN_ROUTES } from '@eventespresso/constants';\nimport { useConfig, getAdminUrl } from '@eventespresso/services';\n\nimport { useEventId } from '../apollo/queries';\nimport { QueryURLRegStatus } from '../types';\n\nexport type RegistrationsLinkArgs = {\n\tdatetime_id?: number;\n\tticket_id?: number;\n\t_reg_status?: QueryURLRegStatus;\n};\n\nexport const useRegistrationsLink = (args: RegistrationsLinkArgs): string => {\n\tconst { siteUrl } = useConfig();\n\tconst eventId = useEventId();\n\n\treturn useMemo(() => {\n\t\tconst adminUrl = getAdminUrl({\n\t\t\tadminSiteUrl: siteUrl.admin,\n\t\t\tpage: ADMIN_ROUTES.REGISTRATIONS,\n\t\t});\n\t\treturn addQueryArgs(adminUrl, {\n\t\t\tevent_id: eventId,\n\t\t\treturn: 'edit',\n\t\t\t...args,\n\t\t});\n\t}, [args, eventId, siteUrl.admin]);\n};\n","/**\n * Copyright (c) 2014-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nvar runtime = (function (exports) {\n \"use strict\";\n\n var Op = Object.prototype;\n var hasOwn = Op.hasOwnProperty;\n var undefined; // More compressible than void 0.\n var $Symbol = typeof Symbol === \"function\" ? Symbol : {};\n var iteratorSymbol = $Symbol.iterator || \"@@iterator\";\n var asyncIteratorSymbol = $Symbol.asyncIterator || \"@@asyncIterator\";\n var toStringTagSymbol = $Symbol.toStringTag || \"@@toStringTag\";\n\n function define(obj, key, value) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n return obj[key];\n }\n try {\n // IE 8 has a broken Object.defineProperty that only works on DOM objects.\n define({}, \"\");\n } catch (err) {\n define = function(obj, key, value) {\n return obj[key] = value;\n };\n }\n\n function wrap(innerFn, outerFn, self, tryLocsList) {\n // If outerFn provided and outerFn.prototype is a Generator, then outerFn.prototype instanceof Generator.\n var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator;\n var generator = Object.create(protoGenerator.prototype);\n var context = new Context(tryLocsList || []);\n\n // The ._invoke method unifies the implementations of the .next,\n // .throw, and .return methods.\n generator._invoke = makeInvokeMethod(innerFn, self, context);\n\n return generator;\n }\n exports.wrap = wrap;\n\n // Try/catch helper to minimize deoptimizations. Returns a completion\n // record like context.tryEntries[i].completion. This interface could\n // have been (and was previously) designed to take a closure to be\n // invoked without arguments, but in all the cases we care about we\n // already have an existing method we want to call, so there's no need\n // to create a new function object. We can even get away with assuming\n // the method takes exactly one argument, since that happens to be true\n // in every case, so we don't have to touch the arguments object. The\n // only additional allocation required is the completion record, which\n // has a stable shape and so hopefully should be cheap to allocate.\n function tryCatch(fn, obj, arg) {\n try {\n return { type: \"normal\", arg: fn.call(obj, arg) };\n } catch (err) {\n return { type: \"throw\", arg: err };\n }\n }\n\n var GenStateSuspendedStart = \"suspendedStart\";\n var GenStateSuspendedYield = \"suspendedYield\";\n var GenStateExecuting = \"executing\";\n var GenStateCompleted = \"completed\";\n\n // Returning this object from the innerFn has the same effect as\n // breaking out of the dispatch switch statement.\n var ContinueSentinel = {};\n\n // Dummy constructor functions that we use as the .constructor and\n // .constructor.prototype properties for functions that return Generator\n // objects. For full spec compliance, you may wish to configure your\n // minifier not to mangle the names of these two functions.\n function Generator() {}\n function GeneratorFunction() {}\n function GeneratorFunctionPrototype() {}\n\n // This is a polyfill for %IteratorPrototype% for environments that\n // don't natively support it.\n var IteratorPrototype = {};\n IteratorPrototype[iteratorSymbol] = function () {\n return this;\n };\n\n var getProto = Object.getPrototypeOf;\n var NativeIteratorPrototype = getProto && getProto(getProto(values([])));\n if (NativeIteratorPrototype &&\n NativeIteratorPrototype !== Op &&\n hasOwn.call(NativeIteratorPrototype, iteratorSymbol)) {\n // This environment has a native %IteratorPrototype%; use it instead\n // of the polyfill.\n IteratorPrototype = NativeIteratorPrototype;\n }\n\n var Gp = GeneratorFunctionPrototype.prototype =\n Generator.prototype = Object.create(IteratorPrototype);\n GeneratorFunction.prototype = Gp.constructor = GeneratorFunctionPrototype;\n GeneratorFunctionPrototype.constructor = GeneratorFunction;\n GeneratorFunction.displayName = define(\n GeneratorFunctionPrototype,\n toStringTagSymbol,\n \"GeneratorFunction\"\n );\n\n // Helper for defining the .next, .throw, and .return methods of the\n // Iterator interface in terms of a single ._invoke method.\n function defineIteratorMethods(prototype) {\n [\"next\", \"throw\", \"return\"].forEach(function(method) {\n define(prototype, method, function(arg) {\n return this._invoke(method, arg);\n });\n });\n }\n\n exports.isGeneratorFunction = function(genFun) {\n var ctor = typeof genFun === \"function\" && genFun.constructor;\n return ctor\n ? ctor === GeneratorFunction ||\n // For the native GeneratorFunction constructor, the best we can\n // do is to check its .name property.\n (ctor.displayName || ctor.name) === \"GeneratorFunction\"\n : false;\n };\n\n exports.mark = function(genFun) {\n if (Object.setPrototypeOf) {\n Object.setPrototypeOf(genFun, GeneratorFunctionPrototype);\n } else {\n genFun.__proto__ = GeneratorFunctionPrototype;\n define(genFun, toStringTagSymbol, \"GeneratorFunction\");\n }\n genFun.prototype = Object.create(Gp);\n return genFun;\n };\n\n // Within the body of any async function, `await x` is transformed to\n // `yield regeneratorRuntime.awrap(x)`, so that the runtime can test\n // `hasOwn.call(value, \"__await\")` to determine if the yielded value is\n // meant to be awaited.\n exports.awrap = function(arg) {\n return { __await: arg };\n };\n\n function AsyncIterator(generator, PromiseImpl) {\n function invoke(method, arg, resolve, reject) {\n var record = tryCatch(generator[method], generator, arg);\n if (record.type === \"throw\") {\n reject(record.arg);\n } else {\n var result = record.arg;\n var value = result.value;\n if (value &&\n typeof value === \"object\" &&\n hasOwn.call(value, \"__await\")) {\n return PromiseImpl.resolve(value.__await).then(function(value) {\n invoke(\"next\", value, resolve, reject);\n }, function(err) {\n invoke(\"throw\", err, resolve, reject);\n });\n }\n\n return PromiseImpl.resolve(value).then(function(unwrapped) {\n // When a yielded Promise is resolved, its final value becomes\n // the .value of the Promise<{value,done}> result for the\n // current iteration.\n result.value = unwrapped;\n resolve(result);\n }, function(error) {\n // If a rejected Promise was yielded, throw the rejection back\n // into the async generator function so it can be handled there.\n return invoke(\"throw\", error, resolve, reject);\n });\n }\n }\n\n var previousPromise;\n\n function enqueue(method, arg) {\n function callInvokeWithMethodAndArg() {\n return new PromiseImpl(function(resolve, reject) {\n invoke(method, arg, resolve, reject);\n });\n }\n\n return previousPromise =\n // If enqueue has been called before, then we want to wait until\n // all previous Promises have been resolved before calling invoke,\n // so that results are always delivered in the correct order. If\n // enqueue has not been called before, then it is important to\n // call invoke immediately, without waiting on a callback to fire,\n // so that the async generator function has the opportunity to do\n // any necessary setup in a predictable way. This predictability\n // is why the Promise constructor synchronously invokes its\n // executor callback, and why async functions synchronously\n // execute code before the first await. Since we implement simple\n // async functions in terms of async generators, it is especially\n // important to get this right, even though it requires care.\n previousPromise ? previousPromise.then(\n callInvokeWithMethodAndArg,\n // Avoid propagating failures to Promises returned by later\n // invocations of the iterator.\n callInvokeWithMethodAndArg\n ) : callInvokeWithMethodAndArg();\n }\n\n // Define the unified helper method that is used to implement .next,\n // .throw, and .return (see defineIteratorMethods).\n this._invoke = enqueue;\n }\n\n defineIteratorMethods(AsyncIterator.prototype);\n AsyncIterator.prototype[asyncIteratorSymbol] = function () {\n return this;\n };\n exports.AsyncIterator = AsyncIterator;\n\n // Note that simple async functions are implemented on top of\n // AsyncIterator objects; they just return a Promise for the value of\n // the final result produced by the iterator.\n exports.async = function(innerFn, outerFn, self, tryLocsList, PromiseImpl) {\n if (PromiseImpl === void 0) PromiseImpl = Promise;\n\n var iter = new AsyncIterator(\n wrap(innerFn, outerFn, self, tryLocsList),\n PromiseImpl\n );\n\n return exports.isGeneratorFunction(outerFn)\n ? iter // If outerFn is a generator, return the full iterator.\n : iter.next().then(function(result) {\n return result.done ? result.value : iter.next();\n });\n };\n\n function makeInvokeMethod(innerFn, self, context) {\n var state = GenStateSuspendedStart;\n\n return function invoke(method, arg) {\n if (state === GenStateExecuting) {\n throw new Error(\"Generator is already running\");\n }\n\n if (state === GenStateCompleted) {\n if (method === \"throw\") {\n throw arg;\n }\n\n // Be forgiving, per 25.3.3.3.3 of the spec:\n // https://people.mozilla.org/~jorendorff/es6-draft.html#sec-generatorresume\n return doneResult();\n }\n\n context.method = method;\n context.arg = arg;\n\n while (true) {\n var delegate = context.delegate;\n if (delegate) {\n var delegateResult = maybeInvokeDelegate(delegate, context);\n if (delegateResult) {\n if (delegateResult === ContinueSentinel) continue;\n return delegateResult;\n }\n }\n\n if (context.method === \"next\") {\n // Setting context._sent for legacy support of Babel's\n // function.sent implementation.\n context.sent = context._sent = context.arg;\n\n } else if (context.method === \"throw\") {\n if (state === GenStateSuspendedStart) {\n state = GenStateCompleted;\n throw context.arg;\n }\n\n context.dispatchException(context.arg);\n\n } else if (context.method === \"return\") {\n context.abrupt(\"return\", context.arg);\n }\n\n state = GenStateExecuting;\n\n var record = tryCatch(innerFn, self, context);\n if (record.type === \"normal\") {\n // If an exception is thrown from innerFn, we leave state ===\n // GenStateExecuting and loop back for another invocation.\n state = context.done\n ? GenStateCompleted\n : GenStateSuspendedYield;\n\n if (record.arg === ContinueSentinel) {\n continue;\n }\n\n return {\n value: record.arg,\n done: context.done\n };\n\n } else if (record.type === \"throw\") {\n state = GenStateCompleted;\n // Dispatch the exception by looping back around to the\n // context.dispatchException(context.arg) call above.\n context.method = \"throw\";\n context.arg = record.arg;\n }\n }\n };\n }\n\n // Call delegate.iterator[context.method](context.arg) and handle the\n // result, either by returning a { value, done } result from the\n // delegate iterator, or by modifying context.method and context.arg,\n // setting context.delegate to null, and returning the ContinueSentinel.\n function maybeInvokeDelegate(delegate, context) {\n var method = delegate.iterator[context.method];\n if (method === undefined) {\n // A .throw or .return when the delegate iterator has no .throw\n // method always terminates the yield* loop.\n context.delegate = null;\n\n if (context.method === \"throw\") {\n // Note: [\"return\"] must be used for ES3 parsing compatibility.\n if (delegate.iterator[\"return\"]) {\n // If the delegate iterator has a return method, give it a\n // chance to clean up.\n context.method = \"return\";\n context.arg = undefined;\n maybeInvokeDelegate(delegate, context);\n\n if (context.method === \"throw\") {\n // If maybeInvokeDelegate(context) changed context.method from\n // \"return\" to \"throw\", let that override the TypeError below.\n return ContinueSentinel;\n }\n }\n\n context.method = \"throw\";\n context.arg = new TypeError(\n \"The iterator does not provide a 'throw' method\");\n }\n\n return ContinueSentinel;\n }\n\n var record = tryCatch(method, delegate.iterator, context.arg);\n\n if (record.type === \"throw\") {\n context.method = \"throw\";\n context.arg = record.arg;\n context.delegate = null;\n return ContinueSentinel;\n }\n\n var info = record.arg;\n\n if (! info) {\n context.method = \"throw\";\n context.arg = new TypeError(\"iterator result is not an object\");\n context.delegate = null;\n return ContinueSentinel;\n }\n\n if (info.done) {\n // Assign the result of the finished delegate to the temporary\n // variable specified by delegate.resultName (see delegateYield).\n context[delegate.resultName] = info.value;\n\n // Resume execution at the desired location (see delegateYield).\n context.next = delegate.nextLoc;\n\n // If context.method was \"throw\" but the delegate handled the\n // exception, let the outer generator proceed normally. If\n // context.method was \"next\", forget context.arg since it has been\n // \"consumed\" by the delegate iterator. If context.method was\n // \"return\", allow the original .return call to continue in the\n // outer generator.\n if (context.method !== \"return\") {\n context.method = \"next\";\n context.arg = undefined;\n }\n\n } else {\n // Re-yield the result returned by the delegate method.\n return info;\n }\n\n // The delegate iterator is finished, so forget it and continue with\n // the outer generator.\n context.delegate = null;\n return ContinueSentinel;\n }\n\n // Define Generator.prototype.{next,throw,return} in terms of the\n // unified ._invoke helper method.\n defineIteratorMethods(Gp);\n\n define(Gp, toStringTagSymbol, \"Generator\");\n\n // A Generator should always return itself as the iterator object when the\n // @@iterator function is called on it. Some browsers' implementations of the\n // iterator prototype chain incorrectly implement this, causing the Generator\n // object to not be returned from this call. This ensures that doesn't happen.\n // See https://github.com/facebook/regenerator/issues/274 for more details.\n Gp[iteratorSymbol] = function() {\n return this;\n };\n\n Gp.toString = function() {\n return \"[object Generator]\";\n };\n\n function pushTryEntry(locs) {\n var entry = { tryLoc: locs[0] };\n\n if (1 in locs) {\n entry.catchLoc = locs[1];\n }\n\n if (2 in locs) {\n entry.finallyLoc = locs[2];\n entry.afterLoc = locs[3];\n }\n\n this.tryEntries.push(entry);\n }\n\n function resetTryEntry(entry) {\n var record = entry.completion || {};\n record.type = \"normal\";\n delete record.arg;\n entry.completion = record;\n }\n\n function Context(tryLocsList) {\n // The root entry object (effectively a try statement without a catch\n // or a finally block) gives us a place to store values thrown from\n // locations where there is no enclosing try statement.\n this.tryEntries = [{ tryLoc: \"root\" }];\n tryLocsList.forEach(pushTryEntry, this);\n this.reset(true);\n }\n\n exports.keys = function(object) {\n var keys = [];\n for (var key in object) {\n keys.push(key);\n }\n keys.reverse();\n\n // Rather than returning an object with a next method, we keep\n // things simple and return the next function itself.\n return function next() {\n while (keys.length) {\n var key = keys.pop();\n if (key in object) {\n next.value = key;\n next.done = false;\n return next;\n }\n }\n\n // To avoid creating an additional object, we just hang the .value\n // and .done properties off the next function object itself. This\n // also ensures that the minifier will not anonymize the function.\n next.done = true;\n return next;\n };\n };\n\n function values(iterable) {\n if (iterable) {\n var iteratorMethod = iterable[iteratorSymbol];\n if (iteratorMethod) {\n return iteratorMethod.call(iterable);\n }\n\n if (typeof iterable.next === \"function\") {\n return iterable;\n }\n\n if (!isNaN(iterable.length)) {\n var i = -1, next = function next() {\n while (++i < iterable.length) {\n if (hasOwn.call(iterable, i)) {\n next.value = iterable[i];\n next.done = false;\n return next;\n }\n }\n\n next.value = undefined;\n next.done = true;\n\n return next;\n };\n\n return next.next = next;\n }\n }\n\n // Return an iterator with no values.\n return { next: doneResult };\n }\n exports.values = values;\n\n function doneResult() {\n return { value: undefined, done: true };\n }\n\n Context.prototype = {\n constructor: Context,\n\n reset: function(skipTempReset) {\n this.prev = 0;\n this.next = 0;\n // Resetting context._sent for legacy support of Babel's\n // function.sent implementation.\n this.sent = this._sent = undefined;\n this.done = false;\n this.delegate = null;\n\n this.method = \"next\";\n this.arg = undefined;\n\n this.tryEntries.forEach(resetTryEntry);\n\n if (!skipTempReset) {\n for (var name in this) {\n // Not sure about the optimal order of these conditions:\n if (name.charAt(0) === \"t\" &&\n hasOwn.call(this, name) &&\n !isNaN(+name.slice(1))) {\n this[name] = undefined;\n }\n }\n }\n },\n\n stop: function() {\n this.done = true;\n\n var rootEntry = this.tryEntries[0];\n var rootRecord = rootEntry.completion;\n if (rootRecord.type === \"throw\") {\n throw rootRecord.arg;\n }\n\n return this.rval;\n },\n\n dispatchException: function(exception) {\n if (this.done) {\n throw exception;\n }\n\n var context = this;\n function handle(loc, caught) {\n record.type = \"throw\";\n record.arg = exception;\n context.next = loc;\n\n if (caught) {\n // If the dispatched exception was caught by a catch block,\n // then let that catch block handle the exception normally.\n context.method = \"next\";\n context.arg = undefined;\n }\n\n return !! caught;\n }\n\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n var record = entry.completion;\n\n if (entry.tryLoc === \"root\") {\n // Exception thrown outside of any try block that could handle\n // it, so set the completion value of the entire function to\n // throw the exception.\n return handle(\"end\");\n }\n\n if (entry.tryLoc <= this.prev) {\n var hasCatch = hasOwn.call(entry, \"catchLoc\");\n var hasFinally = hasOwn.call(entry, \"finallyLoc\");\n\n if (hasCatch && hasFinally) {\n if (this.prev < entry.catchLoc) {\n return handle(entry.catchLoc, true);\n } else if (this.prev < entry.finallyLoc) {\n return handle(entry.finallyLoc);\n }\n\n } else if (hasCatch) {\n if (this.prev < entry.catchLoc) {\n return handle(entry.catchLoc, true);\n }\n\n } else if (hasFinally) {\n if (this.prev < entry.finallyLoc) {\n return handle(entry.finallyLoc);\n }\n\n } else {\n throw new Error(\"try statement without catch or finally\");\n }\n }\n }\n },\n\n abrupt: function(type, arg) {\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n if (entry.tryLoc <= this.prev &&\n hasOwn.call(entry, \"finallyLoc\") &&\n this.prev < entry.finallyLoc) {\n var finallyEntry = entry;\n break;\n }\n }\n\n if (finallyEntry &&\n (type === \"break\" ||\n type === \"continue\") &&\n finallyEntry.tryLoc <= arg &&\n arg <= finallyEntry.finallyLoc) {\n // Ignore the finally entry if control is not jumping to a\n // location outside the try/catch block.\n finallyEntry = null;\n }\n\n var record = finallyEntry ? finallyEntry.completion : {};\n record.type = type;\n record.arg = arg;\n\n if (finallyEntry) {\n this.method = \"next\";\n this.next = finallyEntry.finallyLoc;\n return ContinueSentinel;\n }\n\n return this.complete(record);\n },\n\n complete: function(record, afterLoc) {\n if (record.type === \"throw\") {\n throw record.arg;\n }\n\n if (record.type === \"break\" ||\n record.type === \"continue\") {\n this.next = record.arg;\n } else if (record.type === \"return\") {\n this.rval = this.arg = record.arg;\n this.method = \"return\";\n this.next = \"end\";\n } else if (record.type === \"normal\" && afterLoc) {\n this.next = afterLoc;\n }\n\n return ContinueSentinel;\n },\n\n finish: function(finallyLoc) {\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n if (entry.finallyLoc === finallyLoc) {\n this.complete(entry.completion, entry.afterLoc);\n resetTryEntry(entry);\n return ContinueSentinel;\n }\n }\n },\n\n \"catch\": function(tryLoc) {\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n if (entry.tryLoc === tryLoc) {\n var record = entry.completion;\n if (record.type === \"throw\") {\n var thrown = record.arg;\n resetTryEntry(entry);\n }\n return thrown;\n }\n }\n\n // The context.catch method must only be called with a location\n // argument that corresponds to a known catch block.\n throw new Error(\"illegal catch attempt\");\n },\n\n delegateYield: function(iterable, resultName, nextLoc) {\n this.delegate = {\n iterator: values(iterable),\n resultName: resultName,\n nextLoc: nextLoc\n };\n\n if (this.method === \"next\") {\n // Deliberately forget the last sent value so that we don't\n // accidentally pass it on to the delegate.\n this.arg = undefined;\n }\n\n return ContinueSentinel;\n }\n };\n\n // Regardless of whether this script is executing as a CommonJS module\n // or not, return the runtime object so that we can declare the variable\n // regeneratorRuntime in the outer scope, which allows this module to be\n // injected easily by `bin/regenerator --include-runtime script.js`.\n return exports;\n\n}(\n // If this script is executing as a CommonJS module, use module.exports\n // as the regeneratorRuntime namespace. Otherwise create a new empty\n // object. Either way, the resulting object will be used to initialize\n // the regeneratorRuntime variable at the top of this file.\n typeof module === \"object\" ? module.exports : {}\n));\n\ntry {\n regeneratorRuntime = runtime;\n} catch (accidentalStrictMode) {\n // This module should not be running in strict mode, so the above\n // assignment should always work unless something is misconfigured. Just\n // in case runtime.js accidentally runs in strict mode, we can escape\n // strict mode using a global Function call. This could conceivably fail\n // if a Content Security Policy forbids using Function, but in that case\n // the proper solution is to fix the accidental strict mode problem. If\n // you've misconfigured your bundler to force strict mode and applied a\n // CSP to forbid Function, and you're not willing to fix either of those\n // problems, please detail your unique predicament in a GitHub issue.\n Function(\"r\", \"regeneratorRuntime = r\")(runtime);\n}\n","(function() { module.exports = window[\"eventespresso\"][\"toaster\"]; }());","import { gql } from '@eventespresso/data';\nimport { TICKET_ATTRIBUTES } from '../../queries/tickets';\nimport { PRICE_ATTRIBUTES } from '../../queries/prices';\n\n/**\n * The related prices for a ticket.\n * Can be used to fetch the default prices\n * created for a ticket on the server.\n */\nexport const TICKET_PRICES_ATTRIBUTE: any = gql`\n\tfragment ticketPricesAttribute on EspressoTicket {\n\t\tprices {\n\t\t\tnodes {\n\t\t\t\t...priceAttributes\n\t\t\t}\n\t\t}\n\t}\n\t${PRICE_ATTRIBUTES}\n`;\n\nexport const CREATE_TICKET = gql`\n\tmutation CREATE_TICKET($input: CreateEspressoTicketInput!) {\n\t\tcreateEspressoTicket(input: $input) {\n\t\t\tespressoTicket {\n\t\t\t\t...ticketAttributes\n\t\t\t\t...ticketPricesAttribute # fetch default prices when a ticket is created.\n\t\t\t}\n\t\t}\n\t}\n\t${TICKET_ATTRIBUTES}\n\t${TICKET_PRICES_ATTRIBUTE}\n`;\n\nexport const UPDATE_TICKET = gql`\n\tmutation UPDATE_TICKET($input: UpdateEspressoTicketInput!) {\n\t\tupdateEspressoTicket(input: $input) {\n\t\t\tespressoTicket {\n\t\t\t\t...ticketAttributes\n\t\t\t\t...ticketPricesAttribute # fetch updated prices when a ticket is updated.\n\t\t\t}\n\t\t}\n\t}\n\t${TICKET_ATTRIBUTES}\n\t${TICKET_PRICES_ATTRIBUTE}\n`;\n\nexport const DELETE_TICKET = gql`\n\tmutation DELETE_TICKET($input: DeleteEspressoTicketInput!) {\n\t\tdeleteEspressoTicket(input: $input) {\n\t\t\tespressoTicket {\n\t\t\t\t...ticketAttributes\n\t\t\t}\n\t\t}\n\t}\n\t${TICKET_ATTRIBUTES}\n`;\n\nexport const BULK_UPDATE_TICKETS = gql`\n\tmutation BULK_UPDATE_TICKETS($input: BulkUpdateEspressoTicketInput!) {\n\t\tbulkUpdateEspressoTicket(input: $input) {\n\t\t\tupdated\n\t\t\tfailed\n\t\t}\n\t}\n`;\n\nexport { default as useTicketMutator } from './useTicketMutator';\n\nexport { default as useReorderTickets } from './useReorderTickets';\n\nexport { default as useBulkEditTickets } from './useBulkEditTickets';\n\nexport { default as useBulkDeleteTickets } from './useBulkDeleteTickets';\n\nexport * from './useUpdateTicketQtyByCapacity';\n\nexport * from './types';\n","import { useMemo } from 'react';\nimport { filter } from 'ramda';\n\nimport { useTicketsQuery } from '@eventespresso/data';\nimport { getCacheIds, TicketPred, isNotDefault } from '@eventespresso/predicates';\n\nimport useTicketQueryOptions from './useTicketQueryOptions';\nimport type { Ticket, TicketEdge } from '../../types';\n\nconst useTickets = (filterBy: TicketPred = isNotDefault): Array => {\n\tconst options = useTicketQueryOptions();\n\n\tconst { data } = useTicketsQuery(options);\n\n\tconst nodes = data?.espressoTickets?.nodes || [];\n\n\tconst cacheIds = getCacheIds(nodes);\n\n\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\treturn useMemo(() => filter(filterBy, nodes), [cacheIds]);\n};\n\nexport default useTickets;\n","import { CacheUpdaterFn, useUpdateCache, WriteQueryOptions } from '@eventespresso/data';\n\n/**\n * Updates entity list Apollo cache\n */\nconst useUpdateEntityList = (\n\twriteQueryOptions: WriteQueryOptions = undefined\n): CacheUpdaterFn => {\n\treturn useUpdateCache(writeQueryOptions);\n};\n\nexport default useUpdateEntityList;\n","import { gql } from '@eventespresso/data';\nimport { DATETIME_ATTRIBUTES } from '../../queries/datetimes';\n\nexport const CREATE_DATETIME = gql`\n\tmutation CREATE_DATETIME($input: CreateEspressoDatetimeInput!) {\n\t\tcreateEspressoDatetime(input: $input) {\n\t\t\tespressoDatetime {\n\t\t\t\t...datetimeAttributes\n\t\t\t}\n\t\t}\n\t}\n\t${DATETIME_ATTRIBUTES}\n`;\n\nexport const UPDATE_DATETIME = gql`\n\tmutation UPDATE_DATETIME($input: UpdateEspressoDatetimeInput!) {\n\t\tupdateEspressoDatetime(input: $input) {\n\t\t\tespressoDatetime {\n\t\t\t\t...datetimeAttributes\n\t\t\t}\n\t\t}\n\t}\n\t${DATETIME_ATTRIBUTES}\n`;\n\nexport const DELETE_DATETIME = gql`\n\tmutation DELETE_DATETIME($input: DeleteEspressoDatetimeInput!) {\n\t\tdeleteEspressoDatetime(input: $input) {\n\t\t\tespressoDatetime {\n\t\t\t\t...datetimeAttributes\n\t\t\t}\n\t\t}\n\t}\n\t${DATETIME_ATTRIBUTES}\n`;\n\nexport const BULK_UPDATE_DATETIMES = gql`\n\tmutation BULK_UPDATE_DATETIMES($input: BulkUpdateEspressoDatetimeInput!) {\n\t\tbulkUpdateEspressoDatetime(input: $input) {\n\t\t\tupdated\n\t\t\tfailed\n\t\t}\n\t}\n`;\n\nexport { default as useDatetimeMutator } from './useDatetimeMutator';\n\nexport { default as useDeleteRelatedTickets } from './useDeleteRelatedTickets';\n\nexport { default as useBulkEditDatetimes } from './useBulkEditDatetimes';\n\nexport { default as useBulkDeleteDatetimes } from './useBulkDeleteDatetimes';\n\nexport { default as useReorderDatetimes } from './useReorderDatetimes';\n\nexport * from './types';\n","import { gql } from '@eventespresso/data';\n\nexport const TICKET_ATTRIBUTES: any = gql`\n\tfragment ticketAttributes on EspressoTicket {\n\t\tid\n\t\tdbId\n\t\tcacheId\n\t\tdescription\n\t\tendDate\n\t\tisDefault\n\t\tisExpired\n\t\tisFree\n\t\tisOnSale\n\t\tisPending\n\t\tisRequired\n\t\tisSoldOut\n\t\tisTrashed\n\t\tmax\n\t\tmin\n\t\tname\n\t\torder\n\t\tprice\n\t\tquantity\n\t\tregistrationCount\n\t\treserved\n\t\treverseCalculate\n\t\tsold\n\t\tstartDate\n\t\tuserId\n\t\tuses\n\t\tvisibility\n\t}\n`;\n\nexport const GET_TICKET: any = gql`\n\tquery GET_TICKET($id: ID!) {\n\t\tespressoTicket(id: $id) {\n\t\t\t...ticketAttributes\n\t\t}\n\t}\n\t${TICKET_ATTRIBUTES}\n`;\n\nexport const GET_TICKETS: any = gql`\n\tquery GET_TICKETS($where: EspressoRootQueryTicketsConnectionWhereArgs) {\n\t\tespressoTickets(where: $where) {\n\t\t\tnodes {\n\t\t\t\t...ticketAttributes\n\t\t\t}\n\t\t}\n\t}\n\t${TICKET_ATTRIBUTES}\n`;\n","var Symbol = require('./_Symbol'),\n getRawTag = require('./_getRawTag'),\n objectToString = require('./_objectToString');\n\n/** `Object#toString` result references. */\nvar nullTag = '[object Null]',\n undefinedTag = '[object Undefined]';\n\n/** Built-in value references. */\nvar symToStringTag = Symbol ? Symbol.toStringTag : undefined;\n\n/**\n * The base implementation of `getTag` without fallbacks for buggy environments.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\nfunction baseGetTag(value) {\n if (value == null) {\n return value === undefined ? undefinedTag : nullTag;\n }\n return (symToStringTag && symToStringTag in Object(value))\n ? getRawTag(value)\n : objectToString(value);\n}\n\nmodule.exports = baseGetTag;\n","/**\n * Checks if `value` is object-like. A value is object-like if it's not `null`\n * and has a `typeof` result of \"object\".\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is object-like, else `false`.\n * @example\n *\n * _.isObjectLike({});\n * // => true\n *\n * _.isObjectLike([1, 2, 3]);\n * // => true\n *\n * _.isObjectLike(_.noop);\n * // => false\n *\n * _.isObjectLike(null);\n * // => false\n */\nfunction isObjectLike(value) {\n return value != null && typeof value == 'object';\n}\n\nmodule.exports = isObjectLike;\n","var baseToString = require('./_baseToString');\n\n/**\n * Converts `value` to a string. An empty string is returned for `null`\n * and `undefined` values. The sign of `-0` is preserved.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to convert.\n * @returns {string} Returns the converted string.\n * @example\n *\n * _.toString(null);\n * // => ''\n *\n * _.toString(-0);\n * // => '-0'\n *\n * _.toString([1, 2, 3]);\n * // => '1,2,3'\n */\nfunction toString(value) {\n return value == null ? '' : baseToString(value);\n}\n\nmodule.exports = toString;\n","import { gql } from '@eventespresso/data';\n\nexport const DATETIME_ATTRIBUTES: any = gql`\n\tfragment datetimeAttributes on EspressoDatetime {\n\t\tid\n\t\tdbId\n\t\tcacheId\n\t\tcapacity\n\t\tdescription\n\t\tendDate\n\t\tisActive\n\t\tisExpired\n\t\tisPrimary\n\t\tisSoldOut\n\t\tisTrashed\n\t\tisUpcoming\n\t\tlength\n\t\tname\n\t\torder\n\t\treserved\n\t\tsold\n\t\tstatus\n\t\tstartDate\n\t\tvenue\n\t}\n`;\n\nexport const GET_DATETIME: any = gql`\n\tquery GET_DATETIME($id: ID!) {\n\t\tespressoDatetime(id: $id) {\n\t\t\t...datetimeAttributes\n\t\t}\n\t}\n\t${DATETIME_ATTRIBUTES}\n`;\n\nexport const GET_DATETIMES: any = gql`\n\tquery GET_DATETIMES($where: EspressoRootQueryDatetimesConnectionWhereArgs) {\n\t\tespressoDatetimes(where: $where) {\n\t\t\tnodes {\n\t\t\t\t...datetimeAttributes\n\t\t\t}\n\t\t}\n\t}\n\t${DATETIME_ATTRIBUTES}\n`;\n","import {\n\tentitiesWithGuIdInArray,\n\tentitiesWithGuIdNotInArray,\n\tisActive,\n\tisExpired,\n\tisOnSale,\n\tisPending,\n\tisUpcoming,\n} from '@eventespresso/predicates';\nimport type { AnyObject } from '@eventespresso/utils';\nimport { shiftDate } from '@eventespresso/dates';\nimport type { EntityId } from '@eventespresso/data';\nimport { uuid } from '@eventespresso/utils';\n\nimport { BulkUpdateInput, BulkEditFormBaseShape } from './types';\nimport { Datetime, Ticket, Price } from '../types';\nimport { UpdateDatetimeInput } from '../..';\nimport { UpdateTicketInput } from './tickets';\n\nexport const formToBulkUpdateInput = <\n\tT extends BulkEditFormBaseShape,\n\tE extends Datetime | Ticket,\n\tI extends AnyObject\n>(\n\tformData: T,\n\tallEntities: E[],\n\tselectedIds: EntityId[]\n): BulkUpdateInput => {\n\tconst { shiftDates, ...values } = formData;\n\t// This contains the unique input for each entity.\n\tlet uniqueInputs: BulkUpdateInput['uniqueInputs'] = [];\n\t// we need to shift the dates.\n\tif (shiftDates?.unit && shiftDates?.value && shiftDates?.type) {\n\t\t// get full entity objects from the selected IDs\n\t\tconst selectedEntities = entitiesWithGuIdInArray(allEntities, selectedIds);\n\t\t// keep the date shifter ready\n\t\tconst shiftTheDate = shiftDate(shiftDates);\n\t\t// shift start and end dates for the selected entities\n\t\tuniqueInputs = selectedEntities.map((entity) => {\n\t\t\tconst startDate = shiftTheDate(entity.startDate).toISOString();\n\t\t\tconst endDate = shiftTheDate(entity.endDate).toISOString();\n\t\t\treturn { id: entity.id, startDate, endDate };\n\t\t});\n\t} else {\n\t\t// otherwise we just need the ids for uniqueInputs\n\t\tuniqueInputs = selectedIds.map((id) => ({ id }));\n\t}\n\n\t// we need to add id to shared input to avoid GQL schema yelling at us.\n\tconst sharedInput = { ...values, id: '' };\n\n\treturn {\n\t\tsharedInput,\n\t\tuniqueInputs,\n\t} as BulkUpdateInput;\n};\n\nexport const cacheNodesFromBulkInput = (\n\tinput: BulkUpdateInput,\n\tallEntities: E[]\n): E[] => {\n\t// convert uniqueInputs array to object with ids as keys and the objects as values\n\tconst uniqueInputs = input.uniqueInputs.reduce((inputs, currentInput) => {\n\t\treturn { ...inputs, [currentInput.id]: currentInput };\n\t}, {});\n\n\t// override the data for the selected nodes from the given input\n\tconst nodes = allEntities.map((node) => {\n\t\t// if the node is not in selected nodes\n\t\tif (!uniqueInputs?.[node.id]) {\n\t\t\treturn node;\n\t\t}\n\t\treturn {\n\t\t\t...node,\n\t\t\t...input.sharedInput,\n\t\t\t...uniqueInputs[node.id],\n\t\t\tcacheId: uuid(),\n\t\t};\n\t});\n\n\treturn nodes;\n};\n\nexport const cacheNodesFromBulkDelete = (\n\tentityIds: Array,\n\tallEntities: E[],\n\tdeletePermanently?: boolean\n): E[] => {\n\tif (deletePermanently) {\n\t\treturn entitiesWithGuIdNotInArray(allEntities, entityIds);\n\t}\n\n\t// mark all entities as trashed\n\tconst nodes = allEntities.map((node) => {\n\t\t// if the node is not in selected nodes\n\t\tif (!entityIds.includes(node.id)) {\n\t\t\treturn node;\n\t\t}\n\t\treturn {\n\t\t\t...node,\n\t\t\tisTrashed: true,\n\t\t\tcacheId: uuid(),\n\t\t};\n\t});\n\n\treturn nodes;\n};\n\n/**\n * Updates the boolean date related flags for the given datetime\n * based upon the (possible updated) other fields\n */\nexport const updateDatetimeFlags = (date: Datetime): Datetime => {\n\treturn {\n\t\t...date,\n\t\tisActive: isActive(date, true),\n\t\tisExpired: isExpired(date, true),\n\t\tisUpcoming: isUpcoming(date, true),\n\t};\n};\n\n/**\n * Updates the boolean date related flags for the given ticket\n * based upon the (possible updated) other fields\n */\nexport const updateTicketFlags = (ticket: Ticket): Ticket => {\n\treturn {\n\t\t...ticket,\n\t\tisExpired: isExpired(ticket, true),\n\t\tisFree: !ticket.price,\n\t\tisOnSale: isOnSale(ticket, true),\n\t\tisPending: isPending(ticket, true),\n\t};\n};\n","// ES6 Map\nvar map\ntry {\n map = Map\n} catch (_) { }\nvar set\n\n// ES6 Set\ntry {\n set = Set\n} catch (_) { }\n\nfunction baseClone (src, circulars, clones) {\n // Null/undefined/functions/etc\n if (!src || typeof src !== 'object' || typeof src === 'function') {\n return src\n }\n\n // DOM Node\n if (src.nodeType && 'cloneNode' in src) {\n return src.cloneNode(true)\n }\n\n // Date\n if (src instanceof Date) {\n return new Date(src.getTime())\n }\n\n // RegExp\n if (src instanceof RegExp) {\n return new RegExp(src)\n }\n\n // Arrays\n if (Array.isArray(src)) {\n return src.map(clone)\n }\n\n // ES6 Maps\n if (map && src instanceof map) {\n return new Map(Array.from(src.entries()))\n }\n\n // ES6 Sets\n if (set && src instanceof set) {\n return new Set(Array.from(src.values()))\n }\n\n // Object\n if (src instanceof Object) {\n circulars.push(src)\n var obj = Object.create(src)\n clones.push(obj)\n for (var key in src) {\n var idx = circulars.findIndex(function (i) {\n return i === src[key]\n })\n obj[key] = idx > -1 ? clones[idx] : baseClone(src[key], circulars, clones)\n }\n return obj\n }\n\n // ???\n return src\n}\n\nexport default function clone (src) {\n return baseClone(src, [], [])\n}\n","const toString = Object.prototype.toString;\nconst errorToString = Error.prototype.toString;\nconst regExpToString = RegExp.prototype.toString;\nconst symbolToString = typeof Symbol !== 'undefined' ? Symbol.prototype.toString : () => '';\nconst SYMBOL_REGEXP = /^Symbol\\((.*)\\)(.*)$/;\n\nfunction printNumber(val) {\n if (val != +val) return 'NaN';\n const isNegativeZero = val === 0 && 1 / val < 0;\n return isNegativeZero ? '-0' : '' + val;\n}\n\nfunction printSimpleValue(val, quoteStrings = false) {\n if (val == null || val === true || val === false) return '' + val;\n const typeOf = typeof val;\n if (typeOf === 'number') return printNumber(val);\n if (typeOf === 'string') return quoteStrings ? `\"${val}\"` : val;\n if (typeOf === 'function') return '[Function ' + (val.name || 'anonymous') + ']';\n if (typeOf === 'symbol') return symbolToString.call(val).replace(SYMBOL_REGEXP, 'Symbol($1)');\n const tag = toString.call(val).slice(8, -1);\n if (tag === 'Date') return isNaN(val.getTime()) ? '' + val : val.toISOString(val);\n if (tag === 'Error' || val instanceof Error) return '[' + errorToString.call(val) + ']';\n if (tag === 'RegExp') return regExpToString.call(val);\n return null;\n}\n\nexport default function printValue(value, quoteStrings) {\n let result = printSimpleValue(value, quoteStrings);\n if (result !== null) return result;\n return JSON.stringify(value, function (key, value) {\n let result = printSimpleValue(this[key], quoteStrings);\n if (result !== null) return result;\n return value;\n }, 2);\n}","import printValue from './util/printValue';\nexport let mixed = {\n default: '${path} is invalid',\n required: '${path} is a required field',\n oneOf: '${path} must be one of the following values: ${values}',\n notOneOf: '${path} must not be one of the following values: ${values}',\n notType: ({\n path,\n type,\n value,\n originalValue\n }) => {\n let isCast = originalValue != null && originalValue !== value;\n let msg = `${path} must be a \\`${type}\\` type, ` + `but the final value was: \\`${printValue(value, true)}\\`` + (isCast ? ` (cast from the value \\`${printValue(originalValue, true)}\\`).` : '.');\n\n if (value === null) {\n msg += `\\n If \"null\" is intended as an empty value be sure to mark the schema as \\`.nullable()\\``;\n }\n\n return msg;\n },\n defined: '${path} must be defined'\n};\nexport let string = {\n length: '${path} must be exactly ${length} characters',\n min: '${path} must be at least ${min} characters',\n max: '${path} must be at most ${max} characters',\n matches: '${path} must match the following: \"${regex}\"',\n email: '${path} must be a valid email',\n url: '${path} must be a valid URL',\n uuid: '${path} must be a valid UUID',\n trim: '${path} must be a trimmed string',\n lowercase: '${path} must be a lowercase string',\n uppercase: '${path} must be a upper case string'\n};\nexport let number = {\n min: '${path} must be greater than or equal to ${min}',\n max: '${path} must be less than or equal to ${max}',\n lessThan: '${path} must be less than ${less}',\n moreThan: '${path} must be greater than ${more}',\n positive: '${path} must be a positive number',\n negative: '${path} must be a negative number',\n integer: '${path} must be an integer'\n};\nexport let date = {\n min: '${path} field must be later than ${min}',\n max: '${path} field must be at earlier than ${max}'\n};\nexport let boolean = {\n isValue: '${path} field must be ${value}'\n};\nexport let object = {\n noUnknown: '${path} field has unspecified keys: ${unknown}'\n};\nexport let array = {\n min: '${path} field must have at least ${min} items',\n max: '${path} field must have less than or equal to ${max} items',\n length: '${path} must have ${length} items'\n};\nexport default Object.assign(Object.create(null), {\n mixed,\n string,\n number,\n date,\n object,\n array,\n boolean\n});","const isSchema = obj => obj && obj.__isYupSchema__;\n\nexport default isSchema;","import has from 'lodash/has';\nimport isSchema from './util/isSchema';\n\nclass Condition {\n constructor(refs, options) {\n this.fn = void 0;\n this.refs = refs;\n this.refs = refs;\n\n if (typeof options === 'function') {\n this.fn = options;\n return;\n }\n\n if (!has(options, 'is')) throw new TypeError('`is:` is required for `when()` conditions');\n if (!options.then && !options.otherwise) throw new TypeError('either `then:` or `otherwise:` is required for `when()` conditions');\n let {\n is,\n then,\n otherwise\n } = options;\n let check = typeof is === 'function' ? is : (...values) => values.every(value => value === is);\n\n this.fn = function (...args) {\n let options = args.pop();\n let schema = args.pop();\n let branch = check(...args) ? then : otherwise;\n if (!branch) return undefined;\n if (typeof branch === 'function') return branch(schema);\n return schema.concat(branch.resolve(options));\n };\n }\n\n resolve(base, options) {\n let values = this.refs.map(ref => ref.getValue(options == null ? void 0 : options.value, options == null ? void 0 : options.parent, options == null ? void 0 : options.context));\n let schema = this.fn.apply(base, values.concat(base, options));\n if (schema === undefined || schema === base) return base;\n if (!isSchema(schema)) throw new TypeError('conditions must return a schema object');\n return schema.resolve(options);\n }\n\n}\n\nexport default Condition;","export default function toArray(value) {\n return value == null ? [] : [].concat(value);\n}","function _extends() { _extends = Object.assign || 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); }\n\nimport printValue from './util/printValue';\nimport toArray from './util/toArray';\nlet strReg = /\\$\\{\\s*(\\w+)\\s*\\}/g;\nexport default class ValidationError extends Error {\n static formatError(message, params) {\n const path = params.label || params.path || 'this';\n if (path !== params.path) params = _extends({}, params, {\n path\n });\n if (typeof message === 'string') return message.replace(strReg, (_, key) => printValue(params[key]));\n if (typeof message === 'function') return message(params);\n return message;\n }\n\n static isError(err) {\n return err && err.name === 'ValidationError';\n }\n\n constructor(errorOrErrors, value, field, type) {\n super();\n this.value = void 0;\n this.path = void 0;\n this.type = void 0;\n this.errors = void 0;\n this.params = void 0;\n this.inner = void 0;\n this.name = 'ValidationError';\n this.value = value;\n this.path = field;\n this.type = type;\n this.errors = [];\n this.inner = [];\n toArray(errorOrErrors).forEach(err => {\n if (ValidationError.isError(err)) {\n this.errors.push(...err.errors);\n this.inner = this.inner.concat(err.inner.length ? err.inner : err);\n } else {\n this.errors.push(err);\n }\n });\n this.message = this.errors.length > 1 ? `${this.errors.length} errors occurred` : this.errors[0];\n if (Error.captureStackTrace) Error.captureStackTrace(this, ValidationError);\n }\n\n}","import ValidationError from '../ValidationError';\n\nconst once = cb => {\n let fired = false;\n return (...args) => {\n if (fired) return;\n fired = true;\n cb(...args);\n };\n};\n\nexport default function runTests(options, cb) {\n let {\n endEarly,\n tests,\n args,\n value,\n errors,\n sort,\n path\n } = options;\n let callback = once(cb);\n let count = tests.length;\n const nestedErrors = [];\n errors = errors ? errors : [];\n if (!count) return errors.length ? callback(new ValidationError(errors, value, path)) : callback(null, value);\n\n for (let i = 0; i < tests.length; i++) {\n const test = tests[i];\n test(args, function finishTestRun(err) {\n if (err) {\n // always return early for non validation errors\n if (!ValidationError.isError(err)) {\n return callback(err, value);\n }\n\n if (endEarly) {\n err.value = value;\n return callback(err, value);\n }\n\n nestedErrors.push(err);\n }\n\n if (--count <= 0) {\n if (nestedErrors.length) {\n if (sort) nestedErrors.sort(sort); //show parent errors after the nested ones: name.first, name\n\n if (errors.length) nestedErrors.push(...errors);\n errors = nestedErrors;\n }\n\n if (errors.length) {\n callback(new ValidationError(errors, value, path), value);\n return;\n }\n\n callback(null, value);\n }\n });\n }\n}","import { getter } from 'property-expr';\nconst prefixes = {\n context: '$',\n value: '.'\n};\nexport function create(key, options) {\n return new Reference(key, options);\n}\nexport default class Reference {\n constructor(key, options = {}) {\n this.key = void 0;\n this.isContext = void 0;\n this.isValue = void 0;\n this.isSibling = void 0;\n this.path = void 0;\n this.getter = void 0;\n this.map = void 0;\n if (typeof key !== 'string') throw new TypeError('ref must be a string, got: ' + key);\n this.key = key.trim();\n if (key === '') throw new TypeError('ref must be a non-empty string');\n this.isContext = this.key[0] === prefixes.context;\n this.isValue = this.key[0] === prefixes.value;\n this.isSibling = !this.isContext && !this.isValue;\n let prefix = this.isContext ? prefixes.context : this.isValue ? prefixes.value : '';\n this.path = this.key.slice(prefix.length);\n this.getter = this.path && getter(this.path, true);\n this.map = options.map;\n }\n\n getValue(value, parent, context) {\n let result = this.isContext ? context : this.isValue ? value : parent;\n if (this.getter) result = this.getter(result || {});\n if (this.map) result = this.map(result);\n return result;\n }\n /**\n *\n * @param {*} value\n * @param {Object} options\n * @param {Object=} options.context\n * @param {Object=} options.parent\n */\n\n\n cast(value, options) {\n return this.getValue(value, options == null ? void 0 : options.parent, options == null ? void 0 : options.context);\n }\n\n resolve() {\n return this;\n }\n\n describe() {\n return {\n type: 'ref',\n key: this.key\n };\n }\n\n toString() {\n return `Ref(${this.key})`;\n }\n\n static isRef(value) {\n return value && value.__isYupRef;\n }\n\n} // @ts-ignore\n\nReference.prototype.__isYupRef = true;","function _extends() { _extends = Object.assign || 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); }\n\nfunction _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }\n\nimport mapValues from 'lodash/mapValues';\nimport ValidationError from '../ValidationError';\nimport Ref from '../Reference';\nexport default function createValidation(config) {\n function validate(_ref, cb) {\n let {\n value,\n path = '',\n label,\n options,\n originalValue,\n sync\n } = _ref,\n rest = _objectWithoutPropertiesLoose(_ref, [\"value\", \"path\", \"label\", \"options\", \"originalValue\", \"sync\"]);\n\n const {\n name,\n test,\n params,\n message\n } = config;\n let {\n parent,\n context\n } = options;\n\n function resolve(item) {\n return Ref.isRef(item) ? item.getValue(value, parent, context) : item;\n }\n\n function createError(overrides = {}) {\n const nextParams = mapValues(_extends({\n value,\n originalValue,\n label,\n path: overrides.path || path\n }, params, overrides.params), resolve);\n const error = new ValidationError(ValidationError.formatError(overrides.message || message, nextParams), value, nextParams.path, overrides.type || name);\n error.params = nextParams;\n return error;\n }\n\n let ctx = _extends({\n path,\n parent,\n type: name,\n createError,\n resolve,\n options,\n originalValue\n }, rest);\n\n if (!sync) {\n try {\n Promise.resolve(test.call(ctx, value, ctx)).then(validOrError => {\n if (ValidationError.isError(validOrError)) cb(validOrError);else if (!validOrError) cb(createError());else cb(null, validOrError);\n }).catch(cb);\n } catch (err) {\n cb(err);\n }\n\n return;\n }\n\n let result;\n\n try {\n var _ref2;\n\n result = test.call(ctx, value, ctx);\n\n if (typeof ((_ref2 = result) == null ? void 0 : _ref2.then) === 'function') {\n throw new Error(`Validation test of type: \"${ctx.type}\" returned a Promise during a synchronous validate. ` + `This test will finish after the validate call has returned`);\n }\n } catch (err) {\n cb(err);\n return;\n }\n\n if (ValidationError.isError(result)) cb(result);else if (!result) cb(createError());else cb(null, result);\n }\n\n validate.OPTIONS = config;\n return validate;\n}","import { forEach } from 'property-expr';\n\nlet trim = part => part.substr(0, part.length - 1).substr(1);\n\nexport function getIn(schema, path, value, context = value) {\n let parent, lastPart, lastPartDebug; // root path: ''\n\n if (!path) return {\n parent,\n parentPath: path,\n schema\n };\n forEach(path, (_part, isBracket, isArray) => {\n let part = isBracket ? trim(_part) : _part;\n schema = schema.resolve({\n context,\n parent,\n value\n });\n\n if (schema.innerType) {\n let idx = isArray ? parseInt(part, 10) : 0;\n\n if (value && idx >= value.length) {\n throw new Error(`Yup.reach cannot resolve an array item at index: ${_part}, in the path: ${path}. ` + `because there is no value at that index. `);\n }\n\n parent = value;\n value = value && value[idx];\n schema = schema.innerType;\n } // sometimes the array index part of a path doesn't exist: \"nested.arr.child\"\n // in these cases the current part is the next schema and should be processed\n // in this iteration. For cases where the index signature is included this\n // check will fail and we'll handle the `child` part on the next iteration like normal\n\n\n if (!isArray) {\n if (!schema.fields || !schema.fields[part]) throw new Error(`The schema does not contain the path: ${path}. ` + `(failed at: ${lastPartDebug} which is a type: \"${schema._type}\")`);\n parent = value;\n value = value && value[part];\n schema = schema.fields[part];\n }\n\n lastPart = part;\n lastPartDebug = isBracket ? '[' + _part + ']' : '.' + _part;\n });\n return {\n schema,\n parent,\n parentPath: lastPart\n };\n}\n\nconst reach = (obj, path, value, context) => getIn(obj, path, value, context).schema;\n\nexport default reach;","import Reference from '../Reference';\nexport default class ReferenceSet {\n constructor() {\n this.list = void 0;\n this.refs = void 0;\n this.list = new Set();\n this.refs = new Map();\n }\n\n get size() {\n return this.list.size + this.refs.size;\n }\n\n describe() {\n const description = [];\n\n for (const item of this.list) description.push(item);\n\n for (const [, ref] of this.refs) description.push(ref.describe());\n\n return description;\n }\n\n toArray() {\n return Array.from(this.list).concat(Array.from(this.refs.values()));\n }\n\n resolveAll(resolve) {\n return this.toArray().reduce((acc, e) => acc.concat(Reference.isRef(e) ? resolve(e) : e), []);\n }\n\n add(value) {\n Reference.isRef(value) ? this.refs.set(value.key, value) : this.list.add(value);\n }\n\n delete(value) {\n Reference.isRef(value) ? this.refs.delete(value.key) : this.list.delete(value);\n }\n\n clone() {\n const next = new ReferenceSet();\n next.list = new Set(this.list);\n next.refs = new Map(this.refs);\n return next;\n }\n\n merge(newItems, removeItems) {\n const next = this.clone();\n newItems.list.forEach(value => next.add(value));\n newItems.refs.forEach(value => next.add(value));\n removeItems.list.forEach(value => next.delete(value));\n removeItems.refs.forEach(value => next.delete(value));\n return next;\n }\n\n}","function _extends() { _extends = Object.assign || 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); }\n\n// @ts-ignore\nimport cloneDeep from 'nanoclone';\nimport { mixed as locale } from './locale';\nimport Condition from './Condition';\nimport runTests from './util/runTests';\nimport createValidation from './util/createValidation';\nimport printValue from './util/printValue';\nimport Ref from './Reference';\nimport { getIn } from './util/reach';\nimport ValidationError from './ValidationError';\nimport ReferenceSet from './util/ReferenceSet';\nimport toArray from './util/toArray'; // const UNSET = 'unset' as const;\n\nexport default class BaseSchema {\n constructor(options) {\n this.deps = [];\n this.tests = void 0;\n this.transforms = void 0;\n this.conditions = [];\n this._mutate = void 0;\n this._typeError = void 0;\n this._whitelist = new ReferenceSet();\n this._blacklist = new ReferenceSet();\n this.exclusiveTests = Object.create(null);\n this.spec = void 0;\n this.tests = [];\n this.transforms = [];\n this.withMutation(() => {\n this.typeError(locale.notType);\n });\n this.type = (options == null ? void 0 : options.type) || 'mixed';\n this.spec = _extends({\n strip: false,\n strict: false,\n abortEarly: true,\n recursive: true,\n nullable: false,\n presence: 'optional'\n }, options == null ? void 0 : options.spec);\n } // TODO: remove\n\n\n get _type() {\n return this.type;\n }\n\n _typeCheck(_value) {\n return true;\n }\n\n clone(spec) {\n if (this._mutate) {\n if (spec) Object.assign(this.spec, spec);\n return this;\n } // if the nested value is a schema we can skip cloning, since\n // they are already immutable\n\n\n const next = Object.create(Object.getPrototypeOf(this)); // @ts-expect-error this is readonly\n\n next.type = this.type;\n next._typeError = this._typeError;\n next._whitelistError = this._whitelistError;\n next._blacklistError = this._blacklistError;\n next._whitelist = this._whitelist.clone();\n next._blacklist = this._blacklist.clone();\n next.exclusiveTests = _extends({}, this.exclusiveTests); // @ts-expect-error this is readonly\n\n next.deps = [...this.deps];\n next.conditions = [...this.conditions];\n next.tests = [...this.tests];\n next.transforms = [...this.transforms];\n next.spec = cloneDeep(_extends({}, this.spec, spec));\n return next;\n }\n\n label(label) {\n let next = this.clone();\n next.spec.label = label;\n return next;\n }\n\n meta(...args) {\n if (args.length === 0) return this.spec.meta;\n let next = this.clone();\n next.spec.meta = Object.assign(next.spec.meta || {}, args[0]);\n return next;\n } // withContext(): BaseSchema<\n // TCast,\n // TContext,\n // TOutput\n // > {\n // return this as any;\n // }\n\n\n withMutation(fn) {\n let before = this._mutate;\n this._mutate = true;\n let result = fn(this);\n this._mutate = before;\n return result;\n }\n\n concat(schema) {\n if (!schema || schema === this) return this;\n if (schema.type !== this.type && this.type !== 'mixed') throw new TypeError(`You cannot \\`concat()\\` schema's of different types: ${this.type} and ${schema.type}`);\n let base = this;\n let combined = schema.clone();\n\n const mergedSpec = _extends({}, base.spec, combined.spec); // if (combined.spec.nullable === UNSET)\n // mergedSpec.nullable = base.spec.nullable;\n // if (combined.spec.presence === UNSET)\n // mergedSpec.presence = base.spec.presence;\n\n\n combined.spec = mergedSpec;\n combined._typeError || (combined._typeError = base._typeError);\n combined._whitelistError || (combined._whitelistError = base._whitelistError);\n combined._blacklistError || (combined._blacklistError = base._blacklistError); // manually merge the blacklist/whitelist (the other `schema` takes\n // precedence in case of conflicts)\n\n combined._whitelist = base._whitelist.merge(schema._whitelist, schema._blacklist);\n combined._blacklist = base._blacklist.merge(schema._blacklist, schema._whitelist); // start with the current tests\n\n combined.tests = base.tests;\n combined.exclusiveTests = base.exclusiveTests; // manually add the new tests to ensure\n // the deduping logic is consistent\n\n combined.withMutation(next => {\n schema.tests.forEach(fn => {\n next.test(fn.OPTIONS);\n });\n });\n combined.transforms = [...base.transforms, ...combined.transforms];\n return combined;\n }\n\n isType(v) {\n if (this.spec.nullable && v === null) return true;\n return this._typeCheck(v);\n }\n\n resolve(options) {\n let schema = this;\n\n if (schema.conditions.length) {\n let conditions = schema.conditions;\n schema = schema.clone();\n schema.conditions = [];\n schema = conditions.reduce((schema, condition) => condition.resolve(schema, options), schema);\n schema = schema.resolve(options);\n }\n\n return schema;\n }\n /**\n *\n * @param {*} value\n * @param {Object} options\n * @param {*=} options.parent\n * @param {*=} options.context\n */\n\n\n cast(value, options = {}) {\n let resolvedSchema = this.resolve(_extends({\n value\n }, options));\n\n let result = resolvedSchema._cast(value, options);\n\n if (value !== undefined && options.assert !== false && resolvedSchema.isType(result) !== true) {\n let formattedValue = printValue(value);\n let formattedResult = printValue(result);\n throw new TypeError(`The value of ${options.path || 'field'} could not be cast to a value ` + `that satisfies the schema type: \"${resolvedSchema._type}\". \\n\\n` + `attempted value: ${formattedValue} \\n` + (formattedResult !== formattedValue ? `result of cast: ${formattedResult}` : ''));\n }\n\n return result;\n }\n\n _cast(rawValue, _options) {\n let value = rawValue === undefined ? rawValue : this.transforms.reduce((value, fn) => fn.call(this, value, rawValue, this), rawValue);\n\n if (value === undefined) {\n value = this.getDefault();\n }\n\n return value;\n }\n\n _validate(_value, options = {}, cb) {\n let {\n sync,\n path,\n from = [],\n originalValue = _value,\n strict = this.spec.strict,\n abortEarly = this.spec.abortEarly\n } = options;\n let value = _value;\n\n if (!strict) {\n // this._validating = true;\n value = this._cast(value, _extends({\n assert: false\n }, options)); // this._validating = false;\n } // value is cast, we can check if it meets type requirements\n\n\n let args = {\n value,\n path,\n options,\n originalValue,\n schema: this,\n label: this.spec.label,\n sync,\n from\n };\n let initialTests = [];\n if (this._typeError) initialTests.push(this._typeError);\n let finalTests = [];\n if (this._whitelistError) finalTests.push(this._whitelistError);\n if (this._blacklistError) finalTests.push(this._blacklistError);\n runTests({\n args,\n value,\n path,\n sync,\n tests: initialTests,\n endEarly: abortEarly\n }, err => {\n if (err) return void cb(err, value);\n runTests({\n tests: this.tests.concat(finalTests),\n args,\n path,\n sync,\n value,\n endEarly: abortEarly\n }, cb);\n });\n }\n\n validate(value, options, maybeCb) {\n let schema = this.resolve(_extends({}, options, {\n value\n })); // callback case is for nested validations\n\n return typeof maybeCb === 'function' ? schema._validate(value, options, maybeCb) : new Promise((resolve, reject) => schema._validate(value, options, (err, value) => {\n if (err) reject(err);else resolve(value);\n }));\n }\n\n validateSync(value, options) {\n let schema = this.resolve(_extends({}, options, {\n value\n }));\n let result;\n\n schema._validate(value, _extends({}, options, {\n sync: true\n }), (err, value) => {\n if (err) throw err;\n result = value;\n });\n\n return result;\n }\n\n isValid(value, options) {\n return this.validate(value, options).then(() => true, err => {\n if (ValidationError.isError(err)) return false;\n throw err;\n });\n }\n\n isValidSync(value, options) {\n try {\n this.validateSync(value, options);\n return true;\n } catch (err) {\n if (ValidationError.isError(err)) return false;\n throw err;\n }\n }\n\n _getDefault() {\n let defaultValue = this.spec.default;\n\n if (defaultValue == null) {\n return defaultValue;\n }\n\n return typeof defaultValue === 'function' ? defaultValue.call(this) : cloneDeep(defaultValue);\n }\n\n getDefault(options) {\n let schema = this.resolve(options || {});\n return schema._getDefault();\n }\n\n default(def) {\n if (arguments.length === 0) {\n return this._getDefault();\n }\n\n let next = this.clone({\n default: def\n });\n return next;\n }\n\n strict(isStrict = true) {\n let next = this.clone();\n next.spec.strict = isStrict;\n return next;\n }\n\n _isPresent(value) {\n return value != null;\n }\n\n defined(message = locale.defined) {\n return this.test({\n message,\n name: 'defined',\n exclusive: true,\n\n test(value) {\n return value !== undefined;\n }\n\n });\n }\n\n required(message = locale.required) {\n return this.clone({\n presence: 'required'\n }).withMutation(s => s.test({\n message,\n name: 'required',\n exclusive: true,\n\n test(value) {\n return this.schema._isPresent(value);\n }\n\n }));\n }\n\n notRequired() {\n let next = this.clone({\n presence: 'optional'\n });\n next.tests = next.tests.filter(test => test.OPTIONS.name !== 'required');\n return next;\n }\n\n nullable(isNullable = true) {\n let next = this.clone({\n nullable: isNullable !== false\n });\n return next;\n }\n\n transform(fn) {\n let next = this.clone();\n next.transforms.push(fn);\n return next;\n }\n /**\n * Adds a test function to the schema's queue of tests.\n * tests can be exclusive or non-exclusive.\n *\n * - exclusive tests, will replace any existing tests of the same name.\n * - non-exclusive: can be stacked\n *\n * If a non-exclusive test is added to a schema with an exclusive test of the same name\n * the exclusive test is removed and further tests of the same name will be stacked.\n *\n * If an exclusive test is added to a schema with non-exclusive tests of the same name\n * the previous tests are removed and further tests of the same name will replace each other.\n */\n\n\n test(...args) {\n let opts;\n\n if (args.length === 1) {\n if (typeof args[0] === 'function') {\n opts = {\n test: args[0]\n };\n } else {\n opts = args[0];\n }\n } else if (args.length === 2) {\n opts = {\n name: args[0],\n test: args[1]\n };\n } else {\n opts = {\n name: args[0],\n message: args[1],\n test: args[2]\n };\n }\n\n if (opts.message === undefined) opts.message = locale.default;\n if (typeof opts.test !== 'function') throw new TypeError('`test` is a required parameters');\n let next = this.clone();\n let validate = createValidation(opts);\n let isExclusive = opts.exclusive || opts.name && next.exclusiveTests[opts.name] === true;\n\n if (opts.exclusive) {\n if (!opts.name) throw new TypeError('Exclusive tests must provide a unique `name` identifying the test');\n }\n\n if (opts.name) next.exclusiveTests[opts.name] = !!opts.exclusive;\n next.tests = next.tests.filter(fn => {\n if (fn.OPTIONS.name === opts.name) {\n if (isExclusive) return false;\n if (fn.OPTIONS.test === validate.OPTIONS.test) return false;\n }\n\n return true;\n });\n next.tests.push(validate);\n return next;\n }\n\n when(keys, options) {\n if (!Array.isArray(keys) && typeof keys !== 'string') {\n options = keys;\n keys = '.';\n }\n\n let next = this.clone();\n let deps = toArray(keys).map(key => new Ref(key));\n deps.forEach(dep => {\n // @ts-ignore\n if (dep.isSibling) next.deps.push(dep.key);\n });\n next.conditions.push(new Condition(deps, options));\n return next;\n }\n\n typeError(message) {\n let next = this.clone();\n next._typeError = createValidation({\n message,\n name: 'typeError',\n\n test(value) {\n if (value !== undefined && !this.schema.isType(value)) return this.createError({\n params: {\n type: this.schema._type\n }\n });\n return true;\n }\n\n });\n return next;\n }\n\n oneOf(enums, message = locale.oneOf) {\n let next = this.clone();\n enums.forEach(val => {\n next._whitelist.add(val);\n\n next._blacklist.delete(val);\n });\n next._whitelistError = createValidation({\n message,\n name: 'oneOf',\n\n test(value) {\n if (value === undefined) return true;\n let valids = this.schema._whitelist;\n let resolved = valids.resolveAll(this.resolve);\n return resolved.includes(value) ? true : this.createError({\n params: {\n values: valids.toArray().join(', '),\n resolved\n }\n });\n }\n\n });\n return next;\n }\n\n notOneOf(enums, message = locale.notOneOf) {\n let next = this.clone();\n enums.forEach(val => {\n next._blacklist.add(val);\n\n next._whitelist.delete(val);\n });\n next._blacklistError = createValidation({\n message,\n name: 'notOneOf',\n\n test(value) {\n let invalids = this.schema._blacklist;\n let resolved = invalids.resolveAll(this.resolve);\n if (resolved.includes(value)) return this.createError({\n params: {\n values: invalids.toArray().join(', '),\n resolved\n }\n });\n return true;\n }\n\n });\n return next;\n }\n\n strip(strip = true) {\n let next = this.clone();\n next.spec.strip = strip;\n return next;\n }\n\n describe() {\n const next = this.clone();\n const {\n label,\n meta\n } = next.spec;\n const description = {\n meta,\n label,\n type: next.type,\n oneOf: next._whitelist.describe(),\n notOneOf: next._blacklist.describe(),\n tests: next.tests.map(fn => ({\n name: fn.OPTIONS.name,\n params: fn.OPTIONS.params\n })).filter((n, idx, list) => list.findIndex(c => c.name === n.name) === idx)\n };\n return description;\n }\n\n} // eslint-disable-next-line @typescript-eslint/no-unused-vars\n\n// @ts-expect-error\nBaseSchema.prototype.__isYupSchema__ = true;\n\nfor (const method of ['validate', 'validateSync']) BaseSchema.prototype[`${method}At`] = function (path, value, options = {}) {\n const {\n parent,\n parentPath,\n schema\n } = getIn(this, path, value, options.context);\n return schema[method](parent && parent[parentPath], _extends({}, options, {\n parent,\n path\n }));\n};\n\nfor (const alias of ['equals', 'is']) BaseSchema.prototype[alias] = BaseSchema.prototype.oneOf;\n\nfor (const alias of ['not', 'nope']) BaseSchema.prototype[alias] = BaseSchema.prototype.notOneOf;\n\nBaseSchema.prototype.optional = BaseSchema.prototype.notRequired;","import BaseSchema from './schema';\nconst Mixed = BaseSchema;\nexport default Mixed;\nexport function create() {\n return new Mixed();\n} // XXX: this is using the Base schema so that `addMethod(mixed)` works as a base class\n\ncreate.prototype = Mixed.prototype;","const isAbsent = value => value == null;\n\nexport default isAbsent;","import BaseSchema from './schema';\nimport { boolean as locale } from './locale';\nimport isAbsent from './util/isAbsent';\nexport function create() {\n return new BooleanSchema();\n}\nexport default class BooleanSchema extends BaseSchema {\n constructor() {\n super({\n type: 'boolean'\n });\n this.withMutation(() => {\n this.transform(function (value) {\n if (!this.isType(value)) {\n if (/^(true|1)$/i.test(String(value))) return true;\n if (/^(false|0)$/i.test(String(value))) return false;\n }\n\n return value;\n });\n });\n }\n\n _typeCheck(v) {\n if (v instanceof Boolean) v = v.valueOf();\n return typeof v === 'boolean';\n }\n\n isTrue(message = locale.isValue) {\n return this.test({\n message,\n name: 'is-value',\n exclusive: true,\n params: {\n value: 'true'\n },\n\n test(value) {\n return isAbsent(value) || value === true;\n }\n\n });\n }\n\n isFalse(message = locale.isValue) {\n return this.test({\n message,\n name: 'is-value',\n exclusive: true,\n params: {\n value: 'false'\n },\n\n test(value) {\n return isAbsent(value) || value === false;\n }\n\n });\n }\n\n}\ncreate.prototype = BooleanSchema.prototype;","import { string as locale } from './locale';\nimport isAbsent from './util/isAbsent';\nimport BaseSchema from './schema'; // eslint-disable-next-line\n\nlet rEmail = /^((([a-z]|\\d|[!#\\$%&'\\*\\+\\-\\/=\\?\\^_`{\\|}~]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])+(\\.([a-z]|\\d|[!#\\$%&'\\*\\+\\-\\/=\\?\\^_`{\\|}~]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])+)*)|((\\x22)((((\\x20|\\x09)*(\\x0d\\x0a))?(\\x20|\\x09)+)?(([\\x01-\\x08\\x0b\\x0c\\x0e-\\x1f\\x7f]|\\x21|[\\x23-\\x5b]|[\\x5d-\\x7e]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(\\\\([\\x01-\\x09\\x0b\\x0c\\x0d-\\x7f]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]))))*(((\\x20|\\x09)*(\\x0d\\x0a))?(\\x20|\\x09)+)?(\\x22)))@((([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])*([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])))\\.)+(([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])*([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])))$/i; // eslint-disable-next-line\n\nlet rUrl = /^((https?|ftp):)?\\/\\/(((([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(%[\\da-f]{2})|[!\\$&'\\(\\)\\*\\+,;=]|:)*@)?(((\\d|[1-9]\\d|1\\d\\d|2[0-4]\\d|25[0-5])\\.(\\d|[1-9]\\d|1\\d\\d|2[0-4]\\d|25[0-5])\\.(\\d|[1-9]\\d|1\\d\\d|2[0-4]\\d|25[0-5])\\.(\\d|[1-9]\\d|1\\d\\d|2[0-4]\\d|25[0-5]))|((([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])*([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])))\\.)+(([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])*([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])))\\.?)(:\\d*)?)(\\/((([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(%[\\da-f]{2})|[!\\$&'\\(\\)\\*\\+,;=]|:|@)+(\\/(([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(%[\\da-f]{2})|[!\\$&'\\(\\)\\*\\+,;=]|:|@)*)*)?)?(\\?((([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(%[\\da-f]{2})|[!\\$&'\\(\\)\\*\\+,;=]|:|@)|[\\uE000-\\uF8FF]|\\/|\\?)*)?(\\#((([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(%[\\da-f]{2})|[!\\$&'\\(\\)\\*\\+,;=]|:|@)|\\/|\\?)*)?$/i; // eslint-disable-next-line\n\nlet rUUID = /^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;\n\nlet isTrimmed = value => isAbsent(value) || value === value.trim();\n\nlet objStringTag = {}.toString();\nexport function create() {\n return new StringSchema();\n}\nexport default class StringSchema extends BaseSchema {\n constructor() {\n super({\n type: 'string'\n });\n this.withMutation(() => {\n this.transform(function (value) {\n if (this.isType(value)) return value;\n if (Array.isArray(value)) return value;\n const strValue = value != null && value.toString ? value.toString() : value;\n if (strValue === objStringTag) return value;\n return strValue;\n });\n });\n }\n\n _typeCheck(value) {\n if (value instanceof String) value = value.valueOf();\n return typeof value === 'string';\n }\n\n _isPresent(value) {\n return super._isPresent(value) && !!value.length;\n }\n\n length(length, message = locale.length) {\n return this.test({\n message,\n name: 'length',\n exclusive: true,\n params: {\n length\n },\n\n test(value) {\n return isAbsent(value) || value.length === this.resolve(length);\n }\n\n });\n }\n\n min(min, message = locale.min) {\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n min\n },\n\n test(value) {\n return isAbsent(value) || value.length >= this.resolve(min);\n }\n\n });\n }\n\n max(max, message = locale.max) {\n return this.test({\n name: 'max',\n exclusive: true,\n message,\n params: {\n max\n },\n\n test(value) {\n return isAbsent(value) || value.length <= this.resolve(max);\n }\n\n });\n }\n\n matches(regex, options) {\n let excludeEmptyString = false;\n let message;\n let name;\n\n if (options) {\n if (typeof options === 'object') {\n ({\n excludeEmptyString = false,\n message,\n name\n } = options);\n } else {\n message = options;\n }\n }\n\n return this.test({\n name: name || 'matches',\n message: message || locale.matches,\n params: {\n regex\n },\n test: value => isAbsent(value) || value === '' && excludeEmptyString || value.search(regex) !== -1\n });\n }\n\n email(message = locale.email) {\n return this.matches(rEmail, {\n name: 'email',\n message,\n excludeEmptyString: true\n });\n }\n\n url(message = locale.url) {\n return this.matches(rUrl, {\n name: 'url',\n message,\n excludeEmptyString: true\n });\n }\n\n uuid(message = locale.uuid) {\n return this.matches(rUUID, {\n name: 'uuid',\n message,\n excludeEmptyString: false\n });\n } //-- transforms --\n\n\n ensure() {\n return this.default('').transform(val => val === null ? '' : val);\n }\n\n trim(message = locale.trim) {\n return this.transform(val => val != null ? val.trim() : val).test({\n message,\n name: 'trim',\n test: isTrimmed\n });\n }\n\n lowercase(message = locale.lowercase) {\n return this.transform(value => !isAbsent(value) ? value.toLowerCase() : value).test({\n message,\n name: 'string_case',\n exclusive: true,\n test: value => isAbsent(value) || value === value.toLowerCase()\n });\n }\n\n uppercase(message = locale.uppercase) {\n return this.transform(value => !isAbsent(value) ? value.toUpperCase() : value).test({\n message,\n name: 'string_case',\n exclusive: true,\n test: value => isAbsent(value) || value === value.toUpperCase()\n });\n }\n\n}\ncreate.prototype = StringSchema.prototype; //\n// String Interfaces\n//","import { number as locale } from './locale';\nimport isAbsent from './util/isAbsent';\nimport BaseSchema from './schema';\n\nlet isNaN = value => value != +value;\n\nexport function create() {\n return new NumberSchema();\n}\nexport default class NumberSchema extends BaseSchema {\n constructor() {\n super({\n type: 'number'\n });\n this.withMutation(() => {\n this.transform(function (value) {\n let parsed = value;\n\n if (typeof parsed === 'string') {\n parsed = parsed.replace(/\\s/g, '');\n if (parsed === '') return NaN; // don't use parseFloat to avoid positives on alpha-numeric strings\n\n parsed = +parsed;\n }\n\n if (this.isType(parsed)) return parsed;\n return parseFloat(parsed);\n });\n });\n }\n\n _typeCheck(value) {\n if (value instanceof Number) value = value.valueOf();\n return typeof value === 'number' && !isNaN(value);\n }\n\n min(min, message = locale.min) {\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n min\n },\n\n test(value) {\n return isAbsent(value) || value >= this.resolve(min);\n }\n\n });\n }\n\n max(max, message = locale.max) {\n return this.test({\n message,\n name: 'max',\n exclusive: true,\n params: {\n max\n },\n\n test(value) {\n return isAbsent(value) || value <= this.resolve(max);\n }\n\n });\n }\n\n lessThan(less, message = locale.lessThan) {\n return this.test({\n message,\n name: 'max',\n exclusive: true,\n params: {\n less\n },\n\n test(value) {\n return isAbsent(value) || value < this.resolve(less);\n }\n\n });\n }\n\n moreThan(more, message = locale.moreThan) {\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n more\n },\n\n test(value) {\n return isAbsent(value) || value > this.resolve(more);\n }\n\n });\n }\n\n positive(msg = locale.positive) {\n return this.moreThan(0, msg);\n }\n\n negative(msg = locale.negative) {\n return this.lessThan(0, msg);\n }\n\n integer(message = locale.integer) {\n return this.test({\n name: 'integer',\n message,\n test: val => isAbsent(val) || Number.isInteger(val)\n });\n }\n\n truncate() {\n return this.transform(value => !isAbsent(value) ? value | 0 : value);\n }\n\n round(method) {\n var _method;\n\n let avail = ['ceil', 'floor', 'round', 'trunc'];\n method = ((_method = method) == null ? void 0 : _method.toLowerCase()) || 'round'; // this exists for symemtry with the new Math.trunc\n\n if (method === 'trunc') return this.truncate();\n if (avail.indexOf(method.toLowerCase()) === -1) throw new TypeError('Only valid options for round() are: ' + avail.join(', '));\n return this.transform(value => !isAbsent(value) ? Math[method](value) : value);\n }\n\n}\ncreate.prototype = NumberSchema.prototype; //\n// Number Interfaces\n//","/* eslint-disable */\n\n/**\n *\n * Date.parse with progressive enhancement for ISO 8601 \n * NON-CONFORMANT EDITION.\n * © 2011 Colin Snover \n * Released under MIT license.\n */\n// 1 YYYY 2 MM 3 DD 4 HH 5 mm 6 ss 7 msec 8 Z 9 ± 10 tzHH 11 tzmm\nvar isoReg = /^(\\d{4}|[+\\-]\\d{6})(?:-?(\\d{2})(?:-?(\\d{2}))?)?(?:[ T]?(\\d{2}):?(\\d{2})(?::?(\\d{2})(?:[,\\.](\\d{1,}))?)?(?:(Z)|([+\\-])(\\d{2})(?::?(\\d{2}))?)?)?$/;\nexport default function parseIsoDate(date) {\n var numericKeys = [1, 4, 5, 6, 7, 10, 11],\n minutesOffset = 0,\n timestamp,\n struct;\n\n if (struct = isoReg.exec(date)) {\n // avoid NaN timestamps caused by “undefined” values being passed to Date.UTC\n for (var i = 0, k; k = numericKeys[i]; ++i) struct[k] = +struct[k] || 0; // allow undefined days and months\n\n\n struct[2] = (+struct[2] || 1) - 1;\n struct[3] = +struct[3] || 1; // allow arbitrary sub-second precision beyond milliseconds\n\n struct[7] = struct[7] ? String(struct[7]).substr(0, 3) : 0; // timestamps without timezone identifiers should be considered local time\n\n if ((struct[8] === undefined || struct[8] === '') && (struct[9] === undefined || struct[9] === '')) timestamp = +new Date(struct[1], struct[2], struct[3], struct[4], struct[5], struct[6], struct[7]);else {\n if (struct[8] !== 'Z' && struct[9] !== undefined) {\n minutesOffset = struct[10] * 60 + struct[11];\n if (struct[9] === '+') minutesOffset = 0 - minutesOffset;\n }\n\n timestamp = Date.UTC(struct[1], struct[2], struct[3], struct[4], struct[5] + minutesOffset, struct[6], struct[7]);\n }\n } else timestamp = Date.parse ? Date.parse(date) : NaN;\n\n return timestamp;\n}","// @ts-ignore\nimport isoParse from './util/isodate';\nimport { date as locale } from './locale';\nimport isAbsent from './util/isAbsent';\nimport Ref from './Reference';\nimport BaseSchema from './schema';\nlet invalidDate = new Date('');\n\nlet isDate = obj => Object.prototype.toString.call(obj) === '[object Date]';\n\nexport function create() {\n return new DateSchema();\n}\nexport default class DateSchema extends BaseSchema {\n constructor() {\n super({\n type: 'date'\n });\n this.withMutation(() => {\n this.transform(function (value) {\n if (this.isType(value)) return value;\n value = isoParse(value); // 0 is a valid timestamp equivalent to 1970-01-01T00:00:00Z(unix epoch) or before.\n\n return !isNaN(value) ? new Date(value) : invalidDate;\n });\n });\n }\n\n _typeCheck(v) {\n return isDate(v) && !isNaN(v.getTime());\n }\n\n prepareParam(ref, name) {\n let param;\n\n if (!Ref.isRef(ref)) {\n let cast = this.cast(ref);\n if (!this._typeCheck(cast)) throw new TypeError(`\\`${name}\\` must be a Date or a value that can be \\`cast()\\` to a Date`);\n param = cast;\n } else {\n param = ref;\n }\n\n return param;\n }\n\n min(min, message = locale.min) {\n let limit = this.prepareParam(min, 'min');\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n min\n },\n\n test(value) {\n return isAbsent(value) || value >= this.resolve(limit);\n }\n\n });\n }\n\n max(max, message = locale.max) {\n let limit = this.prepareParam(max, 'max');\n return this.test({\n message,\n name: 'max',\n exclusive: true,\n params: {\n max\n },\n\n test(value) {\n return isAbsent(value) || value <= this.resolve(limit);\n }\n\n });\n }\n\n}\nDateSchema.INVALID_DATE = invalidDate;\ncreate.prototype = DateSchema.prototype;\ncreate.INVALID_DATE = invalidDate;","import has from 'lodash/has'; // @ts-expect-error\n\nimport toposort from 'toposort';\nimport { split } from 'property-expr';\nimport Ref from '../Reference';\nimport isSchema from './isSchema';\nexport default function sortFields(fields, excludedEdges = []) {\n let edges = [];\n let nodes = new Set();\n let excludes = new Set(excludedEdges.map(([a, b]) => `${a}-${b}`));\n\n function addNode(depPath, key) {\n let node = split(depPath)[0];\n nodes.add(node);\n if (!excludes.has(`${key}-${node}`)) edges.push([key, node]);\n }\n\n for (const key in fields) if (has(fields, key)) {\n let value = fields[key];\n nodes.add(key);\n if (Ref.isRef(value) && value.isSibling) addNode(value.path, key);else if (isSchema(value) && 'deps' in value) value.deps.forEach(path => addNode(path, key));\n }\n\n return toposort.array(Array.from(nodes), edges).reverse();\n}","function findIndex(arr, err) {\n let idx = Infinity;\n arr.some((key, ii) => {\n var _err$path;\n\n if (((_err$path = err.path) == null ? void 0 : _err$path.indexOf(key)) !== -1) {\n idx = ii;\n return true;\n }\n });\n return idx;\n}\n\nexport default function sortByKeyOrder(keys) {\n return (a, b) => {\n return findIndex(keys, a) - findIndex(keys, b);\n };\n}","function _extends() { _extends = Object.assign || 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); }\n\nimport has from 'lodash/has';\nimport snakeCase from 'lodash/snakeCase';\nimport camelCase from 'lodash/camelCase';\nimport mapKeys from 'lodash/mapKeys';\nimport mapValues from 'lodash/mapValues';\nimport { getter } from 'property-expr';\nimport { object as locale } from './locale';\nimport sortFields from './util/sortFields';\nimport sortByKeyOrder from './util/sortByKeyOrder';\nimport runTests from './util/runTests';\nimport ValidationError from './ValidationError';\nimport BaseSchema from './schema';\n\nlet isObject = obj => Object.prototype.toString.call(obj) === '[object Object]';\n\nfunction unknown(ctx, value) {\n let known = Object.keys(ctx.fields);\n return Object.keys(value).filter(key => known.indexOf(key) === -1);\n}\n\nconst defaultSort = sortByKeyOrder([]);\nexport default class ObjectSchema extends BaseSchema {\n constructor(spec) {\n super({\n type: 'object'\n });\n this.fields = Object.create(null);\n this._sortErrors = defaultSort;\n this._nodes = [];\n this._excludedEdges = [];\n this.withMutation(() => {\n this.transform(function coerce(value) {\n if (typeof value === 'string') {\n try {\n value = JSON.parse(value);\n } catch (err) {\n value = null;\n }\n }\n\n if (this.isType(value)) return value;\n return null;\n });\n\n if (spec) {\n this.shape(spec);\n }\n });\n }\n\n _typeCheck(value) {\n return isObject(value) || typeof value === 'function';\n }\n\n _cast(_value, options = {}) {\n var _options$stripUnknown;\n\n let value = super._cast(_value, options); //should ignore nulls here\n\n\n if (value === undefined) return this.getDefault();\n if (!this._typeCheck(value)) return value;\n let fields = this.fields;\n let strip = (_options$stripUnknown = options.stripUnknown) != null ? _options$stripUnknown : this.spec.noUnknown;\n\n let props = this._nodes.concat(Object.keys(value).filter(v => this._nodes.indexOf(v) === -1));\n\n let intermediateValue = {}; // is filled during the transform below\n\n let innerOptions = _extends({}, options, {\n parent: intermediateValue,\n __validating: options.__validating || false\n });\n\n let isChanged = false;\n\n for (const prop of props) {\n let field = fields[prop];\n let exists = has(value, prop);\n\n if (field) {\n let fieldValue;\n let inputValue = value[prop]; // safe to mutate since this is fired in sequence\n\n innerOptions.path = (options.path ? `${options.path}.` : '') + prop; // innerOptions.value = value[prop];\n\n field = field.resolve({\n value: inputValue,\n context: options.context,\n parent: intermediateValue\n });\n let fieldSpec = 'spec' in field ? field.spec : undefined;\n let strict = fieldSpec == null ? void 0 : fieldSpec.strict;\n\n if (fieldSpec == null ? void 0 : fieldSpec.strip) {\n isChanged = isChanged || prop in value;\n continue;\n }\n\n fieldValue = !options.__validating || !strict ? // TODO: use _cast, this is double resolving\n field.cast(value[prop], innerOptions) : value[prop];\n\n if (fieldValue !== undefined) {\n intermediateValue[prop] = fieldValue;\n }\n } else if (exists && !strip) {\n intermediateValue[prop] = value[prop];\n }\n\n if (intermediateValue[prop] !== value[prop]) {\n isChanged = true;\n }\n }\n\n return isChanged ? intermediateValue : value;\n }\n\n _validate(_value, opts = {}, callback) {\n let errors = [];\n let {\n sync,\n from = [],\n originalValue = _value,\n abortEarly = this.spec.abortEarly,\n recursive = this.spec.recursive\n } = opts;\n from = [{\n schema: this,\n value: originalValue\n }, ...from]; // this flag is needed for handling `strict` correctly in the context of\n // validation vs just casting. e.g strict() on a field is only used when validating\n\n opts.__validating = true;\n opts.originalValue = originalValue;\n opts.from = from;\n\n super._validate(_value, opts, (err, value) => {\n if (err) {\n if (!ValidationError.isError(err) || abortEarly) {\n return void callback(err, value);\n }\n\n errors.push(err);\n }\n\n if (!recursive || !isObject(value)) {\n callback(errors[0] || null, value);\n return;\n }\n\n originalValue = originalValue || value;\n\n let tests = this._nodes.map(key => (_, cb) => {\n let path = key.indexOf('.') === -1 ? (opts.path ? `${opts.path}.` : '') + key : `${opts.path || ''}[\"${key}\"]`;\n let field = this.fields[key];\n\n if (field && 'validate' in field) {\n field.validate(value[key], _extends({}, opts, {\n // @ts-ignore\n path,\n from,\n // inner fields are always strict:\n // 1. this isn't strict so the casting will also have cast inner values\n // 2. this is strict in which case the nested values weren't cast either\n strict: true,\n parent: value,\n originalValue: originalValue[key]\n }), cb);\n return;\n }\n\n cb(null);\n });\n\n runTests({\n sync,\n tests,\n value,\n errors,\n endEarly: abortEarly,\n sort: this._sortErrors,\n path: opts.path\n }, callback);\n });\n }\n\n clone(spec) {\n const next = super.clone(spec);\n next.fields = _extends({}, this.fields);\n next._nodes = this._nodes;\n next._excludedEdges = this._excludedEdges;\n next._sortErrors = this._sortErrors;\n return next;\n }\n\n concat(schema) {\n let next = super.concat(schema);\n let nextFields = next.fields;\n\n for (let [field, schemaOrRef] of Object.entries(this.fields)) {\n const target = nextFields[field];\n\n if (target === undefined) {\n nextFields[field] = schemaOrRef;\n } else if (target instanceof BaseSchema && schemaOrRef instanceof BaseSchema) {\n nextFields[field] = schemaOrRef.concat(target);\n }\n }\n\n return next.withMutation(() => next.shape(nextFields, this._excludedEdges));\n }\n\n getDefaultFromShape() {\n let dft = {};\n\n this._nodes.forEach(key => {\n const field = this.fields[key];\n dft[key] = 'default' in field ? field.getDefault() : undefined;\n });\n\n return dft;\n }\n\n _getDefault() {\n if ('default' in this.spec) {\n return super._getDefault();\n } // if there is no default set invent one\n\n\n if (!this._nodes.length) {\n return undefined;\n }\n\n return this.getDefaultFromShape();\n }\n\n shape(additions, excludes = []) {\n let next = this.clone();\n let fields = Object.assign(next.fields, additions);\n next.fields = fields;\n next._sortErrors = sortByKeyOrder(Object.keys(fields));\n\n if (excludes.length) {\n // this is a convenience for when users only supply a single pair\n if (!Array.isArray(excludes[0])) excludes = [excludes];\n next._excludedEdges = [...next._excludedEdges, ...excludes];\n }\n\n next._nodes = sortFields(fields, next._excludedEdges);\n return next;\n }\n\n pick(keys) {\n const picked = {};\n\n for (const key of keys) {\n if (this.fields[key]) picked[key] = this.fields[key];\n }\n\n return this.clone().withMutation(next => {\n next.fields = {};\n return next.shape(picked);\n });\n }\n\n omit(keys) {\n const next = this.clone();\n const fields = next.fields;\n next.fields = {};\n\n for (const key of keys) {\n delete fields[key];\n }\n\n return next.withMutation(() => next.shape(fields));\n }\n\n from(from, to, alias) {\n let fromGetter = getter(from, true);\n return this.transform(obj => {\n if (obj == null) return obj;\n let newObj = obj;\n\n if (has(obj, from)) {\n newObj = _extends({}, obj);\n if (!alias) delete newObj[from];\n newObj[to] = fromGetter(obj);\n }\n\n return newObj;\n });\n }\n\n noUnknown(noAllow = true, message = locale.noUnknown) {\n if (typeof noAllow === 'string') {\n message = noAllow;\n noAllow = true;\n }\n\n let next = this.test({\n name: 'noUnknown',\n exclusive: true,\n message: message,\n\n test(value) {\n if (value == null) return true;\n const unknownKeys = unknown(this.schema, value);\n return !noAllow || unknownKeys.length === 0 || this.createError({\n params: {\n unknown: unknownKeys.join(', ')\n }\n });\n }\n\n });\n next.spec.noUnknown = noAllow;\n return next;\n }\n\n unknown(allow = true, message = locale.noUnknown) {\n return this.noUnknown(!allow, message);\n }\n\n transformKeys(fn) {\n return this.transform(obj => obj && mapKeys(obj, (_, key) => fn(key)));\n }\n\n camelCase() {\n return this.transformKeys(camelCase);\n }\n\n snakeCase() {\n return this.transformKeys(snakeCase);\n }\n\n constantCase() {\n return this.transformKeys(key => snakeCase(key).toUpperCase());\n }\n\n describe() {\n let base = super.describe();\n base.fields = mapValues(this.fields, value => value.describe());\n return base;\n }\n\n}\nexport function create(spec) {\n return new ObjectSchema(spec);\n}\ncreate.prototype = ObjectSchema.prototype;","function _extends() { _extends = Object.assign || 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); }\n\nimport isAbsent from './util/isAbsent';\nimport isSchema from './util/isSchema';\nimport printValue from './util/printValue';\nimport { array as locale } from './locale';\nimport runTests from './util/runTests';\nimport ValidationError from './ValidationError';\nimport BaseSchema from './schema';\nexport function create(type) {\n return new ArraySchema(type);\n}\nexport default class ArraySchema extends BaseSchema {\n constructor(type) {\n super({\n type: 'array'\n }); // `undefined` specifically means uninitialized, as opposed to\n // \"no subtype\"\n\n this.innerType = void 0;\n this.innerType = type;\n this.withMutation(() => {\n this.transform(function (values) {\n if (typeof values === 'string') try {\n values = JSON.parse(values);\n } catch (err) {\n values = null;\n }\n return this.isType(values) ? values : null;\n });\n });\n }\n\n _typeCheck(v) {\n return Array.isArray(v);\n }\n\n get _subType() {\n return this.innerType;\n }\n\n _cast(_value, _opts) {\n const value = super._cast(_value, _opts); //should ignore nulls here\n\n\n if (!this._typeCheck(value) || !this.innerType) return value;\n let isChanged = false;\n const castArray = value.map((v, idx) => {\n const castElement = this.innerType.cast(v, _extends({}, _opts, {\n path: `${_opts.path || ''}[${idx}]`\n }));\n\n if (castElement !== v) {\n isChanged = true;\n }\n\n return castElement;\n });\n return isChanged ? castArray : value;\n }\n\n _validate(_value, options = {}, callback) {\n var _options$abortEarly, _options$recursive;\n\n let errors = [];\n let sync = options.sync;\n let path = options.path;\n let innerType = this.innerType;\n let endEarly = (_options$abortEarly = options.abortEarly) != null ? _options$abortEarly : this.spec.abortEarly;\n let recursive = (_options$recursive = options.recursive) != null ? _options$recursive : this.spec.recursive;\n let originalValue = options.originalValue != null ? options.originalValue : _value;\n\n super._validate(_value, options, (err, value) => {\n if (err) {\n if (!ValidationError.isError(err) || endEarly) {\n return void callback(err, value);\n }\n\n errors.push(err);\n }\n\n if (!recursive || !innerType || !this._typeCheck(value)) {\n callback(errors[0] || null, value);\n return;\n }\n\n originalValue = originalValue || value; // #950 Ensure that sparse array empty slots are validated\n\n let tests = new Array(value.length);\n\n for (let idx = 0; idx < value.length; idx++) {\n let item = value[idx];\n let path = `${options.path || ''}[${idx}]`; // object._validate note for isStrict explanation\n\n let innerOptions = _extends({}, options, {\n path,\n strict: true,\n parent: value,\n index: idx,\n originalValue: originalValue[idx]\n });\n\n tests[idx] = (_, cb) => innerType.validate(item, innerOptions, cb);\n }\n\n runTests({\n sync,\n path,\n value,\n errors,\n endEarly,\n tests\n }, callback);\n });\n }\n\n clone(spec) {\n const next = super.clone(spec);\n next.innerType = this.innerType;\n return next;\n }\n\n concat(schema) {\n let next = super.concat(schema);\n next.innerType = this.innerType;\n if (schema.innerType) next.innerType = next.innerType ? // @ts-expect-error Lazy doesn't have concat()\n next.innerType.concat(schema.innerType) : schema.innerType;\n return next;\n }\n\n of(schema) {\n // FIXME: this should return a new instance of array without the default to be\n let next = this.clone();\n if (!isSchema(schema)) throw new TypeError('`array.of()` sub-schema must be a valid yup schema not: ' + printValue(schema)); // FIXME(ts):\n\n next.innerType = schema;\n return next;\n }\n\n length(length, message = locale.length) {\n return this.test({\n message,\n name: 'length',\n exclusive: true,\n params: {\n length\n },\n\n test(value) {\n return isAbsent(value) || value.length === this.resolve(length);\n }\n\n });\n }\n\n min(min, message) {\n message = message || locale.min;\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n min\n },\n\n // FIXME(ts): Array\n test(value) {\n return isAbsent(value) || value.length >= this.resolve(min);\n }\n\n });\n }\n\n max(max, message) {\n message = message || locale.max;\n return this.test({\n message,\n name: 'max',\n exclusive: true,\n params: {\n max\n },\n\n test(value) {\n return isAbsent(value) || value.length <= this.resolve(max);\n }\n\n });\n }\n\n ensure() {\n return this.default(() => []).transform((val, original) => {\n // We don't want to return `null` for nullable schema\n if (this._typeCheck(val)) return val;\n return original == null ? [] : [].concat(original);\n });\n }\n\n compact(rejector) {\n let reject = !rejector ? v => !!v : (v, i, a) => !rejector(v, i, a);\n return this.transform(values => values != null ? values.filter(reject) : values);\n }\n\n describe() {\n let base = super.describe();\n if (this.innerType) base.innerType = this.innerType.describe();\n return base;\n }\n\n nullable(isNullable = true) {\n return super.nullable(isNullable);\n }\n\n defined() {\n return super.defined();\n }\n\n required(msg) {\n return super.required(msg);\n }\n\n}\ncreate.prototype = ArraySchema.prototype; //\n// Interfaces\n//","(function() { module.exports = window[\"eventespresso\"][\"slotFill\"]; }());","import useDatetimeQueryOptions from './useDatetimeQueryOptions';\nimport type { Datetime, DatetimeEdge } from '../../types';\nimport { useMemoStringify } from '@eventespresso/hooks';\nimport { getCacheIds } from '@eventespresso/predicates';\nimport { useDatetimesQuery } from '@eventespresso/data';\n\nconst useDatetimes = (): Array => {\n\tconst options = useDatetimeQueryOptions();\n\tconst { data } = useDatetimesQuery(options);\n\n\tconst nodes = data?.espressoDatetimes?.nodes || [];\n\n\tconst cacheIds = getCacheIds(nodes);\n\n\treturn useMemoStringify(nodes, cacheIds);\n};\n\nexport default useDatetimes;\n","import { gql } from '@eventespresso/data';\nimport { PRICE_ATTRIBUTES } from '../../queries/prices';\n\nexport const CREATE_PRICE = gql`\n\tmutation CREATE_PRICE($input: CreateEspressoPriceInput!) {\n\t\tcreateEspressoPrice(input: $input) {\n\t\t\tespressoPrice {\n\t\t\t\t...priceAttributes\n\t\t\t}\n\t\t}\n\t}\n\t${PRICE_ATTRIBUTES}\n`;\n\nexport const UPDATE_PRICE = gql`\n\tmutation UPDATE_PRICE($input: UpdateEspressoPriceInput!) {\n\t\tupdateEspressoPrice(input: $input) {\n\t\t\tespressoPrice {\n\t\t\t\t...priceAttributes\n\t\t\t}\n\t\t}\n\t}\n\t${PRICE_ATTRIBUTES}\n`;\n\nexport const DELETE_PRICE = gql`\n\tmutation DELETE_PRICE($input: DeleteEspressoPriceInput!) {\n\t\tdeleteEspressoPrice(input: $input) {\n\t\t\tespressoPrice {\n\t\t\t\tid\n\t\t\t}\n\t\t}\n\t}\n`;\n\nexport { default as usePriceMutator } from './usePriceMutator';\n\nexport { default as useBulkDeletePrices } from './useBulkDeletePrices';\n\nexport * from './types';\n","export * from './global';\n","export * from './initialization';\n\nexport * from './meta';\n\nexport * from './mutations';\n\nexport * from './queries';\n\nexport * from './types';\n","var root = require('./_root');\n\n/** Built-in value references. */\nvar Symbol = root.Symbol;\n\nmodule.exports = Symbol;\n","var getNative = require('./_getNative');\n\n/* Built-in method references that are verified to be native. */\nvar nativeCreate = getNative(Object, 'create');\n\nmodule.exports = nativeCreate;\n","var listCacheClear = require('./_listCacheClear'),\n listCacheDelete = require('./_listCacheDelete'),\n listCacheGet = require('./_listCacheGet'),\n listCacheHas = require('./_listCacheHas'),\n listCacheSet = require('./_listCacheSet');\n\n/**\n * Creates an list cache object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction ListCache(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `ListCache`.\nListCache.prototype.clear = listCacheClear;\nListCache.prototype['delete'] = listCacheDelete;\nListCache.prototype.get = listCacheGet;\nListCache.prototype.has = listCacheHas;\nListCache.prototype.set = listCacheSet;\n\nmodule.exports = ListCache;\n","var eq = require('./eq');\n\n/**\n * Gets the index at which the `key` is found in `array` of key-value pairs.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {*} key The key to search for.\n * @returns {number} Returns the index of the matched value, else `-1`.\n */\nfunction assocIndexOf(array, key) {\n var length = array.length;\n while (length--) {\n if (eq(array[length][0], key)) {\n return length;\n }\n }\n return -1;\n}\n\nmodule.exports = assocIndexOf;\n","var isKeyable = require('./_isKeyable');\n\n/**\n * Gets the data for `map`.\n *\n * @private\n * @param {Object} map The map to query.\n * @param {string} key The reference key.\n * @returns {*} Returns the map data.\n */\nfunction getMapData(map, key) {\n var data = map.__data__;\n return isKeyable(key)\n ? data[typeof key == 'string' ? 'string' : 'hash']\n : data.map;\n}\n\nmodule.exports = getMapData;\n","var isSymbol = require('./isSymbol');\n\n/** Used as references for various `Number` constants. */\nvar INFINITY = 1 / 0;\n\n/**\n * Converts `value` to a string key if it's not a string or symbol.\n *\n * @private\n * @param {*} value The value to inspect.\n * @returns {string|symbol} Returns the key.\n */\nfunction toKey(value) {\n if (typeof value == 'string' || isSymbol(value)) {\n return value;\n }\n var result = (value + '');\n return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;\n}\n\nmodule.exports = toKey;\n","import type {\n\tApolloCache,\n\tEntity as BaseEntity,\n\tEntity,\n\tMutationInput,\n\tMutationType,\n\tMutationUpdaterFn,\n\tOperationVariables,\n} from '@eventespresso/data';\nimport type { Merge, AnyObject } from '@eventespresso/utils';\nimport type { ShiftDateArgs } from '@eventespresso/dates';\nimport type { Datetime, DatetimeEdge, Ticket, TicketEdge, Price, PriceEdge } from '../types';\n\nexport interface MutationCallbackFnArgs {\n\tcache?: ApolloCache;\n}\n\ninterface CommonArgs {\n\tdeletePermanently?: boolean;\n}\n\n/* Datetime specific */\nexport interface DatetimeMutationCallbackFnArgs extends MutationCallbackFnArgs, CommonArgs {\n\tdatetime: Datetime;\n\tdatetimes?: DatetimeEdge;\n\ttickets?: string[];\n}\nexport type DatetimeMutationCallbackFn = (args: DatetimeMutationCallbackFnArgs) => void;\n\n/* Ticket specific */\nexport interface TicketMutationCallbackFnArgs extends MutationCallbackFnArgs, CommonArgs {\n\tticket: Ticket;\n\ttickets?: TicketEdge;\n\tdatetimeIds?: string[];\n\tprices?: PriceEdge;\n\tpriceIds?: string[];\n}\nexport type TicketMutationCallbackFn = (args: TicketMutationCallbackFnArgs) => void;\n\n/* Price specific */\nexport interface PriceMutationCallbackFnArgs extends MutationCallbackFnArgs, CommonArgs {\n\tprice: Price;\n\tprices?: PriceEdge;\n\tpriceTypeId?: string;\n\tticketId?: string;\n}\nexport type PriceMutationCallbackFn = (args: PriceMutationCallbackFnArgs) => void;\n\n/* Generic cache updater */\nexport interface CacheUpdaterFnArgs extends MutationCallbackFnArgs {\n\taction: 'add' | 'update' | 'remove';\n\tdatetime?: Datetime;\n\tdatetimeId?: string;\n\tdatetimeIn?: string[];\n\tdatetimes?: DatetimeEdge;\n\tprice?: Price;\n\tprices?: PriceEdge;\n\tticket?: Ticket;\n\tticketId?: string;\n\tticketIn?: string[];\n\ttickets?: TicketEdge;\n}\n\nexport type CacheUpdaterFn = (args: CacheUpdaterFnArgs) => void;\n\nexport enum TypeName {\n\tDatetime = 'Datetime',\n\tEvent = 'Event',\n\tTicket = 'Ticket',\n\tPrice = 'Price',\n\tPriceType = 'PriceType',\n}\n\nexport type OnUpdateFnOptions = {\n\tcache: ApolloCache;\n\tentity: Entity;\n};\n\nexport type OnUpdateFn = (options: OnUpdateFnOptions) => void;\n\nexport interface MutationInputWithId {\n\tclientMutationId: string;\n}\n\nexport interface MutationVariables {\n\tinput: Merge;\n}\n/*********************************/\nexport interface MutationBaseProps {\n\tinput: MI;\n\tmutationType: MutationType;\n}\n\nexport interface MutationUpdaterArgs\n\textends MutationBaseProps {\n\tcache: ApolloCache;\n\tentity: E;\n}\n\nexport type MutationUpdater = (\n\targs: MutationUpdaterArgs\n) => void;\n\nexport type MutationHandler = (\n\tmutationType: MutationType,\n\tinput: MI\n) => MutatorGeneratedObject;\n\nexport interface MutatorGeneratedObject {\n\tonUpdate?: MutationUpdater;\n\toptimisticResponse?: any;\n\tvariables: OperationVariables;\n}\n\nexport interface UpdaterCallbackArgs\n\textends MutationBaseProps {\n\tonUpdate?: MutationUpdater;\n}\n\nexport type UpdaterCallback = (\n\targs: UpdaterCallbackArgs\n) => MutationUpdaterFn;\n\nexport interface BulkUpdateInput {\n\tsharedInput?: T;\n\tuniqueInputs: Array;\n}\nexport interface BulkEditFormBaseShape extends Partial {\n\tshiftDates?: ShiftDateArgs;\n}\n","var baseAssignValue = require('./_baseAssignValue'),\n baseForOwn = require('./_baseForOwn'),\n baseIteratee = require('./_baseIteratee');\n\n/**\n * Creates an object with the same keys as `object` and values generated\n * by running each own enumerable string keyed property of `object` thru\n * `iteratee`. The iteratee is invoked with three arguments:\n * (value, key, object).\n *\n * @static\n * @memberOf _\n * @since 2.4.0\n * @category Object\n * @param {Object} object The object to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @returns {Object} Returns the new mapped object.\n * @see _.mapKeys\n * @example\n *\n * var users = {\n * 'fred': { 'user': 'fred', 'age': 40 },\n * 'pebbles': { 'user': 'pebbles', 'age': 1 }\n * };\n *\n * _.mapValues(users, function(o) { return o.age; });\n * // => { 'fred': 40, 'pebbles': 1 } (iteration order is not guaranteed)\n *\n * // The `_.property` iteratee shorthand.\n * _.mapValues(users, 'age');\n * // => { 'fred': 40, 'pebbles': 1 } (iteration order is not guaranteed)\n */\nfunction mapValues(object, iteratee) {\n var result = {};\n iteratee = baseIteratee(iteratee, 3);\n\n baseForOwn(object, function(value, key, object) {\n baseAssignValue(result, key, iteratee(value, key, object));\n });\n return result;\n}\n\nmodule.exports = mapValues;\n","import setPrototypeOf from \"@babel/runtime/helpers/esm/setPrototypeOf\";\nimport isNativeReflectConstruct from \"@babel/runtime/helpers/esm/isNativeReflectConstruct\";\nexport default function _construct(Parent, args, Class) {\n if (isNativeReflectConstruct()) {\n _construct = Reflect.construct;\n } else {\n _construct = function _construct(Parent, args, Class) {\n var a = [null];\n a.push.apply(a, args);\n var Constructor = Function.bind.apply(Parent, a);\n var instance = new Constructor();\n if (Class) setPrototypeOf(instance, Class.prototype);\n return instance;\n };\n }\n\n return _construct.apply(null, arguments);\n}","import getPrototypeOf from \"@babel/runtime/helpers/esm/getPrototypeOf\";\nimport setPrototypeOf from \"@babel/runtime/helpers/esm/setPrototypeOf\";\nimport isNativeFunction from \"@babel/runtime/helpers/esm/isNativeFunction\";\nimport construct from \"@babel/runtime/helpers/esm/construct\";\nexport default function _wrapNativeSuper(Class) {\n var _cache = typeof Map === \"function\" ? new Map() : undefined;\n\n _wrapNativeSuper = function _wrapNativeSuper(Class) {\n if (Class === null || !isNativeFunction(Class)) return Class;\n\n if (typeof Class !== \"function\") {\n throw new TypeError(\"Super expression must either be null or a function\");\n }\n\n if (typeof _cache !== \"undefined\") {\n if (_cache.has(Class)) return _cache.get(Class);\n\n _cache.set(Class, Wrapper);\n }\n\n function Wrapper() {\n return construct(Class, arguments, getPrototypeOf(this).constructor);\n }\n\n Wrapper.prototype = Object.create(Class.prototype, {\n constructor: {\n value: Wrapper,\n enumerable: false,\n writable: true,\n configurable: true\n }\n });\n return setPrototypeOf(Wrapper, Class);\n };\n\n return _wrapNativeSuper(Class);\n}","export default function _isNativeFunction(fn) {\n return Function.toString.call(fn).indexOf(\"[native code]\") !== -1;\n}","(function() { module.exports = window[\"eventespresso\"][\"storage\"]; }());","import { useMemo } from 'react';\n\nimport type { DatetimesList, DatetimesQueryArgs, CacheQueryOptions } from '@eventespresso/data';\n\nimport useEventId from '../events/useEventId';\nimport { GET_DATETIMES } from '../datetimes';\nimport type { DatetimeEdge } from '../../';\n\ntype DatetimesQueryOptions = CacheQueryOptions, DatetimesQueryArgs>;\n\nconst useDatetimeQueryOptions = (): DatetimesQueryOptions => {\n\tconst eventId = useEventId();\n\n\treturn useMemo(() => {\n\t\treturn {\n\t\t\tquery: GET_DATETIMES,\n\t\t\tvariables: {\n\t\t\t\twhere: {\n\t\t\t\t\teventId,\n\t\t\t\t},\n\t\t\t},\n\t\t};\n\t}, [eventId]);\n};\n\nexport default useDatetimeQueryOptions;\n","import { useMemo } from 'react';\n\nimport type { TicketsList, TicketsQueryArgs, CacheQueryOptions } from '@eventespresso/data';\n\nimport { GET_TICKETS } from '../tickets';\nimport type { TicketEdge } from '../../';\nimport useEventId from '../events/useEventId';\n\nexport type TicketsQueryOptions = CacheQueryOptions, TicketsQueryArgs>;\n\nconst useTicketQueryOptions = (queryArgs?: TicketsQueryArgs['where']): TicketsQueryOptions => {\n\tconst eventId = useEventId();\n\n\treturn useMemo(() => {\n\t\treturn {\n\t\t\tquery: GET_TICKETS,\n\t\t\tvariables: {\n\t\t\t\twhere: {\n\t\t\t\t\teventId,\n\t\t\t\t\tincludeDefaultTickets: true,\n\t\t\t\t\t...queryArgs,\n\t\t\t\t},\n\t\t\t},\n\t\t};\n\t}, [eventId, queryArgs]);\n};\n\nexport default useTicketQueryOptions;\n","const useEventId = (): number => {\n\treturn window?.eventEspressoData?.eventEditor?.event?.dbId || 0;\n};\n\nexport default useEventId;\n","import { useCallback } from 'react';\nimport type { MutationUpdaterFn } from '@apollo/client';\nimport { pathOr } from 'ramda';\n\nimport type { TypeName, UpdaterCallback } from './types';\n\nconst useUpdateCallback = (typeName: TypeName): UpdaterCallback => {\n\treturn useCallback(\n\t\t({ onUpdate, mutationType, input }) => {\n\t\t\t/**\n\t\t\t * Since every mutation update callback is interested\n\t\t\t * in the updated entity data in response, we will\n\t\t\t * pass just that entity to onUpdate.\n\t\t\t */\n\t\t\tconst update: MutationUpdaterFn = (cache, result) => {\n\t\t\t\t// e.g. \"createDatetime\", \"updateTicket\"\n\t\t\t\tconst mutationName = `${mutationType.toLowerCase()}Espresso${typeName}`;\n\t\t\t\t// Example result: { data: { deletePrice: { price : {...} } } }\n\t\t\t\tconst path = ['data', mutationName, `espresso${typeName}`];\n\t\t\t\tconst entity = pathOr({}, path, result);\n\n\t\t\t\tonUpdate?.({ cache, entity, mutationType, input });\n\t\t\t};\n\t\t\treturn update;\n\t\t},\n\t\t[typeName]\n\t);\n};\n\nexport default useUpdateCallback;\n","import { gql } from '@eventespresso/data';\nimport { PRICE_TYPE_ATTRIBUTES } from '../priceTypes';\n\nexport const PRICE_ATTRIBUTES: any = gql`\n\tfragment priceAttributes on EspressoPrice {\n\t\tid\n\t\tdbId\n\t\tamount\n\t\tcacheId\n\t\tdescription\n\t\tisBasePrice\n\t\tisDefault\n\t\tisDiscount\n\t\tisPercent\n\t\tisTax\n\t\tisTrashed\n\t\tname\n\t\torder\n\t\toverrides\n\t}\n`;\n\n/**\n * The related priceType for a price.\n * Can be used to fetch the related priceType\n * created for a price on the server.\n */\nexport const PRICE_BASE_TYPE_ATTRIBUTE: any = gql`\n\tfragment priceBaseTypeAttribute on EspressoPrice {\n\t\tpriceType {\n\t\t\t...priceTypeAttributes\n\t\t}\n\t}\n\t${PRICE_TYPE_ATTRIBUTES}\n`;\n\nexport const GET_PRICE: any = gql`\n\tquery GET_PRICE($id: ID!) {\n\t\tprice(id: $id) {\n\t\t\t...priceAttributes\n\t\t}\n\t}\n\t${PRICE_ATTRIBUTES}\n`;\n\nexport const GET_PRICES: any = gql`\n\tquery GET_PRICES($where: EspressoRootQueryPricesConnectionWhereArgs) {\n\t\tespressoPrices(where: $where) {\n\t\t\tnodes {\n\t\t\t\t...priceAttributes\n\t\t\t}\n\t\t}\n\t}\n\t${PRICE_ATTRIBUTES}\n`;\n","module.exports = function(module) {\n\tif (!module.webpackPolyfill) {\n\t\tmodule.deprecate = function() {};\n\t\tmodule.paths = [];\n\t\t// module.parent = undefined by default\n\t\tif (!module.children) module.children = [];\n\t\tObject.defineProperty(module, \"loaded\", {\n\t\t\tenumerable: true,\n\t\t\tget: function() {\n\t\t\t\treturn module.l;\n\t\t\t}\n\t\t});\n\t\tObject.defineProperty(module, \"id\", {\n\t\t\tenumerable: true,\n\t\t\tget: function() {\n\t\t\t\treturn module.i;\n\t\t\t}\n\t\t});\n\t\tmodule.webpackPolyfill = 1;\n\t}\n\treturn module;\n};\n","export * from './datetimes';\n\nexport * from './tickets';\n\nexport * from './types';\n","var isArray = require('./isArray'),\n isSymbol = require('./isSymbol');\n\n/** Used to match property names within property paths. */\nvar reIsDeepProp = /\\.|\\[(?:[^[\\]]*|([\"'])(?:(?!\\1)[^\\\\]|\\\\.)*?\\1)\\]/,\n reIsPlainProp = /^\\w*$/;\n\n/**\n * Checks if `value` is a property name and not a property path.\n *\n * @private\n * @param {*} value The value to check.\n * @param {Object} [object] The object to query keys on.\n * @returns {boolean} Returns `true` if `value` is a property name, else `false`.\n */\nfunction isKey(value, object) {\n if (isArray(value)) {\n return false;\n }\n var type = typeof value;\n if (type == 'number' || type == 'symbol' || type == 'boolean' ||\n value == null || isSymbol(value)) {\n return true;\n }\n return reIsPlainProp.test(value) || !reIsDeepProp.test(value) ||\n (object != null && value in Object(object));\n}\n\nmodule.exports = isKey;\n","var baseGetTag = require('./_baseGetTag'),\n isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar symbolTag = '[object Symbol]';\n\n/**\n * Checks if `value` is classified as a `Symbol` primitive or object.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a symbol, else `false`.\n * @example\n *\n * _.isSymbol(Symbol.iterator);\n * // => true\n *\n * _.isSymbol('abc');\n * // => false\n */\nfunction isSymbol(value) {\n return typeof value == 'symbol' ||\n (isObjectLike(value) && baseGetTag(value) == symbolTag);\n}\n\nmodule.exports = isSymbol;\n","var mapCacheClear = require('./_mapCacheClear'),\n mapCacheDelete = require('./_mapCacheDelete'),\n mapCacheGet = require('./_mapCacheGet'),\n mapCacheHas = require('./_mapCacheHas'),\n mapCacheSet = require('./_mapCacheSet');\n\n/**\n * Creates a map cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction MapCache(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `MapCache`.\nMapCache.prototype.clear = mapCacheClear;\nMapCache.prototype['delete'] = mapCacheDelete;\nMapCache.prototype.get = mapCacheGet;\nMapCache.prototype.has = mapCacheHas;\nMapCache.prototype.set = mapCacheSet;\n\nmodule.exports = MapCache;\n","/**\n * Checks if `value` is the\n * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)\n * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an object, else `false`.\n * @example\n *\n * _.isObject({});\n * // => true\n *\n * _.isObject([1, 2, 3]);\n * // => true\n *\n * _.isObject(_.noop);\n * // => true\n *\n * _.isObject(null);\n * // => false\n */\nfunction isObject(value) {\n var type = typeof value;\n return value != null && (type == 'object' || type == 'function');\n}\n\nmodule.exports = isObject;\n","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar Map = getNative(root, 'Map');\n\nmodule.exports = Map;\n","/** Used as references for various `Number` constants. */\nvar MAX_SAFE_INTEGER = 9007199254740991;\n\n/**\n * Checks if `value` is a valid array-like length.\n *\n * **Note:** This method is loosely based on\n * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a valid length, else `false`.\n * @example\n *\n * _.isLength(3);\n * // => true\n *\n * _.isLength(Number.MIN_VALUE);\n * // => false\n *\n * _.isLength(Infinity);\n * // => false\n *\n * _.isLength('3');\n * // => false\n */\nfunction isLength(value) {\n return typeof value == 'number' &&\n value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;\n}\n\nmodule.exports = isLength;\n","var arrayLikeKeys = require('./_arrayLikeKeys'),\n baseKeys = require('./_baseKeys'),\n isArrayLike = require('./isArrayLike');\n\n/**\n * Creates an array of the own enumerable property names of `object`.\n *\n * **Note:** Non-object values are coerced to objects. See the\n * [ES spec](http://ecma-international.org/ecma-262/7.0/#sec-object.keys)\n * for more details.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Object\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.keys(new Foo);\n * // => ['a', 'b'] (iteration order is not guaranteed)\n *\n * _.keys('hi');\n * // => ['0', '1']\n */\nfunction keys(object) {\n return isArrayLike(object) ? arrayLikeKeys(object) : baseKeys(object);\n}\n\nmodule.exports = keys;\n","var createCompounder = require('./_createCompounder');\n\n/**\n * Converts `string` to\n * [snake case](https://en.wikipedia.org/wiki/Snake_case).\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to convert.\n * @returns {string} Returns the snake cased string.\n * @example\n *\n * _.snakeCase('Foo Bar');\n * // => 'foo_bar'\n *\n * _.snakeCase('fooBar');\n * // => 'foo_bar'\n *\n * _.snakeCase('--FOO-BAR--');\n * // => 'foo_bar'\n */\nvar snakeCase = createCompounder(function(result, word, index) {\n return result + (index ? '_' : '') + word.toLowerCase();\n});\n\nmodule.exports = snakeCase;\n","import { DataProvider } from '@eventespresso/data';\nimport { ThemeProvider } from '@eventespresso/adapters';\nimport { SlotFillProvider } from '@eventespresso/slot-fill';\nimport { ConfigProvider, FeaturesProvider, RelationsProvider, StatusProvider } from '@eventespresso/services';\nimport { GlobalModalProvider } from '@eventespresso/registry';\n\nexport const ServiceProvider: React.FC = ({ children }) => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t{children}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport const ContextProvider: React.FC = ({ children }) => (\n\t\n\t\t{children}\n\t\n);\n","import { ContextProvider } from './ContextProvider';\nimport type { AnyObject } from '@eventespresso/utils';\n\nconst withEdtrContext =

(Component: React.ComponentType

): React.FC

=> {\n\tconst WrappedComponent: React.FC

= (props) => {\n\t\treturn (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t);\n\t};\n\n\treturn WrappedComponent;\n};\n\nexport default withEdtrContext;\n","import { DatesFilterStateProvider } from './DatesFilterStateProvider';\nimport { FilteredDatesProvider } from './FilteredDatesProvider';\n\nexport const DatetimesListProvider: React.FC = ({ children }) => {\n\treturn (\n\t\t\n\t\t\t{children}\n\t\t\n\t);\n};\n","import { TicketsFilterStateProvider } from './TicketsFilterStateProvider';\nimport { FilteredTicketsProvider } from './FilteredTicketsProvider';\n\nexport const TicketsListProvider: React.FC = ({ children }) => {\n\treturn (\n\t\t\n\t\t\t{children}\n\t\t\n\t);\n};\n","interface ContextHOCArgs {\n\tProvider: React.ComponentType;\n\tComponent: React.ComponentType;\n\t[key: string]: any;\n}\n\nconst withEntityListContext = ({ Provider, Component, ...props }: ContextHOCArgs): React.FC => {\n\tconst wrappedComponent: React.FC = () => {\n\t\treturn (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t);\n\t};\n\n\treturn wrappedComponent;\n};\n\nexport default withEntityListContext;\n","import { useMemoStringify } from '@eventespresso/hooks';\nimport { getGuids } from '@eventespresso/predicates';\nimport { EntityId } from '@eventespresso/data';\nimport useDatetimes from './useDatetimes';\n\nconst useDatetimeIds = (): EntityId[] => {\n\tconst datetimes = useDatetimes();\n\n\treturn useMemoStringify(getGuids(datetimes));\n};\n\nexport default useDatetimeIds;\n","import { useMemo } from 'react';\n\nimport { useCacheQuery, CacheQueryOptions } from '@eventespresso/data';\nimport { useMemoStringify } from '@eventespresso/hooks';\n\nimport { GET_DATETIME } from './queries';\nimport type { Datetime, DatetimeItem } from '../../types';\nimport type { EntityItemProps } from '../types';\n\nconst useDatetimeItem = ({ id }: EntityItemProps): Datetime => {\n\tconst options = useMemo(\n\t\t() => ({\n\t\t\tquery: GET_DATETIME,\n\t\t\tvariables: {\n\t\t\t\tid,\n\t\t\t},\n\t\t\treturnPartialData: true, // avoid console warnings if data not present\n\t\t}),\n\t\t[id]\n\t);\n\tconst { data } = useCacheQuery(options);\n\n\treturn useMemoStringify(data?.espressoDatetime);\n};\n\nexport default useDatetimeItem;\n","import { useMemo } from 'react';\n\nimport { entitiesWithGuIdInArray } from '@eventespresso/predicates';\nimport { entityListCacheIdString } from '@eventespresso/utils';\nimport { useRelations } from '@eventespresso/services';\nimport useDatetimes from './useDatetimes';\nimport type { Datetime } from '../../types';\nimport type { RelatedEntitiesHook } from '../types';\n\nconst useRelatedDatetimes: RelatedEntitiesHook = ({ entity, entityId }) => {\n\tconst datetimes = useDatetimes();\n\tconst { getRelations } = useRelations();\n\tconst relatedDatetimeIds = getRelations({\n\t\tentity,\n\t\tentityId,\n\t\trelation: 'datetimes',\n\t});\n\n\tconst cacheIds = entityListCacheIdString(datetimes);\n\tconst relatedDatetimeIdsStr = JSON.stringify(relatedDatetimeIds);\n\n\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\treturn useMemo(() => entitiesWithGuIdInArray(datetimes, relatedDatetimeIds), [relatedDatetimeIdsStr, cacheIds]);\n};\n\nexport default useRelatedDatetimes;\n","import { useMemo } from 'react';\n\nimport { entitiesWithGuIdInArray } from '@eventespresso/predicates';\nimport { entityListCacheIdString } from '@eventespresso/utils';\nimport { useRelations } from '@eventespresso/services';\nimport usePrices from './usePrices';\nimport type { Price } from '../../types';\nimport type { RelatedEntitiesHook } from '../types';\n\nconst useRelatedPrices: RelatedEntitiesHook = ({ entity, entityId }) => {\n\tconst prices = usePrices();\n\tconst { getRelations } = useRelations();\n\tconst relatedPriceIds = getRelations({\n\t\tentity,\n\t\tentityId,\n\t\trelation: 'prices',\n\t});\n\n\tconst cacheIds = entityListCacheIdString(prices);\n\tconst relatedPriceIdsStr = JSON.stringify(relatedPriceIds);\n\n\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\treturn useMemo(() => entitiesWithGuIdInArray(prices, relatedPriceIds), [relatedPriceIdsStr, cacheIds]);\n};\n\nexport default useRelatedPrices;\n","import { gql } from '@eventespresso/data';\n\nimport { EVENT_ATTRIBUTES } from '../../queries/events';\n\nexport const UPDATE_EVENT = gql`\n\tmutation UPDATE_EVENT($input: UpdateEspressoEventInput!) {\n\t\tupdateEspressoEvent(input: $input) {\n\t\t\tespressoEvent {\n\t\t\t\t...eventAttributes\n\t\t\t}\n\t\t}\n\t}\n\t${EVENT_ATTRIBUTES}\n`;\n\nexport { default as useEventMutator } from './useEventMutator';\n\nexport * from './types';\n","import type { BasicSortBy } from '@eventespresso/services';\n\nexport type SortBy = BasicSortBy | 'date' | 'order';\n\nexport enum DisplayStartOrEndDate {\n\tstart = 'start',\n\tend = 'end',\n\tboth = 'both',\n}\n\nexport interface EntityFilterState {\n\tdisplayStartOrEndDate?: DisplayStartOrEndDate;\n}\n\nexport type EntityFilterActionType = 'SET_DISPLAY_START_OR_END_DATE';\n\nexport interface EntityFilterAction extends Partial {\n\ttype: EntityFilterActionType | AcionType;\n}\n\nexport interface EntityFilterStateManager extends EntityFilterState {\n\tsetDisplayStartOrEndDate: (displayStartOrEndDate: DisplayStartOrEndDate) => void;\n}\n\nexport type EntityFilterStateReducer> = (\n\tstate: EFS,\n\taction: EFA\n) => EFS;\n","import { useMemo } from 'react';\n\nimport type { PricesList, PricesQueryArgs, CacheQueryOptions } from '@eventespresso/data';\n\nimport { GET_PRICES } from '../prices';\nimport useEventId from '../events/useEventId';\nimport type { PriceEdge } from '../../';\n\nexport type PricesQueryOptions = CacheQueryOptions, PricesQueryArgs>;\n\nconst usePriceQueryOptions = (queryArgs?: PricesQueryArgs['where']): PricesQueryOptions => {\n\tconst eventId = useEventId();\n\n\treturn useMemo(() => {\n\t\treturn {\n\t\t\tquery: GET_PRICES,\n\t\t\tvariables: {\n\t\t\t\twhere: {\n\t\t\t\t\teventId,\n\t\t\t\t\tincludeDefaultTicketsPrices: true,\n\t\t\t\t\tincludeDefaultPrices: true,\n\t\t\t\t\t...queryArgs,\n\t\t\t\t},\n\t\t\t},\n\t\t};\n\t}, [eventId, queryArgs]);\n};\n\nexport default usePriceQueryOptions;\n","import { useCallback } from 'react';\nimport { findIndex, update } from 'ramda';\n\nimport { WriteQueryOptions } from '@eventespresso/data';\nimport { entityHasGuid } from '@eventespresso/predicates';\n\nimport { useTicketQueryOptions } from '../../queries';\nimport type { CacheUpdaterFn, CacheUpdaterFnArgs } from '../types';\nimport { Ticket, TicketsList } from '../../';\n\nconst useUpdateTicketCache = (): CacheUpdaterFn => {\n\tconst queryOptions = useTicketQueryOptions();\n\n\tconst updateTicketCache = useCallback(\n\t\t({ cache, tickets, ticket, action }: CacheUpdaterFnArgs): void => {\n\t\t\tconst { nodes = [] } = tickets;\n\t\t\tlet newNodes: Array = [],\n\t\t\t\tticketIndex: number;\n\t\t\tswitch (action) {\n\t\t\t\tcase 'add':\n\t\t\t\t\tnewNodes = [...nodes, ticket];\n\t\t\t\t\tbreak;\n\t\t\t\tcase 'update':\n\t\t\t\t\t// find the index of the ticket to update\n\t\t\t\t\tticketIndex = findIndex(entityHasGuid(ticket.id), nodes);\n\t\t\t\t\t// if ticket exists\n\t\t\t\t\tif (ticketIndex >= 0) {\n\t\t\t\t\t\tnewNodes = update(ticketIndex, ticket, nodes);\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase 'remove':\n\t\t\t\t\tnewNodes = nodes.filter(({ id }) => id !== ticket.id);\n\t\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t\tnewNodes = nodes;\n\t\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\t// write the data to cache without\n\t\t\t// mutating the cache directly\n\t\t\tconst writeOptions: WriteQueryOptions = {\n\t\t\t\t...queryOptions,\n\t\t\t\tdata: {\n\t\t\t\t\tespressoTickets: {\n\t\t\t\t\t\t...tickets,\n\t\t\t\t\t\tnodes: newNodes,\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t};\n\t\t\tcache.writeQuery(writeOptions);\n\t\t},\n\t\t[queryOptions]\n\t);\n\n\treturn updateTicketCache;\n};\n\nexport default useUpdateTicketCache;\n","import { useCallback } from 'react';\nimport { useMutationWithFeedback, gql, MutationType } from '@eventespresso/data';\nimport type { ExecutionResult } from 'graphql';\n\nimport type { EntityId } from '@eventespresso/data';\n\ninterface BulkDeleteEntitiesProps {\n\tentityType: 'DATETIME' | 'TICKET' | 'PRICE';\n\ttypeName: string;\n}\n\ninterface CallbackArgs {\n\tentityIds: Array;\n\tdeletePermanently?: boolean;\n\tupdateEntityList: VoidFunction;\n}\n\ntype Callback = (args: CallbackArgs) => Promise;\n\nconst BULK_DELETE_ENTITIES = gql`\n\tmutation BULK_DELETE_ENTITIES($input: BulkDeleteEspressoEntitiesInput!) {\n\t\tbulkDeleteEspressoEntities(input: $input) {\n\t\t\tdeleted\n\t\t\tfailed\n\t\t}\n\t}\n`;\n\nconst useBulkDeleteEntities = ({ entityType, typeName }: BulkDeleteEntitiesProps): Callback => {\n\tconst bulkDelete = useMutationWithFeedback({\n\t\ttypeName,\n\t\tmutationType: MutationType.Delete,\n\t\tmutation: BULK_DELETE_ENTITIES,\n\t});\n\n\treturn useCallback(\n\t\tasync ({ entityIds, deletePermanently, updateEntityList }) => {\n\t\t\treturn await bulkDelete({\n\t\t\t\tvariables: {\n\t\t\t\t\tinput: {\n\t\t\t\t\t\tclientMutationId: 'BULK_DELETE_ENTITIES',\n\t\t\t\t\t\tentityIds,\n\t\t\t\t\t\tentityType,\n\t\t\t\t\t\tdeletePermanently,\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\tupdate: updateEntityList,\n\t\t\t});\n\t\t},\n\t\t[bulkDelete, entityType]\n\t);\n};\n\nexport default useBulkDeleteEntities;\n","var _isPlaceholder =\n/*#__PURE__*/\nrequire(\"./_isPlaceholder\");\n/**\n * Optimized internal one-arity curry function.\n *\n * @private\n * @category Function\n * @param {Function} fn The function to curry.\n * @return {Function} The curried function.\n */\n\n\nfunction _curry1(fn) {\n return function f1(a) {\n if (arguments.length === 0 || _isPlaceholder(a)) {\n return f1;\n } else {\n return fn.apply(this, arguments);\n }\n };\n}\n\nmodule.exports = _curry1;","import { CREATE_DATETIME, UPDATE_DATETIME, DELETE_DATETIME } from './datetimes';\nimport { UPDATE_EVENT } from './events';\nimport { CREATE_TICKET, UPDATE_TICKET, DELETE_TICKET } from './tickets';\nimport { CREATE_PRICE, UPDATE_PRICE, DELETE_PRICE } from './prices';\n\nexport const mutations: any = {\n\t/* datetimes */\n\tCREATE_DATETIME,\n\tUPDATE_DATETIME,\n\tDELETE_DATETIME,\n\t/* events */\n\tUPDATE_EVENT,\n\t/* tickets */\n\tCREATE_TICKET,\n\tUPDATE_TICKET,\n\tDELETE_TICKET,\n\t/* prices */\n\tCREATE_PRICE,\n\tUPDATE_PRICE,\n\tDELETE_PRICE,\n};\n\nexport * from './datetimes';\nexport * from './events';\nexport * from './tickets';\nexport * from './prices';\n\nexport * from './utils';\nexport * from './types';\n\nexport { default as useUpdateCallback } from './useUpdateCallback';\n","var castPath = require('./_castPath'),\n isArguments = require('./isArguments'),\n isArray = require('./isArray'),\n isIndex = require('./_isIndex'),\n isLength = require('./isLength'),\n toKey = require('./_toKey');\n\n/**\n * Checks if `path` exists on `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Array|string} path The path to check.\n * @param {Function} hasFunc The function to check properties.\n * @returns {boolean} Returns `true` if `path` exists, else `false`.\n */\nfunction hasPath(object, path, hasFunc) {\n path = castPath(path, object);\n\n var index = -1,\n length = path.length,\n result = false;\n\n while (++index < length) {\n var key = toKey(path[index]);\n if (!(result = object != null && hasFunc(object, key))) {\n break;\n }\n object = object[key];\n }\n if (result || ++index != length) {\n return result;\n }\n length = object == null ? 0 : object.length;\n return !!length && isLength(length) && isIndex(key, length) &&\n (isArray(object) || isArguments(object));\n}\n\nmodule.exports = hasPath;\n","var isArray = require('./isArray'),\n isKey = require('./_isKey'),\n stringToPath = require('./_stringToPath'),\n toString = require('./toString');\n\n/**\n * Casts `value` to a path array if it's not one.\n *\n * @private\n * @param {*} value The value to inspect.\n * @param {Object} [object] The object to query keys on.\n * @returns {Array} Returns the cast property path array.\n */\nfunction castPath(value, object) {\n if (isArray(value)) {\n return value;\n }\n return isKey(value, object) ? [value] : stringToPath(toString(value));\n}\n\nmodule.exports = castPath;\n","/** Detect free variable `global` from Node.js. */\nvar freeGlobal = typeof global == 'object' && global && global.Object === Object && global;\n\nmodule.exports = freeGlobal;\n","var baseGetTag = require('./_baseGetTag'),\n isObject = require('./isObject');\n\n/** `Object#toString` result references. */\nvar asyncTag = '[object AsyncFunction]',\n funcTag = '[object Function]',\n genTag = '[object GeneratorFunction]',\n proxyTag = '[object Proxy]';\n\n/**\n * Checks if `value` is classified as a `Function` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a function, else `false`.\n * @example\n *\n * _.isFunction(_);\n * // => true\n *\n * _.isFunction(/abc/);\n * // => false\n */\nfunction isFunction(value) {\n if (!isObject(value)) {\n return false;\n }\n // The use of `Object#toString` avoids issues with the `typeof` operator\n // in Safari 9 which returns 'object' for typed arrays and other constructors.\n var tag = baseGetTag(value);\n return tag == funcTag || tag == genTag || tag == asyncTag || tag == proxyTag;\n}\n\nmodule.exports = isFunction;\n","/** Used for built-in method references. */\nvar funcProto = Function.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/**\n * Converts `func` to its source code.\n *\n * @private\n * @param {Function} func The function to convert.\n * @returns {string} Returns the source code.\n */\nfunction toSource(func) {\n if (func != null) {\n try {\n return funcToString.call(func);\n } catch (e) {}\n try {\n return (func + '');\n } catch (e) {}\n }\n return '';\n}\n\nmodule.exports = toSource;\n","/**\n * Performs a\n * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * comparison between two values to determine if they are equivalent.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n * @example\n *\n * var object = { 'a': 1 };\n * var other = { 'a': 1 };\n *\n * _.eq(object, object);\n * // => true\n *\n * _.eq(object, other);\n * // => false\n *\n * _.eq('a', 'a');\n * // => true\n *\n * _.eq('a', Object('a'));\n * // => false\n *\n * _.eq(NaN, NaN);\n * // => true\n */\nfunction eq(value, other) {\n return value === other || (value !== value && other !== other);\n}\n\nmodule.exports = eq;\n","var baseIsArguments = require('./_baseIsArguments'),\n isObjectLike = require('./isObjectLike');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Built-in value references. */\nvar propertyIsEnumerable = objectProto.propertyIsEnumerable;\n\n/**\n * Checks if `value` is likely an `arguments` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\n * else `false`.\n * @example\n *\n * _.isArguments(function() { return arguments; }());\n * // => true\n *\n * _.isArguments([1, 2, 3]);\n * // => false\n */\nvar isArguments = baseIsArguments(function() { return arguments; }()) ? baseIsArguments : function(value) {\n return isObjectLike(value) && hasOwnProperty.call(value, 'callee') &&\n !propertyIsEnumerable.call(value, 'callee');\n};\n\nmodule.exports = isArguments;\n","/** Used as references for various `Number` constants. */\nvar MAX_SAFE_INTEGER = 9007199254740991;\n\n/** Used to detect unsigned integer values. */\nvar reIsUint = /^(?:0|[1-9]\\d*)$/;\n\n/**\n * Checks if `value` is a valid array-like index.\n *\n * @private\n * @param {*} value The value to check.\n * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index.\n * @returns {boolean} Returns `true` if `value` is a valid index, else `false`.\n */\nfunction isIndex(value, length) {\n var type = typeof value;\n length = length == null ? MAX_SAFE_INTEGER : length;\n\n return !!length &&\n (type == 'number' ||\n (type != 'symbol' && reIsUint.test(value))) &&\n (value > -1 && value % 1 == 0 && value < length);\n}\n\nmodule.exports = isIndex;\n","var defineProperty = require('./_defineProperty');\n\n/**\n * The base implementation of `assignValue` and `assignMergeValue` without\n * value checks.\n *\n * @private\n * @param {Object} object The object to modify.\n * @param {string} key The key of the property to assign.\n * @param {*} value The value to assign.\n */\nfunction baseAssignValue(object, key, value) {\n if (key == '__proto__' && defineProperty) {\n defineProperty(object, key, {\n 'configurable': true,\n 'enumerable': true,\n 'value': value,\n 'writable': true\n });\n } else {\n object[key] = value;\n }\n}\n\nmodule.exports = baseAssignValue;\n","var baseFor = require('./_baseFor'),\n keys = require('./keys');\n\n/**\n * The base implementation of `_.forOwn` without support for iteratee shorthands.\n *\n * @private\n * @param {Object} object The object to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Object} Returns `object`.\n */\nfunction baseForOwn(object, iteratee) {\n return object && baseFor(object, iteratee, keys);\n}\n\nmodule.exports = baseForOwn;\n","var root = require('./_root'),\n stubFalse = require('./stubFalse');\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Built-in value references. */\nvar Buffer = moduleExports ? root.Buffer : undefined;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined;\n\n/**\n * Checks if `value` is a buffer.\n *\n * @static\n * @memberOf _\n * @since 4.3.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a buffer, else `false`.\n * @example\n *\n * _.isBuffer(new Buffer(2));\n * // => true\n *\n * _.isBuffer(new Uint8Array(2));\n * // => false\n */\nvar isBuffer = nativeIsBuffer || stubFalse;\n\nmodule.exports = isBuffer;\n","var baseIsTypedArray = require('./_baseIsTypedArray'),\n baseUnary = require('./_baseUnary'),\n nodeUtil = require('./_nodeUtil');\n\n/* Node.js helper references. */\nvar nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray;\n\n/**\n * Checks if `value` is classified as a typed array.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n * @example\n *\n * _.isTypedArray(new Uint8Array);\n * // => true\n *\n * _.isTypedArray([]);\n * // => false\n */\nvar isTypedArray = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray;\n\nmodule.exports = isTypedArray;\n","var baseMatches = require('./_baseMatches'),\n baseMatchesProperty = require('./_baseMatchesProperty'),\n identity = require('./identity'),\n isArray = require('./isArray'),\n property = require('./property');\n\n/**\n * The base implementation of `_.iteratee`.\n *\n * @private\n * @param {*} [value=_.identity] The value to convert to an iteratee.\n * @returns {Function} Returns the iteratee.\n */\nfunction baseIteratee(value) {\n // Don't store the `typeof` result in a variable to avoid a JIT bug in Safari 9.\n // See https://bugs.webkit.org/show_bug.cgi?id=156034 for more details.\n if (typeof value == 'function') {\n return value;\n }\n if (value == null) {\n return identity;\n }\n if (typeof value == 'object') {\n return isArray(value)\n ? baseMatchesProperty(value[0], value[1])\n : baseMatches(value);\n }\n return property(value);\n}\n\nmodule.exports = baseIteratee;\n","var ListCache = require('./_ListCache'),\n stackClear = require('./_stackClear'),\n stackDelete = require('./_stackDelete'),\n stackGet = require('./_stackGet'),\n stackHas = require('./_stackHas'),\n stackSet = require('./_stackSet');\n\n/**\n * Creates a stack cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction Stack(entries) {\n var data = this.__data__ = new ListCache(entries);\n this.size = data.size;\n}\n\n// Add methods to `Stack`.\nStack.prototype.clear = stackClear;\nStack.prototype['delete'] = stackDelete;\nStack.prototype.get = stackGet;\nStack.prototype.has = stackHas;\nStack.prototype.set = stackSet;\n\nmodule.exports = Stack;\n","var baseIsEqualDeep = require('./_baseIsEqualDeep'),\n isObjectLike = require('./isObjectLike');\n\n/**\n * The base implementation of `_.isEqual` which supports partial comparisons\n * and tracks traversed objects.\n *\n * @private\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @param {boolean} bitmask The bitmask flags.\n * 1 - Unordered comparison\n * 2 - Partial comparison\n * @param {Function} [customizer] The function to customize comparisons.\n * @param {Object} [stack] Tracks traversed `value` and `other` objects.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n */\nfunction baseIsEqual(value, other, bitmask, customizer, stack) {\n if (value === other) {\n return true;\n }\n if (value == null || other == null || (!isObjectLike(value) && !isObjectLike(other))) {\n return value !== value && other !== other;\n }\n return baseIsEqualDeep(value, other, bitmask, customizer, baseIsEqual, stack);\n}\n\nmodule.exports = baseIsEqual;\n","var SetCache = require('./_SetCache'),\n arraySome = require('./_arraySome'),\n cacheHas = require('./_cacheHas');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/**\n * A specialized version of `baseIsEqualDeep` for arrays with support for\n * partial deep comparisons.\n *\n * @private\n * @param {Array} array The array to compare.\n * @param {Array} other The other array to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `array` and `other` objects.\n * @returns {boolean} Returns `true` if the arrays are equivalent, else `false`.\n */\nfunction equalArrays(array, other, bitmask, customizer, equalFunc, stack) {\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG,\n arrLength = array.length,\n othLength = other.length;\n\n if (arrLength != othLength && !(isPartial && othLength > arrLength)) {\n return false;\n }\n // Check that cyclic values are equal.\n var arrStacked = stack.get(array);\n var othStacked = stack.get(other);\n if (arrStacked && othStacked) {\n return arrStacked == other && othStacked == array;\n }\n var index = -1,\n result = true,\n seen = (bitmask & COMPARE_UNORDERED_FLAG) ? new SetCache : undefined;\n\n stack.set(array, other);\n stack.set(other, array);\n\n // Ignore non-index properties.\n while (++index < arrLength) {\n var arrValue = array[index],\n othValue = other[index];\n\n if (customizer) {\n var compared = isPartial\n ? customizer(othValue, arrValue, index, other, array, stack)\n : customizer(arrValue, othValue, index, array, other, stack);\n }\n if (compared !== undefined) {\n if (compared) {\n continue;\n }\n result = false;\n break;\n }\n // Recursively compare arrays (susceptible to call stack limits).\n if (seen) {\n if (!arraySome(other, function(othValue, othIndex) {\n if (!cacheHas(seen, othIndex) &&\n (arrValue === othValue || equalFunc(arrValue, othValue, bitmask, customizer, stack))) {\n return seen.push(othIndex);\n }\n })) {\n result = false;\n break;\n }\n } else if (!(\n arrValue === othValue ||\n equalFunc(arrValue, othValue, bitmask, customizer, stack)\n )) {\n result = false;\n break;\n }\n }\n stack['delete'](array);\n stack['delete'](other);\n return result;\n}\n\nmodule.exports = equalArrays;\n","var isObject = require('./isObject');\n\n/**\n * Checks if `value` is suitable for strict equality comparisons, i.e. `===`.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` if suitable for strict\n * equality comparisons, else `false`.\n */\nfunction isStrictComparable(value) {\n return value === value && !isObject(value);\n}\n\nmodule.exports = isStrictComparable;\n","/**\n * A specialized version of `matchesProperty` for source values suitable\n * for strict equality comparisons, i.e. `===`.\n *\n * @private\n * @param {string} key The key of the property to get.\n * @param {*} srcValue The value to match.\n * @returns {Function} Returns the new spec function.\n */\nfunction matchesStrictComparable(key, srcValue) {\n return function(object) {\n if (object == null) {\n return false;\n }\n return object[key] === srcValue &&\n (srcValue !== undefined || (key in Object(object)));\n };\n}\n\nmodule.exports = matchesStrictComparable;\n","var castPath = require('./_castPath'),\n toKey = require('./_toKey');\n\n/**\n * The base implementation of `_.get` without support for default values.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Array|string} path The path of the property to get.\n * @returns {*} Returns the resolved value.\n */\nfunction baseGet(object, path) {\n path = castPath(path, object);\n\n var index = 0,\n length = path.length;\n\n while (object != null && index < length) {\n object = object[toKey(path[index++])];\n }\n return (index && index == length) ? object : undefined;\n}\n\nmodule.exports = baseGet;\n","var arrayReduce = require('./_arrayReduce'),\n deburr = require('./deburr'),\n words = require('./words');\n\n/** Used to compose unicode capture groups. */\nvar rsApos = \"['\\u2019]\";\n\n/** Used to match apostrophes. */\nvar reApos = RegExp(rsApos, 'g');\n\n/**\n * Creates a function like `_.camelCase`.\n *\n * @private\n * @param {Function} callback The function to combine each word.\n * @returns {Function} Returns the new compounder function.\n */\nfunction createCompounder(callback) {\n return function(string) {\n return arrayReduce(words(deburr(string).replace(reApos, '')), callback, '');\n };\n}\n\nmodule.exports = createCompounder;\n","/** Used to compose unicode character classes. */\nvar rsAstralRange = '\\\\ud800-\\\\udfff',\n rsComboMarksRange = '\\\\u0300-\\\\u036f',\n reComboHalfMarksRange = '\\\\ufe20-\\\\ufe2f',\n rsComboSymbolsRange = '\\\\u20d0-\\\\u20ff',\n rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange,\n rsVarRange = '\\\\ufe0e\\\\ufe0f';\n\n/** Used to compose unicode capture groups. */\nvar rsZWJ = '\\\\u200d';\n\n/** Used to detect strings with [zero-width joiners or code points from the astral planes](http://eev.ee/blog/2015/09/12/dark-corners-of-unicode/). */\nvar reHasUnicode = RegExp('[' + rsZWJ + rsAstralRange + rsComboRange + rsVarRange + ']');\n\n/**\n * Checks if `string` contains Unicode symbols.\n *\n * @private\n * @param {string} string The string to inspect.\n * @returns {boolean} Returns `true` if a symbol is found, else `false`.\n */\nfunction hasUnicode(string) {\n return reHasUnicode.test(string);\n}\n\nmodule.exports = hasUnicode;\n","import { gql } from '@eventespresso/data';\n\nexport const EVENT_ATTRIBUTES: any = gql`\n\tfragment eventAttributes on EspressoEvent {\n\t\tid\n\t\tdbId\n\t\tcacheId\n\t\tallowDonations\n\t\tallowOverflow\n\t\taltRegPage\n\t\tcreated\n\t\tdefaultRegStatus\n\t\tdescription\n\t\tdisplayDescription\n\t\tdisplayTicketSelector\n\t\tisActive\n\t\tisCancelled\n\t\tisExpired\n\t\tisInactive\n\t\tisPostponed\n\t\tisSoldOut\n\t\tisUpcoming\n\t\tmanager {\n\t\t\tid\n\t\t\tname\n\t\t}\n\t\tmaxRegistrations\n\t\tmemberOnly\n\t\tname\n\t\torder\n\t\tphoneNumber\n\t\tshortDescription\n\t\tstatus\n\t\ttimezoneString\n\t\tvenue\n\t}\n`;\n\nexport const GET_EVENT: any = gql`\n\tquery GET_EVENT($id: ID!) {\n\t\tespressoEvent(id: $id) {\n\t\t\t...eventAttributes\n\t\t}\n\t}\n\t${EVENT_ATTRIBUTES}\n`;\n","import { usePricesQuery } from '@eventespresso/data';\nimport { useMemoStringify } from '@eventespresso/hooks';\nimport { getCacheIds } from '@eventespresso/predicates';\n\nimport type { Price, PriceEdge } from '../../types';\nimport usePriceQueryOptions from './usePriceQueryOptions';\n\n/**\n * A custom react hook to retrieve all the prices from cache\n */\nconst usePrices = (): Price[] => {\n\tconst options = usePriceQueryOptions();\n\n\tconst { data } = usePricesQuery(options);\n\n\tconst nodes = data?.espressoPrices?.nodes || [];\n\n\tconst cacheIds = getCacheIds(nodes);\n\n\treturn useMemoStringify(nodes, cacheIds);\n};\n\nexport default usePrices;\n","import { useMemo } from 'react';\nimport type { CacheQueryOptions } from '@eventespresso/data';\n\nimport { GET_PRICE_TYPES } from '../priceTypes';\n\nconst usePriceTypeQueryOptions = (): CacheQueryOptions => {\n\tconst options: CacheQueryOptions = useMemo(\n\t\t() => ({\n\t\t\tquery: GET_PRICE_TYPES,\n\t\t}),\n\t\t[]\n\t);\n\n\treturn options;\n};\n\nexport default usePriceTypeQueryOptions;\n","import { useMemo } from 'react';\n\nimport type { VenuesList, VenuesQueryArgs, CacheQueryOptions } from '@eventespresso/data';\n\nimport { GET_VENUES } from '../venues';\nimport type { VenueEdge } from '../../';\n\nexport type VenuesQueryOptions = CacheQueryOptions, VenuesQueryArgs>;\n\nexport const useVenueQueryOptions = (queryArgs?: VenuesQueryArgs['where']): VenuesQueryOptions => {\n\treturn useMemo(() => {\n\t\treturn {\n\t\t\tquery: GET_VENUES,\n\t\t\tvariables: {\n\t\t\t\twhere: queryArgs,\n\t\t\t},\n\t\t};\n\t}, [queryArgs]);\n};\n","import { createContext } from 'react';\n\nimport type { DatetimesFilterStateManager } from '../../../filterState';\n\nimport { useDatesListFilterStateManager } from '../../../filterState';\n\nconst DatesFilterStateContext = createContext(null);\n\nconst { Provider, Consumer: DatesFilterStateConsumer } = DatesFilterStateContext;\n\nconst DatesFilterStateProvider: React.FC = ({ children }) => {\n\tconst filterState = useDatesListFilterStateManager();\n\n\treturn {children};\n};\n\nexport { DatesFilterStateContext, DatesFilterStateProvider, DatesFilterStateConsumer };\n","import { createContext, useEffect } from 'react';\n\nimport { useFilteredEntities } from '@eventespresso/services';\nimport { getGuids } from '@eventespresso/predicates';\nimport { useMemoStringify } from '@eventespresso/hooks';\nimport type { EntityId } from '@eventespresso/data';\n\nimport { useDatesListFilterState } from '../../../filterState';\nimport { domain, datesList } from '../../../constants';\nimport { useDatetimes } from '../../../apollo';\nimport { useVisibleDatetimeIds } from '../../../hooks';\n\nconst FilteredDatesContext = createContext>(null);\n\nconst { Provider, Consumer: FilteredDatesConsumer } = FilteredDatesContext;\n\nconst FilteredDatesProvider: React.FC = ({ children }) => {\n\tconst datetimes = useDatetimes();\n\tconst filterState = useDatesListFilterState();\n\n\tconst filteredEntities = useFilteredEntities(domain, datesList, datetimes, filterState);\n\n\tconst filteredEntityIds = useMemoStringify(getGuids(filteredEntities));\n\n\t// Update Edtr state for isChained filter\n\tconst [, setVisibleDatetimeIds] = useVisibleDatetimeIds();\n\tuseEffect(() => {\n\t\tsetVisibleDatetimeIds(filteredEntityIds);\n\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\t}, [filteredEntityIds]);\n\n\treturn {children};\n};\n\nexport { FilteredDatesContext, FilteredDatesProvider, FilteredDatesConsumer };\n","import { createContext } from 'react';\n\nimport type { TicketsFilterStateManager } from '../../../filterState';\n\nimport { useTicketsListFilterStateManager } from '../../../filterState';\n\nconst TicketsFilterStateContext = createContext(null);\n\nconst { Provider, Consumer: TicketsFilterStateConsumer } = TicketsFilterStateContext;\n\nconst TicketsFilterStateProvider: React.FC = ({ children }) => {\n\tconst filterState = useTicketsListFilterStateManager();\n\n\treturn {children};\n};\n\nexport { TicketsFilterStateContext, TicketsFilterStateProvider, TicketsFilterStateConsumer };\n","import { createContext, useEffect } from 'react';\n\nimport { getGuids } from '@eventespresso/predicates';\nimport { useFilteredEntities } from '@eventespresso/services';\nimport type { EntityId } from '@eventespresso/data';\nimport { useMemoStringify } from '@eventespresso/hooks';\n\nimport { useTicketsListFilterState } from '../../../filterState';\nimport { domain, ticketsList } from '../../../constants';\nimport { useTickets } from '../../../apollo';\nimport { useVisibleTicketIds } from '../../../hooks';\n\nconst FilteredTicketsContext = createContext>(null);\n\nconst { Provider, Consumer: FilteredTicketsConsumer } = FilteredTicketsContext;\n\nconst FilteredTicketsProvider: React.FC = ({ children }) => {\n\tconst tickets = useTickets();\n\n\tconst filterState = useTicketsListFilterState();\n\n\tconst filteredEntities = useFilteredEntities(domain, ticketsList, tickets, filterState);\n\n\tconst filteredEntityIds = useMemoStringify(getGuids(filteredEntities));\n\n\t// Update Edtr state for bulk edit.\n\tconst [, setVisibleTicketIds] = useVisibleTicketIds();\n\tuseEffect(() => {\n\t\tsetVisibleTicketIds(getGuids(filteredEntities));\n\t}, [filteredEntities, filteredEntityIds, setVisibleTicketIds]);\n\n\treturn {children};\n};\n\nexport { FilteredTicketsContext, FilteredTicketsProvider, FilteredTicketsConsumer };\n","(function() { module.exports = window[\"wp\"][\"url\"]; }());","var capitalize = require('./capitalize'),\n createCompounder = require('./_createCompounder');\n\n/**\n * Converts `string` to [camel case](https://en.wikipedia.org/wiki/CamelCase).\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to convert.\n * @returns {string} Returns the camel cased string.\n * @example\n *\n * _.camelCase('Foo Bar');\n * // => 'fooBar'\n *\n * _.camelCase('--foo-bar--');\n * // => 'fooBar'\n *\n * _.camelCase('__FOO_BAR__');\n * // => 'fooBar'\n */\nvar camelCase = createCompounder(function(result, word, index) {\n word = word.toLowerCase();\n return result + (index ? capitalize(word) : word);\n});\n\nmodule.exports = camelCase;\n","var baseAssignValue = require('./_baseAssignValue'),\n baseForOwn = require('./_baseForOwn'),\n baseIteratee = require('./_baseIteratee');\n\n/**\n * The opposite of `_.mapValues`; this method creates an object with the\n * same values as `object` and keys generated by running each own enumerable\n * string keyed property of `object` thru `iteratee`. The iteratee is invoked\n * with three arguments: (value, key, object).\n *\n * @static\n * @memberOf _\n * @since 3.8.0\n * @category Object\n * @param {Object} object The object to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @returns {Object} Returns the new mapped object.\n * @see _.mapValues\n * @example\n *\n * _.mapKeys({ 'a': 1, 'b': 2 }, function(value, key) {\n * return key + value;\n * });\n * // => { 'a1': 1, 'b2': 2 }\n */\nfunction mapKeys(object, iteratee) {\n var result = {};\n iteratee = baseIteratee(iteratee, 3);\n\n baseForOwn(object, function(value, key, object) {\n baseAssignValue(result, iteratee(value, key, object), value);\n });\n return result;\n}\n\nmodule.exports = mapKeys;\n","\n/**\n * Topological sorting function\n *\n * @param {Array} edges\n * @returns {Array}\n */\n\nmodule.exports = function(edges) {\n return toposort(uniqueNodes(edges), edges)\n}\n\nmodule.exports.array = toposort\n\nfunction toposort(nodes, edges) {\n var cursor = nodes.length\n , sorted = new Array(cursor)\n , visited = {}\n , i = cursor\n // Better data structures make algorithm much faster.\n , outgoingEdges = makeOutgoingEdges(edges)\n , nodesHash = makeNodesHash(nodes)\n\n // check for unknown nodes\n edges.forEach(function(edge) {\n if (!nodesHash.has(edge[0]) || !nodesHash.has(edge[1])) {\n throw new Error('Unknown node. There is an unknown node in the supplied edges.')\n }\n })\n\n while (i--) {\n if (!visited[i]) visit(nodes[i], i, new Set())\n }\n\n return sorted\n\n function visit(node, i, predecessors) {\n if(predecessors.has(node)) {\n var nodeRep\n try {\n nodeRep = \", node was:\" + JSON.stringify(node)\n } catch(e) {\n nodeRep = \"\"\n }\n throw new Error('Cyclic dependency' + nodeRep)\n }\n\n if (!nodesHash.has(node)) {\n throw new Error('Found unknown node. Make sure to provided all involved nodes. Unknown node: '+JSON.stringify(node))\n }\n\n if (visited[i]) return;\n visited[i] = true\n\n var outgoing = outgoingEdges.get(node) || new Set()\n outgoing = Array.from(outgoing)\n\n if (i = outgoing.length) {\n predecessors.add(node)\n do {\n var child = outgoing[--i]\n visit(child, nodesHash.get(child), predecessors)\n } while (i)\n predecessors.delete(node)\n }\n\n sorted[--cursor] = node\n }\n}\n\nfunction uniqueNodes(arr){\n var res = new Set()\n for (var i = 0, len = arr.length; i < len; i++) {\n var edge = arr[i]\n res.add(edge[0])\n res.add(edge[1])\n }\n return Array.from(res)\n}\n\nfunction makeOutgoingEdges(arr){\n var edges = new Map()\n for (var i = 0, len = arr.length; i < len; i++) {\n var edge = arr[i]\n if (!edges.has(edge[0])) edges.set(edge[0], new Set())\n if (!edges.has(edge[1])) edges.set(edge[1], new Set())\n edges.get(edge[0]).add(edge[1])\n }\n return edges\n}\n\nfunction makeNodesHash(arr){\n var res = new Map()\n for (var i = 0, len = arr.length; i < len; i++) {\n res.set(arr[i], i)\n }\n return res\n}\n","import { useMemo } from 'react';\n\nimport useUpdateEntityList from './useUpdateEntityList';\nimport { useDatetimeQueryOptions, DatetimesList } from '../../apollo';\nimport { CacheUpdaterFn, WriteQueryOptions } from '@eventespresso/data';\n\nconst useUpdateDatetimeList = (\n\twriteQueryOptions: WriteQueryOptions = undefined\n): CacheUpdaterFn => {\n\tconst queryOptions = useDatetimeQueryOptions();\n\tconst options = useMemo(\n\t\t() => ({\n\t\t\t...queryOptions,\n\t\t\t...writeQueryOptions,\n\t\t}),\n\t\t[queryOptions, writeQueryOptions]\n\t);\n\treturn useUpdateEntityList(options);\n};\n\nexport default useUpdateDatetimeList;\n","import { useMemo } from 'react';\n\nimport useUpdateEntityList from './useUpdateEntityList';\nimport { TicketsList, useTicketQueryOptions } from '../../apollo';\nimport { CacheUpdaterFn, WriteQueryOptions } from '@eventespresso/data';\n\nconst useUpdateTicketList = (\n\twriteQueryOptions: WriteQueryOptions = undefined\n): CacheUpdaterFn => {\n\tconst queryOptions = useTicketQueryOptions();\n\tconst options = useMemo(\n\t\t() => ({\n\t\t\t...queryOptions,\n\t\t\t...writeQueryOptions,\n\t\t}),\n\t\t[queryOptions, writeQueryOptions]\n\t);\n\treturn useUpdateEntityList(options);\n};\n\nexport default useUpdateTicketList;\n","export * from './queries';\n\nexport { default as useEvent } from './useEvent';\n\nexport { default as useEventQueryOptions } from './useEventQueryOptions';\n\nexport { default as useEventId } from './useEventId';\n","import { isDefault } from '@eventespresso/predicates';\n\nimport useTickets from './useTickets';\nimport type { Ticket } from '../../types';\n\nconst useDefaultTickets = (): Array => {\n\treturn useTickets(isDefault);\n};\n\nexport default useDefaultTickets;\n","import { useMemoStringify } from '@eventespresso/hooks';\nimport { getGuids } from '@eventespresso/predicates';\nimport type { EntityId } from '@eventespresso/data';\n\nimport useDefaultTickets from './useDefaultTickets';\n\nconst useDefaultTicketIds = (): EntityId[] => {\n\tconst tickets = useDefaultTickets();\n\n\treturn useMemoStringify(getGuids(tickets));\n};\n\nexport default useDefaultTicketIds;\n","import { useMemoStringify } from '@eventespresso/hooks';\nimport { getGuids } from '@eventespresso/predicates';\nimport type { EntityId } from '@eventespresso/data';\nimport useTickets from './useTickets';\n\nconst useTicketIds = (): EntityId[] => {\n\tconst tickets = useTickets();\n\n\treturn useMemoStringify(getGuids(tickets));\n};\n\nexport default useTicketIds;\n","import { useMemo } from 'react';\n\nimport { useCacheQuery, CacheQueryOptions } from '@eventespresso/data';\nimport { useMemoStringify } from '@eventespresso/hooks';\n\nimport { GET_TICKET } from './queries';\nimport type { Ticket, TicketItem } from '../../types';\nimport type { EntityItemProps } from '../types';\n\nconst useTicketItem = ({ id }: EntityItemProps): Ticket => {\n\tconst options = useMemo(\n\t\t() => ({\n\t\t\tquery: GET_TICKET,\n\t\t\tvariables: {\n\t\t\t\tid,\n\t\t\t},\n\t\t\treturnPartialData: true, // avoid console warnings if data not present\n\t\t}),\n\t\t[id]\n\t);\n\tconst { data } = useCacheQuery(options);\n\n\treturn useMemoStringify(data?.espressoTicket);\n};\n\nexport default useTicketItem;\n","import { useCallback } from 'react';\n\nimport { entitiesWithGuIdInArray } from '@eventespresso/predicates';\nimport { useRelations } from '@eventespresso/services';\nimport { EntityId } from '@eventespresso/data';\n\nimport { usePrices } from '../prices';\nimport type { Price } from '../../types';\n\ntype GetTicketPrices = (ticketId: EntityId) => Array;\n/**\n * A custom react hook for retrieving the related prices\n * for the given `ticket` identified by `ticket.id`\n *\n * @param {string|string[]} ticketId ticket.id\n */\nconst useTicketPrices = (): GetTicketPrices => {\n\tconst prices = usePrices();\n\tconst { getRelations } = useRelations();\n\n\treturn useCallback(\n\t\t(ticketId) => {\n\t\t\tconst relatedPricesIds = getRelations({\n\t\t\t\tentity: 'tickets',\n\t\t\t\tentityId: ticketId,\n\t\t\t\trelation: 'prices',\n\t\t\t});\n\n\t\t\treturn entitiesWithGuIdInArray(prices, relatedPricesIds);\n\t\t},\n\t\t[getRelations, prices]\n\t);\n};\n\nexport default useTicketPrices;\n","import { useCallback } from 'react';\nimport * as R from 'ramda';\n\nimport { EntityId } from '@eventespresso/data';\nimport { useRelations } from '@eventespresso/services';\nimport { minDateCapacity, ticketQuantityFromCapacity } from '@eventespresso/predicates';\n\nimport { useDatetimes } from '../datetimes';\n\ntype GetCappedQuantity = (args: {\n\tcapacity?: number;\n\tquantity: number;\n\trelatedDateIds?: Array;\n\tticketId?: EntityId;\n}) => number;\n\n/**\n * Returns a callback to get the quantity cap for a ticket\n * based on the related dates capacity\n */\nexport const useCappedQuantity = () => {\n\tconst allDates = useDatetimes();\n\n\tconst { getRelations } = useRelations();\n\n\treturn useCallback(\n\t\t// at least one of `relatedDateIds` and `ticketId` must be passed\n\t\t({ capacity, quantity, ticketId, relatedDateIds = [] }) => {\n\t\t\tconst dateIdsToUse = relatedDateIds?.length\n\t\t\t\t? relatedDateIds\n\t\t\t\t: getRelations({\n\t\t\t\t\t\tentity: 'tickets',\n\t\t\t\t\t\tentityId: ticketId,\n\t\t\t\t\t\trelation: 'datetimes',\n\t\t\t\t });\n\t\t\tconst minimumCapacity = !R.isNil(capacity) ? capacity : minDateCapacity(allDates)(dateIdsToUse);\n\n\t\t\treturn ticketQuantityFromCapacity(minimumCapacity)(quantity);\n\t\t},\n\t\t[allDates, getRelations]\n\t);\n};\n","import type { PriceType, PriceTypesList } from '../../types';\nimport { useCacheQuery } from '@eventespresso/data';\nimport { useMemoStringify } from '@eventespresso/hooks';\nimport usePriceTypeQueryOptions from './usePriceTypeQueryOptions';\nimport { getCacheIds } from '@eventespresso/predicates';\n\n/**\n * A custom react hook for retrieving all the priceTypes from cache\n */\nconst usePriceTypes = (): PriceType[] => {\n\tconst options = usePriceTypeQueryOptions();\n\tconst { data } = useCacheQuery(options);\n\n\tconst nodes = data?.espressoPriceTypes?.nodes || [];\n\n\tconst cacheIds = getCacheIds(nodes);\n\n\treturn useMemoStringify(nodes, cacheIds);\n};\n\nexport default usePriceTypes;\n","import { getDefaultPriceModifierType } from '@eventespresso/predicates';\nimport { useMemoStringify } from '@eventespresso/hooks';\nimport usePriceTypes from './usePriceTypes';\nimport type { PriceType } from '../../types';\n\n/**\n * A custom react hook for retrieving the default price type object.\n */\nconst useDefaultPriceType = (): PriceType | null => {\n\tconst allPriceTypes = usePriceTypes();\n\tconst defaultPriceType: PriceType | null = getDefaultPriceModifierType(allPriceTypes);\n\treturn useMemoStringify(defaultPriceType);\n};\n\nexport default useDefaultPriceType;\n","import isEmpty from 'ramda/src/isEmpty';\n\nimport { useMemoStringify } from '@eventespresso/hooks';\nimport { entitiesWithGuIdInArray } from '@eventespresso/predicates';\nimport { useRelations } from '@eventespresso/services';\n\nimport useDefaultPriceType from './useDefaultPriceType';\nimport usePriceTypes from './usePriceTypes';\n\nimport type { EntityId } from '@eventespresso/data';\nimport type { PriceType } from '../../types';\n\n/**\n * A custom react hook for retrieving the related priceType from cache for the given Price entity\n *\n * @param {string} priceId price.id\n */\nconst usePriceTypeForPrice = (priceId: EntityId): PriceType | null => {\n\tconst { getRelations } = useRelations();\n\t// get related priceTypes for this price\n\tconst relatedPriceTypeIds = getRelations({\n\t\tentity: 'prices',\n\t\tentityId: priceId,\n\t\trelation: 'priceTypes',\n\t});\n\n\t// get the default price type object\n\tconst defaultPriceType: PriceType | null = useDefaultPriceType();\n\tconst allPriceTypes = usePriceTypes();\n\n\tconst relatedPriceTypes = entitiesWithGuIdInArray(allPriceTypes, relatedPriceTypeIds);\n\n\tconst priceType = !isEmpty(relatedPriceTypes) ? relatedPriceTypes[0] : defaultPriceType;\n\n\treturn useMemoStringify(priceType);\n};\n\nexport default usePriceTypeForPrice;\n","import { useCallback } from 'react';\n\nimport { useRelations } from '@eventespresso/services';\nimport type { EntityId } from '@eventespresso/data';\n\nimport { useBulkDeleteTickets } from '../tickets';\n\ntype Callback = (datetimeId: EntityId, deletePermanently?: boolean) => Promise;\n\n/**\n * Returns a callback to delete or trash the related tickets for a given date\n * if the ticket only related to the date\n */\nconst useDeleteRelatedTickets = (): Callback => {\n\tconst { getRelations } = useRelations();\n\n\tconst deleteTickets = useBulkDeleteTickets();\n\n\treturn useCallback(\n\t\tasync (datetimeId, deletePermanently) => {\n\t\t\tconst relatedTicketIds = getRelations({\n\t\t\t\tentity: 'datetimes',\n\t\t\t\tentityId: datetimeId,\n\t\t\t\trelation: 'tickets',\n\t\t\t});\n\n\t\t\tconst ticketIdsRelatedOnlyToTheDate = relatedTicketIds.filter((ticketId) => {\n\t\t\t\tconst relatedDatetimeIds = getRelations({\n\t\t\t\t\tentity: 'tickets',\n\t\t\t\t\tentityId: ticketId,\n\t\t\t\t\trelation: 'datetimes',\n\t\t\t\t});\n\n\t\t\t\treturn relatedDatetimeIds.length === 1;\n\t\t\t});\n\n\t\t\t// if we have something to work with\n\t\t\tif (ticketIdsRelatedOnlyToTheDate.length) {\n\t\t\t\tawait deleteTickets({\n\t\t\t\t\tentityIds: ticketIdsRelatedOnlyToTheDate,\n\t\t\t\t\tdeletePermanently,\n\t\t\t\t\tdeleteRemotely: false,\n\t\t\t\t\trelatedDatetimeIds: [datetimeId],\n\t\t\t\t});\n\t\t\t}\n\t\t},\n\t\t[deleteTickets, getRelations]\n\t);\n};\n\nexport default useDeleteRelatedTickets;\n","import { getHooks } from '@eventespresso/ioc';\nimport type { MutationType, ApolloCache, Entity } from '@eventespresso/data';\nimport type { OptionsType } from '@eventespresso/adapters';\nimport type { BulkEdit } from '@eventespresso/services';\nimport type { ButtonProps } from '@eventespresso/ui-components';\nimport type { SimpleTextEditorModalProps } from '@eventespresso/ee-components';\n\nimport { Datetime, Ticket } from '../apollo';\nimport { DateFormShape, DateFormConfig, TicketFormShape, TicketFormConfig } from '../forms';\n\ntype MutationActionArgs = [\n\tmutationType: MutationType,\n\tinput: Record,\n\tentity: E,\n\tcache?: ApolloCache\n];\n\nexport type Actions = {\n\t'eventEditor.ticket.mutation': MutationActionArgs;\n\t'eventEditor.datetimes.bulkEdit.apply': [action: string, bulkEdit: BulkEdit];\n};\nexport type Filters = {\n\t'eventEditor.ticketForm.initalValues': [initialValues: TicketFormShape, ticket: Ticket];\n\t'eventEditor.ticketForm.sections': [sections: TicketFormConfig['sections'], ticket: Ticket];\n\t'eventEditor.dateForm.initalValues': [initialValues: DateFormShape, datetime: Datetime];\n\t'eventEditor.dateForm.sections': [sections: DateFormConfig['sections'], datetime: Datetime];\n\t'eventEditor.ticket.mutationInput': [input: Record, rawInput?: Record];\n\t'eventEditor.datetimes.bulkEdit.actions': [actions: OptionsType];\n\t'eventEditor.addSingleDate.button': [button: JSX.Element, isOnlyButton: boolean];\n\t'eventEditor.addSingleDate.buttonProps': [props: Partial, isOnlyButton: boolean];\n\t'eventEditor.datetimes.inlineDescriptionProps': [props: Partial, entity: Datetime];\n\t'eventEditor.tickets.inlineDescriptionProps': [props: Partial, entity: Ticket];\n};\n\nexport const hooks = getHooks();\n","import { useCallback, useMemo } from 'react';\nimport { identity, unnest } from 'ramda';\n\nimport { useMutationWithFeedback, MutationType } from '@eventespresso/data';\nimport type { TicketPred } from '@eventespresso/predicates';\n\nimport type { TicketEdge, Ticket } from '../../types';\nimport { useTicketQueryOptions, useTickets } from '../../queries';\nimport { useUpdateTicketList } from '../../../hooks';\nimport { BulkUpdateTicketInput, BULK_UPDATE_TICKETS } from './';\nimport { SINGULAR_ENTITY_NAME } from '../../../constants';\nimport { cacheNodesFromBulkInput, updateTicketFlags } from '../utils';\nimport useOnUpdateTicket from './useOnUpdateTicket';\nimport useAffectedDatesQueries from './useAffectedDatesQueries';\n\ninterface BulkEditTickets {\n\tupdateEntities: (input: BulkUpdateTicketInput) => ReturnType>;\n}\n\nconst useBulkEditTickets = (): BulkEditTickets => {\n\t// ensure that bulk edit preserves default tickets\n\tconst allTickets = useTickets(identity as TicketPred);\n\tconst queryOptions = useTicketQueryOptions();\n\tconst updateTicketList = useUpdateTicketList();\n\tconst onUpdateTicket = useOnUpdateTicket();\n\tconst affectedDatesQueries = useAffectedDatesQueries();\n\n\tconst updateTickets = useMutationWithFeedback({\n\t\ttypeName: SINGULAR_ENTITY_NAME.TICKET,\n\t\tmutationType: MutationType.Update,\n\t\tmutation: BULK_UPDATE_TICKETS,\n\t});\n\n\tconst updateEntityList = useCallback(\n\t\t(input: BulkUpdateTicketInput) => () => {\n\t\t\tconst nodes = cacheNodesFromBulkInput(input, allTickets).map(updateTicketFlags);\n\n\t\t\tconst espressoTickets: TicketEdge = {\n\t\t\t\tnodes,\n\t\t\t\t__typename: 'EspressoRootQueryTicketsConnection',\n\t\t\t};\n\t\t\tupdateTicketList({\n\t\t\t\t...queryOptions,\n\t\t\t\tdata: {\n\t\t\t\t\tespressoTickets,\n\t\t\t\t},\n\t\t\t});\n\t\t\t// update entity relations\n\t\t\tinput.uniqueInputs.forEach(({ datetimes, prices, ...updateInput }) => {\n\t\t\t\tonUpdateTicket({ ticket: updateInput as Ticket, datetimeIds: datetimes, priceIds: prices });\n\t\t\t});\n\t\t},\n\t\t[allTickets, onUpdateTicket, queryOptions, updateTicketList]\n\t);\n\n\tconst updateEntities = useCallback(\n\t\t(input) => {\n\t\t\tconst variables = {\n\t\t\t\tinput: {\n\t\t\t\t\tclientMutationId: 'BULK_UPDATE_TICKETS',\n\t\t\t\t\t...input,\n\t\t\t\t},\n\t\t\t};\n\t\t\t// fetch the affected dates.\n\t\t\tconst refetchQueries = unnest(input.uniqueInputs.map((input) => affectedDatesQueries({ input }))).filter(\n\t\t\t\tBoolean\n\t\t\t);\n\n\t\t\treturn updateTickets({ variables, update: updateEntityList(input), refetchQueries });\n\t\t},\n\t\t[updateTickets, updateEntityList, affectedDatesQueries]\n\t);\n\n\treturn useMemo(() => ({ updateEntities }), [updateEntities]);\n};\n\nexport default useBulkEditTickets;\n","const useEventGuid = (): string => {\n\treturn window?.eventEspressoData?.eventEditor?.event?.id || '';\n};\n\nexport default useEventGuid;\n","import { useMemo } from 'react';\n\nimport type { CacheQueryOptions } from '@eventespresso/data';\nimport useEventGuid from '../events/useEventGuid';\nimport { GET_EVENT } from './queries';\n\nconst useEventQueryOptions = (): CacheQueryOptions => {\n\tconst id = useEventGuid();\n\n\treturn useMemo(\n\t\t() => ({\n\t\t\tquery: GET_EVENT,\n\t\t\tvariables: {\n\t\t\t\tid,\n\t\t\t},\n\t\t}),\n\t\t[id]\n\t);\n};\n\nexport default useEventQueryOptions;\n","import { gql } from '@eventespresso/data';\n\nexport const PRICE_TYPE_ATTRIBUTES: any = gql`\n\tfragment priceTypeAttributes on EspressoPriceType {\n\t\tid\n\t\tdbId\n\t\tbaseType\n\t\tcacheId\n\t\tisBasePrice\n\t\tisDiscount\n\t\tisPercent\n\t\tisTax\n\t\tisTrashed\n\t\tname\n\t\torder\n\t}\n`;\n\nexport const GET_PRICE_TYPE: any = gql`\n\tquery GET_PRICE_TYPE($id: ID!) {\n\t\tpriceType(id: $id) {\n\t\t\t...priceTypeAttributes\n\t\t}\n\t}\n\t${PRICE_TYPE_ATTRIBUTES}\n`;\n\nexport const GET_PRICE_TYPES: any = gql`\n\tquery GET_PRICE_TYPES {\n\t\tespressoPriceTypes {\n\t\t\tnodes {\n\t\t\t\t...priceTypeAttributes\n\t\t\t}\n\t\t}\n\t}\n\t${PRICE_TYPE_ATTRIBUTES}\n`;\n","import { useCallback } from 'react';\nimport { findIndex, update } from 'ramda';\n\nimport type { CacheUpdaterFn, CacheUpdaterFnArgs } from '../types';\nimport type { Datetime, DatetimesList } from '../../types';\nimport { WriteQueryOptions } from '@eventespresso/data';\nimport { entityHasGuid } from '@eventespresso/predicates';\nimport { useDatetimeQueryOptions } from '../../queries';\n\nconst useUpdateDatetimeCache = (): CacheUpdaterFn => {\n\tconst queryOptions = useDatetimeQueryOptions();\n\n\tconst updateDatetimeCache = useCallback(\n\t\t({ cache, datetimes, datetime, action }: CacheUpdaterFnArgs): void => {\n\t\t\tconst { nodes = [] } = datetimes;\n\t\t\tlet newNodes: Array = [],\n\t\t\t\tdatetimeIndex: number;\n\t\t\tswitch (action) {\n\t\t\t\tcase 'add':\n\t\t\t\t\tnewNodes = [...nodes, datetime];\n\t\t\t\t\tbreak;\n\t\t\t\tcase 'update':\n\t\t\t\t\t// find the index of the datetime to update\n\t\t\t\t\tdatetimeIndex = findIndex(entityHasGuid(datetime.id), nodes);\n\t\t\t\t\t// if datetime exists\n\t\t\t\t\tif (datetimeIndex >= 0) {\n\t\t\t\t\t\tnewNodes = update(datetimeIndex, datetime, nodes);\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase 'remove':\n\t\t\t\t\tnewNodes = nodes.filter(({ id }) => id !== datetime.id);\n\t\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t\tnewNodes = nodes;\n\t\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\t// write the data to cache without\n\t\t\t// mutating the cache directly\n\t\t\tconst writeOptions: WriteQueryOptions = {\n\t\t\t\t...queryOptions,\n\t\t\t\tdata: {\n\t\t\t\t\tespressoDatetimes: {\n\t\t\t\t\t\t...datetimes,\n\t\t\t\t\t\tnodes: newNodes,\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t};\n\t\t\tcache.writeQuery(writeOptions);\n\t\t},\n\t\t[queryOptions]\n\t);\n\n\treturn updateDatetimeCache;\n};\n\nexport default useUpdateDatetimeCache;\n","import type { CacheUpdaterFnArgs } from '../types';\nimport { GET_TICKETS } from '../../queries';\nimport type { TicketsList } from '../../types';\nimport { sortBy, identity } from 'ramda';\nimport type { CacheQueryOptions, WriteQueryOptions } from '@eventespresso/data';\n\nconst updateTicketCache = ({ cache, datetimeIn, datetimeId, action }: CacheUpdaterFnArgs): void => {\n\tconst queryOptions: CacheQueryOptions = {\n\t\tquery: GET_TICKETS,\n\t\tvariables: {\n\t\t\twhere: {\n\t\t\t\tdatetimeIn: sortBy(identity, datetimeIn),\n\t\t\t},\n\t\t},\n\t};\n\tlet data: TicketsList;\n\t// Read the existing data from cache.\n\ttry {\n\t\tdata = cache.readQuery(queryOptions);\n\t} catch (error) {\n\t\tdata = null;\n\t}\n\n\t// if there are no tickets\n\tif (!data?.espressoTickets) {\n\t\treturn;\n\t}\n\n\tlet newDatetimeIn: typeof datetimeIn;\n\n\tswitch (action) {\n\t\tcase 'add':\n\t\t\tnewDatetimeIn = [...datetimeIn, datetimeId];\n\t\t\tbreak;\n\t\tcase 'remove':\n\t\t\tnewDatetimeIn = datetimeIn.filter((id) => id !== datetimeId);\n\t\t\tbreak;\n\t\tdefault:\n\t\t\tnewDatetimeIn = datetimeIn;\n\t\t\tbreak;\n\t}\n\n\tconst writeOptions: WriteQueryOptions = {\n\t\tquery: GET_TICKETS,\n\t\tdata,\n\t\tvariables: {\n\t\t\twhere: {\n\t\t\t\tdatetimeIn: sortBy(identity, newDatetimeIn),\n\t\t\t},\n\t\t},\n\t};\n\n\t// write the data to cache without\n\t// mutating the cache directly\n\tcache.writeQuery(writeOptions);\n};\n\nexport default updateTicketCache;\n","import { useCallback } from 'react';\n\nimport { useRelations } from '@eventespresso/services';\nimport { hasTempId } from '@eventespresso/predicates';\nimport type { DatetimeMutationCallbackFn, DatetimeMutationCallbackFnArgs } from '../types';\n\nconst useOnUpdateDatetime = (): DatetimeMutationCallbackFn => {\n\tconst { addRelation, removeRelation, updateRelations } = useRelations();\n\n\tconst onUpdateDatetime = useCallback(\n\t\t({ datetime, tickets }: DatetimeMutationCallbackFnArgs): void => {\n\t\t\tif (hasTempId(datetime)) {\n\t\t\t\treturn;\n\t\t\t}\n\t\t\tconst datetimeId = datetime?.id;\n\t\t\t// if related tickets are passed\n\t\t\t// may be empty array to remove relations\n\t\t\tif (tickets) {\n\t\t\t\t// make sure to remove datetime from\n\t\t\t\t// all existing relations\n\t\t\t\tremoveRelation({\n\t\t\t\t\tentity: 'datetimes',\n\t\t\t\t\tentityId: datetimeId,\n\t\t\t\t\trelation: 'tickets',\n\t\t\t\t});\n\n\t\t\t\t// if we have any tickets\n\t\t\t\tif (tickets.length) {\n\t\t\t\t\tupdateRelations({\n\t\t\t\t\t\tentity: 'datetimes',\n\t\t\t\t\t\tentityId: datetimeId,\n\t\t\t\t\t\trelation: 'tickets',\n\t\t\t\t\t\trelationIds: tickets,\n\t\t\t\t\t});\n\n\t\t\t\t\ttickets.forEach((entityId) => {\n\t\t\t\t\t\taddRelation({\n\t\t\t\t\t\t\tentity: 'tickets',\n\t\t\t\t\t\t\tentityId,\n\t\t\t\t\t\t\trelation: 'datetimes',\n\t\t\t\t\t\t\trelationId: datetimeId,\n\t\t\t\t\t\t});\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t}\n\t\t},\n\t\t[addRelation, removeRelation, updateRelations]\n\t);\n\n\treturn onUpdateDatetime;\n};\n\nexport default useOnUpdateDatetime;\n","import { useCallback } from 'react';\n\nimport updateTicketCache from './updateTicketCache';\nimport useUpdateDatetimeCache from './useUpdateDatetimeCache';\nimport type { DatetimeMutationCallbackFn, DatetimeMutationCallbackFnArgs } from '../types';\nimport { useRelations } from '@eventespresso/services';\nimport { getGuids, hasTempId } from '@eventespresso/predicates';\n\nconst useOnDeleteDatetime = (): DatetimeMutationCallbackFn => {\n\tconst { dropRelations, removeRelation } = useRelations();\n\n\tconst updateDatetimeCache = useUpdateDatetimeCache();\n\n\tconst onDeleteDatetime = useCallback(\n\t\t({ cache, datetimes, datetime, deletePermanently }: DatetimeMutationCallbackFnArgs): void => {\n\t\t\tconst action = deletePermanently ? 'remove' : 'update';\n\t\t\tif (!hasTempId(datetime) && deletePermanently) {\n\t\t\t\tconst { nodes = [] } = datetimes;\n\t\t\t\tconst datetimeIn = getGuids(nodes);\n\t\t\t\tconst { id: datetimeId } = datetime;\n\n\t\t\t\t// Update tickets cache for the changed datetimes,\n\t\t\t\t// to avoid refetching of tickets.\n\t\t\t\tupdateTicketCache({ cache, datetimeIn, datetimeId, action });\n\n\t\t\t\t// Remove the datetime from all ticket relations\n\t\t\t\tremoveRelation({\n\t\t\t\t\tentity: 'datetimes',\n\t\t\t\t\tentityId: datetimeId,\n\t\t\t\t\trelation: 'tickets',\n\t\t\t\t});\n\t\t\t\t// Drop all the relations for the datetime\n\t\t\t\tdropRelations({\n\t\t\t\t\tentity: 'datetimes',\n\t\t\t\t\tentityId: datetimeId,\n\t\t\t\t});\n\t\t\t}\n\t\t\t// Update datetime cache after tickets cache is updated.\n\t\t\tupdateDatetimeCache({ cache, datetimes, datetime: { ...datetime, isTrashed: true }, action });\n\t\t},\n\t\t[dropRelations, removeRelation, updateDatetimeCache]\n\t);\n\n\treturn onDeleteDatetime;\n};\n\nexport default useOnDeleteDatetime;\n","import { useCallback } from 'react';\n\nimport { useRelations } from '@eventespresso/services';\nimport { getGuids, hasTempId } from '@eventespresso/predicates';\nimport updatePriceCache from './updatePriceCache';\nimport useUpdateTicketCache from './useUpdateTicketCache';\nimport type { TicketMutationCallbackFn, TicketMutationCallbackFnArgs } from '../types';\n\nconst useOnDeleteTicket = (): TicketMutationCallbackFn => {\n\tconst { dropRelations, removeRelation } = useRelations();\n\n\tconst updateTicketCache = useUpdateTicketCache();\n\n\tconst onDeleteTicket = useCallback(\n\t\t({ cache, tickets, ticket, deletePermanently }: TicketMutationCallbackFnArgs): void => {\n\t\t\tconst action = deletePermanently ? 'remove' : 'update';\n\t\t\tif (!hasTempId(ticket) && deletePermanently) {\n\t\t\t\tconst { nodes = [] } = tickets;\n\t\t\t\tconst ticketIn = getGuids(nodes);\n\t\t\t\tconst { id: ticketId } = ticket;\n\n\t\t\t\t// Update prices cache for the changed tickets,\n\t\t\t\t// to avoid refetching of prices.\n\t\t\t\tupdatePriceCache({ cache, ticketIn, ticketId, action });\n\n\t\t\t\t// Remove the ticket from all datetime relations\n\t\t\t\tremoveRelation({\n\t\t\t\t\tentity: 'tickets',\n\t\t\t\t\tentityId: ticketId,\n\t\t\t\t\trelation: 'datetimes',\n\t\t\t\t});\n\t\t\t\t// Remove the ticket from all price relations\n\t\t\t\tremoveRelation({\n\t\t\t\t\tentity: 'tickets',\n\t\t\t\t\tentityId: ticketId,\n\t\t\t\t\trelation: 'prices',\n\t\t\t\t});\n\t\t\t\t// Drop all the relations for the ticket\n\t\t\t\tdropRelations({\n\t\t\t\t\tentity: 'tickets',\n\t\t\t\t\tentityId: ticketId,\n\t\t\t\t});\n\t\t\t}\n\t\t\t// Update ticket cache after price cache is updated.\n\t\t\tupdateTicketCache({ cache, tickets, ticket: { ...ticket, isTrashed: true }, action });\n\t\t},\n\t\t[dropRelations, removeRelation, updateTicketCache]\n\t);\n\n\treturn onDeleteTicket;\n};\n\nexport default useOnDeleteTicket;\n","import { assocPath, pathOr, uniqBy, sortBy, identity } from 'ramda';\n\nimport type { CacheUpdaterFnArgs } from '../types';\nimport { DEFAULT_PRICE_LIST_DATA, GET_PRICES } from '../../queries';\nimport type { Price, PricesList } from '../../types';\nimport type { CacheQueryOptions, WriteQueryOptions } from '@eventespresso/data';\nimport { entityDbId } from '@eventespresso/predicates';\n\nconst updatePriceCache = ({ cache, prices = null, ticketIn, ticketId, action }: CacheUpdaterFnArgs): void => {\n\tconst queryOptions: CacheQueryOptions = {\n\t\tquery: GET_PRICES,\n\t\tvariables: {\n\t\t\twhere: {\n\t\t\t\tticketIn: sortBy(identity, ticketIn),\n\t\t\t\tincludeDefaultPrices: true,\n\t\t\t},\n\t\t},\n\t};\n\tlet data: PricesList;\n\t// Read the existing data from cache.\n\ttry {\n\t\tdata = cache.readQuery(queryOptions);\n\t} catch (error) {\n\t\t// do nothing with the error\n\t}\n\n\t// if there is no data, make sure GQL type is properly set.\n\tif (!data?.espressoPrices) {\n\t\tdata = {\n\t\t\tespressoPrices: DEFAULT_PRICE_LIST_DATA,\n\t\t};\n\t}\n\n\tlet newTicketIn: typeof ticketIn;\n\n\tswitch (action) {\n\t\tcase 'add':\n\t\t\tnewTicketIn = [...ticketIn, ticketId];\n\t\t\tbreak;\n\t\tcase 'remove':\n\t\t\tnewTicketIn = ticketIn.filter((id) => id !== ticketId);\n\t\t\tbreak;\n\t\tdefault:\n\t\t\tnewTicketIn = ticketIn;\n\t\t\tbreak;\n\t}\n\n\tconst priceNodes = prices?.nodes || [];\n\tconst pathToNodes = ['espressoPrices', 'nodes'];\n\n\tif (action === 'add' && priceNodes.length) {\n\t\tconst existingPrices = pathOr([], pathToNodes, data);\n\t\t// make sure that default prices are not repeated\n\t\tconst newPrices = uniqBy(entityDbId, [...existingPrices, ...priceNodes]);\n\t\tdata = assocPath(pathToNodes, newPrices, data);\n\t}\n\tconst nodes = pathOr([], pathToNodes, data);\n\t// if there are no prices\n\tif (!nodes.length) {\n\t\treturn;\n\t}\n\n\t// write the data to cache without\n\t// mutating the cache directly\n\tconst writeOptions: WriteQueryOptions = {\n\t\tquery: GET_PRICES,\n\t\tdata,\n\t\tvariables: {\n\t\t\twhere: {\n\t\t\t\tticketIn: sortBy(identity, newTicketIn),\n\t\t\t\tincludeDefaultPrices: true,\n\t\t\t},\n\t\t},\n\t};\n\tcache.writeQuery(writeOptions);\n};\n\nexport default updatePriceCache;\n","import { useCallback, useState, useMemo, useEffect } from 'react';\nimport { clone } from 'ramda';\nimport type { MutationResult } from '@apollo/client';\n\nimport { __ } from '@eventespresso/i18n';\nimport { gql, useMutation } from '@eventespresso/data';\nimport { useSystemNotifications } from '@eventespresso/toaster';\nimport { getGuids } from '@eventespresso/predicates';\nimport type { EntityId } from '@eventespresso/data';\nimport type { Datetime, Ticket } from '../types';\n\ntype Entity = Datetime | Ticket;\n\ninterface ReorderEntitiesProps {\n\tentityType: 'DATETIME' | 'TICKET';\n\tfilteredEntities: Array;\n}\n\ninterface CallbackArgs {\n\tallEntities: Array;\n\tnewIndex: number;\n\toldIndex: number;\n}\n\ntype SortCallback = (args: CallbackArgs) => Array;\n\nconst REORDER_ENTITIES = gql`\n\tmutation REORDER_ENTITIES($input: ReorderEspressoEntitiesInput!) {\n\t\treorderEspressoEntities(input: $input) {\n\t\t\tok\n\t\t}\n\t}\n`;\n\nexport interface ReorderEntities {\n\tallReorderedEntities: Array;\n\tupdateSortOrder: () => Promise;\n\tresult: MutationResult;\n\tsortEntities: SortCallback;\n\tupdateEntityList?: VoidFunction;\n}\n\nexport const useReorderEntities = ({\n\tentityType,\n\tfilteredEntities,\n}: ReorderEntitiesProps): ReorderEntities => {\n\tconst toaster = useSystemNotifications();\n\tconst [allEntityGuids, setAllEntityGuids] = useState>([]);\n\tconst [allReorderedEntities, setAllOrderedEntities] = useState>(filteredEntities);\n\n\tconst [mutate, result] = useMutation(REORDER_ENTITIES);\n\n\tconst updateSortOrder = useCallback(async () => {\n\t\tawait mutate({\n\t\t\tvariables: {\n\t\t\t\tinput: {\n\t\t\t\t\tclientMutationId: 'REORDER_ENTITIES',\n\t\t\t\t\tentityIds: allEntityGuids,\n\t\t\t\t\tentityType,\n\t\t\t\t},\n\t\t\t},\n\t\t});\n\t\ttoaster.success({ message: __('order updated') });\n\t\treturn true;\n\t}, [allEntityGuids, entityType, mutate, toaster]);\n\n\tuseEffect(() => {\n\t\tsetAllOrderedEntities(filteredEntities);\n\t}, [filteredEntities]);\n\n\tconst sortEntities = useCallback>(\n\t\t({ allEntities: allEntitiesList, newIndex, oldIndex }) => {\n\t\t\tif (newIndex === oldIndex || newIndex < 0 || oldIndex < 0) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tconst entityIds = clone(allReorderedEntities.map(({ id }) => id));\n\t\t\tlet allEntities = clone(allEntitiesList);\n\n\t\t\t// remove entity from existing location in filtered list\n\t\t\tconst [removed] = entityIds.splice(oldIndex, 1);\n\n\t\t\t// insert removed entity into new location in same list\n\t\t\tentityIds.splice(newIndex, 0, removed);\n\n\t\t\t// now loop thru entities in filtered list\n\t\t\tconst entities = entityIds.map((entityId, index) => {\n\t\t\t\t// grab index of reordered entities in list of all entities\n\t\t\t\tconst indexInAll = allEntities.findIndex((item) => item.id === entityId);\n\t\t\t\t// remove reordered entities from list of all entities\n\t\t\t\tconst [entity] = allEntities.splice(indexInAll, 1);\n\n\t\t\t\t// reset the order property for all entities in filtered list\n\t\t\t\treturn { ...entity, order: index + 1 };\n\t\t\t});\n\n\t\t\t// insert ordered entities at the beginning of the array\n\t\t\t// which means trashed ones will land up at the end\n\t\t\tallEntities = [...entities, ...allEntities];\n\n\t\t\t// but now we need to reset the order properties for ALL entities\n\t\t\tallEntities.map((entity, index) => {\n\t\t\t\t// add 1 so we don't end up with order: 0\n\t\t\t\treturn { ...entity, order: index + 1 };\n\t\t\t});\n\n\t\t\tsetAllOrderedEntities(entities);\n\n\t\t\tsetAllEntityGuids(getGuids(allEntities));\n\n\t\t\treturn allEntities;\n\t\t},\n\t\t[allReorderedEntities]\n\t);\n\n\treturn useMemo(\n\t\t() => ({ allReorderedEntities, updateSortOrder, result, sortEntities }),\n\t\t[allReorderedEntities, updateSortOrder, result, sortEntities]\n\t);\n};\n","import { useCallback } from 'react';\n\nimport { useRelations } from '@eventespresso/services';\nimport { hasTempId } from '@eventespresso/predicates';\n\nimport useUpdateTicketCache from './useUpdateTicketCache';\nimport type { TicketMutationCallbackFn, TicketMutationCallbackFnArgs } from '../types';\n\nconst useOnUpdateTicket = (): TicketMutationCallbackFn => {\n\tconst { addRelation, removeRelation, updateRelations } = useRelations();\n\n\tconst updateTicketCache = useUpdateTicketCache();\n\n\tconst onUpdateTicket = useCallback(\n\t\t({ cache, tickets, ticket, datetimeIds, priceIds }: TicketMutationCallbackFnArgs): void => {\n\t\t\tif (hasTempId(ticket)) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tconst ticketId = ticket.id;\n\t\t\t// if related datetimes are passed\n\t\t\t// may be empty array to remove relations\n\t\t\tif (datetimeIds) {\n\t\t\t\t// make sure to remove ticket from\n\t\t\t\t// all existing relations\n\t\t\t\tremoveRelation({\n\t\t\t\t\tentity: 'tickets',\n\t\t\t\t\tentityId: ticketId,\n\t\t\t\t\trelation: 'datetimes',\n\t\t\t\t});\n\n\t\t\t\t// if we have any datetime ids\n\t\t\t\tif (datetimeIds.length) {\n\t\t\t\t\tupdateRelations({\n\t\t\t\t\t\tentity: 'tickets',\n\t\t\t\t\t\tentityId: ticketId,\n\t\t\t\t\t\trelation: 'datetimes',\n\t\t\t\t\t\trelationIds: datetimeIds,\n\t\t\t\t\t});\n\n\t\t\t\t\tdatetimeIds.forEach((entityId: string) => {\n\t\t\t\t\t\taddRelation({\n\t\t\t\t\t\t\tentity: 'datetimes',\n\t\t\t\t\t\t\tentityId,\n\t\t\t\t\t\t\trelation: 'tickets',\n\t\t\t\t\t\t\trelationId: ticketId,\n\t\t\t\t\t\t});\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// if related prices are passed\n\t\t\t// may be empty array to remove relations\n\t\t\tif (priceIds) {\n\t\t\t\t// make sure to remove ticket from\n\t\t\t\t// all existing relations\n\t\t\t\tremoveRelation({\n\t\t\t\t\tentity: 'tickets',\n\t\t\t\t\tentityId: ticketId,\n\t\t\t\t\trelation: 'prices',\n\t\t\t\t});\n\n\t\t\t\t// if we have any price ids\n\t\t\t\tif (priceIds.length) {\n\t\t\t\t\tupdateRelations({\n\t\t\t\t\t\tentity: 'tickets',\n\t\t\t\t\t\tentityId: ticketId,\n\t\t\t\t\t\trelation: 'prices',\n\t\t\t\t\t\trelationIds: priceIds,\n\t\t\t\t\t});\n\n\t\t\t\t\tpriceIds.forEach((entityId: string) => {\n\t\t\t\t\t\taddRelation({\n\t\t\t\t\t\t\tentity: 'prices',\n\t\t\t\t\t\t\tentityId,\n\t\t\t\t\t\t\trelation: 'tickets',\n\t\t\t\t\t\t\trelationId: ticketId,\n\t\t\t\t\t\t});\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (cache && tickets) {\n\t\t\t\t// Update ticket cache.\n\t\t\t\tupdateTicketCache({ cache, tickets, ticket, action: 'update' });\n\t\t\t}\n\t\t},\n\t\t[addRelation, removeRelation, updateRelations, updateTicketCache]\n\t);\n\n\treturn onUpdateTicket;\n};\n\nexport default useOnUpdateTicket;\n","import { useCallback } from 'react';\nimport * as R from 'ramda';\n\nimport { useRelations } from '@eventespresso/services';\nimport { MutationType, InternalRefetchQueriesInclude } from '@eventespresso/data';\n\nimport { GET_DATETIME } from '../../queries';\nimport { TicketCommonInput } from './types';\n\ntype AffectedDatesQueries = (args: {\n\tinput: TicketCommonInput;\n\tmutationType?: MutationType;\n}) => InternalRefetchQueriesInclude;\n\n/**\n * Returns the queries of the affected dates as a result of ticket mutations.\n */\nconst useAffectedDatesQueries = (): AffectedDatesQueries => {\n\tconst { getRelations } = useRelations();\n\n\treturn useCallback(\n\t\t({ input, mutationType = MutationType.Update }) => {\n\t\t\t// if we have an id and related datetimes or if it's a delete mutation\n\t\t\tif ((input.id && input.datetimes) || mutationType === MutationType.Delete) {\n\t\t\t\tconst oldDatetimeIds = getRelations({\n\t\t\t\t\tentity: 'tickets',\n\t\t\t\t\tentityId: input.id,\n\t\t\t\t\trelation: 'datetimes',\n\t\t\t\t});\n\n\t\t\t\t// These are the datetime ids which were removed or added for the ticket.\n\t\t\t\t// It removes the ids that were present before as well as afterwards.\n\t\t\t\tconst affectedDatetimeIds = R.difference(\n\t\t\t\t\tR.union(oldDatetimeIds, input.datetimes || []),\n\t\t\t\t\tR.intersection(oldDatetimeIds, input.datetimes || [])\n\t\t\t\t);\n\n\t\t\t\treturn affectedDatetimeIds.map((id) => ({\n\t\t\t\t\tquery: GET_DATETIME,\n\t\t\t\t\tvariables: { id },\n\t\t\t\t}));\n\t\t\t}\n\t\t},\n\t\t[getRelations]\n\t);\n};\n\nexport default useAffectedDatesQueries;\n","function _has(prop, obj) {\n return Object.prototype.hasOwnProperty.call(obj, prop);\n}\n\nmodule.exports = _has;","/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * The base implementation of `_.has` without support for deep paths.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {Array|string} key The key to check.\n * @returns {boolean} Returns `true` if `key` exists, else `false`.\n */\nfunction baseHas(object, key) {\n return object != null && hasOwnProperty.call(object, key);\n}\n\nmodule.exports = baseHas;\n","var Symbol = require('./_Symbol');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar nativeObjectToString = objectProto.toString;\n\n/** Built-in value references. */\nvar symToStringTag = Symbol ? Symbol.toStringTag : undefined;\n\n/**\n * A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the raw `toStringTag`.\n */\nfunction getRawTag(value) {\n var isOwn = hasOwnProperty.call(value, symToStringTag),\n tag = value[symToStringTag];\n\n try {\n value[symToStringTag] = undefined;\n var unmasked = true;\n } catch (e) {}\n\n var result = nativeObjectToString.call(value);\n if (unmasked) {\n if (isOwn) {\n value[symToStringTag] = tag;\n } else {\n delete value[symToStringTag];\n }\n }\n return result;\n}\n\nmodule.exports = getRawTag;\n","/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar nativeObjectToString = objectProto.toString;\n\n/**\n * Converts `value` to a string using `Object.prototype.toString`.\n *\n * @private\n * @param {*} value The value to convert.\n * @returns {string} Returns the converted string.\n */\nfunction objectToString(value) {\n return nativeObjectToString.call(value);\n}\n\nmodule.exports = objectToString;\n","var memoizeCapped = require('./_memoizeCapped');\n\n/** Used to match property names within property paths. */\nvar rePropName = /[^.[\\]]+|\\[(?:(-?\\d+(?:\\.\\d+)?)|([\"'])((?:(?!\\2)[^\\\\]|\\\\.)*?)\\2)\\]|(?=(?:\\.|\\[\\])(?:\\.|\\[\\]|$))/g;\n\n/** Used to match backslashes in property paths. */\nvar reEscapeChar = /\\\\(\\\\)?/g;\n\n/**\n * Converts `string` to a property path array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the property path array.\n */\nvar stringToPath = memoizeCapped(function(string) {\n var result = [];\n if (string.charCodeAt(0) === 46 /* . */) {\n result.push('');\n }\n string.replace(rePropName, function(match, number, quote, subString) {\n result.push(quote ? subString.replace(reEscapeChar, '$1') : (number || match));\n });\n return result;\n});\n\nmodule.exports = stringToPath;\n","var memoize = require('./memoize');\n\n/** Used as the maximum memoize cache size. */\nvar MAX_MEMOIZE_SIZE = 500;\n\n/**\n * A specialized version of `_.memoize` which clears the memoized function's\n * cache when it exceeds `MAX_MEMOIZE_SIZE`.\n *\n * @private\n * @param {Function} func The function to have its output memoized.\n * @returns {Function} Returns the new memoized function.\n */\nfunction memoizeCapped(func) {\n var result = memoize(func, function(key) {\n if (cache.size === MAX_MEMOIZE_SIZE) {\n cache.clear();\n }\n return key;\n });\n\n var cache = result.cache;\n return result;\n}\n\nmodule.exports = memoizeCapped;\n","var MapCache = require('./_MapCache');\n\n/** Error message constants. */\nvar FUNC_ERROR_TEXT = 'Expected a function';\n\n/**\n * Creates a function that memoizes the result of `func`. If `resolver` is\n * provided, it determines the cache key for storing the result based on the\n * arguments provided to the memoized function. By default, the first argument\n * provided to the memoized function is used as the map cache key. The `func`\n * is invoked with the `this` binding of the memoized function.\n *\n * **Note:** The cache is exposed as the `cache` property on the memoized\n * function. Its creation may be customized by replacing the `_.memoize.Cache`\n * constructor with one whose instances implement the\n * [`Map`](http://ecma-international.org/ecma-262/7.0/#sec-properties-of-the-map-prototype-object)\n * method interface of `clear`, `delete`, `get`, `has`, and `set`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Function\n * @param {Function} func The function to have its output memoized.\n * @param {Function} [resolver] The function to resolve the cache key.\n * @returns {Function} Returns the new memoized function.\n * @example\n *\n * var object = { 'a': 1, 'b': 2 };\n * var other = { 'c': 3, 'd': 4 };\n *\n * var values = _.memoize(_.values);\n * values(object);\n * // => [1, 2]\n *\n * values(other);\n * // => [3, 4]\n *\n * object.a = 2;\n * values(object);\n * // => [1, 2]\n *\n * // Modify the result cache.\n * values.cache.set(object, ['a', 'b']);\n * values(object);\n * // => ['a', 'b']\n *\n * // Replace `_.memoize.Cache`.\n * _.memoize.Cache = WeakMap;\n */\nfunction memoize(func, resolver) {\n if (typeof func != 'function' || (resolver != null && typeof resolver != 'function')) {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n var memoized = function() {\n var args = arguments,\n key = resolver ? resolver.apply(this, args) : args[0],\n cache = memoized.cache;\n\n if (cache.has(key)) {\n return cache.get(key);\n }\n var result = func.apply(this, args);\n memoized.cache = cache.set(key, result) || cache;\n return result;\n };\n memoized.cache = new (memoize.Cache || MapCache);\n return memoized;\n}\n\n// Expose `MapCache`.\nmemoize.Cache = MapCache;\n\nmodule.exports = memoize;\n","var Hash = require('./_Hash'),\n ListCache = require('./_ListCache'),\n Map = require('./_Map');\n\n/**\n * Removes all key-value entries from the map.\n *\n * @private\n * @name clear\n * @memberOf MapCache\n */\nfunction mapCacheClear() {\n this.size = 0;\n this.__data__ = {\n 'hash': new Hash,\n 'map': new (Map || ListCache),\n 'string': new Hash\n };\n}\n\nmodule.exports = mapCacheClear;\n","var hashClear = require('./_hashClear'),\n hashDelete = require('./_hashDelete'),\n hashGet = require('./_hashGet'),\n hashHas = require('./_hashHas'),\n hashSet = require('./_hashSet');\n\n/**\n * Creates a hash object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction Hash(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `Hash`.\nHash.prototype.clear = hashClear;\nHash.prototype['delete'] = hashDelete;\nHash.prototype.get = hashGet;\nHash.prototype.has = hashHas;\nHash.prototype.set = hashSet;\n\nmodule.exports = Hash;\n","var nativeCreate = require('./_nativeCreate');\n\n/**\n * Removes all key-value entries from the hash.\n *\n * @private\n * @name clear\n * @memberOf Hash\n */\nfunction hashClear() {\n this.__data__ = nativeCreate ? nativeCreate(null) : {};\n this.size = 0;\n}\n\nmodule.exports = hashClear;\n","var isFunction = require('./isFunction'),\n isMasked = require('./_isMasked'),\n isObject = require('./isObject'),\n toSource = require('./_toSource');\n\n/**\n * Used to match `RegExp`\n * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns).\n */\nvar reRegExpChar = /[\\\\^$.*+?()[\\]{}|]/g;\n\n/** Used to detect host constructors (Safari). */\nvar reIsHostCtor = /^\\[object .+?Constructor\\]$/;\n\n/** Used for built-in method references. */\nvar funcProto = Function.prototype,\n objectProto = Object.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Used to detect if a method is native. */\nvar reIsNative = RegExp('^' +\n funcToString.call(hasOwnProperty).replace(reRegExpChar, '\\\\$&')\n .replace(/hasOwnProperty|(function).*?(?=\\\\\\()| for .+?(?=\\\\\\])/g, '$1.*?') + '$'\n);\n\n/**\n * The base implementation of `_.isNative` without bad shim checks.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a native function,\n * else `false`.\n */\nfunction baseIsNative(value) {\n if (!isObject(value) || isMasked(value)) {\n return false;\n }\n var pattern = isFunction(value) ? reIsNative : reIsHostCtor;\n return pattern.test(toSource(value));\n}\n\nmodule.exports = baseIsNative;\n","var coreJsData = require('./_coreJsData');\n\n/** Used to detect methods masquerading as native. */\nvar maskSrcKey = (function() {\n var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || '');\n return uid ? ('Symbol(src)_1.' + uid) : '';\n}());\n\n/**\n * Checks if `func` has its source masked.\n *\n * @private\n * @param {Function} func The function to check.\n * @returns {boolean} Returns `true` if `func` is masked, else `false`.\n */\nfunction isMasked(func) {\n return !!maskSrcKey && (maskSrcKey in func);\n}\n\nmodule.exports = isMasked;\n","var root = require('./_root');\n\n/** Used to detect overreaching core-js shims. */\nvar coreJsData = root['__core-js_shared__'];\n\nmodule.exports = coreJsData;\n","/**\n * Gets the value at `key` of `object`.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {string} key The key of the property to get.\n * @returns {*} Returns the property value.\n */\nfunction getValue(object, key) {\n return object == null ? undefined : object[key];\n}\n\nmodule.exports = getValue;\n","/**\n * Removes `key` and its value from the hash.\n *\n * @private\n * @name delete\n * @memberOf Hash\n * @param {Object} hash The hash to modify.\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction hashDelete(key) {\n var result = this.has(key) && delete this.__data__[key];\n this.size -= result ? 1 : 0;\n return result;\n}\n\nmodule.exports = hashDelete;\n","var nativeCreate = require('./_nativeCreate');\n\n/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Gets the hash value for `key`.\n *\n * @private\n * @name get\n * @memberOf Hash\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction hashGet(key) {\n var data = this.__data__;\n if (nativeCreate) {\n var result = data[key];\n return result === HASH_UNDEFINED ? undefined : result;\n }\n return hasOwnProperty.call(data, key) ? data[key] : undefined;\n}\n\nmodule.exports = hashGet;\n","var nativeCreate = require('./_nativeCreate');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Checks if a hash value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Hash\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction hashHas(key) {\n var data = this.__data__;\n return nativeCreate ? (data[key] !== undefined) : hasOwnProperty.call(data, key);\n}\n\nmodule.exports = hashHas;\n","var nativeCreate = require('./_nativeCreate');\n\n/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/**\n * Sets the hash `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Hash\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the hash instance.\n */\nfunction hashSet(key, value) {\n var data = this.__data__;\n this.size += this.has(key) ? 0 : 1;\n data[key] = (nativeCreate && value === undefined) ? HASH_UNDEFINED : value;\n return this;\n}\n\nmodule.exports = hashSet;\n","/**\n * Removes all key-value entries from the list cache.\n *\n * @private\n * @name clear\n * @memberOf ListCache\n */\nfunction listCacheClear() {\n this.__data__ = [];\n this.size = 0;\n}\n\nmodule.exports = listCacheClear;\n","var assocIndexOf = require('./_assocIndexOf');\n\n/** Used for built-in method references. */\nvar arrayProto = Array.prototype;\n\n/** Built-in value references. */\nvar splice = arrayProto.splice;\n\n/**\n * Removes `key` and its value from the list cache.\n *\n * @private\n * @name delete\n * @memberOf ListCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction listCacheDelete(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n return false;\n }\n var lastIndex = data.length - 1;\n if (index == lastIndex) {\n data.pop();\n } else {\n splice.call(data, index, 1);\n }\n --this.size;\n return true;\n}\n\nmodule.exports = listCacheDelete;\n","var assocIndexOf = require('./_assocIndexOf');\n\n/**\n * Gets the list cache value for `key`.\n *\n * @private\n * @name get\n * @memberOf ListCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction listCacheGet(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n return index < 0 ? undefined : data[index][1];\n}\n\nmodule.exports = listCacheGet;\n","var assocIndexOf = require('./_assocIndexOf');\n\n/**\n * Checks if a list cache value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf ListCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction listCacheHas(key) {\n return assocIndexOf(this.__data__, key) > -1;\n}\n\nmodule.exports = listCacheHas;\n","var assocIndexOf = require('./_assocIndexOf');\n\n/**\n * Sets the list cache `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf ListCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the list cache instance.\n */\nfunction listCacheSet(key, value) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n ++this.size;\n data.push([key, value]);\n } else {\n data[index][1] = value;\n }\n return this;\n}\n\nmodule.exports = listCacheSet;\n","var getMapData = require('./_getMapData');\n\n/**\n * Removes `key` and its value from the map.\n *\n * @private\n * @name delete\n * @memberOf MapCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction mapCacheDelete(key) {\n var result = getMapData(this, key)['delete'](key);\n this.size -= result ? 1 : 0;\n return result;\n}\n\nmodule.exports = mapCacheDelete;\n","/**\n * Checks if `value` is suitable for use as unique object key.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is suitable, else `false`.\n */\nfunction isKeyable(value) {\n var type = typeof value;\n return (type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean')\n ? (value !== '__proto__')\n : (value === null);\n}\n\nmodule.exports = isKeyable;\n","var getMapData = require('./_getMapData');\n\n/**\n * Gets the map value for `key`.\n *\n * @private\n * @name get\n * @memberOf MapCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction mapCacheGet(key) {\n return getMapData(this, key).get(key);\n}\n\nmodule.exports = mapCacheGet;\n","var getMapData = require('./_getMapData');\n\n/**\n * Checks if a map value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf MapCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction mapCacheHas(key) {\n return getMapData(this, key).has(key);\n}\n\nmodule.exports = mapCacheHas;\n","var getMapData = require('./_getMapData');\n\n/**\n * Sets the map `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf MapCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the map cache instance.\n */\nfunction mapCacheSet(key, value) {\n var data = getMapData(this, key),\n size = data.size;\n\n data.set(key, value);\n this.size += data.size == size ? 0 : 1;\n return this;\n}\n\nmodule.exports = mapCacheSet;\n","var Symbol = require('./_Symbol'),\n arrayMap = require('./_arrayMap'),\n isArray = require('./isArray'),\n isSymbol = require('./isSymbol');\n\n/** Used as references for various `Number` constants. */\nvar INFINITY = 1 / 0;\n\n/** Used to convert symbols to primitives and strings. */\nvar symbolProto = Symbol ? Symbol.prototype : undefined,\n symbolToString = symbolProto ? symbolProto.toString : undefined;\n\n/**\n * The base implementation of `_.toString` which doesn't convert nullish\n * values to empty strings.\n *\n * @private\n * @param {*} value The value to process.\n * @returns {string} Returns the string.\n */\nfunction baseToString(value) {\n // Exit early for strings to avoid a performance hit in some environments.\n if (typeof value == 'string') {\n return value;\n }\n if (isArray(value)) {\n // Recursively convert values (susceptible to call stack limits).\n return arrayMap(value, baseToString) + '';\n }\n if (isSymbol(value)) {\n return symbolToString ? symbolToString.call(value) : '';\n }\n var result = (value + '');\n return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;\n}\n\nmodule.exports = baseToString;\n","/**\n * A specialized version of `_.map` for arrays without support for iteratee\n * shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns the new mapped array.\n */\nfunction arrayMap(array, iteratee) {\n var index = -1,\n length = array == null ? 0 : array.length,\n result = Array(length);\n\n while (++index < length) {\n result[index] = iteratee(array[index], index, array);\n }\n return result;\n}\n\nmodule.exports = arrayMap;\n","var baseGetTag = require('./_baseGetTag'),\n isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]';\n\n/**\n * The base implementation of `_.isArguments`.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\n */\nfunction baseIsArguments(value) {\n return isObjectLike(value) && baseGetTag(value) == argsTag;\n}\n\nmodule.exports = baseIsArguments;\n","var getNative = require('./_getNative');\n\nvar defineProperty = (function() {\n try {\n var func = getNative(Object, 'defineProperty');\n func({}, '', {});\n return func;\n } catch (e) {}\n}());\n\nmodule.exports = defineProperty;\n","var createBaseFor = require('./_createBaseFor');\n\n/**\n * The base implementation of `baseForOwn` which iterates over `object`\n * properties returned by `keysFunc` and invokes `iteratee` for each property.\n * Iteratee functions may exit iteration early by explicitly returning `false`.\n *\n * @private\n * @param {Object} object The object to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @param {Function} keysFunc The function to get the keys of `object`.\n * @returns {Object} Returns `object`.\n */\nvar baseFor = createBaseFor();\n\nmodule.exports = baseFor;\n","/**\n * Creates a base function for methods like `_.forIn` and `_.forOwn`.\n *\n * @private\n * @param {boolean} [fromRight] Specify iterating from right to left.\n * @returns {Function} Returns the new base function.\n */\nfunction createBaseFor(fromRight) {\n return function(object, iteratee, keysFunc) {\n var index = -1,\n iterable = Object(object),\n props = keysFunc(object),\n length = props.length;\n\n while (length--) {\n var key = props[fromRight ? length : ++index];\n if (iteratee(iterable[key], key, iterable) === false) {\n break;\n }\n }\n return object;\n };\n}\n\nmodule.exports = createBaseFor;\n","var baseTimes = require('./_baseTimes'),\n isArguments = require('./isArguments'),\n isArray = require('./isArray'),\n isBuffer = require('./isBuffer'),\n isIndex = require('./_isIndex'),\n isTypedArray = require('./isTypedArray');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Creates an array of the enumerable property names of the array-like `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @param {boolean} inherited Specify returning inherited property names.\n * @returns {Array} Returns the array of property names.\n */\nfunction arrayLikeKeys(value, inherited) {\n var isArr = isArray(value),\n isArg = !isArr && isArguments(value),\n isBuff = !isArr && !isArg && isBuffer(value),\n isType = !isArr && !isArg && !isBuff && isTypedArray(value),\n skipIndexes = isArr || isArg || isBuff || isType,\n result = skipIndexes ? baseTimes(value.length, String) : [],\n length = result.length;\n\n for (var key in value) {\n if ((inherited || hasOwnProperty.call(value, key)) &&\n !(skipIndexes && (\n // Safari 9 has enumerable `arguments.length` in strict mode.\n key == 'length' ||\n // Node.js 0.10 has enumerable non-index properties on buffers.\n (isBuff && (key == 'offset' || key == 'parent')) ||\n // PhantomJS 2 has enumerable non-index properties on typed arrays.\n (isType && (key == 'buffer' || key == 'byteLength' || key == 'byteOffset')) ||\n // Skip index properties.\n isIndex(key, length)\n ))) {\n result.push(key);\n }\n }\n return result;\n}\n\nmodule.exports = arrayLikeKeys;\n","/**\n * The base implementation of `_.times` without support for iteratee shorthands\n * or max array length checks.\n *\n * @private\n * @param {number} n The number of times to invoke `iteratee`.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns the array of results.\n */\nfunction baseTimes(n, iteratee) {\n var index = -1,\n result = Array(n);\n\n while (++index < n) {\n result[index] = iteratee(index);\n }\n return result;\n}\n\nmodule.exports = baseTimes;\n","/**\n * This method returns `false`.\n *\n * @static\n * @memberOf _\n * @since 4.13.0\n * @category Util\n * @returns {boolean} Returns `false`.\n * @example\n *\n * _.times(2, _.stubFalse);\n * // => [false, false]\n */\nfunction stubFalse() {\n return false;\n}\n\nmodule.exports = stubFalse;\n","var baseGetTag = require('./_baseGetTag'),\n isLength = require('./isLength'),\n isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]',\n arrayTag = '[object Array]',\n boolTag = '[object Boolean]',\n dateTag = '[object Date]',\n errorTag = '[object Error]',\n funcTag = '[object Function]',\n mapTag = '[object Map]',\n numberTag = '[object Number]',\n objectTag = '[object Object]',\n regexpTag = '[object RegExp]',\n setTag = '[object Set]',\n stringTag = '[object String]',\n weakMapTag = '[object WeakMap]';\n\nvar arrayBufferTag = '[object ArrayBuffer]',\n dataViewTag = '[object DataView]',\n float32Tag = '[object Float32Array]',\n float64Tag = '[object Float64Array]',\n int8Tag = '[object Int8Array]',\n int16Tag = '[object Int16Array]',\n int32Tag = '[object Int32Array]',\n uint8Tag = '[object Uint8Array]',\n uint8ClampedTag = '[object Uint8ClampedArray]',\n uint16Tag = '[object Uint16Array]',\n uint32Tag = '[object Uint32Array]';\n\n/** Used to identify `toStringTag` values of typed arrays. */\nvar typedArrayTags = {};\ntypedArrayTags[float32Tag] = typedArrayTags[float64Tag] =\ntypedArrayTags[int8Tag] = typedArrayTags[int16Tag] =\ntypedArrayTags[int32Tag] = typedArrayTags[uint8Tag] =\ntypedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] =\ntypedArrayTags[uint32Tag] = true;\ntypedArrayTags[argsTag] = typedArrayTags[arrayTag] =\ntypedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] =\ntypedArrayTags[dataViewTag] = typedArrayTags[dateTag] =\ntypedArrayTags[errorTag] = typedArrayTags[funcTag] =\ntypedArrayTags[mapTag] = typedArrayTags[numberTag] =\ntypedArrayTags[objectTag] = typedArrayTags[regexpTag] =\ntypedArrayTags[setTag] = typedArrayTags[stringTag] =\ntypedArrayTags[weakMapTag] = false;\n\n/**\n * The base implementation of `_.isTypedArray` without Node.js optimizations.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n */\nfunction baseIsTypedArray(value) {\n return isObjectLike(value) &&\n isLength(value.length) && !!typedArrayTags[baseGetTag(value)];\n}\n\nmodule.exports = baseIsTypedArray;\n","/**\n * The base implementation of `_.unary` without support for storing metadata.\n *\n * @private\n * @param {Function} func The function to cap arguments for.\n * @returns {Function} Returns the new capped function.\n */\nfunction baseUnary(func) {\n return function(value) {\n return func(value);\n };\n}\n\nmodule.exports = baseUnary;\n","var freeGlobal = require('./_freeGlobal');\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Detect free variable `process` from Node.js. */\nvar freeProcess = moduleExports && freeGlobal.process;\n\n/** Used to access faster Node.js helpers. */\nvar nodeUtil = (function() {\n try {\n // Use `util.types` for Node.js 10+.\n var types = freeModule && freeModule.require && freeModule.require('util').types;\n\n if (types) {\n return types;\n }\n\n // Legacy `process.binding('util')` for Node.js < 10.\n return freeProcess && freeProcess.binding && freeProcess.binding('util');\n } catch (e) {}\n}());\n\nmodule.exports = nodeUtil;\n","var isPrototype = require('./_isPrototype'),\n nativeKeys = require('./_nativeKeys');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * The base implementation of `_.keys` which doesn't treat sparse arrays as dense.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n */\nfunction baseKeys(object) {\n if (!isPrototype(object)) {\n return nativeKeys(object);\n }\n var result = [];\n for (var key in Object(object)) {\n if (hasOwnProperty.call(object, key) && key != 'constructor') {\n result.push(key);\n }\n }\n return result;\n}\n\nmodule.exports = baseKeys;\n","/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Checks if `value` is likely a prototype object.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a prototype, else `false`.\n */\nfunction isPrototype(value) {\n var Ctor = value && value.constructor,\n proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto;\n\n return value === proto;\n}\n\nmodule.exports = isPrototype;\n","var overArg = require('./_overArg');\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeKeys = overArg(Object.keys, Object);\n\nmodule.exports = nativeKeys;\n","/**\n * Creates a unary function that invokes `func` with its argument transformed.\n *\n * @private\n * @param {Function} func The function to wrap.\n * @param {Function} transform The argument transform.\n * @returns {Function} Returns the new function.\n */\nfunction overArg(func, transform) {\n return function(arg) {\n return func(transform(arg));\n };\n}\n\nmodule.exports = overArg;\n","var isFunction = require('./isFunction'),\n isLength = require('./isLength');\n\n/**\n * Checks if `value` is array-like. A value is considered array-like if it's\n * not a function and has a `value.length` that's an integer greater than or\n * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is array-like, else `false`.\n * @example\n *\n * _.isArrayLike([1, 2, 3]);\n * // => true\n *\n * _.isArrayLike(document.body.children);\n * // => true\n *\n * _.isArrayLike('abc');\n * // => true\n *\n * _.isArrayLike(_.noop);\n * // => false\n */\nfunction isArrayLike(value) {\n return value != null && isLength(value.length) && !isFunction(value);\n}\n\nmodule.exports = isArrayLike;\n","var baseIsMatch = require('./_baseIsMatch'),\n getMatchData = require('./_getMatchData'),\n matchesStrictComparable = require('./_matchesStrictComparable');\n\n/**\n * The base implementation of `_.matches` which doesn't clone `source`.\n *\n * @private\n * @param {Object} source The object of property values to match.\n * @returns {Function} Returns the new spec function.\n */\nfunction baseMatches(source) {\n var matchData = getMatchData(source);\n if (matchData.length == 1 && matchData[0][2]) {\n return matchesStrictComparable(matchData[0][0], matchData[0][1]);\n }\n return function(object) {\n return object === source || baseIsMatch(object, source, matchData);\n };\n}\n\nmodule.exports = baseMatches;\n","var Stack = require('./_Stack'),\n baseIsEqual = require('./_baseIsEqual');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/**\n * The base implementation of `_.isMatch` without support for iteratee shorthands.\n *\n * @private\n * @param {Object} object The object to inspect.\n * @param {Object} source The object of property values to match.\n * @param {Array} matchData The property names, values, and compare flags to match.\n * @param {Function} [customizer] The function to customize comparisons.\n * @returns {boolean} Returns `true` if `object` is a match, else `false`.\n */\nfunction baseIsMatch(object, source, matchData, customizer) {\n var index = matchData.length,\n length = index,\n noCustomizer = !customizer;\n\n if (object == null) {\n return !length;\n }\n object = Object(object);\n while (index--) {\n var data = matchData[index];\n if ((noCustomizer && data[2])\n ? data[1] !== object[data[0]]\n : !(data[0] in object)\n ) {\n return false;\n }\n }\n while (++index < length) {\n data = matchData[index];\n var key = data[0],\n objValue = object[key],\n srcValue = data[1];\n\n if (noCustomizer && data[2]) {\n if (objValue === undefined && !(key in object)) {\n return false;\n }\n } else {\n var stack = new Stack;\n if (customizer) {\n var result = customizer(objValue, srcValue, key, object, source, stack);\n }\n if (!(result === undefined\n ? baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG, customizer, stack)\n : result\n )) {\n return false;\n }\n }\n }\n return true;\n}\n\nmodule.exports = baseIsMatch;\n","var ListCache = require('./_ListCache');\n\n/**\n * Removes all key-value entries from the stack.\n *\n * @private\n * @name clear\n * @memberOf Stack\n */\nfunction stackClear() {\n this.__data__ = new ListCache;\n this.size = 0;\n}\n\nmodule.exports = stackClear;\n","/**\n * Removes `key` and its value from the stack.\n *\n * @private\n * @name delete\n * @memberOf Stack\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction stackDelete(key) {\n var data = this.__data__,\n result = data['delete'](key);\n\n this.size = data.size;\n return result;\n}\n\nmodule.exports = stackDelete;\n","/**\n * Gets the stack value for `key`.\n *\n * @private\n * @name get\n * @memberOf Stack\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction stackGet(key) {\n return this.__data__.get(key);\n}\n\nmodule.exports = stackGet;\n","/**\n * Checks if a stack value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Stack\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction stackHas(key) {\n return this.__data__.has(key);\n}\n\nmodule.exports = stackHas;\n","var ListCache = require('./_ListCache'),\n Map = require('./_Map'),\n MapCache = require('./_MapCache');\n\n/** Used as the size to enable large array optimizations. */\nvar LARGE_ARRAY_SIZE = 200;\n\n/**\n * Sets the stack `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Stack\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the stack cache instance.\n */\nfunction stackSet(key, value) {\n var data = this.__data__;\n if (data instanceof ListCache) {\n var pairs = data.__data__;\n if (!Map || (pairs.length < LARGE_ARRAY_SIZE - 1)) {\n pairs.push([key, value]);\n this.size = ++data.size;\n return this;\n }\n data = this.__data__ = new MapCache(pairs);\n }\n data.set(key, value);\n this.size = data.size;\n return this;\n}\n\nmodule.exports = stackSet;\n","var Stack = require('./_Stack'),\n equalArrays = require('./_equalArrays'),\n equalByTag = require('./_equalByTag'),\n equalObjects = require('./_equalObjects'),\n getTag = require('./_getTag'),\n isArray = require('./isArray'),\n isBuffer = require('./isBuffer'),\n isTypedArray = require('./isTypedArray');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1;\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]',\n arrayTag = '[object Array]',\n objectTag = '[object Object]';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * A specialized version of `baseIsEqual` for arrays and objects which performs\n * deep comparisons and tracks traversed objects enabling objects with circular\n * references to be compared.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} [stack] Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction baseIsEqualDeep(object, other, bitmask, customizer, equalFunc, stack) {\n var objIsArr = isArray(object),\n othIsArr = isArray(other),\n objTag = objIsArr ? arrayTag : getTag(object),\n othTag = othIsArr ? arrayTag : getTag(other);\n\n objTag = objTag == argsTag ? objectTag : objTag;\n othTag = othTag == argsTag ? objectTag : othTag;\n\n var objIsObj = objTag == objectTag,\n othIsObj = othTag == objectTag,\n isSameTag = objTag == othTag;\n\n if (isSameTag && isBuffer(object)) {\n if (!isBuffer(other)) {\n return false;\n }\n objIsArr = true;\n objIsObj = false;\n }\n if (isSameTag && !objIsObj) {\n stack || (stack = new Stack);\n return (objIsArr || isTypedArray(object))\n ? equalArrays(object, other, bitmask, customizer, equalFunc, stack)\n : equalByTag(object, other, objTag, bitmask, customizer, equalFunc, stack);\n }\n if (!(bitmask & COMPARE_PARTIAL_FLAG)) {\n var objIsWrapped = objIsObj && hasOwnProperty.call(object, '__wrapped__'),\n othIsWrapped = othIsObj && hasOwnProperty.call(other, '__wrapped__');\n\n if (objIsWrapped || othIsWrapped) {\n var objUnwrapped = objIsWrapped ? object.value() : object,\n othUnwrapped = othIsWrapped ? other.value() : other;\n\n stack || (stack = new Stack);\n return equalFunc(objUnwrapped, othUnwrapped, bitmask, customizer, stack);\n }\n }\n if (!isSameTag) {\n return false;\n }\n stack || (stack = new Stack);\n return equalObjects(object, other, bitmask, customizer, equalFunc, stack);\n}\n\nmodule.exports = baseIsEqualDeep;\n","var MapCache = require('./_MapCache'),\n setCacheAdd = require('./_setCacheAdd'),\n setCacheHas = require('./_setCacheHas');\n\n/**\n *\n * Creates an array cache object to store unique values.\n *\n * @private\n * @constructor\n * @param {Array} [values] The values to cache.\n */\nfunction SetCache(values) {\n var index = -1,\n length = values == null ? 0 : values.length;\n\n this.__data__ = new MapCache;\n while (++index < length) {\n this.add(values[index]);\n }\n}\n\n// Add methods to `SetCache`.\nSetCache.prototype.add = SetCache.prototype.push = setCacheAdd;\nSetCache.prototype.has = setCacheHas;\n\nmodule.exports = SetCache;\n","/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/**\n * Adds `value` to the array cache.\n *\n * @private\n * @name add\n * @memberOf SetCache\n * @alias push\n * @param {*} value The value to cache.\n * @returns {Object} Returns the cache instance.\n */\nfunction setCacheAdd(value) {\n this.__data__.set(value, HASH_UNDEFINED);\n return this;\n}\n\nmodule.exports = setCacheAdd;\n","/**\n * Checks if `value` is in the array cache.\n *\n * @private\n * @name has\n * @memberOf SetCache\n * @param {*} value The value to search for.\n * @returns {number} Returns `true` if `value` is found, else `false`.\n */\nfunction setCacheHas(value) {\n return this.__data__.has(value);\n}\n\nmodule.exports = setCacheHas;\n","/**\n * A specialized version of `_.some` for arrays without support for iteratee\n * shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {boolean} Returns `true` if any element passes the predicate check,\n * else `false`.\n */\nfunction arraySome(array, predicate) {\n var index = -1,\n length = array == null ? 0 : array.length;\n\n while (++index < length) {\n if (predicate(array[index], index, array)) {\n return true;\n }\n }\n return false;\n}\n\nmodule.exports = arraySome;\n","/**\n * Checks if a `cache` value for `key` exists.\n *\n * @private\n * @param {Object} cache The cache to query.\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction cacheHas(cache, key) {\n return cache.has(key);\n}\n\nmodule.exports = cacheHas;\n","var Symbol = require('./_Symbol'),\n Uint8Array = require('./_Uint8Array'),\n eq = require('./eq'),\n equalArrays = require('./_equalArrays'),\n mapToArray = require('./_mapToArray'),\n setToArray = require('./_setToArray');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/** `Object#toString` result references. */\nvar boolTag = '[object Boolean]',\n dateTag = '[object Date]',\n errorTag = '[object Error]',\n mapTag = '[object Map]',\n numberTag = '[object Number]',\n regexpTag = '[object RegExp]',\n setTag = '[object Set]',\n stringTag = '[object String]',\n symbolTag = '[object Symbol]';\n\nvar arrayBufferTag = '[object ArrayBuffer]',\n dataViewTag = '[object DataView]';\n\n/** Used to convert symbols to primitives and strings. */\nvar symbolProto = Symbol ? Symbol.prototype : undefined,\n symbolValueOf = symbolProto ? symbolProto.valueOf : undefined;\n\n/**\n * A specialized version of `baseIsEqualDeep` for comparing objects of\n * the same `toStringTag`.\n *\n * **Note:** This function only supports comparing values with tags of\n * `Boolean`, `Date`, `Error`, `Number`, `RegExp`, or `String`.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {string} tag The `toStringTag` of the objects to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction equalByTag(object, other, tag, bitmask, customizer, equalFunc, stack) {\n switch (tag) {\n case dataViewTag:\n if ((object.byteLength != other.byteLength) ||\n (object.byteOffset != other.byteOffset)) {\n return false;\n }\n object = object.buffer;\n other = other.buffer;\n\n case arrayBufferTag:\n if ((object.byteLength != other.byteLength) ||\n !equalFunc(new Uint8Array(object), new Uint8Array(other))) {\n return false;\n }\n return true;\n\n case boolTag:\n case dateTag:\n case numberTag:\n // Coerce booleans to `1` or `0` and dates to milliseconds.\n // Invalid dates are coerced to `NaN`.\n return eq(+object, +other);\n\n case errorTag:\n return object.name == other.name && object.message == other.message;\n\n case regexpTag:\n case stringTag:\n // Coerce regexes to strings and treat strings, primitives and objects,\n // as equal. See http://www.ecma-international.org/ecma-262/7.0/#sec-regexp.prototype.tostring\n // for more details.\n return object == (other + '');\n\n case mapTag:\n var convert = mapToArray;\n\n case setTag:\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG;\n convert || (convert = setToArray);\n\n if (object.size != other.size && !isPartial) {\n return false;\n }\n // Assume cyclic values are equal.\n var stacked = stack.get(object);\n if (stacked) {\n return stacked == other;\n }\n bitmask |= COMPARE_UNORDERED_FLAG;\n\n // Recursively compare objects (susceptible to call stack limits).\n stack.set(object, other);\n var result = equalArrays(convert(object), convert(other), bitmask, customizer, equalFunc, stack);\n stack['delete'](object);\n return result;\n\n case symbolTag:\n if (symbolValueOf) {\n return symbolValueOf.call(object) == symbolValueOf.call(other);\n }\n }\n return false;\n}\n\nmodule.exports = equalByTag;\n","var root = require('./_root');\n\n/** Built-in value references. */\nvar Uint8Array = root.Uint8Array;\n\nmodule.exports = Uint8Array;\n","/**\n * Converts `map` to its key-value pairs.\n *\n * @private\n * @param {Object} map The map to convert.\n * @returns {Array} Returns the key-value pairs.\n */\nfunction mapToArray(map) {\n var index = -1,\n result = Array(map.size);\n\n map.forEach(function(value, key) {\n result[++index] = [key, value];\n });\n return result;\n}\n\nmodule.exports = mapToArray;\n","/**\n * Converts `set` to an array of its values.\n *\n * @private\n * @param {Object} set The set to convert.\n * @returns {Array} Returns the values.\n */\nfunction setToArray(set) {\n var index = -1,\n result = Array(set.size);\n\n set.forEach(function(value) {\n result[++index] = value;\n });\n return result;\n}\n\nmodule.exports = setToArray;\n","var getAllKeys = require('./_getAllKeys');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1;\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * A specialized version of `baseIsEqualDeep` for objects with support for\n * partial deep comparisons.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction equalObjects(object, other, bitmask, customizer, equalFunc, stack) {\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG,\n objProps = getAllKeys(object),\n objLength = objProps.length,\n othProps = getAllKeys(other),\n othLength = othProps.length;\n\n if (objLength != othLength && !isPartial) {\n return false;\n }\n var index = objLength;\n while (index--) {\n var key = objProps[index];\n if (!(isPartial ? key in other : hasOwnProperty.call(other, key))) {\n return false;\n }\n }\n // Check that cyclic values are equal.\n var objStacked = stack.get(object);\n var othStacked = stack.get(other);\n if (objStacked && othStacked) {\n return objStacked == other && othStacked == object;\n }\n var result = true;\n stack.set(object, other);\n stack.set(other, object);\n\n var skipCtor = isPartial;\n while (++index < objLength) {\n key = objProps[index];\n var objValue = object[key],\n othValue = other[key];\n\n if (customizer) {\n var compared = isPartial\n ? customizer(othValue, objValue, key, other, object, stack)\n : customizer(objValue, othValue, key, object, other, stack);\n }\n // Recursively compare objects (susceptible to call stack limits).\n if (!(compared === undefined\n ? (objValue === othValue || equalFunc(objValue, othValue, bitmask, customizer, stack))\n : compared\n )) {\n result = false;\n break;\n }\n skipCtor || (skipCtor = key == 'constructor');\n }\n if (result && !skipCtor) {\n var objCtor = object.constructor,\n othCtor = other.constructor;\n\n // Non `Object` object instances with different constructors are not equal.\n if (objCtor != othCtor &&\n ('constructor' in object && 'constructor' in other) &&\n !(typeof objCtor == 'function' && objCtor instanceof objCtor &&\n typeof othCtor == 'function' && othCtor instanceof othCtor)) {\n result = false;\n }\n }\n stack['delete'](object);\n stack['delete'](other);\n return result;\n}\n\nmodule.exports = equalObjects;\n","var baseGetAllKeys = require('./_baseGetAllKeys'),\n getSymbols = require('./_getSymbols'),\n keys = require('./keys');\n\n/**\n * Creates an array of own enumerable property names and symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names and symbols.\n */\nfunction getAllKeys(object) {\n return baseGetAllKeys(object, keys, getSymbols);\n}\n\nmodule.exports = getAllKeys;\n","var arrayPush = require('./_arrayPush'),\n isArray = require('./isArray');\n\n/**\n * The base implementation of `getAllKeys` and `getAllKeysIn` which uses\n * `keysFunc` and `symbolsFunc` to get the enumerable property names and\n * symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Function} keysFunc The function to get the keys of `object`.\n * @param {Function} symbolsFunc The function to get the symbols of `object`.\n * @returns {Array} Returns the array of property names and symbols.\n */\nfunction baseGetAllKeys(object, keysFunc, symbolsFunc) {\n var result = keysFunc(object);\n return isArray(object) ? result : arrayPush(result, symbolsFunc(object));\n}\n\nmodule.exports = baseGetAllKeys;\n","/**\n * Appends the elements of `values` to `array`.\n *\n * @private\n * @param {Array} array The array to modify.\n * @param {Array} values The values to append.\n * @returns {Array} Returns `array`.\n */\nfunction arrayPush(array, values) {\n var index = -1,\n length = values.length,\n offset = array.length;\n\n while (++index < length) {\n array[offset + index] = values[index];\n }\n return array;\n}\n\nmodule.exports = arrayPush;\n","var arrayFilter = require('./_arrayFilter'),\n stubArray = require('./stubArray');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Built-in value references. */\nvar propertyIsEnumerable = objectProto.propertyIsEnumerable;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeGetSymbols = Object.getOwnPropertySymbols;\n\n/**\n * Creates an array of the own enumerable symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of symbols.\n */\nvar getSymbols = !nativeGetSymbols ? stubArray : function(object) {\n if (object == null) {\n return [];\n }\n object = Object(object);\n return arrayFilter(nativeGetSymbols(object), function(symbol) {\n return propertyIsEnumerable.call(object, symbol);\n });\n};\n\nmodule.exports = getSymbols;\n","/**\n * A specialized version of `_.filter` for arrays without support for\n * iteratee shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {Array} Returns the new filtered array.\n */\nfunction arrayFilter(array, predicate) {\n var index = -1,\n length = array == null ? 0 : array.length,\n resIndex = 0,\n result = [];\n\n while (++index < length) {\n var value = array[index];\n if (predicate(value, index, array)) {\n result[resIndex++] = value;\n }\n }\n return result;\n}\n\nmodule.exports = arrayFilter;\n","/**\n * This method returns a new empty array.\n *\n * @static\n * @memberOf _\n * @since 4.13.0\n * @category Util\n * @returns {Array} Returns the new empty array.\n * @example\n *\n * var arrays = _.times(2, _.stubArray);\n *\n * console.log(arrays);\n * // => [[], []]\n *\n * console.log(arrays[0] === arrays[1]);\n * // => false\n */\nfunction stubArray() {\n return [];\n}\n\nmodule.exports = stubArray;\n","var DataView = require('./_DataView'),\n Map = require('./_Map'),\n Promise = require('./_Promise'),\n Set = require('./_Set'),\n WeakMap = require('./_WeakMap'),\n baseGetTag = require('./_baseGetTag'),\n toSource = require('./_toSource');\n\n/** `Object#toString` result references. */\nvar mapTag = '[object Map]',\n objectTag = '[object Object]',\n promiseTag = '[object Promise]',\n setTag = '[object Set]',\n weakMapTag = '[object WeakMap]';\n\nvar dataViewTag = '[object DataView]';\n\n/** Used to detect maps, sets, and weakmaps. */\nvar dataViewCtorString = toSource(DataView),\n mapCtorString = toSource(Map),\n promiseCtorString = toSource(Promise),\n setCtorString = toSource(Set),\n weakMapCtorString = toSource(WeakMap);\n\n/**\n * Gets the `toStringTag` of `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\nvar getTag = baseGetTag;\n\n// Fallback for data views, maps, sets, and weak maps in IE 11 and promises in Node.js < 6.\nif ((DataView && getTag(new DataView(new ArrayBuffer(1))) != dataViewTag) ||\n (Map && getTag(new Map) != mapTag) ||\n (Promise && getTag(Promise.resolve()) != promiseTag) ||\n (Set && getTag(new Set) != setTag) ||\n (WeakMap && getTag(new WeakMap) != weakMapTag)) {\n getTag = function(value) {\n var result = baseGetTag(value),\n Ctor = result == objectTag ? value.constructor : undefined,\n ctorString = Ctor ? toSource(Ctor) : '';\n\n if (ctorString) {\n switch (ctorString) {\n case dataViewCtorString: return dataViewTag;\n case mapCtorString: return mapTag;\n case promiseCtorString: return promiseTag;\n case setCtorString: return setTag;\n case weakMapCtorString: return weakMapTag;\n }\n }\n return result;\n };\n}\n\nmodule.exports = getTag;\n","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar DataView = getNative(root, 'DataView');\n\nmodule.exports = DataView;\n","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar Promise = getNative(root, 'Promise');\n\nmodule.exports = Promise;\n","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar Set = getNative(root, 'Set');\n\nmodule.exports = Set;\n","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar WeakMap = getNative(root, 'WeakMap');\n\nmodule.exports = WeakMap;\n","var isStrictComparable = require('./_isStrictComparable'),\n keys = require('./keys');\n\n/**\n * Gets the property names, values, and compare flags of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the match data of `object`.\n */\nfunction getMatchData(object) {\n var result = keys(object),\n length = result.length;\n\n while (length--) {\n var key = result[length],\n value = object[key];\n\n result[length] = [key, value, isStrictComparable(value)];\n }\n return result;\n}\n\nmodule.exports = getMatchData;\n","var baseIsEqual = require('./_baseIsEqual'),\n get = require('./get'),\n hasIn = require('./hasIn'),\n isKey = require('./_isKey'),\n isStrictComparable = require('./_isStrictComparable'),\n matchesStrictComparable = require('./_matchesStrictComparable'),\n toKey = require('./_toKey');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/**\n * The base implementation of `_.matchesProperty` which doesn't clone `srcValue`.\n *\n * @private\n * @param {string} path The path of the property to get.\n * @param {*} srcValue The value to match.\n * @returns {Function} Returns the new spec function.\n */\nfunction baseMatchesProperty(path, srcValue) {\n if (isKey(path) && isStrictComparable(srcValue)) {\n return matchesStrictComparable(toKey(path), srcValue);\n }\n return function(object) {\n var objValue = get(object, path);\n return (objValue === undefined && objValue === srcValue)\n ? hasIn(object, path)\n : baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG);\n };\n}\n\nmodule.exports = baseMatchesProperty;\n","var baseGet = require('./_baseGet');\n\n/**\n * Gets the value at `path` of `object`. If the resolved value is\n * `undefined`, the `defaultValue` is returned in its place.\n *\n * @static\n * @memberOf _\n * @since 3.7.0\n * @category Object\n * @param {Object} object The object to query.\n * @param {Array|string} path The path of the property to get.\n * @param {*} [defaultValue] The value returned for `undefined` resolved values.\n * @returns {*} Returns the resolved value.\n * @example\n *\n * var object = { 'a': [{ 'b': { 'c': 3 } }] };\n *\n * _.get(object, 'a[0].b.c');\n * // => 3\n *\n * _.get(object, ['a', '0', 'b', 'c']);\n * // => 3\n *\n * _.get(object, 'a.b.c', 'default');\n * // => 'default'\n */\nfunction get(object, path, defaultValue) {\n var result = object == null ? undefined : baseGet(object, path);\n return result === undefined ? defaultValue : result;\n}\n\nmodule.exports = get;\n","var baseHasIn = require('./_baseHasIn'),\n hasPath = require('./_hasPath');\n\n/**\n * Checks if `path` is a direct or inherited property of `object`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Object\n * @param {Object} object The object to query.\n * @param {Array|string} path The path to check.\n * @returns {boolean} Returns `true` if `path` exists, else `false`.\n * @example\n *\n * var object = _.create({ 'a': _.create({ 'b': 2 }) });\n *\n * _.hasIn(object, 'a');\n * // => true\n *\n * _.hasIn(object, 'a.b');\n * // => true\n *\n * _.hasIn(object, ['a', 'b']);\n * // => true\n *\n * _.hasIn(object, 'b');\n * // => false\n */\nfunction hasIn(object, path) {\n return object != null && hasPath(object, path, baseHasIn);\n}\n\nmodule.exports = hasIn;\n","/**\n * The base implementation of `_.hasIn` without support for deep paths.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {Array|string} key The key to check.\n * @returns {boolean} Returns `true` if `key` exists, else `false`.\n */\nfunction baseHasIn(object, key) {\n return object != null && key in Object(object);\n}\n\nmodule.exports = baseHasIn;\n","/**\n * This method returns the first argument it receives.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Util\n * @param {*} value Any value.\n * @returns {*} Returns `value`.\n * @example\n *\n * var object = { 'a': 1 };\n *\n * console.log(_.identity(object) === object);\n * // => true\n */\nfunction identity(value) {\n return value;\n}\n\nmodule.exports = identity;\n","var baseProperty = require('./_baseProperty'),\n basePropertyDeep = require('./_basePropertyDeep'),\n isKey = require('./_isKey'),\n toKey = require('./_toKey');\n\n/**\n * Creates a function that returns the value at `path` of a given object.\n *\n * @static\n * @memberOf _\n * @since 2.4.0\n * @category Util\n * @param {Array|string} path The path of the property to get.\n * @returns {Function} Returns the new accessor function.\n * @example\n *\n * var objects = [\n * { 'a': { 'b': 2 } },\n * { 'a': { 'b': 1 } }\n * ];\n *\n * _.map(objects, _.property('a.b'));\n * // => [2, 1]\n *\n * _.map(_.sortBy(objects, _.property(['a', 'b'])), 'a.b');\n * // => [1, 2]\n */\nfunction property(path) {\n return isKey(path) ? baseProperty(toKey(path)) : basePropertyDeep(path);\n}\n\nmodule.exports = property;\n","/**\n * The base implementation of `_.property` without support for deep paths.\n *\n * @private\n * @param {string} key The key of the property to get.\n * @returns {Function} Returns the new accessor function.\n */\nfunction baseProperty(key) {\n return function(object) {\n return object == null ? undefined : object[key];\n };\n}\n\nmodule.exports = baseProperty;\n","var baseGet = require('./_baseGet');\n\n/**\n * A specialized version of `baseProperty` which supports deep paths.\n *\n * @private\n * @param {Array|string} path The path of the property to get.\n * @returns {Function} Returns the new accessor function.\n */\nfunction basePropertyDeep(path) {\n return function(object) {\n return baseGet(object, path);\n };\n}\n\nmodule.exports = basePropertyDeep;\n","/**\n * A specialized version of `_.reduce` for arrays without support for\n * iteratee shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @param {*} [accumulator] The initial value.\n * @param {boolean} [initAccum] Specify using the first element of `array` as\n * the initial value.\n * @returns {*} Returns the accumulated value.\n */\nfunction arrayReduce(array, iteratee, accumulator, initAccum) {\n var index = -1,\n length = array == null ? 0 : array.length;\n\n if (initAccum && length) {\n accumulator = array[++index];\n }\n while (++index < length) {\n accumulator = iteratee(accumulator, array[index], index, array);\n }\n return accumulator;\n}\n\nmodule.exports = arrayReduce;\n","var deburrLetter = require('./_deburrLetter'),\n toString = require('./toString');\n\n/** Used to match Latin Unicode letters (excluding mathematical operators). */\nvar reLatin = /[\\xc0-\\xd6\\xd8-\\xf6\\xf8-\\xff\\u0100-\\u017f]/g;\n\n/** Used to compose unicode character classes. */\nvar rsComboMarksRange = '\\\\u0300-\\\\u036f',\n reComboHalfMarksRange = '\\\\ufe20-\\\\ufe2f',\n rsComboSymbolsRange = '\\\\u20d0-\\\\u20ff',\n rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange;\n\n/** Used to compose unicode capture groups. */\nvar rsCombo = '[' + rsComboRange + ']';\n\n/**\n * Used to match [combining diacritical marks](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks) and\n * [combining diacritical marks for symbols](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks_for_Symbols).\n */\nvar reComboMark = RegExp(rsCombo, 'g');\n\n/**\n * Deburrs `string` by converting\n * [Latin-1 Supplement](https://en.wikipedia.org/wiki/Latin-1_Supplement_(Unicode_block)#Character_table)\n * and [Latin Extended-A](https://en.wikipedia.org/wiki/Latin_Extended-A)\n * letters to basic Latin letters and removing\n * [combining diacritical marks](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks).\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to deburr.\n * @returns {string} Returns the deburred string.\n * @example\n *\n * _.deburr('déjà vu');\n * // => 'deja vu'\n */\nfunction deburr(string) {\n string = toString(string);\n return string && string.replace(reLatin, deburrLetter).replace(reComboMark, '');\n}\n\nmodule.exports = deburr;\n","var basePropertyOf = require('./_basePropertyOf');\n\n/** Used to map Latin Unicode letters to basic Latin letters. */\nvar deburredLetters = {\n // Latin-1 Supplement block.\n '\\xc0': 'A', '\\xc1': 'A', '\\xc2': 'A', '\\xc3': 'A', '\\xc4': 'A', '\\xc5': 'A',\n '\\xe0': 'a', '\\xe1': 'a', '\\xe2': 'a', '\\xe3': 'a', '\\xe4': 'a', '\\xe5': 'a',\n '\\xc7': 'C', '\\xe7': 'c',\n '\\xd0': 'D', '\\xf0': 'd',\n '\\xc8': 'E', '\\xc9': 'E', '\\xca': 'E', '\\xcb': 'E',\n '\\xe8': 'e', '\\xe9': 'e', '\\xea': 'e', '\\xeb': 'e',\n '\\xcc': 'I', '\\xcd': 'I', '\\xce': 'I', '\\xcf': 'I',\n '\\xec': 'i', '\\xed': 'i', '\\xee': 'i', '\\xef': 'i',\n '\\xd1': 'N', '\\xf1': 'n',\n '\\xd2': 'O', '\\xd3': 'O', '\\xd4': 'O', '\\xd5': 'O', '\\xd6': 'O', '\\xd8': 'O',\n '\\xf2': 'o', '\\xf3': 'o', '\\xf4': 'o', '\\xf5': 'o', '\\xf6': 'o', '\\xf8': 'o',\n '\\xd9': 'U', '\\xda': 'U', '\\xdb': 'U', '\\xdc': 'U',\n '\\xf9': 'u', '\\xfa': 'u', '\\xfb': 'u', '\\xfc': 'u',\n '\\xdd': 'Y', '\\xfd': 'y', '\\xff': 'y',\n '\\xc6': 'Ae', '\\xe6': 'ae',\n '\\xde': 'Th', '\\xfe': 'th',\n '\\xdf': 'ss',\n // Latin Extended-A block.\n '\\u0100': 'A', '\\u0102': 'A', '\\u0104': 'A',\n '\\u0101': 'a', '\\u0103': 'a', '\\u0105': 'a',\n '\\u0106': 'C', '\\u0108': 'C', '\\u010a': 'C', '\\u010c': 'C',\n '\\u0107': 'c', '\\u0109': 'c', '\\u010b': 'c', '\\u010d': 'c',\n '\\u010e': 'D', '\\u0110': 'D', '\\u010f': 'd', '\\u0111': 'd',\n '\\u0112': 'E', '\\u0114': 'E', '\\u0116': 'E', '\\u0118': 'E', '\\u011a': 'E',\n '\\u0113': 'e', '\\u0115': 'e', '\\u0117': 'e', '\\u0119': 'e', '\\u011b': 'e',\n '\\u011c': 'G', '\\u011e': 'G', '\\u0120': 'G', '\\u0122': 'G',\n '\\u011d': 'g', '\\u011f': 'g', '\\u0121': 'g', '\\u0123': 'g',\n '\\u0124': 'H', '\\u0126': 'H', '\\u0125': 'h', '\\u0127': 'h',\n '\\u0128': 'I', '\\u012a': 'I', '\\u012c': 'I', '\\u012e': 'I', '\\u0130': 'I',\n '\\u0129': 'i', '\\u012b': 'i', '\\u012d': 'i', '\\u012f': 'i', '\\u0131': 'i',\n '\\u0134': 'J', '\\u0135': 'j',\n '\\u0136': 'K', '\\u0137': 'k', '\\u0138': 'k',\n '\\u0139': 'L', '\\u013b': 'L', '\\u013d': 'L', '\\u013f': 'L', '\\u0141': 'L',\n '\\u013a': 'l', '\\u013c': 'l', '\\u013e': 'l', '\\u0140': 'l', '\\u0142': 'l',\n '\\u0143': 'N', '\\u0145': 'N', '\\u0147': 'N', '\\u014a': 'N',\n '\\u0144': 'n', '\\u0146': 'n', '\\u0148': 'n', '\\u014b': 'n',\n '\\u014c': 'O', '\\u014e': 'O', '\\u0150': 'O',\n '\\u014d': 'o', '\\u014f': 'o', '\\u0151': 'o',\n '\\u0154': 'R', '\\u0156': 'R', '\\u0158': 'R',\n '\\u0155': 'r', '\\u0157': 'r', '\\u0159': 'r',\n '\\u015a': 'S', '\\u015c': 'S', '\\u015e': 'S', '\\u0160': 'S',\n '\\u015b': 's', '\\u015d': 's', '\\u015f': 's', '\\u0161': 's',\n '\\u0162': 'T', '\\u0164': 'T', '\\u0166': 'T',\n '\\u0163': 't', '\\u0165': 't', '\\u0167': 't',\n '\\u0168': 'U', '\\u016a': 'U', '\\u016c': 'U', '\\u016e': 'U', '\\u0170': 'U', '\\u0172': 'U',\n '\\u0169': 'u', '\\u016b': 'u', '\\u016d': 'u', '\\u016f': 'u', '\\u0171': 'u', '\\u0173': 'u',\n '\\u0174': 'W', '\\u0175': 'w',\n '\\u0176': 'Y', '\\u0177': 'y', '\\u0178': 'Y',\n '\\u0179': 'Z', '\\u017b': 'Z', '\\u017d': 'Z',\n '\\u017a': 'z', '\\u017c': 'z', '\\u017e': 'z',\n '\\u0132': 'IJ', '\\u0133': 'ij',\n '\\u0152': 'Oe', '\\u0153': 'oe',\n '\\u0149': \"'n\", '\\u017f': 's'\n};\n\n/**\n * Used by `_.deburr` to convert Latin-1 Supplement and Latin Extended-A\n * letters to basic Latin letters.\n *\n * @private\n * @param {string} letter The matched letter to deburr.\n * @returns {string} Returns the deburred letter.\n */\nvar deburrLetter = basePropertyOf(deburredLetters);\n\nmodule.exports = deburrLetter;\n","/**\n * The base implementation of `_.propertyOf` without support for deep paths.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Function} Returns the new accessor function.\n */\nfunction basePropertyOf(object) {\n return function(key) {\n return object == null ? undefined : object[key];\n };\n}\n\nmodule.exports = basePropertyOf;\n","var asciiWords = require('./_asciiWords'),\n hasUnicodeWord = require('./_hasUnicodeWord'),\n toString = require('./toString'),\n unicodeWords = require('./_unicodeWords');\n\n/**\n * Splits `string` into an array of its words.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to inspect.\n * @param {RegExp|string} [pattern] The pattern to match words.\n * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.\n * @returns {Array} Returns the words of `string`.\n * @example\n *\n * _.words('fred, barney, & pebbles');\n * // => ['fred', 'barney', 'pebbles']\n *\n * _.words('fred, barney, & pebbles', /[^, ]+/g);\n * // => ['fred', 'barney', '&', 'pebbles']\n */\nfunction words(string, pattern, guard) {\n string = toString(string);\n pattern = guard ? undefined : pattern;\n\n if (pattern === undefined) {\n return hasUnicodeWord(string) ? unicodeWords(string) : asciiWords(string);\n }\n return string.match(pattern) || [];\n}\n\nmodule.exports = words;\n","/** Used to match words composed of alphanumeric characters. */\nvar reAsciiWord = /[^\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\x7f]+/g;\n\n/**\n * Splits an ASCII `string` into an array of its words.\n *\n * @private\n * @param {string} The string to inspect.\n * @returns {Array} Returns the words of `string`.\n */\nfunction asciiWords(string) {\n return string.match(reAsciiWord) || [];\n}\n\nmodule.exports = asciiWords;\n","/** Used to detect strings that need a more robust regexp to match words. */\nvar reHasUnicodeWord = /[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;\n\n/**\n * Checks if `string` contains a word composed of Unicode symbols.\n *\n * @private\n * @param {string} string The string to inspect.\n * @returns {boolean} Returns `true` if a word is found, else `false`.\n */\nfunction hasUnicodeWord(string) {\n return reHasUnicodeWord.test(string);\n}\n\nmodule.exports = hasUnicodeWord;\n","/** Used to compose unicode character classes. */\nvar rsAstralRange = '\\\\ud800-\\\\udfff',\n rsComboMarksRange = '\\\\u0300-\\\\u036f',\n reComboHalfMarksRange = '\\\\ufe20-\\\\ufe2f',\n rsComboSymbolsRange = '\\\\u20d0-\\\\u20ff',\n rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange,\n rsDingbatRange = '\\\\u2700-\\\\u27bf',\n rsLowerRange = 'a-z\\\\xdf-\\\\xf6\\\\xf8-\\\\xff',\n rsMathOpRange = '\\\\xac\\\\xb1\\\\xd7\\\\xf7',\n rsNonCharRange = '\\\\x00-\\\\x2f\\\\x3a-\\\\x40\\\\x5b-\\\\x60\\\\x7b-\\\\xbf',\n rsPunctuationRange = '\\\\u2000-\\\\u206f',\n rsSpaceRange = ' \\\\t\\\\x0b\\\\f\\\\xa0\\\\ufeff\\\\n\\\\r\\\\u2028\\\\u2029\\\\u1680\\\\u180e\\\\u2000\\\\u2001\\\\u2002\\\\u2003\\\\u2004\\\\u2005\\\\u2006\\\\u2007\\\\u2008\\\\u2009\\\\u200a\\\\u202f\\\\u205f\\\\u3000',\n rsUpperRange = 'A-Z\\\\xc0-\\\\xd6\\\\xd8-\\\\xde',\n rsVarRange = '\\\\ufe0e\\\\ufe0f',\n rsBreakRange = rsMathOpRange + rsNonCharRange + rsPunctuationRange + rsSpaceRange;\n\n/** Used to compose unicode capture groups. */\nvar rsApos = \"['\\u2019]\",\n rsBreak = '[' + rsBreakRange + ']',\n rsCombo = '[' + rsComboRange + ']',\n rsDigits = '\\\\d+',\n rsDingbat = '[' + rsDingbatRange + ']',\n rsLower = '[' + rsLowerRange + ']',\n rsMisc = '[^' + rsAstralRange + rsBreakRange + rsDigits + rsDingbatRange + rsLowerRange + rsUpperRange + ']',\n rsFitz = '\\\\ud83c[\\\\udffb-\\\\udfff]',\n rsModifier = '(?:' + rsCombo + '|' + rsFitz + ')',\n rsNonAstral = '[^' + rsAstralRange + ']',\n rsRegional = '(?:\\\\ud83c[\\\\udde6-\\\\uddff]){2}',\n rsSurrPair = '[\\\\ud800-\\\\udbff][\\\\udc00-\\\\udfff]',\n rsUpper = '[' + rsUpperRange + ']',\n rsZWJ = '\\\\u200d';\n\n/** Used to compose unicode regexes. */\nvar rsMiscLower = '(?:' + rsLower + '|' + rsMisc + ')',\n rsMiscUpper = '(?:' + rsUpper + '|' + rsMisc + ')',\n rsOptContrLower = '(?:' + rsApos + '(?:d|ll|m|re|s|t|ve))?',\n rsOptContrUpper = '(?:' + rsApos + '(?:D|LL|M|RE|S|T|VE))?',\n reOptMod = rsModifier + '?',\n rsOptVar = '[' + rsVarRange + ']?',\n rsOptJoin = '(?:' + rsZWJ + '(?:' + [rsNonAstral, rsRegional, rsSurrPair].join('|') + ')' + rsOptVar + reOptMod + ')*',\n rsOrdLower = '\\\\d*(?:1st|2nd|3rd|(?![123])\\\\dth)(?=\\\\b|[A-Z_])',\n rsOrdUpper = '\\\\d*(?:1ST|2ND|3RD|(?![123])\\\\dTH)(?=\\\\b|[a-z_])',\n rsSeq = rsOptVar + reOptMod + rsOptJoin,\n rsEmoji = '(?:' + [rsDingbat, rsRegional, rsSurrPair].join('|') + ')' + rsSeq;\n\n/** Used to match complex or compound words. */\nvar reUnicodeWord = RegExp([\n rsUpper + '?' + rsLower + '+' + rsOptContrLower + '(?=' + [rsBreak, rsUpper, '$'].join('|') + ')',\n rsMiscUpper + '+' + rsOptContrUpper + '(?=' + [rsBreak, rsUpper + rsMiscLower, '$'].join('|') + ')',\n rsUpper + '?' + rsMiscLower + '+' + rsOptContrLower,\n rsUpper + '+' + rsOptContrUpper,\n rsOrdUpper,\n rsOrdLower,\n rsDigits,\n rsEmoji\n].join('|'), 'g');\n\n/**\n * Splits a Unicode `string` into an array of its words.\n *\n * @private\n * @param {string} The string to inspect.\n * @returns {Array} Returns the words of `string`.\n */\nfunction unicodeWords(string) {\n return string.match(reUnicodeWord) || [];\n}\n\nmodule.exports = unicodeWords;\n","var toString = require('./toString'),\n upperFirst = require('./upperFirst');\n\n/**\n * Converts the first character of `string` to upper case and the remaining\n * to lower case.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to capitalize.\n * @returns {string} Returns the capitalized string.\n * @example\n *\n * _.capitalize('FRED');\n * // => 'Fred'\n */\nfunction capitalize(string) {\n return upperFirst(toString(string).toLowerCase());\n}\n\nmodule.exports = capitalize;\n","var createCaseFirst = require('./_createCaseFirst');\n\n/**\n * Converts the first character of `string` to upper case.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category String\n * @param {string} [string=''] The string to convert.\n * @returns {string} Returns the converted string.\n * @example\n *\n * _.upperFirst('fred');\n * // => 'Fred'\n *\n * _.upperFirst('FRED');\n * // => 'FRED'\n */\nvar upperFirst = createCaseFirst('toUpperCase');\n\nmodule.exports = upperFirst;\n","var castSlice = require('./_castSlice'),\n hasUnicode = require('./_hasUnicode'),\n stringToArray = require('./_stringToArray'),\n toString = require('./toString');\n\n/**\n * Creates a function like `_.lowerFirst`.\n *\n * @private\n * @param {string} methodName The name of the `String` case method to use.\n * @returns {Function} Returns the new case function.\n */\nfunction createCaseFirst(methodName) {\n return function(string) {\n string = toString(string);\n\n var strSymbols = hasUnicode(string)\n ? stringToArray(string)\n : undefined;\n\n var chr = strSymbols\n ? strSymbols[0]\n : string.charAt(0);\n\n var trailing = strSymbols\n ? castSlice(strSymbols, 1).join('')\n : string.slice(1);\n\n return chr[methodName]() + trailing;\n };\n}\n\nmodule.exports = createCaseFirst;\n","var baseSlice = require('./_baseSlice');\n\n/**\n * Casts `array` to a slice if it's needed.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {number} start The start position.\n * @param {number} [end=array.length] The end position.\n * @returns {Array} Returns the cast slice.\n */\nfunction castSlice(array, start, end) {\n var length = array.length;\n end = end === undefined ? length : end;\n return (!start && end >= length) ? array : baseSlice(array, start, end);\n}\n\nmodule.exports = castSlice;\n","/**\n * The base implementation of `_.slice` without an iteratee call guard.\n *\n * @private\n * @param {Array} array The array to slice.\n * @param {number} [start=0] The start position.\n * @param {number} [end=array.length] The end position.\n * @returns {Array} Returns the slice of `array`.\n */\nfunction baseSlice(array, start, end) {\n var index = -1,\n length = array.length;\n\n if (start < 0) {\n start = -start > length ? 0 : (length + start);\n }\n end = end > length ? length : end;\n if (end < 0) {\n end += length;\n }\n length = start > end ? 0 : ((end - start) >>> 0);\n start >>>= 0;\n\n var result = Array(length);\n while (++index < length) {\n result[index] = array[index + start];\n }\n return result;\n}\n\nmodule.exports = baseSlice;\n","var asciiToArray = require('./_asciiToArray'),\n hasUnicode = require('./_hasUnicode'),\n unicodeToArray = require('./_unicodeToArray');\n\n/**\n * Converts `string` to an array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the converted array.\n */\nfunction stringToArray(string) {\n return hasUnicode(string)\n ? unicodeToArray(string)\n : asciiToArray(string);\n}\n\nmodule.exports = stringToArray;\n","/**\n * Converts an ASCII `string` to an array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the converted array.\n */\nfunction asciiToArray(string) {\n return string.split('');\n}\n\nmodule.exports = asciiToArray;\n","/** Used to compose unicode character classes. */\nvar rsAstralRange = '\\\\ud800-\\\\udfff',\n rsComboMarksRange = '\\\\u0300-\\\\u036f',\n reComboHalfMarksRange = '\\\\ufe20-\\\\ufe2f',\n rsComboSymbolsRange = '\\\\u20d0-\\\\u20ff',\n rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange,\n rsVarRange = '\\\\ufe0e\\\\ufe0f';\n\n/** Used to compose unicode capture groups. */\nvar rsAstral = '[' + rsAstralRange + ']',\n rsCombo = '[' + rsComboRange + ']',\n rsFitz = '\\\\ud83c[\\\\udffb-\\\\udfff]',\n rsModifier = '(?:' + rsCombo + '|' + rsFitz + ')',\n rsNonAstral = '[^' + rsAstralRange + ']',\n rsRegional = '(?:\\\\ud83c[\\\\udde6-\\\\uddff]){2}',\n rsSurrPair = '[\\\\ud800-\\\\udbff][\\\\udc00-\\\\udfff]',\n rsZWJ = '\\\\u200d';\n\n/** Used to compose unicode regexes. */\nvar reOptMod = rsModifier + '?',\n rsOptVar = '[' + rsVarRange + ']?',\n rsOptJoin = '(?:' + rsZWJ + '(?:' + [rsNonAstral, rsRegional, rsSurrPair].join('|') + ')' + rsOptVar + reOptMod + ')*',\n rsSeq = rsOptVar + reOptMod + rsOptJoin,\n rsSymbol = '(?:' + [rsNonAstral + rsCombo + '?', rsCombo, rsRegional, rsSurrPair, rsAstral].join('|') + ')';\n\n/** Used to match [string symbols](https://mathiasbynens.be/notes/javascript-unicode). */\nvar reUnicode = RegExp(rsFitz + '(?=' + rsFitz + ')|' + rsSymbol + rsSeq, 'g');\n\n/**\n * Converts a Unicode `string` to an array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the converted array.\n */\nfunction unicodeToArray(string) {\n return string.match(reUnicode) || [];\n}\n\nmodule.exports = unicodeToArray;\n","import { useVenuesQuery } from '@eventespresso/data';\nimport { useMemoStringify } from '@eventespresso/hooks';\nimport { getCacheIds } from '@eventespresso/predicates';\n\nimport type { Venue, VenueEdge } from '../../types';\nimport { useVenueQueryOptions } from './useVenueQueryOptions';\n\n/**\n * A custom react hook to retrieve all the venues from cache\n */\nexport const useVenues = (): Venue[] => {\n\tconst options = useVenueQueryOptions();\n\n\tconst { data } = useVenuesQuery(options);\n\n\tconst nodes = data?.espressoVenues?.nodes || [];\n\n\tconst cacheIds = getCacheIds(nodes);\n\n\treturn useMemoStringify(nodes, cacheIds);\n};\n","import { useCallback } from 'react';\n\nimport { EntityId, useLazyCacheQuery } from '@eventespresso/data';\n\nimport { GET_DATETIME } from './queries';\nimport type { Datetime, DatetimeItem } from '../../types';\n\ntype Callback = (id: EntityId) => Datetime;\n\nconst useLazyDatetime = (): Callback => {\n\tconst getData = useLazyCacheQuery();\n\n\treturn useCallback(\n\t\t(id) => {\n\t\t\tconst data = getData({\n\t\t\t\tquery: GET_DATETIME,\n\t\t\t\tvariables: {\n\t\t\t\t\tid,\n\t\t\t\t},\n\t\t\t});\n\t\t\treturn data?.espressoDatetime;\n\t\t},\n\t\t[getData]\n\t);\n};\n\nexport default useLazyDatetime;\n","import { useCallback } from 'react';\n\nimport { useLazyCacheQuery, EntityId } from '@eventespresso/data';\n\nimport { GET_TICKET } from './queries';\nimport type { Ticket, TicketItem } from '../../types';\n\ntype GetTicket = (id: EntityId) => Ticket;\n\nconst useLazyTicket = (): GetTicket => {\n\tconst getData = useLazyCacheQuery();\n\n\treturn useCallback(\n\t\t(id) => {\n\t\t\tconst data = getData({\n\t\t\t\tquery: GET_TICKET,\n\t\t\t\tvariables: {\n\t\t\t\t\tid,\n\t\t\t\t},\n\t\t\t});\n\t\t\treturn data?.espressoTicket;\n\t\t},\n\t\t[getData]\n\t);\n};\n\nexport default useLazyTicket;\n","import { useCallback } from 'react';\n\nimport { entitiesWithGuIdInArray } from '@eventespresso/predicates';\nimport { useRelations } from '@eventespresso/services';\nimport useTickets from './useTickets';\nimport type { Ticket } from '../../types';\nimport type { RelatedEntitiesHook } from '../types';\n\nconst useRelatedTickets = (): RelatedEntitiesHook => {\n\tconst tickets = useTickets();\n\tconst { getRelations } = useRelations();\n\n\treturn useCallback(\n\t\t({ entity, entityId }) => {\n\t\t\tconst relatedTicketIds = getRelations({\n\t\t\t\tentity,\n\t\t\t\tentityId,\n\t\t\t\trelation: 'tickets',\n\t\t\t});\n\n\t\t\treturn entitiesWithGuIdInArray(tickets, relatedTicketIds);\n\t\t},\n\t\t[getRelations, tickets]\n\t);\n};\n\nexport default useRelatedTickets;\n","import { gql } from '@eventespresso/data';\n\nexport const VENUE_ATTRIBUTES: any = gql`\n\tfragment venueAttributes on EspressoVenue {\n\t\tid\n\t\taddress\n\t\taddress2\n\t\tcacheId\n\t\tcapacity\n\t\tcity\n\t\tcountryISO\n\t\tcountryName\n\t\tdbId\n\t\tdescription\n\t\tgoogleMapLink\n\t\tname\n\t\tphone\n\t\tshortDescription\n\t\tstateAbbrev\n\t\tstateName\n\t\tthumbnail\n\t\turl\n\t\tzip\n\t}\n`;\n\nexport const GET_VENUE: any = gql`\n\tquery GET_VENUE($id: ID!) {\n\t\tvenue(id: $id) {\n\t\t\t...venueAttributes\n\t\t}\n\t}\n\t${VENUE_ATTRIBUTES}\n`;\n\nexport const GET_VENUES: any = gql`\n\tquery GET_VENUES($where: RootQueryToEspressoVenueConnectionWhereArgs) {\n\t\tespressoVenues(where: $where) {\n\t\t\tnodes {\n\t\t\t\t...venueAttributes\n\t\t\t}\n\t\t}\n\t}\n\t${VENUE_ATTRIBUTES}\n`;\n","import useUpdateEntityList from './useUpdateEntityList';\nimport { PricesList, usePriceQueryOptions } from '../../apollo';\nimport { CacheUpdaterFn, WriteQueryOptions } from '@eventespresso/data';\nimport { useMemo } from 'react';\n\nconst useUpdatePriceList = (\n\twriteQueryOptions: WriteQueryOptions = undefined\n): CacheUpdaterFn => {\n\tconst queryOptions = usePriceQueryOptions();\n\tconst options = useMemo(\n\t\t() => ({\n\t\t\t...queryOptions,\n\t\t\t...writeQueryOptions,\n\t\t}),\n\t\t[queryOptions, writeQueryOptions]\n\t);\n\treturn useUpdateEntityList(options);\n};\n\nexport default useUpdatePriceList;\n","import { useCallback } from 'react';\nimport { assocPath, pathOr } from 'ramda';\nimport type { ExecutionResult } from 'graphql';\n\nimport { EntityId, useApolloClient } from '@eventespresso/data';\nimport { entitiesWithGuIdNotInArray, findEntityByGuid } from '@eventespresso/predicates';\n\nimport type { Ticket, TicketsList } from '../../types';\nimport { useTickets, useTicketQueryOptions, DEFAULT_TICKET_LIST_DATA as DEFAULT_LIST_DATA } from '../../queries';\nimport { useUpdateTicketList } from '../../../hooks';\nimport useBulkDeleteEntities from '../useBulkDeleteEntities';\nimport { cacheNodesFromBulkDelete } from '../';\nimport { SINGULAR_ENTITY_NAME } from '../../../constants';\nimport useOnDeleteTicket from './useOnDeleteTicket';\n\ntype Callback = (args: {\n\tentityIds: Array;\n\tdeletePermanently?: boolean;\n\tdeleteRemotely?: boolean;\n\trelatedDatetimeIds?: Array;\n}) => R;\n\nconst useBulkDeleteTickets = (): Callback> => {\n\tconst allTickets = useTickets();\n\tconst queryOptions = useTicketQueryOptions();\n\tconst updateTicketList = useUpdateTicketList();\n\tconst onDeleteTicket = useOnDeleteTicket();\n\tconst { cache } = useApolloClient();\n\n\tconst bulkDelete = useBulkDeleteEntities({ entityType: 'TICKET', typeName: SINGULAR_ENTITY_NAME.TICKET });\n\n\tconst updateEntityList = useCallback>(\n\t\t({ entityIds, deletePermanently, relatedDatetimeIds }) =>\n\t\t\t() => {\n\t\t\t\t// Read the existing data from cache.\n\t\t\t\tlet data: TicketsList;\n\t\t\t\ttry {\n\t\t\t\t\tdata = cache.readQuery(queryOptions);\n\t\t\t\t} catch (error) {\n\t\t\t\t\tdata = null;\n\t\t\t\t}\n\t\t\t\tconst tickets = data?.espressoTickets || DEFAULT_LIST_DATA;\n\n\t\t\t\tconst findTicket = findEntityByGuid(tickets.nodes);\n\t\t\t\tconst filteredTickets = { ...tickets };\n\t\t\t\tlet ticket: Ticket;\n\t\t\t\t// run onDelete handler for every deleted ticket\n\t\t\t\tfor (const entityId of entityIds) {\n\t\t\t\t\tticket = findTicket(entityId);\n\t\t\t\t\tonDeleteTicket({\n\t\t\t\t\t\tcache,\n\t\t\t\t\t\ttickets: filteredTickets,\n\t\t\t\t\t\tticket,\n\t\t\t\t\t\tdeletePermanently,\n\t\t\t\t\t});\n\t\t\t\t\tfilteredTickets.nodes = entitiesWithGuIdNotInArray(filteredTickets.nodes, [entityId]);\n\t\t\t\t}\n\n\t\t\t\tconst nodes = cacheNodesFromBulkDelete(entityIds, allTickets, deletePermanently);\n\n\t\t\t\tlet options: typeof queryOptions;\n\t\t\t\t// if bulk delete is done as a result of deletion of related date(s)\n\t\t\t\tif (relatedDatetimeIds.length) {\n\t\t\t\t\tconst path = ['variables', 'where', 'datetimeIn'];\n\t\t\t\t\t// this is the current value for datetimeIn\n\t\t\t\t\tconst datetimeIn = pathOr([], path, queryOptions);\n\t\t\t\t\t// remove the related dates from query options\n\t\t\t\t\t// to make sure ticket list is updated\n\t\t\t\t\tconst finalDatetimeIn = datetimeIn.filter((id) => !relatedDatetimeIds.includes(id));\n\t\t\t\t\t// update query options\n\t\t\t\t\toptions = assocPath(path, finalDatetimeIn, queryOptions);\n\t\t\t\t}\n\n\t\t\t\tupdateTicketList({\n\t\t\t\t\t...queryOptions,\n\t\t\t\t\t...options,\n\t\t\t\t\tdata: {\n\t\t\t\t\t\tespressoTickets: {\n\t\t\t\t\t\t\t...tickets,\n\t\t\t\t\t\t\tnodes,\n\t\t\t\t\t\t},\n\t\t\t\t\t},\n\t\t\t\t});\n\t\t\t},\n\t\t[allTickets, cache, onDeleteTicket, queryOptions, updateTicketList]\n\t);\n\n\treturn useCallback(\n\t\tasync ({ entityIds, deletePermanently, deleteRemotely = true, relatedDatetimeIds = [] }) => {\n\t\t\tconst updateTheEntityList = updateEntityList({ entityIds, deletePermanently, relatedDatetimeIds });\n\t\t\t// if we need to send a remote request\n\t\t\tif (deleteRemotely) {\n\t\t\t\treturn await bulkDelete({\n\t\t\t\t\tentityIds,\n\t\t\t\t\tdeletePermanently,\n\t\t\t\t\tupdateEntityList: updateTheEntityList,\n\t\t\t\t});\n\t\t\t}\n\t\t\tupdateTheEntityList();\n\t\t},\n\t\t[bulkDelete, updateEntityList]\n\t);\n};\n\nexport default useBulkDeleteTickets;\n","import { useContext } from 'react';\nimport invariant from 'invariant';\n\nimport { DatesFilterStateContext } from '../../context';\nimport type { DatetimesFilterStateManager } from './types';\n\nconst useDatesListFilterState = (): DatetimesFilterStateManager => {\n\tconst value = useContext(DatesFilterStateContext);\n\n\tinvariant(value, 'useDatesListFilterState must be used inside component');\n\n\treturn value;\n};\n\nexport default useDatesListFilterState;\n","import { EntityId, makeVar, useReactiveVariable, ReactiveVariable } from '@eventespresso/data';\n\ntype DatetimeIds = Array;\n\nconst visibleDatetimeIds = makeVar([]);\n\nexport const useVisibleDatetimeIds = (): ReactiveVariable => {\n\treturn useReactiveVariable(visibleDatetimeIds);\n};\n","import { useContext } from 'react';\nimport invariant from 'invariant';\n\nimport { TicketsFilterStateContext } from '../../context';\nimport type { TicketsFilterStateManager } from './types';\n\nconst useTicketsListFilterState = (): TicketsFilterStateManager => {\n\tconst value = useContext(TicketsFilterStateContext);\n\n\tinvariant(value, 'useTicketsListFilterState must be used inside component');\n\n\treturn value;\n};\nexport default useTicketsListFilterState;\n","import { makeVar, ReactiveVariable, EntityId, useReactiveVariable } from '@eventespresso/data';\n\ntype TicketIds = Array;\n\nconst visibleTicketIds = makeVar([]);\n\nexport const useVisibleTicketIds = (): ReactiveVariable => {\n\treturn useReactiveVariable(visibleTicketIds);\n};\n","import { DatetimesFilterStateReducer } from './types';\n\nconst reducer: DatetimesFilterStateReducer = (state, action) => {\n\tconst { displayStartOrEndDate, sales, status, recurrence, type } = action;\n\tswitch (type) {\n\t\tcase 'SET_DISPLAY_START_OR_END_DATE':\n\t\t\treturn { ...state, displayStartOrEndDate };\n\t\tcase 'SET_SALES':\n\t\t\treturn { ...state, sales };\n\t\tcase 'SET_STATUS':\n\t\t\treturn { ...state, status };\n\t\tcase 'SET_RECURRENCE':\n\t\t\treturn { ...state, recurrence };\n\t\tdefault:\n\t\t\tthrow new Error('Unknown action');\n\t}\n};\n\nexport default reducer;\n","import { useCallback, useMemo } from 'react';\n\nimport { useEntityListFilterStateManager } from '@eventespresso/services';\nimport { DatetimeSales, DatetimeStatus } from '@eventespresso/predicates';\nimport { useSessionStorageReducer } from '@eventespresso/storage';\n\nimport type { DatetimesFilterState, DatetimesFilterStateManager } from './types';\nimport { DisplayStartOrEndDate, SortBy } from '../types';\nimport { datesList } from '../../constants';\nimport reducer from './reducer';\n\ntype FSM = DatetimesFilterStateManager;\ntype DFS = DatetimesFilterState;\n\nconst initialState: DFS = {\n\tdisplayStartOrEndDate: DisplayStartOrEndDate.start,\n\tsales: DatetimeSales.all,\n\tstatus: DatetimeStatus.activeUpcoming,\n\trecurrence: '',\n};\n\ntype ResetPageNumber = (filter: K, value: DFS[K]) => void;\n\nconst useDatesListFilterStateManager = (): FSM => {\n\tconst [state, dispatch] = useSessionStorageReducer('dates-list-filter-state', reducer, initialState);\n\n\tconst entityFilterState = useEntityListFilterStateManager('order', datesList);\n\n\tconst { setPageNumber } = entityFilterState;\n\n\tconst resetPageNumber = useCallback(\n\t\t(filter, value) => {\n\t\t\tif (value !== state[filter]) {\n\t\t\t\tsetPageNumber(1);\n\t\t\t}\n\t\t},\n\t\t[setPageNumber, state]\n\t);\n\n\tconst setDisplayStartOrEndDate: FSM['setDisplayStartOrEndDate'] = useCallback(\n\t\t(displayStartOrEndDate) => {\n\t\t\tdispatch({\n\t\t\t\ttype: 'SET_DISPLAY_START_OR_END_DATE',\n\t\t\t\tdisplayStartOrEndDate,\n\t\t\t});\n\t\t},\n\t\t[dispatch]\n\t);\n\n\tconst setSales: FSM['setSales'] = useCallback(\n\t\t(sales) => {\n\t\t\tresetPageNumber('sales', sales);\n\n\t\t\tdispatch({\n\t\t\t\ttype: 'SET_SALES',\n\t\t\t\tsales,\n\t\t\t});\n\t\t},\n\t\t[dispatch, resetPageNumber]\n\t);\n\n\tconst setStatus: FSM['setStatus'] = useCallback(\n\t\t(status) => {\n\t\t\tresetPageNumber('status', status);\n\n\t\t\tdispatch({\n\t\t\t\ttype: 'SET_STATUS',\n\t\t\t\tstatus,\n\t\t\t});\n\t\t},\n\t\t[dispatch, resetPageNumber]\n\t);\n\n\tconst setRecurrence: FSM['setRecurrence'] = useCallback(\n\t\t(recurrence) => {\n\t\t\tresetPageNumber('recurrence', recurrence);\n\n\t\t\tdispatch({\n\t\t\t\ttype: 'SET_RECURRENCE',\n\t\t\t\trecurrence,\n\t\t\t});\n\t\t},\n\t\t[dispatch, resetPageNumber]\n\t);\n\n\treturn useMemo(\n\t\t() => ({\n\t\t\t...state,\n\t\t\t...entityFilterState,\n\t\t\tsetDisplayStartOrEndDate,\n\t\t\tsetSales,\n\t\t\tsetStatus,\n\t\t\tsetRecurrence,\n\t\t}),\n\t\t[state, entityFilterState, setDisplayStartOrEndDate, setSales, setStatus, setRecurrence]\n\t);\n};\n\nexport default useDatesListFilterStateManager;\n","import { TicketsFilterStateReducer } from './types';\n\nconst reducer: TicketsFilterStateReducer = (state, action) => {\n\tconst { displayStartOrEndDate, sales, status, type } = action;\n\tswitch (type) {\n\t\tcase 'SET_DISPLAY_START_OR_END_DATE':\n\t\t\treturn { ...state, displayStartOrEndDate };\n\t\tcase 'SET_SALES':\n\t\t\treturn { ...state, sales };\n\t\tcase 'SET_STATUS':\n\t\t\treturn { ...state, status };\n\t\tcase 'TOGGLE_IS_CHAINED':\n\t\t\treturn { ...state, isChained: !state.isChained };\n\t\tdefault:\n\t\t\tthrow new Error('Unknown action');\n\t}\n};\n\nexport default reducer;\n","import { useCallback, useEffect, useMemo, useState } from 'react';\n\nimport { DisplayStartOrEndDate, SortBy } from '../types';\nimport { ticketsList } from '../../constants';\nimport { useEntityListFilterStateManager } from '@eventespresso/services';\nimport { useVisibleDatetimeIds } from '../../hooks';\nimport { useSessionStorageReducer } from '@eventespresso/storage';\nimport { TicketsSales, TicketsStatus } from '@eventespresso/predicates';\n\nimport reducer from './reducer';\nimport type { TicketsFilterState, TicketsFilterStateManager } from './types';\n\ntype FSM = TicketsFilterStateManager;\ntype TFS = TicketsFilterState;\n\nconst initialState: TicketsFilterState = {\n\tdisplayStartOrEndDate: DisplayStartOrEndDate.start,\n\tisChained: true,\n\tsales: TicketsSales.all,\n\tstatus: TicketsStatus.onSaleAndPending,\n};\ntype ResetPageNumber = (filter: K, value: TFS[K]) => void;\n\nconst useTicketsListFilterStateManager = (): FSM => {\n\tconst [state, dispatch] = useSessionStorageReducer('ticket-list-filter-state', reducer, initialState);\n\n\tconst [visibleDatesStr, setVisibleDatesStr] = useState('');\n\n\tconst [visibleDatetimeIds] = useVisibleDatetimeIds();\n\n\tconst entityFilterState = useEntityListFilterStateManager('order', ticketsList);\n\n\tconst { setPageNumber } = entityFilterState;\n\n\t// subscribe to visible dates for isChained\n\tuseEffect(() => {\n\t\tif (state.isChained) {\n\t\t\tsetVisibleDatesStr(visibleDatetimeIds.join(':'));\n\t\t}\n\t}, [state.isChained, visibleDatetimeIds]);\n\n\tconst resetPageNumber = useCallback(\n\t\t(filter, value) => {\n\t\t\tif (value !== state[filter]) {\n\t\t\t\tsetPageNumber(1);\n\t\t\t}\n\t\t},\n\t\t[setPageNumber, state]\n\t);\n\n\tconst setDisplayStartOrEndDate: FSM['setDisplayStartOrEndDate'] = useCallback(\n\t\t(displayStartOrEndDate) => {\n\t\t\tdispatch({\n\t\t\t\ttype: 'SET_DISPLAY_START_OR_END_DATE',\n\t\t\t\tdisplayStartOrEndDate,\n\t\t\t});\n\t\t},\n\t\t[dispatch]\n\t);\n\n\tconst setSales: FSM['setSales'] = useCallback(\n\t\t(sales) => {\n\t\t\tresetPageNumber('sales', sales);\n\n\t\t\tdispatch({\n\t\t\t\ttype: 'SET_SALES',\n\t\t\t\tsales,\n\t\t\t});\n\t\t},\n\t\t[dispatch, resetPageNumber]\n\t);\n\n\tconst setStatus: FSM['setStatus'] = useCallback(\n\t\t(status) => {\n\t\t\tresetPageNumber('status', status);\n\t\t\tdispatch({\n\t\t\t\ttype: 'SET_STATUS',\n\t\t\t\tstatus,\n\t\t\t});\n\t\t},\n\t\t[dispatch, resetPageNumber]\n\t);\n\n\tconst toggleIsChained: FSM['toggleIsChained'] = useCallback(() => {\n\t\tdispatch({\n\t\t\ttype: 'TOGGLE_IS_CHAINED',\n\t\t});\n\t}, [dispatch]);\n\n\treturn useMemo(\n\t\t() => ({\n\t\t\t...state,\n\t\t\t...entityFilterState,\n\t\t\tsetDisplayStartOrEndDate,\n\t\t\tsetSales,\n\t\t\tsetStatus,\n\t\t\ttoggleIsChained,\n\t\t\tvisibleDatesStr,\n\t\t}),\n\t\t[entityFilterState, visibleDatesStr, setDisplayStartOrEndDate, setSales, toggleIsChained, state, setStatus]\n\t);\n};\n\nexport default useTicketsListFilterStateManager;\n","import { useCacheQuery } from '@eventespresso/data';\nimport useEventQueryOptions from './useEventQueryOptions';\nimport { useMemoStringify } from '@eventespresso/hooks';\n\nimport type { Event, EventData } from '../../types';\n\nconst useEvent = (): Event => {\n\tconst options = useEventQueryOptions();\n\n\tconst { data } = useCacheQuery(options);\n\n\treturn useMemoStringify(data?.espressoEvent);\n};\n\nexport default useEvent;\n","function _isPlaceholder(a) {\n return a != null && typeof a === 'object' && a['@@functional/placeholder'] === true;\n}\n\nmodule.exports = _isPlaceholder;","var _has =\n/*#__PURE__*/\nrequire(\"./_has\");\n\nvar toString = Object.prototype.toString;\n\nvar _isArguments =\n/*#__PURE__*/\nfunction () {\n return toString.call(arguments) === '[object Arguments]' ? function _isArguments(x) {\n return toString.call(x) === '[object Arguments]';\n } : function _isArguments(x) {\n return _has('callee', x);\n };\n}();\n\nmodule.exports = _isArguments;","import { useMemo } from 'react';\n\nimport useUpdateEntityList from './useUpdateEntityList';\nimport { PriceTypesList, usePriceTypeQueryOptions } from '../../apollo';\nimport { CacheUpdaterFn, WriteQueryOptions } from '@eventespresso/data';\n\nconst useUpdatePriceTypeList = (\n\twriteQueryOptions: WriteQueryOptions = undefined\n): CacheUpdaterFn => {\n\tconst queryOptions = usePriceTypeQueryOptions();\n\tconst options = useMemo(\n\t\t() => ({\n\t\t\t...queryOptions,\n\t\t\t...writeQueryOptions,\n\t\t}),\n\t\t[queryOptions, writeQueryOptions]\n\t);\n\treturn useUpdateEntityList(options);\n};\n\nexport default useUpdatePriceTypeList;\n","import { useMemo } from 'react';\n\nimport useUpdateEntityList from './useUpdateEntityList';\nimport { VenuesList, useVenueQueryOptions } from '../../apollo';\nimport { CacheUpdaterFn, WriteQueryOptions } from '@eventespresso/data';\n\nconst useUpdateVenueList = (\n\twriteQueryOptions: WriteQueryOptions = undefined\n): CacheUpdaterFn => {\n\tconst queryOptions = useVenueQueryOptions();\n\tconst options = useMemo(\n\t\t() => ({\n\t\t\t...queryOptions,\n\t\t\t...writeQueryOptions,\n\t\t}),\n\t\t[queryOptions, writeQueryOptions]\n\t);\n\treturn useUpdateEntityList(options);\n};\n\nexport default useUpdateVenueList;\n","import { useCallback, useMemo } from 'react';\n\nimport { useMutationWithFeedback, MutationType } from '@eventespresso/data';\nimport { useDatetimeQueryOptions, useDatetimes } from '../../queries';\nimport { BulkUpdateDatetimeInput, BULK_UPDATE_DATETIMES } from './';\nimport useOnUpdateDatetime from './useOnUpdateDatetime';\nimport { useUpdateDatetimeList } from '../../../hooks';\nimport { cacheNodesFromBulkInput, updateDatetimeFlags } from '../utils';\nimport type { DatetimeEdge, Datetime } from '../../types';\nimport { SINGULAR_ENTITY_NAME } from '../../../constants';\n\ninterface BulkEditDatetimes {\n\tupdateEntities: (input: BulkUpdateDatetimeInput) => ReturnType>;\n}\n\nconst useBulkEditDatetimes = (): BulkEditDatetimes => {\n\tconst allDatetimes = useDatetimes();\n\tconst queryOptions = useDatetimeQueryOptions();\n\tconst updateDatetimeList = useUpdateDatetimeList();\n\tconst onUpdateDatetime = useOnUpdateDatetime();\n\n\tconst updateDatetimes = useMutationWithFeedback({\n\t\ttypeName: SINGULAR_ENTITY_NAME.DATETIME,\n\t\tmutationType: MutationType.Update,\n\t\tmutation: BULK_UPDATE_DATETIMES,\n\t});\n\n\tconst updateEntityList = useCallback(\n\t\t(input: BulkUpdateDatetimeInput) => () => {\n\t\t\tconst nodes = cacheNodesFromBulkInput(input, allDatetimes).map(updateDatetimeFlags);\n\n\t\t\tconst espressoDatetimes: DatetimeEdge = {\n\t\t\t\tnodes,\n\t\t\t\t__typename: 'EspressoRootQueryDatetimesConnection',\n\t\t\t};\n\t\t\tupdateDatetimeList({\n\t\t\t\t...queryOptions,\n\t\t\t\tdata: {\n\t\t\t\t\tespressoDatetimes,\n\t\t\t\t},\n\t\t\t});\n\t\t\t// update entity relations\n\t\t\tinput.uniqueInputs.forEach(({ tickets, ...updateInput }) => {\n\t\t\t\tonUpdateDatetime({ datetime: updateInput as Datetime, tickets });\n\t\t\t});\n\t\t},\n\t\t[allDatetimes, onUpdateDatetime, queryOptions, updateDatetimeList]\n\t);\n\n\tconst updateEntities = useCallback(\n\t\t(input) => {\n\t\t\tconst variables = {\n\t\t\t\tinput: {\n\t\t\t\t\tclientMutationId: 'BULK_UPDATE_DATETIMES',\n\t\t\t\t\t...input,\n\t\t\t\t},\n\t\t\t};\n\t\t\treturn updateDatetimes({ variables, update: updateEntityList(input) });\n\t\t},\n\t\t[updateDatetimes, updateEntityList]\n\t);\n\n\treturn useMemo(() => ({ updateEntities }), [updateEntities]);\n};\n\nexport default useBulkEditDatetimes;\n","import { useCallback } from 'react';\nimport type { ExecutionResult } from 'graphql';\n\nimport { EntityId, useApolloClient } from '@eventespresso/data';\nimport { entitiesWithGuIdNotInArray, findEntityByGuid } from '@eventespresso/predicates';\n\nimport type { Datetime, DatetimeEdge, DatetimesList } from '../../types';\nimport { useDatetimes, useDatetimeQueryOptions, DEFAULT_DATETIME_LIST_DATA as DEFAULT_LIST_DATA } from '../../queries';\nimport { useUpdateDatetimeList } from '../../../hooks';\nimport useBulkDeleteEntities from '../useBulkDeleteEntities';\nimport { cacheNodesFromBulkDelete } from '../';\nimport useOnDeleteDatetime from './useOnDeleteDatetime';\nimport useDeleteRelatedTickets from './useDeleteRelatedTickets';\nimport { SINGULAR_ENTITY_NAME } from '../../../constants';\n\ntype Callback = (entityIds: Array, deletePermanently?: boolean) => R;\n\nconst useBulkDeleteDatetimes = (): Callback> => {\n\tconst allDatetimes = useDatetimes();\n\tconst queryOptions = useDatetimeQueryOptions();\n\tconst updateDatetimeList = useUpdateDatetimeList();\n\tconst onDeleteDatetime = useOnDeleteDatetime();\n\n\tconst { cache } = useApolloClient();\n\n\tconst bulkDelete = useBulkDeleteEntities({ entityType: 'DATETIME', typeName: SINGULAR_ENTITY_NAME.DATETIME });\n\n\tconst deleteRelatedTickets = useDeleteRelatedTickets();\n\n\tconst updateEntityList = useCallback>(\n\t\t(entityIds, deletePermanently) => async () => {\n\t\t\t// delete related tickets for each date\n\t\t\tfor (const entityId of entityIds) {\n\t\t\t\tawait deleteRelatedTickets(entityId, deletePermanently);\n\t\t\t}\n\n\t\t\t// Read the existing data from cache.\n\t\t\tlet data: DatetimesList;\n\t\t\ttry {\n\t\t\t\tdata = cache.readQuery(queryOptions);\n\t\t\t} catch (error) {\n\t\t\t\tdata = null;\n\t\t\t}\n\t\t\tconst datetimes = data?.espressoDatetimes || DEFAULT_LIST_DATA;\n\n\t\t\tconst findDatetime = findEntityByGuid(datetimes.nodes);\n\t\t\tconst filteredDatetimes = { ...datetimes };\n\t\t\tlet datetime: Datetime;\n\t\t\t// run onDelete handler for every deleted datetime\n\t\t\tfor (const entityId of entityIds) {\n\t\t\t\tdatetime = findDatetime(entityId);\n\t\t\t\tonDeleteDatetime({\n\t\t\t\t\tcache,\n\t\t\t\t\tdatetimes: filteredDatetimes,\n\t\t\t\t\tdatetime,\n\t\t\t\t\tdeletePermanently,\n\t\t\t\t});\n\t\t\t\tfilteredDatetimes.nodes = entitiesWithGuIdNotInArray(filteredDatetimes.nodes, [entityId]);\n\t\t\t}\n\n\t\t\tconst nodes = cacheNodesFromBulkDelete(entityIds, allDatetimes, deletePermanently);\n\n\t\t\tconst espressoDatetimes: DatetimeEdge = {\n\t\t\t\tnodes,\n\t\t\t\t__typename: 'EspressoRootQueryDatetimesConnection',\n\t\t\t};\n\t\t\tupdateDatetimeList({\n\t\t\t\t...queryOptions,\n\t\t\t\tdata: {\n\t\t\t\t\tespressoDatetimes,\n\t\t\t\t},\n\t\t\t});\n\t\t},\n\t\t[allDatetimes, cache, deleteRelatedTickets, onDeleteDatetime, queryOptions, updateDatetimeList]\n\t);\n\n\treturn useCallback(\n\t\tasync (entityIds, deletePermanently) => {\n\t\t\treturn await bulkDelete({\n\t\t\t\tentityIds,\n\t\t\t\tdeletePermanently,\n\t\t\t\tupdateEntityList: updateEntityList(entityIds, deletePermanently),\n\t\t\t});\n\t\t},\n\t\t[bulkDelete, updateEntityList]\n\t);\n};\n\nexport default useBulkDeleteDatetimes;\n","import { useCallback, useMemo, useState } from 'react';\n\nimport { datetimesDroppableId } from '@eventespresso/constants';\n\nimport type { EntityId } from '@eventespresso/data';\nimport type { EntityTableProps } from '@eventespresso/ee-components';\n\nimport { ReorderEntities, useReorderEntities } from '../useReorderEntities';\nimport { useDatetimes, useDatetimeQueryOptions, useLazyDatetime } from '../../queries';\nimport { useUpdateDatetimeList } from '../../../hooks';\nimport { DatetimesFilterStateManager as DFSM } from '../../../filterState';\nimport type { Datetime, DatetimeEdge } from '../../types';\n\ntype SortResponder = EntityTableProps['onSort'];\n\ninterface ReorderDatetimes extends Pick, 'allReorderedEntities' | 'updateEntityList'> {\n\tsortResponder: SortResponder;\n\tupdateEntityList: VoidFunction;\n}\n\nconst useReorderDatetimes = (filteredEntityIds: Array): ReorderDatetimes => {\n\tconst [allUpdatedEntities, setAllUpdatedEntities] = useState>([]);\n\tconst getDatetime = useLazyDatetime();\n\n\tconst datetimes = useMemo(() => filteredEntityIds.map(getDatetime), [filteredEntityIds, getDatetime]);\n\n\tconst { allReorderedEntities, updateSortOrder, sortEntities } = useReorderEntities({\n\t\tentityType: 'DATETIME',\n\t\tfilteredEntities: datetimes,\n\t});\n\tconst allEntities = useDatetimes();\n\n\tconst queryOptions = useDatetimeQueryOptions();\n\tconst updateDatetimeList = useUpdateDatetimeList();\n\n\tconst updateEntityList = useCallback(async () => {\n\t\tconst espressoDatetimes: DatetimeEdge = {\n\t\t\tnodes: allUpdatedEntities,\n\t\t\t__typename: 'EspressoRootQueryDatetimesConnection',\n\t\t};\n\n\t\tawait updateSortOrder();\n\n\t\tupdateDatetimeList({\n\t\t\t...queryOptions,\n\t\t\tdata: {\n\t\t\t\tespressoDatetimes,\n\t\t\t},\n\t\t});\n\t}, [allUpdatedEntities, updateSortOrder, queryOptions, updateDatetimeList]);\n\n\tconst sortResponder = useCallback(\n\t\t({ destination, source }) => {\n\t\t\tconst noDestination = !destination;\n\t\t\tconst noChange = source?.index === destination?.index && destination?.droppableId === source?.droppableId;\n\t\t\tconst notOurListOfInterest = destination?.droppableId !== datetimesDroppableId;\n\n\t\t\tif (noDestination || noChange || notOurListOfInterest) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tconst allSortedEntities = sortEntities({\n\t\t\t\tallEntities,\n\t\t\t\tnewIndex: destination.index,\n\t\t\t\toldIndex: source.index,\n\t\t\t});\n\n\t\t\tsetAllUpdatedEntities(allSortedEntities);\n\t\t},\n\t\t[allEntities, sortEntities]\n\t);\n\n\treturn useMemo(\n\t\t() => ({ allReorderedEntities, sortResponder, updateEntityList }),\n\t\t[allReorderedEntities, sortResponder, updateEntityList]\n\t);\n};\n\nexport default useReorderDatetimes;\n","import { useCallback, useMemo, useState } from 'react';\n\nimport { ticketDroppableId } from '@eventespresso/constants';\nimport type { EntityId } from '@eventespresso/data';\nimport type { EntityTableProps } from '@eventespresso/ee-components';\n\nimport { ReorderEntities, useReorderEntities } from '../useReorderEntities';\nimport { TicketsFilterStateManager as TFSM } from '../../../filterState';\nimport { useTickets, useTicketQueryOptions, useLazyTicket } from '../../queries';\nimport { useUpdateTicketList } from '../../../hooks';\nimport type { Ticket, TicketEdge } from '../../types';\n\ntype SortResponder = EntityTableProps['onSort'];\n\ninterface ReorderTickets extends Pick, 'allReorderedEntities' | 'updateEntityList'> {\n\tsortResponder: SortResponder;\n}\n\nconst useReorderTickets = (filteredEntityIds: Array): ReorderTickets => {\n\tconst [allUpdatedEntities, setAllUpdatedEntities] = useState>([]);\n\tconst getTicket = useLazyTicket();\n\tconst filteredTickets = useMemo(() => filteredEntityIds.map(getTicket), [filteredEntityIds, getTicket]);\n\n\tconst { allReorderedEntities, updateSortOrder, sortEntities } = useReorderEntities({\n\t\tentityType: 'TICKET',\n\t\tfilteredEntities: filteredTickets,\n\t});\n\n\tconst allEntities = useTickets();\n\n\tconst queryOptions = useTicketQueryOptions();\n\tconst updateTicketList = useUpdateTicketList();\n\tconst updateEntityList = useCallback(async () => {\n\t\tconst espressoTickets: TicketEdge = {\n\t\t\tnodes: allUpdatedEntities,\n\t\t\t__typename: 'EspressoRootQueryTicketsConnection',\n\t\t};\n\n\t\tawait updateSortOrder();\n\n\t\tupdateTicketList({\n\t\t\t...queryOptions,\n\t\t\tdata: {\n\t\t\t\tespressoTickets,\n\t\t\t},\n\t\t});\n\t}, [allUpdatedEntities, updateSortOrder, queryOptions, updateTicketList]);\n\n\tconst sortResponder = useCallback(\n\t\t({ destination, source }) => {\n\t\t\tconst noDestination = !destination;\n\t\t\tconst noChange = source?.index === destination?.index && destination?.droppableId === source?.droppableId;\n\t\t\tconst notOurListOfInterest = destination?.droppableId !== ticketDroppableId;\n\n\t\t\tif (noDestination || noChange || notOurListOfInterest) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tconst allSortedEntities = sortEntities({\n\t\t\t\tallEntities,\n\t\t\t\tnewIndex: destination.index,\n\t\t\t\toldIndex: source.index,\n\t\t\t});\n\n\t\t\tsetAllUpdatedEntities(allSortedEntities);\n\t\t},\n\t\t[allEntities, sortEntities]\n\t);\n\n\treturn useMemo(\n\t\t() => ({ allReorderedEntities, sortResponder, updateEntityList }),\n\t\t[allReorderedEntities, sortResponder, updateEntityList]\n\t);\n};\n\nexport default useReorderTickets;\n","import { useCallback, useMemo } from 'react';\n\nimport { parseInfinity, isInfinite } from '@eventespresso/utils';\nimport { entitiesWithGuIdInArray, uniqTicketsByMinQty, ticketQuantityFromCapacity } from '@eventespresso/predicates';\nimport { EntityId } from '@eventespresso/data';\nimport { useSystemNotifications } from '@eventespresso/toaster';\nimport { __ } from '@eventespresso/i18n';\n\nimport { useTickets, useRelatedTickets } from '../../queries';\nimport useBulkEditTickets from './useBulkEditTickets';\n\nimport type { UpdateTicketInput } from './types';\nimport type { Datetime } from '../../types';\n\ntype UpdateTicketQtyByCapacity = {\n\t/**\n\t * Given a datetime and/or `ticketIdsToUpdate`, it generates bulk edit input with updated ticket quantities\n\t */\n\tcreateBulkQtyUpdateInput: (\n\t\tdatetime: Pick,\n\t\tticketIdsToUpdate?: Array\n\t) => Array;\n\t/**\n\t * Given unique inputs of a bulk edit mutation, it performes the actual mutation\n\t * removing the duplicate entries in the input by retaining the tickets with minimum quantity\n\t */\n\tdoQtyBulkUpdate: (uniqInputs: Array, showNotice?: boolean) => Promise;\n};\n\nexport const useUpdateTicketQtyByCapacity = (): UpdateTicketQtyByCapacity => {\n\tconst tickets = useTickets();\n\tconst getRelatedTickets = useRelatedTickets();\n\tconst { updateEntities: bulkEditTickets } = useBulkEditTickets();\n\tconst toaster = useSystemNotifications();\n\n\tconst createBulkQtyUpdateInput = useCallback(\n\t\t(datetime, ticketIdsToUpdate = []) => {\n\t\t\t// If `ticketIdsToUpdate` is passed, we will give preference to it.\n\t\t\t// Otherwise we will try to update the previous related tickets\n\t\t\tconst ticketsToUpdate = ticketIdsToUpdate?.length\n\t\t\t\t? entitiesWithGuIdInArray(tickets, ticketIdsToUpdate)\n\t\t\t\t: getRelatedTickets({ entity: 'datetimes', entityId: datetime.id });\n\n\t\t\tconst capacity = parseInfinity(datetime.capacity, Infinity);\n\n\t\t\tconst getTicketQuantityFromCapacity = ticketQuantityFromCapacity(capacity);\n\n\t\t\tconst uniqueInputs = ticketsToUpdate\n\t\t\t\t.map(({ id, quantity }) => {\n\t\t\t\t\tconst nonNegativeTicketQuantity = parseInfinity(quantity, Infinity);\n\n\t\t\t\t\t// if capacity is infinite or it's more than ticket quantity\n\t\t\t\t\tif (isInfinite(capacity) || capacity >= nonNegativeTicketQuantity) {\n\t\t\t\t\t\t// no need to update the ticket quantity\n\t\t\t\t\t\treturn null;\n\t\t\t\t\t}\n\t\t\t\t\tconst newQuantity = getTicketQuantityFromCapacity(quantity);\n\n\t\t\t\t\treturn { id, quantity: newQuantity };\n\t\t\t\t})\n\t\t\t\t.filter(Boolean);\n\n\t\t\treturn uniqueInputs;\n\t\t},\n\t\t[getRelatedTickets, tickets]\n\t);\n\n\tconst doQtyBulkUpdate = useCallback(\n\t\tasync (uniqInputs, showNotice = true) => {\n\t\t\tif (uniqInputs.length) {\n\t\t\t\t// remove duplicate entries, if any\n\t\t\t\tconst uniqueInputs = uniqTicketsByMinQty(uniqInputs);\n\t\t\t\t// perform the bulk update\n\t\t\t\tawait bulkEditTickets({ uniqueInputs });\n\n\t\t\t\tif (showNotice) {\n\t\t\t\t\ttoaster.info({\n\t\t\t\t\t\tmessage: __(\n\t\t\t\t\t\t\t'Ticket quantity has been adjusted because it cannot be more than the related event date capacity.'\n\t\t\t\t\t\t),\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t}\n\t\t},\n\t\t[bulkEditTickets, toaster]\n\t);\n\n\treturn useMemo(() => ({ createBulkQtyUpdateInput, doQtyBulkUpdate }), [createBulkQtyUpdateInput, doQtyBulkUpdate]);\n};\n","import { useCallback } from 'react';\nimport type { ExecutionResult } from 'graphql';\n\nimport type { EntityId } from '@eventespresso/data';\nimport type { PriceEdge } from '../../types';\nimport { usePrices, usePriceQueryOptions } from '../../queries';\nimport { useUpdatePriceList } from '../../../hooks';\nimport useBulkDeleteEntities from '../useBulkDeleteEntities';\nimport { TypeName, cacheNodesFromBulkDelete } from '../';\n\ntype Callback = (entityIds: Array) => R;\n\nconst useBulkDeletePrices = (): Callback> => {\n\tconst allPrices = usePrices();\n\tconst queryOptions = usePriceQueryOptions();\n\tconst updatePriceList = useUpdatePriceList();\n\n\tconst bulkDelete = useBulkDeleteEntities({ entityType: 'PRICE', typeName: TypeName.Price });\n\n\tconst updateEntityList = useCallback>(\n\t\t(entityIds) => () => {\n\t\t\t// pass true to deletePermanently, because prices are not trashable\n\t\t\tconst nodes = cacheNodesFromBulkDelete(entityIds, allPrices, true);\n\n\t\t\tconst espressoPrices: PriceEdge = {\n\t\t\t\tnodes,\n\t\t\t\t__typename: 'EspressoRootQueryPricesConnection',\n\t\t\t};\n\t\t\tupdatePriceList({\n\t\t\t\t...queryOptions,\n\t\t\t\tdata: {\n\t\t\t\t\tespressoPrices,\n\t\t\t\t},\n\t\t\t});\n\t\t},\n\t\t[allPrices, queryOptions, updatePriceList]\n\t);\n\n\treturn useCallback(\n\t\tasync (entityIds) => {\n\t\t\treturn await bulkDelete({\n\t\t\t\tentityIds,\n\t\t\t\tupdateEntityList: updateEntityList(entityIds),\n\t\t\t});\n\t\t},\n\t\t[bulkDelete, updateEntityList]\n\t);\n};\n\nexport default useBulkDeletePrices;\n","import type {\n\tAddress,\n\tEntity,\n\tEntityId,\n\tEntityEdge,\n\tTrashable,\n\tDatetimesList as DatetimeList,\n\tTicketsList as TicketList,\n\tUser,\n} from '@eventespresso/data';\n\nexport interface Event extends Entity {\n\tallowDonations: boolean;\n\tallowOverflow: boolean;\n\taltRegPage: string;\n\tcreated: string;\n\tdefaultRegStatus: string;\n\tdescription: string;\n\tdisplayDescription: boolean;\n\tdisplayTicketSelector: boolean;\n\tisActive: boolean;\n\tisCancelled: boolean;\n\tisExpired: boolean;\n\tisInactive: boolean;\n\tisPostponed: boolean;\n\tisSoldOut: boolean;\n\tisUpcoming: boolean;\n\tmanager?: EventManager;\n\tmaxRegistrations: number;\n\tmemberOnly: boolean;\n\tname: string;\n\torder: number;\n\tphoneNumber: string;\n\tshortDescription: string;\n\tstatus: string;\n\ttimezoneString: string;\n\tvenue: EntityId; // UUID\n}\n\nexport type EventManager = Pick;\n\nexport interface EventData {\n\tespressoEvent: Event;\n}\n\nexport enum DateStatus {\n\tsoldOut = 'DTS',\n\tactive = 'DTA',\n\tupcoming = 'DTU',\n\tpostponed = 'DTP',\n\tcancelled = 'DTC',\n\texpired = 'DTE',\n\tinactive = 'DTI',\n}\n\nexport interface Datetime extends Entity, Trashable {\n\t__typename: 'EspressoDatetime';\n\tcapacity: number;\n\tdescription: string;\n\tendDate: string;\n\tisActive: boolean;\n\tisExpired: boolean;\n\tisPrimary: boolean;\n\tisSoldOut: boolean;\n\tisUpcoming: boolean;\n\tlength: number;\n\tname: string;\n\torder: number;\n\treserved: number;\n\tsold: number;\n\tstartDate: string;\n\tstatus: DateStatus;\n\tvenue: EntityId; // UUID\n}\n\n// type guard\n// https://www.typescriptlang.org/docs/handbook/2/narrowing.html\nexport const isDatetime = (entity: Entity): entity is Datetime => {\n\treturn entity.__typename === 'EspressoDatetime';\n};\n\nexport interface DatetimeItem {\n\tespressoDatetime: Datetime;\n}\n\nexport type DatetimeEdge = EntityEdge;\n\nexport type DatetimesList = DatetimeList;\n\nexport interface Price extends Entity, Trashable {\n\tamount: number;\n\tdescription: string;\n\tisBasePrice: boolean;\n\tisDefault: boolean;\n\tisDiscount: boolean;\n\tisPercent: boolean;\n\tisTax: boolean;\n\tname: string;\n\torder: number;\n\toverrides: number;\n}\n\nexport type PriceEdge = EntityEdge;\n\nexport interface PricesList {\n\tespressoPrices: PriceEdge;\n}\n\nexport type TicketVisibility = 'ADMINS_ONLY' | 'ADMIN_UI_ONLY' | 'MEMBERS_ONLY' | 'NONE' | 'PUBLIC';\n\nexport interface Ticket extends Entity, Trashable {\n\tdescription: string;\n\tendDate: string; // ISO string\n\tisDefault: boolean;\n\tisExpired: boolean;\n\tisFree: boolean;\n\tisOnSale: boolean;\n\tisPending: boolean;\n\tisRequired: boolean;\n\tisSoldOut: boolean;\n\tmax: number;\n\tmin: number;\n\tname: string;\n\torder: number;\n\tprice: number;\n\tprices?: PriceEdge; // for create and update ticket mutation\n\tquantity: number;\n\tregistrationCount: number;\n\treserved: number;\n\treverseCalculate: boolean;\n\tsold: number;\n\tstartDate: string; // ISO string\n\tuserId: EntityId;\n\tuses: number;\n\tvisibility: TicketVisibility;\n}\n\nexport interface TicketItem {\n\tespressoTicket: Ticket;\n}\n\nexport type TicketEdge = EntityEdge;\n\nexport type TicketsList = TicketList;\n\nexport enum PriceBasetype {\n\tBASE_PRICE = 'BASE_PRICE',\n\tDISCOUNT = 'DISCOUNT',\n\tSURCHARGE = 'SURCHARGE',\n\tTAX = 'TAX',\n}\n\nexport interface PriceType extends Entity, Trashable {\n\tbaseType: PriceBasetype;\n\tisBasePrice: boolean;\n\tisDiscount: boolean;\n\tisPercent: boolean;\n\tisTax: boolean;\n\tname: string;\n\torder: number;\n}\n\nexport type PriceTypeEdge = EntityEdge;\n\nexport interface PriceTypesList {\n\tespressoPriceTypes: PriceTypeEdge;\n}\n\nexport interface Venue extends Entity, Address {\n\tcapacity: number;\n\tdescription: string;\n\tgoogleMapLink: string;\n\tname: string;\n\tphone: string;\n\tshortDescription: string;\n\tthumbnail: string;\n\turl: string;\n}\n\nexport type VenueEdge = EntityEdge;\n\nexport interface VenuesList {\n\tespressoVenues: VenueEdge;\n}\n","export { default as useDatesListFilterState } from './useDatesListFilterState';\n\nexport { default as useFilteredDateIds } from './useFilteredDateIds';\n\nexport { default as useDatesListFilterStateManager } from './useDatesListFilterStateManager';\n\nexport * from './types';\n","import { useContext } from 'react';\nimport invariant from 'invariant';\n\nimport type { EntityId } from '@eventespresso/data';\nimport { FilteredDatesContext } from '../../context';\n\nconst useFilteredDateIds = (): Array => {\n\tconst value = useContext(FilteredDatesContext);\n\n\tinvariant(value, 'useFilteredDateIds must be used inside component');\n\n\treturn value;\n};\nexport default useFilteredDateIds;\n","export { default as useTicketsListFilterState } from './useTicketsListFilterState';\n\nexport { default as useFilteredTicketIds } from './useFilteredTicketIds';\n\nexport { default as useRegisterIsChainedFilter } from './useRegisterIsChainedFilter';\n\nexport { default as useTicketsListFilterStateManager } from './useTicketsListFilterStateManager';\n\nexport * from './types';\n","import { useContext } from 'react';\nimport invariant from 'invariant';\n\nimport type { EntityId } from '@eventespresso/data';\n\nimport { FilteredTicketsContext } from '../../context';\n\nconst useFilteredTicketIds = (): Array => {\n\tconst value = useContext(FilteredTicketsContext);\n\n\tinvariant(value, 'useFilteredTicketIds must be used inside component');\n\n\treturn value;\n};\n\nexport default useFilteredTicketIds;\n","export * from './types';\n","import type { OptionsType } from '@eventespresso/adapters';\nimport type { User } from '@eventespresso/data';\nimport type { GeneralSettings, RelationalData } from '@eventespresso/services';\nimport type { FormSectionRaw, FormElementRaw } from '@eventespresso/form-builder';\nimport type { DatetimeEdge, TicketEdge, PriceEdge, PriceTypeEdge, Event, EventManager, VenueEdge } from './apollo';\n\nexport type TicketMeta = {\n\tvisibilityOptions: OptionsType;\n};\n\nexport type EdtrFormBuilderData = {\n\tsections: Array;\n\telements: Array;\n\ttopLevelSectionId?: string;\n};\n\nexport interface EventEditorData {\n\tdatetimes?: DatetimeEdge;\n\tevent?: Event;\n\teventManagers?: Array;\n\tformBuilder?: EdtrFormBuilderData;\n\tpriceTypes?: PriceTypeEdge;\n\tprices?: PriceEdge;\n\trelations?: RelationalData;\n\tticketMeta?: TicketMeta;\n\ttickets?: TicketEdge;\n\tvenues?: VenueEdge;\n}\n\nexport interface EditorData {\n\teventEditor: EventEditorData;\n\tcurrentUser?: User;\n\tgeneralSettings?: GeneralSettings;\n}\n\nexport interface EventEditorDomData {\n\teventEditor: EventEditorData;\n}\n\nexport enum EdtrGlobalModals {\n\tDEFAULT_TICKETS = 'defaultTickets',\n\tEDIT_DATE = 'editDate',\n\tEDIT_TICKET = 'editTicket',\n\tNEW_DATE = 'newDate',\n\tTAM = 'tam',\n\tTPC = 'tpc',\n}\n\nexport enum QueryURLRegStatus {\n\tAPPROVED = 'RAP',\n\tPENDING = 'RPP',\n\tWAITLIST = 'RWL',\n\tINCOMPLETE = 'RIC',\n\tNOT_APPROVED = 'RNA',\n\tDECLINED = 'RDC',\n\tCANCELLED = 'RCN',\n}\n","import { useCallback } from 'react';\n\nimport type { MutationType, MutationInput, OperationVariables } from '@eventespresso/data';\n\ntype MutationVariablesCb = (mutationType: MutationType, input: MutationInput) => OperationVariables;\n\nconst useMutationVariables = (): MutationVariablesCb => {\n\treturn useCallback((mutationType, input) => {\n\t\tconst mutationInput: MutationInput = {\n\t\t\tclientMutationId: `${mutationType}_PRICE`,\n\t\t\t...input,\n\t\t};\n\n\t\treturn {\n\t\t\tinput: mutationInput,\n\t\t};\n\t}, []);\n};\n\nexport default useMutationVariables;\n","import { useCallback } from 'react';\nimport { findIndex, update } from 'ramda';\n\nimport type { CacheUpdaterFn, CacheUpdaterFnArgs } from '../types';\nimport { Price, PricesList } from '../../';\nimport { WriteQueryOptions } from '@eventespresso/data';\nimport { entityHasGuid } from '@eventespresso/predicates';\nimport { usePriceQueryOptions } from '../../queries';\n\nconst useUpdatePriceCache = (): CacheUpdaterFn => {\n\tconst queryOptions = usePriceQueryOptions();\n\n\tconst updatePriceCache = useCallback(\n\t\t({ cache, prices, price, action }: CacheUpdaterFnArgs): void => {\n\t\t\tconst { nodes = [] } = prices;\n\t\t\tlet newNodes: Array = [],\n\t\t\t\tpriceIndex: number;\n\t\t\tswitch (action) {\n\t\t\t\tcase 'add':\n\t\t\t\t\tnewNodes = [...nodes, price];\n\t\t\t\t\tbreak;\n\t\t\t\tcase 'update':\n\t\t\t\t\t// find the index of the price to update\n\t\t\t\t\tpriceIndex = findIndex(entityHasGuid(price.id), nodes);\n\t\t\t\t\t// if price exists\n\t\t\t\t\tif (priceIndex >= 0) {\n\t\t\t\t\t\tnewNodes = update(priceIndex, price, nodes);\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\tcase 'remove':\n\t\t\t\t\tnewNodes = nodes.filter(({ id }) => id !== price.id);\n\t\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t\tnewNodes = nodes;\n\t\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\t// write the data to cache without\n\t\t\t// mutating the cache directly\n\t\t\tconst writeOptions: WriteQueryOptions = {\n\t\t\t\t...queryOptions,\n\t\t\t\tdata: {\n\t\t\t\t\tespressoPrices: {\n\t\t\t\t\t\t...prices,\n\t\t\t\t\t\tnodes: newNodes,\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t};\n\t\t\tcache.writeQuery(writeOptions);\n\t\t},\n\t\t[queryOptions]\n\t);\n\n\treturn updatePriceCache;\n};\n\nexport default useUpdatePriceCache;\n","import { useCallback } from 'react';\n\nimport useUpdatePriceCache from './useUpdatePriceCache';\nimport type { PriceMutationCallbackFn, PriceMutationCallbackFnArgs } from '../types';\nimport { useRelations } from '@eventespresso/services';\n\nconst useOnCreatePrice = (): PriceMutationCallbackFn => {\n\tconst { updateRelations } = useRelations();\n\n\tconst updatePriceCache = useUpdatePriceCache();\n\n\tconst onCreatePrice = useCallback(\n\t\t({ cache, price, prices, priceTypeId }: PriceMutationCallbackFnArgs): void => {\n\t\t\tconst { id: priceId } = price;\n\t\t\tif (priceId && priceTypeId) {\n\t\t\t\tupdateRelations({\n\t\t\t\t\tentity: 'prices',\n\t\t\t\t\tentityId: priceId,\n\t\t\t\t\trelation: 'priceTypes',\n\t\t\t\t\trelationIds: [priceTypeId],\n\t\t\t\t});\n\t\t\t}\n\t\t\t// Update price cache.\n\t\t\tupdatePriceCache({ cache, prices, price, action: 'add' });\n\t\t},\n\t\t[updatePriceCache, updateRelations]\n\t);\n\n\treturn onCreatePrice;\n};\n\nexport default useOnCreatePrice;\n","import { useCallback } from 'react';\n\nimport useUpdatePriceCache from './useUpdatePriceCache';\nimport type { PriceMutationCallbackFn, PriceMutationCallbackFnArgs } from '../types';\nimport { useRelations } from '@eventespresso/services';\n\nconst useOnDeletePrice = (): PriceMutationCallbackFn => {\n\tconst { dropRelations, removeRelation } = useRelations();\n\n\tconst updatePriceCache = useUpdatePriceCache();\n\n\tconst onDeletePrice = useCallback(\n\t\t({ cache, prices, price, deletePermanently }: PriceMutationCallbackFnArgs): void => {\n\t\t\tconst { id: priceId } = price;\n\t\t\tconst action = deletePermanently ? 'remove' : 'update';\n\t\t\tif (priceId && deletePermanently) {\n\t\t\t\t// Remove the price from all tickets relations\n\t\t\t\tremoveRelation({\n\t\t\t\t\tentity: 'prices',\n\t\t\t\t\tentityId: priceId,\n\t\t\t\t\trelation: 'tickets',\n\t\t\t\t});\n\t\t\t\t// Drop all the relations for the price\n\t\t\t\tdropRelations({\n\t\t\t\t\tentity: 'prices',\n\t\t\t\t\tentityId: priceId,\n\t\t\t\t});\n\t\t\t}\n\t\t\t// Update price cache.\n\t\t\tupdatePriceCache({ cache, prices, price: { ...price, isTrashed: true }, action });\n\t\t},\n\t\t[dropRelations, removeRelation, updatePriceCache]\n\t);\n\n\treturn onDeletePrice;\n};\n\nexport default useOnDeletePrice;\n","import { useCallback } from 'react';\n\nimport type { PriceMutationCallbackFn, PriceMutationCallbackFnArgs } from '../types';\nimport { useRelations } from '@eventespresso/services';\n\nconst useOnUpdatePrice = (): PriceMutationCallbackFn => {\n\tconst { updateRelations } = useRelations();\n\n\tconst onUpdatePrice = useCallback(\n\t\t({ price, priceTypeId }: PriceMutationCallbackFnArgs): void => {\n\t\t\tconst { id: priceId } = price;\n\t\t\t// if it's not the optimistic response\n\t\t\t// and priceType has been updated.\n\t\t\tif (priceId && priceTypeId) {\n\t\t\t\t// Make sure to update the priceType relation\n\t\t\t\tupdateRelations({\n\t\t\t\t\tentity: 'prices',\n\t\t\t\t\tentityId: priceId,\n\t\t\t\t\trelation: 'priceTypes',\n\t\t\t\t\trelationIds: [priceTypeId],\n\t\t\t\t});\n\t\t\t}\n\t\t},\n\t\t[updateRelations]\n\t);\n\n\treturn onUpdatePrice;\n};\n\nexport default useOnUpdatePrice;\n","import type { KeysOfType } from '@eventespresso/utils';\nimport { PriceBaseInput } from './types';\n\nexport const NUMERIC_FIELDS: Array> = ['amount', 'order', 'overrides', 'wpUser'];\n\nexport const BOOLEAN_FIELDS: Array> = ['isDefault', 'isTrashed'];\n","import { useCallback } from 'react';\n\nimport { MutationType } from '@eventespresso/data';\nimport { normalizeNumericFields, normalizeBooleanFields, removeNullAndUndefined } from '@eventespresso/utils';\n\nimport useMutationVariables from './useMutationVariables';\nimport useOnCreatePrice from './useOnCreatePrice';\nimport useOnDeletePrice from './useOnDeletePrice';\nimport useOnUpdatePrice from './useOnUpdatePrice';\nimport type { MutationHandler, MutationUpdater } from '../types';\nimport { PricesList, Price } from '../../';\nimport { DEFAULT_PRICE_LIST_DATA as DEFAULT_LIST_DATA, usePriceQueryOptions } from '../../queries';\nimport type { PriceCommonInput } from './types';\nimport { BOOLEAN_FIELDS, NUMERIC_FIELDS } from './constants';\n\ntype MH = MutationHandler;\n\nconst useMutationHandler = (): MH => {\n\tconst options = usePriceQueryOptions();\n\n\tconst onCreatePrice = useOnCreatePrice();\n\tconst onUpdatePrice = useOnUpdatePrice();\n\tconst onDeletePrice = useOnDeletePrice();\n\tconst getMutationVariables = useMutationVariables();\n\n\tconst onUpdate = useCallback>(\n\t\t({ cache, entity: price, input, mutationType }) => {\n\t\t\tconst priceTypeId = input?.priceType;\n\t\t\t// Read the existing data from cache.\n\t\t\tlet data: PricesList;\n\t\t\ttry {\n\t\t\t\tdata = cache.readQuery(options);\n\t\t\t} catch (error) {\n\t\t\t\tdata = null;\n\t\t\t}\n\t\t\tconst prices = data?.espressoPrices || DEFAULT_LIST_DATA;\n\n\t\t\tswitch (mutationType) {\n\t\t\t\tcase MutationType.Create:\n\t\t\t\t\tonCreatePrice({ cache, prices, price, priceTypeId });\n\t\t\t\t\tbreak;\n\t\t\t\tcase MutationType.Update:\n\t\t\t\t\tonUpdatePrice({ price, priceTypeId });\n\t\t\t\t\tbreak;\n\t\t\t\tcase MutationType.Delete:\n\t\t\t\t\tonDeletePrice({ cache, prices, price, deletePermanently: input?.deletePermanently });\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t},\n\t\t[onCreatePrice, onDeletePrice, onUpdatePrice, options]\n\t);\n\n\tconst mutator = useCallback(\n\t\t(mutationType, input) => {\n\t\t\t// Get rid of null or undefined values\n\t\t\tconst filteredInput = removeNullAndUndefined(input);\n\t\t\tlet normalizedInput = normalizeNumericFields(NUMERIC_FIELDS, filteredInput);\n\t\t\t// normalize boolean fields\n\t\t\tnormalizedInput = normalizeBooleanFields(BOOLEAN_FIELDS, normalizedInput);\n\n\t\t\tconst variables = getMutationVariables(mutationType, normalizedInput);\n\n\t\t\treturn { variables, onUpdate };\n\t\t},\n\t\t[getMutationVariables, onUpdate]\n\t);\n\n\treturn mutator;\n};\n\nexport default useMutationHandler;\n","import { useCallback, useMemo } from 'react';\n\nimport { MutationType, MutationFunction, useMutationWithFeedback } from '@eventespresso/data';\n\nimport { TypeName } from '../types';\nimport { CREATE_PRICE, UPDATE_PRICE, DELETE_PRICE } from './';\nimport useMutationHandler from './useMutationHandler';\nimport useUpdateCallback from '../useUpdateCallback';\nimport type { CreatePriceInput, UpdatePriceInput, DeletePriceInput } from './types';\nimport type { CreatePriceResult, UpdatePriceResult, DeletePriceResult } from './types';\nimport { SINGULAR_ENTITY_NAME } from '../../../constants';\n\ninterface PriceMutator {\n\tcreateEntity: MutationFunction;\n\tupdateEntity: MutationFunction;\n\tdeleteEntity: MutationFunction;\n}\n\ntype PM = PriceMutator;\n\nconst usePriceMutator = (id = ''): PM => {\n\tconst createPrice = useMutationWithFeedback({\n\t\ttypeName: SINGULAR_ENTITY_NAME.PRICE,\n\t\tmutationType: MutationType.Create,\n\t\tmutation: CREATE_PRICE,\n\t});\n\n\tconst updatePrice = useMutationWithFeedback({\n\t\ttypeName: SINGULAR_ENTITY_NAME.PRICE,\n\t\tmutationType: MutationType.Update,\n\t\tmutation: UPDATE_PRICE,\n\t});\n\n\tconst deletePrice = useMutationWithFeedback({\n\t\ttypeName: SINGULAR_ENTITY_NAME.PRICE,\n\t\tmutationType: MutationType.Delete,\n\t\tmutation: DELETE_PRICE,\n\t});\n\n\tconst mutationHandler = useMutationHandler();\n\n\tconst getUpdateCallback = useUpdateCallback(TypeName.Price);\n\n\tconst createEntity = useCallback(\n\t\t(input) => {\n\t\t\tconst { onUpdate, ...options } = mutationHandler(MutationType.Create, input);\n\n\t\t\tconst update = getUpdateCallback({ onUpdate, mutationType: MutationType.Create, input });\n\n\t\t\treturn createPrice({ ...options, update });\n\t\t},\n\t\t[createPrice, getUpdateCallback, mutationHandler]\n\t);\n\n\tconst updateEntity = useCallback(\n\t\t(input) => {\n\t\t\tconst { onUpdate, ...options } = mutationHandler(MutationType.Update, { id, ...input });\n\n\t\t\tconst update = getUpdateCallback({ onUpdate, mutationType: MutationType.Update, input });\n\n\t\t\treturn updatePrice({ ...options, update });\n\t\t},\n\t\t[getUpdateCallback, id, mutationHandler, updatePrice]\n\t);\n\n\tconst deleteEntity = useCallback(\n\t\t(input) => {\n\t\t\tconst { onUpdate, ...options } = mutationHandler(MutationType.Delete, { id, ...input });\n\n\t\t\tconst update = getUpdateCallback({ onUpdate, mutationType: MutationType.Delete, input });\n\n\t\t\treturn deletePrice({ ...options, update });\n\t\t},\n\t\t[deletePrice, getUpdateCallback, id, mutationHandler]\n\t);\n\treturn useMemo(() => ({ createEntity, updateEntity, deleteEntity }), [createEntity, deleteEntity, updateEntity]);\n};\n\nexport default usePriceMutator;\n","import { useCallback } from 'react';\n\nimport type { MutationType, MutationInput, OperationVariables } from '@eventespresso/data';\n\nimport { useEventId } from '../../queries/events';\n\ntype MutationVariablesCb = (mutationType: MutationType, input: MutationInput) => OperationVariables;\n\nconst useMutationVariables = (): MutationVariablesCb => {\n\tconst eventId = useEventId();\n\n\treturn useCallback(\n\t\t(mutationType, input) => {\n\t\t\tconst mutationInput: MutationInput = {\n\t\t\t\tclientMutationId: `${mutationType}_DATETIME`,\n\t\t\t\t...input,\n\t\t\t};\n\n\t\t\tif (mutationType === 'CREATE') {\n\t\t\t\tmutationInput.eventId = eventId; // required for createDatetime\n\t\t\t}\n\n\t\t\treturn {\n\t\t\t\tinput: mutationInput,\n\t\t\t};\n\t\t},\n\t\t[eventId]\n\t);\n};\n\nexport default useMutationVariables;\n","import { useCallback } from 'react';\n\nimport updateTicketCache from './updateTicketCache';\nimport useUpdateDatetimeCache from './useUpdateDatetimeCache';\nimport type { DatetimeMutationCallbackFn, DatetimeMutationCallbackFnArgs } from '../types';\nimport { useRelations } from '@eventespresso/services';\nimport { getGuids, hasTempId } from '@eventespresso/predicates';\n\nconst useOnCreateDatetime = (): DatetimeMutationCallbackFn => {\n\tconst { updateRelations, addRelation } = useRelations();\n\n\tconst updateDatetimeCache = useUpdateDatetimeCache();\n\n\tconst onCreateDatetime = useCallback(\n\t\t({ cache, datetimes, datetime, tickets }: DatetimeMutationCallbackFnArgs): void => {\n\t\t\tif (!hasTempId(datetime)) {\n\t\t\t\tconst { nodes = [] } = datetimes;\n\t\t\t\tconst datetimeIn = getGuids(nodes).sort();\n\t\t\t\tconst { id: datetimeId } = datetime;\n\n\t\t\t\t// Update tickets cache for the changed datetimes,\n\t\t\t\t// to avoid refetching of tickets.\n\t\t\t\tupdateTicketCache({ cache, datetimeIn, datetimeId, action: 'add' });\n\n\t\t\t\t// if we have related tickets\n\t\t\t\tif (tickets?.length) {\n\t\t\t\t\tupdateRelations({\n\t\t\t\t\t\tentity: 'datetimes',\n\t\t\t\t\t\tentityId: datetimeId,\n\t\t\t\t\t\trelation: 'tickets',\n\t\t\t\t\t\trelationIds: tickets,\n\t\t\t\t\t});\n\t\t\t\t\ttickets.forEach((entityId: string) => {\n\t\t\t\t\t\taddRelation({\n\t\t\t\t\t\t\tentity: 'tickets',\n\t\t\t\t\t\t\tentityId,\n\t\t\t\t\t\t\trelation: 'datetimes',\n\t\t\t\t\t\t\trelationId: datetimeId,\n\t\t\t\t\t\t});\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t}\n\t\t\t// Update datetime cache after tickets cache is updated.\n\t\t\tupdateDatetimeCache({ cache, datetimes, datetime, action: 'add' });\n\t\t},\n\t\t[addRelation, updateDatetimeCache, updateRelations]\n\t);\n\n\treturn onCreateDatetime;\n};\n\nexport default useOnCreateDatetime;\n","import { useCallback } from 'react';\n\nimport { MutationType, MutationInput } from '@eventespresso/data';\nimport { PLUS_ONE_MONTH, PLUS_TWO_MONTHS } from '@eventespresso/constants';\nimport { ucFirst, uuid } from '@eventespresso/utils';\nimport type { Datetime } from '../../types';\nimport { useLazyDatetime } from '../../queries';\n\nexport const DATETIME_DEFAULTS: Datetime = {\n\t__typename: 'EspressoDatetime',\n\tid: '',\n\tdbId: 0,\n\tcacheId: '',\n\tcapacity: -1,\n\tdescription: '',\n\tendDate: PLUS_TWO_MONTHS.toISOString(),\n\tisActive: false,\n\tisExpired: false,\n\tisPrimary: false,\n\tisSoldOut: false,\n\tisTrashed: false,\n\tisUpcoming: false,\n\tlength: 0,\n\tname: '',\n\torder: 0,\n\treserved: 0,\n\tsold: 0,\n\tstartDate: PLUS_ONE_MONTH.toISOString(),\n\tstatus: null,\n\tvenue: '',\n};\n\ntype OptimisticResCb = (mutationType: MutationType, input: MutationInput) => any;\n\nconst useOptimisticResponse = (): OptimisticResCb => {\n\tconst getDatetime = useLazyDatetime();\n\n\treturn useCallback(\n\t\t(mutationType, input) => {\n\t\t\tlet espressoDatetime: Partial = {\n\t\t\t\t__typename: 'EspressoDatetime',\n\t\t\t};\n\n\t\t\tconst datetime = getDatetime(input.id);\n\t\t\tconst cacheId = `temp:${uuid()}`;\n\n\t\t\tswitch (mutationType) {\n\t\t\t\tcase MutationType.Create:\n\t\t\t\t\tespressoDatetime = {\n\t\t\t\t\t\t...espressoDatetime,\n\t\t\t\t\t\t...DATETIME_DEFAULTS,\n\t\t\t\t\t\tcacheId,\n\t\t\t\t\t\t// make sure the id is generated on each call to make sure\n\t\t\t\t\t\t// it is unique for each entity created in bulk\n\t\t\t\t\t\tid: cacheId,\n\t\t\t\t\t\t...input,\n\t\t\t\t\t};\n\t\t\t\t\tbreak;\n\t\t\t\tcase MutationType.Delete:\n\t\t\t\t\tespressoDatetime = {\n\t\t\t\t\t\t...espressoDatetime,\n\t\t\t\t\t\t...DATETIME_DEFAULTS, // to avoid pollution of test console\n\t\t\t\t\t\t...datetime,\n\t\t\t\t\t\t...input,\n\t\t\t\t\t\tisTrashed: true,\n\t\t\t\t\t\tcacheId,\n\t\t\t\t\t};\n\t\t\t\t\tbreak;\n\t\t\t\tcase MutationType.Update:\n\t\t\t\t\tespressoDatetime = {\n\t\t\t\t\t\t...espressoDatetime,\n\t\t\t\t\t\t...datetime,\n\t\t\t\t\t\t...input,\n\t\t\t\t\t\tcacheId,\n\t\t\t\t\t};\n\t\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tconst lcMutationtype = mutationType.toLowerCase();\n\t\t\tconst ucFirstMutationtype = ucFirst(lcMutationtype);\n\n\t\t\t// e.g. \"deleteEspressoDatetime\", \"createEspressoDatetime\"\n\t\t\tconst mutation = `${lcMutationtype}EspressoDatetime`;\n\n\t\t\treturn {\n\t\t\t\t__typename: 'RootMutation',\n\t\t\t\t[mutation]: {\n\t\t\t\t\t__typename: `${ucFirstMutationtype}EspressoDatetimePayload`,\n\t\t\t\t\tespressoDatetime,\n\t\t\t\t},\n\t\t\t};\n\t\t},\n\t\t[getDatetime]\n\t);\n};\n\nexport default useOptimisticResponse;\n","import type { KeysOfType } from '@eventespresso/utils';\nimport type { DatetimeBaseInput } from './types';\n\nexport const NUMERIC_FIELDS: Array> = [\n\t'capacity',\n\t'eventId',\n\t'order',\n\t'reserved',\n\t'sold',\n];\n","import { useCallback } from 'react';\n\nimport { normalizeNumericFields, removeNullAndUndefined } from '@eventespresso/utils';\nimport { MutationType } from '@eventespresso/data';\n\nimport useMutationVariables from './useMutationVariables';\nimport useOnCreateDatetime from './useOnCreateDatetime';\nimport useOnDeleteDatetime from './useOnDeleteDatetime';\nimport useOnUpdateDatetime from './useOnUpdateDatetime';\nimport useOptimisticResponse from './useOptimisticResponse';\nimport { DEFAULT_DATETIME_LIST_DATA as DEFAULT_LIST_DATA } from '../../queries';\nimport type { DatetimesList, Datetime } from '../../types';\nimport type { MutationHandler, MutationUpdater } from '../types';\nimport { useDatetimeQueryOptions } from '../../queries/datetimes';\nimport type { DatetimeCommonInput } from './types';\nimport { NUMERIC_FIELDS } from './constants';\n\ntype MH = MutationHandler;\n\nconst useMutationHandler = (): MH => {\n\tconst options = useDatetimeQueryOptions();\n\n\tconst onCreateDatetime = useOnCreateDatetime();\n\tconst onUpdateDatetime = useOnUpdateDatetime();\n\tconst onDeleteDatetime = useOnDeleteDatetime();\n\n\tconst getMutationVariables = useMutationVariables();\n\tconst getOptimisticResponse = useOptimisticResponse();\n\n\tconst onUpdate = useCallback>(\n\t\t({ cache, entity: datetime, input, mutationType }) => {\n\t\t\t// Read the existing data from cache.\n\t\t\tlet data: DatetimesList;\n\t\t\ttry {\n\t\t\t\tdata = cache.readQuery(options);\n\t\t\t} catch (error) {\n\t\t\t\tdata = null;\n\t\t\t}\n\t\t\tconst datetimes = data?.espressoDatetimes || DEFAULT_LIST_DATA;\n\t\t\tconst tickets = input?.tickets;\n\n\t\t\tswitch (mutationType) {\n\t\t\t\tcase MutationType.Create:\n\t\t\t\t\tonCreateDatetime({ cache, datetimes, datetime, tickets });\n\t\t\t\t\tbreak;\n\t\t\t\tcase MutationType.Update:\n\t\t\t\t\tonUpdateDatetime({ datetime, tickets });\n\t\t\t\t\tbreak;\n\t\t\t\tcase MutationType.Delete:\n\t\t\t\t\tonDeleteDatetime({ cache, datetimes, datetime, deletePermanently: input?.deletePermanently });\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t},\n\t\t[onCreateDatetime, onDeleteDatetime, onUpdateDatetime, options]\n\t);\n\n\tconst mutationHandler = useCallback(\n\t\t(mutationType, input) => {\n\t\t\t// Get rid of null or undefined values\n\t\t\tconst filteredInput = removeNullAndUndefined(input);\n\t\t\t// normalize numeric fields\n\t\t\tconst normalizedInput = normalizeNumericFields(NUMERIC_FIELDS, filteredInput);\n\n\t\t\tconst variables = getMutationVariables(mutationType, normalizedInput);\n\t\t\tconst optimisticResponse = getOptimisticResponse(mutationType, normalizedInput);\n\n\t\t\treturn { variables, optimisticResponse, onUpdate };\n\t\t},\n\t\t[getMutationVariables, getOptimisticResponse, onUpdate]\n\t);\n\n\treturn mutationHandler;\n};\n\nexport default useMutationHandler;\n","import { useCallback, useMemo } from 'react';\n\nimport { MutationType, useMutationWithFeedback } from '@eventespresso/data';\n\nimport type { DatetimeMutator } from './types';\nimport { CREATE_DATETIME, UPDATE_DATETIME, DELETE_DATETIME } from './';\nimport useMutationHandler from './useMutationHandler';\nimport useUpdateCallback from '../useUpdateCallback';\nimport { TypeName } from '../types';\nimport { SINGULAR_ENTITY_NAME } from '../../../constants';\n\ntype DM = DatetimeMutator;\n\nconst useDatetimeMutator = (id = ''): DM => {\n\tconst createDatetime = useMutationWithFeedback({\n\t\ttypeName: SINGULAR_ENTITY_NAME.DATETIME,\n\t\tmutationType: MutationType.Create,\n\t\tmutation: CREATE_DATETIME,\n\t});\n\n\tconst updateDatetime = useMutationWithFeedback({\n\t\ttypeName: SINGULAR_ENTITY_NAME.DATETIME,\n\t\tmutationType: MutationType.Update,\n\t\tmutation: UPDATE_DATETIME,\n\t});\n\n\tconst deleteDatetime = useMutationWithFeedback({\n\t\ttypeName: SINGULAR_ENTITY_NAME.DATETIME,\n\t\tmutationType: MutationType.Delete,\n\t\tmutation: DELETE_DATETIME,\n\t});\n\n\tconst mutationHandler = useMutationHandler();\n\n\tconst getUpdateCallback = useUpdateCallback(TypeName.Datetime);\n\n\tconst createEntity = useCallback(\n\t\t(input) => {\n\t\t\tconst { onUpdate, ...options } = mutationHandler(MutationType.Create, input);\n\n\t\t\tconst update = getUpdateCallback({ onUpdate, mutationType: MutationType.Create, input });\n\n\t\t\treturn createDatetime({ ...options, update });\n\t\t},\n\t\t[createDatetime, getUpdateCallback, mutationHandler]\n\t);\n\n\tconst updateEntity = useCallback(\n\t\t(input) => {\n\t\t\tconst { onUpdate, ...options } = mutationHandler(MutationType.Update, { id, ...input });\n\n\t\t\tconst update = getUpdateCallback({ onUpdate, mutationType: MutationType.Update, input });\n\n\t\t\treturn updateDatetime({ ...options, update });\n\t\t},\n\t\t[getUpdateCallback, id, mutationHandler, updateDatetime]\n\t);\n\n\tconst deleteEntity = useCallback(\n\t\t(input) => {\n\t\t\tconst { onUpdate, ...options } = mutationHandler(MutationType.Delete, { id, ...input });\n\n\t\t\tconst update = getUpdateCallback({ onUpdate, mutationType: MutationType.Delete, input });\n\n\t\t\treturn deleteDatetime({ ...options, update });\n\t\t},\n\t\t[deleteDatetime, getUpdateCallback, id, mutationHandler]\n\t);\n\treturn useMemo(() => ({ createEntity, updateEntity, deleteEntity }), [createEntity, deleteEntity, updateEntity]);\n};\n\nexport default useDatetimeMutator;\n","import { useCallback } from 'react';\n\nimport type { MutationType, MutationInput, OperationVariables } from '@eventespresso/data';\n\ntype MutationVariablesCb = (mutationType: MutationType, input: MutationInput) => OperationVariables;\n\nconst useMutationVariables = (): MutationVariablesCb => {\n\treturn useCallback((mutationType, input) => {\n\t\tconst mutationInput: MutationInput = {\n\t\t\tclientMutationId: `${mutationType}_TICKET`,\n\t\t\t...input,\n\t\t};\n\n\t\treturn {\n\t\t\tinput: mutationInput,\n\t\t};\n\t}, []);\n};\n\nexport default useMutationVariables;\n","import { useCallback } from 'react';\n\nimport { useRelations } from '@eventespresso/services';\nimport { getGuids, hasTempId } from '@eventespresso/predicates';\nimport updatePriceCache from './updatePriceCache';\nimport useUpdateTicketCache from './useUpdateTicketCache';\nimport type { TicketMutationCallbackFn, TicketMutationCallbackFnArgs } from '../types';\n\nconst useOnCreateTicket = (): TicketMutationCallbackFn => {\n\tconst { addRelation, updateRelations } = useRelations();\n\n\tconst updateTicketCache = useUpdateTicketCache();\n\n\tconst onCreateTicket = useCallback(\n\t\t({ cache, datetimeIds, ticket, tickets, prices }: TicketMutationCallbackFnArgs): void => {\n\t\t\tif (!hasTempId(ticket)) {\n\t\t\t\tconst { nodes = [] } = tickets;\n\t\t\t\tconst ticketIn = getGuids(nodes);\n\t\t\t\tconst { id: ticketId } = ticket;\n\n\t\t\t\t// Update prices cache for the changed tickets,\n\t\t\t\t// to avoid refetching of prices.\n\t\t\t\tupdatePriceCache({ cache, prices, ticketIn, ticketId, action: 'add' });\n\n\t\t\t\t// if related datetimes are passed\n\t\t\t\tif (datetimeIds?.length) {\n\t\t\t\t\t// Set relations with datetimes\n\t\t\t\t\tupdateRelations({\n\t\t\t\t\t\tentity: 'tickets',\n\t\t\t\t\t\tentityId: ticketId,\n\t\t\t\t\t\trelation: 'datetimes',\n\t\t\t\t\t\trelationIds: datetimeIds,\n\t\t\t\t\t});\n\t\t\t\t\tdatetimeIds.forEach((entityId: string) => {\n\t\t\t\t\t\taddRelation({\n\t\t\t\t\t\t\tentity: 'datetimes',\n\t\t\t\t\t\t\tentityId,\n\t\t\t\t\t\t\trelation: 'tickets',\n\t\t\t\t\t\t\trelationId: ticketId,\n\t\t\t\t\t\t});\n\t\t\t\t\t});\n\t\t\t\t}\n\n\t\t\t\t// Set relations with prices\n\t\t\t\tconst priceIds = getGuids(prices?.nodes || []);\n\t\t\t\tif (priceIds.length) {\n\t\t\t\t\tupdateRelations({\n\t\t\t\t\t\tentity: 'tickets',\n\t\t\t\t\t\tentityId: ticketId,\n\t\t\t\t\t\trelation: 'prices',\n\t\t\t\t\t\trelationIds: priceIds,\n\t\t\t\t\t});\n\t\t\t\t\tpriceIds.forEach((entityId: string) => {\n\t\t\t\t\t\taddRelation({\n\t\t\t\t\t\t\tentity: 'prices',\n\t\t\t\t\t\t\tentityId,\n\t\t\t\t\t\t\trelation: 'tickets',\n\t\t\t\t\t\t\trelationId: ticketId,\n\t\t\t\t\t\t});\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t}\n\t\t\t// Update ticket cache after price cache is updated.\n\t\t\tupdateTicketCache({ cache, tickets, ticket, action: 'add' });\n\t\t},\n\t\t[addRelation, updateRelations, updateTicketCache]\n\t);\n\n\treturn onCreateTicket;\n};\n\nexport default useOnCreateTicket;\n","import { useCallback } from 'react';\n\nimport { MutationType, MutationInput } from '@eventespresso/data';\nimport { PLUS_ONE_MONTH, PLUS_TWO_MONTHS } from '@eventespresso/constants';\nimport { ucFirst, uuid } from '@eventespresso/utils';\n\nimport type { Ticket } from '../../';\nimport { useLazyTicket } from '../../queries';\n\nexport const TICKET_DEFAULTS: Ticket = {\n\tid: '',\n\tdbId: 0,\n\tcacheId: '',\n\tdescription: '',\n\tendDate: PLUS_TWO_MONTHS.toISOString(),\n\tisSoldOut: false,\n\tisTrashed: false,\n\tisDefault: false,\n\tisExpired: false,\n\tisFree: false,\n\tisOnSale: false,\n\tisPending: true,\n\tisRequired: false,\n\tmax: -1,\n\tmin: 0,\n\tname: '',\n\torder: 0,\n\tprice: null,\n\tprices: null,\n\tquantity: -1,\n\tregistrationCount: 0,\n\treserved: 0,\n\treverseCalculate: true,\n\tsold: 0,\n\tstartDate: PLUS_ONE_MONTH.toISOString(),\n\tuserId: '',\n\tuses: -1,\n\tvisibility: 'PUBLIC',\n};\n\ntype OptimisticResCb = (mutationType: MutationType, input: MutationInput) => any;\n\nconst useOptimisticResponse = (): OptimisticResCb => {\n\tconst getTicket = useLazyTicket();\n\n\treturn useCallback(\n\t\t(mutationType, input) => {\n\t\t\tlet espressoTicket: Partial = {\n\t\t\t\t__typename: 'EspressoTicket',\n\t\t\t};\n\t\t\tconst ticket = getTicket(input.id);\n\t\t\tconst cacheId = `temp:${uuid()}`;\n\n\t\t\tswitch (mutationType) {\n\t\t\t\tcase MutationType.Create:\n\t\t\t\t\tespressoTicket = {\n\t\t\t\t\t\t...espressoTicket,\n\t\t\t\t\t\t...TICKET_DEFAULTS,\n\t\t\t\t\t\tcacheId,\n\t\t\t\t\t\t// make sure the id is generated on each call to make sure\n\t\t\t\t\t\t// it is unique for each entity created in bulk\n\t\t\t\t\t\tid: cacheId,\n\t\t\t\t\t\t...input,\n\t\t\t\t\t\tprices: null,\n\t\t\t\t\t};\n\t\t\t\t\tbreak;\n\t\t\t\tcase MutationType.Delete:\n\t\t\t\t\tespressoTicket = {\n\t\t\t\t\t\t...espressoTicket,\n\t\t\t\t\t\t...TICKET_DEFAULTS, // to avoid pollution of test console\n\t\t\t\t\t\t...ticket,\n\t\t\t\t\t\t...input,\n\t\t\t\t\t\tisTrashed: true,\n\t\t\t\t\t\tcacheId,\n\t\t\t\t\t};\n\t\t\t\t\tbreak;\n\t\t\t\tcase MutationType.Update:\n\t\t\t\t\tespressoTicket = {\n\t\t\t\t\t\t...espressoTicket,\n\t\t\t\t\t\t...ticket,\n\t\t\t\t\t\t...input,\n\t\t\t\t\t\tcacheId,\n\t\t\t\t\t\tprices: null,\n\t\t\t\t\t};\n\t\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tconst lcMutationtype = mutationType.toLowerCase();\n\t\t\tconst ucFirstMutationtype = ucFirst(lcMutationtype);\n\n\t\t\t// e.g. \"deleteEspressoTicket\", \"createEspressoTicket\"\n\t\t\tconst mutation = `${lcMutationtype}EspressoTicket`;\n\n\t\t\treturn {\n\t\t\t\t__typename: 'RootMutation',\n\t\t\t\t[mutation]: {\n\t\t\t\t\t__typename: `${ucFirstMutationtype}EspressoTicketPayload`,\n\t\t\t\t\tespressoTicket,\n\t\t\t\t},\n\t\t\t};\n\t\t},\n\t\t[getTicket]\n\t);\n};\n\nexport default useOptimisticResponse;\n","import type { KeysOfType } from '@eventespresso/utils';\nimport { TicketBaseInput } from './types';\n\nexport const NUMERIC_FIELDS: Array> = [\n\t'max',\n\t'min',\n\t'order',\n\t'price',\n\t'quantity',\n\t'reserved',\n\t'row',\n\t'sold',\n\t'uses',\n\t'wpUser',\n];\n\nexport const BOOLEAN_FIELDS: Array> = [\n\t'isDefault',\n\t'isRequired',\n\t'isTrashed',\n\t'reverseCalculate',\n];\n","import { useCallback } from 'react';\n\nimport { getGuids } from '@eventespresso/predicates';\nimport { MutationType } from '@eventespresso/data';\nimport { normalizeBooleanFields, normalizeNumericFields, removeNullAndUndefined } from '@eventespresso/utils';\n\nimport useMutationVariables from './useMutationVariables';\nimport useOnCreateTicket from './useOnCreateTicket';\nimport useOnDeleteTicket from './useOnDeleteTicket';\nimport useOnUpdateTicket from './useOnUpdateTicket';\nimport useOptimisticResponse from './useOptimisticResponse';\nimport { hooks } from '../../../ioc';\nimport { DEFAULT_TICKET_LIST_DATA as DEFAULT_LIST_DATA, useTicketQueryOptions } from '../../queries';\nimport type { MutationHandler, MutationUpdater } from '../types';\nimport { TicketsList, Ticket } from '../../';\nimport type { TicketCommonInput } from './types';\nimport { BOOLEAN_FIELDS, NUMERIC_FIELDS } from './constants';\nimport useAffectedDatesQueries from './useAffectedDatesQueries';\n\ntype MH = MutationHandler;\n\nconst useMutationHandler = (): MH => {\n\tconst queryOptions = useTicketQueryOptions();\n\n\tconst onCreateTicket = useOnCreateTicket();\n\tconst onUpdateTicket = useOnUpdateTicket();\n\tconst onDeleteTicket = useOnDeleteTicket();\n\tconst affectedDatesQueries = useAffectedDatesQueries();\n\n\tconst getMutationVariables = useMutationVariables();\n\tconst getOptimisticResponse = useOptimisticResponse();\n\n\tconst onUpdate = useCallback>(\n\t\t({ cache, entity, input, mutationType }) => {\n\t\t\t// extract prices data to avoid\n\t\t\t// it going to tickets cache\n\t\t\tconst { prices, ...ticket } = entity;\n\n\t\t\t// Read the existing data from cache.\n\t\t\tlet data: TicketsList;\n\t\t\ttry {\n\t\t\t\tdata = cache.readQuery(queryOptions);\n\t\t\t} catch (error) {\n\t\t\t\tdata = null;\n\t\t\t}\n\t\t\tconst tickets = data?.espressoTickets || DEFAULT_LIST_DATA;\n\t\t\tconst datetimeIds = input?.datetimes;\n\n\t\t\tconst priceIds: string[] = prices?.nodes ? getGuids(prices.nodes) : null;\n\n\t\t\tswitch (mutationType) {\n\t\t\t\tcase MutationType.Create:\n\t\t\t\t\tonCreateTicket({ cache, tickets, ticket, datetimeIds, prices });\n\t\t\t\t\tbreak;\n\t\t\t\tcase MutationType.Update:\n\t\t\t\t\tonUpdateTicket({ cache, tickets, ticket, datetimeIds, priceIds });\n\t\t\t\t\tbreak;\n\t\t\t\tcase MutationType.Delete:\n\t\t\t\t\tonDeleteTicket({ cache, tickets, ticket, deletePermanently: input?.deletePermanently });\n\t\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\thooks.doAction('eventEditor.ticket.mutation', mutationType, input, entity, cache);\n\t\t},\n\t\t[onCreateTicket, onDeleteTicket, onUpdateTicket, queryOptions]\n\t);\n\tconst mutator = useCallback(\n\t\t(mutationType, input) => {\n\t\t\t// Get rid of null or undefined values\n\t\t\tconst filteredInput = removeNullAndUndefined(input);\n\t\t\t// normalize numeric fields\n\t\t\tlet normalizedInput = normalizeNumericFields(NUMERIC_FIELDS, filteredInput);\n\t\t\t// normalize boolean fields\n\t\t\tnormalizedInput = normalizeBooleanFields(BOOLEAN_FIELDS, normalizedInput);\n\n\t\t\tconst variables = getMutationVariables(mutationType, normalizedInput);\n\n\t\t\tif (input.isDefault) {\n\t\t\t\t// no optimistic response for default tickets\n\t\t\t\treturn { variables, onUpdate };\n\t\t\t}\n\n\t\t\tconst refetchQueries = affectedDatesQueries({ input, mutationType });\n\n\t\t\tconst optimisticResponse = getOptimisticResponse(mutationType, normalizedInput);\n\n\t\t\treturn { variables, optimisticResponse, onUpdate, refetchQueries };\n\t\t},\n\t\t[affectedDatesQueries, getMutationVariables, getOptimisticResponse, onUpdate]\n\t);\n\n\treturn mutator;\n};\n\nexport default useMutationHandler;\n","import { useCallback, useMemo } from 'react';\n\nimport { MutationType, MutationFunction, useMutationWithFeedback } from '@eventespresso/data';\n\nimport type { CreateTicketInput, UpdateTicketInput, DeleteTicketInput } from './types';\nimport { CREATE_TICKET, UPDATE_TICKET, DELETE_TICKET } from './';\nimport useMutationHandler from './useMutationHandler';\nimport useUpdateCallback from '../useUpdateCallback';\nimport { TypeName } from '../types';\nimport type { CreateTicketResult, UpdateTicketResult, DeleteTicketResult } from './types';\nimport { SINGULAR_ENTITY_NAME } from '../../../constants';\n\ninterface TicketMutator {\n\tcreateEntity: MutationFunction;\n\tupdateEntity: MutationFunction;\n\tdeleteEntity: MutationFunction;\n}\n\ntype TM = TicketMutator;\n\nconst useTicketMutator = (id = ''): TM => {\n\tconst createTicket = useMutationWithFeedback({\n\t\ttypeName: SINGULAR_ENTITY_NAME.TICKET,\n\t\tmutationType: MutationType.Create,\n\t\tmutation: CREATE_TICKET,\n\t});\n\n\tconst updateTicket = useMutationWithFeedback({\n\t\ttypeName: SINGULAR_ENTITY_NAME.TICKET,\n\t\tmutationType: MutationType.Update,\n\t\tmutation: UPDATE_TICKET,\n\t});\n\n\tconst deleteTicket = useMutationWithFeedback({\n\t\ttypeName: SINGULAR_ENTITY_NAME.TICKET,\n\t\tmutationType: MutationType.Delete,\n\t\tmutation: DELETE_TICKET,\n\t});\n\n\tconst mutationHandler = useMutationHandler();\n\n\tconst getUpdateCallback = useUpdateCallback(TypeName.Ticket);\n\n\tconst createEntity = useCallback(\n\t\t(input) => {\n\t\t\tconst { onUpdate, ...options } = mutationHandler(MutationType.Create, input);\n\n\t\t\tconst update = getUpdateCallback({ onUpdate, mutationType: MutationType.Create, input });\n\n\t\t\treturn createTicket({ ...options, update });\n\t\t},\n\t\t[createTicket, getUpdateCallback, mutationHandler]\n\t);\n\n\tconst updateEntity = useCallback(\n\t\t(input) => {\n\t\t\tconst { onUpdate, ...options } = mutationHandler(MutationType.Update, { id, ...input });\n\n\t\t\tconst update = getUpdateCallback({ onUpdate, mutationType: MutationType.Update, input });\n\n\t\t\treturn updateTicket({ ...options, update });\n\t\t},\n\t\t[getUpdateCallback, id, mutationHandler, updateTicket]\n\t);\n\n\tconst deleteEntity = useCallback(\n\t\t(input) => {\n\t\t\tconst { onUpdate, ...options } = mutationHandler(MutationType.Delete, { id, ...input });\n\n\t\t\tconst update = getUpdateCallback({ onUpdate, mutationType: MutationType.Delete, input });\n\n\t\t\treturn deleteTicket({ ...options, update });\n\t\t},\n\t\t[deleteTicket, getUpdateCallback, id, mutationHandler]\n\t);\n\treturn useMemo(() => ({ createEntity, updateEntity, deleteEntity }), [createEntity, deleteEntity, updateEntity]);\n};\n\nexport default useTicketMutator;\n","import * as yup from 'yup';\n\nimport { endDateAfterStartDateErrorMessage, mayBeAdjustEndDate } from '@eventespresso/dates';\nimport { __ } from '@eventespresso/i18n';\nimport { Decorator } from '@eventespresso/form';\n\nexport const startAndEndDateFixer: Decorator = (form) => {\n\tlet previousValues: any = {};\n\n\tconst unsubscribe = form.subscribe(\n\t\t({ values }) => {\n\t\t\tform.batch(() => {\n\t\t\t\tconst { endDate, startDate } = values;\n\n\t\t\t\tconst prevStartDate = previousValues.startDate;\n\t\t\t\tconst prevEndDate = previousValues.endDate;\n\n\t\t\t\tconst startDateChanged = startDate !== prevStartDate;\n\t\t\t\tconst endDateChanged = endDate !== prevEndDate;\n\n\t\t\t\tconst isEndDateNotPristine = !form.getFieldState('endDate')?.pristine;\n\t\t\t\tconst changedFromStartDate = form.getFieldState('endDate')?.data?.changedFromStartDate;\n\n\t\t\t\tif (startDateChanged) {\n\t\t\t\t\t// there should be no notice unless things are not in order\n\t\t\t\t\tlet endDateFieldNotice: string;\n\n\t\t\t\t\tconst newEndDate = mayBeAdjustEndDate({\n\t\t\t\t\t\tnewEndDate: endDate,\n\t\t\t\t\t\tnewStartDate: startDate,\n\t\t\t\t\t\tprevEndDate,\n\t\t\t\t\t\tprevStartDate,\n\t\t\t\t\t});\n\t\t\t\t\t// if end date has been adjusted\n\t\t\t\t\tif (newEndDate !== endDate) {\n\t\t\t\t\t\tform.change('endDate', newEndDate);\n\t\t\t\t\t\tform.mutators.setFieldData('endDate', { changedFromStartDate: true });\n\t\t\t\t\t\tendDateFieldNotice = __('End date has been adjusted');\n\t\t\t\t\t}\n\n\t\t\t\t\tform.mutators.setFieldData('endDate', { fieldNotice: endDateFieldNotice });\n\t\t\t\t}\n\n\t\t\t\tif (endDateChanged) {\n\t\t\t\t\tif (isEndDateNotPristine && !changedFromStartDate) {\n\t\t\t\t\t\tform.mutators.setFieldData('endDate', { fieldNotice: null });\n\t\t\t\t\t}\n\n\t\t\t\t\tform.mutators.setFieldData('endDate', { changedFromStartDate: false });\n\t\t\t\t}\n\t\t\t});\n\t\t\tpreviousValues = values;\n\t\t},\n\t\t{ values: true }\n\t);\n\treturn unsubscribe;\n};\n\nexport const requiredMessage = (): string => __('Required');\n\nexport const datesSchema = {\n\tstartDate: yup\n\t\t.date()\n\t\t.required(() => __('Start Date is required'))\n\t\t.typeError(requiredMessage),\n\tendDate: yup\n\t\t.date()\n\t\t.required(() => __('End Date is required'))\n\t\t.typeError(requiredMessage)\n\t\t.when(['startDate'], (startDate: Date, schema: yup.DateSchema) => {\n\t\t\treturn schema.min(startDate, () => endDateAfterStartDateErrorMessage);\n\t\t}),\n};\n","import { DisplayStartOrEndDate } from '../filterState';\nimport type { Cell } from '@eventespresso/ui-components';\n\nexport const filterCellByStartOrEndDate =\n\t(displayStartOrEndDate: DisplayStartOrEndDate) =>\n\t(cell: Cell): boolean => {\n\t\tif (displayStartOrEndDate === DisplayStartOrEndDate.start && cell.key === 'end') {\n\t\t\treturn false;\n\t\t}\n\n\t\tif (displayStartOrEndDate === DisplayStartOrEndDate.end && cell.key === 'start') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t};\n","import { EventEditorData } from '../types';\n\nexport const getEdtrDomData = (key: K): EventEditorData[K] => {\n\treturn window.eventEspressoData.eventEditor?.[key];\n};\n","import { useMemo } from 'react';\nimport { EditorData } from '../../types';\n\nconst useCacheRehydrationData = (): EditorData => {\n\treturn useMemo(() => {\n\t\tconst { currentUser, generalSettings } = window?.eventEspressoData?.config || {};\n\t\tconst eventEditor = window?.eventEspressoData?.eventEditor || {};\n\n\t\treturn { currentUser, eventEditor, generalSettings };\n\t}, []);\n};\n\nexport default useCacheRehydrationData;\n","import { useEffect } from 'react';\n\nimport { useRelations, useStatus, TypeName } from '@eventespresso/services';\nimport {\n\tuseCurrentUserQueryOptions,\n\tuseGeneralSettingsQueryOptions,\n\tuseUpdateCache,\n\tuseUpdateCurrentUserCache,\n\tuseUpdateGeneralSettingsCache,\n\tuseIsRehydrated,\n} from '@eventespresso/data';\n\nimport useCacheRehydrationData from './useCacheRehydrationData';\nimport {\n\tuseUpdateDatetimeList,\n\tuseUpdatePriceList,\n\tuseUpdatePriceTypeList,\n\tuseUpdateTicketList,\n\tuseUpdateVenueList,\n} from '../../hooks';\nimport {\n\tDEFAULT_DATETIME_LIST_DATA,\n\tDEFAULT_TICKET_LIST_DATA,\n\tDEFAULT_PRICE_LIST_DATA,\n\tDEFAULT_PRICE_TYPE_LIST_DATA,\n\tDEFAULT_VENUE_LIST_DATA,\n\tuseDatetimeQueryOptions,\n\tuseEventQueryOptions,\n\tusePriceQueryOptions,\n\tusePriceTypeQueryOptions,\n\tuseTicketQueryOptions,\n\tuseVenueQueryOptions,\n} from '../queries';\n\nconst useCacheRehydration = (): boolean => {\n\tconst { setIsLoaded } = useStatus();\n\tconst { initialize: initializeRelations, isInitialized: relationsInitialized } = useRelations();\n\tconst { currentUser, eventEditor, generalSettings } = useCacheRehydrationData();\n\tconst [isRehydrated, setIsRehydrated] = useIsRehydrated();\n\tconst {\n\t\tevent,\n\t\tdatetimes: espressoDatetimes = DEFAULT_DATETIME_LIST_DATA,\n\t\ttickets: espressoTickets = DEFAULT_TICKET_LIST_DATA,\n\t\tprices: espressoPrices = DEFAULT_PRICE_LIST_DATA,\n\t\tpriceTypes: espressoPriceTypes = DEFAULT_PRICE_TYPE_LIST_DATA,\n\t\tvenues: espressoVenues = DEFAULT_VENUE_LIST_DATA,\n\t\trelations,\n\t} = eventEditor;\n\n\tconst priceTypeQueryOptions = usePriceTypeQueryOptions();\n\tconst updatePriceTypeList = useUpdatePriceTypeList();\n\n\tconst datetimeQueryOptions = useDatetimeQueryOptions();\n\tconst updateDatetimeList = useUpdateDatetimeList();\n\n\tconst ticketQueryOptions = useTicketQueryOptions();\n\tconst updateTicketList = useUpdateTicketList();\n\n\tconst priceQueryOptions = usePriceQueryOptions();\n\tconst updatePriceList = useUpdatePriceList();\n\n\tconst venueQueryOptions = useVenueQueryOptions();\n\tconst updateVenueList = useUpdateVenueList();\n\n\tconst currentUserQueryOptions = useCurrentUserQueryOptions();\n\tconst updateCurrentUser = useUpdateCurrentUserCache();\n\n\tconst generalSettingsQueryOptions = useGeneralSettingsQueryOptions();\n\tconst updateGeneralSettings = useUpdateGeneralSettingsCache();\n\n\tconst eventQueryOptions = useEventQueryOptions();\n\tconst updateCache = useUpdateCache();\n\n\tuseEffect(() => {\n\t\tif (!relationsInitialized()) {\n\t\t\t/* Rehydrate relations */\n\t\t\tinitializeRelations(relations);\n\t\t}\n\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\t}, [relations]);\n\n\tuseEffect(() => {\n\t\tif (isRehydrated) {\n\t\t\treturn;\n\t\t}\n\n\t\t/* Rehydrate event data */\n\t\tupdateCache({\n\t\t\t...eventQueryOptions,\n\t\t\tdata: {\n\t\t\t\tespressoEvent: event,\n\t\t\t},\n\t\t});\n\t\t/* Rehydrate price types */\n\t\tupdatePriceTypeList({\n\t\t\t...priceTypeQueryOptions,\n\t\t\tdata: {\n\t\t\t\tespressoPriceTypes,\n\t\t\t},\n\t\t});\n\t\tsetIsLoaded(TypeName.priceTypes, true);\n\n\t\t/* Rehydrate datetimes */\n\t\tupdateDatetimeList({\n\t\t\t...datetimeQueryOptions,\n\t\t\tdata: {\n\t\t\t\tespressoDatetimes,\n\t\t\t},\n\t\t});\n\t\tsetIsLoaded(TypeName.datetimes, true);\n\n\t\t/* Rehydrate tickets */\n\t\tupdateTicketList({\n\t\t\t...ticketQueryOptions,\n\t\t\tdata: {\n\t\t\t\tespressoTickets,\n\t\t\t},\n\t\t});\n\t\tsetIsLoaded(TypeName.tickets, true);\n\n\t\t/* Rehydrate prices */\n\t\tupdatePriceList({\n\t\t\t...priceQueryOptions,\n\t\t\tdata: {\n\t\t\t\tespressoPrices,\n\t\t\t},\n\t\t});\n\t\tsetIsLoaded(TypeName.prices, true);\n\n\t\t/* Rehydrate venues */\n\t\tupdateVenueList({\n\t\t\t...venueQueryOptions,\n\t\t\tdata: {\n\t\t\t\tespressoVenues,\n\t\t\t},\n\t\t});\n\n\t\t/* Rehydrate current user */\n\t\tupdateCurrentUser({\n\t\t\t...currentUserQueryOptions,\n\t\t\tdata: {\n\t\t\t\tviewer: currentUser,\n\t\t\t},\n\t\t});\n\n\t\t/* Rehydrate general settings */\n\t\tupdateGeneralSettings({\n\t\t\t...generalSettingsQueryOptions,\n\t\t\tdata: {\n\t\t\t\tgeneralSettings,\n\t\t\t},\n\t\t});\n\n\t\tsetIsRehydrated(true);\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\t}, []);\n\n\treturn isRehydrated;\n};\n\nexport default useCacheRehydration;\n","import { useCallback } from 'react';\n\nimport { MutationType, MutationInput } from '@eventespresso/data';\nimport { ucFirst, removeNullAndUndefined, uuid } from '@eventespresso/utils';\n\nimport type { Event } from '../../types';\nimport { useEvent } from '../../queries';\n\nexport const EVENT_DEFAULTS: Event = {\n\tid: '',\n\tdbId: 0,\n\tcacheId: uuid(),\n\tallowDonations: false,\n\tallowOverflow: false,\n\taltRegPage: '',\n\tcreated: '',\n\tdescription: '',\n\tdefaultRegStatus: '',\n\tdisplayDescription: false,\n\tdisplayTicketSelector: true,\n\tisActive: true,\n\tisCancelled: false,\n\tisExpired: false,\n\tisInactive: false,\n\tisPostponed: false,\n\tisSoldOut: false,\n\tisUpcoming: false,\n\tmaxRegistrations: 0,\n\tmemberOnly: false,\n\tname: '',\n\torder: 0,\n\tphoneNumber: '',\n\tshortDescription: '',\n\tstatus: '',\n\ttimezoneString: '',\n\tvenue: '',\n};\n\ntype OptimisticResCb = (mutationType: MutationType, input: MutationInput) => any;\n\nconst useOptimisticResponse = (): OptimisticResCb => {\n\tconst event = useEvent();\n\n\treturn useCallback(\n\t\t(mutationType, input) => {\n\t\t\tlet espressoEvent: Partial = {\n\t\t\t\t__typename: 'EspressoEvent',\n\t\t\t};\n\t\t\t// Get rid of null or undefined values\n\t\t\tconst filteredInput = removeNullAndUndefined(input);\n\n\t\t\tswitch (mutationType) {\n\t\t\t\tcase MutationType.Update:\n\t\t\t\t\tespressoEvent = {\n\t\t\t\t\t\t...espressoEvent,\n\t\t\t\t\t\t...event,\n\t\t\t\t\t\t...filteredInput,\n\t\t\t\t\t\tcacheId: uuid(),\n\t\t\t\t\t};\n\t\t\t\t\t// if manager is being updated\n\t\t\t\t\tif (input?.manager) {\n\t\t\t\t\t\t// make sure to properly update manager object\n\t\t\t\t\t\tespressoEvent.manager = {\n\t\t\t\t\t\t\t...event?.manager,\n\t\t\t\t\t\t\tid: input?.manager,\n\t\t\t\t\t\t};\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\tconst lcMutationtype = mutationType.toLowerCase();\n\t\t\tconst ucFirstMutationtype = ucFirst(lcMutationtype);\n\n\t\t\t// e.g. \"updateEspressoEvent\"\n\t\t\tconst mutation = `${lcMutationtype}EspressoEvent`;\n\n\t\t\treturn {\n\t\t\t\t__typename: 'RootMutation',\n\t\t\t\t[mutation]: {\n\t\t\t\t\t__typename: `${ucFirstMutationtype}EspressoEventPayload`,\n\t\t\t\t\tespressoEvent,\n\t\t\t\t},\n\t\t\t};\n\t\t},\n\t\t[event]\n\t);\n};\n\nexport default useOptimisticResponse;\n","import { useCallback } from 'react';\n\nimport { MutationType, MutationInput, OperationVariables } from '@eventespresso/data';\n\nimport useOptimisticResponse from './useOptimisticResponse';\nimport type { MutationHandler } from '../types';\nimport type { Event } from '../../';\nimport type { EventBaseInput } from './types';\n\ntype MH = MutationHandler;\n\nconst useMutationHandler = (): MH => {\n\tconst getOptimisticResponse = useOptimisticResponse();\n\n\tconst createVariables = useCallback((mutationType: MutationType, input: MutationInput): OperationVariables => {\n\t\tconst mutationInput: MutationInput = {\n\t\t\tclientMutationId: `${mutationType}_EVENT`,\n\t\t\t...input,\n\t\t};\n\n\t\treturn {\n\t\t\tinput: mutationInput,\n\t\t};\n\t}, []);\n\n\tconst mutator = useCallback(\n\t\t(mutationType, input) => {\n\t\t\tconst variables = createVariables(mutationType, input);\n\t\t\tconst optimisticResponse = getOptimisticResponse(mutationType, input);\n\n\t\t\treturn { variables, optimisticResponse };\n\t\t},\n\t\t[createVariables, getOptimisticResponse]\n\t);\n\n\treturn mutator;\n};\n\nexport default useMutationHandler;\n","import { useCallback, useMemo } from 'react';\n\nimport { MutationType, MutationFunction, useMutationWithFeedback } from '@eventespresso/data';\n\nimport type { UpdateEventInput } from './types';\nimport { UPDATE_EVENT } from './';\nimport useMutationHandler from './useMutationHandler';\nimport type { UpdateEventResult } from './types';\nimport { SINGULAR_ENTITY_NAME } from '../../../constants';\n\ninterface EventMutator {\n\tupdateEntity: MutationFunction;\n}\n\ntype EM = EventMutator;\n\nconst useEventMutator = (id = ''): EM => {\n\tconst updateEvent = useMutationWithFeedback({\n\t\ttypeName: SINGULAR_ENTITY_NAME.EVENT,\n\t\tmutationType: MutationType.Update,\n\t\tmutation: UPDATE_EVENT,\n\t});\n\n\tconst mutationHandler = useMutationHandler();\n\n\tconst updateEntity = useCallback(\n\t\t(input) => {\n\t\t\tconst options = mutationHandler(MutationType.Update, { id, ...input });\n\n\t\t\treturn updateEvent(options);\n\t\t},\n\t\t[id, mutationHandler, updateEvent]\n\t);\n\n\treturn useMemo(() => ({ updateEntity }), [updateEntity]);\n};\n\nexport default useEventMutator;\n","import { createSlotFill } from '@eventespresso/slot-fill';\n\nconst { Slot: NewDateOptions, Fill: NewDateOption } = createSlotFill('NewDateOptions');\n\nexport { NewDateOption, NewDateOptions };\n","import { makeVar } from '@eventespresso/data';\nimport { useEntityMeta, ManageEntityMeta } from '@eventespresso/services';\n\nconst ticketsMeta = makeVar({});\n\nexport const useTicketsMeta = (): ManageEntityMeta => {\n\treturn useEntityMeta(ticketsMeta);\n};\n","import { useMemoStringify } from '@eventespresso/hooks';\n\nimport type { EventManager } from '../../types';\n\nconst useEventManagers = (): Array => {\n\treturn useMemoStringify(window.eventEspressoData?.eventEditor?.eventManagers || []);\n};\n\nexport default useEventManagers;\n","import { useCallback, useMemo } from 'react';\nimport { keys, pathOr, pickBy, hasPath } from 'ramda';\n\nimport { useRelations } from '@eventespresso/services';\nimport { entitiesWithGuIdInArray } from '@eventespresso/predicates';\n\nimport type { Ticket } from '../../apollo';\nimport { useVisibleDatetimeIds } from '../../hooks';\n\ntype IsChainedFilterCallback = (args: { isChained: boolean; tickets: Array }) => Array;\ntype IsChainedFilterDeps = any;\n\ntype IsChainedFilterTuple = [IsChainedFilterCallback, IsChainedFilterDeps];\n\nconst useIsChainedFilter = (): IsChainedFilterTuple => {\n\tconst { getData } = useRelations();\n\tconst [visibleDatetimeIds] = useVisibleDatetimeIds();\n\n\tconst relatedTicketIds = useMemo(() => {\n\t\treturn keys(\n\t\t\tpickBy((relations) => {\n\t\t\t\treturn (\n\t\t\t\t\thasPath(['datetimes'], relations) &&\n\t\t\t\t\tpathOr([], ['datetimes'], relations).some((id) => visibleDatetimeIds.includes(id))\n\t\t\t\t);\n\t\t\t}, getData().tickets)\n\t\t);\n\t}, [getData, visibleDatetimeIds]);\n\n\tconst callback = useCallback(\n\t\t({ isChained, tickets }) => {\n\t\t\t// bail early\n\t\t\tif (!isChained) {\n\t\t\t\treturn tickets;\n\t\t\t}\n\n\t\t\treturn entitiesWithGuIdInArray(tickets, relatedTicketIds);\n\t\t},\n\n\t\t[relatedTicketIds]\n\t);\n\n\treturn useMemo(() => [callback, relatedTicketIds], [callback, relatedTicketIds]);\n};\n\nexport default useIsChainedFilter;\n","import { useEffect, useRef } from 'react';\n\nimport { FilterBarService } from '@eventespresso/registry';\nimport type { TicketsFilterStateManager } from './types';\n\nimport { domain, ticketsList } from '../../constants';\nimport useIsChainedFilter from './useIsChainedFilter';\nimport type { Ticket } from '../../apollo';\n\ntype Domain = typeof domain;\ntype TFSM = TicketsFilterStateManager;\n\nconst { registerFilter: registerTicketsFilter } = new FilterBarService(\n\tdomain,\n\tticketsList\n);\n\nconst useRegisterIsChainedFilter: VoidFunction = () => {\n\t/**\n\t * isChained filter needs special treatment :)\n\t *\n\t * Unlike other sorters and filters, isChained filter is dependent upon\n\t * external state which can change. Thus we need to update our filter callback\n\t * to make sure the stale state is not bound to the filter callback.\n\t */\n\tconst [isChainedFilter, isChainedDeps] = useIsChainedFilter();\n\t// To avoid multiple filter registrations, we will store the already registered\n\t// filter unSubscribe callback in ref to use it to remove the existing filter.\n\tconst unSubIsChainedFilterRef = useRef();\n\n\tuseEffect(() => {\n\t\t// If already registered, de-register\n\t\tunSubIsChainedFilterRef.current?.();\n\n\t\t// Register isChained filter\n\t\tconst unSubscribeIsChainedFilter = registerTicketsFilter(({ entityList, filterState }) => {\n\t\t\treturn isChainedFilter({ isChained: filterState.isChained, tickets: entityList });\n\t\t}, 9); // we want isChained to run first\n\n\t\t// update ref, it won't cause rerendersٖ\n\t\tunSubIsChainedFilterRef.current = unSubscribeIsChainedFilter;\n\t\t// Housekeeping\n\t\treturn (): void => {\n\t\t\tunSubIsChainedFilterRef.current?.();\n\t\t};\n\t}, [isChainedDeps, isChainedFilter]);\n};\n\nexport default useRegisterIsChainedFilter;\n","var _curry1 =\n/*#__PURE__*/\nrequire(\"./internal/_curry1\");\n\nvar empty =\n/*#__PURE__*/\nrequire(\"./empty\");\n\nvar equals =\n/*#__PURE__*/\nrequire(\"./equals\");\n/**\n * Returns `true` if the given value is its type's empty value; `false`\n * otherwise.\n *\n * @func\n * @memberOf R\n * @since v0.1.0\n * @category Logic\n * @sig a -> Boolean\n * @param {*} x\n * @return {Boolean}\n * @see R.empty\n * @example\n *\n * R.isEmpty([1, 2, 3]); //=> false\n * R.isEmpty([]); //=> true\n * R.isEmpty(''); //=> true\n * R.isEmpty(null); //=> false\n * R.isEmpty({}); //=> true\n * R.isEmpty({length: 0}); //=> false\n */\n\n\nvar isEmpty =\n/*#__PURE__*/\n_curry1(function isEmpty(x) {\n return x != null && equals(x, empty(x));\n});\n\nmodule.exports = isEmpty;","// import global types.\nimport '../../../types';\n\nexport * from './apollo';\n\nexport * from './constants';\n\nexport * from './context';\n\nexport * from './filterState';\n\nexport * from './forms';\n\nexport * from './hooks';\n\nexport * from './ioc';\n\nexport * from './slots';\n\nexport * from './utils';\n\nexport * from './types';\n","var _curry1 =\n/*#__PURE__*/\nrequire(\"./internal/_curry1\");\n\nvar _isArguments =\n/*#__PURE__*/\nrequire(\"./internal/_isArguments\");\n\nvar _isArray =\n/*#__PURE__*/\nrequire(\"./internal/_isArray\");\n\nvar _isObject =\n/*#__PURE__*/\nrequire(\"./internal/_isObject\");\n\nvar _isString =\n/*#__PURE__*/\nrequire(\"./internal/_isString\");\n/**\n * Returns the empty value of its argument's type. Ramda defines the empty\n * value of Array (`[]`), Object (`{}`), String (`''`), and Arguments. Other\n * types are supported if they define `.empty`,\n * `.prototype.empty` or implement the\n * [FantasyLand Monoid spec](https://github.com/fantasyland/fantasy-land#monoid).\n *\n * Dispatches to the `empty` method of the first argument, if present.\n *\n * @func\n * @memberOf R\n * @since v0.3.0\n * @category Function\n * @sig a -> a\n * @param {*} x\n * @return {*}\n * @example\n *\n * R.empty(Just(42)); //=> Nothing()\n * R.empty([1, 2, 3]); //=> []\n * R.empty('unicorns'); //=> ''\n * R.empty({x: 1, y: 2}); //=> {}\n */\n\n\nvar empty =\n/*#__PURE__*/\n_curry1(function empty(x) {\n return x != null && typeof x['fantasy-land/empty'] === 'function' ? x['fantasy-land/empty']() : x != null && x.constructor != null && typeof x.constructor['fantasy-land/empty'] === 'function' ? x.constructor['fantasy-land/empty']() : x != null && typeof x.empty === 'function' ? x.empty() : x != null && x.constructor != null && typeof x.constructor.empty === 'function' ? x.constructor.empty() : _isArray(x) ? [] : _isString(x) ? '' : _isObject(x) ? {} : _isArguments(x) ? function () {\n return arguments;\n }() : void 0 // else\n ;\n});\n\nmodule.exports = empty;","/**\n * Tests whether or not an object is an array.\n *\n * @private\n * @param {*} val The object to test.\n * @return {Boolean} `true` if `val` is an array, `false` otherwise.\n * @example\n *\n * _isArray([]); //=> true\n * _isArray(null); //=> false\n * _isArray({}); //=> false\n */\nmodule.exports = Array.isArray || function _isArray(val) {\n return val != null && val.length >= 0 && Object.prototype.toString.call(val) === '[object Array]';\n};","function _isObject(x) {\n return Object.prototype.toString.call(x) === '[object Object]';\n}\n\nmodule.exports = _isObject;","function _isString(x) {\n return Object.prototype.toString.call(x) === '[object String]';\n}\n\nmodule.exports = _isString;","var _curry2 =\n/*#__PURE__*/\nrequire(\"./internal/_curry2\");\n\nvar _equals =\n/*#__PURE__*/\nrequire(\"./internal/_equals\");\n/**\n * Returns `true` if its arguments are equivalent, `false` otherwise. Handles\n * cyclical data structures.\n *\n * Dispatches symmetrically to the `equals` methods of both arguments, if\n * present.\n *\n * @func\n * @memberOf R\n * @since v0.15.0\n * @category Relation\n * @sig a -> b -> Boolean\n * @param {*} a\n * @param {*} b\n * @return {Boolean}\n * @example\n *\n * R.equals(1, 1); //=> true\n * R.equals(1, '1'); //=> false\n * R.equals([1, 2, 3], [1, 2, 3]); //=> true\n *\n * const a = {}; a.v = a;\n * const b = {}; b.v = b;\n * R.equals(a, b); //=> true\n */\n\n\nvar equals =\n/*#__PURE__*/\n_curry2(function equals(a, b) {\n return _equals(a, b, [], []);\n});\n\nmodule.exports = equals;","var _curry1 =\n/*#__PURE__*/\nrequire(\"./_curry1\");\n\nvar _isPlaceholder =\n/*#__PURE__*/\nrequire(\"./_isPlaceholder\");\n/**\n * Optimized internal two-arity curry function.\n *\n * @private\n * @category Function\n * @param {Function} fn The function to curry.\n * @return {Function} The curried function.\n */\n\n\nfunction _curry2(fn) {\n return function f2(a, b) {\n switch (arguments.length) {\n case 0:\n return f2;\n\n case 1:\n return _isPlaceholder(a) ? f2 : _curry1(function (_b) {\n return fn(a, _b);\n });\n\n default:\n return _isPlaceholder(a) && _isPlaceholder(b) ? f2 : _isPlaceholder(a) ? _curry1(function (_a) {\n return fn(_a, b);\n }) : _isPlaceholder(b) ? _curry1(function (_b) {\n return fn(a, _b);\n }) : fn(a, b);\n }\n };\n}\n\nmodule.exports = _curry2;","var _arrayFromIterator =\n/*#__PURE__*/\nrequire(\"./_arrayFromIterator\");\n\nvar _includesWith =\n/*#__PURE__*/\nrequire(\"./_includesWith\");\n\nvar _functionName =\n/*#__PURE__*/\nrequire(\"./_functionName\");\n\nvar _has =\n/*#__PURE__*/\nrequire(\"./_has\");\n\nvar _objectIs =\n/*#__PURE__*/\nrequire(\"./_objectIs\");\n\nvar keys =\n/*#__PURE__*/\nrequire(\"../keys\");\n\nvar type =\n/*#__PURE__*/\nrequire(\"../type\");\n/**\n * private _uniqContentEquals function.\n * That function is checking equality of 2 iterator contents with 2 assumptions\n * - iterators lengths are the same\n * - iterators values are unique\n *\n * false-positive result will be returned for comparision of, e.g.\n * - [1,2,3] and [1,2,3,4]\n * - [1,1,1] and [1,2,3]\n * */\n\n\nfunction _uniqContentEquals(aIterator, bIterator, stackA, stackB) {\n var a = _arrayFromIterator(aIterator);\n\n var b = _arrayFromIterator(bIterator);\n\n function eq(_a, _b) {\n return _equals(_a, _b, stackA.slice(), stackB.slice());\n } // if *a* array contains any element that is not included in *b*\n\n\n return !_includesWith(function (b, aItem) {\n return !_includesWith(eq, aItem, b);\n }, b, a);\n}\n\nfunction _equals(a, b, stackA, stackB) {\n if (_objectIs(a, b)) {\n return true;\n }\n\n var typeA = type(a);\n\n if (typeA !== type(b)) {\n return false;\n }\n\n if (a == null || b == null) {\n return false;\n }\n\n if (typeof a['fantasy-land/equals'] === 'function' || typeof b['fantasy-land/equals'] === 'function') {\n return typeof a['fantasy-land/equals'] === 'function' && a['fantasy-land/equals'](b) && typeof b['fantasy-land/equals'] === 'function' && b['fantasy-land/equals'](a);\n }\n\n if (typeof a.equals === 'function' || typeof b.equals === 'function') {\n return typeof a.equals === 'function' && a.equals(b) && typeof b.equals === 'function' && b.equals(a);\n }\n\n switch (typeA) {\n case 'Arguments':\n case 'Array':\n case 'Object':\n if (typeof a.constructor === 'function' && _functionName(a.constructor) === 'Promise') {\n return a === b;\n }\n\n break;\n\n case 'Boolean':\n case 'Number':\n case 'String':\n if (!(typeof a === typeof b && _objectIs(a.valueOf(), b.valueOf()))) {\n return false;\n }\n\n break;\n\n case 'Date':\n if (!_objectIs(a.valueOf(), b.valueOf())) {\n return false;\n }\n\n break;\n\n case 'Error':\n return a.name === b.name && a.message === b.message;\n\n case 'RegExp':\n if (!(a.source === b.source && a.global === b.global && a.ignoreCase === b.ignoreCase && a.multiline === b.multiline && a.sticky === b.sticky && a.unicode === b.unicode)) {\n return false;\n }\n\n break;\n }\n\n var idx = stackA.length - 1;\n\n while (idx >= 0) {\n if (stackA[idx] === a) {\n return stackB[idx] === b;\n }\n\n idx -= 1;\n }\n\n switch (typeA) {\n case 'Map':\n if (a.size !== b.size) {\n return false;\n }\n\n return _uniqContentEquals(a.entries(), b.entries(), stackA.concat([a]), stackB.concat([b]));\n\n case 'Set':\n if (a.size !== b.size) {\n return false;\n }\n\n return _uniqContentEquals(a.values(), b.values(), stackA.concat([a]), stackB.concat([b]));\n\n case 'Arguments':\n case 'Array':\n case 'Object':\n case 'Boolean':\n case 'Number':\n case 'String':\n case 'Date':\n case 'Error':\n case 'RegExp':\n case 'Int8Array':\n case 'Uint8Array':\n case 'Uint8ClampedArray':\n case 'Int16Array':\n case 'Uint16Array':\n case 'Int32Array':\n case 'Uint32Array':\n case 'Float32Array':\n case 'Float64Array':\n case 'ArrayBuffer':\n break;\n\n default:\n // Values of other types are only equal if identical.\n return false;\n }\n\n var keysA = keys(a);\n\n if (keysA.length !== keys(b).length) {\n return false;\n }\n\n var extendedStackA = stackA.concat([a]);\n var extendedStackB = stackB.concat([b]);\n idx = keysA.length - 1;\n\n while (idx >= 0) {\n var key = keysA[idx];\n\n if (!(_has(key, b) && _equals(b[key], a[key], extendedStackA, extendedStackB))) {\n return false;\n }\n\n idx -= 1;\n }\n\n return true;\n}\n\nmodule.exports = _equals;","function _arrayFromIterator(iter) {\n var list = [];\n var next;\n\n while (!(next = iter.next()).done) {\n list.push(next.value);\n }\n\n return list;\n}\n\nmodule.exports = _arrayFromIterator;","function _includesWith(pred, x, list) {\n var idx = 0;\n var len = list.length;\n\n while (idx < len) {\n if (pred(x, list[idx])) {\n return true;\n }\n\n idx += 1;\n }\n\n return false;\n}\n\nmodule.exports = _includesWith;","function _functionName(f) {\n // String(x => x) evaluates to \"x => x\", so the pattern may not match.\n var match = String(f).match(/^function (\\w*)/);\n return match == null ? '' : match[1];\n}\n\nmodule.exports = _functionName;","// Based on https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/is\nfunction _objectIs(a, b) {\n // SameValue algorithm\n if (a === b) {\n // Steps 1-5, 7-10\n // Steps 6.b-6.e: +0 != -0\n return a !== 0 || 1 / a === 1 / b;\n } else {\n // Step 6.a: NaN == NaN\n return a !== a && b !== b;\n }\n}\n\nmodule.exports = typeof Object.is === 'function' ? Object.is : _objectIs;","var _curry1 =\n/*#__PURE__*/\nrequire(\"./internal/_curry1\");\n\nvar _has =\n/*#__PURE__*/\nrequire(\"./internal/_has\");\n\nvar _isArguments =\n/*#__PURE__*/\nrequire(\"./internal/_isArguments\"); // cover IE < 9 keys issues\n\n\nvar hasEnumBug = !\n/*#__PURE__*/\n{\n toString: null\n}.propertyIsEnumerable('toString');\nvar nonEnumerableProps = ['constructor', 'valueOf', 'isPrototypeOf', 'toString', 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; // Safari bug\n\nvar hasArgsEnumBug =\n/*#__PURE__*/\nfunction () {\n 'use strict';\n\n return arguments.propertyIsEnumerable('length');\n}();\n\nvar contains = function contains(list, item) {\n var idx = 0;\n\n while (idx < list.length) {\n if (list[idx] === item) {\n return true;\n }\n\n idx += 1;\n }\n\n return false;\n};\n/**\n * Returns a list containing the names of all the enumerable own properties of\n * the supplied object.\n * Note that the order of the output array is not guaranteed to be consistent\n * across different JS platforms.\n *\n * @func\n * @memberOf R\n * @since v0.1.0\n * @category Object\n * @sig {k: v} -> [k]\n * @param {Object} obj The object to extract properties from\n * @return {Array} An array of the object's own properties.\n * @see R.keysIn, R.values\n * @example\n *\n * R.keys({a: 1, b: 2, c: 3}); //=> ['a', 'b', 'c']\n */\n\n\nvar keys = typeof Object.keys === 'function' && !hasArgsEnumBug ?\n/*#__PURE__*/\n_curry1(function keys(obj) {\n return Object(obj) !== obj ? [] : Object.keys(obj);\n}) :\n/*#__PURE__*/\n_curry1(function keys(obj) {\n if (Object(obj) !== obj) {\n return [];\n }\n\n var prop, nIdx;\n var ks = [];\n\n var checkArgsLength = hasArgsEnumBug && _isArguments(obj);\n\n for (prop in obj) {\n if (_has(prop, obj) && (!checkArgsLength || prop !== 'length')) {\n ks[ks.length] = prop;\n }\n }\n\n if (hasEnumBug) {\n nIdx = nonEnumerableProps.length - 1;\n\n while (nIdx >= 0) {\n prop = nonEnumerableProps[nIdx];\n\n if (_has(prop, obj) && !contains(ks, prop)) {\n ks[ks.length] = prop;\n }\n\n nIdx -= 1;\n }\n }\n\n return ks;\n});\nmodule.exports = keys;","var _curry1 =\n/*#__PURE__*/\nrequire(\"./internal/_curry1\");\n/**\n * Gives a single-word string description of the (native) type of a value,\n * returning such answers as 'Object', 'Number', 'Array', or 'Null'. Does not\n * attempt to distinguish user Object types any further, reporting them all as\n * 'Object'.\n *\n * @func\n * @memberOf R\n * @since v0.8.0\n * @category Type\n * @sig (* -> {*}) -> String\n * @param {*} val The value to test\n * @return {String}\n * @example\n *\n * R.type({}); //=> \"Object\"\n * R.type(1); //=> \"Number\"\n * R.type(false); //=> \"Boolean\"\n * R.type('s'); //=> \"String\"\n * R.type(null); //=> \"Null\"\n * R.type([]); //=> \"Array\"\n * R.type(/[A-z]/); //=> \"RegExp\"\n * R.type(() => {}); //=> \"Function\"\n * R.type(undefined); //=> \"Undefined\"\n */\n\n\nvar type =\n/*#__PURE__*/\n_curry1(function type(val) {\n return val === null ? 'Null' : val === undefined ? 'Undefined' : Object.prototype.toString.call(val).slice(8, -1);\n});\n\nmodule.exports = type;"],"sourceRoot":""} \ No newline at end of file diff --git a/assets/static/js/edtrServices.3dfe4571.asset.php b/assets/static/js/edtrServices.bf217bbb.asset.php similarity index 82% rename from assets/static/js/edtrServices.3dfe4571.asset.php rename to assets/static/js/edtrServices.bf217bbb.asset.php index a5480e36792..4372b6a23ed 100644 --- a/assets/static/js/edtrServices.3dfe4571.asset.php +++ b/assets/static/js/edtrServices.bf217bbb.asset.php @@ -1 +1 @@ - array('eventespresso-adapters', 'eventespresso-constants', 'eventespresso-data', 'eventespresso-dates', 'eventespresso-hooks', 'eventespresso-i18n', 'eventespresso-ioc', 'eventespresso-predicates', 'eventespresso-registry', 'eventespresso-services', 'eventespresso-slotFill', 'eventespresso-storage', 'eventespresso-toaster', 'eventespresso-utils', 'ramda', 'react', 'wp-url'), 'version' => '51d76c79e5a83ae1d4cffbeafc0964d3'); \ No newline at end of file + array('eventespresso-adapters', 'eventespresso-constants', 'eventespresso-data', 'eventespresso-dates', 'eventespresso-hooks', 'eventespresso-i18n', 'eventespresso-ioc', 'eventespresso-predicates', 'eventespresso-registry', 'eventespresso-services', 'eventespresso-slotFill', 'eventespresso-storage', 'eventespresso-toaster', 'eventespresso-utils', 'ramda', 'react', 'wp-url'), 'version' => 'da3614adc1335a6e22c35b647522ac30'); \ No newline at end of file diff --git a/assets/static/js/eventEditor.102d65dc.asset.php b/assets/static/js/eventEditor.1aefe9f3.asset.php similarity index 91% rename from assets/static/js/eventEditor.102d65dc.asset.php rename to assets/static/js/eventEditor.1aefe9f3.asset.php index c820227f579..cc1e84125be 100644 --- a/assets/static/js/eventEditor.102d65dc.asset.php +++ b/assets/static/js/eventEditor.1aefe9f3.asset.php @@ -1 +1 @@ - array('eventespresso-adapters', 'eventespresso-constants', 'eventespresso-data', 'eventespresso-dates', 'eventespresso-edtrServices', 'eventespresso-eeComponents', 'eventespresso-form', 'eventespresso-formBuilder', 'eventespresso-helpers', 'eventespresso-hooks', 'eventespresso-i18n', 'eventespresso-plugins', 'eventespresso-predicates', 'eventespresso-registry', 'eventespresso-services', 'eventespresso-toaster', 'eventespresso-tpc', 'eventespresso-uiComponents', 'eventespresso-utils', 'ramda', 'react', 'react-dom', 'wp-i18n', 'wp-url'), 'version' => '30ed38b79417153ecbf910a2d6939277'); \ No newline at end of file + array('eventespresso-adapters', 'eventespresso-constants', 'eventespresso-data', 'eventespresso-dates', 'eventespresso-edtrServices', 'eventespresso-eeComponents', 'eventespresso-form', 'eventespresso-formBuilder', 'eventespresso-helpers', 'eventespresso-hooks', 'eventespresso-i18n', 'eventespresso-plugins', 'eventespresso-predicates', 'eventespresso-registry', 'eventespresso-services', 'eventespresso-toaster', 'eventespresso-tpc', 'eventespresso-uiComponents', 'eventespresso-utils', 'ramda', 'react', 'react-dom', 'wp-i18n', 'wp-url'), 'version' => 'd69f8a725c8a353cfd1b6ff6d27c2940'); \ No newline at end of file diff --git a/assets/static/js/eventEditor.5414d673.js b/assets/static/js/eventEditor.5414d673.js deleted file mode 100644 index b3c76545de7..00000000000 --- a/assets/static/js/eventEditor.5414d673.js +++ /dev/null @@ -1,3 +0,0 @@ -/*! For license information please see eventEditor.5414d673.js.LICENSE.txt */ -this.eventespresso=this.eventespresso||{},this.eventespresso.eventEditor=function(e){function t(t){for(var n,r,a=t[0],o=t[1],c=0,s=[];c2)return n;if(/:/.test(r[0])?(n.date=null,t=r[0]):(n.date=r[0],t=r[1],o.timeZoneDelimiter.test(n.date)&&(n.date=e.split(o.timeZoneDelimiter)[0],t=e.substr(n.date.length,e.length))),t){var i=o.timezone.exec(t);i?(n.time=t.replace(i[1],""),n.timezone=i[1]):n.time=t}return n}function f(e,t){var n=new RegExp("^(?:(\\d{4}|[+-]\\d{"+(4+t)+"})|(\\d{2}|[+-]\\d{"+(2+t)+"})$)"),r=e.match(n);if(!r)return{year:null};var i=r[1]&&parseInt(r[1]),a=r[2]&&parseInt(r[2]);return{year:null==a?i:100*a,restDateString:e.slice((r[1]||r[2]).length)}}function b(e,t){if(null===t)return null;var n=e.match(c);if(!n)return null;var r=!!n[4],i=p(n[1]),a=p(n[2])-1,o=p(n[3]),s=p(n[4]),u=p(n[5])-1;if(r)return function(e,t,n){return t>=1&&t<=53&&n>=0&&n<=6}(0,s,u)?function(e,t,n){var r=new Date(0);r.setUTCFullYear(e,0,4);var i=r.getUTCDay()||7,a=7*(t-1)+n+1-i;return r.setUTCDate(r.getUTCDate()+a),r}(t,s,u):new Date(NaN);var l=new Date(0);return function(e,t,n){return t>=0&&t<=11&&n>=1&&n<=(O[t]||(m(e)?29:28))}(t,a,o)&&function(e,t){return t>=1&&t<=(m(e)?366:365)}(t,i)?(l.setUTCFullYear(t,a,Math.max(i,o)),l):new Date(NaN)}function p(e){return e?parseInt(e):1}function v(e){var t=e.match(s);if(!t)return null;var n=h(t[1]),r=h(t[2]),i=h(t[3]);return function(e,t,n){if(24===e)return 0===t&&0===n;return n>=0&&n<60&&t>=0&&t<60&&e>=0&&e<25}(n,r,i)?n*a+6e4*r+1e3*i:NaN}function h(e){return e&&parseFloat(e.replace(",","."))||0}function j(e){if("Z"===e)return 0;var t=e.match(u);if(!t)return 0;var n="+"===t[1]?-1:1,r=parseInt(t[2]),i=t[3]&&parseInt(t[3])||0;return function(e,t){return t>=0&&t<=59}(0,i)?n*(r*a+6e4*i):NaN}var O=[31,null,31,30,31,30,31,31,30,31,30,31];function m(e){return e%400===0||e%4===0&&e%100}},115:function(e,t,n){"use strict";function r(e){return(r="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})(e)}n.d(t,"a",(function(){return r}))},116:function(e,t,n){"use strict";function r(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}n.d(t,"a",(function(){return r}))},12:function(e,t){e.exports=window.eventespresso.predicates},122:function(e,t,n){var r=n(388),i="object"==typeof self&&self&&self.Object===Object&&self,a=r||i||Function("return this")();e.exports=a},1256:function(e,t,n){"use strict";var r=n(0),i=n(63),a=n.n(i),o=n(169);t.a=function(){var e=Object(r.useContext)(o.FilterStateContext);return a()(e,"useFilterState must be used inside TAM component"),e}},1257:function(e,t){},1258:function(e,t,n){"use strict";var r=n(2),i=n(280),a=n(1);t.a=function(e,t){return function(n){return Object(a.jsx)(i.b,Object(r.a)(Object(r.a)({},t),{},{children:Object(a.jsx)(e,Object(r.a)({},n))}))}}},1259:function(e,t,n){"use strict";var r=n(0),i=n(280),a=n(63),o=n.n(a);t.a=function(){var e=Object(r.useContext)(i.a);return o()(e,"useTAMContext must be used inside TAM component"),e}},1260:function(e,t){},1261:function(e,t,n){"use strict";var r=n(0),i=n(63),a=n.n(i),o=n(602);t.a=function(){var e=Object(r.useContext)(o.a);return a()(e,"useDataState must be used inside DataStateProvider"),e}},1262:function(e,t,n){"use strict";var r=n(43),i=n(34),a=n.n(i),o=n(0),c=n(16),s=n(84);t.a=function(e){var t=e.deletedTickets,n=e.tickets,i=Object(s.useMutateTicket)(!0),u=Object(c.useTicketMutator)().deleteEntity;return Object(o.useCallback)(Object(r.a)(a.a.mark((function e(){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Promise.all(Object.values(n).map(i));case 2:if(!t.length){e.next=5;break}return e.next=5,Promise.all(t.map((function(e){return u({id:e,deletePermanently:!0})})));case 5:case"end":return e.stop()}}),e)}))),[u,t,i,n])}},1263:function(e,t){},1290:function(e,t,n){"use strict";var r=n(31),i=n(0),a=n(3),o=n(16),c=n(5),s=n(456),u=n(1),l=function(e){var t=e.datesByMonth,n=e.setDatesByMonth,l=Object(o.useDatetimes)(),d=Object(s.a)(l),f=t.join(":"),b=Object(i.useMemo)((function(){return[{value:"0:0",label:Object(a.__)("All Dates")}].concat(Object(r.a)(d))}),[d]);return Object(u.jsx)(c.SelectWithLabel,{id:"ee-dates-by-month",label:Object(a.__)("dates by month"),onChangeValue:n,options:b,value:f})},d=function(e){var t=e.showExpiredTickets,n=e.setShowExpiredTickets;return Object(u.jsx)(c.SwitchWithLabel,{id:"show-expired-tickets",isChecked:t,label:Object(a.__)("show expired tickets"),onChangeValue:n})},f=function(e){var t=e.showTrashedDates,n=e.setShowTrashedDates;return Object(u.jsx)(c.SwitchWithLabel,{id:"show-trashed-dates",isChecked:t,label:Object(a.__)("show trashed dates"),onChangeValue:n})},b=function(e){var t=e.showTrashedTickets,n=e.setShowTrashedTickets;return Object(u.jsx)(c.SwitchWithLabel,{id:"show-trashed-tickets",isChecked:t,label:Object(a.__)("show trashed tickets"),onChangeValue:n})},p=n(169),v=n(286);t.a=function(){var e=Object(p.useTAMContext)().assignmentType,t=Object(v.useFilterState)(),n=t.datesByMonth,r=t.setDatesByMonth,i=t.setShowExpiredTickets,a=t.setShowTrashedDates,o=t.setShowTrashedTickets,c=t.showExpiredTickets,s=t.showTrashedDates,h=t.showTrashedTickets;return Object(u.jsxs)("div",{className:"ee-ticket-assignments-manager__filter-bar",children:["forDate"!==e&&Object(u.jsxs)(u.Fragment,{children:[Object(u.jsx)(l,{datesByMonth:n,setDatesByMonth:r}),Object(u.jsx)(f,{showTrashedDates:s,setShowTrashedDates:a})]}),"forTicket"!==e&&Object(u.jsxs)(u.Fragment,{children:[Object(u.jsx)(d,{showExpiredTickets:c,setShowExpiredTickets:i}),Object(u.jsx)(b,{showTrashedTickets:h,setShowTrashedTickets:o})]})]})}},132:function(e,t){var n=Array.isArray;e.exports=n},136:function(e,t,n){"use strict";function r(e){this._maxSize=e,this.clear()}r.prototype.clear=function(){this._size=0,this._values=Object.create(null)},r.prototype.get=function(e){return this._values[e]},r.prototype.set=function(e,t){return this._size>=this._maxSize&&this.clear(),e in this._values||this._size++,this._values[e]=t};var i=/[^.^\]^[]+|(?=\[\]|\.\.)/g,a=/^\d+$/,o=/^\d/,c=/[~`!#$%\^&*+=\-\[\]\\';,/{}|\\":<>\?]/g,s=/^\s*(['"]?)(.*?)(\1)\s*$/,u=new r(512),l=new r(512),d=new r(512);function f(e){return u.get(e)||u.set(e,b(e).map((function(e){return e.replace(s,"$2")})))}function b(e){return e.match(i)}function p(e){return"string"===typeof e&&e&&-1!==["'",'"'].indexOf(e.charAt(0))}function v(e){return!p(e)&&(function(e){return e.match(o)&&!e.match(a)}(e)||function(e){return c.test(e)}(e))}e.exports={Cache:r,split:b,normalizePath:f,setter:function(e){var t=f(e);return l.get(e)||l.set(e,(function(e,n){for(var r=0,i=t.length,a=e;r=0||(i[n]=e[n]);return i}function l(e){return"number"===typeof e&&!isNaN(e)}function d(e){return"boolean"===typeof e}function f(e){return"string"===typeof e}function b(e){return"function"===typeof e}function p(e){return f(e)||b(e)?e:null}function v(e){return 0===e||e}var h=!("undefined"===typeof window||!window.document||!window.document.createElement);function j(e){return Object(r.isValidElement)(e)||f(e)||b(e)||l(e)}var O={TOP_LEFT:"top-left",TOP_RIGHT:"top-right",TOP_CENTER:"top-center",BOTTOM_LEFT:"bottom-left",BOTTOM_RIGHT:"bottom-right",BOTTOM_CENTER:"bottom-center"},m={INFO:"info",SUCCESS:"success",WARNING:"warning",ERROR:"error",DEFAULT:"default"};function y(e){var t=e.enter,n=e.exit,a=e.appendPosition,o=void 0!==a&&a,c=e.collapse,s=void 0===c||c,u=e.collapseDuration,l=void 0===u?300:u;return function(e){var a=e.children,c=e.position,u=e.preventExitTransition,d=e.done,f=e.nodeRef,b=e.isIn,p=o?t+"--"+c:t,v=o?n+"--"+c:n,h=Object(r.useRef)(),j=Object(r.useRef)(0);function O(e){if(e.target===f.current){var t=f.current;t.removeEventListener("animationend",O),0===j.current&&(t.className=h.current)}}function m(){var e=f.current;e.removeEventListener("animationend",m),s?function(e,t,n){void 0===n&&(n=300);var r=e.scrollHeight,i=e.style;requestAnimationFrame((function(){i.minHeight="initial",i.height=r+"px",i.transition="all "+n+"ms",requestAnimationFrame((function(){i.height="0",i.padding="0",i.margin="0",setTimeout(t,n)}))}))}(e,d,l):d()}return Object(r.useLayoutEffect)((function(){!function(){var e=f.current;h.current=e.className,e.className+=" "+p,e.addEventListener("animationend",O)}()}),[]),Object(r.useEffect)((function(){b||(u?m():function(){j.current=1;var e=f.current;e.className+=" "+v,e.addEventListener("animationend",m)}())}),[b]),i.a.createElement(i.a.Fragment,null,a)}}var g={list:new Map,emitQueue:new Map,on:function(e,t){return this.list.has(e)||this.list.set(e,[]),this.list.get(e).push(t),this},off:function(e,t){if(t){var n=this.list.get(e).filter((function(e){return e!==t}));return this.list.set(e,n),this}return this.list.delete(e),this},cancelEmit:function(e){var t=this.emitQueue.get(e);return t&&(t.forEach(clearTimeout),this.emitQueue.delete(e)),this},emit:function(e){for(var t=this,n=arguments.length,r=new Array(n>1?n-1:0),i=1;i0?F:I),hideProgressBar:d(y.hideProgressBar)?y.hideProgressBar:E.hideProgressBar,progress:y.progress,role:f(y.role)?y.role:E.role,deleteToast:function(){!function(e){delete h[e];var n=s.length;(c=v(e)?c-1:c-O.displayedToast)<0&&(c=0);if(n>0){var r=v(e)?1:O.props.limit;if(1===n||1===r)O.displayedToast++,w();else{var i=r>n?n:r;O.displayedToast=i;for(var a=0;a0&&c>E.limit&&S?s.push({toastContent:M,toastProps:N,staleId:m}):l(a)&&a>0?setTimeout((function(){D(M,N,m)}),a):D(M,N,m)}}function D(e,t,n){var r=t.toastId;n&&delete h[n],h[r]={content:e,props:t},a({type:0,toastId:r,staleId:n})}return Object(r.useEffect)((function(){return O.containerId=e.containerId,g.cancelEmit(3).on(0,E).on(1,(function(e){return o.current&&T(e)})).on(5,y).emit(2,O),function(){return g.emit(3,O)}}),[]),Object(r.useEffect)((function(){O.isToastActive=m,O.displayedToast=i.length,g.emit(4,i.length,e.containerId)}),[i]),Object(r.useEffect)((function(){O.props=e})),{getToastToRender:function(t){for(var n={},r=e.newestOnTop?Object.keys(h).reverse():Object.keys(h),i=0;i=1?e.targetTouches[0].clientX:e.clientX}function E(e){return e.targetTouches&&e.targetTouches.length>=1?e.targetTouches[0].clientY:e.clientY}function D(e){var t=Object(r.useState)(!0),n=t[0],i=t[1],a=Object(r.useState)(!1),o=a[0],c=a[1],s=Object(r.useRef)(null),u=_({start:0,x:0,y:0,delta:0,removalDistance:0,canCloseOnClick:!0,canDrag:!1,boundingRect:null}),l=_(e,!0),d=e.autoClose,f=e.pauseOnHover,p=e.closeToast,v=e.onClick,h=e.closeOnClick;function j(t){if(e.draggable){var n=s.current;u.canCloseOnClick=!0,u.canDrag=!0,u.boundingRect=n.getBoundingClientRect(),n.style.transition="",u.x=w(t.nativeEvent),u.y=E(t.nativeEvent),"x"===e.draggableDirection?(u.start=u.x,u.removalDistance=n.offsetWidth*(e.draggablePercent/100)):(u.start=u.y,u.removalDistance=n.offsetHeight*(e.draggablePercent/100))}}function O(){if(u.boundingRect){var t=u.boundingRect,n=t.top,r=t.bottom,i=t.left,a=t.right;e.pauseOnHover&&u.x>=i&&u.x<=a&&u.y>=n&&u.y<=r?y():m()}}function m(){i(!0)}function y(){i(!1)}function g(t){if(u.canDrag){t.preventDefault();var r=s.current;n&&y(),u.x=w(t),u.y=E(t),"x"===e.draggableDirection?u.delta=u.x-u.start:u.delta=u.y-u.start,u.start!==u.x&&(u.canCloseOnClick=!1),r.style.transform="translate"+e.draggableDirection+"("+u.delta+"px)",r.style.opacity=""+(1-Math.abs(u.delta/u.removalDistance))}}function x(){var t=s.current;if(u.canDrag){if(u.canDrag=!1,Math.abs(u.delta)>u.removalDistance)return c(!0),void e.closeToast();t.style.transition="transform 0.2s, opacity 0.2s",t.style.transform="translate"+e.draggableDirection+"(0)",t.style.opacity="1"}}Object(r.useEffect)((function(){return b(e.onOpen)&&e.onOpen(Object(r.isValidElement)(e.children)&&e.children.props),function(){b(l.onClose)&&l.onClose(Object(r.isValidElement)(l.children)&&l.children.props)}}),[]),Object(r.useEffect)((function(){return e.draggable&&(document.addEventListener("mousemove",g),document.addEventListener("mouseup",x),document.addEventListener("touchmove",g),document.addEventListener("touchend",x)),function(){e.draggable&&(document.removeEventListener("mousemove",g),document.removeEventListener("mouseup",x),document.removeEventListener("touchmove",g),document.removeEventListener("touchend",x))}}),[e.draggable]),Object(r.useEffect)((function(){return e.pauseOnFocusLoss&&function(){document.hasFocus()||y();window.addEventListener("focus",m),window.addEventListener("blur",y)}(),function(){e.pauseOnFocusLoss&&(window.removeEventListener("focus",m),window.removeEventListener("blur",y))}}),[e.pauseOnFocusLoss]);var k={onMouseDown:j,onTouchStart:j,onMouseUp:O,onTouchEnd:O};return d&&f&&(k.onMouseEnter=y,k.onMouseLeave=m),h&&(k.onClick=function(e){v&&v(e),u.canCloseOnClick&&p()}),{playToast:m,pauseToast:y,isRunning:n,preventExitTransition:o,toastRef:s,eventHandlers:k}}function C(e){var t=e.closeToast,n=e.theme,i=e.ariaLabel,a=void 0===i?"close":i;return Object(r.createElement)("button",{className:"Toastify__close-button Toastify__close-button--"+n,type:"button",onClick:function(e){e.stopPropagation(),t(e)},"aria-label":a},Object(r.createElement)("svg",{"aria-hidden":"true",viewBox:"0 0 14 16"},Object(r.createElement)("path",{fillRule:"evenodd",d:"M7.71 8.23l3.75 3.75-1.48 1.48-3.75-3.75-3.75 3.75L1 11.98l3.75-3.75L1 4.48 2.48 3l3.75 3.75L9.98 3l1.48 1.48-3.75 3.75z"})))}function S(e){var t,n,i=e.delay,a=e.isRunning,c=e.closeToast,u=e.type,l=e.hide,d=e.className,f=e.style,p=e.controlledProgress,v=e.progress,h=e.rtl,j=e.isIn,O=e.theme,m=s({},f,{animationDuration:i+"ms",animationPlayState:a?"running":"paused",opacity:l?0:1});p&&(m.transform="scaleX("+v+")");var y=o("Toastify__progress-bar",p?"Toastify__progress-bar--controlled":"Toastify__progress-bar--animated","Toastify__progress-bar-theme--"+O,"Toastify__progress-bar--"+u,((t={})["Toastify__progress-bar--rtl"]=h,t)),g=b(d)?d({rtl:h,type:u,defaultClassName:y}):o(y,d),_=((n={})[p&&v>=1?"onTransitionEnd":"onAnimationEnd"]=p&&v<1?null:function(){j&&c()},n);return Object(r.createElement)("div",Object.assign({role:"progressbar","aria-hidden":l?"true":"false","aria-label":"notification timer",className:g,style:m},_))}S.defaultProps={type:m.DEFAULT,hide:!1};var F=["theme","type"],I=function(e){var t=e.theme,n=e.type,r=u(e,F);return i.a.createElement("svg",Object.assign({viewBox:"0 0 24 24",width:"100%",height:"100%",fill:"colored"===t?"currentColor":"var(--toastify-icon-color-"+n+")"},r))};var N={info:function(e){return i.a.createElement(I,Object.assign({},e),i.a.createElement("path",{d:"M12 0a12 12 0 1012 12A12.013 12.013 0 0012 0zm.25 5a1.5 1.5 0 11-1.5 1.5 1.5 1.5 0 011.5-1.5zm2.25 13.5h-4a1 1 0 010-2h.75a.25.25 0 00.25-.25v-4.5a.25.25 0 00-.25-.25h-.75a1 1 0 010-2h1a2 2 0 012 2v4.75a.25.25 0 00.25.25h.75a1 1 0 110 2z"}))},warning:function(e){return i.a.createElement(I,Object.assign({},e),i.a.createElement("path",{d:"M23.32 17.191L15.438 2.184C14.728.833 13.416 0 11.996 0c-1.42 0-2.733.833-3.443 2.184L.533 17.448a4.744 4.744 0 000 4.368C1.243 23.167 2.555 24 3.975 24h16.05C22.22 24 24 22.044 24 19.632c0-.904-.251-1.746-.68-2.44zm-9.622 1.46c0 1.033-.724 1.823-1.698 1.823s-1.698-.79-1.698-1.822v-.043c0-1.028.724-1.822 1.698-1.822s1.698.79 1.698 1.822v.043zm.039-12.285l-.84 8.06c-.057.581-.408.943-.897.943-.49 0-.84-.367-.896-.942l-.84-8.065c-.057-.624.25-1.095.779-1.095h1.91c.528.005.84.476.784 1.1z"}))},success:function(e){return i.a.createElement(I,Object.assign({},e),i.a.createElement("path",{d:"M12 0a12 12 0 1012 12A12.014 12.014 0 0012 0zm6.927 8.2l-6.845 9.289a1.011 1.011 0 01-1.43.188l-4.888-3.908a1 1 0 111.25-1.562l4.076 3.261 6.227-8.451a1 1 0 111.61 1.183z"}))},error:function(e){return i.a.createElement(I,Object.assign({},e),i.a.createElement("path",{d:"M11.983 0a12.206 12.206 0 00-8.51 3.653A11.8 11.8 0 000 12.207 11.779 11.779 0 0011.8 24h.214A12.111 12.111 0 0024 11.791 11.766 11.766 0 0011.983 0zM10.5 16.542a1.476 1.476 0 011.449-1.53h.027a1.527 1.527 0 011.523 1.47 1.475 1.475 0 01-1.449 1.53h-.027a1.529 1.529 0 01-1.523-1.47zM11 12.5v-6a1 1 0 012 0v6a1 1 0 11-2 0z"}))},spinner:function(){return i.a.createElement("div",{className:"Toastify__spinner"})}},A=function(e){var t,n,i=D(e),a=i.isRunning,c=i.preventExitTransition,s=i.toastRef,u=i.eventHandlers,l=e.closeButton,d=e.children,p=e.autoClose,v=e.onClick,h=e.type,j=e.hideProgressBar,O=e.closeToast,m=e.transition,y=e.position,g=e.className,_=e.style,x=e.bodyClassName,k=e.bodyStyle,T=e.progressClassName,w=e.progressStyle,E=e.updateId,C=e.role,F=e.progress,I=e.rtl,A=e.toastId,M=e.deleteToast,P=e.isIn,L=e.isLoading,R=e.icon,z=e.theme,B=o("Toastify__toast","Toastify__toast-theme--"+z,"Toastify__toast--"+h,((t={})["Toastify__toast--rtl"]=I,t)),V=b(g)?g({rtl:I,position:y,type:h,defaultClassName:B}):o(B,g),$=!!F,U=N[h],H={theme:z,type:h},G=U&&U(H);return!1===R?G=void 0:b(R)?G=R(H):Object(r.isValidElement)(R)?G=Object(r.cloneElement)(R,H):f(R)?G=R:L&&(G=N.spinner()),Object(r.createElement)(m,{isIn:P,done:M,position:y,preventExitTransition:c,nodeRef:s},Object(r.createElement)("div",Object.assign({id:A,onClick:v,className:V},u,{style:_,ref:s}),Object(r.createElement)("div",Object.assign({},P&&{role:C},{className:b(x)?x({type:h}):o("Toastify__toast-body",x),style:k}),G&&Object(r.createElement)("div",{className:o("Toastify__toast-icon",(n={},n["Toastify--animate-icon Toastify__zoom-enter"]=!L,n))},G),Object(r.createElement)("div",null,d)),function(e){if(e){var t={closeToast:O,type:h,theme:z};return b(e)?e(t):Object(r.isValidElement)(e)?Object(r.cloneElement)(e,t):void 0}}(l),(p||$)&&Object(r.createElement)(S,Object.assign({},E&&!$?{key:"pb-"+E}:{},{rtl:I,theme:z,delay:p,isRunning:a,isIn:P,closeToast:O,hide:j,type:h,style:w,className:T,controlledProgress:$,progress:F}))))},M=y({enter:"Toastify--animate Toastify__bounce-enter",exit:"Toastify--animate Toastify__bounce-exit",appendPosition:!0}),P=function(e){var t=T(e),n=t.getToastToRender,i=t.containerRef,a=t.isToastActive,c=e.className,u=e.style,l=e.rtl,d=e.containerId;function f(e){var t,n=o("Toastify__toast-container","Toastify__toast-container--"+e,((t={})["Toastify__toast-container--rtl"]=l,t));return b(c)?c({position:e,rtl:l,defaultClassName:n}):o(n,p(c))}return Object(r.createElement)("div",{ref:i,className:"Toastify",id:d},n((function(e,t){var n=0===t.length?s({},u,{pointerEvents:"none"}):s({},u);return Object(r.createElement)("div",{className:f(e),style:n,key:"container-"+e},t.map((function(e){var t=e.content,n=e.props;return Object(r.createElement)(A,Object.assign({},n,{isIn:a(n.toastId),key:"toast-"+n.key,closeButton:!0===n.closeButton?C:n.closeButton}),t)})))})))};P.defaultProps={position:O.TOP_RIGHT,transition:M,rtl:!1,autoClose:5e3,hideProgressBar:!1,closeButton:C,pauseOnHover:!0,pauseOnFocusLoss:!0,closeOnClick:!0,newestOnTop:!1,draggable:!0,draggablePercent:80,draggableDirection:"x",role:"alert",theme:"light"};var L,R,z,B=new Map,V=[],$=!1;function U(){return Math.random().toString(36).substr(2,9)}function H(e){return e&&(f(e.toastId)||l(e.toastId))?e.toastId:U()}function G(e,t){return B.size>0?g.emit(0,e,t):(V.push({content:e,options:t}),$&&h&&($=!1,R=document.createElement("div"),document.body.appendChild(R),Object(c.render)(Object(r.createElement)(P,Object.assign({},z)),R))),t.toastId}function W(e,t){return s({},t,{type:t&&t.type||e,toastId:H(t)})}var q=function(e){return function(t,n){return G(t,W(e,n))}},K=function(e,t){return G(e,W(m.DEFAULT,t))};K.loading=function(e,t){return G(e,W(m.DEFAULT,s({isLoading:!0,autoClose:!1,closeOnClick:!1,closeButton:!1,draggable:!1},t)))},K.promise=function(e,t,n){var r=t.pending,i=t.error,a=t.success,o=f(r)?K.loading(r,n):K.loading(r.render,s({},n,r)),c={isLoading:null,autoClose:null,closeOnClick:null,closeButton:null,draggable:null},u=function(e,t,r){var i=f(t)?{render:t}:t;return K.update(o,s({type:e},c,n,i,{data:r})),r},l=b(e)?e():e;return l.then((function(e){return u("success",a,e)})).catch((function(e){return u("error",i,e)})),l},K.success=q(m.SUCCESS),K.info=q(m.INFO),K.error=q(m.ERROR),K.warning=q(m.WARNING),K.warn=K.warning,K.dark=function(e,t){return G(e,W(m.DEFAULT,s({theme:"dark"},t)))},K.dismiss=function(e){return g.emit(1,e)},K.clearWaitingQueue=function(e){return void 0===e&&(e={}),g.emit(5,e)},K.isActive=function(e){var t=!1;return B.forEach((function(n){n.isToastActive&&n.isToastActive(e)&&(t=!0)})),t},K.update=function(e,t){void 0===t&&(t={}),setTimeout((function(){var n=function(e,t){var n=t.containerId,r=B.get(n||L);return r?r.getToast(e):null}(e,t);if(n){var r=n.props,i=n.content,a=s({},r,t,{toastId:t.toastId||e,updateId:U()});a.toastId!==e&&(a.staleId=e);var o=a.render||i;delete a.render,G(o,a)}}),0)},K.done=function(e){K.update(e,{progress:1})},K.onChange=function(e){return b(e)&&g.on(4,e),function(){b(e)&&g.off(4,e)}},K.configure=function(e){void 0===e&&(e={}),$=!0,z=e},K.POSITION=O,K.TYPE=m,g.on(2,(function(e){L=e.containerId||e,B.set(L,e),V.forEach((function(e){g.emit(0,e.content,e.options)})),V=[]})).on(3,(function(e){B.delete(e.containerId||e),0===B.size&&g.off(0).off(1).off(5),h&&R&&document.body.removeChild(R)}))},14:function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}n.d(t,"a",(function(){return r}))},1410:function(e,t,n){"use strict";var r=n(2),i=n(9),a=n(0),o=n(31),c=n(4),s=n(17),u={deletedTickets:[],tickets:{},isDirty:!1},l=function(e){return Object(a.useCallback)((function(t,n){var i,a,l,d=n.id,f=n.ticket;switch(n.type){case"ADD_TICKET":case"UPDATE_TICKET":i=d||Object(s.uuid)(),l=c.path(["tickets",i],t),a=c.assocPath(["tickets",i],Object(r.a)(Object(r.a)(Object(r.a)({},l),f),{},{id:i,isModified:Boolean(d),isDefault:!0}),t);break;case"DELETE_TICKET":a=Object(r.a)(Object(r.a)({},t),{},{tickets:c.omit([d],t.tickets)});break;case"ADD_TICKET_TO_DELETED":a=t.deletedTickets.includes(d)?t:Object(r.a)(Object(r.a)({},t),{},{deletedTickets:[].concat(Object(o.a)(t.deletedTickets),[d])});break;case"RESET":return e(u);default:throw new Error("Unexpected action")}return Object(r.a)(Object(r.a)({},a),{},{isDirty:!0})}),[e])},d=n(537);t.a=function(){var e=Object(d.a)(),t=l(e),n=Object(a.useReducer)(t,u,e),o=Object(i.a)(n,2),c=o[0],s=o[1],f=Object(a.useCallback)((function(){return c}),[c]),b=Object(a.useCallback)((function(e){s({type:"ADD_TICKET",ticket:e})}),[]),p=Object(a.useCallback)((function(e,t){s({type:"UPDATE_TICKET",id:e,ticket:t})}),[]),v=Object(a.useCallback)((function(e,t){t||s({type:"ADD_TICKET_TO_DELETED",id:e}),s({type:"DELETE_TICKET",id:e})}),[]),h=Object(a.useCallback)((function(){s({type:"RESET"})}),[]);return Object(a.useMemo)((function(){return Object(r.a)(Object(r.a)({},c),{},{addTicket:b,deleteTicket:v,getData:f,updateTicket:p,reset:h})}),[c])}},1411:function(e,t,n){"use strict";var r=n(2),i=n(9),a=n(0),o=function(e,t){var n=t.type,i=t.datesByMonth,a=t.showTrashedDates,o=t.showExpiredTickets,c=t.showTrashedTickets;switch(n){case"SET_DATES_BY_MONTH":return Object(r.a)(Object(r.a)({},e),{},{datesByMonth:i});case"SET_SHOW_TRASHED_DATES":return Object(r.a)(Object(r.a)({},e),{},{showTrashedDates:a});case"SET_SHOW_EXPIRED_TICKETS":return Object(r.a)(Object(r.a)({},e),{},{showExpiredTickets:o});case"SET_SHOW_TRASHED_TICKETS":return Object(r.a)(Object(r.a)({},e),{},{showTrashedTickets:c});default:throw new Error("Unexpected action")}},c={datesByMonth:[0,0],showExpiredTickets:!1,showTrashedDates:!1,showTrashedTickets:!1};t.a=function(){var e=Object(a.useReducer)(o,c),t=Object(i.a)(e,2),n=t[0],s=t[1],u=Object(a.useCallback)((function(e){var t=e.split(":").map(Number),n=Object(i.a)(t,2),r=n[0],a=n[1];s({type:"SET_DATES_BY_MONTH",datesByMonth:[r,a]})}),[]),l=Object(a.useCallback)((function(e){s({type:"SET_SHOW_EXPIRED_TICKETS",showExpiredTickets:e})}),[]),d=Object(a.useCallback)((function(e){s({type:"SET_SHOW_TRASHED_DATES",showTrashedDates:e})}),[]),f=Object(a.useCallback)((function(e){s({type:"SET_SHOW_TRASHED_TICKETS",showTrashedTickets:e})}),[]);return Object(a.useMemo)((function(){return Object(r.a)(Object(r.a)({},n),{},{setDatesByMonth:u,setShowExpiredTickets:l,setShowTrashedDates:d,setShowTrashedTickets:f})}),[n])}},1434:function(e,t){e.exports=window.eventespresso.formBuilder},148:function(e,t,n){var r=n(642),i=n(645);e.exports=function(e,t){var n=i(e,t);return r(n)?n:void 0}},15:function(e,t,n){"use strict";function r(e,t){if(t.length1?"s":"")+" required, but only "+t.length+" present")}n.d(t,"a",(function(){return r}))},151:function(e,t,n){var r=n(633),i=n(386);e.exports=function(e,t){return null!=e&&i(e,t,r)}},1555:function(e,t,n){"use strict";var r=n(2),i=n(22),a=n(1);t.a=Object(i.a)((function(e){return Object(a.jsx)("svg",Object(r.a)(Object(r.a)({viewBox:"64 64 896 896","data-icon":"close",fill:"currentColor","aria-hidden":"true",height:"1.5em",width:"1.5em",className:"ee-svg--close-outlined"},e),{},{children:Object(a.jsx)("path",{d:"M563.8 512l262.5-312.9c4.4-5.2.7-13.1-6.1-13.1h-79.8c-4.7 0-9.2 2.1-12.3 5.7L511.6 449.8 295.1 191.7c-3-3.6-7.5-5.7-12.3-5.7H203c-6.8 0-10.5 7.9-6.1 13.1L459.4 512 196.9 824.9A7.95 7.95 0 00203 838h79.8c4.7 0 9.2-2.1 12.3-5.7l216.5-258.1 216.5 258.1c3 3.6 7.5 5.7 12.3 5.7h79.8c6.8 0 10.5-7.9 6.1-13.1L563.8 512z"})}))}),"close-outlined")},158:function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(r){"object"===typeof window&&(n=window)}e.exports=n},159:function(e,t){},16:function(e,t){e.exports=window.eventespresso.edtrServices},1662:function(e,t,n){"use strict";var r=n(2),i=n(22),a=n(1);t.a=Object(i.a)((function(e){return Object(a.jsx)("svg",Object(r.a)(Object(r.a)({"aria-hidden":"true",height:"1.5em",viewBox:"0 0 20 20",width:"1.5em",xmlns:"http://www.w3.org/2000/svg",className:"ee-svg--link"},e),{},{children:Object(a.jsx)("path",{d:"M17.74 2.76a4.321 4.321 0 010 6.1l-1.53 1.52c-1.12 1.12-2.7 1.47-4.14 1.09l2.62-2.61.76-.77.76-.76c.84-.84.84-2.2 0-3.04a2.13 2.13 0 00-3.04 0l-.77.76-3.38 3.38c-.37-1.44-.02-3.02 1.1-4.14l1.52-1.53a4.321 4.321 0 016.1 0zM8.59 13.43l5.34-5.34c.42-.42.42-1.1 0-1.52-.44-.43-1.13-.39-1.53 0l-5.33 5.34c-.42.42-.42 1.1 0 1.52.44.43 1.13.39 1.52 0zm-.76 2.29l4.14-4.15c.38 1.44.03 3.02-1.09 4.14l-1.52 1.53a4.321 4.321 0 01-6.1 0 4.321 4.321 0 010-6.1l1.53-1.52c1.12-1.12 2.7-1.47 4.14-1.1l-4.14 4.15c-.85.84-.85 2.2 0 3.05.84.84 2.2.84 3.04 0z"})}))}),"link")},1663:function(e,t,n){"use strict";var r=n(2),i=n(22),a=n(1);t.a=Object(i.a)((function(e){return Object(a.jsx)("svg",Object(r.a)(Object(r.a)({"aria-hidden":"true",height:"1.5em",viewBox:"0 0 20 20",width:"1.5em",xmlns:"http://www.w3.org/2000/svg",className:"ee-svg--unlink"},e),{},{children:Object(a.jsx)("path",{d:"M17.74 2.26a4.321 4.321 0 010 6.1l-1.53 1.52c-.32.33-.69.58-1.08.77L13 10l1.69-1.64.76-.77.76-.76c.84-.84.84-2.2 0-3.04a2.13 2.13 0 00-3.04 0l-.77.76-.76.76L10 7l-.65-2.14c.19-.38.44-.75.77-1.07l1.52-1.53a4.321 4.321 0 016.1 0zM2 4l8 6-6-8zm4-2l4 8-2-8H6zM2 6l8 4-8-2V6zm7.36 7.69L10 13l.74 2.35-1.38 1.39a4.321 4.321 0 01-6.1 0 4.321 4.321 0 010-6.1l1.39-1.38L7 10l-.69.64-1.52 1.53c-.85.84-.85 2.2 0 3.04.84.85 2.2.85 3.04 0zM18 16l-8-6 6 8zm-4 2l-4-8 2 8h2zm4-4l-8-4 8 2v2z"})}))}),"unlink")},1674:function(e,t,n){"use strict";var r=n(2),i=n(22),a=n(1);t.a=Object(i.a)((function(e){return Object(a.jsx)("svg",Object(r.a)(Object(r.a)({"aria-hidden":"true",height:"1.5em",viewBox:"-1 -1 22 22",width:"1.5em",xmlns:"http://www.w3.org/2000/svg",className:"ee-svg--calculator"},e),{},{children:Object(a.jsx)("path",{d:"M3 0v20h14V0H3zm2.5 2.5h9v2h-9v-2zm0 4h2v1.75h-2V6.5zm3.5 0h2v1.75H9V6.5zm3.5 0h2v1.75h-2V6.5zm-7 3h2v1.75h-2V9.5zm3.5 0h2v1.75H9V9.5zm3.5 0h2v1.75h-2V9.5zm-7 3h2v1.75h-2V12.5zm3.5 0h2v1.75H9V12.5zm3.5 0h2v1.75h-2V12.5zm-7 3h2v1.75h-2V15.5zm3.5 0h2v1.75H9V15.5zm3.5 0h2v1.75h-2V15.5z"})}))}),"calculator")},1676:function(e,t,n){"use strict";var r=n(2),i=n(22),a=n(1);t.a=Object(i.a)((function(e){return Object(a.jsx)("svg",Object(r.a)(Object(r.a)({"aria-hidden":"true",height:"1.8em",viewBox:"0 1 24 24",width:"1.8em",xmlns:"https://www.w3.org/2000/svg",className:"ee-svg--map-marker"},e),{},{children:Object(a.jsx)("path",{fillRule:"evenodd",d:"M12 2C8.13 2 5 5.13 5 9c0 5.25 7 13 7 13s7-7.75 7-13c0-3.87-3.13-7-7-7zm0 9.5a2.5 2.5 0 010-5 2.5 2.5 0 010 5z"})}))}),"map-marker")},1677:function(e,t,n){"use strict";var r=n(2),i=n(22),a=n(1);t.a=Object(i.a)((function(e){return Object(a.jsx)("svg",Object(r.a)(Object(r.a)({"aria-hidden":"true",height:"1.5em",viewBox:"-2 -1.5 23 23",width:"1.5em",xmlns:"http://www.w3.org/2000/svg",className:"ee-svg--calendar"},e),{},{children:Object(a.jsx)("path",{d:"M0 2v18h20V2zm2 4.5h16V18H2zM15.5 0v8h-1.38l-2.58 2.06.8 1.2.92-.74c.12-.1.32-.28.6-.56l-.04.84v5.7h1.68zm-6 10c0-.6-.24-1.08-.74-1.42-.48-.34-1.16-.52-2-.52-1.04 0-1.92.26-2.66.8l.8 1.2c.34-.22.64-.38.92-.46.28-.1.54-.14.82-.14.76 0 1.16.3 1.16.92 0 .4-.14.7-.44.86s-.76.24-1.4.24h-.62v1.32h.62c.68 0 1.18.08 1.5.24.3.16.46.44.46.82 0 .44-.14.74-.4.94-.28.2-.7.3-1.26.3-.38 0-.76-.06-1.14-.16s-.72-.24-1.04-.4v1.48c.68.3 1.48.44 2.36.44 1.06 0 1.88-.22 2.44-.66.58-.44.86-1.04.86-1.84 0-.54-.18-.96-.52-1.28s-.84-.52-1.48-.6v-.04c.54-.12.98-.38 1.3-.74.3-.36.46-.78.46-1.3zM4 0h2v2H4V0zm10 0h2v2h-2V0z"})}))}),"calendar")},1678:function(e,t,n){"use strict";var r=n(2),i=n(22),a=n(1);t.a=Object(i.a)((function(e){return Object(a.jsx)("svg",Object(r.a)(Object(r.a)({viewBox:"60 80 900 900","data-icon":"calendar",fill:"currentColor","aria-hidden":"true",height:"1.5em",width:"1.5em",className:"ee-svg--calendar-outlined"},e),{},{children:Object(a.jsx)("path",{d:"M880 184H712v-64c0-4.4-3.6-8-8-8h-56c-4.4 0-8 3.6-8 8v64H384v-64c0-4.4-3.6-8-8-8h-56c-4.4 0-8 3.6-8 8v64H144c-17.7 0-32 14.3-32 32v664c0 17.7 14.3 32 32 32h736c17.7 0 32-14.3 32-32V216c0-17.7-14.3-32-32-32zm-40 656H184V460h656v380zM184 392V256h128v48c0 4.4 3.6 8 8 8h56c4.4 0 8-3.6 8-8v-48h256v48c0 4.4 3.6 8 8 8h56c4.4 0 8-3.6 8-8v-48h128v136H184z"})}))}),"calendar-outlined")},169:function(e,t,n){"use strict";var r=n(280);n.d(t,"ContextProvider",(function(){return r.b}));var i=n(534);n.d(t,"DataStateContext",(function(){return i.a}));var a=n(536);n.d(t,"FilterStateContext",(function(){return a.a}));var o=n(1258);n.d(t,"withContext",(function(){return o.a}));var c=n(1259);n.d(t,"useTAMContext",(function(){return c.a}));n(1260)},1692:function(e,t,n){e.exports=n(1694)},1694:function(e,t,n){"use strict";var r,i,a,o;n.r(t);var c=window.baristaAssetsUrl||(null===(r=window)||void 0===r||null===(i=r.eventEspressoData)||void 0===i||null===(a=i.config)||void 0===a||null===(o=a.coreDomain)||void 0===o?void 0:o.distributionAssetsUrl);n.p=c;c=n.p,n(237);var s,u=n(16),l=n(17),d=n(600),f=n(461),b=n(27),p=n(45),v=new p.ModalSubscription(u.domain).getSubscriptions,h=new p.ModalRegistry({domain:u.domain}),j=n(0),O=n(3),m=n(24),y=n(64),g=n(2),_=n(22),x=n(1),k=Object(_.a)((function(e){return Object(x.jsx)("svg",Object(g.a)(Object(g.a)({"aria-hidden":"true",height:"1.5em",viewBox:"-2 0 22 22",width:"1.5em",xmlns:"http://www.w3.org/2000/svg",className:"ee-svg--ticket"},e),{},{children:Object(x.jsx)("path",{d:"M20 6.38L18.99 9.2v-.01c-.52-.19-1.03-.16-1.53.08s-.85.62-1.04 1.14-.16 1.03.07 1.53c.24.5.62.84 1.15 1.03v.01l-1.01 2.82-15.06-5.38.99-2.79c.52.19 1.03.16 1.53-.08.5-.23.84-.61 1.03-1.13s.16-1.03-.08-1.53a1.93 1.93 0 00-1.13-1.02L4.93 1zm-4.97 5.69l1.37-3.76c.12-.31.1-.65-.04-.95s-.39-.53-.7-.65L8.14 3.98c-.64-.23-1.37.12-1.6.74L5.17 8.48c-.24.65.1 1.37.74 1.6l7.52 2.74c.14.05.28.08.43.08.52 0 1-.33 1.17-.83zM7.97 4.45l7.51 2.73c.19.07.34.21.43.39.08.18.09.38.02.57l-1.37 3.76c-.13.38-.58.59-.96.45L6.09 9.61a.75.75 0 01-.45-.96l1.37-3.76c.1-.29.39-.49.7-.49.09 0 .17.02.26.05zm6.82 12.14c.35.27.75.41 1.2.41H16v3H0v-2.96c.55 0 1.03-.2 1.41-.59.39-.38.59-.86.59-1.41s-.2-1.02-.59-1.41-.86-.59-1.41-.59V10h1.05l-.28.8 2.87 1.02c-.51.16-.89.62-.89 1.18v4c0 .69.56 1.25 1.25 1.25h8c.69 0 1.25-.56 1.25-1.25v-1.75l.83.3c.12.43.36.78.71 1.04zM3.25 17v-4c0-.41.34-.75.75-.75h.83l7.92 2.83V17c0 .41-.34.75-.75.75H4c-.41 0-.75-.34-.75-.75z"})}))}),"ticket"),T=n(5),w=n(36),E=n(1677),D=function(e){var t=e.isOnlyButton,n=Object(p.useGlobalModal)(u.EdtrGlobalModals.EDIT_DATE).open,r=Object(j.useMemo)((function(){var e=u.hooks.applyFilters("eventEditor.addSingleDate.buttonProps",w.EMPTY_OBJECT,t);return u.hooks.applyFilters("eventEditor.addSingleDate.button",Object(x.jsx)(T.Button,Object(g.a)({buttonText:t?Object(O.__)("Add New Date"):Object(O.__)("Add Single Date"),buttonType:"primary",onClick:n,icon:t&&E.a,size:t?"big":"default"},e)),t)}),[t,n]);return t?r:Object(x.jsx)(T.NewEntityOption,{className:"ee-new-entity-option__single-datetime",description:Object(O.__)("Add a single date that only occurs once"),icon:E.a,title:Object(O.__)("Single Date"),children:r})},C=function(e){var t=e.children,n=Object(p.useGlobalModal)(u.EdtrGlobalModals.NEW_DATE).openWithData,r=Object(j.useCallback)((function(){n({children:t})}),[t,n]);return Object(x.jsx)(T.Button,{buttonText:Object(O.__)("Add New Date"),buttonType:"primary",icon:E.a,mr:2,onClick:r,size:"big"})},S=function(){return Object(x.jsx)(u.NewDateOptions,{children:function(e){return e.length>1?Object(x.jsx)(C,{children:e}):Object(x.jsx)(x.Fragment,{children:e})}})},F=function(){var e=Object(p.useGlobalModal)(u.EdtrGlobalModals.NEW_DATE),t=e.isOpen,n=e.close,r=e.getData;return t&&Object(x.jsx)(T.NewEntityModal,{isOpen:!0,onClose:n,title:Object(O.__)("Add New Date"),children:r().children})},I=Object(m.withCurrentUserCan)(w.USE_ADVANCED_EDITOR)((function(){var e=Object(p.useGlobalModal)(u.EdtrGlobalModals.TAM).openWithData,t=Object(u.useDatetimes)(),n=Object(u.useTickets)(),r=!t.length||!n.length,i=r&&Object(O.__)("Add a date or a ticket in order to use Ticket Assignment Manager"),a=Object(j.useCallback)((function(){e({assignmentType:"forAll"})}),[e]);return Object(x.jsxs)(T.ButtonRow,{children:[Object(x.jsx)(S,{}),Object(x.jsx)(T.Button,{buttonText:Object(O.__)("Ticket Assignments"),icon:k,isDisabled:r,onClick:a,size:"big",tooltip:i})]})})),N=function(){var e=Object(u.useDatetimes)();return Object(x.jsxs)(x.Fragment,{children:[Object(x.jsx)(y.EntityCacheIds,{entities:e}),Object(x.jsx)(I,{})]})};!function(e){e.CALENDAR="calendar",e.CALCULATOR="calculator",e.EDIT="edit",e.FILTER="filter",e.GROUPS="groups",e.TICKET="ticket-alt"}(s||(s={}));var A,M,P,L,R,z,B=n(467),V={icons:[{icon:s.EDIT,description:Object(O.__)("Edit Event Date Details")},{icon:s.GROUPS,description:Object(O.__)("View Registrations for this Date")},{icon:s.TICKET,description:Object(O.__)("Manage Ticket Assignments")},{icon:B.a,description:Object(O.__)("Move Date to Trash")}],swatches:{DTA:Object(O.__)("Active"),DTT:Object(O.__)("Trashed"),DTE:Object(O.__)("Expired"),DTS:Object(O.__)("Sold Out"),DTU:Object(O.__)("Upcoming")}},$=Object(j.lazy)((function(){return n.e(5).then(n.bind(null,1795))})),U=function(){return Object(x.jsx)(j.Suspense,{fallback:Object(x.jsx)(T.LoadingNotice,{}),children:Object(x.jsx)($,{})})},H=Object(j.lazy)((function(){return n.e(6).then(n.bind(null,1794))})),G=function(){return Object(x.jsx)(j.Suspense,{fallback:Object(x.jsx)(T.LoadingNotice,{}),children:Object(x.jsx)(H,{})})},W=n(12),q=n(14),K=(A={},Object(q.a)(A,u.DisplayStartOrEndDate.start,Object(O.__)("start dates only")),Object(q.a)(A,u.DisplayStartOrEndDate.end,Object(O.__)("end dates only")),Object(q.a)(A,u.DisplayStartOrEndDate.both,Object(O.__)("start and end dates")),A),Y=(M={},Object(q.a)(M,W.DatetimeSales.all,Object(O.__)("all dates")),Object(q.a)(M,W.DatetimeSales.above90Capacity,Object(O.__)("dates above 90% capacity")),Object(q.a)(M,W.DatetimeSales.above75Capacity,Object(O.__)("dates above 75% capacity")),Object(q.a)(M,W.DatetimeSales.above50Capacity,Object(O.__)("dates above 50% capacity")),Object(q.a)(M,W.DatetimeSales.below50Capacity,Object(O.__)("dates below 50% capacity")),M),Z=(P={},Object(q.a)(P,W.DatetimeStatus.all,Object(O.__)("all dates")),Object(q.a)(P,W.DatetimeStatus.activeUpcoming,Object(O.__)("all active and upcoming")),Object(q.a)(P,W.DatetimeStatus.activeOnly,Object(O.__)("active dates only")),Object(q.a)(P,W.DatetimeStatus.upcomingOnly,Object(O.__)("upcoming dates only")),Object(q.a)(P,W.DatetimeStatus.nextActiveUpcomingOnly,Object(O.__)("next active or upcoming only")),Object(q.a)(P,W.DatetimeStatus.soldOutOnly,Object(O.__)("sold out dates only")),Object(q.a)(P,W.DatetimeStatus.recentlyExpiredOnly,Object(O.__)("recently expired dates")),Object(q.a)(P,W.DatetimeStatus.expiredOnly,Object(O.__)("all expired dates")),Object(q.a)(P,W.DatetimeStatus.trashedOnly,Object(O.__)("trashed dates only")),P),Q={date:Object(O.__)("start date"),name:Object(O.__)("name"),id:Object(O.__)("ID"),order:Object(O.__)("custom order")},J={displayStartOrEndDate:Object(O.__)("display"),recurrence:Object(O.__)("recurrence"),sales:Object(O.__)("sales"),sortBy:Object(O.__)("sort by"),search:Object(O.__)("search"),status:Object(O.__)("status")},X=function(){var e=Object(u.useDatesListFilterState)(),t=e.status,n=e.setStatus,r=e.sales,i=e.setSales,a=e.searchText,o=e.setSearchText,c=e.recurrence,s=e.setRecurrence,l="".concat(J.status,": ").concat(null===Z||void 0===Z?void 0:Z[t]),d="".concat(J.sales,": ").concat(null===Y||void 0===Y?void 0:Y[r]),f="".concat(J.search,": ").concat(a),b="".concat(J.recurrence,": ").concat(Object(O.__)("ON")),p=Object(j.useCallback)((function(){return n(W.DatetimeStatus.all)}),[n]),v=Object(j.useCallback)((function(){return i(W.DatetimeSales.all)}),[i]),h=Object(j.useCallback)((function(){return s("")}),[s]),m=Object(j.useCallback)((function(){return o("")}),[o]);return Object(x.jsxs)(T.ActiveFilters,{children:[t!==W.DatetimeStatus.all&&Object(x.jsx)(T.FilterTag,{title:l,onRemove:p}),r!==W.DatetimeSales.all&&Object(x.jsx)(T.FilterTag,{title:d,onRemove:v}),c&&Object(x.jsx)(T.FilterTag,{title:b,onRemove:h}),a?Object(x.jsx)(T.FilterTag,{title:f,onRemove:m}):null]})},ee=Object(l.objectToSelectOptions)(K),te=function(){var e=Object(u.useDatesListFilterState)(),t=e.displayStartOrEndDate,n=e.setDisplayStartOrEndDate;return Object(x.jsx)(T.SelectWithLabel,{id:"ee-dates-list-display-control",label:J.displayStartOrEndDate,value:t,options:ee,onChangeValue:n})},ne=Object(l.objectToSelectOptions)(Y),re=function(){var e=Object(u.useDatesListFilterState)(),t=e.sales,n=e.setSales;return Object(x.jsx)(T.SelectWithLabel,{id:"ee-dates-list-sales-control",label:J.sales,onChangeValue:n,options:ne,value:t})},ie=Object(l.objectToSelectOptions)(Z),ae=function(){var e=Object(u.useDatesListFilterState)(),t=e.status,n=e.setStatus;return Object(x.jsx)(T.SelectWithLabel,{id:"ee-dates-list-status-control",label:J.status,onChangeValue:n,options:ie,value:t})},oe={month:"LLL"},ce=function(e){var t=e.dbId,n=e.endDate,r=e.name,i=e.startDate;return Object(x.jsxs)(x.Fragment,{children:[Object(x.jsxs)("span",{children:[t,")"]}),Object(x.jsxs)("span",{children:[r,": "]}),Object(x.jsx)(y.RangeFormat,{endDate:n,formatTokens:oe,showTime:!0,startDate:i})]})},se=Object(l.objectToSelectOptions)(Q),ue=function(e){return Object(g.a)(Object(g.a)({},e),{},{content:Object(x.jsx)(ce,Object(g.a)({},e))})},le=function(){var e=Object(u.useDatesListFilterState)(),t=e.sortBy,n=e.setSortBy,r=Object(u.useFilteredDateIds)(),i=Object(u.useReorderDatetimes)(r),a=i.allReorderedEntities,o=i.sortResponder,c=i.updateEntityList;return Object(x.jsx)(y.SortByControl,{draggableItems:a,droppableId:w.datetimesDroppableId,entityType:m.TypeName.datetimes,id:"ee-dates-list-sort-by-control",label:J.sortBy,renderDraggableItem:ue,onChangeValue:n,onSort:o,onSubmit:c,options:se,value:t})},de=Object(u.withEntityListContext)({Provider:u.DatetimesListProvider,Component:function(){var e=Object(u.useDatesListFilterState)(),t=Object(j.useCallback)((function(){return"card"===e.view?Object(x.jsx)(U,{}):Object(x.jsx)(G,{})}),[e.view]);return Object(x.jsx)(y.EntityList,{activeFilters:Object(x.jsx)(X,{}),domain:u.domain,entityType:m.TypeName.datetimes,filterState:e,footer:Object(x.jsx)(N,{}),headerText:Object(O.__)("Event Dates"),legendConfig:V,listId:u.datesList,loadingText:Object(O.__)("loading event dates\u2026"),renderList:t})}}),fe=n(10),be=n.n(fe),pe=n(235),ve=function(e){var t=e.status,n=e.onStatusChange,r=be()("ee-edtr-option","ee-edtr-option__active-status",Object(pe.datetimeStatusBgColorClassName)(null)),i=Object(j.useMemo)((function(){return Object(l.objectToSelectOptions)(w.datetimeStatus)}),[]);return Object(x.jsx)(T.SelectWithLabel,{className:r,fitContainer:!0,flow:"inline",id:"ee-event-registration-active-status-select",label:Object(O.__)("Active status"),labelClassName:"ee-grid__item-label",labelPosition:"left-middle",noBorderColor:!0,onChangeValue:n,options:i,value:t,wrapperClassName:"ee-edtr-option__wrapper ee-edtr-option__active-status-wrapper"})},he=function(e){var t=e.altRegPage,n=e.onAltRegPageChange;return Object(x.jsx)(T.InlineEditTextWithLabel,{className:"ee-edtr-option ee-edtr-option__alt-reg-page",id:"ee-event-registration-alt-reg-page",label:Object(O.__)("Alternative Registration Page"),size:"huge",labelClassName:"ee-grid__item-label",labelPosition:"left-middle",onChange:n,placeholder:"https://",tag:"h4",value:t,wrapperClassName:"ee-edtr-option__wrapper ee-edtr-option__alt-reg-page-wrapper"})},je=function(e){var t,n=e.defaultRegStatus,r=e.onDefaultRegStatusChange,i=Object(j.useMemo)((function(){return W.regStatusOptions.filter((function(e){return e.value===n}))}),[n]),a=be()("ee-edtr-option ee-edtr-option__default-reg-status","ee-status-bg--".concat(null===(t=i[0])||void 0===t?void 0:t.code));return Object(x.jsx)(T.SelectWithLabel,{className:a,fitContainer:!0,flow:"inline",label:Object(O.__)("Default Registration Status"),id:"ee-event-registration-default-status-select",noBorderColor:!0,onChangeValue:r,options:W.regStatusOptions,value:n,labelClassName:"ee-grid__item-label",labelPosition:"left-middle",wrapperClassName:"ee-edtr-option__wrapper ee-edtr-option__default-reg-status-wrapper"})},Oe=function(e){var t=e.allowDonations,n=e.onDonationsChange,r=t?Object(O.__)("Donations Enabled"):Object(O.__)("Donations Disabled");return Object(x.jsx)(T.SwitchWithLabel,{className:"ee-edtr-option ee-edtr-option__event-donations",id:"ee-event-donations",label:r,isChecked:t,onChangeValue:n,debounceDelay:5e3,labelClassName:"ee-grid__item-label",labelPosition:"left-middle",wrapperClassName:"ee-edtr-option__wrapper ee-edtr-option__event-donations-wrapper"})},me=function(e){var t=e.eventManagers,n=e.managerId,r=e.onManagerChange,i=Object(j.useMemo)((function(){return t&&Object(l.entityListToSelectOptions)(t)}),[t]);return Object(x.jsx)(T.SelectWithLabel,{className:"ee-edtr-option ee-edtr-option__event-manager",label:Object(O.__)("Event Manager"),fitContainer:!0,flow:"inline",id:"ee-event-registration-manager",noBorderColor:!0,onChangeValue:r,options:i,value:n,labelClassName:"ee-grid__item-label",labelPosition:"left-middle",wrapperClassName:"ee-edtr-option__wrapper ee-edtr-option__event-manager-wrapper"})},ye=function(e){var t=e.onPhoneNumberChange,n=e.phoneNumber;return Object(x.jsx)(T.InlineEditTextWithLabel,{className:"ee-edtr-option ee-edtr-option__event-phone",id:"ee-event-registration-phone-number",onChange:t,tag:"h4",value:n,label:Object(O.__)("Event Phone Number"),labelClassName:"ee-grid__item-label",labelPosition:"left-middle",placeholder:"123-456-7890",wrapperClassName:"ee-edtr-option__wrapper ee-edtr-option__event-phone-wrapper"})},ge=function(e){var t=e.maxReg,n=e.onMaxRegChange,r=t&&String(t);return Object(x.jsx)(T.InlineEditTextWithLabel,{id:"ee-event-registration-max-reg",label:Object(O.__)("Max Registrations per Transaction"),className:"ee-edtr-option ee-edtr-option__max-reg",labelClassName:"ee-grid__item-label",labelPosition:"left-middle",onChange:n,tag:"h4",value:r,wrapperClassName:"ee-edtr-option__wrapper ee-edtr-option__max-reg-wrapper"})},_e=function(e){var t=e.displayTicketSelector,n=e.onTicketSelectorChange,r=t?Object(O.__)("Ticket Selector Enabled"):Object(O.__)("Ticket Selector Disabled");return Object(x.jsx)(T.SwitchWithLabel,{id:"ee-event-registration-ticket-selector",label:r,className:"ee-edtr-option ee-edtr-option__ticket",isChecked:t,onChangeValue:n,debounceDelay:5e3,labelClassName:"ee-grid__item-label",labelPosition:"left-middle",wrapperClassName:"ee-edtr-option__wrapper ee-edtr-option__ticket-wrapper"})},xe=function(e){return function(){var t,n,r=Object(u.useEvent)(),i=Object(u.useEventManagers)(),a=Object(u.useEventMutator)(null===r||void 0===r?void 0:r.id).updateEntity,o=Object(j.useCallback)((function(e){e!==(null===r||void 0===r?void 0:r.altRegPage)&&a({altRegPage:e})}),[null===r||void 0===r?void 0:r.altRegPage,a]),c=Object(j.useCallback)((function(e){(null===r||void 0===r?void 0:r.allowDonations)!==e&&a({allowDonations:e})}),[null===r||void 0===r?void 0:r.allowDonations,a]),s=Object(j.useCallback)((function(e){(null===r||void 0===r?void 0:r.defaultRegStatus)!==e&&a({defaultRegStatus:e})}),[null===r||void 0===r?void 0:r.defaultRegStatus,a]),l=Object(j.useCallback)((function(e){var t;e!==(null===r||void 0===r||null===(t=r.manager)||void 0===t?void 0:t.id)&&a({manager:e})}),[null===r||void 0===r||null===(t=r.manager)||void 0===t?void 0:t.id,a]),d=Object(j.useCallback)((function(e){var t=Number(e);t!==(null===r||void 0===r?void 0:r.maxRegistrations)&&a({maxRegistrations:t})}),[null===r||void 0===r?void 0:r.maxRegistrations,a]),f=Object(j.useCallback)((function(e){e!==(null===r||void 0===r?void 0:r.phoneNumber)&&a({phoneNumber:e})}),[null===r||void 0===r?void 0:r.phoneNumber,a]),b=Object(j.useCallback)((function(e){e!==(null===r||void 0===r?void 0:r.status)&&a({status:e})}),[null===r||void 0===r?void 0:r.status,a]),p=Object(j.useCallback)((function(e){(null===r||void 0===r?void 0:r.displayTicketSelector)!==e&&a({displayTicketSelector:e})}),[null===r||void 0===r?void 0:r.displayTicketSelector,a]);return Object(x.jsx)(e,{allowDonations:null===r||void 0===r?void 0:r.allowDonations,altRegPage:null===r||void 0===r?void 0:r.altRegPage,defaultRegStatus:null===r||void 0===r?void 0:r.defaultRegStatus,displayTicketSelector:null===r||void 0===r?void 0:r.displayTicketSelector,eventManagers:i,managerId:null===r||void 0===r||null===(n=r.manager)||void 0===n?void 0:n.id,maxReg:null===r||void 0===r?void 0:r.maxRegistrations,onAltRegPageChange:o,onDefaultRegStatusChange:s,onDonationsChange:c,onManagerChange:l,onMaxRegChange:d,onPhoneNumberChange:f,onStatusChange:b,onTicketSelectorChange:p,phoneNumber:null===r||void 0===r?void 0:r.phoneNumber,status:null===r||void 0===r?void 0:r.status})}},ke=Object(m.withFeature)("use_reg_options_meta_box")(xe((function(e){var t=e.allowDonations,n=e.altRegPage,r=e.defaultRegStatus,i=e.displayTicketSelector,a=e.eventManagers,o=e.managerId,c=e.maxReg,s=e.onAltRegPageChange,u=void 0===s?l.noop:s,d=e.onDefaultRegStatusChange,f=e.onDonationsChange,b=e.onManagerChange,p=e.onPhoneNumberChange,v=e.onStatusChange,h=e.onTicketSelectorChange,j=e.onMaxRegChange,m=void 0===j?l.noop:j,y=e.phoneNumber,g=e.status;return Object(x.jsxs)(T.Grid,{className:"ee-edtr-section ee-edtr-cards",maxColumns:2,size:"bigger",children:[Object(x.jsxs)(T.GridCard,{className:"ee-event-details",header:Object(O.__)("Event Details"),children:[Object(x.jsx)(ve,{status:g,onStatusChange:v}),Object(x.jsx)(me,{eventManagers:a,managerId:o,onManagerChange:b}),Object(x.jsx)(ye,{phoneNumber:y,onPhoneNumberChange:p}),Object(x.jsx)(Oe,{allowDonations:t,onDonationsChange:f})]}),Object(x.jsxs)(T.GridCard,{className:"ee-reg-options",header:Object(O.__)("Registration Options"),children:[Object(x.jsx)(je,{defaultRegStatus:r,onDefaultRegStatusChange:d}),Object(x.jsx)(_e,{displayTicketSelector:i,onTicketSelectorChange:h}),Object(x.jsx)(ge,{maxReg:c,onMaxRegChange:m}),Object(x.jsx)(he,{altRegPage:n,onAltRegPageChange:u})]})]})}))),Te=function(){return Object(f.d)("ticket")},we={margin:"5px",border:"1px solid red"},Ee=function(e){var t=e.children;return Object(x.jsx)("div",{style:we,children:t})},De=function(){var e=Te();return e.length>1?Object(x.jsx)(Ee,{children:e}):Object(x.jsx)(x.Fragment,{children:e})},Ce=function(e){var t=e.isOnlyButton,n=Object(p.useGlobalModal)(u.EdtrGlobalModals.EDIT_TICKET).open,r=Object(x.jsx)(T.Button,{buttonText:Object(O.__)("Add New Ticket"),icon:t?k:null,noVerticalMargin:!0,onClick:n,size:t?"big":"default"});return t?r:Object(x.jsx)(T.NewEntityOption,{description:Object(O.__)("Add a single ticket and assign the dates to it"),icon:k,title:Object(O.__)("Single Ticket"),children:r})},Se={noPadding:!0,size:"big"},Fe=Object(m.withFeature)("use_default_ticket_manager")((function(){var e=Object(p.useGlobalModal)(u.EdtrGlobalModals.DEFAULT_TICKETS).open,t=Object(m.useCurrentUserCan)()("read","default_tickets");return Object(x.jsx)(T.DropdownMenu,{noZindex:!0,toggleProps:Se,wrapperClassName:"default_tickets",children:Object(x.jsx)(T.DropdownMenuItem,{className:"default_tickets",isDisabled:!t,onClick:e,title:Object(O.__)("Default tickets")})})})),Ie=function(){var e=Object(u.useTickets)();return Object(x.jsxs)(x.Fragment,{children:[Object(x.jsx)(y.EntityCacheIds,{entities:e}),Object(x.jsx)(De,{}),Object(x.jsx)(Fe,{})]})},Ne={icons:[{icon:s.EDIT,description:Object(O.__)("Edit Ticket Details")},{icon:s.CALENDAR,description:Object(O.__)("Manage Date Assignments")},{icon:s.CALCULATOR,description:Object(O.__)("Ticket Price Calculator")},{icon:B.a,description:Object(O.__)("Move Ticket to Trash")}],swatches:{TKA:Object(O.__)("Trashed"),TKE:Object(O.__)("Expired"),TKO:Object(O.__)("On Sale"),TKS:Object(O.__)("Sold Out"),TKP:Object(O.__)("Pending")}},Ae=Object(j.lazy)((function(){return n.e(25).then(n.bind(null,1796))})),Me=function(){return Object(x.jsx)(j.Suspense,{fallback:Object(x.jsx)(T.LoadingNotice,{}),children:Object(x.jsx)(Ae,{})})},Pe=Object(j.lazy)((function(){return n.e(26).then(n.bind(null,1793))})),Le=function(){return Object(x.jsx)(j.Suspense,{fallback:Object(x.jsx)(T.LoadingNotice,{}),children:Object(x.jsx)(Pe,{})})},Re=(L={},Object(q.a)(L,u.DisplayStartOrEndDate.start,Object(O.__)("ticket sales start date only")),Object(q.a)(L,u.DisplayStartOrEndDate.end,Object(O.__)("ticket sales end date only")),Object(q.a)(L,u.DisplayStartOrEndDate.both,Object(O.__)("ticket sales start and end dates")),L),ze=(R={},Object(q.a)(R,W.TicketsSales.all,Object(O.__)("all tickets for all dates")),Object(q.a)(R,W.TicketsSales.above90Sold,Object(O.__)("tickets with 90% or more sold")),Object(q.a)(R,W.TicketsSales.above75Sold,Object(O.__)("tickets with 75% or more sold")),Object(q.a)(R,W.TicketsSales.above50Sold,Object(O.__)("tickets with 50% or more sold")),Object(q.a)(R,W.TicketsSales.below50Sold,Object(O.__)("tickets with less than 50% sold")),R),Be=Object(g.a)(Object(g.a)({},ze),{},Object(q.a)({},W.TicketsSales.all,Object(O.__)("all tickets for above dates"))),Ve=(z={},Object(q.a)(z,W.TicketsStatus.all,Object(O.__)("all tickets for all dates")),Object(q.a)(z,W.TicketsStatus.onSaleAndPending,Object(O.__)("all on sale and sale pending")),Object(q.a)(z,W.TicketsStatus.onSaleOnly,Object(O.__)("on sale tickets only")),Object(q.a)(z,W.TicketsStatus.pendingOnly,Object(O.__)("sale pending tickets only")),Object(q.a)(z,W.TicketsStatus.nextOnSaleOrPendingOnly,Object(O.__)("next on sale or sale pending only")),Object(q.a)(z,W.TicketsStatus.soldOutOnly,Object(O.__)("sold out tickets only")),Object(q.a)(z,W.TicketsStatus.expiredOnly,Object(O.__)("expired tickets only")),Object(q.a)(z,W.TicketsStatus.trashedOnly,Object(O.__)("trashed tickets only")),z),$e=Object(g.a)(Object(g.a)({},Ve),{},Object(q.a)({},W.TicketsStatus.all,Object(O.__)("all tickets for above dates"))),Ue={date:Object(O.__)("ticket sale date"),name:Object(O.__)("ticket name"),id:Object(O.__)("ticket ID"),order:Object(O.__)("custom order")},He={displayStartOrEndDate:Object(O.__)("display"),isChained:Object(O.__)("linked"),sales:Object(O.__)("sales"),search:Object(O.__)("search"),sortBy:Object(O.__)("sort by"),status:Object(O.__)("status")},Ge=function(){var e=Object(u.useTicketsListFilterState)(),t=e.status,n=e.setStatus,r=e.sales,i=e.setSales,a=e.searchText,o=e.setSearchText,c=e.isChained,s=e.toggleIsChained,l="".concat(He.status,": ").concat(null===Ve||void 0===Ve?void 0:Ve[t]),d="".concat(He.sales,": ").concat(null===ze||void 0===ze?void 0:ze[r]),f="".concat(He.search,": ").concat(a),b="".concat(He.isChained,": ").concat(Object(O.__)("ON")),p=Object(j.useCallback)((function(){return n(W.TicketsStatus.all)}),[n]),v=Object(j.useCallback)((function(){return i(W.TicketsSales.all)}),[i]),h=Object(j.useCallback)((function(){return o("")}),[o]);return Object(x.jsxs)(T.ActiveFilters,{children:[t!==W.TicketsStatus.all&&Object(x.jsx)(T.FilterTag,{title:l,onRemove:p}),r!==W.TicketsSales.all&&Object(x.jsx)(T.FilterTag,{title:d,onRemove:v}),a?Object(x.jsx)(T.FilterTag,{title:f,onRemove:h}):null,c&&Object(x.jsx)(T.FilterTag,{title:b,onRemove:s})]})},We=Object(l.objectToSelectOptions)(Re),qe=function(){var e=Object(u.useTicketsListFilterState)(),t=e.displayStartOrEndDate,n=e.setDisplayStartOrEndDate;return Object(x.jsx)(T.SelectWithLabel,{id:"ee-tickets-list-display-control",label:He.displayStartOrEndDate,onChangeValue:n,options:We,value:t})},Ke=n(26),Ye=function(){var e=Object(u.useTicketsListFilterState)(),t=e.isChained,n=e.sales,r=e.setSales,i=Object(Ke.useMemoStringify)(Object(l.objectToSelectOptions)(t?Be:ze),[t]);return Object(x.jsx)(T.SelectWithLabel,{id:"ee-tickets-list-sales-control",label:He.sales,onChangeValue:r,options:i,value:n})},Ze=function(){var e=Object(u.useTicketsListFilterState)(),t=e.isChained,n=e.status,r=e.setStatus,i=Object(Ke.useMemoStringify)(Object(l.objectToSelectOptions)(t?$e:Ve),[t]);return Object(x.jsx)(T.SelectWithLabel,{id:"ee-tickets-list-status-control",label:He.status,onChangeValue:r,options:i,value:n})},Qe={month:"LLL"},Je=function(e){var t=e.dbId,n=e.endDate,r=e.name,i=e.price,a=e.startDate;return Object(x.jsxs)(x.Fragment,{children:[Object(x.jsxs)("span",{children:[t,")"]}),Object(x.jsxs)("span",{children:[r,": "]}),Object(x.jsx)("span",{children:Object(x.jsx)(y.CurrencyDisplay,{value:i})}),Object(x.jsx)("span",{children:"-"}),Object(x.jsx)(y.RangeFormat,{endDate:n,formatTokens:Qe,showTime:!0,startDate:a})]})},Xe=Object(l.objectToSelectOptions)(Ue),et=function(e){return Object(g.a)(Object(g.a)({},e),{},{content:Object(x.jsx)(Je,Object(g.a)({},e))})},tt=function(){var e=Object(u.useTicketsListFilterState)(),t=e.sortBy,n=e.setSortBy,r=Object(u.useFilteredTicketIds)(),i=Object(u.useReorderTickets)(r),a=i.allReorderedEntities,o=i.sortResponder,c=i.updateEntityList;return Object(x.jsx)(y.SortByControl,{draggableItems:a,droppableId:w.ticketDroppableId,entityType:m.TypeName.tickets,id:"ee-tickets-list-sort-by-control",label:He.sortBy,onChangeValue:n,options:Xe,onSort:o,onSubmit:c,renderDraggableItem:et,value:t})},nt=n(1662),rt=n(1663),it=function(){var e=Object(u.useTicketsListFilterState)(),t=e.isChained,n=e.toggleIsChained,r=be()("ee-filter-bar__btn ee-filter-bar__chain",{"ee-filter-bar__btn--active":t,"ee-filter-bar__chain--active":t}),i=t?nt.a:rt.a,a=t?Object(O.__)("tickets list is linked to dates list and is showing tickets for above dates only"):Object(O.__)("tickets list is unlinked and is showing tickets for all event dates");return Object(x.jsx)(T.IconButton,{className:r,icon:i,id:"ee-ticket-list-filter-bar-is-chained",label:He.isChained,onClick:n,tooltip:a,showTooltipOnMobile:!0})},at=Object(u.withEntityListContext)({Provider:u.TicketsListProvider,Component:function(){var e=Object(u.useTicketsListFilterState)(),t=Object(j.useCallback)((function(){return"card"===e.view?Object(x.jsx)(Me,{}):Object(x.jsx)(Le,{})}),[e.view]);return Object(x.jsx)(y.EntityList,{activeFilters:Object(x.jsx)(Ge,{}),domain:u.domain,entityType:m.TypeName.tickets,filterState:e,footer:Object(x.jsx)(Ie,{}),headerText:Object(O.__)("Available Tickets"),legendConfig:Ne,listId:u.ticketsList,loadingText:Object(O.__)("loading tickets\u2026"),renderList:t})}}),ot=function(){return Object(u.useRegisterIsChainedFilter)(),Object(x.jsx)(at,{})},ct=Object(m.withFeature)("use_event_description_rte")((function(){var e=Object(u.useEvent)(),t=Object(u.useEventMutator)(null===e||void 0===e?void 0:e.id).updateEntity,n=Object(j.useCallback)((function(n){n!==(null===e||void 0===e?void 0:e.description)&&t({description:n})}),[null===e||void 0===e?void 0:e.description,t]);return Object(j.useEffect)((function(){var e;null===(e=document.getElementById("postdivrich"))||void 0===e||e.remove()}),[]),Object(x.jsxs)("div",{className:"ee-event-description ee-edtr-section",children:[Object(x.jsx)(T.Heading,{as:"h3",className:"ee-edtr-section-heading",children:Object(O.__)("Event Description")}),Object(x.jsx)(y.AdvancedTextEditor,{debounceDelay:4e3,defaultValue:null===e||void 0===e?void 0:e.description,onChange:n})]})})),st=n(31),ut=n(9),lt=n(1676),dt=Object(_.a)((function(e){return Object(x.jsx)("svg",Object(g.a)(Object(g.a)({"aria-hidden":"true",height:"1.5em",viewBox:"0 1 24 24",width:"1.5em",xmlns:"https://www.w3.org/2000/svg",className:"ee-svg--venue-seat"},e),{},{children:Object(x.jsx)("path",{d:"M4 18v3h3v-3h10v3h3v-6H4zm15-8h3v3h-3zM2 10h3v3H2zm15 3H7V5c0-1.1.9-2 2-2h6c1.1 0 2 .9 2 2v8z"})}))}),"venue-seat"),ft=Object(_.a)((function(e){return Object(x.jsx)("svg",Object(g.a)(Object(g.a)({"aria-hidden":"true",height:"1.5em",viewBox:"-100 -100 720 720",width:"1.5em",xmlns:"https://www.w3.org/2000/svg",className:"ee-svg--phone"},e),{},{children:Object(x.jsx)("path",{d:"M497.39 361.8l-112-48a24 24 0 00-28 6.9l-49.6 60.6A370.66 370.66 0 01130.6 204.11l60.6-49.6a23.94 23.94 0 006.9-28l-48-112A24.16 24.16 0 00122.6.61l-104 24A24 24 0 000 48c0 256.5 207.9 464 464 464a24 24 0 0023.4-18.6l24-104a24.29 24.29 0 00-14.01-27.6z"})}))}),"phone"),bt=n(432),pt=function(e,t){var n=Object(m.useConfig)().siteUrl;return Object(j.useMemo)((function(){var r=Object(m.getAdminUrl)({adminSiteUrl:n.admin,page:w.ADMIN_ROUTES.VENUES});return Object(bt.addQueryArgs)(r,{post:t,action:e,return:"edit"})}),[n.admin,e,t])},vt={container:"ee-edtr-section ee-event-venue"},ht=Object(x.jsx)(T.Heading,{as:"h3",className:"ee-edtr-section-heading",children:Object(O.__)("Venue Details")}),jt=function(){var e=Object(u.useEvent)(),t=Object(u.useEventMutator)(null===e||void 0===e?void 0:e.id).updateEntity,n=Object(j.useState)((null===e||void 0===e?void 0:e.venue)||""),r=Object(ut.a)(n,2),i=r[0],a=r[1],o=Object(u.useVenues)(),c=Object(j.useMemo)((function(){return Object(st.a)(o)}),[o]),s=new Intl.Collator(void 0,{numeric:!0,sensitivity:"base"});c.sort((function(e,t){return s.compare(e.name,t.name)}));var d=Object(j.useMemo)((function(){return Object(W.findEntityByGuid)(c)(i)}),[i,c]),f=pt("create_new"),p=pt("edit",null===d||void 0===d?void 0:d.dbId),v=null===d||void 0===d?void 0:d.capacity,h=Object(l.isInfinite)(v)?Object(O.__)("unlimited space"):Object(O.sprintf)(Object(O.__)("Space for up to %d people"),null===d||void 0===d?void 0:d.capacity),m=Object(j.useCallback)((function(e){return a(e)}),[]),y=Object(j.useCallback)((function(e){return t({venue:e})}),[t]),_=null===d||void 0===d?void 0:d.thumbnail,k=Object(j.useMemo)((function(){return{inline:Object(O.__)("Venue address")}}),[]);return Object(x.jsxs)(T.Container,{"aria-label":Object(O.__)("Venue Details card"),classes:vt,header:ht,children:[d&&Object(x.jsxs)("div",{className:"ee-event-venue__card",children:[_?Object(x.jsx)("div",{className:"ee-event-venue__thumbnail",children:Object(x.jsx)(b.Image,{src:_,alt:null===d||void 0===d?void 0:d.name})}):Object(x.jsx)("div",{className:"ee-event-venue__thumbnail ee-event-venue__thumbnail--no-image",children:Object(O.__)("no image")}),Object(x.jsxs)("div",{className:"ee-event-venue__properties",children:[Object(x.jsx)(T.Heading,{as:"h4",className:"ee-event-venue__venue-name","aria-label":Object(O.__)("Venue name"),children:null===d||void 0===d?void 0:d.name}),Object(x.jsx)("div",{className:"ee-event-venue__desc",children:Object(x.jsx)("p",{children:null===d||void 0===d?void 0:d.shortDescription})}),Object(x.jsxs)("div",{className:"ee-event-venue__details",children:[Object(x.jsxs)("div",{className:"ee-event-venue__detail",children:[Object(x.jsx)("span",{className:"ee-event-venue__detail-label",children:Object(x.jsx)(lt.a,{})}),Object(x.jsx)("span",{className:"ee-event-venue__detail-value",children:Object(x.jsx)(T.Address,Object(g.a)({className:"ee-event-venue__address",inline:!0,labels:k},d))})]}),Object(x.jsxs)("div",{className:"ee-event-venue__detail",children:[Object(x.jsx)("span",{className:"ee-event-venue__detail-label",children:Object(x.jsx)(dt,{})}),Object(x.jsx)("span",{className:"ee-event-venue__detail-value","aria-label":Object(O.__)("Venue capacity"),children:h})]}),Object(x.jsxs)("div",{className:"ee-event-venue__detail",children:[Object(x.jsx)("span",{className:"ee-event-venue__detail-label",children:Object(x.jsx)(ft,{})}),Object(x.jsx)("span",{className:"ee-event-venue__detail-value","aria-label":Object(O.__)("Venue telephone"),children:(null===d||void 0===d?void 0:d.phone)||"(###) ###-####"})]})]}),Object(x.jsx)("div",{className:"ee-event-venue__actions",children:Object(x.jsx)(T.TextLink,{className:"ee-event-venue__edit-link",href:p,showExternalIcon:!0,children:Object(O.__)("Edit this Venue")})})]})]}),Object(x.jsx)(T.VenueSelector,{className:"ee-event-venue",createVenueLink:f,label:Object(O.__)("Select a Venue for the Event"),onChangeValue:y,onChangeInstantValue:m,value:null===e||void 0===e?void 0:e.venue,venueName:null===d||void 0===d?void 0:d.name,venues:c})]})},Ot=n(1434),mt=[{value:"ALL",label:Object(O.__)("all")},{value:"PRIMARY",label:Object(O.__)("primary registrant")},{value:"PURCHASER",label:Object(O.__)("purchaser")},{value:"REGISTRANTS",label:Object(O.__)("registrants")}],yt=[{value:"",label:"..."},{value:"Attendee.fname",label:Object(O.__)("Attendee First Name")},{value:"Attendee.lname",label:Object(O.__)("Attendee Last Name")},{value:"Attendee.email",label:Object(O.__)("Attendee Email Address")},{value:"Attendee.address",label:Object(O.__)("Attendee Address")}],gt=n(4),_t=gt.propEq("type","TEXT"),xt=gt.propEq("mapsTo","Attendee.fname"),kt=gt.allPass([_t,xt]),Tt=gt.any(kt),wt=gt.propEq("type","EMAIL"),Et=gt.propEq("mapsTo","Attendee.email"),Dt=gt.allPass([wt,Et]),Ct=gt.any(Dt),St=function(e){var t=e.elements,n=e.sections,r="",i=Object(j.useMemo)((function(){var e=Object(W.getGuids)(Object.values(n).filter(W.isNotSharedOrDefault)),r=Object.values(t).filter(gt.propSatisfies(gt.flip(gt.includes)(e),"belongsTo"));return{hasFirstName:Tt(r),hasEmail:Ct(r)}}),[t,n]);return i.hasFirstName?i.hasEmail||(r=Object(O.sprintf)(Object(O.__)('Registration form must have a field of type "%1$s" which maps to "%2$s"'),Object(O.__)("Email Address"),Object(O.__)("Attendee Email Address"))):r=Object(O.sprintf)(Object(O.__)('Registration form must have a field of type "%1$s" which maps to "%2$s"'),Object(O.__)("Text Input"),Object(O.__)("Attendee First Name")),r?Object(x.jsx)(T.Banner,{status:"error",title:Object(O.__)("Please add the required fields"),message:r}):null},Ft=Object(x.jsx)(T.Heading,{as:"h3",className:"ee-edtr-section-heading",children:Object(O.__)("Registration Form")}),It=Object(m.withFeature)("use_reg_form_builder")((function(){var e=Object(u.getEdtrDomData)("formBuilder"),t=e.elements,n=e.sections,r=e.topLevelSectionId;return Object(x.jsx)(Ot.FormBuilder,{appliesToOptions:mt,containerClassName:"ee-edtr-section",header:Ft,initialElements:t,initialSections:n,mapsToOptions:yt,topBanner:St,topLevelSectionId:r,onChange:console.log})})),Nt=n(279),At=n(139),Mt=n(175),Pt=n(18),Lt=function(){var e=Object(m.useStatus)().isLoaded,t=Object(Pt.useIsRehydrated)(),n=Object(ut.a)(t,1)[0],r=Object(j.useMemo)((function(){var t=[];if(!w.isDev||!n)return[];for(var r in m.TypeName)e(m.TypeName[r])&&t.push(m.TypeName[r]);return t}),[e,n]);return Object(j.useMemo)((function(){return{dev:{readyTypes:r}}}),[r])},Rt=function(){var e=Object(Mt.useSystemNotifications)(),t=Lt();return Object(j.useEffect)((function(){Object(Mt.initToaster)()}),[]),Object(j.useEffect)((function(){t.dev.readyTypes.forEach((function(t){var n=Object(Nt.sprintf)("%s initialized",t);e.success({message:n,toastId:n})}))}),[e,t]),Object(x.jsx)(At.a,{})},zt=n(8),Bt=n(43),Vt=n(34),$t=n.n(Vt),Ut=n(1772),Ht=n(1678),Gt=n(1773),Wt=n(50),qt=n(222),Kt=n(82),Yt=function(){var e=Object(Bt.a)($t.a.mark((function e(t){return $t.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(Kt.yupToFinalFormErrors)(Zt,t);case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),Zt=qt.b(Object(g.a)({name:qt.c()},u.datesSchema)),Qt=["id","name","description","capacity","isTrashed"],Jt=[u.startAndEndDateFixer],Xt={className:"ee-form-item-pair"},en=function(e,t){var n=Object(u.useDatetimeItem)({id:e}),r=Object(m.useSiteDateToUtcISO)(),i=Object(m.useUtcISOToSiteDate)(),a=Object(Ke.useMemoStringify)((null===n||void 0===n?void 0:n.startDate)?i(null===n||void 0===n?void 0:n.startDate):Object(Wt.setDefaultTime)(w.PLUS_ONE_MONTH,"start")),o=Object(Ke.useMemoStringify)((null===n||void 0===n?void 0:n.endDate)?i(null===n||void 0===n?void 0:n.endDate):Object(Wt.setDefaultTime)(w.PLUS_ONE_MONTH,"end")),c=t.onSubmit,s=Object(j.useCallback)(function(){var e=Object(Bt.a)($t.a.mark((function e(t,n){var i,a,o,s,u,l,d=arguments;return $t.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:for(i=t.startDate,a=t.endDate,o=Object(zt.a)(t,["startDate","endDate"]),s=d.length,u=new Array(s>2?s-2:0),l=2;l0?e.name:0===e.dbId?"":e.dbId.toString()}(e);return Object(O.sprintf)("%1$s %2$s",t,n)}),[]),l=Object(j.useMemo)((function(){var e=u(n,"ticket"),r=u(t,"datetime");switch(o){case null:return Object(O.sprintf)("click to assign %1$s to %2$s",e,r);case"NEW":return Object(O.sprintf)("click to remove new assignment for %1$s from %2$s",e,r);case"OLD":return Object(O.sprintf)("click to remove %1$s from %2$s",e,r);case"REMOVED":return Object(O.sprintf)("click to reassign %1$s to %2$s",e,r)}}),[n,t,o,u]);return Object(x.jsx)(T.Button,{className:"ee-tam-relation-btn",icon:s,margin:"auto",onClick:c,tooltip:l,variant:"link"})},dn=n(111),fn=function(e){var t=e.datetime,n=Object(pe.getDatetimeBackgroundColorClassName)(t),r=be()("date-stripe",n),i=Object(m.useTimeZoneTime)().formatForSite,a=t.startDate;return a instanceof Date?a=i(a,w.LOCALIZED_DATE_SHORT_FORMAT):a&&(a=i(Object(dn.a)(t.startDate),w.LOCALIZED_DATE_SHORT_FORMAT)),Object(x.jsxs)("div",{className:"date-cell-content",children:[Object(x.jsx)("div",{className:r}),Object(x.jsx)("div",{className:"ee-focus-priority-8 date-cell-content__id",children:"".concat(Object(O.__)("ID"),": ").concat(t.dbId)}),Object(x.jsx)("div",{className:"ee-focus-priority-5 date-cell-content__name",children:t.name}),Object(x.jsx)("div",{className:"ee-focus-priority-6",children:a})]})},bn=function(){var e=Object(rn.b)().hasNoAssignedTickets;return Object(j.useCallback)((function(t){return e({datetimeId:t.id})?"no-assignments":""}),[e])},pn=function(){var e=Object(rn.b)().hasNoAssignedDates;return Object(j.useCallback)((function(t){return e({ticketId:t.id})?"no-assignments":""}),[e])},vn=function(e){var t=e.datetimes,n=e.tickets,r=Object(rn.b)().getAssignmentStatus,i=bn(),a=pn();return Object(j.useMemo)((function(){return t.map((function(e){var t={className:"ee-rspnsv-table-column-micro date-cell",key:"datetime",value:Object(x.jsx)(fn,{datetime:e})},o=n.map((function(t){var n=r({datetimeId:e.id,ticketId:t.id}),i=n&&"".concat(n.toLowerCase(),"-assignment");return{className:be()("relation-cell",i,a(t)),key:t.id,size:"huge",textAlign:"center",value:Object(x.jsx)(ln,{datetime:e,ticket:t})}}));return{cells:[t].concat(Object(st.a)(o)),className:{bodyRowClassName:"ee-ticket-assignments-manager-table-body-row"},rowClassName:i(e),key:e.id,primary:!0,type:"row"}}))}),[t,r,a,i,n])},hn="MMM dd yyyy",jn=function(e){var t=e.ticket,n=Object(pe.getTicketBackgroundColorClassName)(t),r=Object(m.useTimeZoneTime)().formatForSite,i=t.startDate;i instanceof Date?i=r(i,hn):i&&(i=r(Object(dn.a)(t.startDate),hn));var a=be()(n,"header-cell-content__after");return Object(x.jsxs)("div",{className:"header-cell-content__wrapper",children:[Object(x.jsxs)("div",{className:"header-cell-content",children:[Object(x.jsx)("div",{className:"ee-focus-priority-6 header-cell-content__id",children:"".concat(Object(O.__)("ID"),": ").concat(t.dbId)}),Object(x.jsx)("div",{className:"ee-focus-priority-5 header-cell-content__name",children:t.name}),Object(x.jsx)("div",{className:"ee-focus-priority-7 header-cell-content__price",children:Object(x.jsx)(y.CurrencyDisplay,{value:t.price||0})})]}),Object(x.jsx)("div",{className:a,children:i})]})},On={key:"empty",size:"huge",value:Object(x.jsxs)("div",{children:[Object(x.jsx)("h3",{children:Object(O.__)("Assignments")}),Object(x.jsx)("p",{children:Object(O.__)("Event Dates are listed below")}),Object(x.jsx)("p",{children:Object(O.__)("Tickets are listed along the top")}),Object(x.jsx)("p",{children:Object(O.__)("Click the cell buttons to toggle assigments")})]})},mn=function(e){var t=pn();return Object(j.useMemo)((function(){var n=e.map((function(e){return{className:t(e),key:e.id,size:"huge",value:Object(x.jsx)(jn,{ticket:e})}}));return[{cells:[On].concat(Object(st.a)(n)),key:"ee-ticket-assignments-manager-table-header-row",primary:!0,type:"row"}]}),[t,e])},yn={isScrollable:!0,tableId:"ee-ticket-assignments-manager-table",tableCaption:Object(O.__)("Ticket Assignment Manager")},gn={tableClassName:"ee-ticket-assignments-manager"},_n=function(e){var t=e.datetimes,n=e.tickets,r=vn({datetimes:t,tickets:n}),i=mn(n);return Object(x.jsx)(T.ResponsiveTable,{bodyRows:r,className:gn,headerRows:i,metaData:yn})},xn=n(286),kn=function(){var e=Object(rn.b)().getData;return Object(x.jsx)(T.DebugInfo,{data:e()})},Tn=function(){var e=Object(rn.d)(),t=Object(rn.b)();return Object(x.jsxs)(x.Fragment,{children:[Object(x.jsx)(xn.FilterBar,{}),Object(x.jsx)(on,{dataState:t}),Object(x.jsx)(_n,Object(g.a)({},e)),Object(x.jsx)(kn,{})]})},wn={icons:[{className:"old-assignment",description:Object(O.__)("existing relation"),icon:un("OLD")},{className:"removed-assignment",description:Object(O.__)("remove existing relation"),icon:un("REMOVED")},{className:"new-assignment",description:Object(O.__)("add new relation"),icon:un("NEW")},{className:"no-assignments",description:Object(O.__)("invalid relation"),icon:un()},{description:Object(O.__)("no relation"),icon:un()}]},En=n(792),Dn=function(e){var t=Object(rn.b)(),n=t.hasOrphanEntities,r=t.getData,i=Object(j.useState)(!1),a=Object(ut.a)(i,2),o=a[0],c=a[1],s=n(),u=Object(j.useCallback)(function(){var t=Object(Bt.a)($t.a.mark((function t(n){return $t.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n.preventDefault(),c(!0),t.next=4,e(r());case 4:c(!1);case 5:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),[r,e]);return Object(j.useMemo)((function(){return{buttonText:Object(O.__)("Submit"),buttonType:T.ButtonType.PRIMARY,icon:En.a,isDisabled:s,isLoading:o,onClick:u,type:"submit"}}),[s,o,u])},Cn=n(280),Sn=function(e){var t=e.onCloseModal,n=e.onSubmit,r=e.title,i=Object(rn.b)(),a=i.hasOrphanEntities,o=i.isDirty,c=a(),s=Dn(n),u=Object(j.useContext)(Cn.a),l=Object(j.useMemo)((function(){return u.entity?"ticket assignment modal for datetime ".concat(u.entity.name):""}),[u]),d=Object(j.useMemo)((function(){return{modalContent:{"aria-label":l}}}),[l]);return Object(x.jsxs)(T.ModalWithAlert,{bodyClassName:"ee-ticket-assignments-manager__body",className:"ee-ticket-assignments-manager",isOpen:!0,isSubmitDisabled:c,onClose:t,onCancel:t,submitButtonProps:s,showAlertOnClose:o||c,title:r||Object(O.__)("Ticket Assignment Manager"),ariaAttributes:d,children:[Object(x.jsx)(Tn,{}),Object(x.jsx)(T.CollapsibleLegend,{direction:"row",legendConfig:wn})]})},Fn=n(377),In=function(e){var t=Object(m.useRelations)().getData,n=Object(j.useState)(!1),r=Object(ut.a)(n,2),i=r[0],a=r[1],o=Object(u.useDefaultTicketIds)(),c=Object(j.useCallback)((function(){for(var e=t(),n=Object(g.a)(Object(g.a)({},e),{},{tickets:gt.omit(o,e.tickets||{})}),r=0,i=Object.entries(gt.pick(Fn.a,n));r2?o-2:0),u=2;u=0;--a){var o=this.tryEntries[a],c=o.completion;if("root"===o.tryLoc)return i("end");if(o.tryLoc<=this.prev){var s=r.call(o,"catchLoc"),u=r.call(o,"finallyLoc");if(s&&u){if(this.prev=0;--n){var i=this.tryEntries[n];if(i.tryLoc<=this.prev&&r.call(i,"finallyLoc")&&this.prev=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),E(n),v}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var i=r.arg;E(n)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(e,n,r){return this.delegate={iterator:C(e),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=t),v}},e}(e.exports);try{regeneratorRuntime=r}catch(i){Function("r","regeneratorRuntime = r")(r)}},175:function(e,t){e.exports=window.eventespresso.toaster},1772:function(e,t,n){"use strict";var r=n(2),i=n(22),a=n(1);t.a=Object(i.a)((function(e){return Object(a.jsx)("svg",Object(r.a)(Object(r.a)({viewBox:"64 64 896 896","data-icon":"profile",fill:"currentColor","aria-hidden":"true",height:"1.5em",width:"1.5em",className:"ee-svg--profile-outlined"},e),{},{children:Object(a.jsx)("path",{d:"M880 112H144c-17.7 0-32 14.3-32 32v736c0 17.7 14.3 32 32 32h736c17.7 0 32-14.3 32-32V144c0-17.7-14.3-32-32-32zm-40 728H184V184h656v656zM492 400h184c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8H492c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8zm0 144h184c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8H492c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8zm0 144h184c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8H492c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8zM340 368a40 40 0 1080 0 40 40 0 10-80 0zm0 144a40 40 0 1080 0 40 40 0 10-80 0zm0 144a40 40 0 1080 0 40 40 0 10-80 0z"})}))}),"profile-outlined")},1773:function(e,t,n){"use strict";var r=n(2),i=n(22),a=n(1);t.a=Object(i.a)((function(e){return Object(a.jsx)("svg",Object(r.a)(Object(r.a)({"data-icon":"control",fill:"currentColor","aria-hidden":"true",height:"1.5em",width:"1.5em",viewBox:"64 64 896 896",className:"ee-svg--control-outlined"},e),{},{children:Object(a.jsx)("path",{d:"M880 112H144c-17.7 0-32 14.3-32 32v736c0 17.7 14.3 32 32 32h736c17.7 0 32-14.3 32-32V144c0-17.7-14.3-32-32-32zm-40 728H184V184h656v656zM340 683v77c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8v-77c-10.1 3.3-20.8 5-32 5s-21.9-1.8-32-5zm64-198V264c0-4.4-3.6-8-8-8h-48c-4.4 0-8 3.6-8 8v221c10.1-3.3 20.8-5 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.4.4c-.5.5-1 .9-1.6 1.4-.6.5-1.1.9-1.7 1.3-.2.1-.3.2-.5.3-.5.3-.9.7-1.4 1-.1.1-.3.2-.4.3-.6.4-1.2.7-1.9 1.1-.1.1-.3.1-.4.2-.5.3-1 .5-1.6.8l-.6.3c-.7.3-1.3.6-2 .8-.7.3-1.4.5-2.1.7-.2.1-.4.1-.6.2-.6.2-1.1.3-1.7.4-.2 0-.3.1-.5.1-.7.2-1.5.3-2.2.4-.2 0-.3 0-.5.1-.6.1-1.2.1-1.8.2h-.6c-.8 0-1.5.1-2.3.1s-1.5 0-2.3-.1h-.6c-.6 0-1.2-.1-1.8-.2-.2 0-.3 0-.5-.1-.7-.1-1.5-.2-2.2-.4-.2 0-.3-.1-.5-.1-.6-.1-1.2-.3-1.7-.4-.2-.1-.4-.1-.6-.2-.7-.2-1.4-.4-2.1-.7-.7-.2-1.3-.5-2-.8l-.6-.3c-.5-.2-1.1-.5-1.6-.8-.1-.1-.3-.1-.4-.2-.6-.3-1.3-.7-1.9-1.1-.1-.1-.3-.2-.4-.3-.5-.3-1-.6-1.4-1-.2-.1-.3-.2-.5-.3-.6-.4-1.2-.9-1.7-1.3s-1.1-.9-1.6-1.4l-.4-.4-1.2-1.2-.3-.3c-.5-.5-1-1.1-1.4-1.6-.1-.1-.2-.3-.3-.4-.4-.4-.7-.9-1-1.4-.1-.2-.2-.3-.3-.5l-1.2-1.8v-.1c-.4-.6-.7-1.2-1-1.8-2.6-5-4.1-10.7-4.1-16.7s1.5-11.7 4.1-16.7z"})}))}),"control-outlined")},178:function(e,t,n){"use strict";var r=n(1261);n.d(t,"useDataState",(function(){return r.a}));n(537);var i=n(1410);n.d(t,"useDataStateManager",(function(){return i.a}));var a=n(1262);n.d(t,"useSubmitForm",(function(){return a.a}));n(1263)},18:function(e,t){e.exports=window.eventespresso.data},2:function(e,t,n){"use strict";n.d(t,"a",(function(){return a}));var r=n(14);function i(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 a(e){for(var t=1;t1&&void 0!==arguments[1]?arguments[1]:"",n=function(n){var a=n.noMargin,s=n.size,u=Object(i.a)(n,["noMargin","size"]),l=o()("ee-svg",s&&"ee-icon--".concat(s),a&&"ee-icon--no-margin",t&&"ee-svg--".concat(t),u.className);return Object(c.jsx)(e,Object(r.a)(Object(r.a)({},u),{},{className:l}))};return n}},222:function(e,t,n){"use strict";n.d(t,"c",(function(){return Oe})),n.d(t,"a",(function(){return xe})),n.d(t,"b",(function(){return Ve}));var r,i,a=n(31),o=n(37),c=n(47);try{r=Map}catch(He){}try{i=Set}catch(He){}function s(e,t,n){if(!e||"object"!==typeof e||"function"===typeof e)return e;if(e.nodeType&&"cloneNode"in e)return e.cloneNode(!0);if(e instanceof Date)return new Date(e.getTime());if(e instanceof RegExp)return new RegExp(e);if(Array.isArray(e))return e.map(u);if(r&&e instanceof r)return new Map(Array.from(e.entries()));if(i&&e instanceof i)return new Set(Array.from(e.values()));if(e instanceof Object){t.push(e);var a=Object.create(e);for(var o in n.push(a),e){var c=t.findIndex((function(t){return t===e[o]}));a[o]=c>-1?n[c]:s(e[o],t,n)}return a}return e}function u(e){return s(e,[],[])}var l=Object.prototype.toString,d=Error.prototype.toString,f=RegExp.prototype.toString,b="undefined"!==typeof Symbol?Symbol.prototype.toString:function(){return""},p=/^Symbol\((.*)\)(.*)$/;function v(e){return e!=+e?"NaN":0===e&&1/e<0?"-0":""+e}function h(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(null==e||!0===e||!1===e)return""+e;var n=typeof e;if("number"===n)return v(e);if("string"===n)return t?'"'.concat(e,'"'):e;if("function"===n)return"[Function "+(e.name||"anonymous")+"]";if("symbol"===n)return b.call(e).replace(p,"Symbol($1)");var r=l.call(e).slice(8,-1);return"Date"===r?isNaN(e.getTime())?""+e:e.toISOString(e):"Error"===r||e instanceof Error?"["+d.call(e)+"]":"RegExp"===r?f.call(e):null}function j(e,t){var n=h(e,t);return null!==n?n:JSON.stringify(e,(function(e,n){var r=h(this[e],t);return null!==r?r:n}),2)}var O={default:"${path} is invalid",required:"${path} is a required field",oneOf:"${path} must be one of the following values: ${values}",notOneOf:"${path} must not be one of the following values: ${values}",notType:function(e){var t=e.path,n=e.type,r=e.value,i=e.originalValue,a=null!=i&&i!==r,o="".concat(t," must be a `").concat(n,"` type, ")+"but the final value was: `".concat(j(r,!0),"`")+(a?" (cast from the value `".concat(j(i,!0),"`)."):".");return null===r&&(o+='\n If "null" is intended as an empty value be sure to mark the schema as `.nullable()`'),o},defined:"${path} must be defined"},m={length:"${path} must be exactly ${length} characters",min:"${path} must be at least ${min} characters",max:"${path} must be at most ${max} characters",matches:'${path} must match the following: "${regex}"',email:"${path} must be a valid email",url:"${path} must be a valid URL",uuid:"${path} must be a valid UUID",trim:"${path} must be a trimmed string",lowercase:"${path} must be a lowercase string",uppercase:"${path} must be a upper case string"},y={min:"${path} must be greater than or equal to ${min}",max:"${path} must be less than or equal to ${max}",lessThan:"${path} must be less than ${less}",moreThan:"${path} must be greater than ${more}",positive:"${path} must be a positive number",negative:"${path} must be a negative number",integer:"${path} must be an integer"},g={min:"${path} field must be later than ${min}",max:"${path} field must be at earlier than ${max}"},_={isValue:"${path} field must be ${value}"},x={noUnknown:"${path} field has unspecified keys: ${unknown}"},k={min:"${path} field must have at least ${min} items",max:"${path} field must have less than or equal to ${max} items",length:"${path} must have ${length} items"},T=(Object.assign(Object.create(null),{mixed:O,string:m,number:y,date:g,object:x,array:k,boolean:_}),n(151)),w=n.n(T),E=function(e){return e&&e.__isYupSchema__},D=function(){function e(t,n){if(Object(o.a)(this,e),this.fn=void 0,this.refs=t,this.refs=t,"function"!==typeof n){if(!w()(n,"is"))throw new TypeError("`is:` is required for `when()` conditions");if(!n.then&&!n.otherwise)throw new TypeError("either `then:` or `otherwise:` is required for `when()` conditions");var r=n.is,i=n.then,a=n.otherwise,c="function"===typeof r?r:function(){for(var e=arguments.length,t=new Array(e),n=0;n1?"".concat(s.errors.length," errors occurred"):s.errors[0],Error.captureStackTrace&&Error.captureStackTrace(Object(C.a)(s),n),s}return Object(c.a)(n,null,[{key:"formatError",value:function(e,t){var n=t.label||t.path||"this";return n!==t.path&&(t=A({},t,{path:n})),"string"===typeof e?e.replace(M,(function(e,n){return j(t[n])})):"function"===typeof e?e(t):e}},{key:"isError",value:function(e){return e&&"ValidationError"===e.name}}]),n}(Object(I.a)(Error));function L(e,t){var n=e.endEarly,r=e.tests,i=e.args,o=e.value,c=e.errors,s=e.sort,u=e.path,l=function(e){var t=!1;return function(){t||(t=!0,e.apply(void 0,arguments))}}(t),d=r.length,f=[];if(c=c||[],!d)return c.length?l(new P(c,o,u)):l(null,o);for(var b=0;b1&&void 0!==arguments[1]?arguments[1]:{};if(Object(o.a)(this,e),this.key=void 0,this.isContext=void 0,this.isValue=void 0,this.isSibling=void 0,this.path=void 0,this.getter=void 0,this.map=void 0,"string"!==typeof t)throw new TypeError("ref must be a string, got: "+t);if(this.key=t.trim(),""===t)throw new TypeError("ref must be a non-empty string");this.isContext=this.key[0]===V,this.isValue=this.key[0]===$,this.isSibling=!this.isContext&&!this.isValue;var r=this.isContext?V:this.isValue?$:"";this.path=this.key.slice(r.length),this.getter=this.path&&Object(B.getter)(this.path,!0),this.map=n.map}return Object(c.a)(e,[{key:"getValue",value:function(e,t,n){var r=this.isContext?n:this.isValue?e:t;return this.getter&&(r=this.getter(r||{})),this.map&&(r=this.map(r)),r}},{key:"cast",value:function(e,t){return this.getValue(e,null==t?void 0:t.parent,null==t?void 0:t.context)}},{key:"resolve",value:function(){return this}},{key:"describe",value:function(){return{type:"ref",key:this.key}}},{key:"toString",value:function(){return"Ref(".concat(this.key,")")}}],[{key:"isRef",value:function(e){return e&&e.__isYupRef}}]),e}();function H(){return(H=Object.assign||function(e){for(var t=1;t=0||(i[n]=e[n]);return i}(t,["value","path","label","options","originalValue","sync"]),d=e.name,f=e.test,b=e.params,p=e.message,v=c.parent,h=c.context;function j(e){return U.isRef(e)?e.getValue(r,v,h):e}function O(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=z()(H({value:r,originalValue:s,label:o,path:e.path||a},b,e.params),j),n=new P(P.formatError(e.message||p,t),r,t.path,e.type||d);return n.params=t,n}var m=H({path:a,parent:v,type:d,createError:O,resolve:j,options:c,originalValue:s},l);if(u){var y;try{var g;if("function"===typeof(null==(g=y=f.call(m,r,m))?void 0:g.then))throw new Error('Validation test of type: "'.concat(m.type,'" returned a Promise during a synchronous validate. ')+"This test will finish after the validate call has returned")}catch(_){return void n(_)}P.isError(y)?n(y):y?n(null,y):n(O())}else try{Promise.resolve(f.call(m,r,m)).then((function(e){P.isError(e)?n(e):e?n(null,e):n(O())})).catch(n)}catch(_){n(_)}}return t.OPTIONS=e,t}U.prototype.__isYupRef=!0;var W=function(e){return e.substr(0,e.length-1).substr(1)};function q(e,t,n){var r,i,a,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:n;return t?(Object(B.forEach)(t,(function(c,s,u){var l=s?W(c):c;if((e=e.resolve({context:o,parent:r,value:n})).innerType){var d=u?parseInt(l,10):0;if(n&&d>=n.length)throw new Error("Yup.reach cannot resolve an array item at index: ".concat(c,", in the path: ").concat(t,". ")+"because there is no value at that index. ");r=n,n=n&&n[d],e=e.innerType}if(!u){if(!e.fields||!e.fields[l])throw new Error("The schema does not contain the path: ".concat(t,". ")+"(failed at: ".concat(a,' which is a type: "').concat(e._type,'")'));r=n,n=n&&n[l],e=e.fields[l]}i=l,a=s?"["+c+"]":"."+c})),{schema:e,parent:r,parentPath:i}):{parent:r,parentPath:t,schema:e}}var K=n(9),Y=n(80),Z=function(){function e(){Object(o.a)(this,e),this.list=void 0,this.refs=void 0,this.list=new Set,this.refs=new Map}return Object(c.a)(e,[{key:"size",get:function(){return this.list.size+this.refs.size}},{key:"describe",value:function(){var e,t=[],n=Object(Y.a)(this.list);try{for(n.s();!(e=n.n()).done;){var r=e.value;t.push(r)}}catch(c){n.e(c)}finally{n.f()}var i,a=Object(Y.a)(this.refs);try{for(a.s();!(i=a.n()).done;){var o=Object(K.a)(i.value,2)[1];t.push(o.describe())}}catch(c){a.e(c)}finally{a.f()}return t}},{key:"toArray",value:function(){return Array.from(this.list).concat(Array.from(this.refs.values()))}},{key:"resolveAll",value:function(e){return this.toArray().reduce((function(t,n){return t.concat(U.isRef(n)?e(n):n)}),[])}},{key:"add",value:function(e){U.isRef(e)?this.refs.set(e.key,e):this.list.add(e)}},{key:"delete",value:function(e){U.isRef(e)?this.refs.delete(e.key):this.list.delete(e)}},{key:"clone",value:function(){var t=new e;return t.list=new Set(this.list),t.refs=new Map(this.refs),t}},{key:"merge",value:function(e,t){var n=this.clone();return e.list.forEach((function(e){return n.add(e)})),e.refs.forEach((function(e){return n.add(e)})),t.list.forEach((function(e){return n.delete(e)})),t.refs.forEach((function(e){return n.delete(e)})),n}}]),e}();function Q(){return(Q=Object.assign||function(e){for(var t=1;t1&&void 0!==arguments[1]?arguments[1]:{},n=this.resolve(Q({value:e},t)),r=n._cast(e,t);if(void 0!==e&&!1!==t.assert&&!0!==n.isType(r)){var i=j(e),a=j(r);throw new TypeError("The value of ".concat(t.path||"field"," could not be cast to a value ")+'that satisfies the schema type: "'.concat(n._type,'". \n\n')+"attempted value: ".concat(i," \n")+(a!==i?"result of cast: ".concat(a):""))}return r}},{key:"_cast",value:function(e,t){var n=this,r=void 0===e?e:this.transforms.reduce((function(t,r){return r.call(n,t,e,n)}),e);return void 0===r&&(r=this.getDefault()),r}},{key:"_validate",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2?arguments[2]:void 0,i=n.sync,a=n.path,o=n.from,c=void 0===o?[]:o,s=n.originalValue,u=void 0===s?e:s,l=n.strict,d=void 0===l?this.spec.strict:l,f=n.abortEarly,b=void 0===f?this.spec.abortEarly:f,p=e;d||(p=this._cast(p,Q({assert:!1},n)));var v={value:p,path:a,options:n,originalValue:u,schema:this,label:this.spec.label,sync:i,from:c},h=[];this._typeError&&h.push(this._typeError);var j=[];this._whitelistError&&j.push(this._whitelistError),this._blacklistError&&j.push(this._blacklistError),L({args:v,value:p,path:a,sync:i,tests:h,endEarly:b},(function(e){e?r(e,p):L({tests:t.tests.concat(j),args:v,path:a,sync:i,value:p,endEarly:b},r)}))}},{key:"validate",value:function(e,t,n){var r=this.resolve(Q({},t,{value:e}));return"function"===typeof n?r._validate(e,t,n):new Promise((function(n,i){return r._validate(e,t,(function(e,t){e?i(e):n(t)}))}))}},{key:"validateSync",value:function(e,t){var n;return this.resolve(Q({},t,{value:e}))._validate(e,Q({},t,{sync:!0}),(function(e,t){if(e)throw e;n=t})),n}},{key:"isValid",value:function(e,t){return this.validate(e,t).then((function(){return!0}),(function(e){if(P.isError(e))return!1;throw e}))}},{key:"isValidSync",value:function(e,t){try{return this.validateSync(e,t),!0}catch(n){if(P.isError(n))return!1;throw n}}},{key:"_getDefault",value:function(){var e=this.spec.default;return null==e?e:"function"===typeof e?e.call(this):u(e)}},{key:"getDefault",value:function(e){return this.resolve(e||{})._getDefault()}},{key:"default",value:function(e){if(0===arguments.length)return this._getDefault();var t=this.clone({default:e});return t}},{key:"strict",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],t=this.clone();return t.spec.strict=e,t}},{key:"_isPresent",value:function(e){return null!=e}},{key:"defined",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:O.defined;return this.test({message:e,name:"defined",exclusive:!0,test:function(e){return void 0!==e}})}},{key:"required",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:O.required;return this.clone({presence:"required"}).withMutation((function(t){return t.test({message:e,name:"required",exclusive:!0,test:function(e){return this.schema._isPresent(e)}})}))}},{key:"notRequired",value:function(){var e=this.clone({presence:"optional"});return e.tests=e.tests.filter((function(e){return"required"!==e.OPTIONS.name})),e}},{key:"nullable",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],t=this.clone({nullable:!1!==e});return t}},{key:"transform",value:function(e){var t=this.clone();return t.transforms.push(e),t}},{key:"test",value:function(){var e;if(void 0===(e=1===arguments.length?"function"===typeof(arguments.length<=0?void 0:arguments[0])?{test:arguments.length<=0?void 0:arguments[0]}:arguments.length<=0?void 0:arguments[0]:2===arguments.length?{name:arguments.length<=0?void 0:arguments[0],test:arguments.length<=1?void 0:arguments[1]}:{name:arguments.length<=0?void 0:arguments[0],message:arguments.length<=1?void 0:arguments[1],test:arguments.length<=2?void 0:arguments[2]}).message&&(e.message=O.default),"function"!==typeof e.test)throw new TypeError("`test` is a required parameters");var t=this.clone(),n=G(e),r=e.exclusive||e.name&&!0===t.exclusiveTests[e.name];if(e.exclusive&&!e.name)throw new TypeError("Exclusive tests must provide a unique `name` identifying the test");return e.name&&(t.exclusiveTests[e.name]=!!e.exclusive),t.tests=t.tests.filter((function(t){if(t.OPTIONS.name===e.name){if(r)return!1;if(t.OPTIONS.test===n.OPTIONS.test)return!1}return!0})),t.tests.push(n),t}},{key:"when",value:function(e,t){Array.isArray(e)||"string"===typeof e||(t=e,e=".");var n=this.clone(),r=N(e).map((function(e){return new U(e)}));return r.forEach((function(e){e.isSibling&&n.deps.push(e.key)})),n.conditions.push(new D(r,t)),n}},{key:"typeError",value:function(e){var t=this.clone();return t._typeError=G({message:e,name:"typeError",test:function(e){return!(void 0!==e&&!this.schema.isType(e))||this.createError({params:{type:this.schema._type}})}}),t}},{key:"oneOf",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:O.oneOf,n=this.clone();return e.forEach((function(e){n._whitelist.add(e),n._blacklist.delete(e)})),n._whitelistError=G({message:t,name:"oneOf",test:function(e){if(void 0===e)return!0;var t=this.schema._whitelist,n=t.resolveAll(this.resolve);return!!n.includes(e)||this.createError({params:{values:t.toArray().join(", "),resolved:n}})}}),n}},{key:"notOneOf",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:O.notOneOf,n=this.clone();return e.forEach((function(e){n._blacklist.add(e),n._whitelist.delete(e)})),n._blacklistError=G({message:t,name:"notOneOf",test:function(e){var t=this.schema._blacklist,n=t.resolveAll(this.resolve);return!n.includes(e)||this.createError({params:{values:t.toArray().join(", "),resolved:n}})}}),n}},{key:"strip",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],t=this.clone();return t.spec.strip=e,t}},{key:"describe",value:function(){var e=this.clone(),t=e.spec,n=t.label;return{meta:t.meta,label:n,type:e.type,oneOf:e._whitelist.describe(),notOneOf:e._blacklist.describe(),tests:e.tests.map((function(e){return{name:e.OPTIONS.name,params:e.OPTIONS.params}})).filter((function(e,t,n){return n.findIndex((function(t){return t.name===e.name}))===t}))}}}]),e}();J.prototype.__isYupSchema__=!0;for(var X=function(){var e=te[ee];J.prototype["".concat(e,"At")]=function(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=q(this,t,n,r.context),a=i.parent,o=i.parentPath,c=i.schema;return c[e](a&&a[o],Q({},r,{parent:a,path:t}))}},ee=0,te=["validate","validateSync"];ee0&&void 0!==arguments[0]?arguments[0]:_.isValue;return this.test({message:e,name:"is-value",exclusive:!0,params:{value:"true"},test:function(e){return ue(e)||!0===e}})}},{key:"isFalse",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:_.isValue;return this.test({message:e,name:"is-value",exclusive:!0,params:{value:"false"},test:function(e){return ue(e)||!1===e}})}}]),n}(J);le.prototype;var de=n(59),fe=n(46),be=/^((([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+(\.([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+)*)|((\x22)((((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(([\x01-\x08\x0b\x0c\x0e-\x1f\x7f]|\x21|[\x23-\x5b]|[\x5d-\x7e]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(\\([\x01-\x09\x0b\x0c\x0d-\x7f]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]))))*(((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(\x22)))@((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))$/i,pe=/^((https?|ftp):)?\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,ve=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,he=function(e){return ue(e)||e===e.trim()},je={}.toString();function Oe(){return new me}var me=function(e){Object(S.a)(n,e);var t=Object(F.a)(n);function n(){var e;return Object(o.a)(this,n),(e=t.call(this,{type:"string"})).withMutation((function(){e.transform((function(e){if(this.isType(e))return e;if(Array.isArray(e))return e;var t=null!=e&&e.toString?e.toString():e;return t===je?e:t}))})),e}return Object(c.a)(n,[{key:"_typeCheck",value:function(e){return e instanceof String&&(e=e.valueOf()),"string"===typeof e}},{key:"_isPresent",value:function(e){return Object(de.a)(Object(fe.a)(n.prototype),"_isPresent",this).call(this,e)&&!!e.length}},{key:"length",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:m.length;return this.test({message:t,name:"length",exclusive:!0,params:{length:e},test:function(t){return ue(t)||t.length===this.resolve(e)}})}},{key:"min",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:m.min;return this.test({message:t,name:"min",exclusive:!0,params:{min:e},test:function(t){return ue(t)||t.length>=this.resolve(e)}})}},{key:"max",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:m.max;return this.test({name:"max",exclusive:!0,message:t,params:{max:e},test:function(t){return ue(t)||t.length<=this.resolve(e)}})}},{key:"matches",value:function(e,t){var n,r,i=!1;if(t)if("object"===typeof t){var a=t.excludeEmptyString;i=void 0!==a&&a,n=t.message,r=t.name}else n=t;return this.test({name:r||"matches",message:n||m.matches,params:{regex:e},test:function(t){return ue(t)||""===t&&i||-1!==t.search(e)}})}},{key:"email",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:m.email;return this.matches(be,{name:"email",message:e,excludeEmptyString:!0})}},{key:"url",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:m.url;return this.matches(pe,{name:"url",message:e,excludeEmptyString:!0})}},{key:"uuid",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:m.uuid;return this.matches(ve,{name:"uuid",message:e,excludeEmptyString:!1})}},{key:"ensure",value:function(){return this.default("").transform((function(e){return null===e?"":e}))}},{key:"trim",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:m.trim;return this.transform((function(e){return null!=e?e.trim():e})).test({message:e,name:"trim",test:he})}},{key:"lowercase",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:m.lowercase;return this.transform((function(e){return ue(e)?e:e.toLowerCase()})).test({message:e,name:"string_case",exclusive:!0,test:function(e){return ue(e)||e===e.toLowerCase()}})}},{key:"uppercase",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:m.uppercase;return this.transform((function(e){return ue(e)?e:e.toUpperCase()})).test({message:e,name:"string_case",exclusive:!0,test:function(e){return ue(e)||e===e.toUpperCase()}})}}]),n}(J);Oe.prototype=me.prototype;var ye=function(e){Object(S.a)(n,e);var t=Object(F.a)(n);function n(){var e;return Object(o.a)(this,n),(e=t.call(this,{type:"number"})).withMutation((function(){e.transform((function(e){var t=e;if("string"===typeof t){if(""===(t=t.replace(/\s/g,"")))return NaN;t=+t}return this.isType(t)?t:parseFloat(t)}))})),e}return Object(c.a)(n,[{key:"_typeCheck",value:function(e){return e instanceof Number&&(e=e.valueOf()),"number"===typeof e&&!function(e){return e!=+e}(e)}},{key:"min",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:y.min;return this.test({message:t,name:"min",exclusive:!0,params:{min:e},test:function(t){return ue(t)||t>=this.resolve(e)}})}},{key:"max",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:y.max;return this.test({message:t,name:"max",exclusive:!0,params:{max:e},test:function(t){return ue(t)||t<=this.resolve(e)}})}},{key:"lessThan",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:y.lessThan;return this.test({message:t,name:"max",exclusive:!0,params:{less:e},test:function(t){return ue(t)||t1&&void 0!==arguments[1]?arguments[1]:y.moreThan;return this.test({message:t,name:"min",exclusive:!0,params:{more:e},test:function(t){return ue(t)||t>this.resolve(e)}})}},{key:"positive",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:y.positive;return this.moreThan(0,e)}},{key:"negative",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:y.negative;return this.lessThan(0,e)}},{key:"integer",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:y.integer;return this.test({name:"integer",message:e,test:function(e){return ue(e)||Number.isInteger(e)}})}},{key:"truncate",value:function(){return this.transform((function(e){return ue(e)?e:0|e}))}},{key:"round",value:function(e){var t,n=["ceil","floor","round","trunc"];if("trunc"===(e=(null==(t=e)?void 0:t.toLowerCase())||"round"))return this.truncate();if(-1===n.indexOf(e.toLowerCase()))throw new TypeError("Only valid options for round() are: "+n.join(", "));return this.transform((function(t){return ue(t)?t:Math[e](t)}))}}]),n}(J);ye.prototype;var ge=/^(\d{4}|[+\-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,\.](\d{1,}))?)?(?:(Z)|([+\-])(\d{2})(?::?(\d{2}))?)?)?$/;var _e=new Date("");function xe(){return new ke}var ke=function(e){Object(S.a)(n,e);var t=Object(F.a)(n);function n(){var e;return Object(o.a)(this,n),(e=t.call(this,{type:"date"})).withMutation((function(){e.transform((function(e){return this.isType(e)?e:(e=function(e){var t,n,r=[1,4,5,6,7,10,11],i=0;if(n=ge.exec(e)){for(var a,o=0;a=r[o];++o)n[a]=+n[a]||0;n[2]=(+n[2]||1)-1,n[3]=+n[3]||1,n[7]=n[7]?String(n[7]).substr(0,3):0,void 0!==n[8]&&""!==n[8]||void 0!==n[9]&&""!==n[9]?("Z"!==n[8]&&void 0!==n[9]&&(i=60*n[10]+n[11],"+"===n[9]&&(i=0-i)),t=Date.UTC(n[1],n[2],n[3],n[4],n[5]+i,n[6],n[7])):t=+new Date(n[1],n[2],n[3],n[4],n[5],n[6],n[7])}else t=Date.parse?Date.parse(e):NaN;return t}(e),isNaN(e)?_e:new Date(e))}))})),e}return Object(c.a)(n,[{key:"_typeCheck",value:function(e){return t=e,"[object Date]"===Object.prototype.toString.call(t)&&!isNaN(e.getTime());var t}},{key:"prepareParam",value:function(e,t){var n;if(U.isRef(e))n=e;else{var r=this.cast(e);if(!this._typeCheck(r))throw new TypeError("`".concat(t,"` must be a Date or a value that can be `cast()` to a Date"));n=r}return n}},{key:"min",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:g.min,n=this.prepareParam(e,"min");return this.test({message:t,name:"min",exclusive:!0,params:{min:e},test:function(e){return ue(e)||e>=this.resolve(n)}})}},{key:"max",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:g.max,n=this.prepareParam(e,"max");return this.test({message:t,name:"max",exclusive:!0,params:{max:e},test:function(e){return ue(e)||e<=this.resolve(n)}})}}]),n}(J);ke.INVALID_DATE=_e,xe.prototype=ke.prototype,xe.INVALID_DATE=_e;var Te=n(327),we=n.n(Te),Ee=n(433),De=n.n(Ee),Ce=n(434),Se=n.n(Ce),Fe=n(435),Ie=n.n(Fe);function Ne(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=[],r=new Set,i=new Set(t.map((function(e){var t=Object(K.a)(e,2),n=t[0],r=t[1];return"".concat(n,"-").concat(r)})));function a(e,t){var a=Object(B.split)(e)[0];r.add(a),i.has("".concat(t,"-").concat(a))||n.push([t,a])}var o=function(t){if(w()(e,t)){var n=e[t];r.add(t),U.isRef(n)&&n.isSibling?a(n.path,t):E(n)&&"deps"in n&&n.deps.forEach((function(e){return a(e,t)}))}};for(var c in e)o(c);return Ie.a.array(Array.from(r),n).reverse()}function Ae(e,t){var n=1/0;return e.some((function(e,r){var i;if(-1!==(null==(i=t.path)?void 0:i.indexOf(e)))return n=r,!0})),n}function Me(e){return function(t,n){return Ae(e,t)-Ae(e,n)}}function Pe(){return(Pe=Object.assign||function(e){for(var t=1;t1&&void 0!==arguments[1]?arguments[1]:{},a=Object(de.a)(Object(fe.a)(n.prototype),"_cast",this).call(this,e,i);if(void 0===a)return this.getDefault();if(!this._typeCheck(a))return a;var o,c=this.fields,s=null!=(t=i.stripUnknown)?t:this.spec.noUnknown,u=this._nodes.concat(Object.keys(a).filter((function(e){return-1===r._nodes.indexOf(e)}))),l={},d=Pe({},i,{parent:l,__validating:i.__validating||!1}),f=!1,b=Object(Y.a)(u);try{for(b.s();!(o=b.n()).done;){var p=o.value,v=c[p],h=w()(a,p);if(v){var j=void 0,O=a[p];d.path=(i.path?"".concat(i.path,"."):"")+p;var m="spec"in(v=v.resolve({value:O,context:i.context,parent:l}))?v.spec:void 0,y=null==m?void 0:m.strict;if(null==m?void 0:m.strip){f=f||p in a;continue}void 0!==(j=i.__validating&&y?a[p]:v.cast(a[p],d))&&(l[p]=j)}else h&&!s&&(l[p]=a[p]);l[p]!==a[p]&&(f=!0)}}catch(g){b.e(g)}finally{b.f()}return f?l:a}},{key:"_validate",value:function(e){var t=this,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=arguments.length>2?arguments[2]:void 0,o=[],c=r.sync,s=r.from,u=void 0===s?[]:s,l=r.originalValue,d=void 0===l?e:l,f=r.abortEarly,b=void 0===f?this.spec.abortEarly:f,p=r.recursive,v=void 0===p?this.spec.recursive:p;u=[{schema:this,value:d}].concat(Object(a.a)(u)),r.__validating=!0,r.originalValue=d,r.from=u,Object(de.a)(Object(fe.a)(n.prototype),"_validate",this).call(this,e,r,(function(e,n){if(e){if(!P.isError(e)||b)return void i(e,n);o.push(e)}if(v&&Le(n)){d=d||n;var a=t._nodes.map((function(e){return function(i,a){var o=-1===e.indexOf(".")?(r.path?"".concat(r.path,"."):"")+e:"".concat(r.path||"",'["').concat(e,'"]'),c=t.fields[e];c&&"validate"in c?c.validate(n[e],Pe({},r,{path:o,from:u,strict:!0,parent:n,originalValue:d[e]}),a):a(null)}}));L({sync:c,tests:a,value:n,errors:o,endEarly:b,sort:t._sortErrors,path:r.path},i)}else i(o[0]||null,n)}))}},{key:"clone",value:function(e){var t=Object(de.a)(Object(fe.a)(n.prototype),"clone",this).call(this,e);return t.fields=Pe({},this.fields),t._nodes=this._nodes,t._excludedEdges=this._excludedEdges,t._sortErrors=this._sortErrors,t}},{key:"concat",value:function(e){for(var t=this,r=Object(de.a)(Object(fe.a)(n.prototype),"concat",this).call(this,e),i=r.fields,a=0,o=Object.entries(this.fields);a1&&void 0!==arguments[1]?arguments[1]:[],n=this.clone(),r=Object.assign(n.fields,e);return n.fields=r,n._sortErrors=Me(Object.keys(r)),t.length&&(Array.isArray(t[0])||(t=[t]),n._excludedEdges=[].concat(Object(a.a)(n._excludedEdges),Object(a.a)(t))),n._nodes=Ne(r,n._excludedEdges),n}},{key:"pick",value:function(e){var t,n={},r=Object(Y.a)(e);try{for(r.s();!(t=r.n()).done;){var i=t.value;this.fields[i]&&(n[i]=this.fields[i])}}catch(a){r.e(a)}finally{r.f()}return this.clone().withMutation((function(e){return e.fields={},e.shape(n)}))}},{key:"omit",value:function(e){var t=this.clone(),n=t.fields;t.fields={};var r,i=Object(Y.a)(e);try{for(i.s();!(r=i.n()).done;){var a=r.value;delete n[a]}}catch(o){i.e(o)}finally{i.f()}return t.withMutation((function(){return t.shape(n)}))}},{key:"from",value:function(e,t,n){var r=Object(B.getter)(e,!0);return this.transform((function(i){if(null==i)return i;var a=i;return w()(i,e)&&(a=Pe({},i),n||delete a[e],a[t]=r(i)),a}))}},{key:"noUnknown",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:x.noUnknown;"string"===typeof e&&(t=e,e=!0);var n=this.test({name:"noUnknown",exclusive:!0,message:t,test:function(t){if(null==t)return!0;var n=Re(this.schema,t);return!e||0===n.length||this.createError({params:{unknown:n.join(", ")}})}});return n.spec.noUnknown=e,n}},{key:"unknown",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:x.noUnknown;return this.noUnknown(!e,t)}},{key:"transformKeys",value:function(e){return this.transform((function(t){return t&&Se()(t,(function(t,n){return e(n)}))}))}},{key:"camelCase",value:function(){return this.transformKeys(De.a)}},{key:"snakeCase",value:function(){return this.transformKeys(we.a)}},{key:"constantCase",value:function(){return this.transformKeys((function(e){return we()(e).toUpperCase()}))}},{key:"describe",value:function(){var e=Object(de.a)(Object(fe.a)(n.prototype),"describe",this).call(this);return e.fields=z()(this.fields,(function(e){return e.describe()})),e}}]),n}(J);function Ve(e){return new Be(e)}function $e(){return($e=Object.assign||function(e){for(var t=1;t1&&void 0!==arguments[1]?arguments[1]:{},o=arguments.length>2?arguments[2]:void 0,c=[],s=a.sync,u=a.path,l=this.innerType,d=null!=(t=a.abortEarly)?t:this.spec.abortEarly,f=null!=(r=a.recursive)?r:this.spec.recursive,b=null!=a.originalValue?a.originalValue:e;Object(de.a)(Object(fe.a)(n.prototype),"_validate",this).call(this,e,a,(function(e,t){if(e){if(!P.isError(e)||d)return void o(e,t);c.push(e)}if(f&&l&&i._typeCheck(t)){b=b||t;for(var n=new Array(t.length),r=function(e){var r=t[e],i="".concat(a.path||"","[").concat(e,"]"),o=$e({},a,{path:i,strict:!0,parent:t,index:e,originalValue:b[e]});n[e]=function(e,t){return l.validate(r,o,t)}},p=0;p1&&void 0!==arguments[1]?arguments[1]:k.length;return this.test({message:t,name:"length",exclusive:!0,params:{length:e},test:function(t){return ue(t)||t.length===this.resolve(e)}})}},{key:"min",value:function(e,t){return t=t||k.min,this.test({message:t,name:"min",exclusive:!0,params:{min:e},test:function(t){return ue(t)||t.length>=this.resolve(e)}})}},{key:"max",value:function(e,t){return t=t||k.max,this.test({message:t,name:"max",exclusive:!0,params:{max:e},test:function(t){return ue(t)||t.length<=this.resolve(e)}})}},{key:"ensure",value:function(){var e=this;return this.default((function(){return[]})).transform((function(t,n){return e._typeCheck(t)?t:null==n?[]:[].concat(n)}))}},{key:"compact",value:function(e){var t=e?function(t,n,r){return!e(t,n,r)}:function(e){return!!e};return this.transform((function(e){return null!=e?e.filter(t):e}))}},{key:"describe",value:function(){var e=Object(de.a)(Object(fe.a)(n.prototype),"describe",this).call(this);return this.innerType&&(e.innerType=this.innerType.describe()),e}},{key:"nullable",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return Object(de.a)(Object(fe.a)(n.prototype),"nullable",this).call(this,e)}},{key:"defined",value:function(){return Object(de.a)(Object(fe.a)(n.prototype),"defined",this).call(this)}},{key:"required",value:function(e){return Object(de.a)(Object(fe.a)(n.prototype),"required",this).call(this,e)}}]),n}(J);Ue.prototype},235:function(e,t){e.exports=window.eventespresso.helpers},237:function(e,t,n){"use strict";n(159)},239:function(e,t,n){var r=n(122).Symbol;e.exports=r},24:function(e,t){e.exports=window.eventespresso.services},240:function(e,t,n){var r=n(148)(Object,"create");e.exports=r},241:function(e,t,n){var r=n(650),i=n(651),a=n(652),o=n(653),c=n(654);function s(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t-1&&e%1==0&&e<=9007199254740991}},302:function(e,t,n){var r=n(666),i=n(672),a=n(676);e.exports=function(e){return a(e)?r(e):i(e)}},31:function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(39);var i=n(68),a=n(42);function o(e){return function(e){if(Array.isArray(e))return Object(r.a)(e)}(e)||Object(i.a)(e)||Object(a.a)(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}},327:function(e,t,n){var r=n(405)((function(e,t,n){return e+(n?"_":"")+t.toLowerCase()}));e.exports=r},33:function(e,t,n){"use strict";function r(e){if(null===e||!0===e||!1===e)return NaN;var t=Number(e);return isNaN(t)?t:t<0?Math.ceil(t):Math.floor(t)}n.d(t,"a",(function(){return r}))},34:function(e,t,n){e.exports=n(171)},36:function(e,t){e.exports=window.eventespresso.constants},37:function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}n.d(t,"a",(function(){return r}))},377:function(e,t,n){"use strict";n.d(t,"a",(function(){return r}));var r=["datetimes","tickets"]},386:function(e,t,n){var r=n(387),i=n(392),a=n(132),o=n(393),c=n(301),s=n(244);e.exports=function(e,t,n){for(var u=-1,l=(t=r(t,e)).length,d=!1;++ue.length)&&(t=e.length);for(var n=0,r=new Array(t);n-1&&e%1==0&&el))return!1;var f=s.get(e),b=s.get(t);if(f&&b)return f==t&&b==e;var p=-1,v=!0,h=2&n?new r:void 0;for(s.set(e,t),s.set(t,e);++p=h?e:o.assocPath([d],v,e)}),{})},b=function(e){var t=function(e){return Object(s.sortDates)({dates:e}).reduce((function(e,t){var n=t.startDate,a=Object(c.a)(n),o=a.getFullYear(),s=a.getMonth(),u=e[o]||{};return s in u?e:(u[s]=Object(l.getMonthName)(a),Object(i.a)(Object(i.a)({},e),{},Object(r.a)({},o,u)))}),{})}(e);return Object.entries(t).map((function(e){var t=Object(a.a)(e,2),n=t[0],r=t[1];return{key:n,label:n,options:Object.entries(r).map((function(e){var t=Object(a.a)(e,2),r=t[0],i=t[1];return{key:"".concat(n,":").concat(r),label:i,value:"".concat(n,":").concat(r)}}))}}))}},46:function(e,t,n){"use strict";function r(e){return(r=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}n.d(t,"a",(function(){return r}))},461:function(e,t,n){"use strict";n.d(t,"a",(function(){return i})),n.d(t,"b",(function(){return a.a})),n.d(t,"c",(function(){return l})),n.d(t,"d",(function(){return f}));var r=n(16),i=function(){return Object(r.useEventsHandler)(),Object(r.useCacheRehydration)()},a=n(825),o=n(0),c=n(45),s=n(26),u=new c.EntityCardDetailsSubscription(r.domain).getSubscriptions,l=function(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=Object(o.useMemo)((function(){return new c.EntityCardDetailsRegistry({domain:r.domain,entityType:e,entityId:t})}),[t,e]),a=i.generateElements,l=u({entityType:n?e:null});return Object.values(l).forEach((function(n){(0,n.callback)({entityType:e,entityId:t,registry:i})})),Object(s.useMemoStringify)(a(),Object.keys(l))},d=new c.NewEntitySubscription(r.domain).getSubscriptions,f=function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=Object(o.useMemo)((function(){return new c.NewEntityOptionsRegistry({domain:r.domain,entityType:e})}),[e]),i=n.generateElements,a=d({entityType:t?e:null});return Object.values(a).forEach((function(t){(0,t.callback)({entityType:e,registry:n})})),Object(s.useMemoStringify)(i(),Object.keys(a))}},467:function(e,t,n){"use strict";var r=n(2),i=n(22),a=n(1);t.a=Object(i.a)((function(e){return Object(a.jsx)("svg",Object(r.a)(Object(r.a)({"aria-hidden":"true",fill:"currentColor",height:"1.5em",viewBox:"0 0 20 20",width:"1.5em",className:"ee-svg--trash"},e),{},{children:Object(a.jsx)("path",{d:"M12 4h3c.6 0 1 .4 1 1v1H3V5c0-.6.5-1 1-1h3c.2-1.1 1.3-2 2.5-2s2.3.9 2.5 2zM8 4h3c-.2-.6-.9-1-1.5-1S8.2 3.4 8 4zM4 7h11l-.9 10.1c0 .5-.5.9-1 .9H5.9c-.5 0-.9-.4-1-.9L4 7z"})}))}),"trash")},47:function(e,t,n){"use strict";function r(e,t){for(var n=0;n-1}},654:function(e,t,n){var r=n(242);e.exports=function(e,t){var n=this.__data__,i=r(n,e);return i<0?(++this.size,n.push([e,t])):n[i][1]=t,this}},655:function(e,t,n){var r=n(243);e.exports=function(e){var t=r(this,e).delete(e);return this.size-=t?1:0,t}},656:function(e,t){e.exports=function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}},657:function(e,t,n){var r=n(243);e.exports=function(e){return r(this,e).get(e)}},658:function(e,t,n){var r=n(243);e.exports=function(e){return r(this,e).has(e)}},659:function(e,t,n){var r=n(243);e.exports=function(e,t){var n=r(this,e),i=n.size;return n.set(e,t),this.size+=n.size==i?0:1,this}},66:function(e,t,n){"use strict";var r=Object.getOwnPropertySymbols,i=Object.prototype.hasOwnProperty,a=Object.prototype.propertyIsEnumerable;function o(e){if(null===e||void 0===e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}e.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var r={};return"abcdefghijklmnopqrst".split("").forEach((function(e){r[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},r)).join("")}catch(i){return!1}}()?Object.assign:function(e,t){for(var n,c,s=o(e),u=1;u=i?e:r(e,t,n)}},727:function(e,t){e.exports=function(e,t,n){var r=-1,i=e.length;t<0&&(t=-t>i?0:i+t),(n=n>i?i:n)<0&&(n+=i),i=t>n?0:n-t>>>0,t>>>=0;for(var a=Array(i);++r=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}n.d(t,"a",(function(){return r}))},80:function(e,t,n){"use strict";n.d(t,"a",(function(){return i}));var r=n(42);function i(e,t){var n;if("undefined"===typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=Object(r.a)(e))||t&&e&&"number"===typeof e.length){n&&(e=n);var i=0,a=function(){};return{s:a,n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:a}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,c=!0,s=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return c=e.done,e},e:function(e){s=!0,o=e},f:function(){try{c||null==n.return||n.return()}finally{if(s)throw o}}}}},82:function(e,t){e.exports=window.eventespresso.form},825:function(e,t,n){"use strict";n.d(t,"a",(function(){return s}));var r=n(0),i=n(45),a=n(16),o=n(26),c=new i.EntityActionsSubscription(a.domain).getSubscriptions,s=function(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],s=Object(r.useMemo)((function(){return new i.EntityActionsMenuRegistry({domain:a.domain,entityType:e,entityId:t.id})}),[t.id,e]),u=s.generateElements,l=c({entityType:n?e:null});return Object.values(l).forEach((function(n){(0,n.callback)({entityType:e,entity:t,registry:s})})),Object(o.useMemoStringify)(u(),Object.keys(l))}},84:function(e,t){e.exports=window.eventespresso.tpc},85:function(e,t,n){"use strict";function r(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}n.d(t,"a",(function(){return r}))},88:function(e,t,n){"use strict";n.d(t,"a",(function(){return u})),n.d(t,"b",(function(){return b})),n.d(t,"c",(function(){return h})),n.d(t,"d",(function(){return _})),n.d(t,"e",(function(){return E})),n.d(t,"f",(function(){return C}));var r=n(14),i=n(9),a=n(0),o=n(4),c=n(24),s=n(377),u=function(){var e=Object(c.useRelationsManager)(),t=e.addRelation,n=e.getData,u=e.getRelations,l=e.initialize,d=e.isInitialized,f=e.removeRelation,b=Object(a.useState)(!1),p=Object(i.a)(b,2),v=p[0],h=p[1],j=Object(a.useCallback)((function(e){var t=e.datetimeId;return u({entity:"datetimes",entityId:t,relation:"tickets"})}),[u]),O=Object(a.useCallback)((function(e){var t=e.ticketId;return u({entity:"tickets",entityId:t,relation:"datetimes"})}),[u]),m=Object(a.useCallback)((function(e){var n=e.datetimeId,r=e.ticketId,i=e.remove,a={entity:"datetimes",entityId:n,relation:"tickets",relationId:r},o={entity:"tickets",entityId:r,relation:"datetimes",relationId:n};void 0!==i&&i?(f(a),f(o)):(t(a),t(o)),h(!0)}),[t,f]),y=Object(a.useCallback)((function(e){var t=e.datetimeId,n=e.ticketId;m({datetimeId:t,ticketId:n})}),[m]),g=Object(a.useCallback)((function(e){var t=e.datetimeId,n=e.ticketId,r=j({datetimeId:t}).includes(n);m({datetimeId:t,ticketId:n,remove:r})}),[j,m]),_=Object(a.useCallback)((function(e){var t=e.datetimeId,n=e.ticketId;m({datetimeId:t,ticketId:n,remove:!0})}),[m]),x=Object(a.useCallback)((function(e){var t=e.assignmentType,n=e.entity,i=e.entityType,a=e.relationalEntity,c=a;if(("forDate"===t&&"datetimes"===i||"forTicket"===t&&"tickets"===i)&&(c=o.pick([n.id],a),o.isEmpty(c))){var u="datetimes"===i?"tickets":"datetimes";c[n.id]=Object(r.a)({},u,[])}return o.map((function(e){return o.pick(s.a,e)}),c)}),[]),k=Object(a.useCallback)((function(e){var t=e.data,n=e.assignmentType,r=e.entity,i=o.pick(s.a,t);i=o.mapObjIndexed((function(e,t){return x({assignmentType:n,entity:r,entityType:t,relationalEntity:e})}),i),l(i)}),[l,x]);return Object(a.useMemo)((function(){return{addAssignment:y,getAssignedDates:O,getAssignedTickets:j,getData:n,initialize:k,isDirty:v,isInitialized:d,removeAssignment:_,toggleAssignment:g}}),[y,O,j,n,k,v,d,_,g])},l=n(63),d=n.n(l),f=n(169),b=function(){var e=Object(a.useContext)(f.DataStateContext);return d()(e,"useDataState must be used inside TAM component"),e},p=n(2),v=n(16),h=function(e){var t,n=Object(a.useState)(!1),r=Object(i.a)(n,2),s=r[0],l=r[1],d=u(),f=Object(c.useRelations)(),b=C(d),h=Object(v.useDefaultTicketIds)(),j=d.initialize,O=(0,d.isInitialized)(),m=Object(a.useCallback)((function(e){var t=e.ticketId;return b.tickets.includes(t)}),[b.tickets]),y=Object(a.useCallback)((function(e){var t=e.datetimeId;return b.datetimes.includes(t)}),[b.datetimes]),g=Object(a.useCallback)((function(t){var n,r,i;return!("tickets"===t&&"forDate"===e.assignmentType||"datetimes"===t&&"forTicket"===e.assignmentType)&&("forAll"!==e.assignmentType?null===(r=b[t])||void 0===r?void 0:r.includes(null===(i=e.entity)||void 0===i?void 0:i.id):(null===(n=b[t])||void 0===n?void 0:n.length)>0)}),[b,e.assignmentType,null===(t=e.entity)||void 0===t?void 0:t.id]),_=Object(a.useCallback)((function(){return g("tickets")}),[g]),x=Object(a.useCallback)((function(){return g("datetimes")}),[g]),k=Object(a.useCallback)((function(){return _()||x()}),[x,_]),T=Object(a.useCallback)((function(e){var t=e.datetimeId;return f.getRelations({entity:"datetimes",entityId:t,relation:"tickets"})}),[f]),w=Object(a.useCallback)((function(e){var t=e.datetimeId,n=e.ticketId,r=T({datetimeId:t}),i=d.getAssignedTickets({datetimeId:t}),a=r.includes(n),o=i.includes(n);switch(!0){case a&&o:return"OLD";case!a&&o:return"NEW";case a&&!o:return"REMOVED";case!a&&!o:return null}}),[d,T]);return Object(a.useEffect)((function(){if(!O){var t,n,r=f.getData(),i=Object(p.a)(Object(p.a)({},r),{},{tickets:o.omit(h,r.tickets||{})});j(Object(p.a)({data:i},e));var a=0!==(null===b||void 0===b||null===(t=b.datetimes)||void 0===t?void 0:t.length)||0!==(null===b||void 0===b||null===(n=b.tickets)||void 0===n?void 0:n.length);l(!a)}}),[h,j,O,b,e,f,l]),Object(a.useMemo)((function(){return Object(p.a)(Object(p.a)({},d),{},{getAssignmentStatus:w,hasNoAssignedDates:m,hasNoAssignedTickets:y,hasOrphanDates:x,hasOrphanEntities:k,hasOrphanTickets:_,initialDataIsValid:s})}),[d,w,m,y,x,k,_,s])},j=n(26),O=n(12),m=n(286),y=function(e){var t=Object(m.useFilterState)(),n=t.showTrashedDates,r=t.datesByMonth,i=Object(O.inYearAndMonth)(r),o=Object(a.useMemo)((function(){return r[0]?i(e):e}),[e,r,i]);return Object(a.useMemo)((function(){return n?o:Object(O.notTrashed)(o)}),[o,n])},g=function(e){var t=Object(m.useFilterState)(),n=t.showExpiredTickets,r=t.showTrashedTickets;return Object(a.useMemo)((function(){var t=e;return n||(t=t.filter((function(e){return!Object(O.isExpired)(e)}))),r||(t=Object(O.notTrashed)(t)),t}),[e,n,r])},_=function(){var e,t,n=Object(f.useTAMContext)(),r=n.assignmentType,i=n.entity,a=Object(v.useDatetimes)(),o=Object(v.useTickets)(),c=y(a),s=g(o);switch(r){case"forAll":e=c,t=s;break;case"forDate":e=[i],t=s;break;case"forTicket":e=c,t=[i]}return Object(j.useMemoStringify)({datetimes:e,tickets:t})},x=n(43),k=n(34),T=n.n(k),w=n(456),E=function(){var e=Object(c.useRelations)().getData,t=Object(v.useDatetimes)(),n=Object(v.useTickets)(),r=Object(v.useBulkEditTickets)().updateEntities;return Object(a.useCallback)(function(){var a=Object(x.a)(T.a.mark((function a(c){var s,u,l,d;return T.a.wrap((function(a){for(;;)switch(a.prev=a.next){case 0:if(s=e(),u=Object(w.b)({entity:"tickets",existingData:s,newData:c,relation:"datetimes"}),l=Object(w.c)({allDates:t,allTickets:n,existingData:s,ticketsToUpdate:u}),d=u.map((function(e){var t=Object(i.a)(e,2),n=t[0],r=t[1],a={id:n,datetimes:null===r||void 0===r?void 0:r.datetimes},o=null===l||void 0===l?void 0:l[n];return o?Object(p.a)(Object(p.a)({},a),{},{quantity:o}):a})),Object.entries(l).forEach((function(e){var t=Object(i.a)(e,2),n=t[0],r=t[1];o.any(Object(O.entityHasGuid)(n),d)||d.push({id:n,quantity:r})})),!(null===d||void 0===d?void 0:d.length)){a.next=8;break}return a.next=8,r({uniqueInputs:d});case 8:case"end":return a.stop()}}),a)})));return function(e){return a.apply(this,arguments)}}(),[t,n,r,e])},D={datetimes:[],tickets:[]},C=function(e){var t=Object(a.useState)(D),n=Object(i.a)(t,2),r=n[0],c=n[1],s=e.getData();return Object(a.useEffect)((function(){if(!o.isEmpty(s)){var e=o.mapObjIndexed((function(e,t){var n="datetimes"===t?"tickets":"datetimes",r=o.pickBy((function(e){return 0===((null===e||void 0===e?void 0:e[n])||[]).length}),e);return Object.keys(r)}),s);c(e)}}),[s]),r}},9:function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(54);var i=n(42),a=n(55);function o(e,t){return Object(r.a)(e)||function(e,t){if("undefined"!==typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,i=!1,a=void 0;try{for(var o,c=e[Symbol.iterator]();!(r=(o=c.next()).done)&&(n.push(o.value),!t||n.length!==t);r=!0);}catch(s){i=!0,a=s}finally{try{r||null==c.return||c.return()}finally{if(i)throw a}}return n}}(e,t)||Object(i.a)(e,t)||Object(a.a)()}},98:function(e,t,n){"use strict";function r(e,t){return(r=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}n.d(t,"a",(function(){return r}))}}); -//# sourceMappingURL=eventEditor.5414d673.js.map \ No newline at end of file diff --git a/assets/static/js/eventEditor.5414d673.js.map b/assets/static/js/eventEditor.5414d673.js.map deleted file mode 100644 index f9da84f5a18..00000000000 --- a/assets/static/js/eventEditor.5414d673.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["../webpack/bootstrap","../external \"React\"","../node_modules/react/jsx-runtime.js","../node_modules/classnames/index.js","../node_modules/date-fns/esm/parseISO/index.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/typeof.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/isNativeReflectConstruct.js","../external [\"eventespresso\",\"predicates\"]","../node_modules/lodash/_root.js","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/filters/filterState/useFilterState.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/context/withContext.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/context/useTAMContext.ts","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/data/useDataState.ts","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/data/useSubmitForm.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/filters/controls/DatesByMonthControl.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/filters/controls/ShowExpiredTicketsControl.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/filters/controls/ShowTrashedDatesControl.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/filters/controls/ShowTrashedTicketsControl.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/filters/FilterBar.tsx","../node_modules/lodash/isArray.js","../node_modules/property-expr/index.js","../node_modules/clsx/dist/clsx.m.js","../../src/utils/propValidator.ts","../../src/utils/constant.ts","../../src/utils/cssTransition.tsx","../../src/utils/collapseToast.ts","../../src/core/eventManager.ts","../../src/hooks/useKeeper.ts","../../src/hooks/toastContainerReducer.ts","../../src/hooks/useToastContainer.ts","../../src/hooks/useToast.ts","../../src/components/CloseButton.tsx","../../src/components/ProgressBar.tsx","../../src/components/Icons.tsx","../../src/components/Toast.tsx","../../src/components/Transitions.tsx","../../src/components/ToastContainer.tsx","../../src/core/toast.tsx","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/defineProperty.js","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/data/useDataStateReducer.ts","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/data/useDataStateManager.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/filters/filterState/reducer.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/filters/filterState/useFilterStateManager.ts","../external [\"eventespresso\",\"formBuilder\"]","../node_modules/lodash/_getNative.js","../node_modules/date-fns/esm/_lib/requiredArgs/index.js","../node_modules/lodash/has.js","../packages/icons/src/icons/CloseOutlined.tsx","../node_modules/webpack/buildin/global.js","../external [\"eventespresso\",\"edtrServices\"]","../packages/icons/src/icons/Link.tsx","../packages/icons/src/icons/Unlink.tsx","../packages/icons/src/icons/Calculator.tsx","../packages/icons/src/icons/MapMarker.tsx","../packages/icons/src/icons/Calendar.tsx","../packages/icons/src/icons/CalendarOutlined.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/context/index.ts","../packages/edtr-services/src/publicPath.ts","../packages/icons/src/types.ts","../domains/core/admin/eventEditor/src/services/utils.ts","../packages/icons/src/icons/Ticket.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/newDateOptions/AddSingleDate.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/newDateOptions/OptionsModalButton.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/newDateOptions/NewDateButton.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/newDateOptions/NewDateModal.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/DatesListButtons.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/DatesListFooter.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/config.ts","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/cardView/RenderCardView.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/tableView/RenderTableView.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/filterBar/controls/options.ts","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/filterBar/ActiveDatesFilters.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/filterBar/controls/DisplayStartOrEndDateControl.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/filterBar/controls/SalesControl.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/filterBar/controls/StatusControl.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/filterBar/controls/SortByControl/DraggableDatetime.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/filterBar/controls/SortByControl/index.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/DatesList.tsx","../domains/core/admin/eventEditor/src/ui/EventRegistrationOptions/ActiveStatus.tsx","../domains/core/admin/eventEditor/src/ui/EventRegistrationOptions/AltRegPage.tsx","../domains/core/admin/eventEditor/src/ui/EventRegistrationOptions/DefaultRegistrationStatus.tsx","../domains/core/admin/eventEditor/src/ui/EventRegistrationOptions/Donations.tsx","../domains/core/admin/eventEditor/src/ui/EventRegistrationOptions/EventManager.tsx","../domains/core/admin/eventEditor/src/ui/EventRegistrationOptions/EventPhoneNumber.tsx","../domains/core/admin/eventEditor/src/ui/EventRegistrationOptions/MaxRegistrations.tsx","../domains/core/admin/eventEditor/src/ui/EventRegistrationOptions/TicketSelector.tsx","../domains/core/admin/eventEditor/src/ui/EventRegistrationOptions/withData.tsx","../domains/core/admin/eventEditor/src/ui/EventRegistrationOptions/index.tsx","../domains/core/admin/eventEditor/src/ui/tickets/hooks/useNewTicketOptionItems.ts","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/newTicketOptions/OptionsModal.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/newTicketOptions/NewTicketButton.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/newTicketOptions/AddSingleTicket.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/actions/Actions.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/TicketsListFooter.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/config.ts","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/cardView/RenderCardView.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/tableView/RenderTableView.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/filterBar/controls/options.ts","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/filterBar/ActiveTicketsFilters.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/filterBar/controls/DisplayStartOrEndDateControl.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/filterBar/controls/SalesControl.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/filterBar/controls/StatusControl.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/filterBar/controls/SortByControl/DraggableTicket.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/filterBar/controls/SortByControl/index.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/filterBar/controls/IsChainedButton.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/TicketsList.tsx","../domains/core/admin/eventEditor/src/ui/EventDescription.tsx","../packages/icons/src/icons/VenueSeat.tsx","../packages/icons/src/icons/Phone.tsx","../domains/core/admin/eventEditor/src/ui/venue/useVenueLink.ts","../domains/core/admin/eventEditor/src/ui/venue/VenueDetails.tsx","../domains/core/admin/eventEditor/src/ui/registrationForm/constants.ts","../domains/core/admin/eventEditor/src/ui/registrationForm/utils.ts","../domains/core/admin/eventEditor/src/ui/registrationForm/ErrorMessage.tsx","../domains/core/admin/eventEditor/src/ui/registrationForm/RegistrationForm.tsx","../domains/core/admin/eventEditor/src/ui/notifications/useNotifications.ts","../domains/core/admin/eventEditor/src/ui/notifications/Notifications.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/dateForm/formValidation.ts","../domains/core/admin/eventEditor/src/ui/datetimes/dateForm/useDateFormConfig.ts","../domains/core/admin/eventEditor/src/ui/datetimes/dateForm/multiStep/DateFormSteps.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/dateForm/multiStep/useDataListener.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/ErrorMessage.tsx","../packages/icons/src/icons/MinusOutlined.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/table/getRelationIcon/index.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/table/BodyCell.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/table/DateCell.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/table/useRowClassName.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/table/useColClassName.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/table/useGetBodyRows.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/table/HeaderCell.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/table/useGetHeaderRows.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/table/Table.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/Debug.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/TicketAssignmentsManager.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/config.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/useSubmitButtonProps.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/TicketAssignmentsManagerModal.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/useInvalidDataAlert.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/ModalContainer.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/dateForm/multiStep/TAMStep.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/dateForm/multiStep/ModalBody.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/dateForm/multiStep/constants.ts","../domains/core/admin/eventEditor/src/ui/datetimes/dateForm/multiStep/FooterButtons.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/dateForm/multiStep/Modal.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/dateForm/multiStep/ContextProvider.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/dateForm/multiStep/Content.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/dateForm/multiStep/useOnSubmit.ts","../domains/core/admin/eventEditor/src/ui/datetimes/dateForm/multiStep/Container.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/actionsMenu/dropdown/useActions.ts","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/actionsMenu/dropdown/DeleteDatetime.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/actionsMenu/dropdown/DateMainMenu.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/actionsMenu/AssignTicketsButton.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/registryInit.tsx","../domains/core/admin/eventEditor/src/ui/tickets/hooks/useDeleteTicketHandler.ts","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/actionsMenu/dropdown/DeleteTicket.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/actionsMenu/dropdown/TicketMainMenu.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketForm/formValidation.ts","../domains/core/admin/eventEditor/src/ui/tickets/ticketForm/useTicketFormConfig.ts","../domains/core/admin/eventEditor/src/ui/tickets/ticketForm/multiStep/TicketFormSteps.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketForm/multiStep/TPCStep.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketForm/multiStep/useDataListener.ts","../domains/core/admin/eventEditor/src/ui/tickets/ticketForm/multiStep/TAMStep.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketForm/multiStep/ModalBody.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketForm/multiStep/constants.ts","../domains/core/admin/eventEditor/src/ui/tickets/ticketForm/multiStep/FooterButtons.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketForm/multiStep/Modal.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketForm/multiStep/ContextProvider.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketForm/multiStep/Content.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketForm/multiStep/useOnSubmit.ts","../domains/core/admin/eventEditor/src/ui/tickets/ticketForm/multiStep/Container.tsx","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/TicketCard.tsx","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/multiStep/useTicketFormConfig.ts","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/multiStep/TicketFormSteps.tsx","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/multiStep/TPCStep.tsx","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/multiStep/ModalBody.tsx","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/multiStep/FooterButtons.tsx","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/multiStep/Modal.tsx","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/multiStep/ContextProvider.tsx","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/multiStep/ContentRenderer.tsx","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/ModalBody.tsx","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/Container.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/actionsMenu/AssignDatesButton.tsx","../domains/core/admin/eventEditor/src/ui/tickets/registryInit.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/registryInit.tsx","../domains/core/admin/eventEditor/src/services/filterState/datetimes/registerFilters.ts","../domains/core/admin/eventEditor/src/services/filterState/tickets/registerFilters.ts","../domains/core/admin/eventEditor/src/ui/EventEditor.tsx","../domains/core/admin/eventEditor/src/ui/index.tsx","../external [\"eventespresso\",\"utils\"]","../node_modules/regenerator-runtime/runtime.js","../external [\"eventespresso\",\"toaster\"]","../packages/icons/src/icons/ProfileOutlined.tsx","../packages/icons/src/icons/ControlOutlined.tsx","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/data/index.ts","../external [\"eventespresso\",\"data\"]","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/objectSpread2.js","../node_modules/lodash/_baseGetTag.js","../node_modules/lodash/isObjectLike.js","../node_modules/lodash/toString.js","../packages/icons/src/withClassName.tsx","../node_modules/nanoclone/src/index.js","../node_modules/yup/es/util/printValue.js","../node_modules/yup/es/locale.js","../node_modules/yup/es/util/isSchema.js","../node_modules/yup/es/Condition.js","../node_modules/yup/es/util/toArray.js","../node_modules/yup/es/ValidationError.js","../node_modules/yup/es/util/runTests.js","../node_modules/yup/es/Reference.js","../node_modules/yup/es/util/createValidation.js","../node_modules/yup/es/util/reach.js","../node_modules/yup/es/util/ReferenceSet.js","../node_modules/yup/es/schema.js","../node_modules/yup/es/mixed.js","../node_modules/yup/es/util/isAbsent.js","../node_modules/yup/es/boolean.js","../node_modules/yup/es/string.js","../node_modules/yup/es/number.js","../node_modules/yup/es/util/isodate.js","../node_modules/yup/es/date.js","../node_modules/yup/es/util/sortFields.js","../node_modules/yup/es/util/sortByKeyOrder.js","../node_modules/yup/es/object.js","../node_modules/yup/es/array.js","../external [\"eventespresso\",\"helpers\"]","../types/index.ts","../node_modules/lodash/_Symbol.js","../external [\"eventespresso\",\"services\"]","../node_modules/lodash/_nativeCreate.js","../node_modules/lodash/_ListCache.js","../node_modules/lodash/_assocIndexOf.js","../node_modules/lodash/_getMapData.js","../node_modules/lodash/_toKey.js","../node_modules/lodash/mapValues.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/construct.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/wrapNativeSuper.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/isNativeFunction.js","../external [\"eventespresso\",\"hooks\"]","../external [\"eventespresso\",\"adapters\"]","../external [\"wp\",\"i18n\"]","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/context/ContextProvider.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/filters/index.ts","../node_modules/webpack/buildin/module.js","../node_modules/lodash/_isKey.js","../node_modules/lodash/isSymbol.js","../node_modules/lodash/_MapCache.js","../node_modules/lodash/isObject.js","../external [\"eventespresso\",\"i18n\"]","../node_modules/lodash/_Map.js","../node_modules/lodash/isLength.js","../node_modules/lodash/keys.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/toConsumableArray.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/arrayWithoutHoles.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/nonIterableSpread.js","../node_modules/lodash/snakeCase.js","../node_modules/date-fns/esm/_lib/toInteger/index.js","../node_modules/@babel/runtime/regenerator/index.js","../external [\"eventespresso\",\"constants\"]","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/classCallCheck.js","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/constants.ts","../node_modules/lodash/_hasPath.js","../node_modules/lodash/_castPath.js","../node_modules/lodash/_freeGlobal.js","../node_modules/lodash/isFunction.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/arrayLikeToArray.js","../node_modules/lodash/_toSource.js","../node_modules/lodash/eq.js","../node_modules/lodash/isArguments.js","../node_modules/lodash/_isIndex.js","../node_modules/lodash/_baseAssignValue.js","../node_modules/lodash/_baseForOwn.js","../node_modules/lodash/isBuffer.js","../node_modules/lodash/isTypedArray.js","../node_modules/lodash/_baseIteratee.js","../node_modules/lodash/_Stack.js","../external \"R\"","../node_modules/lodash/_baseIsEqual.js","../node_modules/lodash/_equalArrays.js","../node_modules/lodash/_isStrictComparable.js","../node_modules/lodash/_matchesStrictComparable.js","../node_modules/lodash/_baseGet.js","../node_modules/lodash/_createCompounder.js","../node_modules/lodash/_hasUnicode.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/asyncToGenerator.js","../external [\"wp\",\"url\"]","../node_modules/lodash/camelCase.js","../node_modules/lodash/mapKeys.js","../node_modules/toposort/index.js","../external [\"eventespresso\",\"registry\"]","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/utils/index.ts","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/getPrototypeOf.js","../domains/core/admin/eventEditor/src/hooks/useEditorInitialization.ts","../domains/core/admin/eventEditor/src/hooks/entityCardDetails/useEntityCardDetailsItems.ts","../domains/core/admin/eventEditor/src/hooks/newEntityOptions/useNewEntityOptionItems.ts","../packages/icons/src/icons/Trash.tsx","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/createClass.js","../external [\"eventespresso\",\"uiComponents\"]","../external [\"eventespresso\",\"dates\"]","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/inherits.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/possibleConstructorReturn.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/createSuper.js","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/context/DataStateProvider.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/filters/filterState/index.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/context/FilterStateProvider.tsx","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/data/useInitialState.ts","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/arrayWithHoles.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/nonIterableRest.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/get.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/superPropBase.js","../external [\"eventespresso\",\"plugins\"]","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/context/DataStateProvider.tsx","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/context/ContextProvider.tsx","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/context/withContext.tsx","../external \"ReactDOM\"","../node_modules/invariant/browser.js","../node_modules/lodash/_baseHas.js","../node_modules/lodash/_getRawTag.js","../node_modules/lodash/_objectToString.js","../node_modules/lodash/_stringToPath.js","../node_modules/lodash/_memoizeCapped.js","../node_modules/lodash/memoize.js","../node_modules/lodash/_mapCacheClear.js","../external [\"eventespresso\",\"eeComponents\"]","../node_modules/lodash/_Hash.js","../node_modules/lodash/_hashClear.js","../node_modules/lodash/_baseIsNative.js","../node_modules/lodash/_isMasked.js","../node_modules/lodash/_coreJsData.js","../node_modules/lodash/_getValue.js","../node_modules/lodash/_hashDelete.js","../node_modules/lodash/_hashGet.js","../node_modules/lodash/_hashHas.js","../node_modules/lodash/_hashSet.js","../node_modules/lodash/_listCacheClear.js","../node_modules/lodash/_listCacheDelete.js","../node_modules/lodash/_listCacheGet.js","../node_modules/lodash/_listCacheHas.js","../node_modules/lodash/_listCacheSet.js","../node_modules/lodash/_mapCacheDelete.js","../node_modules/lodash/_isKeyable.js","../node_modules/lodash/_mapCacheGet.js","../node_modules/lodash/_mapCacheHas.js","../node_modules/lodash/_mapCacheSet.js","../node_modules/object-assign/index.js","../node_modules/lodash/_baseToString.js","../node_modules/lodash/_arrayMap.js","../node_modules/lodash/_baseIsArguments.js","../node_modules/lodash/_defineProperty.js","../node_modules/lodash/_baseFor.js","../node_modules/lodash/_createBaseFor.js","../node_modules/lodash/_arrayLikeKeys.js","../node_modules/lodash/_baseTimes.js","../node_modules/lodash/stubFalse.js","../node_modules/lodash/_baseIsTypedArray.js","../node_modules/lodash/_baseUnary.js","../node_modules/lodash/_nodeUtil.js","../node_modules/lodash/_baseKeys.js","../node_modules/lodash/_isPrototype.js","../node_modules/lodash/_nativeKeys.js","../node_modules/lodash/_overArg.js","../node_modules/lodash/isArrayLike.js","../node_modules/lodash/_baseMatches.js","../node_modules/lodash/_baseIsMatch.js","../node_modules/lodash/_stackClear.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/iterableToArray.js","../node_modules/lodash/_stackDelete.js","../node_modules/lodash/_stackGet.js","../node_modules/lodash/_stackHas.js","../node_modules/lodash/_stackSet.js","../node_modules/lodash/_baseIsEqualDeep.js","../node_modules/lodash/_SetCache.js","../node_modules/lodash/_setCacheAdd.js","../node_modules/lodash/_setCacheHas.js","../node_modules/lodash/_arraySome.js","../node_modules/lodash/_cacheHas.js","../node_modules/lodash/_equalByTag.js","../node_modules/lodash/_Uint8Array.js","../node_modules/lodash/_mapToArray.js","../node_modules/lodash/_setToArray.js","../node_modules/lodash/_equalObjects.js","../node_modules/lodash/_getAllKeys.js","../node_modules/lodash/_baseGetAllKeys.js","../node_modules/lodash/_arrayPush.js","../node_modules/lodash/_getSymbols.js","../node_modules/lodash/_arrayFilter.js","../node_modules/lodash/stubArray.js","../node_modules/lodash/_getTag.js","../node_modules/lodash/_DataView.js","../node_modules/lodash/_Promise.js","../node_modules/lodash/_Set.js","../node_modules/lodash/_WeakMap.js","../node_modules/lodash/_getMatchData.js","../node_modules/lodash/_baseMatchesProperty.js","../node_modules/lodash/get.js","../node_modules/lodash/hasIn.js","../node_modules/lodash/_baseHasIn.js","../node_modules/lodash/identity.js","../node_modules/lodash/property.js","../node_modules/lodash/_baseProperty.js","../node_modules/lodash/_basePropertyDeep.js","../node_modules/lodash/_arrayReduce.js","../node_modules/lodash/deburr.js","../node_modules/lodash/_deburrLetter.js","../node_modules/lodash/_basePropertyOf.js","../node_modules/lodash/words.js","../node_modules/lodash/_asciiWords.js","../node_modules/lodash/_hasUnicodeWord.js","../node_modules/lodash/_unicodeWords.js","../node_modules/lodash/capitalize.js","../node_modules/lodash/upperFirst.js","../node_modules/lodash/_createCaseFirst.js","../node_modules/lodash/_castSlice.js","../node_modules/lodash/_baseSlice.js","../node_modules/lodash/_stringToArray.js","../node_modules/lodash/_asciiToArray.js","../node_modules/lodash/_unicodeToArray.js","../node_modules/react/cjs/react-jsx-runtime.production.min.js","../packages/icons/src/icons/SaveOutlined.tsx","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/createForOfIteratorHelper.js","../external [\"eventespresso\",\"form\"]","../domains/core/admin/eventEditor/src/hooks/entityActionsMenu/useEntityActionsMenuItems.ts","../external [\"eventespresso\",\"tpc\"]","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/assertThisInitialized.js","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/data/useAssignmentManager.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/data/useDataState.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/data/useDataStateManager.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/data/useFilteredDatetimes.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/data/useFilteredTickets.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/data/useDatesAndTickets.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/data/useOnSubmitAssignments.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/data/useValidation.ts","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/slicedToArray.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/iterableToArrayLimit.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js"],"names":["webpackJsonpCallback","data","moduleId","chunkId","chunkIds","moreModules","i","resolves","length","Object","prototype","hasOwnProperty","call","installedChunks","push","modules","parentJsonpFunction","shift","installedModules","installedCssChunks","__webpack_require__","exports","module","l","e","promises","Promise","resolve","reject","href","fullhref","p","existingLinkTags","document","getElementsByTagName","dataHref","tag","getAttribute","rel","existingStyleTags","linkTag","createElement","type","onerror","onload","event","errorType","realHref","target","err","Error","code","request","parentNode","removeChild","head","appendChild","then","installedChunkData","promise","onScriptComplete","script","charset","timeout","nc","setAttribute","src","jsonpScriptSrc","error","clearTimeout","chunk","realSrc","message","name","undefined","setTimeout","all","m","c","d","getter","o","defineProperty","enumerable","get","r","Symbol","toStringTag","value","t","mode","__esModule","ns","create","key","bind","n","object","property","oe","console","jsonpArray","this","oldJsonpFunction","slice","s","window","require","hasOwn","classNames","classes","arguments","arg","argType","Array","isArray","inner","apply","toString","join","default","MILLISECONDS_IN_HOUR","patterns","dateTimeDelimiter","timeZoneDelimiter","timezone","dateRegex","timeRegex","timezoneRegex","parseISO","argument","dirtyOptions","requiredArgs","options","additionalDigits","toInteger","RangeError","Date","NaN","date","dateStrings","splitDateString","parseYearResult","parseYear","parseDate","restDateString","year","isNaN","offset","timestamp","getTime","time","parseTime","dirtyDate","result","setFullYear","getUTCFullYear","getUTCMonth","getUTCDate","setHours","getUTCHours","getUTCMinutes","getUTCSeconds","getUTCMilliseconds","parseTimezone","dateString","timeString","array","split","test","substr","token","exec","replace","regex","RegExp","captures","match","parseInt","century","isWeekDate","dayOfYear","parseDateUnit","month","day","week","dayOfWeek","_year","validateWeekDate","isoWeekYear","setUTCFullYear","fourthOfJanuaryDay","getUTCDay","diff","setUTCDate","dayOfISOWeekYear","daysInMonths","isLeapYearIndex","validateDate","validateDayOfYearDate","Math","max","hours","parseTimeUnit","minutes","seconds","validateTime","parseFloat","timezoneString","sign","_hours","validateTimezone","_typeof","obj","iterator","constructor","_isNativeReflectConstruct","Reflect","construct","sham","Proxy","freeGlobal","freeSelf","self","root","Function","useFilterState","useContext","FilterStateContext","invariant","withContext","Component","contextProps","props","_jsx","ContextProvider","_objectSpread","children","useTAMContext","Context","useDataState","state","DataStateContext","useSubmitForm","_ref","deletedTickets","tickets","mutateTicket","useMutateTicket","deleteTicket","useTicketMutator","deleteEntity","useCallback","_asyncToGenerator","_regeneratorRuntime","mark","_callee","wrap","_context","prev","next","values","map","id","deletePermanently","stop","DatesByMonthControl","datesByMonth","setDatesByMonth","datetimes","useDatetimes","monthsList","getMonthsListFromDatetimes","yearMonth","monthsListWithAllDates","useMemo","label","__","concat","_toConsumableArray","SelectWithLabel","onChangeValue","ShowExpiredTicketsControl","showExpiredTickets","setShowExpiredTickets","SwitchWithLabel","isChecked","ShowTrashedDatesControl","showTrashedDates","setShowTrashedDates","ShowTrashedTicketsControl","showTrashedTickets","setShowTrashedTickets","FilterBar","assignmentType","_useFilterState","_jsxs","className","_Fragment","Cache","maxSize","_maxSize","clear","_size","_values","set","SPLIT_REGEX","DIGIT_REGEX","LEAD_DIGIT_REGEX","SPEC_CHAR_REGEX","CLEAN_QUOTES_REGEX","pathCache","setCache","getCache","normalizePath","path","part","isQuoted","str","indexOf","charAt","shouldBeQuoted","hasLeadingNumber","hasSpecialChars","setter","parts","index","len","safe","segments","reduce","forEach","cb","thisArg","iter","idx","isBracket","toVal","mix","k","y","tmp","x","isNum","v","isBool","isStr","isFn","parseClassName","isToastIdValid","toastId","canUseDom","canBeRendered","content","isValidElement","POSITION","TOP_LEFT","TOP_RIGHT","TOP_CENTER","BOTTOM_LEFT","BOTTOM_RIGHT","BOTTOM_CENTER","TYPE","INFO","SUCCESS","WARNING","ERROR","DEFAULT","cssTransition","enter","exit","appendPosition","_ref$appendPosition","collapse","_ref$collapse","collapseDuration","_ref$collapseDuration","_ref2","position","preventExitTransition","done","nodeRef","isIn","enterClassName","exitClassName","baseClassName","useRef","animationStep","onEntered","current","node","removeEventListener","onExited","duration","scrollHeight","style","requestAnimationFrame","minHeight","height","transition","padding","margin","collapseToast","useLayoutEffect","addEventListener","onEnter","useEffect","onExit","React__default","Fragment","eventManager","list","Map","emitQueue","on","callback","has","off","filter","cancelEmit","timers","emit","args","_len","_key","timer","_this","useKeeper","refresh","ref","reducer","action","staleId","useToastContainer","forceUpdate","useReducer","_useReducer2","toast","dispatch","containerRef","toastCount","queue","collection","instance","toastKey","displayedToast","containerId","isToastActive","getToast","clearWaitingQueue","limit","removeToast","dequeueToast","_queue$shift","appendToast","toastContent","toastProps","buildToast","_ref3","delay","_objectWithoutPropertiesLoose","_excluded","updateId","enableMultiContainer","isNotValid","closeToast","isNotAnUpdate","toastAutoClose","containerAutoClose","isLoading","theme","icon","_options$icon","closeButton","rtl","toastClassName","bodyClassName","toastStyle","bodyStyle","onClick","pauseOnHover","pauseOnFocusLoss","draggable","draggablePercent","draggableDirection","closeOnClick","progressClassName","progressStyle","autoClose","hideProgressBar","progress","role","deleteToast","queueLen","freeSlot","toDequeue","removeFromCollection","onOpen","onClose","cloneElement","getToastToRender","toastToRender","toastList","newestOnTop","keys","reverse","_toast","getX","targetTouches","clientX","getY","clientY","useToast","_useState","useState","isRunning","setIsRunning","_useState2","setPreventExitTransition","toastRef","drag","start","delta","removalDistance","canCloseOnClick","canDrag","boundingRect","syncProps","onDragStart","getBoundingClientRect","nativeEvent","offsetWidth","offsetHeight","onDragTransitionEnd","_drag$boundingRect","top","bottom","left","right","pauseToast","playToast","onDragMove","preventDefault","transform","opacity","abs","onDragEnd","hasFocus","bindFocusEvents","eventHandlers","onMouseDown","onTouchStart","onMouseUp","onTouchEnd","onMouseEnter","onMouseLeave","CloseButton","ariaLabel","_ref$ariaLabel","stopPropagation","viewBox","fillRule","ProgressBar","hide","userStyle","controlledProgress","_extends","animationDuration","animationPlayState","defaultClassName","cx","_cx","animationEvent","_animationEvent","assign","defaultProps","Svg","rest","_excluded$1","width","fill","Icons","info","warning","success","spinner","Toast","_useToast","Transition","cssClasses","isProgressControlled","maybeIcon","iconProps","Icon","_cx2","renderCloseButton","Bounce","ToastContainer","_useToastContainer","getClassName","containerStyle","pointerEvents","latestInstance","containerDomNode","containerConfig","containers","lazy","generateToastId","random","getToastId","dispatchToast","size","body","render","mergeOptions","createToastByType","loading","pending","resetParams","resolver","input","params","update","warn","dark","dismiss","isActive","container","oldOptions","oldContent","nextOptions","onChange","configure","config","containerInstance","item","_defineProperty","configurable","writable","initialState","isDirty","useDataStateReducer","initializer","ticketId","newState","existingTicket","ticket","uuid","R","isModified","Boolean","isDefault","includes","useDataStateManager","useInitialState","dataReducer","useDataReducer","_useReducer","_slicedToArray","getData","addTicket","updateTicket","isNew","reset","useFilterStateManager","_datesByMonth$split$m","Number","_datesByMonth$split$m2","baseIsNative","getValue","required","TypeError","baseHas","hasPath","withClassName","g","xmlns","assetsUrl","baristaAssetsUrl","_window","_window$eventEspresso","eventEspressoData","_window$eventEspresso2","_window$eventEspresso3","coreDomain","distributionAssetsUrl","__webpack_public_path__","IconName","getSubscriptions","ModalSubscription","domain","registry","ModalRegistry","AddSingleDate","isOnlyButton","open","useGlobalModal","EdtrGlobalModals","EDIT_DATE","output","additionalProps","hooks","applyFilters","EMPTY_OBJECT","Button","buttonText","buttonType","Calendar","NewEntityOption","description","title","OptionsModalButton","openWithData","NEW_DATE","mr","NewDateButton","NewDateOptions","fills","NewDateModal","_useGlobalModal","isOpen","close","NewEntityModal","withCurrentUserCan","USE_ADVANCED_EDITOR","TAM","useTickets","isDisabled","tooltip","ButtonRow","Ticket","DatesListFooter","entities","EntityCacheIds","DatesListButtons","legendConfig","icons","EDIT","GROUPS","TICKET","Trash","swatches","DTA","DTT","DTE","DTS","DTU","CardView","RenderCardView","Suspense","fallback","LoadingNotice","TableView","RenderTableView","displayStartOrEndDateOptions","_displayStartOrEndDat","DisplayStartOrEndDate","end","both","salesOptions","_salesOptions","DatetimeSales","above90Capacity","above75Capacity","above50Capacity","below50Capacity","statusOptions","_statusOptions","DatetimeStatus","activeUpcoming","activeOnly","upcomingOnly","nextActiveUpcomingOnly","soldOutOnly","recentlyExpiredOnly","expiredOnly","trashedOnly","sortByOptions","order","labels","displayStartOrEndDate","recurrence","sales","sortBy","search","status","ActiveDatesFilters","_useDatesListFilterSt","useDatesListFilterState","setStatus","setSales","searchText","setSearchText","setRecurrence","statusTitle","salesTitle","searchTitle","recurrenceTitle","onRemoveStatus","onRemoveSales","onRemoveRecurrence","onRemoveSearch","ActiveFilters","FilterTag","onRemove","objectToSelectOptions","DisplayStartOrEndDateControl","setDisplayStartOrEndDate","SalesControl","StatusControl","formatTokens","DraggableDatetime","dbId","endDate","startDate","RangeFormat","showTime","renderDraggableItem","datetime","SortByControl","setSortBy","filteredDateIds","useFilteredDateIds","_useReorderDatetimes","useReorderDatetimes","draggableItems","allReorderedEntities","sortResponder","updateEntityList","SortByControlUI","droppableId","datetimesDroppableId","entityType","TypeName","onSort","onSubmit","withEntityListContext","Provider","DatetimesListProvider","filterState","renderList","view","EntityList","activeFilters","footer","headerText","listId","datesList","loadingText","ActiveStatus","onStatusChange","datetimeStatusBgColorClassName","datetimeStatus","fitContainer","flow","labelClassName","labelPosition","noBorderColor","wrapperClassName","AltRegPage","altRegPage","onAltRegPageChange","InlineEditTextWithLabel","placeholder","DefaultRegistrationStatus","_regStatusCode$","defaultRegStatus","onDefaultRegStatusChange","regStatusCode","regStatusOptions","option","Donations","allowDonations","onDonationsChange","debounceDelay","EventManager","eventManagers","managerId","onManagerChange","entityListToSelectOptions","EventPhoneNumber","onPhoneNumberChange","phoneNumber","MaxRegistrations","maxReg","onMaxRegChange","strValue","String","TicketSelector","displayTicketSelector","onTicketSelectorChange","withData","WrappedComponent","_event$manager2","_event$manager3","useEvent","useEventManagers","updateEvent","useEventMutator","updateEntity","newAltRegPage","newManagerId","_event$manager","manager","newMaxRegistrations","maxRegistrations","newPhoneNumber","withFeature","_ref$onAltRegPageChan","noop","_ref$onMaxRegChange","Grid","maxColumns","GridCard","header","useNewTicketOptionItems","useNewEntityOptionItems","border","OptionsModal","NewTicketButton","optionItems","AddSingleTicket","EDIT_TICKET","noVerticalMargin","toggleProps","noPadding","DEFAULT_TICKETS","canReadDefaultTickets","useCurrentUserCan","currentUserCan","DropdownMenu","noZindex","DropdownMenuItem","TicketsListFooter","Actions","CALENDAR","CALCULATOR","TKA","TKE","TKO","TKS","TKP","TicketsSales","above90Sold","above75Sold","above50Sold","below50Sold","salesIsChainedOptions","TicketsStatus","onSaleAndPending","onSaleOnly","pendingOnly","nextOnSaleOrPendingOnly","statusIsChainedOptions","isChained","ActiveTicketsSFilters","_useTicketsListFilter","useTicketsListFilterState","toggleIsChained","isChainedTitle","useMemoStringify","DraggableTicket","price","CurrencyDisplay","filteredTicketIds","useFilteredTicketIds","_useReorderTickets","useReorderTickets","ticketDroppableId","IsChainedButton","Link","Unlink","IconButton","showTooltipOnMobile","EnhancedTicketsList","TicketsListProvider","ActiveTicketsFilters","ticketsList","ChainedTicketsList","useRegisterIsChainedFilter","onChangeDescription","newDescription","_document$getElementB","getElementById","remove","Heading","as","AdvancedTextEditor","defaultValue","useVenueLink","venueDbId","siteUrl","useConfig","adminUrl","getAdminUrl","adminSiteUrl","admin","page","ADMIN_ROUTES","VENUES","addQueryArgs","post","return","VenueDetails","venue","selectedVenueId","setSelectedVenueId","venues","useVenues","sortedVenues","collator","Intl","Collator","numeric","sensitivity","sort","a","b","compare","selectedVenue","findEntityByGuid","createVenueLink","editVenueLink","capacity","venueCapacity","isInfinite","sprintf","onChangeInstantValue","newValue","thumbnail","addressLabels","inline","Container","Image","alt","shortDescription","MapMarker","Address","VenueSeat","Phone","phone","TextLink","showExternalIcon","VenueSelector","venueName","APPLIES_TO_OPTIONS","MAPS_TO_OPTIONS","hasTypeAsText","hasMapsToAsFName","hasTypeAsTextAndMapsToAsFName","hasAnElementAsAttendeeFName","hasTypeAsEmail","hasMapsToAsEmail","hasTypeAsEmailAndMapsToAsEmail","hasAnElementAsAttendeeEmail","ErrorMessage","elements","sections","formSectionIds","getGuids","isNotSharedOrDefault","formElements","hasFirstName","hasEmail","Banner","_getEdtrDomData","getEdtrDomData","topLevelSectionId","FormBuilder","appliesToOptions","containerClassName","initialElements","initialSections","mapsToOptions","topBanner","log","useNotifications","isLoaded","useStatus","_useIsRehydrated","useIsRehydrated","isRehydrated","readyTypes","types","isDev","dev","Notifications","toaster","useSystemNotifications","toasts","initToaster","validate","yupToFinalFormErrors","validationSchema","abrupt","sent","_x","yup","datesSchema","FIELD_NAMES","decorators","startAndEndDateFixer","adjacentFormItemProps","useDateFormConfig","useDatetimeItem","toUtcISO","useSiteDateToUtcISO","toSiteDate","useUtcISOToSiteDate","setDefaultTime","PLUS_ONE_MONTH","onSubmitFrom","form","restParams","_args","_objectWithoutProperties","_x2","initialValues","ProfileOutlined","fields","fieldType","CalendarOutlined","formControlProps","wrapper","EndDateFieldWrapper","ControlOutlined","parseAsInfinity","min","subscription","layout","DatetimeFormSteps","Steps","showStepNumber","Step","useDataListener","useTAMDataState","_useForm","useForm","mutators","getState","_data$datetimes","_data$datetimes$id","updateFieldValue","_ref$asAlert","asAlert","dataState","hasOrphanDates","hasOrphanTickets","getRelationIcon","CloseOutlined","MinusOutlined","BodyCell","_useDataState","getAssignmentStatus","toggleAssignment","datetimeId","entityLabel","entity","nameOrId","ticketLabel","datetimeLabel","variant","DateCell","bgClassName","getDatetimeBackgroundColorClassName","stripeClassName","format","useTimeZoneTime","formatForSite","LOCALIZED_DATE_SHORT_FORMAT","useRowClassName","hasNoAssignedTickets","useColClassName","hasNoAssignedDates","useGetBodyRows","getRowClass","getColClass","datetimeCell","cells","statusClassName","toLowerCase","textAlign","bodyRowClassName","rowClassName","primary","FORMAT","HeaderCell","getTicketBackgroundColorClassName","startDateClassName","emptyCell","useGetHeaderRows","metaData","isScrollable","tableId","tableCaption","tableClassName","Table","bodyRows","headerRows","ResponsiveTable","Debug","DebugInfo","TicketAssignmentsManager","datesAndTickets","useDatesAndTickets","useSubmitButtonProps","onSubmitData","hasOrphanEntities","isSubmitting","setIsSubmitting","hasErrors","ButtonType","PRIMARY","SaveOutlined","TicketAssignmentsManagerModal","onCloseModal","submitButtonProps","ariaAttributes","modalContent","ModalWithAlert","isSubmitDisabled","onCancel","showAlertOnClose","CollapsibleLegend","direction","useInvalidDataAlert","showAlert","useRelations","validateData","setValidateData","defaultTicketIds","useDefaultTicketIds","newData","_i","_entries","entries","TAM_ENTITIES","entityRelations","_i2","_Object$entries","relations","tamRelations","flat","ModalContainer","submitAssignments","useOnSubmitAssignments","reOpenTamModal","_useConfirmationDialo","useConfirmationDialog","onConfirm","confirmationDialog","_getData","wait","TAMStep","ModalBody","steps","DateFormSteps","withFormSubscription","submitting","Next","Previous","Submit","submit","Modal","usePrevNext","isPristine","useIsPristine","footerButtons","FooterButtons","EntityEditModal","footerContent","useFormValues","TAMContextProvider","Content","entityId","formConfig","useDatetimeFormConfig","FormWithConfig","formWrapper","useOnSubmit","_useDatetimeMutator","useDatetimeMutator","createEntity","_useUpdateTicketQtyBy","useUpdateTicketQtyByCapacity","createBulkQtyUpdateInput","doQtyBulkUpdate","dates","capacityChanged","_result$data","_result$data$createEs","_result$data$createEs2","getHighestOrder","createEspressoDatetime","espressoDatetime","closeEditDateModal","setData","closeNewDateModal","useActions","eventId","useEventId","getRelations","relation","copyDate","newDatetime","trashed","isTrashed","deleteRelatedTickets","useDeleteRelatedTickets","trashDate","DeleteDatetime","_useActions","isTheOnlyDate","total","trashDateTitle","cannotBeDeleted","addIconBG","alertType","AlertType","ACCENT","TrashIcon","yesButtonText","TrashEntity","DateMainMenu","onOpenEditModal","EditEntity","CopyEntity","AssignTicketsButton","count","useRelatedTickets","getRelatedTickets","ItemCount","zeroCountChar","borderless","withIsLoaded","loaded","subscribe","registerContainer","EditDateContainer","EntityActionsSubscription","registerMenuItem","registerElement","FilterBarUISubscription","registerFilterBarItem","FilterBarFilter","registerPlugin","EdtrSlots","ADD_SINGLE_DATE_OPTION","NewDateOption","_ref4","useDeleteTicketHandler","getTicketPrices","useTicketPrices","priceQueryOptions","usePriceQueryOptions","client","useApolloClient","deleteRelatedPrices","_data$espressoPrices","pricesToDelete","isTax","priceIdsToDelete","readQuery","pricesToRetain","entitiesWithGuIdNotInArray","espressoPrices","nodes","writeQuery","catch","DeleteTicket","isTicketTrashed","onConfirmDelete","confirmDelete","_useLockedTicketActio","useLockedTicketAction","alertContainer","isTheOnlyTicket","deleteTicketTitle","onDelete","isLocked","TicketMainMenu","useTicketItem","copyTicket","useCopyTicket","useTicketFormConfig","NOW","priceToTpcModifier","usePriceToTpcModifier","prices","preparePricesForTpc","visibility","publicFields","advancedFields","VISIBILITY_OPTIONS_INFO","VISIBILITY_OPTIONS","ticketDetailsFields","TicketFormSteps","Calculator","TPCStep","useSyncTPC2RFF","TicketPriceCalculator","context","_data$tickets","_data$tickets$id","goto","gotoDetails","gotoTAM","isTPCSubmitDisabled","hasEmptyPrices","SECONDARY","skipsSteps","getTheTicketPrices","getTicket","TPCContextProvider","getCappedQuantity","useCappedQuantity","quantity","relatedDateIds","closeModal","TicketCard","onEdit","renderStartDate","LOCALIZED_DATE_AND_TIME_SHORT_FORMAT","renderEndDate","showAfterDetails","deleteButtonProps","editButtonProps","SimpleTicketCard","newConfig","useMainTicketFormConfig","_props$form$getState$","_tickets$ticketId","_tickets$id","withTPCContext","ContentRenderer","templates","prepTemplatePrices","usePrepTemplatePrices","addEntity","ticketPrices","SimpleEntityList","EntityRenderer","submitForm","AssignDatesButton","useRelatedDatetimes","emphasizeZero","EditTicketContainer","DefaultTicketContainer","TPC","TPCModalContainer","TicketPriceCalculatorButton","NewEntitySubscription","registerOptionItem","totalCount","_ref5","_FilterBarService","FilterBarService","registerDatesFilter","registerFilter","registerDatesSearch","registerSearch","registerDatesSorter","registerSorter","entityList","dateSalesFilter","dateStatusFilter","entityListSearch","searchFields","sortDates","registerTicketsFilter","registerTicketsSearch","registerTicketsSorter","ticketSalesFilter","ticketStatusFilter","sortTickets","generateElements","subscriptions","getRegisteredContainers","EventEditor","useEditorInitialization","EventDescription","EventRegistrationOptions","DatesList","TicketsList","RegistrationForm","PluginArea","Spinner","Editor","ContextProviders","renderDomElement","appendToTarget","domElementToRender","containerID","targetElementID","runtime","Op","$Symbol","iteratorSymbol","asyncIteratorSymbol","asyncIterator","toStringTagSymbol","define","innerFn","outerFn","tryLocsList","protoGenerator","Generator","generator","_invoke","GenStateSuspendedStart","method","GenStateExecuting","GenStateCompleted","doneResult","delegate","delegateResult","maybeInvokeDelegate","ContinueSentinel","_sent","dispatchException","record","tryCatch","GenStateSuspendedYield","makeInvokeMethod","fn","GeneratorFunction","GeneratorFunctionPrototype","IteratorPrototype","getProto","getPrototypeOf","NativeIteratorPrototype","Gp","defineIteratorMethods","AsyncIterator","PromiseImpl","invoke","__await","unwrapped","previousPromise","callInvokeWithMethodAndArg","resultName","nextLoc","pushTryEntry","locs","entry","tryLoc","catchLoc","finallyLoc","afterLoc","tryEntries","resetTryEntry","completion","iterable","iteratorMethod","displayName","isGeneratorFunction","genFun","ctor","setPrototypeOf","__proto__","awrap","async","pop","skipTempReset","rootRecord","rval","exception","handle","loc","caught","hasCatch","hasFinally","finallyEntry","complete","finish","thrown","delegateYield","regeneratorRuntime","accidentalStrictMode","ownKeys","enumerableOnly","getOwnPropertySymbols","symbols","sym","getOwnPropertyDescriptor","_objectSpread2","source","getOwnPropertyDescriptors","defineProperties","getRawTag","objectToString","symToStringTag","baseToString","svgName","WrappedIcon","noMargin","_","Set","baseClone","circulars","clones","nodeType","cloneNode","clone","from","findIndex","errorToString","regExpToString","symbolToString","SYMBOL_REGEXP","printNumber","val","printSimpleValue","quoteStrings","typeOf","toISOString","printValue","JSON","stringify","mixed","oneOf","notOneOf","notType","originalValue","isCast","msg","defined","string","matches","email","url","trim","lowercase","uppercase","number","lessThan","moreThan","positive","negative","integer","boolean","isValue","noUnknown","isSchema","__isYupSchema__","Condition","refs","_classCallCheck","otherwise","is","check","every","_len2","_key2","schema","branch","_createClass","base","parent","toArray","strReg","ValidationError","_Error","_inherits","_super","_createSuper","errorOrErrors","field","errors","_this$errors","isError","captureStackTrace","_assertThisInitialized","_wrapNativeSuper","runTests","endEarly","tests","fired","once","nestedErrors","prefixes","Reference","isContext","isSibling","prefix","__isYupRef","createValidation","_ref$path","sync","excluded","sourceKeys","Ref","isRef","createError","overrides","nextParams","mapValues","formatError","ctx","validOrError","OPTIONS","getIn","lastPart","lastPartDebug","_part","innerType","_type","parentPath","ReferenceSet","_step","_iterator","_createForOfIteratorHelper","f","_step2","_iterator2","describe","acc","add","delete","newItems","removeItems","BaseSchema","deps","transforms","conditions","_mutate","_typeError","_whitelist","_blacklist","exclusiveTests","spec","withMutation","typeError","locale","strip","strict","abortEarly","recursive","nullable","presence","_value","_whitelistError","_blacklistError","cloneDeep","meta","before","combined","mergedSpec","merge","_typeCheck","condition","resolvedSchema","_cast","assert","isType","formattedValue","formattedResult","rawValue","_options","_this2","getDefault","_this3","_options$from","_options$originalValu","_options$strict","_options$abortEarly","initialTests","finalTests","maybeCb","_validate","validateSync","_getDefault","def","isStrict","exclusive","_isPresent","isNullable","opts","isExclusive","dep","enums","valids","resolved","resolveAll","invalids","_next$spec","_loop","_arr","_getIn","_arr2","alias","_i3","_arr3","optional","notRequired","Mixed","isAbsent","BooleanSchema","_BaseSchema","valueOf","rEmail","rUrl","rUUID","isTrimmed","objStringTag","StringSchema","_get","_getPrototypeOf","excludeEmptyString","_options$excludeEmpty","toUpperCase","NumberSchema","parsed","less","more","isInteger","_method","avail","truncate","isoReg","invalidDate","DateSchema","struct","numericKeys","minutesOffset","UTC","parse","isoParse","param","cast","prepareParam","INVALID_DATE","sortFields","excludedEdges","edges","excludes","addNode","depPath","toposort","arr","Infinity","some","ii","_err$path","sortByKeyOrder","isObject","unknown","known","defaultSort","ObjectSchema","_sortErrors","_nodes","_excludedEdges","shape","_options$stripUnknown","stripUnknown","intermediateValue","innerOptions","__validating","isChanged","prop","exists","fieldValue","inputValue","fieldSpec","_opts$from","_opts$originalValue","_opts$abortEarly","_opts$recursive","_this4","nextFields","_Object$entries$_i","schemaOrRef","_this5","dft","getDefaultFromShape","additions","picked","_step3","_iterator3","to","fromGetter","newObj","noAllow","unknownKeys","allow","mapKeys","transformKeys","camelCase","snakeCase","ArraySchema","_opts","castArray","castElement","_options$recursive","original","rejector","nativeCreate","getNative","listCacheClear","listCacheDelete","listCacheGet","listCacheHas","listCacheSet","ListCache","eq","isKeyable","__data__","isSymbol","baseAssignValue","baseForOwn","baseIteratee","iteratee","Parent","Class","isNativeReflectConstruct","_cache","Wrapper","createContext","Consumer","DataStateProvider","FilterStateProvider","webpackPolyfill","deprecate","paths","reIsDeepProp","reIsPlainProp","baseGetTag","isObjectLike","mapCacheClear","mapCacheDelete","mapCacheGet","mapCacheHas","mapCacheSet","MapCache","arrayLikeKeys","baseKeys","isArrayLike","arrayLikeToArray","iterableToArray","unsupportedIterableToArray","createCompounder","word","dirtyNumber","ceil","floor","Constructor","castPath","isArguments","isIndex","isLength","toKey","hasFunc","isKey","stringToPath","global","_arrayLikeToArray","arr2","funcToString","func","other","baseIsArguments","objectProto","propertyIsEnumerable","reIsUint","baseFor","stubFalse","freeExports","freeModule","Buffer","isBuffer","baseIsTypedArray","baseUnary","nodeUtil","nodeIsTypedArray","isTypedArray","baseMatches","baseMatchesProperty","identity","stackClear","stackDelete","stackGet","stackHas","stackSet","Stack","baseIsEqualDeep","baseIsEqual","bitmask","customizer","stack","SetCache","arraySome","cacheHas","equalFunc","isPartial","arrLength","othLength","arrStacked","othStacked","seen","arrValue","othValue","compared","othIndex","srcValue","arrayReduce","deburr","words","reApos","reHasUnicode","_unsupportedIterableToArray","minLen","asyncGeneratorStep","gen","_next","_throw","capitalize","cursor","sorted","visited","outgoingEdges","edge","makeOutgoingEdges","nodesHash","res","makeNodesHash","visit","predecessors","nodeRep","outgoing","child","uniqueNodes","prepareEntitiesForUpdate","existingData","existingEntities","newEntities","possibleRelation","newRelatedEntities","oldRelatedEntities","ticketsWithNewQuantity","allDates","allTickets","ticketsToUpdate","ticketIdToQuantityMap","idToPropMap","getMinDateCapacity","minDateCapacity","_existingData$tickets","_existingData$tickets2","_ref6","existingRelatedDateIds","newOnlyRelatedDateIds","dateId","minimumCapacity","nonNegativeTicketQuantity","parseInfinity","yearWiseMonths","_ref7","parsedDate","getFullYear","getMonth","monthsInTheYear","getMonthName","getYearWiseMonthsFromDates","_ref8","_ref9","months","_ref10","_ref11","monthNumber","monthName","useEventsHandler","useCacheRehydration","EntityCardDetailsSubscription","useEntityCardDetailsItems","filterByEntityType","EntityCardDetailsRegistry","NewEntityOptionsRegistry","_defineProperties","descriptor","protoProps","staticProps","subClass","superClass","_possibleConstructorReturn","assertThisInitialized","Derived","hasNativeReflectConstruct","Super","NewTarget","filterstate","defaultTickets","useDefaultTickets","convertPriceToTpcModifier","normalizedTickets","unSortedPrices","idToEntityMap","_arrayWithHoles","_nonIterableRest","receiver","desc","argIndex","framesToPop","nativeObjectToString","isOwn","unmasked","memoizeCapped","rePropName","reEscapeChar","charCodeAt","quote","subString","memoize","cache","memoized","Hash","hashClear","hashDelete","hashGet","hashHas","hashSet","isFunction","isMasked","toSource","reIsHostCtor","funcProto","reIsNative","coreJsData","maskSrcKey","uid","IE_PROTO","assocIndexOf","splice","getMapData","propIsEnumerable","toObject","test1","getOwnPropertyNames","test2","fromCharCode","test3","letter","shouldUseNative","arrayMap","symbolProto","createBaseFor","fromRight","keysFunc","baseTimes","inherited","isArr","isArg","isBuff","skipIndexes","typedArrayTags","freeProcess","process","binding","isPrototype","nativeKeys","Ctor","overArg","baseIsMatch","getMatchData","matchesStrictComparable","matchData","noCustomizer","objValue","COMPARE_PARTIAL_FLAG","_iterableToArray","pairs","LARGE_ARRAY_SIZE","equalArrays","equalByTag","equalObjects","getTag","argsTag","arrayTag","objectTag","objIsArr","othIsArr","objTag","othTag","objIsObj","othIsObj","isSameTag","objIsWrapped","othIsWrapped","objUnwrapped","othUnwrapped","setCacheAdd","setCacheHas","predicate","Uint8Array","mapToArray","setToArray","symbolValueOf","byteLength","byteOffset","buffer","convert","stacked","getAllKeys","objProps","objLength","objStacked","skipCtor","objCtor","othCtor","baseGetAllKeys","getSymbols","arrayPush","symbolsFunc","arrayFilter","stubArray","nativeGetSymbols","symbol","resIndex","DataView","WeakMap","mapTag","promiseTag","setTag","weakMapTag","dataViewTag","dataViewCtorString","mapCtorString","promiseCtorString","setCtorString","weakMapCtorString","ArrayBuffer","ctorString","isStrictComparable","hasIn","baseGet","baseHasIn","baseProperty","basePropertyDeep","accumulator","initAccum","deburrLetter","reLatin","reComboMark","basePropertyOf","asciiWords","hasUnicodeWord","unicodeWords","pattern","guard","reAsciiWord","reHasUnicodeWord","rsDingbatRange","rsLowerRange","rsUpperRange","rsBreakRange","rsMathOpRange","rsBreak","rsDigits","rsDingbat","rsLower","rsMisc","rsRegional","rsSurrPair","rsUpper","rsMiscLower","rsMiscUpper","rsOptContrLower","rsOptContrUpper","reOptMod","rsModifier","rsOptVar","rsSeq","rsEmoji","reUnicodeWord","upperFirst","createCaseFirst","castSlice","hasUnicode","stringToArray","methodName","strSymbols","chr","trailing","baseSlice","asciiToArray","unicodeToArray","rsAstral","rsCombo","rsFitz","rsNonAstral","rsSymbol","reUnicode","for","h","__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED","ReactCurrentOwner","__self","__source","q","$$typeof","_owner","jsx","jsxs","sourceSymbolKeys","allowArrayLike","it","F","_e","normalCompletion","didErr","step","_e2","useEntityActionsMenuItems","EntityActionsMenuRegistry","ReferenceError","useAssignmentManager","_useRelationsManager","useRelationsManager","addRelation","initializeRelations","initialize","isInitialized","removeRelation","setIsDirty","getAssignedTickets","getAssignedDates","updateAssignment","_ref3$remove","datetimeToTickets","relationId","ticketsToDatetimes","addAssignment","removeAssignment","removeNonTAMRelations","relationalEntity","relationalEntityToUse","newRelationKey","_props$entity2","initialDataIsValid","setInitialDataIsValid","assignmentManager","orphanEntities","useValidation","initialized","hasOrphanEntitiesOfType","_orphanEntities$entit2","_orphanEntities$entit","_props$entity","getOldRelation","oldRelatedTickets","newRelatedTickets","isInOld","isInNew","_orphanEntities$datet","_orphanEntities$ticke","hasOrphans","useFilteredDatetimes","datesInYearAndMonth","inYearAndMonth","notTrashed","useFilteredTickets","isExpired","_useTAMContext","filteredDatetimes","filteredTickets","getExistingData","bulkEditTickets","useBulkEditTickets","updateEntities","ticketsWithChangedQuantity","uniqueInputs","entityHasGuid","DEFAULT_VALIDATION_DATA","validationData","setValidationData","TAMData","newTAMData","emptyRelationalEntities","arrayWithHoles","_n","_d","_s","nonIterableRest","_setPrototypeOf"],"mappings":";qFACE,SAASA,EAAqBC,GAQ7B,IAPA,IAMIC,EAAUC,EANVC,EAAWH,EAAK,GAChBI,EAAcJ,EAAK,GAKAK,EAAI,EAAGC,EAAW,GACpCD,EAAIF,EAASI,OAAQF,IACzBH,EAAUC,EAASE,GAChBG,OAAOC,UAAUC,eAAeC,KAAKC,EAAiBV,IAAYU,EAAgBV,IACpFI,EAASO,KAAKD,EAAgBV,GAAS,IAExCU,EAAgBV,GAAW,EAE5B,IAAID,KAAYG,EACZI,OAAOC,UAAUC,eAAeC,KAAKP,EAAaH,KACpDa,EAAQb,GAAYG,EAAYH,IAKlC,IAFGc,GAAqBA,EAAoBf,GAEtCM,EAASC,QACdD,EAASU,OAATV,GAOF,IAAIW,EAAmB,GAGnBC,EAAqB,CACxB,EAAG,GAMAN,EAAkB,CACrB,EAAG,GAWJ,SAASO,EAAoBlB,GAG5B,GAAGgB,EAAiBhB,GACnB,OAAOgB,EAAiBhB,GAAUmB,QAGnC,IAAIC,EAASJ,EAAiBhB,GAAY,CACzCI,EAAGJ,EACHqB,GAAG,EACHF,QAAS,IAUV,OANAN,EAAQb,GAAUU,KAAKU,EAAOD,QAASC,EAAQA,EAAOD,QAASD,GAG/DE,EAAOC,GAAI,EAGJD,EAAOD,QAKfD,EAAoBI,EAAI,SAAuBrB,GAC9C,IAAIsB,EAAW,GAKZN,EAAmBhB,GAAUsB,EAASX,KAAKK,EAAmBhB,IACzB,IAAhCgB,EAAmBhB,IAFX,CAAC,EAAI,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K7uD,KAAK+zE,EAAGrvE,QAETlF,GAAKqvD,EAAKnvD,SAAWF,GAH8Cq0E,GAAK,IAK9E,MAAO1xE,GACP2xE,GAAK,EACLzE,EAAKltE,EACL,QACA,IACO0xE,GAAsB,MAAhB1nC,EAAW,QAAWA,EAAW,SAC5C,QACA,GAAI2nC,EAAI,MAAMzE,GAIlB,OAAOxgB,GDnBuB,CAAqBoD,EAAKzyD,IAAM,OAAA84D,EAAA,GAA2BrG,EAAKzyD,IAAM,OAAAw0E,EAAA,O,gCELvF,SAASC,EAAgB9vE,EAAGlD,GAMzC,OALAgzE,EAAkBt0E,OAAO6gD,gBAAkB,SAAyBr8C,EAAGlD,GAErE,OADAkD,EAAEs8C,UAAYx/C,EACPkD,IAGcA,EAAGlD,GAN5B","file":"static/js/eventEditor.5414d673.js","sourcesContent":[" \t// install a JSONP callback for chunk loading\n \tfunction webpackJsonpCallback(data) {\n \t\tvar chunkIds = data[0];\n \t\tvar moreModules = data[1];\n\n\n \t\t// add \"moreModules\" to the modules object,\n \t\t// then flag all \"chunkIds\" as loaded and fire callback\n \t\tvar moduleId, chunkId, i = 0, resolves = [];\n \t\tfor(;i < chunkIds.length; i++) {\n \t\t\tchunkId = chunkIds[i];\n \t\t\tif(Object.prototype.hasOwnProperty.call(installedChunks, chunkId) && installedChunks[chunkId]) {\n \t\t\t\tresolves.push(installedChunks[chunkId][0]);\n \t\t\t}\n \t\t\tinstalledChunks[chunkId] = 0;\n \t\t}\n \t\tfor(moduleId in moreModules) {\n \t\t\tif(Object.prototype.hasOwnProperty.call(moreModules, moduleId)) {\n \t\t\t\tmodules[moduleId] = moreModules[moduleId];\n \t\t\t}\n \t\t}\n \t\tif(parentJsonpFunction) parentJsonpFunction(data);\n\n \t\twhile(resolves.length) {\n \t\t\tresolves.shift()();\n \t\t}\n\n \t};\n\n\n \t// The module cache\n \tvar installedModules = {};\n\n \t// object to store loaded CSS chunks\n \tvar installedCssChunks = {\n \t\t9: 0\n \t};\n\n \t// object to store loaded and loading chunks\n \t// undefined = chunk not loaded, null = chunk preloaded/prefetched\n \t// Promise = chunk loading, 0 = chunk loaded\n \tvar installedChunks = {\n \t\t9: 0\n \t};\n\n\n\n \t// script path function\n \tfunction jsonpScriptSrc(chunkId) {\n \t\treturn __webpack_require__.p + \"static/js/\" + ({\"5\":\"dates-card-view\",\"6\":\"dates-table-view\",\"25\":\"tickets-card-view\",\"26\":\"tickets-table-view\"}[chunkId]||chunkId) + \".\" + {\"5\":\"3ec62a13\",\"6\":\"6e63357c\",\"25\":\"d8616a37\",\"26\":\"c7a37c69\"}[chunkId] + \".chunk.js\"\n \t}\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n \t// This file contains only the entry chunk.\n \t// The chunk loading function for additional chunks\n \t__webpack_require__.e = function requireEnsure(chunkId) {\n \t\tvar promises = [];\n\n\n \t\t// mini-css-extract-plugin CSS loading\n \t\tvar cssChunks = {\"6\":1,\"25\":1,\"26\":1};\n \t\tif(installedCssChunks[chunkId]) promises.push(installedCssChunks[chunkId]);\n \t\telse if(installedCssChunks[chunkId] !== 0 && cssChunks[chunkId]) {\n \t\t\tpromises.push(installedCssChunks[chunkId] = new Promise(function(resolve, reject) {\n \t\t\t\tvar href = \"static/css/\" + ({\"5\":\"dates-card-view\",\"6\":\"dates-table-view\",\"25\":\"tickets-card-view\",\"26\":\"tickets-table-view\"}[chunkId]||chunkId) + \".\" + {\"5\":\"31d6cfe0\",\"6\":\"fc6705f5\",\"25\":\"7d56f661\",\"26\":\"7d56f661\"}[chunkId] + \".chunk.css\";\n \t\t\t\tvar fullhref = __webpack_require__.p + href;\n \t\t\t\tvar existingLinkTags = document.getElementsByTagName(\"link\");\n \t\t\t\tfor(var i = 0; i < existingLinkTags.length; i++) {\n \t\t\t\t\tvar tag = existingLinkTags[i];\n \t\t\t\t\tvar dataHref = tag.getAttribute(\"data-href\") || tag.getAttribute(\"href\");\n \t\t\t\t\tif(tag.rel === \"stylesheet\" && (dataHref === href || dataHref === fullhref)) return resolve();\n \t\t\t\t}\n \t\t\t\tvar existingStyleTags = document.getElementsByTagName(\"style\");\n \t\t\t\tfor(var i = 0; i < existingStyleTags.length; i++) {\n \t\t\t\t\tvar tag = existingStyleTags[i];\n \t\t\t\t\tvar dataHref = tag.getAttribute(\"data-href\");\n \t\t\t\t\tif(dataHref === href || dataHref === fullhref) return resolve();\n \t\t\t\t}\n \t\t\t\tvar linkTag = document.createElement(\"link\");\n\n \t\t\t\tlinkTag.rel = \"stylesheet\";\n \t\t\t\tlinkTag.type = \"text/css\";\n \t\t\t\tvar onLinkComplete = function (event) {\n \t\t\t\t\t// avoid mem leaks.\n \t\t\t\t\tlinkTag.onerror = linkTag.onload = null;\n \t\t\t\t\tif (event.type === 'load') {\n \t\t\t\t\t\tresolve();\n \t\t\t\t\t} else {\n \t\t\t\t\t\tvar errorType = event && (event.type === 'load' ? 'missing' : event.type);\n \t\t\t\t\t\tvar realHref = event && event.target && event.target.href || fullhref;\n \t\t\t\t\t\tvar err = new Error(\"Loading CSS chunk \" + chunkId + \" failed.\\n(\" + realHref + \")\");\n \t\t\t\t\t\terr.code = \"CSS_CHUNK_LOAD_FAILED\";\n \t\t\t\t\t\terr.type = errorType;\n \t\t\t\t\t\terr.request = realHref;\n \t\t\t\t\t\tdelete installedCssChunks[chunkId]\n \t\t\t\t\t\tlinkTag.parentNode.removeChild(linkTag)\n \t\t\t\t\t\treject(err);\n \t\t\t\t\t}\n \t\t\t\t};\n \t\t\t\tlinkTag.onerror = linkTag.onload = onLinkComplete;\n \t\t\t\tlinkTag.href = fullhref;\n\n \t\t\t\tdocument.head.appendChild(linkTag);\n \t\t\t}).then(function() {\n \t\t\t\tinstalledCssChunks[chunkId] = 0;\n \t\t\t}));\n \t\t}\n\n \t\t// JSONP chunk loading for javascript\n\n \t\tvar installedChunkData = installedChunks[chunkId];\n \t\tif(installedChunkData !== 0) { // 0 means \"already installed\".\n\n \t\t\t// a Promise means \"currently loading\".\n \t\t\tif(installedChunkData) {\n \t\t\t\tpromises.push(installedChunkData[2]);\n \t\t\t} else {\n \t\t\t\t// setup Promise in chunk cache\n \t\t\t\tvar promise = new Promise(function(resolve, reject) {\n \t\t\t\t\tinstalledChunkData = installedChunks[chunkId] = [resolve, reject];\n \t\t\t\t});\n \t\t\t\tpromises.push(installedChunkData[2] = promise);\n\n \t\t\t\t// start chunk loading\n \t\t\t\tvar script = document.createElement('script');\n \t\t\t\tvar onScriptComplete;\n\n \t\t\t\tscript.charset = 'utf-8';\n \t\t\t\tscript.timeout = 120;\n \t\t\t\tif (__webpack_require__.nc) {\n \t\t\t\t\tscript.setAttribute(\"nonce\", __webpack_require__.nc);\n \t\t\t\t}\n \t\t\t\tscript.src = jsonpScriptSrc(chunkId);\n\n \t\t\t\t// create error before stack unwound to get useful stacktrace later\n \t\t\t\tvar error = new Error();\n \t\t\t\tonScriptComplete = function (event) {\n \t\t\t\t\t// avoid mem leaks in IE.\n \t\t\t\t\tscript.onerror = script.onload = null;\n \t\t\t\t\tclearTimeout(timeout);\n \t\t\t\t\tvar chunk = installedChunks[chunkId];\n \t\t\t\t\tif(chunk !== 0) {\n \t\t\t\t\t\tif(chunk) {\n \t\t\t\t\t\t\tvar errorType = event && (event.type === 'load' ? 'missing' : event.type);\n \t\t\t\t\t\t\tvar realSrc = event && event.target && event.target.src;\n \t\t\t\t\t\t\terror.message = 'Loading chunk ' + chunkId + ' failed.\\n(' + errorType + ': ' + realSrc + ')';\n \t\t\t\t\t\t\terror.name = 'ChunkLoadError';\n \t\t\t\t\t\t\terror.type = errorType;\n \t\t\t\t\t\t\terror.request = realSrc;\n \t\t\t\t\t\t\tchunk[1](error);\n \t\t\t\t\t\t}\n \t\t\t\t\t\tinstalledChunks[chunkId] = undefined;\n \t\t\t\t\t}\n \t\t\t\t};\n \t\t\t\tvar timeout = setTimeout(function(){\n \t\t\t\t\tonScriptComplete({ type: 'timeout', target: script });\n \t\t\t\t}, 120000);\n \t\t\t\tscript.onerror = script.onload = onScriptComplete;\n \t\t\t\tdocument.head.appendChild(script);\n \t\t\t}\n \t\t}\n \t\treturn Promise.all(promises);\n \t};\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"/\";\n\n \t// on error function for async loading\n \t__webpack_require__.oe = function(err) { console.error(err); throw err; };\n\n \tvar jsonpArray = this[\"webpackJsonproot\"] = this[\"webpackJsonproot\"] || [];\n \tvar oldJsonpFunction = jsonpArray.push.bind(jsonpArray);\n \tjsonpArray.push = webpackJsonpCallback;\n \tjsonpArray = jsonpArray.slice();\n \tfor(var i = 0; i < jsonpArray.length; i++) webpackJsonpCallback(jsonpArray[i]);\n \tvar parentJsonpFunction = oldJsonpFunction;\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 1692);\n","(function() { module.exports = window[\"React\"]; }());","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-jsx-runtime.production.min.js');\n} else {\n module.exports = require('./cjs/react-jsx-runtime.development.js');\n}\n","/*!\n Copyright (c) 2018 Jed Watson.\n Licensed under the MIT License (MIT), see\n http://jedwatson.github.io/classnames\n*/\n/* global define */\n\n(function () {\n\t'use strict';\n\n\tvar hasOwn = {}.hasOwnProperty;\n\n\tfunction classNames() {\n\t\tvar classes = [];\n\n\t\tfor (var i = 0; i < arguments.length; i++) {\n\t\t\tvar arg = arguments[i];\n\t\t\tif (!arg) continue;\n\n\t\t\tvar argType = typeof arg;\n\n\t\t\tif (argType === 'string' || argType === 'number') {\n\t\t\t\tclasses.push(arg);\n\t\t\t} else if (Array.isArray(arg)) {\n\t\t\t\tif (arg.length) {\n\t\t\t\t\tvar inner = classNames.apply(null, arg);\n\t\t\t\t\tif (inner) {\n\t\t\t\t\t\tclasses.push(inner);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} else if (argType === 'object') {\n\t\t\t\tif (arg.toString === Object.prototype.toString) {\n\t\t\t\t\tfor (var key in arg) {\n\t\t\t\t\t\tif (hasOwn.call(arg, key) && arg[key]) {\n\t\t\t\t\t\t\tclasses.push(key);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tclasses.push(arg.toString());\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn classes.join(' ');\n\t}\n\n\tif (typeof module !== 'undefined' && module.exports) {\n\t\tclassNames.default = classNames;\n\t\tmodule.exports = classNames;\n\t} else if (typeof define === 'function' && typeof define.amd === 'object' && define.amd) {\n\t\t// register as 'classnames', consistent with npm package name\n\t\tdefine('classnames', [], function () {\n\t\t\treturn classNames;\n\t\t});\n\t} else {\n\t\twindow.classNames = classNames;\n\t}\n}());\n","import toInteger from \"../_lib/toInteger/index.js\";\nimport requiredArgs from \"../_lib/requiredArgs/index.js\";\nvar MILLISECONDS_IN_HOUR = 3600000;\nvar MILLISECONDS_IN_MINUTE = 60000;\nvar DEFAULT_ADDITIONAL_DIGITS = 2;\nvar patterns = {\n dateTimeDelimiter: /[T ]/,\n timeZoneDelimiter: /[Z ]/i,\n timezone: /([Z+-].*)$/\n};\nvar dateRegex = /^-?(?:(\\d{3})|(\\d{2})(?:-?(\\d{2}))?|W(\\d{2})(?:-?(\\d{1}))?|)$/;\nvar timeRegex = /^(\\d{2}(?:[.,]\\d*)?)(?::?(\\d{2}(?:[.,]\\d*)?))?(?::?(\\d{2}(?:[.,]\\d*)?))?$/;\nvar timezoneRegex = /^([+-])(\\d{2})(?::?(\\d{2}))?$/;\n/**\n * @name parseISO\n * @category Common Helpers\n * @summary Parse ISO string\n *\n * @description\n * Parse the given string in ISO 8601 format and return an instance of Date.\n *\n * Function accepts complete ISO 8601 formats as well as partial implementations.\n * ISO 8601: http://en.wikipedia.org/wiki/ISO_8601\n *\n * If the argument isn't a string, the function cannot parse the string or\n * the values are invalid, it returns Invalid Date.\n *\n * ### v2.0.0 breaking changes:\n *\n * - [Changes that are common for the whole library](https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#Common-Changes).\n *\n * - The previous `parse` implementation was renamed to `parseISO`.\n *\n * ```javascript\n * // Before v2.0.0\n * parse('2016-01-01')\n *\n * // v2.0.0 onward\n * parseISO('2016-01-01')\n * ```\n *\n * - `parseISO` now validates separate date and time values in ISO-8601 strings\n * and returns `Invalid Date` if the date is invalid.\n *\n * ```javascript\n * parseISO('2018-13-32')\n * //=> Invalid Date\n * ```\n *\n * - `parseISO` now doesn't fall back to `new Date` constructor\n * if it fails to parse a string argument. Instead, it returns `Invalid Date`.\n *\n * @param {String} argument - the value to convert\n * @param {Object} [options] - an object with options.\n * @param {0|1|2} [options.additionalDigits=2] - the additional number of digits in the extended year format\n * @returns {Date} the parsed date in the local time zone\n * @throws {TypeError} 1 argument required\n * @throws {RangeError} `options.additionalDigits` must be 0, 1 or 2\n *\n * @example\n * // Convert string '2014-02-11T11:30:30' to date:\n * var result = parseISO('2014-02-11T11:30:30')\n * //=> Tue Feb 11 2014 11:30:30\n *\n * @example\n * // Convert string '+02014101' to date,\n * // if the additional number of digits in the extended year format is 1:\n * var result = parseISO('+02014101', { additionalDigits: 1 })\n * //=> Fri Apr 11 2014 00:00:00\n */\n\nexport default function parseISO(argument, dirtyOptions) {\n requiredArgs(1, arguments);\n var options = dirtyOptions || {};\n var additionalDigits = options.additionalDigits == null ? DEFAULT_ADDITIONAL_DIGITS : toInteger(options.additionalDigits);\n\n if (additionalDigits !== 2 && additionalDigits !== 1 && additionalDigits !== 0) {\n throw new RangeError('additionalDigits must be 0, 1 or 2');\n }\n\n if (!(typeof argument === 'string' || Object.prototype.toString.call(argument) === '[object String]')) {\n return new Date(NaN);\n }\n\n var dateStrings = splitDateString(argument);\n var date;\n\n if (dateStrings.date) {\n var parseYearResult = parseYear(dateStrings.date, additionalDigits);\n date = parseDate(parseYearResult.restDateString, parseYearResult.year);\n }\n\n if (isNaN(date) || !date) {\n return new Date(NaN);\n }\n\n var timestamp = date.getTime();\n var time = 0;\n var offset;\n\n if (dateStrings.time) {\n time = parseTime(dateStrings.time);\n\n if (isNaN(time) || time === null) {\n return new Date(NaN);\n }\n }\n\n if (dateStrings.timezone) {\n offset = parseTimezone(dateStrings.timezone);\n\n if (isNaN(offset)) {\n return new Date(NaN);\n }\n } else {\n var dirtyDate = new Date(timestamp + time); // js parsed string assuming it's in UTC timezone\n // but we need it to be parsed in our timezone\n // so we use utc values to build date in our timezone.\n // Year values from 0 to 99 map to the years 1900 to 1999\n // so set year explicitly with setFullYear.\n\n var result = new Date(0);\n result.setFullYear(dirtyDate.getUTCFullYear(), dirtyDate.getUTCMonth(), dirtyDate.getUTCDate());\n result.setHours(dirtyDate.getUTCHours(), dirtyDate.getUTCMinutes(), dirtyDate.getUTCSeconds(), dirtyDate.getUTCMilliseconds());\n return result;\n }\n\n return new Date(timestamp + time + offset);\n}\n\nfunction splitDateString(dateString) {\n var dateStrings = {};\n var array = dateString.split(patterns.dateTimeDelimiter);\n var timeString; // The regex match should only return at maximum two array elements.\n // [date], [time], or [date, time].\n\n if (array.length > 2) {\n return dateStrings;\n }\n\n if (/:/.test(array[0])) {\n dateStrings.date = null;\n timeString = array[0];\n } else {\n dateStrings.date = array[0];\n timeString = array[1];\n\n if (patterns.timeZoneDelimiter.test(dateStrings.date)) {\n dateStrings.date = dateString.split(patterns.timeZoneDelimiter)[0];\n timeString = dateString.substr(dateStrings.date.length, dateString.length);\n }\n }\n\n if (timeString) {\n var token = patterns.timezone.exec(timeString);\n\n if (token) {\n dateStrings.time = timeString.replace(token[1], '');\n dateStrings.timezone = token[1];\n } else {\n dateStrings.time = timeString;\n }\n }\n\n return dateStrings;\n}\n\nfunction parseYear(dateString, additionalDigits) {\n var regex = new RegExp('^(?:(\\\\d{4}|[+-]\\\\d{' + (4 + additionalDigits) + '})|(\\\\d{2}|[+-]\\\\d{' + (2 + additionalDigits) + '})$)');\n var captures = dateString.match(regex); // Invalid ISO-formatted year\n\n if (!captures) return {\n year: null\n };\n var year = captures[1] && parseInt(captures[1]);\n var century = captures[2] && parseInt(captures[2]);\n return {\n year: century == null ? year : century * 100,\n restDateString: dateString.slice((captures[1] || captures[2]).length)\n };\n}\n\nfunction parseDate(dateString, year) {\n // Invalid ISO-formatted year\n if (year === null) return null;\n var captures = dateString.match(dateRegex); // Invalid ISO-formatted string\n\n if (!captures) return null;\n var isWeekDate = !!captures[4];\n var dayOfYear = parseDateUnit(captures[1]);\n var month = parseDateUnit(captures[2]) - 1;\n var day = parseDateUnit(captures[3]);\n var week = parseDateUnit(captures[4]);\n var dayOfWeek = parseDateUnit(captures[5]) - 1;\n\n if (isWeekDate) {\n if (!validateWeekDate(year, week, dayOfWeek)) {\n return new Date(NaN);\n }\n\n return dayOfISOWeekYear(year, week, dayOfWeek);\n } else {\n var date = new Date(0);\n\n if (!validateDate(year, month, day) || !validateDayOfYearDate(year, dayOfYear)) {\n return new Date(NaN);\n }\n\n date.setUTCFullYear(year, month, Math.max(dayOfYear, day));\n return date;\n }\n}\n\nfunction parseDateUnit(value) {\n return value ? parseInt(value) : 1;\n}\n\nfunction parseTime(timeString) {\n var captures = timeString.match(timeRegex);\n if (!captures) return null; // Invalid ISO-formatted time\n\n var hours = parseTimeUnit(captures[1]);\n var minutes = parseTimeUnit(captures[2]);\n var seconds = parseTimeUnit(captures[3]);\n\n if (!validateTime(hours, minutes, seconds)) {\n return NaN;\n }\n\n return hours * MILLISECONDS_IN_HOUR + minutes * MILLISECONDS_IN_MINUTE + seconds * 1000;\n}\n\nfunction parseTimeUnit(value) {\n return value && parseFloat(value.replace(',', '.')) || 0;\n}\n\nfunction parseTimezone(timezoneString) {\n if (timezoneString === 'Z') return 0;\n var captures = timezoneString.match(timezoneRegex);\n if (!captures) return 0;\n var sign = captures[1] === '+' ? -1 : 1;\n var hours = parseInt(captures[2]);\n var minutes = captures[3] && parseInt(captures[3]) || 0;\n\n if (!validateTimezone(hours, minutes)) {\n return NaN;\n }\n\n return sign * (hours * MILLISECONDS_IN_HOUR + minutes * MILLISECONDS_IN_MINUTE);\n}\n\nfunction dayOfISOWeekYear(isoWeekYear, week, day) {\n var date = new Date(0);\n date.setUTCFullYear(isoWeekYear, 0, 4);\n var fourthOfJanuaryDay = date.getUTCDay() || 7;\n var diff = (week - 1) * 7 + day + 1 - fourthOfJanuaryDay;\n date.setUTCDate(date.getUTCDate() + diff);\n return date;\n} // Validation functions\n// February is null to handle the leap year (using ||)\n\n\nvar daysInMonths = [31, null, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31];\n\nfunction isLeapYearIndex(year) {\n return year % 400 === 0 || year % 4 === 0 && year % 100;\n}\n\nfunction validateDate(year, month, date) {\n return month >= 0 && month <= 11 && date >= 1 && date <= (daysInMonths[month] || (isLeapYearIndex(year) ? 29 : 28));\n}\n\nfunction validateDayOfYearDate(year, dayOfYear) {\n return dayOfYear >= 1 && dayOfYear <= (isLeapYearIndex(year) ? 366 : 365);\n}\n\nfunction validateWeekDate(_year, week, day) {\n return week >= 1 && week <= 53 && day >= 0 && day <= 6;\n}\n\nfunction validateTime(hours, minutes, seconds) {\n if (hours === 24) {\n return minutes === 0 && seconds === 0;\n }\n\n return seconds >= 0 && seconds < 60 && minutes >= 0 && minutes < 60 && hours >= 0 && hours < 25;\n}\n\nfunction validateTimezone(_hours, minutes) {\n return minutes >= 0 && minutes <= 59;\n}","export default function _typeof(obj) {\n \"@babel/helpers - typeof\";\n\n if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") {\n _typeof = function _typeof(obj) {\n return typeof obj;\n };\n } else {\n _typeof = function _typeof(obj) {\n return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj;\n };\n }\n\n return _typeof(obj);\n}","export default function _isNativeReflectConstruct() {\n if (typeof Reflect === \"undefined\" || !Reflect.construct) return false;\n if (Reflect.construct.sham) return false;\n if (typeof Proxy === \"function\") return true;\n\n try {\n Date.prototype.toString.call(Reflect.construct(Date, [], function () {}));\n return true;\n } catch (e) {\n return false;\n }\n}","(function() { module.exports = window[\"eventespresso\"][\"predicates\"]; }());","var freeGlobal = require('./_freeGlobal');\n\n/** Detect free variable `self`. */\nvar freeSelf = typeof self == 'object' && self && self.Object === Object && self;\n\n/** Used as a reference to the global object. */\nvar root = freeGlobal || freeSelf || Function('return this')();\n\nmodule.exports = root;\n","import { useContext } from 'react';\nimport invariant from 'invariant';\n\nimport { FilterStateManager } from './types';\nimport { FilterStateContext } from '../../context';\n\nconst useFilterState = (): FilterStateManager => {\n\tconst value = useContext(FilterStateContext);\n\n\tinvariant(value, 'useFilterState must be used inside TAM component');\n\n\treturn value;\n};\n\nexport default useFilterState;\n","import type { AnyObject } from '@eventespresso/utils';\nimport { ContextProvider } from './ContextProvider';\nimport type { WithContextProps } from './types';\n\nconst withContext =

(\n\tComponent: React.ComponentType

,\n\tcontextProps: WithContextProps\n): React.FC

=> {\n\tconst WrappedComponent: React.FC

= (props) => {\n\t\treturn (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t);\n\t};\n\n\treturn WrappedComponent;\n};\n\nexport default withContext;\n","import { useContext } from 'react';\nimport { Context } from './ContextProvider';\nimport type { ContextProps } from './types';\nimport invariant from 'invariant';\n\nconst useTAMContext = (): ContextProps => {\n\tconst value = useContext(Context);\n\n\tinvariant(value, 'useTAMContext must be used inside TAM component');\n\n\treturn value;\n};\n\nexport default useTAMContext;\n","import { useContext } from 'react';\nimport invariant from 'invariant';\n\nimport { DataStateContext } from '../context';\nimport type { DataStateManager } from './types';\n\nconst useDataState = (): DataStateManager => {\n\tconst state = useContext(DataStateContext);\n\n\tinvariant(state, 'useDataState must be used inside DataStateProvider');\n\n\treturn state;\n};\n\nexport default useDataState;\n","import { useCallback } from 'react';\n\nimport { useTicketMutator } from '@eventespresso/edtr-services';\nimport { useMutateTicket } from '@eventespresso/tpc';\n\nimport type { DataState } from './types';\n\ntype UseSubmitForm = (dataState: DataState) => () => Promise;\n\nconst useSubmitForm: UseSubmitForm = ({ deletedTickets, tickets }) => {\n\tconst mutateTicket = useMutateTicket(true);\n\tconst { deleteEntity: deleteTicket } = useTicketMutator();\n\n\treturn useCallback(async () => {\n\t\tawait Promise.all(Object.values(tickets).map(mutateTicket));\n\n\t\tif (deletedTickets.length) {\n\t\t\tawait Promise.all(deletedTickets.map((id) => deleteTicket({ id, deletePermanently: true })));\n\t\t}\n\t}, [deleteTicket, deletedTickets, mutateTicket, tickets]);\n};\n\nexport default useSubmitForm;\n","import { useMemo } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { useDatetimes } from '@eventespresso/edtr-services';\nimport { SelectWithLabel } from '@eventespresso/ui-components';\nimport { getMonthsListFromDatetimes } from '../../utils';\nimport type { FilterStateManager } from '../filterState';\n\ntype DatesByMonthControlProps = Pick;\n\nconst DatesByMonthControl: React.FC = ({ datesByMonth, setDatesByMonth }) => {\n\tconst datetimes = useDatetimes();\n\tconst monthsList = getMonthsListFromDatetimes(datetimes);\n\n\t// e.g. \"2020:4\" for May 2020\n\tconst yearMonth = datesByMonth.join(':');\n\n\t// Add all dates option at the top, \"0:0\" to match the \"year:month\" format\n\tconst monthsListWithAllDates = useMemo(\n\t\t() => [{ value: '0:0', label: __('All Dates') }, ...monthsList],\n\t\t[monthsList]\n\t);\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default DatesByMonthControl;\n","import { __ } from '@eventespresso/i18n';\n\nimport { SwitchWithLabel } from '@eventespresso/ui-components';\nimport type { FilterStateManager } from '../filterState';\n\ntype ShowExpiredTicketsControlProps = Pick;\n\nconst ShowExpiredTicketsControl: React.FC = ({\n\tshowExpiredTickets,\n\tsetShowExpiredTickets,\n}) => {\n\treturn (\n\t\t\n\t);\n};\n\nexport default ShowExpiredTicketsControl;\n","import { __ } from '@eventespresso/i18n';\n\nimport { SwitchWithLabel } from '@eventespresso/ui-components';\nimport { FilterStateManager } from '../filterState';\n\ntype ShowTrashedDatesControlProps = Pick;\n\nconst ShowTrashedDatesControl: React.FC = ({ showTrashedDates, setShowTrashedDates }) => {\n\treturn (\n\t\t\n\t);\n};\n\nexport default ShowTrashedDatesControl;\n","import { __ } from '@eventespresso/i18n';\n\nimport { SwitchWithLabel } from '@eventespresso/ui-components';\nimport type { FilterStateManager } from '../filterState';\n\ntype ShowTrashedTicketsControlProps = Pick;\n\nconst ShowTrashedTicketsControl: React.FC = ({\n\tshowTrashedTickets,\n\tsetShowTrashedTickets,\n}) => {\n\treturn (\n\t\t\n\t);\n};\n\nexport default ShowTrashedTicketsControl;\n","import {\n\tDatesByMonthControl,\n\tShowExpiredTicketsControl,\n\tShowTrashedDatesControl,\n\tShowTrashedTicketsControl,\n} from './controls';\nimport { useTAMContext } from '../context';\nimport { useFilterState } from '../filters';\n\nconst FilterBar: React.FC = () => {\n\tconst { assignmentType } = useTAMContext();\n\tconst {\n\t\tdatesByMonth,\n\t\tsetDatesByMonth,\n\t\tsetShowExpiredTickets,\n\t\tsetShowTrashedDates,\n\t\tsetShowTrashedTickets,\n\t\tshowExpiredTickets,\n\t\tshowTrashedDates,\n\t\tshowTrashedTickets,\n\t} = useFilterState();\n\n\treturn (\n\t\t

\n\t\t\t{assignmentType !== 'forDate' && (\n\t\t\t\t// useless when TAM is for single date\n\t\t\t\t<>\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t)}\n\n\t\t\t{assignmentType !== 'forTicket' && (\n\t\t\t\t// useless when TAM is for single ticket\n\t\t\t\t<>\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t)}\n\t\t
\n\t);\n};\n\nexport default FilterBar;\n","/**\n * Checks if `value` is classified as an `Array` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an array, else `false`.\n * @example\n *\n * _.isArray([1, 2, 3]);\n * // => true\n *\n * _.isArray(document.body.children);\n * // => false\n *\n * _.isArray('abc');\n * // => false\n *\n * _.isArray(_.noop);\n * // => false\n */\nvar isArray = Array.isArray;\n\nmodule.exports = isArray;\n","/**\n * Based on Kendo UI Core expression code \n */\n'use strict'\n\nfunction Cache(maxSize) {\n this._maxSize = maxSize\n this.clear()\n}\nCache.prototype.clear = function () {\n this._size = 0\n this._values = Object.create(null)\n}\nCache.prototype.get = function (key) {\n return this._values[key]\n}\nCache.prototype.set = function (key, value) {\n this._size >= this._maxSize && this.clear()\n if (!(key in this._values)) this._size++\n\n return (this._values[key] = value)\n}\n\nvar SPLIT_REGEX = /[^.^\\]^[]+|(?=\\[\\]|\\.\\.)/g,\n DIGIT_REGEX = /^\\d+$/,\n LEAD_DIGIT_REGEX = /^\\d/,\n SPEC_CHAR_REGEX = /[~`!#$%\\^&*+=\\-\\[\\]\\\\';,/{}|\\\\\":<>\\?]/g,\n CLEAN_QUOTES_REGEX = /^\\s*(['\"]?)(.*?)(\\1)\\s*$/,\n MAX_CACHE_SIZE = 512\n\nvar pathCache = new Cache(MAX_CACHE_SIZE),\n setCache = new Cache(MAX_CACHE_SIZE),\n getCache = new Cache(MAX_CACHE_SIZE)\n\nvar config\n\nmodule.exports = {\n Cache: Cache,\n\n split: split,\n\n normalizePath: normalizePath,\n\n setter: function (path) {\n var parts = normalizePath(path)\n\n return (\n setCache.get(path) ||\n setCache.set(path, function setter(obj, value) {\n var index = 0\n var len = parts.length\n var data = obj\n\n while (index < len - 1) {\n var part = parts[index]\n if (\n part === '__proto__' ||\n part === 'constructor' ||\n part === 'prototype'\n ) {\n return obj\n }\n\n data = data[parts[index++]]\n }\n data[parts[index]] = value\n })\n )\n },\n\n getter: function (path, safe) {\n var parts = normalizePath(path)\n return (\n getCache.get(path) ||\n getCache.set(path, function getter(data) {\n var index = 0,\n len = parts.length\n while (index < len) {\n if (data != null || !safe) data = data[parts[index++]]\n else return\n }\n return data\n })\n )\n },\n\n join: function (segments) {\n return segments.reduce(function (path, part) {\n return (\n path +\n (isQuoted(part) || DIGIT_REGEX.test(part)\n ? '[' + part + ']'\n : (path ? '.' : '') + part)\n )\n }, '')\n },\n\n forEach: function (path, cb, thisArg) {\n forEach(Array.isArray(path) ? path : split(path), cb, thisArg)\n },\n}\n\nfunction normalizePath(path) {\n return (\n pathCache.get(path) ||\n pathCache.set(\n path,\n split(path).map(function (part) {\n return part.replace(CLEAN_QUOTES_REGEX, '$2')\n })\n )\n )\n}\n\nfunction split(path) {\n return path.match(SPLIT_REGEX)\n}\n\nfunction forEach(parts, iter, thisArg) {\n var len = parts.length,\n part,\n idx,\n isArray,\n isBracket\n\n for (idx = 0; idx < len; idx++) {\n part = parts[idx]\n\n if (part) {\n if (shouldBeQuoted(part)) {\n part = '\"' + part + '\"'\n }\n\n isBracket = isQuoted(part)\n isArray = !isBracket && /^\\d+$/.test(part)\n\n iter.call(thisArg, part, isBracket, isArray, idx, parts)\n }\n }\n}\n\nfunction isQuoted(str) {\n return (\n typeof str === 'string' && str && [\"'\", '\"'].indexOf(str.charAt(0)) !== -1\n )\n}\n\nfunction hasLeadingNumber(part) {\n return part.match(LEAD_DIGIT_REGEX) && !part.match(DIGIT_REGEX)\n}\n\nfunction hasSpecialChars(part) {\n return SPEC_CHAR_REGEX.test(part)\n}\n\nfunction shouldBeQuoted(part) {\n return !isQuoted(part) && (hasLeadingNumber(part) || hasSpecialChars(part))\n}\n","function toVal(mix) {\n\tvar k, y, str='';\n\n\tif (typeof mix === 'string' || typeof mix === 'number') {\n\t\tstr += mix;\n\t} else if (typeof mix === 'object') {\n\t\tif (Array.isArray(mix)) {\n\t\t\tfor (k=0; k < mix.length; k++) {\n\t\t\t\tif (mix[k]) {\n\t\t\t\t\tif (y = toVal(mix[k])) {\n\t\t\t\t\t\tstr && (str += ' ');\n\t\t\t\t\t\tstr += y;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t} else {\n\t\t\tfor (k in mix) {\n\t\t\t\tif (mix[k]) {\n\t\t\t\t\tstr && (str += ' ');\n\t\t\t\t\tstr += k;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn str;\n}\n\nexport default function () {\n\tvar i=0, tmp, x, str='';\n\twhile (i < arguments.length) {\n\t\tif (tmp = arguments[i++]) {\n\t\t\tif (x = toVal(tmp)) {\n\t\t\t\tstr && (str += ' ');\n\t\t\t\tstr += x\n\t\t\t}\n\t\t}\n\t}\n\treturn str;\n}\n","import { isValidElement } from 'react';\n\nimport { Id } from '../types';\n\nexport function isNum(v: any): v is Number {\n return typeof v === 'number' && !isNaN(v);\n}\n\nexport function isBool(v: any): v is Boolean {\n return typeof v === 'boolean';\n}\n\nexport function isStr(v: any): v is String {\n return typeof v === 'string';\n}\n\nexport function isFn(v: any): v is Function {\n return typeof v === 'function';\n}\n\nexport function parseClassName(v: any) {\n return isStr(v) || isFn(v) ? v : null;\n}\n\nexport function isToastIdValid(toastId?: Id) {\n return toastId === 0 || toastId;\n}\n\nexport function getAutoCloseDelay(\n toastAutoClose?: false | number,\n containerAutoClose?: false | number\n) {\n return toastAutoClose === false ||\n (isNum(toastAutoClose) && toastAutoClose > 0)\n ? toastAutoClose\n : containerAutoClose;\n}\n\nexport const canUseDom = !!(\n typeof window !== 'undefined' &&\n window.document &&\n window.document.createElement\n);\n\nexport function canBeRendered(content: T): boolean {\n return (\n isValidElement(content) || isStr(content) || isFn(content) || isNum(content)\n );\n}\n","import { ToastPosition, TypeOptions } from '../types';\n\ntype KeyOfPosition =\n | 'TOP_LEFT'\n | 'TOP_RIGHT'\n | 'TOP_CENTER'\n | 'BOTTOM_LEFT'\n | 'BOTTOM_RIGHT'\n | 'BOTTOM_CENTER';\n\ntype KeyOfType = 'INFO' | 'SUCCESS' | 'WARNING' | 'ERROR' | 'DEFAULT';\n\nexport const POSITION: { [key in KeyOfPosition]: ToastPosition } = {\n TOP_LEFT: 'top-left',\n TOP_RIGHT: 'top-right',\n TOP_CENTER: 'top-center',\n BOTTOM_LEFT: 'bottom-left',\n BOTTOM_RIGHT: 'bottom-right',\n BOTTOM_CENTER: 'bottom-center'\n};\n\nexport const TYPE: { [key in KeyOfType]: TypeOptions } = {\n INFO: 'info',\n SUCCESS: 'success',\n WARNING: 'warning',\n ERROR: 'error',\n DEFAULT: 'default'\n};\n\nexport const enum Default {\n COLLAPSE_DURATION = 300,\n DEBOUNCE_DURATION = 50,\n CSS_NAMESPACE = 'Toastify',\n DRAGGABLE_PERCENT = 80\n}\n\nexport const enum Direction {\n X = 'x',\n Y = 'y'\n}\n","import React, { useEffect, useLayoutEffect, useRef } from 'react';\nimport { ToastTransitionProps } from '../types';\n\nimport { collapseToast } from './collapseToast';\nimport { Default } from './constant';\n\nexport interface CSSTransitionProps {\n /**\n * Css class to apply when toast enter\n */\n enter: string;\n\n /**\n * Css class to apply when toast leave\n */\n exit: string;\n\n /**\n * Append current toast position to the classname.\n * If multiple classes are provided, only the last one will get the position\n * For instance `myclass--top-center`...\n * `Default: false`\n */\n appendPosition?: boolean;\n\n /**\n * Collapse toast smoothly when exit animation end\n * `Default: true`\n */\n collapse?: boolean;\n\n /**\n * Collapse transition duration\n * `Default: 300`\n */\n collapseDuration?: number;\n}\n\nconst enum AnimationStep {\n Enter,\n Exit\n}\n\n/**\n * Css animation that just work.\n * You could use animate.css for instance\n *\n *\n * ```\n * cssTransition({\n * enter: \"animate__animated animate__bounceIn\",\n * exit: \"animate__animated animate__bounceOut\"\n * })\n * ```\n *\n */\nexport function cssTransition({\n enter,\n exit,\n appendPosition = false,\n collapse = true,\n collapseDuration = Default.COLLAPSE_DURATION\n}: CSSTransitionProps) {\n return function ToastTransition({\n children,\n position,\n preventExitTransition,\n done,\n nodeRef,\n isIn\n }: ToastTransitionProps) {\n const enterClassName = appendPosition ? `${enter}--${position}` : enter;\n const exitClassName = appendPosition ? `${exit}--${position}` : exit;\n const baseClassName = useRef();\n const animationStep = useRef(AnimationStep.Enter);\n\n useLayoutEffect(() => {\n onEnter();\n }, []);\n\n useEffect(() => {\n if (!isIn) preventExitTransition ? onExited() : onExit();\n }, [isIn]);\n\n function onEnter() {\n const node = nodeRef.current!;\n baseClassName.current = node.className;\n node.className += ` ${enterClassName}`;\n node.addEventListener('animationend', onEntered);\n }\n\n function onEntered(e: AnimationEvent) {\n if (e.target !== nodeRef.current) return;\n\n const node = nodeRef.current!;\n node.removeEventListener('animationend', onEntered);\n if (animationStep.current === AnimationStep.Enter) {\n node.className = baseClassName.current!;\n }\n }\n\n function onExit() {\n animationStep.current = AnimationStep.Exit;\n const node = nodeRef.current!;\n\n node.className += ` ${exitClassName}`;\n node.addEventListener('animationend', onExited);\n }\n\n function onExited() {\n const node = nodeRef.current!;\n\n node.removeEventListener('animationend', onExited);\n collapse ? collapseToast(node, done, collapseDuration) : done();\n }\n\n return <>{children};\n };\n}\n","import { Default } from './constant';\n\n/**\n * Used to collapse toast after exit animation\n */\nexport function collapseToast(\n node: HTMLElement,\n done: () => void,\n duration = Default.COLLAPSE_DURATION\n) {\n const { scrollHeight, style } = node;\n\n requestAnimationFrame(() => {\n style.minHeight = 'initial';\n style.height = scrollHeight + 'px';\n style.transition = `all ${duration}ms`;\n\n requestAnimationFrame(() => {\n style.height = '0';\n style.padding = '0';\n style.margin = '0';\n setTimeout(done, duration as number);\n });\n });\n}\n","import {\n Id,\n ToastContent,\n ClearWaitingQueueParams,\n NotValidatedToastProps\n} from '../types';\nimport { ContainerInstance } from '../hooks';\n\nexport const enum Event {\n Show,\n Clear,\n DidMount,\n WillUnmount,\n Change,\n ClearWaitingQueue\n}\n\ntype OnShowCallback = (\n content: ToastContent,\n options: NotValidatedToastProps\n) => void;\ntype OnClearCallback = (id?: Id) => void;\ntype OnClearWaitingQueue = (params: ClearWaitingQueueParams) => void;\ntype OnDidMountCallback = (containerInstance: ContainerInstance) => void;\ntype OnWillUnmountCallback = OnDidMountCallback;\nexport type OnChangeCallback = (\n toast: number,\n containerId?: number | string\n) => void;\ntype Callback =\n | OnShowCallback\n | OnClearCallback\n | OnClearWaitingQueue\n | OnDidMountCallback\n | OnWillUnmountCallback\n | OnChangeCallback;\ntype TimeoutId = ReturnType;\n\nexport interface EventManager {\n list: Map;\n emitQueue: Map;\n on(event: Event.Show, callback: OnShowCallback): EventManager;\n on(event: Event.Clear, callback: OnClearCallback): EventManager;\n on(\n event: Event.ClearWaitingQueue,\n callback: OnClearWaitingQueue\n ): EventManager;\n on(event: Event.DidMount, callback: OnDidMountCallback): EventManager;\n on(event: Event.WillUnmount, callback: OnWillUnmountCallback): EventManager;\n on(event: Event.Change, callback: OnChangeCallback): EventManager;\n off(event: Event, callback?: Callback): EventManager;\n cancelEmit(event: Event): EventManager;\n emit(\n event: Event.Show,\n content: React.ReactNode,\n options: NotValidatedToastProps\n ): void;\n emit(event: Event.Clear, id?: string | number): void;\n emit(event: Event.ClearWaitingQueue, params: ClearWaitingQueueParams): void;\n emit(event: Event.DidMount, containerInstance: ContainerInstance): void;\n emit(event: Event.WillUnmount, containerInstance: ContainerInstance): void;\n emit(event: Event.Change, toast: number, containerId?: number | string): void;\n}\n\nexport const eventManager: EventManager = {\n list: new Map(),\n emitQueue: new Map(),\n\n on(event: Event, callback: Callback) {\n this.list.has(event) || this.list.set(event, []);\n this.list.get(event)!.push(callback);\n return this;\n },\n\n off(event, callback) {\n if (callback) {\n const cb = this.list.get(event)!.filter(cb => cb !== callback);\n this.list.set(event, cb);\n return this;\n }\n this.list.delete(event);\n return this;\n },\n\n cancelEmit(event) {\n const timers = this.emitQueue.get(event);\n if (timers) {\n timers.forEach(clearTimeout);\n this.emitQueue.delete(event);\n }\n\n return this;\n },\n\n /**\n * Enqueue the event at the end of the call stack\n * Doing so let the user call toast as follow:\n * toast('1')\n * toast('2')\n * toast('3')\n * Without setTimemout the code above will not work\n */\n emit(event: Event, ...args: any[]) {\n this.list.has(event) &&\n this.list.get(event)!.forEach((callback: Callback) => {\n const timer: TimeoutId = setTimeout(() => {\n // @ts-ignore\n callback(...args);\n }, 0);\n\n this.emitQueue.has(event) || this.emitQueue.set(event, []);\n this.emitQueue.get(event)!.push(timer);\n });\n }\n};\n","import { useRef, useEffect } from 'react';\n\n/**\n * `useKeeper` is a helper around `useRef`.\n *\n * You don't need to access the `.current`property to get the value\n * If refresh is set to true. The ref will be updated every render\n */\nexport function useKeeper(arg: T, refresh = false) {\n const ref = useRef(arg);\n\n useEffect(() => {\n if (refresh) ref.current = arg;\n });\n\n return ref.current;\n}\n","import { Id } from '../types';\n\nimport { isToastIdValid } from '../utils';\n\nexport const enum ActionType {\n ADD,\n REMOVE\n}\nexport type State = Array;\nexport type Action =\n | { type: ActionType.ADD; toastId: Id; staleId?: Id }\n | { type: ActionType.REMOVE; toastId?: Id };\n\nexport function reducer(state: State, action: Action) {\n switch (action.type) {\n case ActionType.ADD:\n return [...state, action.toastId].filter(id => id !== action.staleId);\n case ActionType.REMOVE:\n return isToastIdValid(action.toastId)\n ? state.filter(id => id !== action.toastId)\n : [];\n }\n}\n","import {\n useEffect,\n useRef,\n useReducer,\n cloneElement,\n isValidElement\n} from 'react';\nimport {\n parseClassName,\n canBeRendered,\n isBool,\n isFn,\n isNum,\n isStr,\n isToastIdValid,\n getAutoCloseDelay,\n Direction,\n Default\n} from '../utils';\nimport { eventManager, Event } from '../core/eventManager';\n\nimport {\n Id,\n ToastContainerProps,\n ToastProps,\n ToastContent,\n Toast,\n ToastPosition,\n ClearWaitingQueueParams,\n NotValidatedToastProps,\n ToastTransition\n} from '../types';\nimport { useKeeper } from './useKeeper';\nimport { ActionType, reducer } from './toastContainerReducer';\n\ntype CollectionItem = Record;\ntype ToastToRender = Partial>;\n\ninterface QueuedToast {\n toastContent: ToastContent;\n toastProps: ToastProps;\n staleId?: Id;\n}\n\nexport interface ContainerInstance {\n toastKey: number;\n displayedToast: number;\n props: ToastContainerProps;\n containerId?: Id | null;\n isToastActive: (toastId: Id) => boolean;\n getToast: (id: Id) => Toast | null;\n}\n\nexport function useToastContainer(props: ToastContainerProps) {\n const [, forceUpdate] = useReducer(x => x + 1, 0);\n const [toast, dispatch] = useReducer(reducer, []);\n const containerRef = useRef(null);\n let toastCount = useKeeper(0);\n let queue = useKeeper([]);\n const collection = useKeeper({});\n const instance = useKeeper({\n toastKey: 1,\n displayedToast: 0,\n props,\n containerId: null,\n isToastActive: isToastActive,\n getToast: id => collection[id] || null\n });\n\n useEffect(() => {\n instance.containerId = props.containerId;\n eventManager\n .cancelEmit(Event.WillUnmount)\n .on(Event.Show, buildToast)\n .on(Event.Clear, toastId => containerRef.current && removeToast(toastId))\n .on(Event.ClearWaitingQueue, clearWaitingQueue)\n .emit(Event.DidMount, instance);\n\n return () => eventManager.emit(Event.WillUnmount, instance);\n }, []);\n\n useEffect(() => {\n instance.isToastActive = isToastActive;\n instance.displayedToast = toast.length;\n eventManager.emit(Event.Change, toast.length, props.containerId);\n }, [toast]);\n\n useEffect(() => {\n instance.props = props;\n });\n\n function isToastActive(id: Id) {\n return toast.indexOf(id) !== -1;\n }\n\n function clearWaitingQueue({ containerId }: ClearWaitingQueueParams) {\n const { limit } = instance.props;\n if (limit && (!containerId || instance.containerId === containerId)) {\n toastCount -= queue.length;\n queue = [];\n }\n }\n\n function removeToast(toastId?: Id) {\n dispatch({ type: ActionType.REMOVE, toastId });\n }\n\n function dequeueToast() {\n const { toastContent, toastProps, staleId } = queue.shift() as QueuedToast;\n appendToast(toastContent, toastProps, staleId);\n }\n\n /**\n * check if a container is attached to the dom\n * check for multi-container, build only if associated\n * check for duplicate toastId if no update\n */\n function isNotValid({\n containerId,\n toastId,\n updateId\n }: NotValidatedToastProps) {\n return !containerRef.current ||\n (instance.props.enableMultiContainer &&\n containerId !== instance.props.containerId) ||\n (collection[toastId] && updateId == null)\n ? true\n : false;\n }\n\n // this function and all the function called inside needs to rely on ref(`useKeeper`)\n function buildToast(\n content: ToastContent,\n { delay, staleId, ...options }: NotValidatedToastProps\n ) {\n if (!canBeRendered(content) || isNotValid(options)) return;\n\n const { toastId, updateId, data } = options;\n const { props } = instance;\n const closeToast = () => removeToast(toastId);\n const isNotAnUpdate = options.updateId == null;\n\n if (isNotAnUpdate) toastCount++;\n\n const toastProps: ToastProps = {\n toastId,\n updateId,\n isLoading: options.isLoading,\n theme: options.theme || props.theme!,\n icon: options.icon ?? props.icon,\n isIn: false,\n key: options.key || instance.toastKey++,\n type: options.type!,\n closeToast: closeToast,\n closeButton: options.closeButton,\n rtl: props.rtl,\n position: options.position || (props.position as ToastPosition),\n transition: options.transition || (props.transition as ToastTransition),\n className: parseClassName(options.className || props.toastClassName),\n bodyClassName: parseClassName(\n options.bodyClassName || props.bodyClassName\n ),\n style: options.style || props.toastStyle,\n bodyStyle: options.bodyStyle || props.bodyStyle,\n onClick: options.onClick || props.onClick,\n pauseOnHover: isBool(options.pauseOnHover)\n ? options.pauseOnHover\n : props.pauseOnHover,\n pauseOnFocusLoss: isBool(options.pauseOnFocusLoss)\n ? options.pauseOnFocusLoss\n : props.pauseOnFocusLoss,\n draggable: isBool(options.draggable)\n ? options.draggable\n : props.draggable,\n draggablePercent: isNum(options.draggablePercent)\n ? options.draggablePercent\n : (props.draggablePercent as number),\n draggableDirection:\n options.draggableDirection || props.draggableDirection,\n closeOnClick: isBool(options.closeOnClick)\n ? options.closeOnClick\n : props.closeOnClick,\n progressClassName: parseClassName(\n options.progressClassName || props.progressClassName\n ),\n progressStyle: options.progressStyle || props.progressStyle,\n autoClose: options.isLoading\n ? false\n : getAutoCloseDelay(options.autoClose, props.autoClose),\n hideProgressBar: isBool(options.hideProgressBar)\n ? options.hideProgressBar\n : props.hideProgressBar,\n progress: options.progress,\n role: isStr(options.role) ? options.role : props.role,\n deleteToast() {\n removeFromCollection(toastId);\n }\n };\n\n if (isFn(options.onOpen)) toastProps.onOpen = options.onOpen;\n if (isFn(options.onClose)) toastProps.onClose = options.onClose;\n\n // tweak for vertical dragging\n if (\n toastProps.draggableDirection === Direction.Y &&\n toastProps.draggablePercent === Default.DRAGGABLE_PERCENT\n ) {\n (toastProps.draggablePercent as number) *= 1.5;\n }\n\n let closeButton = props.closeButton;\n\n if (options.closeButton === false || canBeRendered(options.closeButton)) {\n closeButton = options.closeButton;\n } else if (options.closeButton === true) {\n closeButton = canBeRendered(props.closeButton) ? props.closeButton : true;\n }\n\n toastProps.closeButton = closeButton;\n\n let toastContent = content;\n\n if (isValidElement(content) && !isStr(content.type)) {\n toastContent = cloneElement(content, {\n closeToast,\n toastProps,\n data\n });\n } else if (isFn(content)) {\n toastContent = content({ closeToast, toastProps, data });\n }\n\n // not handling limit + delay by design. Waiting for user feedback first\n if (\n props.limit &&\n props.limit > 0 &&\n toastCount > props.limit &&\n isNotAnUpdate\n ) {\n queue.push({ toastContent, toastProps, staleId });\n } else if (isNum(delay) && (delay as number) > 0) {\n setTimeout(() => {\n appendToast(toastContent, toastProps, staleId);\n }, delay);\n } else {\n appendToast(toastContent, toastProps, staleId);\n }\n }\n\n function appendToast(\n content: ToastContent,\n toastProps: ToastProps,\n staleId?: Id\n ) {\n const { toastId } = toastProps;\n\n if (staleId) delete collection[staleId];\n\n collection[toastId] = {\n content,\n props: toastProps\n };\n dispatch({\n type: ActionType.ADD,\n toastId,\n staleId\n });\n }\n\n function removeFromCollection(toastId: Id) {\n delete collection[toastId];\n const queueLen = queue.length;\n toastCount = isToastIdValid(toastId)\n ? toastCount - 1\n : toastCount - instance.displayedToast;\n\n if (toastCount < 0) toastCount = 0;\n\n if (queueLen > 0) {\n const freeSlot = isToastIdValid(toastId) ? 1 : instance.props.limit!;\n\n if (queueLen === 1 || freeSlot === 1) {\n instance.displayedToast++;\n dequeueToast();\n } else {\n const toDequeue = freeSlot > queueLen ? queueLen : freeSlot;\n instance.displayedToast = toDequeue;\n\n for (let i = 0; i < toDequeue; i++) dequeueToast();\n }\n } else {\n forceUpdate();\n }\n }\n\n function getToastToRender(\n cb: (position: ToastPosition, toastList: Toast[]) => T\n ) {\n const toastToRender: ToastToRender = {};\n const toastList = props.newestOnTop\n ? Object.keys(collection).reverse()\n : Object.keys(collection);\n\n for (let i = 0; i < toastList.length; i++) {\n const toast = collection[toastList[i]];\n const { position } = toast.props;\n toastToRender[position] || (toastToRender[position] = []);\n\n toastToRender[position]!.push(toast);\n }\n\n return (Object.keys(toastToRender) as Array).map(p =>\n cb(p, toastToRender[p]!)\n );\n }\n\n return {\n getToastToRender,\n collection,\n containerRef,\n isToastActive\n };\n}\n","import {\n useState,\n useRef,\n useEffect,\n isValidElement,\n DOMAttributes\n} from 'react';\n\nimport { isFn } from '../utils';\nimport { ToastProps } from '../types';\nimport { useKeeper } from './useKeeper';\nimport { Direction } from '../utils/constant';\n\ninterface Draggable {\n start: number;\n x: number;\n y: number;\n delta: number;\n removalDistance: number;\n canCloseOnClick: boolean;\n canDrag: boolean;\n boundingRect: DOMRect | null;\n}\n\ntype DragEvent = MouseEvent & TouchEvent;\n\nfunction getX(e: DragEvent) {\n return e.targetTouches && e.targetTouches.length >= 1\n ? e.targetTouches[0].clientX\n : e.clientX;\n}\n\nfunction getY(e: DragEvent) {\n return e.targetTouches && e.targetTouches.length >= 1\n ? e.targetTouches[0].clientY\n : e.clientY;\n}\n\nexport function useToast(props: ToastProps) {\n const [isRunning, setIsRunning] = useState(true);\n const [preventExitTransition, setPreventExitTransition] = useState(false);\n const toastRef = useRef(null);\n const drag = useKeeper({\n start: 0,\n x: 0,\n y: 0,\n delta: 0,\n removalDistance: 0,\n canCloseOnClick: true,\n canDrag: false,\n boundingRect: null\n });\n const syncProps = useKeeper(props, true);\n const { autoClose, pauseOnHover, closeToast, onClick, closeOnClick } = props;\n\n useEffect(() => {\n if (isFn(props.onOpen))\n props.onOpen(isValidElement(props.children) && props.children.props);\n\n return () => {\n if (isFn(syncProps.onClose))\n syncProps.onClose(\n isValidElement(syncProps.children) && syncProps.children.props\n );\n };\n }, []);\n\n useEffect(() => {\n props.draggable && bindDragEvents();\n return () => {\n props.draggable && unbindDragEvents();\n };\n }, [props.draggable]);\n\n useEffect(() => {\n props.pauseOnFocusLoss && bindFocusEvents();\n return () => {\n props.pauseOnFocusLoss && unbindFocusEvents();\n };\n }, [props.pauseOnFocusLoss]);\n\n function onDragStart(\n e: React.MouseEvent | React.TouchEvent\n ) {\n if (props.draggable) {\n const toast = toastRef.current!;\n drag.canCloseOnClick = true;\n drag.canDrag = true;\n drag.boundingRect = toast.getBoundingClientRect();\n toast.style.transition = '';\n drag.x = getX(e.nativeEvent as DragEvent);\n drag.y = getY(e.nativeEvent as DragEvent);\n\n if (props.draggableDirection === Direction.X) {\n drag.start = drag.x;\n drag.removalDistance =\n toast.offsetWidth * (props.draggablePercent / 100);\n } else {\n drag.start = drag.y;\n drag.removalDistance =\n toast.offsetHeight * (props.draggablePercent / 100);\n }\n }\n }\n\n function onDragTransitionEnd() {\n if (drag.boundingRect) {\n const { top, bottom, left, right } = drag.boundingRect;\n\n if (\n props.pauseOnHover &&\n drag.x >= left &&\n drag.x <= right &&\n drag.y >= top &&\n drag.y <= bottom\n ) {\n pauseToast();\n } else {\n playToast();\n }\n }\n }\n\n function playToast() {\n setIsRunning(true);\n }\n\n function pauseToast() {\n setIsRunning(false);\n }\n\n function bindFocusEvents() {\n if (!document.hasFocus()) pauseToast();\n\n window.addEventListener('focus', playToast);\n window.addEventListener('blur', pauseToast);\n }\n\n function unbindFocusEvents() {\n window.removeEventListener('focus', playToast);\n window.removeEventListener('blur', pauseToast);\n }\n\n function bindDragEvents() {\n document.addEventListener('mousemove', onDragMove);\n document.addEventListener('mouseup', onDragEnd);\n\n document.addEventListener('touchmove', onDragMove);\n document.addEventListener('touchend', onDragEnd);\n }\n\n function unbindDragEvents() {\n document.removeEventListener('mousemove', onDragMove);\n document.removeEventListener('mouseup', onDragEnd);\n\n document.removeEventListener('touchmove', onDragMove);\n document.removeEventListener('touchend', onDragEnd);\n }\n\n function onDragMove(e: MouseEvent | TouchEvent) {\n if (drag.canDrag) {\n e.preventDefault();\n\n const toast = toastRef.current!;\n if (isRunning) pauseToast();\n\n drag.x = getX(e as DragEvent);\n drag.y = getY(e as DragEvent);\n\n if (props.draggableDirection === Direction.X) {\n drag.delta = drag.x - drag.start;\n } else {\n drag.delta = drag.y - drag.start;\n }\n\n // prevent false positif during a toast click\n if (drag.start !== drag.x) drag.canCloseOnClick = false;\n\n toast.style.transform = `translate${props.draggableDirection}(${drag.delta}px)`;\n toast.style.opacity = `${1 -\n Math.abs(drag.delta / drag.removalDistance)}`;\n }\n }\n\n function onDragEnd() {\n const toast = toastRef.current!;\n if (drag.canDrag) {\n drag.canDrag = false;\n\n if (Math.abs(drag.delta) > drag.removalDistance) {\n setPreventExitTransition(true);\n props.closeToast();\n return;\n }\n\n toast.style.transition = 'transform 0.2s, opacity 0.2s';\n toast.style.transform = `translate${props.draggableDirection}(0)`;\n toast.style.opacity = '1';\n }\n }\n\n const eventHandlers: DOMAttributes = {\n onMouseDown: onDragStart,\n onTouchStart: onDragStart,\n onMouseUp: onDragTransitionEnd,\n onTouchEnd: onDragTransitionEnd\n };\n\n if (autoClose && pauseOnHover) {\n eventHandlers.onMouseEnter = pauseToast;\n eventHandlers.onMouseLeave = playToast;\n }\n\n // prevent toast from closing when user drags the toast\n if (closeOnClick) {\n eventHandlers.onClick = (e: React.MouseEvent) => {\n onClick && onClick(e);\n drag.canCloseOnClick && closeToast();\n };\n }\n\n return {\n playToast,\n pauseToast,\n isRunning,\n preventExitTransition,\n toastRef,\n eventHandlers\n };\n}\n","import * as React from 'react';\nimport { Default } from '../utils';\nimport { Theme, TypeOptions } from '../types';\n\nexport interface CloseButtonProps {\n closeToast: (e: React.MouseEvent) => void;\n type: TypeOptions;\n ariaLabel?: string;\n theme: Theme;\n}\n\nexport function CloseButton({\n closeToast,\n theme,\n ariaLabel = 'close'\n}: CloseButtonProps) {\n return (\n {\n e.stopPropagation();\n closeToast(e);\n }}\n aria-label={ariaLabel}\n >\n \n \n \n \n );\n}\n","import * as React from 'react';\nimport cx from 'clsx';\n\nimport { TYPE, Default, isFn } from './../utils';\nimport { TypeOptions, ToastClassName, Theme } from '../types';\n\nexport interface ProgressBarProps {\n /**\n * The animation delay which determine when to close the toast\n */\n delay: number;\n\n /**\n * Whether or not the animation is running or paused\n */\n isRunning: boolean;\n\n /**\n * Func to close the current toast\n */\n closeToast: () => void;\n\n /**\n * Optional type : info, success ...\n */\n type: TypeOptions;\n\n /**\n * The theme that is currently used\n */\n theme: Theme;\n\n /**\n * Hide or not the progress bar\n */\n hide?: boolean;\n\n /**\n * Optionnal className\n */\n className?: ToastClassName;\n\n /**\n * Optionnal inline style\n */\n style?: React.CSSProperties;\n\n /**\n * Tell wether or not controlled progress bar is used\n */\n controlledProgress?: boolean;\n\n /**\n * Controlled progress value\n */\n progress?: number | string;\n\n /**\n * Support rtl content\n */\n rtl?: boolean;\n\n /**\n * Tell if the component is visible on screen or not\n */\n isIn?: boolean;\n}\n\nexport function ProgressBar({\n delay,\n isRunning,\n closeToast,\n type,\n hide,\n className,\n style: userStyle,\n controlledProgress,\n progress,\n rtl,\n isIn,\n theme\n}: ProgressBarProps) {\n const style: React.CSSProperties = {\n ...userStyle,\n animationDuration: `${delay}ms`,\n animationPlayState: isRunning ? 'running' : 'paused',\n opacity: hide ? 0 : 1\n };\n\n if (controlledProgress) style.transform = `scaleX(${progress})`;\n const defaultClassName = cx(\n `${Default.CSS_NAMESPACE}__progress-bar`,\n controlledProgress\n ? `${Default.CSS_NAMESPACE}__progress-bar--controlled`\n : `${Default.CSS_NAMESPACE}__progress-bar--animated`,\n `${Default.CSS_NAMESPACE}__progress-bar-theme--${theme}`,\n `${Default.CSS_NAMESPACE}__progress-bar--${type}`,\n {\n [`${Default.CSS_NAMESPACE}__progress-bar--rtl`]: rtl\n }\n );\n const classNames = isFn(className)\n ? className({\n rtl,\n type,\n defaultClassName\n })\n : cx(defaultClassName, className);\n\n // 🧐 controlledProgress is derived from progress\n // so if controlledProgress is set\n // it means that this is also the case for progress\n const animationEvent = {\n [controlledProgress && progress! >= 1\n ? 'onTransitionEnd'\n : 'onAnimationEnd']:\n controlledProgress && progress! < 1\n ? null\n : () => {\n isIn && closeToast();\n }\n };\n\n // TODO: add aria-valuenow, aria-valuemax, aria-valuemin\n\n return (\n \n );\n}\n\nProgressBar.defaultProps = {\n type: TYPE.DEFAULT,\n hide: false\n};\n","import React from 'react';\n\nimport { Theme, TypeOptions } from '../types';\nimport { Default } from '../utils';\n\n/**\n * Used when providing custom icon\n */\nexport interface IconProps {\n theme: Theme;\n type: TypeOptions;\n}\n\nexport type BuiltInIconProps = React.SVGProps & IconProps;\n\nconst Svg: React.FC = ({ theme, type, ...rest }) => (\n \n);\n\nfunction Warning(props: BuiltInIconProps) {\n return (\n \n \n \n );\n}\n\nfunction Info(props: BuiltInIconProps) {\n return (\n \n \n \n );\n}\n\nfunction Success(props: BuiltInIconProps) {\n return (\n \n \n \n );\n}\n\nfunction Error(props: BuiltInIconProps) {\n return (\n \n \n \n );\n}\n\nfunction Spinner() {\n return
;\n}\n\nexport const Icons = {\n info: Info,\n warning: Warning,\n success: Success,\n error: Error,\n spinner: Spinner\n};\n","import * as React from 'react';\nimport cx from 'clsx';\n\nimport { ProgressBar } from './ProgressBar';\nimport { Icons } from './Icons';\nimport { ToastProps } from '../types';\nimport { Default, isFn, isStr } from '../utils';\nimport { useToast } from '../hooks';\n\nexport const Toast: React.FC = props => {\n const {\n isRunning,\n preventExitTransition,\n toastRef,\n eventHandlers\n } = useToast(props);\n const {\n closeButton,\n children,\n autoClose,\n onClick,\n type,\n hideProgressBar,\n closeToast,\n transition: Transition,\n position,\n className,\n style,\n bodyClassName,\n bodyStyle,\n progressClassName,\n progressStyle,\n updateId,\n role,\n progress,\n rtl,\n toastId,\n deleteToast,\n isIn,\n isLoading,\n icon,\n theme\n } = props;\n const defaultClassName = cx(\n `${Default.CSS_NAMESPACE}__toast`,\n `${Default.CSS_NAMESPACE}__toast-theme--${theme}`,\n `${Default.CSS_NAMESPACE}__toast--${type}`,\n {\n [`${Default.CSS_NAMESPACE}__toast--rtl`]: rtl\n }\n );\n const cssClasses = isFn(className)\n ? className({\n rtl,\n position,\n type,\n defaultClassName\n })\n : cx(defaultClassName, className);\n const isProgressControlled = !!progress;\n const maybeIcon = Icons[type as keyof typeof Icons];\n const iconProps = { theme, type };\n let Icon: React.ReactNode = maybeIcon && maybeIcon(iconProps);\n\n if (icon === false) {\n Icon = void 0;\n } else if (isFn(icon)) {\n Icon = icon(iconProps);\n } else if (React.isValidElement(icon)) {\n Icon = React.cloneElement(icon, iconProps);\n } else if (isStr(icon)) {\n Icon = icon;\n } else if (isLoading) {\n Icon = Icons.spinner();\n }\n\n function renderCloseButton(closeButton: any) {\n if (!closeButton) return;\n\n const props = { closeToast, type, theme };\n\n if (isFn(closeButton)) return closeButton(props);\n\n if (React.isValidElement(closeButton))\n return React.cloneElement(closeButton, props);\n }\n\n return (\n \n \n \n {Icon && (\n \n {Icon}\n
\n )}\n
{children}
\n \n {renderCloseButton(closeButton)}\n {(autoClose || isProgressControlled) && (\n \n )}\n \n \n );\n};\n","import { Default, cssTransition } from '../utils';\n\nconst Bounce = cssTransition({\n enter: `${Default.CSS_NAMESPACE}--animate ${Default.CSS_NAMESPACE}__bounce-enter`,\n exit: `${Default.CSS_NAMESPACE}--animate ${Default.CSS_NAMESPACE}__bounce-exit`,\n appendPosition: true\n});\n\nconst Slide = cssTransition({\n enter: `${Default.CSS_NAMESPACE}--animate ${Default.CSS_NAMESPACE}__slide-enter`,\n exit: `${Default.CSS_NAMESPACE}--animate ${Default.CSS_NAMESPACE}__slide-exit`,\n appendPosition: true\n});\n\nconst Zoom = cssTransition({\n enter: `${Default.CSS_NAMESPACE}--animate ${Default.CSS_NAMESPACE}__zoom-enter`,\n exit: `${Default.CSS_NAMESPACE}--animate ${Default.CSS_NAMESPACE}__zoom-exit`\n});\n\nconst Flip = cssTransition({\n enter: `${Default.CSS_NAMESPACE}--animate ${Default.CSS_NAMESPACE}__flip-enter`,\n exit: `${Default.CSS_NAMESPACE}--animate ${Default.CSS_NAMESPACE}__flip-exit`\n});\n\nexport { Bounce, Slide, Zoom, Flip };\n","import * as React from 'react';\nimport cx from 'clsx';\n\nimport { Toast } from './Toast';\nimport { CloseButton } from './CloseButton';\nimport { Bounce } from './Transitions';\nimport { POSITION, Direction, Default, parseClassName, isFn } from '../utils';\nimport { useToastContainer } from '../hooks';\nimport { ToastContainerProps, ToastPosition } from '../types';\n\nexport const ToastContainer: React.FC = props => {\n const { getToastToRender, containerRef, isToastActive } = useToastContainer(\n props\n );\n const { className, style, rtl, containerId } = props;\n\n function getClassName(position: ToastPosition) {\n const defaultClassName = cx(\n `${Default.CSS_NAMESPACE}__toast-container`,\n `${Default.CSS_NAMESPACE}__toast-container--${position}`,\n { [`${Default.CSS_NAMESPACE}__toast-container--rtl`]: rtl }\n );\n return isFn(className)\n ? className({\n position,\n rtl,\n defaultClassName\n })\n : cx(defaultClassName, parseClassName(className));\n }\n\n return (\n \n {getToastToRender((position, toastList) => {\n const containerStyle: React.CSSProperties =\n toastList.length === 0\n ? { ...style, pointerEvents: 'none' }\n : { ...style };\n\n return (\n \n {toastList.map(({ content, props: toastProps }) => {\n return (\n \n {content}\n \n );\n })}\n \n );\n })}\n \n );\n};\n\nToastContainer.defaultProps = {\n position: POSITION.TOP_RIGHT as ToastPosition,\n transition: Bounce,\n rtl: false,\n autoClose: 5000,\n hideProgressBar: false,\n closeButton: CloseButton,\n pauseOnHover: true,\n pauseOnFocusLoss: true,\n closeOnClick: true,\n newestOnTop: false,\n draggable: true,\n draggablePercent: Default.DRAGGABLE_PERCENT as number,\n draggableDirection: Direction.X,\n role: 'alert',\n theme: 'light'\n};\n","import * as React from 'react';\nimport { render } from 'react-dom';\n\nimport { POSITION, TYPE, canUseDom, isStr, isNum, isFn } from '../utils';\nimport { eventManager, OnChangeCallback, Event } from './eventManager';\nimport {\n ToastContent,\n ToastOptions,\n ToastProps,\n Id,\n ToastContainerProps,\n UpdateOptions,\n ClearWaitingQueueParams,\n NotValidatedToastProps,\n TypeOptions\n} from '../types';\nimport { ContainerInstance } from '../hooks';\nimport { ToastContainer } from '../components';\n\ninterface EnqueuedToast {\n content: ToastContent;\n options: NotValidatedToastProps;\n}\n\nlet containers = new Map();\nlet latestInstance: ContainerInstance | Id;\nlet containerDomNode: HTMLElement;\nlet containerConfig: ToastContainerProps;\nlet queue: EnqueuedToast[] = [];\nlet lazy = false;\n\n/**\n * Check whether any container is currently mounted in the DOM\n */\nfunction isAnyContainerMounted() {\n return containers.size > 0;\n}\n\n/**\n * Get the toast by id, given it's in the DOM, otherwise returns null\n */\nfunction getToast(toastId: Id, { containerId }: ToastOptions) {\n const container = containers.get(containerId || latestInstance);\n if (!container) return null;\n\n return container.getToast(toastId);\n}\n\n/**\n * Generate a random toastId\n */\nfunction generateToastId() {\n return Math.random()\n .toString(36)\n .substr(2, 9);\n}\n\n/**\n * Generate a toastId or use the one provided\n */\nfunction getToastId(options?: ToastOptions) {\n if (options && (isStr(options.toastId) || isNum(options.toastId))) {\n return options.toastId;\n }\n\n return generateToastId();\n}\n\n/**\n * If the container is not mounted, the toast is enqueued and\n * the container lazy mounted\n */\nfunction dispatchToast(\n content: ToastContent,\n options: NotValidatedToastProps\n): Id {\n if (isAnyContainerMounted()) {\n eventManager.emit(Event.Show, content, options);\n } else {\n queue.push({ content, options });\n if (lazy && canUseDom) {\n lazy = false;\n containerDomNode = document.createElement('div');\n document.body.appendChild(containerDomNode);\n render(, containerDomNode);\n }\n }\n\n return options.toastId;\n}\n\n/**\n * Merge provided options with the defaults settings and generate the toastId\n */\nfunction mergeOptions(type: string, options?: ToastOptions) {\n return {\n ...options,\n type: (options && options.type) || type,\n toastId: getToastId(options)\n } as NotValidatedToastProps;\n}\n\nconst createToastByType = (type: string) => (\n content: ToastContent,\n options?: ToastOptions\n) => dispatchToast(content, mergeOptions(type, options));\n\nconst toast = (content: ToastContent, options?: ToastOptions) =>\n dispatchToast(content, mergeOptions(TYPE.DEFAULT, options));\n\ntoast.loading = (content: ToastContent, options?: ToastOptions) =>\n dispatchToast(\n content,\n mergeOptions(TYPE.DEFAULT, {\n isLoading: true,\n autoClose: false,\n closeOnClick: false,\n closeButton: false,\n draggable: false,\n ...options\n })\n );\n\ninterface ToastPromiseParams {\n pending: string | UpdateOptions;\n success: string | UpdateOptions;\n error: string | UpdateOptions;\n}\n\nfunction handlePromise(\n promise: Promise | (() => Promise),\n { pending, error, success }: ToastPromiseParams,\n options?: ToastOptions\n) {\n const id = isStr(pending)\n ? toast.loading(pending, options)\n : toast.loading(pending.render, {\n ...options,\n ...(pending as ToastOptions)\n });\n const resetParams = {\n isLoading: null,\n autoClose: null,\n closeOnClick: null,\n closeButton: null,\n draggable: null\n };\n\n const resolver = (\n type: TypeOptions,\n input: string | UpdateOptions,\n result: T\n ) => {\n const params = isStr(input) ? { render: input } : input;\n toast.update(id, {\n type,\n ...resetParams,\n ...options,\n ...params,\n data: result\n });\n return result;\n };\n const p = isFn(promise) ? promise() : promise;\n p.then(result => resolver('success', success, result)).catch(err =>\n resolver('error', error, err)\n );\n\n return p;\n}\n\ntoast.promise = handlePromise;\ntoast.success = createToastByType(TYPE.SUCCESS);\ntoast.info = createToastByType(TYPE.INFO);\ntoast.error = createToastByType(TYPE.ERROR);\ntoast.warning = createToastByType(TYPE.WARNING);\ntoast.warn = toast.warning;\ntoast.dark = (content: ToastContent, options?: ToastOptions) =>\n dispatchToast(\n content,\n mergeOptions(TYPE.DEFAULT, {\n theme: 'dark',\n ...options\n })\n );\n\n/**\n * Remove toast programmaticaly\n */\ntoast.dismiss = (id?: Id) => eventManager.emit(Event.Clear, id);\n\n/**\n * Clear waiting queue when limit is used\n */\ntoast.clearWaitingQueue = (params: ClearWaitingQueueParams = {}) =>\n eventManager.emit(Event.ClearWaitingQueue, params);\n\n/**\n * return true if one container is displaying the toast\n */\ntoast.isActive = (id: Id) => {\n let isToastActive = false;\n\n containers.forEach(container => {\n if (container.isToastActive && container.isToastActive(id)) {\n isToastActive = true;\n }\n });\n\n return isToastActive;\n};\n\ntoast.update = (toastId: Id, options: UpdateOptions = {}) => {\n // if you call toast and toast.update directly nothing will be displayed\n // this is why I defered the update\n setTimeout(() => {\n const toast = getToast(toastId, options as ToastOptions);\n if (toast) {\n const { props: oldOptions, content: oldContent } = toast;\n\n const nextOptions = {\n ...oldOptions,\n ...options,\n toastId: options.toastId || toastId,\n updateId: generateToastId()\n } as ToastProps & UpdateOptions;\n\n if (nextOptions.toastId !== toastId) nextOptions.staleId = toastId;\n\n const content = nextOptions.render || oldContent;\n delete nextOptions.render;\n\n dispatchToast(content, nextOptions);\n }\n }, 0);\n};\n\n/**\n * Used for controlled progress bar.\n */\ntoast.done = (id: Id) => {\n toast.update(id, {\n progress: 1\n });\n};\n\n/**\n * Track changes. The callback get the number of toast displayed\n *\n */\ntoast.onChange = (callback: OnChangeCallback) => {\n if (isFn(callback)) {\n eventManager.on(Event.Change, callback);\n }\n return () => {\n isFn(callback) && eventManager.off(Event.Change, callback);\n };\n};\n\n/**\n * Configure the ToastContainer when lazy mounted\n */\ntoast.configure = (config: ToastContainerProps = {}) => {\n lazy = true;\n containerConfig = config;\n};\n\ntoast.POSITION = POSITION;\ntoast.TYPE = TYPE;\n\n/**\n * Wait until the ToastContainer is mounted to dispatch the toast\n * and attach isActive method\n */\neventManager\n .on(Event.DidMount, (containerInstance: ContainerInstance) => {\n latestInstance = containerInstance.containerId || containerInstance;\n containers.set(latestInstance, containerInstance);\n\n queue.forEach(item => {\n eventManager.emit(Event.Show, item.content, item.options);\n });\n\n queue = [];\n })\n .on(Event.WillUnmount, (containerInstance: ContainerInstance) => {\n containers.delete(containerInstance.containerId || containerInstance);\n\n if (containers.size === 0) {\n eventManager\n .off(Event.Show)\n .off(Event.Clear)\n .off(Event.ClearWaitingQueue);\n }\n\n if (canUseDom && containerDomNode) {\n document.body.removeChild(containerDomNode);\n }\n });\n\nexport { toast };\n","export default function _defineProperty(obj, key, value) {\n if (key in obj) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n } else {\n obj[key] = value;\n }\n\n return obj;\n}","import { useCallback } from 'react';\nimport * as R from 'ramda';\n\nimport { uuid } from '@eventespresso/utils';\n\nimport { DataStateReducer, StateInitializer, DataState, DefaultTicket } from './types';\n\nexport const initialState: DataState = {\n\tdeletedTickets: [],\n\ttickets: {},\n\tisDirty: false,\n};\n\nconst useDataStateReducer = (initializer: StateInitializer): DataStateReducer => {\n\treturn useCallback(\n\t\t(state, action) => {\n\t\t\tconst { id, ticket, type } = action;\n\t\t\tlet ticketId: string, newState: DataState, existingTicket: DefaultTicket;\n\n\t\t\tswitch (type) {\n\t\t\t\tcase 'ADD_TICKET':\n\t\t\t\tcase 'UPDATE_TICKET':\n\t\t\t\t\t// use id to update and uuid to add new\n\t\t\t\t\tticketId = id || uuid();\n\t\t\t\t\texistingTicket = R.path(['tickets', ticketId], state);\n\t\t\t\t\t// we need to make the id inside ticket and in tickets object same\n\t\t\t\t\tnewState = R.assocPath(\n\t\t\t\t\t\t['tickets', ticketId],\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t...existingTicket,\n\t\t\t\t\t\t\t...ticket,\n\t\t\t\t\t\t\tid: ticketId,\n\t\t\t\t\t\t\tisModified: Boolean(id),\n\t\t\t\t\t\t\tisDefault: true,\n\t\t\t\t\t\t},\n\t\t\t\t\t\tstate\n\t\t\t\t\t);\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase 'DELETE_TICKET':\n\t\t\t\t\tnewState = {\n\t\t\t\t\t\t...state,\n\t\t\t\t\t\ttickets: R.omit([id], state.tickets),\n\t\t\t\t\t};\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase 'ADD_TICKET_TO_DELETED':\n\t\t\t\t\tif (state.deletedTickets.includes(id)) {\n\t\t\t\t\t\tnewState = state;\n\t\t\t\t\t} else {\n\t\t\t\t\t\tnewState = {\n\t\t\t\t\t\t\t...state,\n\t\t\t\t\t\t\tdeletedTickets: [...state.deletedTickets, id],\n\t\t\t\t\t\t};\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase 'RESET':\n\t\t\t\t\treturn initializer(initialState);\n\t\t\t\tdefault:\n\t\t\t\t\tthrow new Error('Unexpected action');\n\t\t\t}\n\n\t\t\treturn { ...newState, isDirty: true };\n\t\t},\n\t\t[initializer]\n\t);\n};\n\nexport default useDataStateReducer;\n","import { useCallback, useMemo, useReducer } from 'react';\n\nimport type { DataStateManager, DataStateManagerHook } from './types';\nimport useDataReducer, { initialState } from './useDataStateReducer';\nimport useInitialState from './useInitialState';\n\ntype DSM = DataStateManager;\n\nconst useDataStateManager: DataStateManagerHook = () => {\n\tconst initializer = useInitialState();\n\tconst dataReducer = useDataReducer(initializer);\n\tconst [state, dispatch] = useReducer(dataReducer, initialState, initializer);\n\n\tconst getData: DSM['getData'] = useCallback(() => state, [state]);\n\n\tconst addTicket: DSM['addTicket'] = useCallback((ticket) => {\n\t\tdispatch({\n\t\t\ttype: 'ADD_TICKET',\n\t\t\tticket,\n\t\t});\n\t}, []);\n\n\tconst updateTicket: DSM['updateTicket'] = useCallback((id, ticket) => {\n\t\tdispatch({\n\t\t\ttype: 'UPDATE_TICKET',\n\t\t\tid,\n\t\t\tticket,\n\t\t});\n\t}, []);\n\n\tconst deleteTicket: DSM['deleteTicket'] = useCallback((id, isNew) => {\n\t\tif (!isNew) {\n\t\t\tdispatch({\n\t\t\t\ttype: 'ADD_TICKET_TO_DELETED',\n\t\t\t\tid,\n\t\t\t});\n\t\t}\n\t\tdispatch({\n\t\t\ttype: 'DELETE_TICKET',\n\t\t\tid,\n\t\t});\n\t}, []);\n\n\tconst reset: DSM['reset'] = useCallback(() => {\n\t\tdispatch({ type: 'RESET' });\n\t}, []);\n\n\treturn useMemo(\n\t\t() => ({\n\t\t\t...state,\n\t\t\taddTicket,\n\t\t\tdeleteTicket,\n\t\t\tgetData,\n\t\t\tupdateTicket,\n\t\t\treset,\n\t\t}),\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\t\t[state]\n\t);\n};\n\nexport default useDataStateManager;\n","import { FilterStateReducer } from './types';\n\nconst reducer: FilterStateReducer = (state, action) => {\n\tconst { type, datesByMonth, showTrashedDates, showExpiredTickets, showTrashedTickets } = action;\n\n\tswitch (type) {\n\t\tcase 'SET_DATES_BY_MONTH':\n\t\t\treturn { ...state, datesByMonth };\n\n\t\tcase 'SET_SHOW_TRASHED_DATES':\n\t\t\treturn { ...state, showTrashedDates };\n\n\t\tcase 'SET_SHOW_EXPIRED_TICKETS':\n\t\t\treturn { ...state, showExpiredTickets };\n\n\t\tcase 'SET_SHOW_TRASHED_TICKETS':\n\t\t\treturn { ...state, showTrashedTickets };\n\n\t\tdefault:\n\t\t\tthrow new Error('Unexpected action');\n\t}\n};\n\nexport default reducer;\n","import { useCallback, useMemo, useReducer } from 'react';\n\nimport { FilterState, FilterStateManager, FilterStateManagerHook } from './types';\nimport reducer from './reducer';\n\ntype FSM = FilterStateManager;\n\nconst initialState: FilterState = {\n\tdatesByMonth: [0, 0],\n\tshowExpiredTickets: false,\n\tshowTrashedDates: false,\n\tshowTrashedTickets: false,\n};\n\nconst useFilterStateManager: FilterStateManagerHook = () => {\n\tconst [state, dispatch] = useReducer(reducer, initialState);\n\n\tconst setDatesByMonth: FSM['setDatesByMonth'] = useCallback((datesByMonth) => {\n\t\tconst [year, month] = datesByMonth.split(':').map(Number);\n\n\t\tdispatch({\n\t\t\ttype: 'SET_DATES_BY_MONTH',\n\t\t\tdatesByMonth: [year, month],\n\t\t});\n\t}, []);\n\n\tconst setShowExpiredTickets: FSM['setShowExpiredTickets'] = useCallback((showExpiredTickets) => {\n\t\tdispatch({\n\t\t\ttype: 'SET_SHOW_EXPIRED_TICKETS',\n\t\t\tshowExpiredTickets,\n\t\t});\n\t}, []);\n\n\tconst setShowTrashedDates: FSM['setShowTrashedDates'] = useCallback((showTrashedDates) => {\n\t\tdispatch({\n\t\t\ttype: 'SET_SHOW_TRASHED_DATES',\n\t\t\tshowTrashedDates,\n\t\t});\n\t}, []);\n\n\tconst setShowTrashedTickets: FSM['setShowTrashedTickets'] = useCallback((showTrashedTickets) => {\n\t\tdispatch({\n\t\t\ttype: 'SET_SHOW_TRASHED_TICKETS',\n\t\t\tshowTrashedTickets,\n\t\t});\n\t}, []);\n\n\treturn useMemo(\n\t\t() => ({\n\t\t\t...state,\n\t\t\tsetDatesByMonth,\n\t\t\tsetShowExpiredTickets,\n\t\t\tsetShowTrashedDates,\n\t\t\tsetShowTrashedTickets,\n\t\t}),\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\t\t[state]\n\t);\n};\n\nexport default useFilterStateManager;\n","(function() { module.exports = window[\"eventespresso\"][\"formBuilder\"]; }());","var baseIsNative = require('./_baseIsNative'),\n getValue = require('./_getValue');\n\n/**\n * Gets the native function at `key` of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {string} key The key of the method to get.\n * @returns {*} Returns the function if it's native, else `undefined`.\n */\nfunction getNative(object, key) {\n var value = getValue(object, key);\n return baseIsNative(value) ? value : undefined;\n}\n\nmodule.exports = getNative;\n","export default function requiredArgs(required, args) {\n if (args.length < required) {\n throw new TypeError(required + ' argument' + (required > 1 ? 's' : '') + ' required, but only ' + args.length + ' present');\n }\n}","var baseHas = require('./_baseHas'),\n hasPath = require('./_hasPath');\n\n/**\n * Checks if `path` is a direct property of `object`.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Object\n * @param {Object} object The object to query.\n * @param {Array|string} path The path to check.\n * @returns {boolean} Returns `true` if `path` exists, else `false`.\n * @example\n *\n * var object = { 'a': { 'b': 2 } };\n * var other = _.create({ 'a': _.create({ 'b': 2 }) });\n *\n * _.has(object, 'a');\n * // => true\n *\n * _.has(object, 'a.b');\n * // => true\n *\n * _.has(object, ['a', 'b']);\n * // => true\n *\n * _.has(other, 'a');\n * // => false\n */\nfunction has(object, path) {\n return object != null && hasPath(object, path, baseHas);\n}\n\nmodule.exports = has;\n","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst CloseOutlined = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(CloseOutlined, 'close-outlined');\n","var g;\n\n// This works in non-strict mode\ng = (function() {\n\treturn this;\n})();\n\ntry {\n\t// This works if eval is allowed (see CSP)\n\tg = g || new Function(\"return this\")();\n} catch (e) {\n\t// This works if the window reference is available\n\tif (typeof window === \"object\") g = window;\n}\n\n// g can still be undefined, but nothing to do about it...\n// We return undefined, instead of nothing here, so it's\n// easier to handle this case. if(!global) { ...}\n\nmodule.exports = g;\n","(function() { module.exports = window[\"eventespresso\"][\"edtrServices\"]; }());","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst Link = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(Link, 'link');\n","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst Unlink = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(Unlink, 'unlink');\n","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst Calculator = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(Calculator, 'calculator');\n","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst MapMarker = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(MapMarker, 'map-marker');\n","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst Calendar = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(Calendar, 'calendar');\n","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst CalendarOutlined = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(CalendarOutlined, 'calendar-outlined');\n","export * from './ContextProvider';\nexport * from './DataStateProvider';\nexport * from './FilterStateProvider';\n\nexport { default as withContext } from './withContext';\n\nexport { default as useTAMContext } from './useTAMContext';\n\nexport * from './types';\n","/* eslint-disable \nno-unused-vars,\nno-native-reassign,\nno-global-assign,\n@typescript-eslint/no-unused-vars,\nno-var\n*/\n/* global __webpack_public_path__ */\ndeclare var __webpack_public_path__: string;\nlet assetsUrl = window.baristaAssetsUrl || window?.eventEspressoData?.config?.coreDomain?.distributionAssetsUrl;\n\n__webpack_public_path__ = assetsUrl;\n\n// not needed\nexport default assetsUrl = __webpack_public_path__;\n\ndeclare global {\n\tinterface Window {\n\t\tbaristaAssetsUrl: string;\n\t}\n}\n","import type { SVGProps } from 'react';\n\nexport interface IconProps extends SVGProps {\n\tclassName?: string;\n\tcolor?: string;\n\tname?: IconName | keyof SvgPath;\n\tnoMargin?: boolean;\n\tsize?: IconSize;\n\tsvgSize?: number;\n\tviewBox?: string;\n}\n\nexport enum IconName {\n\tCALENDAR = 'calendar',\n\tCALCULATOR = 'calculator',\n\tEDIT = 'edit',\n\tFILTER = 'filter',\n\tGROUPS = 'groups',\n\tTICKET = 'ticket-alt',\n}\n\nexport type IconSize = 'big' | 'bigger' | 'small' | 'smaller' | 'tiny';\n\nexport type SvgPath = {\n\t[key in IconName]: string;\n};\n\nexport type IconComponent = React.ComponentType;\n","import { ModalSubscription, ModalRegistry } from '@eventespresso/registry';\nimport { domain } from '@eventespresso/edtr-services';\n\nconst { getSubscriptions } = new ModalSubscription(domain);\nconst registry = new ModalRegistry({ domain });\n\nexport const getRegisteredContainers = (): Array => {\n\tconst { generateElements } = registry;\n\n\tconst subscriptions = getSubscriptions();\n\n\tObject.values(subscriptions).forEach(({ callback }) => {\n\t\tcallback({ registry });\n\t});\n\n\treturn generateElements();\n};\n","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst Ticket = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(Ticket, 'ticket');\n","import { useMemo } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { EMPTY_OBJECT } from '@eventespresso/constants';\nimport { Button, NewEntityOption } from '@eventespresso/ui-components';\nimport { EdtrGlobalModals, hooks } from '@eventespresso/edtr-services';\nimport { useGlobalModal } from '@eventespresso/registry';\nimport { Calendar } from '@eventespresso/icons';\n\nimport { EntityEditModalData } from '@edtrUI/types';\n\ntype AddSingleDateProps = {\n\tisOnlyButton?: boolean;\n};\n\nconst AddSingleDate: React.FC = ({ isOnlyButton }) => {\n\tconst { open } = useGlobalModal(EdtrGlobalModals.EDIT_DATE);\n\n\tconst output = useMemo(() => {\n\t\tconst additionalProps = hooks.applyFilters('eventEditor.addSingleDate.buttonProps', EMPTY_OBJECT, isOnlyButton);\n\n\t\treturn hooks.applyFilters(\n\t\t\t// replacement filter for the button.\n\t\t\t'eventEditor.addSingleDate.button',\n\t\t\t,\n\t\t\tisOnlyButton\n\t\t);\n\t}, [isOnlyButton, open]);\n\n\tif (isOnlyButton) {\n\t\treturn output;\n\t}\n\n\treturn (\n\t\t\n\t\t\t{output}\n\t\t\n\t);\n};\n\nexport default AddSingleDate;\n","import { useCallback } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { Button } from '@eventespresso/ui-components';\nimport { useGlobalModal } from '@eventespresso/registry';\nimport { Calendar } from '@eventespresso/icons';\nimport { EdtrGlobalModals } from '@eventespresso/edtr-services';\n\nconst OptionsModalButton: React.FC = ({ children }) => {\n\tconst { openWithData } = useGlobalModal(EdtrGlobalModals.NEW_DATE);\n\n\tconst onClick = useCallback(() => {\n\t\topenWithData({ children });\n\t}, [children, openWithData]);\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default OptionsModalButton;\n","import OptionsModalButton from './OptionsModalButton';\nimport { NewDateOptions } from '@eventespresso/edtr-services';\n\nconst NewDateButton: React.FC = () => {\n\treturn (\n\t\t\n\t\t\t{(fills) => {\n\t\t\t\tif (fills.length > 1) {\n\t\t\t\t\treturn {fills};\n\t\t\t\t}\n\t\t\t\treturn <>{fills};\n\t\t\t}}\n\t\t\n\t);\n};\n\nexport default NewDateButton;\n","import { __ } from '@eventespresso/i18n';\n\nimport { NewEntityModal } from '@eventespresso/ui-components';\nimport { useGlobalModal } from '@eventespresso/registry';\nimport { EdtrGlobalModals } from '@eventespresso/edtr-services';\n\nconst NewDateModal: React.FC = () => {\n\tconst { isOpen, close, getData } = useGlobalModal(EdtrGlobalModals.NEW_DATE);\n\n\treturn (\n\t\tisOpen && (\n\t\t\t\n\t\t\t\t{getData().children}\n\t\t\t\n\t\t)\n\t);\n};\n\nexport default NewDateModal;\n","import { useCallback } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\n\nimport { Ticket } from '@eventespresso/icons';\nimport { Button, ButtonRow } from '@eventespresso/ui-components';\nimport { USE_ADVANCED_EDITOR } from '@eventespresso/constants';\nimport { EdtrGlobalModals, useDatetimes, useTickets } from '@eventespresso/edtr-services';\nimport { useGlobalModal } from '@eventespresso/registry';\nimport { withCurrentUserCan } from '@eventespresso/services';\n\nimport { BaseProps } from '../../ticketAssignmentsManager';\nimport { NewDateButton } from './newDateOptions';\n\nconst DatesListButtons: React.FC = () => {\n\tconst { openWithData } = useGlobalModal(EdtrGlobalModals.TAM);\n\n\tconst datetimes = useDatetimes();\n\tconst tickets = useTickets();\n\tconst isDisabled = !datetimes.length || !tickets.length;\n\n\tconst tooltip = isDisabled && __('Add a date or a ticket in order to use Ticket Assignment Manager');\n\n\tconst onOpen = useCallback(() => {\n\t\topenWithData({ assignmentType: 'forAll' });\n\t}, [openWithData]);\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withCurrentUserCan(USE_ADVANCED_EDITOR)(DatesListButtons);\n","import { useDatetimes } from '@eventespresso/edtr-services';\nimport { EntityCacheIds } from '@eventespresso/ee-components';\n\nimport DatesListButtons from './DatesListButtons';\n\nconst DatesListFooter: React.FC = () => {\n\tconst entities = useDatetimes();\n\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default DatesListFooter;\n","import { IconName, Trash } from '@eventespresso/icons';\nimport { LegendConfig } from '@eventespresso/ui-components';\nimport { __ } from '@eventespresso/i18n';\n\nexport const legendConfig: LegendConfig = {\n\ticons: [\n\t\t{ icon: IconName.EDIT, description: __('Edit Event Date Details') },\n\t\t{ icon: IconName.GROUPS, description: __('View Registrations for this Date') },\n\t\t{ icon: IconName.TICKET, description: __('Manage Ticket Assignments') },\n\t\t{ icon: Trash, description: __('Move Date to Trash') },\n\t],\n\tswatches: {\n\t\tDTA: __('Active'),\n\t\tDTT: __('Trashed'),\n\t\tDTE: __('Expired'),\n\t\tDTS: __('Sold Out'),\n\t\tDTU: __('Upcoming'),\n\t},\n};\n","import { lazy, Suspense } from 'react';\n\nimport { LoadingNotice } from '@eventespresso/ui-components';\n\nconst CardView = lazy(() => import(/* webpackChunkName: \"dates-card-view\" */ './CardView'));\n\nconst RenderCardView: React.FC = () => {\n\treturn (\n\t\t}>\n\t\t\t\n\t\t\n\t);\n};\n\nexport default RenderCardView;\n","import { lazy, Suspense } from 'react';\n\nimport { LoadingNotice } from '@eventespresso/ui-components';\n\nconst TableView = lazy(() => import(/* webpackChunkName: \"dates-table-view\" */ './TableView'));\n\nconst RenderTableView: React.FC = () => {\n\treturn (\n\t\t}>\n\t\t\t\n\t\t\n\t);\n};\n\nexport default RenderTableView;\n","/* eslint-disable @wordpress/i18n-translator-comments */\nimport { __ } from '@eventespresso/i18n';\n\nimport { DisplayStartOrEndDate } from '@eventespresso/edtr-services';\n\nimport { DatetimeSales, DatetimeStatus } from '@eventespresso/predicates';\n\nexport const displayStartOrEndDateOptions = {\n\t[DisplayStartOrEndDate.start]: __('start dates only'),\n\t[DisplayStartOrEndDate.end]: __('end dates only'),\n\t[DisplayStartOrEndDate.both]: __('start and end dates'),\n};\n\nexport const salesOptions = {\n\t[DatetimeSales.all]: __('all dates'),\n\t[DatetimeSales.above90Capacity]: __('dates above 90% capacity'),\n\t[DatetimeSales.above75Capacity]: __('dates above 75% capacity'),\n\t[DatetimeSales.above50Capacity]: __('dates above 50% capacity'),\n\t[DatetimeSales.below50Capacity]: __('dates below 50% capacity'),\n};\n\nexport const statusOptions = {\n\t[DatetimeStatus.all]: __('all dates'),\n\t[DatetimeStatus.activeUpcoming]: __('all active and upcoming'),\n\t[DatetimeStatus.activeOnly]: __('active dates only'),\n\t[DatetimeStatus.upcomingOnly]: __('upcoming dates only'),\n\t[DatetimeStatus.nextActiveUpcomingOnly]: __('next active or upcoming only'),\n\t[DatetimeStatus.soldOutOnly]: __('sold out dates only'),\n\t[DatetimeStatus.recentlyExpiredOnly]: __('recently expired dates'),\n\t[DatetimeStatus.expiredOnly]: __('all expired dates'),\n\t[DatetimeStatus.trashedOnly]: __('trashed dates only'),\n};\n\nexport const sortByOptions = {\n\tdate: __('start date'),\n\tname: __('name'),\n\tid: __('ID'),\n\torder: __('custom order'),\n};\n\nexport const labels = {\n\tdisplayStartOrEndDate: __('display'),\n\trecurrence: __('recurrence'),\n\tsales: __('sales'),\n\tsortBy: __('sort by'),\n\tsearch: __('search'),\n\tstatus: __('status'),\n};\n","import { useCallback } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { ActiveFilters, FilterTag } from '@eventespresso/ui-components';\nimport { useDatesListFilterState } from '@eventespresso/edtr-services';\nimport { DatetimeSales, DatetimeStatus } from '@eventespresso/predicates';\n\nimport { labels, statusOptions, salesOptions } from './controls/options';\n\nconst ActiveDatesFilters: React.FC = () => {\n\tconst { status, setStatus, sales, setSales, searchText, setSearchText, recurrence, setRecurrence } =\n\t\tuseDatesListFilterState();\n\n\tconst statusTitle = `${labels.status}: ${statusOptions?.[status]}`;\n\tconst salesTitle = `${labels.sales}: ${salesOptions?.[sales]}`;\n\tconst searchTitle = `${labels.search}: ${searchText}`;\n\tconst recurrenceTitle = `${labels.recurrence}: ${__('ON')}`;\n\n\tconst onRemoveStatus = useCallback(() => setStatus(DatetimeStatus.all), [setStatus]);\n\tconst onRemoveSales = useCallback(() => setSales(DatetimeSales.all), [setSales]);\n\tconst onRemoveRecurrence = useCallback(() => setRecurrence(''), [setRecurrence]);\n\tconst onRemoveSearch = useCallback(() => setSearchText(''), [setSearchText]);\n\n\treturn (\n\t\t\n\t\t\t{status !== DatetimeStatus.all && }\n\t\t\t{sales !== DatetimeSales.all && }\n\t\t\t{recurrence && }\n\t\t\t{searchText ? : null}\n\t\t\n\t);\n};\n\nexport default ActiveDatesFilters;\n","import { SelectWithLabel } from '@eventespresso/ui-components';\nimport { useDatesListFilterState } from '@eventespresso/edtr-services';\nimport { objectToSelectOptions } from '@eventespresso/utils';\n\nimport { labels, displayStartOrEndDateOptions } from './options';\n\nconst options = objectToSelectOptions(displayStartOrEndDateOptions);\n/**\n * filter for controlling which dates display in a list of Event Dates\n */\nconst DisplayStartOrEndDateControl: React.FC = () => {\n\tconst { displayStartOrEndDate, setDisplayStartOrEndDate } = useDatesListFilterState();\n\n\treturn (\n\t\t\n\t);\n};\nexport default DisplayStartOrEndDateControl;\n","import { SelectWithLabel } from '@eventespresso/ui-components';\nimport { useDatesListFilterState } from '@eventespresso/edtr-services';\nimport { objectToSelectOptions } from '@eventespresso/utils';\n\nimport { labels, salesOptions } from './options';\n\nconst options = objectToSelectOptions(salesOptions);\n\nconst SalesControl: React.FC = () => {\n\tconst { sales, setSales } = useDatesListFilterState();\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default SalesControl;\n","import { SelectWithLabel } from '@eventespresso/ui-components';\nimport { useDatesListFilterState } from '@eventespresso/edtr-services';\nimport { objectToSelectOptions } from '@eventespresso/utils';\n\nimport { labels, statusOptions } from './options';\nconst options = objectToSelectOptions(statusOptions);\n\nconst StatusControl: React.FC = () => {\n\tconst { status, setStatus } = useDatesListFilterState();\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default StatusControl;\n","import { RangeFormat } from '@eventespresso/ee-components';\nimport type { Datetime } from '@eventespresso/edtr-services';\n\nconst formatTokens = { month: 'LLL' };\n\nconst DraggableDatetime: React.FC = ({ dbId, endDate, name, startDate }) => (\n\t<>\n\t\t{dbId})\n\t\t{name}: \n\t\t\n\t\n);\n\nexport default DraggableDatetime;\n","import { SortByControl as SortByControlUI } from '@eventespresso/ee-components';\nimport type { SortByControlProps } from '@eventespresso/ee-components';\nimport {\n\tuseDatesListFilterState,\n\tuseFilteredDateIds,\n\tuseReorderDatetimes,\n\tDatetime,\n} from '@eventespresso/edtr-services';\nimport { objectToSelectOptions } from '@eventespresso/utils';\nimport { datetimesDroppableId } from '@eventespresso/constants';\nimport { TypeName } from '@eventespresso/services';\n\nimport { labels, sortByOptions } from '../options';\nimport DraggableDatetime from './DraggableDatetime';\n\nconst options = objectToSelectOptions(sortByOptions);\n\nconst renderDraggableItem: SortByControlProps['renderDraggableItem'] = (datetime) => ({\n\t...datetime,\n\tcontent: ,\n});\n\nconst SortByControl: React.FC = () => {\n\tconst { sortBy, setSortBy } = useDatesListFilterState();\n\tconst filteredDateIds = useFilteredDateIds();\n\tconst {\n\t\tallReorderedEntities: draggableItems,\n\t\tsortResponder,\n\t\tupdateEntityList,\n\t} = useReorderDatetimes(filteredDateIds);\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default SortByControl;\n","import { useCallback } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { TypeName } from '@eventespresso/services';\nimport {\n\tdomain,\n\tdatesList,\n\tDatetimesListProvider,\n\twithEntityListContext,\n\tuseDatesListFilterState,\n} from '@eventespresso/edtr-services';\nimport { EntityList } from '@eventespresso/ee-components';\n\nimport DatesListFooter from './DatesListFooter';\nimport { legendConfig } from './config';\nimport { RenderCardView } from './cardView';\nimport { RenderTableView } from './tableView';\nimport { ActiveDatesFilters } from './filterBar';\n\nconst DatesList: React.FC = () => {\n\tconst filterState = useDatesListFilterState();\n\n\tconst renderList = useCallback(\n\t\t() => (filterState.view === 'card' ? : ),\n\t\t[filterState.view]\n\t);\n\n\treturn (\n\t\t}\n\t\t\tdomain={domain}\n\t\t\tentityType={TypeName.datetimes}\n\t\t\tfilterState={filterState}\n\t\t\tfooter={}\n\t\t\theaderText={__('Event Dates')}\n\t\t\tlegendConfig={legendConfig}\n\t\t\tlistId={datesList}\n\t\t\tloadingText={__('loading event dates…')}\n\t\t\trenderList={renderList}\n\t\t/>\n\t);\n};\n\nexport default withEntityListContext({\n\tProvider: DatetimesListProvider,\n\tComponent: DatesList,\n});\n","import { useMemo } from 'react';\nimport classNames from 'classnames';\n\nimport { __ } from '@eventespresso/i18n';\nimport { SelectWithLabel } from '@eventespresso/ui-components';\nimport { datetimeStatus } from '@eventespresso/constants';\nimport { objectToSelectOptions } from '@eventespresso/utils';\nimport { datetimeStatusBgColorClassName } from '@eventespresso/helpers';\nimport type { EventRegistrationOptionsProps } from './types';\n\ninterface Props extends Pick {}\n\nconst ActiveStatus: React.FC = ({ status, onStatusChange }) => {\n\tconst className = classNames(\n\t\t'ee-edtr-option',\n\t\t'ee-edtr-option__active-status',\n\t\tdatetimeStatusBgColorClassName(null)\n\t);\n\n\tconst options = useMemo(() => objectToSelectOptions(datetimeStatus), []);\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default ActiveStatus;\n","import { __ } from '@eventespresso/i18n';\nimport { InlineEditTextWithLabel } from '@eventespresso/ui-components';\nimport type { EventRegistrationOptionsProps } from './types';\n\ninterface Props extends Pick {}\n\nconst AltRegPage: React.FC = ({ altRegPage, onAltRegPageChange }) => {\n\treturn (\n\t\t\n\t);\n};\n\nexport default AltRegPage;\n","import { useMemo } from 'react';\nimport { __ } from '@eventespresso/i18n';\nimport classNames from 'classnames';\nimport { SelectWithLabel } from '@eventespresso/ui-components';\nimport { regStatusOptions } from '@eventespresso/predicates';\nimport type { EventRegistrationOptionsProps } from './types';\n\ninterface Props extends Pick {}\n\nconst DefaultRegistrationStatus: React.FC = ({ defaultRegStatus, onDefaultRegStatusChange }) => {\n\tconst regStatusCode = useMemo(\n\t\t() => regStatusOptions.filter((option) => option.value === defaultRegStatus),\n\t\t[defaultRegStatus]\n\t);\n\tconst className = classNames(\n\t\t'ee-edtr-option ee-edtr-option__default-reg-status',\n\t\t`ee-status-bg--${regStatusCode[0]?.code}`\n\t);\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default DefaultRegistrationStatus;\n","import { __ } from '@eventespresso/i18n';\nimport { SwitchWithLabel } from '@eventespresso/ui-components';\nimport type { EventRegistrationOptionsProps } from './types';\n\ninterface Props extends Pick {}\n\nconst Donations: React.FC = ({ allowDonations: isChecked, onDonationsChange }) => {\n\tconst label = isChecked ? __('Donations Enabled') : __('Donations Disabled');\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default Donations;\n","import { useMemo } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { entityListToSelectOptions } from '@eventespresso/utils';\nimport { SelectWithLabel } from '@eventespresso/ui-components';\nimport type { EventRegistrationOptionsProps } from './types';\n\ninterface Props extends Pick {}\n\nconst EventManager: React.FC = ({ eventManagers, managerId, onManagerChange }) => {\n\tconst options = useMemo(() => eventManagers && entityListToSelectOptions(eventManagers), [eventManagers]);\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default EventManager;\n","import { __ } from '@eventespresso/i18n';\nimport { InlineEditTextWithLabel } from '@eventespresso/ui-components';\nimport type { EventRegistrationOptionsProps } from './types';\n\ninterface Props extends Pick {}\n\nconst EventPhoneNumber: React.FC = ({ onPhoneNumberChange, phoneNumber }) => {\n\treturn (\n\t\t\n\t);\n};\n\nexport default EventPhoneNumber;\n","import { __ } from '@eventespresso/i18n';\nimport { InlineEditTextWithLabel } from '@eventespresso/ui-components';\nimport type { EventRegistrationOptionsProps } from './types';\n\ninterface Props extends Pick {}\n\nconst MaxRegistrations: React.FC = ({ maxReg, onMaxRegChange }) => {\n\tconst strValue = maxReg && String(maxReg);\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default MaxRegistrations;\n","import { __ } from '@eventespresso/i18n';\nimport { SwitchWithLabel } from '@eventespresso/ui-components';\nimport type { EventRegistrationOptionsProps } from './types';\n\ninterface Props extends Pick {}\n\nconst TicketSelector: React.FC = ({ displayTicketSelector: isChecked, onTicketSelectorChange }) => {\n\tconst label = isChecked ? __('Ticket Selector Enabled') : __('Ticket Selector Disabled');\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default TicketSelector;\n","import { useCallback } from 'react';\n\nimport { useEvent, useEventManagers, useEventMutator } from '@eventespresso/edtr-services';\nimport type { InlineEditProps, SwitchProps } from '@eventespresso/adapters';\nimport type { AnyObject } from '@eventespresso/utils';\nimport type { EventRegistrationOptionsProps } from './types';\n\nconst withData =

(\n\tWrappedComponent: React.ComponentType\n): React.ComponentType

=> {\n\tconst WithData: React.FC

= () => {\n\t\tconst event = useEvent();\n\t\tconst eventManagers = useEventManagers();\n\n\t\tconst { updateEntity: updateEvent } = useEventMutator(event?.id);\n\n\t\tconst onAltRegPageChange = useCallback(\n\t\t\t(newAltRegPage) => {\n\t\t\t\tif (newAltRegPage !== event?.altRegPage) {\n\t\t\t\t\tupdateEvent({ altRegPage: newAltRegPage });\n\t\t\t\t}\n\t\t\t},\n\t\t\t[event?.altRegPage, updateEvent]\n\t\t);\n\n\t\tconst onDonationsChange = useCallback(\n\t\t\t(allowDonations) => {\n\t\t\t\tif (event?.allowDonations !== allowDonations) {\n\t\t\t\t\tupdateEvent({ allowDonations });\n\t\t\t\t}\n\t\t\t},\n\t\t\t[event?.allowDonations, updateEvent]\n\t\t);\n\n\t\tconst onDefaultRegStatusChange = useCallback(\n\t\t\t(defaultRegStatus) => {\n\t\t\t\tif (event?.defaultRegStatus !== defaultRegStatus) {\n\t\t\t\t\tupdateEvent({ defaultRegStatus });\n\t\t\t\t}\n\t\t\t},\n\t\t\t[event?.defaultRegStatus, updateEvent]\n\t\t);\n\n\t\tconst onManagerChange = useCallback(\n\t\t\t(newManagerId): void => {\n\t\t\t\tif (newManagerId !== event?.manager?.id) {\n\t\t\t\t\tupdateEvent({ manager: newManagerId }); // TODO - check this mutation because manager is an object with properties id and name\n\t\t\t\t}\n\t\t\t},\n\t\t\t[event?.manager?.id, updateEvent]\n\t\t);\n\n\t\tconst onMaxRegChange = useCallback(\n\t\t\t(newMaxRegistrations) => {\n\t\t\t\tconst maxRegistrations = Number(newMaxRegistrations);\n\t\t\t\tif (maxRegistrations !== event?.maxRegistrations) {\n\t\t\t\t\tupdateEvent({ maxRegistrations });\n\t\t\t\t}\n\t\t\t},\n\t\t\t[event?.maxRegistrations, updateEvent]\n\t\t);\n\n\t\tconst onPhoneNumberChange = useCallback(\n\t\t\t(newPhoneNumber) => {\n\t\t\t\tif (newPhoneNumber !== event?.phoneNumber) {\n\t\t\t\t\tupdateEvent({ phoneNumber: newPhoneNumber });\n\t\t\t\t}\n\t\t\t},\n\t\t\t[event?.phoneNumber, updateEvent]\n\t\t);\n\n\t\tconst onStatusChange = useCallback(\n\t\t\t(status) => {\n\t\t\t\tif (status !== event?.status) {\n\t\t\t\t\tupdateEvent({ status });\n\t\t\t\t}\n\t\t\t},\n\t\t\t[event?.status, updateEvent]\n\t\t);\n\n\t\tconst onTicketSelectorChange = useCallback(\n\t\t\t(displayTicketSelector) => {\n\t\t\t\tif (event?.displayTicketSelector !== displayTicketSelector) {\n\t\t\t\t\tupdateEvent({ displayTicketSelector });\n\t\t\t\t}\n\t\t\t},\n\t\t\t[event?.displayTicketSelector, updateEvent]\n\t\t);\n\n\t\treturn (\n\t\t\t\n\t\t);\n\t};\n\n\treturn WithData;\n};\n\nexport default withData;\n","import { __ } from '@eventespresso/i18n';\nimport { Grid, GridCard } from '@eventespresso/ui-components';\nimport { noop } from '@eventespresso/utils';\nimport { withFeature } from '@eventespresso/services';\n\nimport ActiveStatus from './ActiveStatus';\nimport AltRegPage from './AltRegPage';\nimport DefaultRegistrationStatus from './DefaultRegistrationStatus';\nimport Donations from './Donations';\nimport EventManager from './EventManager';\nimport EventPhoneNumber from './EventPhoneNumber';\nimport MaxRegistrations from './MaxRegistrations';\nimport TicketSelector from './TicketSelector';\nimport withData from './withData';\n\nimport type { EventRegistrationOptionsProps } from './types';\n\nimport './style.scss';\n\nexport const EventRegistrationOptions: React.FC> = ({\n\tallowDonations,\n\taltRegPage,\n\tdefaultRegStatus,\n\tdisplayTicketSelector,\n\teventManagers,\n\tmanagerId,\n\tmaxReg,\n\tonAltRegPageChange = noop,\n\tonDefaultRegStatusChange,\n\tonDonationsChange,\n\tonManagerChange,\n\tonPhoneNumberChange,\n\tonStatusChange,\n\tonTicketSelectorChange,\n\tonMaxRegChange = noop,\n\tphoneNumber,\n\tstatus,\n}) => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withFeature('use_reg_options_meta_box')(withData(EventRegistrationOptions));\n","import { useNewEntityOptionItems } from '@edtrHooks/index';\n\nconst useNewTicketOptionItems = (): Array => {\n\treturn useNewEntityOptionItems('ticket');\n};\n\nexport default useNewTicketOptionItems;\n","const style = { margin: '5px', border: '1px solid red' };\nconst OptionsModal: React.FC = ({ children }) => {\n\t// TODO convert this to modal\n\treturn

{children}
;\n};\n\nexport default OptionsModal;\n","import useNewTicketOptionItems from '@edtrUI/tickets/hooks/useNewTicketOptionItems';\nimport OptionsModal from './OptionsModal';\n\nconst NewTicketButton: React.FC = () => {\n\tconst optionItems = useNewTicketOptionItems();\n\tif (optionItems.length > 1) {\n\t\treturn {optionItems};\n\t}\n\treturn <>{optionItems};\n};\n\nexport default NewTicketButton;\n","import { __ } from '@eventespresso/i18n';\n\nimport { Button, NewEntityOption } from '@eventespresso/ui-components';\nimport { Ticket } from '@eventespresso/icons';\nimport { useGlobalModal } from '@eventespresso/registry';\nimport { EntityEditModalData } from '@edtrUI/types';\nimport { EdtrGlobalModals } from '@eventespresso/edtr-services';\n\ntype AddSingleTicketProps = {\n\tisOnlyButton?: boolean;\n};\n\nconst AddSingleTicket: React.FC = ({ isOnlyButton }) => {\n\tconst { open } = useGlobalModal(EdtrGlobalModals.EDIT_TICKET);\n\n\tconst output = (\n\t\t\n\t);\n\n\tif (isOnlyButton) {\n\t\treturn output;\n\t}\n\n\treturn (\n\t\t\n\t\t\t{output}\n\t\t\n\t);\n};\n\nexport default AddSingleTicket;\n","import { __ } from '@eventespresso/i18n';\nimport { useGlobalModal } from '@eventespresso/registry';\nimport { DropdownMenu, DropdownMenuItem, DropdownMenuProps } from '@eventespresso/ui-components';\nimport { EdtrGlobalModals } from '@eventespresso/edtr-services';\nimport { withFeature, useCurrentUserCan } from '@eventespresso/services';\n\nconst toggleProps: DropdownMenuProps['toggleProps'] = {\n\tnoPadding: true,\n\tsize: 'big',\n};\n\nexport const Actions = () => {\n\tconst { open } = useGlobalModal(EdtrGlobalModals.DEFAULT_TICKETS);\n\n\tconst currentUserCan = useCurrentUserCan();\n\n\tconst canReadDefaultTickets = currentUserCan('read', 'default_tickets');\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\t{/* King's throne for other future items */}\n\t\t\n\t);\n};\n\n// Since we only have default tickets in that dropdown for now, lets hide it completely\nexport default withFeature('use_default_ticket_manager')(Actions);\n","import { useTickets } from '@eventespresso/edtr-services';\nimport { EntityCacheIds } from '@eventespresso/ee-components';\n\nimport { NewTicketButton } from './newTicketOptions';\nimport { Actions } from './actions';\n\nconst TicketsListFooter: React.FC = () => {\n\tconst entities = useTickets();\n\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default TicketsListFooter;\n","import { IconName, Trash } from '@eventespresso/icons';\nimport { LegendConfig } from '@eventespresso/ui-components';\nimport { __ } from '@eventespresso/i18n';\n\nexport const legendConfig: LegendConfig = {\n\ticons: [\n\t\t{ icon: IconName.EDIT, description: __('Edit Ticket Details') },\n\t\t{ icon: IconName.CALENDAR, description: __('Manage Date Assignments') },\n\t\t{ icon: IconName.CALCULATOR, description: __('Ticket Price Calculator') },\n\t\t{ icon: Trash, description: __('Move Ticket to Trash') },\n\t],\n\tswatches: {\n\t\tTKA: __('Trashed'),\n\t\tTKE: __('Expired'),\n\t\tTKO: __('On Sale'),\n\t\tTKS: __('Sold Out'),\n\t\tTKP: __('Pending'),\n\t},\n};\n","import { lazy, Suspense } from 'react';\n\nimport { LoadingNotice } from '@eventespresso/ui-components';\n\nconst CardView = lazy(() => import(/* webpackChunkName: \"tickets-card-view\" */ './CardView'));\n\nconst RenderCardView: React.FC = () => {\n\treturn (\n\t\t}>\n\t\t\t\n\t\t\n\t);\n};\n\nexport default RenderCardView;\n","import { lazy, Suspense } from 'react';\n\nimport { LoadingNotice } from '@eventespresso/ui-components';\n\nconst TableView = lazy(() => import(/* webpackChunkName: \"tickets-table-view\" */ './TableView'));\n\nconst RenderTableView: React.FC = () => {\n\treturn (\n\t\t}>\n\t\t\t\n\t\t\n\t);\n};\n\nexport default RenderTableView;\n","import { __ } from '@eventespresso/i18n';\n\nimport { DisplayStartOrEndDate } from '@eventespresso/edtr-services';\n\nimport { TicketsSales, TicketsStatus } from '@eventespresso/predicates';\n\nexport const displayStartOrEndDateOptions = {\n\t[DisplayStartOrEndDate.start]: __('ticket sales start date only'),\n\t[DisplayStartOrEndDate.end]: __('ticket sales end date only'),\n\t[DisplayStartOrEndDate.both]: __('ticket sales start and end dates'),\n};\n\nexport const salesOptions = {\n\t[TicketsSales.all]: __('all tickets for all dates'),\n\t[TicketsSales.above90Sold]: __('tickets with 90% or more sold'),\n\t[TicketsSales.above75Sold]: __('tickets with 75% or more sold'),\n\t[TicketsSales.above50Sold]: __('tickets with 50% or more sold'),\n\t// eslint-disable-next-line @wordpress/i18n-translator-comments\n\t[TicketsSales.below50Sold]: __('tickets with less than 50% sold'),\n};\n\nexport const salesIsChainedOptions = {\n\t...salesOptions,\n\t[TicketsSales.all]: __('all tickets for above dates'),\n};\n\nexport const statusOptions = {\n\t[TicketsStatus.all]: __('all tickets for all dates'),\n\t[TicketsStatus.onSaleAndPending]: __('all on sale and sale pending'),\n\t[TicketsStatus.onSaleOnly]: __('on sale tickets only'),\n\t[TicketsStatus.pendingOnly]: __('sale pending tickets only'),\n\t[TicketsStatus.nextOnSaleOrPendingOnly]: __('next on sale or sale pending only'),\n\t[TicketsStatus.soldOutOnly]: __('sold out tickets only'),\n\t[TicketsStatus.expiredOnly]: __('expired tickets only'),\n\t[TicketsStatus.trashedOnly]: __('trashed tickets only'),\n};\n\nexport const statusIsChainedOptions = {\n\t...statusOptions,\n\t[TicketsStatus.all]: __('all tickets for above dates'),\n};\n\nexport const sortByOptions = {\n\tdate: __('ticket sale date'),\n\tname: __('ticket name'),\n\tid: __('ticket ID'),\n\torder: __('custom order'),\n};\n\nexport const labels = {\n\tdisplayStartOrEndDate: __('display'),\n\tisChained: __('linked'),\n\tsales: __('sales'),\n\tsearch: __('search'),\n\tsortBy: __('sort by'),\n\tstatus: __('status'),\n};\n","import { useCallback } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { ActiveFilters, FilterTag } from '@eventespresso/ui-components';\nimport { useTicketsListFilterState } from '@eventespresso/edtr-services';\nimport { TicketsSales, TicketsStatus } from '@eventespresso/predicates';\n\nimport { labels, statusOptions, salesOptions } from './controls/options';\n\nconst ActiveTicketsSFilters: React.FC = () => {\n\tconst { status, setStatus, sales, setSales, searchText, setSearchText, isChained, toggleIsChained } =\n\t\tuseTicketsListFilterState();\n\n\tconst statusTitle = `${labels.status}: ${statusOptions?.[status]}`;\n\tconst salesTitle = `${labels.sales}: ${salesOptions?.[sales]}`;\n\tconst searchTitle = `${labels.search}: ${searchText}`;\n\tconst isChainedTitle = `${labels.isChained}: ${__('ON')}`;\n\n\tconst onRemoveStatus = useCallback(() => setStatus(TicketsStatus.all), [setStatus]);\n\tconst onRemoveSales = useCallback(() => setSales(TicketsSales.all), [setSales]);\n\tconst onRemoveSearch = useCallback(() => setSearchText(''), [setSearchText]);\n\n\treturn (\n\t\t\n\t\t\t{status !== TicketsStatus.all && }\n\t\t\t{sales !== TicketsSales.all && }\n\t\t\t{searchText ? : null}\n\t\t\t{isChained && }\n\t\t\n\t);\n};\n\nexport default ActiveTicketsSFilters;\n","import { SelectWithLabel } from '@eventespresso/ui-components';\nimport { useTicketsListFilterState } from '@eventespresso/edtr-services';\nimport { objectToSelectOptions } from '@eventespresso/utils';\n\nimport { labels, displayStartOrEndDateOptions } from './options';\n\nconst options = objectToSelectOptions(displayStartOrEndDateOptions);\n\n/**\n * filter for controlling which dates display in a list of Event Dates\n */\nconst DisplayStartOrEndDateControl: React.FC = () => {\n\tconst { displayStartOrEndDate, setDisplayStartOrEndDate } = useTicketsListFilterState();\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default DisplayStartOrEndDateControl;\n","import { SelectWithLabel } from '@eventespresso/ui-components';\nimport { useTicketsListFilterState } from '@eventespresso/edtr-services';\nimport { useMemoStringify } from '@eventespresso/hooks';\nimport { objectToSelectOptions } from '@eventespresso/utils';\n\nimport { labels, salesOptions, salesIsChainedOptions } from './options';\n\nconst SalesControl: React.FC = () => {\n\tconst { isChained, sales, setSales } = useTicketsListFilterState();\n\tconst options = useMemoStringify(objectToSelectOptions(isChained ? salesIsChainedOptions : salesOptions), [\n\t\tisChained,\n\t]);\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default SalesControl;\n","import { SelectWithLabel } from '@eventespresso/ui-components';\nimport { useTicketsListFilterState } from '@eventespresso/edtr-services';\nimport { useMemoStringify } from '@eventespresso/hooks';\nimport { objectToSelectOptions } from '@eventespresso/utils';\n\nimport { labels, statusOptions, statusIsChainedOptions } from './options';\n\nconst StatusControl: React.FC = () => {\n\tconst { isChained, status, setStatus } = useTicketsListFilterState();\n\tconst options = useMemoStringify(objectToSelectOptions(isChained ? statusIsChainedOptions : statusOptions), [\n\t\tisChained,\n\t]);\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default StatusControl;\n","import { CurrencyDisplay, RangeFormat } from '@eventespresso/ee-components';\nimport { Ticket } from '@eventespresso/edtr-services';\n\nconst formatTokens = { month: 'LLL' };\n\nconst DraggableTicket: React.FC = ({ dbId, endDate, name, price, startDate }) => (\n\t<>\n\t\t{dbId})\n\t\t{name}: \n\t\t\n\t\t\t\n\t\t\n\t\t-\n\t\t\n\t\n);\n\nexport default DraggableTicket;\n","import { SortByControl as SortByControlUI } from '@eventespresso/ee-components';\nimport {\n\tTicket,\n\tuseFilteredTicketIds,\n\tuseReorderTickets,\n\tuseTicketsListFilterState,\n} from '@eventespresso/edtr-services';\nimport { ticketDroppableId } from '@eventespresso/constants';\nimport { objectToSelectOptions } from '@eventespresso/utils';\nimport { TypeName } from '@eventespresso/services';\nimport type { SortByControlProps } from '@eventespresso/ee-components';\n\nimport { labels, sortByOptions } from '../options';\nimport DraggableTicket from './DraggableTicket';\n\nconst options = objectToSelectOptions(sortByOptions);\n\nconst renderDraggableItem: SortByControlProps['renderDraggableItem'] = (ticket) => ({\n\t...ticket,\n\tcontent: ,\n});\n\n/**\n * filter for controlling the sorting of a list of Event Dates\n */\nconst SortByControl: React.FC = () => {\n\tconst { sortBy, setSortBy } = useTicketsListFilterState();\n\tconst filteredTicketIds = useFilteredTicketIds();\n\tconst {\n\t\tallReorderedEntities: draggableItems,\n\t\tsortResponder,\n\t\tupdateEntityList,\n\t} = useReorderTickets(filteredTicketIds);\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default SortByControl;\n","import classNames from 'classnames';\nimport { __ } from '@eventespresso/i18n';\n\nimport { IconButton } from '@eventespresso/ui-components';\nimport { Link, Unlink } from '@eventespresso/icons';\nimport { useTicketsListFilterState } from '@eventespresso/edtr-services';\n\nimport { labels } from './options';\n\n/**\n * filter for controlling whether Tickets List is chained to the Dates List\n * if true, then only tickets that are related to the dates in the dates list\n * will appear, otherwise ALL tickets will appear (subject to other filters)\n */\nconst IsChainedButton: React.FC = () => {\n\tconst { isChained, toggleIsChained } = useTicketsListFilterState();\n\tconst className = classNames('ee-filter-bar__btn ee-filter-bar__chain', {\n\t\t'ee-filter-bar__btn--active': isChained,\n\t\t'ee-filter-bar__chain--active': isChained,\n\t});\n\tconst icon = isChained ? Link : Unlink;\n\tconst tooltip = isChained\n\t\t? __('tickets list is linked to dates list and is showing tickets for above dates only')\n\t\t: __('tickets list is unlinked and is showing tickets for all event dates');\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default IsChainedButton;\n","import { useCallback } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { TypeName } from '@eventespresso/services';\nimport {\n\tdomain,\n\tticketsList,\n\tTicketsListProvider,\n\twithEntityListContext,\n\tuseTicketsListFilterState,\n\tuseRegisterIsChainedFilter,\n} from '@eventespresso/edtr-services';\nimport { EntityList } from '@eventespresso/ee-components';\n\nimport TicketsListFooter from './TicketsListFooter';\nimport { legendConfig } from './config';\nimport { RenderCardView } from './cardView';\nimport { RenderTableView } from './tableView';\nimport { ActiveTicketsFilters } from './filterBar';\n\nconst TicketsList: React.FC = () => {\n\tconst filterState = useTicketsListFilterState();\n\n\tconst renderList = useCallback(\n\t\t() => (filterState.view === 'card' ? : ),\n\t\t[filterState.view]\n\t);\n\n\treturn (\n\t\t}\n\t\t\tdomain={domain}\n\t\t\tentityType={TypeName.tickets}\n\t\t\tfilterState={filterState}\n\t\t\tfooter={}\n\t\t\theaderText={__('Available Tickets')}\n\t\t\tlegendConfig={legendConfig}\n\t\t\tlistId={ticketsList}\n\t\t\tloadingText={__('loading tickets…')}\n\t\t\trenderList={renderList}\n\t\t/>\n\t);\n};\n\nconst EnhancedTicketsList = withEntityListContext({\n\tProvider: TicketsListProvider,\n\tComponent: TicketsList,\n});\n\nconst ChainedTicketsList: React.FC = () => {\n\t// register isChained filter using hook.\n\tuseRegisterIsChainedFilter();\n\treturn ;\n};\n\nexport default ChainedTicketsList;\n","import { useCallback, useEffect } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { AdvancedTextEditor } from '@eventespresso/ee-components';\nimport { Heading } from '@eventespresso/ui-components';\nimport { useEvent, useEventMutator } from '@eventespresso/edtr-services';\nimport { withFeature } from '@eventespresso/services';\n\ntype AdvancedTextEditorProps = React.ComponentProps;\n\nconst EventDescription: React.FC = () => {\n\tconst event = useEvent();\n\n\tconst { updateEntity: updateEvent } = useEventMutator(event?.id);\n\n\tconst onChangeDescription = useCallback(\n\t\t(newDescription) => {\n\t\t\tif (newDescription !== event?.description) {\n\t\t\t\tupdateEvent({ description: newDescription });\n\t\t\t}\n\t\t},\n\t\t[event?.description, updateEvent]\n\t);\n\n\tuseEffect(() => {\n\t\t// remove tiny mce editor\n\t\tdocument.getElementById('postdivrich')?.remove();\n\t}, []);\n\n\treturn (\n\t\t
\n\t\t\t\n\t\t\t\t{__('Event Description')}\n\t\t\t\n\t\t\t\n\t\t
\n\t);\n};\n\nexport default withFeature('use_event_description_rte')(EventDescription);\n","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst VenueSeat = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(VenueSeat, 'venue-seat');\n","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst Phone = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(Phone, 'phone');\n","import { useMemo } from 'react';\nimport { addQueryArgs } from '@wordpress/url';\n\nimport { ADMIN_ROUTES } from '@eventespresso/constants';\nimport { useConfig, getAdminUrl } from '@eventespresso/services';\n\nexport const useVenueLink = (type: 'create_new' | 'edit', venueDbId?: number) => {\n\tconst { siteUrl } = useConfig();\n\n\treturn useMemo(() => {\n\t\tconst adminUrl = getAdminUrl({\n\t\t\tadminSiteUrl: siteUrl.admin,\n\t\t\tpage: ADMIN_ROUTES.VENUES,\n\t\t});\n\t\treturn addQueryArgs(adminUrl, {\n\t\t\tpost: venueDbId,\n\t\t\taction: type,\n\t\t\treturn: 'edit',\n\t\t});\n\t}, [siteUrl.admin, type, venueDbId]);\n};\n","import { useCallback, useMemo, useState } from 'react';\n\nimport { __, sprintf } from '@eventespresso/i18n';\nimport { Image } from '@eventespresso/adapters';\nimport { useEvent, useEventMutator, useVenues } from '@eventespresso/edtr-services';\nimport { isInfinite } from '@eventespresso/utils';\nimport { findEntityByGuid } from '@eventespresso/predicates';\nimport { Address, Container, Heading, TextLink, VenueSelector } from '@eventespresso/ui-components';\nimport { MapMarker, Phone, VenueSeat } from '@eventespresso/icons';\n\nimport { useVenueLink } from './useVenueLink';\n\nimport './styles.scss';\n\nconst classes = {\n\tcontainer: 'ee-edtr-section ee-event-venue',\n};\n\nconst header = (\n\t\n\t\t{__('Venue Details')}\n\t\n);\n\nexport const VenueDetails: React.FC = () => {\n\tconst event = useEvent();\n\tconst { updateEntity } = useEventMutator(event?.id);\n\tconst [selectedVenueId, setSelectedVenueId] = useState(event?.venue || '');\n\n\tconst venues = useVenues();\n\t// need to make a copy else we can't sort it\n\tconst sortedVenues = useMemo(() => [...venues], [venues]);\n\t// create a collator to sort the venues by name using the current locale and natural sort order\n\tconst collator = new Intl.Collator(undefined, { numeric: true, sensitivity: 'base' });\n\tsortedVenues.sort((a, b) => collator.compare(a.name, b.name));\n\n\tconst selectedVenue = useMemo(\n\t\t() => findEntityByGuid(sortedVenues)(selectedVenueId),\n\t\t[selectedVenueId, sortedVenues]\n\t);\n\n\tconst createVenueLink = useVenueLink('create_new');\n\tconst editVenueLink = useVenueLink('edit', selectedVenue?.dbId);\n\n\tconst capacity = selectedVenue?.capacity;\n\tconst venueCapacity = isInfinite(capacity)\n\t\t? __('unlimited space')\n\t\t: sprintf(\n\t\t\t\t/* translators: %d venue capacity */\n\t\t\t\t__('Space for up to %d people'),\n\t\t\t\tselectedVenue?.capacity\n\t\t );\n\n\tconst onChangeInstantValue = useCallback((newValue) => setSelectedVenueId(newValue), []);\n\n\tconst onChangeValue = useCallback((venue) => updateEntity({ venue }), [updateEntity]);\n\tconst thumbnail = selectedVenue?.thumbnail;\n\n\tconst addressLabels = useMemo(\n\t\t() => ({\n\t\t\tinline: __('Venue address'),\n\t\t}),\n\t\t[]\n\t);\n\n\treturn (\n\t\t\n\t\t\t{selectedVenue && (\n\t\t\t\t
\n\t\t\t\t\t{thumbnail ? (\n\t\t\t\t\t\t
\n\t\t\t\t\t\t\t{selectedVenue?.name}\n\t\t\t\t\t\t
\n\t\t\t\t\t) : (\n\t\t\t\t\t\t
\n\t\t\t\t\t\t\t{__('no image')}\n\t\t\t\t\t\t
\n\t\t\t\t\t)}\n\t\t\t\t\t
\n\t\t\t\t\t\t\n\t\t\t\t\t\t\t{selectedVenue?.name}\n\t\t\t\t\t\t\n\t\t\t\t\t\t
\n\t\t\t\t\t\t\t

{selectedVenue?.shortDescription}

\n\t\t\t\t\t\t
\n\t\t\t\t\t\t
\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t{venueCapacity}\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t{selectedVenue?.phone || '(###) ###-####'}\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t
\n\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t{__('Edit this Venue')}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t
\n\t\t\t\t\t
\n\t\t\t\t
\n\t\t\t)}\n\t\t\t\n\t\t
\n\t);\n};\n","import { __ } from '@eventespresso/i18n';\nimport type { OptionsType } from '@eventespresso/adapters';\n\nexport type AppliesTo = 'ALL' | 'PRIMARY' | 'PURCHASER' | 'REGISTRANTS';\n\nexport const APPLIES_TO_OPTIONS: OptionsType = [\n\t{\n\t\tvalue: 'ALL',\n\t\tlabel: __('all'),\n\t},\n\t{\n\t\tvalue: 'PRIMARY',\n\t\tlabel: __('primary registrant'),\n\t},\n\t{\n\t\tvalue: 'PURCHASER',\n\t\tlabel: __('purchaser'),\n\t},\n\t{\n\t\tvalue: 'REGISTRANTS',\n\t\tlabel: __('registrants'),\n\t},\n];\n\nexport const MAPS_TO_OPTIONS: OptionsType = [\n\t{\n\t\tvalue: '',\n\t\tlabel: '...',\n\t},\n\t{\n\t\tvalue: 'Attendee.fname',\n\t\tlabel: __('Attendee First Name'),\n\t},\n\t{\n\t\tvalue: 'Attendee.lname',\n\t\tlabel: __('Attendee Last Name'),\n\t},\n\t{\n\t\tvalue: 'Attendee.email',\n\t\tlabel: __('Attendee Email Address'),\n\t},\n\t{\n\t\tvalue: 'Attendee.address',\n\t\tlabel: __('Attendee Address'),\n\t},\n];\n","import * as R from 'ramda';\n\nconst hasTypeAsText = R.propEq('type', 'TEXT');\nconst hasMapsToAsFName = R.propEq('mapsTo', 'Attendee.fname');\nconst hasTypeAsTextAndMapsToAsFName = R.allPass([hasTypeAsText, hasMapsToAsFName]);\n/**\n * Given a list of elements, it returns a boolean indicating whether there is\n * an element which maps to 'Attendee.fname'\n */\nexport const hasAnElementAsAttendeeFName = R.any(hasTypeAsTextAndMapsToAsFName);\n\nconst hasTypeAsEmail = R.propEq('type', 'EMAIL');\nconst hasMapsToAsEmail = R.propEq('mapsTo', 'Attendee.email');\nconst hasTypeAsEmailAndMapsToAsEmail = R.allPass([hasTypeAsEmail, hasMapsToAsEmail]);\n/**\n * Given a list of elements, it returns a boolean indicating whether there is\n * an element which maps to 'Attendee.email'\n */\nexport const hasAnElementAsAttendeeEmail = R.any(hasTypeAsEmailAndMapsToAsEmail);\n","import { useMemo } from 'react';\nimport * as R from 'ramda';\n\nimport { FormBuilderProps } from '@eventespresso/form-builder';\nimport { Banner } from '@eventespresso/ui-components';\nimport { sprintf, __ } from '@eventespresso/i18n';\nimport { isNotSharedOrDefault, getGuids } from '@eventespresso/predicates';\nimport { hasAnElementAsAttendeeEmail, hasAnElementAsAttendeeFName } from './utils';\n\nexport const ErrorMessage: FormBuilderProps['topBanner'] = ({ elements, sections }) => {\n\tlet message = '';\n\n\tconst info = useMemo(() => {\n\t\t// Lets not consider default or shared sections\n\t\t// because it is possible that there is valid data in default or shared sections/elements\n\t\t// but not added to the event\n\t\tconst formSectionIds = getGuids(Object.values(sections).filter(isNotSharedOrDefault));\n\n\t\tconst formElements = Object.values(elements).filter(\n\t\t\t// filters out the elements that belong to shared or default section\n\t\t\tR.propSatisfies(R.flip(R.includes)(formSectionIds), 'belongsTo')\n\t\t);\n\t\treturn {\n\t\t\thasFirstName: hasAnElementAsAttendeeFName(formElements),\n\t\t\thasEmail: hasAnElementAsAttendeeEmail(formElements),\n\t\t};\n\t}, [elements, sections]);\n\n\tif (!info.hasFirstName) {\n\t\tmessage = sprintf(\n\t\t\t/* translators: field name */\n\t\t\t__('Registration form must have a field of type \"%1$s\" which maps to \"%2$s\"'),\n\t\t\t__('Text Input'),\n\t\t\t__('Attendee First Name')\n\t\t);\n\t} else if (!info.hasEmail) {\n\t\tmessage = sprintf(\n\t\t\t/* translators: field name */\n\t\t\t__('Registration form must have a field of type \"%1$s\" which maps to \"%2$s\"'),\n\t\t\t__('Email Address'),\n\t\t\t__('Attendee Email Address')\n\t\t);\n\t}\n\n\tif (!message) {\n\t\treturn null;\n\t}\n\n\treturn ;\n};\n","import { __ } from '@eventespresso/i18n';\nimport { withFeature } from '@eventespresso/services';\nimport { Heading } from '@eventespresso/ui-components';\nimport { FormBuilder } from '@eventespresso/form-builder';\nimport { getEdtrDomData } from '@eventespresso/edtr-services';\n\nimport { APPLIES_TO_OPTIONS, MAPS_TO_OPTIONS } from './constants';\nimport { ErrorMessage } from './ErrorMessage';\n\nconst header = (\n\t\n\t\t{__('Registration Form')}\n\t\n);\n\nexport const RegistrationForm: React.FC = () => {\n\tconst { elements, sections, topLevelSectionId } = getEdtrDomData('formBuilder');\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default withFeature('use_reg_form_builder')(RegistrationForm);\n","import { useMemo } from 'react';\nimport { isDev } from '@eventespresso/constants';\nimport { useIsRehydrated } from '@eventespresso/data';\nimport { useStatus, TypeName } from '@eventespresso/services';\n\nconst useNotifications = () => {\n\tconst { isLoaded } = useStatus();\n\tconst [isRehydrated] = useIsRehydrated();\n\n\tconst readyTypes = useMemo(() => {\n\t\tconst types: string[] = [];\n\t\tif (!isDev || !isRehydrated) {\n\t\t\treturn [];\n\t\t}\n\t\tfor (const key in TypeName) {\n\t\t\tif (isLoaded(TypeName[key])) {\n\t\t\t\ttypes.push(TypeName[key]);\n\t\t\t}\n\t\t}\n\t\treturn types;\n\t}, [isLoaded, isRehydrated]);\n\n\treturn useMemo(\n\t\t() => ({\n\t\t\tdev: {\n\t\t\t\treadyTypes,\n\t\t\t},\n\t\t}),\n\t\t[readyTypes]\n\t);\n};\n\nexport default useNotifications;\n","import { useEffect } from 'react';\nimport { sprintf } from '@wordpress/i18n';\nimport { ToastContainer } from 'react-toastify';\nimport { useSystemNotifications, initToaster } from '@eventespresso/toaster';\n\nimport useNotifications from './useNotifications';\n\nconst Notifications = (): JSX.Element => {\n\tconst toaster = useSystemNotifications();\n\tconst toasts = useNotifications();\n\n\tuseEffect(() => {\n\t\tinitToaster();\n\t}, []);\n\n\tuseEffect(() => {\n\t\ttoasts.dev.readyTypes.forEach((type) => {\n\t\t\tconst message = sprintf('%s initialized', type);\n\t\t\ttoaster.success({ message, toastId: message });\n\t\t});\n\t}, [toaster, toasts]);\n\n\treturn ;\n};\n\nexport default Notifications;\n","import * as yup from 'yup';\n\nimport { datesSchema, DateFormShape } from '@eventespresso/edtr-services';\nimport { yupToFinalFormErrors } from '@eventespresso/form';\n\nexport const validate = async (values: DateFormShape): Promise => {\n\treturn await yupToFinalFormErrors(validationSchema, values);\n};\n\nconst validationSchema = yup.object({\n\tname: yup.string(),\n\t...datesSchema,\n});\n","import { useMemo, useCallback } from 'react';\nimport * as R from 'ramda';\n\nimport { CalendarOutlined, ControlOutlined, ProfileOutlined } from '@eventespresso/icons';\nimport { startAndEndDateFixer, useDatetimeItem, hooks } from '@eventespresso/edtr-services';\nimport { useUtcISOToSiteDate, useSiteDateToUtcISO } from '@eventespresso/services';\nimport type { EspressoFormProps } from '@eventespresso/form';\nimport { PLUS_ONE_MONTH } from '@eventespresso/constants';\nimport { useMemoStringify } from '@eventespresso/hooks';\nimport { setDefaultTime } from '@eventespresso/dates';\nimport { EndDateFieldWrapper } from '@eventespresso/ee-components';\nimport { EntityId } from '@eventespresso/data';\nimport { __ } from '@eventespresso/i18n';\nimport type { Datetime, DateFormConfig } from '@eventespresso/edtr-services';\n\nimport { validate } from './formValidation';\n\nconst FIELD_NAMES: Array = ['id', 'name', 'description', 'capacity', 'isTrashed'];\n\nconst decorators = [startAndEndDateFixer];\n\nconst adjacentFormItemProps = {\n\tclassName: 'ee-form-item-pair',\n};\n\nconst useDateFormConfig = (id: EntityId, config?: EspressoFormProps): DateFormConfig => {\n\tconst datetime = useDatetimeItem({ id });\n\n\tconst toUtcISO = useSiteDateToUtcISO();\n\tconst toSiteDate = useUtcISOToSiteDate();\n\n\tconst startDate = useMemoStringify(\n\t\tdatetime?.startDate ? toSiteDate(datetime?.startDate) : setDefaultTime(PLUS_ONE_MONTH, 'start')\n\t);\n\tconst endDate = useMemoStringify(\n\t\tdatetime?.endDate ? toSiteDate(datetime?.endDate) : setDefaultTime(PLUS_ONE_MONTH, 'end')\n\t);\n\n\tconst { onSubmit } = config;\n\n\tconst onSubmitFrom: DateFormConfig['onSubmit'] = useCallback(\n\t\tasync ({ startDate, endDate, ...values }, form, ...restParams) => {\n\t\t\treturn await onSubmit(\n\t\t\t\t{ ...values, startDate: toUtcISO(startDate), endDate: toUtcISO(endDate) },\n\t\t\t\tform,\n\t\t\t\t...restParams\n\t\t\t);\n\t\t},\n\t\t[onSubmit, toUtcISO]\n\t);\n\n\tconst initialValues = useMemo(() => {\n\t\treturn hooks.applyFilters(\n\t\t\t'eventEditor.dateForm.initalValues',\n\t\t\t{\n\t\t\t\t...R.pick, keyof Datetime>(FIELD_NAMES, datetime || {}),\n\t\t\t\tstartDate,\n\t\t\t\tendDate,\n\t\t\t},\n\t\t\tdatetime\n\t\t);\n\t}, [datetime, endDate, startDate]);\n\n\tconst sections = useMemo(() => {\n\t\treturn hooks.applyFilters(\n\t\t\t'eventEditor.dateForm.sections',\n\t\t\t[\n\t\t\t\t{\n\t\t\t\t\tname: 'basics',\n\t\t\t\t\ticon: ProfileOutlined,\n\t\t\t\t\ttitle: __('Basics'),\n\t\t\t\t\tfields: [\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tfieldType: 'text',\n\t\t\t\t\t\t\tlabel: __('Name'),\n\t\t\t\t\t\t\tname: 'name',\n\t\t\t\t\t\t},\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tname: 'description',\n\t\t\t\t\t\t\tlabel: __('Description'),\n\t\t\t\t\t\t\tfieldType: 'simple-text-editor',\n\t\t\t\t\t\t},\n\t\t\t\t\t],\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\tname: 'dateTime',\n\t\t\t\t\ticon: CalendarOutlined,\n\t\t\t\t\ttitle: __('Dates'),\n\t\t\t\t\tfields: [\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tname: 'startDate',\n\t\t\t\t\t\t\tlabel: __('Start Date'),\n\t\t\t\t\t\t\tfieldType: 'datetimepicker',\n\t\t\t\t\t\t\trequired: true,\n\t\t\t\t\t\t\tformControlProps: adjacentFormItemProps,\n\t\t\t\t\t\t},\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tname: 'endDate',\n\t\t\t\t\t\t\tlabel: __('End Date'),\n\t\t\t\t\t\t\tfieldType: 'datetimepicker',\n\t\t\t\t\t\t\trequired: true,\n\t\t\t\t\t\t\twrapper: EndDateFieldWrapper,\n\t\t\t\t\t\t\tformControlProps: adjacentFormItemProps,\n\t\t\t\t\t\t},\n\t\t\t\t\t],\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\tname: 'details',\n\t\t\t\t\ticon: ControlOutlined,\n\t\t\t\t\ttitle: __('Details'),\n\t\t\t\t\tfields: [\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tname: 'capacity',\n\t\t\t\t\t\t\tlabel: __('Capacity'),\n\t\t\t\t\t\t\tfieldType: 'number',\n\t\t\t\t\t\t\tparseAsInfinity: true,\n\t\t\t\t\t\t\tmin: -1,\n\t\t\t\t\t\t\tinfo:\n\t\t\t\t\t\t\t\t__(\n\t\t\t\t\t\t\t\t\t'The maximum number of registrants that can attend the event at this particular date.'\n\t\t\t\t\t\t\t\t) +\n\t\t\t\t\t\t\t\t'\\n' +\n\t\t\t\t\t\t\t\t__('Set to 0 to close registration or leave blank for no limit.'),\n\t\t\t\t\t\t\twidth: 'small',\n\t\t\t\t\t\t\tformControlProps: adjacentFormItemProps,\n\t\t\t\t\t\t},\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tname: 'isTrashed',\n\t\t\t\t\t\t\tlabel: __('Trash'),\n\t\t\t\t\t\t\tfieldType: 'switch',\n\t\t\t\t\t\t\tformControlProps: adjacentFormItemProps,\n\t\t\t\t\t\t},\n\t\t\t\t\t],\n\t\t\t\t},\n\t\t\t],\n\t\t\tdatetime\n\t\t);\n\t}, [datetime]);\n\n\treturn useMemo(\n\t\t() => ({\n\t\t\t...config,\n\t\t\tonSubmit: onSubmitFrom,\n\t\t\tdecorators,\n\t\t\tinitialValues,\n\t\t\tsubscription: {},\n\t\t\tvalidate,\n\t\t\tlayout: 'horizontal',\n\t\t\tsections,\n\t\t}),\n\t\t[config, initialValues, onSubmitFrom, sections]\n\t);\n};\n\nexport default useDateFormConfig;\n","import { __ } from '@eventespresso/i18n';\n\nimport { Calendar, Ticket } from '@eventespresso/icons';\nimport { Steps, Step } from '@eventespresso/ui-components';\nimport { PrevNext } from '@eventespresso/hooks';\n\nconst DatetimeFormSteps: React.FC> = ({ current }) => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default DatetimeFormSteps;\n","import { useEffect } from 'react';\n\nimport { useForm } from '@eventespresso/form';\n\nimport { useDataState as useTAMDataState } from '@edtrUI/ticketAssignmentsManager/data';\n\n/**\n * A custom hook which subscribes to TAM data and updates\n * RFF data when needed.\n */\nconst useDataListener: VoidFunction = () => {\n\tconst { getData } = useTAMDataState();\n\tconst { mutators, getState } = useForm();\n\tconst data = getData();\n\n\tconst id = getState().values.id || 'NEW_DATE';\n\tuseEffect(() => {\n\t\t// update value of `tickets` field in RFF state\n\t\tmutators.updateFieldValue('tickets', data?.datetimes?.[id]?.tickets);\n\t}, [data, id, mutators]);\n};\n\nexport default useDataListener;\n","/* eslint-disable @wordpress/i18n-no-collapsible-whitespace */\nimport { __ } from '@eventespresso/i18n';\n\nimport { Banner } from '@eventespresso/ui-components';\nimport { useDataState } from '../data';\n\ninterface ErrorMessageProps {\n\tasAlert?: boolean;\n\tdataState: ReturnType;\n}\n\nconst ErrorMessage: React.FC = ({ asAlert = true, dataState }) => {\n\tconst { hasOrphanDates, hasOrphanTickets } = dataState;\n\n\tlet message = '';\n\n\tif (hasOrphanTickets()) {\n\t\tmessage = __(\n\t\t\t'Tickets must always have at least one date assigned to them but one or more of the tickets below does not have any. \\nPlease correct the assignments for the highlighted cells.'\n\t\t);\n\t} else if (hasOrphanDates()) {\n\t\tmessage = __(\n\t\t\t'Event Dates must always have at least one Ticket assigned to them but one or more of the Event Dates below does not have any. \\nPlease correct the assignments for the highlighted cells.'\n\t\t);\n\t}\n\n\tif (!message) {\n\t\treturn null;\n\t}\n\n\tif (asAlert) {\n\t\treturn ;\n\t}\n\n\treturn {message};\n};\n\nexport default ErrorMessage;\n","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst MinusOutlined = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(MinusOutlined, 'minus-outlined');\n","import { CloseOutlined, MinusOutlined, Ticket } from '@eventespresso/icons';\n\nimport type { AssignmentStatus } from '../../../types';\n\nimport './styles.scss';\n\nconst getRelationIcon = (status?: AssignmentStatus): React.ComponentType => {\n\tswitch (status) {\n\t\tcase 'NEW':\n\t\tcase 'OLD':\n\t\t\treturn Ticket;\n\t\tcase 'REMOVED':\n\t\t\treturn CloseOutlined;\n\t\tdefault:\n\t\t\treturn MinusOutlined;\n\t}\n};\n\nexport default getRelationIcon;\n","import { useCallback, useMemo } from 'react';\n\nimport { Button } from '@eventespresso/ui-components';\nimport { sprintf } from '@eventespresso/i18n';\nimport { useDataState } from '../../data';\nimport getRelationIcon from './getRelationIcon';\nimport type { RenderCellProps } from '../../types';\nimport type { Datetime, Ticket } from '@eventespresso/edtr-services';\n\nconst BodyCell: React.FC = ({ datetime, ticket }) => {\n\tconst { getAssignmentStatus, toggleAssignment } = useDataState();\n\n\tconst status = getAssignmentStatus({ datetimeId: datetime.id, ticketId: ticket.id });\n\n\tconst onClick = useCallback(\n\t\t() => toggleAssignment({ datetimeId: datetime.id, ticketId: ticket.id }),\n\t\t[datetime.id, ticket.id, toggleAssignment]\n\t);\n\n\tconst icon = useMemo(() => getRelationIcon(status), [status]);\n\n\tconst nameOrId = (entity: Datetime | Ticket): string => {\n\t\tif (entity.name && entity.name.length > 0) {\n\t\t\treturn entity.name;\n\t\t}\n\t\tif (entity.dbId === 0) {\n\t\t\treturn '';\n\t\t}\n\t\treturn entity.dbId.toString();\n\t};\n\n\tconst entityLabel = useCallback((entity: Datetime | Ticket, type: string): string => {\n\t\tconst token = nameOrId(entity);\n\t\t/* translators: %1$s entity type, %2$s entity name or id */\n\t\treturn sprintf('%1$s %2$s', type, token);\n\t}, []);\n\n\tconst ariaLabel: string = useMemo(() => {\n\t\tconst ticketLabel = entityLabel(ticket, 'ticket');\n\t\tconst datetimeLabel = entityLabel(datetime, 'datetime');\n\t\tswitch (status) {\n\t\t\tcase null:\n\t\t\t\t// no current status so assign new relation\n\t\t\t\t/* translators: %1$s ticket label, %2$s datetime label */\n\t\t\t\treturn sprintf('click to assign %1$s to %2$s', ticketLabel, datetimeLabel);\n\t\t\tcase 'NEW':\n\t\t\t\t// remove newly assigned relation\n\t\t\t\t/* translators: %1$s ticket label, %2$s datetime label */\n\t\t\t\treturn sprintf('click to remove new assignment for %1$s from %2$s', ticketLabel, datetimeLabel);\n\t\t\tcase 'OLD':\n\t\t\t\t// remove existing relation\n\t\t\t\t/* translators: %1$s ticket label, %2$s datetime label */\n\t\t\t\treturn sprintf('click to remove %1$s from %2$s', ticketLabel, datetimeLabel);\n\t\t\tcase 'REMOVED':\n\t\t\t\t// reassign newly removed relation\n\t\t\t\t/* translators: %1$s ticket label, %2$s datetime label */\n\t\t\t\treturn sprintf('click to reassign %1$s to %2$s', ticketLabel, datetimeLabel);\n\t\t}\n\t}, [ticket, datetime, status, entityLabel]);\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default BodyCell;\n","import { parseISO } from 'date-fns';\nimport classNames from 'classnames';\nimport { __ } from '@eventespresso/i18n';\n\nimport type { RenderCellProps } from '../../types';\nimport { getDatetimeBackgroundColorClassName } from '@eventespresso/helpers';\nimport { useTimeZoneTime } from '@eventespresso/services';\nimport { LOCALIZED_DATE_SHORT_FORMAT } from '@eventespresso/constants';\n\nconst DateCell: React.FC = ({ datetime }) => {\n\tconst bgClassName = getDatetimeBackgroundColorClassName(datetime);\n\tconst stripeClassName = classNames('date-stripe', bgClassName);\n\n\tconst { formatForSite: format } = useTimeZoneTime();\n\tlet startDate: any = datetime.startDate;\n\tif (startDate instanceof Date) {\n\t\tstartDate = format(startDate, LOCALIZED_DATE_SHORT_FORMAT);\n\t} else if (startDate) {\n\t\tstartDate = format(parseISO(datetime.startDate), LOCALIZED_DATE_SHORT_FORMAT);\n\t}\n\n\treturn (\n\t\t
\n\t\t\t
\n\t\t\t
{`${__('ID')}: ${datetime.dbId}`}
\n\t\t\t
{datetime.name}
\n\t\t\t
{startDate}
\n\t\t
\n\t);\n};\n\nexport default DateCell;\n","import { useCallback } from 'react';\n\nimport type { Datetime } from '@eventespresso/edtr-services';\nimport { useDataState } from '../../data';\n\ntype Callback = (datetime: Datetime) => string;\n\nconst useRowClassName = (): Callback => {\n\tconst { hasNoAssignedTickets } = useDataState();\n\n\treturn useCallback(\n\t\t(datetime) => {\n\t\t\tconst isOrphan = hasNoAssignedTickets({ datetimeId: datetime.id });\n\t\t\treturn isOrphan ? 'no-assignments' : '';\n\t\t},\n\t\t[hasNoAssignedTickets]\n\t);\n};\n\nexport default useRowClassName;\n","import { useCallback } from 'react';\n\nimport type { Ticket } from '@eventespresso/edtr-services';\nimport { useDataState } from '../../data';\n\ntype Callback = (ticket: Ticket) => string;\n\nconst useColClassName = (): Callback => {\n\tconst { hasNoAssignedDates } = useDataState();\n\n\treturn useCallback(\n\t\t(ticket) => {\n\t\t\tconst isOrphan = hasNoAssignedDates({ ticketId: ticket.id });\n\t\t\treturn isOrphan ? 'no-assignments' : '';\n\t\t},\n\t\t[hasNoAssignedDates]\n\t);\n};\n\nexport default useColClassName;\n","import { useMemo } from 'react';\nimport classNames from 'classnames';\n\nimport type { BodyRow, CellData } from '@eventespresso/ui-components';\n\nimport BodyCell from './BodyCell';\nimport DateCell from './DateCell';\nimport { useDataState } from '../../data';\nimport useRowClassName from './useRowClassName';\nimport useColClassName from './useColClassName';\nimport type { DatesAndTickets, RelationClassName } from '../../types';\n\nconst useGetBodyRows = ({ datetimes, tickets }: DatesAndTickets): BodyRow[] => {\n\tconst { getAssignmentStatus } = useDataState();\n\n\tconst getRowClass = useRowClassName();\n\tconst getColClass = useColClassName();\n\n\treturn useMemo(() => {\n\t\treturn datetimes.map((datetime) => {\n\t\t\tconst datetimeCell: CellData = {\n\t\t\t\tclassName: 'ee-rspnsv-table-column-micro date-cell',\n\t\t\t\tkey: 'datetime',\n\t\t\t\tvalue: ,\n\t\t\t};\n\n\t\t\tconst cells: Array = tickets.map((ticket) => {\n\t\t\t\tconst status = getAssignmentStatus({ datetimeId: datetime.id, ticketId: ticket.id });\n\t\t\t\tconst statusClassName = status && (`${status.toLowerCase()}-assignment` as RelationClassName);\n\n\t\t\t\tconst className = classNames('relation-cell', statusClassName, getColClass(ticket));\n\n\t\t\t\tconst cell: CellData = {\n\t\t\t\t\tclassName,\n\t\t\t\t\tkey: ticket.id,\n\t\t\t\t\tsize: 'huge',\n\t\t\t\t\ttextAlign: 'center',\n\t\t\t\t\tvalue: ,\n\t\t\t\t};\n\n\t\t\t\treturn cell;\n\t\t\t});\n\n\t\t\treturn {\n\t\t\t\tcells: [datetimeCell, ...cells],\n\t\t\t\tclassName: { bodyRowClassName: 'ee-ticket-assignments-manager-table-body-row' },\n\t\t\t\trowClassName: getRowClass(datetime),\n\t\t\t\tkey: datetime.id,\n\t\t\t\tprimary: true,\n\t\t\t\ttype: 'row',\n\t\t\t};\n\t\t});\n\t}, [datetimes, getAssignmentStatus, getColClass, getRowClass, tickets]);\n};\n\nexport default useGetBodyRows;\n","import { parseISO } from 'date-fns';\nimport classNames from 'classnames';\nimport { __ } from '@eventespresso/i18n';\n\nimport { CurrencyDisplay } from '@eventespresso/ee-components';\nimport { getTicketBackgroundColorClassName } from '@eventespresso/helpers';\nimport { useTimeZoneTime } from '@eventespresso/services';\nimport type { RenderCellProps } from '../../types';\n\nconst FORMAT = 'MMM dd yyyy';\n\nconst HeaderCell: React.FC = ({ ticket }) => {\n\tconst bgClassName = getTicketBackgroundColorClassName(ticket);\n\tconst { formatForSite: format } = useTimeZoneTime();\n\tlet startDate: any = ticket.startDate;\n\tif (startDate instanceof Date) {\n\t\tstartDate = format(startDate, FORMAT);\n\t} else if (startDate) {\n\t\tstartDate = format(parseISO(ticket.startDate), FORMAT);\n\t}\n\n\tconst startDateClassName = classNames(bgClassName, 'header-cell-content__after');\n\n\treturn (\n\t\t
\n\t\t\t
\n\t\t\t\t
{`${__('ID')}: ${ticket.dbId}`}
\n\t\t\t\t
{ticket.name}
\n\t\t\t\t
\n\t\t\t\t\t\n\t\t\t\t
\n\t\t\t
\n\t\t\t
{startDate}
\n\t\t
\n\t);\n};\n\nexport default HeaderCell;\n","import { useMemo } from 'react';\n\nimport type { CellData, HeaderRow } from '@eventespresso/ui-components';\nimport type { Ticket } from '@eventespresso/edtr-services';\nimport { __ } from '@eventespresso/i18n';\n\nimport HeaderCell from './HeaderCell';\nimport useColClassName from './useColClassName';\n\nconst emptyCell: CellData = {\n\tkey: 'empty',\n\tsize: 'huge',\n\tvalue: (\n\t\t
\n\t\t\t

{__('Assignments')}

\n\t\t\t

{__('Event Dates are listed below')}

\n\t\t\t

{__('Tickets are listed along the top')}

\n\t\t\t

{__('Click the cell buttons to toggle assigments')}

\n\t\t
\n\t),\n};\n\nconst useGetHeaderRows = (tickets: Ticket[]): HeaderRow[] => {\n\tconst getColClass = useColClassName();\n\n\treturn useMemo(() => {\n\t\tconst cells: Array = tickets.map((ticket) => ({\n\t\t\tclassName: getColClass(ticket),\n\t\t\tkey: ticket.id,\n\t\t\tsize: 'huge',\n\t\t\tvalue: ,\n\t\t}));\n\n\t\treturn [\n\t\t\t{\n\t\t\t\tcells: [emptyCell, ...cells],\n\t\t\t\tkey: 'ee-ticket-assignments-manager-table-header-row',\n\t\t\t\tprimary: true,\n\t\t\t\ttype: 'row',\n\t\t\t},\n\t\t];\n\t}, [getColClass, tickets]);\n};\n\nexport default useGetHeaderRows;\n","import { __ } from '@eventespresso/i18n';\n\nimport useGetBodyRows from './useGetBodyRows';\nimport useGetHeaderRows from './useGetHeaderRows';\nimport { DatesAndTickets } from '../../types';\nimport { ResponsiveTable } from '@eventespresso/ui-components';\n\nimport './styles.scss';\n\nconst metaData = {\n\tisScrollable: true,\n\ttableId: 'ee-ticket-assignments-manager-table',\n\ttableCaption: __('Ticket Assignment Manager'),\n};\nconst className = { tableClassName: 'ee-ticket-assignments-manager' };\n\nconst Table: React.FC = ({ datetimes, tickets }) => {\n\tconst bodyRows = useGetBodyRows({ datetimes, tickets });\n\tconst headerRows = useGetHeaderRows(tickets);\n\n\treturn ;\n};\n\nexport default Table;\n","import { DebugInfo } from '@eventespresso/ui-components';\n\nimport { useDataState } from '../data';\n\nconst Debug = () => {\n\tconst { getData } = useDataState();\n\n\treturn ;\n};\n\nexport default Debug;\n","import ErrorMessage from './ErrorMessage';\nimport { Table } from './table';\nimport { FilterBar } from '../filters';\nimport { useDatesAndTickets } from '../data';\nimport { useDataState } from '../data';\nimport Debug from './Debug';\n\nconst TicketAssignmentsManager: React.FC = () => {\n\tconst datesAndTickets = useDatesAndTickets();\n\tconst dataState = useDataState();\n\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default TicketAssignmentsManager;\n","import { __ } from '@eventespresso/i18n';\nimport getRelationIcon from '../components/table/getRelationIcon';\nimport type { LegendConfig } from '@eventespresso/ui-components';\nimport type { RelationClassName } from '../types';\n\nexport const legendConfig: LegendConfig = {\n\ticons: [\n\t\t{\n\t\t\tclassName: 'old-assignment',\n\t\t\tdescription: __('existing relation'),\n\t\t\ticon: getRelationIcon('OLD'),\n\t\t},\n\t\t{\n\t\t\tclassName: 'removed-assignment',\n\t\t\tdescription: __('remove existing relation'),\n\t\t\ticon: getRelationIcon('REMOVED'),\n\t\t},\n\t\t{\n\t\t\tclassName: 'new-assignment',\n\t\t\tdescription: __('add new relation'),\n\t\t\ticon: getRelationIcon('NEW'),\n\t\t},\n\t\t{\n\t\t\tclassName: 'no-assignments',\n\t\t\tdescription: __('invalid relation'),\n\t\t\ticon: getRelationIcon(),\n\t\t},\n\t\t{\n\t\t\tdescription: __('no relation'),\n\t\t\ticon: getRelationIcon(),\n\t\t},\n\t],\n};\n","import { useCallback, useMemo, useState } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { ButtonType } from '@eventespresso/ui-components';\nimport type { ButtonProps } from '@eventespresso/ui-components';\nimport { SaveOutlined } from '@eventespresso/icons';\n\nimport { useDataState } from '../data';\nimport { TAMModalProps } from '../context';\n\nconst useSubmitButtonProps = (onSubmitData: TAMModalProps['onSubmit']): ButtonProps => {\n\tconst { hasOrphanEntities, getData } = useDataState();\n\tconst [isSubmitting, setIsSubmitting] = useState(false);\n\n\tconst hasErrors = hasOrphanEntities();\n\n\tconst onSubmit = useCallback(\n\t\tasync (e) => {\n\t\t\te.preventDefault();\n\t\t\tsetIsSubmitting(true);\n\t\t\tawait onSubmitData(getData());\n\t\t\tsetIsSubmitting(false);\n\t\t},\n\t\t[getData, onSubmitData]\n\t);\n\n\treturn useMemo(\n\t\t() => ({\n\t\t\tbuttonText: __('Submit'),\n\t\t\tbuttonType: ButtonType.PRIMARY,\n\t\t\ticon: SaveOutlined,\n\t\t\tisDisabled: hasErrors,\n\t\t\tisLoading: isSubmitting,\n\t\t\tonClick: onSubmit,\n\t\t\ttype: 'submit',\n\t\t}),\n\t\t[hasErrors, isSubmitting, onSubmit]\n\t);\n};\n\nexport default useSubmitButtonProps;\n","import { useMemo, useContext } from 'react';\nimport { __ } from '@eventespresso/i18n';\nimport { CollapsibleLegend, ModalWithAlert } from '@eventespresso/ui-components';\nimport type { ModalWithAlertProps } from '@eventespresso/ui-components';\n\nimport { legendConfig } from './config';\nimport TicketAssignmentsManager from './TicketAssignmentsManager';\nimport { useDataState } from '../data';\nimport type { TAMModalProps } from '../context/types';\nimport useSubmitButtonProps from './useSubmitButtonProps';\nimport { Context } from '../context/ContextProvider';\n\nimport './styles.scss';\n\nconst TicketAssignmentsManagerModal: React.FC> = ({ onCloseModal, onSubmit, title }) => {\n\tconst { hasOrphanEntities, isDirty } = useDataState();\n\tconst hasErrors = hasOrphanEntities();\n\n\tconst submitButtonProps = useSubmitButtonProps(onSubmit);\n\n\tconst data = useContext(Context);\n\n\tconst ariaLabel: string = useMemo(() => {\n\t\tif (!data.entity) {\n\t\t\treturn '';\n\t\t}\n\t\treturn `ticket assignment modal for datetime ${data.entity.name}`;\n\t}, [data]);\n\n\tconst ariaAttributes: ModalWithAlertProps['ariaAttributes'] = useMemo(\n\t\t() => ({ modalContent: { 'aria-label': ariaLabel } }),\n\t\t[ariaLabel]\n\t);\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default TicketAssignmentsManagerModal;\n","import { useCallback, useEffect, useState } from 'react';\nimport * as R from 'ramda';\n\nimport { useRelations } from '@eventespresso/services';\nimport { useDefaultTicketIds } from '@eventespresso/edtr-services';\n\nimport { TAM_ENTITIES } from '../constants';\n\ntype Callback = (check: boolean) => void;\n\nconst useInvalidDataAlert = (showAlert: VoidFunction): Callback => {\n\tconst { getData } = useRelations();\n\tconst [validateData, setValidateData] = useState(false);\n\tconst defaultTicketIds = useDefaultTicketIds();\n\n\tconst hasOrphanEntities = useCallback(() => {\n\t\tconst data = getData();\n\t\t// remove default tickets from TAM relations\n\t\tconst newData = { ...data, tickets: R.omit(defaultTicketIds, data.tickets || {}) };\n\t\t// simplify the data for loop\n\t\tconst entries = Object.entries(R.pick(TAM_ENTITIES, newData));\n\n\t\tfor (const [, entityRelations] of entries) {\n\t\t\tfor (const [, relations] of Object.entries(entityRelations)) {\n\t\t\t\tconst tamRelations = R.pick(TAM_ENTITIES, relations);\n\t\t\t\t// flatten the relations\n\t\t\t\tconst relatedIds = Object.values(tamRelations).flat();\n\t\t\t\tif (!relatedIds.length) {\n\t\t\t\t\treturn true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}, [defaultTicketIds, getData]);\n\n\tuseEffect(() => {\n\t\tif (validateData && hasOrphanEntities()) {\n\t\t\tshowAlert();\n\t\t\tsetValidateData(false);\n\t\t}\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\t}, [validateData]);\n\n\treturn setValidateData;\n};\n\nexport default useInvalidDataAlert;\n","import { useMemo, useCallback } from 'react';\n\nimport { sprintf, __ } from '@eventespresso/i18n';\nimport { EdtrGlobalModals } from '@eventespresso/edtr-services';\nimport { useGlobalModal } from '@eventespresso/registry';\nimport { useConfirmationDialog } from '@eventespresso/ui-components';\nimport { wait } from '@eventespresso/utils';\n\nimport TicketAssignmentsManagerModal from './TicketAssignmentsManagerModal';\nimport { withContext } from '../context';\nimport { useOnSubmitAssignments } from '../data';\nimport type { TAMModalProps } from '../context';\nimport type { BaseProps } from '../types';\nimport useInvalidDataAlert from './useInvalidDataAlert';\n\nconst ModalContainer: React.FC = () => {\n\tconst { getData, isOpen, close: onClose, openWithData } = useGlobalModal(EdtrGlobalModals.TAM);\n\n\tconst submitAssignments = useOnSubmitAssignments();\n\n\tconst reOpenTamModal = useCallback(() => {\n\t\topenWithData({ assignmentType: 'forAll' });\n\t}, [openWithData]);\n\n\tconst { confirmationDialog, onOpen: showAlert } = useConfirmationDialog({\n\t\tmessage: __(\n\t\t\t'There seem to be some dates/tickets which have no tickets/dates assigned. Do you want to fix them now?'\n\t\t),\n\t\ttitle: __('Alert!'),\n\t\tonConfirm: reOpenTamModal,\n\t});\n\n\tconst validateData = useInvalidDataAlert(showAlert);\n\n\tconst { assignmentType, entity } = getData();\n\n\tlet title = '';\n\n\tif (assignmentType === 'forDate') {\n\t\ttitle = sprintf(\n\t\t\t/* translators: 1 entity id, 2 entity name */\n\t\t\t__('Ticket Assignment Manager for Datetime: %1$s - %2$s'),\n\t\t\tString(entity.dbId),\n\t\t\tentity.name\n\t\t);\n\t} else if (assignmentType === 'forTicket') {\n\t\ttitle = sprintf(\n\t\t\t/* translators: 1 entity id, 2 entity name */\n\t\t\t__('Ticket Assignment Manager for Ticket: %1$s - %2$s'),\n\t\t\tString(entity.dbId),\n\t\t\tentity.name\n\t\t);\n\t}\n\n\tconst contextProps = useMemo(\n\t\t() => ({ assignmentType, entity, title, onCloseModal: onClose }),\n\t\t[assignmentType, entity, onClose, title]\n\t);\n\n\tconst onSubmit = useCallback(\n\t\tasync (data) => {\n\t\t\tvalidateData(false);\n\t\t\t// wait the next event cycle to fire up isLoading for submit button\n\t\t\tawait wait();\n\t\t\t// close the moal\n\t\t\tonClose();\n\t\t\t// submit TAM data\n\t\t\tawait submitAssignments(data);\n\t\t\tvalidateData(true);\n\t\t},\n\t\t[validateData, onClose, submitAssignments]\n\t);\n\n\tif (!isOpen) {\n\t\treturn <>{confirmationDialog};\n\t}\n\n\tconst Component = withContext(TicketAssignmentsManagerModal, contextProps);\n\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t{confirmationDialog}\n\t\t\n\t);\n};\n\nexport default ModalContainer;\n","import { TicketAssignmentsManager } from '@edtrUI/ticketAssignmentsManager/components';\nimport useDataListener from './useDataListener';\n\nconst TAMStep = () => {\n\tuseDataListener();\n\n\treturn ;\n};\n\nexport default TAMStep;\n","import DateFormSteps from './DateFormSteps';\nimport useDataListener from './useDataListener';\nimport { ModalBodyProps } from './types';\nimport { ASSIGN_TICKETS_STEP, DATE_DETAILS_STEP } from './constants';\nimport TAMStep from './TAMStep';\n\n/**\n * This component is inside both RFF and TAM contexts, so we can use all of their features\n */\nconst ModalBody: React.FC = ({ children: body, steps }) => {\n\t// init data listener to update RFF data\n\tuseDataListener();\n\n\treturn (\n\t\t
\n\t\t\t\n\t\t\t{/* RFF fields */}\n\t\t\t{steps.current === DATE_DETAILS_STEP && body}\n\n\t\t\t{steps.current === ASSIGN_TICKETS_STEP && }\n\t\t
\n\t);\n};\n\nexport default ModalBody;\n","export const DATE_DETAILS_STEP = 0;\n\nexport const ASSIGN_TICKETS_STEP = 1;\n","import { __ } from '@eventespresso/i18n';\n\nimport { ButtonRow, Next, Previous, Submit } from '@eventespresso/ui-components';\nimport { withFormSubscription, FormSubscriptionProps } from '@eventespresso/ee-components';\nimport type { PrevNext } from '@eventespresso/hooks';\n\nimport { useDataState as useTAMDataState } from '@edtrUI/ticketAssignmentsManager/data';\nimport { ASSIGN_TICKETS_STEP, DATE_DETAILS_STEP } from './constants';\n\ninterface FooterButtonsProps extends FormSubscriptionProps {\n\tsteps: PrevNext;\n}\n\nconst FooterButtons: React.FC = ({ form, hasErrors, steps, submitting }) => {\n\tconst { current, prev, next } = steps;\n\tconst { hasOrphanEntities } = useTAMDataState();\n\tconst isSubmitDisabled = hasOrphanEntities();\n\n\treturn (\n\t\t\n\t\t\t{current === DATE_DETAILS_STEP && (\n\t\t\t\t\n\t\t\t)}\n\n\t\t\t{current === ASSIGN_TICKETS_STEP && (\n\t\t\t\t<>\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t)}\n\t\t\n\t);\n};\n\nexport default withFormSubscription(FooterButtons);\n","import { useMemo } from 'react';\nimport { EntityEditModal } from '@eventespresso/ee-components';\nimport { EdtrGlobalModals, useEvent, useDatetimeItem } from '@eventespresso/edtr-services';\nimport { useGlobalModal } from '@eventespresso/registry';\nimport { __, sprintf } from '@eventespresso/i18n';\nimport { usePrevNext } from '@eventespresso/hooks';\nimport { useIsPristine } from '@eventespresso/form';\nimport { EntityEditModalProps } from '@eventespresso/ui-components';\n\nimport ModalBody from './ModalBody';\nimport FooterButtons from './FooterButtons';\n\nimport type { ContentWrapperProps } from './types';\nimport type { EntityEditModalData } from '@edtrUI/types';\n\nconst Modal: React.FC = ({ onClose, ...props }) => {\n\tconst { isOpen } = useGlobalModal(EdtrGlobalModals.EDIT_DATE);\n\tconst event = useEvent();\n\tconst steps = usePrevNext();\n\tconst isPristine = useIsPristine();\n\n\tconst { values } = props.form.getState();\n\n\tconst datetime = useDatetimeItem({ id: values?.id });\n\n\tconst title: string = useMemo(() => {\n\t\tconst str = datetime?.dbId\n\t\t\t? sprintf(\n\t\t\t\t\t/* translators: %d database id */\n\t\t\t\t\t__('Edit datetime %s'),\n\t\t\t\t\t`#${datetime.dbId}`\n\t\t\t )\n\t\t\t: __('New Datetime');\n\t\t// add event name to the title\n\t\treturn event?.name ? `${event.name}: ${str}` : str;\n\t}, [datetime, event]);\n\n\tconst footerButtons = ;\n\n\tconst ariaAttributes: EntityEditModalProps['ariaAttributes'] = useMemo(() => {\n\t\tconst getAriaLabel = (): string => {\n\t\t\tif (!datetime || !datetime.name) {\n\t\t\t\treturn __('modal for datetime');\n\t\t\t}\n\t\t\t/* translators: %s datetime name */\n\t\t\treturn sprintf('modal for datetime %s', datetime.name);\n\t\t};\n\t\treturn {\n\t\t\tmodalContent: { 'aria-label': getAriaLabel() },\n\t\t};\n\t}, [datetime]);\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default Modal;\n","import { useMemoStringify } from '@eventespresso/hooks';\nimport { useFormValues } from '@eventespresso/form';\nimport { Datetime, DateFormShape, useDatetimeItem } from '@eventespresso/edtr-services';\n\nimport { ContextProvider as TAMContextProvider } from '@edtrUI/ticketAssignmentsManager/context';\nimport Modal from './Modal';\n\nimport type { ContentWrapperProps } from './types';\n\nconst ContextProvider: React.FC = (props) => {\n\tconst { values: initialValues } = props.form.getState();\n\tconst values = useFormValues(initialValues);\n\n\tconst datetime = useDatetimeItem({ id: values?.id });\n\n\t// add defaults from Apollo cache and override the set values from form state\n\tconst entity = useMemoStringify({ id: 'NEW_DATE', dbId: 0, ...datetime, ...values } as Datetime);\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default ContextProvider;\n","import { useMemo } from 'react';\n\nimport { FormWithConfig } from '@eventespresso/ee-components';\n\nimport useDatetimeFormConfig from '../useDateFormConfig';\nimport ContextProvider from './ContextProvider';\nimport type { ContentProps } from './types';\n\nconst Content: React.FC = ({ entityId, onClose, onSubmit }) => {\n\tconst config = useMemo(() => ({ onSubmit }), [onSubmit]);\n\tconst formConfig = useDatetimeFormConfig(entityId, config);\n\n\treturn ;\n};\n\nexport default Content;\n","import { useCallback } from 'react';\n\nimport {\n\tuseDatetimeMutator,\n\tuseUpdateTicketQtyByCapacity,\n\tuseDatetimeItem,\n\tuseDatetimes,\n} from '@eventespresso/edtr-services';\nimport { getHighestOrder } from '@eventespresso/predicates';\nimport type { EntityId } from '@eventespresso/data';\nimport { isInfinite, wait } from '@eventespresso/utils';\n\nimport { OnSubmit } from './types';\n\nconst useOnSubmit = (entityId: EntityId, onClose: VoidFunction): OnSubmit => {\n\tconst { createEntity, updateEntity } = useDatetimeMutator();\n\tconst datetime = useDatetimeItem({ id: entityId });\n\n\tconst { createBulkQtyUpdateInput, doQtyBulkUpdate } = useUpdateTicketQtyByCapacity();\n\tconst dates = useDatetimes();\n\n\tconst onSubmit = useCallback(\n\t\tasync (fields) => {\n\t\t\t// wait the next event cycle to fire up isLoading for submit button\n\t\t\tawait wait();\n\n\t\t\t// whether date capacity has been changed\n\t\t\tlet capacityChanged = false;\n\t\t\tlet id = entityId;\n\n\t\t\tonClose();\n\t\t\t// If it's an existing entity\n\t\t\tif (entityId) {\n\t\t\t\t// Update it\n\t\t\t\tawait updateEntity(fields);\n\n\t\t\t\tcapacityChanged = fields?.capacity !== datetime?.capacity;\n\t\t\t} else {\n\t\t\t\t// we need to set the order to be higher than those of all the existing ones\n\t\t\t\tconst order = fields.order || getHighestOrder(dates) + 1;\n\t\t\t\t// otherwise create it\n\t\t\t\tconst result = await createEntity({ ...fields, order });\n\n\t\t\t\t// Get the ID.\n\t\t\t\tid = result?.data?.createEspressoDatetime?.espressoDatetime?.id;\n\n\t\t\t\t// For new dates, capacity matters only if it's finite.\n\t\t\t\tcapacityChanged = !isInfinite(fields?.capacity);\n\t\t\t}\n\t\t\t// if true, we need to update the quantity of all the related tickets\n\t\t\tif (capacityChanged && id) {\n\t\t\t\tconst input = createBulkQtyUpdateInput(fields, fields?.tickets);\n\t\t\t\tawait doQtyBulkUpdate(input);\n\t\t\t}\n\t\t},\n\t\t[createBulkQtyUpdateInput, createEntity, dates, datetime, doQtyBulkUpdate, entityId, onClose, updateEntity]\n\t);\n\n\treturn onSubmit;\n};\n\nexport default useOnSubmit;\n","import { useCallback } from 'react';\n\nimport { EdtrGlobalModals } from '@eventespresso/edtr-services';\nimport { useGlobalModal } from '@eventespresso/registry';\n\nimport Content from './Content';\nimport { EntityEditModalData } from '@edtrUI/types';\nimport useOnSubmit from './useOnSubmit';\n\nconst Container: React.FC = () => {\n\tconst {\n\t\tgetData,\n\t\tisOpen,\n\t\tclose: closeEditDateModal,\n\t\tsetData,\n\t} = useGlobalModal(EdtrGlobalModals.EDIT_DATE);\n\tconst { close: closeNewDateModal } = useGlobalModal(EdtrGlobalModals.NEW_DATE);\n\n\tconst onClose = useCallback(() => {\n\t\tcloseEditDateModal();\n\t\tcloseNewDateModal();\n\t\t// reset the global modal data\n\t\tsetData({ entityId: null });\n\t}, [closeEditDateModal, closeNewDateModal, setData]);\n\n\tconst { entityId } = getData();\n\n\tconst onSubmit = useOnSubmit(entityId, onClose);\n\n\treturn isOpen && ;\n};\n\nexport default Container;\n","import { useCallback, useMemo } from 'react';\nimport * as R from 'ramda';\n\nimport { isTrashed } from '@eventespresso/predicates';\nimport { useDatetimeItem, useDatetimeMutator, useDeleteRelatedTickets, useEventId } from '@eventespresso/edtr-services';\nimport { useRelations } from '@eventespresso/services';\nimport type { EntityId } from '@eventespresso/data';\n\ntype Actions = {\n\tcopyDate: VoidFunction;\n\ttrashDate: VoidFunction;\n\tisTrashed: boolean;\n};\n\nconst useActions = (datetimeId: EntityId): Actions => {\n\t// Make sure to subscribe to Apollo cache\n\t// to avoid stale data\n\tconst datetime = useDatetimeItem({ id: datetimeId });\n\n\tconst eventId = useEventId();\n\n\tconst { createEntity, deleteEntity } = useDatetimeMutator(datetimeId);\n\n\tconst { getRelations } = useRelations();\n\n\tconst tickets = getRelations({\n\t\tentity: 'datetimes',\n\t\tentityId: datetimeId,\n\t\trelation: 'tickets',\n\t});\n\n\tconst copyDate = useCallback(() => {\n\t\tconst newDatetime = R.pick(\n\t\t\t['capacity', 'description', 'endDate', 'isPrimary', 'name', 'order', 'startDate'],\n\t\t\tdatetime\n\t\t);\n\t\treturn createEntity({ ...newDatetime, eventId, tickets });\n\t}, [createEntity, datetime, eventId, tickets]);\n\n\tconst trashed = isTrashed(datetime);\n\n\tconst deleteRelatedTickets = useDeleteRelatedTickets();\n\n\tconst trashDate = useCallback(async () => {\n\t\tawait deleteEntity({ id: datetimeId, deletePermanently: trashed });\n\t\tawait deleteRelatedTickets(datetimeId, trashed);\n\t}, [deleteEntity, deleteRelatedTickets, datetimeId, trashed]);\n\n\treturn useMemo(\n\t\t() => ({\n\t\t\tcopyDate,\n\t\t\ttrashDate,\n\t\t\tisTrashed: trashed,\n\t\t}),\n\t\t[copyDate, trashDate, trashed]\n\t);\n};\n\nexport default useActions;\n","import { __ } from '@eventespresso/i18n';\nimport { AlertType, TrashEntity, useConfirmationDialog } from '@eventespresso/ui-components';\nimport { Trash as TrashIcon } from '@eventespresso/icons';\nimport { useDatesListFilterState } from '@eventespresso/edtr-services';\nimport useActions from './useActions';\nimport type { Datetime } from '@eventespresso/edtr-services';\n\nexport interface DeleteDatetimeProps {\n\tdatetime: Datetime;\n}\n\nexport const DeleteDatetime: React.FC = ({ datetime }) => {\n\tconst { trashDate, isTrashed } = useActions(datetime.id);\n\tconst isTheOnlyDate = useDatesListFilterState().total === 1;\n\tconst trashDateTitle = isTrashed ? __('delete permanently') : __('trash datetime');\n\tconst cannotBeDeleted = isTrashed && isTheOnlyDate;\n\n\tconst title = isTrashed ? __('Permanently Delete Datetime?') : __('Move Datetime to Trash?');\n\tconst message = isTrashed\n\t\t? __(\n\t\t\t\t'Are you sure you want to permanently delete this datetime? This action is permanent and can not be undone.'\n\t\t )\n\t\t: __(\n\t\t\t\t'Are you sure you want to move this datetime to the trash? You can \"untrash\" this datetime later if you need to.'\n\t\t );\n\tconst { confirmationDialog, onOpen } = useConfirmationDialog({\n\t\taddIconBG: true,\n\t\talertType: AlertType.ACCENT,\n\t\ticon: TrashIcon,\n\t\tmessage,\n\t\ttitle,\n\t\tonConfirm: trashDate,\n\t\tyesButtonText: __('delete'),\n\t});\n\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t{confirmationDialog}\n\t\t\n\t);\n};\n","import { useCallback, useMemo } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { CopyEntity, DropdownMenu, DropdownToggleProps, EditEntity } from '@eventespresso/ui-components';\nimport { EdtrGlobalModals } from '@eventespresso/edtr-services';\nimport { useGlobalModal } from '@eventespresso/registry';\nimport type { EntityEditModalData } from '@edtrUI/types';\n\nimport { DeleteDatetime } from './DeleteDatetime';\nimport useActions from './useActions';\nimport type { DateMainMenuProps } from './types';\n\nconst DateMainMenu: React.FC = ({ datetime }) => {\n\tconst { copyDate } = useActions(datetime.id);\n\tconst { openWithData } = useGlobalModal(EdtrGlobalModals.EDIT_DATE);\n\n\tconst toggleProps: DropdownToggleProps = useMemo(\n\t\t() => ({\n\t\t\tclassName: 'ee-date-main-menu',\n\t\t\t'data-testid': `ee-datetime-main-menu-${datetime.dbId}`,\n\t\t\ttooltip: __('event datetime main menu'),\n\t\t}),\n\t\t[datetime.dbId]\n\t);\n\n\tconst onOpenEditModal = useCallback(() => {\n\t\topenWithData({ entityId: datetime.id });\n\t}, [datetime.id, openWithData]);\n\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default DateMainMenu;\n","import { useCallback } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { EdtrGlobalModals, useRelatedTickets } from '@eventespresso/edtr-services';\nimport { IconButton, ItemCount } from '@eventespresso/ui-components';\nimport { Ticket } from '@eventespresso/icons';\nimport { TypeName, withIsLoaded } from '@eventespresso/services';\nimport { useGlobalModal } from '@eventespresso/registry';\nimport type { BaseProps } from '@edtrUI/ticketAssignmentsManager';\n\nimport type { Datetime } from '@eventespresso/edtr-services';\nimport type { EntityListItemProps } from '@eventespresso/ui-components';\n\nconst AssignTicketsButton: React.FC> = ({ entity }) => {\n\tconst { openWithData } = useGlobalModal(EdtrGlobalModals.TAM);\n\n\tconst getRelatedTickets = useRelatedTickets();\n\n\tconst count = getRelatedTickets({\n\t\tentity: 'datetimes',\n\t\tentityId: entity.id,\n\t}).length;\n\n\tconst title = count\n\t\t? __('Number of related tickets')\n\t\t: __('There are no tickets assigned to this datetime. Please click the ticket icon to update the assignments.');\n\n\tconst onOpen = useCallback(() => {\n\t\topenWithData({ entity, assignmentType: 'forDate' });\n\t}, [entity, openWithData]);\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withIsLoaded>(TypeName.tickets, ({ entity, loaded }) => {\n\t/* Hide TAM unless tickets are loaded */\n\treturn loaded && ;\n});\n","/**\n * This file registers the UI elements related to datetime UI via registry package\n */\nimport {\n\tEntityActionsSubscription,\n\tEntityActionsSubscriptionCb,\n\tModalSubscription,\n\tFilterBarUISubscription,\n\tFilterBarUISubscriptionCb,\n} from '@eventespresso/registry';\nimport {\n\tdomain,\n\tEdtrGlobalModals,\n\tDatetime,\n\tDatetimesFilterStateManager,\n\tdatesList,\n\tNewDateOption,\n} from '@eventespresso/edtr-services';\nimport { EdtrSlots } from '@eventespresso/services';\nimport { FilterBarFilter } from '@eventespresso/ui-components';\nimport { registerPlugin } from '@eventespresso/plugins';\n\nimport {\n\tDisplayStartOrEndDateControl,\n\tSalesControl,\n\tSortByControl,\n\tStatusControl,\n} from '@edtrUI/datetimes/datesList/filterBar/controls';\nimport { NewDateModal, AddSingleDate } from '@edtrUI/datetimes/datesList/newDateOptions';\nimport { Container as EditDateContainer } from '@edtrUI/datetimes/dateForm/multiStep';\nimport { DateMainMenu } from '@edtrUI/datetimes/datesList/actionsMenu/dropdown';\nimport AssignTicketsButton from '@edtrUI/datetimes/datesList/actionsMenu/AssignTicketsButton';\n\n// Register date modal containers\nconst modals = new ModalSubscription(domain);\nmodals.subscribe(({ registry: { registerContainer } }) => {\n\t// Register new date popover\n\tregisterContainer(EdtrGlobalModals.NEW_DATE, NewDateModal);\n\t// Register edit date modal\n\tregisterContainer(EdtrGlobalModals.EDIT_DATE, EditDateContainer);\n});\n\n// Register datetime actions menu items.\nconst entityActions = new EntityActionsSubscription(domain);\nconst datesActionHandler: EntityActionsSubscriptionCb = ({ entityType, entity, registry }) => {\n\t// although this is not needed\n\tif (entityType !== 'datetime') {\n\t\treturn;\n\t}\n\n\tconst { registerElement: registerMenuItem } = registry;\n\n\tregisterMenuItem('dateMainMenu', () => );\n\n\tregisterMenuItem('assignTickets', () => );\n};\n\nentityActions.subscribe(datesActionHandler, { entityType: 'datetime' });\n\n// Register datetime filterbar elements\nconst filterBar = new FilterBarUISubscription(domain);\ntype DatesListFilterBarCallback = FilterBarUISubscriptionCb;\nconst datesListFilterBar: DatesListFilterBarCallback = ({ listId, registry }) => {\n\t// although this is not needed\n\tif (listId !== datesList) {\n\t\treturn;\n\t}\n\n\tconst { registerElement: registerFilterBarItem } = registry;\n\n\tregisterFilterBarItem('status', () => {\n\t\treturn (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t);\n\t});\n\n\tregisterFilterBarItem('sales', () => {\n\t\treturn (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t);\n\t});\n\n\tregisterFilterBarItem('displayStartOrEndDate', () => {\n\t\treturn (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t);\n\t});\n\n\tregisterFilterBarItem('sortBy', () => {\n\t\treturn (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t);\n\t});\n};\n\nfilterBar.subscribe(datesListFilterBar, { listId: datesList });\n\nregisterPlugin(EdtrSlots.ADD_SINGLE_DATE_OPTION, {\n\trender: () => (\n\t\t\n\t\t\t{({ count }) => {\n\t\t\t\treturn ;\n\t\t\t}}\n\t\t\n\t),\n});\n","import { useCallback } from 'react';\nimport * as R from 'ramda';\n\nimport { useTicketPrices } from '@eventespresso/edtr-services';\nimport type { EntityId } from '@eventespresso/data';\nimport { useTicketMutator } from '@eventespresso/edtr-services';\nimport { getGuids, entitiesWithGuIdNotInArray } from '@eventespresso/predicates';\nimport { usePriceQueryOptions } from '@eventespresso/edtr-services';\nimport type { PricesList } from '@eventespresso/edtr-services';\nimport { useApolloClient } from '@eventespresso/data';\n\ntype Callback = (deletePermanently?: boolean) => Promise;\n\nconst useDeleteTicketHandler = (id: EntityId): Callback => {\n\tconst { deleteEntity: deleteTicket } = useTicketMutator();\n\tconst getTicketPrices = useTicketPrices();\n\tconst priceQueryOptions = usePriceQueryOptions();\n\tconst client = useApolloClient();\n\n\t/**\n\t * Deletes the related prices from Apollo cache,\n\t * permanent deletion is handled server-side\n\t */\n\tconst deleteRelatedPrices = useCallback(() => {\n\t\t// The prices that are not default or tax prices.\n\t\tconst pricesToDelete = getTicketPrices(id).filter(({ isDefault, isTax }) => !isDefault && !isTax);\n\t\t// if we have nothing to delete\n\t\tif (!pricesToDelete.length) {\n\t\t\treturn;\n\t\t}\n\t\tconst priceIdsToDelete = getGuids(pricesToDelete);\n\t\t// read existing data from Apollo cache\n\t\tconst data = client.readQuery(priceQueryOptions);\n\t\t// filter out the related prices from Apollo cache data\n\t\tconst pricesToRetain = entitiesWithGuIdNotInArray(data?.espressoPrices?.nodes || [], priceIdsToDelete);\n\t\t// avoid the dirty object creation using assocPath\n\t\tconst newData = R.assocPath(['espressoPrices', 'nodes'], pricesToRetain, data);\n\n\t\t// write the data back to cache\n\t\tclient.writeQuery({\n\t\t\t...priceQueryOptions,\n\t\t\tdata: newData,\n\t\t});\n\t}, [client, getTicketPrices, id, priceQueryOptions]);\n\n\treturn useCallback(\n\t\t(deletePermanently) => {\n\t\t\treturn (\n\t\t\t\tdeleteTicket({ id, deletePermanently })\n\t\t\t\t\t// delete prices only if ticket is deleted permanently\n\t\t\t\t\t.then(() => deletePermanently && deleteRelatedPrices())\n\t\t\t\t\t.catch(console.error)\n\t\t\t);\n\t\t},\n\t\t[deleteTicket, id, deleteRelatedPrices]\n\t);\n};\n\nexport default useDeleteTicketHandler;\n","import { useCallback } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { Ticket, useTicketsListFilterState } from '@eventespresso/edtr-services';\nimport { Trash as TrashIcon } from '@eventespresso/icons';\nimport { AlertType, TrashEntity, useConfirmationDialog } from '@eventespresso/ui-components';\nimport { isTrashed as isTicketTrashed, isLocked } from '@eventespresso/predicates';\nimport { useLockedTicketAction } from '@eventespresso/tpc';\n\nimport useDeleteTicketHandler from '@edtrUI/tickets/hooks/useDeleteTicketHandler';\n\nexport interface DeleteTicketProps {\n\tticket: Ticket;\n}\n\nexport const DeleteTicket: React.FC = ({ ticket }) => {\n\tconst isTrashed = isTicketTrashed(ticket);\n\n\tconst title = isTrashed ? __('Permanently Delete Ticket?') : __('Move Ticket to Trash?');\n\n\tconst message = isTrashed\n\t\t? __('Are you sure you want to permanently delete this ticket? This action is permanent and can not be undone.')\n\t\t: __(\n\t\t\t\t`Are you sure you want to move this ticket to the trash? You can \"untrash\" this ticket later if you need to.`\n\t\t );\n\n\tconst deleteTicket = useDeleteTicketHandler(ticket.id);\n\n\tconst onConfirmDelete = useCallback(() => {\n\t\tdeleteTicket(isTrashed);\n\t}, [deleteTicket, isTrashed]);\n\n\tconst { confirmationDialog, onOpen: confirmDelete } = useConfirmationDialog({\n\t\taddIconBG: true,\n\t\talertType: AlertType.ACCENT,\n\t\ticon: TrashIcon,\n\t\tmessage,\n\t\ttitle,\n\t\tonConfirm: onConfirmDelete,\n\t});\n\n\tconst { alertContainer, showAlert } = useLockedTicketAction(ticket);\n\n\tconst isTheOnlyTicket = useTicketsListFilterState().total === 1;\n\n\tconst cannotBeDeleted = isTrashed && isTheOnlyTicket;\n\n\tconst deleteTicketTitle = isTrashed ? __('delete permanently') : __('trash ticket');\n\n\tconst onDelete = isTrashed && isLocked(ticket) ? showAlert : confirmDelete;\n\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t{confirmationDialog}\n\t\t\t{alertContainer}\n\t\t\n\t);\n};\n","import { useCallback, useMemo } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { CopyEntity, DropdownMenu, DropdownToggleProps, EditEntity } from '@eventespresso/ui-components';\nimport { EdtrGlobalModals, useTicketItem } from '@eventespresso/edtr-services';\nimport { useGlobalModal } from '@eventespresso/registry';\nimport { useCopyTicket } from '@eventespresso/tpc';\n\nimport type { TicketMainMenuProps } from './types';\nimport { EntityEditModalData } from '@edtrUI/types';\nimport { DeleteTicket } from './DeleteTicket';\n\nconst TicketMainMenu: React.FC = (props) => {\n\tconst ticketId = props.ticket.id;\n\t// Make sure to subscribe to Apollo cache\n\t// to avoid stale data\n\tconst ticket = useTicketItem({ id: ticketId });\n\n\tconst copyTicket = useCopyTicket(ticket);\n\n\tconst toggleProps: DropdownToggleProps = useMemo(\n\t\t() => ({\n\t\t\tclassName: 'ee-ticket-main-menu',\n\t\t\t'data-testid': `ee-ticket-main-menu-${ticket.dbId}`,\n\t\t\ttooltip: __('ticket main menu'),\n\t\t}),\n\t\t[ticket.dbId]\n\t);\n\n\tconst { openWithData } = useGlobalModal(EdtrGlobalModals.EDIT_TICKET);\n\n\tconst onOpenEditModal = useCallback(() => {\n\t\topenWithData({ entityId: ticketId });\n\t}, [ticketId, openWithData]);\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default TicketMainMenu;\n","import * as yup from 'yup';\n\nimport { datesSchema, TicketFormShape } from '@eventespresso/edtr-services';\nimport { yupToFinalFormErrors } from '@eventespresso/form';\n\nexport const validate = async (values: TicketFormShape): Promise => {\n\treturn await yupToFinalFormErrors(validationSchema, values);\n};\n\nconst validationSchema = yup.object({\n\tname: yup.string(),\n\t...datesSchema,\n});\n","import { useMemo, useCallback } from 'react';\nimport * as R from 'ramda';\n\nimport { __ } from '@eventespresso/i18n';\nimport { CalendarOutlined, ControlOutlined, ProfileOutlined } from '@eventespresso/icons';\nimport { EndDateFieldWrapper } from '@eventespresso/ee-components';\nimport { EntityId } from '@eventespresso/data';\nimport { NOW, PLUS_ONE_MONTH, USE_ADVANCED_EDITOR } from '@eventespresso/constants';\nimport { preparePricesForTpc, usePriceToTpcModifier } from '@eventespresso/tpc';\nimport { setDefaultTime } from '@eventespresso/dates';\nimport { startAndEndDateFixer, useTicketItem, hooks, useTicketPrices } from '@eventespresso/edtr-services';\nimport { useCurrentUserCan } from '@eventespresso/services';\nimport { useMemoStringify } from '@eventespresso/hooks';\nimport { useUtcISOToSiteDate, useSiteDateToUtcISO } from '@eventespresso/services';\nimport { VISIBILITY_OPTIONS, VISIBILITY_OPTIONS_INFO } from '@eventespresso/helpers';\n\nimport type { EspressoFormProps, FieldProps } from '@eventespresso/form';\nimport type { Ticket, TicketFormConfig } from '@eventespresso/edtr-services';\n\nimport { validate } from './formValidation';\n\nexport const FIELD_NAMES: Array = [\n\t'id',\n\t'description',\n\t'isDefault',\n\t'isRequired',\n\t'isTrashed',\n\t'max',\n\t'min',\n\t'name',\n\t'price',\n\t'quantity',\n\t'uses',\n\t'visibility',\n];\n\nconst decorators = [startAndEndDateFixer];\n\nconst adjacentFormItemProps = {\n\tclassName: 'ee-form-item-pair',\n};\n\nexport const useTicketFormConfig = (id: EntityId, config?: EspressoFormProps): TicketFormConfig => {\n\tconst ticket = useTicketItem({ id });\n\tconst currentUserCan = useCurrentUserCan();\n\n\tconst toUtcISO = useSiteDateToUtcISO();\n\tconst toSiteDate = useUtcISOToSiteDate();\n\n\tconst startDate = useMemoStringify(\n\t\tticket?.startDate ? toSiteDate(ticket?.startDate) : setDefaultTime(NOW, 'start')\n\t);\n\tconst endDate = useMemoStringify(\n\t\tticket?.endDate ? toSiteDate(ticket?.endDate) : setDefaultTime(PLUS_ONE_MONTH, 'end')\n\t);\n\n\tconst { onSubmit } = config;\n\n\t//### Submit function for Form Data\n\tconst onSubmitFrom: TicketFormConfig['onSubmit'] = useCallback(\n\t\t({ startDate, endDate, ...values }, form, ...restParams) => {\n\t\t\treturn onSubmit(\n\t\t\t\t{ ...values, startDate: toUtcISO(startDate), endDate: toUtcISO(endDate) },\n\t\t\t\tform,\n\t\t\t\t...restParams\n\t\t\t);\n\t\t},\n\t\t[onSubmit, toUtcISO]\n\t);\n\n\tconst getTicketPrices = useTicketPrices();\n\tconst priceToTpcModifier = usePriceToTpcModifier();\n\n\tconst initialValues = useMemo(() => {\n\t\tconst prices = preparePricesForTpc(getTicketPrices(ticket?.id), priceToTpcModifier);\n\n\t\treturn hooks.applyFilters(\n\t\t\t'eventEditor.ticketForm.initalValues',\n\t\t\t{\n\t\t\t\tvisibility: 'PUBLIC',\n\t\t\t\t...R.pick, 'prices'>, keyof Ticket>(FIELD_NAMES, ticket || {}),\n\t\t\t\t// set initial prices\n\t\t\t\tprices,\n\t\t\t\tstartDate,\n\t\t\t\tendDate,\n\t\t\t},\n\t\t\tticket\n\t\t);\n\t}, [endDate, getTicketPrices, priceToTpcModifier, startDate, ticket]);\n\n\tconst publicFields: Array = useMemo(() => {\n\t\treturn [\n\t\t\t{\n\t\t\t\tname: 'quantity',\n\t\t\t\tlabel: __('Quantity For Sale'),\n\t\t\t\tfieldType: 'number',\n\t\t\t\tparseAsInfinity: true,\n\t\t\t\tmax: 1000000,\n\t\t\t\tmin: -1,\n\t\t\t\tinfo:\n\t\t\t\t\t__('The maximum number of this ticket available for sale.') +\n\t\t\t\t\t'\\n' +\n\t\t\t\t\t__('Set to 0 to stop sales, or leave blank for no limit.'),\n\t\t\t\twidth: 'small',\n\t\t\t\tformControlProps: adjacentFormItemProps,\n\t\t\t},\n\t\t];\n\t}, []);\n\n\tconst advancedFields: Array = useMemo(() => {\n\t\treturn publicFields.concat([\n\t\t\t{\n\t\t\t\tname: 'uses',\n\t\t\t\tlabel: __('Number of Uses'),\n\t\t\t\tfieldType: 'number',\n\t\t\t\tparseAsInfinity: true,\n\t\t\t\tmax: 1000,\n\t\t\t\tmin: 0,\n\t\t\t\tinfo:\n\t\t\t\t\t__(\n\t\t\t\t\t\t'Controls the total number of times this ticket can be used, regardless of the number of dates it is assigned to.'\n\t\t\t\t\t) +\n\t\t\t\t\t'\\n' +\n\t\t\t\t\t__(\n\t\t\t\t\t\t'Example: A ticket might have access to 4 different dates, but setting this field to 2 would mean that the ticket could only be used twice. Leave blank for no limit.'\n\t\t\t\t\t),\n\t\t\t\twidth: 'small',\n\t\t\t\tformControlProps: adjacentFormItemProps,\n\t\t\t},\n\t\t\t{\n\t\t\t\tname: 'min',\n\t\t\t\tlabel: __('Minimum Quantity'),\n\t\t\t\tfieldType: 'number',\n\t\t\t\tmax: 1000000,\n\t\t\t\tmin: 0,\n\t\t\t\tinfo:\n\t\t\t\t\t__(\n\t\t\t\t\t\t'The minimum quantity that can be selected for this ticket. Use this to create ticket bundles or graduated pricing.'\n\t\t\t\t\t) +\n\t\t\t\t\t'\\n' +\n\t\t\t\t\t__('Leave blank for no minimum.'),\n\t\t\t\twidth: 'small',\n\t\t\t\tformControlProps: adjacentFormItemProps,\n\t\t\t},\n\t\t\t{\n\t\t\t\tname: 'max',\n\t\t\t\tlabel: __('Maximum Quantity'),\n\t\t\t\tfieldType: 'number',\n\t\t\t\tparseAsInfinity: true,\n\t\t\t\tmax: 1000000,\n\t\t\t\tmin: -1,\n\t\t\t\tinfo:\n\t\t\t\t\t__(\n\t\t\t\t\t\t'The maximum quantity that can be selected for this ticket. Use this to create ticket bundles or graduated pricing.'\n\t\t\t\t\t) +\n\t\t\t\t\t'\\n' +\n\t\t\t\t\t__('Leave blank for no maximum.'),\n\t\t\t\twidth: 'small',\n\t\t\t\tformControlProps: adjacentFormItemProps,\n\t\t\t},\n\t\t\t{\n\t\t\t\tname: 'isRequired',\n\t\t\t\tlabel: __('Required Ticket'),\n\t\t\t\tfieldType: 'switch',\n\t\t\t\tinfo: __('If enabled, the ticket must be selected and will appear first in ticket lists.'),\n\t\t\t\twidth: 'small',\n\t\t\t\tformControlProps: adjacentFormItemProps,\n\t\t\t},\n\t\t\t{\n\t\t\t\tname: 'isTrashed',\n\t\t\t\tlabel: __('Trash'),\n\t\t\t\tfieldType: 'switch',\n\t\t\t\tformControlProps: adjacentFormItemProps,\n\t\t\t},\n\t\t\t{\n\t\t\t\tname: 'visibility',\n\t\t\t\tlabel: __('Visibility'),\n\t\t\t\tfieldType: 'select',\n\t\t\t\tinfo: VISIBILITY_OPTIONS_INFO,\n\t\t\t\toptions: VISIBILITY_OPTIONS,\n\t\t\t},\n\t\t]);\n\t}, [publicFields]);\n\n\tconst ticketDetailsFields = currentUserCan(USE_ADVANCED_EDITOR) ? advancedFields : publicFields;\n\n\tconst sections = useMemo(() => {\n\t\treturn hooks.applyFilters(\n\t\t\t'eventEditor.ticketForm.sections',\n\t\t\t[\n\t\t\t\t{\n\t\t\t\t\tname: 'basics',\n\t\t\t\t\ticon: ProfileOutlined,\n\t\t\t\t\ttitle: __('Basics'),\n\t\t\t\t\tfields: [\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tname: 'name',\n\t\t\t\t\t\t\tlabel: __('Name'),\n\t\t\t\t\t\t\tfieldType: 'text',\n\t\t\t\t\t\t},\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tname: 'description',\n\t\t\t\t\t\t\tlabel: __('Description'),\n\t\t\t\t\t\t\tfieldType: 'simple-text-editor',\n\t\t\t\t\t\t},\n\t\t\t\t\t],\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\tname: 'sales',\n\t\t\t\t\ticon: CalendarOutlined,\n\t\t\t\t\ttitle: __('Ticket Sales'),\n\t\t\t\t\tfields: [\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tname: 'startDate',\n\t\t\t\t\t\t\tlabel: __('Start Date'),\n\t\t\t\t\t\t\tfieldType: 'datetimepicker',\n\t\t\t\t\t\t\trequired: true,\n\t\t\t\t\t\t\tformControlProps: adjacentFormItemProps,\n\t\t\t\t\t\t},\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tname: 'endDate',\n\t\t\t\t\t\t\tlabel: __('End Date'),\n\t\t\t\t\t\t\tfieldType: 'datetimepicker',\n\t\t\t\t\t\t\trequired: true,\n\t\t\t\t\t\t\twrapper: EndDateFieldWrapper,\n\t\t\t\t\t\t\tformControlProps: adjacentFormItemProps,\n\t\t\t\t\t\t},\n\t\t\t\t\t],\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\tname: 'details',\n\t\t\t\t\ticon: ControlOutlined,\n\t\t\t\t\ttitle: __('Details'),\n\t\t\t\t\tfields: ticketDetailsFields,\n\t\t\t\t},\n\t\t\t],\n\t\t\tticket\n\t\t);\n\t}, [ticket, ticketDetailsFields]);\n\n\treturn useMemo(\n\t\t() => ({\n\t\t\t...config,\n\t\t\tonSubmit: onSubmitFrom,\n\t\t\tdecorators,\n\t\t\tsubscription: {},\n\t\t\tinitialValues,\n\t\t\tvalidate,\n\t\t\tsections,\n\t\t}),\n\t\t[config, initialValues, onSubmitFrom, sections]\n\t);\n};\n\nexport default useTicketFormConfig;\n","import { __ } from '@eventespresso/i18n';\n\nimport { Calculator, Calendar, Ticket } from '@eventespresso/icons';\nimport { Steps, Step } from '@eventespresso/ui-components';\nimport { PrevNext } from '@eventespresso/hooks';\n\nconst TicketFormSteps: React.FC> = ({ current }) => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default TicketFormSteps;\n","import { TicketPriceCalculator, useSyncTPC2RFF } from '@eventespresso/tpc';\n\nconst TPCStep = () => {\n\tuseSyncTPC2RFF();\n\n\treturn ;\n};\n\nexport default TPCStep;\n","import { useEffect } from 'react';\n\nimport { useForm } from '@eventespresso/form';\nimport { useDataState as useTAMDataState } from '@edtrUI/ticketAssignmentsManager/data';\n\n/**\n * A custom hook which subscribes to TAM and TPC data and updates\n * RFF data when needed.\n */\nconst useDataListener: VoidFunction = () => {\n\tconst { getData } = useTAMDataState();\n\tconst { mutators, getState } = useForm();\n\tconst data = getData();\n\n\tconst id = getState().values.id || 'NEW_TICKET';\n\tuseEffect(() => {\n\t\t// update value of `datetimes` field in RFF state\n\t\tmutators.updateFieldValue('datetimes', data?.tickets?.[id]?.datetimes);\n\t}, [data, id, mutators]);\n};\n\nexport default useDataListener;\n","import { TicketAssignmentsManager } from '@edtrUI/ticketAssignmentsManager/components';\nimport useDataListener from './useDataListener';\n\nconst TAMStep = () => {\n\tuseDataListener();\n\n\treturn ;\n};\n\nexport default TAMStep;\n","import TicketFormSteps from './TicketFormSteps';\nimport { ModalBodyProps } from './types';\nimport { ASSIGN_DATES_STEP, TICKET_DETAILS_STEP, TICKET_PRICES_STEP } from './constants';\nimport TPCStep from './TPCStep';\nimport TAMStep from './TAMStep';\n\nconst ModalBody: React.FC = ({ children: body, steps }) => {\n\t// init data listener to update RFF data\n\n\treturn (\n\t\t
\n\t\t\t\n\t\t\t{/* RFF fields */}\n\t\t\t{steps.current === TICKET_DETAILS_STEP && body}\n\t\t\t{steps.current === TICKET_PRICES_STEP && }\n\t\t\t{steps.current === ASSIGN_DATES_STEP && }\n\t\t
\n\t);\n};\n\nexport default ModalBody;\n","export const TICKET_DETAILS_STEP = 0;\n\nexport const TICKET_PRICES_STEP = 1;\n\nexport const ASSIGN_DATES_STEP = 2;\n","import { useCallback } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { ButtonRow, ButtonType, Next, Previous, Submit } from '@eventespresso/ui-components';\nimport { withFormSubscription, FormSubscriptionProps } from '@eventespresso/ee-components';\nimport { hasEmptyPrices } from '@eventespresso/predicates';\nimport type { PrevNext } from '@eventespresso/hooks';\n\nimport { useDataState as useTAMDataState } from '@edtrUI/ticketAssignmentsManager/data';\nimport { ASSIGN_DATES_STEP, TICKET_DETAILS_STEP, TICKET_PRICES_STEP } from './constants';\n\ninterface FooterButtonsProps extends FormSubscriptionProps {\n\tsteps: PrevNext;\n}\n\nconst FooterButtons: React.FC = ({ form, hasErrors, steps, submitting }) => {\n\tconst { current, goto, prev, next } = steps;\n\tconst { hasOrphanEntities } = useTAMDataState();\n\tconst isSubmitDisabled = hasOrphanEntities();\n\n\tconst gotoDetails = useCallback(() => goto(TICKET_DETAILS_STEP), [goto]);\n\tconst gotoTAM = useCallback(() => goto(ASSIGN_DATES_STEP), [goto]);\n\n\tconst { values } = form.getState();\n\n\tconst isTPCSubmitDisabled = hasEmptyPrices(values?.prices || []);\n\n\treturn (\n\t\t\n\t\t\t{current === TICKET_DETAILS_STEP && (\n\t\t\t\t<>\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t)}\n\n\t\t\t{current === TICKET_PRICES_STEP && (\n\t\t\t\t<>\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t)}\n\n\t\t\t{current === ASSIGN_DATES_STEP && (\n\t\t\t\t<>\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t)}\n\t\t\n\t);\n};\n\nexport default withFormSubscription(FooterButtons);\n","import { useMemo } from 'react';\n\nimport { EntityEditModal } from '@eventespresso/ee-components';\nimport { EdtrGlobalModals, useEvent, useTicketItem } from '@eventespresso/edtr-services';\nimport { useGlobalModal } from '@eventespresso/registry';\nimport { __, sprintf } from '@eventespresso/i18n';\nimport { usePrevNext } from '@eventespresso/hooks';\nimport { useIsPristine } from '@eventespresso/form';\nimport type { ModalProps } from '@eventespresso/adapters';\n\nimport ModalBody from './ModalBody';\nimport type { ContentWrapperProps } from './types';\nimport type { EntityEditModalData } from '@edtrUI/types';\nimport FooterButtons from './FooterButtons';\n\nconst Modal: React.FC = ({ onClose, ...props }) => {\n\tconst { isOpen } = useGlobalModal(EdtrGlobalModals.EDIT_TICKET);\n\tconst event = useEvent();\n\tconst steps = usePrevNext();\n\tconst isPristine = useIsPristine();\n\n\tconst { values } = props.form.getState();\n\n\tconst ticket = useTicketItem({ id: values?.id });\n\n\tlet title = ticket?.dbId\n\t\t? sprintf(\n\t\t\t\t/* translators: %1$s ticket name, %2$s ticket id */\n\t\t\t\t__('Edit ticket \"%1$s\" - %2$s'),\n\t\t\t\tticket.name,\n\t\t\t\t`#${ticket.dbId}`\n\t\t )\n\t\t: __('New Ticket Details');\n\n\t// add event name to the title\n\ttitle = event?.name ? `${event.name}: ${title}` : title;\n\n\tconst footerButtons = ;\n\n\tconst ariaAttributes: ModalProps['ariaAttributes'] = useMemo(() => {\n\t\tconst getAriaLabel = (): string => {\n\t\t\tif (!ticket || !ticket.name) {\n\t\t\t\treturn __('modal for ticket');\n\t\t\t}\n\t\t\t/* translators: %s ticket name */\n\t\t\treturn sprintf('modal for ticket %s', ticket.name);\n\t\t};\n\t\treturn {\n\t\t\tmodalContent: { 'aria-label': getAriaLabel() },\n\t\t};\n\t}, [ticket]);\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default Modal;\n","import { useCallback } from 'react';\n\nimport { useFormValues } from '@eventespresso/form';\nimport { Ticket, TicketFormShape, useTicketItem, useTicketPrices } from '@eventespresso/edtr-services';\nimport { useMemoStringify } from '@eventespresso/hooks';\nimport { ContextProvider as TPCContextProvider, usePriceToTpcModifier, preparePricesForTpc } from '@eventespresso/tpc';\n\nimport { ContextProvider as TAMContextProvider } from '@edtrUI/ticketAssignmentsManager/context';\nimport Modal from './Modal';\n\nimport type { ContentWrapperProps } from './types';\n\nconst ContextProvider: React.FC = (props) => {\n\tconst { values: initialValues } = props.form.getState();\n\tconst values = useFormValues(initialValues);\n\n\tconst ticket = useTicketItem({ id: values?.id });\n\tconst priceToTpcModifier = usePriceToTpcModifier();\n\tconst getTheTicketPrices = useTicketPrices();\n\n\t// add defaults from Apollo cache and override the set values from form state\n\tconst entity = useMemoStringify({ id: 'NEW_TICKET', dbId: 0, ...ticket, ...values } as Ticket);\n\n\tconst getTicket = useCallback(() => entity, [entity]);\n\n\tconst getTicketPrices = useCallback(\n\t\t(ticketId: string) => {\n\t\t\t// we have prices in the form values, it means they have been added, lets use those\n\t\t\tconst prices = values?.prices || preparePricesForTpc(getTheTicketPrices(ticketId), priceToTpcModifier);\n\n\t\t\treturn prices;\n\t\t},\n\t\t[priceToTpcModifier, getTheTicketPrices, values?.prices]\n\t);\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default ContextProvider;\n","import { useMemo } from 'react';\n\nimport { FormWithConfig } from '@eventespresso/ee-components';\n\nimport useTicketFormConfig from '../useTicketFormConfig';\nimport ContextProvider from './ContextProvider';\nimport type { ContentProps } from './types';\n\nconst Content: React.FC = ({ entityId, onClose, onSubmit }) => {\n\tconst config = useMemo(() => ({ onSubmit }), [onSubmit]);\n\tconst formConfig = useTicketFormConfig(entityId, config);\n\n\treturn ;\n};\n\nexport default Content;\n","import { useCallback } from 'react';\n\nimport { useMutateTicket } from '@eventespresso/tpc';\nimport { wait } from '@eventespresso/utils';\n\nimport { useCappedQuantity } from '@eventespresso/edtr-services';\nimport { OnSubmit } from './types';\n\nconst useOnSubmit = (onClose: VoidFunction): OnSubmit => {\n\tconst mutateTicket = useMutateTicket();\n\n\tconst getCappedQuantity = useCappedQuantity();\n\tconst onSubmit = useCallback(\n\t\tasync (fields) => {\n\t\t\t// wait the next event cycle to fire up isLoading for submit button\n\t\t\tawait wait();\n\t\t\t// close the modal\n\t\t\tonClose();\n\t\t\t// get the capped quantity for ticket based on the related date(s)\n\t\t\tconst quantity = getCappedQuantity({ quantity: fields.quantity, relatedDateIds: fields.datetimes });\n\n\t\t\tconst input = {\n\t\t\t\t...fields,\n\t\t\t\tisModified: Boolean(fields.id), // should be updated if there is an id\n\t\t\t\tisNew: !fields.id, // it's new if id is empty\n\t\t\t\tquantity,\n\t\t\t};\n\n\t\t\tawait mutateTicket(input);\n\t\t},\n\t\t[getCappedQuantity, mutateTicket, onClose]\n\t);\n\n\treturn onSubmit;\n};\n\nexport default useOnSubmit;\n","import { useCallback } from 'react';\n\nimport { EdtrGlobalModals } from '@eventespresso/edtr-services';\nimport { useGlobalModal } from '@eventespresso/registry';\n\nimport Content from './Content';\nimport { EntityEditModalData } from '@edtrUI/types';\nimport useOnSubmit from './useOnSubmit';\n\nconst Container: React.FC = () => {\n\tconst {\n\t\tgetData,\n\t\tisOpen,\n\t\tclose: closeModal,\n\t\tsetData,\n\t} = useGlobalModal(EdtrGlobalModals.EDIT_TICKET);\n\n\tconst onClose = useCallback(() => {\n\t\tcloseModal();\n\t\t// reset the global modal data\n\t\tsetData({ entityId: null });\n\t}, [closeModal, setData]);\n\n\tconst { entityId } = getData();\n\n\tconst onSubmit = useOnSubmit(onClose);\n\n\treturn isOpen && ;\n};\n\nexport default Container;\n","import { useCallback, useMemo } from 'react';\n\nimport { SimpleTicketCard } from '@eventespresso/ee-components';\nimport { SimpleEntityRendererProps } from '@eventespresso/ui-components';\nimport { LOCALIZED_DATE_AND_TIME_SHORT_FORMAT } from '@eventespresso/constants';\nimport { useTimeZoneTime, useCurrentUserCan } from '@eventespresso/services';\nimport { DefaultTicket } from './data';\n\nconst TicketCard: React.FC> = ({ entity: ticket, onEdit, onDelete }) => {\n\tconst { formatForSite } = useTimeZoneTime();\n\tconst currentUserCan = useCurrentUserCan();\n\n\tconst renderStartDate = useCallback(\n\t\t({ startDate }) => {\n\t\t\treturn formatForSite(startDate, LOCALIZED_DATE_AND_TIME_SHORT_FORMAT);\n\t\t},\n\t\t[formatForSite]\n\t);\n\n\tconst renderEndDate = useCallback(\n\t\t({ endDate }) => {\n\t\t\treturn formatForSite(endDate, LOCALIZED_DATE_AND_TIME_SHORT_FORMAT);\n\t\t},\n\t\t[formatForSite]\n\t);\n\n\tconst showAfterDetails = Boolean(ticket.startDate && ticket.endDate);\n\n\tconst deleteButtonProps = useMemo(() => {\n\t\treturn { isDisabled: !currentUserCan('delete', 'default_ticket', ticket) };\n\t}, [currentUserCan, ticket]);\n\n\tconst editButtonProps = useMemo(() => {\n\t\treturn { isDisabled: !currentUserCan('edit', 'default_ticket', ticket) };\n\t}, [currentUserCan, ticket]);\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default TicketCard;\n","import { useMemo } from 'react';\nimport * as R from 'ramda';\n\nimport type { EspressoFormProps } from '@eventespresso/form';\nimport { Ticket, TicketFormConfig } from '@eventespresso/edtr-services';\nimport useMainTicketFormConfig, { FIELD_NAMES } from '../../ticketForm/useTicketFormConfig';\nimport { DefaultTicket } from '../data';\n\nconst useTicketFormConfig = (ticket?: DefaultTicket, config?: EspressoFormProps): TicketFormConfig => {\n\tconst newConfig = useMainTicketFormConfig(ticket?.id, config);\n\n\treturn useMemo(\n\t\t() => ({\n\t\t\t...newConfig,\n\t\t\tinitialValues: {\n\t\t\t\t...newConfig?.initialValues,\n\t\t\t\t...R.pick, 'prices'>, keyof Ticket>(FIELD_NAMES, ticket || {}),\n\t\t\t},\n\t\t}),\n\t\t[newConfig, ticket]\n\t);\n};\n\nexport default useTicketFormConfig;\n","import { __ } from '@eventespresso/i18n';\n\nimport { Steps, Step } from '@eventespresso/ui-components';\nimport { PrevNext } from '@eventespresso/hooks';\nimport { Calculator, Calendar, Ticket } from '@eventespresso/icons';\n\nconst TicketFormSteps: React.FC> = ({ current }) => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default TicketFormSteps;\n","import { TicketPriceCalculator, useSyncTPC2RFF } from '@eventespresso/tpc';\n\nconst TPCStep = () => {\n\tuseSyncTPC2RFF();\n\n\treturn ;\n};\n\nexport default TPCStep;\n","import TicketFormSteps from './TicketFormSteps';\nimport { ModalBodyProps } from './types';\nimport { TICKET_DETAILS_STEP, TICKET_PRICES_STEP } from '../../ticketForm/multiStep/constants';\nimport TPCStep from './TPCStep';\n\n/**\n * This component is inside both RFF and TAM contexts, so we can use all of their features\n */\nconst ModalBody: React.FC = ({ children: body, steps }) => {\n\treturn (\n\t\t
\n\t\t\t\n\t\t\t{/* RFF fields */}\n\t\t\t{steps.current === TICKET_DETAILS_STEP && body}\n\n\t\t\t{steps.current === TICKET_PRICES_STEP && }\n\t\t
\n\t);\n};\n\nexport default ModalBody;\n","import { __ } from '@eventespresso/i18n';\nimport { ButtonRow, ButtonType, Next, Previous, Submit } from '@eventespresso/ui-components';\nimport { withFormSubscription, FormSubscriptionProps } from '@eventespresso/ee-components';\nimport { hasEmptyPrices } from '@eventespresso/predicates';\nimport type { PrevNext } from '@eventespresso/hooks';\n\nimport { TICKET_DETAILS_STEP, TICKET_PRICES_STEP } from '../../ticketForm/multiStep/constants';\n\ninterface FooterButtonsProps extends FormSubscriptionProps {\n\tsteps: PrevNext;\n}\n\nconst FooterButtons: React.FC = ({ form, hasErrors, steps }) => {\n\tconst { current, prev, next } = steps;\n\n\tconst { values } = form.getState();\n\n\tconst isTPCSubmitDisabled = hasEmptyPrices(values?.prices || []);\n\n\treturn (\n\t\t\n\t\t\t{/* RFF fields */}\n\t\t\t{current === TICKET_DETAILS_STEP && (\n\t\t\t\t<>\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t)}\n\n\t\t\t{current === TICKET_PRICES_STEP && (\n\t\t\t\t<>\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t)}\n\t\t\n\t);\n};\n\nexport default withFormSubscription(FooterButtons);\n","import { EntityEditModal } from '@eventespresso/ui-components';\nimport { __, sprintf } from '@eventespresso/i18n';\nimport { usePrevNext } from '@eventespresso/hooks';\nimport { useIsPristine } from '@eventespresso/form';\n\nimport ModalBody from './ModalBody';\n\nimport type { ContextProviderProps } from './types';\nimport FooterButtons from './FooterButtons';\nimport { useDataState } from '../data';\n\nconst Modal: React.FC = ({ onClose, ...props }) => {\n\tconst steps = usePrevNext();\n\tconst isPristine = useIsPristine();\n\tconst { tickets } = useDataState();\n\n\tconst ticketId = props.form.getState().values?.id;\n\n\tconst title = tickets[ticketId]?.dbId\n\t\t? sprintf(\n\t\t\t\t/* translators: %s ticket id */\n\t\t\t\t__('Edit ticket %s'),\n\t\t\t\t`#${tickets[ticketId].dbId}`\n\t\t )\n\t\t: __('New Ticket Details');\n\n\tconst footerButtons = ;\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default Modal;\n","import { useCallback } from 'react';\n\nimport { withContext as withTPCContext } from '@eventespresso/tpc';\n\nimport type { ContextProviderProps } from './types';\nimport Modal from './Modal';\nimport { useDataState } from '../data';\n\nconst ContextProvider: React.FC = (props) => {\n\tconst { tickets } = useDataState();\n\tconst { values } = props.form.getState();\n\n\tconst getTicket = useCallback((id) => tickets[id], [tickets]);\n\n\tconst getTicketPrices = useCallback((id) => tickets[id]?.prices || [], [tickets]);\n\n\tconst Component = withTPCContext(Modal, {\n\t\tticketId: values.id,\n\t\tgetTicketPrices,\n\t\tgetTicket,\n\t});\n\n\treturn ;\n};\n\nexport default ContextProvider;\n","import { useCallback } from 'react';\n\nimport { FormWithConfig } from '@eventespresso/ee-components';\n\nimport useTicketFormConfig from './useTicketFormConfig';\nimport ContextProvider from './ContextProvider';\nimport type { ContentRendererProps } from './types';\nimport { useDataState } from '../data';\n\nconst ContentRenderer: React.FC = ({ entity, onClose }) => {\n\tconst { addTicket, updateTicket } = useDataState();\n\n\tconst onSubmit = useCallback(\n\t\t(values) => {\n\t\t\tif (entity?.id) {\n\t\t\t\tupdateTicket(entity?.id, values);\n\t\t\t} else {\n\t\t\t\taddTicket({ ...values, isNew: true });\n\t\t\t}\n\t\t\tonClose();\n\t\t},\n\t\t[addTicket, entity?.id, onClose, updateTicket]\n\t);\n\tconst formConfig = useTicketFormConfig(entity, { onSubmit });\n\n\treturn ;\n};\n\nexport default ContentRenderer;\n","import { useCallback, useEffect, useMemo } from 'react';\n\nimport { SimpleEntityList, DebugInfo } from '@eventespresso/ui-components';\nimport { useTickets, useTicketPrices } from '@eventespresso/edtr-services';\nimport { usePrepTemplatePrices } from '@eventespresso/tpc';\nimport { __ } from '@eventespresso/i18n';\n\nimport { DefaultTicket, useDataState } from './data';\nimport TicketCard from './TicketCard';\nimport { ContentRenderer } from './multiStep';\n\nimport './styles.scss';\n\nconst ModalBody: React.FC = () => {\n\tconst { addTicket, tickets, deleteTicket, reset, getData } = useDataState();\n\tconst templates = useTickets();\n\tconst getTicketPrices = useTicketPrices();\n\tconst prepTemplatePrices = usePrepTemplatePrices();\n\n\tconst deleteEntity = useCallback(\n\t\t(ticket: DefaultTicket) => {\n\t\t\tdeleteTicket(ticket.id, ticket.isNew);\n\t\t},\n\t\t[deleteTicket]\n\t);\n\n\tconst entities = useMemo(() => Object.values(tickets), [tickets]);\n\n\tconst addEntity = useCallback(\n\t\t(entity) => {\n\t\t\tconst ticketPrices = getTicketPrices(entity.id);\n\t\t\tconst prices = prepTemplatePrices(ticketPrices);\n\t\t\taddTicket({\n\t\t\t\t...entity,\n\t\t\t\tisNew: true,\n\t\t\t\tdbId: 0,\n\t\t\t\tprices,\n\t\t\t\t/**\n\t\t\t\t * Ensure that ticket is not trashed,\n\t\t\t\t * as it's possible that a trashed ticket is used as a template\n\t\t\t\t *\n\t\t\t\t * @see https://github.com/eventespresso/barista/issues/1013\n\t\t\t\t */\n\t\t\t\tisTrashed: false,\n\t\t\t});\n\t\t},\n\t\t[addTicket, getTicketPrices, prepTemplatePrices]\n\t);\n\n\t// reset state on mount\n\tuseEffect(() => {\n\t\treset();\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\t}, []);\n\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default ModalBody;\n","import { useCallback } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { useGlobalModal } from '@eventespresso/registry';\nimport { EdtrGlobalModals } from '@eventespresso/edtr-services';\nimport { wait } from '@eventespresso/utils';\nimport { ModalWithAlert } from '@eventespresso/ui-components';\n\nimport { withContext } from './context';\nimport { useDataState, useSubmitForm } from './data';\nimport ModalBody from './ModalBody';\n\nconst Container: React.FC = () => {\n\tconst { close: closeModal, isOpen } = useGlobalModal(EdtrGlobalModals.DEFAULT_TICKETS);\n\n\tconst { getData, isDirty, reset } = useDataState();\n\n\tconst submitForm = useSubmitForm(getData());\n\n\tconst onSubmit = useCallback(async () => {\n\t\t// wait the next event cycle to fire up isLoading for submit button\n\t\tawait wait();\n\t\t// close modal\n\t\tcloseModal();\n\t\t// submit the data for mutations\n\t\tawait submitForm();\n\t\treset();\n\t}, [closeModal, reset, submitForm]);\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withContext(Container);\n","import { useCallback } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\n\nimport { Calendar } from '@eventespresso/icons';\nimport { IconButton, EntityListItemProps, ItemCount } from '@eventespresso/ui-components';\nimport { useRelatedDatetimes, EdtrGlobalModals } from '@eventespresso/edtr-services';\nimport { TypeName } from '@eventespresso/services';\nimport { withIsLoaded } from '@eventespresso/services';\nimport type { Ticket } from '@eventespresso/edtr-services';\nimport { useGlobalModal } from '@eventespresso/registry';\n\nimport { BaseProps } from '@edtrUI/ticketAssignmentsManager';\n\nconst AssignDatesButton: React.FC> = ({ entity }) => {\n\tconst { openWithData } = useGlobalModal(EdtrGlobalModals.TAM);\n\n\tconst relatedDatetimes = useRelatedDatetimes({\n\t\tentity: 'tickets',\n\t\tentityId: entity.id,\n\t});\n\n\tconst count = relatedDatetimes.length;\n\n\tconst title = count\n\t\t? __('Number of related dates')\n\t\t: __(\n\t\t\t\t'There are no event dates assigned to this ticket. Please click the calendar icon to update the assignments.'\n\t\t );\n\n\tconst onOpen = useCallback(() => {\n\t\topenWithData({ entity, assignmentType: 'forTicket' });\n\t}, [entity, openWithData]);\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withIsLoaded>(TypeName.datetimes, ({ entity, loaded }) => {\n\t/* Hide TAM unless dates are loaded */\n\treturn loaded && ;\n});\n","/**\n * This file registers the UI elements related to ticket UI via registry package\n */\nimport {\n\tEntityActionsSubscription,\n\tEntityActionsSubscriptionCb,\n\tModalSubscription,\n\tNewEntitySubscription,\n\tFilterBarUISubscription,\n\tFilterBarUISubscriptionCb,\n} from '@eventespresso/registry';\nimport { domain, EdtrGlobalModals, Ticket, TicketsFilterStateManager, ticketsList } from '@eventespresso/edtr-services';\nimport { TicketPriceCalculatorButton, ModalContainer as TPCModalContainer } from '@eventespresso/tpc';\nimport { FilterBarFilter } from '@eventespresso/ui-components';\n\nimport {\n\tDisplayStartOrEndDateControl,\n\tSalesControl,\n\tSortByControl,\n\tStatusControl,\n\tIsChainedButton,\n} from '@edtrUI/tickets/ticketsList/filterBar/controls';\nimport { TicketMainMenu } from '@edtrUI/tickets/ticketsList/actionsMenu/dropdown';\nimport { Container as EditTicketContainer } from '@edtrUI/tickets/ticketForm/multiStep';\nimport DefaultTicketContainer from '@edtrUI/tickets/defaultTickets/Container';\nimport AssignDatesButton from '@edtrUI/tickets/ticketsList/actionsMenu/AssignDatesButton';\nimport { AddSingleTicket } from '@edtrUI/tickets/ticketsList/newTicketOptions';\n\n// Register ticket modal containers\nconst modals = new ModalSubscription(domain);\nmodals.subscribe(({ registry: { registerContainer } }) => {\n\t// Register edit ticket modal\n\tregisterContainer(EdtrGlobalModals.EDIT_TICKET, EditTicketContainer);\n\t// Register default tickets modal\n\tregisterContainer(EdtrGlobalModals.DEFAULT_TICKETS, DefaultTicketContainer);\n\t// Register TPC modal\n\tregisterContainer(EdtrGlobalModals.TPC, TPCModalContainer);\n});\n\n// Register ticket actions menu items.\nconst entityActions = new EntityActionsSubscription(domain);\nconst ticketsActionHandler: EntityActionsSubscriptionCb = ({ entity: ticket, registry }) => {\n\tconst { registerElement: registerMenuItem } = registry;\n\n\tregisterMenuItem('ticketMainMenu', () => );\n\n\tregisterMenuItem('assignDates', () => );\n\n\tregisterMenuItem('ticketPriceCalculator', () => );\n};\nentityActions.subscribe(ticketsActionHandler, { entityType: 'ticket' });\n\n// Register new ticket option(s)\nconst newEntityOptions = new NewEntitySubscription(domain);\nnewEntityOptions.subscribe(\n\t({ registry }) => {\n\t\tconst { registerElement: registerOptionItem } = registry;\n\n\t\tregisterOptionItem('AddSingleTicket', ({ totalCount }) => {\n\t\t\treturn ;\n\t\t});\n\t},\n\t{ entityType: 'ticket' }\n);\n\n// Register ticket filterBar elements\nconst filterBar = new FilterBarUISubscription(domain);\ntype TicketsListFilterBarCallback = FilterBarUISubscriptionCb;\nconst ticketsListFilterBar: TicketsListFilterBarCallback = ({ listId, registry }) => {\n\t// although this is not needed\n\tif (listId !== ticketsList) {\n\t\treturn;\n\t}\n\tconst { registerElement: registerFilterBarItem } = registry;\n\n\tregisterFilterBarItem('status', () => {\n\t\treturn (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t);\n\t});\n\n\tregisterFilterBarItem('isChained', () => {\n\t\treturn (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t);\n\t});\n\n\tregisterFilterBarItem('sales', () => {\n\t\treturn (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t);\n\t});\n\n\tregisterFilterBarItem('displayStartOrEndDate', () => {\n\t\treturn (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t);\n\t});\n\n\tregisterFilterBarItem('sortBy', () => {\n\t\treturn (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t);\n\t});\n};\nfilterBar.subscribe(ticketsListFilterBar, { listId: ticketsList });\n","/**\n * This file registers the UI elements related to TAM UI via registry package\n */\n\nimport { ModalSubscription } from '@eventespresso/registry';\nimport { domain, EdtrGlobalModals } from '@eventespresso/edtr-services';\nimport { ModalContainer } from './components';\n\n// Register date modal containers\nconst modals = new ModalSubscription(domain);\nmodals.subscribe(({ registry: { registerContainer } }) => {\n\t// Register TAM modal\n\tregisterContainer(EdtrGlobalModals.TAM, ModalContainer);\n});\n","/**\n * This file registers the filters for dates list via registry package\n */\nimport { FilterBarService } from '@eventespresso/registry';\nimport { dateSalesFilter, dateStatusFilter, sortDates } from '@eventespresso/predicates';\nimport { datesList, domain } from '@eventespresso/edtr-services';\nimport { entityListSearch } from '@eventespresso/utils';\nimport type { Datetime } from '@eventespresso/edtr-services';\nimport type { DatetimesFilterStateManager } from '@eventespresso/edtr-services';\n\ntype Domain = typeof domain;\ntype DFSM = DatetimesFilterStateManager;\n\nconst {\n\tregisterFilter: registerDatesFilter,\n\tregisterSearch: registerDatesSearch,\n\tregisterSorter: registerDatesSorter,\n} = new FilterBarService(domain, datesList);\n\n// Register sales filter\nregisterDatesFilter(({ entityList, filterState }) => {\n\treturn dateSalesFilter({ dates: entityList, sales: filterState.sales });\n}, 11);\n\n// Register status filter\nregisterDatesFilter(({ entityList, filterState }) => {\n\treturn dateStatusFilter({ dates: entityList, status: filterState.status });\n}, 9);\n\n// Register search\nregisterDatesSearch(({ entityList, filterState }) => {\n\treturn entityListSearch({\n\t\tentities: entityList,\n\t\tsearchFields: ['name', 'description'],\n\t\tsearchText: filterState.searchText,\n\t});\n});\n\n// Register sorter\nregisterDatesSorter(({ entityList, filterState }) => {\n\treturn sortDates({ dates: entityList, sortBy: filterState.sortBy });\n});\n","/**\n * This file registers the filters for tickets list via registry package\n */\nimport { FilterBarService } from '@eventespresso/registry';\nimport { ticketSalesFilter, ticketStatusFilter, sortTickets } from '@eventespresso/predicates';\nimport { domain, ticketsList } from '@eventespresso/edtr-services';\nimport { entityListSearch } from '@eventespresso/utils';\nimport type { Ticket, TicketsFilterStateManager } from '@eventespresso/edtr-services';\n\ntype Domain = typeof domain;\ntype TFSM = TicketsFilterStateManager;\n\nconst {\n\tregisterFilter: registerTicketsFilter,\n\tregisterSearch: registerTicketsSearch,\n\tregisterSorter: registerTicketsSorter,\n} = new FilterBarService(domain, ticketsList);\n\n// Register sales filter\nregisterTicketsFilter(({ entityList, filterState }) => {\n\treturn ticketSalesFilter({ sales: filterState.sales, tickets: entityList });\n}, 11);\n\n// Register status filter\nregisterTicketsFilter(({ entityList, filterState }) => {\n\treturn ticketStatusFilter({ status: filterState.status, tickets: entityList });\n}, 10); // 10 by default\n\n// Register search\nregisterTicketsSearch(({ entityList, filterState }) => {\n\treturn entityListSearch({\n\t\tentities: entityList,\n\t\tsearchFields: ['name', 'description'],\n\t\tsearchText: filterState.searchText,\n\t});\n});\n\n// Register sorter\nregisterTicketsSorter(({ entityList, filterState }) => {\n\treturn sortTickets({ tickets: entityList, sortBy: filterState.sortBy });\n});\n","import { PluginArea } from '@eventespresso/plugins';\n\nimport { useEditorInitialization } from '../hooks';\nimport { Spinner } from '@eventespresso/adapters';\nimport { getRegisteredContainers } from '@edtrServices/utils';\n\nimport { DatesList } from './datetimes/datesList';\nimport EventRegistrationOptions from './EventRegistrationOptions';\nimport { TicketsList } from './tickets/ticketsList';\nimport EventDescription from './EventDescription';\nimport { VenueDetails } from './venue';\nimport { RegistrationForm } from './registrationForm';\nimport Notifications from './notifications/Notifications';\n\n// fire up the service and UI element registry\nimport './registryInit';\nimport './styles.scss';\n\nconst containers = getRegisteredContainers();\n\nconst EventEditor: React.FC = () => {\n\tconst isRehydrated = useEditorInitialization();\n\n\tif (!isRehydrated) {\n\t\treturn ;\n\t}\n\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t{containers}\n\t\t\t\n\t\t\n\t);\n};\n\nexport default EventEditor;\n","import { ContextProviders } from '@edtrServices/context';\nimport { renderDomElement } from '@eventespresso/utils';\n\nimport EventEditor from './EventEditor';\n\nimport '../../../../../../packages/styles/src/themes/default/index.scss'; // to bundle it\n\nconst Editor: React.FC = () => (\n\t\n\t\t\n\t\n);\n\nconst setupEditor = (): void => {\n\trenderDomElement({\n\t\tappendToTarget: false,\n\t\tdomElementToRender: ,\n\t\tcontainerID: 'ee-event-editor',\n\t\tcontainerClassName: 'ee-editor-container',\n\t\ttargetElementID: 'normal-sortables',\n\t});\n};\n\nsetupEditor();\n","(function() { module.exports = window[\"eventespresso\"][\"utils\"]; }());","/**\n * Copyright (c) 2014-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nvar runtime = (function (exports) {\n \"use strict\";\n\n var Op = Object.prototype;\n var hasOwn = Op.hasOwnProperty;\n var undefined; // More compressible than void 0.\n var $Symbol = typeof Symbol === \"function\" ? Symbol : {};\n var iteratorSymbol = $Symbol.iterator || \"@@iterator\";\n var asyncIteratorSymbol = $Symbol.asyncIterator || \"@@asyncIterator\";\n var toStringTagSymbol = $Symbol.toStringTag || \"@@toStringTag\";\n\n function define(obj, key, value) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n return obj[key];\n }\n try {\n // IE 8 has a broken Object.defineProperty that only works on DOM objects.\n define({}, \"\");\n } catch (err) {\n define = function(obj, key, value) {\n return obj[key] = value;\n };\n }\n\n function wrap(innerFn, outerFn, self, tryLocsList) {\n // If outerFn provided and outerFn.prototype is a Generator, then outerFn.prototype instanceof Generator.\n var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator;\n var generator = Object.create(protoGenerator.prototype);\n var context = new Context(tryLocsList || []);\n\n // The ._invoke method unifies the implementations of the .next,\n // .throw, and .return methods.\n generator._invoke = makeInvokeMethod(innerFn, self, context);\n\n return generator;\n }\n exports.wrap = wrap;\n\n // Try/catch helper to minimize deoptimizations. Returns a completion\n // record like context.tryEntries[i].completion. This interface could\n // have been (and was previously) designed to take a closure to be\n // invoked without arguments, but in all the cases we care about we\n // already have an existing method we want to call, so there's no need\n // to create a new function object. We can even get away with assuming\n // the method takes exactly one argument, since that happens to be true\n // in every case, so we don't have to touch the arguments object. The\n // only additional allocation required is the completion record, which\n // has a stable shape and so hopefully should be cheap to allocate.\n function tryCatch(fn, obj, arg) {\n try {\n return { type: \"normal\", arg: fn.call(obj, arg) };\n } catch (err) {\n return { type: \"throw\", arg: err };\n }\n }\n\n var GenStateSuspendedStart = \"suspendedStart\";\n var GenStateSuspendedYield = \"suspendedYield\";\n var GenStateExecuting = \"executing\";\n var GenStateCompleted = \"completed\";\n\n // Returning this object from the innerFn has the same effect as\n // breaking out of the dispatch switch statement.\n var ContinueSentinel = {};\n\n // Dummy constructor functions that we use as the .constructor and\n // .constructor.prototype properties for functions that return Generator\n // objects. For full spec compliance, you may wish to configure your\n // minifier not to mangle the names of these two functions.\n function Generator() {}\n function GeneratorFunction() {}\n function GeneratorFunctionPrototype() {}\n\n // This is a polyfill for %IteratorPrototype% for environments that\n // don't natively support it.\n var IteratorPrototype = {};\n IteratorPrototype[iteratorSymbol] = function () {\n return this;\n };\n\n var getProto = Object.getPrototypeOf;\n var NativeIteratorPrototype = getProto && getProto(getProto(values([])));\n if (NativeIteratorPrototype &&\n NativeIteratorPrototype !== Op &&\n hasOwn.call(NativeIteratorPrototype, iteratorSymbol)) {\n // This environment has a native %IteratorPrototype%; use it instead\n // of the polyfill.\n IteratorPrototype = NativeIteratorPrototype;\n }\n\n var Gp = GeneratorFunctionPrototype.prototype =\n Generator.prototype = Object.create(IteratorPrototype);\n GeneratorFunction.prototype = Gp.constructor = GeneratorFunctionPrototype;\n GeneratorFunctionPrototype.constructor = GeneratorFunction;\n GeneratorFunction.displayName = define(\n GeneratorFunctionPrototype,\n toStringTagSymbol,\n \"GeneratorFunction\"\n );\n\n // Helper for defining the .next, .throw, and .return methods of the\n // Iterator interface in terms of a single ._invoke method.\n function defineIteratorMethods(prototype) {\n [\"next\", \"throw\", \"return\"].forEach(function(method) {\n define(prototype, method, function(arg) {\n return this._invoke(method, arg);\n });\n });\n }\n\n exports.isGeneratorFunction = function(genFun) {\n var ctor = typeof genFun === \"function\" && genFun.constructor;\n return ctor\n ? ctor === GeneratorFunction ||\n // For the native GeneratorFunction constructor, the best we can\n // do is to check its .name property.\n (ctor.displayName || ctor.name) === \"GeneratorFunction\"\n : false;\n };\n\n exports.mark = function(genFun) {\n if (Object.setPrototypeOf) {\n Object.setPrototypeOf(genFun, GeneratorFunctionPrototype);\n } else {\n genFun.__proto__ = GeneratorFunctionPrototype;\n define(genFun, toStringTagSymbol, \"GeneratorFunction\");\n }\n genFun.prototype = Object.create(Gp);\n return genFun;\n };\n\n // Within the body of any async function, `await x` is transformed to\n // `yield regeneratorRuntime.awrap(x)`, so that the runtime can test\n // `hasOwn.call(value, \"__await\")` to determine if the yielded value is\n // meant to be awaited.\n exports.awrap = function(arg) {\n return { __await: arg };\n };\n\n function AsyncIterator(generator, PromiseImpl) {\n function invoke(method, arg, resolve, reject) {\n var record = tryCatch(generator[method], generator, arg);\n if (record.type === \"throw\") {\n reject(record.arg);\n } else {\n var result = record.arg;\n var value = result.value;\n if (value &&\n typeof value === \"object\" &&\n hasOwn.call(value, \"__await\")) {\n return PromiseImpl.resolve(value.__await).then(function(value) {\n invoke(\"next\", value, resolve, reject);\n }, function(err) {\n invoke(\"throw\", err, resolve, reject);\n });\n }\n\n return PromiseImpl.resolve(value).then(function(unwrapped) {\n // When a yielded Promise is resolved, its final value becomes\n // the .value of the Promise<{value,done}> result for the\n // current iteration.\n result.value = unwrapped;\n resolve(result);\n }, function(error) {\n // If a rejected Promise was yielded, throw the rejection back\n // into the async generator function so it can be handled there.\n return invoke(\"throw\", error, resolve, reject);\n });\n }\n }\n\n var previousPromise;\n\n function enqueue(method, arg) {\n function callInvokeWithMethodAndArg() {\n return new PromiseImpl(function(resolve, reject) {\n invoke(method, arg, resolve, reject);\n });\n }\n\n return previousPromise =\n // If enqueue has been called before, then we want to wait until\n // all previous Promises have been resolved before calling invoke,\n // so that results are always delivered in the correct order. If\n // enqueue has not been called before, then it is important to\n // call invoke immediately, without waiting on a callback to fire,\n // so that the async generator function has the opportunity to do\n // any necessary setup in a predictable way. This predictability\n // is why the Promise constructor synchronously invokes its\n // executor callback, and why async functions synchronously\n // execute code before the first await. Since we implement simple\n // async functions in terms of async generators, it is especially\n // important to get this right, even though it requires care.\n previousPromise ? previousPromise.then(\n callInvokeWithMethodAndArg,\n // Avoid propagating failures to Promises returned by later\n // invocations of the iterator.\n callInvokeWithMethodAndArg\n ) : callInvokeWithMethodAndArg();\n }\n\n // Define the unified helper method that is used to implement .next,\n // .throw, and .return (see defineIteratorMethods).\n this._invoke = enqueue;\n }\n\n defineIteratorMethods(AsyncIterator.prototype);\n AsyncIterator.prototype[asyncIteratorSymbol] = function () {\n return this;\n };\n exports.AsyncIterator = AsyncIterator;\n\n // Note that simple async functions are implemented on top of\n // AsyncIterator objects; they just return a Promise for the value of\n // the final result produced by the iterator.\n exports.async = function(innerFn, outerFn, self, tryLocsList, PromiseImpl) {\n if (PromiseImpl === void 0) PromiseImpl = Promise;\n\n var iter = new AsyncIterator(\n wrap(innerFn, outerFn, self, tryLocsList),\n PromiseImpl\n );\n\n return exports.isGeneratorFunction(outerFn)\n ? iter // If outerFn is a generator, return the full iterator.\n : iter.next().then(function(result) {\n return result.done ? result.value : iter.next();\n });\n };\n\n function makeInvokeMethod(innerFn, self, context) {\n var state = GenStateSuspendedStart;\n\n return function invoke(method, arg) {\n if (state === GenStateExecuting) {\n throw new Error(\"Generator is already running\");\n }\n\n if (state === GenStateCompleted) {\n if (method === \"throw\") {\n throw arg;\n }\n\n // Be forgiving, per 25.3.3.3.3 of the spec:\n // https://people.mozilla.org/~jorendorff/es6-draft.html#sec-generatorresume\n return doneResult();\n }\n\n context.method = method;\n context.arg = arg;\n\n while (true) {\n var delegate = context.delegate;\n if (delegate) {\n var delegateResult = maybeInvokeDelegate(delegate, context);\n if (delegateResult) {\n if (delegateResult === ContinueSentinel) continue;\n return delegateResult;\n }\n }\n\n if (context.method === \"next\") {\n // Setting context._sent for legacy support of Babel's\n // function.sent implementation.\n context.sent = context._sent = context.arg;\n\n } else if (context.method === \"throw\") {\n if (state === GenStateSuspendedStart) {\n state = GenStateCompleted;\n throw context.arg;\n }\n\n context.dispatchException(context.arg);\n\n } else if (context.method === \"return\") {\n context.abrupt(\"return\", context.arg);\n }\n\n state = GenStateExecuting;\n\n var record = tryCatch(innerFn, self, context);\n if (record.type === \"normal\") {\n // If an exception is thrown from innerFn, we leave state ===\n // GenStateExecuting and loop back for another invocation.\n state = context.done\n ? GenStateCompleted\n : GenStateSuspendedYield;\n\n if (record.arg === ContinueSentinel) {\n continue;\n }\n\n return {\n value: record.arg,\n done: context.done\n };\n\n } else if (record.type === \"throw\") {\n state = GenStateCompleted;\n // Dispatch the exception by looping back around to the\n // context.dispatchException(context.arg) call above.\n context.method = \"throw\";\n context.arg = record.arg;\n }\n }\n };\n }\n\n // Call delegate.iterator[context.method](context.arg) and handle the\n // result, either by returning a { value, done } result from the\n // delegate iterator, or by modifying context.method and context.arg,\n // setting context.delegate to null, and returning the ContinueSentinel.\n function maybeInvokeDelegate(delegate, context) {\n var method = delegate.iterator[context.method];\n if (method === undefined) {\n // A .throw or .return when the delegate iterator has no .throw\n // method always terminates the yield* loop.\n context.delegate = null;\n\n if (context.method === \"throw\") {\n // Note: [\"return\"] must be used for ES3 parsing compatibility.\n if (delegate.iterator[\"return\"]) {\n // If the delegate iterator has a return method, give it a\n // chance to clean up.\n context.method = \"return\";\n context.arg = undefined;\n maybeInvokeDelegate(delegate, context);\n\n if (context.method === \"throw\") {\n // If maybeInvokeDelegate(context) changed context.method from\n // \"return\" to \"throw\", let that override the TypeError below.\n return ContinueSentinel;\n }\n }\n\n context.method = \"throw\";\n context.arg = new TypeError(\n \"The iterator does not provide a 'throw' method\");\n }\n\n return ContinueSentinel;\n }\n\n var record = tryCatch(method, delegate.iterator, context.arg);\n\n if (record.type === \"throw\") {\n context.method = \"throw\";\n context.arg = record.arg;\n context.delegate = null;\n return ContinueSentinel;\n }\n\n var info = record.arg;\n\n if (! info) {\n context.method = \"throw\";\n context.arg = new TypeError(\"iterator result is not an object\");\n context.delegate = null;\n return ContinueSentinel;\n }\n\n if (info.done) {\n // Assign the result of the finished delegate to the temporary\n // variable specified by delegate.resultName (see delegateYield).\n context[delegate.resultName] = info.value;\n\n // Resume execution at the desired location (see delegateYield).\n context.next = delegate.nextLoc;\n\n // If context.method was \"throw\" but the delegate handled the\n // exception, let the outer generator proceed normally. If\n // context.method was \"next\", forget context.arg since it has been\n // \"consumed\" by the delegate iterator. If context.method was\n // \"return\", allow the original .return call to continue in the\n // outer generator.\n if (context.method !== \"return\") {\n context.method = \"next\";\n context.arg = undefined;\n }\n\n } else {\n // Re-yield the result returned by the delegate method.\n return info;\n }\n\n // The delegate iterator is finished, so forget it and continue with\n // the outer generator.\n context.delegate = null;\n return ContinueSentinel;\n }\n\n // Define Generator.prototype.{next,throw,return} in terms of the\n // unified ._invoke helper method.\n defineIteratorMethods(Gp);\n\n define(Gp, toStringTagSymbol, \"Generator\");\n\n // A Generator should always return itself as the iterator object when the\n // @@iterator function is called on it. Some browsers' implementations of the\n // iterator prototype chain incorrectly implement this, causing the Generator\n // object to not be returned from this call. This ensures that doesn't happen.\n // See https://github.com/facebook/regenerator/issues/274 for more details.\n Gp[iteratorSymbol] = function() {\n return this;\n };\n\n Gp.toString = function() {\n return \"[object Generator]\";\n };\n\n function pushTryEntry(locs) {\n var entry = { tryLoc: locs[0] };\n\n if (1 in locs) {\n entry.catchLoc = locs[1];\n }\n\n if (2 in locs) {\n entry.finallyLoc = locs[2];\n entry.afterLoc = locs[3];\n }\n\n this.tryEntries.push(entry);\n }\n\n function resetTryEntry(entry) {\n var record = entry.completion || {};\n record.type = \"normal\";\n delete record.arg;\n entry.completion = record;\n }\n\n function Context(tryLocsList) {\n // The root entry object (effectively a try statement without a catch\n // or a finally block) gives us a place to store values thrown from\n // locations where there is no enclosing try statement.\n this.tryEntries = [{ tryLoc: \"root\" }];\n tryLocsList.forEach(pushTryEntry, this);\n this.reset(true);\n }\n\n exports.keys = function(object) {\n var keys = [];\n for (var key in object) {\n keys.push(key);\n }\n keys.reverse();\n\n // Rather than returning an object with a next method, we keep\n // things simple and return the next function itself.\n return function next() {\n while (keys.length) {\n var key = keys.pop();\n if (key in object) {\n next.value = key;\n next.done = false;\n return next;\n }\n }\n\n // To avoid creating an additional object, we just hang the .value\n // and .done properties off the next function object itself. This\n // also ensures that the minifier will not anonymize the function.\n next.done = true;\n return next;\n };\n };\n\n function values(iterable) {\n if (iterable) {\n var iteratorMethod = iterable[iteratorSymbol];\n if (iteratorMethod) {\n return iteratorMethod.call(iterable);\n }\n\n if (typeof iterable.next === \"function\") {\n return iterable;\n }\n\n if (!isNaN(iterable.length)) {\n var i = -1, next = function next() {\n while (++i < iterable.length) {\n if (hasOwn.call(iterable, i)) {\n next.value = iterable[i];\n next.done = false;\n return next;\n }\n }\n\n next.value = undefined;\n next.done = true;\n\n return next;\n };\n\n return next.next = next;\n }\n }\n\n // Return an iterator with no values.\n return { next: doneResult };\n }\n exports.values = values;\n\n function doneResult() {\n return { value: undefined, done: true };\n }\n\n Context.prototype = {\n constructor: Context,\n\n reset: function(skipTempReset) {\n this.prev = 0;\n this.next = 0;\n // Resetting context._sent for legacy support of Babel's\n // function.sent implementation.\n this.sent = this._sent = undefined;\n this.done = false;\n this.delegate = null;\n\n this.method = \"next\";\n this.arg = undefined;\n\n this.tryEntries.forEach(resetTryEntry);\n\n if (!skipTempReset) {\n for (var name in this) {\n // Not sure about the optimal order of these conditions:\n if (name.charAt(0) === \"t\" &&\n hasOwn.call(this, name) &&\n !isNaN(+name.slice(1))) {\n this[name] = undefined;\n }\n }\n }\n },\n\n stop: function() {\n this.done = true;\n\n var rootEntry = this.tryEntries[0];\n var rootRecord = rootEntry.completion;\n if (rootRecord.type === \"throw\") {\n throw rootRecord.arg;\n }\n\n return this.rval;\n },\n\n dispatchException: function(exception) {\n if (this.done) {\n throw exception;\n }\n\n var context = this;\n function handle(loc, caught) {\n record.type = \"throw\";\n record.arg = exception;\n context.next = loc;\n\n if (caught) {\n // If the dispatched exception was caught by a catch block,\n // then let that catch block handle the exception normally.\n context.method = \"next\";\n context.arg = undefined;\n }\n\n return !! caught;\n }\n\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n var record = entry.completion;\n\n if (entry.tryLoc === \"root\") {\n // Exception thrown outside of any try block that could handle\n // it, so set the completion value of the entire function to\n // throw the exception.\n return handle(\"end\");\n }\n\n if (entry.tryLoc <= this.prev) {\n var hasCatch = hasOwn.call(entry, \"catchLoc\");\n var hasFinally = hasOwn.call(entry, \"finallyLoc\");\n\n if (hasCatch && hasFinally) {\n if (this.prev < entry.catchLoc) {\n return handle(entry.catchLoc, true);\n } else if (this.prev < entry.finallyLoc) {\n return handle(entry.finallyLoc);\n }\n\n } else if (hasCatch) {\n if (this.prev < entry.catchLoc) {\n return handle(entry.catchLoc, true);\n }\n\n } else if (hasFinally) {\n if (this.prev < entry.finallyLoc) {\n return handle(entry.finallyLoc);\n }\n\n } else {\n throw new Error(\"try statement without catch or finally\");\n }\n }\n }\n },\n\n abrupt: function(type, arg) {\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n if (entry.tryLoc <= this.prev &&\n hasOwn.call(entry, \"finallyLoc\") &&\n this.prev < entry.finallyLoc) {\n var finallyEntry = entry;\n break;\n }\n }\n\n if (finallyEntry &&\n (type === \"break\" ||\n type === \"continue\") &&\n finallyEntry.tryLoc <= arg &&\n arg <= finallyEntry.finallyLoc) {\n // Ignore the finally entry if control is not jumping to a\n // location outside the try/catch block.\n finallyEntry = null;\n }\n\n var record = finallyEntry ? finallyEntry.completion : {};\n record.type = type;\n record.arg = arg;\n\n if (finallyEntry) {\n this.method = \"next\";\n this.next = finallyEntry.finallyLoc;\n return ContinueSentinel;\n }\n\n return this.complete(record);\n },\n\n complete: function(record, afterLoc) {\n if (record.type === \"throw\") {\n throw record.arg;\n }\n\n if (record.type === \"break\" ||\n record.type === \"continue\") {\n this.next = record.arg;\n } else if (record.type === \"return\") {\n this.rval = this.arg = record.arg;\n this.method = \"return\";\n this.next = \"end\";\n } else if (record.type === \"normal\" && afterLoc) {\n this.next = afterLoc;\n }\n\n return ContinueSentinel;\n },\n\n finish: function(finallyLoc) {\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n if (entry.finallyLoc === finallyLoc) {\n this.complete(entry.completion, entry.afterLoc);\n resetTryEntry(entry);\n return ContinueSentinel;\n }\n }\n },\n\n \"catch\": function(tryLoc) {\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n if (entry.tryLoc === tryLoc) {\n var record = entry.completion;\n if (record.type === \"throw\") {\n var thrown = record.arg;\n resetTryEntry(entry);\n }\n return thrown;\n }\n }\n\n // The context.catch method must only be called with a location\n // argument that corresponds to a known catch block.\n throw new Error(\"illegal catch attempt\");\n },\n\n delegateYield: function(iterable, resultName, nextLoc) {\n this.delegate = {\n iterator: values(iterable),\n resultName: resultName,\n nextLoc: nextLoc\n };\n\n if (this.method === \"next\") {\n // Deliberately forget the last sent value so that we don't\n // accidentally pass it on to the delegate.\n this.arg = undefined;\n }\n\n return ContinueSentinel;\n }\n };\n\n // Regardless of whether this script is executing as a CommonJS module\n // or not, return the runtime object so that we can declare the variable\n // regeneratorRuntime in the outer scope, which allows this module to be\n // injected easily by `bin/regenerator --include-runtime script.js`.\n return exports;\n\n}(\n // If this script is executing as a CommonJS module, use module.exports\n // as the regeneratorRuntime namespace. Otherwise create a new empty\n // object. Either way, the resulting object will be used to initialize\n // the regeneratorRuntime variable at the top of this file.\n typeof module === \"object\" ? module.exports : {}\n));\n\ntry {\n regeneratorRuntime = runtime;\n} catch (accidentalStrictMode) {\n // This module should not be running in strict mode, so the above\n // assignment should always work unless something is misconfigured. Just\n // in case runtime.js accidentally runs in strict mode, we can escape\n // strict mode using a global Function call. This could conceivably fail\n // if a Content Security Policy forbids using Function, but in that case\n // the proper solution is to fix the accidental strict mode problem. If\n // you've misconfigured your bundler to force strict mode and applied a\n // CSP to forbid Function, and you're not willing to fix either of those\n // problems, please detail your unique predicament in a GitHub issue.\n Function(\"r\", \"regeneratorRuntime = r\")(runtime);\n}\n","(function() { module.exports = window[\"eventespresso\"][\"toaster\"]; }());","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst ProfileOutlined = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(ProfileOutlined, 'profile-outlined');\n","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst ControlOutlined = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(ControlOutlined, 'control-outlined');\n","export { default as useDataState } from './useDataState';\n\nexport { default as useInitialState } from './useInitialState';\n\nexport { default as useDataStateManager } from './useDataStateManager';\n\nexport { default as useSubmitForm } from './useSubmitForm';\n\nexport * from './types';\n","(function() { module.exports = window[\"eventespresso\"][\"data\"]; }());","import defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\n\nfunction ownKeys(object, enumerableOnly) {\n var keys = Object.keys(object);\n\n if (Object.getOwnPropertySymbols) {\n var symbols = Object.getOwnPropertySymbols(object);\n if (enumerableOnly) symbols = symbols.filter(function (sym) {\n return Object.getOwnPropertyDescriptor(object, sym).enumerable;\n });\n keys.push.apply(keys, symbols);\n }\n\n return keys;\n}\n\nexport default function _objectSpread2(target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i] != null ? arguments[i] : {};\n\n if (i % 2) {\n ownKeys(Object(source), true).forEach(function (key) {\n defineProperty(target, key, source[key]);\n });\n } else if (Object.getOwnPropertyDescriptors) {\n Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));\n } else {\n ownKeys(Object(source)).forEach(function (key) {\n Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));\n });\n }\n }\n\n return target;\n}","var Symbol = require('./_Symbol'),\n getRawTag = require('./_getRawTag'),\n objectToString = require('./_objectToString');\n\n/** `Object#toString` result references. */\nvar nullTag = '[object Null]',\n undefinedTag = '[object Undefined]';\n\n/** Built-in value references. */\nvar symToStringTag = Symbol ? Symbol.toStringTag : undefined;\n\n/**\n * The base implementation of `getTag` without fallbacks for buggy environments.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\nfunction baseGetTag(value) {\n if (value == null) {\n return value === undefined ? undefinedTag : nullTag;\n }\n return (symToStringTag && symToStringTag in Object(value))\n ? getRawTag(value)\n : objectToString(value);\n}\n\nmodule.exports = baseGetTag;\n","/**\n * Checks if `value` is object-like. A value is object-like if it's not `null`\n * and has a `typeof` result of \"object\".\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is object-like, else `false`.\n * @example\n *\n * _.isObjectLike({});\n * // => true\n *\n * _.isObjectLike([1, 2, 3]);\n * // => true\n *\n * _.isObjectLike(_.noop);\n * // => false\n *\n * _.isObjectLike(null);\n * // => false\n */\nfunction isObjectLike(value) {\n return value != null && typeof value == 'object';\n}\n\nmodule.exports = isObjectLike;\n","var baseToString = require('./_baseToString');\n\n/**\n * Converts `value` to a string. An empty string is returned for `null`\n * and `undefined` values. The sign of `-0` is preserved.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to convert.\n * @returns {string} Returns the converted string.\n * @example\n *\n * _.toString(null);\n * // => ''\n *\n * _.toString(-0);\n * // => '-0'\n *\n * _.toString([1, 2, 3]);\n * // => '1,2,3'\n */\nfunction toString(value) {\n return value == null ? '' : baseToString(value);\n}\n\nmodule.exports = toString;\n","import classNames from 'classnames';\n\nimport { IconComponent } from './types';\n\nimport './style.scss';\n\nconst withClassName = (WrappedComponent: IconComponent, svgName = ''): IconComponent => {\n\tconst WrappedIcon: IconComponent = ({ noMargin, size, ...props }) => {\n\t\tconst className = classNames(\n\t\t\t'ee-svg',\n\t\t\tsize && `ee-icon--${size}`,\n\t\t\tnoMargin && 'ee-icon--no-margin',\n\t\t\tsvgName && `ee-svg--${svgName}`,\n\t\t\tprops.className\n\t\t);\n\n\t\treturn ;\n\t};\n\n\treturn WrappedIcon;\n};\n\nexport default withClassName;\n","// ES6 Map\nvar map\ntry {\n map = Map\n} catch (_) { }\nvar set\n\n// ES6 Set\ntry {\n set = Set\n} catch (_) { }\n\nfunction baseClone (src, circulars, clones) {\n // Null/undefined/functions/etc\n if (!src || typeof src !== 'object' || typeof src === 'function') {\n return src\n }\n\n // DOM Node\n if (src.nodeType && 'cloneNode' in src) {\n return src.cloneNode(true)\n }\n\n // Date\n if (src instanceof Date) {\n return new Date(src.getTime())\n }\n\n // RegExp\n if (src instanceof RegExp) {\n return new RegExp(src)\n }\n\n // Arrays\n if (Array.isArray(src)) {\n return src.map(clone)\n }\n\n // ES6 Maps\n if (map && src instanceof map) {\n return new Map(Array.from(src.entries()))\n }\n\n // ES6 Sets\n if (set && src instanceof set) {\n return new Set(Array.from(src.values()))\n }\n\n // Object\n if (src instanceof Object) {\n circulars.push(src)\n var obj = Object.create(src)\n clones.push(obj)\n for (var key in src) {\n var idx = circulars.findIndex(function (i) {\n return i === src[key]\n })\n obj[key] = idx > -1 ? clones[idx] : baseClone(src[key], circulars, clones)\n }\n return obj\n }\n\n // ???\n return src\n}\n\nexport default function clone (src) {\n return baseClone(src, [], [])\n}\n","const toString = Object.prototype.toString;\nconst errorToString = Error.prototype.toString;\nconst regExpToString = RegExp.prototype.toString;\nconst symbolToString = typeof Symbol !== 'undefined' ? Symbol.prototype.toString : () => '';\nconst SYMBOL_REGEXP = /^Symbol\\((.*)\\)(.*)$/;\n\nfunction printNumber(val) {\n if (val != +val) return 'NaN';\n const isNegativeZero = val === 0 && 1 / val < 0;\n return isNegativeZero ? '-0' : '' + val;\n}\n\nfunction printSimpleValue(val, quoteStrings = false) {\n if (val == null || val === true || val === false) return '' + val;\n const typeOf = typeof val;\n if (typeOf === 'number') return printNumber(val);\n if (typeOf === 'string') return quoteStrings ? `\"${val}\"` : val;\n if (typeOf === 'function') return '[Function ' + (val.name || 'anonymous') + ']';\n if (typeOf === 'symbol') return symbolToString.call(val).replace(SYMBOL_REGEXP, 'Symbol($1)');\n const tag = toString.call(val).slice(8, -1);\n if (tag === 'Date') return isNaN(val.getTime()) ? '' + val : val.toISOString(val);\n if (tag === 'Error' || val instanceof Error) return '[' + errorToString.call(val) + ']';\n if (tag === 'RegExp') return regExpToString.call(val);\n return null;\n}\n\nexport default function printValue(value, quoteStrings) {\n let result = printSimpleValue(value, quoteStrings);\n if (result !== null) return result;\n return JSON.stringify(value, function (key, value) {\n let result = printSimpleValue(this[key], quoteStrings);\n if (result !== null) return result;\n return value;\n }, 2);\n}","import printValue from './util/printValue';\nexport let mixed = {\n default: '${path} is invalid',\n required: '${path} is a required field',\n oneOf: '${path} must be one of the following values: ${values}',\n notOneOf: '${path} must not be one of the following values: ${values}',\n notType: ({\n path,\n type,\n value,\n originalValue\n }) => {\n let isCast = originalValue != null && originalValue !== value;\n let msg = `${path} must be a \\`${type}\\` type, ` + `but the final value was: \\`${printValue(value, true)}\\`` + (isCast ? ` (cast from the value \\`${printValue(originalValue, true)}\\`).` : '.');\n\n if (value === null) {\n msg += `\\n If \"null\" is intended as an empty value be sure to mark the schema as \\`.nullable()\\``;\n }\n\n return msg;\n },\n defined: '${path} must be defined'\n};\nexport let string = {\n length: '${path} must be exactly ${length} characters',\n min: '${path} must be at least ${min} characters',\n max: '${path} must be at most ${max} characters',\n matches: '${path} must match the following: \"${regex}\"',\n email: '${path} must be a valid email',\n url: '${path} must be a valid URL',\n uuid: '${path} must be a valid UUID',\n trim: '${path} must be a trimmed string',\n lowercase: '${path} must be a lowercase string',\n uppercase: '${path} must be a upper case string'\n};\nexport let number = {\n min: '${path} must be greater than or equal to ${min}',\n max: '${path} must be less than or equal to ${max}',\n lessThan: '${path} must be less than ${less}',\n moreThan: '${path} must be greater than ${more}',\n positive: '${path} must be a positive number',\n negative: '${path} must be a negative number',\n integer: '${path} must be an integer'\n};\nexport let date = {\n min: '${path} field must be later than ${min}',\n max: '${path} field must be at earlier than ${max}'\n};\nexport let boolean = {\n isValue: '${path} field must be ${value}'\n};\nexport let object = {\n noUnknown: '${path} field has unspecified keys: ${unknown}'\n};\nexport let array = {\n min: '${path} field must have at least ${min} items',\n max: '${path} field must have less than or equal to ${max} items',\n length: '${path} must have ${length} items'\n};\nexport default Object.assign(Object.create(null), {\n mixed,\n string,\n number,\n date,\n object,\n array,\n boolean\n});","const isSchema = obj => obj && obj.__isYupSchema__;\n\nexport default isSchema;","import has from 'lodash/has';\nimport isSchema from './util/isSchema';\n\nclass Condition {\n constructor(refs, options) {\n this.fn = void 0;\n this.refs = refs;\n this.refs = refs;\n\n if (typeof options === 'function') {\n this.fn = options;\n return;\n }\n\n if (!has(options, 'is')) throw new TypeError('`is:` is required for `when()` conditions');\n if (!options.then && !options.otherwise) throw new TypeError('either `then:` or `otherwise:` is required for `when()` conditions');\n let {\n is,\n then,\n otherwise\n } = options;\n let check = typeof is === 'function' ? is : (...values) => values.every(value => value === is);\n\n this.fn = function (...args) {\n let options = args.pop();\n let schema = args.pop();\n let branch = check(...args) ? then : otherwise;\n if (!branch) return undefined;\n if (typeof branch === 'function') return branch(schema);\n return schema.concat(branch.resolve(options));\n };\n }\n\n resolve(base, options) {\n let values = this.refs.map(ref => ref.getValue(options == null ? void 0 : options.value, options == null ? void 0 : options.parent, options == null ? void 0 : options.context));\n let schema = this.fn.apply(base, values.concat(base, options));\n if (schema === undefined || schema === base) return base;\n if (!isSchema(schema)) throw new TypeError('conditions must return a schema object');\n return schema.resolve(options);\n }\n\n}\n\nexport default Condition;","export default function toArray(value) {\n return value == null ? [] : [].concat(value);\n}","function _extends() { _extends = Object.assign || 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); }\n\nimport printValue from './util/printValue';\nimport toArray from './util/toArray';\nlet strReg = /\\$\\{\\s*(\\w+)\\s*\\}/g;\nexport default class ValidationError extends Error {\n static formatError(message, params) {\n const path = params.label || params.path || 'this';\n if (path !== params.path) params = _extends({}, params, {\n path\n });\n if (typeof message === 'string') return message.replace(strReg, (_, key) => printValue(params[key]));\n if (typeof message === 'function') return message(params);\n return message;\n }\n\n static isError(err) {\n return err && err.name === 'ValidationError';\n }\n\n constructor(errorOrErrors, value, field, type) {\n super();\n this.value = void 0;\n this.path = void 0;\n this.type = void 0;\n this.errors = void 0;\n this.params = void 0;\n this.inner = void 0;\n this.name = 'ValidationError';\n this.value = value;\n this.path = field;\n this.type = type;\n this.errors = [];\n this.inner = [];\n toArray(errorOrErrors).forEach(err => {\n if (ValidationError.isError(err)) {\n this.errors.push(...err.errors);\n this.inner = this.inner.concat(err.inner.length ? err.inner : err);\n } else {\n this.errors.push(err);\n }\n });\n this.message = this.errors.length > 1 ? `${this.errors.length} errors occurred` : this.errors[0];\n if (Error.captureStackTrace) Error.captureStackTrace(this, ValidationError);\n }\n\n}","import ValidationError from '../ValidationError';\n\nconst once = cb => {\n let fired = false;\n return (...args) => {\n if (fired) return;\n fired = true;\n cb(...args);\n };\n};\n\nexport default function runTests(options, cb) {\n let {\n endEarly,\n tests,\n args,\n value,\n errors,\n sort,\n path\n } = options;\n let callback = once(cb);\n let count = tests.length;\n const nestedErrors = [];\n errors = errors ? errors : [];\n if (!count) return errors.length ? callback(new ValidationError(errors, value, path)) : callback(null, value);\n\n for (let i = 0; i < tests.length; i++) {\n const test = tests[i];\n test(args, function finishTestRun(err) {\n if (err) {\n // always return early for non validation errors\n if (!ValidationError.isError(err)) {\n return callback(err, value);\n }\n\n if (endEarly) {\n err.value = value;\n return callback(err, value);\n }\n\n nestedErrors.push(err);\n }\n\n if (--count <= 0) {\n if (nestedErrors.length) {\n if (sort) nestedErrors.sort(sort); //show parent errors after the nested ones: name.first, name\n\n if (errors.length) nestedErrors.push(...errors);\n errors = nestedErrors;\n }\n\n if (errors.length) {\n callback(new ValidationError(errors, value, path), value);\n return;\n }\n\n callback(null, value);\n }\n });\n }\n}","import { getter } from 'property-expr';\nconst prefixes = {\n context: '$',\n value: '.'\n};\nexport function create(key, options) {\n return new Reference(key, options);\n}\nexport default class Reference {\n constructor(key, options = {}) {\n this.key = void 0;\n this.isContext = void 0;\n this.isValue = void 0;\n this.isSibling = void 0;\n this.path = void 0;\n this.getter = void 0;\n this.map = void 0;\n if (typeof key !== 'string') throw new TypeError('ref must be a string, got: ' + key);\n this.key = key.trim();\n if (key === '') throw new TypeError('ref must be a non-empty string');\n this.isContext = this.key[0] === prefixes.context;\n this.isValue = this.key[0] === prefixes.value;\n this.isSibling = !this.isContext && !this.isValue;\n let prefix = this.isContext ? prefixes.context : this.isValue ? prefixes.value : '';\n this.path = this.key.slice(prefix.length);\n this.getter = this.path && getter(this.path, true);\n this.map = options.map;\n }\n\n getValue(value, parent, context) {\n let result = this.isContext ? context : this.isValue ? value : parent;\n if (this.getter) result = this.getter(result || {});\n if (this.map) result = this.map(result);\n return result;\n }\n /**\n *\n * @param {*} value\n * @param {Object} options\n * @param {Object=} options.context\n * @param {Object=} options.parent\n */\n\n\n cast(value, options) {\n return this.getValue(value, options == null ? void 0 : options.parent, options == null ? void 0 : options.context);\n }\n\n resolve() {\n return this;\n }\n\n describe() {\n return {\n type: 'ref',\n key: this.key\n };\n }\n\n toString() {\n return `Ref(${this.key})`;\n }\n\n static isRef(value) {\n return value && value.__isYupRef;\n }\n\n} // @ts-ignore\n\nReference.prototype.__isYupRef = true;","function _extends() { _extends = Object.assign || 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); }\n\nfunction _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }\n\nimport mapValues from 'lodash/mapValues';\nimport ValidationError from '../ValidationError';\nimport Ref from '../Reference';\nexport default function createValidation(config) {\n function validate(_ref, cb) {\n let {\n value,\n path = '',\n label,\n options,\n originalValue,\n sync\n } = _ref,\n rest = _objectWithoutPropertiesLoose(_ref, [\"value\", \"path\", \"label\", \"options\", \"originalValue\", \"sync\"]);\n\n const {\n name,\n test,\n params,\n message\n } = config;\n let {\n parent,\n context\n } = options;\n\n function resolve(item) {\n return Ref.isRef(item) ? item.getValue(value, parent, context) : item;\n }\n\n function createError(overrides = {}) {\n const nextParams = mapValues(_extends({\n value,\n originalValue,\n label,\n path: overrides.path || path\n }, params, overrides.params), resolve);\n const error = new ValidationError(ValidationError.formatError(overrides.message || message, nextParams), value, nextParams.path, overrides.type || name);\n error.params = nextParams;\n return error;\n }\n\n let ctx = _extends({\n path,\n parent,\n type: name,\n createError,\n resolve,\n options,\n originalValue\n }, rest);\n\n if (!sync) {\n try {\n Promise.resolve(test.call(ctx, value, ctx)).then(validOrError => {\n if (ValidationError.isError(validOrError)) cb(validOrError);else if (!validOrError) cb(createError());else cb(null, validOrError);\n }).catch(cb);\n } catch (err) {\n cb(err);\n }\n\n return;\n }\n\n let result;\n\n try {\n var _ref2;\n\n result = test.call(ctx, value, ctx);\n\n if (typeof ((_ref2 = result) == null ? void 0 : _ref2.then) === 'function') {\n throw new Error(`Validation test of type: \"${ctx.type}\" returned a Promise during a synchronous validate. ` + `This test will finish after the validate call has returned`);\n }\n } catch (err) {\n cb(err);\n return;\n }\n\n if (ValidationError.isError(result)) cb(result);else if (!result) cb(createError());else cb(null, result);\n }\n\n validate.OPTIONS = config;\n return validate;\n}","import { forEach } from 'property-expr';\n\nlet trim = part => part.substr(0, part.length - 1).substr(1);\n\nexport function getIn(schema, path, value, context = value) {\n let parent, lastPart, lastPartDebug; // root path: ''\n\n if (!path) return {\n parent,\n parentPath: path,\n schema\n };\n forEach(path, (_part, isBracket, isArray) => {\n let part = isBracket ? trim(_part) : _part;\n schema = schema.resolve({\n context,\n parent,\n value\n });\n\n if (schema.innerType) {\n let idx = isArray ? parseInt(part, 10) : 0;\n\n if (value && idx >= value.length) {\n throw new Error(`Yup.reach cannot resolve an array item at index: ${_part}, in the path: ${path}. ` + `because there is no value at that index. `);\n }\n\n parent = value;\n value = value && value[idx];\n schema = schema.innerType;\n } // sometimes the array index part of a path doesn't exist: \"nested.arr.child\"\n // in these cases the current part is the next schema and should be processed\n // in this iteration. For cases where the index signature is included this\n // check will fail and we'll handle the `child` part on the next iteration like normal\n\n\n if (!isArray) {\n if (!schema.fields || !schema.fields[part]) throw new Error(`The schema does not contain the path: ${path}. ` + `(failed at: ${lastPartDebug} which is a type: \"${schema._type}\")`);\n parent = value;\n value = value && value[part];\n schema = schema.fields[part];\n }\n\n lastPart = part;\n lastPartDebug = isBracket ? '[' + _part + ']' : '.' + _part;\n });\n return {\n schema,\n parent,\n parentPath: lastPart\n };\n}\n\nconst reach = (obj, path, value, context) => getIn(obj, path, value, context).schema;\n\nexport default reach;","import Reference from '../Reference';\nexport default class ReferenceSet {\n constructor() {\n this.list = void 0;\n this.refs = void 0;\n this.list = new Set();\n this.refs = new Map();\n }\n\n get size() {\n return this.list.size + this.refs.size;\n }\n\n describe() {\n const description = [];\n\n for (const item of this.list) description.push(item);\n\n for (const [, ref] of this.refs) description.push(ref.describe());\n\n return description;\n }\n\n toArray() {\n return Array.from(this.list).concat(Array.from(this.refs.values()));\n }\n\n resolveAll(resolve) {\n return this.toArray().reduce((acc, e) => acc.concat(Reference.isRef(e) ? resolve(e) : e), []);\n }\n\n add(value) {\n Reference.isRef(value) ? this.refs.set(value.key, value) : this.list.add(value);\n }\n\n delete(value) {\n Reference.isRef(value) ? this.refs.delete(value.key) : this.list.delete(value);\n }\n\n clone() {\n const next = new ReferenceSet();\n next.list = new Set(this.list);\n next.refs = new Map(this.refs);\n return next;\n }\n\n merge(newItems, removeItems) {\n const next = this.clone();\n newItems.list.forEach(value => next.add(value));\n newItems.refs.forEach(value => next.add(value));\n removeItems.list.forEach(value => next.delete(value));\n removeItems.refs.forEach(value => next.delete(value));\n return next;\n }\n\n}","function _extends() { _extends = Object.assign || 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); }\n\n// @ts-ignore\nimport cloneDeep from 'nanoclone';\nimport { mixed as locale } from './locale';\nimport Condition from './Condition';\nimport runTests from './util/runTests';\nimport createValidation from './util/createValidation';\nimport printValue from './util/printValue';\nimport Ref from './Reference';\nimport { getIn } from './util/reach';\nimport ValidationError from './ValidationError';\nimport ReferenceSet from './util/ReferenceSet';\nimport toArray from './util/toArray'; // const UNSET = 'unset' as const;\n\nexport default class BaseSchema {\n constructor(options) {\n this.deps = [];\n this.tests = void 0;\n this.transforms = void 0;\n this.conditions = [];\n this._mutate = void 0;\n this._typeError = void 0;\n this._whitelist = new ReferenceSet();\n this._blacklist = new ReferenceSet();\n this.exclusiveTests = Object.create(null);\n this.spec = void 0;\n this.tests = [];\n this.transforms = [];\n this.withMutation(() => {\n this.typeError(locale.notType);\n });\n this.type = (options == null ? void 0 : options.type) || 'mixed';\n this.spec = _extends({\n strip: false,\n strict: false,\n abortEarly: true,\n recursive: true,\n nullable: false,\n presence: 'optional'\n }, options == null ? void 0 : options.spec);\n } // TODO: remove\n\n\n get _type() {\n return this.type;\n }\n\n _typeCheck(_value) {\n return true;\n }\n\n clone(spec) {\n if (this._mutate) {\n if (spec) Object.assign(this.spec, spec);\n return this;\n } // if the nested value is a schema we can skip cloning, since\n // they are already immutable\n\n\n const next = Object.create(Object.getPrototypeOf(this)); // @ts-expect-error this is readonly\n\n next.type = this.type;\n next._typeError = this._typeError;\n next._whitelistError = this._whitelistError;\n next._blacklistError = this._blacklistError;\n next._whitelist = this._whitelist.clone();\n next._blacklist = this._blacklist.clone();\n next.exclusiveTests = _extends({}, this.exclusiveTests); // @ts-expect-error this is readonly\n\n next.deps = [...this.deps];\n next.conditions = [...this.conditions];\n next.tests = [...this.tests];\n next.transforms = [...this.transforms];\n next.spec = cloneDeep(_extends({}, this.spec, spec));\n return next;\n }\n\n label(label) {\n let next = this.clone();\n next.spec.label = label;\n return next;\n }\n\n meta(...args) {\n if (args.length === 0) return this.spec.meta;\n let next = this.clone();\n next.spec.meta = Object.assign(next.spec.meta || {}, args[0]);\n return next;\n } // withContext(): BaseSchema<\n // TCast,\n // TContext,\n // TOutput\n // > {\n // return this as any;\n // }\n\n\n withMutation(fn) {\n let before = this._mutate;\n this._mutate = true;\n let result = fn(this);\n this._mutate = before;\n return result;\n }\n\n concat(schema) {\n if (!schema || schema === this) return this;\n if (schema.type !== this.type && this.type !== 'mixed') throw new TypeError(`You cannot \\`concat()\\` schema's of different types: ${this.type} and ${schema.type}`);\n let base = this;\n let combined = schema.clone();\n\n const mergedSpec = _extends({}, base.spec, combined.spec); // if (combined.spec.nullable === UNSET)\n // mergedSpec.nullable = base.spec.nullable;\n // if (combined.spec.presence === UNSET)\n // mergedSpec.presence = base.spec.presence;\n\n\n combined.spec = mergedSpec;\n combined._typeError || (combined._typeError = base._typeError);\n combined._whitelistError || (combined._whitelistError = base._whitelistError);\n combined._blacklistError || (combined._blacklistError = base._blacklistError); // manually merge the blacklist/whitelist (the other `schema` takes\n // precedence in case of conflicts)\n\n combined._whitelist = base._whitelist.merge(schema._whitelist, schema._blacklist);\n combined._blacklist = base._blacklist.merge(schema._blacklist, schema._whitelist); // start with the current tests\n\n combined.tests = base.tests;\n combined.exclusiveTests = base.exclusiveTests; // manually add the new tests to ensure\n // the deduping logic is consistent\n\n combined.withMutation(next => {\n schema.tests.forEach(fn => {\n next.test(fn.OPTIONS);\n });\n });\n combined.transforms = [...base.transforms, ...combined.transforms];\n return combined;\n }\n\n isType(v) {\n if (this.spec.nullable && v === null) return true;\n return this._typeCheck(v);\n }\n\n resolve(options) {\n let schema = this;\n\n if (schema.conditions.length) {\n let conditions = schema.conditions;\n schema = schema.clone();\n schema.conditions = [];\n schema = conditions.reduce((schema, condition) => condition.resolve(schema, options), schema);\n schema = schema.resolve(options);\n }\n\n return schema;\n }\n /**\n *\n * @param {*} value\n * @param {Object} options\n * @param {*=} options.parent\n * @param {*=} options.context\n */\n\n\n cast(value, options = {}) {\n let resolvedSchema = this.resolve(_extends({\n value\n }, options));\n\n let result = resolvedSchema._cast(value, options);\n\n if (value !== undefined && options.assert !== false && resolvedSchema.isType(result) !== true) {\n let formattedValue = printValue(value);\n let formattedResult = printValue(result);\n throw new TypeError(`The value of ${options.path || 'field'} could not be cast to a value ` + `that satisfies the schema type: \"${resolvedSchema._type}\". \\n\\n` + `attempted value: ${formattedValue} \\n` + (formattedResult !== formattedValue ? `result of cast: ${formattedResult}` : ''));\n }\n\n return result;\n }\n\n _cast(rawValue, _options) {\n let value = rawValue === undefined ? rawValue : this.transforms.reduce((value, fn) => fn.call(this, value, rawValue, this), rawValue);\n\n if (value === undefined) {\n value = this.getDefault();\n }\n\n return value;\n }\n\n _validate(_value, options = {}, cb) {\n let {\n sync,\n path,\n from = [],\n originalValue = _value,\n strict = this.spec.strict,\n abortEarly = this.spec.abortEarly\n } = options;\n let value = _value;\n\n if (!strict) {\n // this._validating = true;\n value = this._cast(value, _extends({\n assert: false\n }, options)); // this._validating = false;\n } // value is cast, we can check if it meets type requirements\n\n\n let args = {\n value,\n path,\n options,\n originalValue,\n schema: this,\n label: this.spec.label,\n sync,\n from\n };\n let initialTests = [];\n if (this._typeError) initialTests.push(this._typeError);\n let finalTests = [];\n if (this._whitelistError) finalTests.push(this._whitelistError);\n if (this._blacklistError) finalTests.push(this._blacklistError);\n runTests({\n args,\n value,\n path,\n sync,\n tests: initialTests,\n endEarly: abortEarly\n }, err => {\n if (err) return void cb(err, value);\n runTests({\n tests: this.tests.concat(finalTests),\n args,\n path,\n sync,\n value,\n endEarly: abortEarly\n }, cb);\n });\n }\n\n validate(value, options, maybeCb) {\n let schema = this.resolve(_extends({}, options, {\n value\n })); // callback case is for nested validations\n\n return typeof maybeCb === 'function' ? schema._validate(value, options, maybeCb) : new Promise((resolve, reject) => schema._validate(value, options, (err, value) => {\n if (err) reject(err);else resolve(value);\n }));\n }\n\n validateSync(value, options) {\n let schema = this.resolve(_extends({}, options, {\n value\n }));\n let result;\n\n schema._validate(value, _extends({}, options, {\n sync: true\n }), (err, value) => {\n if (err) throw err;\n result = value;\n });\n\n return result;\n }\n\n isValid(value, options) {\n return this.validate(value, options).then(() => true, err => {\n if (ValidationError.isError(err)) return false;\n throw err;\n });\n }\n\n isValidSync(value, options) {\n try {\n this.validateSync(value, options);\n return true;\n } catch (err) {\n if (ValidationError.isError(err)) return false;\n throw err;\n }\n }\n\n _getDefault() {\n let defaultValue = this.spec.default;\n\n if (defaultValue == null) {\n return defaultValue;\n }\n\n return typeof defaultValue === 'function' ? defaultValue.call(this) : cloneDeep(defaultValue);\n }\n\n getDefault(options) {\n let schema = this.resolve(options || {});\n return schema._getDefault();\n }\n\n default(def) {\n if (arguments.length === 0) {\n return this._getDefault();\n }\n\n let next = this.clone({\n default: def\n });\n return next;\n }\n\n strict(isStrict = true) {\n let next = this.clone();\n next.spec.strict = isStrict;\n return next;\n }\n\n _isPresent(value) {\n return value != null;\n }\n\n defined(message = locale.defined) {\n return this.test({\n message,\n name: 'defined',\n exclusive: true,\n\n test(value) {\n return value !== undefined;\n }\n\n });\n }\n\n required(message = locale.required) {\n return this.clone({\n presence: 'required'\n }).withMutation(s => s.test({\n message,\n name: 'required',\n exclusive: true,\n\n test(value) {\n return this.schema._isPresent(value);\n }\n\n }));\n }\n\n notRequired() {\n let next = this.clone({\n presence: 'optional'\n });\n next.tests = next.tests.filter(test => test.OPTIONS.name !== 'required');\n return next;\n }\n\n nullable(isNullable = true) {\n let next = this.clone({\n nullable: isNullable !== false\n });\n return next;\n }\n\n transform(fn) {\n let next = this.clone();\n next.transforms.push(fn);\n return next;\n }\n /**\n * Adds a test function to the schema's queue of tests.\n * tests can be exclusive or non-exclusive.\n *\n * - exclusive tests, will replace any existing tests of the same name.\n * - non-exclusive: can be stacked\n *\n * If a non-exclusive test is added to a schema with an exclusive test of the same name\n * the exclusive test is removed and further tests of the same name will be stacked.\n *\n * If an exclusive test is added to a schema with non-exclusive tests of the same name\n * the previous tests are removed and further tests of the same name will replace each other.\n */\n\n\n test(...args) {\n let opts;\n\n if (args.length === 1) {\n if (typeof args[0] === 'function') {\n opts = {\n test: args[0]\n };\n } else {\n opts = args[0];\n }\n } else if (args.length === 2) {\n opts = {\n name: args[0],\n test: args[1]\n };\n } else {\n opts = {\n name: args[0],\n message: args[1],\n test: args[2]\n };\n }\n\n if (opts.message === undefined) opts.message = locale.default;\n if (typeof opts.test !== 'function') throw new TypeError('`test` is a required parameters');\n let next = this.clone();\n let validate = createValidation(opts);\n let isExclusive = opts.exclusive || opts.name && next.exclusiveTests[opts.name] === true;\n\n if (opts.exclusive) {\n if (!opts.name) throw new TypeError('Exclusive tests must provide a unique `name` identifying the test');\n }\n\n if (opts.name) next.exclusiveTests[opts.name] = !!opts.exclusive;\n next.tests = next.tests.filter(fn => {\n if (fn.OPTIONS.name === opts.name) {\n if (isExclusive) return false;\n if (fn.OPTIONS.test === validate.OPTIONS.test) return false;\n }\n\n return true;\n });\n next.tests.push(validate);\n return next;\n }\n\n when(keys, options) {\n if (!Array.isArray(keys) && typeof keys !== 'string') {\n options = keys;\n keys = '.';\n }\n\n let next = this.clone();\n let deps = toArray(keys).map(key => new Ref(key));\n deps.forEach(dep => {\n // @ts-ignore\n if (dep.isSibling) next.deps.push(dep.key);\n });\n next.conditions.push(new Condition(deps, options));\n return next;\n }\n\n typeError(message) {\n let next = this.clone();\n next._typeError = createValidation({\n message,\n name: 'typeError',\n\n test(value) {\n if (value !== undefined && !this.schema.isType(value)) return this.createError({\n params: {\n type: this.schema._type\n }\n });\n return true;\n }\n\n });\n return next;\n }\n\n oneOf(enums, message = locale.oneOf) {\n let next = this.clone();\n enums.forEach(val => {\n next._whitelist.add(val);\n\n next._blacklist.delete(val);\n });\n next._whitelistError = createValidation({\n message,\n name: 'oneOf',\n\n test(value) {\n if (value === undefined) return true;\n let valids = this.schema._whitelist;\n let resolved = valids.resolveAll(this.resolve);\n return resolved.includes(value) ? true : this.createError({\n params: {\n values: valids.toArray().join(', '),\n resolved\n }\n });\n }\n\n });\n return next;\n }\n\n notOneOf(enums, message = locale.notOneOf) {\n let next = this.clone();\n enums.forEach(val => {\n next._blacklist.add(val);\n\n next._whitelist.delete(val);\n });\n next._blacklistError = createValidation({\n message,\n name: 'notOneOf',\n\n test(value) {\n let invalids = this.schema._blacklist;\n let resolved = invalids.resolveAll(this.resolve);\n if (resolved.includes(value)) return this.createError({\n params: {\n values: invalids.toArray().join(', '),\n resolved\n }\n });\n return true;\n }\n\n });\n return next;\n }\n\n strip(strip = true) {\n let next = this.clone();\n next.spec.strip = strip;\n return next;\n }\n\n describe() {\n const next = this.clone();\n const {\n label,\n meta\n } = next.spec;\n const description = {\n meta,\n label,\n type: next.type,\n oneOf: next._whitelist.describe(),\n notOneOf: next._blacklist.describe(),\n tests: next.tests.map(fn => ({\n name: fn.OPTIONS.name,\n params: fn.OPTIONS.params\n })).filter((n, idx, list) => list.findIndex(c => c.name === n.name) === idx)\n };\n return description;\n }\n\n} // eslint-disable-next-line @typescript-eslint/no-unused-vars\n\n// @ts-expect-error\nBaseSchema.prototype.__isYupSchema__ = true;\n\nfor (const method of ['validate', 'validateSync']) BaseSchema.prototype[`${method}At`] = function (path, value, options = {}) {\n const {\n parent,\n parentPath,\n schema\n } = getIn(this, path, value, options.context);\n return schema[method](parent && parent[parentPath], _extends({}, options, {\n parent,\n path\n }));\n};\n\nfor (const alias of ['equals', 'is']) BaseSchema.prototype[alias] = BaseSchema.prototype.oneOf;\n\nfor (const alias of ['not', 'nope']) BaseSchema.prototype[alias] = BaseSchema.prototype.notOneOf;\n\nBaseSchema.prototype.optional = BaseSchema.prototype.notRequired;","import BaseSchema from './schema';\nconst Mixed = BaseSchema;\nexport default Mixed;\nexport function create() {\n return new Mixed();\n} // XXX: this is using the Base schema so that `addMethod(mixed)` works as a base class\n\ncreate.prototype = Mixed.prototype;","const isAbsent = value => value == null;\n\nexport default isAbsent;","import BaseSchema from './schema';\nimport { boolean as locale } from './locale';\nimport isAbsent from './util/isAbsent';\nexport function create() {\n return new BooleanSchema();\n}\nexport default class BooleanSchema extends BaseSchema {\n constructor() {\n super({\n type: 'boolean'\n });\n this.withMutation(() => {\n this.transform(function (value) {\n if (!this.isType(value)) {\n if (/^(true|1)$/i.test(String(value))) return true;\n if (/^(false|0)$/i.test(String(value))) return false;\n }\n\n return value;\n });\n });\n }\n\n _typeCheck(v) {\n if (v instanceof Boolean) v = v.valueOf();\n return typeof v === 'boolean';\n }\n\n isTrue(message = locale.isValue) {\n return this.test({\n message,\n name: 'is-value',\n exclusive: true,\n params: {\n value: 'true'\n },\n\n test(value) {\n return isAbsent(value) || value === true;\n }\n\n });\n }\n\n isFalse(message = locale.isValue) {\n return this.test({\n message,\n name: 'is-value',\n exclusive: true,\n params: {\n value: 'false'\n },\n\n test(value) {\n return isAbsent(value) || value === false;\n }\n\n });\n }\n\n}\ncreate.prototype = BooleanSchema.prototype;","import { string as locale } from './locale';\nimport isAbsent from './util/isAbsent';\nimport BaseSchema from './schema'; // eslint-disable-next-line\n\nlet rEmail = /^((([a-z]|\\d|[!#\\$%&'\\*\\+\\-\\/=\\?\\^_`{\\|}~]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])+(\\.([a-z]|\\d|[!#\\$%&'\\*\\+\\-\\/=\\?\\^_`{\\|}~]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])+)*)|((\\x22)((((\\x20|\\x09)*(\\x0d\\x0a))?(\\x20|\\x09)+)?(([\\x01-\\x08\\x0b\\x0c\\x0e-\\x1f\\x7f]|\\x21|[\\x23-\\x5b]|[\\x5d-\\x7e]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(\\\\([\\x01-\\x09\\x0b\\x0c\\x0d-\\x7f]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]))))*(((\\x20|\\x09)*(\\x0d\\x0a))?(\\x20|\\x09)+)?(\\x22)))@((([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])*([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])))\\.)+(([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])*([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])))$/i; // eslint-disable-next-line\n\nlet rUrl = /^((https?|ftp):)?\\/\\/(((([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(%[\\da-f]{2})|[!\\$&'\\(\\)\\*\\+,;=]|:)*@)?(((\\d|[1-9]\\d|1\\d\\d|2[0-4]\\d|25[0-5])\\.(\\d|[1-9]\\d|1\\d\\d|2[0-4]\\d|25[0-5])\\.(\\d|[1-9]\\d|1\\d\\d|2[0-4]\\d|25[0-5])\\.(\\d|[1-9]\\d|1\\d\\d|2[0-4]\\d|25[0-5]))|((([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])*([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])))\\.)+(([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])*([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])))\\.?)(:\\d*)?)(\\/((([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(%[\\da-f]{2})|[!\\$&'\\(\\)\\*\\+,;=]|:|@)+(\\/(([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(%[\\da-f]{2})|[!\\$&'\\(\\)\\*\\+,;=]|:|@)*)*)?)?(\\?((([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(%[\\da-f]{2})|[!\\$&'\\(\\)\\*\\+,;=]|:|@)|[\\uE000-\\uF8FF]|\\/|\\?)*)?(\\#((([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(%[\\da-f]{2})|[!\\$&'\\(\\)\\*\\+,;=]|:|@)|\\/|\\?)*)?$/i; // eslint-disable-next-line\n\nlet rUUID = /^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;\n\nlet isTrimmed = value => isAbsent(value) || value === value.trim();\n\nlet objStringTag = {}.toString();\nexport function create() {\n return new StringSchema();\n}\nexport default class StringSchema extends BaseSchema {\n constructor() {\n super({\n type: 'string'\n });\n this.withMutation(() => {\n this.transform(function (value) {\n if (this.isType(value)) return value;\n if (Array.isArray(value)) return value;\n const strValue = value != null && value.toString ? value.toString() : value;\n if (strValue === objStringTag) return value;\n return strValue;\n });\n });\n }\n\n _typeCheck(value) {\n if (value instanceof String) value = value.valueOf();\n return typeof value === 'string';\n }\n\n _isPresent(value) {\n return super._isPresent(value) && !!value.length;\n }\n\n length(length, message = locale.length) {\n return this.test({\n message,\n name: 'length',\n exclusive: true,\n params: {\n length\n },\n\n test(value) {\n return isAbsent(value) || value.length === this.resolve(length);\n }\n\n });\n }\n\n min(min, message = locale.min) {\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n min\n },\n\n test(value) {\n return isAbsent(value) || value.length >= this.resolve(min);\n }\n\n });\n }\n\n max(max, message = locale.max) {\n return this.test({\n name: 'max',\n exclusive: true,\n message,\n params: {\n max\n },\n\n test(value) {\n return isAbsent(value) || value.length <= this.resolve(max);\n }\n\n });\n }\n\n matches(regex, options) {\n let excludeEmptyString = false;\n let message;\n let name;\n\n if (options) {\n if (typeof options === 'object') {\n ({\n excludeEmptyString = false,\n message,\n name\n } = options);\n } else {\n message = options;\n }\n }\n\n return this.test({\n name: name || 'matches',\n message: message || locale.matches,\n params: {\n regex\n },\n test: value => isAbsent(value) || value === '' && excludeEmptyString || value.search(regex) !== -1\n });\n }\n\n email(message = locale.email) {\n return this.matches(rEmail, {\n name: 'email',\n message,\n excludeEmptyString: true\n });\n }\n\n url(message = locale.url) {\n return this.matches(rUrl, {\n name: 'url',\n message,\n excludeEmptyString: true\n });\n }\n\n uuid(message = locale.uuid) {\n return this.matches(rUUID, {\n name: 'uuid',\n message,\n excludeEmptyString: false\n });\n } //-- transforms --\n\n\n ensure() {\n return this.default('').transform(val => val === null ? '' : val);\n }\n\n trim(message = locale.trim) {\n return this.transform(val => val != null ? val.trim() : val).test({\n message,\n name: 'trim',\n test: isTrimmed\n });\n }\n\n lowercase(message = locale.lowercase) {\n return this.transform(value => !isAbsent(value) ? value.toLowerCase() : value).test({\n message,\n name: 'string_case',\n exclusive: true,\n test: value => isAbsent(value) || value === value.toLowerCase()\n });\n }\n\n uppercase(message = locale.uppercase) {\n return this.transform(value => !isAbsent(value) ? value.toUpperCase() : value).test({\n message,\n name: 'string_case',\n exclusive: true,\n test: value => isAbsent(value) || value === value.toUpperCase()\n });\n }\n\n}\ncreate.prototype = StringSchema.prototype; //\n// String Interfaces\n//","import { number as locale } from './locale';\nimport isAbsent from './util/isAbsent';\nimport BaseSchema from './schema';\n\nlet isNaN = value => value != +value;\n\nexport function create() {\n return new NumberSchema();\n}\nexport default class NumberSchema extends BaseSchema {\n constructor() {\n super({\n type: 'number'\n });\n this.withMutation(() => {\n this.transform(function (value) {\n let parsed = value;\n\n if (typeof parsed === 'string') {\n parsed = parsed.replace(/\\s/g, '');\n if (parsed === '') return NaN; // don't use parseFloat to avoid positives on alpha-numeric strings\n\n parsed = +parsed;\n }\n\n if (this.isType(parsed)) return parsed;\n return parseFloat(parsed);\n });\n });\n }\n\n _typeCheck(value) {\n if (value instanceof Number) value = value.valueOf();\n return typeof value === 'number' && !isNaN(value);\n }\n\n min(min, message = locale.min) {\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n min\n },\n\n test(value) {\n return isAbsent(value) || value >= this.resolve(min);\n }\n\n });\n }\n\n max(max, message = locale.max) {\n return this.test({\n message,\n name: 'max',\n exclusive: true,\n params: {\n max\n },\n\n test(value) {\n return isAbsent(value) || value <= this.resolve(max);\n }\n\n });\n }\n\n lessThan(less, message = locale.lessThan) {\n return this.test({\n message,\n name: 'max',\n exclusive: true,\n params: {\n less\n },\n\n test(value) {\n return isAbsent(value) || value < this.resolve(less);\n }\n\n });\n }\n\n moreThan(more, message = locale.moreThan) {\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n more\n },\n\n test(value) {\n return isAbsent(value) || value > this.resolve(more);\n }\n\n });\n }\n\n positive(msg = locale.positive) {\n return this.moreThan(0, msg);\n }\n\n negative(msg = locale.negative) {\n return this.lessThan(0, msg);\n }\n\n integer(message = locale.integer) {\n return this.test({\n name: 'integer',\n message,\n test: val => isAbsent(val) || Number.isInteger(val)\n });\n }\n\n truncate() {\n return this.transform(value => !isAbsent(value) ? value | 0 : value);\n }\n\n round(method) {\n var _method;\n\n let avail = ['ceil', 'floor', 'round', 'trunc'];\n method = ((_method = method) == null ? void 0 : _method.toLowerCase()) || 'round'; // this exists for symemtry with the new Math.trunc\n\n if (method === 'trunc') return this.truncate();\n if (avail.indexOf(method.toLowerCase()) === -1) throw new TypeError('Only valid options for round() are: ' + avail.join(', '));\n return this.transform(value => !isAbsent(value) ? Math[method](value) : value);\n }\n\n}\ncreate.prototype = NumberSchema.prototype; //\n// Number Interfaces\n//","/* eslint-disable */\n\n/**\n *\n * Date.parse with progressive enhancement for ISO 8601 \n * NON-CONFORMANT EDITION.\n * © 2011 Colin Snover \n * Released under MIT license.\n */\n// 1 YYYY 2 MM 3 DD 4 HH 5 mm 6 ss 7 msec 8 Z 9 ± 10 tzHH 11 tzmm\nvar isoReg = /^(\\d{4}|[+\\-]\\d{6})(?:-?(\\d{2})(?:-?(\\d{2}))?)?(?:[ T]?(\\d{2}):?(\\d{2})(?::?(\\d{2})(?:[,\\.](\\d{1,}))?)?(?:(Z)|([+\\-])(\\d{2})(?::?(\\d{2}))?)?)?$/;\nexport default function parseIsoDate(date) {\n var numericKeys = [1, 4, 5, 6, 7, 10, 11],\n minutesOffset = 0,\n timestamp,\n struct;\n\n if (struct = isoReg.exec(date)) {\n // avoid NaN timestamps caused by “undefined” values being passed to Date.UTC\n for (var i = 0, k; k = numericKeys[i]; ++i) struct[k] = +struct[k] || 0; // allow undefined days and months\n\n\n struct[2] = (+struct[2] || 1) - 1;\n struct[3] = +struct[3] || 1; // allow arbitrary sub-second precision beyond milliseconds\n\n struct[7] = struct[7] ? String(struct[7]).substr(0, 3) : 0; // timestamps without timezone identifiers should be considered local time\n\n if ((struct[8] === undefined || struct[8] === '') && (struct[9] === undefined || struct[9] === '')) timestamp = +new Date(struct[1], struct[2], struct[3], struct[4], struct[5], struct[6], struct[7]);else {\n if (struct[8] !== 'Z' && struct[9] !== undefined) {\n minutesOffset = struct[10] * 60 + struct[11];\n if (struct[9] === '+') minutesOffset = 0 - minutesOffset;\n }\n\n timestamp = Date.UTC(struct[1], struct[2], struct[3], struct[4], struct[5] + minutesOffset, struct[6], struct[7]);\n }\n } else timestamp = Date.parse ? Date.parse(date) : NaN;\n\n return timestamp;\n}","// @ts-ignore\nimport isoParse from './util/isodate';\nimport { date as locale } from './locale';\nimport isAbsent from './util/isAbsent';\nimport Ref from './Reference';\nimport BaseSchema from './schema';\nlet invalidDate = new Date('');\n\nlet isDate = obj => Object.prototype.toString.call(obj) === '[object Date]';\n\nexport function create() {\n return new DateSchema();\n}\nexport default class DateSchema extends BaseSchema {\n constructor() {\n super({\n type: 'date'\n });\n this.withMutation(() => {\n this.transform(function (value) {\n if (this.isType(value)) return value;\n value = isoParse(value); // 0 is a valid timestamp equivalent to 1970-01-01T00:00:00Z(unix epoch) or before.\n\n return !isNaN(value) ? new Date(value) : invalidDate;\n });\n });\n }\n\n _typeCheck(v) {\n return isDate(v) && !isNaN(v.getTime());\n }\n\n prepareParam(ref, name) {\n let param;\n\n if (!Ref.isRef(ref)) {\n let cast = this.cast(ref);\n if (!this._typeCheck(cast)) throw new TypeError(`\\`${name}\\` must be a Date or a value that can be \\`cast()\\` to a Date`);\n param = cast;\n } else {\n param = ref;\n }\n\n return param;\n }\n\n min(min, message = locale.min) {\n let limit = this.prepareParam(min, 'min');\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n min\n },\n\n test(value) {\n return isAbsent(value) || value >= this.resolve(limit);\n }\n\n });\n }\n\n max(max, message = locale.max) {\n let limit = this.prepareParam(max, 'max');\n return this.test({\n message,\n name: 'max',\n exclusive: true,\n params: {\n max\n },\n\n test(value) {\n return isAbsent(value) || value <= this.resolve(limit);\n }\n\n });\n }\n\n}\nDateSchema.INVALID_DATE = invalidDate;\ncreate.prototype = DateSchema.prototype;\ncreate.INVALID_DATE = invalidDate;","import has from 'lodash/has'; // @ts-expect-error\n\nimport toposort from 'toposort';\nimport { split } from 'property-expr';\nimport Ref from '../Reference';\nimport isSchema from './isSchema';\nexport default function sortFields(fields, excludedEdges = []) {\n let edges = [];\n let nodes = new Set();\n let excludes = new Set(excludedEdges.map(([a, b]) => `${a}-${b}`));\n\n function addNode(depPath, key) {\n let node = split(depPath)[0];\n nodes.add(node);\n if (!excludes.has(`${key}-${node}`)) edges.push([key, node]);\n }\n\n for (const key in fields) if (has(fields, key)) {\n let value = fields[key];\n nodes.add(key);\n if (Ref.isRef(value) && value.isSibling) addNode(value.path, key);else if (isSchema(value) && 'deps' in value) value.deps.forEach(path => addNode(path, key));\n }\n\n return toposort.array(Array.from(nodes), edges).reverse();\n}","function findIndex(arr, err) {\n let idx = Infinity;\n arr.some((key, ii) => {\n var _err$path;\n\n if (((_err$path = err.path) == null ? void 0 : _err$path.indexOf(key)) !== -1) {\n idx = ii;\n return true;\n }\n });\n return idx;\n}\n\nexport default function sortByKeyOrder(keys) {\n return (a, b) => {\n return findIndex(keys, a) - findIndex(keys, b);\n };\n}","function _extends() { _extends = Object.assign || 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); }\n\nimport has from 'lodash/has';\nimport snakeCase from 'lodash/snakeCase';\nimport camelCase from 'lodash/camelCase';\nimport mapKeys from 'lodash/mapKeys';\nimport mapValues from 'lodash/mapValues';\nimport { getter } from 'property-expr';\nimport { object as locale } from './locale';\nimport sortFields from './util/sortFields';\nimport sortByKeyOrder from './util/sortByKeyOrder';\nimport runTests from './util/runTests';\nimport ValidationError from './ValidationError';\nimport BaseSchema from './schema';\n\nlet isObject = obj => Object.prototype.toString.call(obj) === '[object Object]';\n\nfunction unknown(ctx, value) {\n let known = Object.keys(ctx.fields);\n return Object.keys(value).filter(key => known.indexOf(key) === -1);\n}\n\nconst defaultSort = sortByKeyOrder([]);\nexport default class ObjectSchema extends BaseSchema {\n constructor(spec) {\n super({\n type: 'object'\n });\n this.fields = Object.create(null);\n this._sortErrors = defaultSort;\n this._nodes = [];\n this._excludedEdges = [];\n this.withMutation(() => {\n this.transform(function coerce(value) {\n if (typeof value === 'string') {\n try {\n value = JSON.parse(value);\n } catch (err) {\n value = null;\n }\n }\n\n if (this.isType(value)) return value;\n return null;\n });\n\n if (spec) {\n this.shape(spec);\n }\n });\n }\n\n _typeCheck(value) {\n return isObject(value) || typeof value === 'function';\n }\n\n _cast(_value, options = {}) {\n var _options$stripUnknown;\n\n let value = super._cast(_value, options); //should ignore nulls here\n\n\n if (value === undefined) return this.getDefault();\n if (!this._typeCheck(value)) return value;\n let fields = this.fields;\n let strip = (_options$stripUnknown = options.stripUnknown) != null ? _options$stripUnknown : this.spec.noUnknown;\n\n let props = this._nodes.concat(Object.keys(value).filter(v => this._nodes.indexOf(v) === -1));\n\n let intermediateValue = {}; // is filled during the transform below\n\n let innerOptions = _extends({}, options, {\n parent: intermediateValue,\n __validating: options.__validating || false\n });\n\n let isChanged = false;\n\n for (const prop of props) {\n let field = fields[prop];\n let exists = has(value, prop);\n\n if (field) {\n let fieldValue;\n let inputValue = value[prop]; // safe to mutate since this is fired in sequence\n\n innerOptions.path = (options.path ? `${options.path}.` : '') + prop; // innerOptions.value = value[prop];\n\n field = field.resolve({\n value: inputValue,\n context: options.context,\n parent: intermediateValue\n });\n let fieldSpec = 'spec' in field ? field.spec : undefined;\n let strict = fieldSpec == null ? void 0 : fieldSpec.strict;\n\n if (fieldSpec == null ? void 0 : fieldSpec.strip) {\n isChanged = isChanged || prop in value;\n continue;\n }\n\n fieldValue = !options.__validating || !strict ? // TODO: use _cast, this is double resolving\n field.cast(value[prop], innerOptions) : value[prop];\n\n if (fieldValue !== undefined) {\n intermediateValue[prop] = fieldValue;\n }\n } else if (exists && !strip) {\n intermediateValue[prop] = value[prop];\n }\n\n if (intermediateValue[prop] !== value[prop]) {\n isChanged = true;\n }\n }\n\n return isChanged ? intermediateValue : value;\n }\n\n _validate(_value, opts = {}, callback) {\n let errors = [];\n let {\n sync,\n from = [],\n originalValue = _value,\n abortEarly = this.spec.abortEarly,\n recursive = this.spec.recursive\n } = opts;\n from = [{\n schema: this,\n value: originalValue\n }, ...from]; // this flag is needed for handling `strict` correctly in the context of\n // validation vs just casting. e.g strict() on a field is only used when validating\n\n opts.__validating = true;\n opts.originalValue = originalValue;\n opts.from = from;\n\n super._validate(_value, opts, (err, value) => {\n if (err) {\n if (!ValidationError.isError(err) || abortEarly) {\n return void callback(err, value);\n }\n\n errors.push(err);\n }\n\n if (!recursive || !isObject(value)) {\n callback(errors[0] || null, value);\n return;\n }\n\n originalValue = originalValue || value;\n\n let tests = this._nodes.map(key => (_, cb) => {\n let path = key.indexOf('.') === -1 ? (opts.path ? `${opts.path}.` : '') + key : `${opts.path || ''}[\"${key}\"]`;\n let field = this.fields[key];\n\n if (field && 'validate' in field) {\n field.validate(value[key], _extends({}, opts, {\n // @ts-ignore\n path,\n from,\n // inner fields are always strict:\n // 1. this isn't strict so the casting will also have cast inner values\n // 2. this is strict in which case the nested values weren't cast either\n strict: true,\n parent: value,\n originalValue: originalValue[key]\n }), cb);\n return;\n }\n\n cb(null);\n });\n\n runTests({\n sync,\n tests,\n value,\n errors,\n endEarly: abortEarly,\n sort: this._sortErrors,\n path: opts.path\n }, callback);\n });\n }\n\n clone(spec) {\n const next = super.clone(spec);\n next.fields = _extends({}, this.fields);\n next._nodes = this._nodes;\n next._excludedEdges = this._excludedEdges;\n next._sortErrors = this._sortErrors;\n return next;\n }\n\n concat(schema) {\n let next = super.concat(schema);\n let nextFields = next.fields;\n\n for (let [field, schemaOrRef] of Object.entries(this.fields)) {\n const target = nextFields[field];\n\n if (target === undefined) {\n nextFields[field] = schemaOrRef;\n } else if (target instanceof BaseSchema && schemaOrRef instanceof BaseSchema) {\n nextFields[field] = schemaOrRef.concat(target);\n }\n }\n\n return next.withMutation(() => next.shape(nextFields, this._excludedEdges));\n }\n\n getDefaultFromShape() {\n let dft = {};\n\n this._nodes.forEach(key => {\n const field = this.fields[key];\n dft[key] = 'default' in field ? field.getDefault() : undefined;\n });\n\n return dft;\n }\n\n _getDefault() {\n if ('default' in this.spec) {\n return super._getDefault();\n } // if there is no default set invent one\n\n\n if (!this._nodes.length) {\n return undefined;\n }\n\n return this.getDefaultFromShape();\n }\n\n shape(additions, excludes = []) {\n let next = this.clone();\n let fields = Object.assign(next.fields, additions);\n next.fields = fields;\n next._sortErrors = sortByKeyOrder(Object.keys(fields));\n\n if (excludes.length) {\n // this is a convenience for when users only supply a single pair\n if (!Array.isArray(excludes[0])) excludes = [excludes];\n next._excludedEdges = [...next._excludedEdges, ...excludes];\n }\n\n next._nodes = sortFields(fields, next._excludedEdges);\n return next;\n }\n\n pick(keys) {\n const picked = {};\n\n for (const key of keys) {\n if (this.fields[key]) picked[key] = this.fields[key];\n }\n\n return this.clone().withMutation(next => {\n next.fields = {};\n return next.shape(picked);\n });\n }\n\n omit(keys) {\n const next = this.clone();\n const fields = next.fields;\n next.fields = {};\n\n for (const key of keys) {\n delete fields[key];\n }\n\n return next.withMutation(() => next.shape(fields));\n }\n\n from(from, to, alias) {\n let fromGetter = getter(from, true);\n return this.transform(obj => {\n if (obj == null) return obj;\n let newObj = obj;\n\n if (has(obj, from)) {\n newObj = _extends({}, obj);\n if (!alias) delete newObj[from];\n newObj[to] = fromGetter(obj);\n }\n\n return newObj;\n });\n }\n\n noUnknown(noAllow = true, message = locale.noUnknown) {\n if (typeof noAllow === 'string') {\n message = noAllow;\n noAllow = true;\n }\n\n let next = this.test({\n name: 'noUnknown',\n exclusive: true,\n message: message,\n\n test(value) {\n if (value == null) return true;\n const unknownKeys = unknown(this.schema, value);\n return !noAllow || unknownKeys.length === 0 || this.createError({\n params: {\n unknown: unknownKeys.join(', ')\n }\n });\n }\n\n });\n next.spec.noUnknown = noAllow;\n return next;\n }\n\n unknown(allow = true, message = locale.noUnknown) {\n return this.noUnknown(!allow, message);\n }\n\n transformKeys(fn) {\n return this.transform(obj => obj && mapKeys(obj, (_, key) => fn(key)));\n }\n\n camelCase() {\n return this.transformKeys(camelCase);\n }\n\n snakeCase() {\n return this.transformKeys(snakeCase);\n }\n\n constantCase() {\n return this.transformKeys(key => snakeCase(key).toUpperCase());\n }\n\n describe() {\n let base = super.describe();\n base.fields = mapValues(this.fields, value => value.describe());\n return base;\n }\n\n}\nexport function create(spec) {\n return new ObjectSchema(spec);\n}\ncreate.prototype = ObjectSchema.prototype;","function _extends() { _extends = Object.assign || 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); }\n\nimport isAbsent from './util/isAbsent';\nimport isSchema from './util/isSchema';\nimport printValue from './util/printValue';\nimport { array as locale } from './locale';\nimport runTests from './util/runTests';\nimport ValidationError from './ValidationError';\nimport BaseSchema from './schema';\nexport function create(type) {\n return new ArraySchema(type);\n}\nexport default class ArraySchema extends BaseSchema {\n constructor(type) {\n super({\n type: 'array'\n }); // `undefined` specifically means uninitialized, as opposed to\n // \"no subtype\"\n\n this.innerType = void 0;\n this.innerType = type;\n this.withMutation(() => {\n this.transform(function (values) {\n if (typeof values === 'string') try {\n values = JSON.parse(values);\n } catch (err) {\n values = null;\n }\n return this.isType(values) ? values : null;\n });\n });\n }\n\n _typeCheck(v) {\n return Array.isArray(v);\n }\n\n get _subType() {\n return this.innerType;\n }\n\n _cast(_value, _opts) {\n const value = super._cast(_value, _opts); //should ignore nulls here\n\n\n if (!this._typeCheck(value) || !this.innerType) return value;\n let isChanged = false;\n const castArray = value.map((v, idx) => {\n const castElement = this.innerType.cast(v, _extends({}, _opts, {\n path: `${_opts.path || ''}[${idx}]`\n }));\n\n if (castElement !== v) {\n isChanged = true;\n }\n\n return castElement;\n });\n return isChanged ? castArray : value;\n }\n\n _validate(_value, options = {}, callback) {\n var _options$abortEarly, _options$recursive;\n\n let errors = [];\n let sync = options.sync;\n let path = options.path;\n let innerType = this.innerType;\n let endEarly = (_options$abortEarly = options.abortEarly) != null ? _options$abortEarly : this.spec.abortEarly;\n let recursive = (_options$recursive = options.recursive) != null ? _options$recursive : this.spec.recursive;\n let originalValue = options.originalValue != null ? options.originalValue : _value;\n\n super._validate(_value, options, (err, value) => {\n if (err) {\n if (!ValidationError.isError(err) || endEarly) {\n return void callback(err, value);\n }\n\n errors.push(err);\n }\n\n if (!recursive || !innerType || !this._typeCheck(value)) {\n callback(errors[0] || null, value);\n return;\n }\n\n originalValue = originalValue || value; // #950 Ensure that sparse array empty slots are validated\n\n let tests = new Array(value.length);\n\n for (let idx = 0; idx < value.length; idx++) {\n let item = value[idx];\n let path = `${options.path || ''}[${idx}]`; // object._validate note for isStrict explanation\n\n let innerOptions = _extends({}, options, {\n path,\n strict: true,\n parent: value,\n index: idx,\n originalValue: originalValue[idx]\n });\n\n tests[idx] = (_, cb) => innerType.validate(item, innerOptions, cb);\n }\n\n runTests({\n sync,\n path,\n value,\n errors,\n endEarly,\n tests\n }, callback);\n });\n }\n\n clone(spec) {\n const next = super.clone(spec);\n next.innerType = this.innerType;\n return next;\n }\n\n concat(schema) {\n let next = super.concat(schema);\n next.innerType = this.innerType;\n if (schema.innerType) next.innerType = next.innerType ? // @ts-expect-error Lazy doesn't have concat()\n next.innerType.concat(schema.innerType) : schema.innerType;\n return next;\n }\n\n of(schema) {\n // FIXME: this should return a new instance of array without the default to be\n let next = this.clone();\n if (!isSchema(schema)) throw new TypeError('`array.of()` sub-schema must be a valid yup schema not: ' + printValue(schema)); // FIXME(ts):\n\n next.innerType = schema;\n return next;\n }\n\n length(length, message = locale.length) {\n return this.test({\n message,\n name: 'length',\n exclusive: true,\n params: {\n length\n },\n\n test(value) {\n return isAbsent(value) || value.length === this.resolve(length);\n }\n\n });\n }\n\n min(min, message) {\n message = message || locale.min;\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n min\n },\n\n // FIXME(ts): Array\n test(value) {\n return isAbsent(value) || value.length >= this.resolve(min);\n }\n\n });\n }\n\n max(max, message) {\n message = message || locale.max;\n return this.test({\n message,\n name: 'max',\n exclusive: true,\n params: {\n max\n },\n\n test(value) {\n return isAbsent(value) || value.length <= this.resolve(max);\n }\n\n });\n }\n\n ensure() {\n return this.default(() => []).transform((val, original) => {\n // We don't want to return `null` for nullable schema\n if (this._typeCheck(val)) return val;\n return original == null ? [] : [].concat(original);\n });\n }\n\n compact(rejector) {\n let reject = !rejector ? v => !!v : (v, i, a) => !rejector(v, i, a);\n return this.transform(values => values != null ? values.filter(reject) : values);\n }\n\n describe() {\n let base = super.describe();\n if (this.innerType) base.innerType = this.innerType.describe();\n return base;\n }\n\n nullable(isNullable = true) {\n return super.nullable(isNullable);\n }\n\n defined() {\n return super.defined();\n }\n\n required(msg) {\n return super.required(msg);\n }\n\n}\ncreate.prototype = ArraySchema.prototype; //\n// Interfaces\n//","(function() { module.exports = window[\"eventespresso\"][\"helpers\"]; }());","export * from './global';\n","var root = require('./_root');\n\n/** Built-in value references. */\nvar Symbol = root.Symbol;\n\nmodule.exports = Symbol;\n","(function() { module.exports = window[\"eventespresso\"][\"services\"]; }());","var getNative = require('./_getNative');\n\n/* Built-in method references that are verified to be native. */\nvar nativeCreate = getNative(Object, 'create');\n\nmodule.exports = nativeCreate;\n","var listCacheClear = require('./_listCacheClear'),\n listCacheDelete = require('./_listCacheDelete'),\n listCacheGet = require('./_listCacheGet'),\n listCacheHas = require('./_listCacheHas'),\n listCacheSet = require('./_listCacheSet');\n\n/**\n * Creates an list cache object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction ListCache(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `ListCache`.\nListCache.prototype.clear = listCacheClear;\nListCache.prototype['delete'] = listCacheDelete;\nListCache.prototype.get = listCacheGet;\nListCache.prototype.has = listCacheHas;\nListCache.prototype.set = listCacheSet;\n\nmodule.exports = ListCache;\n","var eq = require('./eq');\n\n/**\n * Gets the index at which the `key` is found in `array` of key-value pairs.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {*} key The key to search for.\n * @returns {number} Returns the index of the matched value, else `-1`.\n */\nfunction assocIndexOf(array, key) {\n var length = array.length;\n while (length--) {\n if (eq(array[length][0], key)) {\n return length;\n }\n }\n return -1;\n}\n\nmodule.exports = assocIndexOf;\n","var isKeyable = require('./_isKeyable');\n\n/**\n * Gets the data for `map`.\n *\n * @private\n * @param {Object} map The map to query.\n * @param {string} key The reference key.\n * @returns {*} Returns the map data.\n */\nfunction getMapData(map, key) {\n var data = map.__data__;\n return isKeyable(key)\n ? data[typeof key == 'string' ? 'string' : 'hash']\n : data.map;\n}\n\nmodule.exports = getMapData;\n","var isSymbol = require('./isSymbol');\n\n/** Used as references for various `Number` constants. */\nvar INFINITY = 1 / 0;\n\n/**\n * Converts `value` to a string key if it's not a string or symbol.\n *\n * @private\n * @param {*} value The value to inspect.\n * @returns {string|symbol} Returns the key.\n */\nfunction toKey(value) {\n if (typeof value == 'string' || isSymbol(value)) {\n return value;\n }\n var result = (value + '');\n return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;\n}\n\nmodule.exports = toKey;\n","var baseAssignValue = require('./_baseAssignValue'),\n baseForOwn = require('./_baseForOwn'),\n baseIteratee = require('./_baseIteratee');\n\n/**\n * Creates an object with the same keys as `object` and values generated\n * by running each own enumerable string keyed property of `object` thru\n * `iteratee`. The iteratee is invoked with three arguments:\n * (value, key, object).\n *\n * @static\n * @memberOf _\n * @since 2.4.0\n * @category Object\n * @param {Object} object The object to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @returns {Object} Returns the new mapped object.\n * @see _.mapKeys\n * @example\n *\n * var users = {\n * 'fred': { 'user': 'fred', 'age': 40 },\n * 'pebbles': { 'user': 'pebbles', 'age': 1 }\n * };\n *\n * _.mapValues(users, function(o) { return o.age; });\n * // => { 'fred': 40, 'pebbles': 1 } (iteration order is not guaranteed)\n *\n * // The `_.property` iteratee shorthand.\n * _.mapValues(users, 'age');\n * // => { 'fred': 40, 'pebbles': 1 } (iteration order is not guaranteed)\n */\nfunction mapValues(object, iteratee) {\n var result = {};\n iteratee = baseIteratee(iteratee, 3);\n\n baseForOwn(object, function(value, key, object) {\n baseAssignValue(result, key, iteratee(value, key, object));\n });\n return result;\n}\n\nmodule.exports = mapValues;\n","import setPrototypeOf from \"@babel/runtime/helpers/esm/setPrototypeOf\";\nimport isNativeReflectConstruct from \"@babel/runtime/helpers/esm/isNativeReflectConstruct\";\nexport default function _construct(Parent, args, Class) {\n if (isNativeReflectConstruct()) {\n _construct = Reflect.construct;\n } else {\n _construct = function _construct(Parent, args, Class) {\n var a = [null];\n a.push.apply(a, args);\n var Constructor = Function.bind.apply(Parent, a);\n var instance = new Constructor();\n if (Class) setPrototypeOf(instance, Class.prototype);\n return instance;\n };\n }\n\n return _construct.apply(null, arguments);\n}","import getPrototypeOf from \"@babel/runtime/helpers/esm/getPrototypeOf\";\nimport setPrototypeOf from \"@babel/runtime/helpers/esm/setPrototypeOf\";\nimport isNativeFunction from \"@babel/runtime/helpers/esm/isNativeFunction\";\nimport construct from \"@babel/runtime/helpers/esm/construct\";\nexport default function _wrapNativeSuper(Class) {\n var _cache = typeof Map === \"function\" ? new Map() : undefined;\n\n _wrapNativeSuper = function _wrapNativeSuper(Class) {\n if (Class === null || !isNativeFunction(Class)) return Class;\n\n if (typeof Class !== \"function\") {\n throw new TypeError(\"Super expression must either be null or a function\");\n }\n\n if (typeof _cache !== \"undefined\") {\n if (_cache.has(Class)) return _cache.get(Class);\n\n _cache.set(Class, Wrapper);\n }\n\n function Wrapper() {\n return construct(Class, arguments, getPrototypeOf(this).constructor);\n }\n\n Wrapper.prototype = Object.create(Class.prototype, {\n constructor: {\n value: Wrapper,\n enumerable: false,\n writable: true,\n configurable: true\n }\n });\n return setPrototypeOf(Wrapper, Class);\n };\n\n return _wrapNativeSuper(Class);\n}","export default function _isNativeFunction(fn) {\n return Function.toString.call(fn).indexOf(\"[native code]\") !== -1;\n}","(function() { module.exports = window[\"eventespresso\"][\"hooks\"]; }());","(function() { module.exports = window[\"eventespresso\"][\"adapters\"]; }());","(function() { module.exports = window[\"wp\"][\"i18n\"]; }());","import { createContext, useMemo } from 'react';\n\nimport type { ProviderProps, ContextProps } from './types';\nimport { DataStateProvider } from './DataStateProvider';\nimport { FilterStateProvider } from './FilterStateProvider';\n\nconst Context = createContext(null);\n\nconst { Provider, Consumer } = Context;\n\nconst ContextProvider: React.FC = ({ children, assignmentType, entity, title, onCloseModal }) => {\n\tconst value: ContextProps = useMemo(\n\t\t() => ({\n\t\t\tassignmentType,\n\t\t\tentity,\n\t\t\ttitle,\n\t\t\tonCloseModal,\n\t\t}),\n\t\t[assignmentType, entity, onCloseModal, title]\n\t);\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\t\t{children}\n\t\t\t\n\t\t\n\t);\n};\n\nexport { Context, ContextProvider, Consumer };\n","export { default as FilterBar } from './FilterBar';\n\nexport * from './filterState';\n","module.exports = function(module) {\n\tif (!module.webpackPolyfill) {\n\t\tmodule.deprecate = function() {};\n\t\tmodule.paths = [];\n\t\t// module.parent = undefined by default\n\t\tif (!module.children) module.children = [];\n\t\tObject.defineProperty(module, \"loaded\", {\n\t\t\tenumerable: true,\n\t\t\tget: function() {\n\t\t\t\treturn module.l;\n\t\t\t}\n\t\t});\n\t\tObject.defineProperty(module, \"id\", {\n\t\t\tenumerable: true,\n\t\t\tget: function() {\n\t\t\t\treturn module.i;\n\t\t\t}\n\t\t});\n\t\tmodule.webpackPolyfill = 1;\n\t}\n\treturn module;\n};\n","var isArray = require('./isArray'),\n isSymbol = require('./isSymbol');\n\n/** Used to match property names within property paths. */\nvar reIsDeepProp = /\\.|\\[(?:[^[\\]]*|([\"'])(?:(?!\\1)[^\\\\]|\\\\.)*?\\1)\\]/,\n reIsPlainProp = /^\\w*$/;\n\n/**\n * Checks if `value` is a property name and not a property path.\n *\n * @private\n * @param {*} value The value to check.\n * @param {Object} [object] The object to query keys on.\n * @returns {boolean} Returns `true` if `value` is a property name, else `false`.\n */\nfunction isKey(value, object) {\n if (isArray(value)) {\n return false;\n }\n var type = typeof value;\n if (type == 'number' || type == 'symbol' || type == 'boolean' ||\n value == null || isSymbol(value)) {\n return true;\n }\n return reIsPlainProp.test(value) || !reIsDeepProp.test(value) ||\n (object != null && value in Object(object));\n}\n\nmodule.exports = isKey;\n","var baseGetTag = require('./_baseGetTag'),\n isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar symbolTag = '[object Symbol]';\n\n/**\n * Checks if `value` is classified as a `Symbol` primitive or object.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a symbol, else `false`.\n * @example\n *\n * _.isSymbol(Symbol.iterator);\n * // => true\n *\n * _.isSymbol('abc');\n * // => false\n */\nfunction isSymbol(value) {\n return typeof value == 'symbol' ||\n (isObjectLike(value) && baseGetTag(value) == symbolTag);\n}\n\nmodule.exports = isSymbol;\n","var mapCacheClear = require('./_mapCacheClear'),\n mapCacheDelete = require('./_mapCacheDelete'),\n mapCacheGet = require('./_mapCacheGet'),\n mapCacheHas = require('./_mapCacheHas'),\n mapCacheSet = require('./_mapCacheSet');\n\n/**\n * Creates a map cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction MapCache(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `MapCache`.\nMapCache.prototype.clear = mapCacheClear;\nMapCache.prototype['delete'] = mapCacheDelete;\nMapCache.prototype.get = mapCacheGet;\nMapCache.prototype.has = mapCacheHas;\nMapCache.prototype.set = mapCacheSet;\n\nmodule.exports = MapCache;\n","/**\n * Checks if `value` is the\n * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)\n * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an object, else `false`.\n * @example\n *\n * _.isObject({});\n * // => true\n *\n * _.isObject([1, 2, 3]);\n * // => true\n *\n * _.isObject(_.noop);\n * // => true\n *\n * _.isObject(null);\n * // => false\n */\nfunction isObject(value) {\n var type = typeof value;\n return value != null && (type == 'object' || type == 'function');\n}\n\nmodule.exports = isObject;\n","(function() { module.exports = window[\"eventespresso\"][\"i18n\"]; }());","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar Map = getNative(root, 'Map');\n\nmodule.exports = Map;\n","/** Used as references for various `Number` constants. */\nvar MAX_SAFE_INTEGER = 9007199254740991;\n\n/**\n * Checks if `value` is a valid array-like length.\n *\n * **Note:** This method is loosely based on\n * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a valid length, else `false`.\n * @example\n *\n * _.isLength(3);\n * // => true\n *\n * _.isLength(Number.MIN_VALUE);\n * // => false\n *\n * _.isLength(Infinity);\n * // => false\n *\n * _.isLength('3');\n * // => false\n */\nfunction isLength(value) {\n return typeof value == 'number' &&\n value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;\n}\n\nmodule.exports = isLength;\n","var arrayLikeKeys = require('./_arrayLikeKeys'),\n baseKeys = require('./_baseKeys'),\n isArrayLike = require('./isArrayLike');\n\n/**\n * Creates an array of the own enumerable property names of `object`.\n *\n * **Note:** Non-object values are coerced to objects. See the\n * [ES spec](http://ecma-international.org/ecma-262/7.0/#sec-object.keys)\n * for more details.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Object\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.keys(new Foo);\n * // => ['a', 'b'] (iteration order is not guaranteed)\n *\n * _.keys('hi');\n * // => ['0', '1']\n */\nfunction keys(object) {\n return isArrayLike(object) ? arrayLikeKeys(object) : baseKeys(object);\n}\n\nmodule.exports = keys;\n","import arrayWithoutHoles from \"@babel/runtime/helpers/esm/arrayWithoutHoles\";\nimport iterableToArray from \"@babel/runtime/helpers/esm/iterableToArray\";\nimport unsupportedIterableToArray from \"@babel/runtime/helpers/esm/unsupportedIterableToArray\";\nimport nonIterableSpread from \"@babel/runtime/helpers/esm/nonIterableSpread\";\nexport default function _toConsumableArray(arr) {\n return arrayWithoutHoles(arr) || iterableToArray(arr) || unsupportedIterableToArray(arr) || nonIterableSpread();\n}","import arrayLikeToArray from \"@babel/runtime/helpers/esm/arrayLikeToArray\";\nexport default function _arrayWithoutHoles(arr) {\n if (Array.isArray(arr)) return arrayLikeToArray(arr);\n}","export default function _nonIterableSpread() {\n throw new TypeError(\"Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}","var createCompounder = require('./_createCompounder');\n\n/**\n * Converts `string` to\n * [snake case](https://en.wikipedia.org/wiki/Snake_case).\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to convert.\n * @returns {string} Returns the snake cased string.\n * @example\n *\n * _.snakeCase('Foo Bar');\n * // => 'foo_bar'\n *\n * _.snakeCase('fooBar');\n * // => 'foo_bar'\n *\n * _.snakeCase('--FOO-BAR--');\n * // => 'foo_bar'\n */\nvar snakeCase = createCompounder(function(result, word, index) {\n return result + (index ? '_' : '') + word.toLowerCase();\n});\n\nmodule.exports = snakeCase;\n","export default function toInteger(dirtyNumber) {\n if (dirtyNumber === null || dirtyNumber === true || dirtyNumber === false) {\n return NaN;\n }\n\n var number = Number(dirtyNumber);\n\n if (isNaN(number)) {\n return number;\n }\n\n return number < 0 ? Math.ceil(number) : Math.floor(number);\n}","module.exports = require(\"regenerator-runtime\");\n","(function() { module.exports = window[\"eventespresso\"][\"constants\"]; }());","export default function _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n}","import { TAMRelationalData } from './types';\n\nexport const TAM_ENTITIES: Array = ['datetimes', 'tickets'];\n","var castPath = require('./_castPath'),\n isArguments = require('./isArguments'),\n isArray = require('./isArray'),\n isIndex = require('./_isIndex'),\n isLength = require('./isLength'),\n toKey = require('./_toKey');\n\n/**\n * Checks if `path` exists on `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Array|string} path The path to check.\n * @param {Function} hasFunc The function to check properties.\n * @returns {boolean} Returns `true` if `path` exists, else `false`.\n */\nfunction hasPath(object, path, hasFunc) {\n path = castPath(path, object);\n\n var index = -1,\n length = path.length,\n result = false;\n\n while (++index < length) {\n var key = toKey(path[index]);\n if (!(result = object != null && hasFunc(object, key))) {\n break;\n }\n object = object[key];\n }\n if (result || ++index != length) {\n return result;\n }\n length = object == null ? 0 : object.length;\n return !!length && isLength(length) && isIndex(key, length) &&\n (isArray(object) || isArguments(object));\n}\n\nmodule.exports = hasPath;\n","var isArray = require('./isArray'),\n isKey = require('./_isKey'),\n stringToPath = require('./_stringToPath'),\n toString = require('./toString');\n\n/**\n * Casts `value` to a path array if it's not one.\n *\n * @private\n * @param {*} value The value to inspect.\n * @param {Object} [object] The object to query keys on.\n * @returns {Array} Returns the cast property path array.\n */\nfunction castPath(value, object) {\n if (isArray(value)) {\n return value;\n }\n return isKey(value, object) ? [value] : stringToPath(toString(value));\n}\n\nmodule.exports = castPath;\n","/** Detect free variable `global` from Node.js. */\nvar freeGlobal = typeof global == 'object' && global && global.Object === Object && global;\n\nmodule.exports = freeGlobal;\n","var baseGetTag = require('./_baseGetTag'),\n isObject = require('./isObject');\n\n/** `Object#toString` result references. */\nvar asyncTag = '[object AsyncFunction]',\n funcTag = '[object Function]',\n genTag = '[object GeneratorFunction]',\n proxyTag = '[object Proxy]';\n\n/**\n * Checks if `value` is classified as a `Function` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a function, else `false`.\n * @example\n *\n * _.isFunction(_);\n * // => true\n *\n * _.isFunction(/abc/);\n * // => false\n */\nfunction isFunction(value) {\n if (!isObject(value)) {\n return false;\n }\n // The use of `Object#toString` avoids issues with the `typeof` operator\n // in Safari 9 which returns 'object' for typed arrays and other constructors.\n var tag = baseGetTag(value);\n return tag == funcTag || tag == genTag || tag == asyncTag || tag == proxyTag;\n}\n\nmodule.exports = isFunction;\n","export default function _arrayLikeToArray(arr, len) {\n if (len == null || len > arr.length) len = arr.length;\n\n for (var i = 0, arr2 = new Array(len); i < len; i++) {\n arr2[i] = arr[i];\n }\n\n return arr2;\n}","/** Used for built-in method references. */\nvar funcProto = Function.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/**\n * Converts `func` to its source code.\n *\n * @private\n * @param {Function} func The function to convert.\n * @returns {string} Returns the source code.\n */\nfunction toSource(func) {\n if (func != null) {\n try {\n return funcToString.call(func);\n } catch (e) {}\n try {\n return (func + '');\n } catch (e) {}\n }\n return '';\n}\n\nmodule.exports = toSource;\n","/**\n * Performs a\n * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * comparison between two values to determine if they are equivalent.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n * @example\n *\n * var object = { 'a': 1 };\n * var other = { 'a': 1 };\n *\n * _.eq(object, object);\n * // => true\n *\n * _.eq(object, other);\n * // => false\n *\n * _.eq('a', 'a');\n * // => true\n *\n * _.eq('a', Object('a'));\n * // => false\n *\n * _.eq(NaN, NaN);\n * // => true\n */\nfunction eq(value, other) {\n return value === other || (value !== value && other !== other);\n}\n\nmodule.exports = eq;\n","var baseIsArguments = require('./_baseIsArguments'),\n isObjectLike = require('./isObjectLike');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Built-in value references. */\nvar propertyIsEnumerable = objectProto.propertyIsEnumerable;\n\n/**\n * Checks if `value` is likely an `arguments` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\n * else `false`.\n * @example\n *\n * _.isArguments(function() { return arguments; }());\n * // => true\n *\n * _.isArguments([1, 2, 3]);\n * // => false\n */\nvar isArguments = baseIsArguments(function() { return arguments; }()) ? baseIsArguments : function(value) {\n return isObjectLike(value) && hasOwnProperty.call(value, 'callee') &&\n !propertyIsEnumerable.call(value, 'callee');\n};\n\nmodule.exports = isArguments;\n","/** Used as references for various `Number` constants. */\nvar MAX_SAFE_INTEGER = 9007199254740991;\n\n/** Used to detect unsigned integer values. */\nvar reIsUint = /^(?:0|[1-9]\\d*)$/;\n\n/**\n * Checks if `value` is a valid array-like index.\n *\n * @private\n * @param {*} value The value to check.\n * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index.\n * @returns {boolean} Returns `true` if `value` is a valid index, else `false`.\n */\nfunction isIndex(value, length) {\n var type = typeof value;\n length = length == null ? MAX_SAFE_INTEGER : length;\n\n return !!length &&\n (type == 'number' ||\n (type != 'symbol' && reIsUint.test(value))) &&\n (value > -1 && value % 1 == 0 && value < length);\n}\n\nmodule.exports = isIndex;\n","var defineProperty = require('./_defineProperty');\n\n/**\n * The base implementation of `assignValue` and `assignMergeValue` without\n * value checks.\n *\n * @private\n * @param {Object} object The object to modify.\n * @param {string} key The key of the property to assign.\n * @param {*} value The value to assign.\n */\nfunction baseAssignValue(object, key, value) {\n if (key == '__proto__' && defineProperty) {\n defineProperty(object, key, {\n 'configurable': true,\n 'enumerable': true,\n 'value': value,\n 'writable': true\n });\n } else {\n object[key] = value;\n }\n}\n\nmodule.exports = baseAssignValue;\n","var baseFor = require('./_baseFor'),\n keys = require('./keys');\n\n/**\n * The base implementation of `_.forOwn` without support for iteratee shorthands.\n *\n * @private\n * @param {Object} object The object to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Object} Returns `object`.\n */\nfunction baseForOwn(object, iteratee) {\n return object && baseFor(object, iteratee, keys);\n}\n\nmodule.exports = baseForOwn;\n","var root = require('./_root'),\n stubFalse = require('./stubFalse');\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Built-in value references. */\nvar Buffer = moduleExports ? root.Buffer : undefined;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined;\n\n/**\n * Checks if `value` is a buffer.\n *\n * @static\n * @memberOf _\n * @since 4.3.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a buffer, else `false`.\n * @example\n *\n * _.isBuffer(new Buffer(2));\n * // => true\n *\n * _.isBuffer(new Uint8Array(2));\n * // => false\n */\nvar isBuffer = nativeIsBuffer || stubFalse;\n\nmodule.exports = isBuffer;\n","var baseIsTypedArray = require('./_baseIsTypedArray'),\n baseUnary = require('./_baseUnary'),\n nodeUtil = require('./_nodeUtil');\n\n/* Node.js helper references. */\nvar nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray;\n\n/**\n * Checks if `value` is classified as a typed array.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n * @example\n *\n * _.isTypedArray(new Uint8Array);\n * // => true\n *\n * _.isTypedArray([]);\n * // => false\n */\nvar isTypedArray = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray;\n\nmodule.exports = isTypedArray;\n","var baseMatches = require('./_baseMatches'),\n baseMatchesProperty = require('./_baseMatchesProperty'),\n identity = require('./identity'),\n isArray = require('./isArray'),\n property = require('./property');\n\n/**\n * The base implementation of `_.iteratee`.\n *\n * @private\n * @param {*} [value=_.identity] The value to convert to an iteratee.\n * @returns {Function} Returns the iteratee.\n */\nfunction baseIteratee(value) {\n // Don't store the `typeof` result in a variable to avoid a JIT bug in Safari 9.\n // See https://bugs.webkit.org/show_bug.cgi?id=156034 for more details.\n if (typeof value == 'function') {\n return value;\n }\n if (value == null) {\n return identity;\n }\n if (typeof value == 'object') {\n return isArray(value)\n ? baseMatchesProperty(value[0], value[1])\n : baseMatches(value);\n }\n return property(value);\n}\n\nmodule.exports = baseIteratee;\n","var ListCache = require('./_ListCache'),\n stackClear = require('./_stackClear'),\n stackDelete = require('./_stackDelete'),\n stackGet = require('./_stackGet'),\n stackHas = require('./_stackHas'),\n stackSet = require('./_stackSet');\n\n/**\n * Creates a stack cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction Stack(entries) {\n var data = this.__data__ = new ListCache(entries);\n this.size = data.size;\n}\n\n// Add methods to `Stack`.\nStack.prototype.clear = stackClear;\nStack.prototype['delete'] = stackDelete;\nStack.prototype.get = stackGet;\nStack.prototype.has = stackHas;\nStack.prototype.set = stackSet;\n\nmodule.exports = Stack;\n","(function() { module.exports = window[\"R\"]; }());","var baseIsEqualDeep = require('./_baseIsEqualDeep'),\n isObjectLike = require('./isObjectLike');\n\n/**\n * The base implementation of `_.isEqual` which supports partial comparisons\n * and tracks traversed objects.\n *\n * @private\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @param {boolean} bitmask The bitmask flags.\n * 1 - Unordered comparison\n * 2 - Partial comparison\n * @param {Function} [customizer] The function to customize comparisons.\n * @param {Object} [stack] Tracks traversed `value` and `other` objects.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n */\nfunction baseIsEqual(value, other, bitmask, customizer, stack) {\n if (value === other) {\n return true;\n }\n if (value == null || other == null || (!isObjectLike(value) && !isObjectLike(other))) {\n return value !== value && other !== other;\n }\n return baseIsEqualDeep(value, other, bitmask, customizer, baseIsEqual, stack);\n}\n\nmodule.exports = baseIsEqual;\n","var SetCache = require('./_SetCache'),\n arraySome = require('./_arraySome'),\n cacheHas = require('./_cacheHas');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/**\n * A specialized version of `baseIsEqualDeep` for arrays with support for\n * partial deep comparisons.\n *\n * @private\n * @param {Array} array The array to compare.\n * @param {Array} other The other array to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `array` and `other` objects.\n * @returns {boolean} Returns `true` if the arrays are equivalent, else `false`.\n */\nfunction equalArrays(array, other, bitmask, customizer, equalFunc, stack) {\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG,\n arrLength = array.length,\n othLength = other.length;\n\n if (arrLength != othLength && !(isPartial && othLength > arrLength)) {\n return false;\n }\n // Check that cyclic values are equal.\n var arrStacked = stack.get(array);\n var othStacked = stack.get(other);\n if (arrStacked && othStacked) {\n return arrStacked == other && othStacked == array;\n }\n var index = -1,\n result = true,\n seen = (bitmask & COMPARE_UNORDERED_FLAG) ? new SetCache : undefined;\n\n stack.set(array, other);\n stack.set(other, array);\n\n // Ignore non-index properties.\n while (++index < arrLength) {\n var arrValue = array[index],\n othValue = other[index];\n\n if (customizer) {\n var compared = isPartial\n ? customizer(othValue, arrValue, index, other, array, stack)\n : customizer(arrValue, othValue, index, array, other, stack);\n }\n if (compared !== undefined) {\n if (compared) {\n continue;\n }\n result = false;\n break;\n }\n // Recursively compare arrays (susceptible to call stack limits).\n if (seen) {\n if (!arraySome(other, function(othValue, othIndex) {\n if (!cacheHas(seen, othIndex) &&\n (arrValue === othValue || equalFunc(arrValue, othValue, bitmask, customizer, stack))) {\n return seen.push(othIndex);\n }\n })) {\n result = false;\n break;\n }\n } else if (!(\n arrValue === othValue ||\n equalFunc(arrValue, othValue, bitmask, customizer, stack)\n )) {\n result = false;\n break;\n }\n }\n stack['delete'](array);\n stack['delete'](other);\n return result;\n}\n\nmodule.exports = equalArrays;\n","var isObject = require('./isObject');\n\n/**\n * Checks if `value` is suitable for strict equality comparisons, i.e. `===`.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` if suitable for strict\n * equality comparisons, else `false`.\n */\nfunction isStrictComparable(value) {\n return value === value && !isObject(value);\n}\n\nmodule.exports = isStrictComparable;\n","/**\n * A specialized version of `matchesProperty` for source values suitable\n * for strict equality comparisons, i.e. `===`.\n *\n * @private\n * @param {string} key The key of the property to get.\n * @param {*} srcValue The value to match.\n * @returns {Function} Returns the new spec function.\n */\nfunction matchesStrictComparable(key, srcValue) {\n return function(object) {\n if (object == null) {\n return false;\n }\n return object[key] === srcValue &&\n (srcValue !== undefined || (key in Object(object)));\n };\n}\n\nmodule.exports = matchesStrictComparable;\n","var castPath = require('./_castPath'),\n toKey = require('./_toKey');\n\n/**\n * The base implementation of `_.get` without support for default values.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Array|string} path The path of the property to get.\n * @returns {*} Returns the resolved value.\n */\nfunction baseGet(object, path) {\n path = castPath(path, object);\n\n var index = 0,\n length = path.length;\n\n while (object != null && index < length) {\n object = object[toKey(path[index++])];\n }\n return (index && index == length) ? object : undefined;\n}\n\nmodule.exports = baseGet;\n","var arrayReduce = require('./_arrayReduce'),\n deburr = require('./deburr'),\n words = require('./words');\n\n/** Used to compose unicode capture groups. */\nvar rsApos = \"['\\u2019]\";\n\n/** Used to match apostrophes. */\nvar reApos = RegExp(rsApos, 'g');\n\n/**\n * Creates a function like `_.camelCase`.\n *\n * @private\n * @param {Function} callback The function to combine each word.\n * @returns {Function} Returns the new compounder function.\n */\nfunction createCompounder(callback) {\n return function(string) {\n return arrayReduce(words(deburr(string).replace(reApos, '')), callback, '');\n };\n}\n\nmodule.exports = createCompounder;\n","/** Used to compose unicode character classes. */\nvar rsAstralRange = '\\\\ud800-\\\\udfff',\n rsComboMarksRange = '\\\\u0300-\\\\u036f',\n reComboHalfMarksRange = '\\\\ufe20-\\\\ufe2f',\n rsComboSymbolsRange = '\\\\u20d0-\\\\u20ff',\n rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange,\n rsVarRange = '\\\\ufe0e\\\\ufe0f';\n\n/** Used to compose unicode capture groups. */\nvar rsZWJ = '\\\\u200d';\n\n/** Used to detect strings with [zero-width joiners or code points from the astral planes](http://eev.ee/blog/2015/09/12/dark-corners-of-unicode/). */\nvar reHasUnicode = RegExp('[' + rsZWJ + rsAstralRange + rsComboRange + rsVarRange + ']');\n\n/**\n * Checks if `string` contains Unicode symbols.\n *\n * @private\n * @param {string} string The string to inspect.\n * @returns {boolean} Returns `true` if a symbol is found, else `false`.\n */\nfunction hasUnicode(string) {\n return reHasUnicode.test(string);\n}\n\nmodule.exports = hasUnicode;\n","import arrayLikeToArray from \"@babel/runtime/helpers/esm/arrayLikeToArray\";\nexport default function _unsupportedIterableToArray(o, minLen) {\n if (!o) return;\n if (typeof o === \"string\") return arrayLikeToArray(o, minLen);\n var n = Object.prototype.toString.call(o).slice(8, -1);\n if (n === \"Object\" && o.constructor) n = o.constructor.name;\n if (n === \"Map\" || n === \"Set\") return Array.from(o);\n if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return arrayLikeToArray(o, minLen);\n}","function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {\n try {\n var info = gen[key](arg);\n var value = info.value;\n } catch (error) {\n reject(error);\n return;\n }\n\n if (info.done) {\n resolve(value);\n } else {\n Promise.resolve(value).then(_next, _throw);\n }\n}\n\nexport default function _asyncToGenerator(fn) {\n return function () {\n var self = this,\n args = arguments;\n return new Promise(function (resolve, reject) {\n var gen = fn.apply(self, args);\n\n function _next(value) {\n asyncGeneratorStep(gen, resolve, reject, _next, _throw, \"next\", value);\n }\n\n function _throw(err) {\n asyncGeneratorStep(gen, resolve, reject, _next, _throw, \"throw\", err);\n }\n\n _next(undefined);\n });\n };\n}","(function() { module.exports = window[\"wp\"][\"url\"]; }());","var capitalize = require('./capitalize'),\n createCompounder = require('./_createCompounder');\n\n/**\n * Converts `string` to [camel case](https://en.wikipedia.org/wiki/CamelCase).\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to convert.\n * @returns {string} Returns the camel cased string.\n * @example\n *\n * _.camelCase('Foo Bar');\n * // => 'fooBar'\n *\n * _.camelCase('--foo-bar--');\n * // => 'fooBar'\n *\n * _.camelCase('__FOO_BAR__');\n * // => 'fooBar'\n */\nvar camelCase = createCompounder(function(result, word, index) {\n word = word.toLowerCase();\n return result + (index ? capitalize(word) : word);\n});\n\nmodule.exports = camelCase;\n","var baseAssignValue = require('./_baseAssignValue'),\n baseForOwn = require('./_baseForOwn'),\n baseIteratee = require('./_baseIteratee');\n\n/**\n * The opposite of `_.mapValues`; this method creates an object with the\n * same values as `object` and keys generated by running each own enumerable\n * string keyed property of `object` thru `iteratee`. The iteratee is invoked\n * with three arguments: (value, key, object).\n *\n * @static\n * @memberOf _\n * @since 3.8.0\n * @category Object\n * @param {Object} object The object to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @returns {Object} Returns the new mapped object.\n * @see _.mapValues\n * @example\n *\n * _.mapKeys({ 'a': 1, 'b': 2 }, function(value, key) {\n * return key + value;\n * });\n * // => { 'a1': 1, 'b2': 2 }\n */\nfunction mapKeys(object, iteratee) {\n var result = {};\n iteratee = baseIteratee(iteratee, 3);\n\n baseForOwn(object, function(value, key, object) {\n baseAssignValue(result, iteratee(value, key, object), value);\n });\n return result;\n}\n\nmodule.exports = mapKeys;\n","\n/**\n * Topological sorting function\n *\n * @param {Array} edges\n * @returns {Array}\n */\n\nmodule.exports = function(edges) {\n return toposort(uniqueNodes(edges), edges)\n}\n\nmodule.exports.array = toposort\n\nfunction toposort(nodes, edges) {\n var cursor = nodes.length\n , sorted = new Array(cursor)\n , visited = {}\n , i = cursor\n // Better data structures make algorithm much faster.\n , outgoingEdges = makeOutgoingEdges(edges)\n , nodesHash = makeNodesHash(nodes)\n\n // check for unknown nodes\n edges.forEach(function(edge) {\n if (!nodesHash.has(edge[0]) || !nodesHash.has(edge[1])) {\n throw new Error('Unknown node. There is an unknown node in the supplied edges.')\n }\n })\n\n while (i--) {\n if (!visited[i]) visit(nodes[i], i, new Set())\n }\n\n return sorted\n\n function visit(node, i, predecessors) {\n if(predecessors.has(node)) {\n var nodeRep\n try {\n nodeRep = \", node was:\" + JSON.stringify(node)\n } catch(e) {\n nodeRep = \"\"\n }\n throw new Error('Cyclic dependency' + nodeRep)\n }\n\n if (!nodesHash.has(node)) {\n throw new Error('Found unknown node. Make sure to provided all involved nodes. Unknown node: '+JSON.stringify(node))\n }\n\n if (visited[i]) return;\n visited[i] = true\n\n var outgoing = outgoingEdges.get(node) || new Set()\n outgoing = Array.from(outgoing)\n\n if (i = outgoing.length) {\n predecessors.add(node)\n do {\n var child = outgoing[--i]\n visit(child, nodesHash.get(child), predecessors)\n } while (i)\n predecessors.delete(node)\n }\n\n sorted[--cursor] = node\n }\n}\n\nfunction uniqueNodes(arr){\n var res = new Set()\n for (var i = 0, len = arr.length; i < len; i++) {\n var edge = arr[i]\n res.add(edge[0])\n res.add(edge[1])\n }\n return Array.from(res)\n}\n\nfunction makeOutgoingEdges(arr){\n var edges = new Map()\n for (var i = 0, len = arr.length; i < len; i++) {\n var edge = arr[i]\n if (!edges.has(edge[0])) edges.set(edge[0], new Set())\n if (!edges.has(edge[1])) edges.set(edge[1], new Set())\n edges.get(edge[0]).add(edge[1])\n }\n return edges\n}\n\nfunction makeNodesHash(arr){\n var res = new Map()\n for (var i = 0, len = arr.length; i < len; i++) {\n res.set(arr[i], i)\n }\n return res\n}\n","(function() { module.exports = window[\"eventespresso\"][\"registry\"]; }());","import * as R from 'ramda';\nimport { parseISO } from 'date-fns';\n\nimport type { EntityId } from '@eventespresso/data';\nimport type { AnyObject } from '@eventespresso/utils';\nimport type { TAMPossibleRelation, TAMRelationEntity, TAMRelationalData, TAMRelationalEntity } from '../types';\nimport type { Datetime, Ticket } from '@eventespresso/edtr-services';\nimport type { OptionsType } from '@eventespresso/adapters';\nimport { sortDates, minDateCapacity } from '@eventespresso/predicates';\nimport { parseInfinity, isInfinite, idToPropMap } from '@eventespresso/utils';\nimport { getMonthName } from '@eventespresso/dates';\n\nexport type EntitiesToUpdate = Array<[EntityId, TAMPossibleRelation]>;\n\ninterface EntitiesForUpdateOptions {\n\tentity: Entity;\n\texistingData: TAMRelationalData;\n\tnewData: TAMRelationalData;\n\trelation: Exclude;\n}\n\nexport const prepareEntitiesForUpdate = ({\n\tentity,\n\texistingData,\n\tnewData,\n\trelation,\n}: EntitiesForUpdateOptions): EntitiesToUpdate => {\n\tconst existingEntities = R.pathOr({}, [entity], existingData);\n\tconst newEntities = R.pathOr({}, [entity], newData);\n\n\treturn R.filter(([entityId, possibleRelation]) => {\n\t\tconst newRelatedEntities = R.pathOr([], [relation], possibleRelation);\n\t\tconst oldRelatedEntities = R.pathOr([], [entityId, relation], existingEntities);\n\t\t// make sure to sort them before compare\n\t\t// to make sure that they are actually different\n\t\treturn !R.equals(newRelatedEntities.sort(), oldRelatedEntities.sort());\n\t}, Object.entries(newEntities));\n};\n\ntype TicketsWithQuantityArgs = {\n\tticketsToUpdate: EntitiesToUpdate;\n\texistingData: TAMRelationalData;\n\tallDates: Array;\n\tallTickets: Array;\n};\n\n/**\n * Returns the tickets to quantity map of the tickets that need update\n */\nexport const ticketsWithNewQuantity = ({\n\tallDates,\n\tallTickets,\n\texistingData,\n\tticketsToUpdate,\n}: TicketsWithQuantityArgs): AnyObject => {\n\t// create a map of ticket ids to quantities\n\tconst ticketIdToQuantityMap = idToPropMap('quantity', allTickets);\n\n\tconst getMinDateCapacity = minDateCapacity(allDates);\n\n\t/**\n\t * This becomes an object with key as ticket id and value as new ticket quantity\n\t * {\n\t * [ticket.id]: quantity\n\t * }\n\t */\n\treturn ticketsToUpdate.reduce>((acc, [ticketId, possibleRelation]) => {\n\t\t// These are the related date ids before TAM was launched\n\t\tconst existingRelatedDateIds = existingData?.tickets?.[ticketId]?.datetimes || [];\n\t\t// These are the related date ids that have been assigned in TAM\n\t\t// these contain old and newly assigned date ids\n\t\tconst allNewRelatedDateIds: Array = possibleRelation?.datetimes || [];\n\n\t\t// lets filter out the existing ones\n\t\tconst newOnlyRelatedDateIds = allNewRelatedDateIds.filter(\n\t\t\t// it's new only if it was not in existing relations\n\t\t\t(dateId) => !existingRelatedDateIds.includes(dateId)\n\t\t);\n\n\t\t// we need to set the ticket quantity to the minimum of all the capacities\n\t\tconst minimumCapacity = getMinDateCapacity(newOnlyRelatedDateIds);\n\n\t\t// Make sure that the non negative ticket quantity value is compared with\n\t\t// a non negative datetime capacity value in Math.min()\n\t\tconst nonNegativeTicketQuantity = parseInfinity(ticketIdToQuantityMap?.[ticketId], Infinity);\n\n\t\t// if capacity is infinite or it's more than ticket quantity\n\t\tif (isInfinite(minimumCapacity) || minimumCapacity >= nonNegativeTicketQuantity) {\n\t\t\t// no need to update the ticket quantity\n\t\t\treturn acc;\n\t\t}\n\n\t\t// set the quantity to minimum capacity\n\t\treturn R.assocPath([ticketId], minimumCapacity, acc);\n\t}, {});\n};\n\n/**\n * e.g\n * {\n * 2019: {\n * 9: 'October',\n * 10: 'November',\n * 11: 'December',\n * },\n * 2020: {\n * 0: 'Januray',\n * 1: 'February',\n * 2: 'March',\n * 3: 'April',\n * },\n * }\n */\ntype YearWiseMonths = AnyObject>;\n\nconst getYearWiseMonthsFromDates = (dates: Array): YearWiseMonths => {\n\tconst sortedDates = sortDates({ dates });\n\n\tconst yearWiseMonths = sortedDates.reduce((acc, { startDate }) => {\n\t\tconst parsedDate = parseISO(startDate);\n\t\tconst year = parsedDate.getFullYear();\n\t\tconst month = parsedDate.getMonth();\n\n\t\tconst monthsInTheYear = acc[year] || {};\n\t\tif (!(month in monthsInTheYear)) {\n\t\t\tmonthsInTheYear[month] = getMonthName(parsedDate);\n\n\t\t\treturn {\n\t\t\t\t...acc,\n\t\t\t\t[year]: monthsInTheYear,\n\t\t\t};\n\t\t}\n\t\treturn acc;\n\t}, {});\n\n\treturn yearWiseMonths;\n};\n\nexport const getMonthsListFromDatetimes = (dates: Array): OptionsType => {\n\tconst yearWiseMonths = getYearWiseMonthsFromDates(dates);\n\n\tconst list = Object.entries(yearWiseMonths).map(([year, months]) => {\n\t\treturn {\n\t\t\tkey: year,\n\t\t\tlabel: year,\n\t\t\toptions: Object.entries(months).map(([monthNumber, monthName]) => {\n\t\t\t\treturn {\n\t\t\t\t\tkey: `${year}:${monthNumber}`,\n\t\t\t\t\tlabel: monthName,\n\t\t\t\t\tvalue: `${year}:${monthNumber}`,\n\t\t\t\t};\n\t\t\t}),\n\t\t};\n\t});\n\n\treturn list;\n};\n","export default function _getPrototypeOf(o) {\n _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) {\n return o.__proto__ || Object.getPrototypeOf(o);\n };\n return _getPrototypeOf(o);\n}","import { useEventsHandler, useCacheRehydration } from '@eventespresso/edtr-services';\n\nconst useEditorInitialization = (): boolean => {\n\t// register global event handlers\n\tuseEventsHandler();\n\n\t// rehydrate data cache\n\treturn useCacheRehydration();\n};\n\nexport default useEditorInitialization;\n","import { useMemo } from 'react';\n\nimport type { EntityId } from '@eventespresso/data';\nimport { EntityCardDetailsSubscription, EntityCardDetailsRegistry } from '@eventespresso/registry';\nimport { domain } from '@eventespresso/edtr-services';\nimport { useMemoStringify } from '@eventespresso/hooks';\n\nconst { getSubscriptions } = new EntityCardDetailsSubscription(domain);\n\nconst useEntityCardDetailsItems = (\n\tentityType: T,\n\tentityId: EntityId,\n\tfilterByEntityType = true\n): Array => {\n\tconst registry = useMemo(\n\t\t() => new EntityCardDetailsRegistry({ domain, entityType, entityId }),\n\t\t[entityId, entityType]\n\t);\n\n\tconst { generateElements } = registry;\n\n\tconst subscriptions = getSubscriptions({ entityType: filterByEntityType ? entityType : null });\n\n\tObject.values(subscriptions).forEach(({ callback }) => {\n\t\tcallback({ entityType, entityId, registry });\n\t});\n\n\t// it should only change if subscriptions change\n\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\treturn useMemoStringify(generateElements(), Object.keys(subscriptions));\n};\n\nexport default useEntityCardDetailsItems;\n","import { useMemo } from 'react';\n\nimport { NewEntitySubscription, NewEntityOptionsRegistry } from '@eventespresso/registry';\nimport { domain } from '@eventespresso/edtr-services';\nimport { useMemoStringify } from '@eventespresso/hooks';\n\nconst { getSubscriptions } = new NewEntitySubscription(domain);\n\nconst useNewEntityOptionItems = (\n\tentityType: T,\n\tfilterByEntityType = true\n): Array => {\n\tconst registry = useMemo(() => new NewEntityOptionsRegistry({ domain, entityType }), [entityType]);\n\n\tconst { generateElements } = registry;\n\n\tconst subscriptions = getSubscriptions({ entityType: filterByEntityType ? entityType : null });\n\n\tObject.values(subscriptions).forEach(({ callback }) => {\n\t\tcallback({ entityType, registry });\n\t});\n\n\t// it should only change if subscriptions change\n\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\treturn useMemoStringify(generateElements(), Object.keys(subscriptions));\n};\n\nexport default useNewEntityOptionItems;\n","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst Trash = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(Trash, 'trash');\n","function _defineProperties(target, props) {\n for (var i = 0; i < props.length; i++) {\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n Object.defineProperty(target, descriptor.key, descriptor);\n }\n}\n\nexport default function _createClass(Constructor, protoProps, staticProps) {\n if (protoProps) _defineProperties(Constructor.prototype, protoProps);\n if (staticProps) _defineProperties(Constructor, staticProps);\n return Constructor;\n}","(function() { module.exports = window[\"eventespresso\"][\"uiComponents\"]; }());","(function() { module.exports = window[\"eventespresso\"][\"dates\"]; }());","import setPrototypeOf from \"@babel/runtime/helpers/esm/setPrototypeOf\";\nexport default function _inherits(subClass, superClass) {\n if (typeof superClass !== \"function\" && superClass !== null) {\n throw new TypeError(\"Super expression must either be null or a function\");\n }\n\n subClass.prototype = Object.create(superClass && superClass.prototype, {\n constructor: {\n value: subClass,\n writable: true,\n configurable: true\n }\n });\n if (superClass) setPrototypeOf(subClass, superClass);\n}","import _typeof from \"@babel/runtime/helpers/esm/typeof\";\nimport assertThisInitialized from \"@babel/runtime/helpers/esm/assertThisInitialized\";\nexport default function _possibleConstructorReturn(self, call) {\n if (call && (_typeof(call) === \"object\" || typeof call === \"function\")) {\n return call;\n }\n\n return assertThisInitialized(self);\n}","import getPrototypeOf from \"@babel/runtime/helpers/esm/getPrototypeOf\";\nimport isNativeReflectConstruct from \"@babel/runtime/helpers/esm/isNativeReflectConstruct\";\nimport possibleConstructorReturn from \"@babel/runtime/helpers/esm/possibleConstructorReturn\";\nexport default function _createSuper(Derived) {\n var hasNativeReflectConstruct = isNativeReflectConstruct();\n return function _createSuperInternal() {\n var Super = getPrototypeOf(Derived),\n result;\n\n if (hasNativeReflectConstruct) {\n var NewTarget = getPrototypeOf(this).constructor;\n result = Reflect.construct(Super, arguments, NewTarget);\n } else {\n result = Super.apply(this, arguments);\n }\n\n return possibleConstructorReturn(this, result);\n };\n}","import { createContext } from 'react';\n\nimport { useMemoStringify } from '@eventespresso/hooks';\nimport { DataStateManager, BaseProps } from '../types';\nimport { useDataStateManager } from '../data';\n\nconst DataStateContext = createContext(null);\n\nconst { Provider, Consumer: DataStateConsumer } = DataStateContext;\n\nconst DataStateProvider: React.FC = ({ children, assignmentType, entity }) => {\n\tconst props = useMemoStringify({ assignmentType, entity });\n\tconst data = useDataStateManager(props);\n\n\treturn {children};\n};\n\nexport { DataStateContext, DataStateProvider, DataStateConsumer };\n","export { default as useFilterStateManager } from './useFilterStateManager';\n\nexport { default as useFilterState } from './useFilterState';\n\nexport * from './types';\n","import { createContext } from 'react';\n\nimport { useFilterStateManager, FilterStateManager } from '../filters/filterState';\n\nconst FilterStateContext = createContext(null);\n\nconst { Provider, Consumer: FilterStateConsumer } = FilterStateContext;\n\nconst FilterStateProvider: React.FC = ({ children }) => {\n\tconst filterstate = useFilterStateManager();\n\n\treturn {children};\n};\n\nexport { FilterStateContext, FilterStateProvider, FilterStateConsumer };\n","import { useCallback } from 'react';\n\nimport { useDefaultTickets } from '@eventespresso/edtr-services';\nimport { idToEntityMap } from '@eventespresso/predicates';\nimport { useTicketPrices } from '@eventespresso/edtr-services';\nimport { usePriceToTpcModifier, preparePricesForTpc } from '@eventespresso/tpc';\n\nimport type { StateInitializer } from './types';\n\n/**\n * Initializes the data state dynamically.\n */\nconst useInitialState = (): StateInitializer => {\n\tconst defaultTickets = useDefaultTickets();\n\tconst getTicketPrices = useTicketPrices();\n\tconst convertPriceToTpcModifier = usePriceToTpcModifier();\n\n\treturn useCallback(\n\t\t(initialState) => {\n\t\t\tconst normalizedTickets = defaultTickets.map((ticket) => {\n\t\t\t\t// get all related prices\n\t\t\t\tconst unSortedPrices = getTicketPrices(ticket.id);\n\n\t\t\t\t// convert to TPC price objects\n\t\t\t\tconst prices = preparePricesForTpc(unSortedPrices, convertPriceToTpcModifier);\n\n\t\t\t\treturn { ...ticket, prices };\n\t\t\t});\n\n\t\t\tconst tickets = idToEntityMap(normalizedTickets);\n\n\t\t\treturn { ...initialState, tickets };\n\t\t},\n\t\t[convertPriceToTpcModifier, defaultTickets, getTicketPrices]\n\t);\n};\n\nexport default useInitialState;\n","export default function _arrayWithHoles(arr) {\n if (Array.isArray(arr)) return arr;\n}","export default function _nonIterableRest() {\n throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}","import superPropBase from \"@babel/runtime/helpers/esm/superPropBase\";\nexport default function _get(target, property, receiver) {\n if (typeof Reflect !== \"undefined\" && Reflect.get) {\n _get = Reflect.get;\n } else {\n _get = function _get(target, property, receiver) {\n var base = superPropBase(target, property);\n if (!base) return;\n var desc = Object.getOwnPropertyDescriptor(base, property);\n\n if (desc.get) {\n return desc.get.call(receiver);\n }\n\n return desc.value;\n };\n }\n\n return _get(target, property, receiver || target);\n}","import getPrototypeOf from \"@babel/runtime/helpers/esm/getPrototypeOf\";\nexport default function _superPropBase(object, property) {\n while (!Object.prototype.hasOwnProperty.call(object, property)) {\n object = getPrototypeOf(object);\n if (object === null) break;\n }\n\n return object;\n}","(function() { module.exports = window[\"eventespresso\"][\"plugins\"]; }());","import { createContext } from 'react';\n\nimport { DataStateManager, useDataStateManager } from '../data';\n\nconst DataStateContext = createContext(null);\n\nconst { Provider, Consumer: DataStateConsumer } = DataStateContext;\n\nconst DataStateProvider: React.FC = ({ children }) => {\n\tconst data = useDataStateManager();\n\n\treturn {children};\n};\n\nexport { DataStateContext, DataStateProvider, DataStateConsumer };\n","import { DataStateProvider } from './DataStateProvider';\n\nexport const ContextProvider: React.FC = ({ children }) => {\n\treturn {children};\n};\n","import type { AnyObject } from '@eventespresso/utils';\nimport { ContextProvider } from './ContextProvider';\n\nconst withContext =

(Component: React.ComponentType

): React.FC

=> {\n\tconst WrappedComponent: React.FC

= (props) => {\n\t\treturn (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t);\n\t};\n\n\treturn WrappedComponent;\n};\n\nexport default withContext;\n","(function() { module.exports = window[\"ReactDOM\"]; }());","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n/**\n * Use invariant() to assert state which your program assumes to be true.\n *\n * Provide sprintf-style format (only %s is supported) and arguments\n * to provide information about what broke and what you were\n * expecting.\n *\n * The invariant message will be stripped in production, but the invariant\n * will remain to ensure logic does not differ in production.\n */\n\nvar invariant = function(condition, format, a, b, c, d, e, f) {\n if (process.env.NODE_ENV !== 'production') {\n if (format === undefined) {\n throw new Error('invariant requires an error message argument');\n }\n }\n\n if (!condition) {\n var error;\n if (format === undefined) {\n error = new Error(\n 'Minified exception occurred; use the non-minified dev environment ' +\n 'for the full error message and additional helpful warnings.'\n );\n } else {\n var args = [a, b, c, d, e, f];\n var argIndex = 0;\n error = new Error(\n format.replace(/%s/g, function() { return args[argIndex++]; })\n );\n error.name = 'Invariant Violation';\n }\n\n error.framesToPop = 1; // we don't care about invariant's own frame\n throw error;\n }\n};\n\nmodule.exports = invariant;\n","/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * The base implementation of `_.has` without support for deep paths.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {Array|string} key The key to check.\n * @returns {boolean} Returns `true` if `key` exists, else `false`.\n */\nfunction baseHas(object, key) {\n return object != null && hasOwnProperty.call(object, key);\n}\n\nmodule.exports = baseHas;\n","var Symbol = require('./_Symbol');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar nativeObjectToString = objectProto.toString;\n\n/** Built-in value references. */\nvar symToStringTag = Symbol ? Symbol.toStringTag : undefined;\n\n/**\n * A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the raw `toStringTag`.\n */\nfunction getRawTag(value) {\n var isOwn = hasOwnProperty.call(value, symToStringTag),\n tag = value[symToStringTag];\n\n try {\n value[symToStringTag] = undefined;\n var unmasked = true;\n } catch (e) {}\n\n var result = nativeObjectToString.call(value);\n if (unmasked) {\n if (isOwn) {\n value[symToStringTag] = tag;\n } else {\n delete value[symToStringTag];\n }\n }\n return result;\n}\n\nmodule.exports = getRawTag;\n","/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar nativeObjectToString = objectProto.toString;\n\n/**\n * Converts `value` to a string using `Object.prototype.toString`.\n *\n * @private\n * @param {*} value The value to convert.\n * @returns {string} Returns the converted string.\n */\nfunction objectToString(value) {\n return nativeObjectToString.call(value);\n}\n\nmodule.exports = objectToString;\n","var memoizeCapped = require('./_memoizeCapped');\n\n/** Used to match property names within property paths. */\nvar rePropName = /[^.[\\]]+|\\[(?:(-?\\d+(?:\\.\\d+)?)|([\"'])((?:(?!\\2)[^\\\\]|\\\\.)*?)\\2)\\]|(?=(?:\\.|\\[\\])(?:\\.|\\[\\]|$))/g;\n\n/** Used to match backslashes in property paths. */\nvar reEscapeChar = /\\\\(\\\\)?/g;\n\n/**\n * Converts `string` to a property path array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the property path array.\n */\nvar stringToPath = memoizeCapped(function(string) {\n var result = [];\n if (string.charCodeAt(0) === 46 /* . */) {\n result.push('');\n }\n string.replace(rePropName, function(match, number, quote, subString) {\n result.push(quote ? subString.replace(reEscapeChar, '$1') : (number || match));\n });\n return result;\n});\n\nmodule.exports = stringToPath;\n","var memoize = require('./memoize');\n\n/** Used as the maximum memoize cache size. */\nvar MAX_MEMOIZE_SIZE = 500;\n\n/**\n * A specialized version of `_.memoize` which clears the memoized function's\n * cache when it exceeds `MAX_MEMOIZE_SIZE`.\n *\n * @private\n * @param {Function} func The function to have its output memoized.\n * @returns {Function} Returns the new memoized function.\n */\nfunction memoizeCapped(func) {\n var result = memoize(func, function(key) {\n if (cache.size === MAX_MEMOIZE_SIZE) {\n cache.clear();\n }\n return key;\n });\n\n var cache = result.cache;\n return result;\n}\n\nmodule.exports = memoizeCapped;\n","var MapCache = require('./_MapCache');\n\n/** Error message constants. */\nvar FUNC_ERROR_TEXT = 'Expected a function';\n\n/**\n * Creates a function that memoizes the result of `func`. If `resolver` is\n * provided, it determines the cache key for storing the result based on the\n * arguments provided to the memoized function. By default, the first argument\n * provided to the memoized function is used as the map cache key. The `func`\n * is invoked with the `this` binding of the memoized function.\n *\n * **Note:** The cache is exposed as the `cache` property on the memoized\n * function. Its creation may be customized by replacing the `_.memoize.Cache`\n * constructor with one whose instances implement the\n * [`Map`](http://ecma-international.org/ecma-262/7.0/#sec-properties-of-the-map-prototype-object)\n * method interface of `clear`, `delete`, `get`, `has`, and `set`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Function\n * @param {Function} func The function to have its output memoized.\n * @param {Function} [resolver] The function to resolve the cache key.\n * @returns {Function} Returns the new memoized function.\n * @example\n *\n * var object = { 'a': 1, 'b': 2 };\n * var other = { 'c': 3, 'd': 4 };\n *\n * var values = _.memoize(_.values);\n * values(object);\n * // => [1, 2]\n *\n * values(other);\n * // => [3, 4]\n *\n * object.a = 2;\n * values(object);\n * // => [1, 2]\n *\n * // Modify the result cache.\n * values.cache.set(object, ['a', 'b']);\n * values(object);\n * // => ['a', 'b']\n *\n * // Replace `_.memoize.Cache`.\n * _.memoize.Cache = WeakMap;\n */\nfunction memoize(func, resolver) {\n if (typeof func != 'function' || (resolver != null && typeof resolver != 'function')) {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n var memoized = function() {\n var args = arguments,\n key = resolver ? resolver.apply(this, args) : args[0],\n cache = memoized.cache;\n\n if (cache.has(key)) {\n return cache.get(key);\n }\n var result = func.apply(this, args);\n memoized.cache = cache.set(key, result) || cache;\n return result;\n };\n memoized.cache = new (memoize.Cache || MapCache);\n return memoized;\n}\n\n// Expose `MapCache`.\nmemoize.Cache = MapCache;\n\nmodule.exports = memoize;\n","var Hash = require('./_Hash'),\n ListCache = require('./_ListCache'),\n Map = require('./_Map');\n\n/**\n * Removes all key-value entries from the map.\n *\n * @private\n * @name clear\n * @memberOf MapCache\n */\nfunction mapCacheClear() {\n this.size = 0;\n this.__data__ = {\n 'hash': new Hash,\n 'map': new (Map || ListCache),\n 'string': new Hash\n };\n}\n\nmodule.exports = mapCacheClear;\n","(function() { module.exports = window[\"eventespresso\"][\"eeComponents\"]; }());","var hashClear = require('./_hashClear'),\n hashDelete = require('./_hashDelete'),\n hashGet = require('./_hashGet'),\n hashHas = require('./_hashHas'),\n hashSet = require('./_hashSet');\n\n/**\n * Creates a hash object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction Hash(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `Hash`.\nHash.prototype.clear = hashClear;\nHash.prototype['delete'] = hashDelete;\nHash.prototype.get = hashGet;\nHash.prototype.has = hashHas;\nHash.prototype.set = hashSet;\n\nmodule.exports = Hash;\n","var nativeCreate = require('./_nativeCreate');\n\n/**\n * Removes all key-value entries from the hash.\n *\n * @private\n * @name clear\n * @memberOf Hash\n */\nfunction hashClear() {\n this.__data__ = nativeCreate ? nativeCreate(null) : {};\n this.size = 0;\n}\n\nmodule.exports = hashClear;\n","var isFunction = require('./isFunction'),\n isMasked = require('./_isMasked'),\n isObject = require('./isObject'),\n toSource = require('./_toSource');\n\n/**\n * Used to match `RegExp`\n * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns).\n */\nvar reRegExpChar = /[\\\\^$.*+?()[\\]{}|]/g;\n\n/** Used to detect host constructors (Safari). */\nvar reIsHostCtor = /^\\[object .+?Constructor\\]$/;\n\n/** Used for built-in method references. */\nvar funcProto = Function.prototype,\n objectProto = Object.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Used to detect if a method is native. */\nvar reIsNative = RegExp('^' +\n funcToString.call(hasOwnProperty).replace(reRegExpChar, '\\\\$&')\n .replace(/hasOwnProperty|(function).*?(?=\\\\\\()| for .+?(?=\\\\\\])/g, '$1.*?') + '$'\n);\n\n/**\n * The base implementation of `_.isNative` without bad shim checks.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a native function,\n * else `false`.\n */\nfunction baseIsNative(value) {\n if (!isObject(value) || isMasked(value)) {\n return false;\n }\n var pattern = isFunction(value) ? reIsNative : reIsHostCtor;\n return pattern.test(toSource(value));\n}\n\nmodule.exports = baseIsNative;\n","var coreJsData = require('./_coreJsData');\n\n/** Used to detect methods masquerading as native. */\nvar maskSrcKey = (function() {\n var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || '');\n return uid ? ('Symbol(src)_1.' + uid) : '';\n}());\n\n/**\n * Checks if `func` has its source masked.\n *\n * @private\n * @param {Function} func The function to check.\n * @returns {boolean} Returns `true` if `func` is masked, else `false`.\n */\nfunction isMasked(func) {\n return !!maskSrcKey && (maskSrcKey in func);\n}\n\nmodule.exports = isMasked;\n","var root = require('./_root');\n\n/** Used to detect overreaching core-js shims. */\nvar coreJsData = root['__core-js_shared__'];\n\nmodule.exports = coreJsData;\n","/**\n * Gets the value at `key` of `object`.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {string} key The key of the property to get.\n * @returns {*} Returns the property value.\n */\nfunction getValue(object, key) {\n return object == null ? undefined : object[key];\n}\n\nmodule.exports = getValue;\n","/**\n * Removes `key` and its value from the hash.\n *\n * @private\n * @name delete\n * @memberOf Hash\n * @param {Object} hash The hash to modify.\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction hashDelete(key) {\n var result = this.has(key) && delete this.__data__[key];\n this.size -= result ? 1 : 0;\n return result;\n}\n\nmodule.exports = hashDelete;\n","var nativeCreate = require('./_nativeCreate');\n\n/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Gets the hash value for `key`.\n *\n * @private\n * @name get\n * @memberOf Hash\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction hashGet(key) {\n var data = this.__data__;\n if (nativeCreate) {\n var result = data[key];\n return result === HASH_UNDEFINED ? undefined : result;\n }\n return hasOwnProperty.call(data, key) ? data[key] : undefined;\n}\n\nmodule.exports = hashGet;\n","var nativeCreate = require('./_nativeCreate');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Checks if a hash value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Hash\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction hashHas(key) {\n var data = this.__data__;\n return nativeCreate ? (data[key] !== undefined) : hasOwnProperty.call(data, key);\n}\n\nmodule.exports = hashHas;\n","var nativeCreate = require('./_nativeCreate');\n\n/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/**\n * Sets the hash `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Hash\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the hash instance.\n */\nfunction hashSet(key, value) {\n var data = this.__data__;\n this.size += this.has(key) ? 0 : 1;\n data[key] = (nativeCreate && value === undefined) ? HASH_UNDEFINED : value;\n return this;\n}\n\nmodule.exports = hashSet;\n","/**\n * Removes all key-value entries from the list cache.\n *\n * @private\n * @name clear\n * @memberOf ListCache\n */\nfunction listCacheClear() {\n this.__data__ = [];\n this.size = 0;\n}\n\nmodule.exports = listCacheClear;\n","var assocIndexOf = require('./_assocIndexOf');\n\n/** Used for built-in method references. */\nvar arrayProto = Array.prototype;\n\n/** Built-in value references. */\nvar splice = arrayProto.splice;\n\n/**\n * Removes `key` and its value from the list cache.\n *\n * @private\n * @name delete\n * @memberOf ListCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction listCacheDelete(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n return false;\n }\n var lastIndex = data.length - 1;\n if (index == lastIndex) {\n data.pop();\n } else {\n splice.call(data, index, 1);\n }\n --this.size;\n return true;\n}\n\nmodule.exports = listCacheDelete;\n","var assocIndexOf = require('./_assocIndexOf');\n\n/**\n * Gets the list cache value for `key`.\n *\n * @private\n * @name get\n * @memberOf ListCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction listCacheGet(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n return index < 0 ? undefined : data[index][1];\n}\n\nmodule.exports = listCacheGet;\n","var assocIndexOf = require('./_assocIndexOf');\n\n/**\n * Checks if a list cache value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf ListCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction listCacheHas(key) {\n return assocIndexOf(this.__data__, key) > -1;\n}\n\nmodule.exports = listCacheHas;\n","var assocIndexOf = require('./_assocIndexOf');\n\n/**\n * Sets the list cache `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf ListCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the list cache instance.\n */\nfunction listCacheSet(key, value) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n ++this.size;\n data.push([key, value]);\n } else {\n data[index][1] = value;\n }\n return this;\n}\n\nmodule.exports = listCacheSet;\n","var getMapData = require('./_getMapData');\n\n/**\n * Removes `key` and its value from the map.\n *\n * @private\n * @name delete\n * @memberOf MapCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction mapCacheDelete(key) {\n var result = getMapData(this, key)['delete'](key);\n this.size -= result ? 1 : 0;\n return result;\n}\n\nmodule.exports = mapCacheDelete;\n","/**\n * Checks if `value` is suitable for use as unique object key.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is suitable, else `false`.\n */\nfunction isKeyable(value) {\n var type = typeof value;\n return (type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean')\n ? (value !== '__proto__')\n : (value === null);\n}\n\nmodule.exports = isKeyable;\n","var getMapData = require('./_getMapData');\n\n/**\n * Gets the map value for `key`.\n *\n * @private\n * @name get\n * @memberOf MapCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction mapCacheGet(key) {\n return getMapData(this, key).get(key);\n}\n\nmodule.exports = mapCacheGet;\n","var getMapData = require('./_getMapData');\n\n/**\n * Checks if a map value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf MapCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction mapCacheHas(key) {\n return getMapData(this, key).has(key);\n}\n\nmodule.exports = mapCacheHas;\n","var getMapData = require('./_getMapData');\n\n/**\n * Sets the map `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf MapCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the map cache instance.\n */\nfunction mapCacheSet(key, value) {\n var data = getMapData(this, key),\n size = data.size;\n\n data.set(key, value);\n this.size += data.size == size ? 0 : 1;\n return this;\n}\n\nmodule.exports = mapCacheSet;\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","var Symbol = require('./_Symbol'),\n arrayMap = require('./_arrayMap'),\n isArray = require('./isArray'),\n isSymbol = require('./isSymbol');\n\n/** Used as references for various `Number` constants. */\nvar INFINITY = 1 / 0;\n\n/** Used to convert symbols to primitives and strings. */\nvar symbolProto = Symbol ? Symbol.prototype : undefined,\n symbolToString = symbolProto ? symbolProto.toString : undefined;\n\n/**\n * The base implementation of `_.toString` which doesn't convert nullish\n * values to empty strings.\n *\n * @private\n * @param {*} value The value to process.\n * @returns {string} Returns the string.\n */\nfunction baseToString(value) {\n // Exit early for strings to avoid a performance hit in some environments.\n if (typeof value == 'string') {\n return value;\n }\n if (isArray(value)) {\n // Recursively convert values (susceptible to call stack limits).\n return arrayMap(value, baseToString) + '';\n }\n if (isSymbol(value)) {\n return symbolToString ? symbolToString.call(value) : '';\n }\n var result = (value + '');\n return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;\n}\n\nmodule.exports = baseToString;\n","/**\n * A specialized version of `_.map` for arrays without support for iteratee\n * shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns the new mapped array.\n */\nfunction arrayMap(array, iteratee) {\n var index = -1,\n length = array == null ? 0 : array.length,\n result = Array(length);\n\n while (++index < length) {\n result[index] = iteratee(array[index], index, array);\n }\n return result;\n}\n\nmodule.exports = arrayMap;\n","var baseGetTag = require('./_baseGetTag'),\n isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]';\n\n/**\n * The base implementation of `_.isArguments`.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\n */\nfunction baseIsArguments(value) {\n return isObjectLike(value) && baseGetTag(value) == argsTag;\n}\n\nmodule.exports = baseIsArguments;\n","var getNative = require('./_getNative');\n\nvar defineProperty = (function() {\n try {\n var func = getNative(Object, 'defineProperty');\n func({}, '', {});\n return func;\n } catch (e) {}\n}());\n\nmodule.exports = defineProperty;\n","var createBaseFor = require('./_createBaseFor');\n\n/**\n * The base implementation of `baseForOwn` which iterates over `object`\n * properties returned by `keysFunc` and invokes `iteratee` for each property.\n * Iteratee functions may exit iteration early by explicitly returning `false`.\n *\n * @private\n * @param {Object} object The object to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @param {Function} keysFunc The function to get the keys of `object`.\n * @returns {Object} Returns `object`.\n */\nvar baseFor = createBaseFor();\n\nmodule.exports = baseFor;\n","/**\n * Creates a base function for methods like `_.forIn` and `_.forOwn`.\n *\n * @private\n * @param {boolean} [fromRight] Specify iterating from right to left.\n * @returns {Function} Returns the new base function.\n */\nfunction createBaseFor(fromRight) {\n return function(object, iteratee, keysFunc) {\n var index = -1,\n iterable = Object(object),\n props = keysFunc(object),\n length = props.length;\n\n while (length--) {\n var key = props[fromRight ? length : ++index];\n if (iteratee(iterable[key], key, iterable) === false) {\n break;\n }\n }\n return object;\n };\n}\n\nmodule.exports = createBaseFor;\n","var baseTimes = require('./_baseTimes'),\n isArguments = require('./isArguments'),\n isArray = require('./isArray'),\n isBuffer = require('./isBuffer'),\n isIndex = require('./_isIndex'),\n isTypedArray = require('./isTypedArray');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Creates an array of the enumerable property names of the array-like `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @param {boolean} inherited Specify returning inherited property names.\n * @returns {Array} Returns the array of property names.\n */\nfunction arrayLikeKeys(value, inherited) {\n var isArr = isArray(value),\n isArg = !isArr && isArguments(value),\n isBuff = !isArr && !isArg && isBuffer(value),\n isType = !isArr && !isArg && !isBuff && isTypedArray(value),\n skipIndexes = isArr || isArg || isBuff || isType,\n result = skipIndexes ? baseTimes(value.length, String) : [],\n length = result.length;\n\n for (var key in value) {\n if ((inherited || hasOwnProperty.call(value, key)) &&\n !(skipIndexes && (\n // Safari 9 has enumerable `arguments.length` in strict mode.\n key == 'length' ||\n // Node.js 0.10 has enumerable non-index properties on buffers.\n (isBuff && (key == 'offset' || key == 'parent')) ||\n // PhantomJS 2 has enumerable non-index properties on typed arrays.\n (isType && (key == 'buffer' || key == 'byteLength' || key == 'byteOffset')) ||\n // Skip index properties.\n isIndex(key, length)\n ))) {\n result.push(key);\n }\n }\n return result;\n}\n\nmodule.exports = arrayLikeKeys;\n","/**\n * The base implementation of `_.times` without support for iteratee shorthands\n * or max array length checks.\n *\n * @private\n * @param {number} n The number of times to invoke `iteratee`.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns the array of results.\n */\nfunction baseTimes(n, iteratee) {\n var index = -1,\n result = Array(n);\n\n while (++index < n) {\n result[index] = iteratee(index);\n }\n return result;\n}\n\nmodule.exports = baseTimes;\n","/**\n * This method returns `false`.\n *\n * @static\n * @memberOf _\n * @since 4.13.0\n * @category Util\n * @returns {boolean} Returns `false`.\n * @example\n *\n * _.times(2, _.stubFalse);\n * // => [false, false]\n */\nfunction stubFalse() {\n return false;\n}\n\nmodule.exports = stubFalse;\n","var baseGetTag = require('./_baseGetTag'),\n isLength = require('./isLength'),\n isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]',\n arrayTag = '[object Array]',\n boolTag = '[object Boolean]',\n dateTag = '[object Date]',\n errorTag = '[object Error]',\n funcTag = '[object Function]',\n mapTag = '[object Map]',\n numberTag = '[object Number]',\n objectTag = '[object Object]',\n regexpTag = '[object RegExp]',\n setTag = '[object Set]',\n stringTag = '[object String]',\n weakMapTag = '[object WeakMap]';\n\nvar arrayBufferTag = '[object ArrayBuffer]',\n dataViewTag = '[object DataView]',\n float32Tag = '[object Float32Array]',\n float64Tag = '[object Float64Array]',\n int8Tag = '[object Int8Array]',\n int16Tag = '[object Int16Array]',\n int32Tag = '[object Int32Array]',\n uint8Tag = '[object Uint8Array]',\n uint8ClampedTag = '[object Uint8ClampedArray]',\n uint16Tag = '[object Uint16Array]',\n uint32Tag = '[object Uint32Array]';\n\n/** Used to identify `toStringTag` values of typed arrays. */\nvar typedArrayTags = {};\ntypedArrayTags[float32Tag] = typedArrayTags[float64Tag] =\ntypedArrayTags[int8Tag] = typedArrayTags[int16Tag] =\ntypedArrayTags[int32Tag] = typedArrayTags[uint8Tag] =\ntypedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] =\ntypedArrayTags[uint32Tag] = true;\ntypedArrayTags[argsTag] = typedArrayTags[arrayTag] =\ntypedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] =\ntypedArrayTags[dataViewTag] = typedArrayTags[dateTag] =\ntypedArrayTags[errorTag] = typedArrayTags[funcTag] =\ntypedArrayTags[mapTag] = typedArrayTags[numberTag] =\ntypedArrayTags[objectTag] = typedArrayTags[regexpTag] =\ntypedArrayTags[setTag] = typedArrayTags[stringTag] =\ntypedArrayTags[weakMapTag] = false;\n\n/**\n * The base implementation of `_.isTypedArray` without Node.js optimizations.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n */\nfunction baseIsTypedArray(value) {\n return isObjectLike(value) &&\n isLength(value.length) && !!typedArrayTags[baseGetTag(value)];\n}\n\nmodule.exports = baseIsTypedArray;\n","/**\n * The base implementation of `_.unary` without support for storing metadata.\n *\n * @private\n * @param {Function} func The function to cap arguments for.\n * @returns {Function} Returns the new capped function.\n */\nfunction baseUnary(func) {\n return function(value) {\n return func(value);\n };\n}\n\nmodule.exports = baseUnary;\n","var freeGlobal = require('./_freeGlobal');\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Detect free variable `process` from Node.js. */\nvar freeProcess = moduleExports && freeGlobal.process;\n\n/** Used to access faster Node.js helpers. */\nvar nodeUtil = (function() {\n try {\n // Use `util.types` for Node.js 10+.\n var types = freeModule && freeModule.require && freeModule.require('util').types;\n\n if (types) {\n return types;\n }\n\n // Legacy `process.binding('util')` for Node.js < 10.\n return freeProcess && freeProcess.binding && freeProcess.binding('util');\n } catch (e) {}\n}());\n\nmodule.exports = nodeUtil;\n","var isPrototype = require('./_isPrototype'),\n nativeKeys = require('./_nativeKeys');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * The base implementation of `_.keys` which doesn't treat sparse arrays as dense.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n */\nfunction baseKeys(object) {\n if (!isPrototype(object)) {\n return nativeKeys(object);\n }\n var result = [];\n for (var key in Object(object)) {\n if (hasOwnProperty.call(object, key) && key != 'constructor') {\n result.push(key);\n }\n }\n return result;\n}\n\nmodule.exports = baseKeys;\n","/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Checks if `value` is likely a prototype object.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a prototype, else `false`.\n */\nfunction isPrototype(value) {\n var Ctor = value && value.constructor,\n proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto;\n\n return value === proto;\n}\n\nmodule.exports = isPrototype;\n","var overArg = require('./_overArg');\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeKeys = overArg(Object.keys, Object);\n\nmodule.exports = nativeKeys;\n","/**\n * Creates a unary function that invokes `func` with its argument transformed.\n *\n * @private\n * @param {Function} func The function to wrap.\n * @param {Function} transform The argument transform.\n * @returns {Function} Returns the new function.\n */\nfunction overArg(func, transform) {\n return function(arg) {\n return func(transform(arg));\n };\n}\n\nmodule.exports = overArg;\n","var isFunction = require('./isFunction'),\n isLength = require('./isLength');\n\n/**\n * Checks if `value` is array-like. A value is considered array-like if it's\n * not a function and has a `value.length` that's an integer greater than or\n * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is array-like, else `false`.\n * @example\n *\n * _.isArrayLike([1, 2, 3]);\n * // => true\n *\n * _.isArrayLike(document.body.children);\n * // => true\n *\n * _.isArrayLike('abc');\n * // => true\n *\n * _.isArrayLike(_.noop);\n * // => false\n */\nfunction isArrayLike(value) {\n return value != null && isLength(value.length) && !isFunction(value);\n}\n\nmodule.exports = isArrayLike;\n","var baseIsMatch = require('./_baseIsMatch'),\n getMatchData = require('./_getMatchData'),\n matchesStrictComparable = require('./_matchesStrictComparable');\n\n/**\n * The base implementation of `_.matches` which doesn't clone `source`.\n *\n * @private\n * @param {Object} source The object of property values to match.\n * @returns {Function} Returns the new spec function.\n */\nfunction baseMatches(source) {\n var matchData = getMatchData(source);\n if (matchData.length == 1 && matchData[0][2]) {\n return matchesStrictComparable(matchData[0][0], matchData[0][1]);\n }\n return function(object) {\n return object === source || baseIsMatch(object, source, matchData);\n };\n}\n\nmodule.exports = baseMatches;\n","var Stack = require('./_Stack'),\n baseIsEqual = require('./_baseIsEqual');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/**\n * The base implementation of `_.isMatch` without support for iteratee shorthands.\n *\n * @private\n * @param {Object} object The object to inspect.\n * @param {Object} source The object of property values to match.\n * @param {Array} matchData The property names, values, and compare flags to match.\n * @param {Function} [customizer] The function to customize comparisons.\n * @returns {boolean} Returns `true` if `object` is a match, else `false`.\n */\nfunction baseIsMatch(object, source, matchData, customizer) {\n var index = matchData.length,\n length = index,\n noCustomizer = !customizer;\n\n if (object == null) {\n return !length;\n }\n object = Object(object);\n while (index--) {\n var data = matchData[index];\n if ((noCustomizer && data[2])\n ? data[1] !== object[data[0]]\n : !(data[0] in object)\n ) {\n return false;\n }\n }\n while (++index < length) {\n data = matchData[index];\n var key = data[0],\n objValue = object[key],\n srcValue = data[1];\n\n if (noCustomizer && data[2]) {\n if (objValue === undefined && !(key in object)) {\n return false;\n }\n } else {\n var stack = new Stack;\n if (customizer) {\n var result = customizer(objValue, srcValue, key, object, source, stack);\n }\n if (!(result === undefined\n ? baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG, customizer, stack)\n : result\n )) {\n return false;\n }\n }\n }\n return true;\n}\n\nmodule.exports = baseIsMatch;\n","var ListCache = require('./_ListCache');\n\n/**\n * Removes all key-value entries from the stack.\n *\n * @private\n * @name clear\n * @memberOf Stack\n */\nfunction stackClear() {\n this.__data__ = new ListCache;\n this.size = 0;\n}\n\nmodule.exports = stackClear;\n","export default function _iterableToArray(iter) {\n if (typeof Symbol !== \"undefined\" && Symbol.iterator in Object(iter)) return Array.from(iter);\n}","/**\n * Removes `key` and its value from the stack.\n *\n * @private\n * @name delete\n * @memberOf Stack\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction stackDelete(key) {\n var data = this.__data__,\n result = data['delete'](key);\n\n this.size = data.size;\n return result;\n}\n\nmodule.exports = stackDelete;\n","/**\n * Gets the stack value for `key`.\n *\n * @private\n * @name get\n * @memberOf Stack\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction stackGet(key) {\n return this.__data__.get(key);\n}\n\nmodule.exports = stackGet;\n","/**\n * Checks if a stack value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Stack\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction stackHas(key) {\n return this.__data__.has(key);\n}\n\nmodule.exports = stackHas;\n","var ListCache = require('./_ListCache'),\n Map = require('./_Map'),\n MapCache = require('./_MapCache');\n\n/** Used as the size to enable large array optimizations. */\nvar LARGE_ARRAY_SIZE = 200;\n\n/**\n * Sets the stack `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Stack\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the stack cache instance.\n */\nfunction stackSet(key, value) {\n var data = this.__data__;\n if (data instanceof ListCache) {\n var pairs = data.__data__;\n if (!Map || (pairs.length < LARGE_ARRAY_SIZE - 1)) {\n pairs.push([key, value]);\n this.size = ++data.size;\n return this;\n }\n data = this.__data__ = new MapCache(pairs);\n }\n data.set(key, value);\n this.size = data.size;\n return this;\n}\n\nmodule.exports = stackSet;\n","var Stack = require('./_Stack'),\n equalArrays = require('./_equalArrays'),\n equalByTag = require('./_equalByTag'),\n equalObjects = require('./_equalObjects'),\n getTag = require('./_getTag'),\n isArray = require('./isArray'),\n isBuffer = require('./isBuffer'),\n isTypedArray = require('./isTypedArray');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1;\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]',\n arrayTag = '[object Array]',\n objectTag = '[object Object]';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * A specialized version of `baseIsEqual` for arrays and objects which performs\n * deep comparisons and tracks traversed objects enabling objects with circular\n * references to be compared.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} [stack] Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction baseIsEqualDeep(object, other, bitmask, customizer, equalFunc, stack) {\n var objIsArr = isArray(object),\n othIsArr = isArray(other),\n objTag = objIsArr ? arrayTag : getTag(object),\n othTag = othIsArr ? arrayTag : getTag(other);\n\n objTag = objTag == argsTag ? objectTag : objTag;\n othTag = othTag == argsTag ? objectTag : othTag;\n\n var objIsObj = objTag == objectTag,\n othIsObj = othTag == objectTag,\n isSameTag = objTag == othTag;\n\n if (isSameTag && isBuffer(object)) {\n if (!isBuffer(other)) {\n return false;\n }\n objIsArr = true;\n objIsObj = false;\n }\n if (isSameTag && !objIsObj) {\n stack || (stack = new Stack);\n return (objIsArr || isTypedArray(object))\n ? equalArrays(object, other, bitmask, customizer, equalFunc, stack)\n : equalByTag(object, other, objTag, bitmask, customizer, equalFunc, stack);\n }\n if (!(bitmask & COMPARE_PARTIAL_FLAG)) {\n var objIsWrapped = objIsObj && hasOwnProperty.call(object, '__wrapped__'),\n othIsWrapped = othIsObj && hasOwnProperty.call(other, '__wrapped__');\n\n if (objIsWrapped || othIsWrapped) {\n var objUnwrapped = objIsWrapped ? object.value() : object,\n othUnwrapped = othIsWrapped ? other.value() : other;\n\n stack || (stack = new Stack);\n return equalFunc(objUnwrapped, othUnwrapped, bitmask, customizer, stack);\n }\n }\n if (!isSameTag) {\n return false;\n }\n stack || (stack = new Stack);\n return equalObjects(object, other, bitmask, customizer, equalFunc, stack);\n}\n\nmodule.exports = baseIsEqualDeep;\n","var MapCache = require('./_MapCache'),\n setCacheAdd = require('./_setCacheAdd'),\n setCacheHas = require('./_setCacheHas');\n\n/**\n *\n * Creates an array cache object to store unique values.\n *\n * @private\n * @constructor\n * @param {Array} [values] The values to cache.\n */\nfunction SetCache(values) {\n var index = -1,\n length = values == null ? 0 : values.length;\n\n this.__data__ = new MapCache;\n while (++index < length) {\n this.add(values[index]);\n }\n}\n\n// Add methods to `SetCache`.\nSetCache.prototype.add = SetCache.prototype.push = setCacheAdd;\nSetCache.prototype.has = setCacheHas;\n\nmodule.exports = SetCache;\n","/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/**\n * Adds `value` to the array cache.\n *\n * @private\n * @name add\n * @memberOf SetCache\n * @alias push\n * @param {*} value The value to cache.\n * @returns {Object} Returns the cache instance.\n */\nfunction setCacheAdd(value) {\n this.__data__.set(value, HASH_UNDEFINED);\n return this;\n}\n\nmodule.exports = setCacheAdd;\n","/**\n * Checks if `value` is in the array cache.\n *\n * @private\n * @name has\n * @memberOf SetCache\n * @param {*} value The value to search for.\n * @returns {number} Returns `true` if `value` is found, else `false`.\n */\nfunction setCacheHas(value) {\n return this.__data__.has(value);\n}\n\nmodule.exports = setCacheHas;\n","/**\n * A specialized version of `_.some` for arrays without support for iteratee\n * shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {boolean} Returns `true` if any element passes the predicate check,\n * else `false`.\n */\nfunction arraySome(array, predicate) {\n var index = -1,\n length = array == null ? 0 : array.length;\n\n while (++index < length) {\n if (predicate(array[index], index, array)) {\n return true;\n }\n }\n return false;\n}\n\nmodule.exports = arraySome;\n","/**\n * Checks if a `cache` value for `key` exists.\n *\n * @private\n * @param {Object} cache The cache to query.\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction cacheHas(cache, key) {\n return cache.has(key);\n}\n\nmodule.exports = cacheHas;\n","var Symbol = require('./_Symbol'),\n Uint8Array = require('./_Uint8Array'),\n eq = require('./eq'),\n equalArrays = require('./_equalArrays'),\n mapToArray = require('./_mapToArray'),\n setToArray = require('./_setToArray');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/** `Object#toString` result references. */\nvar boolTag = '[object Boolean]',\n dateTag = '[object Date]',\n errorTag = '[object Error]',\n mapTag = '[object Map]',\n numberTag = '[object Number]',\n regexpTag = '[object RegExp]',\n setTag = '[object Set]',\n stringTag = '[object String]',\n symbolTag = '[object Symbol]';\n\nvar arrayBufferTag = '[object ArrayBuffer]',\n dataViewTag = '[object DataView]';\n\n/** Used to convert symbols to primitives and strings. */\nvar symbolProto = Symbol ? Symbol.prototype : undefined,\n symbolValueOf = symbolProto ? symbolProto.valueOf : undefined;\n\n/**\n * A specialized version of `baseIsEqualDeep` for comparing objects of\n * the same `toStringTag`.\n *\n * **Note:** This function only supports comparing values with tags of\n * `Boolean`, `Date`, `Error`, `Number`, `RegExp`, or `String`.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {string} tag The `toStringTag` of the objects to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction equalByTag(object, other, tag, bitmask, customizer, equalFunc, stack) {\n switch (tag) {\n case dataViewTag:\n if ((object.byteLength != other.byteLength) ||\n (object.byteOffset != other.byteOffset)) {\n return false;\n }\n object = object.buffer;\n other = other.buffer;\n\n case arrayBufferTag:\n if ((object.byteLength != other.byteLength) ||\n !equalFunc(new Uint8Array(object), new Uint8Array(other))) {\n return false;\n }\n return true;\n\n case boolTag:\n case dateTag:\n case numberTag:\n // Coerce booleans to `1` or `0` and dates to milliseconds.\n // Invalid dates are coerced to `NaN`.\n return eq(+object, +other);\n\n case errorTag:\n return object.name == other.name && object.message == other.message;\n\n case regexpTag:\n case stringTag:\n // Coerce regexes to strings and treat strings, primitives and objects,\n // as equal. See http://www.ecma-international.org/ecma-262/7.0/#sec-regexp.prototype.tostring\n // for more details.\n return object == (other + '');\n\n case mapTag:\n var convert = mapToArray;\n\n case setTag:\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG;\n convert || (convert = setToArray);\n\n if (object.size != other.size && !isPartial) {\n return false;\n }\n // Assume cyclic values are equal.\n var stacked = stack.get(object);\n if (stacked) {\n return stacked == other;\n }\n bitmask |= COMPARE_UNORDERED_FLAG;\n\n // Recursively compare objects (susceptible to call stack limits).\n stack.set(object, other);\n var result = equalArrays(convert(object), convert(other), bitmask, customizer, equalFunc, stack);\n stack['delete'](object);\n return result;\n\n case symbolTag:\n if (symbolValueOf) {\n return symbolValueOf.call(object) == symbolValueOf.call(other);\n }\n }\n return false;\n}\n\nmodule.exports = equalByTag;\n","var root = require('./_root');\n\n/** Built-in value references. */\nvar Uint8Array = root.Uint8Array;\n\nmodule.exports = Uint8Array;\n","/**\n * Converts `map` to its key-value pairs.\n *\n * @private\n * @param {Object} map The map to convert.\n * @returns {Array} Returns the key-value pairs.\n */\nfunction mapToArray(map) {\n var index = -1,\n result = Array(map.size);\n\n map.forEach(function(value, key) {\n result[++index] = [key, value];\n });\n return result;\n}\n\nmodule.exports = mapToArray;\n","/**\n * Converts `set` to an array of its values.\n *\n * @private\n * @param {Object} set The set to convert.\n * @returns {Array} Returns the values.\n */\nfunction setToArray(set) {\n var index = -1,\n result = Array(set.size);\n\n set.forEach(function(value) {\n result[++index] = value;\n });\n return result;\n}\n\nmodule.exports = setToArray;\n","var getAllKeys = require('./_getAllKeys');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1;\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * A specialized version of `baseIsEqualDeep` for objects with support for\n * partial deep comparisons.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction equalObjects(object, other, bitmask, customizer, equalFunc, stack) {\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG,\n objProps = getAllKeys(object),\n objLength = objProps.length,\n othProps = getAllKeys(other),\n othLength = othProps.length;\n\n if (objLength != othLength && !isPartial) {\n return false;\n }\n var index = objLength;\n while (index--) {\n var key = objProps[index];\n if (!(isPartial ? key in other : hasOwnProperty.call(other, key))) {\n return false;\n }\n }\n // Check that cyclic values are equal.\n var objStacked = stack.get(object);\n var othStacked = stack.get(other);\n if (objStacked && othStacked) {\n return objStacked == other && othStacked == object;\n }\n var result = true;\n stack.set(object, other);\n stack.set(other, object);\n\n var skipCtor = isPartial;\n while (++index < objLength) {\n key = objProps[index];\n var objValue = object[key],\n othValue = other[key];\n\n if (customizer) {\n var compared = isPartial\n ? customizer(othValue, objValue, key, other, object, stack)\n : customizer(objValue, othValue, key, object, other, stack);\n }\n // Recursively compare objects (susceptible to call stack limits).\n if (!(compared === undefined\n ? (objValue === othValue || equalFunc(objValue, othValue, bitmask, customizer, stack))\n : compared\n )) {\n result = false;\n break;\n }\n skipCtor || (skipCtor = key == 'constructor');\n }\n if (result && !skipCtor) {\n var objCtor = object.constructor,\n othCtor = other.constructor;\n\n // Non `Object` object instances with different constructors are not equal.\n if (objCtor != othCtor &&\n ('constructor' in object && 'constructor' in other) &&\n !(typeof objCtor == 'function' && objCtor instanceof objCtor &&\n typeof othCtor == 'function' && othCtor instanceof othCtor)) {\n result = false;\n }\n }\n stack['delete'](object);\n stack['delete'](other);\n return result;\n}\n\nmodule.exports = equalObjects;\n","var baseGetAllKeys = require('./_baseGetAllKeys'),\n getSymbols = require('./_getSymbols'),\n keys = require('./keys');\n\n/**\n * Creates an array of own enumerable property names and symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names and symbols.\n */\nfunction getAllKeys(object) {\n return baseGetAllKeys(object, keys, getSymbols);\n}\n\nmodule.exports = getAllKeys;\n","var arrayPush = require('./_arrayPush'),\n isArray = require('./isArray');\n\n/**\n * The base implementation of `getAllKeys` and `getAllKeysIn` which uses\n * `keysFunc` and `symbolsFunc` to get the enumerable property names and\n * symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Function} keysFunc The function to get the keys of `object`.\n * @param {Function} symbolsFunc The function to get the symbols of `object`.\n * @returns {Array} Returns the array of property names and symbols.\n */\nfunction baseGetAllKeys(object, keysFunc, symbolsFunc) {\n var result = keysFunc(object);\n return isArray(object) ? result : arrayPush(result, symbolsFunc(object));\n}\n\nmodule.exports = baseGetAllKeys;\n","/**\n * Appends the elements of `values` to `array`.\n *\n * @private\n * @param {Array} array The array to modify.\n * @param {Array} values The values to append.\n * @returns {Array} Returns `array`.\n */\nfunction arrayPush(array, values) {\n var index = -1,\n length = values.length,\n offset = array.length;\n\n while (++index < length) {\n array[offset + index] = values[index];\n }\n return array;\n}\n\nmodule.exports = arrayPush;\n","var arrayFilter = require('./_arrayFilter'),\n stubArray = require('./stubArray');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Built-in value references. */\nvar propertyIsEnumerable = objectProto.propertyIsEnumerable;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeGetSymbols = Object.getOwnPropertySymbols;\n\n/**\n * Creates an array of the own enumerable symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of symbols.\n */\nvar getSymbols = !nativeGetSymbols ? stubArray : function(object) {\n if (object == null) {\n return [];\n }\n object = Object(object);\n return arrayFilter(nativeGetSymbols(object), function(symbol) {\n return propertyIsEnumerable.call(object, symbol);\n });\n};\n\nmodule.exports = getSymbols;\n","/**\n * A specialized version of `_.filter` for arrays without support for\n * iteratee shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {Array} Returns the new filtered array.\n */\nfunction arrayFilter(array, predicate) {\n var index = -1,\n length = array == null ? 0 : array.length,\n resIndex = 0,\n result = [];\n\n while (++index < length) {\n var value = array[index];\n if (predicate(value, index, array)) {\n result[resIndex++] = value;\n }\n }\n return result;\n}\n\nmodule.exports = arrayFilter;\n","/**\n * This method returns a new empty array.\n *\n * @static\n * @memberOf _\n * @since 4.13.0\n * @category Util\n * @returns {Array} Returns the new empty array.\n * @example\n *\n * var arrays = _.times(2, _.stubArray);\n *\n * console.log(arrays);\n * // => [[], []]\n *\n * console.log(arrays[0] === arrays[1]);\n * // => false\n */\nfunction stubArray() {\n return [];\n}\n\nmodule.exports = stubArray;\n","var DataView = require('./_DataView'),\n Map = require('./_Map'),\n Promise = require('./_Promise'),\n Set = require('./_Set'),\n WeakMap = require('./_WeakMap'),\n baseGetTag = require('./_baseGetTag'),\n toSource = require('./_toSource');\n\n/** `Object#toString` result references. */\nvar mapTag = '[object Map]',\n objectTag = '[object Object]',\n promiseTag = '[object Promise]',\n setTag = '[object Set]',\n weakMapTag = '[object WeakMap]';\n\nvar dataViewTag = '[object DataView]';\n\n/** Used to detect maps, sets, and weakmaps. */\nvar dataViewCtorString = toSource(DataView),\n mapCtorString = toSource(Map),\n promiseCtorString = toSource(Promise),\n setCtorString = toSource(Set),\n weakMapCtorString = toSource(WeakMap);\n\n/**\n * Gets the `toStringTag` of `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\nvar getTag = baseGetTag;\n\n// Fallback for data views, maps, sets, and weak maps in IE 11 and promises in Node.js < 6.\nif ((DataView && getTag(new DataView(new ArrayBuffer(1))) != dataViewTag) ||\n (Map && getTag(new Map) != mapTag) ||\n (Promise && getTag(Promise.resolve()) != promiseTag) ||\n (Set && getTag(new Set) != setTag) ||\n (WeakMap && getTag(new WeakMap) != weakMapTag)) {\n getTag = function(value) {\n var result = baseGetTag(value),\n Ctor = result == objectTag ? value.constructor : undefined,\n ctorString = Ctor ? toSource(Ctor) : '';\n\n if (ctorString) {\n switch (ctorString) {\n case dataViewCtorString: return dataViewTag;\n case mapCtorString: return mapTag;\n case promiseCtorString: return promiseTag;\n case setCtorString: return setTag;\n case weakMapCtorString: return weakMapTag;\n }\n }\n return result;\n };\n}\n\nmodule.exports = getTag;\n","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar DataView = getNative(root, 'DataView');\n\nmodule.exports = DataView;\n","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar Promise = getNative(root, 'Promise');\n\nmodule.exports = Promise;\n","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar Set = getNative(root, 'Set');\n\nmodule.exports = Set;\n","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar WeakMap = getNative(root, 'WeakMap');\n\nmodule.exports = WeakMap;\n","var isStrictComparable = require('./_isStrictComparable'),\n keys = require('./keys');\n\n/**\n * Gets the property names, values, and compare flags of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the match data of `object`.\n */\nfunction getMatchData(object) {\n var result = keys(object),\n length = result.length;\n\n while (length--) {\n var key = result[length],\n value = object[key];\n\n result[length] = [key, value, isStrictComparable(value)];\n }\n return result;\n}\n\nmodule.exports = getMatchData;\n","var baseIsEqual = require('./_baseIsEqual'),\n get = require('./get'),\n hasIn = require('./hasIn'),\n isKey = require('./_isKey'),\n isStrictComparable = require('./_isStrictComparable'),\n matchesStrictComparable = require('./_matchesStrictComparable'),\n toKey = require('./_toKey');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/**\n * The base implementation of `_.matchesProperty` which doesn't clone `srcValue`.\n *\n * @private\n * @param {string} path The path of the property to get.\n * @param {*} srcValue The value to match.\n * @returns {Function} Returns the new spec function.\n */\nfunction baseMatchesProperty(path, srcValue) {\n if (isKey(path) && isStrictComparable(srcValue)) {\n return matchesStrictComparable(toKey(path), srcValue);\n }\n return function(object) {\n var objValue = get(object, path);\n return (objValue === undefined && objValue === srcValue)\n ? hasIn(object, path)\n : baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG);\n };\n}\n\nmodule.exports = baseMatchesProperty;\n","var baseGet = require('./_baseGet');\n\n/**\n * Gets the value at `path` of `object`. If the resolved value is\n * `undefined`, the `defaultValue` is returned in its place.\n *\n * @static\n * @memberOf _\n * @since 3.7.0\n * @category Object\n * @param {Object} object The object to query.\n * @param {Array|string} path The path of the property to get.\n * @param {*} [defaultValue] The value returned for `undefined` resolved values.\n * @returns {*} Returns the resolved value.\n * @example\n *\n * var object = { 'a': [{ 'b': { 'c': 3 } }] };\n *\n * _.get(object, 'a[0].b.c');\n * // => 3\n *\n * _.get(object, ['a', '0', 'b', 'c']);\n * // => 3\n *\n * _.get(object, 'a.b.c', 'default');\n * // => 'default'\n */\nfunction get(object, path, defaultValue) {\n var result = object == null ? undefined : baseGet(object, path);\n return result === undefined ? defaultValue : result;\n}\n\nmodule.exports = get;\n","var baseHasIn = require('./_baseHasIn'),\n hasPath = require('./_hasPath');\n\n/**\n * Checks if `path` is a direct or inherited property of `object`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Object\n * @param {Object} object The object to query.\n * @param {Array|string} path The path to check.\n * @returns {boolean} Returns `true` if `path` exists, else `false`.\n * @example\n *\n * var object = _.create({ 'a': _.create({ 'b': 2 }) });\n *\n * _.hasIn(object, 'a');\n * // => true\n *\n * _.hasIn(object, 'a.b');\n * // => true\n *\n * _.hasIn(object, ['a', 'b']);\n * // => true\n *\n * _.hasIn(object, 'b');\n * // => false\n */\nfunction hasIn(object, path) {\n return object != null && hasPath(object, path, baseHasIn);\n}\n\nmodule.exports = hasIn;\n","/**\n * The base implementation of `_.hasIn` without support for deep paths.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {Array|string} key The key to check.\n * @returns {boolean} Returns `true` if `key` exists, else `false`.\n */\nfunction baseHasIn(object, key) {\n return object != null && key in Object(object);\n}\n\nmodule.exports = baseHasIn;\n","/**\n * This method returns the first argument it receives.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Util\n * @param {*} value Any value.\n * @returns {*} Returns `value`.\n * @example\n *\n * var object = { 'a': 1 };\n *\n * console.log(_.identity(object) === object);\n * // => true\n */\nfunction identity(value) {\n return value;\n}\n\nmodule.exports = identity;\n","var baseProperty = require('./_baseProperty'),\n basePropertyDeep = require('./_basePropertyDeep'),\n isKey = require('./_isKey'),\n toKey = require('./_toKey');\n\n/**\n * Creates a function that returns the value at `path` of a given object.\n *\n * @static\n * @memberOf _\n * @since 2.4.0\n * @category Util\n * @param {Array|string} path The path of the property to get.\n * @returns {Function} Returns the new accessor function.\n * @example\n *\n * var objects = [\n * { 'a': { 'b': 2 } },\n * { 'a': { 'b': 1 } }\n * ];\n *\n * _.map(objects, _.property('a.b'));\n * // => [2, 1]\n *\n * _.map(_.sortBy(objects, _.property(['a', 'b'])), 'a.b');\n * // => [1, 2]\n */\nfunction property(path) {\n return isKey(path) ? baseProperty(toKey(path)) : basePropertyDeep(path);\n}\n\nmodule.exports = property;\n","/**\n * The base implementation of `_.property` without support for deep paths.\n *\n * @private\n * @param {string} key The key of the property to get.\n * @returns {Function} Returns the new accessor function.\n */\nfunction baseProperty(key) {\n return function(object) {\n return object == null ? undefined : object[key];\n };\n}\n\nmodule.exports = baseProperty;\n","var baseGet = require('./_baseGet');\n\n/**\n * A specialized version of `baseProperty` which supports deep paths.\n *\n * @private\n * @param {Array|string} path The path of the property to get.\n * @returns {Function} Returns the new accessor function.\n */\nfunction basePropertyDeep(path) {\n return function(object) {\n return baseGet(object, path);\n };\n}\n\nmodule.exports = basePropertyDeep;\n","/**\n * A specialized version of `_.reduce` for arrays without support for\n * iteratee shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @param {*} [accumulator] The initial value.\n * @param {boolean} [initAccum] Specify using the first element of `array` as\n * the initial value.\n * @returns {*} Returns the accumulated value.\n */\nfunction arrayReduce(array, iteratee, accumulator, initAccum) {\n var index = -1,\n length = array == null ? 0 : array.length;\n\n if (initAccum && length) {\n accumulator = array[++index];\n }\n while (++index < length) {\n accumulator = iteratee(accumulator, array[index], index, array);\n }\n return accumulator;\n}\n\nmodule.exports = arrayReduce;\n","var deburrLetter = require('./_deburrLetter'),\n toString = require('./toString');\n\n/** Used to match Latin Unicode letters (excluding mathematical operators). */\nvar reLatin = /[\\xc0-\\xd6\\xd8-\\xf6\\xf8-\\xff\\u0100-\\u017f]/g;\n\n/** Used to compose unicode character classes. */\nvar rsComboMarksRange = '\\\\u0300-\\\\u036f',\n reComboHalfMarksRange = '\\\\ufe20-\\\\ufe2f',\n rsComboSymbolsRange = '\\\\u20d0-\\\\u20ff',\n rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange;\n\n/** Used to compose unicode capture groups. */\nvar rsCombo = '[' + rsComboRange + ']';\n\n/**\n * Used to match [combining diacritical marks](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks) and\n * [combining diacritical marks for symbols](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks_for_Symbols).\n */\nvar reComboMark = RegExp(rsCombo, 'g');\n\n/**\n * Deburrs `string` by converting\n * [Latin-1 Supplement](https://en.wikipedia.org/wiki/Latin-1_Supplement_(Unicode_block)#Character_table)\n * and [Latin Extended-A](https://en.wikipedia.org/wiki/Latin_Extended-A)\n * letters to basic Latin letters and removing\n * [combining diacritical marks](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks).\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to deburr.\n * @returns {string} Returns the deburred string.\n * @example\n *\n * _.deburr('déjà vu');\n * // => 'deja vu'\n */\nfunction deburr(string) {\n string = toString(string);\n return string && string.replace(reLatin, deburrLetter).replace(reComboMark, '');\n}\n\nmodule.exports = deburr;\n","var basePropertyOf = require('./_basePropertyOf');\n\n/** Used to map Latin Unicode letters to basic Latin letters. */\nvar deburredLetters = {\n // Latin-1 Supplement block.\n '\\xc0': 'A', '\\xc1': 'A', '\\xc2': 'A', '\\xc3': 'A', '\\xc4': 'A', '\\xc5': 'A',\n '\\xe0': 'a', '\\xe1': 'a', '\\xe2': 'a', '\\xe3': 'a', '\\xe4': 'a', '\\xe5': 'a',\n '\\xc7': 'C', '\\xe7': 'c',\n '\\xd0': 'D', '\\xf0': 'd',\n '\\xc8': 'E', '\\xc9': 'E', '\\xca': 'E', '\\xcb': 'E',\n '\\xe8': 'e', '\\xe9': 'e', '\\xea': 'e', '\\xeb': 'e',\n '\\xcc': 'I', '\\xcd': 'I', '\\xce': 'I', '\\xcf': 'I',\n '\\xec': 'i', '\\xed': 'i', '\\xee': 'i', '\\xef': 'i',\n '\\xd1': 'N', '\\xf1': 'n',\n '\\xd2': 'O', '\\xd3': 'O', '\\xd4': 'O', '\\xd5': 'O', '\\xd6': 'O', '\\xd8': 'O',\n '\\xf2': 'o', '\\xf3': 'o', '\\xf4': 'o', '\\xf5': 'o', '\\xf6': 'o', '\\xf8': 'o',\n '\\xd9': 'U', '\\xda': 'U', '\\xdb': 'U', '\\xdc': 'U',\n '\\xf9': 'u', '\\xfa': 'u', '\\xfb': 'u', '\\xfc': 'u',\n '\\xdd': 'Y', '\\xfd': 'y', '\\xff': 'y',\n '\\xc6': 'Ae', '\\xe6': 'ae',\n '\\xde': 'Th', '\\xfe': 'th',\n '\\xdf': 'ss',\n // Latin Extended-A block.\n '\\u0100': 'A', '\\u0102': 'A', '\\u0104': 'A',\n '\\u0101': 'a', '\\u0103': 'a', '\\u0105': 'a',\n '\\u0106': 'C', '\\u0108': 'C', '\\u010a': 'C', '\\u010c': 'C',\n '\\u0107': 'c', '\\u0109': 'c', '\\u010b': 'c', '\\u010d': 'c',\n '\\u010e': 'D', '\\u0110': 'D', '\\u010f': 'd', '\\u0111': 'd',\n '\\u0112': 'E', '\\u0114': 'E', '\\u0116': 'E', '\\u0118': 'E', '\\u011a': 'E',\n '\\u0113': 'e', '\\u0115': 'e', '\\u0117': 'e', '\\u0119': 'e', '\\u011b': 'e',\n '\\u011c': 'G', '\\u011e': 'G', '\\u0120': 'G', '\\u0122': 'G',\n '\\u011d': 'g', '\\u011f': 'g', '\\u0121': 'g', '\\u0123': 'g',\n '\\u0124': 'H', '\\u0126': 'H', '\\u0125': 'h', '\\u0127': 'h',\n '\\u0128': 'I', '\\u012a': 'I', '\\u012c': 'I', '\\u012e': 'I', '\\u0130': 'I',\n '\\u0129': 'i', '\\u012b': 'i', '\\u012d': 'i', '\\u012f': 'i', '\\u0131': 'i',\n '\\u0134': 'J', '\\u0135': 'j',\n '\\u0136': 'K', '\\u0137': 'k', '\\u0138': 'k',\n '\\u0139': 'L', '\\u013b': 'L', '\\u013d': 'L', '\\u013f': 'L', '\\u0141': 'L',\n '\\u013a': 'l', '\\u013c': 'l', '\\u013e': 'l', '\\u0140': 'l', '\\u0142': 'l',\n '\\u0143': 'N', '\\u0145': 'N', '\\u0147': 'N', '\\u014a': 'N',\n '\\u0144': 'n', '\\u0146': 'n', '\\u0148': 'n', '\\u014b': 'n',\n '\\u014c': 'O', '\\u014e': 'O', '\\u0150': 'O',\n '\\u014d': 'o', '\\u014f': 'o', '\\u0151': 'o',\n '\\u0154': 'R', '\\u0156': 'R', '\\u0158': 'R',\n '\\u0155': 'r', '\\u0157': 'r', '\\u0159': 'r',\n '\\u015a': 'S', '\\u015c': 'S', '\\u015e': 'S', '\\u0160': 'S',\n '\\u015b': 's', '\\u015d': 's', '\\u015f': 's', '\\u0161': 's',\n '\\u0162': 'T', '\\u0164': 'T', '\\u0166': 'T',\n '\\u0163': 't', '\\u0165': 't', '\\u0167': 't',\n '\\u0168': 'U', '\\u016a': 'U', '\\u016c': 'U', '\\u016e': 'U', '\\u0170': 'U', '\\u0172': 'U',\n '\\u0169': 'u', '\\u016b': 'u', '\\u016d': 'u', '\\u016f': 'u', '\\u0171': 'u', '\\u0173': 'u',\n '\\u0174': 'W', '\\u0175': 'w',\n '\\u0176': 'Y', '\\u0177': 'y', '\\u0178': 'Y',\n '\\u0179': 'Z', '\\u017b': 'Z', '\\u017d': 'Z',\n '\\u017a': 'z', '\\u017c': 'z', '\\u017e': 'z',\n '\\u0132': 'IJ', '\\u0133': 'ij',\n '\\u0152': 'Oe', '\\u0153': 'oe',\n '\\u0149': \"'n\", '\\u017f': 's'\n};\n\n/**\n * Used by `_.deburr` to convert Latin-1 Supplement and Latin Extended-A\n * letters to basic Latin letters.\n *\n * @private\n * @param {string} letter The matched letter to deburr.\n * @returns {string} Returns the deburred letter.\n */\nvar deburrLetter = basePropertyOf(deburredLetters);\n\nmodule.exports = deburrLetter;\n","/**\n * The base implementation of `_.propertyOf` without support for deep paths.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Function} Returns the new accessor function.\n */\nfunction basePropertyOf(object) {\n return function(key) {\n return object == null ? undefined : object[key];\n };\n}\n\nmodule.exports = basePropertyOf;\n","var asciiWords = require('./_asciiWords'),\n hasUnicodeWord = require('./_hasUnicodeWord'),\n toString = require('./toString'),\n unicodeWords = require('./_unicodeWords');\n\n/**\n * Splits `string` into an array of its words.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to inspect.\n * @param {RegExp|string} [pattern] The pattern to match words.\n * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.\n * @returns {Array} Returns the words of `string`.\n * @example\n *\n * _.words('fred, barney, & pebbles');\n * // => ['fred', 'barney', 'pebbles']\n *\n * _.words('fred, barney, & pebbles', /[^, ]+/g);\n * // => ['fred', 'barney', '&', 'pebbles']\n */\nfunction words(string, pattern, guard) {\n string = toString(string);\n pattern = guard ? undefined : pattern;\n\n if (pattern === undefined) {\n return hasUnicodeWord(string) ? unicodeWords(string) : asciiWords(string);\n }\n return string.match(pattern) || [];\n}\n\nmodule.exports = words;\n","/** Used to match words composed of alphanumeric characters. */\nvar reAsciiWord = /[^\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\x7f]+/g;\n\n/**\n * Splits an ASCII `string` into an array of its words.\n *\n * @private\n * @param {string} The string to inspect.\n * @returns {Array} Returns the words of `string`.\n */\nfunction asciiWords(string) {\n return string.match(reAsciiWord) || [];\n}\n\nmodule.exports = asciiWords;\n","/** Used to detect strings that need a more robust regexp to match words. */\nvar reHasUnicodeWord = /[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;\n\n/**\n * Checks if `string` contains a word composed of Unicode symbols.\n *\n * @private\n * @param {string} string The string to inspect.\n * @returns {boolean} Returns `true` if a word is found, else `false`.\n */\nfunction hasUnicodeWord(string) {\n return reHasUnicodeWord.test(string);\n}\n\nmodule.exports = hasUnicodeWord;\n","/** Used to compose unicode character classes. */\nvar rsAstralRange = '\\\\ud800-\\\\udfff',\n rsComboMarksRange = '\\\\u0300-\\\\u036f',\n reComboHalfMarksRange = '\\\\ufe20-\\\\ufe2f',\n rsComboSymbolsRange = '\\\\u20d0-\\\\u20ff',\n rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange,\n rsDingbatRange = '\\\\u2700-\\\\u27bf',\n rsLowerRange = 'a-z\\\\xdf-\\\\xf6\\\\xf8-\\\\xff',\n rsMathOpRange = '\\\\xac\\\\xb1\\\\xd7\\\\xf7',\n rsNonCharRange = '\\\\x00-\\\\x2f\\\\x3a-\\\\x40\\\\x5b-\\\\x60\\\\x7b-\\\\xbf',\n rsPunctuationRange = '\\\\u2000-\\\\u206f',\n rsSpaceRange = ' \\\\t\\\\x0b\\\\f\\\\xa0\\\\ufeff\\\\n\\\\r\\\\u2028\\\\u2029\\\\u1680\\\\u180e\\\\u2000\\\\u2001\\\\u2002\\\\u2003\\\\u2004\\\\u2005\\\\u2006\\\\u2007\\\\u2008\\\\u2009\\\\u200a\\\\u202f\\\\u205f\\\\u3000',\n rsUpperRange = 'A-Z\\\\xc0-\\\\xd6\\\\xd8-\\\\xde',\n rsVarRange = '\\\\ufe0e\\\\ufe0f',\n rsBreakRange = rsMathOpRange + rsNonCharRange + rsPunctuationRange + rsSpaceRange;\n\n/** Used to compose unicode capture groups. */\nvar rsApos = \"['\\u2019]\",\n rsBreak = '[' + rsBreakRange + ']',\n rsCombo = '[' + rsComboRange + ']',\n rsDigits = '\\\\d+',\n rsDingbat = '[' + rsDingbatRange + ']',\n rsLower = '[' + rsLowerRange + ']',\n rsMisc = '[^' + rsAstralRange + rsBreakRange + rsDigits + rsDingbatRange + rsLowerRange + rsUpperRange + ']',\n rsFitz = '\\\\ud83c[\\\\udffb-\\\\udfff]',\n rsModifier = '(?:' + rsCombo + '|' + rsFitz + ')',\n rsNonAstral = '[^' + rsAstralRange + ']',\n rsRegional = '(?:\\\\ud83c[\\\\udde6-\\\\uddff]){2}',\n rsSurrPair = '[\\\\ud800-\\\\udbff][\\\\udc00-\\\\udfff]',\n rsUpper = '[' + rsUpperRange + ']',\n rsZWJ = '\\\\u200d';\n\n/** Used to compose unicode regexes. */\nvar rsMiscLower = '(?:' + rsLower + '|' + rsMisc + ')',\n rsMiscUpper = '(?:' + rsUpper + '|' + rsMisc + ')',\n rsOptContrLower = '(?:' + rsApos + '(?:d|ll|m|re|s|t|ve))?',\n rsOptContrUpper = '(?:' + rsApos + '(?:D|LL|M|RE|S|T|VE))?',\n reOptMod = rsModifier + '?',\n rsOptVar = '[' + rsVarRange + ']?',\n rsOptJoin = '(?:' + rsZWJ + '(?:' + [rsNonAstral, rsRegional, rsSurrPair].join('|') + ')' + rsOptVar + reOptMod + ')*',\n rsOrdLower = '\\\\d*(?:1st|2nd|3rd|(?![123])\\\\dth)(?=\\\\b|[A-Z_])',\n rsOrdUpper = '\\\\d*(?:1ST|2ND|3RD|(?![123])\\\\dTH)(?=\\\\b|[a-z_])',\n rsSeq = rsOptVar + reOptMod + rsOptJoin,\n rsEmoji = '(?:' + [rsDingbat, rsRegional, rsSurrPair].join('|') + ')' + rsSeq;\n\n/** Used to match complex or compound words. */\nvar reUnicodeWord = RegExp([\n rsUpper + '?' + rsLower + '+' + rsOptContrLower + '(?=' + [rsBreak, rsUpper, '$'].join('|') + ')',\n rsMiscUpper + '+' + rsOptContrUpper + '(?=' + [rsBreak, rsUpper + rsMiscLower, '$'].join('|') + ')',\n rsUpper + '?' + rsMiscLower + '+' + rsOptContrLower,\n rsUpper + '+' + rsOptContrUpper,\n rsOrdUpper,\n rsOrdLower,\n rsDigits,\n rsEmoji\n].join('|'), 'g');\n\n/**\n * Splits a Unicode `string` into an array of its words.\n *\n * @private\n * @param {string} The string to inspect.\n * @returns {Array} Returns the words of `string`.\n */\nfunction unicodeWords(string) {\n return string.match(reUnicodeWord) || [];\n}\n\nmodule.exports = unicodeWords;\n","var toString = require('./toString'),\n upperFirst = require('./upperFirst');\n\n/**\n * Converts the first character of `string` to upper case and the remaining\n * to lower case.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to capitalize.\n * @returns {string} Returns the capitalized string.\n * @example\n *\n * _.capitalize('FRED');\n * // => 'Fred'\n */\nfunction capitalize(string) {\n return upperFirst(toString(string).toLowerCase());\n}\n\nmodule.exports = capitalize;\n","var createCaseFirst = require('./_createCaseFirst');\n\n/**\n * Converts the first character of `string` to upper case.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category String\n * @param {string} [string=''] The string to convert.\n * @returns {string} Returns the converted string.\n * @example\n *\n * _.upperFirst('fred');\n * // => 'Fred'\n *\n * _.upperFirst('FRED');\n * // => 'FRED'\n */\nvar upperFirst = createCaseFirst('toUpperCase');\n\nmodule.exports = upperFirst;\n","var castSlice = require('./_castSlice'),\n hasUnicode = require('./_hasUnicode'),\n stringToArray = require('./_stringToArray'),\n toString = require('./toString');\n\n/**\n * Creates a function like `_.lowerFirst`.\n *\n * @private\n * @param {string} methodName The name of the `String` case method to use.\n * @returns {Function} Returns the new case function.\n */\nfunction createCaseFirst(methodName) {\n return function(string) {\n string = toString(string);\n\n var strSymbols = hasUnicode(string)\n ? stringToArray(string)\n : undefined;\n\n var chr = strSymbols\n ? strSymbols[0]\n : string.charAt(0);\n\n var trailing = strSymbols\n ? castSlice(strSymbols, 1).join('')\n : string.slice(1);\n\n return chr[methodName]() + trailing;\n };\n}\n\nmodule.exports = createCaseFirst;\n","var baseSlice = require('./_baseSlice');\n\n/**\n * Casts `array` to a slice if it's needed.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {number} start The start position.\n * @param {number} [end=array.length] The end position.\n * @returns {Array} Returns the cast slice.\n */\nfunction castSlice(array, start, end) {\n var length = array.length;\n end = end === undefined ? length : end;\n return (!start && end >= length) ? array : baseSlice(array, start, end);\n}\n\nmodule.exports = castSlice;\n","/**\n * The base implementation of `_.slice` without an iteratee call guard.\n *\n * @private\n * @param {Array} array The array to slice.\n * @param {number} [start=0] The start position.\n * @param {number} [end=array.length] The end position.\n * @returns {Array} Returns the slice of `array`.\n */\nfunction baseSlice(array, start, end) {\n var index = -1,\n length = array.length;\n\n if (start < 0) {\n start = -start > length ? 0 : (length + start);\n }\n end = end > length ? length : end;\n if (end < 0) {\n end += length;\n }\n length = start > end ? 0 : ((end - start) >>> 0);\n start >>>= 0;\n\n var result = Array(length);\n while (++index < length) {\n result[index] = array[index + start];\n }\n return result;\n}\n\nmodule.exports = baseSlice;\n","var asciiToArray = require('./_asciiToArray'),\n hasUnicode = require('./_hasUnicode'),\n unicodeToArray = require('./_unicodeToArray');\n\n/**\n * Converts `string` to an array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the converted array.\n */\nfunction stringToArray(string) {\n return hasUnicode(string)\n ? unicodeToArray(string)\n : asciiToArray(string);\n}\n\nmodule.exports = stringToArray;\n","/**\n * Converts an ASCII `string` to an array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the converted array.\n */\nfunction asciiToArray(string) {\n return string.split('');\n}\n\nmodule.exports = asciiToArray;\n","/** Used to compose unicode character classes. */\nvar rsAstralRange = '\\\\ud800-\\\\udfff',\n rsComboMarksRange = '\\\\u0300-\\\\u036f',\n reComboHalfMarksRange = '\\\\ufe20-\\\\ufe2f',\n rsComboSymbolsRange = '\\\\u20d0-\\\\u20ff',\n rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange,\n rsVarRange = '\\\\ufe0e\\\\ufe0f';\n\n/** Used to compose unicode capture groups. */\nvar rsAstral = '[' + rsAstralRange + ']',\n rsCombo = '[' + rsComboRange + ']',\n rsFitz = '\\\\ud83c[\\\\udffb-\\\\udfff]',\n rsModifier = '(?:' + rsCombo + '|' + rsFitz + ')',\n rsNonAstral = '[^' + rsAstralRange + ']',\n rsRegional = '(?:\\\\ud83c[\\\\udde6-\\\\uddff]){2}',\n rsSurrPair = '[\\\\ud800-\\\\udbff][\\\\udc00-\\\\udfff]',\n rsZWJ = '\\\\u200d';\n\n/** Used to compose unicode regexes. */\nvar reOptMod = rsModifier + '?',\n rsOptVar = '[' + rsVarRange + ']?',\n rsOptJoin = '(?:' + rsZWJ + '(?:' + [rsNonAstral, rsRegional, rsSurrPair].join('|') + ')' + rsOptVar + reOptMod + ')*',\n rsSeq = rsOptVar + reOptMod + rsOptJoin,\n rsSymbol = '(?:' + [rsNonAstral + rsCombo + '?', rsCombo, rsRegional, rsSurrPair, rsAstral].join('|') + ')';\n\n/** Used to match [string symbols](https://mathiasbynens.be/notes/javascript-unicode). */\nvar reUnicode = RegExp(rsFitz + '(?=' + rsFitz + ')|' + rsSymbol + rsSeq, 'g');\n\n/**\n * Converts a Unicode `string` to an array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the converted array.\n */\nfunction unicodeToArray(string) {\n return string.match(reUnicode) || [];\n}\n\nmodule.exports = unicodeToArray;\n","/** @license React v17.0.2\n * react-jsx-runtime.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';require(\"object-assign\");var f=require(\"react\"),g=60103;exports.Fragment=60107;if(\"function\"===typeof Symbol&&Symbol.for){var h=Symbol.for;g=h(\"react.element\");exports.Fragment=h(\"react.fragment\")}var m=f.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,n=Object.prototype.hasOwnProperty,p={key:!0,ref:!0,__self:!0,__source:!0};\nfunction q(c,a,k){var b,d={},e=null,l=null;void 0!==k&&(e=\"\"+k);void 0!==a.key&&(e=\"\"+a.key);void 0!==a.ref&&(l=a.ref);for(b in a)n.call(a,b)&&!p.hasOwnProperty(b)&&(d[b]=a[b]);if(c&&c.defaultProps)for(b in a=c.defaultProps,a)void 0===d[b]&&(d[b]=a[b]);return{$$typeof:g,type:c,key:e,ref:l,props:d,_owner:m.current}}exports.jsx=q;exports.jsxs=q;\n","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst SaveOutlined = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(SaveOutlined, 'save-outlined');\n","import objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nexport default function _objectWithoutProperties(source, excluded) {\n if (source == null) return {};\n var target = objectWithoutPropertiesLoose(source, excluded);\n var key, i;\n\n if (Object.getOwnPropertySymbols) {\n var sourceSymbolKeys = Object.getOwnPropertySymbols(source);\n\n for (i = 0; i < sourceSymbolKeys.length; i++) {\n key = sourceSymbolKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;\n target[key] = source[key];\n }\n }\n\n return target;\n}","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n\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\n return target;\n}","import unsupportedIterableToArray from \"@babel/runtime/helpers/esm/unsupportedIterableToArray\";\nexport default function _createForOfIteratorHelper(o, allowArrayLike) {\n var it;\n\n if (typeof Symbol === \"undefined\" || o[Symbol.iterator] == null) {\n if (Array.isArray(o) || (it = unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === \"number\") {\n if (it) o = it;\n var i = 0;\n\n var F = function F() {};\n\n return {\n s: F,\n n: function n() {\n if (i >= o.length) return {\n done: true\n };\n return {\n done: false,\n value: o[i++]\n };\n },\n e: function e(_e) {\n throw _e;\n },\n f: F\n };\n }\n\n throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n }\n\n var normalCompletion = true,\n didErr = false,\n err;\n return {\n s: function s() {\n it = o[Symbol.iterator]();\n },\n n: function n() {\n var step = it.next();\n normalCompletion = step.done;\n return step;\n },\n e: function e(_e2) {\n didErr = true;\n err = _e2;\n },\n f: function f() {\n try {\n if (!normalCompletion && it[\"return\"] != null) it[\"return\"]();\n } finally {\n if (didErr) throw err;\n }\n }\n };\n}","(function() { module.exports = window[\"eventespresso\"][\"form\"]; }());","import { useMemo } from 'react';\n\nimport { EntityActionsSubscription, EntityActionsMenuRegistry } from '@eventespresso/registry';\nimport { domain } from '@eventespresso/edtr-services';\nimport { useMemoStringify } from '@eventespresso/hooks';\nimport type { Entity } from '@eventespresso/data';\n\nconst { getSubscriptions } = new EntityActionsSubscription(domain);\n\nconst useEntityActionsMenuItems = (\n\tentityType: T,\n\tentity: E,\n\tfilterByEntityType = true\n): Array => {\n\tconst registry = useMemo(\n\t\t() => new EntityActionsMenuRegistry({ domain, entityType, entityId: entity.id }),\n\t\t[entity.id, entityType]\n\t);\n\n\tconst { generateElements } = registry;\n\n\tconst subscriptions = getSubscriptions({ entityType: filterByEntityType ? entityType : null });\n\n\tObject.values(subscriptions).forEach(({ callback }) => {\n\t\tcallback({ entityType, entity, registry });\n\t});\n\n\t// it should only change if subscriptions change\n\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\treturn useMemoStringify(generateElements(), Object.keys(subscriptions));\n};\n\nexport default useEntityActionsMenuItems;\n","(function() { module.exports = window[\"eventespresso\"][\"tpc\"]; }());","export default function _assertThisInitialized(self) {\n if (self === void 0) {\n throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\");\n }\n\n return self;\n}","import { useCallback, useMemo, useState } from 'react';\nimport * as R from 'ramda';\n\nimport { useRelationsManager, RelationFunctionProps } from '@eventespresso/services';\n\nimport { AssignmentManager } from '../types';\nimport { TAM_ENTITIES } from '../constants';\n\ntype AM = AssignmentManager;\n\n/**\n * A wrapper for relations manager.\n */\nconst useAssignmentManager = (): AM => {\n\t// Create a fresh instance to manage current relations/assignments\n\t// without modifying/mutating the existing relations\n\tconst {\n\t\taddRelation,\n\t\tgetData,\n\t\tgetRelations,\n\t\tinitialize: initializeRelations,\n\t\tisInitialized,\n\t\tremoveRelation,\n\t} = useRelationsManager();\n\n\tconst [isDirty, setIsDirty] = useState(false);\n\n\tconst getAssignedTickets = useCallback(\n\t\t({ datetimeId }) => {\n\t\t\treturn getRelations({\n\t\t\t\tentity: 'datetimes',\n\t\t\t\tentityId: datetimeId,\n\t\t\t\trelation: 'tickets',\n\t\t\t});\n\t\t},\n\t\t[getRelations]\n\t);\n\n\tconst getAssignedDates = useCallback(\n\t\t({ ticketId }) => {\n\t\t\treturn getRelations({\n\t\t\t\tentity: 'tickets',\n\t\t\t\tentityId: ticketId,\n\t\t\t\trelation: 'datetimes',\n\t\t\t});\n\t\t},\n\t\t[getRelations]\n\t);\n\n\t// args are same\n\tconst updateAssignment = useCallback(\n\t\t({ datetimeId, ticketId, remove = false }) => {\n\t\t\t// relation from datetimes towards tickets\n\t\t\tconst datetimeToTickets: RelationFunctionProps<'datetimes'> = {\n\t\t\t\tentity: 'datetimes',\n\t\t\t\tentityId: datetimeId,\n\t\t\t\trelation: 'tickets',\n\t\t\t\trelationId: ticketId,\n\t\t\t};\n\t\t\t// relation from tickets towards datetimes\n\t\t\tconst ticketsToDatetimes: RelationFunctionProps<'tickets'> = {\n\t\t\t\tentity: 'tickets',\n\t\t\t\tentityId: ticketId,\n\t\t\t\trelation: 'datetimes',\n\t\t\t\trelationId: datetimeId,\n\t\t\t};\n\n\t\t\tif (remove) {\n\t\t\t\tremoveRelation(datetimeToTickets);\n\t\t\t\tremoveRelation(ticketsToDatetimes);\n\t\t\t} else {\n\t\t\t\t// Add both ways relation for fast retieval\n\t\t\t\taddRelation(datetimeToTickets);\n\t\t\t\taddRelation(ticketsToDatetimes);\n\t\t\t}\n\n\t\t\tsetIsDirty(true);\n\t\t},\n\t\t[addRelation, removeRelation]\n\t);\n\n\tconst addAssignment = useCallback(\n\t\t({ datetimeId, ticketId }) => {\n\t\t\tupdateAssignment({ datetimeId, ticketId });\n\t\t},\n\t\t[updateAssignment]\n\t);\n\n\t// args are same\n\tconst toggleAssignment = useCallback(\n\t\t({ datetimeId, ticketId }) => {\n\t\t\tconst assignedTickets = getAssignedTickets({ datetimeId });\n\t\t\tconst remove = assignedTickets.includes(ticketId);\n\t\t\tupdateAssignment({ datetimeId, ticketId, remove });\n\t\t},\n\t\t[getAssignedTickets, updateAssignment]\n\t);\n\n\tconst removeAssignment = useCallback(\n\t\t({ datetimeId, ticketId }) => {\n\t\t\tupdateAssignment({ datetimeId, ticketId, remove: true });\n\t\t},\n\t\t[updateAssignment]\n\t);\n\n\t/**\n\t * Removes other relations from the given relational entity\n\t * like ticket to price relations\n\t */\n\tconst removeNonTAMRelations = useCallback(({ assignmentType, entity, entityType, relationalEntity }) => {\n\t\t// by default all entities (dates/tickets) will be used for relations\n\t\t// e.g. TAM for all dates and tickets\n\t\tlet relationalEntityToUse = relationalEntity;\n\n\t\t// But if TAM is only for a single datetime/ticket\n\t\t// limit relations to that datetime/ticket\n\t\tif (\n\t\t\t(assignmentType === 'forDate' && entityType === 'datetimes') ||\n\t\t\t(assignmentType === 'forTicket' && entityType === 'tickets')\n\t\t) {\n\t\t\t// only the realtions for the given single entity\n\t\t\t// for which TAM has been opened\n\t\t\trelationalEntityToUse = R.pick([entity.id], relationalEntity);\n\t\t\t// if it's for a new date or ticket,\n\t\t\t// there will obviously be no entry of it in existing relations\n\t\t\tif (R.isEmpty(relationalEntityToUse)) {\n\t\t\t\tconst newRelationKey = entityType === 'datetimes' ? 'tickets' : 'datetimes';\n\t\t\t\t// initialize to empty relations\n\t\t\t\trelationalEntityToUse[entity.id] = {\n\t\t\t\t\t[newRelationKey]: [],\n\t\t\t\t};\n\t\t\t}\n\t\t}\n\n\t\t// Now loop through all the relational entities\n\t\treturn R.map((relation) => {\n\t\t\t// pick only TAM relations, i.e. filter out tickets to prices relations\n\t\t\treturn R.pick(TAM_ENTITIES, relation);\n\t\t}, relationalEntityToUse);\n\t}, []);\n\n\t/**\n\t * Inilializes the relations for TAM.\n\t */\n\tconst initialize = useCallback(\n\t\t({ data, assignmentType, entity }) => {\n\t\t\t// pick only datetimes and tickets from relational data\n\t\t\tlet newData = R.pick(TAM_ENTITIES, data);\n\n\t\t\t// Remove other relations from newData\n\t\t\tnewData = R.mapObjIndexed((relationalEntity, entityType) => {\n\t\t\t\treturn removeNonTAMRelations({ assignmentType, entity, entityType, relationalEntity });\n\t\t\t}, newData);\n\n\t\t\t// fire up the relations manager\n\t\t\tinitializeRelations(newData);\n\t\t},\n\t\t[initializeRelations, removeNonTAMRelations]\n\t);\n\n\treturn useMemo(\n\t\t() => ({\n\t\t\taddAssignment,\n\t\t\tgetAssignedDates,\n\t\t\tgetAssignedTickets,\n\t\t\tgetData,\n\t\t\tinitialize,\n\t\t\tisDirty,\n\t\t\tisInitialized,\n\t\t\tremoveAssignment,\n\t\t\ttoggleAssignment,\n\t\t}),\n\t\t[\n\t\t\taddAssignment,\n\t\t\tgetAssignedDates,\n\t\t\tgetAssignedTickets,\n\t\t\tgetData,\n\t\t\tinitialize,\n\t\t\tisDirty,\n\t\t\tisInitialized,\n\t\t\tremoveAssignment,\n\t\t\ttoggleAssignment,\n\t\t]\n\t);\n};\n\nexport default useAssignmentManager;\n","import { useContext } from 'react';\nimport invariant from 'invariant';\n\nimport { DataStateManager } from '../types';\nimport { DataStateContext } from '../context';\n\nconst useDataState = (): DataStateManager => {\n\tconst value = useContext(DataStateContext);\n\n\tinvariant(value, 'useDataState must be used inside TAM component');\n\n\treturn value;\n};\n\nexport default useDataState;\n","import { useEffect, useCallback, useMemo, useState } from 'react';\nimport * as R from 'ramda';\n\nimport { EntityId } from '@eventespresso/data';\nimport { useRelations } from '@eventespresso/services';\nimport { useDefaultTicketIds } from '@eventespresso/edtr-services';\n\nimport { useAssignmentManager, useValidation } from './';\nimport { AssignmentStatus, BaseProps, DataStateManager } from '../types';\n\nconst useDataStateManager = (props: BaseProps): DataStateManager => {\n\tconst [initialDataIsValid, setInitialDataIsValid] = useState(false);\n\tconst assignmentManager = useAssignmentManager();\n\t// The existing relations to be used to create initial data\n\t// and to calculate difference between new and old data\n\tconst relations = useRelations();\n\tconst orphanEntities = useValidation(assignmentManager);\n\tconst defaultTicketIds = useDefaultTicketIds();\n\n\tconst { initialize, isInitialized } = assignmentManager;\n\tconst initialized = isInitialized();\n\n\tconst hasNoAssignedDates = useCallback(\n\t\t({ ticketId }) => orphanEntities.tickets.includes(ticketId),\n\t\t[orphanEntities.tickets]\n\t);\n\n\tconst hasNoAssignedTickets = useCallback(\n\t\t({ datetimeId }) => orphanEntities.datetimes.includes(datetimeId),\n\t\t[orphanEntities.datetimes]\n\t);\n\n\tconst hasOrphanEntitiesOfType = useCallback(\n\t\t(entityType: keyof typeof orphanEntities) => {\n\t\t\tif (\n\t\t\t\t// if TAM is for a date, lets not worry about tickets and vice versa\n\t\t\t\t(entityType === 'tickets' && props.assignmentType === 'forDate') ||\n\t\t\t\t(entityType === 'datetimes' && props.assignmentType === 'forTicket')\n\t\t\t) {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t\t// if TAM is for a particular date/ticket, we should worry only about that particular date/ticket\n\t\t\tif (props.assignmentType !== 'forAll') {\n\t\t\t\treturn orphanEntities[entityType]?.includes(props.entity?.id);\n\t\t\t}\n\t\t\treturn orphanEntities[entityType]?.length > 0;\n\t\t},\n\t\t[orphanEntities, props.assignmentType, props.entity?.id]\n\t);\n\n\tconst hasOrphanTickets = useCallback(() => hasOrphanEntitiesOfType('tickets'), [hasOrphanEntitiesOfType]);\n\n\tconst hasOrphanDates = useCallback(() => hasOrphanEntitiesOfType('datetimes'), [hasOrphanEntitiesOfType]);\n\n\tconst hasOrphanEntities = useCallback(\n\t\t() => hasOrphanTickets() || hasOrphanDates(),\n\t\t[hasOrphanDates, hasOrphanTickets]\n\t);\n\n\tconst getOldRelation = useCallback(\n\t\t({ datetimeId }): EntityId[] => {\n\t\t\treturn relations.getRelations({\n\t\t\t\tentity: 'datetimes',\n\t\t\t\tentityId: datetimeId,\n\t\t\t\trelation: 'tickets',\n\t\t\t});\n\t\t},\n\t\t[relations]\n\t);\n\n\tconst getAssignmentStatus = useCallback(\n\t\t({ datetimeId, ticketId }): AssignmentStatus => {\n\t\t\tconst oldRelatedTickets = getOldRelation({ datetimeId });\n\t\t\tconst newRelatedTickets = assignmentManager.getAssignedTickets({ datetimeId });\n\n\t\t\tconst isInOld = oldRelatedTickets.includes(ticketId);\n\t\t\tconst isInNew = newRelatedTickets.includes(ticketId);\n\n\t\t\tswitch (true) {\n\t\t\t\tcase isInOld && isInNew:\n\t\t\t\t\treturn 'OLD';\n\t\t\t\tcase !isInOld && isInNew:\n\t\t\t\t\treturn 'NEW';\n\t\t\t\tcase isInOld && !isInNew:\n\t\t\t\t\treturn 'REMOVED';\n\t\t\t\tcase !isInOld && !isInNew:\n\t\t\t\t\treturn null;\n\t\t\t}\n\t\t},\n\t\t[assignmentManager, getOldRelation]\n\t);\n\n\tuseEffect(() => {\n\t\tif (!initialized) {\n\t\t\tconst data = relations.getData();\n\t\t\t// remove default tickets from TAM relations\n\t\t\tconst newData = { ...data, tickets: R.omit(defaultTicketIds, data.tickets || {}) };\n\t\t\t// initialize with existing data\n\t\t\tinitialize({ data: newData, ...props });\n\t\t\t// now check if there are any orphaned entities in the initial data and save the result\n\t\t\tconst hasOrphans = orphanEntities?.datetimes?.length !== 0 || orphanEntities?.tickets?.length !== 0;\n\t\t\tsetInitialDataIsValid(!hasOrphans);\n\t\t}\n\t}, [defaultTicketIds, initialize, initialized, orphanEntities, props, relations, setInitialDataIsValid]);\n\n\treturn useMemo(\n\t\t() => ({\n\t\t\t...assignmentManager,\n\t\t\tgetAssignmentStatus,\n\t\t\thasNoAssignedDates,\n\t\t\thasNoAssignedTickets,\n\t\t\thasOrphanDates,\n\t\t\thasOrphanEntities,\n\t\t\thasOrphanTickets,\n\t\t\tinitialDataIsValid,\n\t\t}),\n\t\t[\n\t\t\tassignmentManager,\n\t\t\tgetAssignmentStatus,\n\t\t\thasNoAssignedDates,\n\t\t\thasNoAssignedTickets,\n\t\t\thasOrphanDates,\n\t\t\thasOrphanEntities,\n\t\t\thasOrphanTickets,\n\t\t\tinitialDataIsValid,\n\t\t]\n\t);\n};\n\nexport default useDataStateManager;\n","import { useMemo } from 'react';\n\nimport type { Datetime } from '@eventespresso/edtr-services';\nimport { notTrashed, inYearAndMonth } from '@eventespresso/predicates';\nimport { useFilterState } from '../filters';\n\nconst useFilteredDatetimes = (allDates: Array): Array => {\n\tconst { showTrashedDates, datesByMonth } = useFilterState();\n\n\tconst datesInYearAndMonth = inYearAndMonth(datesByMonth);\n\n\t// If the year i.e. datesByMonth[0] is set, then filter\n\tconst datetimes = useMemo(\n\t\t() => (datesByMonth[0] ? datesInYearAndMonth(allDates) : allDates),\n\t\t[allDates, datesByMonth, datesInYearAndMonth]\n\t);\n\n\treturn useMemo(() => {\n\t\treturn showTrashedDates ? datetimes : notTrashed(datetimes);\n\t}, [datetimes, showTrashedDates]);\n};\n\nexport default useFilteredDatetimes;\n","import { useMemo } from 'react';\n\nimport { isExpired, notTrashed } from '@eventespresso/predicates';\nimport type { Ticket } from '@eventespresso/edtr-services';\nimport { useFilterState } from '../filters';\n\nconst useFilteredTickets = (allTickets: Array): Array => {\n\tconst { showExpiredTickets, showTrashedTickets } = useFilterState();\n\n\treturn useMemo(() => {\n\t\tlet tickets = allTickets;\n\t\tif (!showExpiredTickets) {\n\t\t\ttickets = tickets.filter((ticket) => !isExpired(ticket));\n\t\t}\n\n\t\tif (!showTrashedTickets) {\n\t\t\ttickets = notTrashed(tickets);\n\t\t}\n\n\t\treturn tickets;\n\t}, [allTickets, showExpiredTickets, showTrashedTickets]);\n};\n\nexport default useFilteredTickets;\n","import { Datetime, Ticket, useDatetimes, useTickets } from '@eventespresso/edtr-services';\nimport { useMemoStringify } from '@eventespresso/hooks';\n\nimport { DatesAndTickets } from '../types';\nimport { useTAMContext } from '../context';\nimport useFilteredDatetimes from './useFilteredDatetimes';\nimport useFilteredTickets from './useFilteredTickets';\n\nconst useDatesAndTickets = (): DatesAndTickets => {\n\tconst { assignmentType, entity } = useTAMContext();\n\tconst allDates = useDatetimes();\n\tconst allTickets = useTickets();\n\n\tconst filteredDatetimes = useFilteredDatetimes(allDates);\n\tconst filteredTickets = useFilteredTickets(allTickets);\n\n\tlet datetimes: Array, tickets: Array;\n\n\tswitch (assignmentType) {\n\t\tcase 'forAll':\n\t\t\tdatetimes = filteredDatetimes;\n\t\t\ttickets = filteredTickets;\n\t\t\tbreak;\n\t\tcase 'forDate':\n\t\t\tdatetimes = [entity as Datetime];\n\t\t\ttickets = filteredTickets;\n\t\t\tbreak;\n\t\tcase 'forTicket':\n\t\t\tdatetimes = filteredDatetimes;\n\t\t\ttickets = [entity as Ticket];\n\t\t\tbreak;\n\t}\n\n\treturn useMemoStringify({ datetimes, tickets });\n};\n\nexport default useDatesAndTickets;\n","import { useCallback } from 'react';\nimport * as R from 'ramda';\n\nimport { useRelations } from '@eventespresso/services';\nimport { UpdateTicketInput, useDatetimes, useTickets, useBulkEditTickets } from '@eventespresso/edtr-services';\nimport { entityHasGuid } from '@eventespresso/predicates';\nimport { prepareEntitiesForUpdate, ticketsWithNewQuantity } from '../utils';\nimport { TAMRelationalData } from '../types';\n\ntype Callback = (data: TAMRelationalData) => Promise;\n\nconst useOnSubmitAssignments = (): Callback => {\n\tconst { getData: getExistingData } = useRelations();\n\n\tconst allDates = useDatetimes();\n\tconst allTickets = useTickets();\n\n\tconst { updateEntities: bulkEditTickets } = useBulkEditTickets();\n\n\treturn useCallback(\n\t\tasync (data) => {\n\t\t\tconst existingData = getExistingData();\n\n\t\t\tconst ticketsToUpdate = prepareEntitiesForUpdate({\n\t\t\t\tentity: 'tickets',\n\t\t\t\texistingData,\n\t\t\t\tnewData: data,\n\t\t\t\trelation: 'datetimes',\n\t\t\t});\n\n\t\t\tconst ticketsWithChangedQuantity = ticketsWithNewQuantity({\n\t\t\t\tallDates,\n\t\t\t\tallTickets,\n\t\t\t\texistingData,\n\t\t\t\tticketsToUpdate,\n\t\t\t});\n\n\t\t\tconst uniqueInputs = ticketsToUpdate.map(([id, possibleRelation]) => {\n\t\t\t\tconst input = { id, datetimes: possibleRelation?.datetimes };\n\n\t\t\t\tconst quantity = ticketsWithChangedQuantity?.[id];\n\t\t\t\tif (quantity) {\n\t\t\t\t\treturn { ...input, quantity };\n\t\t\t\t}\n\t\t\t\treturn input;\n\t\t\t});\n\t\t\tObject.entries(ticketsWithChangedQuantity).forEach(([id, quantity]) => {\n\t\t\t\t// if it's already in uniqueInputs\n\t\t\t\tif (R.any(entityHasGuid(id), uniqueInputs)) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\tuniqueInputs.push({ id, quantity });\n\t\t\t});\n\t\t\tif (uniqueInputs?.length) {\n\t\t\t\tawait bulkEditTickets({ uniqueInputs });\n\t\t\t}\n\t\t},\n\t\t[allDates, allTickets, bulkEditTickets, getExistingData]\n\t);\n};\n\nexport default useOnSubmitAssignments;\n","import { useState, useEffect } from 'react';\nimport * as R from 'ramda';\n\nimport { AssignmentManager, TAMPossibleRelation, TAMRelationalData, TAMRelationalEntity } from '../types';\n\nconst DEFAULT_VALIDATION_DATA: TAMPossibleRelation = {\n\tdatetimes: [],\n\ttickets: [],\n};\n\nconst useValidation = (assignmentManager: AssignmentManager): TAMPossibleRelation => {\n\tconst [validationData, setValidationData] = useState(DEFAULT_VALIDATION_DATA);\n\tconst TAMData: TAMRelationalData = assignmentManager.getData();\n\n\tuseEffect(() => {\n\t\t// may be the data is not initialized yet\n\t\tif (R.isEmpty(TAMData)) {\n\t\t\treturn;\n\t\t}\n\t\t// loop through TAM data to find entities with no relations\n\t\t// See the data shape, please check the shape of TAMRelationalData\n\t\tconst newTAMData: TAMPossibleRelation = R.mapObjIndexed((relationalEntity, entity) => {\n\t\t\tconst relation: keyof TAMPossibleRelation = entity === 'datetimes' ? 'tickets' : 'datetimes';\n\t\t\tconst emptyRelationalEntities = R.pickBy(\n\t\t\t\t(relations: TAMPossibleRelation) => {\n\t\t\t\t\tconst relatedIds = relations?.[relation] || [];\n\t\t\t\t\treturn relatedIds.length === 0;\n\t\t\t\t},\n\t\t\t\trelationalEntity\n\t\t\t);\n\t\t\treturn Object.keys(emptyRelationalEntities);\n\t\t}, TAMData);\n\t\tsetValidationData(newTAMData);\n\t}, [TAMData]);\n\n\treturn validationData;\n};\n\nexport default useValidation;\n","import arrayWithHoles from \"@babel/runtime/helpers/esm/arrayWithHoles\";\nimport iterableToArrayLimit from \"@babel/runtime/helpers/esm/iterableToArrayLimit\";\nimport unsupportedIterableToArray from \"@babel/runtime/helpers/esm/unsupportedIterableToArray\";\nimport nonIterableRest from \"@babel/runtime/helpers/esm/nonIterableRest\";\nexport default function _slicedToArray(arr, i) {\n return arrayWithHoles(arr) || iterableToArrayLimit(arr, i) || unsupportedIterableToArray(arr, i) || nonIterableRest();\n}","export default function _iterableToArrayLimit(arr, i) {\n if (typeof Symbol === \"undefined\" || !(Symbol.iterator in Object(arr))) return;\n var _arr = [];\n var _n = true;\n var _d = false;\n var _e = undefined;\n\n try {\n for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) {\n _arr.push(_s.value);\n\n if (i && _arr.length === i) break;\n }\n } catch (err) {\n _d = true;\n _e = err;\n } finally {\n try {\n if (!_n && _i[\"return\"] != null) _i[\"return\"]();\n } finally {\n if (_d) throw _e;\n }\n }\n\n return _arr;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n\n return _setPrototypeOf(o, p);\n}"],"sourceRoot":""} \ No newline at end of file diff --git a/assets/static/js/eventEditor.a576dbed.js b/assets/static/js/eventEditor.a576dbed.js new file mode 100644 index 00000000000..86b225e2ee4 --- /dev/null +++ b/assets/static/js/eventEditor.a576dbed.js @@ -0,0 +1,3 @@ +/*! For license information please see eventEditor.a576dbed.js.LICENSE.txt */ +this.eventespresso=this.eventespresso||{},this.eventespresso.eventEditor=function(e){function t(t){for(var n,r,a=t[0],o=t[1],c=0,s=[];c2)return n;if(/:/.test(r[0])?(n.date=null,t=r[0]):(n.date=r[0],t=r[1],o.timeZoneDelimiter.test(n.date)&&(n.date=e.split(o.timeZoneDelimiter)[0],t=e.substr(n.date.length,e.length))),t){var i=o.timezone.exec(t);i?(n.time=t.replace(i[1],""),n.timezone=i[1]):n.time=t}return n}function f(e,t){var n=new RegExp("^(?:(\\d{4}|[+-]\\d{"+(4+t)+"})|(\\d{2}|[+-]\\d{"+(2+t)+"})$)"),r=e.match(n);if(!r)return{year:null};var i=r[1]&&parseInt(r[1]),a=r[2]&&parseInt(r[2]);return{year:null==a?i:100*a,restDateString:e.slice((r[1]||r[2]).length)}}function b(e,t){if(null===t)return null;var n=e.match(c);if(!n)return null;var r=!!n[4],i=p(n[1]),a=p(n[2])-1,o=p(n[3]),s=p(n[4]),u=p(n[5])-1;if(r)return function(e,t,n){return t>=1&&t<=53&&n>=0&&n<=6}(0,s,u)?function(e,t,n){var r=new Date(0);r.setUTCFullYear(e,0,4);var i=r.getUTCDay()||7,a=7*(t-1)+n+1-i;return r.setUTCDate(r.getUTCDate()+a),r}(t,s,u):new Date(NaN);var l=new Date(0);return function(e,t,n){return t>=0&&t<=11&&n>=1&&n<=(O[t]||(m(e)?29:28))}(t,a,o)&&function(e,t){return t>=1&&t<=(m(e)?366:365)}(t,i)?(l.setUTCFullYear(t,a,Math.max(i,o)),l):new Date(NaN)}function p(e){return e?parseInt(e):1}function v(e){var t=e.match(s);if(!t)return null;var n=h(t[1]),r=h(t[2]),i=h(t[3]);return function(e,t,n){if(24===e)return 0===t&&0===n;return n>=0&&n<60&&t>=0&&t<60&&e>=0&&e<25}(n,r,i)?n*a+6e4*r+1e3*i:NaN}function h(e){return e&&parseFloat(e.replace(",","."))||0}function j(e){if("Z"===e)return 0;var t=e.match(u);if(!t)return 0;var n="+"===t[1]?-1:1,r=parseInt(t[2]),i=t[3]&&parseInt(t[3])||0;return function(e,t){return t>=0&&t<=59}(0,i)?n*(r*a+6e4*i):NaN}var O=[31,null,31,30,31,30,31,31,30,31,30,31];function m(e){return e%400===0||e%4===0&&e%100}},115:function(e,t,n){"use strict";function r(e){return(r="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})(e)}n.d(t,"a",(function(){return r}))},116:function(e,t,n){"use strict";function r(){if("undefined"===typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"===typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}n.d(t,"a",(function(){return r}))},12:function(e,t){e.exports=window.eventespresso.predicates},122:function(e,t,n){var r=n(388),i="object"==typeof self&&self&&self.Object===Object&&self,a=r||i||Function("return this")();e.exports=a},1256:function(e,t,n){"use strict";var r=n(0),i=n(63),a=n.n(i),o=n(169);t.a=function(){var e=Object(r.useContext)(o.FilterStateContext);return a()(e,"useFilterState must be used inside TAM component"),e}},1257:function(e,t){},1258:function(e,t,n){"use strict";var r=n(2),i=n(280),a=n(1);t.a=function(e,t){return function(n){return Object(a.jsx)(i.b,Object(r.a)(Object(r.a)({},t),{},{children:Object(a.jsx)(e,Object(r.a)({},n))}))}}},1259:function(e,t,n){"use strict";var r=n(0),i=n(280),a=n(63),o=n.n(a);t.a=function(){var e=Object(r.useContext)(i.a);return o()(e,"useTAMContext must be used inside TAM component"),e}},1260:function(e,t){},1261:function(e,t,n){"use strict";var r=n(0),i=n(63),a=n.n(i),o=n(602);t.a=function(){var e=Object(r.useContext)(o.a);return a()(e,"useDataState must be used inside DataStateProvider"),e}},1262:function(e,t,n){"use strict";var r=n(43),i=n(34),a=n.n(i),o=n(0),c=n(16),s=n(84);t.a=function(e){var t=e.deletedTickets,n=e.tickets,i=Object(s.useMutateTicket)(!0),u=Object(c.useTicketMutator)().deleteEntity;return Object(o.useCallback)(Object(r.a)(a.a.mark((function e(){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Promise.all(Object.values(n).map(i));case 2:if(!t.length){e.next=5;break}return e.next=5,Promise.all(t.map((function(e){return u({id:e,deletePermanently:!0})})));case 5:case"end":return e.stop()}}),e)}))),[u,t,i,n])}},1263:function(e,t){},1290:function(e,t,n){"use strict";var r=n(31),i=n(0),a=n(3),o=n(16),c=n(5),s=n(456),u=n(1),l=function(e){var t=e.datesByMonth,n=e.setDatesByMonth,l=Object(o.useDatetimes)(),d=Object(s.a)(l),f=t.join(":"),b=Object(i.useMemo)((function(){return[{value:"0:0",label:Object(a.__)("All Dates")}].concat(Object(r.a)(d))}),[d]);return Object(u.jsx)(c.SelectWithLabel,{id:"ee-dates-by-month",label:Object(a.__)("dates by month"),onChangeValue:n,options:b,value:f})},d=function(e){var t=e.showExpiredTickets,n=e.setShowExpiredTickets;return Object(u.jsx)(c.SwitchWithLabel,{id:"show-expired-tickets",isChecked:t,label:Object(a.__)("show expired tickets"),onChangeValue:n})},f=function(e){var t=e.showTrashedDates,n=e.setShowTrashedDates;return Object(u.jsx)(c.SwitchWithLabel,{id:"show-trashed-dates",isChecked:t,label:Object(a.__)("show trashed dates"),onChangeValue:n})},b=function(e){var t=e.showTrashedTickets,n=e.setShowTrashedTickets;return Object(u.jsx)(c.SwitchWithLabel,{id:"show-trashed-tickets",isChecked:t,label:Object(a.__)("show trashed tickets"),onChangeValue:n})},p=n(169),v=n(286);t.a=function(){var e=Object(p.useTAMContext)().assignmentType,t=Object(v.useFilterState)(),n=t.datesByMonth,r=t.setDatesByMonth,i=t.setShowExpiredTickets,a=t.setShowTrashedDates,o=t.setShowTrashedTickets,c=t.showExpiredTickets,s=t.showTrashedDates,h=t.showTrashedTickets;return Object(u.jsxs)("div",{className:"ee-ticket-assignments-manager__filter-bar",children:["forDate"!==e&&Object(u.jsxs)(u.Fragment,{children:[Object(u.jsx)(l,{datesByMonth:n,setDatesByMonth:r}),Object(u.jsx)(f,{showTrashedDates:s,setShowTrashedDates:a})]}),"forTicket"!==e&&Object(u.jsxs)(u.Fragment,{children:[Object(u.jsx)(d,{showExpiredTickets:c,setShowExpiredTickets:i}),Object(u.jsx)(b,{showTrashedTickets:h,setShowTrashedTickets:o})]})]})}},132:function(e,t){var n=Array.isArray;e.exports=n},136:function(e,t,n){"use strict";function r(e){this._maxSize=e,this.clear()}r.prototype.clear=function(){this._size=0,this._values=Object.create(null)},r.prototype.get=function(e){return this._values[e]},r.prototype.set=function(e,t){return this._size>=this._maxSize&&this.clear(),e in this._values||this._size++,this._values[e]=t};var i=/[^.^\]^[]+|(?=\[\]|\.\.)/g,a=/^\d+$/,o=/^\d/,c=/[~`!#$%\^&*+=\-\[\]\\';,/{}|\\":<>\?]/g,s=/^\s*(['"]?)(.*?)(\1)\s*$/,u=new r(512),l=new r(512),d=new r(512);function f(e){return u.get(e)||u.set(e,b(e).map((function(e){return e.replace(s,"$2")})))}function b(e){return e.match(i)}function p(e){return"string"===typeof e&&e&&-1!==["'",'"'].indexOf(e.charAt(0))}function v(e){return!p(e)&&(function(e){return e.match(o)&&!e.match(a)}(e)||function(e){return c.test(e)}(e))}e.exports={Cache:r,split:b,normalizePath:f,setter:function(e){var t=f(e);return l.get(e)||l.set(e,(function(e,n){for(var r=0,i=t.length,a=e;r=0||(i[n]=e[n]);return i}function l(e){return"number"===typeof e&&!isNaN(e)}function d(e){return"boolean"===typeof e}function f(e){return"string"===typeof e}function b(e){return"function"===typeof e}function p(e){return f(e)||b(e)?e:null}function v(e){return 0===e||e}var h=!("undefined"===typeof window||!window.document||!window.document.createElement);function j(e){return Object(r.isValidElement)(e)||f(e)||b(e)||l(e)}var O={TOP_LEFT:"top-left",TOP_RIGHT:"top-right",TOP_CENTER:"top-center",BOTTOM_LEFT:"bottom-left",BOTTOM_RIGHT:"bottom-right",BOTTOM_CENTER:"bottom-center"},m={INFO:"info",SUCCESS:"success",WARNING:"warning",ERROR:"error",DEFAULT:"default"};function y(e){var t=e.enter,n=e.exit,a=e.appendPosition,o=void 0!==a&&a,c=e.collapse,s=void 0===c||c,u=e.collapseDuration,l=void 0===u?300:u;return function(e){var a=e.children,c=e.position,u=e.preventExitTransition,d=e.done,f=e.nodeRef,b=e.isIn,p=o?t+"--"+c:t,v=o?n+"--"+c:n,h=Object(r.useRef)(),j=Object(r.useRef)(0);function O(e){if(e.target===f.current){var t=f.current;t.removeEventListener("animationend",O),0===j.current&&(t.className=h.current)}}function m(){var e=f.current;e.removeEventListener("animationend",m),s?function(e,t,n){void 0===n&&(n=300);var r=e.scrollHeight,i=e.style;requestAnimationFrame((function(){i.minHeight="initial",i.height=r+"px",i.transition="all "+n+"ms",requestAnimationFrame((function(){i.height="0",i.padding="0",i.margin="0",setTimeout(t,n)}))}))}(e,d,l):d()}return Object(r.useLayoutEffect)((function(){!function(){var e=f.current;h.current=e.className,e.className+=" "+p,e.addEventListener("animationend",O)}()}),[]),Object(r.useEffect)((function(){b||(u?m():function(){j.current=1;var e=f.current;e.className+=" "+v,e.addEventListener("animationend",m)}())}),[b]),i.a.createElement(i.a.Fragment,null,a)}}var g={list:new Map,emitQueue:new Map,on:function(e,t){return this.list.has(e)||this.list.set(e,[]),this.list.get(e).push(t),this},off:function(e,t){if(t){var n=this.list.get(e).filter((function(e){return e!==t}));return this.list.set(e,n),this}return this.list.delete(e),this},cancelEmit:function(e){var t=this.emitQueue.get(e);return t&&(t.forEach(clearTimeout),this.emitQueue.delete(e)),this},emit:function(e){for(var t=this,n=arguments.length,r=new Array(n>1?n-1:0),i=1;i0?F:I),hideProgressBar:d(y.hideProgressBar)?y.hideProgressBar:E.hideProgressBar,progress:y.progress,role:f(y.role)?y.role:E.role,deleteToast:function(){!function(e){delete h[e];var n=s.length;(c=v(e)?c-1:c-O.displayedToast)<0&&(c=0);if(n>0){var r=v(e)?1:O.props.limit;if(1===n||1===r)O.displayedToast++,w();else{var i=r>n?n:r;O.displayedToast=i;for(var a=0;a0&&c>E.limit&&S?s.push({toastContent:M,toastProps:N,staleId:m}):l(a)&&a>0?setTimeout((function(){D(M,N,m)}),a):D(M,N,m)}}function D(e,t,n){var r=t.toastId;n&&delete h[n],h[r]={content:e,props:t},a({type:0,toastId:r,staleId:n})}return Object(r.useEffect)((function(){return O.containerId=e.containerId,g.cancelEmit(3).on(0,E).on(1,(function(e){return o.current&&T(e)})).on(5,y).emit(2,O),function(){return g.emit(3,O)}}),[]),Object(r.useEffect)((function(){O.isToastActive=m,O.displayedToast=i.length,g.emit(4,i.length,e.containerId)}),[i]),Object(r.useEffect)((function(){O.props=e})),{getToastToRender:function(t){for(var n={},r=e.newestOnTop?Object.keys(h).reverse():Object.keys(h),i=0;i=1?e.targetTouches[0].clientX:e.clientX}function E(e){return e.targetTouches&&e.targetTouches.length>=1?e.targetTouches[0].clientY:e.clientY}function D(e){var t=Object(r.useState)(!0),n=t[0],i=t[1],a=Object(r.useState)(!1),o=a[0],c=a[1],s=Object(r.useRef)(null),u=_({start:0,x:0,y:0,delta:0,removalDistance:0,canCloseOnClick:!0,canDrag:!1,boundingRect:null}),l=_(e,!0),d=e.autoClose,f=e.pauseOnHover,p=e.closeToast,v=e.onClick,h=e.closeOnClick;function j(t){if(e.draggable){var n=s.current;u.canCloseOnClick=!0,u.canDrag=!0,u.boundingRect=n.getBoundingClientRect(),n.style.transition="",u.x=w(t.nativeEvent),u.y=E(t.nativeEvent),"x"===e.draggableDirection?(u.start=u.x,u.removalDistance=n.offsetWidth*(e.draggablePercent/100)):(u.start=u.y,u.removalDistance=n.offsetHeight*(e.draggablePercent/100))}}function O(){if(u.boundingRect){var t=u.boundingRect,n=t.top,r=t.bottom,i=t.left,a=t.right;e.pauseOnHover&&u.x>=i&&u.x<=a&&u.y>=n&&u.y<=r?y():m()}}function m(){i(!0)}function y(){i(!1)}function g(t){if(u.canDrag){t.preventDefault();var r=s.current;n&&y(),u.x=w(t),u.y=E(t),"x"===e.draggableDirection?u.delta=u.x-u.start:u.delta=u.y-u.start,u.start!==u.x&&(u.canCloseOnClick=!1),r.style.transform="translate"+e.draggableDirection+"("+u.delta+"px)",r.style.opacity=""+(1-Math.abs(u.delta/u.removalDistance))}}function x(){var t=s.current;if(u.canDrag){if(u.canDrag=!1,Math.abs(u.delta)>u.removalDistance)return c(!0),void e.closeToast();t.style.transition="transform 0.2s, opacity 0.2s",t.style.transform="translate"+e.draggableDirection+"(0)",t.style.opacity="1"}}Object(r.useEffect)((function(){return b(e.onOpen)&&e.onOpen(Object(r.isValidElement)(e.children)&&e.children.props),function(){b(l.onClose)&&l.onClose(Object(r.isValidElement)(l.children)&&l.children.props)}}),[]),Object(r.useEffect)((function(){return e.draggable&&(document.addEventListener("mousemove",g),document.addEventListener("mouseup",x),document.addEventListener("touchmove",g),document.addEventListener("touchend",x)),function(){e.draggable&&(document.removeEventListener("mousemove",g),document.removeEventListener("mouseup",x),document.removeEventListener("touchmove",g),document.removeEventListener("touchend",x))}}),[e.draggable]),Object(r.useEffect)((function(){return e.pauseOnFocusLoss&&function(){document.hasFocus()||y();window.addEventListener("focus",m),window.addEventListener("blur",y)}(),function(){e.pauseOnFocusLoss&&(window.removeEventListener("focus",m),window.removeEventListener("blur",y))}}),[e.pauseOnFocusLoss]);var k={onMouseDown:j,onTouchStart:j,onMouseUp:O,onTouchEnd:O};return d&&f&&(k.onMouseEnter=y,k.onMouseLeave=m),h&&(k.onClick=function(e){v&&v(e),u.canCloseOnClick&&p()}),{playToast:m,pauseToast:y,isRunning:n,preventExitTransition:o,toastRef:s,eventHandlers:k}}function C(e){var t=e.closeToast,n=e.theme,i=e.ariaLabel,a=void 0===i?"close":i;return Object(r.createElement)("button",{className:"Toastify__close-button Toastify__close-button--"+n,type:"button",onClick:function(e){e.stopPropagation(),t(e)},"aria-label":a},Object(r.createElement)("svg",{"aria-hidden":"true",viewBox:"0 0 14 16"},Object(r.createElement)("path",{fillRule:"evenodd",d:"M7.71 8.23l3.75 3.75-1.48 1.48-3.75-3.75-3.75 3.75L1 11.98l3.75-3.75L1 4.48 2.48 3l3.75 3.75L9.98 3l1.48 1.48-3.75 3.75z"})))}function S(e){var t,n,i=e.delay,a=e.isRunning,c=e.closeToast,u=e.type,l=e.hide,d=e.className,f=e.style,p=e.controlledProgress,v=e.progress,h=e.rtl,j=e.isIn,O=e.theme,m=s({},f,{animationDuration:i+"ms",animationPlayState:a?"running":"paused",opacity:l?0:1});p&&(m.transform="scaleX("+v+")");var y=o("Toastify__progress-bar",p?"Toastify__progress-bar--controlled":"Toastify__progress-bar--animated","Toastify__progress-bar-theme--"+O,"Toastify__progress-bar--"+u,((t={})["Toastify__progress-bar--rtl"]=h,t)),g=b(d)?d({rtl:h,type:u,defaultClassName:y}):o(y,d),_=((n={})[p&&v>=1?"onTransitionEnd":"onAnimationEnd"]=p&&v<1?null:function(){j&&c()},n);return Object(r.createElement)("div",Object.assign({role:"progressbar","aria-hidden":l?"true":"false","aria-label":"notification timer",className:g,style:m},_))}S.defaultProps={type:m.DEFAULT,hide:!1};var F=["theme","type"],I=function(e){var t=e.theme,n=e.type,r=u(e,F);return i.a.createElement("svg",Object.assign({viewBox:"0 0 24 24",width:"100%",height:"100%",fill:"colored"===t?"currentColor":"var(--toastify-icon-color-"+n+")"},r))};var N={info:function(e){return i.a.createElement(I,Object.assign({},e),i.a.createElement("path",{d:"M12 0a12 12 0 1012 12A12.013 12.013 0 0012 0zm.25 5a1.5 1.5 0 11-1.5 1.5 1.5 1.5 0 011.5-1.5zm2.25 13.5h-4a1 1 0 010-2h.75a.25.25 0 00.25-.25v-4.5a.25.25 0 00-.25-.25h-.75a1 1 0 010-2h1a2 2 0 012 2v4.75a.25.25 0 00.25.25h.75a1 1 0 110 2z"}))},warning:function(e){return i.a.createElement(I,Object.assign({},e),i.a.createElement("path",{d:"M23.32 17.191L15.438 2.184C14.728.833 13.416 0 11.996 0c-1.42 0-2.733.833-3.443 2.184L.533 17.448a4.744 4.744 0 000 4.368C1.243 23.167 2.555 24 3.975 24h16.05C22.22 24 24 22.044 24 19.632c0-.904-.251-1.746-.68-2.44zm-9.622 1.46c0 1.033-.724 1.823-1.698 1.823s-1.698-.79-1.698-1.822v-.043c0-1.028.724-1.822 1.698-1.822s1.698.79 1.698 1.822v.043zm.039-12.285l-.84 8.06c-.057.581-.408.943-.897.943-.49 0-.84-.367-.896-.942l-.84-8.065c-.057-.624.25-1.095.779-1.095h1.91c.528.005.84.476.784 1.1z"}))},success:function(e){return i.a.createElement(I,Object.assign({},e),i.a.createElement("path",{d:"M12 0a12 12 0 1012 12A12.014 12.014 0 0012 0zm6.927 8.2l-6.845 9.289a1.011 1.011 0 01-1.43.188l-4.888-3.908a1 1 0 111.25-1.562l4.076 3.261 6.227-8.451a1 1 0 111.61 1.183z"}))},error:function(e){return i.a.createElement(I,Object.assign({},e),i.a.createElement("path",{d:"M11.983 0a12.206 12.206 0 00-8.51 3.653A11.8 11.8 0 000 12.207 11.779 11.779 0 0011.8 24h.214A12.111 12.111 0 0024 11.791 11.766 11.766 0 0011.983 0zM10.5 16.542a1.476 1.476 0 011.449-1.53h.027a1.527 1.527 0 011.523 1.47 1.475 1.475 0 01-1.449 1.53h-.027a1.529 1.529 0 01-1.523-1.47zM11 12.5v-6a1 1 0 012 0v6a1 1 0 11-2 0z"}))},spinner:function(){return i.a.createElement("div",{className:"Toastify__spinner"})}},A=function(e){var t,n,i=D(e),a=i.isRunning,c=i.preventExitTransition,s=i.toastRef,u=i.eventHandlers,l=e.closeButton,d=e.children,p=e.autoClose,v=e.onClick,h=e.type,j=e.hideProgressBar,O=e.closeToast,m=e.transition,y=e.position,g=e.className,_=e.style,x=e.bodyClassName,k=e.bodyStyle,T=e.progressClassName,w=e.progressStyle,E=e.updateId,C=e.role,F=e.progress,I=e.rtl,A=e.toastId,M=e.deleteToast,P=e.isIn,L=e.isLoading,R=e.icon,z=e.theme,B=o("Toastify__toast","Toastify__toast-theme--"+z,"Toastify__toast--"+h,((t={})["Toastify__toast--rtl"]=I,t)),V=b(g)?g({rtl:I,position:y,type:h,defaultClassName:B}):o(B,g),$=!!F,U=N[h],H={theme:z,type:h},G=U&&U(H);return!1===R?G=void 0:b(R)?G=R(H):Object(r.isValidElement)(R)?G=Object(r.cloneElement)(R,H):f(R)?G=R:L&&(G=N.spinner()),Object(r.createElement)(m,{isIn:P,done:M,position:y,preventExitTransition:c,nodeRef:s},Object(r.createElement)("div",Object.assign({id:A,onClick:v,className:V},u,{style:_,ref:s}),Object(r.createElement)("div",Object.assign({},P&&{role:C},{className:b(x)?x({type:h}):o("Toastify__toast-body",x),style:k}),G&&Object(r.createElement)("div",{className:o("Toastify__toast-icon",(n={},n["Toastify--animate-icon Toastify__zoom-enter"]=!L,n))},G),Object(r.createElement)("div",null,d)),function(e){if(e){var t={closeToast:O,type:h,theme:z};return b(e)?e(t):Object(r.isValidElement)(e)?Object(r.cloneElement)(e,t):void 0}}(l),(p||$)&&Object(r.createElement)(S,Object.assign({},E&&!$?{key:"pb-"+E}:{},{rtl:I,theme:z,delay:p,isRunning:a,isIn:P,closeToast:O,hide:j,type:h,style:w,className:T,controlledProgress:$,progress:F}))))},M=y({enter:"Toastify--animate Toastify__bounce-enter",exit:"Toastify--animate Toastify__bounce-exit",appendPosition:!0}),P=function(e){var t=T(e),n=t.getToastToRender,i=t.containerRef,a=t.isToastActive,c=e.className,u=e.style,l=e.rtl,d=e.containerId;function f(e){var t,n=o("Toastify__toast-container","Toastify__toast-container--"+e,((t={})["Toastify__toast-container--rtl"]=l,t));return b(c)?c({position:e,rtl:l,defaultClassName:n}):o(n,p(c))}return Object(r.createElement)("div",{ref:i,className:"Toastify",id:d},n((function(e,t){var n=0===t.length?s({},u,{pointerEvents:"none"}):s({},u);return Object(r.createElement)("div",{className:f(e),style:n,key:"container-"+e},t.map((function(e){var t=e.content,n=e.props;return Object(r.createElement)(A,Object.assign({},n,{isIn:a(n.toastId),key:"toast-"+n.key,closeButton:!0===n.closeButton?C:n.closeButton}),t)})))})))};P.defaultProps={position:O.TOP_RIGHT,transition:M,rtl:!1,autoClose:5e3,hideProgressBar:!1,closeButton:C,pauseOnHover:!0,pauseOnFocusLoss:!0,closeOnClick:!0,newestOnTop:!1,draggable:!0,draggablePercent:80,draggableDirection:"x",role:"alert",theme:"light"};var L,R,z,B=new Map,V=[],$=!1;function U(){return Math.random().toString(36).substr(2,9)}function H(e){return e&&(f(e.toastId)||l(e.toastId))?e.toastId:U()}function G(e,t){return B.size>0?g.emit(0,e,t):(V.push({content:e,options:t}),$&&h&&($=!1,R=document.createElement("div"),document.body.appendChild(R),Object(c.render)(Object(r.createElement)(P,Object.assign({},z)),R))),t.toastId}function W(e,t){return s({},t,{type:t&&t.type||e,toastId:H(t)})}var q=function(e){return function(t,n){return G(t,W(e,n))}},K=function(e,t){return G(e,W(m.DEFAULT,t))};K.loading=function(e,t){return G(e,W(m.DEFAULT,s({isLoading:!0,autoClose:!1,closeOnClick:!1,closeButton:!1,draggable:!1},t)))},K.promise=function(e,t,n){var r=t.pending,i=t.error,a=t.success,o=f(r)?K.loading(r,n):K.loading(r.render,s({},n,r)),c={isLoading:null,autoClose:null,closeOnClick:null,closeButton:null,draggable:null},u=function(e,t,r){var i=f(t)?{render:t}:t;return K.update(o,s({type:e},c,n,i,{data:r})),r},l=b(e)?e():e;return l.then((function(e){return u("success",a,e)})).catch((function(e){return u("error",i,e)})),l},K.success=q(m.SUCCESS),K.info=q(m.INFO),K.error=q(m.ERROR),K.warning=q(m.WARNING),K.warn=K.warning,K.dark=function(e,t){return G(e,W(m.DEFAULT,s({theme:"dark"},t)))},K.dismiss=function(e){return g.emit(1,e)},K.clearWaitingQueue=function(e){return void 0===e&&(e={}),g.emit(5,e)},K.isActive=function(e){var t=!1;return B.forEach((function(n){n.isToastActive&&n.isToastActive(e)&&(t=!0)})),t},K.update=function(e,t){void 0===t&&(t={}),setTimeout((function(){var n=function(e,t){var n=t.containerId,r=B.get(n||L);return r?r.getToast(e):null}(e,t);if(n){var r=n.props,i=n.content,a=s({},r,t,{toastId:t.toastId||e,updateId:U()});a.toastId!==e&&(a.staleId=e);var o=a.render||i;delete a.render,G(o,a)}}),0)},K.done=function(e){K.update(e,{progress:1})},K.onChange=function(e){return b(e)&&g.on(4,e),function(){b(e)&&g.off(4,e)}},K.configure=function(e){void 0===e&&(e={}),$=!0,z=e},K.POSITION=O,K.TYPE=m,g.on(2,(function(e){L=e.containerId||e,B.set(L,e),V.forEach((function(e){g.emit(0,e.content,e.options)})),V=[]})).on(3,(function(e){B.delete(e.containerId||e),0===B.size&&g.off(0).off(1).off(5),h&&R&&document.body.removeChild(R)}))},14:function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}n.d(t,"a",(function(){return r}))},1410:function(e,t,n){"use strict";var r=n(2),i=n(9),a=n(0),o=n(31),c=n(4),s=n(17),u={deletedTickets:[],tickets:{},isDirty:!1},l=function(e){return Object(a.useCallback)((function(t,n){var i,a,l,d=n.id,f=n.ticket;switch(n.type){case"ADD_TICKET":case"UPDATE_TICKET":i=d||Object(s.uuid)(),l=c.path(["tickets",i],t),a=c.assocPath(["tickets",i],Object(r.a)(Object(r.a)(Object(r.a)({},l),f),{},{id:i,isModified:Boolean(d),isDefault:!0}),t);break;case"DELETE_TICKET":a=Object(r.a)(Object(r.a)({},t),{},{tickets:c.omit([d],t.tickets)});break;case"ADD_TICKET_TO_DELETED":a=t.deletedTickets.includes(d)?t:Object(r.a)(Object(r.a)({},t),{},{deletedTickets:[].concat(Object(o.a)(t.deletedTickets),[d])});break;case"RESET":return e(u);default:throw new Error("Unexpected action")}return Object(r.a)(Object(r.a)({},a),{},{isDirty:!0})}),[e])},d=n(537);t.a=function(){var e=Object(d.a)(),t=l(e),n=Object(a.useReducer)(t,u,e),o=Object(i.a)(n,2),c=o[0],s=o[1],f=Object(a.useCallback)((function(){return c}),[c]),b=Object(a.useCallback)((function(e){s({type:"ADD_TICKET",ticket:e})}),[]),p=Object(a.useCallback)((function(e,t){s({type:"UPDATE_TICKET",id:e,ticket:t})}),[]),v=Object(a.useCallback)((function(e,t){t||s({type:"ADD_TICKET_TO_DELETED",id:e}),s({type:"DELETE_TICKET",id:e})}),[]),h=Object(a.useCallback)((function(){s({type:"RESET"})}),[]);return Object(a.useMemo)((function(){return Object(r.a)(Object(r.a)({},c),{},{addTicket:b,deleteTicket:v,getData:f,updateTicket:p,reset:h})}),[c])}},1411:function(e,t,n){"use strict";var r=n(2),i=n(9),a=n(0),o=function(e,t){var n=t.type,i=t.datesByMonth,a=t.showTrashedDates,o=t.showExpiredTickets,c=t.showTrashedTickets;switch(n){case"SET_DATES_BY_MONTH":return Object(r.a)(Object(r.a)({},e),{},{datesByMonth:i});case"SET_SHOW_TRASHED_DATES":return Object(r.a)(Object(r.a)({},e),{},{showTrashedDates:a});case"SET_SHOW_EXPIRED_TICKETS":return Object(r.a)(Object(r.a)({},e),{},{showExpiredTickets:o});case"SET_SHOW_TRASHED_TICKETS":return Object(r.a)(Object(r.a)({},e),{},{showTrashedTickets:c});default:throw new Error("Unexpected action")}},c={datesByMonth:[0,0],showExpiredTickets:!1,showTrashedDates:!1,showTrashedTickets:!1};t.a=function(){var e=Object(a.useReducer)(o,c),t=Object(i.a)(e,2),n=t[0],s=t[1],u=Object(a.useCallback)((function(e){var t=e.split(":").map(Number),n=Object(i.a)(t,2),r=n[0],a=n[1];s({type:"SET_DATES_BY_MONTH",datesByMonth:[r,a]})}),[]),l=Object(a.useCallback)((function(e){s({type:"SET_SHOW_EXPIRED_TICKETS",showExpiredTickets:e})}),[]),d=Object(a.useCallback)((function(e){s({type:"SET_SHOW_TRASHED_DATES",showTrashedDates:e})}),[]),f=Object(a.useCallback)((function(e){s({type:"SET_SHOW_TRASHED_TICKETS",showTrashedTickets:e})}),[]);return Object(a.useMemo)((function(){return Object(r.a)(Object(r.a)({},n),{},{setDatesByMonth:u,setShowExpiredTickets:l,setShowTrashedDates:d,setShowTrashedTickets:f})}),[n])}},1434:function(e,t){e.exports=window.eventespresso.formBuilder},148:function(e,t,n){var r=n(642),i=n(645);e.exports=function(e,t){var n=i(e,t);return r(n)?n:void 0}},15:function(e,t,n){"use strict";function r(e,t){if(t.length1?"s":"")+" required, but only "+t.length+" present")}n.d(t,"a",(function(){return r}))},151:function(e,t,n){var r=n(633),i=n(386);e.exports=function(e,t){return null!=e&&i(e,t,r)}},1555:function(e,t,n){"use strict";var r=n(2),i=n(22),a=n(1);t.a=Object(i.a)((function(e){return Object(a.jsx)("svg",Object(r.a)(Object(r.a)({viewBox:"64 64 896 896","data-icon":"close",fill:"currentColor","aria-hidden":"true",height:"1.5em",width:"1.5em",className:"ee-svg--close-outlined"},e),{},{children:Object(a.jsx)("path",{d:"M563.8 512l262.5-312.9c4.4-5.2.7-13.1-6.1-13.1h-79.8c-4.7 0-9.2 2.1-12.3 5.7L511.6 449.8 295.1 191.7c-3-3.6-7.5-5.7-12.3-5.7H203c-6.8 0-10.5 7.9-6.1 13.1L459.4 512 196.9 824.9A7.95 7.95 0 00203 838h79.8c4.7 0 9.2-2.1 12.3-5.7l216.5-258.1 216.5 258.1c3 3.6 7.5 5.7 12.3 5.7h79.8c6.8 0 10.5-7.9 6.1-13.1L563.8 512z"})}))}),"close-outlined")},158:function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(r){"object"===typeof window&&(n=window)}e.exports=n},159:function(e,t){},16:function(e,t){e.exports=window.eventespresso.edtrServices},1662:function(e,t,n){"use strict";var r=n(2),i=n(22),a=n(1);t.a=Object(i.a)((function(e){return Object(a.jsx)("svg",Object(r.a)(Object(r.a)({"aria-hidden":"true",height:"1.5em",viewBox:"0 0 20 20",width:"1.5em",xmlns:"http://www.w3.org/2000/svg",className:"ee-svg--link"},e),{},{children:Object(a.jsx)("path",{d:"M17.74 2.76a4.321 4.321 0 010 6.1l-1.53 1.52c-1.12 1.12-2.7 1.47-4.14 1.09l2.62-2.61.76-.77.76-.76c.84-.84.84-2.2 0-3.04a2.13 2.13 0 00-3.04 0l-.77.76-3.38 3.38c-.37-1.44-.02-3.02 1.1-4.14l1.52-1.53a4.321 4.321 0 016.1 0zM8.59 13.43l5.34-5.34c.42-.42.42-1.1 0-1.52-.44-.43-1.13-.39-1.53 0l-5.33 5.34c-.42.42-.42 1.1 0 1.52.44.43 1.13.39 1.52 0zm-.76 2.29l4.14-4.15c.38 1.44.03 3.02-1.09 4.14l-1.52 1.53a4.321 4.321 0 01-6.1 0 4.321 4.321 0 010-6.1l1.53-1.52c1.12-1.12 2.7-1.47 4.14-1.1l-4.14 4.15c-.85.84-.85 2.2 0 3.05.84.84 2.2.84 3.04 0z"})}))}),"link")},1663:function(e,t,n){"use strict";var r=n(2),i=n(22),a=n(1);t.a=Object(i.a)((function(e){return Object(a.jsx)("svg",Object(r.a)(Object(r.a)({"aria-hidden":"true",height:"1.5em",viewBox:"0 0 20 20",width:"1.5em",xmlns:"http://www.w3.org/2000/svg",className:"ee-svg--unlink"},e),{},{children:Object(a.jsx)("path",{d:"M17.74 2.26a4.321 4.321 0 010 6.1l-1.53 1.52c-.32.33-.69.58-1.08.77L13 10l1.69-1.64.76-.77.76-.76c.84-.84.84-2.2 0-3.04a2.13 2.13 0 00-3.04 0l-.77.76-.76.76L10 7l-.65-2.14c.19-.38.44-.75.77-1.07l1.52-1.53a4.321 4.321 0 016.1 0zM2 4l8 6-6-8zm4-2l4 8-2-8H6zM2 6l8 4-8-2V6zm7.36 7.69L10 13l.74 2.35-1.38 1.39a4.321 4.321 0 01-6.1 0 4.321 4.321 0 010-6.1l1.39-1.38L7 10l-.69.64-1.52 1.53c-.85.84-.85 2.2 0 3.04.84.85 2.2.85 3.04 0zM18 16l-8-6 6 8zm-4 2l-4-8 2 8h2zm4-4l-8-4 8 2v2z"})}))}),"unlink")},1674:function(e,t,n){"use strict";var r=n(2),i=n(22),a=n(1);t.a=Object(i.a)((function(e){return Object(a.jsx)("svg",Object(r.a)(Object(r.a)({"aria-hidden":"true",height:"1.5em",viewBox:"-1 -1 22 22",width:"1.5em",xmlns:"http://www.w3.org/2000/svg",className:"ee-svg--calculator"},e),{},{children:Object(a.jsx)("path",{d:"M3 0v20h14V0H3zm2.5 2.5h9v2h-9v-2zm0 4h2v1.75h-2V6.5zm3.5 0h2v1.75H9V6.5zm3.5 0h2v1.75h-2V6.5zm-7 3h2v1.75h-2V9.5zm3.5 0h2v1.75H9V9.5zm3.5 0h2v1.75h-2V9.5zm-7 3h2v1.75h-2V12.5zm3.5 0h2v1.75H9V12.5zm3.5 0h2v1.75h-2V12.5zm-7 3h2v1.75h-2V15.5zm3.5 0h2v1.75H9V15.5zm3.5 0h2v1.75h-2V15.5z"})}))}),"calculator")},1676:function(e,t,n){"use strict";var r=n(2),i=n(22),a=n(1);t.a=Object(i.a)((function(e){return Object(a.jsx)("svg",Object(r.a)(Object(r.a)({"aria-hidden":"true",height:"1.8em",viewBox:"0 1 24 24",width:"1.8em",xmlns:"https://www.w3.org/2000/svg",className:"ee-svg--map-marker"},e),{},{children:Object(a.jsx)("path",{fillRule:"evenodd",d:"M12 2C8.13 2 5 5.13 5 9c0 5.25 7 13 7 13s7-7.75 7-13c0-3.87-3.13-7-7-7zm0 9.5a2.5 2.5 0 010-5 2.5 2.5 0 010 5z"})}))}),"map-marker")},1677:function(e,t,n){"use strict";var r=n(2),i=n(22),a=n(1);t.a=Object(i.a)((function(e){return Object(a.jsx)("svg",Object(r.a)(Object(r.a)({"aria-hidden":"true",height:"1.5em",viewBox:"-2 -1.5 23 23",width:"1.5em",xmlns:"http://www.w3.org/2000/svg",className:"ee-svg--calendar"},e),{},{children:Object(a.jsx)("path",{d:"M0 2v18h20V2zm2 4.5h16V18H2zM15.5 0v8h-1.38l-2.58 2.06.8 1.2.92-.74c.12-.1.32-.28.6-.56l-.04.84v5.7h1.68zm-6 10c0-.6-.24-1.08-.74-1.42-.48-.34-1.16-.52-2-.52-1.04 0-1.92.26-2.66.8l.8 1.2c.34-.22.64-.38.92-.46.28-.1.54-.14.82-.14.76 0 1.16.3 1.16.92 0 .4-.14.7-.44.86s-.76.24-1.4.24h-.62v1.32h.62c.68 0 1.18.08 1.5.24.3.16.46.44.46.82 0 .44-.14.74-.4.94-.28.2-.7.3-1.26.3-.38 0-.76-.06-1.14-.16s-.72-.24-1.04-.4v1.48c.68.3 1.48.44 2.36.44 1.06 0 1.88-.22 2.44-.66.58-.44.86-1.04.86-1.84 0-.54-.18-.96-.52-1.28s-.84-.52-1.48-.6v-.04c.54-.12.98-.38 1.3-.74.3-.36.46-.78.46-1.3zM4 0h2v2H4V0zm10 0h2v2h-2V0z"})}))}),"calendar")},1678:function(e,t,n){"use strict";var r=n(2),i=n(22),a=n(1);t.a=Object(i.a)((function(e){return Object(a.jsx)("svg",Object(r.a)(Object(r.a)({viewBox:"60 80 900 900","data-icon":"calendar",fill:"currentColor","aria-hidden":"true",height:"1.5em",width:"1.5em",className:"ee-svg--calendar-outlined"},e),{},{children:Object(a.jsx)("path",{d:"M880 184H712v-64c0-4.4-3.6-8-8-8h-56c-4.4 0-8 3.6-8 8v64H384v-64c0-4.4-3.6-8-8-8h-56c-4.4 0-8 3.6-8 8v64H144c-17.7 0-32 14.3-32 32v664c0 17.7 14.3 32 32 32h736c17.7 0 32-14.3 32-32V216c0-17.7-14.3-32-32-32zm-40 656H184V460h656v380zM184 392V256h128v48c0 4.4 3.6 8 8 8h56c4.4 0 8-3.6 8-8v-48h256v48c0 4.4 3.6 8 8 8h56c4.4 0 8-3.6 8-8v-48h128v136H184z"})}))}),"calendar-outlined")},169:function(e,t,n){"use strict";var r=n(280);n.d(t,"ContextProvider",(function(){return r.b}));var i=n(534);n.d(t,"DataStateContext",(function(){return i.a}));var a=n(536);n.d(t,"FilterStateContext",(function(){return a.a}));var o=n(1258);n.d(t,"withContext",(function(){return o.a}));var c=n(1259);n.d(t,"useTAMContext",(function(){return c.a}));n(1260)},1692:function(e,t,n){e.exports=n(1694)},1694:function(e,t,n){"use strict";var r,i,a,o;n.r(t);var c=window.baristaAssetsUrl||(null===(r=window)||void 0===r||null===(i=r.eventEspressoData)||void 0===i||null===(a=i.config)||void 0===a||null===(o=a.coreDomain)||void 0===o?void 0:o.distributionAssetsUrl);n.p=c;c=n.p,n(237);var s,u=n(16),l=n(17),d=n(600),f=n(461),b=n(27),p=n(45),v=new p.ModalSubscription(u.domain).getSubscriptions,h=new p.ModalRegistry({domain:u.domain}),j=n(0),O=n(3),m=n(24),y=n(64),g=n(2),_=n(22),x=n(1),k=Object(_.a)((function(e){return Object(x.jsx)("svg",Object(g.a)(Object(g.a)({"aria-hidden":"true",height:"1.5em",viewBox:"-2 0 22 22",width:"1.5em",xmlns:"http://www.w3.org/2000/svg",className:"ee-svg--ticket"},e),{},{children:Object(x.jsx)("path",{d:"M20 6.38L18.99 9.2v-.01c-.52-.19-1.03-.16-1.53.08s-.85.62-1.04 1.14-.16 1.03.07 1.53c.24.5.62.84 1.15 1.03v.01l-1.01 2.82-15.06-5.38.99-2.79c.52.19 1.03.16 1.53-.08.5-.23.84-.61 1.03-1.13s.16-1.03-.08-1.53a1.93 1.93 0 00-1.13-1.02L4.93 1zm-4.97 5.69l1.37-3.76c.12-.31.1-.65-.04-.95s-.39-.53-.7-.65L8.14 3.98c-.64-.23-1.37.12-1.6.74L5.17 8.48c-.24.65.1 1.37.74 1.6l7.52 2.74c.14.05.28.08.43.08.52 0 1-.33 1.17-.83zM7.97 4.45l7.51 2.73c.19.07.34.21.43.39.08.18.09.38.02.57l-1.37 3.76c-.13.38-.58.59-.96.45L6.09 9.61a.75.75 0 01-.45-.96l1.37-3.76c.1-.29.39-.49.7-.49.09 0 .17.02.26.05zm6.82 12.14c.35.27.75.41 1.2.41H16v3H0v-2.96c.55 0 1.03-.2 1.41-.59.39-.38.59-.86.59-1.41s-.2-1.02-.59-1.41-.86-.59-1.41-.59V10h1.05l-.28.8 2.87 1.02c-.51.16-.89.62-.89 1.18v4c0 .69.56 1.25 1.25 1.25h8c.69 0 1.25-.56 1.25-1.25v-1.75l.83.3c.12.43.36.78.71 1.04zM3.25 17v-4c0-.41.34-.75.75-.75h.83l7.92 2.83V17c0 .41-.34.75-.75.75H4c-.41 0-.75-.34-.75-.75z"})}))}),"ticket"),T=n(5),w=n(36),E=n(1677),D=function(e){var t=e.isOnlyButton,n=Object(p.useGlobalModal)(u.EdtrGlobalModals.EDIT_DATE).open,r=Object(j.useMemo)((function(){var e=u.hooks.applyFilters("eventEditor.addSingleDate.buttonProps",w.EMPTY_OBJECT,t);return u.hooks.applyFilters("eventEditor.addSingleDate.button",Object(x.jsx)(T.Button,Object(g.a)({buttonText:t?Object(O.__)("Add New Date"):Object(O.__)("Add Single Date"),buttonType:"primary",onClick:n,icon:t&&E.a,size:t?"big":"default"},e)),t)}),[t,n]);return t?r:Object(x.jsx)(T.NewEntityOption,{className:"ee-new-entity-option__single-datetime",description:Object(O.__)("Add a single date that only occurs once"),icon:E.a,title:Object(O.__)("Single Date"),children:r})},C=function(e){var t=e.children,n=Object(p.useGlobalModal)(u.EdtrGlobalModals.NEW_DATE).openWithData,r=Object(j.useCallback)((function(){n({children:t})}),[t,n]);return Object(x.jsx)(T.Button,{buttonText:Object(O.__)("Add New Date"),buttonType:"primary",icon:E.a,mr:2,onClick:r,size:"big"})},S=function(){return Object(x.jsx)(u.NewDateOptions,{children:function(e){return e.length>1?Object(x.jsx)(C,{children:e}):Object(x.jsx)(x.Fragment,{children:e})}})},F=function(){var e=Object(p.useGlobalModal)(u.EdtrGlobalModals.NEW_DATE),t=e.isOpen,n=e.close,r=e.getData;return t&&Object(x.jsx)(T.NewEntityModal,{isOpen:!0,onClose:n,title:Object(O.__)("Add New Date"),children:r().children})},I=Object(m.withCurrentUserCan)(w.USE_ADVANCED_EDITOR)((function(){var e=Object(p.useGlobalModal)(u.EdtrGlobalModals.TAM).openWithData,t=Object(u.useDatetimes)(),n=Object(u.useTickets)(),r=!t.length||!n.length,i=r&&Object(O.__)("Add a date or a ticket in order to use Ticket Assignment Manager"),a=Object(j.useCallback)((function(){e({assignmentType:"forAll"})}),[e]);return Object(x.jsxs)(T.ButtonRow,{children:[Object(x.jsx)(S,{}),Object(x.jsx)(T.Button,{buttonText:Object(O.__)("Ticket Assignments"),icon:k,isDisabled:r,onClick:a,size:"big",tooltip:i})]})})),N=function(){var e=Object(u.useDatetimes)();return Object(x.jsxs)(x.Fragment,{children:[Object(x.jsx)(y.EntityCacheIds,{entities:e}),Object(x.jsx)(I,{})]})};!function(e){e.CALENDAR="calendar",e.CALCULATOR="calculator",e.EDIT="edit",e.FILTER="filter",e.GROUPS="groups",e.TICKET="ticket-alt"}(s||(s={}));var A,M,P,L,R,z,B=n(467),V={icons:[{icon:s.EDIT,description:Object(O.__)("Edit Event Date Details")},{icon:s.GROUPS,description:Object(O.__)("View Registrations for this Date")},{icon:s.TICKET,description:Object(O.__)("Manage Ticket Assignments")},{icon:B.a,description:Object(O.__)("Move Date to Trash")}],swatches:{DTA:Object(O.__)("Active"),DTT:Object(O.__)("Trashed"),DTE:Object(O.__)("Expired"),DTS:Object(O.__)("Sold Out"),DTU:Object(O.__)("Upcoming")}},$=Object(j.lazy)((function(){return n.e(5).then(n.bind(null,1795))})),U=function(){return Object(x.jsx)(j.Suspense,{fallback:Object(x.jsx)(T.LoadingNotice,{}),children:Object(x.jsx)($,{})})},H=Object(j.lazy)((function(){return n.e(6).then(n.bind(null,1794))})),G=function(){return Object(x.jsx)(j.Suspense,{fallback:Object(x.jsx)(T.LoadingNotice,{}),children:Object(x.jsx)(H,{})})},W=n(12),q=n(14),K=(A={},Object(q.a)(A,u.DisplayStartOrEndDate.start,Object(O.__)("start dates only")),Object(q.a)(A,u.DisplayStartOrEndDate.end,Object(O.__)("end dates only")),Object(q.a)(A,u.DisplayStartOrEndDate.both,Object(O.__)("start and end dates")),A),Y=(M={},Object(q.a)(M,W.DatetimeSales.all,Object(O.__)("all dates")),Object(q.a)(M,W.DatetimeSales.above90Capacity,Object(O.__)("dates above 90% capacity")),Object(q.a)(M,W.DatetimeSales.above75Capacity,Object(O.__)("dates above 75% capacity")),Object(q.a)(M,W.DatetimeSales.above50Capacity,Object(O.__)("dates above 50% capacity")),Object(q.a)(M,W.DatetimeSales.below50Capacity,Object(O.__)("dates below 50% capacity")),M),Z=(P={},Object(q.a)(P,W.DatetimeStatus.all,Object(O.__)("all dates")),Object(q.a)(P,W.DatetimeStatus.activeUpcoming,Object(O.__)("all active and upcoming")),Object(q.a)(P,W.DatetimeStatus.activeOnly,Object(O.__)("active dates only")),Object(q.a)(P,W.DatetimeStatus.upcomingOnly,Object(O.__)("upcoming dates only")),Object(q.a)(P,W.DatetimeStatus.nextActiveUpcomingOnly,Object(O.__)("next active or upcoming only")),Object(q.a)(P,W.DatetimeStatus.soldOutOnly,Object(O.__)("sold out dates only")),Object(q.a)(P,W.DatetimeStatus.recentlyExpiredOnly,Object(O.__)("recently expired dates")),Object(q.a)(P,W.DatetimeStatus.expiredOnly,Object(O.__)("all expired dates")),Object(q.a)(P,W.DatetimeStatus.trashedOnly,Object(O.__)("trashed dates only")),P),Q={date:Object(O.__)("start date"),name:Object(O.__)("name"),id:Object(O.__)("ID"),order:Object(O.__)("custom order")},J={displayStartOrEndDate:Object(O.__)("display"),recurrence:Object(O.__)("recurrence"),sales:Object(O.__)("sales"),sortBy:Object(O.__)("sort by"),search:Object(O.__)("search"),status:Object(O.__)("status")},X=function(){var e=Object(u.useDatesListFilterState)(),t=e.status,n=e.setStatus,r=e.sales,i=e.setSales,a=e.searchText,o=e.setSearchText,c=e.recurrence,s=e.setRecurrence,l="".concat(J.status,": ").concat(null===Z||void 0===Z?void 0:Z[t]),d="".concat(J.sales,": ").concat(null===Y||void 0===Y?void 0:Y[r]),f="".concat(J.search,": ").concat(a),b="".concat(J.recurrence,": ").concat(Object(O.__)("ON")),p=Object(j.useCallback)((function(){return n(W.DatetimeStatus.all)}),[n]),v=Object(j.useCallback)((function(){return i(W.DatetimeSales.all)}),[i]),h=Object(j.useCallback)((function(){return s("")}),[s]),m=Object(j.useCallback)((function(){return o("")}),[o]);return Object(x.jsxs)(T.ActiveFilters,{children:[t!==W.DatetimeStatus.all&&Object(x.jsx)(T.FilterTag,{title:l,onRemove:p}),r!==W.DatetimeSales.all&&Object(x.jsx)(T.FilterTag,{title:d,onRemove:v}),c&&Object(x.jsx)(T.FilterTag,{title:b,onRemove:h}),a?Object(x.jsx)(T.FilterTag,{title:f,onRemove:m}):null]})},ee=Object(l.objectToSelectOptions)(K),te=function(){var e=Object(u.useDatesListFilterState)(),t=e.displayStartOrEndDate,n=e.setDisplayStartOrEndDate;return Object(x.jsx)(T.SelectWithLabel,{id:"ee-dates-list-display-control",label:J.displayStartOrEndDate,value:t,options:ee,onChangeValue:n})},ne=Object(l.objectToSelectOptions)(Y),re=function(){var e=Object(u.useDatesListFilterState)(),t=e.sales,n=e.setSales;return Object(x.jsx)(T.SelectWithLabel,{id:"ee-dates-list-sales-control",label:J.sales,onChangeValue:n,options:ne,value:t})},ie=Object(l.objectToSelectOptions)(Z),ae=function(){var e=Object(u.useDatesListFilterState)(),t=e.status,n=e.setStatus;return Object(x.jsx)(T.SelectWithLabel,{id:"ee-dates-list-status-control",label:J.status,onChangeValue:n,options:ie,value:t})},oe={month:"LLL"},ce=function(e){var t=e.dbId,n=e.endDate,r=e.name,i=e.startDate;return Object(x.jsxs)(x.Fragment,{children:[Object(x.jsxs)("span",{children:[t,")"]}),Object(x.jsxs)("span",{children:[r,": "]}),Object(x.jsx)(y.RangeFormat,{endDate:n,formatTokens:oe,showTime:!0,startDate:i})]})},se=Object(l.objectToSelectOptions)(Q),ue=function(e){return Object(g.a)(Object(g.a)({},e),{},{content:Object(x.jsx)(ce,Object(g.a)({},e))})},le=function(){var e=Object(u.useDatesListFilterState)(),t=e.sortBy,n=e.setSortBy,r=Object(u.useFilteredDateIds)(),i=Object(u.useReorderDatetimes)(r),a=i.allReorderedEntities,o=i.sortResponder,c=i.updateEntityList;return Object(x.jsx)(y.SortByControl,{draggableItems:a,droppableId:w.datetimesDroppableId,entityType:m.TypeName.datetimes,id:"ee-dates-list-sort-by-control",label:J.sortBy,renderDraggableItem:ue,onChangeValue:n,onSort:o,onSubmit:c,options:se,value:t})},de=Object(u.withEntityListContext)({Provider:u.DatetimesListProvider,Component:function(){var e=Object(u.useDatesListFilterState)(),t=Object(j.useCallback)((function(){return"card"===e.view?Object(x.jsx)(U,{}):Object(x.jsx)(G,{})}),[e.view]);return Object(x.jsx)(y.EntityList,{activeFilters:Object(x.jsx)(X,{}),domain:u.domain,entityType:m.TypeName.datetimes,filterState:e,footer:Object(x.jsx)(N,{}),headerText:Object(O.__)("Event Dates"),legendConfig:V,listId:u.datesList,loadingText:Object(O.__)("loading event dates\u2026"),renderList:t})}}),fe=n(10),be=n.n(fe),pe=n(235),ve=function(e){var t=e.status,n=e.onStatusChange,r=be()("ee-edtr-option","ee-edtr-option__active-status",Object(pe.datetimeStatusBgColorClassName)(null)),i=Object(j.useMemo)((function(){return Object(l.objectToSelectOptions)(w.datetimeStatus)}),[]);return Object(x.jsx)(T.SelectWithLabel,{className:r,fitContainer:!0,flow:"inline",id:"ee-event-registration-active-status-select",label:Object(O.__)("Active status"),labelClassName:"ee-grid__item-label",labelPosition:"left-middle",noBorderColor:!0,onChangeValue:n,options:i,value:t,wrapperClassName:"ee-edtr-option__wrapper ee-edtr-option__active-status-wrapper"})},he=function(e){var t=e.altRegPage,n=e.onAltRegPageChange;return Object(x.jsx)(T.InlineEditTextWithLabel,{className:"ee-edtr-option ee-edtr-option__alt-reg-page",id:"ee-event-registration-alt-reg-page",label:Object(O.__)("Alternative Registration Page"),size:"huge",labelClassName:"ee-grid__item-label",labelPosition:"left-middle",onChange:n,placeholder:"https://",tag:"h4",value:t,wrapperClassName:"ee-edtr-option__wrapper ee-edtr-option__alt-reg-page-wrapper"})},je=function(e){var t,n=e.defaultRegStatus,r=e.onDefaultRegStatusChange,i=Object(j.useMemo)((function(){return W.regStatusOptions.filter((function(e){return e.value===n}))}),[n]),a=be()("ee-edtr-option ee-edtr-option__default-reg-status","ee-status-bg--".concat(null===(t=i[0])||void 0===t?void 0:t.code));return Object(x.jsx)(T.SelectWithLabel,{className:a,fitContainer:!0,flow:"inline",label:Object(O.__)("Default Registration Status"),id:"ee-event-registration-default-status-select",noBorderColor:!0,onChangeValue:r,options:W.regStatusOptions,value:n,labelClassName:"ee-grid__item-label",labelPosition:"left-middle",wrapperClassName:"ee-edtr-option__wrapper ee-edtr-option__default-reg-status-wrapper"})},Oe=function(e){var t=e.allowDonations,n=e.onDonationsChange,r=t?Object(O.__)("Donations Enabled"):Object(O.__)("Donations Disabled");return Object(x.jsx)(T.SwitchWithLabel,{className:"ee-edtr-option ee-edtr-option__event-donations",id:"ee-event-donations",label:r,isChecked:t,onChangeValue:n,debounceDelay:5e3,labelClassName:"ee-grid__item-label",labelPosition:"left-middle",wrapperClassName:"ee-edtr-option__wrapper ee-edtr-option__event-donations-wrapper"})},me=function(e){var t=e.eventManagers,n=e.managerId,r=e.onManagerChange,i=Object(j.useMemo)((function(){return t&&Object(l.entityListToSelectOptions)(t)}),[t]);return Object(x.jsx)(T.SelectWithLabel,{className:"ee-edtr-option ee-edtr-option__event-manager",label:Object(O.__)("Event Manager"),fitContainer:!0,flow:"inline",id:"ee-event-registration-manager",noBorderColor:!0,onChangeValue:r,options:i,value:n,labelClassName:"ee-grid__item-label",labelPosition:"left-middle",wrapperClassName:"ee-edtr-option__wrapper ee-edtr-option__event-manager-wrapper"})},ye=function(e){var t=e.onPhoneNumberChange,n=e.phoneNumber;return Object(x.jsx)(T.InlineEditTextWithLabel,{className:"ee-edtr-option ee-edtr-option__event-phone",id:"ee-event-registration-phone-number",onChange:t,tag:"h4",value:n,label:Object(O.__)("Event Phone Number"),labelClassName:"ee-grid__item-label",labelPosition:"left-middle",placeholder:"123-456-7890",wrapperClassName:"ee-edtr-option__wrapper ee-edtr-option__event-phone-wrapper"})},ge=function(e){var t=e.maxReg,n=e.onMaxRegChange,r=t&&String(t);return Object(x.jsx)(T.InlineEditTextWithLabel,{id:"ee-event-registration-max-reg",label:Object(O.__)("Max Registrations per Transaction"),className:"ee-edtr-option ee-edtr-option__max-reg",labelClassName:"ee-grid__item-label",labelPosition:"left-middle",onChange:n,tag:"h4",value:r,wrapperClassName:"ee-edtr-option__wrapper ee-edtr-option__max-reg-wrapper"})},_e=function(e){var t=e.displayTicketSelector,n=e.onTicketSelectorChange,r=t?Object(O.__)("Ticket Selector Enabled"):Object(O.__)("Ticket Selector Disabled");return Object(x.jsx)(T.SwitchWithLabel,{id:"ee-event-registration-ticket-selector",label:r,className:"ee-edtr-option ee-edtr-option__ticket",isChecked:t,onChangeValue:n,debounceDelay:5e3,labelClassName:"ee-grid__item-label",labelPosition:"left-middle",wrapperClassName:"ee-edtr-option__wrapper ee-edtr-option__ticket-wrapper"})},xe=function(e){return function(){var t,n,r=Object(u.useEvent)(),i=Object(u.useEventManagers)(),a=Object(u.useEventMutator)(null===r||void 0===r?void 0:r.id).updateEntity,o=Object(j.useCallback)((function(e){e!==(null===r||void 0===r?void 0:r.altRegPage)&&a({altRegPage:e})}),[null===r||void 0===r?void 0:r.altRegPage,a]),c=Object(j.useCallback)((function(e){(null===r||void 0===r?void 0:r.allowDonations)!==e&&a({allowDonations:e})}),[null===r||void 0===r?void 0:r.allowDonations,a]),s=Object(j.useCallback)((function(e){(null===r||void 0===r?void 0:r.defaultRegStatus)!==e&&a({defaultRegStatus:e})}),[null===r||void 0===r?void 0:r.defaultRegStatus,a]),l=Object(j.useCallback)((function(e){var t;e!==(null===r||void 0===r||null===(t=r.manager)||void 0===t?void 0:t.id)&&a({manager:e})}),[null===r||void 0===r||null===(t=r.manager)||void 0===t?void 0:t.id,a]),d=Object(j.useCallback)((function(e){var t=Number(e);t!==(null===r||void 0===r?void 0:r.maxRegistrations)&&a({maxRegistrations:t})}),[null===r||void 0===r?void 0:r.maxRegistrations,a]),f=Object(j.useCallback)((function(e){e!==(null===r||void 0===r?void 0:r.phoneNumber)&&a({phoneNumber:e})}),[null===r||void 0===r?void 0:r.phoneNumber,a]),b=Object(j.useCallback)((function(e){e!==(null===r||void 0===r?void 0:r.status)&&a({status:e})}),[null===r||void 0===r?void 0:r.status,a]),p=Object(j.useCallback)((function(e){(null===r||void 0===r?void 0:r.displayTicketSelector)!==e&&a({displayTicketSelector:e})}),[null===r||void 0===r?void 0:r.displayTicketSelector,a]);return Object(x.jsx)(e,{allowDonations:null===r||void 0===r?void 0:r.allowDonations,altRegPage:null===r||void 0===r?void 0:r.altRegPage,defaultRegStatus:null===r||void 0===r?void 0:r.defaultRegStatus,displayTicketSelector:null===r||void 0===r?void 0:r.displayTicketSelector,eventManagers:i,managerId:null===r||void 0===r||null===(n=r.manager)||void 0===n?void 0:n.id,maxReg:null===r||void 0===r?void 0:r.maxRegistrations,onAltRegPageChange:o,onDefaultRegStatusChange:s,onDonationsChange:c,onManagerChange:l,onMaxRegChange:d,onPhoneNumberChange:f,onStatusChange:b,onTicketSelectorChange:p,phoneNumber:null===r||void 0===r?void 0:r.phoneNumber,status:null===r||void 0===r?void 0:r.status})}},ke=Object(m.withFeature)("use_reg_options_meta_box")(xe((function(e){var t=e.allowDonations,n=e.altRegPage,r=e.defaultRegStatus,i=e.displayTicketSelector,a=e.eventManagers,o=e.managerId,c=e.maxReg,s=e.onAltRegPageChange,u=void 0===s?l.noop:s,d=e.onDefaultRegStatusChange,f=e.onDonationsChange,b=e.onManagerChange,p=e.onPhoneNumberChange,v=e.onStatusChange,h=e.onTicketSelectorChange,j=e.onMaxRegChange,m=void 0===j?l.noop:j,y=e.phoneNumber,g=e.status;return Object(x.jsxs)(T.Grid,{className:"ee-edtr-section ee-edtr-cards",maxColumns:2,size:"bigger",children:[Object(x.jsxs)(T.GridCard,{className:"ee-event-details",header:Object(O.__)("Event Details"),children:[Object(x.jsx)(ve,{status:g,onStatusChange:v}),Object(x.jsx)(me,{eventManagers:a,managerId:o,onManagerChange:b}),Object(x.jsx)(ye,{phoneNumber:y,onPhoneNumberChange:p}),Object(x.jsx)(Oe,{allowDonations:t,onDonationsChange:f})]}),Object(x.jsxs)(T.GridCard,{className:"ee-reg-options",header:Object(O.__)("Registration Options"),children:[Object(x.jsx)(je,{defaultRegStatus:r,onDefaultRegStatusChange:d}),Object(x.jsx)(_e,{displayTicketSelector:i,onTicketSelectorChange:h}),Object(x.jsx)(ge,{maxReg:c,onMaxRegChange:m}),Object(x.jsx)(he,{altRegPage:n,onAltRegPageChange:u})]})]})}))),Te=function(){return Object(f.d)("ticket")},we={margin:"5px",border:"1px solid red"},Ee=function(e){var t=e.children;return Object(x.jsx)("div",{style:we,children:t})},De=function(){var e=Te();return e.length>1?Object(x.jsx)(Ee,{children:e}):Object(x.jsx)(x.Fragment,{children:e})},Ce=function(e){var t=e.isOnlyButton,n=Object(p.useGlobalModal)(u.EdtrGlobalModals.EDIT_TICKET).open,r=Object(x.jsx)(T.Button,{buttonText:Object(O.__)("Add New Ticket"),icon:t?k:null,noVerticalMargin:!0,onClick:n,size:t?"big":"default"});return t?r:Object(x.jsx)(T.NewEntityOption,{description:Object(O.__)("Add a single ticket and assign the dates to it"),icon:k,title:Object(O.__)("Single Ticket"),children:r})},Se={noPadding:!0,size:"big"},Fe=Object(m.withFeature)("use_default_ticket_manager")((function(){var e=Object(p.useGlobalModal)(u.EdtrGlobalModals.DEFAULT_TICKETS).open,t=Object(m.useCurrentUserCan)()("read","default_tickets");return Object(x.jsx)(T.DropdownMenu,{noZindex:!0,toggleProps:Se,wrapperClassName:"default_tickets",children:Object(x.jsx)(T.DropdownMenuItem,{className:"default_tickets",isDisabled:!t,onClick:e,title:Object(O.__)("Default tickets")})})})),Ie=function(){var e=Object(u.useTickets)();return Object(x.jsxs)(x.Fragment,{children:[Object(x.jsx)(y.EntityCacheIds,{entities:e}),Object(x.jsx)(De,{}),Object(x.jsx)(Fe,{})]})},Ne={icons:[{icon:s.EDIT,description:Object(O.__)("Edit Ticket Details")},{icon:s.CALENDAR,description:Object(O.__)("Manage Date Assignments")},{icon:s.CALCULATOR,description:Object(O.__)("Ticket Price Calculator")},{icon:B.a,description:Object(O.__)("Move Ticket to Trash")}],swatches:{TKA:Object(O.__)("Trashed"),TKE:Object(O.__)("Expired"),TKO:Object(O.__)("On Sale"),TKS:Object(O.__)("Sold Out"),TKP:Object(O.__)("Pending")}},Ae=Object(j.lazy)((function(){return n.e(25).then(n.bind(null,1796))})),Me=function(){return Object(x.jsx)(j.Suspense,{fallback:Object(x.jsx)(T.LoadingNotice,{}),children:Object(x.jsx)(Ae,{})})},Pe=Object(j.lazy)((function(){return n.e(26).then(n.bind(null,1793))})),Le=function(){return Object(x.jsx)(j.Suspense,{fallback:Object(x.jsx)(T.LoadingNotice,{}),children:Object(x.jsx)(Pe,{})})},Re=(L={},Object(q.a)(L,u.DisplayStartOrEndDate.start,Object(O.__)("ticket sales start date only")),Object(q.a)(L,u.DisplayStartOrEndDate.end,Object(O.__)("ticket sales end date only")),Object(q.a)(L,u.DisplayStartOrEndDate.both,Object(O.__)("ticket sales start and end dates")),L),ze=(R={},Object(q.a)(R,W.TicketsSales.all,Object(O.__)("all tickets for all dates")),Object(q.a)(R,W.TicketsSales.above90Sold,Object(O.__)("tickets with 90% or more sold")),Object(q.a)(R,W.TicketsSales.above75Sold,Object(O.__)("tickets with 75% or more sold")),Object(q.a)(R,W.TicketsSales.above50Sold,Object(O.__)("tickets with 50% or more sold")),Object(q.a)(R,W.TicketsSales.below50Sold,Object(O.__)("tickets with less than 50% sold")),R),Be=Object(g.a)(Object(g.a)({},ze),{},Object(q.a)({},W.TicketsSales.all,Object(O.__)("all tickets for above dates"))),Ve=(z={},Object(q.a)(z,W.TicketsStatus.all,Object(O.__)("all tickets for all dates")),Object(q.a)(z,W.TicketsStatus.onSaleAndPending,Object(O.__)("all on sale and sale pending")),Object(q.a)(z,W.TicketsStatus.onSaleOnly,Object(O.__)("on sale tickets only")),Object(q.a)(z,W.TicketsStatus.pendingOnly,Object(O.__)("sale pending tickets only")),Object(q.a)(z,W.TicketsStatus.nextOnSaleOrPendingOnly,Object(O.__)("next on sale or sale pending only")),Object(q.a)(z,W.TicketsStatus.soldOutOnly,Object(O.__)("sold out tickets only")),Object(q.a)(z,W.TicketsStatus.expiredOnly,Object(O.__)("expired tickets only")),Object(q.a)(z,W.TicketsStatus.trashedOnly,Object(O.__)("trashed tickets only")),z),$e=Object(g.a)(Object(g.a)({},Ve),{},Object(q.a)({},W.TicketsStatus.all,Object(O.__)("all tickets for above dates"))),Ue={date:Object(O.__)("ticket sale date"),name:Object(O.__)("ticket name"),id:Object(O.__)("ticket ID"),order:Object(O.__)("custom order")},He={displayStartOrEndDate:Object(O.__)("display"),isChained:Object(O.__)("linked"),sales:Object(O.__)("sales"),search:Object(O.__)("search"),sortBy:Object(O.__)("sort by"),status:Object(O.__)("status")},Ge=function(){var e=Object(u.useTicketsListFilterState)(),t=e.status,n=e.setStatus,r=e.sales,i=e.setSales,a=e.searchText,o=e.setSearchText,c=e.isChained,s=e.toggleIsChained,l="".concat(He.status,": ").concat(null===Ve||void 0===Ve?void 0:Ve[t]),d="".concat(He.sales,": ").concat(null===ze||void 0===ze?void 0:ze[r]),f="".concat(He.search,": ").concat(a),b="".concat(He.isChained,": ").concat(Object(O.__)("ON")),p=Object(j.useCallback)((function(){return n(W.TicketsStatus.all)}),[n]),v=Object(j.useCallback)((function(){return i(W.TicketsSales.all)}),[i]),h=Object(j.useCallback)((function(){return o("")}),[o]);return Object(x.jsxs)(T.ActiveFilters,{children:[t!==W.TicketsStatus.all&&Object(x.jsx)(T.FilterTag,{title:l,onRemove:p}),r!==W.TicketsSales.all&&Object(x.jsx)(T.FilterTag,{title:d,onRemove:v}),a?Object(x.jsx)(T.FilterTag,{title:f,onRemove:h}):null,c&&Object(x.jsx)(T.FilterTag,{title:b,onRemove:s})]})},We=Object(l.objectToSelectOptions)(Re),qe=function(){var e=Object(u.useTicketsListFilterState)(),t=e.displayStartOrEndDate,n=e.setDisplayStartOrEndDate;return Object(x.jsx)(T.SelectWithLabel,{id:"ee-tickets-list-display-control",label:He.displayStartOrEndDate,onChangeValue:n,options:We,value:t})},Ke=n(26),Ye=function(){var e=Object(u.useTicketsListFilterState)(),t=e.isChained,n=e.sales,r=e.setSales,i=Object(Ke.useMemoStringify)(Object(l.objectToSelectOptions)(t?Be:ze),[t]);return Object(x.jsx)(T.SelectWithLabel,{id:"ee-tickets-list-sales-control",label:He.sales,onChangeValue:r,options:i,value:n})},Ze=function(){var e=Object(u.useTicketsListFilterState)(),t=e.isChained,n=e.status,r=e.setStatus,i=Object(Ke.useMemoStringify)(Object(l.objectToSelectOptions)(t?$e:Ve),[t]);return Object(x.jsx)(T.SelectWithLabel,{id:"ee-tickets-list-status-control",label:He.status,onChangeValue:r,options:i,value:n})},Qe={month:"LLL"},Je=function(e){var t=e.dbId,n=e.endDate,r=e.name,i=e.price,a=e.startDate;return Object(x.jsxs)(x.Fragment,{children:[Object(x.jsxs)("span",{children:[t,")"]}),Object(x.jsxs)("span",{children:[r,": "]}),Object(x.jsx)("span",{children:Object(x.jsx)(y.CurrencyDisplay,{value:i})}),Object(x.jsx)("span",{children:"-"}),Object(x.jsx)(y.RangeFormat,{endDate:n,formatTokens:Qe,showTime:!0,startDate:a})]})},Xe=Object(l.objectToSelectOptions)(Ue),et=function(e){return Object(g.a)(Object(g.a)({},e),{},{content:Object(x.jsx)(Je,Object(g.a)({},e))})},tt=function(){var e=Object(u.useTicketsListFilterState)(),t=e.sortBy,n=e.setSortBy,r=Object(u.useFilteredTicketIds)(),i=Object(u.useReorderTickets)(r),a=i.allReorderedEntities,o=i.sortResponder,c=i.updateEntityList;return Object(x.jsx)(y.SortByControl,{draggableItems:a,droppableId:w.ticketDroppableId,entityType:m.TypeName.tickets,id:"ee-tickets-list-sort-by-control",label:He.sortBy,onChangeValue:n,options:Xe,onSort:o,onSubmit:c,renderDraggableItem:et,value:t})},nt=n(1662),rt=n(1663),it=function(){var e=Object(u.useTicketsListFilterState)(),t=e.isChained,n=e.toggleIsChained,r=be()("ee-filter-bar__btn ee-filter-bar__chain",{"ee-filter-bar__btn--active":t,"ee-filter-bar__chain--active":t}),i=t?nt.a:rt.a,a=t?Object(O.__)("tickets list is linked to dates list and is showing tickets for above dates only"):Object(O.__)("tickets list is unlinked and is showing tickets for all event dates");return Object(x.jsx)(T.IconButton,{className:r,icon:i,id:"ee-ticket-list-filter-bar-is-chained",label:He.isChained,onClick:n,tooltip:a,showTooltipOnMobile:!0})},at=Object(u.withEntityListContext)({Provider:u.TicketsListProvider,Component:function(){var e=Object(u.useTicketsListFilterState)(),t=Object(j.useCallback)((function(){return"card"===e.view?Object(x.jsx)(Me,{}):Object(x.jsx)(Le,{})}),[e.view]);return Object(x.jsx)(y.EntityList,{activeFilters:Object(x.jsx)(Ge,{}),domain:u.domain,entityType:m.TypeName.tickets,filterState:e,footer:Object(x.jsx)(Ie,{}),headerText:Object(O.__)("Available Tickets"),legendConfig:Ne,listId:u.ticketsList,loadingText:Object(O.__)("loading tickets\u2026"),renderList:t})}}),ot=function(){return Object(u.useRegisterIsChainedFilter)(),Object(x.jsx)(at,{})},ct=Object(m.withFeature)("use_event_description_rte")((function(){var e=Object(u.useEvent)(),t=Object(u.useEventMutator)(null===e||void 0===e?void 0:e.id).updateEntity,n=Object(j.useCallback)((function(n){n!==(null===e||void 0===e?void 0:e.description)&&t({description:n})}),[null===e||void 0===e?void 0:e.description,t]);return Object(j.useEffect)((function(){var e;null===(e=document.getElementById("postdivrich"))||void 0===e||e.remove()}),[]),Object(x.jsxs)("div",{className:"ee-event-description ee-edtr-section",children:[Object(x.jsx)(T.Heading,{as:"h3",className:"ee-edtr-section-heading",children:Object(O.__)("Event Description")}),Object(x.jsx)(y.AdvancedTextEditor,{debounceDelay:4e3,defaultValue:null===e||void 0===e?void 0:e.description,onChange:n})]})})),st=n(9),ut=n(1676),lt=Object(_.a)((function(e){return Object(x.jsx)("svg",Object(g.a)(Object(g.a)({"aria-hidden":"true",height:"1.5em",viewBox:"0 1 24 24",width:"1.5em",xmlns:"https://www.w3.org/2000/svg",className:"ee-svg--venue-seat"},e),{},{children:Object(x.jsx)("path",{d:"M4 18v3h3v-3h10v3h3v-6H4zm15-8h3v3h-3zM2 10h3v3H2zm15 3H7V5c0-1.1.9-2 2-2h6c1.1 0 2 .9 2 2v8z"})}))}),"venue-seat"),dt=Object(_.a)((function(e){return Object(x.jsx)("svg",Object(g.a)(Object(g.a)({"aria-hidden":"true",height:"1.5em",viewBox:"-100 -100 720 720",width:"1.5em",xmlns:"https://www.w3.org/2000/svg",className:"ee-svg--phone"},e),{},{children:Object(x.jsx)("path",{d:"M497.39 361.8l-112-48a24 24 0 00-28 6.9l-49.6 60.6A370.66 370.66 0 01130.6 204.11l60.6-49.6a23.94 23.94 0 006.9-28l-48-112A24.16 24.16 0 00122.6.61l-104 24A24 24 0 000 48c0 256.5 207.9 464 464 464a24 24 0 0023.4-18.6l24-104a24.29 24.29 0 00-14.01-27.6z"})}))}),"phone"),ft=n(432),bt=function(e,t){var n=Object(m.useConfig)().siteUrl;return Object(j.useMemo)((function(){var r=Object(m.getAdminUrl)({adminSiteUrl:n.admin,page:w.ADMIN_ROUTES.VENUES});return Object(ft.addQueryArgs)(r,{post:t,action:e,return:"edit"})}),[n.admin,e,t])},pt={container:"ee-edtr-section ee-event-venue"},vt=Object(x.jsx)(T.Heading,{as:"h3",className:"ee-edtr-section-heading",children:Object(O.__)("Venue Details")}),ht=function(){var e=Object(u.useEvent)(),t=Object(u.useEventMutator)(null===e||void 0===e?void 0:e.id).updateEntity,n=Object(j.useState)((null===e||void 0===e?void 0:e.venue)||""),r=Object(st.a)(n,2),i=r[0],a=r[1],o=Object(u.useVenues)(),c=Object(j.useMemo)((function(){return Object(W.findEntityByGuid)(o)(i)}),[i,o]),s=bt("create_new"),d=bt("edit",null===c||void 0===c?void 0:c.dbId),f=null===c||void 0===c?void 0:c.capacity,p=Object(l.isInfinite)(f)?Object(O.__)("unlimited space"):Object(O.sprintf)(Object(O.__)("Space for up to %d people"),null===c||void 0===c?void 0:c.capacity),v=Object(j.useCallback)((function(e){return a(e)}),[]),h=Object(j.useCallback)((function(e){return t({venue:e})}),[t]),m=null===c||void 0===c?void 0:c.thumbnail,y=Object(j.useMemo)((function(){return{inline:Object(O.__)("Venue address")}}),[]);return Object(x.jsxs)(T.Container,{"aria-label":Object(O.__)("Venue Details card"),classes:pt,header:vt,children:[c&&Object(x.jsxs)("div",{className:"ee-event-venue__card",children:[m?Object(x.jsx)("div",{className:"ee-event-venue__thumbnail",children:Object(x.jsx)(b.Image,{src:m,alt:null===c||void 0===c?void 0:c.name})}):Object(x.jsx)("div",{className:"ee-event-venue__thumbnail ee-event-venue__thumbnail--no-image",children:Object(O.__)("no image")}),Object(x.jsxs)("div",{className:"ee-event-venue__properties",children:[Object(x.jsx)(T.Heading,{as:"h4",className:"ee-event-venue__venue-name","aria-label":Object(O.__)("Venue name"),children:null===c||void 0===c?void 0:c.name}),Object(x.jsx)("div",{className:"ee-event-venue__desc",children:Object(x.jsx)("p",{children:null===c||void 0===c?void 0:c.shortDescription})}),Object(x.jsxs)("div",{className:"ee-event-venue__details",children:[Object(x.jsxs)("div",{className:"ee-event-venue__detail",children:[Object(x.jsx)("span",{className:"ee-event-venue__detail-label",children:Object(x.jsx)(ut.a,{})}),Object(x.jsx)("span",{className:"ee-event-venue__detail-value",children:Object(x.jsx)(T.Address,Object(g.a)({className:"ee-event-venue__address",inline:!0,labels:y},c))})]}),Object(x.jsxs)("div",{className:"ee-event-venue__detail",children:[Object(x.jsx)("span",{className:"ee-event-venue__detail-label",children:Object(x.jsx)(lt,{})}),Object(x.jsx)("span",{className:"ee-event-venue__detail-value","aria-label":Object(O.__)("Venue capacity"),children:p})]}),Object(x.jsxs)("div",{className:"ee-event-venue__detail",children:[Object(x.jsx)("span",{className:"ee-event-venue__detail-label",children:Object(x.jsx)(dt,{})}),Object(x.jsx)("span",{className:"ee-event-venue__detail-value","aria-label":Object(O.__)("Venue telephone"),children:(null===c||void 0===c?void 0:c.phone)||"(###) ###-####"})]})]}),Object(x.jsx)("div",{className:"ee-event-venue__actions",children:Object(x.jsx)(T.TextLink,{className:"ee-event-venue__edit-link",href:d,showExternalIcon:!0,children:Object(O.__)("Edit this Venue")})})]})]}),Object(x.jsx)(T.VenueSelector,{className:"ee-event-venue",createVenueLink:s,label:Object(O.__)("Select a Venue for the Event"),onChangeValue:h,onChangeInstantValue:v,value:null===e||void 0===e?void 0:e.venue,venueName:null===c||void 0===c?void 0:c.name,venues:o})]})},jt=n(1434),Ot=[{value:"ALL",label:Object(O.__)("all")},{value:"PRIMARY",label:Object(O.__)("primary registrant")},{value:"PURCHASER",label:Object(O.__)("purchaser")},{value:"REGISTRANTS",label:Object(O.__)("registrants")}],mt=[{value:"",label:"..."},{value:"Attendee.fname",label:Object(O.__)("Attendee First Name")},{value:"Attendee.lname",label:Object(O.__)("Attendee Last Name")},{value:"Attendee.email",label:Object(O.__)("Attendee Email Address")},{value:"Attendee.address",label:Object(O.__)("Attendee Address")}],yt=n(4),gt=yt.propEq("type","TEXT"),_t=yt.propEq("mapsTo","Attendee.fname"),xt=yt.allPass([gt,_t]),kt=yt.any(xt),Tt=yt.propEq("type","EMAIL"),wt=yt.propEq("mapsTo","Attendee.email"),Et=yt.allPass([Tt,wt]),Dt=yt.any(Et),Ct=function(e){var t=e.elements,n=e.sections,r="",i=Object(j.useMemo)((function(){var e=Object(W.getGuids)(Object.values(n).filter(W.isNotSharedOrDefault)),r=Object.values(t).filter(yt.propSatisfies(yt.flip(yt.includes)(e),"belongsTo"));return{hasFirstName:kt(r),hasEmail:Dt(r)}}),[t,n]);return i.hasFirstName?i.hasEmail||(r=Object(O.sprintf)(Object(O.__)('Registration form must have a field of type "%1$s" which maps to "%2$s"'),Object(O.__)("Email Address"),Object(O.__)("Attendee Email Address"))):r=Object(O.sprintf)(Object(O.__)('Registration form must have a field of type "%1$s" which maps to "%2$s"'),Object(O.__)("Text Input"),Object(O.__)("Attendee First Name")),r?Object(x.jsx)(T.Banner,{status:"error",title:Object(O.__)("Please add the required fields"),message:r}):null},St=Object(x.jsx)(T.Heading,{as:"h3",className:"ee-edtr-section-heading",children:Object(O.__)("Registration Form")}),Ft=Object(m.withFeature)("use_reg_form_builder")((function(){var e=Object(u.getEdtrDomData)("formBuilder"),t=e.elements,n=e.sections,r=e.topLevelSectionId;return Object(x.jsx)(jt.FormBuilder,{appliesToOptions:Ot,containerClassName:"ee-edtr-section",header:St,initialElements:t,initialSections:n,mapsToOptions:mt,topBanner:Ct,topLevelSectionId:r,onChange:console.log})})),It=n(279),Nt=n(139),At=n(175),Mt=n(18),Pt=function(){var e=Object(m.useStatus)().isLoaded,t=Object(Mt.useIsRehydrated)(),n=Object(st.a)(t,1)[0],r=Object(j.useMemo)((function(){var t=[];if(!w.isDev||!n)return[];for(var r in m.TypeName)e(m.TypeName[r])&&t.push(m.TypeName[r]);return t}),[e,n]);return Object(j.useMemo)((function(){return{dev:{readyTypes:r}}}),[r])},Lt=function(){var e=Object(At.useSystemNotifications)(),t=Pt();return Object(j.useEffect)((function(){Object(At.initToaster)()}),[]),Object(j.useEffect)((function(){t.dev.readyTypes.forEach((function(t){var n=Object(It.sprintf)("%s initialized",t);e.success({message:n,toastId:n})}))}),[e,t]),Object(x.jsx)(Nt.a,{})},Rt=n(8),zt=n(43),Bt=n(34),Vt=n.n(Bt),$t=n(1772),Ut=n(1678),Ht=n(1773),Gt=n(50),Wt=n(222),qt=n(82),Kt=function(){var e=Object(zt.a)(Vt.a.mark((function e(t){return Vt.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(qt.yupToFinalFormErrors)(Yt,t);case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),Yt=Wt.b(Object(g.a)({name:Wt.c()},u.datesSchema)),Zt=["id","name","description","capacity","isTrashed"],Qt=[u.startAndEndDateFixer],Jt={className:"ee-form-item-pair"},Xt=function(e,t){var n=Object(u.useDatetimeItem)({id:e}),r=Object(m.useSiteDateToUtcISO)(),i=Object(m.useUtcISOToSiteDate)(),a=Object(Ke.useMemoStringify)((null===n||void 0===n?void 0:n.startDate)?i(null===n||void 0===n?void 0:n.startDate):Object(Gt.setDefaultTime)(w.PLUS_ONE_MONTH,"start")),o=Object(Ke.useMemoStringify)((null===n||void 0===n?void 0:n.endDate)?i(null===n||void 0===n?void 0:n.endDate):Object(Gt.setDefaultTime)(w.PLUS_ONE_MONTH,"end")),c=t.onSubmit,s=Object(j.useCallback)(function(){var e=Object(zt.a)(Vt.a.mark((function e(t,n){var i,a,o,s,u,l,d=arguments;return Vt.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:for(i=t.startDate,a=t.endDate,o=Object(Rt.a)(t,["startDate","endDate"]),s=d.length,u=new Array(s>2?s-2:0),l=2;l0?e.name:0===e.dbId?"":e.dbId.toString()}(e);return Object(O.sprintf)("%1$s %2$s",t,n)}),[]),l=Object(j.useMemo)((function(){var e=u(n,"ticket"),r=u(t,"datetime");switch(o){case null:return Object(O.sprintf)("click to assign %1$s to %2$s",e,r);case"NEW":return Object(O.sprintf)("click to remove new assignment for %1$s from %2$s",e,r);case"OLD":return Object(O.sprintf)("click to remove %1$s from %2$s",e,r);case"REMOVED":return Object(O.sprintf)("click to reassign %1$s to %2$s",e,r)}}),[n,t,o,u]);return Object(x.jsx)(T.Button,{className:"ee-tam-relation-btn",icon:s,margin:"auto",onClick:c,tooltip:l,variant:"link"})},dn=n(111),fn=function(e){var t=e.datetime,n=Object(pe.getDatetimeBackgroundColorClassName)(t),r=be()("date-stripe",n),i=Object(m.useTimeZoneTime)().formatForSite,a=t.startDate;return a instanceof Date?a=i(a,w.LOCALIZED_DATE_SHORT_FORMAT):a&&(a=i(Object(dn.a)(t.startDate),w.LOCALIZED_DATE_SHORT_FORMAT)),Object(x.jsxs)("div",{className:"date-cell-content",children:[Object(x.jsx)("div",{className:r}),Object(x.jsx)("div",{className:"ee-focus-priority-8 date-cell-content__id",children:"".concat(Object(O.__)("ID"),": ").concat(t.dbId)}),Object(x.jsx)("div",{className:"ee-focus-priority-5 date-cell-content__name",children:t.name}),Object(x.jsx)("div",{className:"ee-focus-priority-6",children:a})]})},bn=function(){var e=Object(nn.b)().hasNoAssignedTickets;return Object(j.useCallback)((function(t){return e({datetimeId:t.id})?"no-assignments":""}),[e])},pn=function(){var e=Object(nn.b)().hasNoAssignedDates;return Object(j.useCallback)((function(t){return e({ticketId:t.id})?"no-assignments":""}),[e])},vn=function(e){var t=e.datetimes,n=e.tickets,r=Object(nn.b)().getAssignmentStatus,i=bn(),a=pn();return Object(j.useMemo)((function(){return t.map((function(e){var t={className:"ee-rspnsv-table-column-micro date-cell",key:"datetime",value:Object(x.jsx)(fn,{datetime:e})},o=n.map((function(t){var n=r({datetimeId:e.id,ticketId:t.id}),i=n&&"".concat(n.toLowerCase(),"-assignment");return{className:be()("relation-cell",i,a(t)),key:t.id,size:"huge",textAlign:"center",value:Object(x.jsx)(ln,{datetime:e,ticket:t})}}));return{cells:[t].concat(Object(on.a)(o)),className:{bodyRowClassName:"ee-ticket-assignments-manager-table-body-row"},rowClassName:i(e),key:e.id,primary:!0,type:"row"}}))}),[t,r,a,i,n])},hn="MMM dd yyyy",jn=function(e){var t=e.ticket,n=Object(pe.getTicketBackgroundColorClassName)(t),r=Object(m.useTimeZoneTime)().formatForSite,i=t.startDate;i instanceof Date?i=r(i,hn):i&&(i=r(Object(dn.a)(t.startDate),hn));var a=be()(n,"header-cell-content__after");return Object(x.jsxs)("div",{className:"header-cell-content__wrapper",children:[Object(x.jsxs)("div",{className:"header-cell-content",children:[Object(x.jsx)("div",{className:"ee-focus-priority-6 header-cell-content__id",children:"".concat(Object(O.__)("ID"),": ").concat(t.dbId)}),Object(x.jsx)("div",{className:"ee-focus-priority-5 header-cell-content__name",children:t.name}),Object(x.jsx)("div",{className:"ee-focus-priority-7 header-cell-content__price",children:Object(x.jsx)(y.CurrencyDisplay,{value:t.price||0})})]}),Object(x.jsx)("div",{className:a,children:i})]})},On={key:"empty",size:"huge",value:Object(x.jsxs)("div",{children:[Object(x.jsx)("h3",{children:Object(O.__)("Assignments")}),Object(x.jsx)("p",{children:Object(O.__)("Event Dates are listed below")}),Object(x.jsx)("p",{children:Object(O.__)("Tickets are listed along the top")}),Object(x.jsx)("p",{children:Object(O.__)("Click the cell buttons to toggle assigments")})]})},mn=function(e){var t=pn();return Object(j.useMemo)((function(){var n=e.map((function(e){return{className:t(e),key:e.id,size:"huge",value:Object(x.jsx)(jn,{ticket:e})}}));return[{cells:[On].concat(Object(on.a)(n)),key:"ee-ticket-assignments-manager-table-header-row",primary:!0,type:"row"}]}),[t,e])},yn={isScrollable:!0,tableId:"ee-ticket-assignments-manager-table",tableCaption:Object(O.__)("Ticket Assignment Manager")},gn={tableClassName:"ee-ticket-assignments-manager"},_n=function(e){var t=e.datetimes,n=e.tickets,r=vn({datetimes:t,tickets:n}),i=mn(n);return Object(x.jsx)(T.ResponsiveTable,{bodyRows:r,className:gn,headerRows:i,metaData:yn})},xn=n(286),kn=function(){var e=Object(nn.b)().getData;return Object(x.jsx)(T.DebugInfo,{data:e()})},Tn=function(){var e=Object(nn.d)(),t=Object(nn.b)();return Object(x.jsxs)(x.Fragment,{children:[Object(x.jsx)(xn.FilterBar,{}),Object(x.jsx)(an,{dataState:t}),Object(x.jsx)(_n,Object(g.a)({},e)),Object(x.jsx)(kn,{})]})},wn={icons:[{className:"old-assignment",description:Object(O.__)("existing relation"),icon:un("OLD")},{className:"removed-assignment",description:Object(O.__)("remove existing relation"),icon:un("REMOVED")},{className:"new-assignment",description:Object(O.__)("add new relation"),icon:un("NEW")},{className:"no-assignments",description:Object(O.__)("invalid relation"),icon:un()},{description:Object(O.__)("no relation"),icon:un()}]},En=n(792),Dn=function(e){var t=Object(nn.b)(),n=t.hasOrphanEntities,r=t.getData,i=Object(j.useState)(!1),a=Object(st.a)(i,2),o=a[0],c=a[1],s=n(),u=Object(j.useCallback)(function(){var t=Object(zt.a)(Vt.a.mark((function t(n){return Vt.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n.preventDefault(),c(!0),t.next=4,e(r());case 4:c(!1);case 5:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),[r,e]);return Object(j.useMemo)((function(){return{buttonText:Object(O.__)("Submit"),buttonType:T.ButtonType.PRIMARY,icon:En.a,isDisabled:s,isLoading:o,onClick:u,type:"submit"}}),[s,o,u])},Cn=n(280),Sn=function(e){var t=e.onCloseModal,n=e.onSubmit,r=e.title,i=Object(nn.b)(),a=i.hasOrphanEntities,o=i.isDirty,c=a(),s=Dn(n),u=Object(j.useContext)(Cn.a),l=Object(j.useMemo)((function(){return u.entity?"ticket assignment modal for datetime ".concat(u.entity.name):""}),[u]),d=Object(j.useMemo)((function(){return{modalContent:{"aria-label":l}}}),[l]);return Object(x.jsxs)(T.ModalWithAlert,{bodyClassName:"ee-ticket-assignments-manager__body",className:"ee-ticket-assignments-manager",isOpen:!0,isSubmitDisabled:c,onClose:t,onCancel:t,submitButtonProps:s,showAlertOnClose:o||c,title:r||Object(O.__)("Ticket Assignment Manager"),ariaAttributes:d,children:[Object(x.jsx)(Tn,{}),Object(x.jsx)(T.CollapsibleLegend,{direction:"row",legendConfig:wn})]})},Fn=n(377),In=function(e){var t=Object(m.useRelations)().getData,n=Object(j.useState)(!1),r=Object(st.a)(n,2),i=r[0],a=r[1],o=Object(u.useDefaultTicketIds)(),c=Object(j.useCallback)((function(){for(var e=t(),n=Object(g.a)(Object(g.a)({},e),{},{tickets:yt.omit(o,e.tickets||{})}),r=0,i=Object.entries(yt.pick(Fn.a,n));r2?o-2:0),u=2;u=0;--a){var o=this.tryEntries[a],c=o.completion;if("root"===o.tryLoc)return i("end");if(o.tryLoc<=this.prev){var s=r.call(o,"catchLoc"),u=r.call(o,"finallyLoc");if(s&&u){if(this.prev=0;--n){var i=this.tryEntries[n];if(i.tryLoc<=this.prev&&r.call(i,"finallyLoc")&&this.prev=0;--t){var n=this.tryEntries[t];if(n.finallyLoc===e)return this.complete(n.completion,n.afterLoc),E(n),v}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var n=this.tryEntries[t];if(n.tryLoc===e){var r=n.completion;if("throw"===r.type){var i=r.arg;E(n)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(e,n,r){return this.delegate={iterator:C(e),resultName:n,nextLoc:r},"next"===this.method&&(this.arg=t),v}},e}(e.exports);try{regeneratorRuntime=r}catch(i){Function("r","regeneratorRuntime = r")(r)}},175:function(e,t){e.exports=window.eventespresso.toaster},1772:function(e,t,n){"use strict";var r=n(2),i=n(22),a=n(1);t.a=Object(i.a)((function(e){return Object(a.jsx)("svg",Object(r.a)(Object(r.a)({viewBox:"64 64 896 896","data-icon":"profile",fill:"currentColor","aria-hidden":"true",height:"1.5em",width:"1.5em",className:"ee-svg--profile-outlined"},e),{},{children:Object(a.jsx)("path",{d:"M880 112H144c-17.7 0-32 14.3-32 32v736c0 17.7 14.3 32 32 32h736c17.7 0 32-14.3 32-32V144c0-17.7-14.3-32-32-32zm-40 728H184V184h656v656zM492 400h184c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8H492c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8zm0 144h184c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8H492c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8zm0 144h184c4.4 0 8-3.6 8-8v-48c0-4.4-3.6-8-8-8H492c-4.4 0-8 3.6-8 8v48c0 4.4 3.6 8 8 8zM340 368a40 40 0 1080 0 40 40 0 10-80 0zm0 144a40 40 0 1080 0 40 40 0 10-80 0zm0 144a40 40 0 1080 0 40 40 0 10-80 0z"})}))}),"profile-outlined")},1773:function(e,t,n){"use strict";var r=n(2),i=n(22),a=n(1);t.a=Object(i.a)((function(e){return Object(a.jsx)("svg",Object(r.a)(Object(r.a)({"data-icon":"control",fill:"currentColor","aria-hidden":"true",height:"1.5em",width:"1.5em",viewBox:"64 64 896 896",className:"ee-svg--control-outlined"},e),{},{children:Object(a.jsx)("path",{d:"M880 112H144c-17.7 0-32 14.3-32 32v736c0 17.7 14.3 32 32 32h736c17.7 0 32-14.3 32-32V144c0-17.7-14.3-32-32-32zm-40 728H184V184h656v656zM340 683v77c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8v-77c-10.1 3.3-20.8 5-32 5s-21.9-1.8-32-5zm64-198V264c0-4.4-3.6-8-8-8h-48c-4.4 0-8 3.6-8 8v221c10.1-3.3 20.8-5 32-5s21.9 1.8 32 5zm-64 198c10.1 3.3 20.8 5 32 5s21.9-1.8 32-5c41.8-13.5 72-52.7 72-99s-30.2-85.5-72-99c-10.1-3.3-20.8-5-32-5s-21.9 1.8-32 5c-41.8 13.5-72 52.7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 .5-1.6.8l-.6.3c-.7.3-1.3.6-2 .8-.7.3-1.4.5-2.1.7-.2.1-.4.1-.6.2-.6.2-1.1.3-1.7.4-.2 0-.3.1-.5.1-.7.2-1.5.3-2.2.4-.2 0-.3 0-.5.1-.6.1-1.2.1-1.8.2h-.6c-.8 0-1.5.1-2.3.1s-1.5 0-2.3-.1h-.6c-.6 0-1.2-.1-1.8-.2-.2 0-.3 0-.5-.1-.7-.1-1.5-.2-2.2-.4-.2 0-.3-.1-.5-.1-.6-.1-1.2-.3-1.7-.4-.2-.1-.4-.1-.6-.2-.7-.2-1.4-.4-2.1-.7-.7-.2-1.3-.5-2-.8l-.6-.3c-.5-.2-1.1-.5-1.6-.8-.1-.1-.3-.1-.4-.2-.6-.3-1.3-.7-1.9-1.1-.1-.1-.3-.2-.4-.3-.5-.3-1-.6-1.4-1-.2-.1-.3-.2-.5-.3-.6-.4-1.2-.9-1.7-1.3s-1.1-.9-1.6-1.4l-.4-.4-1.2-1.2-.3-.3c-.5-.5-1-1.1-1.4-1.6-.1-.1-.2-.3-.3-.4-.4-.4-.7-.9-1-1.4-.1-.2-.2-.3-.3-.5l-1.2-1.8v-.1c-.4-.6-.7-1.2-1-1.8-2.6-5-4.1-10.7-4.1-16.7s1.5-11.7 4.1-16.7z"})}))}),"control-outlined")},178:function(e,t,n){"use strict";var r=n(1261);n.d(t,"useDataState",(function(){return r.a}));n(537);var i=n(1410);n.d(t,"useDataStateManager",(function(){return i.a}));var a=n(1262);n.d(t,"useSubmitForm",(function(){return a.a}));n(1263)},18:function(e,t){e.exports=window.eventespresso.data},2:function(e,t,n){"use strict";n.d(t,"a",(function(){return a}));var r=n(14);function i(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 a(e){for(var t=1;t1&&void 0!==arguments[1]?arguments[1]:"",n=function(n){var a=n.noMargin,s=n.size,u=Object(i.a)(n,["noMargin","size"]),l=o()("ee-svg",s&&"ee-icon--".concat(s),a&&"ee-icon--no-margin",t&&"ee-svg--".concat(t),u.className);return Object(c.jsx)(e,Object(r.a)(Object(r.a)({},u),{},{className:l}))};return n}},222:function(e,t,n){"use strict";n.d(t,"c",(function(){return Oe})),n.d(t,"a",(function(){return xe})),n.d(t,"b",(function(){return Ve}));var r,i,a=n(31),o=n(37),c=n(47);try{r=Map}catch(He){}try{i=Set}catch(He){}function s(e,t,n){if(!e||"object"!==typeof e||"function"===typeof e)return e;if(e.nodeType&&"cloneNode"in e)return e.cloneNode(!0);if(e instanceof Date)return new Date(e.getTime());if(e instanceof RegExp)return new RegExp(e);if(Array.isArray(e))return e.map(u);if(r&&e instanceof r)return new Map(Array.from(e.entries()));if(i&&e instanceof i)return new Set(Array.from(e.values()));if(e instanceof Object){t.push(e);var a=Object.create(e);for(var o in n.push(a),e){var c=t.findIndex((function(t){return t===e[o]}));a[o]=c>-1?n[c]:s(e[o],t,n)}return a}return e}function u(e){return s(e,[],[])}var l=Object.prototype.toString,d=Error.prototype.toString,f=RegExp.prototype.toString,b="undefined"!==typeof Symbol?Symbol.prototype.toString:function(){return""},p=/^Symbol\((.*)\)(.*)$/;function v(e){return e!=+e?"NaN":0===e&&1/e<0?"-0":""+e}function h(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(null==e||!0===e||!1===e)return""+e;var n=typeof e;if("number"===n)return v(e);if("string"===n)return t?'"'.concat(e,'"'):e;if("function"===n)return"[Function "+(e.name||"anonymous")+"]";if("symbol"===n)return b.call(e).replace(p,"Symbol($1)");var r=l.call(e).slice(8,-1);return"Date"===r?isNaN(e.getTime())?""+e:e.toISOString(e):"Error"===r||e instanceof Error?"["+d.call(e)+"]":"RegExp"===r?f.call(e):null}function j(e,t){var n=h(e,t);return null!==n?n:JSON.stringify(e,(function(e,n){var r=h(this[e],t);return null!==r?r:n}),2)}var O={default:"${path} is invalid",required:"${path} is a required field",oneOf:"${path} must be one of the following values: ${values}",notOneOf:"${path} must not be one of the following values: ${values}",notType:function(e){var t=e.path,n=e.type,r=e.value,i=e.originalValue,a=null!=i&&i!==r,o="".concat(t," must be a `").concat(n,"` type, ")+"but the final value was: `".concat(j(r,!0),"`")+(a?" (cast from the value `".concat(j(i,!0),"`)."):".");return null===r&&(o+='\n If "null" is intended as an empty value be sure to mark the schema as `.nullable()`'),o},defined:"${path} must be defined"},m={length:"${path} must be exactly ${length} characters",min:"${path} must be at least ${min} characters",max:"${path} must be at most ${max} characters",matches:'${path} must match the following: "${regex}"',email:"${path} must be a valid email",url:"${path} must be a valid URL",uuid:"${path} must be a valid UUID",trim:"${path} must be a trimmed string",lowercase:"${path} must be a lowercase string",uppercase:"${path} must be a upper case string"},y={min:"${path} must be greater than or equal to ${min}",max:"${path} must be less than or equal to ${max}",lessThan:"${path} must be less than ${less}",moreThan:"${path} must be greater than ${more}",positive:"${path} must be a positive number",negative:"${path} must be a negative number",integer:"${path} must be an integer"},g={min:"${path} field must be later than ${min}",max:"${path} field must be at earlier than ${max}"},_={isValue:"${path} field must be ${value}"},x={noUnknown:"${path} field has unspecified keys: ${unknown}"},k={min:"${path} field must have at least ${min} items",max:"${path} field must have less than or equal to ${max} items",length:"${path} must have ${length} items"},T=(Object.assign(Object.create(null),{mixed:O,string:m,number:y,date:g,object:x,array:k,boolean:_}),n(151)),w=n.n(T),E=function(e){return e&&e.__isYupSchema__},D=function(){function e(t,n){if(Object(o.a)(this,e),this.fn=void 0,this.refs=t,this.refs=t,"function"!==typeof n){if(!w()(n,"is"))throw new TypeError("`is:` is required for `when()` conditions");if(!n.then&&!n.otherwise)throw new TypeError("either `then:` or `otherwise:` is required for `when()` conditions");var r=n.is,i=n.then,a=n.otherwise,c="function"===typeof r?r:function(){for(var e=arguments.length,t=new Array(e),n=0;n1?"".concat(s.errors.length," errors occurred"):s.errors[0],Error.captureStackTrace&&Error.captureStackTrace(Object(C.a)(s),n),s}return Object(c.a)(n,null,[{key:"formatError",value:function(e,t){var n=t.label||t.path||"this";return n!==t.path&&(t=A({},t,{path:n})),"string"===typeof e?e.replace(M,(function(e,n){return j(t[n])})):"function"===typeof e?e(t):e}},{key:"isError",value:function(e){return e&&"ValidationError"===e.name}}]),n}(Object(I.a)(Error));function L(e,t){var n=e.endEarly,r=e.tests,i=e.args,o=e.value,c=e.errors,s=e.sort,u=e.path,l=function(e){var t=!1;return function(){t||(t=!0,e.apply(void 0,arguments))}}(t),d=r.length,f=[];if(c=c||[],!d)return c.length?l(new P(c,o,u)):l(null,o);for(var b=0;b1&&void 0!==arguments[1]?arguments[1]:{};if(Object(o.a)(this,e),this.key=void 0,this.isContext=void 0,this.isValue=void 0,this.isSibling=void 0,this.path=void 0,this.getter=void 0,this.map=void 0,"string"!==typeof t)throw new TypeError("ref must be a string, got: "+t);if(this.key=t.trim(),""===t)throw new TypeError("ref must be a non-empty string");this.isContext=this.key[0]===V,this.isValue=this.key[0]===$,this.isSibling=!this.isContext&&!this.isValue;var r=this.isContext?V:this.isValue?$:"";this.path=this.key.slice(r.length),this.getter=this.path&&Object(B.getter)(this.path,!0),this.map=n.map}return Object(c.a)(e,[{key:"getValue",value:function(e,t,n){var r=this.isContext?n:this.isValue?e:t;return this.getter&&(r=this.getter(r||{})),this.map&&(r=this.map(r)),r}},{key:"cast",value:function(e,t){return this.getValue(e,null==t?void 0:t.parent,null==t?void 0:t.context)}},{key:"resolve",value:function(){return this}},{key:"describe",value:function(){return{type:"ref",key:this.key}}},{key:"toString",value:function(){return"Ref(".concat(this.key,")")}}],[{key:"isRef",value:function(e){return e&&e.__isYupRef}}]),e}();function H(){return(H=Object.assign||function(e){for(var t=1;t=0||(i[n]=e[n]);return i}(t,["value","path","label","options","originalValue","sync"]),d=e.name,f=e.test,b=e.params,p=e.message,v=c.parent,h=c.context;function j(e){return U.isRef(e)?e.getValue(r,v,h):e}function O(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=z()(H({value:r,originalValue:s,label:o,path:e.path||a},b,e.params),j),n=new P(P.formatError(e.message||p,t),r,t.path,e.type||d);return n.params=t,n}var m=H({path:a,parent:v,type:d,createError:O,resolve:j,options:c,originalValue:s},l);if(u){var y;try{var g;if("function"===typeof(null==(g=y=f.call(m,r,m))?void 0:g.then))throw new Error('Validation test of type: "'.concat(m.type,'" returned a Promise during a synchronous validate. ')+"This test will finish after the validate call has returned")}catch(_){return void n(_)}P.isError(y)?n(y):y?n(null,y):n(O())}else try{Promise.resolve(f.call(m,r,m)).then((function(e){P.isError(e)?n(e):e?n(null,e):n(O())})).catch(n)}catch(_){n(_)}}return t.OPTIONS=e,t}U.prototype.__isYupRef=!0;var W=function(e){return e.substr(0,e.length-1).substr(1)};function q(e,t,n){var r,i,a,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:n;return t?(Object(B.forEach)(t,(function(c,s,u){var l=s?W(c):c;if((e=e.resolve({context:o,parent:r,value:n})).innerType){var d=u?parseInt(l,10):0;if(n&&d>=n.length)throw new Error("Yup.reach cannot resolve an array item at index: ".concat(c,", in the path: ").concat(t,". ")+"because there is no value at that index. ");r=n,n=n&&n[d],e=e.innerType}if(!u){if(!e.fields||!e.fields[l])throw new Error("The schema does not contain the path: ".concat(t,". ")+"(failed at: ".concat(a,' which is a type: "').concat(e._type,'")'));r=n,n=n&&n[l],e=e.fields[l]}i=l,a=s?"["+c+"]":"."+c})),{schema:e,parent:r,parentPath:i}):{parent:r,parentPath:t,schema:e}}var K=n(9),Y=n(80),Z=function(){function e(){Object(o.a)(this,e),this.list=void 0,this.refs=void 0,this.list=new Set,this.refs=new Map}return Object(c.a)(e,[{key:"size",get:function(){return this.list.size+this.refs.size}},{key:"describe",value:function(){var e,t=[],n=Object(Y.a)(this.list);try{for(n.s();!(e=n.n()).done;){var r=e.value;t.push(r)}}catch(c){n.e(c)}finally{n.f()}var i,a=Object(Y.a)(this.refs);try{for(a.s();!(i=a.n()).done;){var o=Object(K.a)(i.value,2)[1];t.push(o.describe())}}catch(c){a.e(c)}finally{a.f()}return t}},{key:"toArray",value:function(){return Array.from(this.list).concat(Array.from(this.refs.values()))}},{key:"resolveAll",value:function(e){return this.toArray().reduce((function(t,n){return t.concat(U.isRef(n)?e(n):n)}),[])}},{key:"add",value:function(e){U.isRef(e)?this.refs.set(e.key,e):this.list.add(e)}},{key:"delete",value:function(e){U.isRef(e)?this.refs.delete(e.key):this.list.delete(e)}},{key:"clone",value:function(){var t=new e;return t.list=new Set(this.list),t.refs=new Map(this.refs),t}},{key:"merge",value:function(e,t){var n=this.clone();return e.list.forEach((function(e){return n.add(e)})),e.refs.forEach((function(e){return n.add(e)})),t.list.forEach((function(e){return n.delete(e)})),t.refs.forEach((function(e){return n.delete(e)})),n}}]),e}();function Q(){return(Q=Object.assign||function(e){for(var t=1;t1&&void 0!==arguments[1]?arguments[1]:{},n=this.resolve(Q({value:e},t)),r=n._cast(e,t);if(void 0!==e&&!1!==t.assert&&!0!==n.isType(r)){var i=j(e),a=j(r);throw new TypeError("The value of ".concat(t.path||"field"," could not be cast to a value ")+'that satisfies the schema type: "'.concat(n._type,'". \n\n')+"attempted value: ".concat(i," \n")+(a!==i?"result of cast: ".concat(a):""))}return r}},{key:"_cast",value:function(e,t){var n=this,r=void 0===e?e:this.transforms.reduce((function(t,r){return r.call(n,t,e,n)}),e);return void 0===r&&(r=this.getDefault()),r}},{key:"_validate",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2?arguments[2]:void 0,i=n.sync,a=n.path,o=n.from,c=void 0===o?[]:o,s=n.originalValue,u=void 0===s?e:s,l=n.strict,d=void 0===l?this.spec.strict:l,f=n.abortEarly,b=void 0===f?this.spec.abortEarly:f,p=e;d||(p=this._cast(p,Q({assert:!1},n)));var v={value:p,path:a,options:n,originalValue:u,schema:this,label:this.spec.label,sync:i,from:c},h=[];this._typeError&&h.push(this._typeError);var j=[];this._whitelistError&&j.push(this._whitelistError),this._blacklistError&&j.push(this._blacklistError),L({args:v,value:p,path:a,sync:i,tests:h,endEarly:b},(function(e){e?r(e,p):L({tests:t.tests.concat(j),args:v,path:a,sync:i,value:p,endEarly:b},r)}))}},{key:"validate",value:function(e,t,n){var r=this.resolve(Q({},t,{value:e}));return"function"===typeof n?r._validate(e,t,n):new Promise((function(n,i){return r._validate(e,t,(function(e,t){e?i(e):n(t)}))}))}},{key:"validateSync",value:function(e,t){var n;return this.resolve(Q({},t,{value:e}))._validate(e,Q({},t,{sync:!0}),(function(e,t){if(e)throw e;n=t})),n}},{key:"isValid",value:function(e,t){return this.validate(e,t).then((function(){return!0}),(function(e){if(P.isError(e))return!1;throw e}))}},{key:"isValidSync",value:function(e,t){try{return this.validateSync(e,t),!0}catch(n){if(P.isError(n))return!1;throw n}}},{key:"_getDefault",value:function(){var e=this.spec.default;return null==e?e:"function"===typeof e?e.call(this):u(e)}},{key:"getDefault",value:function(e){return this.resolve(e||{})._getDefault()}},{key:"default",value:function(e){if(0===arguments.length)return this._getDefault();var t=this.clone({default:e});return t}},{key:"strict",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],t=this.clone();return t.spec.strict=e,t}},{key:"_isPresent",value:function(e){return null!=e}},{key:"defined",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:O.defined;return this.test({message:e,name:"defined",exclusive:!0,test:function(e){return void 0!==e}})}},{key:"required",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:O.required;return this.clone({presence:"required"}).withMutation((function(t){return t.test({message:e,name:"required",exclusive:!0,test:function(e){return this.schema._isPresent(e)}})}))}},{key:"notRequired",value:function(){var e=this.clone({presence:"optional"});return e.tests=e.tests.filter((function(e){return"required"!==e.OPTIONS.name})),e}},{key:"nullable",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],t=this.clone({nullable:!1!==e});return t}},{key:"transform",value:function(e){var t=this.clone();return t.transforms.push(e),t}},{key:"test",value:function(){var e;if(void 0===(e=1===arguments.length?"function"===typeof(arguments.length<=0?void 0:arguments[0])?{test:arguments.length<=0?void 0:arguments[0]}:arguments.length<=0?void 0:arguments[0]:2===arguments.length?{name:arguments.length<=0?void 0:arguments[0],test:arguments.length<=1?void 0:arguments[1]}:{name:arguments.length<=0?void 0:arguments[0],message:arguments.length<=1?void 0:arguments[1],test:arguments.length<=2?void 0:arguments[2]}).message&&(e.message=O.default),"function"!==typeof e.test)throw new TypeError("`test` is a required parameters");var t=this.clone(),n=G(e),r=e.exclusive||e.name&&!0===t.exclusiveTests[e.name];if(e.exclusive&&!e.name)throw new TypeError("Exclusive tests must provide a unique `name` identifying the test");return e.name&&(t.exclusiveTests[e.name]=!!e.exclusive),t.tests=t.tests.filter((function(t){if(t.OPTIONS.name===e.name){if(r)return!1;if(t.OPTIONS.test===n.OPTIONS.test)return!1}return!0})),t.tests.push(n),t}},{key:"when",value:function(e,t){Array.isArray(e)||"string"===typeof e||(t=e,e=".");var n=this.clone(),r=N(e).map((function(e){return new U(e)}));return r.forEach((function(e){e.isSibling&&n.deps.push(e.key)})),n.conditions.push(new D(r,t)),n}},{key:"typeError",value:function(e){var t=this.clone();return t._typeError=G({message:e,name:"typeError",test:function(e){return!(void 0!==e&&!this.schema.isType(e))||this.createError({params:{type:this.schema._type}})}}),t}},{key:"oneOf",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:O.oneOf,n=this.clone();return e.forEach((function(e){n._whitelist.add(e),n._blacklist.delete(e)})),n._whitelistError=G({message:t,name:"oneOf",test:function(e){if(void 0===e)return!0;var t=this.schema._whitelist,n=t.resolveAll(this.resolve);return!!n.includes(e)||this.createError({params:{values:t.toArray().join(", "),resolved:n}})}}),n}},{key:"notOneOf",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:O.notOneOf,n=this.clone();return e.forEach((function(e){n._blacklist.add(e),n._whitelist.delete(e)})),n._blacklistError=G({message:t,name:"notOneOf",test:function(e){var t=this.schema._blacklist,n=t.resolveAll(this.resolve);return!n.includes(e)||this.createError({params:{values:t.toArray().join(", "),resolved:n}})}}),n}},{key:"strip",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],t=this.clone();return t.spec.strip=e,t}},{key:"describe",value:function(){var e=this.clone(),t=e.spec,n=t.label;return{meta:t.meta,label:n,type:e.type,oneOf:e._whitelist.describe(),notOneOf:e._blacklist.describe(),tests:e.tests.map((function(e){return{name:e.OPTIONS.name,params:e.OPTIONS.params}})).filter((function(e,t,n){return n.findIndex((function(t){return t.name===e.name}))===t}))}}}]),e}();J.prototype.__isYupSchema__=!0;for(var X=function(){var e=te[ee];J.prototype["".concat(e,"At")]=function(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=q(this,t,n,r.context),a=i.parent,o=i.parentPath,c=i.schema;return c[e](a&&a[o],Q({},r,{parent:a,path:t}))}},ee=0,te=["validate","validateSync"];ee0&&void 0!==arguments[0]?arguments[0]:_.isValue;return this.test({message:e,name:"is-value",exclusive:!0,params:{value:"true"},test:function(e){return ue(e)||!0===e}})}},{key:"isFalse",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:_.isValue;return this.test({message:e,name:"is-value",exclusive:!0,params:{value:"false"},test:function(e){return ue(e)||!1===e}})}}]),n}(J);le.prototype;var de=n(59),fe=n(46),be=/^((([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+(\.([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+)*)|((\x22)((((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(([\x01-\x08\x0b\x0c\x0e-\x1f\x7f]|\x21|[\x23-\x5b]|[\x5d-\x7e]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(\\([\x01-\x09\x0b\x0c\x0d-\x7f]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]))))*(((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(\x22)))@((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))$/i,pe=/^((https?|ftp):)?\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,ve=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,he=function(e){return ue(e)||e===e.trim()},je={}.toString();function Oe(){return new me}var me=function(e){Object(S.a)(n,e);var t=Object(F.a)(n);function n(){var e;return Object(o.a)(this,n),(e=t.call(this,{type:"string"})).withMutation((function(){e.transform((function(e){if(this.isType(e))return e;if(Array.isArray(e))return e;var t=null!=e&&e.toString?e.toString():e;return t===je?e:t}))})),e}return Object(c.a)(n,[{key:"_typeCheck",value:function(e){return e instanceof String&&(e=e.valueOf()),"string"===typeof e}},{key:"_isPresent",value:function(e){return Object(de.a)(Object(fe.a)(n.prototype),"_isPresent",this).call(this,e)&&!!e.length}},{key:"length",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:m.length;return this.test({message:t,name:"length",exclusive:!0,params:{length:e},test:function(t){return ue(t)||t.length===this.resolve(e)}})}},{key:"min",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:m.min;return this.test({message:t,name:"min",exclusive:!0,params:{min:e},test:function(t){return ue(t)||t.length>=this.resolve(e)}})}},{key:"max",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:m.max;return this.test({name:"max",exclusive:!0,message:t,params:{max:e},test:function(t){return ue(t)||t.length<=this.resolve(e)}})}},{key:"matches",value:function(e,t){var n,r,i=!1;if(t)if("object"===typeof t){var a=t.excludeEmptyString;i=void 0!==a&&a,n=t.message,r=t.name}else n=t;return this.test({name:r||"matches",message:n||m.matches,params:{regex:e},test:function(t){return ue(t)||""===t&&i||-1!==t.search(e)}})}},{key:"email",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:m.email;return this.matches(be,{name:"email",message:e,excludeEmptyString:!0})}},{key:"url",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:m.url;return this.matches(pe,{name:"url",message:e,excludeEmptyString:!0})}},{key:"uuid",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:m.uuid;return this.matches(ve,{name:"uuid",message:e,excludeEmptyString:!1})}},{key:"ensure",value:function(){return this.default("").transform((function(e){return null===e?"":e}))}},{key:"trim",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:m.trim;return this.transform((function(e){return null!=e?e.trim():e})).test({message:e,name:"trim",test:he})}},{key:"lowercase",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:m.lowercase;return this.transform((function(e){return ue(e)?e:e.toLowerCase()})).test({message:e,name:"string_case",exclusive:!0,test:function(e){return ue(e)||e===e.toLowerCase()}})}},{key:"uppercase",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:m.uppercase;return this.transform((function(e){return ue(e)?e:e.toUpperCase()})).test({message:e,name:"string_case",exclusive:!0,test:function(e){return ue(e)||e===e.toUpperCase()}})}}]),n}(J);Oe.prototype=me.prototype;var ye=function(e){Object(S.a)(n,e);var t=Object(F.a)(n);function n(){var e;return Object(o.a)(this,n),(e=t.call(this,{type:"number"})).withMutation((function(){e.transform((function(e){var t=e;if("string"===typeof t){if(""===(t=t.replace(/\s/g,"")))return NaN;t=+t}return this.isType(t)?t:parseFloat(t)}))})),e}return Object(c.a)(n,[{key:"_typeCheck",value:function(e){return e instanceof Number&&(e=e.valueOf()),"number"===typeof e&&!function(e){return e!=+e}(e)}},{key:"min",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:y.min;return this.test({message:t,name:"min",exclusive:!0,params:{min:e},test:function(t){return ue(t)||t>=this.resolve(e)}})}},{key:"max",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:y.max;return this.test({message:t,name:"max",exclusive:!0,params:{max:e},test:function(t){return ue(t)||t<=this.resolve(e)}})}},{key:"lessThan",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:y.lessThan;return this.test({message:t,name:"max",exclusive:!0,params:{less:e},test:function(t){return ue(t)||t1&&void 0!==arguments[1]?arguments[1]:y.moreThan;return this.test({message:t,name:"min",exclusive:!0,params:{more:e},test:function(t){return ue(t)||t>this.resolve(e)}})}},{key:"positive",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:y.positive;return this.moreThan(0,e)}},{key:"negative",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:y.negative;return this.lessThan(0,e)}},{key:"integer",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:y.integer;return this.test({name:"integer",message:e,test:function(e){return ue(e)||Number.isInteger(e)}})}},{key:"truncate",value:function(){return this.transform((function(e){return ue(e)?e:0|e}))}},{key:"round",value:function(e){var t,n=["ceil","floor","round","trunc"];if("trunc"===(e=(null==(t=e)?void 0:t.toLowerCase())||"round"))return this.truncate();if(-1===n.indexOf(e.toLowerCase()))throw new TypeError("Only valid options for round() are: "+n.join(", "));return this.transform((function(t){return ue(t)?t:Math[e](t)}))}}]),n}(J);ye.prototype;var ge=/^(\d{4}|[+\-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,\.](\d{1,}))?)?(?:(Z)|([+\-])(\d{2})(?::?(\d{2}))?)?)?$/;var _e=new Date("");function xe(){return new ke}var ke=function(e){Object(S.a)(n,e);var t=Object(F.a)(n);function n(){var e;return Object(o.a)(this,n),(e=t.call(this,{type:"date"})).withMutation((function(){e.transform((function(e){return this.isType(e)?e:(e=function(e){var t,n,r=[1,4,5,6,7,10,11],i=0;if(n=ge.exec(e)){for(var a,o=0;a=r[o];++o)n[a]=+n[a]||0;n[2]=(+n[2]||1)-1,n[3]=+n[3]||1,n[7]=n[7]?String(n[7]).substr(0,3):0,void 0!==n[8]&&""!==n[8]||void 0!==n[9]&&""!==n[9]?("Z"!==n[8]&&void 0!==n[9]&&(i=60*n[10]+n[11],"+"===n[9]&&(i=0-i)),t=Date.UTC(n[1],n[2],n[3],n[4],n[5]+i,n[6],n[7])):t=+new Date(n[1],n[2],n[3],n[4],n[5],n[6],n[7])}else t=Date.parse?Date.parse(e):NaN;return t}(e),isNaN(e)?_e:new Date(e))}))})),e}return Object(c.a)(n,[{key:"_typeCheck",value:function(e){return t=e,"[object Date]"===Object.prototype.toString.call(t)&&!isNaN(e.getTime());var t}},{key:"prepareParam",value:function(e,t){var n;if(U.isRef(e))n=e;else{var r=this.cast(e);if(!this._typeCheck(r))throw new TypeError("`".concat(t,"` must be a Date or a value that can be `cast()` to a Date"));n=r}return n}},{key:"min",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:g.min,n=this.prepareParam(e,"min");return this.test({message:t,name:"min",exclusive:!0,params:{min:e},test:function(e){return ue(e)||e>=this.resolve(n)}})}},{key:"max",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:g.max,n=this.prepareParam(e,"max");return this.test({message:t,name:"max",exclusive:!0,params:{max:e},test:function(e){return ue(e)||e<=this.resolve(n)}})}}]),n}(J);ke.INVALID_DATE=_e,xe.prototype=ke.prototype,xe.INVALID_DATE=_e;var Te=n(327),we=n.n(Te),Ee=n(433),De=n.n(Ee),Ce=n(434),Se=n.n(Ce),Fe=n(435),Ie=n.n(Fe);function Ne(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=[],r=new Set,i=new Set(t.map((function(e){var t=Object(K.a)(e,2),n=t[0],r=t[1];return"".concat(n,"-").concat(r)})));function a(e,t){var a=Object(B.split)(e)[0];r.add(a),i.has("".concat(t,"-").concat(a))||n.push([t,a])}var o=function(t){if(w()(e,t)){var n=e[t];r.add(t),U.isRef(n)&&n.isSibling?a(n.path,t):E(n)&&"deps"in n&&n.deps.forEach((function(e){return a(e,t)}))}};for(var c in e)o(c);return Ie.a.array(Array.from(r),n).reverse()}function Ae(e,t){var n=1/0;return e.some((function(e,r){var i;if(-1!==(null==(i=t.path)?void 0:i.indexOf(e)))return n=r,!0})),n}function Me(e){return function(t,n){return Ae(e,t)-Ae(e,n)}}function Pe(){return(Pe=Object.assign||function(e){for(var t=1;t1&&void 0!==arguments[1]?arguments[1]:{},a=Object(de.a)(Object(fe.a)(n.prototype),"_cast",this).call(this,e,i);if(void 0===a)return this.getDefault();if(!this._typeCheck(a))return a;var o,c=this.fields,s=null!=(t=i.stripUnknown)?t:this.spec.noUnknown,u=this._nodes.concat(Object.keys(a).filter((function(e){return-1===r._nodes.indexOf(e)}))),l={},d=Pe({},i,{parent:l,__validating:i.__validating||!1}),f=!1,b=Object(Y.a)(u);try{for(b.s();!(o=b.n()).done;){var p=o.value,v=c[p],h=w()(a,p);if(v){var j=void 0,O=a[p];d.path=(i.path?"".concat(i.path,"."):"")+p;var m="spec"in(v=v.resolve({value:O,context:i.context,parent:l}))?v.spec:void 0,y=null==m?void 0:m.strict;if(null==m?void 0:m.strip){f=f||p in a;continue}void 0!==(j=i.__validating&&y?a[p]:v.cast(a[p],d))&&(l[p]=j)}else h&&!s&&(l[p]=a[p]);l[p]!==a[p]&&(f=!0)}}catch(g){b.e(g)}finally{b.f()}return f?l:a}},{key:"_validate",value:function(e){var t=this,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=arguments.length>2?arguments[2]:void 0,o=[],c=r.sync,s=r.from,u=void 0===s?[]:s,l=r.originalValue,d=void 0===l?e:l,f=r.abortEarly,b=void 0===f?this.spec.abortEarly:f,p=r.recursive,v=void 0===p?this.spec.recursive:p;u=[{schema:this,value:d}].concat(Object(a.a)(u)),r.__validating=!0,r.originalValue=d,r.from=u,Object(de.a)(Object(fe.a)(n.prototype),"_validate",this).call(this,e,r,(function(e,n){if(e){if(!P.isError(e)||b)return void i(e,n);o.push(e)}if(v&&Le(n)){d=d||n;var a=t._nodes.map((function(e){return function(i,a){var o=-1===e.indexOf(".")?(r.path?"".concat(r.path,"."):"")+e:"".concat(r.path||"",'["').concat(e,'"]'),c=t.fields[e];c&&"validate"in c?c.validate(n[e],Pe({},r,{path:o,from:u,strict:!0,parent:n,originalValue:d[e]}),a):a(null)}}));L({sync:c,tests:a,value:n,errors:o,endEarly:b,sort:t._sortErrors,path:r.path},i)}else i(o[0]||null,n)}))}},{key:"clone",value:function(e){var t=Object(de.a)(Object(fe.a)(n.prototype),"clone",this).call(this,e);return t.fields=Pe({},this.fields),t._nodes=this._nodes,t._excludedEdges=this._excludedEdges,t._sortErrors=this._sortErrors,t}},{key:"concat",value:function(e){for(var t=this,r=Object(de.a)(Object(fe.a)(n.prototype),"concat",this).call(this,e),i=r.fields,a=0,o=Object.entries(this.fields);a1&&void 0!==arguments[1]?arguments[1]:[],n=this.clone(),r=Object.assign(n.fields,e);return n.fields=r,n._sortErrors=Me(Object.keys(r)),t.length&&(Array.isArray(t[0])||(t=[t]),n._excludedEdges=[].concat(Object(a.a)(n._excludedEdges),Object(a.a)(t))),n._nodes=Ne(r,n._excludedEdges),n}},{key:"pick",value:function(e){var t,n={},r=Object(Y.a)(e);try{for(r.s();!(t=r.n()).done;){var i=t.value;this.fields[i]&&(n[i]=this.fields[i])}}catch(a){r.e(a)}finally{r.f()}return this.clone().withMutation((function(e){return e.fields={},e.shape(n)}))}},{key:"omit",value:function(e){var t=this.clone(),n=t.fields;t.fields={};var r,i=Object(Y.a)(e);try{for(i.s();!(r=i.n()).done;){var a=r.value;delete n[a]}}catch(o){i.e(o)}finally{i.f()}return t.withMutation((function(){return t.shape(n)}))}},{key:"from",value:function(e,t,n){var r=Object(B.getter)(e,!0);return this.transform((function(i){if(null==i)return i;var a=i;return w()(i,e)&&(a=Pe({},i),n||delete a[e],a[t]=r(i)),a}))}},{key:"noUnknown",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:x.noUnknown;"string"===typeof e&&(t=e,e=!0);var n=this.test({name:"noUnknown",exclusive:!0,message:t,test:function(t){if(null==t)return!0;var n=Re(this.schema,t);return!e||0===n.length||this.createError({params:{unknown:n.join(", ")}})}});return n.spec.noUnknown=e,n}},{key:"unknown",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:x.noUnknown;return this.noUnknown(!e,t)}},{key:"transformKeys",value:function(e){return this.transform((function(t){return t&&Se()(t,(function(t,n){return e(n)}))}))}},{key:"camelCase",value:function(){return this.transformKeys(De.a)}},{key:"snakeCase",value:function(){return this.transformKeys(we.a)}},{key:"constantCase",value:function(){return this.transformKeys((function(e){return we()(e).toUpperCase()}))}},{key:"describe",value:function(){var e=Object(de.a)(Object(fe.a)(n.prototype),"describe",this).call(this);return e.fields=z()(this.fields,(function(e){return e.describe()})),e}}]),n}(J);function Ve(e){return new Be(e)}function $e(){return($e=Object.assign||function(e){for(var t=1;t1&&void 0!==arguments[1]?arguments[1]:{},o=arguments.length>2?arguments[2]:void 0,c=[],s=a.sync,u=a.path,l=this.innerType,d=null!=(t=a.abortEarly)?t:this.spec.abortEarly,f=null!=(r=a.recursive)?r:this.spec.recursive,b=null!=a.originalValue?a.originalValue:e;Object(de.a)(Object(fe.a)(n.prototype),"_validate",this).call(this,e,a,(function(e,t){if(e){if(!P.isError(e)||d)return void o(e,t);c.push(e)}if(f&&l&&i._typeCheck(t)){b=b||t;for(var n=new Array(t.length),r=function(e){var r=t[e],i="".concat(a.path||"","[").concat(e,"]"),o=$e({},a,{path:i,strict:!0,parent:t,index:e,originalValue:b[e]});n[e]=function(e,t){return l.validate(r,o,t)}},p=0;p1&&void 0!==arguments[1]?arguments[1]:k.length;return this.test({message:t,name:"length",exclusive:!0,params:{length:e},test:function(t){return ue(t)||t.length===this.resolve(e)}})}},{key:"min",value:function(e,t){return t=t||k.min,this.test({message:t,name:"min",exclusive:!0,params:{min:e},test:function(t){return ue(t)||t.length>=this.resolve(e)}})}},{key:"max",value:function(e,t){return t=t||k.max,this.test({message:t,name:"max",exclusive:!0,params:{max:e},test:function(t){return ue(t)||t.length<=this.resolve(e)}})}},{key:"ensure",value:function(){var e=this;return this.default((function(){return[]})).transform((function(t,n){return e._typeCheck(t)?t:null==n?[]:[].concat(n)}))}},{key:"compact",value:function(e){var t=e?function(t,n,r){return!e(t,n,r)}:function(e){return!!e};return this.transform((function(e){return null!=e?e.filter(t):e}))}},{key:"describe",value:function(){var e=Object(de.a)(Object(fe.a)(n.prototype),"describe",this).call(this);return this.innerType&&(e.innerType=this.innerType.describe()),e}},{key:"nullable",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return Object(de.a)(Object(fe.a)(n.prototype),"nullable",this).call(this,e)}},{key:"defined",value:function(){return Object(de.a)(Object(fe.a)(n.prototype),"defined",this).call(this)}},{key:"required",value:function(e){return Object(de.a)(Object(fe.a)(n.prototype),"required",this).call(this,e)}}]),n}(J);Ue.prototype},235:function(e,t){e.exports=window.eventespresso.helpers},237:function(e,t,n){"use strict";n(159)},239:function(e,t,n){var r=n(122).Symbol;e.exports=r},24:function(e,t){e.exports=window.eventespresso.services},240:function(e,t,n){var r=n(148)(Object,"create");e.exports=r},241:function(e,t,n){var r=n(650),i=n(651),a=n(652),o=n(653),c=n(654);function s(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t-1&&e%1==0&&e<=9007199254740991}},302:function(e,t,n){var r=n(666),i=n(672),a=n(676);e.exports=function(e){return a(e)?r(e):i(e)}},31:function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(39);var i=n(68),a=n(42);function o(e){return function(e){if(Array.isArray(e))return Object(r.a)(e)}(e)||Object(i.a)(e)||Object(a.a)(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}},327:function(e,t,n){var r=n(405)((function(e,t,n){return e+(n?"_":"")+t.toLowerCase()}));e.exports=r},33:function(e,t,n){"use strict";function r(e){if(null===e||!0===e||!1===e)return NaN;var t=Number(e);return isNaN(t)?t:t<0?Math.ceil(t):Math.floor(t)}n.d(t,"a",(function(){return r}))},34:function(e,t,n){e.exports=n(171)},36:function(e,t){e.exports=window.eventespresso.constants},37:function(e,t,n){"use strict";function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}n.d(t,"a",(function(){return r}))},377:function(e,t,n){"use strict";n.d(t,"a",(function(){return r}));var r=["datetimes","tickets"]},386:function(e,t,n){var r=n(387),i=n(392),a=n(132),o=n(393),c=n(301),s=n(244);e.exports=function(e,t,n){for(var u=-1,l=(t=r(t,e)).length,d=!1;++ue.length)&&(t=e.length);for(var n=0,r=new Array(t);n-1&&e%1==0&&el))return!1;var f=s.get(e),b=s.get(t);if(f&&b)return f==t&&b==e;var p=-1,v=!0,h=2&n?new r:void 0;for(s.set(e,t),s.set(t,e);++p=h?e:o.assocPath([d],v,e)}),{})},b=function(e){var t=function(e){return Object(s.sortDates)({dates:e}).reduce((function(e,t){var n=t.startDate,a=Object(c.a)(n),o=a.getFullYear(),s=a.getMonth(),u=e[o]||{};return s in u?e:(u[s]=Object(l.getMonthName)(a),Object(i.a)(Object(i.a)({},e),{},Object(r.a)({},o,u)))}),{})}(e);return Object.entries(t).map((function(e){var t=Object(a.a)(e,2),n=t[0],r=t[1];return{key:n,label:n,options:Object.entries(r).map((function(e){var t=Object(a.a)(e,2),r=t[0],i=t[1];return{key:"".concat(n,":").concat(r),label:i,value:"".concat(n,":").concat(r)}}))}}))}},46:function(e,t,n){"use strict";function r(e){return(r=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}n.d(t,"a",(function(){return r}))},461:function(e,t,n){"use strict";n.d(t,"a",(function(){return i})),n.d(t,"b",(function(){return a.a})),n.d(t,"c",(function(){return l})),n.d(t,"d",(function(){return f}));var r=n(16),i=function(){return Object(r.useEventsHandler)(),Object(r.useCacheRehydration)()},a=n(825),o=n(0),c=n(45),s=n(26),u=new c.EntityCardDetailsSubscription(r.domain).getSubscriptions,l=function(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=Object(o.useMemo)((function(){return new c.EntityCardDetailsRegistry({domain:r.domain,entityType:e,entityId:t})}),[t,e]),a=i.generateElements,l=u({entityType:n?e:null});return Object.values(l).forEach((function(n){(0,n.callback)({entityType:e,entityId:t,registry:i})})),Object(s.useMemoStringify)(a(),Object.keys(l))},d=new c.NewEntitySubscription(r.domain).getSubscriptions,f=function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=Object(o.useMemo)((function(){return new c.NewEntityOptionsRegistry({domain:r.domain,entityType:e})}),[e]),i=n.generateElements,a=d({entityType:t?e:null});return Object.values(a).forEach((function(t){(0,t.callback)({entityType:e,registry:n})})),Object(s.useMemoStringify)(i(),Object.keys(a))}},467:function(e,t,n){"use strict";var r=n(2),i=n(22),a=n(1);t.a=Object(i.a)((function(e){return Object(a.jsx)("svg",Object(r.a)(Object(r.a)({"aria-hidden":"true",fill:"currentColor",height:"1.5em",viewBox:"0 0 20 20",width:"1.5em",className:"ee-svg--trash"},e),{},{children:Object(a.jsx)("path",{d:"M12 4h3c.6 0 1 .4 1 1v1H3V5c0-.6.5-1 1-1h3c.2-1.1 1.3-2 2.5-2s2.3.9 2.5 2zM8 4h3c-.2-.6-.9-1-1.5-1S8.2 3.4 8 4zM4 7h11l-.9 10.1c0 .5-.5.9-1 .9H5.9c-.5 0-.9-.4-1-.9L4 7z"})}))}),"trash")},47:function(e,t,n){"use strict";function r(e,t){for(var n=0;n-1}},654:function(e,t,n){var r=n(242);e.exports=function(e,t){var n=this.__data__,i=r(n,e);return i<0?(++this.size,n.push([e,t])):n[i][1]=t,this}},655:function(e,t,n){var r=n(243);e.exports=function(e){var t=r(this,e).delete(e);return this.size-=t?1:0,t}},656:function(e,t){e.exports=function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}},657:function(e,t,n){var r=n(243);e.exports=function(e){return r(this,e).get(e)}},658:function(e,t,n){var r=n(243);e.exports=function(e){return r(this,e).has(e)}},659:function(e,t,n){var r=n(243);e.exports=function(e,t){var n=r(this,e),i=n.size;return n.set(e,t),this.size+=n.size==i?0:1,this}},66:function(e,t,n){"use strict";var r=Object.getOwnPropertySymbols,i=Object.prototype.hasOwnProperty,a=Object.prototype.propertyIsEnumerable;function o(e){if(null===e||void 0===e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}e.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var r={};return"abcdefghijklmnopqrst".split("").forEach((function(e){r[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},r)).join("")}catch(i){return!1}}()?Object.assign:function(e,t){for(var n,c,s=o(e),u=1;u=i?e:r(e,t,n)}},727:function(e,t){e.exports=function(e,t,n){var r=-1,i=e.length;t<0&&(t=-t>i?0:i+t),(n=n>i?i:n)<0&&(n+=i),i=t>n?0:n-t>>>0,t>>>=0;for(var a=Array(i);++r=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}n.d(t,"a",(function(){return r}))},80:function(e,t,n){"use strict";n.d(t,"a",(function(){return i}));var r=n(42);function i(e,t){var n;if("undefined"===typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=Object(r.a)(e))||t&&e&&"number"===typeof e.length){n&&(e=n);var i=0,a=function(){};return{s:a,n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:a}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,c=!0,s=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return c=e.done,e},e:function(e){s=!0,o=e},f:function(){try{c||null==n.return||n.return()}finally{if(s)throw o}}}}},82:function(e,t){e.exports=window.eventespresso.form},825:function(e,t,n){"use strict";n.d(t,"a",(function(){return s}));var r=n(0),i=n(45),a=n(16),o=n(26),c=new i.EntityActionsSubscription(a.domain).getSubscriptions,s=function(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],s=Object(r.useMemo)((function(){return new i.EntityActionsMenuRegistry({domain:a.domain,entityType:e,entityId:t.id})}),[t.id,e]),u=s.generateElements,l=c({entityType:n?e:null});return Object.values(l).forEach((function(n){(0,n.callback)({entityType:e,entity:t,registry:s})})),Object(o.useMemoStringify)(u(),Object.keys(l))}},84:function(e,t){e.exports=window.eventespresso.tpc},85:function(e,t,n){"use strict";function r(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}n.d(t,"a",(function(){return r}))},88:function(e,t,n){"use strict";n.d(t,"a",(function(){return u})),n.d(t,"b",(function(){return b})),n.d(t,"c",(function(){return h})),n.d(t,"d",(function(){return _})),n.d(t,"e",(function(){return E})),n.d(t,"f",(function(){return C}));var r=n(14),i=n(9),a=n(0),o=n(4),c=n(24),s=n(377),u=function(){var e=Object(c.useRelationsManager)(),t=e.addRelation,n=e.getData,u=e.getRelations,l=e.initialize,d=e.isInitialized,f=e.removeRelation,b=Object(a.useState)(!1),p=Object(i.a)(b,2),v=p[0],h=p[1],j=Object(a.useCallback)((function(e){var t=e.datetimeId;return u({entity:"datetimes",entityId:t,relation:"tickets"})}),[u]),O=Object(a.useCallback)((function(e){var t=e.ticketId;return u({entity:"tickets",entityId:t,relation:"datetimes"})}),[u]),m=Object(a.useCallback)((function(e){var n=e.datetimeId,r=e.ticketId,i=e.remove,a={entity:"datetimes",entityId:n,relation:"tickets",relationId:r},o={entity:"tickets",entityId:r,relation:"datetimes",relationId:n};void 0!==i&&i?(f(a),f(o)):(t(a),t(o)),h(!0)}),[t,f]),y=Object(a.useCallback)((function(e){var t=e.datetimeId,n=e.ticketId;m({datetimeId:t,ticketId:n})}),[m]),g=Object(a.useCallback)((function(e){var t=e.datetimeId,n=e.ticketId,r=j({datetimeId:t}).includes(n);m({datetimeId:t,ticketId:n,remove:r})}),[j,m]),_=Object(a.useCallback)((function(e){var t=e.datetimeId,n=e.ticketId;m({datetimeId:t,ticketId:n,remove:!0})}),[m]),x=Object(a.useCallback)((function(e){var t=e.assignmentType,n=e.entity,i=e.entityType,a=e.relationalEntity,c=a;if(("forDate"===t&&"datetimes"===i||"forTicket"===t&&"tickets"===i)&&(c=o.pick([n.id],a),o.isEmpty(c))){var u="datetimes"===i?"tickets":"datetimes";c[n.id]=Object(r.a)({},u,[])}return o.map((function(e){return o.pick(s.a,e)}),c)}),[]),k=Object(a.useCallback)((function(e){var t=e.data,n=e.assignmentType,r=e.entity,i=o.pick(s.a,t);i=o.mapObjIndexed((function(e,t){return x({assignmentType:n,entity:r,entityType:t,relationalEntity:e})}),i),l(i)}),[l,x]);return Object(a.useMemo)((function(){return{addAssignment:y,getAssignedDates:O,getAssignedTickets:j,getData:n,initialize:k,isDirty:v,isInitialized:d,removeAssignment:_,toggleAssignment:g}}),[y,O,j,n,k,v,d,_,g])},l=n(63),d=n.n(l),f=n(169),b=function(){var e=Object(a.useContext)(f.DataStateContext);return d()(e,"useDataState must be used inside TAM component"),e},p=n(2),v=n(16),h=function(e){var t,n=Object(a.useState)(!1),r=Object(i.a)(n,2),s=r[0],l=r[1],d=u(),f=Object(c.useRelations)(),b=C(d),h=Object(v.useDefaultTicketIds)(),j=d.initialize,O=(0,d.isInitialized)(),m=Object(a.useCallback)((function(e){var t=e.ticketId;return b.tickets.includes(t)}),[b.tickets]),y=Object(a.useCallback)((function(e){var t=e.datetimeId;return b.datetimes.includes(t)}),[b.datetimes]),g=Object(a.useCallback)((function(t){var n,r,i;return!("tickets"===t&&"forDate"===e.assignmentType||"datetimes"===t&&"forTicket"===e.assignmentType)&&("forAll"!==e.assignmentType?null===(r=b[t])||void 0===r?void 0:r.includes(null===(i=e.entity)||void 0===i?void 0:i.id):(null===(n=b[t])||void 0===n?void 0:n.length)>0)}),[b,e.assignmentType,null===(t=e.entity)||void 0===t?void 0:t.id]),_=Object(a.useCallback)((function(){return g("tickets")}),[g]),x=Object(a.useCallback)((function(){return g("datetimes")}),[g]),k=Object(a.useCallback)((function(){return _()||x()}),[x,_]),T=Object(a.useCallback)((function(e){var t=e.datetimeId;return f.getRelations({entity:"datetimes",entityId:t,relation:"tickets"})}),[f]),w=Object(a.useCallback)((function(e){var t=e.datetimeId,n=e.ticketId,r=T({datetimeId:t}),i=d.getAssignedTickets({datetimeId:t}),a=r.includes(n),o=i.includes(n);switch(!0){case a&&o:return"OLD";case!a&&o:return"NEW";case a&&!o:return"REMOVED";case!a&&!o:return null}}),[d,T]);return Object(a.useEffect)((function(){if(!O){var t,n,r=f.getData(),i=Object(p.a)(Object(p.a)({},r),{},{tickets:o.omit(h,r.tickets||{})});j(Object(p.a)({data:i},e));var a=0!==(null===b||void 0===b||null===(t=b.datetimes)||void 0===t?void 0:t.length)||0!==(null===b||void 0===b||null===(n=b.tickets)||void 0===n?void 0:n.length);l(!a)}}),[h,j,O,b,e,f,l]),Object(a.useMemo)((function(){return Object(p.a)(Object(p.a)({},d),{},{getAssignmentStatus:w,hasNoAssignedDates:m,hasNoAssignedTickets:y,hasOrphanDates:x,hasOrphanEntities:k,hasOrphanTickets:_,initialDataIsValid:s})}),[d,w,m,y,x,k,_,s])},j=n(26),O=n(12),m=n(286),y=function(e){var t=Object(m.useFilterState)(),n=t.showTrashedDates,r=t.datesByMonth,i=Object(O.inYearAndMonth)(r),o=Object(a.useMemo)((function(){return r[0]?i(e):e}),[e,r,i]);return Object(a.useMemo)((function(){return n?o:Object(O.notTrashed)(o)}),[o,n])},g=function(e){var t=Object(m.useFilterState)(),n=t.showExpiredTickets,r=t.showTrashedTickets;return Object(a.useMemo)((function(){var t=e;return n||(t=t.filter((function(e){return!Object(O.isExpired)(e)}))),r||(t=Object(O.notTrashed)(t)),t}),[e,n,r])},_=function(){var e,t,n=Object(f.useTAMContext)(),r=n.assignmentType,i=n.entity,a=Object(v.useDatetimes)(),o=Object(v.useTickets)(),c=y(a),s=g(o);switch(r){case"forAll":e=c,t=s;break;case"forDate":e=[i],t=s;break;case"forTicket":e=c,t=[i]}return Object(j.useMemoStringify)({datetimes:e,tickets:t})},x=n(43),k=n(34),T=n.n(k),w=n(456),E=function(){var e=Object(c.useRelations)().getData,t=Object(v.useDatetimes)(),n=Object(v.useTickets)(),r=Object(v.useBulkEditTickets)().updateEntities;return Object(a.useCallback)(function(){var a=Object(x.a)(T.a.mark((function a(c){var s,u,l,d;return T.a.wrap((function(a){for(;;)switch(a.prev=a.next){case 0:if(s=e(),u=Object(w.b)({entity:"tickets",existingData:s,newData:c,relation:"datetimes"}),l=Object(w.c)({allDates:t,allTickets:n,existingData:s,ticketsToUpdate:u}),d=u.map((function(e){var t=Object(i.a)(e,2),n=t[0],r=t[1],a={id:n,datetimes:null===r||void 0===r?void 0:r.datetimes},o=null===l||void 0===l?void 0:l[n];return o?Object(p.a)(Object(p.a)({},a),{},{quantity:o}):a})),Object.entries(l).forEach((function(e){var t=Object(i.a)(e,2),n=t[0],r=t[1];o.any(Object(O.entityHasGuid)(n),d)||d.push({id:n,quantity:r})})),!(null===d||void 0===d?void 0:d.length)){a.next=8;break}return a.next=8,r({uniqueInputs:d});case 8:case"end":return a.stop()}}),a)})));return function(e){return a.apply(this,arguments)}}(),[t,n,r,e])},D={datetimes:[],tickets:[]},C=function(e){var t=Object(a.useState)(D),n=Object(i.a)(t,2),r=n[0],c=n[1],s=e.getData();return Object(a.useEffect)((function(){if(!o.isEmpty(s)){var e=o.mapObjIndexed((function(e,t){var n="datetimes"===t?"tickets":"datetimes",r=o.pickBy((function(e){return 0===((null===e||void 0===e?void 0:e[n])||[]).length}),e);return Object.keys(r)}),s);c(e)}}),[s]),r}},9:function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(54);var i=n(42),a=n(55);function o(e,t){return Object(r.a)(e)||function(e,t){if("undefined"!==typeof Symbol&&Symbol.iterator in Object(e)){var n=[],r=!0,i=!1,a=void 0;try{for(var o,c=e[Symbol.iterator]();!(r=(o=c.next()).done)&&(n.push(o.value),!t||n.length!==t);r=!0);}catch(s){i=!0,a=s}finally{try{r||null==c.return||c.return()}finally{if(i)throw a}}return n}}(e,t)||Object(i.a)(e,t)||Object(a.a)()}},98:function(e,t,n){"use strict";function r(e,t){return(r=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}n.d(t,"a",(function(){return r}))}}); +//# sourceMappingURL=eventEditor.a576dbed.js.map \ No newline at end of file diff --git a/assets/static/js/eventEditor.5414d673.js.LICENSE.txt b/assets/static/js/eventEditor.a576dbed.js.LICENSE.txt similarity index 100% rename from assets/static/js/eventEditor.5414d673.js.LICENSE.txt rename to assets/static/js/eventEditor.a576dbed.js.LICENSE.txt diff --git a/assets/static/js/eventEditor.a576dbed.js.map b/assets/static/js/eventEditor.a576dbed.js.map new file mode 100644 index 00000000000..0947c3ea563 --- /dev/null +++ b/assets/static/js/eventEditor.a576dbed.js.map @@ -0,0 +1 @@ +{"version":3,"sources":["../webpack/bootstrap","../external \"React\"","../node_modules/react/jsx-runtime.js","../node_modules/classnames/index.js","../node_modules/date-fns/esm/parseISO/index.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/typeof.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/isNativeReflectConstruct.js","../external [\"eventespresso\",\"predicates\"]","../node_modules/lodash/_root.js","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/filters/filterState/useFilterState.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/context/withContext.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/context/useTAMContext.ts","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/data/useDataState.ts","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/data/useSubmitForm.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/filters/controls/DatesByMonthControl.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/filters/controls/ShowExpiredTicketsControl.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/filters/controls/ShowTrashedDatesControl.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/filters/controls/ShowTrashedTicketsControl.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/filters/FilterBar.tsx","../node_modules/lodash/isArray.js","../node_modules/property-expr/index.js","../node_modules/clsx/dist/clsx.m.js","../../src/utils/propValidator.ts","../../src/utils/constant.ts","../../src/utils/cssTransition.tsx","../../src/utils/collapseToast.ts","../../src/core/eventManager.ts","../../src/hooks/useKeeper.ts","../../src/hooks/toastContainerReducer.ts","../../src/hooks/useToastContainer.ts","../../src/hooks/useToast.ts","../../src/components/CloseButton.tsx","../../src/components/ProgressBar.tsx","../../src/components/Icons.tsx","../../src/components/Toast.tsx","../../src/components/Transitions.tsx","../../src/components/ToastContainer.tsx","../../src/core/toast.tsx","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/defineProperty.js","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/data/useDataStateReducer.ts","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/data/useDataStateManager.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/filters/filterState/reducer.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/filters/filterState/useFilterStateManager.ts","../external [\"eventespresso\",\"formBuilder\"]","../node_modules/lodash/_getNative.js","../node_modules/date-fns/esm/_lib/requiredArgs/index.js","../node_modules/lodash/has.js","../packages/icons/src/icons/CloseOutlined.tsx","../node_modules/webpack/buildin/global.js","../external [\"eventespresso\",\"edtrServices\"]","../packages/icons/src/icons/Link.tsx","../packages/icons/src/icons/Unlink.tsx","../packages/icons/src/icons/Calculator.tsx","../packages/icons/src/icons/MapMarker.tsx","../packages/icons/src/icons/Calendar.tsx","../packages/icons/src/icons/CalendarOutlined.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/context/index.ts","../packages/edtr-services/src/publicPath.ts","../packages/icons/src/types.ts","../domains/core/admin/eventEditor/src/services/utils.ts","../packages/icons/src/icons/Ticket.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/newDateOptions/AddSingleDate.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/newDateOptions/OptionsModalButton.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/newDateOptions/NewDateButton.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/newDateOptions/NewDateModal.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/DatesListButtons.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/DatesListFooter.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/config.ts","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/cardView/RenderCardView.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/tableView/RenderTableView.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/filterBar/controls/options.ts","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/filterBar/ActiveDatesFilters.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/filterBar/controls/DisplayStartOrEndDateControl.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/filterBar/controls/SalesControl.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/filterBar/controls/StatusControl.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/filterBar/controls/SortByControl/DraggableDatetime.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/filterBar/controls/SortByControl/index.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/DatesList.tsx","../domains/core/admin/eventEditor/src/ui/EventRegistrationOptions/ActiveStatus.tsx","../domains/core/admin/eventEditor/src/ui/EventRegistrationOptions/AltRegPage.tsx","../domains/core/admin/eventEditor/src/ui/EventRegistrationOptions/DefaultRegistrationStatus.tsx","../domains/core/admin/eventEditor/src/ui/EventRegistrationOptions/Donations.tsx","../domains/core/admin/eventEditor/src/ui/EventRegistrationOptions/EventManager.tsx","../domains/core/admin/eventEditor/src/ui/EventRegistrationOptions/EventPhoneNumber.tsx","../domains/core/admin/eventEditor/src/ui/EventRegistrationOptions/MaxRegistrations.tsx","../domains/core/admin/eventEditor/src/ui/EventRegistrationOptions/TicketSelector.tsx","../domains/core/admin/eventEditor/src/ui/EventRegistrationOptions/withData.tsx","../domains/core/admin/eventEditor/src/ui/EventRegistrationOptions/index.tsx","../domains/core/admin/eventEditor/src/ui/tickets/hooks/useNewTicketOptionItems.ts","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/newTicketOptions/OptionsModal.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/newTicketOptions/NewTicketButton.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/newTicketOptions/AddSingleTicket.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/actions/Actions.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/TicketsListFooter.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/config.ts","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/cardView/RenderCardView.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/tableView/RenderTableView.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/filterBar/controls/options.ts","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/filterBar/ActiveTicketsFilters.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/filterBar/controls/DisplayStartOrEndDateControl.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/filterBar/controls/SalesControl.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/filterBar/controls/StatusControl.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/filterBar/controls/SortByControl/DraggableTicket.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/filterBar/controls/SortByControl/index.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/filterBar/controls/IsChainedButton.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/TicketsList.tsx","../domains/core/admin/eventEditor/src/ui/EventDescription.tsx","../packages/icons/src/icons/VenueSeat.tsx","../packages/icons/src/icons/Phone.tsx","../domains/core/admin/eventEditor/src/ui/venue/useVenueLink.ts","../domains/core/admin/eventEditor/src/ui/venue/VenueDetails.tsx","../domains/core/admin/eventEditor/src/ui/registrationForm/constants.ts","../domains/core/admin/eventEditor/src/ui/registrationForm/utils.ts","../domains/core/admin/eventEditor/src/ui/registrationForm/ErrorMessage.tsx","../domains/core/admin/eventEditor/src/ui/registrationForm/RegistrationForm.tsx","../domains/core/admin/eventEditor/src/ui/notifications/useNotifications.ts","../domains/core/admin/eventEditor/src/ui/notifications/Notifications.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/dateForm/formValidation.ts","../domains/core/admin/eventEditor/src/ui/datetimes/dateForm/useDateFormConfig.ts","../domains/core/admin/eventEditor/src/ui/datetimes/dateForm/multiStep/DateFormSteps.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/dateForm/multiStep/useDataListener.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/ErrorMessage.tsx","../packages/icons/src/icons/MinusOutlined.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/table/getRelationIcon/index.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/table/BodyCell.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/table/DateCell.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/table/useRowClassName.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/table/useColClassName.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/table/useGetBodyRows.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/table/HeaderCell.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/table/useGetHeaderRows.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/table/Table.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/Debug.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/TicketAssignmentsManager.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/config.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/useSubmitButtonProps.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/TicketAssignmentsManagerModal.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/useInvalidDataAlert.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/components/ModalContainer.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/dateForm/multiStep/TAMStep.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/dateForm/multiStep/ModalBody.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/dateForm/multiStep/constants.ts","../domains/core/admin/eventEditor/src/ui/datetimes/dateForm/multiStep/FooterButtons.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/dateForm/multiStep/Modal.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/dateForm/multiStep/ContextProvider.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/dateForm/multiStep/Content.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/dateForm/multiStep/useOnSubmit.ts","../domains/core/admin/eventEditor/src/ui/datetimes/dateForm/multiStep/Container.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/actionsMenu/dropdown/useActions.ts","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/actionsMenu/dropdown/DeleteDatetime.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/actionsMenu/dropdown/DateMainMenu.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/datesList/actionsMenu/AssignTicketsButton.tsx","../domains/core/admin/eventEditor/src/ui/datetimes/registryInit.tsx","../domains/core/admin/eventEditor/src/ui/tickets/hooks/useDeleteTicketHandler.ts","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/actionsMenu/dropdown/DeleteTicket.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/actionsMenu/dropdown/TicketMainMenu.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketForm/formValidation.ts","../domains/core/admin/eventEditor/src/ui/tickets/ticketForm/useTicketFormConfig.ts","../domains/core/admin/eventEditor/src/ui/tickets/ticketForm/multiStep/TicketFormSteps.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketForm/multiStep/TPCStep.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketForm/multiStep/useDataListener.ts","../domains/core/admin/eventEditor/src/ui/tickets/ticketForm/multiStep/TAMStep.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketForm/multiStep/ModalBody.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketForm/multiStep/constants.ts","../domains/core/admin/eventEditor/src/ui/tickets/ticketForm/multiStep/FooterButtons.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketForm/multiStep/Modal.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketForm/multiStep/ContextProvider.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketForm/multiStep/Content.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketForm/multiStep/useOnSubmit.ts","../domains/core/admin/eventEditor/src/ui/tickets/ticketForm/multiStep/Container.tsx","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/TicketCard.tsx","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/multiStep/useTicketFormConfig.ts","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/multiStep/TicketFormSteps.tsx","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/multiStep/TPCStep.tsx","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/multiStep/ModalBody.tsx","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/multiStep/FooterButtons.tsx","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/multiStep/Modal.tsx","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/multiStep/ContextProvider.tsx","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/multiStep/ContentRenderer.tsx","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/ModalBody.tsx","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/Container.tsx","../domains/core/admin/eventEditor/src/ui/tickets/ticketsList/actionsMenu/AssignDatesButton.tsx","../domains/core/admin/eventEditor/src/ui/tickets/registryInit.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/registryInit.tsx","../domains/core/admin/eventEditor/src/services/filterState/datetimes/registerFilters.ts","../domains/core/admin/eventEditor/src/services/filterState/tickets/registerFilters.ts","../domains/core/admin/eventEditor/src/ui/EventEditor.tsx","../domains/core/admin/eventEditor/src/ui/index.tsx","../external [\"eventespresso\",\"utils\"]","../node_modules/regenerator-runtime/runtime.js","../external [\"eventespresso\",\"toaster\"]","../packages/icons/src/icons/ProfileOutlined.tsx","../packages/icons/src/icons/ControlOutlined.tsx","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/data/index.ts","../external [\"eventespresso\",\"data\"]","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/objectSpread2.js","../node_modules/lodash/_baseGetTag.js","../node_modules/lodash/isObjectLike.js","../node_modules/lodash/toString.js","../packages/icons/src/withClassName.tsx","../node_modules/nanoclone/src/index.js","../node_modules/yup/es/util/printValue.js","../node_modules/yup/es/locale.js","../node_modules/yup/es/util/isSchema.js","../node_modules/yup/es/Condition.js","../node_modules/yup/es/util/toArray.js","../node_modules/yup/es/ValidationError.js","../node_modules/yup/es/util/runTests.js","../node_modules/yup/es/Reference.js","../node_modules/yup/es/util/createValidation.js","../node_modules/yup/es/util/reach.js","../node_modules/yup/es/util/ReferenceSet.js","../node_modules/yup/es/schema.js","../node_modules/yup/es/mixed.js","../node_modules/yup/es/util/isAbsent.js","../node_modules/yup/es/boolean.js","../node_modules/yup/es/string.js","../node_modules/yup/es/number.js","../node_modules/yup/es/util/isodate.js","../node_modules/yup/es/date.js","../node_modules/yup/es/util/sortFields.js","../node_modules/yup/es/util/sortByKeyOrder.js","../node_modules/yup/es/object.js","../node_modules/yup/es/array.js","../external [\"eventespresso\",\"helpers\"]","../types/index.ts","../node_modules/lodash/_Symbol.js","../external [\"eventespresso\",\"services\"]","../node_modules/lodash/_nativeCreate.js","../node_modules/lodash/_ListCache.js","../node_modules/lodash/_assocIndexOf.js","../node_modules/lodash/_getMapData.js","../node_modules/lodash/_toKey.js","../node_modules/lodash/mapValues.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/construct.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/wrapNativeSuper.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/isNativeFunction.js","../external [\"eventespresso\",\"hooks\"]","../external [\"eventespresso\",\"adapters\"]","../external [\"wp\",\"i18n\"]","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/context/ContextProvider.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/filters/index.ts","../node_modules/webpack/buildin/module.js","../node_modules/lodash/_isKey.js","../node_modules/lodash/isSymbol.js","../node_modules/lodash/_MapCache.js","../node_modules/lodash/isObject.js","../external [\"eventespresso\",\"i18n\"]","../node_modules/lodash/_Map.js","../node_modules/lodash/isLength.js","../node_modules/lodash/keys.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/toConsumableArray.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/arrayWithoutHoles.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/nonIterableSpread.js","../node_modules/lodash/snakeCase.js","../node_modules/date-fns/esm/_lib/toInteger/index.js","../node_modules/@babel/runtime/regenerator/index.js","../external [\"eventespresso\",\"constants\"]","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/classCallCheck.js","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/constants.ts","../node_modules/lodash/_hasPath.js","../node_modules/lodash/_castPath.js","../node_modules/lodash/_freeGlobal.js","../node_modules/lodash/isFunction.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/arrayLikeToArray.js","../node_modules/lodash/_toSource.js","../node_modules/lodash/eq.js","../node_modules/lodash/isArguments.js","../node_modules/lodash/_isIndex.js","../node_modules/lodash/_baseAssignValue.js","../node_modules/lodash/_baseForOwn.js","../node_modules/lodash/isBuffer.js","../node_modules/lodash/isTypedArray.js","../node_modules/lodash/_baseIteratee.js","../node_modules/lodash/_Stack.js","../external \"R\"","../node_modules/lodash/_baseIsEqual.js","../node_modules/lodash/_equalArrays.js","../node_modules/lodash/_isStrictComparable.js","../node_modules/lodash/_matchesStrictComparable.js","../node_modules/lodash/_baseGet.js","../node_modules/lodash/_createCompounder.js","../node_modules/lodash/_hasUnicode.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/asyncToGenerator.js","../external [\"wp\",\"url\"]","../node_modules/lodash/camelCase.js","../node_modules/lodash/mapKeys.js","../node_modules/toposort/index.js","../external [\"eventespresso\",\"registry\"]","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/utils/index.ts","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/getPrototypeOf.js","../domains/core/admin/eventEditor/src/hooks/useEditorInitialization.ts","../domains/core/admin/eventEditor/src/hooks/entityCardDetails/useEntityCardDetailsItems.ts","../domains/core/admin/eventEditor/src/hooks/newEntityOptions/useNewEntityOptionItems.ts","../packages/icons/src/icons/Trash.tsx","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/createClass.js","../external [\"eventespresso\",\"uiComponents\"]","../external [\"eventespresso\",\"dates\"]","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/inherits.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/possibleConstructorReturn.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/createSuper.js","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/context/DataStateProvider.tsx","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/filters/filterState/index.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/context/FilterStateProvider.tsx","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/data/useInitialState.ts","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/arrayWithHoles.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/nonIterableRest.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/get.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/superPropBase.js","../external [\"eventespresso\",\"plugins\"]","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/context/DataStateProvider.tsx","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/context/ContextProvider.tsx","../domains/core/admin/eventEditor/src/ui/tickets/defaultTickets/context/withContext.tsx","../external \"ReactDOM\"","../node_modules/invariant/browser.js","../node_modules/lodash/_baseHas.js","../node_modules/lodash/_getRawTag.js","../node_modules/lodash/_objectToString.js","../node_modules/lodash/_stringToPath.js","../node_modules/lodash/_memoizeCapped.js","../node_modules/lodash/memoize.js","../node_modules/lodash/_mapCacheClear.js","../external [\"eventespresso\",\"eeComponents\"]","../node_modules/lodash/_Hash.js","../node_modules/lodash/_hashClear.js","../node_modules/lodash/_baseIsNative.js","../node_modules/lodash/_isMasked.js","../node_modules/lodash/_coreJsData.js","../node_modules/lodash/_getValue.js","../node_modules/lodash/_hashDelete.js","../node_modules/lodash/_hashGet.js","../node_modules/lodash/_hashHas.js","../node_modules/lodash/_hashSet.js","../node_modules/lodash/_listCacheClear.js","../node_modules/lodash/_listCacheDelete.js","../node_modules/lodash/_listCacheGet.js","../node_modules/lodash/_listCacheHas.js","../node_modules/lodash/_listCacheSet.js","../node_modules/lodash/_mapCacheDelete.js","../node_modules/lodash/_isKeyable.js","../node_modules/lodash/_mapCacheGet.js","../node_modules/lodash/_mapCacheHas.js","../node_modules/lodash/_mapCacheSet.js","../node_modules/object-assign/index.js","../node_modules/lodash/_baseToString.js","../node_modules/lodash/_arrayMap.js","../node_modules/lodash/_baseIsArguments.js","../node_modules/lodash/_defineProperty.js","../node_modules/lodash/_baseFor.js","../node_modules/lodash/_createBaseFor.js","../node_modules/lodash/_arrayLikeKeys.js","../node_modules/lodash/_baseTimes.js","../node_modules/lodash/stubFalse.js","../node_modules/lodash/_baseIsTypedArray.js","../node_modules/lodash/_baseUnary.js","../node_modules/lodash/_nodeUtil.js","../node_modules/lodash/_baseKeys.js","../node_modules/lodash/_isPrototype.js","../node_modules/lodash/_nativeKeys.js","../node_modules/lodash/_overArg.js","../node_modules/lodash/isArrayLike.js","../node_modules/lodash/_baseMatches.js","../node_modules/lodash/_baseIsMatch.js","../node_modules/lodash/_stackClear.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/iterableToArray.js","../node_modules/lodash/_stackDelete.js","../node_modules/lodash/_stackGet.js","../node_modules/lodash/_stackHas.js","../node_modules/lodash/_stackSet.js","../node_modules/lodash/_baseIsEqualDeep.js","../node_modules/lodash/_SetCache.js","../node_modules/lodash/_setCacheAdd.js","../node_modules/lodash/_setCacheHas.js","../node_modules/lodash/_arraySome.js","../node_modules/lodash/_cacheHas.js","../node_modules/lodash/_equalByTag.js","../node_modules/lodash/_Uint8Array.js","../node_modules/lodash/_mapToArray.js","../node_modules/lodash/_setToArray.js","../node_modules/lodash/_equalObjects.js","../node_modules/lodash/_getAllKeys.js","../node_modules/lodash/_baseGetAllKeys.js","../node_modules/lodash/_arrayPush.js","../node_modules/lodash/_getSymbols.js","../node_modules/lodash/_arrayFilter.js","../node_modules/lodash/stubArray.js","../node_modules/lodash/_getTag.js","../node_modules/lodash/_DataView.js","../node_modules/lodash/_Promise.js","../node_modules/lodash/_Set.js","../node_modules/lodash/_WeakMap.js","../node_modules/lodash/_getMatchData.js","../node_modules/lodash/_baseMatchesProperty.js","../node_modules/lodash/get.js","../node_modules/lodash/hasIn.js","../node_modules/lodash/_baseHasIn.js","../node_modules/lodash/identity.js","../node_modules/lodash/property.js","../node_modules/lodash/_baseProperty.js","../node_modules/lodash/_basePropertyDeep.js","../node_modules/lodash/_arrayReduce.js","../node_modules/lodash/deburr.js","../node_modules/lodash/_deburrLetter.js","../node_modules/lodash/_basePropertyOf.js","../node_modules/lodash/words.js","../node_modules/lodash/_asciiWords.js","../node_modules/lodash/_hasUnicodeWord.js","../node_modules/lodash/_unicodeWords.js","../node_modules/lodash/capitalize.js","../node_modules/lodash/upperFirst.js","../node_modules/lodash/_createCaseFirst.js","../node_modules/lodash/_castSlice.js","../node_modules/lodash/_baseSlice.js","../node_modules/lodash/_stringToArray.js","../node_modules/lodash/_asciiToArray.js","../node_modules/lodash/_unicodeToArray.js","../node_modules/react/cjs/react-jsx-runtime.production.min.js","../packages/icons/src/icons/SaveOutlined.tsx","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/objectWithoutProperties.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/createForOfIteratorHelper.js","../external [\"eventespresso\",\"form\"]","../domains/core/admin/eventEditor/src/hooks/entityActionsMenu/useEntityActionsMenuItems.ts","../external [\"eventespresso\",\"tpc\"]","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/assertThisInitialized.js","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/data/useAssignmentManager.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/data/useDataState.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/data/useDataStateManager.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/data/useFilteredDatetimes.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/data/useFilteredTickets.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/data/useDatesAndTickets.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/data/useOnSubmitAssignments.ts","../domains/core/admin/eventEditor/src/ui/ticketAssignmentsManager/data/useValidation.ts","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/slicedToArray.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/iterableToArrayLimit.js","../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js"],"names":["webpackJsonpCallback","data","moduleId","chunkId","chunkIds","moreModules","i","resolves","length","Object","prototype","hasOwnProperty","call","installedChunks","push","modules","parentJsonpFunction","shift","installedModules","installedCssChunks","__webpack_require__","exports","module","l","e","promises","Promise","resolve","reject","href","fullhref","p","existingLinkTags","document","getElementsByTagName","dataHref","tag","getAttribute","rel","existingStyleTags","linkTag","createElement","type","onerror","onload","event","errorType","realHref","target","err","Error","code","request","parentNode","removeChild","head","appendChild","then","installedChunkData","promise","onScriptComplete","script","charset","timeout","nc","setAttribute","src","jsonpScriptSrc","error","clearTimeout","chunk","realSrc","message","name","undefined","setTimeout","all","m","c","d","getter","o","defineProperty","enumerable","get","r","Symbol","toStringTag","value","t","mode","__esModule","ns","create","key","bind","n","object","property","oe","console","jsonpArray","this","oldJsonpFunction","slice","s","window","require","hasOwn","classNames","classes","arguments","arg","argType","Array","isArray","inner","apply","toString","join","default","MILLISECONDS_IN_HOUR","patterns","dateTimeDelimiter","timeZoneDelimiter","timezone","dateRegex","timeRegex","timezoneRegex","parseISO","argument","dirtyOptions","requiredArgs","options","additionalDigits","toInteger","RangeError","Date","NaN","date","dateStrings","splitDateString","parseYearResult","parseYear","parseDate","restDateString","year","isNaN","offset","timestamp","getTime","time","parseTime","dirtyDate","result","setFullYear","getUTCFullYear","getUTCMonth","getUTCDate","setHours","getUTCHours","getUTCMinutes","getUTCSeconds","getUTCMilliseconds","parseTimezone","dateString","timeString","array","split","test","substr","token","exec","replace","regex","RegExp","captures","match","parseInt","century","isWeekDate","dayOfYear","parseDateUnit","month","day","week","dayOfWeek","_year","validateWeekDate","isoWeekYear","setUTCFullYear","fourthOfJanuaryDay","getUTCDay","diff","setUTCDate","dayOfISOWeekYear","daysInMonths","isLeapYearIndex","validateDate","validateDayOfYearDate","Math","max","hours","parseTimeUnit","minutes","seconds","validateTime","parseFloat","timezoneString","sign","_hours","validateTimezone","_typeof","obj","iterator","constructor","_isNativeReflectConstruct","Reflect","construct","sham","Proxy","freeGlobal","freeSelf","self","root","Function","useFilterState","useContext","FilterStateContext","invariant","withContext","Component","contextProps","props","_jsx","ContextProvider","_objectSpread","children","useTAMContext","Context","useDataState","state","DataStateContext","useSubmitForm","_ref","deletedTickets","tickets","mutateTicket","useMutateTicket","deleteTicket","useTicketMutator","deleteEntity","useCallback","_asyncToGenerator","_regeneratorRuntime","mark","_callee","wrap","_context","prev","next","values","map","id","deletePermanently","stop","DatesByMonthControl","datesByMonth","setDatesByMonth","datetimes","useDatetimes","monthsList","getMonthsListFromDatetimes","yearMonth","monthsListWithAllDates","useMemo","label","__","concat","_toConsumableArray","SelectWithLabel","onChangeValue","ShowExpiredTicketsControl","showExpiredTickets","setShowExpiredTickets","SwitchWithLabel","isChecked","ShowTrashedDatesControl","showTrashedDates","setShowTrashedDates","ShowTrashedTicketsControl","showTrashedTickets","setShowTrashedTickets","FilterBar","assignmentType","_useFilterState","_jsxs","className","_Fragment","Cache","maxSize","_maxSize","clear","_size","_values","set","SPLIT_REGEX","DIGIT_REGEX","LEAD_DIGIT_REGEX","SPEC_CHAR_REGEX","CLEAN_QUOTES_REGEX","pathCache","setCache","getCache","normalizePath","path","part","isQuoted","str","indexOf","charAt","shouldBeQuoted","hasLeadingNumber","hasSpecialChars","setter","parts","index","len","safe","segments","reduce","forEach","cb","thisArg","iter","idx","isBracket","toVal","mix","k","y","tmp","x","isNum","v","isBool","isStr","isFn","parseClassName","isToastIdValid","toastId","canUseDom","canBeRendered","content","isValidElement","POSITION","TOP_LEFT","TOP_RIGHT","TOP_CENTER","BOTTOM_LEFT","BOTTOM_RIGHT","BOTTOM_CENTER","TYPE","INFO","SUCCESS","WARNING","ERROR","DEFAULT","cssTransition","enter","exit","appendPosition","_ref$appendPosition","collapse","_ref$collapse","collapseDuration","_ref$collapseDuration","_ref2","position","preventExitTransition","done","nodeRef","isIn","enterClassName","exitClassName","baseClassName","useRef","animationStep","onEntered","current","node","removeEventListener","onExited","duration","scrollHeight","style","requestAnimationFrame","minHeight","height","transition","padding","margin","collapseToast","useLayoutEffect","addEventListener","onEnter","useEffect","onExit","React__default","Fragment","eventManager","list","Map","emitQueue","on","callback","has","off","filter","cancelEmit","timers","emit","args","_len","_key","timer","_this","useKeeper","refresh","ref","reducer","action","staleId","useToastContainer","forceUpdate","useReducer","_useReducer2","toast","dispatch","containerRef","toastCount","queue","collection","instance","toastKey","displayedToast","containerId","isToastActive","getToast","clearWaitingQueue","limit","removeToast","dequeueToast","_queue$shift","appendToast","toastContent","toastProps","buildToast","_ref3","delay","_objectWithoutPropertiesLoose","_excluded","updateId","enableMultiContainer","isNotValid","closeToast","isNotAnUpdate","toastAutoClose","containerAutoClose","isLoading","theme","icon","_options$icon","closeButton","rtl","toastClassName","bodyClassName","toastStyle","bodyStyle","onClick","pauseOnHover","pauseOnFocusLoss","draggable","draggablePercent","draggableDirection","closeOnClick","progressClassName","progressStyle","autoClose","hideProgressBar","progress","role","deleteToast","queueLen","freeSlot","toDequeue","removeFromCollection","onOpen","onClose","cloneElement","getToastToRender","toastToRender","toastList","newestOnTop","keys","reverse","_toast","getX","targetTouches","clientX","getY","clientY","useToast","_useState","useState","isRunning","setIsRunning","_useState2","setPreventExitTransition","toastRef","drag","start","delta","removalDistance","canCloseOnClick","canDrag","boundingRect","syncProps","onDragStart","getBoundingClientRect","nativeEvent","offsetWidth","offsetHeight","onDragTransitionEnd","_drag$boundingRect","top","bottom","left","right","pauseToast","playToast","onDragMove","preventDefault","transform","opacity","abs","onDragEnd","hasFocus","bindFocusEvents","eventHandlers","onMouseDown","onTouchStart","onMouseUp","onTouchEnd","onMouseEnter","onMouseLeave","CloseButton","ariaLabel","_ref$ariaLabel","stopPropagation","viewBox","fillRule","ProgressBar","hide","userStyle","controlledProgress","_extends","animationDuration","animationPlayState","defaultClassName","cx","_cx","animationEvent","_animationEvent","assign","defaultProps","Svg","rest","_excluded$1","width","fill","Icons","info","warning","success","spinner","Toast","_useToast","Transition","cssClasses","isProgressControlled","maybeIcon","iconProps","Icon","_cx2","renderCloseButton","Bounce","ToastContainer","_useToastContainer","getClassName","containerStyle","pointerEvents","latestInstance","containerDomNode","containerConfig","containers","lazy","generateToastId","random","getToastId","dispatchToast","size","body","render","mergeOptions","createToastByType","loading","pending","resetParams","resolver","input","params","update","warn","dark","dismiss","isActive","container","oldOptions","oldContent","nextOptions","onChange","configure","config","containerInstance","item","_defineProperty","configurable","writable","initialState","isDirty","useDataStateReducer","initializer","ticketId","newState","existingTicket","ticket","uuid","R","isModified","Boolean","isDefault","includes","useDataStateManager","useInitialState","dataReducer","useDataReducer","_useReducer","_slicedToArray","getData","addTicket","updateTicket","isNew","reset","useFilterStateManager","_datesByMonth$split$m","Number","_datesByMonth$split$m2","baseIsNative","getValue","required","TypeError","baseHas","hasPath","withClassName","g","xmlns","assetsUrl","baristaAssetsUrl","_window","_window$eventEspresso","eventEspressoData","_window$eventEspresso2","_window$eventEspresso3","coreDomain","distributionAssetsUrl","__webpack_public_path__","IconName","getSubscriptions","ModalSubscription","domain","registry","ModalRegistry","AddSingleDate","isOnlyButton","open","useGlobalModal","EdtrGlobalModals","EDIT_DATE","output","additionalProps","hooks","applyFilters","EMPTY_OBJECT","Button","buttonText","buttonType","Calendar","NewEntityOption","description","title","OptionsModalButton","openWithData","NEW_DATE","mr","NewDateButton","NewDateOptions","fills","NewDateModal","_useGlobalModal","isOpen","close","NewEntityModal","withCurrentUserCan","USE_ADVANCED_EDITOR","TAM","useTickets","isDisabled","tooltip","ButtonRow","Ticket","DatesListFooter","entities","EntityCacheIds","DatesListButtons","legendConfig","icons","EDIT","GROUPS","TICKET","Trash","swatches","DTA","DTT","DTE","DTS","DTU","CardView","RenderCardView","Suspense","fallback","LoadingNotice","TableView","RenderTableView","displayStartOrEndDateOptions","_displayStartOrEndDat","DisplayStartOrEndDate","end","both","salesOptions","_salesOptions","DatetimeSales","above90Capacity","above75Capacity","above50Capacity","below50Capacity","statusOptions","_statusOptions","DatetimeStatus","activeUpcoming","activeOnly","upcomingOnly","nextActiveUpcomingOnly","soldOutOnly","recentlyExpiredOnly","expiredOnly","trashedOnly","sortByOptions","order","labels","displayStartOrEndDate","recurrence","sales","sortBy","search","status","ActiveDatesFilters","_useDatesListFilterSt","useDatesListFilterState","setStatus","setSales","searchText","setSearchText","setRecurrence","statusTitle","salesTitle","searchTitle","recurrenceTitle","onRemoveStatus","onRemoveSales","onRemoveRecurrence","onRemoveSearch","ActiveFilters","FilterTag","onRemove","objectToSelectOptions","DisplayStartOrEndDateControl","setDisplayStartOrEndDate","SalesControl","StatusControl","formatTokens","DraggableDatetime","dbId","endDate","startDate","RangeFormat","showTime","renderDraggableItem","datetime","SortByControl","setSortBy","filteredDateIds","useFilteredDateIds","_useReorderDatetimes","useReorderDatetimes","draggableItems","allReorderedEntities","sortResponder","updateEntityList","SortByControlUI","droppableId","datetimesDroppableId","entityType","TypeName","onSort","onSubmit","withEntityListContext","Provider","DatetimesListProvider","filterState","renderList","view","EntityList","activeFilters","footer","headerText","listId","datesList","loadingText","ActiveStatus","onStatusChange","datetimeStatusBgColorClassName","datetimeStatus","fitContainer","flow","labelClassName","labelPosition","noBorderColor","wrapperClassName","AltRegPage","altRegPage","onAltRegPageChange","InlineEditTextWithLabel","placeholder","DefaultRegistrationStatus","_regStatusCode$","defaultRegStatus","onDefaultRegStatusChange","regStatusCode","regStatusOptions","option","Donations","allowDonations","onDonationsChange","debounceDelay","EventManager","eventManagers","managerId","onManagerChange","entityListToSelectOptions","EventPhoneNumber","onPhoneNumberChange","phoneNumber","MaxRegistrations","maxReg","onMaxRegChange","strValue","String","TicketSelector","displayTicketSelector","onTicketSelectorChange","withData","WrappedComponent","_event$manager2","_event$manager3","useEvent","useEventManagers","updateEvent","useEventMutator","updateEntity","newAltRegPage","newManagerId","_event$manager","manager","newMaxRegistrations","maxRegistrations","newPhoneNumber","withFeature","_ref$onAltRegPageChan","noop","_ref$onMaxRegChange","Grid","maxColumns","GridCard","header","useNewTicketOptionItems","useNewEntityOptionItems","border","OptionsModal","NewTicketButton","optionItems","AddSingleTicket","EDIT_TICKET","noVerticalMargin","toggleProps","noPadding","DEFAULT_TICKETS","canReadDefaultTickets","useCurrentUserCan","currentUserCan","DropdownMenu","noZindex","DropdownMenuItem","TicketsListFooter","Actions","CALENDAR","CALCULATOR","TKA","TKE","TKO","TKS","TKP","TicketsSales","above90Sold","above75Sold","above50Sold","below50Sold","salesIsChainedOptions","TicketsStatus","onSaleAndPending","onSaleOnly","pendingOnly","nextOnSaleOrPendingOnly","statusIsChainedOptions","isChained","ActiveTicketsSFilters","_useTicketsListFilter","useTicketsListFilterState","toggleIsChained","isChainedTitle","useMemoStringify","DraggableTicket","price","CurrencyDisplay","filteredTicketIds","useFilteredTicketIds","_useReorderTickets","useReorderTickets","ticketDroppableId","IsChainedButton","Link","Unlink","IconButton","showTooltipOnMobile","EnhancedTicketsList","TicketsListProvider","ActiveTicketsFilters","ticketsList","ChainedTicketsList","useRegisterIsChainedFilter","onChangeDescription","newDescription","_document$getElementB","getElementById","remove","Heading","as","AdvancedTextEditor","defaultValue","useVenueLink","venueDbId","siteUrl","useConfig","adminUrl","getAdminUrl","adminSiteUrl","admin","page","ADMIN_ROUTES","VENUES","addQueryArgs","post","return","VenueDetails","venue","selectedVenueId","setSelectedVenueId","venues","useVenues","selectedVenue","findEntityByGuid","createVenueLink","editVenueLink","capacity","venueCapacity","isInfinite","sprintf","onChangeInstantValue","newValue","thumbnail","addressLabels","inline","Container","Image","alt","shortDescription","MapMarker","Address","VenueSeat","Phone","phone","TextLink","showExternalIcon","VenueSelector","venueName","APPLIES_TO_OPTIONS","MAPS_TO_OPTIONS","hasTypeAsText","hasMapsToAsFName","hasTypeAsTextAndMapsToAsFName","hasAnElementAsAttendeeFName","hasTypeAsEmail","hasMapsToAsEmail","hasTypeAsEmailAndMapsToAsEmail","hasAnElementAsAttendeeEmail","ErrorMessage","elements","sections","formSectionIds","getGuids","isNotSharedOrDefault","formElements","hasFirstName","hasEmail","Banner","_getEdtrDomData","getEdtrDomData","topLevelSectionId","FormBuilder","appliesToOptions","containerClassName","initialElements","initialSections","mapsToOptions","topBanner","log","useNotifications","isLoaded","useStatus","_useIsRehydrated","useIsRehydrated","isRehydrated","readyTypes","types","isDev","dev","Notifications","toaster","useSystemNotifications","toasts","initToaster","validate","yupToFinalFormErrors","validationSchema","abrupt","sent","_x","yup","datesSchema","FIELD_NAMES","decorators","startAndEndDateFixer","adjacentFormItemProps","useDateFormConfig","useDatetimeItem","toUtcISO","useSiteDateToUtcISO","toSiteDate","useUtcISOToSiteDate","setDefaultTime","PLUS_ONE_MONTH","onSubmitFrom","form","restParams","_args","_objectWithoutProperties","_x2","initialValues","ProfileOutlined","fields","fieldType","CalendarOutlined","formControlProps","wrapper","EndDateFieldWrapper","ControlOutlined","parseAsInfinity","min","subscription","layout","DatetimeFormSteps","Steps","showStepNumber","Step","useDataListener","useTAMDataState","_useForm","useForm","mutators","getState","_data$datetimes","_data$datetimes$id","updateFieldValue","_ref$asAlert","asAlert","dataState","hasOrphanDates","hasOrphanTickets","getRelationIcon","CloseOutlined","MinusOutlined","BodyCell","_useDataState","getAssignmentStatus","toggleAssignment","datetimeId","entityLabel","entity","nameOrId","ticketLabel","datetimeLabel","variant","DateCell","bgClassName","getDatetimeBackgroundColorClassName","stripeClassName","format","useTimeZoneTime","formatForSite","LOCALIZED_DATE_SHORT_FORMAT","useRowClassName","hasNoAssignedTickets","useColClassName","hasNoAssignedDates","useGetBodyRows","getRowClass","getColClass","datetimeCell","cells","statusClassName","toLowerCase","textAlign","bodyRowClassName","rowClassName","primary","FORMAT","HeaderCell","getTicketBackgroundColorClassName","startDateClassName","emptyCell","useGetHeaderRows","metaData","isScrollable","tableId","tableCaption","tableClassName","Table","bodyRows","headerRows","ResponsiveTable","Debug","DebugInfo","TicketAssignmentsManager","datesAndTickets","useDatesAndTickets","useSubmitButtonProps","onSubmitData","hasOrphanEntities","isSubmitting","setIsSubmitting","hasErrors","ButtonType","PRIMARY","SaveOutlined","TicketAssignmentsManagerModal","onCloseModal","submitButtonProps","ariaAttributes","modalContent","ModalWithAlert","isSubmitDisabled","onCancel","showAlertOnClose","CollapsibleLegend","direction","useInvalidDataAlert","showAlert","useRelations","validateData","setValidateData","defaultTicketIds","useDefaultTicketIds","newData","_i","_entries","entries","TAM_ENTITIES","entityRelations","_i2","_Object$entries","relations","tamRelations","flat","ModalContainer","submitAssignments","useOnSubmitAssignments","reOpenTamModal","_useConfirmationDialo","useConfirmationDialog","onConfirm","confirmationDialog","_getData","wait","TAMStep","ModalBody","steps","DateFormSteps","withFormSubscription","submitting","Next","Previous","Submit","submit","Modal","usePrevNext","isPristine","useIsPristine","footerButtons","FooterButtons","EntityEditModal","footerContent","useFormValues","TAMContextProvider","Content","entityId","formConfig","useDatetimeFormConfig","FormWithConfig","formWrapper","useOnSubmit","_useDatetimeMutator","useDatetimeMutator","createEntity","_useUpdateTicketQtyBy","useUpdateTicketQtyByCapacity","createBulkQtyUpdateInput","doQtyBulkUpdate","dates","capacityChanged","_result$data","_result$data$createEs","_result$data$createEs2","getHighestOrder","createEspressoDatetime","espressoDatetime","closeEditDateModal","setData","closeNewDateModal","useActions","eventId","useEventId","getRelations","relation","copyDate","newDatetime","trashed","isTrashed","deleteRelatedTickets","useDeleteRelatedTickets","trashDate","DeleteDatetime","_useActions","isTheOnlyDate","total","trashDateTitle","cannotBeDeleted","addIconBG","alertType","AlertType","ACCENT","TrashIcon","yesButtonText","TrashEntity","DateMainMenu","onOpenEditModal","EditEntity","CopyEntity","AssignTicketsButton","count","useRelatedTickets","getRelatedTickets","ItemCount","zeroCountChar","borderless","withIsLoaded","loaded","subscribe","registerContainer","EditDateContainer","EntityActionsSubscription","registerMenuItem","registerElement","FilterBarUISubscription","registerFilterBarItem","FilterBarFilter","registerPlugin","EdtrSlots","ADD_SINGLE_DATE_OPTION","NewDateOption","_ref4","useDeleteTicketHandler","getTicketPrices","useTicketPrices","priceQueryOptions","usePriceQueryOptions","client","useApolloClient","deleteRelatedPrices","_data$espressoPrices","pricesToDelete","isTax","priceIdsToDelete","readQuery","pricesToRetain","entitiesWithGuIdNotInArray","espressoPrices","nodes","writeQuery","catch","DeleteTicket","isTicketTrashed","onConfirmDelete","confirmDelete","_useLockedTicketActio","useLockedTicketAction","alertContainer","isTheOnlyTicket","deleteTicketTitle","onDelete","isLocked","TicketMainMenu","useTicketItem","copyTicket","useCopyTicket","useTicketFormConfig","NOW","priceToTpcModifier","usePriceToTpcModifier","prices","preparePricesForTpc","visibility","publicFields","advancedFields","VISIBILITY_OPTIONS_INFO","VISIBILITY_OPTIONS","ticketDetailsFields","TicketFormSteps","Calculator","TPCStep","useSyncTPC2RFF","TicketPriceCalculator","context","_data$tickets","_data$tickets$id","goto","gotoDetails","gotoTAM","isTPCSubmitDisabled","hasEmptyPrices","SECONDARY","skipsSteps","getTheTicketPrices","getTicket","TPCContextProvider","getCappedQuantity","useCappedQuantity","quantity","relatedDateIds","closeModal","TicketCard","onEdit","renderStartDate","LOCALIZED_DATE_AND_TIME_SHORT_FORMAT","renderEndDate","showAfterDetails","deleteButtonProps","editButtonProps","SimpleTicketCard","newConfig","useMainTicketFormConfig","_props$form$getState$","_tickets$ticketId","_tickets$id","withTPCContext","ContentRenderer","templates","prepTemplatePrices","usePrepTemplatePrices","addEntity","ticketPrices","SimpleEntityList","EntityRenderer","submitForm","AssignDatesButton","useRelatedDatetimes","emphasizeZero","EditTicketContainer","DefaultTicketContainer","TPC","TPCModalContainer","TicketPriceCalculatorButton","NewEntitySubscription","registerOptionItem","totalCount","_ref5","_FilterBarService","FilterBarService","registerDatesFilter","registerFilter","registerDatesSearch","registerSearch","registerDatesSorter","registerSorter","entityList","dateSalesFilter","dateStatusFilter","entityListSearch","searchFields","sortDates","registerTicketsFilter","registerTicketsSearch","registerTicketsSorter","ticketSalesFilter","ticketStatusFilter","sortTickets","generateElements","subscriptions","getRegisteredContainers","EventEditor","useEditorInitialization","EventDescription","EventRegistrationOptions","DatesList","TicketsList","RegistrationForm","PluginArea","Spinner","Editor","ContextProviders","renderDomElement","appendToTarget","domElementToRender","containerID","targetElementID","runtime","Op","$Symbol","iteratorSymbol","asyncIteratorSymbol","asyncIterator","toStringTagSymbol","define","innerFn","outerFn","tryLocsList","protoGenerator","Generator","generator","_invoke","GenStateSuspendedStart","method","GenStateExecuting","GenStateCompleted","doneResult","delegate","delegateResult","maybeInvokeDelegate","ContinueSentinel","_sent","dispatchException","record","tryCatch","GenStateSuspendedYield","makeInvokeMethod","fn","GeneratorFunction","GeneratorFunctionPrototype","IteratorPrototype","getProto","getPrototypeOf","NativeIteratorPrototype","Gp","defineIteratorMethods","AsyncIterator","PromiseImpl","invoke","__await","unwrapped","previousPromise","callInvokeWithMethodAndArg","resultName","nextLoc","pushTryEntry","locs","entry","tryLoc","catchLoc","finallyLoc","afterLoc","tryEntries","resetTryEntry","completion","iterable","iteratorMethod","displayName","isGeneratorFunction","genFun","ctor","setPrototypeOf","__proto__","awrap","async","pop","skipTempReset","rootRecord","rval","exception","handle","loc","caught","hasCatch","hasFinally","finallyEntry","complete","finish","thrown","delegateYield","regeneratorRuntime","accidentalStrictMode","ownKeys","enumerableOnly","getOwnPropertySymbols","symbols","sym","getOwnPropertyDescriptor","_objectSpread2","source","getOwnPropertyDescriptors","defineProperties","getRawTag","objectToString","symToStringTag","baseToString","svgName","WrappedIcon","noMargin","_","Set","baseClone","circulars","clones","nodeType","cloneNode","clone","from","findIndex","errorToString","regExpToString","symbolToString","SYMBOL_REGEXP","printNumber","val","printSimpleValue","quoteStrings","typeOf","toISOString","printValue","JSON","stringify","mixed","oneOf","notOneOf","notType","originalValue","isCast","msg","defined","string","matches","email","url","trim","lowercase","uppercase","number","lessThan","moreThan","positive","negative","integer","boolean","isValue","noUnknown","isSchema","__isYupSchema__","Condition","refs","_classCallCheck","otherwise","is","check","every","_len2","_key2","schema","branch","_createClass","base","parent","toArray","strReg","ValidationError","_Error","_inherits","_super","_createSuper","errorOrErrors","field","errors","_this$errors","isError","captureStackTrace","_assertThisInitialized","_wrapNativeSuper","runTests","endEarly","tests","sort","fired","once","nestedErrors","prefixes","Reference","isContext","isSibling","prefix","__isYupRef","createValidation","_ref$path","sync","excluded","sourceKeys","Ref","isRef","createError","overrides","nextParams","mapValues","formatError","ctx","validOrError","OPTIONS","getIn","lastPart","lastPartDebug","_part","innerType","_type","parentPath","ReferenceSet","_step","_iterator","_createForOfIteratorHelper","f","_step2","_iterator2","describe","acc","add","delete","newItems","removeItems","BaseSchema","deps","transforms","conditions","_mutate","_typeError","_whitelist","_blacklist","exclusiveTests","spec","withMutation","typeError","locale","strip","strict","abortEarly","recursive","nullable","presence","_value","_whitelistError","_blacklistError","cloneDeep","meta","before","combined","mergedSpec","merge","_typeCheck","condition","resolvedSchema","_cast","assert","isType","formattedValue","formattedResult","rawValue","_options","_this2","getDefault","_this3","_options$from","_options$originalValu","_options$strict","_options$abortEarly","initialTests","finalTests","maybeCb","_validate","validateSync","_getDefault","def","isStrict","exclusive","_isPresent","isNullable","opts","isExclusive","dep","enums","valids","resolved","resolveAll","invalids","_next$spec","_loop","_arr","_getIn","_arr2","alias","_i3","_arr3","optional","notRequired","Mixed","isAbsent","BooleanSchema","_BaseSchema","valueOf","rEmail","rUrl","rUUID","isTrimmed","objStringTag","StringSchema","_get","_getPrototypeOf","excludeEmptyString","_options$excludeEmpty","toUpperCase","NumberSchema","parsed","less","more","isInteger","_method","avail","truncate","isoReg","invalidDate","DateSchema","struct","numericKeys","minutesOffset","UTC","parse","isoParse","param","cast","prepareParam","INVALID_DATE","sortFields","excludedEdges","edges","excludes","a","b","addNode","depPath","toposort","arr","Infinity","some","ii","_err$path","sortByKeyOrder","isObject","unknown","known","defaultSort","ObjectSchema","_sortErrors","_nodes","_excludedEdges","shape","_options$stripUnknown","stripUnknown","intermediateValue","innerOptions","__validating","isChanged","prop","exists","fieldValue","inputValue","fieldSpec","_opts$from","_opts$originalValue","_opts$abortEarly","_opts$recursive","_this4","nextFields","_Object$entries$_i","schemaOrRef","_this5","dft","getDefaultFromShape","additions","picked","_step3","_iterator3","to","fromGetter","newObj","noAllow","unknownKeys","allow","mapKeys","transformKeys","camelCase","snakeCase","ArraySchema","_opts","castArray","castElement","_options$recursive","original","rejector","nativeCreate","getNative","listCacheClear","listCacheDelete","listCacheGet","listCacheHas","listCacheSet","ListCache","eq","isKeyable","__data__","isSymbol","baseAssignValue","baseForOwn","baseIteratee","iteratee","Parent","Class","isNativeReflectConstruct","_cache","Wrapper","createContext","Consumer","DataStateProvider","FilterStateProvider","webpackPolyfill","deprecate","paths","reIsDeepProp","reIsPlainProp","baseGetTag","isObjectLike","mapCacheClear","mapCacheDelete","mapCacheGet","mapCacheHas","mapCacheSet","MapCache","arrayLikeKeys","baseKeys","isArrayLike","arrayLikeToArray","iterableToArray","unsupportedIterableToArray","createCompounder","word","dirtyNumber","ceil","floor","Constructor","castPath","isArguments","isIndex","isLength","toKey","hasFunc","isKey","stringToPath","global","_arrayLikeToArray","arr2","funcToString","func","other","baseIsArguments","objectProto","propertyIsEnumerable","reIsUint","baseFor","stubFalse","freeExports","freeModule","Buffer","isBuffer","baseIsTypedArray","baseUnary","nodeUtil","nodeIsTypedArray","isTypedArray","baseMatches","baseMatchesProperty","identity","stackClear","stackDelete","stackGet","stackHas","stackSet","Stack","baseIsEqualDeep","baseIsEqual","bitmask","customizer","stack","SetCache","arraySome","cacheHas","equalFunc","isPartial","arrLength","othLength","arrStacked","othStacked","seen","arrValue","othValue","compared","othIndex","srcValue","arrayReduce","deburr","words","reApos","reHasUnicode","_unsupportedIterableToArray","minLen","asyncGeneratorStep","gen","_next","_throw","capitalize","cursor","sorted","visited","outgoingEdges","edge","makeOutgoingEdges","nodesHash","res","makeNodesHash","visit","predecessors","nodeRep","outgoing","child","uniqueNodes","prepareEntitiesForUpdate","existingData","existingEntities","newEntities","possibleRelation","newRelatedEntities","oldRelatedEntities","ticketsWithNewQuantity","allDates","allTickets","ticketsToUpdate","ticketIdToQuantityMap","idToPropMap","getMinDateCapacity","minDateCapacity","_existingData$tickets","_existingData$tickets2","_ref6","existingRelatedDateIds","newOnlyRelatedDateIds","dateId","minimumCapacity","nonNegativeTicketQuantity","parseInfinity","yearWiseMonths","_ref7","parsedDate","getFullYear","getMonth","monthsInTheYear","getMonthName","getYearWiseMonthsFromDates","_ref8","_ref9","months","_ref10","_ref11","monthNumber","monthName","useEventsHandler","useCacheRehydration","EntityCardDetailsSubscription","useEntityCardDetailsItems","filterByEntityType","EntityCardDetailsRegistry","NewEntityOptionsRegistry","_defineProperties","descriptor","protoProps","staticProps","subClass","superClass","_possibleConstructorReturn","assertThisInitialized","Derived","hasNativeReflectConstruct","Super","NewTarget","filterstate","defaultTickets","useDefaultTickets","convertPriceToTpcModifier","normalizedTickets","unSortedPrices","idToEntityMap","_arrayWithHoles","_nonIterableRest","receiver","desc","argIndex","framesToPop","nativeObjectToString","isOwn","unmasked","memoizeCapped","rePropName","reEscapeChar","charCodeAt","quote","subString","memoize","cache","memoized","Hash","hashClear","hashDelete","hashGet","hashHas","hashSet","isFunction","isMasked","toSource","reIsHostCtor","funcProto","reIsNative","coreJsData","maskSrcKey","uid","IE_PROTO","assocIndexOf","splice","getMapData","propIsEnumerable","toObject","test1","getOwnPropertyNames","test2","fromCharCode","test3","letter","shouldUseNative","arrayMap","symbolProto","createBaseFor","fromRight","keysFunc","baseTimes","inherited","isArr","isArg","isBuff","skipIndexes","typedArrayTags","freeProcess","process","binding","isPrototype","nativeKeys","Ctor","overArg","baseIsMatch","getMatchData","matchesStrictComparable","matchData","noCustomizer","objValue","COMPARE_PARTIAL_FLAG","_iterableToArray","pairs","LARGE_ARRAY_SIZE","equalArrays","equalByTag","equalObjects","getTag","argsTag","arrayTag","objectTag","objIsArr","othIsArr","objTag","othTag","objIsObj","othIsObj","isSameTag","objIsWrapped","othIsWrapped","objUnwrapped","othUnwrapped","setCacheAdd","setCacheHas","predicate","Uint8Array","mapToArray","setToArray","symbolValueOf","byteLength","byteOffset","buffer","convert","stacked","getAllKeys","objProps","objLength","objStacked","skipCtor","objCtor","othCtor","baseGetAllKeys","getSymbols","arrayPush","symbolsFunc","arrayFilter","stubArray","nativeGetSymbols","symbol","resIndex","DataView","WeakMap","mapTag","promiseTag","setTag","weakMapTag","dataViewTag","dataViewCtorString","mapCtorString","promiseCtorString","setCtorString","weakMapCtorString","ArrayBuffer","ctorString","isStrictComparable","hasIn","baseGet","baseHasIn","baseProperty","basePropertyDeep","accumulator","initAccum","deburrLetter","reLatin","reComboMark","basePropertyOf","asciiWords","hasUnicodeWord","unicodeWords","pattern","guard","reAsciiWord","reHasUnicodeWord","rsDingbatRange","rsLowerRange","rsUpperRange","rsBreakRange","rsMathOpRange","rsBreak","rsDigits","rsDingbat","rsLower","rsMisc","rsRegional","rsSurrPair","rsUpper","rsMiscLower","rsMiscUpper","rsOptContrLower","rsOptContrUpper","reOptMod","rsModifier","rsOptVar","rsSeq","rsEmoji","reUnicodeWord","upperFirst","createCaseFirst","castSlice","hasUnicode","stringToArray","methodName","strSymbols","chr","trailing","baseSlice","asciiToArray","unicodeToArray","rsAstral","rsCombo","rsFitz","rsNonAstral","rsSymbol","reUnicode","for","h","__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED","ReactCurrentOwner","__self","__source","q","$$typeof","_owner","jsx","jsxs","sourceSymbolKeys","allowArrayLike","it","F","_e","normalCompletion","didErr","step","_e2","useEntityActionsMenuItems","EntityActionsMenuRegistry","ReferenceError","useAssignmentManager","_useRelationsManager","useRelationsManager","addRelation","initializeRelations","initialize","isInitialized","removeRelation","setIsDirty","getAssignedTickets","getAssignedDates","updateAssignment","_ref3$remove","datetimeToTickets","relationId","ticketsToDatetimes","addAssignment","removeAssignment","removeNonTAMRelations","relationalEntity","relationalEntityToUse","newRelationKey","_props$entity2","initialDataIsValid","setInitialDataIsValid","assignmentManager","orphanEntities","useValidation","initialized","hasOrphanEntitiesOfType","_orphanEntities$entit2","_orphanEntities$entit","_props$entity","getOldRelation","oldRelatedTickets","newRelatedTickets","isInOld","isInNew","_orphanEntities$datet","_orphanEntities$ticke","hasOrphans","useFilteredDatetimes","datesInYearAndMonth","inYearAndMonth","notTrashed","useFilteredTickets","isExpired","_useTAMContext","filteredDatetimes","filteredTickets","getExistingData","bulkEditTickets","useBulkEditTickets","updateEntities","ticketsWithChangedQuantity","uniqueInputs","entityHasGuid","DEFAULT_VALIDATION_DATA","validationData","setValidationData","TAMData","newTAMData","emptyRelationalEntities","arrayWithHoles","_n","_d","_s","nonIterableRest","_setPrototypeOf"],"mappings":";qFACE,SAASA,EAAqBC,GAQ7B,IAPA,IAMIC,EAAUC,EANVC,EAAWH,EAAK,GAChBI,EAAcJ,EAAK,GAKAK,EAAI,EAAGC,EAAW,GACpCD,EAAIF,EAASI,OAAQF,IACzBH,EAAUC,EAASE,GAChBG,OAAOC,UAAUC,eAAeC,KAAKC,EAAiBV,IAAYU,EAAgBV,IACpFI,EAASO,KAAKD,EAAgBV,GAAS,IAExCU,EAAgBV,GAAW,EAE5B,IAAID,KAAYG,EACZI,OAAOC,UAAUC,eAAeC,KAAKP,EAAaH,KACpDa,EAAQb,GAAYG,EAAYH,IAKlC,IAFGc,GAAqBA,EAAoBf,GAEtCM,EAASC,QACdD,EAASU,OAATV,GAOF,IAAIW,EAAmB,GAGnBC,EAAqB,CACxB,EAAG,GAMAN,EAAkB,CACrB,EAAG,GAWJ,SAASO,EAAoBlB,GAG5B,GAAGgB,EAAiBhB,GACnB,OAAOgB,EAAiBhB,GAAUmB,QAGnC,IAAIC,EAASJ,EAAiBhB,GAAY,CACzCI,EAAGJ,EACHqB,GAAG,EACHF,QAAS,IAUV,OANAN,EAAQb,GAAUU,KAAKU,EAAOD,QAASC,EAAQA,EAAOD,QAASD,GAG/DE,EAAOC,GAAI,EAGJD,EAAOD,QAKfD,EAAoBI,EAAI,SAAuBrB,GAC9C,IAAIsB,EAAW,GAKZN,EAAmBhB,GAAUsB,EAASX,KAAKK,EAAmBhB,IACzB,IAAhCgB,EAAmBhB,IAFX,CAAC,EAAI,EAAE,GAAK,EAAE,GAAK,GAE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AMzE,GAIlB,OAAO1gB,GDnBuB,CAAqBsD,EAAKlyD,IAAM,OAAAu4D,EAAA,GAA2BrG,EAAKlyD,IAAM,OAAAi0E,EAAA,O,gCELvF,SAASC,EAAgBvvE,EAAGlD,GAMzC,OALAyyE,EAAkB/zE,OAAOmgD,gBAAkB,SAAyB37C,EAAGlD,GAErE,OADAkD,EAAE47C,UAAY9+C,EACPkD,IAGcA,EAAGlD,GAN5B","file":"static/js/eventEditor.a576dbed.js","sourcesContent":[" \t// install a JSONP callback for chunk loading\n \tfunction webpackJsonpCallback(data) {\n \t\tvar chunkIds = data[0];\n \t\tvar moreModules = data[1];\n\n\n \t\t// add \"moreModules\" to the modules object,\n \t\t// then flag all \"chunkIds\" as loaded and fire callback\n \t\tvar moduleId, chunkId, i = 0, resolves = [];\n \t\tfor(;i < chunkIds.length; i++) {\n \t\t\tchunkId = chunkIds[i];\n \t\t\tif(Object.prototype.hasOwnProperty.call(installedChunks, chunkId) && installedChunks[chunkId]) {\n \t\t\t\tresolves.push(installedChunks[chunkId][0]);\n \t\t\t}\n \t\t\tinstalledChunks[chunkId] = 0;\n \t\t}\n \t\tfor(moduleId in moreModules) {\n \t\t\tif(Object.prototype.hasOwnProperty.call(moreModules, moduleId)) {\n \t\t\t\tmodules[moduleId] = moreModules[moduleId];\n \t\t\t}\n \t\t}\n \t\tif(parentJsonpFunction) parentJsonpFunction(data);\n\n \t\twhile(resolves.length) {\n \t\t\tresolves.shift()();\n \t\t}\n\n \t};\n\n\n \t// The module cache\n \tvar installedModules = {};\n\n \t// object to store loaded CSS chunks\n \tvar installedCssChunks = {\n \t\t9: 0\n \t};\n\n \t// object to store loaded and loading chunks\n \t// undefined = chunk not loaded, null = chunk preloaded/prefetched\n \t// Promise = chunk loading, 0 = chunk loaded\n \tvar installedChunks = {\n \t\t9: 0\n \t};\n\n\n\n \t// script path function\n \tfunction jsonpScriptSrc(chunkId) {\n \t\treturn __webpack_require__.p + \"static/js/\" + ({\"5\":\"dates-card-view\",\"6\":\"dates-table-view\",\"25\":\"tickets-card-view\",\"26\":\"tickets-table-view\"}[chunkId]||chunkId) + \".\" + {\"5\":\"3ec62a13\",\"6\":\"6e63357c\",\"25\":\"d8616a37\",\"26\":\"c7a37c69\"}[chunkId] + \".chunk.js\"\n \t}\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n \t// This file contains only the entry chunk.\n \t// The chunk loading function for additional chunks\n \t__webpack_require__.e = function requireEnsure(chunkId) {\n \t\tvar promises = [];\n\n\n \t\t// mini-css-extract-plugin CSS loading\n \t\tvar cssChunks = {\"6\":1,\"25\":1,\"26\":1};\n \t\tif(installedCssChunks[chunkId]) promises.push(installedCssChunks[chunkId]);\n \t\telse if(installedCssChunks[chunkId] !== 0 && cssChunks[chunkId]) {\n \t\t\tpromises.push(installedCssChunks[chunkId] = new Promise(function(resolve, reject) {\n \t\t\t\tvar href = \"static/css/\" + ({\"5\":\"dates-card-view\",\"6\":\"dates-table-view\",\"25\":\"tickets-card-view\",\"26\":\"tickets-table-view\"}[chunkId]||chunkId) + \".\" + {\"5\":\"31d6cfe0\",\"6\":\"fc6705f5\",\"25\":\"7d56f661\",\"26\":\"7d56f661\"}[chunkId] + \".chunk.css\";\n \t\t\t\tvar fullhref = __webpack_require__.p + href;\n \t\t\t\tvar existingLinkTags = document.getElementsByTagName(\"link\");\n \t\t\t\tfor(var i = 0; i < existingLinkTags.length; i++) {\n \t\t\t\t\tvar tag = existingLinkTags[i];\n \t\t\t\t\tvar dataHref = tag.getAttribute(\"data-href\") || tag.getAttribute(\"href\");\n \t\t\t\t\tif(tag.rel === \"stylesheet\" && (dataHref === href || dataHref === fullhref)) return resolve();\n \t\t\t\t}\n \t\t\t\tvar existingStyleTags = document.getElementsByTagName(\"style\");\n \t\t\t\tfor(var i = 0; i < existingStyleTags.length; i++) {\n \t\t\t\t\tvar tag = existingStyleTags[i];\n \t\t\t\t\tvar dataHref = tag.getAttribute(\"data-href\");\n \t\t\t\t\tif(dataHref === href || dataHref === fullhref) return resolve();\n \t\t\t\t}\n \t\t\t\tvar linkTag = document.createElement(\"link\");\n\n \t\t\t\tlinkTag.rel = \"stylesheet\";\n \t\t\t\tlinkTag.type = \"text/css\";\n \t\t\t\tvar onLinkComplete = function (event) {\n \t\t\t\t\t// avoid mem leaks.\n \t\t\t\t\tlinkTag.onerror = linkTag.onload = null;\n \t\t\t\t\tif (event.type === 'load') {\n \t\t\t\t\t\tresolve();\n \t\t\t\t\t} else {\n \t\t\t\t\t\tvar errorType = event && (event.type === 'load' ? 'missing' : event.type);\n \t\t\t\t\t\tvar realHref = event && event.target && event.target.href || fullhref;\n \t\t\t\t\t\tvar err = new Error(\"Loading CSS chunk \" + chunkId + \" failed.\\n(\" + realHref + \")\");\n \t\t\t\t\t\terr.code = \"CSS_CHUNK_LOAD_FAILED\";\n \t\t\t\t\t\terr.type = errorType;\n \t\t\t\t\t\terr.request = realHref;\n \t\t\t\t\t\tdelete installedCssChunks[chunkId]\n \t\t\t\t\t\tlinkTag.parentNode.removeChild(linkTag)\n \t\t\t\t\t\treject(err);\n \t\t\t\t\t}\n \t\t\t\t};\n \t\t\t\tlinkTag.onerror = linkTag.onload = onLinkComplete;\n \t\t\t\tlinkTag.href = fullhref;\n\n \t\t\t\tdocument.head.appendChild(linkTag);\n \t\t\t}).then(function() {\n \t\t\t\tinstalledCssChunks[chunkId] = 0;\n \t\t\t}));\n \t\t}\n\n \t\t// JSONP chunk loading for javascript\n\n \t\tvar installedChunkData = installedChunks[chunkId];\n \t\tif(installedChunkData !== 0) { // 0 means \"already installed\".\n\n \t\t\t// a Promise means \"currently loading\".\n \t\t\tif(installedChunkData) {\n \t\t\t\tpromises.push(installedChunkData[2]);\n \t\t\t} else {\n \t\t\t\t// setup Promise in chunk cache\n \t\t\t\tvar promise = new Promise(function(resolve, reject) {\n \t\t\t\t\tinstalledChunkData = installedChunks[chunkId] = [resolve, reject];\n \t\t\t\t});\n \t\t\t\tpromises.push(installedChunkData[2] = promise);\n\n \t\t\t\t// start chunk loading\n \t\t\t\tvar script = document.createElement('script');\n \t\t\t\tvar onScriptComplete;\n\n \t\t\t\tscript.charset = 'utf-8';\n \t\t\t\tscript.timeout = 120;\n \t\t\t\tif (__webpack_require__.nc) {\n \t\t\t\t\tscript.setAttribute(\"nonce\", __webpack_require__.nc);\n \t\t\t\t}\n \t\t\t\tscript.src = jsonpScriptSrc(chunkId);\n\n \t\t\t\t// create error before stack unwound to get useful stacktrace later\n \t\t\t\tvar error = new Error();\n \t\t\t\tonScriptComplete = function (event) {\n \t\t\t\t\t// avoid mem leaks in IE.\n \t\t\t\t\tscript.onerror = script.onload = null;\n \t\t\t\t\tclearTimeout(timeout);\n \t\t\t\t\tvar chunk = installedChunks[chunkId];\n \t\t\t\t\tif(chunk !== 0) {\n \t\t\t\t\t\tif(chunk) {\n \t\t\t\t\t\t\tvar errorType = event && (event.type === 'load' ? 'missing' : event.type);\n \t\t\t\t\t\t\tvar realSrc = event && event.target && event.target.src;\n \t\t\t\t\t\t\terror.message = 'Loading chunk ' + chunkId + ' failed.\\n(' + errorType + ': ' + realSrc + ')';\n \t\t\t\t\t\t\terror.name = 'ChunkLoadError';\n \t\t\t\t\t\t\terror.type = errorType;\n \t\t\t\t\t\t\terror.request = realSrc;\n \t\t\t\t\t\t\tchunk[1](error);\n \t\t\t\t\t\t}\n \t\t\t\t\t\tinstalledChunks[chunkId] = undefined;\n \t\t\t\t\t}\n \t\t\t\t};\n \t\t\t\tvar timeout = setTimeout(function(){\n \t\t\t\t\tonScriptComplete({ type: 'timeout', target: script });\n \t\t\t\t}, 120000);\n \t\t\t\tscript.onerror = script.onload = onScriptComplete;\n \t\t\t\tdocument.head.appendChild(script);\n \t\t\t}\n \t\t}\n \t\treturn Promise.all(promises);\n \t};\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"/\";\n\n \t// on error function for async loading\n \t__webpack_require__.oe = function(err) { console.error(err); throw err; };\n\n \tvar jsonpArray = this[\"webpackJsonproot\"] = this[\"webpackJsonproot\"] || [];\n \tvar oldJsonpFunction = jsonpArray.push.bind(jsonpArray);\n \tjsonpArray.push = webpackJsonpCallback;\n \tjsonpArray = jsonpArray.slice();\n \tfor(var i = 0; i < jsonpArray.length; i++) webpackJsonpCallback(jsonpArray[i]);\n \tvar parentJsonpFunction = oldJsonpFunction;\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 1692);\n","(function() { module.exports = window[\"React\"]; }());","'use strict';\n\nif (process.env.NODE_ENV === 'production') {\n module.exports = require('./cjs/react-jsx-runtime.production.min.js');\n} else {\n module.exports = require('./cjs/react-jsx-runtime.development.js');\n}\n","/*!\n Copyright (c) 2018 Jed Watson.\n Licensed under the MIT License (MIT), see\n http://jedwatson.github.io/classnames\n*/\n/* global define */\n\n(function () {\n\t'use strict';\n\n\tvar hasOwn = {}.hasOwnProperty;\n\n\tfunction classNames() {\n\t\tvar classes = [];\n\n\t\tfor (var i = 0; i < arguments.length; i++) {\n\t\t\tvar arg = arguments[i];\n\t\t\tif (!arg) continue;\n\n\t\t\tvar argType = typeof arg;\n\n\t\t\tif (argType === 'string' || argType === 'number') {\n\t\t\t\tclasses.push(arg);\n\t\t\t} else if (Array.isArray(arg)) {\n\t\t\t\tif (arg.length) {\n\t\t\t\t\tvar inner = classNames.apply(null, arg);\n\t\t\t\t\tif (inner) {\n\t\t\t\t\t\tclasses.push(inner);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} else if (argType === 'object') {\n\t\t\t\tif (arg.toString === Object.prototype.toString) {\n\t\t\t\t\tfor (var key in arg) {\n\t\t\t\t\t\tif (hasOwn.call(arg, key) && arg[key]) {\n\t\t\t\t\t\t\tclasses.push(key);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tclasses.push(arg.toString());\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn classes.join(' ');\n\t}\n\n\tif (typeof module !== 'undefined' && module.exports) {\n\t\tclassNames.default = classNames;\n\t\tmodule.exports = classNames;\n\t} else if (typeof define === 'function' && typeof define.amd === 'object' && define.amd) {\n\t\t// register as 'classnames', consistent with npm package name\n\t\tdefine('classnames', [], function () {\n\t\t\treturn classNames;\n\t\t});\n\t} else {\n\t\twindow.classNames = classNames;\n\t}\n}());\n","import toInteger from \"../_lib/toInteger/index.js\";\nimport requiredArgs from \"../_lib/requiredArgs/index.js\";\nvar MILLISECONDS_IN_HOUR = 3600000;\nvar MILLISECONDS_IN_MINUTE = 60000;\nvar DEFAULT_ADDITIONAL_DIGITS = 2;\nvar patterns = {\n dateTimeDelimiter: /[T ]/,\n timeZoneDelimiter: /[Z ]/i,\n timezone: /([Z+-].*)$/\n};\nvar dateRegex = /^-?(?:(\\d{3})|(\\d{2})(?:-?(\\d{2}))?|W(\\d{2})(?:-?(\\d{1}))?|)$/;\nvar timeRegex = /^(\\d{2}(?:[.,]\\d*)?)(?::?(\\d{2}(?:[.,]\\d*)?))?(?::?(\\d{2}(?:[.,]\\d*)?))?$/;\nvar timezoneRegex = /^([+-])(\\d{2})(?::?(\\d{2}))?$/;\n/**\n * @name parseISO\n * @category Common Helpers\n * @summary Parse ISO string\n *\n * @description\n * Parse the given string in ISO 8601 format and return an instance of Date.\n *\n * Function accepts complete ISO 8601 formats as well as partial implementations.\n * ISO 8601: http://en.wikipedia.org/wiki/ISO_8601\n *\n * If the argument isn't a string, the function cannot parse the string or\n * the values are invalid, it returns Invalid Date.\n *\n * ### v2.0.0 breaking changes:\n *\n * - [Changes that are common for the whole library](https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#Common-Changes).\n *\n * - The previous `parse` implementation was renamed to `parseISO`.\n *\n * ```javascript\n * // Before v2.0.0\n * parse('2016-01-01')\n *\n * // v2.0.0 onward\n * parseISO('2016-01-01')\n * ```\n *\n * - `parseISO` now validates separate date and time values in ISO-8601 strings\n * and returns `Invalid Date` if the date is invalid.\n *\n * ```javascript\n * parseISO('2018-13-32')\n * //=> Invalid Date\n * ```\n *\n * - `parseISO` now doesn't fall back to `new Date` constructor\n * if it fails to parse a string argument. Instead, it returns `Invalid Date`.\n *\n * @param {String} argument - the value to convert\n * @param {Object} [options] - an object with options.\n * @param {0|1|2} [options.additionalDigits=2] - the additional number of digits in the extended year format\n * @returns {Date} the parsed date in the local time zone\n * @throws {TypeError} 1 argument required\n * @throws {RangeError} `options.additionalDigits` must be 0, 1 or 2\n *\n * @example\n * // Convert string '2014-02-11T11:30:30' to date:\n * var result = parseISO('2014-02-11T11:30:30')\n * //=> Tue Feb 11 2014 11:30:30\n *\n * @example\n * // Convert string '+02014101' to date,\n * // if the additional number of digits in the extended year format is 1:\n * var result = parseISO('+02014101', { additionalDigits: 1 })\n * //=> Fri Apr 11 2014 00:00:00\n */\n\nexport default function parseISO(argument, dirtyOptions) {\n requiredArgs(1, arguments);\n var options = dirtyOptions || {};\n var additionalDigits = options.additionalDigits == null ? DEFAULT_ADDITIONAL_DIGITS : toInteger(options.additionalDigits);\n\n if (additionalDigits !== 2 && additionalDigits !== 1 && additionalDigits !== 0) {\n throw new RangeError('additionalDigits must be 0, 1 or 2');\n }\n\n if (!(typeof argument === 'string' || Object.prototype.toString.call(argument) === '[object String]')) {\n return new Date(NaN);\n }\n\n var dateStrings = splitDateString(argument);\n var date;\n\n if (dateStrings.date) {\n var parseYearResult = parseYear(dateStrings.date, additionalDigits);\n date = parseDate(parseYearResult.restDateString, parseYearResult.year);\n }\n\n if (isNaN(date) || !date) {\n return new Date(NaN);\n }\n\n var timestamp = date.getTime();\n var time = 0;\n var offset;\n\n if (dateStrings.time) {\n time = parseTime(dateStrings.time);\n\n if (isNaN(time) || time === null) {\n return new Date(NaN);\n }\n }\n\n if (dateStrings.timezone) {\n offset = parseTimezone(dateStrings.timezone);\n\n if (isNaN(offset)) {\n return new Date(NaN);\n }\n } else {\n var dirtyDate = new Date(timestamp + time); // js parsed string assuming it's in UTC timezone\n // but we need it to be parsed in our timezone\n // so we use utc values to build date in our timezone.\n // Year values from 0 to 99 map to the years 1900 to 1999\n // so set year explicitly with setFullYear.\n\n var result = new Date(0);\n result.setFullYear(dirtyDate.getUTCFullYear(), dirtyDate.getUTCMonth(), dirtyDate.getUTCDate());\n result.setHours(dirtyDate.getUTCHours(), dirtyDate.getUTCMinutes(), dirtyDate.getUTCSeconds(), dirtyDate.getUTCMilliseconds());\n return result;\n }\n\n return new Date(timestamp + time + offset);\n}\n\nfunction splitDateString(dateString) {\n var dateStrings = {};\n var array = dateString.split(patterns.dateTimeDelimiter);\n var timeString; // The regex match should only return at maximum two array elements.\n // [date], [time], or [date, time].\n\n if (array.length > 2) {\n return dateStrings;\n }\n\n if (/:/.test(array[0])) {\n dateStrings.date = null;\n timeString = array[0];\n } else {\n dateStrings.date = array[0];\n timeString = array[1];\n\n if (patterns.timeZoneDelimiter.test(dateStrings.date)) {\n dateStrings.date = dateString.split(patterns.timeZoneDelimiter)[0];\n timeString = dateString.substr(dateStrings.date.length, dateString.length);\n }\n }\n\n if (timeString) {\n var token = patterns.timezone.exec(timeString);\n\n if (token) {\n dateStrings.time = timeString.replace(token[1], '');\n dateStrings.timezone = token[1];\n } else {\n dateStrings.time = timeString;\n }\n }\n\n return dateStrings;\n}\n\nfunction parseYear(dateString, additionalDigits) {\n var regex = new RegExp('^(?:(\\\\d{4}|[+-]\\\\d{' + (4 + additionalDigits) + '})|(\\\\d{2}|[+-]\\\\d{' + (2 + additionalDigits) + '})$)');\n var captures = dateString.match(regex); // Invalid ISO-formatted year\n\n if (!captures) return {\n year: null\n };\n var year = captures[1] && parseInt(captures[1]);\n var century = captures[2] && parseInt(captures[2]);\n return {\n year: century == null ? year : century * 100,\n restDateString: dateString.slice((captures[1] || captures[2]).length)\n };\n}\n\nfunction parseDate(dateString, year) {\n // Invalid ISO-formatted year\n if (year === null) return null;\n var captures = dateString.match(dateRegex); // Invalid ISO-formatted string\n\n if (!captures) return null;\n var isWeekDate = !!captures[4];\n var dayOfYear = parseDateUnit(captures[1]);\n var month = parseDateUnit(captures[2]) - 1;\n var day = parseDateUnit(captures[3]);\n var week = parseDateUnit(captures[4]);\n var dayOfWeek = parseDateUnit(captures[5]) - 1;\n\n if (isWeekDate) {\n if (!validateWeekDate(year, week, dayOfWeek)) {\n return new Date(NaN);\n }\n\n return dayOfISOWeekYear(year, week, dayOfWeek);\n } else {\n var date = new Date(0);\n\n if (!validateDate(year, month, day) || !validateDayOfYearDate(year, dayOfYear)) {\n return new Date(NaN);\n }\n\n date.setUTCFullYear(year, month, Math.max(dayOfYear, day));\n return date;\n }\n}\n\nfunction parseDateUnit(value) {\n return value ? parseInt(value) : 1;\n}\n\nfunction parseTime(timeString) {\n var captures = timeString.match(timeRegex);\n if (!captures) return null; // Invalid ISO-formatted time\n\n var hours = parseTimeUnit(captures[1]);\n var minutes = parseTimeUnit(captures[2]);\n var seconds = parseTimeUnit(captures[3]);\n\n if (!validateTime(hours, minutes, seconds)) {\n return NaN;\n }\n\n return hours * MILLISECONDS_IN_HOUR + minutes * MILLISECONDS_IN_MINUTE + seconds * 1000;\n}\n\nfunction parseTimeUnit(value) {\n return value && parseFloat(value.replace(',', '.')) || 0;\n}\n\nfunction parseTimezone(timezoneString) {\n if (timezoneString === 'Z') return 0;\n var captures = timezoneString.match(timezoneRegex);\n if (!captures) return 0;\n var sign = captures[1] === '+' ? -1 : 1;\n var hours = parseInt(captures[2]);\n var minutes = captures[3] && parseInt(captures[3]) || 0;\n\n if (!validateTimezone(hours, minutes)) {\n return NaN;\n }\n\n return sign * (hours * MILLISECONDS_IN_HOUR + minutes * MILLISECONDS_IN_MINUTE);\n}\n\nfunction dayOfISOWeekYear(isoWeekYear, week, day) {\n var date = new Date(0);\n date.setUTCFullYear(isoWeekYear, 0, 4);\n var fourthOfJanuaryDay = date.getUTCDay() || 7;\n var diff = (week - 1) * 7 + day + 1 - fourthOfJanuaryDay;\n date.setUTCDate(date.getUTCDate() + diff);\n return date;\n} // Validation functions\n// February is null to handle the leap year (using ||)\n\n\nvar daysInMonths = [31, null, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31];\n\nfunction isLeapYearIndex(year) {\n return year % 400 === 0 || year % 4 === 0 && year % 100;\n}\n\nfunction validateDate(year, month, date) {\n return month >= 0 && month <= 11 && date >= 1 && date <= (daysInMonths[month] || (isLeapYearIndex(year) ? 29 : 28));\n}\n\nfunction validateDayOfYearDate(year, dayOfYear) {\n return dayOfYear >= 1 && dayOfYear <= (isLeapYearIndex(year) ? 366 : 365);\n}\n\nfunction validateWeekDate(_year, week, day) {\n return week >= 1 && week <= 53 && day >= 0 && day <= 6;\n}\n\nfunction validateTime(hours, minutes, seconds) {\n if (hours === 24) {\n return minutes === 0 && seconds === 0;\n }\n\n return seconds >= 0 && seconds < 60 && minutes >= 0 && minutes < 60 && hours >= 0 && hours < 25;\n}\n\nfunction validateTimezone(_hours, minutes) {\n return minutes >= 0 && minutes <= 59;\n}","export default function _typeof(obj) {\n \"@babel/helpers - typeof\";\n\n if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") {\n _typeof = function _typeof(obj) {\n return typeof obj;\n };\n } else {\n _typeof = function _typeof(obj) {\n return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj;\n };\n }\n\n return _typeof(obj);\n}","export default function _isNativeReflectConstruct() {\n if (typeof Reflect === \"undefined\" || !Reflect.construct) return false;\n if (Reflect.construct.sham) return false;\n if (typeof Proxy === \"function\") return true;\n\n try {\n Date.prototype.toString.call(Reflect.construct(Date, [], function () {}));\n return true;\n } catch (e) {\n return false;\n }\n}","(function() { module.exports = window[\"eventespresso\"][\"predicates\"]; }());","var freeGlobal = require('./_freeGlobal');\n\n/** Detect free variable `self`. */\nvar freeSelf = typeof self == 'object' && self && self.Object === Object && self;\n\n/** Used as a reference to the global object. */\nvar root = freeGlobal || freeSelf || Function('return this')();\n\nmodule.exports = root;\n","import { useContext } from 'react';\nimport invariant from 'invariant';\n\nimport { FilterStateManager } from './types';\nimport { FilterStateContext } from '../../context';\n\nconst useFilterState = (): FilterStateManager => {\n\tconst value = useContext(FilterStateContext);\n\n\tinvariant(value, 'useFilterState must be used inside TAM component');\n\n\treturn value;\n};\n\nexport default useFilterState;\n","import type { AnyObject } from '@eventespresso/utils';\nimport { ContextProvider } from './ContextProvider';\nimport type { WithContextProps } from './types';\n\nconst withContext =

(\n\tComponent: React.ComponentType

,\n\tcontextProps: WithContextProps\n): React.FC

=> {\n\tconst WrappedComponent: React.FC

= (props) => {\n\t\treturn (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t);\n\t};\n\n\treturn WrappedComponent;\n};\n\nexport default withContext;\n","import { useContext } from 'react';\nimport { Context } from './ContextProvider';\nimport type { ContextProps } from './types';\nimport invariant from 'invariant';\n\nconst useTAMContext = (): ContextProps => {\n\tconst value = useContext(Context);\n\n\tinvariant(value, 'useTAMContext must be used inside TAM component');\n\n\treturn value;\n};\n\nexport default useTAMContext;\n","import { useContext } from 'react';\nimport invariant from 'invariant';\n\nimport { DataStateContext } from '../context';\nimport type { DataStateManager } from './types';\n\nconst useDataState = (): DataStateManager => {\n\tconst state = useContext(DataStateContext);\n\n\tinvariant(state, 'useDataState must be used inside DataStateProvider');\n\n\treturn state;\n};\n\nexport default useDataState;\n","import { useCallback } from 'react';\n\nimport { useTicketMutator } from '@eventespresso/edtr-services';\nimport { useMutateTicket } from '@eventespresso/tpc';\n\nimport type { DataState } from './types';\n\ntype UseSubmitForm = (dataState: DataState) => () => Promise;\n\nconst useSubmitForm: UseSubmitForm = ({ deletedTickets, tickets }) => {\n\tconst mutateTicket = useMutateTicket(true);\n\tconst { deleteEntity: deleteTicket } = useTicketMutator();\n\n\treturn useCallback(async () => {\n\t\tawait Promise.all(Object.values(tickets).map(mutateTicket));\n\n\t\tif (deletedTickets.length) {\n\t\t\tawait Promise.all(deletedTickets.map((id) => deleteTicket({ id, deletePermanently: true })));\n\t\t}\n\t}, [deleteTicket, deletedTickets, mutateTicket, tickets]);\n};\n\nexport default useSubmitForm;\n","import { useMemo } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { useDatetimes } from '@eventespresso/edtr-services';\nimport { SelectWithLabel } from '@eventespresso/ui-components';\nimport { getMonthsListFromDatetimes } from '../../utils';\nimport type { FilterStateManager } from '../filterState';\n\ntype DatesByMonthControlProps = Pick;\n\nconst DatesByMonthControl: React.FC = ({ datesByMonth, setDatesByMonth }) => {\n\tconst datetimes = useDatetimes();\n\tconst monthsList = getMonthsListFromDatetimes(datetimes);\n\n\t// e.g. \"2020:4\" for May 2020\n\tconst yearMonth = datesByMonth.join(':');\n\n\t// Add all dates option at the top, \"0:0\" to match the \"year:month\" format\n\tconst monthsListWithAllDates = useMemo(\n\t\t() => [{ value: '0:0', label: __('All Dates') }, ...monthsList],\n\t\t[monthsList]\n\t);\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default DatesByMonthControl;\n","import { __ } from '@eventespresso/i18n';\n\nimport { SwitchWithLabel } from '@eventespresso/ui-components';\nimport type { FilterStateManager } from '../filterState';\n\ntype ShowExpiredTicketsControlProps = Pick;\n\nconst ShowExpiredTicketsControl: React.FC = ({\n\tshowExpiredTickets,\n\tsetShowExpiredTickets,\n}) => {\n\treturn (\n\t\t\n\t);\n};\n\nexport default ShowExpiredTicketsControl;\n","import { __ } from '@eventespresso/i18n';\n\nimport { SwitchWithLabel } from '@eventespresso/ui-components';\nimport { FilterStateManager } from '../filterState';\n\ntype ShowTrashedDatesControlProps = Pick;\n\nconst ShowTrashedDatesControl: React.FC = ({ showTrashedDates, setShowTrashedDates }) => {\n\treturn (\n\t\t\n\t);\n};\n\nexport default ShowTrashedDatesControl;\n","import { __ } from '@eventespresso/i18n';\n\nimport { SwitchWithLabel } from '@eventespresso/ui-components';\nimport type { FilterStateManager } from '../filterState';\n\ntype ShowTrashedTicketsControlProps = Pick;\n\nconst ShowTrashedTicketsControl: React.FC = ({\n\tshowTrashedTickets,\n\tsetShowTrashedTickets,\n}) => {\n\treturn (\n\t\t\n\t);\n};\n\nexport default ShowTrashedTicketsControl;\n","import {\n\tDatesByMonthControl,\n\tShowExpiredTicketsControl,\n\tShowTrashedDatesControl,\n\tShowTrashedTicketsControl,\n} from './controls';\nimport { useTAMContext } from '../context';\nimport { useFilterState } from '../filters';\n\nconst FilterBar: React.FC = () => {\n\tconst { assignmentType } = useTAMContext();\n\tconst {\n\t\tdatesByMonth,\n\t\tsetDatesByMonth,\n\t\tsetShowExpiredTickets,\n\t\tsetShowTrashedDates,\n\t\tsetShowTrashedTickets,\n\t\tshowExpiredTickets,\n\t\tshowTrashedDates,\n\t\tshowTrashedTickets,\n\t} = useFilterState();\n\n\treturn (\n\t\t

\n\t\t\t{assignmentType !== 'forDate' && (\n\t\t\t\t// useless when TAM is for single date\n\t\t\t\t<>\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t)}\n\n\t\t\t{assignmentType !== 'forTicket' && (\n\t\t\t\t// useless when TAM is for single ticket\n\t\t\t\t<>\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t)}\n\t\t
\n\t);\n};\n\nexport default FilterBar;\n","/**\n * Checks if `value` is classified as an `Array` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an array, else `false`.\n * @example\n *\n * _.isArray([1, 2, 3]);\n * // => true\n *\n * _.isArray(document.body.children);\n * // => false\n *\n * _.isArray('abc');\n * // => false\n *\n * _.isArray(_.noop);\n * // => false\n */\nvar isArray = Array.isArray;\n\nmodule.exports = isArray;\n","/**\n * Based on Kendo UI Core expression code \n */\n'use strict'\n\nfunction Cache(maxSize) {\n this._maxSize = maxSize\n this.clear()\n}\nCache.prototype.clear = function () {\n this._size = 0\n this._values = Object.create(null)\n}\nCache.prototype.get = function (key) {\n return this._values[key]\n}\nCache.prototype.set = function (key, value) {\n this._size >= this._maxSize && this.clear()\n if (!(key in this._values)) this._size++\n\n return (this._values[key] = value)\n}\n\nvar SPLIT_REGEX = /[^.^\\]^[]+|(?=\\[\\]|\\.\\.)/g,\n DIGIT_REGEX = /^\\d+$/,\n LEAD_DIGIT_REGEX = /^\\d/,\n SPEC_CHAR_REGEX = /[~`!#$%\\^&*+=\\-\\[\\]\\\\';,/{}|\\\\\":<>\\?]/g,\n CLEAN_QUOTES_REGEX = /^\\s*(['\"]?)(.*?)(\\1)\\s*$/,\n MAX_CACHE_SIZE = 512\n\nvar pathCache = new Cache(MAX_CACHE_SIZE),\n setCache = new Cache(MAX_CACHE_SIZE),\n getCache = new Cache(MAX_CACHE_SIZE)\n\nvar config\n\nmodule.exports = {\n Cache: Cache,\n\n split: split,\n\n normalizePath: normalizePath,\n\n setter: function (path) {\n var parts = normalizePath(path)\n\n return (\n setCache.get(path) ||\n setCache.set(path, function setter(obj, value) {\n var index = 0\n var len = parts.length\n var data = obj\n\n while (index < len - 1) {\n var part = parts[index]\n if (\n part === '__proto__' ||\n part === 'constructor' ||\n part === 'prototype'\n ) {\n return obj\n }\n\n data = data[parts[index++]]\n }\n data[parts[index]] = value\n })\n )\n },\n\n getter: function (path, safe) {\n var parts = normalizePath(path)\n return (\n getCache.get(path) ||\n getCache.set(path, function getter(data) {\n var index = 0,\n len = parts.length\n while (index < len) {\n if (data != null || !safe) data = data[parts[index++]]\n else return\n }\n return data\n })\n )\n },\n\n join: function (segments) {\n return segments.reduce(function (path, part) {\n return (\n path +\n (isQuoted(part) || DIGIT_REGEX.test(part)\n ? '[' + part + ']'\n : (path ? '.' : '') + part)\n )\n }, '')\n },\n\n forEach: function (path, cb, thisArg) {\n forEach(Array.isArray(path) ? path : split(path), cb, thisArg)\n },\n}\n\nfunction normalizePath(path) {\n return (\n pathCache.get(path) ||\n pathCache.set(\n path,\n split(path).map(function (part) {\n return part.replace(CLEAN_QUOTES_REGEX, '$2')\n })\n )\n )\n}\n\nfunction split(path) {\n return path.match(SPLIT_REGEX)\n}\n\nfunction forEach(parts, iter, thisArg) {\n var len = parts.length,\n part,\n idx,\n isArray,\n isBracket\n\n for (idx = 0; idx < len; idx++) {\n part = parts[idx]\n\n if (part) {\n if (shouldBeQuoted(part)) {\n part = '\"' + part + '\"'\n }\n\n isBracket = isQuoted(part)\n isArray = !isBracket && /^\\d+$/.test(part)\n\n iter.call(thisArg, part, isBracket, isArray, idx, parts)\n }\n }\n}\n\nfunction isQuoted(str) {\n return (\n typeof str === 'string' && str && [\"'\", '\"'].indexOf(str.charAt(0)) !== -1\n )\n}\n\nfunction hasLeadingNumber(part) {\n return part.match(LEAD_DIGIT_REGEX) && !part.match(DIGIT_REGEX)\n}\n\nfunction hasSpecialChars(part) {\n return SPEC_CHAR_REGEX.test(part)\n}\n\nfunction shouldBeQuoted(part) {\n return !isQuoted(part) && (hasLeadingNumber(part) || hasSpecialChars(part))\n}\n","function toVal(mix) {\n\tvar k, y, str='';\n\n\tif (typeof mix === 'string' || typeof mix === 'number') {\n\t\tstr += mix;\n\t} else if (typeof mix === 'object') {\n\t\tif (Array.isArray(mix)) {\n\t\t\tfor (k=0; k < mix.length; k++) {\n\t\t\t\tif (mix[k]) {\n\t\t\t\t\tif (y = toVal(mix[k])) {\n\t\t\t\t\t\tstr && (str += ' ');\n\t\t\t\t\t\tstr += y;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t} else {\n\t\t\tfor (k in mix) {\n\t\t\t\tif (mix[k]) {\n\t\t\t\t\tstr && (str += ' ');\n\t\t\t\t\tstr += k;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn str;\n}\n\nexport default function () {\n\tvar i=0, tmp, x, str='';\n\twhile (i < arguments.length) {\n\t\tif (tmp = arguments[i++]) {\n\t\t\tif (x = toVal(tmp)) {\n\t\t\t\tstr && (str += ' ');\n\t\t\t\tstr += x\n\t\t\t}\n\t\t}\n\t}\n\treturn str;\n}\n","import { isValidElement } from 'react';\n\nimport { Id } from '../types';\n\nexport function isNum(v: any): v is Number {\n return typeof v === 'number' && !isNaN(v);\n}\n\nexport function isBool(v: any): v is Boolean {\n return typeof v === 'boolean';\n}\n\nexport function isStr(v: any): v is String {\n return typeof v === 'string';\n}\n\nexport function isFn(v: any): v is Function {\n return typeof v === 'function';\n}\n\nexport function parseClassName(v: any) {\n return isStr(v) || isFn(v) ? v : null;\n}\n\nexport function isToastIdValid(toastId?: Id) {\n return toastId === 0 || toastId;\n}\n\nexport function getAutoCloseDelay(\n toastAutoClose?: false | number,\n containerAutoClose?: false | number\n) {\n return toastAutoClose === false ||\n (isNum(toastAutoClose) && toastAutoClose > 0)\n ? toastAutoClose\n : containerAutoClose;\n}\n\nexport const canUseDom = !!(\n typeof window !== 'undefined' &&\n window.document &&\n window.document.createElement\n);\n\nexport function canBeRendered(content: T): boolean {\n return (\n isValidElement(content) || isStr(content) || isFn(content) || isNum(content)\n );\n}\n","import { ToastPosition, TypeOptions } from '../types';\n\ntype KeyOfPosition =\n | 'TOP_LEFT'\n | 'TOP_RIGHT'\n | 'TOP_CENTER'\n | 'BOTTOM_LEFT'\n | 'BOTTOM_RIGHT'\n | 'BOTTOM_CENTER';\n\ntype KeyOfType = 'INFO' | 'SUCCESS' | 'WARNING' | 'ERROR' | 'DEFAULT';\n\nexport const POSITION: { [key in KeyOfPosition]: ToastPosition } = {\n TOP_LEFT: 'top-left',\n TOP_RIGHT: 'top-right',\n TOP_CENTER: 'top-center',\n BOTTOM_LEFT: 'bottom-left',\n BOTTOM_RIGHT: 'bottom-right',\n BOTTOM_CENTER: 'bottom-center'\n};\n\nexport const TYPE: { [key in KeyOfType]: TypeOptions } = {\n INFO: 'info',\n SUCCESS: 'success',\n WARNING: 'warning',\n ERROR: 'error',\n DEFAULT: 'default'\n};\n\nexport const enum Default {\n COLLAPSE_DURATION = 300,\n DEBOUNCE_DURATION = 50,\n CSS_NAMESPACE = 'Toastify',\n DRAGGABLE_PERCENT = 80\n}\n\nexport const enum Direction {\n X = 'x',\n Y = 'y'\n}\n","import React, { useEffect, useLayoutEffect, useRef } from 'react';\nimport { ToastTransitionProps } from '../types';\n\nimport { collapseToast } from './collapseToast';\nimport { Default } from './constant';\n\nexport interface CSSTransitionProps {\n /**\n * Css class to apply when toast enter\n */\n enter: string;\n\n /**\n * Css class to apply when toast leave\n */\n exit: string;\n\n /**\n * Append current toast position to the classname.\n * If multiple classes are provided, only the last one will get the position\n * For instance `myclass--top-center`...\n * `Default: false`\n */\n appendPosition?: boolean;\n\n /**\n * Collapse toast smoothly when exit animation end\n * `Default: true`\n */\n collapse?: boolean;\n\n /**\n * Collapse transition duration\n * `Default: 300`\n */\n collapseDuration?: number;\n}\n\nconst enum AnimationStep {\n Enter,\n Exit\n}\n\n/**\n * Css animation that just work.\n * You could use animate.css for instance\n *\n *\n * ```\n * cssTransition({\n * enter: \"animate__animated animate__bounceIn\",\n * exit: \"animate__animated animate__bounceOut\"\n * })\n * ```\n *\n */\nexport function cssTransition({\n enter,\n exit,\n appendPosition = false,\n collapse = true,\n collapseDuration = Default.COLLAPSE_DURATION\n}: CSSTransitionProps) {\n return function ToastTransition({\n children,\n position,\n preventExitTransition,\n done,\n nodeRef,\n isIn\n }: ToastTransitionProps) {\n const enterClassName = appendPosition ? `${enter}--${position}` : enter;\n const exitClassName = appendPosition ? `${exit}--${position}` : exit;\n const baseClassName = useRef();\n const animationStep = useRef(AnimationStep.Enter);\n\n useLayoutEffect(() => {\n onEnter();\n }, []);\n\n useEffect(() => {\n if (!isIn) preventExitTransition ? onExited() : onExit();\n }, [isIn]);\n\n function onEnter() {\n const node = nodeRef.current!;\n baseClassName.current = node.className;\n node.className += ` ${enterClassName}`;\n node.addEventListener('animationend', onEntered);\n }\n\n function onEntered(e: AnimationEvent) {\n if (e.target !== nodeRef.current) return;\n\n const node = nodeRef.current!;\n node.removeEventListener('animationend', onEntered);\n if (animationStep.current === AnimationStep.Enter) {\n node.className = baseClassName.current!;\n }\n }\n\n function onExit() {\n animationStep.current = AnimationStep.Exit;\n const node = nodeRef.current!;\n\n node.className += ` ${exitClassName}`;\n node.addEventListener('animationend', onExited);\n }\n\n function onExited() {\n const node = nodeRef.current!;\n\n node.removeEventListener('animationend', onExited);\n collapse ? collapseToast(node, done, collapseDuration) : done();\n }\n\n return <>{children};\n };\n}\n","import { Default } from './constant';\n\n/**\n * Used to collapse toast after exit animation\n */\nexport function collapseToast(\n node: HTMLElement,\n done: () => void,\n duration = Default.COLLAPSE_DURATION\n) {\n const { scrollHeight, style } = node;\n\n requestAnimationFrame(() => {\n style.minHeight = 'initial';\n style.height = scrollHeight + 'px';\n style.transition = `all ${duration}ms`;\n\n requestAnimationFrame(() => {\n style.height = '0';\n style.padding = '0';\n style.margin = '0';\n setTimeout(done, duration as number);\n });\n });\n}\n","import {\n Id,\n ToastContent,\n ClearWaitingQueueParams,\n NotValidatedToastProps\n} from '../types';\nimport { ContainerInstance } from '../hooks';\n\nexport const enum Event {\n Show,\n Clear,\n DidMount,\n WillUnmount,\n Change,\n ClearWaitingQueue\n}\n\ntype OnShowCallback = (\n content: ToastContent,\n options: NotValidatedToastProps\n) => void;\ntype OnClearCallback = (id?: Id) => void;\ntype OnClearWaitingQueue = (params: ClearWaitingQueueParams) => void;\ntype OnDidMountCallback = (containerInstance: ContainerInstance) => void;\ntype OnWillUnmountCallback = OnDidMountCallback;\nexport type OnChangeCallback = (\n toast: number,\n containerId?: number | string\n) => void;\ntype Callback =\n | OnShowCallback\n | OnClearCallback\n | OnClearWaitingQueue\n | OnDidMountCallback\n | OnWillUnmountCallback\n | OnChangeCallback;\ntype TimeoutId = ReturnType;\n\nexport interface EventManager {\n list: Map;\n emitQueue: Map;\n on(event: Event.Show, callback: OnShowCallback): EventManager;\n on(event: Event.Clear, callback: OnClearCallback): EventManager;\n on(\n event: Event.ClearWaitingQueue,\n callback: OnClearWaitingQueue\n ): EventManager;\n on(event: Event.DidMount, callback: OnDidMountCallback): EventManager;\n on(event: Event.WillUnmount, callback: OnWillUnmountCallback): EventManager;\n on(event: Event.Change, callback: OnChangeCallback): EventManager;\n off(event: Event, callback?: Callback): EventManager;\n cancelEmit(event: Event): EventManager;\n emit(\n event: Event.Show,\n content: React.ReactNode,\n options: NotValidatedToastProps\n ): void;\n emit(event: Event.Clear, id?: string | number): void;\n emit(event: Event.ClearWaitingQueue, params: ClearWaitingQueueParams): void;\n emit(event: Event.DidMount, containerInstance: ContainerInstance): void;\n emit(event: Event.WillUnmount, containerInstance: ContainerInstance): void;\n emit(event: Event.Change, toast: number, containerId?: number | string): void;\n}\n\nexport const eventManager: EventManager = {\n list: new Map(),\n emitQueue: new Map(),\n\n on(event: Event, callback: Callback) {\n this.list.has(event) || this.list.set(event, []);\n this.list.get(event)!.push(callback);\n return this;\n },\n\n off(event, callback) {\n if (callback) {\n const cb = this.list.get(event)!.filter(cb => cb !== callback);\n this.list.set(event, cb);\n return this;\n }\n this.list.delete(event);\n return this;\n },\n\n cancelEmit(event) {\n const timers = this.emitQueue.get(event);\n if (timers) {\n timers.forEach(clearTimeout);\n this.emitQueue.delete(event);\n }\n\n return this;\n },\n\n /**\n * Enqueue the event at the end of the call stack\n * Doing so let the user call toast as follow:\n * toast('1')\n * toast('2')\n * toast('3')\n * Without setTimemout the code above will not work\n */\n emit(event: Event, ...args: any[]) {\n this.list.has(event) &&\n this.list.get(event)!.forEach((callback: Callback) => {\n const timer: TimeoutId = setTimeout(() => {\n // @ts-ignore\n callback(...args);\n }, 0);\n\n this.emitQueue.has(event) || this.emitQueue.set(event, []);\n this.emitQueue.get(event)!.push(timer);\n });\n }\n};\n","import { useRef, useEffect } from 'react';\n\n/**\n * `useKeeper` is a helper around `useRef`.\n *\n * You don't need to access the `.current`property to get the value\n * If refresh is set to true. The ref will be updated every render\n */\nexport function useKeeper(arg: T, refresh = false) {\n const ref = useRef(arg);\n\n useEffect(() => {\n if (refresh) ref.current = arg;\n });\n\n return ref.current;\n}\n","import { Id } from '../types';\n\nimport { isToastIdValid } from '../utils';\n\nexport const enum ActionType {\n ADD,\n REMOVE\n}\nexport type State = Array;\nexport type Action =\n | { type: ActionType.ADD; toastId: Id; staleId?: Id }\n | { type: ActionType.REMOVE; toastId?: Id };\n\nexport function reducer(state: State, action: Action) {\n switch (action.type) {\n case ActionType.ADD:\n return [...state, action.toastId].filter(id => id !== action.staleId);\n case ActionType.REMOVE:\n return isToastIdValid(action.toastId)\n ? state.filter(id => id !== action.toastId)\n : [];\n }\n}\n","import {\n useEffect,\n useRef,\n useReducer,\n cloneElement,\n isValidElement\n} from 'react';\nimport {\n parseClassName,\n canBeRendered,\n isBool,\n isFn,\n isNum,\n isStr,\n isToastIdValid,\n getAutoCloseDelay,\n Direction,\n Default\n} from '../utils';\nimport { eventManager, Event } from '../core/eventManager';\n\nimport {\n Id,\n ToastContainerProps,\n ToastProps,\n ToastContent,\n Toast,\n ToastPosition,\n ClearWaitingQueueParams,\n NotValidatedToastProps,\n ToastTransition\n} from '../types';\nimport { useKeeper } from './useKeeper';\nimport { ActionType, reducer } from './toastContainerReducer';\n\ntype CollectionItem = Record;\ntype ToastToRender = Partial>;\n\ninterface QueuedToast {\n toastContent: ToastContent;\n toastProps: ToastProps;\n staleId?: Id;\n}\n\nexport interface ContainerInstance {\n toastKey: number;\n displayedToast: number;\n props: ToastContainerProps;\n containerId?: Id | null;\n isToastActive: (toastId: Id) => boolean;\n getToast: (id: Id) => Toast | null;\n}\n\nexport function useToastContainer(props: ToastContainerProps) {\n const [, forceUpdate] = useReducer(x => x + 1, 0);\n const [toast, dispatch] = useReducer(reducer, []);\n const containerRef = useRef(null);\n let toastCount = useKeeper(0);\n let queue = useKeeper([]);\n const collection = useKeeper({});\n const instance = useKeeper({\n toastKey: 1,\n displayedToast: 0,\n props,\n containerId: null,\n isToastActive: isToastActive,\n getToast: id => collection[id] || null\n });\n\n useEffect(() => {\n instance.containerId = props.containerId;\n eventManager\n .cancelEmit(Event.WillUnmount)\n .on(Event.Show, buildToast)\n .on(Event.Clear, toastId => containerRef.current && removeToast(toastId))\n .on(Event.ClearWaitingQueue, clearWaitingQueue)\n .emit(Event.DidMount, instance);\n\n return () => eventManager.emit(Event.WillUnmount, instance);\n }, []);\n\n useEffect(() => {\n instance.isToastActive = isToastActive;\n instance.displayedToast = toast.length;\n eventManager.emit(Event.Change, toast.length, props.containerId);\n }, [toast]);\n\n useEffect(() => {\n instance.props = props;\n });\n\n function isToastActive(id: Id) {\n return toast.indexOf(id) !== -1;\n }\n\n function clearWaitingQueue({ containerId }: ClearWaitingQueueParams) {\n const { limit } = instance.props;\n if (limit && (!containerId || instance.containerId === containerId)) {\n toastCount -= queue.length;\n queue = [];\n }\n }\n\n function removeToast(toastId?: Id) {\n dispatch({ type: ActionType.REMOVE, toastId });\n }\n\n function dequeueToast() {\n const { toastContent, toastProps, staleId } = queue.shift() as QueuedToast;\n appendToast(toastContent, toastProps, staleId);\n }\n\n /**\n * check if a container is attached to the dom\n * check for multi-container, build only if associated\n * check for duplicate toastId if no update\n */\n function isNotValid({\n containerId,\n toastId,\n updateId\n }: NotValidatedToastProps) {\n return !containerRef.current ||\n (instance.props.enableMultiContainer &&\n containerId !== instance.props.containerId) ||\n (collection[toastId] && updateId == null)\n ? true\n : false;\n }\n\n // this function and all the function called inside needs to rely on ref(`useKeeper`)\n function buildToast(\n content: ToastContent,\n { delay, staleId, ...options }: NotValidatedToastProps\n ) {\n if (!canBeRendered(content) || isNotValid(options)) return;\n\n const { toastId, updateId, data } = options;\n const { props } = instance;\n const closeToast = () => removeToast(toastId);\n const isNotAnUpdate = options.updateId == null;\n\n if (isNotAnUpdate) toastCount++;\n\n const toastProps: ToastProps = {\n toastId,\n updateId,\n isLoading: options.isLoading,\n theme: options.theme || props.theme!,\n icon: options.icon ?? props.icon,\n isIn: false,\n key: options.key || instance.toastKey++,\n type: options.type!,\n closeToast: closeToast,\n closeButton: options.closeButton,\n rtl: props.rtl,\n position: options.position || (props.position as ToastPosition),\n transition: options.transition || (props.transition as ToastTransition),\n className: parseClassName(options.className || props.toastClassName),\n bodyClassName: parseClassName(\n options.bodyClassName || props.bodyClassName\n ),\n style: options.style || props.toastStyle,\n bodyStyle: options.bodyStyle || props.bodyStyle,\n onClick: options.onClick || props.onClick,\n pauseOnHover: isBool(options.pauseOnHover)\n ? options.pauseOnHover\n : props.pauseOnHover,\n pauseOnFocusLoss: isBool(options.pauseOnFocusLoss)\n ? options.pauseOnFocusLoss\n : props.pauseOnFocusLoss,\n draggable: isBool(options.draggable)\n ? options.draggable\n : props.draggable,\n draggablePercent: isNum(options.draggablePercent)\n ? options.draggablePercent\n : (props.draggablePercent as number),\n draggableDirection:\n options.draggableDirection || props.draggableDirection,\n closeOnClick: isBool(options.closeOnClick)\n ? options.closeOnClick\n : props.closeOnClick,\n progressClassName: parseClassName(\n options.progressClassName || props.progressClassName\n ),\n progressStyle: options.progressStyle || props.progressStyle,\n autoClose: options.isLoading\n ? false\n : getAutoCloseDelay(options.autoClose, props.autoClose),\n hideProgressBar: isBool(options.hideProgressBar)\n ? options.hideProgressBar\n : props.hideProgressBar,\n progress: options.progress,\n role: isStr(options.role) ? options.role : props.role,\n deleteToast() {\n removeFromCollection(toastId);\n }\n };\n\n if (isFn(options.onOpen)) toastProps.onOpen = options.onOpen;\n if (isFn(options.onClose)) toastProps.onClose = options.onClose;\n\n // tweak for vertical dragging\n if (\n toastProps.draggableDirection === Direction.Y &&\n toastProps.draggablePercent === Default.DRAGGABLE_PERCENT\n ) {\n (toastProps.draggablePercent as number) *= 1.5;\n }\n\n let closeButton = props.closeButton;\n\n if (options.closeButton === false || canBeRendered(options.closeButton)) {\n closeButton = options.closeButton;\n } else if (options.closeButton === true) {\n closeButton = canBeRendered(props.closeButton) ? props.closeButton : true;\n }\n\n toastProps.closeButton = closeButton;\n\n let toastContent = content;\n\n if (isValidElement(content) && !isStr(content.type)) {\n toastContent = cloneElement(content, {\n closeToast,\n toastProps,\n data\n });\n } else if (isFn(content)) {\n toastContent = content({ closeToast, toastProps, data });\n }\n\n // not handling limit + delay by design. Waiting for user feedback first\n if (\n props.limit &&\n props.limit > 0 &&\n toastCount > props.limit &&\n isNotAnUpdate\n ) {\n queue.push({ toastContent, toastProps, staleId });\n } else if (isNum(delay) && (delay as number) > 0) {\n setTimeout(() => {\n appendToast(toastContent, toastProps, staleId);\n }, delay);\n } else {\n appendToast(toastContent, toastProps, staleId);\n }\n }\n\n function appendToast(\n content: ToastContent,\n toastProps: ToastProps,\n staleId?: Id\n ) {\n const { toastId } = toastProps;\n\n if (staleId) delete collection[staleId];\n\n collection[toastId] = {\n content,\n props: toastProps\n };\n dispatch({\n type: ActionType.ADD,\n toastId,\n staleId\n });\n }\n\n function removeFromCollection(toastId: Id) {\n delete collection[toastId];\n const queueLen = queue.length;\n toastCount = isToastIdValid(toastId)\n ? toastCount - 1\n : toastCount - instance.displayedToast;\n\n if (toastCount < 0) toastCount = 0;\n\n if (queueLen > 0) {\n const freeSlot = isToastIdValid(toastId) ? 1 : instance.props.limit!;\n\n if (queueLen === 1 || freeSlot === 1) {\n instance.displayedToast++;\n dequeueToast();\n } else {\n const toDequeue = freeSlot > queueLen ? queueLen : freeSlot;\n instance.displayedToast = toDequeue;\n\n for (let i = 0; i < toDequeue; i++) dequeueToast();\n }\n } else {\n forceUpdate();\n }\n }\n\n function getToastToRender(\n cb: (position: ToastPosition, toastList: Toast[]) => T\n ) {\n const toastToRender: ToastToRender = {};\n const toastList = props.newestOnTop\n ? Object.keys(collection).reverse()\n : Object.keys(collection);\n\n for (let i = 0; i < toastList.length; i++) {\n const toast = collection[toastList[i]];\n const { position } = toast.props;\n toastToRender[position] || (toastToRender[position] = []);\n\n toastToRender[position]!.push(toast);\n }\n\n return (Object.keys(toastToRender) as Array).map(p =>\n cb(p, toastToRender[p]!)\n );\n }\n\n return {\n getToastToRender,\n collection,\n containerRef,\n isToastActive\n };\n}\n","import {\n useState,\n useRef,\n useEffect,\n isValidElement,\n DOMAttributes\n} from 'react';\n\nimport { isFn } from '../utils';\nimport { ToastProps } from '../types';\nimport { useKeeper } from './useKeeper';\nimport { Direction } from '../utils/constant';\n\ninterface Draggable {\n start: number;\n x: number;\n y: number;\n delta: number;\n removalDistance: number;\n canCloseOnClick: boolean;\n canDrag: boolean;\n boundingRect: DOMRect | null;\n}\n\ntype DragEvent = MouseEvent & TouchEvent;\n\nfunction getX(e: DragEvent) {\n return e.targetTouches && e.targetTouches.length >= 1\n ? e.targetTouches[0].clientX\n : e.clientX;\n}\n\nfunction getY(e: DragEvent) {\n return e.targetTouches && e.targetTouches.length >= 1\n ? e.targetTouches[0].clientY\n : e.clientY;\n}\n\nexport function useToast(props: ToastProps) {\n const [isRunning, setIsRunning] = useState(true);\n const [preventExitTransition, setPreventExitTransition] = useState(false);\n const toastRef = useRef(null);\n const drag = useKeeper({\n start: 0,\n x: 0,\n y: 0,\n delta: 0,\n removalDistance: 0,\n canCloseOnClick: true,\n canDrag: false,\n boundingRect: null\n });\n const syncProps = useKeeper(props, true);\n const { autoClose, pauseOnHover, closeToast, onClick, closeOnClick } = props;\n\n useEffect(() => {\n if (isFn(props.onOpen))\n props.onOpen(isValidElement(props.children) && props.children.props);\n\n return () => {\n if (isFn(syncProps.onClose))\n syncProps.onClose(\n isValidElement(syncProps.children) && syncProps.children.props\n );\n };\n }, []);\n\n useEffect(() => {\n props.draggable && bindDragEvents();\n return () => {\n props.draggable && unbindDragEvents();\n };\n }, [props.draggable]);\n\n useEffect(() => {\n props.pauseOnFocusLoss && bindFocusEvents();\n return () => {\n props.pauseOnFocusLoss && unbindFocusEvents();\n };\n }, [props.pauseOnFocusLoss]);\n\n function onDragStart(\n e: React.MouseEvent | React.TouchEvent\n ) {\n if (props.draggable) {\n const toast = toastRef.current!;\n drag.canCloseOnClick = true;\n drag.canDrag = true;\n drag.boundingRect = toast.getBoundingClientRect();\n toast.style.transition = '';\n drag.x = getX(e.nativeEvent as DragEvent);\n drag.y = getY(e.nativeEvent as DragEvent);\n\n if (props.draggableDirection === Direction.X) {\n drag.start = drag.x;\n drag.removalDistance =\n toast.offsetWidth * (props.draggablePercent / 100);\n } else {\n drag.start = drag.y;\n drag.removalDistance =\n toast.offsetHeight * (props.draggablePercent / 100);\n }\n }\n }\n\n function onDragTransitionEnd() {\n if (drag.boundingRect) {\n const { top, bottom, left, right } = drag.boundingRect;\n\n if (\n props.pauseOnHover &&\n drag.x >= left &&\n drag.x <= right &&\n drag.y >= top &&\n drag.y <= bottom\n ) {\n pauseToast();\n } else {\n playToast();\n }\n }\n }\n\n function playToast() {\n setIsRunning(true);\n }\n\n function pauseToast() {\n setIsRunning(false);\n }\n\n function bindFocusEvents() {\n if (!document.hasFocus()) pauseToast();\n\n window.addEventListener('focus', playToast);\n window.addEventListener('blur', pauseToast);\n }\n\n function unbindFocusEvents() {\n window.removeEventListener('focus', playToast);\n window.removeEventListener('blur', pauseToast);\n }\n\n function bindDragEvents() {\n document.addEventListener('mousemove', onDragMove);\n document.addEventListener('mouseup', onDragEnd);\n\n document.addEventListener('touchmove', onDragMove);\n document.addEventListener('touchend', onDragEnd);\n }\n\n function unbindDragEvents() {\n document.removeEventListener('mousemove', onDragMove);\n document.removeEventListener('mouseup', onDragEnd);\n\n document.removeEventListener('touchmove', onDragMove);\n document.removeEventListener('touchend', onDragEnd);\n }\n\n function onDragMove(e: MouseEvent | TouchEvent) {\n if (drag.canDrag) {\n e.preventDefault();\n\n const toast = toastRef.current!;\n if (isRunning) pauseToast();\n\n drag.x = getX(e as DragEvent);\n drag.y = getY(e as DragEvent);\n\n if (props.draggableDirection === Direction.X) {\n drag.delta = drag.x - drag.start;\n } else {\n drag.delta = drag.y - drag.start;\n }\n\n // prevent false positif during a toast click\n if (drag.start !== drag.x) drag.canCloseOnClick = false;\n\n toast.style.transform = `translate${props.draggableDirection}(${drag.delta}px)`;\n toast.style.opacity = `${1 -\n Math.abs(drag.delta / drag.removalDistance)}`;\n }\n }\n\n function onDragEnd() {\n const toast = toastRef.current!;\n if (drag.canDrag) {\n drag.canDrag = false;\n\n if (Math.abs(drag.delta) > drag.removalDistance) {\n setPreventExitTransition(true);\n props.closeToast();\n return;\n }\n\n toast.style.transition = 'transform 0.2s, opacity 0.2s';\n toast.style.transform = `translate${props.draggableDirection}(0)`;\n toast.style.opacity = '1';\n }\n }\n\n const eventHandlers: DOMAttributes = {\n onMouseDown: onDragStart,\n onTouchStart: onDragStart,\n onMouseUp: onDragTransitionEnd,\n onTouchEnd: onDragTransitionEnd\n };\n\n if (autoClose && pauseOnHover) {\n eventHandlers.onMouseEnter = pauseToast;\n eventHandlers.onMouseLeave = playToast;\n }\n\n // prevent toast from closing when user drags the toast\n if (closeOnClick) {\n eventHandlers.onClick = (e: React.MouseEvent) => {\n onClick && onClick(e);\n drag.canCloseOnClick && closeToast();\n };\n }\n\n return {\n playToast,\n pauseToast,\n isRunning,\n preventExitTransition,\n toastRef,\n eventHandlers\n };\n}\n","import * as React from 'react';\nimport { Default } from '../utils';\nimport { Theme, TypeOptions } from '../types';\n\nexport interface CloseButtonProps {\n closeToast: (e: React.MouseEvent) => void;\n type: TypeOptions;\n ariaLabel?: string;\n theme: Theme;\n}\n\nexport function CloseButton({\n closeToast,\n theme,\n ariaLabel = 'close'\n}: CloseButtonProps) {\n return (\n {\n e.stopPropagation();\n closeToast(e);\n }}\n aria-label={ariaLabel}\n >\n \n \n \n \n );\n}\n","import * as React from 'react';\nimport cx from 'clsx';\n\nimport { TYPE, Default, isFn } from './../utils';\nimport { TypeOptions, ToastClassName, Theme } from '../types';\n\nexport interface ProgressBarProps {\n /**\n * The animation delay which determine when to close the toast\n */\n delay: number;\n\n /**\n * Whether or not the animation is running or paused\n */\n isRunning: boolean;\n\n /**\n * Func to close the current toast\n */\n closeToast: () => void;\n\n /**\n * Optional type : info, success ...\n */\n type: TypeOptions;\n\n /**\n * The theme that is currently used\n */\n theme: Theme;\n\n /**\n * Hide or not the progress bar\n */\n hide?: boolean;\n\n /**\n * Optionnal className\n */\n className?: ToastClassName;\n\n /**\n * Optionnal inline style\n */\n style?: React.CSSProperties;\n\n /**\n * Tell wether or not controlled progress bar is used\n */\n controlledProgress?: boolean;\n\n /**\n * Controlled progress value\n */\n progress?: number | string;\n\n /**\n * Support rtl content\n */\n rtl?: boolean;\n\n /**\n * Tell if the component is visible on screen or not\n */\n isIn?: boolean;\n}\n\nexport function ProgressBar({\n delay,\n isRunning,\n closeToast,\n type,\n hide,\n className,\n style: userStyle,\n controlledProgress,\n progress,\n rtl,\n isIn,\n theme\n}: ProgressBarProps) {\n const style: React.CSSProperties = {\n ...userStyle,\n animationDuration: `${delay}ms`,\n animationPlayState: isRunning ? 'running' : 'paused',\n opacity: hide ? 0 : 1\n };\n\n if (controlledProgress) style.transform = `scaleX(${progress})`;\n const defaultClassName = cx(\n `${Default.CSS_NAMESPACE}__progress-bar`,\n controlledProgress\n ? `${Default.CSS_NAMESPACE}__progress-bar--controlled`\n : `${Default.CSS_NAMESPACE}__progress-bar--animated`,\n `${Default.CSS_NAMESPACE}__progress-bar-theme--${theme}`,\n `${Default.CSS_NAMESPACE}__progress-bar--${type}`,\n {\n [`${Default.CSS_NAMESPACE}__progress-bar--rtl`]: rtl\n }\n );\n const classNames = isFn(className)\n ? className({\n rtl,\n type,\n defaultClassName\n })\n : cx(defaultClassName, className);\n\n // 🧐 controlledProgress is derived from progress\n // so if controlledProgress is set\n // it means that this is also the case for progress\n const animationEvent = {\n [controlledProgress && progress! >= 1\n ? 'onTransitionEnd'\n : 'onAnimationEnd']:\n controlledProgress && progress! < 1\n ? null\n : () => {\n isIn && closeToast();\n }\n };\n\n // TODO: add aria-valuenow, aria-valuemax, aria-valuemin\n\n return (\n \n );\n}\n\nProgressBar.defaultProps = {\n type: TYPE.DEFAULT,\n hide: false\n};\n","import React from 'react';\n\nimport { Theme, TypeOptions } from '../types';\nimport { Default } from '../utils';\n\n/**\n * Used when providing custom icon\n */\nexport interface IconProps {\n theme: Theme;\n type: TypeOptions;\n}\n\nexport type BuiltInIconProps = React.SVGProps & IconProps;\n\nconst Svg: React.FC = ({ theme, type, ...rest }) => (\n \n);\n\nfunction Warning(props: BuiltInIconProps) {\n return (\n \n \n \n );\n}\n\nfunction Info(props: BuiltInIconProps) {\n return (\n \n \n \n );\n}\n\nfunction Success(props: BuiltInIconProps) {\n return (\n \n \n \n );\n}\n\nfunction Error(props: BuiltInIconProps) {\n return (\n \n \n \n );\n}\n\nfunction Spinner() {\n return
;\n}\n\nexport const Icons = {\n info: Info,\n warning: Warning,\n success: Success,\n error: Error,\n spinner: Spinner\n};\n","import * as React from 'react';\nimport cx from 'clsx';\n\nimport { ProgressBar } from './ProgressBar';\nimport { Icons } from './Icons';\nimport { ToastProps } from '../types';\nimport { Default, isFn, isStr } from '../utils';\nimport { useToast } from '../hooks';\n\nexport const Toast: React.FC = props => {\n const {\n isRunning,\n preventExitTransition,\n toastRef,\n eventHandlers\n } = useToast(props);\n const {\n closeButton,\n children,\n autoClose,\n onClick,\n type,\n hideProgressBar,\n closeToast,\n transition: Transition,\n position,\n className,\n style,\n bodyClassName,\n bodyStyle,\n progressClassName,\n progressStyle,\n updateId,\n role,\n progress,\n rtl,\n toastId,\n deleteToast,\n isIn,\n isLoading,\n icon,\n theme\n } = props;\n const defaultClassName = cx(\n `${Default.CSS_NAMESPACE}__toast`,\n `${Default.CSS_NAMESPACE}__toast-theme--${theme}`,\n `${Default.CSS_NAMESPACE}__toast--${type}`,\n {\n [`${Default.CSS_NAMESPACE}__toast--rtl`]: rtl\n }\n );\n const cssClasses = isFn(className)\n ? className({\n rtl,\n position,\n type,\n defaultClassName\n })\n : cx(defaultClassName, className);\n const isProgressControlled = !!progress;\n const maybeIcon = Icons[type as keyof typeof Icons];\n const iconProps = { theme, type };\n let Icon: React.ReactNode = maybeIcon && maybeIcon(iconProps);\n\n if (icon === false) {\n Icon = void 0;\n } else if (isFn(icon)) {\n Icon = icon(iconProps);\n } else if (React.isValidElement(icon)) {\n Icon = React.cloneElement(icon, iconProps);\n } else if (isStr(icon)) {\n Icon = icon;\n } else if (isLoading) {\n Icon = Icons.spinner();\n }\n\n function renderCloseButton(closeButton: any) {\n if (!closeButton) return;\n\n const props = { closeToast, type, theme };\n\n if (isFn(closeButton)) return closeButton(props);\n\n if (React.isValidElement(closeButton))\n return React.cloneElement(closeButton, props);\n }\n\n return (\n \n \n \n {Icon && (\n \n {Icon}\n
\n )}\n
{children}
\n \n {renderCloseButton(closeButton)}\n {(autoClose || isProgressControlled) && (\n \n )}\n \n \n );\n};\n","import { Default, cssTransition } from '../utils';\n\nconst Bounce = cssTransition({\n enter: `${Default.CSS_NAMESPACE}--animate ${Default.CSS_NAMESPACE}__bounce-enter`,\n exit: `${Default.CSS_NAMESPACE}--animate ${Default.CSS_NAMESPACE}__bounce-exit`,\n appendPosition: true\n});\n\nconst Slide = cssTransition({\n enter: `${Default.CSS_NAMESPACE}--animate ${Default.CSS_NAMESPACE}__slide-enter`,\n exit: `${Default.CSS_NAMESPACE}--animate ${Default.CSS_NAMESPACE}__slide-exit`,\n appendPosition: true\n});\n\nconst Zoom = cssTransition({\n enter: `${Default.CSS_NAMESPACE}--animate ${Default.CSS_NAMESPACE}__zoom-enter`,\n exit: `${Default.CSS_NAMESPACE}--animate ${Default.CSS_NAMESPACE}__zoom-exit`\n});\n\nconst Flip = cssTransition({\n enter: `${Default.CSS_NAMESPACE}--animate ${Default.CSS_NAMESPACE}__flip-enter`,\n exit: `${Default.CSS_NAMESPACE}--animate ${Default.CSS_NAMESPACE}__flip-exit`\n});\n\nexport { Bounce, Slide, Zoom, Flip };\n","import * as React from 'react';\nimport cx from 'clsx';\n\nimport { Toast } from './Toast';\nimport { CloseButton } from './CloseButton';\nimport { Bounce } from './Transitions';\nimport { POSITION, Direction, Default, parseClassName, isFn } from '../utils';\nimport { useToastContainer } from '../hooks';\nimport { ToastContainerProps, ToastPosition } from '../types';\n\nexport const ToastContainer: React.FC = props => {\n const { getToastToRender, containerRef, isToastActive } = useToastContainer(\n props\n );\n const { className, style, rtl, containerId } = props;\n\n function getClassName(position: ToastPosition) {\n const defaultClassName = cx(\n `${Default.CSS_NAMESPACE}__toast-container`,\n `${Default.CSS_NAMESPACE}__toast-container--${position}`,\n { [`${Default.CSS_NAMESPACE}__toast-container--rtl`]: rtl }\n );\n return isFn(className)\n ? className({\n position,\n rtl,\n defaultClassName\n })\n : cx(defaultClassName, parseClassName(className));\n }\n\n return (\n \n {getToastToRender((position, toastList) => {\n const containerStyle: React.CSSProperties =\n toastList.length === 0\n ? { ...style, pointerEvents: 'none' }\n : { ...style };\n\n return (\n \n {toastList.map(({ content, props: toastProps }) => {\n return (\n \n {content}\n \n );\n })}\n \n );\n })}\n \n );\n};\n\nToastContainer.defaultProps = {\n position: POSITION.TOP_RIGHT as ToastPosition,\n transition: Bounce,\n rtl: false,\n autoClose: 5000,\n hideProgressBar: false,\n closeButton: CloseButton,\n pauseOnHover: true,\n pauseOnFocusLoss: true,\n closeOnClick: true,\n newestOnTop: false,\n draggable: true,\n draggablePercent: Default.DRAGGABLE_PERCENT as number,\n draggableDirection: Direction.X,\n role: 'alert',\n theme: 'light'\n};\n","import * as React from 'react';\nimport { render } from 'react-dom';\n\nimport { POSITION, TYPE, canUseDom, isStr, isNum, isFn } from '../utils';\nimport { eventManager, OnChangeCallback, Event } from './eventManager';\nimport {\n ToastContent,\n ToastOptions,\n ToastProps,\n Id,\n ToastContainerProps,\n UpdateOptions,\n ClearWaitingQueueParams,\n NotValidatedToastProps,\n TypeOptions\n} from '../types';\nimport { ContainerInstance } from '../hooks';\nimport { ToastContainer } from '../components';\n\ninterface EnqueuedToast {\n content: ToastContent;\n options: NotValidatedToastProps;\n}\n\nlet containers = new Map();\nlet latestInstance: ContainerInstance | Id;\nlet containerDomNode: HTMLElement;\nlet containerConfig: ToastContainerProps;\nlet queue: EnqueuedToast[] = [];\nlet lazy = false;\n\n/**\n * Check whether any container is currently mounted in the DOM\n */\nfunction isAnyContainerMounted() {\n return containers.size > 0;\n}\n\n/**\n * Get the toast by id, given it's in the DOM, otherwise returns null\n */\nfunction getToast(toastId: Id, { containerId }: ToastOptions) {\n const container = containers.get(containerId || latestInstance);\n if (!container) return null;\n\n return container.getToast(toastId);\n}\n\n/**\n * Generate a random toastId\n */\nfunction generateToastId() {\n return Math.random()\n .toString(36)\n .substr(2, 9);\n}\n\n/**\n * Generate a toastId or use the one provided\n */\nfunction getToastId(options?: ToastOptions) {\n if (options && (isStr(options.toastId) || isNum(options.toastId))) {\n return options.toastId;\n }\n\n return generateToastId();\n}\n\n/**\n * If the container is not mounted, the toast is enqueued and\n * the container lazy mounted\n */\nfunction dispatchToast(\n content: ToastContent,\n options: NotValidatedToastProps\n): Id {\n if (isAnyContainerMounted()) {\n eventManager.emit(Event.Show, content, options);\n } else {\n queue.push({ content, options });\n if (lazy && canUseDom) {\n lazy = false;\n containerDomNode = document.createElement('div');\n document.body.appendChild(containerDomNode);\n render(, containerDomNode);\n }\n }\n\n return options.toastId;\n}\n\n/**\n * Merge provided options with the defaults settings and generate the toastId\n */\nfunction mergeOptions(type: string, options?: ToastOptions) {\n return {\n ...options,\n type: (options && options.type) || type,\n toastId: getToastId(options)\n } as NotValidatedToastProps;\n}\n\nconst createToastByType = (type: string) => (\n content: ToastContent,\n options?: ToastOptions\n) => dispatchToast(content, mergeOptions(type, options));\n\nconst toast = (content: ToastContent, options?: ToastOptions) =>\n dispatchToast(content, mergeOptions(TYPE.DEFAULT, options));\n\ntoast.loading = (content: ToastContent, options?: ToastOptions) =>\n dispatchToast(\n content,\n mergeOptions(TYPE.DEFAULT, {\n isLoading: true,\n autoClose: false,\n closeOnClick: false,\n closeButton: false,\n draggable: false,\n ...options\n })\n );\n\ninterface ToastPromiseParams {\n pending: string | UpdateOptions;\n success: string | UpdateOptions;\n error: string | UpdateOptions;\n}\n\nfunction handlePromise(\n promise: Promise | (() => Promise),\n { pending, error, success }: ToastPromiseParams,\n options?: ToastOptions\n) {\n const id = isStr(pending)\n ? toast.loading(pending, options)\n : toast.loading(pending.render, {\n ...options,\n ...(pending as ToastOptions)\n });\n const resetParams = {\n isLoading: null,\n autoClose: null,\n closeOnClick: null,\n closeButton: null,\n draggable: null\n };\n\n const resolver = (\n type: TypeOptions,\n input: string | UpdateOptions,\n result: T\n ) => {\n const params = isStr(input) ? { render: input } : input;\n toast.update(id, {\n type,\n ...resetParams,\n ...options,\n ...params,\n data: result\n });\n return result;\n };\n const p = isFn(promise) ? promise() : promise;\n p.then(result => resolver('success', success, result)).catch(err =>\n resolver('error', error, err)\n );\n\n return p;\n}\n\ntoast.promise = handlePromise;\ntoast.success = createToastByType(TYPE.SUCCESS);\ntoast.info = createToastByType(TYPE.INFO);\ntoast.error = createToastByType(TYPE.ERROR);\ntoast.warning = createToastByType(TYPE.WARNING);\ntoast.warn = toast.warning;\ntoast.dark = (content: ToastContent, options?: ToastOptions) =>\n dispatchToast(\n content,\n mergeOptions(TYPE.DEFAULT, {\n theme: 'dark',\n ...options\n })\n );\n\n/**\n * Remove toast programmaticaly\n */\ntoast.dismiss = (id?: Id) => eventManager.emit(Event.Clear, id);\n\n/**\n * Clear waiting queue when limit is used\n */\ntoast.clearWaitingQueue = (params: ClearWaitingQueueParams = {}) =>\n eventManager.emit(Event.ClearWaitingQueue, params);\n\n/**\n * return true if one container is displaying the toast\n */\ntoast.isActive = (id: Id) => {\n let isToastActive = false;\n\n containers.forEach(container => {\n if (container.isToastActive && container.isToastActive(id)) {\n isToastActive = true;\n }\n });\n\n return isToastActive;\n};\n\ntoast.update = (toastId: Id, options: UpdateOptions = {}) => {\n // if you call toast and toast.update directly nothing will be displayed\n // this is why I defered the update\n setTimeout(() => {\n const toast = getToast(toastId, options as ToastOptions);\n if (toast) {\n const { props: oldOptions, content: oldContent } = toast;\n\n const nextOptions = {\n ...oldOptions,\n ...options,\n toastId: options.toastId || toastId,\n updateId: generateToastId()\n } as ToastProps & UpdateOptions;\n\n if (nextOptions.toastId !== toastId) nextOptions.staleId = toastId;\n\n const content = nextOptions.render || oldContent;\n delete nextOptions.render;\n\n dispatchToast(content, nextOptions);\n }\n }, 0);\n};\n\n/**\n * Used for controlled progress bar.\n */\ntoast.done = (id: Id) => {\n toast.update(id, {\n progress: 1\n });\n};\n\n/**\n * Track changes. The callback get the number of toast displayed\n *\n */\ntoast.onChange = (callback: OnChangeCallback) => {\n if (isFn(callback)) {\n eventManager.on(Event.Change, callback);\n }\n return () => {\n isFn(callback) && eventManager.off(Event.Change, callback);\n };\n};\n\n/**\n * Configure the ToastContainer when lazy mounted\n */\ntoast.configure = (config: ToastContainerProps = {}) => {\n lazy = true;\n containerConfig = config;\n};\n\ntoast.POSITION = POSITION;\ntoast.TYPE = TYPE;\n\n/**\n * Wait until the ToastContainer is mounted to dispatch the toast\n * and attach isActive method\n */\neventManager\n .on(Event.DidMount, (containerInstance: ContainerInstance) => {\n latestInstance = containerInstance.containerId || containerInstance;\n containers.set(latestInstance, containerInstance);\n\n queue.forEach(item => {\n eventManager.emit(Event.Show, item.content, item.options);\n });\n\n queue = [];\n })\n .on(Event.WillUnmount, (containerInstance: ContainerInstance) => {\n containers.delete(containerInstance.containerId || containerInstance);\n\n if (containers.size === 0) {\n eventManager\n .off(Event.Show)\n .off(Event.Clear)\n .off(Event.ClearWaitingQueue);\n }\n\n if (canUseDom && containerDomNode) {\n document.body.removeChild(containerDomNode);\n }\n });\n\nexport { toast };\n","export default function _defineProperty(obj, key, value) {\n if (key in obj) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n } else {\n obj[key] = value;\n }\n\n return obj;\n}","import { useCallback } from 'react';\nimport * as R from 'ramda';\n\nimport { uuid } from '@eventespresso/utils';\n\nimport { DataStateReducer, StateInitializer, DataState, DefaultTicket } from './types';\n\nexport const initialState: DataState = {\n\tdeletedTickets: [],\n\ttickets: {},\n\tisDirty: false,\n};\n\nconst useDataStateReducer = (initializer: StateInitializer): DataStateReducer => {\n\treturn useCallback(\n\t\t(state, action) => {\n\t\t\tconst { id, ticket, type } = action;\n\t\t\tlet ticketId: string, newState: DataState, existingTicket: DefaultTicket;\n\n\t\t\tswitch (type) {\n\t\t\t\tcase 'ADD_TICKET':\n\t\t\t\tcase 'UPDATE_TICKET':\n\t\t\t\t\t// use id to update and uuid to add new\n\t\t\t\t\tticketId = id || uuid();\n\t\t\t\t\texistingTicket = R.path(['tickets', ticketId], state);\n\t\t\t\t\t// we need to make the id inside ticket and in tickets object same\n\t\t\t\t\tnewState = R.assocPath(\n\t\t\t\t\t\t['tickets', ticketId],\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t...existingTicket,\n\t\t\t\t\t\t\t...ticket,\n\t\t\t\t\t\t\tid: ticketId,\n\t\t\t\t\t\t\tisModified: Boolean(id),\n\t\t\t\t\t\t\tisDefault: true,\n\t\t\t\t\t\t},\n\t\t\t\t\t\tstate\n\t\t\t\t\t);\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase 'DELETE_TICKET':\n\t\t\t\t\tnewState = {\n\t\t\t\t\t\t...state,\n\t\t\t\t\t\ttickets: R.omit([id], state.tickets),\n\t\t\t\t\t};\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase 'ADD_TICKET_TO_DELETED':\n\t\t\t\t\tif (state.deletedTickets.includes(id)) {\n\t\t\t\t\t\tnewState = state;\n\t\t\t\t\t} else {\n\t\t\t\t\t\tnewState = {\n\t\t\t\t\t\t\t...state,\n\t\t\t\t\t\t\tdeletedTickets: [...state.deletedTickets, id],\n\t\t\t\t\t\t};\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase 'RESET':\n\t\t\t\t\treturn initializer(initialState);\n\t\t\t\tdefault:\n\t\t\t\t\tthrow new Error('Unexpected action');\n\t\t\t}\n\n\t\t\treturn { ...newState, isDirty: true };\n\t\t},\n\t\t[initializer]\n\t);\n};\n\nexport default useDataStateReducer;\n","import { useCallback, useMemo, useReducer } from 'react';\n\nimport type { DataStateManager, DataStateManagerHook } from './types';\nimport useDataReducer, { initialState } from './useDataStateReducer';\nimport useInitialState from './useInitialState';\n\ntype DSM = DataStateManager;\n\nconst useDataStateManager: DataStateManagerHook = () => {\n\tconst initializer = useInitialState();\n\tconst dataReducer = useDataReducer(initializer);\n\tconst [state, dispatch] = useReducer(dataReducer, initialState, initializer);\n\n\tconst getData: DSM['getData'] = useCallback(() => state, [state]);\n\n\tconst addTicket: DSM['addTicket'] = useCallback((ticket) => {\n\t\tdispatch({\n\t\t\ttype: 'ADD_TICKET',\n\t\t\tticket,\n\t\t});\n\t}, []);\n\n\tconst updateTicket: DSM['updateTicket'] = useCallback((id, ticket) => {\n\t\tdispatch({\n\t\t\ttype: 'UPDATE_TICKET',\n\t\t\tid,\n\t\t\tticket,\n\t\t});\n\t}, []);\n\n\tconst deleteTicket: DSM['deleteTicket'] = useCallback((id, isNew) => {\n\t\tif (!isNew) {\n\t\t\tdispatch({\n\t\t\t\ttype: 'ADD_TICKET_TO_DELETED',\n\t\t\t\tid,\n\t\t\t});\n\t\t}\n\t\tdispatch({\n\t\t\ttype: 'DELETE_TICKET',\n\t\t\tid,\n\t\t});\n\t}, []);\n\n\tconst reset: DSM['reset'] = useCallback(() => {\n\t\tdispatch({ type: 'RESET' });\n\t}, []);\n\n\treturn useMemo(\n\t\t() => ({\n\t\t\t...state,\n\t\t\taddTicket,\n\t\t\tdeleteTicket,\n\t\t\tgetData,\n\t\t\tupdateTicket,\n\t\t\treset,\n\t\t}),\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\t\t[state]\n\t);\n};\n\nexport default useDataStateManager;\n","import { FilterStateReducer } from './types';\n\nconst reducer: FilterStateReducer = (state, action) => {\n\tconst { type, datesByMonth, showTrashedDates, showExpiredTickets, showTrashedTickets } = action;\n\n\tswitch (type) {\n\t\tcase 'SET_DATES_BY_MONTH':\n\t\t\treturn { ...state, datesByMonth };\n\n\t\tcase 'SET_SHOW_TRASHED_DATES':\n\t\t\treturn { ...state, showTrashedDates };\n\n\t\tcase 'SET_SHOW_EXPIRED_TICKETS':\n\t\t\treturn { ...state, showExpiredTickets };\n\n\t\tcase 'SET_SHOW_TRASHED_TICKETS':\n\t\t\treturn { ...state, showTrashedTickets };\n\n\t\tdefault:\n\t\t\tthrow new Error('Unexpected action');\n\t}\n};\n\nexport default reducer;\n","import { useCallback, useMemo, useReducer } from 'react';\n\nimport { FilterState, FilterStateManager, FilterStateManagerHook } from './types';\nimport reducer from './reducer';\n\ntype FSM = FilterStateManager;\n\nconst initialState: FilterState = {\n\tdatesByMonth: [0, 0],\n\tshowExpiredTickets: false,\n\tshowTrashedDates: false,\n\tshowTrashedTickets: false,\n};\n\nconst useFilterStateManager: FilterStateManagerHook = () => {\n\tconst [state, dispatch] = useReducer(reducer, initialState);\n\n\tconst setDatesByMonth: FSM['setDatesByMonth'] = useCallback((datesByMonth) => {\n\t\tconst [year, month] = datesByMonth.split(':').map(Number);\n\n\t\tdispatch({\n\t\t\ttype: 'SET_DATES_BY_MONTH',\n\t\t\tdatesByMonth: [year, month],\n\t\t});\n\t}, []);\n\n\tconst setShowExpiredTickets: FSM['setShowExpiredTickets'] = useCallback((showExpiredTickets) => {\n\t\tdispatch({\n\t\t\ttype: 'SET_SHOW_EXPIRED_TICKETS',\n\t\t\tshowExpiredTickets,\n\t\t});\n\t}, []);\n\n\tconst setShowTrashedDates: FSM['setShowTrashedDates'] = useCallback((showTrashedDates) => {\n\t\tdispatch({\n\t\t\ttype: 'SET_SHOW_TRASHED_DATES',\n\t\t\tshowTrashedDates,\n\t\t});\n\t}, []);\n\n\tconst setShowTrashedTickets: FSM['setShowTrashedTickets'] = useCallback((showTrashedTickets) => {\n\t\tdispatch({\n\t\t\ttype: 'SET_SHOW_TRASHED_TICKETS',\n\t\t\tshowTrashedTickets,\n\t\t});\n\t}, []);\n\n\treturn useMemo(\n\t\t() => ({\n\t\t\t...state,\n\t\t\tsetDatesByMonth,\n\t\t\tsetShowExpiredTickets,\n\t\t\tsetShowTrashedDates,\n\t\t\tsetShowTrashedTickets,\n\t\t}),\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\t\t[state]\n\t);\n};\n\nexport default useFilterStateManager;\n","(function() { module.exports = window[\"eventespresso\"][\"formBuilder\"]; }());","var baseIsNative = require('./_baseIsNative'),\n getValue = require('./_getValue');\n\n/**\n * Gets the native function at `key` of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {string} key The key of the method to get.\n * @returns {*} Returns the function if it's native, else `undefined`.\n */\nfunction getNative(object, key) {\n var value = getValue(object, key);\n return baseIsNative(value) ? value : undefined;\n}\n\nmodule.exports = getNative;\n","export default function requiredArgs(required, args) {\n if (args.length < required) {\n throw new TypeError(required + ' argument' + (required > 1 ? 's' : '') + ' required, but only ' + args.length + ' present');\n }\n}","var baseHas = require('./_baseHas'),\n hasPath = require('./_hasPath');\n\n/**\n * Checks if `path` is a direct property of `object`.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Object\n * @param {Object} object The object to query.\n * @param {Array|string} path The path to check.\n * @returns {boolean} Returns `true` if `path` exists, else `false`.\n * @example\n *\n * var object = { 'a': { 'b': 2 } };\n * var other = _.create({ 'a': _.create({ 'b': 2 }) });\n *\n * _.has(object, 'a');\n * // => true\n *\n * _.has(object, 'a.b');\n * // => true\n *\n * _.has(object, ['a', 'b']);\n * // => true\n *\n * _.has(other, 'a');\n * // => false\n */\nfunction has(object, path) {\n return object != null && hasPath(object, path, baseHas);\n}\n\nmodule.exports = has;\n","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst CloseOutlined = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(CloseOutlined, 'close-outlined');\n","var g;\n\n// This works in non-strict mode\ng = (function() {\n\treturn this;\n})();\n\ntry {\n\t// This works if eval is allowed (see CSP)\n\tg = g || new Function(\"return this\")();\n} catch (e) {\n\t// This works if the window reference is available\n\tif (typeof window === \"object\") g = window;\n}\n\n// g can still be undefined, but nothing to do about it...\n// We return undefined, instead of nothing here, so it's\n// easier to handle this case. if(!global) { ...}\n\nmodule.exports = g;\n","(function() { module.exports = window[\"eventespresso\"][\"edtrServices\"]; }());","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst Link = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(Link, 'link');\n","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst Unlink = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(Unlink, 'unlink');\n","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst Calculator = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(Calculator, 'calculator');\n","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst MapMarker = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(MapMarker, 'map-marker');\n","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst Calendar = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(Calendar, 'calendar');\n","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst CalendarOutlined = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(CalendarOutlined, 'calendar-outlined');\n","export * from './ContextProvider';\nexport * from './DataStateProvider';\nexport * from './FilterStateProvider';\n\nexport { default as withContext } from './withContext';\n\nexport { default as useTAMContext } from './useTAMContext';\n\nexport * from './types';\n","/* eslint-disable \nno-unused-vars,\nno-native-reassign,\nno-global-assign,\n@typescript-eslint/no-unused-vars,\nno-var\n*/\n/* global __webpack_public_path__ */\ndeclare var __webpack_public_path__: string;\nlet assetsUrl = window.baristaAssetsUrl || window?.eventEspressoData?.config?.coreDomain?.distributionAssetsUrl;\n\n__webpack_public_path__ = assetsUrl;\n\n// not needed\nexport default assetsUrl = __webpack_public_path__;\n\ndeclare global {\n\tinterface Window {\n\t\tbaristaAssetsUrl: string;\n\t}\n}\n","import type { SVGProps } from 'react';\n\nexport interface IconProps extends SVGProps {\n\tclassName?: string;\n\tcolor?: string;\n\tname?: IconName | keyof SvgPath;\n\tnoMargin?: boolean;\n\tsize?: IconSize;\n\tsvgSize?: number;\n\tviewBox?: string;\n}\n\nexport enum IconName {\n\tCALENDAR = 'calendar',\n\tCALCULATOR = 'calculator',\n\tEDIT = 'edit',\n\tFILTER = 'filter',\n\tGROUPS = 'groups',\n\tTICKET = 'ticket-alt',\n}\n\nexport type IconSize = 'big' | 'bigger' | 'small' | 'smaller' | 'tiny';\n\nexport type SvgPath = {\n\t[key in IconName]: string;\n};\n\nexport type IconComponent = React.ComponentType;\n","import { ModalSubscription, ModalRegistry } from '@eventespresso/registry';\nimport { domain } from '@eventespresso/edtr-services';\n\nconst { getSubscriptions } = new ModalSubscription(domain);\nconst registry = new ModalRegistry({ domain });\n\nexport const getRegisteredContainers = (): Array => {\n\tconst { generateElements } = registry;\n\n\tconst subscriptions = getSubscriptions();\n\n\tObject.values(subscriptions).forEach(({ callback }) => {\n\t\tcallback({ registry });\n\t});\n\n\treturn generateElements();\n};\n","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst Ticket = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(Ticket, 'ticket');\n","import { useMemo } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { EMPTY_OBJECT } from '@eventespresso/constants';\nimport { Button, NewEntityOption } from '@eventespresso/ui-components';\nimport { EdtrGlobalModals, hooks } from '@eventespresso/edtr-services';\nimport { useGlobalModal } from '@eventespresso/registry';\nimport { Calendar } from '@eventespresso/icons';\n\nimport { EntityEditModalData } from '@edtrUI/types';\n\ntype AddSingleDateProps = {\n\tisOnlyButton?: boolean;\n};\n\nconst AddSingleDate: React.FC = ({ isOnlyButton }) => {\n\tconst { open } = useGlobalModal(EdtrGlobalModals.EDIT_DATE);\n\n\tconst output = useMemo(() => {\n\t\tconst additionalProps = hooks.applyFilters('eventEditor.addSingleDate.buttonProps', EMPTY_OBJECT, isOnlyButton);\n\n\t\treturn hooks.applyFilters(\n\t\t\t// replacement filter for the button.\n\t\t\t'eventEditor.addSingleDate.button',\n\t\t\t,\n\t\t\tisOnlyButton\n\t\t);\n\t}, [isOnlyButton, open]);\n\n\tif (isOnlyButton) {\n\t\treturn output;\n\t}\n\n\treturn (\n\t\t\n\t\t\t{output}\n\t\t\n\t);\n};\n\nexport default AddSingleDate;\n","import { useCallback } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { Button } from '@eventespresso/ui-components';\nimport { useGlobalModal } from '@eventespresso/registry';\nimport { Calendar } from '@eventespresso/icons';\nimport { EdtrGlobalModals } from '@eventespresso/edtr-services';\n\nconst OptionsModalButton: React.FC = ({ children }) => {\n\tconst { openWithData } = useGlobalModal(EdtrGlobalModals.NEW_DATE);\n\n\tconst onClick = useCallback(() => {\n\t\topenWithData({ children });\n\t}, [children, openWithData]);\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default OptionsModalButton;\n","import OptionsModalButton from './OptionsModalButton';\nimport { NewDateOptions } from '@eventespresso/edtr-services';\n\nconst NewDateButton: React.FC = () => {\n\treturn (\n\t\t\n\t\t\t{(fills) => {\n\t\t\t\tif (fills.length > 1) {\n\t\t\t\t\treturn {fills};\n\t\t\t\t}\n\t\t\t\treturn <>{fills};\n\t\t\t}}\n\t\t\n\t);\n};\n\nexport default NewDateButton;\n","import { __ } from '@eventespresso/i18n';\n\nimport { NewEntityModal } from '@eventespresso/ui-components';\nimport { useGlobalModal } from '@eventespresso/registry';\nimport { EdtrGlobalModals } from '@eventespresso/edtr-services';\n\nconst NewDateModal: React.FC = () => {\n\tconst { isOpen, close, getData } = useGlobalModal(EdtrGlobalModals.NEW_DATE);\n\n\treturn (\n\t\tisOpen && (\n\t\t\t\n\t\t\t\t{getData().children}\n\t\t\t\n\t\t)\n\t);\n};\n\nexport default NewDateModal;\n","import { useCallback } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\n\nimport { Ticket } from '@eventespresso/icons';\nimport { Button, ButtonRow } from '@eventespresso/ui-components';\nimport { USE_ADVANCED_EDITOR } from '@eventespresso/constants';\nimport { EdtrGlobalModals, useDatetimes, useTickets } from '@eventespresso/edtr-services';\nimport { useGlobalModal } from '@eventespresso/registry';\nimport { withCurrentUserCan } from '@eventespresso/services';\n\nimport { BaseProps } from '../../ticketAssignmentsManager';\nimport { NewDateButton } from './newDateOptions';\n\nconst DatesListButtons: React.FC = () => {\n\tconst { openWithData } = useGlobalModal(EdtrGlobalModals.TAM);\n\n\tconst datetimes = useDatetimes();\n\tconst tickets = useTickets();\n\tconst isDisabled = !datetimes.length || !tickets.length;\n\n\tconst tooltip = isDisabled && __('Add a date or a ticket in order to use Ticket Assignment Manager');\n\n\tconst onOpen = useCallback(() => {\n\t\topenWithData({ assignmentType: 'forAll' });\n\t}, [openWithData]);\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withCurrentUserCan(USE_ADVANCED_EDITOR)(DatesListButtons);\n","import { useDatetimes } from '@eventespresso/edtr-services';\nimport { EntityCacheIds } from '@eventespresso/ee-components';\n\nimport DatesListButtons from './DatesListButtons';\n\nconst DatesListFooter: React.FC = () => {\n\tconst entities = useDatetimes();\n\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default DatesListFooter;\n","import { IconName, Trash } from '@eventespresso/icons';\nimport { LegendConfig } from '@eventespresso/ui-components';\nimport { __ } from '@eventespresso/i18n';\n\nexport const legendConfig: LegendConfig = {\n\ticons: [\n\t\t{ icon: IconName.EDIT, description: __('Edit Event Date Details') },\n\t\t{ icon: IconName.GROUPS, description: __('View Registrations for this Date') },\n\t\t{ icon: IconName.TICKET, description: __('Manage Ticket Assignments') },\n\t\t{ icon: Trash, description: __('Move Date to Trash') },\n\t],\n\tswatches: {\n\t\tDTA: __('Active'),\n\t\tDTT: __('Trashed'),\n\t\tDTE: __('Expired'),\n\t\tDTS: __('Sold Out'),\n\t\tDTU: __('Upcoming'),\n\t},\n};\n","import { lazy, Suspense } from 'react';\n\nimport { LoadingNotice } from '@eventespresso/ui-components';\n\nconst CardView = lazy(() => import(/* webpackChunkName: \"dates-card-view\" */ './CardView'));\n\nconst RenderCardView: React.FC = () => {\n\treturn (\n\t\t}>\n\t\t\t\n\t\t\n\t);\n};\n\nexport default RenderCardView;\n","import { lazy, Suspense } from 'react';\n\nimport { LoadingNotice } from '@eventespresso/ui-components';\n\nconst TableView = lazy(() => import(/* webpackChunkName: \"dates-table-view\" */ './TableView'));\n\nconst RenderTableView: React.FC = () => {\n\treturn (\n\t\t}>\n\t\t\t\n\t\t\n\t);\n};\n\nexport default RenderTableView;\n","/* eslint-disable @wordpress/i18n-translator-comments */\nimport { __ } from '@eventespresso/i18n';\n\nimport { DisplayStartOrEndDate } from '@eventespresso/edtr-services';\n\nimport { DatetimeSales, DatetimeStatus } from '@eventespresso/predicates';\n\nexport const displayStartOrEndDateOptions = {\n\t[DisplayStartOrEndDate.start]: __('start dates only'),\n\t[DisplayStartOrEndDate.end]: __('end dates only'),\n\t[DisplayStartOrEndDate.both]: __('start and end dates'),\n};\n\nexport const salesOptions = {\n\t[DatetimeSales.all]: __('all dates'),\n\t[DatetimeSales.above90Capacity]: __('dates above 90% capacity'),\n\t[DatetimeSales.above75Capacity]: __('dates above 75% capacity'),\n\t[DatetimeSales.above50Capacity]: __('dates above 50% capacity'),\n\t[DatetimeSales.below50Capacity]: __('dates below 50% capacity'),\n};\n\nexport const statusOptions = {\n\t[DatetimeStatus.all]: __('all dates'),\n\t[DatetimeStatus.activeUpcoming]: __('all active and upcoming'),\n\t[DatetimeStatus.activeOnly]: __('active dates only'),\n\t[DatetimeStatus.upcomingOnly]: __('upcoming dates only'),\n\t[DatetimeStatus.nextActiveUpcomingOnly]: __('next active or upcoming only'),\n\t[DatetimeStatus.soldOutOnly]: __('sold out dates only'),\n\t[DatetimeStatus.recentlyExpiredOnly]: __('recently expired dates'),\n\t[DatetimeStatus.expiredOnly]: __('all expired dates'),\n\t[DatetimeStatus.trashedOnly]: __('trashed dates only'),\n};\n\nexport const sortByOptions = {\n\tdate: __('start date'),\n\tname: __('name'),\n\tid: __('ID'),\n\torder: __('custom order'),\n};\n\nexport const labels = {\n\tdisplayStartOrEndDate: __('display'),\n\trecurrence: __('recurrence'),\n\tsales: __('sales'),\n\tsortBy: __('sort by'),\n\tsearch: __('search'),\n\tstatus: __('status'),\n};\n","import { useCallback } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { ActiveFilters, FilterTag } from '@eventespresso/ui-components';\nimport { useDatesListFilterState } from '@eventespresso/edtr-services';\nimport { DatetimeSales, DatetimeStatus } from '@eventespresso/predicates';\n\nimport { labels, statusOptions, salesOptions } from './controls/options';\n\nconst ActiveDatesFilters: React.FC = () => {\n\tconst { status, setStatus, sales, setSales, searchText, setSearchText, recurrence, setRecurrence } =\n\t\tuseDatesListFilterState();\n\n\tconst statusTitle = `${labels.status}: ${statusOptions?.[status]}`;\n\tconst salesTitle = `${labels.sales}: ${salesOptions?.[sales]}`;\n\tconst searchTitle = `${labels.search}: ${searchText}`;\n\tconst recurrenceTitle = `${labels.recurrence}: ${__('ON')}`;\n\n\tconst onRemoveStatus = useCallback(() => setStatus(DatetimeStatus.all), [setStatus]);\n\tconst onRemoveSales = useCallback(() => setSales(DatetimeSales.all), [setSales]);\n\tconst onRemoveRecurrence = useCallback(() => setRecurrence(''), [setRecurrence]);\n\tconst onRemoveSearch = useCallback(() => setSearchText(''), [setSearchText]);\n\n\treturn (\n\t\t\n\t\t\t{status !== DatetimeStatus.all && }\n\t\t\t{sales !== DatetimeSales.all && }\n\t\t\t{recurrence && }\n\t\t\t{searchText ? : null}\n\t\t\n\t);\n};\n\nexport default ActiveDatesFilters;\n","import { SelectWithLabel } from '@eventespresso/ui-components';\nimport { useDatesListFilterState } from '@eventespresso/edtr-services';\nimport { objectToSelectOptions } from '@eventespresso/utils';\n\nimport { labels, displayStartOrEndDateOptions } from './options';\n\nconst options = objectToSelectOptions(displayStartOrEndDateOptions);\n/**\n * filter for controlling which dates display in a list of Event Dates\n */\nconst DisplayStartOrEndDateControl: React.FC = () => {\n\tconst { displayStartOrEndDate, setDisplayStartOrEndDate } = useDatesListFilterState();\n\n\treturn (\n\t\t\n\t);\n};\nexport default DisplayStartOrEndDateControl;\n","import { SelectWithLabel } from '@eventespresso/ui-components';\nimport { useDatesListFilterState } from '@eventespresso/edtr-services';\nimport { objectToSelectOptions } from '@eventespresso/utils';\n\nimport { labels, salesOptions } from './options';\n\nconst options = objectToSelectOptions(salesOptions);\n\nconst SalesControl: React.FC = () => {\n\tconst { sales, setSales } = useDatesListFilterState();\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default SalesControl;\n","import { SelectWithLabel } from '@eventespresso/ui-components';\nimport { useDatesListFilterState } from '@eventespresso/edtr-services';\nimport { objectToSelectOptions } from '@eventespresso/utils';\n\nimport { labels, statusOptions } from './options';\nconst options = objectToSelectOptions(statusOptions);\n\nconst StatusControl: React.FC = () => {\n\tconst { status, setStatus } = useDatesListFilterState();\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default StatusControl;\n","import { RangeFormat } from '@eventespresso/ee-components';\nimport type { Datetime } from '@eventespresso/edtr-services';\n\nconst formatTokens = { month: 'LLL' };\n\nconst DraggableDatetime: React.FC = ({ dbId, endDate, name, startDate }) => (\n\t<>\n\t\t{dbId})\n\t\t{name}: \n\t\t\n\t\n);\n\nexport default DraggableDatetime;\n","import { SortByControl as SortByControlUI } from '@eventespresso/ee-components';\nimport type { SortByControlProps } from '@eventespresso/ee-components';\nimport {\n\tuseDatesListFilterState,\n\tuseFilteredDateIds,\n\tuseReorderDatetimes,\n\tDatetime,\n} from '@eventespresso/edtr-services';\nimport { objectToSelectOptions } from '@eventespresso/utils';\nimport { datetimesDroppableId } from '@eventespresso/constants';\nimport { TypeName } from '@eventespresso/services';\n\nimport { labels, sortByOptions } from '../options';\nimport DraggableDatetime from './DraggableDatetime';\n\nconst options = objectToSelectOptions(sortByOptions);\n\nconst renderDraggableItem: SortByControlProps['renderDraggableItem'] = (datetime) => ({\n\t...datetime,\n\tcontent: ,\n});\n\nconst SortByControl: React.FC = () => {\n\tconst { sortBy, setSortBy } = useDatesListFilterState();\n\tconst filteredDateIds = useFilteredDateIds();\n\tconst {\n\t\tallReorderedEntities: draggableItems,\n\t\tsortResponder,\n\t\tupdateEntityList,\n\t} = useReorderDatetimes(filteredDateIds);\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default SortByControl;\n","import { useCallback } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { TypeName } from '@eventespresso/services';\nimport {\n\tdomain,\n\tdatesList,\n\tDatetimesListProvider,\n\twithEntityListContext,\n\tuseDatesListFilterState,\n} from '@eventespresso/edtr-services';\nimport { EntityList } from '@eventespresso/ee-components';\n\nimport DatesListFooter from './DatesListFooter';\nimport { legendConfig } from './config';\nimport { RenderCardView } from './cardView';\nimport { RenderTableView } from './tableView';\nimport { ActiveDatesFilters } from './filterBar';\n\nconst DatesList: React.FC = () => {\n\tconst filterState = useDatesListFilterState();\n\n\tconst renderList = useCallback(\n\t\t() => (filterState.view === 'card' ? : ),\n\t\t[filterState.view]\n\t);\n\n\treturn (\n\t\t}\n\t\t\tdomain={domain}\n\t\t\tentityType={TypeName.datetimes}\n\t\t\tfilterState={filterState}\n\t\t\tfooter={}\n\t\t\theaderText={__('Event Dates')}\n\t\t\tlegendConfig={legendConfig}\n\t\t\tlistId={datesList}\n\t\t\tloadingText={__('loading event dates…')}\n\t\t\trenderList={renderList}\n\t\t/>\n\t);\n};\n\nexport default withEntityListContext({\n\tProvider: DatetimesListProvider,\n\tComponent: DatesList,\n});\n","import { useMemo } from 'react';\nimport classNames from 'classnames';\n\nimport { __ } from '@eventespresso/i18n';\nimport { SelectWithLabel } from '@eventespresso/ui-components';\nimport { datetimeStatus } from '@eventespresso/constants';\nimport { objectToSelectOptions } from '@eventespresso/utils';\nimport { datetimeStatusBgColorClassName } from '@eventespresso/helpers';\nimport type { EventRegistrationOptionsProps } from './types';\n\ninterface Props extends Pick {}\n\nconst ActiveStatus: React.FC = ({ status, onStatusChange }) => {\n\tconst className = classNames(\n\t\t'ee-edtr-option',\n\t\t'ee-edtr-option__active-status',\n\t\tdatetimeStatusBgColorClassName(null)\n\t);\n\n\tconst options = useMemo(() => objectToSelectOptions(datetimeStatus), []);\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default ActiveStatus;\n","import { __ } from '@eventespresso/i18n';\nimport { InlineEditTextWithLabel } from '@eventespresso/ui-components';\nimport type { EventRegistrationOptionsProps } from './types';\n\ninterface Props extends Pick {}\n\nconst AltRegPage: React.FC = ({ altRegPage, onAltRegPageChange }) => {\n\treturn (\n\t\t\n\t);\n};\n\nexport default AltRegPage;\n","import { useMemo } from 'react';\nimport { __ } from '@eventespresso/i18n';\nimport classNames from 'classnames';\nimport { SelectWithLabel } from '@eventespresso/ui-components';\nimport { regStatusOptions } from '@eventespresso/predicates';\nimport type { EventRegistrationOptionsProps } from './types';\n\ninterface Props extends Pick {}\n\nconst DefaultRegistrationStatus: React.FC = ({ defaultRegStatus, onDefaultRegStatusChange }) => {\n\tconst regStatusCode = useMemo(\n\t\t() => regStatusOptions.filter((option) => option.value === defaultRegStatus),\n\t\t[defaultRegStatus]\n\t);\n\tconst className = classNames(\n\t\t'ee-edtr-option ee-edtr-option__default-reg-status',\n\t\t`ee-status-bg--${regStatusCode[0]?.code}`\n\t);\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default DefaultRegistrationStatus;\n","import { __ } from '@eventespresso/i18n';\nimport { SwitchWithLabel } from '@eventespresso/ui-components';\nimport type { EventRegistrationOptionsProps } from './types';\n\ninterface Props extends Pick {}\n\nconst Donations: React.FC = ({ allowDonations: isChecked, onDonationsChange }) => {\n\tconst label = isChecked ? __('Donations Enabled') : __('Donations Disabled');\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default Donations;\n","import { useMemo } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { entityListToSelectOptions } from '@eventespresso/utils';\nimport { SelectWithLabel } from '@eventespresso/ui-components';\nimport type { EventRegistrationOptionsProps } from './types';\n\ninterface Props extends Pick {}\n\nconst EventManager: React.FC = ({ eventManagers, managerId, onManagerChange }) => {\n\tconst options = useMemo(() => eventManagers && entityListToSelectOptions(eventManagers), [eventManagers]);\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default EventManager;\n","import { __ } from '@eventespresso/i18n';\nimport { InlineEditTextWithLabel } from '@eventespresso/ui-components';\nimport type { EventRegistrationOptionsProps } from './types';\n\ninterface Props extends Pick {}\n\nconst EventPhoneNumber: React.FC = ({ onPhoneNumberChange, phoneNumber }) => {\n\treturn (\n\t\t\n\t);\n};\n\nexport default EventPhoneNumber;\n","import { __ } from '@eventespresso/i18n';\nimport { InlineEditTextWithLabel } from '@eventespresso/ui-components';\nimport type { EventRegistrationOptionsProps } from './types';\n\ninterface Props extends Pick {}\n\nconst MaxRegistrations: React.FC = ({ maxReg, onMaxRegChange }) => {\n\tconst strValue = maxReg && String(maxReg);\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default MaxRegistrations;\n","import { __ } from '@eventespresso/i18n';\nimport { SwitchWithLabel } from '@eventespresso/ui-components';\nimport type { EventRegistrationOptionsProps } from './types';\n\ninterface Props extends Pick {}\n\nconst TicketSelector: React.FC = ({ displayTicketSelector: isChecked, onTicketSelectorChange }) => {\n\tconst label = isChecked ? __('Ticket Selector Enabled') : __('Ticket Selector Disabled');\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default TicketSelector;\n","import { useCallback } from 'react';\n\nimport { useEvent, useEventManagers, useEventMutator } from '@eventespresso/edtr-services';\nimport type { InlineEditProps, SwitchProps } from '@eventespresso/adapters';\nimport type { AnyObject } from '@eventespresso/utils';\nimport type { EventRegistrationOptionsProps } from './types';\n\nconst withData =

(\n\tWrappedComponent: React.ComponentType\n): React.ComponentType

=> {\n\tconst WithData: React.FC

= () => {\n\t\tconst event = useEvent();\n\t\tconst eventManagers = useEventManagers();\n\n\t\tconst { updateEntity: updateEvent } = useEventMutator(event?.id);\n\n\t\tconst onAltRegPageChange = useCallback(\n\t\t\t(newAltRegPage) => {\n\t\t\t\tif (newAltRegPage !== event?.altRegPage) {\n\t\t\t\t\tupdateEvent({ altRegPage: newAltRegPage });\n\t\t\t\t}\n\t\t\t},\n\t\t\t[event?.altRegPage, updateEvent]\n\t\t);\n\n\t\tconst onDonationsChange = useCallback(\n\t\t\t(allowDonations) => {\n\t\t\t\tif (event?.allowDonations !== allowDonations) {\n\t\t\t\t\tupdateEvent({ allowDonations });\n\t\t\t\t}\n\t\t\t},\n\t\t\t[event?.allowDonations, updateEvent]\n\t\t);\n\n\t\tconst onDefaultRegStatusChange = useCallback(\n\t\t\t(defaultRegStatus) => {\n\t\t\t\tif (event?.defaultRegStatus !== defaultRegStatus) {\n\t\t\t\t\tupdateEvent({ defaultRegStatus });\n\t\t\t\t}\n\t\t\t},\n\t\t\t[event?.defaultRegStatus, updateEvent]\n\t\t);\n\n\t\tconst onManagerChange = useCallback(\n\t\t\t(newManagerId): void => {\n\t\t\t\tif (newManagerId !== event?.manager?.id) {\n\t\t\t\t\tupdateEvent({ manager: newManagerId }); // TODO - check this mutation because manager is an object with properties id and name\n\t\t\t\t}\n\t\t\t},\n\t\t\t[event?.manager?.id, updateEvent]\n\t\t);\n\n\t\tconst onMaxRegChange = useCallback(\n\t\t\t(newMaxRegistrations) => {\n\t\t\t\tconst maxRegistrations = Number(newMaxRegistrations);\n\t\t\t\tif (maxRegistrations !== event?.maxRegistrations) {\n\t\t\t\t\tupdateEvent({ maxRegistrations });\n\t\t\t\t}\n\t\t\t},\n\t\t\t[event?.maxRegistrations, updateEvent]\n\t\t);\n\n\t\tconst onPhoneNumberChange = useCallback(\n\t\t\t(newPhoneNumber) => {\n\t\t\t\tif (newPhoneNumber !== event?.phoneNumber) {\n\t\t\t\t\tupdateEvent({ phoneNumber: newPhoneNumber });\n\t\t\t\t}\n\t\t\t},\n\t\t\t[event?.phoneNumber, updateEvent]\n\t\t);\n\n\t\tconst onStatusChange = useCallback(\n\t\t\t(status) => {\n\t\t\t\tif (status !== event?.status) {\n\t\t\t\t\tupdateEvent({ status });\n\t\t\t\t}\n\t\t\t},\n\t\t\t[event?.status, updateEvent]\n\t\t);\n\n\t\tconst onTicketSelectorChange = useCallback(\n\t\t\t(displayTicketSelector) => {\n\t\t\t\tif (event?.displayTicketSelector !== displayTicketSelector) {\n\t\t\t\t\tupdateEvent({ displayTicketSelector });\n\t\t\t\t}\n\t\t\t},\n\t\t\t[event?.displayTicketSelector, updateEvent]\n\t\t);\n\n\t\treturn (\n\t\t\t\n\t\t);\n\t};\n\n\treturn WithData;\n};\n\nexport default withData;\n","import { __ } from '@eventespresso/i18n';\nimport { Grid, GridCard } from '@eventespresso/ui-components';\nimport { noop } from '@eventespresso/utils';\nimport { withFeature } from '@eventespresso/services';\n\nimport ActiveStatus from './ActiveStatus';\nimport AltRegPage from './AltRegPage';\nimport DefaultRegistrationStatus from './DefaultRegistrationStatus';\nimport Donations from './Donations';\nimport EventManager from './EventManager';\nimport EventPhoneNumber from './EventPhoneNumber';\nimport MaxRegistrations from './MaxRegistrations';\nimport TicketSelector from './TicketSelector';\nimport withData from './withData';\n\nimport type { EventRegistrationOptionsProps } from './types';\n\nimport './style.scss';\n\nexport const EventRegistrationOptions: React.FC> = ({\n\tallowDonations,\n\taltRegPage,\n\tdefaultRegStatus,\n\tdisplayTicketSelector,\n\teventManagers,\n\tmanagerId,\n\tmaxReg,\n\tonAltRegPageChange = noop,\n\tonDefaultRegStatusChange,\n\tonDonationsChange,\n\tonManagerChange,\n\tonPhoneNumberChange,\n\tonStatusChange,\n\tonTicketSelectorChange,\n\tonMaxRegChange = noop,\n\tphoneNumber,\n\tstatus,\n}) => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withFeature('use_reg_options_meta_box')(withData(EventRegistrationOptions));\n","import { useNewEntityOptionItems } from '@edtrHooks/index';\n\nconst useNewTicketOptionItems = (): Array => {\n\treturn useNewEntityOptionItems('ticket');\n};\n\nexport default useNewTicketOptionItems;\n","const style = { margin: '5px', border: '1px solid red' };\nconst OptionsModal: React.FC = ({ children }) => {\n\t// TODO convert this to modal\n\treturn

{children}
;\n};\n\nexport default OptionsModal;\n","import useNewTicketOptionItems from '@edtrUI/tickets/hooks/useNewTicketOptionItems';\nimport OptionsModal from './OptionsModal';\n\nconst NewTicketButton: React.FC = () => {\n\tconst optionItems = useNewTicketOptionItems();\n\tif (optionItems.length > 1) {\n\t\treturn {optionItems};\n\t}\n\treturn <>{optionItems};\n};\n\nexport default NewTicketButton;\n","import { __ } from '@eventespresso/i18n';\n\nimport { Button, NewEntityOption } from '@eventespresso/ui-components';\nimport { Ticket } from '@eventespresso/icons';\nimport { useGlobalModal } from '@eventespresso/registry';\nimport { EntityEditModalData } from '@edtrUI/types';\nimport { EdtrGlobalModals } from '@eventespresso/edtr-services';\n\ntype AddSingleTicketProps = {\n\tisOnlyButton?: boolean;\n};\n\nconst AddSingleTicket: React.FC = ({ isOnlyButton }) => {\n\tconst { open } = useGlobalModal(EdtrGlobalModals.EDIT_TICKET);\n\n\tconst output = (\n\t\t\n\t);\n\n\tif (isOnlyButton) {\n\t\treturn output;\n\t}\n\n\treturn (\n\t\t\n\t\t\t{output}\n\t\t\n\t);\n};\n\nexport default AddSingleTicket;\n","import { __ } from '@eventespresso/i18n';\nimport { useGlobalModal } from '@eventespresso/registry';\nimport { DropdownMenu, DropdownMenuItem, DropdownMenuProps } from '@eventespresso/ui-components';\nimport { EdtrGlobalModals } from '@eventespresso/edtr-services';\nimport { withFeature, useCurrentUserCan } from '@eventespresso/services';\n\nconst toggleProps: DropdownMenuProps['toggleProps'] = {\n\tnoPadding: true,\n\tsize: 'big',\n};\n\nexport const Actions = () => {\n\tconst { open } = useGlobalModal(EdtrGlobalModals.DEFAULT_TICKETS);\n\n\tconst currentUserCan = useCurrentUserCan();\n\n\tconst canReadDefaultTickets = currentUserCan('read', 'default_tickets');\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\t{/* King's throne for other future items */}\n\t\t\n\t);\n};\n\n// Since we only have default tickets in that dropdown for now, lets hide it completely\nexport default withFeature('use_default_ticket_manager')(Actions);\n","import { useTickets } from '@eventespresso/edtr-services';\nimport { EntityCacheIds } from '@eventespresso/ee-components';\n\nimport { NewTicketButton } from './newTicketOptions';\nimport { Actions } from './actions';\n\nconst TicketsListFooter: React.FC = () => {\n\tconst entities = useTickets();\n\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default TicketsListFooter;\n","import { IconName, Trash } from '@eventespresso/icons';\nimport { LegendConfig } from '@eventespresso/ui-components';\nimport { __ } from '@eventespresso/i18n';\n\nexport const legendConfig: LegendConfig = {\n\ticons: [\n\t\t{ icon: IconName.EDIT, description: __('Edit Ticket Details') },\n\t\t{ icon: IconName.CALENDAR, description: __('Manage Date Assignments') },\n\t\t{ icon: IconName.CALCULATOR, description: __('Ticket Price Calculator') },\n\t\t{ icon: Trash, description: __('Move Ticket to Trash') },\n\t],\n\tswatches: {\n\t\tTKA: __('Trashed'),\n\t\tTKE: __('Expired'),\n\t\tTKO: __('On Sale'),\n\t\tTKS: __('Sold Out'),\n\t\tTKP: __('Pending'),\n\t},\n};\n","import { lazy, Suspense } from 'react';\n\nimport { LoadingNotice } from '@eventespresso/ui-components';\n\nconst CardView = lazy(() => import(/* webpackChunkName: \"tickets-card-view\" */ './CardView'));\n\nconst RenderCardView: React.FC = () => {\n\treturn (\n\t\t}>\n\t\t\t\n\t\t\n\t);\n};\n\nexport default RenderCardView;\n","import { lazy, Suspense } from 'react';\n\nimport { LoadingNotice } from '@eventespresso/ui-components';\n\nconst TableView = lazy(() => import(/* webpackChunkName: \"tickets-table-view\" */ './TableView'));\n\nconst RenderTableView: React.FC = () => {\n\treturn (\n\t\t}>\n\t\t\t\n\t\t\n\t);\n};\n\nexport default RenderTableView;\n","import { __ } from '@eventespresso/i18n';\n\nimport { DisplayStartOrEndDate } from '@eventespresso/edtr-services';\n\nimport { TicketsSales, TicketsStatus } from '@eventespresso/predicates';\n\nexport const displayStartOrEndDateOptions = {\n\t[DisplayStartOrEndDate.start]: __('ticket sales start date only'),\n\t[DisplayStartOrEndDate.end]: __('ticket sales end date only'),\n\t[DisplayStartOrEndDate.both]: __('ticket sales start and end dates'),\n};\n\nexport const salesOptions = {\n\t[TicketsSales.all]: __('all tickets for all dates'),\n\t[TicketsSales.above90Sold]: __('tickets with 90% or more sold'),\n\t[TicketsSales.above75Sold]: __('tickets with 75% or more sold'),\n\t[TicketsSales.above50Sold]: __('tickets with 50% or more sold'),\n\t// eslint-disable-next-line @wordpress/i18n-translator-comments\n\t[TicketsSales.below50Sold]: __('tickets with less than 50% sold'),\n};\n\nexport const salesIsChainedOptions = {\n\t...salesOptions,\n\t[TicketsSales.all]: __('all tickets for above dates'),\n};\n\nexport const statusOptions = {\n\t[TicketsStatus.all]: __('all tickets for all dates'),\n\t[TicketsStatus.onSaleAndPending]: __('all on sale and sale pending'),\n\t[TicketsStatus.onSaleOnly]: __('on sale tickets only'),\n\t[TicketsStatus.pendingOnly]: __('sale pending tickets only'),\n\t[TicketsStatus.nextOnSaleOrPendingOnly]: __('next on sale or sale pending only'),\n\t[TicketsStatus.soldOutOnly]: __('sold out tickets only'),\n\t[TicketsStatus.expiredOnly]: __('expired tickets only'),\n\t[TicketsStatus.trashedOnly]: __('trashed tickets only'),\n};\n\nexport const statusIsChainedOptions = {\n\t...statusOptions,\n\t[TicketsStatus.all]: __('all tickets for above dates'),\n};\n\nexport const sortByOptions = {\n\tdate: __('ticket sale date'),\n\tname: __('ticket name'),\n\tid: __('ticket ID'),\n\torder: __('custom order'),\n};\n\nexport const labels = {\n\tdisplayStartOrEndDate: __('display'),\n\tisChained: __('linked'),\n\tsales: __('sales'),\n\tsearch: __('search'),\n\tsortBy: __('sort by'),\n\tstatus: __('status'),\n};\n","import { useCallback } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { ActiveFilters, FilterTag } from '@eventespresso/ui-components';\nimport { useTicketsListFilterState } from '@eventespresso/edtr-services';\nimport { TicketsSales, TicketsStatus } from '@eventespresso/predicates';\n\nimport { labels, statusOptions, salesOptions } from './controls/options';\n\nconst ActiveTicketsSFilters: React.FC = () => {\n\tconst { status, setStatus, sales, setSales, searchText, setSearchText, isChained, toggleIsChained } =\n\t\tuseTicketsListFilterState();\n\n\tconst statusTitle = `${labels.status}: ${statusOptions?.[status]}`;\n\tconst salesTitle = `${labels.sales}: ${salesOptions?.[sales]}`;\n\tconst searchTitle = `${labels.search}: ${searchText}`;\n\tconst isChainedTitle = `${labels.isChained}: ${__('ON')}`;\n\n\tconst onRemoveStatus = useCallback(() => setStatus(TicketsStatus.all), [setStatus]);\n\tconst onRemoveSales = useCallback(() => setSales(TicketsSales.all), [setSales]);\n\tconst onRemoveSearch = useCallback(() => setSearchText(''), [setSearchText]);\n\n\treturn (\n\t\t\n\t\t\t{status !== TicketsStatus.all && }\n\t\t\t{sales !== TicketsSales.all && }\n\t\t\t{searchText ? : null}\n\t\t\t{isChained && }\n\t\t\n\t);\n};\n\nexport default ActiveTicketsSFilters;\n","import { SelectWithLabel } from '@eventespresso/ui-components';\nimport { useTicketsListFilterState } from '@eventespresso/edtr-services';\nimport { objectToSelectOptions } from '@eventespresso/utils';\n\nimport { labels, displayStartOrEndDateOptions } from './options';\n\nconst options = objectToSelectOptions(displayStartOrEndDateOptions);\n\n/**\n * filter for controlling which dates display in a list of Event Dates\n */\nconst DisplayStartOrEndDateControl: React.FC = () => {\n\tconst { displayStartOrEndDate, setDisplayStartOrEndDate } = useTicketsListFilterState();\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default DisplayStartOrEndDateControl;\n","import { SelectWithLabel } from '@eventespresso/ui-components';\nimport { useTicketsListFilterState } from '@eventespresso/edtr-services';\nimport { useMemoStringify } from '@eventespresso/hooks';\nimport { objectToSelectOptions } from '@eventespresso/utils';\n\nimport { labels, salesOptions, salesIsChainedOptions } from './options';\n\nconst SalesControl: React.FC = () => {\n\tconst { isChained, sales, setSales } = useTicketsListFilterState();\n\tconst options = useMemoStringify(objectToSelectOptions(isChained ? salesIsChainedOptions : salesOptions), [\n\t\tisChained,\n\t]);\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default SalesControl;\n","import { SelectWithLabel } from '@eventespresso/ui-components';\nimport { useTicketsListFilterState } from '@eventespresso/edtr-services';\nimport { useMemoStringify } from '@eventespresso/hooks';\nimport { objectToSelectOptions } from '@eventespresso/utils';\n\nimport { labels, statusOptions, statusIsChainedOptions } from './options';\n\nconst StatusControl: React.FC = () => {\n\tconst { isChained, status, setStatus } = useTicketsListFilterState();\n\tconst options = useMemoStringify(objectToSelectOptions(isChained ? statusIsChainedOptions : statusOptions), [\n\t\tisChained,\n\t]);\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default StatusControl;\n","import { CurrencyDisplay, RangeFormat } from '@eventespresso/ee-components';\nimport { Ticket } from '@eventespresso/edtr-services';\n\nconst formatTokens = { month: 'LLL' };\n\nconst DraggableTicket: React.FC = ({ dbId, endDate, name, price, startDate }) => (\n\t<>\n\t\t{dbId})\n\t\t{name}: \n\t\t\n\t\t\t\n\t\t\n\t\t-\n\t\t\n\t\n);\n\nexport default DraggableTicket;\n","import { SortByControl as SortByControlUI } from '@eventespresso/ee-components';\nimport {\n\tTicket,\n\tuseFilteredTicketIds,\n\tuseReorderTickets,\n\tuseTicketsListFilterState,\n} from '@eventespresso/edtr-services';\nimport { ticketDroppableId } from '@eventespresso/constants';\nimport { objectToSelectOptions } from '@eventespresso/utils';\nimport { TypeName } from '@eventespresso/services';\nimport type { SortByControlProps } from '@eventespresso/ee-components';\n\nimport { labels, sortByOptions } from '../options';\nimport DraggableTicket from './DraggableTicket';\n\nconst options = objectToSelectOptions(sortByOptions);\n\nconst renderDraggableItem: SortByControlProps['renderDraggableItem'] = (ticket) => ({\n\t...ticket,\n\tcontent: ,\n});\n\n/**\n * filter for controlling the sorting of a list of Event Dates\n */\nconst SortByControl: React.FC = () => {\n\tconst { sortBy, setSortBy } = useTicketsListFilterState();\n\tconst filteredTicketIds = useFilteredTicketIds();\n\tconst {\n\t\tallReorderedEntities: draggableItems,\n\t\tsortResponder,\n\t\tupdateEntityList,\n\t} = useReorderTickets(filteredTicketIds);\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default SortByControl;\n","import classNames from 'classnames';\nimport { __ } from '@eventespresso/i18n';\n\nimport { IconButton } from '@eventespresso/ui-components';\nimport { Link, Unlink } from '@eventespresso/icons';\nimport { useTicketsListFilterState } from '@eventespresso/edtr-services';\n\nimport { labels } from './options';\n\n/**\n * filter for controlling whether Tickets List is chained to the Dates List\n * if true, then only tickets that are related to the dates in the dates list\n * will appear, otherwise ALL tickets will appear (subject to other filters)\n */\nconst IsChainedButton: React.FC = () => {\n\tconst { isChained, toggleIsChained } = useTicketsListFilterState();\n\tconst className = classNames('ee-filter-bar__btn ee-filter-bar__chain', {\n\t\t'ee-filter-bar__btn--active': isChained,\n\t\t'ee-filter-bar__chain--active': isChained,\n\t});\n\tconst icon = isChained ? Link : Unlink;\n\tconst tooltip = isChained\n\t\t? __('tickets list is linked to dates list and is showing tickets for above dates only')\n\t\t: __('tickets list is unlinked and is showing tickets for all event dates');\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default IsChainedButton;\n","import { useCallback } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { TypeName } from '@eventespresso/services';\nimport {\n\tdomain,\n\tticketsList,\n\tTicketsListProvider,\n\twithEntityListContext,\n\tuseTicketsListFilterState,\n\tuseRegisterIsChainedFilter,\n} from '@eventespresso/edtr-services';\nimport { EntityList } from '@eventespresso/ee-components';\n\nimport TicketsListFooter from './TicketsListFooter';\nimport { legendConfig } from './config';\nimport { RenderCardView } from './cardView';\nimport { RenderTableView } from './tableView';\nimport { ActiveTicketsFilters } from './filterBar';\n\nconst TicketsList: React.FC = () => {\n\tconst filterState = useTicketsListFilterState();\n\n\tconst renderList = useCallback(\n\t\t() => (filterState.view === 'card' ? : ),\n\t\t[filterState.view]\n\t);\n\n\treturn (\n\t\t}\n\t\t\tdomain={domain}\n\t\t\tentityType={TypeName.tickets}\n\t\t\tfilterState={filterState}\n\t\t\tfooter={}\n\t\t\theaderText={__('Available Tickets')}\n\t\t\tlegendConfig={legendConfig}\n\t\t\tlistId={ticketsList}\n\t\t\tloadingText={__('loading tickets…')}\n\t\t\trenderList={renderList}\n\t\t/>\n\t);\n};\n\nconst EnhancedTicketsList = withEntityListContext({\n\tProvider: TicketsListProvider,\n\tComponent: TicketsList,\n});\n\nconst ChainedTicketsList: React.FC = () => {\n\t// register isChained filter using hook.\n\tuseRegisterIsChainedFilter();\n\treturn ;\n};\n\nexport default ChainedTicketsList;\n","import { useCallback, useEffect } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { AdvancedTextEditor } from '@eventespresso/ee-components';\nimport { Heading } from '@eventespresso/ui-components';\nimport { useEvent, useEventMutator } from '@eventespresso/edtr-services';\nimport { withFeature } from '@eventespresso/services';\n\ntype AdvancedTextEditorProps = React.ComponentProps;\n\nconst EventDescription: React.FC = () => {\n\tconst event = useEvent();\n\n\tconst { updateEntity: updateEvent } = useEventMutator(event?.id);\n\n\tconst onChangeDescription = useCallback(\n\t\t(newDescription) => {\n\t\t\tif (newDescription !== event?.description) {\n\t\t\t\tupdateEvent({ description: newDescription });\n\t\t\t}\n\t\t},\n\t\t[event?.description, updateEvent]\n\t);\n\n\tuseEffect(() => {\n\t\t// remove tiny mce editor\n\t\tdocument.getElementById('postdivrich')?.remove();\n\t}, []);\n\n\treturn (\n\t\t
\n\t\t\t\n\t\t\t\t{__('Event Description')}\n\t\t\t\n\t\t\t\n\t\t
\n\t);\n};\n\nexport default withFeature('use_event_description_rte')(EventDescription);\n","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst VenueSeat = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(VenueSeat, 'venue-seat');\n","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst Phone = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(Phone, 'phone');\n","import { useMemo } from 'react';\nimport { addQueryArgs } from '@wordpress/url';\n\nimport { ADMIN_ROUTES } from '@eventespresso/constants';\nimport { useConfig, getAdminUrl } from '@eventespresso/services';\n\nexport const useVenueLink = (type: 'create_new' | 'edit', venueDbId?: number) => {\n\tconst { siteUrl } = useConfig();\n\n\treturn useMemo(() => {\n\t\tconst adminUrl = getAdminUrl({\n\t\t\tadminSiteUrl: siteUrl.admin,\n\t\t\tpage: ADMIN_ROUTES.VENUES,\n\t\t});\n\t\treturn addQueryArgs(adminUrl, {\n\t\t\tpost: venueDbId,\n\t\t\taction: type,\n\t\t\treturn: 'edit',\n\t\t});\n\t}, [siteUrl.admin, type, venueDbId]);\n};\n","import { useCallback, useMemo, useState } from 'react';\n\nimport { __, sprintf } from '@eventespresso/i18n';\nimport { Image } from '@eventespresso/adapters';\nimport { useEvent, useEventMutator, useVenues } from '@eventespresso/edtr-services';\nimport { isInfinite } from '@eventespresso/utils';\nimport { findEntityByGuid } from '@eventespresso/predicates';\nimport { Address, Container, Heading, TextLink, VenueSelector } from '@eventespresso/ui-components';\nimport { MapMarker, Phone, VenueSeat } from '@eventespresso/icons';\n\nimport { useVenueLink } from './useVenueLink';\n\nimport './styles.scss';\n\nconst classes = {\n\tcontainer: 'ee-edtr-section ee-event-venue',\n};\n\nconst header = (\n\t\n\t\t{__('Venue Details')}\n\t\n);\n\nexport const VenueDetails: React.FC = () => {\n\tconst event = useEvent();\n\tconst { updateEntity } = useEventMutator(event?.id);\n\tconst [selectedVenueId, setSelectedVenueId] = useState(event?.venue || '');\n\n\tconst venues = useVenues();\n\n\tconst selectedVenue = useMemo(() => findEntityByGuid(venues)(selectedVenueId), [selectedVenueId, venues]);\n\n\tconst createVenueLink = useVenueLink('create_new');\n\tconst editVenueLink = useVenueLink('edit', selectedVenue?.dbId);\n\n\tconst capacity = selectedVenue?.capacity;\n\tconst venueCapacity = isInfinite(capacity)\n\t\t? __('unlimited space')\n\t\t: sprintf(\n\t\t\t\t/* translators: %d venue capacity */\n\t\t\t\t__('Space for up to %d people'),\n\t\t\t\tselectedVenue?.capacity\n\t\t );\n\n\tconst onChangeInstantValue = useCallback((newValue) => setSelectedVenueId(newValue), []);\n\n\tconst onChangeValue = useCallback((venue) => updateEntity({ venue }), [updateEntity]);\n\tconst thumbnail = selectedVenue?.thumbnail;\n\n\tconst addressLabels = useMemo(\n\t\t() => ({\n\t\t\tinline: __('Venue address'),\n\t\t}),\n\t\t[]\n\t);\n\n\treturn (\n\t\t\n\t\t\t{selectedVenue && (\n\t\t\t\t
\n\t\t\t\t\t{thumbnail ? (\n\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t
\n\t\t\t\t\t) : (\n\t\t\t\t\t\t
\n\t\t\t\t\t\t\t{__('no image')}\n\t\t\t\t\t\t
\n\t\t\t\t\t)}\n\t\t\t\t\t
\n\t\t\t\t\t\t\n\t\t\t\t\t\t\t{selectedVenue?.name}\n\t\t\t\t\t\t\n\t\t\t\t\t\t
\n\t\t\t\t\t\t\t

{selectedVenue?.shortDescription}

\n\t\t\t\t\t\t
\n\t\t\t\t\t\t
\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t{venueCapacity}\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t{selectedVenue?.phone || '(###) ###-####'}\n\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t
\n\t\t\t\t\t\t
\n\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t{__('Edit this Venue')}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t
\n\t\t\t\t\t
\n\t\t\t\t
\n\t\t\t)}\n\t\t\t\n\t\t
\n\t);\n};\n","import { __ } from '@eventespresso/i18n';\nimport type { OptionsType } from '@eventespresso/adapters';\n\nexport type AppliesTo = 'ALL' | 'PRIMARY' | 'PURCHASER' | 'REGISTRANTS';\n\nexport const APPLIES_TO_OPTIONS: OptionsType = [\n\t{\n\t\tvalue: 'ALL',\n\t\tlabel: __('all'),\n\t},\n\t{\n\t\tvalue: 'PRIMARY',\n\t\tlabel: __('primary registrant'),\n\t},\n\t{\n\t\tvalue: 'PURCHASER',\n\t\tlabel: __('purchaser'),\n\t},\n\t{\n\t\tvalue: 'REGISTRANTS',\n\t\tlabel: __('registrants'),\n\t},\n];\n\nexport const MAPS_TO_OPTIONS: OptionsType = [\n\t{\n\t\tvalue: '',\n\t\tlabel: '...',\n\t},\n\t{\n\t\tvalue: 'Attendee.fname',\n\t\tlabel: __('Attendee First Name'),\n\t},\n\t{\n\t\tvalue: 'Attendee.lname',\n\t\tlabel: __('Attendee Last Name'),\n\t},\n\t{\n\t\tvalue: 'Attendee.email',\n\t\tlabel: __('Attendee Email Address'),\n\t},\n\t{\n\t\tvalue: 'Attendee.address',\n\t\tlabel: __('Attendee Address'),\n\t},\n];\n","import * as R from 'ramda';\n\nconst hasTypeAsText = R.propEq('type', 'TEXT');\nconst hasMapsToAsFName = R.propEq('mapsTo', 'Attendee.fname');\nconst hasTypeAsTextAndMapsToAsFName = R.allPass([hasTypeAsText, hasMapsToAsFName]);\n/**\n * Given a list of elements, it returns a boolean indicating whether there is\n * an element which maps to 'Attendee.fname'\n */\nexport const hasAnElementAsAttendeeFName = R.any(hasTypeAsTextAndMapsToAsFName);\n\nconst hasTypeAsEmail = R.propEq('type', 'EMAIL');\nconst hasMapsToAsEmail = R.propEq('mapsTo', 'Attendee.email');\nconst hasTypeAsEmailAndMapsToAsEmail = R.allPass([hasTypeAsEmail, hasMapsToAsEmail]);\n/**\n * Given a list of elements, it returns a boolean indicating whether there is\n * an element which maps to 'Attendee.email'\n */\nexport const hasAnElementAsAttendeeEmail = R.any(hasTypeAsEmailAndMapsToAsEmail);\n","import { useMemo } from 'react';\nimport * as R from 'ramda';\n\nimport { FormBuilderProps } from '@eventespresso/form-builder';\nimport { Banner } from '@eventespresso/ui-components';\nimport { sprintf, __ } from '@eventespresso/i18n';\nimport { isNotSharedOrDefault, getGuids } from '@eventespresso/predicates';\nimport { hasAnElementAsAttendeeEmail, hasAnElementAsAttendeeFName } from './utils';\n\nexport const ErrorMessage: FormBuilderProps['topBanner'] = ({ elements, sections }) => {\n\tlet message = '';\n\n\tconst info = useMemo(() => {\n\t\t// Lets not consider default or shared sections\n\t\t// because it is possible that there is valid data in default or shared sections/elements\n\t\t// but not added to the event\n\t\tconst formSectionIds = getGuids(Object.values(sections).filter(isNotSharedOrDefault));\n\n\t\tconst formElements = Object.values(elements).filter(\n\t\t\t// filters out the elements that belong to shared or default section\n\t\t\tR.propSatisfies(R.flip(R.includes)(formSectionIds), 'belongsTo')\n\t\t);\n\t\treturn {\n\t\t\thasFirstName: hasAnElementAsAttendeeFName(formElements),\n\t\t\thasEmail: hasAnElementAsAttendeeEmail(formElements),\n\t\t};\n\t}, [elements, sections]);\n\n\tif (!info.hasFirstName) {\n\t\tmessage = sprintf(\n\t\t\t/* translators: field name */\n\t\t\t__('Registration form must have a field of type \"%1$s\" which maps to \"%2$s\"'),\n\t\t\t__('Text Input'),\n\t\t\t__('Attendee First Name')\n\t\t);\n\t} else if (!info.hasEmail) {\n\t\tmessage = sprintf(\n\t\t\t/* translators: field name */\n\t\t\t__('Registration form must have a field of type \"%1$s\" which maps to \"%2$s\"'),\n\t\t\t__('Email Address'),\n\t\t\t__('Attendee Email Address')\n\t\t);\n\t}\n\n\tif (!message) {\n\t\treturn null;\n\t}\n\n\treturn ;\n};\n","import { __ } from '@eventespresso/i18n';\nimport { withFeature } from '@eventespresso/services';\nimport { Heading } from '@eventespresso/ui-components';\nimport { FormBuilder } from '@eventespresso/form-builder';\nimport { getEdtrDomData } from '@eventespresso/edtr-services';\n\nimport { APPLIES_TO_OPTIONS, MAPS_TO_OPTIONS } from './constants';\nimport { ErrorMessage } from './ErrorMessage';\n\nconst header = (\n\t\n\t\t{__('Registration Form')}\n\t\n);\n\nexport const RegistrationForm: React.FC = () => {\n\tconst { elements, sections, topLevelSectionId } = getEdtrDomData('formBuilder');\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default withFeature('use_reg_form_builder')(RegistrationForm);\n","import { useMemo } from 'react';\nimport { isDev } from '@eventespresso/constants';\nimport { useIsRehydrated } from '@eventespresso/data';\nimport { useStatus, TypeName } from '@eventespresso/services';\n\nconst useNotifications = () => {\n\tconst { isLoaded } = useStatus();\n\tconst [isRehydrated] = useIsRehydrated();\n\n\tconst readyTypes = useMemo(() => {\n\t\tconst types: string[] = [];\n\t\tif (!isDev || !isRehydrated) {\n\t\t\treturn [];\n\t\t}\n\t\tfor (const key in TypeName) {\n\t\t\tif (isLoaded(TypeName[key])) {\n\t\t\t\ttypes.push(TypeName[key]);\n\t\t\t}\n\t\t}\n\t\treturn types;\n\t}, [isLoaded, isRehydrated]);\n\n\treturn useMemo(\n\t\t() => ({\n\t\t\tdev: {\n\t\t\t\treadyTypes,\n\t\t\t},\n\t\t}),\n\t\t[readyTypes]\n\t);\n};\n\nexport default useNotifications;\n","import { useEffect } from 'react';\nimport { sprintf } from '@wordpress/i18n';\nimport { ToastContainer } from 'react-toastify';\nimport { useSystemNotifications, initToaster } from '@eventespresso/toaster';\n\nimport useNotifications from './useNotifications';\n\nconst Notifications = (): JSX.Element => {\n\tconst toaster = useSystemNotifications();\n\tconst toasts = useNotifications();\n\n\tuseEffect(() => {\n\t\tinitToaster();\n\t}, []);\n\n\tuseEffect(() => {\n\t\ttoasts.dev.readyTypes.forEach((type) => {\n\t\t\tconst message = sprintf('%s initialized', type);\n\t\t\ttoaster.success({ message, toastId: message });\n\t\t});\n\t}, [toaster, toasts]);\n\n\treturn ;\n};\n\nexport default Notifications;\n","import * as yup from 'yup';\n\nimport { datesSchema, DateFormShape } from '@eventespresso/edtr-services';\nimport { yupToFinalFormErrors } from '@eventespresso/form';\n\nexport const validate = async (values: DateFormShape): Promise => {\n\treturn await yupToFinalFormErrors(validationSchema, values);\n};\n\nconst validationSchema = yup.object({\n\tname: yup.string(),\n\t...datesSchema,\n});\n","import { useMemo, useCallback } from 'react';\nimport * as R from 'ramda';\n\nimport { CalendarOutlined, ControlOutlined, ProfileOutlined } from '@eventespresso/icons';\nimport { startAndEndDateFixer, useDatetimeItem, hooks } from '@eventespresso/edtr-services';\nimport { useUtcISOToSiteDate, useSiteDateToUtcISO } from '@eventespresso/services';\nimport type { EspressoFormProps } from '@eventespresso/form';\nimport { PLUS_ONE_MONTH } from '@eventespresso/constants';\nimport { useMemoStringify } from '@eventespresso/hooks';\nimport { setDefaultTime } from '@eventespresso/dates';\nimport { EndDateFieldWrapper } from '@eventespresso/ee-components';\nimport { EntityId } from '@eventespresso/data';\nimport { __ } from '@eventespresso/i18n';\nimport type { Datetime, DateFormConfig } from '@eventespresso/edtr-services';\n\nimport { validate } from './formValidation';\n\nconst FIELD_NAMES: Array = ['id', 'name', 'description', 'capacity', 'isTrashed'];\n\nconst decorators = [startAndEndDateFixer];\n\nconst adjacentFormItemProps = {\n\tclassName: 'ee-form-item-pair',\n};\n\nconst useDateFormConfig = (id: EntityId, config?: EspressoFormProps): DateFormConfig => {\n\tconst datetime = useDatetimeItem({ id });\n\n\tconst toUtcISO = useSiteDateToUtcISO();\n\tconst toSiteDate = useUtcISOToSiteDate();\n\n\tconst startDate = useMemoStringify(\n\t\tdatetime?.startDate ? toSiteDate(datetime?.startDate) : setDefaultTime(PLUS_ONE_MONTH, 'start')\n\t);\n\tconst endDate = useMemoStringify(\n\t\tdatetime?.endDate ? toSiteDate(datetime?.endDate) : setDefaultTime(PLUS_ONE_MONTH, 'end')\n\t);\n\n\tconst { onSubmit } = config;\n\n\tconst onSubmitFrom: DateFormConfig['onSubmit'] = useCallback(\n\t\tasync ({ startDate, endDate, ...values }, form, ...restParams) => {\n\t\t\treturn await onSubmit(\n\t\t\t\t{ ...values, startDate: toUtcISO(startDate), endDate: toUtcISO(endDate) },\n\t\t\t\tform,\n\t\t\t\t...restParams\n\t\t\t);\n\t\t},\n\t\t[onSubmit, toUtcISO]\n\t);\n\n\tconst initialValues = useMemo(() => {\n\t\treturn hooks.applyFilters(\n\t\t\t'eventEditor.dateForm.initalValues',\n\t\t\t{\n\t\t\t\t...R.pick, keyof Datetime>(FIELD_NAMES, datetime || {}),\n\t\t\t\tstartDate,\n\t\t\t\tendDate,\n\t\t\t},\n\t\t\tdatetime\n\t\t);\n\t}, [datetime, endDate, startDate]);\n\n\tconst sections = useMemo(() => {\n\t\treturn hooks.applyFilters(\n\t\t\t'eventEditor.dateForm.sections',\n\t\t\t[\n\t\t\t\t{\n\t\t\t\t\tname: 'basics',\n\t\t\t\t\ticon: ProfileOutlined,\n\t\t\t\t\ttitle: __('Basics'),\n\t\t\t\t\tfields: [\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tfieldType: 'text',\n\t\t\t\t\t\t\tlabel: __('Name'),\n\t\t\t\t\t\t\tname: 'name',\n\t\t\t\t\t\t},\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tname: 'description',\n\t\t\t\t\t\t\tlabel: __('Description'),\n\t\t\t\t\t\t\tfieldType: 'simple-text-editor',\n\t\t\t\t\t\t},\n\t\t\t\t\t],\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\tname: 'dateTime',\n\t\t\t\t\ticon: CalendarOutlined,\n\t\t\t\t\ttitle: __('Dates'),\n\t\t\t\t\tfields: [\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tname: 'startDate',\n\t\t\t\t\t\t\tlabel: __('Start Date'),\n\t\t\t\t\t\t\tfieldType: 'datetimepicker',\n\t\t\t\t\t\t\trequired: true,\n\t\t\t\t\t\t\tformControlProps: adjacentFormItemProps,\n\t\t\t\t\t\t},\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tname: 'endDate',\n\t\t\t\t\t\t\tlabel: __('End Date'),\n\t\t\t\t\t\t\tfieldType: 'datetimepicker',\n\t\t\t\t\t\t\trequired: true,\n\t\t\t\t\t\t\twrapper: EndDateFieldWrapper,\n\t\t\t\t\t\t\tformControlProps: adjacentFormItemProps,\n\t\t\t\t\t\t},\n\t\t\t\t\t],\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\tname: 'details',\n\t\t\t\t\ticon: ControlOutlined,\n\t\t\t\t\ttitle: __('Details'),\n\t\t\t\t\tfields: [\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tname: 'capacity',\n\t\t\t\t\t\t\tlabel: __('Capacity'),\n\t\t\t\t\t\t\tfieldType: 'number',\n\t\t\t\t\t\t\tparseAsInfinity: true,\n\t\t\t\t\t\t\tmin: -1,\n\t\t\t\t\t\t\tinfo:\n\t\t\t\t\t\t\t\t__(\n\t\t\t\t\t\t\t\t\t'The maximum number of registrants that can attend the event at this particular date.'\n\t\t\t\t\t\t\t\t) +\n\t\t\t\t\t\t\t\t'\\n' +\n\t\t\t\t\t\t\t\t__('Set to 0 to close registration or leave blank for no limit.'),\n\t\t\t\t\t\t\twidth: 'small',\n\t\t\t\t\t\t\tformControlProps: adjacentFormItemProps,\n\t\t\t\t\t\t},\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tname: 'isTrashed',\n\t\t\t\t\t\t\tlabel: __('Trash'),\n\t\t\t\t\t\t\tfieldType: 'switch',\n\t\t\t\t\t\t\tformControlProps: adjacentFormItemProps,\n\t\t\t\t\t\t},\n\t\t\t\t\t],\n\t\t\t\t},\n\t\t\t],\n\t\t\tdatetime\n\t\t);\n\t}, [datetime]);\n\n\treturn useMemo(\n\t\t() => ({\n\t\t\t...config,\n\t\t\tonSubmit: onSubmitFrom,\n\t\t\tdecorators,\n\t\t\tinitialValues,\n\t\t\tsubscription: {},\n\t\t\tvalidate,\n\t\t\tlayout: 'horizontal',\n\t\t\tsections,\n\t\t}),\n\t\t[config, initialValues, onSubmitFrom, sections]\n\t);\n};\n\nexport default useDateFormConfig;\n","import { __ } from '@eventespresso/i18n';\n\nimport { Calendar, Ticket } from '@eventespresso/icons';\nimport { Steps, Step } from '@eventespresso/ui-components';\nimport { PrevNext } from '@eventespresso/hooks';\n\nconst DatetimeFormSteps: React.FC> = ({ current }) => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default DatetimeFormSteps;\n","import { useEffect } from 'react';\n\nimport { useForm } from '@eventespresso/form';\n\nimport { useDataState as useTAMDataState } from '@edtrUI/ticketAssignmentsManager/data';\n\n/**\n * A custom hook which subscribes to TAM data and updates\n * RFF data when needed.\n */\nconst useDataListener: VoidFunction = () => {\n\tconst { getData } = useTAMDataState();\n\tconst { mutators, getState } = useForm();\n\tconst data = getData();\n\n\tconst id = getState().values.id || 'NEW_DATE';\n\tuseEffect(() => {\n\t\t// update value of `tickets` field in RFF state\n\t\tmutators.updateFieldValue('tickets', data?.datetimes?.[id]?.tickets);\n\t}, [data, id, mutators]);\n};\n\nexport default useDataListener;\n","/* eslint-disable @wordpress/i18n-no-collapsible-whitespace */\nimport { __ } from '@eventespresso/i18n';\n\nimport { Banner } from '@eventespresso/ui-components';\nimport { useDataState } from '../data';\n\ninterface ErrorMessageProps {\n\tasAlert?: boolean;\n\tdataState: ReturnType;\n}\n\nconst ErrorMessage: React.FC = ({ asAlert = true, dataState }) => {\n\tconst { hasOrphanDates, hasOrphanTickets } = dataState;\n\n\tlet message = '';\n\n\tif (hasOrphanTickets()) {\n\t\tmessage = __(\n\t\t\t'Tickets must always have at least one date assigned to them but one or more of the tickets below does not have any. \\nPlease correct the assignments for the highlighted cells.'\n\t\t);\n\t} else if (hasOrphanDates()) {\n\t\tmessage = __(\n\t\t\t'Event Dates must always have at least one Ticket assigned to them but one or more of the Event Dates below does not have any. \\nPlease correct the assignments for the highlighted cells.'\n\t\t);\n\t}\n\n\tif (!message) {\n\t\treturn null;\n\t}\n\n\tif (asAlert) {\n\t\treturn ;\n\t}\n\n\treturn {message};\n};\n\nexport default ErrorMessage;\n","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst MinusOutlined = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(MinusOutlined, 'minus-outlined');\n","import { CloseOutlined, MinusOutlined, Ticket } from '@eventespresso/icons';\n\nimport type { AssignmentStatus } from '../../../types';\n\nimport './styles.scss';\n\nconst getRelationIcon = (status?: AssignmentStatus): React.ComponentType => {\n\tswitch (status) {\n\t\tcase 'NEW':\n\t\tcase 'OLD':\n\t\t\treturn Ticket;\n\t\tcase 'REMOVED':\n\t\t\treturn CloseOutlined;\n\t\tdefault:\n\t\t\treturn MinusOutlined;\n\t}\n};\n\nexport default getRelationIcon;\n","import { useCallback, useMemo } from 'react';\n\nimport { Button } from '@eventespresso/ui-components';\nimport { sprintf } from '@eventespresso/i18n';\nimport { useDataState } from '../../data';\nimport getRelationIcon from './getRelationIcon';\nimport type { RenderCellProps } from '../../types';\nimport type { Datetime, Ticket } from '@eventespresso/edtr-services';\n\nconst BodyCell: React.FC = ({ datetime, ticket }) => {\n\tconst { getAssignmentStatus, toggleAssignment } = useDataState();\n\n\tconst status = getAssignmentStatus({ datetimeId: datetime.id, ticketId: ticket.id });\n\n\tconst onClick = useCallback(\n\t\t() => toggleAssignment({ datetimeId: datetime.id, ticketId: ticket.id }),\n\t\t[datetime.id, ticket.id, toggleAssignment]\n\t);\n\n\tconst icon = useMemo(() => getRelationIcon(status), [status]);\n\n\tconst nameOrId = (entity: Datetime | Ticket): string => {\n\t\tif (entity.name && entity.name.length > 0) {\n\t\t\treturn entity.name;\n\t\t}\n\t\tif (entity.dbId === 0) {\n\t\t\treturn '';\n\t\t}\n\t\treturn entity.dbId.toString();\n\t};\n\n\tconst entityLabel = useCallback((entity: Datetime | Ticket, type: string): string => {\n\t\tconst token = nameOrId(entity);\n\t\t/* translators: %1$s entity type, %2$s entity name or id */\n\t\treturn sprintf('%1$s %2$s', type, token);\n\t}, []);\n\n\tconst ariaLabel: string = useMemo(() => {\n\t\tconst ticketLabel = entityLabel(ticket, 'ticket');\n\t\tconst datetimeLabel = entityLabel(datetime, 'datetime');\n\t\tswitch (status) {\n\t\t\tcase null:\n\t\t\t\t// no current status so assign new relation\n\t\t\t\t/* translators: %1$s ticket label, %2$s datetime label */\n\t\t\t\treturn sprintf('click to assign %1$s to %2$s', ticketLabel, datetimeLabel);\n\t\t\tcase 'NEW':\n\t\t\t\t// remove newly assigned relation\n\t\t\t\t/* translators: %1$s ticket label, %2$s datetime label */\n\t\t\t\treturn sprintf('click to remove new assignment for %1$s from %2$s', ticketLabel, datetimeLabel);\n\t\t\tcase 'OLD':\n\t\t\t\t// remove existing relation\n\t\t\t\t/* translators: %1$s ticket label, %2$s datetime label */\n\t\t\t\treturn sprintf('click to remove %1$s from %2$s', ticketLabel, datetimeLabel);\n\t\t\tcase 'REMOVED':\n\t\t\t\t// reassign newly removed relation\n\t\t\t\t/* translators: %1$s ticket label, %2$s datetime label */\n\t\t\t\treturn sprintf('click to reassign %1$s to %2$s', ticketLabel, datetimeLabel);\n\t\t}\n\t}, [ticket, datetime, status, entityLabel]);\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default BodyCell;\n","import { parseISO } from 'date-fns';\nimport classNames from 'classnames';\nimport { __ } from '@eventespresso/i18n';\n\nimport type { RenderCellProps } from '../../types';\nimport { getDatetimeBackgroundColorClassName } from '@eventespresso/helpers';\nimport { useTimeZoneTime } from '@eventespresso/services';\nimport { LOCALIZED_DATE_SHORT_FORMAT } from '@eventespresso/constants';\n\nconst DateCell: React.FC = ({ datetime }) => {\n\tconst bgClassName = getDatetimeBackgroundColorClassName(datetime);\n\tconst stripeClassName = classNames('date-stripe', bgClassName);\n\n\tconst { formatForSite: format } = useTimeZoneTime();\n\tlet startDate: any = datetime.startDate;\n\tif (startDate instanceof Date) {\n\t\tstartDate = format(startDate, LOCALIZED_DATE_SHORT_FORMAT);\n\t} else if (startDate) {\n\t\tstartDate = format(parseISO(datetime.startDate), LOCALIZED_DATE_SHORT_FORMAT);\n\t}\n\n\treturn (\n\t\t
\n\t\t\t
\n\t\t\t
{`${__('ID')}: ${datetime.dbId}`}
\n\t\t\t
{datetime.name}
\n\t\t\t
{startDate}
\n\t\t
\n\t);\n};\n\nexport default DateCell;\n","import { useCallback } from 'react';\n\nimport type { Datetime } from '@eventespresso/edtr-services';\nimport { useDataState } from '../../data';\n\ntype Callback = (datetime: Datetime) => string;\n\nconst useRowClassName = (): Callback => {\n\tconst { hasNoAssignedTickets } = useDataState();\n\n\treturn useCallback(\n\t\t(datetime) => {\n\t\t\tconst isOrphan = hasNoAssignedTickets({ datetimeId: datetime.id });\n\t\t\treturn isOrphan ? 'no-assignments' : '';\n\t\t},\n\t\t[hasNoAssignedTickets]\n\t);\n};\n\nexport default useRowClassName;\n","import { useCallback } from 'react';\n\nimport type { Ticket } from '@eventespresso/edtr-services';\nimport { useDataState } from '../../data';\n\ntype Callback = (ticket: Ticket) => string;\n\nconst useColClassName = (): Callback => {\n\tconst { hasNoAssignedDates } = useDataState();\n\n\treturn useCallback(\n\t\t(ticket) => {\n\t\t\tconst isOrphan = hasNoAssignedDates({ ticketId: ticket.id });\n\t\t\treturn isOrphan ? 'no-assignments' : '';\n\t\t},\n\t\t[hasNoAssignedDates]\n\t);\n};\n\nexport default useColClassName;\n","import { useMemo } from 'react';\nimport classNames from 'classnames';\n\nimport type { BodyRow, CellData } from '@eventespresso/ui-components';\n\nimport BodyCell from './BodyCell';\nimport DateCell from './DateCell';\nimport { useDataState } from '../../data';\nimport useRowClassName from './useRowClassName';\nimport useColClassName from './useColClassName';\nimport type { DatesAndTickets, RelationClassName } from '../../types';\n\nconst useGetBodyRows = ({ datetimes, tickets }: DatesAndTickets): BodyRow[] => {\n\tconst { getAssignmentStatus } = useDataState();\n\n\tconst getRowClass = useRowClassName();\n\tconst getColClass = useColClassName();\n\n\treturn useMemo(() => {\n\t\treturn datetimes.map((datetime) => {\n\t\t\tconst datetimeCell: CellData = {\n\t\t\t\tclassName: 'ee-rspnsv-table-column-micro date-cell',\n\t\t\t\tkey: 'datetime',\n\t\t\t\tvalue: ,\n\t\t\t};\n\n\t\t\tconst cells: Array = tickets.map((ticket) => {\n\t\t\t\tconst status = getAssignmentStatus({ datetimeId: datetime.id, ticketId: ticket.id });\n\t\t\t\tconst statusClassName = status && (`${status.toLowerCase()}-assignment` as RelationClassName);\n\n\t\t\t\tconst className = classNames('relation-cell', statusClassName, getColClass(ticket));\n\n\t\t\t\tconst cell: CellData = {\n\t\t\t\t\tclassName,\n\t\t\t\t\tkey: ticket.id,\n\t\t\t\t\tsize: 'huge',\n\t\t\t\t\ttextAlign: 'center',\n\t\t\t\t\tvalue: ,\n\t\t\t\t};\n\n\t\t\t\treturn cell;\n\t\t\t});\n\n\t\t\treturn {\n\t\t\t\tcells: [datetimeCell, ...cells],\n\t\t\t\tclassName: { bodyRowClassName: 'ee-ticket-assignments-manager-table-body-row' },\n\t\t\t\trowClassName: getRowClass(datetime),\n\t\t\t\tkey: datetime.id,\n\t\t\t\tprimary: true,\n\t\t\t\ttype: 'row',\n\t\t\t};\n\t\t});\n\t}, [datetimes, getAssignmentStatus, getColClass, getRowClass, tickets]);\n};\n\nexport default useGetBodyRows;\n","import { parseISO } from 'date-fns';\nimport classNames from 'classnames';\nimport { __ } from '@eventespresso/i18n';\n\nimport { CurrencyDisplay } from '@eventespresso/ee-components';\nimport { getTicketBackgroundColorClassName } from '@eventespresso/helpers';\nimport { useTimeZoneTime } from '@eventespresso/services';\nimport type { RenderCellProps } from '../../types';\n\nconst FORMAT = 'MMM dd yyyy';\n\nconst HeaderCell: React.FC = ({ ticket }) => {\n\tconst bgClassName = getTicketBackgroundColorClassName(ticket);\n\tconst { formatForSite: format } = useTimeZoneTime();\n\tlet startDate: any = ticket.startDate;\n\tif (startDate instanceof Date) {\n\t\tstartDate = format(startDate, FORMAT);\n\t} else if (startDate) {\n\t\tstartDate = format(parseISO(ticket.startDate), FORMAT);\n\t}\n\n\tconst startDateClassName = classNames(bgClassName, 'header-cell-content__after');\n\n\treturn (\n\t\t
\n\t\t\t
\n\t\t\t\t
{`${__('ID')}: ${ticket.dbId}`}
\n\t\t\t\t
{ticket.name}
\n\t\t\t\t
\n\t\t\t\t\t\n\t\t\t\t
\n\t\t\t
\n\t\t\t
{startDate}
\n\t\t
\n\t);\n};\n\nexport default HeaderCell;\n","import { useMemo } from 'react';\n\nimport type { CellData, HeaderRow } from '@eventespresso/ui-components';\nimport type { Ticket } from '@eventespresso/edtr-services';\nimport { __ } from '@eventespresso/i18n';\n\nimport HeaderCell from './HeaderCell';\nimport useColClassName from './useColClassName';\n\nconst emptyCell: CellData = {\n\tkey: 'empty',\n\tsize: 'huge',\n\tvalue: (\n\t\t
\n\t\t\t

{__('Assignments')}

\n\t\t\t

{__('Event Dates are listed below')}

\n\t\t\t

{__('Tickets are listed along the top')}

\n\t\t\t

{__('Click the cell buttons to toggle assigments')}

\n\t\t
\n\t),\n};\n\nconst useGetHeaderRows = (tickets: Ticket[]): HeaderRow[] => {\n\tconst getColClass = useColClassName();\n\n\treturn useMemo(() => {\n\t\tconst cells: Array = tickets.map((ticket) => ({\n\t\t\tclassName: getColClass(ticket),\n\t\t\tkey: ticket.id,\n\t\t\tsize: 'huge',\n\t\t\tvalue: ,\n\t\t}));\n\n\t\treturn [\n\t\t\t{\n\t\t\t\tcells: [emptyCell, ...cells],\n\t\t\t\tkey: 'ee-ticket-assignments-manager-table-header-row',\n\t\t\t\tprimary: true,\n\t\t\t\ttype: 'row',\n\t\t\t},\n\t\t];\n\t}, [getColClass, tickets]);\n};\n\nexport default useGetHeaderRows;\n","import { __ } from '@eventespresso/i18n';\n\nimport useGetBodyRows from './useGetBodyRows';\nimport useGetHeaderRows from './useGetHeaderRows';\nimport { DatesAndTickets } from '../../types';\nimport { ResponsiveTable } from '@eventespresso/ui-components';\n\nimport './styles.scss';\n\nconst metaData = {\n\tisScrollable: true,\n\ttableId: 'ee-ticket-assignments-manager-table',\n\ttableCaption: __('Ticket Assignment Manager'),\n};\nconst className = { tableClassName: 'ee-ticket-assignments-manager' };\n\nconst Table: React.FC = ({ datetimes, tickets }) => {\n\tconst bodyRows = useGetBodyRows({ datetimes, tickets });\n\tconst headerRows = useGetHeaderRows(tickets);\n\n\treturn ;\n};\n\nexport default Table;\n","import { DebugInfo } from '@eventespresso/ui-components';\n\nimport { useDataState } from '../data';\n\nconst Debug = () => {\n\tconst { getData } = useDataState();\n\n\treturn ;\n};\n\nexport default Debug;\n","import ErrorMessage from './ErrorMessage';\nimport { Table } from './table';\nimport { FilterBar } from '../filters';\nimport { useDatesAndTickets } from '../data';\nimport { useDataState } from '../data';\nimport Debug from './Debug';\n\nconst TicketAssignmentsManager: React.FC = () => {\n\tconst datesAndTickets = useDatesAndTickets();\n\tconst dataState = useDataState();\n\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t\n\t\t\t
\n\t\t\t\n\t\t\n\t);\n};\n\nexport default TicketAssignmentsManager;\n","import { __ } from '@eventespresso/i18n';\nimport getRelationIcon from '../components/table/getRelationIcon';\nimport type { LegendConfig } from '@eventespresso/ui-components';\nimport type { RelationClassName } from '../types';\n\nexport const legendConfig: LegendConfig = {\n\ticons: [\n\t\t{\n\t\t\tclassName: 'old-assignment',\n\t\t\tdescription: __('existing relation'),\n\t\t\ticon: getRelationIcon('OLD'),\n\t\t},\n\t\t{\n\t\t\tclassName: 'removed-assignment',\n\t\t\tdescription: __('remove existing relation'),\n\t\t\ticon: getRelationIcon('REMOVED'),\n\t\t},\n\t\t{\n\t\t\tclassName: 'new-assignment',\n\t\t\tdescription: __('add new relation'),\n\t\t\ticon: getRelationIcon('NEW'),\n\t\t},\n\t\t{\n\t\t\tclassName: 'no-assignments',\n\t\t\tdescription: __('invalid relation'),\n\t\t\ticon: getRelationIcon(),\n\t\t},\n\t\t{\n\t\t\tdescription: __('no relation'),\n\t\t\ticon: getRelationIcon(),\n\t\t},\n\t],\n};\n","import { useCallback, useMemo, useState } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { ButtonType } from '@eventespresso/ui-components';\nimport type { ButtonProps } from '@eventespresso/ui-components';\nimport { SaveOutlined } from '@eventespresso/icons';\n\nimport { useDataState } from '../data';\nimport { TAMModalProps } from '../context';\n\nconst useSubmitButtonProps = (onSubmitData: TAMModalProps['onSubmit']): ButtonProps => {\n\tconst { hasOrphanEntities, getData } = useDataState();\n\tconst [isSubmitting, setIsSubmitting] = useState(false);\n\n\tconst hasErrors = hasOrphanEntities();\n\n\tconst onSubmit = useCallback(\n\t\tasync (e) => {\n\t\t\te.preventDefault();\n\t\t\tsetIsSubmitting(true);\n\t\t\tawait onSubmitData(getData());\n\t\t\tsetIsSubmitting(false);\n\t\t},\n\t\t[getData, onSubmitData]\n\t);\n\n\treturn useMemo(\n\t\t() => ({\n\t\t\tbuttonText: __('Submit'),\n\t\t\tbuttonType: ButtonType.PRIMARY,\n\t\t\ticon: SaveOutlined,\n\t\t\tisDisabled: hasErrors,\n\t\t\tisLoading: isSubmitting,\n\t\t\tonClick: onSubmit,\n\t\t\ttype: 'submit',\n\t\t}),\n\t\t[hasErrors, isSubmitting, onSubmit]\n\t);\n};\n\nexport default useSubmitButtonProps;\n","import { useMemo, useContext } from 'react';\nimport { __ } from '@eventespresso/i18n';\nimport { CollapsibleLegend, ModalWithAlert } from '@eventespresso/ui-components';\nimport type { ModalWithAlertProps } from '@eventespresso/ui-components';\n\nimport { legendConfig } from './config';\nimport TicketAssignmentsManager from './TicketAssignmentsManager';\nimport { useDataState } from '../data';\nimport type { TAMModalProps } from '../context/types';\nimport useSubmitButtonProps from './useSubmitButtonProps';\nimport { Context } from '../context/ContextProvider';\n\nimport './styles.scss';\n\nconst TicketAssignmentsManagerModal: React.FC> = ({ onCloseModal, onSubmit, title }) => {\n\tconst { hasOrphanEntities, isDirty } = useDataState();\n\tconst hasErrors = hasOrphanEntities();\n\n\tconst submitButtonProps = useSubmitButtonProps(onSubmit);\n\n\tconst data = useContext(Context);\n\n\tconst ariaLabel: string = useMemo(() => {\n\t\tif (!data.entity) {\n\t\t\treturn '';\n\t\t}\n\t\treturn `ticket assignment modal for datetime ${data.entity.name}`;\n\t}, [data]);\n\n\tconst ariaAttributes: ModalWithAlertProps['ariaAttributes'] = useMemo(\n\t\t() => ({ modalContent: { 'aria-label': ariaLabel } }),\n\t\t[ariaLabel]\n\t);\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default TicketAssignmentsManagerModal;\n","import { useCallback, useEffect, useState } from 'react';\nimport * as R from 'ramda';\n\nimport { useRelations } from '@eventespresso/services';\nimport { useDefaultTicketIds } from '@eventespresso/edtr-services';\n\nimport { TAM_ENTITIES } from '../constants';\n\ntype Callback = (check: boolean) => void;\n\nconst useInvalidDataAlert = (showAlert: VoidFunction): Callback => {\n\tconst { getData } = useRelations();\n\tconst [validateData, setValidateData] = useState(false);\n\tconst defaultTicketIds = useDefaultTicketIds();\n\n\tconst hasOrphanEntities = useCallback(() => {\n\t\tconst data = getData();\n\t\t// remove default tickets from TAM relations\n\t\tconst newData = { ...data, tickets: R.omit(defaultTicketIds, data.tickets || {}) };\n\t\t// simplify the data for loop\n\t\tconst entries = Object.entries(R.pick(TAM_ENTITIES, newData));\n\n\t\tfor (const [, entityRelations] of entries) {\n\t\t\tfor (const [, relations] of Object.entries(entityRelations)) {\n\t\t\t\tconst tamRelations = R.pick(TAM_ENTITIES, relations);\n\t\t\t\t// flatten the relations\n\t\t\t\tconst relatedIds = Object.values(tamRelations).flat();\n\t\t\t\tif (!relatedIds.length) {\n\t\t\t\t\treturn true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}, [defaultTicketIds, getData]);\n\n\tuseEffect(() => {\n\t\tif (validateData && hasOrphanEntities()) {\n\t\t\tshowAlert();\n\t\t\tsetValidateData(false);\n\t\t}\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\t}, [validateData]);\n\n\treturn setValidateData;\n};\n\nexport default useInvalidDataAlert;\n","import { useMemo, useCallback } from 'react';\n\nimport { sprintf, __ } from '@eventespresso/i18n';\nimport { EdtrGlobalModals } from '@eventespresso/edtr-services';\nimport { useGlobalModal } from '@eventespresso/registry';\nimport { useConfirmationDialog } from '@eventespresso/ui-components';\nimport { wait } from '@eventespresso/utils';\n\nimport TicketAssignmentsManagerModal from './TicketAssignmentsManagerModal';\nimport { withContext } from '../context';\nimport { useOnSubmitAssignments } from '../data';\nimport type { TAMModalProps } from '../context';\nimport type { BaseProps } from '../types';\nimport useInvalidDataAlert from './useInvalidDataAlert';\n\nconst ModalContainer: React.FC = () => {\n\tconst { getData, isOpen, close: onClose, openWithData } = useGlobalModal(EdtrGlobalModals.TAM);\n\n\tconst submitAssignments = useOnSubmitAssignments();\n\n\tconst reOpenTamModal = useCallback(() => {\n\t\topenWithData({ assignmentType: 'forAll' });\n\t}, [openWithData]);\n\n\tconst { confirmationDialog, onOpen: showAlert } = useConfirmationDialog({\n\t\tmessage: __(\n\t\t\t'There seem to be some dates/tickets which have no tickets/dates assigned. Do you want to fix them now?'\n\t\t),\n\t\ttitle: __('Alert!'),\n\t\tonConfirm: reOpenTamModal,\n\t});\n\n\tconst validateData = useInvalidDataAlert(showAlert);\n\n\tconst { assignmentType, entity } = getData();\n\n\tlet title = '';\n\n\tif (assignmentType === 'forDate') {\n\t\ttitle = sprintf(\n\t\t\t/* translators: 1 entity id, 2 entity name */\n\t\t\t__('Ticket Assignment Manager for Datetime: %1$s - %2$s'),\n\t\t\tString(entity.dbId),\n\t\t\tentity.name\n\t\t);\n\t} else if (assignmentType === 'forTicket') {\n\t\ttitle = sprintf(\n\t\t\t/* translators: 1 entity id, 2 entity name */\n\t\t\t__('Ticket Assignment Manager for Ticket: %1$s - %2$s'),\n\t\t\tString(entity.dbId),\n\t\t\tentity.name\n\t\t);\n\t}\n\n\tconst contextProps = useMemo(\n\t\t() => ({ assignmentType, entity, title, onCloseModal: onClose }),\n\t\t[assignmentType, entity, onClose, title]\n\t);\n\n\tconst onSubmit = useCallback(\n\t\tasync (data) => {\n\t\t\tvalidateData(false);\n\t\t\t// wait the next event cycle to fire up isLoading for submit button\n\t\t\tawait wait();\n\t\t\t// close the moal\n\t\t\tonClose();\n\t\t\t// submit TAM data\n\t\t\tawait submitAssignments(data);\n\t\t\tvalidateData(true);\n\t\t},\n\t\t[validateData, onClose, submitAssignments]\n\t);\n\n\tif (!isOpen) {\n\t\treturn <>{confirmationDialog};\n\t}\n\n\tconst Component = withContext(TicketAssignmentsManagerModal, contextProps);\n\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t{confirmationDialog}\n\t\t\n\t);\n};\n\nexport default ModalContainer;\n","import { TicketAssignmentsManager } from '@edtrUI/ticketAssignmentsManager/components';\nimport useDataListener from './useDataListener';\n\nconst TAMStep = () => {\n\tuseDataListener();\n\n\treturn ;\n};\n\nexport default TAMStep;\n","import DateFormSteps from './DateFormSteps';\nimport useDataListener from './useDataListener';\nimport { ModalBodyProps } from './types';\nimport { ASSIGN_TICKETS_STEP, DATE_DETAILS_STEP } from './constants';\nimport TAMStep from './TAMStep';\n\n/**\n * This component is inside both RFF and TAM contexts, so we can use all of their features\n */\nconst ModalBody: React.FC = ({ children: body, steps }) => {\n\t// init data listener to update RFF data\n\tuseDataListener();\n\n\treturn (\n\t\t
\n\t\t\t\n\t\t\t{/* RFF fields */}\n\t\t\t{steps.current === DATE_DETAILS_STEP && body}\n\n\t\t\t{steps.current === ASSIGN_TICKETS_STEP && }\n\t\t
\n\t);\n};\n\nexport default ModalBody;\n","export const DATE_DETAILS_STEP = 0;\n\nexport const ASSIGN_TICKETS_STEP = 1;\n","import { __ } from '@eventespresso/i18n';\n\nimport { ButtonRow, Next, Previous, Submit } from '@eventespresso/ui-components';\nimport { withFormSubscription, FormSubscriptionProps } from '@eventespresso/ee-components';\nimport type { PrevNext } from '@eventespresso/hooks';\n\nimport { useDataState as useTAMDataState } from '@edtrUI/ticketAssignmentsManager/data';\nimport { ASSIGN_TICKETS_STEP, DATE_DETAILS_STEP } from './constants';\n\ninterface FooterButtonsProps extends FormSubscriptionProps {\n\tsteps: PrevNext;\n}\n\nconst FooterButtons: React.FC = ({ form, hasErrors, steps, submitting }) => {\n\tconst { current, prev, next } = steps;\n\tconst { hasOrphanEntities } = useTAMDataState();\n\tconst isSubmitDisabled = hasOrphanEntities();\n\n\treturn (\n\t\t\n\t\t\t{current === DATE_DETAILS_STEP && (\n\t\t\t\t\n\t\t\t)}\n\n\t\t\t{current === ASSIGN_TICKETS_STEP && (\n\t\t\t\t<>\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t)}\n\t\t\n\t);\n};\n\nexport default withFormSubscription(FooterButtons);\n","import { useMemo } from 'react';\nimport { EntityEditModal } from '@eventespresso/ee-components';\nimport { EdtrGlobalModals, useEvent, useDatetimeItem } from '@eventespresso/edtr-services';\nimport { useGlobalModal } from '@eventespresso/registry';\nimport { __, sprintf } from '@eventespresso/i18n';\nimport { usePrevNext } from '@eventespresso/hooks';\nimport { useIsPristine } from '@eventespresso/form';\nimport { EntityEditModalProps } from '@eventespresso/ui-components';\n\nimport ModalBody from './ModalBody';\nimport FooterButtons from './FooterButtons';\n\nimport type { ContentWrapperProps } from './types';\nimport type { EntityEditModalData } from '@edtrUI/types';\n\nconst Modal: React.FC = ({ onClose, ...props }) => {\n\tconst { isOpen } = useGlobalModal(EdtrGlobalModals.EDIT_DATE);\n\tconst event = useEvent();\n\tconst steps = usePrevNext();\n\tconst isPristine = useIsPristine();\n\n\tconst { values } = props.form.getState();\n\n\tconst datetime = useDatetimeItem({ id: values?.id });\n\n\tconst title: string = useMemo(() => {\n\t\tconst str = datetime?.dbId\n\t\t\t? sprintf(\n\t\t\t\t\t/* translators: %d database id */\n\t\t\t\t\t__('Edit datetime %s'),\n\t\t\t\t\t`#${datetime.dbId}`\n\t\t\t )\n\t\t\t: __('New Datetime');\n\t\t// add event name to the title\n\t\treturn event?.name ? `${event.name}: ${str}` : str;\n\t}, [datetime, event]);\n\n\tconst footerButtons = ;\n\n\tconst ariaAttributes: EntityEditModalProps['ariaAttributes'] = useMemo(() => {\n\t\tconst getAriaLabel = (): string => {\n\t\t\tif (!datetime || !datetime.name) {\n\t\t\t\treturn __('modal for datetime');\n\t\t\t}\n\t\t\t/* translators: %s datetime name */\n\t\t\treturn sprintf('modal for datetime %s', datetime.name);\n\t\t};\n\t\treturn {\n\t\t\tmodalContent: { 'aria-label': getAriaLabel() },\n\t\t};\n\t}, [datetime]);\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default Modal;\n","import { useMemoStringify } from '@eventespresso/hooks';\nimport { useFormValues } from '@eventespresso/form';\nimport { Datetime, DateFormShape, useDatetimeItem } from '@eventespresso/edtr-services';\n\nimport { ContextProvider as TAMContextProvider } from '@edtrUI/ticketAssignmentsManager/context';\nimport Modal from './Modal';\n\nimport type { ContentWrapperProps } from './types';\n\nconst ContextProvider: React.FC = (props) => {\n\tconst { values: initialValues } = props.form.getState();\n\tconst values = useFormValues(initialValues);\n\n\tconst datetime = useDatetimeItem({ id: values?.id });\n\n\t// add defaults from Apollo cache and override the set values from form state\n\tconst entity = useMemoStringify({ id: 'NEW_DATE', dbId: 0, ...datetime, ...values } as Datetime);\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default ContextProvider;\n","import { useMemo } from 'react';\n\nimport { FormWithConfig } from '@eventespresso/ee-components';\n\nimport useDatetimeFormConfig from '../useDateFormConfig';\nimport ContextProvider from './ContextProvider';\nimport type { ContentProps } from './types';\n\nconst Content: React.FC = ({ entityId, onClose, onSubmit }) => {\n\tconst config = useMemo(() => ({ onSubmit }), [onSubmit]);\n\tconst formConfig = useDatetimeFormConfig(entityId, config);\n\n\treturn ;\n};\n\nexport default Content;\n","import { useCallback } from 'react';\n\nimport {\n\tuseDatetimeMutator,\n\tuseUpdateTicketQtyByCapacity,\n\tuseDatetimeItem,\n\tuseDatetimes,\n} from '@eventespresso/edtr-services';\nimport { getHighestOrder } from '@eventespresso/predicates';\nimport type { EntityId } from '@eventespresso/data';\nimport { isInfinite, wait } from '@eventespresso/utils';\n\nimport { OnSubmit } from './types';\n\nconst useOnSubmit = (entityId: EntityId, onClose: VoidFunction): OnSubmit => {\n\tconst { createEntity, updateEntity } = useDatetimeMutator();\n\tconst datetime = useDatetimeItem({ id: entityId });\n\n\tconst { createBulkQtyUpdateInput, doQtyBulkUpdate } = useUpdateTicketQtyByCapacity();\n\tconst dates = useDatetimes();\n\n\tconst onSubmit = useCallback(\n\t\tasync (fields) => {\n\t\t\t// wait the next event cycle to fire up isLoading for submit button\n\t\t\tawait wait();\n\n\t\t\t// whether date capacity has been changed\n\t\t\tlet capacityChanged = false;\n\t\t\tlet id = entityId;\n\n\t\t\tonClose();\n\t\t\t// If it's an existing entity\n\t\t\tif (entityId) {\n\t\t\t\t// Update it\n\t\t\t\tawait updateEntity(fields);\n\n\t\t\t\tcapacityChanged = fields?.capacity !== datetime?.capacity;\n\t\t\t} else {\n\t\t\t\t// we need to set the order to be higher than those of all the existing ones\n\t\t\t\tconst order = fields.order || getHighestOrder(dates) + 1;\n\t\t\t\t// otherwise create it\n\t\t\t\tconst result = await createEntity({ ...fields, order });\n\n\t\t\t\t// Get the ID.\n\t\t\t\tid = result?.data?.createEspressoDatetime?.espressoDatetime?.id;\n\n\t\t\t\t// For new dates, capacity matters only if it's finite.\n\t\t\t\tcapacityChanged = !isInfinite(fields?.capacity);\n\t\t\t}\n\t\t\t// if true, we need to update the quantity of all the related tickets\n\t\t\tif (capacityChanged && id) {\n\t\t\t\tconst input = createBulkQtyUpdateInput(fields, fields?.tickets);\n\t\t\t\tawait doQtyBulkUpdate(input);\n\t\t\t}\n\t\t},\n\t\t[createBulkQtyUpdateInput, createEntity, dates, datetime, doQtyBulkUpdate, entityId, onClose, updateEntity]\n\t);\n\n\treturn onSubmit;\n};\n\nexport default useOnSubmit;\n","import { useCallback } from 'react';\n\nimport { EdtrGlobalModals } from '@eventespresso/edtr-services';\nimport { useGlobalModal } from '@eventespresso/registry';\n\nimport Content from './Content';\nimport { EntityEditModalData } from '@edtrUI/types';\nimport useOnSubmit from './useOnSubmit';\n\nconst Container: React.FC = () => {\n\tconst {\n\t\tgetData,\n\t\tisOpen,\n\t\tclose: closeEditDateModal,\n\t\tsetData,\n\t} = useGlobalModal(EdtrGlobalModals.EDIT_DATE);\n\tconst { close: closeNewDateModal } = useGlobalModal(EdtrGlobalModals.NEW_DATE);\n\n\tconst onClose = useCallback(() => {\n\t\tcloseEditDateModal();\n\t\tcloseNewDateModal();\n\t\t// reset the global modal data\n\t\tsetData({ entityId: null });\n\t}, [closeEditDateModal, closeNewDateModal, setData]);\n\n\tconst { entityId } = getData();\n\n\tconst onSubmit = useOnSubmit(entityId, onClose);\n\n\treturn isOpen && ;\n};\n\nexport default Container;\n","import { useCallback, useMemo } from 'react';\nimport * as R from 'ramda';\n\nimport { isTrashed } from '@eventespresso/predicates';\nimport { useDatetimeItem, useDatetimeMutator, useDeleteRelatedTickets, useEventId } from '@eventespresso/edtr-services';\nimport { useRelations } from '@eventespresso/services';\nimport type { EntityId } from '@eventespresso/data';\n\ntype Actions = {\n\tcopyDate: VoidFunction;\n\ttrashDate: VoidFunction;\n\tisTrashed: boolean;\n};\n\nconst useActions = (datetimeId: EntityId): Actions => {\n\t// Make sure to subscribe to Apollo cache\n\t// to avoid stale data\n\tconst datetime = useDatetimeItem({ id: datetimeId });\n\n\tconst eventId = useEventId();\n\n\tconst { createEntity, deleteEntity } = useDatetimeMutator(datetimeId);\n\n\tconst { getRelations } = useRelations();\n\n\tconst tickets = getRelations({\n\t\tentity: 'datetimes',\n\t\tentityId: datetimeId,\n\t\trelation: 'tickets',\n\t});\n\n\tconst copyDate = useCallback(() => {\n\t\tconst newDatetime = R.pick(\n\t\t\t['capacity', 'description', 'endDate', 'isPrimary', 'name', 'order', 'startDate'],\n\t\t\tdatetime\n\t\t);\n\t\treturn createEntity({ ...newDatetime, eventId, tickets });\n\t}, [createEntity, datetime, eventId, tickets]);\n\n\tconst trashed = isTrashed(datetime);\n\n\tconst deleteRelatedTickets = useDeleteRelatedTickets();\n\n\tconst trashDate = useCallback(async () => {\n\t\tawait deleteEntity({ id: datetimeId, deletePermanently: trashed });\n\t\tawait deleteRelatedTickets(datetimeId, trashed);\n\t}, [deleteEntity, deleteRelatedTickets, datetimeId, trashed]);\n\n\treturn useMemo(\n\t\t() => ({\n\t\t\tcopyDate,\n\t\t\ttrashDate,\n\t\t\tisTrashed: trashed,\n\t\t}),\n\t\t[copyDate, trashDate, trashed]\n\t);\n};\n\nexport default useActions;\n","import { __ } from '@eventespresso/i18n';\nimport { AlertType, TrashEntity, useConfirmationDialog } from '@eventespresso/ui-components';\nimport { Trash as TrashIcon } from '@eventespresso/icons';\nimport { useDatesListFilterState } from '@eventespresso/edtr-services';\nimport useActions from './useActions';\nimport type { Datetime } from '@eventespresso/edtr-services';\n\nexport interface DeleteDatetimeProps {\n\tdatetime: Datetime;\n}\n\nexport const DeleteDatetime: React.FC = ({ datetime }) => {\n\tconst { trashDate, isTrashed } = useActions(datetime.id);\n\tconst isTheOnlyDate = useDatesListFilterState().total === 1;\n\tconst trashDateTitle = isTrashed ? __('delete permanently') : __('trash datetime');\n\tconst cannotBeDeleted = isTrashed && isTheOnlyDate;\n\n\tconst title = isTrashed ? __('Permanently Delete Datetime?') : __('Move Datetime to Trash?');\n\tconst message = isTrashed\n\t\t? __(\n\t\t\t\t'Are you sure you want to permanently delete this datetime? This action is permanent and can not be undone.'\n\t\t )\n\t\t: __(\n\t\t\t\t'Are you sure you want to move this datetime to the trash? You can \"untrash\" this datetime later if you need to.'\n\t\t );\n\tconst { confirmationDialog, onOpen } = useConfirmationDialog({\n\t\taddIconBG: true,\n\t\talertType: AlertType.ACCENT,\n\t\ticon: TrashIcon,\n\t\tmessage,\n\t\ttitle,\n\t\tonConfirm: trashDate,\n\t\tyesButtonText: __('delete'),\n\t});\n\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t{confirmationDialog}\n\t\t\n\t);\n};\n","import { useCallback, useMemo } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { CopyEntity, DropdownMenu, DropdownToggleProps, EditEntity } from '@eventespresso/ui-components';\nimport { EdtrGlobalModals } from '@eventespresso/edtr-services';\nimport { useGlobalModal } from '@eventespresso/registry';\nimport type { EntityEditModalData } from '@edtrUI/types';\n\nimport { DeleteDatetime } from './DeleteDatetime';\nimport useActions from './useActions';\nimport type { DateMainMenuProps } from './types';\n\nconst DateMainMenu: React.FC = ({ datetime }) => {\n\tconst { copyDate } = useActions(datetime.id);\n\tconst { openWithData } = useGlobalModal(EdtrGlobalModals.EDIT_DATE);\n\n\tconst toggleProps: DropdownToggleProps = useMemo(\n\t\t() => ({\n\t\t\tclassName: 'ee-date-main-menu',\n\t\t\t'data-testid': `ee-datetime-main-menu-${datetime.dbId}`,\n\t\t\ttooltip: __('event datetime main menu'),\n\t\t}),\n\t\t[datetime.dbId]\n\t);\n\n\tconst onOpenEditModal = useCallback(() => {\n\t\topenWithData({ entityId: datetime.id });\n\t}, [datetime.id, openWithData]);\n\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default DateMainMenu;\n","import { useCallback } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { EdtrGlobalModals, useRelatedTickets } from '@eventespresso/edtr-services';\nimport { IconButton, ItemCount } from '@eventespresso/ui-components';\nimport { Ticket } from '@eventespresso/icons';\nimport { TypeName, withIsLoaded } from '@eventespresso/services';\nimport { useGlobalModal } from '@eventespresso/registry';\nimport type { BaseProps } from '@edtrUI/ticketAssignmentsManager';\n\nimport type { Datetime } from '@eventespresso/edtr-services';\nimport type { EntityListItemProps } from '@eventespresso/ui-components';\n\nconst AssignTicketsButton: React.FC> = ({ entity }) => {\n\tconst { openWithData } = useGlobalModal(EdtrGlobalModals.TAM);\n\n\tconst getRelatedTickets = useRelatedTickets();\n\n\tconst count = getRelatedTickets({\n\t\tentity: 'datetimes',\n\t\tentityId: entity.id,\n\t}).length;\n\n\tconst title = count\n\t\t? __('Number of related tickets')\n\t\t: __('There are no tickets assigned to this datetime. Please click the ticket icon to update the assignments.');\n\n\tconst onOpen = useCallback(() => {\n\t\topenWithData({ entity, assignmentType: 'forDate' });\n\t}, [entity, openWithData]);\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withIsLoaded>(TypeName.tickets, ({ entity, loaded }) => {\n\t/* Hide TAM unless tickets are loaded */\n\treturn loaded && ;\n});\n","/**\n * This file registers the UI elements related to datetime UI via registry package\n */\nimport {\n\tEntityActionsSubscription,\n\tEntityActionsSubscriptionCb,\n\tModalSubscription,\n\tFilterBarUISubscription,\n\tFilterBarUISubscriptionCb,\n} from '@eventespresso/registry';\nimport {\n\tdomain,\n\tEdtrGlobalModals,\n\tDatetime,\n\tDatetimesFilterStateManager,\n\tdatesList,\n\tNewDateOption,\n} from '@eventespresso/edtr-services';\nimport { EdtrSlots } from '@eventespresso/services';\nimport { FilterBarFilter } from '@eventespresso/ui-components';\nimport { registerPlugin } from '@eventespresso/plugins';\n\nimport {\n\tDisplayStartOrEndDateControl,\n\tSalesControl,\n\tSortByControl,\n\tStatusControl,\n} from '@edtrUI/datetimes/datesList/filterBar/controls';\nimport { NewDateModal, AddSingleDate } from '@edtrUI/datetimes/datesList/newDateOptions';\nimport { Container as EditDateContainer } from '@edtrUI/datetimes/dateForm/multiStep';\nimport { DateMainMenu } from '@edtrUI/datetimes/datesList/actionsMenu/dropdown';\nimport AssignTicketsButton from '@edtrUI/datetimes/datesList/actionsMenu/AssignTicketsButton';\n\n// Register date modal containers\nconst modals = new ModalSubscription(domain);\nmodals.subscribe(({ registry: { registerContainer } }) => {\n\t// Register new date popover\n\tregisterContainer(EdtrGlobalModals.NEW_DATE, NewDateModal);\n\t// Register edit date modal\n\tregisterContainer(EdtrGlobalModals.EDIT_DATE, EditDateContainer);\n});\n\n// Register datetime actions menu items.\nconst entityActions = new EntityActionsSubscription(domain);\nconst datesActionHandler: EntityActionsSubscriptionCb = ({ entityType, entity, registry }) => {\n\t// although this is not needed\n\tif (entityType !== 'datetime') {\n\t\treturn;\n\t}\n\n\tconst { registerElement: registerMenuItem } = registry;\n\n\tregisterMenuItem('dateMainMenu', () => );\n\n\tregisterMenuItem('assignTickets', () => );\n};\n\nentityActions.subscribe(datesActionHandler, { entityType: 'datetime' });\n\n// Register datetime filterbar elements\nconst filterBar = new FilterBarUISubscription(domain);\ntype DatesListFilterBarCallback = FilterBarUISubscriptionCb;\nconst datesListFilterBar: DatesListFilterBarCallback = ({ listId, registry }) => {\n\t// although this is not needed\n\tif (listId !== datesList) {\n\t\treturn;\n\t}\n\n\tconst { registerElement: registerFilterBarItem } = registry;\n\n\tregisterFilterBarItem('status', () => {\n\t\treturn (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t);\n\t});\n\n\tregisterFilterBarItem('sales', () => {\n\t\treturn (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t);\n\t});\n\n\tregisterFilterBarItem('displayStartOrEndDate', () => {\n\t\treturn (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t);\n\t});\n\n\tregisterFilterBarItem('sortBy', () => {\n\t\treturn (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t);\n\t});\n};\n\nfilterBar.subscribe(datesListFilterBar, { listId: datesList });\n\nregisterPlugin(EdtrSlots.ADD_SINGLE_DATE_OPTION, {\n\trender: () => (\n\t\t\n\t\t\t{({ count }) => {\n\t\t\t\treturn ;\n\t\t\t}}\n\t\t\n\t),\n});\n","import { useCallback } from 'react';\nimport * as R from 'ramda';\n\nimport { useTicketPrices } from '@eventespresso/edtr-services';\nimport type { EntityId } from '@eventespresso/data';\nimport { useTicketMutator } from '@eventespresso/edtr-services';\nimport { getGuids, entitiesWithGuIdNotInArray } from '@eventespresso/predicates';\nimport { usePriceQueryOptions } from '@eventespresso/edtr-services';\nimport type { PricesList } from '@eventespresso/edtr-services';\nimport { useApolloClient } from '@eventespresso/data';\n\ntype Callback = (deletePermanently?: boolean) => Promise;\n\nconst useDeleteTicketHandler = (id: EntityId): Callback => {\n\tconst { deleteEntity: deleteTicket } = useTicketMutator();\n\tconst getTicketPrices = useTicketPrices();\n\tconst priceQueryOptions = usePriceQueryOptions();\n\tconst client = useApolloClient();\n\n\t/**\n\t * Deletes the related prices from Apollo cache,\n\t * permanent deletion is handled server-side\n\t */\n\tconst deleteRelatedPrices = useCallback(() => {\n\t\t// The prices that are not default or tax prices.\n\t\tconst pricesToDelete = getTicketPrices(id).filter(({ isDefault, isTax }) => !isDefault && !isTax);\n\t\t// if we have nothing to delete\n\t\tif (!pricesToDelete.length) {\n\t\t\treturn;\n\t\t}\n\t\tconst priceIdsToDelete = getGuids(pricesToDelete);\n\t\t// read existing data from Apollo cache\n\t\tconst data = client.readQuery(priceQueryOptions);\n\t\t// filter out the related prices from Apollo cache data\n\t\tconst pricesToRetain = entitiesWithGuIdNotInArray(data?.espressoPrices?.nodes || [], priceIdsToDelete);\n\t\t// avoid the dirty object creation using assocPath\n\t\tconst newData = R.assocPath(['espressoPrices', 'nodes'], pricesToRetain, data);\n\n\t\t// write the data back to cache\n\t\tclient.writeQuery({\n\t\t\t...priceQueryOptions,\n\t\t\tdata: newData,\n\t\t});\n\t}, [client, getTicketPrices, id, priceQueryOptions]);\n\n\treturn useCallback(\n\t\t(deletePermanently) => {\n\t\t\treturn (\n\t\t\t\tdeleteTicket({ id, deletePermanently })\n\t\t\t\t\t// delete prices only if ticket is deleted permanently\n\t\t\t\t\t.then(() => deletePermanently && deleteRelatedPrices())\n\t\t\t\t\t.catch(console.error)\n\t\t\t);\n\t\t},\n\t\t[deleteTicket, id, deleteRelatedPrices]\n\t);\n};\n\nexport default useDeleteTicketHandler;\n","import { useCallback } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { Ticket, useTicketsListFilterState } from '@eventespresso/edtr-services';\nimport { Trash as TrashIcon } from '@eventespresso/icons';\nimport { AlertType, TrashEntity, useConfirmationDialog } from '@eventespresso/ui-components';\nimport { isTrashed as isTicketTrashed, isLocked } from '@eventespresso/predicates';\nimport { useLockedTicketAction } from '@eventespresso/tpc';\n\nimport useDeleteTicketHandler from '@edtrUI/tickets/hooks/useDeleteTicketHandler';\n\nexport interface DeleteTicketProps {\n\tticket: Ticket;\n}\n\nexport const DeleteTicket: React.FC = ({ ticket }) => {\n\tconst isTrashed = isTicketTrashed(ticket);\n\n\tconst title = isTrashed ? __('Permanently Delete Ticket?') : __('Move Ticket to Trash?');\n\n\tconst message = isTrashed\n\t\t? __('Are you sure you want to permanently delete this ticket? This action is permanent and can not be undone.')\n\t\t: __(\n\t\t\t\t`Are you sure you want to move this ticket to the trash? You can \"untrash\" this ticket later if you need to.`\n\t\t );\n\n\tconst deleteTicket = useDeleteTicketHandler(ticket.id);\n\n\tconst onConfirmDelete = useCallback(() => {\n\t\tdeleteTicket(isTrashed);\n\t}, [deleteTicket, isTrashed]);\n\n\tconst { confirmationDialog, onOpen: confirmDelete } = useConfirmationDialog({\n\t\taddIconBG: true,\n\t\talertType: AlertType.ACCENT,\n\t\ticon: TrashIcon,\n\t\tmessage,\n\t\ttitle,\n\t\tonConfirm: onConfirmDelete,\n\t});\n\n\tconst { alertContainer, showAlert } = useLockedTicketAction(ticket);\n\n\tconst isTheOnlyTicket = useTicketsListFilterState().total === 1;\n\n\tconst cannotBeDeleted = isTrashed && isTheOnlyTicket;\n\n\tconst deleteTicketTitle = isTrashed ? __('delete permanently') : __('trash ticket');\n\n\tconst onDelete = isTrashed && isLocked(ticket) ? showAlert : confirmDelete;\n\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t{confirmationDialog}\n\t\t\t{alertContainer}\n\t\t\n\t);\n};\n","import { useCallback, useMemo } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { CopyEntity, DropdownMenu, DropdownToggleProps, EditEntity } from '@eventespresso/ui-components';\nimport { EdtrGlobalModals, useTicketItem } from '@eventespresso/edtr-services';\nimport { useGlobalModal } from '@eventespresso/registry';\nimport { useCopyTicket } from '@eventespresso/tpc';\n\nimport type { TicketMainMenuProps } from './types';\nimport { EntityEditModalData } from '@edtrUI/types';\nimport { DeleteTicket } from './DeleteTicket';\n\nconst TicketMainMenu: React.FC = (props) => {\n\tconst ticketId = props.ticket.id;\n\t// Make sure to subscribe to Apollo cache\n\t// to avoid stale data\n\tconst ticket = useTicketItem({ id: ticketId });\n\n\tconst copyTicket = useCopyTicket(ticket);\n\n\tconst toggleProps: DropdownToggleProps = useMemo(\n\t\t() => ({\n\t\t\tclassName: 'ee-ticket-main-menu',\n\t\t\t'data-testid': `ee-ticket-main-menu-${ticket.dbId}`,\n\t\t\ttooltip: __('ticket main menu'),\n\t\t}),\n\t\t[ticket.dbId]\n\t);\n\n\tconst { openWithData } = useGlobalModal(EdtrGlobalModals.EDIT_TICKET);\n\n\tconst onOpenEditModal = useCallback(() => {\n\t\topenWithData({ entityId: ticketId });\n\t}, [ticketId, openWithData]);\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default TicketMainMenu;\n","import * as yup from 'yup';\n\nimport { datesSchema, TicketFormShape } from '@eventespresso/edtr-services';\nimport { yupToFinalFormErrors } from '@eventespresso/form';\n\nexport const validate = async (values: TicketFormShape): Promise => {\n\treturn await yupToFinalFormErrors(validationSchema, values);\n};\n\nconst validationSchema = yup.object({\n\tname: yup.string(),\n\t...datesSchema,\n});\n","import { useMemo, useCallback } from 'react';\nimport * as R from 'ramda';\n\nimport { __ } from '@eventespresso/i18n';\nimport { CalendarOutlined, ControlOutlined, ProfileOutlined } from '@eventespresso/icons';\nimport { EndDateFieldWrapper } from '@eventespresso/ee-components';\nimport { EntityId } from '@eventespresso/data';\nimport { NOW, PLUS_ONE_MONTH, USE_ADVANCED_EDITOR } from '@eventespresso/constants';\nimport { preparePricesForTpc, usePriceToTpcModifier } from '@eventespresso/tpc';\nimport { setDefaultTime } from '@eventespresso/dates';\nimport { startAndEndDateFixer, useTicketItem, hooks, useTicketPrices } from '@eventespresso/edtr-services';\nimport { useCurrentUserCan } from '@eventespresso/services';\nimport { useMemoStringify } from '@eventespresso/hooks';\nimport { useUtcISOToSiteDate, useSiteDateToUtcISO } from '@eventespresso/services';\nimport { VISIBILITY_OPTIONS, VISIBILITY_OPTIONS_INFO } from '@eventespresso/helpers';\n\nimport type { EspressoFormProps, FieldProps } from '@eventespresso/form';\nimport type { Ticket, TicketFormConfig } from '@eventespresso/edtr-services';\n\nimport { validate } from './formValidation';\n\nexport const FIELD_NAMES: Array = [\n\t'id',\n\t'description',\n\t'isDefault',\n\t'isRequired',\n\t'isTrashed',\n\t'max',\n\t'min',\n\t'name',\n\t'price',\n\t'quantity',\n\t'uses',\n\t'visibility',\n];\n\nconst decorators = [startAndEndDateFixer];\n\nconst adjacentFormItemProps = {\n\tclassName: 'ee-form-item-pair',\n};\n\nexport const useTicketFormConfig = (id: EntityId, config?: EspressoFormProps): TicketFormConfig => {\n\tconst ticket = useTicketItem({ id });\n\tconst currentUserCan = useCurrentUserCan();\n\n\tconst toUtcISO = useSiteDateToUtcISO();\n\tconst toSiteDate = useUtcISOToSiteDate();\n\n\tconst startDate = useMemoStringify(\n\t\tticket?.startDate ? toSiteDate(ticket?.startDate) : setDefaultTime(NOW, 'start')\n\t);\n\tconst endDate = useMemoStringify(\n\t\tticket?.endDate ? toSiteDate(ticket?.endDate) : setDefaultTime(PLUS_ONE_MONTH, 'end')\n\t);\n\n\tconst { onSubmit } = config;\n\n\t//### Submit function for Form Data\n\tconst onSubmitFrom: TicketFormConfig['onSubmit'] = useCallback(\n\t\t({ startDate, endDate, ...values }, form, ...restParams) => {\n\t\t\treturn onSubmit(\n\t\t\t\t{ ...values, startDate: toUtcISO(startDate), endDate: toUtcISO(endDate) },\n\t\t\t\tform,\n\t\t\t\t...restParams\n\t\t\t);\n\t\t},\n\t\t[onSubmit, toUtcISO]\n\t);\n\n\tconst getTicketPrices = useTicketPrices();\n\tconst priceToTpcModifier = usePriceToTpcModifier();\n\n\tconst initialValues = useMemo(() => {\n\t\tconst prices = preparePricesForTpc(getTicketPrices(ticket?.id), priceToTpcModifier);\n\n\t\treturn hooks.applyFilters(\n\t\t\t'eventEditor.ticketForm.initalValues',\n\t\t\t{\n\t\t\t\tvisibility: 'PUBLIC',\n\t\t\t\t...R.pick, 'prices'>, keyof Ticket>(FIELD_NAMES, ticket || {}),\n\t\t\t\t// set initial prices\n\t\t\t\tprices,\n\t\t\t\tstartDate,\n\t\t\t\tendDate,\n\t\t\t},\n\t\t\tticket\n\t\t);\n\t}, [endDate, getTicketPrices, priceToTpcModifier, startDate, ticket]);\n\n\tconst publicFields: Array = useMemo(() => {\n\t\treturn [\n\t\t\t{\n\t\t\t\tname: 'quantity',\n\t\t\t\tlabel: __('Quantity For Sale'),\n\t\t\t\tfieldType: 'number',\n\t\t\t\tparseAsInfinity: true,\n\t\t\t\tmax: 1000000,\n\t\t\t\tmin: -1,\n\t\t\t\tinfo:\n\t\t\t\t\t__('The maximum number of this ticket available for sale.') +\n\t\t\t\t\t'\\n' +\n\t\t\t\t\t__('Set to 0 to stop sales, or leave blank for no limit.'),\n\t\t\t\twidth: 'small',\n\t\t\t\tformControlProps: adjacentFormItemProps,\n\t\t\t},\n\t\t];\n\t}, []);\n\n\tconst advancedFields: Array = useMemo(() => {\n\t\treturn publicFields.concat([\n\t\t\t{\n\t\t\t\tname: 'uses',\n\t\t\t\tlabel: __('Number of Uses'),\n\t\t\t\tfieldType: 'number',\n\t\t\t\tparseAsInfinity: true,\n\t\t\t\tmax: 1000,\n\t\t\t\tmin: 0,\n\t\t\t\tinfo:\n\t\t\t\t\t__(\n\t\t\t\t\t\t'Controls the total number of times this ticket can be used, regardless of the number of dates it is assigned to.'\n\t\t\t\t\t) +\n\t\t\t\t\t'\\n' +\n\t\t\t\t\t__(\n\t\t\t\t\t\t'Example: A ticket might have access to 4 different dates, but setting this field to 2 would mean that the ticket could only be used twice. Leave blank for no limit.'\n\t\t\t\t\t),\n\t\t\t\twidth: 'small',\n\t\t\t\tformControlProps: adjacentFormItemProps,\n\t\t\t},\n\t\t\t{\n\t\t\t\tname: 'min',\n\t\t\t\tlabel: __('Minimum Quantity'),\n\t\t\t\tfieldType: 'number',\n\t\t\t\tmax: 1000000,\n\t\t\t\tmin: 0,\n\t\t\t\tinfo:\n\t\t\t\t\t__(\n\t\t\t\t\t\t'The minimum quantity that can be selected for this ticket. Use this to create ticket bundles or graduated pricing.'\n\t\t\t\t\t) +\n\t\t\t\t\t'\\n' +\n\t\t\t\t\t__('Leave blank for no minimum.'),\n\t\t\t\twidth: 'small',\n\t\t\t\tformControlProps: adjacentFormItemProps,\n\t\t\t},\n\t\t\t{\n\t\t\t\tname: 'max',\n\t\t\t\tlabel: __('Maximum Quantity'),\n\t\t\t\tfieldType: 'number',\n\t\t\t\tparseAsInfinity: true,\n\t\t\t\tmax: 1000000,\n\t\t\t\tmin: -1,\n\t\t\t\tinfo:\n\t\t\t\t\t__(\n\t\t\t\t\t\t'The maximum quantity that can be selected for this ticket. Use this to create ticket bundles or graduated pricing.'\n\t\t\t\t\t) +\n\t\t\t\t\t'\\n' +\n\t\t\t\t\t__('Leave blank for no maximum.'),\n\t\t\t\twidth: 'small',\n\t\t\t\tformControlProps: adjacentFormItemProps,\n\t\t\t},\n\t\t\t{\n\t\t\t\tname: 'isRequired',\n\t\t\t\tlabel: __('Required Ticket'),\n\t\t\t\tfieldType: 'switch',\n\t\t\t\tinfo: __('If enabled, the ticket must be selected and will appear first in ticket lists.'),\n\t\t\t\twidth: 'small',\n\t\t\t\tformControlProps: adjacentFormItemProps,\n\t\t\t},\n\t\t\t{\n\t\t\t\tname: 'isTrashed',\n\t\t\t\tlabel: __('Trash'),\n\t\t\t\tfieldType: 'switch',\n\t\t\t\tformControlProps: adjacentFormItemProps,\n\t\t\t},\n\t\t\t{\n\t\t\t\tname: 'visibility',\n\t\t\t\tlabel: __('Visibility'),\n\t\t\t\tfieldType: 'select',\n\t\t\t\tinfo: VISIBILITY_OPTIONS_INFO,\n\t\t\t\toptions: VISIBILITY_OPTIONS,\n\t\t\t},\n\t\t]);\n\t}, [publicFields]);\n\n\tconst ticketDetailsFields = currentUserCan(USE_ADVANCED_EDITOR) ? advancedFields : publicFields;\n\n\tconst sections = useMemo(() => {\n\t\treturn hooks.applyFilters(\n\t\t\t'eventEditor.ticketForm.sections',\n\t\t\t[\n\t\t\t\t{\n\t\t\t\t\tname: 'basics',\n\t\t\t\t\ticon: ProfileOutlined,\n\t\t\t\t\ttitle: __('Basics'),\n\t\t\t\t\tfields: [\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tname: 'name',\n\t\t\t\t\t\t\tlabel: __('Name'),\n\t\t\t\t\t\t\tfieldType: 'text',\n\t\t\t\t\t\t},\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tname: 'description',\n\t\t\t\t\t\t\tlabel: __('Description'),\n\t\t\t\t\t\t\tfieldType: 'simple-text-editor',\n\t\t\t\t\t\t},\n\t\t\t\t\t],\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\tname: 'sales',\n\t\t\t\t\ticon: CalendarOutlined,\n\t\t\t\t\ttitle: __('Ticket Sales'),\n\t\t\t\t\tfields: [\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tname: 'startDate',\n\t\t\t\t\t\t\tlabel: __('Start Date'),\n\t\t\t\t\t\t\tfieldType: 'datetimepicker',\n\t\t\t\t\t\t\trequired: true,\n\t\t\t\t\t\t\tformControlProps: adjacentFormItemProps,\n\t\t\t\t\t\t},\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tname: 'endDate',\n\t\t\t\t\t\t\tlabel: __('End Date'),\n\t\t\t\t\t\t\tfieldType: 'datetimepicker',\n\t\t\t\t\t\t\trequired: true,\n\t\t\t\t\t\t\twrapper: EndDateFieldWrapper,\n\t\t\t\t\t\t\tformControlProps: adjacentFormItemProps,\n\t\t\t\t\t\t},\n\t\t\t\t\t],\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\tname: 'details',\n\t\t\t\t\ticon: ControlOutlined,\n\t\t\t\t\ttitle: __('Details'),\n\t\t\t\t\tfields: ticketDetailsFields,\n\t\t\t\t},\n\t\t\t],\n\t\t\tticket\n\t\t);\n\t}, [ticket, ticketDetailsFields]);\n\n\treturn useMemo(\n\t\t() => ({\n\t\t\t...config,\n\t\t\tonSubmit: onSubmitFrom,\n\t\t\tdecorators,\n\t\t\tsubscription: {},\n\t\t\tinitialValues,\n\t\t\tvalidate,\n\t\t\tsections,\n\t\t}),\n\t\t[config, initialValues, onSubmitFrom, sections]\n\t);\n};\n\nexport default useTicketFormConfig;\n","import { __ } from '@eventespresso/i18n';\n\nimport { Calculator, Calendar, Ticket } from '@eventespresso/icons';\nimport { Steps, Step } from '@eventespresso/ui-components';\nimport { PrevNext } from '@eventespresso/hooks';\n\nconst TicketFormSteps: React.FC> = ({ current }) => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default TicketFormSteps;\n","import { TicketPriceCalculator, useSyncTPC2RFF } from '@eventespresso/tpc';\n\nconst TPCStep = () => {\n\tuseSyncTPC2RFF();\n\n\treturn ;\n};\n\nexport default TPCStep;\n","import { useEffect } from 'react';\n\nimport { useForm } from '@eventespresso/form';\nimport { useDataState as useTAMDataState } from '@edtrUI/ticketAssignmentsManager/data';\n\n/**\n * A custom hook which subscribes to TAM and TPC data and updates\n * RFF data when needed.\n */\nconst useDataListener: VoidFunction = () => {\n\tconst { getData } = useTAMDataState();\n\tconst { mutators, getState } = useForm();\n\tconst data = getData();\n\n\tconst id = getState().values.id || 'NEW_TICKET';\n\tuseEffect(() => {\n\t\t// update value of `datetimes` field in RFF state\n\t\tmutators.updateFieldValue('datetimes', data?.tickets?.[id]?.datetimes);\n\t}, [data, id, mutators]);\n};\n\nexport default useDataListener;\n","import { TicketAssignmentsManager } from '@edtrUI/ticketAssignmentsManager/components';\nimport useDataListener from './useDataListener';\n\nconst TAMStep = () => {\n\tuseDataListener();\n\n\treturn ;\n};\n\nexport default TAMStep;\n","import TicketFormSteps from './TicketFormSteps';\nimport { ModalBodyProps } from './types';\nimport { ASSIGN_DATES_STEP, TICKET_DETAILS_STEP, TICKET_PRICES_STEP } from './constants';\nimport TPCStep from './TPCStep';\nimport TAMStep from './TAMStep';\n\nconst ModalBody: React.FC = ({ children: body, steps }) => {\n\t// init data listener to update RFF data\n\n\treturn (\n\t\t
\n\t\t\t\n\t\t\t{/* RFF fields */}\n\t\t\t{steps.current === TICKET_DETAILS_STEP && body}\n\t\t\t{steps.current === TICKET_PRICES_STEP && }\n\t\t\t{steps.current === ASSIGN_DATES_STEP && }\n\t\t
\n\t);\n};\n\nexport default ModalBody;\n","export const TICKET_DETAILS_STEP = 0;\n\nexport const TICKET_PRICES_STEP = 1;\n\nexport const ASSIGN_DATES_STEP = 2;\n","import { useCallback } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { ButtonRow, ButtonType, Next, Previous, Submit } from '@eventespresso/ui-components';\nimport { withFormSubscription, FormSubscriptionProps } from '@eventespresso/ee-components';\nimport { hasEmptyPrices } from '@eventespresso/predicates';\nimport type { PrevNext } from '@eventespresso/hooks';\n\nimport { useDataState as useTAMDataState } from '@edtrUI/ticketAssignmentsManager/data';\nimport { ASSIGN_DATES_STEP, TICKET_DETAILS_STEP, TICKET_PRICES_STEP } from './constants';\n\ninterface FooterButtonsProps extends FormSubscriptionProps {\n\tsteps: PrevNext;\n}\n\nconst FooterButtons: React.FC = ({ form, hasErrors, steps, submitting }) => {\n\tconst { current, goto, prev, next } = steps;\n\tconst { hasOrphanEntities } = useTAMDataState();\n\tconst isSubmitDisabled = hasOrphanEntities();\n\n\tconst gotoDetails = useCallback(() => goto(TICKET_DETAILS_STEP), [goto]);\n\tconst gotoTAM = useCallback(() => goto(ASSIGN_DATES_STEP), [goto]);\n\n\tconst { values } = form.getState();\n\n\tconst isTPCSubmitDisabled = hasEmptyPrices(values?.prices || []);\n\n\treturn (\n\t\t\n\t\t\t{current === TICKET_DETAILS_STEP && (\n\t\t\t\t<>\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t)}\n\n\t\t\t{current === TICKET_PRICES_STEP && (\n\t\t\t\t<>\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t)}\n\n\t\t\t{current === ASSIGN_DATES_STEP && (\n\t\t\t\t<>\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t)}\n\t\t\n\t);\n};\n\nexport default withFormSubscription(FooterButtons);\n","import { useMemo } from 'react';\n\nimport { EntityEditModal } from '@eventespresso/ee-components';\nimport { EdtrGlobalModals, useEvent, useTicketItem } from '@eventespresso/edtr-services';\nimport { useGlobalModal } from '@eventespresso/registry';\nimport { __, sprintf } from '@eventespresso/i18n';\nimport { usePrevNext } from '@eventespresso/hooks';\nimport { useIsPristine } from '@eventespresso/form';\nimport type { ModalProps } from '@eventespresso/adapters';\n\nimport ModalBody from './ModalBody';\nimport type { ContentWrapperProps } from './types';\nimport type { EntityEditModalData } from '@edtrUI/types';\nimport FooterButtons from './FooterButtons';\n\nconst Modal: React.FC = ({ onClose, ...props }) => {\n\tconst { isOpen } = useGlobalModal(EdtrGlobalModals.EDIT_TICKET);\n\tconst event = useEvent();\n\tconst steps = usePrevNext();\n\tconst isPristine = useIsPristine();\n\n\tconst { values } = props.form.getState();\n\n\tconst ticket = useTicketItem({ id: values?.id });\n\n\tlet title = ticket?.dbId\n\t\t? sprintf(\n\t\t\t\t/* translators: %1$s ticket name, %2$s ticket id */\n\t\t\t\t__('Edit ticket \"%1$s\" - %2$s'),\n\t\t\t\tticket.name,\n\t\t\t\t`#${ticket.dbId}`\n\t\t )\n\t\t: __('New Ticket Details');\n\n\t// add event name to the title\n\ttitle = event?.name ? `${event.name}: ${title}` : title;\n\n\tconst footerButtons = ;\n\n\tconst ariaAttributes: ModalProps['ariaAttributes'] = useMemo(() => {\n\t\tconst getAriaLabel = (): string => {\n\t\t\tif (!ticket || !ticket.name) {\n\t\t\t\treturn __('modal for ticket');\n\t\t\t}\n\t\t\t/* translators: %s ticket name */\n\t\t\treturn sprintf('modal for ticket %s', ticket.name);\n\t\t};\n\t\treturn {\n\t\t\tmodalContent: { 'aria-label': getAriaLabel() },\n\t\t};\n\t}, [ticket]);\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default Modal;\n","import { useCallback } from 'react';\n\nimport { useFormValues } from '@eventespresso/form';\nimport { Ticket, TicketFormShape, useTicketItem, useTicketPrices } from '@eventespresso/edtr-services';\nimport { useMemoStringify } from '@eventespresso/hooks';\nimport { ContextProvider as TPCContextProvider, usePriceToTpcModifier, preparePricesForTpc } from '@eventespresso/tpc';\n\nimport { ContextProvider as TAMContextProvider } from '@edtrUI/ticketAssignmentsManager/context';\nimport Modal from './Modal';\n\nimport type { ContentWrapperProps } from './types';\n\nconst ContextProvider: React.FC = (props) => {\n\tconst { values: initialValues } = props.form.getState();\n\tconst values = useFormValues(initialValues);\n\n\tconst ticket = useTicketItem({ id: values?.id });\n\tconst priceToTpcModifier = usePriceToTpcModifier();\n\tconst getTheTicketPrices = useTicketPrices();\n\n\t// add defaults from Apollo cache and override the set values from form state\n\tconst entity = useMemoStringify({ id: 'NEW_TICKET', dbId: 0, ...ticket, ...values } as Ticket);\n\n\tconst getTicket = useCallback(() => entity, [entity]);\n\n\tconst getTicketPrices = useCallback(\n\t\t(ticketId: string) => {\n\t\t\t// we have prices in the form values, it means they have been added, lets use those\n\t\t\tconst prices = values?.prices || preparePricesForTpc(getTheTicketPrices(ticketId), priceToTpcModifier);\n\n\t\t\treturn prices;\n\t\t},\n\t\t[priceToTpcModifier, getTheTicketPrices, values?.prices]\n\t);\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default ContextProvider;\n","import { useMemo } from 'react';\n\nimport { FormWithConfig } from '@eventespresso/ee-components';\n\nimport useTicketFormConfig from '../useTicketFormConfig';\nimport ContextProvider from './ContextProvider';\nimport type { ContentProps } from './types';\n\nconst Content: React.FC = ({ entityId, onClose, onSubmit }) => {\n\tconst config = useMemo(() => ({ onSubmit }), [onSubmit]);\n\tconst formConfig = useTicketFormConfig(entityId, config);\n\n\treturn ;\n};\n\nexport default Content;\n","import { useCallback } from 'react';\n\nimport { useMutateTicket } from '@eventespresso/tpc';\nimport { wait } from '@eventespresso/utils';\n\nimport { useCappedQuantity } from '@eventespresso/edtr-services';\nimport { OnSubmit } from './types';\n\nconst useOnSubmit = (onClose: VoidFunction): OnSubmit => {\n\tconst mutateTicket = useMutateTicket();\n\n\tconst getCappedQuantity = useCappedQuantity();\n\tconst onSubmit = useCallback(\n\t\tasync (fields) => {\n\t\t\t// wait the next event cycle to fire up isLoading for submit button\n\t\t\tawait wait();\n\t\t\t// close the modal\n\t\t\tonClose();\n\t\t\t// get the capped quantity for ticket based on the related date(s)\n\t\t\tconst quantity = getCappedQuantity({ quantity: fields.quantity, relatedDateIds: fields.datetimes });\n\n\t\t\tconst input = {\n\t\t\t\t...fields,\n\t\t\t\tisModified: Boolean(fields.id), // should be updated if there is an id\n\t\t\t\tisNew: !fields.id, // it's new if id is empty\n\t\t\t\tquantity,\n\t\t\t};\n\n\t\t\tawait mutateTicket(input);\n\t\t},\n\t\t[getCappedQuantity, mutateTicket, onClose]\n\t);\n\n\treturn onSubmit;\n};\n\nexport default useOnSubmit;\n","import { useCallback } from 'react';\n\nimport { EdtrGlobalModals } from '@eventespresso/edtr-services';\nimport { useGlobalModal } from '@eventespresso/registry';\n\nimport Content from './Content';\nimport { EntityEditModalData } from '@edtrUI/types';\nimport useOnSubmit from './useOnSubmit';\n\nconst Container: React.FC = () => {\n\tconst {\n\t\tgetData,\n\t\tisOpen,\n\t\tclose: closeModal,\n\t\tsetData,\n\t} = useGlobalModal(EdtrGlobalModals.EDIT_TICKET);\n\n\tconst onClose = useCallback(() => {\n\t\tcloseModal();\n\t\t// reset the global modal data\n\t\tsetData({ entityId: null });\n\t}, [closeModal, setData]);\n\n\tconst { entityId } = getData();\n\n\tconst onSubmit = useOnSubmit(onClose);\n\n\treturn isOpen && ;\n};\n\nexport default Container;\n","import { useCallback, useMemo } from 'react';\n\nimport { SimpleTicketCard } from '@eventespresso/ee-components';\nimport { SimpleEntityRendererProps } from '@eventespresso/ui-components';\nimport { LOCALIZED_DATE_AND_TIME_SHORT_FORMAT } from '@eventespresso/constants';\nimport { useTimeZoneTime, useCurrentUserCan } from '@eventespresso/services';\nimport { DefaultTicket } from './data';\n\nconst TicketCard: React.FC> = ({ entity: ticket, onEdit, onDelete }) => {\n\tconst { formatForSite } = useTimeZoneTime();\n\tconst currentUserCan = useCurrentUserCan();\n\n\tconst renderStartDate = useCallback(\n\t\t({ startDate }) => {\n\t\t\treturn formatForSite(startDate, LOCALIZED_DATE_AND_TIME_SHORT_FORMAT);\n\t\t},\n\t\t[formatForSite]\n\t);\n\n\tconst renderEndDate = useCallback(\n\t\t({ endDate }) => {\n\t\t\treturn formatForSite(endDate, LOCALIZED_DATE_AND_TIME_SHORT_FORMAT);\n\t\t},\n\t\t[formatForSite]\n\t);\n\n\tconst showAfterDetails = Boolean(ticket.startDate && ticket.endDate);\n\n\tconst deleteButtonProps = useMemo(() => {\n\t\treturn { isDisabled: !currentUserCan('delete', 'default_ticket', ticket) };\n\t}, [currentUserCan, ticket]);\n\n\tconst editButtonProps = useMemo(() => {\n\t\treturn { isDisabled: !currentUserCan('edit', 'default_ticket', ticket) };\n\t}, [currentUserCan, ticket]);\n\n\treturn (\n\t\t\n\t);\n};\n\nexport default TicketCard;\n","import { useMemo } from 'react';\nimport * as R from 'ramda';\n\nimport type { EspressoFormProps } from '@eventespresso/form';\nimport { Ticket, TicketFormConfig } from '@eventespresso/edtr-services';\nimport useMainTicketFormConfig, { FIELD_NAMES } from '../../ticketForm/useTicketFormConfig';\nimport { DefaultTicket } from '../data';\n\nconst useTicketFormConfig = (ticket?: DefaultTicket, config?: EspressoFormProps): TicketFormConfig => {\n\tconst newConfig = useMainTicketFormConfig(ticket?.id, config);\n\n\treturn useMemo(\n\t\t() => ({\n\t\t\t...newConfig,\n\t\t\tinitialValues: {\n\t\t\t\t...newConfig?.initialValues,\n\t\t\t\t...R.pick, 'prices'>, keyof Ticket>(FIELD_NAMES, ticket || {}),\n\t\t\t},\n\t\t}),\n\t\t[newConfig, ticket]\n\t);\n};\n\nexport default useTicketFormConfig;\n","import { __ } from '@eventespresso/i18n';\n\nimport { Steps, Step } from '@eventespresso/ui-components';\nimport { PrevNext } from '@eventespresso/hooks';\nimport { Calculator, Calendar, Ticket } from '@eventespresso/icons';\n\nconst TicketFormSteps: React.FC> = ({ current }) => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default TicketFormSteps;\n","import { TicketPriceCalculator, useSyncTPC2RFF } from '@eventespresso/tpc';\n\nconst TPCStep = () => {\n\tuseSyncTPC2RFF();\n\n\treturn ;\n};\n\nexport default TPCStep;\n","import TicketFormSteps from './TicketFormSteps';\nimport { ModalBodyProps } from './types';\nimport { TICKET_DETAILS_STEP, TICKET_PRICES_STEP } from '../../ticketForm/multiStep/constants';\nimport TPCStep from './TPCStep';\n\n/**\n * This component is inside both RFF and TAM contexts, so we can use all of their features\n */\nconst ModalBody: React.FC = ({ children: body, steps }) => {\n\treturn (\n\t\t
\n\t\t\t\n\t\t\t{/* RFF fields */}\n\t\t\t{steps.current === TICKET_DETAILS_STEP && body}\n\n\t\t\t{steps.current === TICKET_PRICES_STEP && }\n\t\t
\n\t);\n};\n\nexport default ModalBody;\n","import { __ } from '@eventespresso/i18n';\nimport { ButtonRow, ButtonType, Next, Previous, Submit } from '@eventespresso/ui-components';\nimport { withFormSubscription, FormSubscriptionProps } from '@eventespresso/ee-components';\nimport { hasEmptyPrices } from '@eventespresso/predicates';\nimport type { PrevNext } from '@eventespresso/hooks';\n\nimport { TICKET_DETAILS_STEP, TICKET_PRICES_STEP } from '../../ticketForm/multiStep/constants';\n\ninterface FooterButtonsProps extends FormSubscriptionProps {\n\tsteps: PrevNext;\n}\n\nconst FooterButtons: React.FC = ({ form, hasErrors, steps }) => {\n\tconst { current, prev, next } = steps;\n\n\tconst { values } = form.getState();\n\n\tconst isTPCSubmitDisabled = hasEmptyPrices(values?.prices || []);\n\n\treturn (\n\t\t\n\t\t\t{/* RFF fields */}\n\t\t\t{current === TICKET_DETAILS_STEP && (\n\t\t\t\t<>\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t)}\n\n\t\t\t{current === TICKET_PRICES_STEP && (\n\t\t\t\t<>\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t)}\n\t\t\n\t);\n};\n\nexport default withFormSubscription(FooterButtons);\n","import { EntityEditModal } from '@eventespresso/ui-components';\nimport { __, sprintf } from '@eventespresso/i18n';\nimport { usePrevNext } from '@eventespresso/hooks';\nimport { useIsPristine } from '@eventespresso/form';\n\nimport ModalBody from './ModalBody';\n\nimport type { ContextProviderProps } from './types';\nimport FooterButtons from './FooterButtons';\nimport { useDataState } from '../data';\n\nconst Modal: React.FC = ({ onClose, ...props }) => {\n\tconst steps = usePrevNext();\n\tconst isPristine = useIsPristine();\n\tconst { tickets } = useDataState();\n\n\tconst ticketId = props.form.getState().values?.id;\n\n\tconst title = tickets[ticketId]?.dbId\n\t\t? sprintf(\n\t\t\t\t/* translators: %s ticket id */\n\t\t\t\t__('Edit ticket %s'),\n\t\t\t\t`#${tickets[ticketId].dbId}`\n\t\t )\n\t\t: __('New Ticket Details');\n\n\tconst footerButtons = ;\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default Modal;\n","import { useCallback } from 'react';\n\nimport { withContext as withTPCContext } from '@eventespresso/tpc';\n\nimport type { ContextProviderProps } from './types';\nimport Modal from './Modal';\nimport { useDataState } from '../data';\n\nconst ContextProvider: React.FC = (props) => {\n\tconst { tickets } = useDataState();\n\tconst { values } = props.form.getState();\n\n\tconst getTicket = useCallback((id) => tickets[id], [tickets]);\n\n\tconst getTicketPrices = useCallback((id) => tickets[id]?.prices || [], [tickets]);\n\n\tconst Component = withTPCContext(Modal, {\n\t\tticketId: values.id,\n\t\tgetTicketPrices,\n\t\tgetTicket,\n\t});\n\n\treturn ;\n};\n\nexport default ContextProvider;\n","import { useCallback } from 'react';\n\nimport { FormWithConfig } from '@eventespresso/ee-components';\n\nimport useTicketFormConfig from './useTicketFormConfig';\nimport ContextProvider from './ContextProvider';\nimport type { ContentRendererProps } from './types';\nimport { useDataState } from '../data';\n\nconst ContentRenderer: React.FC = ({ entity, onClose }) => {\n\tconst { addTicket, updateTicket } = useDataState();\n\n\tconst onSubmit = useCallback(\n\t\t(values) => {\n\t\t\tif (entity?.id) {\n\t\t\t\tupdateTicket(entity?.id, values);\n\t\t\t} else {\n\t\t\t\taddTicket({ ...values, isNew: true });\n\t\t\t}\n\t\t\tonClose();\n\t\t},\n\t\t[addTicket, entity?.id, onClose, updateTicket]\n\t);\n\tconst formConfig = useTicketFormConfig(entity, { onSubmit });\n\n\treturn ;\n};\n\nexport default ContentRenderer;\n","import { useCallback, useEffect, useMemo } from 'react';\n\nimport { SimpleEntityList, DebugInfo } from '@eventespresso/ui-components';\nimport { useTickets, useTicketPrices } from '@eventespresso/edtr-services';\nimport { usePrepTemplatePrices } from '@eventespresso/tpc';\nimport { __ } from '@eventespresso/i18n';\n\nimport { DefaultTicket, useDataState } from './data';\nimport TicketCard from './TicketCard';\nimport { ContentRenderer } from './multiStep';\n\nimport './styles.scss';\n\nconst ModalBody: React.FC = () => {\n\tconst { addTicket, tickets, deleteTicket, reset, getData } = useDataState();\n\tconst templates = useTickets();\n\tconst getTicketPrices = useTicketPrices();\n\tconst prepTemplatePrices = usePrepTemplatePrices();\n\n\tconst deleteEntity = useCallback(\n\t\t(ticket: DefaultTicket) => {\n\t\t\tdeleteTicket(ticket.id, ticket.isNew);\n\t\t},\n\t\t[deleteTicket]\n\t);\n\n\tconst entities = useMemo(() => Object.values(tickets), [tickets]);\n\n\tconst addEntity = useCallback(\n\t\t(entity) => {\n\t\t\tconst ticketPrices = getTicketPrices(entity.id);\n\t\t\tconst prices = prepTemplatePrices(ticketPrices);\n\t\t\taddTicket({\n\t\t\t\t...entity,\n\t\t\t\tisNew: true,\n\t\t\t\tdbId: 0,\n\t\t\t\tprices,\n\t\t\t\t/**\n\t\t\t\t * Ensure that ticket is not trashed,\n\t\t\t\t * as it's possible that a trashed ticket is used as a template\n\t\t\t\t *\n\t\t\t\t * @see https://github.com/eventespresso/barista/issues/1013\n\t\t\t\t */\n\t\t\t\tisTrashed: false,\n\t\t\t});\n\t\t},\n\t\t[addTicket, getTicketPrices, prepTemplatePrices]\n\t);\n\n\t// reset state on mount\n\tuseEffect(() => {\n\t\treset();\n\t\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\t}, []);\n\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default ModalBody;\n","import { useCallback } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\nimport { useGlobalModal } from '@eventespresso/registry';\nimport { EdtrGlobalModals } from '@eventespresso/edtr-services';\nimport { wait } from '@eventespresso/utils';\nimport { ModalWithAlert } from '@eventespresso/ui-components';\n\nimport { withContext } from './context';\nimport { useDataState, useSubmitForm } from './data';\nimport ModalBody from './ModalBody';\n\nconst Container: React.FC = () => {\n\tconst { close: closeModal, isOpen } = useGlobalModal(EdtrGlobalModals.DEFAULT_TICKETS);\n\n\tconst { getData, isDirty, reset } = useDataState();\n\n\tconst submitForm = useSubmitForm(getData());\n\n\tconst onSubmit = useCallback(async () => {\n\t\t// wait the next event cycle to fire up isLoading for submit button\n\t\tawait wait();\n\t\t// close modal\n\t\tcloseModal();\n\t\t// submit the data for mutations\n\t\tawait submitForm();\n\t\treset();\n\t}, [closeModal, reset, submitForm]);\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withContext(Container);\n","import { useCallback } from 'react';\n\nimport { __ } from '@eventespresso/i18n';\n\nimport { Calendar } from '@eventespresso/icons';\nimport { IconButton, EntityListItemProps, ItemCount } from '@eventespresso/ui-components';\nimport { useRelatedDatetimes, EdtrGlobalModals } from '@eventespresso/edtr-services';\nimport { TypeName } from '@eventespresso/services';\nimport { withIsLoaded } from '@eventespresso/services';\nimport type { Ticket } from '@eventespresso/edtr-services';\nimport { useGlobalModal } from '@eventespresso/registry';\n\nimport { BaseProps } from '@edtrUI/ticketAssignmentsManager';\n\nconst AssignDatesButton: React.FC> = ({ entity }) => {\n\tconst { openWithData } = useGlobalModal(EdtrGlobalModals.TAM);\n\n\tconst relatedDatetimes = useRelatedDatetimes({\n\t\tentity: 'tickets',\n\t\tentityId: entity.id,\n\t});\n\n\tconst count = relatedDatetimes.length;\n\n\tconst title = count\n\t\t? __('Number of related dates')\n\t\t: __(\n\t\t\t\t'There are no event dates assigned to this ticket. Please click the calendar icon to update the assignments.'\n\t\t );\n\n\tconst onOpen = useCallback(() => {\n\t\topenWithData({ entity, assignmentType: 'forTicket' });\n\t}, [entity, openWithData]);\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withIsLoaded>(TypeName.datetimes, ({ entity, loaded }) => {\n\t/* Hide TAM unless dates are loaded */\n\treturn loaded && ;\n});\n","/**\n * This file registers the UI elements related to ticket UI via registry package\n */\nimport {\n\tEntityActionsSubscription,\n\tEntityActionsSubscriptionCb,\n\tModalSubscription,\n\tNewEntitySubscription,\n\tFilterBarUISubscription,\n\tFilterBarUISubscriptionCb,\n} from '@eventespresso/registry';\nimport { domain, EdtrGlobalModals, Ticket, TicketsFilterStateManager, ticketsList } from '@eventespresso/edtr-services';\nimport { TicketPriceCalculatorButton, ModalContainer as TPCModalContainer } from '@eventespresso/tpc';\nimport { FilterBarFilter } from '@eventespresso/ui-components';\n\nimport {\n\tDisplayStartOrEndDateControl,\n\tSalesControl,\n\tSortByControl,\n\tStatusControl,\n\tIsChainedButton,\n} from '@edtrUI/tickets/ticketsList/filterBar/controls';\nimport { TicketMainMenu } from '@edtrUI/tickets/ticketsList/actionsMenu/dropdown';\nimport { Container as EditTicketContainer } from '@edtrUI/tickets/ticketForm/multiStep';\nimport DefaultTicketContainer from '@edtrUI/tickets/defaultTickets/Container';\nimport AssignDatesButton from '@edtrUI/tickets/ticketsList/actionsMenu/AssignDatesButton';\nimport { AddSingleTicket } from '@edtrUI/tickets/ticketsList/newTicketOptions';\n\n// Register ticket modal containers\nconst modals = new ModalSubscription(domain);\nmodals.subscribe(({ registry: { registerContainer } }) => {\n\t// Register edit ticket modal\n\tregisterContainer(EdtrGlobalModals.EDIT_TICKET, EditTicketContainer);\n\t// Register default tickets modal\n\tregisterContainer(EdtrGlobalModals.DEFAULT_TICKETS, DefaultTicketContainer);\n\t// Register TPC modal\n\tregisterContainer(EdtrGlobalModals.TPC, TPCModalContainer);\n});\n\n// Register ticket actions menu items.\nconst entityActions = new EntityActionsSubscription(domain);\nconst ticketsActionHandler: EntityActionsSubscriptionCb = ({ entity: ticket, registry }) => {\n\tconst { registerElement: registerMenuItem } = registry;\n\n\tregisterMenuItem('ticketMainMenu', () => );\n\n\tregisterMenuItem('assignDates', () => );\n\n\tregisterMenuItem('ticketPriceCalculator', () => );\n};\nentityActions.subscribe(ticketsActionHandler, { entityType: 'ticket' });\n\n// Register new ticket option(s)\nconst newEntityOptions = new NewEntitySubscription(domain);\nnewEntityOptions.subscribe(\n\t({ registry }) => {\n\t\tconst { registerElement: registerOptionItem } = registry;\n\n\t\tregisterOptionItem('AddSingleTicket', ({ totalCount }) => {\n\t\t\treturn ;\n\t\t});\n\t},\n\t{ entityType: 'ticket' }\n);\n\n// Register ticket filterBar elements\nconst filterBar = new FilterBarUISubscription(domain);\ntype TicketsListFilterBarCallback = FilterBarUISubscriptionCb;\nconst ticketsListFilterBar: TicketsListFilterBarCallback = ({ listId, registry }) => {\n\t// although this is not needed\n\tif (listId !== ticketsList) {\n\t\treturn;\n\t}\n\tconst { registerElement: registerFilterBarItem } = registry;\n\n\tregisterFilterBarItem('status', () => {\n\t\treturn (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t);\n\t});\n\n\tregisterFilterBarItem('isChained', () => {\n\t\treturn (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t);\n\t});\n\n\tregisterFilterBarItem('sales', () => {\n\t\treturn (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t);\n\t});\n\n\tregisterFilterBarItem('displayStartOrEndDate', () => {\n\t\treturn (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t);\n\t});\n\n\tregisterFilterBarItem('sortBy', () => {\n\t\treturn (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t);\n\t});\n};\nfilterBar.subscribe(ticketsListFilterBar, { listId: ticketsList });\n","/**\n * This file registers the UI elements related to TAM UI via registry package\n */\n\nimport { ModalSubscription } from '@eventespresso/registry';\nimport { domain, EdtrGlobalModals } from '@eventespresso/edtr-services';\nimport { ModalContainer } from './components';\n\n// Register date modal containers\nconst modals = new ModalSubscription(domain);\nmodals.subscribe(({ registry: { registerContainer } }) => {\n\t// Register TAM modal\n\tregisterContainer(EdtrGlobalModals.TAM, ModalContainer);\n});\n","/**\n * This file registers the filters for dates list via registry package\n */\nimport { FilterBarService } from '@eventespresso/registry';\nimport { dateSalesFilter, dateStatusFilter, sortDates } from '@eventespresso/predicates';\nimport { datesList, domain } from '@eventespresso/edtr-services';\nimport { entityListSearch } from '@eventespresso/utils';\nimport type { Datetime } from '@eventespresso/edtr-services';\nimport type { DatetimesFilterStateManager } from '@eventespresso/edtr-services';\n\ntype Domain = typeof domain;\ntype DFSM = DatetimesFilterStateManager;\n\nconst {\n\tregisterFilter: registerDatesFilter,\n\tregisterSearch: registerDatesSearch,\n\tregisterSorter: registerDatesSorter,\n} = new FilterBarService(domain, datesList);\n\n// Register sales filter\nregisterDatesFilter(({ entityList, filterState }) => {\n\treturn dateSalesFilter({ dates: entityList, sales: filterState.sales });\n}, 11);\n\n// Register status filter\nregisterDatesFilter(({ entityList, filterState }) => {\n\treturn dateStatusFilter({ dates: entityList, status: filterState.status });\n}, 9);\n\n// Register search\nregisterDatesSearch(({ entityList, filterState }) => {\n\treturn entityListSearch({\n\t\tentities: entityList,\n\t\tsearchFields: ['name', 'description'],\n\t\tsearchText: filterState.searchText,\n\t});\n});\n\n// Register sorter\nregisterDatesSorter(({ entityList, filterState }) => {\n\treturn sortDates({ dates: entityList, sortBy: filterState.sortBy });\n});\n","/**\n * This file registers the filters for tickets list via registry package\n */\nimport { FilterBarService } from '@eventespresso/registry';\nimport { ticketSalesFilter, ticketStatusFilter, sortTickets } from '@eventespresso/predicates';\nimport { domain, ticketsList } from '@eventespresso/edtr-services';\nimport { entityListSearch } from '@eventespresso/utils';\nimport type { Ticket, TicketsFilterStateManager } from '@eventespresso/edtr-services';\n\ntype Domain = typeof domain;\ntype TFSM = TicketsFilterStateManager;\n\nconst {\n\tregisterFilter: registerTicketsFilter,\n\tregisterSearch: registerTicketsSearch,\n\tregisterSorter: registerTicketsSorter,\n} = new FilterBarService(domain, ticketsList);\n\n// Register sales filter\nregisterTicketsFilter(({ entityList, filterState }) => {\n\treturn ticketSalesFilter({ sales: filterState.sales, tickets: entityList });\n}, 11);\n\n// Register status filter\nregisterTicketsFilter(({ entityList, filterState }) => {\n\treturn ticketStatusFilter({ status: filterState.status, tickets: entityList });\n}, 10); // 10 by default\n\n// Register search\nregisterTicketsSearch(({ entityList, filterState }) => {\n\treturn entityListSearch({\n\t\tentities: entityList,\n\t\tsearchFields: ['name', 'description'],\n\t\tsearchText: filterState.searchText,\n\t});\n});\n\n// Register sorter\nregisterTicketsSorter(({ entityList, filterState }) => {\n\treturn sortTickets({ tickets: entityList, sortBy: filterState.sortBy });\n});\n","import { PluginArea } from '@eventespresso/plugins';\n\nimport { useEditorInitialization } from '../hooks';\nimport { Spinner } from '@eventespresso/adapters';\nimport { getRegisteredContainers } from '@edtrServices/utils';\n\nimport { DatesList } from './datetimes/datesList';\nimport EventRegistrationOptions from './EventRegistrationOptions';\nimport { TicketsList } from './tickets/ticketsList';\nimport EventDescription from './EventDescription';\nimport { VenueDetails } from './venue';\nimport { RegistrationForm } from './registrationForm';\nimport Notifications from './notifications/Notifications';\n\n// fire up the service and UI element registry\nimport './registryInit';\nimport './styles.scss';\n\nconst containers = getRegisteredContainers();\n\nconst EventEditor: React.FC = () => {\n\tconst isRehydrated = useEditorInitialization();\n\n\tif (!isRehydrated) {\n\t\treturn ;\n\t}\n\n\treturn (\n\t\t<>\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t{containers}\n\t\t\t\n\t\t\n\t);\n};\n\nexport default EventEditor;\n","import { ContextProviders } from '@edtrServices/context';\nimport { renderDomElement } from '@eventespresso/utils';\n\nimport EventEditor from './EventEditor';\n\nimport '../../../../../../packages/styles/src/themes/default/index.scss'; // to bundle it\n\nconst Editor: React.FC = () => (\n\t\n\t\t\n\t\n);\n\nconst setupEditor = (): void => {\n\trenderDomElement({\n\t\tappendToTarget: false,\n\t\tdomElementToRender: ,\n\t\tcontainerID: 'ee-event-editor',\n\t\tcontainerClassName: 'ee-editor-container',\n\t\ttargetElementID: 'normal-sortables',\n\t});\n};\n\nsetupEditor();\n","(function() { module.exports = window[\"eventespresso\"][\"utils\"]; }());","/**\n * Copyright (c) 2014-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nvar runtime = (function (exports) {\n \"use strict\";\n\n var Op = Object.prototype;\n var hasOwn = Op.hasOwnProperty;\n var undefined; // More compressible than void 0.\n var $Symbol = typeof Symbol === \"function\" ? Symbol : {};\n var iteratorSymbol = $Symbol.iterator || \"@@iterator\";\n var asyncIteratorSymbol = $Symbol.asyncIterator || \"@@asyncIterator\";\n var toStringTagSymbol = $Symbol.toStringTag || \"@@toStringTag\";\n\n function define(obj, key, value) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n return obj[key];\n }\n try {\n // IE 8 has a broken Object.defineProperty that only works on DOM objects.\n define({}, \"\");\n } catch (err) {\n define = function(obj, key, value) {\n return obj[key] = value;\n };\n }\n\n function wrap(innerFn, outerFn, self, tryLocsList) {\n // If outerFn provided and outerFn.prototype is a Generator, then outerFn.prototype instanceof Generator.\n var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator;\n var generator = Object.create(protoGenerator.prototype);\n var context = new Context(tryLocsList || []);\n\n // The ._invoke method unifies the implementations of the .next,\n // .throw, and .return methods.\n generator._invoke = makeInvokeMethod(innerFn, self, context);\n\n return generator;\n }\n exports.wrap = wrap;\n\n // Try/catch helper to minimize deoptimizations. Returns a completion\n // record like context.tryEntries[i].completion. This interface could\n // have been (and was previously) designed to take a closure to be\n // invoked without arguments, but in all the cases we care about we\n // already have an existing method we want to call, so there's no need\n // to create a new function object. We can even get away with assuming\n // the method takes exactly one argument, since that happens to be true\n // in every case, so we don't have to touch the arguments object. The\n // only additional allocation required is the completion record, which\n // has a stable shape and so hopefully should be cheap to allocate.\n function tryCatch(fn, obj, arg) {\n try {\n return { type: \"normal\", arg: fn.call(obj, arg) };\n } catch (err) {\n return { type: \"throw\", arg: err };\n }\n }\n\n var GenStateSuspendedStart = \"suspendedStart\";\n var GenStateSuspendedYield = \"suspendedYield\";\n var GenStateExecuting = \"executing\";\n var GenStateCompleted = \"completed\";\n\n // Returning this object from the innerFn has the same effect as\n // breaking out of the dispatch switch statement.\n var ContinueSentinel = {};\n\n // Dummy constructor functions that we use as the .constructor and\n // .constructor.prototype properties for functions that return Generator\n // objects. For full spec compliance, you may wish to configure your\n // minifier not to mangle the names of these two functions.\n function Generator() {}\n function GeneratorFunction() {}\n function GeneratorFunctionPrototype() {}\n\n // This is a polyfill for %IteratorPrototype% for environments that\n // don't natively support it.\n var IteratorPrototype = {};\n IteratorPrototype[iteratorSymbol] = function () {\n return this;\n };\n\n var getProto = Object.getPrototypeOf;\n var NativeIteratorPrototype = getProto && getProto(getProto(values([])));\n if (NativeIteratorPrototype &&\n NativeIteratorPrototype !== Op &&\n hasOwn.call(NativeIteratorPrototype, iteratorSymbol)) {\n // This environment has a native %IteratorPrototype%; use it instead\n // of the polyfill.\n IteratorPrototype = NativeIteratorPrototype;\n }\n\n var Gp = GeneratorFunctionPrototype.prototype =\n Generator.prototype = Object.create(IteratorPrototype);\n GeneratorFunction.prototype = Gp.constructor = GeneratorFunctionPrototype;\n GeneratorFunctionPrototype.constructor = GeneratorFunction;\n GeneratorFunction.displayName = define(\n GeneratorFunctionPrototype,\n toStringTagSymbol,\n \"GeneratorFunction\"\n );\n\n // Helper for defining the .next, .throw, and .return methods of the\n // Iterator interface in terms of a single ._invoke method.\n function defineIteratorMethods(prototype) {\n [\"next\", \"throw\", \"return\"].forEach(function(method) {\n define(prototype, method, function(arg) {\n return this._invoke(method, arg);\n });\n });\n }\n\n exports.isGeneratorFunction = function(genFun) {\n var ctor = typeof genFun === \"function\" && genFun.constructor;\n return ctor\n ? ctor === GeneratorFunction ||\n // For the native GeneratorFunction constructor, the best we can\n // do is to check its .name property.\n (ctor.displayName || ctor.name) === \"GeneratorFunction\"\n : false;\n };\n\n exports.mark = function(genFun) {\n if (Object.setPrototypeOf) {\n Object.setPrototypeOf(genFun, GeneratorFunctionPrototype);\n } else {\n genFun.__proto__ = GeneratorFunctionPrototype;\n define(genFun, toStringTagSymbol, \"GeneratorFunction\");\n }\n genFun.prototype = Object.create(Gp);\n return genFun;\n };\n\n // Within the body of any async function, `await x` is transformed to\n // `yield regeneratorRuntime.awrap(x)`, so that the runtime can test\n // `hasOwn.call(value, \"__await\")` to determine if the yielded value is\n // meant to be awaited.\n exports.awrap = function(arg) {\n return { __await: arg };\n };\n\n function AsyncIterator(generator, PromiseImpl) {\n function invoke(method, arg, resolve, reject) {\n var record = tryCatch(generator[method], generator, arg);\n if (record.type === \"throw\") {\n reject(record.arg);\n } else {\n var result = record.arg;\n var value = result.value;\n if (value &&\n typeof value === \"object\" &&\n hasOwn.call(value, \"__await\")) {\n return PromiseImpl.resolve(value.__await).then(function(value) {\n invoke(\"next\", value, resolve, reject);\n }, function(err) {\n invoke(\"throw\", err, resolve, reject);\n });\n }\n\n return PromiseImpl.resolve(value).then(function(unwrapped) {\n // When a yielded Promise is resolved, its final value becomes\n // the .value of the Promise<{value,done}> result for the\n // current iteration.\n result.value = unwrapped;\n resolve(result);\n }, function(error) {\n // If a rejected Promise was yielded, throw the rejection back\n // into the async generator function so it can be handled there.\n return invoke(\"throw\", error, resolve, reject);\n });\n }\n }\n\n var previousPromise;\n\n function enqueue(method, arg) {\n function callInvokeWithMethodAndArg() {\n return new PromiseImpl(function(resolve, reject) {\n invoke(method, arg, resolve, reject);\n });\n }\n\n return previousPromise =\n // If enqueue has been called before, then we want to wait until\n // all previous Promises have been resolved before calling invoke,\n // so that results are always delivered in the correct order. If\n // enqueue has not been called before, then it is important to\n // call invoke immediately, without waiting on a callback to fire,\n // so that the async generator function has the opportunity to do\n // any necessary setup in a predictable way. This predictability\n // is why the Promise constructor synchronously invokes its\n // executor callback, and why async functions synchronously\n // execute code before the first await. Since we implement simple\n // async functions in terms of async generators, it is especially\n // important to get this right, even though it requires care.\n previousPromise ? previousPromise.then(\n callInvokeWithMethodAndArg,\n // Avoid propagating failures to Promises returned by later\n // invocations of the iterator.\n callInvokeWithMethodAndArg\n ) : callInvokeWithMethodAndArg();\n }\n\n // Define the unified helper method that is used to implement .next,\n // .throw, and .return (see defineIteratorMethods).\n this._invoke = enqueue;\n }\n\n defineIteratorMethods(AsyncIterator.prototype);\n AsyncIterator.prototype[asyncIteratorSymbol] = function () {\n return this;\n };\n exports.AsyncIterator = AsyncIterator;\n\n // Note that simple async functions are implemented on top of\n // AsyncIterator objects; they just return a Promise for the value of\n // the final result produced by the iterator.\n exports.async = function(innerFn, outerFn, self, tryLocsList, PromiseImpl) {\n if (PromiseImpl === void 0) PromiseImpl = Promise;\n\n var iter = new AsyncIterator(\n wrap(innerFn, outerFn, self, tryLocsList),\n PromiseImpl\n );\n\n return exports.isGeneratorFunction(outerFn)\n ? iter // If outerFn is a generator, return the full iterator.\n : iter.next().then(function(result) {\n return result.done ? result.value : iter.next();\n });\n };\n\n function makeInvokeMethod(innerFn, self, context) {\n var state = GenStateSuspendedStart;\n\n return function invoke(method, arg) {\n if (state === GenStateExecuting) {\n throw new Error(\"Generator is already running\");\n }\n\n if (state === GenStateCompleted) {\n if (method === \"throw\") {\n throw arg;\n }\n\n // Be forgiving, per 25.3.3.3.3 of the spec:\n // https://people.mozilla.org/~jorendorff/es6-draft.html#sec-generatorresume\n return doneResult();\n }\n\n context.method = method;\n context.arg = arg;\n\n while (true) {\n var delegate = context.delegate;\n if (delegate) {\n var delegateResult = maybeInvokeDelegate(delegate, context);\n if (delegateResult) {\n if (delegateResult === ContinueSentinel) continue;\n return delegateResult;\n }\n }\n\n if (context.method === \"next\") {\n // Setting context._sent for legacy support of Babel's\n // function.sent implementation.\n context.sent = context._sent = context.arg;\n\n } else if (context.method === \"throw\") {\n if (state === GenStateSuspendedStart) {\n state = GenStateCompleted;\n throw context.arg;\n }\n\n context.dispatchException(context.arg);\n\n } else if (context.method === \"return\") {\n context.abrupt(\"return\", context.arg);\n }\n\n state = GenStateExecuting;\n\n var record = tryCatch(innerFn, self, context);\n if (record.type === \"normal\") {\n // If an exception is thrown from innerFn, we leave state ===\n // GenStateExecuting and loop back for another invocation.\n state = context.done\n ? GenStateCompleted\n : GenStateSuspendedYield;\n\n if (record.arg === ContinueSentinel) {\n continue;\n }\n\n return {\n value: record.arg,\n done: context.done\n };\n\n } else if (record.type === \"throw\") {\n state = GenStateCompleted;\n // Dispatch the exception by looping back around to the\n // context.dispatchException(context.arg) call above.\n context.method = \"throw\";\n context.arg = record.arg;\n }\n }\n };\n }\n\n // Call delegate.iterator[context.method](context.arg) and handle the\n // result, either by returning a { value, done } result from the\n // delegate iterator, or by modifying context.method and context.arg,\n // setting context.delegate to null, and returning the ContinueSentinel.\n function maybeInvokeDelegate(delegate, context) {\n var method = delegate.iterator[context.method];\n if (method === undefined) {\n // A .throw or .return when the delegate iterator has no .throw\n // method always terminates the yield* loop.\n context.delegate = null;\n\n if (context.method === \"throw\") {\n // Note: [\"return\"] must be used for ES3 parsing compatibility.\n if (delegate.iterator[\"return\"]) {\n // If the delegate iterator has a return method, give it a\n // chance to clean up.\n context.method = \"return\";\n context.arg = undefined;\n maybeInvokeDelegate(delegate, context);\n\n if (context.method === \"throw\") {\n // If maybeInvokeDelegate(context) changed context.method from\n // \"return\" to \"throw\", let that override the TypeError below.\n return ContinueSentinel;\n }\n }\n\n context.method = \"throw\";\n context.arg = new TypeError(\n \"The iterator does not provide a 'throw' method\");\n }\n\n return ContinueSentinel;\n }\n\n var record = tryCatch(method, delegate.iterator, context.arg);\n\n if (record.type === \"throw\") {\n context.method = \"throw\";\n context.arg = record.arg;\n context.delegate = null;\n return ContinueSentinel;\n }\n\n var info = record.arg;\n\n if (! info) {\n context.method = \"throw\";\n context.arg = new TypeError(\"iterator result is not an object\");\n context.delegate = null;\n return ContinueSentinel;\n }\n\n if (info.done) {\n // Assign the result of the finished delegate to the temporary\n // variable specified by delegate.resultName (see delegateYield).\n context[delegate.resultName] = info.value;\n\n // Resume execution at the desired location (see delegateYield).\n context.next = delegate.nextLoc;\n\n // If context.method was \"throw\" but the delegate handled the\n // exception, let the outer generator proceed normally. If\n // context.method was \"next\", forget context.arg since it has been\n // \"consumed\" by the delegate iterator. If context.method was\n // \"return\", allow the original .return call to continue in the\n // outer generator.\n if (context.method !== \"return\") {\n context.method = \"next\";\n context.arg = undefined;\n }\n\n } else {\n // Re-yield the result returned by the delegate method.\n return info;\n }\n\n // The delegate iterator is finished, so forget it and continue with\n // the outer generator.\n context.delegate = null;\n return ContinueSentinel;\n }\n\n // Define Generator.prototype.{next,throw,return} in terms of the\n // unified ._invoke helper method.\n defineIteratorMethods(Gp);\n\n define(Gp, toStringTagSymbol, \"Generator\");\n\n // A Generator should always return itself as the iterator object when the\n // @@iterator function is called on it. Some browsers' implementations of the\n // iterator prototype chain incorrectly implement this, causing the Generator\n // object to not be returned from this call. This ensures that doesn't happen.\n // See https://github.com/facebook/regenerator/issues/274 for more details.\n Gp[iteratorSymbol] = function() {\n return this;\n };\n\n Gp.toString = function() {\n return \"[object Generator]\";\n };\n\n function pushTryEntry(locs) {\n var entry = { tryLoc: locs[0] };\n\n if (1 in locs) {\n entry.catchLoc = locs[1];\n }\n\n if (2 in locs) {\n entry.finallyLoc = locs[2];\n entry.afterLoc = locs[3];\n }\n\n this.tryEntries.push(entry);\n }\n\n function resetTryEntry(entry) {\n var record = entry.completion || {};\n record.type = \"normal\";\n delete record.arg;\n entry.completion = record;\n }\n\n function Context(tryLocsList) {\n // The root entry object (effectively a try statement without a catch\n // or a finally block) gives us a place to store values thrown from\n // locations where there is no enclosing try statement.\n this.tryEntries = [{ tryLoc: \"root\" }];\n tryLocsList.forEach(pushTryEntry, this);\n this.reset(true);\n }\n\n exports.keys = function(object) {\n var keys = [];\n for (var key in object) {\n keys.push(key);\n }\n keys.reverse();\n\n // Rather than returning an object with a next method, we keep\n // things simple and return the next function itself.\n return function next() {\n while (keys.length) {\n var key = keys.pop();\n if (key in object) {\n next.value = key;\n next.done = false;\n return next;\n }\n }\n\n // To avoid creating an additional object, we just hang the .value\n // and .done properties off the next function object itself. This\n // also ensures that the minifier will not anonymize the function.\n next.done = true;\n return next;\n };\n };\n\n function values(iterable) {\n if (iterable) {\n var iteratorMethod = iterable[iteratorSymbol];\n if (iteratorMethod) {\n return iteratorMethod.call(iterable);\n }\n\n if (typeof iterable.next === \"function\") {\n return iterable;\n }\n\n if (!isNaN(iterable.length)) {\n var i = -1, next = function next() {\n while (++i < iterable.length) {\n if (hasOwn.call(iterable, i)) {\n next.value = iterable[i];\n next.done = false;\n return next;\n }\n }\n\n next.value = undefined;\n next.done = true;\n\n return next;\n };\n\n return next.next = next;\n }\n }\n\n // Return an iterator with no values.\n return { next: doneResult };\n }\n exports.values = values;\n\n function doneResult() {\n return { value: undefined, done: true };\n }\n\n Context.prototype = {\n constructor: Context,\n\n reset: function(skipTempReset) {\n this.prev = 0;\n this.next = 0;\n // Resetting context._sent for legacy support of Babel's\n // function.sent implementation.\n this.sent = this._sent = undefined;\n this.done = false;\n this.delegate = null;\n\n this.method = \"next\";\n this.arg = undefined;\n\n this.tryEntries.forEach(resetTryEntry);\n\n if (!skipTempReset) {\n for (var name in this) {\n // Not sure about the optimal order of these conditions:\n if (name.charAt(0) === \"t\" &&\n hasOwn.call(this, name) &&\n !isNaN(+name.slice(1))) {\n this[name] = undefined;\n }\n }\n }\n },\n\n stop: function() {\n this.done = true;\n\n var rootEntry = this.tryEntries[0];\n var rootRecord = rootEntry.completion;\n if (rootRecord.type === \"throw\") {\n throw rootRecord.arg;\n }\n\n return this.rval;\n },\n\n dispatchException: function(exception) {\n if (this.done) {\n throw exception;\n }\n\n var context = this;\n function handle(loc, caught) {\n record.type = \"throw\";\n record.arg = exception;\n context.next = loc;\n\n if (caught) {\n // If the dispatched exception was caught by a catch block,\n // then let that catch block handle the exception normally.\n context.method = \"next\";\n context.arg = undefined;\n }\n\n return !! caught;\n }\n\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n var record = entry.completion;\n\n if (entry.tryLoc === \"root\") {\n // Exception thrown outside of any try block that could handle\n // it, so set the completion value of the entire function to\n // throw the exception.\n return handle(\"end\");\n }\n\n if (entry.tryLoc <= this.prev) {\n var hasCatch = hasOwn.call(entry, \"catchLoc\");\n var hasFinally = hasOwn.call(entry, \"finallyLoc\");\n\n if (hasCatch && hasFinally) {\n if (this.prev < entry.catchLoc) {\n return handle(entry.catchLoc, true);\n } else if (this.prev < entry.finallyLoc) {\n return handle(entry.finallyLoc);\n }\n\n } else if (hasCatch) {\n if (this.prev < entry.catchLoc) {\n return handle(entry.catchLoc, true);\n }\n\n } else if (hasFinally) {\n if (this.prev < entry.finallyLoc) {\n return handle(entry.finallyLoc);\n }\n\n } else {\n throw new Error(\"try statement without catch or finally\");\n }\n }\n }\n },\n\n abrupt: function(type, arg) {\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n if (entry.tryLoc <= this.prev &&\n hasOwn.call(entry, \"finallyLoc\") &&\n this.prev < entry.finallyLoc) {\n var finallyEntry = entry;\n break;\n }\n }\n\n if (finallyEntry &&\n (type === \"break\" ||\n type === \"continue\") &&\n finallyEntry.tryLoc <= arg &&\n arg <= finallyEntry.finallyLoc) {\n // Ignore the finally entry if control is not jumping to a\n // location outside the try/catch block.\n finallyEntry = null;\n }\n\n var record = finallyEntry ? finallyEntry.completion : {};\n record.type = type;\n record.arg = arg;\n\n if (finallyEntry) {\n this.method = \"next\";\n this.next = finallyEntry.finallyLoc;\n return ContinueSentinel;\n }\n\n return this.complete(record);\n },\n\n complete: function(record, afterLoc) {\n if (record.type === \"throw\") {\n throw record.arg;\n }\n\n if (record.type === \"break\" ||\n record.type === \"continue\") {\n this.next = record.arg;\n } else if (record.type === \"return\") {\n this.rval = this.arg = record.arg;\n this.method = \"return\";\n this.next = \"end\";\n } else if (record.type === \"normal\" && afterLoc) {\n this.next = afterLoc;\n }\n\n return ContinueSentinel;\n },\n\n finish: function(finallyLoc) {\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n if (entry.finallyLoc === finallyLoc) {\n this.complete(entry.completion, entry.afterLoc);\n resetTryEntry(entry);\n return ContinueSentinel;\n }\n }\n },\n\n \"catch\": function(tryLoc) {\n for (var i = this.tryEntries.length - 1; i >= 0; --i) {\n var entry = this.tryEntries[i];\n if (entry.tryLoc === tryLoc) {\n var record = entry.completion;\n if (record.type === \"throw\") {\n var thrown = record.arg;\n resetTryEntry(entry);\n }\n return thrown;\n }\n }\n\n // The context.catch method must only be called with a location\n // argument that corresponds to a known catch block.\n throw new Error(\"illegal catch attempt\");\n },\n\n delegateYield: function(iterable, resultName, nextLoc) {\n this.delegate = {\n iterator: values(iterable),\n resultName: resultName,\n nextLoc: nextLoc\n };\n\n if (this.method === \"next\") {\n // Deliberately forget the last sent value so that we don't\n // accidentally pass it on to the delegate.\n this.arg = undefined;\n }\n\n return ContinueSentinel;\n }\n };\n\n // Regardless of whether this script is executing as a CommonJS module\n // or not, return the runtime object so that we can declare the variable\n // regeneratorRuntime in the outer scope, which allows this module to be\n // injected easily by `bin/regenerator --include-runtime script.js`.\n return exports;\n\n}(\n // If this script is executing as a CommonJS module, use module.exports\n // as the regeneratorRuntime namespace. Otherwise create a new empty\n // object. Either way, the resulting object will be used to initialize\n // the regeneratorRuntime variable at the top of this file.\n typeof module === \"object\" ? module.exports : {}\n));\n\ntry {\n regeneratorRuntime = runtime;\n} catch (accidentalStrictMode) {\n // This module should not be running in strict mode, so the above\n // assignment should always work unless something is misconfigured. Just\n // in case runtime.js accidentally runs in strict mode, we can escape\n // strict mode using a global Function call. This could conceivably fail\n // if a Content Security Policy forbids using Function, but in that case\n // the proper solution is to fix the accidental strict mode problem. If\n // you've misconfigured your bundler to force strict mode and applied a\n // CSP to forbid Function, and you're not willing to fix either of those\n // problems, please detail your unique predicament in a GitHub issue.\n Function(\"r\", \"regeneratorRuntime = r\")(runtime);\n}\n","(function() { module.exports = window[\"eventespresso\"][\"toaster\"]; }());","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst ProfileOutlined = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(ProfileOutlined, 'profile-outlined');\n","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst ControlOutlined = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(ControlOutlined, 'control-outlined');\n","export { default as useDataState } from './useDataState';\n\nexport { default as useInitialState } from './useInitialState';\n\nexport { default as useDataStateManager } from './useDataStateManager';\n\nexport { default as useSubmitForm } from './useSubmitForm';\n\nexport * from './types';\n","(function() { module.exports = window[\"eventespresso\"][\"data\"]; }());","import defineProperty from \"@babel/runtime/helpers/esm/defineProperty\";\n\nfunction ownKeys(object, enumerableOnly) {\n var keys = Object.keys(object);\n\n if (Object.getOwnPropertySymbols) {\n var symbols = Object.getOwnPropertySymbols(object);\n if (enumerableOnly) symbols = symbols.filter(function (sym) {\n return Object.getOwnPropertyDescriptor(object, sym).enumerable;\n });\n keys.push.apply(keys, symbols);\n }\n\n return keys;\n}\n\nexport default function _objectSpread2(target) {\n for (var i = 1; i < arguments.length; i++) {\n var source = arguments[i] != null ? arguments[i] : {};\n\n if (i % 2) {\n ownKeys(Object(source), true).forEach(function (key) {\n defineProperty(target, key, source[key]);\n });\n } else if (Object.getOwnPropertyDescriptors) {\n Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));\n } else {\n ownKeys(Object(source)).forEach(function (key) {\n Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));\n });\n }\n }\n\n return target;\n}","var Symbol = require('./_Symbol'),\n getRawTag = require('./_getRawTag'),\n objectToString = require('./_objectToString');\n\n/** `Object#toString` result references. */\nvar nullTag = '[object Null]',\n undefinedTag = '[object Undefined]';\n\n/** Built-in value references. */\nvar symToStringTag = Symbol ? Symbol.toStringTag : undefined;\n\n/**\n * The base implementation of `getTag` without fallbacks for buggy environments.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\nfunction baseGetTag(value) {\n if (value == null) {\n return value === undefined ? undefinedTag : nullTag;\n }\n return (symToStringTag && symToStringTag in Object(value))\n ? getRawTag(value)\n : objectToString(value);\n}\n\nmodule.exports = baseGetTag;\n","/**\n * Checks if `value` is object-like. A value is object-like if it's not `null`\n * and has a `typeof` result of \"object\".\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is object-like, else `false`.\n * @example\n *\n * _.isObjectLike({});\n * // => true\n *\n * _.isObjectLike([1, 2, 3]);\n * // => true\n *\n * _.isObjectLike(_.noop);\n * // => false\n *\n * _.isObjectLike(null);\n * // => false\n */\nfunction isObjectLike(value) {\n return value != null && typeof value == 'object';\n}\n\nmodule.exports = isObjectLike;\n","var baseToString = require('./_baseToString');\n\n/**\n * Converts `value` to a string. An empty string is returned for `null`\n * and `undefined` values. The sign of `-0` is preserved.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to convert.\n * @returns {string} Returns the converted string.\n * @example\n *\n * _.toString(null);\n * // => ''\n *\n * _.toString(-0);\n * // => '-0'\n *\n * _.toString([1, 2, 3]);\n * // => '1,2,3'\n */\nfunction toString(value) {\n return value == null ? '' : baseToString(value);\n}\n\nmodule.exports = toString;\n","import classNames from 'classnames';\n\nimport { IconComponent } from './types';\n\nimport './style.scss';\n\nconst withClassName = (WrappedComponent: IconComponent, svgName = ''): IconComponent => {\n\tconst WrappedIcon: IconComponent = ({ noMargin, size, ...props }) => {\n\t\tconst className = classNames(\n\t\t\t'ee-svg',\n\t\t\tsize && `ee-icon--${size}`,\n\t\t\tnoMargin && 'ee-icon--no-margin',\n\t\t\tsvgName && `ee-svg--${svgName}`,\n\t\t\tprops.className\n\t\t);\n\n\t\treturn ;\n\t};\n\n\treturn WrappedIcon;\n};\n\nexport default withClassName;\n","// ES6 Map\nvar map\ntry {\n map = Map\n} catch (_) { }\nvar set\n\n// ES6 Set\ntry {\n set = Set\n} catch (_) { }\n\nfunction baseClone (src, circulars, clones) {\n // Null/undefined/functions/etc\n if (!src || typeof src !== 'object' || typeof src === 'function') {\n return src\n }\n\n // DOM Node\n if (src.nodeType && 'cloneNode' in src) {\n return src.cloneNode(true)\n }\n\n // Date\n if (src instanceof Date) {\n return new Date(src.getTime())\n }\n\n // RegExp\n if (src instanceof RegExp) {\n return new RegExp(src)\n }\n\n // Arrays\n if (Array.isArray(src)) {\n return src.map(clone)\n }\n\n // ES6 Maps\n if (map && src instanceof map) {\n return new Map(Array.from(src.entries()))\n }\n\n // ES6 Sets\n if (set && src instanceof set) {\n return new Set(Array.from(src.values()))\n }\n\n // Object\n if (src instanceof Object) {\n circulars.push(src)\n var obj = Object.create(src)\n clones.push(obj)\n for (var key in src) {\n var idx = circulars.findIndex(function (i) {\n return i === src[key]\n })\n obj[key] = idx > -1 ? clones[idx] : baseClone(src[key], circulars, clones)\n }\n return obj\n }\n\n // ???\n return src\n}\n\nexport default function clone (src) {\n return baseClone(src, [], [])\n}\n","const toString = Object.prototype.toString;\nconst errorToString = Error.prototype.toString;\nconst regExpToString = RegExp.prototype.toString;\nconst symbolToString = typeof Symbol !== 'undefined' ? Symbol.prototype.toString : () => '';\nconst SYMBOL_REGEXP = /^Symbol\\((.*)\\)(.*)$/;\n\nfunction printNumber(val) {\n if (val != +val) return 'NaN';\n const isNegativeZero = val === 0 && 1 / val < 0;\n return isNegativeZero ? '-0' : '' + val;\n}\n\nfunction printSimpleValue(val, quoteStrings = false) {\n if (val == null || val === true || val === false) return '' + val;\n const typeOf = typeof val;\n if (typeOf === 'number') return printNumber(val);\n if (typeOf === 'string') return quoteStrings ? `\"${val}\"` : val;\n if (typeOf === 'function') return '[Function ' + (val.name || 'anonymous') + ']';\n if (typeOf === 'symbol') return symbolToString.call(val).replace(SYMBOL_REGEXP, 'Symbol($1)');\n const tag = toString.call(val).slice(8, -1);\n if (tag === 'Date') return isNaN(val.getTime()) ? '' + val : val.toISOString(val);\n if (tag === 'Error' || val instanceof Error) return '[' + errorToString.call(val) + ']';\n if (tag === 'RegExp') return regExpToString.call(val);\n return null;\n}\n\nexport default function printValue(value, quoteStrings) {\n let result = printSimpleValue(value, quoteStrings);\n if (result !== null) return result;\n return JSON.stringify(value, function (key, value) {\n let result = printSimpleValue(this[key], quoteStrings);\n if (result !== null) return result;\n return value;\n }, 2);\n}","import printValue from './util/printValue';\nexport let mixed = {\n default: '${path} is invalid',\n required: '${path} is a required field',\n oneOf: '${path} must be one of the following values: ${values}',\n notOneOf: '${path} must not be one of the following values: ${values}',\n notType: ({\n path,\n type,\n value,\n originalValue\n }) => {\n let isCast = originalValue != null && originalValue !== value;\n let msg = `${path} must be a \\`${type}\\` type, ` + `but the final value was: \\`${printValue(value, true)}\\`` + (isCast ? ` (cast from the value \\`${printValue(originalValue, true)}\\`).` : '.');\n\n if (value === null) {\n msg += `\\n If \"null\" is intended as an empty value be sure to mark the schema as \\`.nullable()\\``;\n }\n\n return msg;\n },\n defined: '${path} must be defined'\n};\nexport let string = {\n length: '${path} must be exactly ${length} characters',\n min: '${path} must be at least ${min} characters',\n max: '${path} must be at most ${max} characters',\n matches: '${path} must match the following: \"${regex}\"',\n email: '${path} must be a valid email',\n url: '${path} must be a valid URL',\n uuid: '${path} must be a valid UUID',\n trim: '${path} must be a trimmed string',\n lowercase: '${path} must be a lowercase string',\n uppercase: '${path} must be a upper case string'\n};\nexport let number = {\n min: '${path} must be greater than or equal to ${min}',\n max: '${path} must be less than or equal to ${max}',\n lessThan: '${path} must be less than ${less}',\n moreThan: '${path} must be greater than ${more}',\n positive: '${path} must be a positive number',\n negative: '${path} must be a negative number',\n integer: '${path} must be an integer'\n};\nexport let date = {\n min: '${path} field must be later than ${min}',\n max: '${path} field must be at earlier than ${max}'\n};\nexport let boolean = {\n isValue: '${path} field must be ${value}'\n};\nexport let object = {\n noUnknown: '${path} field has unspecified keys: ${unknown}'\n};\nexport let array = {\n min: '${path} field must have at least ${min} items',\n max: '${path} field must have less than or equal to ${max} items',\n length: '${path} must have ${length} items'\n};\nexport default Object.assign(Object.create(null), {\n mixed,\n string,\n number,\n date,\n object,\n array,\n boolean\n});","const isSchema = obj => obj && obj.__isYupSchema__;\n\nexport default isSchema;","import has from 'lodash/has';\nimport isSchema from './util/isSchema';\n\nclass Condition {\n constructor(refs, options) {\n this.fn = void 0;\n this.refs = refs;\n this.refs = refs;\n\n if (typeof options === 'function') {\n this.fn = options;\n return;\n }\n\n if (!has(options, 'is')) throw new TypeError('`is:` is required for `when()` conditions');\n if (!options.then && !options.otherwise) throw new TypeError('either `then:` or `otherwise:` is required for `when()` conditions');\n let {\n is,\n then,\n otherwise\n } = options;\n let check = typeof is === 'function' ? is : (...values) => values.every(value => value === is);\n\n this.fn = function (...args) {\n let options = args.pop();\n let schema = args.pop();\n let branch = check(...args) ? then : otherwise;\n if (!branch) return undefined;\n if (typeof branch === 'function') return branch(schema);\n return schema.concat(branch.resolve(options));\n };\n }\n\n resolve(base, options) {\n let values = this.refs.map(ref => ref.getValue(options == null ? void 0 : options.value, options == null ? void 0 : options.parent, options == null ? void 0 : options.context));\n let schema = this.fn.apply(base, values.concat(base, options));\n if (schema === undefined || schema === base) return base;\n if (!isSchema(schema)) throw new TypeError('conditions must return a schema object');\n return schema.resolve(options);\n }\n\n}\n\nexport default Condition;","export default function toArray(value) {\n return value == null ? [] : [].concat(value);\n}","function _extends() { _extends = Object.assign || 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); }\n\nimport printValue from './util/printValue';\nimport toArray from './util/toArray';\nlet strReg = /\\$\\{\\s*(\\w+)\\s*\\}/g;\nexport default class ValidationError extends Error {\n static formatError(message, params) {\n const path = params.label || params.path || 'this';\n if (path !== params.path) params = _extends({}, params, {\n path\n });\n if (typeof message === 'string') return message.replace(strReg, (_, key) => printValue(params[key]));\n if (typeof message === 'function') return message(params);\n return message;\n }\n\n static isError(err) {\n return err && err.name === 'ValidationError';\n }\n\n constructor(errorOrErrors, value, field, type) {\n super();\n this.value = void 0;\n this.path = void 0;\n this.type = void 0;\n this.errors = void 0;\n this.params = void 0;\n this.inner = void 0;\n this.name = 'ValidationError';\n this.value = value;\n this.path = field;\n this.type = type;\n this.errors = [];\n this.inner = [];\n toArray(errorOrErrors).forEach(err => {\n if (ValidationError.isError(err)) {\n this.errors.push(...err.errors);\n this.inner = this.inner.concat(err.inner.length ? err.inner : err);\n } else {\n this.errors.push(err);\n }\n });\n this.message = this.errors.length > 1 ? `${this.errors.length} errors occurred` : this.errors[0];\n if (Error.captureStackTrace) Error.captureStackTrace(this, ValidationError);\n }\n\n}","import ValidationError from '../ValidationError';\n\nconst once = cb => {\n let fired = false;\n return (...args) => {\n if (fired) return;\n fired = true;\n cb(...args);\n };\n};\n\nexport default function runTests(options, cb) {\n let {\n endEarly,\n tests,\n args,\n value,\n errors,\n sort,\n path\n } = options;\n let callback = once(cb);\n let count = tests.length;\n const nestedErrors = [];\n errors = errors ? errors : [];\n if (!count) return errors.length ? callback(new ValidationError(errors, value, path)) : callback(null, value);\n\n for (let i = 0; i < tests.length; i++) {\n const test = tests[i];\n test(args, function finishTestRun(err) {\n if (err) {\n // always return early for non validation errors\n if (!ValidationError.isError(err)) {\n return callback(err, value);\n }\n\n if (endEarly) {\n err.value = value;\n return callback(err, value);\n }\n\n nestedErrors.push(err);\n }\n\n if (--count <= 0) {\n if (nestedErrors.length) {\n if (sort) nestedErrors.sort(sort); //show parent errors after the nested ones: name.first, name\n\n if (errors.length) nestedErrors.push(...errors);\n errors = nestedErrors;\n }\n\n if (errors.length) {\n callback(new ValidationError(errors, value, path), value);\n return;\n }\n\n callback(null, value);\n }\n });\n }\n}","import { getter } from 'property-expr';\nconst prefixes = {\n context: '$',\n value: '.'\n};\nexport function create(key, options) {\n return new Reference(key, options);\n}\nexport default class Reference {\n constructor(key, options = {}) {\n this.key = void 0;\n this.isContext = void 0;\n this.isValue = void 0;\n this.isSibling = void 0;\n this.path = void 0;\n this.getter = void 0;\n this.map = void 0;\n if (typeof key !== 'string') throw new TypeError('ref must be a string, got: ' + key);\n this.key = key.trim();\n if (key === '') throw new TypeError('ref must be a non-empty string');\n this.isContext = this.key[0] === prefixes.context;\n this.isValue = this.key[0] === prefixes.value;\n this.isSibling = !this.isContext && !this.isValue;\n let prefix = this.isContext ? prefixes.context : this.isValue ? prefixes.value : '';\n this.path = this.key.slice(prefix.length);\n this.getter = this.path && getter(this.path, true);\n this.map = options.map;\n }\n\n getValue(value, parent, context) {\n let result = this.isContext ? context : this.isValue ? value : parent;\n if (this.getter) result = this.getter(result || {});\n if (this.map) result = this.map(result);\n return result;\n }\n /**\n *\n * @param {*} value\n * @param {Object} options\n * @param {Object=} options.context\n * @param {Object=} options.parent\n */\n\n\n cast(value, options) {\n return this.getValue(value, options == null ? void 0 : options.parent, options == null ? void 0 : options.context);\n }\n\n resolve() {\n return this;\n }\n\n describe() {\n return {\n type: 'ref',\n key: this.key\n };\n }\n\n toString() {\n return `Ref(${this.key})`;\n }\n\n static isRef(value) {\n return value && value.__isYupRef;\n }\n\n} // @ts-ignore\n\nReference.prototype.__isYupRef = true;","function _extends() { _extends = Object.assign || 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); }\n\nfunction _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }\n\nimport mapValues from 'lodash/mapValues';\nimport ValidationError from '../ValidationError';\nimport Ref from '../Reference';\nexport default function createValidation(config) {\n function validate(_ref, cb) {\n let {\n value,\n path = '',\n label,\n options,\n originalValue,\n sync\n } = _ref,\n rest = _objectWithoutPropertiesLoose(_ref, [\"value\", \"path\", \"label\", \"options\", \"originalValue\", \"sync\"]);\n\n const {\n name,\n test,\n params,\n message\n } = config;\n let {\n parent,\n context\n } = options;\n\n function resolve(item) {\n return Ref.isRef(item) ? item.getValue(value, parent, context) : item;\n }\n\n function createError(overrides = {}) {\n const nextParams = mapValues(_extends({\n value,\n originalValue,\n label,\n path: overrides.path || path\n }, params, overrides.params), resolve);\n const error = new ValidationError(ValidationError.formatError(overrides.message || message, nextParams), value, nextParams.path, overrides.type || name);\n error.params = nextParams;\n return error;\n }\n\n let ctx = _extends({\n path,\n parent,\n type: name,\n createError,\n resolve,\n options,\n originalValue\n }, rest);\n\n if (!sync) {\n try {\n Promise.resolve(test.call(ctx, value, ctx)).then(validOrError => {\n if (ValidationError.isError(validOrError)) cb(validOrError);else if (!validOrError) cb(createError());else cb(null, validOrError);\n }).catch(cb);\n } catch (err) {\n cb(err);\n }\n\n return;\n }\n\n let result;\n\n try {\n var _ref2;\n\n result = test.call(ctx, value, ctx);\n\n if (typeof ((_ref2 = result) == null ? void 0 : _ref2.then) === 'function') {\n throw new Error(`Validation test of type: \"${ctx.type}\" returned a Promise during a synchronous validate. ` + `This test will finish after the validate call has returned`);\n }\n } catch (err) {\n cb(err);\n return;\n }\n\n if (ValidationError.isError(result)) cb(result);else if (!result) cb(createError());else cb(null, result);\n }\n\n validate.OPTIONS = config;\n return validate;\n}","import { forEach } from 'property-expr';\n\nlet trim = part => part.substr(0, part.length - 1).substr(1);\n\nexport function getIn(schema, path, value, context = value) {\n let parent, lastPart, lastPartDebug; // root path: ''\n\n if (!path) return {\n parent,\n parentPath: path,\n schema\n };\n forEach(path, (_part, isBracket, isArray) => {\n let part = isBracket ? trim(_part) : _part;\n schema = schema.resolve({\n context,\n parent,\n value\n });\n\n if (schema.innerType) {\n let idx = isArray ? parseInt(part, 10) : 0;\n\n if (value && idx >= value.length) {\n throw new Error(`Yup.reach cannot resolve an array item at index: ${_part}, in the path: ${path}. ` + `because there is no value at that index. `);\n }\n\n parent = value;\n value = value && value[idx];\n schema = schema.innerType;\n } // sometimes the array index part of a path doesn't exist: \"nested.arr.child\"\n // in these cases the current part is the next schema and should be processed\n // in this iteration. For cases where the index signature is included this\n // check will fail and we'll handle the `child` part on the next iteration like normal\n\n\n if (!isArray) {\n if (!schema.fields || !schema.fields[part]) throw new Error(`The schema does not contain the path: ${path}. ` + `(failed at: ${lastPartDebug} which is a type: \"${schema._type}\")`);\n parent = value;\n value = value && value[part];\n schema = schema.fields[part];\n }\n\n lastPart = part;\n lastPartDebug = isBracket ? '[' + _part + ']' : '.' + _part;\n });\n return {\n schema,\n parent,\n parentPath: lastPart\n };\n}\n\nconst reach = (obj, path, value, context) => getIn(obj, path, value, context).schema;\n\nexport default reach;","import Reference from '../Reference';\nexport default class ReferenceSet {\n constructor() {\n this.list = void 0;\n this.refs = void 0;\n this.list = new Set();\n this.refs = new Map();\n }\n\n get size() {\n return this.list.size + this.refs.size;\n }\n\n describe() {\n const description = [];\n\n for (const item of this.list) description.push(item);\n\n for (const [, ref] of this.refs) description.push(ref.describe());\n\n return description;\n }\n\n toArray() {\n return Array.from(this.list).concat(Array.from(this.refs.values()));\n }\n\n resolveAll(resolve) {\n return this.toArray().reduce((acc, e) => acc.concat(Reference.isRef(e) ? resolve(e) : e), []);\n }\n\n add(value) {\n Reference.isRef(value) ? this.refs.set(value.key, value) : this.list.add(value);\n }\n\n delete(value) {\n Reference.isRef(value) ? this.refs.delete(value.key) : this.list.delete(value);\n }\n\n clone() {\n const next = new ReferenceSet();\n next.list = new Set(this.list);\n next.refs = new Map(this.refs);\n return next;\n }\n\n merge(newItems, removeItems) {\n const next = this.clone();\n newItems.list.forEach(value => next.add(value));\n newItems.refs.forEach(value => next.add(value));\n removeItems.list.forEach(value => next.delete(value));\n removeItems.refs.forEach(value => next.delete(value));\n return next;\n }\n\n}","function _extends() { _extends = Object.assign || 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); }\n\n// @ts-ignore\nimport cloneDeep from 'nanoclone';\nimport { mixed as locale } from './locale';\nimport Condition from './Condition';\nimport runTests from './util/runTests';\nimport createValidation from './util/createValidation';\nimport printValue from './util/printValue';\nimport Ref from './Reference';\nimport { getIn } from './util/reach';\nimport ValidationError from './ValidationError';\nimport ReferenceSet from './util/ReferenceSet';\nimport toArray from './util/toArray'; // const UNSET = 'unset' as const;\n\nexport default class BaseSchema {\n constructor(options) {\n this.deps = [];\n this.tests = void 0;\n this.transforms = void 0;\n this.conditions = [];\n this._mutate = void 0;\n this._typeError = void 0;\n this._whitelist = new ReferenceSet();\n this._blacklist = new ReferenceSet();\n this.exclusiveTests = Object.create(null);\n this.spec = void 0;\n this.tests = [];\n this.transforms = [];\n this.withMutation(() => {\n this.typeError(locale.notType);\n });\n this.type = (options == null ? void 0 : options.type) || 'mixed';\n this.spec = _extends({\n strip: false,\n strict: false,\n abortEarly: true,\n recursive: true,\n nullable: false,\n presence: 'optional'\n }, options == null ? void 0 : options.spec);\n } // TODO: remove\n\n\n get _type() {\n return this.type;\n }\n\n _typeCheck(_value) {\n return true;\n }\n\n clone(spec) {\n if (this._mutate) {\n if (spec) Object.assign(this.spec, spec);\n return this;\n } // if the nested value is a schema we can skip cloning, since\n // they are already immutable\n\n\n const next = Object.create(Object.getPrototypeOf(this)); // @ts-expect-error this is readonly\n\n next.type = this.type;\n next._typeError = this._typeError;\n next._whitelistError = this._whitelistError;\n next._blacklistError = this._blacklistError;\n next._whitelist = this._whitelist.clone();\n next._blacklist = this._blacklist.clone();\n next.exclusiveTests = _extends({}, this.exclusiveTests); // @ts-expect-error this is readonly\n\n next.deps = [...this.deps];\n next.conditions = [...this.conditions];\n next.tests = [...this.tests];\n next.transforms = [...this.transforms];\n next.spec = cloneDeep(_extends({}, this.spec, spec));\n return next;\n }\n\n label(label) {\n let next = this.clone();\n next.spec.label = label;\n return next;\n }\n\n meta(...args) {\n if (args.length === 0) return this.spec.meta;\n let next = this.clone();\n next.spec.meta = Object.assign(next.spec.meta || {}, args[0]);\n return next;\n } // withContext(): BaseSchema<\n // TCast,\n // TContext,\n // TOutput\n // > {\n // return this as any;\n // }\n\n\n withMutation(fn) {\n let before = this._mutate;\n this._mutate = true;\n let result = fn(this);\n this._mutate = before;\n return result;\n }\n\n concat(schema) {\n if (!schema || schema === this) return this;\n if (schema.type !== this.type && this.type !== 'mixed') throw new TypeError(`You cannot \\`concat()\\` schema's of different types: ${this.type} and ${schema.type}`);\n let base = this;\n let combined = schema.clone();\n\n const mergedSpec = _extends({}, base.spec, combined.spec); // if (combined.spec.nullable === UNSET)\n // mergedSpec.nullable = base.spec.nullable;\n // if (combined.spec.presence === UNSET)\n // mergedSpec.presence = base.spec.presence;\n\n\n combined.spec = mergedSpec;\n combined._typeError || (combined._typeError = base._typeError);\n combined._whitelistError || (combined._whitelistError = base._whitelistError);\n combined._blacklistError || (combined._blacklistError = base._blacklistError); // manually merge the blacklist/whitelist (the other `schema` takes\n // precedence in case of conflicts)\n\n combined._whitelist = base._whitelist.merge(schema._whitelist, schema._blacklist);\n combined._blacklist = base._blacklist.merge(schema._blacklist, schema._whitelist); // start with the current tests\n\n combined.tests = base.tests;\n combined.exclusiveTests = base.exclusiveTests; // manually add the new tests to ensure\n // the deduping logic is consistent\n\n combined.withMutation(next => {\n schema.tests.forEach(fn => {\n next.test(fn.OPTIONS);\n });\n });\n combined.transforms = [...base.transforms, ...combined.transforms];\n return combined;\n }\n\n isType(v) {\n if (this.spec.nullable && v === null) return true;\n return this._typeCheck(v);\n }\n\n resolve(options) {\n let schema = this;\n\n if (schema.conditions.length) {\n let conditions = schema.conditions;\n schema = schema.clone();\n schema.conditions = [];\n schema = conditions.reduce((schema, condition) => condition.resolve(schema, options), schema);\n schema = schema.resolve(options);\n }\n\n return schema;\n }\n /**\n *\n * @param {*} value\n * @param {Object} options\n * @param {*=} options.parent\n * @param {*=} options.context\n */\n\n\n cast(value, options = {}) {\n let resolvedSchema = this.resolve(_extends({\n value\n }, options));\n\n let result = resolvedSchema._cast(value, options);\n\n if (value !== undefined && options.assert !== false && resolvedSchema.isType(result) !== true) {\n let formattedValue = printValue(value);\n let formattedResult = printValue(result);\n throw new TypeError(`The value of ${options.path || 'field'} could not be cast to a value ` + `that satisfies the schema type: \"${resolvedSchema._type}\". \\n\\n` + `attempted value: ${formattedValue} \\n` + (formattedResult !== formattedValue ? `result of cast: ${formattedResult}` : ''));\n }\n\n return result;\n }\n\n _cast(rawValue, _options) {\n let value = rawValue === undefined ? rawValue : this.transforms.reduce((value, fn) => fn.call(this, value, rawValue, this), rawValue);\n\n if (value === undefined) {\n value = this.getDefault();\n }\n\n return value;\n }\n\n _validate(_value, options = {}, cb) {\n let {\n sync,\n path,\n from = [],\n originalValue = _value,\n strict = this.spec.strict,\n abortEarly = this.spec.abortEarly\n } = options;\n let value = _value;\n\n if (!strict) {\n // this._validating = true;\n value = this._cast(value, _extends({\n assert: false\n }, options)); // this._validating = false;\n } // value is cast, we can check if it meets type requirements\n\n\n let args = {\n value,\n path,\n options,\n originalValue,\n schema: this,\n label: this.spec.label,\n sync,\n from\n };\n let initialTests = [];\n if (this._typeError) initialTests.push(this._typeError);\n let finalTests = [];\n if (this._whitelistError) finalTests.push(this._whitelistError);\n if (this._blacklistError) finalTests.push(this._blacklistError);\n runTests({\n args,\n value,\n path,\n sync,\n tests: initialTests,\n endEarly: abortEarly\n }, err => {\n if (err) return void cb(err, value);\n runTests({\n tests: this.tests.concat(finalTests),\n args,\n path,\n sync,\n value,\n endEarly: abortEarly\n }, cb);\n });\n }\n\n validate(value, options, maybeCb) {\n let schema = this.resolve(_extends({}, options, {\n value\n })); // callback case is for nested validations\n\n return typeof maybeCb === 'function' ? schema._validate(value, options, maybeCb) : new Promise((resolve, reject) => schema._validate(value, options, (err, value) => {\n if (err) reject(err);else resolve(value);\n }));\n }\n\n validateSync(value, options) {\n let schema = this.resolve(_extends({}, options, {\n value\n }));\n let result;\n\n schema._validate(value, _extends({}, options, {\n sync: true\n }), (err, value) => {\n if (err) throw err;\n result = value;\n });\n\n return result;\n }\n\n isValid(value, options) {\n return this.validate(value, options).then(() => true, err => {\n if (ValidationError.isError(err)) return false;\n throw err;\n });\n }\n\n isValidSync(value, options) {\n try {\n this.validateSync(value, options);\n return true;\n } catch (err) {\n if (ValidationError.isError(err)) return false;\n throw err;\n }\n }\n\n _getDefault() {\n let defaultValue = this.spec.default;\n\n if (defaultValue == null) {\n return defaultValue;\n }\n\n return typeof defaultValue === 'function' ? defaultValue.call(this) : cloneDeep(defaultValue);\n }\n\n getDefault(options) {\n let schema = this.resolve(options || {});\n return schema._getDefault();\n }\n\n default(def) {\n if (arguments.length === 0) {\n return this._getDefault();\n }\n\n let next = this.clone({\n default: def\n });\n return next;\n }\n\n strict(isStrict = true) {\n let next = this.clone();\n next.spec.strict = isStrict;\n return next;\n }\n\n _isPresent(value) {\n return value != null;\n }\n\n defined(message = locale.defined) {\n return this.test({\n message,\n name: 'defined',\n exclusive: true,\n\n test(value) {\n return value !== undefined;\n }\n\n });\n }\n\n required(message = locale.required) {\n return this.clone({\n presence: 'required'\n }).withMutation(s => s.test({\n message,\n name: 'required',\n exclusive: true,\n\n test(value) {\n return this.schema._isPresent(value);\n }\n\n }));\n }\n\n notRequired() {\n let next = this.clone({\n presence: 'optional'\n });\n next.tests = next.tests.filter(test => test.OPTIONS.name !== 'required');\n return next;\n }\n\n nullable(isNullable = true) {\n let next = this.clone({\n nullable: isNullable !== false\n });\n return next;\n }\n\n transform(fn) {\n let next = this.clone();\n next.transforms.push(fn);\n return next;\n }\n /**\n * Adds a test function to the schema's queue of tests.\n * tests can be exclusive or non-exclusive.\n *\n * - exclusive tests, will replace any existing tests of the same name.\n * - non-exclusive: can be stacked\n *\n * If a non-exclusive test is added to a schema with an exclusive test of the same name\n * the exclusive test is removed and further tests of the same name will be stacked.\n *\n * If an exclusive test is added to a schema with non-exclusive tests of the same name\n * the previous tests are removed and further tests of the same name will replace each other.\n */\n\n\n test(...args) {\n let opts;\n\n if (args.length === 1) {\n if (typeof args[0] === 'function') {\n opts = {\n test: args[0]\n };\n } else {\n opts = args[0];\n }\n } else if (args.length === 2) {\n opts = {\n name: args[0],\n test: args[1]\n };\n } else {\n opts = {\n name: args[0],\n message: args[1],\n test: args[2]\n };\n }\n\n if (opts.message === undefined) opts.message = locale.default;\n if (typeof opts.test !== 'function') throw new TypeError('`test` is a required parameters');\n let next = this.clone();\n let validate = createValidation(opts);\n let isExclusive = opts.exclusive || opts.name && next.exclusiveTests[opts.name] === true;\n\n if (opts.exclusive) {\n if (!opts.name) throw new TypeError('Exclusive tests must provide a unique `name` identifying the test');\n }\n\n if (opts.name) next.exclusiveTests[opts.name] = !!opts.exclusive;\n next.tests = next.tests.filter(fn => {\n if (fn.OPTIONS.name === opts.name) {\n if (isExclusive) return false;\n if (fn.OPTIONS.test === validate.OPTIONS.test) return false;\n }\n\n return true;\n });\n next.tests.push(validate);\n return next;\n }\n\n when(keys, options) {\n if (!Array.isArray(keys) && typeof keys !== 'string') {\n options = keys;\n keys = '.';\n }\n\n let next = this.clone();\n let deps = toArray(keys).map(key => new Ref(key));\n deps.forEach(dep => {\n // @ts-ignore\n if (dep.isSibling) next.deps.push(dep.key);\n });\n next.conditions.push(new Condition(deps, options));\n return next;\n }\n\n typeError(message) {\n let next = this.clone();\n next._typeError = createValidation({\n message,\n name: 'typeError',\n\n test(value) {\n if (value !== undefined && !this.schema.isType(value)) return this.createError({\n params: {\n type: this.schema._type\n }\n });\n return true;\n }\n\n });\n return next;\n }\n\n oneOf(enums, message = locale.oneOf) {\n let next = this.clone();\n enums.forEach(val => {\n next._whitelist.add(val);\n\n next._blacklist.delete(val);\n });\n next._whitelistError = createValidation({\n message,\n name: 'oneOf',\n\n test(value) {\n if (value === undefined) return true;\n let valids = this.schema._whitelist;\n let resolved = valids.resolveAll(this.resolve);\n return resolved.includes(value) ? true : this.createError({\n params: {\n values: valids.toArray().join(', '),\n resolved\n }\n });\n }\n\n });\n return next;\n }\n\n notOneOf(enums, message = locale.notOneOf) {\n let next = this.clone();\n enums.forEach(val => {\n next._blacklist.add(val);\n\n next._whitelist.delete(val);\n });\n next._blacklistError = createValidation({\n message,\n name: 'notOneOf',\n\n test(value) {\n let invalids = this.schema._blacklist;\n let resolved = invalids.resolveAll(this.resolve);\n if (resolved.includes(value)) return this.createError({\n params: {\n values: invalids.toArray().join(', '),\n resolved\n }\n });\n return true;\n }\n\n });\n return next;\n }\n\n strip(strip = true) {\n let next = this.clone();\n next.spec.strip = strip;\n return next;\n }\n\n describe() {\n const next = this.clone();\n const {\n label,\n meta\n } = next.spec;\n const description = {\n meta,\n label,\n type: next.type,\n oneOf: next._whitelist.describe(),\n notOneOf: next._blacklist.describe(),\n tests: next.tests.map(fn => ({\n name: fn.OPTIONS.name,\n params: fn.OPTIONS.params\n })).filter((n, idx, list) => list.findIndex(c => c.name === n.name) === idx)\n };\n return description;\n }\n\n} // eslint-disable-next-line @typescript-eslint/no-unused-vars\n\n// @ts-expect-error\nBaseSchema.prototype.__isYupSchema__ = true;\n\nfor (const method of ['validate', 'validateSync']) BaseSchema.prototype[`${method}At`] = function (path, value, options = {}) {\n const {\n parent,\n parentPath,\n schema\n } = getIn(this, path, value, options.context);\n return schema[method](parent && parent[parentPath], _extends({}, options, {\n parent,\n path\n }));\n};\n\nfor (const alias of ['equals', 'is']) BaseSchema.prototype[alias] = BaseSchema.prototype.oneOf;\n\nfor (const alias of ['not', 'nope']) BaseSchema.prototype[alias] = BaseSchema.prototype.notOneOf;\n\nBaseSchema.prototype.optional = BaseSchema.prototype.notRequired;","import BaseSchema from './schema';\nconst Mixed = BaseSchema;\nexport default Mixed;\nexport function create() {\n return new Mixed();\n} // XXX: this is using the Base schema so that `addMethod(mixed)` works as a base class\n\ncreate.prototype = Mixed.prototype;","const isAbsent = value => value == null;\n\nexport default isAbsent;","import BaseSchema from './schema';\nimport { boolean as locale } from './locale';\nimport isAbsent from './util/isAbsent';\nexport function create() {\n return new BooleanSchema();\n}\nexport default class BooleanSchema extends BaseSchema {\n constructor() {\n super({\n type: 'boolean'\n });\n this.withMutation(() => {\n this.transform(function (value) {\n if (!this.isType(value)) {\n if (/^(true|1)$/i.test(String(value))) return true;\n if (/^(false|0)$/i.test(String(value))) return false;\n }\n\n return value;\n });\n });\n }\n\n _typeCheck(v) {\n if (v instanceof Boolean) v = v.valueOf();\n return typeof v === 'boolean';\n }\n\n isTrue(message = locale.isValue) {\n return this.test({\n message,\n name: 'is-value',\n exclusive: true,\n params: {\n value: 'true'\n },\n\n test(value) {\n return isAbsent(value) || value === true;\n }\n\n });\n }\n\n isFalse(message = locale.isValue) {\n return this.test({\n message,\n name: 'is-value',\n exclusive: true,\n params: {\n value: 'false'\n },\n\n test(value) {\n return isAbsent(value) || value === false;\n }\n\n });\n }\n\n}\ncreate.prototype = BooleanSchema.prototype;","import { string as locale } from './locale';\nimport isAbsent from './util/isAbsent';\nimport BaseSchema from './schema'; // eslint-disable-next-line\n\nlet rEmail = /^((([a-z]|\\d|[!#\\$%&'\\*\\+\\-\\/=\\?\\^_`{\\|}~]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])+(\\.([a-z]|\\d|[!#\\$%&'\\*\\+\\-\\/=\\?\\^_`{\\|}~]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])+)*)|((\\x22)((((\\x20|\\x09)*(\\x0d\\x0a))?(\\x20|\\x09)+)?(([\\x01-\\x08\\x0b\\x0c\\x0e-\\x1f\\x7f]|\\x21|[\\x23-\\x5b]|[\\x5d-\\x7e]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(\\\\([\\x01-\\x09\\x0b\\x0c\\x0d-\\x7f]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]))))*(((\\x20|\\x09)*(\\x0d\\x0a))?(\\x20|\\x09)+)?(\\x22)))@((([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])*([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])))\\.)+(([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])*([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])))$/i; // eslint-disable-next-line\n\nlet rUrl = /^((https?|ftp):)?\\/\\/(((([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(%[\\da-f]{2})|[!\\$&'\\(\\)\\*\\+,;=]|:)*@)?(((\\d|[1-9]\\d|1\\d\\d|2[0-4]\\d|25[0-5])\\.(\\d|[1-9]\\d|1\\d\\d|2[0-4]\\d|25[0-5])\\.(\\d|[1-9]\\d|1\\d\\d|2[0-4]\\d|25[0-5])\\.(\\d|[1-9]\\d|1\\d\\d|2[0-4]\\d|25[0-5]))|((([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])*([a-z]|\\d|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])))\\.)+(([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])*([a-z]|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])))\\.?)(:\\d*)?)(\\/((([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(%[\\da-f]{2})|[!\\$&'\\(\\)\\*\\+,;=]|:|@)+(\\/(([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(%[\\da-f]{2})|[!\\$&'\\(\\)\\*\\+,;=]|:|@)*)*)?)?(\\?((([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(%[\\da-f]{2})|[!\\$&'\\(\\)\\*\\+,;=]|:|@)|[\\uE000-\\uF8FF]|\\/|\\?)*)?(\\#((([a-z]|\\d|-|\\.|_|~|[\\u00A0-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF])|(%[\\da-f]{2})|[!\\$&'\\(\\)\\*\\+,;=]|:|@)|\\/|\\?)*)?$/i; // eslint-disable-next-line\n\nlet rUUID = /^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;\n\nlet isTrimmed = value => isAbsent(value) || value === value.trim();\n\nlet objStringTag = {}.toString();\nexport function create() {\n return new StringSchema();\n}\nexport default class StringSchema extends BaseSchema {\n constructor() {\n super({\n type: 'string'\n });\n this.withMutation(() => {\n this.transform(function (value) {\n if (this.isType(value)) return value;\n if (Array.isArray(value)) return value;\n const strValue = value != null && value.toString ? value.toString() : value;\n if (strValue === objStringTag) return value;\n return strValue;\n });\n });\n }\n\n _typeCheck(value) {\n if (value instanceof String) value = value.valueOf();\n return typeof value === 'string';\n }\n\n _isPresent(value) {\n return super._isPresent(value) && !!value.length;\n }\n\n length(length, message = locale.length) {\n return this.test({\n message,\n name: 'length',\n exclusive: true,\n params: {\n length\n },\n\n test(value) {\n return isAbsent(value) || value.length === this.resolve(length);\n }\n\n });\n }\n\n min(min, message = locale.min) {\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n min\n },\n\n test(value) {\n return isAbsent(value) || value.length >= this.resolve(min);\n }\n\n });\n }\n\n max(max, message = locale.max) {\n return this.test({\n name: 'max',\n exclusive: true,\n message,\n params: {\n max\n },\n\n test(value) {\n return isAbsent(value) || value.length <= this.resolve(max);\n }\n\n });\n }\n\n matches(regex, options) {\n let excludeEmptyString = false;\n let message;\n let name;\n\n if (options) {\n if (typeof options === 'object') {\n ({\n excludeEmptyString = false,\n message,\n name\n } = options);\n } else {\n message = options;\n }\n }\n\n return this.test({\n name: name || 'matches',\n message: message || locale.matches,\n params: {\n regex\n },\n test: value => isAbsent(value) || value === '' && excludeEmptyString || value.search(regex) !== -1\n });\n }\n\n email(message = locale.email) {\n return this.matches(rEmail, {\n name: 'email',\n message,\n excludeEmptyString: true\n });\n }\n\n url(message = locale.url) {\n return this.matches(rUrl, {\n name: 'url',\n message,\n excludeEmptyString: true\n });\n }\n\n uuid(message = locale.uuid) {\n return this.matches(rUUID, {\n name: 'uuid',\n message,\n excludeEmptyString: false\n });\n } //-- transforms --\n\n\n ensure() {\n return this.default('').transform(val => val === null ? '' : val);\n }\n\n trim(message = locale.trim) {\n return this.transform(val => val != null ? val.trim() : val).test({\n message,\n name: 'trim',\n test: isTrimmed\n });\n }\n\n lowercase(message = locale.lowercase) {\n return this.transform(value => !isAbsent(value) ? value.toLowerCase() : value).test({\n message,\n name: 'string_case',\n exclusive: true,\n test: value => isAbsent(value) || value === value.toLowerCase()\n });\n }\n\n uppercase(message = locale.uppercase) {\n return this.transform(value => !isAbsent(value) ? value.toUpperCase() : value).test({\n message,\n name: 'string_case',\n exclusive: true,\n test: value => isAbsent(value) || value === value.toUpperCase()\n });\n }\n\n}\ncreate.prototype = StringSchema.prototype; //\n// String Interfaces\n//","import { number as locale } from './locale';\nimport isAbsent from './util/isAbsent';\nimport BaseSchema from './schema';\n\nlet isNaN = value => value != +value;\n\nexport function create() {\n return new NumberSchema();\n}\nexport default class NumberSchema extends BaseSchema {\n constructor() {\n super({\n type: 'number'\n });\n this.withMutation(() => {\n this.transform(function (value) {\n let parsed = value;\n\n if (typeof parsed === 'string') {\n parsed = parsed.replace(/\\s/g, '');\n if (parsed === '') return NaN; // don't use parseFloat to avoid positives on alpha-numeric strings\n\n parsed = +parsed;\n }\n\n if (this.isType(parsed)) return parsed;\n return parseFloat(parsed);\n });\n });\n }\n\n _typeCheck(value) {\n if (value instanceof Number) value = value.valueOf();\n return typeof value === 'number' && !isNaN(value);\n }\n\n min(min, message = locale.min) {\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n min\n },\n\n test(value) {\n return isAbsent(value) || value >= this.resolve(min);\n }\n\n });\n }\n\n max(max, message = locale.max) {\n return this.test({\n message,\n name: 'max',\n exclusive: true,\n params: {\n max\n },\n\n test(value) {\n return isAbsent(value) || value <= this.resolve(max);\n }\n\n });\n }\n\n lessThan(less, message = locale.lessThan) {\n return this.test({\n message,\n name: 'max',\n exclusive: true,\n params: {\n less\n },\n\n test(value) {\n return isAbsent(value) || value < this.resolve(less);\n }\n\n });\n }\n\n moreThan(more, message = locale.moreThan) {\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n more\n },\n\n test(value) {\n return isAbsent(value) || value > this.resolve(more);\n }\n\n });\n }\n\n positive(msg = locale.positive) {\n return this.moreThan(0, msg);\n }\n\n negative(msg = locale.negative) {\n return this.lessThan(0, msg);\n }\n\n integer(message = locale.integer) {\n return this.test({\n name: 'integer',\n message,\n test: val => isAbsent(val) || Number.isInteger(val)\n });\n }\n\n truncate() {\n return this.transform(value => !isAbsent(value) ? value | 0 : value);\n }\n\n round(method) {\n var _method;\n\n let avail = ['ceil', 'floor', 'round', 'trunc'];\n method = ((_method = method) == null ? void 0 : _method.toLowerCase()) || 'round'; // this exists for symemtry with the new Math.trunc\n\n if (method === 'trunc') return this.truncate();\n if (avail.indexOf(method.toLowerCase()) === -1) throw new TypeError('Only valid options for round() are: ' + avail.join(', '));\n return this.transform(value => !isAbsent(value) ? Math[method](value) : value);\n }\n\n}\ncreate.prototype = NumberSchema.prototype; //\n// Number Interfaces\n//","/* eslint-disable */\n\n/**\n *\n * Date.parse with progressive enhancement for ISO 8601 \n * NON-CONFORMANT EDITION.\n * © 2011 Colin Snover \n * Released under MIT license.\n */\n// 1 YYYY 2 MM 3 DD 4 HH 5 mm 6 ss 7 msec 8 Z 9 ± 10 tzHH 11 tzmm\nvar isoReg = /^(\\d{4}|[+\\-]\\d{6})(?:-?(\\d{2})(?:-?(\\d{2}))?)?(?:[ T]?(\\d{2}):?(\\d{2})(?::?(\\d{2})(?:[,\\.](\\d{1,}))?)?(?:(Z)|([+\\-])(\\d{2})(?::?(\\d{2}))?)?)?$/;\nexport default function parseIsoDate(date) {\n var numericKeys = [1, 4, 5, 6, 7, 10, 11],\n minutesOffset = 0,\n timestamp,\n struct;\n\n if (struct = isoReg.exec(date)) {\n // avoid NaN timestamps caused by “undefined” values being passed to Date.UTC\n for (var i = 0, k; k = numericKeys[i]; ++i) struct[k] = +struct[k] || 0; // allow undefined days and months\n\n\n struct[2] = (+struct[2] || 1) - 1;\n struct[3] = +struct[3] || 1; // allow arbitrary sub-second precision beyond milliseconds\n\n struct[7] = struct[7] ? String(struct[7]).substr(0, 3) : 0; // timestamps without timezone identifiers should be considered local time\n\n if ((struct[8] === undefined || struct[8] === '') && (struct[9] === undefined || struct[9] === '')) timestamp = +new Date(struct[1], struct[2], struct[3], struct[4], struct[5], struct[6], struct[7]);else {\n if (struct[8] !== 'Z' && struct[9] !== undefined) {\n minutesOffset = struct[10] * 60 + struct[11];\n if (struct[9] === '+') minutesOffset = 0 - minutesOffset;\n }\n\n timestamp = Date.UTC(struct[1], struct[2], struct[3], struct[4], struct[5] + minutesOffset, struct[6], struct[7]);\n }\n } else timestamp = Date.parse ? Date.parse(date) : NaN;\n\n return timestamp;\n}","// @ts-ignore\nimport isoParse from './util/isodate';\nimport { date as locale } from './locale';\nimport isAbsent from './util/isAbsent';\nimport Ref from './Reference';\nimport BaseSchema from './schema';\nlet invalidDate = new Date('');\n\nlet isDate = obj => Object.prototype.toString.call(obj) === '[object Date]';\n\nexport function create() {\n return new DateSchema();\n}\nexport default class DateSchema extends BaseSchema {\n constructor() {\n super({\n type: 'date'\n });\n this.withMutation(() => {\n this.transform(function (value) {\n if (this.isType(value)) return value;\n value = isoParse(value); // 0 is a valid timestamp equivalent to 1970-01-01T00:00:00Z(unix epoch) or before.\n\n return !isNaN(value) ? new Date(value) : invalidDate;\n });\n });\n }\n\n _typeCheck(v) {\n return isDate(v) && !isNaN(v.getTime());\n }\n\n prepareParam(ref, name) {\n let param;\n\n if (!Ref.isRef(ref)) {\n let cast = this.cast(ref);\n if (!this._typeCheck(cast)) throw new TypeError(`\\`${name}\\` must be a Date or a value that can be \\`cast()\\` to a Date`);\n param = cast;\n } else {\n param = ref;\n }\n\n return param;\n }\n\n min(min, message = locale.min) {\n let limit = this.prepareParam(min, 'min');\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n min\n },\n\n test(value) {\n return isAbsent(value) || value >= this.resolve(limit);\n }\n\n });\n }\n\n max(max, message = locale.max) {\n let limit = this.prepareParam(max, 'max');\n return this.test({\n message,\n name: 'max',\n exclusive: true,\n params: {\n max\n },\n\n test(value) {\n return isAbsent(value) || value <= this.resolve(limit);\n }\n\n });\n }\n\n}\nDateSchema.INVALID_DATE = invalidDate;\ncreate.prototype = DateSchema.prototype;\ncreate.INVALID_DATE = invalidDate;","import has from 'lodash/has'; // @ts-expect-error\n\nimport toposort from 'toposort';\nimport { split } from 'property-expr';\nimport Ref from '../Reference';\nimport isSchema from './isSchema';\nexport default function sortFields(fields, excludedEdges = []) {\n let edges = [];\n let nodes = new Set();\n let excludes = new Set(excludedEdges.map(([a, b]) => `${a}-${b}`));\n\n function addNode(depPath, key) {\n let node = split(depPath)[0];\n nodes.add(node);\n if (!excludes.has(`${key}-${node}`)) edges.push([key, node]);\n }\n\n for (const key in fields) if (has(fields, key)) {\n let value = fields[key];\n nodes.add(key);\n if (Ref.isRef(value) && value.isSibling) addNode(value.path, key);else if (isSchema(value) && 'deps' in value) value.deps.forEach(path => addNode(path, key));\n }\n\n return toposort.array(Array.from(nodes), edges).reverse();\n}","function findIndex(arr, err) {\n let idx = Infinity;\n arr.some((key, ii) => {\n var _err$path;\n\n if (((_err$path = err.path) == null ? void 0 : _err$path.indexOf(key)) !== -1) {\n idx = ii;\n return true;\n }\n });\n return idx;\n}\n\nexport default function sortByKeyOrder(keys) {\n return (a, b) => {\n return findIndex(keys, a) - findIndex(keys, b);\n };\n}","function _extends() { _extends = Object.assign || 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); }\n\nimport has from 'lodash/has';\nimport snakeCase from 'lodash/snakeCase';\nimport camelCase from 'lodash/camelCase';\nimport mapKeys from 'lodash/mapKeys';\nimport mapValues from 'lodash/mapValues';\nimport { getter } from 'property-expr';\nimport { object as locale } from './locale';\nimport sortFields from './util/sortFields';\nimport sortByKeyOrder from './util/sortByKeyOrder';\nimport runTests from './util/runTests';\nimport ValidationError from './ValidationError';\nimport BaseSchema from './schema';\n\nlet isObject = obj => Object.prototype.toString.call(obj) === '[object Object]';\n\nfunction unknown(ctx, value) {\n let known = Object.keys(ctx.fields);\n return Object.keys(value).filter(key => known.indexOf(key) === -1);\n}\n\nconst defaultSort = sortByKeyOrder([]);\nexport default class ObjectSchema extends BaseSchema {\n constructor(spec) {\n super({\n type: 'object'\n });\n this.fields = Object.create(null);\n this._sortErrors = defaultSort;\n this._nodes = [];\n this._excludedEdges = [];\n this.withMutation(() => {\n this.transform(function coerce(value) {\n if (typeof value === 'string') {\n try {\n value = JSON.parse(value);\n } catch (err) {\n value = null;\n }\n }\n\n if (this.isType(value)) return value;\n return null;\n });\n\n if (spec) {\n this.shape(spec);\n }\n });\n }\n\n _typeCheck(value) {\n return isObject(value) || typeof value === 'function';\n }\n\n _cast(_value, options = {}) {\n var _options$stripUnknown;\n\n let value = super._cast(_value, options); //should ignore nulls here\n\n\n if (value === undefined) return this.getDefault();\n if (!this._typeCheck(value)) return value;\n let fields = this.fields;\n let strip = (_options$stripUnknown = options.stripUnknown) != null ? _options$stripUnknown : this.spec.noUnknown;\n\n let props = this._nodes.concat(Object.keys(value).filter(v => this._nodes.indexOf(v) === -1));\n\n let intermediateValue = {}; // is filled during the transform below\n\n let innerOptions = _extends({}, options, {\n parent: intermediateValue,\n __validating: options.__validating || false\n });\n\n let isChanged = false;\n\n for (const prop of props) {\n let field = fields[prop];\n let exists = has(value, prop);\n\n if (field) {\n let fieldValue;\n let inputValue = value[prop]; // safe to mutate since this is fired in sequence\n\n innerOptions.path = (options.path ? `${options.path}.` : '') + prop; // innerOptions.value = value[prop];\n\n field = field.resolve({\n value: inputValue,\n context: options.context,\n parent: intermediateValue\n });\n let fieldSpec = 'spec' in field ? field.spec : undefined;\n let strict = fieldSpec == null ? void 0 : fieldSpec.strict;\n\n if (fieldSpec == null ? void 0 : fieldSpec.strip) {\n isChanged = isChanged || prop in value;\n continue;\n }\n\n fieldValue = !options.__validating || !strict ? // TODO: use _cast, this is double resolving\n field.cast(value[prop], innerOptions) : value[prop];\n\n if (fieldValue !== undefined) {\n intermediateValue[prop] = fieldValue;\n }\n } else if (exists && !strip) {\n intermediateValue[prop] = value[prop];\n }\n\n if (intermediateValue[prop] !== value[prop]) {\n isChanged = true;\n }\n }\n\n return isChanged ? intermediateValue : value;\n }\n\n _validate(_value, opts = {}, callback) {\n let errors = [];\n let {\n sync,\n from = [],\n originalValue = _value,\n abortEarly = this.spec.abortEarly,\n recursive = this.spec.recursive\n } = opts;\n from = [{\n schema: this,\n value: originalValue\n }, ...from]; // this flag is needed for handling `strict` correctly in the context of\n // validation vs just casting. e.g strict() on a field is only used when validating\n\n opts.__validating = true;\n opts.originalValue = originalValue;\n opts.from = from;\n\n super._validate(_value, opts, (err, value) => {\n if (err) {\n if (!ValidationError.isError(err) || abortEarly) {\n return void callback(err, value);\n }\n\n errors.push(err);\n }\n\n if (!recursive || !isObject(value)) {\n callback(errors[0] || null, value);\n return;\n }\n\n originalValue = originalValue || value;\n\n let tests = this._nodes.map(key => (_, cb) => {\n let path = key.indexOf('.') === -1 ? (opts.path ? `${opts.path}.` : '') + key : `${opts.path || ''}[\"${key}\"]`;\n let field = this.fields[key];\n\n if (field && 'validate' in field) {\n field.validate(value[key], _extends({}, opts, {\n // @ts-ignore\n path,\n from,\n // inner fields are always strict:\n // 1. this isn't strict so the casting will also have cast inner values\n // 2. this is strict in which case the nested values weren't cast either\n strict: true,\n parent: value,\n originalValue: originalValue[key]\n }), cb);\n return;\n }\n\n cb(null);\n });\n\n runTests({\n sync,\n tests,\n value,\n errors,\n endEarly: abortEarly,\n sort: this._sortErrors,\n path: opts.path\n }, callback);\n });\n }\n\n clone(spec) {\n const next = super.clone(spec);\n next.fields = _extends({}, this.fields);\n next._nodes = this._nodes;\n next._excludedEdges = this._excludedEdges;\n next._sortErrors = this._sortErrors;\n return next;\n }\n\n concat(schema) {\n let next = super.concat(schema);\n let nextFields = next.fields;\n\n for (let [field, schemaOrRef] of Object.entries(this.fields)) {\n const target = nextFields[field];\n\n if (target === undefined) {\n nextFields[field] = schemaOrRef;\n } else if (target instanceof BaseSchema && schemaOrRef instanceof BaseSchema) {\n nextFields[field] = schemaOrRef.concat(target);\n }\n }\n\n return next.withMutation(() => next.shape(nextFields, this._excludedEdges));\n }\n\n getDefaultFromShape() {\n let dft = {};\n\n this._nodes.forEach(key => {\n const field = this.fields[key];\n dft[key] = 'default' in field ? field.getDefault() : undefined;\n });\n\n return dft;\n }\n\n _getDefault() {\n if ('default' in this.spec) {\n return super._getDefault();\n } // if there is no default set invent one\n\n\n if (!this._nodes.length) {\n return undefined;\n }\n\n return this.getDefaultFromShape();\n }\n\n shape(additions, excludes = []) {\n let next = this.clone();\n let fields = Object.assign(next.fields, additions);\n next.fields = fields;\n next._sortErrors = sortByKeyOrder(Object.keys(fields));\n\n if (excludes.length) {\n // this is a convenience for when users only supply a single pair\n if (!Array.isArray(excludes[0])) excludes = [excludes];\n next._excludedEdges = [...next._excludedEdges, ...excludes];\n }\n\n next._nodes = sortFields(fields, next._excludedEdges);\n return next;\n }\n\n pick(keys) {\n const picked = {};\n\n for (const key of keys) {\n if (this.fields[key]) picked[key] = this.fields[key];\n }\n\n return this.clone().withMutation(next => {\n next.fields = {};\n return next.shape(picked);\n });\n }\n\n omit(keys) {\n const next = this.clone();\n const fields = next.fields;\n next.fields = {};\n\n for (const key of keys) {\n delete fields[key];\n }\n\n return next.withMutation(() => next.shape(fields));\n }\n\n from(from, to, alias) {\n let fromGetter = getter(from, true);\n return this.transform(obj => {\n if (obj == null) return obj;\n let newObj = obj;\n\n if (has(obj, from)) {\n newObj = _extends({}, obj);\n if (!alias) delete newObj[from];\n newObj[to] = fromGetter(obj);\n }\n\n return newObj;\n });\n }\n\n noUnknown(noAllow = true, message = locale.noUnknown) {\n if (typeof noAllow === 'string') {\n message = noAllow;\n noAllow = true;\n }\n\n let next = this.test({\n name: 'noUnknown',\n exclusive: true,\n message: message,\n\n test(value) {\n if (value == null) return true;\n const unknownKeys = unknown(this.schema, value);\n return !noAllow || unknownKeys.length === 0 || this.createError({\n params: {\n unknown: unknownKeys.join(', ')\n }\n });\n }\n\n });\n next.spec.noUnknown = noAllow;\n return next;\n }\n\n unknown(allow = true, message = locale.noUnknown) {\n return this.noUnknown(!allow, message);\n }\n\n transformKeys(fn) {\n return this.transform(obj => obj && mapKeys(obj, (_, key) => fn(key)));\n }\n\n camelCase() {\n return this.transformKeys(camelCase);\n }\n\n snakeCase() {\n return this.transformKeys(snakeCase);\n }\n\n constantCase() {\n return this.transformKeys(key => snakeCase(key).toUpperCase());\n }\n\n describe() {\n let base = super.describe();\n base.fields = mapValues(this.fields, value => value.describe());\n return base;\n }\n\n}\nexport function create(spec) {\n return new ObjectSchema(spec);\n}\ncreate.prototype = ObjectSchema.prototype;","function _extends() { _extends = Object.assign || 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); }\n\nimport isAbsent from './util/isAbsent';\nimport isSchema from './util/isSchema';\nimport printValue from './util/printValue';\nimport { array as locale } from './locale';\nimport runTests from './util/runTests';\nimport ValidationError from './ValidationError';\nimport BaseSchema from './schema';\nexport function create(type) {\n return new ArraySchema(type);\n}\nexport default class ArraySchema extends BaseSchema {\n constructor(type) {\n super({\n type: 'array'\n }); // `undefined` specifically means uninitialized, as opposed to\n // \"no subtype\"\n\n this.innerType = void 0;\n this.innerType = type;\n this.withMutation(() => {\n this.transform(function (values) {\n if (typeof values === 'string') try {\n values = JSON.parse(values);\n } catch (err) {\n values = null;\n }\n return this.isType(values) ? values : null;\n });\n });\n }\n\n _typeCheck(v) {\n return Array.isArray(v);\n }\n\n get _subType() {\n return this.innerType;\n }\n\n _cast(_value, _opts) {\n const value = super._cast(_value, _opts); //should ignore nulls here\n\n\n if (!this._typeCheck(value) || !this.innerType) return value;\n let isChanged = false;\n const castArray = value.map((v, idx) => {\n const castElement = this.innerType.cast(v, _extends({}, _opts, {\n path: `${_opts.path || ''}[${idx}]`\n }));\n\n if (castElement !== v) {\n isChanged = true;\n }\n\n return castElement;\n });\n return isChanged ? castArray : value;\n }\n\n _validate(_value, options = {}, callback) {\n var _options$abortEarly, _options$recursive;\n\n let errors = [];\n let sync = options.sync;\n let path = options.path;\n let innerType = this.innerType;\n let endEarly = (_options$abortEarly = options.abortEarly) != null ? _options$abortEarly : this.spec.abortEarly;\n let recursive = (_options$recursive = options.recursive) != null ? _options$recursive : this.spec.recursive;\n let originalValue = options.originalValue != null ? options.originalValue : _value;\n\n super._validate(_value, options, (err, value) => {\n if (err) {\n if (!ValidationError.isError(err) || endEarly) {\n return void callback(err, value);\n }\n\n errors.push(err);\n }\n\n if (!recursive || !innerType || !this._typeCheck(value)) {\n callback(errors[0] || null, value);\n return;\n }\n\n originalValue = originalValue || value; // #950 Ensure that sparse array empty slots are validated\n\n let tests = new Array(value.length);\n\n for (let idx = 0; idx < value.length; idx++) {\n let item = value[idx];\n let path = `${options.path || ''}[${idx}]`; // object._validate note for isStrict explanation\n\n let innerOptions = _extends({}, options, {\n path,\n strict: true,\n parent: value,\n index: idx,\n originalValue: originalValue[idx]\n });\n\n tests[idx] = (_, cb) => innerType.validate(item, innerOptions, cb);\n }\n\n runTests({\n sync,\n path,\n value,\n errors,\n endEarly,\n tests\n }, callback);\n });\n }\n\n clone(spec) {\n const next = super.clone(spec);\n next.innerType = this.innerType;\n return next;\n }\n\n concat(schema) {\n let next = super.concat(schema);\n next.innerType = this.innerType;\n if (schema.innerType) next.innerType = next.innerType ? // @ts-expect-error Lazy doesn't have concat()\n next.innerType.concat(schema.innerType) : schema.innerType;\n return next;\n }\n\n of(schema) {\n // FIXME: this should return a new instance of array without the default to be\n let next = this.clone();\n if (!isSchema(schema)) throw new TypeError('`array.of()` sub-schema must be a valid yup schema not: ' + printValue(schema)); // FIXME(ts):\n\n next.innerType = schema;\n return next;\n }\n\n length(length, message = locale.length) {\n return this.test({\n message,\n name: 'length',\n exclusive: true,\n params: {\n length\n },\n\n test(value) {\n return isAbsent(value) || value.length === this.resolve(length);\n }\n\n });\n }\n\n min(min, message) {\n message = message || locale.min;\n return this.test({\n message,\n name: 'min',\n exclusive: true,\n params: {\n min\n },\n\n // FIXME(ts): Array\n test(value) {\n return isAbsent(value) || value.length >= this.resolve(min);\n }\n\n });\n }\n\n max(max, message) {\n message = message || locale.max;\n return this.test({\n message,\n name: 'max',\n exclusive: true,\n params: {\n max\n },\n\n test(value) {\n return isAbsent(value) || value.length <= this.resolve(max);\n }\n\n });\n }\n\n ensure() {\n return this.default(() => []).transform((val, original) => {\n // We don't want to return `null` for nullable schema\n if (this._typeCheck(val)) return val;\n return original == null ? [] : [].concat(original);\n });\n }\n\n compact(rejector) {\n let reject = !rejector ? v => !!v : (v, i, a) => !rejector(v, i, a);\n return this.transform(values => values != null ? values.filter(reject) : values);\n }\n\n describe() {\n let base = super.describe();\n if (this.innerType) base.innerType = this.innerType.describe();\n return base;\n }\n\n nullable(isNullable = true) {\n return super.nullable(isNullable);\n }\n\n defined() {\n return super.defined();\n }\n\n required(msg) {\n return super.required(msg);\n }\n\n}\ncreate.prototype = ArraySchema.prototype; //\n// Interfaces\n//","(function() { module.exports = window[\"eventespresso\"][\"helpers\"]; }());","export * from './global';\n","var root = require('./_root');\n\n/** Built-in value references. */\nvar Symbol = root.Symbol;\n\nmodule.exports = Symbol;\n","(function() { module.exports = window[\"eventespresso\"][\"services\"]; }());","var getNative = require('./_getNative');\n\n/* Built-in method references that are verified to be native. */\nvar nativeCreate = getNative(Object, 'create');\n\nmodule.exports = nativeCreate;\n","var listCacheClear = require('./_listCacheClear'),\n listCacheDelete = require('./_listCacheDelete'),\n listCacheGet = require('./_listCacheGet'),\n listCacheHas = require('./_listCacheHas'),\n listCacheSet = require('./_listCacheSet');\n\n/**\n * Creates an list cache object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction ListCache(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `ListCache`.\nListCache.prototype.clear = listCacheClear;\nListCache.prototype['delete'] = listCacheDelete;\nListCache.prototype.get = listCacheGet;\nListCache.prototype.has = listCacheHas;\nListCache.prototype.set = listCacheSet;\n\nmodule.exports = ListCache;\n","var eq = require('./eq');\n\n/**\n * Gets the index at which the `key` is found in `array` of key-value pairs.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {*} key The key to search for.\n * @returns {number} Returns the index of the matched value, else `-1`.\n */\nfunction assocIndexOf(array, key) {\n var length = array.length;\n while (length--) {\n if (eq(array[length][0], key)) {\n return length;\n }\n }\n return -1;\n}\n\nmodule.exports = assocIndexOf;\n","var isKeyable = require('./_isKeyable');\n\n/**\n * Gets the data for `map`.\n *\n * @private\n * @param {Object} map The map to query.\n * @param {string} key The reference key.\n * @returns {*} Returns the map data.\n */\nfunction getMapData(map, key) {\n var data = map.__data__;\n return isKeyable(key)\n ? data[typeof key == 'string' ? 'string' : 'hash']\n : data.map;\n}\n\nmodule.exports = getMapData;\n","var isSymbol = require('./isSymbol');\n\n/** Used as references for various `Number` constants. */\nvar INFINITY = 1 / 0;\n\n/**\n * Converts `value` to a string key if it's not a string or symbol.\n *\n * @private\n * @param {*} value The value to inspect.\n * @returns {string|symbol} Returns the key.\n */\nfunction toKey(value) {\n if (typeof value == 'string' || isSymbol(value)) {\n return value;\n }\n var result = (value + '');\n return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;\n}\n\nmodule.exports = toKey;\n","var baseAssignValue = require('./_baseAssignValue'),\n baseForOwn = require('./_baseForOwn'),\n baseIteratee = require('./_baseIteratee');\n\n/**\n * Creates an object with the same keys as `object` and values generated\n * by running each own enumerable string keyed property of `object` thru\n * `iteratee`. The iteratee is invoked with three arguments:\n * (value, key, object).\n *\n * @static\n * @memberOf _\n * @since 2.4.0\n * @category Object\n * @param {Object} object The object to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @returns {Object} Returns the new mapped object.\n * @see _.mapKeys\n * @example\n *\n * var users = {\n * 'fred': { 'user': 'fred', 'age': 40 },\n * 'pebbles': { 'user': 'pebbles', 'age': 1 }\n * };\n *\n * _.mapValues(users, function(o) { return o.age; });\n * // => { 'fred': 40, 'pebbles': 1 } (iteration order is not guaranteed)\n *\n * // The `_.property` iteratee shorthand.\n * _.mapValues(users, 'age');\n * // => { 'fred': 40, 'pebbles': 1 } (iteration order is not guaranteed)\n */\nfunction mapValues(object, iteratee) {\n var result = {};\n iteratee = baseIteratee(iteratee, 3);\n\n baseForOwn(object, function(value, key, object) {\n baseAssignValue(result, key, iteratee(value, key, object));\n });\n return result;\n}\n\nmodule.exports = mapValues;\n","import setPrototypeOf from \"@babel/runtime/helpers/esm/setPrototypeOf\";\nimport isNativeReflectConstruct from \"@babel/runtime/helpers/esm/isNativeReflectConstruct\";\nexport default function _construct(Parent, args, Class) {\n if (isNativeReflectConstruct()) {\n _construct = Reflect.construct;\n } else {\n _construct = function _construct(Parent, args, Class) {\n var a = [null];\n a.push.apply(a, args);\n var Constructor = Function.bind.apply(Parent, a);\n var instance = new Constructor();\n if (Class) setPrototypeOf(instance, Class.prototype);\n return instance;\n };\n }\n\n return _construct.apply(null, arguments);\n}","import getPrototypeOf from \"@babel/runtime/helpers/esm/getPrototypeOf\";\nimport setPrototypeOf from \"@babel/runtime/helpers/esm/setPrototypeOf\";\nimport isNativeFunction from \"@babel/runtime/helpers/esm/isNativeFunction\";\nimport construct from \"@babel/runtime/helpers/esm/construct\";\nexport default function _wrapNativeSuper(Class) {\n var _cache = typeof Map === \"function\" ? new Map() : undefined;\n\n _wrapNativeSuper = function _wrapNativeSuper(Class) {\n if (Class === null || !isNativeFunction(Class)) return Class;\n\n if (typeof Class !== \"function\") {\n throw new TypeError(\"Super expression must either be null or a function\");\n }\n\n if (typeof _cache !== \"undefined\") {\n if (_cache.has(Class)) return _cache.get(Class);\n\n _cache.set(Class, Wrapper);\n }\n\n function Wrapper() {\n return construct(Class, arguments, getPrototypeOf(this).constructor);\n }\n\n Wrapper.prototype = Object.create(Class.prototype, {\n constructor: {\n value: Wrapper,\n enumerable: false,\n writable: true,\n configurable: true\n }\n });\n return setPrototypeOf(Wrapper, Class);\n };\n\n return _wrapNativeSuper(Class);\n}","export default function _isNativeFunction(fn) {\n return Function.toString.call(fn).indexOf(\"[native code]\") !== -1;\n}","(function() { module.exports = window[\"eventespresso\"][\"hooks\"]; }());","(function() { module.exports = window[\"eventespresso\"][\"adapters\"]; }());","(function() { module.exports = window[\"wp\"][\"i18n\"]; }());","import { createContext, useMemo } from 'react';\n\nimport type { ProviderProps, ContextProps } from './types';\nimport { DataStateProvider } from './DataStateProvider';\nimport { FilterStateProvider } from './FilterStateProvider';\n\nconst Context = createContext(null);\n\nconst { Provider, Consumer } = Context;\n\nconst ContextProvider: React.FC = ({ children, assignmentType, entity, title, onCloseModal }) => {\n\tconst value: ContextProps = useMemo(\n\t\t() => ({\n\t\t\tassignmentType,\n\t\t\tentity,\n\t\t\ttitle,\n\t\t\tonCloseModal,\n\t\t}),\n\t\t[assignmentType, entity, onCloseModal, title]\n\t);\n\n\treturn (\n\t\t\n\t\t\t\n\t\t\t\t{children}\n\t\t\t\n\t\t\n\t);\n};\n\nexport { Context, ContextProvider, Consumer };\n","export { default as FilterBar } from './FilterBar';\n\nexport * from './filterState';\n","module.exports = function(module) {\n\tif (!module.webpackPolyfill) {\n\t\tmodule.deprecate = function() {};\n\t\tmodule.paths = [];\n\t\t// module.parent = undefined by default\n\t\tif (!module.children) module.children = [];\n\t\tObject.defineProperty(module, \"loaded\", {\n\t\t\tenumerable: true,\n\t\t\tget: function() {\n\t\t\t\treturn module.l;\n\t\t\t}\n\t\t});\n\t\tObject.defineProperty(module, \"id\", {\n\t\t\tenumerable: true,\n\t\t\tget: function() {\n\t\t\t\treturn module.i;\n\t\t\t}\n\t\t});\n\t\tmodule.webpackPolyfill = 1;\n\t}\n\treturn module;\n};\n","var isArray = require('./isArray'),\n isSymbol = require('./isSymbol');\n\n/** Used to match property names within property paths. */\nvar reIsDeepProp = /\\.|\\[(?:[^[\\]]*|([\"'])(?:(?!\\1)[^\\\\]|\\\\.)*?\\1)\\]/,\n reIsPlainProp = /^\\w*$/;\n\n/**\n * Checks if `value` is a property name and not a property path.\n *\n * @private\n * @param {*} value The value to check.\n * @param {Object} [object] The object to query keys on.\n * @returns {boolean} Returns `true` if `value` is a property name, else `false`.\n */\nfunction isKey(value, object) {\n if (isArray(value)) {\n return false;\n }\n var type = typeof value;\n if (type == 'number' || type == 'symbol' || type == 'boolean' ||\n value == null || isSymbol(value)) {\n return true;\n }\n return reIsPlainProp.test(value) || !reIsDeepProp.test(value) ||\n (object != null && value in Object(object));\n}\n\nmodule.exports = isKey;\n","var baseGetTag = require('./_baseGetTag'),\n isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar symbolTag = '[object Symbol]';\n\n/**\n * Checks if `value` is classified as a `Symbol` primitive or object.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a symbol, else `false`.\n * @example\n *\n * _.isSymbol(Symbol.iterator);\n * // => true\n *\n * _.isSymbol('abc');\n * // => false\n */\nfunction isSymbol(value) {\n return typeof value == 'symbol' ||\n (isObjectLike(value) && baseGetTag(value) == symbolTag);\n}\n\nmodule.exports = isSymbol;\n","var mapCacheClear = require('./_mapCacheClear'),\n mapCacheDelete = require('./_mapCacheDelete'),\n mapCacheGet = require('./_mapCacheGet'),\n mapCacheHas = require('./_mapCacheHas'),\n mapCacheSet = require('./_mapCacheSet');\n\n/**\n * Creates a map cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction MapCache(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `MapCache`.\nMapCache.prototype.clear = mapCacheClear;\nMapCache.prototype['delete'] = mapCacheDelete;\nMapCache.prototype.get = mapCacheGet;\nMapCache.prototype.has = mapCacheHas;\nMapCache.prototype.set = mapCacheSet;\n\nmodule.exports = MapCache;\n","/**\n * Checks if `value` is the\n * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)\n * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an object, else `false`.\n * @example\n *\n * _.isObject({});\n * // => true\n *\n * _.isObject([1, 2, 3]);\n * // => true\n *\n * _.isObject(_.noop);\n * // => true\n *\n * _.isObject(null);\n * // => false\n */\nfunction isObject(value) {\n var type = typeof value;\n return value != null && (type == 'object' || type == 'function');\n}\n\nmodule.exports = isObject;\n","(function() { module.exports = window[\"eventespresso\"][\"i18n\"]; }());","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar Map = getNative(root, 'Map');\n\nmodule.exports = Map;\n","/** Used as references for various `Number` constants. */\nvar MAX_SAFE_INTEGER = 9007199254740991;\n\n/**\n * Checks if `value` is a valid array-like length.\n *\n * **Note:** This method is loosely based on\n * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a valid length, else `false`.\n * @example\n *\n * _.isLength(3);\n * // => true\n *\n * _.isLength(Number.MIN_VALUE);\n * // => false\n *\n * _.isLength(Infinity);\n * // => false\n *\n * _.isLength('3');\n * // => false\n */\nfunction isLength(value) {\n return typeof value == 'number' &&\n value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;\n}\n\nmodule.exports = isLength;\n","var arrayLikeKeys = require('./_arrayLikeKeys'),\n baseKeys = require('./_baseKeys'),\n isArrayLike = require('./isArrayLike');\n\n/**\n * Creates an array of the own enumerable property names of `object`.\n *\n * **Note:** Non-object values are coerced to objects. See the\n * [ES spec](http://ecma-international.org/ecma-262/7.0/#sec-object.keys)\n * for more details.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Object\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.keys(new Foo);\n * // => ['a', 'b'] (iteration order is not guaranteed)\n *\n * _.keys('hi');\n * // => ['0', '1']\n */\nfunction keys(object) {\n return isArrayLike(object) ? arrayLikeKeys(object) : baseKeys(object);\n}\n\nmodule.exports = keys;\n","import arrayWithoutHoles from \"@babel/runtime/helpers/esm/arrayWithoutHoles\";\nimport iterableToArray from \"@babel/runtime/helpers/esm/iterableToArray\";\nimport unsupportedIterableToArray from \"@babel/runtime/helpers/esm/unsupportedIterableToArray\";\nimport nonIterableSpread from \"@babel/runtime/helpers/esm/nonIterableSpread\";\nexport default function _toConsumableArray(arr) {\n return arrayWithoutHoles(arr) || iterableToArray(arr) || unsupportedIterableToArray(arr) || nonIterableSpread();\n}","import arrayLikeToArray from \"@babel/runtime/helpers/esm/arrayLikeToArray\";\nexport default function _arrayWithoutHoles(arr) {\n if (Array.isArray(arr)) return arrayLikeToArray(arr);\n}","export default function _nonIterableSpread() {\n throw new TypeError(\"Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}","var createCompounder = require('./_createCompounder');\n\n/**\n * Converts `string` to\n * [snake case](https://en.wikipedia.org/wiki/Snake_case).\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to convert.\n * @returns {string} Returns the snake cased string.\n * @example\n *\n * _.snakeCase('Foo Bar');\n * // => 'foo_bar'\n *\n * _.snakeCase('fooBar');\n * // => 'foo_bar'\n *\n * _.snakeCase('--FOO-BAR--');\n * // => 'foo_bar'\n */\nvar snakeCase = createCompounder(function(result, word, index) {\n return result + (index ? '_' : '') + word.toLowerCase();\n});\n\nmodule.exports = snakeCase;\n","export default function toInteger(dirtyNumber) {\n if (dirtyNumber === null || dirtyNumber === true || dirtyNumber === false) {\n return NaN;\n }\n\n var number = Number(dirtyNumber);\n\n if (isNaN(number)) {\n return number;\n }\n\n return number < 0 ? Math.ceil(number) : Math.floor(number);\n}","module.exports = require(\"regenerator-runtime\");\n","(function() { module.exports = window[\"eventespresso\"][\"constants\"]; }());","export default function _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n}","import { TAMRelationalData } from './types';\n\nexport const TAM_ENTITIES: Array = ['datetimes', 'tickets'];\n","var castPath = require('./_castPath'),\n isArguments = require('./isArguments'),\n isArray = require('./isArray'),\n isIndex = require('./_isIndex'),\n isLength = require('./isLength'),\n toKey = require('./_toKey');\n\n/**\n * Checks if `path` exists on `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Array|string} path The path to check.\n * @param {Function} hasFunc The function to check properties.\n * @returns {boolean} Returns `true` if `path` exists, else `false`.\n */\nfunction hasPath(object, path, hasFunc) {\n path = castPath(path, object);\n\n var index = -1,\n length = path.length,\n result = false;\n\n while (++index < length) {\n var key = toKey(path[index]);\n if (!(result = object != null && hasFunc(object, key))) {\n break;\n }\n object = object[key];\n }\n if (result || ++index != length) {\n return result;\n }\n length = object == null ? 0 : object.length;\n return !!length && isLength(length) && isIndex(key, length) &&\n (isArray(object) || isArguments(object));\n}\n\nmodule.exports = hasPath;\n","var isArray = require('./isArray'),\n isKey = require('./_isKey'),\n stringToPath = require('./_stringToPath'),\n toString = require('./toString');\n\n/**\n * Casts `value` to a path array if it's not one.\n *\n * @private\n * @param {*} value The value to inspect.\n * @param {Object} [object] The object to query keys on.\n * @returns {Array} Returns the cast property path array.\n */\nfunction castPath(value, object) {\n if (isArray(value)) {\n return value;\n }\n return isKey(value, object) ? [value] : stringToPath(toString(value));\n}\n\nmodule.exports = castPath;\n","/** Detect free variable `global` from Node.js. */\nvar freeGlobal = typeof global == 'object' && global && global.Object === Object && global;\n\nmodule.exports = freeGlobal;\n","var baseGetTag = require('./_baseGetTag'),\n isObject = require('./isObject');\n\n/** `Object#toString` result references. */\nvar asyncTag = '[object AsyncFunction]',\n funcTag = '[object Function]',\n genTag = '[object GeneratorFunction]',\n proxyTag = '[object Proxy]';\n\n/**\n * Checks if `value` is classified as a `Function` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a function, else `false`.\n * @example\n *\n * _.isFunction(_);\n * // => true\n *\n * _.isFunction(/abc/);\n * // => false\n */\nfunction isFunction(value) {\n if (!isObject(value)) {\n return false;\n }\n // The use of `Object#toString` avoids issues with the `typeof` operator\n // in Safari 9 which returns 'object' for typed arrays and other constructors.\n var tag = baseGetTag(value);\n return tag == funcTag || tag == genTag || tag == asyncTag || tag == proxyTag;\n}\n\nmodule.exports = isFunction;\n","export default function _arrayLikeToArray(arr, len) {\n if (len == null || len > arr.length) len = arr.length;\n\n for (var i = 0, arr2 = new Array(len); i < len; i++) {\n arr2[i] = arr[i];\n }\n\n return arr2;\n}","/** Used for built-in method references. */\nvar funcProto = Function.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/**\n * Converts `func` to its source code.\n *\n * @private\n * @param {Function} func The function to convert.\n * @returns {string} Returns the source code.\n */\nfunction toSource(func) {\n if (func != null) {\n try {\n return funcToString.call(func);\n } catch (e) {}\n try {\n return (func + '');\n } catch (e) {}\n }\n return '';\n}\n\nmodule.exports = toSource;\n","/**\n * Performs a\n * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * comparison between two values to determine if they are equivalent.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n * @example\n *\n * var object = { 'a': 1 };\n * var other = { 'a': 1 };\n *\n * _.eq(object, object);\n * // => true\n *\n * _.eq(object, other);\n * // => false\n *\n * _.eq('a', 'a');\n * // => true\n *\n * _.eq('a', Object('a'));\n * // => false\n *\n * _.eq(NaN, NaN);\n * // => true\n */\nfunction eq(value, other) {\n return value === other || (value !== value && other !== other);\n}\n\nmodule.exports = eq;\n","var baseIsArguments = require('./_baseIsArguments'),\n isObjectLike = require('./isObjectLike');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Built-in value references. */\nvar propertyIsEnumerable = objectProto.propertyIsEnumerable;\n\n/**\n * Checks if `value` is likely an `arguments` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\n * else `false`.\n * @example\n *\n * _.isArguments(function() { return arguments; }());\n * // => true\n *\n * _.isArguments([1, 2, 3]);\n * // => false\n */\nvar isArguments = baseIsArguments(function() { return arguments; }()) ? baseIsArguments : function(value) {\n return isObjectLike(value) && hasOwnProperty.call(value, 'callee') &&\n !propertyIsEnumerable.call(value, 'callee');\n};\n\nmodule.exports = isArguments;\n","/** Used as references for various `Number` constants. */\nvar MAX_SAFE_INTEGER = 9007199254740991;\n\n/** Used to detect unsigned integer values. */\nvar reIsUint = /^(?:0|[1-9]\\d*)$/;\n\n/**\n * Checks if `value` is a valid array-like index.\n *\n * @private\n * @param {*} value The value to check.\n * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index.\n * @returns {boolean} Returns `true` if `value` is a valid index, else `false`.\n */\nfunction isIndex(value, length) {\n var type = typeof value;\n length = length == null ? MAX_SAFE_INTEGER : length;\n\n return !!length &&\n (type == 'number' ||\n (type != 'symbol' && reIsUint.test(value))) &&\n (value > -1 && value % 1 == 0 && value < length);\n}\n\nmodule.exports = isIndex;\n","var defineProperty = require('./_defineProperty');\n\n/**\n * The base implementation of `assignValue` and `assignMergeValue` without\n * value checks.\n *\n * @private\n * @param {Object} object The object to modify.\n * @param {string} key The key of the property to assign.\n * @param {*} value The value to assign.\n */\nfunction baseAssignValue(object, key, value) {\n if (key == '__proto__' && defineProperty) {\n defineProperty(object, key, {\n 'configurable': true,\n 'enumerable': true,\n 'value': value,\n 'writable': true\n });\n } else {\n object[key] = value;\n }\n}\n\nmodule.exports = baseAssignValue;\n","var baseFor = require('./_baseFor'),\n keys = require('./keys');\n\n/**\n * The base implementation of `_.forOwn` without support for iteratee shorthands.\n *\n * @private\n * @param {Object} object The object to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Object} Returns `object`.\n */\nfunction baseForOwn(object, iteratee) {\n return object && baseFor(object, iteratee, keys);\n}\n\nmodule.exports = baseForOwn;\n","var root = require('./_root'),\n stubFalse = require('./stubFalse');\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Built-in value references. */\nvar Buffer = moduleExports ? root.Buffer : undefined;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined;\n\n/**\n * Checks if `value` is a buffer.\n *\n * @static\n * @memberOf _\n * @since 4.3.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a buffer, else `false`.\n * @example\n *\n * _.isBuffer(new Buffer(2));\n * // => true\n *\n * _.isBuffer(new Uint8Array(2));\n * // => false\n */\nvar isBuffer = nativeIsBuffer || stubFalse;\n\nmodule.exports = isBuffer;\n","var baseIsTypedArray = require('./_baseIsTypedArray'),\n baseUnary = require('./_baseUnary'),\n nodeUtil = require('./_nodeUtil');\n\n/* Node.js helper references. */\nvar nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray;\n\n/**\n * Checks if `value` is classified as a typed array.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n * @example\n *\n * _.isTypedArray(new Uint8Array);\n * // => true\n *\n * _.isTypedArray([]);\n * // => false\n */\nvar isTypedArray = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray;\n\nmodule.exports = isTypedArray;\n","var baseMatches = require('./_baseMatches'),\n baseMatchesProperty = require('./_baseMatchesProperty'),\n identity = require('./identity'),\n isArray = require('./isArray'),\n property = require('./property');\n\n/**\n * The base implementation of `_.iteratee`.\n *\n * @private\n * @param {*} [value=_.identity] The value to convert to an iteratee.\n * @returns {Function} Returns the iteratee.\n */\nfunction baseIteratee(value) {\n // Don't store the `typeof` result in a variable to avoid a JIT bug in Safari 9.\n // See https://bugs.webkit.org/show_bug.cgi?id=156034 for more details.\n if (typeof value == 'function') {\n return value;\n }\n if (value == null) {\n return identity;\n }\n if (typeof value == 'object') {\n return isArray(value)\n ? baseMatchesProperty(value[0], value[1])\n : baseMatches(value);\n }\n return property(value);\n}\n\nmodule.exports = baseIteratee;\n","var ListCache = require('./_ListCache'),\n stackClear = require('./_stackClear'),\n stackDelete = require('./_stackDelete'),\n stackGet = require('./_stackGet'),\n stackHas = require('./_stackHas'),\n stackSet = require('./_stackSet');\n\n/**\n * Creates a stack cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction Stack(entries) {\n var data = this.__data__ = new ListCache(entries);\n this.size = data.size;\n}\n\n// Add methods to `Stack`.\nStack.prototype.clear = stackClear;\nStack.prototype['delete'] = stackDelete;\nStack.prototype.get = stackGet;\nStack.prototype.has = stackHas;\nStack.prototype.set = stackSet;\n\nmodule.exports = Stack;\n","(function() { module.exports = window[\"R\"]; }());","var baseIsEqualDeep = require('./_baseIsEqualDeep'),\n isObjectLike = require('./isObjectLike');\n\n/**\n * The base implementation of `_.isEqual` which supports partial comparisons\n * and tracks traversed objects.\n *\n * @private\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @param {boolean} bitmask The bitmask flags.\n * 1 - Unordered comparison\n * 2 - Partial comparison\n * @param {Function} [customizer] The function to customize comparisons.\n * @param {Object} [stack] Tracks traversed `value` and `other` objects.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n */\nfunction baseIsEqual(value, other, bitmask, customizer, stack) {\n if (value === other) {\n return true;\n }\n if (value == null || other == null || (!isObjectLike(value) && !isObjectLike(other))) {\n return value !== value && other !== other;\n }\n return baseIsEqualDeep(value, other, bitmask, customizer, baseIsEqual, stack);\n}\n\nmodule.exports = baseIsEqual;\n","var SetCache = require('./_SetCache'),\n arraySome = require('./_arraySome'),\n cacheHas = require('./_cacheHas');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/**\n * A specialized version of `baseIsEqualDeep` for arrays with support for\n * partial deep comparisons.\n *\n * @private\n * @param {Array} array The array to compare.\n * @param {Array} other The other array to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `array` and `other` objects.\n * @returns {boolean} Returns `true` if the arrays are equivalent, else `false`.\n */\nfunction equalArrays(array, other, bitmask, customizer, equalFunc, stack) {\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG,\n arrLength = array.length,\n othLength = other.length;\n\n if (arrLength != othLength && !(isPartial && othLength > arrLength)) {\n return false;\n }\n // Check that cyclic values are equal.\n var arrStacked = stack.get(array);\n var othStacked = stack.get(other);\n if (arrStacked && othStacked) {\n return arrStacked == other && othStacked == array;\n }\n var index = -1,\n result = true,\n seen = (bitmask & COMPARE_UNORDERED_FLAG) ? new SetCache : undefined;\n\n stack.set(array, other);\n stack.set(other, array);\n\n // Ignore non-index properties.\n while (++index < arrLength) {\n var arrValue = array[index],\n othValue = other[index];\n\n if (customizer) {\n var compared = isPartial\n ? customizer(othValue, arrValue, index, other, array, stack)\n : customizer(arrValue, othValue, index, array, other, stack);\n }\n if (compared !== undefined) {\n if (compared) {\n continue;\n }\n result = false;\n break;\n }\n // Recursively compare arrays (susceptible to call stack limits).\n if (seen) {\n if (!arraySome(other, function(othValue, othIndex) {\n if (!cacheHas(seen, othIndex) &&\n (arrValue === othValue || equalFunc(arrValue, othValue, bitmask, customizer, stack))) {\n return seen.push(othIndex);\n }\n })) {\n result = false;\n break;\n }\n } else if (!(\n arrValue === othValue ||\n equalFunc(arrValue, othValue, bitmask, customizer, stack)\n )) {\n result = false;\n break;\n }\n }\n stack['delete'](array);\n stack['delete'](other);\n return result;\n}\n\nmodule.exports = equalArrays;\n","var isObject = require('./isObject');\n\n/**\n * Checks if `value` is suitable for strict equality comparisons, i.e. `===`.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` if suitable for strict\n * equality comparisons, else `false`.\n */\nfunction isStrictComparable(value) {\n return value === value && !isObject(value);\n}\n\nmodule.exports = isStrictComparable;\n","/**\n * A specialized version of `matchesProperty` for source values suitable\n * for strict equality comparisons, i.e. `===`.\n *\n * @private\n * @param {string} key The key of the property to get.\n * @param {*} srcValue The value to match.\n * @returns {Function} Returns the new spec function.\n */\nfunction matchesStrictComparable(key, srcValue) {\n return function(object) {\n if (object == null) {\n return false;\n }\n return object[key] === srcValue &&\n (srcValue !== undefined || (key in Object(object)));\n };\n}\n\nmodule.exports = matchesStrictComparable;\n","var castPath = require('./_castPath'),\n toKey = require('./_toKey');\n\n/**\n * The base implementation of `_.get` without support for default values.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Array|string} path The path of the property to get.\n * @returns {*} Returns the resolved value.\n */\nfunction baseGet(object, path) {\n path = castPath(path, object);\n\n var index = 0,\n length = path.length;\n\n while (object != null && index < length) {\n object = object[toKey(path[index++])];\n }\n return (index && index == length) ? object : undefined;\n}\n\nmodule.exports = baseGet;\n","var arrayReduce = require('./_arrayReduce'),\n deburr = require('./deburr'),\n words = require('./words');\n\n/** Used to compose unicode capture groups. */\nvar rsApos = \"['\\u2019]\";\n\n/** Used to match apostrophes. */\nvar reApos = RegExp(rsApos, 'g');\n\n/**\n * Creates a function like `_.camelCase`.\n *\n * @private\n * @param {Function} callback The function to combine each word.\n * @returns {Function} Returns the new compounder function.\n */\nfunction createCompounder(callback) {\n return function(string) {\n return arrayReduce(words(deburr(string).replace(reApos, '')), callback, '');\n };\n}\n\nmodule.exports = createCompounder;\n","/** Used to compose unicode character classes. */\nvar rsAstralRange = '\\\\ud800-\\\\udfff',\n rsComboMarksRange = '\\\\u0300-\\\\u036f',\n reComboHalfMarksRange = '\\\\ufe20-\\\\ufe2f',\n rsComboSymbolsRange = '\\\\u20d0-\\\\u20ff',\n rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange,\n rsVarRange = '\\\\ufe0e\\\\ufe0f';\n\n/** Used to compose unicode capture groups. */\nvar rsZWJ = '\\\\u200d';\n\n/** Used to detect strings with [zero-width joiners or code points from the astral planes](http://eev.ee/blog/2015/09/12/dark-corners-of-unicode/). */\nvar reHasUnicode = RegExp('[' + rsZWJ + rsAstralRange + rsComboRange + rsVarRange + ']');\n\n/**\n * Checks if `string` contains Unicode symbols.\n *\n * @private\n * @param {string} string The string to inspect.\n * @returns {boolean} Returns `true` if a symbol is found, else `false`.\n */\nfunction hasUnicode(string) {\n return reHasUnicode.test(string);\n}\n\nmodule.exports = hasUnicode;\n","import arrayLikeToArray from \"@babel/runtime/helpers/esm/arrayLikeToArray\";\nexport default function _unsupportedIterableToArray(o, minLen) {\n if (!o) return;\n if (typeof o === \"string\") return arrayLikeToArray(o, minLen);\n var n = Object.prototype.toString.call(o).slice(8, -1);\n if (n === \"Object\" && o.constructor) n = o.constructor.name;\n if (n === \"Map\" || n === \"Set\") return Array.from(o);\n if (n === \"Arguments\" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return arrayLikeToArray(o, minLen);\n}","function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {\n try {\n var info = gen[key](arg);\n var value = info.value;\n } catch (error) {\n reject(error);\n return;\n }\n\n if (info.done) {\n resolve(value);\n } else {\n Promise.resolve(value).then(_next, _throw);\n }\n}\n\nexport default function _asyncToGenerator(fn) {\n return function () {\n var self = this,\n args = arguments;\n return new Promise(function (resolve, reject) {\n var gen = fn.apply(self, args);\n\n function _next(value) {\n asyncGeneratorStep(gen, resolve, reject, _next, _throw, \"next\", value);\n }\n\n function _throw(err) {\n asyncGeneratorStep(gen, resolve, reject, _next, _throw, \"throw\", err);\n }\n\n _next(undefined);\n });\n };\n}","(function() { module.exports = window[\"wp\"][\"url\"]; }());","var capitalize = require('./capitalize'),\n createCompounder = require('./_createCompounder');\n\n/**\n * Converts `string` to [camel case](https://en.wikipedia.org/wiki/CamelCase).\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to convert.\n * @returns {string} Returns the camel cased string.\n * @example\n *\n * _.camelCase('Foo Bar');\n * // => 'fooBar'\n *\n * _.camelCase('--foo-bar--');\n * // => 'fooBar'\n *\n * _.camelCase('__FOO_BAR__');\n * // => 'fooBar'\n */\nvar camelCase = createCompounder(function(result, word, index) {\n word = word.toLowerCase();\n return result + (index ? capitalize(word) : word);\n});\n\nmodule.exports = camelCase;\n","var baseAssignValue = require('./_baseAssignValue'),\n baseForOwn = require('./_baseForOwn'),\n baseIteratee = require('./_baseIteratee');\n\n/**\n * The opposite of `_.mapValues`; this method creates an object with the\n * same values as `object` and keys generated by running each own enumerable\n * string keyed property of `object` thru `iteratee`. The iteratee is invoked\n * with three arguments: (value, key, object).\n *\n * @static\n * @memberOf _\n * @since 3.8.0\n * @category Object\n * @param {Object} object The object to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @returns {Object} Returns the new mapped object.\n * @see _.mapValues\n * @example\n *\n * _.mapKeys({ 'a': 1, 'b': 2 }, function(value, key) {\n * return key + value;\n * });\n * // => { 'a1': 1, 'b2': 2 }\n */\nfunction mapKeys(object, iteratee) {\n var result = {};\n iteratee = baseIteratee(iteratee, 3);\n\n baseForOwn(object, function(value, key, object) {\n baseAssignValue(result, iteratee(value, key, object), value);\n });\n return result;\n}\n\nmodule.exports = mapKeys;\n","\n/**\n * Topological sorting function\n *\n * @param {Array} edges\n * @returns {Array}\n */\n\nmodule.exports = function(edges) {\n return toposort(uniqueNodes(edges), edges)\n}\n\nmodule.exports.array = toposort\n\nfunction toposort(nodes, edges) {\n var cursor = nodes.length\n , sorted = new Array(cursor)\n , visited = {}\n , i = cursor\n // Better data structures make algorithm much faster.\n , outgoingEdges = makeOutgoingEdges(edges)\n , nodesHash = makeNodesHash(nodes)\n\n // check for unknown nodes\n edges.forEach(function(edge) {\n if (!nodesHash.has(edge[0]) || !nodesHash.has(edge[1])) {\n throw new Error('Unknown node. There is an unknown node in the supplied edges.')\n }\n })\n\n while (i--) {\n if (!visited[i]) visit(nodes[i], i, new Set())\n }\n\n return sorted\n\n function visit(node, i, predecessors) {\n if(predecessors.has(node)) {\n var nodeRep\n try {\n nodeRep = \", node was:\" + JSON.stringify(node)\n } catch(e) {\n nodeRep = \"\"\n }\n throw new Error('Cyclic dependency' + nodeRep)\n }\n\n if (!nodesHash.has(node)) {\n throw new Error('Found unknown node. Make sure to provided all involved nodes. Unknown node: '+JSON.stringify(node))\n }\n\n if (visited[i]) return;\n visited[i] = true\n\n var outgoing = outgoingEdges.get(node) || new Set()\n outgoing = Array.from(outgoing)\n\n if (i = outgoing.length) {\n predecessors.add(node)\n do {\n var child = outgoing[--i]\n visit(child, nodesHash.get(child), predecessors)\n } while (i)\n predecessors.delete(node)\n }\n\n sorted[--cursor] = node\n }\n}\n\nfunction uniqueNodes(arr){\n var res = new Set()\n for (var i = 0, len = arr.length; i < len; i++) {\n var edge = arr[i]\n res.add(edge[0])\n res.add(edge[1])\n }\n return Array.from(res)\n}\n\nfunction makeOutgoingEdges(arr){\n var edges = new Map()\n for (var i = 0, len = arr.length; i < len; i++) {\n var edge = arr[i]\n if (!edges.has(edge[0])) edges.set(edge[0], new Set())\n if (!edges.has(edge[1])) edges.set(edge[1], new Set())\n edges.get(edge[0]).add(edge[1])\n }\n return edges\n}\n\nfunction makeNodesHash(arr){\n var res = new Map()\n for (var i = 0, len = arr.length; i < len; i++) {\n res.set(arr[i], i)\n }\n return res\n}\n","(function() { module.exports = window[\"eventespresso\"][\"registry\"]; }());","import * as R from 'ramda';\nimport { parseISO } from 'date-fns';\n\nimport type { EntityId } from '@eventespresso/data';\nimport type { AnyObject } from '@eventespresso/utils';\nimport type { TAMPossibleRelation, TAMRelationEntity, TAMRelationalData, TAMRelationalEntity } from '../types';\nimport type { Datetime, Ticket } from '@eventespresso/edtr-services';\nimport type { OptionsType } from '@eventespresso/adapters';\nimport { sortDates, minDateCapacity } from '@eventespresso/predicates';\nimport { parseInfinity, isInfinite, idToPropMap } from '@eventespresso/utils';\nimport { getMonthName } from '@eventespresso/dates';\n\nexport type EntitiesToUpdate = Array<[EntityId, TAMPossibleRelation]>;\n\ninterface EntitiesForUpdateOptions {\n\tentity: Entity;\n\texistingData: TAMRelationalData;\n\tnewData: TAMRelationalData;\n\trelation: Exclude;\n}\n\nexport const prepareEntitiesForUpdate = ({\n\tentity,\n\texistingData,\n\tnewData,\n\trelation,\n}: EntitiesForUpdateOptions): EntitiesToUpdate => {\n\tconst existingEntities = R.pathOr({}, [entity], existingData);\n\tconst newEntities = R.pathOr({}, [entity], newData);\n\n\treturn R.filter(([entityId, possibleRelation]) => {\n\t\tconst newRelatedEntities = R.pathOr([], [relation], possibleRelation);\n\t\tconst oldRelatedEntities = R.pathOr([], [entityId, relation], existingEntities);\n\t\t// make sure to sort them before compare\n\t\t// to make sure that they are actually different\n\t\treturn !R.equals(newRelatedEntities.sort(), oldRelatedEntities.sort());\n\t}, Object.entries(newEntities));\n};\n\ntype TicketsWithQuantityArgs = {\n\tticketsToUpdate: EntitiesToUpdate;\n\texistingData: TAMRelationalData;\n\tallDates: Array;\n\tallTickets: Array;\n};\n\n/**\n * Returns the tickets to quantity map of the tickets that need update\n */\nexport const ticketsWithNewQuantity = ({\n\tallDates,\n\tallTickets,\n\texistingData,\n\tticketsToUpdate,\n}: TicketsWithQuantityArgs): AnyObject => {\n\t// create a map of ticket ids to quantities\n\tconst ticketIdToQuantityMap = idToPropMap('quantity', allTickets);\n\n\tconst getMinDateCapacity = minDateCapacity(allDates);\n\n\t/**\n\t * This becomes an object with key as ticket id and value as new ticket quantity\n\t * {\n\t * [ticket.id]: quantity\n\t * }\n\t */\n\treturn ticketsToUpdate.reduce>((acc, [ticketId, possibleRelation]) => {\n\t\t// These are the related date ids before TAM was launched\n\t\tconst existingRelatedDateIds = existingData?.tickets?.[ticketId]?.datetimes || [];\n\t\t// These are the related date ids that have been assigned in TAM\n\t\t// these contain old and newly assigned date ids\n\t\tconst allNewRelatedDateIds: Array = possibleRelation?.datetimes || [];\n\n\t\t// lets filter out the existing ones\n\t\tconst newOnlyRelatedDateIds = allNewRelatedDateIds.filter(\n\t\t\t// it's new only if it was not in existing relations\n\t\t\t(dateId) => !existingRelatedDateIds.includes(dateId)\n\t\t);\n\n\t\t// we need to set the ticket quantity to the minimum of all the capacities\n\t\tconst minimumCapacity = getMinDateCapacity(newOnlyRelatedDateIds);\n\n\t\t// Make sure that the non negative ticket quantity value is compared with\n\t\t// a non negative datetime capacity value in Math.min()\n\t\tconst nonNegativeTicketQuantity = parseInfinity(ticketIdToQuantityMap?.[ticketId], Infinity);\n\n\t\t// if capacity is infinite or it's more than ticket quantity\n\t\tif (isInfinite(minimumCapacity) || minimumCapacity >= nonNegativeTicketQuantity) {\n\t\t\t// no need to update the ticket quantity\n\t\t\treturn acc;\n\t\t}\n\n\t\t// set the quantity to minimum capacity\n\t\treturn R.assocPath([ticketId], minimumCapacity, acc);\n\t}, {});\n};\n\n/**\n * e.g\n * {\n * 2019: {\n * 9: 'October',\n * 10: 'November',\n * 11: 'December',\n * },\n * 2020: {\n * 0: 'Januray',\n * 1: 'February',\n * 2: 'March',\n * 3: 'April',\n * },\n * }\n */\ntype YearWiseMonths = AnyObject>;\n\nconst getYearWiseMonthsFromDates = (dates: Array): YearWiseMonths => {\n\tconst sortedDates = sortDates({ dates });\n\n\tconst yearWiseMonths = sortedDates.reduce((acc, { startDate }) => {\n\t\tconst parsedDate = parseISO(startDate);\n\t\tconst year = parsedDate.getFullYear();\n\t\tconst month = parsedDate.getMonth();\n\n\t\tconst monthsInTheYear = acc[year] || {};\n\t\tif (!(month in monthsInTheYear)) {\n\t\t\tmonthsInTheYear[month] = getMonthName(parsedDate);\n\n\t\t\treturn {\n\t\t\t\t...acc,\n\t\t\t\t[year]: monthsInTheYear,\n\t\t\t};\n\t\t}\n\t\treturn acc;\n\t}, {});\n\n\treturn yearWiseMonths;\n};\n\nexport const getMonthsListFromDatetimes = (dates: Array): OptionsType => {\n\tconst yearWiseMonths = getYearWiseMonthsFromDates(dates);\n\n\tconst list = Object.entries(yearWiseMonths).map(([year, months]) => {\n\t\treturn {\n\t\t\tkey: year,\n\t\t\tlabel: year,\n\t\t\toptions: Object.entries(months).map(([monthNumber, monthName]) => {\n\t\t\t\treturn {\n\t\t\t\t\tkey: `${year}:${monthNumber}`,\n\t\t\t\t\tlabel: monthName,\n\t\t\t\t\tvalue: `${year}:${monthNumber}`,\n\t\t\t\t};\n\t\t\t}),\n\t\t};\n\t});\n\n\treturn list;\n};\n","export default function _getPrototypeOf(o) {\n _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) {\n return o.__proto__ || Object.getPrototypeOf(o);\n };\n return _getPrototypeOf(o);\n}","import { useEventsHandler, useCacheRehydration } from '@eventespresso/edtr-services';\n\nconst useEditorInitialization = (): boolean => {\n\t// register global event handlers\n\tuseEventsHandler();\n\n\t// rehydrate data cache\n\treturn useCacheRehydration();\n};\n\nexport default useEditorInitialization;\n","import { useMemo } from 'react';\n\nimport type { EntityId } from '@eventespresso/data';\nimport { EntityCardDetailsSubscription, EntityCardDetailsRegistry } from '@eventespresso/registry';\nimport { domain } from '@eventespresso/edtr-services';\nimport { useMemoStringify } from '@eventespresso/hooks';\n\nconst { getSubscriptions } = new EntityCardDetailsSubscription(domain);\n\nconst useEntityCardDetailsItems = (\n\tentityType: T,\n\tentityId: EntityId,\n\tfilterByEntityType = true\n): Array => {\n\tconst registry = useMemo(\n\t\t() => new EntityCardDetailsRegistry({ domain, entityType, entityId }),\n\t\t[entityId, entityType]\n\t);\n\n\tconst { generateElements } = registry;\n\n\tconst subscriptions = getSubscriptions({ entityType: filterByEntityType ? entityType : null });\n\n\tObject.values(subscriptions).forEach(({ callback }) => {\n\t\tcallback({ entityType, entityId, registry });\n\t});\n\n\t// it should only change if subscriptions change\n\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\treturn useMemoStringify(generateElements(), Object.keys(subscriptions));\n};\n\nexport default useEntityCardDetailsItems;\n","import { useMemo } from 'react';\n\nimport { NewEntitySubscription, NewEntityOptionsRegistry } from '@eventespresso/registry';\nimport { domain } from '@eventespresso/edtr-services';\nimport { useMemoStringify } from '@eventespresso/hooks';\n\nconst { getSubscriptions } = new NewEntitySubscription(domain);\n\nconst useNewEntityOptionItems = (\n\tentityType: T,\n\tfilterByEntityType = true\n): Array => {\n\tconst registry = useMemo(() => new NewEntityOptionsRegistry({ domain, entityType }), [entityType]);\n\n\tconst { generateElements } = registry;\n\n\tconst subscriptions = getSubscriptions({ entityType: filterByEntityType ? entityType : null });\n\n\tObject.values(subscriptions).forEach(({ callback }) => {\n\t\tcallback({ entityType, registry });\n\t});\n\n\t// it should only change if subscriptions change\n\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\treturn useMemoStringify(generateElements(), Object.keys(subscriptions));\n};\n\nexport default useNewEntityOptionItems;\n","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst Trash = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(Trash, 'trash');\n","function _defineProperties(target, props) {\n for (var i = 0; i < props.length; i++) {\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n Object.defineProperty(target, descriptor.key, descriptor);\n }\n}\n\nexport default function _createClass(Constructor, protoProps, staticProps) {\n if (protoProps) _defineProperties(Constructor.prototype, protoProps);\n if (staticProps) _defineProperties(Constructor, staticProps);\n return Constructor;\n}","(function() { module.exports = window[\"eventespresso\"][\"uiComponents\"]; }());","(function() { module.exports = window[\"eventespresso\"][\"dates\"]; }());","import setPrototypeOf from \"@babel/runtime/helpers/esm/setPrototypeOf\";\nexport default function _inherits(subClass, superClass) {\n if (typeof superClass !== \"function\" && superClass !== null) {\n throw new TypeError(\"Super expression must either be null or a function\");\n }\n\n subClass.prototype = Object.create(superClass && superClass.prototype, {\n constructor: {\n value: subClass,\n writable: true,\n configurable: true\n }\n });\n if (superClass) setPrototypeOf(subClass, superClass);\n}","import _typeof from \"@babel/runtime/helpers/esm/typeof\";\nimport assertThisInitialized from \"@babel/runtime/helpers/esm/assertThisInitialized\";\nexport default function _possibleConstructorReturn(self, call) {\n if (call && (_typeof(call) === \"object\" || typeof call === \"function\")) {\n return call;\n }\n\n return assertThisInitialized(self);\n}","import getPrototypeOf from \"@babel/runtime/helpers/esm/getPrototypeOf\";\nimport isNativeReflectConstruct from \"@babel/runtime/helpers/esm/isNativeReflectConstruct\";\nimport possibleConstructorReturn from \"@babel/runtime/helpers/esm/possibleConstructorReturn\";\nexport default function _createSuper(Derived) {\n var hasNativeReflectConstruct = isNativeReflectConstruct();\n return function _createSuperInternal() {\n var Super = getPrototypeOf(Derived),\n result;\n\n if (hasNativeReflectConstruct) {\n var NewTarget = getPrototypeOf(this).constructor;\n result = Reflect.construct(Super, arguments, NewTarget);\n } else {\n result = Super.apply(this, arguments);\n }\n\n return possibleConstructorReturn(this, result);\n };\n}","import { createContext } from 'react';\n\nimport { useMemoStringify } from '@eventespresso/hooks';\nimport { DataStateManager, BaseProps } from '../types';\nimport { useDataStateManager } from '../data';\n\nconst DataStateContext = createContext(null);\n\nconst { Provider, Consumer: DataStateConsumer } = DataStateContext;\n\nconst DataStateProvider: React.FC = ({ children, assignmentType, entity }) => {\n\tconst props = useMemoStringify({ assignmentType, entity });\n\tconst data = useDataStateManager(props);\n\n\treturn {children};\n};\n\nexport { DataStateContext, DataStateProvider, DataStateConsumer };\n","export { default as useFilterStateManager } from './useFilterStateManager';\n\nexport { default as useFilterState } from './useFilterState';\n\nexport * from './types';\n","import { createContext } from 'react';\n\nimport { useFilterStateManager, FilterStateManager } from '../filters/filterState';\n\nconst FilterStateContext = createContext(null);\n\nconst { Provider, Consumer: FilterStateConsumer } = FilterStateContext;\n\nconst FilterStateProvider: React.FC = ({ children }) => {\n\tconst filterstate = useFilterStateManager();\n\n\treturn {children};\n};\n\nexport { FilterStateContext, FilterStateProvider, FilterStateConsumer };\n","import { useCallback } from 'react';\n\nimport { useDefaultTickets } from '@eventespresso/edtr-services';\nimport { idToEntityMap } from '@eventespresso/predicates';\nimport { useTicketPrices } from '@eventespresso/edtr-services';\nimport { usePriceToTpcModifier, preparePricesForTpc } from '@eventespresso/tpc';\n\nimport type { StateInitializer } from './types';\n\n/**\n * Initializes the data state dynamically.\n */\nconst useInitialState = (): StateInitializer => {\n\tconst defaultTickets = useDefaultTickets();\n\tconst getTicketPrices = useTicketPrices();\n\tconst convertPriceToTpcModifier = usePriceToTpcModifier();\n\n\treturn useCallback(\n\t\t(initialState) => {\n\t\t\tconst normalizedTickets = defaultTickets.map((ticket) => {\n\t\t\t\t// get all related prices\n\t\t\t\tconst unSortedPrices = getTicketPrices(ticket.id);\n\n\t\t\t\t// convert to TPC price objects\n\t\t\t\tconst prices = preparePricesForTpc(unSortedPrices, convertPriceToTpcModifier);\n\n\t\t\t\treturn { ...ticket, prices };\n\t\t\t});\n\n\t\t\tconst tickets = idToEntityMap(normalizedTickets);\n\n\t\t\treturn { ...initialState, tickets };\n\t\t},\n\t\t[convertPriceToTpcModifier, defaultTickets, getTicketPrices]\n\t);\n};\n\nexport default useInitialState;\n","export default function _arrayWithHoles(arr) {\n if (Array.isArray(arr)) return arr;\n}","export default function _nonIterableRest() {\n throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n}","import superPropBase from \"@babel/runtime/helpers/esm/superPropBase\";\nexport default function _get(target, property, receiver) {\n if (typeof Reflect !== \"undefined\" && Reflect.get) {\n _get = Reflect.get;\n } else {\n _get = function _get(target, property, receiver) {\n var base = superPropBase(target, property);\n if (!base) return;\n var desc = Object.getOwnPropertyDescriptor(base, property);\n\n if (desc.get) {\n return desc.get.call(receiver);\n }\n\n return desc.value;\n };\n }\n\n return _get(target, property, receiver || target);\n}","import getPrototypeOf from \"@babel/runtime/helpers/esm/getPrototypeOf\";\nexport default function _superPropBase(object, property) {\n while (!Object.prototype.hasOwnProperty.call(object, property)) {\n object = getPrototypeOf(object);\n if (object === null) break;\n }\n\n return object;\n}","(function() { module.exports = window[\"eventespresso\"][\"plugins\"]; }());","import { createContext } from 'react';\n\nimport { DataStateManager, useDataStateManager } from '../data';\n\nconst DataStateContext = createContext(null);\n\nconst { Provider, Consumer: DataStateConsumer } = DataStateContext;\n\nconst DataStateProvider: React.FC = ({ children }) => {\n\tconst data = useDataStateManager();\n\n\treturn {children};\n};\n\nexport { DataStateContext, DataStateProvider, DataStateConsumer };\n","import { DataStateProvider } from './DataStateProvider';\n\nexport const ContextProvider: React.FC = ({ children }) => {\n\treturn {children};\n};\n","import type { AnyObject } from '@eventespresso/utils';\nimport { ContextProvider } from './ContextProvider';\n\nconst withContext =

(Component: React.ComponentType

): React.FC

=> {\n\tconst WrappedComponent: React.FC

= (props) => {\n\t\treturn (\n\t\t\t\n\t\t\t\t\n\t\t\t\n\t\t);\n\t};\n\n\treturn WrappedComponent;\n};\n\nexport default withContext;\n","(function() { module.exports = window[\"ReactDOM\"]; }());","/**\n * Copyright (c) 2013-present, Facebook, Inc.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\n'use strict';\n\n/**\n * Use invariant() to assert state which your program assumes to be true.\n *\n * Provide sprintf-style format (only %s is supported) and arguments\n * to provide information about what broke and what you were\n * expecting.\n *\n * The invariant message will be stripped in production, but the invariant\n * will remain to ensure logic does not differ in production.\n */\n\nvar invariant = function(condition, format, a, b, c, d, e, f) {\n if (process.env.NODE_ENV !== 'production') {\n if (format === undefined) {\n throw new Error('invariant requires an error message argument');\n }\n }\n\n if (!condition) {\n var error;\n if (format === undefined) {\n error = new Error(\n 'Minified exception occurred; use the non-minified dev environment ' +\n 'for the full error message and additional helpful warnings.'\n );\n } else {\n var args = [a, b, c, d, e, f];\n var argIndex = 0;\n error = new Error(\n format.replace(/%s/g, function() { return args[argIndex++]; })\n );\n error.name = 'Invariant Violation';\n }\n\n error.framesToPop = 1; // we don't care about invariant's own frame\n throw error;\n }\n};\n\nmodule.exports = invariant;\n","/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * The base implementation of `_.has` without support for deep paths.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {Array|string} key The key to check.\n * @returns {boolean} Returns `true` if `key` exists, else `false`.\n */\nfunction baseHas(object, key) {\n return object != null && hasOwnProperty.call(object, key);\n}\n\nmodule.exports = baseHas;\n","var Symbol = require('./_Symbol');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar nativeObjectToString = objectProto.toString;\n\n/** Built-in value references. */\nvar symToStringTag = Symbol ? Symbol.toStringTag : undefined;\n\n/**\n * A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the raw `toStringTag`.\n */\nfunction getRawTag(value) {\n var isOwn = hasOwnProperty.call(value, symToStringTag),\n tag = value[symToStringTag];\n\n try {\n value[symToStringTag] = undefined;\n var unmasked = true;\n } catch (e) {}\n\n var result = nativeObjectToString.call(value);\n if (unmasked) {\n if (isOwn) {\n value[symToStringTag] = tag;\n } else {\n delete value[symToStringTag];\n }\n }\n return result;\n}\n\nmodule.exports = getRawTag;\n","/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar nativeObjectToString = objectProto.toString;\n\n/**\n * Converts `value` to a string using `Object.prototype.toString`.\n *\n * @private\n * @param {*} value The value to convert.\n * @returns {string} Returns the converted string.\n */\nfunction objectToString(value) {\n return nativeObjectToString.call(value);\n}\n\nmodule.exports = objectToString;\n","var memoizeCapped = require('./_memoizeCapped');\n\n/** Used to match property names within property paths. */\nvar rePropName = /[^.[\\]]+|\\[(?:(-?\\d+(?:\\.\\d+)?)|([\"'])((?:(?!\\2)[^\\\\]|\\\\.)*?)\\2)\\]|(?=(?:\\.|\\[\\])(?:\\.|\\[\\]|$))/g;\n\n/** Used to match backslashes in property paths. */\nvar reEscapeChar = /\\\\(\\\\)?/g;\n\n/**\n * Converts `string` to a property path array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the property path array.\n */\nvar stringToPath = memoizeCapped(function(string) {\n var result = [];\n if (string.charCodeAt(0) === 46 /* . */) {\n result.push('');\n }\n string.replace(rePropName, function(match, number, quote, subString) {\n result.push(quote ? subString.replace(reEscapeChar, '$1') : (number || match));\n });\n return result;\n});\n\nmodule.exports = stringToPath;\n","var memoize = require('./memoize');\n\n/** Used as the maximum memoize cache size. */\nvar MAX_MEMOIZE_SIZE = 500;\n\n/**\n * A specialized version of `_.memoize` which clears the memoized function's\n * cache when it exceeds `MAX_MEMOIZE_SIZE`.\n *\n * @private\n * @param {Function} func The function to have its output memoized.\n * @returns {Function} Returns the new memoized function.\n */\nfunction memoizeCapped(func) {\n var result = memoize(func, function(key) {\n if (cache.size === MAX_MEMOIZE_SIZE) {\n cache.clear();\n }\n return key;\n });\n\n var cache = result.cache;\n return result;\n}\n\nmodule.exports = memoizeCapped;\n","var MapCache = require('./_MapCache');\n\n/** Error message constants. */\nvar FUNC_ERROR_TEXT = 'Expected a function';\n\n/**\n * Creates a function that memoizes the result of `func`. If `resolver` is\n * provided, it determines the cache key for storing the result based on the\n * arguments provided to the memoized function. By default, the first argument\n * provided to the memoized function is used as the map cache key. The `func`\n * is invoked with the `this` binding of the memoized function.\n *\n * **Note:** The cache is exposed as the `cache` property on the memoized\n * function. Its creation may be customized by replacing the `_.memoize.Cache`\n * constructor with one whose instances implement the\n * [`Map`](http://ecma-international.org/ecma-262/7.0/#sec-properties-of-the-map-prototype-object)\n * method interface of `clear`, `delete`, `get`, `has`, and `set`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Function\n * @param {Function} func The function to have its output memoized.\n * @param {Function} [resolver] The function to resolve the cache key.\n * @returns {Function} Returns the new memoized function.\n * @example\n *\n * var object = { 'a': 1, 'b': 2 };\n * var other = { 'c': 3, 'd': 4 };\n *\n * var values = _.memoize(_.values);\n * values(object);\n * // => [1, 2]\n *\n * values(other);\n * // => [3, 4]\n *\n * object.a = 2;\n * values(object);\n * // => [1, 2]\n *\n * // Modify the result cache.\n * values.cache.set(object, ['a', 'b']);\n * values(object);\n * // => ['a', 'b']\n *\n * // Replace `_.memoize.Cache`.\n * _.memoize.Cache = WeakMap;\n */\nfunction memoize(func, resolver) {\n if (typeof func != 'function' || (resolver != null && typeof resolver != 'function')) {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n var memoized = function() {\n var args = arguments,\n key = resolver ? resolver.apply(this, args) : args[0],\n cache = memoized.cache;\n\n if (cache.has(key)) {\n return cache.get(key);\n }\n var result = func.apply(this, args);\n memoized.cache = cache.set(key, result) || cache;\n return result;\n };\n memoized.cache = new (memoize.Cache || MapCache);\n return memoized;\n}\n\n// Expose `MapCache`.\nmemoize.Cache = MapCache;\n\nmodule.exports = memoize;\n","var Hash = require('./_Hash'),\n ListCache = require('./_ListCache'),\n Map = require('./_Map');\n\n/**\n * Removes all key-value entries from the map.\n *\n * @private\n * @name clear\n * @memberOf MapCache\n */\nfunction mapCacheClear() {\n this.size = 0;\n this.__data__ = {\n 'hash': new Hash,\n 'map': new (Map || ListCache),\n 'string': new Hash\n };\n}\n\nmodule.exports = mapCacheClear;\n","(function() { module.exports = window[\"eventespresso\"][\"eeComponents\"]; }());","var hashClear = require('./_hashClear'),\n hashDelete = require('./_hashDelete'),\n hashGet = require('./_hashGet'),\n hashHas = require('./_hashHas'),\n hashSet = require('./_hashSet');\n\n/**\n * Creates a hash object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\nfunction Hash(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n}\n\n// Add methods to `Hash`.\nHash.prototype.clear = hashClear;\nHash.prototype['delete'] = hashDelete;\nHash.prototype.get = hashGet;\nHash.prototype.has = hashHas;\nHash.prototype.set = hashSet;\n\nmodule.exports = Hash;\n","var nativeCreate = require('./_nativeCreate');\n\n/**\n * Removes all key-value entries from the hash.\n *\n * @private\n * @name clear\n * @memberOf Hash\n */\nfunction hashClear() {\n this.__data__ = nativeCreate ? nativeCreate(null) : {};\n this.size = 0;\n}\n\nmodule.exports = hashClear;\n","var isFunction = require('./isFunction'),\n isMasked = require('./_isMasked'),\n isObject = require('./isObject'),\n toSource = require('./_toSource');\n\n/**\n * Used to match `RegExp`\n * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns).\n */\nvar reRegExpChar = /[\\\\^$.*+?()[\\]{}|]/g;\n\n/** Used to detect host constructors (Safari). */\nvar reIsHostCtor = /^\\[object .+?Constructor\\]$/;\n\n/** Used for built-in method references. */\nvar funcProto = Function.prototype,\n objectProto = Object.prototype;\n\n/** Used to resolve the decompiled source of functions. */\nvar funcToString = funcProto.toString;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/** Used to detect if a method is native. */\nvar reIsNative = RegExp('^' +\n funcToString.call(hasOwnProperty).replace(reRegExpChar, '\\\\$&')\n .replace(/hasOwnProperty|(function).*?(?=\\\\\\()| for .+?(?=\\\\\\])/g, '$1.*?') + '$'\n);\n\n/**\n * The base implementation of `_.isNative` without bad shim checks.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a native function,\n * else `false`.\n */\nfunction baseIsNative(value) {\n if (!isObject(value) || isMasked(value)) {\n return false;\n }\n var pattern = isFunction(value) ? reIsNative : reIsHostCtor;\n return pattern.test(toSource(value));\n}\n\nmodule.exports = baseIsNative;\n","var coreJsData = require('./_coreJsData');\n\n/** Used to detect methods masquerading as native. */\nvar maskSrcKey = (function() {\n var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || '');\n return uid ? ('Symbol(src)_1.' + uid) : '';\n}());\n\n/**\n * Checks if `func` has its source masked.\n *\n * @private\n * @param {Function} func The function to check.\n * @returns {boolean} Returns `true` if `func` is masked, else `false`.\n */\nfunction isMasked(func) {\n return !!maskSrcKey && (maskSrcKey in func);\n}\n\nmodule.exports = isMasked;\n","var root = require('./_root');\n\n/** Used to detect overreaching core-js shims. */\nvar coreJsData = root['__core-js_shared__'];\n\nmodule.exports = coreJsData;\n","/**\n * Gets the value at `key` of `object`.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {string} key The key of the property to get.\n * @returns {*} Returns the property value.\n */\nfunction getValue(object, key) {\n return object == null ? undefined : object[key];\n}\n\nmodule.exports = getValue;\n","/**\n * Removes `key` and its value from the hash.\n *\n * @private\n * @name delete\n * @memberOf Hash\n * @param {Object} hash The hash to modify.\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction hashDelete(key) {\n var result = this.has(key) && delete this.__data__[key];\n this.size -= result ? 1 : 0;\n return result;\n}\n\nmodule.exports = hashDelete;\n","var nativeCreate = require('./_nativeCreate');\n\n/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Gets the hash value for `key`.\n *\n * @private\n * @name get\n * @memberOf Hash\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction hashGet(key) {\n var data = this.__data__;\n if (nativeCreate) {\n var result = data[key];\n return result === HASH_UNDEFINED ? undefined : result;\n }\n return hasOwnProperty.call(data, key) ? data[key] : undefined;\n}\n\nmodule.exports = hashGet;\n","var nativeCreate = require('./_nativeCreate');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Checks if a hash value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Hash\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction hashHas(key) {\n var data = this.__data__;\n return nativeCreate ? (data[key] !== undefined) : hasOwnProperty.call(data, key);\n}\n\nmodule.exports = hashHas;\n","var nativeCreate = require('./_nativeCreate');\n\n/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/**\n * Sets the hash `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Hash\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the hash instance.\n */\nfunction hashSet(key, value) {\n var data = this.__data__;\n this.size += this.has(key) ? 0 : 1;\n data[key] = (nativeCreate && value === undefined) ? HASH_UNDEFINED : value;\n return this;\n}\n\nmodule.exports = hashSet;\n","/**\n * Removes all key-value entries from the list cache.\n *\n * @private\n * @name clear\n * @memberOf ListCache\n */\nfunction listCacheClear() {\n this.__data__ = [];\n this.size = 0;\n}\n\nmodule.exports = listCacheClear;\n","var assocIndexOf = require('./_assocIndexOf');\n\n/** Used for built-in method references. */\nvar arrayProto = Array.prototype;\n\n/** Built-in value references. */\nvar splice = arrayProto.splice;\n\n/**\n * Removes `key` and its value from the list cache.\n *\n * @private\n * @name delete\n * @memberOf ListCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction listCacheDelete(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n return false;\n }\n var lastIndex = data.length - 1;\n if (index == lastIndex) {\n data.pop();\n } else {\n splice.call(data, index, 1);\n }\n --this.size;\n return true;\n}\n\nmodule.exports = listCacheDelete;\n","var assocIndexOf = require('./_assocIndexOf');\n\n/**\n * Gets the list cache value for `key`.\n *\n * @private\n * @name get\n * @memberOf ListCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction listCacheGet(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n return index < 0 ? undefined : data[index][1];\n}\n\nmodule.exports = listCacheGet;\n","var assocIndexOf = require('./_assocIndexOf');\n\n/**\n * Checks if a list cache value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf ListCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction listCacheHas(key) {\n return assocIndexOf(this.__data__, key) > -1;\n}\n\nmodule.exports = listCacheHas;\n","var assocIndexOf = require('./_assocIndexOf');\n\n/**\n * Sets the list cache `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf ListCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the list cache instance.\n */\nfunction listCacheSet(key, value) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n ++this.size;\n data.push([key, value]);\n } else {\n data[index][1] = value;\n }\n return this;\n}\n\nmodule.exports = listCacheSet;\n","var getMapData = require('./_getMapData');\n\n/**\n * Removes `key` and its value from the map.\n *\n * @private\n * @name delete\n * @memberOf MapCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction mapCacheDelete(key) {\n var result = getMapData(this, key)['delete'](key);\n this.size -= result ? 1 : 0;\n return result;\n}\n\nmodule.exports = mapCacheDelete;\n","/**\n * Checks if `value` is suitable for use as unique object key.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is suitable, else `false`.\n */\nfunction isKeyable(value) {\n var type = typeof value;\n return (type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean')\n ? (value !== '__proto__')\n : (value === null);\n}\n\nmodule.exports = isKeyable;\n","var getMapData = require('./_getMapData');\n\n/**\n * Gets the map value for `key`.\n *\n * @private\n * @name get\n * @memberOf MapCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction mapCacheGet(key) {\n return getMapData(this, key).get(key);\n}\n\nmodule.exports = mapCacheGet;\n","var getMapData = require('./_getMapData');\n\n/**\n * Checks if a map value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf MapCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction mapCacheHas(key) {\n return getMapData(this, key).has(key);\n}\n\nmodule.exports = mapCacheHas;\n","var getMapData = require('./_getMapData');\n\n/**\n * Sets the map `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf MapCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the map cache instance.\n */\nfunction mapCacheSet(key, value) {\n var data = getMapData(this, key),\n size = data.size;\n\n data.set(key, value);\n this.size += data.size == size ? 0 : 1;\n return this;\n}\n\nmodule.exports = mapCacheSet;\n","/*\nobject-assign\n(c) Sindre Sorhus\n@license MIT\n*/\n\n'use strict';\n/* eslint-disable no-unused-vars */\nvar getOwnPropertySymbols = Object.getOwnPropertySymbols;\nvar hasOwnProperty = Object.prototype.hasOwnProperty;\nvar propIsEnumerable = Object.prototype.propertyIsEnumerable;\n\nfunction toObject(val) {\n\tif (val === null || val === undefined) {\n\t\tthrow new TypeError('Object.assign cannot be called with null or undefined');\n\t}\n\n\treturn Object(val);\n}\n\nfunction shouldUseNative() {\n\ttry {\n\t\tif (!Object.assign) {\n\t\t\treturn false;\n\t\t}\n\n\t\t// Detect buggy property enumeration order in older V8 versions.\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=4118\n\t\tvar test1 = new String('abc'); // eslint-disable-line no-new-wrappers\n\t\ttest1[5] = 'de';\n\t\tif (Object.getOwnPropertyNames(test1)[0] === '5') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test2 = {};\n\t\tfor (var i = 0; i < 10; i++) {\n\t\t\ttest2['_' + String.fromCharCode(i)] = i;\n\t\t}\n\t\tvar order2 = Object.getOwnPropertyNames(test2).map(function (n) {\n\t\t\treturn test2[n];\n\t\t});\n\t\tif (order2.join('') !== '0123456789') {\n\t\t\treturn false;\n\t\t}\n\n\t\t// https://bugs.chromium.org/p/v8/issues/detail?id=3056\n\t\tvar test3 = {};\n\t\t'abcdefghijklmnopqrst'.split('').forEach(function (letter) {\n\t\t\ttest3[letter] = letter;\n\t\t});\n\t\tif (Object.keys(Object.assign({}, test3)).join('') !==\n\t\t\t\t'abcdefghijklmnopqrst') {\n\t\t\treturn false;\n\t\t}\n\n\t\treturn true;\n\t} catch (err) {\n\t\t// We don't expect any of the above to throw, but better to be safe.\n\t\treturn false;\n\t}\n}\n\nmodule.exports = shouldUseNative() ? Object.assign : function (target, source) {\n\tvar from;\n\tvar to = toObject(target);\n\tvar symbols;\n\n\tfor (var s = 1; s < arguments.length; s++) {\n\t\tfrom = Object(arguments[s]);\n\n\t\tfor (var key in from) {\n\t\t\tif (hasOwnProperty.call(from, key)) {\n\t\t\t\tto[key] = from[key];\n\t\t\t}\n\t\t}\n\n\t\tif (getOwnPropertySymbols) {\n\t\t\tsymbols = getOwnPropertySymbols(from);\n\t\t\tfor (var i = 0; i < symbols.length; i++) {\n\t\t\t\tif (propIsEnumerable.call(from, symbols[i])) {\n\t\t\t\t\tto[symbols[i]] = from[symbols[i]];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\treturn to;\n};\n","var Symbol = require('./_Symbol'),\n arrayMap = require('./_arrayMap'),\n isArray = require('./isArray'),\n isSymbol = require('./isSymbol');\n\n/** Used as references for various `Number` constants. */\nvar INFINITY = 1 / 0;\n\n/** Used to convert symbols to primitives and strings. */\nvar symbolProto = Symbol ? Symbol.prototype : undefined,\n symbolToString = symbolProto ? symbolProto.toString : undefined;\n\n/**\n * The base implementation of `_.toString` which doesn't convert nullish\n * values to empty strings.\n *\n * @private\n * @param {*} value The value to process.\n * @returns {string} Returns the string.\n */\nfunction baseToString(value) {\n // Exit early for strings to avoid a performance hit in some environments.\n if (typeof value == 'string') {\n return value;\n }\n if (isArray(value)) {\n // Recursively convert values (susceptible to call stack limits).\n return arrayMap(value, baseToString) + '';\n }\n if (isSymbol(value)) {\n return symbolToString ? symbolToString.call(value) : '';\n }\n var result = (value + '');\n return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;\n}\n\nmodule.exports = baseToString;\n","/**\n * A specialized version of `_.map` for arrays without support for iteratee\n * shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns the new mapped array.\n */\nfunction arrayMap(array, iteratee) {\n var index = -1,\n length = array == null ? 0 : array.length,\n result = Array(length);\n\n while (++index < length) {\n result[index] = iteratee(array[index], index, array);\n }\n return result;\n}\n\nmodule.exports = arrayMap;\n","var baseGetTag = require('./_baseGetTag'),\n isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]';\n\n/**\n * The base implementation of `_.isArguments`.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\n */\nfunction baseIsArguments(value) {\n return isObjectLike(value) && baseGetTag(value) == argsTag;\n}\n\nmodule.exports = baseIsArguments;\n","var getNative = require('./_getNative');\n\nvar defineProperty = (function() {\n try {\n var func = getNative(Object, 'defineProperty');\n func({}, '', {});\n return func;\n } catch (e) {}\n}());\n\nmodule.exports = defineProperty;\n","var createBaseFor = require('./_createBaseFor');\n\n/**\n * The base implementation of `baseForOwn` which iterates over `object`\n * properties returned by `keysFunc` and invokes `iteratee` for each property.\n * Iteratee functions may exit iteration early by explicitly returning `false`.\n *\n * @private\n * @param {Object} object The object to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @param {Function} keysFunc The function to get the keys of `object`.\n * @returns {Object} Returns `object`.\n */\nvar baseFor = createBaseFor();\n\nmodule.exports = baseFor;\n","/**\n * Creates a base function for methods like `_.forIn` and `_.forOwn`.\n *\n * @private\n * @param {boolean} [fromRight] Specify iterating from right to left.\n * @returns {Function} Returns the new base function.\n */\nfunction createBaseFor(fromRight) {\n return function(object, iteratee, keysFunc) {\n var index = -1,\n iterable = Object(object),\n props = keysFunc(object),\n length = props.length;\n\n while (length--) {\n var key = props[fromRight ? length : ++index];\n if (iteratee(iterable[key], key, iterable) === false) {\n break;\n }\n }\n return object;\n };\n}\n\nmodule.exports = createBaseFor;\n","var baseTimes = require('./_baseTimes'),\n isArguments = require('./isArguments'),\n isArray = require('./isArray'),\n isBuffer = require('./isBuffer'),\n isIndex = require('./_isIndex'),\n isTypedArray = require('./isTypedArray');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * Creates an array of the enumerable property names of the array-like `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @param {boolean} inherited Specify returning inherited property names.\n * @returns {Array} Returns the array of property names.\n */\nfunction arrayLikeKeys(value, inherited) {\n var isArr = isArray(value),\n isArg = !isArr && isArguments(value),\n isBuff = !isArr && !isArg && isBuffer(value),\n isType = !isArr && !isArg && !isBuff && isTypedArray(value),\n skipIndexes = isArr || isArg || isBuff || isType,\n result = skipIndexes ? baseTimes(value.length, String) : [],\n length = result.length;\n\n for (var key in value) {\n if ((inherited || hasOwnProperty.call(value, key)) &&\n !(skipIndexes && (\n // Safari 9 has enumerable `arguments.length` in strict mode.\n key == 'length' ||\n // Node.js 0.10 has enumerable non-index properties on buffers.\n (isBuff && (key == 'offset' || key == 'parent')) ||\n // PhantomJS 2 has enumerable non-index properties on typed arrays.\n (isType && (key == 'buffer' || key == 'byteLength' || key == 'byteOffset')) ||\n // Skip index properties.\n isIndex(key, length)\n ))) {\n result.push(key);\n }\n }\n return result;\n}\n\nmodule.exports = arrayLikeKeys;\n","/**\n * The base implementation of `_.times` without support for iteratee shorthands\n * or max array length checks.\n *\n * @private\n * @param {number} n The number of times to invoke `iteratee`.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns the array of results.\n */\nfunction baseTimes(n, iteratee) {\n var index = -1,\n result = Array(n);\n\n while (++index < n) {\n result[index] = iteratee(index);\n }\n return result;\n}\n\nmodule.exports = baseTimes;\n","/**\n * This method returns `false`.\n *\n * @static\n * @memberOf _\n * @since 4.13.0\n * @category Util\n * @returns {boolean} Returns `false`.\n * @example\n *\n * _.times(2, _.stubFalse);\n * // => [false, false]\n */\nfunction stubFalse() {\n return false;\n}\n\nmodule.exports = stubFalse;\n","var baseGetTag = require('./_baseGetTag'),\n isLength = require('./isLength'),\n isObjectLike = require('./isObjectLike');\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]',\n arrayTag = '[object Array]',\n boolTag = '[object Boolean]',\n dateTag = '[object Date]',\n errorTag = '[object Error]',\n funcTag = '[object Function]',\n mapTag = '[object Map]',\n numberTag = '[object Number]',\n objectTag = '[object Object]',\n regexpTag = '[object RegExp]',\n setTag = '[object Set]',\n stringTag = '[object String]',\n weakMapTag = '[object WeakMap]';\n\nvar arrayBufferTag = '[object ArrayBuffer]',\n dataViewTag = '[object DataView]',\n float32Tag = '[object Float32Array]',\n float64Tag = '[object Float64Array]',\n int8Tag = '[object Int8Array]',\n int16Tag = '[object Int16Array]',\n int32Tag = '[object Int32Array]',\n uint8Tag = '[object Uint8Array]',\n uint8ClampedTag = '[object Uint8ClampedArray]',\n uint16Tag = '[object Uint16Array]',\n uint32Tag = '[object Uint32Array]';\n\n/** Used to identify `toStringTag` values of typed arrays. */\nvar typedArrayTags = {};\ntypedArrayTags[float32Tag] = typedArrayTags[float64Tag] =\ntypedArrayTags[int8Tag] = typedArrayTags[int16Tag] =\ntypedArrayTags[int32Tag] = typedArrayTags[uint8Tag] =\ntypedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] =\ntypedArrayTags[uint32Tag] = true;\ntypedArrayTags[argsTag] = typedArrayTags[arrayTag] =\ntypedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] =\ntypedArrayTags[dataViewTag] = typedArrayTags[dateTag] =\ntypedArrayTags[errorTag] = typedArrayTags[funcTag] =\ntypedArrayTags[mapTag] = typedArrayTags[numberTag] =\ntypedArrayTags[objectTag] = typedArrayTags[regexpTag] =\ntypedArrayTags[setTag] = typedArrayTags[stringTag] =\ntypedArrayTags[weakMapTag] = false;\n\n/**\n * The base implementation of `_.isTypedArray` without Node.js optimizations.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n */\nfunction baseIsTypedArray(value) {\n return isObjectLike(value) &&\n isLength(value.length) && !!typedArrayTags[baseGetTag(value)];\n}\n\nmodule.exports = baseIsTypedArray;\n","/**\n * The base implementation of `_.unary` without support for storing metadata.\n *\n * @private\n * @param {Function} func The function to cap arguments for.\n * @returns {Function} Returns the new capped function.\n */\nfunction baseUnary(func) {\n return function(value) {\n return func(value);\n };\n}\n\nmodule.exports = baseUnary;\n","var freeGlobal = require('./_freeGlobal');\n\n/** Detect free variable `exports`. */\nvar freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n/** Detect free variable `module`. */\nvar freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n/** Detect the popular CommonJS extension `module.exports`. */\nvar moduleExports = freeModule && freeModule.exports === freeExports;\n\n/** Detect free variable `process` from Node.js. */\nvar freeProcess = moduleExports && freeGlobal.process;\n\n/** Used to access faster Node.js helpers. */\nvar nodeUtil = (function() {\n try {\n // Use `util.types` for Node.js 10+.\n var types = freeModule && freeModule.require && freeModule.require('util').types;\n\n if (types) {\n return types;\n }\n\n // Legacy `process.binding('util')` for Node.js < 10.\n return freeProcess && freeProcess.binding && freeProcess.binding('util');\n } catch (e) {}\n}());\n\nmodule.exports = nodeUtil;\n","var isPrototype = require('./_isPrototype'),\n nativeKeys = require('./_nativeKeys');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * The base implementation of `_.keys` which doesn't treat sparse arrays as dense.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n */\nfunction baseKeys(object) {\n if (!isPrototype(object)) {\n return nativeKeys(object);\n }\n var result = [];\n for (var key in Object(object)) {\n if (hasOwnProperty.call(object, key) && key != 'constructor') {\n result.push(key);\n }\n }\n return result;\n}\n\nmodule.exports = baseKeys;\n","/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Checks if `value` is likely a prototype object.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a prototype, else `false`.\n */\nfunction isPrototype(value) {\n var Ctor = value && value.constructor,\n proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto;\n\n return value === proto;\n}\n\nmodule.exports = isPrototype;\n","var overArg = require('./_overArg');\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeKeys = overArg(Object.keys, Object);\n\nmodule.exports = nativeKeys;\n","/**\n * Creates a unary function that invokes `func` with its argument transformed.\n *\n * @private\n * @param {Function} func The function to wrap.\n * @param {Function} transform The argument transform.\n * @returns {Function} Returns the new function.\n */\nfunction overArg(func, transform) {\n return function(arg) {\n return func(transform(arg));\n };\n}\n\nmodule.exports = overArg;\n","var isFunction = require('./isFunction'),\n isLength = require('./isLength');\n\n/**\n * Checks if `value` is array-like. A value is considered array-like if it's\n * not a function and has a `value.length` that's an integer greater than or\n * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is array-like, else `false`.\n * @example\n *\n * _.isArrayLike([1, 2, 3]);\n * // => true\n *\n * _.isArrayLike(document.body.children);\n * // => true\n *\n * _.isArrayLike('abc');\n * // => true\n *\n * _.isArrayLike(_.noop);\n * // => false\n */\nfunction isArrayLike(value) {\n return value != null && isLength(value.length) && !isFunction(value);\n}\n\nmodule.exports = isArrayLike;\n","var baseIsMatch = require('./_baseIsMatch'),\n getMatchData = require('./_getMatchData'),\n matchesStrictComparable = require('./_matchesStrictComparable');\n\n/**\n * The base implementation of `_.matches` which doesn't clone `source`.\n *\n * @private\n * @param {Object} source The object of property values to match.\n * @returns {Function} Returns the new spec function.\n */\nfunction baseMatches(source) {\n var matchData = getMatchData(source);\n if (matchData.length == 1 && matchData[0][2]) {\n return matchesStrictComparable(matchData[0][0], matchData[0][1]);\n }\n return function(object) {\n return object === source || baseIsMatch(object, source, matchData);\n };\n}\n\nmodule.exports = baseMatches;\n","var Stack = require('./_Stack'),\n baseIsEqual = require('./_baseIsEqual');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/**\n * The base implementation of `_.isMatch` without support for iteratee shorthands.\n *\n * @private\n * @param {Object} object The object to inspect.\n * @param {Object} source The object of property values to match.\n * @param {Array} matchData The property names, values, and compare flags to match.\n * @param {Function} [customizer] The function to customize comparisons.\n * @returns {boolean} Returns `true` if `object` is a match, else `false`.\n */\nfunction baseIsMatch(object, source, matchData, customizer) {\n var index = matchData.length,\n length = index,\n noCustomizer = !customizer;\n\n if (object == null) {\n return !length;\n }\n object = Object(object);\n while (index--) {\n var data = matchData[index];\n if ((noCustomizer && data[2])\n ? data[1] !== object[data[0]]\n : !(data[0] in object)\n ) {\n return false;\n }\n }\n while (++index < length) {\n data = matchData[index];\n var key = data[0],\n objValue = object[key],\n srcValue = data[1];\n\n if (noCustomizer && data[2]) {\n if (objValue === undefined && !(key in object)) {\n return false;\n }\n } else {\n var stack = new Stack;\n if (customizer) {\n var result = customizer(objValue, srcValue, key, object, source, stack);\n }\n if (!(result === undefined\n ? baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG, customizer, stack)\n : result\n )) {\n return false;\n }\n }\n }\n return true;\n}\n\nmodule.exports = baseIsMatch;\n","var ListCache = require('./_ListCache');\n\n/**\n * Removes all key-value entries from the stack.\n *\n * @private\n * @name clear\n * @memberOf Stack\n */\nfunction stackClear() {\n this.__data__ = new ListCache;\n this.size = 0;\n}\n\nmodule.exports = stackClear;\n","export default function _iterableToArray(iter) {\n if (typeof Symbol !== \"undefined\" && Symbol.iterator in Object(iter)) return Array.from(iter);\n}","/**\n * Removes `key` and its value from the stack.\n *\n * @private\n * @name delete\n * @memberOf Stack\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\nfunction stackDelete(key) {\n var data = this.__data__,\n result = data['delete'](key);\n\n this.size = data.size;\n return result;\n}\n\nmodule.exports = stackDelete;\n","/**\n * Gets the stack value for `key`.\n *\n * @private\n * @name get\n * @memberOf Stack\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\nfunction stackGet(key) {\n return this.__data__.get(key);\n}\n\nmodule.exports = stackGet;\n","/**\n * Checks if a stack value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Stack\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction stackHas(key) {\n return this.__data__.has(key);\n}\n\nmodule.exports = stackHas;\n","var ListCache = require('./_ListCache'),\n Map = require('./_Map'),\n MapCache = require('./_MapCache');\n\n/** Used as the size to enable large array optimizations. */\nvar LARGE_ARRAY_SIZE = 200;\n\n/**\n * Sets the stack `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Stack\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the stack cache instance.\n */\nfunction stackSet(key, value) {\n var data = this.__data__;\n if (data instanceof ListCache) {\n var pairs = data.__data__;\n if (!Map || (pairs.length < LARGE_ARRAY_SIZE - 1)) {\n pairs.push([key, value]);\n this.size = ++data.size;\n return this;\n }\n data = this.__data__ = new MapCache(pairs);\n }\n data.set(key, value);\n this.size = data.size;\n return this;\n}\n\nmodule.exports = stackSet;\n","var Stack = require('./_Stack'),\n equalArrays = require('./_equalArrays'),\n equalByTag = require('./_equalByTag'),\n equalObjects = require('./_equalObjects'),\n getTag = require('./_getTag'),\n isArray = require('./isArray'),\n isBuffer = require('./isBuffer'),\n isTypedArray = require('./isTypedArray');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1;\n\n/** `Object#toString` result references. */\nvar argsTag = '[object Arguments]',\n arrayTag = '[object Array]',\n objectTag = '[object Object]';\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * A specialized version of `baseIsEqual` for arrays and objects which performs\n * deep comparisons and tracks traversed objects enabling objects with circular\n * references to be compared.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} [stack] Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction baseIsEqualDeep(object, other, bitmask, customizer, equalFunc, stack) {\n var objIsArr = isArray(object),\n othIsArr = isArray(other),\n objTag = objIsArr ? arrayTag : getTag(object),\n othTag = othIsArr ? arrayTag : getTag(other);\n\n objTag = objTag == argsTag ? objectTag : objTag;\n othTag = othTag == argsTag ? objectTag : othTag;\n\n var objIsObj = objTag == objectTag,\n othIsObj = othTag == objectTag,\n isSameTag = objTag == othTag;\n\n if (isSameTag && isBuffer(object)) {\n if (!isBuffer(other)) {\n return false;\n }\n objIsArr = true;\n objIsObj = false;\n }\n if (isSameTag && !objIsObj) {\n stack || (stack = new Stack);\n return (objIsArr || isTypedArray(object))\n ? equalArrays(object, other, bitmask, customizer, equalFunc, stack)\n : equalByTag(object, other, objTag, bitmask, customizer, equalFunc, stack);\n }\n if (!(bitmask & COMPARE_PARTIAL_FLAG)) {\n var objIsWrapped = objIsObj && hasOwnProperty.call(object, '__wrapped__'),\n othIsWrapped = othIsObj && hasOwnProperty.call(other, '__wrapped__');\n\n if (objIsWrapped || othIsWrapped) {\n var objUnwrapped = objIsWrapped ? object.value() : object,\n othUnwrapped = othIsWrapped ? other.value() : other;\n\n stack || (stack = new Stack);\n return equalFunc(objUnwrapped, othUnwrapped, bitmask, customizer, stack);\n }\n }\n if (!isSameTag) {\n return false;\n }\n stack || (stack = new Stack);\n return equalObjects(object, other, bitmask, customizer, equalFunc, stack);\n}\n\nmodule.exports = baseIsEqualDeep;\n","var MapCache = require('./_MapCache'),\n setCacheAdd = require('./_setCacheAdd'),\n setCacheHas = require('./_setCacheHas');\n\n/**\n *\n * Creates an array cache object to store unique values.\n *\n * @private\n * @constructor\n * @param {Array} [values] The values to cache.\n */\nfunction SetCache(values) {\n var index = -1,\n length = values == null ? 0 : values.length;\n\n this.__data__ = new MapCache;\n while (++index < length) {\n this.add(values[index]);\n }\n}\n\n// Add methods to `SetCache`.\nSetCache.prototype.add = SetCache.prototype.push = setCacheAdd;\nSetCache.prototype.has = setCacheHas;\n\nmodule.exports = SetCache;\n","/** Used to stand-in for `undefined` hash values. */\nvar HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n/**\n * Adds `value` to the array cache.\n *\n * @private\n * @name add\n * @memberOf SetCache\n * @alias push\n * @param {*} value The value to cache.\n * @returns {Object} Returns the cache instance.\n */\nfunction setCacheAdd(value) {\n this.__data__.set(value, HASH_UNDEFINED);\n return this;\n}\n\nmodule.exports = setCacheAdd;\n","/**\n * Checks if `value` is in the array cache.\n *\n * @private\n * @name has\n * @memberOf SetCache\n * @param {*} value The value to search for.\n * @returns {number} Returns `true` if `value` is found, else `false`.\n */\nfunction setCacheHas(value) {\n return this.__data__.has(value);\n}\n\nmodule.exports = setCacheHas;\n","/**\n * A specialized version of `_.some` for arrays without support for iteratee\n * shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {boolean} Returns `true` if any element passes the predicate check,\n * else `false`.\n */\nfunction arraySome(array, predicate) {\n var index = -1,\n length = array == null ? 0 : array.length;\n\n while (++index < length) {\n if (predicate(array[index], index, array)) {\n return true;\n }\n }\n return false;\n}\n\nmodule.exports = arraySome;\n","/**\n * Checks if a `cache` value for `key` exists.\n *\n * @private\n * @param {Object} cache The cache to query.\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\nfunction cacheHas(cache, key) {\n return cache.has(key);\n}\n\nmodule.exports = cacheHas;\n","var Symbol = require('./_Symbol'),\n Uint8Array = require('./_Uint8Array'),\n eq = require('./eq'),\n equalArrays = require('./_equalArrays'),\n mapToArray = require('./_mapToArray'),\n setToArray = require('./_setToArray');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/** `Object#toString` result references. */\nvar boolTag = '[object Boolean]',\n dateTag = '[object Date]',\n errorTag = '[object Error]',\n mapTag = '[object Map]',\n numberTag = '[object Number]',\n regexpTag = '[object RegExp]',\n setTag = '[object Set]',\n stringTag = '[object String]',\n symbolTag = '[object Symbol]';\n\nvar arrayBufferTag = '[object ArrayBuffer]',\n dataViewTag = '[object DataView]';\n\n/** Used to convert symbols to primitives and strings. */\nvar symbolProto = Symbol ? Symbol.prototype : undefined,\n symbolValueOf = symbolProto ? symbolProto.valueOf : undefined;\n\n/**\n * A specialized version of `baseIsEqualDeep` for comparing objects of\n * the same `toStringTag`.\n *\n * **Note:** This function only supports comparing values with tags of\n * `Boolean`, `Date`, `Error`, `Number`, `RegExp`, or `String`.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {string} tag The `toStringTag` of the objects to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction equalByTag(object, other, tag, bitmask, customizer, equalFunc, stack) {\n switch (tag) {\n case dataViewTag:\n if ((object.byteLength != other.byteLength) ||\n (object.byteOffset != other.byteOffset)) {\n return false;\n }\n object = object.buffer;\n other = other.buffer;\n\n case arrayBufferTag:\n if ((object.byteLength != other.byteLength) ||\n !equalFunc(new Uint8Array(object), new Uint8Array(other))) {\n return false;\n }\n return true;\n\n case boolTag:\n case dateTag:\n case numberTag:\n // Coerce booleans to `1` or `0` and dates to milliseconds.\n // Invalid dates are coerced to `NaN`.\n return eq(+object, +other);\n\n case errorTag:\n return object.name == other.name && object.message == other.message;\n\n case regexpTag:\n case stringTag:\n // Coerce regexes to strings and treat strings, primitives and objects,\n // as equal. See http://www.ecma-international.org/ecma-262/7.0/#sec-regexp.prototype.tostring\n // for more details.\n return object == (other + '');\n\n case mapTag:\n var convert = mapToArray;\n\n case setTag:\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG;\n convert || (convert = setToArray);\n\n if (object.size != other.size && !isPartial) {\n return false;\n }\n // Assume cyclic values are equal.\n var stacked = stack.get(object);\n if (stacked) {\n return stacked == other;\n }\n bitmask |= COMPARE_UNORDERED_FLAG;\n\n // Recursively compare objects (susceptible to call stack limits).\n stack.set(object, other);\n var result = equalArrays(convert(object), convert(other), bitmask, customizer, equalFunc, stack);\n stack['delete'](object);\n return result;\n\n case symbolTag:\n if (symbolValueOf) {\n return symbolValueOf.call(object) == symbolValueOf.call(other);\n }\n }\n return false;\n}\n\nmodule.exports = equalByTag;\n","var root = require('./_root');\n\n/** Built-in value references. */\nvar Uint8Array = root.Uint8Array;\n\nmodule.exports = Uint8Array;\n","/**\n * Converts `map` to its key-value pairs.\n *\n * @private\n * @param {Object} map The map to convert.\n * @returns {Array} Returns the key-value pairs.\n */\nfunction mapToArray(map) {\n var index = -1,\n result = Array(map.size);\n\n map.forEach(function(value, key) {\n result[++index] = [key, value];\n });\n return result;\n}\n\nmodule.exports = mapToArray;\n","/**\n * Converts `set` to an array of its values.\n *\n * @private\n * @param {Object} set The set to convert.\n * @returns {Array} Returns the values.\n */\nfunction setToArray(set) {\n var index = -1,\n result = Array(set.size);\n\n set.forEach(function(value) {\n result[++index] = value;\n });\n return result;\n}\n\nmodule.exports = setToArray;\n","var getAllKeys = require('./_getAllKeys');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1;\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Used to check objects for own properties. */\nvar hasOwnProperty = objectProto.hasOwnProperty;\n\n/**\n * A specialized version of `baseIsEqualDeep` for objects with support for\n * partial deep comparisons.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\nfunction equalObjects(object, other, bitmask, customizer, equalFunc, stack) {\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG,\n objProps = getAllKeys(object),\n objLength = objProps.length,\n othProps = getAllKeys(other),\n othLength = othProps.length;\n\n if (objLength != othLength && !isPartial) {\n return false;\n }\n var index = objLength;\n while (index--) {\n var key = objProps[index];\n if (!(isPartial ? key in other : hasOwnProperty.call(other, key))) {\n return false;\n }\n }\n // Check that cyclic values are equal.\n var objStacked = stack.get(object);\n var othStacked = stack.get(other);\n if (objStacked && othStacked) {\n return objStacked == other && othStacked == object;\n }\n var result = true;\n stack.set(object, other);\n stack.set(other, object);\n\n var skipCtor = isPartial;\n while (++index < objLength) {\n key = objProps[index];\n var objValue = object[key],\n othValue = other[key];\n\n if (customizer) {\n var compared = isPartial\n ? customizer(othValue, objValue, key, other, object, stack)\n : customizer(objValue, othValue, key, object, other, stack);\n }\n // Recursively compare objects (susceptible to call stack limits).\n if (!(compared === undefined\n ? (objValue === othValue || equalFunc(objValue, othValue, bitmask, customizer, stack))\n : compared\n )) {\n result = false;\n break;\n }\n skipCtor || (skipCtor = key == 'constructor');\n }\n if (result && !skipCtor) {\n var objCtor = object.constructor,\n othCtor = other.constructor;\n\n // Non `Object` object instances with different constructors are not equal.\n if (objCtor != othCtor &&\n ('constructor' in object && 'constructor' in other) &&\n !(typeof objCtor == 'function' && objCtor instanceof objCtor &&\n typeof othCtor == 'function' && othCtor instanceof othCtor)) {\n result = false;\n }\n }\n stack['delete'](object);\n stack['delete'](other);\n return result;\n}\n\nmodule.exports = equalObjects;\n","var baseGetAllKeys = require('./_baseGetAllKeys'),\n getSymbols = require('./_getSymbols'),\n keys = require('./keys');\n\n/**\n * Creates an array of own enumerable property names and symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names and symbols.\n */\nfunction getAllKeys(object) {\n return baseGetAllKeys(object, keys, getSymbols);\n}\n\nmodule.exports = getAllKeys;\n","var arrayPush = require('./_arrayPush'),\n isArray = require('./isArray');\n\n/**\n * The base implementation of `getAllKeys` and `getAllKeysIn` which uses\n * `keysFunc` and `symbolsFunc` to get the enumerable property names and\n * symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Function} keysFunc The function to get the keys of `object`.\n * @param {Function} symbolsFunc The function to get the symbols of `object`.\n * @returns {Array} Returns the array of property names and symbols.\n */\nfunction baseGetAllKeys(object, keysFunc, symbolsFunc) {\n var result = keysFunc(object);\n return isArray(object) ? result : arrayPush(result, symbolsFunc(object));\n}\n\nmodule.exports = baseGetAllKeys;\n","/**\n * Appends the elements of `values` to `array`.\n *\n * @private\n * @param {Array} array The array to modify.\n * @param {Array} values The values to append.\n * @returns {Array} Returns `array`.\n */\nfunction arrayPush(array, values) {\n var index = -1,\n length = values.length,\n offset = array.length;\n\n while (++index < length) {\n array[offset + index] = values[index];\n }\n return array;\n}\n\nmodule.exports = arrayPush;\n","var arrayFilter = require('./_arrayFilter'),\n stubArray = require('./stubArray');\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/** Built-in value references. */\nvar propertyIsEnumerable = objectProto.propertyIsEnumerable;\n\n/* Built-in method references for those with the same name as other `lodash` methods. */\nvar nativeGetSymbols = Object.getOwnPropertySymbols;\n\n/**\n * Creates an array of the own enumerable symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of symbols.\n */\nvar getSymbols = !nativeGetSymbols ? stubArray : function(object) {\n if (object == null) {\n return [];\n }\n object = Object(object);\n return arrayFilter(nativeGetSymbols(object), function(symbol) {\n return propertyIsEnumerable.call(object, symbol);\n });\n};\n\nmodule.exports = getSymbols;\n","/**\n * A specialized version of `_.filter` for arrays without support for\n * iteratee shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {Array} Returns the new filtered array.\n */\nfunction arrayFilter(array, predicate) {\n var index = -1,\n length = array == null ? 0 : array.length,\n resIndex = 0,\n result = [];\n\n while (++index < length) {\n var value = array[index];\n if (predicate(value, index, array)) {\n result[resIndex++] = value;\n }\n }\n return result;\n}\n\nmodule.exports = arrayFilter;\n","/**\n * This method returns a new empty array.\n *\n * @static\n * @memberOf _\n * @since 4.13.0\n * @category Util\n * @returns {Array} Returns the new empty array.\n * @example\n *\n * var arrays = _.times(2, _.stubArray);\n *\n * console.log(arrays);\n * // => [[], []]\n *\n * console.log(arrays[0] === arrays[1]);\n * // => false\n */\nfunction stubArray() {\n return [];\n}\n\nmodule.exports = stubArray;\n","var DataView = require('./_DataView'),\n Map = require('./_Map'),\n Promise = require('./_Promise'),\n Set = require('./_Set'),\n WeakMap = require('./_WeakMap'),\n baseGetTag = require('./_baseGetTag'),\n toSource = require('./_toSource');\n\n/** `Object#toString` result references. */\nvar mapTag = '[object Map]',\n objectTag = '[object Object]',\n promiseTag = '[object Promise]',\n setTag = '[object Set]',\n weakMapTag = '[object WeakMap]';\n\nvar dataViewTag = '[object DataView]';\n\n/** Used to detect maps, sets, and weakmaps. */\nvar dataViewCtorString = toSource(DataView),\n mapCtorString = toSource(Map),\n promiseCtorString = toSource(Promise),\n setCtorString = toSource(Set),\n weakMapCtorString = toSource(WeakMap);\n\n/**\n * Gets the `toStringTag` of `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\nvar getTag = baseGetTag;\n\n// Fallback for data views, maps, sets, and weak maps in IE 11 and promises in Node.js < 6.\nif ((DataView && getTag(new DataView(new ArrayBuffer(1))) != dataViewTag) ||\n (Map && getTag(new Map) != mapTag) ||\n (Promise && getTag(Promise.resolve()) != promiseTag) ||\n (Set && getTag(new Set) != setTag) ||\n (WeakMap && getTag(new WeakMap) != weakMapTag)) {\n getTag = function(value) {\n var result = baseGetTag(value),\n Ctor = result == objectTag ? value.constructor : undefined,\n ctorString = Ctor ? toSource(Ctor) : '';\n\n if (ctorString) {\n switch (ctorString) {\n case dataViewCtorString: return dataViewTag;\n case mapCtorString: return mapTag;\n case promiseCtorString: return promiseTag;\n case setCtorString: return setTag;\n case weakMapCtorString: return weakMapTag;\n }\n }\n return result;\n };\n}\n\nmodule.exports = getTag;\n","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar DataView = getNative(root, 'DataView');\n\nmodule.exports = DataView;\n","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar Promise = getNative(root, 'Promise');\n\nmodule.exports = Promise;\n","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar Set = getNative(root, 'Set');\n\nmodule.exports = Set;\n","var getNative = require('./_getNative'),\n root = require('./_root');\n\n/* Built-in method references that are verified to be native. */\nvar WeakMap = getNative(root, 'WeakMap');\n\nmodule.exports = WeakMap;\n","var isStrictComparable = require('./_isStrictComparable'),\n keys = require('./keys');\n\n/**\n * Gets the property names, values, and compare flags of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the match data of `object`.\n */\nfunction getMatchData(object) {\n var result = keys(object),\n length = result.length;\n\n while (length--) {\n var key = result[length],\n value = object[key];\n\n result[length] = [key, value, isStrictComparable(value)];\n }\n return result;\n}\n\nmodule.exports = getMatchData;\n","var baseIsEqual = require('./_baseIsEqual'),\n get = require('./get'),\n hasIn = require('./hasIn'),\n isKey = require('./_isKey'),\n isStrictComparable = require('./_isStrictComparable'),\n matchesStrictComparable = require('./_matchesStrictComparable'),\n toKey = require('./_toKey');\n\n/** Used to compose bitmasks for value comparisons. */\nvar COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n/**\n * The base implementation of `_.matchesProperty` which doesn't clone `srcValue`.\n *\n * @private\n * @param {string} path The path of the property to get.\n * @param {*} srcValue The value to match.\n * @returns {Function} Returns the new spec function.\n */\nfunction baseMatchesProperty(path, srcValue) {\n if (isKey(path) && isStrictComparable(srcValue)) {\n return matchesStrictComparable(toKey(path), srcValue);\n }\n return function(object) {\n var objValue = get(object, path);\n return (objValue === undefined && objValue === srcValue)\n ? hasIn(object, path)\n : baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG);\n };\n}\n\nmodule.exports = baseMatchesProperty;\n","var baseGet = require('./_baseGet');\n\n/**\n * Gets the value at `path` of `object`. If the resolved value is\n * `undefined`, the `defaultValue` is returned in its place.\n *\n * @static\n * @memberOf _\n * @since 3.7.0\n * @category Object\n * @param {Object} object The object to query.\n * @param {Array|string} path The path of the property to get.\n * @param {*} [defaultValue] The value returned for `undefined` resolved values.\n * @returns {*} Returns the resolved value.\n * @example\n *\n * var object = { 'a': [{ 'b': { 'c': 3 } }] };\n *\n * _.get(object, 'a[0].b.c');\n * // => 3\n *\n * _.get(object, ['a', '0', 'b', 'c']);\n * // => 3\n *\n * _.get(object, 'a.b.c', 'default');\n * // => 'default'\n */\nfunction get(object, path, defaultValue) {\n var result = object == null ? undefined : baseGet(object, path);\n return result === undefined ? defaultValue : result;\n}\n\nmodule.exports = get;\n","var baseHasIn = require('./_baseHasIn'),\n hasPath = require('./_hasPath');\n\n/**\n * Checks if `path` is a direct or inherited property of `object`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Object\n * @param {Object} object The object to query.\n * @param {Array|string} path The path to check.\n * @returns {boolean} Returns `true` if `path` exists, else `false`.\n * @example\n *\n * var object = _.create({ 'a': _.create({ 'b': 2 }) });\n *\n * _.hasIn(object, 'a');\n * // => true\n *\n * _.hasIn(object, 'a.b');\n * // => true\n *\n * _.hasIn(object, ['a', 'b']);\n * // => true\n *\n * _.hasIn(object, 'b');\n * // => false\n */\nfunction hasIn(object, path) {\n return object != null && hasPath(object, path, baseHasIn);\n}\n\nmodule.exports = hasIn;\n","/**\n * The base implementation of `_.hasIn` without support for deep paths.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {Array|string} key The key to check.\n * @returns {boolean} Returns `true` if `key` exists, else `false`.\n */\nfunction baseHasIn(object, key) {\n return object != null && key in Object(object);\n}\n\nmodule.exports = baseHasIn;\n","/**\n * This method returns the first argument it receives.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Util\n * @param {*} value Any value.\n * @returns {*} Returns `value`.\n * @example\n *\n * var object = { 'a': 1 };\n *\n * console.log(_.identity(object) === object);\n * // => true\n */\nfunction identity(value) {\n return value;\n}\n\nmodule.exports = identity;\n","var baseProperty = require('./_baseProperty'),\n basePropertyDeep = require('./_basePropertyDeep'),\n isKey = require('./_isKey'),\n toKey = require('./_toKey');\n\n/**\n * Creates a function that returns the value at `path` of a given object.\n *\n * @static\n * @memberOf _\n * @since 2.4.0\n * @category Util\n * @param {Array|string} path The path of the property to get.\n * @returns {Function} Returns the new accessor function.\n * @example\n *\n * var objects = [\n * { 'a': { 'b': 2 } },\n * { 'a': { 'b': 1 } }\n * ];\n *\n * _.map(objects, _.property('a.b'));\n * // => [2, 1]\n *\n * _.map(_.sortBy(objects, _.property(['a', 'b'])), 'a.b');\n * // => [1, 2]\n */\nfunction property(path) {\n return isKey(path) ? baseProperty(toKey(path)) : basePropertyDeep(path);\n}\n\nmodule.exports = property;\n","/**\n * The base implementation of `_.property` without support for deep paths.\n *\n * @private\n * @param {string} key The key of the property to get.\n * @returns {Function} Returns the new accessor function.\n */\nfunction baseProperty(key) {\n return function(object) {\n return object == null ? undefined : object[key];\n };\n}\n\nmodule.exports = baseProperty;\n","var baseGet = require('./_baseGet');\n\n/**\n * A specialized version of `baseProperty` which supports deep paths.\n *\n * @private\n * @param {Array|string} path The path of the property to get.\n * @returns {Function} Returns the new accessor function.\n */\nfunction basePropertyDeep(path) {\n return function(object) {\n return baseGet(object, path);\n };\n}\n\nmodule.exports = basePropertyDeep;\n","/**\n * A specialized version of `_.reduce` for arrays without support for\n * iteratee shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @param {*} [accumulator] The initial value.\n * @param {boolean} [initAccum] Specify using the first element of `array` as\n * the initial value.\n * @returns {*} Returns the accumulated value.\n */\nfunction arrayReduce(array, iteratee, accumulator, initAccum) {\n var index = -1,\n length = array == null ? 0 : array.length;\n\n if (initAccum && length) {\n accumulator = array[++index];\n }\n while (++index < length) {\n accumulator = iteratee(accumulator, array[index], index, array);\n }\n return accumulator;\n}\n\nmodule.exports = arrayReduce;\n","var deburrLetter = require('./_deburrLetter'),\n toString = require('./toString');\n\n/** Used to match Latin Unicode letters (excluding mathematical operators). */\nvar reLatin = /[\\xc0-\\xd6\\xd8-\\xf6\\xf8-\\xff\\u0100-\\u017f]/g;\n\n/** Used to compose unicode character classes. */\nvar rsComboMarksRange = '\\\\u0300-\\\\u036f',\n reComboHalfMarksRange = '\\\\ufe20-\\\\ufe2f',\n rsComboSymbolsRange = '\\\\u20d0-\\\\u20ff',\n rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange;\n\n/** Used to compose unicode capture groups. */\nvar rsCombo = '[' + rsComboRange + ']';\n\n/**\n * Used to match [combining diacritical marks](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks) and\n * [combining diacritical marks for symbols](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks_for_Symbols).\n */\nvar reComboMark = RegExp(rsCombo, 'g');\n\n/**\n * Deburrs `string` by converting\n * [Latin-1 Supplement](https://en.wikipedia.org/wiki/Latin-1_Supplement_(Unicode_block)#Character_table)\n * and [Latin Extended-A](https://en.wikipedia.org/wiki/Latin_Extended-A)\n * letters to basic Latin letters and removing\n * [combining diacritical marks](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks).\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to deburr.\n * @returns {string} Returns the deburred string.\n * @example\n *\n * _.deburr('déjà vu');\n * // => 'deja vu'\n */\nfunction deburr(string) {\n string = toString(string);\n return string && string.replace(reLatin, deburrLetter).replace(reComboMark, '');\n}\n\nmodule.exports = deburr;\n","var basePropertyOf = require('./_basePropertyOf');\n\n/** Used to map Latin Unicode letters to basic Latin letters. */\nvar deburredLetters = {\n // Latin-1 Supplement block.\n '\\xc0': 'A', '\\xc1': 'A', '\\xc2': 'A', '\\xc3': 'A', '\\xc4': 'A', '\\xc5': 'A',\n '\\xe0': 'a', '\\xe1': 'a', '\\xe2': 'a', '\\xe3': 'a', '\\xe4': 'a', '\\xe5': 'a',\n '\\xc7': 'C', '\\xe7': 'c',\n '\\xd0': 'D', '\\xf0': 'd',\n '\\xc8': 'E', '\\xc9': 'E', '\\xca': 'E', '\\xcb': 'E',\n '\\xe8': 'e', '\\xe9': 'e', '\\xea': 'e', '\\xeb': 'e',\n '\\xcc': 'I', '\\xcd': 'I', '\\xce': 'I', '\\xcf': 'I',\n '\\xec': 'i', '\\xed': 'i', '\\xee': 'i', '\\xef': 'i',\n '\\xd1': 'N', '\\xf1': 'n',\n '\\xd2': 'O', '\\xd3': 'O', '\\xd4': 'O', '\\xd5': 'O', '\\xd6': 'O', '\\xd8': 'O',\n '\\xf2': 'o', '\\xf3': 'o', '\\xf4': 'o', '\\xf5': 'o', '\\xf6': 'o', '\\xf8': 'o',\n '\\xd9': 'U', '\\xda': 'U', '\\xdb': 'U', '\\xdc': 'U',\n '\\xf9': 'u', '\\xfa': 'u', '\\xfb': 'u', '\\xfc': 'u',\n '\\xdd': 'Y', '\\xfd': 'y', '\\xff': 'y',\n '\\xc6': 'Ae', '\\xe6': 'ae',\n '\\xde': 'Th', '\\xfe': 'th',\n '\\xdf': 'ss',\n // Latin Extended-A block.\n '\\u0100': 'A', '\\u0102': 'A', '\\u0104': 'A',\n '\\u0101': 'a', '\\u0103': 'a', '\\u0105': 'a',\n '\\u0106': 'C', '\\u0108': 'C', '\\u010a': 'C', '\\u010c': 'C',\n '\\u0107': 'c', '\\u0109': 'c', '\\u010b': 'c', '\\u010d': 'c',\n '\\u010e': 'D', '\\u0110': 'D', '\\u010f': 'd', '\\u0111': 'd',\n '\\u0112': 'E', '\\u0114': 'E', '\\u0116': 'E', '\\u0118': 'E', '\\u011a': 'E',\n '\\u0113': 'e', '\\u0115': 'e', '\\u0117': 'e', '\\u0119': 'e', '\\u011b': 'e',\n '\\u011c': 'G', '\\u011e': 'G', '\\u0120': 'G', '\\u0122': 'G',\n '\\u011d': 'g', '\\u011f': 'g', '\\u0121': 'g', '\\u0123': 'g',\n '\\u0124': 'H', '\\u0126': 'H', '\\u0125': 'h', '\\u0127': 'h',\n '\\u0128': 'I', '\\u012a': 'I', '\\u012c': 'I', '\\u012e': 'I', '\\u0130': 'I',\n '\\u0129': 'i', '\\u012b': 'i', '\\u012d': 'i', '\\u012f': 'i', '\\u0131': 'i',\n '\\u0134': 'J', '\\u0135': 'j',\n '\\u0136': 'K', '\\u0137': 'k', '\\u0138': 'k',\n '\\u0139': 'L', '\\u013b': 'L', '\\u013d': 'L', '\\u013f': 'L', '\\u0141': 'L',\n '\\u013a': 'l', '\\u013c': 'l', '\\u013e': 'l', '\\u0140': 'l', '\\u0142': 'l',\n '\\u0143': 'N', '\\u0145': 'N', '\\u0147': 'N', '\\u014a': 'N',\n '\\u0144': 'n', '\\u0146': 'n', '\\u0148': 'n', '\\u014b': 'n',\n '\\u014c': 'O', '\\u014e': 'O', '\\u0150': 'O',\n '\\u014d': 'o', '\\u014f': 'o', '\\u0151': 'o',\n '\\u0154': 'R', '\\u0156': 'R', '\\u0158': 'R',\n '\\u0155': 'r', '\\u0157': 'r', '\\u0159': 'r',\n '\\u015a': 'S', '\\u015c': 'S', '\\u015e': 'S', '\\u0160': 'S',\n '\\u015b': 's', '\\u015d': 's', '\\u015f': 's', '\\u0161': 's',\n '\\u0162': 'T', '\\u0164': 'T', '\\u0166': 'T',\n '\\u0163': 't', '\\u0165': 't', '\\u0167': 't',\n '\\u0168': 'U', '\\u016a': 'U', '\\u016c': 'U', '\\u016e': 'U', '\\u0170': 'U', '\\u0172': 'U',\n '\\u0169': 'u', '\\u016b': 'u', '\\u016d': 'u', '\\u016f': 'u', '\\u0171': 'u', '\\u0173': 'u',\n '\\u0174': 'W', '\\u0175': 'w',\n '\\u0176': 'Y', '\\u0177': 'y', '\\u0178': 'Y',\n '\\u0179': 'Z', '\\u017b': 'Z', '\\u017d': 'Z',\n '\\u017a': 'z', '\\u017c': 'z', '\\u017e': 'z',\n '\\u0132': 'IJ', '\\u0133': 'ij',\n '\\u0152': 'Oe', '\\u0153': 'oe',\n '\\u0149': \"'n\", '\\u017f': 's'\n};\n\n/**\n * Used by `_.deburr` to convert Latin-1 Supplement and Latin Extended-A\n * letters to basic Latin letters.\n *\n * @private\n * @param {string} letter The matched letter to deburr.\n * @returns {string} Returns the deburred letter.\n */\nvar deburrLetter = basePropertyOf(deburredLetters);\n\nmodule.exports = deburrLetter;\n","/**\n * The base implementation of `_.propertyOf` without support for deep paths.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Function} Returns the new accessor function.\n */\nfunction basePropertyOf(object) {\n return function(key) {\n return object == null ? undefined : object[key];\n };\n}\n\nmodule.exports = basePropertyOf;\n","var asciiWords = require('./_asciiWords'),\n hasUnicodeWord = require('./_hasUnicodeWord'),\n toString = require('./toString'),\n unicodeWords = require('./_unicodeWords');\n\n/**\n * Splits `string` into an array of its words.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to inspect.\n * @param {RegExp|string} [pattern] The pattern to match words.\n * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.\n * @returns {Array} Returns the words of `string`.\n * @example\n *\n * _.words('fred, barney, & pebbles');\n * // => ['fred', 'barney', 'pebbles']\n *\n * _.words('fred, barney, & pebbles', /[^, ]+/g);\n * // => ['fred', 'barney', '&', 'pebbles']\n */\nfunction words(string, pattern, guard) {\n string = toString(string);\n pattern = guard ? undefined : pattern;\n\n if (pattern === undefined) {\n return hasUnicodeWord(string) ? unicodeWords(string) : asciiWords(string);\n }\n return string.match(pattern) || [];\n}\n\nmodule.exports = words;\n","/** Used to match words composed of alphanumeric characters. */\nvar reAsciiWord = /[^\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\x7f]+/g;\n\n/**\n * Splits an ASCII `string` into an array of its words.\n *\n * @private\n * @param {string} The string to inspect.\n * @returns {Array} Returns the words of `string`.\n */\nfunction asciiWords(string) {\n return string.match(reAsciiWord) || [];\n}\n\nmodule.exports = asciiWords;\n","/** Used to detect strings that need a more robust regexp to match words. */\nvar reHasUnicodeWord = /[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;\n\n/**\n * Checks if `string` contains a word composed of Unicode symbols.\n *\n * @private\n * @param {string} string The string to inspect.\n * @returns {boolean} Returns `true` if a word is found, else `false`.\n */\nfunction hasUnicodeWord(string) {\n return reHasUnicodeWord.test(string);\n}\n\nmodule.exports = hasUnicodeWord;\n","/** Used to compose unicode character classes. */\nvar rsAstralRange = '\\\\ud800-\\\\udfff',\n rsComboMarksRange = '\\\\u0300-\\\\u036f',\n reComboHalfMarksRange = '\\\\ufe20-\\\\ufe2f',\n rsComboSymbolsRange = '\\\\u20d0-\\\\u20ff',\n rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange,\n rsDingbatRange = '\\\\u2700-\\\\u27bf',\n rsLowerRange = 'a-z\\\\xdf-\\\\xf6\\\\xf8-\\\\xff',\n rsMathOpRange = '\\\\xac\\\\xb1\\\\xd7\\\\xf7',\n rsNonCharRange = '\\\\x00-\\\\x2f\\\\x3a-\\\\x40\\\\x5b-\\\\x60\\\\x7b-\\\\xbf',\n rsPunctuationRange = '\\\\u2000-\\\\u206f',\n rsSpaceRange = ' \\\\t\\\\x0b\\\\f\\\\xa0\\\\ufeff\\\\n\\\\r\\\\u2028\\\\u2029\\\\u1680\\\\u180e\\\\u2000\\\\u2001\\\\u2002\\\\u2003\\\\u2004\\\\u2005\\\\u2006\\\\u2007\\\\u2008\\\\u2009\\\\u200a\\\\u202f\\\\u205f\\\\u3000',\n rsUpperRange = 'A-Z\\\\xc0-\\\\xd6\\\\xd8-\\\\xde',\n rsVarRange = '\\\\ufe0e\\\\ufe0f',\n rsBreakRange = rsMathOpRange + rsNonCharRange + rsPunctuationRange + rsSpaceRange;\n\n/** Used to compose unicode capture groups. */\nvar rsApos = \"['\\u2019]\",\n rsBreak = '[' + rsBreakRange + ']',\n rsCombo = '[' + rsComboRange + ']',\n rsDigits = '\\\\d+',\n rsDingbat = '[' + rsDingbatRange + ']',\n rsLower = '[' + rsLowerRange + ']',\n rsMisc = '[^' + rsAstralRange + rsBreakRange + rsDigits + rsDingbatRange + rsLowerRange + rsUpperRange + ']',\n rsFitz = '\\\\ud83c[\\\\udffb-\\\\udfff]',\n rsModifier = '(?:' + rsCombo + '|' + rsFitz + ')',\n rsNonAstral = '[^' + rsAstralRange + ']',\n rsRegional = '(?:\\\\ud83c[\\\\udde6-\\\\uddff]){2}',\n rsSurrPair = '[\\\\ud800-\\\\udbff][\\\\udc00-\\\\udfff]',\n rsUpper = '[' + rsUpperRange + ']',\n rsZWJ = '\\\\u200d';\n\n/** Used to compose unicode regexes. */\nvar rsMiscLower = '(?:' + rsLower + '|' + rsMisc + ')',\n rsMiscUpper = '(?:' + rsUpper + '|' + rsMisc + ')',\n rsOptContrLower = '(?:' + rsApos + '(?:d|ll|m|re|s|t|ve))?',\n rsOptContrUpper = '(?:' + rsApos + '(?:D|LL|M|RE|S|T|VE))?',\n reOptMod = rsModifier + '?',\n rsOptVar = '[' + rsVarRange + ']?',\n rsOptJoin = '(?:' + rsZWJ + '(?:' + [rsNonAstral, rsRegional, rsSurrPair].join('|') + ')' + rsOptVar + reOptMod + ')*',\n rsOrdLower = '\\\\d*(?:1st|2nd|3rd|(?![123])\\\\dth)(?=\\\\b|[A-Z_])',\n rsOrdUpper = '\\\\d*(?:1ST|2ND|3RD|(?![123])\\\\dTH)(?=\\\\b|[a-z_])',\n rsSeq = rsOptVar + reOptMod + rsOptJoin,\n rsEmoji = '(?:' + [rsDingbat, rsRegional, rsSurrPair].join('|') + ')' + rsSeq;\n\n/** Used to match complex or compound words. */\nvar reUnicodeWord = RegExp([\n rsUpper + '?' + rsLower + '+' + rsOptContrLower + '(?=' + [rsBreak, rsUpper, '$'].join('|') + ')',\n rsMiscUpper + '+' + rsOptContrUpper + '(?=' + [rsBreak, rsUpper + rsMiscLower, '$'].join('|') + ')',\n rsUpper + '?' + rsMiscLower + '+' + rsOptContrLower,\n rsUpper + '+' + rsOptContrUpper,\n rsOrdUpper,\n rsOrdLower,\n rsDigits,\n rsEmoji\n].join('|'), 'g');\n\n/**\n * Splits a Unicode `string` into an array of its words.\n *\n * @private\n * @param {string} The string to inspect.\n * @returns {Array} Returns the words of `string`.\n */\nfunction unicodeWords(string) {\n return string.match(reUnicodeWord) || [];\n}\n\nmodule.exports = unicodeWords;\n","var toString = require('./toString'),\n upperFirst = require('./upperFirst');\n\n/**\n * Converts the first character of `string` to upper case and the remaining\n * to lower case.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to capitalize.\n * @returns {string} Returns the capitalized string.\n * @example\n *\n * _.capitalize('FRED');\n * // => 'Fred'\n */\nfunction capitalize(string) {\n return upperFirst(toString(string).toLowerCase());\n}\n\nmodule.exports = capitalize;\n","var createCaseFirst = require('./_createCaseFirst');\n\n/**\n * Converts the first character of `string` to upper case.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category String\n * @param {string} [string=''] The string to convert.\n * @returns {string} Returns the converted string.\n * @example\n *\n * _.upperFirst('fred');\n * // => 'Fred'\n *\n * _.upperFirst('FRED');\n * // => 'FRED'\n */\nvar upperFirst = createCaseFirst('toUpperCase');\n\nmodule.exports = upperFirst;\n","var castSlice = require('./_castSlice'),\n hasUnicode = require('./_hasUnicode'),\n stringToArray = require('./_stringToArray'),\n toString = require('./toString');\n\n/**\n * Creates a function like `_.lowerFirst`.\n *\n * @private\n * @param {string} methodName The name of the `String` case method to use.\n * @returns {Function} Returns the new case function.\n */\nfunction createCaseFirst(methodName) {\n return function(string) {\n string = toString(string);\n\n var strSymbols = hasUnicode(string)\n ? stringToArray(string)\n : undefined;\n\n var chr = strSymbols\n ? strSymbols[0]\n : string.charAt(0);\n\n var trailing = strSymbols\n ? castSlice(strSymbols, 1).join('')\n : string.slice(1);\n\n return chr[methodName]() + trailing;\n };\n}\n\nmodule.exports = createCaseFirst;\n","var baseSlice = require('./_baseSlice');\n\n/**\n * Casts `array` to a slice if it's needed.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {number} start The start position.\n * @param {number} [end=array.length] The end position.\n * @returns {Array} Returns the cast slice.\n */\nfunction castSlice(array, start, end) {\n var length = array.length;\n end = end === undefined ? length : end;\n return (!start && end >= length) ? array : baseSlice(array, start, end);\n}\n\nmodule.exports = castSlice;\n","/**\n * The base implementation of `_.slice` without an iteratee call guard.\n *\n * @private\n * @param {Array} array The array to slice.\n * @param {number} [start=0] The start position.\n * @param {number} [end=array.length] The end position.\n * @returns {Array} Returns the slice of `array`.\n */\nfunction baseSlice(array, start, end) {\n var index = -1,\n length = array.length;\n\n if (start < 0) {\n start = -start > length ? 0 : (length + start);\n }\n end = end > length ? length : end;\n if (end < 0) {\n end += length;\n }\n length = start > end ? 0 : ((end - start) >>> 0);\n start >>>= 0;\n\n var result = Array(length);\n while (++index < length) {\n result[index] = array[index + start];\n }\n return result;\n}\n\nmodule.exports = baseSlice;\n","var asciiToArray = require('./_asciiToArray'),\n hasUnicode = require('./_hasUnicode'),\n unicodeToArray = require('./_unicodeToArray');\n\n/**\n * Converts `string` to an array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the converted array.\n */\nfunction stringToArray(string) {\n return hasUnicode(string)\n ? unicodeToArray(string)\n : asciiToArray(string);\n}\n\nmodule.exports = stringToArray;\n","/**\n * Converts an ASCII `string` to an array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the converted array.\n */\nfunction asciiToArray(string) {\n return string.split('');\n}\n\nmodule.exports = asciiToArray;\n","/** Used to compose unicode character classes. */\nvar rsAstralRange = '\\\\ud800-\\\\udfff',\n rsComboMarksRange = '\\\\u0300-\\\\u036f',\n reComboHalfMarksRange = '\\\\ufe20-\\\\ufe2f',\n rsComboSymbolsRange = '\\\\u20d0-\\\\u20ff',\n rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange,\n rsVarRange = '\\\\ufe0e\\\\ufe0f';\n\n/** Used to compose unicode capture groups. */\nvar rsAstral = '[' + rsAstralRange + ']',\n rsCombo = '[' + rsComboRange + ']',\n rsFitz = '\\\\ud83c[\\\\udffb-\\\\udfff]',\n rsModifier = '(?:' + rsCombo + '|' + rsFitz + ')',\n rsNonAstral = '[^' + rsAstralRange + ']',\n rsRegional = '(?:\\\\ud83c[\\\\udde6-\\\\uddff]){2}',\n rsSurrPair = '[\\\\ud800-\\\\udbff][\\\\udc00-\\\\udfff]',\n rsZWJ = '\\\\u200d';\n\n/** Used to compose unicode regexes. */\nvar reOptMod = rsModifier + '?',\n rsOptVar = '[' + rsVarRange + ']?',\n rsOptJoin = '(?:' + rsZWJ + '(?:' + [rsNonAstral, rsRegional, rsSurrPair].join('|') + ')' + rsOptVar + reOptMod + ')*',\n rsSeq = rsOptVar + reOptMod + rsOptJoin,\n rsSymbol = '(?:' + [rsNonAstral + rsCombo + '?', rsCombo, rsRegional, rsSurrPair, rsAstral].join('|') + ')';\n\n/** Used to match [string symbols](https://mathiasbynens.be/notes/javascript-unicode). */\nvar reUnicode = RegExp(rsFitz + '(?=' + rsFitz + ')|' + rsSymbol + rsSeq, 'g');\n\n/**\n * Converts a Unicode `string` to an array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the converted array.\n */\nfunction unicodeToArray(string) {\n return string.match(reUnicode) || [];\n}\n\nmodule.exports = unicodeToArray;\n","/** @license React v17.0.2\n * react-jsx-runtime.production.min.js\n *\n * Copyright (c) Facebook, Inc. and its affiliates.\n *\n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n */\n'use strict';require(\"object-assign\");var f=require(\"react\"),g=60103;exports.Fragment=60107;if(\"function\"===typeof Symbol&&Symbol.for){var h=Symbol.for;g=h(\"react.element\");exports.Fragment=h(\"react.fragment\")}var m=f.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,n=Object.prototype.hasOwnProperty,p={key:!0,ref:!0,__self:!0,__source:!0};\nfunction q(c,a,k){var b,d={},e=null,l=null;void 0!==k&&(e=\"\"+k);void 0!==a.key&&(e=\"\"+a.key);void 0!==a.ref&&(l=a.ref);for(b in a)n.call(a,b)&&!p.hasOwnProperty(b)&&(d[b]=a[b]);if(c&&c.defaultProps)for(b in a=c.defaultProps,a)void 0===d[b]&&(d[b]=a[b]);return{$$typeof:g,type:c,key:e,ref:l,props:d,_owner:m.current}}exports.jsx=q;exports.jsxs=q;\n","import withClassName from '../withClassName';\nimport { IconProps } from '../types';\n\nconst SaveOutlined = (props: IconProps): JSX.Element => {\n\treturn (\n\t\t\n\t\t\t\n\t\t\n\t);\n};\n\nexport default withClassName(SaveOutlined, 'save-outlined');\n","import objectWithoutPropertiesLoose from \"@babel/runtime/helpers/esm/objectWithoutPropertiesLoose\";\nexport default function _objectWithoutProperties(source, excluded) {\n if (source == null) return {};\n var target = objectWithoutPropertiesLoose(source, excluded);\n var key, i;\n\n if (Object.getOwnPropertySymbols) {\n var sourceSymbolKeys = Object.getOwnPropertySymbols(source);\n\n for (i = 0; i < sourceSymbolKeys.length; i++) {\n key = sourceSymbolKeys[i];\n if (excluded.indexOf(key) >= 0) continue;\n if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;\n target[key] = source[key];\n }\n }\n\n return target;\n}","export default function _objectWithoutPropertiesLoose(source, excluded) {\n if (source == null) return {};\n var target = {};\n var sourceKeys = Object.keys(source);\n var key, i;\n\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\n return target;\n}","import unsupportedIterableToArray from \"@babel/runtime/helpers/esm/unsupportedIterableToArray\";\nexport default function _createForOfIteratorHelper(o, allowArrayLike) {\n var it;\n\n if (typeof Symbol === \"undefined\" || o[Symbol.iterator] == null) {\n if (Array.isArray(o) || (it = unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === \"number\") {\n if (it) o = it;\n var i = 0;\n\n var F = function F() {};\n\n return {\n s: F,\n n: function n() {\n if (i >= o.length) return {\n done: true\n };\n return {\n done: false,\n value: o[i++]\n };\n },\n e: function e(_e) {\n throw _e;\n },\n f: F\n };\n }\n\n throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\");\n }\n\n var normalCompletion = true,\n didErr = false,\n err;\n return {\n s: function s() {\n it = o[Symbol.iterator]();\n },\n n: function n() {\n var step = it.next();\n normalCompletion = step.done;\n return step;\n },\n e: function e(_e2) {\n didErr = true;\n err = _e2;\n },\n f: function f() {\n try {\n if (!normalCompletion && it[\"return\"] != null) it[\"return\"]();\n } finally {\n if (didErr) throw err;\n }\n }\n };\n}","(function() { module.exports = window[\"eventespresso\"][\"form\"]; }());","import { useMemo } from 'react';\n\nimport { EntityActionsSubscription, EntityActionsMenuRegistry } from '@eventespresso/registry';\nimport { domain } from '@eventespresso/edtr-services';\nimport { useMemoStringify } from '@eventespresso/hooks';\nimport type { Entity } from '@eventespresso/data';\n\nconst { getSubscriptions } = new EntityActionsSubscription(domain);\n\nconst useEntityActionsMenuItems = (\n\tentityType: T,\n\tentity: E,\n\tfilterByEntityType = true\n): Array => {\n\tconst registry = useMemo(\n\t\t() => new EntityActionsMenuRegistry({ domain, entityType, entityId: entity.id }),\n\t\t[entity.id, entityType]\n\t);\n\n\tconst { generateElements } = registry;\n\n\tconst subscriptions = getSubscriptions({ entityType: filterByEntityType ? entityType : null });\n\n\tObject.values(subscriptions).forEach(({ callback }) => {\n\t\tcallback({ entityType, entity, registry });\n\t});\n\n\t// it should only change if subscriptions change\n\t// eslint-disable-next-line react-hooks/exhaustive-deps\n\treturn useMemoStringify(generateElements(), Object.keys(subscriptions));\n};\n\nexport default useEntityActionsMenuItems;\n","(function() { module.exports = window[\"eventespresso\"][\"tpc\"]; }());","export default function _assertThisInitialized(self) {\n if (self === void 0) {\n throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\");\n }\n\n return self;\n}","import { useCallback, useMemo, useState } from 'react';\nimport * as R from 'ramda';\n\nimport { useRelationsManager, RelationFunctionProps } from '@eventespresso/services';\n\nimport { AssignmentManager } from '../types';\nimport { TAM_ENTITIES } from '../constants';\n\ntype AM = AssignmentManager;\n\n/**\n * A wrapper for relations manager.\n */\nconst useAssignmentManager = (): AM => {\n\t// Create a fresh instance to manage current relations/assignments\n\t// without modifying/mutating the existing relations\n\tconst {\n\t\taddRelation,\n\t\tgetData,\n\t\tgetRelations,\n\t\tinitialize: initializeRelations,\n\t\tisInitialized,\n\t\tremoveRelation,\n\t} = useRelationsManager();\n\n\tconst [isDirty, setIsDirty] = useState(false);\n\n\tconst getAssignedTickets = useCallback(\n\t\t({ datetimeId }) => {\n\t\t\treturn getRelations({\n\t\t\t\tentity: 'datetimes',\n\t\t\t\tentityId: datetimeId,\n\t\t\t\trelation: 'tickets',\n\t\t\t});\n\t\t},\n\t\t[getRelations]\n\t);\n\n\tconst getAssignedDates = useCallback(\n\t\t({ ticketId }) => {\n\t\t\treturn getRelations({\n\t\t\t\tentity: 'tickets',\n\t\t\t\tentityId: ticketId,\n\t\t\t\trelation: 'datetimes',\n\t\t\t});\n\t\t},\n\t\t[getRelations]\n\t);\n\n\t// args are same\n\tconst updateAssignment = useCallback(\n\t\t({ datetimeId, ticketId, remove = false }) => {\n\t\t\t// relation from datetimes towards tickets\n\t\t\tconst datetimeToTickets: RelationFunctionProps<'datetimes'> = {\n\t\t\t\tentity: 'datetimes',\n\t\t\t\tentityId: datetimeId,\n\t\t\t\trelation: 'tickets',\n\t\t\t\trelationId: ticketId,\n\t\t\t};\n\t\t\t// relation from tickets towards datetimes\n\t\t\tconst ticketsToDatetimes: RelationFunctionProps<'tickets'> = {\n\t\t\t\tentity: 'tickets',\n\t\t\t\tentityId: ticketId,\n\t\t\t\trelation: 'datetimes',\n\t\t\t\trelationId: datetimeId,\n\t\t\t};\n\n\t\t\tif (remove) {\n\t\t\t\tremoveRelation(datetimeToTickets);\n\t\t\t\tremoveRelation(ticketsToDatetimes);\n\t\t\t} else {\n\t\t\t\t// Add both ways relation for fast retieval\n\t\t\t\taddRelation(datetimeToTickets);\n\t\t\t\taddRelation(ticketsToDatetimes);\n\t\t\t}\n\n\t\t\tsetIsDirty(true);\n\t\t},\n\t\t[addRelation, removeRelation]\n\t);\n\n\tconst addAssignment = useCallback(\n\t\t({ datetimeId, ticketId }) => {\n\t\t\tupdateAssignment({ datetimeId, ticketId });\n\t\t},\n\t\t[updateAssignment]\n\t);\n\n\t// args are same\n\tconst toggleAssignment = useCallback(\n\t\t({ datetimeId, ticketId }) => {\n\t\t\tconst assignedTickets = getAssignedTickets({ datetimeId });\n\t\t\tconst remove = assignedTickets.includes(ticketId);\n\t\t\tupdateAssignment({ datetimeId, ticketId, remove });\n\t\t},\n\t\t[getAssignedTickets, updateAssignment]\n\t);\n\n\tconst removeAssignment = useCallback(\n\t\t({ datetimeId, ticketId }) => {\n\t\t\tupdateAssignment({ datetimeId, ticketId, remove: true });\n\t\t},\n\t\t[updateAssignment]\n\t);\n\n\t/**\n\t * Removes other relations from the given relational entity\n\t * like ticket to price relations\n\t */\n\tconst removeNonTAMRelations = useCallback(({ assignmentType, entity, entityType, relationalEntity }) => {\n\t\t// by default all entities (dates/tickets) will be used for relations\n\t\t// e.g. TAM for all dates and tickets\n\t\tlet relationalEntityToUse = relationalEntity;\n\n\t\t// But if TAM is only for a single datetime/ticket\n\t\t// limit relations to that datetime/ticket\n\t\tif (\n\t\t\t(assignmentType === 'forDate' && entityType === 'datetimes') ||\n\t\t\t(assignmentType === 'forTicket' && entityType === 'tickets')\n\t\t) {\n\t\t\t// only the realtions for the given single entity\n\t\t\t// for which TAM has been opened\n\t\t\trelationalEntityToUse = R.pick([entity.id], relationalEntity);\n\t\t\t// if it's for a new date or ticket,\n\t\t\t// there will obviously be no entry of it in existing relations\n\t\t\tif (R.isEmpty(relationalEntityToUse)) {\n\t\t\t\tconst newRelationKey = entityType === 'datetimes' ? 'tickets' : 'datetimes';\n\t\t\t\t// initialize to empty relations\n\t\t\t\trelationalEntityToUse[entity.id] = {\n\t\t\t\t\t[newRelationKey]: [],\n\t\t\t\t};\n\t\t\t}\n\t\t}\n\n\t\t// Now loop through all the relational entities\n\t\treturn R.map((relation) => {\n\t\t\t// pick only TAM relations, i.e. filter out tickets to prices relations\n\t\t\treturn R.pick(TAM_ENTITIES, relation);\n\t\t}, relationalEntityToUse);\n\t}, []);\n\n\t/**\n\t * Inilializes the relations for TAM.\n\t */\n\tconst initialize = useCallback(\n\t\t({ data, assignmentType, entity }) => {\n\t\t\t// pick only datetimes and tickets from relational data\n\t\t\tlet newData = R.pick(TAM_ENTITIES, data);\n\n\t\t\t// Remove other relations from newData\n\t\t\tnewData = R.mapObjIndexed((relationalEntity, entityType) => {\n\t\t\t\treturn removeNonTAMRelations({ assignmentType, entity, entityType, relationalEntity });\n\t\t\t}, newData);\n\n\t\t\t// fire up the relations manager\n\t\t\tinitializeRelations(newData);\n\t\t},\n\t\t[initializeRelations, removeNonTAMRelations]\n\t);\n\n\treturn useMemo(\n\t\t() => ({\n\t\t\taddAssignment,\n\t\t\tgetAssignedDates,\n\t\t\tgetAssignedTickets,\n\t\t\tgetData,\n\t\t\tinitialize,\n\t\t\tisDirty,\n\t\t\tisInitialized,\n\t\t\tremoveAssignment,\n\t\t\ttoggleAssignment,\n\t\t}),\n\t\t[\n\t\t\taddAssignment,\n\t\t\tgetAssignedDates,\n\t\t\tgetAssignedTickets,\n\t\t\tgetData,\n\t\t\tinitialize,\n\t\t\tisDirty,\n\t\t\tisInitialized,\n\t\t\tremoveAssignment,\n\t\t\ttoggleAssignment,\n\t\t]\n\t);\n};\n\nexport default useAssignmentManager;\n","import { useContext } from 'react';\nimport invariant from 'invariant';\n\nimport { DataStateManager } from '../types';\nimport { DataStateContext } from '../context';\n\nconst useDataState = (): DataStateManager => {\n\tconst value = useContext(DataStateContext);\n\n\tinvariant(value, 'useDataState must be used inside TAM component');\n\n\treturn value;\n};\n\nexport default useDataState;\n","import { useEffect, useCallback, useMemo, useState } from 'react';\nimport * as R from 'ramda';\n\nimport { EntityId } from '@eventespresso/data';\nimport { useRelations } from '@eventespresso/services';\nimport { useDefaultTicketIds } from '@eventespresso/edtr-services';\n\nimport { useAssignmentManager, useValidation } from './';\nimport { AssignmentStatus, BaseProps, DataStateManager } from '../types';\n\nconst useDataStateManager = (props: BaseProps): DataStateManager => {\n\tconst [initialDataIsValid, setInitialDataIsValid] = useState(false);\n\tconst assignmentManager = useAssignmentManager();\n\t// The existing relations to be used to create initial data\n\t// and to calculate difference between new and old data\n\tconst relations = useRelations();\n\tconst orphanEntities = useValidation(assignmentManager);\n\tconst defaultTicketIds = useDefaultTicketIds();\n\n\tconst { initialize, isInitialized } = assignmentManager;\n\tconst initialized = isInitialized();\n\n\tconst hasNoAssignedDates = useCallback(\n\t\t({ ticketId }) => orphanEntities.tickets.includes(ticketId),\n\t\t[orphanEntities.tickets]\n\t);\n\n\tconst hasNoAssignedTickets = useCallback(\n\t\t({ datetimeId }) => orphanEntities.datetimes.includes(datetimeId),\n\t\t[orphanEntities.datetimes]\n\t);\n\n\tconst hasOrphanEntitiesOfType = useCallback(\n\t\t(entityType: keyof typeof orphanEntities) => {\n\t\t\tif (\n\t\t\t\t// if TAM is for a date, lets not worry about tickets and vice versa\n\t\t\t\t(entityType === 'tickets' && props.assignmentType === 'forDate') ||\n\t\t\t\t(entityType === 'datetimes' && props.assignmentType === 'forTicket')\n\t\t\t) {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t\t// if TAM is for a particular date/ticket, we should worry only about that particular date/ticket\n\t\t\tif (props.assignmentType !== 'forAll') {\n\t\t\t\treturn orphanEntities[entityType]?.includes(props.entity?.id);\n\t\t\t}\n\t\t\treturn orphanEntities[entityType]?.length > 0;\n\t\t},\n\t\t[orphanEntities, props.assignmentType, props.entity?.id]\n\t);\n\n\tconst hasOrphanTickets = useCallback(() => hasOrphanEntitiesOfType('tickets'), [hasOrphanEntitiesOfType]);\n\n\tconst hasOrphanDates = useCallback(() => hasOrphanEntitiesOfType('datetimes'), [hasOrphanEntitiesOfType]);\n\n\tconst hasOrphanEntities = useCallback(\n\t\t() => hasOrphanTickets() || hasOrphanDates(),\n\t\t[hasOrphanDates, hasOrphanTickets]\n\t);\n\n\tconst getOldRelation = useCallback(\n\t\t({ datetimeId }): EntityId[] => {\n\t\t\treturn relations.getRelations({\n\t\t\t\tentity: 'datetimes',\n\t\t\t\tentityId: datetimeId,\n\t\t\t\trelation: 'tickets',\n\t\t\t});\n\t\t},\n\t\t[relations]\n\t);\n\n\tconst getAssignmentStatus = useCallback(\n\t\t({ datetimeId, ticketId }): AssignmentStatus => {\n\t\t\tconst oldRelatedTickets = getOldRelation({ datetimeId });\n\t\t\tconst newRelatedTickets = assignmentManager.getAssignedTickets({ datetimeId });\n\n\t\t\tconst isInOld = oldRelatedTickets.includes(ticketId);\n\t\t\tconst isInNew = newRelatedTickets.includes(ticketId);\n\n\t\t\tswitch (true) {\n\t\t\t\tcase isInOld && isInNew:\n\t\t\t\t\treturn 'OLD';\n\t\t\t\tcase !isInOld && isInNew:\n\t\t\t\t\treturn 'NEW';\n\t\t\t\tcase isInOld && !isInNew:\n\t\t\t\t\treturn 'REMOVED';\n\t\t\t\tcase !isInOld && !isInNew:\n\t\t\t\t\treturn null;\n\t\t\t}\n\t\t},\n\t\t[assignmentManager, getOldRelation]\n\t);\n\n\tuseEffect(() => {\n\t\tif (!initialized) {\n\t\t\tconst data = relations.getData();\n\t\t\t// remove default tickets from TAM relations\n\t\t\tconst newData = { ...data, tickets: R.omit(defaultTicketIds, data.tickets || {}) };\n\t\t\t// initialize with existing data\n\t\t\tinitialize({ data: newData, ...props });\n\t\t\t// now check if there are any orphaned entities in the initial data and save the result\n\t\t\tconst hasOrphans = orphanEntities?.datetimes?.length !== 0 || orphanEntities?.tickets?.length !== 0;\n\t\t\tsetInitialDataIsValid(!hasOrphans);\n\t\t}\n\t}, [defaultTicketIds, initialize, initialized, orphanEntities, props, relations, setInitialDataIsValid]);\n\n\treturn useMemo(\n\t\t() => ({\n\t\t\t...assignmentManager,\n\t\t\tgetAssignmentStatus,\n\t\t\thasNoAssignedDates,\n\t\t\thasNoAssignedTickets,\n\t\t\thasOrphanDates,\n\t\t\thasOrphanEntities,\n\t\t\thasOrphanTickets,\n\t\t\tinitialDataIsValid,\n\t\t}),\n\t\t[\n\t\t\tassignmentManager,\n\t\t\tgetAssignmentStatus,\n\t\t\thasNoAssignedDates,\n\t\t\thasNoAssignedTickets,\n\t\t\thasOrphanDates,\n\t\t\thasOrphanEntities,\n\t\t\thasOrphanTickets,\n\t\t\tinitialDataIsValid,\n\t\t]\n\t);\n};\n\nexport default useDataStateManager;\n","import { useMemo } from 'react';\n\nimport type { Datetime } from '@eventespresso/edtr-services';\nimport { notTrashed, inYearAndMonth } from '@eventespresso/predicates';\nimport { useFilterState } from '../filters';\n\nconst useFilteredDatetimes = (allDates: Array): Array => {\n\tconst { showTrashedDates, datesByMonth } = useFilterState();\n\n\tconst datesInYearAndMonth = inYearAndMonth(datesByMonth);\n\n\t// If the year i.e. datesByMonth[0] is set, then filter\n\tconst datetimes = useMemo(\n\t\t() => (datesByMonth[0] ? datesInYearAndMonth(allDates) : allDates),\n\t\t[allDates, datesByMonth, datesInYearAndMonth]\n\t);\n\n\treturn useMemo(() => {\n\t\treturn showTrashedDates ? datetimes : notTrashed(datetimes);\n\t}, [datetimes, showTrashedDates]);\n};\n\nexport default useFilteredDatetimes;\n","import { useMemo } from 'react';\n\nimport { isExpired, notTrashed } from '@eventespresso/predicates';\nimport type { Ticket } from '@eventespresso/edtr-services';\nimport { useFilterState } from '../filters';\n\nconst useFilteredTickets = (allTickets: Array): Array => {\n\tconst { showExpiredTickets, showTrashedTickets } = useFilterState();\n\n\treturn useMemo(() => {\n\t\tlet tickets = allTickets;\n\t\tif (!showExpiredTickets) {\n\t\t\ttickets = tickets.filter((ticket) => !isExpired(ticket));\n\t\t}\n\n\t\tif (!showTrashedTickets) {\n\t\t\ttickets = notTrashed(tickets);\n\t\t}\n\n\t\treturn tickets;\n\t}, [allTickets, showExpiredTickets, showTrashedTickets]);\n};\n\nexport default useFilteredTickets;\n","import { Datetime, Ticket, useDatetimes, useTickets } from '@eventespresso/edtr-services';\nimport { useMemoStringify } from '@eventespresso/hooks';\n\nimport { DatesAndTickets } from '../types';\nimport { useTAMContext } from '../context';\nimport useFilteredDatetimes from './useFilteredDatetimes';\nimport useFilteredTickets from './useFilteredTickets';\n\nconst useDatesAndTickets = (): DatesAndTickets => {\n\tconst { assignmentType, entity } = useTAMContext();\n\tconst allDates = useDatetimes();\n\tconst allTickets = useTickets();\n\n\tconst filteredDatetimes = useFilteredDatetimes(allDates);\n\tconst filteredTickets = useFilteredTickets(allTickets);\n\n\tlet datetimes: Array, tickets: Array;\n\n\tswitch (assignmentType) {\n\t\tcase 'forAll':\n\t\t\tdatetimes = filteredDatetimes;\n\t\t\ttickets = filteredTickets;\n\t\t\tbreak;\n\t\tcase 'forDate':\n\t\t\tdatetimes = [entity as Datetime];\n\t\t\ttickets = filteredTickets;\n\t\t\tbreak;\n\t\tcase 'forTicket':\n\t\t\tdatetimes = filteredDatetimes;\n\t\t\ttickets = [entity as Ticket];\n\t\t\tbreak;\n\t}\n\n\treturn useMemoStringify({ datetimes, tickets });\n};\n\nexport default useDatesAndTickets;\n","import { useCallback } from 'react';\nimport * as R from 'ramda';\n\nimport { useRelations } from '@eventespresso/services';\nimport { UpdateTicketInput, useDatetimes, useTickets, useBulkEditTickets } from '@eventespresso/edtr-services';\nimport { entityHasGuid } from '@eventespresso/predicates';\nimport { prepareEntitiesForUpdate, ticketsWithNewQuantity } from '../utils';\nimport { TAMRelationalData } from '../types';\n\ntype Callback = (data: TAMRelationalData) => Promise;\n\nconst useOnSubmitAssignments = (): Callback => {\n\tconst { getData: getExistingData } = useRelations();\n\n\tconst allDates = useDatetimes();\n\tconst allTickets = useTickets();\n\n\tconst { updateEntities: bulkEditTickets } = useBulkEditTickets();\n\n\treturn useCallback(\n\t\tasync (data) => {\n\t\t\tconst existingData = getExistingData();\n\n\t\t\tconst ticketsToUpdate = prepareEntitiesForUpdate({\n\t\t\t\tentity: 'tickets',\n\t\t\t\texistingData,\n\t\t\t\tnewData: data,\n\t\t\t\trelation: 'datetimes',\n\t\t\t});\n\n\t\t\tconst ticketsWithChangedQuantity = ticketsWithNewQuantity({\n\t\t\t\tallDates,\n\t\t\t\tallTickets,\n\t\t\t\texistingData,\n\t\t\t\tticketsToUpdate,\n\t\t\t});\n\n\t\t\tconst uniqueInputs = ticketsToUpdate.map(([id, possibleRelation]) => {\n\t\t\t\tconst input = { id, datetimes: possibleRelation?.datetimes };\n\n\t\t\t\tconst quantity = ticketsWithChangedQuantity?.[id];\n\t\t\t\tif (quantity) {\n\t\t\t\t\treturn { ...input, quantity };\n\t\t\t\t}\n\t\t\t\treturn input;\n\t\t\t});\n\t\t\tObject.entries(ticketsWithChangedQuantity).forEach(([id, quantity]) => {\n\t\t\t\t// if it's already in uniqueInputs\n\t\t\t\tif (R.any(entityHasGuid(id), uniqueInputs)) {\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t\tuniqueInputs.push({ id, quantity });\n\t\t\t});\n\t\t\tif (uniqueInputs?.length) {\n\t\t\t\tawait bulkEditTickets({ uniqueInputs });\n\t\t\t}\n\t\t},\n\t\t[allDates, allTickets, bulkEditTickets, getExistingData]\n\t);\n};\n\nexport default useOnSubmitAssignments;\n","import { useState, useEffect } from 'react';\nimport * as R from 'ramda';\n\nimport { AssignmentManager, TAMPossibleRelation, TAMRelationalData, TAMRelationalEntity } from '../types';\n\nconst DEFAULT_VALIDATION_DATA: TAMPossibleRelation = {\n\tdatetimes: [],\n\ttickets: [],\n};\n\nconst useValidation = (assignmentManager: AssignmentManager): TAMPossibleRelation => {\n\tconst [validationData, setValidationData] = useState(DEFAULT_VALIDATION_DATA);\n\tconst TAMData: TAMRelationalData = assignmentManager.getData();\n\n\tuseEffect(() => {\n\t\t// may be the data is not initialized yet\n\t\tif (R.isEmpty(TAMData)) {\n\t\t\treturn;\n\t\t}\n\t\t// loop through TAM data to find entities with no relations\n\t\t// See the data shape, please check the shape of TAMRelationalData\n\t\tconst newTAMData: TAMPossibleRelation = R.mapObjIndexed((relationalEntity, entity) => {\n\t\t\tconst relation: keyof TAMPossibleRelation = entity === 'datetimes' ? 'tickets' : 'datetimes';\n\t\t\tconst emptyRelationalEntities = R.pickBy(\n\t\t\t\t(relations: TAMPossibleRelation) => {\n\t\t\t\t\tconst relatedIds = relations?.[relation] || [];\n\t\t\t\t\treturn relatedIds.length === 0;\n\t\t\t\t},\n\t\t\t\trelationalEntity\n\t\t\t);\n\t\t\treturn Object.keys(emptyRelationalEntities);\n\t\t}, TAMData);\n\t\tsetValidationData(newTAMData);\n\t}, [TAMData]);\n\n\treturn validationData;\n};\n\nexport default useValidation;\n","import arrayWithHoles from \"@babel/runtime/helpers/esm/arrayWithHoles\";\nimport iterableToArrayLimit from \"@babel/runtime/helpers/esm/iterableToArrayLimit\";\nimport unsupportedIterableToArray from \"@babel/runtime/helpers/esm/unsupportedIterableToArray\";\nimport nonIterableRest from \"@babel/runtime/helpers/esm/nonIterableRest\";\nexport default function _slicedToArray(arr, i) {\n return arrayWithHoles(arr) || iterableToArrayLimit(arr, i) || unsupportedIterableToArray(arr, i) || nonIterableRest();\n}","export default function _iterableToArrayLimit(arr, i) {\n if (typeof Symbol === \"undefined\" || !(Symbol.iterator in Object(arr))) return;\n var _arr = [];\n var _n = true;\n var _d = false;\n var _e = undefined;\n\n try {\n for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) {\n _arr.push(_s.value);\n\n if (i && _arr.length === i) break;\n }\n } catch (err) {\n _d = true;\n _e = err;\n } finally {\n try {\n if (!_n && _i[\"return\"] != null) _i[\"return\"]();\n } finally {\n if (_d) throw _e;\n }\n }\n\n return _arr;\n}","export default function _setPrototypeOf(o, p) {\n _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) {\n o.__proto__ = p;\n return o;\n };\n\n return _setPrototypeOf(o, p);\n}"],"sourceRoot":""} \ No newline at end of file diff --git a/caffeinated/admin/extend/events/Extend_Events_Admin_Page.core.php b/caffeinated/admin/extend/events/Extend_Events_Admin_Page.core.php index 7bcc23947e3..bd5622d5b96 100644 --- a/caffeinated/admin/extend/events/Extend_Events_Admin_Page.core.php +++ b/caffeinated/admin/extend/events/Extend_Events_Admin_Page.core.php @@ -206,7 +206,8 @@ protected function _set_page_config() add_filter('FHEE__Events_Admin_Page___event_legend_items__items', [$this, 'additional_legend_items']); add_action('admin_init', [$this, 'admin_init']); // this is a filter that allows the addition of extra html after the permalink field on the wp post edit-form - add_filter('get_sample_permalink_html', [DuplicateEventButton::class, 'addButton'], 8, 4); + // add_filter('get_sample_permalink_html', [DuplicateEventButton::class, 'addButton'], 8, 2); + DuplicateEventButton::addEventEditorPermalinkButton(8); } diff --git a/caffeinated/admin/extend/registrations/EE_Event_Registrations_List_Table.class.php b/caffeinated/admin/extend/registrations/EE_Event_Registrations_List_Table.class.php index e928e947947..371498d542e 100644 --- a/caffeinated/admin/extend/registrations/EE_Event_Registrations_List_Table.class.php +++ b/caffeinated/admin/extend/registrations/EE_Event_Registrations_List_Table.class.php @@ -6,6 +6,7 @@ use EventEspresso\core\exceptions\InvalidDataTypeException; use EventEspresso\core\exceptions\InvalidInterfaceException; use EventEspresso\core\services\loaders\LoaderFactory; +use EventEspresso\core\services\request\DataType; use EventEspresso\core\services\request\RequestInterface; use EventEspresso\ui\browser\checkins\entities\CheckinStatusDashicon; @@ -58,8 +59,9 @@ class EE_Event_Registrations_List_Table extends EE_Admin_List_Table */ public function __construct($admin_page) { - parent::__construct($admin_page); + $this->request = LoaderFactory::getLoader()->getShared(RequestInterface::class); $this->resolveRequestVars(); + parent::__construct($admin_page); } @@ -70,7 +72,7 @@ public function __construct($admin_page) */ private function resolveRequestVars() { - $this->event_id = $this->request->getRequestParam('event_id', 0, 'int'); + $this->event_id = $this->request->getRequestParam('event_id', 0, DataType::INTEGER); $this->datetimes_for_event = DatetimesForEventCheckIn::fromEventID($this->event_id); // if we're filtering for a specific event and it only has one datetime, then grab its ID $this->datetime = $this->datetimes_for_event->getOneDatetimeForEvent(); @@ -79,7 +81,7 @@ private function resolveRequestVars() $this->datetime_id = $this->request->getRequestParam( 'DTT_ID', $this->datetime_id, - 'int' + DataType::INTEGER ); } @@ -106,8 +108,6 @@ protected function _setup_data() */ protected function _set_properties() { - $return_url = $this->getReturnUrl(); - $this->_wp_list_args = [ 'singular' => esc_html__('registrant', 'event_espresso'), 'plural' => esc_html__('registrants', 'event_espresso'), @@ -139,7 +139,7 @@ protected function _set_properties() $this->_primary_column = '_REG_att_checked_in'; $csv_report = RegistrationsCsvReportParams::getRequestParams( - $return_url, + $this->getReturnUrl(), $this->_req_data, $this->event_id, $this->datetime_id @@ -195,8 +195,8 @@ protected function _get_row_class($item): string protected function _get_table_filters() { $filters = []; - $this->hide_expired = $this->request->getRequestParam('hide_expired', false, 'bool'); - $this->hide_upcoming = $this->request->getRequestParam('hide_upcoming', false, 'bool'); + $this->hide_expired = $this->request->getRequestParam('hide_expired', false, DataType::BOOL); + $this->hide_upcoming = $this->request->getRequestParam('hide_upcoming', false, DataType::BOOL); $hide_expired_checked = $this->hide_expired ? 'checked' : ''; $hide_upcoming_checked = $this->hide_upcoming ? 'checked' : ''; // get datetimes for ALL active events (note possible capability restrictions) diff --git a/core/EE_Cart.core.php b/core/EE_Cart.core.php index 820284f96bb..db141f3bf2c 100644 --- a/core/EE_Cart.core.php +++ b/core/EE_Cart.core.php @@ -191,8 +191,10 @@ private function _create_grand_total() * * @access public * @return EE_Line_Item[] + * @throws EE_Error + * @throws ReflectionException */ - public function get_tickets() + public function get_tickets(): array { if ($this->_grand_total === null) { return array(); @@ -209,7 +211,7 @@ public function get_tickets() * @throws EE_Error * @throws ReflectionException */ - public function all_ticket_quantity_count() + public function all_ticket_quantity_count(): int { $tickets = $this->get_tickets(); if (empty($tickets)) { @@ -217,7 +219,7 @@ public function all_ticket_quantity_count() } $count = 0; foreach ($tickets as $ticket) { - $count += $ticket->get('LIN_quantity'); + $count += $ticket->quantity(); } return $count; } diff --git a/core/EE_Config.core.php b/core/EE_Config.core.php index d6a4a75d39c..6e674d04231 100644 --- a/core/EE_Config.core.php +++ b/core/EE_Config.core.php @@ -2757,14 +2757,23 @@ public function setUseAdvancedEditor($use_advanced_editor = true) */ class EE_Template_Config extends EE_Config_Base { - public ?EE_Ticket_Selector_Config $EED_Ticket_Selector; + /** + * @var EE_Ticket_Selector_Config|stdClass|null + */ + public $EED_Ticket_Selector; - public ?EE_Event_Single_Config $EED_Event_Single; + /** + * @var EE_Event_Single_Config|stdClass|null + */ + public $EED_Event_Single; - public ?EE_Events_Archive_Config $EED_Events_Archive; + /** + * @var EE_Events_Archive_Config|stdClass|null + */ + public $EED_Events_Archive; /** - * @var EE_People_Config|null $EED_People_Single + * @var EE_People_Config|stdClass|null * @since 5.0.12.p */ public $EED_People_Single; diff --git a/core/EE_Error.core.php b/core/EE_Error.core.php index 5ac63fdf763..6a77dd32642 100644 --- a/core/EE_Error.core.php +++ b/core/EE_Error.core.php @@ -738,7 +738,7 @@ public static function clearNotices(): bool } if (EE_Session::isLoadedAndActive()) { // clear notices for user currently engaged in a session - return EE_Session::instance()->reset_data(EE_Error::OPTIONS_KEY_NOTICES); + return EE_Session::instance()->reset_data([EE_Error::OPTIONS_KEY_NOTICES]); } // clear global notices and hope none belonged to some for some other site visitor return update_option(EE_Error::OPTIONS_KEY_NOTICES, []); diff --git a/core/EE_Session.core.php b/core/EE_Session.core.php index 8f8ac19d407..3da9ca2b7dd 100644 --- a/core/EE_Session.core.php +++ b/core/EE_Session.core.php @@ -39,91 +39,74 @@ class EE_Session implements SessionIdentifierInterface const SAVE_STATE_DIRTY = 'dirty'; - /** - * instance of the EE_Session object - * - * @var EE_Session - */ - private static $_instance; + private static ?EE_Session $_instance = null; - /** - * @var CacheStorageInterface $cache_storage - */ - protected $cache_storage; + protected ?Base64Encoder $encryption = null; - /** - * @var Base64Encoder - */ - protected $encryption; + protected ?CacheStorageInterface $cache_storage = null; + + protected ?RequestInterface $request = null; + + protected ?SessionStartHandler $session_start_handler = null; /** - * @var SessionStartHandler $session_start_handler + * how long an EE session lasts + * default session lifespan of 1 hour (for not so instant IPNs) + * + * @var SessionLifespan|null $session_lifespan */ - protected $session_start_handler; + private ?SessionLifespan $session_lifespan = null; /** * the session id * * @var string */ - private $_sid; + private string $_sid = ''; /** * session id salt * * @var string */ - private $_sid_salt; + private string $_sid_salt = ''; - /** - * session data - * - * @var array - */ - private $_session_data = []; - - /** - * how long an EE session lasts - * default session lifespan of 1 hour (for not so instant IPNs) - * - * @var SessionLifespan $session_lifespan - */ - private $session_lifespan; + private array $_session_data = []; /** * session expiration time as Unix timestamp in GMT * * @var int */ - private $_expiration; + private int $_expiration = 0; /** * whether session has expired at some point * * @var boolean */ - private $_expired = false; + private bool $_expired = false; /** * current time as Unix timestamp in GMT * - * @var int + * @var int|null */ - private $_time; + private ?int $_time = null; /** * whether to encrypt session data * * @var bool */ - private $_use_encryption; + private bool $_use_encryption = false; /** * well... according to the server... * - * @var null + * @var string */ - private $_user_agent; + private string $_user_agent = ''; /** @@ -131,7 +114,7 @@ class EE_Session implements SessionIdentifierInterface * * @var array */ - private $_default_session_vars = [ + private array $_default_session_vars = [ 'id' => null, 'user_id' => null, 'ip_address' => null, @@ -147,26 +130,21 @@ class EE_Session implements SessionIdentifierInterface * * @var int $_last_gc */ - private $_last_gc; - - /** - * @var RequestInterface $request - */ - protected $request; + private int $_last_gc = 0; /** * whether session is active or not * * @var int $status */ - private $status = EE_Session::STATUS_CLOSED; + private int $status = EE_Session::STATUS_CLOSED; /** * whether session data has changed therefore requiring a session save * * @var string $save_state */ - private $save_state = EE_Session::SAVE_STATE_CLEAN; + private string $save_state = EE_Session::SAVE_STATE_CLEAN; /** @@ -176,7 +154,7 @@ class EE_Session implements SessionIdentifierInterface * @param RequestInterface|null $request * @param SessionStartHandler|null $session_start_handler * @param Base64Encoder|null $encryption - * @return EE_Session + * @return EE_Session|null * @throws InvalidArgumentException * @throws InvalidDataTypeException * @throws InvalidInterfaceException @@ -187,7 +165,7 @@ public static function instance( RequestInterface $request = null, SessionStartHandler $session_start_handler = null, Base64Encoder $encryption = null - ) { + ): ?EE_Session { // check if class object is instantiated // session loading is turned ON by default, but prior to the init hook, can be turned back OFF via: // add_filter( 'FHEE_load_EE_Session', '__return_false' ); @@ -649,6 +627,16 @@ private function _espresso_session(): bool return true; } + private function sessionKey(string $prefix = ''): string + { + return $prefix . EE_Session::session_id_prefix . $this->_sid; + } + + private function hashCheckKey(): string + { + return EE_Session::hash_check_prefix . $this->_sid; + } + /** * _get_session_data @@ -666,18 +654,14 @@ private function _espresso_session(): bool */ protected function _retrieve_session_data(): array { - $ssn_key = EE_Session::session_id_prefix . $this->_sid; try { // we're using WP's Transient API to store session data using the PHP session ID as the option name - $session_data = $this->cache_storage->get($ssn_key, false); + $session_data = $this->cache_storage->get($this->sessionKey(), false); if (empty($session_data)) { return []; } if (apply_filters('FHEE__EE_Session___perform_session_id_hash_check', WP_DEBUG)) { - $hash_check = $this->cache_storage->get( - EE_Session::hash_check_prefix . $this->_sid, - false - ); + $hash_check = $this->cache_storage->get($this->hashCheckKey(), false); if ($hash_check && $hash_check !== md5($session_data)) { EE_Error::add_error( sprintf( @@ -685,7 +669,7 @@ protected function _retrieve_session_data(): array 'The stored data for session %1$s failed to pass a hash check and therefore appears to be invalid.', 'event_espresso' ), - EE_Session::session_id_prefix . $this->_sid + $this->sessionKey() ), __FILE__, __FUNCTION__, @@ -699,12 +683,10 @@ protected function _retrieve_session_data(): array $row = $wpdb->get_row( $wpdb->prepare( "SELECT option_value FROM $wpdb->options WHERE option_name = %s LIMIT 1", - '_transient_' . $ssn_key + $this->sessionKey('_transient_') ) ); - $session_data = is_object($row) - ? $row->option_value - : null; + $session_data = is_object($row) ? $row->option_value : null; if ($session_data) { $session_data = preg_replace_callback( '!s:(d+):"(.*?)";!', @@ -736,7 +718,7 @@ function ($match) { . '
' . $this->find_serialize_error($session_data) : ''; - $this->cache_storage->delete(EE_Session::session_id_prefix . $this->_sid); + $this->cache_storage->delete($this->sessionKey()); throw new InvalidSessionDataException($msg, 0, $e); } } @@ -750,7 +732,7 @@ function ($match) { $msg .= WP_DEBUG ? '

' . print_r($session_data, true) . '

' . $this->find_serialize_error($session_data) : ''; - $this->cache_storage->delete(EE_Session::session_id_prefix . $this->_sid); + $this->cache_storage->delete($this->sessionKey()); throw new InvalidSessionDataException($msg); } if (isset($session_data['transaction']) && absint($session_data['transaction']) !== 0) { @@ -834,9 +816,7 @@ protected function _set_init_access_and_expiration() */ public function update(bool $new_session = false): bool { - $this->_session_data = is_array($this->_session_data) && isset($this->_session_data['id']) - ? $this->_session_data - : []; + $this->_session_data = isset($this->_session_data['id']) ? $this->_session_data : []; if (empty($this->_session_data)) { $this->_set_defaults(); } @@ -925,18 +905,29 @@ private function _create_espresso_session() */ private function sessionHasStuffWorthSaving(): bool { - return $this->save_state === EE_Session::SAVE_STATE_DIRTY - // we may want to eventually remove the following - // on the assumption that the above check is enough - || $this->cart() instanceof EE_Cart - || ( - isset($this->_session_data['ee_notices']) - && ( - ! empty($this->_session_data['ee_notices']['attention']) - || ! empty($this->_session_data['ee_notices']['errors']) - || ! empty($this->_session_data['ee_notices']['success']) - ) - ); + if ($this->save_state === EE_Session::SAVE_STATE_DIRTY) { + return true; + } + $default_session_vars = array_keys($this->_default_session_vars); + foreach ($this->_session_data as $key => $sessionDatum) { + if (in_array($key, $default_session_vars, true)) { + continue; + } + if (! empty($sessionDatum)) { + return true; + } + if ( + $key === 'ee_notices' + && ( + ! empty($this->_session_data['ee_notices']['attention']) + || ! empty($this->_session_data['ee_notices']['errors']) + || ! empty($this->_session_data['ee_notices']['success']) + ) + ) { + return true; + } + } + return false; } @@ -981,14 +972,14 @@ private function _save_session_to_db(bool $clear_session = false): bool // maybe save hash check if (apply_filters('FHEE__EE_Session___perform_session_id_hash_check', WP_DEBUG)) { $this->cache_storage->add( - EE_Session::hash_check_prefix . $this->_sid, + $this->hashCheckKey(), md5($session_data), $this->session_lifespan->inSeconds() ); } // we're using the Transient API for storing session data, $saved = $this->cache_storage->add( - EE_Session::session_id_prefix . $this->_sid, + $this->sessionKey(), $session_data, $this->session_lifespan->inSeconds() ); @@ -1055,11 +1046,6 @@ public function _wp_user_id(): int */ public function clear_session(string $class = '', string $function = '') { -// echo ' -//

-// ' . __CLASS__ . '::' . __FUNCTION__ . '( ' . $class . '::' . $function . '() )
-// ' . __FILE__ . ' ' . __LINE__ . ' -//

'; do_action('AHEE_log', __FILE__, __FUNCTION__, 'session cleared by : ' . $class . '::' . $function . '()'); $this->reset_cart(); $this->reset_checkout(); @@ -1076,18 +1062,18 @@ public function clear_session(string $class = '', string $function = '') /** * resets all non-default session vars. Returns TRUE on success, FALSE on fail * - * @param array|mixed $data_to_reset + * @param array|mixed $keys_to_reset * @param bool $show_all_notices * @return bool */ - public function reset_data($data_to_reset = [], bool $show_all_notices = false): bool + public function reset_data($keys_to_reset = [], bool $show_all_notices = false): bool { - // if $data_to_reset is not in an array, then put it in one - if (! is_array($data_to_reset)) { - $data_to_reset = [$data_to_reset]; - } + $keys_to_reset = (array) apply_filters( + 'FHEE__EE_Session__reset_data__session_data_keys_to_reset', + (array) $keys_to_reset + ); // nothing ??? go home! - if (empty($data_to_reset)) { + if (empty($keys_to_reset)) { EE_Error::add_error( esc_html__( 'No session data could be reset, because no session var name was provided.', @@ -1100,45 +1086,10 @@ public function reset_data($data_to_reset = [], bool $show_all_notices = false): return false; } $return_value = true; - // since $data_to_reset is an array, cycle through the values - foreach ($data_to_reset as $reset) { + // since $keys_to_reset is an array, cycle through the values + foreach ($keys_to_reset as $key_to_reset) { // first check to make sure it is a valid session var - if (isset($this->_session_data[ $reset ])) { - // then check to make sure it is not a default var - if (! array_key_exists($reset, $this->_default_session_vars)) { - // remove session var - unset($this->_session_data[ $reset ]); - $this->setSaveState(); - if ($show_all_notices) { - EE_Error::add_success( - sprintf( - esc_html__('The session variable %s was removed.', 'event_espresso'), - $reset - ), - __FILE__, - __FUNCTION__, - __LINE__ - ); - } - } else { - // yeeeeeeeeerrrrrrrrrrr OUT !!!! - if ($show_all_notices) { - EE_Error::add_error( - sprintf( - esc_html__( - 'Sorry! %s is a default session datum and can not be reset.', - 'event_espresso' - ), - $reset - ), - __FILE__, - __FUNCTION__, - __LINE__ - ); - } - $return_value = false; - } - } elseif ($show_all_notices) { + if (! isset($this->_session_data[ $key_to_reset ]) && $show_all_notices) { // oops! that session var does not exist! EE_Error::add_error( sprintf( @@ -1146,13 +1097,48 @@ public function reset_data($data_to_reset = [], bool $show_all_notices = false): 'The session item provided, %s, is invalid or does not exist.', 'event_espresso' ), - $reset + $key_to_reset ), __FILE__, __FUNCTION__, __LINE__ ); $return_value = false; + continue; + } + // then check to make sure it is not a default var + if (array_key_exists($key_to_reset, $this->_default_session_vars)) { + // yeeeeeeeeerrrrrrrrrrr OUT !!!! + if ($show_all_notices) { + EE_Error::add_error( + sprintf( + esc_html__( + 'Sorry! %s is a default session datum and can not be reset.', + 'event_espresso' + ), + $key_to_reset + ), + __FILE__, + __FUNCTION__, + __LINE__ + ); + } + $return_value = false; + continue; + } + // remove session var + unset($this->_session_data[ $key_to_reset ]); + $this->setSaveState(); + if ($show_all_notices) { + EE_Error::add_success( + sprintf( + esc_html__('The session variable %s was removed.', 'event_espresso'), + $key_to_reset + ), + __FILE__, + __FUNCTION__, + __LINE__ + ); } } // end of foreach return $return_value; @@ -1202,7 +1188,7 @@ public function configure_garbage_collection_filters() 50 ) ); - // is there a value? or one that is different than the default 50 records? + // is there a value? or one that is different from the default 50 records? if ($expired_session_transient_delete_query_limit === 0) { // hook into TransientCacheStorage in case Session cleanup was turned off add_filter('FHEE__TransientCacheStorage__transient_cleanup_schedule', '__return_zero'); @@ -1265,7 +1251,7 @@ function ($match) { $error .= "\t-> Section Data1 = "; $error .= substr_replace( substr($data1, $start, $length), - "{$data1[ $i ]}", + "$i", $rpoint, $rlength ); @@ -1273,7 +1259,7 @@ function ($match) { $error .= "\t-> Section Data2 = "; $error .= substr_replace( substr($data2, $start, $length), - "{$data2[ $i ]}", + "$i", $rpoint, $rlength ); diff --git a/core/admin/EE_Admin_List_Table.core.php b/core/admin/EE_Admin_List_Table.core.php index 87c0b3af48d..c824a76e007 100644 --- a/core/admin/EE_Admin_List_Table.core.php +++ b/core/admin/EE_Admin_List_Table.core.php @@ -229,7 +229,7 @@ abstract class EE_Admin_List_Table extends WP_List_Table */ public function __construct(EE_Admin_Page $admin_page, ?AdminListTableFilters $filters = null) { - $this->request = LoaderFactory::getShared(RequestInterface::class); + $this->request = $this->request ?? LoaderFactory::getShared(RequestInterface::class); $this->_admin_page = $admin_page; $this->_req_data = $this->_admin_page->get_request_data(); $this->_view = $this->_admin_page->get_view(); @@ -249,6 +249,8 @@ public function __construct(EE_Admin_Page $admin_page, ?AdminListTableFilters $f $this->_setup_data(); $this->_add_view_counts(); + // ensure changes made to views in child classes get ported back to the admin page + $this->_admin_page->updateViews($this->_views); $this->_nonce_action_ref = $this->_view; diff --git a/core/admin/EE_Admin_Page.core.php b/core/admin/EE_Admin_Page.core.php index 06fd389b9c9..76f74cf3a0c 100644 --- a/core/admin/EE_Admin_Page.core.php +++ b/core/admin/EE_Admin_Page.core.php @@ -107,7 +107,7 @@ abstract class EE_Admin_Page extends EE_Base implements InterminableInterface protected bool $_routing = false; /** - * whether or not initializePage() has run + * whether initializePage() has run * * @var bool */ @@ -1691,10 +1691,8 @@ public function admin_footer_global()
- '; - - // current set timezone for timezone js - echo ''; + + '; } @@ -2088,23 +2086,23 @@ protected function _set_list_table_object() */ public function get_list_table_view_RLs(array $extra_query_args = []): array { - do_action('AHEE_log', __FILE__, __FUNCTION__, ''); - if (empty($this->_views)) { - $this->_views = []; - } + $extra_query_args = apply_filters( + 'FHEE__EE_Admin_Page__get_list_table_view_RLs__extra_query_args', + $extra_query_args, + $this + ); // cycle thru views foreach ($this->_views as $key => $view) { $query_args = []; // check for current view - $this->_views[ $key ]['class'] = $this->_view === $view['slug'] ? 'current' : ''; - $query_args['action'] = $this->_req_action; - $query_args[ $this->_req_action . '_nonce' ] = wp_create_nonce($query_args['action'] . '_nonce'); - $query_args['status'] = $view['slug']; + $this->_views[ $key ]['class'] = $this->_view === $view['slug'] ? 'current' : ''; + $query_args['action'] = $this->_req_action; + $action_nonce = "{$this->_req_action}_nonce"; + $query_args[ $action_nonce ] = wp_create_nonce($action_nonce); + $query_args['status'] = $view['slug']; // merge any other arguments sent in. if (isset($extra_query_args[ $view['slug'] ])) { - foreach ($extra_query_args[ $view['slug'] ] as $extra_query_arg) { - $query_args[] = $extra_query_arg; - } + $query_args = array_merge($query_args, $extra_query_args[ $view['slug'] ]); } $this->_views[ $key ]['url'] = EE_Admin_Page::add_query_args_and_nonce($query_args, $this->_admin_base_url); } @@ -2122,7 +2120,6 @@ public function get_list_table_view_RLs(array $extra_query_args = []): array */ protected function _entries_per_page_dropdown(int $max_entries = 0): string { - do_action('AHEE_log', __FILE__, __FUNCTION__, ''); $values = [10, 25, 50, 100]; $per_page = $this->request->getRequestParam('per_page', 10, DataType::INT); if ($max_entries) { @@ -2683,7 +2680,6 @@ public function _add_admin_page_meta_box( // if $create_func is true (default) then we automatically create the function for displaying the actual meta box. If false then we take the $callback reference passed through and use it instead (so callers can define their own callback function/method if they wish) $call_back_func = $create_func ? static function ($post, $metabox) { - do_action('AHEE_log', __FILE__, __FUNCTION__, ''); echo EEH_Template::display_template( $metabox['args']['template_path'], $metabox['args']['template_args'], @@ -3895,6 +3891,18 @@ public function get_views(): array } + /** + * @param array $views + * @return void + * @since $VID:$ + */ + public function updateViews(array $views) + { + $this->_views = array_merge($this->_views, $views); + } + + + /** /** * get_current_page * diff --git a/core/admin/EE_Admin_Page_CPT.core.php b/core/admin/EE_Admin_Page_CPT.core.php index 8ef947f7130..48f80785854 100644 --- a/core/admin/EE_Admin_Page_CPT.core.php +++ b/core/admin/EE_Admin_Page_CPT.core.php @@ -361,12 +361,15 @@ protected function _load_page_dependencies() ); } // add preview button - add_filter('get_sample_permalink_html', [PreviewButton::class, 'addButton'], 5, 2); + // add_filter('get_sample_permalink_html', [PreviewButton::class, 'addButton'], 5, 2); + PreviewButton::addEventEditorPermalinkButton(5); // add shortlink button to cpt edit screens. // We can do this as a universal thing BECAUSE, cpts use the same format for shortlinks as posts! - add_filter('get_sample_permalink_html', [EventShortlinkButton::class, 'addButton'], 10, 2); + // add_filter('get_sample_permalink_html', [EventShortlinkButton::class, 'addButton'], 10, 2); + EventShortlinkButton::addEventEditorPermalinkButton(); // this is a filter that allows the addition of extra html after the permalink field on the wp post edit-form - add_filter('get_sample_permalink_html', [TicketSelectorShortcodeButton::class, 'addButton'], 12, 4); + // add_filter('get_sample_permalink_html', [TicketSelectorShortcodeButton::class, 'addButton'], 12, 2); + TicketSelectorShortcodeButton::addEventEditorPermalinkButton(12); // insert our own post_stati dropdown add_action('post_submitbox_misc_actions', [$this, 'custom_post_stati_dropdown']); // This allows adding additional information to the publish post submitbox on the wp post edit form diff --git a/core/admin/assets/ee-admin-base.css b/core/admin/assets/ee-admin-base.css index 0459d250db6..d458cde5578 100644 --- a/core/admin/assets/ee-admin-base.css +++ b/core/admin/assets/ee-admin-base.css @@ -171,26 +171,26 @@ --ee-color-white-cloud: hsl(207, 5%, 87.5%); --ee-color-grey-cloud: hsl(207, 5%, 75%); --ee-color-off-white: hsl(207, 0%, 90%); - --ee-status-color-pink: hsl(340, 100%, 70%); - --ee-status-color-hot-pink: hsl(342, 74%, 63%); - --ee-status-color-red: hsl(350, 90%, 60%); - --ee-status-color-orange: hsl(20, 100%, 60%); - --ee-status-color-gold: hsl(40, 98%, 50%); - --ee-status-color-yellow: hsl(50, 95%, 45%); - --ee-status-color-pale-yellow: hsl(50, 70%, 75%); - --ee-status-color-yellow-desat: hsl(50, 95%, 45%); - --ee-status-color-dark-green: hsl(95, 50%, 25%); - --ee-status-color-green: hsl(140, 85%, 35%); - --ee-status-color-dark-green-low-contrast: hsl(140, 85%, 45%); - --ee-status-color-green-high-contrast: hsl(140, 100%, 25%); - --ee-status-color-light-green: hsl(145, 35%, 45%); - --ee-status-color-blue-green: hsl(176, 95%, 30%); - --ee-status-color-blue: hsl(203, 60%, 50%); - --ee-status-color-light-blue: hsl(203, 90%, 70%); - --ee-status-color-pale-blue: hsl(203, 55%, 95%); - --ee-status-color-violet: hsl(239, 35%, 60%); - --ee-status-color-purple: hsl(279, 35%, 50%); - --ee-status-color-light-purple: hsl(279, 35%, 70%); + --ee-status-color-pink: hsl(340, 100%, 75%); + --ee-status-color-hot-pink: hsl(342, 79%, 68%); + --ee-status-color-red: hsl(350, 95%, 65%); + --ee-status-color-orange: hsl(20, 100%, 65%); + --ee-status-color-gold: hsl(40, 100%, 55%); + --ee-status-color-yellow: hsl(50, 100%, 50%); + --ee-status-color-pale-yellow: hsl(50, 75%, 80%); + --ee-status-color-yellow-desat: hsl(50, 100%, 50%); + --ee-status-color-dark-green: hsl(95, 55%, 30%); + --ee-status-color-green: hsl(140, 90%, 40%); + --ee-status-color-dark-green-low-contrast: hsl(140, 90%, 50%); + --ee-status-color-green-high-contrast: hsl(140, 100%, 30%); + --ee-status-color-light-green: hsl(145, 40%, 50%); + --ee-status-color-blue-green: hsl(176, 100%, 35%); + --ee-status-color-blue: hsl(203, 65%, 55%); + --ee-status-color-light-blue: hsl(203, 95%, 75%); + --ee-status-color-pale-blue: hsl(203, 60%, 95%); + --ee-status-color-violet: hsl(239, 40%, 65%); + --ee-status-color-purple: hsl(279, 40%, 55%); + --ee-status-color-light-purple: hsl(279, 40%, 75%); --ee-status-color-pale-grey: hsl(219, 2%, 75%); --ee-status-color-light-grey: hsl(219, 2%, 55%); --ee-status-color-grey: hsl(225, 2%, 37.5%); diff --git a/core/admin/assets/ee-admin-menu.css b/core/admin/assets/ee-admin-menu.css index 8fdb8c71e81..f86d33e40dd 100644 --- a/core/admin/assets/ee-admin-menu.css +++ b/core/admin/assets/ee-admin-menu.css @@ -209,8 +209,8 @@ div.TB-ee-frame a { .ee-switch .ee-switch__input + .ee-switch__toggle, input.ee-toggle-round-flat + label { - width: var(--ee-switch-width); - height: var(--ee-switch-height); + width: var(--ee-switch-width) !important; + height: var(--ee-switch-height) !important; background-color: var(--ee-status-color-light-grey); border-radius: var(--ee-switch-height); transition: background 0.4s; diff --git a/core/admin/assets/ee-admin-page.css b/core/admin/assets/ee-admin-page.css index fcec713ecb4..fb62686d706 100644 --- a/core/admin/assets/ee-admin-page.css +++ b/core/admin/assets/ee-admin-page.css @@ -35,6 +35,7 @@ .ee-status-color--DTA, .ee-status-color--MSN, .ee-status-color--PAP, +.ee-status-color--PRA, .ee-status-color--RAP, .ee-status-color--TCM, .ee-status-color--TKO { @@ -47,6 +48,7 @@ .ee-status-color--DTU, .ee-status-color--MID, .ee-status-color--PPN, +.ee-status-color--PRU, .ee-status-color--RPP, .ee-status-color--TIN, .ee-status-color--TKP { @@ -66,6 +68,7 @@ .ee-status-color--DTE, .ee-status-color--MDO, .ee-status-color--PCN, +.ee-status-color--PRX, .ee-status-color--RCN, .ee-status-color--TKE { color: var(--ee-status-color-light-grey) !important; @@ -75,6 +78,7 @@ .ee-status--inactive, .ee-status-color--DTI, .ee-status-color--MIC, +.ee-status-color--PRN, .ee-status-color--TKA { color: var(--ee-status-color-grey) !important; } @@ -112,6 +116,7 @@ .ee-status-bg--RIC, .ee-status-bg--TAB { background-color: var(--ee-status-color-yellow) !important; + color: var(--ee-status-color-dark-grey) !important; } /* txn abandoned, reg incomplete, dtt sold out */ .ee-status-bg--attention { @@ -124,6 +129,7 @@ .ee-status-bg--DTA, .ee-status-bg--MSN, .ee-status-bg--PAP, +.ee-status-bg--PRA, .ee-status-bg--RAP, .ee-status-bg--TCM, .ee-status-bg--TKO { @@ -136,6 +142,7 @@ .ee-status-bg--DTU, .ee-status-bg--MID, .ee-status-bg--PPN, +.ee-status-bg--PRU, .ee-status-bg--RPP, .ee-status-bg--TIN, .ee-status-bg--TKP { @@ -161,6 +168,7 @@ .ee-status-bg--ignore, .ee-status-bg--DTE, .ee-status-bg--PCN, +.ee-status-bg--PRX, .ee-status-bg--RCN, .ee-status-bg--TKE { background-color: var(--ee-status-color-light-grey) !important; @@ -173,6 +181,7 @@ .ee-status-bg--DTI, .ee-status-bg--DTT, .ee-status-bg--MIC, +.ee-status-bg--PRN, .ee-status-bg--TKA { background-color: var(--ee-status-color-grey) !important; color: var(--ee-color-white) !important; @@ -215,6 +224,11 @@ font-size: var(--ee-font-size-default); padding-block: var(--ee-padding-default); padding-inline: var(--ee-padding-big); + word-wrap: break-word; + white-space: break-spaces; +} +.ee-status-outline.small-text { + font-size: var(--ee-font-size-smaller); } .ee-status-outline.ee-status-outline--error { @@ -254,18 +268,40 @@ } +.ee-status-outline.ee-status-outline--small { + font-size: inherit; + padding-block: var(--ee-padding-micro); + padding-inline: var(--ee-padding-smaller); +} + +.ee-status-outline.ee-status-outline--micro { + font-size: inherit; + padding-block: var(--ee-padding-pico); + padding-inline: var(--ee-padding-micro); +} + + .espresso-admin .ee-status-pill, .espresso-admin .postbox .inside .ee-status-pill { border-radius: var(--ee-size-small); display: inline-flex; margin-block: var(--ee-margin-nano); - margin-inline: var(--ee-padding-nano); + margin-inline: var(--ee-margin-nano); padding-block: var(--ee-padding-nano); padding-inline: var(--ee-padding-default); } +.espresso-admin .ee-tag { + display: inline-flex; + margin-block: var(--ee-margin-nano); + margin-inline: var(--ee-margin-nano); + padding-block: var(--ee-padding-nano); + padding-inline: var(--ee-padding-micro); +} + + /** LAYOUT */ .ee-layout-row, @@ -327,29 +363,67 @@ } +.ee-modal__overlay { + align-content: center; + background-color: hsla(0, 0%, 0%, .75); + display: none; + height: 100vh; + justify-content: center; + left: 0; + overflow-y: hidden; + position: absolute; + top: 0; + width: 100vw; + z-index: 9999; +} +.ee-modal__overlay--open { + display: grid; +} + +.ee-modal, .ee-mini-modal { background-color: var(--ee-color-white); border-radius: calc(.25 * var(--ee-base-ui-scale)); box-shadow: 0 3px 6px -1px hsla(0, 0%, 0%, .75), 0 0 20px -2px hsla(0, 0%, 0%, .15); - height: auto; + box-sizing: border-box; + height: 100%; + isolation: isolate; margin: 0; - max-height: 300px; - min-height: 150px; - min-width: 300px; - overflow: scroll; - padding: var(--ee-base-ui-scale) !important; + max-height: 100%; + max-width: 100%; + overflow-y: scroll; + position: relative; text-align: start; - width: fit-content; - white-space: nowrap; - z-index: 4000; + width: 100%; + z-index: 100; + /* Hide scrollbar for IE, Edge and Firefox */ + -ms-overflow-style: none; /* IE and Edge */ + scrollbar-width: none; /* Firefox */ +} +/* Hide scrollbar for Chrome, Safari and Opera */ +.ee-modal::-webkit-scrollbar, +.ee-mini-modal::-webkit-scrollbar { + display: none; } + +.ee-modal { + border-radius: var(--ee-base-ui-scale); + padding: var(--ee-padding-bigger); +} +.ee-mini-modal { + padding: var(--ee-base-ui-scale) !important; +} + +.ee-modal.ee-modal--open, .ee-mini-modal.ee-mini-modal--open { display: block; } +.ee-modal.ee-modal--closed, .ee-mini-modal.ee-mini-modal--closed { display: none; } +.ee-modal-close-btn, .ee-mini-modal-close-btn { border: none !important; background: none !important; @@ -357,14 +431,57 @@ cursor: pointer; font-size: var(--ee-font-size-xl); position: absolute; + transition: all 150ms; +} +.ee-modal-close-btn { + inset-block-start: calc(.60 * var(--ee-base-ui-scale)); + inset-inline-end: calc(.75 * var(--ee-base-ui-scale)); +} +.ee-mini-modal-close-btn { inset-block-start: calc(.25 * var(--ee-base-ui-scale)); inset-inline-end: 0; - transition: all 150ms; } +.ee-modal-close-btn:hover, .ee-mini-modal-close-btn:hover { color: hsla(207, 5%, 10%, 1); } +.espresso-admin .ee-modal__header h2:not(.hndle):not(.nav-tab-wrapper) { + font-size: 1.5rem; + font-weight: 800; + margin-block-start: var(--ee-margin-nano); + margin-block-end: var(--ee-margin-big); +} + +.ee-modal__footer { + padding-block-start: var(--ee-padding-smaller); +} + +@media screen and (min-width: 782px) { + .ee-modal, + .ee-mini-modal { + min-height: min(100%, 150px); + min-width: min(100%, 300px); + width: fit-content; + } + .ee-modal { + height: auto; + max-height: min(90vh, 1024px); + max-width: min(100%, 768px); + min-height: min(60vh, 427px); + min-width: min(100%, 320px); + padding: var(--ee-padding-bigger); + width: 80vw; + } + .ee-mini-modal { + max-height: max(100%, 300px); + min-height: min(100%, 150px); + min-width: min(100%, 300px); + padding: var(--ee-base-ui-scale) !important; + width: fit-content; + } +} + .ee-page-status__wrapper { display: inline-flex; height: var(--ee-input-height); @@ -487,6 +604,12 @@ div.espresso-admin.wp-core-ui button:not(.ee-btn-base):not(.button--primary):not border-color: var(--ee-link-color); } +.espresso-admin.wp-core-ui .wp-list-table .colspanchange { + color: var(--ee-status-color-red) !important; + font-size: var(--ee-font-size-bigger); + font-weight: 600; +} + .espresso-admin.wp-core-ui .wp-tab-panel, .espresso-admin.wp-core-ui .posttypediv div.tabs-panel, .espresso-admin.wp-core-ui .categorydiv div.tabs-panel, @@ -1075,6 +1198,11 @@ div.espresso-admin.wp-core-ui button:not(.ee-btn-base):not(.button--primary):not margin-inline-end: var(--ee-margin-micro); } +.espresso-admin .tablenav .ee-list-table-filters__submit-buttons { + display: flex; + flex-wrap: nowrap; +} + .espresso-admin .tablenav div { margin-inline-end: var(--ee-margin-micro); } @@ -1683,8 +1811,10 @@ table .espresso-radio-btn-options-ul .big-lbl, .ee-entity--id, .currency-code { color: var(--ee-status-color-light-grey); - font-size: var(--ee-font-size-tiny); - vertical-align: text-top; + font-size: var(--ee-font-size-smaller); + font-weight: 300; + margin-inline-start: var(--ee-margin-pico); + vertical-align: middle; } .ee-entity--id { @@ -3738,9 +3868,6 @@ body.espresso-admin #contextual-help-wrap strong { .espresso-admin .postbox .inside .chosen-container-single .chosen-search input[type=text], .espresso-admin .postbox .inside input:not([type="radio"]):not([type="submit"]):not([type="button"]):not([type="checkbox"]), .espresso-admin .postbox .inside input:not(.ee-input-base):not([type="radio"]):not([type="submit"]):not([type="button"]):not([type="checkbox"]):not(.chosen-search-input) { - margin-inline: var(--ee-margin-pico); - margin-block-start: 0; - margin-block-end: var(--ee-margin-micro); max-width: 100%; width: 100%; } @@ -3887,7 +4014,7 @@ body.espresso-admin #contextual-help-wrap strong { position: relative; } -.ee-aria-tooltip .ee-tooltip { +.ee-aria-tooltip .ee-tooltip.ee-tooltip { background: var(--ee-attention-bg-color); border-radius: var(--ee-size-pico); box-shadow: var(--ee-box-shadow); @@ -3900,7 +4027,7 @@ body.espresso-admin #contextual-help-wrap strong { letter-spacing: .1rem; line-height: 1.25; max-width: clamp(24rem, 36rem, 48rem); - min-width: clamp(30ch, 45ch, 60ch); + min-width: clamp(24ch, 36ch, 48ch); overflow: visible; padding: var(--ee-padding-tiny) var(--ee-padding-small); pointer-events: none; @@ -3910,11 +4037,11 @@ body.espresso-admin #contextual-help-wrap strong { text-indent: 0; text-shadow: none; white-space: pre-wrap; - width: auto; + width: fit-content; z-index: 9999; } -.ee-aria-tooltip.ee-aria-tooltip--big-box .ee-tooltip { +.ee-aria-tooltip.ee-aria-tooltip--big-box .ee-tooltip.ee-tooltip { font-size: var(--ee-font-size-bigger); letter-spacing: unset; line-height: 1.5; @@ -3926,7 +4053,7 @@ body.espresso-admin #contextual-help-wrap strong { z-index: 99999; } -.espresso-admin .ee-locked-entity.ee-aria-tooltip .ee-tooltip { +.espresso-admin .ee-locked-entity.ee-aria-tooltip .ee-tooltip.ee-tooltip { background: var(--ee-status-color-red); color: var(--ee-color-white); font-size: var(--ee-font-size-bigger); @@ -3935,12 +4062,15 @@ body.espresso-admin #contextual-help-wrap strong { } @media screen and (min-width: 782px) { - .ee-aria-tooltip.ee-aria-tooltip--big-box .ee-tooltip { + .ee-aria-tooltip.ee-aria-tooltip--big-box .ee-tooltip.ee-tooltip { max-width: clamp(24rem, 48rem, 96rem); min-width: clamp(30ch, 60ch, 90ch); } } +.ee-aria-tooltip__bounding-box { + position: relative; +} /* INPUTS */ @@ -4555,9 +4685,9 @@ body.espresso-admin #contextual-help-wrap strong { display: inline-flex; font-size: calc(var(--ee-button-height) * .421053); font-weight: 500; - height: min(calc(var(--ee-button-height) - 4px), auto); + height: var(--ee-button-height); justify-content: center; - line-height: 1.25; + line-height: 1; margin: 0; margin-block: var(--ee-margin-nano); margin-inline: var(--ee-margin-nano); @@ -4581,8 +4711,6 @@ body.espresso-admin #contextual-help-wrap strong { .espresso-admin.wp-core-ui input.button.tagadd, -.espresso-admin.wp-core-ui input[type="submit"], -.espresso-admin.wp-core-ui input[type="submit"].button, .espresso-admin.wp-core-ui .quicktags-toolbar input.button:not([type="checkbox"]):not([type="radio"]):not([type="submit"]) { line-height: 1.25; } @@ -4616,6 +4744,7 @@ body.espresso-admin #contextual-help-wrap strong { font-size: calc(var(--ee-button-height-forth) + var(--ee-button-height-shim)); height: var(--ee-button-height); padding-block: var(--ee-padding-nano); + padding-block-start: var(--ee-padding-micro); padding-inline: var(--ee-padding-tiny); } @@ -5898,7 +6027,6 @@ body.espresso-admin #contextual-help-wrap strong { } .espresso-admin .tablenav .actions { - padding-inline-end: var(--ee-padding-default); flex-grow: 4; } @@ -5912,6 +6040,7 @@ body.espresso-admin #contextual-help-wrap strong { .espresso-admin .tablenav .tablenav-pages { flex-grow: 1; justify-content: flex-end; + margin-inline-end: 0; margin-inline-start: auto; padding-inline-start: var(--ee-padding-default); } @@ -6578,6 +6707,7 @@ body.espresso-admin #contextual-help-wrap strong { } .espresso-admin #poststuff .tagsdiv .ajaxtag { + align-items: center; display: flex; margin-block-start: unset; } @@ -6773,3 +6903,34 @@ body.espresso-admin #contextual-help-wrap strong { .espresso-admin div[aria-label="Special character"].mce-floatpanel .mce-reset > .mce-container-body table { min-width: 526px; } + + +.ee-filter-header__text { + align-items: center; + display: inline-flex; + font-size: .9em; +} + +.ee-filter-header__text .ee-status-outline { + margin-inline: var(--ee-margin-pico); +} + +.ee-filter-header__text .ee-filter-header__details { + color: var(--ee-status-color-grey); + font-size: .9em; +} + +.ee-filter-header__text .ee-filter-header__details .dashicons { + margin-inline-end: var(--ee-margin-pico); + position: relative; + top: -0.1875rem; +} + +.ee-ticket-assignments-manager .ee-rspnsv-table__inner-wrapper[role="region"], +.ee-ticket-assignments-manager .ee-rspnsv-table__inner-wrapper #ee-ticket-assignments-manager-table { + position: unset !important; +} + +.ee-ticket-assignments-manager.ee-ticket-assignments-manager.ee-rspnsv-table__outer_wrapper .ee-rspnsv-table thead th:first-child>div { + font-size: var(--ee-font-size-tiny); +} diff --git a/core/admin/assets/ee-admin-page.js b/core/admin/assets/ee-admin-page.js index 0af117be3ce..78ecd3ed2df 100644 --- a/core/admin/assets/ee-admin-page.js +++ b/core/admin/assets/ee-admin-page.js @@ -4,7 +4,7 @@ jQuery(document).ready(function($) { // clear firefox and safari cache $(window).on("unload", function() {}); - const $wpContent = $('#wpcontent'); + const $wpwrap = $('#wpwrap'); function validate_form_inputs( submittedForm ) { @@ -218,7 +218,7 @@ jQuery(document).ready(function($) { }); - $wpContent.on( 'click', '.espresso-help-tab-lnk', function(){ + $wpwrap.on( 'click', '.espresso-help-tab-lnk', function(){ var target_help_tab = '#tab-link-' + $(this).attr('id') + ' a'; if ( $('#contextual-help-wrap').css('display') === 'none' ) { $('#contextual-help-link').trigger('click'); @@ -235,11 +235,12 @@ jQuery(document).ready(function($) { espressoAjaxPopulate = function(el) { function show(i, id) { var p, e = $('#' + id).find('.widget-loading'); + const page = $('#espresso_admin_current_page').val(); if ( e.length ) { p = e.parent(); var u = $('#' + id + '_url').text(); setTimeout( function(){ - p.load( ajaxurl + '?action=espresso-ajax-content&ee_admin_ajax=1&contentid=' + id + '&contenturl=' + u, '', function() { + p.load( ajaxurl + '?page=' + page + '&action=espresso-ajax-content&ee_admin_ajax=1&contentid=' + id + '&contenturl=' + u, '', function() { p.hide().slideDown('normal', function(){ $(this).css('display', ''); }); @@ -267,17 +268,17 @@ jQuery(document).ready(function($) { }); } - $wpContent.on( 'click', '.ee-modal-menu__button', function(e) { + $wpwrap.on( 'click', '.ee-modal-menu__button', function(e) { e.preventDefault(); espressoCloseModalMenus(); $(this).parent().toggleClass('active'); }); - $wpContent.on('click', '.ee-modal-menu__close', function () { + $wpwrap.on('click', '.ee-modal-menu__close', function () { espressoCloseModalMenus(); }); - $wpContent.on('mouseenter', '.ee-aria-tooltip', function () { + $wpwrap.on('mouseenter', '.ee-aria-tooltip', function () { const label = $(this).attr('aria-label'); const tooltip = '' + label + ''; @@ -295,39 +296,71 @@ jQuery(document).ready(function($) { windowTop += 16; } - const tooltipHeight = $tooltip.height(); - const tooltipWidth = $tooltip.width(); - const tooltipPosition = $(this).offset(); + const tooltipHeight = $tooltip.outerHeight(); + const tooltipWidth = $tooltip.outerWidth(); + const tooltipOffset = $(this).offset(); + const tooltipLeft = tooltipOffset.left; + const tooltipRight = tooltipLeft + tooltipWidth; + const tooltipTop = tooltipOffset.top; + const tooltipBottom = tooltipTop + tooltipHeight; - const tooltipLeft = tooltipPosition.left; - const tooltipRight = tooltipLeft + tooltipWidth; - const tooltipTop = tooltipPosition.top; - const tooltipBottom = tooltipTop + tooltipHeight; - - let shiftLeft = -12; - let shiftTop = (tooltipHeight + 24) * -1; + let shiftLeft = -16; // plus 1 rem for a bit of space + let shiftTop = (tooltipHeight + 8) * -1; // plus half rem for a bit of space + // does tooltip go off the top of the screen? if (tooltipTop < windowTop) { - shiftTop = (shiftTop - (windowTop - tooltipTop)) * -1; - } else if (tooltipBottom > windowBottom) { + shiftTop -= tooltipTop - windowTop; + } + // or the bottom of the screen? + if (tooltipBottom > windowBottom) { shiftTop -= tooltipBottom - windowBottom; } - + // what about the left side of the screen? if (tooltipLeft < 0) { - shiftLeft = (shiftTop - tooltipLeft) * -1; - } else if (tooltipRight > windowWidth) { + shiftLeft = 16; // just set left to 1 rem for a bit of space + } + // or the right side? + if (tooltipRight > windowWidth) { shiftLeft -= tooltipRight - windowWidth; } - $tooltip.css({ - left: $tooltip.position().left + shiftLeft + "px", - top: $tooltip.position().top + shiftTop + "px" - }); - - $tooltip.delay(500).fadeIn(250); + const $parent = $(this).closest('.ee-aria-tooltip__bounding-box'); + if ($parent.length) { + const parentHeight = $parent.height(); + const parentWidth = $parent.width(); + const parentOffset = $parent.offset(); + const parentLeft = parentOffset.left; + const parentRight = parentLeft + parentWidth; + const parentTop = parentOffset.top; + const parentBottom = parentTop + parentHeight; + + // does tooltip go off the top of the parent container? + if ((tooltipTop + shiftTop) < parentTop) { + shiftTop += tooltipTop - parentTop; + } + // or the bottom of the parent container? + if ((tooltipBottom + shiftTop) > parentBottom) { + shiftTop -= tooltipBottom - parentBottom; + } + // what about the left side of the parent container? + if ((tooltipLeft + shiftLeft) < parentLeft) { + shiftLeft = parentLeft + 16; + } + // or the right side of the parent container? + if ((tooltipRight + shiftLeft) > parentRight) { + shiftLeft -= tooltipRight - parentRight + 16; + } + } + const tooltipStyles = { + left: shiftLeft + "px", + top: shiftTop + "px" + }; + + $tooltip.css(tooltipStyles).delay(500).fadeIn(250); }); - $wpContent.on('mouseleave', '.ee-aria-tooltip', function () { + $wpwrap.on('mouseleave', '.ee-aria-tooltip', function () { + // comment this out if you need to adjust tooltip styles and want them to stay open $(this).find('.ee-tooltip').fadeOut(125).remove(); }); diff --git a/core/data_migration_scripts/4_1_0_stages/EE_DMS_4_1_0_events.dmsstage.php b/core/data_migration_scripts/4_1_0_stages/EE_DMS_4_1_0_events.dmsstage.php index 10ef69a07d2..d83e7150370 100644 --- a/core/data_migration_scripts/4_1_0_stages/EE_DMS_4_1_0_events.dmsstage.php +++ b/core/data_migration_scripts/4_1_0_stages/EE_DMS_4_1_0_events.dmsstage.php @@ -261,12 +261,13 @@ protected function _migration_step($num_items_to_migrate = 50) $this->_convert_start_end_times($event_row, $post_id); $event_meta = maybe_unserialize($event_row['event_meta']); $guid = $event_meta['event_thumbnail_url'] ?? null; - $this->get_migration_script()->convert_image_url_to_attachment_and_attach_to_post( - $guid, - $post_id, - $this - ); - + if ($guid) { + $this->get_migration_script()->convert_image_url_to_attachment_and_attach_to_post( + $guid, + $post_id, + $this + ); + } // maybe create a venue from info on the event? $new_venue_id = $this->_maybe_create_venue($event_row); if ($new_venue_id) { @@ -604,11 +605,13 @@ private function _maybe_create_venue($old_event): int if ($new_id) { $this->_insert_venue_into_meta_table($new_id, $old_event); $guid = $old_event['venue_image'] ?? null; - $this->get_migration_script()->convert_image_url_to_attachment_and_attach_to_post( - $guid, - $new_id, - $this - ); + if($guid) { + $this->get_migration_script()->convert_image_url_to_attachment_and_attach_to_post( + $guid, + $new_id, + $this + ); + } } // we don't bother recording the conversion from old events to venues as that // will complicate finding the conversion from old venues to new events diff --git a/core/data_migration_scripts/4_1_0_stages/EE_DMS_4_1_0_gateways.dmsstage.php b/core/data_migration_scripts/4_1_0_stages/EE_DMS_4_1_0_gateways.dmsstage.php index d6aeea81110..6445b26dc00 100644 --- a/core/data_migration_scripts/4_1_0_stages/EE_DMS_4_1_0_gateways.dmsstage.php +++ b/core/data_migration_scripts/4_1_0_stages/EE_DMS_4_1_0_gateways.dmsstage.php @@ -187,7 +187,7 @@ private function _convert_gateway_settings(array $old_gateway_settings, string $ * @param string $new_gateway_slug * @return string */ - private function _get_old_gateway_option(string $new_gateway_slug): string + private function _get_old_gateway_option(string $new_gateway_slug): ?string { return get_option( $this->_get_old_gateway_option_name($new_gateway_slug), diff --git a/core/data_migration_scripts/4_1_0_stages/EE_DMS_4_1_0_question_groups.dmsstage.php b/core/data_migration_scripts/4_1_0_stages/EE_DMS_4_1_0_question_groups.dmsstage.php index 90571ff39a9..c2d4ac48797 100644 --- a/core/data_migration_scripts/4_1_0_stages/EE_DMS_4_1_0_question_groups.dmsstage.php +++ b/core/data_migration_scripts/4_1_0_stages/EE_DMS_4_1_0_question_groups.dmsstage.php @@ -143,9 +143,9 @@ private function _insert_new_question_group(array $old_question_group): int $identifier = $old_question_group['group_identifier']; } $cols_n_values = [ - 'QSG_name' => stripslashes($old_question_group['group_name']), + 'QSG_name' => stripslashes($old_question_group['group_name'] ?: ''), 'QSG_identifier' => $identifier, - 'QSG_desc' => stripslashes($old_question_group['group_description']), + 'QSG_desc' => stripslashes($old_question_group['group_description'] ?: ''), 'QSG_order' => $old_question_group['group_order'], 'QSG_show_group_name' => $old_question_group['show_group_name'], 'QSG_show_group_desc' => $old_question_group['show_group_description'], diff --git a/core/data_migration_scripts/4_1_0_stages/EE_DMS_4_1_0_questions.dmsstage.php b/core/data_migration_scripts/4_1_0_stages/EE_DMS_4_1_0_questions.dmsstage.php index e973a28a862..2dab2a550c4 100644 --- a/core/data_migration_scripts/4_1_0_stages/EE_DMS_4_1_0_questions.dmsstage.php +++ b/core/data_migration_scripts/4_1_0_stages/EE_DMS_4_1_0_questions.dmsstage.php @@ -140,11 +140,11 @@ private function _insert_new_question($old_question): int $cols_n_values = [ 'QST_display_text' => stripslashes($old_question['question']), - 'QST_admin_label' => $old_question['system_name'] ?: sanitize_title($old_question['question']), + 'QST_admin_label' => sanitize_title($old_question['question'] ?: ''), 'QST_system' => (string) $old_question['system_name'], 'QST_type' => $old_question['question_type'], 'QST_required' => 'Y' == $old_question['required'], - 'QST_required_text' => stripslashes($old_question['required_text']), + 'QST_required_text' => stripslashes($old_question['required_text'] ?: ''), 'QST_order' => $old_question['sequence'], 'QST_admin_only' => 'Y' == $old_question['admin_only'], 'QST_wp_user' => $old_question['wp_user'], diff --git a/core/data_migration_scripts/4_6_0_stages/EE_DMS_4_6_0_invoice_settings.dmsstage.php b/core/data_migration_scripts/4_6_0_stages/EE_DMS_4_6_0_invoice_settings.dmsstage.php index 73a863fafd5..910cb8ae6c8 100644 --- a/core/data_migration_scripts/4_6_0_stages/EE_DMS_4_6_0_invoice_settings.dmsstage.php +++ b/core/data_migration_scripts/4_6_0_stages/EE_DMS_4_6_0_invoice_settings.dmsstage.php @@ -49,14 +49,14 @@ protected function _migration_step($num_items_to_migrate = 1) $templates_relative_path = 'modules/gateways/Invoice/lib/templates/'; $overridden_invoice_body = EEH_Template::locate_template( $templates_relative_path . 'invoice_body.template.php', - null, + [], false, false, true ); $overridden_receipt_body = EEH_Template::locate_template( $templates_relative_path . 'receipt_body.template.php', - null, + [], false, false, true diff --git a/core/data_migration_scripts/EE_DMS_Core_5_0_0.dms.php b/core/data_migration_scripts/EE_DMS_Core_5_0_0.dms.php index 396eb584848..c062d2a23ee 100644 --- a/core/data_migration_scripts/EE_DMS_Core_5_0_0.dms.php +++ b/core/data_migration_scripts/EE_DMS_Core_5_0_0.dms.php @@ -59,8 +59,8 @@ public function can_migrate_from_version($version_array): bool { $version_string = $version_array['Core']; return $version_string && - version_compare($version_string, '5.0.0.decaf', '<') && - version_compare($version_string, '4.10.0.decaf', '>='); + version_compare($version_string, '5.0.0.decaf', '<') && + version_compare($version_string, '4.10.0.decaf', '>='); } @@ -79,10 +79,10 @@ public function schema_changes_before_migration(): bool REG_ID int(10) unsigned NOT NULL, QST_ID int(10) unsigned NOT NULL, ANS_value text NOT NULL, - PRIMARY KEY (ANS_ID), - KEY REG_ID (REG_ID), - KEY QST_ID (QST_ID)' + PRIMARY KEY (ANS_ID)' ); + $this->_get_table_manager()->addIndex('esp_answer', 'REG_ID', 'REG_ID'); + $this->_get_table_manager()->addIndex('esp_answer', 'QST_ID', 'QST_ID'); $this->_table_has_not_changed_since_previous( @@ -99,12 +99,18 @@ public function schema_changes_before_migration(): bool ATT_zip varchar(12) DEFAULT NULL, ATT_email varchar(255) NOT NULL, ATT_phone varchar(45) DEFAULT NULL, - PRIMARY KEY (ATTM_ID), - KEY ATT_ID (ATT_ID), - KEY ATT_email (ATT_email(191)), - KEY ATT_lname (ATT_lname), - KEY ATT_fname (ATT_fname)" + PRIMARY KEY (ATTM_ID)" ); + $this->_get_table_manager()->addIndex('esp_attendee_meta', 'ATT_ID', 'ATT_ID'); + $this->_get_table_manager()->addIndex( + 'esp_attendee_meta', + 'ATT_email', + 'ATT_email', + TableAnalysis::INDEX_TYPE_INDEX, + TableAnalysis::INDEX_COLUMN_SIZE + ); + $this->_get_table_manager()->addIndex('esp_attendee_meta', 'ATT_lname', 'ATT_lname'); + $this->_get_table_manager()->addIndex('esp_attendee_meta', 'ATT_fname', 'ATT_fname'); $this->_table_has_not_changed_since_previous( @@ -114,9 +120,17 @@ public function schema_changes_before_migration(): bool DTT_ID int(10) unsigned NOT NULL, CHK_in tinyint(1) unsigned NOT NULL DEFAULT 1, CHK_timestamp datetime NOT NULL DEFAULT CURRENT_TIMESTAMP, - PRIMARY KEY (CHK_ID), - KEY REG_ID (REG_ID), - KEY DTT_ID (DTT_ID)" + PRIMARY KEY (CHK_ID)" + ); + $this->_get_table_manager()->addIndex('esp_checkin', 'REG_ID', 'REG_ID'); + $this->_get_table_manager()->addIndex('esp_checkin', 'DTT_ID', 'DTT_ID'); + $this->_get_table_manager()->addIndex( + 'esp_checkin', + 'CHK_timestamp', + 'CHK_timestamp', + TableAnalysis::INDEX_TYPE_INDEX, + null, + true ); @@ -162,9 +176,9 @@ public function schema_changes_before_migration(): bool "CPM_ID int(11) NOT NULL AUTO_INCREMENT, CUR_code varchar(6) NOT NULL, PMD_ID int(11) NOT NULL, - PRIMARY KEY (CPM_ID), - KEY PMD_ID (PMD_ID)" + PRIMARY KEY (CPM_ID)" ); + $this->_get_table_manager()->addIndex('esp_currency_payment_method', 'PMD_ID', 'PMD_ID'); $this->_table_is_changed_in_this_version( @@ -183,13 +197,13 @@ public function schema_changes_before_migration(): bool DTT_order mediumint(3) unsigned DEFAULT 0, DTT_parent int(10) unsigned DEFAULT 0, DTT_deleted tinyint(1) unsigned NOT NULL DEFAULT 0, - PRIMARY KEY (DTT_ID), - KEY DTT_EVT_start (DTT_EVT_start), - KEY DTT_EVT_end (DTT_EVT_end), - KEY EVT_ID (EVT_ID), - KEY VNU_ID (VNU_ID)" + PRIMARY KEY (DTT_ID)" ); - $this->_get_table_manager()->dropIndex('esp_datetime', 'DTT_is_primary'); + $this->_get_table_manager()->addIndex('esp_datetime', 'EVT_ID', 'EVT_ID'); + // $this->_get_table_manager()->addIndex('esp_datetime', 'VNU_ID', 'VNU_ID'); + $this->_get_table_manager()->addIndex('esp_datetime', 'DTT_EVT_start', 'DTT_EVT_start'); + // $this->_get_table_manager()->addIndex('esp_datetime', 'DTT_EVT_end', 'DTT_EVT_end'); + // $this->_get_table_manager()->dropIndex('esp_datetime', 'DTT_is_primary'); $this->_table_has_not_changed_since_previous( @@ -197,10 +211,10 @@ public function schema_changes_before_migration(): bool "DTK_ID int(10) unsigned NOT NULL AUTO_INCREMENT, DTT_ID int(10) unsigned NOT NULL, TKT_ID int(10) unsigned NOT NULL, - PRIMARY KEY (DTK_ID), - KEY DTT_ID (DTT_ID), - KEY TKT_ID (TKT_ID)" + PRIMARY KEY (DTK_ID)" ); + $this->_get_table_manager()->addIndex('esp_datetime_ticket', 'DTT_ID', 'DTT_ID'); + $this->_get_table_manager()->addIndex('esp_datetime_ticket', 'TKT_ID', 'TKT_ID'); $this->_table_has_not_changed_since_previous( @@ -208,10 +222,10 @@ public function schema_changes_before_migration(): bool "EMT_ID bigint(20) unsigned NOT NULL AUTO_INCREMENT, EVT_ID bigint(20) unsigned NOT NULL DEFAULT 0, GRP_ID int(10) unsigned NOT NULL DEFAULT 0, - PRIMARY KEY (EMT_ID), - KEY EVT_ID (EVT_ID), - KEY GRP_ID (GRP_ID)" + PRIMARY KEY (EMT_ID)" ); + $this->_get_table_manager()->addIndex('esp_event_message_template', 'EVT_ID', 'EVT_ID'); + $this->_get_table_manager()->addIndex('esp_event_message_template', 'GRP_ID', 'GRP_ID'); $this->_table_is_changed_in_this_version( @@ -231,10 +245,17 @@ public function schema_changes_before_migration(): bool EVT_external_URL varchar(200) NULL, EVT_donations tinyint(1) NULL, FSC_UUID varchar(25) DEFAULT NULL, - PRIMARY KEY (EVTM_ID), - KEY EVT_ID (EVT_ID), - KEY VNU_ID (VNU_ID)" + PRIMARY KEY (EVTM_ID)" ); + $this->_get_table_manager()->addIndex( + 'esp_event_meta', + 'EVT_ID', + 'EVT_ID', + TableAnalysis::INDEX_TYPE_INDEX, + null, + true + ); + // $this->_get_table_manager()->addIndex('esp_event_meta', 'VNU_ID', 'VNU_ID'); $this->_table_has_not_changed_since_previous( @@ -244,10 +265,10 @@ public function schema_changes_before_migration(): bool QSG_ID int(10) unsigned NOT NULL, EQG_primary tinyint(1) unsigned NOT NULL DEFAULT 0, EQG_additional tinyint(1) unsigned NOT NULL DEFAULT 0, - PRIMARY KEY (EQG_ID), - KEY EVT_ID (EVT_ID), - KEY QSG_ID (QSG_ID)" + PRIMARY KEY (EQG_ID)" ); + $this->_get_table_manager()->addIndex('esp_event_question_group', 'EVT_ID', 'EVT_ID'); + $this->_get_table_manager()->addIndex('esp_event_question_group', 'QSG_ID', 'QSG_ID'); $this->_table_has_not_changed_since_previous( @@ -267,9 +288,9 @@ public function schema_changes_before_migration(): bool EXM_type varchar(45) DEFAULT NULL, EXM_key varchar(45) DEFAULT NULL, EXM_value text, - PRIMARY KEY (EXM_ID), - KEY EXM_type (EXM_type,OBJ_ID,EXM_key)" + PRIMARY KEY (EXM_ID)" ); + $this->_get_table_manager()->addIndex('esp_extra_meta', 'EXM_type', 'EXM_type,OBJ_ID,EXM_key'); $this->_table_has_not_changed_since_previous( @@ -279,9 +300,17 @@ public function schema_changes_before_migration(): bool EXJ_first_model_name varchar(20) NOT NULL, EXJ_second_model_id varchar(12) NOT NULL, EXJ_second_model_name varchar(20) NOT NULL, - PRIMARY KEY (EXJ_ID), - KEY first_model (EXJ_first_model_name,EXJ_first_model_id), - KEY second_model (EXJ_second_model_name,EXJ_second_model_id)" + PRIMARY KEY (EXJ_ID)" + ); + $this->_get_table_manager()->addIndex( + 'esp_extra_join', + 'first_model', + 'EXJ_first_model_name,EXJ_first_model_id' + ); + $this->_get_table_manager()->addIndex( + 'esp_extra_join', + 'second_model', + 'EXJ_second_model_name,EXJ_second_model_id' ); @@ -300,11 +329,11 @@ public function schema_changes_before_migration(): bool FIN_status varchar(32) NOT NULL DEFAULT 'active', FIN_type tinytext DEFAULT NULL, FIN_wpUser bigint(20) unsigned DEFAULT NULL, - PRIMARY KEY (FIN_UUID), - KEY FSC_UUID (FSC_UUID)" + PRIMARY KEY (FIN_UUID)" ); - $this->_get_table_manager()->dropIndex('esp_form_element', 'FIN_order'); - $this->_get_table_manager()->dropIndex('esp_form_element', 'FIN_status'); + $this->_get_table_manager()->addIndex('esp_form_element', 'FSC_UUID', 'FSC_UUID'); + // $this->_get_table_manager()->dropIndex('esp_form_element', 'FIN_order'); + // $this->_get_table_manager()->dropIndex('esp_form_element', 'FIN_status'); $this->_table_is_new_in_this_version( @@ -317,11 +346,11 @@ public function schema_changes_before_migration(): bool FSC_order tinyint(2) unsigned NOT NULL DEFAULT 0, FSC_status varchar(32) NOT NULL DEFAULT 'active', FSC_wpUser bigint(20) unsigned DEFAULT NULL, - PRIMARY KEY (FSC_UUID), - KEY FSC_belongsTo (FSC_belongsTo)" + PRIMARY KEY (FSC_UUID)" ); - $this->_get_table_manager()->dropIndex('esp_form_section', 'FSC_order'); - $this->_get_table_manager()->dropIndex('esp_form_section', 'FSC_status'); + $this->_get_table_manager()->addIndex('esp_form_section', 'FSC_belongsTo', 'FSC_belongsTo'); + // $this->_get_table_manager()->dropIndex('esp_form_section', 'FSC_order'); + // $this->_get_table_manager()->dropIndex('esp_form_section', 'FSC_status'); $this->_table_is_new_in_this_version( @@ -331,9 +360,17 @@ public function schema_changes_before_migration(): bool TXN_ID int(10) DEFAULT NULL, FSB_data mediumtext DEFAULT NULL, FSB_submitted datetime NOT NULL DEFAULT CURRENT_TIMESTAMP, - PRIMARY KEY (FSB_UUID), - KEY FSC_UUID (FSC_UUID), - KEY TXN_ID (TXN_ID)" + PRIMARY KEY (FSB_UUID)" + ); + $this->_get_table_manager()->addIndex('esp_form_submission', 'FSC_UUID', 'FSC_UUID'); + $this->_get_table_manager()->addIndex('esp_form_submission', 'TXN_ID', 'TXN_ID'); + $this->_get_table_manager()->addIndex( + 'esp_form_submission', + 'FSB_submitted', + 'FSB_submitted', + TableAnalysis::INDEX_TYPE_INDEX, + null, + true ); @@ -356,11 +393,19 @@ public function schema_changes_before_migration(): bool OBJ_ID int(11) DEFAULT NULL, OBJ_type varchar(45) DEFAULT NULL, LIN_timestamp datetime NOT NULL DEFAULT CURRENT_TIMESTAMP, - PRIMARY KEY (LIN_ID), - KEY parent_order (LIN_parent,LIN_order), - KEY txn_type_timestamp (TXN_ID,LIN_type,LIN_timestamp), - KEY txn_obj_id_obj_type (TXN_ID,OBJ_ID,OBJ_type), - KEY obj_id_obj_type (OBJ_ID,OBJ_type)" + PRIMARY KEY (LIN_ID)" + ); + $this->_get_table_manager()->addIndex('esp_line_item', 'parent_order', 'LIN_parent,LIN_order'); + $this->_get_table_manager()->addIndex('esp_line_item', 'txn_type_timestamp', 'TXN_ID,LIN_type,LIN_timestamp'); + $this->_get_table_manager()->addIndex('esp_line_item', 'txn_obj_id_obj_type', 'TXN_ID,OBJ_ID,OBJ_type'); + $this->_get_table_manager()->addIndex('esp_line_item', 'obj_id_obj_type', 'OBJ_ID,OBJ_type'); + $this->_get_table_manager()->addIndex( + 'esp_line_item', + 'LIN_timestamp', + 'LIN_timestamp', + TableAnalysis::INDEX_TYPE_INDEX, + null, + true ); @@ -373,11 +418,11 @@ public function schema_changes_before_migration(): bool LOG_type varchar(45) DEFAULT NULL, LOG_message text, LOG_wp_user int(11) DEFAULT NULL, - PRIMARY KEY (LOG_ID), - KEY LOG_time (LOG_time), - KEY OBJ (OBJ_type,OBJ_ID), - KEY LOG_type (LOG_type)" + PRIMARY KEY (LOG_ID)" ); + $this->_get_table_manager()->addIndex('esp_log', 'LOG_time', 'LOG_time'); + $this->_get_table_manager()->addIndex('esp_log', 'LOG_type', 'LOG_type'); + $this->_get_table_manager()->addIndex('esp_log', 'OBJ', 'OBJ_type,OBJ_ID'); $this->_table_has_not_changed_since_previous( @@ -399,22 +444,34 @@ public function schema_changes_before_migration(): bool STS_ID varchar(3) NOT NULL DEFAULT 'MIC', MSG_created datetime NOT NULL DEFAULT CURRENT_TIMESTAMP, MSG_modified datetime NOT NULL DEFAULT CURRENT_TIMESTAMP, - PRIMARY KEY (MSG_ID), - KEY GRP_ID (GRP_ID), - KEY TXN_ID (TXN_ID), - KEY MSG_recipient_ID (MSG_recipient_ID), - KEY MSG_to (MSG_to(191)), - KEY MSG_from (MSG_from(191)), - KEY MSG_modified (MSG_modified)" - ); - $this->_get_table_manager()->dropIndex('esp_message', 'MSG_messenger'); - $this->_get_table_manager()->dropIndex('esp_message', 'MSG_message_type'); - $this->_get_table_manager()->dropIndex('esp_message', 'MSG_context'); - $this->_get_table_manager()->dropIndex('esp_message', 'MSG_recipient_type'); - $this->_get_table_manager()->dropIndex('esp_message', 'MSG_subject'); - $this->_get_table_manager()->dropIndex('esp_message', 'MSG_created'); - $this->_get_table_manager()->dropIndex('esp_message', 'MSG_priority'); - $this->_get_table_manager()->dropIndex('esp_message', 'STS_ID'); + PRIMARY KEY (MSG_ID)" + ); + $this->_get_table_manager()->addIndex('esp_message', 'GRP_ID', 'GRP_ID'); + $this->_get_table_manager()->addIndex('esp_message', 'TXN_ID', 'TXN_ID'); + $this->_get_table_manager()->addIndex('esp_message', 'MSG_recipient_ID', 'MSG_recipient_ID'); + $this->_get_table_manager()->addIndex( + 'esp_message', + 'MSG_to', + 'MSG_to', + TableAnalysis::INDEX_TYPE_INDEX, + TableAnalysis::INDEX_COLUMN_SIZE + ); + $this->_get_table_manager()->addIndex( + 'esp_message', + 'MSG_from', + 'MSG_from', + TableAnalysis::INDEX_TYPE_INDEX, + TableAnalysis::INDEX_COLUMN_SIZE + ); + $this->_get_table_manager()->addIndex('esp_message', 'MSG_modified', 'MSG_modified'); + // $this->_get_table_manager()->dropIndex('esp_message', 'MSG_messenger'); + // $this->_get_table_manager()->dropIndex('esp_message', 'MSG_message_type'); + // $this->_get_table_manager()->dropIndex('esp_message', 'MSG_context'); + // $this->_get_table_manager()->dropIndex('esp_message', 'MSG_recipient_type'); + // $this->_get_table_manager()->dropIndex('esp_message', 'MSG_subject'); + // $this->_get_table_manager()->dropIndex('esp_message', 'MSG_created'); + // $this->_get_table_manager()->dropIndex('esp_message', 'MSG_priority'); + // $this->_get_table_manager()->dropIndex('esp_message', 'STS_ID'); $this->_table_has_not_changed_since_previous( @@ -424,9 +481,9 @@ public function schema_changes_before_migration(): bool MTP_context varchar(50) NOT NULL, MTP_template_field varchar(30) NOT NULL, MTP_content text NOT NULL, - PRIMARY KEY (MTP_ID), - KEY GRP_ID (GRP_ID)" + PRIMARY KEY (MTP_ID)" ); + $this->_get_table_manager()->addIndex('esp_message_template', 'GRP_ID', 'GRP_ID'); $this->_table_has_not_changed_since_previous( @@ -441,9 +498,9 @@ public function schema_changes_before_migration(): bool MTP_is_override tinyint(1) NOT NULL DEFAULT '0', MTP_deleted tinyint(1) NOT NULL DEFAULT '0', MTP_is_active tinyint(1) NOT NULL DEFAULT '1', - PRIMARY KEY (GRP_ID), - KEY MTP_user_id (MTP_user_id)" + PRIMARY KEY (GRP_ID)" ); + $this->_get_table_manager()->addIndex('esp_message_template_group', 'MTP_user_id', 'MTP_user_id'); $this->_table_has_not_changed_since_previous( @@ -462,10 +519,17 @@ public function schema_changes_before_migration(): bool PAY_details text, PAY_redirect_url varchar(300), PAY_redirect_args text, - PRIMARY KEY (PAY_ID), - KEY PAY_timestamp (PAY_timestamp), - KEY TXN_ID (TXN_ID)" + PRIMARY KEY (PAY_ID)" ); + $this->_get_table_manager()->addIndex( + 'esp_payment', + 'PAY_timestamp', + 'PAY_timestamp', + TableAnalysis::INDEX_TYPE_INDEX, + null, + true + ); + $this->_get_table_manager()->addIndex('esp_payment', 'TXN_ID', 'TXN_ID'); $this->_table_has_not_changed_since_previous( @@ -483,10 +547,15 @@ public function schema_changes_before_migration(): bool PMD_open_by_default tinyint(1) NOT NULL DEFAULT '0', PMD_button_url varchar(1012) DEFAULT NULL, PMD_scope varchar(255) NULL DEFAULT 'frontend', - PRIMARY KEY (PMD_ID), - UNIQUE KEY PMD_slug_UNIQUE (PMD_slug)" + PRIMARY KEY (PMD_ID)" ); - $this->_get_table_manager()->dropIndex('esp_payment_method', 'PMD_type'); + $this->_get_table_manager()->addIndex( + 'esp_payment_method', + 'PMD_slug_UNIQUE', + 'PMD_slug', + TableAnalysis::INDEX_TYPE_UNIQUE + ); + // $this->_get_table_manager()->dropIndex('esp_payment_method', 'PMD_type'); $this->_table_is_changed_in_this_version( @@ -502,9 +571,9 @@ public function schema_changes_before_migration(): bool PRC_order tinyint(3) unsigned NOT NULL DEFAULT '0', PRC_wp_user bigint(20) unsigned NULL, PRC_parent int(10) unsigned DEFAULT 0, - PRIMARY KEY (PRC_ID), - KEY PRT_ID (PRT_ID)" + PRIMARY KEY (PRC_ID)" ); + $this->_get_table_manager()->addIndex('esp_price', 'PRT_ID', 'PRT_ID'); $this->_table_has_not_changed_since_previous( @@ -526,10 +595,10 @@ public function schema_changes_before_migration(): bool "TKP_ID int(10) unsigned NOT NULL AUTO_INCREMENT, TKT_ID int(10) unsigned NOT NULL, PRC_ID int(10) unsigned NOT NULL, - PRIMARY KEY (TKP_ID), - KEY TKT_ID (TKT_ID), - KEY PRC_ID (PRC_ID)" + PRIMARY KEY (TKP_ID)" ); + $this->_get_table_manager()->addIndex('esp_ticket_price', 'TKT_ID', 'TKT_ID'); + $this->_get_table_manager()->addIndex('esp_ticket_price', 'PRC_ID', 'PRC_ID'); $this->_table_has_not_changed_since_previous( @@ -558,7 +627,7 @@ public function schema_changes_before_migration(): bool QST_deleted tinyint(2) unsigned NOT NULL DEFAULT 0, PRIMARY KEY (QST_ID)" ); - $this->_get_table_manager()->dropIndex('esp_question', 'QST_order'); + // $this->_get_table_manager()->dropIndex('esp_question', 'QST_order'); $this->_table_has_not_changed_since_previous( @@ -573,11 +642,15 @@ public function schema_changes_before_migration(): bool QSG_system tinyint(2) NULL, QSG_deleted tinyint(1) unsigned NOT NULL DEFAULT 0, QSG_wp_user bigint(20) unsigned NULL, - PRIMARY KEY (QSG_ID), - UNIQUE KEY QSG_identifier_UNIQUE (QSG_identifier), - KEY QSG_order (QSG_order)" + PRIMARY KEY (QSG_ID)" + ); + $this->_get_table_manager()->addIndex( + 'esp_question_group', + 'QSG_identifier_UNIQUE', + 'QSG_identifier', + TableAnalysis::INDEX_TYPE_UNIQUE ); - $this->_get_table_manager()->dropIndex('esp_question_group', 'QSG_order'); + // $this->_get_table_manager()->dropIndex('esp_question_group', 'QSG_order'); $this->_table_has_not_changed_since_previous( @@ -586,10 +659,10 @@ public function schema_changes_before_migration(): bool QSG_ID int(10) unsigned NOT NULL, QST_ID int(10) unsigned NOT NULL, QGQ_order int(10) unsigned NOT NULL DEFAULT 0, - PRIMARY KEY (QGQ_ID), - KEY QST_ID (QST_ID)" + PRIMARY KEY (QGQ_ID)" ); - $this->_get_table_manager()->dropIndex('esp_question_group_question', 'QSG_ID_order'); + $this->_get_table_manager()->addIndex('esp_question_group_question', 'QST_ID', 'QST_ID'); + // $this->_get_table_manager()->dropIndex('esp_question_group_question', 'QSG_ID_order'); $this->_table_has_not_changed_since_previous( @@ -601,9 +674,9 @@ public function schema_changes_before_migration(): bool QSO_order int(10) unsigned NOT NULL DEFAULT 0, QSO_system varchar(25) DEFAULT NULL, QSO_deleted tinyint(1) unsigned NOT NULL DEFAULT 0, - PRIMARY KEY (QSO_ID), - KEY QST_ID (QST_ID)" + PRIMARY KEY (QSO_ID)" ); + $this->_get_table_manager()->addIndex('esp_question_option', 'QST_ID', 'QST_ID'); $this->_get_table_manager()->dropIndex('esp_question_option', 'QSO_order'); @@ -625,16 +698,24 @@ public function schema_changes_before_migration(): bool REG_group_size tinyint(2) unsigned DEFAULT '1', REG_att_is_going tinyint(1) DEFAULT '0', REG_deleted tinyint(1) DEFAULT '0', - PRIMARY KEY (REG_ID), - KEY REG_url_link (REG_url_link), - KEY REG_code (REG_code), - KEY REG_date (REG_date), - KEY TXN_ID (TXN_ID), - KEY ATT_ID (ATT_ID), - KEY TKT_ID (TKT_ID), - KEY EVT_ID (EVT_ID)" - ); - $this->_get_table_manager()->dropIndex('esp_registration', 'STS_ID'); + PRIMARY KEY (REG_ID)" + ); + $this->_get_table_manager()->addIndex('esp_registration', 'REG_url_link', 'REG_url_link'); + $this->_get_table_manager()->addIndex('esp_registration', 'REG_code', 'REG_code'); + // $this->_get_table_manager()->addIndex( + // 'esp_registration', + // 'REG_date', + // 'REG_date', + // TableAnalysis::INDEX_TYPE_INDEX, + // null, + // true + // ); + $this->_get_table_manager()->addIndex('esp_registration', 'TXN_ID', 'TXN_ID'); + $this->_get_table_manager()->addIndex('esp_registration', 'ATT_ID', 'ATT_ID'); + $this->_get_table_manager()->addIndex('esp_registration', 'TKT_ID', 'TKT_ID'); + $this->_get_table_manager()->addIndex('esp_registration', 'EVT_ID', 'EVT_ID'); + $this->_get_table_manager()->dropIndex('esp_registration', 'REG_deleted'); + // $this->_get_table_manager()->dropIndex('esp_registration', 'STS_ID'); $this->_table_has_not_changed_since_previous( @@ -643,10 +724,10 @@ public function schema_changes_before_migration(): bool REG_ID int(10) unsigned NOT NULL, PAY_ID int(10) unsigned NULL, RPY_amount decimal(12,3) NOT NULL DEFAULT '0.00', - PRIMARY KEY (RPY_ID), - KEY REG_ID (REG_ID), - KEY PAY_ID (PAY_ID)" + PRIMARY KEY (RPY_ID)" ); + $this->_get_table_manager()->addIndex('esp_registration_payment', 'REG_ID', 'REG_ID'); + $this->_get_table_manager()->addIndex('esp_registration_payment', 'PAY_ID', 'PAY_ID'); $this->_table_has_not_changed_since_previous( @@ -656,10 +737,10 @@ public function schema_changes_before_migration(): bool STA_abbrev varchar(24) NOT NULL, STA_name varchar(100) NOT NULL, STA_active tinyint(1) DEFAULT '1', - PRIMARY KEY (STA_ID), - KEY STA_abbrev (STA_abbrev), - KEY CNT_ISO (CNT_ISO)" + PRIMARY KEY (STA_ID)" ); + $this->_get_table_manager()->addIndex('esp_state', 'STA_abbrev', 'STA_abbrev'); + $this->_get_table_manager()->addIndex('esp_state', 'CNT_ISO', 'CNT_ISO'); $this->_table_has_not_changed_since_previous( @@ -670,9 +751,10 @@ public function schema_changes_before_migration(): bool STS_can_edit tinyint(1) NOT NULL DEFAULT 0, STS_desc tinytext, STS_open tinyint(1) NOT NULL DEFAULT 1, - UNIQUE KEY STS_ID_UNIQUE (STS_ID), - KEY STS_type (STS_type)" + PRIMARY KEY (STS_ID)" ); + $this->_get_table_manager()->addIndex('esp_status', 'STS_type', 'STS_type'); + $this->_get_table_manager()->dropIndex('esp_status', 'STS_ID_UNIQUE'); $this->_table_is_changed_in_this_version( @@ -700,10 +782,10 @@ public function schema_changes_before_migration(): bool TKT_parent int(10) unsigned DEFAULT '0', TKT_deleted tinyint(1) NOT NULL DEFAULT '0', TKT_visibility smallint(6) unsigned NOT NULL DEFAULT 100, - PRIMARY KEY (TKT_ID), - KEY TKT_start_date (TKT_start_date), - KEY TKT_end_date (TKT_end_date)" + PRIMARY KEY (TKT_ID)" ); + $this->_get_table_manager()->addIndex('esp_ticket', 'TKT_start_date', 'TKT_start_date'); + // $this->_get_table_manager()->addIndex('esp_ticket', 'TKT_end_date', 'TKT_end_date'); $this->_table_has_not_changed_since_previous( @@ -717,10 +799,17 @@ public function schema_changes_before_migration(): bool TXN_hash_salt varchar(250) DEFAULT NULL, PMD_ID int(11) DEFAULT NULL, TXN_reg_steps text, - PRIMARY KEY (TXN_ID), - KEY TXN_timestamp (TXN_timestamp)" + PRIMARY KEY (TXN_ID)" + ); + $this->_get_table_manager()->addIndex( + 'esp_transaction', + 'TXN_timestamp', + 'TXN_timestamp', + TableAnalysis::INDEX_TYPE_INDEX, + null, + true ); - $this->_get_table_manager()->dropIndex('esp_transaction', 'STS_ID'); + // $this->_get_table_manager()->dropIndex('esp_transaction', 'STS_ID'); $this->_table_has_not_changed_since_previous( @@ -740,11 +829,11 @@ public function schema_changes_before_migration(): bool VNU_virtual_url varchar(255) DEFAULT NULL, VNU_enable_for_gmap tinyint(1) DEFAULT 0, VNU_google_map_link varchar(255) DEFAULT NULL, - PRIMARY KEY (VNUM_ID), - KEY VNU_ID (VNU_ID), - KEY STA_ID (STA_ID), - KEY CNT_ISO (CNT_ISO)' + PRIMARY KEY (VNUM_ID)' ); + $this->_get_table_manager()->addIndex('esp_venue_meta', 'VNU_ID', 'VNU_ID'); + $this->_get_table_manager()->addIndex('esp_venue_meta', 'STA_ID', 'STA_ID'); + $this->_get_table_manager()->addIndex('esp_venue_meta', 'CNT_ISO', 'CNT_ISO'); $this->previous_dms->insert_default_data(); diff --git a/core/data_migration_scripts/EE_Data_Migration_Script_Stage_Table.core.php b/core/data_migration_scripts/EE_Data_Migration_Script_Stage_Table.core.php index 55ebdb0a60a..99faeafb439 100644 --- a/core/data_migration_scripts/EE_Data_Migration_Script_Stage_Table.core.php +++ b/core/data_migration_scripts/EE_Data_Migration_Script_Stage_Table.core.php @@ -28,7 +28,7 @@ abstract class EE_Data_Migration_Script_Stage_Table extends EE_Data_Migration_Sc * * @var string|null */ - protected ?string $_extra_where_sql; + protected ?string $_extra_where_sql = ''; /** diff --git a/core/db_classes/EE_Attendee.class.php b/core/db_classes/EE_Attendee.class.php index 46fcbd1a22d..2fdff103d88 100644 --- a/core/db_classes/EE_Attendee.class.php +++ b/core/db_classes/EE_Attendee.class.php @@ -674,11 +674,16 @@ public function save_and_clean_billing_info_for_payment_method( return false; } $billing_form->clean_sensitive_data(); - return update_post_meta( - $this->ID(), - $this->get_billing_info_postmeta_name($payment_method), - $billing_form->input_values(true) - ); + $postmeta_name = $this->get_billing_info_postmeta_name($payment_method); + $saved_values = get_post_meta($this->ID(), $postmeta_name); + $input_values = $billing_form->input_values(true); + // Merge the values in case some fields were already saved somewhere. + if ($saved_values && is_array($saved_values)) { + // Need a one dimensional array. + $saved_values = array_merge(...$saved_values); + $input_values = array_merge($saved_values, $input_values); + } + return update_post_meta($this->ID(), $postmeta_name, $input_values); } diff --git a/core/db_classes/EE_Line_Item.class.php b/core/db_classes/EE_Line_Item.class.php index e637fc74b36..4e9dc8b0b09 100644 --- a/core/db_classes/EE_Line_Item.class.php +++ b/core/db_classes/EE_Line_Item.class.php @@ -213,7 +213,7 @@ public function set_name(string $name) */ public function desc(): string { - return $this->get('LIN_desc'); + return (string) $this->get('LIN_desc'); } diff --git a/core/db_classes/EE_Question_Form_Input.class.php b/core/db_classes/EE_Question_Form_Input.class.php index 2879f451775..667749f8623 100644 --- a/core/db_classes/EE_Question_Form_Input.class.php +++ b/core/db_classes/EE_Question_Form_Input.class.php @@ -150,15 +150,17 @@ private function _set_input_name($qstn_id) */ public function get(string $property = '') { - if (! empty($property)) { - if (EEM_Question::instance()->has_field($property)) { - return $this->_QST->get($property); - } elseif (EEM_Answer::instance()->has_field($property)) { - return $this->_ANS->get($property); - // } elseif ($this->_question_form_input_property_exists($property)) { - } elseif (property_exists($this, $property)) { - return $this->{$property}; - } + if (empty($property)) { + return null; + } + if (EEM_Question::instance()->has_field($property)) { + return $this->_QST->get($property); + } + if (EEM_Answer::instance()->has_field($property)) { + return $this->_ANS->get($property); + } + if (property_exists($this, $property)) { + return $this->{$property}; } return null; } @@ -175,14 +177,17 @@ public function get(string $property = '') */ public function set(string $property = '', $value = null) { - if (! empty($property)) { - if (EEM_Question::instance()->has_field($property)) { - $this->_QST->set($property, $value); - } elseif (EEM_Answer::instance()->has_field($property)) { - $this->_ANS->set($property, $value); - } elseif (property_exists($this, $property)) { - $this->{$property} = $value; - } + if (empty($property)) { + return; + } + if (EEM_Question::instance()->has_field($property)) { + $this->_QST->set($property, $value); + } + if (EEM_Answer::instance()->has_field($property)) { + $this->_ANS->set($property, $value); + } + if (property_exists($this, $property)) { + $this->{$property} = $value; } } diff --git a/core/db_classes/EE_Question_Option.class.php b/core/db_classes/EE_Question_Option.class.php index 17681ea8b2b..cd3c66495d4 100644 --- a/core/db_classes/EE_Question_Option.class.php +++ b/core/db_classes/EE_Question_Option.class.php @@ -24,7 +24,7 @@ class EE_Question_Option extends EE_Soft_Delete_Base_Class implements EEI_Duplic * used.) * @param array $date_formats incoming date_formats in an array where the first value is the * date_format and the second value is the time format - * @return EE_Attendee + * @return EE_Question_Option */ public static function new_instance($props_n_values = [], $timezone = '', $date_formats = []) { @@ -37,7 +37,7 @@ public static function new_instance($props_n_values = [], $timezone = '', $date_ * @param array $props_n_values incoming values from the database * @param string $timezone incoming timezone as set by the model. If not set the timezone for * the website will be used. - * @return EE_Attendee + * @return EE_Question_Option */ public static function new_instance_from_db($props_n_values = [], $timezone = '') { diff --git a/core/db_classes/EE_Taxes.class.php b/core/db_classes/EE_Taxes.class.php index 6c0b437a13f..19348a3ed12 100644 --- a/core/db_classes/EE_Taxes.class.php +++ b/core/db_classes/EE_Taxes.class.php @@ -16,14 +16,14 @@ class EE_Taxes extends EE_Base * * @var array */ - private static $_subtotal = []; + private static array $_subtotal = []; /** * This holds an array of EE_Price objects that are of PRT_ID == 4 (tax price types) * * @var EE_Price[] */ - private static $_default_taxes = []; + private static array $_default_taxes = []; /** @@ -36,13 +36,13 @@ class EE_Taxes extends EE_Base * @throws EE_Error * @throws ReflectionException */ - public static function get_total_taxes_for_admin(EE_Ticket $ticket) + public static function get_total_taxes_for_admin(EE_Ticket $ticket): float { - $tax = 0; + $tax = 0; $total_tax = 0; // This first checks to see if the given ticket is taxable. if (! $ticket->taxable()) { - return $tax; + return (float) $tax; } // get subtotal (notice we're only retrieving a subtotal if there isn't one given) $subtotal = EE_Taxes::get_subtotal_for_admin($ticket); @@ -53,7 +53,7 @@ public static function get_total_taxes_for_admin(EE_Ticket $ticket) // assuming taxes are not cumulative $total_tax += $subtotal * $tax->amount() / 100; } - return $total_tax; + return (float) $total_tax; } @@ -65,13 +65,13 @@ public static function get_total_taxes_for_admin(EE_Ticket $ticket) * @throws ReflectionException * eg 20 for %20 tax (NOT 0.20, which */ - public static function get_total_taxes_percentage() + public static function get_total_taxes_percentage(): float { $total_tax_percent = 0; foreach (EE_Taxes::get_taxes_for_admin() as $tax_price) { $total_tax_percent += $tax_price->get('PRC_amount'); } - return $total_tax_percent; + return (float) $total_tax_percent; } @@ -81,7 +81,7 @@ public static function get_total_taxes_percentage() * @throws EE_Error * @throws ReflectionException */ - public static function get_subtotal_for_admin(EE_Ticket $ticket) + public static function get_subtotal_for_admin(EE_Ticket $ticket): float { $TKT_ID = $ticket->ID(); return EE_Taxes::$_subtotal[ $TKT_ID ] ?? EE_Taxes::_get_subtotal_for_admin($ticket); @@ -103,7 +103,7 @@ private static function _get_subtotal_for_admin(EE_Ticket $ticket) $prices = $ticket->get_many_related( 'Price', [ - 0 => [ + 0 => [ 'Price_Type.PBT_ID' => ['!=', EEM_Price_Type::base_type_tax], ], 'default_where_conditions' => 'none', @@ -131,8 +131,8 @@ private static function _get_subtotal_for_admin(EE_Ticket $ticket) } } } - $TKT_ID = $ticket->ID(); - EE_Taxes::$_subtotal[ $TKT_ID ] = $subtotal; + $TKT_ID = $ticket->ID(); + EE_Taxes::$_subtotal[ $TKT_ID ] = (float) $subtotal; return $subtotal; } @@ -142,12 +142,13 @@ private static function _get_subtotal_for_admin(EE_Ticket $ticket) * * @return EE_Price[] EE_Price objects that have PRT_ID == 4 * @throws EE_Error + * @throws ReflectionException */ public static function get_taxes_for_admin(): array { if (empty(EE_Taxes::$_default_taxes)) { /** @var EEM_Price $price_model */ - $price_model = LoaderFactory::getLoader()->getShared('EEM_Price'); + $price_model = LoaderFactory::getLoader()->getShared('EEM_Price'); EE_Taxes::$_default_taxes = $price_model->get_all( [['PRC_is_default' => 1, 'Price_Type.PBT_ID' => 4]] ); diff --git a/core/db_classes/EE_Ticket.class.php b/core/db_classes/EE_Ticket.class.php index 74997f52f24..078b466f456 100644 --- a/core/db_classes/EE_Ticket.class.php +++ b/core/db_classes/EE_Ticket.class.php @@ -645,12 +645,19 @@ public function is_free() * @throws EE_Error * @throws ReflectionException */ - public function get_ticket_total_with_taxes($no_cache = false) + public function get_ticket_total_with_taxes(bool $no_cache = false): float { if ($this->_ticket_total_with_taxes === null || $no_cache) { - $this->_ticket_total_with_taxes = $this->usesGlobalTaxes() - ? $this->get_ticket_subtotal() + $this->get_ticket_taxes_total_for_admin() - : $this->ticket_price(); + $this->_ticket_total_with_taxes = $this->get_ticket_subtotal(); + // add taxes + if ($this->usesGlobalTaxes()) { + $this->_ticket_total_with_taxes += $this->get_ticket_taxes_total_for_admin(); + } else { + $subtotal = $this->_ticket_total_with_taxes; + foreach ($this->tax_price_modifiers() as $tax) { + $this->_ticket_total_with_taxes += $subtotal * $tax->amount() / 100; + } + } } return (float) $this->_ticket_total_with_taxes; } diff --git a/core/db_models/EEM_Line_Item.model.php b/core/db_models/EEM_Line_Item.model.php index 976944b90ea..3897a64fbc0 100644 --- a/core/db_models/EEM_Line_Item.model.php +++ b/core/db_models/EEM_Line_Item.model.php @@ -485,6 +485,33 @@ public function get_existing_promotion_line_item(EE_Line_Item $parent_line_item, } + /** + * searches the cart for existing line items for the specified transaction and promotion + * + * @param int $TXN_ID + * @param string $promo_code + * @return EE_Base_Class|EE_Line_Item|EE_Soft_Delete_Base_Class|null + * @throws EE_Error + * @throws InvalidArgumentException + * @throws InvalidDataTypeException + * @throws InvalidInterfaceException + * @throws ReflectionException + * @since 1.0.0 + */ + public function getExistingPromotionLineItemForTransactionByCode(int $TXN_ID, string $promo_code) + { + return $this->get_one( + [ + [ + 'TXN_ID' => $TXN_ID, + 'LIN_name' => $promo_code, + 'OBJ_type' => EEM_Line_Item::OBJ_TYPE_PROMOTION, + ], + ] + ); + } + + /** * get_all_promotion_line_items * searches the cart for any and all existing promotion line items diff --git a/core/domain/services/admin/events/editor/ui/DuplicateEventButton.php b/core/domain/services/admin/events/editor/ui/DuplicateEventButton.php index d5590ae0e95..7d0b7b1faa9 100644 --- a/core/domain/services/admin/events/editor/ui/DuplicateEventButton.php +++ b/core/domain/services/admin/events/editor/ui/DuplicateEventButton.php @@ -12,38 +12,34 @@ * @author Hossein Rafiei * @since 5.0.0.p */ -class DuplicateEventButton +class DuplicateEventButton extends PermalinkHtmlHook { - public static function addButton( - string $return, - int $id, - ?string $new_title, - ?string $new_slug - ): string { + public static function addButton(string $html, int $post_id): string + { // make sure this is only when editing - if (empty($id)) { - return $return; + if (empty($post_id)) { + return $html; } - $post = get_post($id); + $post = get_post($post_id); // make sure this is EE event if (! $post || $post->post_type !== 'espresso_events') { - return $return; + return $html; } - $href = EEH_URL::add_query_args_and_nonce( - ['action' => 'duplicate_event', 'EVT_ID' => $id], + $href = EEH_URL::add_query_args_and_nonce( + ['action' => 'duplicate_event', 'EVT_ID' => $post_id], admin_url('admin.php?page=espresso_events') ); - $title = esc_attr__('Duplicate', 'event_espresso'); - $return .= " - "; } return $html; diff --git a/core/domain/services/admin/events/editor/ui/PermalinkHtmlHook.php b/core/domain/services/admin/events/editor/ui/PermalinkHtmlHook.php new file mode 100644 index 00000000000..78c4ee3b52c --- /dev/null +++ b/core/domain/services/admin/events/editor/ui/PermalinkHtmlHook.php @@ -0,0 +1,14 @@ + "; } - return $return; + return $html; } } diff --git a/core/domain/services/admin/events/editor/ui/TicketSelectorShortcodeButton.php b/core/domain/services/admin/events/editor/ui/TicketSelectorShortcodeButton.php index ba86450efea..486e68f77f2 100644 --- a/core/domain/services/admin/events/editor/ui/TicketSelectorShortcodeButton.php +++ b/core/domain/services/admin/events/editor/ui/TicketSelectorShortcodeButton.php @@ -10,27 +10,24 @@ * @author Hossein Rafiei * @since 5.0.0.p */ -class TicketSelectorShortcodeButton +class TicketSelectorShortcodeButton extends PermalinkHtmlHook { - public static function addButton( - string $return, - int $id, - ?string $new_title, - ?string $new_slug - ): string { + public static function addButton(string $html, int $post_id): string + { // make sure this is only when editing - if (empty($id)) { - return $return; + if (empty($post_id)) { + return $html; } - $post = get_post($id); + $post = get_post($post_id); // make sure this is EE event if (! $post || $post->post_type !== 'espresso_events') { - return $return; + return $html; } - $onclick = 'prompt("Ticket Selector Shortcode:", jQuery("#espresso-ticket-selector-shortlink").val()); return false;'; - $shortcode = esc_attr("[ESPRESSO_TICKET_SELECTOR event_id='$id']"); + $onclick = + 'prompt("Ticket Selector Shortcode:", jQuery("#espresso-ticket-selector-shortlink").val()); return false;'; + $shortcode = esc_attr("[ESPRESSO_TICKET_SELECTOR event_id='$post_id']"); $title = esc_html__('Ticket Selector Shortcode', 'event_espresso'); - $return .= " + $html .= " $title - "; - $return .= ""; - return $return; + + "; + return $html; } } diff --git a/core/domain/services/admin/registrations/list_table/csv_reports/RegistrationsCsvReportParams.php b/core/domain/services/admin/registrations/list_table/csv_reports/RegistrationsCsvReportParams.php index 3a41d3b44d3..f2eb5b60ce7 100644 --- a/core/domain/services/admin/registrations/list_table/csv_reports/RegistrationsCsvReportParams.php +++ b/core/domain/services/admin/registrations/list_table/csv_reports/RegistrationsCsvReportParams.php @@ -21,11 +21,11 @@ class RegistrationsCsvReportParams * @return array */ public static function getRequestParams( - $return_url, - $request_params = [], - $EVT_ID = 0, - $DTT_ID = 0 - ) { + string $return_url, + array $request_params = [], + int $EVT_ID = 0, + int $DTT_ID = 0 + ): array { if ( ! EE_Capabilities::instance()->current_user_can( 'ee_read_registrations', diff --git a/core/domain/services/admin/registrations/list_table/page_header/AttendeeFilterHeader.php b/core/domain/services/admin/registrations/list_table/page_header/AttendeeFilterHeader.php index d44a815f35b..0bda197cb0c 100644 --- a/core/domain/services/admin/registrations/list_table/page_header/AttendeeFilterHeader.php +++ b/core/domain/services/admin/registrations/list_table/page_header/AttendeeFilterHeader.php @@ -56,7 +56,7 @@ public function getHeaderText($text = '') '%1$s Viewing registrations for %2$s%3$s', 'event_espresso' ), - '

', + '

', ''; + $text .= ''; $text .= ''; $text .= $datetime->name(); $text .= ' ( ' . $datetime->start_date() . ' )'; diff --git a/core/domain/services/admin/registrations/list_table/page_header/EventFilterHeader.php b/core/domain/services/admin/registrations/list_table/page_header/EventFilterHeader.php index f0679a366ff..4f7147fb7ed 100644 --- a/core/domain/services/admin/registrations/list_table/page_header/EventFilterHeader.php +++ b/core/domain/services/admin/registrations/list_table/page_header/EventFilterHeader.php @@ -6,6 +6,7 @@ use EE_Error; use EE_Event; use EEM_Event; +use EEM_Status; use EventEspresso\core\exceptions\InvalidDataTypeException; use EventEspresso\core\exceptions\InvalidInterfaceException; use EventEspresso\core\services\admin\AdminPageHeaderDecorator; @@ -56,14 +57,24 @@ public function getHeaderText($text = '') { $EVT_ID = $this->request->getRequestParam('EVT_ID'); $EVT_ID = $this->request->getRequestParam('event_id', $EVT_ID, 'int'); + $reg_status_code = $this->request->getRequestParam('_reg_status', ''); + $reg_statuses = $reg_status_code + ? EEM_Status::instance()->localized_status( + [$reg_status_code => 'APPROVED'], + false, + 'lowercase' + ) + : []; + $reg_status = $reg_statuses[ $reg_status_code ] ?? ''; if ($EVT_ID) { $event = $this->event_model->get_one_by_ID($EVT_ID); if ($event instanceof EE_Event) { $text .= sprintf( /* translators: %s:

%s: Event Name %s:

*/ // phpcs:ignore WordPress.WP.I18n.UnorderedPlaceholdersText - esc_html__('%s Viewing registrations for the event: %s%s', 'event_espresso'), - '

', + esc_html__('%s Viewing%s registrations for the event: %s%s', 'event_espresso'), + '

', + $reg_status ? " $reg_status" : '', ' '; + $text = '

'; $text .= esc_html__('Viewing registrations for ticket:', 'event_espresso'); } $text .= '    '; - $text .= ''; + $text .= ''; $text .= ''; $text .= $ticket_details . '

'; } diff --git a/core/domain/services/database/MaintenanceStatus.php b/core/domain/services/database/MaintenanceStatus.php index a106bd6e5f5..e4d2e6d634c 100644 --- a/core/domain/services/database/MaintenanceStatus.php +++ b/core/domain/services/database/MaintenanceStatus.php @@ -28,26 +28,56 @@ class MaintenanceStatus private static string $status = MaintenanceStatus::DISABLED; + /** + * returns true if maintenance mode is enabled for the entire site (admin & frontend) + * + * @return bool + */ public static function isFullSite(): bool { return MaintenanceStatus::$status === MaintenanceStatus::FULL_SITE; } + + /** + * returns true if maintenance mode is NOT enabled for the entire site (admin & frontend) + * PLZ NOTE: this does not mean that maintenance mode is NOT enabled for the frontend only + * + * @return bool + */ public static function isNotFullSite(): bool { return MaintenanceStatus::$status !== MaintenanceStatus::FULL_SITE; } + + /** + * returns true if maintenance mode is enabled for the site's frontend only + * + * @return bool + */ public static function isPublicOnly(): bool { return MaintenanceStatus::$status === MaintenanceStatus::PUBLIC_ONLY; } + + /** + * returns true if maintenance mode is NOT enabled in any way + * + * @return bool + */ public static function isDisabled(): bool { return MaintenanceStatus::$status === MaintenanceStatus::DISABLED; } + + /** + * returns true if maintenance mode is enabled for the site in some way (admin and/or frontend) + * + * @return bool + */ public static function isNotDisabled(): bool { return MaintenanceStatus::$status !== MaintenanceStatus::DISABLED; diff --git a/core/domain/services/validation/email/strategies/Basic.php b/core/domain/services/validation/email/strategies/Basic.php index 4ee827e8a33..423f853be7f 100644 --- a/core/domain/services/validation/email/strategies/Basic.php +++ b/core/domain/services/validation/email/strategies/Basic.php @@ -21,12 +21,18 @@ class Basic implements EmailValidatorInterface */ public function validate(string $email_address): bool { - if (! preg_match('/^.+@\S+$/', (string) $email_address)) { + if (! preg_match('/^.+@\S+$/', $email_address)) { // email not in correct {string}@{string} format throw new EmailValidationException( esc_html__('Email does not have the required @ sign.', 'event_espresso') ); } + if (substr_count($email_address, '@') > 1) { + // more than one email address? + throw new EmailValidationException( + esc_html__('Only one email address allowed (multiple @ sign detected).', 'event_espresso') + ); + } $atIndex = $this->getAtIndex($email_address); $local = $this->getLocalPartOfEmail($email_address, $atIndex); $localLen = strlen($local); diff --git a/core/helpers/EEH_Export.helper.php b/core/helpers/EEH_Export.helper.php index 39fb89bda3a..f8af849e543 100644 --- a/core/helpers/EEH_Export.helper.php +++ b/core/helpers/EEH_Export.helper.php @@ -123,8 +123,9 @@ public static function get_csv_row(array $row, $delimiter = ',', $enclosure = '" continue; } - $output[] = preg_match("/(?:${delimiter_esc}|${enclosure_esc}|\s)/", $field_value) ? - ( $enclosure . str_replace($enclosure, $enclosure . $enclosure, $field_value) . $enclosure ) : $field_value; + $output[] = $field_value && preg_match("/(?:${delimiter_esc}|${enclosure_esc}|\s)/", $field_value) + ? ( $enclosure . str_replace($enclosure, $enclosure . $enclosure, $field_value) . $enclosure ) + : $field_value; } return implode($delimiter, $output) . PHP_EOL; diff --git a/core/helpers/EEH_Form_Fields.helper.php b/core/helpers/EEH_Form_Fields.helper.php index a4b0539cbb3..fd13751b2ff 100644 --- a/core/helpers/EEH_Form_Fields.helper.php +++ b/core/helpers/EEH_Form_Fields.helper.php @@ -841,38 +841,36 @@ public static function generate_form_input(EE_Question_Form_Input $QFI) // we also need to verify - $display_text = $QFI->get('QST_display_text'); - $input_name = $QFI->get('QST_input_name'); + $display_text = (string) $QFI->get('QST_display_text'); + $input_name = (string) $QFI->get('QST_input_name'); $answer = $request->getRequestParam($input_name, $QFI->get('ANS_value')); - $input_id = $QFI->get('QST_input_id'); - $input_class = $QFI->get('QST_input_class'); + $input_id = (string) $QFI->get('QST_input_id'); + $input_class = (string) $QFI->get('QST_input_class'); // $disabled = $QFI->get('QST_disabled') ? ' disabled="disabled"' : ''; - $disabled = $QFI->get('QST_disabled'); + $disabled = (bool) $QFI->get('QST_disabled'); $required_label = apply_filters(' FHEE__EEH_Form_Fields__generate_form_input__required_label', '*'); - $QST_required = $QFI->get('QST_required'); - $required = - $QST_required - ? ['label' => $required_label, 'class' => 'required needs-value', 'title' => $QST_required] - : []; + $QST_required = (bool) $QFI->get('QST_required'); + $required = $QST_required + ? ['label' => $required_label, 'class' => 'required needs-value', 'title' => $QST_required] + : []; $use_html_entities = $QFI->get_meta('htmlentities'); - $required_text = - $QFI->get('QST_required_text') != '' - ? $QFI->get('QST_required_text') - : esc_html__('This field is required', 'event_espresso'); + $required_text = (string) $QFI->get('QST_required_text') !== '' + ? (string) $QFI->get('QST_required_text') + : esc_html__('This field is required', 'event_espresso'); $required_text = $QST_required ? "\n\t\t\t" . '' : ''; - $label_class = $QFI->get('label_class'); + $label_class = (string) $QFI->get('label_class'); $label_class = $label_class ? "{$label_class} espresso-form-input-lbl" : 'espresso-form-input-lbl'; $QST_options = $QFI->options(true, $answer); $options = is_array($QST_options) ? self::prep_answer_options($QST_options) : []; - $system_ID = $QFI->get('QST_system'); - $label_b4 = $QFI->get_meta('label_b4'); - $use_desc_4_label = $QFI->get_meta('use_desc_4_label'); - $add_mobile_label = $QFI->get_meta('add_mobile_label'); + $system_ID = (string) $QFI->get('QST_system'); + $label_b4 = (bool) $QFI->get_meta('label_b4'); + $use_desc_4_label = (bool) $QFI->get_meta('use_desc_4_label'); + $add_mobile_label = (bool) $QFI->get_meta('add_mobile_label'); switch ($QFI->get('QST_type')) { @@ -1330,11 +1328,11 @@ private static function _generate_select_option( /** * generates HTML for form radio button inputs * - * @param bool|string $question label content - * @param string $answer form input value attribute + * @param string $question label content + * @param string|int $answer form input value attribute * @param array|bool $options array of answer options where array key = option value and array value = option * display text - * @param bool|string $name form input name attribute + * @param string $name form input name attribute * @param string $id form input css id attribute * @param string $class form input css class attribute * @param array|bool $required 'label', 'class', and 'msg' - array of values for required "label" content, css @@ -1342,28 +1340,28 @@ private static function _generate_select_option( * @param string $required_text * @param string $label_class css class attribute for the label * @param bool|string $disabled disabled="disabled" or null - * @param bool $system_ID + * @param string $system_ID * @param bool $use_html_entities * @param bool $label_b4 * @param bool $use_desc_4_label * @return string HTML */ public static function radio( - $question = false, + string $question = '', $answer = null, $options = false, - $name = false, - $id = '', - $class = '', + string $name = '', + string $id = '', + string $class = '', $required = false, - $required_text = '', - $label_class = '', - $disabled = false, - $system_ID = false, - $use_html_entities = true, - $label_b4 = false, - $use_desc_4_label = false, - $add_mobile_label = false + string $required_text = '', + string $label_class = '', + bool $disabled = false, + string $system_ID = '', + bool $use_html_entities = true, + bool $label_b4 = false, + bool $use_desc_4_label = false, + bool $add_mobile_label = false ) { // need these if (! $question || ! $name || ! $options || empty($options) || ! is_array($options)) { @@ -1404,6 +1402,7 @@ public static function radio( : self::get_label_size_class($OPT->value()); $desc = $OPT->desc();// no self::prep_answer $answer = is_numeric($value) && empty($answer) ? 0 : $answer; + $value = is_numeric($answer) && empty($value) ? 0 : $value; $checked = (string) $value == (string) $answer ? ' checked' : ''; $opt = '-' . sanitize_key($value); @@ -1709,7 +1708,7 @@ public static function prep_answer_options($QSOs = []) /** * prep_option_value * - * @param string $option_value + * @param string|int $option_value * @return string */ public static function prep_option_value($option_value) diff --git a/core/helpers/EEH_Template.helper.php b/core/helpers/EEH_Template.helper.php index ff511df1954..30ad6bfbcb2 100644 --- a/core/helpers/EEH_Template.helper.php +++ b/core/helpers/EEH_Template.helper.php @@ -185,10 +185,10 @@ public static function get_template_part( */ public static function locate_template( $templates = [], - $template_args = [], - $load = true, - $return_string = true, - $check_if_custom = false + array $template_args = [], + bool $load = true, + bool $return_string = true, + bool $check_if_custom = false ) { // first use WP locate_template to check for template in the current theme folder $template_path = locate_template($templates); @@ -513,7 +513,7 @@ public static function format_currency( // add currency code ? $amount_formatted = $display_code - ? $amount_formatted . ' (' . $mny->code . ')' + ? $amount_formatted . ' ' . $mny->code . '' : $amount_formatted; } // filter results diff --git a/core/libraries/form_sections/base/EE_Form_Section_Proper.form.php b/core/libraries/form_sections/base/EE_Form_Section_Proper.form.php index c82aa48c314..e116757240c 100644 --- a/core/libraries/form_sections/base/EE_Form_Section_Proper.form.php +++ b/core/libraries/form_sections/base/EE_Form_Section_Proper.form.php @@ -389,7 +389,7 @@ protected function get_submitted_form_data_from_session() public static function flush_submitted_form_data_from_session() { return EE_Registry::instance()->SSN->reset_data( - array(EE_Form_Section_Proper::SUBMITTED_FORM_DATA_SSN_KEY) + [EE_Form_Section_Proper::SUBMITTED_FORM_DATA_SSN_KEY] ); } diff --git a/core/libraries/messages/EE_messenger.lib.php b/core/libraries/messages/EE_messenger.lib.php index 8b3922bd8ef..b4e798e6a9e 100644 --- a/core/libraries/messages/EE_messenger.lib.php +++ b/core/libraries/messages/EE_messenger.lib.php @@ -582,7 +582,7 @@ protected function _get_admin_content_events_edit($message_types, $extra) $select_values, $default_value, 'data-messenger="' . $this->name . '" data-messagetype="' . $mt_slug . '"', - 'message-template-selector' + 'message-template-selector ee-input-size--small' ); $new_template_name = sprintf( esc_html__('Custom %1$s', 'event_espresso'), @@ -598,7 +598,7 @@ protected function _get_admin_content_events_edit($message_types, $extra) data-grpid="' . $default_value . '" target="_blank" href="' . $create_url . '" - class="button button--secondary create-mtpg-button" + class="button button--secondary button--small create-mtpg-button" > ' . esc_html__('Create New Custom', 'event_espresso') . '
'; @@ -618,7 +618,7 @@ class="button button--secondary create-mtpg-button" data-grpid="' . $default_value . '" target="_blank" href="' . $edit_url . '" - class="button button--secondary edit-mtpg-button" + class="button button--secondary button--small edit-mtpg-button" > ' . esc_html__('Edit', 'event_espresso') . ' ' diff --git a/core/libraries/payment_methods/EE_Gateway.lib.php b/core/libraries/payment_methods/EE_Gateway.lib.php index 5a4b00b3cf0..7359a0770e4 100644 --- a/core/libraries/payment_methods/EE_Gateway.lib.php +++ b/core/libraries/payment_methods/EE_Gateway.lib.php @@ -42,7 +42,7 @@ abstract class EE_Gateway * * @var boolean */ - protected $_supports_sending_refunds = false; + protected bool $_supports_sending_refunds = false; /** * Whether this gateway can support RECEIVING a refund request from the payment @@ -50,76 +50,70 @@ abstract class EE_Gateway * * @var boolean */ - protected $_supports_receiving_refunds = false; + protected bool $_supports_receiving_refunds = false; /** * Model for querying for existing payments * - * @var EEMI_Payment + * @var EEMI_Payment|null */ - protected $_pay_model; + protected ?EEMI_Payment $_pay_model = null; /** * Model used for adding to the payments log * - * @var EEM_Change_Log + * @var EEM_Change_Log|null */ - protected $_pay_log; + protected ?EEM_Change_Log $_pay_log = null; /** * Used for formatting some input to gateways * - * @var EEH_Template + * @var EEH_Template|null */ - protected $_template; + protected ?EEH_Template $_template = null; /** * Concrete class that implements EEHI_Money, used by most gateways * - * @var EEH_Money + * @var EEH_Money|null */ - protected $_money; + protected ?EEH_Money $_money = null; /** * Concrete class that implements EEH_Line_Item, used for manipulating the line item tree * - * @var EEH_Line_Item + * @var EEH_Line_Item|null */ - protected $_line_item; + protected ?EEH_Line_Item $_line_item = null; - /** - * @var GatewayDataFormatterInterface - */ - protected $_gateway_data_formatter; + protected ?GatewayDataFormatterInterface $_gateway_data_formatter = null; - /** - * @var FormatterInterface - */ - protected $_unsupported_character_remover; + protected ?FormatterInterface $_unsupported_character_remover = null; /** * The ID of the payment method using this gateway * * @var int */ - protected int $_ID; + protected int $_ID = 0; /** * @var $_debug_mode boolean whether to send requests to teh sandbox site or not */ - protected bool $_debug_mode; + protected bool $_debug_mode = false; /** * @var string $_name name to show for this payment method */ - protected string $_name; + protected string $_name = ''; /** * @var string name to show for this payment method to admin-type users */ - protected string $_admin_name; + protected string $_admin_name = ''; - protected array $settings; + protected array $settings = []; diff --git a/core/libraries/plugin_api/EE_Register_Addon.lib.php b/core/libraries/plugin_api/EE_Register_Addon.lib.php index 52b36c9d1de..53bb8936b3d 100644 --- a/core/libraries/plugin_api/EE_Register_Addon.lib.php +++ b/core/libraries/plugin_api/EE_Register_Addon.lib.php @@ -649,6 +649,7 @@ private static function _addon_is_compatible(string $addon_name, array $addon_se * * @param array $addon_settings * @return void + * @throws EE_Error */ private static function _setup_namespaces(array $addon_settings) { diff --git a/core/services/admin/AdminPageModalContainer.php b/core/services/admin/AdminPageModalContainer.php new file mode 100644 index 00000000000..3942b8ceea9 --- /dev/null +++ b/core/services/admin/AdminPageModalContainer.php @@ -0,0 +1,101 @@ +modal_ID = esc_attr($modal_ID); + $this->trigger_ID = esc_attr($trigger_ID); + $this->header = esc_html($header); + $this->content = wp_kses($content, AllowedTags::getWithFullTags()); + $this->footer = wp_kses($footer, AllowedTags::getWithFullTags()); + $this->modal_class = ! empty($modal_class) ? "$modal_class " : ''; + add_action('admin_print_footer_scripts', [$this, 'renderModal'], 998); + add_action('admin_print_footer_scripts', [$this, 'printJs'], 999); + } + + + public function renderModal() + { + echo " +
+
+
+ +

$this->header

+
+
+ $this->content +
+ +
+
+ "; + } + + + public function printJs() + { + ?> + + prefix or not * * @param string $table_name @@ -61,7 +67,7 @@ public function tableIsEmpty(string $table_name): bool /** - * Indicates whether or not the table exists. $table_name can optionally + * Indicates whether the table exists. $table_name can optionally * have the $wpdb->prefix on the beginning, or not. * * @param string $table_name @@ -71,9 +77,12 @@ public function tableIsEmpty(string $table_name): bool */ public function tableExists(string $table_name): bool { - global $wpdb, $EZSQL_ERROR; $table_name = $this->ensureTableNameHasPrefix($table_name); - // ignore if this causes an sql error + if (isset($this->known_tables[ $table_name ])) { + return true; + } + global $wpdb, $EZSQL_ERROR; + // ignore if this causes an SQL error $old_error = $wpdb->last_error; $old_suppress_errors = $wpdb->suppress_errors(); $old_show_errors_value = $wpdb->show_errors(false); @@ -101,19 +110,19 @@ public function tableExists(string $table_name): bool ) // in case not using mysql and error codes aren't reliable, just check for this error string ) { return false; - } else { - // log this because that's weird. Just use the normal PHP error log - error_log( - sprintf( - esc_html__( - 'Event Espresso error detected when checking if table existed: %1$s (it wasn\'t just that the table didn\'t exist either)', - 'event_espresso' - ), - $new_error - ) - ); } + // log this because that's weird. Just use the normal PHP error log + error_log( + sprintf( + esc_html__( + 'Event Espresso error detected when checking if table existed: %1$s (it wasn\'t just that the table didn\'t exist either)', + 'event_espresso' + ), + $new_error + ) + ); } + $this->known_tables[ $table_name ] = true; return true; } @@ -127,8 +136,27 @@ public function tableExists(string $table_name): bool public function showIndexes(string $table_name, string $index_name): array { global $wpdb; + if (! $this->tableExists($table_name)) { + return []; + } $table_name = $this->ensureTableNameHasPrefix($table_name); $index_exists_query = "SHOW INDEX FROM $table_name WHERE Key_name = '$index_name'"; return $wpdb->get_results($index_exists_query); } + + + /** + * @param string $table_name + * @param string $index_name + * @return bool + * @since $VID:$ + */ + public function indexExists(string $table_name, string $index_name): bool + { + global $wpdb; + $table_name = $this->ensureTableNameHasPrefix($table_name); + $index_exists_query = "SHOW INDEX FROM $table_name WHERE key_name = '$index_name'"; + // using get_var with the $index_exists_query returns the table's name + return $this->tableExists($table_name) && $wpdb->get_var($index_exists_query) === $table_name; + } } diff --git a/core/services/database/TableManager.php b/core/services/database/TableManager.php index 37f8721dfec..4f34d455f1d 100644 --- a/core/services/database/TableManager.php +++ b/core/services/database/TableManager.php @@ -165,13 +165,8 @@ public function dropIndex(string $table_name, string $index_name) return 0; } global $wpdb; - $table_name = $this->getTableAnalysis()->ensureTableNameHasPrefix($table_name); - $index_exists_query = "SHOW INDEX FROM $table_name WHERE key_name = '$index_name'"; - if ( - $this->getTableAnalysis()->tableExists($table_name) - && $wpdb->get_var($index_exists_query) - === $table_name // using get_var with the $index_exists_query returns the table's name - ) { + $table_name = $this->getTableAnalysis()->ensureTableNameHasPrefix($table_name); + if ($this->getTableAnalysis()->indexExists($table_name, $index_name)) { return $wpdb->query("ALTER TABLE $table_name DROP INDEX $index_name"); } return 0; @@ -246,7 +241,7 @@ public function createTable(string $table_name, string $create_sql, string $engi * @param string $index_name * @param string $column_name if none is provided, we assume the column name matches the index * (often true in EE) - * @param string|int $desired_index_size defaults to TableAnalysis::index_col_size, the max for utf8mb4. + * @param string|int $index_size defaults to TableAnalysis::index_col_size, the max for utf8mb4. * @return bool whether an index was dropped or not * @throws /EE_Error if table analysis object isn't defined */ @@ -254,7 +249,7 @@ public function dropIndexIfSizeNot( string $table_name, string $index_name, string $column_name = '', - $desired_index_size = TableAnalysis::INDEX_COLUMN_SIZE + $index_size = TableAnalysis::INDEX_COLUMN_SIZE ) { if ($column_name === '') { $column_name = $index_name; @@ -269,11 +264,49 @@ public function dropIndexIfSizeNot( foreach ($index_entries as $index_entry) { if ( $column_name === $index_entry->Column_name - && (string)$desired_index_size !== $index_entry->Sub_part + && (string) $index_size !== $index_entry->Sub_part ) { return $this->dropIndex($table_name, $index_name); } } return false; } + + + /** + * @param string $table_name + * @param string $index_name + * @param string $column_name + * @param string $index_type + * @param string|null $index_size + * @param bool $descending + * @throws EE_Error + */ + public function addIndex( + string $table_name, + string $index_name, + string $column_name, + string $index_type = TableAnalysis::INDEX_TYPE_INDEX, + ?string $index_size = null, + bool $descending = false + ) { + if (apply_filters('FHEE__EEH_Activation__add_index__short_circuit', false)) { + return; + } + global $wpdb; + $table_name = $this->getTableAnalysis()->ensureTableNameHasPrefix($table_name); + if (! $this->getTableAnalysis()->indexExists($table_name, $index_name)) { + // ensure index type is valid + $index_type = in_array($index_type, [TableAnalysis::INDEX_TYPE_INDEX, TableAnalysis::INDEX_TYPE_UNIQUE]) + ? $index_type + : TableAnalysis::INDEX_TYPE_INDEX; + // ensure index size does not exceed max allowed for utf8mb4 + $index_size = $index_size ? max($index_size, TableAnalysis::INDEX_COLUMN_SIZE) : null; + // if index size is set, then add it to the column name + $column_name = $index_size ? "$column_name($index_size)" : $column_name; + // add DESC to the column name for indexes that will benefit from that (like timestamps) + $column_name = $descending ? "$column_name DESC" : $column_name; + $wpdb->query("ALTER TABLE $table_name ADD $index_type $index_name ($column_name);"); + } + } } diff --git a/core/services/request/sanitizers/AllowedTags.php b/core/services/request/sanitizers/AllowedTags.php index 3539630b02d..8a9c10be6a4 100644 --- a/core/services/request/sanitizers/AllowedTags.php +++ b/core/services/request/sanitizers/AllowedTags.php @@ -12,87 +12,80 @@ */ class AllowedTags { - /** - * @var array[] - */ - private static $attributes = [ - 'accept-charset' => true, - 'action' => true, - 'alt' => true, - 'allow' => true, - 'allowfullscreen' => true, - 'align' => true, - 'aria-controls' => true, - 'aria-current' => true, - 'aria-describedby' => true, - 'aria-details' => true, - 'aria-expanded' => true, - 'aria-hidden' => true, - 'aria-label' => true, - 'aria-labelledby' => true, - 'aria-live' => true, - 'autocomplete' => true, - 'bgcolor' => true, - 'border' => true, - 'cellpadding' => true, - 'cellspacing' => true, - 'checked' => true, - 'class' => true, - 'cols' => true, - 'content' => true, - 'data-*' => true, - 'dir' => true, - 'disabled' => true, - 'enctype' => true, - 'extension' => true, - 'for' => true, - 'frameborder' => true, - 'height' => true, - 'href' => true, - 'id' => true, - 'itemprop' => true, - 'itemscope' => true, - 'itemtype' => true, - 'label' => true, - 'lang' => true, - 'leftmargin' => true, - 'marginheight' => true, - 'marginwidth' => true, - 'max' => true, - 'maxlength' => true, - 'media' => true, - 'method' => true, - 'min' => true, - 'multiple' => true, - 'name' => true, - 'novalidate' => true, - 'onclick' => true, - 'placeholder' => true, - 'property' => true, - 'readonly' => true, - 'rel' => true, - 'required' => true, - 'rows' => true, - 'selected' => true, - 'src' => true, - 'size' => true, - 'style' => true, - 'step' => true, - 'tabindex' => true, - 'target' => true, - 'title' => true, - 'topmargin' => true, - 'type' => true, - 'value' => true, - 'width' => true, - 'http-equiv' => true, + private static array $attributes = [ + 'accept-charset' => true, + 'action' => true, + 'alt' => true, + 'allow' => true, + 'allowfullscreen' => true, + 'align' => true, + 'aria-controls' => true, + 'aria-current' => true, + 'aria-describedby' => true, + 'aria-details' => true, + 'aria-expanded' => true, + 'aria-hidden' => true, + 'aria-label' => true, + 'aria-labelledby' => true, + 'aria-live' => true, + 'autocomplete' => true, + 'bgcolor' => true, + 'border' => true, + 'cellpadding' => true, + 'cellspacing' => true, + 'checked' => true, + 'class' => true, + 'cols' => true, + 'content' => true, + 'data-*' => true, + 'dir' => true, + 'disabled' => true, + 'enctype' => true, + 'extension' => true, + 'for' => true, + 'frameborder' => true, + 'height' => true, + 'href' => true, + 'id' => true, + 'itemprop' => true, + 'itemscope' => true, + 'itemtype' => true, + 'label' => true, + 'lang' => true, + 'leftmargin' => true, + 'marginheight' => true, + 'marginwidth' => true, + 'max' => true, + 'maxlength' => true, + 'media' => true, + 'method' => true, + 'min' => true, + 'multiple' => true, + 'name' => true, + 'novalidate' => true, + 'onclick' => true, + 'placeholder' => true, + 'property' => true, + 'readonly' => true, + 'rel' => true, + 'required' => true, + 'rows' => true, + 'selected' => true, + 'src' => true, + 'size' => true, + 'style' => true, + 'step' => true, + 'tabindex' => true, + 'target' => true, + 'title' => true, + 'topmargin' => true, + 'type' => true, + 'value' => true, + 'width' => true, + 'http-equiv' => true, ]; - - /** - * @var array - */ - private static $tags = [ + private static array $tags = [ 'a', 'abbr', 'b', @@ -122,34 +115,15 @@ class AllowedTags 'ul', ]; + private static array $allowed_tags = []; - /** - * @var array - */ - private static $allowed_tags; + private static array $allowed_with_embed_tags = []; + private static array $allowed_with_form_tags = []; - /** - * @var array - */ - private static $allowed_with_embed_tags; - + private static array $allowed_with_script_and_style_tags = []; - /** - * @var array - */ - private static $allowed_with_form_tags; - - - /** - * @var array - */ - private static $allowed_with_script_and_style_tags; - - /** - * @var array - */ - private static $allowed_with_full_tags; + private static array $allowed_with_full_tags = []; /** @@ -158,7 +132,7 @@ class AllowedTags private static function initializeAllowedTags() { $allowed_post_tags = wp_kses_allowed_html('post'); - $allowed_tags = []; + $allowed_tags = []; foreach (AllowedTags::$tags as $tag) { $allowed_tags[ $tag ] = AllowedTags::$attributes; } @@ -171,9 +145,9 @@ private static function initializeAllowedTags() */ private static function initializeWithEmbedTags() { - $all_tags = AllowedTags::getAllowedTags(); - $embed_tags = [ - 'iframe' => AllowedTags::$attributes + $all_tags = AllowedTags::getAllowedTags(); + $embed_tags = [ + 'iframe' => AllowedTags::$attributes, ]; AllowedTags::$allowed_with_embed_tags = array_merge_recursive($all_tags, $embed_tags); } @@ -184,18 +158,18 @@ private static function initializeWithEmbedTags() */ private static function initializeWithFormTags() { - $all_tags = AllowedTags::getAllowedTags(); - $form_tags = [ + $all_tags = AllowedTags::getAllowedTags(); + $form_tags = [ + 'button' => AllowedTags::$attributes, + 'fieldset' => AllowedTags::$attributes, 'form' => AllowedTags::$attributes, - 'label' => AllowedTags::$attributes, 'input' => AllowedTags::$attributes, - 'select' => AllowedTags::$attributes, - 'option' => AllowedTags::$attributes, + 'label' => AllowedTags::$attributes, 'optgroup' => AllowedTags::$attributes, - 'textarea' => AllowedTags::$attributes, - 'button' => AllowedTags::$attributes, - 'fieldset' => AllowedTags::$attributes, + 'option' => AllowedTags::$attributes, 'output' => AllowedTags::$attributes, + 'select' => AllowedTags::$attributes, + 'textarea' => AllowedTags::$attributes, ]; AllowedTags::$allowed_with_form_tags = array_merge_recursive($all_tags, $form_tags); } @@ -206,43 +180,69 @@ private static function initializeWithFormTags() */ private static function initializeWithScriptAndStyleTags() { - $all_tags = AllowedTags::getAllowedTags(); - $script_and_style_tags = [ - 'script' => AllowedTags::$attributes, - 'style' => AllowedTags::$attributes, + $all_tags = AllowedTags::getAllowedTags(); + $script_and_style_tags = [ 'link' => AllowedTags::$attributes, 'noscript' => AllowedTags::$attributes, + 'script' => AllowedTags::$attributes, + 'style' => AllowedTags::$attributes, ]; AllowedTags::$allowed_with_script_and_style_tags = array_merge_recursive($all_tags, $script_and_style_tags); } + /** * merges all head and body tags and attributes into the EE all tags */ private static function initializeWithFullTags() { - $all_tags = AllowedTags::getAllowedTags(); - $full_tags = [ - 'script' => AllowedTags::$attributes, - 'style' => AllowedTags::$attributes, - 'link' => AllowedTags::$attributes, - 'title' => AllowedTags::$attributes, - 'meta' => AllowedTags::$attributes, - 'iframe' => AllowedTags::$attributes, - 'form' => AllowedTags::$attributes, - 'label' => AllowedTags::$attributes, - 'input' => AllowedTags::$attributes, - 'select' => AllowedTags::$attributes, - 'option' => AllowedTags::$attributes, - 'optgroup' => AllowedTags::$attributes, - 'textarea' => AllowedTags::$attributes, - 'button' => AllowedTags::$attributes, - 'fieldset' => AllowedTags::$attributes, - 'output' => AllowedTags::$attributes, - 'noscript' => AllowedTags::$attributes, - 'html' => AllowedTags::$attributes, - 'body' => AllowedTags::$attributes, - 'head' => AllowedTags::$attributes, + $all_tags = AllowedTags::getAllowedTags(); + $full_tags = [ + 'body' => AllowedTags::$attributes, + 'button' => AllowedTags::$attributes, + 'circle' => [ + 'cx' => true, + 'cy' => true, + 'fill' => true, + 'r' => true, + ], + 'defs' => AllowedTags::$attributes, + 'fieldset' => AllowedTags::$attributes, + 'form' => AllowedTags::$attributes, + 'g' => AllowedTags::$attributes, + 'head' => AllowedTags::$attributes, + 'html' => AllowedTags::$attributes, + 'iframe' => AllowedTags::$attributes, + 'input' => AllowedTags::$attributes, + 'label' => AllowedTags::$attributes, + 'link' => AllowedTags::$attributes, + 'meta' => AllowedTags::$attributes, + 'noscript' => AllowedTags::$attributes, + 'optgroup' => AllowedTags::$attributes, + 'option' => AllowedTags::$attributes, + 'output' => AllowedTags::$attributes, + 'path' => [ + 'class' => true, + 'd' => true + ], + 'script' => AllowedTags::$attributes, + 'select' => AllowedTags::$attributes, + 'style' => AllowedTags::$attributes, + 'svg' => [ + 'aria-hidden' => true, + 'class' => true, + 'display' => true, + 'fill' => true, + 'focusable' => true, + 'height' => true, + 'stroke' => true, + 'stroke-width' => true, + 'viewBox' => true, + 'width' => true, + 'xmlns' => true, + ], + 'textarea' => AllowedTags::$attributes, + 'title' => AllowedTags::$attributes, ]; AllowedTags::$allowed_with_full_tags = array_merge_recursive($all_tags, $full_tags); } @@ -251,7 +251,7 @@ private static function initializeWithFullTags() /** * @return array[] */ - public static function getAllowedTags() + public static function getAllowedTags(): array { if (empty(AllowedTags::$allowed_tags)) { AllowedTags::initializeAllowedTags(); @@ -263,7 +263,7 @@ public static function getAllowedTags() /** * @return array[] */ - public static function getWithEmbedTags() + public static function getWithEmbedTags(): array { if (empty(AllowedTags::$allowed_with_embed_tags)) { AllowedTags::initializeWithEmbedTags(); @@ -275,7 +275,7 @@ public static function getWithEmbedTags() /** * @return array[] */ - public static function getWithFormTags() + public static function getWithFormTags(): array { if (empty(AllowedTags::$allowed_with_form_tags)) { AllowedTags::initializeWithFormTags(); @@ -287,7 +287,7 @@ public static function getWithFormTags() /** * @return array[] */ - public static function getWithScriptAndStyleTags() + public static function getWithScriptAndStyleTags(): array { if (empty(AllowedTags::$allowed_with_script_and_style_tags)) { AllowedTags::initializeWithScriptAndStyleTags(); @@ -299,7 +299,7 @@ public static function getWithScriptAndStyleTags() /** * @return array[] */ - public static function getWithFullTags() + public static function getWithFullTags(): array { if (empty(AllowedTags::$allowed_with_full_tags)) { AllowedTags::initializeWithFullTags(); diff --git a/core/services/shortcodes/EspressoShortcode.php b/core/services/shortcodes/EspressoShortcode.php index 2ec67cac31d..2263ec187a7 100644 --- a/core/services/shortcodes/EspressoShortcode.php +++ b/core/services/shortcodes/EspressoShortcode.php @@ -19,20 +19,10 @@ */ abstract class EspressoShortcode implements ShortcodeInterface { - /** - * @type string - */ public const CACHE_TRANSIENT_PREFIX = 'SC_'; - - /** - * @type string - */ public const SHORTCODE_PREFIX = 'ESPRESSO_'; - /** - * @var PostRelatedCacheManager $cache_manager - */ - private $cache_manager; + private PostRelatedCacheManager $cache_manager; /** * true if ShortcodeInterface::initializeShortcode() has been called @@ -40,7 +30,7 @@ abstract class EspressoShortcode implements ShortcodeInterface * * @var bool $initialized */ - private $initialized = false; + private bool $initialized = false; /** @@ -100,7 +90,6 @@ final public function processShortcodeCallback($attributes = array()): string */ private function shortcodeContent(array $attributes) { - $shortcode = $this; $post_ID = $this->currentPostID(); // something like "SC_EVENTS-123" $cache_ID = $this->shortcodeCacheID($post_ID); @@ -110,11 +99,11 @@ private function shortcodeContent(array $attributes) // serialized attributes wp_json_encode($attributes), // Closure for generating content if cache is expired - function () use ($shortcode, $attributes) { - if ($shortcode->initialized() === false) { - $shortcode->initializeShortcode(); + function () use ($attributes) { + if ($this->initialized() === false) { + $this->initializeShortcode(); } - return $shortcode->processShortcode($attributes); + return $this->processShortcode($attributes); }, // filterable cache expiration set by each shortcode apply_filters( @@ -234,11 +223,11 @@ private function sanitizeAttributes(array $attributes): array /** - * Returns whether or not this shortcode has been initialized + * Returns whether this shortcode has been initialized * * @return bool */ - public function initialized() + public function initialized(): bool { return $this->initialized; } diff --git a/core/templates/espresso-ajax-notices.template.php b/core/templates/espresso-ajax-notices.template.php index 79bfa9d7022..05a3b095cd3 100644 --- a/core/templates/espresso-ajax-notices.template.php +++ b/core/templates/espresso-ajax-notices.template.php @@ -1,25 +1,35 @@
diff --git a/core/templates/global_assets/css/espresso_default.css b/core/templates/global_assets/css/espresso_default.css index d83031445c0..ac75144e90a 100644 --- a/core/templates/global_assets/css/espresso_default.css +++ b/core/templates/global_assets/css/espresso_default.css @@ -11,26 +11,35 @@ :root { --ee-color-white: hsl(207, 0%, 100%); + --ee-color-may-as-well-be-white: hsl(207, 0%, 97.5%); --ee-color-almost-white: hsl(207, 0%, 95%); + --ee-color-white-cloud: hsl(207, 5%, 87.5%); + --ee-color-grey-cloud: hsl(207, 5%, 75%); --ee-color-off-white: hsl(207, 0%, 90%); - --ee-status-color-pink: hsl(340, 100%, 85%); - --ee-status-color-red: hsl(340, 60%, 55%); - --ee-status-color-orange: hsl(18, 70%, 50%); - --ee-status-color-gold: hsl(39, 98%, 50%); - --ee-status-color-yellow: hsl(50, 95%, 45%); - --ee-status-color-dark-green: hsl(95, 70%, 22.5%); - --ee-status-color-green: hsl(140, 85%, 35%); - --ee-status-color-green-high-contrast: hsl(140, 100%, 25%); - --ee-status-color-blue-green: hsl(176, 95%, 30%); - --ee-status-color-blue: hsl(203, 60%, 50%); - --ee-status-color-light-blue: hsl(203, 90%, 70%); - --ee-status-color-pale-blue: hsl(203, 50%, 95%); - --ee-status-color-violet: hsl(239, 35%, 60%); - --ee-status-color-purple: hsl(279, 35%, 50%); + --ee-status-color-pink: hsl(340, 100%, 75%); + --ee-status-color-hot-pink: hsl(342, 79%, 68%); + --ee-status-color-red: hsl(350, 95%, 65%); + --ee-status-color-orange: hsl(20, 100%, 65%); + --ee-status-color-gold: hsl(40, 100%, 55%); + --ee-status-color-yellow: hsl(50, 100%, 50%); + --ee-status-color-pale-yellow: hsl(50, 75%, 80%); + --ee-status-color-yellow-desat: hsl(50, 100%, 50%); + --ee-status-color-dark-green: hsl(95, 55%, 30%); + --ee-status-color-green: hsl(140, 90%, 40%); + --ee-status-color-dark-green-low-contrast: hsl(140, 90%, 50%); + --ee-status-color-green-high-contrast: hsl(140, 100%, 30%); + --ee-status-color-light-green: hsl(145, 40%, 50%); + --ee-status-color-blue-green: hsl(176, 100%, 35%); + --ee-status-color-blue: hsl(203, 65%, 55%); + --ee-status-color-light-blue: hsl(203, 95%, 75%); + --ee-status-color-pale-blue: hsl(203, 60%, 95%); + --ee-status-color-violet: hsl(239, 40%, 65%); + --ee-status-color-purple: hsl(279, 40%, 55%); + --ee-status-color-light-purple: hsl(279, 40%, 75%); --ee-status-color-pale-grey: hsl(219, 2%, 75%); --ee-status-color-light-grey: hsl(219, 2%, 55%); --ee-status-color-grey: hsl(225, 2%, 37.5%); - --ee-status-color-dark-grey: hsl(225, 2%, 20%); + --ee-status-color-dark-grey: hsl(225, 2%, 25%); --ee-status-color-charcoal: hsl(225, 0%, 15%); } @@ -744,23 +753,23 @@ input.ee-register-button { .espresso-notices, .espresso-ajax-notices { - box-sizing: border-box; - position: relative; - width: 74.5%; - min-width: 200px; - max-width: 640px; - height: auto; - padding: .75em 2.5%; - margin: 0 auto 2em; - z-index: 999; - background: #fff; - border : 4px solid; - font-size: 1em; - color: #666; - line-height: 1.6em; - text-align: center; - font-weight: bold; - box-shadow: 4px 10px 15px -3px rgba(0,0,0,.3), 0 1px 3px -1px rgba(0,0,0,.6), -3px -2px 10px rgba(0,0,0,.1); + background: var(--ee-color-white); + border: 4px solid; + box-shadow: 4px 10px 15px -3px rgba(0,0,0,.3), 0 9px 9px -3px rgba(0,0,0,.6), -3px -2px 10px rgba(0,0,0,.15); + box-sizing: border-box; + color: var(--ee-status-color-dark-grey); + font-size: 1em; + font-weight: bold; + height: auto; + line-height: 1.6em; + margin: 0 auto 2em; + max-width: 640px; + min-width: 300px; + padding: 1em 1.25em; + position: relative; + text-align: center; + width: 74.5%; + z-index: 999; } .espresso-notices p, .espresso-ajax-notices p { @@ -788,13 +797,14 @@ input.ee-register-button { font-size: 21px; font-weight: bold; line-height: 21px; + margin: 0; padding: 0; position: absolute; right: 3px; text-align: center; + text-decoration: none !important; top: 1px; vertical-align: middle; - text-decoration: none !important; } .close-espresso-notice:hover { color: var(--ee-status-color-dark-grey); diff --git a/espresso.php b/espresso.php index 2463713d2ed..4f521f48bb5 100644 --- a/espresso.php +++ b/espresso.php @@ -3,7 +3,7 @@ Plugin Name:Event Espresso Plugin URI: https://eventespresso.com/pricing/?ee_ver=ee4&utm_source=ee4_plugin_admin&utm_medium=link&utm_campaign=wordpress_plugins_page&utm_content=support_link Description: Manage events, sell tickets, and receive payments from your WordPress website. Reduce event administration time, cut-out ticketing fees, and own your customer data. | Extensions | Sales | Support - Version: 5.0.13.rc.000 + Version: 5.0.13.rc.025 Author: Event Espresso Author URI: http://eventespresso.com/?ee_ver=ee4&utm_source=ee4_plugin_admin&utm_medium=link&utm_campaign=wordpress_plugins_page&utm_content=support_link License: GPLv3 @@ -104,7 +104,7 @@ function espresso_minimum_php_version_error() */ function espresso_version(): string { - return apply_filters('FHEE__espresso__espresso_version', '5.0.13.rc.000'); + return apply_filters('FHEE__espresso__espresso_version', '5.0.13.rc.025'); } /** diff --git a/languages/event_espresso-translations-js.php b/languages/event_espresso-translations-js.php index cdfced3687d..aab268f486a 100644 --- a/languages/event_espresso-translations-js.php +++ b/languages/event_espresso-translations-js.php @@ -1126,39 +1126,39 @@ __( 'Qty', 'event_espresso' ), // Reference: domains/core/admin/eventEditor/src/ui/venue/VenueDetails.tsx:104 - __( 'Venue capacity', 'event_espresso' ), - - // Reference: domains/core/admin/eventEditor/src/ui/venue/VenueDetails.tsx:112 __( 'Venue telephone', 'event_espresso' ), - // Reference: domains/core/admin/eventEditor/src/ui/venue/VenueDetails.tsx:119 + // Reference: domains/core/admin/eventEditor/src/ui/venue/VenueDetails.tsx:111 __( 'Edit this Venue', 'event_espresso' ), - // Reference: domains/core/admin/eventEditor/src/ui/venue/VenueDetails.tsx:128 + // Reference: domains/core/admin/eventEditor/src/ui/venue/VenueDetails.tsx:120 __( 'Select a Venue for the Event', 'event_espresso' ), // Reference: domains/core/admin/eventEditor/src/ui/venue/VenueDetails.tsx:21 __( 'Venue Details', 'event_espresso' ), - // Reference: domains/core/admin/eventEditor/src/ui/venue/VenueDetails.tsx:47 + // Reference: domains/core/admin/eventEditor/src/ui/venue/VenueDetails.tsx:39 __( 'unlimited space', 'event_espresso' ), - // Reference: domains/core/admin/eventEditor/src/ui/venue/VenueDetails.tsx:50 + // Reference: domains/core/admin/eventEditor/src/ui/venue/VenueDetails.tsx:42 /* translators: %d venue capacity */ __( 'Space for up to %d people', 'event_espresso' ), - // Reference: domains/core/admin/eventEditor/src/ui/venue/VenueDetails.tsx:61 + // Reference: domains/core/admin/eventEditor/src/ui/venue/VenueDetails.tsx:53 __( 'Venue address', 'event_espresso' ), - // Reference: domains/core/admin/eventEditor/src/ui/venue/VenueDetails.tsx:67 + // Reference: domains/core/admin/eventEditor/src/ui/venue/VenueDetails.tsx:59 __( 'Venue Details card', 'event_espresso' ), - // Reference: domains/core/admin/eventEditor/src/ui/venue/VenueDetails.tsx:76 + // Reference: domains/core/admin/eventEditor/src/ui/venue/VenueDetails.tsx:68 __( 'no image', 'event_espresso' ), - // Reference: domains/core/admin/eventEditor/src/ui/venue/VenueDetails.tsx:80 + // Reference: domains/core/admin/eventEditor/src/ui/venue/VenueDetails.tsx:72 __( 'Venue name', 'event_espresso' ), + // Reference: domains/core/admin/eventEditor/src/ui/venue/VenueDetails.tsx:96 + __( 'Venue capacity', 'event_espresso' ), + // Reference: domains/core/admin/wpPluginsPage/src/exitSurvey/Popup.tsx:29 __( 'Do you have a moment to share why you are deactivating Event Espresso?', 'event_espresso' ), diff --git a/modules/invalid_checkout_access/EED_Invalid_Checkout_Access.module.php b/modules/invalid_checkout_access/EED_Invalid_Checkout_Access.module.php index 98507468672..9ba99f44503 100644 --- a/modules/invalid_checkout_access/EED_Invalid_Checkout_Access.module.php +++ b/modules/invalid_checkout_access/EED_Invalid_Checkout_Access.module.php @@ -58,7 +58,7 @@ public function run($WP) /** * @return InvalidCheckoutAccess */ - public static function getInvalidCheckoutAccess() + public static function getInvalidCheckoutAccess(): InvalidCheckoutAccess { if (! self::$invalid_checkout_access_form instanceof InvalidCheckoutAccess) { self::$invalid_checkout_access_form = new InvalidCheckoutAccess(); diff --git a/modules/single_page_checkout/EED_Single_Page_Checkout.module.php b/modules/single_page_checkout/EED_Single_Page_Checkout.module.php index ebf32ae5b02..a146d6d1a10 100644 --- a/modules/single_page_checkout/EED_Single_Page_Checkout.module.php +++ b/modules/single_page_checkout/EED_Single_Page_Checkout.module.php @@ -21,37 +21,30 @@ class EED_Single_Page_Checkout extends EED_Module { /** * $_initialized - has the SPCO controller already been initialized ? - * - * @var bool $_initialized */ - private static $_initialized = false; + private static bool $_initialized = false; /** * $_checkout_verified - is the EE_Checkout verified as correct for this request ? - * - * @var bool $_valid_checkout */ - private static $_checkout_verified = true; + private static bool $_checkout_verified = true; /** - * $_reg_steps_array - holds initial array of reg steps + * $_reg_steps_array - holds initial array of reg steps * * @var array $_reg_steps_array */ - private static $_reg_steps_array = array(); + private static array $_reg_steps_array = []; /** - * $checkout - EE_Checkout object for handling the properties of the current checkout process - * - * @var EE_Checkout $checkout + * $checkout - EE_Checkout object for handling the properties of the current checkout process */ - public $checkout; + public ?EE_Checkout $checkout = null; - /** - * @var RequestInterface $request - */ - protected $request; + protected ?RequestInterface $request = null; + + private bool $debug = false; // true false /** @@ -69,7 +62,7 @@ public static function instance() /** * @return EE_CART */ - public function cart() + public function cart(): EE_CART { return $this->checkout->cart; } @@ -79,7 +72,7 @@ public function cart() * @return RequestInterface * @since 4.10.14.p */ - public static function getRequest() + public static function getRequest(): RequestInterface { return LoaderFactory::getLoader()->getShared(RequestInterface::class); } @@ -88,7 +81,7 @@ public static function getRequest() /** * @return EE_Transaction */ - public function transaction() + public function transaction(): EE_Transaction { return $this->checkout->transaction; } @@ -123,12 +116,12 @@ public static function set_hooks_admin() ob_start(); EED_Single_Page_Checkout::load_reg_steps(); // set ajax hooks - add_action('wp_ajax_process_reg_step', array('EED_Single_Page_Checkout', 'process_reg_step')); - add_action('wp_ajax_nopriv_process_reg_step', array('EED_Single_Page_Checkout', 'process_reg_step')); - add_action('wp_ajax_display_spco_reg_step', array('EED_Single_Page_Checkout', 'display_reg_step')); - add_action('wp_ajax_nopriv_display_spco_reg_step', array('EED_Single_Page_Checkout', 'display_reg_step')); - add_action('wp_ajax_update_reg_step', array('EED_Single_Page_Checkout', 'update_reg_step')); - add_action('wp_ajax_nopriv_update_reg_step', array('EED_Single_Page_Checkout', 'update_reg_step')); + add_action('wp_ajax_process_reg_step', ['EED_Single_Page_Checkout', 'process_reg_step']); + add_action('wp_ajax_nopriv_process_reg_step', ['EED_Single_Page_Checkout', 'process_reg_step']); + add_action('wp_ajax_display_spco_reg_step', ['EED_Single_Page_Checkout', 'display_reg_step']); + add_action('wp_ajax_nopriv_display_spco_reg_step', ['EED_Single_Page_Checkout', 'display_reg_step']); + add_action('wp_ajax_update_reg_step', ['EED_Single_Page_Checkout', 'update_reg_step']); + add_action('wp_ajax_nopriv_update_reg_step', ['EED_Single_Page_Checkout', 'update_reg_step']); } @@ -139,7 +132,7 @@ public static function set_hooks_admin() * @throws EE_Error * @throws ReflectionException */ - public static function process_ajax_request($ajax_action) + public static function process_ajax_request(string $ajax_action) { $request = EED_Single_Page_Checkout::getRequest(); $request->setRequestParam('action', $ajax_action); @@ -196,15 +189,6 @@ public static function update_checkout() } - /** - * @return void - * @deprecated 4.10.14.p - */ - public static function load_request_handler() - { - } - - /** * set_definitions * @@ -218,7 +202,7 @@ public static function set_definitions() } define( 'SPCO_BASE_PATH', - rtrim(str_replace(array('\\', '/'), '/', plugin_dir_path(__FILE__)), '/') . '/' + rtrim(str_replace(['\\', '/'], '/', plugin_dir_path(__FILE__)), '/') . '/' ); define('SPCO_CSS_URL', plugin_dir_url(__FILE__) . 'css/'); define('SPCO_IMG_URL', plugin_dir_url(__FILE__) . 'img/'); @@ -227,8 +211,8 @@ public static function set_definitions() define('SPCO_REG_STEPS_PATH', SPCO_BASE_PATH . 'reg_steps/'); define('SPCO_TEMPLATES_PATH', SPCO_BASE_PATH . 'templates/'); EEH_Autoloader::register_autoloaders_for_each_file_in_folder(SPCO_BASE_PATH, true); - EE_Registry::$i18n_js_strings['registration_expiration_notice'] = EED_Single_Page_Checkout::getRegistrationExpirationNotice( - ); + EE_Registry::$i18n_js_strings['registration_expiration_notice'] = + EED_Single_Page_Checkout::getRegistrationExpirationNotice(); } @@ -275,7 +259,7 @@ public static function load_reg_steps() ); } if (is_callable($reg_step['class_name'], 'set_hooks')) { - call_user_func(array($reg_step['class_name'], 'set_hooks')); + call_user_func([$reg_step['class_name'], 'set_hooks']); } } } @@ -289,39 +273,37 @@ public static function load_reg_steps() * * @return array */ - public static function get_reg_steps() + public static function get_reg_steps(): array { $reg_steps = EE_Registry::instance()->CFG->registration->reg_steps; if (empty($reg_steps)) { - $reg_steps = array( - 10 => array( + $reg_steps = [ + 10 => [ 'file_path' => SPCO_REG_STEPS_PATH . 'attendee_information', 'class_name' => 'EE_SPCO_Reg_Step_Attendee_Information', 'slug' => 'attendee_information', 'has_hooks' => false, - ), - 30 => array( + ], + 30 => [ 'file_path' => SPCO_REG_STEPS_PATH . 'payment_options', 'class_name' => 'EE_SPCO_Reg_Step_Payment_Options', 'slug' => 'payment_options', 'has_hooks' => true, - ), - 999 => array( + ], + 999 => [ 'file_path' => SPCO_REG_STEPS_PATH . 'finalize_registration', 'class_name' => 'EE_SPCO_Reg_Step_Finalize_Registration', 'slug' => 'finalize_registration', 'has_hooks' => false, - ), - ); + ], + ]; } return $reg_steps; } /** - * registration_checkout_for_admin - * - * @return string + * @return array|string * @throws EE_Error * @throws ReflectionException */ @@ -338,13 +320,11 @@ public static function registration_checkout_for_admin() /** - * process_registration_from_admin - * - * @return EE_Transaction + * @return EE_Transaction|null * @throws EE_Error * @throws ReflectionException */ - public static function process_registration_from_admin() + public static function process_registration_from_admin(): ?EE_Transaction { $request = EED_Single_Page_Checkout::getRequest(); $request->setRequestParam('step', 'attendee_information'); @@ -369,7 +349,7 @@ public static function process_registration_from_admin() /** * run * - * @param WP_Query $WP_Query + * @param WP_Query|null $WP_Query * @return void */ public function run($WP_Query) @@ -390,7 +370,7 @@ public function run($WP_Query) * * @return bool */ - protected function _is_reg_checkout() + protected function _is_reg_checkout(): bool { // get current permalink for reg page without any extra query args $reg_page_url = get_permalink(EE_Config::instance()->core->reg_page_id); @@ -422,16 +402,14 @@ protected function _is_reg_checkout() * @throws EE_Error * @throws ReflectionException */ - public static function init($wp_query) + public static function init(WP_Query $wp_query) { EED_Single_Page_Checkout::instance()->run($wp_query); } /** - * _initialize - initial module setup - * - * @return void + * @return void */ private function _initialize() { @@ -443,7 +421,7 @@ private function _initialize() $this->request = EED_Single_Page_Checkout::getRequest(); EED_Single_Page_Checkout::load_reg_steps(); $this->_verify_session(); - // setup the EE_Checkout object + // set up the EE_Checkout object $this->checkout = $this->_initialize_checkout(); // filter checkout $this->checkout = apply_filters('FHEE__EED_Single_Page_Checkout___initialize__checkout', $this->checkout); @@ -467,11 +445,12 @@ private function _initialize() $this->checkout->set_current_step($this->checkout->step); // and the next step $this->checkout->set_next_step(); - // verify that everything has been setup correctly + // verify that everything has been set up correctly if (! ($this->_verify_transaction_and_get_registrations() && $this->_final_verifications())) { EED_Single_Page_Checkout::$_initialized = true; return; } + do_action('AHEE__Single_Page_Checkout___initialize__after_final_verifications', $this->checkout); // lock the transaction $this->checkout->transaction->lock(); // make sure all of our cached objects are added to their respective model entity mappers @@ -496,9 +475,9 @@ private function _initialize() // set no cache headers and constants EE_System::do_not_cache(); // add anchor - add_action('loop_start', array($this, 'set_checkout_anchor'), 1); + add_action('loop_start', [$this, 'set_checkout_anchor'], 1); // remove transaction lock - add_action('shutdown', array($this, 'unlock_transaction'), 1); + add_action('shutdown', [$this, 'unlock_transaction'], 1); } catch (Exception $e) { EE_Error::add_error($e->getMessage(), __FILE__, __FUNCTION__, __LINE__); } @@ -506,7 +485,6 @@ private function _initialize() /** - * _verify_session * checks that the session is valid and not expired * * @throws EE_Error @@ -545,14 +523,13 @@ private function _verify_session() /** - * _initialize_checkout * loads and instantiates EE_Checkout * * @return EE_Checkout * @throws EE_Error * @throws ReflectionException */ - private function _initialize_checkout() + private function _initialize_checkout(): EE_Checkout { // look in session for existing checkout /** @type EE_Checkout $checkout */ @@ -564,7 +541,7 @@ private function _initialize_checkout() SPCO_INC_PATH, 'EE_Checkout', 'class', - array(), + [], false ); } else { @@ -586,9 +563,7 @@ private function _initialize_checkout() /** - * _get_request_vars - * - * @return void + * @return void */ private function _get_request_vars() { @@ -612,9 +587,9 @@ private function _get_request_vars() } // or some other kind of revisit ? $this->checkout->revisit = $this->request->getRequestParam('revisit', false, 'bool'); - // and whether or not to generate a reg form for this request + // and whether to generate a reg form for this request $this->checkout->generate_reg_form = $this->request->getRequestParam('generate_reg_form', true, 'bool'); - // and whether or not to process a reg form submission for this request + // and whether to process a reg form submission for this request $this->checkout->process_form_submission = $this->request->getRequestParam( 'process_form_submission', $this->checkout->action === 'process_reg_step', @@ -626,18 +601,16 @@ private function _get_request_vars() : false, FILTER_VALIDATE_BOOLEAN ); - // $this->_display_request_vars(); + $this->_display_request_vars(); } /** - * _display_request_vars - * - * @return void + * @return void */ protected function _display_request_vars() { - if (! WP_DEBUG) { + if (! ($this->debug && defined('WP_DEBUG') && WP_DEBUG)) { return; } EEH_Debug_Tools::printr($this->request->requestParams(), 'requestParams', __FILE__, __LINE__); @@ -664,47 +637,42 @@ protected function _display_request_vars() /** * _block_bots * checks that the incoming request has either of the following set: - * a uts (unix timestamp) which indicates that the request was redirected from the Ticket Selector + * a UTS (unix timestamp) which indicates that the request was redirected from the Ticket Selector * a REG URL Link, which indicates that the request is a return visit to SPCO for a valid TXN * so if you're not coming from the Ticket Selector nor returning for a valid IP... * then where you coming from man? * * @return boolean */ - private function _block_bots() + private function _block_bots(): bool { - $invalid_checkout_access = EED_Invalid_Checkout_Access::getInvalidCheckoutAccess(); - if ($invalid_checkout_access->checkoutAccessIsInvalid($this->checkout)) { - return true; - } - return false; + return EED_Invalid_Checkout_Access::getInvalidCheckoutAccess()->checkoutAccessIsInvalid($this->checkout); } /** - * _get_first_step * gets slug for first step in $_reg_steps_array * - * @return string + * @return string */ - private function _get_first_step() + private function _get_first_step(): string { $first_step = reset(EED_Single_Page_Checkout::$_reg_steps_array); - return isset($first_step['slug']) ? $first_step['slug'] : 'attendee_information'; + return $first_step['slug'] ?? 'attendee_information'; } /** * instantiates each reg step based on the loaded reg_steps array * - * @return bool + * @return bool * @throws EE_Error * @throws InvalidArgumentException * @throws InvalidDataTypeException * @throws InvalidInterfaceException * @throws ReflectionException */ - private function _load_and_instantiate_reg_steps() + private function _load_and_instantiate_reg_steps(): bool { do_action('AHEE__Single_Page_Checkout___load_and_instantiate_reg_steps__start', $this->checkout); // have reg_steps already been instantiated ? @@ -752,15 +720,13 @@ private function _load_and_instantiate_reg_steps() /** - * _load_and_instantiate_reg_step - * * @param array $reg_step * @param int $order * @return bool * @throws EE_Error * @throws ReflectionException */ - private function _load_and_instantiate_reg_step($reg_step = array(), $order = 0) + private function _load_and_instantiate_reg_step(array $reg_step = [], int $order = 0): bool { // we need a file_path, class_name, and slug to add a reg step if (isset($reg_step['file_path'], $reg_step['class_name'], $reg_step['slug'])) { @@ -788,7 +754,7 @@ private function _load_and_instantiate_reg_step($reg_step = array(), $order = 0) [$this->checkout], false ); - // did we gets the goods ? + // did we get the goods ? if ($reg_step_obj instanceof EE_SPCO_Reg_Step) { // set reg step order based on config $reg_step_obj->set_order($order); @@ -811,9 +777,9 @@ private function _load_and_instantiate_reg_step($reg_step = array(), $order = 0) 'A registration step could not be loaded. One or more of the following data points is invalid:%4$s%5$sFile Path: %1$s%6$s%5$sClass Name: %2$s%6$s%5$sSlug: %3$s%6$s%7$s', 'event_espresso' ), - isset($reg_step['file_path']) ? $reg_step['file_path'] : '', - isset($reg_step['class_name']) ? $reg_step['class_name'] : '', - isset($reg_step['slug']) ? $reg_step['slug'] : '', + $reg_step['file_path'] ?? '', + $reg_step['class_name'] ?? '', + $reg_step['slug'] ?? '', '
    ', '
  • ', '
  • ', @@ -831,13 +797,11 @@ private function _load_and_instantiate_reg_step($reg_step = array(), $order = 0) /** - * _verify_transaction_and_get_registrations - * * @return bool * @throws EE_Error * @throws ReflectionException */ - private function _verify_transaction_and_get_registrations() + private function _verify_transaction_and_get_registrations(): bool { // was there already a valid transaction in the checkout from the session ? if (! $this->checkout->transaction instanceof EE_Transaction) { @@ -869,13 +833,11 @@ private function _verify_transaction_and_get_registrations() /** - * _get_transaction_and_cart_for_previous_visit - * * @return EE_Transaction|null * @throws EE_Error * @throws ReflectionException */ - private function _get_transaction_and_cart_for_previous_visit() + private function _get_transaction_and_cart_for_previous_visit(): ?EE_Transaction { /** @var $TXN_model EEM_Transaction */ $TXN_model = EE_Registry::instance()->load_model('Transaction'); @@ -889,7 +851,10 @@ private function _get_transaction_and_cart_for_previous_visit() return $transaction; } EE_Error::add_error( - esc_html__('Your Registration and Transaction information could not be retrieved from the db.', 'event_espresso'), + esc_html__( + 'Your Registration and Transaction information could not be retrieved from the db.', + 'event_espresso' + ), __FILE__, __FUNCTION__, __LINE__ @@ -899,38 +864,33 @@ private function _get_transaction_and_cart_for_previous_visit() /** - * _get_cart_for_transaction - * - * @param EE_Transaction $transaction + * @param EE_Transaction|null $transaction * @return EE_Cart */ - private function _get_cart_for_transaction($transaction) + private function _get_cart_for_transaction(?EE_Transaction $transaction): EE_Cart { return $this->checkout->get_cart_for_transaction($transaction); } /** - * get_cart_for_transaction - * - * @param EE_Transaction $transaction + * @param EE_Transaction|null $transaction * @return EE_Cart */ - public function get_cart_for_transaction(EE_Transaction $transaction) + public function get_cart_for_transaction(?EE_Transaction $transaction): EE_Cart { return $this->checkout->get_cart_for_transaction($transaction); } /** - * _get_transaction_and_cart_for_current_session - * generates a new EE_Transaction object and adds it to the $_transaction property. + * generates a new EE_Transaction object and adds it to the $_transaction property. * - * @return EE_Transaction + * @return EE_Transaction|null * @throws EE_Error * @throws ReflectionException */ - private function _get_cart_for_current_session_and_setup_new_transaction() + private function _get_cart_for_current_session_and_setup_new_transaction(): ?EE_Transaction { // if there's no transaction, then this is the FIRST visit to SPCO // so load up the cart ( passing nothing for the TXN because it doesn't exist yet ) @@ -939,8 +899,6 @@ private function _get_cart_for_current_session_and_setup_new_transaction() $transaction = $this->_initialize_transaction(); // verify transaction if ($transaction instanceof EE_Transaction) { - // save it so that we have an ID for other objects to use - $transaction->save(); // and save TXN data to the cart $this->checkout->cart->get_grand_total()->save_this_and_descendants_to_txn($transaction->ID()); } else { @@ -956,11 +914,11 @@ private function _get_cart_for_current_session_and_setup_new_transaction() /** - * generates a new EE_Transaction object and adds it to the $_transaction property. + * generates a new EE_Transaction object and adds it to the $_transaction property. * * @return EE_Transaction|null */ - private function _initialize_transaction() + private function _initialize_transaction(): ?EE_Transaction { try { // ensure cart totals have been calculated @@ -969,12 +927,12 @@ private function _initialize_transaction() $cart_total = $this->checkout->cart->get_cart_grand_total(); // create new TXN $transaction = EE_Transaction::new_instance( - array( + [ 'TXN_reg_steps' => $this->checkout->initialize_txn_reg_steps_array(), - 'TXN_total' => $cart_total > 0 ? $cart_total : 0, + 'TXN_total' => max($cart_total, 0), 'TXN_paid' => 0, 'STS_ID' => EEM_Transaction::failed_status_code, - ) + ] ); // save it so that we have an ID for other objects to use $transaction->save(); @@ -1002,7 +960,7 @@ private function _initialize_transaction() private function _get_registrations(EE_Transaction $transaction) { // first step: grab the registrants { : o - $registrations = $transaction->registrations($this->checkout->reg_cache_where_params); + $registrations = $transaction->registrations($this->checkout->reg_cache_where_params); $this->checkout->total_ticket_count = count($registrations); // verify registrations have been set if (empty($registrations)) { @@ -1015,7 +973,7 @@ private function _get_registrations(EE_Transaction $transaction) } } // sort by their original registration order - usort($registrations, array('EED_Single_Page_Checkout', 'sort_registrations_by_REG_count')); + usort($registrations, ['EED_Single_Page_Checkout', 'sort_registrations_by_REG_count']); // then loop thru the array foreach ($registrations as $registration) { // verify each registration @@ -1040,63 +998,61 @@ private function _get_registrations(EE_Transaction $transaction) /** - * adds related EE_Registration objects for each ticket in the cart to the current EE_Transaction object + * adds related EE_Registration objects for each ticket in the cart to the current EE_Transaction object * * @param EE_Transaction $transaction - * @return array + * @return array * @throws EE_Error * @throws ReflectionException */ - private function _initialize_registrations(EE_Transaction $transaction) + private function _initialize_registrations(EE_Transaction $transaction): array { - $att_nmbr = 0; - $registrations = array(); - if ($transaction instanceof EE_Transaction) { - /** @type EE_Registration_Processor $registration_processor */ - $registration_processor = EE_Registry::instance()->load_class('Registration_Processor'); - $this->checkout->total_ticket_count = $this->checkout->cart->all_ticket_quantity_count(); - // now let's add the cart items to the $transaction - foreach ($this->checkout->cart->get_tickets() as $line_item) { - // do the following for each ticket of this type they selected - for ($x = 1; $x <= $line_item->quantity(); $x++) { - $att_nmbr++; - /** @var CreateRegistrationCommand $CreateRegistrationCommand */ - $CreateRegistrationCommand = EE_Registry::instance()->create( - CreateRegistrationCommand::class, - [ - $transaction, - $line_item, - $att_nmbr, - $this->checkout->total_ticket_count, - ] + $att_nmbr = 0; + $registrations = []; + /** @type EE_Registration_Processor $registration_processor */ + $registration_processor = EE_Registry::instance()->load_class('Registration_Processor'); + $this->checkout->total_ticket_count = $this->checkout->cart->all_ticket_quantity_count(); + // now let's add the cart items to the $transaction + foreach ($this->checkout->cart->get_tickets() as $line_item) { + // do the following for each ticket of this type they selected + for ($x = 1; $x <= $line_item->quantity(); $x++) { + $att_nmbr++; + /** @var CreateRegistrationCommand $CreateRegistrationCommand */ + $CreateRegistrationCommand = EE_Registry::instance()->create( + CreateRegistrationCommand::class, + [ + $transaction, + $line_item, + $att_nmbr, + $this->checkout->total_ticket_count, + ] + ); + // override capabilities for frontend registrations + if ($this->request->isFrontend()) { + $CreateRegistrationCommand->setCapCheck( + new PublicCapabilities('', 'create_new_registration') ); - // override capabilities for frontend registrations - if ($this->request->isFrontend()) { - $CreateRegistrationCommand->setCapCheck( - new PublicCapabilities('', 'create_new_registration') - ); - } - $registration = EE_Registry::instance()->BUS->execute($CreateRegistrationCommand); - if (! $registration instanceof EE_Registration) { - throw new InvalidEntityException($registration, 'EE_Registration'); - } - $registrations[ $registration->ID() ] = $registration; } + $registration = EE_Registry::instance()->BUS->execute($CreateRegistrationCommand); + if (! $registration instanceof EE_Registration) { + throw new InvalidEntityException($registration, 'EE_Registration'); + } + $registrations[ $registration->ID() ] = $registration; } - $registration_processor->fix_reg_final_price_rounding_issue($transaction); } + $registration_processor->fix_reg_final_price_rounding_issue($transaction); return $registrations; } /** - * sorts registrations by REG_count - * * @param EE_Registration $reg_A * @param EE_Registration $reg_B * @return int + * @throws EE_Error + * @throws ReflectionException */ - public static function sort_registrations_by_REG_count(EE_Registration $reg_A, EE_Registration $reg_B) + public static function sort_registrations_by_REG_count(EE_Registration $reg_A, EE_Registration $reg_B): int { // this shouldn't ever happen within the same TXN, but oh well if ($reg_A->count() === $reg_B->count()) { @@ -1107,14 +1063,13 @@ public static function sort_registrations_by_REG_count(EE_Registration $reg_A, E /** - * _final_verifications * just makes sure that everything is set up correctly before proceeding * - * @return bool + * @return bool * @throws EE_Error * @throws ReflectionException */ - private function _final_verifications() + private function _final_verifications(): bool { // filter checkout $this->checkout = apply_filters( @@ -1150,7 +1105,11 @@ private function _final_verifications() return false; } $valid_registrant = null; - foreach ($this->checkout->transaction->registrations($this->checkout->reg_cache_where_params) as $registration) { + foreach ( + $this->checkout->transaction->registrations( + $this->checkout->reg_cache_where_params + ) as $registration + ) { if ( $registration instanceof EE_Registration && $registration->reg_url_link() === $this->checkout->reg_url_link @@ -1163,7 +1122,7 @@ private function _final_verifications() if (EED_Single_Page_Checkout::$_checkout_verified) { // clear the session, mark the checkout as unverified, and try again EE_Registry::instance()->SSN->clear_session(__CLASS__, __FUNCTION__); - EED_Single_Page_Checkout::$_initialized = false; + EED_Single_Page_Checkout::$_initialized = false; EED_Single_Page_Checkout::$_checkout_verified = false; $this->_initialize(); EE_Error::reset_notices(); @@ -1189,14 +1148,13 @@ private function _final_verifications() /** - * _initialize_reg_steps * first makes sure that EE_Transaction_Processor::set_reg_step_initiated() is called as required - * then loops thru all of the active reg steps and calls the initialize_reg_step() method + * then loops thru all the active reg steps and calls the initialize_reg_step() method * * @param bool $reinitializing * @throws EE_Error */ - private function _initialize_reg_steps($reinitializing = false) + private function _initialize_reg_steps(bool $reinitializing = false) { $this->checkout->set_reg_step_initiated($this->checkout->current_step); // loop thru all steps to call their individual "initialize" methods and set i18n strings for JS @@ -1226,13 +1184,11 @@ private function _initialize_reg_steps($reinitializing = false) /** - * _check_form_submission - * * @return boolean * @throws EE_Error * @throws ReflectionException */ - private function _check_form_submission() + private function _check_form_submission(): bool { // does this request require the reg form to be generated ? if ($this->checkout->generate_reg_form) { @@ -1245,7 +1201,7 @@ private function _check_form_submission() && $this->checkout->current_step->reg_form->was_submitted() ) { // clear out any old data in case this step is being run again - $this->checkout->current_step->set_valid_data(array()); + $this->checkout->current_step->set_valid_data([]); // capture submitted form data $request_data = $this->request->requestParams(); $this->checkout->current_step->reg_form->receive_form_submission( @@ -1283,8 +1239,6 @@ private function _check_form_submission() /** - * _process_action - * * @return void * @throws EE_Error * @throws ReflectionException @@ -1306,7 +1260,7 @@ private function _process_form_action() // meh... do one of those other steps first if ( ! empty($this->checkout->action) - && is_callable(array($this->checkout->current_step, $this->checkout->action)) + && is_callable([$this->checkout->current_step, $this->checkout->action]) ) { // dynamically creates hook point like: // AHEE__Single_Page_Checkout__before_attendee_information__process_reg_step @@ -1371,53 +1325,52 @@ private function _process_form_action() /** * @param EED_Single_Page_Checkout|EE_SPCO_Reg_Step $target an object with the method `translate_js_strings` and * `enqueue_styles_and_scripts`. - * @return void + * @return void */ public function add_styles_and_scripts($target) { // i18n $target->translate_js_strings(); if ($this->checkout->admin_request) { - add_action('admin_enqueue_scripts', array($target, 'enqueue_styles_and_scripts'), 10); + add_action('admin_enqueue_scripts', [$target, 'enqueue_styles_and_scripts']); } else { - add_action('wp_enqueue_scripts', array($target, 'enqueue_styles_and_scripts'), 10); + add_action('wp_enqueue_scripts', [$target, 'enqueue_styles_and_scripts']); } } + /** - * translate_js_strings - * - * @return void + * @return void */ public function translate_js_strings() { - EE_Registry::$i18n_js_strings['revisit'] = $this->checkout->revisit; - EE_Registry::$i18n_js_strings['e_reg_url_link'] = $this->checkout->reg_url_link; - EE_Registry::$i18n_js_strings['server_error'] = esc_html__( + EE_Registry::$i18n_js_strings['revisit'] = $this->checkout->revisit; + EE_Registry::$i18n_js_strings['e_reg_url_link'] = $this->checkout->reg_url_link; + EE_Registry::$i18n_js_strings['server_error'] = esc_html__( 'An unknown error occurred on the server while attempting to process your request. Please refresh the page and try again or contact support.', 'event_espresso' ); - EE_Registry::$i18n_js_strings['invalid_json_response'] = esc_html__( + EE_Registry::$i18n_js_strings['invalid_json_response'] = esc_html__( 'An invalid response was returned from the server while attempting to process your request. Please refresh the page and try again or contact support.', 'event_espresso' ); - EE_Registry::$i18n_js_strings['validation_error'] = esc_html__( + EE_Registry::$i18n_js_strings['validation_error'] = esc_html__( 'There appears to be a problem with the form validation configuration! Please check the admin settings or contact support.', 'event_espresso' ); - EE_Registry::$i18n_js_strings['invalid_payment_method'] = esc_html__( + EE_Registry::$i18n_js_strings['invalid_payment_method'] = esc_html__( 'There appears to be a problem with the payment method configuration! Please refresh the page and try again or contact support.', 'event_espresso' ); - EE_Registry::$i18n_js_strings['reg_step_error'] = esc_html__( + EE_Registry::$i18n_js_strings['reg_step_error'] = esc_html__( 'This registration step could not be completed. Please refresh the page and try again.', 'event_espresso' ); - EE_Registry::$i18n_js_strings['invalid_coupon'] = esc_html__( + EE_Registry::$i18n_js_strings['invalid_coupon'] = esc_html__( 'We\'re sorry but that coupon code does not appear to be valid. If this is incorrect, please contact the site administrator.', 'event_espresso' ); - EE_Registry::$i18n_js_strings['process_registration'] = sprintf( + EE_Registry::$i18n_js_strings['process_registration'] = sprintf( esc_html__( 'Please wait while we process your registration.%sDo not refresh the page or navigate away while this is happening.%sThank you for your patience.', 'event_espresso' @@ -1425,34 +1378,34 @@ public function translate_js_strings() '
    ', '
    ' ); - EE_Registry::$i18n_js_strings['language'] = get_bloginfo('language'); - EE_Registry::$i18n_js_strings['EESID'] = EE_Registry::instance()->SSN->id(); - EE_Registry::$i18n_js_strings['currency'] = EE_Registry::instance()->CFG->currency; - EE_Registry::$i18n_js_strings['datepicker_yearRange'] = '-150:+20'; - EE_Registry::$i18n_js_strings['timer_years'] = esc_html__('years', 'event_espresso'); - EE_Registry::$i18n_js_strings['timer_months'] = esc_html__('months', 'event_espresso'); - EE_Registry::$i18n_js_strings['timer_weeks'] = esc_html__('weeks', 'event_espresso'); - EE_Registry::$i18n_js_strings['timer_days'] = esc_html__('days', 'event_espresso'); - EE_Registry::$i18n_js_strings['timer_hours'] = esc_html__('hours', 'event_espresso'); - EE_Registry::$i18n_js_strings['timer_minutes'] = esc_html__('minutes', 'event_espresso'); - EE_Registry::$i18n_js_strings['timer_seconds'] = esc_html__('seconds', 'event_espresso'); - EE_Registry::$i18n_js_strings['timer_year'] = esc_html__('year', 'event_espresso'); - EE_Registry::$i18n_js_strings['timer_month'] = esc_html__('month', 'event_espresso'); - EE_Registry::$i18n_js_strings['timer_week'] = esc_html__('week', 'event_espresso'); - EE_Registry::$i18n_js_strings['timer_day'] = esc_html__('day', 'event_espresso'); - EE_Registry::$i18n_js_strings['timer_hour'] = esc_html__('hour', 'event_espresso'); - EE_Registry::$i18n_js_strings['timer_minute'] = esc_html__('minute', 'event_espresso'); - EE_Registry::$i18n_js_strings['timer_second'] = esc_html__('second', 'event_espresso'); - EE_Registry::$i18n_js_strings['registration_expiration_notice'] = EED_Single_Page_Checkout::getRegistrationExpirationNotice( - ); - EE_Registry::$i18n_js_strings['ajax_submit'] = apply_filters( + EE_Registry::$i18n_js_strings['language'] = get_bloginfo('language'); + EE_Registry::$i18n_js_strings['EESID'] = EE_Registry::instance()->SSN->id(); + EE_Registry::$i18n_js_strings['currency'] = EE_Registry::instance()->CFG->currency; + EE_Registry::$i18n_js_strings['datepicker_yearRange'] = '-150:+20'; + EE_Registry::$i18n_js_strings['timer_years'] = esc_html__('years', 'event_espresso'); + EE_Registry::$i18n_js_strings['timer_months'] = esc_html__('months', 'event_espresso'); + EE_Registry::$i18n_js_strings['timer_weeks'] = esc_html__('weeks', 'event_espresso'); + EE_Registry::$i18n_js_strings['timer_days'] = esc_html__('days', 'event_espresso'); + EE_Registry::$i18n_js_strings['timer_hours'] = esc_html__('hours', 'event_espresso'); + EE_Registry::$i18n_js_strings['timer_minutes'] = esc_html__('minutes', 'event_espresso'); + EE_Registry::$i18n_js_strings['timer_seconds'] = esc_html__('seconds', 'event_espresso'); + EE_Registry::$i18n_js_strings['timer_year'] = esc_html__('year', 'event_espresso'); + EE_Registry::$i18n_js_strings['timer_month'] = esc_html__('month', 'event_espresso'); + EE_Registry::$i18n_js_strings['timer_week'] = esc_html__('week', 'event_espresso'); + EE_Registry::$i18n_js_strings['timer_day'] = esc_html__('day', 'event_espresso'); + EE_Registry::$i18n_js_strings['timer_hour'] = esc_html__('hour', 'event_espresso'); + EE_Registry::$i18n_js_strings['timer_minute'] = esc_html__('minute', 'event_espresso'); + EE_Registry::$i18n_js_strings['timer_second'] = esc_html__('second', 'event_espresso'); + EE_Registry::$i18n_js_strings['registration_expiration_notice'] = + EED_Single_Page_Checkout::getRegistrationExpirationNotice(); + EE_Registry::$i18n_js_strings['ajax_submit'] = apply_filters( 'FHEE__Single_Page_Checkout__translate_js_strings__ajax_submit', true ); - EE_Registry::$i18n_js_strings['session_extension'] = absint( + EE_Registry::$i18n_js_strings['session_extension'] = absint( apply_filters('FHEE__EE_Session__extend_expiration__seconds_added', 10 * MINUTE_IN_SECONDS) ); - EE_Registry::$i18n_js_strings['session_expiration'] = gmdate( + EE_Registry::$i18n_js_strings['session_expiration'] = gmdate( 'M d, Y H:i:s', EE_Registry::instance()->SSN->expiration() + (get_option('gmt_offset') * HOUR_IN_SECONDS) ); @@ -1460,9 +1413,7 @@ public function translate_js_strings() /** - * enqueue_styles_and_scripts - * - * @return void + * @return void * @throws EE_Error */ public function enqueue_styles_and_scripts() @@ -1471,7 +1422,7 @@ public function enqueue_styles_and_scripts() wp_register_style( 'single_page_checkout', SPCO_CSS_URL . 'single_page_checkout.css', - array('espresso_default'), + ['espresso_default'], EVENT_ESPRESSO_VERSION ); wp_enqueue_style('single_page_checkout'); @@ -1479,21 +1430,21 @@ public function enqueue_styles_and_scripts() wp_register_script( 'jquery_plugin', EE_THIRD_PARTY_URL . 'jquery .plugin.min.js', - array('jquery'), + ['jquery'], '1.0.1', true ); wp_register_script( 'jquery_countdown', EE_THIRD_PARTY_URL . 'jquery .countdown.min.js', - array('jquery_plugin'), + ['jquery_plugin'], '2.1.0', true ); wp_register_script( 'single_page_checkout', SPCO_JS_URL . 'single_page_checkout.js', - array('espresso_core', 'underscore', 'ee_form_section_validation'), + ['espresso_core', 'underscore', 'ee_form_section_validation'], EVENT_ESPRESSO_VERSION, true ); @@ -1525,9 +1476,9 @@ public function enqueue_styles_and_scripts() /** - * display the Registration Single Page Checkout Form + * display the Registration Single Page Checkout Form * - * @return void + * @return void * @throws EE_Error * @throws ReflectionException */ @@ -1538,12 +1489,12 @@ private function _display_spco_reg_form() EED_Single_Page_Checkout::getResponse()->addOutput($this->checkout->current_step->display_reg_form()); } else { // add powered by EE msg - add_action('AHEE__SPCO__reg_form_footer', array('EED_Single_Page_Checkout', 'display_registration_footer')); - $empty_cart = count( - $this->checkout->transaction->registrations($this->checkout->reg_cache_where_params) - ) < 1; + add_action('AHEE__SPCO__reg_form_footer', ['EED_Single_Page_Checkout', 'display_registration_footer']); + $empty_cart = count( + $this->checkout->transaction->registrations($this->checkout->reg_cache_where_params) + ) < 1; EE_Registry::$i18n_js_strings['empty_cart'] = $empty_cart; - $cookies_not_set_msg = ''; + $cookies_not_set_msg = ''; if ($empty_cart) { $cookies_not_set_msg = apply_filters( 'FHEE__Single_Page_Checkout__display_spco_reg_form__cookies_not_set_msg', @@ -1565,14 +1516,14 @@ private function _display_spco_reg_form() ); } $this->checkout->registration_form = new EE_Form_Section_Proper( - array( + [ 'name' => 'single-page-checkout', 'html_id' => 'ee-single-page-checkout-dv', 'layout_strategy' => new EE_Template_Layout( - array( + [ 'layout_template_file' => SPCO_TEMPLATES_PATH . 'registration_page_wrapper.template.php', - 'template_args' => array( + 'template_args' => [ 'empty_cart' => $empty_cart, 'revisit' => $this->checkout->revisit, 'reg_steps' => $this->checkout->reg_steps, @@ -1600,10 +1551,10 @@ private function _display_spco_reg_form() EE_Registry::instance()->SSN->expiration() + (get_option('gmt_offset') * HOUR_IN_SECONDS) ), - ), - ) + ], + ] ), - ) + ] ); // load template and add to output sent that gets filtered into the_content() EED_Single_Page_Checkout::getResponse()->addOutput($this->checkout->registration_form->get_html()); @@ -1612,10 +1563,7 @@ private function _display_spco_reg_form() /** - * add_extra_finalize_registration_inputs - * * @param $next_step - * @internal param string $label * @return void */ public function add_extra_finalize_registration_inputs($next_step) @@ -1627,9 +1575,7 @@ public function add_extra_finalize_registration_inputs($next_step) /** - * display_registration_footer - * - * @return string + * @return void */ public static function display_registration_footer() { @@ -1650,18 +1596,15 @@ function ($url) { EEH_Template::powered_by_event_espresso( '', 'espresso-registration-footer-dv', - array('utm_content' => 'registration_checkout') + ['utm_content' => 'registration_checkout'] ) ); } - return ''; } /** - * unlock_transaction - * - * @return void + * @return void * @throws EE_Error * @throws ReflectionException */ @@ -1674,8 +1617,6 @@ public function unlock_transaction() /** - * _setup_redirect - * * @return void */ private function _setup_redirect() @@ -1695,7 +1636,7 @@ private function _setup_redirect() /** - * handle ajax message responses and redirects + * handle ajax message responses and redirects * * @return void * @throws EE_Error @@ -1718,7 +1659,7 @@ public function go_to_next_step() } // AJAX response $this->_handle_json_response(); - // redirect to next step or the Thank You page + // redirect to next step or the Thank-You page $this->_handle_html_redirects(); // hmmm... must be something wrong, so let's just display the form again ! $this->_display_spco_reg_form(); @@ -1726,8 +1667,6 @@ public function go_to_next_step() /** - * _handle_json_response - * * @return void * @throws EE_Error */ @@ -1750,8 +1689,6 @@ protected function _handle_json_response() /** - * _handle_redirects - * * @return void */ protected function _handle_html_redirects() @@ -1767,8 +1704,6 @@ protected function _handle_html_redirects() /** - * set_checkout_anchor - * * @return void */ public function set_checkout_anchor() @@ -1776,13 +1711,12 @@ public function set_checkout_anchor() echo ''; } + /** - * getRegistrationExpirationNotice - * - * @since 4.9.59.p - * @return string + * @return string + * @since 4.9.59.p */ - public static function getRegistrationExpirationNotice() + public static function getRegistrationExpirationNotice(): string { return sprintf( esc_html__( diff --git a/modules/single_page_checkout/inc/EE_Checkout.class.php b/modules/single_page_checkout/inc/EE_Checkout.class.php index 581574fd90c..4a0da542fb6 100644 --- a/modules/single_page_checkout/inc/EE_Checkout.class.php +++ b/modules/single_page_checkout/inc/EE_Checkout.class.php @@ -458,35 +458,15 @@ public function set_reg_step_order($reg_step_slug = '', $order = 100) /** - * set_current_step - * - * @access public * @param string $current_step - * @return void + * @return void */ - public function set_current_step($current_step) + public function set_current_step(string $current_step) { // grab what step we're on - $this->current_step = isset($this->reg_steps[ $current_step ]) - ? $this->reg_steps[ $current_step ] - : reset( - $this->reg_steps - ); + $this->current_step = $this->reg_steps[ $current_step ] ?? reset($this->reg_steps); // verify instance - if ($this->current_step instanceof EE_SPCO_Reg_Step) { - // we don't want to repeat completed steps if this is the first time through SPCO - if ($this->continue_reg && ! $this->revisit && $this->current_step->completed()) { - // so advance to the next step - $this->set_next_step(); - if ($this->next_step instanceof EE_SPCO_Reg_Step) { - // and attempt to set it as the current step - $this->set_current_step($this->next_step->slug()); - } - return; - } - $this->current_step->set_is_current_step(true); - $this->current_step->setRequest(EED_Single_Page_Checkout::getRequest()); - } else { + if (! $this->current_step instanceof EE_SPCO_Reg_Step) { EE_Error::add_error( esc_html__('The current step could not be set.', 'event_espresso'), __FILE__, @@ -494,6 +474,18 @@ public function set_current_step($current_step) __LINE__ ); } + // we don't want to repeat completed steps if this is the first time through SPCO + if ($this->continue_reg && ! $this->revisit && $this->current_step->completed()) { + // so advance to the next step + $this->set_next_step(); + if ($this->next_step instanceof EE_SPCO_Reg_Step) { + // and attempt to set it as the current step + $this->set_current_step($this->next_step->slug()); + } + return; + } + $this->current_step->set_is_current_step(true); + $this->current_step->setRequest(EED_Single_Page_Checkout::getRequest()); } diff --git a/modules/thank_you_page/EED_Thank_You_Page.module.php b/modules/thank_you_page/EED_Thank_You_Page.module.php index 94809706d29..d95af61e9a0 100644 --- a/modules/thank_you_page/EED_Thank_You_Page.module.php +++ b/modules/thank_you_page/EED_Thank_You_Page.module.php @@ -275,6 +275,8 @@ public function load_resources() EED_Thank_You_Page::resend_reg_confirmation_email(); } if (! EE_Registry::instance()->SSN instanceof EE_Session) { + // Make sure we allow loading the session. It is required here. + add_filter('FHEE_load_EE_Session', '__return_true', 999); EE_Registry::instance()->SSN = LoaderFactory::getShared('EE_Session'); } EE_Registry::instance()->SSN->clear_session(__CLASS__, __FUNCTION__); diff --git a/public/Espresso_Arabica_2014/content-espresso_event_attendees.php b/public/Espresso_Arabica_2014/content-espresso_event_attendees.php index 7c5791ff69c..6c8d8699f34 100644 --- a/public/Espresso_Arabica_2014/content-espresso_event_attendees.php +++ b/public/Espresso_Arabica_2014/content-espresso_event_attendees.php @@ -24,5 +24,3 @@
  • full_name(true), AllowedTags::getAllowedTags()); ?>
  • - -